Did some searching but couldn’t find anyone experiencing the same weird issue I’ve found with DHT11 and DHT22 sensors, so figured I’d ask the question. Most folks are adding resistors.
I have several DHT11 and DHT22 sensors that I wired according to the recommendation including a 4.7 K ohm resistor. Hooked them up to a NodeMCU for testing using the default config HERE and neither would work.
Here’s the DHT11 sensor I used…
After quite some time I cut out the resistors on the DHT11 and DHT22 and they started working perfectly?? I am really confused why that would be the case?? Thoughts?
Was the resistor between data and vcc? If so it should have worked. All i can think is to test the resistance of the resistor and check its not been labled wrong.
4.7 ohm? Is that a typo or did you really use 4.7 ohm? It should be 4.7 KILOohm…
But, if sensor already have resistor onboard external is generally not needed, if wires are not too long. Adding it might lower resistance value to a point when it’s too low and then doesn’t work anymore.
Hi @phillipzx3 thought that to, so measured resistance across connectors vcc and data and not showing 4.7K resistance. Blew my mind, so no idea. I had heard some GPIO ports on NodeMCU have built in resistors… but I’ve never seen it, so figure it is not true.
ESP8266EX has 17 GPIO pins which can be assigned to various functions by programming
the appropriate registers. Each GPIO can be configured with internal pull-up or pull-down, or set to high impedance
I’ll also add that NodeMCU is firmware, not the hardware
To answer your question… yes, it is an ESP8266, and thanks for the explanation of the NodeMCU, I wasn’t aware that was firmware.
I think you might be on to something re the internal pull-up or pull-down, maybe that is what is going on here. I will do some research and see if I can figure out how to turn the internal pull-up or pull-down on/off.
I see there is a way for esphome to change the pullup, but have never used it before. Wondering what the default setting is?
I have some devkit v1 ESP32 units, so do they have the internal pull-up or pull-down as well? I am thinking I might try an ESP32 instead of the ESP8266.
Hey hey
using an esp32 together with esphome i have a DHT22 sensor (not module, so it has four pins) without a resister but the internal pull-up functionality
Most sensors already have pull up resistor on-board. But, if not, internal pull-up will work until distance between esp and sensor is short. When using long(er) cable problems will occur, since internal resistor is pretty high valued so cable will start to pickup noise.