Encoder button fix. Current code works
This commit is contained in:
parent
d47dcdf828
commit
4e279f1e8c
1 changed files with 5 additions and 1 deletions
|
@ -107,10 +107,14 @@ void loop() {
|
||||||
Serial.println("E2Btn State Change");
|
Serial.println("E2Btn State Change");
|
||||||
E2Btn = !E2Btn;
|
E2Btn = !E2Btn;
|
||||||
E2Bounce = DebounceTime;
|
E2Bounce = DebounceTime;
|
||||||
E1Click = true;
|
E2Click = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//false click handler
|
||||||
|
E1Click = false;
|
||||||
|
E2Click = false;
|
||||||
|
|
||||||
bool newCD = digitalRead(ClockDetect);
|
bool newCD = digitalRead(ClockDetect);
|
||||||
|
|
||||||
if (newCD != CDPrev){
|
if (newCD != CDPrev){
|
||||||
|
|
Loading…
Reference in a new issue