B-
b-abel/ESP8266-Sensors-to-Hono
ESP8266 sends sensor data to Hono
ESP8266 Sensors to Hono
This project sends temperature and humidity with MQTT
to Eclipse Hono.
Prerequisites
- WiFi
- Running Hono instance with
MQTT Adapter
Hardware
- ESP8266-12
(tested with ESP12E DevKit V2) - DHT22 sensor for temperature and humidity on Pin 2
(wiring)
Firmware
NodeMCU 2.0.0 custom build
(created by https://nodemcu-build.com/,
build provides integer and float version, use float)
with modules: cjson,dht,file,gpio,http,mqtt,net,node,tmr,uart,wifi.
See the NodeMCU documentation for information about the modules as well as building and flashing the firmware.
IDE
- e.g.: ESPlorer - includes a serial terminal. Might require drivers for the board (MacOS, Win, Linux should work). Set Baud rate to 115200.
Configure
Configure in file config.lua.
Usage
Flash, configure and start the device.
It will register itself at Hono as "esp8266.MAC-address".