mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-08 16:59:50 +03:00
add back obj_id for HA test
This commit is contained in:
@@ -205,8 +205,9 @@ void Shower::create_ha_discovery() {
|
||||
} else {
|
||||
snprintf(str, sizeof(str), "shower_active"); // v3.4 compatible
|
||||
}
|
||||
doc["uniq_id"] = str;
|
||||
doc["default_entity_id"] = (std::string) "binary_sensor." + str;
|
||||
doc["uniq_id"] = str;
|
||||
doc["obj_id"] = str;
|
||||
doc["def_ent_id"] = (std::string) "binary_sensor." + str;
|
||||
|
||||
snprintf(stat_t, sizeof(stat_t), "%s/shower_active", Mqtt::base().c_str());
|
||||
doc["stat_t"] = stat_t;
|
||||
@@ -223,8 +224,9 @@ void Shower::create_ha_discovery() {
|
||||
|
||||
snprintf(str, sizeof(str), "%s_shower_duration", Mqtt::basename().c_str());
|
||||
|
||||
doc["uniq_id"] = str;
|
||||
doc["default_entity_id"] = (std::string) "sensor." + str;
|
||||
doc["uniq_id"] = str;
|
||||
doc["obj_id"] = str;
|
||||
doc["def_ent_id"] = (std::string) "sensor." + str;
|
||||
|
||||
snprintf(stat_t, sizeof(stat_t), "%s/shower_data", Mqtt::base().c_str());
|
||||
doc["stat_t"] = stat_t;
|
||||
|
||||
Reference in New Issue
Block a user