Fiverr gig
$15 — I will help you with your project and simulate it for you
Hire me
🔬 Sensor Tutorials

DHT Arduino UNO

EmbedLab TeamApril 5, 20254 min read
DHT Arduino UNO

This project demonstrates a simple yet effective temperature and humidity monitoring system using an Arduino, a DHT11 sensor, and a Liquid Crystal Display (LCD). It allows real-time monitoring of environmental conditions, providing real-time readings of both temperature and humidity. This Arduino-based project is ideal for beginners looking to explore Arduino sensors, temperature sensing, humidity monitoring, and LCD display integration.

Key Features:

  1. DHT11 Sensor Integration:

    • The DHT11 sensor accurately reads temperature (in degrees Celsius) and relative humidity levels, perfect for environmental monitoring projects.
  2. LCD Display:

    • A 16x2 Liquid Crystal Display (LCD) visually presents the real-time temperature and humidity readings, offering a user-friendly interface for easy data visualization.
  3. Temperature Threshold:

    • A predefined temperature threshold of 30°C allows you to set up custom alerts, useful for applications like temperature-sensitive environments or home automation systems.
  4. Serial Monitoring:

    • The data is also sent to the Serial Monitor for debugging and additional functionality, enabling further development and integration with other Arduino projects.

Components Required:

  • Arduino Board (e.g., Uno or Mega)
  • DHT11 Temperature and Humidity Sensor
  • 16x2 LCD with I2C or pin-based connection
  • Jumper Wires
  • Breadboard

How It Works:

  1. The DHT11 sensor continuously measures the surrounding temperature and humidity levels.
  2. These measurements are transmitted to the Arduino and displayed on the LCD screen in real-time, providing immediate feedback on environmental conditions.
  3. The data is also logged to the Serial Monitor, allowing for easier debugging and performance analysis.

This Arduino project is a great starting point for anyone interested in learning about sensor integration, Arduino programming, and creating simple yet effective environmental monitoring systems. You can expand this project to integrate with IoT devices, smart home systems, and other automation technologies for a complete home automation solution.

Schematic:



Schematic



LCD Wiring

Code:

#include <Wire.h>
#include <LiquidCrystal.h>
#include <DHT.h>
#define DHTTYPE DHT11  
#define DHTPIN  A0       // DHT11 sensor used
DHT dht11(DHTPIN, DHTTYPE);  // configure DHT library


LiquidCrystal lcd(12, 11, 5, 4, 3, 2, 10, 9, 8, 7);

const int THRESHOLD = 30; // Temperature threshold


void setup() {
  Wire.begin(); // Join I2C bus with address #8
  lcd.begin(16, 2); // Set up the LCD's number of columns and rows
  lcd.print("DHT11 Sensor");
  dht11.begin(); // Start the DHT11 sensor


void loop() {
  float t = dht11.readTemperature();
  float h = dht11.readHumidity();
if (t >= THRESHOLD) {
    lcd.clear();
    lcd.setCursor(0, 0);
    lcd.print("Temp:"); lcd.print(t);
    lcd.setCursor(0, 1);
    lcd.print("Humidity:"); lcd.print(h);

delay(2000); // Wait for 2 seconds before refreshing data
ET

EmbedLab Team

Embedded systems engineer and educator. Writes weekly tutorials at EmbedLab to help beginners ship real hardware.

Related projects

Arduino UNO with LM35 sensor and I2C LCD showing temperature
🔬 Sensor Tutorials

Arduino UNO I2C Temperature Monitor — LCD, LM35 & Free Arduino IDE Code

Build an Arduino UNO I2C temperature monitoring project step by step: LM35 sensor, I2C LCD display, free Arduino IDE code and Arduino library — same wiring works for Arduino Nano, Arduino Mega and ESP32 Arduino.

Nov 5 6 min
Arduino UNO with HC-SR04 ultrasonic sensor and LCD
🔬 Sensor Tutorials

Arduino UNO Ultrasonic Project — HC-SR04 Distance Sensor with Free Arduino IDE Code

Build an Arduino UNO ultrasonic distance project with the HC-SR04 sensor and LCD display: free Arduino IDE code and Arduino library — easily ported to Arduino Nano, Arduino Mega and ESP32 Arduino.

Oct 27 8 min
Arduino UNO with LM35 temperature sensor and LCD display
🔬 Sensor Tutorials

Fix LM35 Wrong Values on Arduino UNO — Free Arduino IDE Code & LCD Tutorial

How to fix LM35 wrong values on Arduino UNO: free Arduino IDE code, Arduino library, LCD display wiring and analog reference tips — also works for Arduino Nano, Arduino Mega and ESP32 Arduino temperature projects.

Oct 27 8 min
Arduino Ultrasonic Sensor
🔬 Sensor Tutorials

Arduino Ultrasonic Sensor

Arduino ultrasonic projects let you measure distance and respond to it in real time. In this guide, you’ll build a reliable Arduino ultrasonic distance sensor that activates an LED when an object come

Nov 13 10 min
Build Arduino Smart Parking System with LCD & Sensors
🔬 Sensor Tutorials

Build Arduino Smart Parking System with LCD & Sensors

Arduino Smart Parking System Global schematic Are you tired of circling blocks looking for parking? Imagine a smart system that shows you instantly whether a spot is free. This Arduino Smart Parking S

Nov 5 10 min
Browse all 50+ projects