{"product_id":"dht22-humidity-temperature-sensor-module","title":"DHT22 Humidity \/ Temperature Sensor Module","description":"\u003cp\u003e\u003cspan\u003e1-wire interface reports humidity (0 to 99.9%) and temp (-40 to 80°C).\u003c\/span\u003e\u003c\/p\u003e\n\u003ch2\u003eDescription\u003c\/h2\u003e\n\u003cp\u003eThe DHT22 Humidity \/ Temperature Sensor Module uses a 1-wire interface to report both humidity (0 – 99.9%) and temperature (-40 – 80°C).\u003c\/p\u003e\n\u003ch2\u003e\u003cstrong\u003ePACKAGE INCLUDES:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cul\u003e\n\u003cli\u003eDHT22 Humidity \/ Temperature Sensor Module\u003c\/li\u003e\n\u003cli\u003eFemale \/ Female 3 x 8″ jumper cable for connecting the module to a microcontroller.\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003ch2\u003e\u003cstrong\u003eKEY FEATURES OF DHT22 HUMIDITY \/ TEMPERATURE  MODULE:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cul\u003e\n\u003cli\u003eReports humidity over range of 0% to 99.9%\u003c\/li\u003e\n\u003cli\u003eReports temperature over range of -40°C to 80°C\u003c\/li\u003e\n\u003cli\u003eUses 1-Wire interface\u003c\/li\u003e\n\u003cli\u003e3.3 and 5V logic compatible\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003eThis module utilizes the DHT22 which is a combined humidity and temperature sensor assembly.  Note that AM2302 is just another name sometimes used for the DHT22 and you may see this marking on the module.\u003c\/p\u003e\n\u003cp\u003eThe DHT22 sensor is capable of reading humidity over the full range of 0 to 99.9% with an accuracy of +\/- 2% and temperature over the range of -40 to 125°C with an accuracy of +\/- 0.5°C.   The humidity accuracy increases to +\/-5% at temperature extremes.\u003c\/p\u003e\n\u003cp\u003eThe device does have a minimum sampling time of 2 seconds so the sensor cannot be polled more often than every 2 seconds or bad data may be retrieved.\u003c\/p\u003e\n\u003ch3\u003eModule Connections\u003c\/h3\u003e\n\u003cp\u003eThe module has a 3-pin header on the assembly.\u003c\/p\u003e\n\u003cp\u003e\u003cstrong\u003e1 x 3 Header\u003c\/strong\u003e\u003c\/p\u003e\n\u003cul\u003e\n\u003cli\u003e\n\u003cstrong\u003e‘+’\u003c\/strong\u003e  =       Connect to 3.3V to 5V.\u003c\/li\u003e\n\u003cli\u003e\n\u003cstrong\u003eOUT\u003c\/strong\u003e  =  Digital sensor I\/O – Connects to a digital pin on a microcontroller\u003c\/li\u003e\n\u003cli\u003e\n\u003cstrong\u003e‘- ‘\u003c\/strong\u003e  =       Connect to system ground.  This ground needs to be in common with the microcontroller.\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003eThe sensor is written and read via a single digital pin and requires the use of a library for the communications.  With an Arduino, the DHTLib library can be downloaded from the Arduino site or GitHub.\u003c\/p\u003e\n\u003ch2\u003e\u003cstrong\u003eOUR EVALUATION RESULTS:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cp\u003eThis is a commonly used module for basic humidity and temperature measurement.  Once up and running with a microcontroller, it is easy to test basic functionality of the module by breathing on the sensor.  That will increase both humidity and temperature temporarily.\u003cimg decoding=\"async\" class=\"alignright wp-image-10211 size-medium entered lazyloaded\" src=\"https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-300x225.jpg\" alt=\"DHT22 Humidity Temperature Module - In Use\" width=\"300\" height=\"225\" data-lazy-srcset=\"https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-300x225.jpg 300w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-768x576.jpg 768w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-249x187.jpg 249w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-400x300.jpg 400w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use.jpg 800w\" data-lazy-sizes=\"(max-width: 300px) 100vw, 300px\" data-lazy-src=\"https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-300x225.jpg\" data-ll-status=\"loaded\" sizes=\"(max-width: 300px) 100vw, 300px\" srcset=\"https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-300x225.jpg 300w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-768x576.jpg 768w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-249x187.jpg 249w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use-400x300.jpg 400w, https:\/\/protosupplies.com\/wp-content\/uploads\/2018\/04\/DHT22-Humidity-Temperature-Module-In-Use.jpg 800w\"\u003e\u003c\/p\u003e\n\u003cp\u003eThe DHT22 has a larger measurement range and higher accuracy compared to the similar DHT11 sensor which is why it costs more.  If you are looking for a less expensive option, check out our DHT11 Module below.\u003c\/p\u003e\n\u003cp\u003eThese sensors are often spec’d to read temps of up to 125C.  While the circuit will indeed measure temps that high, the plastic housing will start to deform, therefore I recommend not using it at temps higher than 80C which is higher than most applications will require anyway.\u003c\/p\u003e\n\u003cp\u003eThe sensor can not be polled faster than once every 2 seconds, otherwise data errors may occur.  If you get occasional bad readings (such as -999.00) try increasing the delay between reads.  Our sample program below uses a 3 second delay just to be safe.\u003c\/p\u003e\n\u003cp\u003eOnce the DHT library is installed, using the device is fairly simple as shown in the code below.  We are using pin 7 for the digital I\/O, but this can be changed to any digital pin.\u003c\/p\u003e\n\u003ch3\u003eDHT22 Humidity \/ Temperature Sensor Test Program\u003c\/h3\u003e\n\u003cpre class=\"copy-the-code-target\"\u003e\u003cspan\u003e\/*\u003c\/span\u003e\n\u003cspan\u003e  DHT22 Temp \/ Humidity sensor module test\u003c\/span\u003e\n\n\u003cspan\u003e  Basic code for exercising the module.\u003c\/span\u003e\n\u003cspan\u003e  Requires DHT library to be installed\u003c\/span\u003e\n\u003cspan\u003e*\/\u003c\/span\u003e\n\n\u003cspan\u003e#include\u003c\/span\u003e \u003cspan\u003e\u0026lt;\u003c\/span\u003e\u003cspan\u003edht\u003c\/span\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eh\u003c\/span\u003e\u003cspan\u003e\u0026gt;\u003c\/span\u003e          \u003cspan\u003e\/\/ Include the DHT library\u003c\/span\u003e\n\u003cspan\u003edht\u003c\/span\u003e \u003cspan\u003eDHT\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e                  \u003cspan\u003e\/\/ Create instance of DHT object\u003c\/span\u003e\n\n\u003cspan\u003eint\u003c\/span\u003e \u003cspan\u003econst\u003c\/span\u003e \u003cspan\u003eDHT22_PIN\u003c\/span\u003e \u003cspan\u003e=\u003c\/span\u003e \u003cspan\u003e7\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e  \u003cspan\u003e\/\/ Connects to sensor I\/O, use any digital pin\u003c\/span\u003e\n\u003cspan\u003eint\u003c\/span\u003e \u003cspan\u003esensor\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e               \u003cspan\u003e\/\/ Dummy variable for sensor read\u003c\/span\u003e\n\u003cspan\u003e\/\/===============================================================================\u003c\/span\u003e\n\u003cspan\u003e\/\/  Initialization\u003c\/span\u003e\n\u003cspan\u003e\/\/===============================================================================\u003c\/span\u003e\n\u003cspan\u003evoid\u003c\/span\u003e \u003cspan\u003esetup\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\n\u003cspan\u003e{\u003c\/span\u003e\n  \u003cb\u003e\u003cspan\u003eSerial\u003c\/span\u003e\u003c\/b\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003ebegin\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e9600\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e     \u003cspan\u003e\/\/ Initialize serial comm\u003c\/span\u003e\n\u003cspan\u003e}\u003c\/span\u003e\n\u003cspan\u003e\/\/===============================================================================\u003c\/span\u003e\n\u003cspan\u003e\/\/  Main\u003c\/span\u003e\n\u003cspan\u003e\/\/===============================================================================\u003c\/span\u003e\n\u003cspan\u003evoid\u003c\/span\u003e \u003cspan\u003eloop\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\n\u003cspan\u003e{\u003c\/span\u003e\n  \u003cspan\u003esensor\u003c\/span\u003e \u003cspan\u003e=\u003c\/span\u003e \u003cspan\u003eDHT\u003c\/span\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eread22\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003eDHT22_PIN\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e  \u003cspan\u003e\/\/ Read sensor\u003c\/span\u003e\n  \u003cb\u003e\u003cspan\u003eSerial\u003c\/span\u003e\u003c\/b\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eprint\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e\"Temperature = \"\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e  \u003cspan\u003e\/\/ Printout returned results\u003c\/span\u003e\n  \u003cb\u003e\u003cspan\u003eSerial\u003c\/span\u003e\u003c\/b\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eprint\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003eDHT\u003c\/span\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003etemperature\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e\n  \u003cb\u003e\u003cspan\u003eSerial\u003c\/span\u003e\u003c\/b\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eprint\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e\" C  \"\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e\n  \u003cb\u003e\u003cspan\u003eSerial\u003c\/span\u003e\u003c\/b\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eprint\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e\"Humidity = \"\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e\n  \u003cb\u003e\u003cspan\u003eSerial\u003c\/span\u003e\u003c\/b\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eprint\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003eDHT\u003c\/span\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003ehumidity\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e\n  \u003cb\u003e\u003cspan\u003eSerial\u003c\/span\u003e\u003c\/b\u003e\u003cspan\u003e.\u003c\/span\u003e\u003cspan\u003eprintln\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e\" %\"\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e\n  \u003cspan\u003edelay\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e3000\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e  \u003cspan\u003e\/\/ 2 sec min read time, so using 3 to be safe\u003c\/span\u003e\n\u003cspan\u003e}\u003c\/span\u003e\n\u003cbutton class=\"copy-the-code-button\" data-style=\"svg-icon\" title=\"Copy\"\u003e\u003csvg aria-hidden=\"true\" role=\"img\" class=\"copy-icon\" viewbox=\"0 0 16 16\" width=\"16\" height=\"16\" fill=\"currentColor\" focusable=\"false\"\u003e\u003cpath d=\"M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z\"\u003e\u003c\/path\u003e\u003cpath d=\"M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z\"\u003e\u003c\/path\u003e\u003c\/svg\u003e\u003c\/button\u003e\u003c\/pre\u003e\n\u003ch2\u003e\u003cstrong\u003eBEFORE THEY ARE SHIPPED, THESE MODULES ARE:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cul\u003e\n\u003cli\u003eSample inspected and tested for correct operation\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003e\u003cem\u003eNotes: \u003c\/em\u003e\u003c\/p\u003e\n\u003col\u003e\n\u003cli\u003e\u003ci\u003eWire colors may vary from the pics\u003c\/i\u003e\u003c\/li\u003e\n\u003c\/ol\u003e\n\u003chr\u003e\n\u003ch2\u003eTechnical Specifications\u003c\/h2\u003e\n\u003ctable class=\"table table-hover\" width=\"862\"\u003e\n\u003ctbody\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003cstrong\u003eMaximum Ratings\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e          V\u003csub\u003ecc\u003c\/sub\u003e\n\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eRange\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e3.3 to 5.5V\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e          V\u003csub\u003emax\u003c\/sub\u003e\n\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e\u0026lt;500uA\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e          T\u003csub\u003emin\u003c\/sub\u003e\n\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e Minimum Sampling Period\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e2 seconds\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003cstrong\u003eOperating Ratings\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e          Humidity\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eRange\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e0% to 99.9%RH  (+\/- 2%RH)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e          Temperature\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e -40 to 80°C   (+\/- 0.5°C)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003cstrong\u003eDimensions\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eL x W (PCB)\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e37 x 16mm (1.5 x 0.6″)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003cstrong\u003eDatasheet\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e\u003ca href=\"https:\/\/akizukidenshi.com\/download\/ds\/aosong\/AM2302.pdf\" rel=\"noopener noreferrer\" target=\"_blank\"\u003e\u003cspan\u003e\u003cstrong\u003eDHT22\u003c\/strong\u003e\u003c\/span\u003e\u003c\/a\u003e\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003c\/tbody\u003e\n\u003c\/table\u003e\n\u003c!----\u003e","brand":"Keszoox","offers":[{"title":"Default Title","offer_id":45683396903147,"sku":"","price":7.37,"currency_code":"USD","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0677\/1005\/8731\/files\/DHT22-Humidity-Temperature-Module.jpg?v=1723005280","url":"https:\/\/keszooxstore.com\/products\/dht22-humidity-temperature-sensor-module","provider":"Keszoox","version":"1.0","type":"link"}