2 #include <util/delay.h>
4 #include <avr/interrupt.h>
10 static void hw_setup()
27 set_sleep_mode(SLEEP_MODE_IDLE);
31 static void hw_suspend()
48 set_sleep_mode(SLEEP_MODE_PWR_DOWN);
58 // allow wakeup by long button-press only
59 } while (!buttons_wait_for_release());
61 // ok, so I will wake up
70 power_usi_disable(); // Once for lifetime
71 ACSR |= _BV(ACD); // disable analog comparator
76 // power_down(); - not while still debugging