This controller is the heart of my new wateringsystem.
- Monitoring weather data (temperature, humidity and air pressure)
- Monitoring th soil moisture of the plant
- Monitoring of energy consumption
- super long deepsleep times to save energy
- easy to configurable with the help of Node-RED
- Controllable via MQTT
- widely-used sensors
- completly asynchron programming
- host by your own: complete control over your data (no external cloud service needed)
- OTA updates
- connect all parts to the ESP32
- connect power
- the ESP32 starting an own Wifi access point named "wateringsystem-{device ID}"
- connect to this Wifi with your smartphone
- use
waaatering
for Wifi password - you will redirected to a config page
- insert your Wifi and MQTT broker credentials
- click on "save"
- the ESP32 will restarting and connect to your MQTT broker
- after about 1 minute you should see a new topic in your MQTT broker
wateringsystem/{device ID}/out/info
with a lot of information in the payload
The whole module is controllable via MQTT protocol. So it's easy to integrate in existing SmartHome systems (like Home Assistant or Node-Red).
Topic: wateringsystem/{device ID}
/in/{command}
command | description | payload |
---|---|---|
watering | Start watering for specific duration (in milliseconds!) | { duration: number } |
abort-watering | Abort watering before timer ends | - |
sleep | Start deep-sleep for specific duration (in milliseconds!) | { duration: number } |
info | Send info via MQTT topic wateringsystem/out/info package |
- |
hard-reset | Reset config with WiFi and MQTT settings and start internal hotspot to reconfigure device. | - |
Topic: wateringsystem/{device ID}
/out/{command}
command | description | payload |
---|---|---|
info | status info | complex JSON. See "info-state" chapter |
sleep | was send if sytem enter deep-sleep | { duration: number } |
wakeup | was send if sytem wakeup from deep-sleep | reason "timer" |
field | description | type |
---|---|---|
version | version number of module firmware | string |
soilMoisture | analog value of soil-moisture sensor | number |
system.deviceId | Unique ID of the device. Will used also in MQTT topics. | string |
system.freeHeap | free heap memory of CPU | number |
energy.shuntVoltage | voltage between V- and V+ (in mV) | number |
energy.busVoltage | voltage of power input pin (in V) (optimal value between 3.6 and 4.0) | number |
energy.current | current (in mA) | number |
energy.power | energy consumption (in mW) | number |
energy.loadVoltage | load voltage (in V) | number |
network.wifiRssi | wifi signal strength (RSSI) | number |
network.wifiQuality | quality of signal strength (value between 0 and 100%) | number |
network.wifiSsid | SSID of connected wifi | string |
network.ip | ip address of the module | string |
- buy sensor and ESP32
- soldering first prototype of the sketch
- test firmware
- test OTA updates
- create housing (3D print)
- create example flow with Node-RED
- add part list
- add video doc
- add WifiManager to easy setup