Skip to content
Home » Arduino Dht11 I2C Lcd | Hiển Thị Nhiệt Độ, Độ Ẩm Lên Lcd Sử Dụng I2C

Arduino Dht11 I2C Lcd | Hiển Thị Nhiệt Độ, Độ Ẩm Lên Lcd Sử Dụng I2C

Temperature and humidity sensor Dht 11 with i2c LCD display

Step 4: You Are Done!

Upload the sketch to your board and you are done!

This code will work with the sensor and screen that I have gotten from AliExpress.com

The LCD code especially was done based on the code provided by turbiny as a comment on this instructable

The end result is as shown in the picture.

DHT11 Temperature and Humidity with LCD Display

The data from DHT11 Sensor send to Arduino UNO and then displaying the humidity and temperature on the I2C LCD Display.

Parts List
  • Arduino UNO
  • I2C LCD display 16×2
  • DHT11 Temperature and Humidity Sensor
  • 4.7k resistor
Library

DHT11 LibraryWire LibraryLiquidCrystal_I2C Library

Wiring Arduino UNO + I2C LCD + DHT11 Sensor
Upload Code to Arduino

#include

#include

#include

#include LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE); // Addr, En, Rw, Rs, d4, d5, d6, d7, backlighpin, polarity int pin = A0; DHT11 dht11(pin); double Fahrenheit(double celsius) { return ((double)(9 / 5) * celsius) + 32; } double Kelvin(double celsius) { return celsius + 273.15; } void setup() { lcd.begin(16, 2); lcd.backlight(); lcd.clear(); lcd.print(“Humidity & temp”); delay(3000); lcd.clear(); lcd.print(“Starting…..”); delay(3000); } void loop() { int err; float temp, humi; if ((err = dht11.read(humi, temp)) == 0) { lcd.clear(); delay(500); lcd.setCursor(0, 0); lcd.print(“Temp”); lcd.setCursor(0, 1); lcd.print(“Humidity”); lcd.setCursor(9, 0); lcd.print(temp); lcd.print(” C”); lcd.setCursor(9, 1); lcd.print(humi); lcd.print(” %”); delay(10000); } else { lcd.println(); lcd.print(“Error No :”); lcd.print(err); lcd.println(); } }


DHT11 Sensors Temperature and Humidity and i2c LCD – arduino

What Will I Learn?

In this tutorial we will learn how to use the DHT11 sensor for measuring temperature and humidity and either heat Index. And we will see the value output of the DHT sensors on both the serial monitor and the LCD screen. we are going to use The LCD screen componen with this tutorial you can also print on a serial monitor on the Desktop IDE. Code and circuit diagram are compatible within both sensors. so lets start the procedures.

Requirements

We need these couples of components in this tutorial,

  • DHT11 Sensor Module
  • I2C LCD Display 2×16
  • Arduino board
  • Breadboard
  • Jumper wires
  • Type b usb cable
Difficulty
  • Intermediate
Tutorial Contents

Were going to use the I2C LCD to display the Temperature and Humidity that the DHT11 has captured, I used an Arduino UNO 5V pin to support the DHT11 and the I2C display. DHT22 humidity sensor can be used in place of DHT11 for more accuracy and higher resolution. i made a Circuit diagram on fritzing for you to easily follow the wirings.

Connection of I2c Display to arduino board

  • VCC – 5V
  • GND – GND
  • SCL – A4
  • SDA – A5

Connection of DHT11 sensor module to arduino board

  • VCC – 3.3V
  • GND – GND
  • DAT – PIN 2 PWM

SOFTWARE

We are done building the circuit so lets start to set up and make a code for this. we are going to use the arduino ide, to set the sketch for this, if you dont have make sure to download the Arduino IDE for your specific operating system. I’ll leave a link to where you can download this software: https://www.arduino.cc/en/Main/Software

  • After the installation we need to download the DHT11 library for the sensor module Library or you can directly Installed from the Library Manager in Arduino IDE or download on github; https://github.com/adafruit/DHT-sensor-library

  • We need to download the i2c library To get the i2c 2×16 LCD library download it here: https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads/ just download the latest one.

When the download is finished open the zip file then copy the folder unzip the folder to your desktop you can rename it as well.

Cut the folder in your desktop then go to your folders then locate the arduino folder>> libraries then paste it there. and now the folder liquidcrystal and DHT11 library is already in the arduino ide libraries.

The first thing we need to do is to define the i2c LCD address i will put here the code of the i2c scanner

LiquidCrystal_I2C lcd(INPUT ADDRESS HERE, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);

cut the input address here on the code and put i2c address there.to do this download the i2c scanner on this link http://www.mediafire.com/file/f7oaa4et779yaaz/i2c_scanner.ino open it with arduino DEsktop IDE compile then upload it to the board, now click on the serial monitor and get the address of your LCD.

An address before the ! sign is the address of your display. lets say your address is 0x27 replace the input address here with your captured address. so it will become

LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);

when making a code we need include all the libraries we will be using we have to add the library that we have recently downloaded.

#include

for DHT sensor library and

#include

for the i2c 2×16 LCD DISPLAY.

#define DHTPIN 2

Define DHT pin this the pin where the sensor pin of the DHT is connected to the digital pin 2 on the arduino board.

LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);

Input the i2c address that we recently make.

DHT dht;

define the uppercase DHT to dht in lowercase to recognized that the lower case is the same as upper case on the same state.

setup()

method is ran once at the just after the Arduino is powered up and the

loop()

method is ran continuously afterwards.

setup()

is where you want to do any initialisation steps, and in

loop()

you want to run the code you want to run over and over again.

lcd.begin(16,2);

initializes the LCD 2X16 and specifies the dimensions

lcd.print

the iput text word that appears on the serial monitor or lcd display.

delay(2000);

1000 is equals to 1 second timeframe.

COPY SOURCE CODE HERE:


#include

#include #define DHTPin 2 //define DHT pin LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE); DHT dht; void setup() { dht.setup(DHTPin); lcd.begin(16,2); //initializes the LCD and specifies the dimensions } void loop() { float temp = dht.getTemperature(); float humi = dht.getHumidity(); lcd.setCursor(0,0); lcd.print("Temp: "); lcd.print(temp); lcd.print(" C"); lcd.setCursor(0,1); lcd.print("Humi: "); lcd.print(humi); lcd.print(" %"); delay(2000); }

The end result is as shown in the picture.

I hope you enjoy this actitvity if want to learn how arduino works, and how to make a sketch, then maybe this site http://educ8s.tv/ might help you, i was inspired by Mert Arduino and Techfor this wonderful stuff. and thank you for stopping by.

You can also check my previous posts:

Humidity and temperature meter using DHT11 and OLED Display DHT11 Sensors Temperature and Humidity Tutorial using Arduino Ultrasonic Sensor HC-SR04 with IIC LCD Display (Distance Meter) i2C Oled display and 8glib Library arduino Control 2 servo with Potentiometer/ XOD Controlling 2 Servo Motor with Joystick Ultrasonic Sensor HC-SR04 alarm system

Posted on Utopian.io – Rewarding Open Source Contributors

Your contribution cannot be approved because it does not follow the Utopian Rules.

  • https://steemit.com/utopian-io/@pakganern/dht11-sensors-temperature-and-humidity-tutorial-using-arduino
  • This doesn’t make sense. Are you trying to abuse the utopian platform? If so you may be banned.
  • Ignoring the lcd which doesn’t really make a big deal, the rest is the same.

You can contact us on Discord.[utopian-moderator]

Oh! Im sorry, never do it again. I thought i can add different component and make a post then. By the way thank you for reviewing. Im new to utopian im really sorry about this.

Hiển thị nhiệt độ, độ ẩm lên LCD sử dụng I2C

Màn hình LCD I2C Arduino UNO R3
GND GND
VCC 5V
SDA A4
SCL A5
Cảm biến nhiệt độ, độ ẩm DHT11
VCC 5V
DATA D4
GND GND

Sơ đồ đấu nối

Các linh kiện cần thiết cho dự án:

Linh kiện Số lượng Shoppe
Arduino Uno R3 Xem ngay
Dây cáp nạp Xem ngay
Màn hình LCD 16×2 Xem ngay
Module I2C LCD 16×2 Xem ngay
Cảm biến nhiệt độ, độ ẩm DHT11 Xem ngay
Bread Board (Bo Test) Xem ngay
Dây cắm ( Đực – Cái) Xem ngay
Dây cắm ( Đực – Cái) Xem ngay
Nguồn 12V/2A Jack DC (Nếu có rồi không cần mua) Xem ngay
Temperature and humidity sensor Dht 11 with i2c LCD display
Temperature and humidity sensor Dht 11 with i2c LCD display

Giải thích code

Hàm createChar()

lcd.createChar(1, degree);

Dùng để tạo một ký tự tùy chỉnh để sử dụng trên màn hình LCD 16×2. Tối đa có 8 ký tự được hỗ trợ là 5×8 pixel (được đánh số từ 0 đến 7).Sự xuất hiện của mỗi ký tự tùy chỉnh được chỉ định bởi một mảng gồm 8 byte, 1 byte cho mỗi hàng.

Để hiển thị một ký tự tùy chỉnh trên màn hình ta dùng hàm write() để viết ra con số đó.

Cú pháp

lcd.createChar(số, dữ liệu)

Thông số

lcd: là một biến của kiểu dư liệu LiquidCrystal.

số: tạo ký tự (0 đến 7).

dữ liệu: dữ liệu của các ký tự là pixel.

Hàm isnan()

if (isnan(t) || isnan(h))

Hàm isnan() là hàm trả về true hoặc false nếu giá trị cần kiểm tra không phải là một biểu thức toán học đúng.

Ở đoạn code trên mình kiểm tra xem thử việc đọc giá trị của nhiệt độ hoặc độ ẩm trả về có bị thất bại hay không.

Cú pháp

isnan(double x) ;

Hàm round()

lcd.print(round(t));

Hàm round() là hàm làm tròn của một giá trị nào từ số thập phân làm tròn tới số nguyên gần nhất.

Step 2: Wiring the LCD, Sensor, and Arduino

Wiring is rather simple. I wired the sensor on a breadboard as per the diagram above. DHT11 needs 3.3 volts and the LCD needs 5 v.

Arduino, LCD, and sesnor Pin Assignments:

  • PIN 12: DHT Data
  • SDA: LCD SDA
  • SCL: LCD SCL
  • 3V3: DHT Power
  • 5V: LCD VCC
  • GND: LCD and DHT Gnd
Arduino | Hiển Thị Nhiệt Độ & Độ Ẩm Cảm Biến DHT11 Lên LCD
Arduino | Hiển Thị Nhiệt Độ & Độ Ẩm Cảm Biến DHT11 Lên LCD

Introduction: Arduino Temp/Humidity Sensor Using DHT11 and I2C LCD One Day Project

I have purchased an Arduino Mega 2560 set which came with some sensors and of course, and Arduino Mega.

In this instructable, I will share with you the steps I took to make an Arduino based temperature and humidity display.

Items required:

  • Arduino Mega 2560
  • LCD1602 IIC I2C

  • DHT11 Temperature/Humidity sensor
  • Breadboard
  • Jumper wires
  • 10K

Step 1: IDE Libraries Required

DHT11 Library is available on https://github.com/adafruit/DHT-sensor-library. You can download the ZIP file and include the library in your IDE.

The I2C LCD was a bit tricky. I took hours to figure out how to get it to work, and I then found F Malpartida’s New LiquidCrystal library which was brilliant. This can be downloaded from https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads and added to the IDE.

Arduino Weather Station || dht11 Temperature & Humidity sensor
Arduino Weather Station || dht11 Temperature & Humidity sensor

Code mẫu

#include

#include

#include LiquidCrystal_I2C lcd(0x3F,16,2); const int DHTPIN = 4; const int DHTTYPE = DHT11; DHT dht(DHTPIN, DHTTYPE); byte degree[8] = { 0B01110, 0B01010, 0B01110, 0B00000, 0B00000, 0B00000, 0B00000, 0B00000 }; void setup() { lcd.init(); lcd.backlight(); lcd.print(“Nhiet do: “); lcd.setCursor(0,1); lcd.print(“Do am: “); lcd.createChar(1, degree); dht.begin(); } void loop() { float h = dht.readHumidity(); float t = dht.readTemperature(); if (isnan(t) || isnan(h)) { } else { lcd.setCursor(10,0); lcd.print(round(t)); lcd.print(” “); lcd.write(1); lcd.print(“C”); lcd.setCursor(10,1); lcd.print(round(h)); lcd.print(” %”); } }

Bạn sẽ học được gì

  • Có kiến thức cơ bản về Robotics
  • Chế tạo Robot dò đường thông minh
  • Đánh thức nhà khoa học bên trong bạn
  • Tìm hiểu thêm về Robotics, các thuật toán Robot tự động
  • Kiến thức nền tảng để chế tạo các máy móc tự động phục vụ đời sống sinh hoạt, lao động sản xuất
  • Kiến thức để chế tạo sản phẩm, tham gia các cuộc thi khoa học công nghệ trong nước và quốc tế

CHI TIẾT BÀI VIẾT

HƯỚNG DẪN SỬ DỤNG CẢM BIẾN DHT11 VÀ ARDUINO HIỂN THỊ NHIỆT ĐỘ VÀ ĐỘ ẨM LÊN MÀN HÌNH LCD

1. Giới thiệu

Bài viết này sẽ hướng dẫn các bạn cách sử dụng Sensor (cảm biến) DHT11 với Arduino và LCD để hiển thị nhiệt độ, độ ẩm.

2. Nội dung chính

  • Sử dụng cảm biến nhiệt độ và độ ẩm DTH11 kết nối với Arduino.
  • Sử dụng LCD hiển thị nhiệt độ và độ ẩm từ DHT11.

3. Phần cứng cần thiết

  • Arduino Uno R3
  • LCD Text LCD1602
  • Module giao tiếp I2C

– LCD có quá nhiều chân gây khó khăn trong quá trình đấu nối và chiếm dụng nhiều chân trên vi điều khiển.

– Module I2C ra đời để giải quyết vấn để này.

– Thay vì phải sử dụng 6 chân vi điều khiển để kết nối với LCD 16×2 (RS, EN, D7, D6, D5 và D4) thì module IC2 bạn chỉ cần tốn 2 chân (SCL, SDA) để kết nối.

– Module I2C hỗ trợ các loại LCD sử dụng driver HD44780(LCD 16×2, LCD 20×4, …) và tương thích với hầu hết các vi điều khiển hiện nay.

  • Module DHT11 (sensor đo độ ẩm và nhiệt độ)

  • BreadBoard

4. Kết nối các thiết bị

  • Nối nguồn Arduino với Breadboard

– Nối trực tiếp chân 5V từ Arduino ra Board mạch tại cực dương.

– Nối trực tiếp chân GND từ Arduino ra Board mạch tại cực âm.

  • Thực hiện kết nối DHT11 với Arduino
  • Kết nối Module I2C & LCD với Arduino

5. Code thiết bị Arduino

Để sử sensor DHT11 giao tiếp với Arduino thì ta cần cài đặt thư viện DHT_Sensor

– Mở phần mềm Arduino 🡪 Sketch 🡪 Include Lirbary 🡪 Add .zip Library 🡪 chọn tới file zip DHT-sensor.zip.

– Tương tự ta add tiếp 🡪 file zip Adafruit_Sensor-master.zip

– Sau khi add thư viện nên thoát khỏi phần mềm Arduino rồi mở lại.

– Gọi thư viện DHT Sensor , LiquidCrystal_I2C.

– Mở Phần mềm Arduino 🡪 Sketch 🡪 Include Lirbary 🡪 Kéo xuống dưới chọn DHT_Sensor.

– Mở Phần mềm Arduino 🡪 Sketch 🡪 Include Lirbary 🡪 Kéo xuống dưới chọn LiquidCrystal_I2C.

LiquidCrystal_I2C lcd(0x27,16,2); // Khai báo LCD

  • Đặt địa chỉ LCD là 0x27 cho màn hình LCD 16×2.
  • 16 là số cột của màn hình (nếu dùng loại màn hình 20×4) thì thay bằng 20.
  • 2 là số dòng của màn hình (nếu dùng loại màn hình 20×4) thì thay bằng 4.

Code cấu hình DHT11, Arduino, LCD

#include

#include

LiquidCrystal_I2C lcd(0x27,16,2);

const int DHTPIN = 2;

const int DHTTYPE = DHT11;

DHT dht(DHTPIN, DHTTYPE);

byte degree[8] = {

0B01110,

0B01010,

0B01110,

0B00000,

0B00000,

0B00000,

0B00000,

0B00000

};

void setup() {

lcd.init();

lcd.backlight();

lcd.print(“Nhiet do: “);

lcd.setCursor(0,1);

lcd.print(“Do am: “);

lcd.createChar(1, degree);

dht.begin();

void loop() {

float h = dht.readHumidity();

float t = dht.readTemperature();

if (isnan(t) || isnan(h)) {

else {

lcd.setCursor(10,0);

lcd.print(round(t));

lcd.print(” “);

lcd.write(1);

lcd.print(“C”);

lcd.setCursor(10,1);

lcd.print(round(h));

lcd.print(” %”);

Thực hiện: Nguyễn Mạnh Cương

Hardware components
Software apps and online services
Hand tools and fabrication machines

Now I have been struggling with this project for like hours now. But at the end I find out I did not have the correct knowledge. So people it is very important to know what you are making. In this case I recommend you to go through the page and not just copy and paste the code.

Now, this project uses a DHT11 temperature and humidity sensor with the three pin but you can also use any other sensor the changes in the code should be as per the model. I have used Arduino UNO for this project.

First, make the connection of the DHT sensor with the Arduino board.

VCC – 5.5V

DATA – PIN 4(you can also use pins 3, 4, 5, 12, 13 or 14

Pin 15 can work but DHT must be disconnected during program upload)

GND – GND

Second, make the connection of the LCD 1602 I2C display with the above circuit.

LCD connections with Arduino board

VCC – 5.5V

GND – GND

SDA – A4(Analog Pin 4)

SCL – A5(Analog Pin 5)

If you are thinking what I am thinking then the circuit will look something like this:

Red Wires indicate the VCC wires and the black ones indicate GND wires.

NOTE- If you see that your sensor is rapidly getting warm(only for 4 pin sensors) then attach a 10K pull up resistor joining VCC and Signal ends of the sensor.

Lastly, the code part where the real understanding begins. So, basically I have used two libraries one for the sensor and the other for the LCD 1602 I2C display. Then let us start:

We first insert the DHT library the link to download this library is given below. So it will go something like this.


#include"DHT.h"

Then define the sensor pin. As I have taken the data pin to be 4. My code will be followed as


#defineDHTPIN4

After that we need to determine the sensor that is being used. Now, I have used the DHT 11 sensor but if you have a different sensor then the code will change as per the sensor model


#defineDHTTYPEDHT11

Then using the above data


DHTdht(DHTPIN,DHTTYPE);

After interfacing with the DHT sensor we now are going to move on to the LCD display


#include


LiquidCrystal_I2Clcd(0x27,16,2);

So, now we are ready to start with the void setup and loop part.

I wrote the whole code together hope you may not find it too difficult.


void setup() { dht.begin();// initialize the sensor lcd.backlight();// turn on lcd backlight lcd.init();// initialize lcd } void loop() { lcd.clear(); lcd.setCursor(0,0);// set the cursor on the first row and column lcd.print("Humidity="); lcd.print((float)dht.readHumidity());//print the humidity lcd.print("%"); lcd.setCursor(0,1);//set the cursor on the second row and first column lcd.print("Temp="); lcd.print((float)dht.readTemperature());//print the temperature lcd.print("Celsius"); delay(2000); lcd.clear(); }

Please note that the temperature is automatically in the celsius scale ergo you do not need to change any values unless you want the answer in Farenheit.

I strongly recommend the Arduino Web Editor as you do not need to download any additional libraries since it is pre-included but if you do not use the web editor and use the software instead you may need to make slight changes but the main part remains the same.

NOTE- If you are using the software then you do not need to download the LiquidCrystal_I2C library as it is pre-included in the software.

If you want to download the DHT library then click here.

Looks like we have reached the end of the project.

Bye guys, have fun.

Hi all,
I am new to Arduino. I am trying to connect my Arduino UNO with I2C LCD display and DHT11 sensor. I connected all, tried different codes, but results for humidity and temperature are always 0.

          #include 
#include 
//#define DHTTYPE DHT11
LiquidCrystal_I2C lcd(0x27, 16, 2); // I2C address 0x3F, 16 column and 2 rows
#define DHTPIN 4
dht DHT;
//DHT ddt(DHTPIN, DHTTYPE);
void setup(){
lcd.init();
lcd.backlight();
lcd.begin(16,2);
Serial.begin(9600);
}
void loop(){
DHT.read11(DHTPIN);
lcd.setCursor(0, 0);
lcd.print("Humidity = ");
lcd.print(DHT.humidity);
lcd.print("% ");
delay(2000);
lcd.setCursor(0, 1);
lcd.print("Temp: ");
lcd.print(DHT.temperature);
lcd.print((char)223); // print ° character
lcd.print("C ");
delay(1000);
}

        

I followed this

tutorial

I tried to change pin for data on DHT11 from 2 to 3,5,7,8 and A0, but result is the same.
I tried to change code multiple times, tried given code and code in tutorial.
I am pretty sure that board and all wires are working properly.
Printing results as Serial.print also gives 0, so I doubt that my DHT11 sensor is not working.
Any help? Advice?

Several things to try. Try the contrast trim pot and see if your characters will appear, you should at least get some blocks where the characters should appear. If that does not work change your lcd.print statements to Serial.print and see if you get the information on the console. At this point you will know if your problem is in the interface-library or the hardware. If this does not resolve your problem post a schematic and links to each of the hardware devices.

The FLOAT value direct from the sensor needs to be formatted for printing. Try

          lcd.print(String(DHT.temperature, 1) + char(223));
...
lcd.print(String(DHT.humidity, 0) + "%");

        

DHT temp only has 1 decimal place, humidity has zero.

With this code change, I got “0%” for humidity and nothing is printed for temperature.
Tested on both Serial.print and lcd.print and result is the same.
Here is the output I get:

I got same result on lcd and in console, 0 for both temperature and humidity.
Here is my schema:

andjelkadzida:


DHT.read11(DHTPIN);

Maybe it ought to be —
DHT.read(DHTPIN);

Still getting the same result, printing only 0 values.

Your pic shows DHT data connected to D2,
but your sketch has —

#define

DHTPIN 4
// So Use D4

Some modules show 5V supply rather than the 3v3 you have.
So which DHT11 module do you have?
Are you using a breadboard for connections.
Show a photo of what you have in front of you rather than what could be.

I tried using different pins, but still facing the same issue.

The above diagram shows that DATA-pin of the Sensor is connected with DPin-2 of UNO. So, check that the following code line has been included in your sketch.


#define DHTPIN 2 //and not #define DHTPIN 4

I have DTH11 with 3 connectors (VCC, Data and GND). Tried with 3.3V and 5V, but no result.
I do not use breadboard.

Yes, I corrected the code and uploaded it once again, but result is the same.




Paul_B






17

Did you actually

read

the question before posting that?


1 Like

Try by uploading the following sketch and report result:

          #include  //header file containing codes various commands
dht DHT; //dht = className; DHT = Object
#define DHT11_PIN 2
void setup()
{
Serial.begin(9600);
}
void loop()
{
int chk = DHT.read11(DHT11_PIN);
if (chk != 0)
{
Serial.print("There is error!");
while (1); //wait for ever
}
Serial.println("Sensor is found.");
Serial.println();
Serial.print("Humidity: ");
float myHum = DHT.humidity;
Serial.print(myHum, 2); Serial.println ('%');
Serial.print("Temperature = ");
float myTemp = DHT.temperature;
Serial.print(myTemp, 2); //2-digit after decimal point
Serial.print(' '); Serial.println("degC");
delay(1000); //test/sampling interval
}

        


Output:

          Humidity: 22.00%
Temperature = 29.00 degC

        

If the DHT-11 was not connected you’d get NAN (Not A Number) returned on your display for f and h. Soo, I’d say your DHT is fried. If it’s returning zero’s for both, that sounds like a dead ground.

Did you try the Example sketch for the library that you are using to read the DHT11?

Well basically you have changed the code from the link description and I was wondering why…

Also, do you have pullup resistor on the data line (10k) ….perhaps it is already on the module.

Either way, throw in some pics of “what you have there” include power supply.

Temperature & Humidity Sensor |  DHT 11 With I2C Module LCD Display
Temperature & Humidity Sensor | DHT 11 With I2C Module LCD Display

EBOOK ARDUINO CHO NGƯỜI MỚI BẮT ĐẦU

Trong bài viết hôm trước mình đã hướng dẫn các bạn làm thế nào để hiển thị các ký tự lên màn hình LCD 16×2 bằng giao tiếp I2C.

Tiếp tục trong chuỗi bài viết về LCD hôm nay mình sẽ hướng dẫn các bạn làm thế nào để hiển thị các thông số của cảm biến nhiệt độ, độ ẩm lên LCD.

Để hiểu hơn về bài viết này các bạn đọc lại 2 bài viết bên dưới rồi chúng ta tiếp tục bài này tiếp nha.

  • Đọc thêm: Tổng quan LCD 16×2 và giao tiếp I2C LCD sử dụng Arduino
  • Đọc thêm: Đọc nhiệt độ, độ ẩm (DHT11) sử dụng Arduino Uno

Keywords searched by users: arduino dht11 i2c lcd

Beginner Arduino Project - Dht11 With Lcd (I2C) - Youtube
Beginner Arduino Project – Dht11 With Lcd (I2C) – Youtube
Arduino Uno R3 With Dht11 And 16X2 I2C Lcd - Youtube
Arduino Uno R3 With Dht11 And 16X2 I2C Lcd – Youtube
Hiển Thị Nhiệt Độ, Độ Ẩm Lên Lcd 16X2 Giao Tiếp Bằng I2C Sử Dụng Arduino |  Arduino Kit
Hiển Thị Nhiệt Độ, Độ Ẩm Lên Lcd 16X2 Giao Tiếp Bằng I2C Sử Dụng Arduino | Arduino Kit
Temperature and humidity sensor Dht 11 with i2c LCD display
Temperature And Humidity Sensor Dht 11 With I2C Lcd Display – Youtube
Arduino Temp/Humidity Sensor Using Dht11 And I2C Lcd One Day Project : 4  Steps - Instructables
Arduino Temp/Humidity Sensor Using Dht11 And I2C Lcd One Day Project : 4 Steps – Instructables
Arduino - Temp And Humidity Dht11 + Lcd 1602A - Ky-015 - Hackster.Io
Arduino – Temp And Humidity Dht11 + Lcd 1602A – Ky-015 – Hackster.Io
Measure Temperature/Humidity Using Dht11 + Lcd I2C + Arduino – Surtr  Technology
Measure Temperature/Humidity Using Dht11 + Lcd I2C + Arduino – Surtr Technology
Experiment 3 - How To Interface Dht11 And 12C Lcd Display To Arduino Uno -  Youtube
Experiment 3 – How To Interface Dht11 And 12C Lcd Display To Arduino Uno – Youtube
Arduino Temp/Humidity Sensor Using Dht11 And I2C Lcd One Day Project : 4  Steps - Instructables
Arduino Temp/Humidity Sensor Using Dht11 And I2C Lcd One Day Project : 4 Steps – Instructables
First Steps With The Arduino-Uno R3 And Nano | Maker, Makered, Coding | I2C  Lcd Temp./Humidity Displaying | Edu: Digital Citizenship, Cybersecurity,  Eskills, Modern Edu By Gust Mees
First Steps With The Arduino-Uno R3 And Nano | Maker, Makered, Coding | I2C Lcd Temp./Humidity Displaying | Edu: Digital Citizenship, Cybersecurity, Eskills, Modern Edu By Gust Mees
Dht11 Giao Tiếp Arduino, Cảm Biến Nhiệt Độ, Độ Ẩm + Lcd1602 + Arduino
Dht11 Giao Tiếp Arduino, Cảm Biến Nhiệt Độ, Độ Ẩm + Lcd1602 + Arduino
Temperature Monitor With Dht11 And I2C 20X4 Lcd - Hackster.Io
Temperature Monitor With Dht11 And I2C 20X4 Lcd – Hackster.Io
Hiển Thị Nhiệt Độ, Độ Ẩm Lên Lcd 16X2 Giao Tiếp Bằng I2C Sử Dụng Arduino |  Arduino Kit
Hiển Thị Nhiệt Độ, Độ Ẩm Lên Lcd 16X2 Giao Tiếp Bằng I2C Sử Dụng Arduino | Arduino Kit

See more here: kientrucannam.vn

Leave a Reply

Your email address will not be published. Required fields are marked *