https://github.com/edjopato/esp-mqtt-dht
A NodeMCU with a DHT Temperature Sensor sending data over MQTT
https://github.com/edjopato/esp-mqtt-dht
dht-sensor dht-temperature-sensors dht11 dht22 mqtt-smarthome nodemcu-arduino nodemcu-sensor-mqtt
Last synced: 28 days ago
JSON representation
A NodeMCU with a DHT Temperature Sensor sending data over MQTT
- Host: GitHub
- URL: https://github.com/edjopato/esp-mqtt-dht
- Owner: EdJoPaTo
- License: mit
- Created: 2018-08-26T22:50:49.000Z (over 6 years ago)
- Default Branch: main
- Last Pushed: 2024-03-05T14:32:27.000Z (about 1 year ago)
- Last Synced: 2025-02-05T07:13:42.248Z (3 months ago)
- Topics: dht-sensor, dht-temperature-sensors, dht11, dht22, mqtt-smarthome, nodemcu-arduino, nodemcu-sensor-mqtt
- Language: C++
- Size: 90.8 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ESP MQTT DHT
This is the script for my [mqtt-smarthome](https://github.com/mqtt-smarthome/mqtt-smarthome) based Temperature Sensors (DHT22).
It is running on a NodeMCU board (ESP8266).The basic source code was inspired by this [repo](https://github.com/titusece/ESP8266-MQTT-Publish-DHT11)
## Installation
In order to build this the Arduino tool was used.
### MQTT Server
As an MQTT server I use a Raspberry Pi with `mosquitto`.
It is in the Debian repository (which includes Raspberry Pi OS) and can easily be installed: `sudo apt install mosquitto`.Make sure to allow anonymous (and enable the default listener on 1883 if you also want web socket support)
```conf
listener 1883allow_anonymous true
```### Prepare Arduino
Set the following under File → Preferences → Settings → Additional Board Manager Urls (hit the rightmost button to open the Window):
```plaintext
https://arduino.esp8266.com/stable/package_esp8266com_index.json
https://dl.espressif.com/dl/package_esp32_index.json
```Next Steps… TODO