DHT22 module wiring colour and function

The module came with a plug in 3 wire set of colours green, red and black.

Am I correct as follows (?):
Green = ground
Red = 5v
Black = data

1 Like

DFRobot products use the following colour coding convention:
image
And Black for ground.

1 Like

Many thanks.

I made an assumption that Red for Power, Green for ground, and Black for data – there was nothing on the Core Electronics website with the product and nothing in the module product box.

Anyway – to an RPi 4, I had Red power hooked up correctly to a 5 volt pin, Green Digital I/O hooked up to ground, and Black ground hooked up to various GPIO # pins.

Is it possible I may have damaged the Pi?

Is it possible I have damaged the DHT22 module and its sensor?

Hi :slight_smile:

It really depends on how you connected it up, and how long for, but it’s not likely.

The DHT22 requires an external pullup, which means its got a high impedance pull-down internally, so swapping the ground and data around probably didn’t hurt your Pi or the sensor because there is probably a high impedance path between the ground and data pins.

If everything’s working correctly, you got away lucky! Good lesson though - always double-check the datasheet and connections or you can damage your expensive kit.

Many thanks Oliver

Yes – good learning lesson for me.

I suppose I am less concerned for the sensor / module than I am for the Raspberry Pi.

Any tips on how I would confirm whether Pi has been damaged or not. Would it be as simple as running pintest (I recall seeing something of that on the Internet), or would there need to be a more thorough check than that?

If it’s working, that’s a pretty good sign - I wouldn’t worry too much I don’t expect any damage. But yes, pintest could help check:

http://wiringpi.com/download-and-install/
http://wiringpi.com/the-gpio-utility/pin-test/

Many thanks.

2 Likes