@@ -68,6 +68,9 @@ uint8_t CctPacketFormatter::getCctStatusButton(uint8_t groupId, MiLightStatus st
if (status == ON) {
switch(groupId) {
+ case 0:
+ button = CCT_ALL_ON;
+ break;
case 1:
button = CCT_GROUP_1_ON;
break;
@@ -83,6 +86,9 @@ uint8_t CctPacketFormatter::getCctStatusButton(uint8_t groupId, MiLightStatus st
}
} else {
+ button = CCT_ALL_OFF;
button = CCT_GROUP_1_OFF;
@@ -96,6 +96,10 @@ void V5MiLightUdpServer::handleCommand(uint8_t command, uint8_t commandArg) {
client->increaseTemperature();
+ case UDP_CCT_NIGHT_MODE:
+ client->enableNightMode();
+
default:
if (!handled) {
Serial.print(F("V5MiLightUdpServer - Unhandled command: "));
@@ -24,6 +24,7 @@ enum MiLightUdpCommands {
UDP_CCT_TEMPERATURE_UP = 0x3E,
UDP_CCT_BRIGHTNESS_DOWN = 0x34,
UDP_CCT_BRIGHTNESS_UP = 0x3C,
+ UDP_CCT_NIGHT_MODE = 0xB9,
UDP_RGBW_ALL_ON = 0x41,
UDP_RGBW_ALL_OFF = 0x42,