diff options
405 files changed, 5174 insertions, 2929 deletions
diff --git a/.gitignore b/.gitignore index 90f3d6752..3592abcea 100644 --- a/.gitignore +++ b/.gitignore | |||
@@ -5,6 +5,7 @@ | |||
5 | *.eep | 5 | *.eep |
6 | *.elf | 6 | *.elf |
7 | *.hex | 7 | *.hex |
8 | *.uf2 | ||
8 | *.qmk | 9 | *.qmk |
9 | !util/bootloader.hex | 10 | !util/bootloader.hex |
10 | !quantum/tools/eeprom_reset.hex | 11 | !quantum/tools/eeprom_reset.hex |
@@ -29,6 +29,13 @@ $(info QMK Firmware $(QMK_VERSION)) | |||
29 | endif | 29 | endif |
30 | endif | 30 | endif |
31 | 31 | ||
32 | # Determine which qmk cli to use | ||
33 | ifeq (,$(shell which qmk)) | ||
34 | QMK_BIN = bin/qmk | ||
35 | else | ||
36 | QMK_BIN = qmk | ||
37 | endif | ||
38 | |||
32 | # avoid 'Entering|Leaving directory' messages | 39 | # avoid 'Entering|Leaving directory' messages |
33 | MAKEFLAGS += --no-print-directory | 40 | MAKEFLAGS += --no-print-directory |
34 | 41 | ||
@@ -86,8 +93,8 @@ clean: | |||
86 | 93 | ||
87 | .PHONY: distclean | 94 | .PHONY: distclean |
88 | distclean: clean | 95 | distclean: clean |
89 | echo -n 'Deleting *.bin and *.hex ... ' | 96 | echo -n 'Deleting *.bin, *.hex, and *.uf2 ... ' |
90 | rm -f *.bin *.hex | 97 | rm -f *.bin *.hex *.uf2 |
91 | echo 'done.' | 98 | echo 'done.' |
92 | 99 | ||
93 | #Compatibility with the old make variables, anything you specify directly on the command line | 100 | #Compatibility with the old make variables, anything you specify directly on the command line |
@@ -384,7 +391,7 @@ define PARSE_KEYMAP | |||
384 | # Format it in bold | 391 | # Format it in bold |
385 | KB_SP := $(BOLD)$$(KB_SP)$(NO_COLOR) | 392 | KB_SP := $(BOLD)$$(KB_SP)$(NO_COLOR) |
386 | # Specify the variables that we are passing forward to submake | 393 | # Specify the variables that we are passing forward to submake |
387 | MAKE_VARS := KEYBOARD=$$(CURRENT_KB) KEYMAP=$$(CURRENT_KM) REQUIRE_PLATFORM_KEY=$$(REQUIRE_PLATFORM_KEY) | 394 | MAKE_VARS := KEYBOARD=$$(CURRENT_KB) KEYMAP=$$(CURRENT_KM) REQUIRE_PLATFORM_KEY=$$(REQUIRE_PLATFORM_KEY) QMK_BIN=$$(QMK_BIN) |
388 | # And the first part of the make command | 395 | # And the first part of the make command |
389 | MAKE_CMD := $$(MAKE) -r -R -C $(ROOT_DIR) -f build_keyboard.mk $$(MAKE_TARGET) | 396 | MAKE_CMD := $$(MAKE) -r -R -C $(ROOT_DIR) -f build_keyboard.mk $$(MAKE_TARGET) |
390 | # The message to display | 397 | # The message to display |
@@ -501,8 +508,8 @@ endef | |||
501 | %: | 508 | %: |
502 | # Check if we have the CMP tool installed | 509 | # Check if we have the CMP tool installed |
503 | cmp $(ROOT_DIR)/Makefile $(ROOT_DIR)/Makefile >/dev/null 2>&1; if [ $$? -gt 0 ]; then printf "$(MSG_NO_CMP)"; exit 1; fi; | 510 | cmp $(ROOT_DIR)/Makefile $(ROOT_DIR)/Makefile >/dev/null 2>&1; if [ $$? -gt 0 ]; then printf "$(MSG_NO_CMP)"; exit 1; fi; |
504 | # Ensure that bin/qmk works. | 511 | # Ensure that $(QMK_BIN) works. |
505 | if ! bin/qmk hello 1> /dev/null 2>&1; then printf "$(MSG_PYTHON_MISSING)"; exit 1; fi | 512 | if ! $(QMK_BIN) hello 1> /dev/null 2>&1; then printf "$(MSG_PYTHON_MISSING)"; exit 1; fi |
506 | # Check if the submodules are dirty, and display a warning if they are | 513 | # Check if the submodules are dirty, and display a warning if they are |
507 | ifndef SKIP_GIT | 514 | ifndef SKIP_GIT |
508 | if [ ! -e lib/chibios ]; then git submodule sync lib/chibios && git submodule update --depth 50 --init lib/chibios; fi | 515 | if [ ! -e lib/chibios ]; then git submodule sync lib/chibios && git submodule update --depth 50 --init lib/chibios; fi |
@@ -73,8 +73,11 @@ def main(): | |||
73 | """ | 73 | """ |
74 | # Change to the root of our checkout | 74 | # Change to the root of our checkout |
75 | os.environ['ORIG_CWD'] = os.getcwd() | 75 | os.environ['ORIG_CWD'] = os.getcwd() |
76 | os.environ['DEPRECATED_BIN_QMK'] = '1' | ||
76 | os.chdir(qmk_dir) | 77 | os.chdir(qmk_dir) |
77 | 78 | ||
79 | print('Warning: The bin/qmk script is being deprecated. Please install the QMK CLI: python3 -m pip install qmk', file=sys.stderr) | ||
80 | |||
78 | # Import the subcommands | 81 | # Import the subcommands |
79 | import qmk.cli # noqa | 82 | import qmk.cli # noqa |
80 | 83 | ||
diff --git a/bootloader.mk b/bootloader.mk index fd76446e9..ead52cbe3 100644 --- a/bootloader.mk +++ b/bootloader.mk | |||
@@ -137,3 +137,6 @@ ifeq ($(strip $(BOOTLOADER)), stm32duino) | |||
137 | DFU_ARGS = -d 1EAF:0003 -a 2 -R | 137 | DFU_ARGS = -d 1EAF:0003 -a 2 -R |
138 | DFU_SUFFIX_ARGS = -v 1EAF -p 0003 | 138 | DFU_SUFFIX_ARGS = -v 1EAF -p 0003 |
139 | endif | 139 | endif |
140 | ifeq ($(strip $(BOOTLOADER)), tinyuf2) | ||
141 | OPT_DEFS += -DBOOTLOADER_TINYUF2 | ||
142 | endif | ||
diff --git a/build_json.mk b/build_json.mk index 6e2f9c4c8..8822be6a1 100644 --- a/build_json.mk +++ b/build_json.mk | |||
@@ -28,4 +28,4 @@ endif | |||
28 | 28 | ||
29 | # Generate the keymap.c | 29 | # Generate the keymap.c |
30 | $(KEYBOARD_OUTPUT)/src/keymap.c: $(KEYMAP_JSON) | 30 | $(KEYBOARD_OUTPUT)/src/keymap.c: $(KEYMAP_JSON) |
31 | bin/qmk json2c --quiet --output $(KEYMAP_C) $(KEYMAP_JSON) | 31 | $(QMK_BIN) json2c --quiet --output $(KEYMAP_C) $(KEYMAP_JSON) |
diff --git a/build_keyboard.mk b/build_keyboard.mk index 366d1f5d2..74046a094 100644 --- a/build_keyboard.mk +++ b/build_keyboard.mk | |||
@@ -12,6 +12,9 @@ endif | |||
12 | 12 | ||
13 | include common.mk | 13 | include common.mk |
14 | 14 | ||
15 | # Set the qmk cli to use | ||
16 | QMK_BIN ?= qmk | ||
17 | |||
15 | # Set the filename for the final firmware binary | 18 | # Set the filename for the final firmware binary |
16 | KEYBOARD_FILESAFE := $(subst /,_,$(KEYBOARD)) | 19 | KEYBOARD_FILESAFE := $(subst /,_,$(KEYBOARD)) |
17 | TARGET ?= $(KEYBOARD_FILESAFE)_$(KEYMAP) | 20 | TARGET ?= $(KEYBOARD_FILESAFE)_$(KEYMAP) |
@@ -97,7 +100,7 @@ MAIN_KEYMAP_PATH_4 := $(KEYBOARD_PATH_4)/keymaps/$(KEYMAP) | |||
97 | MAIN_KEYMAP_PATH_5 := $(KEYBOARD_PATH_5)/keymaps/$(KEYMAP) | 100 | MAIN_KEYMAP_PATH_5 := $(KEYBOARD_PATH_5)/keymaps/$(KEYMAP) |
98 | 101 | ||
99 | # Pull in rules from info.json | 102 | # Pull in rules from info.json |
100 | INFO_RULES_MK = $(shell bin/qmk generate-rules-mk --quiet --escape --keyboard $(KEYBOARD) --output $(KEYBOARD_OUTPUT)/src/rules.mk) | 103 | INFO_RULES_MK = $(shell $(QMK_BIN) generate-rules-mk --quiet --escape --keyboard $(KEYBOARD) --output $(KEYBOARD_OUTPUT)/src/rules.mk) |
101 | include $(INFO_RULES_MK) | 104 | include $(INFO_RULES_MK) |
102 | 105 | ||
103 | # Check for keymap.json first, so we can regenerate keymap.c | 106 | # Check for keymap.json first, so we can regenerate keymap.c |
@@ -294,10 +297,10 @@ endif | |||
294 | CONFIG_H += $(KEYBOARD_OUTPUT)/src/info_config.h $(KEYBOARD_OUTPUT)/src/layouts.h | 297 | CONFIG_H += $(KEYBOARD_OUTPUT)/src/info_config.h $(KEYBOARD_OUTPUT)/src/layouts.h |
295 | 298 | ||
296 | $(KEYBOARD_OUTPUT)/src/info_config.h: $(INFO_JSON_FILES) | 299 | $(KEYBOARD_OUTPUT)/src/info_config.h: $(INFO_JSON_FILES) |
297 | bin/qmk generate-config-h --quiet --keyboard $(KEYBOARD) --output $(KEYBOARD_OUTPUT)/src/info_config.h | 300 | $(QMK_BIN) generate-config-h --quiet --keyboard $(KEYBOARD) --output $(KEYBOARD_OUTPUT)/src/info_config.h |
298 | 301 | ||
299 | $(KEYBOARD_OUTPUT)/src/layouts.h: $(INFO_JSON_FILES) | 302 | $(KEYBOARD_OUTPUT)/src/layouts.h: $(INFO_JSON_FILES) |
300 | bin/qmk generate-layouts --quiet --keyboard $(KEYBOARD) --output $(KEYBOARD_OUTPUT)/src/layouts.h | 303 | $(QMK_BIN) generate-layouts --quiet --keyboard $(KEYBOARD) --output $(KEYBOARD_OUTPUT)/src/layouts.h |
301 | 304 | ||
302 | generated-files: $(KEYBOARD_OUTPUT)/src/info_config.h $(KEYBOARD_OUTPUT)/src/layouts.h | 305 | generated-files: $(KEYBOARD_OUTPUT)/src/info_config.h $(KEYBOARD_OUTPUT)/src/layouts.h |
303 | 306 | ||
diff --git a/common_features.mk b/common_features.mk index 8c9d0a90c..5a1231de4 100644 --- a/common_features.mk +++ b/common_features.mk | |||
@@ -223,14 +223,17 @@ VALID_LED_MATRIX_TYPES := IS31FL3731 custom | |||
223 | 223 | ||
224 | ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) | 224 | ifeq ($(strip $(LED_MATRIX_ENABLE)), yes) |
225 | ifeq ($(filter $(LED_MATRIX_DRIVER),$(VALID_LED_MATRIX_TYPES)),) | 225 | ifeq ($(filter $(LED_MATRIX_DRIVER),$(VALID_LED_MATRIX_TYPES)),) |
226 | $(error LED_MATRIX_DRIVER="$(LED_MATRIX_DRIVER)" is not a valid matrix type) | 226 | $(error "$(LED_MATRIX_DRIVER)" is not a valid matrix type) |
227 | else | ||
228 | BACKLIGHT_ENABLE = yes | ||
229 | BACKLIGHT_DRIVER = custom | ||
230 | OPT_DEFS += -DLED_MATRIX_ENABLE | ||
231 | SRC += $(QUANTUM_DIR)/led_matrix.c | ||
232 | SRC += $(QUANTUM_DIR)/led_matrix_drivers.c | ||
233 | endif | 227 | endif |
228 | OPT_DEFS += -DLED_MATRIX_ENABLE | ||
229 | ifneq (,$(filter $(MCU), atmega16u2 atmega32u2 at90usb162)) | ||
230 | # ATmegaxxU2 does not have hardware MUL instruction - lib8tion must be told to use software multiplication routines | ||
231 | OPT_DEFS += -DLIB8_ATTINY | ||
232 | endif | ||
233 | SRC += $(QUANTUM_DIR)/process_keycode/process_backlight.c | ||
234 | SRC += $(QUANTUM_DIR)/led_matrix.c | ||
235 | SRC += $(QUANTUM_DIR)/led_matrix_drivers.c | ||
236 | CIE1931_CURVE := yes | ||
234 | 237 | ||
235 | ifeq ($(strip $(LED_MATRIX_DRIVER)), IS31FL3731) | 238 | ifeq ($(strip $(LED_MATRIX_DRIVER)), IS31FL3731) |
236 | OPT_DEFS += -DIS31FL3731 -DSTM32_I2C -DHAL_USE_I2C=TRUE | 239 | OPT_DEFS += -DIS31FL3731 -DSTM32_I2C -DHAL_USE_I2C=TRUE |
@@ -422,10 +425,6 @@ ifeq ($(strip $(TERMINAL_ENABLE)), yes) | |||
422 | OPT_DEFS += -DUSER_PRINT | 425 | OPT_DEFS += -DUSER_PRINT |
423 | endif | 426 | endif |
424 | 427 | ||
425 | ifeq ($(strip $(USB_HID_ENABLE)), yes) | ||
426 | include $(TMK_DIR)/protocol/usb_hid.mk | ||
427 | endif | ||
428 | |||
429 | ifeq ($(strip $(WPM_ENABLE)), yes) | 428 | ifeq ($(strip $(WPM_ENABLE)), yes) |
430 | SRC += $(QUANTUM_DIR)/wpm.c | 429 | SRC += $(QUANTUM_DIR)/wpm.c |
431 | OPT_DEFS += -DWPM_ENABLE | 430 | OPT_DEFS += -DWPM_ENABLE |
@@ -459,6 +458,23 @@ ifeq ($(strip $(DIP_SWITCH_ENABLE)), yes) | |||
459 | SRC += $(QUANTUM_DIR)/dip_switch.c | 458 | SRC += $(QUANTUM_DIR)/dip_switch.c |
460 | endif | 459 | endif |
461 | 460 | ||
461 | VALID_MAGIC_TYPES := yes full lite | ||
462 | BOOTMAGIC_ENABLE ?= no | ||
463 | ifneq ($(strip $(BOOTMAGIC_ENABLE)), no) | ||
464 | ifeq ($(filter $(BOOTMAGIC_ENABLE),$(VALID_MAGIC_TYPES)),) | ||
465 | $(error BOOTMAGIC_ENABLE="$(BOOTMAGIC_ENABLE)" is not a valid type of magic) | ||
466 | endif | ||
467 | ifneq ($(strip $(BOOTMAGIC_ENABLE)), full) | ||
468 | OPT_DEFS += -DBOOTMAGIC_LITE | ||
469 | QUANTUM_SRC += $(QUANTUM_DIR)/bootmagic/bootmagic_lite.c | ||
470 | else | ||
471 | OPT_DEFS += -DBOOTMAGIC_ENABLE | ||
472 | QUANTUM_SRC += $(QUANTUM_DIR)/bootmagic/bootmagic_full.c | ||
473 | endif | ||
474 | endif | ||
475 | COMMON_VPATH += $(QUANTUM_DIR)/bootmagic | ||
476 | QUANTUM_SRC += $(QUANTUM_DIR)/bootmagic/magic.c | ||
477 | |||
462 | VALID_CUSTOM_MATRIX_TYPES:= yes lite no | 478 | VALID_CUSTOM_MATRIX_TYPES:= yes lite no |
463 | 479 | ||
464 | CUSTOM_MATRIX ?= no | 480 | CUSTOM_MATRIX ?= no |
@@ -673,4 +689,4 @@ ifeq ($(strip $(USBPD_ENABLE)), yes) | |||
673 | # Board designers can add their own driver to $(SRC) | 689 | # Board designers can add their own driver to $(SRC) |
674 | endif | 690 | endif |
675 | endif | 691 | endif |
676 | endif \ No newline at end of file | 692 | endif |
diff --git a/data/schemas/keyboard.jsonschema b/data/schemas/keyboard.jsonschema index ec03a8828..99121d79e 100644 --- a/data/schemas/keyboard.jsonschema +++ b/data/schemas/keyboard.jsonschema | |||
@@ -25,7 +25,7 @@ | |||
25 | }, | 25 | }, |
26 | "processor": { | 26 | "processor": { |
27 | "type": "string", | 27 | "type": "string", |
28 | "enum": ["cortex-m0", "cortex-m0plus", "cortex-m3", "cortex-m4", "MKL26Z64", "MK20DX128", "MK20DX256", "STM32F042", "STM32F072", "STM32F103", "STM32F303", "STM32F401", "STM32F411", "STM32G431", "STM32G474", "atmega16u2", "atmega32u2", "atmega16u4", "atmega32u4", "at90usb162", "at90usb646", "at90usb647", "at90usb1286", "at90usb1287", "atmega32a", "atmega328p", "atmega328", "attiny85", "unknown"] | 28 | "enum": ["cortex-m0", "cortex-m0plus", "cortex-m3", "cortex-m4", "MKL26Z64", "MK20DX128", "MK20DX256", "MK66F18", "STM32F042", "STM32F072", "STM32F103", "STM32F303", "STM32F401", "STM32F411", "STM32F446", "STM32G431", "STM32G474", "atmega16u2", "atmega32u2", "atmega16u4", "atmega32u4", "at90usb162", "at90usb646", "at90usb647", "at90usb1286", "at90usb1287", "atmega32a", "atmega328p", "atmega328", "attiny85", "unknown"] |
29 | }, | 29 | }, |
30 | "board": { | 30 | "board": { |
31 | "type": "string", | 31 | "type": "string", |
@@ -34,7 +34,7 @@ | |||
34 | }, | 34 | }, |
35 | "bootloader": { | 35 | "bootloader": { |
36 | "type": "string", | 36 | "type": "string", |
37 | "enum": ["atmel-dfu", "bootloadHID", "caterina", "halfkay", "kiibohd", "lufa-dfu", "lufa-ms", "micronucleus", "qmk-dfu", "stm32-dfu", "stm32duino", "unknown", "USBasp"] | 37 | "enum": ["atmel-dfu", "bootloadHID", "caterina", "halfkay", "kiibohd", "lufa-dfu", "lufa-ms", "micronucleus", "qmk-dfu", "stm32-dfu", "stm32duino", "unknown", "USBasp", "tinyuf2"] |
38 | }, | 38 | }, |
39 | "diode_direction": { | 39 | "diode_direction": { |
40 | "type": "string", | 40 | "type": "string", |
diff --git a/docs/ChangeLog/20210529/PR12172.md b/docs/ChangeLog/20210529/PR12172.md new file mode 100644 index 000000000..0c355c151 --- /dev/null +++ b/docs/ChangeLog/20210529/PR12172.md | |||
@@ -0,0 +1,13 @@ | |||
1 | ## Bootmagic Deprecation and Refactor ([#12172](https://github.com/qmk/qmk_firmware/pull/12172)) | ||
2 | |||
3 | QMK has decided to deprecate the full Bootmagic feature and leave Bootmagic Lite as the only remaining option. | ||
4 | |||
5 | This pull request changes the behavior of `BOOTMAGIC_ENABLE` such that specifying `BOOTMAGIC_ENABLE = yes` enables Bootmagic Lite instead of full Bootmagic. | ||
6 | |||
7 | ### Tentative Deprecation Schedule | ||
8 | |||
9 | This is the current planned roadmap for the behavior of `BOOTMAGIC_ENABLE`: | ||
10 | |||
11 | - From 2021-05-29, setting `BOOTMAGIC_ENABLE = yes` will enable Bootmagic Lite instead of full Bootmagic. | ||
12 | - From 2021-08-28, `BOOTMAGIC_ENABLE` must be either `yes`, `lite`, or `no` – setting `BOOTMAGIC_ENABLE = full` will cause compilation to fail. | ||
13 | - From 2021-11-27, `BOOTMAGIC_ENABLE` must be either `yes` or `no` – setting `BOOTMAGIC_ENABLE = lite` will cause compilation to fail. | ||
diff --git a/docs/adc_driver.md b/docs/adc_driver.md index 6e3d51386..69fff4b3c 100644 --- a/docs/adc_driver.md +++ b/docs/adc_driver.md | |||
@@ -47,73 +47,79 @@ Note that some of these pins are doubled-up on ADCs with the same channel. This | |||
47 | 47 | ||
48 | Also note that the F0 and F3 use different numbering schemes. The F0 has a single ADC and the channels are 0-indexed, whereas the F3 has 4 ADCs and the channels are 1-indexed. This is because the F0 uses the `ADCv1` implementation of the ADC, whereas the F3 uses the `ADCv3` implementation. | 48 | Also note that the F0 and F3 use different numbering schemes. The F0 has a single ADC and the channels are 0-indexed, whereas the F3 has 4 ADCs and the channels are 1-indexed. This is because the F0 uses the `ADCv1` implementation of the ADC, whereas the F3 uses the `ADCv3` implementation. |
49 | 49 | ||
50 | |ADC|Channel|STM32F0xx|STM32F3xx| | 50 | |ADC|Channel|STM32F0xx|STM32F1xx|STM32F3xx|STM32F4xx| |
51 | |---|-------|---------|---------| | 51 | |---|-------|---------|---------|---------|---------| |
52 | |1 |0 |`A0` | | | 52 | |1 |0 |`A0` |`A0` | |`A0` | |
53 | |1 |1 |`A1` |`A0` | | 53 | |1 |1 |`A1` |`A1` |`A0` |`A1` | |
54 | |1 |2 |`A2` |`A1` | | 54 | |1 |2 |`A2` |`A2` |`A1` |`A2` | |
55 | |1 |3 |`A3` |`A2` | | 55 | |1 |3 |`A3` |`A3` |`A2` |`A3` | |
56 | |1 |4 |`A4` |`A3` | | 56 | |1 |4 |`A4` |`A4` |`A3` |`A4` | |
57 | |1 |5 |`A5` |`F4` | | 57 | |1 |5 |`A5` |`A5` |`F4` |`A5` | |
58 | |1 |6 |`A6` |`C0` | | 58 | |1 |6 |`A6` |`A6` |`C0` |`A6` | |
59 | |1 |7 |`A7` |`C1` | | 59 | |1 |7 |`A7` |`A7` |`C1` |`A7` | |
60 | |1 |8 |`B0` |`C2` | | 60 | |1 |8 |`B0` |`B0` |`C2` |`B0` | |
61 | |1 |9 |`B1` |`C3` | | 61 | |1 |9 |`B1` |`B1` |`C3` |`B1` | |
62 | |1 |10 |`C0` |`F2` | | 62 | |1 |10 |`C0` |`C0` |`F2` |`C0` | |
63 | |1 |11 |`C1` | | | 63 | |1 |11 |`C1` |`C1` | |`C1` | |
64 | |1 |12 |`C2` | | | 64 | |1 |12 |`C2` |`C2` | |`C2` | |
65 | |1 |13 |`C3` | | | 65 | |1 |13 |`C3` |`C3` | |`C3` | |
66 | |1 |14 |`C4` | | | 66 | |1 |14 |`C4` |`C4` | |`C4` | |
67 | |1 |15 |`C5` | | | 67 | |1 |15 |`C5` |`C5` | |`C5` | |
68 | |1 |16 | | | | 68 | |1 |16 | | | | | |
69 | |2 |1 | |`A4` | | 69 | |2 |0 | |`A0`¹ | |`A0`² | |
70 | |2 |2 | |`A5` | | 70 | |2 |1 | |`A1`¹ |`A4` |`A1`² | |
71 | |2 |3 | |`A6` | | 71 | |2 |2 | |`A2`¹ |`A5` |`A2`² | |
72 | |2 |4 | |`A7` | | 72 | |2 |3 | |`A3`¹ |`A6` |`A3`² | |
73 | |2 |5 | |`C4` | | 73 | |2 |4 | |`A4`¹ |`A7` |`A4`² | |
74 | |2 |6 | |`C0` | | 74 | |2 |5 | |`A5`¹ |`C4` |`A5`² | |
75 | |2 |7 | |`C1` | | 75 | |2 |6 | |`A6`¹ |`C0` |`A6`² | |
76 | |2 |8 | |`C2` | | 76 | |2 |7 | |`A7`¹ |`C1` |`A7`² | |
77 | |2 |9 | |`C3` | | 77 | |2 |8 | |`B0`¹ |`C2` |`B0`² | |
78 | |2 |10 | |`F2` | | 78 | |2 |9 | |`B1`¹ |`C3` |`B1`² | |
79 | |2 |11 | |`C5` | | 79 | |2 |10 | |`C0`¹ |`F2` |`C0`² | |
80 | |2 |12 | |`B2` | | 80 | |2 |11 | |`C1`¹ |`C5` |`C1`² | |
81 | |2 |13 | | | | 81 | |2 |12 | |`C2`¹ |`B2` |`C2`² | |
82 | |2 |14 | | | | 82 | |2 |13 | |`C3`¹ | |`C3`² | |
83 | |2 |15 | | | | 83 | |2 |14 | |`C4`¹ | |`C4`² | |
84 | |2 |16 | | | | 84 | |2 |15 | |`C5`¹ | |`C5`² | |
85 | |3 |1 | |`B1` | | 85 | |2 |16 | | | | | |
86 | |3 |2 | |`E9` | | 86 | |3 |0 | |`A0`¹ | |`A0`² | |
87 | |3 |3 | |`E13` | | 87 | |3 |1 | |`A1`¹ |`B1` |`A1`² | |
88 | |3 |4 | | | | 88 | |3 |2 | |`A2`¹ |`E9` |`A2`² | |
89 | |3 |5 | | | | 89 | |3 |3 | |`A3`¹ |`E13` |`A3`² | |
90 | |3 |6 | |`E8` | | 90 | |3 |4 | |`F6`¹ | |`F6`² | |
91 | |3 |7 | |`D10` | | 91 | |3 |5 | |`F7`¹ |`B13` |`F7`² | |
92 | |3 |8 | |`D11` | | 92 | |3 |6 | |`F8`¹ |`E8` |`F8`² | |
93 | |3 |9 | |`D12` | | 93 | |3 |7 | |`F9`¹ |`D10` |`F9`² | |
94 | |3 |10 | |`D13` | | 94 | |3 |8 | |`F10`¹ |`D11` |`F10`² | |
95 | |3 |11 | |`D14` | | 95 | |3 |9 | | |`D12` |`F3`² | |
96 | |3 |12 | |`B0` | | 96 | |3 |10 | |`C0`¹ |`D13` |`C0`² | |
97 | |3 |13 | |`E7` | | 97 | |3 |11 | |`C1`¹ |`D14` |`C1`² | |
98 | |3 |14 | |`E10` | | 98 | |3 |12 | |`C2`¹ |`B0` |`C2`² | |
99 | |3 |15 | |`E11` | | 99 | |3 |13 | |`C3`¹ |`E7` |`C3`² | |
100 | |3 |16 | |`E12` | | 100 | |3 |14 | | |`E10` |`F4`² | |
101 | |4 |1 | |`E14` | | 101 | |3 |15 | | |`E11` |`F5`² | |
102 | |4 |2 | |`B12` | | 102 | |3 |16 | | |`E12` | | |
103 | |4 |3 | |`B13` | | 103 | |4 |1 | | |`E14` | | |
104 | |4 |4 | |`B14` | | 104 | |4 |2 | | |`E15` | | |
105 | |4 |5 | |`B15` | | 105 | |4 |3 | | |`B12` | | |
106 | |4 |6 | |`E8` | | 106 | |4 |4 | | |`B14` | | |
107 | |4 |7 | |`D10` | | 107 | |4 |5 | | |`B15` | | |
108 | |4 |8 | |`D11` | | 108 | |4 |6 | | |`E8` | | |
109 | |4 |9 | |`D12` | | 109 | |4 |7 | | |`D10` | | |
110 | |4 |10 | |`D13` | | 110 | |4 |8 | | |`D11` | | |
111 | |4 |11 | |`D14` | | 111 | |4 |9 | | |`D12` | | |
112 | |4 |12 | |`D8` | | 112 | |4 |10 | | |`D13` | | |
113 | |4 |13 | |`D9` | | 113 | |4 |11 | | |`D14` | | |
114 | |4 |14 | | | | 114 | |4 |12 | | |`D8` | | |
115 | |4 |15 | | | | 115 | |4 |13 | | |`D9` | | |
116 | |4 |16 | | | | 116 | |4 |14 | | | | | |
117 | |4 |15 | | | | | | ||
118 | |4 |16 | | | | | | ||
119 | |||
120 | <sup>¹ As of ChibiOS 20.3.4, the ADC driver for STM32F1xx devices supports only ADC1, therefore any configurations involving ADC2 or ADC3 cannot actually be used. In particular, pins `F6`…`F10`, which are present at least on some STM32F103x[C-G] devices, cannot be used as ADC inputs because of this driver limitation.</sup> | ||
121 | |||
122 | <sup>² Not all STM32F4xx devices have ADC2 and/or ADC3, therefore some configurations shown in this table may be unavailable; in particular, pins `F4`…`F10` cannot be used as ADC inputs on devices which do not have ADC3. Check the device datasheet to confirm which pin functions are supported.</sup> | ||
117 | 123 | ||
118 | ## Functions | 124 | ## Functions |
119 | 125 | ||
@@ -141,10 +147,10 @@ Also note that the F0 and F3 use different numbering schemes. The F0 has a singl | |||
141 | 147 | ||
142 | The ARM implementation of the ADC has a few additional options that you can override in your own keyboards and keymaps to change how it operates. Please consult the corresponding `hal_adc_lld.h` in ChibiOS for your specific microcontroller for further documentation on your available options. | 148 | The ARM implementation of the ADC has a few additional options that you can override in your own keyboards and keymaps to change how it operates. Please consult the corresponding `hal_adc_lld.h` in ChibiOS for your specific microcontroller for further documentation on your available options. |
143 | 149 | ||
144 | |`#define` |Type |Default |Description | | 150 | |`#define` |Type |Default |Description | |
145 | |---------------------|------|---------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | 151 | |---------------------|------|----------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| |
146 | |`ADC_CIRCULAR_BUFFER`|`bool`|`false` |If `true`, then the implementation will use a circular buffer. | | 152 | |`ADC_CIRCULAR_BUFFER`|`bool`|`false` |If `true`, then the implementation will use a circular buffer. | |
147 | |`ADC_NUM_CHANNELS` |`int` |`1` |Sets the number of channels that will be scanned as part of an ADC operation. The current implementation only supports `1`. | | 153 | |`ADC_NUM_CHANNELS` |`int` |`1` |Sets the number of channels that will be scanned as part of an ADC operation. The current implementation only supports `1`. | |
148 | |`ADC_BUFFER_DEPTH` |`int` |`2` |Sets the depth of each result. Since we are only getting a 12-bit result by default, we set this to 2 bytes so we can contain our one value. This could be set to 1 if you opt for an 8-bit or lower result.| | 154 | |`ADC_BUFFER_DEPTH` |`int` |`2` |Sets the depth of each result. Since we are only getting a 10-bit result by default, we set this to 2 bytes so we can contain our one value. This could be set to 1 if you opt for an 8-bit or lower result.| |
149 | |`ADC_SAMPLING_RATE` |`int` |`ADC_SMPR_SMP_1P5` |Sets the sampling rate of the ADC. By default, it is set to the fastest setting. | | 155 | |`ADC_SAMPLING_RATE` |`int` |`ADC_SMPR_SMP_1P5` |Sets the sampling rate of the ADC. By default, it is set to the fastest setting. | |
150 | |`ADC_RESOLUTION` |`int` |`ADC_CFGR1_RES_12BIT`|The resolution of your result. We choose 12 bit by default, but you can opt for 12, 10, 8, or 6 bit. | | 156 | |`ADC_RESOLUTION` |`int` |`ADC_CFGR1_RES_10BIT` or `ADC_CFGR_RES_10BITS`|The resolution of your result. We choose 10 bit by default, but you can opt for 12, 10, 8, or 6 bit. Different MCUs use slightly different names for the resolution constants. | |
diff --git a/docs/compatible_microcontrollers.md b/docs/compatible_microcontrollers.md index 47a4844e7..5e16ab277 100644 --- a/docs/compatible_microcontrollers.md +++ b/docs/compatible_microcontrollers.md | |||
@@ -28,6 +28,7 @@ You can also use any ARM chip with USB that [ChibiOS](https://www.chibios.org) s | |||
28 | * [STM32F303](https://www.st.com/en/microcontrollers-microprocessors/stm32f303.html) | 28 | * [STM32F303](https://www.st.com/en/microcontrollers-microprocessors/stm32f303.html) |
29 | * [STM32F401](https://www.st.com/en/microcontrollers-microprocessors/stm32f401.html) | 29 | * [STM32F401](https://www.st.com/en/microcontrollers-microprocessors/stm32f401.html) |
30 | * [STM32F411](https://www.st.com/en/microcontrollers-microprocessors/stm32f411.html) | 30 | * [STM32F411](https://www.st.com/en/microcontrollers-microprocessors/stm32f411.html) |
31 | * [STM32F446](https://www.st.com/en/microcontrollers-microprocessors/stm32f446.html) | ||
31 | * [STM32G431](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x1.html) | 32 | * [STM32G431](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x1.html) |
32 | * [STM32G474](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x4.html) | 33 | * [STM32G474](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x4.html) |
33 | 34 | ||
diff --git a/docs/feature_auto_shift.md b/docs/feature_auto_shift.md index 8e04d9dd3..ec7eeaaa0 100644 --- a/docs/feature_auto_shift.md +++ b/docs/feature_auto_shift.md | |||
@@ -109,6 +109,33 @@ Do not Auto Shift numeric keys, zero through nine. | |||
109 | 109 | ||
110 | Do not Auto Shift alpha characters, which include A through Z. | 110 | Do not Auto Shift alpha characters, which include A through Z. |
111 | 111 | ||
112 | ### Auto Shift Per Key | ||
113 | |||
114 | This is a function that allows you to determine which keys shold be autoshifted, much like the tap-hold keys. | ||
115 | |||
116 | The default function looks like this: | ||
117 | |||
118 | ```c | ||
119 | bool get_auto_shifted_key(uint16_t keycode, keyrecord_t *record) { | ||
120 | switch (keycode) { | ||
121 | # ifndef NO_AUTO_SHIFT_ALPHA | ||
122 | case KC_A ... KC_Z: | ||
123 | # endif | ||
124 | # ifndef NO_AUTO_SHIFT_NUMERIC | ||
125 | case KC_1 ... KC_0: | ||
126 | # endif | ||
127 | # ifndef NO_AUTO_SHIFT_SPECIAL | ||
128 | case KC_TAB: | ||
129 | case KC_MINUS ... KC_SLASH: | ||
130 | case KC_NONUS_BSLASH: | ||
131 | # endif | ||
132 | return true; | ||
133 | } | ||
134 | return false; | ||
135 | } | ||
136 | ``` | ||
137 | This functionality is enabled by default, and does not need a define. | ||
138 | |||
112 | ### AUTO_SHIFT_REPEAT (simple define) | 139 | ### AUTO_SHIFT_REPEAT (simple define) |
113 | 140 | ||
114 | Enables keyrepeat. | 141 | Enables keyrepeat. |
diff --git a/docs/feature_leader_key.md b/docs/feature_leader_key.md index 41ff8f1a4..f10bca758 100644 --- a/docs/feature_leader_key.md +++ b/docs/feature_leader_key.md | |||
@@ -72,6 +72,19 @@ SEQ_THREE_KEYS(KC_C, KC_C, KC_C) { | |||
72 | } | 72 | } |
73 | ``` | 73 | ``` |
74 | 74 | ||
75 | ## Infinite Leader key timeout | ||
76 | |||
77 | Sometimes your leader key is not on a comfortable places as the rest of keys on your sequence. Imagine that your leader key is one of your outer top right keys, you may need to reposition your hand just to reach your leader key. | ||
78 | This can make typing the entire sequence on time hard even if you are able to type most of the sequence fast. For example, if your sequence is `Leader + asd` typing `asd` fast is very easy once you have your hands in your home row. However starting the sequence in time after moving your hand out of the home row to reach the leader key and back is not. | ||
79 | To remove the stress this situation produces to your hands you can enable an infinite timeout just for the leader key. This mean that, after you hit the leader key you will have an infinite amount of time to start the rest of the sequence, allowing you to proper position your hands on the best position to type the rest of the sequence comfortably. | ||
80 | This infinite timeout only affects the leader key, so in our previous example of `Leader + asd` you will have an infinite amount of time between `Leader` and `a`, but once you start the sequence the timeout you have configured (global or per key) will work normally. | ||
81 | This way you can configure a very short `LEADER_TIMEOUT` but still have plenty of time to position your hands. | ||
82 | |||
83 | In order to enable this, place this in your `config.h`: | ||
84 | ```c | ||
85 | #define LEADER_NO_TIMEOUT | ||
86 | ``` | ||
87 | |||
75 | ## Strict Key Processing | 88 | ## Strict Key Processing |
76 | 89 | ||
77 | By default, the Leader Key feature will filter the keycode out of [`Mod-Tap`](mod_tap.md) and [`Layer Tap`](feature_layers.md#switching-and-toggling-layers) functions when checking for the Leader sequences. That means if you're using `LT(3, KC_A)`, it will pick this up as `KC_A` for the sequence, rather than `LT(3, KC_A)`, giving a more expected behavior for newer users. | 90 | By default, the Leader Key feature will filter the keycode out of [`Mod-Tap`](mod_tap.md) and [`Layer Tap`](feature_layers.md#switching-and-toggling-layers) functions when checking for the Leader sequences. That means if you're using `LT(3, KC_A)`, it will pick this up as `KC_A` for the sequence, rather than `LT(3, KC_A)`, giving a more expected behavior for newer users. |
diff --git a/docs/feature_led_matrix.md b/docs/feature_led_matrix.md index f4a661634..ac2be2e77 100644 --- a/docs/feature_led_matrix.md +++ b/docs/feature_led_matrix.md | |||
@@ -79,7 +79,7 @@ Custom layer effects can be done by defining this in your `<keyboard>.c`: | |||
79 | 79 | ||
80 | ```c | 80 | ```c |
81 | void led_matrix_indicators_kb(void) { | 81 | void led_matrix_indicators_kb(void) { |
82 | led_matrix_set_index_value(index, value); | 82 | led_matrix_set_value(index, value); |
83 | } | 83 | } |
84 | ``` | 84 | ``` |
85 | 85 | ||
diff --git a/docs/feature_rgb_matrix.md b/docs/feature_rgb_matrix.md index e996caddd..046b1f17f 100644 --- a/docs/feature_rgb_matrix.md +++ b/docs/feature_rgb_matrix.md | |||
@@ -447,6 +447,8 @@ These are defined in [`rgblight_list.h`](https://github.com/qmk/qmk_firmware/blo | |||
447 | #define RGB_MATRIX_STARTUP_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS // Sets the default brightness value, if none has been set | 447 | #define RGB_MATRIX_STARTUP_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS // Sets the default brightness value, if none has been set |
448 | #define RGB_MATRIX_STARTUP_SPD 127 // Sets the default animation speed, if none has been set | 448 | #define RGB_MATRIX_STARTUP_SPD 127 // Sets the default animation speed, if none has been set |
449 | #define RGB_MATRIX_DISABLE_KEYCODES // disables control of rgb matrix by keycodes (must use code functions to control the feature) | 449 | #define RGB_MATRIX_DISABLE_KEYCODES // disables control of rgb matrix by keycodes (must use code functions to control the feature) |
450 | #define RGB_MATRIX_SPLIT { X, Y } // (Optional) For split keyboards, the number of LEDs connected on each half. X = left, Y = Right. | ||
451 | // If RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is enabled, you also will want to enable SPLIT_TRANSPORT_MIRROR | ||
450 | ``` | 452 | ``` |
451 | 453 | ||
452 | ## EEPROM storage :id=eeprom-storage | 454 | ## EEPROM storage :id=eeprom-storage |
diff --git a/docs/feature_rgblight.md b/docs/feature_rgblight.md index d2612a6d1..8e8d6b81c 100644 --- a/docs/feature_rgblight.md +++ b/docs/feature_rgblight.md | |||
@@ -74,6 +74,7 @@ Changing the **Value** sets the overall brightness.<br> | |||
74 | |`RGB_MODE_XMAS` |`RGB_M_X` |Christmas animation mode | | 74 | |`RGB_MODE_XMAS` |`RGB_M_X` |Christmas animation mode | |
75 | |`RGB_MODE_GRADIENT`|`RGB_M_G` |Static gradient animation mode | | 75 | |`RGB_MODE_GRADIENT`|`RGB_M_G` |Static gradient animation mode | |
76 | |`RGB_MODE_RGBTEST` |`RGB_M_T` |Red, Green, Blue test animation mode | | 76 | |`RGB_MODE_RGBTEST` |`RGB_M_T` |Red, Green, Blue test animation mode | |
77 | |`RGB_MODE_TWINKLE` |`RGB_M_TW`|Twinkle animation mode | | ||
77 | 78 | ||
78 | !> By default, if you have both the RGB Light and the [RGB Matrix](feature_rgb_matrix.md) feature enabled, these keycodes will work for both features, at the same time. You can disable the keycode functionality by defining the `*_DISABLE_KEYCODES` option for the specific feature. | 79 | !> By default, if you have both the RGB Light and the [RGB Matrix](feature_rgb_matrix.md) feature enabled, these keycodes will work for both features, at the same time. You can disable the keycode functionality by defining the `*_DISABLE_KEYCODES` option for the specific feature. |
79 | 80 | ||
diff --git a/docs/feature_wpm.md b/docs/feature_wpm.md index 12dd08057..c8ec3a7f3 100644 --- a/docs/feature_wpm.md +++ b/docs/feature_wpm.md | |||
@@ -1,25 +1,62 @@ | |||
1 | # Word Per Minute (WPM) Calculcation | 1 | # Word Per Minute (WPM) Calculcation |
2 | 2 | ||
3 | The WPM feature uses time between keystrokes to compute a rolling average words | 3 | The WPM feature uses time between keystrokes to compute a rolling average words per minute rate and makes this available for various uses. |
4 | per minute rate and makes this available for various uses. | ||
5 | 4 | ||
6 | Enable the WPM system by adding this to your `rules.mk`: | 5 | Enable the WPM system by adding this to your `rules.mk`: |
7 | 6 | ||
8 | WPM_ENABLE = yes | 7 | WPM_ENABLE = yes |
9 | 8 | ||
10 | For split keyboards using soft serial, the computed WPM | 9 | For split keyboards using soft serial, the computed WPM score will be available on the master AND slave half. |
11 | score will be available on the master AND slave half. | ||
12 | 10 | ||
13 | ## Public Functions | 11 | ## Configuration |
14 | |||
15 | `uint8_t get_current_wpm(void);` | ||
16 | This function returns the current WPM as an unsigned integer. | ||
17 | 12 | ||
13 | |Define |Default | Description | | ||
14 | |-----------------------------|--------------|------------------------------------------------------------------------------------------| | ||
15 | |`WPM_SMOOTHING` |`0.0487` | Sets the smoothing to about 40 keystrokes | | ||
16 | |`WPM_ESTIMATED_WORD_SIZE` |`5` | This is the value used when estimating average word size (for regression and normal use) | | ||
17 | |`WPM_ALLOW_COUNT_REGRESSOIN` |_Not defined_ | If defined allows the WPM to be decreased when hitting Delete or Backspace | | ||
18 | ## Public Functions | ||
18 | 19 | ||
19 | ## Customized keys for WPM calc | 20 | |Function |Description | |
20 | 21 | |--------------------------|--------------------------------------------------| | |
21 | By default, the WPM score only includes letters, numbers, space and some | 22 | |`get_current_wpm(void)` | Returns the current WPM as a value between 0-255 | |
22 | punctuation. If you want to change the set of characters considered as part of | 23 | |`set_current_wpm(x)` | Sets the current WPM to `x` (between 0-255) | |
23 | the WPM calculation, you can implement `wpm_keycode_user(uint16_t keycode)` | 24 | |
24 | and return true for any characters you would like included in the calculation, | 25 | ## Callbacks |
25 | or false to not count that particular keycode. | 26 | |
27 | By default, the WPM score only includes letters, numbers, space and some punctuation. If you want to change the set of characters considered as part of the WPM calculation, you can implement your own `bool wpm_keycode_user(uint16_t keycode)` and return true for any characters you would like included in the calculation, or false to not count that particular keycode. | ||
28 | |||
29 | For instance, the default is: | ||
30 | |||
31 | ```c | ||
32 | bool wpm_keycode_user(uint16_t keycode) { | ||
33 | if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) || (keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX) || (keycode >= QK_MODS && keycode <= QK_MODS_MAX)) { | ||
34 | keycode = keycode & 0xFF; | ||
35 | } else if (keycode > 0xFF) { | ||
36 | keycode = 0; | ||
37 | } | ||
38 | if ((keycode >= KC_A && keycode <= KC_0) || (keycode >= KC_TAB && keycode <= KC_SLASH)) { | ||
39 | return true; | ||
40 | } | ||
41 | |||
42 | return false; | ||
43 | } | ||
44 | ``` | ||
45 | |||
46 | Additionally, if `WPM_ALLOW_COUNT_REGRESSION` is defined, there is the `uint8_t wpm_regress_count(uint16_t keycode)` function that allows you to decrease the WPM. This is useful if you want to be able to penalize certain keycodes (or even combinations). | ||
47 | |||
48 | __attribute__((weak)) uint8_t wpm_regress_count(uint16_t keycode) { | ||
49 | bool weak_modded = (keycode >= QK_LCTL && keycode < QK_LSFT) || (keycode >= QK_RCTL && keycode < QK_RSFT); | ||
50 | |||
51 | if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) || (keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX) || (keycode >= QK_MODS && keycode <= QK_MODS_MAX)) { | ||
52 | keycode = keycode & 0xFF; | ||
53 | } else if (keycode > 0xFF) { | ||
54 | keycode = 0; | ||
55 | } | ||
56 | if (((get_mods() | get_oneshot_mods()) & MOD_MASK_CTRL} || weak_modded) && (keycode == KC_DEL || keycode == KC_BSPC)) { | ||
57 | return WPM_ESTIMATED_WORD_SIZE; | ||
58 | } | ||
59 | if (keycode == KC_DEL || keycode == KC_BSPC) { | ||
60 | return 1; | ||
61 | } | ||
62 | } | ||
diff --git a/docs/flashing.md b/docs/flashing.md index 7804a6bad..83c97444e 100644 --- a/docs/flashing.md +++ b/docs/flashing.md | |||
@@ -249,3 +249,29 @@ Flashing sequence: | |||
249 | 2. Wait for the OS to detect the device | 249 | 2. Wait for the OS to detect the device |
250 | 3. Flash a .bin file | 250 | 3. Flash a .bin file |
251 | 4. Reset the device into application mode (may be done automatically) | 251 | 4. Reset the device into application mode (may be done automatically) |
252 | |||
253 | ## tinyuf2 | ||
254 | |||
255 | Keyboards may opt into supporting the tinyuf2 bootloader. This is currently only supported on the F411 blackpill. | ||
256 | |||
257 | The `rules.mk` setting for this bootloader is `tinyuf2`, and can be specified at the keymap or user level. | ||
258 | |||
259 | To ensure compatibility with the tinyuf2 bootloader, make sure this block is present in your `rules.mk`: | ||
260 | |||
261 | ```make | ||
262 | # Bootloader selection | ||
263 | BOOTLOADER = tinyuf2 | ||
264 | ``` | ||
265 | |||
266 | Compatible flashers: | ||
267 | |||
268 | * Any application able to copy a file from one place to another, such as _macOS Finder_ or _Windows Explorer_. | ||
269 | |||
270 | Flashing sequence: | ||
271 | |||
272 | 1. Enter the bootloader using any of the following methods: | ||
273 | * Tap the `RESET` keycode | ||
274 | * Double-tap the `nRST` button on the PCB. | ||
275 | 2. Wait for the OS to detect the device | ||
276 | 3. Copy the .uf2 file to the new USB disk | ||
277 | 4. Wait for the keyboard to become available | ||
diff --git a/docs/ja/compatible_microcontrollers.md b/docs/ja/compatible_microcontrollers.md index fdd11f14f..69da70f2c 100644 --- a/docs/ja/compatible_microcontrollers.md +++ b/docs/ja/compatible_microcontrollers.md | |||
@@ -33,6 +33,7 @@ QMK は十分な容量のフラッシュメモリを備えた USB 対応 AVR ま | |||
33 | * [STM32F303](https://www.st.com/en/microcontrollers-microprocessors/stm32f303.html) | 33 | * [STM32F303](https://www.st.com/en/microcontrollers-microprocessors/stm32f303.html) |
34 | * [STM32F401](https://www.st.com/en/microcontrollers-microprocessors/stm32f401.html) | 34 | * [STM32F401](https://www.st.com/en/microcontrollers-microprocessors/stm32f401.html) |
35 | * [STM32F411](https://www.st.com/en/microcontrollers-microprocessors/stm32f411.html) | 35 | * [STM32F411](https://www.st.com/en/microcontrollers-microprocessors/stm32f411.html) |
36 | * [STM32F446](https://www.st.com/en/microcontrollers-microprocessors/stm32f446.html) | ||
36 | * [STM32G431](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x1.html) | 37 | * [STM32G431](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x1.html) |
37 | * [STM32G474](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x4.html) | 38 | * [STM32G474](https://www.st.com/en/microcontrollers-microprocessors/stm32g4x4.html) |
38 | 39 | ||
diff --git a/docs/ja/feature_led_matrix.md b/docs/ja/feature_led_matrix.md index b73487ca6..62e22859f 100644 --- a/docs/ja/feature_led_matrix.md +++ b/docs/ja/feature_led_matrix.md | |||
@@ -76,7 +76,7 @@ I2C IS31FL3731 RGB コントローラを使ったアドレス指定可能な LED | |||
76 | カスタムレイヤー効果は `<keyboard>.c` 内で以下を定義することで行うことができます: | 76 | カスタムレイヤー効果は `<keyboard>.c` 内で以下を定義することで行うことができます: |
77 | 77 | ||
78 | void led_matrix_indicators_kb(void) { | 78 | void led_matrix_indicators_kb(void) { |
79 | led_matrix_set_index_value(index, value); | 79 | led_matrix_set_value(index, value); |
80 | } | 80 | } |
81 | 81 | ||
82 | 同様の関数がキーマップ内で `led_matrix_indicators_user` として動作します。 | 82 | 同様の関数がキーマップ内で `led_matrix_indicators_user` として動作します。 |
diff --git a/docs/keycodes.md b/docs/keycodes.md index 9acf8b683..f3c519b13 100644 --- a/docs/keycodes.md +++ b/docs/keycodes.md | |||
@@ -516,6 +516,9 @@ See also: [One Shot Keys](one_shot_keys.md) | |||
516 | |------------|----------------------------------| | 516 | |------------|----------------------------------| |
517 | |`OSM(mod)` |Hold `mod` for one keypress | | 517 | |`OSM(mod)` |Hold `mod` for one keypress | |
518 | |`OSL(layer)`|Switch to `layer` for one keypress| | 518 | |`OSL(layer)`|Switch to `layer` for one keypress| |
519 | |`OS_ON` |Turns One Shot keys on | | ||
520 | |`OS_OFF` |Turns One Shot keys off | | ||
521 | |`OS_TOGG` |Toggles One Shot keys status | | ||
519 | 522 | ||
520 | ## Space Cadet :id=space-cadet | 523 | ## Space Cadet :id=space-cadet |
521 | 524 | ||
diff --git a/docs/one_shot_keys.md b/docs/one_shot_keys.md index 9a082d7d6..9fc548629 100644 --- a/docs/one_shot_keys.md +++ b/docs/one_shot_keys.md | |||
@@ -17,6 +17,9 @@ You can control the behavior of one shot keys by defining these in `config.h`: | |||
17 | 17 | ||
18 | * `OSM(mod)` - Momentarily hold down *mod*. You must use the `MOD_*` keycodes as shown in [Mod Tap](mod_tap.md), not the `KC_*` codes. | 18 | * `OSM(mod)` - Momentarily hold down *mod*. You must use the `MOD_*` keycodes as shown in [Mod Tap](mod_tap.md), not the `KC_*` codes. |
19 | * `OSL(layer)` - momentary switch to *layer*. | 19 | * `OSL(layer)` - momentary switch to *layer*. |
20 | * `OS_ON` - Turns on One Shot keys. | ||
21 | * `OS_OFF` - Turns off One Shot keys. OSM act as regular mod keys, OSL act like `MO`. | ||
22 | * `ON_TOGG` - Toggles the one shot key status. | ||
20 | 23 | ||
21 | Sometimes, you want to activate a one-shot key as part of a macro or tap dance routine. | 24 | Sometimes, you want to activate a one-shot key as part of a macro or tap dance routine. |
22 | 25 | ||
diff --git a/docs/ws2812_driver.md b/docs/ws2812_driver.md index cca6827ec..e69400364 100644 --- a/docs/ws2812_driver.md +++ b/docs/ws2812_driver.md | |||
@@ -77,6 +77,25 @@ Configure the hardware via your config.h: | |||
77 | 77 | ||
78 | You must also turn on the SPI feature in your halconf.h and mcuconf.h | 78 | You must also turn on the SPI feature in your halconf.h and mcuconf.h |
79 | 79 | ||
80 | #### Circular Buffer Mode | ||
81 | Some boards may flicker while in the normal buffer mode. To fix this issue, circular buffer mode may be used to rectify the issue. | ||
82 | |||
83 | By default, the circular buffer mode is disabled. | ||
84 | |||
85 | To enable this alternative buffer mode, place this into your `config.h` file: | ||
86 | ```c | ||
87 | #define WS2812_SPI_USE_CIRCULAR_BUFFER | ||
88 | ``` | ||
89 | |||
90 | #### Setting baudrate with divisor | ||
91 | To adjust the baudrate at which the SPI peripheral is configured, users will need to derive the target baudrate from the clock tree provided by STM32CubeMX. | ||
92 | |||
93 | Only divisors of 2, 4, 8, 16, 32, 64, 128 and 256 are supported by hardware. | ||
94 | |||
95 | |Define |Default|Description | | ||
96 | |--------------------|-------|-------------------------------------| | ||
97 | |`WS2812_SPI_DIVISOR`|`16` |SPI source clock peripheral divisor | | ||
98 | |||
80 | #### Testing Notes | 99 | #### Testing Notes |
81 | 100 | ||
82 | While not an exhaustive list, the following table provides the scenarios that have been partially validated: | 101 | While not an exhaustive list, the following table provides the scenarios that have been partially validated: |
@@ -102,11 +121,14 @@ Configure the hardware via your config.h: | |||
102 | #define WS2812_PWM_DRIVER PWMD2 // default: PWMD2 | 121 | #define WS2812_PWM_DRIVER PWMD2 // default: PWMD2 |
103 | #define WS2812_PWM_CHANNEL 2 // default: 2 | 122 | #define WS2812_PWM_CHANNEL 2 // default: 2 |
104 | #define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2 | 123 | #define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2 |
124 | //#define WS2812_PWM_COMPLEMENTARY_OUTPUT // Define for a complementary timer output (TIMx_CHyN); omit for a normal timer output (TIMx_CHy). | ||
105 | #define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU. | 125 | #define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU. |
106 | #define WS2812_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU. | 126 | #define WS2812_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU. |
107 | #define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM2_UP // DMAMUX configuration for TIMx_UP -- only required if your MCU has a DMAMUX peripheral, see the respective reference manual for the appropriate values for your MCU. | 127 | #define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM2_UP // DMAMUX configuration for TIMx_UP -- only required if your MCU has a DMAMUX peripheral, see the respective reference manual for the appropriate values for your MCU. |
108 | ``` | 128 | ``` |
109 | 129 | ||
130 | Note that using a complementary timer output (TIMx_CHyN) is possible only for advanced-control timers (TIM1, TIM8, TIM20 on STM32), and the `STM32_PWM_USE_ADVANCED` option in mcuconf.h must be set to `TRUE`. Complementary outputs of general-purpose timers are not supported due to ChibiOS limitations. | ||
131 | |||
110 | You must also turn on the PWM feature in your halconf.h and mcuconf.h | 132 | You must also turn on the PWM feature in your halconf.h and mcuconf.h |
111 | 133 | ||
112 | #### Testing Notes | 134 | #### Testing Notes |
diff --git a/drivers/chibios/analog.c b/drivers/chibios/analog.c index 2b3872afb..b1081623d 100644 --- a/drivers/chibios/analog.c +++ b/drivers/chibios/analog.c | |||
@@ -101,7 +101,11 @@ | |||
101 | 101 | ||
102 | // Options are 12, 10, 8, and 6 bit. | 102 | // Options are 12, 10, 8, and 6 bit. |
103 | #ifndef ADC_RESOLUTION | 103 | #ifndef ADC_RESOLUTION |
104 | # define ADC_RESOLUTION ADC_CFGR1_RES_10BIT | 104 | # ifdef ADC_CFGR_RES_10BITS // ADCv3, ADCv4 |
105 | # define ADC_RESOLUTION ADC_CFGR_RES_10BITS | ||
106 | # else // ADCv1, ADCv5, or the bodge for ADCv2 above | ||
107 | # define ADC_RESOLUTION ADC_CFGR1_RES_10BIT | ||
108 | # endif | ||
105 | #endif | 109 | #endif |
106 | 110 | ||
107 | static ADCConfig adcCfg = {}; | 111 | static ADCConfig adcCfg = {}; |
@@ -161,8 +165,8 @@ __attribute__((weak)) adc_mux pinToMux(pin_t pin) { | |||
161 | case B0: return TO_MUX( ADC_CHANNEL_IN12, 2 ); | 165 | case B0: return TO_MUX( ADC_CHANNEL_IN12, 2 ); |
162 | case B1: return TO_MUX( ADC_CHANNEL_IN1, 2 ); | 166 | case B1: return TO_MUX( ADC_CHANNEL_IN1, 2 ); |
163 | case B2: return TO_MUX( ADC_CHANNEL_IN12, 1 ); | 167 | case B2: return TO_MUX( ADC_CHANNEL_IN12, 1 ); |
164 | case B12: return TO_MUX( ADC_CHANNEL_IN2, 3 ); | 168 | case B12: return TO_MUX( ADC_CHANNEL_IN3, 3 ); |
165 | case B13: return TO_MUX( ADC_CHANNEL_IN3, 3 ); | 169 | case B13: return TO_MUX( ADC_CHANNEL_IN5, 2 ); |
166 | case B14: return TO_MUX( ADC_CHANNEL_IN4, 3 ); | 170 | case B14: return TO_MUX( ADC_CHANNEL_IN4, 3 ); |
167 | case B15: return TO_MUX( ADC_CHANNEL_IN5, 3 ); | 171 | case B15: return TO_MUX( ADC_CHANNEL_IN5, 3 ); |
168 | case C0: return TO_MUX( ADC_CHANNEL_IN6, 0 ); // Can also be ADC2 | 172 | case C0: return TO_MUX( ADC_CHANNEL_IN6, 0 ); // Can also be ADC2 |
@@ -189,11 +193,52 @@ __attribute__((weak)) adc_mux pinToMux(pin_t pin) { | |||
189 | case E15: return TO_MUX( ADC_CHANNEL_IN2, 3 ); | 193 | case E15: return TO_MUX( ADC_CHANNEL_IN2, 3 ); |
190 | case F2: return TO_MUX( ADC_CHANNEL_IN10, 0 ); // Can also be ADC2 | 194 | case F2: return TO_MUX( ADC_CHANNEL_IN10, 0 ); // Can also be ADC2 |
191 | case F4: return TO_MUX( ADC_CHANNEL_IN5, 0 ); | 195 | case F4: return TO_MUX( ADC_CHANNEL_IN5, 0 ); |
192 | #elif defined(STM32F4XX) // TODO: add all pins | 196 | #elif defined(STM32F4XX) |
193 | case A0: return TO_MUX( ADC_CHANNEL_IN0, 0 ); | 197 | case A0: return TO_MUX( ADC_CHANNEL_IN0, 0 ); |
194 | //case A1: return TO_MUX( ADC_CHANNEL_IN1, 0 ); | 198 | case A1: return TO_MUX( ADC_CHANNEL_IN1, 0 ); |
195 | #elif defined(STM32F1XX) // TODO: add all pins | 199 | case A2: return TO_MUX( ADC_CHANNEL_IN2, 0 ); |
200 | case A3: return TO_MUX( ADC_CHANNEL_IN3, 0 ); | ||
201 | case A4: return TO_MUX( ADC_CHANNEL_IN4, 0 ); | ||
202 | case A5: return TO_MUX( ADC_CHANNEL_IN5, 0 ); | ||
203 | case A6: return TO_MUX( ADC_CHANNEL_IN6, 0 ); | ||
204 | case A7: return TO_MUX( ADC_CHANNEL_IN7, 0 ); | ||
205 | case B0: return TO_MUX( ADC_CHANNEL_IN8, 0 ); | ||
206 | case B1: return TO_MUX( ADC_CHANNEL_IN9, 0 ); | ||
207 | case C0: return TO_MUX( ADC_CHANNEL_IN10, 0 ); | ||
208 | case C1: return TO_MUX( ADC_CHANNEL_IN11, 0 ); | ||
209 | case C2: return TO_MUX( ADC_CHANNEL_IN12, 0 ); | ||
210 | case C3: return TO_MUX( ADC_CHANNEL_IN13, 0 ); | ||
211 | case C4: return TO_MUX( ADC_CHANNEL_IN14, 0 ); | ||
212 | case C5: return TO_MUX( ADC_CHANNEL_IN15, 0 ); | ||
213 | # if STM32_ADC_USE_ADC3 | ||
214 | case F3: return TO_MUX( ADC_CHANNEL_IN9, 2 ); | ||
215 | case F4: return TO_MUX( ADC_CHANNEL_IN14, 2 ); | ||
216 | case F5: return TO_MUX( ADC_CHANNEL_IN15, 2 ); | ||
217 | case F6: return TO_MUX( ADC_CHANNEL_IN4, 2 ); | ||
218 | case F7: return TO_MUX( ADC_CHANNEL_IN5, 2 ); | ||
219 | case F8: return TO_MUX( ADC_CHANNEL_IN6, 2 ); | ||
220 | case F9: return TO_MUX( ADC_CHANNEL_IN7, 2 ); | ||
221 | case F10: return TO_MUX( ADC_CHANNEL_IN8, 2 ); | ||
222 | # endif | ||
223 | #elif defined(STM32F1XX) | ||
196 | case A0: return TO_MUX( ADC_CHANNEL_IN0, 0 ); | 224 | case A0: return TO_MUX( ADC_CHANNEL_IN0, 0 ); |
225 | case A1: return TO_MUX( ADC_CHANNEL_IN1, 0 ); | ||
226 | case A2: return TO_MUX( ADC_CHANNEL_IN2, 0 ); | ||
227 | case A3: return TO_MUX( ADC_CHANNEL_IN3, 0 ); | ||
228 | case A4: return TO_MUX( ADC_CHANNEL_IN4, 0 ); | ||
229 | case A5: return TO_MUX( ADC_CHANNEL_IN5, 0 ); | ||
230 | case A6: return TO_MUX( ADC_CHANNEL_IN6, 0 ); | ||
231 | case A7: return TO_MUX( ADC_CHANNEL_IN7, 0 ); | ||
232 | case B0: return TO_MUX( ADC_CHANNEL_IN8, 0 ); | ||
233 | case B1: return TO_MUX( ADC_CHANNEL_IN9, 0 ); | ||
234 | case C0: return TO_MUX( ADC_CHANNEL_IN10, 0 ); | ||
235 | case C1: return TO_MUX( ADC_CHANNEL_IN11, 0 ); | ||
236 | case C2: return TO_MUX( ADC_CHANNEL_IN12, 0 ); | ||
237 | case C3: return TO_MUX( ADC_CHANNEL_IN13, 0 ); | ||
238 | case C4: return TO_MUX( ADC_CHANNEL_IN14, 0 ); | ||
239 | case C5: return TO_MUX( ADC_CHANNEL_IN15, 0 ); | ||
240 | // STM32F103x[C-G] in 144-pin packages also have analog inputs on F6...F10, but they are on ADC3, and the | ||
241 | // ChibiOS ADC driver for STM32F1xx currently supports only ADC1, therefore these pins are not usable. | ||
197 | #endif | 242 | #endif |
198 | } | 243 | } |
199 | 244 | ||
diff --git a/drivers/chibios/ws2812_pwm.c b/drivers/chibios/ws2812_pwm.c index 140120d48..e6af55b6b 100644 --- a/drivers/chibios/ws2812_pwm.c +++ b/drivers/chibios/ws2812_pwm.c | |||
@@ -27,6 +27,15 @@ | |||
27 | # error "please consult your MCU's datasheet and specify in your config.h: #define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM?_UP" | 27 | # error "please consult your MCU's datasheet and specify in your config.h: #define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM?_UP" |
28 | #endif | 28 | #endif |
29 | 29 | ||
30 | #ifndef WS2812_PWM_COMPLEMENTARY_OUTPUT | ||
31 | # define WS2812_PWM_OUTPUT_MODE PWM_OUTPUT_ACTIVE_HIGH | ||
32 | #else | ||
33 | # if !STM32_PWM_USE_ADVANCED | ||
34 | # error "WS2812_PWM_COMPLEMENTARY_OUTPUT requires STM32_PWM_USE_ADVANCED == TRUE" | ||
35 | # endif | ||
36 | # define WS2812_PWM_OUTPUT_MODE PWM_COMPLEMENTARY_OUTPUT_ACTIVE_HIGH | ||
37 | #endif | ||
38 | |||
30 | // Push Pull or Open Drain Configuration | 39 | // Push Pull or Open Drain Configuration |
31 | // Default Push Pull | 40 | // Default Push Pull |
32 | #ifndef WS2812_EXTERNAL_PULLUP | 41 | #ifndef WS2812_EXTERNAL_PULLUP |
@@ -247,7 +256,7 @@ void ws2812_init(void) { | |||
247 | .channels = | 256 | .channels = |
248 | { | 257 | { |
249 | [0 ... 3] = {.mode = PWM_OUTPUT_DISABLED, .callback = NULL}, // Channels default to disabled | 258 | [0 ... 3] = {.mode = PWM_OUTPUT_DISABLED, .callback = NULL}, // Channels default to disabled |
250 | [WS2812_PWM_CHANNEL - 1] = {.mode = PWM_OUTPUT_ACTIVE_HIGH, .callback = NULL}, // Turn on the channel we care about | 259 | [WS2812_PWM_CHANNEL - 1] = {.mode = WS2812_PWM_OUTPUT_MODE, .callback = NULL}, // Turn on the channel we care about |
251 | }, | 260 | }, |
252 | .cr2 = 0, | 261 | .cr2 = 0, |
253 | .dier = TIM_DIER_UDE, // DMA on update event for next period | 262 | .dier = TIM_DIER_UDE, // DMA on update event for next period |
diff --git a/drivers/chibios/ws2812_spi.c b/drivers/chibios/ws2812_spi.c index 89df2987b..e02cbabc0 100644 --- a/drivers/chibios/ws2812_spi.c +++ b/drivers/chibios/ws2812_spi.c | |||
@@ -32,6 +32,37 @@ | |||
32 | # endif | 32 | # endif |
33 | #endif | 33 | #endif |
34 | 34 | ||
35 | // Define SPI config speed | ||
36 | // baudrate should target 3.2MHz | ||
37 | // F072 fpclk = 48MHz | ||
38 | // 48/16 = 3Mhz | ||
39 | #if WS2812_SPI_DIVISOR == 2 | ||
40 | # define WS2812_SPI_DIVISOR (0) | ||
41 | #elif WS2812_SPI_DIVISOR == 4 | ||
42 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_0) | ||
43 | #elif WS2812_SPI_DIVISOR == 8 | ||
44 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_1) | ||
45 | #elif WS2812_SPI_DIVISOR == 16 // same as default | ||
46 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_1 | SPI_CR1_BR_0) | ||
47 | #elif WS2812_SPI_DIVISOR == 32 | ||
48 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_2) | ||
49 | #elif WS2812_SPI_DIVISOR == 64 | ||
50 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_2 | SPI_CR1_BR_0) | ||
51 | #elif WS2812_SPI_DIVISOR == 128 | ||
52 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_2 | SPI_CR1_BR_1) | ||
53 | #elif WS2812_SPI_DIVISOR == 256 | ||
54 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_2 | SPI_CR1_BR_1 | SPI_CR1_BR_0) | ||
55 | #else | ||
56 | # define WS2812_SPI_DIVISOR (SPI_CR1_BR_1 | SPI_CR1_BR_0) // default | ||
57 | #endif | ||
58 | |||
59 | // Use SPI circular buffer | ||
60 | #ifdef WS2812_SPI_USE_CIRCULAR_BUFFER | ||
61 | # define WS2812_SPI_BUFFER_MODE 1 // circular buffer | ||
62 | #else | ||
63 | # define WS2812_SPI_BUFFER_MODE 0 // normal buffer | ||
64 | #endif | ||
65 | |||
35 | #define BYTES_FOR_LED_BYTE 4 | 66 | #define BYTES_FOR_LED_BYTE 4 |
36 | #define NB_COLORS 3 | 67 | #define NB_COLORS 3 |
37 | #define BYTES_FOR_LED (BYTES_FOR_LED_BYTE * NB_COLORS) | 68 | #define BYTES_FOR_LED (BYTES_FOR_LED_BYTE * NB_COLORS) |
@@ -81,14 +112,14 @@ void ws2812_init(void) { | |||
81 | palSetLineMode(RGB_DI_PIN, WS2812_OUTPUT_MODE); | 112 | palSetLineMode(RGB_DI_PIN, WS2812_OUTPUT_MODE); |
82 | 113 | ||
83 | // TODO: more dynamic baudrate | 114 | // TODO: more dynamic baudrate |
84 | static const SPIConfig spicfg = { | 115 | static const SPIConfig spicfg = {WS2812_SPI_BUFFER_MODE, NULL, PAL_PORT(RGB_DI_PIN), PAL_PAD(RGB_DI_PIN), WS2812_SPI_DIVISOR}; |
85 | 0, NULL, PAL_PORT(RGB_DI_PIN), PAL_PAD(RGB_DI_PIN), | ||
86 | SPI_CR1_BR_1 | SPI_CR1_BR_0 // baudrate : fpclk / 8 => 1tick is 0.32us (2.25 MHz) | ||
87 | }; | ||
88 | 116 | ||
89 | spiAcquireBus(&WS2812_SPI); /* Acquire ownership of the bus. */ | 117 | spiAcquireBus(&WS2812_SPI); /* Acquire ownership of the bus. */ |
90 | spiStart(&WS2812_SPI, &spicfg); /* Setup transfer parameters. */ | 118 | spiStart(&WS2812_SPI, &spicfg); /* Setup transfer parameters. */ |
91 | spiSelect(&WS2812_SPI); /* Slave Select assertion. */ | 119 | spiSelect(&WS2812_SPI); /* Slave Select assertion. */ |
120 | #ifdef WS2812_SPI_USE_CIRCULAR_BUFFER | ||
121 | spiStartSend(&WS2812_SPI, sizeof(txbuf) / sizeof(txbuf[0]), txbuf); | ||
122 | #endif | ||
92 | } | 123 | } |
93 | 124 | ||
94 | void ws2812_setleds(LED_TYPE* ledarray, uint16_t leds) { | 125 | void ws2812_setleds(LED_TYPE* ledarray, uint16_t leds) { |
@@ -104,9 +135,11 @@ void ws2812_setleds(LED_TYPE* ledarray, uint16_t leds) { | |||
104 | 135 | ||
105 | // Send async - each led takes ~0.03ms, 50 leds ~1.5ms, animations flushing faster than send will cause issues. | 136 | // Send async - each led takes ~0.03ms, 50 leds ~1.5ms, animations flushing faster than send will cause issues. |
106 | // Instead spiSend can be used to send synchronously (or the thread logic can be added back). | 137 | // Instead spiSend can be used to send synchronously (or the thread logic can be added back). |
107 | #ifdef WS2812_SPI_SYNC | 138 | #ifndef WS2812_SPI_USE_CIRCULAR_BUFFER |
139 | # ifdef WS2812_SPI_SYNC | ||
108 | spiSend(&WS2812_SPI, sizeof(txbuf) / sizeof(txbuf[0]), txbuf); | 140 | spiSend(&WS2812_SPI, sizeof(txbuf) / sizeof(txbuf[0]), txbuf); |
109 | #else | 141 | # else |
110 | spiStartSend(&WS2812_SPI, sizeof(txbuf) / sizeof(txbuf[0]), txbuf); | 142 | spiStartSend(&WS2812_SPI, sizeof(txbuf) / sizeof(txbuf[0]), txbuf); |
143 | # endif | ||
111 | #endif | 144 | #endif |
112 | } | 145 | } |
diff --git a/drivers/oled/oled_driver.c b/drivers/oled/oled_driver.c index 92c64399e..6c1238cd6 100644 --- a/drivers/oled/oled_driver.c +++ b/drivers/oled/oled_driver.c | |||
@@ -24,6 +24,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
24 | 24 | ||
25 | #include "progmem.h" | 25 | #include "progmem.h" |
26 | 26 | ||
27 | #include "keyboard.h" | ||
28 | |||
27 | // Used commands from spec sheet: https://cdn-shop.adafruit.com/datasheets/SSD1306.pdf | 29 | // Used commands from spec sheet: https://cdn-shop.adafruit.com/datasheets/SSD1306.pdf |
28 | // for SH1106: https://www.velleman.eu/downloads/29/infosheets/sh1106_datasheet.pdf | 30 | // for SH1106: https://www.velleman.eu/downloads/29/infosheets/sh1106_datasheet.pdf |
29 | 31 | ||
@@ -152,6 +154,12 @@ static void InvertCharacter(uint8_t *cursor) { | |||
152 | } | 154 | } |
153 | 155 | ||
154 | bool oled_init(uint8_t rotation) { | 156 | bool oled_init(uint8_t rotation) { |
157 | #if defined(USE_I2C) && defined(SPLIT_KEYBOARD) | ||
158 | if (!is_keyboard_master()) { | ||
159 | return true; | ||
160 | } | ||
161 | #endif | ||
162 | |||
155 | oled_rotation = oled_init_user(rotation); | 163 | oled_rotation = oled_init_user(rotation); |
156 | if (!HAS_FLAGS(oled_rotation, OLED_ROTATION_90)) { | 164 | if (!HAS_FLAGS(oled_rotation, OLED_ROTATION_90)) { |
157 | oled_rotation_width = OLED_DISPLAY_WIDTH; | 165 | oled_rotation_width = OLED_DISPLAY_WIDTH; |
diff --git a/drivers/oled/oled_driver.h b/drivers/oled/oled_driver.h index 72ab21247..00896f01c 100644 --- a/drivers/oled/oled_driver.h +++ b/drivers/oled/oled_driver.h | |||
@@ -158,6 +158,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
158 | # define OLED_I2C_TIMEOUT 100 | 158 | # define OLED_I2C_TIMEOUT 100 |
159 | #endif | 159 | #endif |
160 | 160 | ||
161 | #if !defined(OLED_UPDATE_INTERVAL) && defined(SPLIT_KEYBOARD) | ||
162 | # define OLED_UPDATE_INTERVAL 50 | ||
163 | #endif | ||
164 | |||
161 | typedef struct __attribute__((__packed__)) { | 165 | typedef struct __attribute__((__packed__)) { |
162 | uint8_t *current_element; | 166 | uint8_t *current_element; |
163 | uint16_t remaining_element_count; | 167 | uint16_t remaining_element_count; |
diff --git a/keyboards/1upkeyboards/sweet16/rules.mk b/keyboards/1upkeyboards/sweet16/rules.mk index d7e57eb33..22f9c36e6 100644 --- a/keyboards/1upkeyboards/sweet16/rules.mk +++ b/keyboards/1upkeyboards/sweet16/rules.mk | |||
@@ -1,7 +1,7 @@ | |||
1 | # Build Options | 1 | # Build Options |
2 | # | 2 | # |
3 | DEFAULT_FOLDER = 1upkeyboards/sweet16/v1 | 3 | DEFAULT_FOLDER = 1upkeyboards/sweet16/v1 |
4 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 4 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
5 | MOUSEKEY_ENABLE = yes # Mouse keys | 5 | MOUSEKEY_ENABLE = yes # Mouse keys |
6 | EXTRAKEY_ENABLE = yes # Audio control and System control | 6 | EXTRAKEY_ENABLE = yes # Audio control and System control |
7 | CONSOLE_ENABLE = no # Console for debug | 7 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/40percentclub/gherkin/rules.mk b/keyboards/40percentclub/gherkin/rules.mk index db971e00e..18a35b275 100644 --- a/keyboards/40percentclub/gherkin/rules.mk +++ b/keyboards/40percentclub/gherkin/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/40percentclub/luddite/rules.mk b/keyboards/40percentclub/luddite/rules.mk index 6da5cd05a..3e42dddd6 100644 --- a/keyboards/40percentclub/luddite/rules.mk +++ b/keyboards/40percentclub/luddite/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/40percentclub/tomato/rules.mk b/keyboards/40percentclub/tomato/rules.mk index 312134b7c..80b40c719 100644 --- a/keyboards/40percentclub/tomato/rules.mk +++ b/keyboards/40percentclub/tomato/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/40percentclub/ut47/rules.mk b/keyboards/40percentclub/ut47/rules.mk index 50868429a..3c8a8f68f 100644 --- a/keyboards/40percentclub/ut47/rules.mk +++ b/keyboards/40percentclub/ut47/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/acheron/arctic/rules.mk b/keyboards/acheron/arctic/rules.mk index 5edab2afe..4a6aa0a4a 100644 --- a/keyboards/acheron/arctic/rules.mk +++ b/keyboards/acheron/arctic/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/acheron/austin/rules.mk b/keyboards/acheron/austin/rules.mk index 6796ab140..b73c2cf7c 100644 --- a/keyboards/acheron/austin/rules.mk +++ b/keyboards/acheron/austin/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/acheron/keebspcb/rules.mk b/keyboards/acheron/keebspcb/rules.mk index b08ad400c..849a137cd 100644 --- a/keyboards/acheron/keebspcb/rules.mk +++ b/keyboards/acheron/keebspcb/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/acheron/lasgweloth/rules.mk b/keyboards/acheron/lasgweloth/rules.mk index 6bfb44ee9..56b91b692 100644 --- a/keyboards/acheron/lasgweloth/rules.mk +++ b/keyboards/acheron/lasgweloth/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/acheron/shark/rules.mk b/keyboards/acheron/shark/rules.mk index 04f2a7b94..94accbd8f 100644 --- a/keyboards/acheron/shark/rules.mk +++ b/keyboards/acheron/shark/rules.mk | |||
@@ -5,7 +5,7 @@ BOARD = QMK_PROTON_C | |||
5 | # Build Options | 5 | # Build Options |
6 | # change yes to no to disable | 6 | # change yes to no to disable |
7 | # | 7 | # |
8 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 8 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
9 | MOUSEKEY_ENABLE = yes # Mouse keys | 9 | MOUSEKEY_ENABLE = yes # Mouse keys |
10 | EXTRAKEY_ENABLE = yes # Audio control and System control | 10 | EXTRAKEY_ENABLE = yes # Audio control and System control |
11 | CONSOLE_ENABLE = yes # Console for debug | 11 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/acr60/rules.mk b/keyboards/acr60/rules.mk index c1f1f22ba..22fd09140 100644 --- a/keyboards/acr60/rules.mk +++ b/keyboards/acr60/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/aeboards/ext65/rev2/config.h b/keyboards/aeboards/ext65/rev2/config.h index 541f07ee9..dc1bfb71c 100644 --- a/keyboards/aeboards/ext65/rev2/config.h +++ b/keyboards/aeboards/ext65/rev2/config.h | |||
@@ -74,3 +74,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
74 | #define BACKLIGHT_LEVELS 6 | 74 | #define BACKLIGHT_LEVELS 6 |
75 | #define BACKLIGHT_BREATHING | 75 | #define BACKLIGHT_BREATHING |
76 | #define BREATHING_PERIOD 6 | 76 | #define BREATHING_PERIOD 6 |
77 | |||
78 | #define SLEEP_LED_GPT_DRIVER GPTD1 | ||
diff --git a/keyboards/aeboards/ext65/rev2/halconf.h b/keyboards/aeboards/ext65/rev2/halconf.h index 6e2f53640..9fa1eca60 100644 --- a/keyboards/aeboards/ext65/rev2/halconf.h +++ b/keyboards/aeboards/ext65/rev2/halconf.h | |||
@@ -27,5 +27,7 @@ | |||
27 | 27 | ||
28 | #define HAL_USE_SPI TRUE | 28 | #define HAL_USE_SPI TRUE |
29 | 29 | ||
30 | #define HAL_USE_GPT TRUE | ||
31 | |||
30 | #include_next <halconf.h> | 32 | #include_next <halconf.h> |
31 | 33 | ||
diff --git a/keyboards/aeboards/ext65/rev2/mcuconf.h b/keyboards/aeboards/ext65/rev2/mcuconf.h index 26ce80615..43d53d4f2 100644 --- a/keyboards/aeboards/ext65/rev2/mcuconf.h +++ b/keyboards/aeboards/ext65/rev2/mcuconf.h | |||
@@ -32,3 +32,5 @@ | |||
32 | #undef STM32_SPI_USE_SPI2 | 32 | #undef STM32_SPI_USE_SPI2 |
33 | #define STM32_SPI_USE_SPI2 TRUE | 33 | #define STM32_SPI_USE_SPI2 TRUE |
34 | 34 | ||
35 | #undef STM32_GPT_USE_TIM1 | ||
36 | #define STM32_GPT_USE_TIM1 TRUE | ||
diff --git a/keyboards/alf/x2/rules.mk b/keyboards/alf/x2/rules.mk index c1f1f22ba..22fd09140 100644 --- a/keyboards/alf/x2/rules.mk +++ b/keyboards/alf/x2/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/alpha/rules.mk b/keyboards/alpha/rules.mk index 773655f2f..dceb6e307 100755 --- a/keyboards/alpha/rules.mk +++ b/keyboards/alpha/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/alpine65/rules.mk b/keyboards/alpine65/rules.mk index 56ee0e25b..4f9422096 100644 --- a/keyboards/alpine65/rules.mk +++ b/keyboards/alpine65/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/alu84/rules.mk b/keyboards/alu84/rules.mk index 81dbad070..8d1652171 100755 --- a/keyboards/alu84/rules.mk +++ b/keyboards/alu84/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/at101_bh/rules.mk b/keyboards/at101_bh/rules.mk index 1930d9f27..af0606f6d 100644 --- a/keyboards/at101_bh/rules.mk +++ b/keyboards/at101_bh/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/at_at/660m/rules.mk b/keyboards/at_at/660m/rules.mk index a94604fb0..a272f6d34 100644 --- a/keyboards/at_at/660m/rules.mk +++ b/keyboards/at_at/660m/rules.mk | |||
@@ -6,7 +6,7 @@ BOARD = GENERIC_STM32_F072XB | |||
6 | # comment out to disable the options. | 6 | # comment out to disable the options. |
7 | # | 7 | # |
8 | 8 | ||
9 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = yes # Mouse keys | 10 | MOUSEKEY_ENABLE = yes # Mouse keys |
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/bantam44/rules.mk b/keyboards/bantam44/rules.mk index d90f8155e..e0fbf5a8c 100644 --- a/keyboards/bantam44/rules.mk +++ b/keyboards/bantam44/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/beatervan/rules.mk b/keyboards/beatervan/rules.mk index 1ea4a84d5..fd23f3301 100644 --- a/keyboards/beatervan/rules.mk +++ b/keyboards/beatervan/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = caterina | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/bfake/rules.mk b/keyboards/bfake/rules.mk index 5846b173b..c25b22249 100644 --- a/keyboards/bfake/rules.mk +++ b/keyboards/bfake/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32a | |||
12 | BOOTLOADER = bootloadHID | 12 | BOOTLOADER = bootloadHID |
13 | 13 | ||
14 | # build options | 14 | # build options |
15 | BOOTMAGIC_ENABLE = yes | 15 | BOOTMAGIC_ENABLE = full |
16 | MOUSEKEY_ENABLE = yes | 16 | MOUSEKEY_ENABLE = yes |
17 | EXTRAKEY_ENABLE = yes | 17 | EXTRAKEY_ENABLE = yes |
18 | CONSOLE_ENABLE = no | 18 | CONSOLE_ENABLE = no |
diff --git a/keyboards/blackplum/rules.mk b/keyboards/blackplum/rules.mk index 6465dec7f..76aeee6ec 100644 --- a/keyboards/blackplum/rules.mk +++ b/keyboards/blackplum/rules.mk | |||
@@ -13,7 +13,7 @@ BOOTLOADER = qmk-dfu | |||
13 | # Build Options | 13 | # Build Options |
14 | # comment out to disable the options. | 14 | # comment out to disable the options. |
15 | # | 15 | # |
16 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 16 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
17 | MOUSEKEY_ENABLE = yes # Mouse keys | 17 | MOUSEKEY_ENABLE = yes # Mouse keys |
18 | EXTRAKEY_ENABLE = yes # Audio control and System control | 18 | EXTRAKEY_ENABLE = yes # Audio control and System control |
19 | CONSOLE_ENABLE = no # Console for debug | 19 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/boston/rules.mk b/keyboards/boston/rules.mk index 47dc20576..e7bc2db59 100644 --- a/keyboards/boston/rules.mk +++ b/keyboards/boston/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = no # Mouse keys | 8 | MOUSEKEY_ENABLE = no # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = no # Console for debug | 10 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/box75/rules.mk b/keyboards/box75/rules.mk index 2d2f71e19..a202eca61 100644 --- a/keyboards/box75/rules.mk +++ b/keyboards/box75/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/bpiphany/pegasushoof/keymaps/blowrak/rules.mk b/keyboards/bpiphany/pegasushoof/keymaps/blowrak/rules.mk index 8254a8389..a605a865e 100644 --- a/keyboards/bpiphany/pegasushoof/keymaps/blowrak/rules.mk +++ b/keyboards/bpiphany/pegasushoof/keymaps/blowrak/rules.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # change to "no" to disable the options, or define them in the Makefile in | 2 | # change to "no" to disable the options, or define them in the Makefile in |
3 | # the appropriate keymap folder that will get included automatically | 3 | # the appropriate keymap folder that will get included automatically |
4 | # | 4 | # |
5 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 5 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
6 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 6 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
8 | CONSOLE_ENABLE = yes # Console for debug(+400) | 8 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/bpiphany/pegasushoof/keymaps/default/rules.mk b/keyboards/bpiphany/pegasushoof/keymaps/default/rules.mk index d6ebcd5d7..972b7fc71 100644 --- a/keyboards/bpiphany/pegasushoof/keymaps/default/rules.mk +++ b/keyboards/bpiphany/pegasushoof/keymaps/default/rules.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # change to "no" to disable the options, or define them in the Makefile in | 2 | # change to "no" to disable the options, or define them in the Makefile in |
3 | # the appropriate keymap folder that will get included automatically | 3 | # the appropriate keymap folder that will get included automatically |
4 | # | 4 | # |
5 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 5 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
6 | MOUSEKEY_ENABLE = yes # Mouse keys | 6 | MOUSEKEY_ENABLE = yes # Mouse keys |
7 | EXTRAKEY_ENABLE = yes # Audio control and System control | 7 | EXTRAKEY_ENABLE = yes # Audio control and System control |
8 | CONSOLE_ENABLE = yes # Console for debug | 8 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/bpiphany/pegasushoof/keymaps/default_jis/rules.mk b/keyboards/bpiphany/pegasushoof/keymaps/default_jis/rules.mk index 8254a8389..a605a865e 100644 --- a/keyboards/bpiphany/pegasushoof/keymaps/default_jis/rules.mk +++ b/keyboards/bpiphany/pegasushoof/keymaps/default_jis/rules.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # change to "no" to disable the options, or define them in the Makefile in | 2 | # change to "no" to disable the options, or define them in the Makefile in |
3 | # the appropriate keymap folder that will get included automatically | 3 | # the appropriate keymap folder that will get included automatically |
4 | # | 4 | # |
5 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 5 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
6 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 6 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
8 | CONSOLE_ENABLE = yes # Console for debug(+400) | 8 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/bpiphany/pegasushoof/rules.mk b/keyboards/bpiphany/pegasushoof/rules.mk index ffb642a9c..ffc4fc0e8 100644 --- a/keyboards/bpiphany/pegasushoof/rules.mk +++ b/keyboards/bpiphany/pegasushoof/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/bpiphany/unloved_bastard/rules.mk b/keyboards/bpiphany/unloved_bastard/rules.mk index b211fa5e9..d6c3d6232 100644 --- a/keyboards/bpiphany/unloved_bastard/rules.mk +++ b/keyboards/bpiphany/unloved_bastard/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/cannonkeys/an_c/rules.mk b/keyboards/cannonkeys/an_c/rules.mk index 8ed2d0ead..7309744d1 100644 --- a/keyboards/cannonkeys/an_c/rules.mk +++ b/keyboards/cannonkeys/an_c/rules.mk | |||
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys | |||
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
13 | COMMAND_ENABLE = yes # Commands for debug and configuration | 13 | COMMAND_ENABLE = yes # Commands for debug and configuration |
14 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 14 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
15 | NKRO_ENABLE = yes # USB Nkey Rollover | 15 | NKRO_ENABLE = yes # USB Nkey Rollover |
16 | CUSTOM_MATRIX = no # Custom matrix file | 16 | CUSTOM_MATRIX = no # Custom matrix file |
17 | BACKLIGHT_ENABLE = yes | 17 | BACKLIGHT_ENABLE = yes |
diff --git a/keyboards/cannonkeys/chimera65/rules.mk b/keyboards/cannonkeys/chimera65/rules.mk index 4d940da78..a08f2fa49 100644 --- a/keyboards/cannonkeys/chimera65/rules.mk +++ b/keyboards/cannonkeys/chimera65/rules.mk | |||
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys | |||
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
13 | COMMAND_ENABLE = yes # Commands for debug and configuration | 13 | COMMAND_ENABLE = yes # Commands for debug and configuration |
14 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 14 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
15 | NKRO_ENABLE = yes # USB Nkey Rollover | 15 | NKRO_ENABLE = yes # USB Nkey Rollover |
16 | CUSTOM_MATRIX = no # Custom matrix file | 16 | CUSTOM_MATRIX = no # Custom matrix file |
17 | BACKLIGHT_ENABLE = yes | 17 | BACKLIGHT_ENABLE = yes |
diff --git a/keyboards/cannonkeys/instant60/rules.mk b/keyboards/cannonkeys/instant60/rules.mk index 0973ad954..e5ba2903b 100644 --- a/keyboards/cannonkeys/instant60/rules.mk +++ b/keyboards/cannonkeys/instant60/rules.mk | |||
@@ -10,7 +10,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys | |||
10 | EXTRAKEY_ENABLE = yes # Audio control and System control | 10 | EXTRAKEY_ENABLE = yes # Audio control and System control |
11 | CONSOLE_ENABLE = yes # Console for debug | 11 | CONSOLE_ENABLE = yes # Console for debug |
12 | COMMAND_ENABLE = yes # Commands for debug and configuration | 12 | COMMAND_ENABLE = yes # Commands for debug and configuration |
13 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 13 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
14 | NKRO_ENABLE = yes # USB Nkey Rollover | 14 | NKRO_ENABLE = yes # USB Nkey Rollover |
15 | CUSTOM_MATRIX = no # Custom matrix file | 15 | CUSTOM_MATRIX = no # Custom matrix file |
16 | BACKLIGHT_ENABLE = yes | 16 | BACKLIGHT_ENABLE = yes |
diff --git a/keyboards/cannonkeys/iron165/rules.mk b/keyboards/cannonkeys/iron165/rules.mk index 3925458dd..9de75a614 100644 --- a/keyboards/cannonkeys/iron165/rules.mk +++ b/keyboards/cannonkeys/iron165/rules.mk | |||
@@ -9,7 +9,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys | |||
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
11 | COMMAND_ENABLE = yes # Commands for debug and configuration | 11 | COMMAND_ENABLE = yes # Commands for debug and configuration |
12 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 12 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
13 | NKRO_ENABLE = yes # USB Nkey Rollover | 13 | NKRO_ENABLE = yes # USB Nkey Rollover |
14 | CUSTOM_MATRIX = no # Custom matrix file | 14 | CUSTOM_MATRIX = no # Custom matrix file |
15 | BACKLIGHT_ENABLE = yes | 15 | BACKLIGHT_ENABLE = yes |
diff --git a/keyboards/cannonkeys/ortho48/rules.mk b/keyboards/cannonkeys/ortho48/rules.mk index 6e468c49a..ac927481f 100644 --- a/keyboards/cannonkeys/ortho48/rules.mk +++ b/keyboards/cannonkeys/ortho48/rules.mk | |||
@@ -8,7 +8,7 @@ BOOTLOADER = stm32duino | |||
8 | VPATH += keyboards/cannonkeys/bluepill | 8 | VPATH += keyboards/cannonkeys/bluepill |
9 | SRC = keyboard.c | 9 | SRC = keyboard.c |
10 | 10 | ||
11 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 11 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
12 | MOUSEKEY_ENABLE = yes # Mouse keys | 12 | MOUSEKEY_ENABLE = yes # Mouse keys |
13 | EXTRAKEY_ENABLE = yes # Audio control and System control | 13 | EXTRAKEY_ENABLE = yes # Audio control and System control |
14 | CONSOLE_ENABLE = yes # Console for debug | 14 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/cannonkeys/ortho60/rules.mk b/keyboards/cannonkeys/ortho60/rules.mk index ea9bd6b2d..ec91d3b81 100644 --- a/keyboards/cannonkeys/ortho60/rules.mk +++ b/keyboards/cannonkeys/ortho60/rules.mk | |||
@@ -8,7 +8,7 @@ BOOTLOADER = stm32duino | |||
8 | VPATH += keyboards/cannonkeys/bluepill | 8 | VPATH += keyboards/cannonkeys/bluepill |
9 | SRC = keyboard.c | 9 | SRC = keyboard.c |
10 | 10 | ||
11 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 11 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
12 | MOUSEKEY_ENABLE = yes # Mouse keys | 12 | MOUSEKEY_ENABLE = yes # Mouse keys |
13 | EXTRAKEY_ENABLE = yes # Audio control and System control | 13 | EXTRAKEY_ENABLE = yes # Audio control and System control |
14 | CONSOLE_ENABLE = yes # Console for debug | 14 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/cannonkeys/ortho75/rules.mk b/keyboards/cannonkeys/ortho75/rules.mk index e132ccaf1..9d6004656 100644 --- a/keyboards/cannonkeys/ortho75/rules.mk +++ b/keyboards/cannonkeys/ortho75/rules.mk | |||
@@ -8,7 +8,7 @@ BOOTLOADER = stm32duino | |||
8 | VPATH += keyboards/cannonkeys/bluepill | 8 | VPATH += keyboards/cannonkeys/bluepill |
9 | SRC = keyboard.c | 9 | SRC = keyboard.c |
10 | 10 | ||
11 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 11 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
12 | MOUSEKEY_ENABLE = yes # Mouse keys | 12 | MOUSEKEY_ENABLE = yes # Mouse keys |
13 | EXTRAKEY_ENABLE = yes # Audio control and System control | 13 | EXTRAKEY_ENABLE = yes # Audio control and System control |
14 | CONSOLE_ENABLE = yes # Console for debug | 14 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/cannonkeys/practice60/rules.mk b/keyboards/cannonkeys/practice60/rules.mk index 3f9ca1448..80bde01cf 100644 --- a/keyboards/cannonkeys/practice60/rules.mk +++ b/keyboards/cannonkeys/practice60/rules.mk | |||
@@ -8,7 +8,7 @@ BOOTLOADER = stm32duino | |||
8 | VPATH += keyboards/cannonkeys/bluepill | 8 | VPATH += keyboards/cannonkeys/bluepill |
9 | SRC = keyboard.c | 9 | SRC = keyboard.c |
10 | 10 | ||
11 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 11 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
12 | MOUSEKEY_ENABLE = yes # Mouse keys | 12 | MOUSEKEY_ENABLE = yes # Mouse keys |
13 | EXTRAKEY_ENABLE = yes # Audio control and System control | 13 | EXTRAKEY_ENABLE = yes # Audio control and System control |
14 | CONSOLE_ENABLE = yes # Console for debug | 14 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/cannonkeys/practice65/rules.mk b/keyboards/cannonkeys/practice65/rules.mk index 344844b0e..130f9b98e 100644 --- a/keyboards/cannonkeys/practice65/rules.mk +++ b/keyboards/cannonkeys/practice65/rules.mk | |||
@@ -8,7 +8,7 @@ BOOTLOADER = stm32duino | |||
8 | VPATH += keyboards/cannonkeys/bluepill | 8 | VPATH += keyboards/cannonkeys/bluepill |
9 | SRC = keyboard.c | 9 | SRC = keyboard.c |
10 | 10 | ||
11 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 11 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
12 | MOUSEKEY_ENABLE = yes # Mouse keys | 12 | MOUSEKEY_ENABLE = yes # Mouse keys |
13 | EXTRAKEY_ENABLE = yes # Audio control and System control | 13 | EXTRAKEY_ENABLE = yes # Audio control and System control |
14 | CONSOLE_ENABLE = yes # Console for debug | 14 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/cannonkeys/satisfaction75/rules.mk b/keyboards/cannonkeys/satisfaction75/rules.mk index e3abea546..3861b4849 100644 --- a/keyboards/cannonkeys/satisfaction75/rules.mk +++ b/keyboards/cannonkeys/satisfaction75/rules.mk | |||
@@ -15,7 +15,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys | |||
15 | EXTRAKEY_ENABLE = yes # Audio control and System control | 15 | EXTRAKEY_ENABLE = yes # Audio control and System control |
16 | CONSOLE_ENABLE = yes # Console for debug | 16 | CONSOLE_ENABLE = yes # Console for debug |
17 | COMMAND_ENABLE = yes # Commands for debug and configuration | 17 | COMMAND_ENABLE = yes # Commands for debug and configuration |
18 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend | 18 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
19 | NKRO_ENABLE = yes # USB Nkey Rollover | 19 | NKRO_ENABLE = yes # USB Nkey Rollover |
20 | CUSTOM_MATRIX = no # Custom matrix file | 20 | CUSTOM_MATRIX = no # Custom matrix file |
21 | ENCODER_ENABLE = yes | 21 | ENCODER_ENABLE = yes |
diff --git a/keyboards/cannonkeys/savage65/rules.mk b/keyboards/cannonkeys/savage65/rules.mk index 8e1b984fd..2454573d2 100644 --- a/keyboards/cannonkeys/savage65/rules.mk +++ b/keyboards/cannonkeys/savage65/rules.mk | |||
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys | |||
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
13 | COMMAND_ENABLE = yes # Commands for debug and configuration | 13 | COMMAND_ENABLE = yes # Commands for debug and configuration |
14 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 14 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
15 | NKRO_ENABLE = yes # USB Nkey Rollover | 15 | NKRO_ENABLE = yes # USB Nkey Rollover |
16 | CUSTOM_MATRIX = no # Custom matrix file | 16 | CUSTOM_MATRIX = no # Custom matrix file |
17 | BACKLIGHT_ENABLE = yes | 17 | BACKLIGHT_ENABLE = yes |
diff --git a/keyboards/cannonkeys/tmov2/rules.mk b/keyboards/cannonkeys/tmov2/rules.mk index 9b29e8fd1..294c873ee 100644 --- a/keyboards/cannonkeys/tmov2/rules.mk +++ b/keyboards/cannonkeys/tmov2/rules.mk | |||
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys | |||
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
13 | COMMAND_ENABLE = yes # Commands for debug and configuration | 13 | COMMAND_ENABLE = yes # Commands for debug and configuration |
14 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 14 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
15 | NKRO_ENABLE = yes # USB Nkey Rollover | 15 | NKRO_ENABLE = yes # USB Nkey Rollover |
16 | CUSTOM_MATRIX = no # Custom matrix file | 16 | CUSTOM_MATRIX = no # Custom matrix file |
17 | BACKLIGHT_ENABLE = yes | 17 | BACKLIGHT_ENABLE = yes |
diff --git a/keyboards/cannonkeys/tsukuyomi/rules.mk b/keyboards/cannonkeys/tsukuyomi/rules.mk index ce881f198..4e7791a79 100644 --- a/keyboards/cannonkeys/tsukuyomi/rules.mk +++ b/keyboards/cannonkeys/tsukuyomi/rules.mk | |||
@@ -10,7 +10,7 @@ EXTRAKEY_ENABLE = yes # Audio control and System control | |||
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
11 | COMMAND_ENABLE = yes # Commands for debug and configuration | 11 | COMMAND_ENABLE = yes # Commands for debug and configuration |
12 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | 12 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE |
13 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 13 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
14 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | 14 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work |
15 | NKRO_ENABLE = yes # USB Nkey Rollover | 15 | NKRO_ENABLE = yes # USB Nkey Rollover |
16 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality | 16 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality |
diff --git a/keyboards/chimera_ergo/rules.mk b/keyboards/chimera_ergo/rules.mk index 01d5c3c70..b7084b4a1 100644 --- a/keyboards/chimera_ergo/rules.mk +++ b/keyboards/chimera_ergo/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/chimera_ls/rules.mk b/keyboards/chimera_ls/rules.mk index 536e6053a..2f414ba81 100644 --- a/keyboards/chimera_ls/rules.mk +++ b/keyboards/chimera_ls/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/chimera_ortho/rules.mk b/keyboards/chimera_ortho/rules.mk index e3bbaa39d..d97cff59f 100644 --- a/keyboards/chimera_ortho/rules.mk +++ b/keyboards/chimera_ortho/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/ck60i/rules.mk b/keyboards/ck60i/rules.mk index 10f86791e..2360b9c85 100644 --- a/keyboards/ck60i/rules.mk +++ b/keyboards/ck60i/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = no # Console for debug | 10 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/ckeys/thedora/rules.mk b/keyboards/ckeys/thedora/rules.mk index aa378710c..508af7d39 100755 --- a/keyboards/ckeys/thedora/rules.mk +++ b/keyboards/ckeys/thedora/rules.mk | |||
@@ -6,7 +6,7 @@ BOARD = QMK_PROTON_C | |||
6 | # comment out to disable the options. | 6 | # comment out to disable the options. |
7 | # | 7 | # |
8 | BACKLIGHT_ENABLE = no | 8 | BACKLIGHT_ENABLE = no |
9 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = yes # Mouse keys | 10 | MOUSEKEY_ENABLE = yes # Mouse keys |
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = no # Console for debug | 12 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/clueboard/66_hotswap/gen1/gen1.c b/keyboards/clueboard/66_hotswap/gen1/gen1.c index dd399317c..339bd78d5 100644 --- a/keyboards/clueboard/66_hotswap/gen1/gen1.c +++ b/keyboards/clueboard/66_hotswap/gen1/gen1.c | |||
@@ -16,8 +16,6 @@ | |||
16 | #include "gen1.h" | 16 | #include "gen1.h" |
17 | 17 | ||
18 | #ifdef LED_MATRIX_ENABLE | 18 | #ifdef LED_MATRIX_ENABLE |
19 | #include "is31fl3731-simple.h" | ||
20 | |||
21 | const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { | 19 | const is31_led g_is31_leds[DRIVER_LED_TOTAL] = { |
22 | /* Refer to IS31 manual for these locations | 20 | /* Refer to IS31 manual for these locations |
23 | * driver | 21 | * driver |
diff --git a/keyboards/contra/rules.mk b/keyboards/contra/rules.mk index 5894ca132..9bd4c0851 100755 --- a/keyboards/contra/rules.mk +++ b/keyboards/contra/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/converter/siemens_tastatur/rules.mk b/keyboards/converter/siemens_tastatur/rules.mk index 451d07e67..ff54cf24e 100644 --- a/keyboards/converter/siemens_tastatur/rules.mk +++ b/keyboards/converter/siemens_tastatur/rules.mk | |||
@@ -6,7 +6,7 @@ BOOTLOADER = stm32duino | |||
6 | 6 | ||
7 | SRC = matrix.c | 7 | SRC = matrix.c |
8 | 8 | ||
9 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = yes # Mouse keys | 10 | MOUSEKEY_ENABLE = yes # Mouse keys |
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/converter/usb_usb/rules.mk b/keyboards/converter/usb_usb/rules.mk index d277853cf..d2b991837 100644 --- a/keyboards/converter/usb_usb/rules.mk +++ b/keyboards/converter/usb_usb/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | #MOUSEKEY_ENABLE = yes # Mouse keys | 18 | #MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | #CONSOLE_ENABLE = yes # Console for debug | 20 | #CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/crkbd/rev1/common/config.h b/keyboards/crkbd/rev1/common/config.h index a2c2cde0b..b468fe395 100644 --- a/keyboards/crkbd/rev1/common/config.h +++ b/keyboards/crkbd/rev1/common/config.h | |||
@@ -23,6 +23,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
23 | 23 | ||
24 | #ifdef RGB_MATRIX_ENABLE | 24 | #ifdef RGB_MATRIX_ENABLE |
25 | # define RGB_MATRIX_SPLIT { 27, 27 } | 25 | # define RGB_MATRIX_SPLIT { 27, 27 } |
26 | # define SPLIT_TRANSPORT_MIRROR | ||
26 | #endif | 27 | #endif |
27 | 28 | ||
28 | #define DIODE_DIRECTION COL2ROW | 29 | #define DIODE_DIRECTION COL2ROW |
diff --git a/keyboards/crkbd/rev1/common/rules.mk b/keyboards/crkbd/rev1/common/rules.mk index 0b8106e3f..d38a61809 100644 --- a/keyboards/crkbd/rev1/common/rules.mk +++ b/keyboards/crkbd/rev1/common/rules.mk | |||
@@ -1,2 +1 @@ | |||
1 | SPLIT_KEYBOARD = yes | SPLIT_KEYBOARD = yes | |
2 | SPLIT_TRANSPORT = mirror # for when Split Mirroring drops, it will maintain mirroring functionality | ||
diff --git a/keyboards/crkbd/rev1/rev1.c b/keyboards/crkbd/rev1/rev1.c index f2df8942a..347f98150 100644 --- a/keyboards/crkbd/rev1/rev1.c +++ b/keyboards/crkbd/rev1/rev1.c | |||
@@ -87,7 +87,7 @@ led_config_t g_led_config = { { | |||
87 | 87 | ||
88 | void matrix_init_kb(void) { | 88 | void matrix_init_kb(void) { |
89 | 89 | ||
90 | #ifdef RGB_MATRIX_ENABLE | 90 | #if defined(RGB_MATRIX_ENABLE) && !defined(RGB_MATRIX_SPLIT) |
91 | if (!isLeftHand) { | 91 | if (!isLeftHand) { |
92 | g_led_config = (led_config_t){ { | 92 | g_led_config = (led_config_t){ { |
93 | { 51, 50, 45, 44, 37, 36 }, | 93 | { 51, 50, 45, 44, 37, 36 }, |
diff --git a/keyboards/cutie_club/wraith/rules.mk b/keyboards/cutie_club/wraith/rules.mk index dce4ad686..a42fd4257 100644 --- a/keyboards/cutie_club/wraith/rules.mk +++ b/keyboards/cutie_club/wraith/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/daji/seis_cinco/rules.mk b/keyboards/daji/seis_cinco/rules.mk index fa34092cd..768e50069 100644 --- a/keyboards/daji/seis_cinco/rules.mk +++ b/keyboards/daji/seis_cinco/rules.mk | |||
@@ -11,7 +11,7 @@ EXTRAKEY_ENABLE = yes # Audio control and System control | |||
11 | CONSOLE_ENABLE = no # Console for debug | 11 | CONSOLE_ENABLE = no # Console for debug |
12 | COMMAND_ENABLE = no # Commands for debug and configuration | 12 | COMMAND_ENABLE = no # Commands for debug and configuration |
13 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | 13 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE |
14 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 14 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
15 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | 15 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work |
16 | NKRO_ENABLE = yes # USB Nkey Rollover | 16 | NKRO_ENABLE = yes # USB Nkey Rollover |
17 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality | 17 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality |
diff --git a/keyboards/dichotomy/rules.mk b/keyboards/dichotomy/rules.mk index d6f98125e..a9a01d867 100755 --- a/keyboards/dichotomy/rules.mk +++ b/keyboards/dichotomy/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | #MOUSEKEY_ENABLE = yes # Mouse keys | 18 | #MOUSEKEY_ENABLE = yes # Mouse keys |
19 | POINTING_DEVICE_ENABLE = yes # Generic Pointer, not as big as mouse keys hopefully. | 19 | POINTING_DEVICE_ENABLE = yes # Generic Pointer, not as big as mouse keys hopefully. |
20 | EXTRAKEY_ENABLE = yes # Audio control and System control | 20 | EXTRAKEY_ENABLE = yes # Audio control and System control |
diff --git a/keyboards/do60/rules.mk b/keyboards/do60/rules.mk index 73bb4f096..106a1f06d 100644 --- a/keyboards/do60/rules.mk +++ b/keyboards/do60/rules.mk | |||
@@ -15,7 +15,7 @@ BOOTLOADER = atmel-dfu | |||
15 | AUDIO_ENABLE = no # Audio output on port C6 | 15 | AUDIO_ENABLE = no # Audio output on port C6 |
16 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality | 16 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality |
17 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID | 17 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID |
18 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 18 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
19 | COMMAND_ENABLE = no # Commands for debug and configuration | 19 | COMMAND_ENABLE = no # Commands for debug and configuration |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
21 | EXTRAKEY_ENABLE = yes # Audio control and System control | 21 | EXTRAKEY_ENABLE = yes # Audio control and System control |
diff --git a/keyboards/durgod/k320/board.h b/keyboards/durgod/boards/DURGOD_STM32_F070/board.h index 17d08b17f..2d04bccbd 100644 --- a/keyboards/durgod/k320/board.h +++ b/keyboards/durgod/boards/DURGOD_STM32_F070/board.h | |||
@@ -20,4 +20,3 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
20 | #define STM32_HSECLK 12000000U | 20 | #define STM32_HSECLK 12000000U |
21 | #include_next <board.h> | 21 | #include_next <board.h> |
22 | #undef STM32_HSE_BYPASS | 22 | #undef STM32_HSE_BYPASS |
23 | |||
diff --git a/keyboards/durgod/boards/DURGOD_STM32_F070/board.mk b/keyboards/durgod/boards/DURGOD_STM32_F070/board.mk new file mode 100644 index 000000000..479184833 --- /dev/null +++ b/keyboards/durgod/boards/DURGOD_STM32_F070/board.mk | |||
@@ -0,0 +1,12 @@ | |||
1 | # List of all the board related files. | ||
2 | BOARDSRC = $(CHIBIOS)/os/hal/boards/ST_NUCLEO64_F070RB/board.c | ||
3 | |||
4 | # Required include directories | ||
5 | BOARDINC = $(CHIBIOS)/os/hal/boards/ST_NUCLEO64_F070RB | ||
6 | |||
7 | # Include mcu configuration | ||
8 | EXTRAINCDIRS = $(BOARD_PATH)/boards/DURGOD_STM32_F070 | ||
9 | |||
10 | # Shared variables | ||
11 | ALLCSRC += $(BOARDSRC) | ||
12 | ALLINC += $(BOARDINC) | ||
diff --git a/keyboards/durgod/k320/bootloader_defs.h b/keyboards/durgod/boards/DURGOD_STM32_F070/bootloader_defs.h index 02c48c4e6..02c48c4e6 100644 --- a/keyboards/durgod/k320/bootloader_defs.h +++ b/keyboards/durgod/boards/DURGOD_STM32_F070/bootloader_defs.h | |||
diff --git a/keyboards/durgod/k320/chconf.h b/keyboards/durgod/boards/DURGOD_STM32_F070/chconf.h index 374a03003..a7d95c51a 100644 --- a/keyboards/durgod/k320/chconf.h +++ b/keyboards/durgod/boards/DURGOD_STM32_F070/chconf.h | |||
@@ -25,19 +25,4 @@ | |||
25 | 25 | ||
26 | #define CH_CFG_ST_TIMEDELTA 0 | 26 | #define CH_CFG_ST_TIMEDELTA 0 |
27 | 27 | ||
28 | #define CH_CFG_OPTIMIZE_SPEED FALSE | ||
29 | |||
30 | #define CH_CFG_USE_REGISTRY TRUE | ||
31 | |||
32 | #define CH_CFG_USE_WAITEXIT TRUE | ||
33 | |||
34 | #define CH_CFG_USE_CONDVARS TRUE | ||
35 | |||
36 | #define CH_CFG_USE_CONDVARS_TIMEOUT FALSE | ||
37 | |||
38 | #define CH_CFG_USE_MESSAGES TRUE | ||
39 | |||
40 | #define CH_CFG_USE_MAILBOXES TRUE | ||
41 | |||
42 | #include_next <chconf.h> | 28 | #include_next <chconf.h> |
43 | |||
diff --git a/keyboards/durgod/k320/mcuconf.h b/keyboards/durgod/boards/DURGOD_STM32_F070/mcuconf.h index 6d67aa96a..6d67aa96a 100644 --- a/keyboards/durgod/k320/mcuconf.h +++ b/keyboards/durgod/boards/DURGOD_STM32_F070/mcuconf.h | |||
diff --git a/keyboards/durgod/k320/config.h b/keyboards/durgod/k320/config.h index 70438900e..323a9ccff 100644 --- a/keyboards/durgod/k320/config.h +++ b/keyboards/durgod/k320/config.h | |||
@@ -1,19 +1,18 @@ | |||
1 | /* | 1 | /* Copyright 2021 kuenhlee and Don Kjer |
2 | Copyright 2021 kuenhlee and Don Kjer | 2 | * |
3 | 3 | * This program is free software: you can redistribute it and/or modify | |
4 | This program is free software: you can redistribute it and/or modify | 4 | * it under the terms of the GNU General Public License as published by |
5 | it under the terms of the GNU General Public License as published by | 5 | * the Free Software Foundation, either version 2 of the License, or |
6 | the Free Software Foundation, either version 2 of the License, or | 6 | * (at your option) any later version. |
7 | (at your option) any later version. | 7 | * |
8 | 8 | * This program is distributed in the hope that it will be useful, | |
9 | This program is distributed in the hope that it will be useful, | 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
10 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 11 | * GNU General Public License for more details. |
12 | GNU General Public License for more details. | 12 | * |
13 | 13 | * You should have received a copy of the GNU General Public License | |
14 | You should have received a copy of the GNU General Public License | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
15 | along with this program. If not, see <http://www.gnu.org/licenses/>. | 15 | */ |
16 | */ | ||
17 | 16 | ||
18 | #pragma once | 17 | #pragma once |
19 | 18 | ||
@@ -36,8 +35,13 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
36 | /* COL2ROW, ROW2COL*/ | 35 | /* COL2ROW, ROW2COL*/ |
37 | #define DIODE_DIRECTION ROW2COL | 36 | #define DIODE_DIRECTION ROW2COL |
38 | 37 | ||
38 | // Dynamic EEPROM | ||
39 | // Something sensible or else VIA may crash | ||
40 | // Users may enable more if they wish | ||
41 | #define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 4095 | ||
42 | |||
39 | /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ | 43 | /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ |
40 | #define DEBOUNCE 7 | 44 | #define DEBOUNCE 5 |
41 | 45 | ||
42 | /* Bootmagic Lite key configuration */ | 46 | /* Bootmagic Lite key configuration */ |
43 | #define EARLY_INIT_PERFORM_BOOTLOADER_JUMP TRUE | 47 | #define EARLY_INIT_PERFORM_BOOTLOADER_JUMP TRUE |
@@ -50,4 +54,3 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
50 | #define LED_WIN_LOCK_PIN A9 | 54 | #define LED_WIN_LOCK_PIN A9 |
51 | #define LED_MR_LOCK_PIN A10 | 55 | #define LED_MR_LOCK_PIN A10 |
52 | #define LED_PIN_ON_STATE 0 | 56 | #define LED_PIN_ON_STATE 0 |
53 | |||
diff --git a/keyboards/durgod/k320/info.json b/keyboards/durgod/k320/info.json index 5e33d8fcd..6c67c3d45 100644 --- a/keyboards/durgod/k320/info.json +++ b/keyboards/durgod/k320/info.json | |||
@@ -7,913 +7,293 @@ | |||
7 | "layouts": { | 7 | "layouts": { |
8 | "LAYOUT_tkl_ansi": { | 8 | "LAYOUT_tkl_ansi": { |
9 | "layout": [ | 9 | "layout": [ |
10 | { | 10 | { "label": "Esc", "x": 0, "y": 0 }, |
11 | "label": "Esc", | 11 | { "label": "F1", "x": 2, "y": 0 }, |
12 | "x": 0, | 12 | { "label": "F2", "x": 3, "y": 0 }, |
13 | "y": 0 | 13 | { "label": "F3", "x": 4, "y": 0 }, |
14 | }, | 14 | { "label": "F4", "x": 5, "y": 0 }, |
15 | { | 15 | { "label": "F5", "x": 6.5, "y": 0 }, |
16 | "label": "F1", | 16 | { "label": "F6", "x": 7.5, "y": 0 }, |
17 | "x": 2, | 17 | { "label": "F7", "x": 8.5, "y": 0 }, |
18 | "y": 0 | 18 | { "label": "F8", "x": 9.5, "y": 0 }, |
19 | }, | 19 | { "label": "F9", "x": 11, "y": 0 }, |
20 | { | 20 | { "label": "F10", "x": 12, "y": 0 }, |
21 | "label": "F2", | 21 | { "label": "F11", "x": 13, "y": 0 }, |
22 | "x": 3, | 22 | { "label": "F12", "x": 14, "y": 0 }, |
23 | "y": 0 | 23 | { "label": "PrtSc", "x": 15.25, "y": 0 }, |
24 | }, | 24 | { "label": "Scroll Lock", "x": 16.25, "y": 0 }, |
25 | { | 25 | { "label": "Pause", "x": 17.25, "y": 0 }, |
26 | "label": "F3", | 26 | |
27 | "x": 4, | 27 | { "label": "~", "x": 0, "y": 1.5 }, |
28 | "y": 0 | 28 | { "label": "!", "x": 1, "y": 1.5 }, |
29 | }, | 29 | { "label": "@", "x": 2, "y": 1.5 }, |
30 | { | 30 | { "label": "#", "x": 3, "y": 1.5 }, |
31 | "label": "F4", | 31 | { "label": "$", "x": 4, "y": 1.5 }, |
32 | "x": 5, | 32 | { "label": "%", "x": 5, "y": 1.5 }, |
33 | "y": 0 | 33 | { "label": "^", "x": 6, "y": 1.5 }, |
34 | }, | 34 | { "label": "&", "x": 7, "y": 1.5 }, |
35 | { | 35 | { "label": "*", "x": 8, "y": 1.5 }, |
36 | "label": "F5", | 36 | { "label": "(", "x": 9, "y": 1.5 }, |
37 | "x": 6.5, | 37 | { "label": ")", "x": 10, "y": 1.5 }, |
38 | "y": 0 | 38 | { "label": "_", "x": 11, "y": 1.5 }, |
39 | }, | 39 | { "label": "+", "x": 12, "y": 1.5 }, |
40 | { | 40 | { "label": "Backspace", "x": 13, "y": 1.5, "w": 2 }, |
41 | "label": "F6", | 41 | { "label": "Insert", "x": 15.25, "y": 1.5 }, |
42 | "x": 7.5, | 42 | { "label": "Home", "x": 16.25, "y": 1.5 }, |
43 | "y": 0 | 43 | { "label": "PgUp", "x": 17.25, "y": 1.5 }, |
44 | }, | 44 | |
45 | { | 45 | { "label": "Tab", "x": 0, "y": 2.5, "w": 1.5 }, |
46 | "label": "F7", | 46 | { "label": "Q", "x": 1.5, "y": 2.5 }, |
47 | "x": 8.5, | 47 | { "label": "W", "x": 2.5, "y": 2.5 }, |
48 | "y": 0 | 48 | { "label": "E", "x": 3.5, "y": 2.5 }, |
49 | }, | 49 | { "label": "R", "x": 4.5, "y": 2.5 }, |
50 | { | 50 | { "label": "T", "x": 5.5, "y": 2.5 }, |
51 | "label": "F8", | 51 | { "label": "Y", "x": 6.5, "y": 2.5 }, |
52 | "x": 9.5, | 52 | { "label": "U", "x": 7.5, "y": 2.5 }, |
53 | "y": 0 | 53 | { "label": "I", "x": 8.5, "y": 2.5 }, |
54 | }, | 54 | { "label": "O", "x": 9.5, "y": 2.5 }, |
55 | { | 55 | { "label": "P", "x": 10.5, "y": 2.5 }, |
56 | "label": "F9", | 56 | { "label": "{", "x": 11.5, "y": 2.5 }, |
57 | "x": 11, | 57 | { "label": "}", "x": 12.5, "y": 2.5 }, |
58 | "y": 0 | 58 | { "label": "|", "x": 13.5, "y": 2.5, "w": 1.5 }, |
59 | }, | 59 | { "label": "Delete", "x": 15.25, "y": 2.5 }, |
60 | { | 60 | { "label": "End", "x": 16.25, "y": 2.5 }, |
61 | "label": "F10", | 61 | { "label": "PgDn", "x": 17.25, "y": 2.5 }, |
62 | "x": 12, | 62 | |
63 | "y": 0 | 63 | { "label": "Caps Lock", "x": 0, "y": 3.5, "w": 1.75 }, |
64 | }, | 64 | { "label": "A", "x": 1.75, "y": 3.5 }, |
65 | { | 65 | { "label": "S", "x": 2.75, "y": 3.5 }, |
66 | "label": "F11", | 66 | { "label": "D", "x": 3.75, "y": 3.5 }, |
67 | "x": 13, | 67 | { "label": "F", "x": 4.75, "y": 3.5 }, |
68 | "y": 0 | 68 | { "label": "G", "x": 5.75, "y": 3.5 }, |
69 | }, | 69 | { "label": "H", "x": 6.75, "y": 3.5 }, |
70 | { | 70 | { "label": "J", "x": 7.75, "y": 3.5 }, |
71 | "label": "F12", | 71 | { "label": "K", "x": 8.75, "y": 3.5 }, |
72 | "x": 14, | 72 | { "label": "L", "x": 9.75, "y": 3.5 }, |
73 | "y": 0 | 73 | { "label": ":", "x": 10.75, "y": 3.5 }, |
74 | }, | 74 | { "label": "\"", "x": 11.75, "y": 3.5 }, |
75 | { | 75 | { "label": "Enter", "x": 12.75, "y": 3.5, "w": 2.25 }, |
76 | "label": "PrtSc", | 76 | |
77 | "x": 15.25, | 77 | { "label": "Shift", "x": 0, "y": 4.5, "w": 2.25 }, |
78 | "y": 0 | 78 | { "label": "Z", "x": 2.25, "y": 4.5 }, |
79 | }, | 79 | { "label": "X", "x": 3.25, "y": 4.5 }, |
80 | { | 80 | { "label": "C", "x": 4.25, "y": 4.5 }, |
81 | "label": "Scroll Lock", | 81 | { "label": "V", "x": 5.25, "y": 4.5 }, |
82 | "x": 16.25, | 82 | { "label": "B", "x": 6.25, "y": 4.5 }, |
83 | "y": 0 | 83 | { "label": "N", "x": 7.25, "y": 4.5 }, |
84 | }, | 84 | { "label": "M", "x": 8.25, "y": 4.5 }, |
85 | { | 85 | { "label": "<", "x": 9.25, "y": 4.5 }, |
86 | "label": "Pause", | 86 | { "label": ">", "x": 10.25, "y": 4.5 }, |
87 | "x": 17.25, | 87 | { "label": "?", "x": 11.25, "y": 4.5 }, |
88 | "y": 0 | 88 | { "label": "Shift", "x": 12.25, "y": 4.5, "w": 2.75 }, |
89 | }, | 89 | { "label": "\u2191", "x": 16.25, "y": 4.5 }, |
90 | { | 90 | |
91 | "label": "~", | 91 | { "label": "Ctrl", "x": 0, "y": 5.5, "w": 1.25 }, |
92 | "x": 0, | 92 | { "label": "Win", "x": 1.25, "y": 5.5, "w": 1.25 }, |
93 | "y": 1.5 | 93 | { "label": "Alt", "x": 2.5, "y": 5.5, "w": 1.25 }, |
94 | }, | 94 | { "x": 3.75, "y": 5.5, "w": 6.25 }, |
95 | { | 95 | { "label": "Alt", "x": 10, "y": 5.5, "w": 1.25 }, |
96 | "label": "!", | 96 | { "label": "Fn", "x": 11.25, "y": 5.5, "w": 1.25 }, |
97 | "x": 1, | 97 | { "label": "Menu", "x": 12.5, "y": 5.5, "w": 1.25 }, |
98 | "y": 1.5 | 98 | { "label": "Ctrl", "x": 13.75, "y": 5.5, "w": 1.25 }, |
99 | }, | 99 | { "label": "\u2190", "x": 15.25, "y": 5.5 }, |
100 | { | 100 | { "label": "\u2193", "x": 16.25, "y": 5.5 }, |
101 | "label": "@", | 101 | { "label": "\u2192", "x": 17.25, "y": 5.5 } |
102 | "x": 2, | ||
103 | "y": 1.5 | ||
104 | }, | ||
105 | { | ||
106 | "label": "#", | ||
107 | "x": 3, | ||
108 | "y": 1.5 | ||
109 | }, | ||
110 | { | ||
111 | "label": "$", | ||
112 | "x": 4, | ||
113 | "y": 1.5 | ||
114 | }, | ||
115 | { | ||
116 | "label": "%", | ||
117 | "x": 5, | ||
118 | "y": 1.5 | ||
119 | }, | ||
120 | { | ||
121 | "label": "^", | ||
122 | "x": 6, | ||
123 | "y": 1.5 | ||
124 | }, | ||
125 | { | ||
126 | "label": "&", | ||
127 | "x": 7, | ||
128 | "y": 1.5 | ||
129 | }, | ||
130 | { | ||
131 | "label": "*", | ||
132 | "x": 8, | ||
133 | "y": 1.5 | ||
134 | }, | ||
135 | { | ||
136 | "label": "(", | ||
137 | "x": 9, | ||
138 | "y": 1.5 | ||
139 | }, | ||
140 | { | ||
141 | "label": ")", | ||
142 | "x": 10, | ||
143 | "y": 1.5 | ||
144 | }, | ||
145 | { | ||
146 | "label": "_", | ||
147 | "x": 11, | ||
148 | "y": 1.5 | ||
149 | }, | ||
150 | { | ||
151 | "label": "+", | ||
152 | "x": 12, | ||
153 | "y": 1.5 | ||
154 | }, | ||
155 | { | ||
156 | "label": "Backspace", | ||
157 | "x": 13, | ||
158 | "y": 1.5, | ||
159 | "w": 2 | ||
160 | }, | ||
161 | { | ||
162 | "label": "Insert", | ||
163 | "x": 15.25, | ||
164 | "y": 1.5 | ||
165 | }, | ||
166 | { | ||
167 | "label": "Home", | ||
168 | "x": 16.25, | ||
169 | "y": 1.5 | ||
170 | }, | ||
171 | { | ||
172 | "label": "PgUp", | ||
173 | "x": 17.25, | ||
174 | "y": 1.5 | ||
175 | }, | ||
176 | { | ||
177 | "label": "Tab", | ||
178 | "x": 0, | ||
179 | "y": 2.5, | ||
180 | "w": 1.5 | ||
181 | }, | ||
182 | { | ||
183 | "label": "Q", | ||
184 | "x": 1.5, | ||
185 | "y": 2.5 | ||
186 | }, | ||
187 | { | ||
188 | "label": "W", | ||
189 | "x": 2.5, | ||
190 | "y": 2.5 | ||
191 | }, | ||
192 | { | ||
193 | "label": "E", | ||
194 | "x": 3.5, | ||
195 | "y": 2.5 | ||
196 | }, | ||
197 | { | ||
198 | "label": "R", | ||
199 | "x": 4.5, | ||
200 | "y": 2.5 | ||
201 | }, | ||
202 | { | ||
203 | "label": "T", | ||
204 | "x": 5.5, | ||
205 | "y": 2.5 | ||
206 | }, | ||
207 | { | ||
208 | "label": "Y", | ||
209 | "x": 6.5, | ||
210 | "y": 2.5 | ||
211 | }, | ||
212 | { | ||
213 | "label": "U", | ||
214 | "x": 7.5, | ||
215 | "y": 2.5 | ||
216 | }, | ||
217 | { | ||
218 | "label": "I", | ||
219 | "x": 8.5, | ||
220 | "y": 2.5 | ||
221 | }, | ||
222 | { | ||
223 | "label": "O", | ||
224 | "x": 9.5, | ||
225 | "y": 2.5 | ||
226 | }, | ||
227 | { | ||
228 | "label": "P", | ||
229 | "x": 10.5, | ||
230 | "y": 2.5 | ||
231 | }, | ||
232 | { | ||
233 | "label": "{", | ||
234 | "x": 11.5, | ||
235 | "y": 2.5 | ||
236 | }, | ||
237 | { | ||
238 | "label": "}", | ||
239 | "x": 12.5, | ||
240 | "y": 2.5 | ||
241 | }, | ||
242 | { | ||
243 | "label": "|", | ||
244 | "x": 13.5, | ||
245 | "y": 2.5, | ||
246 | "w": 1.5 | ||
247 | }, | ||
248 | { | ||
249 | "label": "Delete", | ||
250 | "x": 15.25, | ||
251 | "y": 2.5 | ||
252 | }, | ||
253 | { | ||
254 | "label": "End", | ||
255 | "x": 16.25, | ||
256 | "y": 2.5 | ||
257 | }, | ||
258 | { | ||
259 | "label": "PgDn", | ||
260 | "x": 17.25, | ||
261 | "y": 2.5 | ||
262 | }, | ||
263 | { | ||
264 | "label": "Caps Lock", | ||
265 | "x": 0, | ||
266 | "y": 3.5, | ||
267 | "w": 1.75 | ||
268 | }, | ||
269 | { | ||
270 | "label": "A", | ||
271 | "x": 1.75, | ||
272 | "y": 3.5 | ||
273 | }, | ||
274 | { | ||
275 | "label": "S", | ||
276 | "x": 2.75, | ||
277 | "y": 3.5 | ||
278 | }, | ||
279 | { | ||
280 | "label": "D", | ||
281 | "x": 3.75, | ||
282 | "y": 3.5 | ||
283 | }, | ||
284 | { | ||
285 | "label": "F", | ||
286 | "x": 4.75, | ||
287 | "y": 3.5 | ||
288 | }, | ||
289 | { | ||
290 | "label": "G", | ||
291 | "x": 5.75, | ||
292 | "y": 3.5 | ||
293 | }, | ||
294 | { | ||
295 | "label": "H", | ||
296 | "x": 6.75, | ||
297 | "y": 3.5 | ||
298 | }, | ||
299 | { | ||
300 | "label": "J", | ||
301 | "x": 7.75, | ||
302 | "y": 3.5 | ||
303 | }, | ||
304 | { | ||
305 | "label": "K", | ||
306 | "x": 8.75, | ||
307 | "y": 3.5 | ||
308 | }, | ||
309 | { | ||
310 | "label": "L", | ||
311 | "x": 9.75, | ||
312 | "y": 3.5 | ||
313 | }, | ||
314 | { | ||
315 | "label": ":", | ||
316 | "x": 10.75, | ||
317 | "y": 3.5 | ||
318 | }, | ||
319 | { | ||
320 | "label": "\"", | ||
321 | "x": 11.75, | ||
322 | "y": 3.5 | ||
323 | }, | ||
324 | { | ||
325 | "label": "Enter", | ||
326 | "x": 12.75, | ||
327 | "y": 3.5, | ||
328 | "w": 2.25 | ||
329 | }, | ||
330 | { | ||
331 | "label": "Shift", | ||
332 | "x": 0, | ||
333 | "y": 4.5, | ||
334 | "w": 2.25 | ||
335 | }, | ||
336 | { | ||
337 | "label": "Z", | ||
338 | "x": 2.25, | ||
339 | "y": 4.5 | ||
340 | }, | ||
341 | { | ||
342 | "label": "X", | ||
343 | "x": 3.25, | ||
344 | "y": 4.5 | ||
345 | }, | ||
346 | { | ||
347 | "label": "C", | ||
348 | "x": 4.25, | ||
349 | "y": 4.5 | ||
350 | }, | ||
351 | { | ||
352 | "label": "V", | ||
353 | "x": 5.25, | ||
354 | "y": 4.5 | ||
355 | }, | ||
356 | { | ||
357 | "label": "B", | ||
358 | "x": 6.25, | ||
359 | "y": 4.5 | ||
360 | }, | ||
361 | { | ||
362 | "label": "N", | ||
363 | "x": 7.25, | ||
364 | "y": 4.5 | ||
365 | }, | ||
366 | { | ||
367 | "label": "M", | ||
368 | "x": 8.25, | ||
369 | "y": 4.5 | ||
370 | }, | ||
371 | { | ||
372 | "label": "<", | ||
373 | "x": 9.25, | ||
374 | "y": 4.5 | ||
375 | }, | ||
376 | { | ||
377 | "label": ">", | ||
378 | "x": 10.25, | ||
379 | "y": 4.5 | ||
380 | }, | ||
381 | { | ||
382 | "label": "?", | ||
383 | "x": 11.25, | ||
384 | "y": 4.5 | ||
385 | }, | ||
386 | { | ||
387 | "label": "Shift", | ||
388 | "x": 12.25, | ||
389 | "y": 4.5, | ||
390 | "w": 2.75 | ||
391 | }, | ||
392 | { | ||
393 | "label": "\u2191", | ||
394 | "x": 16.25, | ||
395 | "y": 4.5 | ||
396 | }, | ||
397 | { | ||
398 | "label": "Ctrl", | ||
399 | "x": 0, | ||
400 | "y": 5.5, | ||
401 | "w": 1.25 | ||
402 | }, | ||
403 | { | ||
404 | "label": "Win", | ||
405 | "x": 1.25, | ||
406 | "y": 5.5, | ||
407 | "w": 1.25 | ||
408 | }, | ||
409 | { | ||
410 | "label": "Alt", | ||
411 | "x": 2.5, | ||
412 | "y": 5.5, | ||
413 | "w": 1.25 | ||
414 | }, | ||
415 | { | ||
416 | "x": 3.75, | ||
417 | "y": 5.5, | ||
418 | "w": 6.25 | ||
419 | }, | ||
420 | { | ||
421 | "label": "Alt", | ||
422 | "x": 10, | ||
423 | "y": 5.5, | ||
424 | "w": 1.25 | ||
425 | }, | ||
426 | { | ||
427 | "label": "Fn", | ||
428 | "x": 11.25, | ||
429 | "y": 5.5, | ||
430 | "w": 1.25 | ||
431 | }, | ||
432 | { | ||
433 | "label": "Menu", | ||
434 | "x": 12.5, | ||
435 | "y": 5.5, | ||
436 | "w": 1.25 | ||
437 | }, | ||
438 | { | ||
439 | "label": "Ctrl", | ||
440 | "x": 13.75, | ||
441 | "y": 5.5, | ||
442 | "w": 1.25 | ||
443 | }, | ||
444 | { | ||
445 | "label": "\u2190", | ||
446 | "x": 15.25, | ||
447 | "y": 5.5 | ||
448 | }, | ||
449 | { | ||
450 | "label": "\u2193", | ||
451 | "x": 16.25, | ||
452 | "y": 5.5 | ||
453 | }, | ||
454 | { | ||
455 | "label": "\u2192", | ||
456 | "x": 17.25, | ||
457 | "y": 5.5 | ||
458 | } | ||
459 | ] | 102 | ] |
460 | }, | 103 | }, |
461 | "LAYOUT_tkl_iso": { | 104 | "LAYOUT_tkl_iso": { |
462 | "layout": [ | 105 | "layout": [ |
463 | { | 106 | { "label": "Esc", "x": 0, "y": 0 }, |
464 | "label": "Esc", | 107 | { "label": "F1", "x": 2, "y": 0 }, |
465 | "x": 0, | 108 | { "label": "F2", "x": 3, "y": 0 }, |
466 | "y": 0 | 109 | { "label": "F3", "x": 4, "y": 0 }, |
467 | }, | 110 | { "label": "F4", "x": 5, "y": 0 }, |
468 | { | 111 | { "label": "F5", "x": 6.5, "y": 0 }, |
469 | "label": "F1", | 112 | { "label": "F6", "x": 7.5, "y": 0 }, |
470 | "x": 2, | 113 | { "label": "F7", "x": 8.5, "y": 0 }, |
471 | "y": 0 | 114 | { "label": "F8", "x": 9.5, "y": 0 }, |
472 | }, | 115 | { "label": "F9", "x": 11, "y": 0 }, |
473 | { | 116 | { "label": "F10", "x": 12, "y": 0 }, |
474 | "label": "F2", | 117 | { "label": "F11", "x": 13, "y": 0 }, |
475 | "x": 3, | 118 | { "label": "F12", "x": 14, "y": 0 }, |
476 | "y": 0 | 119 | { "label": "PrtSc", "x": 15.25, "y": 0 }, |
477 | }, | 120 | { "label": "Scroll Lock", "x": 16.25, "y": 0 }, |
478 | { | 121 | { "label": "Pause", "x": 17.25, "y": 0 }, |
479 | "label": "F3", | 122 | |
480 | "x": 4, | 123 | { "label": "~", "x": 0, "y": 1.5 }, |
481 | "y": 0 | 124 | { "label": "!", "x": 1, "y": 1.5 }, |
482 | }, | 125 | { "label": "@", "x": 2, "y": 1.5 }, |
483 | { | 126 | { "label": "#", "x": 3, "y": 1.5 }, |
484 | "label": "F4", | 127 | { "label": "$", "x": 4, "y": 1.5 }, |
485 | "x": 5, | 128 | { "label": "%", "x": 5, "y": 1.5 }, |
486 | "y": 0 | 129 | { "label": "^", "x": 6, "y": 1.5 }, |
487 | }, | 130 | { "label": "&", "x": 7, "y": 1.5 }, |
488 | { | 131 | { "label": "*", "x": 8, "y": 1.5 }, |
489 | "label": "F5", | 132 | { "label": "(", "x": 9, "y": 1.5 }, |
490 | "x": 6.5, | 133 | { "label": ")", "x": 10, "y": 1.5 }, |
491 | "y": 0 | 134 | { "label": "_", "x": 11, "y": 1.5 }, |
492 | }, | 135 | { "label": "+", "x": 12, "y": 1.5 }, |
493 | { | 136 | { "label": "Backspace", "x": 13, "y": 1.5, "w": 2 }, |
494 | "label": "F6", | 137 | { "label": "Insert", "x": 15.25, "y": 1.5 }, |
495 | "x": 7.5, | 138 | { "label": "Home", "x": 16.25, "y": 1.5 }, |
496 | "y": 0 | 139 | { "label": "PgUp", "x": 17.25, "y": 1.5 }, |
497 | }, | 140 | |
498 | { | 141 | { "label": "Tab", "x": 0, "y": 2.5, "w": 1.5 }, |
499 | "label": "F7", | 142 | { "label": "Q", "x": 1.5, "y": 2.5 }, |
500 | "x": 8.5, | 143 | { "label": "W", "x": 2.5, "y": 2.5 }, |
501 | "y": 0 | 144 | { "label": "E", "x": 3.5, "y": 2.5 }, |
502 | }, | 145 | { "label": "R", "x": 4.5, "y": 2.5 }, |
503 | { | 146 | { "label": "T", "x": 5.5, "y": 2.5 }, |
504 | "label": "F8", | 147 | { "label": "Y", "x": 6.5, "y": 2.5 }, |
505 | "x": 9.5, | 148 | { "label": "U", "x": 7.5, "y": 2.5 }, |
506 | "y": 0 | 149 | { "label": "I", "x": 8.5, "y": 2.5 }, |
507 | }, | 150 | { "label": "O", "x": 9.5, "y": 2.5 }, |
508 | { | 151 | { "label": "P", "x": 10.5, "y": 2.5 }, |
509 | "label": "F9", | 152 | { "label": "{", "x": 11.5, "y": 2.5 }, |
510 | "x": 11, | 153 | { "label": "}", "x": 12.5, "y": 2.5 }, |
511 | "y": 0 | 154 | { "label": "Delete", "x": 15.25, "y": 2.5 }, |
512 | }, | 155 | { "label": "End", "x": 16.25, "y": 2.5 }, |
513 | { | 156 | { "label": "PgDn", "x": 17.25, "y": 2.5 }, |
514 | "label": "F10", | 157 | |
515 | "x": 12, | 158 | { "label": "Caps Lock", "x": 0, "y": 3.5, "w": 1.75 }, |
516 | "y": 0 | 159 | { "label": "A", "x": 1.75, "y": 3.5 }, |
517 | }, | 160 | { "label": "S", "x": 2.75, "y": 3.5 }, |
518 | { | 161 | { "label": "D", "x": 3.75, "y": 3.5 }, |
519 | "label": "F11", | 162 | { "label": "F", "x": 4.75, "y": 3.5 }, |
520 | "x": 13, | 163 | { "label": "G", "x": 5.75, "y": 3.5 }, |
521 | "y": 0 | 164 | { "label": "H", "x": 6.75, "y": 3.5 }, |
522 | }, | 165 | { "label": "J", "x": 7.75, "y": 3.5 }, |
523 | { | 166 | { "label": "K", "x": 8.75, "y": 3.5 }, |
524 | "label": "F12", | 167 | { "label": "L", "x": 9.75, "y": 3.5 }, |
525 | "x": 14, | 168 | { "label": ":", "x": 10.75, "y": 3.5 }, |
526 | "y": 0 | 169 | { "label": "\"", "x": 11.75, "y": 3.5 }, |
527 | }, | 170 | { "label": "#", "x": 12.75, "y": 3.5 }, |
528 | { | 171 | { "label": "Enter", "x": 13.75, "y": 2.5, "w": 1.25, "h": 2 }, |
529 | "label": "PrtSc", | 172 | |
530 | "x": 15.25, | 173 | { "label": "Shift", "x": 0, "y": 4.5, "w": 1.25 }, |
531 | "y": 0 | 174 | { "label": "\\", "x": 1.25, "y": 4.5 }, |
532 | }, | 175 | { "label": "Z", "x": 2.25, "y": 4.5 }, |
533 | { | 176 | { "label": "X", "x": 3.25, "y": 4.5 }, |
534 | "label": "Scroll Lock", | 177 | { "label": "C", "x": 4.25, "y": 4.5 }, |
535 | "x": 16.25, | 178 | { "label": "V", "x": 5.25, "y": 4.5 }, |
536 | "y": 0 | 179 | { "label": "B", "x": 6.25, "y": 4.5 }, |
537 | }, | 180 | { "label": "N", "x": 7.25, "y": 4.5 }, |
538 | { | 181 | { "label": "M", "x": 8.25, "y": 4.5 }, |
539 | "label": "Pause", | 182 | { "label": "<", "x": 9.25, "y": 4.5 }, |
540 | "x": 17.25, | 183 | { "label": ">", "x": 10.25, "y": 4.5 }, |
541 | "y": 0 | 184 | { "label": "?", "x": 11.25, "y": 4.5 }, |
542 | }, | 185 | { "label": "Shift", "x": 12.25, "y": 4.5, "w": 2.75 }, |
543 | { | 186 | { "label": "\u2191", "x": 16.25, "y": 4.5 }, |
544 | "label": "~", | 187 | |
545 | "x": 0, | 188 | { "label": "Ctrl", "x": 0, "y": 5.5, "w": 1.25 }, |
546 | "y": 1.5 | 189 | { "label": "Win", "x": 1.25, "y": 5.5, "w": 1.25 }, |
547 | }, | 190 | { "label": "Alt", "x": 2.5, "y": 5.5, "w": 1.25 }, |
548 | { | 191 | { "x": 3.75, "y": 5.5, "w": 6.25 }, |
549 | "label": "!", | 192 | { "label": "Alt", "x": 10, "y": 5.5, "w": 1.25 }, |
550 | "x": 1, | 193 | { "label": "Fn", "x": 11.25, "y": 5.5, "w": 1.25 }, |
551 | "y": 1.5 | 194 | { "label": "Menu", "x": 12.5, "y": 5.5, "w": 1.25 }, |
552 | }, | 195 | { "label": "Ctrl", "x": 13.75, "y": 5.5, "w": 1.25 }, |
553 | { | 196 | { "label": "\u2190", "x": 15.25, "y": 5.5 }, |
554 | "label": "@", | 197 | { "label": "\u2193", "x": 16.25, "y": 5.5 }, |
555 | "x": 2, | 198 | { "label": "\u2192", "x": 17.25, "y": 5.5 } |
556 | "y": 1.5 | 199 | ] |
557 | }, | 200 | }, |
558 | { | 201 | "LAYOUT_all": { |
559 | "label": "#", | 202 | "layout": [ |
560 | "x": 3, | 203 | { "label": "Esc", "x": 0, "y": 0 }, |
561 | "y": 1.5 | 204 | { "label": "F1", "x": 2, "y": 0 }, |
562 | }, | 205 | { "label": "F2", "x": 3, "y": 0 }, |
563 | { | 206 | { "label": "F3", "x": 4, "y": 0 }, |
564 | "label": "$", | 207 | { "label": "F4", "x": 5, "y": 0 }, |
565 | "x": 4, | 208 | { "label": "F5", "x": 6.5, "y": 0 }, |
566 | "y": 1.5 | 209 | { "label": "F6", "x": 7.5, "y": 0 }, |
567 | }, | 210 | { "label": "F7", "x": 8.5, "y": 0 }, |
568 | { | 211 | { "label": "F8", "x": 9.5, "y": 0 }, |
569 | "label": "%", | 212 | { "label": "F9", "x": 11, "y": 0 }, |
570 | "x": 5, | 213 | { "label": "F10", "x": 12, "y": 0 }, |
571 | "y": 1.5 | 214 | { "label": "F11", "x": 13, "y": 0 }, |
572 | }, | 215 | { "label": "F12", "x": 14, "y": 0 }, |
573 | { | 216 | { "label": "PrtSc", "x": 15.25, "y": 0 }, |
574 | "label": "^", | 217 | { "label": "Scroll Lock", "x": 16.25, "y": 0 }, |
575 | "x": 6, | 218 | { "label": "Pause", "x": 17.25, "y": 0 }, |
576 | "y": 1.5 | 219 | |
577 | }, | 220 | { "label": "~", "x": 0, "y": 1.5 }, |
578 | { | 221 | { "label": "!", "x": 1, "y": 1.5 }, |
579 | "label": "&", | 222 | { "label": "@", "x": 2, "y": 1.5 }, |
580 | "x": 7, | 223 | { "label": "#", "x": 3, "y": 1.5 }, |
581 | "y": 1.5 | 224 | { "label": "$", "x": 4, "y": 1.5 }, |
582 | }, | 225 | { "label": "%", "x": 5, "y": 1.5 }, |
583 | { | 226 | { "label": "^", "x": 6, "y": 1.5 }, |
584 | "label": "*", | 227 | { "label": "&", "x": 7, "y": 1.5 }, |
585 | "x": 8, | 228 | { "label": "*", "x": 8, "y": 1.5 }, |
586 | "y": 1.5 | 229 | { "label": "(", "x": 9, "y": 1.5 }, |
587 | }, | 230 | { "label": ")", "x": 10, "y": 1.5 }, |
588 | { | 231 | { "label": "_", "x": 11, "y": 1.5 }, |
589 | "label": "(", | 232 | { "label": "+", "x": 12, "y": 1.5 }, |
590 | "x": 9, | 233 | { "label": "Backspace", "x": 13, "y": 1.5, "w": 2 }, |
591 | "y": 1.5 | 234 | { "label": "Insert", "x": 15.25, "y": 1.5 }, |
592 | }, | 235 | { "label": "Home", "x": 16.25, "y": 1.5 }, |
593 | { | 236 | { "label": "PgUp", "x": 17.25, "y": 1.5 }, |
594 | "label": ")", | 237 | |
595 | "x": 10, | 238 | { "label": "Tab", "x": 0, "y": 2.5, "w": 1.5 }, |
596 | "y": 1.5 | 239 | { "label": "Q", "x": 1.5, "y": 2.5 }, |
597 | }, | 240 | { "label": "W", "x": 2.5, "y": 2.5 }, |
598 | { | 241 | { "label": "E", "x": 3.5, "y": 2.5 }, |
599 | "label": "_", | 242 | { "label": "R", "x": 4.5, "y": 2.5 }, |
600 | "x": 11, | 243 | { "label": "T", "x": 5.5, "y": 2.5 }, |
601 | "y": 1.5 | 244 | { "label": "Y", "x": 6.5, "y": 2.5 }, |
602 | }, | 245 | { "label": "U", "x": 7.5, "y": 2.5 }, |
603 | { | 246 | { "label": "I", "x": 8.5, "y": 2.5 }, |
604 | "label": "+", | 247 | { "label": "O", "x": 9.5, "y": 2.5 }, |
605 | "x": 12, | 248 | { "label": "P", "x": 10.5, "y": 2.5 }, |
606 | "y": 1.5 | 249 | { "label": "{", "x": 11.5, "y": 2.5 }, |
607 | }, | 250 | { "label": "}", "x": 12.5, "y": 2.5 }, |
608 | { | 251 | { "label": "|", "x": 13.5, "y": 2.5, "w": 1.5 }, |
609 | "label": "Backspace", | 252 | { "label": "Delete", "x": 15.25, "y": 2.5 }, |
610 | "x": 13, | 253 | { "label": "End", "x": 16.25, "y": 2.5 }, |
611 | "y": 1.5, | 254 | { "label": "PgDn", "x": 17.25, "y": 2.5 }, |
612 | "w": 2 | 255 | |
613 | }, | 256 | { "label": "Caps Lock", "x": 0, "y": 3.5, "w": 1.75 }, |
614 | { | 257 | { "label": "A", "x": 1.75, "y": 3.5 }, |
615 | "label": "Insert", | 258 | { "label": "S", "x": 2.75, "y": 3.5 }, |
616 | "x": 15.25, | 259 | { "label": "D", "x": 3.75, "y": 3.5 }, |
617 | "y": 1.5 | 260 | { "label": "F", "x": 4.75, "y": 3.5 }, |
618 | }, | 261 | { "label": "G", "x": 5.75, "y": 3.5 }, |
619 | { | 262 | { "label": "H", "x": 6.75, "y": 3.5 }, |
620 | "label": "Home", | 263 | { "label": "J", "x": 7.75, "y": 3.5 }, |
621 | "x": 16.25, | 264 | { "label": "K", "x": 8.75, "y": 3.5 }, |
622 | "y": 1.5 | 265 | { "label": "L", "x": 9.75, "y": 3.5 }, |
623 | }, | 266 | { "label": ":", "x": 10.75, "y": 3.5 }, |
624 | { | 267 | { "label": "\"", "x": 11.75, "y": 3.5 }, |
625 | "label": "PgUp", | 268 | { "label": "#", "x": 12.75, "y": 3.5 }, |
626 | "x": 17.25, | 269 | { "label": "Enter", "x": 13.75, "y": 3.5, "w": 1.25 }, |
627 | "y": 1.5 | 270 | |
628 | }, | 271 | { "label": "Shift", "x": 0, "y": 4.5, "w": 1.25 }, |
629 | { | 272 | { "label": "\\", "x": 1.25, "y": 4.5 }, |
630 | "label": "Tab", | 273 | { "label": "Z", "x": 2.25, "y": 4.5 }, |
631 | "x": 0, | 274 | { "label": "X", "x": 3.25, "y": 4.5 }, |
632 | "y": 2.5, | 275 | { "label": "C", "x": 4.25, "y": 4.5 }, |
633 | "w": 1.5 | 276 | { "label": "V", "x": 5.25, "y": 4.5 }, |
634 | }, | 277 | { "label": "B", "x": 6.25, "y": 4.5 }, |
635 | { | 278 | { "label": "N", "x": 7.25, "y": 4.5 }, |
636 | "label": "Q", | 279 | { "label": "M", "x": 8.25, "y": 4.5 }, |
637 | "x": 1.5, | 280 | { "label": "<", "x": 9.25, "y": 4.5 }, |
638 | "y": 2.5 | 281 | { "label": ">", "x": 10.25, "y": 4.5 }, |
639 | }, | 282 | { "label": "?", "x": 11.25, "y": 4.5 }, |
640 | { | 283 | { "label": "Shift", "x": 12.25, "y": 4.5, "w": 2.75 }, |
641 | "label": "W", | 284 | { "label": "\u2191", "x": 16.25, "y": 4.5 }, |
642 | "x": 2.5, | 285 | |
643 | "y": 2.5 | 286 | { "label": "Ctrl", "x": 0, "y": 5.5, "w": 1.25 }, |
644 | }, | 287 | { "label": "Win", "x": 1.25, "y": 5.5, "w": 1.25 }, |
645 | { | 288 | { "label": "Alt", "x": 2.5, "y": 5.5, "w": 1.25 }, |
646 | "label": "E", | 289 | { "x": 3.75, "y": 5.5, "w": 6.25 }, |
647 | "x": 3.5, | 290 | { "label": "Alt", "x": 10, "y": 5.5, "w": 1.25 }, |
648 | "y": 2.5 | 291 | { "label": "Fn", "x": 11.25, "y": 5.5, "w": 1.25 }, |
649 | }, | 292 | { "label": "Menu", "x": 12.5, "y": 5.5, "w": 1.25 }, |
650 | { | 293 | { "label": "Ctrl", "x": 13.75, "y": 5.5, "w": 1.25 }, |
651 | "label": "R", | 294 | { "label": "\u2190", "x": 15.25, "y": 5.5 }, |
652 | "x": 4.5, | 295 | { "label": "\u2193", "x": 16.25, "y": 5.5 }, |
653 | "y": 2.5 | 296 | { "label": "\u2192", "x": 17.25, "y": 5.5 } |
654 | }, | ||
655 | { | ||
656 | "label": "T", | ||
657 | "x": 5.5, | ||
658 | "y": 2.5 | ||
659 | }, | ||
660 | { | ||
661 | "label": "Y", | ||
662 | "x": 6.5, | ||
663 | "y": 2.5 | ||
664 | }, | ||
665 | { | ||
666 | "label": "U", | ||
667 | "x": 7.5, | ||
668 | "y": 2.5 | ||
669 | }, | ||
670 | { | ||
671 | "label": "I", | ||
672 | "x": 8.5, | ||
673 | "y": 2.5 | ||
674 | }, | ||
675 | { | ||
676 | "label": "O", | ||
677 | "x": 9.5, | ||
678 | "y": 2.5 | ||
679 | }, | ||
680 | { | ||
681 | "label": "P", | ||
682 | "x": 10.5, | ||
683 | "y": 2.5 | ||
684 | }, | ||
685 | { | ||
686 | "label": "{", | ||
687 | "x": 11.5, | ||
688 | "y": 2.5 | ||
689 | }, | ||
690 | { | ||
691 | "label": "}", | ||
692 | "x": 12.5, | ||
693 | "y": 2.5 | ||
694 | }, | ||
695 | { | ||
696 | "label": "Enter", | ||
697 | "x": 13.75, | ||
698 | "y": 2.5, | ||
699 | "w": 1.25, | ||
700 | "h": 2 | ||
701 | }, | ||
702 | { | ||
703 | "label": "Delete", | ||
704 | "x": 15.25, | ||
705 | "y": 2.5 | ||
706 | }, | ||
707 | { | ||
708 | "label": "End", | ||
709 | "x": 16.25, | ||
710 | "y": 2.5 | ||
711 | }, | ||
712 | { | ||
713 | "label": "PgDn", | ||
714 | "x": 17.25, | ||
715 | "y": 2.5 | ||
716 | }, | ||
717 | { | ||
718 | "label": "Caps Lock", | ||
719 | "x": 0, | ||
720 | "y": 3.5, | ||
721 | "w": 1.75 | ||
722 | }, | ||
723 | { | ||
724 | "label": "A", | ||
725 | "x": 1.75, | ||
726 | "y": 3.5 | ||
727 | }, | ||
728 | { | ||
729 | "label": "S", | ||
730 | "x": 2.75, | ||
731 | "y": 3.5 | ||
732 | }, | ||
733 | { | ||
734 | "label": "D", | ||
735 | "x": 3.75, | ||
736 | "y": 3.5 | ||
737 | }, | ||
738 | { | ||
739 | "label": "F", | ||
740 | "x": 4.75, | ||
741 | "y": 3.5 | ||
742 | }, | ||
743 | { | ||
744 | "label": "G", | ||
745 | "x": 5.75, | ||
746 | "y": 3.5 | ||
747 | }, | ||
748 | { | ||
749 | "label": "H", | ||
750 | "x": 6.75, | ||
751 | "y": 3.5 | ||
752 | }, | ||
753 | { | ||
754 | "label": "J", | ||
755 | "x": 7.75, | ||
756 | "y": 3.5 | ||
757 | }, | ||
758 | { | ||
759 | "label": "K", | ||
760 | "x": 8.75, | ||
761 | "y": 3.5 | ||
762 | }, | ||
763 | { | ||
764 | "label": "L", | ||
765 | "x": 9.75, | ||
766 | "y": 3.5 | ||
767 | }, | ||
768 | { | ||
769 | "label": ":", | ||
770 | "x": 10.75, | ||
771 | "y": 3.5 | ||
772 | }, | ||
773 | { | ||
774 | "label": "\"", | ||
775 | "x": 11.75, | ||
776 | "y": 3.5 | ||
777 | }, | ||
778 | { | ||
779 | "label": "#", | ||
780 | "x": 12.75, | ||
781 | "y": 3.5 | ||
782 | }, | ||
783 | { | ||
784 | "label": "Shift", | ||
785 | "x": 0, | ||
786 | "y": 4.5, | ||
787 | "w": 1.25 | ||
788 | }, | ||
789 | { | ||
790 | "label": "\\", | ||
791 | "x": 1.25, | ||
792 | "y": 4.5 | ||
793 | }, | ||
794 | { | ||
795 | "label": "Z", | ||
796 | "x": 2.25, | ||
797 | "y": 4.5 | ||
798 | }, | ||
799 | { | ||
800 | "label": "X", | ||
801 | "x": 3.25, | ||
802 | "y": 4.5 | ||
803 | }, | ||
804 | { | ||
805 | "label": "C", | ||
806 | "x": 4.25, | ||
807 | "y": 4.5 | ||
808 | }, | ||
809 | { | ||
810 | "label": "V", | ||
811 | "x": 5.25, | ||
812 | "y": 4.5 | ||
813 | }, | ||
814 | { | ||
815 | "label": "B", | ||
816 | "x": 6.25, | ||
817 | "y": 4.5 | ||
818 | }, | ||
819 | { | ||
820 | "label": "N", | ||
821 | "x": 7.25, | ||
822 | "y": 4.5 | ||
823 | }, | ||
824 | { | ||
825 | "label": "M", | ||
826 | "x": 8.25, | ||
827 | "y": 4.5 | ||
828 | }, | ||
829 | { | ||
830 | "label": "<", | ||
831 | "x": 9.25, | ||
832 | "y": 4.5 | ||
833 | }, | ||
834 | { | ||
835 | "label": ">", | ||
836 | "x": 10.25, | ||
837 | "y": 4.5 | ||
838 | }, | ||
839 | { | ||
840 | "label": "?", | ||
841 | "x": 11.25, | ||
842 | "y": 4.5 | ||
843 | }, | ||
844 | { | ||
845 | "label": "Shift", | ||
846 | "x": 12.25, | ||
847 | "y": 4.5, | ||
848 | "w": 2.75 | ||
849 | }, | ||
850 | { | ||
851 | "label": "\u2191", | ||
852 | "x": 16.25, | ||
853 | "y": 4.5 | ||
854 | }, | ||
855 | { | ||
856 | "label": "Ctrl", | ||
857 | "x": 0, | ||
858 | "y": 5.5, | ||
859 | "w": 1.25 | ||
860 | }, | ||
861 | { | ||
862 | "label": "Win", | ||
863 | "x": 1.25, | ||
864 | "y": 5.5, | ||
865 | "w": 1.25 | ||
866 | }, | ||
867 | { | ||
868 | "label": "Alt", | ||
869 | "x": 2.5, | ||
870 | "y": 5.5, | ||
871 | "w": 1.25 | ||
872 | }, | ||
873 | { | ||
874 | "x": 3.75, | ||
875 | "y": 5.5, | ||
876 | "w": 6.25 | ||
877 | }, | ||
878 | { | ||
879 | "label": "Alt", | ||
880 | "x": 10, | ||
881 | "y": 5.5, | ||
882 | "w": 1.25 | ||
883 | }, | ||
884 | { | ||
885 | "label": "Fn", | ||
886 | "x": 11.25, | ||
887 | "y": 5.5, | ||
888 | "w": 1.25 | ||
889 | }, | ||
890 | { | ||
891 | "label": "Menu", | ||
892 | "x": 12.5, | ||
893 | "y": 5.5, | ||
894 | "w": 1.25 | ||
895 | }, | ||
896 | { | ||
897 | "label": "Ctrl", | ||
898 | "x": 13.75, | ||
899 | "y": 5.5, | ||
900 | "w": 1.25 | ||
901 | }, | ||
902 | { | ||
903 | "label": "\u2190", | ||
904 | "x": 15.25, | ||
905 | "y": 5.5 | ||
906 | }, | ||
907 | { | ||
908 | "label": "\u2193", | ||
909 | "x": 16.25, | ||
910 | "y": 5.5 | ||
911 | }, | ||
912 | { | ||
913 | "label": "\u2192", | ||
914 | "x": 17.25, | ||
915 | "y": 5.5 | ||
916 | } | ||
917 | ] | 297 | ] |
918 | } | 298 | } |
919 | } | 299 | } |
diff --git a/keyboards/durgod/k320/k320.c b/keyboards/durgod/k320/k320.c index f5500ea83..42091f36c 100644 --- a/keyboards/durgod/k320/k320.c +++ b/keyboards/durgod/k320/k320.c | |||
@@ -40,3 +40,23 @@ void led_init_ports(void) { | |||
40 | off_all_leds(); | 40 | off_all_leds(); |
41 | } | 41 | } |
42 | 42 | ||
43 | |||
44 | #ifndef WINLOCK_DISABLED | ||
45 | static bool win_key_locked = false; | ||
46 | |||
47 | bool process_record_kb(uint16_t keycode, keyrecord_t *record) { | ||
48 | switch (keycode) { | ||
49 | case KC_TGUI: | ||
50 | if (record->event.pressed) { | ||
51 | // Toggle GUI lock on key press | ||
52 | win_key_locked = !win_key_locked; | ||
53 | writePin(LED_WIN_LOCK_PIN, !win_key_locked); | ||
54 | } | ||
55 | break; | ||
56 | case KC_LGUI: | ||
57 | if (win_key_locked) { return false; } | ||
58 | break; | ||
59 | } | ||
60 | return process_record_user(keycode, record); | ||
61 | } | ||
62 | #endif /* WINLOCK_DISABLED */ | ||
diff --git a/keyboards/durgod/k320/k320.h b/keyboards/durgod/k320/k320.h index 48da04841..c504f5a2b 100644 --- a/keyboards/durgod/k320/k320.h +++ b/keyboards/durgod/k320/k320.h | |||
@@ -17,6 +17,17 @@ | |||
17 | 17 | ||
18 | #include "quantum.h" | 18 | #include "quantum.h" |
19 | 19 | ||
20 | #ifndef WINLOCK_DISABLED | ||
21 | // Define the TGUI key here so it is available in QMK configurator | ||
22 | enum K320_keycodes { | ||
23 | KC_TGUI = SAFE_RANGE, // Toggle between GUI Lock or Unlock | ||
24 | NEW_SAFE_RANGE | ||
25 | }; | ||
26 | |||
27 | #undef SAFE_RANGE | ||
28 | #define SAFE_RANGE NEW_SAFE_RANGE | ||
29 | #endif /* WINLOCK_DISABLED */ | ||
30 | |||
20 | /* Function Prototype */ | 31 | /* Function Prototype */ |
21 | void off_all_leds(void); | 32 | void off_all_leds(void); |
22 | void on_all_leds(void); | 33 | void on_all_leds(void); |
@@ -26,12 +37,12 @@ void on_all_leds(void); | |||
26 | 37 | ||
27 | // This a shortcut to help you visually see your layout. | 38 | // This a shortcut to help you visually see your layout. |
28 | #define LAYOUT_tkl_ansi( \ | 39 | #define LAYOUT_tkl_ansi( \ |
29 | K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ | 40 | K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ |
30 | K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1E, K2E, K2F, K1F, \ | 41 | K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1E, K2E, K2F, K1F, \ |
31 | K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K3D, K3E, K3F, \ | 42 | K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K3D, K3E, K3F, \ |
32 | K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K4E, \ | 43 | K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K4E, \ |
33 | K40, K42, K43, K44, K45, K46, K47, K48, K49, K4A, K4B, K4D, K4F, \ | 44 | K40, K42, K43, K44, K45, K46, K47, K48, K49, K4A, K4B, K4D, K4F, \ |
34 | K50, K51, K52, K56, K5A, K5B, K5C, K5D, K5E, K5F, K6F \ | 45 | K50, K51, K52, K56, K5A, K5B, K5C, K5D, K5E, K5F, K6F \ |
35 | ) { \ | 46 | ) { \ |
36 | { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F }, \ | 47 | { K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F }, \ |
37 | { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, XXX, K1E, K1F }, \ | 48 | { K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, XXX, K1E, K1F }, \ |
@@ -45,10 +56,10 @@ void on_all_leds(void); | |||
45 | 56 | ||
46 | // This a shortcut to help you visually see your layout. | 57 | // This a shortcut to help you visually see your layout. |
47 | #define LAYOUT_tkl_iso( \ | 58 | #define LAYOUT_tkl_iso( \ |
48 | K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ | 59 | K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ |
49 | K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1E, K2E, K2F, K1F, \ | 60 | K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1E, K2E, K2F, K1F, \ |
50 | K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K4E, K3D, K3E, K3F, \ | 61 | K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K3D, K3E, K3F, \ |
51 | K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, \ | 62 | K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K4E, \ |
52 | K40, K41, K42, K43, K44, K45, K46, K47, K48, K49, K4A, K4B, K4D, K4F, \ | 63 | K40, K41, K42, K43, K44, K45, K46, K47, K48, K49, K4A, K4B, K4D, K4F, \ |
53 | K50, K51, K52, K56, K5A, K5B, K5C, K5D, K5E, K5F, K6F \ | 64 | K50, K51, K52, K56, K5A, K5B, K5C, K5D, K5E, K5F, K6F \ |
54 | ) { \ | 65 | ) { \ |
@@ -64,7 +75,7 @@ void on_all_leds(void); | |||
64 | 75 | ||
65 | // This a shortcut to help you visually see your layout. | 76 | // This a shortcut to help you visually see your layout. |
66 | #define LAYOUT_all( \ | 77 | #define LAYOUT_all( \ |
67 | K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ | 78 | K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, \ |
68 | K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1E, K2E, K2F, K1F, \ | 79 | K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1E, K2E, K2F, K1F, \ |
69 | K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K3D, K3E, K3F, \ | 80 | K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K3D, K3E, K3F, \ |
70 | K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K4E, \ | 81 | K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K4E, \ |
diff --git a/keyboards/durgod/k320/keymaps/default/keymap.c b/keyboards/durgod/k320/keymaps/default/keymap.c deleted file mode 100644 index 49a14ec29..000000000 --- a/keyboards/durgod/k320/keymaps/default/keymap.c +++ /dev/null | |||
@@ -1,95 +0,0 @@ | |||
1 | /* Copyright 2021 kuenhlee and Don Kjer | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include QMK_KEYBOARD_H | ||
17 | |||
18 | // Layer shorthand | ||
19 | enum _layer { | ||
20 | _BASE, | ||
21 | _FUNC | ||
22 | }; | ||
23 | |||
24 | static bool win_key_locked = false; | ||
25 | |||
26 | // Defines the keycodes used by our macros in process_record_user | ||
27 | enum custom_keycodes { | ||
28 | KC_TGUI = SAFE_RANGE // Toggle between GUI Lock or Unlock | ||
29 | }; | ||
30 | |||
31 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
32 | /* Keymap _BASE: Base Layer (Default Layer) | ||
33 | * ,-----------------------------------------------------------. ,--------------. | ||
34 | * |Esc |f1| f2| f3| f4| | f5| f6| f7| f8| | f9|f10|f11|f12| |Prnt|ScLk|Paus| | ||
35 | * |-----------------------------------------------------------| |--------------| | ||
36 | * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0| - | = |Backsp | | Ins|Home|PgUp| | ||
37 | * |-----------------------------------------------------------| |--------------| | ||
38 | * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \| | Del| End|PgDn| | ||
39 | * |-----------------------------------------------------------| `--------------' | ||
40 | * |CAPS | A| S| D| F| G| H| J| K| L| ;| '|Return | | ||
41 | * |-----------------------------------------------------------| ,----. | ||
42 | * |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift | | Up | | ||
43 | * |-----------------------------------------------------------| ,-------------. | ||
44 | * |Ctrl|Gui |Alt | Space |Alt |Func |App |Ctrl| |Lft| Dn |Rig | | ||
45 | * `-----------------------------------------------------------' `-------------' | ||
46 | */ | ||
47 | [_BASE] = LAYOUT_tkl_ansi( /* Base Layer */ | ||
48 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, | ||
49 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, | ||
50 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, | ||
51 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, | ||
52 | KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, | ||
53 | KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(_FUNC),KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT | ||
54 | ), | ||
55 | /* Keymap _FUNC: Function Layer | ||
56 | * ,-----------------------------------------------------------. ,--------------. | ||
57 | * | |Play|Stop|Prev|Next| |Mute|Vol+|Vol-| | | | | | | | | | | | ||
58 | * |-----------------------------------------------------------| |--------------| | ||
59 | * | | | | | | | | | | | | | | | | | | | | ||
60 | * |-----------------------------------------------------------| |--------------| | ||
61 | * | | | | | | | | | | | | | | | | | | | | ||
62 | * |-----------------------------------------------------------| `--------------' | ||
63 | * | | | | | | | | | | | | | | | ||
64 | * |-----------------------------------------------------------| ,----. | ||
65 | * | | | | | | | | | | | | | | | | ||
66 | * |-----------------------------------------------------------| ,-------------. | ||
67 | * | |Lock| | | |Func | | | | | | | | ||
68 | * `-----------------------------------------------------------' `-------------' | ||
69 | */ | ||
70 | [_FUNC] = LAYOUT_tkl_ansi( /* Function Layer */ | ||
71 | _______, KC_MPLY, KC_MSTP, KC_MRWD, KC_MFFD, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, | ||
72 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
73 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
74 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
75 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
76 | _______, KC_TGUI, _______, _______, _______, _______, _______, _______, _______, _______, _______ | ||
77 | ) | ||
78 | }; | ||
79 | |||
80 | bool process_record_user(uint16_t keycode, keyrecord_t *record) { | ||
81 | switch (keycode) { | ||
82 | case KC_TGUI: | ||
83 | if (!record->event.pressed) { | ||
84 | // Toggle GUI lock on key release | ||
85 | win_key_locked = !win_key_locked; | ||
86 | writePin(LED_WIN_LOCK_PIN, !win_key_locked); | ||
87 | } | ||
88 | break; | ||
89 | case KC_LGUI: | ||
90 | if (win_key_locked) { return false; } | ||
91 | break; | ||
92 | } | ||
93 | return true; | ||
94 | } | ||
95 | |||
diff --git a/keyboards/durgod/k320/keymaps/default/keymap.json b/keyboards/durgod/k320/keymaps/default/keymap.json new file mode 100644 index 000000000..d8242ae76 --- /dev/null +++ b/keyboards/durgod/k320/keymaps/default/keymap.json | |||
@@ -0,0 +1,26 @@ | |||
1 | { | ||
2 | "keyboard": "durgod/k320", | ||
3 | "keymap": "default", | ||
4 | "layout": "LAYOUT_all", | ||
5 | "layers": [ | ||
6 | [ | ||
7 | "KC_ESC", "KC_F1", "KC_F2", "KC_F3", "KC_F4", "KC_F5", "KC_F6", "KC_F7", "KC_F8", "KC_F9", "KC_F10", "KC_F11", "KC_F12", "KC_PSCR", "KC_SLCK", "KC_PAUS", | ||
8 | "KC_GRV", "KC_1", "KC_2", "KC_3", "KC_4", "KC_5", "KC_6", "KC_7", "KC_8", "KC_9", "KC_0", "KC_MINS", "KC_EQL", "KC_BSPC", "KC_INS", "KC_HOME", "KC_PGUP", | ||
9 | "KC_TAB", "KC_Q", "KC_W", "KC_E", "KC_R", "KC_T", "KC_Y", "KC_U", "KC_I", "KC_O", "KC_P", "KC_LBRC", "KC_RBRC", "KC_BSLS", "KC_DEL", "KC_END", "KC_PGDN", | ||
10 | "KC_CAPS", "KC_A", "KC_S", "KC_D", "KC_F", "KC_G", "KC_H", "KC_J", "KC_K", "KC_L", "KC_SCLN", "KC_QUOT", "KC_NUHS", "KC_ENT", | ||
11 | "KC_LSFT", "KC_NUBS", "KC_Z", "KC_X", "KC_C", "KC_V", "KC_B", "KC_N", "KC_M", "KC_COMM", "KC_DOT", "KC_SLSH", "KC_RSFT", "KC_UP", | ||
12 | "KC_LCTL", "KC_LGUI", "KC_LALT", "KC_SPC", "KC_RALT", "MO(1)", "KC_APP", "KC_RCTL", "KC_LEFT", "KC_DOWN", "KC_RGHT" | ||
13 | ], | ||
14 | [ | ||
15 | "KC_TRNS", "KC_MPLY", "KC_MSTP", "KC_MPRV", "KC_MNXT", "KC_MUTE", "KC_VOLD", "KC_VOLU", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
16 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
17 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
18 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
19 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
20 | "KC_TRNS", "KC_TGUI", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS" | ||
21 | ] | ||
22 | ], | ||
23 | "author":"dkjer", | ||
24 | "notes":"", | ||
25 | "version":1 | ||
26 | } | ||
diff --git a/keyboards/durgod/k320/keymaps/default/readme.md b/keyboards/durgod/k320/keymaps/default/readme.md index e26c79c8a..c94943a83 100644 --- a/keyboards/durgod/k320/keymaps/default/readme.md +++ b/keyboards/durgod/k320/keymaps/default/readme.md | |||
@@ -1,6 +1,8 @@ | |||
1 | # The default keymap for Durgod Taurus K320. | 1 | # The default keymap for Durgod Taurus K320. |
2 | 2 | ||
3 | Layer 0 : Standard ANSI 87 Keys TKL layout (Windows) | 3 | Supports both ANSI and ISO layouts. |
4 | |||
5 | Layer 0 : Standard 87/88 keys TKL layout (Windows) | ||
4 | 6 | ||
5 | Layer 1 : Media control and Windows lock key | 7 | Layer 1 : Media control and Windows lock key |
6 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 | 8 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 |
diff --git a/keyboards/durgod/k320/keymaps/default_iso/keymap.c b/keyboards/durgod/k320/keymaps/default_iso/keymap.c deleted file mode 100644 index 559b6fe71..000000000 --- a/keyboards/durgod/k320/keymaps/default_iso/keymap.c +++ /dev/null | |||
@@ -1,72 +0,0 @@ | |||
1 | /* Copyright 2021 kuenhlee and Don Kjer | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include QMK_KEYBOARD_H | ||
17 | |||
18 | // Layer shorthand | ||
19 | enum _layer { | ||
20 | _BASE, | ||
21 | _FUNC | ||
22 | }; | ||
23 | |||
24 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
25 | /* Keymap _BASE: Base Layer (Default Layer) | ||
26 | * ,-----------------------------------------------------------. ,--------------. | ||
27 | * |Esc |f1| f2| f3| f4| | f5| f6| f7| f8| | f9|f10|f11|f12| |Prnt|ScLk|Paus| | ||
28 | * |-----------------------------------------------------------| |--------------| | ||
29 | * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0| - | = |Backsp | | Ins|Home|PgUp| | ||
30 | * |-----------------------------------------------------------| |--------------| | ||
31 | * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| | | Del| End|PgDn| | ||
32 | * |------------------------------------------------------ Ret | `--------------' | ||
33 | * |CAPS | A| S| D| F| G| H| J| K| L| ;| '| #| | | ||
34 | * |-----------------------------------------------------------| ,----. | ||
35 | * |Shift| \| Z| X| C| V| B| N| M| ,| .| /|Shift | | Up | | ||
36 | * |-----------------------------------------------------------| ,-------------. | ||
37 | * |Ctrl|Gui |Alt | Space |Alt | Fn |App |Ctrl| |Lft| Dn |Rig | | ||
38 | * `-----------------------------------------------------------' `-------------' | ||
39 | */ | ||
40 | [_BASE] = LAYOUT_tkl_iso( /* Base Layer */ | ||
41 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, | ||
42 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, | ||
43 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_ENT, KC_DEL, KC_END, KC_PGDN, | ||
44 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, | ||
45 | KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, | ||
46 | KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(_FUNC),KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT | ||
47 | ), | ||
48 | /* Keymap _FUNC: Function Layer | ||
49 | * ,-----------------------------------------------------------. ,--------------. | ||
50 | * | |Play|Stop|Prev|Next| |Mute|Vol+|Vol-| | | | | | | | | | | | ||
51 | * |-----------------------------------------------------------| |--------------| | ||
52 | * | | | | | | | | | | | | | | | | | | | | ||
53 | * |-----------------------------------------------------------| |--------------| | ||
54 | * | | | | | | | | | | | | | | | | | | | | ||
55 | * |------------------------------------------------------- | `--------------' | ||
56 | * | | | | | | | | | | | | | | | | ||
57 | * |-----------------------------------------------------------| ,----. | ||
58 | * | | | | | | | | | | | | | | | | | ||
59 | * |-----------------------------------------------------------| ,-------------. | ||
60 | * | | | | | |Func | | | | | | | | ||
61 | * `-----------------------------------------------------------' `-------------' | ||
62 | */ | ||
63 | [_FUNC] = LAYOUT_tkl_iso( /* Function Layer */ | ||
64 | _______, KC_MPLY, KC_MSTP, KC_MRWD, KC_MFFD, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, | ||
65 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
66 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
67 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
68 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
69 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ | ||
70 | ) | ||
71 | }; | ||
72 | |||
diff --git a/keyboards/durgod/k320/keymaps/default_iso/readme.md b/keyboards/durgod/k320/keymaps/default_iso/readme.md deleted file mode 100644 index a7d1d5f1d..000000000 --- a/keyboards/durgod/k320/keymaps/default_iso/readme.md +++ /dev/null | |||
@@ -1,7 +0,0 @@ | |||
1 | # The ISO keymap for Durgod Taurus K320. | ||
2 | |||
3 | Layer 0 : Standard ISO 88 Keys TKL layout (Windows) | ||
4 | |||
5 | Layer 1 : Media control and Windows lock key | ||
6 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 | ||
7 | |||
diff --git a/keyboards/durgod/k320/keymaps/default_iso_mac/keymap.c b/keyboards/durgod/k320/keymaps/default_iso_mac/keymap.c deleted file mode 100644 index 783fc45f1..000000000 --- a/keyboards/durgod/k320/keymaps/default_iso_mac/keymap.c +++ /dev/null | |||
@@ -1,71 +0,0 @@ | |||
1 | /* Copyright 2021 kuenhlee and Don Kjer | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include QMK_KEYBOARD_H | ||
17 | |||
18 | // Layer shorthand | ||
19 | enum _layer { | ||
20 | _BASE, | ||
21 | _FUNC | ||
22 | }; | ||
23 | |||
24 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
25 | /* Keymap _BASE: Base Layer (Default Layer) | ||
26 | * ,-----------------------------------------------------------. ,--------------. | ||
27 | * |Esc |f1| f2| f3| f4| | f5| f6| f7| f8| | f9|f10|f11|f12| |Prnt|ScLk|Paus| | ||
28 | * |-----------------------------------------------------------| |--------------| | ||
29 | * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0| - | = |Backsp | | Ins|Home|PgUp| | ||
30 | * |-----------------------------------------------------------| |--------------| | ||
31 | * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| | | Del| End|PgDn| | ||
32 | * |------------------------------------------------------ Ret | `--------------' | ||
33 | * |CAPS | A| S| D| F| G| H| J| K| L| ;| '| #| | | ||
34 | * |-----------------------------------------------------------| ,----. | ||
35 | * |Shift| \| Z| X| C| V| B| N| M| ,| .| /|Shift | | Up | | ||
36 | * |-----------------------------------------------------------| ,-------------. | ||
37 | * |Ctrl|Alt |Gui | Space |Alt | Fn |App |Ctrl| |Lft| Dn |Rig | | ||
38 | * `-----------------------------------------------------------' `-------------' | ||
39 | */ | ||
40 | [_BASE] = LAYOUT_tkl_iso( /* Base Layer */ | ||
41 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, | ||
42 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, | ||
43 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_ENT, KC_DEL, KC_END, KC_PGDN, | ||
44 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, | ||
45 | KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, | ||
46 | KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_RALT, MO(_FUNC),KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT | ||
47 | ), | ||
48 | /* Keymap _FUNC: Function Layer | ||
49 | * ,-----------------------------------------------------------. ,--------------. | ||
50 | * | |Play|Stop|Prev|Next| |Mute|Vol+|Vol-| | | | | | | | | | | | ||
51 | * |-----------------------------------------------------------| |--------------| | ||
52 | * | | | | | | | | | | | | | | | | | | | | ||
53 | * |-----------------------------------------------------------| |--------------| | ||
54 | * | | | | | | | | | | | | | | | | | | | | ||
55 | * |------------------------------------------------------- | `--------------' | ||
56 | * | | | | | | | | | | | | | | | | ||
57 | * |-----------------------------------------------------------| ,----. | ||
58 | * | | | | | | | | | | | | | | | | | ||
59 | * |-----------------------------------------------------------| ,-------------. | ||
60 | * | | | | | |Func | | | | | | | | ||
61 | * `-----------------------------------------------------------' `-------------' | ||
62 | */ | ||
63 | [_FUNC] = LAYOUT_tkl_iso( /* Function Layer */ | ||
64 | _______, KC_MPLY, KC_MSTP, KC_MRWD, KC_MFFD, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, | ||
65 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
66 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
67 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
68 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
69 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ | ||
70 | ) | ||
71 | }; | ||
diff --git a/keyboards/durgod/k320/keymaps/default_iso_mac/readme.md b/keyboards/durgod/k320/keymaps/default_iso_mac/readme.md deleted file mode 100644 index 354f7b4cb..000000000 --- a/keyboards/durgod/k320/keymaps/default_iso_mac/readme.md +++ /dev/null | |||
@@ -1,6 +0,0 @@ | |||
1 | # The ISO (Mac) keymap for Durgod Taurus K320. | ||
2 | |||
3 | Layer 0 : Standard ISO 88 Keys TKL layout (Mac) | ||
4 | |||
5 | Layer 1 : Media control | ||
6 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 | ||
diff --git a/keyboards/durgod/k320/keymaps/default_mac/keymap.json b/keyboards/durgod/k320/keymaps/default_mac/keymap.json new file mode 100644 index 000000000..dc5d3d3fd --- /dev/null +++ b/keyboards/durgod/k320/keymaps/default_mac/keymap.json | |||
@@ -0,0 +1,26 @@ | |||
1 | { | ||
2 | "keyboard": "durgod/k320", | ||
3 | "keymap": "default_mac", | ||
4 | "layout": "LAYOUT_all", | ||
5 | "layers": [ | ||
6 | [ | ||
7 | "KC_ESC", "KC_F1", "KC_F2", "KC_F3", "KC_F4", "KC_F5", "KC_F6", "KC_F7", "KC_F8", "KC_F9", "KC_F10", "KC_F11", "KC_F12", "KC_F13", "KC_F14", "KC_F15", | ||
8 | "KC_GRV", "KC_1", "KC_2", "KC_3", "KC_4", "KC_5", "KC_6", "KC_7", "KC_8", "KC_9", "KC_0", "KC_MINS", "KC_EQL", "KC_BSPC", "KC_INS", "KC_HOME", "KC_PGUP", | ||
9 | "KC_TAB", "KC_Q", "KC_W", "KC_E", "KC_R", "KC_T", "KC_Y", "KC_U", "KC_I", "KC_O", "KC_P", "KC_LBRC", "KC_RBRC", "KC_BSLS", "KC_DEL", "KC_END", "KC_PGDN", | ||
10 | "KC_CAPS", "KC_A", "KC_S", "KC_D", "KC_F", "KC_G", "KC_H", "KC_J", "KC_K", "KC_L", "KC_SCLN", "KC_QUOT", "KC_NUHS", "KC_ENT", | ||
11 | "KC_LSFT", "KC_NUBS", "KC_Z", "KC_X", "KC_C", "KC_V", "KC_B", "KC_N", "KC_M", "KC_COMM", "KC_DOT", "KC_SLSH", "KC_RSFT", "KC_UP", | ||
12 | "KC_LCTL", "KC_LALT", "KC_LGUI", "KC_SPC", "KC_RGUI", "KC_RALT", "MO(1)", "KC_RCTL", "KC_LEFT", "KC_DOWN", "KC_RGHT" | ||
13 | ], | ||
14 | [ | ||
15 | "KC_TRNS", "KC_MPLY", "KC_MSTP", "KC_MPRV", "KC_MNXT", "KC_MUTE", "KC_VOLD", "KC_VOLU", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
16 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
17 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
18 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
19 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", | ||
20 | "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS" | ||
21 | ] | ||
22 | ], | ||
23 | "author":"AlCutter", | ||
24 | "notes":"", | ||
25 | "version":1 | ||
26 | } | ||
diff --git a/keyboards/durgod/k320/keymaps/default_mac/readme.md b/keyboards/durgod/k320/keymaps/default_mac/readme.md new file mode 100644 index 000000000..2765f14f9 --- /dev/null +++ b/keyboards/durgod/k320/keymaps/default_mac/readme.md | |||
@@ -0,0 +1,8 @@ | |||
1 | # The default (Mac) keymap for Durgod Taurus K320. | ||
2 | |||
3 | Supports both ANSI and ISO layouts. | ||
4 | |||
5 | Layer 0 : Standard 87/88 keys TKL layout (Mac) | ||
6 | |||
7 | Layer 1 : Media control | ||
8 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 | ||
diff --git a/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/keymap.c b/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/keymap.c index 834d2ca55..8494fbe03 100644 --- a/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/keymap.c +++ b/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/keymap.c | |||
@@ -59,20 +59,20 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
59 | * |-----------------------------------------------------------| |--------------| | 59 | * |-----------------------------------------------------------| |--------------| |
60 | * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \| | Del| End|PgDn| | 60 | * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \| | Del| End|PgDn| |
61 | * |-----------------------------------------------------------| `--------------' | 61 | * |-----------------------------------------------------------| `--------------' |
62 | * |CAPS | A| S| D| F| G| H| J| K| L| ;| '|Return | | 62 | * |CAPS | A| S| D| F| G| H| J| K| L| ;| '| #|Ret | |
63 | * |-----------------------------------------------------------| ,----. | 63 | * |-----------------------------------------------------------| ,----. |
64 | * |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift | | Up | | 64 | * |Shift| \| Z| X| C| V| B| N| M| ,| .| /|Shift | | Up | |
65 | * |-----------------------------------------------------------| ,-------------. | 65 | * |-----------------------------------------------------------| ,-------------. |
66 | * |Ctrl|Gui |Alt | Space |Alt |Func |App|Ctrl | |Lft| Dn |Rig | | 66 | * |Ctrl|Gui |Alt | Space |Alt |Func |App|Ctrl | |Lft| Dn |Rig | |
67 | * `-----------------------------------------------------------' `-------------' | 67 | * `-----------------------------------------------------------' `-------------' |
68 | */ | 68 | */ |
69 | [_WBL] = LAYOUT_tkl_ansi( /* Windows Base Layer */ | 69 | [_WBL] = LAYOUT_all( /* Windows Base Layer */ |
70 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, | 70 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, |
71 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, | 71 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, |
72 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, | 72 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, |
73 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, | 73 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, |
74 | KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, | 74 | KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, |
75 | KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_WFN, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT | 75 | KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_WFN, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT |
76 | ), | 76 | ), |
77 | /* Keymap _WFL: Windows Function Layer | 77 | /* Keymap _WFL: Windows Function Layer |
78 | * ,-----------------------------------------------------------. ,--------------. | 78 | * ,-----------------------------------------------------------. ,--------------. |
@@ -82,20 +82,20 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
82 | * |-----------------------------------------------------------| |--------------| | 82 | * |-----------------------------------------------------------| |--------------| |
83 | * | | | | | | | | | | | | | | | | | | | | 83 | * | | | | | | | | | | | | | | | | | | | |
84 | * |-----------------------------------------------------------| `--------------' | 84 | * |-----------------------------------------------------------| `--------------' |
85 | * | | | | | | | | | | | | | | | 85 | * | | | | | | | | | | | | | | | |
86 | * |-----------------------------------------------------------| ,----. | 86 | * |-----------------------------------------------------------| ,----. |
87 | * | | | | | | | | | | | | | | | | 87 | * | | | | | | | | | | | | | | | | |
88 | * |-----------------------------------------------------------| ,-------------. | 88 | * |-----------------------------------------------------------| ,-------------. |
89 | * | |Lock| | | |Func |Sys| | | | | | | 89 | * | |Lock| | | |Func |Sys| | | | | | |
90 | * `-----------------------------------------------------------' `-------------' | 90 | * `-----------------------------------------------------------' `-------------' |
91 | */ | 91 | */ |
92 | [_WFL] = LAYOUT_tkl_ansi( /* Windows First Layer */ | 92 | [_WFL] = LAYOUT_all( /* Windows First Layer */ |
93 | _______, KC_MPLY, KC_MSTP, KC_MRWD, KC_MFFD, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, | 93 | _______, KC_MPLY, KC_MSTP, KC_MPRV, KC_MNXT, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, |
94 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 94 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
95 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 95 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
96 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 96 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
97 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 97 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
98 | _______, KC_TGUI, _______, _______, _______, _______, MO_WSL, _______, _______, _______, _______ | 98 | _______, KC_TGUI, _______, _______, _______, _______, MO_WSL, _______, _______, _______, _______ |
99 | ), | 99 | ), |
100 | /* Keymap _WSL: Windows System Layer | 100 | /* Keymap _WSL: Windows System Layer |
101 | * ,-----------------------------------------------------------. ,--------------. | 101 | * ,-----------------------------------------------------------. ,--------------. |
@@ -105,20 +105,20 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
105 | * |-----------------------------------------------------------| |--------------| | 105 | * |-----------------------------------------------------------| |--------------| |
106 | * | | | | | | | | | | | | | | | | | | | | 106 | * | | | | | | | | | | | | | | | | | | | |
107 | * |-----------------------------------------------------------| `--------------' | 107 | * |-----------------------------------------------------------| `--------------' |
108 | * | | | | | | | | | | | | | | | 108 | * | | | | | | | | | | | | | | | |
109 | * |-----------------------------------------------------------| ,----. | 109 | * |-----------------------------------------------------------| ,----. |
110 | * | | | | | | | | | | | | | | | | 110 | * | | | | | | | | | | | | | | | | |
111 | * |-----------------------------------------------------------| ,-------------. | 111 | * |-----------------------------------------------------------| ,-------------. |
112 | * | | | | | |Func |Sys| | | | | | | 112 | * | | | | | |Func |Sys| | | | | | |
113 | * `-----------------------------------------------------------' `-------------' | 113 | * `-----------------------------------------------------------' `-------------' |
114 | */ | 114 | */ |
115 | [_WSL] = LAYOUT_tkl_ansi( /* Windows Second / System Layer */ | 115 | [_WSL] = LAYOUT_all( /* Windows Second / System Layer */ |
116 | RESET, KC_SLEP, XXXXXXX, XXXXXXX, KC_PWR, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, DF_W2MBL, XXXXXXX, XXXXXXX, XXXXXXX, | 116 | RESET, KC_SLEP, XXXXXXX, XXXXXXX, KC_PWR, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, DF_W2MBL, XXXXXXX, XXXXXXX, XXXXXXX, |
117 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 117 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
118 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 118 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
119 | XXXXXXX, XXXXXXX, XXXXXXX, DEBUG, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 119 | XXXXXXX, XXXXXXX, XXXXXXX, DEBUG, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
120 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 120 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
121 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX | 121 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX |
122 | ), | 122 | ), |
123 | 123 | ||
124 | /* Keymap _MBL: Mac Base Layer (Alternate Layout) | 124 | /* Keymap _MBL: Mac Base Layer (Alternate Layout) |
@@ -129,20 +129,20 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
129 | * |-----------------------------------------------------------| |--------------| | 129 | * |-----------------------------------------------------------| |--------------| |
130 | * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \| | Del| End|PgDn| | 130 | * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \| | Del| End|PgDn| |
131 | * |-----------------------------------------------------------| `--------------' | 131 | * |-----------------------------------------------------------| `--------------' |
132 | * |CAPS | A| S| D| F| G| H| J| K| L| ;| '|Return | | 132 | * |CAPS | A| S| D| F| G| H| J| K| L| ;| '| #|Ret | |
133 | * |-----------------------------------------------------------| ,----. | 133 | * |-----------------------------------------------------------| ,----. |
134 | * |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift | | Up | | 134 | * |Shift| \| Z| X| C| V| B| N| M| ,| .| /|Shift | | Up | |
135 | * |-----------------------------------------------------------| ,-------------. | 135 | * |-----------------------------------------------------------| ,-------------. |
136 | * |Ctrl|Alt |Gui | Space |Gui |Alt|Func |Ctrl | |Lft| Dn |Rig | | 136 | * |Ctrl|Alt |Gui | Space |Gui |Alt|Func |Ctrl | |Lft| Dn |Rig | |
137 | * `-----------------------------------------------------------' `-------------' | 137 | * `-----------------------------------------------------------' `-------------' |
138 | */ | 138 | */ |
139 | [_MBL] = LAYOUT_tkl_ansi( /* Mac Base Layer */ | 139 | [_MBL] = LAYOUT_all( /* Mac Base Layer */ |
140 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F13, KC_F14, KC_F15, | 140 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F13, KC_F14, KC_F15, |
141 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, | 141 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, |
142 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, | 142 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, |
143 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, | 143 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, |
144 | KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, | 144 | KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, |
145 | KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_RGUI, KC_RALT, KC_MFN, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT | 145 | KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_RGUI, KC_RALT, KC_MFN, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT |
146 | ), | 146 | ), |
147 | /* Keymap _MFL: Mac Function Layer | 147 | /* Keymap _MFL: Mac Function Layer |
148 | * ,-----------------------------------------------------------. ,--------------. | 148 | * ,-----------------------------------------------------------. ,--------------. |
@@ -152,20 +152,20 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
152 | * |-----------------------------------------------------------| |--------------| | 152 | * |-----------------------------------------------------------| |--------------| |
153 | * | | | | | | | | | | | | | | | | | | | | 153 | * | | | | | | | | | | | | | | | | | | | |
154 | * |-----------------------------------------------------------| `--------------' | 154 | * |-----------------------------------------------------------| `--------------' |
155 | * | | | | | | | | | | | | | | | 155 | * | | | | | | | | | | | | | | | |
156 | * |-----------------------------------------------------------| ,----. | 156 | * |-----------------------------------------------------------| ,----. |
157 | * | | | | | | | | | | | | | | | | 157 | * | | | | | | | | | | | | | | | | |
158 | * |-----------------------------------------------------------| ,-------------. | 158 | * |-----------------------------------------------------------| ,-------------. |
159 | * | | | | | |Sys|Func | | | | | | | 159 | * | | | | | |Sys|Func | | | | | | |
160 | * `-----------------------------------------------------------' `-------------' | 160 | * `-----------------------------------------------------------' `-------------' |
161 | */ | 161 | */ |
162 | [_MFL] = LAYOUT_tkl_ansi( /* Mac First Layer */ | 162 | [_MFL] = LAYOUT_all( /* Mac First Layer */ |
163 | _______, KC_BRID, KC_BRIU, _______, _______, _______, _______, KC_MRWD, KC_MPLY, KC_MFFD, KC_MUTE, KC_VOLD, KC_VOLU, KC_TMED, _______, _______, | 163 | _______, KC_BRID, KC_BRIU, _______, _______, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT, KC_MUTE, KC_VOLD, KC_VOLU, KC_TMED, _______, _______, |
164 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 164 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
165 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 165 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
166 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 166 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
167 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 167 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
168 | _______, _______, _______, _______, _______, MO_MSL, _______, _______, _______, _______, _______ | 168 | _______, _______, _______, _______, _______, MO_MSL, _______, _______, _______, _______, _______ |
169 | ), | 169 | ), |
170 | /* Keymap _MSL: Mac System Layer | 170 | /* Keymap _MSL: Mac System Layer |
171 | * ,-----------------------------------------------------------. ,--------------. | 171 | * ,-----------------------------------------------------------. ,--------------. |
@@ -175,20 +175,20 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
175 | * |-----------------------------------------------------------| |--------------| | 175 | * |-----------------------------------------------------------| |--------------| |
176 | * | | | | | | | | | | | | | | | | | | | | 176 | * | | | | | | | | | | | | | | | | | | | |
177 | * |-----------------------------------------------------------| `--------------' | 177 | * |-----------------------------------------------------------| `--------------' |
178 | * | | | | | | | | | | | | | | | 178 | * | | | | | | | | | | | | | | | |
179 | * |-----------------------------------------------------------| ,----. | 179 | * |-----------------------------------------------------------| ,----. |
180 | * | | | | | | | | | | | | | | | | 180 | * | | | | | | | | | | | | | | | | |
181 | * |-----------------------------------------------------------| ,-------------. | 181 | * |-----------------------------------------------------------| ,-------------. |
182 | * | | | | | |Sys|Func | | | | | | | 182 | * | | | | | |Sys|Func | | | | | | |
183 | * `-----------------------------------------------------------' `-------------' | 183 | * `-----------------------------------------------------------' `-------------' |
184 | */ | 184 | */ |
185 | [_MSL] = LAYOUT_tkl_ansi( /* Mac Second / System Layer */ | 185 | [_MSL] = LAYOUT_all( /* Mac Second / System Layer */ |
186 | RESET, XXXXXXX, XXXXXXX, XXXXXXX, KC_SLEP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, DF_M2WBL, XXXXXXX, XXXXXXX, XXXXXXX, | 186 | RESET, XXXXXXX, XXXXXXX, XXXXXXX, KC_SLEP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, DF_M2WBL, XXXXXXX, XXXXXXX, XXXXXXX, |
187 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 187 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
188 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 188 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
189 | XXXXXXX, XXXXXXX, XXXXXXX, DEBUG, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 189 | XXXXXXX, XXXXXXX, XXXXXXX, DEBUG, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
190 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | 190 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, |
191 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX | 191 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX |
192 | ) | 192 | ) |
193 | }; | 193 | }; |
194 | 194 | ||
diff --git a/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/readme.md b/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/readme.md index 821c8b26a..0eef77fd4 100644 --- a/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/readme.md +++ b/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/readme.md | |||
@@ -1,6 +1,8 @@ | |||
1 | # A keymap for Durgod Taurus K320 that supports toggling between Mac and Windows | 1 | # A keymap for Durgod Taurus K320 that supports toggling between Mac and Windows |
2 | 2 | ||
3 | Layer 0 : Standard ANSI 87 Keys TKL layout (Windows) | 3 | Supports both ANSI and ISO layouts. |
4 | |||
5 | Layer 0 : Standard 87/88 keys TKL layout (Windows) | ||
4 | 6 | ||
5 | Layer 1 : Media control and Windows lock key (Windows) | 7 | Layer 1 : Media control and Windows lock key (Windows) |
6 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 | 8 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 |
@@ -12,7 +14,7 @@ Layer 2 : System layer (Windows) | |||
12 | - Fn + Menu + F4 : Turning Off System | 14 | - Fn + Menu + F4 : Turning Off System |
13 | - Fn + Menu + F12 : Switch to Mac layout | 15 | - Fn + Menu + F12 : Switch to Mac layout |
14 | 16 | ||
15 | Layer 3 : Mac 87 Keys TKL layout | 17 | Layer 3 : Mac 87/88 keys TKL layout |
16 | 18 | ||
17 | Layer 4 : Media control and Media lock key (Mac) | 19 | Layer 4 : Media control and Media lock key (Mac) |
18 | - Standard Mac Media keys for Fn + F1 ~ Fn + F12. | 20 | - Standard Mac Media keys for Fn + F1 ~ Fn + F12. |
@@ -61,4 +63,3 @@ For repeating Flashing you have two options with this keymap: | |||
61 | 2. Use key combination if using default keymap | 63 | 2. Use key combination if using default keymap |
62 | - Hold down Fn + Menu (Windows Layout) or Fn + Right-Alt (Mac layout) (These are the same physical keys) | 64 | - Hold down Fn + Menu (Windows Layout) or Fn + Right-Alt (Mac layout) (These are the same physical keys) |
63 | - Press Esc. Keyboard should go into booloader state. | 65 | - Press Esc. Keyboard should go into booloader state. |
64 | |||
diff --git a/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/rules.mk b/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/rules.mk new file mode 100644 index 000000000..19843e8a2 --- /dev/null +++ b/keyboards/durgod/k320/keymaps/default_toggle_mac_windows/rules.mk | |||
@@ -0,0 +1 @@ | |||
OPT_DEFS += -DWINLOCK_DISABLED | |||
diff --git a/keyboards/durgod/k320/keymaps/kuenhlee/keymap.c b/keyboards/durgod/k320/keymaps/kuenhlee/keymap.c index bf79f24db..866e522fc 100644 --- a/keyboards/durgod/k320/keymaps/kuenhlee/keymap.c +++ b/keyboards/durgod/k320/keymaps/kuenhlee/keymap.c | |||
@@ -35,11 +35,6 @@ | |||
35 | #define KC_STOP LCTL(LSFT(KC_HOME)) // Select from Cursor to Home | 35 | #define KC_STOP LCTL(LSFT(KC_HOME)) // Select from Cursor to Home |
36 | #define KC_SEND LCTL(LSFT(KC_END)) // Select from Cursor to End | 36 | #define KC_SEND LCTL(LSFT(KC_END)) // Select from Cursor to End |
37 | 37 | ||
38 | // Defines the keycodes used by our macros in process_record_user | ||
39 | enum custom_keycodes { | ||
40 | KC_TGUI = SAFE_RANGE // Toggle between GUI Lock or Unlock | ||
41 | }; | ||
42 | |||
43 | // °±²³µ©ΩθΩ√∞∆≈≠→↓←↑≡■□●○∴«»÷≤≥Σ | 38 | // °±²³µ©ΩθΩ√∞∆≈≠→↓←↑≡■□●○∴«»÷≤≥Σ |
44 | // Defines the Enumeration for Unicode Map | 39 | // Defines the Enumeration for Unicode Map |
45 | enum unicode_names { | 40 | enum unicode_names { |
diff --git a/keyboards/durgod/k320/keymaps/via/keymap.c b/keyboards/durgod/k320/keymaps/via/keymap.c index 9a4d9ff38..fc46e3860 100644 --- a/keyboards/durgod/k320/keymaps/via/keymap.c +++ b/keyboards/durgod/k320/keymaps/via/keymap.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* Copyright 2021 kuenhlee and Don Kjer | 1 | /* Copyright 2021 Maxime Coirault |
2 | * | 2 | * |
3 | * This program is free software: you can redistribute it and/or modify | 3 | * This program is free software: you can redistribute it and/or modify |
4 | * it under the terms of the GNU General Public License as published by | 4 | * it under the terms of the GNU General Public License as published by |
@@ -19,7 +19,8 @@ | |||
19 | enum _layer { | 19 | enum _layer { |
20 | _BASE, | 20 | _BASE, |
21 | _FUNC, | 21 | _FUNC, |
22 | _LAYER3 | 22 | _LAYER3, |
23 | _LAYER4 | ||
23 | }; | 24 | }; |
24 | 25 | ||
25 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | 26 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { |
@@ -39,12 +40,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
39 | * `-----------------------------------------------------------' `-------------' | 40 | * `-----------------------------------------------------------' `-------------' |
40 | */ | 41 | */ |
41 | [_BASE] = LAYOUT_all( /* Base Layer */ | 42 | [_BASE] = LAYOUT_all( /* Base Layer */ |
42 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, | 43 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, |
43 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, | 44 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, |
44 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, | 45 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, |
45 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, | 46 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT, |
46 | KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, | 47 | KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, |
47 | KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(_FUNC),KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT | 48 | KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(_FUNC),KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT |
48 | ), | 49 | ), |
49 | /* Keymap _FUNC: Function Layer | 50 | /* Keymap _FUNC: Function Layer |
50 | * ,-----------------------------------------------------------. ,--------------. | 51 | * ,-----------------------------------------------------------. ,--------------. |
@@ -62,20 +63,28 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
62 | * `-----------------------------------------------------------' `-------------' | 63 | * `-----------------------------------------------------------' `-------------' |
63 | */ | 64 | */ |
64 | [_FUNC] = LAYOUT_all( /* Function Layer */ | 65 | [_FUNC] = LAYOUT_all( /* Function Layer */ |
65 | _______, KC_MPLY, KC_MSTP, KC_MRWD, KC_MFFD, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, | 66 | _______, KC_MPLY, KC_MSTP, KC_MPRV, KC_MNXT, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, _______, _______, _______, |
66 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 67 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
67 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 68 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
68 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 69 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
69 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 70 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
70 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ | 71 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ |
71 | ), | 72 | ), |
72 | [_LAYER3] = LAYOUT_all( /* Function Layer */ | 73 | [_LAYER3] = LAYOUT_all( /* Layer 3 */ |
73 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 74 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
74 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 75 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
75 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 76 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
76 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 77 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
77 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | 78 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, |
78 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ | 79 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ |
79 | ), | 80 | ), |
81 | [_LAYER4] = LAYOUT_all( /* Layer 4 */ | ||
82 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
83 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
84 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
85 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
86 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
87 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ | ||
88 | ) | ||
80 | }; | 89 | }; |
81 | 90 | ||
diff --git a/keyboards/durgod/k320/keymaps/via/readme.md b/keyboards/durgod/k320/keymaps/via/readme.md index 1ed99238c..d1b2ac191 100644 --- a/keyboards/durgod/k320/keymaps/via/readme.md +++ b/keyboards/durgod/k320/keymaps/via/readme.md | |||
@@ -1,6 +1,6 @@ | |||
1 | # The default keymap for Durgod Taurus K320. | 1 | # The default keymap for Durgod Taurus K320. |
2 | 2 | ||
3 | Layer 0 : Standard Keys TKL layout | 3 | Layer 0 : Standard 87/88 keys TKL layout |
4 | 4 | ||
5 | Layer 1 : Media control | 5 | Layer 1 : Media control |
6 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 | 6 | - Reusing Durgod's Original Media Control for Fn + F1 ~ Fn + F7 |
diff --git a/keyboards/durgod/k320/keymaps/via/rules.mk b/keyboards/durgod/k320/keymaps/via/rules.mk index 36b7ba9cb..8815b6a0a 100644 --- a/keyboards/durgod/k320/keymaps/via/rules.mk +++ b/keyboards/durgod/k320/keymaps/via/rules.mk | |||
@@ -1,2 +1,4 @@ | |||
1 | OPT_DEFS += -DWINLOCK_DISABLED | ||
2 | |||
1 | VIA_ENABLE = yes | 3 | VIA_ENABLE = yes |
2 | LTO_ENABLE = yes | 4 | LTO_ENABLE = yes |
diff --git a/keyboards/durgod/k320/readme.md b/keyboards/durgod/k320/readme.md index 115029435..551a29282 100644 --- a/keyboards/durgod/k320/readme.md +++ b/keyboards/durgod/k320/readme.md | |||
@@ -1,6 +1,6 @@ | |||
1 | # K320 | 1 | # K320 |
2 | 2 | ||
3 | This is a standard fixed ANSI TKL from off the shelf Durgod Taurus K320 without Backlight. | 3 | This is a standard off-the-shelf Durgod Taurus K320 TKL (87/88-key) keyboard without backlight. |
4 | 4 | ||
5 | * Keyboard Maintainer: [dkjer](https://github.com/dkjer) | 5 | * Keyboard Maintainer: [dkjer](https://github.com/dkjer) |
6 | * Hardware Supported: Durgod Taurus K320 board with STM32F070RBT6 | 6 | * Hardware Supported: Durgod Taurus K320 board with STM32F070RBT6 |
@@ -30,7 +30,7 @@ For first Flashing from initial Stock's Firmware | |||
30 | - Plug In USB | 30 | - Plug In USB |
31 | - Make a Flash Image's Backup in case you wanted to restore the Keyboard to Stock's Image: | 31 | - Make a Flash Image's Backup in case you wanted to restore the Keyboard to Stock's Image: |
32 | - Using DFUseDemo.exe from ST's STSW-STM32080: https://www.st.com/en/development-tools/stsw-stm32080.html | 32 | - Using DFUseDemo.exe from ST's STSW-STM32080: https://www.st.com/en/development-tools/stsw-stm32080.html |
33 | - Using dfu-util (thanks to [tylert](https://github.com/tylert) for instructions!): | 33 | - Using dfu-util: |
34 | 34 | ||
35 | dfu-util --list | 35 | dfu-util --list |
36 | dfu-util --alt 0 --dfuse-address 0x08000000 --upload ${OLD_STOCK_BIN} | 36 | dfu-util --alt 0 --dfuse-address 0x08000000 --upload ${OLD_STOCK_BIN} |
@@ -55,4 +55,3 @@ For repeating Flashing you can use BootMagic: | |||
55 | - Unplug USB Cable | 55 | - Unplug USB Cable |
56 | - Holding Esc Button | 56 | - Holding Esc Button |
57 | - Plug in USB Cable, Keyboard should be in ST-Bootloader state | 57 | - Plug in USB Cable, Keyboard should be in ST-Bootloader state |
58 | |||
diff --git a/keyboards/durgod/k320/rules.mk b/keyboards/durgod/k320/rules.mk index 040ea2dc8..7e910174f 100644 --- a/keyboards/durgod/k320/rules.mk +++ b/keyboards/durgod/k320/rules.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # Actually F070, but close enough | 2 | # Actually F070, but close enough |
3 | MCU = STM32F072 | 3 | MCU = STM32F072 |
4 | 4 | ||
5 | BOARD = ST_NUCLEO64_F070RB | 5 | BOARD = DURGOD_STM32_F070 |
6 | 6 | ||
7 | # Do not put the microcontroller into power saving mode | 7 | # Do not put the microcontroller into power saving mode |
8 | OPT_DEFS += -DNO_SUSPEND_POWER_DOWN | 8 | OPT_DEFS += -DNO_SUSPEND_POWER_DOWN |
diff --git a/keyboards/dz60/keymaps/LEdiodes/rules.mk b/keyboards/dz60/keymaps/LEdiodes/rules.mk index 38b067eb0..251d25fad 100644 --- a/keyboards/dz60/keymaps/LEdiodes/rules.mk +++ b/keyboards/dz60/keymaps/LEdiodes/rules.mk | |||
@@ -1,7 +1,7 @@ | |||
1 | # Build Options | 1 | # Build Options |
2 | # comment out to disable the options. | 2 | # comment out to disable the options. |
3 | # | 3 | # |
4 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 4 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
5 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 5 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
6 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 6 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
7 | CONSOLE_ENABLE = no # Console for debug(+400) | 7 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/dz60/keymaps/krusli/rules.mk b/keyboards/dz60/keymaps/krusli/rules.mk index 3138a24b6..1e7c0f745 100644 --- a/keyboards/dz60/keymaps/krusli/rules.mk +++ b/keyboards/dz60/keymaps/krusli/rules.mk | |||
@@ -1,7 +1,7 @@ | |||
1 | # Build Options | 1 | # Build Options |
2 | # comment out to disable the options. | 2 | # comment out to disable the options. |
3 | # | 3 | # |
4 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 4 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
5 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 5 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
6 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 6 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
7 | CONSOLE_ENABLE = no # Console for debug(+400) | 7 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/dz60/keymaps/marianas/rules.mk b/keyboards/dz60/keymaps/marianas/rules.mk index 230d194ab..b68cc80cf 100644 --- a/keyboards/dz60/keymaps/marianas/rules.mk +++ b/keyboards/dz60/keymaps/marianas/rules.mk | |||
@@ -3,7 +3,7 @@ | |||
3 | # | 3 | # |
4 | 4 | ||
5 | 5 | ||
6 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 6 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
7 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 7 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
8 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 8 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
9 | CONSOLE_ENABLE = no # Console for debug(+400) | 9 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/dz60/rules.mk b/keyboards/dz60/rules.mk index a626f1f5d..1671c42e9 100644 --- a/keyboards/dz60/rules.mk +++ b/keyboards/dz60/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = atmel-dfu | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/dztech/bocc/rules.mk b/keyboards/dztech/bocc/rules.mk index 6695a40a6..2668874ea 100644 --- a/keyboards/dztech/bocc/rules.mk +++ b/keyboards/dztech/bocc/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = atmel-dfu | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/dztech/volcano660/rules.mk b/keyboards/dztech/volcano660/rules.mk index c23060121..e7aea4087 100644 --- a/keyboards/dztech/volcano660/rules.mk +++ b/keyboards/dztech/volcano660/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = atmel-dfu | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/ergodone/rules.mk b/keyboards/ergodone/rules.mk index f0008e48f..acd485f2f 100644 --- a/keyboards/ergodone/rules.mk +++ b/keyboards/ergodone/rules.mk | |||
@@ -16,7 +16,7 @@ BOOTLOADER = caterina | |||
16 | # | 16 | # |
17 | CUSTOM_MATRIX = yes # Custom matrix file for the ErgoDone | 17 | CUSTOM_MATRIX = yes # Custom matrix file for the ErgoDone |
18 | UNICODE_ENABLE = yes # Unicode | 18 | UNICODE_ENABLE = yes # Unicode |
19 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 19 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
20 | MOUSEKEY_ENABLE = yes # Mouse keys | 20 | MOUSEKEY_ENABLE = yes # Mouse keys |
21 | EXTRAKEY_ENABLE = yes # Audio control and System control | 21 | EXTRAKEY_ENABLE = yes # Audio control and System control |
22 | CONSOLE_ENABLE = no # Console for debug | 22 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/espectro/rules.mk b/keyboards/espectro/rules.mk index 065014b97..57a846fb3 100755 --- a/keyboards/espectro/rules.mk +++ b/keyboards/espectro/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/exclusive/e6_rgb/rules.mk b/keyboards/exclusive/e6_rgb/rules.mk index e9db9676b..7fbd7e81f 100644 --- a/keyboards/exclusive/e6_rgb/rules.mk +++ b/keyboards/exclusive/e6_rgb/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/fc660c/rules.mk b/keyboards/fc660c/rules.mk index 54fadc826..b4ed65362 100644 --- a/keyboards/fc660c/rules.mk +++ b/keyboards/fc660c/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | # BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | # BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/fc980c/rules.mk b/keyboards/fc980c/rules.mk index 54fadc826..b4ed65362 100644 --- a/keyboards/fc980c/rules.mk +++ b/keyboards/fc980c/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | # BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | # BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/felix/rules.mk b/keyboards/felix/rules.mk index 01db7a212..1fcdf216c 100644 --- a/keyboards/felix/rules.mk +++ b/keyboards/felix/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/flehrad/numbrero/rules.mk b/keyboards/flehrad/numbrero/rules.mk index 969dd0b50..d83407139 100644 --- a/keyboards/flehrad/numbrero/rules.mk +++ b/keyboards/flehrad/numbrero/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = no # Console for debug(+400) | 20 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/flehrad/snagpad/rules.mk b/keyboards/flehrad/snagpad/rules.mk index 566a398fe..fbc918ba4 100644 --- a/keyboards/flehrad/snagpad/rules.mk +++ b/keyboards/flehrad/snagpad/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/flehrad/tradestation/rules.mk b/keyboards/flehrad/tradestation/rules.mk index d3612c3c2..cf6c47d74 100644 --- a/keyboards/flehrad/tradestation/rules.mk +++ b/keyboards/flehrad/tradestation/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = no # Console for debug(+400) | 20 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/four_banger/rules.mk b/keyboards/four_banger/rules.mk index ae77f0a0e..b989b893b 100644 --- a/keyboards/four_banger/rules.mk +++ b/keyboards/four_banger/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/foxlab/leaf60/hotswap/rules.mk b/keyboards/foxlab/leaf60/hotswap/rules.mk index 6d4bcc7ef..b8332901c 100644 --- a/keyboards/foxlab/leaf60/hotswap/rules.mk +++ b/keyboards/foxlab/leaf60/hotswap/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/fr4/southpaw75/rules.mk b/keyboards/fr4/southpaw75/rules.mk index e70a8a7d6..bde08efba 100644 --- a/keyboards/fr4/southpaw75/rules.mk +++ b/keyboards/fr4/southpaw75/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = caterina | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/fractal/rules.mk b/keyboards/fractal/rules.mk index d83deb422..0952b247a 100755 --- a/keyboards/fractal/rules.mk +++ b/keyboards/fractal/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/funky40/rules.mk b/keyboards/funky40/rules.mk index 138ac68e2..c50d7999b 100644 --- a/keyboards/funky40/rules.mk +++ b/keyboards/funky40/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/gh60/satan/keymaps/denolfe/rules.mk b/keyboards/gh60/satan/keymaps/denolfe/rules.mk index 5a8745b68..4e002fc0f 100644 --- a/keyboards/gh60/satan/keymaps/denolfe/rules.mk +++ b/keyboards/gh60/satan/keymaps/denolfe/rules.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # Build Options | 2 | # Build Options |
3 | # comment out to disable the options. | 3 | # comment out to disable the options. |
4 | # | 4 | # |
5 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 5 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
6 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 6 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
8 | CONSOLE_ENABLE = yes # Console for debug(+400) | 8 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/gh60/satan/keymaps/iso_split_rshift/rules.mk b/keyboards/gh60/satan/keymaps/iso_split_rshift/rules.mk index 7b395f4cc..071edf30e 100644 --- a/keyboards/gh60/satan/keymaps/iso_split_rshift/rules.mk +++ b/keyboards/gh60/satan/keymaps/iso_split_rshift/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 1 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
2 | MOUSEKEY_ENABLE = no # Mouse keys | 2 | MOUSEKEY_ENABLE = no # Mouse keys |
3 | EXTRAKEY_ENABLE = yes # Audio control and System control | 3 | EXTRAKEY_ENABLE = yes # Audio control and System control |
4 | CONSOLE_ENABLE = yes # Console for debug | 4 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/gh60/satan/keymaps/olligranlund_iso/rules.mk b/keyboards/gh60/satan/keymaps/olligranlund_iso/rules.mk index 3d886f14f..4175ab137 100644 --- a/keyboards/gh60/satan/keymaps/olligranlund_iso/rules.mk +++ b/keyboards/gh60/satan/keymaps/olligranlund_iso/rules.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # change to "no" to disable the options, or define them in the Makefile in | 2 | # change to "no" to disable the options, or define them in the Makefile in |
3 | # the appropriate keymap folder that will get included automatically | 3 | # the appropriate keymap folder that will get included automatically |
4 | # | 4 | # |
5 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 5 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
6 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 6 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
8 | CONSOLE_ENABLE = no # Console for debug(+400) | 8 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/gskt00/rules.mk b/keyboards/gskt00/rules.mk index f0bbcad81..0011ec6ce 100755 --- a/keyboards/gskt00/rules.mk +++ b/keyboards/gskt00/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/handwired/2x5keypad/rules.mk b/keyboards/handwired/2x5keypad/rules.mk index 997c9c0e9..52f64eb3f 100644 --- a/keyboards/handwired/2x5keypad/rules.mk +++ b/keyboards/handwired/2x5keypad/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | 14 | ||
15 | AUDIO_ENABLE = no | 15 | AUDIO_ENABLE = no |
16 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality | 16 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | COMMAND_ENABLE = no # Commands for debug and configuration | 18 | COMMAND_ENABLE = no # Commands for debug and configuration |
19 | CONSOLE_ENABLE= no # Console for debug | 19 | CONSOLE_ENABLE= no # Console for debug |
20 | EXTRAKEY_ENABLE = yes # Audio control and System control | 20 | EXTRAKEY_ENABLE = yes # Audio control and System control |
diff --git a/keyboards/handwired/aek64/rules.mk b/keyboards/handwired/aek64/rules.mk index 52c306130..e5a1d648a 100644 --- a/keyboards/handwired/aek64/rules.mk +++ b/keyboards/handwired/aek64/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # change to no to disable the options. | 15 | # change to no to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = yes # Console for debug(+400) | 20 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/handwired/arrow_pad/keymaps/pad_21/rules.mk b/keyboards/handwired/arrow_pad/keymaps/pad_21/rules.mk index d2403c9ec..702538af3 100644 --- a/keyboards/handwired/arrow_pad/keymaps/pad_21/rules.mk +++ b/keyboards/handwired/arrow_pad/keymaps/pad_21/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 1 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
3 | EXTRAKEY_ENABLE = no # Audio control and System control(+450) | 3 | EXTRAKEY_ENABLE = no # Audio control and System control(+450) |
4 | CONSOLE_ENABLE = no # Console for debug(+400) | 4 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/handwired/arrow_pad/keymaps/pad_24/rules.mk b/keyboards/handwired/arrow_pad/keymaps/pad_24/rules.mk index b305f8482..12c820839 100644 --- a/keyboards/handwired/arrow_pad/keymaps/pad_24/rules.mk +++ b/keyboards/handwired/arrow_pad/keymaps/pad_24/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 1 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
3 | EXTRAKEY_ENABLE = no # Audio control and System control(+450) | 3 | EXTRAKEY_ENABLE = no # Audio control and System control(+450) |
4 | CONSOLE_ENABLE = no # Console for debug(+400) | 4 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/handwired/arrow_pad/rules.mk b/keyboards/handwired/arrow_pad/rules.mk index 65fc42a06..e1eb35c51 100644 --- a/keyboards/handwired/arrow_pad/rules.mk +++ b/keyboards/handwired/arrow_pad/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = yes # Console for debug(+400) | 20 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/handwired/ck4x4/rules.mk b/keyboards/handwired/ck4x4/rules.mk index 0709f341b..ebf1648c2 100644 --- a/keyboards/handwired/ck4x4/rules.mk +++ b/keyboards/handwired/ck4x4/rules.mk | |||
@@ -5,12 +5,12 @@ MCU = STM32F072 | |||
5 | # comment out to disable the options. | 5 | # comment out to disable the options. |
6 | # | 6 | # |
7 | 7 | ||
8 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 8 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
9 | MOUSEKEY_ENABLE = yes # Mouse keys | 9 | MOUSEKEY_ENABLE = yes # Mouse keys |
10 | EXTRAKEY_ENABLE = yes # Audio control and System control | 10 | EXTRAKEY_ENABLE = yes # Audio control and System control |
11 | CONSOLE_ENABLE = yes # Console for debug | 11 | CONSOLE_ENABLE = yes # Console for debug |
12 | COMMAND_ENABLE = yes # Commands for debug and configuration | 12 | COMMAND_ENABLE = yes # Commands for debug and configuration |
13 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 13 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
14 | NKRO_ENABLE = yes # USB Nkey Rollover | 14 | NKRO_ENABLE = yes # USB Nkey Rollover |
15 | CUSTOM_MATRIX = no # Custom matrix file | 15 | CUSTOM_MATRIX = no # Custom matrix file |
16 | 16 | ||
diff --git a/keyboards/handwired/co60/rev1/rules.mk b/keyboards/handwired/co60/rev1/rules.mk index ae50334a3..0986bed20 100644 --- a/keyboards/handwired/co60/rev1/rules.mk +++ b/keyboards/handwired/co60/rev1/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = no # Console for debug(+400) | 20 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/handwired/colorlice/rules.mk b/keyboards/handwired/colorlice/rules.mk index 77e6d03d6..077b197ef 100644 --- a/keyboards/handwired/colorlice/rules.mk +++ b/keyboards/handwired/colorlice/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/handwired/curiosity/rules.mk b/keyboards/handwired/curiosity/rules.mk index dace27ef3..d410771e8 100644 --- a/keyboards/handwired/curiosity/rules.mk +++ b/keyboards/handwired/curiosity/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = caterina | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/handwired/ddg_56/rules.mk b/keyboards/handwired/ddg_56/rules.mk index dfbb0959f..814338430 100644 --- a/keyboards/handwired/ddg_56/rules.mk +++ b/keyboards/handwired/ddg_56/rules.mk | |||
@@ -6,7 +6,7 @@ BOARD = QMK_PROTON_C | |||
6 | # change to "no" to disable the options, or define them in the Makefile in | 6 | # change to "no" to disable the options, or define them in the Makefile in |
7 | # the appropriate keymap folder that will get included automatically | 7 | # the appropriate keymap folder that will get included automatically |
8 | # | 8 | # |
9 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = no # Mouse keys | 10 | MOUSEKEY_ENABLE = no # Mouse keys |
11 | EXTRAKEY_ENABLE = no # Audio control and System control | 11 | EXTRAKEY_ENABLE = no # Audio control and System control |
12 | CONSOLE_ENABLE = no # Console for debug | 12 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/handwired/eagleii/rules.mk b/keyboards/handwired/eagleii/rules.mk index e45af67e5..aeee86d3a 100644 --- a/keyboards/handwired/eagleii/rules.mk +++ b/keyboards/handwired/eagleii/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes | 17 | BOOTMAGIC_ENABLE = full |
18 | MOUSEKEY_ENABLE = yes | 18 | MOUSEKEY_ENABLE = yes |
19 | EXTRAKEY_ENABLE = yes | 19 | EXTRAKEY_ENABLE = yes |
20 | CONSOLE_ENABLE = no | 20 | CONSOLE_ENABLE = no |
diff --git a/keyboards/handwired/fc200rt_qmk/rules.mk b/keyboards/handwired/fc200rt_qmk/rules.mk index fb1748db0..55a088771 100644 --- a/keyboards/handwired/fc200rt_qmk/rules.mk +++ b/keyboards/handwired/fc200rt_qmk/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/handwired/hexon38/rules.mk b/keyboards/handwired/hexon38/rules.mk index fb5e1b0c9..93b7a1176 100644 --- a/keyboards/handwired/hexon38/rules.mk +++ b/keyboards/handwired/hexon38/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32u4 | |||
12 | BOOTLOADER = halfkay | 12 | BOOTLOADER = halfkay |
13 | 13 | ||
14 | # Enabled build options: | 14 | # Enabled build options: |
15 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 15 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
16 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 16 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
17 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 17 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
18 | CONSOLE_ENABLE = yes # Console for debug(+400) | 18 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/handwired/minorca/rules.mk b/keyboards/handwired/minorca/rules.mk index 64837b88e..f3f1502de 100644 --- a/keyboards/handwired/minorca/rules.mk +++ b/keyboards/handwired/minorca/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/handwired/onekey/blackpill_f411_tinyuf2/chconf.h b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/chconf.h new file mode 100644 index 000000000..3d9a39363 --- /dev/null +++ b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/chconf.h | |||
@@ -0,0 +1,21 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #pragma once | ||
18 | |||
19 | #define CH_CFG_ST_FREQUENCY 10000 | ||
20 | |||
21 | #include_next <chconf.h> | ||
diff --git a/keyboards/handwired/onekey/blackpill_f411_tinyuf2/config.h b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/config.h new file mode 100755 index 000000000..95e99aacc --- /dev/null +++ b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/config.h | |||
@@ -0,0 +1,31 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #pragma once | ||
18 | |||
19 | #include "config_common.h" | ||
20 | |||
21 | #define MATRIX_COL_PINS { B0 } | ||
22 | #define MATRIX_ROW_PINS { A7 } | ||
23 | #define UNUSED_PINS | ||
24 | |||
25 | #define BACKLIGHT_PIN A0 | ||
26 | #define BACKLIGHT_PWM_DRIVER PWMD5 | ||
27 | #define BACKLIGHT_PWM_CHANNEL 1 | ||
28 | |||
29 | #define RGB_DI_PIN A1 | ||
30 | |||
31 | #define ADC_PIN A0 | ||
diff --git a/keyboards/handwired/onekey/blackpill_f411_tinyuf2/halconf.h b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/halconf.h new file mode 100644 index 000000000..e15870984 --- /dev/null +++ b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/halconf.h | |||
@@ -0,0 +1,22 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #pragma once | ||
18 | |||
19 | #define HAL_USE_I2C TRUE | ||
20 | #define HAL_USE_PWM TRUE | ||
21 | |||
22 | #include_next <halconf.h> | ||
diff --git a/keyboards/handwired/onekey/blackpill_f411_tinyuf2/mcuconf.h b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/mcuconf.h new file mode 100755 index 000000000..ad8aecdb1 --- /dev/null +++ b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/mcuconf.h | |||
@@ -0,0 +1,24 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <https://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #include_next "mcuconf.h" | ||
19 | |||
20 | #undef STM32_I2C_USE_I2C1 | ||
21 | #define STM32_I2C_USE_I2C1 TRUE | ||
22 | |||
23 | #undef STM32_PWM_USE_TIM5 | ||
24 | #define STM32_PWM_USE_TIM5 TRUE | ||
diff --git a/keyboards/handwired/onekey/blackpill_f411_tinyuf2/readme.md b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/readme.md new file mode 100755 index 000000000..ff43658f4 --- /dev/null +++ b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/readme.md | |||
@@ -0,0 +1,9 @@ | |||
1 | # f411 blackpill onekey | ||
2 | |||
3 | Supported Hardware: *STM32F411CEU6 WeAct v1.3*. | ||
4 | |||
5 | To trigger keypress, short together pins *B0* and *A7*. | ||
6 | |||
7 | This variant requires the TinyUF2 bootloader to be installed. This can be downloaded from the [tinyuf2 releases page](https://github.com/adafruit/tinyuf2/releases). The F401 blackpill binary works for both F401- and F411-based blackpill devices. | ||
8 | |||
9 | Double-tap reset to enter bootloader mode. Copy the built uf2 file to the device by dragging the file to the new USB disk. \ No newline at end of file | ||
diff --git a/keyboards/handwired/onekey/blackpill_f411_tinyuf2/rules.mk b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/rules.mk new file mode 100755 index 000000000..ec38577b2 --- /dev/null +++ b/keyboards/handwired/onekey/blackpill_f411_tinyuf2/rules.mk | |||
@@ -0,0 +1,10 @@ | |||
1 | # MCU name | ||
2 | MCU = STM32F411 | ||
3 | |||
4 | # Build Options | ||
5 | # change yes to no to disable | ||
6 | # | ||
7 | KEYBOARD_SHARED_EP = yes | ||
8 | |||
9 | # We want to use the tinyuf2 bootloader... | ||
10 | BOOTLOADER = tinyuf2 \ No newline at end of file | ||
diff --git a/keyboards/handwired/onekey/rules.mk b/keyboards/handwired/onekey/rules.mk index 259050d55..df2ec1ecf 100644 --- a/keyboards/handwired/onekey/rules.mk +++ b/keyboards/handwired/onekey/rules.mk | |||
@@ -7,9 +7,9 @@ EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | |||
7 | CONSOLE_ENABLE = yes # Console for debug(+400) | 7 | CONSOLE_ENABLE = yes # Console for debug(+400) |
8 | COMMAND_ENABLE = no # Commands for debug and configuration | 8 | COMMAND_ENABLE = no # Commands for debug and configuration |
9 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | 9 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE |
10 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 10 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
11 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | 11 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work |
12 | NKRO_ENABLE = yes # USB Nkey Rollover | 12 | NKRO_ENABLE = yes # USB Nkey Rollover |
13 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default | 13 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default |
14 | RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow | 14 | RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow |
15 | MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config) | 15 | MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config) |
diff --git a/keyboards/handwired/p1800fl/rules.mk b/keyboards/handwired/p1800fl/rules.mk index b85602bb9..cde197a0d 100644 --- a/keyboards/handwired/p1800fl/rules.mk +++ b/keyboards/handwired/p1800fl/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = qmk-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/handwired/p65rgb/rules.mk b/keyboards/handwired/p65rgb/rules.mk index 7e8ac8d55..00d15f090 100644 --- a/keyboards/handwired/p65rgb/rules.mk +++ b/keyboards/handwired/p65rgb/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = qmk-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/handwired/prkl30/feather/rules.mk b/keyboards/handwired/prkl30/feather/rules.mk index 27df4272a..366e53cf7 100644 --- a/keyboards/handwired/prkl30/feather/rules.mk +++ b/keyboards/handwired/prkl30/feather/rules.mk | |||
@@ -18,7 +18,7 @@ BOOTLOADER = caterina | |||
18 | # change yes to no to disable | 18 | # change yes to no to disable |
19 | # | 19 | # |
20 | BLUETOOTH = AdafruitBLE | 20 | BLUETOOTH = AdafruitBLE |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | ENCODER_ENABLE = yes | 22 | ENCODER_ENABLE = yes |
23 | MOUSEKEY_ENABLE = no # Mouse keys | 23 | MOUSEKEY_ENABLE = no # Mouse keys |
24 | EXTRAKEY_ENABLE = no # Audio control and System control | 24 | EXTRAKEY_ENABLE = no # Audio control and System control |
diff --git a/keyboards/handwired/retro_refit/rules.mk b/keyboards/handwired/retro_refit/rules.mk index 04db510d1..1506838a4 100644 --- a/keyboards/handwired/retro_refit/rules.mk +++ b/keyboards/handwired/retro_refit/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = yes # Console for debug(+400) | 20 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/handwired/space_oddity/rules.mk b/keyboards/handwired/space_oddity/rules.mk index a2e63690b..97f9cfd80 100644 --- a/keyboards/handwired/space_oddity/rules.mk +++ b/keyboards/handwired/space_oddity/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = no # Console for debug(+400) | 20 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/handwired/symmetry60/rules.mk b/keyboards/handwired/symmetry60/rules.mk index 905b15699..f41c45fff 100644 --- a/keyboards/handwired/symmetry60/rules.mk +++ b/keyboards/handwired/symmetry60/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/handwired/wulkan/rules.mk b/keyboards/handwired/wulkan/rules.mk index 96bfe18dd..94086e14f 100644 --- a/keyboards/handwired/wulkan/rules.mk +++ b/keyboards/handwired/wulkan/rules.mk | |||
@@ -6,7 +6,7 @@ BOARD = QMK_PROTON_C | |||
6 | # comment out to disable the options. | 6 | # comment out to disable the options. |
7 | # | 7 | # |
8 | BACKLIGHT_ENABLE = no | 8 | BACKLIGHT_ENABLE = no |
9 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = yes # Mouse keys | 10 | MOUSEKEY_ENABLE = yes # Mouse keys |
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = no # Console for debug | 12 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/hecomi/rules.mk b/keyboards/hecomi/rules.mk index 75686f922..f91432cad 100644 --- a/keyboards/hecomi/rules.mk +++ b/keyboards/hecomi/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/hhkb/ansi/rules.mk b/keyboards/hhkb/ansi/rules.mk index a367ef48d..3ff7170e0 100644 --- a/keyboards/hhkb/ansi/rules.mk +++ b/keyboards/hhkb/ansi/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/hhkb/jp/rules.mk b/keyboards/hhkb/jp/rules.mk index 774b444c5..f1294ed61 100644 --- a/keyboards/hhkb/jp/rules.mk +++ b/keyboards/hhkb/jp/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/hhkb_lite_2/rules.mk b/keyboards/hhkb_lite_2/rules.mk index dd0271792..aa224ffe4 100644 --- a/keyboards/hhkb_lite_2/rules.mk +++ b/keyboards/hhkb_lite_2/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = halfkay | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/hid_liber/keymaps/bakageta/rules.mk b/keyboards/hid_liber/keymaps/bakageta/rules.mk index 0f131bce9..1697e07c5 100755 --- a/keyboards/hid_liber/keymaps/bakageta/rules.mk +++ b/keyboards/hid_liber/keymaps/bakageta/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
22 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 22 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
24 | CONSOLE_ENABLE = yes # Console for debug(+400) | 24 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/hid_liber/rules.mk b/keyboards/hid_liber/rules.mk index 44833d755..ea64be00d 100755 --- a/keyboards/hid_liber/rules.mk +++ b/keyboards/hid_liber/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/honeycomb/rules.mk b/keyboards/honeycomb/rules.mk index d6f98125e..a9a01d867 100755 --- a/keyboards/honeycomb/rules.mk +++ b/keyboards/honeycomb/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | #MOUSEKEY_ENABLE = yes # Mouse keys | 18 | #MOUSEKEY_ENABLE = yes # Mouse keys |
19 | POINTING_DEVICE_ENABLE = yes # Generic Pointer, not as big as mouse keys hopefully. | 19 | POINTING_DEVICE_ENABLE = yes # Generic Pointer, not as big as mouse keys hopefully. |
20 | EXTRAKEY_ENABLE = yes # Audio control and System control | 20 | EXTRAKEY_ENABLE = yes # Audio control and System control |
diff --git a/keyboards/hotdox/rules.mk b/keyboards/hotdox/rules.mk index 95f6c7ec6..dd175e9f6 100644 --- a/keyboards/hotdox/rules.mk +++ b/keyboards/hotdox/rules.mk | |||
@@ -16,7 +16,7 @@ BOOTLOADER = atmel-dfu | |||
16 | # | 16 | # |
17 | CUSTOM_MATRIX = yes # Custom matrix file for the ErgoDone | 17 | CUSTOM_MATRIX = yes # Custom matrix file for the ErgoDone |
18 | UNICODE_ENABLE = yes # Unicode | 18 | UNICODE_ENABLE = yes # Unicode |
19 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 19 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
20 | MOUSEKEY_ENABLE = yes # Mouse keys | 20 | MOUSEKEY_ENABLE = yes # Mouse keys |
21 | EXTRAKEY_ENABLE = yes # Audio control and System control | 21 | EXTRAKEY_ENABLE = yes # Audio control and System control |
22 | CONSOLE_ENABLE = yes # Console for debug | 22 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/iron180/rules.mk b/keyboards/iron180/rules.mk index 2d2f71e19..a202eca61 100644 --- a/keyboards/iron180/rules.mk +++ b/keyboards/iron180/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/jd40/rules.mk b/keyboards/jd40/rules.mk index 73336244e..18780b47b 100644 --- a/keyboards/jd40/rules.mk +++ b/keyboards/jd40/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | # CONSOLE_ENABLE = yes # Console for debug | 20 | # CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/jd45/rules.mk b/keyboards/jd45/rules.mk index cc5af4b7a..82e70975d 100644 --- a/keyboards/jd45/rules.mk +++ b/keyboards/jd45/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/jj40/keymaps/fun40/rules.mk b/keyboards/jj40/keymaps/fun40/rules.mk index 92f168a16..3ec0a7515 100644 --- a/keyboards/jj40/keymaps/fun40/rules.mk +++ b/keyboards/jj40/keymaps/fun40/rules.mk | |||
@@ -1,6 +1,6 @@ | |||
1 | 1 | ||
2 | 2 | ||
3 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 3 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
4 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 4 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
5 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 5 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
6 | CONSOLE_ENABLE = no # Console for debug(+400) | 6 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/jj40/keymaps/waples/rules.mk b/keyboards/jj40/keymaps/waples/rules.mk index 69b7c18d4..4395f7f8f 100644 --- a/keyboards/jj40/keymaps/waples/rules.mk +++ b/keyboards/jj40/keymaps/waples/rules.mk | |||
@@ -1,5 +1,5 @@ | |||
1 | # build options | 1 | # build options |
2 | BOOTMAGIC_ENABLE = yes | 2 | BOOTMAGIC_ENABLE = full |
3 | MOUSEKEY_ENABLE = no | 3 | MOUSEKEY_ENABLE = no |
4 | EXTRAKEY_ENABLE = yes | 4 | EXTRAKEY_ENABLE = yes |
5 | CONSOLE_ENABLE = no | 5 | CONSOLE_ENABLE = no |
diff --git a/keyboards/kbdfans/bella/rgb/rules.mk b/keyboards/kbdfans/bella/rgb/rules.mk index a4fcb5782..bba2c1a6c 100644 --- a/keyboards/kbdfans/bella/rgb/rules.mk +++ b/keyboards/kbdfans/bella/rgb/rules.mk | |||
@@ -23,3 +23,5 @@ AUDIO_ENABLE = no # Audio output | |||
23 | RGB_MATRIX_ENABLE = yes | 23 | RGB_MATRIX_ENABLE = yes |
24 | RGB_MATRIX_DRIVER = IS31FL3741 | 24 | RGB_MATRIX_DRIVER = IS31FL3741 |
25 | NO_USB_STARTUP_CHECK = no # Disable initialization only when usb is plugged in | 25 | NO_USB_STARTUP_CHECK = no # Disable initialization only when usb is plugged in |
26 | |||
27 | LTO_ENABLE = yes | ||
diff --git a/keyboards/kbdfans/bella/rgb_iso/rules.mk b/keyboards/kbdfans/bella/rgb_iso/rules.mk index a4fcb5782..bba2c1a6c 100644 --- a/keyboards/kbdfans/bella/rgb_iso/rules.mk +++ b/keyboards/kbdfans/bella/rgb_iso/rules.mk | |||
@@ -23,3 +23,5 @@ AUDIO_ENABLE = no # Audio output | |||
23 | RGB_MATRIX_ENABLE = yes | 23 | RGB_MATRIX_ENABLE = yes |
24 | RGB_MATRIX_DRIVER = IS31FL3741 | 24 | RGB_MATRIX_DRIVER = IS31FL3741 |
25 | NO_USB_STARTUP_CHECK = no # Disable initialization only when usb is plugged in | 25 | NO_USB_STARTUP_CHECK = no # Disable initialization only when usb is plugged in |
26 | |||
27 | LTO_ENABLE = yes | ||
diff --git a/keyboards/kbdfans/kbd6x/rules.mk b/keyboards/kbdfans/kbd6x/rules.mk index e95a436c3..7d9f13e31 100644 --- a/keyboards/kbdfans/kbd6x/rules.mk +++ b/keyboards/kbdfans/kbd6x/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/kbdfans/kbd75/keymaps/tucznak/rules.mk b/keyboards/kbdfans/kbd75/keymaps/tucznak/rules.mk index 7d6400f97..c854fdd2d 100644 --- a/keyboards/kbdfans/kbd75/keymaps/tucznak/rules.mk +++ b/keyboards/kbdfans/kbd75/keymaps/tucznak/rules.mk | |||
@@ -1,7 +1,7 @@ | |||
1 | # Build Options | 1 | # Build Options |
2 | # change yes to no to disable | 2 | # change yes to no to disable |
3 | # | 3 | # |
4 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 4 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
5 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 5 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
6 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 6 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
7 | CONSOLE_ENABLE = no # Console for debug(+400) | 7 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/kbdfans/kbd75/rev1/rules.mk b/keyboards/kbdfans/kbd75/rev1/rules.mk index ae6507a85..054cb687b 100644 --- a/keyboards/kbdfans/kbd75/rev1/rules.mk +++ b/keyboards/kbdfans/kbd75/rev1/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kbdfans/kbd75/rev2/rules.mk b/keyboards/kbdfans/kbd75/rev2/rules.mk index ae6507a85..054cb687b 100644 --- a/keyboards/kbdfans/kbd75/rev2/rules.mk +++ b/keyboards/kbdfans/kbd75/rev2/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kc60/keymaps/stanleylai/rules.mk b/keyboards/kc60/keymaps/stanleylai/rules.mk index a826c2bf2..b4471d606 100644 --- a/keyboards/kc60/keymaps/stanleylai/rules.mk +++ b/keyboards/kc60/keymaps/stanleylai/rules.mk | |||
@@ -3,7 +3,7 @@ | |||
3 | # Build Options | 3 | # Build Options |
4 | # change yes to no to disable | 4 | # change yes to no to disable |
5 | # | 5 | # |
6 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 6 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
7 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 7 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
8 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 8 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
9 | CONSOLE_ENABLE = no # Console for debug(+400) | 9 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/kc60/keymaps/wigguno/rules.mk b/keyboards/kc60/keymaps/wigguno/rules.mk index db084a76a..d95742d42 100644 --- a/keyboards/kc60/keymaps/wigguno/rules.mk +++ b/keyboards/kc60/keymaps/wigguno/rules.mk | |||
@@ -3,7 +3,7 @@ | |||
3 | # Build Options | 3 | # Build Options |
4 | # change yes to no to disable | 4 | # change yes to no to disable |
5 | # | 5 | # |
6 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 6 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
7 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 7 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
8 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 8 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
9 | CONSOLE_ENABLE = no # Console for debug(+400) | 9 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/keebio/dilly/rules.mk b/keyboards/keebio/dilly/rules.mk index dbb338e3a..dd730c950 100644 --- a/keyboards/keebio/dilly/rules.mk +++ b/keyboards/keebio/dilly/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/keebio/iris/keymaps/vyolle/rules.mk b/keyboards/keebio/iris/keymaps/vyolle/rules.mk index e7cbfb83d..f93940de3 100644 --- a/keyboards/keebio/iris/keymaps/vyolle/rules.mk +++ b/keyboards/keebio/iris/keymaps/vyolle/rules.mk | |||
@@ -4,4 +4,4 @@ STENO_ENABLE = no # Additional protocols for Stenography(+1700), require | |||
4 | AUDIO_ENABLE = no # Audio output on port C6 | 4 | AUDIO_ENABLE = no # Audio output on port C6 |
5 | MIDI_ENABLE = no # MIDI controls | 5 | MIDI_ENABLE = no # MIDI controls |
6 | NKRO_ENABLE = yes | 6 | NKRO_ENABLE = yes |
7 | BOOTMAGIC_ENABLE = yes | 7 | BOOTMAGIC_ENABLE = full |
diff --git a/keyboards/keebio/levinson/keymaps/steno/rules.mk b/keyboards/keebio/levinson/keymaps/steno/rules.mk index 47cd0563d..7693b24b5 100644 --- a/keyboards/keebio/levinson/keymaps/steno/rules.mk +++ b/keyboards/keebio/levinson/keymaps/steno/rules.mk | |||
@@ -4,4 +4,4 @@ STENO_ENABLE = yes # Additional protocols for Stenography, requires VIR | |||
4 | AUDIO_ENABLE = no # Audio output on port C6 | 4 | AUDIO_ENABLE = no # Audio output on port C6 |
5 | MIDI_ENABLE = no # MIDI controls | 5 | MIDI_ENABLE = no # MIDI controls |
6 | NKRO_ENABLE = yes | 6 | NKRO_ENABLE = yes |
7 | BOOTMAGIC_ENABLE = yes | 7 | BOOTMAGIC_ENABLE = full |
diff --git a/keyboards/keebio/nyquist/keymaps/danielhklein/rules.mk b/keyboards/keebio/nyquist/keymaps/danielhklein/rules.mk index 12ad2fec5..93cf3c8ea 100644 --- a/keyboards/keebio/nyquist/keymaps/danielhklein/rules.mk +++ b/keyboards/keebio/nyquist/keymaps/danielhklein/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
22 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 22 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
24 | CONSOLE_ENABLE = no # Console for debug(+400) | 24 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/kinesis/alvicstep/config.h b/keyboards/kinesis/alvicstep/config.h index 88b7e2644..73aa4dd4d 100644 --- a/keyboards/kinesis/alvicstep/config.h +++ b/keyboards/kinesis/alvicstep/config.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define ALVICSTEP_CONFIG_H | 2 | #define ALVICSTEP_CONFIG_H |
3 | 3 | ||
4 | #include "../config.h" | 4 | #include "../config.h" |
5 | #include "config_common.h" | ||
5 | 6 | ||
6 | /* USB Device descriptor parameter */ | 7 | /* USB Device descriptor parameter */ |
7 | #define PRODUCT_ID 0x6060 | 8 | #define PRODUCT_ID 0x6060 |
diff --git a/keyboards/kinesis/config.h b/keyboards/kinesis/config.h index ddb16d33b..c5a89d453 100644 --- a/keyboards/kinesis/config.h +++ b/keyboards/kinesis/config.h | |||
@@ -18,8 +18,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
18 | #ifndef CONFIG_H | 18 | #ifndef CONFIG_H |
19 | #define CONFIG_H | 19 | #define CONFIG_H |
20 | 20 | ||
21 | #include "config_common.h" | ||
22 | |||
23 | /* USB Device descriptor parameter */ | 21 | /* USB Device descriptor parameter */ |
24 | #define VENDOR_ID 0xFEED | 22 | #define VENDOR_ID 0xFEED |
25 | #define MANUFACTURER You | 23 | #define MANUFACTURER You |
diff --git a/keyboards/kinesis/kinesis.h b/keyboards/kinesis/kinesis.h index 444322d1f..0833992b8 100644 --- a/keyboards/kinesis/kinesis.h +++ b/keyboards/kinesis/kinesis.h | |||
@@ -13,6 +13,9 @@ | |||
13 | #ifdef KEYBOARD_kinesis_nguyenvietyen | 13 | #ifdef KEYBOARD_kinesis_nguyenvietyen |
14 | #include "nguyenvietyen.h" | 14 | #include "nguyenvietyen.h" |
15 | #endif | 15 | #endif |
16 | #ifdef KEYBOARD_kinesis_kint36 | ||
17 | #include "kint36.h" | ||
18 | #endif | ||
16 | 19 | ||
17 | #include "quantum.h" | 20 | #include "quantum.h" |
18 | 21 | ||
diff --git a/keyboards/kinesis/kint2pp/config.h b/keyboards/kinesis/kint2pp/config.h index 902c9b24a..ff5761b6b 100644 --- a/keyboards/kinesis/kint2pp/config.h +++ b/keyboards/kinesis/kint2pp/config.h | |||
@@ -36,3 +36,7 @@ | |||
36 | #define DEBOUNCE 5 | 36 | #define DEBOUNCE 5 |
37 | 37 | ||
38 | #define IGNORE_MOD_TAP_INTERRUPT | 38 | #define IGNORE_MOD_TAP_INTERRUPT |
39 | |||
40 | // Reduce input latency by lowering the USB polling interval | ||
41 | // from its 10ms default to the 1ms minimum that USB 1.x (Full Speed) allows: | ||
42 | #define USB_POLLING_INTERVAL_MS 1 | ||
diff --git a/keyboards/kinesis/kint2pp/rules.mk b/keyboards/kinesis/kint2pp/rules.mk index e69de29bb..7c48a98bf 100644 --- a/keyboards/kinesis/kint2pp/rules.mk +++ b/keyboards/kinesis/kint2pp/rules.mk | |||
@@ -0,0 +1,3 @@ | |||
1 | # Debounce eagerly (report change immediately), keep per-key timers. We can use | ||
2 | # this because the kinT does not have to deal with noise. | ||
3 | DEBOUNCE_TYPE = sym_eager_pk | ||
diff --git a/keyboards/kinesis/kint36/chconf.h b/keyboards/kinesis/kint36/chconf.h new file mode 100644 index 000000000..81dfcd5a2 --- /dev/null +++ b/keyboards/kinesis/kint36/chconf.h | |||
@@ -0,0 +1,28 @@ | |||
1 | /* Copyright 2020 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | /* | ||
18 | * This file was auto-generated by: | ||
19 | * `qmk chibios-confmigrate -i keyboards/kinesis/kint36/chconf.h -r platforms/chibios/common/configs/chconf.h` | ||
20 | */ | ||
21 | |||
22 | #pragma once | ||
23 | |||
24 | #define CH_CFG_ST_TIMEDELTA 0 | ||
25 | |||
26 | #define CH_CFG_TIME_QUANTUM 20 | ||
27 | |||
28 | #include_next <chconf.h> | ||
diff --git a/keyboards/kinesis/kint36/config.h b/keyboards/kinesis/kint36/config.h new file mode 100644 index 000000000..be5752603 --- /dev/null +++ b/keyboards/kinesis/kint36/config.h | |||
@@ -0,0 +1,66 @@ | |||
1 | /* Copyright 2020 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #pragma once | ||
18 | |||
19 | /* USB Device descriptor parameter */ | ||
20 | #undef VENDOR_ID | ||
21 | #define VENDOR_ID 0x1209 | ||
22 | #undef PRODUCT_ID | ||
23 | #define PRODUCT_ID 0x345C | ||
24 | #undef DEVICE_VER | ||
25 | #define DEVICE_VER 0x0001 | ||
26 | #undef MANUFACTURER | ||
27 | #define MANUFACTURER "https://github.com/stapelberg" | ||
28 | #undef PRODUCT | ||
29 | #define PRODUCT "kinT (kint36)" | ||
30 | |||
31 | /* key matrix size */ | ||
32 | #define MATRIX_ROWS 15 | ||
33 | #define MATRIX_COLS 7 | ||
34 | |||
35 | /* | ||
36 | * Keyboard Matrix Assignments | ||
37 | * | ||
38 | * Change this to how you wired your keyboard | ||
39 | * COLS: AVR pins used for columns, left to right | ||
40 | * ROWS: AVR pins used for rows, top to bottom | ||
41 | * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) | ||
42 | * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) | ||
43 | * | ||
44 | */ | ||
45 | #define MATRIX_ROW_PINS { D3, C3, C4, C6, D2, B0, D7, A12, A13, B17, B16, D0, B1, C2, D6 } | ||
46 | #define MATRIX_COL_PINS { B3, D1, C0, D5, C1, B2, D4 } | ||
47 | |||
48 | #define UNUSED_PINS | ||
49 | |||
50 | /* COL2ROW or ROW2COL */ | ||
51 | #define DIODE_DIRECTION COL2ROW | ||
52 | |||
53 | /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ | ||
54 | #define DEBOUNCE 5 | ||
55 | |||
56 | #define IGNORE_MOD_TAP_INTERRUPT | ||
57 | |||
58 | // Reduce input latency by lowering the USB polling interval | ||
59 | // from its 10ms default to the 1ms minimum that USB 1.x (Full Speed) allows: | ||
60 | #define USB_POLLING_INTERVAL_MS 1 | ||
61 | |||
62 | #define LED_PIN_ON_STATE 0 | ||
63 | #define LED_NUM_LOCK_PIN A14 | ||
64 | #define LED_CAPS_LOCK_PIN C7 | ||
65 | #define LED_SCROLL_LOCK_PIN A5 | ||
66 | #define LED_COMPOSE_PIN E26 | ||
diff --git a/keyboards/durgod/k320/keymaps/via/config.h b/keyboards/kinesis/kint36/keymaps/kzar/config.h index 2ae6fca9d..6b03aa6a7 100644 --- a/keyboards/durgod/k320/keymaps/via/config.h +++ b/keyboards/kinesis/kint36/keymaps/kzar/config.h | |||
@@ -1,5 +1,4 @@ | |||
1 | /* | 1 | /* Copyright 2021 Dave Vandyke <kzar@kzar.co.uk> |
2 | * Copyright 2021 Maxime Coirault | ||
3 | * | 2 | * |
4 | * This program is free software: you can redistribute it and/or modify | 3 | * This program is free software: you can redistribute it and/or modify |
5 | * it under the terms of the GNU General Public License as published by | 4 | * it under the terms of the GNU General Public License as published by |
@@ -17,4 +16,4 @@ | |||
17 | 16 | ||
18 | #pragma once | 17 | #pragma once |
19 | 18 | ||
20 | #define DYNAMIC_KEYMAP_LAYER_COUNT 3 | 19 | #undef LED_COMPOSE_PIN |
diff --git a/keyboards/kinesis/kint36/keymaps/kzar/keymap.c b/keyboards/kinesis/kint36/keymaps/kzar/keymap.c new file mode 100644 index 000000000..20b135268 --- /dev/null +++ b/keyboards/kinesis/kint36/keymaps/kzar/keymap.c | |||
@@ -0,0 +1,405 @@ | |||
1 | /* Copyright 2021 Dave Vandyke <kzar@kzar.co.uk>, | ||
2 | * Based upon Xyverz's Kinesis keymap Copyright 2017-2020. | ||
3 | * | ||
4 | * This program is free software: you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License as published by | ||
6 | * the Free Software Foundation, either version 2 of the License, or | ||
7 | * (at your option) any later version. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, | ||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | * GNU General Public License for more details. | ||
13 | * | ||
14 | * You should have received a copy of the GNU General Public License | ||
15 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
16 | */ | ||
17 | |||
18 | #include QMK_KEYBOARD_H | ||
19 | #include "version.h" | ||
20 | |||
21 | enum layer_names {_QWERTY, _DVORAK, _MAC, _PC, _KEYPAD, _PROGRAM}; | ||
22 | enum my_keycodes {QWERTY = SAFE_RANGE, DVORAK, WIN, MAC, PC, STATUS, PROGRAM}; | ||
23 | |||
24 | #define LED_KEYPAD E26 | ||
25 | |||
26 | // clang-format off | ||
27 | |||
28 | /* | ||
29 | QWERTY layer: | ||
30 | ,---------------------------------------------------------------------------. | ||
31 | | ESC | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | | ||
32 | `---------------------------------------------------------------------------' | ||
33 | ,---------------------------------------------------------------------------. | ||
34 | | F9 | F10 | F11 | F12 | PScr | SLck | Pause | Keypad | Prgrm | | ||
35 | `---------------------------------------------------------------------------' | ||
36 | ,-------------------------------------------.,-------------------------------------------. | ||
37 | | = | 1 | 2 | 3 | 4 | 5 || 6 | 7 | 8 | 9 | 0 | - | | ||
38 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
39 | | Tab | Q | W | E | R | T || Y | U | I | O | P | \ | | ||
40 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
41 | | CapsLk | A | S | D | F | G || H | J | K | L | ; | ' | | ||
42 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
43 | | LShift | Z | X | C | V | B || N | M | , | . | / | RShift | | ||
44 | `--------+------+------+------+------+------'`------+------+------+------+------+--------' | ||
45 | | ` | \ | Left | Rght | | Up | Dn | [ | ] | | ||
46 | `---------------------------' `---------------------------' | ||
47 | ,--------------.,--------------. | ||
48 | | LCtl | LAlt || LGUI | RCtl | | ||
49 | ,------|-------|------||------+-------+-------. | ||
50 | | | | Home || PgUp | Enter | | | ||
51 | | BkSp | Del |------||------| / | Space | | ||
52 | | | | End || PgDn | KeyPd | | | ||
53 | `---------------------'`----------------------' | ||
54 | |||
55 | Dvorak layer: | ||
56 | ,---------------------------------------------------------------------------. | ||
57 | | | | | | | | | | | | ||
58 | `---------------------------------------------------------------------------' | ||
59 | ,---------------------------------------------------------------------------. | ||
60 | | | | | | | | | | | | ||
61 | `---------------------------------------------------------------------------' | ||
62 | ,-------------------------------------------.,-------------------------------------------. | ||
63 | | | | | | | || | | | | | | | ||
64 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
65 | | | ' | , | . | P | Y || F | G | C | R | L | / | | ||
66 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
67 | | | A | O | E | U | I || D | H | T | N | S | \ | | ||
68 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
69 | | | ; | Q | J | K | X || B | M | W | V | Z | | | ||
70 | `--------+------+------+------+------+------'`------+------+------+------+------+--------' | ||
71 | | | | | | | | | | | | ||
72 | `---------------------------' `---------------------------' | ||
73 | ,--------------.,--------------. | ||
74 | | | || | | | ||
75 | ,------|-------|------||------+-------+-------. | ||
76 | | | | || | | | | ||
77 | | | |------||------| | | | ||
78 | | | | || | | | | ||
79 | `---------------------'`----------------------' | ||
80 | |||
81 | Mac layer: | ||
82 | ,-------------------------------------------------------------------------------. | ||
83 | | | | | | | | | | | | ||
84 | `-------------------------------------------------------------------------------' | ||
85 | ,-------------------------------------------------------------------------------. | ||
86 | | | | | | | Power | | | | | ||
87 | `-------------------------------------------------------------------------------' | ||
88 | ,-------------------------------------------.,-------------------------------------------. | ||
89 | | | | | | | || | | | | | | | ||
90 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
91 | | | | | | | || | | | | | | | ||
92 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
93 | | | | | | | || | | | | | | | ||
94 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
95 | | | | | | | || | | | | | | | ||
96 | `--------+------+------+------+------+------'`------+------+------+------+------+--------' | ||
97 | | | | | | | | | | | | ||
98 | `---------------------------' `---------------------------' | ||
99 | ,-------------.,-------------. | ||
100 | | LGUI | LAlt || RCtl | RGUI | | ||
101 | ,------|------|------||------+------+------. | ||
102 | | | | || | | | | ||
103 | | | |------||------| | | | ||
104 | | | | || | | | | ||
105 | `--------------------'`--------------------' | ||
106 | |||
107 | PC layer: | ||
108 | ,-------------------------------------------------------------------------------. | ||
109 | | | | | | | | | | | | ||
110 | `-------------------------------------------------------------------------------' | ||
111 | ,-------------------------------------------------------------------------------. | ||
112 | | | | | | | | | | | | ||
113 | `-------------------------------------------------------------------------------' | ||
114 | ,-------------------------------------------.,-------------------------------------------. | ||
115 | | | | | | | || | | | | | | | ||
116 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
117 | | | | | | | || | | | | | | | ||
118 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
119 | | | | | | | || | | | | | | | ||
120 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
121 | | | | | | | || | | | | | | | ||
122 | `--------+------+------+------+------+------'`------+------+------+------+------+--------' | ||
123 | | | | | | | | | | | | ||
124 | `---------------------------' `---------------------------' | ||
125 | ,-------------.,-------------. | ||
126 | | | || RAlt | | | ||
127 | ,------|------|------||------+------+------. | ||
128 | | | | || | | | | ||
129 | | | |------||------| | | | ||
130 | | | | || | | | | ||
131 | `--------------------'`--------------------' | ||
132 | |||
133 | Keypad layer: | ||
134 | ,---------------------------------------------------------------------------. | ||
135 | | | | | | | | | | | | ||
136 | `---------------------------------------------------------------------------' | ||
137 | ,---------------------------------------------------------------------------. | ||
138 | | | | | | Mute | Vol Down | Vol Up | Keypad | | | ||
139 | `---------------------------------------------------------------------------' | ||
140 | ,-------------------------------------------.,-------------------------------------------. | ||
141 | | | | | | | || | NmLk | KP = | KP / | KP * | | | ||
142 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
143 | | | | | | | || | KP 7 | KP 8 | KP 9 | KP - | | | ||
144 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
145 | | | | | | | || | KP 4 | KP 5 | KP 6 | KP + | | | ||
146 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
147 | | | | | | | || | KP 1 | KP 2 | KP 3 |KP Ent| | | ||
148 | `--------+------+------+------+------+------'`------+------+------+------+------+--------' | ||
149 | | | INS | | | | | | KP . |KP Ent| | ||
150 | `---------------------------' `---------------------------' | ||
151 | ,-------------.,-------------. | ||
152 | | | || | | | ||
153 | ,------|------|------||------+------+------. | ||
154 | | | | || | | | | ||
155 | | | |------||------| | KP 0 | | ||
156 | | | | || | | | | ||
157 | `--------------------'`--------------------' | ||
158 | |||
159 | Program layer: | ||
160 | ,-------------------------------------------------------------------------------. | ||
161 | | STATUS | | | QWERTY | DVORAK | | | | | | ||
162 | `-------------------------------------------------------------------------------' | ||
163 | ,-------------------------------------------------------------------------------. | ||
164 | | RESET | | | | | | | | | | ||
165 | `-------------------------------------------------------------------------------' | ||
166 | ,-------------------------------------------.,-------------------------------------------. | ||
167 | | | | | | | || | | | | | | | ||
168 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
169 | | | | | | | || | | | | | | | ||
170 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
171 | | | | | | | || | | | | | | | ||
172 | |--------+------+------+------+------+------||------+------+------+------+------+--------| | ||
173 | | | | | | | || | | | | | | | ||
174 | `--------+------+------+------+------+------'`------+------+------+------+------+--------' | ||
175 | | | | | | | | | | | | ||
176 | `---------------------------' `---------------------------' | ||
177 | ,-------------.,-------------. | ||
178 | | | || | | | ||
179 | ,------|------|------||------+------+------. | ||
180 | | | | || | | | | ||
181 | | | |------||------| | | | ||
182 | | | | || | | | | ||
183 | `--------------------'`--------------------' | ||
184 | |||
185 | */ | ||
186 | |||
187 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
188 | |||
189 | [_QWERTY] = LAYOUT ( | ||
190 | // Left Hand | ||
191 | KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, | ||
192 | KC_EQL, KC_1, KC_2, KC_3, KC_4, KC_5, | ||
193 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, | ||
194 | KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, | ||
195 | KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, | ||
196 | KC_GRV, KC_NUBS, KC_LEFT, KC_RGHT, | ||
197 | // Left Thumb | ||
198 | KC_LCTL, KC_LALT, | ||
199 | KC_HOME, | ||
200 | KC_BSPC, KC_DEL, KC_END, | ||
201 | |||
202 | // Right Hand | ||
203 | KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, TG(_KEYPAD), MO(_PROGRAM), | ||
204 | KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, | ||
205 | KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS, | ||
206 | KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, | ||
207 | KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, | ||
208 | KC_UP, KC_DOWN, KC_LBRC, KC_RBRC, | ||
209 | // Right Thumb | ||
210 | KC_LGUI, KC_RCTL, | ||
211 | KC_PGUP, | ||
212 | KC_PGDN, KC_ENT, KC_SPC | ||
213 | ), | ||
214 | |||
215 | [_DVORAK] = LAYOUT ( | ||
216 | // Left Hand | ||
217 | _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
218 | _______, _______, _______, _______, _______, _______, | ||
219 | _______, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, | ||
220 | _______, KC_A, KC_O, KC_E, KC_U, KC_I, | ||
221 | _______, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, | ||
222 | _______, _______, _______, _______, | ||
223 | // Left Thumb | ||
224 | _______, _______, | ||
225 | _______, | ||
226 | _______, _______, _______, | ||
227 | |||
228 | // Right Hand | ||
229 | _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
230 | _______, _______, _______, _______, _______, _______, | ||
231 | KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLSH, | ||
232 | KC_D, KC_H, KC_T, KC_N, KC_S, KC_BSLS, | ||
233 | KC_B, KC_M, KC_W, KC_V, KC_Z, _______, | ||
234 | _______, _______, _______, _______, | ||
235 | // Right Thumb | ||
236 | _______, _______, | ||
237 | _______, | ||
238 | _______, _______, _______ | ||
239 | ), | ||
240 | |||
241 | [_MAC] = LAYOUT ( | ||
242 | // Left Hand | ||
243 | _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
244 | _______, _______, _______, _______, _______, _______, | ||
245 | _______, _______, _______, _______, _______, _______, | ||
246 | _______, _______, _______, _______, _______, _______, | ||
247 | _______, _______, _______, _______, _______, _______, | ||
248 | _______, _______, _______, _______, | ||
249 | // Left Thumb | ||
250 | KC_LGUI, KC_LALT, | ||
251 | _______, | ||
252 | _______, _______, _______, | ||
253 | |||
254 | // Right Hand | ||
255 | _______, _______, _______, _______, _______, KC_POWER, _______, _______, _______, | ||
256 | _______, _______, _______, _______, _______, _______, | ||
257 | _______, _______, _______, _______, _______, _______, | ||
258 | _______, _______, _______, _______, _______, _______, | ||
259 | _______, _______, _______, _______, _______, _______, | ||
260 | _______, _______, _______, _______, | ||
261 | // Right Thumb | ||
262 | KC_RCTL, KC_RGUI, | ||
263 | _______, | ||
264 | _______, _______, _______ | ||
265 | ), | ||
266 | |||
267 | [_PC] = LAYOUT ( | ||
268 | // Left Hand | ||
269 | _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
270 | _______, _______, _______, _______, _______, _______, | ||
271 | _______, _______, _______, _______, _______, _______, | ||
272 | _______, _______, _______, _______, _______, _______, | ||
273 | _______, _______, _______, _______, _______, _______, | ||
274 | _______, _______, _______, _______, | ||
275 | // Left Thumb | ||
276 | _______, _______, | ||
277 | _______, | ||
278 | _______, _______, _______, | ||
279 | |||
280 | // Right Hand | ||
281 | _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
282 | _______, _______, _______, _______, _______, _______, | ||
283 | _______, _______, _______, _______, _______, _______, | ||
284 | _______, _______, _______, _______, _______, _______, | ||
285 | _______, _______, _______, _______, _______, _______, | ||
286 | _______, _______, _______, _______, | ||
287 | // Right Thumb | ||
288 | KC_RALT, _______, | ||
289 | _______, | ||
290 | _______, _______, _______ | ||
291 | ), | ||
292 | |||
293 | [_KEYPAD] = LAYOUT ( | ||
294 | // Left Hand | ||
295 | _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
296 | _______, _______, _______, _______, _______, _______, | ||
297 | _______, _______, _______, _______, _______, _______, | ||
298 | _______, _______, _______, _______, _______, _______, | ||
299 | _______, _______, _______, _______, _______, _______, | ||
300 | _______, KC_INS, _______, _______, | ||
301 | // Left Thumb | ||
302 | _______, _______, | ||
303 | _______, | ||
304 | _______, _______, _______, | ||
305 | |||
306 | // Right Hand | ||
307 | _______, _______, _______, _______, KC__MUTE, KC__VOLDOWN, KC__VOLUP, _______, _______, | ||
308 | _______, KC_NLCK, KC_PEQL, KC_PSLS, KC_PAST, _______, | ||
309 | _______, KC_P7, KC_P8, KC_P9, KC_PMNS, _______, | ||
310 | _______, KC_P4, KC_P5, KC_P6, KC_PPLS, _______, | ||
311 | _______, KC_P1, KC_P2, KC_P3, KC_PENT, _______, | ||
312 | _______, _______, KC_PDOT, KC_PENT, | ||
313 | // Right Thumb | ||
314 | _______, _______, | ||
315 | _______, | ||
316 | _______, _______, KC_P0 | ||
317 | ), | ||
318 | |||
319 | [_PROGRAM] = LAYOUT ( | ||
320 | // Left Hand | ||
321 | STATUS, _______, _______, QWERTY, DVORAK, MAC, PC, WIN, _______, | ||
322 | _______, _______, _______, _______ , _______, _______, | ||
323 | _______, _______, _______, _______ , _______, _______, | ||
324 | _______, _______, _______, _______ , _______, _______, | ||
325 | _______, _______, _______, _______ , _______, _______, | ||
326 | _______, _______, _______ , _______, | ||
327 | // Left Thumb | ||
328 | _______, _______, | ||
329 | _______, | ||
330 | _______, _______, _______, | ||
331 | |||
332 | // Right Hand | ||
333 | RESET, _______, _______, _______, _______, _______, _______, _______, _______, | ||
334 | _______, _______, _______, _______, _______, _______, | ||
335 | _______, _______, _______, _______, _______, _______, | ||
336 | _______, _______, _______, _______, _______, _______, | ||
337 | _______, _______, _______, _______, _______, _______, | ||
338 | _______, _______, _______, _______, | ||
339 | // Right Thumb | ||
340 | _______, _______, | ||
341 | _______, | ||
342 | _______, _______, _______ | ||
343 | ) | ||
344 | |||
345 | }; | ||
346 | |||
347 | layer_state_t layer_state_set_user(layer_state_t state) { | ||
348 | writePin(LED_KEYPAD, !layer_state_cmp(state, _KEYPAD)); | ||
349 | return state; | ||
350 | } | ||
351 | |||
352 | bool process_record_user(uint16_t keycode, keyrecord_t *record) { | ||
353 | if (record->event.pressed) { | ||
354 | switch (keycode) { | ||
355 | case QWERTY: | ||
356 | set_single_persistent_default_layer(_QWERTY); | ||
357 | return false; | ||
358 | case DVORAK: | ||
359 | set_single_persistent_default_layer(_DVORAK); | ||
360 | return false; | ||
361 | case MAC: | ||
362 | layer_on(_MAC); | ||
363 | layer_off(_PC); | ||
364 | return false; | ||
365 | case PC: | ||
366 | layer_off(_MAC); | ||
367 | layer_on(_PC); | ||
368 | return false; | ||
369 | case WIN: | ||
370 | layer_off(_MAC); | ||
371 | layer_off(_PC); | ||
372 | return false; | ||
373 | case STATUS: | ||
374 | SEND_STRING("Firmware> QMK " QMK_VERSION ", " QMK_BUILDDATE "\n"); | ||
375 | SEND_STRING("Keyboard> " QMK_KEYBOARD "\n"); | ||
376 | SEND_STRING("Keymap> " QMK_KEYMAP "\n"); | ||
377 | |||
378 | if (layer_state_is(_QWERTY)) | ||
379 | SEND_STRING("Layout> QWERTY\n"); | ||
380 | else | ||
381 | SEND_STRING("Layout> DVORAK\n"); | ||
382 | |||
383 | if (layer_state_is(_MAC)) | ||
384 | SEND_STRING("Thumb keys mode> MAC\n"); | ||
385 | else if (layer_state_is(_PC)) | ||
386 | SEND_STRING("Thumb keys mode> PC\n"); | ||
387 | else | ||
388 | SEND_STRING("Thumb keys mode> WIN\n"); | ||
389 | |||
390 | if (keymap_config.nkro) | ||
391 | SEND_STRING("NKRO> Enabled\n"); | ||
392 | else | ||
393 | SEND_STRING("NKRO> Disabled\n"); | ||
394 | |||
395 | if (debug_enable) | ||
396 | SEND_STRING("Debug> Enabled\n"); | ||
397 | else | ||
398 | SEND_STRING("Debug> Disabled\n"); | ||
399 | |||
400 | return false; | ||
401 | } | ||
402 | } | ||
403 | |||
404 | return true; | ||
405 | } | ||
diff --git a/keyboards/kinesis/kint36/keymaps/kzar/readme.md b/keyboards/kinesis/kint36/keymaps/kzar/readme.md new file mode 100644 index 000000000..b45808892 --- /dev/null +++ b/keyboards/kinesis/kint36/keymaps/kzar/readme.md | |||
@@ -0,0 +1,9 @@ | |||
1 | # Dave's Kinesis Advantage keymap | ||
2 | |||
3 | Kinesis Advantage keymap aiming to emulate the stock controller. QWERTY, DVORAK, | ||
4 | WIN, MAC, PC, program and keypad layers are all supported, along with the | ||
5 | keypad LED and RESET + STATUS keys. | ||
6 | |||
7 | Tested with a Kinesis Advantage2, kinT (stapelberg) keyboard controller built | ||
8 | with a Teensy 3.6 microcontroller and a UK system layout. Originally based upon | ||
9 | the xyvers keymap. | ||
diff --git a/keyboards/kinesis/kint36/keymaps/kzar/rules.mk b/keyboards/kinesis/kint36/keymaps/kzar/rules.mk new file mode 100644 index 000000000..753718884 --- /dev/null +++ b/keyboards/kinesis/kint36/keymaps/kzar/rules.mk | |||
@@ -0,0 +1,5 @@ | |||
1 | BOOTMAGIC_ENABLE = no | ||
2 | COMMAND_ENABLE = yes | ||
3 | MOUSEKEY_ENABLE = no | ||
4 | NKRO_ENABLE = yes | ||
5 | RGBLIGHT_ENABLE = no | ||
diff --git a/keyboards/kinesis/kint36/kint36.c b/keyboards/kinesis/kint36/kint36.c new file mode 100644 index 000000000..108c14c7b --- /dev/null +++ b/keyboards/kinesis/kint36/kint36.c | |||
@@ -0,0 +1,26 @@ | |||
1 | /* Copyright 2020 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #include "kint36.h" | ||
18 | |||
19 | void matrix_init_kb(void) { | ||
20 | matrix_init_user(); | ||
21 | |||
22 | // Turn on the Teensy 3.6 Power LED: | ||
23 | #define LED_POWER C5 | ||
24 | setPinOutput(LED_POWER); | ||
25 | writePinHigh(LED_POWER); | ||
26 | } | ||
diff --git a/keyboards/kinesis/kint36/kint36.h b/keyboards/kinesis/kint36/kint36.h new file mode 100644 index 000000000..d427a1c2d --- /dev/null +++ b/keyboards/kinesis/kint36/kint36.h | |||
@@ -0,0 +1,92 @@ | |||
1 | /* Copyright 2020 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #pragma once | ||
18 | |||
19 | #include "quantum.h" | ||
20 | |||
21 | #define ___ KC_NO | ||
22 | |||
23 | // This a shortcut to help you visually see your layout. | ||
24 | // The first section contains all of the arguments as on the physical keyboard | ||
25 | // The second converts the arguments into the 2-D scanned array | ||
26 | |||
27 | #define LAYOUT( \ | ||
28 | kC0, kD0, kE0, kC1, kD1, kE1, kC2, kD2, kE2, \ | ||
29 | k00, k10, k20, k30, k40, k50, \ | ||
30 | k01, k11, k21, k31, k41, k51, \ | ||
31 | k02, k12, k22, k32, k42, k52, \ | ||
32 | k03, k13, k23, k33, k43, k53, \ | ||
33 | k14, k24, k34, k54, \ | ||
34 | k56, k55, \ | ||
35 | k35, \ | ||
36 | k36, k46, k25, \ | ||
37 | \ | ||
38 | kC3, kD3, kE3, kC4, kD4, kE4, kC5, kE5, kD5, \ | ||
39 | k60, k70, k80, k90, kA0, kB0, \ | ||
40 | k61, k71, k81, k91, kA1, kB1, \ | ||
41 | k62, k72, k82, k92, kA2, kB2, \ | ||
42 | k63, k73, k83, k93, kA3, kB3, \ | ||
43 | k64, k84, k94, kA4, \ | ||
44 | k96, k85, \ | ||
45 | k86, \ | ||
46 | k66, k75, k65 \ | ||
47 | ) { \ | ||
48 | { k00, k01, k02, k03, ___, ___, ___ }, \ | ||
49 | { k10, k11, k12, k13, k14, ___, ___ }, \ | ||
50 | { k20, k21, k22, k23, k24, k25, ___ }, \ | ||
51 | { k30, k31, k32, k33, k34, k35, k36 }, \ | ||
52 | { k40, k41, k42, k43, ___, ___, k46 }, \ | ||
53 | { k50, k51, k52, k53, k54, k55, k56 }, \ | ||
54 | { k60, k61, k62, k63, k64, k65, k66 }, \ | ||
55 | { k70, k71, k72, k73, ___, k75, ___ }, \ | ||
56 | { k80, k81, k82, k83, k84, k85, k86 }, \ | ||
57 | { k90, k91, k92, k93, k94, ___, k96 }, \ | ||
58 | { kA0, kA1, kA2, kA3, kA4, ___, ___ }, \ | ||
59 | { kB0, kB1, kB2, kB3, ___, ___, ___ }, \ | ||
60 | { kC0, kC1, kC2, kC3, kC4, kC5, ___ }, \ | ||
61 | { kD0, kD1, kD2, kD3, kD4, kD5, ___ }, \ | ||
62 | { kE0, kE1, kE2, kE3, kE4, kE5, ___ }, \ | ||
63 | } | ||
64 | |||
65 | /* ---------------- LEFT HAND ----------------- ---------------- RIGHT HAND ---------------- */ | ||
66 | #define LAYOUT_pretty( \ | ||
67 | kC0, kD0, kE0, kC1, kD1, kE1, kC2, kD2, kE2, kC3, kD3, kE3, kC4, kD4, kE4, kC5, kE5, kD5, \ | ||
68 | k00, k10, k20, k30, k40, k50, k60, k70, k80, k90, kA0, kB0, \ | ||
69 | k01, k11, k21, k31, k41, k51, k61, k71, k81, k91, kA1, kB1, \ | ||
70 | k02, k12, k22, k32, k42, k52, k62, k72, k82, k92, kA2, kB2, \ | ||
71 | k03, k13, k23, k33, k43, k53, k63, k73, k83, k93, kA3, kB3, \ | ||
72 | k14, k24, k34, k54, k64, k84, k94, kA4, \ | ||
73 | k56, k55, k96, k85, \ | ||
74 | k35, k86, \ | ||
75 | k36, k46, k25, k66, k75, k65 \ | ||
76 | ) { \ | ||
77 | { k00, k01, k02, k03, ___, ___, ___ }, \ | ||
78 | { k10, k11, k12, k13, k14, ___, ___ }, \ | ||
79 | { k20, k21, k22, k23, k24, k25, ___ }, \ | ||
80 | { k30, k31, k32, k33, k34, k35, k36 }, \ | ||
81 | { k40, k41, k42, k43, ___, ___, k46 }, \ | ||
82 | { k50, k51, k52, k53, k54, k55, k56 }, \ | ||
83 | { k60, k61, k62, k63, k64, k65, k66 }, \ | ||
84 | { k70, k71, k72, k73, ___, k75, ___ }, \ | ||
85 | { k80, k81, k82, k83, k84, k85, k86 }, \ | ||
86 | { k90, k91, k92, k93, k94, ___, k96 }, \ | ||
87 | { kA0, kA1, kA2, kA3, kA4, ___, ___ }, \ | ||
88 | { kB0, kB1, kB2, kB3, ___, ___, ___ }, \ | ||
89 | { kC0, kC1, kC2, kC3, kC4, kC5, ___ }, \ | ||
90 | { kD0, kD1, kD2, kD3, kD4, kD5, ___ }, \ | ||
91 | { kE0, kE1, kE2, kE3, kE4, kE5, ___ } \ | ||
92 | } | ||
diff --git a/keyboards/kinesis/kint36/mcuconf.h b/keyboards/kinesis/kint36/mcuconf.h new file mode 100644 index 000000000..b0ea44567 --- /dev/null +++ b/keyboards/kinesis/kint36/mcuconf.h | |||
@@ -0,0 +1,65 @@ | |||
1 | // based on lib/chibios-contrib/demos/KINETIS/RT-TEENSY3_6/mcuconf.h: | ||
2 | /* | ||
3 | ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio | ||
4 | |||
5 | Licensed under the Apache License, Version 2.0 (the "License"); | ||
6 | you may not use this file except in compliance with the License. | ||
7 | You may obtain a copy of the License at | ||
8 | |||
9 | http://www.apache.org/licenses/LICENSE-2.0 | ||
10 | |||
11 | Unless required by applicable law or agreed to in writing, software | ||
12 | distributed under the License is distributed on an "AS IS" BASIS, | ||
13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
14 | See the License for the specific language governing permissions and | ||
15 | limitations under the License. | ||
16 | */ | ||
17 | |||
18 | #ifndef _MCUCONF_H_ | ||
19 | #define _MCUCONF_H_ | ||
20 | |||
21 | #define MK66FX1M0_MCUCONF | ||
22 | |||
23 | /* | ||
24 | * HAL driver system settings. | ||
25 | */ | ||
26 | |||
27 | /* Select the MCU clocking mode below by enabling the appropriate block. */ | ||
28 | |||
29 | /* PEE mode - 180 MHz system clock driving by 16 MHz xtal */ | ||
30 | #define KINETIS_MCG_MODE KINETIS_MCG_MODE_PEE | ||
31 | //#define KINETIS_PLLCLK_FREQUENCY 180000000UL // 180 MHz (HSRUN) | ||
32 | #define KINETIS_PLLCLK_FREQUENCY 120000000UL // 120 MHz (RUN) | ||
33 | #define KINETIS_SYSCLK_FREQUENCY KINETIS_PLLCLK_FREQUENCY | ||
34 | #define KINETIS_BUSCLK_FREQUENCY 60000000UL | ||
35 | //#define KINETIS_FLASHCLK_FREQUENCY 28000000UL // 28 MHz (HSRUN) | ||
36 | #define KINETIS_FLASHCLK_FREQUENCY 24000000UL // 24 MHz (RUN) | ||
37 | |||
38 | #if KINETIS_PLLCLK_FREQUENCY == 180000000UL | ||
39 | # define KINETIS_CLKDIV1_OUTDIV1 1 // -> 0 | ||
40 | # define KINETIS_CLKDIV1_OUTDIV2 3 // -> 2 | ||
41 | # define KINETIS_CLKDIV1_OUTDIV4 7 // -> 6 | ||
42 | #else | ||
43 | # define KINETIS_CLKDIV1_OUTDIV1 1 // -> 0 | ||
44 | # define KINETIS_CLKDIV1_OUTDIV2 2 // -> 1 | ||
45 | # define KINETIS_CLKDIV1_OUTDIV4 5 // -> 4 | ||
46 | #endif | ||
47 | |||
48 | /* | ||
49 | * SERIAL driver system settings. | ||
50 | */ | ||
51 | #define KINETIS_SERIAL_USE_UART4 TRUE | ||
52 | |||
53 | /* | ||
54 | * USB driver settings | ||
55 | */ | ||
56 | #define KINETIS_USB_USE_USB0 TRUE | ||
57 | #define KINETIS_USB_USB0_IRQ_PRIORITY 5 | ||
58 | |||
59 | /* | ||
60 | * I2C driver settings | ||
61 | */ | ||
62 | #define KINETIS_I2C_USE_I2C0 TRUE | ||
63 | #define KINETIS_I2C_I2C0_PRIORITY 4 | ||
64 | |||
65 | #endif /* _MCUCONF_H_ */ | ||
diff --git a/keyboards/kinesis/kint36/readme.md b/keyboards/kinesis/kint36/readme.md new file mode 100644 index 000000000..a2bb0c1cf --- /dev/null +++ b/keyboards/kinesis/kint36/readme.md | |||
@@ -0,0 +1,3 @@ | |||
1 | # kinesis_kint36 keyboard firmware | ||
2 | |||
3 | Please see https://github.com/kinx-project/kint for details. | ||
diff --git a/keyboards/kinesis/kint36/rules.mk b/keyboards/kinesis/kint36/rules.mk new file mode 100644 index 000000000..cf58cb913 --- /dev/null +++ b/keyboards/kinesis/kint36/rules.mk | |||
@@ -0,0 +1,6 @@ | |||
1 | BOARD = PJRC_TEENSY_3_6 | ||
2 | MCU = MK66F18 | ||
3 | |||
4 | # Debounce eagerly (report change immediately), keep per-key timers. We can use | ||
5 | # this because the kinT does not have to deal with noise. | ||
6 | DEBOUNCE_TYPE = sym_eager_pk | ||
diff --git a/keyboards/kinesis/nguyenvietyen/rules.mk b/keyboards/kinesis/nguyenvietyen/rules.mk index c2d5f729b..a401973aa 100644 --- a/keyboards/kinesis/nguyenvietyen/rules.mk +++ b/keyboards/kinesis/nguyenvietyen/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = caterina | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes | 10 | BOOTMAGIC_ENABLE = full |
11 | MOUSEKEY_ENABLE = yes | 11 | MOUSEKEY_ENABLE = yes |
12 | EXTRAKEY_ENABLE = yes | 12 | EXTRAKEY_ENABLE = yes |
13 | COMMAND_ENABLE = yes | 13 | COMMAND_ENABLE = yes |
diff --git a/keyboards/kinesis/rules.mk b/keyboards/kinesis/rules.mk index cc0691e98..651751fa6 100644 --- a/keyboards/kinesis/rules.mk +++ b/keyboards/kinesis/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kinesis/stapelberg/config.h b/keyboards/kinesis/stapelberg/config.h index 5037baebd..8f920c19c 100644 --- a/keyboards/kinesis/stapelberg/config.h +++ b/keyboards/kinesis/stapelberg/config.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define STAPELBERG_CONFIG_H | 2 | #define STAPELBERG_CONFIG_H |
3 | 3 | ||
4 | #include "../config.h" | 4 | #include "../config.h" |
5 | #include "config_common.h" | ||
5 | 6 | ||
6 | /* USB Device descriptor parameter */ | 7 | /* USB Device descriptor parameter */ |
7 | #define PRODUCT_ID 0x6060 | 8 | #define PRODUCT_ID 0x6060 |
diff --git a/keyboards/kingly_keys/ropro/rules.mk b/keyboards/kingly_keys/ropro/rules.mk index d3fad8265..a8cce7780 100644 --- a/keyboards/kingly_keys/ropro/rules.mk +++ b/keyboards/kingly_keys/ropro/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kingly_keys/soap/rules.mk b/keyboards/kingly_keys/soap/rules.mk index 56adb1e55..e6d997bfe 100644 --- a/keyboards/kingly_keys/soap/rules.mk +++ b/keyboards/kingly_keys/soap/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kmac/rules.mk b/keyboards/kmac/rules.mk index 33e423d3d..2a35f70cd 100644 --- a/keyboards/kmac/rules.mk +++ b/keyboards/kmac/rules.mk | |||
@@ -17,7 +17,7 @@ BOOTLOADER = atmel-dfu | |||
17 | # Build Options | 17 | # Build Options |
18 | # change yes to no to disable | 18 | # change yes to no to disable |
19 | # | 19 | # |
20 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 20 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
21 | MOUSEKEY_ENABLE = yes # Mouse keys | 21 | MOUSEKEY_ENABLE = yes # Mouse keys |
22 | EXTRAKEY_ENABLE = yes # Audio control and System control | 22 | EXTRAKEY_ENABLE = yes # Audio control and System control |
23 | CONSOLE_ENABLE = no # Console for debug | 23 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kmini/rules.mk b/keyboards/kmini/rules.mk index f40b013f7..1694b9ac6 100755 --- a/keyboards/kmini/rules.mk +++ b/keyboards/kmini/rules.mk | |||
@@ -17,7 +17,7 @@ BOOTLOADER = atmel-dfu | |||
17 | # Build Options | 17 | # Build Options |
18 | # change yes to no to disable | 18 | # change yes to no to disable |
19 | # | 19 | # |
20 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 20 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
21 | MOUSEKEY_ENABLE = yes # Mouse keys | 21 | MOUSEKEY_ENABLE = yes # Mouse keys |
22 | EXTRAKEY_ENABLE = yes # Audio control and System control | 22 | EXTRAKEY_ENABLE = yes # Audio control and System control |
23 | CONSOLE_ENABLE = no # Console for debug | 23 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/ansi/rules.mk b/keyboards/kona_classic/keymaps/ansi/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/ansi/rules.mk +++ b/keyboards/kona_classic/keymaps/ansi/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/ansi_arrows/rules.mk b/keyboards/kona_classic/keymaps/ansi_arrows/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/ansi_arrows/rules.mk +++ b/keyboards/kona_classic/keymaps/ansi_arrows/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/ansi_arrows_lcap/rules.mk b/keyboards/kona_classic/keymaps/ansi_arrows_lcap/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/ansi_arrows_lcap/rules.mk +++ b/keyboards/kona_classic/keymaps/ansi_arrows_lcap/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/ansi_split/rules.mk b/keyboards/kona_classic/keymaps/ansi_split/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/ansi_split/rules.mk +++ b/keyboards/kona_classic/keymaps/ansi_split/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/ansi_split_arrows/rules.mk b/keyboards/kona_classic/keymaps/ansi_split_arrows/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/ansi_split_arrows/rules.mk +++ b/keyboards/kona_classic/keymaps/ansi_split_arrows/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/default/rules.mk b/keyboards/kona_classic/keymaps/default/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/default/rules.mk +++ b/keyboards/kona_classic/keymaps/default/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/iso/rules.mk b/keyboards/kona_classic/keymaps/iso/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/iso/rules.mk +++ b/keyboards/kona_classic/keymaps/iso/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/iso_arrows/rules.mk b/keyboards/kona_classic/keymaps/iso_arrows/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/iso_arrows/rules.mk +++ b/keyboards/kona_classic/keymaps/iso_arrows/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/iso_split/rules.mk b/keyboards/kona_classic/keymaps/iso_split/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/iso_split/rules.mk +++ b/keyboards/kona_classic/keymaps/iso_split/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/kona_classic/keymaps/iso_split_arrows/rules.mk b/keyboards/kona_classic/keymaps/iso_split_arrows/rules.mk index e4865902c..fec19c9df 100644 --- a/keyboards/kona_classic/keymaps/iso_split_arrows/rules.mk +++ b/keyboards/kona_classic/keymaps/iso_split_arrows/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = yes # Mouse keys | 22 | MOUSEKEY_ENABLE = yes # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = no # Console for debug | 24 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/leeku/finger65/rules.mk b/keyboards/leeku/finger65/rules.mk index 16ce59ecb..1ebd43b08 100644 --- a/keyboards/leeku/finger65/rules.mk +++ b/keyboards/leeku/finger65/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = bootloadHID | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = no # Audio control and System control | 19 | EXTRAKEY_ENABLE = no # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/lets_split/keymaps/pyrol/rules.mk b/keyboards/lets_split/keymaps/pyrol/rules.mk index 6e1be51be..8d49979f9 100644 --- a/keyboards/lets_split/keymaps/pyrol/rules.mk +++ b/keyboards/lets_split/keymaps/pyrol/rules.mk | |||
@@ -1 +1 @@ | |||
BOOTMAGIC_ENABLE = yes | BOOTMAGIC_ENABLE = full | ||
diff --git a/keyboards/masterworks/classy_tkl/rev_a/rules.mk b/keyboards/masterworks/classy_tkl/rev_a/rules.mk index 34bcd87a4..68d6bc50c 100644 --- a/keyboards/masterworks/classy_tkl/rev_a/rules.mk +++ b/keyboards/masterworks/classy_tkl/rev_a/rules.mk | |||
@@ -8,7 +8,7 @@ BOOTLOADER = atmel-dfu | |||
8 | # Build Options | 8 | # Build Options |
9 | # change yes to no to disable | 9 | # change yes to no to disable |
10 | # | 10 | # |
11 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 11 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
12 | MOUSEKEY_ENABLE = yes # Mouse keys | 12 | MOUSEKEY_ENABLE = yes # Mouse keys |
13 | EXTRAKEY_ENABLE = yes # Audio control and System control | 13 | EXTRAKEY_ENABLE = yes # Audio control and System control |
14 | CONSOLE_ENABLE = yes # Console for debug | 14 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/matrix/m12og/rules.mk b/keyboards/matrix/m12og/rules.mk index 74432d49c..58ec898a6 100644 --- a/keyboards/matrix/m12og/rules.mk +++ b/keyboards/matrix/m12og/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/matrix/m20add/rules.mk b/keyboards/matrix/m20add/rules.mk index 93ddf05e9..d5516964d 100644 --- a/keyboards/matrix/m20add/rules.mk +++ b/keyboards/matrix/m20add/rules.mk | |||
@@ -13,7 +13,7 @@ BOARD = ST_NUCLEO64_F411RE | |||
13 | # Build Options | 13 | # Build Options |
14 | # comment out to disable the options. | 14 | # comment out to disable the options. |
15 | # | 15 | # |
16 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 16 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
17 | MOUSEKEY_ENABLE = yes # Mouse keys | 17 | MOUSEKEY_ENABLE = yes # Mouse keys |
18 | EXTRAKEY_ENABLE = yes # Audio control and System control | 18 | EXTRAKEY_ENABLE = yes # Audio control and System control |
19 | CONSOLE_ENABLE = no # Console for debug | 19 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/matrix/noah/rules.mk b/keyboards/matrix/noah/rules.mk index 5566bd26a..25106a9b5 100644 --- a/keyboards/matrix/noah/rules.mk +++ b/keyboards/matrix/noah/rules.mk | |||
@@ -13,7 +13,7 @@ BOARD = ST_NUCLEO64_F411RE | |||
13 | # Build Options | 13 | # Build Options |
14 | # comment out to disable the options. | 14 | # comment out to disable the options. |
15 | # | 15 | # |
16 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 16 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
17 | MOUSEKEY_ENABLE = yes # Mouse keys | 17 | MOUSEKEY_ENABLE = yes # Mouse keys |
18 | EXTRAKEY_ENABLE = yes # Audio control and System control | 18 | EXTRAKEY_ENABLE = yes # Audio control and System control |
19 | CONSOLE_ENABLE = no # Console for debug | 19 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/mechmini/v1/rules.mk b/keyboards/mechmini/v1/rules.mk index 93646c8e1..c1582d9c6 100644 --- a/keyboards/mechmini/v1/rules.mk +++ b/keyboards/mechmini/v1/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32a | |||
12 | BOOTLOADER = atmel-dfu | 12 | BOOTLOADER = atmel-dfu |
13 | 13 | ||
14 | # build options | 14 | # build options |
15 | BOOTMAGIC_ENABLE = yes | 15 | BOOTMAGIC_ENABLE = full |
16 | MOUSEKEY_ENABLE = yes | 16 | MOUSEKEY_ENABLE = yes |
17 | EXTRAKEY_ENABLE = yes | 17 | EXTRAKEY_ENABLE = yes |
18 | CONSOLE_ENABLE = no | 18 | CONSOLE_ENABLE = no |
diff --git a/keyboards/mechmini/v2/keymaps/lbibass_625_space/rules.mk b/keyboards/mechmini/v2/keymaps/lbibass_625_space/rules.mk index 7bc50168d..49a55db51 100755 --- a/keyboards/mechmini/v2/keymaps/lbibass_625_space/rules.mk +++ b/keyboards/mechmini/v2/keymaps/lbibass_625_space/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 1 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
3 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 3 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
4 | CONSOLE_ENABLE = yes # Console for debug(+400) | 4 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/mechmini/v2/keymaps/lbibass_split_space/rules.mk b/keyboards/mechmini/v2/keymaps/lbibass_split_space/rules.mk index fd3621e84..9ea2eeee8 100755 --- a/keyboards/mechmini/v2/keymaps/lbibass_split_space/rules.mk +++ b/keyboards/mechmini/v2/keymaps/lbibass_split_space/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 1 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
3 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 3 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
4 | CONSOLE_ENABLE = yes # Console for debug(+400) | 4 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/mechmini/v2/keymaps/wsturgiss/rules.mk b/keyboards/mechmini/v2/keymaps/wsturgiss/rules.mk index a2c78f8db..1484e2dd0 100755 --- a/keyboards/mechmini/v2/keymaps/wsturgiss/rules.mk +++ b/keyboards/mechmini/v2/keymaps/wsturgiss/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 1 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
2 | CONSOLE_ENABLE = no # Console for debug(+400) | 2 | CONSOLE_ENABLE = no # Console for debug(+400) |
3 | COMMAND_ENABLE = no # Commands for debug and configuration | 3 | COMMAND_ENABLE = no # Commands for debug and configuration |
4 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 4 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend |
diff --git a/keyboards/mechmini/v2/rules.mk b/keyboards/mechmini/v2/rules.mk index a82774319..d585958de 100755 --- a/keyboards/mechmini/v2/rules.mk +++ b/keyboards/mechmini/v2/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/mehkee96/rules.mk b/keyboards/mehkee96/rules.mk index 488c63fce..91c9dc0df 100644 --- a/keyboards/mehkee96/rules.mk +++ b/keyboards/mehkee96/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = bootloadHID | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/mitosis/rules.mk b/keyboards/mitosis/rules.mk index 4cb6d8c9b..5ca62fc8b 100644 --- a/keyboards/mitosis/rules.mk +++ b/keyboards/mitosis/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/mt40/rules.mk b/keyboards/mt40/rules.mk index 2b8e18a95..3f4847400 100644 --- a/keyboards/mt40/rules.mk +++ b/keyboards/mt40/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32a | |||
12 | BOOTLOADER = bootloadHID | 12 | BOOTLOADER = bootloadHID |
13 | 13 | ||
14 | # build options | 14 | # build options |
15 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 15 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
16 | MOUSEKEY_ENABLE = no # Mouse keys | 16 | MOUSEKEY_ENABLE = no # Mouse keys |
17 | EXTRAKEY_ENABLE = yes # Audio control and System control | 17 | EXTRAKEY_ENABLE = yes # Audio control and System control |
18 | CONSOLE_ENABLE = no # Console for debug | 18 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/mt64rgb/rules.mk b/keyboards/mt64rgb/rules.mk index 08450b37a..b77c0d52b 100644 --- a/keyboards/mt64rgb/rules.mk +++ b/keyboards/mt64rgb/rules.mk | |||
@@ -25,3 +25,5 @@ BLUETOOTH_ENABLE = no # Enable Bluetooth | |||
25 | AUDIO_ENABLE = no # Audio output | 25 | AUDIO_ENABLE = no # Audio output |
26 | 26 | ||
27 | LAYOUTS = 64_ansi | 27 | LAYOUTS = 64_ansi |
28 | |||
29 | LTO_ENABLE = yes | ||
diff --git a/keyboards/nemui/rules.mk b/keyboards/nemui/rules.mk index 109141ebb..011a8a89b 100644 --- a/keyboards/nemui/rules.mk +++ b/keyboards/nemui/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/nightly_boards/ph_arisu/rules.mk b/keyboards/nightly_boards/ph_arisu/rules.mk index e70a8a7d6..bde08efba 100644 --- a/keyboards/nightly_boards/ph_arisu/rules.mk +++ b/keyboards/nightly_boards/ph_arisu/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = caterina | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/nopunin10did/railroad/rev0/rules.mk b/keyboards/nopunin10did/railroad/rev0/rules.mk index a7facc532..54bb17ad2 100644 --- a/keyboards/nopunin10did/railroad/rev0/rules.mk +++ b/keyboards/nopunin10did/railroad/rev0/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = atmel-dfu | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/ok60/rules.mk b/keyboards/ok60/rules.mk index 064683816..f2801c945 100644 --- a/keyboards/ok60/rules.mk +++ b/keyboards/ok60/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | # CONSOLE_ENABLE = yes # Console for debug | 20 | # CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/omnikey_bh/rules.mk b/keyboards/omnikey_bh/rules.mk index 739bea393..1843f1ba6 100644 --- a/keyboards/omnikey_bh/rules.mk +++ b/keyboards/omnikey_bh/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/orange75/rules.mk b/keyboards/orange75/rules.mk index ce242bb2a..08a8fc02e 100644 --- a/keyboards/orange75/rules.mk +++ b/keyboards/orange75/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/org60/rules.mk b/keyboards/org60/rules.mk index a57d68acc..f115d70ba 100644 --- a/keyboards/org60/rules.mk +++ b/keyboards/org60/rules.mk | |||
@@ -15,7 +15,7 @@ BOOTLOADER = atmel-dfu | |||
15 | AUDIO_ENABLE = no # Audio output on port C6 | 15 | AUDIO_ENABLE = no # Audio output on port C6 |
16 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality | 16 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality |
17 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID | 17 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID |
18 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 18 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
19 | COMMAND_ENABLE = no # Commands for debug and configuration | 19 | COMMAND_ENABLE = no # Commands for debug and configuration |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
21 | EXTRAKEY_ENABLE = yes # Audio control and System control | 21 | EXTRAKEY_ENABLE = yes # Audio control and System control |
diff --git a/keyboards/paladin64/rules.mk b/keyboards/paladin64/rules.mk index 739e00613..a4fb2cf3a 100755 --- a/keyboards/paladin64/rules.mk +++ b/keyboards/paladin64/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/pearl/keymaps/cijanzen/rules.mk b/keyboards/pearl/keymaps/cijanzen/rules.mk index 863b9419a..90be4603a 100644 --- a/keyboards/pearl/keymaps/cijanzen/rules.mk +++ b/keyboards/pearl/keymaps/cijanzen/rules.mk | |||
@@ -1,5 +1,5 @@ | |||
1 | # build options | 1 | # build options |
2 | BOOTMAGIC_ENABLE = yes | 2 | BOOTMAGIC_ENABLE = full |
3 | MOUSEKEY_ENABLE = no | 3 | MOUSEKEY_ENABLE = no |
4 | EXTRAKEY_ENABLE = yes | 4 | EXTRAKEY_ENABLE = yes |
5 | CONSOLE_ENABLE = no | 5 | CONSOLE_ENABLE = no |
diff --git a/keyboards/peiorisboards/ixora/rules.mk b/keyboards/peiorisboards/ixora/rules.mk index 1d93c6a30..5451bf95e 100644 --- a/keyboards/peiorisboards/ixora/rules.mk +++ b/keyboards/peiorisboards/ixora/rules.mk | |||
@@ -5,7 +5,7 @@ MCU = STM32F042 | |||
5 | # comment out to disable the options. | 5 | # comment out to disable the options. |
6 | # | 6 | # |
7 | BACKLIGHT_ENABLE = no | 7 | BACKLIGHT_ENABLE = no |
8 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 8 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
9 | MOUSEKEY_ENABLE = yes # Mouse keys | 9 | MOUSEKEY_ENABLE = yes # Mouse keys |
10 | EXTRAKEY_ENABLE = yes # Audio control and System control | 10 | EXTRAKEY_ENABLE = yes # Audio control and System control |
11 | CONSOLE_ENABLE = no # Console for debug | 11 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/planck/ez/rules.mk b/keyboards/planck/ez/rules.mk index 71f0a5fd1..acf3455c9 100644 --- a/keyboards/planck/ez/rules.mk +++ b/keyboards/planck/ez/rules.mk | |||
@@ -6,7 +6,7 @@ BOARD = QMK_PROTON_C | |||
6 | # change to "no" to disable the options, or define them in the Makefile in | 6 | # change to "no" to disable the options, or define them in the Makefile in |
7 | # the appropriate keymap folder that will get included automatically | 7 | # the appropriate keymap folder that will get included automatically |
8 | # | 8 | # |
9 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = yes # Mouse keys | 10 | MOUSEKEY_ENABLE = yes # Mouse keys |
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/planck/keymaps/danielhklein/rules.mk b/keyboards/planck/keymaps/danielhklein/rules.mk index 72386fae7..4660d443d 100644 --- a/keyboards/planck/keymaps/danielhklein/rules.mk +++ b/keyboards/planck/keymaps/danielhklein/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 1 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 2 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
3 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 3 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
4 | CONSOLE_ENABLE = no # Console for debug(+400) | 4 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/planck/keymaps/vifon/rules.mk b/keyboards/planck/keymaps/vifon/rules.mk index 527e63d38..3f9b4544e 100644 --- a/keyboards/planck/keymaps/vifon/rules.mk +++ b/keyboards/planck/keymaps/vifon/rules.mk | |||
@@ -4,7 +4,7 @@ | |||
4 | # change to "no" to disable the options, or define them in the Makefile in | 4 | # change to "no" to disable the options, or define them in the Makefile in |
5 | # the appropriate keymap folder that will get included automatically | 5 | # the appropriate keymap folder that will get included automatically |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
8 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 8 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
10 | CONSOLE_ENABLE = no # Console for debug(+400) | 10 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/planck/rev6/rules.mk b/keyboards/planck/rev6/rules.mk index c3fcf3dbd..e0f9ff0d0 100644 --- a/keyboards/planck/rev6/rules.mk +++ b/keyboards/planck/rev6/rules.mk | |||
@@ -6,7 +6,7 @@ BOARD = QMK_PROTON_C | |||
6 | # change to "no" to disable the options, or define them in the Makefile in | 6 | # change to "no" to disable the options, or define them in the Makefile in |
7 | # the appropriate keymap folder that will get included automatically | 7 | # the appropriate keymap folder that will get included automatically |
8 | # | 8 | # |
9 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = yes # Mouse keys | 10 | MOUSEKEY_ENABLE = yes # Mouse keys |
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/playkbtw/pk60/rules.mk b/keyboards/playkbtw/pk60/rules.mk index 23b186842..948e212e6 100644 --- a/keyboards/playkbtw/pk60/rules.mk +++ b/keyboards/playkbtw/pk60/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/preonic/keymaps/dlaroe/rules.mk b/keyboards/preonic/keymaps/dlaroe/rules.mk index 68f78de6e..2b7cff4db 100644 --- a/keyboards/preonic/keymaps/dlaroe/rules.mk +++ b/keyboards/preonic/keymaps/dlaroe/rules.mk | |||
@@ -4,7 +4,7 @@ | |||
4 | # change to "no" to disable the options, or define them in the Makefile in | 4 | # change to "no" to disable the options, or define them in the Makefile in |
5 | # the appropriate keymap folder that will get included automatically | 5 | # the appropriate keymap folder that will get included automatically |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
8 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 8 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
10 | CONSOLE_ENABLE = no # Console for debug(+400) | 10 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/preonic/rev3/rules.mk b/keyboards/preonic/rev3/rules.mk index 249d13705..d600be4a4 100644 --- a/keyboards/preonic/rev3/rules.mk +++ b/keyboards/preonic/rev3/rules.mk | |||
@@ -6,7 +6,7 @@ BOARD = QMK_PROTON_C | |||
6 | # change to "no" to disable the options, or define them in the Makefile in | 6 | # change to "no" to disable the options, or define them in the Makefile in |
7 | # the appropriate keymap folder that will get included automatically | 7 | # the appropriate keymap folder that will get included automatically |
8 | # | 8 | # |
9 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 9 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
10 | MOUSEKEY_ENABLE = yes # Mouse keys | 10 | MOUSEKEY_ENABLE = yes # Mouse keys |
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | 11 | EXTRAKEY_ENABLE = yes # Audio control and System control |
12 | CONSOLE_ENABLE = yes # Console for debug | 12 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/primekb/prime_e/rules.mk b/keyboards/primekb/prime_e/rules.mk index e9045dba9..f5ea0075c 100644 --- a/keyboards/primekb/prime_e/rules.mk +++ b/keyboards/primekb/prime_e/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/primekb/prime_r/rules.mk b/keyboards/primekb/prime_r/rules.mk index 6f7dd4705..101e16752 100644 --- a/keyboards/primekb/prime_r/rules.mk +++ b/keyboards/primekb/prime_r/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/projectkb/alice/config.h b/keyboards/projectkb/alice/config.h new file mode 100644 index 000000000..95fb682e1 --- /dev/null +++ b/keyboards/projectkb/alice/config.h | |||
@@ -0,0 +1,3 @@ | |||
1 | #pragma once | ||
2 | |||
3 | #define SLEEP_LED_GPT_DRIVER GPTD1 | ||
diff --git a/keyboards/projectkb/alice/halconf.h b/keyboards/projectkb/alice/halconf.h index b17808ffe..0016e53ba 100644 --- a/keyboards/projectkb/alice/halconf.h +++ b/keyboards/projectkb/alice/halconf.h | |||
@@ -27,5 +27,7 @@ | |||
27 | 27 | ||
28 | #define HAL_USE_SPI TRUE | 28 | #define HAL_USE_SPI TRUE |
29 | 29 | ||
30 | #define HAL_USE_GPT TRUE | ||
31 | |||
30 | #include_next <halconf.h> | 32 | #include_next <halconf.h> |
31 | 33 | ||
diff --git a/keyboards/projectkb/alice/mcuconf.h b/keyboards/projectkb/alice/mcuconf.h index 4bfc7f946..6e0f1a50d 100644 --- a/keyboards/projectkb/alice/mcuconf.h +++ b/keyboards/projectkb/alice/mcuconf.h | |||
@@ -32,3 +32,5 @@ | |||
32 | #undef STM32_SPI_USE_SPI2 | 32 | #undef STM32_SPI_USE_SPI2 |
33 | #define STM32_SPI_USE_SPI2 TRUE | 33 | #define STM32_SPI_USE_SPI2 TRUE |
34 | 34 | ||
35 | #undef STM32_GPT_USE_TIM1 | ||
36 | #define STM32_GPT_USE_TIM1 TRUE | ||
diff --git a/keyboards/projectkb/signature87/rules.mk b/keyboards/projectkb/signature87/rules.mk index fe0d976d1..a307166cd 100644 --- a/keyboards/projectkb/signature87/rules.mk +++ b/keyboards/projectkb/signature87/rules.mk | |||
@@ -4,12 +4,12 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # comment out to disable the options. | 5 | # comment out to disable the options. |
6 | # | 6 | # |
7 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
11 | COMMAND_ENABLE = yes # Commands for debug and configuration | 11 | COMMAND_ENABLE = yes # Commands for debug and configuration |
12 | SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend | 12 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
13 | NKRO_ENABLE = yes # USB Nkey Rollover | 13 | NKRO_ENABLE = yes # USB Nkey Rollover |
14 | BACKLIGHT_ENABLE = no | 14 | BACKLIGHT_ENABLE = no |
15 | 15 | ||
diff --git a/keyboards/rainkeeb/rules.mk b/keyboards/rainkeeb/rules.mk index aa9aab9b7..0c7dd09c2 100644 --- a/keyboards/rainkeeb/rules.mk +++ b/keyboards/rainkeeb/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = caterina | |||
7 | # Build Options | 7 | # Build Options |
8 | # comment out to disable the options. | 8 | # comment out to disable the options. |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/ramonimbao/wete/config.h b/keyboards/ramonimbao/wete/config.h index 5d68a7efd..3d8955009 100644 --- a/keyboards/ramonimbao/wete/config.h +++ b/keyboards/ramonimbao/wete/config.h | |||
@@ -46,6 +46,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
46 | #define RGBLED_NUM 24 | 46 | #define RGBLED_NUM 24 |
47 | #define RGBLIGHT_ANIMATIONS | 47 | #define RGBLIGHT_ANIMATIONS |
48 | 48 | ||
49 | #define SLEEP_LED_GPT_DRIVER GPTD1 | ||
50 | |||
49 | /* define if matrix has ghost */ | 51 | /* define if matrix has ghost */ |
50 | //#define MATRIX_HAS_GHOST | 52 | //#define MATRIX_HAS_GHOST |
51 | 53 | ||
diff --git a/keyboards/ramonimbao/wete/halconf.h b/keyboards/ramonimbao/wete/halconf.h index c43440a45..b3de873be 100644 --- a/keyboards/ramonimbao/wete/halconf.h +++ b/keyboards/ramonimbao/wete/halconf.h | |||
@@ -23,5 +23,7 @@ | |||
23 | 23 | ||
24 | #define HAL_USE_PWM TRUE | 24 | #define HAL_USE_PWM TRUE |
25 | 25 | ||
26 | #define HAL_USE_GPT TRUE | ||
27 | |||
26 | #include_next <halconf.h> | 28 | #include_next <halconf.h> |
27 | 29 | ||
diff --git a/keyboards/ramonimbao/wete/mcuconf.h b/keyboards/ramonimbao/wete/mcuconf.h index b7f2c481c..7a2e87776 100644 --- a/keyboards/ramonimbao/wete/mcuconf.h +++ b/keyboards/ramonimbao/wete/mcuconf.h | |||
@@ -35,3 +35,5 @@ | |||
35 | #undef STM32_SPI_USE_SPI2 | 35 | #undef STM32_SPI_USE_SPI2 |
36 | #define STM32_SPI_USE_SPI2 TRUE | 36 | #define STM32_SPI_USE_SPI2 TRUE |
37 | 37 | ||
38 | #undef STM32_GPT_USE_TIM1 | ||
39 | #define STM32_GPT_USE_TIM1 TRUE | ||
diff --git a/keyboards/ramonimbao/wete/rules.mk b/keyboards/ramonimbao/wete/rules.mk index 81c717c57..039cc87a2 100644 --- a/keyboards/ramonimbao/wete/rules.mk +++ b/keyboards/ramonimbao/wete/rules.mk | |||
@@ -5,7 +5,7 @@ MCU = STM32F072 | |||
5 | # comment out to disable the options. | 5 | # comment out to disable the options. |
6 | # | 6 | # |
7 | 7 | ||
8 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 8 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
9 | MOUSEKEY_ENABLE = yes # Mouse keys | 9 | MOUSEKEY_ENABLE = yes # Mouse keys |
10 | EXTRAKEY_ENABLE = yes # Audio control and System control | 10 | EXTRAKEY_ENABLE = yes # Audio control and System control |
11 | CONSOLE_ENABLE = yes # Console for debug | 11 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/readme.md b/keyboards/readme.md index 6b7b92e0c..a23d0845b 100644 --- a/keyboards/readme.md +++ b/keyboards/readme.md | |||
@@ -63,4 +63,4 @@ These keyboards are part of the QMK repository, but their manufacturers are not | |||
63 | * [Vision Division](/keyboards/vision_division) — Full Size / Split Linear Keyboard by IBNobody. | 63 | * [Vision Division](/keyboards/vision_division) — Full Size / Split Linear Keyboard by IBNobody. |
64 | * [XD004](/keyboards/xd004) — 1x4 macro keyboard sold by KPrepublic. | 64 | * [XD004](/keyboards/xd004) — 1x4 macro keyboard sold by KPrepublic. |
65 | * [XD75](/keyboards/xd75) — 15x5 ortholinear keyboard by XIUDI. | 65 | * [XD75](/keyboards/xd75) — 15x5 ortholinear keyboard by XIUDI. |
66 | * [YMDK NP21](/keyboards/ymdk_np21) — ps2avrGB based number pad (numpad) sold by YMDK on Aliexpress. | 66 | * [YMDK NP21](/keyboards/ymdk_np21) — ps2avrGB based number pad (numpad) sold by YMDK on Aliexpress. |
diff --git a/keyboards/redox_w/rules.mk b/keyboards/redox_w/rules.mk index 01d5c3c70..b7084b4a1 100644 --- a/keyboards/redox_w/rules.mk +++ b/keyboards/redox_w/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/reversestudio/decadepad/rules.mk b/keyboards/reversestudio/decadepad/rules.mk index 65dbf4901..6011be9e8 100644 --- a/keyboards/reversestudio/decadepad/rules.mk +++ b/keyboards/reversestudio/decadepad/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/rgbkb/zygomorph/keymaps/xulkal/rules.mk b/keyboards/rgbkb/zygomorph/keymaps/xulkal/rules.mk index 78969ad7a..d7d50e137 100644 --- a/keyboards/rgbkb/zygomorph/keymaps/xulkal/rules.mk +++ b/keyboards/rgbkb/zygomorph/keymaps/xulkal/rules.mk | |||
@@ -8,11 +8,13 @@ EXTRAKEY_ENABLE = yes # Audio control and System control | |||
8 | CONSOLE_ENABLE = no # Console for debug | 8 | CONSOLE_ENABLE = no # Console for debug |
9 | COMMAND_ENABLE = no # Commands for debug and configuration | 9 | COMMAND_ENABLE = no # Commands for debug and configuration |
10 | NKRO_ENABLE = no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | 10 | NKRO_ENABLE = no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work |
11 | RGBLIGHT_ENABLE = yes # Enable global lighting effects. Do not enable with RGB Matrix | 11 | RGBLIGHT_ENABLE = no # Enable global lighting effects. Do not enable with RGB Matrix |
12 | RGBLIGHT_ANIMATIONS = yes # LED animations | 12 | RGBLIGHT_ANIMATIONS = no # LED animations |
13 | RGBLIGHT_SPLIT_ENABLE = yes # Split RGBLight Support | 13 | RGBLIGHT_SPLIT_ENABLE = no # Split RGBLight Support |
14 | RGB_MATRIX_ENABLE = no # Enable per-key coordinate based RGB effects. Do not enable with RGBlight | 14 | RGB_MATRIX_ENABLE = yes # Enable per-key coordinate based RGB effects. Do not enable with RGBlight |
15 | RGB_MATRIX_DRIVER = WS2812 | ||
15 | RGB_MATRIX_KEYPRESSES = no # Enable reactive per-key effects. | 16 | RGB_MATRIX_KEYPRESSES = no # Enable reactive per-key effects. |
17 | SPLIT_RGB_MATRIX_ENABLE = yes # For split RGB Matrix support | ||
16 | RGBLIGHT_FULL_POWER = yes # Allow maximum RGB brightness. Otherwise, limited to a safe level for a normal USB-A port | 18 | RGBLIGHT_FULL_POWER = yes # Allow maximum RGB brightness. Otherwise, limited to a safe level for a normal USB-A port |
17 | UNICODE_ENABLE = no # Unicode | 19 | UNICODE_ENABLE = no # Unicode |
18 | SWAP_HANDS_ENABLE = no # Enable one-hand typing | 20 | SWAP_HANDS_ENABLE = no # Enable one-hand typing |
@@ -40,3 +42,7 @@ endif | |||
40 | ifeq ($(strip $(RGBLIGHT_SPLIT_ENABLE)), yes) | 42 | ifeq ($(strip $(RGBLIGHT_SPLIT_ENABLE)), yes) |
41 | OPT_DEFS += -DRGBLIGHT_SPLIT_ENABLE | 43 | OPT_DEFS += -DRGBLIGHT_SPLIT_ENABLE |
42 | endif | 44 | endif |
45 | |||
46 | ifeq ($(strip $(SPLIT_RGB_MATRIX_ENABLE)), yes) | ||
47 | OPT_DEFS += -DSPLIT_TRANSPORT_MIRROR | ||
48 | endif | ||
diff --git a/keyboards/rgbkb/zygomorph/rev1/config.h b/keyboards/rgbkb/zygomorph/rev1/config.h index 667b68f73..190a8bbe3 100644 --- a/keyboards/rgbkb/zygomorph/rev1/config.h +++ b/keyboards/rgbkb/zygomorph/rev1/config.h | |||
@@ -55,7 +55,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
55 | #define RGBLED_NUM 60 | 55 | #define RGBLED_NUM 60 |
56 | #define RGBLED_SPLIT { 30, 30 } | 56 | #define RGBLED_SPLIT { 30, 30 } |
57 | #endif | 57 | #endif |
58 | #define DRIVER_LED_TOTAL 30 | 58 | |
59 | #define DRIVER_LED_TOTAL 60 | ||
60 | #define RGB_MATRIX_SPLIT { 30, 30 } | ||
59 | 61 | ||
60 | #ifdef IOS_DEVICE_ENABLE | 62 | #ifdef IOS_DEVICE_ENABLE |
61 | #define RGBLIGHT_LIMIT_VAL 40 | 63 | #define RGBLIGHT_LIMIT_VAL 40 |
diff --git a/keyboards/rgbkb/zygomorph/rev1/rev1.c b/keyboards/rgbkb/zygomorph/rev1/rev1.c index 3edf48c5d..1fb1716a0 100644 --- a/keyboards/rgbkb/zygomorph/rev1/rev1.c +++ b/keyboards/rgbkb/zygomorph/rev1/rev1.c | |||
@@ -2,72 +2,42 @@ | |||
2 | 2 | ||
3 | 3 | ||
4 | #ifdef RGB_MATRIX_ENABLE | 4 | #ifdef RGB_MATRIX_ENABLE |
5 | #define RGB_LEFT_HAND { { 0 | ( 5 << 4) }, { 102, 0 }, 4}, \ | 5 | led_config_t g_led_config = { { |
6 | { { 0 | ( 4 << 4) }, { 81, 0 }, 4}, \ | 6 | { 5, 4, 3, 2, 1, 0 }, |
7 | { { 0 | ( 3 << 4) }, { 61, 0 }, 4}, \ | 7 | { 11, 10, 9, 8, 7, 6 }, |
8 | { { 0 | ( 2 << 4) }, { 41, 0 }, 4}, \ | 8 | { 17, 16, 15, 14, 13, 12 }, |
9 | { { 0 | ( 1 << 4) }, { 20, 0 }, 4}, \ | 9 | { 23, 22, 21, 20, 19, 18 }, |
10 | { { 0 | ( 0 << 4) }, { 0, 0 }, 1}, \ | 10 | { 29, 28, 27, 26, 25, 24 }, |
11 | { { 1 | ( 5 << 4) }, { 102, 16 }, 4}, \ | 11 | { 35, 34, 33, 32, 31, 30 }, |
12 | { { 1 | ( 4 << 4) }, { 81, 16 }, 4}, \ | 12 | { 41, 40, 39, 38, 37, 36 }, |
13 | { { 1 | ( 3 << 4) }, { 61, 16 }, 4}, \ | 13 | { 47, 46, 45, 44, 43, 42 }, |
14 | { { 1 | ( 2 << 4) }, { 41, 16 }, 4}, \ | 14 | { 53, 52, 51, 50, 49, 48 }, |
15 | { { 1 | ( 1 << 4) }, { 20, 16 }, 4}, \ | 15 | { 59, 58, 57, 56, 55, 54 } |
16 | { { 1 | ( 0 << 4) }, { 0, 16 }, 1}, \ | 16 | }, { |
17 | { { 2 | ( 5 << 4) }, { 102, 32 }, 4}, \ | 17 | // Left Hand |
18 | { { 2 | ( 4 << 4) }, { 81, 32 }, 4}, \ | 18 | { 102, 0 }, { 81, 0 }, { 61, 0 }, { 41, 0 }, { 20, 0 }, { 0, 0 }, |
19 | { { 2 | ( 3 << 4) }, { 61, 32 }, 4}, \ | 19 | { 102, 16 }, { 81, 16 }, { 61, 16 }, { 41, 16 }, { 20, 16 }, { 0, 16 }, |
20 | { { 2 | ( 2 << 4) }, { 41, 32 }, 4}, \ | 20 | { 102, 32 }, { 81, 32 }, { 61, 32 }, { 41, 32 }, { 20, 32 }, { 0, 32 }, |
21 | { { 2 | ( 1 << 4) }, { 20, 32 }, 4}, \ | 21 | { 102, 48 }, { 81, 48 }, { 61, 48 }, { 41, 48 }, { 20, 48 }, { 0, 48 }, |
22 | { { 2 | ( 0 << 4) }, { 0, 32 }, 1}, \ | 22 | { 102, 64 }, { 81, 64 }, { 61, 64 }, { 41, 64 }, { 20, 64 }, { 0, 64 }, |
23 | { { 3 | ( 5 << 4) }, { 102, 48 }, 4}, \ | 23 | // Right Hand |
24 | { { 3 | ( 4 << 4) }, { 81, 48 }, 4}, \ | 24 | { 224, 0 }, { 204, 0 }, { 183, 0 }, { 163, 0 }, { 143, 0 }, { 122, 0 }, |
25 | { { 3 | ( 3 << 4) }, { 61, 48 }, 4}, \ | 25 | { 224, 16 }, { 204, 16 }, { 183, 16 }, { 163, 16 }, { 143, 16 }, { 122, 16 }, |
26 | { { 3 | ( 2 << 4) }, { 41, 48 }, 4}, \ | 26 | { 224, 32 }, { 204, 32 }, { 183, 32 }, { 163, 32 }, { 143, 32 }, { 122, 32 }, |
27 | { { 3 | ( 1 << 4) }, { 20, 48 }, 4}, \ | 27 | { 224, 48 }, { 204, 48 }, { 183, 48 }, { 163, 48 }, { 143, 48 }, { 122, 48 }, |
28 | { { 3 | ( 0 << 4) }, { 0, 48 }, 1}, \ | 28 | { 224, 64 }, { 204, 64 }, { 183, 64 }, { 163, 64 }, { 143, 64 }, { 122, 64 } |
29 | { { 4 | ( 5 << 4) }, { 102, 64 }, 1}, \ | 29 | }, { |
30 | { { 4 | ( 4 << 4) }, { 81, 64 }, 1}, \ | ||
31 | { { 4 | ( 3 << 4) }, { 61, 64 }, 1}, \ | ||
32 | { { 4 | ( 2 << 4) }, { 41, 64 }, 1}, \ | ||
33 | { { 4 | ( 1 << 4) }, { 20, 64 }, 1}, \ | ||
34 | { { 4 | ( 0 << 4) }, { 0, 64 }, 1} | ||
35 | |||
36 | #define RGB_RIGHT_HAND { { 0 | (11 << 4) }, { 224, 0 }, 1}, \ | ||
37 | { { 0 | (10 << 4) }, { 204, 0 }, 4}, \ | ||
38 | { { 0 | ( 9 << 4) }, { 183, 0 }, 4}, \ | ||
39 | { { 0 | ( 8 << 4) }, { 163, 0 }, 4}, \ | ||
40 | { { 0 | ( 7 << 4) }, { 143, 0 }, 4}, \ | ||
41 | { { 0 | ( 6 << 4) }, { 122, 0 }, 4}, \ | ||
42 | { { 1 | (11 << 4) }, { 224, 16 }, 1}, \ | ||
43 | { { 1 | (10 << 4) }, { 204, 16 }, 4}, \ | ||
44 | { { 1 | ( 9 << 4) }, { 183, 16 }, 4}, \ | ||
45 | { { 1 | ( 8 << 4) }, { 163, 16 }, 4}, \ | ||
46 | { { 1 | ( 7 << 4) }, { 143, 16 }, 4}, \ | ||
47 | { { 1 | ( 6 << 4) }, { 122, 16 }, 4}, \ | ||
48 | { { 2 | (11 << 4) }, { 224, 32 }, 1}, \ | ||
49 | { { 2 | (10 << 4) }, { 204, 32 }, 4}, \ | ||
50 | { { 2 | ( 9 << 4) }, { 183, 32 }, 4}, \ | ||
51 | { { 2 | ( 8 << 4) }, { 163, 32 }, 4}, \ | ||
52 | { { 2 | ( 7 << 4) }, { 143, 32 }, 4}, \ | ||
53 | { { 2 | ( 6 << 4) }, { 122, 32 }, 4}, \ | ||
54 | { { 3 | (11 << 4) }, { 224, 48 }, 1}, \ | ||
55 | { { 3 | (10 << 4) }, { 204, 48 }, 4}, \ | ||
56 | { { 3 | ( 9 << 4) }, { 183, 48 }, 4}, \ | ||
57 | { { 3 | ( 8 << 4) }, { 163, 48 }, 4}, \ | ||
58 | { { 3 | ( 7 << 4) }, { 143, 48 }, 4}, \ | ||
59 | { { 3 | ( 6 << 4) }, { 122, 48 }, 4}, \ | ||
60 | { { 4 | (11 << 4) }, { 224, 64 }, 1}, \ | ||
61 | { { 4 | (10 << 4) }, { 204, 64 }, 1}, \ | ||
62 | { { 4 | ( 9 << 4) }, { 183, 64 }, 1}, \ | ||
63 | { { 4 | ( 8 << 4) }, { 163, 64 }, 1}, \ | ||
64 | { { 4 | ( 7 << 4) }, { 143, 64 }, 1}, \ | ||
65 | { { 4 | ( 6 << 4) }, { 122, 64 }, 1} | ||
66 | |||
67 | rgb_led g_rgb_leds[DRIVER_LED_TOTAL] = { | ||
68 | // Left Hand | 30 | // Left Hand |
69 | RGB_LEFT_HAND | 31 | 4, 4, 4, 4, 4, 1, |
32 | 4, 4, 4, 4, 4, 1, | ||
33 | 4, 4, 4, 4, 4, 1, | ||
34 | 4, 4, 4, 4, 4, 1, | ||
35 | 1, 1, 1, 1, 1, 1, | ||
70 | // Right Hand | 36 | // Right Hand |
71 | //RGB_RIGHT_HAND | 37 | 4, 4, 4, 4, 4, 4, |
72 | }; | 38 | 1, 4, 4, 4, 4, 4, |
39 | 1, 4, 4, 4, 4, 4, | ||
40 | 1, 4, 4, 4, 4, 4, | ||
41 | 1, 1, 1, 1, 1, 1 | ||
42 | } }; | ||
73 | #endif | 43 | #endif |
diff --git a/keyboards/rotr/rules.mk b/keyboards/rotr/rules.mk index 38e08de7a..6f93f044e 100644 --- a/keyboards/rotr/rules.mk +++ b/keyboards/rotr/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/sam/sg81m/rules.mk b/keyboards/sam/sg81m/rules.mk index 9b9aa5d96..b7b60cb1f 100644 --- a/keyboards/sam/sg81m/rules.mk +++ b/keyboards/sam/sg81m/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = atmel-dfu | |||
7 | # Build Options | 7 | # Build Options |
8 | # change yes to no to disable | 8 | # change yes to no to disable |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/sck/neiso/rules.mk b/keyboards/sck/neiso/rules.mk index 6d27e3032..8b5cc72ff 100644 --- a/keyboards/sck/neiso/rules.mk +++ b/keyboards/sck/neiso/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = no # Audio control and System control | 19 | EXTRAKEY_ENABLE = no # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/sentraq/s60_x/keymaps/ansi_qwertz/rules.mk b/keyboards/sentraq/s60_x/keymaps/ansi_qwertz/rules.mk index 1bcd7ea7f..95d084dff 100644 --- a/keyboards/sentraq/s60_x/keymaps/ansi_qwertz/rules.mk +++ b/keyboards/sentraq/s60_x/keymaps/ansi_qwertz/rules.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # change to "no" to disable the options, or define them in the Makefile in | 2 | # change to "no" to disable the options, or define them in the Makefile in |
3 | # the appropriate keymap folder that will get included automatically | 3 | # the appropriate keymap folder that will get included automatically |
4 | # | 4 | # |
5 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 5 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
6 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | 6 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) |
7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 7 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
8 | CONSOLE_ENABLE = yes # Console for debug(+400) | 8 | CONSOLE_ENABLE = yes # Console for debug(+400) |
diff --git a/keyboards/sentraq/s65_plus/rules.mk b/keyboards/sentraq/s65_plus/rules.mk index 8424d60e4..c1fb6cfd2 100644 --- a/keyboards/sentraq/s65_plus/rules.mk +++ b/keyboards/sentraq/s65_plus/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | 20 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE |
diff --git a/keyboards/shambles/rules.mk b/keyboards/shambles/rules.mk index 890de1ffe..e6af5d3ab 100644 --- a/keyboards/shambles/rules.mk +++ b/keyboards/shambles/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/smk60/rules.mk b/keyboards/smk60/rules.mk index ce0e621c3..eee57dbba 100644 --- a/keyboards/smk60/rules.mk +++ b/keyboards/smk60/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/southpole/rules.mk b/keyboards/southpole/rules.mk index f1bf7c8fd..25a0059d9 100644 --- a/keyboards/southpole/rules.mk +++ b/keyboards/southpole/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/sowbug/68keys/rules.mk b/keyboards/sowbug/68keys/rules.mk index 414140c5e..043949124 100644 --- a/keyboards/sowbug/68keys/rules.mk +++ b/keyboards/sowbug/68keys/rules.mk | |||
@@ -12,7 +12,7 @@ DFU_SUFFIX_ARGS = -v 1eaf -p 0003 | |||
12 | # Build Options | 12 | # Build Options |
13 | # comment out to disable the options. | 13 | # comment out to disable the options. |
14 | # | 14 | # |
15 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 15 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
16 | MOUSEKEY_ENABLE = yes # Mouse keys | 16 | MOUSEKEY_ENABLE = yes # Mouse keys |
17 | EXTRAKEY_ENABLE = yes # Audio control and System control | 17 | EXTRAKEY_ENABLE = yes # Audio control and System control |
18 | CONSOLE_ENABLE = no | 18 | CONSOLE_ENABLE = no |
diff --git a/keyboards/sowbug/ansi_tkl/rules.mk b/keyboards/sowbug/ansi_tkl/rules.mk index 414140c5e..043949124 100644 --- a/keyboards/sowbug/ansi_tkl/rules.mk +++ b/keyboards/sowbug/ansi_tkl/rules.mk | |||
@@ -12,7 +12,7 @@ DFU_SUFFIX_ARGS = -v 1eaf -p 0003 | |||
12 | # Build Options | 12 | # Build Options |
13 | # comment out to disable the options. | 13 | # comment out to disable the options. |
14 | # | 14 | # |
15 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 15 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
16 | MOUSEKEY_ENABLE = yes # Mouse keys | 16 | MOUSEKEY_ENABLE = yes # Mouse keys |
17 | EXTRAKEY_ENABLE = yes # Audio control and System control | 17 | EXTRAKEY_ENABLE = yes # Audio control and System control |
18 | CONSOLE_ENABLE = no | 18 | CONSOLE_ENABLE = no |
diff --git a/keyboards/spaceman/pancake/feather/rules.mk b/keyboards/spaceman/pancake/feather/rules.mk index f9f172695..fb77e328e 100644 --- a/keyboards/spaceman/pancake/feather/rules.mk +++ b/keyboards/spaceman/pancake/feather/rules.mk | |||
@@ -18,7 +18,7 @@ BOOTLOADER = caterina | |||
18 | # comment out to disable the options. | 18 | # comment out to disable the options. |
19 | # | 19 | # |
20 | BLUETOOTH = AdafruitBLE | 20 | BLUETOOTH = AdafruitBLE |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
22 | MOUSEKEY_ENABLE = no # Mouse keys | 22 | MOUSEKEY_ENABLE = no # Mouse keys |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control |
24 | CONSOLE_ENABLE = yes # Console for debug | 24 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/spaceman/pancake/promicro/rules.mk b/keyboards/spaceman/pancake/promicro/rules.mk index 407ae090f..7287f3a0d 100644 --- a/keyboards/spaceman/pancake/promicro/rules.mk +++ b/keyboards/spaceman/pancake/promicro/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/splitish/rules.mk b/keyboards/splitish/rules.mk index 4cba00bcc..7764619a6 100644 --- a/keyboards/splitish/rules.mk +++ b/keyboards/splitish/rules.mk | |||
@@ -11,7 +11,7 @@ MCU = atmega32u4 | |||
11 | # ATmega328P USBasp | 11 | # ATmega328P USBasp |
12 | BOOTLOADER = caterina | 12 | BOOTLOADER = caterina |
13 | 13 | ||
14 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 14 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
15 | MOUSEKEY_ENABLE = yes # Mouse keys | 15 | MOUSEKEY_ENABLE = yes # Mouse keys |
16 | EXTRAKEY_ENABLE = yes # Audio control and System control | 16 | EXTRAKEY_ENABLE = yes # Audio control and System control |
17 | CONSOLE_ENABLE = no # Console for debug | 17 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/splitreus62/rules.mk b/keyboards/splitreus62/rules.mk index bc2b6a115..ce1ec3b87 100644 --- a/keyboards/splitreus62/rules.mk +++ b/keyboards/splitreus62/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/sx60/rules.mk b/keyboards/sx60/rules.mk index 3fa616a27..6443ca6a4 100755 --- a/keyboards/sx60/rules.mk +++ b/keyboards/sx60/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/technika/rules.mk b/keyboards/technika/rules.mk index 683d7f148..a548dbe9c 100644 --- a/keyboards/technika/rules.mk +++ b/keyboards/technika/rules.mk | |||
@@ -4,7 +4,7 @@ MCU = STM32F072 | |||
4 | # Build Options | 4 | # Build Options |
5 | # change yes to no to disable | 5 | # change yes to no to disable |
6 | # | 6 | # |
7 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 7 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
8 | MOUSEKEY_ENABLE = yes # Mouse keys | 8 | MOUSEKEY_ENABLE = yes # Mouse keys |
9 | EXTRAKEY_ENABLE = yes # Audio control and System control | 9 | EXTRAKEY_ENABLE = yes # Audio control and System control |
10 | CONSOLE_ENABLE = yes # Console for debug | 10 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/telophase/rules.mk b/keyboards/telophase/rules.mk index 65cac9364..614d90918 100644 --- a/keyboards/telophase/rules.mk +++ b/keyboards/telophase/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | #BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | #BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/tenki/rules.mk b/keyboards/tenki/rules.mk index 4c47d369b..e96881cc0 100644 --- a/keyboards/tenki/rules.mk +++ b/keyboards/tenki/rules.mk | |||
@@ -13,7 +13,7 @@ BOOTLOADER = caterina | |||
13 | # Build Options | 13 | # Build Options |
14 | # comment out to disable the options. | 14 | # comment out to disable the options. |
15 | # | 15 | # |
16 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 16 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
17 | MOUSEKEY_ENABLE = yes # Mouse keys | 17 | MOUSEKEY_ENABLE = yes # Mouse keys |
18 | EXTRAKEY_ENABLE = yes # Audio control and System control | 18 | EXTRAKEY_ENABLE = yes # Audio control and System control |
19 | CONSOLE_ENABLE = no # Console for debug | 19 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/terrazzo/rules.mk b/keyboards/terrazzo/rules.mk index 7a08fb769..843dbb88d 100644 --- a/keyboards/terrazzo/rules.mk +++ b/keyboards/terrazzo/rules.mk | |||
@@ -16,7 +16,7 @@ BOOTLOADER = atmel-dfu | |||
16 | # Build Options | 16 | # Build Options |
17 | # comment out to disable the options. | 17 | # comment out to disable the options. |
18 | # | 18 | # |
19 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 19 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
20 | MOUSEKEY_ENABLE = no # Mouse keys | 20 | MOUSEKEY_ENABLE = no # Mouse keys |
21 | EXTRAKEY_ENABLE = yes # Audio control and System control | 21 | EXTRAKEY_ENABLE = yes # Audio control and System control |
22 | CONSOLE_ENABLE = no # Console for debug | 22 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/terrazzo/terrazzo.c b/keyboards/terrazzo/terrazzo.c index f079ded4d..1319b05e7 100644 --- a/keyboards/terrazzo/terrazzo.c +++ b/keyboards/terrazzo/terrazzo.c | |||
@@ -17,7 +17,6 @@ | |||
17 | #include "terrazzo.h" | 17 | #include "terrazzo.h" |
18 | 18 | ||
19 | #ifdef LED_MATRIX_ENABLE | 19 | #ifdef LED_MATRIX_ENABLE |
20 | #include "is31fl3731-simple.h" | ||
21 | #include <math.h> | 20 | #include <math.h> |
22 | #include "print.h" | 21 | #include "print.h" |
23 | #include "quantum.h" | 22 | #include "quantum.h" |
@@ -59,7 +58,7 @@ uint8_t terrazzo_effect = 1; | |||
59 | void terrazzo_set_pixel(uint8_t x, uint8_t y, uint8_t value) { | 58 | void terrazzo_set_pixel(uint8_t x, uint8_t y, uint8_t value) { |
60 | uint8_t target = y * LED_MATRIX_COLS + x; | 59 | uint8_t target = y * LED_MATRIX_COLS + x; |
61 | if (target < DRIVER_LED_TOTAL && target >= 0) { | 60 | if (target < DRIVER_LED_TOTAL && target >= 0) { |
62 | led_matrix_set_index_value(y * LED_MATRIX_COLS + x, value); | 61 | led_matrix_set_value(y * LED_MATRIX_COLS + x, value); |
63 | } | 62 | } |
64 | } | 63 | } |
65 | 64 | ||
@@ -113,7 +112,7 @@ void terrazzo_mode_off(void) { | |||
113 | void terrazzo_render(void) { | 112 | void terrazzo_render(void) { |
114 | switch(terrazzo_effect) { | 113 | switch(terrazzo_effect) { |
115 | case TERRAZZO_NONE: | 114 | case TERRAZZO_NONE: |
116 | led_matrix_set_index_value_all(0); | 115 | led_matrix_set_value_all(0); |
117 | break; | 116 | break; |
118 | #define TERRAZZO_EFFECT(name, ...) \ | 117 | #define TERRAZZO_EFFECT(name, ...) \ |
119 | case TERRAZZO_EFFECT_##name: \ | 118 | case TERRAZZO_EFFECT_##name: \ |
diff --git a/keyboards/terrazzo/terrazzo_effects/dino.h b/keyboards/terrazzo/terrazzo_effects/dino.h index 747ef6178..18c629f41 100644 --- a/keyboards/terrazzo/terrazzo_effects/dino.h +++ b/keyboards/terrazzo/terrazzo_effects/dino.h | |||
@@ -148,7 +148,7 @@ static uint8_t dino_bg[10][42] = { | |||
148 | }; | 148 | }; |
149 | 149 | ||
150 | void DINO(uint8_t i, bool dir) { | 150 | void DINO(uint8_t i, bool dir) { |
151 | led_matrix_set_index_value_all(0); | 151 | led_matrix_set_value_all(0); |
152 | if (dir) { | 152 | if (dir) { |
153 | terrazzo_draw_at(0, 7, 7, 8, dino_frames[i % 2]); | 153 | terrazzo_draw_at(0, 7, 7, 8, dino_frames[i % 2]); |
154 | } else { | 154 | } else { |
diff --git a/keyboards/terrazzo/terrazzo_effects/dot.h b/keyboards/terrazzo/terrazzo_effects/dot.h index e8eb8e0fc..07c4621c2 100644 --- a/keyboards/terrazzo/terrazzo_effects/dot.h +++ b/keyboards/terrazzo/terrazzo_effects/dot.h | |||
@@ -19,8 +19,8 @@ TERRAZZO_EFFECT(DOT) | |||
19 | # ifdef TERRAZZO_EFFECT_IMPLS | 19 | # ifdef TERRAZZO_EFFECT_IMPLS |
20 | // Animation for debugging. Lights one pixel according to animation index | 20 | // Animation for debugging. Lights one pixel according to animation index |
21 | void DOT(uint8_t i, bool dir) { | 21 | void DOT(uint8_t i, bool dir) { |
22 | led_matrix_set_index_value_all(0); | 22 | led_matrix_set_value_all(0); |
23 | led_matrix_set_index_value(i, 10); | 23 | led_matrix_set_value(i, 10); |
24 | } | 24 | } |
25 | 25 | ||
26 | # endif | 26 | # endif |
diff --git a/keyboards/terrazzo/terrazzo_effects/heart.h b/keyboards/terrazzo/terrazzo_effects/heart.h index bdcd2d7b9..bfbd6acc3 100644 --- a/keyboards/terrazzo/terrazzo_effects/heart.h +++ b/keyboards/terrazzo/terrazzo_effects/heart.h | |||
@@ -91,7 +91,7 @@ static uint8_t heart_frames[4][105] = { | |||
91 | 91 | ||
92 | 92 | ||
93 | void HEART(uint8_t i, bool dir) { | 93 | void HEART(uint8_t i, bool dir) { |
94 | led_matrix_set_index_value_all(0); | 94 | led_matrix_set_value_all(0); |
95 | terrazzo_draw_at(0, 0, 7, 15, heart_frames[i % 4]); | 95 | terrazzo_draw_at(0, 0, 7, 15, heart_frames[i % 4]); |
96 | } | 96 | } |
97 | 97 | ||
diff --git a/keyboards/terrazzo/terrazzo_effects/outrun.h b/keyboards/terrazzo/terrazzo_effects/outrun.h index b4455ef49..127e714b2 100644 --- a/keyboards/terrazzo/terrazzo_effects/outrun.h +++ b/keyboards/terrazzo/terrazzo_effects/outrun.h | |||
@@ -89,7 +89,7 @@ bool last_dir; | |||
89 | uint8_t change_index = 0; | 89 | uint8_t change_index = 0; |
90 | 90 | ||
91 | void OUTRUN(uint8_t i, bool dir) { | 91 | void OUTRUN(uint8_t i, bool dir) { |
92 | led_matrix_set_index_value_all(0); | 92 | led_matrix_set_value_all(0); |
93 | 93 | ||
94 | if(dir != last_dir) { | 94 | if(dir != last_dir) { |
95 | change_index = i; | 95 | change_index = i; |
diff --git a/keyboards/terrazzo/terrazzo_effects/pac_dude.h b/keyboards/terrazzo/terrazzo_effects/pac_dude.h index aa4fc9923..aaf0c5545 100644 --- a/keyboards/terrazzo/terrazzo_effects/pac_dude.h +++ b/keyboards/terrazzo/terrazzo_effects/pac_dude.h | |||
@@ -51,7 +51,7 @@ static uint8_t pac_ghost[20] = { | |||
51 | 51 | ||
52 | 52 | ||
53 | void PAC_DUDE(uint8_t i, bool dir) { | 53 | void PAC_DUDE(uint8_t i, bool dir) { |
54 | led_matrix_set_index_value_all(0); | 54 | led_matrix_set_value_all(0); |
55 | if (dir) { | 55 | if (dir) { |
56 | terrazzo_draw_at(1, 4, 5, 5, pac_frames[i % 2]); | 56 | terrazzo_draw_at(1, 4, 5, 5, pac_frames[i % 2]); |
57 | terrazzo_set_pixel(3, 0 + i % 3, 5); | 57 | terrazzo_set_pixel(3, 0 + i % 3, 5); |
diff --git a/keyboards/terrazzo/terrazzo_effects/wpm_chart.h b/keyboards/terrazzo/terrazzo_effects/wpm_chart.h index 5c66bc39a..b80b604d2 100644 --- a/keyboards/terrazzo/terrazzo_effects/wpm_chart.h +++ b/keyboards/terrazzo/terrazzo_effects/wpm_chart.h | |||
@@ -85,14 +85,14 @@ static uint8_t number_3_4[10][12] = { | |||
85 | uint8_t wpm_levels[10] = {20, 9, 8, 7, 6, 5, 4, 3, 2, 1}; | 85 | uint8_t wpm_levels[10] = {20, 9, 8, 7, 6, 5, 4, 3, 2, 1}; |
86 | 86 | ||
87 | void WPM_CHART(uint8_t i, bool dir) { | 87 | void WPM_CHART(uint8_t i, bool dir) { |
88 | led_matrix_set_index_value_all(0); | 88 | led_matrix_set_value_all(0); |
89 | uint8_t c_wpm = get_current_wpm(); | 89 | uint8_t c_wpm = get_current_wpm(); |
90 | uint8_t half_wpm = floor(c_wpm / 2); | 90 | uint8_t half_wpm = floor(c_wpm / 2); |
91 | uint8_t max_rows = 10; | 91 | uint8_t max_rows = 10; |
92 | /* Turn on LED for current WPM. Each pixel is 2 wpm. */ | 92 | /* Turn on LED for current WPM. Each pixel is 2 wpm. */ |
93 | for (int k = 0; k < half_wpm && k < 70; k++) { | 93 | for (int k = 0; k < half_wpm && k < 70; k++) { |
94 | uint8_t current_row = (int)floor(k / 7); | 94 | uint8_t current_row = (int)floor(k / 7); |
95 | led_matrix_set_index_value(k, wpm_levels[max_rows - current_row]); | 95 | led_matrix_set_value(k, wpm_levels[max_rows - current_row]); |
96 | }; | 96 | }; |
97 | uint8_t d1 = (int)floor(c_wpm / 10); | 97 | uint8_t d1 = (int)floor(c_wpm / 10); |
98 | /* There is only room to print 2 digits. If the WPM is greater than | 98 | /* There is only room to print 2 digits. If the WPM is greater than |
diff --git a/keyboards/thevankeyboards/minivan/rules.mk b/keyboards/thevankeyboards/minivan/rules.mk index d9a34f38b..4e1320815 100644 --- a/keyboards/thevankeyboards/minivan/rules.mk +++ b/keyboards/thevankeyboards/minivan/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/thevankeyboards/roadkit/rules.mk b/keyboards/thevankeyboards/roadkit/rules.mk index e8ab28cb5..760337e18 100644 --- a/keyboards/thevankeyboards/roadkit/rules.mk +++ b/keyboards/thevankeyboards/roadkit/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/ua62/rules.mk b/keyboards/ua62/rules.mk index 78fed4633..b28e458b7 100644 --- a/keyboards/ua62/rules.mk +++ b/keyboards/ua62/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/ut472/rules.mk b/keyboards/ut472/rules.mk index caf4c1c87..a100637b4 100644 --- a/keyboards/ut472/rules.mk +++ b/keyboards/ut472/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/vinta/rules.mk b/keyboards/vinta/rules.mk index 736509689..d35a64197 100644 --- a/keyboards/vinta/rules.mk +++ b/keyboards/vinta/rules.mk | |||
@@ -5,7 +5,7 @@ MCU = STM32F042 | |||
5 | # comment out to disable the options. | 5 | # comment out to disable the options. |
6 | # | 6 | # |
7 | BACKLIGHT_ENABLE = no | 7 | BACKLIGHT_ENABLE = no |
8 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 8 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
9 | MOUSEKEY_ENABLE = yes # Mouse keys | 9 | MOUSEKEY_ENABLE = yes # Mouse keys |
10 | EXTRAKEY_ENABLE = yes # Audio control and System control | 10 | EXTRAKEY_ENABLE = yes # Audio control and System control |
11 | CONSOLE_ENABLE = no # Console for debug | 11 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/vision_division/rules.mk b/keyboards/vision_division/rules.mk index 789ff97c7..b92464285 100644 --- a/keyboards/vision_division/rules.mk +++ b/keyboards/vision_division/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/walletburner/cajal/rules.mk b/keyboards/walletburner/cajal/rules.mk index 0bb221f12..173b00fee 100644 --- a/keyboards/walletburner/cajal/rules.mk +++ b/keyboards/walletburner/cajal/rules.mk | |||
@@ -7,7 +7,7 @@ BOOTLOADER = atmel-dfu | |||
7 | # Build Options | 7 | # Build Options |
8 | # comment out to disable the options. | 8 | # comment out to disable the options. |
9 | # | 9 | # |
10 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 10 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
11 | MOUSEKEY_ENABLE = yes # Mouse keys | 11 | MOUSEKEY_ENABLE = yes # Mouse keys |
12 | EXTRAKEY_ENABLE = yes # Audio control and System control | 12 | EXTRAKEY_ENABLE = yes # Audio control and System control |
13 | CONSOLE_ENABLE = no # Console for debug | 13 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/westfoxtrot/prophet/config.h b/keyboards/westfoxtrot/prophet/config.h index 4f447e4ca..0f2ddc1dc 100644 --- a/keyboards/westfoxtrot/prophet/config.h +++ b/keyboards/westfoxtrot/prophet/config.h | |||
@@ -30,3 +30,5 @@ | |||
30 | #define LOCKING_SUPPORT_ENABLE | 30 | #define LOCKING_SUPPORT_ENABLE |
31 | /* Locking resynchronize hack */ | 31 | /* Locking resynchronize hack */ |
32 | #define LOCKING_RESYNC_ENABLE | 32 | #define LOCKING_RESYNC_ENABLE |
33 | |||
34 | #define SLEEP_LED_GPT_DRIVER GPTD1 | ||
diff --git a/keyboards/westfoxtrot/prophet/halconf.h b/keyboards/westfoxtrot/prophet/halconf.h new file mode 100644 index 000000000..cbfd1307f --- /dev/null +++ b/keyboards/westfoxtrot/prophet/halconf.h | |||
@@ -0,0 +1,27 @@ | |||
1 | /* Copyright 2020 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | /* | ||
18 | * This file was auto-generated by: | ||
19 | * `qmk chibios-confmigrate -i keyboards/projectkb/alice/halconf.h -r platforms/chibios/common/configs/halconf.h` | ||
20 | */ | ||
21 | |||
22 | #pragma once | ||
23 | |||
24 | #define HAL_USE_GPT TRUE | ||
25 | |||
26 | #include_next <halconf.h> | ||
27 | |||
diff --git a/keyboards/westfoxtrot/prophet/mcuconf.h b/keyboards/westfoxtrot/prophet/mcuconf.h index 2665f9c9e..550141af6 100644 --- a/keyboards/westfoxtrot/prophet/mcuconf.h +++ b/keyboards/westfoxtrot/prophet/mcuconf.h | |||
@@ -23,6 +23,5 @@ | |||
23 | 23 | ||
24 | #include_next <mcuconf.h> | 24 | #include_next <mcuconf.h> |
25 | 25 | ||
26 | #undef STM32_PWM_USE_TIM3 | 26 | #undef STM32_GPT_USE_TIM1 |
27 | #define STM32_PWM_USE_TIM3 TRUE | 27 | #define STM32_GPT_USE_TIM1 TRUE |
28 | |||
diff --git a/keyboards/whitefox/rules.mk b/keyboards/whitefox/rules.mk index 429795c23..771804369 100644 --- a/keyboards/whitefox/rules.mk +++ b/keyboards/whitefox/rules.mk | |||
@@ -16,7 +16,7 @@ BOARD = IC_TEENSY_3_1 | |||
16 | # Build Options | 16 | # Build Options |
17 | # change yes to no to disable | 17 | # change yes to no to disable |
18 | # | 18 | # |
19 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 19 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
20 | MOUSEKEY_ENABLE = yes # Mouse keys | 20 | MOUSEKEY_ENABLE = yes # Mouse keys |
21 | EXTRAKEY_ENABLE = yes # Audio control and System control | 21 | EXTRAKEY_ENABLE = yes # Audio control and System control |
22 | CONSOLE_ENABLE = no # Console for debug | 22 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/winkeyless/bminiex/rules.mk b/keyboards/winkeyless/bminiex/rules.mk index f44b7fe85..fa7336cd8 100644 --- a/keyboards/winkeyless/bminiex/rules.mk +++ b/keyboards/winkeyless/bminiex/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32a | |||
12 | BOOTLOADER = bootloadHID | 12 | BOOTLOADER = bootloadHID |
13 | 13 | ||
14 | # build options | 14 | # build options |
15 | BOOTMAGIC_ENABLE = yes | 15 | BOOTMAGIC_ENABLE = full |
16 | MOUSEKEY_ENABLE = yes | 16 | MOUSEKEY_ENABLE = yes |
17 | EXTRAKEY_ENABLE = yes | 17 | EXTRAKEY_ENABLE = yes |
18 | CONSOLE_ENABLE = no | 18 | CONSOLE_ENABLE = no |
diff --git a/keyboards/wsk/houndstooth/rules.mk b/keyboards/wsk/houndstooth/rules.mk index c93932238..b1bdf25e3 100644 --- a/keyboards/wsk/houndstooth/rules.mk +++ b/keyboards/wsk/houndstooth/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/wsk/kodachi50/rules.mk b/keyboards/wsk/kodachi50/rules.mk index 0f9fe8d42..9de501227 100644 --- a/keyboards/wsk/kodachi50/rules.mk +++ b/keyboards/wsk/kodachi50/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/wsk/pain27/rules.mk b/keyboards/wsk/pain27/rules.mk index 8b5c7c51b..e939ba823 100644 --- a/keyboards/wsk/pain27/rules.mk +++ b/keyboards/wsk/pain27/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 18 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
20 | CONSOLE_ENABLE = no # Console for debug(+400) | 20 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/wsk/sl40/rules.mk b/keyboards/wsk/sl40/rules.mk index 0f9fe8d42..9de501227 100644 --- a/keyboards/wsk/sl40/rules.mk +++ b/keyboards/wsk/sl40/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = caterina | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/xd60/readme.md b/keyboards/xd60/readme.md index 428041482..f4926d01a 100644 --- a/keyboards/xd60/readme.md +++ b/keyboards/xd60/readme.md | |||
@@ -7,6 +7,7 @@ Compact 60% with arrows. | |||
7 | * Keyboard Maintainer: QMK Community | 7 | * Keyboard Maintainer: QMK Community |
8 | * Hardware Supported: XD60 PCB rev2 & rev3 | 8 | * Hardware Supported: XD60 PCB rev2 & rev3 |
9 | * Hardware Availability: [Drop.com](https://www.drop.com/buy/xd60-xd64-custom-mechanical-keyboard-kit?mode=guest_open), [KPRepublic on AliExpress](https://www.aliexpress.com/item/32814945677.html) | 9 | * Hardware Availability: [Drop.com](https://www.drop.com/buy/xd60-xd64-custom-mechanical-keyboard-kit?mode=guest_open), [KPRepublic on AliExpress](https://www.aliexpress.com/item/32814945677.html) |
10 | * Schematic Availability: Public Domain [on EasyEDA](https://easyeda.com/langzisanshao/xd60) | ||
10 | 11 | ||
11 | Make example for this keyboard (after setting up your build environment): | 12 | Make example for this keyboard (after setting up your build environment): |
12 | 13 | ||
diff --git a/keyboards/xd60/rev2/rules.mk b/keyboards/xd60/rev2/rules.mk index 56a01b3c5..a06ac2e2c 100644 --- a/keyboards/xd60/rev2/rules.mk +++ b/keyboards/xd60/rev2/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32u4 | |||
12 | BOOTLOADER = atmel-dfu | 12 | BOOTLOADER = atmel-dfu |
13 | 13 | ||
14 | # Build Options | 14 | # Build Options |
15 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 15 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
16 | MOUSEKEY_ENABLE = yes # Mouse keys | 16 | MOUSEKEY_ENABLE = yes # Mouse keys |
17 | EXTRAKEY_ENABLE = yes # Audio control and System control | 17 | EXTRAKEY_ENABLE = yes # Audio control and System control |
18 | CONSOLE_ENABLE = no # Console for debug | 18 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/xd60/rev3/rules.mk b/keyboards/xd60/rev3/rules.mk index 56a01b3c5..a06ac2e2c 100644 --- a/keyboards/xd60/rev3/rules.mk +++ b/keyboards/xd60/rev3/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32u4 | |||
12 | BOOTLOADER = atmel-dfu | 12 | BOOTLOADER = atmel-dfu |
13 | 13 | ||
14 | # Build Options | 14 | # Build Options |
15 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 15 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
16 | MOUSEKEY_ENABLE = yes # Mouse keys | 16 | MOUSEKEY_ENABLE = yes # Mouse keys |
17 | EXTRAKEY_ENABLE = yes # Audio control and System control | 17 | EXTRAKEY_ENABLE = yes # Audio control and System control |
18 | CONSOLE_ENABLE = no # Console for debug | 18 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/xd75/keymaps/4sstylz/rules.mk b/keyboards/xd75/keymaps/4sstylz/rules.mk index ffb70f0a9..0a9e12512 100644 --- a/keyboards/xd75/keymaps/4sstylz/rules.mk +++ b/keyboards/xd75/keymaps/4sstylz/rules.mk | |||
@@ -17,7 +17,7 @@ COMBO_ENABLE = yes # Enable combo for special function when using multiple k | |||
17 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality | 17 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality |
18 | RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight. | 18 | RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight. |
19 | 19 | ||
20 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 20 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
21 | MOUSEKEY_ENABLE = no # Mouse keys | 21 | MOUSEKEY_ENABLE = no # Mouse keys |
22 | EXTRAKEY_ENABLE = yes # Audio control and System control | 22 | EXTRAKEY_ENABLE = yes # Audio control and System control |
23 | CONSOLE_ENABLE = no # Console for debug | 23 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/xd75/keymaps/fabian/rules.mk b/keyboards/xd75/keymaps/fabian/rules.mk index 8831f2d62..39b003dee 100644 --- a/keyboards/xd75/keymaps/fabian/rules.mk +++ b/keyboards/xd75/keymaps/fabian/rules.mk | |||
@@ -18,7 +18,7 @@ | |||
18 | # change to "no" to disable the options, or define them in the Makefile in | 18 | # change to "no" to disable the options, or define them in the Makefile in |
19 | # the appropriate keymap folder that will get included automatically | 19 | # the appropriate keymap folder that will get included automatically |
20 | # | 20 | # |
21 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000) | 21 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration(+1000) |
22 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | 22 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) |
23 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | 23 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) |
24 | CONSOLE_ENABLE = no # Console for debug(+400) | 24 | CONSOLE_ENABLE = no # Console for debug(+400) |
diff --git a/keyboards/xd75/keymaps/revok75/rules.mk b/keyboards/xd75/keymaps/revok75/rules.mk index 7472e8c64..21ba8f74b 100644 --- a/keyboards/xd75/keymaps/revok75/rules.mk +++ b/keyboards/xd75/keymaps/revok75/rules.mk | |||
@@ -13,6 +13,6 @@ | |||
13 | # You should have received a copy of the GNU General Public License | 13 | # You should have received a copy of the GNU General Public License |
14 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | 14 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
15 | 15 | ||
16 | BOOTMAGIC_ENABLE = yes | 16 | BOOTMAGIC_ENABLE = full |
17 | BACKLIGHT_ENABLE = yes | 17 | BACKLIGHT_ENABLE = yes |
18 | RGBLIGHT_ENABLE = yes | 18 | RGBLIGHT_ENABLE = yes |
diff --git a/keyboards/xd87/rules.mk b/keyboards/xd87/rules.mk index abd7a41bb..6d5d8b6da 100644 --- a/keyboards/xd87/rules.mk +++ b/keyboards/xd87/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = yes # Console for debug | 20 | CONSOLE_ENABLE = yes # Console for debug |
diff --git a/keyboards/ymd75/rev1/rules.mk b/keyboards/ymd75/rev1/rules.mk index b77457b5a..2499c1c5e 100644 --- a/keyboards/ymd75/rev1/rules.mk +++ b/keyboards/ymd75/rev1/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32a | |||
12 | BOOTLOADER = bootloadHID | 12 | BOOTLOADER = bootloadHID |
13 | 13 | ||
14 | # build options | 14 | # build options |
15 | BOOTMAGIC_ENABLE = yes | 15 | BOOTMAGIC_ENABLE = full |
16 | MOUSEKEY_ENABLE = no | 16 | MOUSEKEY_ENABLE = no |
17 | EXTRAKEY_ENABLE = yes | 17 | EXTRAKEY_ENABLE = yes |
18 | CONSOLE_ENABLE = no | 18 | CONSOLE_ENABLE = no |
diff --git a/keyboards/ymd75/rev2/rules.mk b/keyboards/ymd75/rev2/rules.mk index b77457b5a..2499c1c5e 100644 --- a/keyboards/ymd75/rev2/rules.mk +++ b/keyboards/ymd75/rev2/rules.mk | |||
@@ -12,7 +12,7 @@ MCU = atmega32a | |||
12 | BOOTLOADER = bootloadHID | 12 | BOOTLOADER = bootloadHID |
13 | 13 | ||
14 | # build options | 14 | # build options |
15 | BOOTMAGIC_ENABLE = yes | 15 | BOOTMAGIC_ENABLE = full |
16 | MOUSEKEY_ENABLE = no | 16 | MOUSEKEY_ENABLE = no |
17 | EXTRAKEY_ENABLE = yes | 17 | EXTRAKEY_ENABLE = yes |
18 | CONSOLE_ENABLE = no | 18 | CONSOLE_ENABLE = no |
diff --git a/keyboards/ymdk/sp64/rules.mk b/keyboards/ymdk/sp64/rules.mk index 91dc8ab74..8db57de3b 100644 --- a/keyboards/ymdk/sp64/rules.mk +++ b/keyboards/ymdk/sp64/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = bootloadHID | |||
14 | # Build Options | 14 | # Build Options |
15 | # change yes to no to disable | 15 | # change yes to no to disable |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/ymdk/ymd67/rules.mk b/keyboards/ymdk/ymd67/rules.mk index 891c7739a..2ffe8fcab 100644 --- a/keyboards/ymdk/ymd67/rules.mk +++ b/keyboards/ymdk/ymd67/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = no # Mouse keys | 18 | MOUSEKEY_ENABLE = no # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/z150_bh/rules.mk b/keyboards/z150_bh/rules.mk index 739bea393..1843f1ba6 100644 --- a/keyboards/z150_bh/rules.mk +++ b/keyboards/z150_bh/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = halfkay | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/keyboards/zlant/rules.mk b/keyboards/zlant/rules.mk index 5daad3db2..03d57e23f 100755 --- a/keyboards/zlant/rules.mk +++ b/keyboards/zlant/rules.mk | |||
@@ -14,7 +14,7 @@ BOOTLOADER = atmel-dfu | |||
14 | # Build Options | 14 | # Build Options |
15 | # comment out to disable the options. | 15 | # comment out to disable the options. |
16 | # | 16 | # |
17 | BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration | 17 | BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration |
18 | MOUSEKEY_ENABLE = yes # Mouse keys | 18 | MOUSEKEY_ENABLE = yes # Mouse keys |
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | 19 | EXTRAKEY_ENABLE = yes # Audio control and System control |
20 | CONSOLE_ENABLE = no # Console for debug | 20 | CONSOLE_ENABLE = no # Console for debug |
diff --git a/layouts/community/ergodox/bocaj/rules.mk b/layouts/community/ergodox/bocaj/rules.mk index 88eaf39f8..c6a306fda 100644 --- a/layouts/community/ergodox/bocaj/rules.mk +++ b/layouts/community/ergodox/bocaj/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | BOOTMAGIC_ENABLE = yes | 1 | BOOTMAGIC_ENABLE = full |
2 | TAP_DANCE_ENABLE = no | 2 | TAP_DANCE_ENABLE = no |
3 | COMMAND_ENABLE = no # Commands for debug and configuration | 3 | COMMAND_ENABLE = no # Commands for debug and configuration |
4 | CONSOLE_ENABLE = yes | 4 | CONSOLE_ENABLE = yes |
diff --git a/lib/python/qmk/commands.py b/lib/python/qmk/commands.py index d742f6756..510abffdc 100644 --- a/lib/python/qmk/commands.py +++ b/lib/python/qmk/commands.py | |||
@@ -181,6 +181,7 @@ def compile_configurator_json(user_keymap, bootloader=None, parallel=1, **env_va | |||
181 | f'VERBOSE={verbose}', | 181 | f'VERBOSE={verbose}', |
182 | f'COLOR={color}', | 182 | f'COLOR={color}', |
183 | 'SILENT=false', | 183 | 'SILENT=false', |
184 | f'QMK_BIN={"bin/qmk" if "DEPRECATED_BIN_QMK" in os.environ else "qmk"}', | ||
184 | ]) | 185 | ]) |
185 | 186 | ||
186 | return make_command | 187 | return make_command |
diff --git a/lib/python/qmk/constants.py b/lib/python/qmk/constants.py index 3ed69f3bf..33adb0a13 100644 --- a/lib/python/qmk/constants.py +++ b/lib/python/qmk/constants.py | |||
@@ -10,7 +10,7 @@ QMK_FIRMWARE = Path.cwd() | |||
10 | MAX_KEYBOARD_SUBFOLDERS = 5 | 10 | MAX_KEYBOARD_SUBFOLDERS = 5 |
11 | 11 | ||
12 | # Supported processor types | 12 | # Supported processor types |
13 | CHIBIOS_PROCESSORS = 'cortex-m0', 'cortex-m0plus', 'cortex-m3', 'cortex-m4', 'MKL26Z64', 'MK20DX128', 'MK20DX256', 'STM32F042', 'STM32F072', 'STM32F103', 'STM32F303', 'STM32F401', 'STM32F411', 'STM32G431', 'STM32G474' | 13 | CHIBIOS_PROCESSORS = 'cortex-m0', 'cortex-m0plus', 'cortex-m3', 'cortex-m4', 'MKL26Z64', 'MK20DX128', 'MK20DX256', 'MK66F18', 'STM32F042', 'STM32F072', 'STM32F103', 'STM32F303', 'STM32F401', 'STM32F411', 'STM32F446', 'STM32G431', 'STM32G474' |
14 | LUFA_PROCESSORS = 'at90usb162', 'atmega16u2', 'atmega32u2', 'atmega16u4', 'atmega32u4', 'at90usb646', 'at90usb647', 'at90usb1286', 'at90usb1287', None | 14 | LUFA_PROCESSORS = 'at90usb162', 'atmega16u2', 'atmega32u2', 'atmega16u4', 'atmega32u4', 'at90usb646', 'at90usb647', 'at90usb1286', 'at90usb1287', None |
15 | VUSB_PROCESSORS = 'atmega32a', 'atmega328p', 'atmega328', 'attiny85' | 15 | VUSB_PROCESSORS = 'atmega32a', 'atmega328p', 'atmega328', 'attiny85' |
16 | 16 | ||
diff --git a/lib/python/qmk/tests/test_cli_commands.py b/lib/python/qmk/tests/test_cli_commands.py index c57d2b7fc..0a87f60e0 100644 --- a/lib/python/qmk/tests/test_cli_commands.py +++ b/lib/python/qmk/tests/test_cli_commands.py | |||
@@ -8,7 +8,7 @@ is_windows = 'windows' in platform.platform().lower() | |||
8 | 8 | ||
9 | 9 | ||
10 | def check_subcommand(command, *args): | 10 | def check_subcommand(command, *args): |
11 | cmd = ['bin/qmk', command, *args] | 11 | cmd = ['qmk', command, *args] |
12 | result = run(cmd, stdout=PIPE, stderr=STDOUT, universal_newlines=True) | 12 | result = run(cmd, stdout=PIPE, stderr=STDOUT, universal_newlines=True) |
13 | return result | 13 | return result |
14 | 14 | ||
@@ -17,7 +17,7 @@ def check_subcommand_stdin(file_to_read, command, *args): | |||
17 | """Pipe content of a file to a command and return output. | 17 | """Pipe content of a file to a command and return output. |
18 | """ | 18 | """ |
19 | with open(file_to_read, encoding='utf-8') as my_file: | 19 | with open(file_to_read, encoding='utf-8') as my_file: |
20 | cmd = ['bin/qmk', command, *args] | 20 | cmd = ['qmk', command, *args] |
21 | result = run(cmd, stdin=my_file, stdout=PIPE, stderr=STDOUT, universal_newlines=True) | 21 | result = run(cmd, stdin=my_file, stdout=PIPE, stderr=STDOUT, universal_newlines=True) |
22 | return result | 22 | return result |
23 | 23 | ||
diff --git a/message.mk b/message.mk index 3240c041b..c3f391919 100644 --- a/message.mk +++ b/message.mk | |||
@@ -47,10 +47,12 @@ MSG_SIZE_AFTER = Size after: | |||
47 | MSG_COFF = Converting to AVR COFF: | 47 | MSG_COFF = Converting to AVR COFF: |
48 | MSG_EXTENDED_COFF = Converting to AVR Extended COFF: | 48 | MSG_EXTENDED_COFF = Converting to AVR Extended COFF: |
49 | MSG_FLASH = Creating load file for flashing: | 49 | MSG_FLASH = Creating load file for flashing: |
50 | MSG_UF2 = Creating UF2 file for deployment: | ||
50 | MSG_EEPROM = Creating load file for EEPROM: | 51 | MSG_EEPROM = Creating load file for EEPROM: |
51 | MSG_BIN = Creating binary load file for flashing: | 52 | MSG_BIN = Creating binary load file for flashing: |
52 | MSG_EXTENDED_LISTING = Creating Extended Listing: | 53 | MSG_EXTENDED_LISTING = Creating Extended Listing: |
53 | MSG_SYMBOL_TABLE = Creating Symbol Table: | 54 | MSG_SYMBOL_TABLE = Creating Symbol Table: |
55 | MSG_EXECUTING = Executing: | ||
54 | MSG_LINKING = Linking: | 56 | MSG_LINKING = Linking: |
55 | MSG_COMPILING = Compiling: | 57 | MSG_COMPILING = Compiling: |
56 | MSG_COMPILING_CXX = Compiling: | 58 | MSG_COMPILING_CXX = Compiling: |
diff --git a/platforms/chibios/BLACKPILL_STM32_F411/ld/STM32F411xC_tinyuf2.ld b/platforms/chibios/BLACKPILL_STM32_F411/ld/STM32F411xC_tinyuf2.ld new file mode 100644 index 000000000..82253d3de --- /dev/null +++ b/platforms/chibios/BLACKPILL_STM32_F411/ld/STM32F411xC_tinyuf2.ld | |||
@@ -0,0 +1,89 @@ | |||
1 | /* | ||
2 | ChibiOS - Copyright (C) 2006..2018 Giovanni Di Sirio | ||
3 | |||
4 | Licensed under the Apache License, Version 2.0 (the "License"); | ||
5 | you may not use this file except in compliance with the License. | ||
6 | You may obtain a copy of the License at | ||
7 | |||
8 | http://www.apache.org/licenses/LICENSE-2.0 | ||
9 | |||
10 | Unless required by applicable law or agreed to in writing, software | ||
11 | distributed under the License is distributed on an "AS IS" BASIS, | ||
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
13 | See the License for the specific language governing permissions and | ||
14 | limitations under the License. | ||
15 | */ | ||
16 | |||
17 | /* | ||
18 | * STM32F411xC memory setup. | ||
19 | */ | ||
20 | MEMORY | ||
21 | { | ||
22 | flash0 (rx) : org = 0x08000000 + 64k, len = 256k - 64k /* tinyuf2 bootloader requires app to be located at 64k offset for this MCU */ | ||
23 | flash1 (rx) : org = 0x00000000, len = 0 | ||
24 | flash2 (rx) : org = 0x00000000, len = 0 | ||
25 | flash3 (rx) : org = 0x00000000, len = 0 | ||
26 | flash4 (rx) : org = 0x00000000, len = 0 | ||
27 | flash5 (rx) : org = 0x00000000, len = 0 | ||
28 | flash6 (rx) : org = 0x00000000, len = 0 | ||
29 | flash7 (rx) : org = 0x00000000, len = 0 | ||
30 | ram0 (wx) : org = 0x20000000, len = 128k | ||
31 | ram1 (wx) : org = 0x00000000, len = 0 | ||
32 | ram2 (wx) : org = 0x00000000, len = 0 | ||
33 | ram3 (wx) : org = 0x00000000, len = 0 | ||
34 | ram4 (wx) : org = 0x00000000, len = 0 | ||
35 | ram5 (wx) : org = 0x00000000, len = 0 | ||
36 | ram6 (wx) : org = 0x00000000, len = 0 | ||
37 | ram7 (wx) : org = 0x00000000, len = 0 | ||
38 | } | ||
39 | |||
40 | /* For each data/text section two region are defined, a virtual region | ||
41 | and a load region (_LMA suffix).*/ | ||
42 | |||
43 | /* Flash region to be used for exception vectors.*/ | ||
44 | REGION_ALIAS("VECTORS_FLASH", flash0); | ||
45 | REGION_ALIAS("VECTORS_FLASH_LMA", flash0); | ||
46 | |||
47 | /* Flash region to be used for constructors and destructors.*/ | ||
48 | REGION_ALIAS("XTORS_FLASH", flash0); | ||
49 | REGION_ALIAS("XTORS_FLASH_LMA", flash0); | ||
50 | |||
51 | /* Flash region to be used for code text.*/ | ||
52 | REGION_ALIAS("TEXT_FLASH", flash0); | ||
53 | REGION_ALIAS("TEXT_FLASH_LMA", flash0); | ||
54 | |||
55 | /* Flash region to be used for read only data.*/ | ||
56 | REGION_ALIAS("RODATA_FLASH", flash0); | ||
57 | REGION_ALIAS("RODATA_FLASH_LMA", flash0); | ||
58 | |||
59 | /* Flash region to be used for various.*/ | ||
60 | REGION_ALIAS("VARIOUS_FLASH", flash0); | ||
61 | REGION_ALIAS("VARIOUS_FLASH_LMA", flash0); | ||
62 | |||
63 | /* Flash region to be used for RAM(n) initialization data.*/ | ||
64 | REGION_ALIAS("RAM_INIT_FLASH_LMA", flash0); | ||
65 | |||
66 | /* RAM region to be used for Main stack. This stack accommodates the processing | ||
67 | of all exceptions and interrupts.*/ | ||
68 | REGION_ALIAS("MAIN_STACK_RAM", ram0); | ||
69 | |||
70 | /* RAM region to be used for the process stack. This is the stack used by | ||
71 | the main() function.*/ | ||
72 | REGION_ALIAS("PROCESS_STACK_RAM", ram0); | ||
73 | |||
74 | /* RAM region to be used for data segment.*/ | ||
75 | REGION_ALIAS("DATA_RAM", ram0); | ||
76 | REGION_ALIAS("DATA_RAM_LMA", flash0); | ||
77 | |||
78 | /* RAM region to be used for BSS segment.*/ | ||
79 | REGION_ALIAS("BSS_RAM", ram0); | ||
80 | |||
81 | /* RAM region to be used for the default heap.*/ | ||
82 | REGION_ALIAS("HEAP_RAM", ram0); | ||
83 | |||
84 | /* Generic rules inclusion.*/ | ||
85 | INCLUDE rules.ld | ||
86 | |||
87 | /* TinyUF2 bootloader reset support */ | ||
88 | _board_dfu_dbl_tap = ORIGIN(ram0) + 64k - 4; /* this is based off the linker file for tinyuf2 */ | ||
89 | |||
diff --git a/platforms/chibios/BLACKPILL_STM32_F411/ld/STM32F411xE_tinyuf2.ld b/platforms/chibios/BLACKPILL_STM32_F411/ld/STM32F411xE_tinyuf2.ld new file mode 100644 index 000000000..1656c67bf --- /dev/null +++ b/platforms/chibios/BLACKPILL_STM32_F411/ld/STM32F411xE_tinyuf2.ld | |||
@@ -0,0 +1,89 @@ | |||
1 | /* | ||
2 | ChibiOS - Copyright (C) 2006..2018 Giovanni Di Sirio | ||
3 | |||
4 | Licensed under the Apache License, Version 2.0 (the "License"); | ||
5 | you may not use this file except in compliance with the License. | ||
6 | You may obtain a copy of the License at | ||
7 | |||
8 | http://www.apache.org/licenses/LICENSE-2.0 | ||
9 | |||
10 | Unless required by applicable law or agreed to in writing, software | ||
11 | distributed under the License is distributed on an "AS IS" BASIS, | ||
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
13 | See the License for the specific language governing permissions and | ||
14 | limitations under the License. | ||
15 | */ | ||
16 | |||
17 | /* | ||
18 | * STM32F411xE memory setup. | ||
19 | */ | ||
20 | MEMORY | ||
21 | { | ||
22 | flash0 (rx) : org = 0x08000000 + 64k, len = 512k - 64k /* tinyuf2 bootloader requires app to be located at 64k offset for this MCU */ | ||
23 | flash1 (rx) : org = 0x00000000, len = 0 | ||
24 | flash2 (rx) : org = 0x00000000, len = 0 | ||
25 | flash3 (rx) : org = 0x00000000, len = 0 | ||
26 | flash4 (rx) : org = 0x00000000, len = 0 | ||
27 | flash5 (rx) : org = 0x00000000, len = 0 | ||
28 | flash6 (rx) : org = 0x00000000, len = 0 | ||
29 | flash7 (rx) : org = 0x00000000, len = 0 | ||
30 | ram0 (wx) : org = 0x20000000, len = 128k | ||
31 | ram1 (wx) : org = 0x00000000, len = 0 | ||
32 | ram2 (wx) : org = 0x00000000, len = 0 | ||
33 | ram3 (wx) : org = 0x00000000, len = 0 | ||
34 | ram4 (wx) : org = 0x00000000, len = 0 | ||
35 | ram5 (wx) : org = 0x00000000, len = 0 | ||
36 | ram6 (wx) : org = 0x00000000, len = 0 | ||
37 | ram7 (wx) : org = 0x00000000, len = 0 | ||
38 | } | ||
39 | |||
40 | /* For each data/text section two region are defined, a virtual region | ||
41 | and a load region (_LMA suffix).*/ | ||
42 | |||
43 | /* Flash region to be used for exception vectors.*/ | ||
44 | REGION_ALIAS("VECTORS_FLASH", flash0); | ||
45 | REGION_ALIAS("VECTORS_FLASH_LMA", flash0); | ||
46 | |||
47 | /* Flash region to be used for constructors and destructors.*/ | ||
48 | REGION_ALIAS("XTORS_FLASH", flash0); | ||
49 | REGION_ALIAS("XTORS_FLASH_LMA", flash0); | ||
50 | |||
51 | /* Flash region to be used for code text.*/ | ||
52 | REGION_ALIAS("TEXT_FLASH", flash0); | ||
53 | REGION_ALIAS("TEXT_FLASH_LMA", flash0); | ||
54 | |||
55 | /* Flash region to be used for read only data.*/ | ||
56 | REGION_ALIAS("RODATA_FLASH", flash0); | ||
57 | REGION_ALIAS("RODATA_FLASH_LMA", flash0); | ||
58 | |||
59 | /* Flash region to be used for various.*/ | ||
60 | REGION_ALIAS("VARIOUS_FLASH", flash0); | ||
61 | REGION_ALIAS("VARIOUS_FLASH_LMA", flash0); | ||
62 | |||
63 | /* Flash region to be used for RAM(n) initialization data.*/ | ||
64 | REGION_ALIAS("RAM_INIT_FLASH_LMA", flash0); | ||
65 | |||
66 | /* RAM region to be used for Main stack. This stack accommodates the processing | ||
67 | of all exceptions and interrupts.*/ | ||
68 | REGION_ALIAS("MAIN_STACK_RAM", ram0); | ||
69 | |||
70 | /* RAM region to be used for the process stack. This is the stack used by | ||
71 | the main() function.*/ | ||
72 | REGION_ALIAS("PROCESS_STACK_RAM", ram0); | ||
73 | |||
74 | /* RAM region to be used for data segment.*/ | ||
75 | REGION_ALIAS("DATA_RAM", ram0); | ||
76 | REGION_ALIAS("DATA_RAM_LMA", flash0); | ||
77 | |||
78 | /* RAM region to be used for BSS segment.*/ | ||
79 | REGION_ALIAS("BSS_RAM", ram0); | ||
80 | |||
81 | /* RAM region to be used for the default heap.*/ | ||
82 | REGION_ALIAS("HEAP_RAM", ram0); | ||
83 | |||
84 | /* Generic rules inclusion.*/ | ||
85 | INCLUDE rules.ld | ||
86 | |||
87 | /* TinyUF2 bootloader reset support */ | ||
88 | _board_dfu_dbl_tap = ORIGIN(ram0) + 64k - 4; /* this is based off the linker file for tinyuf2 */ | ||
89 | |||
diff --git a/platforms/chibios/GENERIC_STM32_F446XE/board/board.mk b/platforms/chibios/GENERIC_STM32_F446XE/board/board.mk new file mode 100644 index 000000000..57897941c --- /dev/null +++ b/platforms/chibios/GENERIC_STM32_F446XE/board/board.mk | |||
@@ -0,0 +1,9 @@ | |||
1 | # List of all the board related files. | ||
2 | BOARDSRC = $(CHIBIOS)/os/hal/boards/ST_NUCLEO64_F446RE/board.c | ||
3 | |||
4 | # Required include directories | ||
5 | BOARDINC = $(CHIBIOS)/os/hal/boards/ST_NUCLEO64_F446RE | ||
6 | |||
7 | # Shared variables | ||
8 | ALLCSRC += $(BOARDSRC) | ||
9 | ALLINC += $(BOARDINC) | ||
diff --git a/platforms/chibios/GENERIC_STM32_F446XE/configs/board.h b/platforms/chibios/GENERIC_STM32_F446XE/configs/board.h new file mode 100644 index 000000000..80dfcffa9 --- /dev/null +++ b/platforms/chibios/GENERIC_STM32_F446XE/configs/board.h | |||
@@ -0,0 +1,24 @@ | |||
1 | /* Copyright 2020 Nick Brassel (tzarc) | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <https://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #define STM32_HSECLK 16000000 | ||
19 | // The following is required to disable the pull-down on PA9, when PA9 is used for the keyboard matrix: | ||
20 | #define BOARD_OTG_NOVBUSSENS | ||
21 | |||
22 | #include_next "board.h" | ||
23 | |||
24 | #undef STM32_HSE_BYPASS | ||
diff --git a/platforms/chibios/GENERIC_STM32_F446XE/configs/config.h b/platforms/chibios/GENERIC_STM32_F446XE/configs/config.h new file mode 100644 index 000000000..cc52a953e --- /dev/null +++ b/platforms/chibios/GENERIC_STM32_F446XE/configs/config.h | |||
@@ -0,0 +1,23 @@ | |||
1 | /* Copyright 2021 Andrei Purdea | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | /* Address for jumping to bootloader on STM32 chips. */ | ||
18 | /* It is chip dependent, the correct number can be looked up by checking against ST's application note AN2606. | ||
19 | */ | ||
20 | #define STM32_BOOTLOADER_ADDRESS 0x1FFF0000 | ||
21 | #ifndef EARLY_INIT_PERFORM_BOOTLOADER_JUMP | ||
22 | # define EARLY_INIT_PERFORM_BOOTLOADER_JUMP TRUE | ||
23 | #endif | ||
diff --git a/platforms/chibios/GENERIC_STM32_F446XE/configs/mcuconf.h b/platforms/chibios/GENERIC_STM32_F446XE/configs/mcuconf.h new file mode 100644 index 000000000..d2de75590 --- /dev/null +++ b/platforms/chibios/GENERIC_STM32_F446XE/configs/mcuconf.h | |||
@@ -0,0 +1,361 @@ | |||
1 | /* | ||
2 | ChibiOS - Copyright (C) 2006..2018 Giovanni Di Sirio | ||
3 | |||
4 | Licensed under the Apache License, Version 2.0 (the "License"); | ||
5 | you may not use this file except in compliance with the License. | ||
6 | You may obtain a copy of the License at | ||
7 | |||
8 | http://www.apache.org/licenses/LICENSE-2.0 | ||
9 | |||
10 | Unless required by applicable law or agreed to in writing, software | ||
11 | distributed under the License is distributed on an "AS IS" BASIS, | ||
12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
13 | See the License for the specific language governing permissions and | ||
14 | limitations under the License. | ||
15 | */ | ||
16 | |||
17 | #ifndef MCUCONF_H | ||
18 | #define MCUCONF_H | ||
19 | |||
20 | /* | ||
21 | * STM32F4xx drivers configuration. | ||
22 | * The following settings override the default settings present in | ||
23 | * the various device driver implementation headers. | ||
24 | * Note that the settings for each driver only have effect if the whole | ||
25 | * driver is enabled in halconf.h. | ||
26 | * | ||
27 | * IRQ priorities: | ||
28 | * 15...0 Lowest...Highest. | ||
29 | * | ||
30 | * DMA priorities: | ||
31 | * 0...3 Lowest...Highest. | ||
32 | */ | ||
33 | |||
34 | #define STM32F4xx_MCUCONF | ||
35 | |||
36 | /* | ||
37 | * HAL driver system settings. | ||
38 | */ | ||
39 | #define STM32_NO_INIT FALSE | ||
40 | #define STM32_HSI_ENABLED FALSE | ||
41 | #define STM32_LSI_ENABLED TRUE | ||
42 | #define STM32_HSE_ENABLED TRUE | ||
43 | #define STM32_LSE_ENABLED FALSE | ||
44 | #define STM32_CLOCK48_REQUIRED TRUE | ||
45 | #define STM32_SW STM32_SW_PLL | ||
46 | #define STM32_PLLSRC STM32_PLLSRC_HSE | ||
47 | #define STM32_PLLM_VALUE 8 | ||
48 | #define STM32_PLLN_VALUE 180 | ||
49 | #define STM32_PLLP_VALUE 2 | ||
50 | #define STM32_PLLQ_VALUE 7 | ||
51 | #define STM32_PLLI2SN_VALUE 192 | ||
52 | #define STM32_PLLI2SM_VALUE 8 | ||
53 | #define STM32_PLLI2SR_VALUE 4 | ||
54 | #define STM32_PLLI2SP_VALUE 4 | ||
55 | #define STM32_PLLI2SQ_VALUE 4 | ||
56 | #define STM32_PLLSAIN_VALUE 192 | ||
57 | #define STM32_PLLSAIM_VALUE 8 | ||
58 | #define STM32_PLLSAIP_VALUE 8 | ||
59 | #define STM32_PLLSAIQ_VALUE 4 | ||
60 | #define STM32_HPRE STM32_HPRE_DIV1 | ||
61 | #define STM32_PPRE1 STM32_PPRE1_DIV4 | ||
62 | #define STM32_PPRE2 STM32_PPRE2_DIV2 | ||
63 | #define STM32_RTCSEL STM32_RTCSEL_LSI | ||
64 | #define STM32_RTCPRE_VALUE 8 | ||
65 | #define STM32_MCO1SEL STM32_MCO1SEL_HSE | ||
66 | #define STM32_MCO1PRE STM32_MCO1PRE_DIV1 | ||
67 | #define STM32_MCO2SEL STM32_MCO2SEL_PLLI2S | ||
68 | #define STM32_MCO2PRE STM32_MCO2PRE_DIV1 | ||
69 | #define STM32_I2SSRC STM32_I2SSRC_PLLI2S | ||
70 | #define STM32_SAI1SEL STM32_SAI2SEL_PLLR | ||
71 | #define STM32_SAI2SEL STM32_SAI2SEL_PLLR | ||
72 | #define STM32_CK48MSEL STM32_CK48MSEL_PLLALT | ||
73 | #define STM32_PVD_ENABLE FALSE | ||
74 | #define STM32_PLS STM32_PLS_LEV0 | ||
75 | #define STM32_BKPRAM_ENABLE FALSE | ||
76 | |||
77 | /* | ||
78 | * IRQ system settings. | ||
79 | */ | ||
80 | #define STM32_IRQ_EXTI0_PRIORITY 6 | ||
81 | #define STM32_IRQ_EXTI1_PRIORITY 6 | ||
82 | #define STM32_IRQ_EXTI2_PRIORITY 6 | ||
83 | #define STM32_IRQ_EXTI3_PRIORITY 6 | ||
84 | #define STM32_IRQ_EXTI4_PRIORITY 6 | ||
85 | #define STM32_IRQ_EXTI5_9_PRIORITY 6 | ||
86 | #define STM32_IRQ_EXTI10_15_PRIORITY 6 | ||
87 | #define STM32_IRQ_EXTI16_PRIORITY 6 | ||
88 | #define STM32_IRQ_EXTI17_PRIORITY 15 | ||
89 | #define STM32_IRQ_EXTI18_PRIORITY 6 | ||
90 | #define STM32_IRQ_EXTI19_PRIORITY 6 | ||
91 | #define STM32_IRQ_EXTI20_PRIORITY 6 | ||
92 | #define STM32_IRQ_EXTI21_PRIORITY 15 | ||
93 | #define STM32_IRQ_EXTI22_PRIORITY 15 | ||
94 | |||
95 | /* | ||
96 | * ADC driver system settings. | ||
97 | */ | ||
98 | #define STM32_ADC_ADCPRE ADC_CCR_ADCPRE_DIV4 | ||
99 | #define STM32_ADC_USE_ADC1 FALSE | ||
100 | #define STM32_ADC_USE_ADC2 FALSE | ||
101 | #define STM32_ADC_USE_ADC3 FALSE | ||
102 | #define STM32_ADC_ADC1_DMA_STREAM STM32_DMA_STREAM_ID(2, 4) | ||
103 | #define STM32_ADC_ADC2_DMA_STREAM STM32_DMA_STREAM_ID(2, 2) | ||
104 | #define STM32_ADC_ADC3_DMA_STREAM STM32_DMA_STREAM_ID(2, 1) | ||
105 | #define STM32_ADC_ADC1_DMA_PRIORITY 2 | ||
106 | #define STM32_ADC_ADC2_DMA_PRIORITY 2 | ||
107 | #define STM32_ADC_ADC3_DMA_PRIORITY 2 | ||
108 | #define STM32_ADC_IRQ_PRIORITY 6 | ||
109 | #define STM32_ADC_ADC1_DMA_IRQ_PRIORITY 6 | ||
110 | #define STM32_ADC_ADC2_DMA_IRQ_PRIORITY 6 | ||
111 | #define STM32_ADC_ADC3_DMA_IRQ_PRIORITY 6 | ||
112 | |||
113 | /* | ||
114 | * CAN driver system settings. | ||
115 | */ | ||
116 | #define STM32_CAN_USE_CAN1 FALSE | ||
117 | #define STM32_CAN_USE_CAN2 FALSE | ||
118 | #define STM32_CAN_CAN1_IRQ_PRIORITY 11 | ||
119 | #define STM32_CAN_CAN2_IRQ_PRIORITY 11 | ||
120 | |||
121 | /* | ||
122 | * DAC driver system settings. | ||
123 | */ | ||
124 | #define STM32_DAC_DUAL_MODE FALSE | ||
125 | #define STM32_DAC_USE_DAC1_CH1 FALSE | ||
126 | #define STM32_DAC_USE_DAC1_CH2 FALSE | ||
127 | #define STM32_DAC_DAC1_CH1_IRQ_PRIORITY 10 | ||
128 | #define STM32_DAC_DAC1_CH2_IRQ_PRIORITY 10 | ||
129 | #define STM32_DAC_DAC1_CH1_DMA_PRIORITY 2 | ||
130 | #define STM32_DAC_DAC1_CH2_DMA_PRIORITY 2 | ||
131 | #define STM32_DAC_DAC1_CH1_DMA_STREAM STM32_DMA_STREAM_ID(1, 5) | ||
132 | #define STM32_DAC_DAC1_CH2_DMA_STREAM STM32_DMA_STREAM_ID(1, 6) | ||
133 | |||
134 | /* | ||
135 | * GPT driver system settings. | ||
136 | */ | ||
137 | #define STM32_GPT_USE_TIM1 FALSE | ||
138 | #define STM32_GPT_USE_TIM2 FALSE | ||
139 | #define STM32_GPT_USE_TIM3 FALSE | ||
140 | #define STM32_GPT_USE_TIM4 FALSE | ||
141 | #define STM32_GPT_USE_TIM5 FALSE | ||
142 | #define STM32_GPT_USE_TIM6 FALSE | ||
143 | #define STM32_GPT_USE_TIM7 FALSE | ||
144 | #define STM32_GPT_USE_TIM8 FALSE | ||
145 | #define STM32_GPT_USE_TIM9 FALSE | ||
146 | #define STM32_GPT_USE_TIM11 FALSE | ||
147 | #define STM32_GPT_USE_TIM12 FALSE | ||
148 | #define STM32_GPT_USE_TIM14 FALSE | ||
149 | #define STM32_GPT_TIM1_IRQ_PRIORITY 7 | ||
150 | #define STM32_GPT_TIM2_IRQ_PRIORITY 7 | ||
151 | #define STM32_GPT_TIM3_IRQ_PRIORITY 7 | ||
152 | #define STM32_GPT_TIM4_IRQ_PRIORITY 7 | ||
153 | #define STM32_GPT_TIM5_IRQ_PRIORITY 7 | ||
154 | #define STM32_GPT_TIM6_IRQ_PRIORITY 7 | ||
155 | #define STM32_GPT_TIM7_IRQ_PRIORITY 7 | ||
156 | #define STM32_GPT_TIM8_IRQ_PRIORITY 7 | ||
157 | #define STM32_GPT_TIM9_IRQ_PRIORITY 7 | ||
158 | #define STM32_GPT_TIM11_IRQ_PRIORITY 7 | ||
159 | #define STM32_GPT_TIM12_IRQ_PRIORITY 7 | ||
160 | #define STM32_GPT_TIM14_IRQ_PRIORITY 7 | ||
161 | |||
162 | /* | ||
163 | * I2C driver system settings. | ||
164 | */ | ||
165 | #define STM32_I2C_USE_I2C1 FALSE | ||
166 | #define STM32_I2C_USE_I2C2 FALSE | ||
167 | #define STM32_I2C_USE_I2C3 FALSE | ||
168 | #define STM32_I2C_BUSY_TIMEOUT 50 | ||
169 | #define STM32_I2C_I2C1_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 0) | ||
170 | #define STM32_I2C_I2C1_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 6) | ||
171 | #define STM32_I2C_I2C2_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 2) | ||
172 | #define STM32_I2C_I2C2_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 7) | ||
173 | #define STM32_I2C_I2C3_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 2) | ||
174 | #define STM32_I2C_I2C3_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 4) | ||
175 | #define STM32_I2C_I2C1_IRQ_PRIORITY 5 | ||
176 | #define STM32_I2C_I2C2_IRQ_PRIORITY 5 | ||
177 | #define STM32_I2C_I2C3_IRQ_PRIORITY 5 | ||
178 | #define STM32_I2C_I2C1_DMA_PRIORITY 3 | ||
179 | #define STM32_I2C_I2C2_DMA_PRIORITY 3 | ||
180 | #define STM32_I2C_I2C3_DMA_PRIORITY 3 | ||
181 | #define STM32_I2C_DMA_ERROR_HOOK(i2cp) osalSysHalt("DMA failure") | ||
182 | |||
183 | /* | ||
184 | * I2S driver system settings. | ||
185 | */ | ||
186 | #define STM32_I2S_USE_SPI2 FALSE | ||
187 | #define STM32_I2S_USE_SPI3 FALSE | ||
188 | #define STM32_I2S_SPI2_IRQ_PRIORITY 10 | ||
189 | #define STM32_I2S_SPI3_IRQ_PRIORITY 10 | ||
190 | #define STM32_I2S_SPI2_DMA_PRIORITY 1 | ||
191 | #define STM32_I2S_SPI3_DMA_PRIORITY 1 | ||
192 | #define STM32_I2S_SPI2_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 3) | ||
193 | #define STM32_I2S_SPI2_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 4) | ||
194 | #define STM32_I2S_SPI3_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 0) | ||
195 | #define STM32_I2S_SPI3_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 7) | ||
196 | #define STM32_I2S_DMA_ERROR_HOOK(i2sp) osalSysHalt("DMA failure") | ||
197 | |||
198 | /* | ||
199 | * ICU driver system settings. | ||
200 | */ | ||
201 | #define STM32_ICU_USE_TIM1 FALSE | ||
202 | #define STM32_ICU_USE_TIM2 FALSE | ||
203 | #define STM32_ICU_USE_TIM3 FALSE | ||
204 | #define STM32_ICU_USE_TIM4 FALSE | ||
205 | #define STM32_ICU_USE_TIM5 FALSE | ||
206 | #define STM32_ICU_USE_TIM8 FALSE | ||
207 | #define STM32_ICU_USE_TIM9 FALSE | ||
208 | #define STM32_ICU_TIM1_IRQ_PRIORITY 7 | ||
209 | #define STM32_ICU_TIM2_IRQ_PRIORITY 7 | ||
210 | #define STM32_ICU_TIM3_IRQ_PRIORITY 7 | ||
211 | #define STM32_ICU_TIM4_IRQ_PRIORITY 7 | ||
212 | #define STM32_ICU_TIM5_IRQ_PRIORITY 7 | ||
213 | #define STM32_ICU_TIM8_IRQ_PRIORITY 7 | ||
214 | #define STM32_ICU_TIM9_IRQ_PRIORITY 7 | ||
215 | |||
216 | /* | ||
217 | * MAC driver system settings. | ||
218 | */ | ||
219 | #define STM32_MAC_TRANSMIT_BUFFERS 2 | ||
220 | #define STM32_MAC_RECEIVE_BUFFERS 4 | ||
221 | #define STM32_MAC_BUFFERS_SIZE 1522 | ||
222 | #define STM32_MAC_PHY_TIMEOUT 100 | ||
223 | #define STM32_MAC_ETH1_CHANGE_PHY_STATE TRUE | ||
224 | #define STM32_MAC_ETH1_IRQ_PRIORITY 13 | ||
225 | #define STM32_MAC_IP_CHECKSUM_OFFLOAD 0 | ||
226 | |||
227 | /* | ||
228 | * PWM driver system settings. | ||
229 | */ | ||
230 | #define STM32_PWM_USE_ADVANCED FALSE | ||
231 | #define STM32_PWM_USE_TIM1 FALSE | ||
232 | #define STM32_PWM_USE_TIM2 FALSE | ||
233 | #define STM32_PWM_USE_TIM3 FALSE | ||
234 | #define STM32_PWM_USE_TIM4 FALSE | ||
235 | #define STM32_PWM_USE_TIM5 FALSE | ||
236 | #define STM32_PWM_USE_TIM8 FALSE | ||
237 | #define STM32_PWM_USE_TIM9 FALSE | ||
238 | #define STM32_PWM_TIM1_IRQ_PRIORITY 7 | ||
239 | #define STM32_PWM_TIM2_IRQ_PRIORITY 7 | ||
240 | #define STM32_PWM_TIM3_IRQ_PRIORITY 7 | ||
241 | #define STM32_PWM_TIM4_IRQ_PRIORITY 7 | ||
242 | #define STM32_PWM_TIM5_IRQ_PRIORITY 7 | ||
243 | #define STM32_PWM_TIM8_IRQ_PRIORITY 7 | ||
244 | #define STM32_PWM_TIM9_IRQ_PRIORITY 7 | ||
245 | |||
246 | /* | ||
247 | * SDC driver system settings. | ||
248 | */ | ||
249 | #define STM32_SDC_SDIO_DMA_PRIORITY 3 | ||
250 | #define STM32_SDC_SDIO_IRQ_PRIORITY 9 | ||
251 | #define STM32_SDC_WRITE_TIMEOUT_MS 1000 | ||
252 | #define STM32_SDC_READ_TIMEOUT_MS 1000 | ||
253 | #define STM32_SDC_CLOCK_ACTIVATION_DELAY 10 | ||
254 | #define STM32_SDC_SDIO_UNALIGNED_SUPPORT TRUE | ||
255 | #define STM32_SDC_SDIO_DMA_STREAM STM32_DMA_STREAM_ID(2, 3) | ||
256 | |||
257 | /* | ||
258 | * SERIAL driver system settings. | ||
259 | */ | ||
260 | #define STM32_SERIAL_USE_USART1 FALSE | ||
261 | #define STM32_SERIAL_USE_USART2 FALSE | ||
262 | #define STM32_SERIAL_USE_USART3 FALSE | ||
263 | #define STM32_SERIAL_USE_UART4 FALSE | ||
264 | #define STM32_SERIAL_USE_UART5 FALSE | ||
265 | #define STM32_SERIAL_USE_USART6 FALSE | ||
266 | #define STM32_SERIAL_USE_UART7 FALSE | ||
267 | #define STM32_SERIAL_USE_UART8 FALSE | ||
268 | #define STM32_SERIAL_USART1_PRIORITY 12 | ||
269 | #define STM32_SERIAL_USART2_PRIORITY 12 | ||
270 | #define STM32_SERIAL_USART3_PRIORITY 12 | ||
271 | #define STM32_SERIAL_UART4_PRIORITY 12 | ||
272 | #define STM32_SERIAL_UART5_PRIORITY 12 | ||
273 | #define STM32_SERIAL_USART6_PRIORITY 12 | ||
274 | #define STM32_SERIAL_UART7_PRIORITY 12 | ||
275 | #define STM32_SERIAL_UART8_PRIORITY 12 | ||
276 | |||
277 | /* | ||
278 | * SPI driver system settings. | ||
279 | */ | ||
280 | #define STM32_SPI_USE_SPI1 FALSE | ||
281 | #define STM32_SPI_USE_SPI2 FALSE | ||
282 | #define STM32_SPI_USE_SPI3 FALSE | ||
283 | #define STM32_SPI_USE_SPI4 FALSE | ||
284 | #define STM32_SPI_SPI1_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 0) | ||
285 | #define STM32_SPI_SPI1_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 3) | ||
286 | #define STM32_SPI_SPI2_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 3) | ||
287 | #define STM32_SPI_SPI2_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 4) | ||
288 | #define STM32_SPI_SPI3_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 0) | ||
289 | #define STM32_SPI_SPI3_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 7) | ||
290 | #define STM32_SPI_SPI4_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 0) | ||
291 | #define STM32_SPI_SPI4_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 1) | ||
292 | #define STM32_SPI_SPI1_DMA_PRIORITY 1 | ||
293 | #define STM32_SPI_SPI2_DMA_PRIORITY 1 | ||
294 | #define STM32_SPI_SPI3_DMA_PRIORITY 1 | ||
295 | #define STM32_SPI_SPI4_DMA_PRIORITY 1 | ||
296 | #define STM32_SPI_SPI1_IRQ_PRIORITY 10 | ||
297 | #define STM32_SPI_SPI2_IRQ_PRIORITY 10 | ||
298 | #define STM32_SPI_SPI3_IRQ_PRIORITY 10 | ||
299 | #define STM32_SPI_SPI4_IRQ_PRIORITY 10 | ||
300 | #define STM32_SPI_DMA_ERROR_HOOK(spip) osalSysHalt("DMA failure") | ||
301 | |||
302 | /* | ||
303 | * ST driver system settings. | ||
304 | */ | ||
305 | #define STM32_ST_IRQ_PRIORITY 8 | ||
306 | #define STM32_ST_USE_TIMER 2 | ||
307 | |||
308 | /* | ||
309 | * UART driver system settings. | ||
310 | */ | ||
311 | #define STM32_UART_USE_USART1 FALSE | ||
312 | #define STM32_UART_USE_USART2 FALSE | ||
313 | #define STM32_UART_USE_USART3 FALSE | ||
314 | #define STM32_UART_USE_UART4 FALSE | ||
315 | #define STM32_UART_USE_UART5 FALSE | ||
316 | #define STM32_UART_USE_USART6 FALSE | ||
317 | #define STM32_UART_USART1_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 5) | ||
318 | #define STM32_UART_USART1_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 7) | ||
319 | #define STM32_UART_USART2_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 5) | ||
320 | #define STM32_UART_USART2_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 6) | ||
321 | #define STM32_UART_USART3_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 1) | ||
322 | #define STM32_UART_USART3_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 3) | ||
323 | #define STM32_UART_UART4_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 2) | ||
324 | #define STM32_UART_UART4_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 4) | ||
325 | #define STM32_UART_UART5_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 0) | ||
326 | #define STM32_UART_UART5_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 7) | ||
327 | #define STM32_UART_USART6_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 2) | ||
328 | #define STM32_UART_USART6_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 7) | ||
329 | #define STM32_UART_USART1_IRQ_PRIORITY 12 | ||
330 | #define STM32_UART_USART2_IRQ_PRIORITY 12 | ||
331 | #define STM32_UART_USART3_IRQ_PRIORITY 12 | ||
332 | #define STM32_UART_UART4_IRQ_PRIORITY 12 | ||
333 | #define STM32_UART_UART5_IRQ_PRIORITY 12 | ||
334 | #define STM32_UART_USART6_IRQ_PRIORITY 12 | ||
335 | #define STM32_UART_USART1_DMA_PRIORITY 0 | ||
336 | #define STM32_UART_USART2_DMA_PRIORITY 0 | ||
337 | #define STM32_UART_USART3_DMA_PRIORITY 0 | ||
338 | #define STM32_UART_UART4_DMA_PRIORITY 0 | ||
339 | #define STM32_UART_UART5_DMA_PRIORITY 0 | ||
340 | #define STM32_UART_USART6_DMA_PRIORITY 0 | ||
341 | #define STM32_UART_DMA_ERROR_HOOK(uartp) osalSysHalt("DMA failure") | ||
342 | |||
343 | /* | ||
344 | * USB driver system settings. | ||
345 | */ | ||
346 | #define STM32_USB_USE_OTG1 TRUE | ||
347 | #define STM32_USB_USE_OTG2 FALSE | ||
348 | #define STM32_USB_OTG1_IRQ_PRIORITY 14 | ||
349 | #define STM32_USB_OTG2_IRQ_PRIORITY 14 | ||
350 | #define STM32_USB_OTG1_RX_FIFO_SIZE 512 | ||
351 | #define STM32_USB_OTG2_RX_FIFO_SIZE 1024 | ||
352 | #define STM32_USB_OTG_THREAD_PRIO LOWPRIO | ||
353 | #define STM32_USB_OTG_THREAD_STACK_SIZE 128 | ||
354 | #define STM32_USB_OTGFIFO_FILL_BASEPRI 0 | ||
355 | |||
356 | /* | ||
357 | * WDG driver system settings. | ||
358 | */ | ||
359 | #define STM32_WDG_USE_IWDG FALSE | ||
360 | |||
361 | #endif /* MCUCONF_H */ | ||
diff --git a/quantum/bootmagic/bootmagic.h b/quantum/bootmagic/bootmagic.h new file mode 100644 index 000000000..959750178 --- /dev/null +++ b/quantum/bootmagic/bootmagic.h | |||
@@ -0,0 +1,24 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #if defined(BOOTMAGIC_ENABLE) | ||
19 | # include "bootmagic_full.h" | ||
20 | #elif defined(BOOTMAGIC_LITE) | ||
21 | # include "bootmagic_lite.h" | ||
22 | #endif | ||
23 | |||
24 | void bootmagic(void); | ||
diff --git a/tmk_core/common/bootmagic.c b/quantum/bootmagic/bootmagic_full.c index c1b3adf94..a7a0dcfcb 100644 --- a/tmk_core/common/bootmagic.c +++ b/quantum/bootmagic/bootmagic_full.c | |||
@@ -1,3 +1,18 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
1 | #include <stdint.h> | 16 | #include <stdint.h> |
2 | #include <stdbool.h> | 17 | #include <stdbool.h> |
3 | #include "wait.h" | 18 | #include "wait.h" |
@@ -10,18 +25,35 @@ | |||
10 | #include "eeconfig.h" | 25 | #include "eeconfig.h" |
11 | #include "bootmagic.h" | 26 | #include "bootmagic.h" |
12 | 27 | ||
13 | keymap_config_t keymap_config; | 28 | /** \brief Scan Keycode |
14 | |||
15 | /** \brief Bootmagic | ||
16 | * | 29 | * |
17 | * FIXME: needs doc | 30 | * FIXME: needs doc |
18 | */ | 31 | */ |
19 | void bootmagic(void) { | 32 | static bool scan_keycode(uint8_t keycode) { |
20 | /* check signature */ | 33 | for (uint8_t r = 0; r < MATRIX_ROWS; r++) { |
21 | if (!eeconfig_is_enabled()) { | 34 | matrix_row_t matrix_row = matrix_get_row(r); |
22 | eeconfig_init(); | 35 | for (uint8_t c = 0; c < MATRIX_COLS; c++) { |
36 | if (matrix_row & ((matrix_row_t)1 << c)) { | ||
37 | if (keycode == keymap_key_to_keycode(0, (keypos_t){.row = r, .col = c})) { | ||
38 | return true; | ||
39 | } | ||
40 | } | ||
41 | } | ||
23 | } | 42 | } |
43 | return false; | ||
44 | } | ||
45 | |||
46 | /** \brief Bootmagic Scan Keycode | ||
47 | * | ||
48 | * FIXME: needs doc | ||
49 | */ | ||
50 | static bool bootmagic_scan_keycode(uint8_t keycode) { | ||
51 | if (!scan_keycode(BOOTMAGIC_KEY_SALT)) return false; | ||
52 | |||
53 | return scan_keycode(keycode); | ||
54 | } | ||
24 | 55 | ||
56 | void bootmagic(void) { | ||
25 | /* do scans in case of bounce */ | 57 | /* do scans in case of bounce */ |
26 | print("bootmagic scan: ... "); | 58 | print("bootmagic scan: ... "); |
27 | uint8_t scan = 100; | 59 | uint8_t scan = 100; |
@@ -46,8 +78,6 @@ void bootmagic(void) { | |||
46 | bootloader_jump(); | 78 | bootloader_jump(); |
47 | } | 79 | } |
48 | 80 | ||
49 | /* debug enable */ | ||
50 | debug_config.raw = eeconfig_read_debug(); | ||
51 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEBUG_ENABLE)) { | 81 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEBUG_ENABLE)) { |
52 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEBUG_MATRIX)) { | 82 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEBUG_MATRIX)) { |
53 | debug_config.matrix = !debug_config.matrix; | 83 | debug_config.matrix = !debug_config.matrix; |
@@ -61,8 +91,6 @@ void bootmagic(void) { | |||
61 | } | 91 | } |
62 | eeconfig_update_debug(debug_config.raw); | 92 | eeconfig_update_debug(debug_config.raw); |
63 | 93 | ||
64 | /* keymap config */ | ||
65 | keymap_config.raw = eeconfig_read_keymap(); | ||
66 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_SWAP_CONTROL_CAPSLOCK)) { | 94 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_SWAP_CONTROL_CAPSLOCK)) { |
67 | keymap_config.swap_control_capslock = !keymap_config.swap_control_capslock; | 95 | keymap_config.swap_control_capslock = !keymap_config.swap_control_capslock; |
68 | } | 96 | } |
@@ -93,71 +121,27 @@ void bootmagic(void) { | |||
93 | uint8_t default_layer = 0; | 121 | uint8_t default_layer = 0; |
94 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_0)) { | 122 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_0)) { |
95 | default_layer |= (1 << 0); | 123 | default_layer |= (1 << 0); |
96 | } | 124 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_1)) { |
97 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_1)) { | ||
98 | default_layer |= (1 << 1); | 125 | default_layer |= (1 << 1); |
99 | } | 126 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_2)) { |
100 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_2)) { | ||
101 | default_layer |= (1 << 2); | 127 | default_layer |= (1 << 2); |
102 | } | 128 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_3)) { |
103 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_3)) { | ||
104 | default_layer |= (1 << 3); | 129 | default_layer |= (1 << 3); |
105 | } | 130 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_4)) { |
106 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_4)) { | ||
107 | default_layer |= (1 << 4); | 131 | default_layer |= (1 << 4); |
108 | } | 132 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_5)) { |
109 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_5)) { | ||
110 | default_layer |= (1 << 5); | 133 | default_layer |= (1 << 5); |
111 | } | 134 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_6)) { |
112 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_6)) { | ||
113 | default_layer |= (1 << 6); | 135 | default_layer |= (1 << 6); |
114 | } | 136 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_7)) { |
115 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_DEFAULT_LAYER_7)) { | ||
116 | default_layer |= (1 << 7); | 137 | default_layer |= (1 << 7); |
117 | } | 138 | } |
118 | if (default_layer) { | 139 | eeconfig_update_default_layer(default_layer); |
119 | eeconfig_update_default_layer(default_layer); | ||
120 | default_layer_set((layer_state_t)default_layer); | ||
121 | } else { | ||
122 | default_layer = eeconfig_read_default_layer(); | ||
123 | default_layer_set((layer_state_t)default_layer); | ||
124 | } | ||
125 | /* Also initialize layer state to trigger callback functions for layer_state */ | ||
126 | layer_state_set_kb((layer_state_t)layer_state); | ||
127 | 140 | ||
128 | /* EE_HANDS handedness */ | 141 | /* EE_HANDS handedness */ |
129 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_EE_HANDS_LEFT)) { | 142 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_EE_HANDS_LEFT)) { |
130 | eeconfig_update_handedness(true); | 143 | eeconfig_update_handedness(true); |
131 | } | 144 | } else if (bootmagic_scan_keycode(BOOTMAGIC_KEY_EE_HANDS_RIGHT)) { |
132 | if (bootmagic_scan_keycode(BOOTMAGIC_KEY_EE_HANDS_RIGHT)) { | ||
133 | eeconfig_update_handedness(false); | 145 | eeconfig_update_handedness(false); |
134 | } | 146 | } |
135 | } | 147 | } |
136 | |||
137 | /** \brief Scan Keycode | ||
138 | * | ||
139 | * FIXME: needs doc | ||
140 | */ | ||
141 | static bool scan_keycode(uint8_t keycode) { | ||
142 | for (uint8_t r = 0; r < MATRIX_ROWS; r++) { | ||
143 | matrix_row_t matrix_row = matrix_get_row(r); | ||
144 | for (uint8_t c = 0; c < MATRIX_COLS; c++) { | ||
145 | if (matrix_row & ((matrix_row_t)1 << c)) { | ||
146 | if (keycode == keymap_key_to_keycode(0, (keypos_t){.row = r, .col = c})) { | ||
147 | return true; | ||
148 | } | ||
149 | } | ||
150 | } | ||
151 | } | ||
152 | return false; | ||
153 | } | ||
154 | |||
155 | /** \brief Bootmagic Scan Keycode | ||
156 | * | ||
157 | * FIXME: needs doc | ||
158 | */ | ||
159 | bool bootmagic_scan_keycode(uint8_t keycode) { | ||
160 | if (!scan_keycode(BOOTMAGIC_KEY_SALT)) return false; | ||
161 | |||
162 | return scan_keycode(keycode); | ||
163 | } | ||
diff --git a/tmk_core/common/bootmagic.h b/quantum/bootmagic/bootmagic_full.h index 8209d0194..28f914c1b 100644 --- a/tmk_core/common/bootmagic.h +++ b/quantum/bootmagic/bootmagic_full.h | |||
@@ -1,3 +1,19 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
1 | #pragma once | 17 | #pragma once |
2 | 18 | ||
3 | /* FIXME: Add special doxygen comments for defines here. */ | 19 | /* FIXME: Add special doxygen comments for defines here. */ |
@@ -96,7 +112,4 @@ | |||
96 | #endif | 112 | #endif |
97 | #ifndef BOOTMAGIC_KEY_DEFAULT_LAYER_7 | 113 | #ifndef BOOTMAGIC_KEY_DEFAULT_LAYER_7 |
98 | # define BOOTMAGIC_KEY_DEFAULT_LAYER_7 KC_7 | 114 | # define BOOTMAGIC_KEY_DEFAULT_LAYER_7 KC_7 |
99 | #endif | 115 | #endif \ No newline at end of file |
100 | |||
101 | void bootmagic(void); | ||
102 | bool bootmagic_scan_keycode(uint8_t keycode); | ||
diff --git a/tmk_core/common/bootmagic_lite.c b/quantum/bootmagic/bootmagic_lite.c index cbf756a17..9cbdcb0bb 100644 --- a/tmk_core/common/bootmagic_lite.c +++ b/quantum/bootmagic/bootmagic_lite.c | |||
@@ -1,3 +1,18 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
1 | #include "quantum.h" | 16 | #include "quantum.h" |
2 | 17 | ||
3 | /** \brief Reset eeprom | 18 | /** \brief Reset eeprom |
@@ -47,3 +62,5 @@ __attribute__((weak)) void bootmagic_lite(void) { | |||
47 | bootloader_jump(); | 62 | bootloader_jump(); |
48 | } | 63 | } |
49 | } | 64 | } |
65 | |||
66 | void bootmagic(void) { bootmagic_lite(); } | ||
diff --git a/quantum/bootmagic/bootmagic_lite.h b/quantum/bootmagic/bootmagic_lite.h new file mode 100644 index 000000000..17777e6b4 --- /dev/null +++ b/quantum/bootmagic/bootmagic_lite.h | |||
@@ -0,0 +1,25 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #ifndef BOOTMAGIC_LITE_COLUMN | ||
19 | # define BOOTMAGIC_LITE_COLUMN 0 | ||
20 | #endif | ||
21 | #ifndef BOOTMAGIC_LITE_ROW | ||
22 | # define BOOTMAGIC_LITE_ROW 0 | ||
23 | #endif | ||
24 | |||
25 | void bootmagic_lite(void); | ||
diff --git a/quantum/bootmagic/magic.c b/quantum/bootmagic/magic.c new file mode 100644 index 000000000..f1cb11c39 --- /dev/null +++ b/quantum/bootmagic/magic.c | |||
@@ -0,0 +1,54 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include <stdint.h> | ||
17 | #include <stdbool.h> | ||
18 | #include "wait.h" | ||
19 | #include "matrix.h" | ||
20 | #include "bootloader.h" | ||
21 | #include "debug.h" | ||
22 | #include "keymap.h" | ||
23 | #include "host.h" | ||
24 | #include "action_layer.h" | ||
25 | #include "eeconfig.h" | ||
26 | #include "bootmagic.h" | ||
27 | |||
28 | keymap_config_t keymap_config; | ||
29 | |||
30 | __attribute__((weak)) void bootmagic(void) {} | ||
31 | |||
32 | /** \brief Magic | ||
33 | * | ||
34 | * FIXME: Needs doc | ||
35 | */ | ||
36 | void magic(void) { | ||
37 | /* check signature */ | ||
38 | if (!eeconfig_is_enabled()) { | ||
39 | eeconfig_init(); | ||
40 | } | ||
41 | |||
42 | /* init globals */ | ||
43 | debug_config.raw = eeconfig_read_debug(); | ||
44 | keymap_config.raw = eeconfig_read_keymap(); | ||
45 | |||
46 | bootmagic(); | ||
47 | |||
48 | /* read here just incase bootmagic process changed its value */ | ||
49 | layer_state_t default_layer = (layer_state_t)eeconfig_read_default_layer(); | ||
50 | default_layer_set(default_layer); | ||
51 | |||
52 | /* Also initialize layer state to trigger callback functions for layer_state */ | ||
53 | layer_state_set_kb((layer_state_t)layer_state); | ||
54 | } | ||
diff --git a/quantum/bootmagic/magic.h b/quantum/bootmagic/magic.h new file mode 100644 index 000000000..2c3969b85 --- /dev/null +++ b/quantum/bootmagic/magic.h | |||
@@ -0,0 +1,18 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | void magic(void); | ||
diff --git a/quantum/keycode_config.h b/quantum/keycode_config.h index f878168c5..d7e334fdc 100644 --- a/quantum/keycode_config.h +++ b/quantum/keycode_config.h | |||
@@ -37,6 +37,7 @@ typedef union { | |||
37 | bool nkro : 1; | 37 | bool nkro : 1; |
38 | bool swap_lctl_lgui : 1; | 38 | bool swap_lctl_lgui : 1; |
39 | bool swap_rctl_rgui : 1; | 39 | bool swap_rctl_rgui : 1; |
40 | bool oneshot_disable : 1; | ||
40 | }; | 41 | }; |
41 | } keymap_config_t; | 42 | } keymap_config_t; |
42 | 43 | ||
diff --git a/quantum/led_matrix.c b/quantum/led_matrix.c index 4f1f06c7a..72eb5190b 100644 --- a/quantum/led_matrix.c +++ b/quantum/led_matrix.c | |||
@@ -17,79 +17,111 @@ | |||
17 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | 17 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <stdint.h> | ||
21 | #include <stdbool.h> | ||
22 | #include "quantum.h" | ||
23 | #include "led_matrix.h" | 20 | #include "led_matrix.h" |
24 | #include "progmem.h" | 21 | #include "progmem.h" |
25 | #include "config.h" | 22 | #include "config.h" |
26 | #include "eeprom.h" | 23 | #include "eeprom.h" |
27 | #include <string.h> | 24 | #include <string.h> |
28 | #include <math.h> | 25 | #include <math.h> |
26 | #include "led_tables.h" | ||
29 | 27 | ||
30 | led_eeconfig_t led_matrix_eeconfig; | 28 | #include <lib/lib8tion/lib8tion.h> |
31 | 29 | ||
32 | #ifndef MAX | 30 | #if defined(LED_DISABLE_AFTER_TIMEOUT) && !defined(LED_DISABLE_TIMEOUT) |
33 | # define MAX(X, Y) ((X) > (Y) ? (X) : (Y)) | 31 | # define LED_DISABLE_TIMEOUT (LED_DISABLE_AFTER_TIMEOUT * 1200UL) |
34 | #endif | 32 | #endif |
35 | 33 | ||
36 | #ifndef MIN | 34 | #ifndef LED_DISABLE_TIMEOUT |
37 | # define MIN(a, b) ((a) < (b) ? (a) : (b)) | 35 | # define LED_DISABLE_TIMEOUT 0 |
38 | #endif | ||
39 | |||
40 | #ifndef LED_DISABLE_AFTER_TIMEOUT | ||
41 | # define LED_DISABLE_AFTER_TIMEOUT 0 | ||
42 | #endif | 36 | #endif |
43 | 37 | ||
44 | #ifndef LED_DISABLE_WHEN_USB_SUSPENDED | 38 | #ifndef LED_DISABLE_WHEN_USB_SUSPENDED |
45 | # define LED_DISABLE_WHEN_USB_SUSPENDED false | 39 | # define LED_DISABLE_WHEN_USB_SUSPENDED false |
46 | #endif | 40 | #endif |
47 | 41 | ||
48 | #ifndef EECONFIG_LED_MATRIX | 42 | #if !defined(LED_MATRIX_MAXIMUM_BRIGHTNESS) || LED_MATRIX_MAXIMUM_BRIGHTNESS > UINT8_MAX |
49 | # define EECONFIG_LED_MATRIX EECONFIG_RGBLIGHT | 43 | # undef LED_MATRIX_MAXIMUM_BRIGHTNESS |
44 | # define LED_MATRIX_MAXIMUM_BRIGHTNESS UINT8_MAX | ||
50 | #endif | 45 | #endif |
51 | 46 | ||
52 | #if !defined(LED_MATRIX_MAXIMUM_BRIGHTNESS) || LED_MATRIX_MAXIMUM_BRIGHTNESS > 255 | 47 | #if !defined(LED_MATRIX_VAL_STEP) |
53 | # define LED_MATRIX_MAXIMUM_BRIGHTNESS 255 | 48 | # define LED_MATRIX_VAL_STEP 8 |
54 | #endif | 49 | #endif |
55 | 50 | ||
56 | bool g_suspend_state = false; | 51 | #if !defined(LED_MATRIX_SPD_STEP) |
52 | # define LED_MATRIX_SPD_STEP 16 | ||
53 | #endif | ||
57 | 54 | ||
58 | // Global tick at 20 Hz | 55 | #if !defined(LED_MATRIX_STARTUP_MODE) |
59 | uint32_t g_tick = 0; | 56 | # define LED_MATRIX_STARTUP_MODE LED_MATRIX_UNIFORM_BRIGHTNESS |
57 | #endif | ||
60 | 58 | ||
61 | // Ticks since this key was last hit. | 59 | #if !defined(LED_MATRIX_STARTUP_VAL) |
62 | uint8_t g_key_hit[DRIVER_LED_TOTAL]; | 60 | # define LED_MATRIX_STARTUP_VAL LED_MATRIX_MAXIMUM_BRIGHTNESS |
61 | #endif | ||
63 | 62 | ||
64 | // Ticks since any key was last hit. | 63 | #if !defined(LED_MATRIX_STARTUP_SPD) |
65 | uint32_t g_any_key_hit = 0; | 64 | # define LED_MATRIX_STARTUP_SPD UINT8_MAX / 2 |
65 | #endif | ||
66 | 66 | ||
67 | uint32_t eeconfig_read_led_matrix(void) { return eeprom_read_dword(EECONFIG_LED_MATRIX); } | 67 | // globals |
68 | bool g_suspend_state = false; | ||
69 | led_eeconfig_t led_matrix_eeconfig; // TODO: would like to prefix this with g_ for global consistancy, do this in another pr | ||
70 | uint32_t g_led_timer; | ||
71 | #ifdef LED_MATRIX_FRAMEBUFFER_EFFECTS | ||
72 | uint8_t g_led_frame_buffer[MATRIX_ROWS][MATRIX_COLS] = {{0}}; | ||
73 | #endif // LED_MATRIX_FRAMEBUFFER_EFFECTS | ||
74 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED | ||
75 | last_hit_t g_last_hit_tracker; | ||
76 | #endif // LED_MATRIX_KEYREACTIVE_ENABLED | ||
77 | |||
78 | // internals | ||
79 | static uint8_t led_last_enable = UINT8_MAX; | ||
80 | static uint8_t led_last_effect = UINT8_MAX; | ||
81 | static effect_params_t led_effect_params = {0, LED_FLAG_ALL, false}; | ||
82 | static led_task_states led_task_state = SYNCING; | ||
83 | #if LED_DISABLE_TIMEOUT > 0 | ||
84 | static uint32_t led_anykey_timer; | ||
85 | #endif // LED_DISABLE_TIMEOUT > 0 | ||
86 | |||
87 | // double buffers | ||
88 | static uint32_t led_timer_buffer; | ||
89 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED | ||
90 | static last_hit_t last_hit_buffer; | ||
91 | #endif // LED_MATRIX_KEYREACTIVE_ENABLED | ||
92 | |||
93 | // split led matrix | ||
94 | #if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
95 | const uint8_t k_led_matrix_split[2] = LED_MATRIX_SPLIT; | ||
96 | #endif | ||
68 | 97 | ||
69 | void eeconfig_update_led_matrix(uint32_t config_value) { eeprom_update_dword(EECONFIG_LED_MATRIX, config_value); } | 98 | void eeconfig_read_led_matrix(void) { eeprom_read_block(&led_matrix_eeconfig, EECONFIG_LED_MATRIX, sizeof(led_matrix_eeconfig)); } |
99 | |||
100 | void eeconfig_update_led_matrix(void) { eeprom_update_block(&led_matrix_eeconfig, EECONFIG_LED_MATRIX, sizeof(led_matrix_eeconfig)); } | ||
70 | 101 | ||
71 | void eeconfig_update_led_matrix_default(void) { | 102 | void eeconfig_update_led_matrix_default(void) { |
72 | dprintf("eeconfig_update_led_matrix_default\n"); | 103 | dprintf("eeconfig_update_led_matrix_default\n"); |
73 | led_matrix_eeconfig.enable = 1; | 104 | led_matrix_eeconfig.enable = 1; |
74 | led_matrix_eeconfig.mode = LED_MATRIX_UNIFORM_BRIGHTNESS; | 105 | led_matrix_eeconfig.mode = LED_MATRIX_STARTUP_MODE; |
75 | led_matrix_eeconfig.val = 128; | 106 | led_matrix_eeconfig.val = LED_MATRIX_STARTUP_VAL; |
76 | led_matrix_eeconfig.speed = 0; | 107 | led_matrix_eeconfig.speed = LED_MATRIX_STARTUP_SPD; |
77 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 108 | led_matrix_eeconfig.flags = LED_FLAG_ALL; |
109 | eeconfig_update_led_matrix(); | ||
78 | } | 110 | } |
79 | 111 | ||
80 | void eeconfig_debug_led_matrix(void) { | 112 | void eeconfig_debug_led_matrix(void) { |
81 | dprintf("led_matrix_eeconfig eeprom\n"); | 113 | dprintf("led_matrix_eeconfig EEPROM\n"); |
82 | dprintf("led_matrix_eeconfig.enable = %d\n", led_matrix_eeconfig.enable); | 114 | dprintf("led_matrix_eeconfig.enable = %d\n", led_matrix_eeconfig.enable); |
83 | dprintf("led_matrix_eeconfig.mode = %d\n", led_matrix_eeconfig.mode); | 115 | dprintf("led_matrix_eeconfig.mode = %d\n", led_matrix_eeconfig.mode); |
84 | dprintf("led_matrix_eeconfig.val = %d\n", led_matrix_eeconfig.val); | 116 | dprintf("led_matrix_eeconfig.val = %d\n", led_matrix_eeconfig.val); |
85 | dprintf("led_matrix_eeconfig.speed = %d\n", led_matrix_eeconfig.speed); | 117 | dprintf("led_matrix_eeconfig.speed = %d\n", led_matrix_eeconfig.speed); |
118 | dprintf("led_matrix_eeconfig.flags = %d\n", led_matrix_eeconfig.flags); | ||
86 | } | 119 | } |
87 | 120 | ||
88 | uint8_t g_last_led_hit[LED_HITS_TO_REMEMBER] = {255}; | 121 | __attribute__((weak)) uint8_t led_matrix_map_row_column_to_led_kb(uint8_t row, uint8_t column, uint8_t *led_i) { return 0; } |
89 | uint8_t g_last_led_count = 0; | ||
90 | 122 | ||
91 | uint8_t map_row_column_to_led(uint8_t row, uint8_t column, uint8_t *led_i) { | 123 | uint8_t led_matrix_map_row_column_to_led(uint8_t row, uint8_t column, uint8_t *led_i) { |
92 | uint8_t led_count = 0; | 124 | uint8_t led_count = led_matrix_map_row_column_to_led_kb(row, column, led_i); |
93 | uint8_t led_index = g_led_config.matrix_co[row][column]; | 125 | uint8_t led_index = g_led_config.matrix_co[row][column]; |
94 | if (led_index != NO_LED) { | 126 | if (led_index != NO_LED) { |
95 | led_i[led_count] = led_index; | 127 | led_i[led_count] = led_index; |
@@ -100,88 +132,227 @@ uint8_t map_row_column_to_led(uint8_t row, uint8_t column, uint8_t *led_i) { | |||
100 | 132 | ||
101 | void led_matrix_update_pwm_buffers(void) { led_matrix_driver.flush(); } | 133 | void led_matrix_update_pwm_buffers(void) { led_matrix_driver.flush(); } |
102 | 134 | ||
103 | void led_matrix_set_index_value(int index, uint8_t value) { led_matrix_driver.set_value(index, value); } | 135 | void led_matrix_set_value(int index, uint8_t value) { |
104 | 136 | #if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | |
105 | void led_matrix_set_index_value_all(uint8_t value) { led_matrix_driver.set_value_all(value); } | 137 | if (!is_keyboard_left() && index >= k_led_matrix_split[0]) |
106 | 138 | # ifdef USE_CIE1931_CURVE | |
107 | bool process_led_matrix(uint16_t keycode, keyrecord_t *record) { | 139 | led_matrix_driver.set_value(index - k_led_matrix_split[0], pgm_read_byte(&CIE1931_CURVE[value])); |
108 | if (record->event.pressed) { | 140 | # else |
109 | uint8_t led[8]; | 141 | led_matrix_driver.set_value(index - k_led_matrix_split[0], value); |
110 | uint8_t led_count = map_row_column_to_led(record->event.key.row, record->event.key.col, led); | 142 | # endif |
111 | if (led_count > 0) { | 143 | else if (is_keyboard_left() && index < k_led_matrix_split[0]) |
112 | for (uint8_t i = LED_HITS_TO_REMEMBER; i > 1; i--) { | 144 | #endif |
113 | g_last_led_hit[i - 1] = g_last_led_hit[i - 2]; | 145 | #ifdef USE_CIE1931_CURVE |
114 | } | 146 | led_matrix_driver.set_value(index, pgm_read_byte(&CIE1931_CURVE[value])); |
115 | g_last_led_hit[0] = led[0]; | 147 | #else |
116 | g_last_led_count = MIN(LED_HITS_TO_REMEMBER, g_last_led_count + 1); | 148 | led_matrix_driver.set_value(index, value); |
117 | } | 149 | #endif |
118 | for (uint8_t i = 0; i < led_count; i++) g_key_hit[led[i]] = 0; | 150 | } |
119 | g_any_key_hit = 0; | ||
120 | } else { | ||
121 | #ifdef LED_MATRIX_KEYRELEASES | ||
122 | uint8_t led[8]; | ||
123 | uint8_t led_count = map_row_column_to_led(record->event.key.row, record->event.key.col, led); | ||
124 | for (uint8_t i = 0; i < led_count; i++) g_key_hit[led[i]] = 255; | ||
125 | 151 | ||
126 | g_any_key_hit = 255; | 152 | void led_matrix_set_value_all(uint8_t value) { |
153 | #if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
154 | for (uint8_t i = 0; i < DRIVER_LED_TOTAL; i++) led_matrix_set_value(i, value); | ||
155 | #else | ||
156 | # ifdef USE_CIE1931_CURVE | ||
157 | led_matrix_driver.set_value_all(pgm_read_byte(&CIE1931_CURVE[value])); | ||
158 | # else | ||
159 | led_matrix_driver.set_value_all(value); | ||
160 | # endif | ||
127 | #endif | 161 | #endif |
128 | } | ||
129 | return true; | ||
130 | } | 162 | } |
131 | 163 | ||
132 | void led_matrix_set_suspend_state(bool state) { g_suspend_state = state; } | 164 | void process_led_matrix(uint8_t row, uint8_t col, bool pressed) { |
165 | #ifndef LED_MATRIX_SPLIT | ||
166 | if (!is_keyboard_master()) return; | ||
167 | #endif | ||
168 | #if LED_DISABLE_TIMEOUT > 0 | ||
169 | led_anykey_timer = 0; | ||
170 | #endif // LED_DISABLE_TIMEOUT > 0 | ||
133 | 171 | ||
134 | // All LEDs off | 172 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED |
135 | void led_matrix_all_off(void) { led_matrix_set_index_value_all(0); } | 173 | uint8_t led[LED_HITS_TO_REMEMBER]; |
174 | uint8_t led_count = 0; | ||
136 | 175 | ||
137 | // Uniform brightness | 176 | # if defined(LED_MATRIX_KEYRELEASES) |
138 | void led_matrix_uniform_brightness(void) { led_matrix_set_index_value_all(LED_MATRIX_MAXIMUM_BRIGHTNESS / BACKLIGHT_LEVELS * led_matrix_eeconfig.val); } | 177 | if (!pressed) |
178 | # elif defined(LED_MATRIX_KEYPRESSES) | ||
179 | if (pressed) | ||
180 | # endif // defined(LED_MATRIX_KEYRELEASES) | ||
181 | { | ||
182 | led_count = led_matrix_map_row_column_to_led(row, col, led); | ||
183 | } | ||
139 | 184 | ||
140 | void led_matrix_custom(void) {} | 185 | if (last_hit_buffer.count + led_count > LED_HITS_TO_REMEMBER) { |
186 | memcpy(&last_hit_buffer.x[0], &last_hit_buffer.x[led_count], LED_HITS_TO_REMEMBER - led_count); | ||
187 | memcpy(&last_hit_buffer.y[0], &last_hit_buffer.y[led_count], LED_HITS_TO_REMEMBER - led_count); | ||
188 | memcpy(&last_hit_buffer.tick[0], &last_hit_buffer.tick[led_count], (LED_HITS_TO_REMEMBER - led_count) * 2); // 16 bit | ||
189 | memcpy(&last_hit_buffer.index[0], &last_hit_buffer.index[led_count], LED_HITS_TO_REMEMBER - led_count); | ||
190 | last_hit_buffer.count--; | ||
191 | } | ||
141 | 192 | ||
142 | void led_matrix_task(void) { | 193 | for (uint8_t i = 0; i < led_count; i++) { |
143 | if (!led_matrix_eeconfig.enable) { | 194 | uint8_t index = last_hit_buffer.count; |
144 | led_matrix_all_off(); | 195 | last_hit_buffer.x[index] = g_led_config.point[led[i]].x; |
145 | led_matrix_indicators(); | 196 | last_hit_buffer.y[index] = g_led_config.point[led[i]].y; |
146 | return; | 197 | last_hit_buffer.index[index] = led[i]; |
198 | last_hit_buffer.tick[index] = 0; | ||
199 | last_hit_buffer.count++; | ||
147 | } | 200 | } |
201 | #endif // LED_MATRIX_KEYREACTIVE_ENABLED | ||
148 | 202 | ||
149 | g_tick++; | 203 | #if defined(LED_MATRIX_FRAMEBUFFER_EFFECTS) && !defined(DISABLE_LED_MATRIX_TYPING_HEATMAP) |
204 | if (led_matrix_eeconfig.mode == LED_MATRIX_TYPING_HEATMAP) { | ||
205 | process_led_matrix_typing_heatmap(row, col); | ||
206 | } | ||
207 | #endif // defined(LED_MATRIX_FRAMEBUFFER_EFFECTS) && !defined(DISABLE_LED_MATRIX_TYPING_HEATMAP) | ||
208 | } | ||
150 | 209 | ||
151 | if (g_any_key_hit < 0xFFFFFFFF) { | 210 | static bool led_matrix_none(effect_params_t *params) { |
152 | g_any_key_hit++; | 211 | if (!params->init) { |
212 | return false; | ||
153 | } | 213 | } |
154 | 214 | ||
155 | for (int led = 0; led < DRIVER_LED_TOTAL; led++) { | 215 | led_matrix_set_value_all(0); |
156 | if (g_key_hit[led] < 255) { | 216 | return false; |
157 | if (g_key_hit[led] == 254) g_last_led_count = MAX(g_last_led_count - 1, 0); | 217 | } |
158 | g_key_hit[led]++; | 218 | |
219 | static bool led_matrix_uniform_brightness(effect_params_t *params) { | ||
220 | LED_MATRIX_USE_LIMITS(led_min, led_max); | ||
221 | |||
222 | uint8_t val = led_matrix_eeconfig.val; | ||
223 | for (uint8_t i = led_min; i < led_max; i++) { | ||
224 | LED_MATRIX_TEST_LED_FLAGS(); | ||
225 | led_matrix_set_value(i, val); | ||
226 | } | ||
227 | return led_max < DRIVER_LED_TOTAL; | ||
228 | } | ||
229 | |||
230 | static void led_task_timers(void) { | ||
231 | #if defined(LED_MATRIX_KEYREACTIVE_ENABLED) || LED_DISABLE_TIMEOUT > 0 | ||
232 | uint32_t deltaTime = sync_timer_elapsed32(led_timer_buffer); | ||
233 | #endif // defined(LED_MATRIX_KEYREACTIVE_ENABLED) || LED_DISABLE_TIMEOUT > 0 | ||
234 | led_timer_buffer = sync_timer_read32(); | ||
235 | |||
236 | // Update double buffer timers | ||
237 | #if LED_DISABLE_TIMEOUT > 0 | ||
238 | if (led_anykey_timer < UINT32_MAX) { | ||
239 | if (UINT32_MAX - deltaTime < led_anykey_timer) { | ||
240 | led_anykey_timer = UINT32_MAX; | ||
241 | } else { | ||
242 | led_anykey_timer += deltaTime; | ||
243 | } | ||
244 | } | ||
245 | #endif // LED_DISABLE_TIMEOUT > 0 | ||
246 | |||
247 | // Update double buffer last hit timers | ||
248 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED | ||
249 | uint8_t count = last_hit_buffer.count; | ||
250 | for (uint8_t i = 0; i < count; ++i) { | ||
251 | if (UINT16_MAX - deltaTime < last_hit_buffer.tick[i]) { | ||
252 | last_hit_buffer.count--; | ||
253 | continue; | ||
159 | } | 254 | } |
255 | last_hit_buffer.tick[i] += deltaTime; | ||
160 | } | 256 | } |
257 | #endif // LED_MATRIX_KEYREACTIVE_ENABLED | ||
258 | } | ||
161 | 259 | ||
162 | // Ideally we would also stop sending zeros to the LED driver PWM buffers | 260 | static void led_task_sync(void) { |
163 | // while suspended and just do a software shutdown. This is a cheap hack for now. | 261 | // next task |
164 | bool suspend_backlight = ((g_suspend_state && LED_DISABLE_WHEN_USB_SUSPENDED) || (LED_DISABLE_AFTER_TIMEOUT > 0 && g_any_key_hit > LED_DISABLE_AFTER_TIMEOUT * 60 * 20)); | 262 | if (sync_timer_elapsed32(g_led_timer) >= LED_MATRIX_LED_FLUSH_LIMIT) led_task_state = STARTING; |
165 | uint8_t effect = suspend_backlight ? 0 : led_matrix_eeconfig.mode; | 263 | } |
264 | |||
265 | static void led_task_start(void) { | ||
266 | // reset iter | ||
267 | led_effect_params.iter = 0; | ||
268 | |||
269 | // update double buffers | ||
270 | g_led_timer = led_timer_buffer; | ||
271 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED | ||
272 | g_last_hit_tracker = last_hit_buffer; | ||
273 | #endif // LED_MATRIX_KEYREACTIVE_ENABLED | ||
274 | |||
275 | // next task | ||
276 | led_task_state = RENDERING; | ||
277 | } | ||
278 | |||
279 | static void led_task_render(uint8_t effect) { | ||
280 | bool rendering = false; | ||
281 | led_effect_params.init = (effect != led_last_effect) || (led_matrix_eeconfig.enable != led_last_enable); | ||
282 | if (led_effect_params.flags != led_matrix_eeconfig.flags) { | ||
283 | led_effect_params.flags = led_matrix_eeconfig.flags; | ||
284 | led_matrix_set_value_all(0); | ||
285 | } | ||
166 | 286 | ||
167 | // this gets ticked at 20 Hz. | ||
168 | // each effect can opt to do calculations | 287 | // each effect can opt to do calculations |
169 | // and/or request PWM buffer updates. | 288 | // and/or request PWM buffer updates. |
170 | switch (effect) { | 289 | switch (effect) { |
171 | case LED_MATRIX_UNIFORM_BRIGHTNESS: | 290 | case LED_MATRIX_NONE: |
172 | led_matrix_uniform_brightness(); | 291 | rendering = led_matrix_none(&led_effect_params); |
173 | break; | 292 | break; |
174 | default: | 293 | case LED_MATRIX_UNIFORM_BRIGHTNESS: |
175 | led_matrix_custom(); | 294 | rendering = led_matrix_uniform_brightness(&led_effect_params); |
176 | break; | 295 | break; |
177 | } | 296 | } |
178 | 297 | ||
179 | if (!suspend_backlight) { | 298 | led_effect_params.iter++; |
180 | led_matrix_indicators(); | 299 | |
300 | // next task | ||
301 | if (!rendering) { | ||
302 | led_task_state = FLUSHING; | ||
303 | if (!led_effect_params.init && effect == LED_MATRIX_NONE) { | ||
304 | // We only need to flush once if we are LED_MATRIX_NONE | ||
305 | led_task_state = SYNCING; | ||
306 | } | ||
181 | } | 307 | } |
308 | } | ||
182 | 309 | ||
183 | // Tell the LED driver to update its state | 310 | static void led_task_flush(uint8_t effect) { |
184 | led_matrix_driver.flush(); | 311 | // update last trackers after the first full render so we can init over several frames |
312 | led_last_effect = effect; | ||
313 | led_last_enable = led_matrix_eeconfig.enable; | ||
314 | |||
315 | // update pwm buffers | ||
316 | led_matrix_update_pwm_buffers(); | ||
317 | |||
318 | // next task | ||
319 | led_task_state = SYNCING; | ||
320 | } | ||
321 | |||
322 | void led_matrix_task(void) { | ||
323 | led_task_timers(); | ||
324 | |||
325 | // Ideally we would also stop sending zeros to the LED driver PWM buffers | ||
326 | // while suspended and just do a software shutdown. This is a cheap hack for now. | ||
327 | bool suspend_backlight = | ||
328 | #if LED_DISABLE_WHEN_USB_SUSPENDED == true | ||
329 | g_suspend_state || | ||
330 | #endif // LED_DISABLE_WHEN_USB_SUSPENDED == true | ||
331 | #if LED_DISABLE_TIMEOUT > 0 | ||
332 | (led_anykey_timer > (uint32_t)LED_DISABLE_TIMEOUT) || | ||
333 | #endif // LED_DISABLE_TIMEOUT > 0 | ||
334 | false; | ||
335 | |||
336 | uint8_t effect = suspend_backlight || !led_matrix_eeconfig.enable ? 0 : led_matrix_eeconfig.mode; | ||
337 | |||
338 | switch (led_task_state) { | ||
339 | case STARTING: | ||
340 | led_task_start(); | ||
341 | break; | ||
342 | case RENDERING: | ||
343 | led_task_render(effect); | ||
344 | if (effect) { | ||
345 | led_matrix_indicators(); | ||
346 | led_matrix_indicators_advanced(&led_effect_params); | ||
347 | } | ||
348 | break; | ||
349 | case FLUSHING: | ||
350 | led_task_flush(effect); | ||
351 | break; | ||
352 | case SYNCING: | ||
353 | led_task_sync(); | ||
354 | break; | ||
355 | } | ||
185 | } | 356 | } |
186 | 357 | ||
187 | void led_matrix_indicators(void) { | 358 | void led_matrix_indicators(void) { |
@@ -193,33 +364,42 @@ __attribute__((weak)) void led_matrix_indicators_kb(void) {} | |||
193 | 364 | ||
194 | __attribute__((weak)) void led_matrix_indicators_user(void) {} | 365 | __attribute__((weak)) void led_matrix_indicators_user(void) {} |
195 | 366 | ||
196 | // void led_matrix_set_indicator_index(uint8_t *index, uint8_t row, uint8_t column) | 367 | void led_matrix_indicators_advanced(effect_params_t *params) { |
197 | // { | 368 | /* special handling is needed for "params->iter", since it's already been incremented. |
198 | // if (row >= MATRIX_ROWS) | 369 | * Could move the invocations to led_task_render, but then it's missing a few checks |
199 | // { | 370 | * and not sure which would be better. Otherwise, this should be called from |
200 | // // Special value, 255=none, 254=all | 371 | * led_task_render, right before the iter++ line. |
201 | // *index = row; | 372 | */ |
202 | // } | 373 | #if defined(LED_MATRIX_LED_PROCESS_LIMIT) && LED_MATRIX_LED_PROCESS_LIMIT > 0 && LED_MATRIX_LED_PROCESS_LIMIT < DRIVER_LED_TOTAL |
203 | // else | 374 | uint8_t min = LED_MATRIX_LED_PROCESS_LIMIT * (params->iter - 1); |
204 | // { | 375 | uint8_t max = min + LED_MATRIX_LED_PROCESS_LIMIT; |
205 | // // This needs updated to something like | 376 | if (max > DRIVER_LED_TOTAL) max = DRIVER_LED_TOTAL; |
206 | // // uint8_t led[8]; | 377 | #else |
207 | // // uint8_t led_count = map_row_column_to_led(row, column, led); | 378 | uint8_t min = 0; |
208 | // // for(uint8_t i = 0; i < led_count; i++) | 379 | uint8_t max = DRIVER_LED_TOTAL; |
209 | // map_row_column_to_led(row, column, index); | 380 | #endif |
210 | // } | 381 | led_matrix_indicators_advanced_kb(min, max); |
211 | // } | 382 | led_matrix_indicators_advanced_user(min, max); |
383 | } | ||
384 | |||
385 | __attribute__((weak)) void led_matrix_indicators_advanced_kb(uint8_t led_min, uint8_t led_max) {} | ||
386 | |||
387 | __attribute__((weak)) void led_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {} | ||
212 | 388 | ||
213 | void led_matrix_init(void) { | 389 | void led_matrix_init(void) { |
214 | led_matrix_driver.init(); | 390 | led_matrix_driver.init(); |
215 | 391 | ||
216 | // Wait half a second for the driver to finish initializing | 392 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED |
217 | wait_ms(500); | 393 | g_last_hit_tracker.count = 0; |
394 | for (uint8_t i = 0; i < LED_HITS_TO_REMEMBER; ++i) { | ||
395 | g_last_hit_tracker.tick[i] = UINT16_MAX; | ||
396 | } | ||
218 | 397 | ||
219 | // clear the key hits | 398 | last_hit_buffer.count = 0; |
220 | for (int led = 0; led < DRIVER_LED_TOTAL; led++) { | 399 | for (uint8_t i = 0; i < LED_HITS_TO_REMEMBER; ++i) { |
221 | g_key_hit[led] = 255; | 400 | last_hit_buffer.tick[i] = UINT16_MAX; |
222 | } | 401 | } |
402 | #endif // LED_MATRIX_KEYREACTIVE_ENABLED | ||
223 | 403 | ||
224 | if (!eeconfig_is_enabled()) { | 404 | if (!eeconfig_is_enabled()) { |
225 | dprintf("led_matrix_init_drivers eeconfig is not enabled.\n"); | 405 | dprintf("led_matrix_init_drivers eeconfig is not enabled.\n"); |
@@ -227,122 +407,135 @@ void led_matrix_init(void) { | |||
227 | eeconfig_update_led_matrix_default(); | 407 | eeconfig_update_led_matrix_default(); |
228 | } | 408 | } |
229 | 409 | ||
230 | led_matrix_eeconfig.raw = eeconfig_read_led_matrix(); | 410 | eeconfig_read_led_matrix(); |
231 | |||
232 | if (!led_matrix_eeconfig.mode) { | 411 | if (!led_matrix_eeconfig.mode) { |
233 | dprintf("led_matrix_init_drivers led_matrix_eeconfig.mode = 0. Write default values to EEPROM.\n"); | 412 | dprintf("led_matrix_init_drivers led_matrix_eeconfig.mode = 0. Write default values to EEPROM.\n"); |
234 | eeconfig_update_led_matrix_default(); | 413 | eeconfig_update_led_matrix_default(); |
235 | led_matrix_eeconfig.raw = eeconfig_read_led_matrix(); | ||
236 | } | 414 | } |
237 | |||
238 | eeconfig_debug_led_matrix(); // display current eeprom values | 415 | eeconfig_debug_led_matrix(); // display current eeprom values |
239 | } | 416 | } |
240 | 417 | ||
241 | // Deals with the messy details of incrementing an integer | 418 | void led_matrix_set_suspend_state(bool state) { |
242 | static uint8_t increment(uint8_t value, uint8_t step, uint8_t min, uint8_t max) { | 419 | if (LED_DISABLE_WHEN_USB_SUSPENDED && state) { |
243 | int16_t new_value = value; | 420 | led_matrix_set_value_all(0); // turn off all LEDs when suspending |
244 | new_value += step; | 421 | } |
245 | return MIN(MAX(new_value, min), max); | 422 | g_suspend_state = state; |
246 | } | 423 | } |
247 | 424 | ||
248 | static uint8_t decrement(uint8_t value, uint8_t step, uint8_t min, uint8_t max) { | 425 | bool led_matrix_get_suspend_state(void) { return g_suspend_state; } |
249 | int16_t new_value = value; | ||
250 | new_value -= step; | ||
251 | return MIN(MAX(new_value, min), max); | ||
252 | } | ||
253 | 426 | ||
254 | // void *backlight_get_custom_key_value_eeprom_address(uint8_t led) { | 427 | void led_matrix_toggle_eeprom_helper(bool write_to_eeprom) { |
255 | // // 3 bytes per value | ||
256 | // return EECONFIG_LED_MATRIX + (led * 3); | ||
257 | // } | ||
258 | |||
259 | // void backlight_get_key_value(uint8_t led, uint8_t *value) { | ||
260 | // void *address = backlight_get_custom_key_value_eeprom_address(led); | ||
261 | // value = eeprom_read_byte(address); | ||
262 | // } | ||
263 | |||
264 | // void backlight_set_key_value(uint8_t row, uint8_t column, uint8_t value) { | ||
265 | // uint8_t led[8]; | ||
266 | // uint8_t led_count = map_row_column_to_led(row, column, led); | ||
267 | // for(uint8_t i = 0; i < led_count; i++) { | ||
268 | // if (led[i] < DRIVER_LED_TOTAL) { | ||
269 | // void *address = backlight_get_custom_key_value_eeprom_address(led[i]); | ||
270 | // eeprom_update_byte(address, value); | ||
271 | // } | ||
272 | // } | ||
273 | // } | ||
274 | |||
275 | uint32_t led_matrix_get_tick(void) { return g_tick; } | ||
276 | |||
277 | void led_matrix_toggle(void) { | ||
278 | led_matrix_eeconfig.enable ^= 1; | 428 | led_matrix_eeconfig.enable ^= 1; |
279 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 429 | led_task_state = STARTING; |
430 | if (write_to_eeprom) { | ||
431 | eeconfig_update_led_matrix(); | ||
432 | } | ||
433 | dprintf("led matrix toggle [%s]: led_matrix_eeconfig.enable = %u\n", (write_to_eeprom) ? "EEPROM" : "NOEEPROM", led_matrix_eeconfig.enable); | ||
280 | } | 434 | } |
435 | void led_matrix_toggle_noeeprom(void) { led_matrix_toggle_eeprom_helper(false); } | ||
436 | void led_matrix_toggle(void) { led_matrix_toggle_eeprom_helper(true); } | ||
281 | 437 | ||
282 | void led_matrix_enable(void) { | 438 | void led_matrix_enable(void) { |
283 | led_matrix_eeconfig.enable = 1; | 439 | led_matrix_enable_noeeprom(); |
284 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 440 | eeconfig_update_led_matrix(); |
285 | } | 441 | } |
286 | 442 | ||
287 | void led_matrix_enable_noeeprom(void) { led_matrix_eeconfig.enable = 1; } | 443 | void led_matrix_enable_noeeprom(void) { |
444 | if (!led_matrix_eeconfig.enable) led_task_state = STARTING; | ||
445 | led_matrix_eeconfig.enable = 1; | ||
446 | } | ||
288 | 447 | ||
289 | void led_matrix_disable(void) { | 448 | void led_matrix_disable(void) { |
449 | led_matrix_disable_noeeprom(); | ||
450 | eeconfig_update_led_matrix(); | ||
451 | } | ||
452 | |||
453 | void led_matrix_disable_noeeprom(void) { | ||
454 | if (led_matrix_eeconfig.enable) led_task_state = STARTING; | ||
290 | led_matrix_eeconfig.enable = 0; | 455 | led_matrix_eeconfig.enable = 0; |
291 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | ||
292 | } | 456 | } |
293 | 457 | ||
294 | void led_matrix_disable_noeeprom(void) { led_matrix_eeconfig.enable = 0; } | 458 | uint8_t led_matrix_is_enabled(void) { return led_matrix_eeconfig.enable; } |
295 | 459 | ||
296 | void led_matrix_step(void) { | 460 | void led_matrix_mode_eeprom_helper(uint8_t mode, bool write_to_eeprom) { |
297 | led_matrix_eeconfig.mode++; | 461 | if (!led_matrix_eeconfig.enable) { |
298 | if (led_matrix_eeconfig.mode >= LED_MATRIX_EFFECT_MAX) { | 462 | return; |
299 | led_matrix_eeconfig.mode = 1; | ||
300 | } | 463 | } |
301 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 464 | if (mode < 1) { |
302 | } | 465 | led_matrix_eeconfig.mode = 1; |
303 | 466 | } else if (mode >= LED_MATRIX_EFFECT_MAX) { | |
304 | void led_matrix_step_reverse(void) { | ||
305 | led_matrix_eeconfig.mode--; | ||
306 | if (led_matrix_eeconfig.mode < 1) { | ||
307 | led_matrix_eeconfig.mode = LED_MATRIX_EFFECT_MAX - 1; | 467 | led_matrix_eeconfig.mode = LED_MATRIX_EFFECT_MAX - 1; |
468 | } else { | ||
469 | led_matrix_eeconfig.mode = mode; | ||
470 | } | ||
471 | led_task_state = STARTING; | ||
472 | if (write_to_eeprom) { | ||
473 | eeconfig_update_led_matrix(); | ||
308 | } | 474 | } |
309 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 475 | dprintf("led matrix mode [%s]: %u\n", (write_to_eeprom) ? "EEPROM" : "NOEEPROM", led_matrix_eeconfig.mode); |
310 | } | 476 | } |
477 | void led_matrix_mode_noeeprom(uint8_t mode) { led_matrix_mode_eeprom_helper(mode, false); } | ||
478 | void led_matrix_mode(uint8_t mode) { led_matrix_mode_eeprom_helper(mode, true); } | ||
311 | 479 | ||
312 | void led_matrix_increase_val(void) { | 480 | uint8_t led_matrix_get_mode(void) { return led_matrix_eeconfig.mode; } |
313 | led_matrix_eeconfig.val = increment(led_matrix_eeconfig.val, 8, 0, LED_MATRIX_MAXIMUM_BRIGHTNESS); | ||
314 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | ||
315 | } | ||
316 | 481 | ||
317 | void led_matrix_decrease_val(void) { | 482 | void led_matrix_step_helper(bool write_to_eeprom) { |
318 | led_matrix_eeconfig.val = decrement(led_matrix_eeconfig.val, 8, 0, LED_MATRIX_MAXIMUM_BRIGHTNESS); | 483 | uint8_t mode = led_matrix_eeconfig.mode + 1; |
319 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 484 | led_matrix_mode_eeprom_helper((mode < LED_MATRIX_EFFECT_MAX) ? mode : 1, write_to_eeprom); |
320 | } | 485 | } |
486 | void led_matrix_step_noeeprom(void) { led_matrix_step_helper(false); } | ||
487 | void led_matrix_step(void) { led_matrix_step_helper(true); } | ||
321 | 488 | ||
322 | void led_matrix_increase_speed(void) { | 489 | void led_matrix_step_reverse_helper(bool write_to_eeprom) { |
323 | led_matrix_eeconfig.speed = increment(led_matrix_eeconfig.speed, 1, 0, 3); | 490 | uint8_t mode = led_matrix_eeconfig.mode - 1; |
324 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); // EECONFIG needs to be increased to support this | 491 | led_matrix_mode_eeprom_helper((mode < 1) ? LED_MATRIX_EFFECT_MAX - 1 : mode, write_to_eeprom); |
325 | } | 492 | } |
493 | void led_matrix_step_reverse_noeeprom(void) { led_matrix_step_reverse_helper(false); } | ||
494 | void led_matrix_step_reverse(void) { led_matrix_step_reverse_helper(true); } | ||
326 | 495 | ||
327 | void led_matrix_decrease_speed(void) { | 496 | void led_matrix_set_val_eeprom_helper(uint8_t val, bool write_to_eeprom) { |
328 | led_matrix_eeconfig.speed = decrement(led_matrix_eeconfig.speed, 1, 0, 3); | 497 | if (!led_matrix_eeconfig.enable) { |
329 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); // EECONFIG needs to be increased to support this | 498 | return; |
499 | } | ||
500 | led_matrix_eeconfig.val = (val > LED_MATRIX_MAXIMUM_BRIGHTNESS) ? LED_MATRIX_MAXIMUM_BRIGHTNESS : val; | ||
501 | if (write_to_eeprom) { | ||
502 | eeconfig_update_led_matrix(); | ||
503 | } | ||
504 | dprintf("led matrix set val [%s]: %u\n", (write_to_eeprom) ? "EEPROM" : "NOEEPROM", led_matrix_eeconfig.val); | ||
330 | } | 505 | } |
506 | void led_matrix_set_val_noeeprom(uint8_t val) { led_matrix_set_val_eeprom_helper(val, false); } | ||
507 | void led_matrix_set_val(uint8_t val) { led_matrix_set_val_eeprom_helper(val, true); } | ||
331 | 508 | ||
332 | void led_matrix_mode(uint8_t mode, bool eeprom_write) { | 509 | uint8_t led_matrix_get_val(void) { return led_matrix_eeconfig.val; } |
333 | led_matrix_eeconfig.mode = mode; | 510 | |
334 | if (eeprom_write) { | 511 | void led_matrix_increase_val_helper(bool write_to_eeprom) { led_matrix_set_val_eeprom_helper(qadd8(led_matrix_eeconfig.val, LED_MATRIX_VAL_STEP), write_to_eeprom); } |
335 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 512 | void led_matrix_increase_val_noeeprom(void) { led_matrix_increase_val_helper(false); } |
513 | void led_matrix_increase_val(void) { led_matrix_increase_val_helper(true); } | ||
514 | |||
515 | void led_matrix_decrease_val_helper(bool write_to_eeprom) { led_matrix_set_val_eeprom_helper(qsub8(led_matrix_eeconfig.val, LED_MATRIX_VAL_STEP), write_to_eeprom); } | ||
516 | void led_matrix_decrease_val_noeeprom(void) { led_matrix_decrease_val_helper(false); } | ||
517 | void led_matrix_decrease_val(void) { led_matrix_decrease_val_helper(true); } | ||
518 | |||
519 | void led_matrix_set_speed_eeprom_helper(uint8_t speed, bool write_to_eeprom) { | ||
520 | led_matrix_eeconfig.speed = speed; | ||
521 | if (write_to_eeprom) { | ||
522 | eeconfig_update_led_matrix(); | ||
336 | } | 523 | } |
524 | dprintf("led matrix set speed [%s]: %u\n", (write_to_eeprom) ? "EEPROM" : "NOEEPROM", led_matrix_eeconfig.speed); | ||
337 | } | 525 | } |
526 | void led_matrix_set_speed_noeeprom(uint8_t speed) { led_matrix_set_speed_eeprom_helper(speed, false); } | ||
527 | void led_matrix_set_speed(uint8_t speed) { led_matrix_set_speed_eeprom_helper(speed, true); } | ||
338 | 528 | ||
339 | uint8_t led_matrix_get_mode(void) { return led_matrix_eeconfig.mode; } | 529 | uint8_t led_matrix_get_speed(void) { return led_matrix_eeconfig.speed; } |
340 | 530 | ||
341 | void led_matrix_set_value_noeeprom(uint8_t val) { led_matrix_eeconfig.val = val; } | 531 | void led_matrix_increase_speed_helper(bool write_to_eeprom) { led_matrix_set_speed_eeprom_helper(qadd8(led_matrix_eeconfig.speed, LED_MATRIX_SPD_STEP), write_to_eeprom); } |
532 | void led_matrix_increase_speed_noeeprom(void) { led_matrix_increase_speed_helper(false); } | ||
533 | void led_matrix_increase_speed(void) { led_matrix_increase_speed_helper(true); } | ||
342 | 534 | ||
343 | void led_matrix_set_value(uint8_t val) { | 535 | void led_matrix_decrease_speed_helper(bool write_to_eeprom) { led_matrix_set_speed_eeprom_helper(qsub8(led_matrix_eeconfig.speed, LED_MATRIX_SPD_STEP), write_to_eeprom); } |
344 | led_matrix_set_value_noeeprom(val); | 536 | void led_matrix_decrease_speed_noeeprom(void) { led_matrix_decrease_speed_helper(false); } |
345 | eeconfig_update_led_matrix(led_matrix_eeconfig.raw); | 537 | void led_matrix_decrease_speed(void) { led_matrix_decrease_speed_helper(true); } |
346 | } | 538 | |
539 | led_flags_t led_matrix_get_flags(void) { return led_matrix_eeconfig.flags; } | ||
347 | 540 | ||
348 | void backlight_set(uint8_t val) { led_matrix_set_value(val); } | 541 | void led_matrix_set_flags(led_flags_t flags) { led_matrix_eeconfig.flags = flags; } |
diff --git a/quantum/led_matrix.h b/quantum/led_matrix.h index 85bae43c1..f35bbe209 100644 --- a/quantum/led_matrix.h +++ b/quantum/led_matrix.h | |||
@@ -19,61 +19,104 @@ | |||
19 | 19 | ||
20 | #pragma once | 20 | #pragma once |
21 | 21 | ||
22 | #include <stdint.h> | ||
23 | #include <stdbool.h> | ||
22 | #include "led_matrix_types.h" | 24 | #include "led_matrix_types.h" |
25 | #include "quantum.h" | ||
23 | 26 | ||
24 | #ifndef BACKLIGHT_ENABLE | 27 | #ifdef IS31FL3731 |
25 | # error You must define BACKLIGHT_ENABLE with LED_MATRIX_ENABLE | 28 | # include "is31fl3731-simple.h" |
26 | #endif | 29 | #endif |
27 | 30 | ||
31 | #ifndef LED_MATRIX_LED_FLUSH_LIMIT | ||
32 | # define LED_MATRIX_LED_FLUSH_LIMIT 16 | ||
33 | #endif | ||
34 | |||
35 | #ifndef LED_MATRIX_LED_PROCESS_LIMIT | ||
36 | # define LED_MATRIX_LED_PROCESS_LIMIT (DRIVER_LED_TOTAL + 4) / 5 | ||
37 | #endif | ||
38 | |||
39 | #if defined(LED_MATRIX_LED_PROCESS_LIMIT) && LED_MATRIX_LED_PROCESS_LIMIT > 0 && LED_MATRIX_LED_PROCESS_LIMIT < DRIVER_LED_TOTAL | ||
40 | # define LED_MATRIX_USE_LIMITS(min, max) \ | ||
41 | uint8_t min = LED_MATRIX_LED_PROCESS_LIMIT * params->iter; \ | ||
42 | uint8_t max = min + LED_MATRIX_LED_PROCESS_LIMIT; \ | ||
43 | if (max > DRIVER_LED_TOTAL) max = DRIVER_LED_TOTAL; | ||
44 | #else | ||
45 | # define LED_MATRIX_USE_LIMITS(min, max) \ | ||
46 | uint8_t min = 0; \ | ||
47 | uint8_t max = DRIVER_LED_TOTAL; | ||
48 | #endif | ||
49 | |||
50 | #define LED_MATRIX_TEST_LED_FLAGS() \ | ||
51 | if (!HAS_ANY_FLAGS(g_led_config.flags[i], params->flags)) continue | ||
52 | |||
28 | enum led_matrix_effects { | 53 | enum led_matrix_effects { |
29 | LED_MATRIX_UNIFORM_BRIGHTNESS = 1, | 54 | LED_MATRIX_NONE = 0, |
55 | |||
56 | LED_MATRIX_UNIFORM_BRIGHTNESS, | ||
30 | // All new effects go above this line | 57 | // All new effects go above this line |
58 | |||
31 | LED_MATRIX_EFFECT_MAX | 59 | LED_MATRIX_EFFECT_MAX |
32 | }; | 60 | }; |
33 | 61 | ||
34 | void led_matrix_set_index_value(int index, uint8_t value); | 62 | void eeconfig_update_led_matrix_default(void); |
35 | void led_matrix_set_index_value_all(uint8_t value); | 63 | void eeconfig_update_led_matrix(void); |
64 | void eeconfig_debug_led_matrix(void); | ||
65 | |||
66 | uint8_t led_matrix_map_row_column_to_led_kb(uint8_t row, uint8_t column, uint8_t *led_i); | ||
67 | uint8_t led_matrix_map_row_column_to_led(uint8_t row, uint8_t column, uint8_t *led_i); | ||
68 | |||
69 | void led_matrix_set_value(int index, uint8_t value); | ||
70 | void led_matrix_set_value_all(uint8_t value); | ||
71 | |||
72 | void process_led_matrix(uint8_t row, uint8_t col, bool pressed); | ||
73 | |||
74 | void led_matrix_task(void); | ||
36 | 75 | ||
37 | // This runs after another backlight effect and replaces | 76 | // This runs after another backlight effect and replaces |
38 | // colors already set | 77 | // values already set |
39 | void led_matrix_indicators(void); | 78 | void led_matrix_indicators(void); |
40 | void led_matrix_indicators_kb(void); | 79 | void led_matrix_indicators_kb(void); |
41 | void led_matrix_indicators_user(void); | 80 | void led_matrix_indicators_user(void); |
42 | 81 | ||
43 | void led_matrix_init(void); | 82 | void led_matrix_indicators_advanced(effect_params_t *params); |
44 | void led_matrix_setup_drivers(void); | 83 | void led_matrix_indicators_advanced_kb(uint8_t led_min, uint8_t led_max); |
45 | 84 | void led_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max); | |
46 | void led_matrix_set_suspend_state(bool state); | ||
47 | void led_matrix_set_indicator_state(uint8_t state); | ||
48 | 85 | ||
49 | void led_matrix_task(void); | 86 | void led_matrix_init(void); |
50 | 87 | ||
51 | // This should not be called from an interrupt | 88 | void led_matrix_set_suspend_state(bool state); |
52 | // (eg. from a timer interrupt). | 89 | bool led_matrix_get_suspend_state(void); |
53 | // Call this while idle (in between matrix scans). | 90 | void led_matrix_toggle(void); |
54 | // If the buffer is dirty, it will update the driver with the buffer. | 91 | void led_matrix_toggle_noeeprom(void); |
55 | void led_matrix_update_pwm_buffers(void); | 92 | void led_matrix_enable(void); |
56 | 93 | void led_matrix_enable_noeeprom(void); | |
57 | bool process_led_matrix(uint16_t keycode, keyrecord_t *record); | 94 | void led_matrix_disable(void); |
58 | 95 | void led_matrix_disable_noeeprom(void); | |
59 | uint32_t led_matrix_get_tick(void); | 96 | uint8_t led_matrix_is_enabled(void); |
60 | 97 | void led_matrix_mode(uint8_t mode); | |
61 | void led_matrix_toggle(void); | 98 | void led_matrix_mode_noeeprom(uint8_t mode); |
62 | void led_matrix_enable(void); | 99 | uint8_t led_matrix_get_mode(void); |
63 | void led_matrix_enable_noeeprom(void); | 100 | void led_matrix_step(void); |
64 | void led_matrix_disable(void); | 101 | void led_matrix_step_noeeprom(void); |
65 | void led_matrix_disable_noeeprom(void); | 102 | void led_matrix_step_reverse(void); |
66 | void led_matrix_step(void); | 103 | void led_matrix_step_reverse_noeeprom(void); |
67 | void led_matrix_step_reverse(void); | 104 | void led_matrix_set_val(uint8_t val); |
68 | void led_matrix_increase_val(void); | 105 | void led_matrix_set_val_noeeprom(uint8_t val); |
69 | void led_matrix_decrease_val(void); | 106 | uint8_t led_matrix_get_val(void); |
70 | void led_matrix_increase_speed(void); | 107 | void led_matrix_increase_val(void); |
71 | void led_matrix_decrease_speed(void); | 108 | void led_matrix_increase_val_noeeprom(void); |
72 | void led_matrix_mode(uint8_t mode, bool eeprom_write); | 109 | void led_matrix_decrease_val(void); |
73 | void led_matrix_mode_noeeprom(uint8_t mode); | 110 | void led_matrix_decrease_val_noeeprom(void); |
74 | uint8_t led_matrix_get_mode(void); | 111 | void led_matrix_set_speed(uint8_t speed); |
75 | void led_matrix_set_value(uint8_t mode); | 112 | void led_matrix_set_speed_noeeprom(uint8_t speed); |
76 | void led_matrix_set_value_noeeprom(uint8_t mode); | 113 | uint8_t led_matrix_get_speed(void); |
114 | void led_matrix_increase_speed(void); | ||
115 | void led_matrix_increase_speed_noeeprom(void); | ||
116 | void led_matrix_decrease_speed(void); | ||
117 | void led_matrix_decrease_speed_noeeprom(void); | ||
118 | led_flags_t led_matrix_get_flags(void); | ||
119 | void led_matrix_set_flags(led_flags_t flags); | ||
77 | 120 | ||
78 | typedef struct { | 121 | typedef struct { |
79 | /* Perform any initialisation required for the other driver functions to work. */ | 122 | /* Perform any initialisation required for the other driver functions to work. */ |
@@ -91,4 +134,12 @@ extern const led_matrix_driver_t led_matrix_driver; | |||
91 | 134 | ||
92 | extern led_eeconfig_t led_matrix_eeconfig; | 135 | extern led_eeconfig_t led_matrix_eeconfig; |
93 | 136 | ||
137 | extern bool g_suspend_state; | ||
138 | extern uint32_t g_led_timer; | ||
94 | extern led_config_t g_led_config; | 139 | extern led_config_t g_led_config; |
140 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED | ||
141 | extern last_hit_t g_last_hit_tracker; | ||
142 | #endif | ||
143 | #ifdef LED_MATRIX_FRAMEBUFFER_EFFECTS | ||
144 | extern uint8_t g_led_frame_buffer[MATRIX_ROWS][MATRIX_COLS]; | ||
145 | #endif | ||
diff --git a/quantum/led_matrix_drivers.c b/quantum/led_matrix_drivers.c index eddf3f286..370c5e685 100644 --- a/quantum/led_matrix_drivers.c +++ b/quantum/led_matrix_drivers.c | |||
@@ -15,9 +15,6 @@ | |||
15 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | 15 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
16 | */ | 16 | */ |
17 | 17 | ||
18 | #include <stdint.h> | ||
19 | #include <stdbool.h> | ||
20 | #include "quantum.h" | ||
21 | #include "led_matrix.h" | 18 | #include "led_matrix.h" |
22 | 19 | ||
23 | /* Each driver needs to define a struct: | 20 | /* Each driver needs to define a struct: |
@@ -30,10 +27,6 @@ | |||
30 | 27 | ||
31 | #if defined(IS31FL3731) || defined(IS31FL3733) | 28 | #if defined(IS31FL3731) || defined(IS31FL3733) |
32 | 29 | ||
33 | # if defined(IS31FL3731) | ||
34 | # include "is31fl3731-simple.h" | ||
35 | # endif | ||
36 | |||
37 | # include "i2c_master.h" | 30 | # include "i2c_master.h" |
38 | 31 | ||
39 | static void init(void) { | 32 | static void init(void) { |
diff --git a/quantum/led_matrix_types.h b/quantum/led_matrix_types.h index 669b67042..13f44b07e 100644 --- a/quantum/led_matrix_types.h +++ b/quantum/led_matrix_types.h | |||
@@ -29,16 +29,43 @@ | |||
29 | # pragma pack(push, 1) | 29 | # pragma pack(push, 1) |
30 | #endif | 30 | #endif |
31 | 31 | ||
32 | #if defined(LED_MATRIX_KEYPRESSES) || defined(LED_MATRIX_KEYRELEASES) | ||
33 | # define LED_MATRIX_KEYREACTIVE_ENABLED | ||
34 | #endif | ||
35 | |||
32 | // Last led hit | 36 | // Last led hit |
33 | #ifndef LED_HITS_TO_REMEMBER | 37 | #ifndef LED_HITS_TO_REMEMBER |
34 | # define LED_HITS_TO_REMEMBER 8 | 38 | # define LED_HITS_TO_REMEMBER 8 |
35 | #endif // LED_HITS_TO_REMEMBER | 39 | #endif // LED_HITS_TO_REMEMBER |
36 | 40 | ||
41 | #ifdef LED_MATRIX_KEYREACTIVE_ENABLED | ||
42 | typedef struct PACKED { | ||
43 | uint8_t count; | ||
44 | uint8_t x[LED_HITS_TO_REMEMBER]; | ||
45 | uint8_t y[LED_HITS_TO_REMEMBER]; | ||
46 | uint8_t index[LED_HITS_TO_REMEMBER]; | ||
47 | uint16_t tick[LED_HITS_TO_REMEMBER]; | ||
48 | } last_hit_t; | ||
49 | #endif // LED_MATRIX_KEYREACTIVE_ENABLED | ||
50 | |||
51 | typedef enum led_task_states { STARTING, RENDERING, FLUSHING, SYNCING } led_task_states; | ||
52 | |||
53 | typedef uint8_t led_flags_t; | ||
54 | |||
55 | typedef struct PACKED { | ||
56 | uint8_t iter; | ||
57 | led_flags_t flags; | ||
58 | bool init; | ||
59 | } effect_params_t; | ||
60 | |||
37 | typedef struct PACKED { | 61 | typedef struct PACKED { |
38 | uint8_t x; | 62 | uint8_t x; |
39 | uint8_t y; | 63 | uint8_t y; |
40 | } point_t; | 64 | } point_t; |
41 | 65 | ||
66 | #define HAS_FLAGS(bits, flags) ((bits & flags) == flags) | ||
67 | #define HAS_ANY_FLAGS(bits, flags) ((bits & flags) != 0x00) | ||
68 | |||
42 | #define LED_FLAG_ALL 0xFF | 69 | #define LED_FLAG_ALL 0xFF |
43 | #define LED_FLAG_NONE 0x00 | 70 | #define LED_FLAG_NONE 0x00 |
44 | #define LED_FLAG_MODIFIER 0x01 | 71 | #define LED_FLAG_MODIFIER 0x01 |
@@ -56,11 +83,12 @@ typedef struct PACKED { | |||
56 | typedef union { | 83 | typedef union { |
57 | uint32_t raw; | 84 | uint32_t raw; |
58 | struct PACKED { | 85 | struct PACKED { |
59 | uint8_t enable : 2; | 86 | uint8_t enable : 2; |
60 | uint8_t mode : 6; | 87 | uint8_t mode : 6; |
61 | uint16_t reserved; | 88 | uint16_t reserved; |
62 | uint8_t val; | 89 | uint8_t val; |
63 | uint8_t speed; // EECONFIG needs to be increased to support this | 90 | uint8_t speed; // EECONFIG needs to be increased to support this |
91 | led_flags_t flags; | ||
64 | }; | 92 | }; |
65 | } led_eeconfig_t; | 93 | } led_eeconfig_t; |
66 | 94 | ||
diff --git a/quantum/matrix.h b/quantum/matrix.h index ce57010a4..3fe691aae 100644 --- a/quantum/matrix.h +++ b/quantum/matrix.h | |||
@@ -74,6 +74,11 @@ void matrix_scan_kb(void); | |||
74 | void matrix_init_user(void); | 74 | void matrix_init_user(void); |
75 | void matrix_scan_user(void); | 75 | void matrix_scan_user(void); |
76 | 76 | ||
77 | #ifdef SPLIT_KEYBOARD | ||
78 | void matrix_slave_scan_kb(void); | ||
79 | void matrix_slave_scan_user(void); | ||
80 | #endif | ||
81 | |||
77 | #ifdef __cplusplus | 82 | #ifdef __cplusplus |
78 | } | 83 | } |
79 | #endif | 84 | #endif |
diff --git a/quantum/mcu_selection.mk b/quantum/mcu_selection.mk index f7329fc4d..edf44f5dc 100644 --- a/quantum/mcu_selection.mk +++ b/quantum/mcu_selection.mk | |||
@@ -81,6 +81,33 @@ ifneq ($(findstring MK20DX256, $(MCU)),) | |||
81 | BOARD ?= PJRC_TEENSY_3_1 | 81 | BOARD ?= PJRC_TEENSY_3_1 |
82 | endif | 82 | endif |
83 | 83 | ||
84 | ifneq ($(findstring MK66F18, $(MCU)),) | ||
85 | # Cortex version | ||
86 | MCU = cortex-m4 | ||
87 | |||
88 | # ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7 | ||
89 | ARMV = 7 | ||
90 | |||
91 | ## chip/board settings | ||
92 | # - the next two should match the directories in | ||
93 | # <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES) | ||
94 | MCU_FAMILY = KINETIS | ||
95 | MCU_SERIES = MK66F18 | ||
96 | |||
97 | # Linker script to use | ||
98 | # - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/ | ||
99 | # or <keyboard_dir>/ld/ | ||
100 | MCU_LDSCRIPT ?= MK66FX1M0 | ||
101 | |||
102 | # Startup code to use | ||
103 | # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/ | ||
104 | MCU_STARTUP ?= MK66F18 | ||
105 | |||
106 | # Board: it should exist either in <chibios>/os/hal/boards/, | ||
107 | # <keyboard_dir>/boards/, or drivers/boards/ | ||
108 | BOARD ?= PJRC_TEENSY_3_6 | ||
109 | endif | ||
110 | |||
84 | ifneq ($(findstring STM32F042, $(MCU)),) | 111 | ifneq ($(findstring STM32F042, $(MCU)),) |
85 | # Cortex version | 112 | # Cortex version |
86 | MCU = cortex-m0 | 113 | MCU = cortex-m0 |
@@ -112,6 +139,9 @@ ifneq ($(findstring STM32F042, $(MCU)),) | |||
112 | # Options to pass to dfu-util when flashing | 139 | # Options to pass to dfu-util when flashing |
113 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 140 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
114 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 141 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
142 | |||
143 | # UF2 settings | ||
144 | UF2_FAMILY ?= STM32F0 | ||
115 | endif | 145 | endif |
116 | 146 | ||
117 | ifneq ($(findstring STM32F072, $(MCU)),) | 147 | ifneq ($(findstring STM32F072, $(MCU)),) |
@@ -145,6 +175,9 @@ ifneq ($(findstring STM32F072, $(MCU)),) | |||
145 | # Options to pass to dfu-util when flashing | 175 | # Options to pass to dfu-util when flashing |
146 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 176 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
147 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 177 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
178 | |||
179 | # UF2 settings | ||
180 | UF2_FAMILY ?= STM32F0 | ||
148 | endif | 181 | endif |
149 | 182 | ||
150 | ifneq ($(findstring STM32F103, $(MCU)),) | 183 | ifneq ($(findstring STM32F103, $(MCU)),) |
@@ -178,6 +211,9 @@ ifneq ($(findstring STM32F103, $(MCU)),) | |||
178 | # Options to pass to dfu-util when flashing | 211 | # Options to pass to dfu-util when flashing |
179 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 212 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
180 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 213 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
214 | |||
215 | # UF2 settings | ||
216 | UF2_FAMILY ?= STM32F1 | ||
181 | endif | 217 | endif |
182 | 218 | ||
183 | ifneq ($(findstring STM32F303, $(MCU)),) | 219 | ifneq ($(findstring STM32F303, $(MCU)),) |
@@ -211,6 +247,9 @@ ifneq ($(findstring STM32F303, $(MCU)),) | |||
211 | # Options to pass to dfu-util when flashing | 247 | # Options to pass to dfu-util when flashing |
212 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 248 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
213 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 249 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
250 | |||
251 | # UF2 settings | ||
252 | UF2_FAMILY ?= STM32F3 | ||
214 | endif | 253 | endif |
215 | 254 | ||
216 | ifneq ($(findstring STM32F401, $(MCU)),) | 255 | ifneq ($(findstring STM32F401, $(MCU)),) |
@@ -244,6 +283,9 @@ ifneq ($(findstring STM32F401, $(MCU)),) | |||
244 | # Options to pass to dfu-util when flashing | 283 | # Options to pass to dfu-util when flashing |
245 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 284 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
246 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 285 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
286 | |||
287 | # UF2 settings | ||
288 | UF2_FAMILY ?= STM32F4 | ||
247 | endif | 289 | endif |
248 | 290 | ||
249 | ifneq ($(findstring STM32F411, $(MCU)),) | 291 | ifneq ($(findstring STM32F411, $(MCU)),) |
@@ -262,7 +304,12 @@ ifneq ($(findstring STM32F411, $(MCU)),) | |||
262 | # Linker script to use | 304 | # Linker script to use |
263 | # - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/ | 305 | # - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/ |
264 | # or <keyboard_dir>/ld/ | 306 | # or <keyboard_dir>/ld/ |
265 | MCU_LDSCRIPT ?= STM32F411xE | 307 | ifeq ($(strip $(BOOTLOADER)), tinyuf2) |
308 | MCU_LDSCRIPT ?= STM32F411xE_tinyuf2 | ||
309 | FIRMWARE_FORMAT ?= uf2 | ||
310 | else | ||
311 | MCU_LDSCRIPT ?= STM32F411xE | ||
312 | endif | ||
266 | 313 | ||
267 | # Startup code to use | 314 | # Startup code to use |
268 | # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/ | 315 | # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/ |
@@ -277,6 +324,43 @@ ifneq ($(findstring STM32F411, $(MCU)),) | |||
277 | # Options to pass to dfu-util when flashing | 324 | # Options to pass to dfu-util when flashing |
278 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 325 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
279 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 326 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
327 | |||
328 | # UF2 settings | ||
329 | UF2_FAMILY ?= STM32F4 | ||
330 | endif | ||
331 | |||
332 | ifneq ($(findstring STM32F446, $(MCU)),) | ||
333 | # Cortex version | ||
334 | MCU = cortex-m4 | ||
335 | |||
336 | # ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7 | ||
337 | ARMV = 7 | ||
338 | |||
339 | ## chip/board settings | ||
340 | # - the next two should match the directories in | ||
341 | # <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES) | ||
342 | MCU_FAMILY = STM32 | ||
343 | MCU_SERIES = STM32F4xx | ||
344 | |||
345 | # Linker script to use | ||
346 | # - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/ | ||
347 | # or <chibios>/os/common/startup/ARMCMx/compilers/GCC/ld/ | ||
348 | # or <keyboard_dir>/ld/ | ||
349 | MCU_LDSCRIPT ?= STM32F446xE | ||
350 | |||
351 | # Startup code to use | ||
352 | # - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/ | ||
353 | MCU_STARTUP ?= stm32f4xx | ||
354 | |||
355 | # Board: it should exist either in <chibios>/os/hal/boards/, | ||
356 | # <keyboard_dir>/boards/, or drivers/boards/ | ||
357 | BOARD ?= GENERIC_STM32_F446XE | ||
358 | |||
359 | USE_FPU ?= yes | ||
360 | |||
361 | # Options to pass to dfu-util when flashing | ||
362 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | ||
363 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | ||
280 | endif | 364 | endif |
281 | 365 | ||
282 | ifneq ($(findstring STM32G431, $(MCU)),) | 366 | ifneq ($(findstring STM32G431, $(MCU)),) |
@@ -310,6 +394,9 @@ ifneq ($(findstring STM32G431, $(MCU)),) | |||
310 | # Options to pass to dfu-util when flashing | 394 | # Options to pass to dfu-util when flashing |
311 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 395 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
312 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 396 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
397 | |||
398 | # UF2 settings | ||
399 | UF2_FAMILY ?= STM32G4 | ||
313 | endif | 400 | endif |
314 | 401 | ||
315 | ifneq ($(findstring STM32G474, $(MCU)),) | 402 | ifneq ($(findstring STM32G474, $(MCU)),) |
@@ -343,6 +430,9 @@ ifneq ($(findstring STM32G474, $(MCU)),) | |||
343 | # Options to pass to dfu-util when flashing | 430 | # Options to pass to dfu-util when flashing |
344 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave | 431 | DFU_ARGS ?= -d 0483:DF11 -a 0 -s 0x08000000:leave |
345 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 | 432 | DFU_SUFFIX_ARGS ?= -v 0483 -p DF11 |
433 | |||
434 | # UF2 settings | ||
435 | UF2_FAMILY ?= STM32G4 | ||
346 | endif | 436 | endif |
347 | 437 | ||
348 | ifneq (,$(filter $(MCU),at90usb162 atmega16u2 atmega32u2 atmega16u4 atmega32u4 at90usb646 at90usb647 at90usb1286 at90usb1287)) | 438 | ifneq (,$(filter $(MCU),at90usb162 atmega16u2 atmega32u2 atmega16u4 atmega32u4 at90usb646 at90usb647 at90usb1286 at90usb1287)) |
diff --git a/quantum/process_keycode/process_auto_shift.c b/quantum/process_keycode/process_auto_shift.c index bf359e994..51b0efdb4 100644 --- a/quantum/process_keycode/process_auto_shift.c +++ b/quantum/process_keycode/process_auto_shift.c | |||
@@ -216,7 +216,18 @@ bool process_auto_shift(uint16_t keycode, keyrecord_t *record) { | |||
216 | # endif | 216 | # endif |
217 | } | 217 | } |
218 | } | 218 | } |
219 | if (get_auto_shifted_key(keycode, record)) { | ||
220 | if (record->event.pressed) { | ||
221 | return autoshift_press(keycode, now, record); | ||
222 | } else { | ||
223 | autoshift_end(keycode, now, false); | ||
224 | return false; | ||
225 | } | ||
226 | } | ||
227 | return true; | ||
228 | } | ||
219 | 229 | ||
230 | __attribute__((weak)) bool get_auto_shifted_key(uint16_t keycode, keyrecord_t *record) { | ||
220 | switch (keycode) { | 231 | switch (keycode) { |
221 | # ifndef NO_AUTO_SHIFT_ALPHA | 232 | # ifndef NO_AUTO_SHIFT_ALPHA |
222 | case KC_A ... KC_Z: | 233 | case KC_A ... KC_Z: |
@@ -229,14 +240,9 @@ bool process_auto_shift(uint16_t keycode, keyrecord_t *record) { | |||
229 | case KC_MINUS ... KC_SLASH: | 240 | case KC_MINUS ... KC_SLASH: |
230 | case KC_NONUS_BSLASH: | 241 | case KC_NONUS_BSLASH: |
231 | # endif | 242 | # endif |
232 | if (record->event.pressed) { | 243 | return true; |
233 | return autoshift_press(keycode, now, record); | ||
234 | } else { | ||
235 | autoshift_end(keycode, now, false); | ||
236 | return false; | ||
237 | } | ||
238 | } | 244 | } |
239 | return true; | 245 | return false; |
240 | } | 246 | } |
241 | 247 | ||
242 | #endif | 248 | #endif |
diff --git a/quantum/process_keycode/process_auto_shift.h b/quantum/process_keycode/process_auto_shift.h index 5b2718f11..00a9ab036 100644 --- a/quantum/process_keycode/process_auto_shift.h +++ b/quantum/process_keycode/process_auto_shift.h | |||
@@ -31,3 +31,4 @@ bool get_autoshift_state(void); | |||
31 | uint16_t get_autoshift_timeout(void); | 31 | uint16_t get_autoshift_timeout(void); |
32 | void set_autoshift_timeout(uint16_t timeout); | 32 | void set_autoshift_timeout(uint16_t timeout); |
33 | void autoshift_matrix_scan(void); | 33 | void autoshift_matrix_scan(void); |
34 | bool get_auto_shifted_key(uint16_t keycode, keyrecord_t *record); | ||
diff --git a/quantum/process_keycode/process_backlight.c b/quantum/process_keycode/process_backlight.c index 4d12f6813..8b70339a5 100644 --- a/quantum/process_keycode/process_backlight.c +++ b/quantum/process_keycode/process_backlight.c | |||
@@ -16,11 +16,35 @@ | |||
16 | 16 | ||
17 | #include "process_backlight.h" | 17 | #include "process_backlight.h" |
18 | 18 | ||
19 | #include "backlight.h" | 19 | #ifdef LED_MATRIX_ENABLE |
20 | # include "led_matrix.h" | ||
21 | #else | ||
22 | # include "backlight.h" | ||
23 | #endif | ||
20 | 24 | ||
21 | bool process_backlight(uint16_t keycode, keyrecord_t *record) { | 25 | bool process_backlight(uint16_t keycode, keyrecord_t *record) { |
22 | if (record->event.pressed) { | 26 | if (record->event.pressed) { |
23 | switch (keycode) { | 27 | switch (keycode) { |
28 | #ifdef LED_MATRIX_ENABLE | ||
29 | case BL_ON: | ||
30 | led_matrix_enable(); | ||
31 | return false; | ||
32 | case BL_OFF: | ||
33 | led_matrix_disable(); | ||
34 | return false; | ||
35 | case BL_DEC: | ||
36 | led_matrix_decrease_val(); | ||
37 | return false; | ||
38 | case BL_INC: | ||
39 | led_matrix_increase_val(); | ||
40 | return false; | ||
41 | case BL_TOGG: | ||
42 | led_matrix_toggle(); | ||
43 | return false; | ||
44 | case BL_STEP: | ||
45 | led_matrix_step(); | ||
46 | return false; | ||
47 | #else | ||
24 | case BL_ON: | 48 | case BL_ON: |
25 | backlight_level(BACKLIGHT_LEVELS); | 49 | backlight_level(BACKLIGHT_LEVELS); |
26 | return false; | 50 | return false; |
@@ -39,10 +63,11 @@ bool process_backlight(uint16_t keycode, keyrecord_t *record) { | |||
39 | case BL_STEP: | 63 | case BL_STEP: |
40 | backlight_step(); | 64 | backlight_step(); |
41 | return false; | 65 | return false; |
42 | #ifdef BACKLIGHT_BREATHING | 66 | # ifdef BACKLIGHT_BREATHING |
43 | case BL_BRTG: | 67 | case BL_BRTG: |
44 | backlight_toggle_breathing(); | 68 | backlight_toggle_breathing(); |
45 | return false; | 69 | return false; |
70 | # endif | ||
46 | #endif | 71 | #endif |
47 | } | 72 | } |
48 | } | 73 | } |
diff --git a/quantum/process_keycode/process_leader.c b/quantum/process_keycode/process_leader.c index 58a615d85..cf63f2514 100644 --- a/quantum/process_keycode/process_leader.c +++ b/quantum/process_keycode/process_leader.c | |||
@@ -49,7 +49,10 @@ bool process_leader(uint16_t keycode, keyrecord_t *record) { | |||
49 | // Leader key set-up | 49 | // Leader key set-up |
50 | if (record->event.pressed) { | 50 | if (record->event.pressed) { |
51 | if (leading) { | 51 | if (leading) { |
52 | if (timer_elapsed(leader_time) < LEADER_TIMEOUT) { | 52 | # ifndef LEADER_NO_TIMEOUT |
53 | if (timer_elapsed(leader_time) < LEADER_TIMEOUT) | ||
54 | # endif // LEADER_NO_TIMEOUT | ||
55 | { | ||
53 | # ifndef LEADER_KEY_STRICT_KEY_PROCESSING | 56 | # ifndef LEADER_KEY_STRICT_KEY_PROCESSING |
54 | if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) || (keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX)) { | 57 | if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) || (keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX)) { |
55 | keycode = keycode & 0xFF; | 58 | keycode = keycode & 0xFF; |
diff --git a/quantum/process_keycode/process_leader.h b/quantum/process_keycode/process_leader.h index 9844f27a1..32ccd42f7 100644 --- a/quantum/process_keycode/process_leader.h +++ b/quantum/process_keycode/process_leader.h | |||
@@ -35,4 +35,11 @@ void qk_leader_start(void); | |||
35 | extern uint16_t leader_time; \ | 35 | extern uint16_t leader_time; \ |
36 | extern uint16_t leader_sequence[5]; \ | 36 | extern uint16_t leader_sequence[5]; \ |
37 | extern uint8_t leader_sequence_size | 37 | extern uint8_t leader_sequence_size |
38 | #define LEADER_DICTIONARY() if (leading && timer_elapsed(leader_time) > LEADER_TIMEOUT) | 38 | |
39 | #ifdef LEADER_NO_TIMEOUT | ||
40 | # define LEADER_DICTIONARY() if (leading && leader_sequence_size > 0 && timer_elapsed(leader_time) > LEADER_TIMEOUT) | ||
41 | #else | ||
42 | # define LEADER_DICTIONARY() if (leading && timer_elapsed(leader_time) > LEADER_TIMEOUT) | ||
43 | #endif | ||
44 | |||
45 | #endif | ||
diff --git a/quantum/process_keycode/process_rgb.c b/quantum/process_keycode/process_rgb.c index 5dd8e7809..167c0c03c 100644 --- a/quantum/process_keycode/process_rgb.c +++ b/quantum/process_keycode/process_rgb.c | |||
@@ -207,6 +207,11 @@ bool process_rgb(const uint16_t keycode, const keyrecord_t *record) { | |||
207 | rgblight_mode(RGBLIGHT_MODE_RGB_TEST); | 207 | rgblight_mode(RGBLIGHT_MODE_RGB_TEST); |
208 | #endif | 208 | #endif |
209 | return false; | 209 | return false; |
210 | case RGB_MODE_TWINKLE: | ||
211 | #if defined(RGBLIGHT_ENABLE) && !defined(RGBLIGHT_DISABLE_KEYCODES) && defined(RGBLIGHT_EFFECT_TWINKLE) | ||
212 | handleKeycodeRGBMode(RGBLIGHT_MODE_TWINKLE, RGBLIGHT_MODE_TWINKLE_end); | ||
213 | #endif | ||
214 | return false; | ||
210 | } | 215 | } |
211 | } | 216 | } |
212 | 217 | ||
diff --git a/quantum/quantum.c b/quantum/quantum.c index b40b40544..8ccdb774b 100644 --- a/quantum/quantum.c +++ b/quantum/quantum.c | |||
@@ -15,6 +15,7 @@ | |||
15 | */ | 15 | */ |
16 | 16 | ||
17 | #include "quantum.h" | 17 | #include "quantum.h" |
18 | #include "magic.h" | ||
18 | 19 | ||
19 | #ifdef BLUETOOTH_ENABLE | 20 | #ifdef BLUETOOTH_ENABLE |
20 | # include "outputselect.h" | 21 | # include "outputselect.h" |
@@ -233,7 +234,7 @@ bool process_record_quantum(keyrecord_t *record) { | |||
233 | #ifdef AUDIO_ENABLE | 234 | #ifdef AUDIO_ENABLE |
234 | process_audio(keycode, record) && | 235 | process_audio(keycode, record) && |
235 | #endif | 236 | #endif |
236 | #ifdef BACKLIGHT_ENABLE | 237 | #if defined(BACKLIGHT_ENABLE) || defined(LED_MATRIX_ENABLE) |
237 | process_backlight(keycode, record) && | 238 | process_backlight(keycode, record) && |
238 | #endif | 239 | #endif |
239 | #ifdef STENO_ENABLE | 240 | #ifdef STENO_ENABLE |
@@ -318,6 +319,17 @@ bool process_record_quantum(keyrecord_t *record) { | |||
318 | set_output(OUTPUT_BLUETOOTH); | 319 | set_output(OUTPUT_BLUETOOTH); |
319 | return false; | 320 | return false; |
320 | #endif | 321 | #endif |
322 | #ifndef NO_ACTION_ONESHOT | ||
323 | case ONESHOT_TOGGLE: | ||
324 | oneshot_toggle(); | ||
325 | break; | ||
326 | case ONESHOT_ENABLE: | ||
327 | oneshot_enable(); | ||
328 | break; | ||
329 | case ONESHOT_DISABLE: | ||
330 | oneshot_disable(); | ||
331 | break; | ||
332 | #endif | ||
321 | } | 333 | } |
322 | } | 334 | } |
323 | 335 | ||
@@ -341,26 +353,20 @@ layer_state_t update_tri_layer_state(layer_state_t state, uint8_t layer1, uint8_ | |||
341 | void update_tri_layer(uint8_t layer1, uint8_t layer2, uint8_t layer3) { layer_state_set(update_tri_layer_state(layer_state, layer1, layer2, layer3)); } | 353 | void update_tri_layer(uint8_t layer1, uint8_t layer2, uint8_t layer3) { layer_state_set(update_tri_layer_state(layer_state, layer1, layer2, layer3)); } |
342 | 354 | ||
343 | void matrix_init_quantum() { | 355 | void matrix_init_quantum() { |
344 | #ifdef BOOTMAGIC_LITE | 356 | magic(); |
345 | bootmagic_lite(); | ||
346 | #endif | ||
347 | if (!eeconfig_is_enabled()) { | ||
348 | eeconfig_init(); | ||
349 | } | ||
350 | #if defined(LED_NUM_LOCK_PIN) || defined(LED_CAPS_LOCK_PIN) || defined(LED_SCROLL_LOCK_PIN) || defined(LED_COMPOSE_PIN) || defined(LED_KANA_PIN) | 357 | #if defined(LED_NUM_LOCK_PIN) || defined(LED_CAPS_LOCK_PIN) || defined(LED_SCROLL_LOCK_PIN) || defined(LED_COMPOSE_PIN) || defined(LED_KANA_PIN) |
351 | // TODO: remove calls to led_init_ports from keyboards and remove ifdef | 358 | // TODO: remove calls to led_init_ports from keyboards and remove ifdef |
352 | led_init_ports(); | 359 | led_init_ports(); |
353 | #endif | 360 | #endif |
354 | #ifdef BACKLIGHT_ENABLE | 361 | #ifdef BACKLIGHT_ENABLE |
355 | # ifdef LED_MATRIX_ENABLE | ||
356 | led_matrix_init(); | ||
357 | # else | ||
358 | backlight_init_ports(); | 362 | backlight_init_ports(); |
359 | # endif | ||
360 | #endif | 363 | #endif |
361 | #ifdef AUDIO_ENABLE | 364 | #ifdef AUDIO_ENABLE |
362 | audio_init(); | 365 | audio_init(); |
363 | #endif | 366 | #endif |
367 | #ifdef LED_MATRIX_ENABLE | ||
368 | led_matrix_init(); | ||
369 | #endif | ||
364 | #ifdef RGB_MATRIX_ENABLE | 370 | #ifdef RGB_MATRIX_ENABLE |
365 | rgb_matrix_init(); | 371 | rgb_matrix_init(); |
366 | #endif | 372 | #endif |
diff --git a/quantum/quantum.h b/quantum/quantum.h index e24a4c43a..fe6bf310a 100644 --- a/quantum/quantum.h +++ b/quantum/quantum.h | |||
@@ -30,11 +30,11 @@ | |||
30 | #include "keymap.h" | 30 | #include "keymap.h" |
31 | 31 | ||
32 | #ifdef BACKLIGHT_ENABLE | 32 | #ifdef BACKLIGHT_ENABLE |
33 | # ifdef LED_MATRIX_ENABLE | 33 | # include "backlight.h" |
34 | # include "led_matrix.h" | 34 | #endif |
35 | # else | 35 | |
36 | # include "backlight.h" | 36 | #ifdef LED_MATRIX_ENABLE |
37 | # endif | 37 | # include "led_matrix.h" |
38 | #endif | 38 | #endif |
39 | 39 | ||
40 | #if defined(RGBLIGHT_ENABLE) | 40 | #if defined(RGBLIGHT_ENABLE) |
@@ -52,6 +52,7 @@ | |||
52 | #include "action_layer.h" | 52 | #include "action_layer.h" |
53 | #include "eeconfig.h" | 53 | #include "eeconfig.h" |
54 | #include "bootloader.h" | 54 | #include "bootloader.h" |
55 | #include "bootmagic.h" | ||
55 | #include "timer.h" | 56 | #include "timer.h" |
56 | #include "sync_timer.h" | 57 | #include "sync_timer.h" |
57 | #include "config_common.h" | 58 | #include "config_common.h" |
@@ -97,7 +98,7 @@ extern layer_state_t layer_state; | |||
97 | # include "process_music.h" | 98 | # include "process_music.h" |
98 | #endif | 99 | #endif |
99 | 100 | ||
100 | #ifdef BACKLIGHT_ENABLE | 101 | #if defined(BACKLIGHT_ENABLE) || defined(LED_MATRIX_ENABLE) |
101 | # include "process_backlight.h" | 102 | # include "process_backlight.h" |
102 | #endif | 103 | #endif |
103 | 104 | ||
@@ -199,39 +200,6 @@ extern layer_state_t layer_state; | |||
199 | # include "usbpd.h" | 200 | # include "usbpd.h" |
200 | #endif | 201 | #endif |
201 | 202 | ||
202 | // Function substitutions to ease GPIO manipulation | ||
203 | #if defined(__AVR__) | ||
204 | |||
205 | /* The AVR series GPIOs have a one clock read delay for changes in the digital input signal. | ||
206 | * But here's more margin to make it two clocks. */ | ||
207 | # if !defined(GPIO_INPUT_PIN_DELAY) | ||
208 | # define GPIO_INPUT_PIN_DELAY 2 | ||
209 | # endif | ||
210 | # define waitInputPinDelay() wait_cpuclock(GPIO_INPUT_PIN_DELAY) | ||
211 | |||
212 | #elif defined(__ARMEL__) || defined(__ARMEB__) | ||
213 | |||
214 | /* For GPIOs on ARM-based MCUs, the input pins are sampled by the clock of the bus | ||
215 | * to which the GPIO is connected. | ||
216 | * The connected buses differ depending on the various series of MCUs. | ||
217 | * And since the instruction execution clock of the CPU and the bus clock of GPIO are different, | ||
218 | * there is a delay of several clocks to read the change of the input signal. | ||
219 | * | ||
220 | * Define this delay with the GPIO_INPUT_PIN_DELAY macro. | ||
221 | * If the GPIO_INPUT_PIN_DELAY macro is not defined, the following default values will be used. | ||
222 | * (A fairly large value of 0.25 microseconds is set.) | ||
223 | */ | ||
224 | # if !defined(GPIO_INPUT_PIN_DELAY) | ||
225 | # if defined(STM32_SYSCLK) | ||
226 | # define GPIO_INPUT_PIN_DELAY (STM32_SYSCLK / 1000000L / 4) | ||
227 | # elif defined(KINETIS_SYSCLK_FREQUENCY) | ||
228 | # define GPIO_INPUT_PIN_DELAY (KINETIS_SYSCLK_FREQUENCY / 1000000L / 4) | ||
229 | # endif | ||
230 | # endif | ||
231 | # define waitInputPinDelay() wait_cpuclock(GPIO_INPUT_PIN_DELAY) | ||
232 | |||
233 | #endif | ||
234 | |||
235 | // For tri-layer | 203 | // For tri-layer |
236 | void update_tri_layer(uint8_t layer1, uint8_t layer2, uint8_t layer3); | 204 | void update_tri_layer(uint8_t layer1, uint8_t layer2, uint8_t layer3); |
237 | layer_state_t update_tri_layer_state(layer_state_t state, uint8_t layer1, uint8_t layer2, uint8_t layer3); | 205 | layer_state_t update_tri_layer_state(layer_state_t state, uint8_t layer1, uint8_t layer2, uint8_t layer3); |
@@ -256,15 +224,6 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record); | |||
256 | void post_process_record_kb(uint16_t keycode, keyrecord_t *record); | 224 | void post_process_record_kb(uint16_t keycode, keyrecord_t *record); |
257 | void post_process_record_user(uint16_t keycode, keyrecord_t *record); | 225 | void post_process_record_user(uint16_t keycode, keyrecord_t *record); |
258 | 226 | ||
259 | #ifndef BOOTMAGIC_LITE_COLUMN | ||
260 | # define BOOTMAGIC_LITE_COLUMN 0 | ||
261 | #endif | ||
262 | #ifndef BOOTMAGIC_LITE_ROW | ||
263 | # define BOOTMAGIC_LITE_ROW 0 | ||
264 | #endif | ||
265 | |||
266 | void bootmagic_lite(void); | ||
267 | |||
268 | void reset_keyboard(void); | 227 | void reset_keyboard(void); |
269 | 228 | ||
270 | void startup_user(void); | 229 | void startup_user(void); |
diff --git a/quantum/quantum_keycodes.h b/quantum/quantum_keycodes.h index e49f8dcda..26021598a 100644 --- a/quantum/quantum_keycodes.h +++ b/quantum/quantum_keycodes.h | |||
@@ -16,19 +16,7 @@ | |||
16 | 16 | ||
17 | #pragma once | 17 | #pragma once |
18 | 18 | ||
19 | #if defined(SEQUENCER_ENABLE) | 19 | #include "sequencer.h" |
20 | # include "sequencer.h" | ||
21 | #endif | ||
22 | |||
23 | #ifndef MIDI_ENABLE_STRICT | ||
24 | # define MIDI_ENABLE_STRICT 0 | ||
25 | #endif | ||
26 | |||
27 | #if !MIDI_ENABLE_STRICT || (defined(MIDI_ENABLE) && defined(MIDI_ADVANCED)) | ||
28 | # ifndef MIDI_TONE_KEYCODE_OCTAVES | ||
29 | # define MIDI_TONE_KEYCODE_OCTAVES 3 | ||
30 | # endif | ||
31 | #endif | ||
32 | 20 | ||
33 | // Fillers to make layering more clear | 21 | // Fillers to make layering more clear |
34 | #define _______ KC_TRNS | 22 | #define _______ KC_TRNS |
@@ -67,6 +55,8 @@ enum quantum_keycodes { | |||
67 | QK_ONE_SHOT_LAYER_MAX = 0x54FF, | 55 | QK_ONE_SHOT_LAYER_MAX = 0x54FF, |
68 | QK_ONE_SHOT_MOD = 0x5500, | 56 | QK_ONE_SHOT_MOD = 0x5500, |
69 | QK_ONE_SHOT_MOD_MAX = 0x55FF, | 57 | QK_ONE_SHOT_MOD_MAX = 0x55FF, |
58 | QK_SWAP_HANDS = 0x5600, | ||
59 | QK_SWAP_HANDS_MAX = 0x56FF, | ||
70 | QK_TAP_DANCE = 0x5700, | 60 | QK_TAP_DANCE = 0x5700, |
71 | QK_TAP_DANCE_MAX = 0x57FF, | 61 | QK_TAP_DANCE_MAX = 0x57FF, |
72 | QK_LAYER_TAP_TOGGLE = 0x5800, | 62 | QK_LAYER_TAP_TOGGLE = 0x5800, |
@@ -77,507 +67,458 @@ enum quantum_keycodes { | |||
77 | QK_STENO_BOLT = 0x5A30, | 67 | QK_STENO_BOLT = 0x5A30, |
78 | QK_STENO_GEMINI = 0x5A31, | 68 | QK_STENO_GEMINI = 0x5A31, |
79 | QK_STENO_MAX = 0x5A3F, | 69 | QK_STENO_MAX = 0x5A3F, |
80 | QK_SWAP_HANDS = 0x5B00, | 70 | // 0x5C00 - 0x5FFF are reserved, see below |
81 | QK_SWAP_HANDS_MAX = 0x5BFF, | 71 | QK_MOD_TAP = 0x6000, |
82 | QK_MOD_TAP = 0x6000, | 72 | QK_MOD_TAP_MAX = 0x7FFF, |
83 | QK_MOD_TAP_MAX = 0x7FFF, | 73 | QK_UNICODE = 0x8000, |
84 | QK_UNICODE = 0x8000, | 74 | QK_UNICODE_MAX = 0xFFFF, |
85 | QK_UNICODE_MAX = 0xFFFF, | 75 | QK_UNICODEMAP = 0x8000, |
86 | QK_UNICODEMAP = 0x8000, | 76 | QK_UNICODEMAP_MAX = 0xBFFF, |
87 | QK_UNICODEMAP_MAX = 0xBFFF, | 77 | QK_UNICODEMAP_PAIR = 0xC000, |
88 | QK_UNICODEMAP_PAIR = 0xC000, | 78 | QK_UNICODEMAP_PAIR_MAX = 0xFFFF, |
89 | QK_UNICODEMAP_PAIR_MAX = 0xFFFF, | ||
90 | 79 | ||
91 | // Loose keycodes - to be used directly | 80 | // Loose keycodes - to be used directly |
92 | RESET = 0x5C00, | 81 | RESET = 0x5C00, |
93 | DEBUG, | 82 | DEBUG, // 5C01 |
94 | MAGIC_SWAP_CONTROL_CAPSLOCK, | 83 | |
95 | MAGIC_CAPSLOCK_TO_CONTROL, | 84 | // Magic |
96 | MAGIC_SWAP_LALT_LGUI, | 85 | MAGIC_SWAP_CONTROL_CAPSLOCK, // 5C02 |
97 | MAGIC_SWAP_RALT_RGUI, | 86 | MAGIC_CAPSLOCK_TO_CONTROL, // 5C03 |
98 | MAGIC_NO_GUI, | 87 | MAGIC_SWAP_LALT_LGUI, // 5C04 |
99 | MAGIC_SWAP_GRAVE_ESC, | 88 | MAGIC_SWAP_RALT_RGUI, // 5C05 |
100 | MAGIC_SWAP_BACKSLASH_BACKSPACE, | 89 | MAGIC_NO_GUI, // 5C06 |
101 | MAGIC_HOST_NKRO, | 90 | MAGIC_SWAP_GRAVE_ESC, // 5C07 |
102 | MAGIC_SWAP_ALT_GUI, | 91 | MAGIC_SWAP_BACKSLASH_BACKSPACE, // 5C08 |
103 | MAGIC_UNSWAP_CONTROL_CAPSLOCK, | 92 | MAGIC_HOST_NKRO, // 5C09 |
104 | MAGIC_UNCAPSLOCK_TO_CONTROL, | 93 | MAGIC_SWAP_ALT_GUI, // 5C0A |
105 | MAGIC_UNSWAP_LALT_LGUI, | 94 | MAGIC_UNSWAP_CONTROL_CAPSLOCK, // 5C0B |
106 | MAGIC_UNSWAP_RALT_RGUI, | 95 | MAGIC_UNCAPSLOCK_TO_CONTROL, // 5C0C |
107 | MAGIC_UNNO_GUI, | 96 | MAGIC_UNSWAP_LALT_LGUI, // 5C0D |
108 | MAGIC_UNSWAP_GRAVE_ESC, | 97 | MAGIC_UNSWAP_RALT_RGUI, // 5C0E |
109 | MAGIC_UNSWAP_BACKSLASH_BACKSPACE, | 98 | MAGIC_UNNO_GUI, // 5C0F |
110 | MAGIC_UNHOST_NKRO, | 99 | MAGIC_UNSWAP_GRAVE_ESC, // 5C10 |
111 | MAGIC_UNSWAP_ALT_GUI, | 100 | MAGIC_UNSWAP_BACKSLASH_BACKSPACE, // 5C11 |
112 | MAGIC_TOGGLE_NKRO, | 101 | MAGIC_UNHOST_NKRO, // 5C12 |
113 | MAGIC_TOGGLE_ALT_GUI, | 102 | MAGIC_UNSWAP_ALT_GUI, // 5C13 |
114 | GRAVE_ESC, | 103 | MAGIC_TOGGLE_NKRO, // 5C14 |
115 | 104 | MAGIC_TOGGLE_ALT_GUI, // 5C15 | |
116 | // Leader key | 105 | |
117 | #ifdef LEADER_ENABLE | 106 | // Grave Escape |
118 | KC_LEAD, | 107 | GRAVE_ESC, // 5C16 |
119 | #endif | 108 | |
120 | 109 | // Auto Shift | |
121 | // Auto Shift setup | 110 | KC_ASUP, // 5C17 |
122 | #ifndef AUTO_SHIFT_NO_SETUP | 111 | KC_ASDN, // 5C18 |
123 | KC_ASUP, | 112 | KC_ASRP, // 5C19 |
124 | KC_ASDN, | 113 | KC_ASTG, // 5C1A |
125 | KC_ASRP, | 114 | KC_ASON, // 5C1B |
126 | #endif | 115 | KC_ASOFF, // 5C1C |
127 | KC_ASTG, | 116 | |
128 | KC_ASON, | 117 | // Audio |
129 | KC_ASOFF, | 118 | AU_ON, // 5C1D |
130 | 119 | AU_OFF, // 5C1E | |
131 | // Audio on/off/toggle | 120 | AU_TOG, // 5C1F |
132 | AU_ON, | 121 | |
133 | AU_OFF, | 122 | // Audio Clicky |
134 | AU_TOG, | 123 | CLICKY_TOGGLE, // 5C20 |
135 | 124 | CLICKY_ENABLE, // 5C21 | |
136 | // Faux clicky as part of main audio feature | 125 | CLICKY_DISABLE, // 5C22 |
137 | CLICKY_TOGGLE, | 126 | CLICKY_UP, // 5C23 |
138 | CLICKY_ENABLE, | 127 | CLICKY_DOWN, // 5C24 |
139 | CLICKY_DISABLE, | 128 | CLICKY_RESET, // 5C25 |
140 | CLICKY_UP, | 129 | |
141 | CLICKY_DOWN, | 130 | // Music mode |
142 | CLICKY_RESET, | 131 | MU_ON, // 5C26 |
143 | 132 | MU_OFF, // 5C27 | |
144 | // Music mode on/off/toggle | 133 | MU_TOG, // 5C28 |
145 | MU_ON, | 134 | MU_MOD, // 5C29 |
146 | MU_OFF, | 135 | MUV_IN, // 5C2A |
147 | MU_TOG, | 136 | MUV_DE, // 5C2B |
148 | 137 | ||
149 | // Music mode cycle | 138 | // MIDI |
150 | MU_MOD, | 139 | MI_ON, // 5C2C |
151 | 140 | MI_OFF, // 5C2D | |
152 | // Music voice iterate | 141 | MI_TOG, // 5C2E |
153 | MUV_IN, | 142 | |
154 | MUV_DE, | 143 | MI_C, // 5C2F |
155 | 144 | MI_Cs, // 5C30 | |
156 | // Midi | ||
157 | #if !MIDI_ENABLE_STRICT || (defined(MIDI_ENABLE) && defined(MIDI_BASIC)) | ||
158 | MI_ON, | ||
159 | MI_OFF, | ||
160 | MI_TOG, | ||
161 | #endif | ||
162 | |||
163 | #if !MIDI_ENABLE_STRICT || (defined(MIDI_ENABLE) && defined(MIDI_ADVANCED)) | ||
164 | MIDI_TONE_MIN, | ||
165 | |||
166 | # if !MIDI_ENABLE_STRICT || MIDI_TONE_KEYCODE_OCTAVES > 0 | ||
167 | MI_C = MIDI_TONE_MIN, | ||
168 | MI_Cs, | ||
169 | MI_Db = MI_Cs, | 145 | MI_Db = MI_Cs, |
170 | MI_D, | 146 | MI_D, // 5C31 |
171 | MI_Ds, | 147 | MI_Ds, // 5C32 |
172 | MI_Eb = MI_Ds, | 148 | MI_Eb = MI_Ds, |
173 | MI_E, | 149 | MI_E, // 5C33 |
174 | MI_F, | 150 | MI_F, // 5C34 |
175 | MI_Fs, | 151 | MI_Fs, // 5C35 |
176 | MI_Gb = MI_Fs, | 152 | MI_Gb = MI_Fs, |
177 | MI_G, | 153 | MI_G, // 5C36 |
178 | MI_Gs, | 154 | MI_Gs, // 5C37 |
179 | MI_Ab = MI_Gs, | 155 | MI_Ab = MI_Gs, |
180 | MI_A, | 156 | MI_A, // 5C38 |
181 | MI_As, | 157 | MI_As, // 5C39 |
182 | MI_Bb = MI_As, | 158 | MI_Bb = MI_As, |
183 | MI_B, | 159 | MI_B, // 5C3A |
184 | # endif | ||
185 | 160 | ||
186 | # if !MIDI_ENABLE_STRICT || MIDI_TONE_KEYCODE_OCTAVES > 1 | 161 | MI_C_1, // 5C3B |
187 | MI_C_1, | 162 | MI_Cs_1, // 5C3C |
188 | MI_Cs_1, | ||
189 | MI_Db_1 = MI_Cs_1, | 163 | MI_Db_1 = MI_Cs_1, |
190 | MI_D_1, | 164 | MI_D_1, // 5C3D |
191 | MI_Ds_1, | 165 | MI_Ds_1, // 5C3E |
192 | MI_Eb_1 = MI_Ds_1, | 166 | MI_Eb_1 = MI_Ds_1, |
193 | MI_E_1, | 167 | MI_E_1, // 5C3F |
194 | MI_F_1, | 168 | MI_F_1, // 5C40 |
195 | MI_Fs_1, | 169 | MI_Fs_1, // 5C41 |
196 | MI_Gb_1 = MI_Fs_1, | 170 | MI_Gb_1 = MI_Fs_1, |
197 | MI_G_1, | 171 | MI_G_1, // 5C42 |
198 | MI_Gs_1, | 172 | MI_Gs_1, // 5C43 |
199 | MI_Ab_1 = MI_Gs_1, | 173 | MI_Ab_1 = MI_Gs_1, |
200 | MI_A_1, | 174 | MI_A_1, // 5C44 |
201 | MI_As_1, | 175 | MI_As_1, // 5C45 |
202 | MI_Bb_1 = MI_As_1, | 176 | MI_Bb_1 = MI_As_1, |
203 | MI_B_1, | 177 | MI_B_1, // 5C46 |
204 | # endif | ||
205 | 178 | ||
206 | # if !MIDI_ENABLE_STRICT || MIDI_TONE_KEYCODE_OCTAVES > 2 | 179 | MI_C_2, // 5C47 |
207 | MI_C_2, | 180 | MI_Cs_2, // 5C48 |
208 | MI_Cs_2, | ||
209 | MI_Db_2 = MI_Cs_2, | 181 | MI_Db_2 = MI_Cs_2, |
210 | MI_D_2, | 182 | MI_D_2, // 5C49 |
211 | MI_Ds_2, | 183 | MI_Ds_2, // 5C4A |
212 | MI_Eb_2 = MI_Ds_2, | 184 | MI_Eb_2 = MI_Ds_2, |
213 | MI_E_2, | 185 | MI_E_2, // 5C4B |
214 | MI_F_2, | 186 | MI_F_2, // 5C4C |
215 | MI_Fs_2, | 187 | MI_Fs_2, // 5C4D |
216 | MI_Gb_2 = MI_Fs_2, | 188 | MI_Gb_2 = MI_Fs_2, |
217 | MI_G_2, | 189 | MI_G_2, // 5C4E |
218 | MI_Gs_2, | 190 | MI_Gs_2, // 5C4F |
219 | MI_Ab_2 = MI_Gs_2, | 191 | MI_Ab_2 = MI_Gs_2, |
220 | MI_A_2, | 192 | MI_A_2, // 5C50 |
221 | MI_As_2, | 193 | MI_As_2, // 5C51 |
222 | MI_Bb_2 = MI_As_2, | 194 | MI_Bb_2 = MI_As_2, |
223 | MI_B_2, | 195 | MI_B_2, // 5C52 |
224 | # endif | ||
225 | 196 | ||
226 | # if !MIDI_ENABLE_STRICT || MIDI_TONE_KEYCODE_OCTAVES > 3 | 197 | MI_C_3, // 5C53 |
227 | MI_C_3, | 198 | MI_Cs_3, // 5C54 |
228 | MI_Cs_3, | ||
229 | MI_Db_3 = MI_Cs_3, | 199 | MI_Db_3 = MI_Cs_3, |
230 | MI_D_3, | 200 | MI_D_3, // 5C55 |
231 | MI_Ds_3, | 201 | MI_Ds_3, // 5C56 |
232 | MI_Eb_3 = MI_Ds_3, | 202 | MI_Eb_3 = MI_Ds_3, |
233 | MI_E_3, | 203 | MI_E_3, // 5C57 |
234 | MI_F_3, | 204 | MI_F_3, // 5C58 |
235 | MI_Fs_3, | 205 | MI_Fs_3, // 5C59 |
236 | MI_Gb_3 = MI_Fs_3, | 206 | MI_Gb_3 = MI_Fs_3, |
237 | MI_G_3, | 207 | MI_G_3, // 5C5A |
238 | MI_Gs_3, | 208 | MI_Gs_3, // 5C5B |
239 | MI_Ab_3 = MI_Gs_3, | 209 | MI_Ab_3 = MI_Gs_3, |
240 | MI_A_3, | 210 | MI_A_3, // 5C5C |
241 | MI_As_3, | 211 | MI_As_3, // 5C5D |
242 | MI_Bb_3 = MI_As_3, | 212 | MI_Bb_3 = MI_As_3, |
243 | MI_B_3, | 213 | MI_B_3, // 5C5E |
244 | # endif | ||
245 | 214 | ||
246 | # if !MIDI_ENABLE_STRICT || MIDI_TONE_KEYCODE_OCTAVES > 4 | 215 | MI_C_4, // 5C5F |
247 | MI_C_4, | 216 | MI_Cs_4, // 5C60 |
248 | MI_Cs_4, | ||
249 | MI_Db_4 = MI_Cs_4, | 217 | MI_Db_4 = MI_Cs_4, |
250 | MI_D_4, | 218 | MI_D_4, // 5C61 |
251 | MI_Ds_4, | 219 | MI_Ds_4, // 5C62 |
252 | MI_Eb_4 = MI_Ds_4, | 220 | MI_Eb_4 = MI_Ds_4, |
253 | MI_E_4, | 221 | MI_E_4, // 5C63 |
254 | MI_F_4, | 222 | MI_F_4, // 5C64 |
255 | MI_Fs_4, | 223 | MI_Fs_4, // 5C65 |
256 | MI_Gb_4 = MI_Fs_4, | 224 | MI_Gb_4 = MI_Fs_4, |
257 | MI_G_4, | 225 | MI_G_4, // 5C66 |
258 | MI_Gs_4, | 226 | MI_Gs_4, // 5C67 |
259 | MI_Ab_4 = MI_Gs_4, | 227 | MI_Ab_4 = MI_Gs_4, |
260 | MI_A_4, | 228 | MI_A_4, // 5C68 |
261 | MI_As_4, | 229 | MI_As_4, // 5C69 |
262 | MI_Bb_4 = MI_As_4, | 230 | MI_Bb_4 = MI_As_4, |
263 | MI_B_4, | 231 | MI_B_4, // 5C6A |
264 | # endif | ||
265 | 232 | ||
266 | # if !MIDI_ENABLE_STRICT || MIDI_TONE_KEYCODE_OCTAVES > 5 | 233 | MI_C_5, // 5C6B |
267 | MI_C_5, | 234 | MI_Cs_5, // 5C6C |
268 | MI_Cs_5, | ||
269 | MI_Db_5 = MI_Cs_5, | 235 | MI_Db_5 = MI_Cs_5, |
270 | MI_D_5, | 236 | MI_D_5, // 5C6D |
271 | MI_Ds_5, | 237 | MI_Ds_5, // 5C6E |
272 | MI_Eb_5 = MI_Ds_5, | 238 | MI_Eb_5 = MI_Ds_5, |
273 | MI_E_5, | 239 | MI_E_5, // 5C6F |
274 | MI_F_5, | 240 | MI_F_5, // 5C70 |
275 | MI_Fs_5, | 241 | MI_Fs_5, // 5C71 |
276 | MI_Gb_5 = MI_Fs_5, | 242 | MI_Gb_5 = MI_Fs_5, |
277 | MI_G_5, | 243 | MI_G_5, // 5C72 |
278 | MI_Gs_5, | 244 | MI_Gs_5, // 5C73 |
279 | MI_Ab_5 = MI_Gs_5, | 245 | MI_Ab_5 = MI_Gs_5, |
280 | MI_A_5, | 246 | MI_A_5, // 5C74 |
281 | MI_As_5, | 247 | MI_As_5, // 5C75 |
282 | MI_Bb_5 = MI_As_5, | 248 | MI_Bb_5 = MI_As_5, |
283 | MI_B_5, | 249 | MI_B_5, // 5C76 |
284 | # endif | 250 | |
285 | 251 | MI_OCT_N2, // 5C77 | |
286 | # if !MIDI_ENABLE_STRICT || MIDI_TONE_KEYCODE_OCTAVES > 5 | 252 | MI_OCT_N1, // 5C78 |
287 | MIDI_TONE_MAX = MI_B_5, | 253 | MI_OCT_0, // 5C79 |
288 | # elif MIDI_TONE_KEYCODE_OCTAVES > 4 | 254 | MI_OCT_1, // 5C7A |
289 | MIDI_TONE_MAX = MI_B_4, | 255 | MI_OCT_2, // 5C7B |
290 | # elif MIDI_TONE_KEYCODE_OCTAVES > 3 | 256 | MI_OCT_3, // 5C7C |
291 | MIDI_TONE_MAX = MI_B_3, | 257 | MI_OCT_4, // 5C7D |
292 | # elif MIDI_TONE_KEYCODE_OCTAVES > 2 | 258 | MI_OCT_5, // 5C7E |
293 | MIDI_TONE_MAX = MI_B_2, | 259 | MI_OCT_6, // 5C7F |
294 | # elif MIDI_TONE_KEYCODE_OCTAVES > 1 | 260 | MI_OCT_7, // 5C80 |
295 | MIDI_TONE_MAX = MI_B_1, | 261 | MI_OCTD, // 5C81 |
296 | # elif MIDI_TONE_KEYCODE_OCTAVES > 0 | 262 | MI_OCTU, // 5C82 |
297 | MIDI_TONE_MAX = MI_B, | 263 | |
298 | # endif | 264 | MI_TRNS_N6, // 5C83 |
299 | 265 | MI_TRNS_N5, // 5C84 | |
300 | MIDI_OCTAVE_MIN, | 266 | MI_TRNS_N4, // 5C85 |
301 | MI_OCT_N2 = MIDI_OCTAVE_MIN, | 267 | MI_TRNS_N3, // 5C86 |
302 | MI_OCT_N1, | 268 | MI_TRNS_N2, // 5C87 |
303 | MI_OCT_0, | 269 | MI_TRNS_N1, // 5C88 |
304 | MI_OCT_1, | 270 | MI_TRNS_0, // 5C89 |
305 | MI_OCT_2, | 271 | MI_TRNS_1, // 5C8A |
306 | MI_OCT_3, | 272 | MI_TRNS_2, // 5C8B |
307 | MI_OCT_4, | 273 | MI_TRNS_3, // 5C8C |
308 | MI_OCT_5, | 274 | MI_TRNS_4, // 5C8D |
309 | MI_OCT_6, | 275 | MI_TRNS_5, // 5C8E |
310 | MI_OCT_7, | 276 | MI_TRNS_6, // 5C8F |
311 | MIDI_OCTAVE_MAX = MI_OCT_7, | 277 | MI_TRNSD, // 5C90 |
312 | MI_OCTD, // octave down | 278 | MI_TRNSU, // 5C91 |
313 | MI_OCTU, // octave up | 279 | |
314 | 280 | MI_VEL_0, // 5C92 | |
315 | MIDI_TRANSPOSE_MIN, | 281 | #ifdef VIA_ENABLE |
316 | MI_TRNS_N6 = MIDI_TRANSPOSE_MIN, | 282 | MI_VEL_1 = MI_VEL_0, |
317 | MI_TRNS_N5, | 283 | #else |
318 | MI_TRNS_N4, | 284 | MI_VEL_1, // 5C93 |
319 | MI_TRNS_N3, | ||
320 | MI_TRNS_N2, | ||
321 | MI_TRNS_N1, | ||
322 | MI_TRNS_0, | ||
323 | MI_TRNS_1, | ||
324 | MI_TRNS_2, | ||
325 | MI_TRNS_3, | ||
326 | MI_TRNS_4, | ||
327 | MI_TRNS_5, | ||
328 | MI_TRNS_6, | ||
329 | MIDI_TRANSPOSE_MAX = MI_TRNS_6, | ||
330 | MI_TRNSD, // transpose down | ||
331 | MI_TRNSU, // transpose up | ||
332 | |||
333 | MIDI_VELOCITY_MIN, | ||
334 | MI_VEL_0 = MIDI_VELOCITY_MIN, | ||
335 | # ifdef VIA_ENABLE | ||
336 | MI_VEL_1 = MIDI_VELOCITY_MIN, | ||
337 | # else | ||
338 | MI_VEL_1, | ||
339 | # endif | ||
340 | MI_VEL_2, | ||
341 | MI_VEL_3, | ||
342 | MI_VEL_4, | ||
343 | MI_VEL_5, | ||
344 | MI_VEL_6, | ||
345 | MI_VEL_7, | ||
346 | MI_VEL_8, | ||
347 | MI_VEL_9, | ||
348 | MI_VEL_10, | ||
349 | MIDI_VELOCITY_MAX = MI_VEL_10, | ||
350 | MI_VELD, // velocity down | ||
351 | MI_VELU, // velocity up | ||
352 | |||
353 | MIDI_CHANNEL_MIN, | ||
354 | MI_CH1 = MIDI_CHANNEL_MIN, | ||
355 | MI_CH2, | ||
356 | MI_CH3, | ||
357 | MI_CH4, | ||
358 | MI_CH5, | ||
359 | MI_CH6, | ||
360 | MI_CH7, | ||
361 | MI_CH8, | ||
362 | MI_CH9, | ||
363 | MI_CH10, | ||
364 | MI_CH11, | ||
365 | MI_CH12, | ||
366 | MI_CH13, | ||
367 | MI_CH14, | ||
368 | MI_CH15, | ||
369 | MI_CH16, | ||
370 | MIDI_CHANNEL_MAX = MI_CH16, | ||
371 | MI_CHD, // previous channel | ||
372 | MI_CHU, // next channel | ||
373 | |||
374 | MI_ALLOFF, // all notes off | ||
375 | |||
376 | MI_SUS, // sustain | ||
377 | MI_PORT, // portamento | ||
378 | MI_SOST, // sostenuto | ||
379 | MI_SOFT, // soft pedal | ||
380 | MI_LEG, // legato | ||
381 | |||
382 | MI_MOD, // modulation | ||
383 | MI_MODSD, // decrease modulation speed | ||
384 | MI_MODSU, // increase modulation speed | ||
385 | |||
386 | MI_BENDD, // Bend down | ||
387 | MI_BENDU, // Bend up | ||
388 | #endif // MIDI_ADVANCED | ||
389 | |||
390 | // Backlight functionality | ||
391 | BL_ON, | ||
392 | BL_OFF, | ||
393 | BL_DEC, | ||
394 | BL_INC, | ||
395 | BL_TOGG, | ||
396 | BL_STEP, | ||
397 | BL_BRTG, | ||
398 | |||
399 | // RGB functionality | ||
400 | RGB_TOG, | ||
401 | RGB_MODE_FORWARD, | ||
402 | RGB_MODE_REVERSE, | ||
403 | RGB_HUI, | ||
404 | RGB_HUD, | ||
405 | RGB_SAI, | ||
406 | RGB_SAD, | ||
407 | RGB_VAI, | ||
408 | RGB_VAD, | ||
409 | RGB_SPI, | ||
410 | RGB_SPD, | ||
411 | RGB_MODE_PLAIN, | ||
412 | RGB_MODE_BREATHE, | ||
413 | RGB_MODE_RAINBOW, | ||
414 | RGB_MODE_SWIRL, | ||
415 | RGB_MODE_SNAKE, | ||
416 | RGB_MODE_KNIGHT, | ||
417 | RGB_MODE_XMAS, | ||
418 | RGB_MODE_GRADIENT, | ||
419 | RGB_MODE_RGBTEST, | ||
420 | |||
421 | // Momentum matching toggle | ||
422 | VLK_TOG, | ||
423 | |||
424 | // Left shift, open paren | ||
425 | KC_LSPO, | ||
426 | |||
427 | // Right shift, close paren | ||
428 | KC_RSPC, | ||
429 | |||
430 | // Shift, Enter | ||
431 | KC_SFTENT, | ||
432 | |||
433 | // Printing | ||
434 | PRINT_ON, | ||
435 | PRINT_OFF, | ||
436 | |||
437 | // output selection | ||
438 | OUT_AUTO, | ||
439 | OUT_USB, | ||
440 | #ifdef BLUETOOTH_ENABLE | ||
441 | OUT_BT, | ||
442 | #endif | ||
443 | |||
444 | #ifdef KEY_LOCK_ENABLE | ||
445 | KC_LOCK, | ||
446 | #endif | 285 | #endif |
447 | 286 | MI_VEL_2, // 5C94 | |
448 | #ifdef TERMINAL_ENABLE | 287 | MI_VEL_3, // 5C95 |
449 | TERM_ON, | 288 | MI_VEL_4, // 5C96 |
450 | TERM_OFF, | 289 | MI_VEL_5, // 5C97 |
451 | #endif | 290 | MI_VEL_6, // 5C98 |
452 | 291 | MI_VEL_7, // 5C99 | |
453 | EEPROM_RESET, | 292 | MI_VEL_8, // 5C9A |
454 | 293 | MI_VEL_9, // 5C9B | |
455 | UNICODE_MODE_FORWARD, | 294 | MI_VEL_10, // 5C9C |
456 | UNICODE_MODE_REVERSE, | 295 | MI_VELD, // 5C9D |
457 | UNICODE_MODE_MAC, | 296 | MI_VELU, // 5C9E |
458 | UNICODE_MODE_LNX, | 297 | |
459 | UNICODE_MODE_WIN, | 298 | MI_CH1, // 5C9F |
460 | UNICODE_MODE_BSD, | 299 | MI_CH2, // 5CA0 |
461 | UNICODE_MODE_WINC, | 300 | MI_CH3, // 5CA1 |
462 | 301 | MI_CH4, // 5CA2 | |
463 | HPT_ON, | 302 | MI_CH5, // 5CA3 |
464 | HPT_OFF, | 303 | MI_CH6, // 5CA4 |
465 | HPT_TOG, | 304 | MI_CH7, // 5CA5 |
466 | HPT_RST, | 305 | MI_CH8, // 5CA6 |
467 | HPT_FBK, | 306 | MI_CH9, // 5CA7 |
468 | HPT_BUZ, | 307 | MI_CH10, // 5CA8 |
469 | HPT_MODI, | 308 | MI_CH11, // 5CA9 |
470 | HPT_MODD, | 309 | MI_CH12, // 5CAA |
471 | HPT_CONT, | 310 | MI_CH13, // 5CAB |
472 | HPT_CONI, | 311 | MI_CH14, // 5CAC |
473 | HPT_COND, | 312 | MI_CH15, // 5CAD |
474 | HPT_DWLI, | 313 | MI_CH16, // 5CAE |
475 | HPT_DWLD, | 314 | MI_CHD, // 5CAF |
476 | 315 | MI_CHU, // 5CB0 | |
477 | // Left control, open paren | 316 | |
478 | KC_LCPO, | 317 | MI_ALLOFF, // 5CB1 |
479 | 318 | ||
480 | // Right control, close paren | 319 | MI_SUS, // 5CB2 |
481 | KC_RCPC, | 320 | MI_PORT, // 5CB3 |
482 | 321 | MI_SOST, // 5CB4 | |
483 | // Left control, open paren | 322 | MI_SOFT, // 5CB5 |
484 | KC_LAPO, | 323 | MI_LEG, // 5CB6 |
485 | 324 | ||
486 | // Right control, close paren | 325 | MI_MOD, // 5CB7 |
487 | KC_RAPC, | 326 | MI_MODSD, // 5CB8 |
488 | 327 | MI_MODSU, // 5CB9 | |
489 | CMB_ON, | 328 | |
490 | CMB_OFF, | 329 | MI_BENDD, // 5CBA |
491 | CMB_TOG, | 330 | MI_BENDU, // 5CBB |
492 | 331 | ||
493 | MAGIC_SWAP_LCTL_LGUI, | 332 | // Backlight |
494 | MAGIC_SWAP_RCTL_RGUI, | 333 | BL_ON, // 5CBC |
495 | MAGIC_UNSWAP_LCTL_LGUI, | 334 | BL_OFF, // 5CBD |
496 | MAGIC_UNSWAP_RCTL_RGUI, | 335 | BL_DEC, // 5CBE |
497 | MAGIC_SWAP_CTL_GUI, | 336 | BL_INC, // 5CBF |
498 | MAGIC_UNSWAP_CTL_GUI, | 337 | BL_TOGG, // 5CC0 |
499 | MAGIC_TOGGLE_CTL_GUI, | 338 | BL_STEP, // 5CC1 |
500 | MAGIC_EE_HANDS_LEFT, | 339 | BL_BRTG, // 5CC2 |
501 | MAGIC_EE_HANDS_RIGHT, | 340 | |
341 | // RGB underglow/matrix | ||
342 | RGB_TOG, // 5CC3 | ||
343 | RGB_MODE_FORWARD, // 5CC4 | ||
344 | RGB_MODE_REVERSE, // 5CC5 | ||
345 | RGB_HUI, // 5CC6 | ||
346 | RGB_HUD, // 5CC7 | ||
347 | RGB_SAI, // 5CC8 | ||
348 | RGB_SAD, // 5CC9 | ||
349 | RGB_VAI, // 5CCA | ||
350 | RGB_VAD, // 5CCB | ||
351 | RGB_SPI, // 5CCC | ||
352 | RGB_SPD, // 5CCD | ||
353 | RGB_MODE_PLAIN, // 5CCE | ||
354 | RGB_MODE_BREATHE, // 5CCF | ||
355 | RGB_MODE_RAINBOW, // 5CD0 | ||
356 | RGB_MODE_SWIRL, // 5CD1 | ||
357 | RGB_MODE_SNAKE, // 5CD2 | ||
358 | RGB_MODE_KNIGHT, // 5CD3 | ||
359 | RGB_MODE_XMAS, // 5CD4 | ||
360 | RGB_MODE_GRADIENT, // 5CD5 | ||
361 | RGB_MODE_RGBTEST, // 5CD6 | ||
362 | |||
363 | // Velocikey | ||
364 | VLK_TOG, // 5CD7 | ||
365 | |||
366 | // Space Cadet | ||
367 | KC_LSPO, // 5CD8 | ||
368 | KC_RSPC, // 5CD9 | ||
369 | KC_SFTENT, // 5CDA | ||
370 | |||
371 | // Thermal Printer | ||
372 | PRINT_ON, // 5CDB | ||
373 | PRINT_OFF, // 5CDC | ||
374 | |||
375 | // Bluetooth: output selection | ||
376 | OUT_AUTO, // 5CDD | ||
377 | OUT_USB, // 5CDE | ||
378 | |||
379 | // Clear EEPROM | ||
380 | EEPROM_RESET, // 5CDF | ||
381 | |||
382 | // Unicode | ||
383 | UNICODE_MODE_FORWARD, // 5CE0 | ||
384 | UNICODE_MODE_REVERSE, // 5CE1 | ||
385 | UNICODE_MODE_MAC, // 5CE2 | ||
386 | UNICODE_MODE_LNX, // 5CE3 | ||
387 | UNICODE_MODE_WIN, // 5CE4 | ||
388 | UNICODE_MODE_BSD, // 5CE5 | ||
389 | UNICODE_MODE_WINC, // 5CE6 | ||
390 | |||
391 | // Haptic | ||
392 | HPT_ON, // 5CE7 | ||
393 | HPT_OFF, // 5CE8 | ||
394 | HPT_TOG, // 5CE9 | ||
395 | HPT_RST, // 5CEA | ||
396 | HPT_FBK, // 5CEB | ||
397 | HPT_BUZ, // 5CEC | ||
398 | HPT_MODI, // 5CED | ||
399 | HPT_MODD, // 5CEE | ||
400 | HPT_CONT, // 5CEF | ||
401 | HPT_CONI, // 5CF0 | ||
402 | HPT_COND, // 5CF1 | ||
403 | HPT_DWLI, // 5CF2 | ||
404 | HPT_DWLD, // 5CF3 | ||
405 | |||
406 | // Space Cadet (continued) | ||
407 | KC_LCPO, // 5CF4 | ||
408 | KC_RCPC, // 5CF5 | ||
409 | KC_LAPO, // 5CF6 | ||
410 | KC_RAPC, // 5CF7 | ||
411 | |||
412 | // Combos | ||
413 | CMB_ON, // 5CF8 | ||
414 | CMB_OFF, // 5CF9 | ||
415 | CMB_TOG, // 5CFA | ||
416 | |||
417 | // Magic (continued) | ||
418 | MAGIC_SWAP_LCTL_LGUI, // 5CFB | ||
419 | MAGIC_SWAP_RCTL_RGUI, // 5CFC | ||
420 | MAGIC_UNSWAP_LCTL_LGUI, // 5CFD | ||
421 | MAGIC_UNSWAP_RCTL_RGUI, // 5CFE | ||
422 | MAGIC_SWAP_CTL_GUI, // 5CFF | ||
423 | MAGIC_UNSWAP_CTL_GUI, // 5D00 | ||
424 | MAGIC_TOGGLE_CTL_GUI, // 5D01 | ||
425 | MAGIC_EE_HANDS_LEFT, // 5D02 | ||
426 | MAGIC_EE_HANDS_RIGHT, // 5D03 | ||
502 | 427 | ||
503 | // Dynamic Macros | 428 | // Dynamic Macros |
504 | DYN_REC_START1, | 429 | DYN_REC_START1, // 5D04 |
505 | DYN_REC_START2, | 430 | DYN_REC_START2, // 5D05 |
506 | DYN_REC_STOP, | 431 | DYN_REC_STOP, // 5D06 |
507 | DYN_MACRO_PLAY1, | 432 | DYN_MACRO_PLAY1, // 5D07 |
508 | DYN_MACRO_PLAY2, | 433 | DYN_MACRO_PLAY2, // 5D08 |
509 | 434 | ||
510 | JS_BUTTON0, | 435 | // Joystick |
511 | JS_BUTTON_MIN = JS_BUTTON0, | 436 | JS_BUTTON0, // 5D09 |
512 | JS_BUTTON1, | 437 | JS_BUTTON1, // 5D0A |
513 | JS_BUTTON2, | 438 | JS_BUTTON2, // 5D0B |
514 | JS_BUTTON3, | 439 | JS_BUTTON3, // 5D0C |
515 | JS_BUTTON4, | 440 | JS_BUTTON4, // 5D0D |
516 | JS_BUTTON5, | 441 | JS_BUTTON5, // 5D0E |
517 | JS_BUTTON6, | 442 | JS_BUTTON6, // 5D0F |
518 | JS_BUTTON7, | 443 | JS_BUTTON7, // 5D10 |
519 | JS_BUTTON8, | 444 | JS_BUTTON8, // 5D11 |
520 | JS_BUTTON9, | 445 | JS_BUTTON9, // 5D12 |
521 | JS_BUTTON10, | 446 | JS_BUTTON10, // 5D13 |
522 | JS_BUTTON11, | 447 | JS_BUTTON11, // 5D14 |
523 | JS_BUTTON12, | 448 | JS_BUTTON12, // 5D15 |
524 | JS_BUTTON13, | 449 | JS_BUTTON13, // 5D16 |
525 | JS_BUTTON14, | 450 | JS_BUTTON14, // 5D17 |
526 | JS_BUTTON15, | 451 | JS_BUTTON15, // 5D18 |
527 | JS_BUTTON16, | 452 | JS_BUTTON16, // 5D19 |
528 | JS_BUTTON17, | 453 | JS_BUTTON17, // 5D1A |
529 | JS_BUTTON18, | 454 | JS_BUTTON18, // 5D1B |
530 | JS_BUTTON19, | 455 | JS_BUTTON19, // 5D1C |
531 | JS_BUTTON20, | 456 | JS_BUTTON20, // 5D1D |
532 | JS_BUTTON21, | 457 | JS_BUTTON21, // 5D1E |
533 | JS_BUTTON22, | 458 | JS_BUTTON22, // 5D1F |
534 | JS_BUTTON23, | 459 | JS_BUTTON23, // 5D20 |
535 | JS_BUTTON24, | 460 | JS_BUTTON24, // 5D21 |
536 | JS_BUTTON25, | 461 | JS_BUTTON25, // 5D22 |
537 | JS_BUTTON26, | 462 | JS_BUTTON26, // 5D23 |
538 | JS_BUTTON27, | 463 | JS_BUTTON27, // 5D24 |
539 | JS_BUTTON28, | 464 | JS_BUTTON28, // 5D25 |
540 | JS_BUTTON29, | 465 | JS_BUTTON29, // 5D26 |
541 | JS_BUTTON30, | 466 | JS_BUTTON30, // 5D27 |
542 | JS_BUTTON31, | 467 | JS_BUTTON31, // 5D28 |
543 | JS_BUTTON_MAX = JS_BUTTON31, | 468 | |
544 | 469 | // Leader Key | |
545 | #if defined(SEQUENCER_ENABLE) | 470 | KC_LEAD, // 5D29 |
546 | SQ_ON, | 471 | |
547 | SQ_OFF, | 472 | // Bluetooth: output selection (continued) |
548 | SQ_TOG, | 473 | OUT_BT, // 5D2A |
549 | 474 | ||
550 | SQ_TMPD, // Decrease tempo | 475 | // Lock Key |
551 | SQ_TMPU, // Increase tempo | 476 | KC_LOCK, // 5D2B |
477 | |||
478 | // Terminal | ||
479 | TERM_ON, // 5D2C | ||
480 | TERM_OFF, // 5D2D | ||
481 | |||
482 | // Sequencer | ||
483 | SQ_ON, // 5D2E | ||
484 | SQ_OFF, // 5D2F | ||
485 | SQ_TOG, // 5D30 | ||
486 | |||
487 | SQ_TMPD, // 5D31 | ||
488 | SQ_TMPU, // 5D32 | ||
489 | |||
490 | SQ_RESD, // 5D33 | ||
491 | SQ_RESU, // 5D34 | ||
492 | |||
493 | SQ_SALL, // 5D35 | ||
494 | SQ_SCLR, // 5D36 | ||
495 | |||
496 | SEQUENCER_STEP_MIN, // 5D37 | ||
497 | SEQUENCER_STEP_MAX = SEQUENCER_STEP_MIN + SEQUENCER_STEPS, | ||
552 | 498 | ||
553 | SEQUENCER_RESOLUTION_MIN, | 499 | SEQUENCER_RESOLUTION_MIN, |
554 | SEQUENCER_RESOLUTION_MAX = SEQUENCER_RESOLUTION_MIN + SEQUENCER_RESOLUTIONS, | 500 | SEQUENCER_RESOLUTION_MAX = SEQUENCER_RESOLUTION_MIN + SEQUENCER_RESOLUTIONS, |
555 | SQ_RESD, // Decrease resolution | ||
556 | SQ_RESU, // Increase resolution | ||
557 | |||
558 | SQ_SALL, // All steps on | ||
559 | SQ_SCLR, // All steps off | ||
560 | SEQUENCER_STEP_MIN, | ||
561 | SEQUENCER_STEP_MAX = SEQUENCER_STEP_MIN + SEQUENCER_STEPS, | ||
562 | 501 | ||
563 | SEQUENCER_TRACK_MIN, | 502 | SEQUENCER_TRACK_MIN, |
564 | SEQUENCER_TRACK_MAX = SEQUENCER_TRACK_MIN + SEQUENCER_TRACKS, | 503 | SEQUENCER_TRACK_MAX = SEQUENCER_TRACK_MIN + SEQUENCER_TRACKS, |
565 | 504 | ||
566 | /** | 505 | #define SQ_S(n) (n < SEQUENCER_STEPS ? SEQUENCER_STEP_MIN + n : KC_NO) |
567 | * Helpers to assign a keycode to a step, a resolution, or a track. | 506 | #define SQ_R(n) (n < SEQUENCER_RESOLUTIONS ? SEQUENCER_RESOLUTION_MIN + n : KC_NO) |
568 | * Falls back to NOOP if n is out of range. | 507 | #define SQ_T(n) (n < SEQUENCER_TRACKS ? SEQUENCER_TRACK_MIN + n : KC_NO) |
569 | */ | ||
570 | # define SQ_S(n) (n < SEQUENCER_STEPS ? SEQUENCER_STEP_MIN + n : XXXXXXX) | ||
571 | # define SQ_R(n) (n < SEQUENCER_RESOLUTIONS ? SEQUENCER_RESOLUTION_MIN + n : XXXXXXX) | ||
572 | # define SQ_T(n) (n < SEQUENCER_TRACKS ? SEQUENCER_TRACK_MIN + n : XXXXXXX) | ||
573 | 508 | ||
574 | #endif | 509 | // One Shot |
510 | ONESHOT_ENABLE, | ||
511 | ONESHOT_DISABLE, | ||
512 | ONESHOT_TOGGLE, | ||
513 | |||
514 | // RGB underglow/matrix (continued) | ||
515 | RGB_MODE_TWINKLE, | ||
575 | 516 | ||
576 | // always leave at the end | 517 | // Start of custom keycode range for keyboards and keymaps - always leave at the end |
577 | SAFE_RANGE | 518 | SAFE_RANGE |
578 | }; | 519 | }; |
579 | 520 | ||
580 | // Ability to use mods in layouts | 521 | // Keycode modifiers & aliases |
581 | #define LCTL(kc) (QK_LCTL | (kc)) | 522 | #define LCTL(kc) (QK_LCTL | (kc)) |
582 | #define LSFT(kc) (QK_LSFT | (kc)) | 523 | #define LSFT(kc) (QK_LSFT | (kc)) |
583 | #define LALT(kc) (QK_LALT | (kc)) | 524 | #define LALT(kc) (QK_LALT | (kc)) |
@@ -609,11 +550,7 @@ enum quantum_keycodes { | |||
609 | #define MOD_HYPR 0xF | 550 | #define MOD_HYPR 0xF |
610 | #define MOD_MEH 0x7 | 551 | #define MOD_MEH 0x7 |
611 | 552 | ||
612 | // Aliases for shifted symbols | 553 | // US ANSI shifted keycode aliases |
613 | // Each key has a 4-letter code, and some have longer aliases too. | ||
614 | // While the long aliases are descriptive, the 4-letter codes | ||
615 | // make for nicer grid layouts (everything lines up), and are | ||
616 | // the preferred style for Quantum. | ||
617 | #define KC_TILD LSFT(KC_GRV) // ~ | 554 | #define KC_TILD LSFT(KC_GRV) // ~ |
618 | #define KC_TILDE KC_TILD | 555 | #define KC_TILDE KC_TILD |
619 | 556 | ||
@@ -680,18 +617,15 @@ enum quantum_keycodes { | |||
680 | 617 | ||
681 | #define KC_DELT KC_DELETE // Del key (four letter code) | 618 | #define KC_DELT KC_DELETE // Del key (four letter code) |
682 | 619 | ||
683 | // Alias for function layers than expand past FN31 | 620 | // Modified keycode aliases |
684 | #define FUNC(kc) (QK_FUNCTION | (kc)) | ||
685 | |||
686 | // Aliases | ||
687 | #define C(kc) LCTL(kc) | 621 | #define C(kc) LCTL(kc) |
688 | #define S(kc) LSFT(kc) | 622 | #define S(kc) LSFT(kc) |
689 | #define A(kc) LALT(kc) | 623 | #define A(kc) LALT(kc) |
690 | #define G(kc) LGUI(kc) | 624 | #define G(kc) LGUI(kc) |
691 | 625 | ||
692 | #define F(kc) FUNC(kc) | 626 | // Deprecated - do not use |
627 | #define F(kc) (QK_FUNCTION | (kc)) | ||
693 | #define M(kc) (QK_MACRO | (kc)) | 628 | #define M(kc) (QK_MACRO | (kc)) |
694 | |||
695 | #define MACROTAP(kc) (QK_MACRO | (FUNC_TAP << 8) | (kc)) | 629 | #define MACROTAP(kc) (QK_MACRO | (FUNC_TAP << 8) | (kc)) |
696 | #define MACRODOWN(...) (record->event.pressed ? MACRO(__VA_ARGS__) : MACRO_NONE) | 630 | #define MACRODOWN(...) (record->event.pressed ? MACRO(__VA_ARGS__) : MACRO_NONE) |
697 | 631 | ||
@@ -699,19 +633,21 @@ enum quantum_keycodes { | |||
699 | 633 | ||
700 | #define EEP_RST EEPROM_RESET | 634 | #define EEP_RST EEPROM_RESET |
701 | 635 | ||
636 | // Audio Clicky aliases | ||
702 | #define CK_TOGG CLICKY_TOGGLE | 637 | #define CK_TOGG CLICKY_TOGGLE |
703 | #define CK_RST CLICKY_RESET | 638 | #define CK_RST CLICKY_RESET |
704 | #define CK_UP CLICKY_UP | 639 | #define CK_UP CLICKY_UP |
705 | #define CK_DOWN CLICKY_DOWN | 640 | #define CK_DOWN CLICKY_DOWN |
706 | #define CK_ON CLICKY_ENABLE | 641 | #define CK_ON CLICKY_ENABLE |
707 | #define CK_OFF CLICKY_DISABLE | 642 | #define CK_OFF CLICKY_DISABLE |
643 | // Fauxclicky (deprecated) redirects to Audio Clicky | ||
708 | #define FC_ON CLICKY_ENABLE | 644 | #define FC_ON CLICKY_ENABLE |
709 | #define FC_OFF CLICKY_DISABLE | 645 | #define FC_OFF CLICKY_DISABLE |
710 | #define FC_TOGG CLICKY_TOGGLE | 646 | #define FC_TOGG CLICKY_TOGGLE |
711 | 647 | ||
648 | // RGB aliases | ||
712 | #define RGB_MOD RGB_MODE_FORWARD | 649 | #define RGB_MOD RGB_MODE_FORWARD |
713 | #define RGB_RMOD RGB_MODE_REVERSE | 650 | #define RGB_RMOD RGB_MODE_REVERSE |
714 | |||
715 | #define RGB_M_P RGB_MODE_PLAIN | 651 | #define RGB_M_P RGB_MODE_PLAIN |
716 | #define RGB_M_B RGB_MODE_BREATHE | 652 | #define RGB_M_B RGB_MODE_BREATHE |
717 | #define RGB_M_R RGB_MODE_RAINBOW | 653 | #define RGB_M_R RGB_MODE_RAINBOW |
@@ -721,10 +657,9 @@ enum quantum_keycodes { | |||
721 | #define RGB_M_X RGB_MODE_XMAS | 657 | #define RGB_M_X RGB_MODE_XMAS |
722 | #define RGB_M_G RGB_MODE_GRADIENT | 658 | #define RGB_M_G RGB_MODE_GRADIENT |
723 | #define RGB_M_T RGB_MODE_RGBTEST | 659 | #define RGB_M_T RGB_MODE_RGBTEST |
660 | #define RGB_M_TW RGB_MODE_TWINKLE | ||
724 | 661 | ||
725 | // L-ayer, T-ap - 256 keycode max, 16 layer max | 662 | // Magic aliases |
726 | #define LT(layer, kc) (QK_LAYER_TAP | (((layer)&0xF) << 8) | ((kc)&0xFF)) | ||
727 | |||
728 | #define CL_SWAP MAGIC_SWAP_CONTROL_CAPSLOCK | 663 | #define CL_SWAP MAGIC_SWAP_CONTROL_CAPSLOCK |
729 | #define CL_NORM MAGIC_UNSWAP_CONTROL_CAPSLOCK | 664 | #define CL_NORM MAGIC_UNSWAP_CONTROL_CAPSLOCK |
730 | #define CL_CTRL MAGIC_CAPSLOCK_TO_CONTROL | 665 | #define CL_CTRL MAGIC_CAPSLOCK_TO_CONTROL |
@@ -793,6 +728,9 @@ enum quantum_keycodes { | |||
793 | // Layer tap-toggle | 728 | // Layer tap-toggle |
794 | #define TT(layer) (QK_LAYER_TAP_TOGGLE | ((layer)&0xFF)) | 729 | #define TT(layer) (QK_LAYER_TAP_TOGGLE | ((layer)&0xFF)) |
795 | 730 | ||
731 | // L-ayer, T-ap - 256 keycode max, 16 layer max | ||
732 | #define LT(layer, kc) (QK_LAYER_TAP | (((layer)&0xF) << 8) | ((kc)&0xFF)) | ||
733 | |||
796 | // M-od, T-ap - 256 keycode max | 734 | // M-od, T-ap - 256 keycode max |
797 | #define MT(mod, kc) (QK_MOD_TAP | (((mod)&0x1F) << 8) | ((kc)&0xFF)) | 735 | #define MT(mod, kc) (QK_MOD_TAP | (((mod)&0x1F) << 8) | ((kc)&0xFF)) |
798 | 736 | ||
@@ -842,6 +780,7 @@ enum quantum_keycodes { | |||
842 | #define KC_HYPR HYPR(KC_NO) | 780 | #define KC_HYPR HYPR(KC_NO) |
843 | #define KC_MEH MEH(KC_NO) | 781 | #define KC_MEH MEH(KC_NO) |
844 | 782 | ||
783 | // Unicode aliases | ||
845 | // UNICODE_ENABLE - Allows Unicode input up to 0x7FFF | 784 | // UNICODE_ENABLE - Allows Unicode input up to 0x7FFF |
846 | #define UC(c) (QK_UNICODE | (c)) | 785 | #define UC(c) (QK_UNICODE | (c)) |
847 | // UNICODEMAP_ENABLE - Allows Unicode input up to 0x10FFFF, requires unicode_map | 786 | // UNICODEMAP_ENABLE - Allows Unicode input up to 0x10FFFF, requires unicode_map |
@@ -859,6 +798,7 @@ enum quantum_keycodes { | |||
859 | #define UC_M_BS UNICODE_MODE_BSD | 798 | #define UC_M_BS UNICODE_MODE_BSD |
860 | #define UC_M_WC UNICODE_MODE_WINC | 799 | #define UC_M_WC UNICODE_MODE_WINC |
861 | 800 | ||
801 | // Swap Hands | ||
862 | #define SH_T(kc) (QK_SWAP_HANDS | (kc)) | 802 | #define SH_T(kc) (QK_SWAP_HANDS | (kc)) |
863 | #define SH_TG (QK_SWAP_HANDS | OP_SH_TOGGLE) | 803 | #define SH_TG (QK_SWAP_HANDS | OP_SH_TOGGLE) |
864 | #define SH_TT (QK_SWAP_HANDS | OP_SH_TAP_TOGGLE) | 804 | #define SH_TT (QK_SWAP_HANDS | OP_SH_TAP_TOGGLE) |
@@ -868,9 +808,30 @@ enum quantum_keycodes { | |||
868 | #define SH_ON (QK_SWAP_HANDS | OP_SH_ON) | 808 | #define SH_ON (QK_SWAP_HANDS | OP_SH_ON) |
869 | #define SH_OFF (QK_SWAP_HANDS | OP_SH_OFF) | 809 | #define SH_OFF (QK_SWAP_HANDS | OP_SH_OFF) |
870 | 810 | ||
811 | // MIDI aliases | ||
812 | #define MIDI_TONE_MIN MI_C | ||
813 | #define MIDI_TONE_MAX MI_B_5 | ||
814 | #define MIDI_OCTAVE_MIN MI_OCT_N2 | ||
815 | #define MIDI_OCTAVE_MAX MI_OCT_7 | ||
816 | #define MIDI_TRANSPOSE_MIN MI_TRNS_N6 | ||
817 | #define MIDI_TRANSPOSE_MAX MI_TRNS_6 | ||
818 | #define MIDI_VELOCITY_MIN MI_VEL_0 | ||
819 | #define MIDI_VELOCITY_MAX MI_VEL_10 | ||
820 | #define MIDI_CHANNEL_MIN MI_CH1 | ||
821 | #define MIDI_CHANNEL_MAX MI_CH16 | ||
822 | |||
871 | // Dynamic Macros aliases | 823 | // Dynamic Macros aliases |
872 | #define DM_REC1 DYN_REC_START1 | 824 | #define DM_REC1 DYN_REC_START1 |
873 | #define DM_REC2 DYN_REC_START2 | 825 | #define DM_REC2 DYN_REC_START2 |
874 | #define DM_RSTP DYN_REC_STOP | 826 | #define DM_RSTP DYN_REC_STOP |
875 | #define DM_PLY1 DYN_MACRO_PLAY1 | 827 | #define DM_PLY1 DYN_MACRO_PLAY1 |
876 | #define DM_PLY2 DYN_MACRO_PLAY2 | 828 | #define DM_PLY2 DYN_MACRO_PLAY2 |
829 | |||
830 | // Joystick aliases | ||
831 | #define JS_BUTTON_MIN JS_BUTTON0 | ||
832 | #define JS_BUTTON_MAX JS_BUTTON31 | ||
833 | |||
834 | // One Shot aliases | ||
835 | #define OS_TOGG ONESHOT_TOGGLE | ||
836 | #define OS_ON ONESHOT_ENABLE | ||
837 | #define OS_OFF ONESHOT_DISABLE | ||
diff --git a/quantum/rgb_matrix.c b/quantum/rgb_matrix.c index ec17b4d72..8aae48603 100644 --- a/quantum/rgb_matrix.c +++ b/quantum/rgb_matrix.c | |||
@@ -131,7 +131,7 @@ last_hit_t g_last_hit_tracker; | |||
131 | // internals | 131 | // internals |
132 | static uint8_t rgb_last_enable = UINT8_MAX; | 132 | static uint8_t rgb_last_enable = UINT8_MAX; |
133 | static uint8_t rgb_last_effect = UINT8_MAX; | 133 | static uint8_t rgb_last_effect = UINT8_MAX; |
134 | static effect_params_t rgb_effect_params = {0, 0xFF}; | 134 | static effect_params_t rgb_effect_params = {0, LED_FLAG_ALL, false}; |
135 | static rgb_task_states rgb_task_state = SYNCING; | 135 | static rgb_task_states rgb_task_state = SYNCING; |
136 | #if RGB_DISABLE_TIMEOUT > 0 | 136 | #if RGB_DISABLE_TIMEOUT > 0 |
137 | static uint32_t rgb_anykey_timer; | 137 | static uint32_t rgb_anykey_timer; |
@@ -143,6 +143,11 @@ static uint32_t rgb_timer_buffer; | |||
143 | static last_hit_t last_hit_buffer; | 143 | static last_hit_t last_hit_buffer; |
144 | #endif // RGB_MATRIX_KEYREACTIVE_ENABLED | 144 | #endif // RGB_MATRIX_KEYREACTIVE_ENABLED |
145 | 145 | ||
146 | // split rgb matrix | ||
147 | #if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
148 | const uint8_t k_rgb_matrix_split[2] = RGB_MATRIX_SPLIT; | ||
149 | #endif | ||
150 | |||
146 | void eeconfig_read_rgb_matrix(void) { eeprom_read_block(&rgb_matrix_config, EECONFIG_RGB_MATRIX, sizeof(rgb_matrix_config)); } | 151 | void eeconfig_read_rgb_matrix(void) { eeprom_read_block(&rgb_matrix_config, EECONFIG_RGB_MATRIX, sizeof(rgb_matrix_config)); } |
147 | 152 | ||
148 | void eeconfig_update_rgb_matrix(void) { eeprom_update_block(&rgb_matrix_config, EECONFIG_RGB_MATRIX, sizeof(rgb_matrix_config)); } | 153 | void eeconfig_update_rgb_matrix(void) { eeprom_update_block(&rgb_matrix_config, EECONFIG_RGB_MATRIX, sizeof(rgb_matrix_config)); } |
@@ -153,6 +158,7 @@ void eeconfig_update_rgb_matrix_default(void) { | |||
153 | rgb_matrix_config.mode = RGB_MATRIX_STARTUP_MODE; | 158 | rgb_matrix_config.mode = RGB_MATRIX_STARTUP_MODE; |
154 | rgb_matrix_config.hsv = (HSV){RGB_MATRIX_STARTUP_HUE, RGB_MATRIX_STARTUP_SAT, RGB_MATRIX_STARTUP_VAL}; | 159 | rgb_matrix_config.hsv = (HSV){RGB_MATRIX_STARTUP_HUE, RGB_MATRIX_STARTUP_SAT, RGB_MATRIX_STARTUP_VAL}; |
155 | rgb_matrix_config.speed = RGB_MATRIX_STARTUP_SPD; | 160 | rgb_matrix_config.speed = RGB_MATRIX_STARTUP_SPD; |
161 | rgb_matrix_config.flags = LED_FLAG_ALL; | ||
156 | eeconfig_update_rgb_matrix(); | 162 | eeconfig_update_rgb_matrix(); |
157 | } | 163 | } |
158 | 164 | ||
@@ -164,6 +170,7 @@ void eeconfig_debug_rgb_matrix(void) { | |||
164 | dprintf("rgb_matrix_config.hsv.s = %d\n", rgb_matrix_config.hsv.s); | 170 | dprintf("rgb_matrix_config.hsv.s = %d\n", rgb_matrix_config.hsv.s); |
165 | dprintf("rgb_matrix_config.hsv.v = %d\n", rgb_matrix_config.hsv.v); | 171 | dprintf("rgb_matrix_config.hsv.v = %d\n", rgb_matrix_config.hsv.v); |
166 | dprintf("rgb_matrix_config.speed = %d\n", rgb_matrix_config.speed); | 172 | dprintf("rgb_matrix_config.speed = %d\n", rgb_matrix_config.speed); |
173 | dprintf("rgb_matrix_config.flags = %d\n", rgb_matrix_config.flags); | ||
167 | } | 174 | } |
168 | 175 | ||
169 | __attribute__((weak)) uint8_t rgb_matrix_map_row_column_to_led_kb(uint8_t row, uint8_t column, uint8_t *led_i) { return 0; } | 176 | __attribute__((weak)) uint8_t rgb_matrix_map_row_column_to_led_kb(uint8_t row, uint8_t column, uint8_t *led_i) { return 0; } |
@@ -180,9 +187,22 @@ uint8_t rgb_matrix_map_row_column_to_led(uint8_t row, uint8_t column, uint8_t *l | |||
180 | 187 | ||
181 | void rgb_matrix_update_pwm_buffers(void) { rgb_matrix_driver.flush(); } | 188 | void rgb_matrix_update_pwm_buffers(void) { rgb_matrix_driver.flush(); } |
182 | 189 | ||
183 | void rgb_matrix_set_color(int index, uint8_t red, uint8_t green, uint8_t blue) { rgb_matrix_driver.set_color(index, red, green, blue); } | 190 | void rgb_matrix_set_color(int index, uint8_t red, uint8_t green, uint8_t blue) { |
191 | #if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
192 | if (!is_keyboard_left() && index >= k_rgb_matrix_split[0]) | ||
193 | rgb_matrix_driver.set_color(index - k_rgb_matrix_split[0], red, green, blue); | ||
194 | else if (is_keyboard_left() && index < k_rgb_matrix_split[0]) | ||
195 | #endif | ||
196 | rgb_matrix_driver.set_color(index, red, green, blue); | ||
197 | } | ||
184 | 198 | ||
185 | void rgb_matrix_set_color_all(uint8_t red, uint8_t green, uint8_t blue) { rgb_matrix_driver.set_color_all(red, green, blue); } | 199 | void rgb_matrix_set_color_all(uint8_t red, uint8_t green, uint8_t blue) { |
200 | #if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
201 | for (uint8_t i = 0; i < DRIVER_LED_TOTAL; i++) rgb_matrix_set_color(i, red, green, blue); | ||
202 | #else | ||
203 | rgb_matrix_driver.set_color_all(red, green, blue); | ||
204 | #endif | ||
205 | } | ||
186 | 206 | ||
187 | void process_rgb_matrix(uint8_t row, uint8_t col, bool pressed) { | 207 | void process_rgb_matrix(uint8_t row, uint8_t col, bool pressed) { |
188 | #ifndef RGB_MATRIX_SPLIT | 208 | #ifndef RGB_MATRIX_SPLIT |
@@ -315,6 +335,10 @@ static void rgb_task_start(void) { | |||
315 | static void rgb_task_render(uint8_t effect) { | 335 | static void rgb_task_render(uint8_t effect) { |
316 | bool rendering = false; | 336 | bool rendering = false; |
317 | rgb_effect_params.init = (effect != rgb_last_effect) || (rgb_matrix_config.enable != rgb_last_enable); | 337 | rgb_effect_params.init = (effect != rgb_last_effect) || (rgb_matrix_config.enable != rgb_last_enable); |
338 | if (rgb_effect_params.flags != rgb_matrix_config.flags) { | ||
339 | rgb_effect_params.flags = rgb_matrix_config.flags; | ||
340 | rgb_matrix_set_color_all(0, 0, 0); | ||
341 | } | ||
318 | 342 | ||
319 | // each effect can opt to do calculations | 343 | // each effect can opt to do calculations |
320 | // and/or request PWM buffer updates. | 344 | // and/or request PWM buffer updates. |
@@ -618,6 +642,6 @@ void rgb_matrix_decrease_speed_helper(bool write_to_eeprom) { rgb_matrix_set_spe | |||
618 | void rgb_matrix_decrease_speed_noeeprom(void) { rgb_matrix_decrease_speed_helper(false); } | 642 | void rgb_matrix_decrease_speed_noeeprom(void) { rgb_matrix_decrease_speed_helper(false); } |
619 | void rgb_matrix_decrease_speed(void) { rgb_matrix_decrease_speed_helper(true); } | 643 | void rgb_matrix_decrease_speed(void) { rgb_matrix_decrease_speed_helper(true); } |
620 | 644 | ||
621 | led_flags_t rgb_matrix_get_flags(void) { return rgb_effect_params.flags; } | 645 | led_flags_t rgb_matrix_get_flags(void) { return rgb_matrix_config.flags; } |
622 | 646 | ||
623 | void rgb_matrix_set_flags(led_flags_t flags) { rgb_effect_params.flags = flags; } | 647 | void rgb_matrix_set_flags(led_flags_t flags) { rgb_matrix_config.flags = flags; } |
diff --git a/quantum/rgb_matrix_types.h b/quantum/rgb_matrix_types.h index 7b8171fb2..1a37922af 100644 --- a/quantum/rgb_matrix_types.h +++ b/quantum/rgb_matrix_types.h | |||
@@ -85,10 +85,11 @@ typedef struct PACKED { | |||
85 | typedef union { | 85 | typedef union { |
86 | uint32_t raw; | 86 | uint32_t raw; |
87 | struct PACKED { | 87 | struct PACKED { |
88 | uint8_t enable : 2; | 88 | uint8_t enable : 2; |
89 | uint8_t mode : 6; | 89 | uint8_t mode : 6; |
90 | HSV hsv; | 90 | HSV hsv; |
91 | uint8_t speed; // EECONFIG needs to be increased to support this | 91 | uint8_t speed; // EECONFIG needs to be increased to support this |
92 | led_flags_t flags; | ||
92 | }; | 93 | }; |
93 | } rgb_config_t; | 94 | } rgb_config_t; |
94 | 95 | ||
diff --git a/quantum/split_common/matrix.c b/quantum/split_common/matrix.c index d6636b886..f8de17809 100644 --- a/quantum/split_common/matrix.c +++ b/quantum/split_common/matrix.c | |||
@@ -43,6 +43,7 @@ extern matrix_row_t matrix[MATRIX_ROWS]; // debounced values | |||
43 | uint8_t thisHand, thatHand; | 43 | uint8_t thisHand, thatHand; |
44 | 44 | ||
45 | // user-defined overridable functions | 45 | // user-defined overridable functions |
46 | __attribute__((weak)) void matrix_slave_scan_kb(void) { matrix_slave_scan_user(); } | ||
46 | __attribute__((weak)) void matrix_slave_scan_user(void) {} | 47 | __attribute__((weak)) void matrix_slave_scan_user(void) {} |
47 | 48 | ||
48 | static inline void setPinOutput_writeLow(pin_t pin) { | 49 | static inline void setPinOutput_writeLow(pin_t pin) { |
@@ -284,7 +285,7 @@ bool matrix_post_scan(void) { | |||
284 | } else { | 285 | } else { |
285 | transport_slave(matrix + thatHand, matrix + thisHand); | 286 | transport_slave(matrix + thatHand, matrix + thisHand); |
286 | 287 | ||
287 | matrix_slave_scan_user(); | 288 | matrix_slave_scan_kb(); |
288 | } | 289 | } |
289 | 290 | ||
290 | return changed; | 291 | return changed; |
diff --git a/quantum/split_common/split_util.c b/quantum/split_common/split_util.c index 2ae44e6e1..9e75e19ce 100644 --- a/quantum/split_common/split_util.c +++ b/quantum/split_common/split_util.c | |||
@@ -1,3 +1,18 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
1 | #include "split_util.h" | 16 | #include "split_util.h" |
2 | #include "matrix.h" | 17 | #include "matrix.h" |
3 | #include "keyboard.h" | 18 | #include "keyboard.h" |
@@ -6,14 +21,7 @@ | |||
6 | #include "transport.h" | 21 | #include "transport.h" |
7 | #include "quantum.h" | 22 | #include "quantum.h" |
8 | #include "wait.h" | 23 | #include "wait.h" |
9 | 24 | #include "usb_util.h" | |
10 | #ifdef PROTOCOL_LUFA | ||
11 | # include <LUFA/Drivers/USB/USB.h> | ||
12 | #endif | ||
13 | |||
14 | #ifdef PROTOCOL_VUSB | ||
15 | # include <usbdrv/usbdrv.h> | ||
16 | #endif | ||
17 | 25 | ||
18 | #ifdef EE_HANDS | 26 | #ifdef EE_HANDS |
19 | # include "eeconfig.h" | 27 | # include "eeconfig.h" |
@@ -31,56 +39,21 @@ | |||
31 | # define SPLIT_USB_TIMEOUT_POLL 10 | 39 | # define SPLIT_USB_TIMEOUT_POLL 10 |
32 | #endif | 40 | #endif |
33 | 41 | ||
34 | #ifdef PROTOCOL_CHIBIOS | ||
35 | # define SPLIT_USB_DETECT // Force this on for now | ||
36 | #endif | ||
37 | |||
38 | volatile bool isLeftHand = true; | 42 | volatile bool isLeftHand = true; |
39 | 43 | ||
40 | #if defined(SPLIT_USB_DETECT) | 44 | #if defined(SPLIT_USB_DETECT) |
41 | # if defined(PROTOCOL_LUFA) | 45 | static bool usbIsActive(void) { |
42 | static inline bool usbHasActiveConnection(void) { return USB_Device_IsAddressSet(); } | ||
43 | static inline void usbDisable(void) { | ||
44 | USB_Disable(); | ||
45 | USB_DeviceState = DEVICE_STATE_Unattached; | ||
46 | } | ||
47 | # elif defined(PROTOCOL_CHIBIOS) | ||
48 | static inline bool usbHasActiveConnection(void) { return usbGetDriverStateI(&USBD1) == USB_ACTIVE; } | ||
49 | static inline void usbDisable(void) { usbStop(&USBD1); } | ||
50 | # elif defined(PROTOCOL_VUSB) | ||
51 | static inline bool usbHasActiveConnection(void) { | ||
52 | usbPoll(); | ||
53 | return usbConfiguration; | ||
54 | } | ||
55 | static inline void usbDisable(void) { usbDeviceDisconnect(); } | ||
56 | # else | ||
57 | static inline bool usbHasActiveConnection(void) { return true; } | ||
58 | static inline void usbDisable(void) {} | ||
59 | # endif | ||
60 | |||
61 | bool usbIsActive(void) { | ||
62 | for (uint8_t i = 0; i < (SPLIT_USB_TIMEOUT / SPLIT_USB_TIMEOUT_POLL); i++) { | 46 | for (uint8_t i = 0; i < (SPLIT_USB_TIMEOUT / SPLIT_USB_TIMEOUT_POLL); i++) { |
63 | // This will return true if a USB connection has been established | 47 | // This will return true if a USB connection has been established |
64 | if (usbHasActiveConnection()) { | 48 | if (usb_connected_state()) { |
65 | return true; | 49 | return true; |
66 | } | 50 | } |
67 | wait_ms(SPLIT_USB_TIMEOUT_POLL); | 51 | wait_ms(SPLIT_USB_TIMEOUT_POLL); |
68 | } | 52 | } |
69 | |||
70 | // Avoid NO_USB_STARTUP_CHECK - Disable USB as the previous checks seem to enable it somehow | ||
71 | usbDisable(); | ||
72 | |||
73 | return false; | 53 | return false; |
74 | } | 54 | } |
75 | #elif defined(PROTOCOL_LUFA) && defined(OTGPADE) | ||
76 | static inline bool usbIsActive(void) { | ||
77 | USB_OTGPAD_On(); // enables VBUS pad | ||
78 | wait_us(5); | ||
79 | |||
80 | return USB_VBUS_GetStatus(); // checks state of VBUS | ||
81 | } | ||
82 | #else | 55 | #else |
83 | static inline bool usbIsActive(void) { return true; } | 56 | static inline bool usbIsActive(void) { return usb_vbus_state(); } |
84 | #endif | 57 | #endif |
85 | 58 | ||
86 | #ifdef SPLIT_HAND_MATRIX_GRID | 59 | #ifdef SPLIT_HAND_MATRIX_GRID |
@@ -126,6 +99,11 @@ __attribute__((weak)) bool is_keyboard_master(void) { | |||
126 | // only check once, as this is called often | 99 | // only check once, as this is called often |
127 | if (usbstate == UNKNOWN) { | 100 | if (usbstate == UNKNOWN) { |
128 | usbstate = usbIsActive() ? MASTER : SLAVE; | 101 | usbstate = usbIsActive() ? MASTER : SLAVE; |
102 | |||
103 | // Avoid NO_USB_STARTUP_CHECK - Disable USB as the previous checks seem to enable it somehow | ||
104 | if (usbstate == SLAVE) { | ||
105 | usb_disable(); | ||
106 | } | ||
129 | } | 107 | } |
130 | 108 | ||
131 | return (usbstate == MASTER); | 109 | return (usbstate == MASTER); |
diff --git a/quantum/split_common/transport.c b/quantum/split_common/transport.c index 61b61ea08..b67702f15 100644 --- a/quantum/split_common/transport.c +++ b/quantum/split_common/transport.c | |||
@@ -22,6 +22,13 @@ static pin_t encoders_pad[] = ENCODERS_PAD_A; | |||
22 | # define NUMBER_OF_ENCODERS (sizeof(encoders_pad) / sizeof(pin_t)) | 22 | # define NUMBER_OF_ENCODERS (sizeof(encoders_pad) / sizeof(pin_t)) |
23 | #endif | 23 | #endif |
24 | 24 | ||
25 | #if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
26 | # include "led_matrix.h" | ||
27 | #endif | ||
28 | #if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
29 | # include "rgb_matrix.h" | ||
30 | #endif | ||
31 | |||
25 | #if defined(USE_I2C) | 32 | #if defined(USE_I2C) |
26 | 33 | ||
27 | # include "i2c_master.h" | 34 | # include "i2c_master.h" |
@@ -54,6 +61,14 @@ typedef struct _I2C_slave_buffer_t { | |||
54 | # ifdef WPM_ENABLE | 61 | # ifdef WPM_ENABLE |
55 | uint8_t current_wpm; | 62 | uint8_t current_wpm; |
56 | # endif | 63 | # endif |
64 | # if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
65 | led_eeconfig_t led_matrix; | ||
66 | bool led_suspend_state; | ||
67 | # endif | ||
68 | # if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
69 | rgb_config_t rgb_matrix; | ||
70 | bool rgb_suspend_state; | ||
71 | # endif | ||
57 | } I2C_slave_buffer_t; | 72 | } I2C_slave_buffer_t; |
58 | 73 | ||
59 | static I2C_slave_buffer_t *const i2c_buffer = (I2C_slave_buffer_t *)i2c_slave_reg; | 74 | static I2C_slave_buffer_t *const i2c_buffer = (I2C_slave_buffer_t *)i2c_slave_reg; |
@@ -68,6 +83,10 @@ static I2C_slave_buffer_t *const i2c_buffer = (I2C_slave_buffer_t *)i2c_slave_re | |||
68 | # define I2C_RGB_START offsetof(I2C_slave_buffer_t, rgblight_sync) | 83 | # define I2C_RGB_START offsetof(I2C_slave_buffer_t, rgblight_sync) |
69 | # define I2C_ENCODER_START offsetof(I2C_slave_buffer_t, encoder_state) | 84 | # define I2C_ENCODER_START offsetof(I2C_slave_buffer_t, encoder_state) |
70 | # define I2C_WPM_START offsetof(I2C_slave_buffer_t, current_wpm) | 85 | # define I2C_WPM_START offsetof(I2C_slave_buffer_t, current_wpm) |
86 | # define I2C_LED_MATRIX_START offsetof(I2C_slave_buffer_t, led_matrix) | ||
87 | # define I2C_LED_SUSPEND_START offsetof(I2C_slave_buffer_t, led_suspend_state) | ||
88 | # define I2C_RGB_MATRIX_START offsetof(I2C_slave_buffer_t, rgb_matrix) | ||
89 | # define I2C_RGB_SUSPEND_START offsetof(I2C_slave_buffer_t, rgb_suspend_state) | ||
71 | 90 | ||
72 | # define TIMEOUT 100 | 91 | # define TIMEOUT 100 |
73 | 92 | ||
@@ -141,6 +160,15 @@ bool transport_master(matrix_row_t master_matrix[], matrix_row_t slave_matrix[]) | |||
141 | # endif | 160 | # endif |
142 | # endif | 161 | # endif |
143 | 162 | ||
163 | # if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
164 | i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_LED_MATRIX_START, (void *)led_matrix_eeconfig, sizeof(i2c_buffer->led_matrix), TIMEOUT); | ||
165 | i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_LED_SUSPEND_START, (void *)g_suspend_state, sizeof(i2c_buffer->led_suspend_state), TIMEOUT); | ||
166 | # endif | ||
167 | # if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
168 | i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_RGB_MATRIX_START, (void *)rgb_matrix_config, sizeof(i2c_buffer->rgb_matrix), TIMEOUT); | ||
169 | i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_RGB_SUSPEND_START, (void *)g_suspend_state, sizeof(i2c_buffer->rgb_suspend_state), TIMEOUT); | ||
170 | # endif | ||
171 | |||
144 | # ifndef DISABLE_SYNC_TIMER | 172 | # ifndef DISABLE_SYNC_TIMER |
145 | i2c_buffer->sync_timer = sync_timer_read32() + SYNC_TIMER_OFFSET; | 173 | i2c_buffer->sync_timer = sync_timer_read32() + SYNC_TIMER_OFFSET; |
146 | i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_SYNC_TIME_START, (void *)&i2c_buffer->sync_timer, sizeof(i2c_buffer->sync_timer), TIMEOUT); | 174 | i2c_writeReg(SLAVE_I2C_ADDRESS, I2C_SYNC_TIME_START, (void *)&i2c_buffer->sync_timer, sizeof(i2c_buffer->sync_timer), TIMEOUT); |
@@ -186,6 +214,15 @@ void transport_slave(matrix_row_t master_matrix[], matrix_row_t slave_matrix[]) | |||
186 | set_oneshot_mods(i2c_buffer->oneshot_mods); | 214 | set_oneshot_mods(i2c_buffer->oneshot_mods); |
187 | # endif | 215 | # endif |
188 | # endif | 216 | # endif |
217 | |||
218 | # if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
219 | memcpy((void *)i2c_buffer->led_matrix, (void *)led_matrix_eeconfig, sizeof(i2c_buffer->led_matrix)); | ||
220 | memcpy((void *)i2c_buffer->led_suspend_state, (void *)g_suspend_state, sizeof(i2c_buffer->led_suspend_state)); | ||
221 | # endif | ||
222 | # if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
223 | memcpy((void *)i2c_buffer->rgb_matrix, (void *)rgb_matrix_config, sizeof(i2c_buffer->rgb_matrix)); | ||
224 | memcpy((void *)i2c_buffer->rgb_suspend_state, (void *)g_suspend_state, sizeof(i2c_buffer->rgb_suspend_state)); | ||
225 | # endif | ||
189 | } | 226 | } |
190 | 227 | ||
191 | void transport_master_init(void) { i2c_init(); } | 228 | void transport_master_init(void) { i2c_init(); } |
@@ -208,23 +245,31 @@ typedef struct _Serial_s2m_buffer_t { | |||
208 | 245 | ||
209 | typedef struct _Serial_m2s_buffer_t { | 246 | typedef struct _Serial_m2s_buffer_t { |
210 | # ifdef SPLIT_MODS_ENABLE | 247 | # ifdef SPLIT_MODS_ENABLE |
211 | uint8_t real_mods; | 248 | uint8_t real_mods; |
212 | uint8_t weak_mods; | 249 | uint8_t weak_mods; |
213 | # ifndef NO_ACTION_ONESHOT | 250 | # ifndef NO_ACTION_ONESHOT |
214 | uint8_t oneshot_mods; | 251 | uint8_t oneshot_mods; |
215 | # endif | 252 | # endif |
216 | # endif | 253 | # endif |
217 | # ifndef DISABLE_SYNC_TIMER | 254 | # ifndef DISABLE_SYNC_TIMER |
218 | uint32_t sync_timer; | 255 | uint32_t sync_timer; |
219 | # endif | 256 | # endif |
220 | # ifdef SPLIT_TRANSPORT_MIRROR | 257 | # ifdef SPLIT_TRANSPORT_MIRROR |
221 | matrix_row_t mmatrix[ROWS_PER_HAND]; | 258 | matrix_row_t mmatrix[ROWS_PER_HAND]; |
222 | # endif | 259 | # endif |
223 | # ifdef BACKLIGHT_ENABLE | 260 | # ifdef BACKLIGHT_ENABLE |
224 | uint8_t backlight_level; | 261 | uint8_t backlight_level; |
225 | # endif | 262 | # endif |
226 | # ifdef WPM_ENABLE | 263 | # ifdef WPM_ENABLE |
227 | uint8_t current_wpm; | 264 | uint8_t current_wpm; |
265 | # endif | ||
266 | # if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
267 | led_eeconfig_t led_matrix; | ||
268 | bool led_suspend_state; | ||
269 | # endif | ||
270 | # if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
271 | rgb_config_t rgb_matrix; | ||
272 | bool rgb_suspend_state; | ||
228 | # endif | 273 | # endif |
229 | } Serial_m2s_buffer_t; | 274 | } Serial_m2s_buffer_t; |
230 | 275 | ||
@@ -333,18 +378,28 @@ bool transport_master(matrix_row_t master_matrix[], matrix_row_t slave_matrix[]) | |||
333 | 378 | ||
334 | # ifdef WPM_ENABLE | 379 | # ifdef WPM_ENABLE |
335 | // Write wpm to slave | 380 | // Write wpm to slave |
336 | serial_m2s_buffer.current_wpm = get_current_wpm(); | 381 | serial_m2s_buffer.current_wpm = get_current_wpm(); |
337 | # endif | 382 | # endif |
338 | 383 | ||
339 | # ifdef SPLIT_MODS_ENABLE | 384 | # ifdef SPLIT_MODS_ENABLE |
340 | serial_m2s_buffer.real_mods = get_mods(); | 385 | serial_m2s_buffer.real_mods = get_mods(); |
341 | serial_m2s_buffer.weak_mods = get_weak_mods(); | 386 | serial_m2s_buffer.weak_mods = get_weak_mods(); |
342 | # ifndef NO_ACTION_ONESHOT | 387 | # ifndef NO_ACTION_ONESHOT |
343 | serial_m2s_buffer.oneshot_mods = get_oneshot_mods(); | 388 | serial_m2s_buffer.oneshot_mods = get_oneshot_mods(); |
344 | # endif | 389 | # endif |
345 | # endif | 390 | # endif |
391 | |||
392 | # if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
393 | serial_m2s_buffer.led_matrix = led_matrix_econfig; | ||
394 | serial_m2s_buffer.led_suspend_state = g_suspend_state; | ||
395 | # endif | ||
396 | # if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
397 | serial_m2s_buffer.rgb_matrix = rgb_matrix_config; | ||
398 | serial_m2s_buffer.rgb_suspend_state = g_suspend_state; | ||
399 | # endif | ||
400 | |||
346 | # ifndef DISABLE_SYNC_TIMER | 401 | # ifndef DISABLE_SYNC_TIMER |
347 | serial_m2s_buffer.sync_timer = sync_timer_read32() + SYNC_TIMER_OFFSET; | 402 | serial_m2s_buffer.sync_timer = sync_timer_read32() + SYNC_TIMER_OFFSET; |
348 | # endif | 403 | # endif |
349 | return true; | 404 | return true; |
350 | } | 405 | } |
@@ -381,6 +436,15 @@ void transport_slave(matrix_row_t master_matrix[], matrix_row_t slave_matrix[]) | |||
381 | set_oneshot_mods(serial_m2s_buffer.oneshot_mods); | 436 | set_oneshot_mods(serial_m2s_buffer.oneshot_mods); |
382 | # endif | 437 | # endif |
383 | # endif | 438 | # endif |
439 | |||
440 | # if defined(LED_MATRIX_ENABLE) && defined(LED_MATRIX_SPLIT) | ||
441 | led_matrix_eeconfig = serial_m2s_buffer.led_matrix; | ||
442 | g_suspend_state = serial_m2s_buffer.led_suspend_state; | ||
443 | # endif | ||
444 | # if defined(RGB_MATRIX_ENABLE) && defined(RGB_MATRIX_SPLIT) | ||
445 | rgb_matrix_config = serial_m2s_buffer.rgb_matrix; | ||
446 | g_suspend_state = serial_m2s_buffer.rgb_suspend_state; | ||
447 | # endif | ||
384 | } | 448 | } |
385 | 449 | ||
386 | #endif | 450 | #endif |
diff --git a/quantum/wpm.c b/quantum/wpm.c index da30bd252..bec419a48 100644 --- a/quantum/wpm.c +++ b/quantum/wpm.c | |||
@@ -19,11 +19,10 @@ | |||
19 | 19 | ||
20 | // WPM Stuff | 20 | // WPM Stuff |
21 | static uint8_t current_wpm = 0; | 21 | static uint8_t current_wpm = 0; |
22 | static uint8_t latest_wpm = 0; | ||
23 | static uint16_t wpm_timer = 0; | 22 | static uint16_t wpm_timer = 0; |
24 | 23 | ||
25 | // This smoothing is 40 keystrokes | 24 | // This smoothing is 40 keystrokes |
26 | static const float wpm_smoothing = 0.0487; | 25 | static const float wpm_smoothing = WPM_SMOOTHING; |
27 | 26 | ||
28 | void set_current_wpm(uint8_t new_wpm) { current_wpm = new_wpm; } | 27 | void set_current_wpm(uint8_t new_wpm) { current_wpm = new_wpm; } |
29 | 28 | ||
@@ -46,19 +45,46 @@ __attribute__((weak)) bool wpm_keycode_user(uint16_t keycode) { | |||
46 | return false; | 45 | return false; |
47 | } | 46 | } |
48 | 47 | ||
48 | #ifdef WPM_ALLOW_COUNT_REGRESSION | ||
49 | __attribute__((weak)) uint8_t wpm_regress_count(uint16_t keycode) { | ||
50 | bool weak_modded = (keycode >= QK_LCTL && keycode < QK_LSFT) || (keycode >= QK_RCTL && keycode < QK_RSFT); | ||
51 | |||
52 | if ((keycode >= QK_MOD_TAP && keycode <= QK_MOD_TAP_MAX) || (keycode >= QK_LAYER_TAP && keycode <= QK_LAYER_TAP_MAX) || (keycode >= QK_MODS && keycode <= QK_MODS_MAX)) { | ||
53 | keycode = keycode & 0xFF; | ||
54 | } else if (keycode > 0xFF) { | ||
55 | keycode = 0; | ||
56 | } | ||
57 | if (keycode == KC_DEL || keycode == KC_BSPC) { | ||
58 | if (((get_mods() | get_oneshot_mods()) & MOD_MASK_CTRL) || weak_modded) { | ||
59 | return WPM_ESTIMATED_WORD_SIZE; | ||
60 | } else { | ||
61 | return 1; | ||
62 | } | ||
63 | } else { | ||
64 | return 0; | ||
65 | } | ||
66 | } | ||
67 | #endif | ||
68 | |||
49 | void update_wpm(uint16_t keycode) { | 69 | void update_wpm(uint16_t keycode) { |
50 | if (wpm_keycode(keycode)) { | 70 | if (wpm_keycode(keycode)) { |
51 | if (wpm_timer > 0) { | 71 | if (wpm_timer > 0) { |
52 | latest_wpm = 60000 / timer_elapsed(wpm_timer) / 5; | 72 | current_wpm += ((60000 / timer_elapsed(wpm_timer) / WPM_ESTIMATED_WORD_SIZE) - current_wpm) * wpm_smoothing; |
53 | current_wpm = (latest_wpm - current_wpm) * wpm_smoothing + current_wpm; | ||
54 | } | 73 | } |
55 | wpm_timer = timer_read(); | 74 | wpm_timer = timer_read(); |
56 | } | 75 | } |
76 | #ifdef WPM_ALLOW_COUNT_REGRESSION | ||
77 | uint8_t regress = wpm_regress_count(keycode); | ||
78 | if (regress) { | ||
79 | current_wpm -= regress; | ||
80 | wpm_timer = timer_read(); | ||
81 | } | ||
82 | #endif | ||
57 | } | 83 | } |
58 | 84 | ||
59 | void decay_wpm(void) { | 85 | void decay_wpm(void) { |
60 | if (timer_elapsed(wpm_timer) > 1000) { | 86 | if (timer_elapsed(wpm_timer) > 1000) { |
61 | current_wpm = (0 - current_wpm) * wpm_smoothing + current_wpm; | 87 | current_wpm += (-current_wpm) * wpm_smoothing; |
62 | wpm_timer = timer_read(); | 88 | wpm_timer = timer_read(); |
63 | } | 89 | } |
64 | } | 90 | } |
diff --git a/quantum/wpm.h b/quantum/wpm.h index 15ab4ffcd..4af52d2b9 100644 --- a/quantum/wpm.h +++ b/quantum/wpm.h | |||
@@ -19,10 +19,21 @@ | |||
19 | 19 | ||
20 | #include "quantum.h" | 20 | #include "quantum.h" |
21 | 21 | ||
22 | #ifndef WPM_ESTIMATED_WORD_SIZE | ||
23 | # define WPM_ESTIMATED_WORD_SIZE 5 | ||
24 | #endif | ||
25 | #ifndef WPM_SMOOTHING | ||
26 | # define WPM_SMOOTHING 0.0487 | ||
27 | #endif | ||
28 | |||
22 | bool wpm_keycode(uint16_t keycode); | 29 | bool wpm_keycode(uint16_t keycode); |
23 | bool wpm_keycode_kb(uint16_t keycode); | 30 | bool wpm_keycode_kb(uint16_t keycode); |
24 | bool wpm_keycode_user(uint16_t keycode); | 31 | bool wpm_keycode_user(uint16_t keycode); |
25 | 32 | ||
33 | #ifdef WPM_ALLOW_COUNT_REGRESSION | ||
34 | uint8_t wpm_regress_count(uint16_t keycode); | ||
35 | #endif | ||
36 | |||
26 | void set_current_wpm(uint8_t); | 37 | void set_current_wpm(uint8_t); |
27 | uint8_t get_current_wpm(void); | 38 | uint8_t get_current_wpm(void); |
28 | void update_wpm(uint16_t); | 39 | void update_wpm(uint16_t); |
@@ -9,6 +9,12 @@ | |||
9 | 9 | ||
10 | This is a keyboard firmware based on the [tmk\_keyboard firmware](https://github.com/tmk/tmk_keyboard) with some useful features for Atmel AVR and ARM controllers, and more specifically, the [OLKB product line](https://olkb.com), the [ErgoDox EZ](https://ergodox-ez.com) keyboard, and the [Clueboard product line](https://clueboard.co). | 10 | This is a keyboard firmware based on the [tmk\_keyboard firmware](https://github.com/tmk/tmk_keyboard) with some useful features for Atmel AVR and ARM controllers, and more specifically, the [OLKB product line](https://olkb.com), the [ErgoDox EZ](https://ergodox-ez.com) keyboard, and the [Clueboard product line](https://clueboard.co). |
11 | 11 | ||
12 | # THIS IS THE DEVELOP BRANCH | ||
13 | |||
14 | Warning- This is the `develop` branch of QMK Firmware. You may encounter broken code here. Please see [Breaking Changes](https://docs.qmk.fm/#/breaking_changes) for more information. | ||
15 | |||
16 | # Original readme continues | ||
17 | |||
12 | ## Documentation | 18 | ## Documentation |
13 | 19 | ||
14 | * [See the official documentation on docs.qmk.fm](https://docs.qmk.fm) | 20 | * [See the official documentation on docs.qmk.fm](https://docs.qmk.fm) |
diff --git a/tmk_core/chibios.mk b/tmk_core/chibios.mk index 40595a1e3..cdf9ba649 100644 --- a/tmk_core/chibios.mk +++ b/tmk_core/chibios.mk | |||
@@ -190,6 +190,8 @@ else ifneq ("$(wildcard $(KEYBOARD_PATH_2)/ld/$(MCU_LDSCRIPT).ld)","") | |||
190 | LDSCRIPT = $(KEYBOARD_PATH_2)/ld/$(MCU_LDSCRIPT).ld | 190 | LDSCRIPT = $(KEYBOARD_PATH_2)/ld/$(MCU_LDSCRIPT).ld |
191 | else ifneq ("$(wildcard $(KEYBOARD_PATH_1)/ld/$(MCU_LDSCRIPT).ld)","") | 191 | else ifneq ("$(wildcard $(KEYBOARD_PATH_1)/ld/$(MCU_LDSCRIPT).ld)","") |
192 | LDSCRIPT = $(KEYBOARD_PATH_1)/ld/$(MCU_LDSCRIPT).ld | 192 | LDSCRIPT = $(KEYBOARD_PATH_1)/ld/$(MCU_LDSCRIPT).ld |
193 | else ifneq ("$(wildcard $(TOP_DIR)/platforms/chibios/$(BOARD)/ld/$(MCU_LDSCRIPT).ld)","") | ||
194 | LDSCRIPT = $(TOP_DIR)/platforms/chibios/$(BOARD)/ld/$(MCU_LDSCRIPT).ld | ||
193 | else ifneq ("$(wildcard $(TOP_DIR)/platforms/chibios/common/ld/$(MCU_LDSCRIPT).ld)","") | 195 | else ifneq ("$(wildcard $(TOP_DIR)/platforms/chibios/common/ld/$(MCU_LDSCRIPT).ld)","") |
194 | LDSCRIPT = $(TOP_DIR)/platforms/chibios/common/ld/$(MCU_LDSCRIPT).ld | 196 | LDSCRIPT = $(TOP_DIR)/platforms/chibios/common/ld/$(MCU_LDSCRIPT).ld |
195 | else ifneq ("$(wildcard $(STARTUPLD_CONTRIB)/$(MCU_LDSCRIPT).ld)","") | 197 | else ifneq ("$(wildcard $(STARTUPLD_CONTRIB)/$(MCU_LDSCRIPT).ld)","") |
diff --git a/tmk_core/common.mk b/tmk_core/common.mk index 238b3c69f..2f8f81126 100644 --- a/tmk_core/common.mk +++ b/tmk_core/common.mk | |||
@@ -12,6 +12,7 @@ TMK_COMMON_SRC += $(COMMON_DIR)/host.c \ | |||
12 | $(COMMON_DIR)/sendchar_null.c \ | 12 | $(COMMON_DIR)/sendchar_null.c \ |
13 | $(COMMON_DIR)/eeconfig.c \ | 13 | $(COMMON_DIR)/eeconfig.c \ |
14 | $(COMMON_DIR)/report.c \ | 14 | $(COMMON_DIR)/report.c \ |
15 | $(COMMON_DIR)/usb_util.c \ | ||
15 | $(PLATFORM_COMMON_DIR)/suspend.c \ | 16 | $(PLATFORM_COMMON_DIR)/suspend.c \ |
16 | $(PLATFORM_COMMON_DIR)/timer.c \ | 17 | $(PLATFORM_COMMON_DIR)/timer.c \ |
17 | $(COMMON_DIR)/sync_timer.c \ | 18 | $(COMMON_DIR)/sync_timer.c \ |
@@ -24,28 +25,6 @@ else | |||
24 | include $(TMK_PATH)/$(COMMON_DIR)/lib_printf.mk | 25 | include $(TMK_PATH)/$(COMMON_DIR)/lib_printf.mk |
25 | endif | 26 | endif |
26 | 27 | ||
27 | # Option modules | ||
28 | BOOTMAGIC_ENABLE ?= no | ||
29 | VALID_MAGIC_TYPES := yes full lite | ||
30 | ifneq ($(strip $(BOOTMAGIC_ENABLE)), no) | ||
31 | ifeq ($(filter $(BOOTMAGIC_ENABLE),$(VALID_MAGIC_TYPES)),) | ||
32 | $(error BOOTMAGIC_ENABLE="$(BOOTMAGIC_ENABLE)" is not a valid type of magic) | ||
33 | endif | ||
34 | ifeq ($(strip $(BOOTMAGIC_ENABLE)), lite) | ||
35 | TMK_COMMON_DEFS += -DBOOTMAGIC_LITE | ||
36 | TMK_COMMON_SRC += $(COMMON_DIR)/bootmagic_lite.c | ||
37 | |||
38 | TMK_COMMON_DEFS += -DMAGIC_ENABLE | ||
39 | TMK_COMMON_SRC += $(COMMON_DIR)/magic.c | ||
40 | else | ||
41 | TMK_COMMON_DEFS += -DBOOTMAGIC_ENABLE | ||
42 | TMK_COMMON_SRC += $(COMMON_DIR)/bootmagic.c | ||
43 | endif | ||
44 | else | ||
45 | TMK_COMMON_DEFS += -DMAGIC_ENABLE | ||
46 | TMK_COMMON_SRC += $(COMMON_DIR)/magic.c | ||
47 | endif | ||
48 | |||
49 | SHARED_EP_ENABLE = no | 28 | SHARED_EP_ENABLE = no |
50 | MOUSE_SHARED_EP ?= yes | 29 | MOUSE_SHARED_EP ?= yes |
51 | ifeq ($(strip $(KEYBOARD_SHARED_EP)), yes) | 30 | ifeq ($(strip $(KEYBOARD_SHARED_EP)), yes) |
diff --git a/tmk_core/common/action_util.c b/tmk_core/common/action_util.c index 000503b08..a57c8bf66 100644 --- a/tmk_core/common/action_util.c +++ b/tmk_core/common/action_util.c | |||
@@ -147,12 +147,16 @@ void clear_oneshot_swaphands(void) { | |||
147 | * FIXME: needs doc | 147 | * FIXME: needs doc |
148 | */ | 148 | */ |
149 | void set_oneshot_layer(uint8_t layer, uint8_t state) { | 149 | void set_oneshot_layer(uint8_t layer, uint8_t state) { |
150 | oneshot_layer_data = layer << 3 | state; | 150 | if (!keymap_config.oneshot_disable) { |
151 | layer_on(layer); | 151 | oneshot_layer_data = layer << 3 | state; |
152 | layer_on(layer); | ||
152 | # if (defined(ONESHOT_TIMEOUT) && (ONESHOT_TIMEOUT > 0)) | 153 | # if (defined(ONESHOT_TIMEOUT) && (ONESHOT_TIMEOUT > 0)) |
153 | oneshot_layer_time = timer_read(); | 154 | oneshot_layer_time = timer_read(); |
154 | # endif | 155 | # endif |
155 | oneshot_layer_changed_kb(get_oneshot_layer()); | 156 | oneshot_layer_changed_kb(get_oneshot_layer()); |
157 | } else { | ||
158 | layer_on(layer); | ||
159 | } | ||
156 | } | 160 | } |
157 | /** \brief Reset oneshot layer | 161 | /** \brief Reset oneshot layer |
158 | * | 162 | * |
@@ -172,7 +176,7 @@ void reset_oneshot_layer(void) { | |||
172 | void clear_oneshot_layer_state(oneshot_fullfillment_t state) { | 176 | void clear_oneshot_layer_state(oneshot_fullfillment_t state) { |
173 | uint8_t start_state = oneshot_layer_data; | 177 | uint8_t start_state = oneshot_layer_data; |
174 | oneshot_layer_data &= ~state; | 178 | oneshot_layer_data &= ~state; |
175 | if (!get_oneshot_layer_state() && start_state != oneshot_layer_data) { | 179 | if ((!get_oneshot_layer_state() && start_state != oneshot_layer_data) || keymap_config.oneshot_disable) { |
176 | layer_off(get_oneshot_layer()); | 180 | layer_off(get_oneshot_layer()); |
177 | reset_oneshot_layer(); | 181 | reset_oneshot_layer(); |
178 | } | 182 | } |
@@ -182,6 +186,39 @@ void clear_oneshot_layer_state(oneshot_fullfillment_t state) { | |||
182 | * FIXME: needs doc | 186 | * FIXME: needs doc |
183 | */ | 187 | */ |
184 | bool is_oneshot_layer_active(void) { return get_oneshot_layer_state(); } | 188 | bool is_oneshot_layer_active(void) { return get_oneshot_layer_state(); } |
189 | |||
190 | /** \brief set oneshot | ||
191 | * | ||
192 | * FIXME: needs doc | ||
193 | */ | ||
194 | void oneshot_set(bool active) { | ||
195 | if (keymap_config.oneshot_disable != active) { | ||
196 | keymap_config.oneshot_disable = active; | ||
197 | eeconfig_update_keymap(keymap_config.raw); | ||
198 | dprintf("Oneshot: active: %d\n", active); | ||
199 | } | ||
200 | } | ||
201 | |||
202 | /** \brief toggle oneshot | ||
203 | * | ||
204 | * FIXME: needs doc | ||
205 | */ | ||
206 | void oneshot_toggle(void) { oneshot_set(!keymap_config.oneshot_disable); } | ||
207 | |||
208 | /** \brief enable oneshot | ||
209 | * | ||
210 | * FIXME: needs doc | ||
211 | */ | ||
212 | void oneshot_enable(void) { oneshot_set(true); } | ||
213 | |||
214 | /** \brief disable oneshot | ||
215 | * | ||
216 | * FIXME: needs doc | ||
217 | */ | ||
218 | void oneshot_disable(void) { oneshot_set(false); } | ||
219 | |||
220 | bool is_oneshot_enabled(void) { return keymap_config.oneshot_disable; } | ||
221 | |||
185 | #endif | 222 | #endif |
186 | 223 | ||
187 | /** \brief Send keyboard report | 224 | /** \brief Send keyboard report |
@@ -321,14 +358,17 @@ void del_oneshot_mods(uint8_t mods) { | |||
321 | * FIXME: needs doc | 358 | * FIXME: needs doc |
322 | */ | 359 | */ |
323 | void set_oneshot_mods(uint8_t mods) { | 360 | void set_oneshot_mods(uint8_t mods) { |
324 | if (oneshot_mods != mods) { | 361 | if (!keymap_config.oneshot_disable) { |
362 | if (oneshot_mods != mods) { | ||
325 | # if (defined(ONESHOT_TIMEOUT) && (ONESHOT_TIMEOUT > 0)) | 363 | # if (defined(ONESHOT_TIMEOUT) && (ONESHOT_TIMEOUT > 0)) |
326 | oneshot_time = timer_read(); | 364 | oneshot_time = timer_read(); |
327 | # endif | 365 | # endif |
328 | oneshot_mods = mods; | 366 | oneshot_mods = mods; |
329 | oneshot_mods_changed_kb(mods); | 367 | oneshot_mods_changed_kb(mods); |
368 | } | ||
330 | } | 369 | } |
331 | } | 370 | } |
371 | |||
332 | /** \brief clear oneshot mods | 372 | /** \brief clear oneshot mods |
333 | * | 373 | * |
334 | * FIXME: needs doc | 374 | * FIXME: needs doc |
diff --git a/tmk_core/common/action_util.h b/tmk_core/common/action_util.h index ff29f79b0..f2b3897ae 100644 --- a/tmk_core/common/action_util.h +++ b/tmk_core/common/action_util.h | |||
@@ -85,6 +85,11 @@ void oneshot_mods_changed_kb(uint8_t mods); | |||
85 | void oneshot_layer_changed_user(uint8_t layer); | 85 | void oneshot_layer_changed_user(uint8_t layer); |
86 | void oneshot_layer_changed_kb(uint8_t layer); | 86 | void oneshot_layer_changed_kb(uint8_t layer); |
87 | 87 | ||
88 | void oneshot_toggle(void); | ||
89 | void oneshot_enable(void); | ||
90 | void oneshot_disable(void); | ||
91 | bool is_oneshot_enabled(void); | ||
92 | |||
88 | /* inspect */ | 93 | /* inspect */ |
89 | uint8_t has_anymod(void); | 94 | uint8_t has_anymod(void); |
90 | 95 | ||
diff --git a/tmk_core/common/arm_atsam/_wait.h b/tmk_core/common/arm_atsam/_wait.h new file mode 100644 index 000000000..41b686b56 --- /dev/null +++ b/tmk_core/common/arm_atsam/_wait.h | |||
@@ -0,0 +1,22 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #include "clks.h" | ||
19 | |||
20 | #define wait_ms(ms) CLK_delay_ms(ms) | ||
21 | #define wait_us(us) CLK_delay_us(us) | ||
22 | #define waitInputPinDelay() | ||
diff --git a/tmk_core/common/avr/_wait.h b/tmk_core/common/avr/_wait.h new file mode 100644 index 000000000..56eb316fa --- /dev/null +++ b/tmk_core/common/avr/_wait.h | |||
@@ -0,0 +1,29 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #include <util/delay.h> | ||
19 | |||
20 | #define wait_ms(ms) _delay_ms(ms) | ||
21 | #define wait_us(us) _delay_us(us) | ||
22 | |||
23 | /* The AVR series GPIOs have a one clock read delay for changes in the digital input signal. | ||
24 | * But here's more margin to make it two clocks. */ | ||
25 | #ifndef GPIO_INPUT_PIN_DELAY | ||
26 | # define GPIO_INPUT_PIN_DELAY 2 | ||
27 | #endif | ||
28 | |||
29 | #define waitInputPinDelay() __builtin_avr_delay_cycles(GPIO_INPUT_PIN_DELAY) | ||
diff --git a/tmk_core/common/avr/suspend.c b/tmk_core/common/avr/suspend.c index 47a82a2ee..96b19a77f 100644 --- a/tmk_core/common/avr/suspend.c +++ b/tmk_core/common/avr/suspend.c | |||
@@ -28,6 +28,13 @@ | |||
28 | # include "rgblight.h" | 28 | # include "rgblight.h" |
29 | #endif | 29 | #endif |
30 | 30 | ||
31 | #ifdef LED_MATRIX_ENABLE | ||
32 | # include "led_matrix.h" | ||
33 | #endif | ||
34 | #ifdef RGB_MATRIX_ENABLE | ||
35 | # include "rgb_matrix.h" | ||
36 | #endif | ||
37 | |||
31 | /** \brief Suspend idle | 38 | /** \brief Suspend idle |
32 | * | 39 | * |
33 | * FIXME: needs doc | 40 | * FIXME: needs doc |
diff --git a/tmk_core/common/chibios/_wait.h b/tmk_core/common/chibios/_wait.h new file mode 100644 index 000000000..5bface53e --- /dev/null +++ b/tmk_core/common/chibios/_wait.h | |||
@@ -0,0 +1,55 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #include <ch.h> | ||
19 | |||
20 | /* chThdSleepX of zero maps to infinite - so we map to a tiny delay to still yield */ | ||
21 | #define wait_ms(ms) \ | ||
22 | do { \ | ||
23 | if (ms != 0) { \ | ||
24 | chThdSleepMilliseconds(ms); \ | ||
25 | } else { \ | ||
26 | chThdSleepMicroseconds(1); \ | ||
27 | } \ | ||
28 | } while (0) | ||
29 | #define wait_us(us) \ | ||
30 | do { \ | ||
31 | if (us != 0) { \ | ||
32 | chThdSleepMicroseconds(us); \ | ||
33 | } else { \ | ||
34 | chThdSleepMicroseconds(1); \ | ||
35 | } \ | ||
36 | } while (0) | ||
37 | |||
38 | /* For GPIOs on ARM-based MCUs, the input pins are sampled by the clock of the bus | ||
39 | * to which the GPIO is connected. | ||
40 | * The connected buses differ depending on the various series of MCUs. | ||
41 | * And since the instruction execution clock of the CPU and the bus clock of GPIO are different, | ||
42 | * there is a delay of several clocks to read the change of the input signal. | ||
43 | * | ||
44 | * Define this delay with the GPIO_INPUT_PIN_DELAY macro. | ||
45 | * If the GPIO_INPUT_PIN_DELAY macro is not defined, the following default values will be used. | ||
46 | * (A fairly large value of 0.25 microseconds is set.) | ||
47 | */ | ||
48 | |||
49 | #include "wait.c" | ||
50 | |||
51 | #ifndef GPIO_INPUT_PIN_DELAY | ||
52 | # define GPIO_INPUT_PIN_DELAY (STM32_SYSCLK / 1000000L / 4) | ||
53 | #endif | ||
54 | |||
55 | #define waitInputPinDelay() wait_cpuclock(GPIO_INPUT_PIN_DELAY) | ||
diff --git a/tmk_core/common/chibios/bootloader.c b/tmk_core/common/chibios/bootloader.c index 6cabcc4b8..11f7abf43 100644 --- a/tmk_core/common/chibios/bootloader.c +++ b/tmk_core/common/chibios/bootloader.c | |||
@@ -13,7 +13,23 @@ | |||
13 | # define STM32_BOOTLOADER_DUAL_BANK FALSE | 13 | # define STM32_BOOTLOADER_DUAL_BANK FALSE |
14 | #endif | 14 | #endif |
15 | 15 | ||
16 | #if STM32_BOOTLOADER_DUAL_BANK | 16 | #ifdef BOOTLOADER_TINYUF2 |
17 | |||
18 | # define DBL_TAP_MAGIC 0xf01669ef // From tinyuf2's board_api.h | ||
19 | |||
20 | // defined by linker script | ||
21 | extern uint32_t _board_dfu_dbl_tap[]; | ||
22 | # define DBL_TAP_REG _board_dfu_dbl_tap[0] | ||
23 | |||
24 | void bootloader_jump(void) { | ||
25 | DBL_TAP_REG = DBL_TAP_MAGIC; | ||
26 | NVIC_SystemReset(); | ||
27 | } | ||
28 | |||
29 | void enter_bootloader_mode_if_requested(void) { /* not needed, no two-stage reset */ | ||
30 | } | ||
31 | |||
32 | #elif STM32_BOOTLOADER_DUAL_BANK | ||
17 | 33 | ||
18 | // Need pin definitions | 34 | // Need pin definitions |
19 | # include "config_common.h" | 35 | # include "config_common.h" |
@@ -79,7 +95,7 @@ void enter_bootloader_mode_if_requested(void) { | |||
79 | } | 95 | } |
80 | } | 96 | } |
81 | 97 | ||
82 | #elif defined(KL2x) || defined(K20x) // STM32_BOOTLOADER_DUAL_BANK // STM32_BOOTLOADER_ADDRESS | 98 | #elif defined(KL2x) || defined(K20x) || defined(MK66F18) // STM32_BOOTLOADER_DUAL_BANK // STM32_BOOTLOADER_ADDRESS |
83 | /* Kinetis */ | 99 | /* Kinetis */ |
84 | 100 | ||
85 | # if defined(BOOTLOADER_KIIBOHD) | 101 | # if defined(BOOTLOADER_KIIBOHD) |
diff --git a/tmk_core/common/chibios/chibios_config.h b/tmk_core/common/chibios/chibios_config.h index b4d96465d..1d8ace495 100644 --- a/tmk_core/common/chibios/chibios_config.h +++ b/tmk_core/common/chibios/chibios_config.h | |||
@@ -15,6 +15,8 @@ | |||
15 | */ | 15 | */ |
16 | #pragma once | 16 | #pragma once |
17 | 17 | ||
18 | #define SPLIT_USB_DETECT // Force this on for now | ||
19 | |||
18 | #if defined(STM32F1XX) | 20 | #if defined(STM32F1XX) |
19 | # define USE_GPIOV1 | 21 | # define USE_GPIOV1 |
20 | #endif | 22 | #endif |
@@ -28,4 +30,9 @@ | |||
28 | # define USE_I2CV1 | 30 | # define USE_I2CV1 |
29 | # define USE_I2CV1_CONTRIB // for some reason a bunch of ChibiOS-Contrib boards only have clock_speed | 31 | # define USE_I2CV1_CONTRIB // for some reason a bunch of ChibiOS-Contrib boards only have clock_speed |
30 | # define USE_GPIOV1 | 32 | # define USE_GPIOV1 |
33 | # define STM32_SYSCLK KINETIS_SYSCLK_FREQUENCY | ||
34 | #endif | ||
35 | |||
36 | #if defined(MK66F18) | ||
37 | # define STM32_SYSCLK KINETIS_SYSCLK_FREQUENCY | ||
31 | #endif | 38 | #endif |
diff --git a/tmk_core/common/chibios/pin_defs.h b/tmk_core/common/chibios/pin_defs.h index 86bc1076e..c03f8de0c 100644 --- a/tmk_core/common/chibios/pin_defs.h +++ b/tmk_core/common/chibios/pin_defs.h | |||
@@ -70,6 +70,23 @@ | |||
70 | # define A13 PAL_LINE(GPIOA, 13) | 70 | # define A13 PAL_LINE(GPIOA, 13) |
71 | # define A14 PAL_LINE(GPIOA, 14) | 71 | # define A14 PAL_LINE(GPIOA, 14) |
72 | # define A15 PAL_LINE(GPIOA, 15) | 72 | # define A15 PAL_LINE(GPIOA, 15) |
73 | # define A16 PAL_LINE(GPIOA, 16) | ||
74 | # define A17 PAL_LINE(GPIOA, 17) | ||
75 | # define A18 PAL_LINE(GPIOA, 18) | ||
76 | # define A19 PAL_LINE(GPIOA, 19) | ||
77 | # define A20 PAL_LINE(GPIOA, 20) | ||
78 | # define A21 PAL_LINE(GPIOA, 21) | ||
79 | # define A22 PAL_LINE(GPIOA, 22) | ||
80 | # define A23 PAL_LINE(GPIOA, 23) | ||
81 | # define A24 PAL_LINE(GPIOA, 24) | ||
82 | # define A25 PAL_LINE(GPIOA, 25) | ||
83 | # define A26 PAL_LINE(GPIOA, 26) | ||
84 | # define A27 PAL_LINE(GPIOA, 27) | ||
85 | # define A28 PAL_LINE(GPIOA, 28) | ||
86 | # define A29 PAL_LINE(GPIOA, 29) | ||
87 | # define A30 PAL_LINE(GPIOA, 30) | ||
88 | # define A31 PAL_LINE(GPIOA, 31) | ||
89 | # define A32 PAL_LINE(GPIOA, 32) | ||
73 | # define B0 PAL_LINE(GPIOB, 0) | 90 | # define B0 PAL_LINE(GPIOB, 0) |
74 | # define B1 PAL_LINE(GPIOB, 1) | 91 | # define B1 PAL_LINE(GPIOB, 1) |
75 | # define B2 PAL_LINE(GPIOB, 2) | 92 | # define B2 PAL_LINE(GPIOB, 2) |
@@ -90,6 +107,19 @@ | |||
90 | # define B17 PAL_LINE(GPIOB, 17) | 107 | # define B17 PAL_LINE(GPIOB, 17) |
91 | # define B18 PAL_LINE(GPIOB, 18) | 108 | # define B18 PAL_LINE(GPIOB, 18) |
92 | # define B19 PAL_LINE(GPIOB, 19) | 109 | # define B19 PAL_LINE(GPIOB, 19) |
110 | # define B20 PAL_LINE(GPIOB, 20) | ||
111 | # define B21 PAL_LINE(GPIOB, 21) | ||
112 | # define B22 PAL_LINE(GPIOB, 22) | ||
113 | # define B23 PAL_LINE(GPIOB, 23) | ||
114 | # define B24 PAL_LINE(GPIOB, 24) | ||
115 | # define B25 PAL_LINE(GPIOB, 25) | ||
116 | # define B26 PAL_LINE(GPIOB, 26) | ||
117 | # define B27 PAL_LINE(GPIOB, 27) | ||
118 | # define B28 PAL_LINE(GPIOB, 28) | ||
119 | # define B29 PAL_LINE(GPIOB, 29) | ||
120 | # define B30 PAL_LINE(GPIOB, 30) | ||
121 | # define B31 PAL_LINE(GPIOB, 31) | ||
122 | # define B32 PAL_LINE(GPIOB, 32) | ||
93 | # define C0 PAL_LINE(GPIOC, 0) | 123 | # define C0 PAL_LINE(GPIOC, 0) |
94 | # define C1 PAL_LINE(GPIOC, 1) | 124 | # define C1 PAL_LINE(GPIOC, 1) |
95 | # define C2 PAL_LINE(GPIOC, 2) | 125 | # define C2 PAL_LINE(GPIOC, 2) |
@@ -106,6 +136,23 @@ | |||
106 | # define C13 PAL_LINE(GPIOC, 13) | 136 | # define C13 PAL_LINE(GPIOC, 13) |
107 | # define C14 PAL_LINE(GPIOC, 14) | 137 | # define C14 PAL_LINE(GPIOC, 14) |
108 | # define C15 PAL_LINE(GPIOC, 15) | 138 | # define C15 PAL_LINE(GPIOC, 15) |
139 | # define C16 PAL_LINE(GPIOC, 16) | ||
140 | # define C17 PAL_LINE(GPIOC, 17) | ||
141 | # define C18 PAL_LINE(GPIOC, 18) | ||
142 | # define C19 PAL_LINE(GPIOC, 19) | ||
143 | # define C20 PAL_LINE(GPIOC, 20) | ||
144 | # define C21 PAL_LINE(GPIOC, 21) | ||
145 | # define C22 PAL_LINE(GPIOC, 22) | ||
146 | # define C23 PAL_LINE(GPIOC, 23) | ||
147 | # define C24 PAL_LINE(GPIOC, 24) | ||
148 | # define C25 PAL_LINE(GPIOC, 25) | ||
149 | # define C26 PAL_LINE(GPIOC, 26) | ||
150 | # define C27 PAL_LINE(GPIOC, 27) | ||
151 | # define C28 PAL_LINE(GPIOC, 28) | ||
152 | # define C29 PAL_LINE(GPIOC, 29) | ||
153 | # define C30 PAL_LINE(GPIOC, 30) | ||
154 | # define C31 PAL_LINE(GPIOC, 31) | ||
155 | # define C32 PAL_LINE(GPIOC, 32) | ||
109 | # define D0 PAL_LINE(GPIOD, 0) | 156 | # define D0 PAL_LINE(GPIOD, 0) |
110 | # define D1 PAL_LINE(GPIOD, 1) | 157 | # define D1 PAL_LINE(GPIOD, 1) |
111 | # define D2 PAL_LINE(GPIOD, 2) | 158 | # define D2 PAL_LINE(GPIOD, 2) |
@@ -122,6 +169,23 @@ | |||
122 | # define D13 PAL_LINE(GPIOD, 13) | 169 | # define D13 PAL_LINE(GPIOD, 13) |
123 | # define D14 PAL_LINE(GPIOD, 14) | 170 | # define D14 PAL_LINE(GPIOD, 14) |
124 | # define D15 PAL_LINE(GPIOD, 15) | 171 | # define D15 PAL_LINE(GPIOD, 15) |
172 | # define D16 PAL_LINE(GPIOD, 16) | ||
173 | # define D17 PAL_LINE(GPIOD, 17) | ||
174 | # define D18 PAL_LINE(GPIOD, 18) | ||
175 | # define D19 PAL_LINE(GPIOD, 19) | ||
176 | # define D20 PAL_LINE(GPIOD, 20) | ||
177 | # define D21 PAL_LINE(GPIOD, 21) | ||
178 | # define D22 PAL_LINE(GPIOD, 22) | ||
179 | # define D23 PAL_LINE(GPIOD, 23) | ||
180 | # define D24 PAL_LINE(GPIOD, 24) | ||
181 | # define D25 PAL_LINE(GPIOD, 25) | ||
182 | # define D26 PAL_LINE(GPIOD, 26) | ||
183 | # define D27 PAL_LINE(GPIOD, 27) | ||
184 | # define D28 PAL_LINE(GPIOD, 28) | ||
185 | # define D29 PAL_LINE(GPIOD, 29) | ||
186 | # define D30 PAL_LINE(GPIOD, 30) | ||
187 | # define D31 PAL_LINE(GPIOD, 31) | ||
188 | # define D32 PAL_LINE(GPIOD, 32) | ||
125 | # define E0 PAL_LINE(GPIOE, 0) | 189 | # define E0 PAL_LINE(GPIOE, 0) |
126 | # define E1 PAL_LINE(GPIOE, 1) | 190 | # define E1 PAL_LINE(GPIOE, 1) |
127 | # define E2 PAL_LINE(GPIOE, 2) | 191 | # define E2 PAL_LINE(GPIOE, 2) |
@@ -138,6 +202,23 @@ | |||
138 | # define E13 PAL_LINE(GPIOE, 13) | 202 | # define E13 PAL_LINE(GPIOE, 13) |
139 | # define E14 PAL_LINE(GPIOE, 14) | 203 | # define E14 PAL_LINE(GPIOE, 14) |
140 | # define E15 PAL_LINE(GPIOE, 15) | 204 | # define E15 PAL_LINE(GPIOE, 15) |
205 | # define E16 PAL_LINE(GPIOE, 16) | ||
206 | # define E17 PAL_LINE(GPIOE, 17) | ||
207 | # define E18 PAL_LINE(GPIOE, 18) | ||
208 | # define E19 PAL_LINE(GPIOE, 19) | ||
209 | # define E20 PAL_LINE(GPIOE, 20) | ||
210 | # define E21 PAL_LINE(GPIOE, 21) | ||
211 | # define E22 PAL_LINE(GPIOE, 22) | ||
212 | # define E23 PAL_LINE(GPIOE, 23) | ||
213 | # define E24 PAL_LINE(GPIOE, 24) | ||
214 | # define E25 PAL_LINE(GPIOE, 25) | ||
215 | # define E26 PAL_LINE(GPIOE, 26) | ||
216 | # define E27 PAL_LINE(GPIOE, 27) | ||
217 | # define E28 PAL_LINE(GPIOE, 28) | ||
218 | # define E29 PAL_LINE(GPIOE, 29) | ||
219 | # define E30 PAL_LINE(GPIOE, 30) | ||
220 | # define E31 PAL_LINE(GPIOE, 31) | ||
221 | # define E32 PAL_LINE(GPIOE, 32) | ||
141 | # define F0 PAL_LINE(GPIOF, 0) | 222 | # define F0 PAL_LINE(GPIOF, 0) |
142 | # define F1 PAL_LINE(GPIOF, 1) | 223 | # define F1 PAL_LINE(GPIOF, 1) |
143 | # define F2 PAL_LINE(GPIOF, 2) | 224 | # define F2 PAL_LINE(GPIOF, 2) |
diff --git a/tmk_core/common/chibios/sleep_led.c b/tmk_core/common/chibios/sleep_led.c index 5595eec0e..477056a45 100644 --- a/tmk_core/common/chibios/sleep_led.c +++ b/tmk_core/common/chibios/sleep_led.c | |||
@@ -9,21 +9,13 @@ | |||
9 | * Use LP timer on Kinetises, TIM14 on STM32F0. | 9 | * Use LP timer on Kinetises, TIM14 on STM32F0. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #if defined(KL2x) || defined(K20x) | 12 | #ifndef SLEEP_LED_GPT_DRIVER |
13 | 13 | # if defined(STM32F0XX) | |
14 | /* Use Low Power Timer (LPTMR) */ | 14 | # define SLEEP_LED_GPT_DRIVER GPTD14 |
15 | # define TIMER_INTERRUPT_VECTOR KINETIS_LPTMR0_IRQ_VECTOR | 15 | # endif |
16 | # define RESET_COUNTER LPTMR0->CSR |= LPTMRx_CSR_TCF | ||
17 | |||
18 | #elif defined(STM32F0XX) | ||
19 | |||
20 | /* Use TIM14 manually */ | ||
21 | # define TIMER_INTERRUPT_VECTOR STM32_TIM14_HANDLER | ||
22 | # define RESET_COUNTER STM32_TIM14->SR &= ~STM32_TIM_SR_UIF | ||
23 | |||
24 | #endif | 16 | #endif |
25 | 17 | ||
26 | #if defined(KL2x) || defined(K20x) || defined(STM32F0XX) /* common parts for timers/interrupts */ | 18 | #if defined(KL2x) || defined(K20x) || defined(SLEEP_LED_GPT_DRIVER) /* common parts for timers/interrupts */ |
27 | 19 | ||
28 | /* Breathing Sleep LED brighness(PWM On period) table | 20 | /* Breathing Sleep LED brighness(PWM On period) table |
29 | * (64[steps] * 4[duration]) / 64[PWM periods/s] = 4 second breath cycle | 21 | * (64[steps] * 4[duration]) / 64[PWM periods/s] = 4 second breath cycle |
@@ -33,10 +25,7 @@ | |||
33 | */ | 25 | */ |
34 | static const uint8_t breathing_table[64] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 4, 6, 10, 15, 23, 32, 44, 58, 74, 93, 113, 135, 157, 179, 199, 218, 233, 245, 252, 255, 252, 245, 233, 218, 199, 179, 157, 135, 113, 93, 74, 58, 44, 32, 23, 15, 10, 6, 4, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}; | 26 | static const uint8_t breathing_table[64] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 4, 6, 10, 15, 23, 32, 44, 58, 74, 93, 113, 135, 157, 179, 199, 218, 233, 245, 252, 255, 252, 245, 233, 218, 199, 179, 157, 135, 113, 93, 74, 58, 44, 32, 23, 15, 10, 6, 4, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}; |
35 | 27 | ||
36 | /* interrupt handler */ | 28 | void sleep_led_timer_callback(void) { |
37 | OSAL_IRQ_HANDLER(TIMER_INTERRUPT_VECTOR) { | ||
38 | OSAL_IRQ_PROLOGUE(); | ||
39 | |||
40 | /* Software PWM | 29 | /* Software PWM |
41 | * timer:1111 1111 1111 1111 | 30 | * timer:1111 1111 1111 1111 |
42 | * \_____/\/ \_______/____ count(0-255) | 31 | * \_____/\/ \_______/____ count(0-255) |
@@ -64,17 +53,16 @@ OSAL_IRQ_HANDLER(TIMER_INTERRUPT_VECTOR) { | |||
64 | if (timer.pwm.count == breathing_table[timer.pwm.index]) { | 53 | if (timer.pwm.count == breathing_table[timer.pwm.index]) { |
65 | led_set(0); | 54 | led_set(0); |
66 | } | 55 | } |
67 | |||
68 | /* Reset the counter */ | ||
69 | RESET_COUNTER; | ||
70 | |||
71 | OSAL_IRQ_EPILOGUE(); | ||
72 | } | 56 | } |
73 | 57 | ||
74 | #endif /* common parts for known platforms */ | 58 | #endif /* common parts for known platforms */ |
75 | 59 | ||
76 | #if defined(KL2x) || defined(K20x) /* platform selection: familiar Kinetis chips */ | 60 | #if defined(KL2x) || defined(K20x) /* platform selection: familiar Kinetis chips */ |
77 | 61 | ||
62 | /* Use Low Power Timer (LPTMR) */ | ||
63 | # define TIMER_INTERRUPT_VECTOR KINETIS_LPTMR0_IRQ_VECTOR | ||
64 | # define RESET_COUNTER LPTMR0->CSR |= LPTMRx_CSR_TCF | ||
65 | |||
78 | /* LPTMR clock options */ | 66 | /* LPTMR clock options */ |
79 | # define LPTMR_CLOCK_MCGIRCLK 0 /* 4MHz clock */ | 67 | # define LPTMR_CLOCK_MCGIRCLK 0 /* 4MHz clock */ |
80 | # define LPTMR_CLOCK_LPO 1 /* 1kHz clock */ | 68 | # define LPTMR_CLOCK_LPO 1 /* 1kHz clock */ |
@@ -86,6 +74,18 @@ OSAL_IRQ_HANDLER(TIMER_INTERRUPT_VECTOR) { | |||
86 | # define SIM_SCGC5_LPTMR SIM_SCGC5_LPTIMER | 74 | # define SIM_SCGC5_LPTMR SIM_SCGC5_LPTIMER |
87 | # endif | 75 | # endif |
88 | 76 | ||
77 | /* interrupt handler */ | ||
78 | OSAL_IRQ_HANDLER(TIMER_INTERRUPT_VECTOR) { | ||
79 | OSAL_IRQ_PROLOGUE(); | ||
80 | |||
81 | sleep_led_timer_callback(); | ||
82 | |||
83 | /* Reset the counter */ | ||
84 | RESET_COUNTER; | ||
85 | |||
86 | OSAL_IRQ_EPILOGUE(); | ||
87 | } | ||
88 | |||
89 | /* Initialise the timer */ | 89 | /* Initialise the timer */ |
90 | void sleep_led_init(void) { | 90 | void sleep_led_init(void) { |
91 | /* Make sure the clock to the LPTMR is enabled */ | 91 | /* Make sure the clock to the LPTMR is enabled */ |
@@ -159,45 +159,23 @@ void sleep_led_toggle(void) { | |||
159 | LPTMR0->CSR ^= LPTMRx_CSR_TEN; | 159 | LPTMR0->CSR ^= LPTMRx_CSR_TEN; |
160 | } | 160 | } |
161 | 161 | ||
162 | #elif defined(STM32F0XX) /* platform selection: STM32F0XX */ | 162 | #elif defined(SLEEP_LED_GPT_DRIVER) |
163 | |||
164 | /* Initialise the timer */ | ||
165 | void sleep_led_init(void) { | ||
166 | /* enable clock */ | ||
167 | rccEnableTIM14(FALSE); /* low power enable = FALSE */ | ||
168 | rccResetTIM14(); | ||
169 | |||
170 | /* prescale */ | ||
171 | /* Assuming 48MHz internal clock */ | ||
172 | /* getting cca 65484 irqs/sec */ | ||
173 | STM32_TIM14->PSC = 733; | ||
174 | 163 | ||
175 | /* auto-reload */ | 164 | static void gptTimerCallback(GPTDriver *gptp) { |
176 | /* 0 => interrupt every time */ | 165 | (void)gptp; |
177 | STM32_TIM14->ARR = 3; | 166 | sleep_led_timer_callback(); |
167 | } | ||
178 | 168 | ||
179 | /* enable counter update event interrupt */ | 169 | static const GPTConfig gptcfg = {1000000, gptTimerCallback, 0, 0}; |
180 | STM32_TIM14->DIER |= STM32_TIM_DIER_UIE; | ||
181 | 170 | ||
182 | /* register interrupt vector */ | 171 | /* Initialise the timer */ |
183 | nvicEnableVector(STM32_TIM14_NUMBER, 2); /* vector, priority */ | 172 | void sleep_led_init(void) { gptStart(&SLEEP_LED_GPT_DRIVER, &gptcfg); } |
184 | } | ||
185 | 173 | ||
186 | void sleep_led_enable(void) { | 174 | void sleep_led_enable(void) { gptStartContinuous(&SLEEP_LED_GPT_DRIVER, gptcfg.frequency / 0xFFFF); } |
187 | /* Enable the timer */ | ||
188 | STM32_TIM14->CR1 = STM32_TIM_CR1_CEN | STM32_TIM_CR1_URS; | ||
189 | /* URS => update event only on overflow; setting UG bit disabled */ | ||
190 | } | ||
191 | 175 | ||
192 | void sleep_led_disable(void) { | 176 | void sleep_led_disable(void) { gptStopTimer(&SLEEP_LED_GPT_DRIVER); } |
193 | /* Disable the timer */ | ||
194 | STM32_TIM14->CR1 = 0; | ||
195 | } | ||
196 | 177 | ||
197 | void sleep_led_toggle(void) { | 178 | void sleep_led_toggle(void) { (SLEEP_LED_GPT_DRIVER.state == GPT_READY) ? sleep_led_enable() : sleep_led_disable(); } |
198 | /* Toggle the timer */ | ||
199 | STM32_TIM14->CR1 ^= STM32_TIM_CR1_CEN; | ||
200 | } | ||
201 | 179 | ||
202 | #else /* platform selection: not on familiar chips */ | 180 | #else /* platform selection: not on familiar chips */ |
203 | 181 | ||
diff --git a/tmk_core/common/chibios/suspend.c b/tmk_core/common/chibios/suspend.c index 49e20641f..b3949185e 100644 --- a/tmk_core/common/chibios/suspend.c +++ b/tmk_core/common/chibios/suspend.c | |||
@@ -24,6 +24,13 @@ | |||
24 | # include "rgblight.h" | 24 | # include "rgblight.h" |
25 | #endif | 25 | #endif |
26 | 26 | ||
27 | #ifdef LED_MATRIX_ENABLE | ||
28 | # include "led_matrix.h" | ||
29 | #endif | ||
30 | #ifdef RGB_MATRIX_ENABLE | ||
31 | # include "rgb_matrix.h" | ||
32 | #endif | ||
33 | |||
27 | /** \brief suspend idle | 34 | /** \brief suspend idle |
28 | * | 35 | * |
29 | * FIXME: needs doc | 36 | * FIXME: needs doc |
@@ -53,6 +60,13 @@ void suspend_power_down(void) { | |||
53 | backlight_set(0); | 60 | backlight_set(0); |
54 | #endif | 61 | #endif |
55 | 62 | ||
63 | #ifdef LED_MATRIX_ENABLE | ||
64 | led_matrix_task(); | ||
65 | #endif | ||
66 | #ifdef RGB_MATRIX_ENABLE | ||
67 | rgb_matrix_task(); | ||
68 | #endif | ||
69 | |||
56 | // Turn off LED indicators | 70 | // Turn off LED indicators |
57 | uint8_t leds_off = 0; | 71 | uint8_t leds_off = 0; |
58 | #if defined(BACKLIGHT_CAPS_LOCK) && defined(BACKLIGHT_ENABLE) | 72 | #if defined(BACKLIGHT_CAPS_LOCK) && defined(BACKLIGHT_ENABLE) |
diff --git a/tmk_core/common/chibios/wait.c b/tmk_core/common/chibios/wait.c new file mode 100644 index 000000000..c6270fd95 --- /dev/null +++ b/tmk_core/common/chibios/wait.c | |||
@@ -0,0 +1,89 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #ifndef __OPTIMIZE__ | ||
18 | # pragma message "Compiler optimizations disabled; wait_cpuclock() won't work as designed" | ||
19 | #endif | ||
20 | |||
21 | #define CLOCK_DELAY_NOP8 "nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t" | ||
22 | |||
23 | __attribute__((always_inline)) static inline void wait_cpuclock(unsigned int n) { /* n: 1..135 */ | ||
24 | /* The argument n must be a constant expression. | ||
25 | * That way, compiler optimization will remove unnecessary code. */ | ||
26 | if (n < 1) { | ||
27 | return; | ||
28 | } | ||
29 | if (n > 8) { | ||
30 | unsigned int n8 = n / 8; | ||
31 | n = n - n8 * 8; | ||
32 | switch (n8) { | ||
33 | case 16: | ||
34 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
35 | case 15: | ||
36 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
37 | case 14: | ||
38 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
39 | case 13: | ||
40 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
41 | case 12: | ||
42 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
43 | case 11: | ||
44 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
45 | case 10: | ||
46 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
47 | case 9: | ||
48 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
49 | case 8: | ||
50 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
51 | case 7: | ||
52 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
53 | case 6: | ||
54 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
55 | case 5: | ||
56 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
57 | case 4: | ||
58 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
59 | case 3: | ||
60 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
61 | case 2: | ||
62 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
63 | case 1: | ||
64 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
65 | case 0: | ||
66 | break; | ||
67 | } | ||
68 | } | ||
69 | switch (n) { | ||
70 | case 8: | ||
71 | asm volatile("nop" ::: "memory"); | ||
72 | case 7: | ||
73 | asm volatile("nop" ::: "memory"); | ||
74 | case 6: | ||
75 | asm volatile("nop" ::: "memory"); | ||
76 | case 5: | ||
77 | asm volatile("nop" ::: "memory"); | ||
78 | case 4: | ||
79 | asm volatile("nop" ::: "memory"); | ||
80 | case 3: | ||
81 | asm volatile("nop" ::: "memory"); | ||
82 | case 2: | ||
83 | asm volatile("nop" ::: "memory"); | ||
84 | case 1: | ||
85 | asm volatile("nop" ::: "memory"); | ||
86 | case 0: | ||
87 | break; | ||
88 | } | ||
89 | } \ No newline at end of file | ||
diff --git a/tmk_core/common/eeconfig.c b/tmk_core/common/eeconfig.c index 5e3ebe6ee..92a509217 100644 --- a/tmk_core/common/eeconfig.c +++ b/tmk_core/common/eeconfig.c | |||
@@ -57,7 +57,7 @@ void eeconfig_init_quantum(void) { | |||
57 | eeprom_update_dword(EECONFIG_HAPTIC, 0); | 57 | eeprom_update_dword(EECONFIG_HAPTIC, 0); |
58 | eeprom_update_byte(EECONFIG_VELOCIKEY, 0); | 58 | eeprom_update_byte(EECONFIG_VELOCIKEY, 0); |
59 | eeprom_update_dword(EECONFIG_RGB_MATRIX, 0); | 59 | eeprom_update_dword(EECONFIG_RGB_MATRIX, 0); |
60 | eeprom_update_byte(EECONFIG_RGB_MATRIX_SPEED, 0); | 60 | eeprom_update_word(EECONFIG_RGB_MATRIX_EXTENDED, 0); |
61 | 61 | ||
62 | // TODO: Remove once ARM has a way to configure EECONFIG_HANDEDNESS | 62 | // TODO: Remove once ARM has a way to configure EECONFIG_HANDEDNESS |
63 | // within the emulated eeprom via dfu-util or another tool | 63 | // within the emulated eeprom via dfu-util or another tool |
diff --git a/tmk_core/common/eeconfig.h b/tmk_core/common/eeconfig.h index 86b9e6f99..9e18fd4e1 100644 --- a/tmk_core/common/eeconfig.h +++ b/tmk_core/common/eeconfig.h | |||
@@ -21,7 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
21 | #include <stdbool.h> | 21 | #include <stdbool.h> |
22 | 22 | ||
23 | #ifndef EECONFIG_MAGIC_NUMBER | 23 | #ifndef EECONFIG_MAGIC_NUMBER |
24 | # define EECONFIG_MAGIC_NUMBER (uint16_t)0xFEEB // When changing, decrement this value to avoid future re-init issues | 24 | # define EECONFIG_MAGIC_NUMBER (uint16_t)0xFEEA // When changing, decrement this value to avoid future re-init issues |
25 | #endif | 25 | #endif |
26 | #define EECONFIG_MAGIC_NUMBER_OFF (uint16_t)0xFFFF | 26 | #define EECONFIG_MAGIC_NUMBER_OFF (uint16_t)0xFFFF |
27 | 27 | ||
@@ -43,12 +43,18 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
43 | #define EECONFIG_VELOCIKEY (uint8_t *)23 | 43 | #define EECONFIG_VELOCIKEY (uint8_t *)23 |
44 | 44 | ||
45 | #define EECONFIG_HAPTIC (uint32_t *)24 | 45 | #define EECONFIG_HAPTIC (uint32_t *)24 |
46 | |||
47 | // Mutually exclusive | ||
48 | #define EECONFIG_LED_MATRIX (uint32_t *)28 | ||
46 | #define EECONFIG_RGB_MATRIX (uint32_t *)28 | 49 | #define EECONFIG_RGB_MATRIX (uint32_t *)28 |
47 | #define EECONFIG_RGB_MATRIX_SPEED (uint8_t *)32 | 50 | // Speed & Flags |
51 | #define EECONFIG_LED_MATRIX_EXTENDED (uint16_t *)32 | ||
52 | #define EECONFIG_RGB_MATRIX_EXTENDED (uint16_t *)32 | ||
53 | |||
48 | // TODO: Combine these into a single word and single block of EEPROM | 54 | // TODO: Combine these into a single word and single block of EEPROM |
49 | #define EECONFIG_KEYMAP_UPPER_BYTE (uint8_t *)33 | 55 | #define EECONFIG_KEYMAP_UPPER_BYTE (uint8_t *)34 |
50 | // Size of EEPROM being used, other code can refer to this for available EEPROM | 56 | // Size of EEPROM being used, other code can refer to this for available EEPROM |
51 | #define EECONFIG_SIZE 34 | 57 | #define EECONFIG_SIZE 35 |
52 | /* debug bit */ | 58 | /* debug bit */ |
53 | #define EECONFIG_DEBUG_ENABLE (1 << 0) | 59 | #define EECONFIG_DEBUG_ENABLE (1 << 0) |
54 | #define EECONFIG_DEBUG_MATRIX (1 << 1) | 60 | #define EECONFIG_DEBUG_MATRIX (1 << 1) |
diff --git a/tmk_core/common/keyboard.c b/tmk_core/common/keyboard.c index ce3255c06..24baf41c0 100644 --- a/tmk_core/common/keyboard.c +++ b/tmk_core/common/keyboard.c | |||
@@ -34,11 +34,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
34 | #ifdef BACKLIGHT_ENABLE | 34 | #ifdef BACKLIGHT_ENABLE |
35 | # include "backlight.h" | 35 | # include "backlight.h" |
36 | #endif | 36 | #endif |
37 | #ifdef BOOTMAGIC_ENABLE | ||
38 | # include "bootmagic.h" | ||
39 | #else | ||
40 | # include "magic.h" | ||
41 | #endif | ||
42 | #ifdef MOUSEKEY_ENABLE | 37 | #ifdef MOUSEKEY_ENABLE |
43 | # include "mousekey.h" | 38 | # include "mousekey.h" |
44 | #endif | 39 | #endif |
@@ -54,6 +49,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
54 | #ifdef RGBLIGHT_ENABLE | 49 | #ifdef RGBLIGHT_ENABLE |
55 | # include "rgblight.h" | 50 | # include "rgblight.h" |
56 | #endif | 51 | #endif |
52 | #ifdef LED_MATRIX_ENABLE | ||
53 | # include "led_matrix.h" | ||
54 | #endif | ||
57 | #ifdef RGB_MATRIX_ENABLE | 55 | #ifdef RGB_MATRIX_ENABLE |
58 | # include "rgb_matrix.h" | 56 | # include "rgb_matrix.h" |
59 | #endif | 57 | #endif |
@@ -96,6 +94,12 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
96 | #ifdef DIP_SWITCH_ENABLE | 94 | #ifdef DIP_SWITCH_ENABLE |
97 | # include "dip_switch.h" | 95 | # include "dip_switch.h" |
98 | #endif | 96 | #endif |
97 | #ifdef STM32_EEPROM_ENABLE | ||
98 | # include "eeprom_stm32.h" | ||
99 | #endif | ||
100 | #ifdef EEPROM_DRIVER | ||
101 | # include "eeprom_driver.h" | ||
102 | #endif | ||
99 | 103 | ||
100 | static uint32_t last_input_modification_time = 0; | 104 | static uint32_t last_input_modification_time = 0; |
101 | uint32_t last_input_activity_time(void) { return last_input_modification_time; } | 105 | uint32_t last_input_activity_time(void) { return last_input_modification_time; } |
@@ -233,6 +237,12 @@ void keyboard_setup(void) { | |||
233 | disable_jtag(); | 237 | disable_jtag(); |
234 | #endif | 238 | #endif |
235 | print_set_sendchar(sendchar); | 239 | print_set_sendchar(sendchar); |
240 | #ifdef STM32_EEPROM_ENABLE | ||
241 | EEPROM_Init(); | ||
242 | #endif | ||
243 | #ifdef EEPROM_DRIVER | ||
244 | eeprom_driver_init(); | ||
245 | #endif | ||
236 | matrix_setup(); | 246 | matrix_setup(); |
237 | keyboard_pre_init_kb(); | 247 | keyboard_pre_init_kb(); |
238 | } | 248 | } |
@@ -296,11 +306,6 @@ void keyboard_init(void) { | |||
296 | #ifdef ADB_MOUSE_ENABLE | 306 | #ifdef ADB_MOUSE_ENABLE |
297 | adb_mouse_init(); | 307 | adb_mouse_init(); |
298 | #endif | 308 | #endif |
299 | #ifdef BOOTMAGIC_ENABLE | ||
300 | bootmagic(); | ||
301 | #else | ||
302 | magic(); | ||
303 | #endif | ||
304 | #ifdef BACKLIGHT_ENABLE | 309 | #ifdef BACKLIGHT_ENABLE |
305 | backlight_init(); | 310 | backlight_init(); |
306 | #endif | 311 | #endif |
@@ -337,6 +342,9 @@ void keyboard_init(void) { | |||
337 | * This is differnet than keycode events as no layer processing, or filtering occurs. | 342 | * This is differnet than keycode events as no layer processing, or filtering occurs. |
338 | */ | 343 | */ |
339 | void switch_events(uint8_t row, uint8_t col, bool pressed) { | 344 | void switch_events(uint8_t row, uint8_t col, bool pressed) { |
345 | #if defined(LED_MATRIX_ENABLE) | ||
346 | process_led_matrix(row, col, pressed); | ||
347 | #endif | ||
340 | #if defined(RGB_MATRIX_ENABLE) | 348 | #if defined(RGB_MATRIX_ENABLE) |
341 | process_rgb_matrix(row, col, pressed); | 349 | process_rgb_matrix(row, col, pressed); |
342 | #endif | 350 | #endif |
@@ -422,6 +430,9 @@ MATRIX_LOOP_END: | |||
422 | rgblight_task(); | 430 | rgblight_task(); |
423 | #endif | 431 | #endif |
424 | 432 | ||
433 | #ifdef LED_MATRIX_ENABLE | ||
434 | led_matrix_task(); | ||
435 | #endif | ||
425 | #ifdef RGB_MATRIX_ENABLE | 436 | #ifdef RGB_MATRIX_ENABLE |
426 | rgb_matrix_task(); | 437 | rgb_matrix_task(); |
427 | #endif | 438 | #endif |
diff --git a/tmk_core/common/magic.c b/tmk_core/common/magic.c deleted file mode 100644 index e14994164..000000000 --- a/tmk_core/common/magic.c +++ /dev/null | |||
@@ -1,39 +0,0 @@ | |||
1 | #include <stdint.h> | ||
2 | #include <stdbool.h> | ||
3 | #if defined(__AVR__) | ||
4 | # include <util/delay.h> | ||
5 | #endif | ||
6 | #include "matrix.h" | ||
7 | #include "bootloader.h" | ||
8 | #include "debug.h" | ||
9 | #include "keymap.h" | ||
10 | #include "host.h" | ||
11 | #include "action_layer.h" | ||
12 | #include "eeconfig.h" | ||
13 | #include "magic.h" | ||
14 | |||
15 | keymap_config_t keymap_config; | ||
16 | |||
17 | /** \brief Magic | ||
18 | * | ||
19 | * FIXME: Needs doc | ||
20 | */ | ||
21 | void magic(void) { | ||
22 | /* check signature */ | ||
23 | if (!eeconfig_is_enabled()) { | ||
24 | eeconfig_init(); | ||
25 | } | ||
26 | |||
27 | /* debug enable */ | ||
28 | debug_config.raw = eeconfig_read_debug(); | ||
29 | |||
30 | /* keymap config */ | ||
31 | keymap_config.raw = eeconfig_read_keymap(); | ||
32 | |||
33 | uint8_t default_layer = 0; | ||
34 | default_layer = eeconfig_read_default_layer(); | ||
35 | default_layer_set((layer_state_t)default_layer); | ||
36 | |||
37 | /* Also initialize layer state to trigger callback functions for layer_state */ | ||
38 | layer_state_set_kb((layer_state_t)layer_state); | ||
39 | } | ||
diff --git a/tmk_core/common/magic.h b/tmk_core/common/magic.h deleted file mode 100644 index a6552c04d..000000000 --- a/tmk_core/common/magic.h +++ /dev/null | |||
@@ -1,3 +0,0 @@ | |||
1 | #pragma once | ||
2 | |||
3 | void magic(void); | ||
diff --git a/tmk_core/common/test/_wait.h b/tmk_core/common/test/_wait.h new file mode 100644 index 000000000..4e22f593b --- /dev/null +++ b/tmk_core/common/test/_wait.h | |||
@@ -0,0 +1,22 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #include <inttypes.h> | ||
19 | |||
20 | void wait_ms(uint32_t ms); | ||
21 | #define wait_us(us) wait_ms(us / 1000) | ||
22 | #define waitInputPinDelay() | ||
diff --git a/tmk_core/common/usb_util.c b/tmk_core/common/usb_util.c new file mode 100644 index 000000000..e4c50fcb1 --- /dev/null +++ b/tmk_core/common/usb_util.c | |||
@@ -0,0 +1,29 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include "usb_util.h" | ||
17 | #include "wait.h" | ||
18 | |||
19 | __attribute__((weak)) void usb_disable(void) {} | ||
20 | __attribute__((weak)) bool usb_connected_state(void) { return true; } | ||
21 | __attribute__((weak)) bool usb_vbus_state(void) { | ||
22 | #ifdef USB_VBUS_PIN | ||
23 | setPinInput(USB_VBUS_PIN); | ||
24 | wait_us(5); | ||
25 | return readPin(USB_VBUS_PIN); | ||
26 | #else | ||
27 | return true; | ||
28 | #endif | ||
29 | } | ||
diff --git a/tmk_core/common/usb_util.h b/tmk_core/common/usb_util.h new file mode 100644 index 000000000..4ebedb1e7 --- /dev/null +++ b/tmk_core/common/usb_util.h | |||
@@ -0,0 +1,22 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #pragma once | ||
17 | |||
18 | #include <stdbool.h> | ||
19 | |||
20 | void usb_disable(void); | ||
21 | bool usb_connected_state(void); | ||
22 | bool usb_vbus_state(void); | ||
diff --git a/tmk_core/common/wait.h b/tmk_core/common/wait.h index 28224fe3a..cf7180fb0 100644 --- a/tmk_core/common/wait.h +++ b/tmk_core/common/wait.h | |||
@@ -1,3 +1,18 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
1 | #pragma once | 16 | #pragma once |
2 | 17 | ||
3 | #include <inttypes.h> | 18 | #include <inttypes.h> |
@@ -6,114 +21,8 @@ | |||
6 | extern "C" { | 21 | extern "C" { |
7 | #endif | 22 | #endif |
8 | 23 | ||
9 | #if defined(__ARMEL__) || defined(__ARMEB__) | 24 | #if __has_include_next("_wait.h") |
10 | # ifndef __OPTIMIZE__ | 25 | # include_next "_wait.h" /* Include the platforms _wait.h */ |
11 | # pragma message "Compiler optimizations disabled; wait_cpuclock() won't work as designed" | ||
12 | # endif | ||
13 | |||
14 | # define wait_cpuclock(x) wait_cpuclock_allnop(x) | ||
15 | |||
16 | # define CLOCK_DELAY_NOP8 "nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t nop\n\t" | ||
17 | |||
18 | __attribute__((always_inline)) static inline void wait_cpuclock_allnop(unsigned int n) { /* n: 1..135 */ | ||
19 | /* The argument n must be a constant expression. | ||
20 | * That way, compiler optimization will remove unnecessary code. */ | ||
21 | if (n < 1) { | ||
22 | return; | ||
23 | } | ||
24 | if (n > 8) { | ||
25 | unsigned int n8 = n / 8; | ||
26 | n = n - n8 * 8; | ||
27 | switch (n8) { | ||
28 | case 16: | ||
29 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
30 | case 15: | ||
31 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
32 | case 14: | ||
33 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
34 | case 13: | ||
35 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
36 | case 12: | ||
37 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
38 | case 11: | ||
39 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
40 | case 10: | ||
41 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
42 | case 9: | ||
43 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
44 | case 8: | ||
45 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
46 | case 7: | ||
47 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
48 | case 6: | ||
49 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
50 | case 5: | ||
51 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
52 | case 4: | ||
53 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
54 | case 3: | ||
55 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
56 | case 2: | ||
57 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
58 | case 1: | ||
59 | asm volatile(CLOCK_DELAY_NOP8::: "memory"); | ||
60 | case 0: | ||
61 | break; | ||
62 | } | ||
63 | } | ||
64 | switch (n) { | ||
65 | case 8: | ||
66 | asm volatile("nop" ::: "memory"); | ||
67 | case 7: | ||
68 | asm volatile("nop" ::: "memory"); | ||
69 | case 6: | ||
70 | asm volatile("nop" ::: "memory"); | ||
71 | case 5: | ||
72 | asm volatile("nop" ::: "memory"); | ||
73 | case 4: | ||
74 | asm volatile("nop" ::: "memory"); | ||
75 | case 3: | ||
76 | asm volatile("nop" ::: "memory"); | ||
77 | case 2: | ||
78 | asm volatile("nop" ::: "memory"); | ||
79 | case 1: | ||
80 | asm volatile("nop" ::: "memory"); | ||
81 | case 0: | ||
82 | break; | ||
83 | } | ||
84 | } | ||
85 | #endif | ||
86 | |||
87 | #if defined(__AVR__) | ||
88 | # include <util/delay.h> | ||
89 | # define wait_ms(ms) _delay_ms(ms) | ||
90 | # define wait_us(us) _delay_us(us) | ||
91 | # define wait_cpuclock(x) __builtin_avr_delay_cycles(x) | ||
92 | #elif defined PROTOCOL_CHIBIOS | ||
93 | # include <ch.h> | ||
94 | # define wait_ms(ms) \ | ||
95 | do { \ | ||
96 | if (ms != 0) { \ | ||
97 | chThdSleepMilliseconds(ms); \ | ||
98 | } else { \ | ||
99 | chThdSleepMicroseconds(1); \ | ||
100 | } \ | ||
101 | } while (0) | ||
102 | # define wait_us(us) \ | ||
103 | do { \ | ||
104 | if (us != 0) { \ | ||
105 | chThdSleepMicroseconds(us); \ | ||
106 | } else { \ | ||
107 | chThdSleepMicroseconds(1); \ | ||
108 | } \ | ||
109 | } while (0) | ||
110 | #elif defined PROTOCOL_ARM_ATSAM | ||
111 | # include "clks.h" | ||
112 | # define wait_ms(ms) CLK_delay_ms(ms) | ||
113 | # define wait_us(us) CLK_delay_us(us) | ||
114 | #else // Unit tests | ||
115 | void wait_ms(uint32_t ms); | ||
116 | # define wait_us(us) wait_ms(us / 1000) | ||
117 | #endif | 26 | #endif |
118 | 27 | ||
119 | #ifdef __cplusplus | 28 | #ifdef __cplusplus |
diff --git a/tmk_core/protocol.mk b/tmk_core/protocol.mk index 0c41642b9..cc87e8347 100644 --- a/tmk_core/protocol.mk +++ b/tmk_core/protocol.mk | |||
@@ -54,5 +54,9 @@ ifeq ($(strip $(XT_ENABLE)), yes) | |||
54 | OPT_DEFS += -DXT_ENABLE | 54 | OPT_DEFS += -DXT_ENABLE |
55 | endif | 55 | endif |
56 | 56 | ||
57 | ifeq ($(strip $(USB_HID_ENABLE)), yes) | ||
58 | include $(TMK_DIR)/protocol/usb_hid.mk | ||
59 | endif | ||
60 | |||
57 | # Search Path | 61 | # Search Path |
58 | VPATH += $(TMK_DIR)/protocol | 62 | VPATH += $(TMK_DIR)/protocol |
diff --git a/tmk_core/protocol/chibios.mk b/tmk_core/protocol/chibios.mk index 80554abb3..d01697835 100644 --- a/tmk_core/protocol/chibios.mk +++ b/tmk_core/protocol/chibios.mk | |||
@@ -6,6 +6,7 @@ SRC += $(CHIBIOS_DIR)/usb_main.c | |||
6 | SRC += $(CHIBIOS_DIR)/main.c | 6 | SRC += $(CHIBIOS_DIR)/main.c |
7 | SRC += usb_descriptor.c | 7 | SRC += usb_descriptor.c |
8 | SRC += $(CHIBIOS_DIR)/usb_driver.c | 8 | SRC += $(CHIBIOS_DIR)/usb_driver.c |
9 | SRC += $(CHIBIOS_DIR)/usb_util.c | ||
9 | SRC += $(LIBSRC) | 10 | SRC += $(LIBSRC) |
10 | 11 | ||
11 | VPATH += $(TMK_PATH)/$(PROTOCOL_DIR) | 12 | VPATH += $(TMK_PATH)/$(PROTOCOL_DIR) |
diff --git a/tmk_core/protocol/chibios/main.c b/tmk_core/protocol/chibios/main.c index 63e4c99d2..e2ec01118 100644 --- a/tmk_core/protocol/chibios/main.c +++ b/tmk_core/protocol/chibios/main.c | |||
@@ -51,12 +51,6 @@ | |||
51 | #ifdef MIDI_ENABLE | 51 | #ifdef MIDI_ENABLE |
52 | # include "qmk_midi.h" | 52 | # include "qmk_midi.h" |
53 | #endif | 53 | #endif |
54 | #ifdef STM32_EEPROM_ENABLE | ||
55 | # include "eeprom_stm32.h" | ||
56 | #endif | ||
57 | #ifdef EEPROM_DRIVER | ||
58 | # include "eeprom_driver.h" | ||
59 | #endif | ||
60 | #include "suspend.h" | 54 | #include "suspend.h" |
61 | #include "wait.h" | 55 | #include "wait.h" |
62 | 56 | ||
@@ -150,13 +144,6 @@ int main(void) { | |||
150 | halInit(); | 144 | halInit(); |
151 | chSysInit(); | 145 | chSysInit(); |
152 | 146 | ||
153 | #ifdef STM32_EEPROM_ENABLE | ||
154 | EEPROM_Init(); | ||
155 | #endif | ||
156 | #ifdef EEPROM_DRIVER | ||
157 | eeprom_driver_init(); | ||
158 | #endif | ||
159 | |||
160 | // TESTING | 147 | // TESTING |
161 | // chThdCreateStatic(waThread1, sizeof(waThread1), NORMALPRIO, Thread1, NULL); | 148 | // chThdCreateStatic(waThread1, sizeof(waThread1), NORMALPRIO, Thread1, NULL); |
162 | 149 | ||
diff --git a/tmk_core/protocol/chibios/usb_util.c b/tmk_core/protocol/chibios/usb_util.c new file mode 100644 index 000000000..5945e8a8d --- /dev/null +++ b/tmk_core/protocol/chibios/usb_util.c | |||
@@ -0,0 +1,21 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include <hal.h> | ||
17 | #include "usb_util.h" | ||
18 | |||
19 | void usb_disable(void) { usbStop(&USBD1); } | ||
20 | |||
21 | bool usb_connected_state(void) { return usbGetDriverStateI(&USBD1) == USB_ACTIVE; } | ||
diff --git a/tmk_core/protocol/lufa.mk b/tmk_core/protocol/lufa.mk index 1cc1fa04e..514d5fac4 100644 --- a/tmk_core/protocol/lufa.mk +++ b/tmk_core/protocol/lufa.mk | |||
@@ -44,6 +44,7 @@ ifeq ($(strip $(VIRTSER_ENABLE)), yes) | |||
44 | endif | 44 | endif |
45 | 45 | ||
46 | SRC += $(LUFA_SRC) | 46 | SRC += $(LUFA_SRC) |
47 | SRC += $(LUFA_DIR)/usb_util.c | ||
47 | 48 | ||
48 | # Search Path | 49 | # Search Path |
49 | VPATH += $(TMK_PATH)/$(LUFA_DIR) | 50 | VPATH += $(TMK_PATH)/$(LUFA_DIR) |
@@ -66,8 +67,8 @@ LUFA_OPTS += -DFIXED_CONTROL_ENDPOINT_SIZE=8 | |||
66 | LUFA_OPTS += -DFIXED_CONTROL_ENDPOINT_SIZE=8 | 67 | LUFA_OPTS += -DFIXED_CONTROL_ENDPOINT_SIZE=8 |
67 | LUFA_OPTS += -DFIXED_NUM_CONFIGURATIONS=1 | 68 | LUFA_OPTS += -DFIXED_NUM_CONFIGURATIONS=1 |
68 | 69 | ||
69 | # Remote wakeup fix for ATmega32U2 https://github.com/tmk/tmk_keyboard/issues/361 | 70 | # Remote wakeup fix for ATmega16/32U2 https://github.com/tmk/tmk_keyboard/issues/361 |
70 | ifeq ($(MCU),atmega32u2) | 71 | ifneq (,$(filter $(MCU), at90usb162 atmega16u2 atmega32u2)) |
71 | LUFA_OPTS += -DNO_LIMITED_CONTROLLER_CONNECT | 72 | LUFA_OPTS += -DNO_LIMITED_CONTROLLER_CONNECT |
72 | endif | 73 | endif |
73 | 74 | ||
diff --git a/tmk_core/protocol/lufa/usb_util.c b/tmk_core/protocol/lufa/usb_util.c new file mode 100644 index 000000000..9e943a21b --- /dev/null +++ b/tmk_core/protocol/lufa/usb_util.c | |||
@@ -0,0 +1,34 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include <LUFA/Drivers/USB/USB.h> | ||
17 | #include "usb_util.h" | ||
18 | #include "wait.h" | ||
19 | |||
20 | void usb_disable(void) { | ||
21 | USB_Disable(); | ||
22 | USB_DeviceState = DEVICE_STATE_Unattached; | ||
23 | } | ||
24 | |||
25 | bool usb_connected_state(void) { return USB_Device_IsAddressSet(); } | ||
26 | |||
27 | #if defined(OTGPADE) | ||
28 | bool usb_vbus_state(void) { | ||
29 | USB_OTGPAD_On(); // enables VBUS pad | ||
30 | wait_us(5); | ||
31 | |||
32 | return USB_VBUS_GetStatus(); // checks state of VBUS | ||
33 | } | ||
34 | #endif | ||
diff --git a/tmk_core/protocol/vusb.mk b/tmk_core/protocol/vusb.mk index 1de600308..e4d013b38 100644 --- a/tmk_core/protocol/vusb.mk +++ b/tmk_core/protocol/vusb.mk | |||
@@ -5,6 +5,7 @@ VUSB_PATH = $(LIB_PATH)/vusb | |||
5 | 5 | ||
6 | SRC += $(VUSB_DIR)/main.c \ | 6 | SRC += $(VUSB_DIR)/main.c \ |
7 | $(VUSB_DIR)/vusb.c \ | 7 | $(VUSB_DIR)/vusb.c \ |
8 | $(VUSB_DIR)/usb_util.c \ | ||
8 | $(VUSB_PATH)/usbdrv/usbdrv.c \ | 9 | $(VUSB_PATH)/usbdrv/usbdrv.c \ |
9 | $(VUSB_PATH)/usbdrv/usbdrvasm.S \ | 10 | $(VUSB_PATH)/usbdrv/usbdrvasm.S \ |
10 | $(VUSB_PATH)/usbdrv/oddebug.c | 11 | $(VUSB_PATH)/usbdrv/oddebug.c |
diff --git a/tmk_core/protocol/vusb/usb_util.c b/tmk_core/protocol/vusb/usb_util.c new file mode 100644 index 000000000..602854dbe --- /dev/null +++ b/tmk_core/protocol/vusb/usb_util.c | |||
@@ -0,0 +1,24 @@ | |||
1 | /* Copyright 2021 QMK | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 3 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include <usbdrv/usbdrv.h> | ||
17 | #include "usb_util.h" | ||
18 | |||
19 | void usb_disable(void) { usbDeviceDisconnect(); } | ||
20 | |||
21 | bool usb_connected_state(void) { | ||
22 | usbPoll(); | ||
23 | return usbConfiguration; | ||
24 | } | ||
diff --git a/tmk_core/rules.mk b/tmk_core/rules.mk index bbcfc1e4d..8dbed35fb 100644 --- a/tmk_core/rules.mk +++ b/tmk_core/rules.mk | |||
@@ -223,6 +223,12 @@ ifneq ($(filter Darwin FreeBSD,$(shell uname -s)),) | |||
223 | MD5SUM = md5 | 223 | MD5SUM = md5 |
224 | endif | 224 | endif |
225 | 225 | ||
226 | # UF2 format settings | ||
227 | # To produce a UF2 file in your build, add to your keyboard's rules.mk: | ||
228 | # FIRMWARE_FORMAT = uf2 | ||
229 | UF2CONV = $(TOP_DIR)/util/uf2conv.py | ||
230 | UF2_FAMILY ?= 0x0 | ||
231 | |||
226 | # Compiler flags to generate dependency files. | 232 | # Compiler flags to generate dependency files. |
227 | #GENDEPFLAGS = -MMD -MP -MF .dep/$(@F).d | 233 | #GENDEPFLAGS = -MMD -MP -MF .dep/$(@F).d |
228 | GENDEPFLAGS = -MMD -MP -MF $(patsubst %.o,%.td,$@) | 234 | GENDEPFLAGS = -MMD -MP -MF $(patsubst %.o,%.td,$@) |
@@ -255,6 +261,7 @@ DFU_SUFFIX_ARGS ?= | |||
255 | 261 | ||
256 | elf: $(BUILD_DIR)/$(TARGET).elf | 262 | elf: $(BUILD_DIR)/$(TARGET).elf |
257 | hex: $(BUILD_DIR)/$(TARGET).hex | 263 | hex: $(BUILD_DIR)/$(TARGET).hex |
264 | uf2: $(BUILD_DIR)/$(TARGET).uf2 | ||
258 | cpfirmware: $(FIRMWARE_FORMAT) | 265 | cpfirmware: $(FIRMWARE_FORMAT) |
259 | $(SILENT) || printf "Copying $(TARGET).$(FIRMWARE_FORMAT) to qmk_firmware folder" | $(AWK_CMD) | 266 | $(SILENT) || printf "Copying $(TARGET).$(FIRMWARE_FORMAT) to qmk_firmware folder" | $(AWK_CMD) |
260 | $(COPY) $(BUILD_DIR)/$(TARGET).$(FIRMWARE_FORMAT) $(TARGET).$(FIRMWARE_FORMAT) && $(PRINT_OK) | 267 | $(COPY) $(BUILD_DIR)/$(TARGET).$(FIRMWARE_FORMAT) $(TARGET).$(FIRMWARE_FORMAT) && $(PRINT_OK) |
@@ -283,32 +290,44 @@ gccversion : | |||
283 | 290 | ||
284 | # Create final output files (.hex, .eep) from ELF output file. | 291 | # Create final output files (.hex, .eep) from ELF output file. |
285 | %.hex: %.elf | 292 | %.hex: %.elf |
286 | @$(SILENT) || printf "$(MSG_FLASH) $@" | $(AWK_CMD) | ||
287 | $(eval CMD=$(HEX) $< $@) | 293 | $(eval CMD=$(HEX) $< $@) |
294 | #@$(SILENT) || printf "$(MSG_EXECUTING) '$(CMD)':\n" | ||
295 | @$(SILENT) || printf "$(MSG_FLASH) $@" | $(AWK_CMD) | ||
296 | @$(BUILD_CMD) | ||
297 | |||
298 | %.uf2: %.hex | ||
299 | $(eval CMD=$(UF2CONV) $(BUILD_DIR)/$(TARGET).hex -o $(BUILD_DIR)/$(TARGET).uf2 -c -f $(UF2_FAMILY) >/dev/null 2>&1) | ||
300 | #@$(SILENT) || printf "$(MSG_EXECUTING) '$(CMD)':\n" | ||
301 | @$(SILENT) || printf "$(MSG_UF2) $@" | $(AWK_CMD) | ||
288 | @$(BUILD_CMD) | 302 | @$(BUILD_CMD) |
289 | 303 | ||
290 | %.eep: %.elf | 304 | %.eep: %.elf |
291 | @$(SILENT) || printf "$(MSG_EEPROM) $@" | $(AWK_CMD) | ||
292 | $(eval CMD=$(EEP) $< $@ || exit 0) | 305 | $(eval CMD=$(EEP) $< $@ || exit 0) |
306 | #@$(SILENT) || printf "$(MSG_EXECUTING) '$(CMD)':\n" | ||
307 | @$(SILENT) || printf "$(MSG_EEPROM) $@" | $(AWK_CMD) | ||
293 | @$(BUILD_CMD) | 308 | @$(BUILD_CMD) |
294 | 309 | ||
295 | # Create extended listing file from ELF output file. | 310 | # Create extended listing file from ELF output file. |
296 | %.lss: %.elf | 311 | %.lss: %.elf |
297 | @$(SILENT) || printf "$(MSG_EXTENDED_LISTING) $@" | $(AWK_CMD) | ||
298 | $(eval CMD=$(OBJDUMP) -h -S -z $< > $@) | 312 | $(eval CMD=$(OBJDUMP) -h -S -z $< > $@) |
313 | #@$(SILENT) || printf "$(MSG_EXECUTING) '$(CMD)':\n" | ||
314 | @$(SILENT) || printf "$(MSG_EXTENDED_LISTING) $@" | $(AWK_CMD) | ||
299 | @$(BUILD_CMD) | 315 | @$(BUILD_CMD) |
300 | 316 | ||
301 | # Create a symbol table from ELF output file. | 317 | # Create a symbol table from ELF output file. |
302 | %.sym: %.elf | 318 | %.sym: %.elf |
303 | @$(SILENT) || printf "$(MSG_SYMBOL_TABLE) $@" | $(AWK_CMD) | ||
304 | $(eval CMD=$(NM) -n $< > $@ ) | 319 | $(eval CMD=$(NM) -n $< > $@ ) |
320 | #@$(SILENT) || printf "$(MSG_EXECUTING) '$(CMD)':\n" | ||
321 | @$(SILENT) || printf "$(MSG_SYMBOL_TABLE) $@" | $(AWK_CMD) | ||
305 | @$(BUILD_CMD) | 322 | @$(BUILD_CMD) |
306 | 323 | ||
307 | %.bin: %.elf | 324 | %.bin: %.elf |
308 | @$(SILENT) || printf "$(MSG_BIN) $@" | $(AWK_CMD) | ||
309 | $(eval CMD=$(BIN) $< $@ || exit 0) | 325 | $(eval CMD=$(BIN) $< $@ || exit 0) |
326 | #@$(SILENT) || printf "$(MSG_EXECUTING) '$(CMD)':\n" | ||
327 | @$(SILENT) || printf "$(MSG_BIN) $@" | $(AWK_CMD) | ||
310 | @$(BUILD_CMD) | 328 | @$(BUILD_CMD) |
311 | if [ ! -z "$(DFU_SUFFIX_ARGS)" ]; then \ | 329 | if [ ! -z "$(DFU_SUFFIX_ARGS)" ]; then \ |
330 | #$(SILENT) || printf "$(MSG_EXECUTING) '$(DFU_SUFFIX) $(DFU_SUFFIX_ARGS) -a $(BUILD_DIR)/$(TARGET).bin 1>/dev/null':\n" ;\ | ||
312 | $(DFU_SUFFIX) $(DFU_SUFFIX_ARGS) -a $(BUILD_DIR)/$(TARGET).bin 1>/dev/null ;\ | 331 | $(DFU_SUFFIX) $(DFU_SUFFIX_ARGS) -a $(BUILD_DIR)/$(TARGET).bin 1>/dev/null ;\ |
313 | fi | 332 | fi |
314 | $(COPY) $(BUILD_DIR)/$(TARGET).bin $(TARGET).bin; | 333 | $(COPY) $(BUILD_DIR)/$(TARGET).bin $(TARGET).bin; |
@@ -476,7 +495,7 @@ $(eval $(foreach OUTPUT,$(OUTPUTS),$(shell mkdir -p $(OUTPUT) 2>/dev/null))) | |||
476 | 495 | ||
477 | # Listing of phony targets. | 496 | # Listing of phony targets. |
478 | .PHONY : all dump_vars finish sizebefore sizeafter qmkversion \ | 497 | .PHONY : all dump_vars finish sizebefore sizeafter qmkversion \ |
479 | gccversion build elf hex eep lss sym coff extcoff \ | 498 | gccversion build elf hex uf2 eep lss sym coff extcoff \ |
480 | clean clean_list debug gdb-config show_path \ | 499 | clean clean_list debug gdb-config show_path \ |
481 | program teensy dfu dfu-ee dfu-start \ | 500 | program teensy dfu dfu-ee dfu-start \ |
482 | flash dfu-split-left dfu-split-right \ | 501 | flash dfu-split-left dfu-split-right \ |
diff --git a/users/gordon/rules.mk b/users/gordon/rules.mk index 19e77b01b..06e671a63 100644 --- a/users/gordon/rules.mk +++ b/users/gordon/rules.mk | |||
@@ -1,4 +1,4 @@ | |||
1 | TAP_DANCE_ENABLE = yes | 1 | TAP_DANCE_ENABLE = yes |
2 | SRC += gordon.c | 2 | SRC += gordon.c |
3 | 3 | ||
4 | # BOOTMAGIC_ENABLE = yes | 4 | # BOOTMAGIC_ENABLE = full |
diff --git a/util/uf2conv.py b/util/uf2conv.py new file mode 100755 index 000000000..044a7f231 --- /dev/null +++ b/util/uf2conv.py | |||
@@ -0,0 +1,319 @@ | |||
1 | #!/usr/bin/env python3 | ||
2 | import sys | ||
3 | import struct | ||
4 | import subprocess | ||
5 | import re | ||
6 | import os | ||
7 | import os.path | ||
8 | import argparse | ||
9 | |||
10 | |||
11 | UF2_MAGIC_START0 = 0x0A324655 # "UF2\n" | ||
12 | UF2_MAGIC_START1 = 0x9E5D5157 # Randomly selected | ||
13 | UF2_MAGIC_END = 0x0AB16F30 # Ditto | ||
14 | |||
15 | families = { | ||
16 | 'SAMD21': 0x68ed2b88, | ||
17 | 'SAML21': 0x1851780a, | ||
18 | 'SAMD51': 0x55114460, | ||
19 | 'NRF52': 0x1b57745f, | ||
20 | 'STM32F0': 0x647824b6, | ||
21 | 'STM32F1': 0x5ee21072, | ||
22 | 'STM32F2': 0x5d1a0a2e, | ||
23 | 'STM32F3': 0x6b846188, | ||
24 | 'STM32F4': 0x57755a57, | ||
25 | 'STM32F7': 0x53b80f00, | ||
26 | 'STM32G0': 0x300f5633, | ||
27 | 'STM32G4': 0x4c71240a, | ||
28 | 'STM32H7': 0x6db66082, | ||
29 | 'STM32L0': 0x202e3a91, | ||
30 | 'STM32L1': 0x1e1f432d, | ||
31 | 'STM32L4': 0x00ff6919, | ||
32 | 'STM32L5': 0x04240bdf, | ||
33 | 'STM32WB': 0x70d16653, | ||
34 | 'STM32WL': 0x21460ff0, | ||
35 | 'ATMEGA32': 0x16573617, | ||
36 | 'MIMXRT10XX': 0x4FB2D5BD, | ||
37 | 'LPC55': 0x2abc77ec, | ||
38 | 'GD32F350': 0x31D228C6, | ||
39 | 'ESP32S2': 0xbfdd4eee, | ||
40 | 'RP2040': 0xe48bff56 | ||
41 | } | ||
42 | |||
43 | INFO_FILE = "/INFO_UF2.TXT" | ||
44 | |||
45 | appstartaddr = 0x2000 | ||
46 | familyid = 0x0 | ||
47 | |||
48 | |||
49 | def is_uf2(buf): | ||
50 | w = struct.unpack("<II", buf[0:8]) | ||
51 | return w[0] == UF2_MAGIC_START0 and w[1] == UF2_MAGIC_START1 | ||
52 | |||
53 | def is_hex(buf): | ||
54 | try: | ||
55 | w = buf[0:30].decode("utf-8") | ||
56 | except UnicodeDecodeError: | ||
57 | return False | ||
58 | if w[0] == ':' and re.match(b"^[:0-9a-fA-F\r\n]+$", buf): | ||
59 | return True | ||
60 | return False | ||
61 | |||
62 | def convert_from_uf2(buf): | ||
63 | global appstartaddr | ||
64 | numblocks = len(buf) // 512 | ||
65 | curraddr = None | ||
66 | outp = [] | ||
67 | for blockno in range(numblocks): | ||
68 | ptr = blockno * 512 | ||
69 | block = buf[ptr:ptr + 512] | ||
70 | hd = struct.unpack(b"<IIIIIIII", block[0:32]) | ||
71 | if hd[0] != UF2_MAGIC_START0 or hd[1] != UF2_MAGIC_START1: | ||
72 | print("Skipping block at " + ptr + "; bad magic") | ||
73 | continue | ||
74 | if hd[2] & 1: | ||
75 | # NO-flash flag set; skip block | ||
76 | continue | ||
77 | datalen = hd[4] | ||
78 | if datalen > 476: | ||
79 | assert False, "Invalid UF2 data size at " + ptr | ||
80 | newaddr = hd[3] | ||
81 | if curraddr == None: | ||
82 | appstartaddr = newaddr | ||
83 | curraddr = newaddr | ||
84 | padding = newaddr - curraddr | ||
85 | if padding < 0: | ||
86 | assert False, "Block out of order at " + ptr | ||
87 | if padding > 10*1024*1024: | ||
88 | assert False, "More than 10M of padding needed at " + ptr | ||
89 | if padding % 4 != 0: | ||
90 | assert False, "Non-word padding size at " + ptr | ||
91 | while padding > 0: | ||
92 | padding -= 4 | ||
93 | outp += b"\x00\x00\x00\x00" | ||
94 | outp.append(block[32 : 32 + datalen]) | ||
95 | curraddr = newaddr + datalen | ||
96 | return b"".join(outp) | ||
97 | |||
98 | def convert_to_carray(file_content): | ||
99 | outp = "const unsigned long bindata_len = %d;\n" % len(file_content) | ||
100 | outp += "const unsigned char bindata[] __attribute__((aligned(16))) = {" | ||
101 | for i in range(len(file_content)): | ||
102 | if i % 16 == 0: | ||
103 | outp += "\n" | ||
104 | outp += "0x%02x, " % file_content[i] | ||
105 | outp += "\n};\n" | ||
106 | return bytes(outp, "utf-8") | ||
107 | |||
108 | def convert_to_uf2(file_content): | ||
109 | global familyid | ||
110 | datapadding = b"" | ||
111 | while len(datapadding) < 512 - 256 - 32 - 4: | ||
112 | datapadding += b"\x00\x00\x00\x00" | ||
113 | numblocks = (len(file_content) + 255) // 256 | ||
114 | outp = [] | ||
115 | for blockno in range(numblocks): | ||
116 | ptr = 256 * blockno | ||
117 | chunk = file_content[ptr:ptr + 256] | ||
118 | flags = 0x0 | ||
119 | if familyid: | ||
120 | flags |= 0x2000 | ||
121 | hd = struct.pack(b"<IIIIIIII", | ||
122 | UF2_MAGIC_START0, UF2_MAGIC_START1, | ||
123 | flags, ptr + appstartaddr, 256, blockno, numblocks, familyid) | ||
124 | while len(chunk) < 256: | ||
125 | chunk += b"\x00" | ||
126 | block = hd + chunk + datapadding + struct.pack(b"<I", UF2_MAGIC_END) | ||
127 | assert len(block) == 512 | ||
128 | outp.append(block) | ||
129 | return b"".join(outp) | ||
130 | |||
131 | class Block: | ||
132 | def __init__(self, addr): | ||
133 | self.addr = addr | ||
134 | self.bytes = bytearray(256) | ||
135 | |||
136 | def encode(self, blockno, numblocks): | ||
137 | global familyid | ||
138 | flags = 0x0 | ||
139 | if familyid: | ||
140 | flags |= 0x2000 | ||
141 | hd = struct.pack("<IIIIIIII", | ||
142 | UF2_MAGIC_START0, UF2_MAGIC_START1, | ||
143 | flags, self.addr, 256, blockno, numblocks, familyid) | ||
144 | hd += self.bytes[0:256] | ||
145 | while len(hd) < 512 - 4: | ||
146 | hd += b"\x00" | ||
147 | hd += struct.pack("<I", UF2_MAGIC_END) | ||
148 | return hd | ||
149 | |||
150 | def convert_from_hex_to_uf2(buf): | ||
151 | global appstartaddr | ||
152 | appstartaddr = None | ||
153 | upper = 0 | ||
154 | currblock = None | ||
155 | blocks = [] | ||
156 | for line in buf.split('\n'): | ||
157 | if line[0] != ":": | ||
158 | continue | ||
159 | i = 1 | ||
160 | rec = [] | ||
161 | while i < len(line) - 1: | ||
162 | rec.append(int(line[i:i+2], 16)) | ||
163 | i += 2 | ||
164 | tp = rec[3] | ||
165 | if tp == 4: | ||
166 | upper = ((rec[4] << 8) | rec[5]) << 16 | ||
167 | elif tp == 2: | ||
168 | upper = ((rec[4] << 8) | rec[5]) << 4 | ||
169 | assert (upper & 0xffff) == 0 | ||
170 | elif tp == 1: | ||
171 | break | ||
172 | elif tp == 0: | ||
173 | addr = upper | (rec[1] << 8) | rec[2] | ||
174 | if appstartaddr == None: | ||
175 | appstartaddr = addr | ||
176 | i = 4 | ||
177 | while i < len(rec) - 1: | ||
178 | if not currblock or currblock.addr & ~0xff != addr & ~0xff: | ||
179 | currblock = Block(addr & ~0xff) | ||
180 | blocks.append(currblock) | ||
181 | currblock.bytes[addr & 0xff] = rec[i] | ||
182 | addr += 1 | ||
183 | i += 1 | ||
184 | numblocks = len(blocks) | ||
185 | resfile = b"" | ||
186 | for i in range(0, numblocks): | ||
187 | resfile += blocks[i].encode(i, numblocks) | ||
188 | return resfile | ||
189 | |||
190 | def to_str(b): | ||
191 | return b.decode("utf-8") | ||
192 | |||
193 | def get_drives(): | ||
194 | drives = [] | ||
195 | if sys.platform == "win32": | ||
196 | r = subprocess.check_output(["wmic", "PATH", "Win32_LogicalDisk", | ||
197 | "get", "DeviceID,", "VolumeName,", | ||
198 | "FileSystem,", "DriveType"]) | ||
199 | for line in to_str(r).split('\n'): | ||
200 | words = re.split('\s+', line) | ||
201 | if len(words) >= 3 and words[1] == "2" and words[2] == "FAT": | ||
202 | drives.append(words[0]) | ||
203 | else: | ||
204 | rootpath = "/media" | ||
205 | if sys.platform == "darwin": | ||
206 | rootpath = "/Volumes" | ||
207 | elif sys.platform == "linux": | ||
208 | tmp = rootpath + "/" + os.environ["USER"] | ||
209 | if os.path.isdir(tmp): | ||
210 | rootpath = tmp | ||
211 | for d in os.listdir(rootpath): | ||
212 | drives.append(os.path.join(rootpath, d)) | ||
213 | |||
214 | |||
215 | def has_info(d): | ||
216 | try: | ||
217 | return os.path.isfile(d + INFO_FILE) | ||
218 | except: | ||
219 | return False | ||
220 | |||
221 | return list(filter(has_info, drives)) | ||
222 | |||
223 | |||
224 | def board_id(path): | ||
225 | with open(path + INFO_FILE, mode='r') as file: | ||
226 | file_content = file.read() | ||
227 | return re.search("Board-ID: ([^\r\n]*)", file_content).group(1) | ||
228 | |||
229 | |||
230 | def list_drives(): | ||
231 | for d in get_drives(): | ||
232 | print(d, board_id(d)) | ||
233 | |||
234 | |||
235 | def write_file(name, buf): | ||
236 | with open(name, "wb") as f: | ||
237 | f.write(buf) | ||
238 | print("Wrote %d bytes to %s" % (len(buf), name)) | ||
239 | |||
240 | |||
241 | def main(): | ||
242 | global appstartaddr, familyid | ||
243 | def error(msg): | ||
244 | print(msg) | ||
245 | sys.exit(1) | ||
246 | parser = argparse.ArgumentParser(description='Convert to UF2 or flash directly.') | ||
247 | parser.add_argument('input', metavar='INPUT', type=str, nargs='?', | ||
248 | help='input file (HEX, BIN or UF2)') | ||
249 | parser.add_argument('-b' , '--base', dest='base', type=str, | ||
250 | default="0x2000", | ||
251 | help='set base address of application for BIN format (default: 0x2000)') | ||
252 | parser.add_argument('-o' , '--output', metavar="FILE", dest='output', type=str, | ||
253 | help='write output to named file; defaults to "flash.uf2" or "flash.bin" where sensible') | ||
254 | parser.add_argument('-d' , '--device', dest="device_path", | ||
255 | help='select a device path to flash') | ||
256 | parser.add_argument('-l' , '--list', action='store_true', | ||
257 | help='list connected devices') | ||
258 | parser.add_argument('-c' , '--convert', action='store_true', | ||
259 | help='do not flash, just convert') | ||
260 | parser.add_argument('-D' , '--deploy', action='store_true', | ||
261 | help='just flash, do not convert') | ||
262 | parser.add_argument('-f' , '--family', dest='family', type=str, | ||
263 | default="0x0", | ||
264 | help='specify familyID - number or name (default: 0x0)') | ||
265 | parser.add_argument('-C' , '--carray', action='store_true', | ||
266 | help='convert binary file to a C array, not UF2') | ||
267 | args = parser.parse_args() | ||
268 | appstartaddr = int(args.base, 0) | ||
269 | |||
270 | if args.family.upper() in families: | ||
271 | familyid = families[args.family.upper()] | ||
272 | else: | ||
273 | try: | ||
274 | familyid = int(args.family, 0) | ||
275 | except ValueError: | ||
276 | error("Family ID needs to be a number or one of: " + ", ".join(families.keys())) | ||
277 | |||
278 | if args.list: | ||
279 | list_drives() | ||
280 | else: | ||
281 | if not args.input: | ||
282 | error("Need input file") | ||
283 | with open(args.input, mode='rb') as f: | ||
284 | inpbuf = f.read() | ||
285 | from_uf2 = is_uf2(inpbuf) | ||
286 | ext = "uf2" | ||
287 | if args.deploy: | ||
288 | outbuf = inpbuf | ||
289 | elif from_uf2: | ||
290 | outbuf = convert_from_uf2(inpbuf) | ||
291 | ext = "bin" | ||
292 | elif is_hex(inpbuf): | ||
293 | outbuf = convert_from_hex_to_uf2(inpbuf.decode("utf-8")) | ||
294 | elif args.carray: | ||
295 | outbuf = convert_to_carray(inpbuf) | ||
296 | ext = "h" | ||
297 | else: | ||
298 | outbuf = convert_to_uf2(inpbuf) | ||
299 | print("Converting to %s, output size: %d, start address: 0x%x" % | ||
300 | (ext, len(outbuf), appstartaddr)) | ||
301 | if args.convert or ext != "uf2": | ||
302 | drives = [] | ||
303 | if args.output == None: | ||
304 | args.output = "flash." + ext | ||
305 | else: | ||
306 | drives = get_drives() | ||
307 | |||
308 | if args.output: | ||
309 | write_file(args.output, outbuf) | ||
310 | else: | ||
311 | if len(drives) == 0: | ||
312 | error("No drive to deploy.") | ||
313 | for d in drives: | ||
314 | print("Flashing %s (%s)" % (d, board_id(d))) | ||
315 | write_file(d + "/NEW.UF2", outbuf) | ||
316 | |||
317 | |||
318 | if __name__ == "__main__": | ||
319 | main() | ||