##// END OF EJS Templates
imanay -
r58:59
parent child
Show More
@@ -8,7 +8,7
8 8 No newline at end of file
9 9 class ABSClient: No newline at end of file
10 10
11 No newline at end of file
11 def __init__(self,ipSource="localhost", ipDestino="192.168.1.255", portDestino=7000): No newline at end of file
12 12 No newline at end of file
13 13 self.ipSource = ipSource No newline at end of file
14 14 self.ipDestino = ipDestino No newline at end of file
@@ -1,7 +1,13
1 1 import socket No newline at end of file
2 import select No newline at end of file
2 3 No newline at end of file
3 4 dgramSock = socket.socket( socket.AF_INET, socket.SOCK_DGRAM ) No newline at end of file
4 5
6 No newline at end of file
5 dgramSock.sendto( "Hello World\n", ('', 23000) ) No newline at end of file
No newline at end of file
7 #dgramSock.setblocking(0)
No newline at end of file
8 dgramSock.sendto( "Hello World\n", ('192.168.1.117', 7000) )
No newline at end of file
9 ready = select.select ([dgramSock],[],[],35)
No newline at end of file
10 if ready[0]: No newline at end of file
6 11 print dgramSock.recv( 100 ) No newline at end of file
7 12 dgramSock.close() No newline at end of file
General Comments 0
You need to be logged in to leave comments. Login now