change Handler1 to get_input only with 1/10 skip for serial

pico-v0.39
alanbjohnston 3 years ago committed by GitHub
parent 64c9a0af55
commit c2e9a5d526
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -341,7 +341,7 @@ void loop() {
} }
bool TimerHandler1(struct repeating_timer *t) { bool TimerHandler1(struct repeating_timer *t) {
/*
if (((skip++)%10) == 0) if (((skip++)%10) == 0)
serial_input(); serial_input();
@ -353,6 +353,8 @@ bool TimerHandler1(struct repeating_timer *t) {
// if (wifi) // if (wifi)
// check_for_browser(); // check_for_browser();
*/
get_input();
return(true); return(true);
} }
@ -4954,8 +4956,9 @@ void start_clockgen() {
} }
void get_input() { void get_input() {
serial_input(); if (((skip++)%10) == 0)
serial_input();
// check for button press // check for button press
if (digitalRead(MAIN_PB_PIN) == PRESSED) // pushbutton is pressed if (digitalRead(MAIN_PB_PIN) == PRESSED) // pushbutton is pressed

Loading…
Cancel
Save

Powered by TurnKey Linux.