Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Sensor DHT22 on modul A16
#21
An update, the temperature reading has changed from 25.0 to 24.9 and then 24.8 degrees so it's reading the DHT22 as a DHT11 for temperature (it wasn't just stuck on a value of 25.0), but not humidity which is stuck on 2%.

However this can't be a DHT11 because only the DHT22 does fractional degrees, it must be a DHT22.  However if I try and read it as a DHT22 the readings are zero.  If I try and read it as a DHT11 it works, but the readings are in fractional degrees which only DHT22 can do.

(02-13-2025, 08:42 AM)admin Wrote: can you take a photo of your DHT22 sensor?

Sure, here it is:

   

This is the front, there's no information on there just the plastic face plate:

   
Reply
#22
I've just checked it and it has a 10kΩ pullup on the sensor, could this be what's causing the problem?  That is, if both the sensor and the A16 have pullups you'd have a much lower resistance... but then some sources recommend a 4.7kΩ pullup which is what would be in effect if both ends have 10kΩ pullups so it should still work.
Reply
#23
you can try connect to another GPIO, if also humidty is 2%, i suggest you change a sensor to test, maybe it's broken.
Reply
#24
Sure, I'll test it tomorrow and report results for both a different GPIO and a different sensor.
Reply
#25
I thought perhaps the problem might be conflicting pullups, the DHT22 module has a 10k pullup to Vcc which is 5V when powered from the 433MHz connector and the board has a 47k pullup to 3V on the GPIO connector then this would cause problems. I moved the Vcc for the DHT22 module across to the 3V line on the GPIO connector and I'm still getting the same results, temperature is accurate, currently 24.2 in DHT11 mode which shouldn't be able to sense fractional degrees, humidity is stuck on 2%.

In any case it seems unsafe to power a DHT22 module with internal pullups, which many have, from the 5V 433Mhz connector because you've got pullups to both 3V and 5V, and you're connecting the 3V to 5V line via a 10k + 47k resistor. According to the circuit diagram this goes straight to the ESP32 pin 8 (labelled HT1) which is 2.3 - 3.6V and presumably can't handle 5V.
Reply
#26
because your photo is not Original sensor. i use this one, it's OK.
   
Reply
#27
Yes, there are different types of sensor sold as DHT22, the four-lead one is just the raw sensor while the three-lead ones have internal pullups and possibly other circuitry as well, which may be why it works at 3V rather than 5V.  Doing a search for ones on sale in my country, about 75% of them are the three-lead ones with pullups, only 25% are the four-lead ones without pullups.  I've ordered one of the four-lead ones and will report results when it arrives.
Reply


Forum Jump:


Users browsing this thread:
1 Guest(s)