1

Trying to get a DHT22 sensor to work on a Raspberry Pi ZERO WH running BUSTER. The demo Python program works on pin 21 (4 is in use by my DS18B20 sensors.) I tried the dtoverlay method, but I don't even get a new w1_bus_master2 directory.

If anyone has gotten the dtoverlay method to work, please tell me how. (I've tried JAVA, but none of those examples work either. JAVA would be my preferred way to access it.)

1 Answers1

2

It probably has something to do with the face that DHT22 DOES NOT use the 1-Wire protocol, but a proprietary non-standard protocol - which is similar, but not the same and very critical on timing.

(It should be possible to write a suitable overlay, but AFAIK despite the popularity of DHT11/22 no one has bothered). I note there does seem to be a dht11 overlay, but I have not used it, and never seen any reference to it being used.

Incidentally the Adafruit code, while it does work is unreliable - not to mention overly complex. I use https://raspberrypi.stackexchange.com/a/105549/8697

Milliways
  • 62,573
  • 32
  • 113
  • 225