From e3494d280fd6e2db591ea40c4365cdf18524fbdc Mon Sep 17 00:00:00 2001 From: Jack the Ripper Date: Sun, 15 Nov 2015 10:50:45 +0100 Subject: - workaround for timeout error - improved logging - disabled apscheduler in support of a simple sleep() --- usv_driver.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'usv_driver.py') diff --git a/usv_driver.py b/usv_driver.py index c8ba8bc..5cb1167 100755 --- a/usv_driver.py +++ b/usv_driver.py @@ -7,7 +7,8 @@ import re class Usv(object): def __init__(self, device, baudrate, json_file): self._serial_port = serial.Serial(device, - baudrate=baudrate) + baudrate=baudrate, + timeout=10) # force a clean prompt self._serial_port.write(b"\r") -- cgit v1.2.1