|
|
@ -173,7 +173,6 @@ try: |
|
|
|
conn, addr = s.accept() |
|
|
|
conn, addr = s.accept() |
|
|
|
|
|
|
|
|
|
|
|
while True: |
|
|
|
while True: |
|
|
|
try: |
|
|
|
|
|
|
|
m = conn.recv(1) |
|
|
|
m = conn.recv(1) |
|
|
|
|
|
|
|
|
|
|
|
if len(m) == 0: |
|
|
|
if len(m) == 0: |
|
|
@ -193,9 +192,10 @@ try: |
|
|
|
v = int(round(w.pos_y*100)) |
|
|
|
v = int(round(w.pos_y*100)) |
|
|
|
r += struct.pack('b', v) |
|
|
|
r += struct.pack('b', v) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
try: |
|
|
|
conn.send(r) |
|
|
|
conn.send(r) |
|
|
|
except ConnectionResetError: |
|
|
|
except ConnectionResetError: |
|
|
|
continue |
|
|
|
break |
|
|
|
except (KeyboardInterrupt, SystemExit): |
|
|
|
except (KeyboardInterrupt, SystemExit): |
|
|
|
t1.stop = True |
|
|
|
t1.stop = True |
|
|
|
t2.stop = True |
|
|
|
t2.stop = True |
|
|
|