Datasheet

4
3. Usage
3.1 With Arduino
This demo is going to show you how to read temperature and humidity information from this Grove
- Temperature and Humidity Sensor.
The Temperature and Humidity sensor is connecting to analog port A0 of Grove - Base Shield.
Download Humidity_Temperature_Sensor library for Arduino boards with 16MHz XTAL; Unzip
and put it in the libraries file of Arduino IDE by the path: ..\arduino-1.0\libraries; Another library
- DHTlib is also available instead of Humidity_Temperature_Sensor library. This library supports
both 16MHz and 8MHz Arduino(eg. Seeeduino Stalker)
Open DHTtester example via the path: File --> Examples -->
Humidity_Temperature_Sensor --> DHTtester.
// Example testing sketch for various DHT humidity/temperature sensors
// Written by ladyada, public domain
#include "DHT.h"
#define DHTPIN A0 // what pin we're connected to
// Uncomment whatever type you're using!
#define DHTTYPE DHT11 // DHT 11
//#define DHTTYPE DHT22 // DHT 22 (AM2302)