From 1d85fe176a12c31c959865fa78f340e090fff587 Mon Sep 17 00:00:00 2001 From: Ryan Date: Thu, 29 Oct 2020 06:14:11 +1100 Subject: VN66 refactor (#10776) --- keyboards/vn66/vn66.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) (limited to 'keyboards/vn66/vn66.c') diff --git a/keyboards/vn66/vn66.c b/keyboards/vn66/vn66.c index 122047468c..77fe23aefe 100644 --- a/keyboards/vn66/vn66.c +++ b/keyboards/vn66/vn66.c @@ -13,24 +13,22 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ + #include "vn66.h" void matrix_init_kb(void) { - led_init_ports(); - matrix_init_user(); -}; + led_init_ports(); + matrix_init_user(); +} void led_init_ports(void) { - setPinOutput(E6); + setPinOutput(E6); } -void led_set_kb(uint8_t usb_led) { - if (IS_LED_ON(usb_led, USB_LED_CAPS_LOCK)) { - // Turn Caps Lock LED on - writePinLow(E6); - } else { - // Turn Caps Lock LED off - writePinHigh(E6); - } - led_set_user(usb_led); +bool led_update_kb(led_t led_state) { + if (led_update_user(led_state)) { + writePin(E6, !led_state.caps_lock); + } + + return true; } -- cgit v1.2.3