To read temperature and humidity data using DHT22 sensor and Arduino UNO and logs it to the serial monitor.
- Arduino UNO
- DHT22 sensor
- 10kΩ Pull-up Resistor
- Jumper wires
- Install the 'DHT' and 'Adafruit Unified Sensor' libraries.
- Upload the code to the Arduino using Arduino IDE.
- Open the Serial Monitor to view the data.
+---------------------+
| Arduino Uno |
| |
| [5V] ----------- (VCC) -- DHT22
| |
| [GND] ---------- (GND) -- DHT22
| |
| [Pin 2] --------- (DATA) -- DHT22
| |
+---------------------+
|
10kΩ Resistor
|
(VCC)
- Temperature: 25.3 °C | Humidity: 60.5 %
- Temperature: 26.1 °C | Humidity: 59.7 %
- Temperature: 24.8 °C | Humidity: 62.0 %