Browse Source

MQTT: send mired if cct in use (#1742)

master
copyrights 5 years ago
committed by Max Prokhorov
parent
commit
21b0ac04df
1 changed files with 8 additions and 4 deletions
  1. +8
    -4
      code/espurna/light.ino

+ 8
- 4
code/espurna/light.ino View File

@ -665,10 +665,14 @@ void lightMQTT() {
_toHSV(buffer, sizeof(buffer), true); _toHSV(buffer, sizeof(buffer), true);
mqttSend(MQTT_TOPIC_COLOR_HSV, buffer); mqttSend(MQTT_TOPIC_COLOR_HSV, buffer);
// Mireds
snprintf_P(buffer, sizeof(buffer), PSTR("%d"), _light_mireds);
mqttSend(MQTT_TOPIC_MIRED, buffer);
}
if (_light_has_color || _light_use_cct) {
// Mireds
snprintf_P(buffer, sizeof(buffer), PSTR("%d"), _light_mireds);
mqttSend(MQTT_TOPIC_MIRED, buffer);
} }
// Channels // Channels


Loading…
Cancel
Save