diff options
Diffstat (limited to 'tomorrowtheground.py')
| -rwxr-xr-x | tomorrowtheground.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tomorrowtheground.py b/tomorrowtheground.py new file mode 100755 index 0000000..7b68b12 --- /dev/null +++ b/tomorrowtheground.py @@ -0,0 +1,11 @@ +#!/usr/bin/python +#UDP listener + +import socket +UDP_IP="127.0.0.1" +UDP_PORT=5204 +sock = socket.socket( socket.AF_INET, socket.SOCK_DGRAM ) +sock.bind( (UDP_IP,UDP_PORT) ) +while True: + data, addr = sock.recvfrom( 1024 ) + print "received message:", data
\ No newline at end of file |
