This commit is contained in:
Alex
2019-06-13 22:46:01 +03:00
parent f440172c8f
commit 7a6ae9243b
2 changed files with 2 additions and 5 deletions

View File

@@ -118,7 +118,7 @@ boolean settChanged = false;
void setup() {
ESP.wdtDisable();
ESP.wdtEnable(WDTO_8S);
//ESP.wdtEnable(WDTO_8S);
delay(1000);
// ЛЕНТА
FastLED.addLeds<WS2812B, LED_PIN, COLOR_ORDER>(leds, NUM_LEDS)/*.setCorrection( TypicalLEDStrip )*/;

View File

@@ -2,10 +2,7 @@ uint32_t effTimer;
void effectsTick() {
if (!dawnFlag) {
int thisDelay;
if (currentMode < 5) thisDelay = modes[currentMode].speed;
else thisDelay = 50;
if (ONflag && millis() - effTimer >= thisDelay) {
if (ONflag && millis() - effTimer >= ((currentMode < 5) ? modes[currentMode].speed : 50) ) {
effTimer = millis();
switch (currentMode) {
case 0: sparklesRoutine();