]> git.donarmstrong.com Git - qmk_firmware.git/blobdiff - tmk_core/common/avr/suspend.c
Fixes typos in keycode.txt
[qmk_firmware.git] / tmk_core / common / avr / suspend.c
index c07c2801d5ef75e277ab1b460f0fcac826b13568..8a7272bbc5298612bc935f51116d5e44973cddf2 100644 (file)
@@ -9,10 +9,16 @@
 #include "suspend.h"
 #include "timer.h"
 #include "led.h"
+
 #ifdef PROTOCOL_LUFA
-#include "lufa.h"
+       #include "lufa.h"
 #endif
 
+#ifdef AUDIO_ENABLE
+    #include "audio.h"
+#endif /* AUDIO_ENABLE */
+
+
 
 #define wdt_intr_enable(value)   \
 __asm__ __volatile__ (  \
@@ -72,6 +78,11 @@ static void power_down(uint8_t wdto)
        // Turn off LED indicators
        led_set(0);
 
+       #ifdef AUDIO_ENABLE
+        // This sometimes disables the start-up noise, so it's been disabled
+               // stop_all_notes();
+       #endif /* AUDIO_ENABLE */
+
     // TODO: more power saving
     // See PicoPower application note
     // - I/O port input with pullup
@@ -106,7 +117,7 @@ bool suspend_wakeup_condition(void)
     for (uint8_t r = 0; r < MATRIX_ROWS; r++) {
         if (matrix_get_row(r)) return true;
     }
-    return false;
+     return false;
 }
 
 // run immediately after wakeup
@@ -135,4 +146,3 @@ ISR(WDT_vect)
     }
 }
 #endif
-