Fix bug.
This commit is contained in:
parent
86c37fa5b1
commit
dc0934bb97
2
relay.py
2
relay.py
@ -75,7 +75,7 @@ if action != 'status':
|
|||||||
#print ('Renvoie :\r\n' + bytes)
|
#print ('Renvoie :\r\n' + bytes)
|
||||||
|
|
||||||
ser.write('?RLY\r\n'.encode('ascii'))
|
ser.write('?RLY\r\n'.encode('ascii'))
|
||||||
answer = ser.readline()
|
answer = ser.readline().decode('ascii')
|
||||||
status = ''
|
status = ''
|
||||||
for char in answer:
|
for char in answer:
|
||||||
if char in ['0', '1']:
|
if char in ['0', '1']:
|
||||||
|
Loading…
Reference in New Issue
Block a user