]> git.donarmstrong.com Git - qmk_firmware.git/commitdiff
Examples should all use _user functions for consistency
authorU-LANDSRAAD\drashna <drashna@live.com>
Mon, 5 Mar 2018 15:59:27 +0000 (07:59 -0800)
committerJack Humbert <jack.humb@gmail.com>
Wed, 7 Mar 2018 22:05:38 +0000 (17:05 -0500)
docs/custom_quantum_functions.md

index e7a45e0bfd3718b487384d6a9b3338329a04ed65..ab3a72e5d384c3dbba360087a68c1f6a421e1d3c 100644 (file)
@@ -98,10 +98,10 @@ This allows you to control the 5 LED's defined as part of the USB Keyboard spec.
 * `USB_LED_COMPOSE`
 * `USB_LED_KANA`
 
-### Example `led_set_kb()` Implementation
+### Example `led_set_user()` Implementation
 
 ```
-void led_set_kb(uint8_t usb_led) {
+void led_set_user(uint8_t usb_led) {
     if (usb_led & (1<<USB_LED_NUM_LOCK)) {
         PORTB |= (1<<0);
     } else {
@@ -144,9 +144,8 @@ Before a keyboard can be used the hardware must be initialized. QMK handles init
 This example, at the keyboard level, sets up B1, B2, and B3 as LED pins.
 
 ```
-void matrix_init_kb(void) {
+void matrix_init_user(void) {
   // Call the keymap level matrix init.
-  matrix_init_user();
 
   // Set our LED pins as output
   DDRB |= (1<<1);
@@ -176,3 +175,5 @@ This example has been deliberately omitted. You should understand enough about Q
 This function gets called at every matrix scan, which is basically as often as the MCU can handle. Be careful what you put here, as it will get run a lot.
 
 You should use this function if you need custom matrix scanning code. It can also be used for custom status output (such as LED's or a display) or other functionality that you want to trigger regularly even when the user isn't typing.
+
+