]> git.donarmstrong.com Git - qmk_firmware.git/blob - keyboards/crkbd/rev1/rev1.c
Merge branch 'master' of github.com:qmk/qmk_firmware into hf/shinydox
[qmk_firmware.git] / keyboards / crkbd / rev1 / rev1.c
1 #include "crkbd.h"
2
3
4 #ifdef AUDIO_ENABLE
5     float tone_startup[][2] = SONG(STARTUP_SOUND);
6     float tone_goodbye[][2] = SONG(GOODBYE_SOUND);
7 #endif
8
9 #ifdef SSD1306OLED
10 void led_set_kb(uint8_t usb_led) {
11     // put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
12     //led_set_user(usb_led);
13 }
14 #endif
15
16 void matrix_init_kb(void) {
17
18     #ifdef AUDIO_ENABLE
19         _delay_ms(20); // gets rid of tick
20         PLAY_SONG(tone_startup);
21     #endif
22
23         matrix_init_user();
24 };
25
26 void shutdown_kb(void) {
27     #ifdef AUDIO_ENABLE
28         PLAY_SONG(tone_goodbye);
29         _delay_ms(150);
30         stop_all_notes();
31     #endif
32 }