Professional Documents
Culture Documents
Temperature and Humidity Sensor With LCD 1602 I2C
Temperature and Humidity Sensor With LCD 1602 I2C
Temperature and Humidity Sensor With LCD 1602 I2C
Temperature and
Humidity sensor
with LCD 1602 I2C
display © GPL3+
Here I am going to display the
temperature and humidity using
the DHT11 sensor and LCD display
1602 with an I2C module and a
relevant code.
Arduino UNO × 1 !
DHT11
Temperature & × 1 !
Humidity Sensor
(3 pins)
DFRobot I2C
16x2 Arduino × 1 !
LCD Display
Module
Premium Male/Male !
Jumper Wires, 40 x 3"
(75mm)
Premium Female/Male !
Extension Jumper Wires,
40 x 6" (150mm)
LiquidCrystal_I2Clcd(0x27,16,2);
void setup() {
dht.begin();// initialize the se
nsor
lcd.backlight();// turn on lcd b
acklight
lcd.init();// initialize lcd
}
void loop() {
lcd.clear();
lcd.setCursor(0,0);// set the
cursor on the first row and colum
n
lcd.print("Humidity=");
lcd.print((float)dht.readHumid
ity());//print the humidity
lcd.print("%");
lcd.setCursor(0,1);//set the c
ursor on the second row and first
column
lcd.print("Temp=");
CODE $
2
1 //by Druhi Chakraborty
3 #include "DHT.h"
4 #define DHTPIN 4// you can use
5 #define DHTTYPE DHT11//#define D
6 //#define D
7 DHT dht(DHTPIN, DHTTYPE);//you c
8 // Pin 15 can work but DHT mu
9 #include <LiquidCrystal_I2C.h>
10 LiquidCrystal_I2C lcd(0x27,
11 void setup() {
12 dht.begin();// initialize the s
13 lcd.backlight();// turn on lcd
14 lcd.init();// initialize lcd
15 }
16 void loop() {
17 lcd.clear();
18 lcd.setCursor(0,0);// set the
SCHEMATICS $
DOWNLOAD
#
temperature_and_humi
dity_sensor_vRLiYYT9rF.
fzz
COMMENTS $
lavitz
7 months ago
Druhi Chakraborty
7 months ago
Druhi Chakraborty
7 months ago
oddjobber
5 months ago
Druhi Chakraborty
5 months ago
AUTHO R
Druhi Chakraborty
1 PROJECT 0 FOLLOWERS
FOLLOW
P U BL ISHED ON
( WRITE A COMMENT
) Share
and 3 others
S IM IL AR PROJ E CTS Y OU MI GH T L I K E
DHT11 Humidity +
Temperature Sensor with 16x2
LCD
Projectdisplay
showcase by onatto22
Temperature + Humidity on
LCD
Project showcase by interpeo
Arduino Temperature -
Humidity - Rain Sensor
Project showcase by Mako
Powered by