From 2f274399f317aa05afb08515ef2902a1c28df182 Mon Sep 17 00:00:00 2001 From: Frank Date: Mon, 13 Mar 2023 19:13:46 +0100 Subject: [PATCH] UM rotary bugfix fixing a crash that was caused by calling updateInterfaces() too often. --- .../usermod_v2_rotary_encoder_ui_ALT.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/usermods/usermod_v2_rotary_encoder_ui_ALT/usermod_v2_rotary_encoder_ui_ALT.h b/usermods/usermod_v2_rotary_encoder_ui_ALT/usermod_v2_rotary_encoder_ui_ALT.h index 59f1ccaa..96539658 100644 --- a/usermods/usermod_v2_rotary_encoder_ui_ALT/usermod_v2_rotary_encoder_ui_ALT.h +++ b/usermods/usermod_v2_rotary_encoder_ui_ALT/usermod_v2_rotary_encoder_ui_ALT.h @@ -514,7 +514,8 @@ public: // 6: fx changed 7: hue 8: preset cycle 9: blynk 10: alexa //setValuesFromFirstSelectedSeg(); //to make transition work on main segment (should no longer be required) stateUpdated(CALL_MODE_BUTTON); - updateInterfaces(CALL_MODE_BUTTON); + if ((millis() - lastInterfaceUpdate) > INTERFACE_UPDATE_COOLDOWN) // WLEDMM respect cooldown times, to avoid crash in AsyncWebSocketMessageBuffer + updateInterfaces(CALL_MODE_BUTTON); } void changeBrightness(bool increase) {