summaryrefslogtreecommitdiff
path: root/tmk_core/common.mk
diff options
context:
space:
mode:
authorAlex Ong <alex.ong@unsw.edu.au>2018-08-29 10:19:36 +1000
committerAlex Ong <alex.ong@unsw.edu.au>2018-08-29 10:19:36 +1000
commit3cf7f7322c24e3cab21d402f1a859b60df857603 (patch)
tree08e5f119b2faa8c393dbbad7c085fe83728046c3 /tmk_core/common.mk
parent9bd6d6112d698ea5823b268983809fe3b8d98b26 (diff)
Removed "debounce_algo = manual" in all keyboards with CUSTOM_MATRIX = yes.
Diffstat (limited to 'tmk_core/common.mk')
-rw-r--r--tmk_core/common.mk17
1 files changed, 16 insertions, 1 deletions
diff --git a/tmk_core/common.mk b/tmk_core/common.mk
index 3e407f1573..72b2d3cc86 100644
--- a/tmk_core/common.mk
+++ b/tmk_core/common.mk
@@ -1,4 +1,5 @@
COMMON_DIR = common
+DEBOUNCE = $(COMMON_DIR)/debounce
ifeq ($(PLATFORM),AVR)
PLATFORM_COMMON_DIR = $(COMMON_DIR)/avr
else ifeq ($(PLATFORM),CHIBIOS)
@@ -9,6 +10,7 @@ endif
TMK_COMMON_SRC += $(COMMON_DIR)/host.c \
$(COMMON_DIR)/keyboard.c \
+ $(COMMON_DIR)/debounce.c \
$(COMMON_DIR)/action.c \
$(COMMON_DIR)/action_tapping.c \
$(COMMON_DIR)/action_macro.c \
@@ -39,7 +41,20 @@ ifeq ($(PLATFORM),TEST)
TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/eeprom.c
endif
-
+# Debounce Modules. If implemented in matrix.c, don't use these.
+ifeq ($(strip $(CUSTOM_MATRIX)), yes)
+ # Do nothing. Custom matrix code.
+else ifeq ($(strip $(SPLIT_KEYBOARD)), yes)
+ # Do nothing, debouncing is inside matrix.c inside split_common
+else ifeq ($(strip $(DEBOUNCE_ALGO)), manual)
+ # Do nothing. do your debouncing in matrix.c
+else ifeq ($(strip $(DEBOUNCE_ALGO)), sym_g)
+ TMK_COMMON_SRC += $(DEBOUNCE)/debounce_sym_g.c
+else ifeq ($(strip $(DEBOUNCE_ALGO)), eager_pk)
+ TMK_COMMON_SRC += $(DEBOUNCE)/debounce_eager_pk.c
+else # default algorithm
+ TMK_COMMON_SRC += $(DEBOUNCE)/debounce_sym_g.c
+endif
# Option modules
ifeq ($(strip $(BOOTMAGIC_ENABLE)), yes)