v5.8.0k - Missed one

Add retain to ENERGY messages controlled by command SensorRetain (#1013)
This commit is contained in:
arendst 2017-10-12 14:38:28 +02:00
parent 60426fca2f
commit 766e05b997
1 changed files with 1 additions and 1 deletions

View File

@ -668,7 +668,7 @@ void hlw_mqttPresent(byte option)
// {"Time":"2017-03-04T13:37:24", "Total":0.013, "Yesterday":0.013, "Today":0.000, "Period":0, "Power":0, "Factor":0.00, "Voltage":0, "Current":0.000} // {"Time":"2017-03-04T13:37:24", "Total":0.013, "Yesterday":0.013, "Today":0.000, "Period":0, "Power":0, "Factor":0.00, "Voltage":0, "Current":0.000}
snprintf_P(mqtt_data, sizeof(mqtt_data), PSTR("{\"" D_TIME "\":\"%s\", "), getDateTime().c_str()); snprintf_P(mqtt_data, sizeof(mqtt_data), PSTR("{\"" D_TIME "\":\"%s\", "), getDateTime().c_str());
hlw_mqttStat(option); hlw_mqttStat(option);
mqtt_publish_topic_P(2, PSTR(D_RSLT_ENERGY)); mqtt_publish_topic_P(2, PSTR(D_RSLT_ENERGY), sysCfg.flag.mqtt_sensor_retain);
} }
void hlw_mqttStatus() void hlw_mqttStatus()