From 17f36a21bfc340e4715c5849e4d0c537820e7cbe Mon Sep 17 00:00:00 2001 From: Ryan Date: Tue, 5 Dec 2023 22:49:14 +1100 Subject: Rework RGBLight driver system (#22529) --- builddefs/common_features.mk | 1 + 1 file changed, 1 insertion(+) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index 60f1cbd837..d793d5faf5 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -313,6 +313,7 @@ ifeq ($(strip $(RGBLIGHT_ENABLE)), yes) OPT_DEFS += -DRGBLIGHT_$(strip $(shell echo $(RGBLIGHT_DRIVER) | tr '[:lower:]' '[:upper:]')) SRC += $(QUANTUM_DIR)/color.c SRC += $(QUANTUM_DIR)/rgblight/rgblight.c + SRC += $(QUANTUM_DIR)/rgblight/rgblight_drivers.c CIE1931_CURVE := yes RGB_KEYCODES_ENABLE := yes endif -- cgit v1.2.3 From 4682226e20d17437c0a6f67f5d6160432074d948 Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Mon, 11 Dec 2023 23:06:18 +0000 Subject: Keymap introspection for Dip Switches (#22543) --- builddefs/common_features.mk | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index d793d5faf5..5e93480e4d 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -908,6 +908,12 @@ ifeq ($(strip $(ENCODER_ENABLE)), yes) endif endif +ifeq ($(strip $(DIP_SWITCH_ENABLE)), yes) + ifeq ($(strip $(DIP_SWITCH_MAP_ENABLE)), yes) + OPT_DEFS += -DDIP_SWITCH_MAP_ENABLE + endif +endif + VALID_WS2812_DRIVER_TYPES := bitbang custom i2c pwm spi vendor WS2812_DRIVER ?= bitbang -- cgit v1.2.3 From e1c0bd8a7c8d86ca573b430d5a914cf649c8d9b2 Mon Sep 17 00:00:00 2001 From: Ryan Date: Mon, 1 Jan 2024 12:40:35 +1100 Subject: LED drivers: extract IS31FL3742A from IS31COMMON (#22620) --- builddefs/common_features.mk | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index 5e93480e4d..f049b09247 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -396,10 +396,9 @@ ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3742a) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3742a-simple.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3743a) @@ -503,10 +502,9 @@ ifeq ($(strip $(RGB_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3742a) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3742a.c endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3743a) -- cgit v1.2.3 From ae2d5e2e5a170fa49e25b324c63e8650e6c872f9 Mon Sep 17 00:00:00 2001 From: Ryan Date: Mon, 1 Jan 2024 17:04:51 +1100 Subject: LED drivers: extract IS31FL3743A from IS31COMMON (#22635) --- builddefs/common_features.mk | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index f049b09247..5ed5c65b47 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -402,10 +402,9 @@ ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3743a) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3743a-simple.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3745) @@ -508,10 +507,9 @@ ifeq ($(strip $(RGB_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3743a) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3743a.c endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3745) -- cgit v1.2.3 From a88dd675bf3e1dedac2ceb7df779e0fb6931948a Mon Sep 17 00:00:00 2001 From: Ryan Date: Mon, 1 Jan 2024 19:31:44 +1100 Subject: LED drivers: extract IS31FL3745 from IS31COMMON (#22636) --- builddefs/common_features.mk | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index 5ed5c65b47..d5446a54c8 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -408,10 +408,9 @@ ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3745) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3745-simple.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3746a) @@ -513,10 +512,9 @@ ifeq ($(strip $(RGB_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3745) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3745.c endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3746a) -- cgit v1.2.3 From 0a6913b68274c03302b09466a79b99efffd35e59 Mon Sep 17 00:00:00 2001 From: Ryan Date: Mon, 1 Jan 2024 21:44:18 +1100 Subject: LED drivers: extract IS31FL3746A from IS31COMMON (#22637) --- builddefs/common_features.mk | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index d5446a54c8..cfdc63f1d4 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -414,10 +414,9 @@ ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3746a) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3746a-simple.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), snled27351) @@ -518,10 +517,9 @@ ifeq ($(strip $(RGB_MATRIX_ENABLE)), yes) endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3746a) - OPT_DEFS += -DIS31FLCOMMON I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31flcommon.c + SRC += is31fl3746a.c endif ifeq ($(strip $(RGB_MATRIX_DRIVER)), snled27351) -- cgit v1.2.3 From 597de0e29841aa6c738eb40454620bc30d44099a Mon Sep 17 00:00:00 2001 From: Ryan Date: Thu, 4 Jan 2024 17:05:37 +1100 Subject: LED drivers: rename "simple" to "mono" (#22814) --- builddefs/common_features.mk | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index cfdc63f1d4..a6193991f8 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -362,67 +362,67 @@ ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3218) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3218-simple.c + SRC += is31fl3218-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3731) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3731-simple.c + SRC += is31fl3731-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3733) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3733-simple.c + SRC += is31fl3733-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3736) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3736-simple.c + SRC += is31fl3736-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3737) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3737-simple.c + SRC += is31fl3737-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3741) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3741-simple.c + SRC += is31fl3741-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3742a) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3742a-simple.c + SRC += is31fl3742a-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3743a) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3743a-simple.c + SRC += is31fl3743a-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3745) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3745-simple.c + SRC += is31fl3745-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3746a) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi - SRC += is31fl3746a-simple.c + SRC += is31fl3746a-mono.c endif ifeq ($(strip $(LED_MATRIX_DRIVER)), snled27351) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led - SRC += snled27351-simple.c + SRC += snled27351-mono.c endif endif -- cgit v1.2.3 From 5cd31fda9c1302044f4423d940be7c888d15ad1a Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Sun, 28 Jan 2024 22:51:58 +0000 Subject: Begin removal of bootmagic lite terminology (#22970) --- builddefs/common_features.mk | 15 --------------- builddefs/generic_features.mk | 1 + 2 files changed, 1 insertion(+), 15 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index a6193991f8..513a3678a9 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -608,24 +608,9 @@ ifeq ($(strip $(VIA_ENABLE)), yes) TRI_LAYER_ENABLE := yes endif -VALID_MAGIC_TYPES := yes -BOOTMAGIC_ENABLE ?= no -ifneq ($(strip $(BOOTMAGIC_ENABLE)), no) - ifeq ($(filter $(BOOTMAGIC_ENABLE),$(VALID_MAGIC_TYPES)),) - $(call CATASTROPHIC_ERROR,Invalid BOOTMAGIC_ENABLE,BOOTMAGIC_ENABLE="$(BOOTMAGIC_ENABLE)" is not a valid type of magic) - endif - ifneq ($(strip $(BOOTMAGIC_ENABLE)), no) - OPT_DEFS += -DBOOTMAGIC_LITE - QUANTUM_SRC += $(QUANTUM_DIR)/bootmagic/bootmagic_lite.c - endif -endif -COMMON_VPATH += $(QUANTUM_DIR)/bootmagic -QUANTUM_SRC += $(QUANTUM_DIR)/bootmagic/magic.c - VALID_CUSTOM_MATRIX_TYPES:= yes lite no CUSTOM_MATRIX ?= no - ifneq ($(strip $(CUSTOM_MATRIX)), yes) ifeq ($(filter $(CUSTOM_MATRIX),$(VALID_CUSTOM_MATRIX_TYPES)),) $(call CATASTROPHIC_ERROR,Invalid CUSTOM_MATRIX,CUSTOM_MATRIX="$(CUSTOM_MATRIX)" is not a valid custom matrix type) diff --git a/builddefs/generic_features.mk b/builddefs/generic_features.mk index 9c86958625..dc34a64230 100644 --- a/builddefs/generic_features.mk +++ b/builddefs/generic_features.mk @@ -21,6 +21,7 @@ SPACE_CADET_ENABLE ?= yes GENERIC_FEATURES = \ AUTO_SHIFT \ AUTOCORRECT \ + BOOTMAGIC \ CAPS_WORD \ COMBO \ COMMAND \ -- cgit v1.2.3 From 77e88674986ee14bd1799b1ab19b4c94af083bac Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Fri, 16 Feb 2024 14:14:46 +0000 Subject: Fix joystick initialization (#22953) --- builddefs/common_features.mk | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index 513a3678a9..dab4ea083a 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -815,15 +815,12 @@ ifeq ($(strip $(JOYSTICK_ENABLE)), yes) $(call CATASTROPHIC_ERROR,Invalid JOYSTICK_DRIVER,JOYSTICK_DRIVER="$(JOYSTICK_DRIVER)" is not a valid joystick driver) endif OPT_DEFS += -DJOYSTICK_ENABLE + OPT_DEFS += -DJOYSTICK_$(strip $(shell echo $(JOYSTICK_DRIVER) | tr '[:lower:]' '[:upper:]')) SRC += $(QUANTUM_DIR)/process_keycode/process_joystick.c SRC += $(QUANTUM_DIR)/joystick.c ifeq ($(strip $(JOYSTICK_DRIVER)), analog) ANALOG_DRIVER_REQUIRED = yes - OPT_DEFS += -DANALOG_JOYSTICK_ENABLE - endif - ifeq ($(strip $(JOYSTICK_DRIVER)), digital) - OPT_DEFS += -DDIGITAL_JOYSTICK_ENABLE endif endif -- cgit v1.2.3 From f6709e65ebfd385a9963348d41c19abe9b91e8ad Mon Sep 17 00:00:00 2001 From: HorrorTroll Date: Fri, 16 Feb 2024 21:41:35 +0700 Subject: Add RGB matrix & LED Matrix support for IS31FL3729 (#21944) Co-authored-by: Xelus22 Co-authored-by: dexter93 --- builddefs/common_features.mk | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index dab4ea083a..90e0ff827d 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -340,7 +340,7 @@ LED_MATRIX_DRIVER := snled27351 endif LED_MATRIX_ENABLE ?= no -VALID_LED_MATRIX_TYPES := is31fl3218 is31fl3731 is31fl3733 is31fl3736 is31fl3737 is31fl3741 is31fl3742a is31fl3743a is31fl3745 is31fl3746a snled27351 custom +VALID_LED_MATRIX_TYPES := is31fl3218 is31fl3729 is31fl3731 is31fl3733 is31fl3736 is31fl3737 is31fl3741 is31fl3742a is31fl3743a is31fl3745 is31fl3746a snled27351 custom ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) ifeq ($(filter $(LED_MATRIX_DRIVER),$(VALID_LED_MATRIX_TYPES)),) @@ -365,6 +365,12 @@ ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) SRC += is31fl3218-mono.c endif + ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3729) + I2C_DRIVER_REQUIRED = yes + COMMON_VPATH += $(DRIVER_PATH)/led/issi + SRC += is31fl3729-mono.c + endif + ifeq ($(strip $(LED_MATRIX_DRIVER)), is31fl3731) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi @@ -437,7 +443,7 @@ endif RGB_MATRIX_ENABLE ?= no -VALID_RGB_MATRIX_TYPES := aw20216s is31fl3218 is31fl3731 is31fl3733 is31fl3736 is31fl3737 is31fl3741 is31fl3742a is31fl3743a is31fl3745 is31fl3746a snled27351 ws2812 custom +VALID_RGB_MATRIX_TYPES := aw20216s is31fl3218 is31fl3729 is31fl3731 is31fl3733 is31fl3736 is31fl3737 is31fl3741 is31fl3742a is31fl3743a is31fl3745 is31fl3746a snled27351 ws2812 custom ifeq ($(strip $(RGB_MATRIX_ENABLE)), yes) ifeq ($(filter $(RGB_MATRIX_DRIVER),$(VALID_RGB_MATRIX_TYPES)),) $(call CATASTROPHIC_ERROR,Invalid RGB_MATRIX_DRIVER,RGB_MATRIX_DRIVER="$(RGB_MATRIX_DRIVER)" is not a valid matrix type) @@ -468,6 +474,12 @@ ifeq ($(strip $(RGB_MATRIX_ENABLE)), yes) SRC += is31fl3218.c endif + ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3729) + I2C_DRIVER_REQUIRED = yes + COMMON_VPATH += $(DRIVER_PATH)/led/issi + SRC += is31fl3729.c + endif + ifeq ($(strip $(RGB_MATRIX_DRIVER)), is31fl3731) I2C_DRIVER_REQUIRED = yes COMMON_VPATH += $(DRIVER_PATH)/led/issi -- cgit v1.2.3 From 9d9cdaaa2d035787b0b50c26f2975695fdbc16f4 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Sun, 18 Feb 2024 21:17:15 +1100 Subject: Add encoder abstraction. (#21548) --- builddefs/common_features.mk | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index 90e0ff827d..58e41f5230 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -886,9 +886,24 @@ ifeq ($(strip $(BLUETOOTH_ENABLE)), yes) endif endif +ENCODER_ENABLE ?= no +ENCODER_DRIVER ?= quadrature +VALID_ENCODER_DRIVER_TYPES := quadrature custom ifeq ($(strip $(ENCODER_ENABLE)), yes) + ifeq ($(filter $(ENCODER_DRIVER),$(VALID_ENCODER_DRIVER_TYPES)),) + $(call CATASTROPHIC_ERROR,Invalid ENCODER_DRIVER,ENCODER_DRIVER="$(ENCODER_DRIVER)" is not a valid encoder driver) + endif SRC += $(QUANTUM_DIR)/encoder.c OPT_DEFS += -DENCODER_ENABLE + OPT_DEFS += -DENCODER_DRIVER_$(strip $(shell echo $(ENCODER_DRIVER) | tr '[:lower:]' '[:upper:]')) + + COMMON_VPATH += $(PLATFORM_PATH)/$(PLATFORM_KEY)/$(DRIVER_DIR)/encoder + COMMON_VPATH += $(DRIVER_PATH)/encoder + + ifneq ($(strip $(ENCODER_DRIVER)), custom) + SRC += encoder_$(strip $(ENCODER_DRIVER)).c + endif + ifeq ($(strip $(ENCODER_MAP_ENABLE)), yes) OPT_DEFS += -DENCODER_MAP_ENABLE endif -- cgit v1.2.3 From 61fa6949fbb537f54d48a4fc0218ff2b6873e940 Mon Sep 17 00:00:00 2001 From: Stefan Kerkmann Date: Tue, 20 Feb 2024 11:34:24 +0100 Subject: [Core] Allow ChibiOS `SIO` driver for `UART` driver (#22839) * onekey: stm32f3_disco: add usart pins and activate peripheral Signed-off-by: Stefan Kerkmann * chibios: uart: change SD1 prefix to UART Signed-off-by: Stefan Kerkmann * chibios: uart: add SIO driver and RP2040 compatibility Signed-off-by: Stefan Kerkmann Co-authored-by: Sergey Vlasov * Update platforms/chibios/drivers/uart.h Co-authored-by: Joel Challis --------- Signed-off-by: Stefan Kerkmann Co-authored-by: Sergey Vlasov Co-authored-by: Joel Challis --- builddefs/common_features.mk | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'builddefs') diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index 58e41f5230..7227a5558e 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -960,6 +960,15 @@ ifeq ($(strip $(SPI_DRIVER_REQUIRED)), yes) endif ifeq ($(strip $(UART_DRIVER_REQUIRED)), yes) - OPT_DEFS += -DHAL_USE_SERIAL=TRUE - QUANTUM_LIB_SRC += uart.c + ifeq ($(strip $(PLATFORM)), CHIBIOS) + ifneq ($(filter $(MCU_SERIES),RP2040),) + OPT_DEFS += -DHAL_USE_SIO=TRUE + QUANTUM_LIB_SRC += uart_sio.c + else + OPT_DEFS += -DHAL_USE_SERIAL=TRUE + QUANTUM_LIB_SRC += uart_serial.c + endif + else + QUANTUM_LIB_SRC += uart.c + endif endif -- cgit v1.2.3