DHT11 / DHT22 Sensor Pinout, Circuit, and Wiring Diagram
Hi, in this article, we are going to see the DHT11 Sensor Pinout, Circuit, and Wiring Diagram. The DHT11 is a very simple basic low-cost digital sensor used to measure temperature and humidity. It uses a single-wire digital interface to communicate with microcontrollers or other devices. This makes it easy to integrate into a variety of projects. It sends data as a 40-bit packet, which includes the humidity and temperature readings. The DHT11 Sensor is used for Monitoring temperature and humidity levels. It is also used for controlling heating, ventilation, and air conditioning (HVAC) systems. It can be used in smart devices to monitor and report environmental data.
DHT11 Sensor Pinout Diagram
Here, you can see the Pinout Diagram of the DHT11 Sensor.
As you can see in the above figure, the DHT11 sensor has four pins where one pin is unused. The Pin 1 is VCC). It is used to power the sensor. It should be connected to a 3.3V to 5V power supply.
Pin 2 is DATA or OUT. This pin is used for communication between the sensor and the microcontroller. It transmits the digital signal, carrying the temperature and humidity data. Generally, a pull-up resistor (4.7kΩ to 10kΩ) is connected between this pin and the VCC to stabilize the signal.
Pin 3 is NC. This pin is not connected to anything and is usually left unconnected. In some versions of the DHT11, this pin might be absent altogether.
Pin 4 is Ground(GND). This pin is connected to the ground of the power supply. It provides the reference voltage for the sensor and completes the circuit.
DHT11 Sensor Circuit Diagram
Here, you can see the circuit diagram of a DHT11 Sensor Module where the sensor is mounted on a small PCB board. A pull-up resistor is connected between the Data and the VCC pin to stabilize the signal. Also, you can see that Pin 3 is kept disconnected as it is an NC terminal. Only three terminals are brought to the output of the sensor module.
DHT11 Sensor Connection with Arduino
Here, you can see the wiring diagram for connecting a DHT sensor with Arduino for an automatic fan control circuit.
You can see, the Signal or Data pin of the DHT11 Sensor Module is connected to the Digital Pin no 2 of the Arduino. The Vcc pin of the DHT11 Sensor Module is connected to the 3.3V power pin of the Arduino. The Ground pin of the DHT11 Sensor Module is connected to the GND pin of the Arduino.
The DHT11 sensor continuously measures the temperature and humidity of the surrounding environment. As the sensor is connected to the Arduino so the Arduino reads the data from the DHT11 sensor through its digital I/O pin (e.g., pin D2).
Then the Arduino processes this data and checks whether the temperature exceeds a predefined threshold (for example 30°C).
The relay is used to control the power supply to the cooling fan. The Arduino sends a HIGH or LOW signal to the relay module based on the temperature reading.
If the temperature exceeds the threshold: The Arduino sends a HIGH signal to the relay module, which closes the relay switch and turns on the cooling fan.
If the temperature is below the threshold the Arduino sends a LOW signal to the relay module, which opens the relay switch and turns off the cooling fan.
DHT22 Sensor Pinout Diagram
Here, you can see the pinout diagram of the DHT22 Sensor.
You can see the pinout of the DHT11 and DHT22 sensors is the same so, you can use the DHT22 Sensor in the same way as the DHT11 sensor. The difference between the DHT11 and DHT22 Sensors is that the temperature range of DHT11 is 0°C to 50°C whereas the temperature range of DHT22 is -40°C to 80°C. The humidity Range of DHT11 is 20% to 90% RH whereas the humidity range of DHT22 is 0% to 100% RH.
Read Also:
DHT11 / DHT22 Sensor Pinout, Circuit, and Wiring Diagram
Reviewed by Author
on
August 13, 2024
Rating: