Sfoglia il codice sorgente

fix color command in RGB

Chris Mullins 8 anni fa
parent
commit
7fde23feae
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      lib/MiLight/RgbPacketFormatter.cpp

+ 1 - 1
lib/MiLight/RgbPacketFormatter.cpp

@@ -38,8 +38,8 @@ void RgbPacketFormatter::updateHue(uint16_t value) {
 }
 
 void RgbPacketFormatter::updateColorRaw(uint8_t value) {
-  currentPacket[RGB_COLOR_INDEX] = value;
   command(0, 0);
+  currentPacket[RGB_COLOR_INDEX] = value;
 }
 
 void RgbPacketFormatter::updateBrightness(uint8_t value) {