esp8266, mqtt acquisition of temperature and humidity

Use esp8266-01s, and transmission sensors mqtt DHT11 acquired temperature and humidity value
very much, this application is also very useful

DHT11

DHT11 is a temperature and humidity sensors, can be used to test environmental temperature and humidity, the sensor temperature measuring range is 0 ~ 50 ° C, an error of 2 ° C; humidity measuring range at 30% @ 0 ° C -90 % RH, ambient temperature of 25 ° C, humidity measuring range of 20% -90% RH, at 50 ° C, measuring range of 20% -80%.

Pin The corresponding interface
VCC 5V
de Single serial data bus (any one IO)
GND Negative ground

arduino IDE configuration
in project management load library library search download dht DHT sensor by Adafruit (1.30)
enter description here
search adafruit unifi download A large fruit Unified Sensor (1.02) After installing
enter description here
and then you can go to test temperature and humidity module

Use esp module

Esp8266-01s module can
use to transmit data GPIO2

Connecting circuit

3.3v power source vcc and ground en
GPIO2 dht11 output signal to the
GND Ground

Students may be less likely to refer to the study
esp8266 mqtt use arduino development

http://niehen.cn/esp8266/esp8266-mqtt-%e4%bd%bf%e7%94%a8arduino%e5%bc%80%e5%8f%91%e6%95%99%e7%a8%8b/

esp8266-01s use Description

http://niehen.cn/esp8266/esp8266-01s%e4%bb%8b%e7%bb%8d/

Refer https://www.bilibili.com/video/av23531283/

Item reference code links

GitHub address

More tutorials

ESP developers learn the basics

Including an understanding of the basics esp modules awareness and understanding mqtt agreement, arduino IDE application code is written, and so on.

  1. arduino based learning
  2. Introduction esp Series Modules
  3. Introduction and use mqtt agreement
  4. Using mqtt esp module arduino IDE Development Methodology
  5. AT command esp brush firmware module
  6. esp module using sleep mode
  7. esp8266-01s introduction and use
  8. esp8266-12f introduction and use
  9. NodeMcu introduction and use
esp development of IOT applications

Based modules and other modules esp8266 application scenario according to an actual production and demand of Things

  1. FRID access control systems FRID arduino relay electromagnetic lock-based development
  2. esp32-cam video stream acquired image processing
  3. Stepping motor esp8266 mqtt developed automatic curtain control
  4. Gets indoor temperature and humidity based on DHT11 Esp8266 mqtt
  5. Gets indoor air quality based on CCS811 esp8266 mqtt
  6. Based on infrared remote control intelligent module esp8266 mqtt development
  7. Based ws2812 esp8266 mqtt development of intelligent multi-level lighting
  8. Based ws2812 esp8266 mqtt development of intelligent multi-mode light atmosphere
  9. Broadcast System Intelligent Voice mp3player esp8266 mqtt based development
  10. The wisdom of the comprehensive application of IOT classroom project development
Published 46 original articles · won praise 59 · views 70000 +

Guess you like

Origin blog.csdn.net/Nirvana_6174/article/details/104683764