Commits

iorodeo  committed 2c680e2 Draft

Added serial timeout to python library.

  • Participants
  • Parent commits d557d49

Comments (0)

Files changed (1)

File flyherder_libs/python/flyherder_serial/flyherder_serial/flyherder_serial.py

 class FlyHerder(SerialDevice):
 
     BAUDRATE = 9600 
+    TIMEOUT = 8.0
     DEVICE_MODEL_NUMBER = 1105
     POWER_ON_SLEEP_T = 1.0
     WAIT_SLEEP_DT = 0.2
 
     def __init__(self,*args,**kwargs):
-        kwargs.update({'baudrate': FlyHerder.BAUDRATE})
+        kwargs.update({
+            'baudrate': FlyHerder.BAUDRATE, 
+            'timeout': FlyHerder.TIMEOUT,
+            })
         super(FlyHerder,self).__init__(*args,**kwargs)
         self.deviceInfoDict = self.getDeviceInfoDict()
         self.cmdDict = self.getCmdDict()