]> git.donarmstrong.com Git - qmk_firmware.git/blob - quantum/template/template.c
Merge remote-tracking branch 'refs/remotes/jackhumbert/master'
[qmk_firmware.git] / quantum / template / template.c
1 #include "%KEYBOARD%.h"
2
3 __attribute__ ((weak))
4 void matrix_init_user(void) {
5         // leave this function blank - it can be defined in a keymap file
6         return NULL;
7 };
8
9 __attribute__ ((weak))
10 void matrix_scan_user(void) {
11         // leave this function blank - it can be defined in a keymap file
12         return NULL;
13 };
14
15 __attribute__ ((weak))
16 void led_set_user(uint8_t usb_led) {
17         // leave this function blank - it can be defined in a keymap file
18         return NULL;
19 };
20
21 void matrix_init_kb(void) {
22         // put your keyboard start-up code here
23         // runs once when the firmware starts up
24         
25         matrix_init_user();
26 };
27
28 void matrix_scan_kb(void) {
29     // put your looping keyboard code here
30     // runs every cycle (a lot)
31
32         matrix_scan_user();
33 };
34
35 void led_set_kb(uint8_t usb_led) {
36         // put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
37
38         led_set_user(usb_led);
39 };