Skip to content
This repository was archived by the owner on Mar 1, 2024. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions HyperionRGB/HyperionRGB.ino
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ WrapperJsonServer jsonServer;
#endif

Mode activeMode;
boolean autoswitch;
boolean autoswitch, initDone;

ThreadController threadController = ThreadController();
Thread statusThread = Thread();
Expand Down Expand Up @@ -86,7 +86,7 @@ void changeMode(Mode newMode, int interval = 0) {
animationThread.setInterval(interval);
break;
case HYPERION_UDP:
if (!autoswitch)
if (!autoswitch && initDone)
udpLed.begin();
}
if (interval > 0)
Expand Down Expand Up @@ -190,6 +190,7 @@ void handleEvents(void) {
}

void setup(void) {
initDone = false;
LoggerInit loggerInit = LoggerInit(115200);

initConfig();
Expand Down Expand Up @@ -239,6 +240,7 @@ void setup(void) {

pinMode(LED, OUTPUT); // LED pin as output.
Log.info("HEAP=%i", ESP.getFreeHeap());
initDone = true;
}

void loop(void) {
Expand Down