]> git.donarmstrong.com Git - qmk_firmware.git/commitdiff
[Keyboard] Update e65.c to fix Caps Lock indicator (#7405)
authortrinity1561 <47289299+trinity1561@users.noreply.github.com>
Wed, 20 Nov 2019 21:11:00 +0000 (16:11 -0500)
committerDrashna Jaelre <drashna@live.com>
Wed, 20 Nov 2019 21:10:59 +0000 (13:10 -0800)
* Update e65.c

Fixing Caps Lock LED indicator

* Update e65.c

Using new LED functions (led_update_kb)

keyboards/exclusive/e65/e65.c

index e3dab383071df4bdf73c21947945f0d2920c07e7..e01a0614c52967bd2fb16ed8a2d27a15014be5a2 100644 (file)
 #include "e65.h"
 
 void matrix_init_kb(void) {
-    setPinOutput(B6);
+    // put your keyboard start-up code here
+    // runs once when the firmware starts up
+
     matrix_init_user();
+    led_init_ports();
+}
+
+void led_init_ports(void) {
+    setPinOutput(B6);
+    writePinHigh(B6);
 }
 
-void led_set_kb(uint8_t usb_led) {
-    if (IS_LED_ON(usb_led, USB_LED_CAPS_LOCK)) {
-        writePinHigh(B6);
-    } else {
-        writePinLow(B6);
+bool led_update_kb(led_t led_state) {
+    if(led_update_user(led_state)) {
+        writePin(B6, !led_state.caps_lock);
     }
 
-    led_set_user(usb_led);
+    return true;
 }