application: minor, use proper wait
This commit is contained in:
parent
44c75a70a2
commit
f1168608c7
|
@ -414,9 +414,7 @@ void main(void)
|
|||
action = true; // action has been performed
|
||||
puts("button pressed\n");
|
||||
led_toggle(); // toggle LED
|
||||
for (uint32_t i = 0; i < 1000000; i++) { // wait a bit to remove noise and double trigger
|
||||
__asm__("nop");
|
||||
}
|
||||
sleep_ms(100); // wait a bit to remove noise and double trigger
|
||||
button_flag = false; // reset flag
|
||||
}
|
||||
if (rtc_internal_tick_flag) { // the internal RTC ticked
|
||||
|
|
Loading…
Reference in New Issue