Introduction: TEMPERATURE AND HUMIDITY MEASUREMENT USING DHT 11
In this project ,I am using DHT 11 temperature and humidity sensor to measure our environment temperature as well as humidity using Arduino (Nano).
SOME OF THE BASIC ELECTRICAL CHARACTERISTICS:
OPERATING VOLTAGE: 3.5V-5V
CURRENT (measurement):0.3 mA
CURRENT (standby):60 micro amps
RANGE:0 to 50 degree Celsius
RESOLUTION: 16bit
SAMPLING PERIOD: >2 ms
Step 1: CREATING SCHEMATIC
In this schematics using an DHT11 sensor with 5k(ohm) pull up resistor for data line.
PINS:
RED WIRE TO +VCC
BLACK WIRE TO GND
YELLOW WIRE WITH 5 K RESISTOR
3rd pin is NO CONNECTION
COMPONENTS NEEDED:
1. Arduino
2. DHT11 temp and humidity sensor
3.5 k ohm resistor
I AM USING DHT11 WITH BUILT IN RESISTOR AND CAPACITOR FOR PULL UP AND SMOOTHENING THE INPUT VOLTAGE RESPECTIVELY.
Step 2: EXPERIMENT TIME-CONNECTIONS
I have been connected the pins accordingly
5v - +VCC
GND - GND
digital pin 2 - DATA PIN
Step 3: EXPERIMENT TIME-CODE
Using Arduino IDE we can program our Arduino board
but first download and install the library for DHT sensors..
the purpose of downloading the library is to reduce the complexity of the code.
I am downloading the library called SIMPLEDHT it is awesome.
after installing the library by clicking install button.
open file-examples- simpledht-dht11 default.
I am using DHT11. if you are using DHT22 there is also an example code below.. RIGHT THERE...
after opening the code. connect the Arduino board to your computer, and select the PORT. and upload the example sketch.
make sure you connect the data pin to digital pin2 of the Arduino..
CODE PART IS DONE
Step 4: EXPERIMENT TIME - SETUP
after uploading the code open the serial monitor.
you will observe that the sensor sends the data.
not much hard right?
Step 5: WORKING
As I said that the sensor sends out 40bits
8bit humidity integer data + 8bit humidity decimal data + 8bit temperature integer data + 8 bit temperature fractional data + 8bit check sum= 40 bits
Example 1: 40 data received:
0011 0101 0000 0000 0001 1000 0000 0100 1101
Calculate: 0011 0101+0000 0000+0001 1000+0000 0000= 0100 1101
Received data is correct
Humidity:0011 0101=35H (hex) =53%RH
Temperature:0001 1000=18H (hex) =24℃.
SOURCE:-
https://media.digikey.com/pdf/Data%20Sheets/Adafruit%20PDFs/DHT11_ProdManual.pdf
THANK YOU GUYS
IF YOU FIND MISTAKES PLEASE WRITE IN COMMENTS.
SO THAT I CAN RECTIFY IT.
BECAUSE I AM A BUDDING ENGINEER.
IN NEXT PROJECT I CAN USE A LCD DISPLAY TO DISPLAY TEMPERATURE.
STAY AWSOME GUYSS...……………..
Attachments

Participated in the
First Time Author
Comments