diff options
author | Ryan <fauxpark@gmail.com> | 2020-10-29 06:14:11 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-29 06:14:11 +1100 |
commit | 1d85fe176a12c31c959865fa78f340e090fff587 (patch) | |
tree | 8f061c05d9c4b32e227d00275a385026672380be /keyboards/vn66/vn66.c | |
parent | a42e3ba2cb4a3520ed7e7691288694f3795321c4 (diff) |
VN66 refactor (#10776)
Diffstat (limited to 'keyboards/vn66/vn66.c')
-rw-r--r-- | keyboards/vn66/vn66.c | 24 |
1 files changed, 11 insertions, 13 deletions
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 <http://www.gnu.org/licenses/>. */ + #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; } |