Skip to content

Commit

Permalink
cantor: fix LT(layer, kc) do not work after waking up PC qmk#16406
Browse files Browse the repository at this point in the history
Refactor of the orignal Philong's workaround. Instead of a user function
in the keymap this commit applies the workarund at the keyboard level
to make it available to every cantor user.

Co-authored-by: Philong <philong@users.noreply.github.com>
  • Loading branch information
nolith and philong committed Mar 21, 2023
1 parent b6a636d commit 5d4883d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
11 changes: 11 additions & 0 deletions keyboards/cantor/cantor.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// Copyright 2023 Alessio Caiazza (@nolith)
// SPDX-License-Identifier: GPL-2.0-or-later

#include "quantum.h"

// Workaround for https://github.com/qmk/qmk_firmware/issues/16406
__attribute__ ((weak))
void suspend_wakeup_init_kb(void) {
NVIC_SystemReset();
suspend_wakeup_init_user();
}
2 changes: 2 additions & 0 deletions keyboards/cantor/rules.mk
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
SPLIT_KEYBOARD = yes
SERIAL_DRIVER = usart

SRC += cantor.c

0 comments on commit 5d4883d

Please sign in to comment.