Skip to content
Snippets Groups Projects
Commit d98a7cc4 authored by Kevin Pulo's avatar Kevin Pulo
Browse files

keyboard-fw: don't disable WDT during its interrupt handler

parent 1a9c21f6
No related branches found
No related tags found
No related merge requests found
......@@ -342,7 +342,7 @@ void setup_hardware(void)
ISR(WDT_vect)
{
// WDT interrupt enable and flag cleared on entry
wdt_disable(); // Disable watchdog for now
Delay_MS(1);
}
/** Event handler for the library USB Connection event. */
......
......@@ -60,6 +60,7 @@ void keyboard_power_off(void)
sleep_cpu(); // Actually go to sleep
// Zzzzzz
sleep_disable(); // We've woken up
wdt_disable(); // Disable watchdog for now
sei();
// Check if circle key has been pressed (active-low)
// If not reset the watchdog and try again
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment