EnigmaIOT
0.9.8
Secure sensor and gateway platform based on ESP8266 and ESP32
|
This is a basic and straightforward example of an EnigmaIOT node. It only sends a message with mocked values, in addition to input voltage value on ESP8266 and ESP32, and sleeps during 10 seconds.
If you use an ESP8266 you have to connect GPIO16 and RST pins or it will never wake from sleep. You can reset your ESP8266 board manually to force a wake.
It uses CayenneLPP as payload encoding. CayenneLPP is a pretty efficient encoding format. Other examples uses MessagePack that is less efficient but much more versatile. So I recommend using the latter unless you have many values to send that do not fin in the maximum 214 bytes of a single EnigmaIOT message.
In order to adapt it to your needs you only have to modify this code to readout sensor values.
When receiving this message, MQTT Gateway produces this output: