We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cf20c80 commit cf2f378Copy full SHA for cf2f378
usermods/multi_relay/usermod_multi_relay.h
@@ -496,10 +496,10 @@ void MultiRelay::setup() {
496
* loop() is called continuously. Here you can check for events, read sensors, etc.
497
*/
498
void MultiRelay::loop() {
499
+ static unsigned long lastUpdate = 0;
500
yield();
- if (!enabled || strip.isUpdating()) return;
501
+ if (!enabled || (strip.isUpdating() && millis() - lastUpdate < 100)) return;
502
- static unsigned long lastUpdate = 0;
503
if (millis() - lastUpdate < 100) return; // update only 10 times/s
504
lastUpdate = millis();
505
0 commit comments