Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move Bluetooth config to common_features.mk #14404

Merged
merged 2 commits into from
Sep 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions common_features.mk
Original file line number Diff line number Diff line change
Expand Up @@ -745,3 +745,26 @@ ifeq ($(strip $(USBPD_ENABLE)), yes)
endif
endif
endif

BLUETOOTH_ENABLE ?= no
VALID_BLUETOOTH_DRIVER_TYPES = AdafruitBLE RN42 custom
ifeq ($(strip $(BLUETOOTH_ENABLE)), yes)
ifeq ($(filter $(strip $(BLUETOOTH_DRIVER)),$(VALID_BLUETOOTH_DRIVER_TYPES)),)
$(error "$(BLUETOOTH_DRIVER)" is not a valid Bluetooth driver type)
endif
OPT_DEFS += -DBLUETOOTH_ENABLE
NO_USB_STARTUP_CHECK := yes
SRC += outputselect.c

ifeq ($(strip $(BLUETOOTH_DRIVER)), AdafruitBLE)
OPT_DEFS += -DMODULE_ADAFRUIT_BLE
SRC += analog.c
SRC += $(LUFA_DIR)/adafruit_ble.cpp
QUANTUM_LIB_SRC += spi_master.c
endif

ifeq ($(strip $(BLUETOOTH_DRIVER)), RN42)
OPT_DEFS += DMODULE_RN42
SRC += $(TMK_DIR)/protocol/serial_uart.c
endif
endif
1 change: 0 additions & 1 deletion disable_features.mk
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# Unconditionally disable features that a keyboard advertises it doesn't support

FEATURE_NAMES :=
FEATURE_NAMES += ADAFRUIT_BLE
FEATURE_NAMES += AUDIO
FEATURE_NAMES += BACKLIGHT
FEATURE_NAMES += BLUETOOTH
Expand Down
19 changes: 10 additions & 9 deletions docs/feature_bluetooth.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@

Currently Bluetooth support is limited to AVR based chips. For Bluetooth 2.1, QMK has support for RN-42 modules. For more recent BLE protocols, currently only the Adafruit Bluefruit SPI Friend is directly supported. BLE is needed to connect to iOS devices. Note iOS does not support mouse input.

|Board |Bluetooth Protocol |Connection Type |rules.mk |Bluetooth Chip|
|----------------------------------------------------------------|----------------------------|----------------|---------------------------|--------------|
|Roving Networks RN-42 (Sparkfun Bluesmirf) |Bluetooth Classic | UART |`BLUETOOTH = RN42` | RN-42 |
|[Bluefruit LE SPI Friend](https://www.adafruit.com/product/2633)|Bluetooth Low Energy | SPI |`BLUETOOTH = AdafruitBLE` | nRF51822 |
|Board |Bluetooth Protocol |Connection Type|rules.mk |Bluetooth Chip|
|----------------------------------------------------------------|--------------------|---------------|--------------------------------|--------------|
|Roving Networks RN-42 (Sparkfun Bluesmirf) |Bluetooth Classic |UART |`BLUETOOTH_DRIVER = RN42` |RN-42 |
|[Bluefruit LE SPI Friend](https://www.adafruit.com/product/2633)|Bluetooth Low Energy|SPI |`BLUETOOTH_DRIVER = AdafruitBLE`|nRF51822 |

Not Supported Yet but possible:
* [Bluefruit LE UART Friend](https://www.adafruit.com/product/2479). [Possible tmk implementation found in](https://github.com/tmk/tmk_keyboard/issues/514)
Expand All @@ -23,16 +23,17 @@ Currently The only bluetooth chipset supported by QMK is the Adafruit Bluefruit

A Bluefruit UART friend can be converted to an SPI friend, however this [requires](https://github.com/qmk/qmk_firmware/issues/2274) some reflashing and soldering directly to the MDBT40 chip.


<!-- FIXME: Document bluetooth support more completely. -->
## Bluetooth Rules.mk Options

The currently supported Bluetooth chipsets do not support [N-Key Rollover (NKRO)](reference_glossary.md#n-key-rollover-nkro), so `rules.mk` must contain `NKRO_ENABLE = no`.

Use only one of these to enable Bluetooth:
* BLUETOOTH_ENABLE = yes (Legacy Option)
* BLUETOOTH = RN42
* BLUETOOTH = AdafruitBLE
Add the following to your `rules.mk`:

```makefile
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE # or RN42
```

## Bluetooth Keycodes

Expand Down
4 changes: 2 additions & 2 deletions keyboards/10bleoledhub/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
OLED_ENABLE = yes
OLED_DRIVER = SSD1306
ENCODER_ENABLE = yes
3 changes: 2 additions & 1 deletion keyboards/40percentclub/mf68/keymaps/mf68_ble/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@ F_CPU = 8000000
# Build Options
# change yes to no to disable
#
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
BACKLIGHT_ENABLE = no
3 changes: 2 additions & 1 deletion keyboards/atreus/feather/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@ BOOTLOADER = caterina
# Build Options
# change yes to no to disable
#
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
CONSOLE_ENABLE = no
1 change: 0 additions & 1 deletion keyboards/converter/adb_usb/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ NKRO_ENABLE = no # USB Nkey Rollover - not yet supported in LUFA
EXTRAKEY_ENABLE = yes
USB_HID_ENABLE = yes
BACKLIGHT_ENABLE = no
#BLUETOOTH = AdafruitBLE # For Adafruit Feather 32U4 BLE support, uncomment this line
CUSTOM_MATRIX = yes

SRC = matrix.c adb.c led.c
1 change: 0 additions & 1 deletion keyboards/converter/m0110_usb/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ NKRO_ENABLE = no # USB Nkey Rollover - not yet supported in LUFA
EXTRAKEY_ENABLE = yes
USB_HID_ENABLE = yes
BACKLIGHT_ENABLE = no
#BLUETOOTH = AdafruitBLE # For Adafruit Feather 32U4 BLE support, uncomment this line
CUSTOM_MATRIX = yes

SRC = matrix.c m0110.c
6 changes: 3 additions & 3 deletions keyboards/converter/usb_usb/ble/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
UNICODE_ENABLE = no # Unicode
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
AUDIO_ENABLE = no # Audio output on port C6
BLUETOOTH = AdafruitBLE
ADAFRUIT_BLE_ENABLE = yes

BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE

EXTRAFLAGS += -flto
3 changes: 2 additions & 1 deletion keyboards/handwired/42/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,5 @@ AUDIO_ENABLE = no # Audio output on port C6
UNICODE_ENABLE = no # Unicode
UNICODEMAP_ENABLE = no # ^^
UCIS_ENABLE = no # ^^
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
3 changes: 2 additions & 1 deletion keyboards/handwired/bdn9_ble/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
UNICODE_ENABLE = no # Unicode
BLUETOOTH = AdafruitBLE # Enable Bluetooth
AUDIO_ENABLE = no # Audio output on port C6
ENCODER_ENABLE = no
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
4 changes: 2 additions & 2 deletions keyboards/handwired/fruity60/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
UNICODE_ENABLE = no # Unicode
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
AUDIO_ENABLE = no # Audio output on port C6
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE

LAYOUTS = 60_tsangan_hhkb
5 changes: 3 additions & 2 deletions keyboards/handwired/hacked_motospeed/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality on B7 by default
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
UNICODE_ENABLE = no # Unicode
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
AUDIO_ENABLE = no # Audio output on port C6
NO_USB_STARTUP_CHECK = yes # Disable initialization only when usb is plugged in
BLUETOOTH = RN42
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = RN42

4 changes: 3 additions & 1 deletion keyboards/handwired/prkl30/feather/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ BOOTLOADER = caterina
# Build Options
# change yes to no to disable
#
BLUETOOTH = AdafruitBLE
BOOTMAGIC_ENABLE = lite # Enable Bootmagic Lite
ENCODER_ENABLE = yes
MOUSEKEY_ENABLE = no # Mouse keys
Expand All @@ -22,3 +21,6 @@ NKRO_ENABLE = yes # USB Nkey Rollover - if this doesn't work, see here
BACKLIGHT_ENABLE = no
AUDIO_ENABLE = no # This can be enabled if a speaker is connected to the expansion port. Not compatible with RGBLIGHT below
RGBLIGHT_ENABLE = no # This can be enabled if a ws2812 strip is connected to the expansion port.

BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
2 changes: 0 additions & 2 deletions keyboards/handwired/promethium/keymaps/default/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,9 @@ MIDI_ENABLE = no # MIDI controls
AUDIO_ENABLE = no # Audio output on port C6
UNICODE_ENABLE = no # Unicode
UNICODEMAP_ENABLE = yes
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.
PS2_MOUSE_ENABLE = yes
PS2_USE_INT = yes
BLUETOOTH = AdafruitBLE

# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
2 changes: 0 additions & 2 deletions keyboards/handwired/promethium/keymaps/priyadi/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,9 @@ MIDI_ENABLE = no # MIDI controls
AUDIO_ENABLE = no # Audio output on port C6
UNICODE_ENABLE = no # Unicode
UNICODEMAP_ENABLE = yes
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.
PS2_MOUSE_ENABLE = yes
PS2_USE_INT = yes
BLUETOOTH = AdafruitBLE

# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
4 changes: 2 additions & 2 deletions keyboards/handwired/promethium/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
AUDIO_ENABLE = no # Audio output on port C6
UNICODE_ENABLE = no # Unicode
UNICODEMAP_ENABLE = yes
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.
PS2_MOUSE_ENABLE = yes
PS2_USE_INT = yes
CUSTOM_MATRIX = yes
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE

# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
Expand Down
4 changes: 2 additions & 2 deletions keyboards/handwired/pterodactyl/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
BLUETOOTH = AdafruitBLE
UNICODE_ENABLE = yes
CUSTOM_MATRIX = yes
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE

SRC += matrix.c
QUANTUM_LIB_SRC += i2c_master.c
4 changes: 2 additions & 2 deletions keyboards/handwired/slash/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
UNICODE_ENABLE = no # Unicode
#BLUETOOTH_ENABLE = Yes # Enable Bluetooth with the Adafruit EZ-Key HID
BLUETOOTH = AdafruitBLE
AUDIO_ENABLE = no # Audio output on port C6
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
4 changes: 2 additions & 2 deletions keyboards/laptreus/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@ TAP_DANCE_ENABLE = no
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend

BLUETOOTH_ENABLE = no # Legacy bluetooth support
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
4 changes: 2 additions & 2 deletions keyboards/latin47ble/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE

LAYOUTS = planck_mit
4 changes: 2 additions & 2 deletions keyboards/latin64ble/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
4 changes: 2 additions & 2 deletions keyboards/latinpadble/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output

BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
OLED_ENABLE = yes
OLED_DRIVER = SSD1306
ENCODER_ENABLE = yes
2 changes: 1 addition & 1 deletion keyboards/meira/featherble/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
F_CPU = 8000000

BLUETOOTH_ENABLE = yes
BLUETOOTH = AdafruitBLE
BLUETOOTH_DRIVER = AdafruitBLE
4 changes: 2 additions & 2 deletions keyboards/nek_type_a/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
UNICODE_ENABLE = no # Unicode
BLUETOOTH_ENABLE = yes # Enable Bluetooth with the Adafruit EZ-Key HID
AUDIO_ENABLE = no # Audio output on port C6
CUSTOM_MATRIX = yes
DEBUG_ENABLE = yes
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE

SRC += matrix.c mcp23017.c
3 changes: 2 additions & 1 deletion keyboards/spaceman/pancake/rev1/feather/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ BOOTLOADER = caterina
# Build Options
# comment out to disable the options.
#
BLUETOOTH = AdafruitBLE
BOOTMAGIC_ENABLE = lite # Enable Bootmagic Lite
MOUSEKEY_ENABLE = no # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
Expand All @@ -21,6 +20,8 @@ NKRO_ENABLE = yes # USB Nkey Rollover - if this doesn't work, see here: https:
BACKLIGHT_ENABLE = no # Custom backlighting code is used, so this should not be enabled
AUDIO_ENABLE = no # This can be enabled if a speaker is connected to the expansion port. Not compatible with RGBLIGHT below
RGBLIGHT_ENABLE = no # This can be enabled if a ws2812 strip is connected to the expansion port.
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE

LAYOUTS = ortho_4x12 planck_mit

Expand Down
4 changes: 2 additions & 2 deletions keyboards/tokyokeyboard/alix40/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = no # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
BLUETOOTH = AdafruitBLE
BLUETOOTH_ENABLE = yes
BLUETOOTH_DRIVER = AdafruitBLE
2 changes: 1 addition & 1 deletion show_options.mk
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ HARDWARE_OPTION_NAMES = \
CIE1931_CURVE \
MIDI_ENABLE \
BLUETOOTH_ENABLE \
BLUETOOTH_DRIVER \
AUDIO_ENABLE \
HD44780_ENABLE \
ENCODER_ENABLE \
Expand Down Expand Up @@ -57,7 +58,6 @@ OTHER_OPTION_NAMES = \
LED_ANIMATIONS \
IOS_DEVICE_ENABLE \
HELIX ZINC \
ADAFRUIT_BLE_ENABLE \
AUTOLOG_ENABLE \
DEBUG_ENABLE \
ENCODER_ENABLE_CUSTOM \
Expand Down
19 changes: 0 additions & 19 deletions tmk_core/common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,6 @@ ifeq ($(strip $(NKRO_ENABLE)), yes)
$(info NKRO is not currently supported on V-USB, and has been disabled.)
else ifeq ($(strip $(BLUETOOTH_ENABLE)), yes)
$(info NKRO is not currently supported with Bluetooth, and has been disabled.)
else ifneq ($(BLUETOOTH),)
$(info NKRO is not currently supported with Bluetooth, and has been disabled.)
else
TMK_COMMON_DEFS += -DNKRO_ENABLE
SHARED_EP_ENABLE = yes
Expand All @@ -77,23 +75,6 @@ ifeq ($(strip $(NO_SUSPEND_POWER_DOWN)), yes)
TMK_COMMON_DEFS += -DNO_SUSPEND_POWER_DOWN
endif

ifeq ($(strip $(BLUETOOTH_ENABLE)), yes)
TMK_COMMON_DEFS += -DBLUETOOTH_ENABLE
TMK_COMMON_DEFS += -DNO_USB_STARTUP_CHECK
endif

ifeq ($(strip $(BLUETOOTH)), AdafruitBLE)
TMK_COMMON_DEFS += -DBLUETOOTH_ENABLE
TMK_COMMON_DEFS += -DMODULE_ADAFRUIT_BLE
TMK_COMMON_DEFS += -DNO_USB_STARTUP_CHECK
endif

ifeq ($(strip $(BLUETOOTH)), RN42)
TMK_COMMON_DEFS += -DBLUETOOTH_ENABLE
TMK_COMMON_DEFS += -DMODULE_RN42
TMK_COMMON_DEFS += -DNO_USB_STARTUP_CHECK
endif

ifeq ($(strip $(SWAP_HANDS_ENABLE)), yes)
TMK_COMMON_DEFS += -DSWAP_HANDS_ENABLE
endif
Expand Down
Loading