Commit 7438afffb16b1b5d67bb0b2822cbda986e8b0358
1 parent
3f616717
Exists in
dev
bientot le ACK 06 !!! avec reponse G#
Showing
1 changed file
with
50 additions
and
2 deletions
Show diff stats
sockets_tele/client_gemini_run.py
... | ... | @@ -46,16 +46,64 @@ with SocketClientTelescopeGEMINI(HOST, PORT, DEBUG) as tsock: |
46 | 46 | #pos = tsock.get_position() |
47 | 47 | #dec = tsock.get("DEC") |
48 | 48 | #ra = tsock.get("RA") |
49 | + ''' | |
49 | 50 | radec = tsock.get("RA-DEC") |
50 | 51 | print("RA-DEC is", radec) |
52 | + ''' | |
53 | + | |
54 | + # TEST BAS NIVEAU POUR ACK 06: | |
55 | + ''' | |
56 | + >>> a=b'\x3A' | |
57 | + >>> a | |
58 | + b':' | |
59 | + >>> a.decode() | |
60 | + ':' | |
61 | + | |
62 | + >>> a=b'\x47' | |
63 | + >>> a | |
64 | + b'G' | |
65 | + >>> a.decode() | |
66 | + 'G' | |
67 | + | |
68 | + >>> a=b'\x44' | |
69 | + >>> a | |
70 | + b'D' | |
71 | + >>> a.decode() | |
72 | + 'D' | |
73 | + | |
74 | + >>> a=b'\x23' | |
75 | + >>> a | |
76 | + b'#' | |
77 | + >>> a.decode() | |
78 | + '#' | |
79 | + >>> tsock.mysock.sendto(b'\x00\x00\x00\x01\x00\x00\x00\x00\x3A\x47\x44\x23\x00', (HOST, PORT)) | |
80 | + RECEIVED (ALL BYTES): b'\x00\x00\x00\x01\x00\x00\x00\x00+90.000000#\x00' | |
81 | + | |
82 | + >>> a=b'\x52' | |
83 | + >>> a | |
84 | + b'R' | |
85 | + >>> a.decode() | |
86 | + 'R' | |
87 | + >>> tsock.mysock.sendto(b'\x00\x00\x00\x01\x00\x00\x00\x00\x3A\x47\x52\x23\x00', (HOST, PORT)) | |
88 | + RECEIVED (ALL BYTES): b'\x00\x00\x00\x01\x00\x00\x00\x008.911844#\x00' | |
51 | 89 | |
90 | + >>> tsock.mysock.sendto(b'\x00\x00\x00\x01\x00\x00\x00\x00\x00\x06\x00\x00', (HOST, PORT)) | |
91 | + RECEIVED (ALL BYTES): b'\x00\x00\x00\x01\x00\x00\x00\x00G#\x00' | |
92 | + | |
52 | 93 | ''' |
53 | - TEST BAS NIVEAU POUR ACK 06: | |
54 | 94 | #tsock.mysock.sendto(b'00030000:GD#\x00', (HOST, PORT)) |
55 | 95 | #tsock.mysock.sendto(b'00030000\x06\x00', (HOST, PORT)) |
56 | 96 | #tsock.mysock.sendto(b'00030000\x00\x06\x00', (HOST, PORT)) |
57 | 97 | #tsock.mysock.sendto(b'00030000\0x06\x00', (HOST, PORT)) |
58 | - tsock.mysock.sendto(b'00010000\0x06\x00', (HOST, PORT)) | |
98 | + #tsock.mysock.sendto(b'00010000\0x06\x00', (HOST, PORT)) | |
99 | + # :GD# | |
100 | + ###tsock.mysock.sendto(b'\x00\x00\x00\x01\x00\x00\x00\x00\x3A\x47\x44\x23\x00', (HOST, PORT)) | |
101 | + # :GR# | |
102 | + ###tsock.mysock.sendto(b'\x00\x00\x00\x01\x00\x00\x00\x00\x3A\x47\x52\x23\x00', (HOST, PORT)) | |
103 | + ''' | |
104 | + #tsock.mysock.sendto(b'\x00\x00\x00\x01\x00\x00\x00\x00\x00\x05\x00\x00\x00\x00\x00', (HOST, PORT)) | |
105 | + ACK 06 OK !!! | |
106 | + tsock.mysock.sendto(b'\x00\x00\x00\x01\x00\x00\x00\x00\x00\x06\x00\x00', (HOST, PORT)) | |
59 | 107 | data_received = tsock.receive_data() |
60 | 108 | ''' |
61 | 109 | ... | ... |