Fixed function name collision
This commit is contained in:
parent
8b89bdeee6
commit
34286c4877
@ -33,14 +33,14 @@ def prepare_grid(grid):
|
||||
out += 'q'
|
||||
return out
|
||||
|
||||
def serial():
|
||||
def serial_func():
|
||||
with serial.Serial('/dev/ttyACM0', 9600, timeout=1) as ser:
|
||||
with lock:
|
||||
if data != '':
|
||||
serial.write(bytes(data, 'ascii'))
|
||||
data = ''
|
||||
|
||||
serial_thread = threading.Thread(target=serial)
|
||||
serial_thread = threading.Thread(target=serial_func)
|
||||
serial_thread.start()
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
Loading…
Reference in New Issue
Block a user