Fix for segment on/off transitions.

Fix for missing return.
Slightly smoother Chunchun, added Speed parameter for Hiphotic.
This commit is contained in:
Blaz Kristan
2022-08-23 16:00:50 +02:00
parent 89f334e67b
commit a7dbfc4954
7 changed files with 28 additions and 23 deletions

View File

@@ -197,10 +197,10 @@ void handleAnalog(uint8_t b)
// otherwise use "double press" for segment selection
Segment& seg = strip.getSegment(macroDoublePress[b]);
if (aRead == 0) {
seg.on = false; // off
seg.setOption(SEG_OPTION_ON, false); // off (use transition)
} else {
seg.setOpacity(aRead);
seg.on = true;
seg.setOption(SEG_OPTION_ON, true); // on (use transition)
}
// this will notify clients of update (websockets,mqtt,etc)
updateInterfaces(CALL_MODE_BUTTON);