Refactor callMode (#702)

This commit is contained in:
Def3nder
2020-02-22 16:17:32 +01:00
committed by GitHub
parent c1a8fde9a0
commit 1a4061fdb5
15 changed files with 114 additions and 106 deletions

View File

@@ -47,7 +47,7 @@ void userLoop()
if (millis() + strip.timebase > (cycleTime - 25)) { //wipe complete
effectCurrent = FX_MODE_STATIC;
timeStaticStart = millis();
colorUpdated(3);
colorUpdated(NOTIFIER_CALL_MODE_NOTIFICATION);
wipeState = 2;
}
} else if (wipeState == 2) { //static
@@ -59,7 +59,7 @@ void userLoop()
#ifdef STAIRCASE_WIPE_OFF
effectCurrent = FX_MODE_COLOR_WIPE;
strip.timebase = 360 + (255 - effectSpeed)*75 - millis(); //make sure wipe starts fully lit
colorUpdated(3);
colorUpdated(NOTIFIER_CALL_MODE_NOTIFICATION);
wipeState = 4;
#else
turnOff();
@@ -93,7 +93,7 @@ void startWipe()
bool doReverse = (userVar0 == 2);
seg.setOption(1, doReverse);
colorUpdated(3);
colorUpdated(NOTIFIER_CALL_MODE_NOTIFICATION);
}
void turnOff()
@@ -104,7 +104,7 @@ void turnOff()
transitionDelayTemp = 4000; //fade out slowly
#endif
bri = 0;
colorUpdated(3);
colorUpdated(NOTIFIER_CALL_MODE_NOTIFICATION);
wipeState = 0;
userVar0 = 0;
previousUserVar0 = 0;