add debug
This commit is contained in:
parent
b5f7526345
commit
dab2d4ca75
@ -75,6 +75,7 @@ class driver(inputDriver):
|
|||||||
return time.time()
|
return time.time()
|
||||||
|
|
||||||
def inputWatchdog(self,active , eventQueue):
|
def inputWatchdog(self,active , eventQueue):
|
||||||
|
try:
|
||||||
while active.value:
|
while active.value:
|
||||||
r, w, x = select(self.iDevices, [], [], 0.5)
|
r, w, x = select(self.iDevices, [], [], 0.5)
|
||||||
for fd in r:
|
for fd in r:
|
||||||
@ -106,6 +107,8 @@ class driver(inputDriver):
|
|||||||
if foreward and not eventFired:
|
if foreward and not eventFired:
|
||||||
self.writeEventBuffer()
|
self.writeEventBuffer()
|
||||||
self.clearEventBuffer()
|
self.clearEventBuffer()
|
||||||
|
except Exception as e:
|
||||||
|
self.env['runtime']['debug'].writeDebugOut("INPUT WATCHDOG CRASH: "+str(e),debug.debugLevel.ERROR)
|
||||||
|
|
||||||
def handleInputEvent(self, event):
|
def handleInputEvent(self, event):
|
||||||
return
|
return
|
||||||
@ -184,7 +187,6 @@ class driver(inputDriver):
|
|||||||
self.grabDevice(currDevice.fd)
|
self.grabDevice(currDevice.fd)
|
||||||
self.env['runtime']['debug'].writeDebugOut('Device added (Name):' + self.iDevices[currDevice.fd].name,debug.debugLevel.INFO)
|
self.env['runtime']['debug'].writeDebugOut('Device added (Name):' + self.iDevices[currDevice.fd].name,debug.debugLevel.INFO)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(e)
|
|
||||||
self.env['runtime']['debug'].writeDebugOut("Device Skipped (Exception): " + deviceFile +' ' + currDevice.name +' '+ str(e),debug.debugLevel.INFO)
|
self.env['runtime']['debug'].writeDebugOut("Device Skipped (Exception): " + deviceFile +' ' + currDevice.name +' '+ str(e),debug.debugLevel.INFO)
|
||||||
self.iDeviceNo = len(evdev.list_devices())
|
self.iDeviceNo = len(evdev.list_devices())
|
||||||
self.updateMPiDevicesFD()
|
self.updateMPiDevicesFD()
|
||||||
|
Loading…
Reference in New Issue
Block a user