write button mode change to log
This commit is contained in:
parent
d2c3ac00cc
commit
7797090f30
|
@ -418,9 +418,19 @@ void readADC() {
|
||||||
|
|
||||||
|
|
||||||
if (digitalRead(PIN_MODE_SWITCH)) { //pushed in, also high if cable got disconnected
|
if (digitalRead(PIN_MODE_SWITCH)) { //pushed in, also high if cable got disconnected
|
||||||
speedmode=SPEEDMODE_SLOW;
|
if (speedmode!=SPEEDMODE_SLOW) {
|
||||||
|
speedmode=SPEEDMODE_SLOW;
|
||||||
|
if (loopmillis>WRITE_HEADER_TIME) {
|
||||||
|
writeLogComment(Serial1,loopmillis, "Mode switched to SPEEDMODE_SLOW");
|
||||||
|
}
|
||||||
|
}
|
||||||
}else{ //button not pushed in
|
}else{ //button not pushed in
|
||||||
speedmode=SPEEDMODE_NORMAL;
|
if (speedmode!=SPEEDMODE_NORMAL) {
|
||||||
|
speedmode=SPEEDMODE_NORMAL;
|
||||||
|
if (loopmillis>WRITE_HEADER_TIME) {
|
||||||
|
writeLogComment(Serial1,loopmillis, "Mode switched to SPEEDMODE_NORMAL");
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue