]> gitweb.maison.local Git - pyowl.git/commitdiff
Patch : adujsted a permssion denied message and prepare a big change in customer...
authorlionel <lionel@stargate.enneade.fdn.org>
Tue, 29 Dec 2015 07:37:53 +0000 (08:37 +0100)
committerlionel <lionel@stargate.enneade.fdn.org>
Tue, 29 Dec 2015 07:37:53 +0000 (08:37 +0100)
cm160Server.py

index 285b1a8ea2f8f1554173c347cd694cd8901c579f..a5f4c27ae0c12b93f6bc451aef0e54c47ae0be50 100755 (executable)
@@ -364,7 +364,7 @@ class CM160:
         available.append( (i, s.portstr))
       except serial.SerialException as e:
         if e.__str__().find('Permission denied:') != -1:
-          self.__uo.warn("Try running as root to access %s" % (portname) )
+          self.__uo.warn("No permission on %s ! Adujst it or try running as root (not a good idea)" % (portname) )
     return available
     
   def openSerialPort(self):
@@ -377,7 +377,7 @@ class CM160:
        
     self.__ser = None
     try:
-    # WHY : why must we use a custom cp210x driver ? why can't we just specify the baud rate here ?
+    # TODO WHY : why must we use a custom cp210x driver ? why can't we just specify the baud rate here ?
     # self.__ser = serial.Serial(self.__serialPortName, 250000, bytesize=8, parity='N', stopbits=1, xonxoff=False, rtscts=False, dsrdtr = False, timeout=30)
       #Assume we have the custom cp210x driver loaded that maps the requested baud rate of 0 to a physical port speed of 250000 Bps required 
       #for the CM160 device.