TINKER PiEDESIGN IN INDIA

Temperature + humidity DHT22 with TinkerPie

The white, more accurate sibling of the DHT11.

TypeTiming sensors
Connect toany accessory pin
Gives°C and % RH, more precise
SimulatorUse it on the real board

How it works

The DHT22 (also called AM2302) works like the DHT11 but with better sensing parts, so it covers a wider range with more accuracy. It uses the same one-wire timing signal.

How to wire it

One or two signal pins on S1-S4 or P10-P13. Studio reads them with precise timing in the board firmware.

Code

In blocks: Accessories category in TinkerPie Studio. As code:

// JavaScript
sensors.dhtTemperature(Pin.S1, DhtType.DHT22)

// Arduino C++
sensors::dhtTemperature(Pin::S1, DhtType::DHT22)

Good to know

Try it in TinkerPie Studio

Similar modules

Questions

Can I try the Temperature + humidity DHT22 without buying one?

You can write and check the program in TinkerPie Studio first; to see it work you need the real module connected to the board.

Can I swap a DHT11 for a DHT22 in my project?

Yes. Choose the DHT22 type in the blocks or code and read it a little more slowly (every 2 seconds).