DHT11/22 1wire problems on Omega2 Pro
-
Dear Allium Comrades,
It's been cold here recently... and I've had a hankering to work out how cold it actually is.
What better way of testing my nice new Omega2 Pro than wiring up a DHT22 (or a DHT11) combined temp/humidity sensor checking?
The DHT22/11 sensors communicate via Dallas 1wire. So, I've followed the Communicating with One-Wire Devices instructions, but have had no joy.
the 1w-gpio-custom kmod loads correctly, and I can see the that there is a /sys/devices/w1_bus_master1 directory, but the slave count remains persistently 0.
I've tried with both known-working DHT22 and DHT11 sensors.
I've tested the sensors on an Ardunio, so I know that they're operational, and I've double checked the wiring. I've also tried with and without a 4k7 ohm pullup resistor on the GPIO... but nada.
Any ideas?
-
@chris-Ó-Luanaigh which GPIO are you using? I've had the same thing happen on some GPIOs but then had it work when I tried again on different ones.
-
@Lazar-Demin I've tried 18 and 19
-
@chris-Ó-Luanaigh said in DHT11/22 1wire problems on Omega2 Pro:
The DHT22/11 sensors communicate via Dallas 1wire. So, I've followed the Communicating with One-Wire Devices instructions, but have had no joy.
I 'm afraid that the DHT11/22 sensors are not 1-Wire devices.
-
Yes, very helpful.
There is THE official Dallas-semi's One-Wire (as a noun and very specific, 1-Wire) protocol, there is the almost-there, one-wire (as an adjective) protocol used by DHT11/22/AM2302.See:
https://lastminuteengineers.com/dht11-dht22-arduino-tutorial/
and scroll down to the section with the heading:
"How DHT11 and DHT22/AM2302 Works?"
-
@chris-Ó-Luanaigh
@György-Farkas is correct, DHT11/22 sensors are not 1-wire sensors, that hadn't clicked with me.Check out this blog post on reading DHT11/22 sensors with the Omega2: https://onion.io/2bt-reading-dht-sensor-data/