startup reason mqtt notification
This commit is contained in:
@@ -36,6 +36,7 @@ HomieNode sensorLipo("lipo", "Battery Status", "Lipo");
|
||||
HomieNode sensorSolar("solar", "Solar Status", "Solarpanel");
|
||||
HomieNode sensorWater("water", "WaterSensor", "Water");
|
||||
HomieNode sensorTemp("temperature", "Temperature", "temperature");
|
||||
HomieNode startupReason("startupReason", "startupReason", "startupReason");
|
||||
HomieNode stayAlive("stay", "alive", "alive"); /**< Necessary for Mqtt Active Command */
|
||||
|
||||
/* @} */
|
||||
|
18
esp32/include/WakeReason.h
Normal file
18
esp32/include/WakeReason.h
Normal file
@@ -0,0 +1,18 @@
|
||||
#ifndef WAKEUP_REASON_H
|
||||
#define WAKEUP_REASON_H
|
||||
|
||||
#define WAKEUP_REASON_UNDEFINED 0
|
||||
#define WAKEUP_REASON_TEMP1_CHANGE 2
|
||||
#define WAKEUP_REASON_TEMP2_CHANGE 3
|
||||
#define WAKEUP_REASON_BATTERY_CHANGE 4
|
||||
#define WAKEUP_REASON_SOLAR_CHANGE 5
|
||||
#define WAKEUP_REASON_RTC_MISSING 6
|
||||
#define WAKEUP_REASON_TIME_UNSET 7
|
||||
#define WAKEUP_REASON_MODE2_WAKEUP_TIMER 8
|
||||
|
||||
|
||||
#define WAKEUP_REASON_MOIST_CHANGE 20 //20-26
|
||||
#define WAKEUP_REASON_PLANT_DRY 30 //30-36
|
||||
|
||||
|
||||
#endif
|
Reference in New Issue
Block a user