bilalda1
Published

Display Temperature and Humidity on LCD

Display Temperature and Humidity on 16x2 LCD

IntermediateFull instructions provided283
Display Temperature and Humidity on LCD

Things used in this project

Hardware components

Arduino UNO
Arduino UNO
×1
DHT11 Temperature & Humidity Sensor (3 pins)
DHT11 Temperature & Humidity Sensor (3 pins)
×1
Rotary potentiometer (generic)
Rotary potentiometer (generic)
I used a bigger potentiometer but don't worry this potentiometer will work even better. 10k pot will be perfect but you can use any other for sure
×1
Breadboard (generic)
Breadboard (generic)
×1
Jumper wires (generic)
Jumper wires (generic)
×1

Software apps and online services

Arduino IDE
Arduino IDE

Story

Read more

Schematics

Temp Hum LCD

NOTE: FOLLOW THE TEXT, FIRST PIN OF THE LCD CONNECT TO GROUND AND SECOND PIN TO 5V. ON THE SCHEMATICS IT'S INVERSED. FOLLOW THE TEXT I TYPED

Code

Temp Hum LCD

Arduino
Code works
#include <LiquidCrystal.h>
#include <DHT.h>
int pin = 6;
int type = DHT11;
DHT dht (pin, type);
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

void setup() {
  // put your setup code here, to run once:
  lcd.begin(16, 2);
   dht.begin();
}

void loop() {
  // put your main code here, to run repeatedly:
 
 
 float Temp = dht.readTemperature();
  lcd.setCursor(0, 0);
   lcd.print("Temp:");
    lcd.print(Temp);
     lcd.print("C");

 float Humid = dht.readHumidity();

  lcd.setCursor(0, 2);
   lcd.print("Humid:");
    lcd.print(Humid);
     lcd.print("%");

}

Credits

bilalda1

bilalda1

1 project • 1 follower

Comments