Compare commits

..

No commits in common. "1bbacec44d6be90b6044ca46865738887e709b30" and "e11235ee14f9cd3fc45b836eec99ed312cb137dd" have entirely different histories.

32 changed files with 313 additions and 488 deletions

View File

@ -180,6 +180,13 @@ generated-files: $(KEYMAP_OUTPUT)/src/config.h $(KEYMAP_OUTPUT)/src/keymap.c
endif
# PLATFORM_KEY should be detected in info.json via key 'processor' (or rules.mk 'MCU')
ifeq ($(PLATFORM_KEY),)
$(call CATASTROPHIC_ERROR,Platform not defined)
endif
PLATFORM=$(shell echo $(PLATFORM_KEY) | tr '[:lower:]' '[:upper:]')
include $(BUILDDEFS_PATH)/converters.mk
include $(BUILDDEFS_PATH)/mcu_selection.mk
@ -257,24 +264,6 @@ ifneq ("$(wildcard $(KEYBOARD_PATH_5)/$(KEYBOARD_FOLDER_5).h)","")
FOUND_KEYBOARD_H = $(KEYBOARD_FOLDER_5).h
endif
# Determine and set parameters based on the keyboard's processor family.
# We can assume a ChibiOS target When MCU_FAMILY is defined since it's
# not used for LUFA
ifdef MCU_FAMILY
PLATFORM=CHIBIOS
PLATFORM_KEY=chibios
FIRMWARE_FORMAT?=bin
OPT_DEFS += -DMCU_$(MCU_FAMILY)
else ifdef ARM_ATSAM
PLATFORM=ARM_ATSAM
PLATFORM_KEY=arm_atsam
FIRMWARE_FORMAT=bin
else
PLATFORM=AVR
PLATFORM_KEY=avr
FIRMWARE_FORMAT?=hex
endif
# Find all of the config.h files and add them to our CONFIG_H define.
CONFIG_H :=
ifneq ("$(wildcard $(KEYBOARD_PATH_5)/config.h)","")

View File

@ -1,8 +1,19 @@
# Note for new boards -- CTPC and CONVERT_TO_PROTON_C are deprecated terms
# and should not be replicated for new boards. These will be removed from
# documentation as well as existing keymaps in due course.
ifneq ($(findstring yes, $(CTPC)$(CONVERT_TO_PROTON_C)),)
$(call CATASTROPHIC_ERROR,The `CONVERT_TO_PROTON_C` and `CTPC` options are now deprecated. `CONVERT_TO=proton_c` should be used instead.)
ifeq ($(strip $(CTPC)), yes)
CONVERT_TO_PROTON_C=yes
endif
ifeq ($(strip $(CONVERT_TO_PROTON_C)), yes)
CONVERT_TO=proton_c
cpfirmware: ctpc_warning
.INTERMEDIATE: ctpc_warning
ctpc_warning: elf
$(info @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@)
$(info The `CONVERT_TO_PROTON_C` and `CTPC` options are soon to be deprecated.)
$(info Boards should be changed to use `CONVERT_TO=proton_c` instead.)
$(info @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@)
endif
# TODO: opt in rather than assume everything uses a pro micro

View File

@ -38,6 +38,8 @@
"PS2_MOUSE_ENABLE": {"info_key": "ps2.mouse_enabled", "value_type": "bool"},
"PS2_DRIVER": {"info_key": "ps2.driver"},
"PLATFORM_KEY": {"info_key": "platform_key", "to_json": false},
// Items we want flagged in lint
"CTPC": {"info_key": "_deprecated.ctpc", "deprecated": true, "replace_with": "CONVERT_TO=proton_c"},
"CONVERT_TO_PROTON_C": {"info_key": "_deprecated.ctpc", "deprecated": true, "replace_with": "CONVERT_TO=proton_c"},

View File

@ -14,7 +14,7 @@ The laser cutting file is ideal for Ponoko's P1 board size.
If you want to reflash the pre-installed firmware, use the `.bin` file for Proton C and the `.hex` file for Pro Micro builds. Flash with the QMK Toolbox or via the command line.
Building for Proton C: `make ckeys/handwire_101:default CONVERT_TO=proton_c`
Building for Proton C: `make ckeys/handwire_101:default CTPC=yes`
Building for Pro Micro: `make ckeys/handwire_101:default`
Pre-built firmware files (and laser cutting case files) can be found here: https://github.com/c-keys/handwire

View File

@ -1,4 +1,4 @@
MOUSEKEY_ENABLE = yes
ifneq (, $(findstring rev1, $(KEYBOARD)))
CONVERT_TO=proton_c
CTPC = yes
endif

View File

@ -27,77 +27,77 @@
{"matrix":[0,13], "x":14, "y":0},
{"matrix":[0,15], "x":15.25, "y":0},
{"matrix":[1, 0], "x":0, "y":1.25},
{"matrix":[1, 1], "x":1, "y":1.25},
{"matrix":[1, 2], "x":2, "y":1.25},
{"matrix":[1, 3], "x":3, "y":1.25},
{"matrix":[1, 4], "x":4, "y":1.25},
{"matrix":[1, 5], "x":5, "y":1.25},
{"matrix":[1, 6], "x":6, "y":1.25},
{"matrix":[1, 7], "x":7, "y":1.25},
{"matrix":[1, 8], "x":8, "y":1.25},
{"matrix":[1, 9], "x":9, "y":1.25},
{"matrix":[1,10], "x":10, "y":1.25},
{"matrix":[1,11], "x":11, "y":1.25},
{"matrix":[1,12], "x":12, "y":1.25},
{"matrix":[1,13], "x":13, "y":1.25, "w":2},
{"matrix":[1,15], "x":15.25, "y":1.25},
{"matrix":[1, 0], "x":0, "y":1},
{"matrix":[1, 1], "x":1, "y":1},
{"matrix":[1, 2], "x":2, "y":1},
{"matrix":[1, 3], "x":3, "y":1},
{"matrix":[1, 4], "x":4, "y":1},
{"matrix":[1, 5], "x":5, "y":1},
{"matrix":[1, 6], "x":6, "y":1},
{"matrix":[1, 7], "x":7, "y":1},
{"matrix":[1, 8], "x":8, "y":1},
{"matrix":[1, 9], "x":9, "y":1},
{"matrix":[1,10], "x":10, "y":1},
{"matrix":[1,11], "x":11, "y":1},
{"matrix":[1,12], "x":12, "y":1},
{"matrix":[1,13], "x":13, "y":1, "w":2},
{"matrix":[1,15], "x":15.25, "y":1},
{"matrix":[2, 0], "x":0, "y":2.25, "w":1.5},
{"matrix":[2, 1], "x":1.5, "y":2.25},
{"matrix":[2, 2], "x":2.5, "y":2.25},
{"matrix":[2, 3], "x":3.5, "y":2.25},
{"matrix":[2, 4], "x":4.5, "y":2.25},
{"matrix":[2, 5], "x":5.5, "y":2.25},
{"matrix":[2, 6], "x":6.5, "y":2.25},
{"matrix":[2, 7], "x":7.5, "y":2.25},
{"matrix":[2, 8], "x":8.5, "y":2.25},
{"matrix":[2, 9], "x":9.5, "y":2.25},
{"matrix":[2,10], "x":10.5, "y":2.25},
{"matrix":[2,11], "x":11.5, "y":2.25},
{"matrix":[2,12], "x":12.5, "y":2.25},
{"matrix":[2,13], "x":13.5, "y":2.25, "w":1.5},
{"matrix":[2,15], "x":15.25, "y":2.25},
{"matrix":[2, 0], "x":0, "y":2, "w":1.5},
{"matrix":[2, 1], "x":1.5, "y":2},
{"matrix":[2, 2], "x":2.5, "y":2},
{"matrix":[2, 3], "x":3.5, "y":2},
{"matrix":[2, 4], "x":4.5, "y":2},
{"matrix":[2, 5], "x":5.5, "y":2},
{"matrix":[2, 6], "x":6.5, "y":2},
{"matrix":[2, 7], "x":7.5, "y":2},
{"matrix":[2, 8], "x":8.5, "y":2},
{"matrix":[2, 9], "x":9.5, "y":2},
{"matrix":[2,10], "x":10.5, "y":2},
{"matrix":[2,11], "x":11.5, "y":2},
{"matrix":[2,12], "x":12.5, "y":2},
{"matrix":[2,13], "x":13.5, "y":2, "w":1.5},
{"matrix":[2,15], "x":15.25, "y":2},
{"matrix":[3, 0], "x":0, "y":3.25, "w":1.75},
{"matrix":[3, 1], "x":1.75, "y":3.25},
{"matrix":[3, 2], "x":2.75, "y":3.25},
{"matrix":[3, 3], "x":3.75, "y":3.25},
{"matrix":[3, 4], "x":4.75, "y":3.25},
{"matrix":[3, 5], "x":5.75, "y":3.25},
{"matrix":[3, 6], "x":6.75, "y":3.25},
{"matrix":[3, 7], "x":7.75, "y":3.25},
{"matrix":[3, 8], "x":8.75, "y":3.25},
{"matrix":[3, 9], "x":9.75, "y":3.25},
{"matrix":[3,10], "x":10.75, "y":3.25},
{"matrix":[3,11], "x":11.75, "y":3.25},
{"matrix":[3,13], "x":12.75, "y":3.25, "w":2.25},
{"matrix":[3,15], "x":15.25, "y":3.25},
{"matrix":[3, 0], "x":0, "y":3, "w":1.75},
{"matrix":[3, 1], "x":1.75, "y":3},
{"matrix":[3, 2], "x":2.75, "y":3},
{"matrix":[3, 3], "x":3.75, "y":3},
{"matrix":[3, 4], "x":4.75, "y":3},
{"matrix":[3, 5], "x":5.75, "y":3},
{"matrix":[3, 6], "x":6.75, "y":3},
{"matrix":[3, 7], "x":7.75, "y":3},
{"matrix":[3, 8], "x":8.75, "y":3},
{"matrix":[3, 9], "x":9.75, "y":3},
{"matrix":[3,10], "x":10.75, "y":3},
{"matrix":[3,11], "x":11.75, "y":3},
{"matrix":[3,13], "x":12.75, "y":3, "w":2.25},
{"matrix":[3,15], "x":15.25, "y":3},
{"matrix":[4, 0], "x":0, "y":4.25, "w":2.25},
{"matrix":[4, 2], "x":2.25, "y":4.25},
{"matrix":[4, 3], "x":3.25, "y":4.25},
{"matrix":[4, 4], "x":4.25, "y":4.25},
{"matrix":[4, 5], "x":5.25, "y":4.25},
{"matrix":[4, 6], "x":6.25, "y":4.25},
{"matrix":[4, 7], "x":7.25, "y":4.25},
{"matrix":[4, 8], "x":8.25, "y":4.25},
{"matrix":[4, 9], "x":9.25, "y":4.25},
{"matrix":[4,10], "x":10.25, "y":4.25},
{"matrix":[4,11], "x":11.25, "y":4.25},
{"matrix":[4,13], "x":12.25, "y":4.25, "w":1.75},
{"matrix":[4,14], "x":14.25, "y":4.5},
{"matrix":[4, 0], "x":0, "y":4, "w":2.25},
{"matrix":[4, 2], "x":2.25, "y":4},
{"matrix":[4, 3], "x":3.25, "y":4},
{"matrix":[4, 4], "x":4.25, "y":4},
{"matrix":[4, 5], "x":5.25, "y":4},
{"matrix":[4, 6], "x":6.25, "y":4},
{"matrix":[4, 7], "x":7.25, "y":4},
{"matrix":[4, 8], "x":8.25, "y":4},
{"matrix":[4, 9], "x":9.25, "y":4},
{"matrix":[4,10], "x":10.25, "y":4},
{"matrix":[4,11], "x":11.25, "y":4},
{"matrix":[4,13], "x":12.25, "y":4, "w":1.75},
{"matrix":[4,14], "x":14.25, "y":4.25},
{"matrix":[5, 0], "x":0, "y":5.25, "w":1.25},
{"matrix":[5, 1], "x":1.25, "y":5.25, "w":1.25},
{"matrix":[5, 2], "x":2.5, "y":5.25, "w":1.25},
{"matrix":[5, 6], "x":3.75, "y":5.25, "w":6.25},
{"matrix":[5,10], "x":10, "y":5.25},
{"matrix":[5,11], "x":11, "y":5.25},
{"matrix":[5,12], "x":12, "y":5.25},
{"matrix":[5,13], "x":13.25, "y":5.5},
{"matrix":[5,14], "x":14.25, "y":5.5},
{"matrix":[5,15], "x":15.25, "y":5.5}
{"matrix":[5, 0], "x":0, "y":5, "w":1.25},
{"matrix":[5, 1], "x":1.25, "y":5, "w":1.25},
{"matrix":[5, 2], "x":2.5, "y":5, "w":1.25},
{"matrix":[5, 6], "x":3.75, "y":5, "w":6.25},
{"matrix":[5,10], "x":10, "y":5},
{"matrix":[5,11], "x":11, "y":5},
{"matrix":[5,12], "x":12, "y":5},
{"matrix":[5,13], "x":13.25, "y":5.25},
{"matrix":[5,14], "x":14.25, "y":5.25},
{"matrix":[5,15], "x":15.25, "y":5.25}
]
}
}

View File

@ -27,77 +27,77 @@
{"matrix":[0,13], "x":14, "y":0},
{"matrix":[0,15], "x":15.25, "y":0},
{"matrix":[1, 0], "x":0, "y":1.25},
{"matrix":[1, 1], "x":1, "y":1.25},
{"matrix":[1, 2], "x":2, "y":1.25},
{"matrix":[1, 3], "x":3, "y":1.25},
{"matrix":[1, 4], "x":4, "y":1.25},
{"matrix":[1, 5], "x":5, "y":1.25},
{"matrix":[1, 6], "x":6, "y":1.25},
{"matrix":[1, 7], "x":7, "y":1.25},
{"matrix":[1, 8], "x":8, "y":1.25},
{"matrix":[1, 9], "x":9, "y":1.25},
{"matrix":[1,10], "x":10, "y":1.25},
{"matrix":[1,11], "x":11, "y":1.25},
{"matrix":[1,12], "x":12, "y":1.25},
{"matrix":[1,13], "x":13, "y":1.25, "w":2},
{"matrix":[1,15], "x":15.25, "y":1.25},
{"matrix":[1, 0], "x":0, "y":1},
{"matrix":[1, 1], "x":1, "y":1},
{"matrix":[1, 2], "x":2, "y":1},
{"matrix":[1, 3], "x":3, "y":1},
{"matrix":[1, 4], "x":4, "y":1},
{"matrix":[1, 5], "x":5, "y":1},
{"matrix":[1, 6], "x":6, "y":1},
{"matrix":[1, 7], "x":7, "y":1},
{"matrix":[1, 8], "x":8, "y":1},
{"matrix":[1, 9], "x":9, "y":1},
{"matrix":[1,10], "x":10, "y":1},
{"matrix":[1,11], "x":11, "y":1},
{"matrix":[1,12], "x":12, "y":1},
{"matrix":[1,13], "x":13, "y":1, "w":2},
{"matrix":[1,15], "x":15.25, "y":1},
{"matrix":[2, 0], "x":0, "y":2.25, "w":1.5},
{"matrix":[2, 1], "x":1.5, "y":2.25},
{"matrix":[2, 2], "x":2.5, "y":2.25},
{"matrix":[2, 3], "x":3.5, "y":2.25},
{"matrix":[2, 4], "x":4.5, "y":2.25},
{"matrix":[2, 5], "x":5.5, "y":2.25},
{"matrix":[2, 6], "x":6.5, "y":2.25},
{"matrix":[2, 7], "x":7.5, "y":2.25},
{"matrix":[2, 8], "x":8.5, "y":2.25},
{"matrix":[2, 9], "x":9.5, "y":2.25},
{"matrix":[2,10], "x":10.5, "y":2.25},
{"matrix":[2,11], "x":11.5, "y":2.25},
{"matrix":[2,12], "x":12.5, "y":2.25},
{"matrix":[2,13], "x":13.5, "y":2.25, "w":1.5},
{"matrix":[2,15], "x":15.25, "y":2.25},
{"matrix":[2, 0], "x":0, "y":2, "w":1.5},
{"matrix":[2, 1], "x":1.5, "y":2},
{"matrix":[2, 2], "x":2.5, "y":2},
{"matrix":[2, 3], "x":3.5, "y":2},
{"matrix":[2, 4], "x":4.5, "y":2},
{"matrix":[2, 5], "x":5.5, "y":2},
{"matrix":[2, 6], "x":6.5, "y":2},
{"matrix":[2, 7], "x":7.5, "y":2},
{"matrix":[2, 8], "x":8.5, "y":2},
{"matrix":[2, 9], "x":9.5, "y":2},
{"matrix":[2,10], "x":10.5, "y":2},
{"matrix":[2,11], "x":11.5, "y":2},
{"matrix":[2,12], "x":12.5, "y":2},
{"matrix":[2,13], "x":13.5, "y":2, "w":1.5},
{"matrix":[2,15], "x":15.25, "y":2},
{"matrix":[3, 0], "x":0, "y":3.25, "w":1.75},
{"matrix":[3, 1], "x":1.75, "y":3.25},
{"matrix":[3, 2], "x":2.75, "y":3.25},
{"matrix":[3, 3], "x":3.75, "y":3.25},
{"matrix":[3, 4], "x":4.75, "y":3.25},
{"matrix":[3, 5], "x":5.75, "y":3.25},
{"matrix":[3, 6], "x":6.75, "y":3.25},
{"matrix":[3, 7], "x":7.75, "y":3.25},
{"matrix":[3, 8], "x":8.75, "y":3.25},
{"matrix":[3, 9], "x":9.75, "y":3.25},
{"matrix":[3,10], "x":10.75, "y":3.25},
{"matrix":[3,11], "x":11.75, "y":3.25},
{"matrix":[3,13], "x":12.75, "y":3.25, "w":2.25},
{"matrix":[3,15], "x":15.25, "y":3.25},
{"matrix":[3, 0], "x":0, "y":3, "w":1.75},
{"matrix":[3, 1], "x":1.75, "y":3},
{"matrix":[3, 2], "x":2.75, "y":3},
{"matrix":[3, 3], "x":3.75, "y":3},
{"matrix":[3, 4], "x":4.75, "y":3},
{"matrix":[3, 5], "x":5.75, "y":3},
{"matrix":[3, 6], "x":6.75, "y":3},
{"matrix":[3, 7], "x":7.75, "y":3},
{"matrix":[3, 8], "x":8.75, "y":3},
{"matrix":[3, 9], "x":9.75, "y":3},
{"matrix":[3,10], "x":10.75, "y":3},
{"matrix":[3,11], "x":11.75, "y":3},
{"matrix":[3,13], "x":12.75, "y":3, "w":2.25},
{"matrix":[3,15], "x":15.25, "y":3},
{"matrix":[4, 0], "x":0, "y":4.25, "w":2.25},
{"matrix":[4, 2], "x":2.25, "y":4.25},
{"matrix":[4, 3], "x":3.25, "y":4.25},
{"matrix":[4, 4], "x":4.25, "y":4.25},
{"matrix":[4, 5], "x":5.25, "y":4.25},
{"matrix":[4, 6], "x":6.25, "y":4.25},
{"matrix":[4, 7], "x":7.25, "y":4.25},
{"matrix":[4, 8], "x":8.25, "y":4.25},
{"matrix":[4, 9], "x":9.25, "y":4.25},
{"matrix":[4,10], "x":10.25, "y":4.25},
{"matrix":[4,11], "x":11.25, "y":4.25},
{"matrix":[4,13], "x":12.25, "y":4.25, "w":1.75},
{"matrix":[4,14], "x":14.25, "y":4.5},
{"matrix":[4, 0], "x":0, "y":4, "w":2.25},
{"matrix":[4, 2], "x":2.25, "y":4},
{"matrix":[4, 3], "x":3.25, "y":4},
{"matrix":[4, 4], "x":4.25, "y":4},
{"matrix":[4, 5], "x":5.25, "y":4},
{"matrix":[4, 6], "x":6.25, "y":4},
{"matrix":[4, 7], "x":7.25, "y":4},
{"matrix":[4, 8], "x":8.25, "y":4},
{"matrix":[4, 9], "x":9.25, "y":4},
{"matrix":[4,10], "x":10.25, "y":4},
{"matrix":[4,11], "x":11.25, "y":4},
{"matrix":[4,13], "x":12.25, "y":4, "w":1.75},
{"matrix":[4,14], "x":14.25, "y":4.25},
{"matrix":[5, 0], "x":0, "y":5.25, "w":1.25},
{"matrix":[5, 1], "x":1.25, "y":5.25, "w":1.25},
{"matrix":[5, 2], "x":2.5, "y":5.25, "w":1.25},
{"matrix":[5, 6], "x":3.75, "y":5.25, "w":6.25},
{"matrix":[5,10], "x":10, "y":5.25},
{"matrix":[5,11], "x":11, "y":5.25},
{"matrix":[5,12], "x":12, "y":5.25},
{"matrix":[5,13], "x":13.25, "y":5.5},
{"matrix":[5,14], "x":14.25, "y":5.5},
{"matrix":[5,15], "x":15.25, "y":5.5}
{"matrix":[5, 0], "x":0, "y":5, "w":1.25},
{"matrix":[5, 1], "x":1.25, "y":5, "w":1.25},
{"matrix":[5, 2], "x":2.5, "y":5, "w":1.25},
{"matrix":[5, 6], "x":3.75, "y":5, "w":6.25},
{"matrix":[5,10], "x":10, "y":5},
{"matrix":[5,11], "x":11, "y":5},
{"matrix":[5,12], "x":12, "y":5},
{"matrix":[5,13], "x":13.25, "y":5.25},
{"matrix":[5,14], "x":14.25, "y":5.25},
{"matrix":[5,15], "x":15.25, "y":5.25}
]
}
}

View File

@ -25,9 +25,9 @@
{"matrix":[0,11], "x":11.75, "y":0},
{"matrix":[0,12], "x":12.75, "y":0},
{"matrix":[0,13], "x":14, "y":0},
{"matrix":[0,14], "x":15.25, "y":0},
{"matrix":[0,15], "x":16.25, "y":0},
{"matrix":[3,14], "x":17.25, "y":0},
{"matrix":[0,14], "x":15.75, "y":0},
{"matrix":[0,15], "x":16.75, "y":0},
{"matrix":[3,14], "x":17.75, "y":0},
{"matrix":[1, 0], "x":0, "y":1.25},
{"matrix":[1, 1], "x":1, "y":1.25},
@ -43,9 +43,9 @@
{"matrix":[1,11], "x":11, "y":1.25},
{"matrix":[1,12], "x":12, "y":1.25},
{"matrix":[1,13], "x":13, "y":1.25, "w":2},
{"matrix":[1,14], "x":15.25, "y":1.25},
{"matrix":[1,15], "x":16.25, "y":1.25},
{"matrix":[3,15], "x":17.25, "y":1.25},
{"matrix":[1,14], "x":15.75, "y":1.25},
{"matrix":[1,15], "x":16.75, "y":1.25},
{"matrix":[3,15], "x":17.75, "y":1.25},
{"matrix":[2, 0], "x":0, "y":2.25, "w":1.5},
{"matrix":[2, 1], "x":1.5, "y":2.25},
@ -61,9 +61,9 @@
{"matrix":[2,11], "x":11.5, "y":2.25},
{"matrix":[2,12], "x":12.5, "y":2.25},
{"matrix":[2,13], "x":13.5, "y":2.25, "w":1.5},
{"matrix":[2,14], "x":15.25, "y":2.25},
{"matrix":[2,15], "x":16.25, "y":2.25},
{"matrix":[3,12], "x":17.25, "y":2.25},
{"matrix":[2,14], "x":15.75, "y":2.25},
{"matrix":[2,15], "x":16.75, "y":2.25},
{"matrix":[3,12], "x":17.75, "y":2.25},
{"matrix":[3, 0], "x":0, "y":3.25, "w":1.75},
{"matrix":[3, 1], "x":1.75, "y":3.25},
@ -91,7 +91,7 @@
{"matrix":[4,10], "x":10.25, "y":4.25},
{"matrix":[4,11], "x":11.25, "y":4.25},
{"matrix":[4,13], "x":12.25, "y":4.25, "w":2.75},
{"matrix":[4,15], "x":16.25, "y":4.25},
{"matrix":[4,15], "x":16.75, "y":4.25},
{"matrix":[5, 0], "x":0, "y":5.25, "w":1.25},
{"matrix":[5, 1], "x":1.25, "y":5.25, "w":1.25},
@ -101,9 +101,9 @@
{"matrix":[5,11], "x":11.25, "y":5.25, "w":1.25},
{"matrix":[5,12], "x":12.5, "y":5.25, "w":1.25},
{"matrix":[5,13], "x":13.75, "y":5.25, "w":1.25},
{"matrix":[5,14], "x":15.25, "y":5.25},
{"matrix":[5,15], "x":16.25, "y":5.25},
{"matrix":[4,14], "x":17.25, "y":5.25}
{"matrix":[5,14], "x":15.75, "y":5.25},
{"matrix":[5,15], "x":16.75, "y":5.25},
{"matrix":[4,14], "x":17.75, "y":5.25}
]
}
}

View File

@ -25,9 +25,9 @@
{"matrix":[0,11], "x":11.75, "y":0},
{"matrix":[0,12], "x":12.75, "y":0},
{"matrix":[0,13], "x":14, "y":0},
{"matrix":[0,14], "x":15.25, "y":0},
{"matrix":[0,15], "x":16.25, "y":0},
{"matrix":[3,14], "x":17.25, "y":0},
{"matrix":[0,14], "x":15.75, "y":0},
{"matrix":[0,15], "x":16.75, "y":0},
{"matrix":[3,14], "x":17.75, "y":0},
{"matrix":[1, 0], "x":0, "y":1.25},
{"matrix":[1, 1], "x":1, "y":1.25},

View File

@ -1,4 +1,4 @@
CONVERT_TO=proton_c
CTPC=yes
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
AUDIO_ENABLE = yes

View File

@ -1 +1 @@
CONVERT_TO=proton_c
CTPC = yes

View File

@ -12,7 +12,7 @@ To compile and flash to the board:
If you want to use this with a Proton C, do this instead:
make shapeshifter4060:debug CONVERT_TO=proton_c
make shapeshifter4060:debug CTPC=yes
To just compile:

View File

@ -13,7 +13,7 @@ Make example for this keyboard (after setting up your build environment):
For use with the Proton C
make shapeshifter4060:default CONVERT_TO=proton_c
make shapeshifter4060:default CTPC=yes
Flashing example for this keyboard:

View File

@ -41,7 +41,15 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define DIODE_DIRECTION COL2ROW
#define USB_MAX_POWER_CONSUMPTION 100
//#define LED_NUM_LOCK_PIN B0
//#define LED_CAPS_LOCK_PIN B1
//#define LED_SCROLL_LOCK_PIN B2
//#define LED_COMPOSE_PIN B3
//#define LED_KANA_PIN B4
//#define BACKLIGHT_PIN B7
//#define BACKLIGHT_LEVELS 3
//#define BACKLIGHT_BREATHING
#define RGBLIGHT_DI_PIN E6
//# define RGBLIGHT_HUE_STEP 8
@ -57,6 +65,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGBLIGHT_EFFECT_KNIGHT
#define RGBLIGHT_EFFECT_CHRISTMAS
#define RGBLIGHT_EFFECT_STATIC_GRADIENT
#define RGBLIGHT_EFFECT_RGB_TEST
#define RGBLIGHT_EFFECT_TWINKLE
#define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_STATIC_LIGHT
@ -75,8 +84,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGB_MATRIX_DISABLE_KEYCODES
#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_LEFT_RIGHT // Sets the default mode, if none has been set
#define RGB_DISABLE_WHEN_USB_SUSPENDED
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
// #define RGB_MATRIX_KEYPRESSES
// RGB Matrix Animation modes. Explicitly enabled
// For full list of effects, see:
@ -114,18 +121,18 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define ENABLE_RGB_MATRIX_TYPING_HEATMAP
#define ENABLE_RGB_MATRIX_DIGITAL_RAIN
// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
// #define ENABLE_RGB_MATRIX_SPLASH
// #define ENABLE_RGB_MATRIX_MULTISPLASH
// #define ENABLE_RGB_MATRIX_SOLID_SPLASH
// #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
#define ENABLE_RGB_MATRIX_SPLASH
#define ENABLE_RGB_MATRIX_MULTISPLASH
#define ENABLE_RGB_MATRIX_SOLID_SPLASH
#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
#define DEBOUNCE 5

View File

@ -14,15 +14,15 @@
{"label": "k01", "x": 1, "y": 0},
{"label": "k02", "x": 2, "y": 0},
{"label": "k03", "x": 3, "y": 0},
{"label": "k04", "x": 4, "y": 0},
{"label": "k05", "x": 5, "y": 0},
{"label": "k06", "x": 6, "y": 0},
{"label": "k07", "x": 7, "y": 0},
{"label": "k08", "x": 8, "y": 0},
{"label": "k09", "x": 9, "y": 0},
{"label": "k0a", "x": 10, "y": 0},
{"label": "k0b", "x": 11, "y": 0}
{"label": "k03", "x": 3, "y": 1, "w": 0},
{"label": "k04", "x": 4, "y": 1, "w": 0},
{"label": "k05", "x": 5, "y": 1, "w": 0},
{"label": "k06", "x": 6, "y": 1, "w": 0},
{"label": "k07", "x": 7, "y": 1, "w": 0},
{"label": "k08", "x": 8, "y": 1, "w": 0},
{"label": "k09", "x": 9, "y": 1, "w": 0},
{"label": "k0a", "x": 10, "y": 1, "w": 0},
{"label": "k0b", "x": 11, "y": 1, "w": 0}
]
}
}

View File

@ -9,15 +9,13 @@
* Feature disable options
* These options are also useful to firmware size reduction.
*/
#define USB_MAX_POWER_CONSUMPTION 100
#define RGB_DI_PIN D1
#define RGB_MATRIX_LED_COUNT 12
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 150
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 255
#define RGB_MATRIX_DISABLE_KEYCODES
#define RGB_DISABLE_WHEN_USB_SUSPENDED
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
// #define RGB_MATRIX_KEYPRESSES
#define RGBLIGHT_DI_PIN D2
#define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
@ -57,18 +55,18 @@
#define ENABLE_RGB_MATRIX_TYPING_HEATMAP
#define ENABLE_RGB_MATRIX_DIGITAL_RAIN
// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
// #define ENABLE_RGB_MATRIX_SPLASH
// #define ENABLE_RGB_MATRIX_MULTISPLASH
// #define ENABLE_RGB_MATRIX_SOLID_SPLASH
// #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
#define ENABLE_RGB_MATRIX_SPLASH
#define ENABLE_RGB_MATRIX_MULTISPLASH
#define ENABLE_RGB_MATRIX_SOLID_SPLASH
#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
/* disable debug print */
//#define NO_DEBUG

View File

@ -22,13 +22,13 @@
"processor": "atmega32u4",
"rgblight": {
"animations": {
"alternating": false,
"alternating": true,
"breathing": true,
"christmas": true,
"knight": true,
"rainbow_mood": true,
"rainbow_swirl": true,
"rgb_test": false,
"rgb_test": true,
"snake": true,
"static_gradient": true,
"twinkle": true
@ -36,7 +36,7 @@
"brightness_steps": 8,
"hue_steps": 8,
"led_count": 8,
"max_brightness": 150,
"max_brightness": 255,
"saturation_steps": 8
},
"url": "https://worklouder.cc/",

View File

@ -0,0 +1,5 @@
// Copyright 2022 QMK
// SPDX-License-Identifier: GPL-2.0-or-later
#pragma once
#undef RGBLIGHT_EFFECT_TWINKLE

View File

@ -8,25 +8,25 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_MPLY, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
RGB_TOG, XXXXXXX, XXXXXXX, TO(1)
RGB_TOG, XXXXXXX, XXXXXXX, 0x5011
),
[1] = LAYOUT(
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, TO(2)
XXXXXXX, XXXXXXX, XXXXXXX, 0x5012
),
[2] = LAYOUT(
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, TO(3)
XXXXXXX, XXXXXXX, XXXXXXX, 0x5013
),
[3] = LAYOUT(
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
USER00, USER01, USER03, USER05,
XXXXXXX, USER02, USER04, USER06,
XXXXXXX, XXXXXXX, XXXXXXX, TO(0)
XXXXXXX, XXXXXXX, XXXXXXX, 0x5010
)
};
@ -49,8 +49,6 @@ typedef union {
work_louder_config_t work_louder_config;
#define WL_LED_MAX_BRIGHT 75
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case USER09:
@ -59,11 +57,21 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
if (work_louder_config.led_level > 4) {
work_louder_config.led_level = 1;
}
work_louder_micro_led_all_set((uint8_t)(work_louder_config.led_level * WL_LED_MAX_BRIGHT / 4));
work_louder_micro_led_all_set((uint8_t)(work_louder_config.led_level * 255 / 4));
eeconfig_update_user(work_louder_config.raw);
layer_state_set_kb(layer_state);
}
break;
case 0x5000 ... 0x500F:
if (record->event.pressed) {
layer_move(keycode - 0x5000);
}
return false; break;
case 0x5010 ... 0x501F:
if (record->event.pressed) {
layer_move(keycode - 0x5010);
}
return false; break;
}
return true;
}
@ -80,87 +88,14 @@ layer_state_t layer_state_set_user(layer_state_t state) {
void eeconfig_init_user(void) {
work_louder_config.raw = 0;
work_louder_config.led_level = 1;
work_louder_micro_led_all_set((uint8_t)(work_louder_config.led_level * WL_LED_MAX_BRIGHT / 4));
eeconfig_update_user(work_louder_config.raw);
}
void keyboard_post_init_user(void) {
work_louder_config.raw = eeconfig_read_user();
work_louder_micro_led_all_set((uint8_t)(work_louder_config.led_level * WL_LED_MAX_BRIGHT / 4));
work_louder_micro_led_all_set((uint8_t)(work_louder_config.led_level * 255 / 4));
}
void suspend_wakeup_init_user(void) {
layer_state_set_user(layer_state);
}
enum via_indicator_value {
id_wl_brightness = 1,
id_wl_layer, // placeholder
};
void wl_config_set_value(uint8_t *data) {
// data = [ value_id, value_data ]
uint8_t *value_id = &(data[0]);
uint8_t *value_data = &(data[1]);
switch (*value_id) {
case id_wl_brightness:
work_louder_config.led_level = (uint8_t)*value_data;
work_louder_micro_led_all_set((uint8_t)(work_louder_config.led_level * WL_LED_MAX_BRIGHT / 4));
layer_state_set_kb(layer_state);
break;
// case id_wl_layer:
// layer_move(*value_data);
// break;
}
}
void wl_config_get_value(uint8_t *data) {
// data = [ value_id, value_data ]
uint8_t *value_id = &(data[0]);
uint8_t *value_data = &(data[1]);
switch (*value_id) {
case id_wl_brightness:
*value_data = work_louder_config.led_level;
break;
// case id_wl_layer:
// *value_data = get_highest_layer(layer_state);
// break;
}
}
void wl_config_save(void) {
eeconfig_update_user(work_louder_config.raw);
}
void via_custom_value_command_kb(uint8_t *data, uint8_t length) {
uint8_t *command_id = &(data[0]);
uint8_t *channel_id = &(data[1]);
uint8_t *value_id_and_data = &(data[2]);
if (*channel_id == id_custom_channel) {
switch (*command_id) {
case id_custom_set_value: {
wl_config_set_value(value_id_and_data);
break;
}
case id_custom_get_value: {
wl_config_get_value(value_id_and_data);
break;
}
case id_custom_save: {
wl_config_save();
break;
}
default: {
// Unhandled message.
*command_id = id_unhandled;
break;
}
}
return;
}
*command_id = id_unhandled;
}

View File

@ -41,7 +41,15 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* COL2ROW, ROW2COL */
#define DIODE_DIRECTION COL2ROW
#define USB_MAX_POWER_CONSUMPTION 100
//#define LED_NUM_LOCK_PIN B0
//#define LED_CAPS_LOCK_PIN B1
//#define LED_SCROLL_LOCK_PIN B2
//#define LED_COMPOSE_PIN B3
//#define LED_KANA_PIN B4
//#define BACKLIGHT_PIN B7
//#define BACKLIGHT_LEVELS 3
//#define BACKLIGHT_BREATHING
#define RGBLIGHT_DI_PIN C7
#define RGBLED_NUM 6
@ -58,8 +66,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGBLIGHT_EFFECT_KNIGHT
#define RGBLIGHT_EFFECT_CHRISTMAS
#define RGBLIGHT_EFFECT_STATIC_GRADIENT
#define RGBLIGHT_EFFECT_RGB_TEST
#define RGBLIGHT_EFFECT_TWINKLE
#define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_STATIC_LIGHT
#define RGBLIGHT_DEFAULT_HUE 170
@ -76,8 +84,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 120
#define RGB_MATRIX_DISABLE_KEYCODES
#define RGB_DISABLE_WHEN_USB_SUSPENDED
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
// #define RGB_MATRIX_KEYPRESSES
// RGB Matrix Animation modes. Explicitly enabled
// For full list of effects, see:
@ -115,18 +121,18 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define ENABLE_RGB_MATRIX_TYPING_HEATMAP
#define ENABLE_RGB_MATRIX_DIGITAL_RAIN
// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
// #define ENABLE_RGB_MATRIX_SPLASH
// #define ENABLE_RGB_MATRIX_MULTISPLASH
// #define ENABLE_RGB_MATRIX_SOLID_SPLASH
// #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
#define ENABLE_RGB_MATRIX_SPLASH
#define ENABLE_RGB_MATRIX_MULTISPLASH
#define ENABLE_RGB_MATRIX_SOLID_SPLASH
#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
#define DEBOUNCE 5

View File

@ -22,59 +22,11 @@
// #define RGB_DI_PIN D1
#define RGB_MATRIX_LED_COUNT 16
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 150
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 255
#define RGB_MATRIX_DISABLE_KEYCODES
#define RGB_DISABLE_WHEN_USB_SUSPENDED
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
#define RGBLIGHT_DI_PIN D2
#define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_STATIC_GRADIENT + 9
#define RGBLIGHT_DEFAULT_HUE 213
#define ENABLE_RGB_MATRIX_ALPHAS_MODS
#define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN
#define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
#define ENABLE_RGB_MATRIX_BREATHING
#define ENABLE_RGB_MATRIX_BAND_SAT
#define ENABLE_RGB_MATRIX_BAND_VAL
#define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
#define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
#define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT
#define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL
#define ENABLE_RGB_MATRIX_CYCLE_ALL
#define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
#define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN
#define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
#define ENABLE_RGB_MATRIX_CYCLE_OUT_IN
#define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
#define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL
#define ENABLE_RGB_MATRIX_CYCLE_SPIRAL
#define ENABLE_RGB_MATRIX_DUAL_BEACON
#define ENABLE_RGB_MATRIX_RAINBOW_BEACON
#define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS
#define ENABLE_RGB_MATRIX_RAINDROPS
#define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
#define ENABLE_RGB_MATRIX_HUE_BREATHING
#define ENABLE_RGB_MATRIX_HUE_PENDULUM
#define ENABLE_RGB_MATRIX_HUE_WAVE
#define ENABLE_RGB_MATRIX_PIXEL_RAIN
#define ENABLE_RGB_MATRIX_PIXEL_FLOW
#define ENABLE_RGB_MATRIX_PIXEL_FRACTAL
// enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined
#define ENABLE_RGB_MATRIX_TYPING_HEATMAP
#define ENABLE_RGB_MATRIX_DIGITAL_RAIN
// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
// #define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
// #define ENABLE_RGB_MATRIX_SPLASH
// #define ENABLE_RGB_MATRIX_MULTISPLASH
// #define ENABLE_RGB_MATRIX_SOLID_SPLASH
// #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH

View File

@ -62,7 +62,7 @@
"brightness_steps": 8,
"hue_steps": 8,
"led_count": 8,
"max_brightness": 120,
"max_brightness": 255,
"pin": "D1",
"saturation_steps": 8,
"sleep": true

View File

@ -41,8 +41,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* COL2ROW, ROW2COL */
#define DIODE_DIRECTION COL2ROW
#define USB_MAX_POWER_CONSUMPTION 100
#define RGBLIGHT_DI_PIN D2
//# define RGBLIGHT_HUE_STEP 8
//# define RGBLIGHT_SAT_STEP 8
@ -57,6 +55,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGBLIGHT_EFFECT_KNIGHT
#define RGBLIGHT_EFFECT_CHRISTMAS
#define RGBLIGHT_EFFECT_STATIC_GRADIENT
#define RGBLIGHT_EFFECT_RGB_TEST
#define RGBLIGHT_EFFECT_TWINKLE
#define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_STATIC_GRADIENT + 9
@ -74,8 +73,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 120
#define RGB_MATRIX_DISABLE_KEYCODES
#define RGB_DISABLE_WHEN_USB_SUSPENDED
// #define RGB_MATRIX_FRAMEBUFFER_EFFECTS
// #define RGB_MATRIX_KEYPRESSES
// RGB Matrix Animation modes. Explicitly enabled
// For full list of effects, see:

View File

@ -16,7 +16,12 @@
#include QMK_KEYBOARD_H
enum planck_layers { _QWERTY, _LOWER, _RAISE, _ADJUST };
enum planck_layers {
_QWERTY,
_LOWER,
_RAISE,
_ADJUST
};
enum tap_dances {
ENC_TAP,
@ -54,16 +59,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
#ifdef ENCODER_MAP_ENABLE
const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
[_QWERTY] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[_LOWER] = { ENCODER_CCW_CW(KC_PGDN, KC_PGUP) },
[_RAISE] = { ENCODER_CCW_CW(R_M_RMOD, R_M_MOD) },
[_ADJUST] = { ENCODER_CCW_CW(R_M_HUI, R_M_HUD) },
};
#endif
// clang-format on
void dance_enc_finished(tap_dance_state_t *state, void *user_data) {
if (state->count == 1) {
register_code(KC_MPLY);
@ -89,25 +84,11 @@ tap_dance_action_t tap_dance_actions[] = {
[ENC_TAP] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, dance_enc_finished, dance_enc_reset),
};
typedef union {
uint32_t raw;
struct {
uint8_t led_level : 3;
};
} work_louder_config_t;
work_louder_config_t work_louder_config;
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
if (keycode == USER09) {
preprocess_tap_dance(TD(ENC_TAP), record);
return process_tap_dance(TD(ENC_TAP), record);
} else if (keycode == USER10 && record->event.pressed) {
work_louder_config.led_level ^= true;
eeconfig_update_user(work_louder_config.raw);
layer_state_set_kb(layer_state);
}
return true;
}
@ -116,99 +97,26 @@ layer_state_t layer_state_set_user(layer_state_t state) {
writePinLow(B3);
writePinLow(B7);
if (work_louder_config.led_level) {
switch (get_highest_layer(state)) {
case 1:
writePinHigh(B2);
break;
case 2:
writePinHigh(B3);
break;
case 3:
writePinHigh(B7);
break;
}
switch (get_highest_layer(state)) {
case 1:
writePinHigh(B2);
break;
case 2:
writePinHigh(B3);
break;
case 3:
writePinHigh(B7);
break;
}
return state;
}
void eeconfig_init_user(void) {
work_louder_config.raw = 0;
work_louder_config.led_level = true;
eeconfig_update_user(work_louder_config.raw);
}
void keyboard_post_init_user(void) {
work_louder_config.raw = eeconfig_read_user();
}
enum via_indicator_value {
id_wl_brightness = 1,
id_wl_layer, // placeholder
#ifdef ENCODER_MAP_ENABLE
const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
[_QWERTY] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[_LOWER] = { ENCODER_CCW_CW(KC_PGDN, KC_PGUP) },
[_RAISE] = { ENCODER_CCW_CW(R_M_RMOD, R_M_MOD) },
[_ADJUST] = { ENCODER_CCW_CW(R_M_HUI, R_M_HUD) },
};
void wl_config_set_value(uint8_t *data) {
// data = [ value_id, value_data ]
uint8_t *value_id = &(data[0]);
uint8_t *value_data = &(data[1]);
switch (*value_id) {
case id_wl_brightness:
work_louder_config.led_level = (bool)*value_data;
layer_state_set_kb(layer_state);
break;
// case id_wl_layer:
// layer_move(*value_data);
// break;
}
}
void wl_config_get_value(uint8_t *data) {
// data = [ value_id, value_data ]
uint8_t *value_id = &(data[0]);
uint8_t *value_data = &(data[1]);
switch (*value_id) {
case id_wl_brightness:
*value_data = work_louder_config.led_level;
break;
// case id_wl_layer:
// *value_data = get_highest_layer(layer_state);
// break;
}
}
void wl_config_save(void) {
eeconfig_update_user(work_louder_config.raw);
}
void via_custom_value_command_kb(uint8_t *data, uint8_t length) {
uint8_t *command_id = &(data[0]);
uint8_t *channel_id = &(data[1]);
uint8_t *value_id_and_data = &(data[2]);
if (*channel_id == id_custom_channel) {
switch (*command_id) {
case id_custom_set_value: {
wl_config_set_value(value_id_and_data);
break;
}
case id_custom_get_value: {
wl_config_get_value(value_id_and_data);
break;
}
case id_custom_save: {
wl_config_save();
break;
}
default: {
// Unhandled message.
*command_id = id_unhandled;
break;
}
}
return;
}
*command_id = id_unhandled;
}
#endif

View File

@ -22,6 +22,9 @@ USE_ARM_CONFIG ?= no
ifeq ($(strip $(CONVERT_TO)), proton_c)
USE_ARM_CONFIG = yes
endif
ifeq ($(strip $(CTPC)), yes)
USE_ARM_CONFIG = yes
endif
ifeq ($(strip $(MCU)), STM32F303)
USE_ARM_CONFIG = yes
endif

View File

@ -751,6 +751,7 @@ def arm_processor_rules(info_data, rules):
"""
info_data['processor_type'] = 'arm'
info_data['protocol'] = 'ChibiOS'
info_data['platform_key'] = 'chibios'
if 'STM32' in info_data['processor']:
info_data['platform'] = 'STM32'
@ -758,6 +759,7 @@ def arm_processor_rules(info_data, rules):
info_data['platform'] = rules['MCU_SERIES']
elif 'ARM_ATSAM' in rules:
info_data['platform'] = 'ARM_ATSAM'
info_data['platform_key'] = 'arm_atsam'
return info_data
@ -767,6 +769,7 @@ def avr_processor_rules(info_data, rules):
"""
info_data['processor_type'] = 'avr'
info_data['platform'] = rules['ARCH'] if 'ARCH' in rules else 'unknown'
info_data['platform_key'] = 'avr'
info_data['protocol'] = 'V-USB' if info_data['processor'] in VUSB_PROCESSORS else 'LUFA'
# FIXME(fauxpark/anyone): Eventually we should detect the protocol by looking at PROTOCOL inherited from mcu_selection.mk:

View File

@ -27,6 +27,8 @@
# the respective file under `platforms/<PLATFORM>/bootloaders/custom.c` to see
# which functions may be overridden.
FIRMWARE_FORMAT?=bin
ifeq ($(strip $(BOOTLOADER)), custom)
OPT_DEFS += -DBOOTLOADER_CUSTOM
BOOTLOADER_TYPE = custom

View File

@ -37,6 +37,8 @@
# BOOTLOADER_SIZE can still be defined manually, but it's recommended
# you add any possible configuration to this list
FIRMWARE_FORMAT?=hex
ifeq ($(strip $(BOOTLOADER)), custom)
OPT_DEFS += -DBOOTLOADER_CUSTOM
BOOTLOADER_TYPE = custom

View File

@ -36,6 +36,8 @@
# the respective file under `platforms/<PLATFORM>/bootloaders/custom.c` to see
# which functions may be overridden.
FIRMWARE_FORMAT?=bin
ifeq ($(strip $(BOOTLOADER)), custom)
OPT_DEFS += -DBOOTLOADER_CUSTOM
BOOTLOADER_TYPE = custom

View File

@ -442,6 +442,9 @@ LDFLAGS += $(SHARED_LDFLAGS) $(SHARED_LDSYMBOLS) $(TOOLCHAIN_LDFLAGS) $(TOOLCHA
# Tell QMK that we are hosting it on ChibiOS.
OPT_DEFS += -DPROTOCOL_CHIBIOS
# And what flavor of MCU
OPT_DEFS += -DMCU_$(MCU_FAMILY)
# ChibiOS supports synchronization primitives like a Mutex
OPT_DEFS += -DPLATFORM_SUPPORTS_SYNCHRONIZATION

View File

@ -141,14 +141,14 @@ void matrix_scan_cmd_tab(void) {
*
* Sends 'qmk compile -kb keyboard -km keymap' command to compile firmware
* Uses 'qmk flash' and resets keyboard, if flash_bootloader set to true
* Sends CONVERT_TO and/or FORCE_LAYOUT parameters if built with those options
* Sends CTPC and/or FORCE_LAYOUT parameters if built with those options
*/
void send_make_command(bool flash_bootloader) {
#ifdef FORCE_LAYOUT // Add layout string if built with FORCE_LAYOUT
SEND_STRING("FORCE_LAYOUT=" FORCE_LAYOUT " ");
#endif
#ifdef CONVERT_TO_PROTON_C // Add CONVERT_TO if built with converter
SEND_STRING("CONVERT_TO=proton_c ");
#ifdef CONVERT_TO_PROTON_C // Add CTPC if built with CONVERT_TO_PROTON_C
SEND_STRING("CTPC=yes ");
#endif
SEND_STRING("qmk ");
if (flash_bootloader) {

View File

@ -45,7 +45,7 @@ VPATH += $(USER_PATH)/oled
# SERIAL_DRIVER = usart
# AUDIO_ENABLE = no
# LTO_ENABLE = no
# CONVERT_TO=proton_c
# CONVERT_TO_PROTON_C = yes
# so the keyboard's code doesn't add stuff we don't need.
# when we use our own oled renders.