This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
|
tutorials:learn:sensors:dht.html [2011/06/23 00:13] daigo created |
tutorials:learn:sensors:dht.html [2016/01/28 18:05] (current) |
||
|---|---|---|---|
| Line 5: | Line 5: | ||
| - | This tutorial covers the low cost [[http://www.adafruit.com/category/35_66|DHT temperature & humidity sensors]]. These sensors are very basic and slow, but are great for hobbyists who want to do some basic data logging. The DHT sensors are made of two parts, a capacitive humidity sensor and a[[http://www.ladyada.net///thermistor.html| thermistor.]] There is also a very basic chip inside that does some analog to digital conversion and spits out a digital signal with the temperature and humidity. The digital signal is fairly easy to read using any microcontroller. | + | This tutorial covers the low cost [[http://www.adafruit.com/category/35_66|DHT temperature & humidity sensors]]. These sensors are very basic and slow, but are great for hobbyists who want to do some basic data logging. The DHT sensors are made of two parts, a capacitive humidity sensor and a[[http://www.ladyada.net/learn/sensors/thermistor.html| thermistor.]] There is also a very basic chip inside that does some analog to digital conversion and spits out a digital signal with the temperature and humidity. The digital signal is fairly easy to read using any microcontroller. |
| Line 41: | Line 41: | ||
| As you can see, the [[http://www.adafruit.com/products/385|DHT22]] is a little more accurate and good over a slightly larger range. Both use a single digital pin and are 'sluggish' in that you can't query them more than once every second or two. | As you can see, the [[http://www.adafruit.com/products/385|DHT22]] is a little more accurate and good over a slightly larger range. Both use a single digital pin and are 'sluggish' in that you can't query them more than once every second or two. | ||
| - | **You can pick up both the [[http://www.adafruit.com/products/386|DHT11]] and DHT22 from the adafruit shop!** | + | **You can pick up both the [[http://www.adafruit.com/products/386|DHT11]] and [[http://www.adafruit.com/products/385|DHT22]] from the adafruit shop!** |
| Line 86: | Line 86: | ||
| {{ http://www.ladyada.net/images/sensors/dhttester.gif?nolink&566x600 |}} | {{ http://www.ladyada.net/images/sensors/dhttester.gif?nolink&566x600 |}} | ||
| + | <class center> | ||
| If you're using a **DHT11** sensor, comment out the line that sets the type: | If you're using a **DHT11** sensor, comment out the line that sets the type: | ||
| + | <code> | ||
| //#define DHTTYPE DHT22 // DHT 22 (AM2302) | //#define DHTTYPE DHT22 // DHT 22 (AM2302) | ||
| + | </code> | ||
| and uncomment the line that says | and uncomment the line that says | ||
| + | <code> | ||
| #define DHTTYPE DHT11 // DHT 11 | #define DHTTYPE DHT11 // DHT 11 | ||
| + | </code> | ||
| + | </class> | ||