File indexing completed on 2024-11-03 06:41:20

0001 #!/usr/bin/python
0002 
0003 from socket import *
0004 import psutil
0005 
0006 HOST = 'localhost'
0007 PORT = 1027
0008 ADDR = (HOST,PORT)
0009 client = socket(AF_INET, SOCK_DGRAM)
0010 client.bind(ADDR)
0011 while True:
0012   data, addr = client.recvfrom(1024)
0013   print('read ' + data, addr)
0014 
0015