2

Hello. I've got a question about DHT11 sensor. Why should pullup resistor be connected as on the image below: enter image description here

while as far as I know, pullup resistor should be placed between Arduino 5V pin and Vcc of sensor as shown here: enter image description here

PS: I know that there is a wrong icon of DHT11, but I couldn't find a correct one.

4
  • I don't know why but the datasheet says dataline must be connected to 4.7K pullup robocraft.ru/files/datasheet/DHT11.pdf
    – Lefteris E
    Jul 3, 2021 at 10:32
  • Then it wouldn't be a pull-up resistor; Vcc already is 5V. Signals are what need to be pulled high or kow. Jul 3, 2021 at 10:33
  • @Dave Newton but it seems to me, that when the resistor is connected as shown in the first image, it's in parallel to Vcc-OUT in sensor therefore resistance between 5V and OUT is 0.
    – Maciaz99
    Jul 3, 2021 at 10:56
  • If you draw a proper schematic, you will see that, in the first drawing, the resistor is between Vcc and Out (also called “data”). It “pulls up” the data/Out pin to a high logic level when there’s no internal or external signal driving it.
    – StarCat
    Jul 5, 2021 at 18:39

1 Answer 1

8

You require a pullup resistor between the data wire and VCC because the DHT11 uses a bidirectional communication system on a single wire. When neither end is communicating both ends of the link will be in "high impedance" mode - i.e., input mode. In that case the signal will be "floating" and needs the pullup to keep it in a known state.

When actively communicating the outputs switch to "open drain" mode to allow then to pull the signal low against the pull of the pullup resistor.

A resistor in series with the Arduino's 5V and the VCC of the DHT11 is not a pullup resistor. It is not an arrangement that you would ever want, since it would make the voltage to the DHT11 unstable.

1
  • Note that the pullup is typically not required when using one of the common breakout boards for DHT11 (from Adafruit or similar), because they already include it.
    – PMF
    Jul 4, 2021 at 6:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.