Get rid of USB_LED_NUM_LOCK (#21424)

This commit is contained in:
Ryan
2023-07-02 19:35:41 +01:00
committed by GitHub
parent 7ff80a57cb
commit 9ab16e62f7
25 changed files with 91 additions and 133 deletions
@@ -187,8 +187,9 @@ static THD_FUNCTION(LEDthread, arg) {
// initialize persistent variables
pwm_step_status = 4; //full brightness
page_status = 0; //start frame 0 (all off/on)
numlock_status = (host_keyboard_leds() & (1<<USB_LED_NUM_LOCK)) ? 1 : 0;
capslock_status = (host_keyboard_leds() & (1<<USB_LED_CAPS_LOCK)) ? 1 : 0;
led_t led_state = host_keyboard_led_state();
numlock_status = led_state.num_lock ? 1 : 0;
capslock_status = led_state.caps_lock ? 1 : 0;
while(true) {
// wait for a message (asynchronous)