From d283e27bf870aaf24d35720c8eb7f8fc9979562c Mon Sep 17 00:00:00 2001 From: Lostdotfish Date: Wed, 11 Dec 2024 20:29:36 +0000 Subject: [PATCH] [Keymap] Update rp2040_orbweaver (#24704) * Update keymap.c enhancement - power down indicator LEDs when host sleeps * Update keyboards/lostdotfish/rp2040_orbweaver/keymaps/default/keymap.c Co-authored-by: jack * Update keyboards/lostdotfish/rp2040_orbweaver/keymaps/default/keymap.c Co-authored-by: jack --------- Co-authored-by: jack --- .../rp2040_orbweaver/keymaps/default/keymap.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/keyboards/lostdotfish/rp2040_orbweaver/keymaps/default/keymap.c b/keyboards/lostdotfish/rp2040_orbweaver/keymaps/default/keymap.c index f98f656bc9fa..df59752ce0c4 100644 --- a/keyboards/lostdotfish/rp2040_orbweaver/keymaps/default/keymap.c +++ b/keyboards/lostdotfish/rp2040_orbweaver/keymaps/default/keymap.c @@ -76,3 +76,15 @@ layer_state_t layer_state_set_user(layer_state_t state) { } return state; } +void suspend_power_down_kb(void) { + // code will run multiple times while keyboard is suspended + gpio_write_pin_high(GP23); + gpio_write_pin_high(GP24); + gpio_write_pin_high(GP25); + suspend_power_down_user(); +} + +void suspend_wakeup_init_kb(void) { + layer_state_set_kb(layer_state); + suspend_wakeup_init_user(); +}