summaryrefslogtreecommitdiffstats
path: root/keyboards/handwired/arrow_pad
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/handwired/arrow_pad')
-rw-r--r--keyboards/handwired/arrow_pad/keymaps/default/keymap.c7
-rw-r--r--keyboards/handwired/arrow_pad/keymaps/pad_21/keymap.c7
-rw-r--r--keyboards/handwired/arrow_pad/keymaps/pad_24/keymap.c7
3 files changed, 12 insertions, 9 deletions
diff --git a/keyboards/handwired/arrow_pad/keymaps/default/keymap.c b/keyboards/handwired/arrow_pad/keymaps/default/keymap.c
index cecaefe80d..820851f803 100644
--- a/keyboards/handwired/arrow_pad/keymaps/default/keymap.c
+++ b/keyboards/handwired/arrow_pad/keymaps/default/keymap.c
@@ -96,9 +96,9 @@ bool process_record_user(uint16_t keycode, keyrecord_t * record) {
return true;
}
-void led_set_user(uint8_t usb_led)
+bool led_update_user(led_t led_state)
{
- if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
+ if (led_state.caps_lock) {
// output high
DDRD |= (1<<6);
PORTD |= (1<<6);
@@ -107,7 +107,7 @@ void led_set_user(uint8_t usb_led)
DDRD &= ~(1<<6);
PORTD &= ~(1<<6);
}
- if (usb_led & (1<<USB_LED_NUM_LOCK)) {
+ if (led_state.num_lock) {
// output low
DDRC |= (1<<7);
PORTC |= ~(1<<7);
@@ -116,4 +116,5 @@ void led_set_user(uint8_t usb_led)
DDRC &= ~(1<<7);
PORTC &= ~(1<<7);
}
+ return false;
}
diff --git a/keyboards/handwired/arrow_pad/keymaps/pad_21/keymap.c b/keyboards/handwired/arrow_pad/keymaps/pad_21/keymap.c
index cf291c00cf..c3ab462ce3 100644
--- a/keyboards/handwired/arrow_pad/keymaps/pad_21/keymap.c
+++ b/keyboards/handwired/arrow_pad/keymaps/pad_21/keymap.c
@@ -109,9 +109,9 @@ bool process_record_user(uint16_t keycode, keyrecord_t * record) {
return true;
}
-void led_set_user(uint8_t usb_led)
+bool led_update_user(led_t led_state)
{
- if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
+ if (led_state.caps_lock) {
// output high
DDRD |= (1<<6);
PORTD |= (1<<6);
@@ -120,7 +120,7 @@ void led_set_user(uint8_t usb_led)
DDRD &= ~(1<<6);
PORTD &= ~(1<<6);
}
- if (usb_led & (1<<USB_LED_NUM_LOCK)) {
+ if (led_state.num_lock) {
// output low
DDRC |= (1<<7);
PORTC |= ~(1<<7);
@@ -129,4 +129,5 @@ void led_set_user(uint8_t usb_led)
DDRC &= ~(1<<7);
PORTC &= ~(1<<7);
}
+ return false;
}
diff --git a/keyboards/handwired/arrow_pad/keymaps/pad_24/keymap.c b/keyboards/handwired/arrow_pad/keymaps/pad_24/keymap.c
index b69d49b7e5..fc044a0e1a 100644
--- a/keyboards/handwired/arrow_pad/keymaps/pad_24/keymap.c
+++ b/keyboards/handwired/arrow_pad/keymaps/pad_24/keymap.c
@@ -96,9 +96,9 @@ bool process_record_user(uint16_t keycode, keyrecord_t * record) {
return true;
}
-void led_set_user(uint8_t usb_led)
+bool led_update_user(led_t led_state)
{
- if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
+ if (led_state.caps_lock) {
// output high
DDRD |= (1<<6);
PORTD |= (1<<6);
@@ -107,7 +107,7 @@ void led_set_user(uint8_t usb_led)
DDRD &= ~(1<<6);
PORTD &= ~(1<<6);
}
- if (usb_led & (1<<USB_LED_NUM_LOCK)) {
+ if (led_state.num_lock) {
// output low
DDRC |= (1<<7);
PORTC |= ~(1<<7);
@@ -116,4 +116,5 @@ void led_set_user(uint8_t usb_led)
DDRC &= ~(1<<7);
PORTC &= ~(1<<7);
}
+ return false;
}