0% found this document useful (0 votes)
10 views8 pages

DHT 11 Sensor

DHT 11 Sensor wrking.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views8 pages

DHT 11 Sensor

DHT 11 Sensor wrking.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 8

DHT 11/22 Sensor

• DHT11 sensor measures and provides humidity and temperature values


serially over a single wire.

• It can measure relative humidity in percentage (20 to 90% RH) and


temperature in degree Celsius in the range of 0 to 50°C.

• It has 4 pins one of which is used for data communication in serial form.

• DHT11 sensor uses resistive humidity measurement component, and NTC


temperature measurement component.
DHT11 Specifications

• Ultra-low cost

• 3 to 5V

• 2.5mA max current use during conversion (while


requesting data)

• Good for 20-80% humidity readings with 5% accuracy

• Good for 0-50°C temperature readings ±2°C accuracy


DHT22 Specifications
• Low cost

• 3 to 5V

• 2.5mA max current use during conversion (while requesting data)

• Good for 0-100% humidity readings with 2-5% accuracy

• Good for -40 to 125°C temperature readings ±0.5°C accuracy


DHT11 Sensor
Install Python 3 Dependencies
• sudo apt-get update

• sudo apt-get install python3-pip

• sudo python3 -m pip install --upgrade pip


setuptools wheel
DHT 11 Library Installation Command
• Install with pip

• Python 2:
– sudo pip install Adafruit_DHT

• Python 3:
– sudo pip3 install Adafruit_DHT
DHT 11

import Adafruit_DHT
import time as t

while True:
humidity, temperature = Adafruit_DHT.read_retry(11, 4)
print ('Temp: {0:0.1f} C Humidity: {1:0.1f} %'.format(temperature,
humidity))
time.sleep(2)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy