Multi Inputs, No actions

This commit is contained in:
Laurent Claude 2025-06-16 08:05:03 +02:00
parent 1a87cd09f1
commit 7a8a650dc2

View File

@ -91,12 +91,12 @@ void setup() {
// Main loop // Main loop
// ------------- // -------------
void loop() { void loop() {
if (!digitalRead(PinInput0)) { todo = fctinput0; } if ((!digitalRead(PinInput0)) & (fctinput0 !="")) { todo = fctinput0; }
if (!digitalRead(PinInput1)) { todo = fctinput1; } if ((!digitalRead(PinInput1)) & (fctinput1 !="")) { todo = fctinput1; }
if (!digitalRead(PinInput2)) { todo = fctinput2; } if ((!digitalRead(PinInput2)) & (fctinput2 !="")) { todo = fctinput2; }
if (!digitalRead(PinInput3)) { todo = fctinput3; } if ((!digitalRead(PinInput3)) & (fctinput3 !="")) { todo = fctinput3; }
if ((todo != "") & (millis() > debouncetime + 100)) { if ((todo != "") & (millis() > debouncetime + 75)) {
digitalWrite(LedMoozy, true); // for debug digitalWrite(LedMoozy, true); // for debug
if ((todo =="LC") & (!doNotRepeat)) {doNotRepeat = true; dolc(); } if ((todo =="LC") & (!doNotRepeat)) {doNotRepeat = true; dolc(); }
if ((todo =="LCD") & (!doNotRepeat)) {doNotRepeat = true; dolcd(); } if ((todo =="LCD") & (!doNotRepeat)) {doNotRepeat = true; dolcd(); }