Hello so I just fixed the permission issue, pin number was wrong because refering to a wrong jetson card type (xavier and not nano … ) But everytime I read the value I still get TG(-39909.0, -39909.0, 0) with no value and 0 at the end. 0 at the end means “communication error” if I am not mistaking. I am using a 3 pin DHT11, left pin connected to 3.3v center pin to pin 37 of the jetson nano for the data and right pin to grn through a 10k resistor. Anything wrong in my setup ?
do you still see Operation not permitted failures by using root permission?
BTW, there’re level shifters, you may see-also application note for 40-Pin Expansion Header.
No I don’t have permissions error anymore. I am always getting (-39909.0, -39909.0, 0) as answer where, if I am right the last 0 means communication error.
At the moment my DHT11 sensor is connected as follows:
left pin of DHT11 to pin 17 of Jetson nano (3.3v)
center pin of DHT11(Data) to pin 37 of Jetson nano
right pin of DHT11 to pin 9 of Jetson nano (Grn)
it should be checksum failure, are you able to examine the byte values, its last 8-bit for the check-sum.
BTW, how about using the other approach to fetch the values? i.e. C_DHT.readSensor(0), and C_DHT.readSensor(1).
may I also know how long is the cable? you may also try reduce the length to avoid line voltage drop.
this is also mentioned in the datasheet, please try configure the wait time to 5-sec for reading data.
when power is supplied to sensor, don’t send any instruction to the sensor within one second to pass unstable status.
Still not … even with 5V and with 5 sec.
The picture is showing the model I Use, 3 pins with embedded resistor.
I tried with signal connected to pin 29 and with signal connected to pin 37.
My C_DHT.c #define PIN0 jetsonnano_pin37 #define PIN1 jetsonnano_pin29
My Code:
import C_DHT
import time
while True:
C_DHT.readSensorDHT11(0)
C_DHT.readSensorDHT11(1)
time.sleep(5)