This tutorial will teach you how to read temperature and humidity readings using the IC Station DHT22 Temperature & Humidity Module. Once you have those readings, you can calculate neat things like Heat Index and Dew Point, and by adding a wind speed sensor, Wind Chill.
Use checkout code “steveics”, and get a 15% discount on the sensors!
Become the Maker you were born to be. Try Arduino Academy for FREE!
Unlike the bare sensors, this one is assembled with the appropriate resistor, so there’s only 3 connections. + connects to Arduino 5v or 3.3v, – to Ground, and out connects to the digital pin of your choice. We are using pin 2 per the included example.
Once again we are using an awesome library written by Adafruit:
Download and import into your Arduino sketchbook libraries folder using the import library feature in the IDE per our previous tutorial.
Load the example sketch DHTtester found under File, Examples, DHT Sensor Library.
Since we are using the Arduino Micro, we added the following line just after Serial.begin(9600);
while (!Serial) ; //needed for leonardo and micro
Now upload to your Arduino and run the Serial Monitor. You should see something similar to the following:
This example already includes Metric and Standard unit display. We will be adding Dew Point calculations at a later date.