Sensor only works once.
Posted: Tue Jul 05, 2022 1:33 am
We use the Nvidia Jetson Orin with Ubuntu 20.04.4 LTS.
After a reboot I can succesfully establish a connection with the HumiditySensor using the following script.
after that when I restart the script, I get TimeOut errors. So it works only once. (after a reboot).
After a reboot I can succesfully establish a connection with the HumiditySensor using the following script.
Code: Select all
from Phidget22.Devices.HumiditySensor import *
Phidget.resetLibrary()
#serial: 627720
def onHumiditySensor0_Attach(self):
print(f"Attach HumiditySensor! {self.getHubPort()}")
hum = HumiditySensor()
hum.setOnAttachHandler(onHumiditySensor0_Attach)
hum.openWaitForAttachment(10000)
hum.close()