mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
dxgrid socket command
This commit is contained in:
parent
b1b63ce26f
commit
e922e3d289
1 changed files with 10 additions and 1 deletions
9
sock.py
9
sock.py
|
@ -140,6 +140,15 @@ class CMDTCPRequestHandler(socketserver.BaseRequestHandler):
|
|||
static.MYCALLSIGN_CRC8 = helpers.get_crc_8(static.MYCALLSIGN)
|
||||
logging.info("CMD | MYCALLSIGN: " + str(static.MYCALLSIGN))
|
||||
|
||||
if received_json["command"] == 'SET:MYGRID':
|
||||
mygrid = received_json["parameter"]
|
||||
|
||||
if bytes(mygrid, encoding) == b'':
|
||||
self.request.sendall(b'INVALID GRID')
|
||||
else:
|
||||
static.MYGRID = bytes(mygrid, encoding)
|
||||
logging.info("CMD | MYGRID: " + str(static.MYGRID))
|
||||
|
||||
|
||||
if received_json["command"] == 'GET:STATION_INFO':
|
||||
output = {
|
||||
|
|
Loading…
Reference in a new issue