Home - Blog

DHT22 Pinout: How it Works and its Application

If you have a faulty dehumidifier system, your home will have extensive mold growth, risking your family’s health and property value. Besides, a dysfunctional temperature and humidity sensor can lead to a defective dehumidifier. However, the DHT22 pinout can help in troubleshooting your system. 

It’s a low-cost digital humidity and temperature sensor that connects through a single digital wire. Additionally, the DHT22 pinout has a thermistor and capacitive humidity sensor, making it applicable to HVAC and dehumidification systems for measuring air ambiance. In this article, you’ll learn about the DHT22 pinout connection; now, let’s get started!

What is DHT22?

The DHT22 is a simple temperature and humidity sensor with a digital display. It measures the ambient air with a capacitive humidity sensor and a thermistor and outputs a digital signal on the data pin, requiring no analog input pins.

Pin Specifications and Configurations

The DHT22 is a simple temperature and humidity sensor with a digital display. It measures the ambient air with a capacitive humidity sensor and a thermistor. And it outputs a digital signal on the data pin, requiring no analog input pins.

Pin Configuration

NoPin NameDescription
DHT22 Module
1VCCIt has a power supply of 3.5V to 5.5V.
2DataThe temperature and humidity output signals via serial data.
3GroundThe module usually connects to the ground of a circuit.
DHT22 Sensor
1VCCIt also has a power supply voltage of 3.5V to 5.5V
2DataThe humidity and temperature output via serial data.
3NCNot applicable because it has no connection.
4GroundThe DHt22 humidity sensor specs also connect to the ground of a circuit.

DHT22 Specifications

  • It operates on 3.5 to 5.5 volts.
  • The standby operating voltage current is 60uA, while the measuring is 0.3mA.
  • Serial data acts as the output.
  • The temperature measuring range is around -40°C to 80°C.
  • Temperature and humidity are both 16-bit resolutions.
  • -0.5°C accuracy and 1 percent accuracy.

Difference Between DHT22 Sensor and Module

The sensor comes with a 4-pin package, and only three pins are functional, while the module only comes with an applicable 3-pin package. See the illustration of the AM2302 sensor pinout below.

DHT22 Sensor Pinout, Specs, Equivalents, Circuit & Datasheet

Besides, you will also notice that the module has an inbuilt pull-up resistor and a filtering capacitor. However, these are not inbuilt for the sensor, and you can only use them externally whenever required.

The module is slightly more expensive than the DHT11, but it has a more comprehensive measurement range and superior precision.

Where Can You Use DHT22 Pinout?

The DHT22 uses minimal electricity because it is compact, and Additionally the length of its transmission is roughly 20 meters. The primary application for the DHT22 sensor is to help in measuring the ambient temperature and humidity.

As much as DHT11 can perform the same job and give almost similar results, most people find the DHT22 more dependable. This device is pre-calibrated and has inbuilt digital temperature compensation.

They build these sensors to be functional in various severe environments, and you can easily interface the devices with microcontrollers or Arduino UNO.  

Moreover, this sensor would be appropriate for use in an application that requires a sensor to detect the temperature in the range. Here are the preferable sensor readings -40°C to +125°C or to monitor humidity.

How to Use DHT22

When opening the DHT22/AM2302 sensor or DHT11 sensor, you’ll notice two sensing elements: an NTC (thermistor) and a humidity sensor.

Besides, the humidity sensor device has two electrodes connected by a moisture-holding substrate. One can measure the resistance between the electrodes using the sensor. However, the results are not constant because it depends on the temperature and moisture values in the air.

If you check at the back of the sensor, you will find/see a tiny IC that helps measure and process the analog signal. Moreover, the IC helps convert the measurements from analog to digital and store the calibration coefficients.

Connection of DHT22 with Any Microcontroller

You don’t need any electrical components to complete the connections. The device comes with four pins, but one of them is not a connecting pin. However, the good news is that you can connect any microcontroller to the functional three pins.

The DHT22 runs in a serial asynchronous mode since it lacks a clock pin. Therefore, keeping it in high logic requires a pull-up resistor between the data line and the ground.

Besides, you will require a pull-up resistor between the sensor and the microcontroller for accessible serial communication. 

Microcontroller

Microcontroller

Interfacing the Sensor with PIC Microcontroller

You can connect this sensor directly to a PIC microcontroller or an Arduino since the breakout board has an integrated pull-up resistor.

The diagram below uses a PIC18F25K20  type of program to receive data from a DHT22 sensor through the RAO pin. You can also use a pull-up resistor with humidity readings of 4.7k or 10k. Moreover, you can now connect the PIC18F25K20’s RA0 pin to the data output pin. Below is a connection between a DHT22 sensor and a PIC microcontroller.

Applications for the DHT22

  • You can use the DHT22 sensor in the HVAC industry.
  • Testing and inspection equipment.
  • Home appliances and consumer products to measure temperature and humidity range.
  • Used in the medical units to detect humidity levels of patients in isolation wards.
  • To monitor the weather, fax machines, refrigerators, food processing devices, among others.
  • In Pharmaceutical units to ensure the humidity levels are at acceptable limits.
  • Automatic climate control.
  • Medical devices to assess air humidity levels for patients who suffer from certain lung diseases.
HVAC System

HVAC System

Summary

It would help if you did not worry about your indoor or outdoor weather monitoring anymore. The DHT22 provides a cost-effective alternative to traditional hygrometers. And they are relatively cheap and have a wide temperature and humidity ranges, applicable in several settings. 

Whether you need the sensor module for HVAC, home appliances (like a fridge), weather monitoring, and other projects, you’ll need specialized production. So calibrating the DHT22 to your project’s specifications will ensure efficiency and practicality. 

Now, you know everything about the DHT22 sensor module. You can now finish your projects that may require temperature and humidity sensors-at affordable prices. 

If you have any questions about the DHT22 pinout, please get in touch with us!

Avatar photo
Emma Lu
Our professional engineering support saves our customers a lot of trouble and loss. >>>>>> After you place the order, our engineer will conduct technical reviews to make sure the parts can be mounted well/correctly on the boards. We will check if the component packages match well with the Gerber footprints, if the part numbers you provided match well with the descriptions, and if the polarity is clearly marked. >>>>> When your design is ready, please send your Gerber and BOM so we can quote and start!

Services