diff --git a/src/httpserver/hass.c b/src/httpserver/hass.c index c5da34281..e840d6b24 100644 --- a/src/httpserver/hass.c +++ b/src/httpserver/hass.c @@ -282,6 +282,12 @@ HassDeviceInfo* hass_init_light_device_info(ENTITY_TYPE type) { cJSON_AddStringToObject(info->root, "clr_temp_cmd_t", g_hassBuffer); //color_temp_command_topic cJSON_AddStringToObject(info->root, "clr_temp_stat_t", "~/led_temperature/get"); //color_temp_state_topic + + sprintf(g_hassBuffer, "%.0f", led_temperature_min); + cJSON_AddStringToObject(info->root, "min_mirs", g_hassBuffer); //min_mireds + + sprintf(g_hassBuffer, "%.0f", led_temperature_max); + cJSON_AddStringToObject(info->root, "max_mirs", g_hassBuffer); //max_mireds } cJSON_AddStringToObject(info->root, STATE_TOPIC_KEY, "~/led_enableAll/get"); //state_topic diff --git a/src/httpserver/hass.h b/src/httpserver/hass.h index 9529c8e0b..c5bf079c2 100644 --- a/src/httpserver/hass.h +++ b/src/httpserver/hass.h @@ -3,6 +3,7 @@ #include "../cJSON/cJSON.h" #include "../new_pins.h" #include "../mqtt/new_mqtt.h" +#include "../cmnds/cmd_public.h" typedef enum { /// @brief Switch