summaryrefslogtreecommitdiffstats
path: root/tmk_core
diff options
context:
space:
mode:
authorAlex Ong <the.onga@gmail.com>2019-01-04 19:39:14 +1100
committerAlex Ong <the.onga@gmail.com>2019-01-04 19:39:14 +1100
commit47c91fc7f75ae0a477e55b687aa0fc30da0a283c (patch)
tree65ad39452748ff2e6d4a83ce54ede6ca22c9ada9 /tmk_core
parentac9b88e8ccbbf38762871504cd827ff0d941c426 (diff)
parent563ce3f225d981ce460c12ca5130dfe47af41df0 (diff)
Merge branch 'master' of https://github.com/qmk/qmk_firmware
Diffstat (limited to 'tmk_core')
-rw-r--r--tmk_core/arm_atsam.mk56
-rw-r--r--tmk_core/avr.mk55
-rw-r--r--tmk_core/chibios.mk24
-rw-r--r--tmk_core/common.mk58
-rw-r--r--tmk_core/common/action.c38
-rw-r--r--tmk_core/common/action.h4
-rw-r--r--tmk_core/common/action_layer.c23
-rw-r--r--tmk_core/common/action_layer.h8
-rw-r--r--tmk_core/common/arm_atsam/bootloader.c51
-rw-r--r--tmk_core/common/arm_atsam/eeprom.c98
-rw-r--r--tmk_core/common/arm_atsam/printf.c66
-rw-r--r--tmk_core/common/arm_atsam/printf.h11
-rw-r--r--tmk_core/common/arm_atsam/suspend.c85
-rw-r--r--tmk_core/common/arm_atsam/timer.c59
-rw-r--r--tmk_core/common/avr/suspend.c41
-rw-r--r--tmk_core/common/backlight.c51
-rw-r--r--tmk_core/common/backlight.h7
-rwxr-xr-xtmk_core/common/chibios/eeprom_stm32.c673
-rwxr-xr-xtmk_core/common/chibios/eeprom_stm32.h95
-rw-r--r--tmk_core/common/chibios/eeprom_teensy.c (renamed from tmk_core/common/chibios/eeprom.c)0
-rwxr-xr-xtmk_core/common/chibios/flash_stm32.c188
-rwxr-xr-xtmk_core/common/chibios/flash_stm32.h53
-rw-r--r--tmk_core/common/command.c4
-rw-r--r--tmk_core/common/command.h5
-rw-r--r--tmk_core/common/eeconfig.c112
-rw-r--r--tmk_core/common/eeconfig.h44
-rw-r--r--tmk_core/common/host.c22
-rw-r--r--tmk_core/common/keyboard.c24
-rw-r--r--tmk_core/common/keyboard.h2
-rw-r--r--tmk_core/common/keycode.h816
-rw-r--r--tmk_core/common/print.h42
-rw-r--r--tmk_core/common/report.c21
-rw-r--r--tmk_core/common/report.h52
-rw-r--r--tmk_core/protocol.mk5
-rw-r--r--tmk_core/protocol/arm_atsam.mk25
-rw-r--r--tmk_core/protocol/arm_atsam/adc.c99
-rw-r--r--tmk_core/protocol/arm_atsam/adc.h37
-rw-r--r--tmk_core/protocol/arm_atsam/arm_atsam_protocol.h44
-rw-r--r--tmk_core/protocol/arm_atsam/clks.c439
-rw-r--r--tmk_core/protocol/arm_atsam/clks.h90
-rw-r--r--tmk_core/protocol/arm_atsam/d51_util.c227
-rw-r--r--tmk_core/protocol/arm_atsam/d51_util.h223
-rw-r--r--tmk_core/protocol/arm_atsam/i2c_master.c586
-rw-r--r--tmk_core/protocol/arm_atsam/i2c_master.h108
-rw-r--r--tmk_core/protocol/arm_atsam/issi3733_driver.h201
-rw-r--r--tmk_core/protocol/arm_atsam/led_matrix.c528
-rw-r--r--tmk_core/protocol/arm_atsam/led_matrix.h144
-rw-r--r--tmk_core/protocol/arm_atsam/main_arm_atsam.c340
-rw-r--r--tmk_core/protocol/arm_atsam/main_arm_atsam.h23
-rw-r--r--tmk_core/protocol/arm_atsam/md_bootloader.h25
-rw-r--r--tmk_core/protocol/arm_atsam/spi.c87
-rw-r--r--tmk_core/protocol/arm_atsam/spi.h70
-rw-r--r--tmk_core/protocol/arm_atsam/startup.c559
-rw-r--r--tmk_core/protocol/arm_atsam/usb/compiler.h1177
-rw-r--r--tmk_core/protocol/arm_atsam/usb/conf_usb.h168
-rw-r--r--tmk_core/protocol/arm_atsam/usb/main_usb.c132
-rw-r--r--tmk_core/protocol/arm_atsam/usb/status_codes.h158
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udc.c1164
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udc.h260
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udc_desc.h135
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udd.h396
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi.h133
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_cdc.c1380
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_cdc.h376
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_cdc_conf.h72
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_device_conf.h781
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_device_epsize.h32
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_hid.c162
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_hid.h85
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_hid_kbd.c992
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_hid_kbd.h122
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_hid_kbd_conf.h60
-rw-r--r--tmk_core/protocol/arm_atsam/usb/udi_hid_kbd_desc.c185
-rw-r--r--tmk_core/protocol/arm_atsam/usb/ui.c104
-rw-r--r--tmk_core/protocol/arm_atsam/usb/ui.h76
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb.c1144
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb.h492
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb2422.c409
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb2422.h404
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_atmel.h190
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_device_udd.c1097
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_main.h103
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_protocol.h498
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_protocol_cdc.h193
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_protocol_hid.h319
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_util.c59
-rw-r--r--tmk_core/protocol/arm_atsam/usb/usb_util.h10
-rw-r--r--tmk_core/protocol/arm_atsam/wait_api.h8
-rw-r--r--tmk_core/protocol/chibios/main.c18
-rw-r--r--tmk_core/protocol/chibios/usb_main.c183
-rw-r--r--tmk_core/protocol/chibios/usb_main.h11
-rw-r--r--tmk_core/protocol/lufa/lufa.c93
-rw-r--r--tmk_core/protocol/usb_descriptor.c213
-rw-r--r--tmk_core/protocol/usb_descriptor.h170
-rw-r--r--tmk_core/protocol/vusb/usbdrv/usbdrvasm.S8
-rw-r--r--tmk_core/protocol/xt.h71
-rw-r--r--tmk_core/protocol/xt_interrupt.c173
-rw-r--r--tmk_core/rules.mk41
98 files changed, 19921 insertions, 884 deletions
diff --git a/tmk_core/arm_atsam.mk b/tmk_core/arm_atsam.mk
new file mode 100644
index 0000000000..06823fb629
--- /dev/null
+++ b/tmk_core/arm_atsam.mk
@@ -0,0 +1,56 @@
+# Hey Emacs, this is a -*- makefile -*-
+##############################################################################
+# Compiler settings
+#
+CC = arm-none-eabi-gcc
+OBJCOPY = arm-none-eabi-objcopy
+OBJDUMP = arm-none-eabi-objdump
+SIZE = arm-none-eabi-size
+AR = arm-none-eabi-ar rcs
+NM = arm-none-eabi-nm
+HEX = $(OBJCOPY) -O $(FORMAT) -R .eeprom -R .fuse -R .lock -R .signature
+EEP = $(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" --change-section-lma .eeprom=0 --no-change-warnings -O $(FORMAT)
+BIN =
+
+COMMON_VPATH += $(LIB_PATH)/arm_atsam/packs/atmel/SAMD51_DFP/1.0.70/include
+COMMON_VPATH += $(LIB_PATH)/arm_atsam/packs/arm/cmsis/5.0.1/CMSIS/Include
+
+COMPILEFLAGS += -funsigned-char
+COMPILEFLAGS += -funsigned-bitfields
+COMPILEFLAGS += -ffunction-sections
+COMPILEFLAGS += -fshort-enums
+COMPILEFLAGS += -fno-inline-small-functions
+COMPILEFLAGS += -fno-strict-aliasing
+COMPILEFLAGS += -mfloat-abi=hard
+COMPILEFLAGS += -mfpu=fpv4-sp-d16
+COMPILEFLAGS += -mthumb
+
+#ALLOW_WARNINGS = yes
+
+CFLAGS += $(COMPILEFLAGS)
+
+CPPFLAGS += $(COMPILEFLAGS)
+CPPFLAGS += -fno-exceptions -std=c++11
+
+LDFLAGS +=-Wl,--gc-sections
+LDFLAGS += -Wl,-Map="%OUT%%PROJ_NAME%.map"
+LDFLAGS += -Wl,--start-group
+LDFLAGS += -Wl,--end-group
+LDFLAGS += --specs=rdimon.specs
+LDFLAGS += -T$(LIB_PATH)/arm_atsam/packs/atmel/SAMD51_DFP/1.0.70/gcc/gcc/samd51j18a_flash.ld
+
+OPT_DEFS += -DPROTOCOL_ARM_ATSAM
+
+MCUFLAGS = -mcpu=$(MCU)
+MCUFLAGS += -D__$(ARM_ATSAM)__
+
+# List any extra directories to look for libraries here.
+# Each directory must be seperated by a space.
+# Use forward slashes for directory separators.
+# For a directory that has spaces, enclose it in quotes.
+EXTRALIBDIRS =
+
+# Convert hex to bin.
+bin: $(BUILD_DIR)/$(TARGET).hex
+ $(OBJCOPY) -Iihex -Obinary $(BUILD_DIR)/$(TARGET).hex $(BUILD_DIR)/$(TARGET).bin
+ $(COPY) $(BUILD_DIR)/$(TARGET).bin $(TARGET).bin;
diff --git a/tmk_core/avr.mk b/tmk_core/avr.mk
index cf62b0f078..0c3a9624cb 100644
--- a/tmk_core/avr.mk
+++ b/tmk_core/avr.mk
@@ -169,7 +169,38 @@ dfu-ee: $(BUILD_DIR)/$(TARGET).hex $(BUILD_DIR)/$(TARGET).eep
fi
$(DFU_PROGRAMMER) $(MCU) reset
-avrdude: $(BUILD_DIR)/$(TARGET).hex check-size cpfirmware
+dfu-split-left: $(BUILD_DIR)/$(TARGET).hex cpfirmware check-size
+ until $(DFU_PROGRAMMER) $(MCU) get bootloader-version; do\
+ echo "Error: Bootloader not found. Trying again in 5s." ;\
+ sleep 5 ;\
+ done
+ if $(DFU_PROGRAMMER) --version 2>&1 | $(GREP) -q 0.7 ; then\
+ $(DFU_PROGRAMMER) $(MCU) erase --force;\
+ $(DFU_PROGRAMMER) $(MCU) flash --eeprom $(QUANTUM_PATH)/split_common/eeprom-lefthand.eep;\
+ else\
+ $(DFU_PROGRAMMER) $(MCU) erase;\
+ $(DFU_PROGRAMMER) $(MCU) flash-eeprom $(QUANTUM_PATH)/split_common/eeprom-lefthand.eep;\
+ fi
+ $(DFU_PROGRAMMER) $(MCU) flash $(BUILD_DIR)/$(TARGET).hex
+ $(DFU_PROGRAMMER) $(MCU) reset
+
+dfu-split-right: $(BUILD_DIR)/$(TARGET).hex cpfirmware check-size
+ until $(DFU_PROGRAMMER) $(MCU) get bootloader-version; do\
+ echo "Error: Bootloader not found. Trying again in 5s." ;\
+ sleep 5 ;\
+ done
+ if $(DFU_PROGRAMMER) --version 2>&1 | $(GREP) -q 0.7 ; then\
+ $(DFU_PROGRAMMER) $(MCU) erase --force;\
+ $(DFU_PROGRAMMER) $(MCU) flash --eeprom $(QUANTUM_PATH)/split_common/eeprom-righthand.eep;\
+ else\
+ $(DFU_PROGRAMMER) $(MCU) erase;\
+ $(DFU_PROGRAMMER) $(MCU) flash-eeprom $(QUANTUM_PATH)/split_common/eeprom-rightand.eep;\
+ fi
+ $(DFU_PROGRAMMER) $(MCU) flash $(BUILD_DIR)/$(TARGET).hex
+ $(DFU_PROGRAMMER) $(MCU) reset
+
+define EXEC_AVRDUDE
+ USB= ;\
if $(GREP) -q -s Microsoft /proc/version; then \
echo 'ERROR: AVR flashing cannot be automated within the Windows Subsystem for Linux (WSL) currently. Instead, take the .hex file generated and flash it using AVRDUDE, AVRDUDESS, or XLoader.'; \
else \
@@ -191,6 +222,15 @@ avrdude: $(BUILD_DIR)/$(TARGET).hex check-size cpfirmware
sleep 1; \
avrdude -p $(MCU) -c avr109 -P $$USB -U flash:w:$(BUILD_DIR)/$(TARGET).hex; \
fi
+endef
+
+avrdude: $(BUILD_DIR)/$(TARGET).hex check-size cpfirmware
+ $(call EXEC_AVRDUDE)
+
+avrdude-loop: $(BUILD_DIR)/$(TARGET).hex check-size cpfirmware
+ while true; do \
+ $(call EXEC_AVRDUDE) ; \
+ done
# Convert hex to bin.
bin: $(BUILD_DIR)/$(TARGET).hex
@@ -253,12 +293,12 @@ extcoff: $(BUILD_DIR)/$(TARGET).elf
bootloader:
make -C lib/lufa/Bootloaders/DFU/ clean
printf "#ifndef QMK_KEYBOARD\n#define QMK_KEYBOARD\n\n" > lib/lufa/Bootloaders/DFU/Keyboard.h
- printf "%s\n" "`$(GREP) "MANUFACTURER" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
- printf "%s Bootloader\n" "`$(GREP) "PRODUCT" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
- printf "%s\n" "`$(GREP) "QMK_ESC_OUTPUT" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
- printf "%s\n" "`$(GREP) "QMK_ESC_INPUT" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
- printf "%s\n" "`$(GREP) "QMK_LED" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
- printf "%s\n" "`$(GREP) "QMK_SPEAKER" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
+ printf "%s\n" "`$(GREP) "MANUFACTURER\s" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
+ printf "%s Bootloader\n" "`$(GREP) "PRODUCT\s" $(ALL_CONFIGS) -h | tail -1 | tr -d '\r'`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
+ printf "%s\n" "`$(GREP) "QMK_ESC_OUTPUT\s" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
+ printf "%s\n" "`$(GREP) "QMK_ESC_INPUT\s" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
+ printf "%s\n" "`$(GREP) "QMK_LED\s" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
+ printf "%s\n" "`$(GREP) "QMK_SPEAKER\s" $(ALL_CONFIGS) -h | tail -1`" >> lib/lufa/Bootloaders/DFU/Keyboard.h
printf "\n#endif" >> lib/lufa/Bootloaders/DFU/Keyboard.h
make -C lib/lufa/Bootloaders/DFU/
printf "BootloaderDFU.hex copied to $(TARGET)_bootloader.hex\n"
@@ -269,4 +309,3 @@ production: $(BUILD_DIR)/$(TARGET).hex bootloader cpfirmware
@cat $(TARGET)_bootloader.hex >> $(TARGET)_production.hex
echo "File sizes:"
$(SIZE) $(TARGET).hex $(TARGET)_bootloader.hex $(TARGET)_production.hex
-
diff --git a/tmk_core/chibios.mk b/tmk_core/chibios.mk
index 25c49204bc..0f665450ac 100644
--- a/tmk_core/chibios.mk
+++ b/tmk_core/chibios.mk
@@ -198,10 +198,13 @@ ifneq ("$(SERIAL)","")
DFU_ARGS += -S $(SERIAL)
endif
+ST_LINK_ARGS ?=
+
# List any extra directories to look for libraries here.
EXTRALIBDIRS = $(RULESPATH)/ld
DFU_UTIL ?= dfu-util
+ST_LINK_CLI ?= st-link_cli
# Generate a .qmk for the QMK-FF
qmk: $(BUILD_DIR)/$(TARGET).bin
@@ -230,5 +233,26 @@ qmk: $(BUILD_DIR)/$(TARGET).bin
dfu-util: $(BUILD_DIR)/$(TARGET).bin cpfirmware sizeafter
$(DFU_UTIL) $(DFU_ARGS) -D $(BUILD_DIR)/$(TARGET).bin
+
+ifneq ($(strip $(TIME_DELAY)),)
+ TIME_DELAY = $(strip $(TIME_DELAY))
+else
+ TIME_DELAY = 10
+endif
+dfu-util-wait: $(BUILD_DIR)/$(TARGET).bin cpfirmware sizeafter
+ echo "Preparing to flash firmware. Please enter bootloader now..." ;\
+ COUNTDOWN=$(TIME_DELAY) ;\
+ while [[ $$COUNTDOWN -ge 1 ]] ; do \
+ echo "Flashing in $$COUNTDOWN ..."; \
+ sleep 1 ;\
+ ((COUNTDOWN = COUNTDOWN - 1)) ; \
+ done; \
+ echo "Flashing $(TARGET).bin" ;\
+ sleep 1 ;\
+ $(DFU_UTIL) $(DFU_ARGS) -D $(BUILD_DIR)/$(TARGET).bin
+
+st-link-cli: $(BUILD_DIR)/$(TARGET).hex sizeafter
+ $(ST_LINK_CLI) $(ST_LINK_ARGS) -q -c SWD -p $(BUILD_DIR)/$(TARGET).hex -Rst
+
bin: $(BUILD_DIR)/$(TARGET).bin sizeafter
$(COPY) $(BUILD_DIR)/$(TARGET).bin $(TARGET).bin;
diff --git a/tmk_core/common.mk b/tmk_core/common.mk
index 3e407f1573..063115acb1 100644
--- a/tmk_core/common.mk
+++ b/tmk_core/common.mk
@@ -3,6 +3,8 @@ ifeq ($(PLATFORM),AVR)
PLATFORM_COMMON_DIR = $(COMMON_DIR)/avr
else ifeq ($(PLATFORM),CHIBIOS)
PLATFORM_COMMON_DIR = $(COMMON_DIR)/chibios
+else ifeq ($(PLATFORM),ARM_ATSAM)
+ PLATFORM_COMMON_DIR = $(COMMON_DIR)/arm_atsam
else
PLATFORM_COMMON_DIR = $(COMMON_DIR)/test
endif
@@ -29,12 +31,31 @@ endif
ifeq ($(PLATFORM),CHIBIOS)
TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/printf.c
- TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/eeprom.c
+ ifeq ($(MCU_SERIES), STM32F3xx)
+ TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/eeprom_stm32.c
+ TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/flash_stm32.c
+ TMK_COMMON_DEFS += -DEEPROM_EMU_STM32F303xC
+ TMK_COMMON_DEFS += -DSTM32_EEPROM_ENABLE
+ else ifeq ($(MCU_SERIES), STM32F1xx)
+ TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/eeprom_stm32.c
+ TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/flash_stm32.c
+ TMK_COMMON_DEFS += -DEEPROM_EMU_STM32F103xB
+ TMK_COMMON_DEFS += -DSTM32_EEPROM_ENABLE
+ else
+ TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/eeprom_teensy.c
+ endif
ifeq ($(strip $(AUTO_SHIFT_ENABLE)), yes)
TMK_COMMON_SRC += $(CHIBIOS)/os/various/syscalls.c
+ else ifeq ($(strip $(TERMINAL_ENABLE)), yes)
+ TMK_COMMON_SRC += $(CHIBIOS)/os/various/syscalls.c
endif
endif
+ifeq ($(PLATFORM),ARM_ATSAM)
+ TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/printf.c
+ TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/eeprom.c
+endif
+
ifeq ($(PLATFORM),TEST)
TMK_COMMON_SRC += $(PLATFORM_COMMON_DIR)/eeprom.c
endif
@@ -42,22 +63,50 @@ endif
# Option modules
-ifeq ($(strip $(BOOTMAGIC_ENABLE)), yes)
+BOOTMAGIC_ENABLE ?= no
+VALID_MAGIC_TYPES := yes full lite
+ifneq ($(strip $(BOOTMAGIC_ENABLE)), no)
+ ifeq ($(filter $(BOOTMAGIC_ENABLE),$(VALID_MAGIC_TYPES)),)
+ $(error BOOTMAGIC_ENABLE="$(BOOTMAGIC_ENABLE)" is not a valid type of magic)
+ endif
+ ifeq ($(strip $(BOOTMAGIC_ENABLE)), lite)
+ TMK_COMMON_DEFS += -DBOOTMAGIC_LITE
+ TMK_COMMON_DEFS += -DMAGIC_ENABLE
+ TMK_COMMON_SRC += $(COMMON_DIR)/magic.c
+ else
TMK_COMMON_DEFS += -DBOOTMAGIC_ENABLE
TMK_COMMON_SRC += $(COMMON_DIR)/bootmagic.c
+ endif
else
TMK_COMMON_DEFS += -DMAGIC_ENABLE
TMK_COMMON_SRC += $(COMMON_DIR)/magic.c
endif
+SHARED_EP_ENABLE = no
+MOUSE_SHARED_EP ?= yes
+ifeq ($(strip $(KEYBOARD_SHARED_EP)), yes)
+ TMK_COMMON_DEFS += -DKEYBOARD_SHARED_EP
+ SHARED_EP_ENABLE = yes
+ # With