From 254801343fbb47ac71d8ccfc9bf32a69b396998d Mon Sep 17 00:00:00 2001 From: 1Conan Date: Sun, 23 Oct 2022 22:53:31 +0800 Subject: [PATCH] rename bt driver and fix build --- builddefs/common_features.mk | 4 ++-- data/schemas/keyboard.jsonschema | 2 +- drivers/bluetooth/iton_bt.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/builddefs/common_features.mk b/builddefs/common_features.mk index 927f507ed5e4..eee95c80f31e 100644 --- a/builddefs/common_features.mk +++ b/builddefs/common_features.mk @@ -891,7 +891,7 @@ ifeq ($(strip $(USBPD_ENABLE)), yes) endif BLUETOOTH_ENABLE ?= no -VALID_BLUETOOTH_DRIVER_TYPES := BluefruitLE RN42 ITON_BT custom +VALID_BLUETOOTH_DRIVER_TYPES := BluefruitLE RN42 ItonBT custom ifeq ($(strip $(BLUETOOTH_ENABLE)), yes) ifeq ($(filter $(strip $(BLUETOOTH_DRIVER)),$(VALID_BLUETOOTH_DRIVER_TYPES)),) $(call CATASTROPHIC_ERROR,Invalid BLUETOOTH_DRIVER,BLUETOOTH_DRIVER="$(BLUETOOTH_DRIVER)" is not a valid Bluetooth driver type) @@ -914,7 +914,7 @@ ifeq ($(strip $(BLUETOOTH_ENABLE)), yes) QUANTUM_LIB_SRC += uart.c endif - ifeq ($(strip $(BLUETOOTH_DRIVER)), ITON_BT) + ifeq ($(strip $(BLUETOOTH_DRIVER)), ItonBT) OPT_DEFS += -DBLUETOOTH_ITON_BT SRC += $(DRIVER_PATH)/bluetooth/iton_bt.c endif diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index 3ecf0c6fb79d..bb56eb6d470a 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema @@ -130,7 +130,7 @@ "properties": { "driver": { "type": "string", - "enum": ["BluefruitLE", "RN42"] + "enum": ["BluefruitLE", "RN42", "ItonBT"] } } }, diff --git a/drivers/bluetooth/iton_bt.c b/drivers/bluetooth/iton_bt.c index b5b99be7b805..b18f51727ff2 100644 --- a/drivers/bluetooth/iton_bt.c +++ b/drivers/bluetooth/iton_bt.c @@ -69,7 +69,7 @@ const SPIConfig iton_bt_spicfg = { .slave = true, .data_cb = iton_bt_data_cb, // mcu specific - .ctrl0 = SPI_CTRL0_DL(8), + .ctrl0 = (8 << 8), // Data Length = 8 }; /**