Skip to content

lumang/esp32-DHT11

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ESP32-DHT11

Esp-idf driver for DHT11 temperature and humidity sensor

Install

Use Platformio to install this link
or
Clone this repo inside [esp]/esp-idf/components folder

how to add CMaklists.txt file

link

Minimal Component CMakeLists

How to use

Import dht11.h inside your program, initialize the device with DHT11_init(gpio_num) and then call DHT11_read() whenever you need to read from the DHT11 sensor.
DHT11_read() returns a struct with temperature and humidity and a status code of the operation for error checking.

Check the examples folder for more information.

WARNING: DHT11_read() is a blocking function.

About

Esp-idf driver for DHT11 temperature and humidity sensor 单总线温湿度传感器

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 98.7%
  • Makefile 1.3%