summaryrefslogtreecommitdiff
path: root/keyboards
diff options
context:
space:
mode:
authorcoderkun <olli@coderkun.de>2016-10-02 10:04:29 +0200
committercoderkun <olli@coderkun.de>2016-10-02 10:04:29 +0200
commit8655677584483e46d9b45873aa50ec6e860486dd (patch)
tree3f1037d47607fd40be82fe9169795978f8f3551f /keyboards
parenta10e100bd5e8bad73e1b04f54639a4cec36e4b9e (diff)
parent35e6870e5c8943c044187256e01c96ef400ca067 (diff)
Merge branch 'master' into coderkun_neo2
Diffstat (limited to 'keyboards')
-rw-r--r--keyboards/alps64/Makefile69
-rw-r--r--keyboards/alps64/rules.mk66
-rw-r--r--keyboards/amj60/Makefile71
-rw-r--r--keyboards/amj60/rules.mk66
-rw-r--r--keyboards/arrow_pad/Makefile73
-rw-r--r--keyboards/arrow_pad/readme.md119
-rw-r--r--keyboards/arrow_pad/rules.mk70
-rw-r--r--keyboards/atomic/Makefile72
-rw-r--r--keyboards/atomic/keymaps/pvc/Makefile4
-rw-r--r--keyboards/atomic/keymaps/pvc/config.h11
-rw-r--r--keyboards/atomic/keymaps/pvc/keymap.c458
-rw-r--r--keyboards/atomic/readme.md7
-rw-r--r--keyboards/atomic/rules.mk69
-rw-r--r--keyboards/atreus/Makefile89
-rw-r--r--keyboards/atreus/config.h4
-rw-r--r--keyboards/atreus/keymaps/classic/keymap.c48
-rw-r--r--keyboards/atreus/keymaps/default/keymap.c22
-rw-r--r--keyboards/atreus/keymaps/erlandsona/config.h96
-rw-r--r--keyboards/atreus/keymaps/erlandsona/keymap.c61
-rw-r--r--keyboards/atreus/keymaps/jeremy/keymap.c66
-rw-r--r--keyboards/atreus/keymaps/jeremy/readme.md45
-rw-r--r--keyboards/atreus/readme.md7
-rw-r--r--keyboards/atreus/rules.mk82
-rw-r--r--keyboards/bantam44/Makefile73
-rw-r--r--keyboards/bantam44/readme.md7
-rw-r--r--keyboards/bantam44/rules.mk67
-rw-r--r--keyboards/chibios_test/Makefile11
-rw-r--r--keyboards/chibios_test/boards/GENERIC_STM32_F103/board.c98
-rw-r--r--keyboards/chibios_test/boards/GENERIC_STM32_F103/board.h332
-rw-r--r--keyboards/chibios_test/boards/GENERIC_STM32_F103/board.mk10
-rw-r--r--keyboards/chibios_test/ld/MKL26Z64.ld210
-rw-r--r--keyboards/chibios_test/ld/STM32F103x8_stm32duino_bootloader.ld176
-rw-r--r--keyboards/chibios_test/rules.mk8
-rw-r--r--keyboards/chibios_test/stm32_f072_onekey/Makefile42
-rw-r--r--keyboards/chibios_test/stm32_f072_onekey/mcuconf.h342
-rw-r--r--keyboards/chibios_test/stm32_f072_onekey/rules.mk41
-rw-r--r--keyboards/chibios_test/stm32_f103_onekey/Makefile53
-rw-r--r--keyboards/chibios_test/stm32_f103_onekey/mcuconf.h418
-rw-r--r--keyboards/chibios_test/stm32_f103_onekey/rules.mk52
-rw-r--r--keyboards/chibios_test/teensy_lc_onekey/Makefile48
-rw-r--r--keyboards/chibios_test/teensy_lc_onekey/chconf.h1048
-rw-r--r--keyboards/chibios_test/teensy_lc_onekey/halconf.h374
-rw-r--r--keyboards/chibios_test/teensy_lc_onekey/mcuconf.h110
-rw-r--r--keyboards/chibios_test/teensy_lc_onekey/rules.mk49
-rw-r--r--keyboards/clueboard/Makefile108
-rw-r--r--keyboards/clueboard/readme.md26
-rw-r--r--keyboards/clueboard/rev1/Makefile6
-rw-r--r--keyboards/clueboard/rev1/rules.mk5
-rw-r--r--keyboards/clueboard/rev2/Makefile6
-rw-r--r--keyboards/clueboard/rev2/rules.mk5
-rw-r--r--keyboards/clueboard/rules.mk103
-rw-r--r--keyboards/cluecard/Makefile77
-rw-r--r--keyboards/cluecard/readme.md6
-rw-r--r--keyboards/cluecard/rules.mk70
-rw-r--r--keyboards/cluepad/Makefile71
-rw-r--r--keyboards/cluepad/rules.mk65
-rw-r--r--keyboards/ergodox/Makefile33
-rw-r--r--keyboards/ergodox/ergodox.c24
-rw-r--r--keyboards/ergodox/ez/Makefile77
-rw-r--r--keyboards/ergodox/ez/ez.h41
-rw-r--r--keyboards/ergodox/ez/keymaps/profet_80/ergodox80.pngbin0 -> 20663 bytes
-rw-r--r--keyboards/ergodox/ez/keymaps/profet_80/keymap.c183
-rw-r--r--keyboards/ergodox/ez/keymaps/profet_80/readme.md10
-rw-r--r--keyboards/ergodox/ez/rules.mk78
-rw-r--r--keyboards/ergodox/infinity/Makefile78
-rw-r--r--keyboards/ergodox/infinity/rules.mk77
-rw-r--r--keyboards/ergodox/keymaps/absenth/absenth_highres.pngbin0 -> 1463041 bytes
-rw-r--r--keyboards/ergodox/keymaps/absenth/keymap.c183
-rw-r--r--keyboards/ergodox/keymaps/absenth/readme.md11
-rw-r--r--keyboards/ergodox/keymaps/algernon/Makefile11
-rw-r--r--keyboards/ergodox/keymaps/algernon/images/adore-layer.pngbin93748 -> 97225 bytes
-rw-r--r--keyboards/ergodox/keymaps/algernon/images/base-layer.pngbin95222 -> 102142 bytes
-rw-r--r--keyboards/ergodox/keymaps/algernon/images/heatmap.pngbin137912 -> 139351 bytes
-rw-r--r--keyboards/ergodox/keymaps/algernon/keymap.c709
-rw-r--r--keyboards/ergodox/keymaps/algernon/readme.md141
-rw-r--r--keyboards/ergodox/keymaps/algernon/tools/heatmap-layout.ADORE.json (renamed from keyboards/ergodox/keymaps/algernon/tools/heatmap-adore-layout.json)208
-rw-r--r--keyboards/ergodox/keymaps/algernon/tools/heatmap-layout.Dvorak.json (renamed from keyboards/ergodox/keymaps/algernon/tools/heatmap-base-layout.json)156
-rwxr-xr-xkeyboards/ergodox/keymaps/algernon/tools/hid-commands61
-rwxr-xr-xkeyboards/ergodox/keymaps/algernon/tools/layer-notify12
-rwxr-xr-xkeyboards/ergodox/keymaps/algernon/tools/log-to-heatmap.py448
-rwxr-xr-xkeyboards/ergodox/keymaps/algernon/tools/max-focused5
-rwxr-xr-xkeyboards/ergodox/keymaps/algernon/tools/text-to-log.py107
-rw-r--r--keyboards/ergodox/keymaps/bepo_csa/keymap.c527
-rw-r--r--keyboards/ergodox/keymaps/bepo_csa/readme.md162
-rw-r--r--keyboards/ergodox/keymaps/default/keymap.c12
-rw-r--r--keyboards/ergodox/keymaps/default/readme.md2
-rw-r--r--keyboards/ergodox/keymaps/kastyle/keymap.c77
-rw-r--r--keyboards/ergodox/keymaps/kastyle/readme.md14
-rw-r--r--keyboards/ergodox/keymaps/mclennon_osx/README.md5
-rw-r--r--keyboards/ergodox/keymaps/mclennon_osx/keymap.c144
-rw-r--r--keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keyboard-layout.pngbin0 -> 140077 bytes
-rw-r--r--keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keymap.c180
-rw-r--r--keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/readme.md30
-rw-r--r--keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keyboard-layout.pngbin0 -> 97519 bytes
-rw-r--r--keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keymap.c180
-rw-r--r--keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/readme.md30
-rw-r--r--keyboards/ergodox/keymaps/romanzolotarev-norman-osx/keymap.c30
-rw-r--r--keyboards/ergodox/keymaps/romanzolotarev-norman-osx/readme.md39
-rw-r--r--keyboards/ergodox/keymaps/yoruian/90-ergodox-yoruian.conf6
-rw-r--r--keyboards/ergodox/keymaps/yoruian/Makefile13
-rw-r--r--keyboards/ergodox/keymaps/yoruian/README102
-rw-r--r--keyboards/ergodox/keymaps/yoruian/ergodox_yoruian34
-rw-r--r--keyboards/ergodox/keymaps/yoruian/keymap.c61
-rw-r--r--keyboards/ergodox/keymaps/yoruian/yoruian.h61
-rw-r--r--keyboards/ergodox/keymaps/zweihander-osx/Makefile (renamed from keyboards/ergodox/keymaps/zweihander-osx/makefile.mk)0
-rw-r--r--keyboards/ergodox/keymaps/zweihander-osx/keymap.c14
-rw-r--r--keyboards/ergodox/keymaps/zweihander-osx/readme.markdown8
-rw-r--r--keyboards/ergodox/readme.md165
-rw-r--r--keyboards/ergodox/rules.mk29
-rw-r--r--keyboards/gh60/Makefile77
-rw-r--r--keyboards/gh60/config.h322
-rw-r--r--keyboards/gh60/gh60.c50
-rw-r--r--keyboards/gh60/gh60.h148
-rw-r--r--keyboards/gh60/keymaps/robotmaxtron/Makefile224
-rw-r--r--keyboards/gh60/keymaps/robotmaxtron/config.h380
-rw-r--r--keyboards/gh60/pinout.txt34
-rw-r--r--keyboards/gh60/readme.md122
-rw-r--r--keyboards/gh60/rules.mk66
-rw-r--r--keyboards/handwired/CMD60/Makefile74
-rw-r--r--keyboards/handwired/CMD60/rules.mk73
-rw-r--r--keyboards/handwired/Makefile2
-rw-r--r--keyboards/handwired/fivethirteen/Makefile74
-rw-r--r--keyboards/handwired/fivethirteen/rules.mk73
-rw-r--r--keyboards/handwired/minorca/Makefile70
-rw-r--r--keyboards/handwired/minorca/rules.mk67
-rw-r--r--keyboards/handwired/onekey/Makefile64
-rw-r--r--keyboards/handwired/onekey/rules.mk65
-rw-r--r--keyboards/handwired/retro_refit/Makefile3
-rw-r--r--keyboards/handwired/retro_refit/config.h (renamed from keyboards/retro_refit/config.h)0
-rw-r--r--keyboards/handwired/retro_refit/keymaps/default/keymap.c (renamed from keyboards/retro_refit/keymaps/default/keymap.c)0
-rw-r--r--keyboards/handwired/retro_refit/readme.md60
-rw-r--r--keyboards/handwired/retro_refit/retro_refit.c (renamed from keyboards/retro_refit/retro_refit.c)0
-rw-r--r--keyboards/handwired/retro_refit/retro_refit.h (renamed from keyboards/retro_refit/retro_refit.h)0
-rw-r--r--keyboards/handwired/retro_refit/rules.mk (renamed from keyboards/retro_refit/Makefile)6
-rw-r--r--keyboards/handwired/rules.mk0
-rw-r--r--keyboards/handwired/traveller/Makefile90
-rw-r--r--keyboards/handwired/traveller/rules.mk89
-rw-r--r--keyboards/hhkb/Makefile91
-rw-r--r--keyboards/hhkb/keymaps/dbroqua/keymap.c70
-rw-r--r--keyboards/hhkb/keymaps/dbroqua/readme.md9
-rw-r--r--keyboards/hhkb/keymaps/jp/Makefile2
-rw-r--r--keyboards/hhkb/keymaps/rdg_jp/Makefile2
-rw-r--r--keyboards/hhkb/readme.md8
-rw-r--r--keyboards/hhkb/rules.mk80
-rw-r--r--keyboards/infinity60/MEMO.txt (renamed from keyboards/infinity_chibios/MEMO.txt)0
-rw-r--r--keyboards/infinity60/Makefile3
-rw-r--r--keyboards/infinity60/bootloader_defs.h (renamed from keyboards/infinity_chibios/bootloader_defs.h)0
-rw-r--r--keyboards/infinity60/chconf.h (renamed from keyboards/infinity_chibios/chconf.h)1048
-rw-r--r--keyboards/infinity60/config.h (renamed from keyboards/infinity_chibios/config.h)9
-rw-r--r--keyboards/infinity60/halconf.h (renamed from keyboards/infinity_chibios/halconf.h)706
-rw-r--r--keyboards/infinity60/infinity60.c (renamed from keyboards/infinity_chibios/infinity_chibios.c)2
-rw-r--r--keyboards/infinity60/infinity60.h (renamed from keyboards/infinity_chibios/infinity_chibios.h)0
-rw-r--r--keyboards/infinity60/keymaps/default/keymap.c (renamed from keyboards/infinity_chibios/keymaps/default/keymap.c)2
-rwxr-xr-xkeyboards/infinity60/keymaps/depariel/keymap.c (renamed from keyboards/infinity_chibios/keymaps/depariel/keymap.c)2
-rw-r--r--keyboards/infinity60/keymaps/hasu/keymap.c (renamed from keyboards/infinity_chibios/keymaps/hasu/keymap.c)2
-rw-r--r--keyboards/infinity60/led.c (renamed from keyboards/infinity_chibios/led.c)0
-rw-r--r--keyboards/infinity60/matrix.c (renamed from keyboards/infinity_chibios/matrix.c)0
-rw-r--r--keyboards/infinity60/mcuconf.h (renamed from keyboards/infinity_chibios/mcuconf.h)110
-rw-r--r--keyboards/infinity60/readme.md29
-rw-r--r--keyboards/infinity60/rules.mk (renamed from keyboards/infinity_chibios/Makefile)6
-rw-r--r--keyboards/jd40/Makefile74
-rw-r--r--keyboards/jd40/config.h79
-rw-r--r--keyboards/jd40/jd40.c26
-rw-r--r--keyboards/jd40/jd40.h45
-rw-r--r--keyboards/jd40/keymaps/default/keymap.c164
-rw-r--r--keyboards/jd40/readme.md17
-rw-r--r--keyboards/jd40/rules.mk69
-rw-r--r--keyboards/jd45/Makefile72
-rw-r--r--keyboards/jd45/rules.mk67
-rw-r--r--keyboards/kc60/Makefile76
-rw-r--r--keyboards/kc60/config.h2
-rw-r--r--keyboards/kc60/keymaps/dbroqua/keymap.c10
-rw-r--r--keyboards/kc60/keymaps/workman-dead/keymap.c8
-rw-r--r--keyboards/kc60/keymaps/workman-dead/readme.md (renamed from keyboards/kc60/keymaps/workman-dead/README.md)0
-rw-r--r--keyboards/kc60/readme.md12
-rw-r--r--keyboards/kc60/rules.mk71
-rw-r--r--keyboards/kinesis/Makefile80
-rw-r--r--keyboards/kinesis/readme.md6
-rw-r--r--keyboards/kinesis/rules.mk73
-rw-r--r--keyboards/kitten_paw/Makefile76
-rw-r--r--keyboards/kitten_paw/rules.mk72
-rw-r--r--keyboards/lets_split/Makefile77
-rw-r--r--keyboards/lets_split/config.h7
-rw-r--r--keyboards/lets_split/i2c.c3
-rw-r--r--keyboards/lets_split/keymaps/i2c/config.h102
-rw-r--r--keyboards/lets_split/keymaps/i2c/keymap.c214
-rw-r--r--keyboards/lets_split/keymaps/serial/config.h102
-rw-r--r--keyboards/lets_split/keymaps/serial/keymap.c214
-rw-r--r--keyboards/lets_split/lets_split.c8
-rw-r--r--keyboards/lets_split/matrix.c23
-rw-r--r--keyboards/lets_split/rules.mk74
-rw-r--r--keyboards/lets_split/serial.c5
-rw-r--r--keyboards/lets_split/split_util.c8
-rw-r--r--keyboards/phantom/Makefile75
-rw-r--r--keyboards/phantom/rules.mk69
-rw-r--r--keyboards/planck/Makefile71
-rw-r--r--keyboards/planck/keymaps/bone2planck/config.h7
-rw-r--r--keyboards/planck/keymaps/bone2planck/keymap.c51
-rw-r--r--keyboards/planck/keymaps/bone2planck/readme.md8
-rw-r--r--keyboards/planck/keymaps/callum/keymap.c192
-rw-r--r--keyboards/planck/keymaps/callum/readme.md111
-rw-r--r--keyboards/planck/keymaps/cbbrowne/config.h8
-rw-r--r--keyboards/planck/keymaps/cbbrowne/keymap.c107
-rw-r--r--keyboards/planck/keymaps/cbbrowne/readme.md67
-rw-r--r--keyboards/planck/keymaps/impossible/Makefile25
-rw-r--r--keyboards/planck/keymaps/impossible/keymap.c242
-rw-r--r--keyboards/planck/keymaps/impossible/readme.md73
-rw-r--r--keyboards/planck/keymaps/jhenahan/Makefile25
-rw-r--r--keyboards/planck/keymaps/jhenahan/config.h9
-rw-r--r--keyboards/planck/keymaps/jhenahan/keymap.c314
-rw-r--r--keyboards/planck/keymaps/jhenahan/readme.md41
-rw-r--r--keyboards/planck/keymaps/pvc/Makefile6
-rw-r--r--keyboards/planck/keymaps/pvc/config.h21
-rw-r--r--keyboards/planck/keymaps/pvc/keymap.c509
-rw-r--r--keyboards/planck/keymaps/sgoodwin/Makefile25
-rw-r--r--keyboards/planck/keymaps/sgoodwin/keymap.c233
-rw-r--r--keyboards/planck/keymaps/sgoodwin/readme.md10
-rw-r--r--keyboards/planck/keymaps/tong92/Makefile62
-rw-r--r--keyboards/planck/keymaps/tong92/keymap.c146
-rw-r--r--keyboards/planck/keymaps/tong92/readme.md66
-rw-r--r--keyboards/planck/readme.md8
-rw-r--r--keyboards/planck/rev3/Makefile4
-rw-r--r--keyboards/planck/rev3/rules.mk5
-rw-r--r--keyboards/planck/rev4/Makefile4
-rw-r--r--keyboards/planck/rev4/rules.mk5
-rw-r--r--keyboards/planck/rules.mk67
-rw-r--r--keyboards/preonic/Makefile72
-rw-r--r--keyboards/preonic/readme.md8
-rw-r--r--keyboards/preonic/rules.mk69
-rw-r--r--keyboards/readme.md47
-rw-r--r--keyboards/retro_refit/readme.md24
-rw-r--r--keyboards/s60-x/Makefile76
-rw-r--r--keyboards/s60-x/readme.md4
-rw-r--r--keyboards/s60-x/rules.mk69
-rw-r--r--keyboards/satan/Makefile71
-rw-r--r--keyboards/satan/rules.mk66
-rw-r--r--keyboards/sixkeyboard/Makefile76
-rw-r--r--keyboards/sixkeyboard/rules.mk70
-rw-r--r--keyboards/tada68/Makefile3
-rw-r--r--keyboards/tada68/config.h97
-rw-r--r--keyboards/tada68/keymaps/default/Makefile21
-rw-r--r--keyboards/tada68/keymaps/default/keymap.c98
-rw-r--r--keyboards/tada68/keymaps/default/readme.md1
-rw-r--r--keyboards/tada68/readme.md4
-rw-r--r--keyboards/tada68/rules.mk66
-rw-r--r--keyboards/tada68/tada68.c30
-rw-r--r--keyboards/tada68/tada68.h43
-rw-r--r--keyboards/tv44/Makefile76
-rw-r--r--keyboards/tv44/keymaps/jeebak/Makefile21
-rw-r--r--keyboards/tv44/keymaps/jeebak/config.h21
-rw-r--r--keyboards/tv44/keymaps/jeebak/keymap.c425
-rw-r--r--keyboards/tv44/keymaps/jeebak/readme.md129
-rw-r--r--keyboards/tv44/readme.md6
-rw-r--r--keyboards/tv44/rules.mk69
-rw-r--r--keyboards/vision_division/Makefile77
-rw-r--r--keyboards/vision_division/config.h19
-rw-r--r--keyboards/vision_division/keymaps/default/Makefile26
-rw-r--r--keyboards/vision_division/keymaps/default/config.h46
-rw-r--r--keyboards/vision_division/keymaps/default/keymap.c940
-rw-r--r--keyboards/vision_division/matrix_types.h33
-rw-r--r--keyboards/vision_division/readme.md6
-rw-r--r--keyboards/vision_division/rules.mk70
-rw-r--r--keyboards/vision_division/vision_division.c40
263 files changed, 14564 insertions, 7841 deletions
diff --git a/keyboards/alps64/Makefile b/keyboards/alps64/Makefile
index d8325e6c89..4e2a6f00fd 100644
--- a/keyboards/alps64/Makefile
+++ b/keyboards/alps64/Makefile
@@ -1,70 +1,3 @@
-
-
-# Target file name (without extension).
-
-# project specific files
-SRC = led.c
-
-# MCU name
-MCU = atmega32u2
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-#SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
-#NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/alps64/rules.mk b/keyboards/alps64/rules.mk
new file mode 100644
index 0000000000..c326d3e26c
--- /dev/null
+++ b/keyboards/alps64/rules.mk
@@ -0,0 +1,66 @@
+
+
+# Target file name (without extension).
+
+# project specific files
+SRC = led.c
+
+# MCU name
+MCU = atmega32u2
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+#SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+#NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA \ No newline at end of file
diff --git a/keyboards/amj60/Makefile b/keyboards/amj60/Makefile
index 1f695aa4d8..4e2a6f00fd 100644
--- a/keyboards/amj60/Makefile
+++ b/keyboards/amj60/Makefile
@@ -1,70 +1,3 @@
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-RGBLIGHT_ENABLE ?= yes # Enable keyboard underlight functionality (+4870)
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality (+1150)
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/amj60/rules.mk b/keyboards/amj60/rules.mk
new file mode 100644
index 0000000000..18403ac328
--- /dev/null
+++ b/keyboards/amj60/rules.mk
@@ -0,0 +1,66 @@
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+RGBLIGHT_ENABLE ?= yes # Enable keyboard underlight functionality (+4870)
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality (+1150)
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
diff --git a/keyboards/arrow_pad/Makefile b/keyboards/arrow_pad/Makefile
index 09fcf3e7a0..4e2a6f00fd 100644
--- a/keyboards/arrow_pad/Makefile
+++ b/keyboards/arrow_pad/Makefile
@@ -1,74 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=512
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= yes # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/arrow_pad/readme.md b/keyboards/arrow_pad/readme.md
index 5aa44cce54..d0d172272e 100644
--- a/keyboards/arrow_pad/readme.md
+++ b/keyboards/arrow_pad/readme.md
@@ -1,24 +1,133 @@
arrow_pad keyboard firmware
======================
+## Keyboard Info
+
+The ArrowPad is a wired conversion that can be made to any stand-alone keypad. It uses two main layers - a standard numpad, and a more advanced arrow cluster navigator.
+
+The first 24-key ArrowPad was handwired, but the PCB was wired as listed below.
+
+```
+<Chip Ref Des> pin <Pin #>
+<Keycap Name> (Silkscreen Name if different) - <Switch Pin #>
+
+
+Note:
+U2 pin 2 is the Num Lock LED and is active low.
+
+U2 pin 1
+Clear (Num Lock) - 1
+Enter - 2
+Esc (ESC) - 2
+
+
+U2 pin 3
+- - 1
+
+U2 pin 4
+7 - 2
+8 - 2
+9 - 2
+
+U2 pin 5
+* - 2
+Delete (BACK SPACE) - 2
+
+U2 pin 6
+1 - 2
+0 - 2
+. - 2
+, - 2
+
+U2 pin 7
+4 - 2
+5 - 2
+6 - 2
+
+U2 pin 8
+Tab - 2
+= (/) - 2
+
+U2 pin 13
+Delete (BACK SPACE) - 1
+9 - 1
+6 - 1
+3 - 1
+. - 1
+
+U2 pin 14
+Tab - 1
+8 - 1
+5 - 1
+2 - 1
+0 - 1
+
+U2 pin 15
+Esc (ESC) - 1
+= (/) - 1
+/ (*) - 1
+7 - 1
+4 - 1
+1 - 1
++ - 1
+
+U2 pin 16
+Enter - 1
+* (<--) - 1
+, - 1
+
+U2 pin 17
+Fn (#NAME?) - 1
+- - 2
+Clear (Num Lock) - 2
+
+U2 pin 18
+Fn (#NAME?) - 2
+* (<--) - 2
++ - 2
+3 - 2
+2 - 2
+```
+
+More info can be found on [GeekHack](https://geekhack.org/index.php?topic=73632.msg1802497#msg1802497)
+
+The second ArrowPad was a conversion from a 21-key Genovation keypad. It used a 2 row x 11 column matrix.
+
+```
+#define KEYMAP( \
+ KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
+ KM_NUM, KM_FSL, KM_AST, KM_MIN, \
+ KM___7, KM___8, KM___9, ___PLS, \
+ KM___4, KM___5, KM___6, KM_PLS, \
+ KM___1, KM___2, KM___3, ___ENT, \
+ KM___0, _____0, KM_DOT, KM_ENT \
+) { \
+ { KM_ESC, KM_TAB, KM_BSL, KM_ARR, KM___7, KM___8, KM___9, KM_PLS, KM___1, KM___2, KM___3, }, \
+ { KM_NUM, KM_FSL, KM_AST, KM_MIN, KM___4, KM___5, KM___6, KM_ENT, KC_NO, KM___0, KM_DOT, }, \
+}
+```
+
+
## Quantum MK Firmware
For the full Quantum feature list, see [the parent readme.md](/readme.md).
## Building
-Download or clone the whole firmware and navigate to the keyboards/arrow_pad folder. Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Teensy Loader to program your .hex file.
+Download or clone the whole firmware and navigate to the keyboards/arrow_pad folder. Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Teensy Loader to program your .hex file.
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|pad_21|pad_24|<name>]
```
-Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder. \ No newline at end of file
+
+Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
diff --git a/keyboards/arrow_pad/rules.mk b/keyboards/arrow_pad/rules.mk
new file mode 100644
index 0000000000..3dca9b6ea7
--- /dev/null
+++ b/keyboards/arrow_pad/rules.mk
@@ -0,0 +1,70 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=512
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= yes # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6 \ No newline at end of file
diff --git a/keyboards/atomic/Makefile b/keyboards/atomic/Makefile
index 08e9205cbf..4e2a6f00fd 100644
--- a/keyboards/atomic/Makefile
+++ b/keyboards/atomic/Makefile
@@ -1,73 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-# Build Options
-# change to "no" to disable the options, or define them in the Makefile in
-# the appropriate keymap folder that will get included automatically
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no # Audio output on port C6
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
-
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/atomic/keymaps/pvc/Makefile b/keyboards/atomic/keymaps/pvc/Makefile
index 278407e6c9..c7c04485fc 100644
--- a/keyboards/atomic/keymaps/pvc/Makefile
+++ b/keyboards/atomic/keymaps/pvc/Makefile
@@ -1,7 +1,7 @@
-BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
-CONSOLE_ENABLE = no # Console for debug(+400)
+CONSOLE_ENABLE = yes # Console for debug(+400)
COMMAND_ENABLE = yes # Commands for debug and configuration
NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
diff --git a/keyboards/atomic/keymaps/pvc/config.h b/keyboards/atomic/keymaps/pvc/config.h
index 70353323b6..18a7253f2e 100644
--- a/keyboards/atomic/keymaps/pvc/config.h
+++ b/keyboards/atomic/keymaps/pvc/config.h
@@ -150,10 +150,17 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/* disable debug print */
-//#define NO_DEBUG
+#ifndef NO_DEBUG
+# define NO_DEBUG
+#endif
/* disable print */
-//#define NO_PRINT
+// #ifndef NO_PRINT
+// # define NO_PRINT
+// #endif
+
+/* Only print user print statements */
+#define USER_PRINT
/* disable action features */
//#define NO_ACTION_LAYER
diff --git a/keyboards/atomic/keymaps/pvc/keymap.c b/keyboards/atomic/keymaps/pvc/keymap.c
index b02e89d2c7..d10bfe3bfc 100644
--- a/keyboards/atomic/keymaps/pvc/keymap.c
+++ b/keyboards/atomic/keymaps/pvc/keymap.c
@@ -2,48 +2,59 @@
#include "action_layer.h"
#include "eeconfig.h"
#include "led.h"
+#include "mousekey.h"
#ifdef AUDIO_ENABLE
#include "audio.h"
#include "song_list.h"
#endif
-#define LAYER_QWERTY 0
-#define LAYER_COLEMAK 1
-#define LAYER_DVORAK 2
-#define LAYER_UPPER 3
-#define LAYER_LOWER 4
-#define LAYER_FUNCTION 5
-#define LAYER_MOUSE 6
-#define LAYER_ADJUST 7
-
-#define MACRO_QWERTY 0
-#define MACRO_COLEMAK 1
-#define MACRO_DVORAK 2
-#define MACRO_UPPER 3
-#define MACRO_LOWER 4
-#define MACRO_FUNCTION 5
-#define MACRO_MOUSE 6
-#define MACRO_TIMBRE_1 7
-#define MACRO_TIMBRE_2 8
-#define MACRO_TIMBRE_3 9
-#define MACRO_TIMBRE_4 10
-#define MACRO_TEMPO_U 11
-#define MACRO_TEMPO_D 12
-#define MACRO_TONE_DEFAULT 13
-#define MACRO_MUSIC_TOGGLE 14
-#define MACRO_AUDIO_TOGGLE 16
-#define MACRO_INC_VOICE 18
-#define MACRO_DEC_VOICE 19
-#define MACRO_BACKLIGHT 20
-#define MACRO_BREATH_TOGGLE 21
-#define MACRO_BREATH_SPEED_INC 23
-#define MACRO_BREATH_SPEED_DEC 24
-#define MACRO_BREATH_DEFAULT 25
+enum keyboard_layers {
+ LAYER_QWERTY = 0,
+ LAYER_UPPER,
+ LAYER_LOWER,
+ LAYER_FUNCTION,
+ LAYER_MOUSE,
+ LAYER_ADJUST,
+};
+enum keyboard_macros {
+ MACRO_QWERTY = 0,
+ MACRO_UPPER,
+ MACRO_LOWER,
+ MACRO_FUNCTION,
+ MACRO_MOUSE,
+ MACRO_TIMBRE_1,
+ MACRO_TIMBRE_2,
+ MACRO_TIMBRE_3,
+ MACRO_TIMBRE_4,
+ MACRO_TEMPO_U,
+ MACRO_TEMPO_D,
+ MACRO_TONE_DEFAULT,
+ MACRO_MUSIC_TOGGLE,
+ MACRO_AUDIO_TOGGLE,
+ MACRO_INC_VOICE,
+ MACRO_DEC_VOICE,
+ MACRO_BACKLIGHT,
+ MACRO_BREATH_TOGGLE,
+ MACRO_BREATH_SPEED_INC,
+ MACRO_BREATH_SPEED_DEC,
+ MACRO_BREATH_DEFAULT,
+ MACRO_MOUSE_MOVE_UL,
+ MACRO_MOUSE_MOVE_UR,
+ MACRO_MOUSE_MOVE_DL,
+ MACRO_MOUSE_MOVE_DR,
+ MACRO_HELP_1,
+ MACRO_HELP_2,
+ MACRO_HELP_3,
+ MACRO_HELP_4,
+ MACRO_HELP_5,
+ MACRO_HELP_6,
+ MACRO_HELP_7,
+ MACRO_HELP_8,
+ MACRO_HELP_9,
+};
#define M_QWRTY M(MACRO_QWERTY)
-#define M_COLMK M(MACRO_COLEMAK)
-#define M_DVORK M(MACRO_DVORAK)
#define M_UPPER M(MACRO_UPPER)
#define M_LOWER M(MACRO_LOWER)
#define M_FUNCT M(MACRO_FUNCTION)
@@ -60,6 +71,19 @@
#define M_BSPDU M(MACRO_BREATH_SPEED_INC)
#define M_BSPDD M(MACRO_BREATH_SPEED_DEC)
#define M_BDFLT M(MACRO_BREATH_DEFAULT)
+#define M_MS_UL M(MACRO_MOUSE_MOVE_UL)
+#define M_MS_UR M(MACRO_MOUSE_MOVE_UR)
+#define M_MS_DL M(MACRO_MOUSE_MOVE_DL)
+#define M_MS_DR M(MACRO_MOUSE_MOVE_DR)
+#define M_HELP1 M(MACRO_HELP_1)
+#define M_HELP2 M(MACRO_HELP_2)
+#define M_HELP3 M(MACRO_HELP_3)
+#define M_HELP4 M(MACRO_HELP_4)
+#define M_HELP5 M(MACRO_HELP_5)
+#define M_HELP6 M(MACRO_HELP_6)
+#define M_HELP7 M(MACRO_HELP_7)
+#define M_HELP8 M(MACRO_HELP_8)
+#define M_HELP9 M(MACRO_HELP_9)
#define VC_UP M(MACRO_INC_VOICE)
@@ -77,6 +101,7 @@
#define SC_ACLS LALT(KC_F4)
#define SC_CCLS LCTL(KC_F4)
+#define TG_NKRO MAGIC_TOGGLE_NKRO
#define OS_SHFT KC_FN0
#define _______ KC_TRNS
@@ -86,169 +111,126 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
-/* QWERTY
- * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
- * | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | XXXXXX . BACKSP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | TAB | Q | W | E | R | T | Y | U | I | O | P | [ | ] | \ | DEL |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
- * | CAPS | A | S | D | F | G | H | J | K | L | ; | ' | XXXXXX . ENTER | PG UP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
- * | LSHIFT | Z | X | C | V | B | N | M | , | . | / | XXXXXX . RSHIFT | UP | PG DN |
- * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
- * | LCTRL | LWIN | FN | LALT | UPPER | XXXXXX . SPACE | LOWER | SHIFT | RALT | APP | RCTRL | LEFT | DOWN | RIGHT |
- * '--------------------------------------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_QWERTY] = { // QWERTY
- { KC_ESC, 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_BSPC },
- { 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_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, KC_ENT, KC_PGUP },
- { 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_RSFT, KC_UP, KC_PGDN },
- { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT },
- },
-
- /* COLEMAK
- * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
- * | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | XXXXXX . BACKSP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | TAB | Q | W | F | P | G | J | L | U | Y | ; | [ | ] | \ | DEL |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
- * | BACKSP | A | R | S | T | D | H | N | E | I | O | ' | XXXXXX . ENTER | PG UP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
- * | LSHIFT | Z | X | C | V | B | K | M | , | . | / | XXXXXX . RSHIFT | UP | PG DN |
- * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
- * | LCTRL | LWIN | FN | LALT | UPPER | XXXXXX . SPACE | LOWER | SHIFT | RALT | APP | RCTRL | LEFT | DOWN | RIGHT |
- * '--------------------------------------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_COLEMAK] = { // COLEMAK
- { KC_ESC, 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_BSPC },
- { KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL },
- { KC_BSPC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT, KC_ENT, KC_ENT, KC_PGUP },
- { KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_RSFT, KC_UP, KC_PGDN },
- { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT },
+/* LAYER = LAYER_QWERTY
+ .--------------------------------------------------------------------------------------------------------------------------------------.
+ | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | BACKSP . BACKSP |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | TAB | Q | W | E | R | T | Y | U | I | O | P | [ | ] | \ | DEL |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | CAP LK | A | S | D | F | G | H | J | K | L | ; | ' | ENTER . ENTER | PG UP |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | LSHIFT | Z | X | C | V | B | N | M | , | . | / | RSHIFT . RSHIFT | UP | PG DN |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | LCTRL | LWIN | FN | LALT | UPPER | SPACE . SPACE | LOWER | OSHIFT | RALT | APP | RCTRL | LEFT | DOWN | RIGHT |
+ '--------------------------------------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_QWERTY] = {
+ { KC_ESC , 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_BSPC },
+ { 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_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 , KC_ENT , KC_PGUP },
+ { 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_RSFT, KC_UP , KC_PGDN },
+ { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC , KC_SPC , M_LOWER, OS_SHFT, KC_RALT, KC_APP , KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT }
},
-
-/* DVORAK
- * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
- * | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | [ | ] | XXXXXX . BACKSP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | TAB | ' | , | . | P | Y | F | G | C | R | L | / | = | \ | DEL |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
- * | CAPS | A | O | E | U | I | D | H | T | N | S | - | XXXXXX . ENTER | PG UP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
- * | LSHIFT | ; | Q | J | K | X | B | M | W | V | Z | XXXXXX . RSHIFT | UP | PG DN |
- * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
- * | LCTRL | LWIN | FN | LALT | UPPER | XXXXXX . SPACE | LOWER | SHIFT | RALT | APP | RCTRL | LEFT | DOWN | RIGHT |
- * '--------------------------------------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_DVORAK] = { // DVORAK
- { KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_LBRC, KC_RBRC, KC_BSPC, KC_BSPC },
- { KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLSH, KC_EQL, KC_BSLS, KC_DEL },
- { KC_CAPS, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_MINS, KC_ENT, KC_ENT, KC_PGUP },
- { KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_RSFT, KC_RSFT, KC_UP, KC_PGDN },
- { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT },
- },
-
-/* UPPER
- * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
- * | PRINT | BR TOG | BR SP+ | BR SP- | BR RST | XXXXXX | XXXXXX | NUM LK | / | * | | NUM LK | SCR LK | XXXXXX . PAUSE |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | | F1 | F2 | F3 | F4 | | | 7 | 8 | 9 | - | | | | INS |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
- * | CAP LK | F5 | F6 | F7 | F8 | | | 4 | 5 | 6 | + | | XXXXXX . | HOME |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
- * | | F9 | F10 | F11 | F12 | | | 1 | 2 | 3 | ENTER | XXXXXX . | | END |
- * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
- * | | | | | | 0 | | RALT | . | ENTER | | | | |
- * '--------------------------------------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_UPPER] = { // UPPER
- { KC_PSCR, M_BRTOG, M_BSPDU, M_BSPDD, M_BDFLT, XXXXXXX, XXXXXXX, KC_NLCK, KC_PSLS, KC_PAST, XXXXXXX, XXXXXXX, KC_SLCK, KC_PAUS, KC_PAUS },
- { _______, KC_F1, KC_F2, KC_F3, KC_F4, XXXXXXX, XXXXXXX, KC_KP_7, KC_KP_8, KC_KP_9, KC_PMNS, _______, _______, _______, KC_INS },
- { KC_CAPS, KC_F5, KC_F6, KC_F7, KC_F8, XXXXXXX, XXXXXXX, KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, _______, ________________, KC_HOME },
- { _______, KC_F9, KC_F10, KC_F11, KC_F12, XXXXXXX, XXXXXXX, KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, ________________, _______, KC_END },
- { _______, _______, _______, _______, _______, KC_KP_0, KC_KP_0, _______, KC_RALT, KC_PDOT, KC_PENT, _______, _______, _______, _______ },
- },
-
-/* LOWER
- * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
- * | | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | XXXXXX . BACKSP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | | $ | { | [ | ( | % | # | ) | ] | } | @ | | | | INS |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
- * | | ^ | * | + | - | / | \ | _ | ' | " | ` | | XXXXXX . | HOME |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
- * | | | | & | ! | ~ | ; | : | = | < | > | ? | XXXXXX . | | END |
- * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
- * | | | | | | | | | | | | | | |
- * '--------------------------------------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_LOWER] = { // LOWER
- { _______, 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_DLR, KC_LCBR, KC_LBRC, KC_LPRN, KC_PERC, KC_HASH, KC_RPRN, KC_RBRC, KC_RCBR, KC_AT, _______, _______, _______, KC_INS },
- { _______, KC_CIRC, KC_ASTR, KC_PPLS, KC_PMNS, KC_SLSH, KC_BSLS, KC_UNDS, KC_QUOT, KC_DQT, KC_GRV, _______, ________________, KC_HOME },
- { _______, KC_PIPE, KC_AMPR, KC_EXLM, KC_TILD, KC_SCLN, KC_COLN, KC_EQL, KC_LT, KC_GT, KC_QUES, ________________, _______, KC_END },
- { _______, _______, _______, _______, _______, ________________, _______, _______, _______, _______, _______, _______, _______, _______ },
- },
-
-/* FUNCTION
- * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
- * | NUM LK | | | | | | | | | | | | | XXXXXX . |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | SCR LK | F13 | F14 | F15 | F16 | | | | | | | | | | |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
- * | CAP LK | F17 | F18 | F19 | F20 | | | | | | | | XXXXXX . | |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
- * | | F21 | F22 | F23 | F24 | | | | | | | XXXXXX . | VOL UP | MUTE |
- * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
- * | | | | | | PLAY/PAUSE | | | | | | PTRACK | VOL DN | NTRACK |
- * '--------------------------------------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_FUNCTION] = { // FUNCTION
- { KC_NLCK, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX },
- { KC_SLCK, KC_F13, KC_F14, KC_F15, KC_F16, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
- { KC_CAPS, KC_F17, KC_F18, KC_F19, KC_F20, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX, XXXXXXX },
- { _______, KC_F21, KC_F22, KC_F23, KC_F24, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, ________________, KC_VOLU, KC_MUTE },
- { _______, _______, _______, _______, _______, KC_MPLY, KC_MPLY, _______, _______, _______, _______, _______, KC_MPRV, KC_VOLD, KC_MNXT },
- },
-
-#ifdef MOUSEKEY_ENABLE
-
- [LAYER_MOUSE] = { // MOUSE
- { _______, KC_ACL0, KC_ACL1, KC_ACL2, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX },
- { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
- { XXXXXXX, KC_BTN5, KC_BTN4, KC_BTN3, KC_BTN2, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX, KC_WH_U },
- { _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, ________________, KC_MS_U, KC_WH_D },
- { _______, _______, _______, _______, _______, KC_BTN1, KC_BTN1, _______, _______, _______, _______, _______, KC_MS_L, KC_MS_D, KC_MS_R },
- },
-
-#endif
-
- [LAYER_ADJUST] = { // ADJUST
- { _______, TIMBR_1, TIMBR_2, TIMBR_3, TIMBR_4, TMPO_UP, TMPO_DN, TMPO_DF, _______, _______, _______, MU_TOG, AU_TOG, ________________ },
- { _______, M_QWRTY, M_COLMK, M_DVORK, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________, _______ },
- { _______, _______, _______, _______, M_BACKL, RESET, _______, M_MOUSE, _______, _______, _______, ________________, MUV_IN, _______ },
- { _______, _______, _______, _______, _______, ________________, _______, _______, _______, _______, _______, _______, MUV_DE, _______ },
- },
-
-
-/*
- [LAYER_EMPTY] = { // LAYER
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________ },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________, _______ },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________, _______, _______ },
- { _______, _______, _______, _______, _______, ________________, _______, _______, _______, _______, _______, _______, _______, _______ },
- },
+/* LAYER = LAYER_UPPER
+ .--------------------------------------------------------------------------------------------------------------------------------------.
+ | PRINT | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | NUM LK | KP / | KP * | KP - | XXXXXX | XXXXXX | ______ . ______ |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | PAUSE | F1 | F2 | F3 | F4 | NUM LK | KP / | KP 7 | KP 8 | KP 9 | KP - | ______ | ______ | ______ | INS |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | F5 | F6 | F7 | F8 | CAP LK | KP * | KP 4 | KP 5 | KP 6 | KP + | ______ | ______ . ______ | HOME |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | F9 | F10 | F11 | F12 | SCR LK | KP 0 | KP 1 | KP 2 | KP 3 | KP ENT | ______ . ______ | ______ | END |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | ______ | ______ | UPPER | KP 0 . KP 0 | ______ | RALT | KP . | KP ENT | ______ | ______ | ______ | ______ |
+ '--------------------------------------------------------------------------------------------------------------------------------------'
*/
-
+[LAYER_UPPER] = {
+ { KC_PSCR, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, XXXXXXX, XXXXXXX, _______, _______ },
+ { KC_PAUS, KC_F1 , KC_F2 , KC_F3 , KC_F4 , KC_NLCK, KC_PSLS, KC_KP_7, KC_KP_8, KC_KP_9, KC_PMNS, _______, _______, _______, KC_INS },
+ { _______, KC_F5 , KC_F6 , KC_F7 , KC_F8 , KC_CAPS, KC_PAST, KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, _______, _______, _______, KC_HOME },
+ { _______, KC_F9 , KC_F10 , KC_F11 , KC_F12 , KC_SLCK, KC_KP_0, KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, _______, _______, _______, KC_END },
+ { _______, _______, _______, _______, M_UPPER, KC_KP_0, KC_KP_0, _______, KC_RALT, KC_PDOT, KC_PENT, _______, _______, _______, _______ }
+},
+/* LAYER = LAYER_LOWER
+ .--------------------------------------------------------------------------------------------------------------------------------------.
+ | PRINT | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | ______ . ______ |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | $ | { | [ | ( | % | # | ) | ] | } | @ | ______ | ______ | ______ | INS |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ^ | * | + | - | / | \ | _ | ' | " | ` | ______ | ______ . ______ | HOME |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | | | & | ! | ~ | ; | : | = | < | > | ? | ______ . ______ | ______ | END |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | ______ | ______ | ______ | ______ . ______ | LOWER | ______ | ______ | ______ | ______ | ______ | ______ | ______ |
+ '--------------------------------------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_LOWER] = {
+ { KC_PSCR, 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_DLR , KC_LCBR, KC_LBRC, KC_LPRN, KC_PERC, KC_HASH, KC_RPRN, KC_RBRC, KC_RCBR, KC_AT , _______, _______, _______, KC_INS },
+ { _______, KC_CIRC, KC_ASTR, KC_PLUS, KC_MINS, KC_SLSH, KC_BSLS, KC_UNDS, KC_QUOT, KC_DQT , KC_GRV , _______, _______, _______, KC_HOME },
+ { _______, KC_PIPE, KC_AMPR, KC_EXLM, KC_TILD, KC_SCLN, KC_COLN, KC_EQL , KC_LT , KC_GT , KC_QUES, _______, _______, _______, KC_END },
+ { _______, _______, _______, _______, _______, _______, _______, M_LOWER, _______, _______, _______, _______, _______, _______, _______ }
+},
+/* LAYER = LAYER_FUNCTION
+ .--------------------------------------------------------------------------------------------------------------------------------------.
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX . XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | F13 | F14 | F15 | F16 | NUM LK | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | F17 | F18 | F19 | F20 | SCR LK | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX . XXXXXX | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | F21 | F22 | F23 | F24 | CAP LK | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | ______ . ______ | VOL UP | MUTE |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | FN | ______ | ______ | PLAY . PLAY | ______ | ______ | ______ | ______ | ______ | PREV | VOL DN | NEXT |
+ '--------------------------------------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_FUNCTION] = {
+ { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { XXXXXXX, KC_F13 , KC_F14 , KC_F15 , KC_F16 , KC_NLCK, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { XXXXXXX, KC_F17 , KC_F18 , KC_F19 , KC_F20 , KC_SLCK, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { _______, KC_F21 , KC_F22 , KC_F23 , KC_F24 , KC_CAPS, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, KC_VOLU, KC_MUTE },
+ { _______, _______, M_FUNCT, _______, _______, KC_MPLY, KC_MPLY, _______, _______, _______, _______, _______, KC_MPRV, KC_VOLD, KC_MNXT }
+},
+/* LAYER = LAYER_MOUSE
+ .--------------------------------------------------------------------------------------------------------------------------------------.
+ | ESC | MS AC0 | MS AC1 | MS AC2 | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX . XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | MS UL | MS U | MS UR | XXXXXX | XXXXXX | XXXXXX | MS WHL | MS WHR |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | MS BT5 | MS BT4 | MS BT3 | MS BT2 | XXXXXX | XXXXXX | MS L | XXXXXX | MS R | XXXXXX | XXXXXX | XXXXXX . XXXXXX | MS WHU |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | MS DL | MS D | MS DR | XXXXXX | ______ . ______ | MS U | MS WHD |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | ______ | ______ | ______ | MS BT1 . MS BT1 | ______ | ______ | ______ | ______ | ______ | MS L | MS D | MS R |
+ '--------------------------------------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_MOUSE] = {
+ { KC_ESC , KC_ACL0, KC_ACL1, KC_ACL2, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_MS_UL, KC_MS_U, M_MS_UR, XXXXXXX, XXXXXXX, XXXXXXX, KC_WH_L, KC_WH_R },
+ { XXXXXXX, KC_BTN5, KC_BTN4, KC_BTN3, KC_BTN2, XXXXXXX, XXXXXXX, KC_MS_L, XXXXXXX, KC_MS_R, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_WH_U },
+ { _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_MS_DL, KC_MS_D, M_MS_DR, XXXXXXX, _______, _______, KC_MS_U, KC_WH_D },
+ { _______, _______, _______, _______, _______, KC_BTN1, KC_BTN1, _______, _______, _______, _______, _______, KC_MS_L, KC_MS_D, KC_MS_R }
+},
+/* LAYER = LAYER_ADJUST
+ .--------------------------------------------------------------------------------------------------------------------------------------.
+ | XXXXXX | HELP 1 | HELP 2 | HELP 3 | HELP 4 | HELP 5 | HELP 6 | HELP 7 | HELP 8 | HELP 9 | XXXXXX | MUSIC | AUDIO | XXXXXX . XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | BRTOG | BRSPD+ | BRSPD- | BRDFLT | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX . XXXXXX | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | QWERTY | XXXXXX | XXXXXX | BACKLT | RESET | XXXXXX | MOUSE | XXXXXX | XXXXXX | XXXXXX | XXXXXX . XXXXXX | VOICE+ | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | UPPER | XXXXXX . XXXXXX | LOWER | XXXXXX | XXXXXX | XXXXXX | XXXXXX | TEMPO- | VOICE- | TEMPO+ |
+ '--------------------------------------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_ADJUST] = {
+ { XXXXXXX, M_HELP1, M_HELP2, M_HELP3, M_HELP4, M_HELP5, M_HELP6, M_HELP7, M_HELP8, M_HELP9, XXXXXXX, MU_TOG , AU_TOG , XXXXXXX, XXXXXXX },
+ { XXXXXXX, M_BRTOG, M_BSPDU, M_BSPDD, M_BDFLT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { XXXXXXX, M_QWRTY, XXXXXXX, XXXXXXX, M_BACKL, RESET , XXXXXXX, M_MOUSE, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, MUV_IN , XXXXXXX },
+ { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_UPPER, XXXXXXX, XXXXXXX, M_LOWER, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, TMPO_DN, MUV_DE , TMPO_UP }
+},
};
#ifdef AUDIO_ENABLE
@@ -290,61 +272,101 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
switch(id)
{
- case MACRO_BREATH_TOGGLE:
+ case MACRO_HELP_1:
if (record->event.pressed)
{
- breathing_toggle();
+ uprintf("1");
}
break;
- case MACRO_BREATH_SPEED_INC:
+ case MACRO_HELP_2:
if (record->event.pressed)
{
- breathing_speed_inc(1);
+ uprintf("2");
}
break;
- case MACRO_BREATH_SPEED_DEC:
+ case MACRO_HELP_3:
if (record->event.pressed)
{
- breathing_speed_dec(1);
+ uprintf("3");
}
break;
- case MACRO_BREATH_DEFAULT:
+ case MACRO_HELP_4:
if (record->event.pressed)
{
- breathing_defaults();
+ uprintf("4");
}
break;
- case MACRO_QWERTY:
+ case MACRO_HELP_5:
if (record->event.pressed)
{
- persistant_default_layer_set(1UL<<LAYER_QWERTY);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_qwerty, false, STACCATO);
- #endif /* AUDIO_ENABLE */
+ uprintf("5");
}
break;
- case MACRO_COLEMAK:
+ case MACRO_HELP_6:
if (record->event.pressed)
{
- persistant_default_layer_set(1UL<<LAYER_COLEMAK);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_colemak, false, STACCATO);
- #endif /* AUDIO_ENABLE */
+ uprintf("6");
}
break;
- case MACRO_DVORAK:
+ case MACRO_HELP_7:
if (record->event.pressed)
{
- persistant_default_layer_set(1UL<<LAYER_DVORAK);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_dvorak, false, STACCATO);
- #endif /* AUDIO_ENABLE */
+ uprintf("7");
+ }
+ break;
+
+ case MACRO_HELP_8:
+ if (record->event.pressed)
+ {
+ uprintf("8");
+ }
+ break;
+
+ case MACRO_HELP_9:
+ if (record->event.pressed)
+ {
+ uprintf("9");
+ }
+ break;
+
+ case MACRO_BREATH_TOGGLE:
+ if (record->event.pressed)
+ {
+ breathing_toggle();
+ }
+ break;
+
+ case MACRO_BREATH_SPEED_INC:
+ if (record->event.pressed)
+ {
+ breathing_speed_inc(1);
+ }
+ break;
+
+ case MACRO_BREATH_SPEED_DEC:
+ if (record->event.pressed)
+ {
+ breathing_speed_dec(1);
+ }
+ break;
+
+ case MACRO_BREATH_DEFAULT:
+ if (record->event.pressed)
+ {
+ breathing_defaults();
+ }
+ break;
+
+ case MACRO_QWERTY:
+ if (record->event.pressed)
+ {
+ persistant_default_layer_set(1UL<<LAYER_QWERTY);
}
break;
diff --git a/keyboards/atomic/readme.md b/keyboards/atomic/readme.md
index ab1e7ba1ff..674dcf113b 100644
--- a/keyboards/atomic/readme.md
+++ b/keyboards/atomic/readme.md
@@ -13,13 +13,14 @@ Download or clone the whole firmware and navigate to the keyboards/atomic folder
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create a file in the keymaps folder named `<name>.c` and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|jack|<name>]
```
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
diff --git a/keyboards/atomic/rules.mk b/keyboards/atomic/rules.mk
new file mode 100644
index 0000000000..d0f3a3a1c0
--- /dev/null
+++ b/keyboards/atomic/rules.mk
@@ -0,0 +1,69 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no # Audio output on port C6
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend \ No newline at end of file
diff --git a/keyboards/atreus/Makefile b/keyboards/atreus/Makefile
index 5894d231f9..4e2a6f00fd 100644
--- a/keyboards/atreus/Makefile
+++ b/keyboards/atreus/Makefile
@@ -1,88 +1,3 @@
-
-
-ifdef TEENSY2
- OPT_DEFS += -DATREUS_TEENSY2
- ATREUS_UPLOAD_COMMAND = teensy_loader_cli -w -mmcu=$(MCU) $(TARGET).hex
-else
- OPT_DEFS += -DATREUS_ASTAR
- OPT_DEFS += -DCATERINA_BOOTLOADER
- ATREUS_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \
- avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB)
-endif
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-#BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-NKRO_ENABLE ?= yes # USB Nkey Rollover - not yet supported in LUFA
-# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-# MIDI_ENABLE ?= YES # MIDI controls
-UNICODE_ENABLE ?= YES # Unicode
-# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
-USB ?= /dev/cu.usbmodem1411
-
-upload: build
- $(ATREUS_UPLOAD_COMMAND)
-
+endif \ No newline at end of file
diff --git a/keyboards/atreus/config.h b/keyboards/atreus/config.h
index 624d90188c..51162cde3a 100644
--- a/keyboards/atreus/config.h
+++ b/keyboards/atreus/config.h
@@ -37,7 +37,11 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
// COLS: Left to right, ROWS: Top to bottom
#if defined(ATREUS_ASTAR)
# define MATRIX_ROW_PINS { D0, D1, D3, D2 }
+#if defined(PCBDOWN)
+# define MATRIX_COL_PINS { B7, D6, F7, F6, B6, D4, E6, B4, B5, C6, D7 }
+#else
# define MATRIX_COL_PINS { D7, C6, B5, B4, E6, D4, B6, F6, F7, D6, B7 }
+#endif
# define UNUSED_PINS
#elif defined(ATREUS_TEENSY2)
# define MATRIX_ROW_PINS { D0, D1, D2, D3 }
diff --git a/keyboards/atreus/keymaps/classic/keymap.c b/keyboards/atreus/keymaps/classic/keymap.c
new file mode 100644
index 0000000000..6ca0b2077d
--- /dev/null
+++ b/keyboards/atreus/keymaps/classic/keymap.c
@@ -0,0 +1,48 @@
+#include "atreus.h"
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _QW 0
+#define _RS 1
+#define _LW 2
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+[_QW] = { /* Qwerty */
+ {KC_Q, KC_W, KC_E, KC_R, KC_T, KC_TRNS, KC_Y, KC_U, KC_I, KC_O, KC_P },
+ {KC_A, KC_S, KC_D, KC_F, KC_G, KC_TRNS, KC_H, KC_J, KC_K, KC_L, KC_SCLN },
+ {KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LALT, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH },
+ {KC_ESC, KC_TAB, KC_LGUI, KC_LSFT, KC_BSPC, KC_LCTL, KC_SPC, MO(_RS), KC_MINS, KC_QUOT, KC_ENT }
+},
+[_RS] = { /* [> RAISE <] */
+ {KC_EXLM, KC_AT, KC_LCBR, KC_RCBR, KC_PIPE, KC_TRNS, KC_PGUP, KC_7, KC_8, KC_9, KC_ASTR},
+ {KC_HASH, KC_DLR, KC_LPRN, KC_RPRN, KC_GRV, KC_TRNS, KC_PGDN, KC_4, KC_5, KC_6, KC_PLUS},
+ {KC_PERC, KC_CIRC, KC_LBRC, KC_RBRC, KC_TILD, KC_LALT, KC_AMPR, KC_1, KC_2, KC_3, KC_BSLS},
+ {TG(_LW), KC_INS, KC_LGUI, KC_LSFT, KC_BSPC, KC_LCTL, KC_SPC, KC_TRNS, KC_DOT, KC_0, KC_EQL}
+},
+[_LW] = { /* [> LOWER <] */
+ {KC_INS, KC_HOME, KC_UP, KC_END, KC_PGUP, KC_TRNS, KC_UP, KC_F7, KC_F8, KC_F9, KC_F10},
+ {KC_DELT, KC_LEFT, KC_DOWN, KC_RGHT, KC_DOWN, KC_TRNS, KC_DOWN, KC_F4, KC_F5, KC_F6, KC_F11},
+ {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LALT, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F12},
+ {KC_TRNS, KC_TRNS, KC_LGUI, KC_LSFT, KC_BSPC, KC_LCTL, KC_SPC, DF(_QW), KC_TRNS, KC_TRNS, RESET}
+}};
+
+const uint16_t PROGMEM fn_actions[] = {
+
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ register_code(KC_RSFT);
+ } else {
+ unregister_code(KC_RSFT);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
diff --git a/keyboards/atreus/keymaps/default/keymap.c b/keyboards/atreus/keymaps/default/keymap.c
index 1c4280ff56..04ad66fed8 100644
--- a/keyboards/atreus/keymaps/default/keymap.c
+++ b/keyboards/atreus/keymaps/default/keymap.c
@@ -18,17 +18,29 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
{KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LALT, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH },
{KC_ESC, KC_TAB, KC_LGUI, KC_LSFT, KC_BSPC, KC_LCTL, KC_SPC, MO(_RS), KC_MINS, KC_QUOT, KC_ENT }
},
+/*
+ * ! @ up { } || pgup 7 8 9 *
+ * # left down right $ || pgdn 4 5 6 +
+ * [ ] ( ) & || ` 1 2 3 \
+ * lower insert super shift bksp ctrl || alt space fn . 0 =
+ */
[_RS] = { /* [> RAISE <] */
- {KC_EXLM, KC_AT, KC_LCBR, KC_RCBR, KC_PIPE, KC_TRNS, KC_PGUP, KC_7, KC_8, KC_9, KC_ASTR},
- {KC_HASH, KC_DLR, KC_LPRN, KC_RPRN, KC_GRV, KC_TRNS, KC_PGDN, KC_4, KC_5, KC_6, KC_PLUS},
- {KC_PERC, KC_CIRC, KC_LBRC, KC_RBRC, KC_TILD, KC_LALT, KC_AMPR, KC_1, KC_2, KC_3, KC_BSLS},
+ {KC_EXLM, KC_AT, KC_UP, KC_LCBR, KC_RCBR, KC_TRNS, KC_PGUP, KC_7, KC_8, KC_9, KC_ASTR},
+ {KC_HASH, KC_LEFT, KC_DOWN, KC_RGHT, KC_DLR, KC_TRNS, KC_PGDN, KC_4, KC_5, KC_6, KC_PLUS},
+ {KC_LBRC, KC_RBRC, KC_LPRN, KC_RPRN, KC_AMPR, KC_LALT, KC_GRV, KC_1, KC_2, KC_3, KC_BSLS},
{TG(_LW), KC_INS, KC_LGUI, KC_LSFT, KC_BSPC, KC_LCTL, KC_SPC, KC_TRNS, KC_DOT, KC_0, KC_EQL}
},
+/*
+ * insert home up end pgup || up F7 F8 F9 F10
+ * del left down right pgdn || down F4 F5 F6 F11
+ * volup reset || F1 F2 F3 F12
+ * voldn super shift bksp ctrl || alt space L0 prtsc scroll pause
+ */
[_LW] = { /* [> LOWER <] */
{KC_INS, KC_HOME, KC_UP, KC_END, KC_PGUP, KC_TRNS, KC_UP, KC_F7, KC_F8, KC_F9, KC_F10},
{KC_DELT, KC_LEFT, KC_DOWN, KC_RGHT, KC_DOWN, KC_TRNS, KC_DOWN, KC_F4, KC_F5, KC_F6, KC_F11},
- {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LALT, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F12},
- {KC_TRNS, KC_TRNS, KC_LGUI, KC_LSFT, KC_BSPC, KC_LCTL, KC_SPC, DF(_QW), KC_TRNS, KC_TRNS, RESET}
+ {KC_TRNS, KC_VOLU, KC_TRNS, KC_TRNS, RESET, KC_LALT, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F12},
+ {KC_TRNS, KC_VOLD, KC_LGUI, KC_LSFT, KC_BSPC, KC_LCTL, KC_SPC, DF(_QW), KC_PSCR, KC_SLCK, KC_PAUS}
}};
const uint16_t PROGMEM fn_actions[] = {
diff --git a/keyboards/atreus/keymaps/erlandsona/config.h b/keyboards/atreus/keymaps/erlandsona/config.h
new file mode 100644
index 0000000000..d9eb1903ed
--- /dev/null
+++ b/keyboards/atreus/keymaps/erlandsona/config.h
@@ -0,0 +1,96 @@
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "config_common.h"
+
+
+/* Make Overloaded Keys switch faster */
+#define TAPPING_TERM 150
+
+/* USB Device descriptor parameter */
+
+#define VENDOR_ID 0xFEED
+#define PRODUCT_ID 0x6060
+#define DEVICE_VER 0x0001
+#define MANUFACTURER Technomancy
+#define PRODUCT Atreus
+#define DESCRIPTION q.m.k. keyboard firmware for Atreus
+
+/* key matrix size */
+#define MATRIX_ROWS 4
+#define MATRIX_COLS 11
+
+// Change this to how you wired your keyboard
+// COLS: Left to right, ROWS: Top to bottom
+#if defined(ATREUS_ASTAR)
+# define MATRIX_ROW_PINS { D0, D1, D3, D2 }
+#if defined(PCBDOWN)
+# define MATRIX_COL_PINS { B7, D6, F7, F6, B6, D4, E6, B4, B5, C6, D7 }
+#else
+# define MATRIX_COL_PINS { D7, C6, B5, B4, E6, D4, B6, F6, F7, D6, B7 }
+#endif
+# define UNUSED_PINS
+#elif defined(ATREUS_TEENSY2)
+# define MATRIX_ROW_PINS { D0, D1, D2, D3 }
+# define MATRIX_COL_PINS { F6, F5, F4, B7, B6, B5, B4, B3, B2, B1, B0 }
+# define UNUSED_PINS
+#endif
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* define if matrix has ghost */
+//#define MATRIX_HAS_GHOST
+
+/* number of backlight levels */
+//#define BACKLIGHT_LEVELS 3
+
+/* Set 0 if debouncing isn't needed */
+#define DEBOUNCING_DELAY 5
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+/* key combination for command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
+)
+
+/*
+ * Feature disable options
+ * These options are also useful to firmware size reduction.
+ */
+
+/* disable debug print */
+//#define NO_DEBUG
+
+/* disable print */
+//#define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
+
+#endif
diff --git a/keyboards/atreus/keymaps/erlandsona/keymap.c b/keyboards/atreus/keymaps/erlandsona/keymap.c
new file mode 100644
index 0000000000..32c8826e02
--- /dev/null
+++ b/keyboards/atreus/keymaps/erlandsona/keymap.c
@@ -0,0 +1,61 @@
+// this is the style you want to emulate.
+// This is the canonical layout file for the Quantum project. If you want to add another keyboard,
+
+#include "atreus.h"
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define BASE 0
+#define NUMS 1
+#define MOUS 2
+
+// Some quick aliases, just to make it look pretty
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+[BASE] = KEYMAP( /* Qwerty */
+ KC_Q , KC_W , KC_E , KC_R , KC_T , KC_Y , KC_U , KC_I , KC_O , KC_P ,
+ KC_A , KC_S , KC_D , KC_F , KC_G , KC_H , KC_J , KC_K , KC_L , KC_SCLN ,
+ SFT_T(KC_Z), KC_X , KC_C , KC_V , KC_B , KC_N , KC_M , KC_COMM, KC_DOT , SFT_T(KC_QUOT),
+ KC_LCTL , KC_LALT, KC_LALT, KC_LGUI, KC_BSPC, KC_ESC, KC_ENT, KC_SPC, F(NUMS), KC_RALT, KC_SLSH, KC_BSLS ),
+
+[NUMS] = KEYMAP( /* Numbers / Arrows / Symbols */
+ KC_GRV , KC_1 , KC_2 , KC_3 , KC_4 , KC_LPRN, KC_RPRN, KC_MINS, KC_EQL , KC_LBRC,
+ KC_TAB , KC_5 , KC_6 , KC_7 , KC_8 , KC_LEFT, KC_DOWN, KC_UP , KC_RGHT, KC_RBRC,
+ _______, KC_9 , KC_0 , KC_DOT , KC_COMM, KC_HOME, KC_PGDN, KC_PGUP, KC_END , _______,
+ _______, _______, _______, _______, KC_DEL , F(MOUS), _______, _______, _______, _______, _______, _______),
+
+[MOUS] = KEYMAP( /* Mouse and Media Keys */
+ KC_SLCK, KC_PAUSE, KC_F11 , KC_F10 , KC_F9 , KC_F8 , KC_F7 , KC_F6 , KC_F5 , KC_F4,
+ KC_VOLD, KC_ACL0 , KC_ACL1, KC_ACL2, KC_VOLU, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, KC_F3,
+ KC_MUTE, KC_MPRV , KC_MPLY, KC_MNXT, KC_MUTE, KC_WH_R, KC_WH_U, KC_WH_D, KC_WH_L, KC_F2,
+ _______, _______ , _______, _______, _______, _______, _______, KC_BTN1, F(BASE), RESET , KC_F12 , KC_F1)
+};
+
+
+// I prefer this layer switching strategy to the TG and MO functions.
+// so that I can get out of mouse mode just by tapping/holding my base layer FN key.
+const uint16_t PROGMEM fn_actions[] = {
+ [BASE] = ACTION_LAYER_OFF(2, 1), // switch back to layer 0
+ [NUMS] = ACTION_LAYER_MOMENTARY(1), // to Fn overlay
+ [MOUS] = ACTION_LAYER_ON(2, 1) // switch to layer 2
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ register_code(KC_RSFT);
+ } else {
+ unregister_code(KC_RSFT);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
diff --git a/keyboards/atreus/keymaps/jeremy/keymap.c b/keyboards/atreus/keymaps/jeremy/keymap.c
new file mode 100644
index 0000000000..90ec6f9049
--- /dev/null
+++ b/keyboards/atreus/keymaps/jeremy/keymap.c
@@ -0,0 +1,66 @@
+// This is the personal keymap of Jeremy Cowgar (@jcowgar). It is written for the programmer.
+
+#include "atreus.h"
+#include "action_layer.h"
+#include "keymap_colemak.h"
+
+#define PREVENT_STUCK_MODIFIERS
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+#define ALPH 0
+#define NUMS 1
+#define CURS 2
+#define SYMB 3
+#define FKEY 4
+
+// Some handy macros to keep the keymaps clean and easier to maintain
+#define KM_SAVE LGUI(CM_S)
+#define KM_CLSE LGUI(CM_W)
+#define KM_OPEN LGUI(CM_O)
+
+#define KM_COPY LGUI(KC_C)
+#define KM_CUT LGUI(KC_X)
+#define KM_PAST LGUI(KC_V)
+#define KM_UNDO LGUI(KC_Z)
+#define KM_REDO LGUI(LSFT(KC_Z))
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+[ALPH] = {
+ {KC_Q, KC_W, KC_E, KC_R, KC_T, KC_TRNS, KC_Y, KC_U, KC_I, KC_O, KC_P},
+ {KC_A, LT(NUMS, KC_S), LT(FKEY, KC_D), KC_F, KC_G, KC_TRNS, KC_H, KC_J, LT(CURS, KC_K), LT(SYMB, KC_L), KC_SCLN},
+ {KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LALT, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH},
+ {KC_LCTL, KC_ESC, KC_NO, KC_LSFT, KC_SPC, KC_LGUI, KC_ENT, KC_RSFT, KC_NO, KC_ESC, KC_RCTL}
+},
+[NUMS] = {
+ {KC_TRNS, KC_TRNS, KC_TRNS, KC_ASTR, KC_SLSH, KC_TRNS, KC_TRNS, KC_7, KC_8, KC_9, KC_SLSH},
+ {KC_TRNS, KC_TRNS, KC_EQL, KC_PLUS, KC_MINS, KC_TRNS, KC_LPRN, KC_4, KC_5, KC_6, KC_ASTR},
+ {KC_TRNS, KC_TRNS, KC_DOT, KC_COMM, CM_SCLN, KC_TRNS, KC_RPRN, KC_1, KC_2, KC_3, KC_MINS},
+ {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_0, KC_DOT, KC_EQL, KC_PLUS}
+},
+[CURS] = {
+ {KC_TRNS, KC_BSPC, KC_UP, KC_DELT, KC_PGUP, KC_TRNS, KC_TRNS, KM_SAVE, KC_TRNS, KM_OPEN, KC_TRNS},
+ {KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_PGDN, KC_TRNS, KM_UNDO, KC_LALT, KC_TRNS, KC_LGUI, KC_TRNS},
+ {KC_TRNS, KC_VOLD, KC_MUTE, KC_VOLU, KC_MPLY, KM_COPY, KM_REDO, KM_CLSE, KC_TRNS, KC_TRNS, KC_TRNS},
+ {KC_TRNS, KC_TRNS, RESET, KC_TRNS, KC_TAB, KM_CUT, KM_PAST, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS}
+},
+[SYMB] = {
+ {KC_BSLS, KC_EXLM, KC_LABK, KC_RABK, CM_COLN, KC_TRNS, KC_UNDS, KC_DLR, KC_QUES, KC_TRNS, KC_PERC},
+ {KC_AT, KC_AMPR, KC_LPRN, KC_RPRN, CM_SCLN, KC_TRNS, KC_COMM, KC_DOT, KC_QUOT, KC_TRNS, KC_TILD},
+ {KC_HASH, KC_PIPE, KC_LCBR, KC_RCBR, KC_SLSH, KC_TRNS, KC_TRNS, KC_GRV, KC_DQT, KC_TRNS, KC_CIRC},
+ {KC_TRNS, KC_TRNS, KC_LBRC, KC_RBRC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS}
+},
+[FKEY] = {
+ {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_F9, KC_F10, KC_F11, KC_F12},
+ {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_F5, KC_F6, KC_F7, KC_F8},
+ {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4},
+ {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS}
+}};
+
+const uint16_t PROGMEM fn_actions[] = {};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ switch(id) {}
+
+ return MACRO_NONE;
+};
diff --git a/keyboards/atreus/keymaps/jeremy/readme.md b/keyboards/atreus/keymaps/jeremy/readme.md
new file mode 100644
index 0000000000..df0179a8e0
--- /dev/null
+++ b/keyboards/atreus/keymaps/jeremy/readme.md
@@ -0,0 +1,45 @@
+Jeremy's Atreus Key Mapping
+===========================
+
+I am a programmer by trade that suffers from the beginning stages of RSI. As a programmer I use letters, symbols and cursor navigation most often. To prevent strange finger gymnastics, I wrote a script to rank which non-letter characters occurred in my primary source projects most often and then placed these characters in the easiest to reach locations, for me. I made heavy use of momentary layer toggling.
+
+My layout is also geared toward a software based Colemak mapping. I would like it to be hardware, but I use my Laptop on the go frequently and thus my laptop keyboard. I have moved the keycaps to reflect the Colemak layout. My laptop is a MacBook Pro (2015).
+
+## Main Layers
+
+1. [Letters](http://www.keyboard-layout-editor.com/#/gists/6861cb9df09ce78efaddf8aa7471e3ac)
+2. [Symbols](http://www.keyboard-layout-editor.com/#/gists/8956a18b508a78e93b9c38ec3fcccaa5)
+3. [Navigation](http://www.keyboard-layout-editor.com/#/gists/6ed492b714a7f54eb1c5de09b87fd8c4)
+4. [Numbers](http://www.keyboard-layout-editor.com/#/gists/399ceb5624e8388e48a3a5eacac8e973)
+5. [Function Keys](http://www.keyboard-layout-editor.com/#/gists/7fd7dc24c7048316f3724b1893c64e89)
+
+## Notes
+
+### General
+
+Some characters can be accessed multiple ways. This was done because you may be in a given layer, such as numbers, where when doing math, you may need quick access to the parentheses characters for grouping. This prevents some layer switching.
+
+I own an ErgoDox and plan on porting this as a base layer, then using the extra keys the ErgoDox provides accordingly. My goal, though, is to be fully functional on this base setup and build everything into muscle memory.
+
+### Symbol Layer
+
+1. I placed characters that deal with an if statement close together, such as !, & and |.
+2. All matching brace/bracket characters are together as well.
+
+### Number Layer
+
+1. Everything I did was a compromise when trying to mimic a ten-key. I did the best I could.
+2. Operators are duplicated on the right and left. I do not find it comfortable to use my pinky much, so I tend to use my left hand for +, -, * and / but those were also placed on the right hand to mimic the ten-key.
+3. Parentheses were added for typing on the calculator.
+
+### Cursor Layer
+
+1. It includes basic audio controls because they didn't really fit anywhere else
+2. It contains basic file manipulation. I'm not sure that was a good idea. I do save all the time, but Cmd+S isn't exactly hard.
+3. It contains the backspace and delete keys right on top of the left and right arrows.
+4. Cmd and Opt keys are duplicated. This makes for very easy navigation, for example on a Mac, Opt+Left/Right moves word by word. It also backspaces or deletes word by word.
+
+### Function Layer
+
+1. Almost all other layers I saw grouped the F keys into a bunch of three. This only gives nine function keys in order if you attempt to stay as close to the home row as possible. I went with a group of four, which gives all twelve function keys to the right hand, one row below and above the home row.
+2. I duplicated the Command and Option keys the same as on the cursor layer. This makes it dead easy to hit modified function keys such as Cmd+Opt+F5. It's also easy to toss in a Shift modifier in there with the right thumb since the bottom row is preserved.
diff --git a/keyboards/atreus/readme.md b/keyboards/atreus/readme.md
index 734f58f0f0..a4077668e3 100644
--- a/keyboards/atreus/readme.md
+++ b/keyboards/atreus/readme.md
@@ -174,13 +174,14 @@ Download or clone the whole firmware and navigate to the keyboards/planck folder
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|jack|<name>]
```
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
diff --git a/keyboards/atreus/rules.mk b/keyboards/atreus/rules.mk
new file mode 100644
index 0000000000..3a00993bd5
--- /dev/null
+++ b/keyboards/atreus/rules.mk
@@ -0,0 +1,82 @@
+
+
+ifdef TEENSY2
+ OPT_DEFS += -DATREUS_TEENSY2
+ ATREUS_UPLOAD_COMMAND = teensy_loader_cli -w -mmcu=$(MCU) $(TARGET).hex
+else
+ OPT_DEFS += -DATREUS_ASTAR
+ OPT_DEFS += -DCATERINA_BOOTLOADER
+ ATREUS_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \
+ avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB)
+endif
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+#BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= yes # USB Nkey Rollover - not yet supported in LUFA
+# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+# MIDI_ENABLE ?= YES # MIDI controls
+UNICODE_ENABLE ?= YES # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
+
+USB ?= /dev/cu.usbmodem1411
+
+upload: build
+ $(ATREUS_UPLOAD_COMMAND)
diff --git a/keyboards/bantam44/Makefile b/keyboards/bantam44/Makefile
index 03893dbf89..4e2a6f00fd 100644
--- a/keyboards/bantam44/Makefile
+++ b/keyboards/bantam44/Makefile
@@ -1,72 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=512
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-# NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-# MIDI_ENABLE ?= YES # MIDI controls
-# UNICODE_ENABLE ?= YES # Unicode
-# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
+endif \ No newline at end of file
diff --git a/keyboards/bantam44/readme.md b/keyboards/bantam44/readme.md
index 89d7f9d053..462f67c124 100644
--- a/keyboards/bantam44/readme.md
+++ b/keyboards/bantam44/readme.md
@@ -12,13 +12,14 @@ Download or clone the whole firmware and navigate to the keyboards/Bantam44 fold
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|jack|<name>]
```
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder. \ No newline at end of file
diff --git a/keyboards/bantam44/rules.mk b/keyboards/bantam44/rules.mk
new file mode 100644
index 0000000000..baa0e9e7a2
--- /dev/null
+++ b/keyboards/bantam44/rules.mk
@@ -0,0 +1,67 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=512
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+# NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+# MIDI_ENABLE ?= YES # MIDI controls
+# UNICODE_ENABLE ?= YES # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
diff --git a/keyboards/chibios_test/Makefile b/keyboards/chibios_test/Makefile
index d9f2b8b83b..4b07a62343 100644
--- a/keyboards/chibios_test/Makefile
+++ b/keyboards/chibios_test/Makefile
@@ -1,14 +1,5 @@
SUBPROJECT_DEFAULT = stm32_f072_onekey
-#BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration
-MOUSEKEY_ENABLE ?= yes # Mouse keys
-EXTRAKEY_ENABLE ?= yes # Audio control and System control
-CONSOLE_ENABLE ?= yes # Console for debug
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-NKRO_ENABLE ?= yes # USB Nkey Rollover
-CUSTOM_MATRIX ?= yes # Custom matrix file
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.c b/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.c
index 31319ef575..2809c9d184 100644
--- a/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.c
+++ b/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.c
@@ -1,49 +1,49 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-#include "hal.h"
-
-/**
- * @brief PAL setup.
- * @details Digital I/O ports static configuration as defined in @p board.h.
- * This variable is used by the HAL when initializing the PAL driver.
- */
-#if HAL_USE_PAL || defined(__DOXYGEN__)
-const PALConfig pal_default_config =
-{
- {VAL_GPIOAODR, VAL_GPIOACRL, VAL_GPIOACRH},
- {VAL_GPIOBODR, VAL_GPIOBCRL, VAL_GPIOBCRH},
- {VAL_GPIOCODR, VAL_GPIOCCRL, VAL_GPIOCCRH},
- {VAL_GPIODODR, VAL_GPIODCRL, VAL_GPIODCRH},
- {VAL_GPIOEODR, VAL_GPIOECRL, VAL_GPIOECRH},
-};
-#endif
-
-/*
- * Early initialization code.
- * This initialization must be performed just after stack setup and before
- * any other initialization.
- */
-void __early_init(void) {
-
- stm32_clock_init();
-}
-
-/*
- * Board-specific initialization code.
- */
-void boardInit(void) {
-}
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+#include "hal.h"
+
+/**
+ * @brief PAL setup.
+ * @details Digital I/O ports static configuration as defined in @p board.h.
+ * This variable is used by the HAL when initializing the PAL driver.
+ */
+#if HAL_USE_PAL || defined(__DOXYGEN__)
+const PALConfig pal_default_config =
+{
+ {VAL_GPIOAODR, VAL_GPIOACRL, VAL_GPIOACRH},
+ {VAL_GPIOBODR, VAL_GPIOBCRL, VAL_GPIOBCRH},
+ {VAL_GPIOCODR, VAL_GPIOCCRL, VAL_GPIOCCRH},
+ {VAL_GPIODODR, VAL_GPIODCRL, VAL_GPIODCRH},
+ {VAL_GPIOEODR, VAL_GPIOECRL, VAL_GPIOECRH},
+};
+#endif
+
+/*
+ * Early initialization code.
+ * This initialization must be performed just after stack setup and before
+ * any other initialization.
+ */
+void __early_init(void) {
+
+ stm32_clock_init();
+}
+
+/*
+ * Board-specific initialization code.
+ */
+void boardInit(void) {
+}
diff --git a/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.h b/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.h
index 7253e77826..b31d74307b 100644
--- a/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.h
+++ b/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.h
@@ -1,166 +1,166 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-#ifndef _BOARD_H_
-#define _BOARD_H_
-
-/*
- * Setup for a Generic STM32F103 board.
- */
-
-/*
- * Board identifier.
- */
-#define BOARD_GENERIC_STM32_F103
-#define BOARD_NAME "Generic STM32F103x board"
-
-/*
- * Board frequencies.
- */
-#define STM32_LSECLK 32768
-#define STM32_HSECLK 8000000
-
-/*
- * MCU type, supported types are defined in ./os/hal/platforms/hal_lld.h.
- */
-#define STM32F103xB
-
-/*
- * IO pins assignments
- */
-
-/* on-board */
-
-#define GPIOC_LED 13
-#define GPIOD_OSC_IN 0
-#define GPIOD_OSC_OUT 1
-
-/* In case your board has a "USB enable" hardware
- controlled by a pin, define it here. (It could be just
- a 1.5k resistor connected to D+ line.)
-*/
-/*
-#define GPIOB_USB_DISC 10
-*/
-
-/*
- * I/O ports initial setup, this configuration is established soon after reset
- * in the initialization code.
- *
- * The digits have the following meaning:
- * 0 - Analog input.
- * 1 - Push Pull output 10MHz.
- * 2 - Push Pull output 2MHz.
- * 3 - Push Pull output 50MHz.
- * 4 - Digital input.
- * 5 - Open Drain output 10MHz.
- * 6 - Open Drain output 2MHz.
- * 7 - Open Drain output 50MHz.
- * 8 - Digital input with PullUp or PullDown resistor depending on ODR.
- * 9 - Alternate Push Pull output 10MHz.
- * A - Alternate Push Pull output 2MHz.
- * B - Alternate Push Pull output 50MHz.
- * C - Reserved.
- * D - Alternate Open Drain output 10MHz.
- * E - Alternate Open Drain output 2MHz.
- * F - Alternate Open Drain output 50MHz.
- * Please refer to the STM32 Reference Manual for details.
- */
-
-/*
- * Port A setup.
- * Everything input with pull-up except:
- * PA2 - Alternate output (USART2 TX).
- * PA3 - Normal input (USART2 RX).
- * PA9 - Alternate output (USART1 TX).
- * PA10 - Normal input (USART1 RX).
- */
-#define VAL_GPIOACRL 0x88884B88 /* PA7...PA0 */
-#define VAL_GPIOACRH 0x888884B8 /* PA15...PA8 */
-#define VAL_GPIOAODR 0xFFFFFFFF
-
-/*
- * Port B setup.
- * Everything input with pull-up except:
- * PB10 - Push Pull output (USB switch).
- */
-#define VAL_GPIOBCRL 0x88888888 /* PB7...PB0 */
-#define VAL_GPIOBCRH 0x88888388 /* PB15...PB8 */
-#define VAL_GPIOBODR 0xFFFFFFFF
-
-/*
- * Port C setup.
- * Everything input with pull-up except:
- * PC13 - Push Pull output (LED).
- */
-#define VAL_GPIOCCRL 0x88888888 /* PC7...PC0 */
-#define VAL_GPIOCCRH 0x88388888 /* PC15...PC8 */
-#define VAL_GPIOCODR 0xFFFFFFFF
-
-/*
- * Port D setup.
- * Everything input with pull-up except:
- * PD0 - Normal input (XTAL).
- * PD1 - Normal input (XTAL).
- */
-#define VAL_GPIODCRL 0x88888844 /* PD7...PD0 */
-#define VAL_GPIODCRH 0x88888888 /* PD15...PD8 */
-#define VAL_GPIODODR 0xFFFFFFFF
-
-/*
- * Port E setup.
- * Everything input with pull-up except:
- */
-#define VAL_GPIOECRL 0x88888888 /* PE7...PE0 */
-#define VAL_GPIOECRH 0x88888888 /* PE15...PE8 */
-#define VAL_GPIOEODR 0xFFFFFFFF
-
-/*
- * USB bus activation macro, required by the USB driver.
- */
-/* The point is that most of the generic STM32F103* boards
- have a 1.5k resistor connected on one end to the D+ line
- and on the other end to some pin. Or even a slightly more
- complicated "USB enable" circuit, controlled by a pin.
- That should go here.
-
- However on some boards (e.g. one that I have), there's no
- such hardware. In which case it's better to not do anything.
-*/
-/*
-#define usb_lld_connect_bus(usbp) palClearPad(GPIOB, GPIOB_USB_DISC)
-*/
-#define usb_lld_connect_bus(usbp) palSetPadMode(GPIOA, 12, PAL_MODE_INPUT);
-
-/*
- * USB bus de-activation macro, required by the USB driver.
- */
-/*
-#define usb_lld_disconnect_bus(usbp) palSetPad(GPIOB, GPIOB_USB_DISC)
-*/
-#define usb_lld_disconnect_bus(usbp) palSetPadMode(GPIOA, 12, PAL_MODE_OUTPUT_PUSHPULL); palClearPad(GPIOA, 12);
-
-#if !defined(_FROM_ASM_)
-#ifdef __cplusplus
-extern "C" {
-#endif
- void boardInit(void);
-#ifdef __cplusplus
-}
-#endif
-#endif /* _FROM_ASM_ */
-
-#endif /* _BOARD_H_ */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+#ifndef _BOARD_H_
+#define _BOARD_H_
+
+/*
+ * Setup for a Generic STM32F103 board.
+ */
+
+/*
+ * Board identifier.
+ */
+#define BOARD_GENERIC_STM32_F103
+#define BOARD_NAME "Generic STM32F103x board"
+
+/*
+ * Board frequencies.
+ */
+#define STM32_LSECLK 32768
+#define STM32_HSECLK 8000000
+
+/*
+ * MCU type, supported types are defined in ./os/hal/platforms/hal_lld.h.
+ */
+#define STM32F103xB
+
+/*
+ * IO pins assignments
+ */
+
+/* on-board */
+
+#define GPIOC_LED 13
+#define GPIOD_OSC_IN 0
+#define GPIOD_OSC_OUT 1
+
+/* In case your board has a "USB enable" hardware
+ controlled by a pin, define it here. (It could be just
+ a 1.5k resistor connected to D+ line.)
+*/
+/*
+#define GPIOB_USB_DISC 10
+*/
+
+/*
+ * I/O ports initial setup, this configuration is established soon after reset
+ * in the initialization code.
+ *
+ * The digits have the following meaning:
+ * 0 - Analog input.
+ * 1 - Push Pull output 10MHz.
+ * 2 - Push Pull output 2MHz.
+ * 3 - Push Pull output 50MHz.
+ * 4 - Digital input.
+ * 5 - Open Drain output 10MHz.
+ * 6 - Open Drain output 2MHz.
+ * 7 - Open Drain output 50MHz.
+ * 8 - Digital input with PullUp or PullDown resistor depending on ODR.
+ * 9 - Alternate Push Pull output 10MHz.
+ * A - Alternate Push Pull output 2MHz.
+ * B - Alternate Push Pull output 50MHz.
+ * C - Reserved.
+ * D - Alternate Open Drain output 10MHz.
+ * E - Alternate Open Drain output 2MHz.
+ * F - Alternate Open Drain output 50MHz.
+ * Please refer to the STM32 Reference Manual for details.
+ */
+
+/*
+ * Port A setup.
+ * Everything input with pull-up except:
+ * PA2 - Alternate output (USART2 TX).
+ * PA3 - Normal input (USART2 RX).
+ * PA9 - Alternate output (USART1 TX).
+ * PA10 - Normal input (USART1 RX).
+ */
+#define VAL_GPIOACRL 0x88884B88 /* PA7...PA0 */
+#define VAL_GPIOACRH 0x888884B8 /* PA15...PA8 */
+#define VAL_GPIOAODR 0xFFFFFFFF
+
+/*
+ * Port B setup.
+ * Everything input with pull-up except:
+ * PB10 - Push Pull output (USB switch).
+ */
+#define VAL_GPIOBCRL 0x88888888 /* PB7...PB0 */
+#define VAL_GPIOBCRH 0x88888388 /* PB15...PB8 */
+#define VAL_GPIOBODR 0xFFFFFFFF
+
+/*
+ * Port C setup.
+ * Everything input with pull-up except:
+ * PC13 - Push Pull output (LED).
+ */
+#define VAL_GPIOCCRL 0x88888888 /* PC7...PC0 */
+#define VAL_GPIOCCRH 0x88388888 /* PC15...PC8 */
+#define VAL_GPIOCODR 0xFFFFFFFF
+
+/*
+ * Port D setup.
+ * Everything input with pull-up except:
+ * PD0 - Normal input (XTAL).
+ * PD1 - Normal input (XTAL).
+ */
+#define VAL_GPIODCRL 0x88888844 /* PD7...PD0 */
+#define VAL_GPIODCRH 0x88888888 /* PD15...PD8 */
+#define VAL_GPIODODR 0xFFFFFFFF
+
+/*
+ * Port E setup.
+ * Everything input with pull-up except:
+ */
+#define VAL_GPIOECRL 0x88888888 /* PE7...PE0 */
+#define VAL_GPIOECRH 0x88888888 /* PE15...PE8 */
+#define VAL_GPIOEODR 0xFFFFFFFF
+
+/*
+ * USB bus activation macro, required by the USB driver.
+ */
+/* The point is that most of the generic STM32F103* boards
+ have a 1.5k resistor connected on one end to the D+ line
+ and on the other end to some pin. Or even a slightly more
+ complicated "USB enable" circuit, controlled by a pin.
+ That should go here.
+
+ However on some boards (e.g. one that I have), there's no
+ such hardware. In which case it's better to not do anything.
+*/
+/*
+#define usb_lld_connect_bus(usbp) palClearPad(GPIOB, GPIOB_USB_DISC)
+*/
+#define usb_lld_connect_bus(usbp) palSetPadMode(GPIOA, 12, PAL_MODE_INPUT);
+
+/*
+ * USB bus de-activation macro, required by the USB driver.
+ */
+/*
+#define usb_lld_disconnect_bus(usbp) palSetPad(GPIOB, GPIOB_USB_DISC)
+*/
+#define usb_lld_disconnect_bus(usbp) palSetPadMode(GPIOA, 12, PAL_MODE_OUTPUT_PUSHPULL); palClearPad(GPIOA, 12);
+
+#if !defined(_FROM_ASM_)
+#ifdef __cplusplus
+extern "C" {
+#endif
+ void boardInit(void);
+#ifdef __cplusplus
+}
+#endif
+#endif /* _FROM_ASM_ */
+
+#endif /* _BOARD_H_ */
diff --git a/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.mk b/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.mk
index d692c0ee46..48e0e51fe6 100644
--- a/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.mk
+++ b/keyboards/chibios_test/boards/GENERIC_STM32_F103/board.mk
@@ -1,5 +1,5 @@
-# List of all the board related files.
-BOARDSRC = $(KEYBOARD_PATH)/boards/GENERIC_STM32_F103/board.c
-
-# Required include directories
-BOARDINC = $(KEYBOARD_PATH)/boards/GENERIC_STM32_F103
+# List of all the board related files.
+BOARDSRC = $(KEYBOARD_PATH)/boards/GENERIC_STM32_F103/board.c
+
+# Required include directories
+BOARDINC = $(KEYBOARD_PATH)/boards/GENERIC_STM32_F103
diff --git a/keyboards/chibios_test/ld/MKL26Z64.ld b/keyboards/chibios_test/ld/MKL26Z64.ld
index fb141f888c..c4ca8b874c 100644
--- a/keyboards/chibios_test/ld/MKL26Z64.ld
+++ b/keyboards/chibios_test/ld/MKL26Z64.ld
@@ -1,105 +1,105 @@
-/*
- * Copyright (C) 2013-2016 Fabio Utzig, http://fabioutzig.com
- * (C) 2016 flabbergast <s3+flabbergast@sdfeu.org>
- *
- * Permission is hereby granted, free of charge, to any person obtaining
- * a copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
- * SOFTWARE.
- */
-
-/*
- * KL26Z64 memory setup.
- */
-MEMORY
-{
- flash0 : org = 0x00000000, len = 0x100
- flash1 : org = 0x00000400, len = 0x10
- flash2 : org = 0x00000410, len = 62k - 0x410
- flash3 : org = 0x0000F800, len = 2k
- flash4 : org = 0x00000000, len = 0
- flash5 : org = 0x00000000, len = 0
- flash6 : org = 0x00000000, len = 0
- flash7 : org = 0x00000000, len = 0
- ram0 : org = 0x1FFFF800, len = 8k
- ram1 : org = 0x00000000, len = 0
- ram2 : org = 0x00000000, len = 0
- ram3 : org = 0x00000000, len = 0
- ram4 : org = 0x00000000, len = 0
- ram5 : org = 0x00000000, len = 0
- ram6 : org = 0x00000000, len = 0
- ram7 : org = 0x00000000, len = 0
-}
-
-/* Flash region for the configuration bytes.*/
-SECTIONS
-{
- .cfmprotect : ALIGN(4) SUBALIGN(4)
- {
- KEEP(*(.cfmconfig))
- } > flash1
-}
-
-/* For each data/text section two region are defined, a virtual region
- and a load region (_LMA suffix).*/
-
-/* Flash region to be used for exception vectors.*/
-REGION_ALIAS("VECTORS_FLASH", flash0);
-REGION_ALIAS("VECTORS_FLASH_LMA", flash0);
-
-/* Flash region to be used for constructors and destructors.*/
-REGION_ALIAS("XTORS_FLASH", flash2);
-REGION_ALIAS("XTORS_FLASH_LMA", flash2);
-
-/* Flash region to be used for code text.*/
-REGION_ALIAS("TEXT_FLASH", flash2);
-REGION_ALIAS("TEXT_FLASH_LMA", flash2);
-
-/* Flash region to be used for read only data.*/
-REGION_ALIAS("RODATA_FLASH", flash2);
-REGION_ALIAS("RODATA_FLASH_LMA", flash2);
-
-/* Flash region to be used for various.*/
-REGION_ALIAS("VARIOUS_FLASH", flash2);
-REGION_ALIAS("VARIOUS_FLASH_LMA", flash2);
-
-/* Flash region to be used for RAM(n) initialization data.*/
-REGION_ALIAS("RAM_INIT_FLASH_LMA", flash2);
-
-/* RAM region to be used for Main stack. This stack accommodates the processing
- of all exceptions and interrupts.*/
-REGION_ALIAS("MAIN_STACK_RAM", ram0);
-
-/* RAM region to be used for the process stack. This is the stack used by
- the main() function.*/
-REGION_ALIAS("PROCESS_STACK_RAM", ram0);
-
-/* RAM region to be used for data segment.*/
-REGION_ALIAS("DATA_RAM", ram0);
-REGION_ALIAS("DATA_RAM_LMA", flash2);
-
-/* RAM region to be used for BSS segment.*/
-REGION_ALIAS("BSS_RAM", ram0);
-
-/* RAM region to be used for the default heap.*/
-REGION_ALIAS("HEAP_RAM", ram0);
-
-__eeprom_workarea_start__ = ORIGIN(flash3);
-__eeprom_workarea_size__ = LENGTH(flash3);
-__eeprom_workarea_end__ = __eeprom_workarea_start__ + __eeprom_workarea_size__;
-
-/* Generic rules inclusion.*/
-INCLUDE rules.ld
+/*
+ * Copyright (C) 2013-2016 Fabio Utzig, http://fabioutzig.com
+ * (C) 2016 flabbergast <s3+flabbergast@sdfeu.org>
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+/*
+ * KL26Z64 memory setup.
+ */
+MEMORY
+{
+ flash0 : org = 0x00000000, len = 0x100
+ flash1 : org = 0x00000400, len = 0x10
+ flash2 : org = 0x00000410, len = 62k - 0x410
+ flash3 : org = 0x0000F800, len = 2k
+ flash4 : org = 0x00000000, len = 0
+ flash5 : org = 0x00000000, len = 0
+ flash6 : org = 0x00000000, len = 0
+ flash7 : org = 0x00000000, len = 0
+ ram0 : org = 0x1FFFF800, len = 8k
+ ram1 : org = 0x00000000, len = 0
+ ram2 : org = 0x00000000, len = 0
+ ram3 : org = 0x00000000, len = 0
+ ram4 : org = 0x00000000, len = 0
+ ram5 : org = 0x00000000, len = 0
+ ram6 : org = 0x00000000, len = 0
+ ram7 : org = 0x00000000, len = 0
+}
+
+/* Flash region for the configuration bytes.*/
+SECTIONS
+{
+ .cfmprotect : ALIGN(4) SUBALIGN(4)
+ {
+ KEEP(*(.cfmconfig))
+ } > flash1
+}
+
+/* For each data/text section two region are defined, a virtual region
+ and a load region (_LMA suffix).*/
+
+/* Flash region to be used for exception vectors.*/
+REGION_ALIAS("VECTORS_FLASH", flash0);
+REGION_ALIAS("VECTORS_FLASH_LMA", flash0);
+
+/* Flash region to be used for constructors and destructors.*/
+REGION_ALIAS("XTORS_FLASH", flash2);
+REGION_ALIAS("XTORS_FLASH_LMA", flash2);
+
+/* Flash region to be used for code text.*/
+REGION_ALIAS("TEXT_FLASH", flash2);
+REGION_ALIAS("TEXT_FLASH_LMA", flash2);
+
+/* Flash region to be used for read only data.*/
+REGION_ALIAS("RODATA_FLASH", flash2);
+REGION_ALIAS("RODATA_FLASH_LMA", flash2);
+
+/* Flash region to be used for various.*/
+REGION_ALIAS("VARIOUS_FLASH", flash2);
+REGION_ALIAS("VARIOUS_FLASH_LMA", flash2);
+
+/* Flash region to be used for RAM(n) initialization data.*/
+REGION_ALIAS("RAM_INIT_FLASH_LMA", flash2);
+
+/* RAM region to be used for Main stack. This stack accommodates the processing
+ of all exceptions and interrupts.*/
+REGION_ALIAS("MAIN_STACK_RAM", ram0);
+
+/* RAM region to be used for the process stack. This is the stack used by
+ the main() function.*/
+REGION_ALIAS("PROCESS_STACK_RAM", ram0);
+
+/* RAM region to be used for data segment.*/
+REGION_ALIAS("DATA_RAM", ram0);
+REGION_ALIAS("DATA_RAM_LMA", flash2);
+
+/* RAM region to be used for BSS segment.*/
+REGION_ALIAS("BSS_RAM", ram0);
+
+/* RAM region to be used for the default heap.*/
+REGION_ALIAS("HEAP_RAM", ram0);
+
+__eeprom_workarea_start__ = ORIGIN(flash3);
+__eeprom_workarea_size__ = LENGTH(flash3);
+__eeprom_workarea_end__ = __eeprom_workarea_start__ + __eeprom_workarea_size__;
+
+/* Generic rules inclusion.*/
+INCLUDE rules.ld
diff --git a/keyboards/chibios_test/ld/STM32F103x8_stm32duino_bootloader.ld b/keyboards/chibios_test/ld/STM32F103x8_stm32duino_bootloader.ld
index 00613328ed..f9bfe9c005 100644
--- a/keyboards/chibios_test/ld/STM32F103x8_stm32duino_bootloader.ld
+++ b/keyboards/chibios_test/ld/STM32F103x8_stm32duino_bootloader.ld
@@ -1,88 +1,88 @@
-/*
- ChibiOS - Copyright (C) 2006..2016 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-/*
- * ST32F103xB memory setup for use with the maplemini bootloader.
- * You will have to
- * #define CORTEX_VTOR_INIT 0x5000
- * in your projects chconf.h
- */
-MEMORY
-{
- flash0 : org = 0x08002000, len = 128k - 0x2000
- flash1 : org = 0x00000000, len = 0
- flash2 : org = 0x00000000, len = 0
- flash3 : org = 0x00000000, len = 0
- flash4 : org = 0x00000000, len = 0
- flash5 : org = 0x00000000, len = 0
- flash6 : org = 0x00000000, len = 0
- flash7 : org = 0x00000000, len = 0
- ram0 : org = 0x20000000, len = 20k
- ram1 : org = 0x00000000, len = 0
- ram2 : org = 0x00000000, len = 0
- ram3 : org = 0x00000000, len = 0
- ram4 : org = 0x00000000, len = 0
- ram5 : org = 0x00000000, len = 0
- ram6 : org = 0x00000000, len = 0
- ram7 : org = 0x00000000, len = 0
-}
-
-/* For each data/text section two region are defined, a virtual region
- and a load region (_LMA suffix).*/
-
-/* Flash region to be used for exception vectors.*/
-REGION_ALIAS("VECTORS_FLASH", flash0);
-REGION_ALIAS("VECTORS_FLASH_LMA", flash0);
-
-/* Flash region to be used for constructors and destructors.*/
-REGION_ALIAS("XTORS_FLASH", flash0);
-REGION_ALIAS("XTORS_FLASH_LMA", flash0);
-
-/* Flash region to be used for code text.*/
-REGION_ALIAS("TEXT_FLASH", flash0);
-REGION_ALIAS("TEXT_FLASH_LMA", flash0);
-
-/* Flash region to be used for read only data.*/
-REGION_ALIAS("RODATA_FLASH", flash0);
-REGION_ALIAS("RODATA_FLASH_LMA", flash0);
-
-/* Flash region to be used for various.*/
-REGION_ALIAS("VARIOUS_FLASH", flash0);
-REGION_ALIAS("VARIOUS_FLASH_LMA", flash0);
-
-/* Flash region to be used for RAM(n) initialization data.*/
-REGION_ALIAS("RAM_INIT_FLASH_LMA", flash0);
-
-/* RAM region to be used for Main stack. This stack accommodates the processing
- of all exceptions and interrupts.*/
-REGION_ALIAS("MAIN_STACK_RAM", ram0);
-
-/* RAM region to be used for the process stack. This is the stack used by
- the main() function.*/
-REGION_ALIAS("PROCESS_STACK_RAM", ram0);
-
-/* RAM region to be used for data segment.*/
-REGION_ALIAS("DATA_RAM", ram0);
-REGION_ALIAS("DATA_RAM_LMA", flash0);
-
-/* RAM region to be used for BSS segment.*/
-REGION_ALIAS("BSS_RAM", ram0);
-
-/* RAM region to be used for the default heap.*/
-REGION_ALIAS("HEAP_RAM", ram0);
-
-/* Generic rules inclusion.*/
-INCLUDE rules.ld
+/*
+ ChibiOS - Copyright (C) 2006..2016 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+/*
+ * ST32F103xB memory setup for use with the maplemini bootloader.
+ * You will have to
+ * #define CORTEX_VTOR_INIT 0x5000
+ * in your projects chconf.h
+ */
+MEMORY
+{
+ flash0 : org = 0x08002000, len = 128k - 0x2000
+ flash1 : org = 0x00000000, len = 0
+ flash2 : org = 0x00000000, len = 0
+ flash3 : org = 0x00000000, len = 0
+ flash4 : org = 0x00000000, len = 0
+ flash5 : org = 0x00000000, len = 0
+ flash6 : org = 0x00000000, len = 0
+ flash7 : org = 0x00000000, len = 0
+ ram0 : org = 0x20000000, len = 20k
+ ram1 : org = 0x00000000, len = 0
+ ram2 : org = 0x00000000, len = 0
+ ram3 : org = 0x00000000, len = 0
+ ram4 : org = 0x00000000, len = 0
+ ram5 : org = 0x00000000, len = 0
+ ram6 : org = 0x00000000, len = 0
+ ram7 : org = 0x00000000, len = 0
+}
+
+/* For each data/text section two region are defined, a virtual region
+ and a load region (_LMA suffix).*/
+
+/* Flash region to be used for exception vectors.*/
+REGION_ALIAS("VECTORS_FLASH", flash0);
+REGION_ALIAS("VECTORS_FLASH_LMA", flash0);
+
+/* Flash region to be used for constructors and destructors.*/
+REGION_ALIAS("XTORS_FLASH", flash0);
+REGION_ALIAS("XTORS_FLASH_LMA", flash0);
+
+/* Flash region to be used for code text.*/
+REGION_ALIAS("TEXT_FLASH", flash0);
+REGION_ALIAS("TEXT_FLASH_LMA", flash0);
+
+/* Flash region to be used for read only data.*/
+REGION_ALIAS("RODATA_FLASH", flash0);
+REGION_ALIAS("RODATA_FLASH_LMA", flash0);
+
+/* Flash region to be used for various.*/
+REGION_ALIAS("VARIOUS_FLASH", flash0);
+REGION_ALIAS("VARIOUS_FLASH_LMA", flash0);
+
+/* Flash region to be used for RAM(n) initialization data.*/
+REGION_ALIAS("RAM_INIT_FLASH_LMA", flash0);
+
+/* RAM region to be used for Main stack. This stack accommodates the processing
+ of all exceptions and interrupts.*/
+REGION_ALIAS("MAIN_STACK_RAM", ram0);
+
+/* RAM region to be used for the process stack. This is the stack used by
+ the main() function.*/
+REGION_ALIAS("PROCESS_STACK_RAM", ram0);
+
+/* RAM region to be used for data segment.*/
+REGION_ALIAS("DATA_RAM", ram0);
+REGION_ALIAS("DATA_RAM_LMA", flash0);
+
+/* RAM region to be used for BSS segment.*/
+REGION_ALIAS("BSS_RAM", ram0);
+
+/* RAM region to be used for the default heap.*/
+REGION_ALIAS("HEAP_RAM", ram0);
+
+/* Generic rules inclusion.*/
+INCLUDE rules.ld
diff --git a/keyboards/chibios_test/rules.mk b/keyboards/chibios_test/rules.mk
new file mode 100644
index 0000000000..4b5a845356
--- /dev/null
+++ b/keyboards/chibios_test/rules.mk
@@ -0,0 +1,8 @@
+#BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration
+MOUSEKEY_ENABLE ?= yes # Mouse keys
+EXTRAKEY_ENABLE ?= yes # Audio control and System control
+CONSOLE_ENABLE ?= yes # Console for debug
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= yes # USB Nkey Rollover
+CUSTOM_MATRIX ?= yes # Custom matrix file \ No newline at end of file
diff --git a/keyboards/chibios_test/stm32_f072_onekey/Makefile b/keyboards/chibios_test/stm32_f072_onekey/Makefile
index eae38c4b2b..191c6bb664 100644
--- a/keyboards/chibios_test/stm32_f072_onekey/Makefile
+++ b/keyboards/chibios_test/stm32_f072_onekey/Makefile
@@ -1,41 +1,3 @@
-# project specific files
-SRC = matrix.c \
- led.c
-
-## chip/board settings
-# the next two should match the directories in
-# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
-MCU_FAMILY = STM32
-MCU_SERIES = STM32F0xx
-# linker script to use
-# it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
-# or <this_dir>/ld/
-MCU_LDSCRIPT = STM32F072xB
-# startup code to use
-# is should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
-MCU_STARTUP = stm32f0xx
-# it should exist either in <chibios>/os/hal/boards/
-# or <this_dir>/boards
-BOARD = ST_STM32F072B_DISCOVERY
-# Cortex version
-# Teensy LC is cortex-m0; Teensy 3.x are cortex-m4
-MCU = cortex-m0
-# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
-ARMV = 6
-# If you want to be able to jump to bootloader from firmware on STM32 MCUs,
-# set the correct BOOTLOADER_ADDRESS. Either set it here, or define it in
-# ./bootloader_defs.h or in ./boards/<FOO>/bootloader_defs.h (if you have
-# a custom board definition that you plan to reuse).
-# If you're not setting it here, leave it commented out.
-# It is chip dependent, the correct number can be looked up here (page 175):
-# http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf
-# This also requires a patch to chibios:
-# <tmk_dir>/tmk_core/tool/chibios/ch-bootloader-jump.patch
-#STM32_BOOTLOADER_ADDRESS = 0x1FFFC800
-
-# Build Options
-# comment out to disable the options.
-#
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/chibios_test/stm32_f072_onekey/mcuconf.h b/keyboards/chibios_test/stm32_f072_onekey/mcuconf.h
index 3d877aaa2b..faca3defdf 100644
--- a/keyboards/chibios_test/stm32_f072_onekey/mcuconf.h
+++ b/keyboards/chibios_test/stm32_f072_onekey/mcuconf.h
@@ -1,171 +1,171 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-#ifndef _MCUCONF_H_
-#define _MCUCONF_H_
-
-/*
- * STM32F0xx drivers configuration.
- * The following settings override the default settings present in
- * the various device driver implementation headers.
- * Note that the settings for each driver only have effect if the whole
- * driver is enabled in halconf.h.
- *
- * IRQ priorities:
- * 3...0 Lowest...Highest.
- *
- * DMA priorities:
- * 0...3 Lowest...Highest.
- */
-
-#define STM32F0xx_MCUCONF
-
-/*
- * HAL driver system settings.
- */
-#define STM32_NO_INIT FALSE
-#define STM32_PVD_ENABLE FALSE
-#define STM32_PLS STM32_PLS_LEV0
-#define STM32_HSI_ENABLED TRUE
-#define STM32_HSI14_ENABLED TRUE
-#define STM32_HSI48_ENABLED FALSE
-#define STM32_LSI_ENABLED TRUE
-#define STM32_HSE_ENABLED FALSE
-#define STM32_LSE_ENABLED FALSE
-#define STM32_SW STM32_SW_PLL
-#define STM32_PLLSRC STM32_PLLSRC_HSI_DIV2
-#define STM32_PREDIV_VALUE 1
-#define STM32_PLLMUL_VALUE 12
-#define STM32_HPRE STM32_HPRE_DIV1
-#define STM32_PPRE STM32_PPRE_DIV1
-#define STM32_ADCSW STM32_ADCSW_HSI14
-#define STM32_ADCPRE STM32_ADCPRE_DIV4
-#define STM32_MCOSEL STM32_MCOSEL_NOCLOCK
-#define STM32_ADCPRE STM32_ADCPRE_DIV4
-#define STM32_ADCSW STM32_ADCSW_HSI14
-#define STM32_USBSW STM32_USBSW_HSI48
-#define STM32_CECSW STM32_CECSW_HSI
-#define STM32_I2C1SW STM32_I2C1SW_HSI
-#define STM32_USART1SW STM32_USART1SW_PCLK
-#define STM32_RTCSEL STM32_RTCSEL_LSI
-
-/*
- * ADC driver system settings.
- */
-#define STM32_ADC_USE_ADC1 FALSE
-#define STM32_ADC_ADC1_DMA_PRIORITY 2
-#define STM32_ADC_IRQ_PRIORITY 2
-#define STM32_ADC_ADC1_DMA_IRQ_PRIORITY 2
-
-/*
- * EXT driver system settings.
- */
-#define STM32_EXT_EXTI0_1_IRQ_PRIORITY 3
-#define STM32_EXT_EXTI2_3_IRQ_PRIORITY 3
-#define STM32_EXT_EXTI4_15_IRQ_PRIORITY 3
-#define STM32_EXT_EXTI16_IRQ_PRIORITY 3
-#define STM32_EXT_EXTI17_IRQ_PRIORITY 3
-
-/*
- * GPT driver system settings.
- */
-#define STM32_GPT_USE_TIM1 FALSE
-#define STM32_GPT_USE_TIM2 FALSE
-#define STM32_GPT_USE_TIM3 FALSE
-#define STM32_GPT_USE_TIM14 FALSE
-#define STM32_GPT_TIM1_IRQ_PRIORITY 2
-#define STM32_GPT_TIM2_IRQ_PRIORITY 2
-#define STM32_GPT_TIM3_IRQ_PRIORITY 2
-#define STM32_GPT_TIM14_IRQ_PRIORITY 2
-
-/*
- * I2C driver system settings.
- */
-#define STM32_I2C_USE_I2C1 FALSE
-#define STM32_I2C_USE_I2C2 FALSE
-#define STM32_I2C_BUSY_TIMEOUT 50
-#define STM32_I2C_I2C1_IRQ_PRIORITY 3
-#define STM32_I2C_I2C2_IRQ_PRIORITY 3
-#define STM32_I2C_USE_DMA TRUE
-#define STM32_I2C_I2C1_DMA_PRIORITY 1
-#define STM32_I2C_I2C2_DMA_PRIORITY 1
-#define STM32_I2C_DMA_ERROR_HOOK(i2cp) osalSysHalt("DMA failure")
-
-/*
- * ICU driver system settings.
- */
-#define STM32_ICU_USE_TIM1 FALSE
-#define STM32_ICU_USE_TIM2 FALSE
-#define STM32_ICU_USE_TIM3 FALSE
-#define STM32_ICU_TIM1_IRQ_PRIORITY 3
-#define STM32_ICU_TIM2_IRQ_PRIORITY 3
-#define STM32_ICU_TIM3_IRQ_PRIORITY 3
-
-/*
- * PWM driver system settings.
- */
-#define STM32_PWM_USE_ADVANCED FALSE
-#define STM32_PWM_USE_TIM1 FALSE
-#define STM32_PWM_USE_TIM2 FALSE
-#define STM32_PWM_USE_TIM3 FALSE
-#define STM32_PWM_TIM1_IRQ_PRIORITY 3
-#define STM32_PWM_TIM2_IRQ_PRIORITY 3
-#define STM32_PWM_TIM3_IRQ_PRIORITY 3
-
-/*
- * SERIAL driver system settings.
- */
-#define STM32_SERIAL_USE_USART1 FALSE
-#define STM32_SERIAL_USE_USART2 FALSE
-#define STM32_SERIAL_USART1_PRIORITY 3
-#define STM32_SERIAL_USART2_PRIORITY 3
-
-/*
- * SPI driver system settings.
- */
-#define STM32_SPI_USE_SPI1 FALSE
-#define STM32_SPI_USE_SPI2 FALSE
-#define STM32_SPI_SPI1_DMA_PRIORITY 1
-#define STM32_SPI_SPI2_DMA_PRIORITY 1
-#define STM32_SPI_SPI1_IRQ_PRIORITY 2
-#define STM32_SPI_SPI2_IRQ_PRIORITY 2
-#define STM32_SPI_DMA_ERROR_HOOK(spip) osalSysHalt("DMA failure")
-
-/*
- * ST driver system settings.
- */
-#define STM32_ST_IRQ_PRIORITY 2
-#define STM32_ST_USE_TIMER 2
-
-/*
- * UART driver system settings.
- */
-#define STM32_UART_USE_USART1 FALSE
-#define STM32_UART_USE_USART2 FALSE
-#define STM32_UART_USART1_IRQ_PRIORITY 3
-#define STM32_UART_USART2_IRQ_PRIORITY 3
-#define STM32_UART_USART1_DMA_PRIORITY 0
-#define STM32_UART_USART2_DMA_PRIORITY 0
-#define STM32_UART_DMA_ERROR_HOOK(uartp) osalSysHalt("DMA failure")
-
-/*
- * USB driver system settings.
- */
-#define STM32_USB_USE_USB1 TRUE
-#define STM32_USB_LOW_POWER_ON_SUSPEND FALSE
-#define STM32_USB_USB1_LP_IRQ_PRIORITY 3
-
-#endif /* _MCUCONF_H_ */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+#ifndef _MCUCONF_H_
+#define _MCUCONF_H_
+
+/*
+ * STM32F0xx drivers configuration.
+ * The following settings override the default settings present in
+ * the various device driver implementation headers.
+ * Note that the settings for each driver only have effect if the whole
+ * driver is enabled in halconf.h.
+ *
+ * IRQ priorities:
+ * 3...0 Lowest...Highest.
+ *
+ * DMA priorities:
+ * 0...3 Lowest...Highest.
+ */
+
+#define STM32F0xx_MCUCONF
+
+/*
+ * HAL driver system settings.
+ */
+#define STM32_NO_INIT FALSE
+#define STM32_PVD_ENABLE FALSE
+#define STM32_PLS STM32_PLS_LEV0
+#define STM32_HSI_ENABLED TRUE
+#define STM32_HSI14_ENABLED TRUE
+#define STM32_HSI48_ENABLED FALSE
+#define STM32_LSI_ENABLED TRUE
+#define STM32_HSE_ENABLED FALSE
+#define STM32_LSE_ENABLED FALSE
+#define STM32_SW STM32_SW_PLL
+#define STM32_PLLSRC STM32_PLLSRC_HSI_DIV2
+#define STM32_PREDIV_VALUE 1
+#define STM32_PLLMUL_VALUE 12
+#define STM32_HPRE STM32_HPRE_DIV1
+#define STM32_PPRE STM32_PPRE_DIV1
+#define STM32_ADCSW STM32_ADCSW_HSI14
+#define STM32_ADCPRE STM32_ADCPRE_DIV4
+#define STM32_MCOSEL STM32_MCOSEL_NOCLOCK
+#define STM32_ADCPRE STM32_ADCPRE_DIV4
+#define STM32_ADCSW STM32_ADCSW_HSI14
+#define STM32_USBSW STM32_USBSW_HSI48
+#define STM32_CECSW STM32_CECSW_HSI
+#define STM32_I2C1SW STM32_I2C1SW_HSI
+#define STM32_USART1SW STM32_USART1SW_PCLK
+#define STM32_RTCSEL STM32_RTCSEL_LSI
+
+/*
+ * ADC driver system settings.
+ */
+#define STM32_ADC_USE_ADC1 FALSE
+#define STM32_ADC_ADC1_DMA_PRIORITY 2
+#define STM32_ADC_IRQ_PRIORITY 2
+#define STM32_ADC_ADC1_DMA_IRQ_PRIORITY 2
+
+/*
+ * EXT driver system settings.
+ */
+#define STM32_EXT_EXTI0_1_IRQ_PRIORITY 3
+#define STM32_EXT_EXTI2_3_IRQ_PRIORITY 3
+#define STM32_EXT_EXTI4_15_IRQ_PRIORITY 3
+#define STM32_EXT_EXTI16_IRQ_PRIORITY 3
+#define STM32_EXT_EXTI17_IRQ_PRIORITY 3
+
+/*
+ * GPT driver system settings.
+ */
+#define STM32_GPT_USE_TIM1 FALSE
+#define STM32_GPT_USE_TIM2 FALSE
+#define STM32_GPT_USE_TIM3 FALSE
+#define STM32_GPT_USE_TIM14 FALSE
+#define STM32_GPT_TIM1_IRQ_PRIORITY 2
+#define STM32_GPT_TIM2_IRQ_PRIORITY 2
+#define STM32_GPT_TIM3_IRQ_PRIORITY 2
+#define STM32_GPT_TIM14_IRQ_PRIORITY 2
+
+/*
+ * I2C driver system settings.
+ */
+#define STM32_I2C_USE_I2C1 FALSE
+#define STM32_I2C_USE_I2C2 FALSE
+#define STM32_I2C_BUSY_TIMEOUT 50
+#define STM32_I2C_I2C1_IRQ_PRIORITY 3
+#define STM32_I2C_I2C2_IRQ_PRIORITY 3
+#define STM32_I2C_USE_DMA TRUE
+#define STM32_I2C_I2C1_DMA_PRIORITY 1
+#define STM32_I2C_I2C2_DMA_PRIORITY 1
+#define STM32_I2C_DMA_ERROR_HOOK(i2cp) osalSysHalt("DMA failure")
+
+/*
+ * ICU driver system settings.
+ */
+#define STM32_ICU_USE_TIM1 FALSE
+#define STM32_ICU_USE_TIM2 FALSE
+#define STM32_ICU_USE_TIM3 FALSE
+#define STM32_ICU_TIM1_IRQ_PRIORITY 3
+#define STM32_ICU_TIM2_IRQ_PRIORITY 3
+#define STM32_ICU_TIM3_IRQ_PRIORITY 3
+
+/*
+ * PWM driver system settings.
+ */
+#define STM32_PWM_USE_ADVANCED FALSE
+#define STM32_PWM_USE_TIM1 FALSE
+#define STM32_PWM_USE_TIM2 FALSE
+#define STM32_PWM_USE_TIM3 FALSE
+#define STM32_PWM_TIM1_IRQ_PRIORITY 3
+#define STM32_PWM_TIM2_IRQ_PRIORITY 3
+#define STM32_PWM_TIM3_IRQ_PRIORITY 3
+
+/*
+ * SERIAL driver system settings.
+ */
+#define STM32_SERIAL_USE_USART1 FALSE
+#define STM32_SERIAL_USE_USART2 FALSE
+#define STM32_SERIAL_USART1_PRIORITY 3
+#define STM32_SERIAL_USART2_PRIORITY 3
+
+/*
+ * SPI driver system settings.
+ */
+#define STM32_SPI_USE_SPI1 FALSE
+#define STM32_SPI_USE_SPI2 FALSE
+#define STM32_SPI_SPI1_DMA_PRIORITY 1
+#define STM32_SPI_SPI2_DMA_PRIORITY 1
+#define STM32_SPI_SPI1_IRQ_PRIORITY 2
+#define STM32_SPI_SPI2_IRQ_PRIORITY 2
+#define STM32_SPI_DMA_ERROR_HOOK(spip) osalSysHalt("DMA failure")
+
+/*
+ * ST driver system settings.
+ */
+#define STM32_ST_IRQ_PRIORITY 2
+#define STM32_ST_USE_TIMER 2
+
+/*
+ * UART driver system settings.
+ */
+#define STM32_UART_USE_USART1 FALSE
+#define STM32_UART_USE_USART2 FALSE
+#define STM32_UART_USART1_IRQ_PRIORITY 3
+#define STM32_UART_USART2_IRQ_PRIORITY 3
+#define STM32_UART_USART1_DMA_PRIORITY 0
+#define STM32_UART_USART2_DMA_PRIORITY 0
+#define STM32_UART_DMA_ERROR_HOOK(uartp) osalSysHalt("DMA failure")
+
+/*
+ * USB driver system settings.
+ */
+#define STM32_USB_USE_USB1 TRUE
+#define STM32_USB_LOW_POWER_ON_SUSPEND FALSE
+#define STM32_USB_USB1_LP_IRQ_PRIORITY 3
+
+#endif /* _MCUCONF_H_ */
diff --git a/keyboards/chibios_test/stm32_f072_onekey/rules.mk b/keyboards/chibios_test/stm32_f072_onekey/rules.mk
new file mode 100644
index 0000000000..eae38c4b2b
--- /dev/null
+++ b/keyboards/chibios_test/stm32_f072_onekey/rules.mk
@@ -0,0 +1,41 @@
+# project specific files
+SRC = matrix.c \
+ led.c
+
+## chip/board settings
+# the next two should match the directories in
+# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
+MCU_FAMILY = STM32
+MCU_SERIES = STM32F0xx
+# linker script to use
+# it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
+# or <this_dir>/ld/
+MCU_LDSCRIPT = STM32F072xB
+# startup code to use
+# is should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
+MCU_STARTUP = stm32f0xx
+# it should exist either in <chibios>/os/hal/boards/
+# or <this_dir>/boards
+BOARD = ST_STM32F072B_DISCOVERY
+# Cortex version
+# Teensy LC is cortex-m0; Teensy 3.x are cortex-m4
+MCU = cortex-m0
+# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
+ARMV = 6
+# If you want to be able to jump to bootloader from firmware on STM32 MCUs,
+# set the correct BOOTLOADER_ADDRESS. Either set it here, or define it in
+# ./bootloader_defs.h or in ./boards/<FOO>/bootloader_defs.h (if you have
+# a custom board definition that you plan to reuse).
+# If you're not setting it here, leave it commented out.
+# It is chip dependent, the correct number can be looked up here (page 175):
+# http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf
+# This also requires a patch to chibios:
+# <tmk_dir>/tmk_core/tool/chibios/ch-bootloader-jump.patch
+#STM32_BOOTLOADER_ADDRESS = 0x1FFFC800
+
+# Build Options
+# comment out to disable the options.
+#
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
diff --git a/keyboards/chibios_test/stm32_f103_onekey/Makefile b/keyboards/chibios_test/stm32_f103_onekey/Makefile
index 307ca5b198..191c6bb664 100644
--- a/keyboards/chibios_test/stm32_f103_onekey/Makefile
+++ b/keyboards/chibios_test/stm32_f103_onekey/Makefile
@@ -1,52 +1,3 @@
-# project specific files
-SRC = matrix.c \
- led.c
-
-# GENERIC STM32F103C8T6 board - stm32duino bootloader
-OPT_DEFS = -DCORTEX_VTOR_INIT=0x2000
-MCU_LDSCRIPT = STM32F103x8_stm32duino_bootloader
-BOARD = GENERIC_STM32_F103
-
-# GENERIC STM32F103C8T6 board - no bootloader (programmer over serial or SWD)
-# OPT_DEFS =
-# MCU_LDSCRIPT = STM32F103x8
-# BOARD = GENERIC_STM32_F103
-
-# MAPLE MINI
-# OPT_DEFS = -DCORTEX_VTOR_INIT=0x5000
-# MCU_LDSCRIPT = STM32F103xB_maplemini_bootloader
-# BOARD = MAPLEMINI_STM32_F103
-
-## chip/board settings
-# the next two should match the directories in
-# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
-MCU_FAMILY = STM32
-MCU_SERIES = STM32F1xx
-# linker script to use
-# it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
-# or <this_dir>/ld/
-# startup code to use
-# is should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
-MCU_STARTUP = stm32f1xx
-# it should exist either in <chibios>/os/hal/boards/
-# or <this_dir>/boards
-# Cortex version
-# Teensy LC is cortex-m0; Teensy 3.x are cortex-m4
-MCU = cortex-m3
-# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
-ARMV = 7
-# If you want to be able to jump to bootloader from firmware on STM32 MCUs,
-# set the correct BOOTLOADER_ADDRESS. Either set it here, or define it in
-# ./bootloader_defs.h or in ./boards/<FOO>/bootloader_defs.h (if you have
-# a custom board definition that you plan to reuse).
-# If you're not setting it here, leave it commented out.
-# It is chip dependent, the correct number can be looked up here (page 175):
-# http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf
-# This also requires a patch to chibios:
-# <tmk_dir>/tmk_core/tool/chibios/ch-bootloader-jump.patch
-#STM32_BOOTLOADER_ADDRESS = 0x1FFFC800
-
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/chibios_test/stm32_f103_onekey/mcuconf.h b/keyboards/chibios_test/stm32_f103_onekey/mcuconf.h
index 626332a6aa..276829216e 100644
--- a/keyboards/chibios_test/stm32_f103_onekey/mcuconf.h
+++ b/keyboards/chibios_test/stm32_f103_onekey/mcuconf.h
@@ -1,209 +1,209 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-#ifndef _MCUCONF_H_
-#define _MCUCONF_H_
-
-#define STM32F103_MCUCONF
-
-/*
- * STM32F103 drivers configuration.
- * The following settings override the default settings present in
- * the various device driver implementation headers.
- * Note that the settings for each driver only have effect if the whole
- * driver is enabled in halconf.h.
- *
- * IRQ priorities:
- * 15...0 Lowest...Highest.
- *
- * DMA priorities:
- * 0...3 Lowest...Highest.
- */
-
-/*
- * HAL driver system settings.
- */
-#define STM32_NO_INIT FALSE
-#define STM32_HSI_ENABLED TRUE
-#define STM32_LSI_ENABLED FALSE
-#define STM32_HSE_ENABLED TRUE
-#define STM32_LSE_ENABLED FALSE
-#define STM32_SW STM32_SW_PLL
-#define STM32_PLLSRC STM32_PLLSRC_HSE
-#define STM32_PLLXTPRE STM32_PLLXTPRE_DIV1
-#define STM32_PLLMUL_VALUE 9
-#define STM32_HPRE STM32_HPRE_DIV1
-#define STM32_PPRE1 STM32_PPRE1_DIV2
-#define STM32_PPRE2 STM32_PPRE2_DIV2
-#define STM32_ADCPRE STM32_ADCPRE_DIV4
-#define STM32_USB_CLOCK_REQUIRED TRUE
-#define STM32_USBPRE STM32_USBPRE_DIV1P5
-#define STM32_MCOSEL STM32_MCOSEL_NOCLOCK
-#define STM32_RTCSEL STM32_RTCSEL_HSEDIV
-#define STM32_PVD_ENABLE FALSE
-#define STM32_PLS STM32_PLS_LEV0
-
-/*
- * ADC driver system settings.
- */
-#define STM32_ADC_USE_ADC1 FALSE
-#define STM32_ADC_ADC1_DMA_PRIORITY 2
-#define STM32_ADC_ADC1_IRQ_PRIORITY 6
-
-/*
- * CAN driver system settings.
- */
-#define STM32_CAN_USE_CAN1 FALSE
-#define STM32_CAN_CAN1_IRQ_PRIORITY 11
-
-/*
- * EXT driver system settings.
- */
-#define STM32_EXT_EXTI0_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI1_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI2_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI3_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI4_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI5_9_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI10_15_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI16_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI17_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI18_IRQ_PRIORITY 6
-#define STM32_EXT_EXTI19_IRQ_PRIORITY 6
-
-/*
- * GPT driver system settings.
- */
-#define STM32_GPT_USE_TIM1 FALSE
-#define STM32_GPT_USE_TIM2 FALSE
-#define STM32_GPT_USE_TIM3 FALSE
-#define STM32_GPT_USE_TIM4 FALSE
-#define STM32_GPT_USE_TIM5 FALSE
-#define STM32_GPT_USE_TIM8 FALSE
-#define STM32_GPT_TIM1_IRQ_PRIORITY 7
-#define STM32_GPT_TIM2_IRQ_PRIORITY 7
-#define STM32_GPT_TIM3_IRQ_PRIORITY 7
-#define STM32_GPT_TIM4_IRQ_PRIORITY 7
-#define STM32_GPT_TIM5_IRQ_PRIORITY 7
-#define STM32_GPT_TIM8_IRQ_PRIORITY 7
-
-/*
- * I2C driver system settings.
- */
-#define STM32_I2C_USE_I2C1 FALSE
-#define STM32_I2C_USE_I2C2 FALSE
-#define STM32_I2C_BUSY_TIMEOUT 50
-#define STM32_I2C_I2C1_IRQ_PRIORITY 5
-#define STM32_I2C_I2C2_IRQ_PRIORITY 5
-#define STM32_I2C_I2C1_DMA_PRIORITY 3
-#define STM32_I2C_I2C2_DMA_PRIORITY 3
-#define STM32_I2C_DMA_ERROR_HOOK(i2cp) osalSysHalt("DMA failure")
-
-/*
- * ICU driver system settings.
- */
-#define STM32_ICU_USE_TIM1 FALSE
-#define STM32_ICU_USE_TIM2 FALSE
-#define STM32_ICU_USE_TIM3 FALSE
-#define STM32_ICU_USE_TIM4 FALSE
-#define STM32_ICU_USE_TIM5 FALSE
-#define STM32_ICU_USE_TIM8 FALSE
-#define STM32_ICU_TIM1_IRQ_PRIORITY 7
-#define STM32_ICU_TIM2_IRQ_PRIORITY 7
-#define STM32_ICU_TIM3_IRQ_PRIORITY 7
-#define STM32_ICU_TIM4_IRQ_PRIORITY 7
-#define STM32_ICU_TIM5_IRQ_PRIORITY 7
-#define STM32_ICU_TIM8_IRQ_PRIORITY 7
-
-/*
- * PWM driver system settings.
- */
-#define STM32_PWM_USE_ADVANCED FALSE
-#define STM32_PWM_USE_TIM1 FALSE
-#define STM32_PWM_USE_TIM2 FALSE
-#define STM32_PWM_USE_TIM3 FALSE
-#define STM32_PWM_USE_TIM4 FALSE
-#define STM32_PWM_USE_TIM5 FALSE
-#define STM32_PWM_USE_TIM8 FALSE
-#define STM32_PWM_TIM1_IRQ_PRIORITY 7
-#define STM32_PWM_TIM2_IRQ_PRIORITY 7
-#define STM32_PWM_TIM3_IRQ_PRIORITY 7
-#define STM32_PWM_TIM4_IRQ_PRIORITY 7
-#define STM32_PWM_TIM5_IRQ_PRIORITY 7
-#define STM32_PWM_TIM8_IRQ_PRIORITY 7
-
-/*
- * RTC driver system settings.
- */
-#define STM32_RTC_IRQ_PRIORITY 15
-
-/*
- * SERIAL driver system settings.
- */
-#define STM32_SERIAL_USE_USART1 FALSE
-#define STM32_SERIAL_USE_USART2 FALSE
-#define STM32_SERIAL_USE_USART3 FALSE
-#define STM32_SERIAL_USE_UART4 FALSE
-#define STM32_SERIAL_USE_UART5 FALSE
-#define STM32_SERIAL_USART1_PRIORITY 12
-#define STM32_SERIAL_USART2_PRIORITY 12
-#define STM32_SERIAL_USART3_PRIORITY 12
-#define STM32_SERIAL_UART4_PRIORITY 12
-#define STM32_SERIAL_UART5_PRIORITY 12
-
-/*
- * SPI driver system settings.
- */
-#define STM32_SPI_USE_SPI1 FALSE
-#define STM32_SPI_USE_SPI2 FALSE
-#define STM32_SPI_USE_SPI3 FALSE
-#define STM32_SPI_SPI1_DMA_PRIORITY 1
-#define STM32_SPI_SPI2_DMA_PRIORITY 1
-#define STM32_SPI_SPI3_DMA_PRIORITY 1
-#define STM32_SPI_SPI1_IRQ_PRIORITY 10
-#define STM32_SPI_SPI2_IRQ_PRIORITY 10
-#define STM32_SPI_SPI3_IRQ_PRIORITY 10
-#define STM32_SPI_DMA_ERROR_HOOK(spip) osalSysHalt("DMA failure")
-
-/*
- * ST driver system settings.
- */
-#define STM32_ST_IRQ_PRIORITY 8
-#define STM32_ST_USE_TIMER 2
-
-/*
- * UART driver system settings.
- */
-#define STM32_UART_USE_USART1 FALSE
-#define STM32_UART_USE_USART2 FALSE
-#define STM32_UART_USE_USART3 FALSE
-#define STM32_UART_USART1_IRQ_PRIORITY 12
-#define STM32_UART_USART2_IRQ_PRIORITY 12
-#define STM32_UART_USART3_IRQ_PRIORITY 12
-#define STM32_UART_USART1_DMA_PRIORITY 0
-#define STM32_UART_USART2_DMA_PRIORITY 0
-#define STM32_UART_USART3_DMA_PRIORITY 0
-#define STM32_UART_DMA_ERROR_HOOK(uartp) osalSysHalt("DMA failure")
-
-/*
- * USB driver system settings.
- */
-#define STM32_USB_USE_USB1 TRUE
-#define STM32_USB_LOW_POWER_ON_SUSPEND FALSE
-#define STM32_USB_USB1_HP_IRQ_PRIORITY 13
-#define STM32_USB_USB1_LP_IRQ_PRIORITY 14
-
-#endif /* _MCUCONF_H_ */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+#ifndef _MCUCONF_H_
+#define _MCUCONF_H_
+
+#define STM32F103_MCUCONF
+
+/*
+ * STM32F103 drivers configuration.
+ * The following settings override the default settings present in
+ * the various device driver implementation headers.
+ * Note that the settings for each driver only have effect if the whole
+ * driver is enabled in halconf.h.
+ *
+ * IRQ priorities:
+ * 15...0 Lowest...Highest.
+ *
+ * DMA priorities:
+ * 0...3 Lowest...Highest.
+ */
+
+/*
+ * HAL driver system settings.
+ */
+#define STM32_NO_INIT FALSE
+#define STM32_HSI_ENABLED TRUE
+#define STM32_LSI_ENABLED FALSE
+#define STM32_HSE_ENABLED TRUE
+#define STM32_LSE_ENABLED FALSE
+#define STM32_SW STM32_SW_PLL
+#define STM32_PLLSRC STM32_PLLSRC_HSE
+#define STM32_PLLXTPRE STM32_PLLXTPRE_DIV1
+#define STM32_PLLMUL_VALUE 9
+#define STM32_HPRE STM32_HPRE_DIV1
+#define STM32_PPRE1 STM32_PPRE1_DIV2
+#define STM32_PPRE2 STM32_PPRE2_DIV2
+#define STM32_ADCPRE STM32_ADCPRE_DIV4
+#define STM32_USB_CLOCK_REQUIRED TRUE
+#define STM32_USBPRE STM32_USBPRE_DIV1P5
+#define STM32_MCOSEL STM32_MCOSEL_NOCLOCK
+#define STM32_RTCSEL STM32_RTCSEL_HSEDIV
+#define STM32_PVD_ENABLE FALSE
+#define STM32_PLS STM32_PLS_LEV0
+
+/*
+ * ADC driver system settings.
+ */
+#define STM32_ADC_USE_ADC1 FALSE
+#define STM32_ADC_ADC1_DMA_PRIORITY 2
+#define STM32_ADC_ADC1_IRQ_PRIORITY 6
+
+/*
+ * CAN driver system settings.
+ */
+#define STM32_CAN_USE_CAN1 FALSE
+#define STM32_CAN_CAN1_IRQ_PRIORITY 11
+
+/*
+ * EXT driver system settings.
+ */
+#define STM32_EXT_EXTI0_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI1_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI2_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI3_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI4_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI5_9_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI10_15_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI16_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI17_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI18_IRQ_PRIORITY 6
+#define STM32_EXT_EXTI19_IRQ_PRIORITY 6
+
+/*
+ * GPT driver system settings.
+ */
+#define STM32_GPT_USE_TIM1 FALSE
+#define STM32_GPT_USE_TIM2 FALSE
+#define STM32_GPT_USE_TIM3 FALSE
+#define STM32_GPT_USE_TIM4 FALSE
+#define STM32_GPT_USE_TIM5 FALSE
+#define STM32_GPT_USE_TIM8 FALSE
+#define STM32_GPT_TIM1_IRQ_PRIORITY 7
+#define STM32_GPT_TIM2_IRQ_PRIORITY 7
+#define STM32_GPT_TIM3_IRQ_PRIORITY 7
+#define STM32_GPT_TIM4_IRQ_PRIORITY 7
+#define STM32_GPT_TIM5_IRQ_PRIORITY 7
+#define STM32_GPT_TIM8_IRQ_PRIORITY 7
+
+/*
+ * I2C driver system settings.
+ */
+#define STM32_I2C_USE_I2C1 FALSE
+#define STM32_I2C_USE_I2C2 FALSE
+#define STM32_I2C_BUSY_TIMEOUT 50
+#define STM32_I2C_I2C1_IRQ_PRIORITY 5
+#define STM32_I2C_I2C2_IRQ_PRIORITY 5
+#define STM32_I2C_I2C1_DMA_PRIORITY 3
+#define STM32_I2C_I2C2_DMA_PRIORITY 3
+#define STM32_I2C_DMA_ERROR_HOOK(i2cp) osalSysHalt("DMA failure")
+
+/*
+ * ICU driver system settings.
+ */
+#define STM32_ICU_USE_TIM1 FALSE
+#define STM32_ICU_USE_TIM2 FALSE
+#define STM32_ICU_USE_TIM3 FALSE
+#define STM32_ICU_USE_TIM4 FALSE
+#define STM32_ICU_USE_TIM5 FALSE
+#define STM32_ICU_USE_TIM8 FALSE
+#define STM32_ICU_TIM1_IRQ_PRIORITY 7
+#define STM32_ICU_TIM2_IRQ_PRIORITY 7
+#define STM32_ICU_TIM3_IRQ_PRIORITY 7
+#define STM32_ICU_TIM4_IRQ_PRIORITY 7
+#define STM32_ICU_TIM5_IRQ_PRIORITY 7
+#define STM32_ICU_TIM8_IRQ_PRIORITY 7
+
+/*
+ * PWM driver system settings.
+ */
+#define STM32_PWM_USE_ADVANCED FALSE
+#define STM32_PWM_USE_TIM1 FALSE
+#define STM32_PWM_USE_TIM2 FALSE
+#define STM32_PWM_USE_TIM3 FALSE
+#define STM32_PWM_USE_TIM4 FALSE
+#define STM32_PWM_USE_TIM5 FALSE
+#define STM32_PWM_USE_TIM8 FALSE
+#define STM32_PWM_TIM1_IRQ_PRIORITY 7
+#define STM32_PWM_TIM2_IRQ_PRIORITY 7
+#define STM32_PWM_TIM3_IRQ_PRIORITY 7
+#define STM32_PWM_TIM4_IRQ_PRIORITY 7
+#define STM32_PWM_TIM5_IRQ_PRIORITY 7
+#define STM32_PWM_TIM8_IRQ_PRIORITY 7
+
+/*
+ * RTC driver system settings.
+ */
+#define STM32_RTC_IRQ_PRIORITY 15
+
+/*
+ * SERIAL driver system settings.
+ */
+#define STM32_SERIAL_USE_USART1 FALSE
+#define STM32_SERIAL_USE_USART2 FALSE
+#define STM32_SERIAL_USE_USART3 FALSE
+#define STM32_SERIAL_USE_UART4 FALSE
+#define STM32_SERIAL_USE_UART5 FALSE
+#define STM32_SERIAL_USART1_PRIORITY 12
+#define STM32_SERIAL_USART2_PRIORITY 12
+#define STM32_SERIAL_USART3_PRIORITY 12
+#define STM32_SERIAL_UART4_PRIORITY 12
+#define STM32_SERIAL_UART5_PRIORITY 12
+
+/*
+ * SPI driver system settings.
+ */
+#define STM32_SPI_USE_SPI1 FALSE
+#define STM32_SPI_USE_SPI2 FALSE
+#define STM32_SPI_USE_SPI3 FALSE
+#define STM32_SPI_SPI1_DMA_PRIORITY 1
+#define STM32_SPI_SPI2_DMA_PRIORITY 1
+#define STM32_SPI_SPI3_DMA_PRIORITY 1
+#define STM32_SPI_SPI1_IRQ_PRIORITY 10
+#define STM32_SPI_SPI2_IRQ_PRIORITY 10
+#define STM32_SPI_SPI3_IRQ_PRIORITY 10
+#define STM32_SPI_DMA_ERROR_HOOK(spip) osalSysHalt("DMA failure")
+
+/*
+ * ST driver system settings.
+ */
+#define STM32_ST_IRQ_PRIORITY 8
+#define STM32_ST_USE_TIMER 2
+
+/*
+ * UART driver system settings.
+ */
+#define STM32_UART_USE_USART1 FALSE
+#define STM32_UART_USE_USART2 FALSE
+#define STM32_UART_USE_USART3 FALSE
+#define STM32_UART_USART1_IRQ_PRIORITY 12
+#define STM32_UART_USART2_IRQ_PRIORITY 12
+#define STM32_UART_USART3_IRQ_PRIORITY 12
+#define STM32_UART_USART1_DMA_PRIORITY 0
+#define STM32_UART_USART2_DMA_PRIORITY 0
+#define STM32_UART_USART3_DMA_PRIORITY 0
+#define STM32_UART_DMA_ERROR_HOOK(uartp) osalSysHalt("DMA failure")
+
+/*
+ * USB driver system settings.
+ */
+#define STM32_USB_USE_USB1 TRUE
+#define STM32_USB_LOW_POWER_ON_SUSPEND FALSE
+#define STM32_USB_USB1_HP_IRQ_PRIORITY 13
+#define STM32_USB_USB1_LP_IRQ_PRIORITY 14
+
+#endif /* _MCUCONF_H_ */
diff --git a/keyboards/chibios_test/stm32_f103_onekey/rules.mk b/keyboards/chibios_test/stm32_f103_onekey/rules.mk
new file mode 100644
index 0000000000..307ca5b198
--- /dev/null
+++ b/keyboards/chibios_test/stm32_f103_onekey/rules.mk
@@ -0,0 +1,52 @@
+# project specific files
+SRC = matrix.c \
+ led.c
+
+# GENERIC STM32F103C8T6 board - stm32duino bootloader
+OPT_DEFS = -DCORTEX_VTOR_INIT=0x2000
+MCU_LDSCRIPT = STM32F103x8_stm32duino_bootloader
+BOARD = GENERIC_STM32_F103
+
+# GENERIC STM32F103C8T6 board - no bootloader (programmer over serial or SWD)
+# OPT_DEFS =
+# MCU_LDSCRIPT = STM32F103x8
+# BOARD = GENERIC_STM32_F103
+
+# MAPLE MINI
+# OPT_DEFS = -DCORTEX_VTOR_INIT=0x5000
+# MCU_LDSCRIPT = STM32F103xB_maplemini_bootloader
+# BOARD = MAPLEMINI_STM32_F103
+
+## chip/board settings
+# the next two should match the directories in
+# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
+MCU_FAMILY = STM32
+MCU_SERIES = STM32F1xx
+# linker script to use
+# it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
+# or <this_dir>/ld/
+# startup code to use
+# is should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
+MCU_STARTUP = stm32f1xx
+# it should exist either in <chibios>/os/hal/boards/
+# or <this_dir>/boards
+# Cortex version
+# Teensy LC is cortex-m0; Teensy 3.x are cortex-m4
+MCU = cortex-m3
+# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
+ARMV = 7
+# If you want to be able to jump to bootloader from firmware on STM32 MCUs,
+# set the correct BOOTLOADER_ADDRESS. Either set it here, or define it in
+# ./bootloader_defs.h or in ./boards/<FOO>/bootloader_defs.h (if you have
+# a custom board definition that you plan to reuse).
+# If you're not setting it here, leave it commented out.
+# It is chip dependent, the correct number can be looked up here (page 175):
+# http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf
+# This also requires a patch to chibios:
+# <tmk_dir>/tmk_core/tool/chibios/ch-bootloader-jump.patch
+#STM32_BOOTLOADER_ADDRESS = 0x1FFFC800
+
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
diff --git a/keyboards/chibios_test/teensy_lc_onekey/Makefile b/keyboards/chibios_test/teensy_lc_onekey/Makefile
index 43ea9d82d9..191c6bb664 100644
--- a/keyboards/chibios_test/teensy_lc_onekey/Makefile
+++ b/keyboards/chibios_test/teensy_lc_onekey/Makefile
@@ -1,49 +1,3 @@
-# project specific files
-SRC = matrix.c \
- led.c
-
-## chip/board settings
-# - the next two should match the directories in
-# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
-# - For Teensies, FAMILY = KINETIS and SERIES is either
-# KL2x (LC) or K20x (3.0,3.1,3.2).
-MCU_FAMILY = KINETIS
-MCU_SERIES = KL2x
-
-# Linker script to use
-# - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
-# or <this_dir>/ld/
-# - NOTE: a custom ld script is needed for EEPROM on Teensy LC
-# - LDSCRIPT =
-# - MKL26Z64 for Teensy LC
-# - MK20DX128 for Teensy 3.0
-# - MK20DX256 for Teensy 3.1 and 3.2
-MCU_LDSCRIPT = MKL26Z64
-
-# Startup code to use
-# - it should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
-# - STARTUP =
-# - kl2x for Teensy LC
-# - k20x5 for Teensy 3.0
-# - k20x7 for Teensy 3.1 and 3.2
-MCU_STARTUP = kl2x
-
-# Board: it should exist either in <chibios>/os/hal/boards/
-# or <this_dir>/boards
-# - BOARD =
-# - PJRC_TEENSY_LC for Teensy LC
-# - PJRC_TEENSY_3 for Teensy 3.0
-# - PJRC_TEENSY_3_1 for Teensy 3.1 or 3.2
-BOARD = PJRC_TEENSY_LC
-
-# Cortex version
-# Teensy LC is cortex-m0plus; Teensy 3.x are cortex-m4
-MCU = cortex-m0plus
-
-# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
-# I.e. 6 for Teensy LC; 7 for Teensy 3.x
-ARMV = 6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/chibios_test/teensy_lc_onekey/chconf.h b/keyboards/chibios_test/teensy_lc_onekey/chconf.h
index cb36996c33..3294ac7eee 100644
--- a/keyboards/chibios_test/teensy_lc_onekey/chconf.h
+++ b/keyboards/chibios_test/teensy_lc_onekey/chconf.h
@@ -1,524 +1,524 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-/**
- * @file templates/chconf.h
- * @brief Configuration file template.
- * @details A copy of this file must be placed in each project directory, it
- * contains the application specific kernel settings.
- *
- * @addtogroup config
- * @details Kernel related settings and hooks.
- * @{
- */
-
-#ifndef CHCONF_H
-#define CHCONF_H
-
-#define _CHIBIOS_RT_CONF_
-
-/*===========================================================================*/
-/**
- * @name System timers settings
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief System time counter resolution.
- * @note Allowed values are 16 or 32 bits.
- */
-#define CH_CFG_ST_RESOLUTION 32
-
-/**
- * @brief System tick frequency.
- * @details Frequency of the system timer that drives the system ticks. This
- * setting also defines the system tick time unit.
- */
-#define CH_CFG_ST_FREQUENCY 1000
-
-/**
- * @brief Time delta constant for the tick-less mode.
- * @note If this value is zero then the system uses the classic
- * periodic tick. This value represents the minimum number
- * of ticks that is safe to specify in a timeout directive.
- * The value one is not valid, timeouts are rounded up to
- * this value.
- */
-#define CH_CFG_ST_TIMEDELTA 0
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Kernel parameters and options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Round robin interval.
- * @details This constant is the number of system ticks allowed for the
- * threads before preemption occurs. Setting this value to zero
- * disables the preemption for threads with equal priority and the
- * round robin becomes cooperative. Note that higher priority
- * threads can still preempt, the kernel is always preemptive.
- * @note Disabling the round robin preemption makes the kernel more compact
- * and generally faster.
- * @note The round robin preemption is not supported in tickless mode and
- * must be set to zero in that case.
- */
-#define CH_CFG_TIME_QUANTUM 20
-
-/**
- * @brief Managed RAM size.
- * @details Size of the RAM area to be managed by the OS. If set to zero
- * then the whole available RAM is used. The core memory is made
- * available to the heap allocator and/or can be used directly through
- * the simplified core memory allocator.
- *
- * @note In order to let the OS manage the whole RAM the linker script must
- * provide the @p __heap_base__ and @p __heap_end__ symbols.
- * @note Requires @p CH_CFG_USE_MEMCORE.
- */
-#define CH_CFG_MEMCORE_SIZE 0
-
-/**
- * @brief Idle thread automatic spawn suppression.
- * @details When this option is activated the function @p chSysInit()
- * does not spawn the idle thread. The application @p main()
- * function becomes the idle thread and must implement an
- * infinite loop.
- */
-#define CH_CFG_NO_IDLE_THREAD FALSE
-
-/* Use __WFI in the idle thread for waiting. Does lower the power
- * consumption. */
-#define CORTEX_ENABLE_WFI_IDLE TRUE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Performance options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief OS optimization.
- * @details If enabled then time efficient rather than space efficient code
- * is used when two possible implementations exist.
- *
- * @note This is not related to the compiler optimization options.
- * @note The default is @p TRUE.
- */
-#define CH_CFG_OPTIMIZE_SPEED TRUE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Subsystem options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Time Measurement APIs.
- * @details If enabled then the time measurement APIs are included in
- * the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_TM FALSE
-
-/**
- * @brief Threads registry APIs.
- * @details If enabled then the registry APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_REGISTRY TRUE
-
-/**
- * @brief Threads synchronization APIs.
- * @details If enabled then the @p chThdWait() function is included in
- * the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_WAITEXIT TRUE
-
-/**
- * @brief Semaphores APIs.
- * @details If enabled then the Semaphores APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_SEMAPHORES TRUE
-
-/**
- * @brief Semaphores queuing mode.
- * @details If enabled then the threads are enqueued on semaphores by
- * priority rather than in FIFO order.
- *
- * @note The default is @p FALSE. Enable this if you have special
- * requirements.
- * @note Requires @p CH_CFG_USE_SEMAPHORES.
- */
-#define CH_CFG_USE_SEMAPHORES_PRIORITY FALSE
-
-/**
- * @brief Mutexes APIs.
- * @details If enabled then the mutexes APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MUTEXES TRUE
-
-/**
- * @brief Enables recursive behavior on mutexes.
- * @note Recursive mutexes are heavier and have an increased
- * memory footprint.
- *
- * @note The default is @p FALSE.
- * @note Requires @p CH_CFG_USE_MUTEXES.
- */
-#define CH_CFG_USE_MUTEXES_RECURSIVE FALSE
-
-/**
- * @brief Conditional Variables APIs.
- * @details If enabled then the conditional variables APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_MUTEXES.
- */
-#define CH_CFG_USE_CONDVARS TRUE
-
-/**
- * @brief Conditional Variables APIs with timeout.
- * @details If enabled then the conditional variables APIs with timeout
- * specification are included in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_CONDVARS.
- */
-#define CH_CFG_USE_CONDVARS_TIMEOUT TRUE
-
-/**
- * @brief Events Flags APIs.
- * @details If enabled then the event flags APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_EVENTS TRUE
-
-/**
- * @brief Events Flags APIs with timeout.
- * @details If enabled then the events APIs with timeout specification
- * are included in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_EVENTS.
- */
-#define CH_CFG_USE_EVENTS_TIMEOUT TRUE
-
-/**
- * @brief Synchronous Messages APIs.
- * @details If enabled then the synchronous messages APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MESSAGES TRUE
-
-/**
- * @brief Synchronous Messages queuing mode.
- * @details If enabled then messages are served by priority rather than in
- * FIFO order.
- *
- * @note The default is @p FALSE. Enable this if you have special
- * requirements.
- * @note Requires @p CH_CFG_USE_MESSAGES.
- */
-#define CH_CFG_USE_MESSAGES_PRIORITY FALSE
-
-/**
- * @brief Mailboxes APIs.
- * @details If enabled then the asynchronous messages (mailboxes) APIs are
- * included in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_SEMAPHORES.
- */
-#define CH_CFG_USE_MAILBOXES TRUE
-
-/**
- * @brief Core Memory Manager APIs.
- * @details If enabled then the core memory manager APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MEMCORE TRUE
-
-/**
- * @brief Heap Allocator APIs.
- * @details If enabled then the memory heap allocator APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_MEMCORE and either @p CH_CFG_USE_MUTEXES or
- * @p CH_CFG_USE_SEMAPHORES.
- * @note Mutexes are recommended.
- */
-#define CH_CFG_USE_HEAP TRUE
-
-/**
- * @brief Memory Pools Allocator APIs.
- * @details If enabled then the memory pools allocator APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MEMPOOLS TRUE
-
-/**
- * @brief Dynamic Threads APIs.
- * @details If enabled then the dynamic threads creation APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_WAITEXIT.
- * @note Requires @p CH_CFG_USE_HEAP and/or @p CH_CFG_USE_MEMPOOLS.
- */
-#define CH_CFG_USE_DYNAMIC TRUE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Debug options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Debug option, kernel statistics.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_STATISTICS FALSE
-
-/**
- * @brief Debug option, system state check.
- * @details If enabled the correct call protocol for system APIs is checked
- * at runtime.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_SYSTEM_STATE_CHECK TRUE
-
-/**
- * @brief Debug option, parameters checks.
- * @details If enabled then the checks on the API functions input
- * parameters are activated.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_ENABLE_CHECKS TRUE
-
-/**
- * @brief Debug option, consistency checks.
- * @details If enabled then all the assertions in the kernel code are
- * activated. This includes consistency checks inside the kernel,
- * runtime anomalies and port-defined checks.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_ENABLE_ASSERTS TRUE
-
-/**
- * @brief Debug option, trace buffer.
- * @details If enabled then the trace buffer is activated.
- *
- * @note The default is @p CH_DBG_TRACE_MASK_DISABLED.
- */
-#define CH_DBG_TRACE_MASK CH_DBG_TRACE_MASK_DISABLED
-
-/**
- * @brief Trace buffer entries.
- * @note The trace buffer is only allocated if @p CH_DBG_TRACE_MASK is
- * different from @p CH_DBG_TRACE_MASK_DISABLED.
- */
-#define CH_DBG_TRACE_BUFFER_SIZE 128
-
-/**
- * @brief Debug option, stack checks.
- * @details If enabled then a runtime stack check is performed.
- *
- * @note The default is @p FALSE.
- * @note The stack check is performed in a architecture/port dependent way.
- * It may not be implemented or some ports.
- * @note The default failure mode is to halt the system with the global
- * @p panic_msg variable set to @p NULL.
- */
-#define CH_DBG_ENABLE_STACK_CHECK TRUE
-
-/**
- * @brief Debug option, stacks initialization.
- * @details If enabled then the threads working area is filled with a byte
- * value when a thread is created. This can be useful for the
- * runtime measurement of the used stack.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_FILL_THREADS TRUE
-
-/**
- * @brief Debug option, threads profiling.
- * @details If enabled then a field is added to the @p thread_t structure that
- * counts the system ticks occurred while executing the thread.
- *
- * @note The default is @p FALSE.
- * @note This debug option is not currently compatible with the
- * tickless mode.
- */
-#define CH_DBG_THREADS_PROFILING FALSE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Kernel hooks
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Threads descriptor structure extension.
- * @details User fields added to the end of the @p thread_t structure.
- */
-#define CH_CFG_THREAD_EXTRA_FIELDS \
- /* Add threads custom fields here.*/
-
-/**
- * @brief Threads initialization hook.
- * @details User initialization code added to the @p chThdInit() API.
- *
- * @note It is invoked from within @p chThdInit() and implicitly from all
- * the threads creation APIs.
- */
-#define CH_CFG_THREAD_INIT_HOOK(tp) { \
- /* Add threads initialization code here.*/ \
-}
-
-/**
- * @brief Threads finalization hook.
- * @details User finalization code added to the @p chThdExit() API.
- */
-#define CH_CFG_THREAD_EXIT_HOOK(tp) { \
- /* Add threads finalization code here.*/ \
-}
-
-/**
- * @brief Context switch hook.
- * @details This hook is invoked just before switching between threads.
- */
-#define CH_CFG_CONTEXT_SWITCH_HOOK(ntp, otp) { \
- /* Context switch code here.*/ \
-}
-
-/**
- * @brief ISR enter hook.
- */
-#define CH_CFG_IRQ_PROLOGUE_HOOK() { \
- /* IRQ prologue code here.*/ \
-}
-
-/**
- * @brief ISR exit hook.
- */
-#define CH_CFG_IRQ_EPILOGUE_HOOK() { \
- /* IRQ epilogue code here.*/ \
-}
-
-/**
- * @brief Idle thread enter hook.
- * @note This hook is invoked within a critical zone, no OS functions
- * should be invoked from here.
- * @note This macro can be used to activate a power saving mode.
- */
-#define CH_CFG_IDLE_ENTER_HOOK() { \
- /* Idle-enter code here.*/ \
-}
-
-/**
- * @brief Idle thread leave hook.
- * @note This hook is invoked within a critical zone, no OS functions
- * should be invoked from here.
- * @note This macro can be used to deactivate a power saving mode.
- */
-#define CH_CFG_IDLE_LEAVE_HOOK() { \
- /* Idle-leave code here.*/ \
-}
-
-/**
- * @brief Idle Loop hook.
- * @details This hook is continuously invoked by the idle thread loop.
- */
-#define CH_CFG_IDLE_LOOP_HOOK() { \
- /* Idle loop code here.*/ \
-}
-
-/**
- * @brief System tick event hook.
- * @details This hook is invoked in the system tick handler immediately
- * after processing the virtual timers queue.
- */
-#define CH_CFG_SYSTEM_TICK_HOOK() { \
- /* System tick event code here.*/ \
-}
-
-/**
- * @brief System halt hook.
- * @details This hook is invoked in case to a system halting error before
- * the system is halted.
- */
-#define CH_CFG_SYSTEM_HALT_HOOK(reason) { \
- /* System halt code here.*/ \
-}
-
-/**
- * @brief Trace hook.
- * @details This hook is invoked each time a new record is written in the
- * trace buffer.
- */
-#define CH_CFG_TRACE_HOOK(tep) { \
- /* Trace code here.*/ \
-}
-
-/** @} */
-
-/*===========================================================================*/
-/* Port-specific settings (override port settings defaulted in chcore.h). */
-/*===========================================================================*/
-
-#endif /* CHCONF_H */
-
-/** @} */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+/**
+ * @file templates/chconf.h
+ * @brief Configuration file template.
+ * @details A copy of this file must be placed in each project directory, it
+ * contains the application specific kernel settings.
+ *
+ * @addtogroup config
+ * @details Kernel related settings and hooks.
+ * @{
+ */
+
+#ifndef CHCONF_H
+#define CHCONF_H
+
+#define _CHIBIOS_RT_CONF_
+
+/*===========================================================================*/
+/**
+ * @name System timers settings
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief System time counter resolution.
+ * @note Allowed values are 16 or 32 bits.
+ */
+#define CH_CFG_ST_RESOLUTION 32
+
+/**
+ * @brief System tick frequency.
+ * @details Frequency of the system timer that drives the system ticks. This
+ * setting also defines the system tick time unit.
+ */
+#define CH_CFG_ST_FREQUENCY 1000
+
+/**
+ * @brief Time delta constant for the tick-less mode.
+ * @note If this value is zero then the system uses the classic
+ * periodic tick. This value represents the minimum number
+ * of ticks that is safe to specify in a timeout directive.
+ * The value one is not valid, timeouts are rounded up to
+ * this value.
+ */
+#define CH_CFG_ST_TIMEDELTA 0
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Kernel parameters and options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Round robin interval.
+ * @details This constant is the number of system ticks allowed for the
+ * threads before preemption occurs. Setting this value to zero
+ * disables the preemption for threads with equal priority and the
+ * round robin becomes cooperative. Note that higher priority
+ * threads can still preempt, the kernel is always preemptive.
+ * @note Disabling the round robin preemption makes the kernel more compact
+ * and generally faster.
+ * @note The round robin preemption is not supported in tickless mode and
+ * must be set to zero in that case.
+ */
+#define CH_CFG_TIME_QUANTUM 20
+
+/**
+ * @brief Managed RAM size.
+ * @details Size of the RAM area to be managed by the OS. If set to zero
+ * then the whole available RAM is used. The core memory is made
+ * available to the heap allocator and/or can be used directly through
+ * the simplified core memory allocator.
+ *
+ * @note In order to let the OS manage the whole RAM the linker script must
+ * provide the @p __heap_base__ and @p __heap_end__ symbols.
+ * @note Requires @p CH_CFG_USE_MEMCORE.
+ */
+#define CH_CFG_MEMCORE_SIZE 0
+
+/**
+ * @brief Idle thread automatic spawn suppression.
+ * @details When this option is activated the function @p chSysInit()
+ * does not spawn the idle thread. The application @p main()
+ * function becomes the idle thread and must implement an
+ * infinite loop.
+ */
+#define CH_CFG_NO_IDLE_THREAD FALSE
+
+/* Use __WFI in the idle thread for waiting. Does lower the power
+ * consumption. */
+#define CORTEX_ENABLE_WFI_IDLE TRUE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Performance options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief OS optimization.
+ * @details If enabled then time efficient rather than space efficient code
+ * is used when two possible implementations exist.
+ *
+ * @note This is not related to the compiler optimization options.
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_OPTIMIZE_SPEED TRUE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Subsystem options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Time Measurement APIs.
+ * @details If enabled then the time measurement APIs are included in
+ * the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_TM FALSE
+
+/**
+ * @brief Threads registry APIs.
+ * @details If enabled then the registry APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_REGISTRY TRUE
+
+/**
+ * @brief Threads synchronization APIs.
+ * @details If enabled then the @p chThdWait() function is included in
+ * the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_WAITEXIT TRUE
+
+/**
+ * @brief Semaphores APIs.
+ * @details If enabled then the Semaphores APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_SEMAPHORES TRUE
+
+/**
+ * @brief Semaphores queuing mode.
+ * @details If enabled then the threads are enqueued on semaphores by
+ * priority rather than in FIFO order.
+ *
+ * @note The default is @p FALSE. Enable this if you have special
+ * requirements.
+ * @note Requires @p CH_CFG_USE_SEMAPHORES.
+ */
+#define CH_CFG_USE_SEMAPHORES_PRIORITY FALSE
+
+/**
+ * @brief Mutexes APIs.
+ * @details If enabled then the mutexes APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MUTEXES TRUE
+
+/**
+ * @brief Enables recursive behavior on mutexes.
+ * @note Recursive mutexes are heavier and have an increased
+ * memory footprint.
+ *
+ * @note The default is @p FALSE.
+ * @note Requires @p CH_CFG_USE_MUTEXES.
+ */
+#define CH_CFG_USE_MUTEXES_RECURSIVE FALSE
+
+/**
+ * @brief Conditional Variables APIs.
+ * @details If enabled then the conditional variables APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_MUTEXES.
+ */
+#define CH_CFG_USE_CONDVARS TRUE
+
+/**
+ * @brief Conditional Variables APIs with timeout.
+ * @details If enabled then the conditional variables APIs with timeout
+ * specification are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_CONDVARS.
+ */
+#define CH_CFG_USE_CONDVARS_TIMEOUT TRUE
+
+/**
+ * @brief Events Flags APIs.
+ * @details If enabled then the event flags APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_EVENTS TRUE
+
+/**
+ * @brief Events Flags APIs with timeout.
+ * @details If enabled then the events APIs with timeout specification
+ * are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_EVENTS.
+ */
+#define CH_CFG_USE_EVENTS_TIMEOUT TRUE
+
+/**
+ * @brief Synchronous Messages APIs.
+ * @details If enabled then the synchronous messages APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MESSAGES TRUE
+
+/**
+ * @brief Synchronous Messages queuing mode.
+ * @details If enabled then messages are served by priority rather than in
+ * FIFO order.
+ *
+ * @note The default is @p FALSE. Enable this if you have special
+ * requirements.
+ * @note Requires @p CH_CFG_USE_MESSAGES.
+ */
+#define CH_CFG_USE_MESSAGES_PRIORITY FALSE
+
+/**
+ * @brief Mailboxes APIs.
+ * @details If enabled then the asynchronous messages (mailboxes) APIs are
+ * included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_SEMAPHORES.
+ */
+#define CH_CFG_USE_MAILBOXES TRUE
+
+/**
+ * @brief Core Memory Manager APIs.
+ * @details If enabled then the core memory manager APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MEMCORE TRUE
+
+/**
+ * @brief Heap Allocator APIs.
+ * @details If enabled then the memory heap allocator APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_MEMCORE and either @p CH_CFG_USE_MUTEXES or
+ * @p CH_CFG_USE_SEMAPHORES.
+ * @note Mutexes are recommended.
+ */
+#define CH_CFG_USE_HEAP TRUE
+
+/**
+ * @brief Memory Pools Allocator APIs.
+ * @details If enabled then the memory pools allocator APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MEMPOOLS TRUE
+
+/**
+ * @brief Dynamic Threads APIs.
+ * @details If enabled then the dynamic threads creation APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_WAITEXIT.
+ * @note Requires @p CH_CFG_USE_HEAP and/or @p CH_CFG_USE_MEMPOOLS.
+ */
+#define CH_CFG_USE_DYNAMIC TRUE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Debug options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Debug option, kernel statistics.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_STATISTICS FALSE
+
+/**
+ * @brief Debug option, system state check.
+ * @details If enabled the correct call protocol for system APIs is checked
+ * at runtime.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_SYSTEM_STATE_CHECK TRUE
+
+/**
+ * @brief Debug option, parameters checks.
+ * @details If enabled then the checks on the API functions input
+ * parameters are activated.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_ENABLE_CHECKS TRUE
+
+/**
+ * @brief Debug option, consistency checks.
+ * @details If enabled then all the assertions in the kernel code are
+ * activated. This includes consistency checks inside the kernel,
+ * runtime anomalies and port-defined checks.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_ENABLE_ASSERTS TRUE
+
+/**
+ * @brief Debug option, trace buffer.
+ * @details If enabled then the trace buffer is activated.
+ *
+ * @note The default is @p CH_DBG_TRACE_MASK_DISABLED.
+ */
+#define CH_DBG_TRACE_MASK CH_DBG_TRACE_MASK_DISABLED
+
+/**
+ * @brief Trace buffer entries.
+ * @note The trace buffer is only allocated if @p CH_DBG_TRACE_MASK is
+ * different from @p CH_DBG_TRACE_MASK_DISABLED.
+ */
+#define CH_DBG_TRACE_BUFFER_SIZE 128
+
+/**
+ * @brief Debug option, stack checks.
+ * @details If enabled then a runtime stack check is performed.
+ *
+ * @note The default is @p FALSE.
+ * @note The stack check is performed in a architecture/port dependent way.
+ * It may not be implemented or some ports.
+ * @note The default failure mode is to halt the system with the global
+ * @p panic_msg variable set to @p NULL.
+ */
+#define CH_DBG_ENABLE_STACK_CHECK TRUE
+
+/**
+ * @brief Debug option, stacks initialization.
+ * @details If enabled then the threads working area is filled with a byte
+ * value when a thread is created. This can be useful for the
+ * runtime measurement of the used stack.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_FILL_THREADS TRUE
+
+/**
+ * @brief Debug option, threads profiling.
+ * @details If enabled then a field is added to the @p thread_t structure that
+ * counts the system ticks occurred while executing the thread.
+ *
+ * @note The default is @p FALSE.
+ * @note This debug option is not currently compatible with the
+ * tickless mode.
+ */
+#define CH_DBG_THREADS_PROFILING FALSE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Kernel hooks
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Threads descriptor structure extension.
+ * @details User fields added to the end of the @p thread_t structure.
+ */
+#define CH_CFG_THREAD_EXTRA_FIELDS \
+ /* Add threads custom fields here.*/
+
+/**
+ * @brief Threads initialization hook.
+ * @details User initialization code added to the @p chThdInit() API.
+ *
+ * @note It is invoked from within @p chThdInit() and implicitly from all
+ * the threads creation APIs.
+ */
+#define CH_CFG_THREAD_INIT_HOOK(tp) { \
+ /* Add threads initialization code here.*/ \
+}
+
+/**
+ * @brief Threads finalization hook.
+ * @details User finalization code added to the @p chThdExit() API.
+ */
+#define CH_CFG_THREAD_EXIT_HOOK(tp) { \
+ /* Add threads finalization code here.*/ \
+}
+
+/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#define CH_CFG_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* Context switch code here.*/ \
+}
+
+/**
+ * @brief ISR enter hook.
+ */
+#define CH_CFG_IRQ_PROLOGUE_HOOK() { \
+ /* IRQ prologue code here.*/ \
+}
+
+/**
+ * @brief ISR exit hook.
+ */
+#define CH_CFG_IRQ_EPILOGUE_HOOK() { \
+ /* IRQ epilogue code here.*/ \
+}
+
+/**
+ * @brief Idle thread enter hook.
+ * @note This hook is invoked within a critical zone, no OS functions
+ * should be invoked from here.
+ * @note This macro can be used to activate a power saving mode.
+ */
+#define CH_CFG_IDLE_ENTER_HOOK() { \
+ /* Idle-enter code here.*/ \
+}
+
+/**
+ * @brief Idle thread leave hook.
+ * @note This hook is invoked within a critical zone, no OS functions
+ * should be invoked from here.
+ * @note This macro can be used to deactivate a power saving mode.
+ */
+#define CH_CFG_IDLE_LEAVE_HOOK() { \
+ /* Idle-leave code here.*/ \
+}
+
+/**
+ * @brief Idle Loop hook.
+ * @details This hook is continuously invoked by the idle thread loop.
+ */
+#define CH_CFG_IDLE_LOOP_HOOK() { \
+ /* Idle loop code here.*/ \
+}
+
+/**
+ * @brief System tick event hook.
+ * @details This hook is invoked in the system tick handler immediately
+ * after processing the virtual timers queue.
+ */
+#define CH_CFG_SYSTEM_TICK_HOOK() { \
+ /* System tick event code here.*/ \
+}
+
+/**
+ * @brief System halt hook.
+ * @details This hook is invoked in case to a system halting error before
+ * the system is halted.
+ */
+#define CH_CFG_SYSTEM_HALT_HOOK(reason) { \
+ /* System halt code here.*/ \
+}
+
+/**
+ * @brief Trace hook.
+ * @details This hook is invoked each time a new record is written in the
+ * trace buffer.
+ */
+#define CH_CFG_TRACE_HOOK(tep) { \
+ /* Trace code here.*/ \
+}
+
+/** @} */
+
+/*===========================================================================*/
+/* Port-specific settings (override port settings defaulted in chcore.h). */
+/*===========================================================================*/
+
+#endif /* CHCONF_H */
+
+/** @} */
diff --git a/keyboards/chibios_test/teensy_lc_onekey/halconf.h b/keyboards/chibios_test/teensy_lc_onekey/halconf.h
index b1d2cd5502..0436408b09 100644
--- a/keyboards/chibios_test/teensy_lc_onekey/halconf.h
+++ b/keyboards/chibios_test/teensy_lc_onekey/halconf.h
@@ -1,187 +1,187 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-/**
- * @file templates/halconf.h
- * @brief HAL configuration header.
- * @details HAL configuration file, this file allows to enable or disable the
- * various device drivers from your application. You may also use
- * this file in order to override the device drivers default settings.
- *
- * @addtogroup HAL_CONF
- * @{
- */
-
-#ifndef _HALCONF_H_
-#define _HALCONF_H_
-
-#include "mcuconf.h"
-
-/**
- * @brief Enables the PAL subsystem.
- */
-#if !defined(HAL_USE_PAL) || defined(__DOXYGEN__)
-#define HAL_USE_PAL TRUE
-#endif
-
-/**
- * @brief Enables the ADC subsystem.
- */
-#if !defined(HAL_USE_ADC) || defined(__DOXYGEN__)
-#define HAL_USE_ADC FALSE
-#endif
-
-/**
- * @brief Enables the CAN subsystem.
- */
-#if !defined(HAL_USE_CAN) || defined(__DOXYGEN__)
-#define HAL_USE_CAN FALSE
-#endif
-
-/**
- * @brief Enables the DAC subsystem.
- */
-#if !defined(HAL_USE_DAC) || defined(__DOXYGEN__)
-#define HAL_USE_DAC FALSE
-#endif
-
-/**
- * @brief Enables the EXT subsystem.
- */
-#if !defined(HAL_USE_EXT) || defined(__DOXYGEN__)
-#define HAL_USE_EXT FALSE
-#endif
-
-/**
- * @brief Enables the GPT subsystem.
- */
-#if !defined(HAL_USE_GPT) || defined(__DOXYGEN__)
-#define HAL_USE_GPT FALSE
-#endif
-
-/**
- * @brief Enables the I2C subsystem.
- */
-#if !defined(HAL_USE_I2C) || defined(__DOXYGEN__)
-#define HAL_USE_I2C FALSE
-#endif
-
-/**
- * @brief Enables the I2S subsystem.
- */
-#if !defined(HAL_USE_I2S) || defined(__DOXYGEN__)
-#define HAL_USE_I2S FALSE
-#endif
-
-/**
- * @brief Enables the ICU subsystem.
- */
-#if !defined(HAL_USE_ICU) || defined(__DOXYGEN__)
-#define HAL_USE_ICU FALSE
-#endif
-
-/**
- * @brief Enables the MAC subsystem.
- */
-#if !defined(HAL_USE_MAC) || defined(__DOXYGEN__)
-#define HAL_USE_MAC FALSE
-#endif
-
-/**
- * @brief Enables the MMC_SPI subsystem.
- */
-#if !defined(HAL_USE_MMC_SPI) || defined(__DOXYGEN__)
-#define HAL_USE_MMC_SPI FALSE
-#endif
-
-/**
- * @brief Enables the PWM subsystem.
- */
-#if !defined(HAL_USE_PWM) || defined(__DOXYGEN__)
-#define HAL_USE_PWM FALSE
-#endif
-
-/**
- * @brief Enables the RTC subsystem.
- */
-#if !defined(HAL_USE_RTC) || defined(__DOXYGEN__)
-#define HAL_USE_RTC FALSE
-#endif
-
-/**
- * @brief Enables the SDC subsystem.
- */
-#if !defined(HAL_USE_SDC) || defined(__DOXYGEN__)
-#define HAL_USE_SDC FALSE
-#endif
-
-/**
- * @brief Enables the SERIAL subsystem.
- */
-#if !defined(HAL_USE_SERIAL) || defined(__DOXYGEN__)
-#define HAL_USE_SERIAL FALSE
-#endif
-
-/**
- * @brief Enables the SERIAL over USB subsystem.
- */
-#if !defined(HAL_USE_SERIAL_USB) || defined(__DOXYGEN__)
-#define HAL_USE_SERIAL_USB FALSE
-#endif
-
-/**
- * @brief Enables the SPI subsystem.
- */
-#if !defined(HAL_USE_SPI) || defined(__DOXYGEN__)
-#define HAL_USE_SPI FALSE
-#endif
-
-/**
- * @brief Enables the UART subsystem.
- */
-#if !defined(HAL_USE_UART) || defined(__DOXYGEN__)
-#define HAL_USE_UART FALSE
-#endif
-
-/**
- * @brief Enables the USB subsystem.
- */
-#if !defined(HAL_USE_USB) || defined(__DOXYGEN__)
-#define HAL_USE_USB TRUE
-#endif
-
-/**
- * @brief Enables the WDG subsystem.
- */
-#if !defined(HAL_USE_WDG) || defined(__DOXYGEN__)
-#define HAL_USE_WDG FALSE
-#endif
-
-/*===========================================================================*/
-/* USB driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Enables synchronous APIs.
- * @note Disabling this option saves both code and data space.
- */
-#if !defined(USB_USE_WAIT) || defined(__DOXYGEN__)
-#define USB_USE_WAIT TRUE
-#endif
-
-#endif /* _HALCONF_H_ */
-
-/** @} */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+/**
+ * @file templates/halconf.h
+ * @brief HAL configuration header.
+ * @details HAL configuration file, this file allows to enable or disable the
+ * various device drivers from your application. You may also use
+ * this file in order to override the device drivers default settings.
+ *
+ * @addtogroup HAL_CONF
+ * @{
+ */
+
+#ifndef _HALCONF_H_
+#define _HALCONF_H_
+
+#include "mcuconf.h"
+
+/**
+ * @brief Enables the PAL subsystem.
+ */
+#if !defined(HAL_USE_PAL) || defined(__DOXYGEN__)
+#define HAL_USE_PAL TRUE
+#endif
+
+/**
+ * @brief Enables the ADC subsystem.
+ */
+#if !defined(HAL_USE_ADC) || defined(__DOXYGEN__)
+#define HAL_USE_ADC FALSE
+#endif
+
+/**
+ * @brief Enables the CAN subsystem.
+ */
+#if !defined(HAL_USE_CAN) || defined(__DOXYGEN__)
+#define HAL_USE_CAN FALSE
+#endif
+
+/**
+ * @brief Enables the DAC subsystem.
+ */
+#if !defined(HAL_USE_DAC) || defined(__DOXYGEN__)
+#define HAL_USE_DAC FALSE
+#endif
+
+/**
+ * @brief Enables the EXT subsystem.
+ */
+#if !defined(HAL_USE_EXT) || defined(__DOXYGEN__)
+#define HAL_USE_EXT FALSE
+#endif
+
+/**
+ * @brief Enables the GPT subsystem.
+ */
+#if !defined(HAL_USE_GPT) || defined(__DOXYGEN__)
+#define HAL_USE_GPT FALSE
+#endif
+
+/**
+ * @brief Enables the I2C subsystem.
+ */
+#if !defined(HAL_USE_I2C) || defined(__DOXYGEN__)
+#define HAL_USE_I2C FALSE
+#endif
+
+/**
+ * @brief Enables the I2S subsystem.
+ */
+#if !defined(HAL_USE_I2S) || defined(__DOXYGEN__)
+#define HAL_USE_I2S FALSE
+#endif
+
+/**
+ * @brief Enables the ICU subsystem.
+ */
+#if !defined(HAL_USE_ICU) || defined(__DOXYGEN__)
+#define HAL_USE_ICU FALSE
+#endif
+
+/**
+ * @brief Enables the MAC subsystem.
+ */
+#if !defined(HAL_USE_MAC) || defined(__DOXYGEN__)
+#define HAL_USE_MAC FALSE
+#endif
+
+/**
+ * @brief Enables the MMC_SPI subsystem.
+ */
+#if !defined(HAL_USE_MMC_SPI) || defined(__DOXYGEN__)
+#define HAL_USE_MMC_SPI FALSE
+#endif
+
+/**
+ * @brief Enables the PWM subsystem.
+ */
+#if !defined(HAL_USE_PWM) || defined(__DOXYGEN__)
+#define HAL_USE_PWM FALSE
+#endif
+
+/**
+ * @brief Enables the RTC subsystem.
+ */
+#if !defined(HAL_USE_RTC) || defined(__DOXYGEN__)
+#define HAL_USE_RTC FALSE
+#endif
+
+/**
+ * @brief Enables the SDC subsystem.
+ */
+#if !defined(HAL_USE_SDC) || defined(__DOXYGEN__)
+#define HAL_USE_SDC FALSE
+#endif
+
+/**
+ * @brief Enables the SERIAL subsystem.
+ */
+#if !defined(HAL_USE_SERIAL) || defined(__DOXYGEN__)
+#define HAL_USE_SERIAL FALSE
+#endif
+
+/**
+ * @brief Enables the SERIAL over USB subsystem.
+ */
+#if !defined(HAL_USE_SERIAL_USB) || defined(__DOXYGEN__)
+#define HAL_USE_SERIAL_USB FALSE
+#endif
+
+/**
+ * @brief Enables the SPI subsystem.
+ */
+#if !defined(HAL_USE_SPI) || defined(__DOXYGEN__)
+#define HAL_USE_SPI FALSE
+#endif
+
+/**
+ * @brief Enables the UART subsystem.
+ */
+#if !defined(HAL_USE_UART) || defined(__DOXYGEN__)
+#define HAL_USE_UART FALSE
+#endif
+
+/**
+ * @brief Enables the USB subsystem.
+ */
+#if !defined(HAL_USE_USB) || defined(__DOXYGEN__)
+#define HAL_USE_USB TRUE
+#endif
+
+/**
+ * @brief Enables the WDG subsystem.
+ */
+#if !defined(HAL_USE_WDG) || defined(__DOXYGEN__)
+#define HAL_USE_WDG FALSE
+#endif
+
+/*===========================================================================*/
+/* USB driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Enables synchronous APIs.
+ * @note Disabling this option saves both code and data space.
+ */
+#if !defined(USB_USE_WAIT) || defined(__DOXYGEN__)
+#define USB_USE_WAIT TRUE
+#endif
+
+#endif /* _HALCONF_H_ */
+
+/** @} */
diff --git a/keyboards/chibios_test/teensy_lc_onekey/mcuconf.h b/keyboards/chibios_test/teensy_lc_onekey/mcuconf.h
index c636590197..2764e88989 100644
--- a/keyboards/chibios_test/teensy_lc_onekey/mcuconf.h
+++ b/keyboards/chibios_test/teensy_lc_onekey/mcuconf.h
@@ -1,55 +1,55 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-#ifndef _MCUCONF_H_
-#define _MCUCONF_H_
-
-#define KL2x_MCUCONF
-
-/*
- * HAL driver system settings.
- */
-#if 1
-/* PEE mode - 48MHz system clock driven by (16 MHz) external crystal. */
-#define KINETIS_MCG_MODE KINETIS_MCG_MODE_PEE
-#define KINETIS_PLLCLK_FREQUENCY 96000000UL
-#define KINETIS_SYSCLK_FREQUENCY 48000000UL
-#endif
-
-#if 0
-/* crystal-less FEI mode - 48 MHz with internal 32.768 kHz crystal */
-#define KINETIS_MCG_MODE KINETIS_MCG_MODE_FEI
-#define KINETIS_MCG_FLL_DMX32 1 /* Fine-tune for 32.768 kHz */
-#define KINETIS_MCG_FLL_DRS 1 /* 1464x FLL factor */
-#define KINETIS_SYSCLK_FREQUENCY 47972352UL /* 32.768 kHz * 1464 (~48 MHz) */
-#define KINETIS_CLKDIV1_OUTDIV1 1 /* do not divide system clock */
-#endif
-
-/*
- * SERIAL driver system settings.
- */
-#define KINETIS_SERIAL_USE_UART0 TRUE
-
-/*
- * USB driver settings
- */
-#define KINETIS_USB_USE_USB0 TRUE
-/* Need to redefine this, since the default is for K20x */
-/* This is for Teensy LC; you should comment it out (or change to 5)
- * for Teensy 3.x */
-#define KINETIS_USB_USB0_IRQ_PRIORITY 2
-
-#endif /* _MCUCONF_H_ */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+#ifndef _MCUCONF_H_
+#define _MCUCONF_H_
+
+#define KL2x_MCUCONF
+
+/*
+ * HAL driver system settings.
+ */
+#if 1
+/* PEE mode - 48MHz system clock driven by (16 MHz) external crystal. */
+#define KINETIS_MCG_MODE KINETIS_MCG_MODE_PEE
+#define KINETIS_PLLCLK_FREQUENCY 96000000UL
+#define KINETIS_SYSCLK_FREQUENCY 48000000UL
+#endif
+
+#if 0
+/* crystal-less FEI mode - 48 MHz with internal 32.768 kHz crystal */
+#define KINETIS_MCG_MODE KINETIS_MCG_MODE_FEI
+#define KINETIS_MCG_FLL_DMX32 1 /* Fine-tune for 32.768 kHz */
+#define KINETIS_MCG_FLL_DRS 1 /* 1464x FLL factor */
+#define KINETIS_SYSCLK_FREQUENCY 47972352UL /* 32.768 kHz * 1464 (~48 MHz) */
+#define KINETIS_CLKDIV1_OUTDIV1 1 /* do not divide system clock */
+#endif
+
+/*
+ * SERIAL driver system settings.
+ */
+#define KINETIS_SERIAL_USE_UART0 TRUE
+
+/*
+ * USB driver settings
+ */
+#define KINETIS_USB_USE_USB0 TRUE
+/* Need to redefine this, since the default is for K20x */
+/* This is for Teensy LC; you should comment it out (or change to 5)
+ * for Teensy 3.x */
+#define KINETIS_USB_USB0_IRQ_PRIORITY 2
+
+#endif /* _MCUCONF_H_ */
diff --git a/keyboards/chibios_test/teensy_lc_onekey/rules.mk b/keyboards/chibios_test/teensy_lc_onekey/rules.mk
new file mode 100644
index 0000000000..43ea9d82d9
--- /dev/null
+++ b/keyboards/chibios_test/teensy_lc_onekey/rules.mk
@@ -0,0 +1,49 @@
+# project specific files
+SRC = matrix.c \
+ led.c
+
+## chip/board settings
+# - the next two should match the directories in
+# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
+# - For Teensies, FAMILY = KINETIS and SERIES is either
+# KL2x (LC) or K20x (3.0,3.1,3.2).
+MCU_FAMILY = KINETIS
+MCU_SERIES = KL2x
+
+# Linker script to use
+# - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
+# or <this_dir>/ld/
+# - NOTE: a custom ld script is needed for EEPROM on Teensy LC
+# - LDSCRIPT =
+# - MKL26Z64 for Teensy LC
+# - MK20DX128 for Teensy 3.0
+# - MK20DX256 for Teensy 3.1 and 3.2
+MCU_LDSCRIPT = MKL26Z64
+
+# Startup code to use
+# - it should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
+# - STARTUP =
+# - kl2x for Teensy LC
+# - k20x5 for Teensy 3.0
+# - k20x7 for Teensy 3.1 and 3.2
+MCU_STARTUP = kl2x
+
+# Board: it should exist either in <chibios>/os/hal/boards/
+# or <this_dir>/boards
+# - BOARD =
+# - PJRC_TEENSY_LC for Teensy LC
+# - PJRC_TEENSY_3 for Teensy 3.0
+# - PJRC_TEENSY_3_1 for Teensy 3.1 or 3.2
+BOARD = PJRC_TEENSY_LC
+
+# Cortex version
+# Teensy LC is cortex-m0plus; Teensy 3.x are cortex-m4
+MCU = cortex-m0plus
+
+# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
+# I.e. 6 for Teensy LC; 7 for Teensy 3.x
+ARMV = 6
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/clueboard/Makefile b/keyboards/clueboard/Makefile
index e6b13f955a..b9bada8f8d 100644
--- a/keyboards/clueboard/Makefile
+++ b/keyboards/clueboard/Makefile
@@ -1,109 +1,5 @@
-#----------------------------------------------------------------------------
-# On command line:
-#
-# make all = Make software.
-#
-# make clean = Clean out built project files.
-#
-# make coff = Convert ELF to AVR COFF.
-#
-# make extcoff = Convert ELF to AVR Extended COFF.
-#
-# make program = Download the hex file to the device.
-# Please customize your programmer settings(PROGRAM_CMD)
-#
-# make teensy = Download the hex file to the device, using teensy_loader_cli.
-# (must have teensy_loader_cli installed).
-#
-# make dfu = Download the hex file to the device, using dfu-programmer (must
-# have dfu-programmer installed).
-#
-# make flip = Download the hex file to the device, using Atmel FLIP (must
-# have Atmel FLIP installed).
-#
-# make dfu-ee = Download the eeprom file to the device, using dfu-programmer
-# (must have dfu-programmer installed).
-#
-# make flip-ee = Download the eeprom file to the device, using Atmel FLIP
-# (must have Atmel FLIP installed).
-#
-# make debug = Start either simulavr or avarice as specified for debugging,
-# with avr-gdb or avr-insight as the front end for debugging.
-#
-# make filename.s = Just compile filename.c into the assembler code only.
-#
-# make filename.i = Create a preprocessed source file for use in submitting
-# bug reports to the GCC project.
-#
-# To rebuild project do "make clean" then "make all".
-#----------------------------------------------------------------------------
-
SUBPROJECT_DEFAULT = rev2
-# MCU name
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# change to no to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-AUDIO_ENABLE ?= no
-RGBLIGHT_ENABLE ?= no # Enable keyboard underlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/clueboard/readme.md b/keyboards/clueboard/readme.md
index 6c29c09eca..4a76e2908c 100644
--- a/keyboards/clueboard/readme.md
+++ b/keyboards/clueboard/readme.md
@@ -31,36 +31,36 @@ If you would like to use one of the alternative keymaps, or create your own, see
## Clueboard 1.0
-If you have a first generation Clueboard (one with a black PCB) you will need to use the revision 1 code. To do so add `SUBPROJECT=rev1` to your make command, like this:
+If you have a first generation Clueboard (one with a black PCB) you will need to use the revision 1 code. To do so add `rev1` to your make command, like this:
```
-$ make SUBPROJECT=rev1
+$ make rev1
```
And when flashing your keyboard:
```
-$ make SUBPROJECT=rev1 dfu
+$ make rev1-dfu
```
-If you are flashing an alternative layout to your rev1, include both `SUBPROJECT=rev1` and `KEYMAP=<keymap>` in your command, for example when flashing max:
+If you are flashing an alternative layout to your rev1, include both `rev1` and `<keymap>` in your command, for example when flashing max:
```
-$ make SUBPROJECT=rev1 KEYMAP=max dfu
+$ make rev1-max-dfu
```
## Alternate Keymaps
-There are many alternative and user-contributed layouts available in the [keymaps/](keymaps/) directory. To compile and flash an alternative you will want to add `KEYMAP=<keymap>` to your command:
+There are many alternative and user-contributed layouts available in the [keymaps/](keymaps/) directory. To compile and flash an alternative you will want to add `<keymap>` to your command:
```
-$ make KEYMAP=skully
+$ make skully
```
-And when flashing your keyboard, put `KEYMAP=<keymap>` between "make" and "dfu":
+And when flashing your keyboard, put `<keymap>` between "make" and "dfu":
```
-$ make KEYMAP=skully dfu
+$ make skully-dfu
```
### Notable Layouts
@@ -76,15 +76,15 @@ These layouts are notable for one reason or another. If you are looking for idea
There are a lot of possibilities when creating your own keymap, and the primary documentation for doing that is [Customizing Your Keymap](/readme.md##customizing-your-keymap) in the main readme.md. As a way to get started, here is the procedure I recommend:
* Copy `[keymaps/default](keymaps/default/)` to `keymaps/<your_layout>`.
-* Compile the firmware (`$ make KEYMAP=<your_layout>`)
-* Flash the firmware (`$ make KEYMAP=<your_layout> dfu`)
+* Compile the firmware (`$ make <your_layout>`)
+* Flash the firmware (`$ make <your_layout>-dfu`)
* Make sure everything works like the default keyboard
* Modify `keymaps/<your_layout>/readme.md` to tell others about your layout.
* Modify `keymaps/<your_layout>/keymap.c` to reflect your desired layout.
-* Compile your new custom firmware (`$ make KEYMAP=<your_layout>`)
+* Compile your new custom firmware (`$ make <your_layout>`)
** If you have warnings you may flash without fixing them, but something may not work right.
** If you have any errors you must fix them before continuing.
-* Flash the firmware (`$ make KEYMAP=<your_layout> dfu`)
+* Flash the firmware (`$ make <your_layout>-dfu`)
## Share Your Keymap
diff --git a/keyboards/clueboard/rev1/Makefile b/keyboards/clueboard/rev1/Makefile
index 80a942d06f..191c6bb664 100644
--- a/keyboards/clueboard/rev1/Makefile
+++ b/keyboards/clueboard/rev1/Makefile
@@ -1,5 +1,3 @@
-BACKLIGHT_ENABLE = no
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/clueboard/rev1/rules.mk b/keyboards/clueboard/rev1/rules.mk
new file mode 100644
index 0000000000..80a942d06f
--- /dev/null
+++ b/keyboards/clueboard/rev1/rules.mk
@@ -0,0 +1,5 @@
+BACKLIGHT_ENABLE = no
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
diff --git a/keyboards/clueboard/rev2/Makefile b/keyboards/clueboard/rev2/Makefile
index cea967b795..191c6bb664 100644
--- a/keyboards/clueboard/rev2/Makefile
+++ b/keyboards/clueboard/rev2/Makefile
@@ -1,5 +1,3 @@
-BACKLIGHT_ENABLE = yes
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/clueboard/rev2/rules.mk b/keyboards/clueboard/rev2/rules.mk
new file mode 100644
index 0000000000..cea967b795
--- /dev/null
+++ b/keyboards/clueboard/rev2/rules.mk
@@ -0,0 +1,5 @@
+BACKLIGHT_ENABLE = yes
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
diff --git a/keyboards/clueboard/rules.mk b/keyboards/clueboard/rules.mk
new file mode 100644
index 0000000000..3909fbd5cb
--- /dev/null
+++ b/keyboards/clueboard/rules.mk
@@ -0,0 +1,103 @@
+#----------------------------------------------------------------------------
+# On command line:
+#
+# make all = Make software.
+#
+# make clean = Clean out built project files.
+#
+# make coff = Convert ELF to AVR COFF.
+#
+# make extcoff = Convert ELF to AVR Extended COFF.
+#
+# make program = Download the hex file to the device.
+# Please customize your programmer settings(PROGRAM_CMD)
+#
+# make teensy = Download the hex file to the device, using teensy_loader_cli.
+# (must have teensy_loader_cli installed).
+#
+# make dfu = Download the hex file to the device, using dfu-programmer (must
+# have dfu-programmer installed).
+#
+# make flip = Download the hex file to the device, using Atmel FLIP (must
+# have Atmel FLIP installed).
+#
+# make dfu-ee = Download the eeprom file to the device, using dfu-programmer
+# (must have dfu-programmer installed).
+#
+# make flip-ee = Download the eeprom file to the device, using Atmel FLIP
+# (must have Atmel FLIP installed).
+#
+# make debug = Start either simulavr or avarice as specified for debugging,
+# with avr-gdb or avr-insight as the front end for debugging.
+#
+# make filename.s = Just compile filename.c into the assembler code only.
+#
+# make filename.i = Create a preprocessed source file for use in submitting
+# bug reports to the GCC project.
+#
+# To rebuild project do "make clean" then "make all".
+#----------------------------------------------------------------------------
+
+# MCU name
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+AUDIO_ENABLE ?= no
+RGBLIGHT_ENABLE ?= no # Enable keyboard underlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID \ No newline at end of file
diff --git a/keyboards/cluecard/Makefile b/keyboards/cluecard/Makefile
index 029d0b9670..4e2a6f00fd 100644
--- a/keyboards/cluecard/Makefile
+++ b/keyboards/cluecard/Makefile
@@ -1,76 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-RGBLIGHT_ENABLE ?= yes # Enable keyboard underlight functionality (+4870)
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= yes # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
-
+endif \ No newline at end of file
diff --git a/keyboards/cluecard/readme.md b/keyboards/cluecard/readme.md
index ae1afbbfdd..be13fc0171 100644
--- a/keyboards/cluecard/readme.md
+++ b/keyboards/cluecard/readme.md
@@ -13,16 +13,16 @@ Depending on which keymap you would like to use, you will have to compile slight
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create a folder with the name of your keymap in the keymaps folder, and see keymap documentation (you can find in top readme.md) and existant keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `keymap` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
```
-$ make keymap=[default|jack|<name>]
+$ make [default|jack|<name>]
```
Keymaps follow the format **__keymap.c__** and are stored in folders in the `keymaps` folder, eg `keymaps/my_keymap/`
diff --git a/keyboards/cluecard/rules.mk b/keyboards/cluecard/rules.mk
new file mode 100644
index 0000000000..454235877d
--- /dev/null
+++ b/keyboards/cluecard/rules.mk
@@ -0,0 +1,70 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+RGBLIGHT_ENABLE ?= yes # Enable keyboard underlight functionality (+4870)
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= yes # Audio output on port C6
diff --git a/keyboards/cluepad/Makefile b/keyboards/cluepad/Makefile
index a331ff4dcd..4e2a6f00fd 100644
--- a/keyboards/cluepad/Makefile
+++ b/keyboards/cluepad/Makefile
@@ -1,70 +1,3 @@
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-# MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-# EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-# CONSOLE_ENABLE ?= yes # Console for debug(+400)
-# COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE ?= yes # Enable numpad's backlight functionality
-RGBLIGHT_ENABLE ?= yes
-# MIDI_ENABLE ?= YES # MIDI controls
-# UNICODE_ENABLE ?= YES # Unicode
-# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/cluepad/rules.mk b/keyboards/cluepad/rules.mk
new file mode 100644
index 0000000000..19b16b95a9
--- /dev/null
+++ b/keyboards/cluepad/rules.mk
@@ -0,0 +1,65 @@
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+# MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+# EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+# CONSOLE_ENABLE ?= yes # Console for debug(+400)
+# COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE ?= yes # Enable numpad's backlight functionality
+RGBLIGHT_ENABLE ?= yes
+# MIDI_ENABLE ?= YES # MIDI controls
+# UNICODE_ENABLE ?= YES # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID \ No newline at end of file
diff --git a/keyboards/ergodox/Makefile b/keyboards/ergodox/Makefile
index 05fb588d11..7165350050 100644
--- a/keyboards/ergodox/Makefile
+++ b/keyboards/ergodox/Makefile
@@ -1,34 +1,5 @@
-#----------------------------------------------------------------------------
-# On command line:
-#
-# make = Make software.
-#
-# make clean = Clean out built project files.
-#
-# That's pretty much all you need. To compile, always go make clean,
-# followed by make.
-#
-# For advanced users only:
-# make teensy = Download the hex file to the device, using teensy_loader_cli.
-# (must have teensy_loader_cli installed).
-#
-#----------------------------------------------------------------------------
SUBPROJECT_DEFAULT = ez
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-CUSTOM_MATRIX ?= yes # Custom matrix file for the ErgoDox EZ
-SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= yes # Unicode
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/ergodox/ergodox.c b/keyboards/ergodox/ergodox.c
index e69de29bb2..c88c1ad890 100644
--- a/keyboards/ergodox/ergodox.c
+++ b/keyboards/ergodox/ergodox.c
@@ -0,0 +1,24 @@
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+
+// swap-hands action needs a matrix to define the swap
+const keypos_t hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
+ /* Left hand, matrix positions */
+ {{0,13}, {1,13}, {2,13}, {3,13}, {4,13}, {5,13}},
+ {{0,12}, {1,12}, {2,12}, {3,12}, {4,12}, {5,12}},
+ {{0,11}, {1,11}, {2,11}, {3,11}, {4,11}, {5,11}},
+ {{0,10}, {1,10}, {2,10}, {3,10}, {4,10}, {5,10}},
+ {{0,9}, {1,9}, {2,9}, {3,9}, {4,9}, {5,9}},
+ {{0,8}, {1,8}, {2,8}, {3,8}, {4,8}, {5,8}},
+ {{0,7}, {1,7}, {2,7}, {3,7}, {4,7}, {5,7}},
+ /* Right hand, matrix positions */
+ {{0,6}, {1,6}, {2,6}, {3,6}, {4,6}, {5,6}},
+ {{0,5}, {1,5}, {2,5}, {3,5}, {4,5}, {5,5}},
+ {{0,4}, {1,4}, {2,4}, {3,4}, {4,4}, {5,4}},
+ {{0,3}, {1,3}, {2,3}, {3,3}, {4,3}, {5,3}},
+ {{0,2}, {1,2}, {2,2}, {3,2}, {4,2}, {5,2}},
+ {{0,1}, {1,1}, {2,1}, {3,1}, {4,1}, {5,1}},
+ {{0,0}, {1,0}, {2,0}, {3,0}, {4,0}, {5,0}},
+};
+
diff --git a/keyboards/ergodox/ez/Makefile b/keyboards/ergodox/ez/Makefile
index 37e554b304..191c6bb664 100644
--- a/keyboards/ergodox/ez/Makefile
+++ b/keyboards/ergodox/ez/Makefile
@@ -1,76 +1,3 @@
-#----------------------------------------------------------------------------
-# On command line:
-#
-# make = Make software.
-#
-# make clean = Clean out built project files.
-#
-# That's pretty much all you need. To compile, always go make clean,
-# followed by make.
-#
-# For advanced users only:
-# make teensy = Download the hex file to the device, using teensy_loader_cli.
-# (must have teensy_loader_cli installed).
-#
-#----------------------------------------------------------------------------
-
-# # project specific files
-SRC = twimaster.c \
- matrix.c
-
-# MCU name
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=512
-
-
-# Build Options
-# comment out to disable the options.
-#
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/ergodox/ez/ez.h b/keyboards/ergodox/ez/ez.h
index db4ec867bc..124bf850e7 100644
--- a/keyboards/ergodox/ez/ez.h
+++ b/keyboards/ergodox/ez/ez.h
@@ -119,4 +119,45 @@ inline void ergodox_led_all_set(uint8_t n)
{ k0D, k1D, k2D, k3D, k4D, KC_NO } \
}
+#define KEYMAP_80( \
+ \
+ /* left hand, spatial positions */ \
+ k00,k01,k02,k03,k04,k05,k06, \
+ k10,k11,k12,k13,k14,k15,k16, \
+ k20,k21,k22,k23,k24,k25, \
+ k30,k31,k32,k33,k34,k35,k36, \
+ k40,k41,k42,k43,k44, \
+ k55,k56, \
+ k45,k46,k54, \
+ k53,k52,k51, \
+ \
+ /* right hand, spatial positions */ \
+ k07,k08,k09,k0A,k0B,k0C,k0D, \
+ k17,k18,k19,k1A,k1B,k1C,k1D, \
+ k28,k29,k2A,k2B,k2C,k2D, \
+ k37,k38,k39,k3A,k3B,k3C,k3D, \
+ k49,k4A,k4B,k4C,k4D, \
+ k57,k58, \
+ k59,k47,k48, \
+ k5C,k5B,k5A ) \
+ \
+ /* matrix positions */ \
+ { \
+ { k00, k10, k20, k30, k40, KC_NO }, \
+ { k01, k11, k21, k31, k41, k51 }, \
+ { k02, k12, k22, k32, k42, k52 }, \
+ { k03, k13, k23, k33, k43, k53 }, \
+ { k04, k14, k24, k34, k44, k54 }, \
+ { k05, k15, k25, k35, k45, k55 }, \
+ { k06, k16, KC_NO, k36, k46, k56 }, \
+ \
+ { k07, k17, KC_NO, k37, k47, k57 }, \
+ { k08, k18, k28, k38, k48, k58 }, \
+ { k09, k19, k29, k39, k49, k59 }, \
+ { k0A, k1A, k2A, k3A, k4A, k5A }, \
+ { k0B, k1B, k2B, k3B, k4B, k5B }, \
+ { k0C, k1C, k2C, k3C, k4C, k5C }, \
+ { k0D, k1D, k2D, k3D, k4D, KC_NO } \
+ }
+
#endif
diff --git a/keyboards/ergodox/ez/keymaps/profet_80/ergodox80.png b/keyboards/ergodox/ez/keymaps/profet_80/ergodox80.png
new file mode 100644
index 0000000000..66b9752ebc
--- /dev/null
+++ b/keyboards/ergodox/ez/keymaps/profet_80/ergodox80.png
Binary files differ
diff --git a/keyboards/ergodox/ez/keymaps/profet_80/keymap.c b/keyboards/ergodox/ez/keymaps/profet_80/keymap.c
new file mode 100644
index 0000000000..505ff29722
--- /dev/null
+++ b/keyboards/ergodox/ez/keymaps/profet_80/keymap.c
@@ -0,0 +1,183 @@
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+#include "version.h"
+
+#define BASE 0 // default layer
+#define SYMB 1 // symbols
+#define MDIA 2 // media keys
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+/* Keymap 0: Basic layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | = | 1 | 2 | 3 | 4 | 5 | LEFT | | RIGHT| 6 | 7 | 8 | 9 | 0 | - |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | Del | Q | W | E | R | T | L1 | | L1 | Y | U | I | O | P | \ |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | BkSp | A | S | D | F | G |------| |------| H | J | K | L |; / L2|' / Cmd |
+ * |--------+------+------+------+------+------| Hyper| | Meh |------+------+------+------+------+--------|
+ * | LShift |Z/Ctrl| X | C | V | B | | | | N | M | , | . |//Ctrl| RShift |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * |Grv/L1| '" |AltShf| Left | Right| | Up | Down | [ | ] | ~L1 |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | App | LGui | | Alt |Ctrl/Esc|
+ * ,------|------|------| |------+--------+------.
+ * | 1 | 2 | Home | | PgUp | 3 | 4 |
+ * |------|------|------| |------|--------|------|
+ * | Space| BkSp | End | | PgDn | Tab |Enter |
+ * `--------------------' `----------------------'
+ */
+// If it accepts an argument (i.e, is a function), it doesn't need KC_.
+// Otherwise, it needs KC_*
+[BASE] = KEYMAP_80( // layer 0 : default
+ // left hand
+ KC_EQL, KC_1, KC_2, KC_3, KC_4, KC_5, KC_LEFT,
+ KC_DELT, KC_Q, KC_W, KC_E, KC_R, KC_T, TG(SYMB),
+ KC_BSPC, KC_A, KC_S, KC_D, KC_F, KC_G,
+ KC_LSFT, CTL_T(KC_Z), KC_X, KC_C, KC_V, KC_B, ALL_T(KC_NO),
+ LT(SYMB,KC_GRV),KC_QUOT, LALT(KC_LSFT), KC_LEFT,KC_RGHT,
+ ALT_T(KC_APP), KC_LGUI,
+ KC_1, KC_2, KC_HOME,
+ KC_SPC,KC_BSPC,KC_END,
+ // right hand
+ KC_RGHT, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,
+ TG(SYMB), KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
+ KC_H, KC_J, KC_K, KC_L, LT(MDIA, KC_SCLN),GUI_T(KC_QUOT),
+ MEH_T(KC_NO),KC_N, KC_M, KC_COMM,KC_DOT, CTL_T(KC_SLSH), KC_RSFT,
+ KC_UP, KC_DOWN,KC_LBRC,KC_RBRC, KC_FN1,
+ KC_LALT, CTL_T(KC_ESC),
+ KC_PGUP,KC_3, KC_4,
+ KC_PGDN,KC_TAB, KC_ENT
+ ),
+/* Keymap 1: Symbol Layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * |Version | F1 | F2 | F3 | F4 | F5 | | | | F6 | F7 | F8 | F9 | F10 | F11 |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | ! | @ | { | } | | | | | | Up | 7 | 8 | 9 | * | F12 |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | # | $ | ( | ) | ` |------| |------| Down | 4 | 5 | 6 | + | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | % | ^ | [ | ] | ~ | | | | & | 1 | 2 | 3 | \ | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | | . | 0 | = | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * |------|------|------| |------|------|------|
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+// SYMBOLS
+[SYMB] = KEYMAP_80(
+ // left hand
+ M(0), KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS,
+ KC_TRNS,KC_EXLM,KC_AT, KC_LCBR,KC_RCBR,KC_PIPE,KC_TRNS,
+ KC_TRNS,KC_HASH,KC_DLR, KC_LPRN,KC_RPRN,KC_GRV,
+ KC_TRNS,KC_PERC,KC_CIRC,KC_LBRC,KC_RBRC,KC_TILD,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,
+ // right hand
+ KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
+ KC_TRNS, KC_UP, KC_7, KC_8, KC_9, KC_ASTR, KC_F12,
+ KC_DOWN, KC_4, KC_5, KC_6, KC_PLUS, KC_TRNS,
+ KC_TRNS, KC_AMPR, KC_1, KC_2, KC_3, KC_BSLS, KC_TRNS,
+ KC_TRNS,KC_DOT, KC_0, KC_EQL, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+),
+/* Keymap 2: Media and mouse keys
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | | | | | | | | | | | | | | | |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | | MsUp | | | | | | | | | | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | |MsLeft|MsDown|MsRght| |------| |------| | | | | | Play |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | | | | | | | | Prev | Next | | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | Lclk | Rclk | |VolUp |VolDn | Mute | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+----------.
+ * | | | | | | | |
+ * |------|------|------| |------|------|----------|
+ * | | | | | | |BrwserBack|
+ * `--------------------' `------------------------'
+ */
+// MEDIA AND MOUSE
+[MDIA] = KEYMAP_80(
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_MS_U, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_MS_L, KC_MS_D, KC_MS_R, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_BTN1, KC_BTN2,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS,
+ // right hand
+ 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, KC_TRNS, KC_TRNS, KC_MPLY,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_MPRV, KC_MNXT, KC_TRNS, KC_TRNS,
+ KC_VOLU, KC_VOLD, KC_MUTE, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_WBAK
+),
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+ [1] = ACTION_LAYER_TAP_TOGGLE(SYMB) // FN1 - Momentary Layer 1 (Symbols)
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ SEND_STRING (QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
+
+// Runs just one time when the keyboard initializes.
+void matrix_init_user(void) {
+
+};
+
+// Runs constantly in the background, in a loop.
+void matrix_scan_user(void) {
+
+ uint8_t layer = biton32(layer_state);
+
+ ergodox_board_led_off();
+ ergodox_right_led_1_off();
+ ergodox_right_led_2_off();
+ ergodox_right_led_3_off();
+ switch (layer) {
+ // TODO: Make this relevant to the ErgoDox EZ.
+ case 1:
+ ergodox_right_led_1_on();
+ break;
+ case 2:
+ ergodox_right_led_2_on();
+ break;
+ default:
+ // none
+ break;
+ }
+
+};
diff --git a/keyboards/ergodox/ez/keymaps/profet_80/readme.md b/keyboards/ergodox/ez/keymaps/profet_80/readme.md
new file mode 100644
index 0000000000..b6bbb86d2c
--- /dev/null
+++ b/keyboards/ergodox/ez/keymaps/profet_80/readme.md
@@ -0,0 +1,10 @@
+# ErgoDox 80 Default Configuration
+
+This is based on the default Ergodox EZ keymap.
+The difference is that this keymap supports 80 key layouts.
+If you own an 80 key Ergodox, use this as an example to get your desired keymap.
+
+**NOTE:** This layout is not physically supported by the Ergodox EZ.
+
+
+![Default80](ergodox80.png)
diff --git a/keyboards/ergodox/ez/rules.mk b/keyboards/ergodox/ez/rules.mk
new file mode 100644
index 0000000000..a9715beb85
--- /dev/null
+++ b/keyboards/ergodox/ez/rules.mk
@@ -0,0 +1,78 @@
+#----------------------------------------------------------------------------
+# On command line:
+#
+# make = Make software.
+#
+# make clean = Clean out built project files.
+#
+# That's pretty much all you need. To compile, always go make clean,
+# followed by make.
+#
+# For advanced users only:
+# make teensy = Download the hex file to the device, using teensy_loader_cli.
+# (must have teensy_loader_cli installed).
+#
+#----------------------------------------------------------------------------
+
+# # project specific files
+SRC = twimaster.c \
+ matrix.c
+
+# MCU name
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=512
+
+
+# Build Options
+# comment out to disable the options.
+#
+
+SLEEP_LED_ENABLE = no
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
diff --git a/keyboards/ergodox/infinity/Makefile b/keyboards/ergodox/infinity/Makefile
index ccb735a485..191c6bb664 100644
--- a/keyboards/ergodox/infinity/Makefile
+++ b/keyboards/ergodox/infinity/Makefile
@@ -1,77 +1,3 @@
-# project specific files
-SRC = matrix.c \
- led.c
-
-## chip/board settings
-# - the next two should match the directories in
-# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
-# - For Teensies, FAMILY = KINETIS and SERIES is either
-# KL2x (LC) or K20x (3.0,3.1,3.2).
-# - For Infinity KB, SERIES = K20x
-MCU_FAMILY = KINETIS
-MCU_SERIES = K20x
-
-# Linker script to use
-# - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
-# or <this_dir>/ld/
-# - NOTE: a custom ld script is needed for EEPROM on Teensy LC
-# - LDSCRIPT =
-# - MKL26Z64 for Teensy LC
-# - MK20DX128 for Teensy 3.0
-# - MK20DX256 for Teensy 3.1 and 3.2
-# - MK20DX128BLDR4 for Infinity 60% with Kiibohd bootloader
-# - MK20DX256BLDR8 for Infinity ErgoDox with Kiibohd bootloader
-MCU_LDSCRIPT = MK20DX256BLDR8
-
-# Startup code to use
-# - it should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
-# - STARTUP =
-# - kl2x for Teensy LC
-# - k20x5 for Teensy 3.0 and Infinity 60%
-# - k20x7 for Teensy 3.1, 3.2 and Infinity ErgoDox
-MCU_STARTUP = k20x7
-
-# Board: it should exist either in <chibios>/os/hal/boards/
-# or <this_dir>/boards
-# - BOARD =
-# - PJRC_TEENSY_LC for Teensy LC
-# - PJRC_TEENSY_3 for Teensy 3.0
-# - PJRC_TEENSY_3_1 for Teensy 3.1 or 3.2
-# - MCHCK_K20 for Infinity KB
-#BOARD = MCHCK_K20
-BOARD = PJRC_TEENSY_3_1
-
-# Cortex version
-# Teensy LC is cortex-m0; Teensy 3.x are cortex-m4
-MCU = cortex-m4
-
-# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
-# I.e. 6 for Teensy LC; 7 for Teensy 3.x
-ARMV = 7
-
-# Vector table for application
-# 0x00000000-0x00001000 area is occupied by bootlaoder.*/
-# The CORTEX_VTOR... is needed only for MCHCK/Infinity KB
-OPT_DEFS += -DCORTEX_VTOR_INIT=0x00002000
-
-# Build Options
-# comment out to disable the options.
-#
-CUSTOM_MATRIX ?= yes # Custom matrix file
-SERIAL_LINK_ENABLE = yes
-VISUALIZER_ENABLE ?= no #temporarily disabled to make everything compile
-LCD_ENABLE ?= yes
-LED_ENABLE ?= yes
-LCD_BACKLIGHT_ENABLE ?= yes
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
-
-ifdef LCD_ENABLE
-include $(SUBPROJECT_PATH)/drivers/gdisp/st7565ergodox/driver.mk
-endif
-
-ifdef LED_ENABLE
-include $(SUBPROJECT_PATH)/drivers/gdisp/IS31FL3731C/driver.mk
-endif
+endif \ No newline at end of file
diff --git a/keyboards/ergodox/infinity/rules.mk b/keyboards/ergodox/infinity/rules.mk
new file mode 100644
index 0000000000..ccb735a485
--- /dev/null
+++ b/keyboards/ergodox/infinity/rules.mk
@@ -0,0 +1,77 @@
+# project specific files
+SRC = matrix.c \
+ led.c
+
+## chip/board settings
+# - the next two should match the directories in
+# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
+# - For Teensies, FAMILY = KINETIS and SERIES is either
+# KL2x (LC) or K20x (3.0,3.1,3.2).
+# - For Infinity KB, SERIES = K20x
+MCU_FAMILY = KINETIS
+MCU_SERIES = K20x
+
+# Linker script to use
+# - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
+# or <this_dir>/ld/
+# - NOTE: a custom ld script is needed for EEPROM on Teensy LC
+# - LDSCRIPT =
+# - MKL26Z64 for Teensy LC
+# - MK20DX128 for Teensy 3.0
+# - MK20DX256 for Teensy 3.1 and 3.2
+# - MK20DX128BLDR4 for Infinity 60% with Kiibohd bootloader
+# - MK20DX256BLDR8 for Infinity ErgoDox with Kiibohd bootloader
+MCU_LDSCRIPT = MK20DX256BLDR8
+
+# Startup code to use
+# - it should exist in <chibios>/os/common/ports/ARMCMx/compilers/GCC/mk/
+# - STARTUP =
+# - kl2x for Teensy LC
+# - k20x5 for Teensy 3.0 and Infinity 60%
+# - k20x7 for Teensy 3.1, 3.2 and Infinity ErgoDox
+MCU_STARTUP = k20x7
+
+# Board: it should exist either in <chibios>/os/hal/boards/
+# or <this_dir>/boards
+# - BOARD =
+# - PJRC_TEENSY_LC for Teensy LC
+# - PJRC_TEENSY_3 for Teensy 3.0
+# - PJRC_TEENSY_3_1 for Teensy 3.1 or 3.2
+# - MCHCK_K20 for Infinity KB
+#BOARD = MCHCK_K20
+BOARD = PJRC_TEENSY_3_1
+
+# Cortex version
+# Teensy LC is cortex-m0; Teensy 3.x are cortex-m4
+MCU = cortex-m4
+
+# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
+# I.e. 6 for Teensy LC; 7 for Teensy 3.x
+ARMV = 7
+
+# Vector table for application
+# 0x00000000-0x00001000 area is occupied by bootlaoder.*/
+# The CORTEX_VTOR... is needed only for MCHCK/Infinity KB
+OPT_DEFS += -DCORTEX_VTOR_INIT=0x00002000
+
+# Build Options
+# comment out to disable the options.
+#
+CUSTOM_MATRIX ?= yes # Custom matrix file
+SERIAL_LINK_ENABLE = yes
+VISUALIZER_ENABLE ?= no #temporarily disabled to make everything compile
+LCD_ENABLE ?= yes
+LED_ENABLE ?= yes
+LCD_BACKLIGHT_ENABLE ?= yes
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
+
+ifdef LCD_ENABLE
+include $(SUBPROJECT_PATH)/drivers/gdisp/st7565ergodox/driver.mk
+endif
+
+ifdef LED_ENABLE
+include $(SUBPROJECT_PATH)/drivers/gdisp/IS31FL3731C/driver.mk
+endif
diff --git a/keyboards/ergodox/keymaps/absenth/absenth_highres.png b/keyboards/ergodox/keymaps/absenth/absenth_highres.png
new file mode 100644
index 0000000000..c07aa8803f
--- /dev/null
+++ b/keyboards/ergodox/keymaps/absenth/absenth_highres.png
Binary files differ
diff --git a/keyboards/ergodox/keymaps/absenth/keymap.c b/keyboards/ergodox/keymaps/absenth/keymap.c
new file mode 100644
index 0000000000..ded668e13b
--- /dev/null
+++ b/keyboards/ergodox/keymaps/absenth/keymap.c
@@ -0,0 +1,183 @@
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+#include "version.h"
+
+#define BASE 0 // default layer
+#define SYMB 1 // symbols
+#define MDIA 2 // media keys
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+/* Keymap 0: Basic layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | = | 1 | 2 | 3 | 4 | 5 | LEFT | | RIGHT| 6 | 7 | 8 | 9 | 0 | - |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | Del | Q | W | E | R | T | L1 | | L1 | Y | U | I | O | P | \ |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | BkSp | A/L2 | S | D | F | G |------| |------| H | J | K | L |; / L2|' / Cmd |
+ * |--------+------+------+------+------+------| Hyper| | Meh |------+------+------+------+------+--------|
+ * | LS/PO |Z/Ctrl| X | C | V | B | | | | N | M | , | . |//Ctrl| RS/PC |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * |Grv/L1| '" |AltShf| Left | Right| | Up | Down | [ | ] | ~L1 |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | App | LGui | | Alt |Ctrl/Esc|
+ * ,------|------|------| |------+--------+------.
+ * | | | Home | | PgUp | | |
+ * | Space|Backsp|------| |------| Tab |Enter |
+ * | |ace | End | | PgDn | | |
+ * `--------------------' `----------------------'
+ */
+// If it accepts an argument (i.e, is a function), it doesn't need KC_.
+// Otherwise, it needs KC_*
+[BASE] = KEYMAP( // layer 0 : default
+ // left hand
+ KC_EQL, KC_1, KC_2, KC_3, KC_4, KC_5, KC_LEFT,
+ KC_DELT, KC_Q, KC_W, KC_E, KC_R, KC_T, TG(SYMB),
+ KC_BSPC, LT(MDIA, KC_A), KC_S, KC_D, KC_F, KC_G,
+ KC_LSPO, CTL_T(KC_Z), KC_X, KC_C, KC_V, KC_B, ALL_T(KC_NO),
+ LT(SYMB,KC_GRV),KC_QUOT, LALT(KC_LSFT), KC_LEFT,KC_RGHT,
+ ALT_T(KC_APP), KC_LGUI,
+ KC_HOME,
+ KC_SPC,KC_BSPC,KC_END,
+ // right hand
+ KC_RGHT, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,
+ TG(SYMB), KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
+ KC_H, KC_J, KC_K, KC_L, LT(MDIA, KC_SCLN),GUI_T(KC_QUOT),
+ MEH_T(KC_NO),KC_N, KC_M, KC_COMM,KC_DOT, CTL_T(KC_SLSH), KC_RSPC,
+ KC_UP, KC_DOWN,KC_LBRC,KC_RBRC, KC_FN1,
+ KC_LALT, CTL_T(KC_ESC),
+ KC_PGUP,
+ KC_PGDN,KC_TAB, KC_ENT
+ ),
+/* Keymap 1: Symbol Layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * |Version | F1 | F2 | F3 | F4 | F5 | | | | F6 | F7 | F8 | F9 | F10 | F11 |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | ! | @ | { | } | | | | | | Up | 7 | 8 | 9 | * | F12 |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | # | $ | ( | ) | ` |------| |------| Down | 4 | 5 | 6 | + | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | % | ^ | [ | ] | ~ | | | | & | 1 | 2 | 3 | \ | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | | . | 0 | = | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | | |------| |------| | |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+// SYMBOLS
+[SYMB] = KEYMAP(
+ // left hand
+ M(0), KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS,
+ KC_TRNS,KC_EXLM,KC_AT, KC_LCBR,KC_RCBR,KC_PIPE,KC_TRNS,
+ KC_TRNS,KC_HASH,KC_DLR, KC_LPRN,KC_RPRN,KC_GRV,
+ KC_TRNS,KC_PERC,KC_CIRC,KC_LBRC,KC_RBRC,KC_TILD,KC_TRNS,
+ KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,
+ KC_TRNS,KC_TRNS,
+ KC_TRNS,
+ KC_TRNS,KC_TRNS,KC_TRNS,
+ // right hand
+ KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
+ KC_TRNS, KC_UP, KC_7, KC_8, KC_9, KC_ASTR, KC_F12,
+ KC_DOWN, KC_4, KC_5, KC_6, KC_PLUS, KC_TRNS,
+ KC_TRNS, KC_AMPR, KC_1, KC_2, KC_3, KC_BSLS, KC_TRNS,
+ KC_TRNS,KC_DOT, KC_0, KC_EQL, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+),
+/* Keymap 2: Media and mouse keys
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | | | | | | | | | | | | | | | |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | | MsUp | | | | | | | | | | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | |MsLeft|MsDown|MsRght| |------| |------| left | down | up | down | | Play |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | | | | | | | | Prev | Next | | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | Lclk | Rclk | |VolUp |VolDn | Mute | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | |Brwser|
+ * | Lclk | Rclk |------| |------| |Back |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+// MEDIA AND MOUSE
+[MDIA] = KEYMAP(
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_MS_U, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_MS_L, KC_MS_D, KC_MS_R, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_BTN1, KC_BTN2,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_BTN1, KC_BTN2, KC_TRNS,
+ // right hand
+ 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_LEFT, KC_DOWN, KC_UP, KC_RIGHT,KC_TRNS, KC_MPLY,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_MPRV, KC_MNXT, KC_TRNS, KC_TRNS,
+ KC_VOLU, KC_VOLD, KC_MUTE, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_WBAK
+),
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+ [1] = ACTION_LAYER_TAP_TOGGLE(SYMB) // FN1 - Momentary Layer 1 (Symbols)
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ SEND_STRING (QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
+
+// Runs just one time when the keyboard initializes.
+void matrix_init_user(void) {
+
+};
+
+// Runs constantly in the background, in a loop.
+void matrix_scan_user(void) {
+
+ uint8_t layer = biton32(layer_state);
+
+ ergodox_board_led_off();
+ ergodox_right_led_1_off();
+ ergodox_right_led_2_off();
+ ergodox_right_led_3_off();
+ switch (layer) {
+ // TODO: Make this relevant to the ErgoDox EZ.
+ case 1:
+ ergodox_right_led_1_on();
+ break;
+ case 2:
+ ergodox_right_led_2_on();
+ break;
+ default:
+ // none
+ break;
+ }
+
+};
diff --git a/keyboards/ergodox/keymaps/absenth/readme.md b/keyboards/ergodox/keymaps/absenth/readme.md
new file mode 100644
index 0000000000..0c04bf4177
--- /dev/null
+++ b/keyboards/ergodox/keymaps/absenth/readme.md
@@ -0,0 +1,11 @@
+# ErgoDox EZ Absenth Configuration
+
+## Changelog
+
+
+* Sept. 14, 2016 (V0.2):
+ * Added Space Cadet to Left and Right Shift. Pressing Left shift with no other key adds an "(" and pressing Right shift with no other key adds an ")"
+* Sept. 8, 2016 (V0.1):
+ * Made A key double as MEDIA Layer change when you hold it. Added mouse buttons to the large thumb buttons on the left side on the Media Layer. Added vi/vim style arrow keys on HJKL on media layer.
+
+![Absenth](absenth_highres.png)
diff --git a/keyboards/ergodox/keymaps/algernon/Makefile b/keyboards/ergodox/keymaps/algernon/Makefile
index 00194857ac..699add3dda 100644
--- a/keyboards/ergodox/keymaps/algernon/Makefile
+++ b/keyboards/ergodox/keymaps/algernon/Makefile
@@ -1,22 +1,23 @@
BOOTMAGIC_ENABLE=no
COMMAND_ENABLE=no
SLEEP_LED_ENABLE=no
-UNICODE_ENABLE=no
FORCE_NKRO ?= yes
DEBUG_ENABLE = no
CONSOLE_ENABLE = no
TAP_DANCE_ENABLE = yes
KEYLOGGER_ENABLE ?= yes
+UCIS_ENABLE = yes
+MOUSEKEY_ENABLE = no
-ADORE_AUTOLOG ?= no
+AUTOLOG_ENABLE ?= no
ifeq (${FORCE_NKRO},yes)
OPT_DEFS += -DFORCE_NKRO
endif
-ifeq (${ADORE_AUTOLOG},yes)
+ifeq (${AUTOLOG_ENABLE},yes)
KEYLOGGER_ENABLE = yes
-OPT_DEFS += -DADORE_AUTOLOG
+OPT_DEFS += -DAUTOLOG_ENABLE
endif
ifeq (${KEYLOGGER_ENABLE},yes)
@@ -24,6 +25,8 @@ OPT_DEFS += -DKEYLOGGER_ENABLE
CONSOLE_ENABLE = yes
endif
+OPT_DEFS += -DUSER_PRINT
+
KEYMAP_VERSION = $(shell \
if [ -d "${KEYMAP_PATH}/.git" ]; then \
cd "${KEYMAP_PATH}" && git describe --abbrev=6 --dirty --always --tags --match 'v*' 2>/dev/null; \
diff --git a/keyboards/ergodox/keymaps/algernon/images/adore-layer.png b/keyboards/ergodox/keymaps/algernon/images/adore-layer.png
index 44ad8a1eb7..b611fbc42a 100644
--- a/keyboards/ergodox/keymaps/algernon/images/adore-layer.png
+++ b/keyboards/ergodox/keymaps/algernon/images/adore-layer.png
Binary files differ
diff --git a/keyboards/ergodox/keymaps/algernon/images/base-layer.png b/keyboards/ergodox/keymaps/algernon/images/base-layer.png
index da159fbe2e..2a981a4706 100644
--- a/keyboards/ergodox/keymaps/algernon/images/base-layer.png
+++ b/keyboards/ergodox/keymaps/algernon/images/base-layer.png
Binary files differ
diff --git a/keyboards/ergodox/keymaps/algernon/images/heatmap.png b/keyboards/ergodox/keymaps/algernon/images/heatmap.png
index 356035e0a6..4f55c5adff 100644
--- a/keyboards/ergodox/keymaps/algernon/images/heatmap.png
+++ b/keyboards/ergodox/keymaps/algernon/images/heatmap.png
Binary files differ
diff --git a/keyboards/ergodox/keymaps/algernon/keymap.c b/keyboards/ergodox/keymaps/algernon/keymap.c
index 144030e2e9..248a0ed303 100644
--- a/keyboards/ergodox/keymaps/algernon/keymap.c
+++ b/keyboards/ergodox/keymaps/algernon/keymap.c
@@ -2,12 +2,12 @@
* algernon's ErgoDox EZ layout, please see the readme.md file!
*/
+#include <stdarg.h>
#include "ergodox.h"
#include "led.h"
#include "debug.h"
#include "action_layer.h"
#include "action_util.h"
-#include "mousekey.h"
#include "timer.h"
#include "keymap_plover.h"
#include "eeconfig.h"
@@ -33,22 +33,8 @@ enum {
// Buttons that do extra stuff
A_GUI,
A_PLVR,
- A_ESC,
A_MPN,
- // Function / number keys
- KF_1, // 1, F1
- KF_2, // 2, F2
- KF_3, // ...
- KF_4,
- KF_5,
- KF_6,
- KF_7,
- KF_8,
- KF_9,
- KF_10,
- KF_11, // =, F11
-
// Application select keys
APP_SLK, // Slack
APP_EMCS, // Emacs
@@ -56,12 +42,6 @@ enum {
APP_CHRM, // Chrome
APP_MSIC, // Music
- // Diagonal mouse movement
- A_MUL,
- A_MUR,
- A_MDL,
- A_MDR,
-
// Hungarian layer keys
HU_AA, // Á
HU_OO, // Ó
@@ -72,6 +52,18 @@ enum {
HU_UE, // Ü
HU_OEE, // Ő
HU_UEE, // Ű
+
+ // number/symbol keys
+ A_1, // 1
+ A_2, // 2
+ A_3, // ...
+ A_4,
+ A_5,
+ A_6,
+ A_7,
+ A_8,
+ A_9,
+ A_0,
};
/* Fn keys */
@@ -89,10 +81,11 @@ enum {
enum {
CT_CLN = 0,
- CT_MNS,
CT_TA,
CT_LBP,
- CT_RBP
+ CT_RBP,
+ CT_TMUX,
+ CT_TPS,
};
/* States & timers */
@@ -102,11 +95,17 @@ uint16_t gui_timer = 0;
uint16_t kf_timers[12];
#if KEYLOGGER_ENABLE
+# ifdef AUTOLOG_ENABLE
+bool log_enable = true;
+# else
bool log_enable = false;
+# endif
#endif
bool time_travel = false;
+static uint8_t is_adore = 0;
+
/* The Keymap */
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
@@ -114,13 +113,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Keymap 0: Base Layer
*
* ,-----------------------------------------------------. ,-----------------------------------------------------.
- * | Next/Prev | 1 F1 | 2 F2 | 3 F3 | 4 F4 | 5 F5 | Plvr | | Apps | 6 F6 | 7 F7 | 8 F8 | 9 F9 | 0 F10| F11 |
+ * | Next/Prev | 9 | 7 @ | 5 * | 3 ^ | 1 $ | F11 | | F12 | 0 % | 2 ! | 4 # | 6 & | 8 | Plover |
* |-----------+------+------+------+------+-------------| |------+------+------+------+------+------+-----------|
- * | ~ | ' | , | . | P | Y | [ | | ] | F | G | C | R | L | \ |
- * |-----------+------+------+------+------+------| | | |------+------+------+------+------+-----------|
+ * | ~ | ' | , | . | P | Y | ( | | ) | F | G | C | R | L | \ |
+ * |-----------+------+------+------+------+------| [ | | ] |------+------+------+------+------+-----------|
* | Tab/ARROW | A | O | E | U | I |------| |------| D | H | T | N | S | = / Arrow |
- * |-----------+------+------+------+------+------| ( | | ) |------+------+------+------+------+-----------|
- * | Play/Pause| / | Q | J | K | X | | | | B | M | W | V | Z | Stop |
+ * |-----------+------+------+------+------+------| tmux | | tmux |------+------+------+------+------+-----------|
+ * | Play/Pause| / | Q | J | K | X | | | Pane | B | M | W | V | Z | Stop |
* `-----------+------+------+------+------+-------------' `-------------+------+------+------+------+-----------'
* | | | | | : | | - | | | | |
* `-----------------------------------' `-----------------------------------'
@@ -134,22 +133,22 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
*/
[BASE] = KEYMAP(
// left hand
- M(A_MPN) ,M(KF_1) ,M(KF_2) ,M(KF_3),M(KF_4),M(KF_5),M(A_PLVR)
-,KC_GRV ,KC_QUOT ,KC_COMM ,KC_DOT ,KC_P ,KC_Y ,KC_LBRC
-,TD(CT_TA) ,KC_A ,KC_O ,KC_E ,KC_U ,KC_I
-,KC_MPLY ,KC_SLSH ,KC_Q ,KC_J ,KC_K ,KC_X ,KC_LPRN
-,KC_NO ,KC_NO ,KC_NO ,KC_NO ,TD(CT_CLN)
+ M(A_MPN) ,M(A_9) ,M(A_7) ,M(A_5) ,M(A_3) ,M(A_1) ,KC_F11
+,KC_GRV ,KC_QUOT ,KC_COMM ,KC_DOT ,KC_P ,KC_Y ,TD(CT_LBP)
+,TD(CT_TA) ,KC_A ,KC_O ,KC_E ,KC_U ,KC_I
+,KC_MPLY ,KC_SLSH ,KC_Q ,KC_J ,KC_K ,KC_X ,TD(CT_TMUX)
+,KC_NO ,KC_NO ,KC_NO ,KC_NO ,TD(CT_CLN)
,F(F_ALT),F(F_GUI)
,F(F_CTRL)
- ,KC_BSPC,F(F_SFT),M(A_ESC)
+ ,KC_BSPC,F(F_SFT),KC_ESC
// right hand
- ,KC_APP ,M(KF_6),M(KF_7) ,M(KF_8),M(KF_9) ,M(KF_10) ,KC_F11
- ,KC_RBRC ,KC_F ,KC_G ,KC_C ,KC_R ,KC_L ,KC_BSLS
- ,KC_D ,KC_H ,KC_T ,KC_N ,KC_S ,KC_EQL
- ,KC_RPRN ,KC_B ,KC_M ,KC_W ,KC_V ,KC_Z ,KC_MSTP
- ,TD(CT_MNS),KC_NO ,KC_NO ,KC_NO ,KC_NO
+ ,KC_F12 ,M(A_0) ,M(A_2) ,M(A_4) ,M(A_6) ,M(A_8) ,M(A_PLVR)
+ ,TD(CT_RBP),KC_F ,KC_G ,KC_C ,KC_R ,KC_L ,KC_BSLS
+ ,KC_D ,KC_H ,KC_T ,KC_N ,KC_S ,KC_EQL
+ ,TD(CT_TPS),KC_B ,KC_M ,KC_W ,KC_V ,KC_Z ,KC_MSTP
+ ,KC_MINS ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,OSL(NMDIA),KC_DEL
,KC_LEAD
@@ -159,15 +158,15 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Keymap 1: Adore layer
*
* ,-----------------------------------------------------. ,-----------------------------------------------------.
- * | Play/Pause| 1 F1 | 2 F2 | 3 F3 | 4 F4 | 5 F5 | Plvr | | Apps | 6 F6 | 7 F7 | 8 F8 | 9 F9 | 0 F10| F11 |
+ * | Play/Pause| 9 | 7 @ | 5 * | 3 ^ | 1 $ | F11 | | F12 | 0 % | 2 ! | 4 # | 6 & | 8 | Plover |
* |-----------+------+------+------+------+-------------| |------+------+------+------+------+------+-----------|
- * | `~ | X | W | K | L | M | ( | | ) | F | H | C | P | Y | \ |
+ * | `~ | X | W | G | L | M | ( | | ) | F | H | C | P | Y | \ |
* |-----------+------+------+------+------+------| [ | | ] |------+------+------+------+------+-----------|
* | Tab/Arrow | A | O | E | I | U |------| |------| D | R | T | N | S | = |
- * |-----------+------+------+------+------+------| | | |------+------+------+------+------+-----------|
- * | | Z | Q | ' | , | . | : | | - | B | G | V | J | / | |
+ * |-----------+------+------+------+------+------| tmux | | tmux |------+------+------+------+------+-----------|
+ * | | Z | Q | ' | , | . | | | pane | B | K | V | J | / | |
* `-----------+------+------+------+------+-------------' `-------------+------+------+------+------+-----------'
- * | | | | | | | | | | | |
+ * | | | | | : | | - | | | | |
* `-----------------------------------' `-----------------------------------'
* ,-------------. ,-------------.
* | LAlt | GUI | | MDIA | Del |
@@ -179,22 +178,22 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
*/
[ADORE] = KEYMAP(
// left hand
- KC_MPLY ,M(KF_1) ,M(KF_2) ,M(KF_3),M(KF_4),M(KF_5),M(A_PLVR)
-,KC_GRV ,KC_X ,KC_W ,KC_K ,KC_L ,KC_M ,TD(CT_LBP)
-,TD(CT_TA) ,KC_A ,KC_O ,KC_E ,KC_I ,KC_U
-,KC_NO ,KC_Z ,KC_Q ,KC_QUOT,KC_COMM,KC_DOT ,TD(CT_CLN)
-,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+ KC_MPLY ,M(A_9) ,M(A_7) ,M(A_5) ,M(A_3) ,M(A_1) ,KC_F11
+,KC_GRV ,KC_X ,KC_W ,KC_G ,KC_L ,KC_M ,TD(CT_LBP)
+,TD(CT_TA) ,KC_A ,KC_O ,KC_E ,KC_I ,KC_U
+,KC_NO ,KC_Z ,KC_Q ,KC_QUOT ,KC_COMM ,KC_DOT ,TD(CT_TMUX)
+,KC_NO ,KC_NO ,KC_NO ,KC_NO ,TD(CT_CLN)
,F(F_ALT),F(F_GUI)
,F(F_CTRL)
- ,KC_BSPC,F(F_SFT),M(A_ESC)
+ ,KC_BSPC,F(F_SFT),KC_ESC
// right hand
- ,KC_APP ,M(KF_6),M(KF_7),M(KF_8),M(KF_9) ,M(KF_10) ,KC_F11
- ,TD(CT_RBP),KC_F ,KC_H ,KC_C ,KC_P ,KC_Y ,KC_BSLS
- ,KC_D ,KC_R ,KC_T ,KC_N ,KC_S ,KC_EQL
- ,TD(CT_MNS),KC_B ,KC_G ,KC_V ,KC_J ,KC_SLSH ,KC_NO
- ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+ ,KC_F12 ,M(A_0) ,M(A_2) ,M(A_4) ,M(A_6) ,M(A_8) ,M(A_PLVR)
+ ,TD(CT_RBP),KC_F ,KC_H ,KC_C ,KC_P ,KC_Y ,KC_BSLS
+ ,KC_D ,KC_R ,KC_T ,KC_N ,KC_S ,KC_EQL
+ ,TD(CT_TPS),KC_B ,KC_K ,KC_V ,KC_J ,KC_SLSH ,KC_NO
+ ,KC_MINS ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,OSL(NMDIA),KC_DEL
,F(F_HUN)
@@ -343,45 +342,45 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Keymap 5: Navigation & Media layer
*
* ,-----------------------------------------------------. ,-----------------------------------------------------.
- * | MS Slow | | | | | |ScrLCK| |ScrLCK| | | | | | |
+ * | | F9 | F7 | F5 | F3 | F1 | | |ScrLCK| F10 | F2 | F4 | F6 | F8 | |
* |-----------+------+------+------+------+-------------| |------+------+------+------+------+------+-----------|
- * | MS Normal | | Home | Up | PgUp | | | |Scroll| |MsUpL | MsUp |MsUpR | |PrintScreen|
- * |-----------+------+------+------+------+------| | | Up |------+------+------+------+------+-----------|
- * | MS Fast | | Left | Down | Right| |------| |------| |MsLeft| MsDn |MsRght| | |
- * |-----------+------+------+------+------+------| | |Scroll|------+------+------+------+------+-----------|
- * | Play/Pause| | End | Down | PgDn | | | | Down | |MsDnL | MsDn |MsDnR | | Stop |
+ * | | | | | | | | | | | | | | | |
+ * |-----------+------+------+------+------+------| | | |------+------+------+------+------+-----------|
+ * | | | | | | |------| |------| | | | | | |
+ * |-----------+------+------+------+------+------| | | |------+------+------+------+------+-----------|
+ * | | | | | | | | | | | | | | | |
* `-----------+------+------+------+------+-------------' `-------------+------+------+------+------+-----------'
* | | | | | | | | | | | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
- * | Mute | VlUp | | BASE | MClk |
+ * | Mute | VlUp | | BASE | |
* ,------|------|------| |------+------+------.
- * | | | VlDn | | Prev |Left |Right |
- * | SPC | Enter|------| |------| Click| Click|
- * | | | ESC | | Next | | |
+ * | | | VlDn | | | | |
+ * | | |------| |------| | |
+ * | | | | | | | |
* `--------------------' `--------------------'
*/
[NMDIA] = KEYMAP(
// left hand
- KC_ACL0 ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,LGUI(KC_L)
-,KC_ACL1 ,KC_NO ,KC_HOME ,KC_UP ,KC_PGUP ,KC_NO ,KC_NO
-,KC_ACL2 ,KC_NO ,KC_LEFT ,KC_DOWN ,KC_RIGHT,KC_NO
-,KC_MPLY ,KC_NO ,KC_END ,KC_DOWN ,KC_PGDN ,KC_NO ,KC_NO
+ KC_NO ,KC_F9 ,KC_F7 ,KC_F5 ,KC_F3 ,KC_F1 ,KC_NO
+,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_MUTE ,KC_VOLU
,KC_VOLD
- ,KC_SPC,KC_ENTER,M(A_ESC)
+ ,KC_NO ,KC_NO ,KC_TRNS
// right hand
- ,LGUI(KC_L),KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
- ,KC_WH_U ,KC_NO ,M(A_MUL),KC_MS_U ,M(A_MUR),KC_NO ,KC_PSCR
- ,KC_NO ,KC_MS_L ,KC_MS_D ,KC_MS_R ,KC_NO ,KC_NO
- ,KC_WH_D ,KC_NO ,M(A_MDL),KC_MS_D ,M(A_MDR),KC_NO ,KC_MSTP
+ ,LGUI(KC_L),KC_F10 ,KC_F2 ,KC_F4 ,KC_F6 ,KC_F8 ,KC_NO
+ ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+ ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+ ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
- ,KC_TRNS ,KC_MS_BTN3
- ,KC_MPRV
- ,KC_MNXT ,KC_BTN1 ,KC_BTN2
+ ,KC_TRNS ,KC_NO
+ ,KC_NO
+ ,KC_NO ,KC_NO ,KC_NO
),
/* Keymap 6: Steno for Plover
@@ -439,7 +438,7 @@ const uint16_t PROGMEM fn_actions[] = {
,[F_CTRL] = ACTION_MODS_ONESHOT (MOD_LCTL)
};
-void toggle_steno(int pressed)
+static void toggle_steno(int pressed)
{
uint8_t layer = biton32(layer_state);
@@ -462,7 +461,7 @@ void toggle_steno(int pressed)
}
}
-macro_t *ang_do_hun (keyrecord_t *record, uint16_t accent, uint16_t hun_char)
+static macro_t *ang_do_hun (keyrecord_t *record, uint16_t accent, uint16_t hun_char)
{
uint8_t need_shift = 0;
uint8_t hold_shift = 0;
@@ -507,46 +506,65 @@ macro_t *ang_do_hun (keyrecord_t *record, uint16_t accent, uint16_t hun_char)
return MACRO_NONE;
}
-void ang_handle_kf (keyrecord_t *record, uint8_t id)
-{
- uint8_t code = id - KF_1;
+static void ang_handle_num_row(uint8_t id, keyrecord_t *record) {
+ uint8_t idx = id - A_1;
+ uint8_t kc;
+ static bool shifted[10];
- if (record->event.pressed) {
- kf_timers[code] = timer_read ();
+ if (keyboard_report->mods & MOD_BIT(KC_LSFT) ||
+ ((get_oneshot_mods() & MOD_BIT(KC_LSFT)) && !has_oneshot_mods_timed_out())) {
+ if (record->event.pressed)
+ shifted[idx] = true;
+ }
+
+ if (!shifted[idx]) {
+ kc = idx + KC_1;
} else {
- uint8_t kc;
-
- if (timer_elapsed (kf_timers[code]) > TAPPING_TERM) {
- // Long press
- kc = KC_F1 + code;
- } else {
- if (id == KF_11)
- kc = KC_EQL;
- else
- kc = KC_1 + code;
+ switch (id) {
+ case A_8:
+ case A_9:
+ shifted[idx] = false;
+ return;
+
+ case A_7:
+ kc = KC_2;
+ break;
+ case A_5:
+ kc = KC_8;
+ break;
+ case A_3:
+ kc = KC_6;
+ break;
+ case A_1:
+ kc = KC_4;
+ break;
+
+ case A_0:
+ kc = KC_5;
+ break;
+ case A_2:
+ kc = KC_1;
+ break;
+ case A_4:
+ kc = KC_3;
+ break;
+ case A_6:
+ kc = KC_7;
+ break;
}
+ }
+ if (record->event.pressed) {
register_code (kc);
+ } else {
unregister_code (kc);
+ shifted[idx] = false;
}
}
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
{
switch(id) {
- case A_ESC:
- if (record->event.pressed) {
- if ((get_oneshot_mods ()) && !has_oneshot_mods_timed_out ()) {
- clear_oneshot_mods ();
- } else {
- register_code (KC_ESC);
- }
- layer_off (HUN);
- } else {
- unregister_code (KC_ESC);
- }
- break;
-
case A_MPN:
if (record->event.pressed) {
if (keyboard_report->mods & MOD_BIT(KC_LSFT) ||
@@ -588,51 +606,6 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
case HU_UEE:
return ang_do_hun (record, KC_EQL, KC_U);
- /* Mouse movement */
- case A_MUL:
- if (record->event.pressed) {
- mousekey_on(KC_MS_UP);
- mousekey_on(KC_MS_LEFT);
- } else {
- mousekey_off(KC_MS_UP);
- mousekey_off(KC_MS_LEFT);
- }
- mousekey_send();
- break;
-
- case A_MUR:
- if (record->event.pressed) {
- mousekey_on(KC_MS_UP);
- mousekey_on(KC_MS_RIGHT);
- } else {
- mousekey_off(KC_MS_UP);
- mousekey_off(KC_MS_RIGHT);
- }
- mousekey_send();
- break;
-
- case A_MDL:
- if (record->event.pressed) {
- mousekey_on(KC_MS_DOWN);
- mousekey_on(KC_MS_LEFT);
- } else {
- mousekey_off(KC_MS_DOWN);
- mousekey_off(KC_MS_LEFT);
- }
- mousekey_send();
- break;
-
- case A_MDR:
- if (record->event.pressed) {
- mousekey_on(KC_MS_DOWN);
- mousekey_on(KC_MS_RIGHT);
- } else {
- mousekey_off(KC_MS_DOWN);
- mousekey_off(KC_MS_RIGHT);
- }
- mousekey_send();
- break;
-
/* Plover base */
case A_PLVR:
toggle_steno(record->event.pressed);
@@ -644,7 +617,6 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
register_code (KC_LGUI);
if (record->tap.count && !record->tap.interrupted) {
if (record->tap.count >= 2) {
- register_code (KC_W);
layer_on (APPSEL);
set_oneshot_layer (APPSEL, ONESHOT_START);
}
@@ -655,7 +627,6 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
} else {
if (record->tap.count >= 2)
{
- unregister_code (KC_W);
clear_oneshot_layer_state (ONESHOT_PRESSED);
}
gui_timer = timer_read ();
@@ -663,35 +634,45 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
break;
case APP_SLK:
- return MACRODOWN(T(S), T(L), T(A), T(C), T(K), T(ENT), END);
+ if (record->event.pressed)
+ uprintf("CMD:appsel_slack\n");
+ break;
case APP_EMCS:
- return MACRODOWN(T(G), T(N), T(U), T(SPC), T(E), T(M), T(A), T(C), T(S), T(SPC), T(2), T(4), T(ENT), END);
+ if (record->event.pressed)
+ uprintf("CMD:appsel_emacs\n");
+ break;
case APP_TERM:
- return MACRODOWN(T(T), T(E), T(R), T(M), T(ENT), END);
+ if (record->event.pressed)
+ uprintf("CMD:appsel_term\n");
+ break;
case APP_CHRM:
- return MACRODOWN(T(C), T(H), T(R), T(O), T(M), T(ENT), END);
+ if (record->event.pressed)
+ uprintf("CMD:appsel_chrome\n");
+ break;
case APP_MSIC:
- return MACRODOWN(T(R), T(H), T(Y), T(T), T(H), T(M), T(B), T(O), T(X), T(ENT), END);
+ if (record->event.pressed)
+ uprintf("CMD:appsel_music\n");
+ break;
- /* Function keys */
- case KF_1 ... KF_11:
- ang_handle_kf (record, id);
+ // number row and symbols
+ case A_1 ... A_0:
+ ang_handle_num_row(id, record);
break;
}
return MACRO_NONE;
};
-uint8_t is_adore = 0;
-
// Runs just one time when the keyboard initializes.
void matrix_init_user(void) {
uint8_t dl;
+ set_unicode_input_mode(UC_LNX);
+
ergodox_led_all_on();
for (int i = LED_BRIGHTNESS_HI; i > LED_BRIGHTNESS_LO; i--) {
ergodox_led_all_set (i);
@@ -709,120 +690,38 @@ void matrix_init_user(void) {
dl = eeconfig_read_default_layer ();
if (dl == (1UL << ADORE)) {
is_adore = 1;
-#if ADORE_AUTOLOG
- log_enable = true;
-#endif
}
};
LEADER_EXTERNS();
-void ang_do_unicode (void) {
- register_code (KC_RCTL);
- register_code (KC_RSFT);
- register_code (KC_U);
- unregister_code (KC_U);
- unregister_code (KC_RSFT);
- unregister_code (KC_RCTL);
- wait_ms (100);
-}
+static void ang_tap (uint8_t code, ...) {
+ uint8_t kc = code;
+ va_list ap;
-void ang_tap (uint16_t codes[]) {
- for (int i = 0; codes[i] != 0; i++) {
- register_code (codes[i]);
- unregister_code (codes[i]);
- wait_ms (50);
- }
+ va_start(ap, code);
+
+ do {
+ register_code(kc);
+ unregister_code(kc);
+ wait_ms(50);
+ kc = va_arg(ap, int);
+ } while (kc != 0);
+ va_end(ap);
}
#define TAP_ONCE(code) \
register_code (code); \
unregister_code (code)
-void ang_tap_dance_bp_finished (qk_tap_dance_state_t *state, void *user_data) {
- bool left, parens;
-
- if (state->count > 2) {
- state->count = 0;
- return;
- }
-
- if (state->keycode == TD(CT_LBP))
- left = true;
- else
- left = false;
-
- if (state->count == 1)
- parens = false;
- else
- parens = true;
-
- if (parens) {
- register_code (KC_RSFT);
- if (left) {
- TAP_ONCE(KC_9);
- } else {
- TAP_ONCE(KC_0);
- }
- unregister_code (KC_RSFT);
- } else {
- if (left) {
- TAP_ONCE (KC_LBRC);
- } else {
- TAP_ONCE (KC_RBRC);
- }
- }
-}
-
-void ang_tap_dance_cln_finished (qk_tap_dance_state_t *state, void *user_data) {
- if (state->count == 1) {
- register_code (KC_RSFT);
- register_code (KC_SCLN);
- } else if (state->count == 2) {
- register_code (KC_SCLN);
- }
-}
-
-void ang_tap_dance_cln_reset (qk_tap_dance_state_t *state, void *user_data) {
- if (state->count == 1) {
- unregister_code (KC_SCLN);
- unregister_code (KC_RSFT);
- } else if (state->count == 2) {
- unregister_code (KC_SCLN);
- }
-}
-
-void ang_tap_dance_mns_finished (qk_tap_dance_state_t *state, void *user_data) {
- if (state->count == 1) {
- register_code (KC_MINS);
- } else if (state->count == 2) {
- register_code (KC_RSFT);
- register_code (KC_MINS);
- }
-}
-
-void ang_tap_dance_mns_reset (qk_tap_dance_state_t *state, void *user_data) {
- if (state->count == 1) {
- unregister_code (KC_MINS);
- } else if (state->count == 2) {
- unregister_code (KC_RSFT);
- unregister_code (KC_MINS);
- }
-}
-
typedef struct {
bool layer_toggle;
bool sticky;
- bool finished_once;
} td_ta_state_t;
-void ang_tap_dance_ta_finished (qk_tap_dance_state_t *state, void *user_data) {
+static void ang_tap_dance_ta_finished (qk_tap_dance_state_t *state, void *user_data) {
td_ta_state_t *td_ta = (td_ta_state_t *) user_data;
- if (td_ta->finished_once) {
- return;
- }
-
if (td_ta->sticky) {
td_ta->sticky = false;
td_ta->layer_toggle = false;
@@ -830,7 +729,6 @@ void ang_tap_dance_ta_finished (qk_tap_dance_state_t *state, void *user_data) {
return;
}
- td_ta->finished_once = true;
if (state->count == 1 && !state->pressed) {
register_code (KC_TAB);
td_ta->sticky = false;
@@ -842,35 +740,70 @@ void ang_tap_dance_ta_finished (qk_tap_dance_state_t *state, void *user_data) {
}
}
-void ang_tap_dance_ta_reset (qk_tap_dance_state_t *state, void *user_data) {
+static void ang_tap_dance_ta_reset (qk_tap_dance_state_t *state, void *user_data) {
td_ta_state_t *td_ta = (td_ta_state_t *) user_data;
if (!td_ta->layer_toggle)
unregister_code (KC_TAB);
if (!td_ta->sticky)
layer_off (ARRW);
+}
- td_ta->finished_once = false;
+static void ang_tap_dance_tmux_finished (qk_tap_dance_state_t *state, void *user_data) {
+ if (state->count == 1) {
+ register_code(KC_LALT);
+ register_code(KC_SPC);
+ unregister_code(KC_SPC);
+ unregister_code(KC_LALT);
+ } else {
+ register_code(KC_LCTL);
+ register_code(KC_A);
+ unregister_code(KC_A);
+ unregister_code(KC_LCTL);
+ }
+}
+
+static void ang_tap_dance_tmux_pane_select (qk_tap_dance_state_t *state, void *user_data) {
+ uint8_t kc = KC_P;
+
+ if (state->count >= 2) {
+ kc = KC_Z;
+ }
+
+ register_code(KC_LALT);
+ register_code(KC_SPC);
+ unregister_code(KC_SPC);
+ unregister_code(KC_LALT);
+
+ register_code(kc);
+ unregister_code(kc);
}
qk_tap_dance_action_t tap_dance_actions[] = {
- [CT_CLN] = ACTION_TAP_DANCE_FN_ADVANCED (NULL, ang_tap_dance_cln_finished, ang_tap_dance_cln_reset)
- ,[CT_MNS] = ACTION_TAP_DANCE_FN_ADVANCED (NULL, ang_tap_dance_mns_finished, ang_tap_dance_mns_reset)
+ [CT_CLN] = ACTION_TAP_DANCE_DOUBLE (KC_COLN, KC_SCLN)
,[CT_TA] = {
.fn = { NULL, ang_tap_dance_ta_finished, ang_tap_dance_ta_reset },
- .user_data = (void *)&((td_ta_state_t) { false, false, false })
+ .user_data = (void *)&((td_ta_state_t) { false, false })
}
- ,[CT_LBP] = ACTION_TAP_DANCE_FN (ang_tap_dance_bp_finished)
- ,[CT_RBP] = ACTION_TAP_DANCE_FN (ang_tap_dance_bp_finished)
+ ,[CT_LBP] = ACTION_TAP_DANCE_DOUBLE (KC_LBRC, KC_LPRN)
+ ,[CT_RBP] = ACTION_TAP_DANCE_DOUBLE (KC_RBRC, KC_RPRN)
+ ,[CT_TMUX]= ACTION_TAP_DANCE_FN (ang_tap_dance_tmux_finished)
+ ,[CT_TPS] = ACTION_TAP_DANCE_FN (ang_tap_dance_tmux_pane_select)
};
-static uint16_t uni[32];
-static uint8_t unicnt;
-static bool unimagic = false;
-
// Runs constantly in the background, in a loop.
void matrix_scan_user(void) {
+ static uint32_t prev_layer_state;
uint8_t layer = biton32(layer_state);
+ bool is_arrow = false;
+ static char *layer_lookup[] = {"Dvorak", "ADORE", "Arrows", "AppSel", "Hungarian", "Nav/Media", "Plover"};
+
+ if (layer_state != prev_layer_state) {
+ prev_layer_state = layer_state;
+ if (layer_lookup[layer])
+ uprintf("LAYER: %s\n", layer_lookup[layer]);
+ }
+
if (gui_timer && timer_elapsed (gui_timer) > TAPPING_TERM)
unregister_code (KC_LGUI);
@@ -893,13 +826,19 @@ void matrix_scan_user(void) {
ergodox_right_led_2_set (LED_BRIGHTNESS_HI);
}
+ if (layer_state & (1UL << ARRW)) {
+ ergodox_right_led_1_on ();
+ ergodox_right_led_3_on ();
+ is_arrow = true;
+ }
+
if (keyboard_report->mods & MOD_BIT(KC_LSFT) ||
((get_oneshot_mods() & MOD_BIT(KC_LSFT)) && !has_oneshot_mods_timed_out())) {
ergodox_right_led_1_set (LED_BRIGHTNESS_HI);
ergodox_right_led_1_on ();
} else {
ergodox_right_led_1_set (LED_BRIGHTNESS_LO);
- if (layer != NMDIA && layer != PLVR && layer != ADORE)
+ if (layer != NMDIA && layer != PLVR && layer != ADORE && !is_arrow)
ergodox_right_led_1_off ();
}
@@ -919,7 +858,7 @@ void matrix_scan_user(void) {
ergodox_right_led_3_on ();
} else {
ergodox_right_led_3_set (LED_BRIGHTNESS_LO);
- if (layer != HUN && layer != PLVR && layer != ADORE)
+ if (layer != HUN && layer != PLVR && layer != ADORE && !is_arrow)
ergodox_right_led_3_off ();
}
@@ -936,20 +875,17 @@ void matrix_scan_user(void) {
}
#endif
+ SEQ_ONE_KEY (KC_Q) {
+ register_code16 (LCTL(KC_1));
+ unregister_code16 (LCTL(KC_1));
+ }
+
SEQ_ONE_KEY (KC_T) {
time_travel = !time_travel;
}
SEQ_ONE_KEY (KC_U) {
- ang_do_unicode ();
- }
-
- SEQ_TWO_KEYS (KC_LEAD, KC_U) {
- unicnt = 0;
- unimagic = true;
- register_code(KC_RSFT);
- TAP_ONCE(KC_U);
- unregister_code(KC_RSFT);
+ qk_ucis_start();
}
SEQ_ONE_KEY (KC_V) {
@@ -958,41 +894,27 @@ void matrix_scan_user(void) {
SEQ_ONE_KEY (KC_L) {
/* λ */
- ang_do_unicode ();
-
- uint16_t codes[] = {KC_0, KC_3, KC_B, KC_B, KC_ENT, 0};
- ang_tap (codes);
+ unicode_input_start();
+ register_hex(0x03bb);
+ unicode_input_finish();
}
SEQ_ONE_KEY (KC_Y) {
- uint16_t codes[] = {KC_BSLS, KC_O, KC_SLSH, 0};
- ang_tap (codes);
+ ang_tap (KC_BSLS, KC_O, KC_SLSH, 0);
}
SEQ_ONE_KEY (KC_S) {
- ang_do_unicode (); TAP_ONCE (KC_A); TAP_ONCE (KC_F); TAP_ONCE (KC_SPC);
+ unicode_input_start(); register_hex(0xaf); unicode_input_finish();
TAP_ONCE (KC_BSLS);
register_code (KC_RSFT); TAP_ONCE (KC_MINS); TAP_ONCE (KC_9); unregister_code (KC_RSFT);
- ang_do_unicode (); TAP_ONCE (KC_3); TAP_ONCE (KC_0); TAP_ONCE (KC_C); TAP_ONCE (KC_4); TAP_ONCE (KC_SPC);
+ unicode_input_start (); register_hex(0x30c4); unicode_input_finish();
register_code (KC_RSFT); TAP_ONCE (KC_0); TAP_ONCE (KC_MINS); unregister_code (KC_RSFT);
TAP_ONCE (KC_SLSH);
- ang_do_unicode (); TAP_ONCE (KC_A); TAP_ONCE (KC_F); TAP_ONCE (KC_SPC);
+ unicode_input_start (); register_hex(0xaf); unicode_input_finish();
}
SEQ_TWO_KEYS (KC_W, KC_M) {
- register_code (KC_LALT);
- register_code (KC_F2);
- unregister_code (KC_F2);
- unregister_code (KC_LALT);
-
- wait_ms (1000);
-
- uint16_t codes[] = {KC_M, KC_A, KC_X, KC_MINS, KC_F, KC_O, KC_C, KC_U, KC_S, KC_E, KC_D, KC_ENT, 0};
- ang_tap (codes);
- register_code (KC_LGUI);
- register_code (KC_UP);
- unregister_code (KC_UP);
- unregister_code (KC_LGUI);
+ uprintf("CMD:wm\n");
}
SEQ_ONE_KEY (KC_A) {
@@ -1013,13 +935,7 @@ void matrix_scan_user(void) {
ergodox_right_led_2_off ();
wait_ms (100);
ergodox_right_led_1_off ();
-#if ADORE_AUTOLOG
- log_enable = true;
-#endif
} else {
-#if ADORE_AUTOLOG
- log_enable = false;
-#endif
is_adore = 0;
default_layer_and (0);
default_layer_or (1UL << BASE);
@@ -1043,140 +959,41 @@ void matrix_scan_user(void) {
static uint16_t last4[4];
-bool is_uni_seq(char *seq) {
- uint8_t i;
-
- for (i = 0; seq[i]; i++) {
- uint16_t code;
- if (('1' <= seq[i]) && (seq[i] <= '9'))
- code = seq[i] - '1' + KC_1;
- else if (seq[i] == '0')
- code = KC_0;
- else
- code = seq[i] - 'a' + KC_A;
-
- if (i > unicnt)
- return false;
- if (uni[i] != code)
- return false;
- }
-
- if (uni[i] == KC_ENT || uni[i] == KC_SPC)
- return true;
-
- return false;
-}
+const qk_ucis_symbol_t ucis_symbol_table[] = UCIS_TABLE
+(
+ UCIS_SYM("poop", 0x1f4a9),
+ UCIS_SYM("rofl", 0x1f923),
+ UCIS_SYM("kiss", 0x1f619),
+ UCIS_SYM("snowman", 0x2603),
+ UCIS_SYM("coffee", 0x2615),
+ UCIS_SYM("heart", 0x2764),
+ UCIS_SYM("bolt", 0x26a1)
+);
-uint16_t hex_to_keycode(uint8_t hex)
-{
- if (hex == 0x0) {
- return KC_0;
- } else if (hex < 0xA) {
- return KC_1 + (hex - 0x1);
- } else {
- return KC_A + (hex - 0xA);
- }
-}
+bool process_record_user (uint16_t keycode, keyrecord_t *record) {
+#if KEYLOGGER_ENABLE
+ if (log_enable) {
+ uint8_t layer = biton32(layer_state);
-void register_hex(uint16_t hex) {
- bool leading_zeros = true;
-
- for(int i = 3; i >= 0; i--) {
- uint8_t digit = ((hex >> (i*4)) & 0xF);
- if (digit != 0)
- leading_zeros = false;
- else if (leading_zeros)
- continue;
- register_code(hex_to_keycode(digit));
- unregister_code(hex_to_keycode(digit));
- wait_ms(10);
+ if ((layer == ADORE) || (layer == BASE))
+ uprintf ("KL: col=%02d, row=%02d, pressed=%d, layer=%s\n", record->event.key.col,
+ record->event.key.row, record->event.pressed, (is_adore) ? "ADORE" : "Dvorak");
}
-}
-
-typedef struct {
- char *symbol;
- uint16_t codes[4];
-} qk_ucis_symbol_t;
-
-static qk_ucis_symbol_t ucis_symbol_table[] = {
- {"poop", {0x1, 0xf4a9, 0}},
- {"rofl", {0x1, 0xf923, 0}},
- {"kiss", {0x1, 0xf619, 0}},
- {"snowman", {0x2603, 0}},
- {NULL, {}}
-};
-
-bool process_record_ucis (uint16_t keycode, keyrecord_t *record) {
- uint8_t i;
-
- if (!unimagic)
- return true;
-
- if (!record->event.pressed)
- return true;
+#endif
- uni[unicnt] = keycode;
- unicnt++;
+ if (keycode == KC_ESC && record->event.pressed) {
+ bool queue = true;
- if (keycode == KC_BSPC) {
- if (unicnt >= 2) {
- unicnt-= 2;
- return true;
- } else {
- unicnt--;
- return false;
+ if ((get_oneshot_mods ()) && !has_oneshot_mods_timed_out ()) {
+ clear_oneshot_mods ();
+ queue = false;
}
- }
-
- if (keycode == KC_ENT || keycode == KC_SPC) {
- bool symbol_found = false;
-
- for (i = unicnt; i > 0; i--) {
- register_code (KC_BSPC);
- unregister_code (KC_BSPC);
- wait_ms(10);
+ if (layer_state & (1UL<<HUN)) {
+ layer_off (HUN);
+ queue = false;
}
-
- ang_do_unicode();
- wait_ms(10);
- for (i = 0; ucis_symbol_table[i].symbol; i++) {
- if (is_uni_seq (ucis_symbol_table[i].symbol)) {
- symbol_found = true;
- for (uint8_t j = 0; ucis_symbol_table[i].codes[j]; j++) {
- register_hex(ucis_symbol_table[i].codes[j]);
- }
- break;
- }
- }
- if (!symbol_found) {
- for (i = 0; i < unicnt - 1; i++) {
- uint8_t code;
-
- if (uni[i] > KF_1)
- code = uni[i] - KF_1 + KC_1;
- else
- code = uni[i];
- TAP_ONCE(code);
- wait_ms (10);
- }
- }
-
- unimagic = false;
- return true;
+ return queue;
}
- return true;
-}
-
-bool process_record_user (uint16_t keycode, keyrecord_t *record) {
-#if KEYLOGGER_ENABLE
- if (log_enable) {
- xprintf ("KL: col=%d, row=%d\n", record->event.key.col,
- record->event.key.row);
- }
-#endif
-
- if (!process_record_ucis (keycode, record))
- return false;
if (time_travel && !record->event.pressed) {
uint8_t p;
@@ -1188,15 +1005,13 @@ bool process_record_user (uint16_t keycode, keyrecord_t *record) {
last4[3] = keycode;
if (last4[0] == KC_D && last4[1] == KC_A && last4[2] == KC_T && last4[3] == KC_E) {
- uint16_t codes[] = {KC_E, KC_SPC, KC_MINS, KC_D, KC_SPC, KC_QUOT, 0};
- ang_tap (codes);
+ ang_tap (KC_E, KC_SPC, KC_MINS, KC_D, KC_SPC, KC_QUOT, 0);
register_code (KC_RSFT);
register_code (KC_EQL);
unregister_code (KC_EQL);
unregister_code (KC_RSFT);
- uint16_t codes2[] = {KC_4, KC_SPC, KC_D, KC_A, KC_Y, KC_S, KC_QUOT, 0};
- ang_tap (codes2);
+ ang_tap (KC_4, KC_SPC, KC_D, KC_A, KC_Y, KC_S, KC_QUOT, 0);
return false;
}
@@ -1204,3 +1019,17 @@ bool process_record_user (uint16_t keycode, keyrecord_t *record) {
return true;
}
+
+void qk_ucis_symbol_fallback (void) {
+ for (uint8_t i = 0; i < qk_ucis_state.count - 1; i++) {
+ uint8_t code;
+
+ if ((qk_ucis_state.codes[i] >= M(A_1)) && (qk_ucis_state.codes[i] <= M(A_0)))
+ code = qk_ucis_state.codes[i] - M(A_1) + KC_1;
+ else
+ code = qk_ucis_state.codes[i];
+ register_code(code);
+ unregister_code(code);
+ wait_ms (10);
+ }
+}
diff --git a/keyboards/ergodox/keymaps/algernon/readme.md b/keyboards/ergodox/keymaps/algernon/readme.md
index 26dfddbe6a..f15b676528 100644
--- a/keyboards/ergodox/keymaps/algernon/readme.md
+++ b/keyboards/ergodox/keymaps/algernon/readme.md
@@ -3,23 +3,26 @@
algernon's layout
=======================
-This is an unconventional layout for the ErgoDox EZ. For more details about the history of the layout, see my [blog posts about my ErgoDox journey][blog-ergodox].
+This is an unconventional layout for the [ErgoDox EZ][ez]. For more details about the history of the layout, see my [blog posts about my ErgoDox journey][blog-ergodox].
+ [ez]: https://ergodox-ez.com/
[blog-ergodox]: https://asylum.madhouse-project.org/blog/tags/ergodox/
-Some of the things in the layout only work when one uses Spacemacs and GNOME under Linux. Your mileage may vary.
+Some of the things in the layout only work when one uses [Spacemacs][spacemacs] and [GNOME][gnome] under Linux. Your mileage may vary.
+
+ [spacemacs]: http://spacemacs.org/
+ [gnome]: https://www.gnome.org/
## Table of Contents
* [Layouts](#layouts)
- [Base layer](#base-layer)
- [ADORE layer](#adore-layer)
- - [Hungarian layer](#hungarian-layer)
- - [Navigation and media layer](#navigation-and-media-layer)
- [Steno layer](#steno-layer)
- [LED states](#led-states)
* [Tools](#tools)
- [Heatmap](#heatmap)
+ - [Layer notification](#layer-notification)
* [Special features](#special-features)
- [Unicode Symbol Input](#unicode-symbol-input)
* [Building](#building)
@@ -35,15 +38,15 @@ Some of the things in the layout only work when one uses Spacemacs and GNOME und
At its core, this is a Dvorak layout, with some minor changes. The more interesting parts are how certain keys behave:
-* The keys on the number row double as function keys, when held for a bit longer than an usual tap. This allows me to use the function keys without having to switch layers.
+* The number row is the same as in the [ADORE](#adore-layer) layer. The function keys are on the **Media** layer.
* The `Shift`, `Alt`, and `Control` modifiers are one-shot. When tapped, they are considered active for the next key press only. When double tapped, they toggle on, until a third, single tap sometime later. When held, they act as expected. My usual pattern is that I use these for the next keypress only, so this behaviour is perfect. If I need them held, I'll just double-tap.
* The `GUI` key is special, because when I double-tap it, it sends `GUI + w`, which pops up an application selector. It also switches to a one-shot layer, where the number row on the left half turns into app selector macros, for the most common things I usually want to switch to. Otherwise it behaves as on a normal layout.
* The `ESC` key also doubles as a one-shot cancel key: if tapped while any of the one-shot modifiers are in-flight (as in, single-tapped, and not expired yet), it cancels all one-shot modifiers. It also cancels the **Hun** layer, if active. Otherwise it sends the usual keycode.
* The **Media** and **Hun** layer keys are one-shot, the **STENO** key is a toggle.
-* When holding any of the **Arrow** layer keys, the arrow layer activates while the layer key is held. Tapping the key produces the normal key.
+* When holding the `Tab`/**Arrow** key, the arrow layer activates while the key is held. Tapping the key produces the normal, `Tab` key. Double-tapping it toggles the **Arrow** layer on until a third tap.
* Tapping the `:` key once yields `:`, tapping it twice yields `;`.
+* Tapping the `[{(`/`)}]` keys once yields `[` (or `{` when shifted), tapping them twice yields `(`.
* The **Lead** key allows me to type in a sequence of keys, and trigger some actions:
- - `LEAD u` enters unicode input mode, by sending the GTK+ key sequence that does this.
- `LEAD l` uses the unicode input method to enter a `λ`.
- `LEAD s` does a lot of magic to type in a shruggie: `¯\_(ツ)_/¯`
- `LEAD y` types `\o/`.
@@ -52,29 +55,17 @@ At its core, this is a Dvorak layout, with some minor changes. The more interest
- `LEAD v` prints the firmware version, the keyboard and the keymap.
- `LEAD d` toggles logging keypress positions to the HID console.
- `LEAD t` toggles time travel. Figuring out the current `date` is left as an exercise to the reader.
- - `LEAD LEAD u` enters the [Unicode symbol input][#unicode-symbol-input] mode.
+ - `LEAD u` enters the [Unicode symbol input](#unicode-symbol-input) mode.
+
+The symbols on the front in the image above have the same color as the key that activates them, with the exception of the **Arrow** layer, which is just black on the front.
## ADORE layer
[![ADORE layer](images/adore-layer.png)](http://www.keyboard-layout-editor.com/#/gists/45681a17453d235925b6028dd83bf12a)
-While using the standard Dvorak layout, I encountered a number of inconveniences, and on this layer, I am playing with ideas to make the layout feel better. Initially, it was based on [Capewell-Dvorak][cpd], but that too, had shortcomings I was not happy with. So now this is something inbetween, with own observations thrown in. How it works out in the long run remains to be seen.
-
- [cpd]: http://www.michaelcapewell.com/projects/keyboard/layout_capewell-dvorak.htm
-
-Based on a week and a half of typing, the keys were rearranged, and the home row neatly spelled out **ADORE**, that gave the layout its name.
-
-## Hungarian layer
-
-[![Hungarian layer](images/hun-layer.png)](http://www.keyboard-layout-editor.com/#/gists/b160f6ec90d58c127c114c89f66e9dc9)
-
-On this layer, the accented characters are at the same position as their base variant. For some, which can have other diatribes, the long one is on top, short's on bottom. Tapping any of the accented characters takes us back to the base layer.
+My experimental layout, that I keep tweaking. No full description here, because things are very much in flux.
-## Navigation and media layer
-
-[![Navigation and media layer](images/nav-n-media-layer.png)](http://www.keyboard-layout-editor.com/#/gists/c59c453f9fe1a3238ba1494e7e5c6892)
-
-This layer is primarily for navigating with the cursor or the mouse, and some media things.
+Note that the **HUN** layer does not work well with ADORE: it still has the same layout as on the [Base](#base-layer) layer. This will remain until ADORE becomes the default.
## Steno layer
@@ -89,8 +80,9 @@ The primary purpose of the LEDs is to show the modifier status, a secondary, to
For the layers, the following rules apply:
* When the [ADORE layer](#adore-layer) is toggled on, LEDs will light up from left to right in a sequence, then turn off. When the layer is toggled off, the LEDs light up and turn off in the other direction. No LEDs are on while the layer is active.
-* When the [Hungarian layer](#hungarian-layer) is active, the *green* and *blue* LEDs are on.
-* When the [Navigation and media layer](#navigation-and-media-layer) is active, the *red* and *green* ones are on.
+* When the **Hungarian** layer is active, the *green* and *blue* LEDs are on.
+* When the **Media** layer is active, the *red* and *green* ones are on.
+* When the **ARROW** layer is active, the *red* and *blue* ones are on.
* For the [Steno layer](#steno-layer), all LEDs will be turned on.
Unless noted otherwise, the layers use a dim light for the LEDs, while modifiers use a stronger one, and modifiers override any layer preferences. For example, when on the one-handed layer, with the left side active (*red* light blinking), if `Shift` is on, the *red* light will be constantly on.
@@ -116,7 +108,7 @@ This is an experimental feature, and may or may not work reliably.
When the keypress logging functionality is enabled (by `LEAD d`), the keyboard will output a line every time a key is pressed, containing the position of the key in the matrix. This allows one to collect this information, and build analytics over it, such as a heat map, including dead keys too.
-Included with the firmware is a small tool that can parse these logs, and create a heatmap that one can import into [KLE][kle]. To use it, simply point `tools/log-to-heatmap.py` to a base layout file (one is included in the `tools/` directory), and the key position log. The latter one can create by running `hid-listen`, and redirecting its output to a file.
+Included with the firmware is a small tool that can parse these logs, and create a heatmap that one can import into [KLE][kle]. To use it, either pipe the output of `hid_listen` into it, or pipe it an already saved log, and it will save the results into files in an output directory (given on the command-line). See the output of `tools/log-to-heatmap.py --help` for more information.
[kle]: http://www.keyboard-layout-editor.com/
@@ -124,6 +116,10 @@ The generated heatmap looks somewhat like this:
![Heatmap](images/heatmap.png)
+## Layer notification
+
+There is a very small tool in `tools/layer-notify`, that listens to the HID console, looking for layer change events, and pops up a notification for every detected change. It is a very simple tool, mainly serving as an example.
+
# Building
To make my workflow easier, this layout is maintained in [its own repository][algernon:ez-layout]. To build it, you will need the [QMK][qmk] firmware checked out, and this repo either checked out to something like `keyboards/ergodox_ez/algernon-master`. One way to achieve that is this:
@@ -151,7 +147,72 @@ The keymap default to forcing NKRO, which seems to upset Windows, and except the
# Changelog
-## v1.5 - 2016-08-12
+## v1.7
+
+*2016-09-18*
+
+### Overall changes
+
+* The number row has been completely rearranged on both the [Base](#base-layer) and the [ADORE](#adore-layer) layers.
+* The number/function key behavior was changed: function keys are now on the **Media**.
+* The `:`/`;` and `-`/`_` keys were put back to their thumb position on the bottom row, on both the [Base](#base-layer) and [ADORE](#adore-layer) layers.
+* The bottom large keys on the inner side of each half now function as [tmux](http://tmux.github.io/) keys: the left to send the prefix, the right to send the `display-panes` key. The left also doubles as a GNU screen prefix key, and sends `C-a` when double tapped.
+* A number of functions, such as the **AppSel** layer, now require the `hid-commands` tool to be running, with the output of `hid_listen` being piped to it.
+
+### ADORE
+
+* `Y` and `X` have been swapped again.
+
+### Media/Navigation layer
+
+* The function keys are now on this layer.
+* Mouse keys have been removed.
+* Media start/stop/prev/next have been removed.
+* `Print screen` has been removed.
+* There is only one screen lock key now.
+
+### Heatmap
+
+* Fixed a few issues in the finger-stats calculation.
+* The tool now also timestamps and saves all input lines to a logfile, which it loads on start, allowing one to continue the collection after upgrading the tool.
+* The heatmap tool will now colorize the stats by default.
+* The periodic stats are now printed in a more compact format.
+
+### Tools
+
+* Added a new tool, `tools/layer-notify` that listens to layer change events on the HID console, and pops up a notification on layer changes.
+* Another new tool, `tools/text-to-log.py` has been added that converts arbitrary text to a keylogger output, which can be fed to the heatmap generator.
+* A number of features have been moved to the `tools/hid-commands` utility. These generally are OS dependent, and are easier to implement on the software side.
+
+## v1.6
+
+*2016-08-24*
+
+### Base layer changes
+
+* The parentheses & bracket keys have been merged: tapping them results in `[` or `{` (if it was shifted), double tapping leads to `(`.
+* The `:;` and `-_` keys are now available on the base layer, on their [ADORE](#adore-layer) location, too, just below `[{(`/`]})`.
+* The `Apps` key has been replaced by `F12`.
+* The `-`/`_` is no longer a tap-dance key.
+
+### ADORE layer changes
+
+* Adjustments were made to the [ADORE](#adore-layer) layer, to separate some inconvenient combinations.
+
+### Miscellaneous changes
+
+* `LEAD u` now starts the symbolic unicode input system, instead of the OS-one.
+* The mouse acceleration keys on the **Navigation/Media** layer have been turned into toggles: tap them once to turn them on, until tapped again. Tapping an accelerator button will turn all the others off.
+* When the **ARROW** layer is on, the *red* and *blue* LEDs light up now.
+
+### Heatmap
+
+* The built-in keylogger has been greatly enhanced, it now outputs the pressed state, and the layer (Dvorak or ADORE). As such, the `ADORE_AUTOLOG` option has been removed, instead there is `AUTOLOG_ENABLE` now, which when enabled, makes the keylogger start when the keyboard boots. It defaults to off.
+* The heatmap generator received a lot of updates.
+
+## v1.5
+
+*2016-08-12*
* The **1HAND** layer has been removed.
* A `Delete` key is now available on the right thumb cluster.
@@ -161,7 +222,9 @@ The keymap default to forcing NKRO, which seems to upset Windows, and except the
* On the **ARROW** layer, `Backspace` has been replaced by `Enter`.
* There is some experimental support for entering Unicode symbols.
-## v1.4 - 2016-07-29
+## v1.4
+
+*2016-07-29*
* When toggling the key logging on or off, the LEDs will do a little dance.
* The keylogger is now optional, but enabled by default. Use `KEYLOGGER_ENABLE=no` on the `make` command line to disable it.
@@ -169,25 +232,31 @@ The keymap default to forcing NKRO, which seems to upset Windows, and except the
* The `-`/`_` key was turned into a tap-dance key too.
* There is now a way to travel time with the keyboard, toggle the feature on by hitting `LEAD t`.
-## v1.3 - 2016-07-06
+## v1.3
+
+*2016-07-06*
* Added support for logging keys, by pressing `LEAD d`. Also included is a tool to generate a [heatmap](#heatmap) out of the logs.
* The arrow and navigation keys were rearranged again, and now require an additional key being held to activate. See the [base layer](#base-layer) for an image that shows where arrows are.
* The **experimental** layer has been redone, and is now called [ADORE](#adore-layer), and as such, can be enabled by `LEAD a` now.
* Switching between Dvorak and ADORE is now persisted into EEPROM, and survives a reboot.
-## v1.2 - 2016-06-22
+## v1.2
+
+*2016-06-22*
* The forced NKRO mode can be easily toggled off at compile-time, to make the firmware compatible with [certain operating systems](#using-on-windows).
* The `:;` key has changed behaviour: to access the `;` symbol, the key needs to be double-tapped, instead of shifted.
* The `=` and `\` keys were swapped, `=` moved to the home row, on both the [base](#base-layer) and the **experimental** layers.
* The arrow and navigation keys were redone, they are now more accessible, but the navigation keys require an extra tap to access.
-* The **Emacs** layer is gone, replaced by a simplified [navigation and media](#navigation-and-media-layer) layer.
+* The **Emacs** layer is gone, replaced by a simplified **navigation and media** layer.
* `LEAD v` types the firmware version, and the keymap version.
* On the **experimental** layer, the `L` and `Q`, and the `K` and `G` keys were swapped.
* The [Steno](#steno-layer) layer gained a few more `#` and `*` keys, to make it easier on my fingers.
-## v1.1 - 2016-06-14
+## v1.1
+
+*2016-06-14*
* The keyboard starts in NKRO mode, bootmagic and other things are disabled.
* A [Steno](#steno-layer) layer was added, to be used with Plover.
@@ -199,9 +268,11 @@ The keymap default to forcing NKRO, which seems to upset Windows, and except the
- `-` on the left half was replaced by `Tab`.
- `Tab`'s original position is taken by a `Media Next`/`Media Prev` key.
- `:` now inputs `;` when shifted.
-* `ESC` cancels the [Hungarian](#hungarian-layer) layer too, not just modifiers.
+* `ESC` cancels the **Hungarian** layer too, not just modifiers.
+
+## v1.0
-## v1.0 - 2016-05-26
+*2016-05-26*
Initial version.
diff --git a/keyboards/ergodox/keymaps/algernon/tools/heatmap-adore-layout.json b/keyboards/ergodox/keymaps/algernon/tools/heatmap-layout.ADORE.json
index 544f61ce87..502d1e6ea4 100644
--- a/keyboards/ergodox/keymaps/algernon/tools/heatmap-adore-layout.json
+++ b/keyboards/ergodox/keymaps/algernon/tools/heatmap-layout.ADORE.json
@@ -13,18 +13,15 @@
[
{
"x": 3.5,
- "c": "#a7d0db",
"fa": [
0,
0,
2
]
},
- "#\n3\nF3",
+ "*\n5\nF5",
{
"x": 10.5,
- "c": "#a7d0db",
- "t": "#000000",
"a": 4,
"fa": [
0,
@@ -32,54 +29,44 @@
2
]
},
- "*\n8\nF8"
+ "#\n4\nF4"
],
[
{
"y": -0.875,
- "x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 2.5
},
- "@\n2\nF2",
+ "@\n7\nF7",
{
- "x": 1,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 1
},
- "$\n4\nF4",
+ "^\n3\nF3",
{
"x": 8.5
},
- "&\n7\nF7",
+ "!\n2\nF2",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
- "(\n9\nF9"
+ "&\n6\nF6"
],
[
{
"y": -0.875,
- "x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 5.5
},
- "%\n5\nF5",
+ "$\n1\nF1",
{
- "c": "#f9cd31",
"a": 7,
- "f": 2
+ "f": 3
},
- "STENO",
+ "F11",
{
"x": 4.5,
- "f": 6
+ "f": 3
},
- "<i class='mss mss-Unicode-Option-3'></i>",
+ "F12",
{
- "c": "#7adabd",
"a": 4,
"f": 3,
"fa": [
@@ -88,39 +75,43 @@
2
]
},
- "^\n6\nF6"
+ "%\n0\nF10"
],
[
{
"y": -0.875,
- "c": "#ffb2d2",
- "f": 3,
+ "f": 9,
+ "a": 6,
"w": 1.5
},
- "\n\n~\n`",
+ "\n\n<i class='kb kb-Multimedia-Play-Pause'></i>",
{
- "t": "#0d0d0b"
+ "f": 3,
+ "a": 4,
+ "fa": [
+ 0,
+ 0,
+ 2
+ ]
},
- "!\n1\nF1",
+ " \n9\nF9",
{
"x": 14.5
},
- ")\n0\nF10",
+ " \n8\nF8",
{
"a": 7,
"w": 1.5
},
- "F11"
+ "STENO"
],
[
{
"y": -0.375,
"x": 3.5,
- "c": "#a7d0db",
- "t": "#000000",
"a": 6
},
- "L",
+ "G",
{
"x": 10.5
},
@@ -130,50 +121,41 @@
{
"y": -0.875,
"x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b",
- "a": 4
+ "a": 6
},
- ">\n.",
+ "W",
{
"x": 1,
- "c": "#7adabd",
- "t": "#000000",
"a": 6
},
- "W",
+ "L",
{
"x": 8.5
},
"H",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
"P"
],
[
{
"y": -0.875,
- "x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 5.5
},
"M",
{
- "c": "#93c9b7",
"a": 4,
+ "fa": [0, 0, 0],
"h": 1.5
},
- "{\n[",
+ "{\n(\n[",
{
"x": 4.5,
"h": 1.5
},
- "}\n]",
+ "}\n)\n]",
{
- "c": "#7adabd",
"a": 6
},
"F"
@@ -181,18 +163,16 @@
[
{
"y": -0.875,
- "c": "#ffb07b",
- "t": "#0d0d0b",
- "f": 6,
+ "f": 3,
+ "a": 4,
"w": 1.5
},
- "<i class='fa fa-fast-backward'></i>\n\n<i class='fa fa-fast-forward'></i>",
+ "\n\n~\n`",
{
- "c": "#ffb2d2",
- "a": 4,
+ "a": 6,
"f": 3
},
- "<\n,",
+ "X",
{
"x": 14.5,
"a": 6
@@ -208,8 +188,6 @@
{
"y": -0.375,
"x": 3.5,
- "c": "#a7d0db",
- "t": "#000000",
"a": 6
},
"E",
@@ -221,15 +199,11 @@
[
{
"y": -0.875,
- "x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 2.5
},
"O",
{
"x": 1,
- "c": "#7adabd",
- "t": "#000000",
"n": true
},
"I",
@@ -239,18 +213,14 @@
},
"R",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
"N"
],
[
{
"y": -0.875,
- "x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 5.5
},
"U",
{
@@ -261,8 +231,6 @@
[
{
"y": -0.875,
- "c": "#ffb2d2",
- "t": "#0d0d0b",
"fa": [
6
],
@@ -298,29 +266,29 @@
{
"y": -0.625,
"x": 6.5,
- "c": "#93c9b7",
- "t": "#000000",
"a": 7,
+ "f": 9,
"h": 1.5
},
- "(",
+ "<i class='fa fa-columns'></i>",
{
"x": 4.5,
"h": 1.5
},
- ")"
+ "<i class='fa fa-table'></i>"
],
[
{
"y": -0.75,
"x": 3.5,
- "c": "#a7d0db",
"a": 4,
"f": 3
},
"\"\n'",
{
- "x": 10.5
+ "x": 10.5,
+ "a": 6,
+ "f": 3
},
"V"
],
@@ -328,24 +296,21 @@
{
"y": -0.875,
"x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "a": 6
},
- "Z",
+ "Q",
{
"x": 1,
- "c": "#7adabd",
- "t": "#000000"
+ "a": 4
},
- "K",
+ "<\n,",
{
- "x": 8.5
+ "x": 8.5,
+ "a": 6
},
- "G",
+ "K",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
"J"
],
@@ -353,48 +318,46 @@
{
"y": -0.875,
"x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "a": 4
},
- "X",
+ ">\n.",
{
- "x": 6.5
+ "x": 6.5,
+ "a": 6
},
"B"
],
[
{
"y": -0.875,
- "c": "#ffb07b",
"f": 9,
- "w": 1.5
+ "w": 1.5,
+ "g": true
},
- "\n\n<i class='kb kb-Multimedia-Play-Pause'></i>",
+ "",
{
- "c": "#ffb2d2",
- "t": "#0d0d0b",
- "a": 4,
- "f": 3
+ "a": 6,
+ "f": 3,
+ "g": false
},
- "?\n/",
+ "Z",
{
"x": 14.5,
- "a": 6
+ "a": 4
},
- "Q",
+ "?\n/",
{
- "c": "#ffb07b",
- "t": "#000000",
"f": 9,
- "w": 1.5
+ "g": true,
+ "w": 1.5,
+ "a": 4
},
- "<i class='kb kb-Multimedia-Stop'></i>"
+ ""
],
[
{
"y": -0.375,
"x": 3.5,
- "c": "#d9dae0",
"g": true,
"a": 7,
"f": 3
@@ -413,7 +376,6 @@
"",
{
"x": 1,
- "c": "#d4872a",
"g": false,
"a": 5
},
@@ -424,7 +386,6 @@
"_\n-",
{
"x": 1,
- "c": "#d9dae0",
"g": true,
"a": 7
},
@@ -452,7 +413,6 @@
"ry": 4.25,
"y": -1,
"x": 1,
- "c": "#f9cd31",
"g": false
},
"Alt",
@@ -469,7 +429,6 @@
],
[
{
- "c": "#d4872a",
"a": 7,
"f": 9,
"h": 2
@@ -480,15 +439,13 @@
},
"<i class='fa fa-angle-double-up'></i>",
{
- "c": "#f9cd31",
"f": 3
},
"Ctrl"
],
[
{
- "x": 2,
- "c": "#e26757"
+ "x": 2
},
"ESC"
],
@@ -498,20 +455,18 @@
"rx": 13,
"y": -1,
"x": -3,
- "c": "#f9cd31",
"f": 2
},
"MEDIA",
{},
- "1HAND"
+ "DEL"
],
[
{
"x": -3
},
- "LEAD",
+ "HUN",
{
- "c": "#d4872a",
"f": 9,
"h": 2
},
@@ -525,9 +480,8 @@
[
{
"x": -3,
- "c": "#f9cd31",
"f": 2
},
- "HUN"
+ "LEAD"
]
]
diff --git a/keyboards/ergodox/keymaps/algernon/tools/heatmap-base-layout.json b/keyboards/ergodox/keymaps/algernon/tools/heatmap-layout.Dvorak.json
index 148bb1f23b..5b4ca06c30 100644
--- a/keyboards/ergodox/keymaps/algernon/tools/heatmap-base-layout.json
+++ b/keyboards/ergodox/keymaps/algernon/tools/heatmap-layout.Dvorak.json
@@ -13,18 +13,15 @@
[
{
"x": 3.5,
- "c": "#a7d0db",
"fa": [
0,
0,
2
]
},
- "#\n3\nF3",
+ "*\n5\nF5",
{
"x": 10.5,
- "c": "#a7d0db",
- "t": "#000000",
"a": 4,
"fa": [
0,
@@ -32,54 +29,44 @@
2
]
},
- "*\n8\nF8"
+ "#\n4\nF4"
],
[
{
"y": -0.875,
- "x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 2.5
},
- "@\n2\nF2",
+ "@\n7\nF7",
{
- "x": 1,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 1
},
- "$\n4\nF4",
+ "^\n3\nF3",
{
"x": 8.5
},
- "&\n7\nF7",
+ "!\n2\nF2",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
- "(\n9\nF9"
+ "&\n6\nF6"
],
[
{
"y": -0.875,
- "x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 5.5
},
- "%\n5\nF5",
+ "$\n1\nF1",
{
- "c": "#f9cd31",
"a": 7,
- "f": 2
+ "f": 3
},
- "STENO",
+ "F11",
{
"x": 4.5,
- "f": 6
+ "f": 3
},
- "<i class='mss mss-Unicode-Option-3'></i>",
+ "F12",
{
- "c": "#7adabd",
"a": 4,
"f": 3,
"fa": [
@@ -88,36 +75,41 @@
2
]
},
- "^\n6\nF6"
+ "%\n0\nF10"
],
[
{
"y": -0.875,
- "c": "#ffb2d2",
- "f": 3,
+ "f": 6,
+ "a": 6,
"w": 1.5
},
- "\n\n~\n`",
+ "<i class='fa fa-fast-backward'></i>\n\n<i class='fa fa-fast-forward'></i>",
{
- "t": "#0d0d0b"
+ "f": 3,
+ "a": 4,
+ "fa": [
+ 0,
+ 0,
+ 2
+ ]
+
},
- "!\n1\nF1",
+ " \n9\nF9",
{
"x": 14.5
},
- ")\n0\nF10",
+ " \n8\nF8",
{
"a": 7,
"w": 1.5
},
- "F11"
+ "STENO"
],
[
{
"y": -0.375,
"x": 3.5,
- "c": "#a7d0db",
- "t": "#000000",
"a": 4
},
">\n.",
@@ -131,15 +123,11 @@
{
"y": -0.875,
"x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b",
"a": 4
},
"<\n,",
{
"x": 1,
- "c": "#7adabd",
- "t": "#000000",
"a": 6
},
"P",
@@ -148,33 +136,27 @@
},
"G",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
"R"
],
[
{
"y": -0.875,
- "x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 5.5
},
"Y",
{
- "c": "#93c9b7",
"a": 4,
"h": 1.5
},
- "{\n[",
+ "{\n(\n[",
{
"x": 4.5,
"h": 1.5
},
- "}\n]",
+ "}\n)\n]",
{
- "c": "#7adabd",
"a": 6
},
"F"
@@ -182,14 +164,12 @@
[
{
"y": -0.875,
- "c": "#ffb07b",
- "t": "#0d0d0b",
- "f": 6,
+ "f": 3,
+ "a": 4,
"w": 1.5
},
- "<i class='fa fa-fast-backward'></i>\n\n<i class='fa fa-fast-forward'></i>",
+ "\n\n~\n`",
{
- "c": "#ffb2d2",
"a": 4,
"f": 3
},
@@ -209,8 +189,6 @@
{
"y": -0.375,
"x": 3.5,
- "c": "#a7d0db",
- "t": "#000000",
"a": 6
},
"E",
@@ -222,15 +200,11 @@
[
{
"y": -0.875,
- "x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 2.5
},
"O",
{
"x": 1,
- "c": "#7adabd",
- "t": "#000000",
"n": true
},
"U",
@@ -240,18 +214,14 @@
},
"H",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
"N"
],
[
{
"y": -0.875,
- "x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 5.5
},
"I",
{
@@ -262,8 +232,6 @@
[
{
"y": -0.875,
- "c": "#ffb2d2",
- "t": "#0d0d0b",
"fa": [
6
],
@@ -299,23 +267,22 @@
{
"y": -0.625,
"x": 6.5,
- "c": "#93c9b7",
- "t": "#000000",
"a": 7,
+ "f": 9,
"h": 1.5
},
- "(",
+ "<i class='fa fa-columns'></i>",
{
"x": 4.5,
"h": 1.5
},
- ")"
+ "<i class='fa fa-table'></i>"
],
[
{
"y": -0.75,
"x": 3.5,
- "c": "#a7d0db",
+ "f": 3,
"a": 6
},
"J",
@@ -327,15 +294,11 @@
[
{
"y": -0.875,
- "x": 2.5,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 2.5
},
"Q",
{
- "x": 1,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 1
},
"K",
{
@@ -343,18 +306,14 @@
},
"M",
{
- "x": 1,
- "c": "#bfbad1",
- "t": "#0d0d0b"
+ "x": 1
},
"V"
],
[
{
"y": -0.875,
- "x": 5.5,
- "c": "#7adabd",
- "t": "#000000"
+ "x": 5.5
},
"X",
{
@@ -365,14 +324,11 @@
[
{
"y": -0.875,
- "c": "#ffb07b",
"f": 9,
"w": 1.5
},
"\n\n<i class='kb kb-Multimedia-Play-Pause'></i>",
{
- "c": "#ffb2d2",
- "t": "#0d0d0b",
"a": 4,
"f": 3
},
@@ -383,8 +339,6 @@
},
"Z",
{
- "c": "#ffb07b",
- "t": "#000000",
"f": 9,
"w": 1.5
},
@@ -394,7 +348,6 @@
{
"y": -0.375,
"x": 3.5,
- "c": "#d9dae0",
"g": true,
"a": 7,
"f": 3
@@ -413,7 +366,6 @@
"",
{
"x": 1,
- "c": "#d4872a",
"g": false,
"a": 5
},
@@ -424,7 +376,6 @@
"_\n-",
{
"x": 1,
- "c": "#d9dae0",
"g": true,
"a": 7
},
@@ -452,7 +403,6 @@
"ry": 4.25,
"y": -1,
"x": 1,
- "c": "#f9cd31",
"g": false
},
"Alt",
@@ -469,7 +419,6 @@
],
[
{
- "c": "#d4872a",
"a": 7,
"f": 9,
"h": 2
@@ -480,15 +429,13 @@
},
"<i class='fa fa-angle-double-up'></i>",
{
- "c": "#f9cd31",
"f": 3
},
"Ctrl"
],
[
{
- "x": 2,
- "c": "#e26757"
+ "x": 2
},
"ESC"
],
@@ -498,12 +445,11 @@
"rx": 13,
"y": -1,
"x": -3,
- "c": "#f9cd31",
"f": 2
},
"MEDIA",
{},
- "1HAND"
+ "DEL"
],
[
{
@@ -511,7 +457,6 @@
},
"LEAD",
{
- "c": "#d4872a",
"f": 9,
"h": 2
},
@@ -525,7 +470,6 @@
[
{
"x": -3,
- "c": "#f9cd31",
"f": 2
},
"HUN"
diff --git a/keyboards/ergodox/keymaps/algernon/tools/hid-commands b/keyboards/ergodox/keymaps/algernon/tools/hid-commands
new file mode 100755
index 0000000000..f3b83cf6d1
--- /dev/null
+++ b/keyboards/ergodox/keymaps/algernon/tools/hid-commands
@@ -0,0 +1,61 @@
+#!/bin/bash
+set -e
+
+cmd_wm () {
+ WIN="$(xdotool getactivewindow)"
+ wmctrl -i -r ${WIN} -b remove,maximized_vert,maximized_horz
+ xdotool windowsize ${WIN} 100% 100%
+ wmctrl -i -r ${WIN} -b add,maximized_vert,maximized_horz
+}
+
+_cmd_appsel () {
+ wmctrl -x -a $1 || true
+ xdotool key Escape
+}
+
+cmd_appsel_music () {
+ wmctrl -x -a rhythmbox || wmctrl -x -a spotify || true
+ xdotool key Escape
+}
+
+cmd_appsel_slack () {
+ _cmd_appsel slack
+}
+
+cmd_appsel_emacs () {
+ _cmd_appsel emacs24
+}
+
+cmd_appsel_term () {
+ _cmd_appsel gnome-terminal
+}
+
+cmd_appsel_chrome () {
+ _cmd_appsel chromium
+}
+
+cmd_help () {
+ cat <<EOF
+Use the source, Luke!
+EOF
+}
+
+while read l; do
+ case "$l" in
+ "CMD:"*)
+ ;;
+ *)
+ continue
+ ;;
+ esac
+
+ cmd="$(echo $l | cut -d: -f2-)"
+
+ echo "Got command: ${cmd}"
+
+ if type cmd_${cmd} >/dev/null 2>&1; then
+ cmd_${cmd}
+ fi
+done
+
+
diff --git a/keyboards/ergodox/keymaps/algernon/tools/layer-notify b/keyboards/ergodox/keymaps/algernon/tools/layer-notify
new file mode 100755
index 0000000000..627c2861ef
--- /dev/null
+++ b/keyboards/ergodox/keymaps/algernon/tools/layer-notify
@@ -0,0 +1,12 @@
+#!/bin/sh
+HL="${HID_LISTEN:-$HOME/src/ext/hid_listen/hid_listen}"
+
+sudo "${HL}" | grep --line-buffered LAYER: | \
+(while read line; do
+ case $line in
+ LAYER:*)
+ layer="$(echo $(echo $line | cut -d: -f2-))"
+ notify-send -i mark-location-symbolic "Switched to layer: $layer"
+ ;;
+ esac
+ done)
diff --git a/keyboards/ergodox/keymaps/algernon/tools/log-to-heatmap.py b/keyboards/ergodox/keymaps/algernon/tools/log-to-heatmap.py
index a13d12e81a..09c737646c 100755
--- a/keyboards/ergodox/keymaps/algernon/tools/log-to-heatmap.py
+++ b/keyboards/ergodox/keymaps/algernon/tools/log-to-heatmap.py
@@ -1,145 +1,339 @@
-#! /usr/bin/env python
+#! /usr/bin/env python3
import json
import os
import sys
import re
+import argparse
+import time
from math import floor
+from os.path import dirname
+from subprocess import Popen, PIPE, STDOUT
+from blessings import Terminal
-cr_coord_map = [
- [
- # Row 0
- [ 4, 0], [ 4, 2], [ 2, 0], [ 1, 0], [ 2, 2], [ 3, 0], [ 3, 2],
- [ 3, 4], [ 3, 6], [ 2, 4], [ 1, 2], [ 2, 6], [ 4, 4], [ 4, 6],
- ],
- [
- # Row 1
- [ 8, 0], [ 8, 2], [ 6, 0], [ 5, 0], [ 6, 2], [ 7, 0], [ 7, 2],
- [ 7, 4], [ 7, 6], [ 6, 4], [ 5, 2], [ 6, 6], [ 8, 4], [ 8, 6],
- ],
- [
- # Row 2
- [12, 0], [12, 2], [10, 0], [ 9, 0], [10, 2], [11, 0], [ ],
- [ ], [11, 2], [10, 4], [ 9, 2], [10, 6], [12, 4], [12, 6],
- ],
- [
- # Row 3
- [17, 0], [17, 2], [15, 0], [14, 0], [15, 2], [16, 0], [13, 0],
- [13, 2], [16, 2], [15, 4], [14, 2], [15, 6], [17, 4], [17, 6],
- ],
- [
- # Row 4
- [20, 0], [20, 2], [19, 0], [18, 0], [19, 2], [], [], [], [],
- [19, 4], [18, 2], [19, 6], [20, 4], [20, 6],
- ],
- [
- # Row 5
- [ ], [23, 0], [22, 2], [22, 0], [22, 4], [21, 0], [21, 2],
- [24, 0], [24, 2], [25, 0], [25, 4], [25, 2], [26, 0], [ ],
- ],
-]
-
-def set_attr_at(j, b, n, attr, fn, val):
- blk = j[b][n]
- if attr in blk:
- blk[attr] = fn(blk[attr], val)
+class Heatmap(object):
+ coords = [
+ [
+ # Row 0
+ [ 4, 0], [ 4, 2], [ 2, 0], [ 1, 0], [ 2, 2], [ 3, 0], [ 3, 2],
+ [ 3, 4], [ 3, 6], [ 2, 4], [ 1, 2], [ 2, 6], [ 4, 4], [ 4, 6],
+ ],
+ [
+ # Row 1
+ [ 8, 0], [ 8, 2], [ 6, 0], [ 5, 0], [ 6, 2], [ 7, 0], [ 7, 2],
+ [ 7, 4], [ 7, 6], [ 6, 4], [ 5, 2], [ 6, 6], [ 8, 4], [ 8, 6],
+ ],
+ [
+ # Row 2
+ [12, 0], [12, 2], [10, 0], [ 9, 0], [10, 2], [11, 0], [ ],
+ [ ], [11, 2], [10, 4], [ 9, 2], [10, 6], [12, 4], [12, 6],
+ ],
+ [
+ # Row 3
+ [17, 0], [17, 2], [15, 0], [14, 0], [15, 2], [16, 0], [13, 0],
+ [13, 2], [16, 2], [15, 4], [14, 2], [15, 6], [17, 4], [17, 6],
+ ],
+ [
+ # Row 4
+ [20, 0], [20, 2], [19, 0], [18, 0], [19, 2], [], [], [], [],
+ [19, 4], [18, 2], [19, 6], [20, 4], [20, 6], [], [], [], []
+ ],
+ [
+ # Row 5
+ [ ], [23, 0], [22, 2], [22, 0], [22, 4], [21, 0], [21, 2],
+ [24, 0], [24, 2], [25, 0], [25, 4], [25, 2], [26, 0], [ ],
+ ],
+ ]
+
+ def set_attr_at(self, block, n, attr, fn, val):
+ blk = self.heatmap[block][n]
+ if attr in blk:
+ blk[attr] = fn(blk[attr], val)
+ else:
+ blk[attr] = fn(None, val)
+
+ def coord(self, col, row):
+ return self.coords[row][col]
+
+ @staticmethod
+ def set_attr(orig, new):
+ return new
+
+ def set_bg(self, coords, color):
+ (block, n) = coords
+ self.set_attr_at(block, n, "c", self.set_attr, color)
+ #self.set_attr_at(block, n, "g", self.set_attr, False)
+
+ def set_tap_info(self, coords, count, cap):
+ (block, n) = coords
+ def _set_tap_info(o, _count, _cap):
+ ns = 4 - o.count ("\n")
+ return o + "\n" * ns + "%.02f%%" % (float(_count) / float(_cap) * 100)
+
+ if not cap:
+ cap = 1
+ self.heatmap[block][n + 1] = _set_tap_info (self.heatmap[block][n + 1], count, cap)
+
+ @staticmethod
+ def heatmap_color (v):
+ colors = [ [0.3, 0.3, 1], [0.3, 1, 0.3], [1, 1, 0.3], [1, 0.3, 0.3]]
+ fb = 0
+ if v <= 0:
+ idx1, idx2 = 0, 0
+ elif v >= 1:
+ idx1, idx2 = len(colors) - 1, len(colors) - 1
+ else:
+ val = v * (len(colors) - 1)
+ idx1 = int(floor(val))
+ idx2 = idx1 + 1
+ fb = val - float(idx1)
+
+ r = (colors[idx2][0] - colors[idx1][0]) * fb + colors[idx1][0]
+ g = (colors[idx2][1] - colors[idx1][1]) * fb + colors[idx1][1]
+ b = (colors[idx2][2] - colors[idx1][2]) * fb + colors[idx1][2]
+
+ r, g, b = [x * 255 for x in (r, g, b)]
+ return "#%02x%02x%02x" % (int(r), int(g), int(b))
+
+ def __init__(self, layout):
+ self.log = {}
+ self.total = 0
+ self.max_cnt = 0
+ self.layout = layout
+
+ def update_log(self, coords):
+ (c, r) = coords
+ if not (c, r) in self.log:
+ self.log[(c, r)] = 0
+ self.log[(c, r)] = self.log[(c, r)] + 1
+ self.total = self.total + 1
+ if self.max_cnt < self.log[(c, r)]:
+ self.max_cnt = self.log[(c, r)]
+
+ def get_heatmap(self):
+ with open("%s/heatmap-layout.%s.json" % (dirname(sys.argv[0]), self.layout), "r") as f:
+ self.heatmap = json.load (f)
+
+ ## Reset colors
+ for row in self.coords:
+ for coord in row:
+ if coord != []:
+ self.set_bg (coord, "#d9dae0")
+
+ for (c, r) in self.log:
+ coords = self.coord(c, r)
+ b, n = coords
+ cap = self.max_cnt
+ if cap == 0:
+ cap = 1
+ v = float(self.log[(c, r)]) / cap
+ self.set_bg (coords, self.heatmap_color (v))
+ self.set_tap_info (coords, self.log[(c, r)], self.total)
+ return self.heatmap
+
+ def get_stats(self):
+ usage = [
+ # left hand
+ [0, 0, 0, 0, 0],
+ # right hand
+ [0, 0, 0, 0, 0]
+ ]
+ finger_map = [0, 0, 1, 2, 3, 3, 3, 1, 1, 1, 2, 3, 4, 4]
+ for (c, r) in self.log:
+ if r == 5: # thumb cluster
+ if c <= 6: # left side
+ usage[0][4] = usage[0][4] + self.log[(c, r)]
+ else:
+ usage[1][0] = usage[1][0] + self.log[(c, r)]
+ else:
+ fc = c
+ hand = 0
+ if fc >= 7:
+ hand = 1
+ fm = finger_map[fc]
+ usage[hand][fm] = usage[hand][fm] + self.log[(c, r)]
+ hand_usage = [0, 0]
+ for f in usage[0]:
+ hand_usage[0] = hand_usage[0] + f
+ for f in usage[1]:
+ hand_usage[1] = hand_usage[1] + f
+
+ total = self.total
+ if total == 0:
+ total = 1
+ stats = {
+ "total-keys": total,
+ "hands": {
+ "left": {
+ "usage": round(float(hand_usage[0]) / total * 100, 2),
+ "fingers": {
+ "pinky": 0,
+ "ring": 0,
+ "middle": 0,
+ "index": 0,
+ "thumb": 0,
+ }
+ },
+ "right": {
+ "usage": round(float(hand_usage[1]) / total * 100, 2),
+ "fingers": {
+ "thumb": 0,
+ "index": 0,
+ "middle": 0,
+ "ring": 0,
+ "pinky": 0,
+ }
+ },
+ }
+ }
+
+ hmap = ['left', 'right']
+ fmap = ['pinky', 'ring', 'middle', 'index', 'thumb',
+ 'thumb', 'index', 'middle', 'ring', 'pinky']
+ for hand_idx in range(len(usage)):
+ hand = usage[hand_idx]
+ for finger_idx in range(len(hand)):
+ stats['hands'][hmap[hand_idx]]['fingers'][fmap[finger_idx + hand_idx * 5]] = round(float(hand[finger_idx]) / total * 100, 2)
+ return stats
+
+def dump_all(out_dir, heatmaps):
+ stats = {}
+ t = Terminal()
+ t.clear()
+ sys.stdout.write("\x1b[2J\x1b[H")
+
+ print ('{t.underline}{outdir}{t.normal}\n'.format(t=t, outdir=out_dir))
+
+ keys = list(heatmaps.keys())
+ keys.sort()
+
+ for layer in keys:
+ if len(heatmaps[layer].log) == 0:
+ continue
+
+ with open ("%s/%s.json" % (out_dir, layer), "w") as f:
+ json.dump(heatmaps[layer].get_heatmap(), f)
+ stats[layer] = heatmaps[layer].get_stats()
+
+ left = stats[layer]['hands']['left']
+ right = stats[layer]['hands']['right']
+
+ print ('{t.bold}{layer}{t.normal} ({total:,} taps):'.format(t=t, layer=layer,
+ total=int(stats[layer]['total-keys'] / 2)))
+ print (('{t.underline} | ' + \
+ 'left ({l[usage]:6.2f}%) | ' + \
+ 'right ({r[usage]:6.2f}%) |{t.normal}').format(t=t, l=left, r=right))
+ print ((' {t.bright_magenta}pinky{t.white} | {left[pinky]:6.2f}% | {right[pinky]:6.2f}% |\n' + \
+ ' {t.bright_cyan}ring{t.white} | {left[ring]:6.2f}% | {right[ring]:6.2f}% |\n' + \
+ ' {t.bright_blue}middle{t.white} | {left[middle]:6.2f}% | {right[middle]:6.2f}% |\n' + \
+ ' {t.bright_green}index{t.white} | {left[index]:6.2f}% | {right[index]:6.2f}% |\n' + \
+ ' {t.bright_red}thumb{t.white} | {left[thumb]:6.2f}% | {right[thumb]:6.2f}% |\n' + \
+ '').format(left=left['fingers'], right=right['fingers'], t=t))
+
+def process_line(line, heatmaps, opts, stamped_log = None):
+ m = re.search ('KL: col=(\d+), row=(\d+), pressed=(\d+), layer=(.*)', line)
+ if not m:
+ return False
+ if stamped_log is not None:
+ if line.startswith("KL:"):
+ print ("%10.10f %s" % (time.time(), line),
+ file = stamped_log, end = '')
+ else:
+ print (line,
+ file = stamped_log, end = '')
+ stamped_log.flush()
+
+ (c, r, l) = (int(m.group (2)), int(m.group (1)), m.group (4))
+ if (c, r) not in opts.allowed_keys:
+ return False
+
+ heatmaps[l].update_log ((c, r))
+
+ return True
+
+def setup_allowed_keys(opts):
+ if len(opts.only_key):
+ incmap={}
+ for v in opts.only_key:
+ m = re.search ('(\d+),(\d+)', v)
+ if not m:
+ continue
+ (c, r) = (int(m.group(1)), int(m.group(2)))
+ incmap[(c, r)] = True
else:
- blk[attr] = fn(None, val)
+ incmap={}
+ for r in range(0, 6):
+ for c in range(0, 14):
+ incmap[(c, r)] = True
+
+ for v in opts.ignore_key:
+ m = re.search ('(\d+),(\d+)', v)
+ if not m:
+ continue
+ (c, r) = (int(m.group(1)), int(m.group(2)))
+ del(incmap[(c, r)])
+
+ return incmap
-def coord(col, row):
- return cr_coord_map[row][col]
+def main(opts):
+ heatmaps = {"Dvorak": Heatmap("Dvorak"),
+ "ADORE": Heatmap("ADORE")
+ }
+ cnt = 0
+ out_dir = opts.outdir
-def set_attr(orig, new):
- return new
+ if not os.path.exists(out_dir):
+ os.makedirs(out_dir)
-def set_bg(j, (b, n), color):
- set_attr_at(j, b, n, "c", set_attr, color)
- #set_attr_at(j, b, n, "g", set_attr, False)
+ opts.allowed_keys = setup_allowed_keys(opts)
-def _set_tap_info(o, count, cap):
- ns = 4 - o.count ("\n")
- return o + "\n" * ns + "%.02f%%" % (float(count) / float(cap) * 100)
+ if not opts.one_shot:
-def set_tap_info(j, (b, n), count, cap):
- j[b][n + 1] = _set_tap_info (j[b][n + 1], count, cap)
+ try:
+ with open("%s/stamped-log" % out_dir, "r") as f:
+ while True:
+ line = f.readline()
+ if not line:
+ break
+ if not process_line(line, heatmaps, opts):
+ continue
+ except:
+ pass
-def heatmap_color (v):
- colors = [ [0.3, 0.3, 1], [0.3, 1, 0.3], [1, 1, 0.3], [1, 0.3, 0.3]]
- fb = 0
- if v <= 0:
- idx1, idx2 = 0, 0
- elif v >= 1:
- idx1, idx2 = len(colors) - 1, len(colors) - 1
+ stamped_log = open ("%s/stamped-log" % (out_dir), "a+")
else:
- val = v * (len(colors) - 1)
- idx1 = int(floor(val))
- idx2 = idx1 + 1
- fb = val - float(idx1)
-
- r = (colors[idx2][0] - colors[idx1][0]) * fb + colors[idx1][0]
- g = (colors[idx2][1] - colors[idx1][1]) * fb + colors[idx1][1]
- b = (colors[idx2][2] - colors[idx1][2]) * fb + colors[idx1][2]
-
- r, g, b = [x * 255 for x in r, g, b]
- return "#%02x%02x%02x" % (r, g, b)
-
-# Load the keylog
-def load_keylog(fname, restrict_row):
- keylog = {}
- total = 0
- with open(fname, "r") as f:
- lines = f.readlines()
- for line in lines:
- m = re.search ('KL: col=(\d+), row=(\d+)', line)
- if not m:
- continue
- (c, r) = (int(m.group (2)), int(m.group (1)))
- if restrict_row != None and r != int(restrict_row):
+ stamped_log = None
+
+ while True:
+ line = sys.stdin.readline()
+ if not line:
+ break
+ if not process_line(line, heatmaps, opts, stamped_log):
continue
- if (c, r) in keylog:
- keylog[(c, r)] = keylog[(c, r)] + 1
- else:
- keylog[(c, r)] = 1
- total = total + 1
- return total / 2, keylog
-
-def l_flat(s):
- f = s.split("\n")
- return ", ".join (f)
-
-def main(base_fn, log_fn, restrict_row = None):
-
- with open(base_fn, "r") as f:
- layout = json.load (f)
-
- ## Reset colors
- for row in cr_coord_map:
- for col in row:
- if col != []:
- set_bg (layout, col, "#d9dae0")
- #set_attr_at (layout, col[0], col[1], "g", set_attr, True)
-
- total, log = load_keylog (log_fn, restrict_row)
- max_cnt = 0
- for (c, r) in log:
- max_cnt = max(max_cnt, log[(c, r)])
-
- # Create the heatmap
- for (c, r) in log:
- coords = coord(c, r)
- b, n = coords
- cap = max_cnt
- v = float(log[(c, r)]) / cap
- print >> sys.stderr, "%s => %d/%d => %f = %s" % (l_flat(layout[b][n+1]), log[(c,r)], cap, v, heatmap_color(v))
- set_bg (layout, coord(c, r), heatmap_color (v))
- set_tap_info (layout, coord (c, r), log[(c, r)], total)
-
- print json.dumps(layout)
-if __name__ == "__main__":
- if len(sys.argv) < 3:
- print """Log to Heatmap -- creates a heatmap out of keyboard logs
+ cnt = cnt + 1
+
+ if opts.dump_interval != -1 and cnt >= opts.dump_interval and not opts.one_shot:
+ cnt = 0
+ dump_all(out_dir, heatmaps)
-Usage: log-to-heatmap.py base-layout.json logfile [row] >layout.json"""
- sys.exit (1)
- main(*sys.argv[1:])
+ dump_all (out_dir, heatmaps)
+
+if __name__ == "__main__":
+ parser = argparse.ArgumentParser (description = "keylog to heatmap processor")
+ parser.add_argument ('outdir', action = 'store',
+ help = 'Output directory')
+ parser.add_argument ('--dump-interval', dest = 'dump_interval', action = 'store', type = int,
+ default = 100, help = 'Dump stats and heatmap at every Nth event, -1 for dumping at EOF only')
+ parser.add_argument ('--ignore-key', dest = 'ignore_key', action = 'append', type = str,
+ default = [], help = 'Ignore the key at position (x, y)')
+ parser.add_argument ('--only-key', dest = 'only_key', action = 'append', type = str,
+ default = [], help = 'Only include key at position (x, y)')
+ parser.add_argument ('--one-shot', dest = 'one_shot', action = 'store_true',
+ help = 'Do not load previous data, and do not update it, either.')
+ args = parser.parse_args()
+ if len(args.ignore_key) and len(args.only_key):
+ print ("--ignore-key and --only-key are mutually exclusive, please only use one of them!",
+ file = sys.stderr)
+ sys.exit(1)
+ main(args)
diff --git a/keyboards/ergodox/keymaps/algernon/tools/max-focused b/keyboards/ergodox/keymaps/algernon/tools/max-focused
deleted file mode 100755
index 4d5220aa8b..0000000000
--- a/keyboards/ergodox/keymaps/algernon/tools/max-focused
+++ /dev/null
@@ -1,5 +0,0 @@
-#! /bin/sh
-WIN="$(xdotool getactivewindow)"
-wmctrl -i -r ${WIN} -b remove,maximized_vert,maximized_horz
-xdotool windowsize ${WIN} 100% 100%
-wmctrl -i -r ${WIN} -b add,maximized_vert,maximized_horz
diff --git a/keyboards/ergodox/keymaps/algernon/tools/text-to-log.py b/keyboards/ergodox/keymaps/algernon/tools/text-to-log.py
new file mode 100755
index 0000000000..e068c3cbfb
--- /dev/null
+++ b/keyboards/ergodox/keymaps/algernon/tools/text-to-log.py
@@ -0,0 +1,107 @@
+#!/usr/bin/env python3
+
+import os
+import sys
+
+charmap = {
+ '9': [[1, 0]],
+ '7': [[2, 0]], '@': [[2, 5], [2, 0]],
+ '5': [[3, 0]], '*': [[2, 5], [3, 0]],
+ '3': [[4, 0]], '^': [[2, 5], [4, 0]],
+ '1': [[5, 0]], '$': [[2, 5], [5, 0]],
+ '0': [[8, 0]], '%': [[2, 5], [8, 0]],
+ '2': [[9, 0]], '!': [[2, 5], [9, 0]],
+ '4': [[10, 0]], '#': [[2, 5], [10, 0]],
+ '6': [[11, 0]], '&': [[2, 5], [11, 0]],
+ '8': [[12, 0]],
+
+ '`': [[0, 1]], '~': [[2, 5], [0, 1]],
+ 'y': [[1, 1]], 'Y': [[2, 5], [1, 1]],
+ 'w': [[2, 1]], 'W': [[2, 5], [2, 1]],
+ 'g': [[3, 1]], 'G': [[2, 5], [3, 1]],
+ 'l': [[4, 1]], 'L': [[2, 5], [4, 1]],
+ 'm': [[5, 1]], 'M': [[2, 5], [5, 1]],
+ '[': [[6, 1]], '{': [[2, 5], [6, 1]], '(': [[6, 1], [6, 1]],
+ ']': [[7, 1]], '}': [[2, 5], [7, 1]], ')': [[7, 1], [7, 1]],
+ 'f': [[8, 1]], 'F': [[2, 5], [8, 1]],
+ 'h': [[9, 1]], 'H': [[2, 5], [9, 1]],
+ 'c': [[10, 1]], 'C': [[2, 5], [10, 1]],
+ 'p': [[11, 1]], 'P': [[2, 5], [11, 1]],
+ 'x': [[12, 1]], 'X': [[2, 5], [12, 1]],
+ '\\': [[13, 1]], '|': [[2, 5], [13, 1]],
+
+ '\t': [[0, 2]],
+ 'a': [[1, 2]], 'A': [[2, 5], [1, 2]],
+ 'o': [[2, 2]], 'O': [[2, 5], [2, 2]],
+ 'e': [[3, 2]], 'E': [[2, 5], [3, 2]],
+ 'i': [[4, 2]], 'I': [[2, 5], [4, 2]],
+ 'u': [[5, 2]], 'U': [[2, 5], [5, 2]],
+ 'd': [[8, 2]], 'D': [[2, 5], [8, 2]],
+ 'r': [[9, 2]], 'R': [[2, 5], [9, 2]],
+ 't': [[10, 2]], 'T': [[2, 5], [10, 2]],
+ 'n': [[11, 2]], 'N': [[2, 5], [11, 2]],
+ 's': [[12, 2]], 'S': [[2, 5], [12, 2]],
+ '=': [[13, 2]], '+': [[2, 5], [13, 2]],
+
+ 'z': [[1, 3]], 'Z': [[2, 5], [1, 3]],
+ 'q': [[2, 3]], 'Q': [[2, 5], [2, 3]],
+ '\'': [[3, 3]], '"': [[2, 5], [3, 3]],
+ ',': [[4, 3]], '<': [[2, 5], [4, 3]],
+ '.': [[5, 3]], '>': [[2, 5], [5, 3]],
+ 'b': [[8, 3]], 'B': [[2, 5], [8, 3]],
+ 'k': [[9, 3]], 'K': [[2, 5], [9, 3]],
+ 'v': [[10, 3]], 'V': [[2, 5], [10, 3]],
+ 'j': [[11, 3]], 'J': [[2, 5], [11, 3]],
+ '/': [[12, 3]], '?': [[2, 5], [12, 3]],
+
+ ':': [[4, 4]], ';': [[4, 4], [4, 4]],
+ '-': [[9, 4]], '_': [[2, 5], [9, 4]],
+
+ ' ': [[10, 5]],
+ '\n': [[11, 5]],
+
+ ## Layered things
+ # Hungarian
+ 'á': [[9, 5], [1, 2]], 'Á': [[2, 5], [9, 5], [1, 2]],
+ 'ó': [[9, 5], [2, 2]], 'Ó': [[2, 5], [9, 5], [2, 2]],
+ 'ő': [[9, 5], [2, 1]], 'Ő': [[2, 5], [9, 5], [2, 1]],
+ 'ö': [[9, 5], [2, 3]], 'Ö': [[2, 5], [9, 5], [2, 3]],
+ 'é': [[9, 5], [3, 2]], 'É': [[2, 5], [9, 5], [3, 2]],
+ 'ú': [[9, 5], [4, 2]], 'Ú': [[2, 5], [9, 5], [4, 2]],
+ 'ű': [[9, 5], [4, 1]], 'Ű': [[2, 5], [9, 5], [4, 1]],
+ 'ü': [[9, 5], [4, 3]], 'Ü': [[2, 5], [9, 5], [4, 3]],
+ 'í': [[9, 5], [5, 2]], 'Í': [[2, 5], [9, 5], [5, 2]],
+}
+
+def lookup_char(layer, ch):
+ if ch in charmap:
+ return charmap[ch]
+ return None
+
+def process_char(layer, ch, out=sys.stdout):
+ keys = lookup_char(layer, ch)
+ if not keys:
+ print ("Unknown char: %s" % ch, file=sys.stderr)
+ else:
+ for (c, r) in keys:
+ print ("KL: col=%d, row=%d, pressed=1, layer=%s" % (r, c, layer), file=out)
+ print ("KL: col=%d, row=%d, pressed=0, layer=%s" % (r, c, layer), file=out)
+
+def process_file(fn, layer, out=sys.stdout):
+ with open(fn, "r") as f:
+ ch = f.read(1)
+ while ch:
+ process_char(layer, ch, out)
+ ch = f.read(1)
+
+if sys.argv[1] == '-':
+ out='/dev/stdin'
+else:
+ out=sys.argv[1]
+
+if len(sys.argv) >= 2:
+ layer = 'ADORE'
+else:
+ layer = sys.argv[2]
+
+process_file(out, layer = layer)
diff --git a/keyboards/ergodox/keymaps/bepo_csa/keymap.c b/keyboards/ergodox/keymaps/bepo_csa/keymap.c
new file mode 100644
index 0000000000..495242adb3
--- /dev/null
+++ b/keyboards/ergodox/keymaps/bepo_csa/keymap.c
@@ -0,0 +1,527 @@
+/* TypeMatrix-2030-like keymap */
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+#include "action_util.h"
+#include "led.h"
+#include "keymap_extras/keymap_bepo.h"
+#include "keymap_extras/keymap_canadian_multilingual.h"
+
+enum layers {
+ LR_BASE, // default layer
+ LR_CSA, // BÉPO over Canadian Multilingual (CSA)
+ LR_CSA_SFT, // shifted BÉPO over CSA
+ LR_CSA_AGR, // altgr-ed BÉPO over CSA
+ LR_CSA_AGR_SFT, // altgr-shifted BÉPO over CSA
+ LR_NUMR, // numeric layer
+ LR_FN, // fn layer
+};
+
+#define IS_CA_MULT_ENABLED() (layer_state & (1 << LR_CSA))
+
+enum macros {
+ // Characters that do not exist in CSA and must be implemented based on unicode support
+ // Note: these are intentionally declared first to be used as indexes in spec_chars below
+ UC_NDSH, // –
+ UC_MDSH, // —
+ UC_ELPS, // …
+ END_UC, // indicates the last unicode character macro
+ // other macros
+ M_CSA_SFT, // toggle shift on CSA
+ M_CSA_AGR_SFT, // toggle shift on LR_CSA_AGR (goes to LR_CSA_AGR_SFT)
+ M_CSA_SFT_AGR, // toggle AltGr on LR_CSA_SFT (goes to LR_CSA_AGR_SFT)
+ // macros for characters that need to be un-shifted in LR_CA_MULT_SHIFT
+ M_1,
+ M_2,
+ M_3,
+ M_4,
+ M_5,
+ M_6,
+ M_7,
+ M_8,
+ M_9,
+ M_0,
+ M_DEGR,
+ M_SCLN,
+ M_GRV,
+ M_NBSP,
+ // macros for characters that don't have a simple key combination in LR_CA_MULT_ALTGR
+ M_CRC,
+ // other layer macros
+ M_DBL0, // double 0
+ M_FNLR, // fn layer
+ M_NMAL, // num+alt
+};
+
+#define CSA(name) M(M_CSA_##name) // calls a CSA macro
+
+const uint16_t unicode_chars[] = {
+ [UC_NDSH] = L'–',
+ [UC_MDSH] = L'—',
+ [UC_ELPS] = L'…',
+};
+
+/* shortcut for unicode character macros */
+#define MUC(name) M(UC_##name) // calls a unicode macro
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+/* Basic layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | $ | " | « | » | ( | ) | Del | | Del | @ | + | - | / | * | W |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | Tab | B | É | P | O | È |Backsp| |Backsp| ^ | V | D | L | J | Z |
+ * |--------+------+------+------+------+------|ace | |ace |------+------+------+------+------+--------|
+ * | = | A | U | I | E | , |------| |------| C | T | S | R | N | M |
+ * |--------+------+------+------+------+------|Enter | |Enter |------+------+------+------+------+--------|
+ * | LShift | À | Y | X | . | K | | | | ' | Q | G | H | F | RShift |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * |LCtrl | fn | LGui |numAlt| LAlt | |Alt Gr| % | App | Ç | RCtrl|
+ * `----------------------------------' `----------------------------------'
+ * ,--------------. ,-------------.
+ * | Esc | num | | Left |Right |
+ * ,------+-------+------| |------+------+------.
+ * | | | PgUp | | Up | | |
+ * |Space | Home |------| |------| End |Space |
+ * | | | PgDn | | Down | | |
+ * `---------------------' `--------------------'
+ */
+// If it accepts an argument (i.e, is a function), it doesn't need KC_.
+// Otherwise, it needs KC_*
+[LR_BASE] = KEYMAP( // layer 0 : default
+ // left hand
+ BP_DLR, KC_1, KC_2, KC_3, KC_4, KC_5, KC_DELT,
+ KC_TAB, BP_B, BP_ECUT, BP_P, BP_O, BP_EGRV, KC_BSPC,
+ BP_EQL, BP_A, BP_U, BP_I, BP_E, BP_COMM,
+ KC_LSFT, BP_AGRV, BP_Y, BP_X, BP_DOT, BP_K, KC_ENT,
+ KC_LCTL, M(M_FNLR), KC_LGUI, M(M_NMAL), KC_LALT,
+
+ KC_ESC, TG(LR_NUMR),
+ KC_PGUP,
+ KC_SPC, KC_HOME, KC_PGDN,
+
+ // right hand
+ KC_DELT, KC_6, KC_7, KC_8, KC_9, KC_0, BP_W,
+ KC_BSPC, BP_DCRC, BP_V, BP_D, BP_L, BP_J, BP_Z,
+ BP_C, BP_T, BP_S, BP_R, BP_N, BP_M,
+ KC_ENT, BP_APOS, BP_Q, BP_G, BP_H, BP_F, KC_RSFT,
+ BP_ALGR, BP_PERC, KC_APP, BP_CCED, KC_RCTL,
+
+ KC_LEFT, KC_RGHT,
+ KC_UP,
+ KC_DOWN, KC_END, KC_SPC
+ ),
+/**
+ * Same as default but for use with Canadian Multilingual on OS side
+ */
+[LR_CSA] = KEYMAP(
+ // left hand
+ KC_DLR, CSA_DQOT, CSA_LGIL, CSA_RGIL, KC_LPRN, KC_RPRN, KC_TRNS,
+ KC_TRNS, KC_B, CSA_ECUT, KC_P, KC_O, CSA_EGRV, KC_TRNS,
+ KC_EQL, KC_A, KC_U, KC_I, KC_E, KC_COMM,
+ CSA(SFT), CSA_AGRV, KC_Y, KC_X, KC_DOT, KC_K, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS,
+
+ // right hand
+ KC_TRNS, KC_AT, KC_PLUS, KC_MINS, CSA_SLSH, KC_ASTR, KC_W,
+ KC_TRNS, CSA_DCRC, KC_V, KC_D, KC_L, KC_J, KC_Z,
+ KC_C, KC_T, KC_S, KC_R, KC_N, KC_M,
+ KC_TRNS, CSA_APOS, KC_Q, KC_G, KC_H, KC_F, CSA(SFT),
+ MO(LR_CSA_AGR), KC_PERC, KC_TRNS, CSA_CCED, KC_LCTL, // RCTL has a special behaviour in CSA so use LCTL
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+ ),
+/* Shifted BÉPO over Canadian Multilingual
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | # | 1 | 2 | 3 | 4 | 5 | | | | 6 | 7 | 8 | 9 | 0 | |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | | | | | | | | ! | | | | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | ° | | | | | ; |------| |------| | | | | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | : | | | | | ? | | | | | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | | ` | | | |
+ * `----------------------------------' `-----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | | |------| |------| | |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+[LR_CSA_SFT] = KEYMAP(
+ // left hand
+ KC_HASH, M(M_1), M(M_2), M(M_3), M(M_4), M(M_5), KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ M(M_DEGR),KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, M(M_SCLN),
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_COLN, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ M(M_NBSP), KC_TRNS, KC_TRNS,
+
+ // right hand
+ KC_TRNS, M(M_6), M(M_7), M(M_8), M(M_9), M(M_0), KC_TRNS,
+ KC_TRNS, KC_EXLM, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, CSA_QEST, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ CSA(SFT_AGR), M(M_GRV), KC_TRNS, KC_TRNS, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, M(M_NBSP)
+ ),
+/* AltGr-ed BÉPO over Canadian Multilingual
+ * "////" indicates that the key is disabled (unsupported bépo character)
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | – | — | < | > | [ | ] | | | | ^ | ± | //// | ÷ | × | dead ˘ |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | |dead '| & | œ |dead `| | | | ¡ |dead ˇ| ð | //// | ij | ////// |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | ////// | æ | ù |dead "| € | ̛’ |------| |------| © | þ | ß | ® |dead ~| dead ¯ |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | \ | { | } | … | ~ | | | | ¿ |dead °| μ | //// |dead ˛| |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | | //// | |dead ¸| |
+ * `----------------------------------' `-----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | _ | |------| |------| | _ |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+[LR_CSA_AGR] = KEYMAP(
+ // left hand
+ MUC(NDSH), MUC(MDSH), CSA_LESS, CSA_GRTR, CSA_LBRC, CSA_RBRC, KC_TRNS,
+ KC_TRNS, CSA_PIPE, CSA_DACT, KC_AMPR, CSA_OE, CSA_DGRV, KC_TRNS,
+ KC_NO, CSA_AE, CSA_UGRV, CSA_DTRM, CSA_EURO, CSA_RQOT,
+ CSA(AGR_SFT), CSA_BSLS, CSA_LCBR, CSA_RCBR, MUC(ELPS), CSA_TILD, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_UNDS, CSA(AGR_SFT), KC_TRNS,
+
+ // right hand
+ KC_TRNS, M(M_CRC), CSA_PSMS, KC_NO, CSA_DVSN, CSA_TIMS, CSA_DBRV,
+ KC_TRNS, CSA_IXLM, CSA_DCAR, CSA_ETH, KC_NO, CSA_IJ, KC_NO,
+ CSA_CPRT, CSA_THRN, CSA_SRPS, CSA_RTM, CSA_DTLD, CSA_DMCR,
+ KC_TRNS, CSA_IQST, CSA_DRNG, CSA_MU, KC_NO, CSA_DOGO, CSA(AGR_SFT),
+ KC_TRNS, KC_NO, KC_TRNS, CSA_DCED, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, CSA(AGR_SFT), KC_UNDS
+ ),
+/* AltGr-shifted BÉPO over Canadian Multilingual
+ * "////" indicates that the key is disabled (unsupported bépo character or unused in bépo)
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | ¶ | //// | “ | ” | //// | //// | | | | //// | ¬ | ¼ | ½ | ¾ | ////// |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | ¦ | ˝ | § | Œ | ` | | | | //// | //// | Ð | //// | IJ | ////// |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | ////// | Æ | Ù |dead-˙| //// | //// |------| |------| //// | Þ | ẞ | ™ | //// | º |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | //// | ‘ | ’ | //// | //// | | | | //// | //// | //// | //// | ª | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | | | | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | | |------| |------| | |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+[LR_CSA_AGR_SFT] = KEYMAP(
+ // left hand
+ CSA_PARG, KC_NO, CSA_LDQT, CSA_RDQT, KC_NO, KC_NO, KC_TRNS,
+ KC_TRNS, CSA_BPIP, CSA_DDCT, CSA_SECT, S(CSA_OE), M(M_GRV), KC_TRNS,
+ KC_NO, S(CSA_AE), S(CSA_UGRV), CSA_DDTA, KC_NO, KC_NO,
+ CSA(AGR_SFT), KC_NO, CSA_LQOT, CSA_RQOT, KC_NO, KC_NO, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, CSA(AGR_SFT), KC_TRNS,
+
+ // right hand
+ KC_TRNS, KC_NO, CSA_NEGT, CSA_1QRT, CSA_1HLF, CSA_3QRT, KC_NO,
+ KC_TRNS, KC_NO, KC_NO, S(CSA_ETH), KC_NO, S(CSA_IJ), KC_NO,
+ KC_NO, S(CSA_THRN), S(CSA_SRPS), CSA_TM, KC_NO, CSA_ORDO,
+ KC_TRNS, KC_NO, KC_NO, KC_NO, KC_NO, CSA_ORDA, CSA(AGR_SFT),
+ CSA(SFT_AGR), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, CSA(AGR_SFT), KC_TRNS
+ ),
+/* Numeric Layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | | F1 | F2 | F3 | F4 | F5 | | | | | | Tab | / | * | - |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | F6 | F7 | F8 | F9 | F10 | | | | | Home | 7 | 8 | 9 | + |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | F11 | F12 | | | |------| |------| Up | End | 4 | 5 | 6 | + |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | | | | | Left | Down | Right| 1 | 2 | 3 |KpEnter |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | | 0 | 00 | . |Etr/Ctl|
+ * `----------------------------------' `-----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | |n.lock|c.lock|
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | | |------| |------| | |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+// SYMBOLS
+[LR_NUMR] = KEYMAP(
+ // left hand
+ KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS,
+ KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_TRNS,
+ KC_TRNS, KC_F11, KC_F12, 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,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS,KC_TRNS,
+
+ // right hand
+ KC_TRNS, KC_F6, KC_F7, KC_TAB, KC_PSLS, KC_PAST, KC_PMNS,
+ KC_TRNS, KC_TRNS, KC_HOME, KC_P7, KC_P8, KC_P9, KC_PPLS,
+ KC_UP, KC_END, KC_P4, KC_P5, KC_P6, KC_PPLS,
+ KC_LEFT, KC_DOWN, KC_RGHT, KC_P1, KC_P2, KC_P3, KC_PENT,
+ KC_TRNS, KC_P0, M(M_DBL0),KC_PDOT, CTL_T(KC_PENT),
+
+ KC_NLCK, KC_CAPS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+),
+/* fn layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * |~CA-mult| | | | | |Insert| |Insert|Eject |Power |Sleep | Wake |PrtScr|ScrollLk|
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | | | | |VolUp | | | | | | | | Pause |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | RESET | | | Calc | Mail |Browsr|------| |------| | | | | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | App | cut | copy |paste | Mute |VolDn | | | | | | | | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | | | | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | Next | | | | |
+ * | Mute | play |------| |------| | |
+ * | | | Prev | | | | |
+ * `--------------------' `--------------------'
+ */
+// MEDIA AND MOUSE
+[LR_FN] = KEYMAP(
+ TG(LR_CSA), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_INS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLU,
+ RESET, KC_TRNS, KC_TRNS, KC_CALC, KC_MAIL, KC_WHOM,
+ KC_TRNS, KC_APP, S(KC_DELT), LCTL(KC_INS),S(KC_INS), KC_MUTE, KC_VOLD,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_MPRV,
+ KC_MUTE, KC_MPLY, KC_MNXT,
+
+ // right hand
+ KC_INS, KC_EJCT, KC_PWR, KC_SLEP, KC_WAKE, KC_PSCR, KC_SLCK,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PAUS,
+ 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, KC_TRNS,
+
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+),
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+};
+
+void hold_shift(void) {
+ register_code(KC_LSHIFT);
+}
+
+void release_shift(void) {
+ unregister_code(KC_LSHIFT);
+}
+
+uint16_t hextokeycode(int hex) {
+ if (hex == 0x0) {
+ return KC_P0;
+ } else if (hex < 0xA) {
+ return KC_P1 + (hex - 0x1);
+ } else {
+ return KC_A + (hex - 0xA);
+ }
+}
+
+void send_unicode(uint16_t unicode)
+{
+ // For more info on how this works per OS, see here: https://en.wikipedia.org/wiki/Unicode_input#Hexadecimal_code_input
+ // Implemented for Windows:
+ // Pressing ALT followed by + followed by the unicode code point in hex.
+ // Requires registry key HKEY_CURRENT_USER\Control Panel\Input Method\EnableHexNumpad set to String 1
+ register_code(KC_LALT);
+ register_code(KC_PPLS);
+ unregister_code(KC_PPLS);
+
+ for (int i = 12; i >= 0; i -= 4) {
+ register_code(hextokeycode((unicode >> i) & 0xF));
+ unregister_code(hextokeycode((unicode >> i) & 0xF));
+ }
+
+ unregister_code(KC_LALT);
+}
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0 ... END_UC:
+ if (record->event.pressed) {
+ send_unicode(unicode_chars[id]);
+ }
+ break;
+ case M_CSA_SFT:
+ // BÉPO over CSA: toggle shift layer
+ layer_invert(LR_CSA_SFT);
+ if (record->event.pressed) {
+ hold_shift();
+ } else {
+ release_shift();
+ }
+ break;
+ case M_CSA_SFT_AGR:
+ // BÉPO over CSA: from shift layer, momentary altgr+shift layer
+ layer_invert(LR_CSA_AGR);
+ layer_invert(LR_CSA_AGR_SFT);
+ if (record->event.pressed) {
+ // shift not needed for LR_CSA_AGR_SFT
+ release_shift();
+ } else {
+ // back to shift layer
+ hold_shift();
+ }
+ break;
+ case M_CSA_AGR_SFT:
+ // BÉPO over CSA: from altgr layer, momentary altgr+shift layer
+ layer_invert(LR_CSA_SFT);
+ layer_invert(LR_CSA_AGR_SFT);
+ break;
+ case M_1 ... M_0:
+ case M_DEGR:
+ case M_SCLN:
+ case M_GRV:
+ case M_NBSP:
+ // macros of the shift layer that require to release shift
+ if (record->event.pressed) {
+ release_shift();
+ switch (id) {
+ case M_1 ... M_0:
+ register_code(KC_1 + (id - M_1));
+ break;
+ case M_DEGR:
+ return MACRO(DOWN(CSA_ALTGR), D(SCLN), END);
+ case M_SCLN:
+ return MACRO(D(SCLN), END);
+ case M_GRV:
+ return MACRO(I(75), DOWN(CSA_ALTGR), TYPE(CSA_DCRC), UP(CSA_ALTGR), T(SPACE), END);
+ case M_NBSP:
+ // use weak mod such that pressing another key will not be affected
+ add_weak_mods(MOD_BIT(CSA_ALTGR));
+ return MACRO(D(SPACE), END);
+ }
+ } else {
+ hold_shift();
+ switch (id) {
+ case M_1 ... M_0:
+ unregister_code(KC_1 + (id - M_1));
+ break;
+ case M_DEGR:
+ return MACRO(UP(CSA_ALTGR), U(SCLN), END);
+ case M_SCLN:
+ return MACRO(U(SCLN), END);
+ case M_NBSP:
+ del_weak_mods(MOD_BIT(CSA_ALTGR));
+ return MACRO(U(SPACE), END);
+ }
+ }
+ break;
+ case M_CRC:
+ if (record->event.pressed) {
+ return MACRO(I(75), TYPE(CSA_DCRC), T(SPACE), END);
+ }
+ break;
+ case M_DBL0:
+ if (record->event.pressed) {
+ return MACRO( I(25), T(P0), T(P0), END );
+ }
+ break;
+ case M_FNLR:
+ layer_invert(LR_NUMR);
+ layer_invert(LR_FN);
+ break;
+ case M_NMAL:
+ layer_invert(LR_NUMR);
+ if (record->event.pressed) {
+ register_code(KC_LALT);
+ } else {
+ unregister_code(KC_LALT);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
+
+// Runs just one time when the keyboard initializes.
+void matrix_init_user(void) {
+};
+
+// Runs constantly in the background, in a loop.
+void matrix_scan_user(void) {
+
+ ergodox_board_led_off();
+ ergodox_right_led_1_off();
+ ergodox_right_led_2_off();
+ ergodox_right_led_3_off();
+ // led 1: numeric layer
+ if (layer_state & (1 << LR_NUMR)) {
+ ergodox_right_led_1_on();
+ }
+ // led 2: BÉPO over Canadian Multilingual
+ if (IS_CA_MULT_ENABLED()) {
+ ergodox_right_led_2_on();
+ }
+ // led 3: caps lock
+ if (host_keyboard_leds() & (1<<USB_LED_CAPS_LOCK)) {
+ ergodox_right_led_3_on();
+ }
+};
diff --git a/keyboards/ergodox/keymaps/bepo_csa/readme.md b/keyboards/ergodox/keymaps/bepo_csa/readme.md
new file mode 100644
index 0000000000..d4975b2265
--- /dev/null
+++ b/keyboards/ergodox/keymaps/bepo_csa/readme.md
@@ -0,0 +1,162 @@
+# BÉPO Keymap with firmware-remapping for software CSA layout
+
+This is a keymap intended to be used with the [BÉPO layout](http://bepo.fr), a French ergonomic layout designed by following Dvorak's principles.
+
+The particularity of this keymap is that it supports using the [Canadian Multilingual Standard layout](https://en.wikipedia.org/wiki/QWERTY#Canadian_Multilingual_Standard) (also known as _ACNOR keyboard_ or _CSA keyboard_, see also the [French page](https://fr.wikipedia.org/wiki/QWERTY#Clavier_canadien_multilingue_standard) which contains more details) on the OS side, by enabling the _CSA_ layer. This is especially useful for operating systems that natively provide CSA, but not BÉPO, like Windows. The CSA layout was chosen because it is probably the standard layout that provides the best character set coverage.
+
+This keymap is based on the [tm2030](../tm2030/) keymap, whose goal was to have a [TypeMatrix™ 2030](http://typematrix.com/2030/features.php) inspired layout for the ErgoDox EZ.
+
+As this keyboard is intended for French people, the rest of this page will be in French.
+
+# Keymap BÉPO avec support en firmware pour utilisation avec la disposition CSA en software
+
+Cette keymap a été conçue pour être utilisée avec la [disposition BÉPO](http://bepo.fr), la disposition francophone, ergonomique et libre basée sure les principes de Dvorak.
+
+La particularité de cette keymap est qu'elle supporte l'utilisation du [clavier canadien multilingue standard](https://fr.wikipedia.org/wiki/QWERTY#Clavier_canadien_multilingue_standard) (aussi appelé _clavier ACNOR_ ou _clavier CSA_) du côté du système d'exploitation, en activant la couche _CSA_. Ceci s'avère particulièrement utile pour les systèmes d'exploitations qui fournissent nativement le CSA, mais pas le BÉPO, comme Windows. Le clavier CSA a été choisi comme base car c'est probablement la disposition standard qui fournit la meilleure couverture en termes de caractères disponibles.
+
+Cette keymap est basée sur la keymap [tm2030](../tm2030/), dont le but est de fournir une disposition inspirée du [TypeMatrix™ 2030](http://typematrix.com/2030/features.php) pour l'ErgoDox EZ.
+
+## Couche de base
+C'est la couche par défaut, proche du TypeMatrix, avec les différences suivantes:
+- La ligne du haut (les touches `F`) et la colonne de droite sont retirées, les touches correspondantes étant déplacées ailleurs.
+- Les touches situés en bas à gauche sont redisposées dans cet ordre: `Ctrl`, `fn`, `Gui`, `num+Alt`, `Alt`
+- Les touches `shuffle` (`Alt+Tab`) et `desktop` ne sont pas supportés
+- `W` est déplacé à la place de `=`
+- `=` est déplacé sous `Tab` (au lieu d'avoir un grand `Shift`)
+- `%` et `Ç` sont déplacés à la place de `Home` et `End` respectivement
+- Les flèches ainsi que `PgUp`/`PgDown`/`Home`/`End` sont déplacées sur les pouces
+
+À noter que pour `W` et `Ç`, le but a été de ne pas les déplacer trop par rapport à la disposition BÉPO _standard_, afin de pouvoir repasser facilement sur un TypeMatrix ou un clavier traditionnel.
+
+
+```
+,--------------------------------------------------. ,--------------------------------------------------.
+| $ | " | « | » | ( | ) | Del | | Del | @ | + | - | / | * | W |
+|--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+| Tab | B | É | P | O | È |Backsp| |Backsp| ^ | V | D | L | J | Z |
+|--------+------+------+------+------+------|ace | |ace |------+------+------+------+------+--------|
+| = | A | U | I | E | , |------| |------| C | T | S | R | N | M |
+|--------+------+------+------+------+------|Enter | |Enter |------+------+------+------+------+--------|
+| LShift | À | Y | X | . | K | | | | ' | Q | G | H | F | RShift |
+`--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ |LCtrl | fn | LGui |numAlt| LAlt | |Alt Gr| % | App | Ç | RCtrl|
+ `----------------------------------' `----------------------------------'
+ ,--------------. ,-------------.
+ | Esc | num | | Left |Right |
+ ,------+-------+------| |------+------+------.
+ | | | PgUp | | Up | | |
+ |Space | Home |------| |------| End |Space |
+ | | | PgDn | | Down | | |
+ `---------------------' `--------------------'
+```
+
+### Changer de couche
+
+- Utilisez `num` pour activer/désactiver [la couche numérique](#couche-numérique)
+- Maintenez `fn` pour activer temporairement [les couches numériques et Fn](#couche-fn)
+- Maintenez `numAlt` pour activer temporairement la couche numérique combinée avec `Alt` (facilite l'utilisation des raccourcis tels que `Alt`+`F4`)
+
+### Diodes
+Les diodes de l'ErgoDox EZ (côté droit) sont utilisées de la façon suivante :
+
+- diode de gauche (rouge) : indique l'activation de [la couche numérique](#couche-numérique)
+- diode du milieu (verte) : indique l'activation du [mode CSA](#couche-csa)
+- diode de droite (bleue) : indique le verrouillage majuscules
+
+## Couche CSA
+La couche _CSA_ est la même que la couche de base, pour une utilisation avec un clavier Canadien Multilingue configuré dans le système d'exploitation.
+
+Pour l'activer, appuyez sur `fn`+`$`. La [diode](#diodes) verte indique que la couche CSA est activée.
+
+### Limitations
+Seuls les caractères présents dans le clavier CSA sont parfaitement supportés. De manière générale, il s'agit des caractères suivants :
+
+- toute la couche de base
+- tous les caractères accessibles en `Shift`
+- tous les caractères de la main gauche accessibles en `AltGr` à l'exception du `≠`
+- environ la moitié des caractères de la main droite accessibles en `AltGr` et la moitié des caractères accessibles en `AltGr`+`Shift` (consultez [le fichier source](keymap.c) pour voir les caractères supportés)
+
+En particulier, les caractères suivants sont émulés via le support Unicode (Windows seulement):
+
+- le tiret cadratin (tiret long) : —
+- le tiret demi-cadratin (demi tiret) : –
+- les points de suspension : …
+
+L'implémentation actuelle ne fonctionne pas dans toutes les applications, en particulier les applications MS Office.
+
+Il est probable que l'utilisation de la couche CSA ne fonctionne pas correctement dans certains jeux vidéos.
+
+Cette fonctionnalité a été conçue et testée essentiellment pour Windows (7).
+
+### Détails techniques
+Techniquement, la couche CSA est en réalité composée de 4 couches servant à émuler la couche de base, les appuis sur `Shift` ou `Alt` et la combinaison des deux.
+
+Le changement de couches se fait par des macros afin d'activer ou désactiver plusieurs couches et la touche `Shift` en même temps.
+
+Certains caractères sont également implémentés par des macros, notamment ceux de la couche `Shift` qui n'ont pas besoin de cette touche en CSA, comme les chiffres.
+
+Les caractères Unicode se basent sur une implémentation spécifique et non celle fournie dans QMK — il faudrait sans doute migrer le code. Notez la façon dont ces caractères sont déclarés tels quels dans [le code source](keymap.c) (tableau `unicode_char`).
+
+## Couche numérique
+Couche numérique proche du TM lorsqu'on active `num`, avec les différences suivantes :
+
+- Le clavier numérique est déplacés de 1 vers le haut et vers la droite.
+- Les flèches sont décalées de 1 vers la gauche.
+- Fournit l'accès aux touches `F1` à `F12`, `caps-lock` et `num-lock`.
+
+La couche numérique est indiquée par la [diode](#diodes) de gauche (rouge). Caps-lock est indiqué par la diode de droite (bleue).
+
+La touche `numAlt` de [la couche de base](#couche-de-base) permet d'activer la couche numérique et la touche `Alt` simultanément, afin de faciliter les raccourcis claviers comme `Alt`+`F4`.
+
+```
+,--------------------------------------------------. ,--------------------------------------------------.
+| | F1 | F2 | F3 | F4 | F5 | | | | | | Tab | / | * | - |
+|--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+| | F6 | F7 | F8 | F9 | F10 | | | | | Home | 7 | 8 | 9 | + |
+|--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+| | F11 | F12 | | | |------| |------| Up | End | 4 | 5 | 6 | + |
+|--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+| | | | | | | | | Left | Down | Right| 1 | 2 | 3 |KpEnter |
+`--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ | | | | | | | | 0 | 00 | . |Etr/Ctl|
+ `----------------------------------' `-----------------------------------'
+ ,-------------. ,-------------.
+ | | | |n.lock|c.lock|
+ ,------|------|------| |------+------+------.
+ | | | | | | | |
+ | | |------| |------| | |
+ | | | | | | | |
+ `--------------------' `--------------------'
+```
+
+## Couche Fn
+Activée simultanément avec la couche numérique lorsque l'on maintient la touche `fn`. Comme sur le TM, elle fournit l'accès aux fonctionnalités suivantes :
+
+- `couper`, `copier` et `coller` — attention: ne pas utiliser dans l'explorateur de fichiers.
+- monter/baisser/couper le volume — seulement accessible en main gauche, contrairement au TM.
+- piste précédente/suivante
+- calculatrice, e-mail et page d'accueil du navigateur web
+- `insert`, `power`, `sleep`, `wake`, `print screen`, `scroll-lock` et `pause`
+- ~CSA: (dés)activation de [la couche CSA](#couche-csa) sur `$`
+- RESET: rechargement du firmware avec Teensy-Loader (pour les développeurs)
+
+```
+,--------------------------------------------------. ,--------------------------------------------------.
+| ~CSA | | | | | |Insert| |Insert|Eject |Power |Sleep | Wake |PrtScr|ScrollLk|
+|--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+| | | | | | |VolUp | | | | | | | | Pause |
+|--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+| RESET | | | Calc | Mail |Browsr|------| |------| | | | | | |
+|--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+| | App | cut | copy |paste | Mute |VolDn | | | | | | | | |
+`--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ | | | | | | | | | | | |
+ `----------------------------------' `----------------------------------'
+ ,-------------. ,-------------.
+ | | | | | |
+ ,------|------|------| |------+------+------.
+ | | | Next | | | | |
+ | Mute | play |------| |------| | |
+ | | | Prev | | | | |
+ `--------------------' `--------------------'
+``` \ No newline at end of file
diff --git a/keyboards/ergodox/keymaps/default/keymap.c b/keyboards/ergodox/keymaps/default/keymap.c
index 1b80cb3a23..2f399bd181 100644
--- a/keyboards/ergodox/keymaps/default/keymap.c
+++ b/keyboards/ergodox/keymaps/default/keymap.c
@@ -7,6 +7,8 @@
#define SYMB 1 // symbols
#define MDIA 2 // media keys
+#define EPRM M(1) // Macro 1: Reset EEPROM
+
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Keymap 0: Basic layer
*
@@ -62,7 +64,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
* | | % | ^ | [ | ] | ~ | | | | & | 1 | 2 | 3 | \ | |
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
- * | | | | | | | | . | 0 | = | |
+ * | EPRM | | | | | | | . | 0 | = | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
* | | | | | |
@@ -79,7 +81,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS,KC_EXLM,KC_AT, KC_LCBR,KC_RCBR,KC_PIPE,KC_TRNS,
KC_TRNS,KC_HASH,KC_DLR, KC_LPRN,KC_RPRN,KC_GRV,
KC_TRNS,KC_PERC,KC_CIRC,KC_LBRC,KC_RBRC,KC_TILD,KC_TRNS,
- KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,
+ EPRM,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,
KC_TRNS,KC_TRNS,
KC_TRNS,
KC_TRNS,KC_TRNS,KC_TRNS,
@@ -149,6 +151,11 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
SEND_STRING (QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION);
}
break;
+ case 1:
+ if (record->event.pressed) { // For resetting EEPROM
+ eeconfig_init();
+ }
+ break;
}
return MACRO_NONE;
};
@@ -158,6 +165,7 @@ void matrix_init_user(void) {
};
+
// Runs constantly in the background, in a loop.
void matrix_scan_user(void) {
diff --git a/keyboards/ergodox/keymaps/default/readme.md b/keyboards/ergodox/keymaps/default/readme.md
index 8f6dba45e9..f68138ed62 100644
--- a/keyboards/ergodox/keymaps/default/readme.md
+++ b/keyboards/ergodox/keymaps/default/readme.md
@@ -2,6 +2,8 @@
## Changelog
+* Sep 22, 2016:
+ * Created a new key in layer 1 (bottom-corner key) that resets the EEPROM.
* Feb 2, 2016 (V1.1):
* Made the right-hand quote key double as Cmd/Win on hold. So you get ' when you tap it, " when you tap it with Shift, and Cmd or Win when you hold it. You can then use it as a modifier, or just press and hold it for a moment (and then let go) to send a single Cmd or Win keystroke (handy for opening the Start menu on Windows).
diff --git a/keyboards/ergodox/keymaps/kastyle/keymap.c b/keyboards/ergodox/keymaps/kastyle/keymap.c
index a920850039..4679966869 100644
--- a/keyboards/ergodox/keymaps/kastyle/keymap.c
+++ b/keyboards/ergodox/keymaps/kastyle/keymap.c
@@ -1,3 +1,6 @@
+/* Setup to approximate a Kinesis Advantage with an eye to use in a
+ * Mac/OSX environment
+ * This version adds a hand swap feature to flip the keyboard */
#include "ergodox.h"
#include "debug.h"
#include "action_layer.h"
@@ -18,10 +21,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |--------+------+------+------+------+------| Hyper| | Meh |------+------+------+------+------+--------|
* | LShift |Z/Ctrl| X | C | V | B | | | | N | M | , | . |//Ctrl| RShift |
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
- * |Grv/L1| '" |AltShf| Left | Right| | Up | Down | [ | ] | ~L1 |
+ * |Grv/L1| \ |AltShf| Left | Right| | Up | Down | [ | ] |Grv/L1|
* `----------------------------------' `----------------------------------'
* ,---------------. ,---------------.
- * |Ctrl/Esc| Alt | | Alt |Ctrl/Esc|
+ * | LGUI |Al/Esc| |Al/Esc| RGUI |
* ,------|--------|------| |------+--------+------.
* | | | Home | | PgUp | | |
* |Backsp| Del |------| |------| Enter | Space|
@@ -31,33 +34,34 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// If it accepts an argument (i.e, is a function), it doesn't need KC_.
// Otherwise, it needs KC_*
[BASE] = KEYMAP( // layer 0 : default
- // left hand
- KC_EQL, KC_1, KC_2, KC_3, KC_4, KC_5, KC_LGUI,
- KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, TG(1),
- KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G,
- KC_LSFT, CTL_T(KC_Z), KC_X, KC_C, KC_V, KC_B, ALL_T(KC_NO),
- LT(SYMB,KC_GRV),KC_QUOT, LALT(KC_LSFT), KC_LEFT,KC_RGHT,
- CTL_T(KC_ESC), ALT_T(KC_APP),
- KC_HOME,
- KC_BSPC,KC_DEL,KC_END,
- // right hand
- KC_APP, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,
- TG(1), KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
- KC_H, KC_J, KC_K, KC_L, LT(MDIA, KC_SCLN),KC_QUOT,
- MEH_T(KC_NO),KC_N, KC_M, KC_COMM,KC_DOT, CTL_T(KC_SLSH), KC_RSFT,
- KC_UP, KC_DOWN,KC_LBRC,KC_RBRC, KC_FN1,
- KC_LALT, CTL_T(KC_ESC),
- KC_PGUP,
- KC_PGDN,KC_ENT, KC_SPC
- ),
+ // left hand
+ KC_EQL, KC_1, KC_2, KC_3, KC_4, KC_5, KC_LGUI,
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, TG(1),
+ KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G,
+ KC_LSFT, CTL_T(KC_Z), KC_X, KC_C, KC_V, KC_B, ALL_T(KC_NO),
+ KC_FN1, KC_BSLS, LALT(KC_LSFT), KC_LEFT, KC_RGHT,
+ KC_LGUI, ALT_T(KC_ESC),
+ KC_HOME,
+ KC_BSPC, KC_DEL, KC_END,
+ // right hand
+ KC_APP, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,
+ TG(1), KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
+ KC_H, KC_J, KC_K, KC_L, LT(MDIA, KC_SCLN), KC_QUOT,
+ MEH_T(KC_NO), KC_N, KC_M, KC_COMM, KC_DOT, CTL_T(KC_SLSH), KC_RSFT,
+ KC_UP, KC_DOWN, KC_LBRC, KC_RBRC, KC_FN1,
+ ALT_T(KC_ESC), KC_RGUI,
+ KC_PGUP,
+ KC_PGDN, KC_ENT, KC_SPC
+),
+
/* Keymap 1: Symbol Layer
*
* ,--------------------------------------------------. ,--------------------------------------------------.
- * | | F1 | F2 | F3 | F4 | F5 | | | | F6 | F7 | F8 | F9 | F10 | F11 |
+ * | PrScr | F1 | F2 | F3 | F4 | F5 | | | | F6 | F7 | F8 | F9 | F10 | F11 |
* |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
- * | | ! | @ | { | } | | | | | | Up | 7 | 8 | 9 | * | F12 |
+ * | ScrLk | ! | @ | { | } | | | | | | Up | 7 | 8 | 9 | * | F12 |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
- * | | # | $ | ( | ) | ` |------| |------| Down | 4 | 5 | 6 | + | |
+ * | Pause | # | $ | ( | ) | ` |------| |------| Down | 4 | 5 | 6 | + | |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
* | | % | ^ | [ | ] | ~ | | | | & | 1 | 2 | 3 | \ | |
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
@@ -74,14 +78,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// SYMBOLS
[SYMB] = KEYMAP(
// left hand
- KC_TRNS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS,
- KC_TRNS,KC_EXLM,KC_AT, KC_LCBR,KC_RCBR,KC_PIPE,KC_TRNS,
- KC_TRNS,KC_HASH,KC_DLR, KC_LPRN,KC_RPRN,KC_GRV,
- KC_TRNS,KC_PERC,KC_CIRC,KC_LBRC,KC_RBRC,KC_TILD,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_PSCR, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS,
+ KC_SLCK, KC_EXLM, KC_AT, KC_LCBR, KC_RCBR, KC_PIPE, KC_TRNS,
+ KC_PAUS, KC_HASH, KC_DLR, KC_LPRN, KC_RPRN, KC_GRV,
+ KC_TRNS, KC_PERC, KC_CIRC, KC_LBRC, KC_RBRC, KC_TILD, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS,
// right hand
KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
KC_TRNS, KC_UP, KC_7, KC_8, KC_9, KC_ASTR, KC_F12,
@@ -92,6 +96,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS
),
+
/* Keymap 2: Media and mouse keys
*
* ,--------------------------------------------------. ,--------------------------------------------------.
@@ -135,10 +140,6 @@ KEYMAP(
),
};
-const uint16_t PROGMEM fn_actions[] = {
- [1] = ACTION_LAYER_TAP_TOGGLE(SYMB) // FN1 - Momentary Layer 1 (Symbols)
-};
-
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
{
// MACRODOWN only works in this function
@@ -154,6 +155,10 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
return MACRO_NONE;
};
+const uint16_t PROGMEM fn_actions[] = {
+ [1] = ACTION_SWAP_HANDS_TAP_KEY(KC_GRV) // FN1 - Tap = Grave/Tilde - Hold Momentary swap hands
+};
+
// Runs just one time when the keyboard initializes.
void matrix_init_user(void) {
diff --git a/keyboards/ergodox/keymaps/kastyle/readme.md b/keyboards/ergodox/keymaps/kastyle/readme.md
new file mode 100644
index 0000000000..944286a818
--- /dev/null
+++ b/keyboards/ergodox/keymaps/kastyle/readme.md
@@ -0,0 +1,14 @@
+The kastyle keymap was originally intended to remap the ErgoDox EZ to more
+closely approximate the layout of a Kinesis Advantage. Notable changes
+over the stock ErgoDox layout include:
+
+ * Re-arragnement of tab, enter, space, and delete to match the Kinesis
+ * Addition of print screen, pause, etc. keys following the kines-ish keymap
+ on L1
+ * GUI keys have replaced Ctrl on the thumb keys (for Mac use), and Alt keys
+ are mapped to allow Esc on tap (good for Vi users)
+ * Most notably, the addition of a momentary one-handed mode for quick and
+ easy access to keys on the other half of the keyboard, e.g. while using a
+ mouse in one hand, one may add text to a dialogue box with the other without
+ having to reach across the keyboard or remove one's hand from the mouse.
+
diff --git a/keyboards/ergodox/keymaps/mclennon_osx/README.md b/keyboards/ergodox/keymaps/mclennon_osx/README.md
new file mode 100644
index 0000000000..60980d043d
--- /dev/null
+++ b/keyboards/ergodox/keymaps/mclennon_osx/README.md
@@ -0,0 +1,5 @@
+# Ergodox EZ for OS X
+
+This keymapping is designed to be reasonably familiar to an ordinary Mac keyboard while taking advantage of the Ergodox EZ's features. Caps lock instead enables a layer which allows a user to use HJKL as arrow keys and to control media. Shift and control have additional mappings on S and D to provide easier access while holding down caps lock.
+
+If you choose to compile this yourself, be sure to compile with `#define PREVENT_STUCK_MODIFIERS` in your `config.h`. Firmware built using [qmk_firmware](https://github.com/jackhumbert/qmk_firmware/).
diff --git a/keyboards/ergodox/keymaps/mclennon_osx/keymap.c b/keyboards/ergodox/keymaps/mclennon_osx/keymap.c
new file mode 100644
index 0000000000..627ff01e4a
--- /dev/null
+++ b/keyboards/ergodox/keymaps/mclennon_osx/keymap.c
@@ -0,0 +1,144 @@
+// Media keys work on OSX, but not on Windows.
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+
+#define BASE 0 // Default layer
+#define AUXI 1 // Auxiliary layer
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+/* Keymap 0: Basic Layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | ~` | 1 | 2 | 3 | 4 | 5 | 6 | | 7 | 8 | 9 | 0 | -_ | += | Bkspc |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | Tab | Q | W | E | R | T | L1 | | Del | Y | U | I | O | P | |\ |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | L1 | A | S | D | F | G |------| |------| H | J | K | L | ;: | Enter |
+ * |--------+------+------+------+------+------| {[ | | }] |------+------+------+------+------+--------|
+ * | LShift | Z | X | C | V | B | | | | N | M | <, | >. | ?/ | "' |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * |LCtrl | | | | Esc | | | | | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | |Power | |
+ * ,------|------|------| |------+--------+------.
+ * | | | | | | | |
+ * | LGui | LAlt |------| |------| Bkspc |Space |
+ * | | | | | Del | | |
+ * `--------------------' `----------------------'
+ */
+// If it accepts an argument (i.e, is a function), it doesn't need KC_.
+// Otherwise, it needs KC_*
+[BASE] = KEYMAP( // layer 0 : default
+ // left hand
+ KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6,
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, MO(1),
+ MO(1), KC_A, KC_S, KC_D, KC_F, KC_G,
+ KC_LSHIFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LBRC,
+ KC_LCTL, KC_TRNS,KC_TRNS,KC_TRNS,KC_ESC,
+ KC_TRNS,KC_TRNS,
+ KC_TRNS,
+ KC_LGUI,KC_LALT,KC_TRNS,
+
+ // right hand
+ KC_7, KC_8, KC_9, KC_0, KC_MINS,KC_EQL, KC_BSPC,
+ KC_DELETE, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLASH,
+ KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_ENT,
+ KC_RBRC, KC_N, KC_M, KC_COMM,KC_DOT, KC_SLSH,KC_QUOT,
+ KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,
+ KC_PWR, KC_TRNS,
+ KC_TRNS,
+ KC_DELETE, KC_BSPC, KC_SPC
+ ),
+/* Keymap 1: Auxiliary Layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | | F1 | F2 | F3 | F4 | F5 | F6 | | F7 | F8 | F9 | F10 | F11 | F12 | |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | | | | | TRNS | | | Mute | VolDn| VolUp| Play | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | TRNS | |LShift| LCtrl| | |------| |------| LEFT | DOWN | UP |RIGHT | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | LShift | | | | | | | | | MPrv | MNxt | | | | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * |LCtrl | | | | | | | | | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | LGui | LAlt |------| |------| Bkspc| Space|
+ * | | | | | Del | | |
+ * `--------------------' `--------------------'
+ */
+// AUXILIARY
+[AUXI] = KEYMAP(
+ // left hand
+ KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_LSHIFT,KC_LCTL, KC_TRNS, KC_TRNS,
+ KC_LSHIFT,KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_LCTL, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_LGUI, KC_LALT, KC_TRNS,
+ // right hand
+ KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_TRNS,
+ KC_TRNS, KC_MUTE, KC_VOLD, KC_VOLU, KC_MPLY, KC_TRNS, KC_TRNS,
+ KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT,KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_MPRV, KC_MNXT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_PWR, KC_TRNS,
+ KC_TRNS,
+ KC_DELETE, KC_BSPC, KC_SPC
+),
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+ [1] = ACTION_LAYER_TAP_TOGGLE(AUXI) // FN1 - Momentary Layer 1 (Auxiliary)
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ register_code(KC_RSFT);
+ } else {
+ unregister_code(KC_RSFT);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
+
+// Runs just one time when the keyboard initializes.
+void matrix_init_user(void) {
+
+};
+
+// Runs constantly in the background, in a loop.
+void matrix_scan_user(void) {
+
+ uint8_t layer = biton32(layer_state);
+
+ ergodox_board_led_off();
+ ergodox_right_led_1_off();
+ ergodox_right_led_2_off();
+ ergodox_right_led_3_off();
+ switch (layer) {
+ // TODO: Make this relevant to the ErgoDox EZ.
+ case 1:
+ ergodox_right_led_1_on();
+ break;
+ case 2:
+ ergodox_right_led_2_on();
+ break;
+ default:
+ // none
+ break;
+ }
+
+};
diff --git a/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keyboard-layout.png b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keyboard-layout.png
new file mode 100644
index 0000000000..544b5658e9
--- /dev/null
+++ b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keyboard-layout.png
Binary files differ
diff --git a/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keymap.c b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keymap.c
new file mode 100644
index 0000000000..1d505f8e38
--- /dev/null
+++ b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/keymap.c
@@ -0,0 +1,180 @@
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+#include "keymap_norwegian.h"
+
+#define BASE 0 // default layer
+#define BASE_MAC 1 // default layer mac
+#define NUMB_FUNC 2 // numbers and function keys
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Keymap 0: Basic layer PC
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | * | [ | ] | { | } | ~ |Mac/PC| | ^ | $ | ( | ) | < | > | @ |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | + | Q | W | E | R | T | " | | ' | Y | U | I | O | P | Å |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | / | A | S | D | F | G |------| |------| H | J | K | L | Ø | Æ |
+ * |--------+------+------+------+------+------| ; | | = |------+------+------+------+------+--------|
+ * | - | Z | X | C | V | B | | | | N | M | RIGHT| DOWN | UP | _ |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * |Alt/esc| ! | ? | : | TAB | | LEFT | _ | & | | |Num/fn|
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,--------------.
+ * | # | ` | |Insert| % |
+ * ,------|------|------| |------+-------+------.
+ * | | | ´ | | Del | | |
+ * | Shift|Ctrl/.|------| |------| Enter |Space |
+ * | | |GUI/, | | Bspc | | |
+ * `--------------------' `---------------------'
+ */
+[BASE] = KEYMAP(
+ // left hand
+ KC_PAST, NO_LBRC, NO_RBRC, NO_LCBR, NO_RCBR, KC_FN2, TG(1),
+ KC_PPLS, KC_Q, KC_W, KC_E, KC_R, KC_T, NO_QUO2,
+ KC_PSLS, KC_A, KC_S, KC_D, KC_F, KC_G,
+ KC_PMNS, KC_Z, KC_X, KC_C, KC_V, KC_B, NO_SCLN,
+ ALT_T(KC_ESC), KC_EXLM , NO_QUES, NO_COLN, KC_TAB,
+ KC_HASH, KC_FN7,
+ KC_FN6,
+ KC_FN1,CTL_T(KC_DOT),GUI_T(KC_COMMA),
+ // right hand
+ KC_FN5, NO_DLR, NO_LPRN, NO_RPRN ,KC_FN3, KC_FN4,NO_AT,
+ NO_APOS, KC_Y, KC_U, KC_I, KC_O, KC_P, NO_AA ,
+ KC_H, KC_J, KC_K, KC_L, NO_OSLH, NO_AE,
+ NO_EQL, KC_N, KC_M, KC_RIGHT, KC_DOWN, KC_UP, NO_BSLS,
+ KC_LEFT, NO_UNDS, NO_AMPR, NO_PIPE, OSL(2),
+ KC_INSERT, KC_PERC,
+ KC_DELT,
+ KC_BSPC,KC_ENT,KC_SPC
+ ),
+/* Keymap 1: Basic layer MACS (Same as pc, except for cmd/ctrl, which are swapped)
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | \ | | | { | } | | | | | $ | | | < | > | @ |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | | | | | | | | | | | | | |
+ * |--------+------+------+------+------+------| | | ' |------+------+------+------+------+--------|
+ * | | | | | | |------| |------| | | | | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | | | | | | | | | | | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | |,/Ctrl| | | | ` | |Num/fn|
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | ` | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | ´ | | | | |
+ * | |GUI/. |------| |------| | |
+ * | | |crtl/,| | | | |
+ * `--------------------' `--------------------'
+ */
+[BASE_MAC] = KEYMAP(
+ KC_TRNS, KC_TRNS,KC_TRNS, NO_LCBR_MAC,NO_RCBR_MAC, 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, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, NO_GRV_MAC,
+ KC_FN10,
+ KC_TRNS,GUI_T(KC_DOT) , CTL_T(KC_COMMA),
+ // right hand
+ KC_TRNS, NO_DLR_MAC, KC_TRNS,KC_TRNS,KC_FN8, KC_FN9,NO_AT_MAC,
+ NO_APOS_MAC, 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, KC_TRNS, NO_BSLS_MAC,
+ KC_TRNS, KC_TRNS, KC_TRNS, NO_PIPE_MAC, OSL(2),
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+),
+
+/* Keymap 2: Number ++´ánd Fn layer
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | | | | | | | | | | | F9 | F10 | F11 | F12 | |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | 8 | 7 | 6 | 5 | 9 | | | | | F5 | F6 | F7 | F8 | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | 4 | 3 | 2 | 1 | 0 |------| |------| | F1 | F2 | F3 | F4 | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | | | | | | | | END | PGDWN| PGUP | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | HOME | | | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | | |------| |------| | |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+[NUMB_FUNC] = KEYMAP(
+ NO_ASTR, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ NO_PLUS, KC_8, KC_7,KC_6,KC_5, KC_9 , KC_TRNS,
+ NO_SLSH , KC_4 , KC_3 , KC_2 , KC_1 , KC_0,
+ NO_MINS, 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,
+ // right hand
+ KC_TRNS, KC_TRNS, KC_F9, KC_F10, KC_F11, KC_F12, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_F5, KC_F6 , KC_F7, KC_F8, KC_TRNS,
+ KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_TRNS,
+ KC_TRNS, KC_HOME, KC_TRNS, KC_END, KC_PGDN, KC_PGUP, KC_TRNS,
+ KC_HOME, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+)
+};
+
+enum macro_id {
+ TILDE_NO, LESS_NO, GRTR_NO, CIRC_NO, ACUT_NO, GRV_NO, LESS_NO_MAC, GRTR_NO_MAC, ACUT_NO_MAC
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+ [1] = ACTION_MODS_ONESHOT(MOD_LSFT), // Sticky shift light. Tap for the next keypress to be shifted. Hold for regular shift.
+ [2] = ACTION_MACRO(TILDE_NO), // Completed ~ character(pc and mac), no space needed.
+ [3] = ACTION_MACRO(LESS_NO), // < completed on keypress down, to avoid shifting the next character if it is not released first.
+ [4] = ACTION_MACRO(GRTR_NO), // > completed on keypress down, to avoid shifting the next character if it is not released first.
+ [5] = ACTION_MACRO(CIRC_NO), // Completed ^ character, no space needed.
+ [6] = ACTION_MACRO(ACUT_NO), // Completed ´ character, no space needed.
+ [7] = ACTION_MACRO(GRV_NO), // Completed ` character, no space needed.
+ [8] = ACTION_MACRO(LESS_NO_MAC), // < completed on keypress down, to avoid same button problem when typing <> quickly
+ [9] = ACTION_MACRO(GRTR_NO_MAC), // > completed on keypress down, to avoid same button problem when typing <> quickly
+ [10] = ACTION_MACRO(ACUT_NO_MAC), // Completed ´ character, no space needed
+};
+
+
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ keyevent_t event = record->event;
+
+ switch (id) {
+ case TILDE_NO:
+ return (event.pressed ? MACRO( D(RALT), T(RBRC), U(RALT), T(SPC), END ) : MACRO_NONE);
+ case LESS_NO:
+ return (event.pressed ? MACRO( T(NUBS), END ) : MACRO_NONE);
+ case GRTR_NO:
+ return (event.pressed ? MACRO( D(LSFT), T(NUBS), U(LSFT), END ) : MACRO_NONE);
+ case CIRC_NO:
+ return (event.pressed ? MACRO( D(LSFT), T(RBRC), U(LSFT), T(SPC), END ) : MACRO_NONE);
+ case ACUT_NO:
+ return (event.pressed ? MACRO( D(RALT), T(EQL), U(RALT), T(SPC), END ) : MACRO_NONE);
+ case GRV_NO:
+ return (event.pressed ? MACRO( D(LSFT), T(EQL), T(SPC), U(LSFT), END ) : MACRO_NONE);
+ case LESS_NO_MAC:
+ return (event.pressed ? MACRO( T(GRV), END ) : MACRO_NONE);
+ case GRTR_NO_MAC:
+ return (event.pressed ? MACRO( D(LSFT), T(GRV), U(LSFT), END ) : MACRO_NONE);
+ case ACUT_NO_MAC:
+ return (event.pressed ? MACRO( T(EQL), T(SPC), END ) : MACRO_NONE);
+ }
+ return MACRO_NONE;
+};
diff --git a/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/readme.md b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/readme.md
new file mode 100644
index 0000000000..f7e8baf56a
--- /dev/null
+++ b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc/readme.md
@@ -0,0 +1,30 @@
+# Norwegian setup with osx/pc toggle
+
+## Motivation
+I wanted a Norwegian setup that worked in a similar way on both my Mac and PC. I also wanted the keyboard to translate from a standard Norwegian keyboard OS setup.
+
+## Overview
+The setup is created to be programmer friendly.
+- Most of the symbols used in code can be activated without using layers or shift key.
+- You can reach the IDE/OS shortcut activators(Ctrl, Win/Cmd, Alt, Shift) with the thumb or the wrist.
+- Navigation is prioritized, arrows below the home row.
+
+## PC/Mac toggle
+The default setup is for Norwegian keyboard setting(on a PC(Windows or Linux) or Mac. Use the Mac/PC toggle button to switch between OSX and PC setup. The settings will be reverted to PC setup each time you restart/connect the keyboard.
+
+## Layers
+Since symbols are prioritized in this setup, numbers and function keys are on a new layer. The easiest way to use the layer switch(and also the alt key), is to push your hand right below the little finger, on the key. You will then have all your fingers free to type numbers or press function keys.
+
+## Tap-shift
+Tap for the next character to be shifted, hold down for regular shift.
+
+## Comma dot and escape
+Comma, dot and escape share buttons with modifier keys. Tap to access these keys, hold down to use the keys as modifier keys.
+
+## Numpad symbols
++-/* are implemented with the numpad keycodes. The benefit is that they will work better with shortcuts in certain programs. For some reason, the default setting in the osx terminal is to not accept numpad characters for '/' and '-'. For a solution, see https://discussions.apple.com/thread/6613968?start=0&tstart=0.
+If you really need the norwegian symbols in a program, you can access them using the number toggle button.
+
+## Layout
+
+![keyboard-layout](keyboard-layout.png)
diff --git a/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keyboard-layout.png b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keyboard-layout.png
new file mode 100644
index 0000000000..462de5c56b
--- /dev/null
+++ b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keyboard-layout.png
Binary files differ
diff --git a/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keymap.c b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keymap.c
new file mode 100644
index 0000000000..acf74a47d2
--- /dev/null
+++ b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/keymap.c
@@ -0,0 +1,180 @@
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+#include "keymap_norwegian.h"
+
+#define BASE 0 // default layer
+#define BASE_MAC 1 // default layer mac
+#define NUMB_FUNC 2 // numbers and function keys
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Keymap 0: Basic layer PC
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | * | [ | ] | { | } | ~ |Mac/PC| | ^ | $ | ( | ) | < | > | @ |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | + | Q | W | F | P | G | " | | ' | J | L | U | Y | Å | Æ |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | / | A | R | S | T | D |------| |------| H | N | E | I | O | Ø |
+ * |--------+------+------+------+------+------| ; | | = |------+------+------+------+------+--------|
+ * | - | Z | X | C | V | B | | | | K | M | RIGHT| DOWN | UP | _ |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * |Alt/esc| ! | ? | : | TAB | | LEFT | _ | & | | |Num/fn|
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,--------------.
+ * | # | ` | |Insert| % |
+ * ,------|------|------| |------+-------+------.
+ * | | | ´ | | Del | | |
+ * | Shift|Ctrl/.|------| |------| Enter |Space |
+ * | | |GUI/, | | Bspc | | |
+ * `--------------------' `---------------------'
+ */
+[BASE] = KEYMAP(
+ // left hand
+ KC_PAST, NO_LBRC, NO_RBRC, NO_LCBR, NO_RCBR, KC_FN2, TG(1),
+ KC_PPLS, KC_Q, KC_W, KC_F, KC_P, KC_G, NO_QUO2,
+ KC_PSLS, KC_A, KC_R, KC_S, KC_T, KC_D,
+ KC_PMNS, KC_Z, KC_X, KC_C, KC_V, KC_B, NO_SCLN,
+ ALT_T(KC_ESC), KC_EXLM , NO_QUES, NO_COLN, KC_TAB,
+ KC_HASH, KC_FN7,
+ KC_FN6,
+ KC_FN1,CTL_T(KC_DOT),GUI_T(KC_COMMA),
+ // right hand
+ KC_FN5, NO_DLR, NO_LPRN, NO_RPRN ,KC_FN3, KC_FN4,NO_AT,
+ NO_APOS, KC_J, KC_L, KC_U, KC_Y, NO_AA, NO_AE ,
+ KC_H, KC_N, KC_E, KC_I, KC_O, NO_OSLH,
+ NO_EQL, KC_K, KC_M, KC_RIGHT, KC_DOWN, KC_UP, NO_BSLS,
+ KC_LEFT, NO_UNDS, NO_AMPR, NO_PIPE, OSL(2),
+ KC_INSERT, KC_PERC,
+ KC_DELT,
+ KC_BSPC,KC_ENT,KC_SPC
+ ),
+/* Keymap 1: Basic layer MAC (Same as pc, except for cmd/ctrl, which are swapped)
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | \ | | | { | } | | | | | $ | | | < | > | @ |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | | | | | | | | | | | | | | |
+ * |--------+------+------+------+------+------| | | ' |------+------+------+------+------+--------|
+ * | | | | | | |------| |------| | | | | | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | | | | | | | | | | | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | |,/Ctrl| | | | ` | |Num/fn|
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | ` | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | ´ | | | | |
+ * | |GUI/. |------| |------| | |
+ * | | |crtl/,| | | | |
+ * `--------------------' `--------------------'
+ */
+[BASE_MAC] = KEYMAP(
+ KC_TRNS, KC_TRNS,KC_TRNS, NO_LCBR_MAC,NO_RCBR_MAC, 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, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, NO_GRV_MAC,
+ KC_FN10,
+ KC_TRNS,GUI_T(KC_DOT) , CTL_T(KC_COMMA),
+ // right hand
+ KC_TRNS, NO_DLR_MAC, KC_TRNS,KC_TRNS,KC_FN8, KC_FN9,NO_AT_MAC,
+ NO_APOS_MAC, 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, KC_TRNS, NO_BSLS_MAC,
+ KC_TRNS, KC_TRNS, KC_TRNS, NO_PIPE_MAC, OSL(2),
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+),
+
+/* Keymap 2: Number ++´ánd Fn layer pc
+ *
+ * ,--------------------------------------------------. ,--------------------------------------------------.
+ * | | | | | | | | | | | F9 | F10 | F11 | F12 | |
+ * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
+ * | | 8 | 7 | 6 | 5 | 9 | | | | | F5 | F6 | F7 | F8 | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | 4 | 3 | 2 | 1 | 0 |------| |------| | F1 | F2 | F3 | F4 | |
+ * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
+ * | | | | | | | | | | | | END | PGDWN| PGUP | |
+ * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
+ * | | | | | | | HOME | | | | |
+ * `----------------------------------' `----------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | | |------| |------| | |
+ * | | | | | | | |
+ * `--------------------' `--------------------'
+ */
+[NUMB_FUNC] = KEYMAP(
+ NO_ASTR, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ NO_PLUS, KC_8, KC_7,KC_6,KC_5, KC_9 , KC_TRNS,
+ NO_SLSH , KC_4 , KC_3 , KC_2 , KC_1 , KC_0,
+ NO_MINS, 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,
+ // right hand
+ KC_TRNS, KC_TRNS, KC_F9, KC_F10, KC_F11, KC_F12, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_F5, KC_F6 , KC_F7, KC_F8, KC_TRNS,
+ KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_TRNS,
+ KC_TRNS, KC_HOME, KC_TRNS, KC_END, KC_PGDN, KC_PGUP, KC_TRNS,
+ KC_HOME, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS,
+ KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS
+)
+};
+
+enum macro_id {
+ TILDE_NO, LESS_NO, GRTR_NO, CIRC_NO, ACUT_NO, GRV_NO, LESS_NO_MAC, GRTR_NO_MAC, ACUT_NO_MAC
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+ [1] = ACTION_MODS_ONESHOT(MOD_LSFT), // Sticky shift light. Tap for the next keypress to be shifted. Hold for regular shift.
+ [2] = ACTION_MACRO(TILDE_NO), // Completed ~ character(pc and mac), no space needed.
+ [3] = ACTION_MACRO(LESS_NO), // < completed on keypress down, to avoid shifting the next character if it is not released first.
+ [4] = ACTION_MACRO(GRTR_NO), // > completed on keypress down, to avoid shifting the next character if it is not released first.
+ [5] = ACTION_MACRO(CIRC_NO), // Completed ^ character, no space needed.
+ [6] = ACTION_MACRO(ACUT_NO), // Completed ´ character, no space needed.
+ [7] = ACTION_MACRO(GRV_NO), // Completed ` character, no space needed.
+ [8] = ACTION_MACRO(LESS_NO_MAC), // < completed on keypress down, to avoid same button problem when typing <> quickly
+ [9] = ACTION_MACRO(GRTR_NO_MAC), // > completed on keypress down, to avoid same button problem when typing <> quickly
+ [10] = ACTION_MACRO(ACUT_NO_MAC), // Completed ´ character, no space needed
+};
+
+
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ keyevent_t event = record->event;
+
+ switch (id) {
+ case TILDE_NO:
+ return (event.pressed ? MACRO( D(RALT), T(RBRC), U(RALT), T(SPC), END ) : MACRO_NONE);
+ case LESS_NO:
+ return (event.pressed ? MACRO( T(NUBS), END ) : MACRO_NONE);
+ case GRTR_NO:
+ return (event.pressed ? MACRO( D(LSFT), T(NUBS), U(LSFT), END ) : MACRO_NONE);
+ case CIRC_NO:
+ return (event.pressed ? MACRO( D(LSFT), T(RBRC), U(LSFT), T(SPC), END ) : MACRO_NONE);
+ case ACUT_NO:
+ return (event.pressed ? MACRO( D(RALT), T(EQL), U(RALT), T(SPC), END ) : MACRO_NONE);
+ case GRV_NO:
+ return (event.pressed ? MACRO( D(LSFT), T(EQL), T(SPC), U(LSFT), END ) : MACRO_NONE);
+ case LESS_NO_MAC:
+ return (event.pressed ? MACRO( T(GRV), END ) : MACRO_NONE);
+ case GRTR_NO_MAC:
+ return (event.pressed ? MACRO( D(LSFT), T(GRV), U(LSFT), END ) : MACRO_NONE);
+ case ACUT_NO_MAC:
+ return (event.pressed ? MACRO( T(EQL), T(SPC), END ) : MACRO_NONE);
+ }
+ return MACRO_NONE;
+};
diff --git a/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/readme.md b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/readme.md
new file mode 100644
index 0000000000..aaaec3e534
--- /dev/null
+++ b/keyboards/ergodox/keymaps/norwegian_programmer_osx_pc_colemak/readme.md
@@ -0,0 +1,30 @@
+# Norwegian Colemak setup with osx/pc toggle
+
+## Motivation
+I wanted a Norwegian Colemak setup that worked in a similar way on both my Mac and PC. I also wanted the keyboard to translate from a standard Norwegian keyboard OS setup.
+
+## Overview
+The setup is created to be programmer friendly.
+- Most of the symbols used in code can be activated without using layers or shift key.
+- You can reach the IDE/OS shortcut activators(Ctrl, Win/Cmd, Alt, Shift) with the thumb or the wrist.
+- Navigation is prioritized, arrows below the home row.
+
+## PC/Mac toggle
+The default setup is for Norwegian keyboard setting(not colemak software variants) on a PC(Windows or Linux) or Mac. Use the Mac/PC toggle button to switch between OSX and PC setup. The settings will be reverted to PC setup each time you restart/connect the keyboard.
+
+## Layers
+Since symbols are prioritized in this setup, numbers and function keys are on a new layer. The easiest way to use the layer switch(and also the alt key), is to push your hand right below the little finger, on the key. You will then have all your fingers free to type numbers or press function keys.
+
+## Tap-shift
+Tap for the next character to be shifted, hold down for regular shift.
+
+## Comma dot and escape
+Comma, dot and escape share buttons with modifier keys. Tap to access these keys, hold down to use the keys as modifier keys.
+
+## Numpad symbols
++-/* are implemented with the numpad keycodes. The benefit is that they will work better with shortcuts in certain programs. For some reason, the default setting in the osx terminal is to not accept numpad characters for '/' and '-'. For a solution, see https://discussions.apple.com/thread/6613968?start=0&tstart=0.
+If you really need the norwegian symbols in a program, you can access them using the number toggle button.
+
+## Layout
+
+![keyboard-layout](keyboard-layout.png)
diff --git a/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/keymap.c b/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/keymap.c
index 24d0c4ecb7..2c64304404 100644
--- a/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/keymap.c
+++ b/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/keymap.c
@@ -6,23 +6,23 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[BASE] = KEYMAP(
- KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_F5,
- KC_TAB, KC_Q, KC_W, KC_D, KC_F, KC_K, KC_BSLS,
- CTL_T(KC_ESC), KC_A, KC_S, KC_E, KC_T, KC_G,
- KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LBRC,
- KC_F1, KC_F2, KC_F3, KC_F4, KC_LGUI,
- /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ KC_VOLD, KC_MUTE,
- /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ KC_VOLU,
- /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ KC_BSPC, CTL_T(KC_ESC), KC_LALT,
+ KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_F5,
+ KC_TAB, KC_Q, KC_W, KC_D, KC_F, KC_K, KC_BSLS,
+ KC_LCTRL, KC_A, KC_S, KC_E, KC_T, KC_G,
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LBRC,
+ KC_F1, KC_F2, KC_F3, KC_F4, KC_LGUI,
+ /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ KC_VOLD, KC_MUTE,
+ /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ KC_VOLU,
+ /*-*/ /*-*/ /*-*/ /*-*/ /*-*/ KC_BSPC, CTL_T(KC_ESC), KC_LALT,
//
- /*-*/ KC_F6, KC_6, KC_7, KC_8, KC_9, KC_0, KC_EQL,
- /*-*/ KC_NO, KC_J, KC_U, KC_R, KC_L, KC_SCLN, KC_MINS,
- /*-*/ /*-*/ KC_Y, KC_N, KC_I, KC_O, KC_H, KC_ENT,
- /*-*/ KC_RBRC, KC_P, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT,
- /*-*/ /*-*/ /*-*/ KC_RGUI, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT,
- KC_MPLY, KC_MNXT,
+ /*-*/ KC_F6, KC_6, KC_7, KC_8, KC_9, KC_0, KC_EQL,
+ /*-*/ KC_NO, KC_J, KC_U, KC_R, KC_L, KC_SCLN, KC_MINS,
+ /*-*/ /*-*/ KC_Y, KC_N, KC_I, KC_O, KC_H, KC_ENT,
+ /*-*/ KC_RBRC, KC_P, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT,
+ /*-*/ /*-*/ /*-*/ KC_RGUI, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT,
+ KC_MPLY, KC_MNXT,
KC_MPRV,
- KC_RALT, KC_QUOT, KC_SPC
+ KC_RALT, KC_QUOT, KC_SPC
)
};
diff --git a/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/readme.md b/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/readme.md
index 80475ab21e..4fa1814fb1 100644
--- a/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/readme.md
+++ b/keyboards/ergodox/keymaps/romanzolotarev-norman-osx/readme.md
@@ -1,28 +1,41 @@
# Roman's Layout
-There is only one layer based on [Norman layout](https://normanlayout.info/).
+There is only one layer, and it is based on [Norman
+layout](https://normanlayout.info/).
Looking for multiple-layer layouts?
-- [Symbols, arrows, plover, HJKL arrows](../romanzolotarev-norman-plover-osx-hjkl/)
+- [Symbols, arrows, plover, HJKL
+ arrows](../romanzolotarev-norman-plover-osx-hjkl/)
- [Same with IJKL arrows](../romanzolotarev-norman-plover-osx/)
[![keyboard-layout](romanzolotarev-norman-osx.png)](http://www.keyboard-layout-editor.com/#/gists/9e89d54f1ea6eeeb7dab1b2d19d28195)
-## Functional Keys
+## How to use Vim key
-- Tap `F1` to mute microphone via [Shush](http://mizage.com/shush/).
-- Tap `F2` to copy screenshot to the clipboard.
-- Hold `SHIFT` and tap `F2` to save screenshot as a file.
-- Tap `F3`, `F4`, `F5`, `F6` to resize a window via [Divvy](http://mizage.com/divvy/).
-
-## CTRL/ESC
-
-CTRL and ESC are frequently used in Vim.
+It is `CTL_T(KC_ESC)` and it works this way:
- Tap `CTRL/ESC` to send `ESC`.
- Hold `CTRL/ESC` to use as `CTRL`.
-## Activate N-rollover
+## How to activate N-rollover
+
+- Hold left `SHIFT` and right `SHIFT` and then tap `N`.
+
+## How to make and flash on OS X
+
+First you need to install few brew packages.
+
+```bash
+brew tap osx-cross/avr
+brew install dfu-programmer avr-libc teensy_loader_cli
+```
+
+Then you can clone this repository, make and flash your ErgoDox.
-- Hold left `SHIFT` and right `SHIRT` and then tap `N`.
+```bash
+git clone https://github.com/romanzolotarev/qmk_firmware
+cd qmk_firmware/keyboards/ergodox
+# Optionally tweak ./keymaps/romanzolotarev-norman-osx/keymap.c
+SLEEP_LED_ENABLED=no KEYMAP=romanzolotarev-norman-osx make teensy
+```
diff --git a/keyboards/ergodox/keymaps/yoruian/90-ergodox-yoruian.conf b/keyboards/ergodox/keymaps/yoruian/90-ergodox-yoruian.conf
new file mode 100644
index 0000000000..ce4fce3b1d
--- /dev/null
+++ b/keyboards/ergodox/keymaps/yoruian/90-ergodox-yoruian.conf
@@ -0,0 +1,6 @@
+Section "InputClass"
+ Identifier "ErgoDox EZ"
+ MatchIsKeyboard "on"
+ MatchProduct "ErgoDox EZ ErgoDox EZ"
+ Option "XkbLayout" "ergodox_yoruian"
+EndSection
diff --git a/keyboards/ergodox/keymaps/yoruian/Makefile b/keyboards/ergodox/keymaps/yoruian/Makefile
new file mode 100644
index 0000000000..b43a24c611
--- /dev/null
+++ b/keyboards/ergodox/keymaps/yoruian/Makefile
@@ -0,0 +1,13 @@
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif
+
+install-xorg-configuration:
+ install -m 0664 90-$(KEYBOARD)-$(KEYMAP).conf \
+ /etc/X11/xorg.conf.d/90-$(KEYBOARD)-$(KEYMAP).conf
+ install -m 0644 $(KEYBOARD)_$(KEYMAP) \
+ /usr/share/X11/xkb/symbols/$(KEYBOARD)_$(KEYMAP)
+
+uninstall-xorg-configuration:
+ -rm -f /etc/X11/xorg.conf.d/90-$(KEYBOARD)-$(KEYMAP).conf
+ -rm -f /usr/share/X11/xkb/symbols/$(KEYBOARD)_$(KEYMAP)
diff --git a/keyboards/ergodox/keymaps/yoruian/README b/keyboards/ergodox/keymaps/yoruian/README
new file mode 100644
index 0000000000..99b41434ef
--- /dev/null
+++ b/keyboards/ergodox/keymaps/yoruian/README
@@ -0,0 +1,102 @@
+ Snarfangel's YORUIAN for the ErgoDox EZ
+ ‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾
+DEFAULT
+┏━━━┯━━━┯━━━┯━━━┯━━━┯━━━┯━━━┓ ┏━━━┯━━━┯━━━┯━━━┯━━━┯━━━┯━━━┓
+┃ ` │ ; │ : │ - │ / │ ( │ < ┃ ┃ > │ ) │ ^ │ * │ ~ │ Γ │ σ ┃
+┠───┼───┼───┼───┼───┼───┼───┨ ┠───┼───┼───┼───┼───┼───┼───┨
+┃ ⎋ │ . │ y │ o │ r │ ? │ ✦ ┃ ┃ ✦ │ j │ v │ d │ f │ w │ q ┃
+┠───┼───┼───┼───┼───┼───┤ ┃ ┃ ├───┼───┼───┼───┼───┼───┨
+┃ ⎈ │ u │ i │ a │ n │ ! ├───┨ ┠───┤ m │ h │ t │ s │ c │ ⎈ ┃
+┠───┼───┼───┼───┼───┼───┤ ❖ ┃ ┃ ❖ ├───┼───┼───┼───┼───┼───┨
+┃ λ │ ' │ " │ , │ _ │ = │ ┃ ┃ │ k │ l │ p │ g │ b │ x ┃
+┠───┼───┼───┼───┼───╆━━━┷━━━┛ ┗━━━┷━━━╅───┼───┼───┼───┼───┨
+┃ ⎀ │ E │ │ │ ◆ ┃ ┃ ◆ │ │ │ z │ ⎙ ┃
+┗━━━┷━━━┷━━━┷━━━┷━━━┛ ┗━━━┷━━━┷━━━┷━━━┷━━━┛
+ ┏━━━┯━━━┓ ┏━━━┯━━━┓
+ ┃ ⌫ │ ⌥ ┃ ┃ ⎄ │ ↹ ┃
+ ┏━━━╃───┼───┨ ┠───┼───╄━━━┓
+ ┃ │ │ ┃ ┃ │ │ ┃
+ ┃ e │ ⇧ ├───┨ ┠───┤ ⏎ │ ␣ ┃
+ ┃ │ │ ┃ ┃ │ │ ┃
+ ┗━━━┷━━━┷━━━┛ ┗━━━┷━━━┷━━━┛
+SHIFTED
+┏━━━┯━━━┯━━━┯━━━┯━━━┯━━━┯━━━┓ ┏━━━┯━━━┯━━━┯━━━┯━━━┯━━━┯━━━┓
+┃ 9 │ 7 │ 5 │ 3 │ 1 │ [ │ { ┃ ┃ } │ ] │ 0 │ 2 │ 4 │ 6 │ 8 ┃
+┠───┼───┼───┼───┼───┼───┼───┨ ┠───┼───┼───┼───┼───┼───┼───┨
+┃ │ * │ Y │ O │ R │ \ │ ┃ ┃ │ J │ V │ D │ F │ W │ Q ┃
+┠───┼───┼───┼───┼───┼───┤ ┃ ┃ ├───┼───┼───┼───┼───┼───┨
+┃ │ U │ I │ A │ N │ | ├───┨ ┠───┤ M │ H │ T │ S │ C │ ┃
+┠───┼───┼───┼───┼───┼───┤ ┃ ┃ ├───┼───┼───┼───┼───┼───┨
+┃ │ # │ $ │ @ │ & │ + │ ┃ ┃ │ K │ L │ P │ G │ B │ X ┃
+┠───┼───┼───┼───┼───╆━━━┷━━━┛ ┗━━━┷━━━╅───┼───┼───┼───┼───┨
+┃ │ │ │ │ ┃ ┃ │ │ │ Z │ ┃
+┗━━━┷━━━┷━━━┷━━━┷━━━┛ ┗━━━┷━━━┷━━━┷━━━┷━━━┛
+ ┏━━━┯━━━┓ ┏━━━┯━━━┓
+ ┃ │ ┃ ┃ │ ┃
+ ┏━━━╃───┼───┨ ┠───┼───╄━━━┓
+ ┃ │ │ ┃ ┃ │ │ ┃
+ ┃ │ ├───┨ ┠───┤ │ ┃
+ ┃ │ │ ┃ ┃ │ │ ┃
+ ┗━━━┷━━━┷━━━┛ ┗━━━┷━━━┷━━━┛
+λ LAYER
+┏━━━┯━━━┯━━━┯━━━┯━━━┯━━━┯━━━┓ ┏━━━┯━━━┯━━━┯━━━┯━━━┯━━━┯━━━┓
+┃ │ │ │ │ │ │ ┃ ┃ │ │ ⑤ │ ⑥ │ ⑦ │ ⑧ │ ⑨ ┃
+┠───┼───┼───┼───┼───┼───┼───┨ ┠───┼───┼───┼───┼───┼───┼───┨
+┃ │ │ │ │ │ │ ┃ ┃ │ │ ① │ ② │ ③ │ ④ │ ⑩ ┃
+┠───┼───┼───┼───┼───┼───┤ ┃ ┃ ├───┼───┼───┼───┼───┼───┨
+┃ │ │ │ │ │ ├───┨ ┠───┤ ⎉ │ ← │ ↓ │ ↑ │ → │ ⑪ ┃
+┠───┼───┼───┼───┼───┼───┤ ┃ ┃ ├───┼───┼───┼───┼───┼───┨
+┃ λ │ │ │ │ │ │ ┃ ┃ │ │ ⇱ │ ⎘ │ ⎗ │ ⇲ │ ⑫ ┃
+┠───┼───┼───┼───┼───╆━━━┷━━━┛ ┗━━━┷━━━╅───┼───┼───┼───┼───┨
+┃ │ │ │ │ ┃ ┃ │ │ │ │ ┃
+┗━━━┷━━━┷━━━┷━━━┷━━━┛ ┗━━━┷━━━┷━━━┷━━━┷━━━┛
+ ┏━━━┯━━━┓ ┏━━━┯━━━┓
+ ┃ │ ┃ ┃ │ ┃
+ ┏━━━╃───┼───┨ ┠───┼───╄━━━┓
+ ┃ │ │ ┃ ┃ │ │ ┃
+ ┃ │ ├───┨ ┠───┤ │ ┃
+ ┃ │ │ ┃ ┃ │ │ ┃
+ ┗━━━┷━━━┷━━━┛ ┗━━━┷━━━┷━━━┛
+
+Installation (X only)
+‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾
+ 1. Build and flash firmware as usual
+
+ 2. sudo make install-xorg-configuration
+
+ 3. Restart X
+
+Features
+‾‾‾‾‾‾‾‾
+ • E on the thumb
+
+ • Emacs-friendly
+
+ • Symmetric control keys for finger wear levelling
+
+ • Greek and subscript dead keys
+
+ • Compose key for arbitrary Unicode input via ~/.XCompose
+
+Don't Cares
+‾‾‾‾‾‾‾‾‾‾‾
+ • Easy migration from QWERTY
+
+ • Compatbility with non-XKB systems
+
+ • Mouse emulation
+
+ • Media keys
+
+Acknowledgements
+‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾
+Snarfangel, for designing the layout.
+
+The GNU FreeFont project and Steve White, for adding new keyboard
+symbols.
+
+Xah Lee, for http://xahlee.info/comp/unicode_computing_symbols.html
+
+Colophon
+‾‾‾‾‾‾‾‾
+This file is best-viewed with an SVN version of GNU FreeFont Mono.
diff --git a/keyboards/ergodox/keymaps/yoruian/ergodox_yoruian b/keyboards/ergodox/keymaps/yoruian/ergodox_yoruian
new file mode 100644
index 0000000000..0d13fbfd4c
--- /dev/null
+++ b/keyboards/ergodox/keymaps/yoruian/ergodox_yoruian
@@ -0,0 +1,34 @@
+partial alphanumeric_keys modifier_keys
+xkb_symbols "ergodox_yoruian" {
+ include "us"
+ name[Group1]= "English (yoruian-1.0.0)";
+
+ replace key <KP2> { [ Multi_key, Multi_key ] };
+ replace key <KP3> { [ Hyper_L, Hyper_L ] };
+ replace key <AE09> { [ grave, 9 ] };
+ replace key <AE07> { [ semicolon, 7 ] };
+ replace key <AE05> { [ colon, 5 ] };
+ replace key <AE03> { [ minus, 3 ] };
+ replace key <AE01> { [ slash, 1 ] };
+ replace key <AE10> { [ asciicircum, 0 ] };
+ replace key <AE02> { [ percent, 2 ] };
+ replace key <AE04> { [ asciitilde, 4 ] };
+ replace key <AE06> { [ dead_greek, 6 ] };
+ replace key <AE08> { [ dead_caron, 8 ] };
+ replace key <KP1> { [ E, E ] };
+ replace key <AD12> { [ period, asterisk ] };
+ replace key <BKSL> { [ question, backslash ] };
+ replace key <AC10> { [ exclam, bar ] };
+ replace key <AC11> { [ apostrophe, numbersign ] };
+ replace key <AB08> { [ quotedbl, dollar ] };
+ replace key <AB09> { [ comma, at ] };
+ replace key <AB10> { [ underscore, ampersand ] };
+ replace key <KP0> { [ equal, plus ] };
+ replace key <TLDE> { [ parenleft, bracketleft ] };
+ replace key <AE11> { [ less, braceleft ] };
+ replace key <AE12> { [ greater, braceright ] };
+ replace key <AD11> { [ parenright, bracketright ] };
+
+ modifier_map none { <HYPR> };
+ modifier_map Mod3 { <KP3> };
+};
diff --git a/keyboards/ergodox/keymaps/yoruian/keymap.c b/keyboards/ergodox/keymaps/yoruian/keymap.c
new file mode 100644
index 0000000000..d3635ddf3f
--- /dev/null
+++ b/keyboards/ergodox/keymaps/yoruian/keymap.c
@@ -0,0 +1,61 @@
+/*
+ * Copyright 2016 Thomas Fitzsimmons <fitzsim@fitzsim.org>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+#include "yoruian.h"
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+[0] = KEYMAP\
+(9, 7, 5, 3, 1, GRV, MINS, EQL, LBRC, 0, 2, 4, 6, 8,
+ ES, RBRC, Y, O, R, BSLS, P3, P3, J, V, D, F, W, Q,
+ LC, U, I, A, N, SCLN, M, H, T, S, C, RC,
+ FF, QUOT, COMM, DOT, SLSH, P0, LGUI, LGUI, K, L, P, G, B, X,
+ IN, P1, NO, NO, LALT, LALT, NO, NO, Z, PS,
+ BSPC, RALT, P2, TAB,
+ NO, NO,
+ E, LSFT, NO, NO, ENT, SPC),
+[1] = KEYMAP\
+(TR, TR, TR, TR, TR, TR, TR, TR, TR, F5, F6, F7, F8, F9,
+ TR, TR, TR, TR, TR, TR, TR, TR, TR, F1, F2, F3, F4, FT,
+ TR, TR, TR, TR, TR, TR, PAUS, LEFT, DOWN, UP, RGHT, FE,
+ TR, TR, TR, TR, TR, TR, TR, TR, TR, HOME, PGDN, PGUP, END, FW,
+ TR, TR, TR, TR, TR, TR, TR, TR, TR, TR,
+ TR, TR, TR, TR,
+ TR, TR,
+ TR, TR, TR, TR, TR, TR),
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
+ return MACRO_NONE;
+};
+
+void matrix_init_user(void) {
+};
+
+void matrix_scan_user(void) {
+ ergodox_board_led_off();
+ ergodox_right_led_1_off();
+ ergodox_right_led_2_off();
+ ergodox_right_led_3_off();
+};
+
+/*
+ * Local Variables:
+ * electric-indent-mode: nil
+ * End:
+ */
diff --git a/keyboards/ergodox/keymaps/yoruian/yoruian.h b/keyboards/ergodox/keymaps/yoruian/yoruian.h
new file mode 100644
index 0000000000..1adcb7fd3f
--- /dev/null
+++ b/keyboards/ergodox/keymaps/yoruian/yoruian.h
@@ -0,0 +1,61 @@
+/*
+ * Copyright 2016 Thomas Fitzsimmons <fitzsim@fitzsim.org>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+#include "ergodox.h"
+#include "debug.h"
+#include "action_layer.h"
+
+#undef KEYMAP
+#define KEYMAP\
+( \
+ /* Spacial positions. */ \
+ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D, \
+ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1C, k1D, \
+ k20, k21, k22, k23, k24, k25, k28, k29, k2A, k2B, k2C, k2D, \
+ k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3A, k3B, k3C, k3D, \
+ k40, k41, k42, k43, k44, k49, k4A, k4B, k4C, k4D, \
+ k55, k56, k57, k58, \
+ k54, k59, \
+ k53, k52, k51, k5C, k5B, k5A) \
+ \
+ /* Matrix positions. */ \
+ { \
+ { KC_##k00, KC_##k10, KC_##k20, KC_##k30, KC_##k40, KC_NO }, \
+ { KC_##k01, KC_##k11, KC_##k21, KC_##k31, KC_##k41, KC_##k51 }, \
+ { KC_##k02, KC_##k12, KC_##k22, KC_##k32, KC_##k42, KC_##k52 }, \
+ { KC_##k03, KC_##k13, KC_##k23, KC_##k33, KC_##k43, KC_##k53 }, \
+ { KC_##k04, KC_##k14, KC_##k24, KC_##k34, KC_##k44, KC_##k54 }, \
+ { KC_##k05, KC_##k15, KC_##k25, KC_##k35, KC_NO, KC_##k55 }, \
+ { KC_##k06, KC_##k16, KC_NO, KC_##k36, KC_NO, KC_##k56 }, \
+ { KC_##k07, KC_##k17, KC_NO, KC_##k37, KC_NO, KC_##k57 }, \
+ { KC_##k08, KC_##k18, KC_##k28, KC_##k38, KC_NO, KC_##k58 }, \
+ { KC_##k09, KC_##k19, KC_##k29, KC_##k39, KC_##k49, KC_##k59 }, \
+ { KC_##k0A, KC_##k1A, KC_##k2A, KC_##k3A, KC_##k4A, KC_##k5A }, \
+ { KC_##k0B, KC_##k1B, KC_##k2B, KC_##k3B, KC_##k4B, KC_##k5B }, \
+ { KC_##k0C, KC_##k1C, KC_##k2C, KC_##k3C, KC_##k4C, KC_##k5C }, \
+ { KC_##k0D, KC_##k1D, KC_##k2D, KC_##k3D, KC_##k4D, KC_NO } \
+ }
+
+#define KC_ES KC_ESC
+#define KC_LC KC_LCTL
+#define KC_RC KC_RCTL
+#define KC_FF MO(1)
+#define KC_IN KC_INS
+#define KC_PS KC_PSCR
+#define KC_TR KC_TRNS
+#define KC_FT KC_F10
+#define KC_FE KC_F11
+#define KC_FW KC_F12
diff --git a/keyboards/ergodox/keymaps/zweihander-osx/makefile.mk b/keyboards/ergodox/keymaps/zweihander-osx/Makefile
index 6e3d088a43..6e3d088a43 100644
--- a/keyboards/ergodox/keymaps/zweihander-osx/makefile.mk
+++ b/keyboards/ergodox/keymaps/zweihander-osx/Makefile
diff --git a/keyboards/ergodox/keymaps/zweihander-osx/keymap.c b/keyboards/ergodox/keymaps/zweihander-osx/keymap.c
index d6d66fd55d..725a73e346 100644
--- a/keyboards/ergodox/keymaps/zweihander-osx/keymap.c
+++ b/keyboards/ergodox/keymaps/zweihander-osx/keymap.c
@@ -32,7 +32,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* ,------|------|------| |------+--------+------.
* | | | PgUp | | PgDn | | |
* | | ⇥ |------| |------| ⇥ |Enter |
- * | | | L⌥ | | L⌃ | | |
+ * | | | R⌥ | | R⌃ | | |
* `--------------------' `----------------------'
*/
// If it accepts an argument (i.e, is a function), it doesn't need KC_.
@@ -46,7 +46,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_LCTL, KC_LALT, KC_LGUI,KC_LEFT,KC_RGHT,
KC_GRV, KC_QUOT,
KC_PGUP,
- KC_SPC,KC_TAB ,KC_LALT,
+ KC_SPC,KC_TAB ,KC_RALT,
// right hand
TG(SYMB), KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,
MO(SYMB), KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
@@ -55,7 +55,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_UP, KC_DOWN,KC_LBRC,KC_RBRC, KC_SPC ,
KC_ESC, KC_BSPC,
KC_PGDN,
- KC_LCTL, KC_TAB, KC_ENT
+ KC_RCTL, KC_TAB, KC_ENT
),
/* Keymap 1: Symbol Layer
*
@@ -102,13 +102,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Keymap 2: Media keys
*
* ,--------------------------------------------------. ,--------------------------------------------------.
- * | | F14 | F15 | | | | | | ⌘Q | ⌘W | ⌘⇧` | ⌘` | | | Power |
+ * | | F14 | F15 |PrtScr|SclLck| Pause| | | ⌘Q | ⌘W | ⌘⇧` | ⌘` | | | Power |
* |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
* | | | | PgUp |⌘S⌘⇥⌘R| Term | | | | ⌘] | ⌥⌘↑ | ↑ | ⌥⌘↓ | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
* | | |Safari| PgDn | | |------| |------| ⌘[ | ← | ↓ | → | | ⏯ |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
- * | | | | | |BBEdit| | | |L⇧+Spc| Spc | ⏮ | ⏭ | | |
+ * | | | | | |BBEdit| | | | | ⏯ | ⏮ | ⏭ | | |
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
* | | | | | | |VolUp |VolDn | Mute | | |
* `----------------------------------' `----------------------------------'
@@ -122,7 +122,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
*/
// MEDIA AND MOUSE
[MDIA] = KEYMAP(
- KC_TRNS, KC_F14 , KC_F15 , KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, /* F14 dims screen, F15 brightens */
+ KC_TRNS, KC_F14 , KC_F15 , KC_PSCR, KC_SLCK, KC_PAUS, KC_TRNS, /* F14 dims screen, F15 brightens */
KC_TRNS, KC_TRNS, KC_TRNS, KC_PGUP, M(SGWF), M(TMNL), KC_TRNS,
KC_TRNS, KC_TRNS, M(SAFA), KC_PGDN, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, M(BBED), KC_TRNS,
@@ -134,7 +134,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
LGUI(KC_Q), LGUI(KC_W), LGUI(LSFT(KC_GRV)), LGUI(KC_GRV), KC_TRNS, KC_TRNS, KC_PWR ,
KC_TRNS, LGUI(KC_RBRC), LGUI(LALT(KC_UP)), KC_UP , LGUI(LALT(KC_DOWN)), KC_TRNS, KC_TRNS,
LGUI(KC_LBRC), KC_LEFT, KC_DOWN, KC_RGHT, KC_TRNS, KC_MPLY,
- KC_TRNS, LSFT(KC_SPC), KC_SPC , KC_MPRV, KC_MNXT, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_MPLY, KC_MPRV, KC_MNXT, KC_TRNS, KC_TRNS,
KC_VOLU, KC_VOLD, KC_MUTE, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS,
KC_END ,
diff --git a/keyboards/ergodox/keymaps/zweihander-osx/readme.markdown b/keyboards/ergodox/keymaps/zweihander-osx/readme.markdown
index 3b7f52941a..5125a12ee1 100644
--- a/keyboards/ergodox/keymaps/zweihander-osx/readme.markdown
+++ b/keyboards/ergodox/keymaps/zweihander-osx/readme.markdown
@@ -7,7 +7,7 @@ This layout is tuned for people who…
## use OS X
-This layout doesn’t make any concessions for Windows use. While it should work fine in Windows, I’m not about to devote precious keyboard space to Windows-specific shortcuts.
+While this layout should work fine in Windows, it’s not tuned for it. No sane person who primarily uses Windows would put this many Windows keys on a keyboard layout.
## mouse left-handed while doing other things with the right hand
@@ -21,8 +21,6 @@ I tend to have my mouse in my left hand, but I like to use my other hand to make
- Go Up and Close Just-Left Folder (⌥⌘↑)
- Cycle through open windows in current application (⌘\` and ⌘⇧\`)
- Cycle through tabs in current window (⌥⇥ and ⌥⇧⇥)
-- Space (page down in browsers; Quick Look in the Finder)
-- Shift-Space (page up in web browsers)
Because moving letter-by-letter is way slower than moving word-by-word, I added Option (⌥) to the bottommost button on the left side. This key can be held easily while holding ; (activate media layer) and pressing J and L to move left and right by word.
@@ -34,11 +32,15 @@ I wanted to preserve the feel of a number of shortcuts that involve pressing lot
- Empty Trash Without Asking for Confirmation (⇧⌥⌘⌫)
- Shut Down Without Asking for Confirmation (⇧⌥⌘ power)
+⇧⌥⌘⌫, when you press the backspace on the right half of the keyboard, is much more satisfying than if you curl your left hand into a claw to press all the keys on the left. Try both; you’ll agree.
+
## use Emacs-style shortcuts
I press C-a, C-e, and C-k all the time. It’s difficult to press these key combinations with the control key on the bottom left and I’m too quick on the draw for the control function on the / key to work reliably, so the bottommost thumb button on the right side is another control key.
+Having trouble remembering which thumb key is alt and which is ctrl? It’s like on the lower right of a normal keyboard — leftmost is alt, rightmost is ctrl.
+
## use spreadsheets
diff --git a/keyboards/ergodox/readme.md b/keyboards/ergodox/readme.md
index f81d7cd8df..3bbe98fd69 100644
--- a/keyboards/ergodox/readme.md
+++ b/keyboards/ergodox/readme.md
@@ -1,33 +1,137 @@
-# Getting started
+# The Easy Way
-There are two main ways you could customize the ErgoDox (EZ and Infinity)
+If you can find firmware someone else has made that does what you want, that
+is the easiest way to customize your ErgoDox. It requires no programming
+experience or the setup of a build environment.
-## The Easy Way: Use an existing firmware file and just flash it (ErgoDox EZ only)
+Quickstart:
-1. Download and install the [Teensy Loader](https://www.pjrc.com/teensy/loader.html). Some Linux distributions already provide a binary (may be called `teensy-loader-cli`), so you may prefer to use this.
-2. Find a firmware file you like. There are [dozens of community-contributed keymaps](http://qmk.fm/keyboards/ergodox/) you can browse and download. You can also use the [Massdrop configurator](https://keyboard-configurator.massdrop.com/ext/ergodox) to create a firmware Hex file you like.
-3. Download the firmware file
-4. Connect the keyboard, press its Reset button (gently insert a paperclip into the hole in the top-right corner) and flash it using the Teensy loader you installed on step 1 and the firmware you downloaded.
+ - Find and download an existing firmware
+ [from Other Firmware Options](#other-firmware-options)
-## More technical: compile an existing keymap, or create your own totally custom firmware by editing the source files.
+ - Then flash the firmware to your [ErgoDox Ez](#ergodox-ez)
+ or [ErgoDox Infinity](#ergodox-infinity)
-This requires a little bit of familiarity with coding.
-If you are just compiling an existing keymap and don't want to create your own, you can skip step 4, 5 and 8.
+# Customizing Keymaps
-1. Go to https://github.com/jackhumbert/qmk_firmware and read the readme at the base of this repository, top to bottom. Then come back here :)
-2. Clone the repository (download it)
-3. Set up a build environment as per the readme.
-4. Copy `keyboards/ergodox/keymaps/default/keymap.c` into `keymaps/your_name/keymap.c` (for example, `keymaps/german/keymap.c`)
-5. Edit this file, changing keycodes to your liking (see "Finding the keycodes you need" below). Try to edit the comments as well, so the "text graphics" represent your layout correctly. See below for more tips on sharing your work.
-6. Compile your firmware by running `make keymap=keymap_name`. For example, `make keymap=german`. This will result in a hex file, which will be called `ergodox_ez_keymap_name.hex`, e.g. `ergodox_ez_german.hex`. For **Infinity ErgoDox** you need to add `subproject=infinity` to the make command.
-7. **ErgoDox EZ** - Flash this hex file using the [Teensy loader](https://www.pjrc.com/teensy/loader.html) as described in step 4 in the "Easy Way" above. If you prefer you can automatically flash the hex file after successful build by running `make teensy keymap=keymap_name`.
+There are many existing keymaps in the "keymaps" directory. If you just want
+to use one of them, you don't need to modify keymaps and can just build and
+flash the firmware as described below. These directories each have a
+"readme.md" file which describe them.
- **Infinity ErgoDox** - Flash the firmware by running `make dfu-util keymap=keymap_name subproject=infinity`
-8. Submit your work as a pull request to this repository, so others can also use it. :) See below on specifics.
+If none of the existing keymaps suit you, you can create your own custom
+keymap. This will require some experience with coding. Follow these steps
+to customize a keymap:
-Good luck! :)
+ - Read the [qmk firmware README](https://github.com/jackhumbert/qmk_firmware) from top to bottom. Then come back here. :)
-## Contributing your keymap
+ - Clone the qmk_firmware repository
+
+ - Set up your build environment (see below).
+
+ - Make a new directory under "keymaps" to hold your customizations.
+
+ - Copy an existing keymap that is close to what you want, such as
+ "keymaps/default/keymap.c".
+
+ - Use an editor to modify the new "keymap.c". See "Finding the keycodes you
+ need" below). Try to edit the comments as well, so the "text graphics"
+ represent your layout correctly.
+
+ - Compile your new firmware (see below)
+
+ - Flash your firmware (see below)
+
+ - Test the changes.
+
+ - Submit your keymap as a pull request to the qmk_firmware repository so
+ others can use it. You will want to add a "readme.md" that describes the
+ keymap.
+
+# Build Dependencies
+
+Before you can build, you will need the build dependencies. There is a script
+to try to do this for Linux:
+
+ - Run the `util/install_dependencies.sh` script as root.
+
+For the Infinity, you need the chibios submodules to be checked out or you
+will receive errors about the build process being unable to find the chibios
+files. Check them out with:
+
+ - Go to the top level repo directory and run: `git submodule update --init --recursive`
+
+# Flashing Firmware
+
+## ErgoDox Ez
+
+The Ez uses the [Teensy Loader](https://www.pjrc.com/teensy/loader.html).
+
+Linux users need to modify udev rules as described on the Teensy Linux page.
+Some distributions provide a binary, maybe called `teensy-loader-cli`).
+
+To flash the firmware:
+
+ - Build the firmware with `make keymapname`, for example `make default`
+ - This will result in a hex file called `ergodox_ez_keymapname.hex`, e.g.
+ `ergodox_ez_default.hex`
+
+ - Start the teensy loader.
+
+ - Load the .hex file into it.
+
+ - Press the Reset button by inserting a paperclip gently into the reset hole
+ in the top right corder.
+
+ - Click the button in the Teensy app to download the firmware.
+
+## ErgoDox Infinity
+
+The Infinity is two completely independent keyboards, and needs to be flashed
+for the left and right halves seperately. To flash them:
+
+ - Build the firmware with `make infinity-keymapname`
+
+ - Plug in the left hand keyboard only.
+
+ - Press the program button (back of keyboard, above thumb pad).
+
+ - Install the firmware with `sudo make infinity-keymapname-dfu-util`
+
+ - Build left hand firmware with `make infinity-keymapname MASTER=right`
+
+ - Plug in the right hand keyboard only.
+
+ - Press the program button (back of keyboard, above thumb pad).
+
+ - Install the firmware with `sudo make infinity-keymapname-dfu-util MASTER=right`
+
+More information on the Infinity firmware is available in the [TMK/chibios for
+Input Club Infinity Ergodox](https://github.com/fredizzimo/infinity_ergodox/blob/master/README.md)
+
+### Infinity Master/Two Halves
+
+The Infinity is two completely independent keyboards, that can connect together.
+You have a few options in how you flash the firmware:
+
+- Flash the left half, rebuild the firmware with "MASTER=right" and then flash
+ the right half. This allows you to plug in either half directly to the
+ computer and is what the above instructions do.
+
+- Flash the left half, then flash the same firmware on the right. This only
+ works when the left half is plugged directly to the computer and the keymap
+ is mirrored. It saves the small extra step of rebuilding with
+ "MASTER=right".
+
+- The same as the previous one but with "MASTER=right" when you build the
+ firmware, then flash the same firmware to both halves. You just have to
+ directly connect the right half to the computer.
+
+- For minor changes such as changing only the keymap without having updated
+ any part of the firmware code itself, you can program only the MASTER half.
+ It is safest to program both halves though.
+
+# Contributing your keymap
The QMK firmware is open-source, so it would be wonderful to have your contribution! Within a very short time after launching we already amassed dozens of user-contributed keymaps, with all sorts of creative improvements and tweaks. This is very valuable for people who aren't comfortable coding, but do want to customize their ErgoDox. To make it easy for these people to use your layout, I recommend submitting your PR in the following format.
@@ -36,11 +140,26 @@ The QMK firmware is open-source, so it would be wonderful to have your contribut
3. `readme.md` - a readme file, which GitHub would display by default when people go to your directory. Explain what's different about your keymap, what you tweaked or how it works. No specific format to follow, just communicate what you did. :)
4. Any graphics you wish to add. This is absolutely not a must. If you feel like it, you can use [Keyboard Layout Editor](http://keyboard-layout-editor.com) to make something and grab a screenshot, but it's really not a must. If you do have graphics, your readme can just embed the graphic as a link, just like I did with the default layout.
-
-## Finding the keycodes you need
+# Finding the keycodes you need
Let's say you want a certain key in your layout to send a colon; to figure out what keycode to use to make it do that, you're going to need `quantum/keymap_common.h`.
That file contains a big list of all of the special, fancy keys (like, being able to send % on its own and whatnot).
If you want to send a plain vanilla key, you can look up its code under `doc/keycode.txt`. That's where all the boring keys hang out.
+
+# Other Firmware Options
+
+There are external tools for customizing the layout, but those do not use
+the featurs of this qmk firmware. These sites include:
+
+ - [Massdrop configurator](https://keyboard-configurator.massdrop.com/ext/ergodox) for Ez
+ - [Input Club configurator](https://input.club/configurator-ergodox) for Infinity, provides left and right files
+
+You can also find an existing firmware that you like, for example from:
+
+ - [Dozens of community-contributed keymaps](http://qmk.fm/keyboards/ergodox/)
+
+This qmk firmware also provides the ability to customize keymaps, but requires
+a toolchain to build the firmware. See below for instructions on building
+firmware and customizing keymaps.
diff --git a/keyboards/ergodox/rules.mk b/keyboards/ergodox/rules.mk
new file mode 100644
index 0000000000..add64ec76f
--- /dev/null
+++ b/keyboards/ergodox/rules.mk
@@ -0,0 +1,29 @@
+#----------------------------------------------------------------------------
+# On command line:
+#
+# make = Make software.
+#
+# make clean = Clean out built project files.
+#
+# That's pretty much all you need. To compile, always go make clean,
+# followed by make.
+#
+# For advanced users only:
+# make teensy = Download the hex file to the device, using teensy_loader_cli.
+# (must have teensy_loader_cli installed).
+#
+#----------------------------------------------------------------------------
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+CUSTOM_MATRIX ?= yes # Custom matrix file for the ErgoDox EZ
+SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= yes # Unicode
+ONEHAND_ENABLE ?= yes # Allow swapping hands of keyboard
diff --git a/keyboards/gh60/Makefile b/keyboards/gh60/Makefile
index 39a9cc0ae1..57b2ef62e5 100644
--- a/keyboards/gh60/Makefile
+++ b/keyboards/gh60/Makefile
@@ -1,74 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-# CONSOLE_ENABLE ?= yes # Console for debug(+400)
-# COMMAND_ENABLE ?= yes # Commands for debug and configuration
-KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-# MIDI_ENABLE ?= YES # MIDI controls
-# UNICODE_ENABLE ?= YES # Unicode
-# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-
-
-ifndef QUANTUM_DIR
- include ../../Makefile
-endif
-
+ifndef MAKEFILE_INCLUDED
+ include ../../Makefile
+endif
diff --git a/keyboards/gh60/config.h b/keyboards/gh60/config.h
index 4813c4e786..97753bc069 100644
--- a/keyboards/gh60/config.h
+++ b/keyboards/gh60/config.h
@@ -1,161 +1,161 @@
-/*
-Copyright 2012 Jun Wako <wakojun@gmail.com>
-
-This program is free software: you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation, either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program. If not, see <http://www.gnu.org/licenses/>.
-*/
-
-#ifndef CONFIG_H
-#define CONFIG_H
-
-#include "config_common.h"
-
-/* USB Device descriptor parameter */
-#define VENDOR_ID 0xFEED
-#define PRODUCT_ID 0x6060
-#define DEVICE_VER 0x0001
-#define MANUFACTURER geekhack
-#define PRODUCT GH60
-#define DESCRIPTION t.m.k. keyboard firmware for GH60
-
-/* key matrix size */
-#define MATRIX_ROWS 5
-#define MATRIX_COLS 14
-
-/*
- * Keyboard Matrix Assignments
- *
- * Change this to how you wired your keyboard
- * COLS: AVR pins used for columns, left to right
- * ROWS: AVR pins used for rows, top to bottom
- * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
- * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
- *
-*/
- #define MATRIX_ROW_PINS { D0, D1, D2, D3, D5 }
-// Rev A
-// #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B0, B5, B4, D7, D6, B3 }
-// Rev B/C
- #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B7, B5, B4, D7, D6, B3 }
-#define UNUSED_PINS
-
-/* COL2ROW or ROW2COL */
-#define DIODE_DIRECTION COL2ROW
-
-/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
-#define DEBOUNCING_DELAY 5
-
-/* define if matrix has ghost (lacks anti-ghosting diodes) */
-//#define MATRIX_HAS_GHOST
-
-/* number of backlight levels */
-#define BACKLIGHT_LEVELS 3
-
-/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
-#define LOCKING_SUPPORT_ENABLE
-/* Locking resynchronize hack */
-#define LOCKING_RESYNC_ENABLE
-
-/*
- * Force NKRO
- *
- * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
- * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
- * makefile for this to work.)
- *
- * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
- * until the next keyboard reset.
- *
- * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
- * fully operational during normal computer usage.
- *
- * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
- * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
- * bootmagic, NKRO mode will always be enabled until it is toggled again during a
- * power-up.
- *
- */
-//#define FORCE_NKRO
-
-/*
- * Magic Key Options
- *
- * Magic keys are hotkey commands that allow control over firmware functions of
- * the keyboard. They are best used in combination with the HID Listen program,
- * found here: https://www.pjrc.com/teensy/hid_listen.html
- *
- * The options below allow the magic key functionality to be changed. This is
- * useful if your keyboard/keypad is missing keys and you want magic key support.
- *
- */
-
-/* key combination for magic key command */
-#define IS_COMMAND() ( \
- keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
-)
-
-/* control how magic key switches layers */
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS true
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS true
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM false
-
-/* override magic key keymap */
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM
-//#define MAGIC_KEY_HELP1 H
-//#define MAGIC_KEY_HELP2 SLASH
-//#define MAGIC_KEY_DEBUG D
-//#define MAGIC_KEY_DEBUG_MATRIX X
-//#define MAGIC_KEY_DEBUG_KBD K
-//#define MAGIC_KEY_DEBUG_MOUSE M
-//#define MAGIC_KEY_VERSION V
-//#define MAGIC_KEY_STATUS S
-//#define MAGIC_KEY_CONSOLE C
-//#define MAGIC_KEY_LAYER0_ALT1 ESC
-//#define MAGIC_KEY_LAYER0_ALT2 GRAVE
-//#define MAGIC_KEY_LAYER0 0
-//#define MAGIC_KEY_LAYER1 1
-//#define MAGIC_KEY_LAYER2 2
-//#define MAGIC_KEY_LAYER3 3
-//#define MAGIC_KEY_LAYER4 4
-//#define MAGIC_KEY_LAYER5 5
-//#define MAGIC_KEY_LAYER6 6
-//#define MAGIC_KEY_LAYER7 7
-//#define MAGIC_KEY_LAYER8 8
-//#define MAGIC_KEY_LAYER9 9
-//#define MAGIC_KEY_BOOTLOADER PAUSE
-//#define MAGIC_KEY_LOCK CAPS
-//#define MAGIC_KEY_EEPROM E
-//#define MAGIC_KEY_NKRO N
-//#define MAGIC_KEY_SLEEP_LED Z
-
-/*
- * Feature disable options
- * These options are also useful to firmware size reduction.
- */
-
-/* disable debug print */
-//#define NO_DEBUG
-
-/* disable print */
-//#define NO_PRINT
-
-/* disable action features */
-//#define NO_ACTION_LAYER
-//#define NO_ACTION_TAPPING
-//#define NO_ACTION_ONESHOT
-//#define NO_ACTION_MACRO
-//#define NO_ACTION_FUNCTION
-
-#endif
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0xFEED
+#define PRODUCT_ID 0x6060
+#define DEVICE_VER 0x0001
+#define MANUFACTURER geekhack
+#define PRODUCT GH60
+#define DESCRIPTION t.m.k. keyboard firmware for GH60
+
+/* key matrix size */
+#define MATRIX_ROWS 5
+#define MATRIX_COLS 14
+
+/*
+ * Keyboard Matrix Assignments
+ *
+ * Change this to how you wired your keyboard
+ * COLS: AVR pins used for columns, left to right
+ * ROWS: AVR pins used for rows, top to bottom
+ * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
+ * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
+ *
+*/
+ #define MATRIX_ROW_PINS { D0, D1, D2, D3, D5 }
+// Rev A
+// #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B0, B5, B4, D7, D6, B3 }
+// Rev B/C
+ #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B7, B5, B4, D7, D6, B3 }
+#define UNUSED_PINS
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
+#define DEBOUNCING_DELAY 5
+
+/* define if matrix has ghost (lacks anti-ghosting diodes) */
+//#define MATRIX_HAS_GHOST
+
+/* number of backlight levels */
+#define BACKLIGHT_LEVELS 3
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+/*
+ * Force NKRO
+ *
+ * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
+ * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
+ * makefile for this to work.)
+ *
+ * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
+ * until the next keyboard reset.
+ *
+ * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
+ * fully operational during normal computer usage.
+ *
+ * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
+ * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
+ * bootmagic, NKRO mode will always be enabled until it is toggled again during a
+ * power-up.
+ *
+ */
+//#define FORCE_NKRO
+
+/*
+ * Magic Key Options
+ *
+ * Magic keys are hotkey commands that allow control over firmware functions of
+ * the keyboard. They are best used in combination with the HID Listen program,
+ * found here: https://www.pjrc.com/teensy/hid_listen.html
+ *
+ * The options below allow the magic key functionality to be changed. This is
+ * useful if your keyboard/keypad is missing keys and you want magic key support.
+ *
+ */
+
+/* key combination for magic key command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
+)
+
+/* control how magic key switches layers */
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS true
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS true
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM false
+
+/* override magic key keymap */
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM
+//#define MAGIC_KEY_HELP1 H
+//#define MAGIC_KEY_HELP2 SLASH
+//#define MAGIC_KEY_DEBUG D
+//#define MAGIC_KEY_DEBUG_MATRIX X
+//#define MAGIC_KEY_DEBUG_KBD K
+//#define MAGIC_KEY_DEBUG_MOUSE M
+//#define MAGIC_KEY_VERSION V
+//#define MAGIC_KEY_STATUS S
+//#define MAGIC_KEY_CONSOLE C
+//#define MAGIC_KEY_LAYER0_ALT1 ESC
+//#define MAGIC_KEY_LAYER0_ALT2 GRAVE
+//#define MAGIC_KEY_LAYER0 0
+//#define MAGIC_KEY_LAYER1 1
+//#define MAGIC_KEY_LAYER2 2
+//#define MAGIC_KEY_LAYER3 3
+//#define MAGIC_KEY_LAYER4 4
+//#define MAGIC_KEY_LAYER5 5
+//#define MAGIC_KEY_LAYER6 6
+//#define MAGIC_KEY_LAYER7 7
+//#define MAGIC_KEY_LAYER8 8
+//#define MAGIC_KEY_LAYER9 9
+//#define MAGIC_KEY_BOOTLOADER PAUSE
+//#define MAGIC_KEY_LOCK CAPS
+//#define MAGIC_KEY_EEPROM E
+//#define MAGIC_KEY_NKRO N
+//#define MAGIC_KEY_SLEEP_LED Z
+
+/*
+ * Feature disable options
+ * These options are also useful to firmware size reduction.
+ */
+
+/* disable debug print */
+//#define NO_DEBUG
+
+/* disable print */
+//#define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
+
+#endif
diff --git a/keyboards/gh60/gh60.c b/keyboards/gh60/gh60.c
index 255d87de99..f5a158e12f 100644
--- a/keyboards/gh60/gh60.c
+++ b/keyboards/gh60/gh60.c
@@ -1,25 +1,25 @@
-#include "gh60.h"
-
-void led_set_kb(uint8_t usb_led) {
- // put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
-
- if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
- gh60_caps_led_on();
- } else {
- gh60_caps_led_off();
- }
-
- // if (usb_led & (1<<USB_LED_NUM_LOCK)) {
- // gh60_esc_led_on();
- // } else {
- // gh60_esc_led_off();
- // }
-
- // if (usb_led & (1<<USB_LED_SCROLL_LOCK)) {
- // gh60_fn_led_on();
- // } else {
- // gh60_fn_led_off();
- // }
-
- led_set_user(usb_led);
-}
+#include "gh60.h"
+
+void led_set_kb(uint8_t usb_led) {
+ // put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
+
+ if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
+ gh60_caps_led_on();
+ } else {
+ gh60_caps_led_off();
+ }
+
+ // if (usb_led & (1<<USB_LED_NUM_LOCK)) {
+ // gh60_esc_led_on();
+ // } else {
+ // gh60_esc_led_off();
+ // }
+
+ // if (usb_led & (1<<USB_LED_SCROLL_LOCK)) {
+ // gh60_fn_led_on();
+ // } else {
+ // gh60_fn_led_off();
+ // }
+
+ led_set_user(usb_led);
+}
diff --git a/keyboards/gh60/gh60.h b/keyboards/gh60/gh60.h
index ca30562a44..82624b6148 100644
--- a/keyboards/gh60/gh60.h
+++ b/keyboards/gh60/gh60.h
@@ -1,74 +1,74 @@
-#ifndef GH60_H
-#define GH60_H
-
-#include "quantum.h"
-#include "led.h"
-
-/* GH60 LEDs
- * GPIO pads
- * 0 F7 WASD LEDs
- * 1 F6 ESC LED
- * 2 F5 FN LED
- * 3 F4 POKER Arrow LEDs
- * B2 Capslock LED
- * B0 not connected
- */
-inline void gh60_caps_led_on(void) { DDRB |= (1<<2); PORTB &= ~(1<<2); }
-inline void gh60_poker_leds_on(void) { DDRF |= (1<<4); PORTF &= ~(1<<4); }
-inline void gh60_fn_led_on(void) { DDRF |= (1<<5); PORTF &= ~(1<<5); }
-inline void gh60_esc_led_on(void) { DDRF |= (1<<6); PORTF &= ~(1<<6); }
-inline void gh60_wasd_leds_on(void) { DDRF |= (1<<7); PORTF &= ~(1<<7); }
-
-inline void gh60_caps_led_off(void) { DDRB &= ~(1<<2); PORTB &= ~(1<<2); }
-inline void gh60_poker_leds_off(void) { DDRF &= ~(1<<4); PORTF &= ~(1<<4); }
-inline void gh60_fn_led_off(void) { DDRF &= ~(1<<5); PORTF &= ~(1<<5); }
-inline void gh60_esc_led_off(void) { DDRF &= ~(1<<6); PORTF &= ~(1<<6); }
-inline void gh60_wasd_leds_off(void) { DDRF &= ~(1<<7); PORTF &= ~(1<<7); }
-
-/* GH60 keymap definition macro
- * K2C, K31 and K3C are extra keys for ISO
- */
-#define KEYMAP( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, \
- K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
- K40, K41, K42, K45, K49, K4A, K4B, K4C, K4D \
-) { \
- { KC_##K00, KC_##K01, KC_##K02, KC_##K03, KC_##K04, KC_##K05, KC_##K06, KC_##K07, KC_##K08, KC_##K09, KC_##K0A, KC_##K0B, KC_##K0C, KC_##K0D }, \
- { KC_##K10, KC_##K11, KC_##K12, KC_##K13, KC_##K14, KC_##K15, KC_##K16, KC_##K17, KC_##K18, KC_##K19, KC_##K1A, KC_##K1B, KC_##K1C, KC_##K1D }, \
- { KC_##K20, KC_##K21, KC_##K22, KC_##K23, KC_##K24, KC_##K25, KC_##K26, KC_##K27, KC_##K28, KC_##K29, KC_##K2A, KC_##K2B, KC_##K2C, KC_##K2D }, \
- { KC_##K30, KC_##K31, KC_##K32, KC_##K33, KC_##K34, KC_##K35, KC_##K36, KC_##K37, KC_##K38, KC_##K39, KC_##K3A, KC_##K3B, KC_##K3C, KC_##K3D }, \
- { KC_##K40, KC_##K41, KC_##K42, KC_NO, KC_NO, KC_##K45, KC_NO, KC_NO, KC_NO, KC_##K49, KC_##K4A, KC_##K4B, KC_##K4C, KC_##K4D } \
-}
-
-/* ANSI valiant. No extra keys for ISO */
-#define KEYMAP_ANSI( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, \
- K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, \
- K40, K41, K42, K45, K4A, K4B, K4C, K4D \
-) KEYMAP( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, NO, K2D, \
- K30, NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, NO, K3D, \
- K40, K41, K42, K45, NO, K4A, K4B, K4C, K4D \
-)
-
-#define KEYMAP_HHKB( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K49,\
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, \
- K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, K3C, \
- K40, K41, K42, K45, K4A, K4B, K4C, K4D \
-) KEYMAP( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, NO, K2D, \
- K30, NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
- K40, K41, K42, K45, K49, K4A, K4B, K4C, K4D \
-)
-
-#endif
+#ifndef GH60_H
+#define GH60_H
+
+#include "quantum.h"
+#include "led.h"
+
+/* GH60 LEDs
+ * GPIO pads
+ * 0 F7 WASD LEDs
+ * 1 F6 ESC LED
+ * 2 F5 FN LED
+ * 3 F4 POKER Arrow LEDs
+ * B2 Capslock LED
+ * B0 not connected
+ */
+inline void gh60_caps_led_on(void) { DDRB |= (1<<2); PORTB &= ~(1<<2); }
+inline void gh60_poker_leds_on(void) { DDRF |= (1<<4); PORTF &= ~(1<<4); }
+inline void gh60_fn_led_on(void) { DDRF |= (1<<5); PORTF &= ~(1<<5); }
+inline void gh60_esc_led_on(void) { DDRF |= (1<<6); PORTF &= ~(1<<6); }
+inline void gh60_wasd_leds_on(void) { DDRF |= (1<<7); PORTF &= ~(1<<7); }
+
+inline void gh60_caps_led_off(void) { DDRB &= ~(1<<2); PORTB &= ~(1<<2); }
+inline void gh60_poker_leds_off(void) { DDRF &= ~(1<<4); PORTF &= ~(1<<4); }
+inline void gh60_fn_led_off(void) { DDRF &= ~(1<<5); PORTF &= ~(1<<5); }
+inline void gh60_esc_led_off(void) { DDRF &= ~(1<<6); PORTF &= ~(1<<6); }
+inline void gh60_wasd_leds_off(void) { DDRF &= ~(1<<7); PORTF &= ~(1<<7); }
+
+/* GH60 keymap definition macro
+ * K2C, K31 and K3C are extra keys for ISO
+ */
+#define KEYMAP( \
+ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
+ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
+ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, \
+ K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
+ K40, K41, K42, K45, K49, K4A, K4B, K4C, K4D \
+) { \
+ { KC_##K00, KC_##K01, KC_##K02, KC_##K03, KC_##K04, KC_##K05, KC_##K06, KC_##K07, KC_##K08, KC_##K09, KC_##K0A, KC_##K0B, KC_##K0C, KC_##K0D }, \
+ { KC_##K10, KC_##K11, KC_##K12, KC_##K13, KC_##K14, KC_##K15, KC_##K16, KC_##K17, KC_##K18, KC_##K19, KC_##K1A, KC_##K1B, KC_##K1C, KC_##K1D }, \
+ { KC_##K20, KC_##K21, KC_##K22, KC_##K23, KC_##K24, KC_##K25, KC_##K26, KC_##K27, KC_##K28, KC_##K29, KC_##K2A, KC_##K2B, KC_##K2C, KC_##K2D }, \
+ { KC_##K30, KC_##K31, KC_##K32, KC_##K33, KC_##K34, KC_##K35, KC_##K36, KC_##K37, KC_##K38, KC_##K39, KC_##K3A, KC_##K3B, KC_##K3C, KC_##K3D }, \
+ { KC_##K40, KC_##K41, KC_##K42, KC_NO, KC_NO, KC_##K45, KC_NO, KC_NO, KC_NO, KC_##K49, KC_##K4A, KC_##K4B, KC_##K4C, KC_##K4D } \
+}
+
+/* ANSI valiant. No extra keys for ISO */
+#define KEYMAP_ANSI( \
+ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
+ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
+ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, \
+ K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, \
+ K40, K41, K42, K45, K4A, K4B, K4C, K4D \
+) KEYMAP( \
+ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
+ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
+ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, NO, K2D, \
+ K30, NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, NO, K3D, \
+ K40, K41, K42, K45, NO, K4A, K4B, K4C, K4D \
+)
+
+#define KEYMAP_HHKB( \
+ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K49,\
+ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
+ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, \
+ K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, K3C, \
+ K40, K41, K42, K45, K4A, K4B, K4C, K4D \
+) KEYMAP( \
+ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
+ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
+ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, NO, K2D, \
+ K30, NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
+ K40, K41, K42, K45, K49, K4A, K4B, K4C, K4D \
+)
+
+#endif
diff --git a/keyboards/gh60/keymaps/robotmaxtron/Makefile b/keyboards/gh60/keymaps/robotmaxtron/Makefile
index 2e69aee298..c73cf11417 100644
--- a/keyboards/gh60/keymaps/robotmaxtron/Makefile
+++ b/keyboards/gh60/keymaps/robotmaxtron/Makefile
@@ -1,112 +1,112 @@
-#----------------------------------------------------------------------------
-# On command line:
-#
-# make all = Make software.
-#
-# make clean = Clean out built project files.
-#
-# make coff = Convert ELF to AVR COFF.
-#
-# make extcoff = Convert ELF to AVR Extended COFF.
-#
-# make program = Download the hex file to the device.
-# Please customize your programmer settings(PROGRAM_CMD)
-#
-# make teensy = Download the hex file to the device, using teensy_loader_cli.
-# (must have teensy_loader_cli installed).
-#
-# make dfu = Download the hex file to the device, using dfu-programmer (must
-# have dfu-programmer installed).
-#
-# make flip = Download the hex file to the device, using Atmel FLIP (must
-# have Atmel FLIP installed).
-#
-# make dfu-ee = Download the eeprom file to the device, using dfu-programmer
-# (must have dfu-programmer installed).
-#
-# make flip-ee = Download the eeprom file to the device, using Atmel FLIP
-# (must have Atmel FLIP installed).
-#
-# make debug = Start either simulavr or avarice as specified for debugging,
-# with avr-gdb or avr-insight as the front end for debugging.
-#
-# make filename.s = Just compile filename.c into the assembler code only.
-#
-# make filename.i = Create a preprocessed source file for use in submitting
-# bug reports to the GCC project.
-#
-# To rebuild project do "make clean" then "make all".
-#----------------------------------------------------------------------------
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-# CONSOLE_ENABLE ?= yes # Console for debug(+400)
-# COMMAND_ENABLE ?= yes # Commands for debug and configuration
-KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-# MIDI_ENABLE ?= YES # MIDI controls
-# UNICODE_ENABLE ?= YES # Unicode
-# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-RGBLIGHT_ENABLE ?= yes # Enable RGB Underglow
-
-ifndef QUANTUM_DIR
- include ../../../../Makefile
-endif
-
+#----------------------------------------------------------------------------
+# On command line:
+#
+# make all = Make software.
+#
+# make clean = Clean out built project files.
+#
+# make coff = Convert ELF to AVR COFF.
+#
+# make extcoff = Convert ELF to AVR Extended COFF.
+#
+# make program = Download the hex file to the device.
+# Please customize your programmer settings(PROGRAM_CMD)
+#
+# make teensy = Download the hex file to the device, using teensy_loader_cli.
+# (must have teensy_loader_cli installed).
+#
+# make dfu = Download the hex file to the device, using dfu-programmer (must
+# have dfu-programmer installed).
+#
+# make flip = Download the hex file to the device, using Atmel FLIP (must
+# have Atmel FLIP installed).
+#
+# make dfu-ee = Download the eeprom file to the device, using dfu-programmer
+# (must have dfu-programmer installed).
+#
+# make flip-ee = Download the eeprom file to the device, using Atmel FLIP
+# (must have Atmel FLIP installed).
+#
+# make debug = Start either simulavr or avarice as specified for debugging,
+# with avr-gdb or avr-insight as the front end for debugging.
+#
+# make filename.s = Just compile filename.c into the assembler code only.
+#
+# make filename.i = Create a preprocessed source file for use in submitting
+# bug reports to the GCC project.
+#
+# To rebuild project do "make clean" then "make all".
+#----------------------------------------------------------------------------
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+# CONSOLE_ENABLE ?= yes # Console for debug(+400)
+# COMMAND_ENABLE ?= yes # Commands for debug and configuration
+KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+# MIDI_ENABLE ?= YES # MIDI controls
+# UNICODE_ENABLE ?= YES # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= yes # Enable RGB Underglow
+
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif
+
diff --git a/keyboards/gh60/keymaps/robotmaxtron/config.h b/keyboards/gh60/keymaps/robotmaxtron/config.h
index 8272875ed0..6a29e6b8c2 100644
--- a/keyboards/gh60/keymaps/robotmaxtron/config.h
+++ b/keyboards/gh60/keymaps/robotmaxtron/config.h
@@ -1,190 +1,190 @@
-/*
-Copyright 2012 Jun Wako <wakojun@gmail.com>
-
-This program is free software: you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation, either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program. If not, see <http://www.gnu.org/licenses/>.
-*/
-
-#ifndef CONFIG_H
-#define CONFIG_H
-
-#include "config_common.h"
-
-/* USB Device descriptor parameter */
-#define VENDOR_ID 0xFEED
-#define PRODUCT_ID 0x6060
-#define DEVICE_VER 0x0001
-#define MANUFACTURER geekhack
-#define PRODUCT GH60
-#define DESCRIPTION t.m.k. keyboard firmware for GH60
-
-/* key matrix size */
-#define MATRIX_ROWS 5
-#define MATRIX_COLS 14
-
-/*
- * Keyboard Matrix Assignments
- *
- * Change this to how you wired your keyboard
- * COLS: AVR pins used for columns, left to right
- * ROWS: AVR pins used for rows, top to bottom
- * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
- * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
- *
-*/
- #define MATRIX_ROW_PINS { D0, D1, D2, D3, D5 }
-// Rev A
-// #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B0, B5, B4, D7, D6, B3 }
-// Rev B/C
- #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B7, B5, B4, D7, D6, B3 }
-#define UNUSED_PINS
-
-/* COL2ROW or ROW2COL */
-#define DIODE_DIRECTION COL2ROW
-
-/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
-#define DEBOUNCING_DELAY 5
-
-/* define if matrix has ghost (lacks anti-ghosting diodes) */
-//#define MATRIX_HAS_GHOST
-
-/* number of backlight levels */
-#define BACKLIGHT_LEVELS 3
-
-/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
-#define LOCKING_SUPPORT_ENABLE
-/* Locking resynchronize hack */
-#define LOCKING_RESYNC_ENABLE
-
-/*
- * Force NKRO
- *
- * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
- * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
- * makefile for this to work.)
- *
- * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
- * until the next keyboard reset.
- *
- * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
- * fully operational during normal computer usage.
- *
- * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
- * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
- * bootmagic, NKRO mode will always be enabled until it is toggled again during a
- * power-up.
- *
- */
-//#define FORCE_NKRO
-
-/*
- * Magic Key Options
- *
- * Magic keys are hotkey commands that allow control over firmware functions of
- * the keyboard. They are best used in combination with the HID Listen program,
- * found here: https://www.pjrc.com/teensy/hid_listen.html
- *
- * The options below allow the magic key functionality to be changed. This is
- * useful if your keyboard/keypad is missing keys and you want magic key support.
- *
- */
-
-/* key combination for magic key command */
-#define IS_COMMAND() ( \
- keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
-)
-
-/* control how magic key switches layers */
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS true
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS true
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM false
-
-/* override magic key keymap */
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS
-//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM
-//#define MAGIC_KEY_HELP1 H
-//#define MAGIC_KEY_HELP2 SLASH
-//#define MAGIC_KEY_DEBUG D
-//#define MAGIC_KEY_DEBUG_MATRIX X
-//#define MAGIC_KEY_DEBUG_KBD K
-//#define MAGIC_KEY_DEBUG_MOUSE M
-//#define MAGIC_KEY_VERSION V
-//#define MAGIC_KEY_STATUS S
-//#define MAGIC_KEY_CONSOLE C
-//#define MAGIC_KEY_LAYER0_ALT1 ESC
-//#define MAGIC_KEY_LAYER0_ALT2 GRAVE
-//#define MAGIC_KEY_LAYER0 0
-//#define MAGIC_KEY_LAYER1 1
-//#define MAGIC_KEY_LAYER2 2
-//#define MAGIC_KEY_LAYER3 3
-//#define MAGIC_KEY_LAYER4 4
-//#define MAGIC_KEY_LAYER5 5
-//#define MAGIC_KEY_LAYER6 6
-//#define MAGIC_KEY_LAYER7 7
-//#define MAGIC_KEY_LAYER8 8
-//#define MAGIC_KEY_LAYER9 9
-//#define MAGIC_KEY_BOOTLOADER PAUSE
-//#define MAGIC_KEY_LOCK CAPS
-//#define MAGIC_KEY_EEPROM E
-//#define MAGIC_KEY_NKRO N
-//#define MAGIC_KEY_SLEEP_LED Z
-
-/*
- * Feature disable options
- * These options are also useful to firmware size reduction.
- */
-
-/* disable debug print */
-//#define NO_DEBUG
-
-/* disable print */
-//#define NO_PRINT
-
-/* disable action features */
-//#define NO_ACTION_LAYER
-//#define NO_ACTION_TAPPING
-//#define NO_ACTION_ONESHOT
-//#define NO_ACTION_MACRO
-//#define NO_ACTION_FUNCTION
-
-/*
- * RGB Underglow
- * These settings are for the F4 by default:
- *
- *
- * #define ws2812_PORTREG PORTF
- * #define ws2812_DDRREG DDRF
- * #define ws2812_pin PF4
- * #define RGBLED_NUM 14 // Number of LEDs
- * #define RGBLIGHT_HUE_STEP 10
- * #define RGBLIGHT_SAT_STEP 17
- * #define RGBLIGHT_VAL_STEP 17
- *
- * The firmware supports 5 different light effects, and the color (hue, saturation, brightness) can be customized in most effects.
- * To control the underglow, you need to modify your keymap file to assign those functions to some keys/key combinations.
- * For details, please check this keymap. keyboard/planck/keymaps/yang/keymap.c
-*/
-
-/* Deprecated code below
-#define ws2812_PORTREG PORTF
-#define ws2812_DDRREG DDRF
-#define ws2812_pin PF4
-*/
-#define RGB_DI_PIN F4
-#define RGBLIGHT_TIMER
-#define RGBLED_NUM 8 // Number of LEDs
-#define RGBLIGHT_HUE_STEP 8
-#define RGBLIGHT_SAT_STEP 8
-#define RGBLIGHT_VAL_STEP 8
-#endif
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0xFEED
+#define PRODUCT_ID 0x6060
+#define DEVICE_VER 0x0001
+#define MANUFACTURER geekhack
+#define PRODUCT GH60
+#define DESCRIPTION t.m.k. keyboard firmware for GH60
+
+/* key matrix size */
+#define MATRIX_ROWS 5
+#define MATRIX_COLS 14
+
+/*
+ * Keyboard Matrix Assignments
+ *
+ * Change this to how you wired your keyboard
+ * COLS: AVR pins used for columns, left to right
+ * ROWS: AVR pins used for rows, top to bottom
+ * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
+ * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
+ *
+*/
+ #define MATRIX_ROW_PINS { D0, D1, D2, D3, D5 }
+// Rev A
+// #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B0, B5, B4, D7, D6, B3 }
+// Rev B/C
+ #define MATRIX_COL_PINS { F0, F1, E6, C7, C6, B6, D4, B1, B7, B5, B4, D7, D6, B3 }
+#define UNUSED_PINS
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
+#define DEBOUNCING_DELAY 5
+
+/* define if matrix has ghost (lacks anti-ghosting diodes) */
+//#define MATRIX_HAS_GHOST
+
+/* number of backlight levels */
+#define BACKLIGHT_LEVELS 3
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+/*
+ * Force NKRO
+ *
+ * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
+ * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
+ * makefile for this to work.)
+ *
+ * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
+ * until the next keyboard reset.
+ *
+ * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
+ * fully operational during normal computer usage.
+ *
+ * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
+ * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
+ * bootmagic, NKRO mode will always be enabled until it is toggled again during a
+ * power-up.
+ *
+ */
+//#define FORCE_NKRO
+
+/*
+ * Magic Key Options
+ *
+ * Magic keys are hotkey commands that allow control over firmware functions of
+ * the keyboard. They are best used in combination with the HID Listen program,
+ * found here: https://www.pjrc.com/teensy/hid_listen.html
+ *
+ * The options below allow the magic key functionality to be changed. This is
+ * useful if your keyboard/keypad is missing keys and you want magic key support.
+ *
+ */
+
+/* key combination for magic key command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
+)
+
+/* control how magic key switches layers */
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS true
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS true
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM false
+
+/* override magic key keymap */
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS
+//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM
+//#define MAGIC_KEY_HELP1 H
+//#define MAGIC_KEY_HELP2 SLASH
+//#define MAGIC_KEY_DEBUG D
+//#define MAGIC_KEY_DEBUG_MATRIX X
+//#define MAGIC_KEY_DEBUG_KBD K
+//#define MAGIC_KEY_DEBUG_MOUSE M
+//#define MAGIC_KEY_VERSION V
+//#define MAGIC_KEY_STATUS S
+//#define MAGIC_KEY_CONSOLE C
+//#define MAGIC_KEY_LAYER0_ALT1 ESC
+//#define MAGIC_KEY_LAYER0_ALT2 GRAVE
+//#define MAGIC_KEY_LAYER0 0
+//#define MAGIC_KEY_LAYER1 1
+//#define MAGIC_KEY_LAYER2 2
+//#define MAGIC_KEY_LAYER3 3
+//#define MAGIC_KEY_LAYER4 4
+//#define MAGIC_KEY_LAYER5 5
+//#define MAGIC_KEY_LAYER6 6
+//#define MAGIC_KEY_LAYER7 7
+//#define MAGIC_KEY_LAYER8 8
+//#define MAGIC_KEY_LAYER9 9
+//#define MAGIC_KEY_BOOTLOADER PAUSE
+//#define MAGIC_KEY_LOCK CAPS
+//#define MAGIC_KEY_EEPROM E
+//#define MAGIC_KEY_NKRO N
+//#define MAGIC_KEY_SLEEP_LED Z
+
+/*
+ * Feature disable options
+ * These options are also useful to firmware size reduction.
+ */
+
+/* disable debug print */
+//#define NO_DEBUG
+
+/* disable print */
+//#define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
+
+/*
+ * RGB Underglow
+ * These settings are for the F4 by default:
+ *
+ *
+ * #define ws2812_PORTREG PORTF
+ * #define ws2812_DDRREG DDRF
+ * #define ws2812_pin PF4
+ * #define RGBLED_NUM 14 // Number of LEDs
+ * #define RGBLIGHT_HUE_STEP 10
+ * #define RGBLIGHT_SAT_STEP 17
+ * #define RGBLIGHT_VAL_STEP 17
+ *
+ * The firmware supports 5 different light effects, and the color (hue, saturation, brightness) can be customized in most effects.
+ * To control the underglow, you need to modify your keymap file to assign those functions to some keys/key combinations.
+ * For details, please check this keymap. keyboard/planck/keymaps/yang/keymap.c
+*/
+
+/* Deprecated code below
+#define ws2812_PORTREG PORTF
+#define ws2812_DDRREG DDRF
+#define ws2812_pin PF4
+*/
+#define RGB_DI_PIN F4
+#define RGBLIGHT_TIMER
+#define RGBLED_NUM 8 // Number of LEDs
+#define RGBLIGHT_HUE_STEP 8
+#define RGBLIGHT_SAT_STEP 8
+#define RGBLIGHT_VAL_STEP 8
+#endif
diff --git a/keyboards/gh60/pinout.txt b/keyboards/gh60/pinout.txt
index 3787f938e7..e9bf1983a5 100644
--- a/keyboards/gh60/pinout.txt
+++ b/keyboards/gh60/pinout.txt
@@ -1,18 +1,18 @@
- /* Column pin configuration
- * col: 0 1 2 3 4 5 6 7 8 9 10 11 12 13
- * pin: F0 F1 E6 C7 C6 B6 D4 B1 B7 B5 B4 D7 D6 B3 (Rev.C)
- */
-
- /* Row pin configuration
- * row: 0 1 2 3 4
- * pin: D0 D1 D2 D3 D5
- */
-
- GPIO pads
- 0 F7 WASD LEDs
- 1 F6 ESC LED
- 2 F5 FN LED
- 3 F4 POKER Arrow LEDs
-
- B2 Capslock LED
+ /* Column pin configuration
+ * col: 0 1 2 3 4 5 6 7 8 9 10 11 12 13
+ * pin: F0 F1 E6 C7 C6 B6 D4 B1 B7 B5 B4 D7 D6 B3 (Rev.C)
+ */
+
+ /* Row pin configuration
+ * row: 0 1 2 3 4
+ * pin: D0 D1 D2 D3 D5
+ */
+
+ GPIO pads
+ 0 F7 WASD LEDs
+ 1 F6 ESC LED
+ 2 F5 FN LED
+ 3 F4 POKER Arrow LEDs
+
+ B2 Capslock LED
B0 not connected \ No newline at end of file
diff --git a/keyboards/gh60/readme.md b/keyboards/gh60/readme.md
index 92302d507c..8c744bfd3c 100644
--- a/keyboards/gh60/readme.md
+++ b/keyboards/gh60/readme.md
@@ -1,60 +1,62 @@
-## gh60 Rev C keyboard firmware
-
-![gh60 Rev C PCB](gh60revc.jpg)
-
- /* Column pin configuration
- * col: 0 1 2 3 4 5 6 7 8 9 10 11 12 13
- * pin: F0 F1 E6 C7 C6 B6 D4 B1 B7 B5 B4 D7 D6 B3 (Rev.C)
- */
-
- /* Row pin configuration
- * row: 0 1 2 3 4
- * pin: D0 D1 D2 D3 D5
- */
-
- GPIO pads
- 0 F7 WASD LEDs
- 1 F6 ESC LED
- 2 F5 FN LED
- 3 F4 POKER Arrow LEDs
-
- B2 Capslock LED
- B0 not connected
-
-Functions to controls LED clusters
-
- gh60_caps_led_on()
- gh60_poker_leds_on()
- gh60_fn_led_on()
- gh60_esc_led_on()
- gh60_wasd_leds_on()
-
- gh60_caps_led_off()
- gh60_poker_leds_off()
- gh60_fn_led_off()
- gh60_esc_led_off()
- gh60_wasd_leds_off()
-
-======================
-
-## Quantum MK Firmware
-
-For the full Quantum feature list, see [the parent readme.md](/readme.md).
-
-## Building
-
-Download or clone the whole firmware and navigate to the keyboards/gh60_rev_c folder. Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Teensy Loader to program your .hex file.
-
-Depending on which keymap you would like to use, you will have to compile slightly differently.
-
-### Default
-To build with the default keymap, simply run `make`.
-
-### Other Keymaps
-Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document (you can find in top readme.md) and existent keymap files.
-
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
-```
-$ make KEYMAP=[default|jack|<name>]
-```
-Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
+## gh60 Rev C keyboard firmware
+
+![gh60 Rev C PCB](gh60revc.jpg)
+
+ /* Column pin configuration
+ * col: 0 1 2 3 4 5 6 7 8 9 10 11 12 13
+ * pin: F0 F1 E6 C7 C6 B6 D4 B1 B7 B5 B4 D7 D6 B3 (Rev.C)
+ */
+
+ /* Row pin configuration
+ * row: 0 1 2 3 4
+ * pin: D0 D1 D2 D3 D5
+ */
+
+ GPIO pads
+ 0 F7 WASD LEDs
+ 1 F6 ESC LED
+ 2 F5 FN LED
+ 3 F4 POKER Arrow LEDs
+
+ B2 Capslock LED
+ B0 not connected
+
+Functions to controls LED clusters
+
+ gh60_caps_led_on()
+ gh60_poker_leds_on()
+ gh60_fn_led_on()
+ gh60_esc_led_on()
+ gh60_wasd_leds_on()
+
+ gh60_caps_led_off()
+ gh60_poker_leds_off()
+ gh60_fn_led_off()
+ gh60_esc_led_off()
+ gh60_wasd_leds_off()
+
+======================
+
+## Quantum MK Firmware
+
+For the full Quantum feature list, see [the parent readme.md](/readme.md).
+
+## Building
+
+Download or clone the whole firmware and navigate to the keyboards/gh60_rev_c folder. Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Teensy Loader to program your .hex file.
+
+Depending on which keymap you would like to use, you will have to compile slightly differently.
+
+### Default
+To build with the default keymap, simply run `make default`.
+
+### Other Keymaps
+Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document (you can find in top readme.md) and existent keymap files.
+
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
+```
+$ make [default|jack|<name>]
+```
+
+Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
diff --git a/keyboards/gh60/rules.mk b/keyboards/gh60/rules.mk
new file mode 100644
index 0000000000..aba680e45b
--- /dev/null
+++ b/keyboards/gh60/rules.mk
@@ -0,0 +1,66 @@
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+# CONSOLE_ENABLE ?= yes # Console for debug(+400)
+# COMMAND_ENABLE ?= yes # Commands for debug and configuration
+KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+# MIDI_ENABLE ?= YES # MIDI controls
+# UNICODE_ENABLE ?= YES # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
diff --git a/keyboards/handwired/CMD60/Makefile b/keyboards/handwired/CMD60/Makefile
index 7117599173..191c6bb664 100644
--- a/keyboards/handwired/CMD60/Makefile
+++ b/keyboards/handwired/CMD60/Makefile
@@ -1,73 +1,3 @@
-
-# MCU name
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=512
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
-
-
+endif \ No newline at end of file
diff --git a/keyboards/handwired/CMD60/rules.mk b/keyboards/handwired/CMD60/rules.mk
new file mode 100644
index 0000000000..7117599173
--- /dev/null
+++ b/keyboards/handwired/CMD60/rules.mk
@@ -0,0 +1,73 @@
+
+# MCU name
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=512
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
+
+
diff --git a/keyboards/handwired/Makefile b/keyboards/handwired/Makefile
index 57493a47ca..4e2a6f00fd 100644
--- a/keyboards/handwired/Makefile
+++ b/keyboards/handwired/Makefile
@@ -1,3 +1,3 @@
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/handwired/fivethirteen/Makefile b/keyboards/handwired/fivethirteen/Makefile
index 7117599173..191c6bb664 100644
--- a/keyboards/handwired/fivethirteen/Makefile
+++ b/keyboards/handwired/fivethirteen/Makefile
@@ -1,73 +1,3 @@
-
-# MCU name
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=512
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
-
-
+endif \ No newline at end of file
diff --git a/keyboards/handwired/fivethirteen/rules.mk b/keyboards/handwired/fivethirteen/rules.mk
new file mode 100644
index 0000000000..7117599173
--- /dev/null
+++ b/keyboards/handwired/fivethirteen/rules.mk
@@ -0,0 +1,73 @@
+
+# MCU name
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=512
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
+
+
diff --git a/keyboards/handwired/minorca/Makefile b/keyboards/handwired/minorca/Makefile
index 155c1f9a29..191c6bb664 100644
--- a/keyboards/handwired/minorca/Makefile
+++ b/keyboards/handwired/minorca/Makefile
@@ -1,71 +1,3 @@
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=512
-
-# Build Options
-# change to "no" to disable the options, or define them in the Makefile in
-# the appropriate keymap folder that will get included automatically
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no # Audio output on port C6
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-RGBLIGHT_ENABLE ?= yes # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
-
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/handwired/minorca/rules.mk b/keyboards/handwired/minorca/rules.mk
new file mode 100644
index 0000000000..c51371a781
--- /dev/null
+++ b/keyboards/handwired/minorca/rules.mk
@@ -0,0 +1,67 @@
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=512
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no # Audio output on port C6
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= yes # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend \ No newline at end of file
diff --git a/keyboards/handwired/onekey/Makefile b/keyboards/handwired/onekey/Makefile
index c6d10856a1..191c6bb664 100644
--- a/keyboards/handwired/onekey/Makefile
+++ b/keyboards/handwired/onekey/Makefile
@@ -1,65 +1,3 @@
-
-
-# MCU name
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-#SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
-#NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/handwired/onekey/rules.mk b/keyboards/handwired/onekey/rules.mk
new file mode 100644
index 0000000000..c6d10856a1
--- /dev/null
+++ b/keyboards/handwired/onekey/rules.mk
@@ -0,0 +1,65 @@
+
+
+# MCU name
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+#SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+#NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/handwired/retro_refit/Makefile b/keyboards/handwired/retro_refit/Makefile
new file mode 100644
index 0000000000..191c6bb664
--- /dev/null
+++ b/keyboards/handwired/retro_refit/Makefile
@@ -0,0 +1,3 @@
+ifndef MAKEFILE_INCLUDED
+ include ../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/retro_refit/config.h b/keyboards/handwired/retro_refit/config.h
index f2194e550c..f2194e550c 100644
--- a/keyboards/retro_refit/config.h
+++ b/keyboards/handwired/retro_refit/config.h
diff --git a/keyboards/retro_refit/keymaps/default/keymap.c b/keyboards/handwired/retro_refit/keymaps/default/keymap.c
index 405402d5e3..405402d5e3 100644
--- a/keyboards/retro_refit/keymaps/default/keymap.c
+++ b/keyboards/handwired/retro_refit/keymaps/default/keymap.c
diff --git a/keyboards/handwired/retro_refit/readme.md b/keyboards/handwired/retro_refit/readme.md
new file mode 100644
index 0000000000..9f10edf9fc
--- /dev/null
+++ b/keyboards/handwired/retro_refit/readme.md
@@ -0,0 +1,60 @@
+retro_refit keyboard firmware
+======================
+
+## Keyboard Info
+
+The retro refit keyboard used a Teensy to replace the original controller on a 386 "laptop".
+
+http://imgur.com/a/08Fyj
+
+This keyboard uses a KEYMAP macro that is a great example of using a non-standard row-column matrix. The keyboard in question had 11 rows and 8 columns, but the rows were not all horizontal, and the columns were not all vertical. For example, row 2 contained "Print Screen", "N", "M", ",", ".", "/", "Right Shift", and"Left Alt". Column 0 contained "F6", "7", "O", "'", "Q", "D", "B", "Left Alt", "Up Arrow", and "Down Arrow".
+
+The macro makes programming the keys easier and in a more straight-forward manner because it realigns the keys into a 6x15 sensible keyboard layout instead of the obtuse 11x8 matrix. Each Kxy corrisponds to a key in row x column y.
+
+```
+#define KEYMAP( \
+ K77, K05, K04, K03, K02, K01, K00, KA7, KA6, KA5, KA4, KA3, KA2, K11, K94, \
+ K27, K76, K75, K74, K73, K72, K71, K70, K67, K66, K65, K64, K63, K62, KA1, \
+ K61, K60, K57, K56, K55, K54, K53, K52, K51, K50, K47, K46, K45, K97, \
+ K43, K42, K41, K40, K37, K36, K35, K34, K33, K32, K31, K30, K44, K87, \
+ K26, K24, K23, K22, K21, K20, K17, K16, K15, K14, K13, K12, KA0, K91, \
+ K10, K06, K25, K07, K86, K85, K95, K90, K93 \
+) { \
+{ KC_##K00, KC_##K01, KC_##K02, KC_##K03, KC_##K04, KC_##K05, KC_##K06, KC_##K07, }, \
+{ KC_##K10, KC_##K11, KC_##K12, KC_##K13, KC_##K14, KC_##K15, KC_##K16, KC_##K17, }, \
+{ KC_##K20, KC_##K21, KC_##K22, KC_##K23, KC_##K24, KC_##K25, KC_##K26, KC_##K27, }, \
+{ KC_##K30, KC_##K31, KC_##K32, KC_##K33, KC_##K34, KC_##K35, KC_##K36, KC_##K37, }, \
+{ KC_##K40, KC_##K41, KC_##K42, KC_##K43, KC_##K44, KC_##K45, KC_##K46, KC_##K47, }, \
+{ KC_##K50, KC_##K51, KC_##K52, KC_##K53, KC_##K54, KC_##K55, KC_##K56, KC_##K57, }, \
+{ KC_##K60, KC_##K61, KC_##K62, KC_##K63, KC_##K64, KC_##K65, KC_##K66, KC_##K67, }, \
+{ KC_##K70, KC_##K71, KC_##K72, KC_##K73, KC_##K74, KC_##K75, KC_##K76, KC_##K77, }, \
+{ KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_##K85, KC_##K86, KC_##K87, }, \
+{ KC_##K90, KC_##K91, KC_NO, KC_##K93, KC_##K94, KC_##K95, KC_NO, KC_##K97, }, \
+{ KC_##KA0, KC_##KA1, KC_##KA2, KC_##KA3, KC_##KA4, KC_##KA5, KC_##KA6, KC_##KA7, } \
+}
+```
+
+
+## Quantum MK Firmware
+
+For the full Quantum feature list, see [the parent readme.md](/readme.md).
+
+## Building
+
+Download or clone the whole firmware and navigate to the keyboards/retro_refit folder. Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Teensy Loader to program your .hex file.
+
+Depending on which keymap you would like to use, you will have to compile slightly differently.
+
+### Default
+To build with the default keymap, simply run `make default`.
+
+### Other Keymaps
+Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` and see keymap document (you can find in top readme.md) and existent keymap files.
+
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
+```
+$ make [default|jack|<name>]
+```
+
+Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder. \ No newline at end of file
diff --git a/keyboards/retro_refit/retro_refit.c b/keyboards/handwired/retro_refit/retro_refit.c
index 3d610eba34..3d610eba34 100644
--- a/keyboards/retro_refit/retro_refit.c
+++ b/keyboards/handwired/retro_refit/retro_refit.c
diff --git a/keyboards/retro_refit/retro_refit.h b/keyboards/handwired/retro_refit/retro_refit.h
index 109acdc399..109acdc399 100644
--- a/keyboards/retro_refit/retro_refit.h
+++ b/keyboards/handwired/retro_refit/retro_refit.h
diff --git a/keyboards/retro_refit/Makefile b/keyboards/handwired/retro_refit/rules.mk
index 2dd8cc5f79..10fbfa5c9d 100644
--- a/keyboards/retro_refit/Makefile
+++ b/keyboards/handwired/retro_refit/rules.mk
@@ -66,9 +66,3 @@ NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https
# MIDI_ENABLE ?= YES # MIDI controls
# UNICODE_ENABLE ?= YES # Unicode
# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-
-
-ifndef QUANTUM_DIR
- include ../../Makefile
-endif
-
diff --git a/keyboards/handwired/rules.mk b/keyboards/handwired/rules.mk
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/keyboards/handwired/rules.mk
diff --git a/keyboards/handwired/traveller/Makefile b/keyboards/handwired/traveller/Makefile
index 12a4b71f4e..191c6bb664 100644
--- a/keyboards/handwired/traveller/Makefile
+++ b/keyboards/handwired/traveller/Makefile
@@ -1,89 +1,3 @@
-
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-# for avr upload
-USB ?= /dev/cu.usbmodem1421
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-
-ifdef TEENSY2
- OPT_DEFS += -DATREUS_TEENSY2
- ATREUS_UPLOAD_COMMAND = teensy_loader_cli -w -mmcu=$(MCU) $(TARGET).hex
-else
- OPT_DEFS += -DATREUS_ASTAR
- OPT_DEFS += -DCATERINA_BOOTLOADER
- ATREUS_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \
- avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB)
-endif
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# MCU name
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= no # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-RGBLIGHT_ENABLE = yes
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
-endif
-
-upload: build
- $(ATREUS_UPLOAD_COMMAND)
-
+endif \ No newline at end of file
diff --git a/keyboards/handwired/traveller/rules.mk b/keyboards/handwired/traveller/rules.mk
new file mode 100644
index 0000000000..12a4b71f4e
--- /dev/null
+++ b/keyboards/handwired/traveller/rules.mk
@@ -0,0 +1,89 @@
+
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+# for avr upload
+USB ?= /dev/cu.usbmodem1421
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+
+ifdef TEENSY2
+ OPT_DEFS += -DATREUS_TEENSY2
+ ATREUS_UPLOAD_COMMAND = teensy_loader_cli -w -mmcu=$(MCU) $(TARGET).hex
+else
+ OPT_DEFS += -DATREUS_ASTAR
+ OPT_DEFS += -DCATERINA_BOOTLOADER
+ ATREUS_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \
+ avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB)
+endif
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# MCU name
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= no # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6
+RGBLIGHT_ENABLE = yes
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif
+
+upload: build
+ $(ATREUS_UPLOAD_COMMAND)
+
diff --git a/keyboards/hhkb/Makefile b/keyboards/hhkb/Makefile
index 6fe973e1eb..4e2a6f00fd 100644
--- a/keyboards/hhkb/Makefile
+++ b/keyboards/hhkb/Makefile
@@ -1,90 +1,3 @@
-
-
-# project specific files
-SRC = matrix.c
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-#OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-# as per original hasu settings
-OPT_DEFS += -DBOOTLOADER_SIZE=512
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-CUSTOM_MATRIX ?= yes # Custom matrix file for the HHKB
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-# NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-# MIDI_ENABLE ?= YES # MIDI controls
-# UNICODE_ENABLE ?= YES # Unicode
-# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-
-
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
-ifneq (, $(findstring yes, $(HHKB_JP)))
- OPT_DEFS += -DHHKB_JP
-endif
-
-debug-on: EXTRAFLAGS += -DDEBUG -DDEBUG_ACTION
-debug-on: all
-
-debug-off: EXTRAFLAGS += -DNO_DEBUG -DNO_PRINT
-debug-off: OPT_DEFS := $(filter-out -DCONSOLE_ENABLE,$(OPT_DEFS))
-debug-off: all
+endif \ No newline at end of file
diff --git a/keyboards/hhkb/keymaps/dbroqua/keymap.c b/keyboards/hhkb/keymaps/dbroqua/keymap.c
new file mode 100644
index 0000000000..ef43aae281
--- /dev/null
+++ b/keyboards/hhkb/keymaps/dbroqua/keymap.c
@@ -0,0 +1,70 @@
+/*
+ * dbroqua HHKB Layout
+ */
+#include "hhkb.h"
+
+#define BASE 0
+#define FN 1
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ /* BASE Level: Default Layer
+ * ,-----------------------------------------------------------------------------------------.
+ * | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | \ | ` |
+ * |-----------------------------------------------------------------------------------------+
+ * | Tab | Q | W | E | R | T | Y | U | I | O | P | [ | ] | Bksp |
+ * |-----------------------------------------------------------------------------------------+
+ * | Ctrl | A | S | D | F | G | H | J | K | L | ; | ' | Enter |
+ * |-----------------------------------------------------------------------------------------+
+ * | Shift | Z | X | C | V | B | N | M | , | . | / | Left |Right|
+ * +-----------------------------------------------------------------------------------------+
+ * | Gui | Alt | Space | AltGr | fn |
+ * `----------------------------------------------------------------´
+ */
+ [BASE] = KEYMAP(
+ KC_ESC, 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_BSLS, KC_GRV, \
+ 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_BSPC, \
+ KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, \
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_LEFT, KC_RGHT, \
+ KC_LGUI, KC_LALT, /* */ KC_SPC, KC_RALT, MO(FN)
+ ),
+
+ /* BASE Level: Default Layer
+ * ,-----------------------------------------------------------------------------------------.
+ * | | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F0 | F11 | F12 | Ins | Del|
+ * |-----------------------------------------------------------------------------------------+
+ * | Caps | | | | | | | | | | | Up | | |
+ * |-----------------------------------------------------------------------------------------+
+ * | | Vol-| Vol+| Mute| | | |PrtSc| Home| PgUp| Left |Right| |
+ * |-----------------------------------------------------------------------------------------+
+ * | | Prev| Play| Next| | | | | End |PgDwn| Down| Up | Down|
+ * +-----------------------------------------------------------------------------------------+
+ * | | | | | |
+ * `----------------------------------------------------------------´
+ */
+ [FN] = KEYMAP(
+ KC_TRNS, 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_INS, KC_DEL, \
+ KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, \
+ KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_TRNS, KC_TRNS, KC_TRNS, KC_PSCR, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_TRNS, \
+ KC_TRNS, KC_MPRV, KC_MPLY, KC_MNXT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, KC_PGDN, KC_DOWN, KC_UP, KC_DOWN, \
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
+ )
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ register_code(KC_RSFT);
+ } else {
+ unregister_code(KC_RSFT);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
diff --git a/keyboards/hhkb/keymaps/dbroqua/readme.md b/keyboards/hhkb/keymaps/dbroqua/readme.md
new file mode 100644
index 0000000000..0afebc84c8
--- /dev/null
+++ b/keyboards/hhkb/keymaps/dbroqua/readme.md
@@ -0,0 +1,9 @@
+# Dbroqua Layout
+
+* Online keyboard layout editor: http://www.keyboard-layout-editor.com/#/gists/78eaf35e80bb714eea80cb4049dedb01
+
+# Programming Instructions:
+Enter into programming mode and run the following command.
+```
+$ sudo KEYMAP=dbroqua make dfu
+``` \ No newline at end of file
diff --git a/keyboards/hhkb/keymaps/jp/Makefile b/keyboards/hhkb/keymaps/jp/Makefile
index 92986292a2..a7f700f019 100644
--- a/keyboards/hhkb/keymaps/jp/Makefile
+++ b/keyboards/hhkb/keymaps/jp/Makefile
@@ -1 +1 @@
-HHKB_JP=yes
+OPT_DEFS += -DHHKB_JP
diff --git a/keyboards/hhkb/keymaps/rdg_jp/Makefile b/keyboards/hhkb/keymaps/rdg_jp/Makefile
index 92986292a2..a7f700f019 100644
--- a/keyboards/hhkb/keymaps/rdg_jp/Makefile
+++ b/keyboards/hhkb/keymaps/rdg_jp/Makefile
@@ -1 +1 @@
-HHKB_JP=yes
+OPT_DEFS += -DHHKB_JP
diff --git a/keyboards/hhkb/readme.md b/keyboards/hhkb/readme.md
index 39d49b32a1..367c0a08f7 100644
--- a/keyboards/hhkb/readme.md
+++ b/keyboards/hhkb/readme.md
@@ -168,13 +168,15 @@ Download or clone the whole firmware and navigate to the keyboards/planck folder
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create a file in the keymaps folder named `<name>.c` and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|jack|<name>]
```
+
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
diff --git a/keyboards/hhkb/rules.mk b/keyboards/hhkb/rules.mk
new file mode 100644
index 0000000000..a46271f023
--- /dev/null
+++ b/keyboards/hhkb/rules.mk
@@ -0,0 +1,80 @@
+
+
+# project specific files
+SRC = matrix.c
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+#OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+# as per original hasu settings
+OPT_DEFS += -DBOOTLOADER_SIZE=512
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+CUSTOM_MATRIX ?= yes # Custom matrix file for the HHKB
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+# NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+# MIDI_ENABLE ?= yes # MIDI controls
+# UNICODE_ENABLE ?= yes # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
+
+debug-on: EXTRAFLAGS += -DDEBUG -DDEBUG_ACTION
+debug-on: all
+
+debug-off: EXTRAFLAGS += -DNO_DEBUG -DNO_PRINT
+debug-off: OPT_DEFS := $(filter-out -DCONSOLE_ENABLE,$(OPT_DEFS))
+debug-off: all
diff --git a/keyboards/infinity_chibios/MEMO.txt b/keyboards/infinity60/MEMO.txt
index e2886aa002..e2886aa002 100644
--- a/keyboards/infinity_chibios/MEMO.txt
+++ b/keyboards/infinity60/MEMO.txt
diff --git a/keyboards/infinity60/Makefile b/keyboards/infinity60/Makefile
new file mode 100644
index 0000000000..4e2a6f00fd
--- /dev/null
+++ b/keyboards/infinity60/Makefile
@@ -0,0 +1,3 @@
+ifndef MAKEFILE_INCLUDED
+ include ../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/infinity_chibios/bootloader_defs.h b/keyboards/infinity60/bootloader_defs.h
index c67153be60..c67153be60 100644
--- a/keyboards/infinity_chibios/bootloader_defs.h
+++ b/keyboards/infinity60/bootloader_defs.h
diff --git a/keyboards/infinity_chibios/chconf.h b/keyboards/infinity60/chconf.h
index b886c383bb..43c845739a 100644
--- a/keyboards/infinity_chibios/chconf.h
+++ b/keyboards/infinity60/chconf.h
@@ -1,524 +1,524 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-/**
- * @file templates/chconf.h
- * @brief Configuration file template.
- * @details A copy of this file must be placed in each project directory, it
- * contains the application specific kernel settings.
- *
- * @addtogroup config
- * @details Kernel related settings and hooks.
- * @{
- */
-
-#ifndef CHCONF_H
-#define CHCONF_H
-
-#define _CHIBIOS_RT_CONF_
-
-/*===========================================================================*/
-/**
- * @name System timers settings
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief System time counter resolution.
- * @note Allowed values are 16 or 32 bits.
- */
-#define CH_CFG_ST_RESOLUTION 32
-
-/**
- * @brief System tick frequency.
- * @details Frequency of the system timer that drives the system ticks. This
- * setting also defines the system tick time unit.
- */
-#define CH_CFG_ST_FREQUENCY 1000
-
-/**
- * @brief Time delta constant for the tick-less mode.
- * @note If this value is zero then the system uses the classic
- * periodic tick. This value represents the minimum number
- * of ticks that is safe to specify in a timeout directive.
- * The value one is not valid, timeouts are rounded up to
- * this value.
- */
-#define CH_CFG_ST_TIMEDELTA 0
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Kernel parameters and options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Round robin interval.
- * @details This constant is the number of system ticks allowed for the
- * threads before preemption occurs. Setting this value to zero
- * disables the preemption for threads with equal priority and the
- * round robin becomes cooperative. Note that higher priority
- * threads can still preempt, the kernel is always preemptive.
- * @note Disabling the round robin preemption makes the kernel more compact
- * and generally faster.
- * @note The round robin preemption is not supported in tickless mode and
- * must be set to zero in that case.
- */
-#define CH_CFG_TIME_QUANTUM 20
-
-/**
- * @brief Managed RAM size.
- * @details Size of the RAM area to be managed by the OS. If set to zero
- * then the whole available RAM is used. The core memory is made
- * available to the heap allocator and/or can be used directly through
- * the simplified core memory allocator.
- *
- * @note In order to let the OS manage the whole RAM the linker script must
- * provide the @p __heap_base__ and @p __heap_end__ symbols.
- * @note Requires @p CH_CFG_USE_MEMCORE.
- */
-#define CH_CFG_MEMCORE_SIZE 0
-
-/**
- * @brief Idle thread automatic spawn suppression.
- * @details When this option is activated the function @p chSysInit()
- * does not spawn the idle thread. The application @p main()
- * function becomes the idle thread and must implement an
- * infinite loop.
- */
-#define CH_CFG_NO_IDLE_THREAD FALSE
-
-/* Use __WFI in the idle thread for waiting. Does lower the power
- * consumption. */
-#define CORTEX_ENABLE_WFI_IDLE TRUE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Performance options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief OS optimization.
- * @details If enabled then time efficient rather than space efficient code
- * is used when two possible implementations exist.
- *
- * @note This is not related to the compiler optimization options.
- * @note The default is @p TRUE.
- */
-#define CH_CFG_OPTIMIZE_SPEED TRUE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Subsystem options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Time Measurement APIs.
- * @details If enabled then the time measurement APIs are included in
- * the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_TM FALSE
-
-/**
- * @brief Threads registry APIs.
- * @details If enabled then the registry APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_REGISTRY TRUE
-
-/**
- * @brief Threads synchronization APIs.
- * @details If enabled then the @p chThdWait() function is included in
- * the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_WAITEXIT TRUE
-
-/**
- * @brief Semaphores APIs.
- * @details If enabled then the Semaphores APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_SEMAPHORES TRUE
-
-/**
- * @brief Semaphores queuing mode.
- * @details If enabled then the threads are enqueued on semaphores by
- * priority rather than in FIFO order.
- *
- * @note The default is @p FALSE. Enable this if you have special
- * requirements.
- * @note Requires @p CH_CFG_USE_SEMAPHORES.
- */
-#define CH_CFG_USE_SEMAPHORES_PRIORITY FALSE
-
-/**
- * @brief Mutexes APIs.
- * @details If enabled then the mutexes APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MUTEXES TRUE
-
-/**
- * @brief Enables recursive behavior on mutexes.
- * @note Recursive mutexes are heavier and have an increased
- * memory footprint.
- *
- * @note The default is @p FALSE.
- * @note Requires @p CH_CFG_USE_MUTEXES.
- */
-#define CH_CFG_USE_MUTEXES_RECURSIVE FALSE
-
-/**
- * @brief Conditional Variables APIs.
- * @details If enabled then the conditional variables APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_MUTEXES.
- */
-#define CH_CFG_USE_CONDVARS TRUE
-
-/**
- * @brief Conditional Variables APIs with timeout.
- * @details If enabled then the conditional variables APIs with timeout
- * specification are included in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_CONDVARS.
- */
-#define CH_CFG_USE_CONDVARS_TIMEOUT TRUE
-
-/**
- * @brief Events Flags APIs.
- * @details If enabled then the event flags APIs are included in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_EVENTS TRUE
-
-/**
- * @brief Events Flags APIs with timeout.
- * @details If enabled then the events APIs with timeout specification
- * are included in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_EVENTS.
- */
-#define CH_CFG_USE_EVENTS_TIMEOUT TRUE
-
-/**
- * @brief Synchronous Messages APIs.
- * @details If enabled then the synchronous messages APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MESSAGES TRUE
-
-/**
- * @brief Synchronous Messages queuing mode.
- * @details If enabled then messages are served by priority rather than in
- * FIFO order.
- *
- * @note The default is @p FALSE. Enable this if you have special
- * requirements.
- * @note Requires @p CH_CFG_USE_MESSAGES.
- */
-#define CH_CFG_USE_MESSAGES_PRIORITY FALSE
-
-/**
- * @brief Mailboxes APIs.
- * @details If enabled then the asynchronous messages (mailboxes) APIs are
- * included in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_SEMAPHORES.
- */
-#define CH_CFG_USE_MAILBOXES TRUE
-
-/**
- * @brief Core Memory Manager APIs.
- * @details If enabled then the core memory manager APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MEMCORE TRUE
-
-/**
- * @brief Heap Allocator APIs.
- * @details If enabled then the memory heap allocator APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_MEMCORE and either @p CH_CFG_USE_MUTEXES or
- * @p CH_CFG_USE_SEMAPHORES.
- * @note Mutexes are recommended.
- */
-#define CH_CFG_USE_HEAP TRUE
-
-/**
- * @brief Memory Pools Allocator APIs.
- * @details If enabled then the memory pools allocator APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- */
-#define CH_CFG_USE_MEMPOOLS TRUE
-
-/**
- * @brief Dynamic Threads APIs.
- * @details If enabled then the dynamic threads creation APIs are included
- * in the kernel.
- *
- * @note The default is @p TRUE.
- * @note Requires @p CH_CFG_USE_WAITEXIT.
- * @note Requires @p CH_CFG_USE_HEAP and/or @p CH_CFG_USE_MEMPOOLS.
- */
-#define CH_CFG_USE_DYNAMIC TRUE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Debug options
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Debug option, kernel statistics.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_STATISTICS FALSE
-
-/**
- * @brief Debug option, system state check.
- * @details If enabled the correct call protocol for system APIs is checked
- * at runtime.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_SYSTEM_STATE_CHECK FALSE
-
-/**
- * @brief Debug option, parameters checks.
- * @details If enabled then the checks on the API functions input
- * parameters are activated.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_ENABLE_CHECKS FALSE
-
-/**
- * @brief Debug option, consistency checks.
- * @details If enabled then all the assertions in the kernel code are
- * activated. This includes consistency checks inside the kernel,
- * runtime anomalies and port-defined checks.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_ENABLE_ASSERTS FALSE
-
-/**
- * @brief Debug option, trace buffer.
- * @details If enabled then the trace buffer is activated.
- *
- * @note The default is @p CH_DBG_TRACE_MASK_DISABLED.
- */
-#define CH_DBG_TRACE_MASK CH_DBG_TRACE_MASK_DISABLED
-
-/**
- * @brief Trace buffer entries.
- * @note The trace buffer is only allocated if @p CH_DBG_TRACE_MASK is
- * different from @p CH_DBG_TRACE_MASK_DISABLED.
- */
-#define CH_DBG_TRACE_BUFFER_SIZE 128
-
-/**
- * @brief Debug option, stack checks.
- * @details If enabled then a runtime stack check is performed.
- *
- * @note The default is @p FALSE.
- * @note The stack check is performed in a architecture/port dependent way.
- * It may not be implemented or some ports.
- * @note The default failure mode is to halt the system with the global
- * @p panic_msg variable set to @p NULL.
- */
-#define CH_DBG_ENABLE_STACK_CHECK FALSE
-
-/**
- * @brief Debug option, stacks initialization.
- * @details If enabled then the threads working area is filled with a byte
- * value when a thread is created. This can be useful for the
- * runtime measurement of the used stack.
- *
- * @note The default is @p FALSE.
- */
-#define CH_DBG_FILL_THREADS FALSE
-
-/**
- * @brief Debug option, threads profiling.
- * @details If enabled then a field is added to the @p thread_t structure that
- * counts the system ticks occurred while executing the thread.
- *
- * @note The default is @p FALSE.
- * @note This debug option is not currently compatible with the
- * tickless mode.
- */
-#define CH_DBG_THREADS_PROFILING FALSE
-
-/** @} */
-
-/*===========================================================================*/
-/**
- * @name Kernel hooks
- * @{
- */
-/*===========================================================================*/
-
-/**
- * @brief Threads descriptor structure extension.
- * @details User fields added to the end of the @p thread_t structure.
- */
-#define CH_CFG_THREAD_EXTRA_FIELDS \
- /* Add threads custom fields here.*/
-
-/**
- * @brief Threads initialization hook.
- * @details User initialization code added to the @p chThdInit() API.
- *
- * @note It is invoked from within @p chThdInit() and implicitly from all
- * the threads creation APIs.
- */
-#define CH_CFG_THREAD_INIT_HOOK(tp) { \
- /* Add threads initialization code here.*/ \
-}
-
-/**
- * @brief Threads finalization hook.
- * @details User finalization code added to the @p chThdExit() API.
- */
-#define CH_CFG_THREAD_EXIT_HOOK(tp) { \
- /* Add threads finalization code here.*/ \
-}
-
-/**
- * @brief Context switch hook.
- * @details This hook is invoked just before switching between threads.
- */
-#define CH_CFG_CONTEXT_SWITCH_HOOK(ntp, otp) { \
- /* Context switch code here.*/ \
-}
-
-/**
- * @brief ISR enter hook.
- */
-#define CH_CFG_IRQ_PROLOGUE_HOOK() { \
- /* IRQ prologue code here.*/ \
-}
-
-/**
- * @brief ISR exit hook.
- */
-#define CH_CFG_IRQ_EPILOGUE_HOOK() { \
- /* IRQ epilogue code here.*/ \
-}
-
-/**
- * @brief Idle thread enter hook.
- * @note This hook is invoked within a critical zone, no OS functions
- * should be invoked from here.
- * @note This macro can be used to activate a power saving mode.
- */
-#define CH_CFG_IDLE_ENTER_HOOK() { \
- /* Idle-enter code here.*/ \
-}
-
-/**
- * @brief Idle thread leave hook.
- * @note This hook is invoked within a critical zone, no OS functions
- * should be invoked from here.
- * @note This macro can be used to deactivate a power saving mode.
- */
-#define CH_CFG_IDLE_LEAVE_HOOK() { \
- /* Idle-leave code here.*/ \
-}
-
-/**
- * @brief Idle Loop hook.
- * @details This hook is continuously invoked by the idle thread loop.
- */
-#define CH_CFG_IDLE_LOOP_HOOK() { \
- /* Idle loop code here.*/ \
-}
-
-/**
- * @brief System tick event hook.
- * @details This hook is invoked in the system tick handler immediately
- * after processing the virtual timers queue.
- */
-#define CH_CFG_SYSTEM_TICK_HOOK() { \
- /* System tick event code here.*/ \
-}
-
-/**
- * @brief System halt hook.
- * @details This hook is invoked in case to a system halting error before
- * the system is halted.
- */
-#define CH_CFG_SYSTEM_HALT_HOOK(reason) { \
- /* System halt code here.*/ \
-}
-
-/**
- * @brief Trace hook.
- * @details This hook is invoked each time a new record is written in the
- * trace buffer.
- */
-#define CH_CFG_TRACE_HOOK(tep) { \
- /* Trace code here.*/ \
-}
-
-/** @} */
-
-/*===========================================================================*/
-/* Port-specific settings (override port settings defaulted in chcore.h). */
-/*===========================================================================*/
-
-#endif /* CHCONF_H */
-
-/** @} */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+/**
+ * @file templates/chconf.h
+ * @brief Configuration file template.
+ * @details A copy of this file must be placed in each project directory, it
+ * contains the application specific kernel settings.
+ *
+ * @addtogroup config
+ * @details Kernel related settings and hooks.
+ * @{
+ */
+
+#ifndef CHCONF_H
+#define CHCONF_H
+
+#define _CHIBIOS_RT_CONF_
+
+/*===========================================================================*/
+/**
+ * @name System timers settings
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief System time counter resolution.
+ * @note Allowed values are 16 or 32 bits.
+ */
+#define CH_CFG_ST_RESOLUTION 32
+
+/**
+ * @brief System tick frequency.
+ * @details Frequency of the system timer that drives the system ticks. This
+ * setting also defines the system tick time unit.
+ */
+#define CH_CFG_ST_FREQUENCY 1000
+
+/**
+ * @brief Time delta constant for the tick-less mode.
+ * @note If this value is zero then the system uses the classic
+ * periodic tick. This value represents the minimum number
+ * of ticks that is safe to specify in a timeout directive.
+ * The value one is not valid, timeouts are rounded up to
+ * this value.
+ */
+#define CH_CFG_ST_TIMEDELTA 0
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Kernel parameters and options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Round robin interval.
+ * @details This constant is the number of system ticks allowed for the
+ * threads before preemption occurs. Setting this value to zero
+ * disables the preemption for threads with equal priority and the
+ * round robin becomes cooperative. Note that higher priority
+ * threads can still preempt, the kernel is always preemptive.
+ * @note Disabling the round robin preemption makes the kernel more compact
+ * and generally faster.
+ * @note The round robin preemption is not supported in tickless mode and
+ * must be set to zero in that case.
+ */
+#define CH_CFG_TIME_QUANTUM 20
+
+/**
+ * @brief Managed RAM size.
+ * @details Size of the RAM area to be managed by the OS. If set to zero
+ * then the whole available RAM is used. The core memory is made
+ * available to the heap allocator and/or can be used directly through
+ * the simplified core memory allocator.
+ *
+ * @note In order to let the OS manage the whole RAM the linker script must
+ * provide the @p __heap_base__ and @p __heap_end__ symbols.
+ * @note Requires @p CH_CFG_USE_MEMCORE.
+ */
+#define CH_CFG_MEMCORE_SIZE 0
+
+/**
+ * @brief Idle thread automatic spawn suppression.
+ * @details When this option is activated the function @p chSysInit()
+ * does not spawn the idle thread. The application @p main()
+ * function becomes the idle thread and must implement an
+ * infinite loop.
+ */
+#define CH_CFG_NO_IDLE_THREAD FALSE
+
+/* Use __WFI in the idle thread for waiting. Does lower the power
+ * consumption. */
+#define CORTEX_ENABLE_WFI_IDLE TRUE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Performance options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief OS optimization.
+ * @details If enabled then time efficient rather than space efficient code
+ * is used when two possible implementations exist.
+ *
+ * @note This is not related to the compiler optimization options.
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_OPTIMIZE_SPEED TRUE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Subsystem options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Time Measurement APIs.
+ * @details If enabled then the time measurement APIs are included in
+ * the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_TM FALSE
+
+/**
+ * @brief Threads registry APIs.
+ * @details If enabled then the registry APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_REGISTRY TRUE
+
+/**
+ * @brief Threads synchronization APIs.
+ * @details If enabled then the @p chThdWait() function is included in
+ * the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_WAITEXIT TRUE
+
+/**
+ * @brief Semaphores APIs.
+ * @details If enabled then the Semaphores APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_SEMAPHORES TRUE
+
+/**
+ * @brief Semaphores queuing mode.
+ * @details If enabled then the threads are enqueued on semaphores by
+ * priority rather than in FIFO order.
+ *
+ * @note The default is @p FALSE. Enable this if you have special
+ * requirements.
+ * @note Requires @p CH_CFG_USE_SEMAPHORES.
+ */
+#define CH_CFG_USE_SEMAPHORES_PRIORITY FALSE
+
+/**
+ * @brief Mutexes APIs.
+ * @details If enabled then the mutexes APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MUTEXES TRUE
+
+/**
+ * @brief Enables recursive behavior on mutexes.
+ * @note Recursive mutexes are heavier and have an increased
+ * memory footprint.
+ *
+ * @note The default is @p FALSE.
+ * @note Requires @p CH_CFG_USE_MUTEXES.
+ */
+#define CH_CFG_USE_MUTEXES_RECURSIVE FALSE
+
+/**
+ * @brief Conditional Variables APIs.
+ * @details If enabled then the conditional variables APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_MUTEXES.
+ */
+#define CH_CFG_USE_CONDVARS TRUE
+
+/**
+ * @brief Conditional Variables APIs with timeout.
+ * @details If enabled then the conditional variables APIs with timeout
+ * specification are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_CONDVARS.
+ */
+#define CH_CFG_USE_CONDVARS_TIMEOUT TRUE
+
+/**
+ * @brief Events Flags APIs.
+ * @details If enabled then the event flags APIs are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_EVENTS TRUE
+
+/**
+ * @brief Events Flags APIs with timeout.
+ * @details If enabled then the events APIs with timeout specification
+ * are included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_EVENTS.
+ */
+#define CH_CFG_USE_EVENTS_TIMEOUT TRUE
+
+/**
+ * @brief Synchronous Messages APIs.
+ * @details If enabled then the synchronous messages APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MESSAGES TRUE
+
+/**
+ * @brief Synchronous Messages queuing mode.
+ * @details If enabled then messages are served by priority rather than in
+ * FIFO order.
+ *
+ * @note The default is @p FALSE. Enable this if you have special
+ * requirements.
+ * @note Requires @p CH_CFG_USE_MESSAGES.
+ */
+#define CH_CFG_USE_MESSAGES_PRIORITY FALSE
+
+/**
+ * @brief Mailboxes APIs.
+ * @details If enabled then the asynchronous messages (mailboxes) APIs are
+ * included in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_SEMAPHORES.
+ */
+#define CH_CFG_USE_MAILBOXES TRUE
+
+/**
+ * @brief Core Memory Manager APIs.
+ * @details If enabled then the core memory manager APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MEMCORE TRUE
+
+/**
+ * @brief Heap Allocator APIs.
+ * @details If enabled then the memory heap allocator APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_MEMCORE and either @p CH_CFG_USE_MUTEXES or
+ * @p CH_CFG_USE_SEMAPHORES.
+ * @note Mutexes are recommended.
+ */
+#define CH_CFG_USE_HEAP TRUE
+
+/**
+ * @brief Memory Pools Allocator APIs.
+ * @details If enabled then the memory pools allocator APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ */
+#define CH_CFG_USE_MEMPOOLS TRUE
+
+/**
+ * @brief Dynamic Threads APIs.
+ * @details If enabled then the dynamic threads creation APIs are included
+ * in the kernel.
+ *
+ * @note The default is @p TRUE.
+ * @note Requires @p CH_CFG_USE_WAITEXIT.
+ * @note Requires @p CH_CFG_USE_HEAP and/or @p CH_CFG_USE_MEMPOOLS.
+ */
+#define CH_CFG_USE_DYNAMIC TRUE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Debug options
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Debug option, kernel statistics.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_STATISTICS FALSE
+
+/**
+ * @brief Debug option, system state check.
+ * @details If enabled the correct call protocol for system APIs is checked
+ * at runtime.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_SYSTEM_STATE_CHECK FALSE
+
+/**
+ * @brief Debug option, parameters checks.
+ * @details If enabled then the checks on the API functions input
+ * parameters are activated.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_ENABLE_CHECKS FALSE
+
+/**
+ * @brief Debug option, consistency checks.
+ * @details If enabled then all the assertions in the kernel code are
+ * activated. This includes consistency checks inside the kernel,
+ * runtime anomalies and port-defined checks.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_ENABLE_ASSERTS FALSE
+
+/**
+ * @brief Debug option, trace buffer.
+ * @details If enabled then the trace buffer is activated.
+ *
+ * @note The default is @p CH_DBG_TRACE_MASK_DISABLED.
+ */
+#define CH_DBG_TRACE_MASK CH_DBG_TRACE_MASK_DISABLED
+
+/**
+ * @brief Trace buffer entries.
+ * @note The trace buffer is only allocated if @p CH_DBG_TRACE_MASK is
+ * different from @p CH_DBG_TRACE_MASK_DISABLED.
+ */
+#define CH_DBG_TRACE_BUFFER_SIZE 128
+
+/**
+ * @brief Debug option, stack checks.
+ * @details If enabled then a runtime stack check is performed.
+ *
+ * @note The default is @p FALSE.
+ * @note The stack check is performed in a architecture/port dependent way.
+ * It may not be implemented or some ports.
+ * @note The default failure mode is to halt the system with the global
+ * @p panic_msg variable set to @p NULL.
+ */
+#define CH_DBG_ENABLE_STACK_CHECK FALSE
+
+/**
+ * @brief Debug option, stacks initialization.
+ * @details If enabled then the threads working area is filled with a byte
+ * value when a thread is created. This can be useful for the
+ * runtime measurement of the used stack.
+ *
+ * @note The default is @p FALSE.
+ */
+#define CH_DBG_FILL_THREADS FALSE
+
+/**
+ * @brief Debug option, threads profiling.
+ * @details If enabled then a field is added to the @p thread_t structure that
+ * counts the system ticks occurred while executing the thread.
+ *
+ * @note The default is @p FALSE.
+ * @note This debug option is not currently compatible with the
+ * tickless mode.
+ */
+#define CH_DBG_THREADS_PROFILING FALSE
+
+/** @} */
+
+/*===========================================================================*/
+/**
+ * @name Kernel hooks
+ * @{
+ */
+/*===========================================================================*/
+
+/**
+ * @brief Threads descriptor structure extension.
+ * @details User fields added to the end of the @p thread_t structure.
+ */
+#define CH_CFG_THREAD_EXTRA_FIELDS \
+ /* Add threads custom fields here.*/
+
+/**
+ * @brief Threads initialization hook.
+ * @details User initialization code added to the @p chThdInit() API.
+ *
+ * @note It is invoked from within @p chThdInit() and implicitly from all
+ * the threads creation APIs.
+ */
+#define CH_CFG_THREAD_INIT_HOOK(tp) { \
+ /* Add threads initialization code here.*/ \
+}
+
+/**
+ * @brief Threads finalization hook.
+ * @details User finalization code added to the @p chThdExit() API.
+ */
+#define CH_CFG_THREAD_EXIT_HOOK(tp) { \
+ /* Add threads finalization code here.*/ \
+}
+
+/**
+ * @brief Context switch hook.
+ * @details This hook is invoked just before switching between threads.
+ */
+#define CH_CFG_CONTEXT_SWITCH_HOOK(ntp, otp) { \
+ /* Context switch code here.*/ \
+}
+
+/**
+ * @brief ISR enter hook.
+ */
+#define CH_CFG_IRQ_PROLOGUE_HOOK() { \
+ /* IRQ prologue code here.*/ \
+}
+
+/**
+ * @brief ISR exit hook.
+ */
+#define CH_CFG_IRQ_EPILOGUE_HOOK() { \
+ /* IRQ epilogue code here.*/ \
+}
+
+/**
+ * @brief Idle thread enter hook.
+ * @note This hook is invoked within a critical zone, no OS functions
+ * should be invoked from here.
+ * @note This macro can be used to activate a power saving mode.
+ */
+#define CH_CFG_IDLE_ENTER_HOOK() { \
+ /* Idle-enter code here.*/ \
+}
+
+/**
+ * @brief Idle thread leave hook.
+ * @note This hook is invoked within a critical zone, no OS functions
+ * should be invoked from here.
+ * @note This macro can be used to deactivate a power saving mode.
+ */
+#define CH_CFG_IDLE_LEAVE_HOOK() { \
+ /* Idle-leave code here.*/ \
+}
+
+/**
+ * @brief Idle Loop hook.
+ * @details This hook is continuously invoked by the idle thread loop.
+ */
+#define CH_CFG_IDLE_LOOP_HOOK() { \
+ /* Idle loop code here.*/ \
+}
+
+/**
+ * @brief System tick event hook.
+ * @details This hook is invoked in the system tick handler immediately
+ * after processing the virtual timers queue.
+ */
+#define CH_CFG_SYSTEM_TICK_HOOK() { \
+ /* System tick event code here.*/ \
+}
+
+/**
+ * @brief System halt hook.
+ * @details This hook is invoked in case to a system halting error before
+ * the system is halted.
+ */
+#define CH_CFG_SYSTEM_HALT_HOOK(reason) { \
+ /* System halt code here.*/ \
+}
+
+/**
+ * @brief Trace hook.
+ * @details This hook is invoked each time a new record is written in the
+ * trace buffer.
+ */
+#define CH_CFG_TRACE_HOOK(tep) { \
+ /* Trace code here.*/ \
+}
+
+/** @} */
+
+/*===========================================================================*/
+/* Port-specific settings (override port settings defaulted in chcore.h). */
+/*===========================================================================*/
+
+#endif /* CHCONF_H */
+
+/** @} */
diff --git a/keyboards/infinity_chibios/config.h b/keyboards/infinity60/config.h
index 452cc2a9fb..f8346fe165 100644
--- a/keyboards/infinity_chibios/config.h
+++ b/keyboards/infinity60/config.h
@@ -26,11 +26,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define DEVICE_VER 0x0001
/* in python2: list(u"whatever".encode('utf-16-le')) */
/* at most 32 characters or the ugly hack in usb_main.c borks */
-#define MANUFACTURER "TMK"
-#define USBSTR_MANUFACTURER 'T', '\x00', 'M', '\x00', 'K', '\x00', ' ', '\x00', '\xc6', '\x00'
-#define PRODUCT "Infinity keyboard/TMK"
-#define USBSTR_PRODUCT 'I', '\x00', 'n', '\x00', 'f', '\x00', 'i', '\x00', 'n', '\x00', 'i', '\x00', 't', '\x00', 'y', '\x00', ' ', '\x00', 'k', '\x00', 'e', '\x00', 'y', '\x00', 'b', '\x00', 'o', '\x00', 'a', '\x00', 'r', '\x00', 'd', '\x00', '/', '\x00', 'T', '\x00', 'M', '\x00', 'K', '\x00'
-
+#define MANUFACTURER "Input Club"
+#define USBSTR_MANUFACTURER 'I', '\x00', 'n', '\x00', 'p', '\x00', 'u', '\x00', 't', '\x00', ' ', '\x00', 'C', '\x00', 'l', '\x00', 'u', '\x00', 'b', '\x00'
+#define PRODUCT "Infinity keyboard/QMK"
+#define USBSTR_PRODUCT 'I', '\x00', 'n', '\x00', 'f', '\x00', 'i', '\x00', 'n', '\x00', 'i', '\x00', 't', '\x00', 'y', '\x00', ' ', '\x00', 'k', '\x00', 'e', '\x00', 'y', '\x00', 'b', '\x00', 'o', '\x00', 'a', '\x00', 'r', '\x00', 'd', '\x00', '/', '\x00', 'Q', '\x00', 'M', '\x00', 'K', '\x00'
/* key matrix size */
#define MATRIX_ROWS 9
#define MATRIX_COLS 7
diff --git a/keyboards/infinity_chibios/halconf.h b/keyboards/infinity60/halconf.h
index 53538de149..46b37a4f46 100644
--- a/keyboards/infinity_chibios/halconf.h
+++ b/keyboards/infinity60/halconf.h
@@ -1,353 +1,353 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-/**
- * @file templates/halconf.h
- * @brief HAL configuration header.
- * @details HAL configuration file, this file allows to enable or disable the
- * various device drivers from your application. You may also use
- * this file in order to override the device drivers default settings.
- *
- * @addtogroup HAL_CONF
- * @{
- */
-
-#ifndef _HALCONF_H_
-#define _HALCONF_H_
-
-#include "mcuconf.h"
-
-/**
- * @brief Enables the PAL subsystem.
- */
-#if !defined(HAL_USE_PAL) || defined(__DOXYGEN__)
-#define HAL_USE_PAL TRUE
-#endif
-
-/**
- * @brief Enables the ADC subsystem.
- */
-#if !defined(HAL_USE_ADC) || defined(__DOXYGEN__)
-#define HAL_USE_ADC FALSE
-#endif
-
-/**
- * @brief Enables the CAN subsystem.
- */
-#if !defined(HAL_USE_CAN) || defined(__DOXYGEN__)
-#define HAL_USE_CAN FALSE
-#endif
-
-/**
- * @brief Enables the DAC subsystem.
- */
-#if !defined(HAL_USE_DAC) || defined(__DOXYGEN__)
-#define HAL_USE_DAC FALSE
-#endif
-
-/**
- * @brief Enables the EXT subsystem.
- */
-#if !defined(HAL_USE_EXT) || defined(__DOXYGEN__)
-#define HAL_USE_EXT FALSE
-#endif
-
-/**
- * @brief Enables the GPT subsystem.
- */
-#if !defined(HAL_USE_GPT) || defined(__DOXYGEN__)
-#define HAL_USE_GPT FALSE
-#endif
-
-/**
- * @brief Enables the I2C subsystem.
- */
-#if !defined(HAL_USE_I2C) || defined(__DOXYGEN__)
-#define HAL_USE_I2C FALSE
-#endif
-
-/**
- * @brief Enables the I2S subsystem.
- */
-#if !defined(HAL_USE_I2S) || defined(__DOXYGEN__)
-#define HAL_USE_I2S FALSE
-#endif
-
-/**
- * @brief Enables the ICU subsystem.
- */
-#if !defined(HAL_USE_ICU) || defined(__DOXYGEN__)
-#define HAL_USE_ICU FALSE
-#endif
-
-/**
- * @brief Enables the MAC subsystem.
- */
-#if !defined(HAL_USE_MAC) || defined(__DOXYGEN__)
-#define HAL_USE_MAC FALSE
-#endif
-
-/**
- * @brief Enables the MMC_SPI subsystem.
- */
-#if !defined(HAL_USE_MMC_SPI) || defined(__DOXYGEN__)
-#define HAL_USE_MMC_SPI FALSE
-#endif
-
-/**
- * @brief Enables the PWM subsystem.
- */
-#if !defined(HAL_USE_PWM) || defined(__DOXYGEN__)
-#define HAL_USE_PWM FALSE
-#endif
-
-/**
- * @brief Enables the RTC subsystem.
- */
-#if !defined(HAL_USE_RTC) || defined(__DOXYGEN__)
-#define HAL_USE_RTC FALSE
-#endif
-
-/**
- * @brief Enables the SDC subsystem.
- */
-#if !defined(HAL_USE_SDC) || defined(__DOXYGEN__)
-#define HAL_USE_SDC FALSE
-#endif
-
-/**
- * @brief Enables the SERIAL subsystem.
- */
-#if !defined(HAL_USE_SERIAL) || defined(__DOXYGEN__)
-#define HAL_USE_SERIAL FALSE
-#endif
-
-/**
- * @brief Enables the SERIAL over USB subsystem.
- */
-#if !defined(HAL_USE_SERIAL_USB) || defined(__DOXYGEN__)
-#define HAL_USE_SERIAL_USB TRUE
-#endif
-
-/**
- * @brief Enables the SPI subsystem.
- */
-#if !defined(HAL_USE_SPI) || defined(__DOXYGEN__)
-#define HAL_USE_SPI FALSE
-#endif
-
-/**
- * @brief Enables the UART subsystem.
- */
-#if !defined(HAL_USE_UART) || defined(__DOXYGEN__)
-#define HAL_USE_UART FALSE
-#endif
-
-/**
- * @brief Enables the USB subsystem.
- */
-#if !defined(HAL_USE_USB) || defined(__DOXYGEN__)
-#define HAL_USE_USB TRUE
-#endif
-
-/**
- * @brief Enables the WDG subsystem.
- */
-#if !defined(HAL_USE_WDG) || defined(__DOXYGEN__)
-#define HAL_USE_WDG FALSE
-#endif
-
-/*===========================================================================*/
-/* ADC driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Enables synchronous APIs.
- * @note Disabling this option saves both code and data space.
- */
-#if !defined(ADC_USE_WAIT) || defined(__DOXYGEN__)
-#define ADC_USE_WAIT TRUE
-#endif
-
-/**
- * @brief Enables the @p adcAcquireBus() and @p adcReleaseBus() APIs.
- * @note Disabling this option saves both code and data space.
- */
-#if !defined(ADC_USE_MUTUAL_EXCLUSION) || defined(__DOXYGEN__)
-#define ADC_USE_MUTUAL_EXCLUSION TRUE
-#endif
-
-/*===========================================================================*/
-/* CAN driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Sleep mode related APIs inclusion switch.
- */
-#if !defined(CAN_USE_SLEEP_MODE) || defined(__DOXYGEN__)
-#define CAN_USE_SLEEP_MODE TRUE
-#endif
-
-/*===========================================================================*/
-/* I2C driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Enables the mutual exclusion APIs on the I2C bus.
- */
-#if !defined(I2C_USE_MUTUAL_EXCLUSION) || defined(__DOXYGEN__)
-#define I2C_USE_MUTUAL_EXCLUSION TRUE
-#endif
-
-/*===========================================================================*/
-/* MAC driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Enables an event sources for incoming packets.
- */
-#if !defined(MAC_USE_ZERO_COPY) || defined(__DOXYGEN__)
-#define MAC_USE_ZERO_COPY FALSE
-#endif
-
-/**
- * @brief Enables an event sources for incoming packets.
- */
-#if !defined(MAC_USE_EVENTS) || defined(__DOXYGEN__)
-#define MAC_USE_EVENTS TRUE
-#endif
-
-/*===========================================================================*/
-/* MMC_SPI driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Delays insertions.
- * @details If enabled this options inserts delays into the MMC waiting
- * routines releasing some extra CPU time for the threads with
- * lower priority, this may slow down the driver a bit however.
- * This option is recommended also if the SPI driver does not
- * use a DMA channel and heavily loads the CPU.
- */
-#if !defined(MMC_NICE_WAITING) || defined(__DOXYGEN__)
-#define MMC_NICE_WAITING TRUE
-#endif
-
-/*===========================================================================*/
-/* SDC driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Number of initialization attempts before rejecting the card.
- * @note Attempts are performed at 10mS intervals.
- */
-#if !defined(SDC_INIT_RETRY) || defined(__DOXYGEN__)
-#define SDC_INIT_RETRY 100
-#endif
-
-/**
- * @brief Include support for MMC cards.
- * @note MMC support is not yet implemented so this option must be kept
- * at @p FALSE.
- */
-#if !defined(SDC_MMC_SUPPORT) || defined(__DOXYGEN__)
-#define SDC_MMC_SUPPORT FALSE
-#endif
-
-/**
- * @brief Delays insertions.
- * @details If enabled this options inserts delays into the MMC waiting
- * routines releasing some extra CPU time for the threads with
- * lower priority, this may slow down the driver a bit however.
- */
-#if !defined(SDC_NICE_WAITING) || defined(__DOXYGEN__)
-#define SDC_NICE_WAITING TRUE
-#endif
-
-/*===========================================================================*/
-/* SERIAL driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Default bit rate.
- * @details Configuration parameter, this is the baud rate selected for the
- * default configuration.
- */
-#if !defined(SERIAL_DEFAULT_BITRATE) || defined(__DOXYGEN__)
-#define SERIAL_DEFAULT_BITRATE 38400
-#endif
-
-/**
- * @brief Serial buffers size.
- * @details Configuration parameter, you can change the depth of the queue
- * buffers depending on the requirements of your application.
- * @note The default is 64 bytes for both the transmission and receive
- * buffers.
- */
-#if !defined(SERIAL_BUFFERS_SIZE) || defined(__DOXYGEN__)
-#define SERIAL_BUFFERS_SIZE 16
-#endif
-
-/*===========================================================================*/
-/* SERIAL_USB driver related setting. */
-/*===========================================================================*/
-
-/**
- * @brief Serial over USB buffers size.
- * @details Configuration parameter, the buffer size must be a multiple of
- * the USB data endpoint maximum packet size.
- * @note The default is 64 bytes for both the transmission and receive
- * buffers.
- */
-#if !defined(SERIAL_USB_BUFFERS_SIZE) || defined(__DOXYGEN__)
-#define SERIAL_USB_BUFFERS_SIZE 256
-#endif
-
-/*===========================================================================*/
-/* SPI driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Enables synchronous APIs.
- * @note Disabling this option saves both code and data space.
- */
-#if !defined(SPI_USE_WAIT) || defined(__DOXYGEN__)
-#define SPI_USE_WAIT TRUE
-#endif
-
-/**
- * @brief Enables the @p spiAcquireBus() and @p spiReleaseBus() APIs.
- * @note Disabling this option saves both code and data space.
- */
-#if !defined(SPI_USE_MUTUAL_EXCLUSION) || defined(__DOXYGEN__)
-#define SPI_USE_MUTUAL_EXCLUSION TRUE
-#endif
-
-/*===========================================================================*/
-/* USB driver related settings. */
-/*===========================================================================*/
-
-/**
- * @brief Enables synchronous APIs.
- * @note Disabling this option saves both code and data space.
- */
-#if !defined(USB_USE_WAIT) || defined(__DOXYGEN__)
-#define USB_USE_WAIT TRUE
-#endif
-
-#endif /* _HALCONF_H_ */
-
-/** @} */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+/**
+ * @file templates/halconf.h
+ * @brief HAL configuration header.
+ * @details HAL configuration file, this file allows to enable or disable the
+ * various device drivers from your application. You may also use
+ * this file in order to override the device drivers default settings.
+ *
+ * @addtogroup HAL_CONF
+ * @{
+ */
+
+#ifndef _HALCONF_H_
+#define _HALCONF_H_
+
+#include "mcuconf.h"
+
+/**
+ * @brief Enables the PAL subsystem.
+ */
+#if !defined(HAL_USE_PAL) || defined(__DOXYGEN__)
+#define HAL_USE_PAL TRUE
+#endif
+
+/**
+ * @brief Enables the ADC subsystem.
+ */
+#if !defined(HAL_USE_ADC) || defined(__DOXYGEN__)
+#define HAL_USE_ADC FALSE
+#endif
+
+/**
+ * @brief Enables the CAN subsystem.
+ */
+#if !defined(HAL_USE_CAN) || defined(__DOXYGEN__)
+#define HAL_USE_CAN FALSE
+#endif
+
+/**
+ * @brief Enables the DAC subsystem.
+ */
+#if !defined(HAL_USE_DAC) || defined(__DOXYGEN__)
+#define HAL_USE_DAC FALSE
+#endif
+
+/**
+ * @brief Enables the EXT subsystem.
+ */
+#if !defined(HAL_USE_EXT) || defined(__DOXYGEN__)
+#define HAL_USE_EXT FALSE
+#endif
+
+/**
+ * @brief Enables the GPT subsystem.
+ */
+#if !defined(HAL_USE_GPT) || defined(__DOXYGEN__)
+#define HAL_USE_GPT FALSE
+#endif
+
+/**
+ * @brief Enables the I2C subsystem.
+ */
+#if !defined(HAL_USE_I2C) || defined(__DOXYGEN__)
+#define HAL_USE_I2C FALSE
+#endif
+
+/**
+ * @brief Enables the I2S subsystem.
+ */
+#if !defined(HAL_USE_I2S) || defined(__DOXYGEN__)
+#define HAL_USE_I2S FALSE
+#endif
+
+/**
+ * @brief Enables the ICU subsystem.
+ */
+#if !defined(HAL_USE_ICU) || defined(__DOXYGEN__)
+#define HAL_USE_ICU FALSE
+#endif
+
+/**
+ * @brief Enables the MAC subsystem.
+ */
+#if !defined(HAL_USE_MAC) || defined(__DOXYGEN__)
+#define HAL_USE_MAC FALSE
+#endif
+
+/**
+ * @brief Enables the MMC_SPI subsystem.
+ */
+#if !defined(HAL_USE_MMC_SPI) || defined(__DOXYGEN__)
+#define HAL_USE_MMC_SPI FALSE
+#endif
+
+/**
+ * @brief Enables the PWM subsystem.
+ */
+#if !defined(HAL_USE_PWM) || defined(__DOXYGEN__)
+#define HAL_USE_PWM FALSE
+#endif
+
+/**
+ * @brief Enables the RTC subsystem.
+ */
+#if !defined(HAL_USE_RTC) || defined(__DOXYGEN__)
+#define HAL_USE_RTC FALSE
+#endif
+
+/**
+ * @brief Enables the SDC subsystem.
+ */
+#if !defined(HAL_USE_SDC) || defined(__DOXYGEN__)
+#define HAL_USE_SDC FALSE
+#endif
+
+/**
+ * @brief Enables the SERIAL subsystem.
+ */
+#if !defined(HAL_USE_SERIAL) || defined(__DOXYGEN__)
+#define HAL_USE_SERIAL FALSE
+#endif
+
+/**
+ * @brief Enables the SERIAL over USB subsystem.
+ */
+#if !defined(HAL_USE_SERIAL_USB) || defined(__DOXYGEN__)
+#define HAL_USE_SERIAL_USB TRUE
+#endif
+
+/**
+ * @brief Enables the SPI subsystem.
+ */
+#if !defined(HAL_USE_SPI) || defined(__DOXYGEN__)
+#define HAL_USE_SPI FALSE
+#endif
+
+/**
+ * @brief Enables the UART subsystem.
+ */
+#if !defined(HAL_USE_UART) || defined(__DOXYGEN__)
+#define HAL_USE_UART FALSE
+#endif
+
+/**
+ * @brief Enables the USB subsystem.
+ */
+#if !defined(HAL_USE_USB) || defined(__DOXYGEN__)
+#define HAL_USE_USB TRUE
+#endif
+
+/**
+ * @brief Enables the WDG subsystem.
+ */
+#if !defined(HAL_USE_WDG) || defined(__DOXYGEN__)
+#define HAL_USE_WDG FALSE
+#endif
+
+/*===========================================================================*/
+/* ADC driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Enables synchronous APIs.
+ * @note Disabling this option saves both code and data space.
+ */
+#if !defined(ADC_USE_WAIT) || defined(__DOXYGEN__)
+#define ADC_USE_WAIT TRUE
+#endif
+
+/**
+ * @brief Enables the @p adcAcquireBus() and @p adcReleaseBus() APIs.
+ * @note Disabling this option saves both code and data space.
+ */
+#if !defined(ADC_USE_MUTUAL_EXCLUSION) || defined(__DOXYGEN__)
+#define ADC_USE_MUTUAL_EXCLUSION TRUE
+#endif
+
+/*===========================================================================*/
+/* CAN driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Sleep mode related APIs inclusion switch.
+ */
+#if !defined(CAN_USE_SLEEP_MODE) || defined(__DOXYGEN__)
+#define CAN_USE_SLEEP_MODE TRUE
+#endif
+
+/*===========================================================================*/
+/* I2C driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Enables the mutual exclusion APIs on the I2C bus.
+ */
+#if !defined(I2C_USE_MUTUAL_EXCLUSION) || defined(__DOXYGEN__)
+#define I2C_USE_MUTUAL_EXCLUSION TRUE
+#endif
+
+/*===========================================================================*/
+/* MAC driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Enables an event sources for incoming packets.
+ */
+#if !defined(MAC_USE_ZERO_COPY) || defined(__DOXYGEN__)
+#define MAC_USE_ZERO_COPY FALSE
+#endif
+
+/**
+ * @brief Enables an event sources for incoming packets.
+ */
+#if !defined(MAC_USE_EVENTS) || defined(__DOXYGEN__)
+#define MAC_USE_EVENTS TRUE
+#endif
+
+/*===========================================================================*/
+/* MMC_SPI driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Delays insertions.
+ * @details If enabled this options inserts delays into the MMC waiting
+ * routines releasing some extra CPU time for the threads with
+ * lower priority, this may slow down the driver a bit however.
+ * This option is recommended also if the SPI driver does not
+ * use a DMA channel and heavily loads the CPU.
+ */
+#if !defined(MMC_NICE_WAITING) || defined(__DOXYGEN__)
+#define MMC_NICE_WAITING TRUE
+#endif
+
+/*===========================================================================*/
+/* SDC driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Number of initialization attempts before rejecting the card.
+ * @note Attempts are performed at 10mS intervals.
+ */
+#if !defined(SDC_INIT_RETRY) || defined(__DOXYGEN__)
+#define SDC_INIT_RETRY 100
+#endif
+
+/**
+ * @brief Include support for MMC cards.
+ * @note MMC support is not yet implemented so this option must be kept
+ * at @p FALSE.
+ */
+#if !defined(SDC_MMC_SUPPORT) || defined(__DOXYGEN__)
+#define SDC_MMC_SUPPORT FALSE
+#endif
+
+/**
+ * @brief Delays insertions.
+ * @details If enabled this options inserts delays into the MMC waiting
+ * routines releasing some extra CPU time for the threads with
+ * lower priority, this may slow down the driver a bit however.
+ */
+#if !defined(SDC_NICE_WAITING) || defined(__DOXYGEN__)
+#define SDC_NICE_WAITING TRUE
+#endif
+
+/*===========================================================================*/
+/* SERIAL driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Default bit rate.
+ * @details Configuration parameter, this is the baud rate selected for the
+ * default configuration.
+ */
+#if !defined(SERIAL_DEFAULT_BITRATE) || defined(__DOXYGEN__)
+#define SERIAL_DEFAULT_BITRATE 38400
+#endif
+
+/**
+ * @brief Serial buffers size.
+ * @details Configuration parameter, you can change the depth of the queue
+ * buffers depending on the requirements of your application.
+ * @note The default is 64 bytes for both the transmission and receive
+ * buffers.
+ */
+#if !defined(SERIAL_BUFFERS_SIZE) || defined(__DOXYGEN__)
+#define SERIAL_BUFFERS_SIZE 16
+#endif
+
+/*===========================================================================*/
+/* SERIAL_USB driver related setting. */
+/*===========================================================================*/
+
+/**
+ * @brief Serial over USB buffers size.
+ * @details Configuration parameter, the buffer size must be a multiple of
+ * the USB data endpoint maximum packet size.
+ * @note The default is 64 bytes for both the transmission and receive
+ * buffers.
+ */
+#if !defined(SERIAL_USB_BUFFERS_SIZE) || defined(__DOXYGEN__)
+#define SERIAL_USB_BUFFERS_SIZE 256
+#endif
+
+/*===========================================================================*/
+/* SPI driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Enables synchronous APIs.
+ * @note Disabling this option saves both code and data space.
+ */
+#if !defined(SPI_USE_WAIT) || defined(__DOXYGEN__)
+#define SPI_USE_WAIT TRUE
+#endif
+
+/**
+ * @brief Enables the @p spiAcquireBus() and @p spiReleaseBus() APIs.
+ * @note Disabling this option saves both code and data space.
+ */
+#if !defined(SPI_USE_MUTUAL_EXCLUSION) || defined(__DOXYGEN__)
+#define SPI_USE_MUTUAL_EXCLUSION TRUE
+#endif
+
+/*===========================================================================*/
+/* USB driver related settings. */
+/*===========================================================================*/
+
+/**
+ * @brief Enables synchronous APIs.
+ * @note Disabling this option saves both code and data space.
+ */
+#if !defined(USB_USE_WAIT) || defined(__DOXYGEN__)
+#define USB_USE_WAIT TRUE
+#endif
+
+#endif /* _HALCONF_H_ */
+
+/** @} */
diff --git a/keyboards/infinity_chibios/infinity_chibios.c b/keyboards/infinity60/infinity60.c
index 845eda01b0..e471250feb 100644
--- a/keyboards/infinity_chibios/infinity_chibios.c
+++ b/keyboards/infinity60/infinity60.c
@@ -14,4 +14,4 @@ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "infinity_chibios.h"
+#include "infinity60.h"
diff --git a/keyboards/infinity_chibios/infinity_chibios.h b/keyboards/infinity60/infinity60.h
index f1ba15e489..f1ba15e489 100644
--- a/keyboards/infinity_chibios/infinity_chibios.h
+++ b/keyboards/infinity60/infinity60.h
diff --git a/keyboards/infinity_chibios/keymaps/default/keymap.c b/keyboards/infinity60/keymaps/default/keymap.c
index 5f3b46a367..4434128579 100644
--- a/keyboards/infinity_chibios/keymaps/default/keymap.c
+++ b/keyboards/infinity60/keymaps/default/keymap.c
@@ -1,4 +1,4 @@
-#include "infinity_chibios.h"
+#include "infinity60.h"
const uint16_t keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Layer 0: Default Layer
diff --git a/keyboards/infinity_chibios/keymaps/depariel/keymap.c b/keyboards/infinity60/keymaps/depariel/keymap.c
index e68891f79e..7412b9b9dd 100755
--- a/keyboards/infinity_chibios/keymaps/depariel/keymap.c
+++ b/keyboards/infinity60/keymaps/depariel/keymap.c
@@ -1,4 +1,4 @@
-#include "infinity_chibios.h"
+#include "infinity60.h"
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Layer 0: Default Layer
diff --git a/keyboards/infinity_chibios/keymaps/hasu/keymap.c b/keyboards/infinity60/keymaps/hasu/keymap.c
index a1954d2587..d3728869ab 100644
--- a/keyboards/infinity_chibios/keymaps/hasu/keymap.c
+++ b/keyboards/infinity60/keymaps/hasu/keymap.c
@@ -1,4 +1,4 @@
-#include "infinity_chibios.h"
+#include "infinity60.h"
const uint16_t keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Layer 0: Default Layer
diff --git a/keyboards/infinity_chibios/led.c b/keyboards/infinity60/led.c
index aed66c7c03..aed66c7c03 100644
--- a/keyboards/infinity_chibios/led.c
+++ b/keyboards/infinity60/led.c
diff --git a/keyboards/infinity_chibios/matrix.c b/keyboards/infinity60/matrix.c
index 62c165aa53..62c165aa53 100644
--- a/keyboards/infinity_chibios/matrix.c
+++ b/keyboards/infinity60/matrix.c
diff --git a/keyboards/infinity_chibios/mcuconf.h b/keyboards/infinity60/mcuconf.h
index 66b6ce25de..f453304b75 100644
--- a/keyboards/infinity_chibios/mcuconf.h
+++ b/keyboards/infinity60/mcuconf.h
@@ -1,55 +1,55 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-#ifndef _MCUCONF_H_
-#define _MCUCONF_H_
-
-#define K20x_MCUCONF
-
-/*
- * HAL driver system settings.
- */
-
-/* Select the MCU clocking mode below by enabling the appropriate block. */
-
-#define KINETIS_NO_INIT FALSE
-
-/* FEI mode - 48 MHz with internal 32.768 kHz crystal */
-#define KINETIS_MCG_MODE KINETIS_MCG_MODE_FEI
-#define KINETIS_MCG_FLL_DMX32 1 /* Fine-tune for 32.768 kHz */
-#define KINETIS_MCG_FLL_DRS 1 /* 1464x FLL factor */
-#define KINETIS_SYSCLK_FREQUENCY 47972352UL /* 32.768 kHz * 1464 (~48 MHz) */
-#define KINETIS_CLKDIV1_OUTDIV1 1
-#define KINETIS_CLKDIV1_OUTDIV2 1
-#define KINETIS_CLKDIV1_OUTDIV4 2
-#define KINETIS_BUSCLK_FREQUENCY KINETIS_SYSCLK_FREQUENCY
-#define KINETIS_FLASHCLK_FREQUENCY KINETIS_SYSCLK_FREQUENCY/2
-
-/*
- * SERIAL driver system settings.
- */
-#define KINETIS_SERIAL_USE_UART0 TRUE
-
-/*
- * USB driver settings
- */
-#define KINETIS_USB_USE_USB0 TRUE
-/* Need to redefine this, since the default is for K20x */
-/* This is for Teensy LC; you should comment it out (or change to 5)
- * for Teensy 3.x */
-#define KINETIS_USB_USB0_IRQ_PRIORITY 2
-
-#endif /* _MCUCONF_H_ */
+/*
+ ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+*/
+
+#ifndef _MCUCONF_H_
+#define _MCUCONF_H_
+
+#define K20x_MCUCONF
+
+/*
+ * HAL driver system settings.
+ */
+
+/* Select the MCU clocking mode below by enabling the appropriate block. */
+
+#define KINETIS_NO_INIT FALSE
+
+/* FEI mode - 48 MHz with internal 32.768 kHz crystal */
+#define KINETIS_MCG_MODE KINETIS_MCG_MODE_FEI
+#define KINETIS_MCG_FLL_DMX32 1 /* Fine-tune for 32.768 kHz */
+#define KINETIS_MCG_FLL_DRS 1 /* 1464x FLL factor */
+#define KINETIS_SYSCLK_FREQUENCY 47972352UL /* 32.768 kHz * 1464 (~48 MHz) */
+#define KINETIS_CLKDIV1_OUTDIV1 1
+#define KINETIS_CLKDIV1_OUTDIV2 1
+#define KINETIS_CLKDIV1_OUTDIV4 2
+#define KINETIS_BUSCLK_FREQUENCY KINETIS_SYSCLK_FREQUENCY
+#define KINETIS_FLASHCLK_FREQUENCY KINETIS_SYSCLK_FREQUENCY/2
+
+/*
+ * SERIAL driver system settings.
+ */
+#define KINETIS_SERIAL_USE_UART0 TRUE
+
+/*
+ * USB driver settings
+ */
+#define KINETIS_USB_USE_USB0 TRUE
+/* Need to redefine this, since the default is for K20x */
+/* This is for Teensy LC; you should comment it out (or change to 5)
+ * for Teensy 3.x */
+#define KINETIS_USB_USB0_IRQ_PRIORITY 2
+
+#endif /* _MCUCONF_H_ */
diff --git a/keyboards/infinity60/readme.md b/keyboards/infinity60/readme.md
new file mode 100644
index 0000000000..97457b4077
--- /dev/null
+++ b/keyboards/infinity60/readme.md
@@ -0,0 +1,29 @@
+Infinity 60% keyboard firmware
+======================
+
+## Quantum MK Firmware
+
+For the full Quantum feature list, see [the parent readme](/).
+
+## Keymaps
+
+Several versions of keymaps are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create a folder with the name of your keymap in the keymaps folder, and see keymap documentation (you can find in top readme.md) and existant keymap files.
+
+Keymaps follow the format **__keymap.c__** and are stored in folders in the `keymaps` folder, eg `keymaps/my_keymap/`
+
+
+## Compiling
+
+Download or clone the whole firmware and navigate to the keyboards/infinity60 folder. Once your dev env is setup, you'll be able to use the `make` command to both compile your keymap and flash it to your keyboard.
+
+To just compile, which generates the output files in the `.build` folder at the root of the repository, run `make keymap`, where keymap is the name of the keymap that you want to compile.
+
+## Flashing
+
+To flash the firmware to the keyboard
+
+1. First press the flash button on the bottom of the keyboard. If you already have a flah button mapped in a keyboard layout running on the keyboard, you can also use that.
+2. Then run `make keymap-dfu-util`, where keymap is the name of the keymap you want to flash. On Linux based operating systems you might need to run the comamnd as root, for example `sudo make keymap-dfu-util` on Ubuntu.
+
+**Tip** `make keymap-dfu-util` will also compile the keymap if needed, so you can skip the compilation step if you want to.
+
diff --git a/keyboards/infinity_chibios/Makefile b/keyboards/infinity60/rules.mk
index 649b43e64d..56d6470b59 100644
--- a/keyboards/infinity_chibios/Makefile
+++ b/keyboards/infinity60/rules.mk
@@ -63,8 +63,4 @@ CONSOLE_ENABLE ?= yes # Console for debug
COMMAND_ENABLE ?= yes # Commands for debug and configuration
SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
NKRO_ENABLE ?= yes # USB Nkey Rollover
-CUSTOM_MATRIX ?= yes # Custom matrix file
-
-ifndef QUANTUM_DIR
- include ../../Makefile
-endif \ No newline at end of file
+CUSTOM_MATRIX ?= yes # Custom matrix file \ No newline at end of file
diff --git a/keyboards/jd40/Makefile b/keyboards/jd40/Makefile
new file mode 100644
index 0000000000..242748111c
--- /dev/null
+++ b/keyboards/jd40/Makefile
@@ -0,0 +1,74 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+# CONSOLE_ENABLE ?= yes # Console for debug(+400)
+# COMMAND_ENABLE ?= yes # Commands for debug and configuration
+KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+# MIDI_ENABLE ?= YES # MIDI controls
+# UNICODE_ENABLE ?= YES # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= yes # Enable RGB Underglow
+
+ifndef QUANTUM_DIR
+ include ../../Makefile
+endif
+
diff --git a/keyboards/jd40/config.h b/keyboards/jd40/config.h
new file mode 100644
index 0000000000..e2594f4b37
--- /dev/null
+++ b/keyboards/jd40/config.h
@@ -0,0 +1,79 @@
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0xFEED
+#define PRODUCT_ID 0x6060
+#define DEVICE_VER 0x0001
+#define MANUFACTURER geekhack
+#define PRODUCT jd40v2
+#define DESCRIPTION t.m.k. keyboard firmware for JD40 MKII
+
+/* key matrix size */
+#define MATRIX_ROWS 4
+#define MATRIX_COLS 12
+
+/*
+ * Keyboard Matrix Assignments
+ *
+ * Change this to how you wired your keyboard
+ * COLS: AVR pins used for columns, left to right
+ * ROWS: AVR pins used for rows, top to bottom
+ * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
+ * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
+ *
+*/
+#define MATRIX_ROW_PINS { F0, F1, F5, B4 }
+#define MATRIX_COL_PINS { F4, D7, B5, B6, C6, C7, D4, D6, D5, D0, D1, D2 }
+#define UNUSED_PINS
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
+#define DEBOUNCING_DELAY 5
+
+/* define if matrix has ghost (lacks anti-ghosting diodes) */
+//#define MATRIX_HAS_GHOST
+
+/* number of backlight levels */
+#define BACKLIGHT_LEVELS 3
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+
+/* key combination for magic key command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
+)
+
+#define RGB_DI_PIN D3
+#define RGBLIGHT_TIMER
+#define RGBLED_NUM 12 // Number of LEDs
+#define RGBLIGHT_HUE_STEP 8
+#define RGBLIGHT_SAT_STEP 8
+#define RGBLIGHT_VAL_STEP 8
+
+#endif
diff --git a/keyboards/jd40/jd40.c b/keyboards/jd40/jd40.c
new file mode 100644
index 0000000000..fa06356d97
--- /dev/null
+++ b/keyboards/jd40/jd40.c
@@ -0,0 +1,26 @@
+#include "jd40.h"
+
+void led_set_kb(uint8_t usb_led) {
+ // put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
+
+
+ // if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
+ // gh60_caps_led_on();
+ // } else {
+ // gh60_caps_led_off();
+ // }
+
+ // if (usb_led & (1<<USB_LED_NUM_LOCK)) {
+ // gh60_esc_led_on();
+ // } else {
+ // gh60_esc_led_off();
+ // }
+
+ // if (usb_led & (1<<USB_LED_SCROLL_LOCK)) {
+ // gh60_fn_led_on();
+ // } else {
+ // gh60_fn_led_off();
+ // }
+
+ led_set_user(usb_led);
+}
diff --git a/keyboards/jd40/jd40.h b/keyboards/jd40/jd40.h
new file mode 100644
index 0000000000..77a1222993
--- /dev/null
+++ b/keyboards/jd40/jd40.h
@@ -0,0 +1,45 @@
+#ifndef JD40_H
+#define JD40_H
+
+#include "quantum.h"
+#include "led.h"
+
+/* GH60 LEDs
+ * GPIO pads
+ * 0 F7 WASD LEDs
+ * 1 F6 ESC LED
+ * 2 F5 FN LED
+ * 3 F4 POKER Arrow LEDs
+ * B2 Capslock LED
+ * B0 not connected
+ */
+
+ /*
+inline void gh60_caps_led_on(void) { DDRB |= (1<<2); PORTB &= ~(1<<2); }
+inline void gh60_poker_leds_on(void) { DDRF |= (1<<4); PORTF &= ~(1<<4); }
+inline void gh60_fn_led_on(void) { DDRF |= (1<<5); PORTF &= ~(1<<5); }
+inline void gh60_esc_led_on(void) { DDRF |= (1<<6); PORTF &= ~(1<<6); }
+inline void gh60_wasd_leds_on(void) { DDRF |= (1<<7); PORTF &= ~(1<<7); }
+
+inline void gh60_caps_led_off(void) { DDRB &= ~(1<<2); PORTB &= ~(1<<2); }
+inline void gh60_poker_leds_off(void) { DDRF &= ~(1<<4); PORTF &= ~(1<<4); }
+inline void gh60_fn_led_off(void) { DDRF &= ~(1<<5); PORTF &= ~(1<<5); }
+inline void gh60_esc_led_off(void) { DDRF &= ~(1<<6); PORTF &= ~(1<<6); }
+inline void gh60_wasd_leds_off(void) { DDRF &= ~(1<<7); PORTF &= ~(1<<7); }
+*/
+
+/* JD40 MKII keymap definition macro
+ */
+#define KEYMAP( \
+ K01, K02, K03, K04, K05, K06, K07, K08, K09, K10, K11, K12, \
+ K13, K14, K15, K16, K17, K18, K19, K20, K21, K22, K23, \
+ K24, K25, K26, K27, K28, K29, K30, K31, K32, K33, K34, \
+ K35, K36, K37, K38, K39, K40, K41, K42, K43, K44 \
+) { \
+ { KC_##K01, KC_##K02, KC_##K03, KC_##K04, KC_##K05, KC_##K06, KC_##K07, KC_##K08, KC_##K09, KC_##K10, KC_##K11, KC_##K12 }, \
+ { KC_##K13, KC_##K14, KC_##K15, KC_##K16, KC_##K17, KC_##K18, KC_##K19, KC_##K20, KC_##K21, KC_##K22, KC_##K23, KC_NO }, \
+ { KC_##K24, KC_##K25, KC_##K26, KC_##K27, KC_##K28, KC_##K29, KC_##K30, KC_##K31, KC_##K32, KC_##K33, KC_##K34, KC_NO }, \
+ { KC_##K35, KC_##K36, KC_##K37, KC_##K38, KC_##K39, KC_NO, KC_##K40, KC_##K41, KC_##K42, KC_##K43, KC_##K44, KC_NO } \
+}
+
+#endif
diff --git a/keyboards/jd40/keymaps/default/keymap.c b/keyboards/jd40/keymaps/default/keymap.c
new file mode 100644
index 0000000000..79ac146c9e
--- /dev/null
+++ b/keyboards/jd40/keymaps/default/keymap.c
@@ -0,0 +1,164 @@
+#include "jd40.h"
+#include "action_layer.h"
+
+#define _BL 0
+#define _AL 1
+#define _FL 2
+#define _UL 3
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ [_BL] = KEYMAP(
+ F12, Q, W, E, R, T, Y, U, I, O, P, BSPC,
+ TAB, A, S, D, F, G, H, J, K, L, ENT,
+ LSFT, Z, X, C, V, B, N, M, COMM, UP, DOT,
+ LCTL, LGUI, LALT, FN0, SPC, SPC, FN0, LEFT, DOWN, RIGHT ),
+
+ [_AL] = KEYMAP(
+ GRV, F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, DEL,
+ CAPS, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0,
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, SCLN, PGUP, QUOT,
+ TRNS, TRNS, TRNS, TRNS, FN3, FN3, TRNS, HOME, PGDN, END ),
+
+ [_FL] = KEYMAP(
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS,
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS,
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS,
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS ),
+
+ [_UL] = KEYMAP(
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS,
+ TRNS, FN4, FN5, FN11, FN10, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS,
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS,
+ TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS, TRNS ),
+};
+
+enum function_id {
+ RGBLED_TOGGLE,
+ RGBLED_STEP_MODE,
+ RGBLED_INCREASE_HUE,
+ RGBLED_DECREASE_HUE,
+ RGBLED_INCREASE_SAT,
+ RGBLED_DECREASE_SAT,
+ RGBLED_INCREASE_VAL,
+ RGBLED_DECREASE_VAL,
+ SHIFT_ESC,
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+ [0] = ACTION_LAYER_MOMENTARY(1), // Momentary Fn overlay
+ [1] = ACTION_LAYER_TOGGLE(2), // Toggle Arrow Layer overlay
+ [2] = ACTION_LAYER_TAP_KEY(2, KC_CAPS), // Tap to toggle caps lock and hold to activate function layer
+ [3] = ACTION_LAYER_TOGGLE(3), // Toggle Underglow Layer overlay
+ [4] = ACTION_FUNCTION(RGBLED_TOGGLE), //Turn on/off underglow
+ [5] = ACTION_FUNCTION(RGBLED_STEP_MODE), // Change underglow mode
+ [6] = ACTION_FUNCTION(RGBLED_INCREASE_HUE),
+ [7] = ACTION_FUNCTION(RGBLED_DECREASE_HUE),
+ [8] = ACTION_FUNCTION(RGBLED_INCREASE_SAT),
+ [9] = ACTION_FUNCTION(RGBLED_DECREASE_SAT),
+ [10] = ACTION_FUNCTION(RGBLED_INCREASE_VAL),
+ [11] = ACTION_FUNCTION(RGBLED_DECREASE_VAL),
+ [12] = ACTION_FUNCTION(SHIFT_ESC),
+};
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ // MACRODOWN only works in this function
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ register_code(KC_RSFT);
+ } else {
+ unregister_code(KC_RSFT);
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
+
+void matrix_scan_user(void) {
+
+// Layer LED indicators
+// ESC led on when in function layer, WASD cluster leds enabled when on arrow cluster
+ uint32_t layer = layer_state;
+ if (layer & (1<<1)) {
+ //gh60_wasd_leds_on();
+ } else {
+ //gh60_wasd_leds_off();
+ }
+
+ if (layer & (1<<2)) {
+ //gh60_esc_led_on();
+ } else {
+ //gh60_esc_led_off();
+ }
+};
+
+#define MODS_CTRL_MASK (MOD_BIT(KC_LSHIFT)|MOD_BIT(KC_RSHIFT))
+
+void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) {
+ switch (id) {
+ case RGBLED_TOGGLE:
+ //led operations
+ if (record->event.pressed) {
+ rgblight_toggle();
+ }
+ break;
+ case RGBLED_INCREASE_HUE:
+ if (record->event.pressed) {
+ rgblight_increase_hue();
+ }
+ break;
+ case RGBLED_DECREASE_HUE:
+ if (record->event.pressed) {
+ rgblight_decrease_hue();
+ }
+ break;
+ case RGBLED_INCREASE_SAT:
+ if (record->event.pressed) {
+ rgblight_increase_sat();
+ }
+ break;
+ case RGBLED_DECREASE_SAT:
+ if (record->event.pressed) {
+ rgblight_decrease_sat();
+ }
+ break;
+ case RGBLED_INCREASE_VAL:
+ if (record->event.pressed) {
+ rgblight_increase_val();
+ }
+ break;
+ case RGBLED_DECREASE_VAL:
+ if (record->event.pressed) {
+ rgblight_decrease_val();
+ }
+ break;
+ case RGBLED_STEP_MODE:
+ if (record->event.pressed) {
+ rgblight_step();
+ }
+ break;
+ static uint8_t shift_esc_shift_mask;
+ // Shift + ESC = ~
+ case SHIFT_ESC:
+ shift_esc_shift_mask = get_mods()&MODS_CTRL_MASK;
+ if (record->event.pressed) {
+ if (shift_esc_shift_mask) {
+ add_key(KC_GRV);
+ send_keyboard_report();
+ } else {
+ add_key(KC_ESC);
+ send_keyboard_report();
+ }
+ } else {
+ if (shift_esc_shift_mask) {
+ del_key(KC_GRV);
+ send_keyboard_report();
+ } else {
+ del_key(KC_ESC);
+ send_keyboard_report();
+ }
+ }
+ break;
+ }
+};
diff --git a/keyboards/jd40/readme.md b/keyboards/jd40/readme.md
new file mode 100644
index 0000000000..7daa0980eb
--- /dev/null
+++ b/keyboards/jd40/readme.md
@@ -0,0 +1,17 @@
+## jd40 mkii keyboard firmware
+
+ Pins:
+ MATRIX_ROW_PINS { F0, F1, F5, B4 }
+ MATRIX_COL_PINS { F4, D7, B5, B6, C6, C7, D4, D6, D5, D0, D1, D2 }
+ RGB_DI_PIN D3
+
+======================
+
+## Quantum MK Firmware
+
+For the full Quantum feature list, see [the parent readme.md](/readme.md).
+
+## Building
+
+Download or clone the whole firmware and navigate to the keyboards/jd40 folder.
+Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Amtel Flip to program your .hex file.
diff --git a/keyboards/jd40/rules.mk b/keyboards/jd40/rules.mk
new file mode 100644
index 0000000000..2f18fdf10d
--- /dev/null
+++ b/keyboards/jd40/rules.mk
@@ -0,0 +1,69 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+# CONSOLE_ENABLE ?= yes # Console for debug(+400)
+# COMMAND_ENABLE ?= yes # Commands for debug and configuration
+KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+# BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+# MIDI_ENABLE ?= YES # MIDI controls
+# UNICODE_ENABLE ?= YES # Unicode
+# BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= yes # Enable RGB Underglow \ No newline at end of file
diff --git a/keyboards/jd45/Makefile b/keyboards/jd45/Makefile
index 75d544f16a..4e2a6f00fd 100644
--- a/keyboards/jd45/Makefile
+++ b/keyboards/jd45/Makefile
@@ -1,71 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
-# NKRO_ENABLE ?= yes # USB Nkey Rollover - not yet supported in LUFA
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-MIDI_ENABLE ?= YES # MIDI controls
-# UNICODE_ENABLE ?= YES # Unicode
-BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/jd45/rules.mk b/keyboards/jd45/rules.mk
new file mode 100644
index 0000000000..2f1e266a14
--- /dev/null
+++ b/keyboards/jd45/rules.mk
@@ -0,0 +1,67 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+# SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
+# NKRO_ENABLE ?= yes # USB Nkey Rollover - not yet supported in LUFA
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+MIDI_ENABLE ?= YES # MIDI controls
+# UNICODE_ENABLE ?= YES # Unicode
+BLUETOOTH_ENABLE ?= yes # Enable Bluetooth with the Adafruit EZ-Key HID \ No newline at end of file
diff --git a/keyboards/kc60/Makefile b/keyboards/kc60/Makefile
index 0d17d32dac..57b2ef62e5 100644
--- a/keyboards/kc60/Makefile
+++ b/keyboards/kc60/Makefile
@@ -1,77 +1,3 @@
-# project specific files
-SRC = led.c
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif
-
diff --git a/keyboards/kc60/config.h b/keyboards/kc60/config.h
index c4a9b9ff82..29695d0b9d 100644
--- a/keyboards/kc60/config.h
+++ b/keyboards/kc60/config.h
@@ -62,7 +62,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
//#define MATRIX_HAS_GHOST
/* number of backlight levels */
-#define BACKLIGHT_LEVELS 3
+#define BACKLIGHT_LEVELS 5
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
#define LOCKING_SUPPORT_ENABLE
diff --git a/keyboards/kc60/keymaps/dbroqua/keymap.c b/keyboards/kc60/keymaps/dbroqua/keymap.c
index e17827fad9..1b645ea938 100644
--- a/keyboards/kc60/keymaps/dbroqua/keymap.c
+++ b/keyboards/kc60/keymaps/dbroqua/keymap.c
@@ -34,9 +34,9 @@ const uint16_t PROGMEM fn_actions[] = {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Qwerty
* ,-----------------------------------------------------------------------------------------.
- * | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | ` | Bksp|
+ * | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | \ | ` |
* |-----------------------------------------------------------------------------------------+
- * | Tab | Q | W | E | R | T | Y | U | I | O | P | [ | ] | \ |
+ * | Tab | Q | W | E | R | T | Y | U | I | O | P | [ | ] | Bksp |
* |-----------------------------------------------------------------------------------------+
* | Caps/FN1| A | S | D | F | G | H | J | K | L | ; | ' | Enter |
* |-----------------------------------------------------------------------------------------+
@@ -46,11 +46,11 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* `-----------------------------------------------------------------------------------------'
*/
[0] = KEYMAP( /* Basic QWERTY */
- KC_ESC, 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_GRV, \
- 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_ESC, 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_BSLS, \
+ 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_BSPC, \
LT(_FNCAPS, 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_NO, KC_ENT, \
KC_LSFT, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, MO(_FNRIGHTSHIFT), KC_UP, \
- KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_BSPC, KC_RALT, KC_LEFT, KC_DOWN, KC_RIGHT \
+ KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_GRV, KC_RALT, KC_LEFT, KC_DOWN, KC_RIGHT \
),
/* Layer 1
diff --git a/keyboards/kc60/keymaps/workman-dead/keymap.c b/keyboards/kc60/keymaps/workman-dead/keymap.c
index 9786e37d8c..9e3b9bb656 100644
--- a/keyboards/kc60/keymaps/workman-dead/keymap.c
+++ b/keyboards/kc60/keymaps/workman-dead/keymap.c
@@ -56,7 +56,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TABM, KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, KC_SCLN, KC_LBRC, KC_RBRC, KC_BSLS, \
KC_LCTL, KC_A, KC_S, KC_H, KC_T, KC_G, KC_Y, KC_N, KC_E, KC_O, KC_I, KC_QUOT, _______, KC_ENT, \
KC_LSFT, _______, KC_Z, KC_X, KC_M, KC_C, KC_V, KC_K, KC_L, DK_ACT, KC_DOT, KC_SLSH, _______, KC_RSFT, \
- KC_LCTL, KC_LALT, KC_LGUI, KC_SPFN, KC_NO, KC_RALT, KC_RGUI, KC_RCTL, KC_DFQW),
+ KC_LCTL, KC_LALT, KC_LGUI, KC_SPFN, _______, KC_RALT, KC_RGUI, KC_RCTL, KC_DFQW),
// QWERTY
/*
@@ -77,7 +77,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TABM, 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_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, _______, KC_ENT, \
KC_LSFT, _______, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, DK_ACT, KC_DOT, KC_SLSH, _______, KC_RSFT, \
- KC_LCTL, KC_LALT, KC_LGUI, KC_SPFN, KC_NO, KC_RALT, KC_RGUI, KC_RCTL, KC_DOWN),
+ KC_LCTL, KC_LALT, KC_LGUI, KC_SPFN, _______, KC_RALT, KC_RGUI, KC_RCTL, KC_DFWM),
// dead key layer
/*
@@ -98,7 +98,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
XXXXXXX, KC_PERC, KC_AMPR, KC_QUES, KC_PLUS, KC_AT, KC_DLR, KC_UNDS, KC_LBRC, KC_RBRC, KC_EXLM, KC_TILD, KC_CIRC, _______, \
_______, KC_HASH, KC_LPRN, KC_EQL, KC_0, KC_LCBR, KC_RCBR, KC_1, KC_ASTR, KC_RPRN, KC_MINS, KC_GRV, _______, KC_CENT, \
_______, _______, KC_6, KC_7, KC_8, KC_9, KC_PIPE, KC_BSLS, KC_2, DK_REL, KC_4, KC_5, _______, _______, \
- KC_LCTL, KC_LALT, KC_LGUI, KC_COMS, KC_NO, KC_RALT, KC_RGUI, KC_RCTL, _______),
+ KC_LCTL, KC_LALT, KC_LGUI, KC_COMS, _______, KC_RALT, KC_RGUI, KC_RCTL, _______),
// function layer
/*
@@ -119,7 +119,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_ESC, KC_CMDQ, KC_CMDD, KC_CSTB, KC_C_TB, _______, _______, KC_PGDN, KC_UP, KC_PGUP, _______, _______, _______, KC_INS, \
KC_LSFT, KC_CMDA, KC_CMDS, KC_C_LF, KC_C_RT, _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, KC_HOME, KC_END, _______, KC_BSPC, \
KC_LSFT, _______, KC_CMDZ, KC_CMDX, _______, KC_CMDC, KC_CMDV, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, _______, _______, \
- KC_LCTL, KC_LALT, KC_LGUI, KC_TRNS, KC_NO, KC_RALT, KC_RGUI, KC_RCTL, RESET),
+ KC_LCTL, KC_LALT, KC_LGUI, KC_TRNS, _______, KC_RALT, KC_RGUI, KC_RCTL, RESET),
// mouse layer
/*
diff --git a/keyboards/kc60/keymaps/workman-dead/README.md b/keyboards/kc60/keymaps/workman-dead/readme.md
index f1fcdc9606..f1fcdc9606 100644
--- a/keyboards/kc60/keymaps/workman-dead/README.md
+++ b/keyboards/kc60/keymaps/workman-dead/readme.md
diff --git a/keyboards/kc60/readme.md b/keyboards/kc60/readme.md
index b29c6be302..da84f6159a 100644
--- a/keyboards/kc60/readme.md
+++ b/keyboards/kc60/readme.md
@@ -10,25 +10,27 @@ Download or clone the whole firmware and navigate to the keyboards/kc60 folder.
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|jack|<name>]
```
+
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
## WS2812 Support
![Image of KC60 with RGB Underglow](keymaps/ws2812/ws2812_example.jpg)
-Build with WS2812 Support by running `make KEYMAP=ws2812`.
+Build with WS2812 Support by running `make ws2812`.
## Warning
For those who want to use 2x1U instead of classic backspace you need to use K0D and K49 like this:
* K0D represents the key at the right of =.
* K49 represents the last key of the row (is wired at the right of the space key on the PCB)
-In kc60.h I've put several definitions' examples of possible layouts proposed by online editor (http://123.57.250.164:9128/). \ No newline at end of file
+In kc60.h I've put several definitions' examples of possible layouts proposed by online editor (http://123.57.250.164:9128/).
diff --git a/keyboards/kc60/rules.mk b/keyboards/kc60/rules.mk
new file mode 100644
index 0000000000..a935ed19ee
--- /dev/null
+++ b/keyboards/kc60/rules.mk
@@ -0,0 +1,71 @@
+# project specific files
+SRC = led.c
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+KEYBOARD_LOCK_ENABLE ?= yes # Allow locking of keyboard via magic key
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6
diff --git a/keyboards/kinesis/Makefile b/keyboards/kinesis/Makefile
index ca077e6366..4e2a6f00fd 100644
--- a/keyboards/kinesis/Makefile
+++ b/keyboards/kinesis/Makefile
@@ -1,79 +1,3 @@
-
-## Project specific files
-
-SRC= matrix.c
-
-# MCU name
-MCU = at90usb1286
-#MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=1024
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= no
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE = no # Audio output should be port E6, current quantum library hardcodes C6, which we use for programming
-CUSTOM_MATRIX=yes # need to do our own thing with the matrix
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
-
+endif \ No newline at end of file
diff --git a/keyboards/kinesis/readme.md b/keyboards/kinesis/readme.md
index a990f9cb99..79c86581e6 100644
--- a/keyboards/kinesis/readme.md
+++ b/keyboards/kinesis/readme.md
@@ -27,16 +27,16 @@ Depending on which keymap you would like to use, you will have to compile slight
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create a folder with the name of your keymap in the keymaps folder, and see keymap documentation (you can find in top readme.md) and existant keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `keymap` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
```
-$ make keymap=[default|jack|<name>]
+$ make [default|jack|<name>]
```
Keymaps follow the format **__keymap.c__** and are stored in folders in the `keymaps` folder, eg `keymaps/my_keymap/`
diff --git a/keyboards/kinesis/rules.mk b/keyboards/kinesis/rules.mk
new file mode 100644
index 0000000000..a4a2b7d156
--- /dev/null
+++ b/keyboards/kinesis/rules.mk
@@ -0,0 +1,73 @@
+
+## Project specific files
+
+SRC= matrix.c
+
+# MCU name
+MCU = at90usb1286
+#MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=1024
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= no
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE = no # Audio output should be port E6, current quantum library hardcodes C6, which we use for programming
+CUSTOM_MATRIX=yes # need to do our own thing with the matrix
diff --git a/keyboards/kitten_paw/Makefile b/keyboards/kitten_paw/Makefile
index 3b5585ed6f..57b2ef62e5 100644
--- a/keyboards/kitten_paw/Makefile
+++ b/keyboards/kitten_paw/Makefile
@@ -1,77 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u2
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
- OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-CUSTOM_MATRIX = yes
-SRC += matrix.c
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif
-
diff --git a/keyboards/kitten_paw/rules.mk b/keyboards/kitten_paw/rules.mk
new file mode 100644
index 0000000000..b0c909d11f
--- /dev/null
+++ b/keyboards/kitten_paw/rules.mk
@@ -0,0 +1,72 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u2
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+ OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6
+
+CUSTOM_MATRIX = yes
+SRC += matrix.c
diff --git a/keyboards/lets_split/Makefile b/keyboards/lets_split/Makefile
index b9f07636be..4e2a6f00fd 100644
--- a/keyboards/lets_split/Makefile
+++ b/keyboards/lets_split/Makefile
@@ -1,78 +1,3 @@
-SRC += matrix.c \
- i2c.c \
- split_util.c \
- serial.c
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-# Build Options
-# change to "no" to disable the options, or define them in the Makefile in
-# the appropriate keymap folder that will get included automatically
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= yes # Audio output on port C6
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
-
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-
-CUSTOM_MATRIX = yes
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/lets_split/config.h b/keyboards/lets_split/config.h
index ec99514aa3..f4d900accb 100644
--- a/keyboards/lets_split/config.h
+++ b/keyboards/lets_split/config.h
@@ -41,6 +41,11 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
// #define USE_I2C
+// Use serial if not using I2C
+#ifndef USE_I2C
+# define USE_SERIAL
+#endif
+
// #define EE_HANDS
#define I2C_MASTER_LEFT
@@ -94,4 +99,4 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
//#define NO_ACTION_MACRO
//#define NO_ACTION_FUNCTION
-#endif \ No newline at end of file
+#endif
diff --git a/keyboards/lets_split/i2c.c b/keyboards/lets_split/i2c.c
index c72789403e..084c890c40 100644
--- a/keyboards/lets_split/i2c.c
+++ b/keyboards/lets_split/i2c.c
@@ -6,6 +6,8 @@
#include <stdbool.h>
#include "i2c.h"
+#ifdef USE_I2C
+
// Limits the amount of we wait for any one i2c transaction.
// Since were running SCL line 100kHz (=> 10μs/bit), and each transactions is
// 9 bits, a single transaction will take around 90μs to complete.
@@ -157,3 +159,4 @@ ISR(TWI_vect) {
// Reset everything, so we are ready for the next TWI interrupt
TWCR |= (1<<TWIE) | (1<<TWINT) | (ack<<TWEA) | (1<<TWEN);
}
+#endif
diff --git a/keyboards/lets_split/keymaps/i2c/config.h b/keyboards/lets_split/keymaps/i2c/config.h
new file mode 100644
index 0000000000..2671fabf6d
--- /dev/null
+++ b/keyboards/lets_split/keymaps/i2c/config.h
@@ -0,0 +1,102 @@
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0xFEED
+#define PRODUCT_ID 0x3060
+#define DEVICE_VER 0x0001
+#define MANUFACTURER Wootpatoot
+#define PRODUCT Lets Split
+#define DESCRIPTION A split keyboard for the cheap makers
+
+/* key matrix size */
+// Rows are doubled-up
+#define MATRIX_ROWS 8
+#define MATRIX_COLS 6
+
+// wiring of each half
+#define MATRIX_ROW_PINS { B5, B4, E6, D7 }
+#define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3 }
+
+#define CATERINA_BOOTLOADER
+
+#define USE_I2C
+
+// Use serial if not using I2C
+#ifndef USE_I2C
+# define USE_SERIAL
+#endif
+
+// #define EE_HANDS
+
+#define I2C_MASTER_LEFT
+// #define I2C_MASTER_RIGHT
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* define if matrix has ghost */
+//#define MATRIX_HAS_GHOST
+
+/* number of backlight levels */
+// #define BACKLIGHT_LEVELS 3
+
+/* Set 0 if debouncing isn't needed */
+#define DEBOUNCING_DELAY 5
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+/* key combination for command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
+)
+
+/* ws2812 RGB LED */
+#define RGB_DI_PIN D4
+#define RGBLIGHT_TIMER
+#define RGBLED_NUM 8 // Number of LEDs
+#define RGBLIGHT_HUE_STEP 10
+#define RGBLIGHT_SAT_STEP 17
+#define RGBLIGHT_VAL_STEP 17
+
+/*
+ * Feature disable options
+ * These options are also useful to firmware size reduction.
+ */
+
+/* disable debug print */
+// #define NO_DEBUG
+
+/* disable print */
+// #define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
+
+#endif
diff --git a/keyboards/lets_split/keymaps/i2c/keymap.c b/keyboards/lets_split/keymaps/i2c/keymap.c
new file mode 100644
index 0000000000..0d2d94b672
--- /dev/null
+++ b/keyboards/lets_split/keymaps/i2c/keymap.c
@@ -0,0 +1,214 @@
+#include "lets_split.h"
+#include "action_layer.h"
+#include "eeconfig.h"
+
+extern keymap_config_t keymap_config;
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _QWERTY 0
+#define _COLEMAK 1
+#define _DVORAK 2
+#define _LOWER 3
+#define _RAISE 4
+#define _ADJUST 16
+
+enum custom_keycodes {
+ QWERTY = SAFE_RANGE,
+ COLEMAK,
+ DVORAK,
+ LOWER,
+ RAISE,
+ ADJUST,
+};
+
+// Fillers to make layering more clear
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Qwerty
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | S | D | F | G | H | J | K | L | ; | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | N | M | , | . | / |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_QWERTY] = KEYMAP( \
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
+ KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
+ ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
+),
+
+/* Colemak
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | F | P | G | J | L | U | Y | ; | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | R | S | T | D | H | N | E | I | O | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | K | M | , | . | / |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_COLEMAK] = KEYMAP( \
+ KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC, \
+ KC_ESC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT, \
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
+ ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
+),
+
+/* Dvorak
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | " | , | . | P | Y | F | G | C | R | L | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | O | E | U | I | D | H | T | N | S | / |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| ; | Q | J | K | X | B | M | W | V | Z |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_DVORAK] = KEYMAP( \
+ KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_BSPC, \
+ KC_ESC, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH, \
+ KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_ENT , \
+ ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
+),
+
+/* Lower
+ * ,-----------------------------------------------------------------------------------.
+ * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | | \ | | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | | |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | Next | Vol- | Vol+ | Play |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_LOWER] = KEYMAP( \
+ KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, \
+ KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, \
+ _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS),_______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
+),
+
+/* Raise
+ * ,-----------------------------------------------------------------------------------.
+ * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Del | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / | | |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | Next | Vol- | Vol+ | Play |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_RAISE] = KEYMAP( \
+ KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
+ KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, \
+ _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
+),
+
+/* Adjust (Lower + Raise)
+ * ,-----------------------------------------------------------------------------------.
+ * | | Reset| | | | | | | | | | Del |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | | | |Aud on|Audoff|AGnorm|AGswap|Qwerty|Colemk|Dvorak| | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | | | | | | | | | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_ADJUST] = KEYMAP( \
+ _______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL, \
+ _______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, COLEMAK, DVORAK, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
+)
+
+
+};
+
+#ifdef AUDIO_ENABLE
+float tone_qwerty[][2] = SONG(QWERTY_SOUND);
+float tone_dvorak[][2] = SONG(DVORAK_SOUND);
+float tone_colemak[][2] = SONG(COLEMAK_SOUND);
+#endif
+
+void persistant_default_layer_set(uint16_t default_layer) {
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ case QWERTY:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_qwerty, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_QWERTY);
+ }
+ return false;
+ break;
+ case COLEMAK:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_colemak, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_COLEMAK);
+ }
+ return false;
+ break;
+ case DVORAK:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_dvorak, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_DVORAK);
+ }
+ return false;
+ break;
+ case LOWER:
+ if (record->event.pressed) {
+ layer_on(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case RAISE:
+ if (record->event.pressed) {
+ layer_on(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case ADJUST:
+ if (record->event.pressed) {
+ layer_on(_ADJUST);
+ } else {
+ layer_off(_ADJUST);
+ }
+ return false;
+ break;
+ }
+ return true;
+} \ No newline at end of file
diff --git a/keyboards/lets_split/keymaps/serial/config.h b/keyboards/lets_split/keymaps/serial/config.h
new file mode 100644
index 0000000000..f4d900accb
--- /dev/null
+++ b/keyboards/lets_split/keymaps/serial/config.h
@@ -0,0 +1,102 @@
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0xFEED
+#define PRODUCT_ID 0x3060
+#define DEVICE_VER 0x0001
+#define MANUFACTURER Wootpatoot
+#define PRODUCT Lets Split
+#define DESCRIPTION A split keyboard for the cheap makers
+
+/* key matrix size */
+// Rows are doubled-up
+#define MATRIX_ROWS 8
+#define MATRIX_COLS 6
+
+// wiring of each half
+#define MATRIX_ROW_PINS { B5, B4, E6, D7 }
+#define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3 }
+
+#define CATERINA_BOOTLOADER
+
+// #define USE_I2C
+
+// Use serial if not using I2C
+#ifndef USE_I2C
+# define USE_SERIAL
+#endif
+
+// #define EE_HANDS
+
+#define I2C_MASTER_LEFT
+// #define I2C_MASTER_RIGHT
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* define if matrix has ghost */
+//#define MATRIX_HAS_GHOST
+
+/* number of backlight levels */
+// #define BACKLIGHT_LEVELS 3
+
+/* Set 0 if debouncing isn't needed */
+#define DEBOUNCING_DELAY 5
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+/* key combination for command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
+)
+
+/* ws2812 RGB LED */
+#define RGB_DI_PIN D4
+#define RGBLIGHT_TIMER
+#define RGBLED_NUM 8 // Number of LEDs
+#define RGBLIGHT_HUE_STEP 10
+#define RGBLIGHT_SAT_STEP 17
+#define RGBLIGHT_VAL_STEP 17
+
+/*
+ * Feature disable options
+ * These options are also useful to firmware size reduction.
+ */
+
+/* disable debug print */
+// #define NO_DEBUG
+
+/* disable print */
+// #define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
+
+#endif
diff --git a/keyboards/lets_split/keymaps/serial/keymap.c b/keyboards/lets_split/keymaps/serial/keymap.c
new file mode 100644
index 0000000000..0d2d94b672
--- /dev/null
+++ b/keyboards/lets_split/keymaps/serial/keymap.c
@@ -0,0 +1,214 @@
+#include "lets_split.h"
+#include "action_layer.h"
+#include "eeconfig.h"
+
+extern keymap_config_t keymap_config;
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _QWERTY 0
+#define _COLEMAK 1
+#define _DVORAK 2
+#define _LOWER 3
+#define _RAISE 4
+#define _ADJUST 16
+
+enum custom_keycodes {
+ QWERTY = SAFE_RANGE,
+ COLEMAK,
+ DVORAK,
+ LOWER,
+ RAISE,
+ ADJUST,
+};
+
+// Fillers to make layering more clear
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Qwerty
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | S | D | F | G | H | J | K | L | ; | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | N | M | , | . | / |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_QWERTY] = KEYMAP( \
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
+ KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
+ ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
+),
+
+/* Colemak
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | F | P | G | J | L | U | Y | ; | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | R | S | T | D | H | N | E | I | O | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | K | M | , | . | / |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_COLEMAK] = KEYMAP( \
+ KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC, \
+ KC_ESC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT, \
+ KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
+ ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
+),
+
+/* Dvorak
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | " | , | . | P | Y | F | G | C | R | L | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | O | E | U | I | D | H | T | N | S | / |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| ; | Q | J | K | X | B | M | W | V | Z |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_DVORAK] = KEYMAP( \
+ KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_BSPC, \
+ KC_ESC, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH, \
+ KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_ENT , \
+ ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
+),
+
+/* Lower
+ * ,-----------------------------------------------------------------------------------.
+ * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | | \ | | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | | |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | Next | Vol- | Vol+ | Play |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_LOWER] = KEYMAP( \
+ KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, \
+ KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, \
+ _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS),_______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
+),
+
+/* Raise
+ * ,-----------------------------------------------------------------------------------.
+ * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Del | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / | | |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | Next | Vol- | Vol+ | Play |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_RAISE] = KEYMAP( \
+ KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
+ KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, \
+ _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
+),
+
+/* Adjust (Lower + Raise)
+ * ,-----------------------------------------------------------------------------------.
+ * | | Reset| | | | | | | | | | Del |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | | | |Aud on|Audoff|AGnorm|AGswap|Qwerty|Colemk|Dvorak| | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | | | | | | | | | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_ADJUST] = KEYMAP( \
+ _______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL, \
+ _______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, COLEMAK, DVORAK, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
+)
+
+
+};
+
+#ifdef AUDIO_ENABLE
+float tone_qwerty[][2] = SONG(QWERTY_SOUND);
+float tone_dvorak[][2] = SONG(DVORAK_SOUND);
+float tone_colemak[][2] = SONG(COLEMAK_SOUND);
+#endif
+
+void persistant_default_layer_set(uint16_t default_layer) {
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ case QWERTY:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_qwerty, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_QWERTY);
+ }
+ return false;
+ break;
+ case COLEMAK:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_colemak, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_COLEMAK);
+ }
+ return false;
+ break;
+ case DVORAK:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_dvorak, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_DVORAK);
+ }
+ return false;
+ break;
+ case LOWER:
+ if (record->event.pressed) {
+ layer_on(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case RAISE:
+ if (record->event.pressed) {
+ layer_on(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case ADJUST:
+ if (record->event.pressed) {
+ layer_on(_ADJUST);
+ } else {
+ layer_off(_ADJUST);
+ }
+ return false;
+ break;
+ }
+ return true;
+} \ No newline at end of file
diff --git a/keyboards/lets_split/lets_split.c b/keyboards/lets_split/lets_split.c
index 574c116a75..c505d3a6e3 100644
--- a/keyboards/lets_split/lets_split.c
+++ b/keyboards/lets_split/lets_split.c
@@ -24,7 +24,9 @@ void matrix_init_kb(void) {
};
void shutdown_user(void) {
- PLAY_NOTE_ARRAY(tone_goodbye, false, 0);
- _delay_ms(150);
- stop_all_notes();
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_goodbye, false, 0);
+ _delay_ms(150);
+ stop_all_notes();
+ #endif
}
diff --git a/keyboards/lets_split/matrix.c b/keyboards/lets_split/matrix.c
index 1d768c59b3..1389690042 100644
--- a/keyboards/lets_split/matrix.c
+++ b/keyboards/lets_split/matrix.c
@@ -28,14 +28,18 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "debug.h"
#include "util.h"
#include "matrix.h"
-#include "i2c.h"
-#include "serial.h"
#include "split_util.h"
#include "pro_micro.h"
#include "config.h"
+#ifdef USE_I2C
+# include "i2c.h"
+#else // USE_SERIAL
+# include "serial.h"
+#endif
+
#ifndef DEBOUNCE
-# define DEBOUNCE 5
+# define DEBOUNCE 5
#endif
#define ERROR_DISCONNECT_COUNT 5
@@ -145,6 +149,8 @@ uint8_t _matrix_scan(void)
return 1;
}
+#ifdef USE_I2C
+
// Get rows from other half over i2c
int i2c_transaction(void) {
int slaveOffset = (isLeftHand) ? (ROWS_PER_HAND) : 0;
@@ -176,7 +182,8 @@ i2c_error: // the cable is disconnceted, or something else went wrong
return 0;
}
-#ifndef USE_I2C
+#else // USE_SERIAL
+
int serial_transaction(void) {
int slaveOffset = (isLeftHand) ? (ROWS_PER_HAND) : 0;
@@ -199,7 +206,7 @@ uint8_t matrix_scan(void)
#ifdef USE_I2C
if( i2c_transaction() ) {
-#else
+#else // USE_SERIAL
if( serial_transaction() ) {
#endif
// turn on the indicator led when halves are disconnected
@@ -235,7 +242,7 @@ void matrix_slave_scan(void) {
/* i2c_slave_buffer[i] = matrix[offset+i]; */
i2c_slave_buffer[i] = matrix[offset+i];
}
-#else
+#else // USE_SERIAL
for (int i = 0; i < ROWS_PER_HAND; ++i) {
serial_slave_buffer[i] = matrix[offset+i];
}
@@ -290,7 +297,7 @@ static void init_cols(void)
static matrix_row_t read_cols(void)
{
matrix_row_t result = 0;
- for(int x = 0; x < MATRIX_COLS; x++) {
+ for(int x = 0; x < MATRIX_COLS; x++) {
result |= (_SFR_IO8(col_pins[x] >> 4) & _BV(col_pins[x] & 0xF)) ? 0 : (1 << x);
}
return result;
@@ -298,7 +305,7 @@ static matrix_row_t read_cols(void)
static void unselect_rows(void)
{
- for(int x = 0; x < ROWS_PER_HAND; x++) {
+ for(int x = 0; x < ROWS_PER_HAND; x++) {
_SFR_IO8((row_pins[x] >> 4) + 1) &= ~_BV(row_pins[x] & 0xF);
_SFR_IO8((row_pins[x] >> 4) + 2) |= _BV(row_pins[x] & 0xF);
}
diff --git a/keyboards/lets_split/rules.mk b/keyboards/lets_split/rules.mk
new file mode 100644
index 0000000000..6fde8a444c
--- /dev/null
+++ b/keyboards/lets_split/rules.mk
@@ -0,0 +1,74 @@
+SRC += matrix.c \
+ i2c.c \
+ split_util.c \
+ serial.c
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= yes # Audio output on port C6
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+
+CUSTOM_MATRIX = yes
diff --git a/keyboards/lets_split/serial.c b/keyboards/lets_split/serial.c
index f439c2f20b..6faed09ce0 100644
--- a/keyboards/lets_split/serial.c
+++ b/keyboards/lets_split/serial.c
@@ -10,9 +10,10 @@
#include <avr/interrupt.h>
#include <util/delay.h>
#include <stdbool.h>
-
#include "serial.h"
+#ifdef USE_SERIAL
+
// Serial pulse period in microseconds. Its probably a bad idea to lower this
// value.
#define SERIAL_DELAY 24
@@ -223,3 +224,5 @@ int serial_update_buffers(void) {
sei();
return 0;
}
+
+#endif
diff --git a/keyboards/lets_split/split_util.c b/keyboards/lets_split/split_util.c
index 65003a71a4..461921798f 100644
--- a/keyboards/lets_split/split_util.c
+++ b/keyboards/lets_split/split_util.c
@@ -6,11 +6,15 @@
#include <avr/eeprom.h>
#include "split_util.h"
#include "matrix.h"
-#include "i2c.h"
-#include "serial.h"
#include "keyboard.h"
#include "config.h"
+#ifdef USE_I2C
+# include "i2c.h"
+#else
+# include "serial.h"
+#endif
+
volatile bool isLeftHand = true;
static void setup_handedness(void) {
diff --git a/keyboards/phantom/Makefile b/keyboards/phantom/Makefile
index 3a71fd0ee3..4e2a6f00fd 100644
--- a/keyboards/phantom/Makefile
+++ b/keyboards/phantom/Makefile
@@ -1,74 +1,3 @@
-
-
-SRC = led.c
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-RGBLIGHT_ENABLE ?=yes # Enable keyboard underlight functionality (+4870)
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality (+1150)
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/phantom/rules.mk b/keyboards/phantom/rules.mk
new file mode 100644
index 0000000000..c6b8ca6c35
--- /dev/null
+++ b/keyboards/phantom/rules.mk
@@ -0,0 +1,69 @@
+
+
+SRC = led.c
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+RGBLIGHT_ENABLE ?=yes # Enable keyboard underlight functionality (+4870)
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality (+1150)
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
diff --git a/keyboards/planck/Makefile b/keyboards/planck/Makefile
index 23944f92ea..7d49c5ef96 100644
--- a/keyboards/planck/Makefile
+++ b/keyboards/planck/Makefile
@@ -1,74 +1,5 @@
-
SUBPROJECT_DEFAULT = rev4
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-# Build Options
-# change to "no" to disable the options, or define them in the Makefile in
-# the appropriate keymap folder that will get included automatically
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no # Audio output on port C6
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
-
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/planck/keymaps/bone2planck/config.h b/keyboards/planck/keymaps/bone2planck/config.h
new file mode 100644
index 0000000000..60aff6db0d
--- /dev/null
+++ b/keyboards/planck/keymaps/bone2planck/config.h
@@ -0,0 +1,7 @@
+#ifndef CONFIG_USER_H
+#define CONFIG_USER_H
+#endif
+
+#include "../../config.h"
+
+#define PREVENT_STUCK_MODIFIERS \ No newline at end of file
diff --git a/keyboards/planck/keymaps/bone2planck/keymap.c b/keyboards/planck/keymaps/bone2planck/keymap.c
index 66cf9386df..69d164b8c7 100644
--- a/keyboards/planck/keymaps/bone2planck/keymap.c
+++ b/keyboards/planck/keymaps/bone2planck/keymap.c
@@ -4,6 +4,13 @@
#endif
#include "keymap_german.h"
+// for intellisense, has to be commented for building
+/*
+#include "..\..\..\..\quantum\keymap_extras\keymap_german.h"
+#include "..\..\..\..\quantum\keymap_common.h"
+#include "..\..\..\..\tmk_core\common\keycode.h"
+*/
+
#define _______ KC_TRNS
/* This Layout tries to emulate the Bone2 Variant of Neo2, and is intended to be used with a German QWERTZ Softwarelayout.
@@ -24,14 +31,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | Shift| F | V | Ü | Ä | Ö | Y | Z | , | . | K |Shift |
* |------+------+------+------+------+------+------+------+------+------+------+------|
-* | GUI | Ctrl | Alt | M4 | M2 | Space | M2 | M4 | | Ctrl | Esc |
+* | Ctrl | GUI | Alt | M4 | M2 | Space | M2 | M4 | Alt | Esc | Ctrl |
* `-----------------------------------------------------------------------------------'
*/
[0] = {
- { DE_Q, DE_J, DE_D, DE_U, DE_A, DE_X, DE_P, DE_H, DE_L, DE_M, DE_W, DE_SS },
- { LT(1,KC_TAB), DE_C, DE_T, DE_I, DE_E, DE_O, DE_B, DE_N, DE_R, DE_S, DE_G, LT(1,KC_ENT) },
- { KC_LSFT, DE_F, DE_V, DE_UE, DE_AE, DE_OE, DE_Y, DE_Z, DE_COMM, DE_DOT, DE_K, KC_LSFT },
- { KC_LGUI, KC_LCTL, KC_LALT, MO(4), MO(2), KC_SPC, KC_SPC, MO(2), MO(4), KC_NO, KC_RCTL, KC_ESC }
+ { DE_Q, DE_J, DE_D, DE_U, DE_A, DE_X, DE_P, DE_H, DE_L, DE_M, DE_W, DE_SS },
+ { LT(1,KC_TAB), DE_C, DE_T, DE_I, DE_E, DE_O, DE_B, DE_N, DE_R, DE_S, DE_G, LT(1,KC_ENT) },
+ { KC_LSFT, DE_F, DE_V, DE_UE, DE_AE, DE_OE, DE_Y, DE_Z, DE_COMM, DE_DOT, DE_K, KC_LSFT },
+ { KC_LCTL, KC_RGUI, KC_LALT, MO(4), MO(2), KC_SPC, KC_SPC, MO(2), MO(4), KC_RALT, KC_ESC, KC_RCTL }
},
/* M1 Special Characters
@@ -43,7 +50,7 @@ very ergonomic placement for coding
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | Shift| # | $ | | | ~ | € | + | % | " | ' | ; |Shift |
* |------+------+------+------+------+------+------+------+------+------+------+------|
-* | GUI | Ctrl | Alt | M4 | M2 | Space | M2 | M4 | | Ctrl | Esc |
+* | Ctrl | GUI | Alt | M4 | M2 | Space | M2 | M4 | Alt | Esc | Ctrl |
* `-----------------------------------------------------------------------------------'
*/
[1] = {
@@ -56,37 +63,37 @@ very ergonomic placement for coding
/* Navigation & Number Blocks
very easy to get used to & intuituve placement
* ,-----------------------------------------------------------------------------------.
-* | | PgUp | Bksp | Up | DEL | PgDn | | 7 | 8 | 9 | | |
+* | | PgUp | Bksp | Up | DEL | PgDn | | 7 | 8 | 9 | | Ins |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | Tab | Home | Lft | Down | Right| End | . | 4 | 5 | 6 | , | Enter|
* |------+------+------+------+------+------|------+------+------+------+------+------|
-* | Shift| | Tab | Ins | Enter| | 0 | 1 | 2 | 3 | ; |Shift |
+* | Shift| | Tab | | Enter| | 0 | 1 | 2 | 3 | ; |Shift |
* |------+------+------+------+------+------+------+------+------+------+------+------|
-* | GUI | Ctrl | Alt | M3 | M2 | Space | M2 | M3 | | Ctrl | Esc |
+* | Ctrl | GUI | Alt | M3 | M2 | Space | M2 | M3 | Alt | Esc | Ctrl |
* `-----------------------------------------------------------------------------------'
*/
[2] = {
- { KC_NO, KC_PGUP, KC_BSPC, KC_UP, KC_DEL, KC_PGDN, KC_NO, DE_7, DE_8, DE_9, KC_NO, KC_NO },
+ { KC_NO, KC_PGUP, KC_BSPC, KC_UP, KC_DEL, KC_PGDN, KC_NO, DE_7, DE_8, DE_9, KC_NO, KC_INS },
{ KC_TAB, KC_HOME, KC_LEFT, KC_DOWN, KC_RGHT, KC_END, DE_DOT, DE_4, DE_5, DE_6, DE_COMM, KC_ENT },
- { _______, KC_NO, KC_TAB, KC_INS, KC_ENT, KC_NO, DE_0, DE_1, DE_2, DE_3, DE_SCLN, _______ },
+ { _______, KC_NO, KC_TAB, KC_NO, KC_ENT, KC_NO, DE_0, DE_1, DE_2, DE_3, DE_SCLN, _______ },
{ _______, _______, _______, MO(3), _______, _______, _______, _______, MO(3), _______, _______, _______ }
},
/* Flipped Navigation & Number Blocks for one handed use
accessed by sliding from M2 to M3 with thumb
* ,-----------------------------------------------------------------------------------.
-* | | | 7 | 8 | 9 | | PgUp | Bksp | Up | DEL | PgDn | |
+* | Ins | | 7 | 8 | 9 | | PgUp | Bksp | Up | DEL | PgDn | |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | Tab | . | 4 | 5 | 6 | , | Home | Left | Down | Right| End | Enter|
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | Shift| 0 | 1 | 2 | 3 | ; | | Tab | Ins | Enter| |Shift |
* |------+------+------+------+------+------+------+------+------+------+------+------|
-* | GUI | Ctrl | Alt | M3 | | Space | | M3 | | Ctrl | Esc |
+* | Ctrl | GUI | Alt | M3 | | Space | | M3 | Alt | Esc | Ctrl |
* `-----------------------------------------------------------------------------------'
*/
[3] = {
- { KC_NO, KC_NO, DE_7, DE_8, DE_9, KC_NO, KC_PGUP, KC_BSPC, KC_UP, KC_DEL, KC_PGDN, KC_NO },
+ { KC_INS, KC_NO, DE_7, DE_8, DE_9, KC_NO, KC_PGUP, KC_BSPC, KC_UP, KC_DEL, KC_PGDN, KC_NO },
{ _______, DE_DOT, DE_4, DE_5, DE_6, DE_COMM, KC_HOME, KC_LEFT, KC_DOWN, KC_RGHT, KC_END, _______ },
{ _______, DE_0, DE_1, DE_2, DE_3, DE_SCLN, KC_NO, KC_TAB, KC_INS, KC_ENT, KC_NO, _______ },
{ _______, _______, _______, _______, KC_NO, _______, _______, KC_NO, _______, _______, _______, _______ }
@@ -102,7 +109,7 @@ slide from m4 to m5 to access flipped version
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | Shift| | Prev | Play | Next | | ² | F1 | F2 | F3 | F10 |Shift |
* |------+------+------+------+------+------+------+------+------+------+------+------|
-* | GUI | Ctrl | Alt | M4 | M5 | Space | M5 | M4 | | Ctrl | Esc |
+* | Ctrl | GUI | Alt | M4 | M5 | Space | M5 | M4 | Alt | Esc | Ctrl |
* `-----------------------------------------------------------------------------------'
*/
[4] = {
@@ -115,19 +122,19 @@ slide from m4 to m5 to access flipped version
/* flipped Function & Media Keys
* ,-----------------------------------------------------------------------------------.
-* | | | F7 | F8 | F9 | | | Print|Scroll| Pause| | |
+* | | | F7 | F8 | F9 | F12 | | Print|Scroll| Pause| | |
* |------+------+------+------+------+-------------+------+------+------+------+------|
-* | | ³ | F4 | F5 | F6 | | | Mute | Vol- | Vol+ | | |
+* | | ³ | F4 | F5 | F6 | F11 | | Mute | Vol- | Vol+ | | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
-* | Shift| ² | F1 | F2 | F3 | | | Prev | Play | Next | |Shift |
+* | Shift| ² | F1 | F2 | F3 | F10 | | Prev | Play | Next | |Shift |
* |------+------+------+------+------+------+------+------+------+------+------+------|
-* | GUI | Ctrl | Alt | | M5 | Space | M5 | | | Ctrl | Esc |
+* | Ctrl | GUI | Alt | | M5 | Space | M5 | | Alt | Esc | Ctrl |
* `-----------------------------------------------------------------------------------'
*/
[5] = {
- { KC_NO, KC_NO, KC_F7, KC_F8, KC_F9, KC_NO, KC_NO, KC_PSCR, KC_SLCK, KC_PAUS, KC_NO, KC_NO },
- { KC_NO, DE_SQ3, KC_F4, KC_F5, KC_F6, KC_NO, KC_NO, KC_MUTE, KC_VOLD, KC_VOLU, KC_NO, KC_NO },
- { _______, DE_SQ2, KC_F1, KC_F2, KC_F3, KC_NO, KC_NO, KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, _______ },
+ { KC_NO, KC_NO, KC_F7, KC_F8, KC_F9, KC_F12, KC_NO, KC_PSCR, KC_SLCK, KC_PAUS, KC_NO, KC_NO },
+ { KC_NO, DE_SQ3, KC_F4, KC_F5, KC_F6, KC_F11, KC_NO, KC_MUTE, KC_VOLD, KC_VOLU, KC_NO, KC_NO },
+ { _______, DE_SQ2, KC_F1, KC_F2, KC_F3, KC_F10, KC_NO, KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, _______ },
{ _______, _______, _______, KC_NO, _______, _______, _______, _______, KC_NO, _______, _______, _______ }
}
};
diff --git a/keyboards/planck/keymaps/bone2planck/readme.md b/keyboards/planck/keymaps/bone2planck/readme.md
new file mode 100644
index 0000000000..3c425efddb
--- /dev/null
+++ b/keyboards/planck/keymaps/bone2planck/readme.md
@@ -0,0 +1,8 @@
+check keymap.c to the layers
+
+This Layout tries to emulate the Bone2 Variant of Neo2, and is intended to be used with a German QWERTZ Softwarelayout.
+It has "üäöß" as it is optimized for a mix of German & English.
+My favourite features are the placement of the special characters often used for programming right on the home row
+and the number & navigation block combo, so you never have to move your hands from their home position.
+
+Bone2 wiki page: http://wiki.neo-layout.org/wiki/Bone \ No newline at end of file
diff --git a/keyboards/planck/keymaps/callum/keymap.c b/keyboards/planck/keymaps/callum/keymap.c
index ed187df1da..82ba83f4e4 100644
--- a/keyboards/planck/keymaps/callum/keymap.c
+++ b/keyboards/planck/keymaps/callum/keymap.c
@@ -14,13 +14,21 @@ extern keymap_config_t keymap_config;
#define _BASE 0
#define _MOVE 1
#define _SYMB 2
-#define _FUNC 3
+#define _MOUSE 3
+#define _FUNC 4
enum planck_keycodes {
- BASE = SAFE_RANGE,
- MOVE,
+ MOVE = SAFE_RANGE,
SYMB,
- FUNC
+ FUNC,
+ CMDLEFT,
+ CMDRGHT,
+ BELOW,
+ ABOVE,
+ DASH,
+ GBP,
+ VOLUP,
+ VOLDN
};
// Fillers to make layering more clear
@@ -32,73 +40,91 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* BASE
* ,-----------------------------------------------------------------------------------.
* | Tab | Q | W | F | P | G | J | L | U | Y | ; | - |
- * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
* | Bksp | A | R | S | T | D | H | N | E | I | O | " |
- * |------+------+------+------+------+------|------+------+------+------+------+------|
- * | Shift| Z | X | C | V | B | K | M | , | . | / |Shift |
* |------+------+------+------+------+------+------+------+------+------+------+------|
- * | Func | GUI | Alt | Ctrl | Symb |Enter |Space | Move | GUI | Alt | Ctrl |Caps |
+ * | Shift| Z | X | C | V | B | K | M | , | . | / | Shift|
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Func | Ctrl | Alt | Cmd | Symb | Enter| Space| Move | Cmd | Alt | Ctrl | Func |
* `-----------------------------------------------------------------------------------'
*/
[_BASE] = {
{KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_MINS},
{KC_BSPC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT},
{KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT},
- {FUNC, KC_LGUI, KC_LALT, KC_LCTL, SYMB, KC_ENT, KC_SPC, MOVE, KC_RGUI, KC_RALT, KC_RCTL, KC_CAPS}
+ {FUNC, KC_LCTL, KC_LALT, KC_LGUI, SYMB, KC_ENT, KC_SPC, MOVE, KC_RGUI, KC_RALT, KC_RCTL, FUNC }
},
/* MOVE
* ,-----------------------------------------------------------------------------------.
- * | Esc | | Home | Up | End | | | Home | Up | End | | Esc |
- * |------+------+------+------+------+-------------+------+------+------+------+------|
- * | Del | | Left | Down |Right | | | Left | Down |Right | | Del |
- * |------+------+------+------+------+------|------+------+------+------+------+------|
- * | | | |Pg Up |Pg Dn | | |Pg Dn |Pg Up | | | |
+ * | Esc | | Cmd-L| Up | Cmd-R| | | Cmd-L| Up | Cmd-R| | Esc |
* |------+------+------+------+------+------+------+------+------+------+------+------|
- * | | | | | | | | | | | | |
+ * | Del | | Left | Down | Right| | | Left | Down | Right| | Del |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | Pg Up| Pg Dn| Above| | Pg Dn| Pg Up| | Caps | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | Below| | | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_MOVE] = {
- {KC_ESC, _______, KC_HOME, KC_UP, KC_END, _______, _______, KC_HOME, KC_UP, KC_END, _______, KC_ESC},
- {KC_DEL, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_DEL},
- {_______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, KC_PGDN, KC_PGUP, _______, _______, _______},
- {_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______}
+ {KC_ESC, XXXXXXX, CMDLEFT, KC_UP, CMDRGHT, XXXXXXX, XXXXXXX, CMDLEFT, KC_UP, CMDRGHT, XXXXXXX, KC_ESC },
+ {KC_DEL, KC_CAPS, KC_LEFT, KC_DOWN, KC_RGHT, XXXXXXX, XXXXXXX, KC_LEFT, KC_DOWN, KC_RGHT, KC_CAPS, KC_DEL },
+ {_______, XXXXXXX, XXXXXXX, KC_PGUP, KC_PGDN, ABOVE, XXXXXXX, KC_PGDN, KC_PGUP, XXXXXXX, XXXXXXX, _______},
+ {_______, _______, _______, _______, _______, BELOW, _______, _______, _______, _______, _______, _______}
},
/* SYMB
* ,-----------------------------------------------------------------------------------.
- * | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Esc |
- * |-----------------------------------------------------------------------------------.
- * | Del | ! | @ | # | $ | % | ^ | & | * | ( | ) | Del |
- * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | – |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Del | ! | @ | # | $ | % | ^ | & | * | ( | ) | £ |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
* | | ~ | ` | + | = | | | \ | [ | ] | { | } | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | | | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_SYMB] = {
- {KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_ESC },
- {KC_DEL, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_DEL },
+ {KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, DASH },
+ {KC_DEL, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, GBP },
{_______, KC_TILD, KC_GRV, KC_PLUS, KC_EQL, KC_PIPE, KC_BSLS, KC_LBRC, KC_RBRC, KC_LCBR, KC_RCBR, _______},
{_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______}
},
+/* MOUSE
+ * ,-----------------------------------------------------------------------------------.
+ * | | | ACC-2| ACC-1| ACC-0| | | SW-L | M-U | SW-R | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | MB-3 | MB-2 | MB-1 | | | M-L | M-D | M-R | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | SW-D | SW-U | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_MOUSE] = {
+ {XXXXXXX, XXXXXXX, KC_ACL2, KC_ACL1, KC_ACL0, XXXXXXX, XXXXXXX, KC_WH_L, KC_MS_U, KC_WH_R, XXXXXXX, XXXXXXX},
+ {XXXXXXX, XXXXXXX, KC_BTN3, KC_BTN2, KC_BTN1, XXXXXXX, XXXXXXX, KC_MS_L, KC_MS_D, KC_MS_R, XXXXXXX, XXXXXXX},
+ {_______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_WH_D, KC_WH_U, XXXXXXX, XXXXXXX, _______},
+ {_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______}
+},
+
/* FUNC
* ,-----------------------------------------------------------------------------------.
- * | F12 | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 |
- * |-----------------------------------------------------------------------------------.
- * | | Play | Prev | Next | BL+ | | | | | | | |
- * |------+------+------+------+------+------|------+------+------+------+------+------|
- * | | Mute | Vol- | Vol+ | BL- | | | | | | | |
+ * | Reset| F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | Vol+ |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | F11 | F12 | F13 | F14 | F15 | F16 | F17 | F18 | F19 | F20 | Vol- |
* |------+------+------+------+------+------+------+------+------+------+------+------|
- * | | | | | | | | | | | |Reset |
+ * | | F21 | F22 | F23 | F24 | | | | | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | Prev | Mute | Play | Next | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_FUNC] = {
- {KC_F12, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11 },
- {_______, KC_MPLY, KC_MPRV, KC_MNXT, KC_PAUS, _______, _______, _______, _______, _______, _______, _______},
- {_______, KC_MUTE, KC_VOLD, KC_VOLU, KC_SLCK, _______, _______, _______, _______, _______, _______, _______},
- {_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RESET }
+ {RESET, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, VOLUP },
+ {XXXXXXX, KC_F11, KC_F12, KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, VOLDN },
+ {_______, KC_F21, KC_F22, KC_F23, KC_F24, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______},
+ {_______, _______, _______, _______, KC_MPRV, KC_MUTE, KC_MPLY, KC_MNXT, _______, _______, _______, _______}
}
};
@@ -108,20 +134,20 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
case MOVE:
if (record->event.pressed) {
layer_on(_MOVE);
- update_tri_layer(_MOVE, _SYMB, _FUNC);
+ update_tri_layer(_MOVE, _SYMB, _MOUSE);
} else {
layer_off(_MOVE);
- update_tri_layer(_MOVE, _SYMB, _FUNC);
+ update_tri_layer(_MOVE, _SYMB, _MOUSE);
}
return false;
break;
case SYMB:
if (record->event.pressed) {
layer_on(_SYMB);
- update_tri_layer(_MOVE, _SYMB, _FUNC);
+ update_tri_layer(_MOVE, _SYMB, _MOUSE);
} else {
layer_off(_SYMB);
- update_tri_layer(_MOVE, _SYMB, _FUNC);
+ update_tri_layer(_MOVE, _SYMB, _MOUSE);
}
return false;
break;
@@ -133,6 +159,94 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
}
return false;
break;
+ case CMDLEFT:
+ if (record->event.pressed) {
+ register_code(KC_LGUI);
+ register_code(KC_LEFT);
+ } else {
+ unregister_code(KC_LEFT);
+ unregister_code(KC_LGUI);
+ }
+ return false;
+ break;
+ case CMDRGHT:
+ if (record->event.pressed) {
+ register_code(KC_LGUI);
+ register_code(KC_RGHT);
+ } else {
+ unregister_code(KC_RGHT);
+ unregister_code(KC_LGUI);
+ }
+ return false;
+ break;
+ case BELOW:
+ if (record->event.pressed) {
+ register_code(KC_LGUI);
+ register_code(KC_RGHT);
+ unregister_code(KC_RGHT);
+ unregister_code(KC_LGUI);
+ register_code(KC_ENT);
+ unregister_code(KC_ENT);
+ }
+ return false;
+ break;
+ case ABOVE:
+ if (record->event.pressed) {
+ register_code(KC_LGUI);
+ register_code(KC_LEFT);
+ unregister_code(KC_LEFT);
+ unregister_code(KC_LGUI);
+ register_code(KC_ENT);
+ unregister_code(KC_ENT);
+ register_code(KC_UP);
+ unregister_code(KC_UP);
+ }
+ return false;
+ break;
+ case DASH:
+ if (record->event.pressed) {
+ register_code(KC_LALT);
+ register_code(KC_MINS);
+ } else {
+ unregister_code(KC_MINS);
+ unregister_code(KC_LALT);
+ }
+ return false;
+ break;
+ case GBP:
+ if (record->event.pressed) {
+ register_code(KC_LALT);
+ register_code(KC_3);
+ } else {
+ unregister_code(KC_3);
+ unregister_code(KC_LALT);
+ }
+ return false;
+ break;
+ case VOLUP:
+ if (record->event.pressed) {
+ register_code(KC_LALT);
+ register_code(KC_LSFT);
+ register_code(KC_VOLU);
+ } else {
+ unregister_code(KC_VOLU);
+ unregister_code(KC_LSFT);
+ unregister_code(KC_LALT);
+ }
+ return false;
+ break;
+ case VOLDN:
+ if (record->event.pressed) {
+ register_code(KC_LALT);
+ register_code(KC_LSFT);
+ register_code(KC_VOLD);
+ } else {
+ unregister_code(KC_VOLD);
+ unregister_code(KC_LSFT);
+ unregister_code(KC_LALT);
+ }
+ return false;
+ break;
}
return true;
}
diff --git a/keyboards/planck/keymaps/callum/readme.md b/keyboards/planck/keymaps/callum/readme.md
index 030def7f77..b5997cd5ae 100644
--- a/keyboards/planck/keymaps/callum/readme.md
+++ b/keyboards/planck/keymaps/callum/readme.md
@@ -1,48 +1,71 @@
# callum’s planck layout
-This is a layout for the grid planck, built with a few ideals in mind. These ideals are just my opinion mind! The great thing about *qmk* is that we can all afford to have different opinions about what makes a good layout:
+This is a layout for the grid planck, built with a few ideals in mind:
-- Minimal response times should be maintained. i.e. keys that react differently depending on whether they are tapped or held, keys that react differently if they are double tapped, etc. should be avoided --- since they inevitably send their keycode later than a normal key, interrupting the immediate feedback from the screen. Therefore we restrict ourselves to chording.
+- Minimal response times should be maintained. Keys that react differently depending on whether they are tapped or held, keys that react differently if they are double tapped, etc. should be avoided – they inevitably send their keycode later than a normal key – interrupting the immediate feedback from the screen. Therefore we restrict ourselves to chording as our only means of getting more than one symbol out of a single physical key.
- The hands should never need to leave the home position. The usual culprit for this is the arrow cluster, so the arrow cluster should be as close to home as possible.
-- There should be two of every modifier (one on each side), since otherwise certain long key combinations become hard to make.
-- Backspace should be in the “capslock position” as God intended.
-- The keyboard should be usable without any firmware changes on any operating system. In my case that means it should work on *Windows* and *Linux* without any software modifications, while I can change the behaviour slightly on *macOS* in software since that’s my home OS. The images reflect the intended use on *macOS* **after** minor software tweaks; which will be noted.
-
-We have four layers. A `BASE` layer, in colemak; a `MOVE` layer, with an arrow cluster etc, a `SYMB` layer, with numbers and symbols; and a `FUNC` layer, with function keys and media keys.
-
-## The `BASE` layer
-![](http://i.imgur.com/aEXOlWl.png)
-
-This is the default layer; in [colemak](https://colemak.com). `esc` and `del` are conspicuously absent but are especially easy to reach from either of the other main layers (see below). The `backspace` location is standard colemak. The `caps` key is still on the `BASE` layer but only because I don’t really use the bottom corners so there’s nothing else I would rather put there. Having `enter` on a thumb means I can still have `quote` immediately to the right of `O`, something that would have annoyed me endlessly otherwise. `minus` is in the upper right because I had an extra space and it’s probably my next most used key that didn’t yet have a home.
-
-The `MOVE` and `SYMB` layers are reached by holding down the `move` and `symb` keys respectively. The `FUNC` layer is reached by holding down both the `move` and `symb` keys simultaneosly, *or* by holding down the `fn` key. The intended use is that whenever both hands are on the keyboard, the former method is used, and the latter is only used when, for example, reaching over to the keyboard with one hand to access the media controls.
-
-The `ctrl`, `alt`, `cmd` cluster is asymmetric around the centre so that at least one of each of the modifiers can be reached with the thumbs. The intended use is to always hit the left `cmd` and the right `ctrl`, unless an awkward key combination dictates otherwise.
-
-In firmware `ctrl` and `cmd`/`GUI` are swapped with respect to the image above --- I swap them to the illustrated location when using *macOS* and leave them be for *Windows* and *Linux*. (so that `cmd-z,x,c,v,...` becomes `ctrl-z,x,c,v,...` saving me some confusion)
-
-## The `MOVE` layer
-![](http://i.imgur.com/KXRSuHT.png)
-
-This is fairly self explanatory. I almost exclusively use the right hand cluster so that movement is a one handed affair, but the left hand cluster is there if it’s needed.
-
-On *macOS* I recommend using [Karabiner](https://pqrs.org/osx/karabiner/) and ticking *Use PC Style Home/End #2* and *Use PC Style PageUp/PageDown* so that `home` and `end` jump you to the beginning and end of the line respectively and so that `pg up` and `pg dn` move the cursor instead of just scrolling.
-
-None of the modifiers are overwritten so that `shift-alt-arrows` etc work as expected.
-
-## The `SYMB` layer
-![](http://i.imgur.com/thh1ne2.png)
-
-The symbol layer has all the numbers and their usual corresponding symbols in the first two rows, with the symbols on the home row since I use them more frequently than the numbers. The third row contains all the remaining symbols, arranged roughly so that the most used symbols are accessible with the strongest fingers.
-
-`esc` and `del` are repeated here since I wanted to be able to reach either, one handed, with either hand.
-
-Again none of the modifiers are overwritten so that shortcuts involving numbers or symbols work as expected.
-
-## The `FUNC` layer
-![](http://i.imgur.com/skxRZiH.png)
-
-The only thing of note here is that `bl+` and `bl-` are short for *backlight up* and *backlight down* respectively, and in firmware are actually `KC_PAUS` and `KC_SLCK` respectively, since *macOS* interprets these as the backlight keys.
-
-## Other changes from the default
-I have LEDs and sound disabled, simply because I have no need of them. \ No newline at end of file
+- There should be two of every modifier (one on each side), otherwise certain long key combinations become hard to make.
+
+We have five layers. A `BASE` layer, in colemak; a `MOVE` layer, with an arrow cluster and other movement keys; a `SYMB` layer, with numbers and symbols; a `FUNC` layer, with function keys and media keys; and a `MOUSE` layer, with mouse emulation.
+
+```
+/* BASE
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | F | P | G | J | L | U | Y | ; | - |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Bksp | A | R | S | T | D | H | N | E | I | O | " |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | K | M | , | . | / | Shift|
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Func | Ctrl | Alt | Cmd | Symb | Enter| Space| Move | Cmd | Alt | Ctrl | Func |
+ * `-----------------------------------------------------------------------------------'
+ */
+
+/* MOVE
+ * ,-----------------------------------------------------------------------------------.
+ * | Esc | | Cmd-L| Up | Cmd-R| | | Cmd-L| Up | Cmd-R| | Esc |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Del | | Left | Down | Right| | | Left | Down | Right| | Del |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | Pg Up| Pg Dn| Above| | Pg Dn| Pg Up| | Caps | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | Below| | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+
+/* SYMB
+ * ,-----------------------------------------------------------------------------------.
+ * | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | – |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Del | ! | @ | # | $ | % | ^ | & | * | ( | ) | £ |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | ~ | ` | + | = | | | \ | [ | ] | { | } | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+
+/* MOUSE
+ * ,-----------------------------------------------------------------------------------.
+ * | | | ACC-2| ACC-1| ACC-0| | | SW-L | M-U | SW-R | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | MB-3 | MB-2 | MB-1 | | | M-L | M-D | M-R | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | SW-D | SW-U | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+
+/* FUNC
+ * ,-----------------------------------------------------------------------------------.
+ * | Reset| F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | Vol+ |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | F11 | F12 | F13 | F14 | F15 | F16 | F17 | F18 | F19 | F20 | Vol- |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | F21 | F22 | F23 | F24 | | | | | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | Prev | Mute | Play | Next | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+```
diff --git a/keyboards/planck/keymaps/cbbrowne/config.h b/keyboards/planck/keymaps/cbbrowne/config.h
index 2d3df59bd2..1e04ba61d7 100644
--- a/keyboards/planck/keymaps/cbbrowne/config.h
+++ b/keyboards/planck/keymaps/cbbrowne/config.h
@@ -3,13 +3,19 @@
#include "../../config.h"
+#define LEADER_TIMEOUT 300
+#define BACKLIGHT_BREATHING
+
/* cbbrowne user configuration */
#define randadd 53
#define randmul 181
#define randmod 167
-#endif
+/* Filler to make layering a bit clearer *
+ * borrowed from basic keymap */
+#define _______ KC_TRNS
+#endif
diff --git a/keyboards/planck/keymaps/cbbrowne/keymap.c b/keyboards/planck/keymaps/cbbrowne/keymap.c
index 70eaefb7be..7f1601af75 100644
--- a/keyboards/planck/keymaps/cbbrowne/keymap.c
+++ b/keyboards/planck/keymaps/cbbrowne/keymap.c
@@ -1,6 +1,6 @@
#include "planck.h"
#ifdef BACKLIGHT_ENABLE
- #include "backlight.h"
+#include "backlight.h"
#endif
#include "config.h"
#include "quantum.h"
@@ -65,10 +65,11 @@
*/
enum layers {
- _QW = 0, /* Qwerty mapping */
- _LW, /* Lower layer, where top line has symbols !@#$%^&*() */
- _RS, /* Raised layer, where top line has digits 1234567890 */
- _KP, /* Key pad */
+ _QWERTY = 0, /* Qwerty mapping */
+ _LOWER, /* Lower layer, where top line has symbols !@#$%^&*() */
+ _RAISE, /* Raised layer, where top line has digits 1234567890 */
+ _KEYPAD, /* Key pad */
+ _ADJUST, /* Special Adjust layer coming via tri-placement */
};
enum macro_id {
@@ -76,38 +77,63 @@ enum macro_id {
M_USERNAME,
M_RANDDIGIT,
M_RANDLETTER,
- M_VERSION
+ M_VERSION,
+ MACRO_UPPER,
+ MACRO_LOWER,
};
+#define M_LOWER M(MACRO_LOWER)
+#define M_UPPER M(MACRO_UPPER)
+#define ROT_LED M(M_LED) /* Rotate LED */
+#define QWERTY DF(_QWERTY) /* Switch to QWERTY layout */
+#define KEYPAD DF(_KEYPAD) /* Switch to keypad */
+#define USERNAME M(M_USERNAME) /* shortcut for username */
+#define RANDDIG M(M_RANDDIGIT)
+#define RANDALP M(M_RANDLETTER)
+#define CTLENTER MT(MOD_RCTL, KC_ENT)
+#define SHIFTQUOTE MT(MOD_RSFT, KC_QUOT)
+#define ALTRIGHT MT(MOD_LALT, KC_RGHT)
+#define MVERSION M(M_VERSION)
+
+
/* Note that Planck has dimensions 4 rows x 12 columns */
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
-[_QW] = { /* Qwerty */
+[_QWERTY] = { /* Qwerty */
{KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC},
- {KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT},
- {KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_QUOT },
- {KC_TAB, M(M_LED), KC_LALT, KC_LGUI, MO(_LW), KC_SPC, KC_SPC, MO(_RS), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT}
+ {KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, CTLENTER},
+ {KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, SHIFTQUOTE },
+ {KC_TAB, KC_LALT, ROT_LED, KC_LGUI, M_LOWER, KC_SPC, KC_SPC, M_UPPER, KC_LEFT, KC_DOWN, KC_UP, ALTRIGHT}
+ /* Note that KC_SPC is recorded TWICE, so that either matrix position can activate it */
},
-[_RS] = { /* RAISE */
+[_RAISE] = { /* RAISE */
{KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC},
- {KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS},
- {KC_TRNS, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, DF(_QW), DF(_KP), DF(_KP), RESET, KC_TRNS},
- {KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY}
+ {_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS},
+ {_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, QWERTY, KEYPAD, KEYPAD, RESET, _______},
+ {_______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY}
},
-[_LW] = { /* LOWER */
+[_LOWER] = { /* LOWER */
{KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC},
- {KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE},
- {KC_TRNS, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, DF(_QW), DF(_KP), DF(_KP), RESET, KC_TRNS},
- {KC_TRNS, DF(_KP), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY}
+ {_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE},
+ {_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, QWERTY, KEYPAD, KEYPAD, RESET, _______},
+ {_______, KEYPAD, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY}
+ },
+[_KEYPAD] = { /* Key Pad */
+ {KC_ESC, USERNAME, MVERSION, KC_F10, KC_F11, KC_F12, KC_PGUP, KC_KP_ENTER, KC_7, KC_8, KC_9, KC_BSPC},
+ {KC_LCTL, RANDDIG, KC_F5, KC_F6, KC_F7, KC_F8, KC_PGDN, KC_KP_MINUS, KC_4, KC_5, KC_6, KC_PIPE},
+ {KC_LSFT, RANDALP, KC_F1, KC_F2, KC_F3, KC_F4, KC_DEL, KC_KP_PLUS, KC_1, KC_2, KC_3, KC_ENTER},
+ {KC_TAB, KC_LALT, ROT_LED, KC_LGUI, M_LOWER, KC_SPC, KC_SPC, QWERTY, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT}
},
-[_KP] = { /* Key Pad */
- {KC_ESC, M(M_USERNAME), M(M_VERSION), KC_F10, KC_F11, KC_F12, KC_PGUP, KC_KP_ENTER, KC_7, KC_8, KC_9, KC_BSPC},
- {KC_LCTL, M(M_RANDDIGIT), KC_F5, KC_F6, KC_F7, KC_F8, KC_PGDN, KC_KP_MINUS, KC_4, KC_5, KC_6, KC_PIPE},
- {KC_LSFT, M(M_RANDLETTER), KC_F1, KC_F2, KC_F3, KC_F4, KC_DEL, KC_KP_PLUS, KC_1, KC_2, KC_3, KC_ENTER},
- {BL_STEP, M(M_LED), KC_LALT, KC_LGUI, KC_NO, KC_SPC, KC_SPC, DF(_QW), KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT}
-}
+
+[_ADJUST] = { /* Adjustments - gonna shift the wild tools in here */
+ {ROT_LED,USERNAME,MVERSION, _______, _______, _______, _______, _______, _______, _______, _______, _______ },
+ {_______, RANDDIG, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ },
+ {_______, RANDALP, _______, _______, _______, RESET, RESET, _______, _______, _______, _______, _______ },
+ {_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ }
+}
};
+/* What is fn_actions actually used for??? */
const uint16_t PROGMEM fn_actions[] = {
};
@@ -169,6 +195,39 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
unregister_code (KC_A + rval);
}
break;
+ case MACRO_UPPER:
+ if (record->event.pressed)
+ {
+ layer_on(_RAISE);
+#ifdef BACKLIGHT_ENABLE
+ breathing_speed_set(2);
+ breathing_pulse();
+#endif
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ else
+ {
+ layer_off(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ break;
+ case MACRO_LOWER:
+ if (record->event.pressed)
+ {
+ layer_on(_LOWER);
+#ifdef BACKLIGHT_ENABLE
+ breathing_speed_set(2);
+ breathing_pulse();
+#endif
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ else
+ {
+ layer_off(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ break;
+
}
return MACRO_NONE;
};
diff --git a/keyboards/planck/keymaps/cbbrowne/readme.md b/keyboards/planck/keymaps/cbbrowne/readme.md
index c676dd2c1c..184142e0c1 100644
--- a/keyboards/planck/keymaps/cbbrowne/readme.md
+++ b/keyboards/planck/keymaps/cbbrowne/readme.md
@@ -7,16 +7,10 @@ Christopher Browne
This was originally based on the default keyboard map, but I have been
doing sundry experimentation:
-1. Experiments
+1. Useful Experiments
----------------------------------------
- * To figure things out about the toolset
- * I'm an Emacs guy, so will be needing a fair bit of tuning
* It made sense to mess around some with keyboard maps.
- - I tried added Workman alongside Dvorak and Colemak
- - Boy, oh boy, these don't help!!!
- - I have done 30 years of learning of Emacs key mappings, and
- these alternative keyboards massively mess me up
- I added a keypad, originally based on keymaps/numpad.c, but
mighty substantially revised, as that one seems to be rotated 90
degrees from usual conventions for number pads
@@ -30,6 +24,26 @@ doing sundry experimentation:
- Key [2][2] aka "a" uses a random number generator to select a digit 0-9 at random
- Key [3][2] aka "z" uses a random number generator to select a letter a-z at random
- Key [1][3] aka "e" spits out the keymap version number
+ * Trying out sgoodwin's "hold Enter down to get Shift"
+ - Liking this Quite Well Enough...
+ - Applied this to both Shift and Quote
+ - It seems likely that Alt should get a right-hand-side, akin to this...
+ - Alt needs to move, and get a RHS
+ - Hence ALTRIGHT, and shifted ROT_LED over
+ - Emacs likes this!!! :-)
+ - I'm suspicious that I'll want to shift ROT_LED another location over,
+ so some modifier can replace the OS/KC_LGUI key
+ * I have added an alternate ADJUST layer that is activated via update_tri_layer()
+ - e.g. - LOWER+RAISE simultaneously
+ - This seems entirely more useful for handling my "special keys"
+ like the random numbers, user name, and such, than the keypad layer
+ * The _ADJUST layer provides a good place to have RESET
+ - But this isn't strictly enough; I want RESET somewhat accessible from
+ main layer lest an error hide that layer
+ - I never use the OS/KC_LGUI key (that's Command on MacOS, Windows
+ Key on Windows), so that's a good place to have it as a chord of
+ some sort
+
2. Some code structure ideas
---------------------------------------------------
@@ -48,8 +62,8 @@ doing sundry experimentation:
only need to fit 4 symbols onto each line, rather than 12.
I used enums to manage layer IDs and macro IDs so that I don't need
- to care (beyond "start at 0", and arguably that's not needed) about
- their values.
+ to care (beyond "start at 0", and arguably even that's not needed)
+ about their values.
3. Things I did not like about the default mapping
---------------------------------------------------------
@@ -62,3 +76,38 @@ doing sundry experimentation:
and shift ESC off the first column so KC_LCTL and KC_LALT can
be on the first column.
* I needed to swap ' and ENTER
+
+4. Unuseful experiments
+---------------------------------------------------------
+
+I have tried some things out that didn't turn out particularly well.
+I'll note some of these for posterity, hopefully helpful in not doing
+unwise things again...
+
+ * I tried added Workman alongside Dvorak and Colemak
+ - Boy, oh boy, these don't help!!!
+ - I have done 30 years of learning of Emacs key mappings, and
+ these alternative keyboards massively mess me up
+
+ * Space Cadet Shift; switching L_SHIFT to KC_LSP0, so that when I
+ just hit SHIFT, I get a left parens. In principle, this is great
+ for Lisping.
+ - Unfortunately, there are times when mouse interfaces use SHIFT
+ to allow selecting multiple items, and this really interferes
+ with that
+
+5. TODO
+---------------------------------------------------------
+
+ * I use tmux quite a lot; the mollat keymap seems to have some
+ interesting helpers. It might be interesting to add a "tmux
+ layer," or to have a few keys in a layer oriented towards that
+ * The mollat tmux layer also suggests some thoughts about Emacs
+ helpers.
+ * I do not presently have anything that handles X11 screen
+ switching, as with Control-Alt-various
+ * I ought to probably look into KC_LEAD, to have some key combos
+ that do not need to be concurrent
+ * The jeebak keymap seems to have some neat ideas:
+ - Number layer which is aggressive about having numbers in several places
+ - Touch layer seems interesting
diff --git a/keyboards/planck/keymaps/impossible/Makefile b/keyboards/planck/keymaps/impossible/Makefile
new file mode 100644
index 0000000000..581e08cd02
--- /dev/null
+++ b/keyboards/planck/keymaps/impossible/Makefile
@@ -0,0 +1,25 @@
+
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
+CONSOLE_ENABLE = no # Console for debug(+400)
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+MIDI_ENABLE = no # MIDI controls
+AUDIO_ENABLE = yes # Audio output on port C6
+UNICODE_ENABLE = no # Unicode
+BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/planck/keymaps/impossible/keymap.c b/keyboards/planck/keymaps/impossible/keymap.c
new file mode 100644
index 0000000000..503976fa28
--- /dev/null
+++ b/keyboards/planck/keymaps/impossible/keymap.c
@@ -0,0 +1,242 @@
+// This is the canonical layout file for the Quantum project. If you want to add another keyboard,
+// this is the style you want to emulate.
+
+#include "planck.h"
+#include "action_layer.h"
+#ifdef AUDIO_ENABLE
+ #include "audio.h"
+#endif
+#include "eeconfig.h"
+
+extern keymap_config_t keymap_config;
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+
+#define _WORKMAN 0
+#define _FN 1
+#define _QWERTY 2
+#define _QW_FN 3
+#define _PLOVER 4
+#define _ADJ 5
+
+enum planck_keycodes {
+ WORKMAN = SAFE_RANGE,
+ QWERTY,
+ PLOVER
+};
+
+// Fillers to make layering more clear
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Workman Alpha-numeric
+ * ,-----------------------------------------------------------------------------------------------.
+ * | Q | D | R | W | B | F | U | P | J | 7 | 8 | 9 |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * | A | S | H | T | G | N | E | O | I | 4 | 5 | 6 |
+ * |-------+-------+-------+-------+-------+-------|-------+-------+-------+-------+-------+-------|
+ * | Z | X | M | C | V | L | Y | K | Up | 1 | 2 | 3 |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * |Alt/Tab|Gui/Esc| , |CTL/Bsp| Fn/Ent|SFT/SPC| . | Left | Down | Right | 0 |Adj/Ent|
+ * `-----------------------------------------------------------------------------------------------'
+ */
+
+[_WORKMAN] = {
+ {KC_Q, KC_D, KC_R, KC_W, KC_B, KC_F, KC_U, KC_P, KC_J, KC_KP_7, KC_KP_8, KC_KP_9},
+ {KC_A, KC_S, KC_H, KC_T, KC_G, KC_N, KC_E, KC_O, KC_I, KC_KP_4, KC_KP_5, KC_KP_6},
+ {KC_Z, KC_X, KC_M, KC_C, KC_V, KC_L, KC_Y, KC_K, KC_UP, KC_KP_1, KC_KP_2, KC_KP_3},
+ {ALT_T(KC_TAB), GUI_T(KC_ESC), KC_COMM, CTL_T(KC_BSPC), LT(_FN, KC_ENT), SFT_T(KC_SPC), KC_DOT, KC_LEFT, KC_DOWN, KC_RGHT, KC_KP_0, LT(_ADJ, KC_ENT)}
+},
+
+/* FN-key held (Workman)
+ * ,-----------------------------------------------------------------------------------------------.
+ * | ! | @ | # | $ | % | ^ | & | * | F12 | F7 | F8 | F9 |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * | Tab | [ | ] | - | Del | ' | ( | ) | F11 | F4 | F5 | F6 |
+ * |-------+-------+-------+-------+-------+-------|-------+-------+-------+-------+-------+-------|
+ * | Menu | | | = | \ | / | | | PgUp | F1 | F2 | F3 |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * |Alt/Tab| Gui | ~ |CTL/Bsp| Fn/Ent|SFT/Spc| ; | Home | PgDn | End | F10 |Adj/Ent|
+ * `-----------------------------------------------------------------------------------------------'
+ */
+
+[_FN] = {
+ {KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_F12, KC_F7, KC_F8, KC_F9},
+ {KC_TAB, KC_LBRACKET, KC_RBRACKET, KC_MINUS, KC_DELETE, KC_QUOT, KC_LPRN, KC_RPRN, KC_F11, KC_F4, KC_F5, KC_F6},
+ {KC_MENU, _______, _______, KC_EQUAL, KC_BSLS, KC_SLSH, XXXXXXX, XXXXXXX, KC_PGUP, KC_F1, KC_F2, KC_F3},
+ {_______, KC_LGUI, KC_GRAVE, _______, _______, _______, KC_SCOLON, KC_HOME, KC_PGDN, KC_END, KC_F10, _______}
+},
+
+/* Qwerty
+ * ,-----------------------------------------------------------------------------------------------.
+ * |Gui/Esc| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
+ * |-------+-------+-------+-------+-------+---------------+-------+-------+-------+-------+-------|
+ * | Ctrl | Q | W | E | R | T | Y | U | I | O | P | / |
+ * |-------+-------+-------+-------+-------+---------------+-------+-------+-------+-------+-------|
+ * | Shift | A | S | D | F | G | H | J | K | L | ; | " |
+ * |-------+-------+-------+-------+-------+-------|-------+-------+-------+-------+-------+-------|
+ * |Alt/Tab| Z | X | C | V | Fn/SPC| B | N | M | , | . |Adj/Ent|
+ * `-----------------------------------------------------------------------------------------------'
+ */
+
+[_QWERTY] = {
+ {GUI_T(KC_ESC), KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC},
+ {KC_LCTL, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_ENT},
+ {KC_LSFT, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT},
+ {ALT_T(KC_TAB), KC_Z, KC_X, KC_C, KC_V, LT(_QW_FN, KC_SPC), KC_B, KC_N, KC_M, KC_COMM, KC_DOT, LT(_ADJ, KC_ENT)},
+},
+
+/* FN-key held (Qwerty)
+ * ,-----------------------------------------------------------------------------------------------.
+ * | Gui | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * | Ctrl | ~ | [ | PgUp | ] | | | - | Up | = | | F12 |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * | Shift | Tab | Home | PgDn | End | Del | | Left | Down | Right | | |
+ * |-------+-------+-------+-------+-------+-------|-------+-------+-------+-------+-------+-------|
+ * |Alt/Tab| | | | | Fn/Spc| | | | | Menu |Adj/Ent|
+ * `-----------------------------------------------------------------------------------------------'
+ */
+
+[_QW_FN] = {
+ {KC_LGUI, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11},
+ {_______, KC_GRAVE, KC_LBRC, KC_PGUP, KC_RBRC, XXXXXXX, XXXXXXX, KC_MINS, KC_UP, KC_EQUAL, XXXXXXX, KC_F12},
+ {_______, KC_TAB, KC_HOME, KC_PGDN, KC_END, KC_DELETE, XXXXXXX, KC_LEFT, KC_DOWN, KC_RIGHT, XXXXXXX, XXXXXXX},
+ {_______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, XXXXXXX, _______, _______, _______, KC_MENU, _______}
+},
+
+/* Plover layer (http://opensteno.org)
+ * ,-----------------------------------------------------------------------------------------------.
+ * | S | T | P | H | * | F | P | L | T | D | | |
+ * |-------+-------+-------+-------+-------+-------|-------+-------+-------+-------+-------+-------|
+ * | S | K | W | R | * | R | B | G | S | Z | | |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * | # | # | # | # | | # | # | # | # | # | | |
+ * |-------+-------+-------+-------+-------+---------------+-------+-------+-------+-------+-------|
+ * | | | A | O | | E | U | | | | |Adj/Ent|
+ * `-----------------------------------------------------------------------------------------------'
+ */
+
+[_PLOVER] = {
+ {KC_Q, KC_W, KC_E, KC_R, KC_T, KC_U, KC_I, KC_O, KC_P, KC_LBRC, XXXXXXX, XXXXXXX},
+ {KC_A, KC_S, KC_D, KC_F, KC_G, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, XXXXXXX, XXXXXXX},
+ {KC_1, KC_1, KC_1, KC_1, XXXXXXX, KC_1, KC_1, KC_1, KC_1, KC_1, XXXXXXX, XXXXXXX},
+ {XXXXXXX, XXXXXXX, KC_C, KC_V, XXXXXXX, KC_N, KC_M, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, LT(_ADJ, KC_ENT)}
+},
+
+/* Adjust
+ * ,-----------------------------------------------------------------------------------------------.
+ * | | | | | | | | | Insert| PrtSc | Pause | RESET |
+ * |-------+-------+-------+-------+-------+---------------+-------+-------+-------+-------+-------|
+ * | | | | | | | | CapLk |Voice +| Audio |MIDIoff| |
+ * |-------+-------+-------+-------+-------+-------|-------+-------+-------+-------+-------+-------|
+ * | | | | | | | | ScrLk |Voice -| Music |MIDI on| |
+ * |-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------|
+ * | | | | | | | | Numlk |Workman| Qwerty| Plover|Adj/Ent|
+ * `-----------------------------------------------------------------------------------------------'
+ */
+
+[_ADJ] = {
+ {_______, _______, _______, _______, _______, _______, _______, _______, KC_INS, KC_PSCR, KC_PAUSE, RESET},
+ {_______, _______, _______, _______, _______, _______, _______, KC_CLCK, MUV_IN, AU_TOG, MI_OFF, _______},
+ {_______, _______, _______, _______, _______, _______, _______, KC_SLCK, MUV_DE, MU_TOG, MI_ON, _______},
+ {_______, _______, _______, _______, _______, _______, _______, KC_NLCK, WORKMAN, QWERTY, PLOVER, _______}
+}
+
+};
+
+#ifdef AUDIO_ENABLE
+
+float tone_startup[][2] = SONG(STARTUP_SOUND);
+float tone_goodbye[][2] = SONG(GOODBYE_SOUND);
+
+float tone_workman[][2] = SONG(QWERTY_SOUND);
+float tone_qwerty[][2] = SONG(COLEMAK_SOUND);
+float tone_plover[][2] = SONG(PLOVER_SOUND);
+
+float music_scale[][2] = SONG(MUSIC_SCALE_SOUND);
+
+#endif
+
+
+void persistant_default_layer_set(uint16_t default_layer) {
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ case WORKMAN:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_workman, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_WORKMAN);
+ }
+ return false;
+ break;
+ case QWERTY:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_qwerty, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_QWERTY);
+ }
+ return false;
+ break;
+ case PLOVER:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_plover, false, 0);
+ #endif
+ if (!eeconfig_is_enabled()) {
+ eeconfig_init();
+ }
+ keymap_config.raw = eeconfig_read_keymap();
+ keymap_config.nkro = 1;
+ eeconfig_update_keymap(keymap_config.raw);
+ persistant_default_layer_set(1UL<<_PLOVER);
+ }
+ return false;
+ break;
+ }
+ return true;
+}
+
+void matrix_init_user(void) {
+ #ifdef AUDIO_ENABLE
+ startup_user();
+ #endif
+}
+
+#ifdef AUDIO_ENABLE
+
+void startup_user()
+{
+ _delay_ms(20); // gets rid of tick
+ PLAY_NOTE_ARRAY(tone_startup, false, 0);
+}
+
+void shutdown_user()
+{
+ PLAY_NOTE_ARRAY(tone_goodbye, false, 0);
+ _delay_ms(150);
+ stop_all_notes();
+}
+
+void music_on_user(void)
+{
+ music_scale_user();
+}
+
+void music_scale_user(void)
+{
+ PLAY_NOTE_ARRAY(music_scale, false, 0);
+}
+
+#endif
diff --git a/keyboards/planck/keymaps/impossible/readme.md b/keyboards/planck/keymaps/impossible/readme.md
new file mode 100644
index 0000000000..02c719197e
--- /dev/null
+++ b/keyboards/planck/keymaps/impossible/readme.md
@@ -0,0 +1,73 @@
+# The Impossible Layout
+
+The Impossible Layout is named such because it manages to fit in both a numpad and an inverted-T arrow cluster into the same layer as the alpha keys.
+
+## Main layout
+
+The Impossible Layout places the middle column of the alphas onto where the punctuation keys were, moving he most used punctuation to be accessed by the thumbs. Because removing the middle columns fits with the Workman layout's philosopy, Workman is used as the basis for the layout. This means the layout should be very easy to learn for Workman users, and reasonable for Colemak users. Other space gains are made by combining keys that are only ever chorded with other non symbol keys (with function-layer alternatives where needed).
+
+### Alpha-numeric layer
+
+| | | | | | | | | | | | |
+|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|
+| Q | D | R | W | B | F | U | P | J | 7 | 8 | 9 |
+| A | S | H | T | G | N | E | O | I | 4 | 5 | 6 |
+| Z | X | M | C | V | L | Y | K | Up | 1 | 2 | 3 |
+|Alt/Tab|Gui/Esc| , |CTL/Bsp| Fn/Ent|SFT/SPC| . | Left | Down | Right | 0 |Adj/Ent|
+
+### Function layer
+
+| | | | | | | | | | | | |
+|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|
+| ! | @ | # | $ | % | ^ | & | * | F12 | F7 | F8 | F9 |
+| Tab | [ | ] | - | Del | ' | ( | ) | F11 | F4 | F5 | F6 |
+| Menu | | | = | \ | / | | | PgUp | F1 | F2 | F3 |
+|Alt/Tab| Gui | ~ |CTL/Bsp| Fn/Ent|SFT/Spc| ; | Home | PgDn | End | F10 |Adj/Ent|
+
+## Qwerty
+
+The Qwerty layer, mostly intended for gaming use, makes use of the doubled chorded/non-symbolic keys to obtain use of the entire alpha-numeric typing area.
+
+### Qwerty layer
+
+| | | | | | | | | | | | |
+|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|
+|Gui/Esc| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
+| Ctrl | Q | W | E | R | T | Y | U | I | O | P | / |
+| Shift | A | S | D | F | G | H | J | K | L | ; | " |
+|Alt/Tab| Z | X | C | V | Fn/SPC| B | N | M | , | . |Adj/Ent|
+
+### Qwerty Fn Layer
+
+| | | | | | | | | | | | |
+|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|
+| Gui | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 |
+| Ctrl | ~ | [ | PgUp | ] | | | - | Up | = | | F12 |
+| Shift | Tab | Home | PgDn | End | Del | | Left | Down | Right | | |
+|Alt/Tab| | | | | Fn/Spc| | | | | Menu |Adj/Ent|
+
+## Stenography
+
+The Steno/Plover layer moves the number row below the regular keys, providing a much more comfortable placement for the thumb keys. Using this layout will require a slightly different dictionary to account for different keys being adjacent to the number row.
+
+### Steno Layer
+
+| | | | | | | | | | | | |
+|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|
+| S | T | P | H | * | F | P | L | T | D | | |
+| S | K | W | R | * | R | B | G | S | Z | | |
+| # | # | # | # | | # | # | # | # | # | | |
+| | | A | O | | E | U | | | | |Adj/Ent|
+
+## Adjustments and Options
+
+In order to switch between layouts and change other keyboard settings, an adjustment layer is accessible from the same position over any layout.
+
+### Adjustment Layer
+
+| | | | | | | | | | | | |
+|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|:-----:|
+| | | | | | | | | Insert| PrtSc | Pause | RESET |
+| | | | | | | | CapLk |Voice +| Audio |MIDIoff| |
+| | | | | | | | ScrLk |Voice -| Music |MIDI on| |
+| | | | | | | | Numlk |Workman| Qwerty| Plover|Adj/Ent|
diff --git a/keyboards/planck/keymaps/jhenahan/Makefile b/keyboards/planck/keymaps/jhenahan/Makefile
new file mode 100644
index 0000000000..de01ad2404
--- /dev/null
+++ b/keyboards/planck/keymaps/jhenahan/Makefile
@@ -0,0 +1,25 @@
+
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
+CONSOLE_ENABLE = no # Console for debug(+400)
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
+MIDI_ENABLE = no # MIDI controls
+AUDIO_ENABLE = yes # Audio output on port C6
+UNICODE_ENABLE = no # Unicode
+BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif
diff --git a/keyboards/planck/keymaps/jhenahan/config.h b/keyboards/planck/keymaps/jhenahan/config.h
new file mode 100644
index 0000000000..cd3adc41cc
--- /dev/null
+++ b/keyboards/planck/keymaps/jhenahan/config.h
@@ -0,0 +1,9 @@
+#ifndef CONFIG_USER_H
+#define CONFIG_USER_H
+
+#include "../../config.h"
+
+#define FORCE_NKRO
+#define WORKMAN_SOUND COLEMAK_SOUND
+
+#endif
diff --git a/keyboards/planck/keymaps/jhenahan/keymap.c b/keyboards/planck/keymaps/jhenahan/keymap.c
new file mode 100644
index 0000000000..2bda4b6956
--- /dev/null
+++ b/keyboards/planck/keymaps/jhenahan/keymap.c
@@ -0,0 +1,314 @@
+// This is the canonical layout file for the Quantum project. If you want to add another keyboard,
+// this is the style you want to emulate.
+
+#include "planck.h"
+#include "action_layer.h"
+#ifdef AUDIO_ENABLE
+ #include "audio.h"
+#endif
+#include "eeconfig.h"
+
+extern keymap_config_t keymap_config;
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _WORKMAN 0
+#define _DEAD 1
+#define _QWERTY 2
+#define _LOWER 3
+#define _RAISE 4
+#define _PLOVER 5
+#define _ADJUST 16
+
+enum planck_keycodes {
+ WORKMAN = SAFE_RANGE,
+ DEAD,
+ QWERTY,
+ LOWER,
+ RAISE,
+ PLOVER,
+ EXT_PLV,
+ TOG_PLV
+};
+
+// Fillers to make layering more clear
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+
+/* Workman
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | D | R | W | B | J | F | U | P | ; | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | S | H | T | G | Y | N | E | O | I | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | M | C | V | K | L | Dead | . | / |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Ctrl | RAlt | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_WORKMAN] = {
+ {KC_TAB, KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, KC_SCLN, KC_BSPC},
+ {MT(MOD_LCTL,KC_ESC), KC_A, KC_S, KC_H, KC_T, KC_G, KC_Y, KC_N, KC_E, KC_O, KC_I, KC_QUOT},
+ {KC_LSFT, KC_Z, KC_X, KC_M, KC_C, KC_V, KC_K, KC_L, DEAD, KC_DOT, KC_SLSH, KC_ENT},
+ {KC_LCTL, KC_RALT, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT}
+},
+
+/* Workman Dead Layer
+ * ,-----------------------------------------------------------------------------------.
+ * | | % | & | ? | + | @ | $ | _ | [ | ] | ! | |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | | / | ( | = | 0 | { | } | 1 | * | ) | - | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | 6 | 7 | 8 | 9 | | | \ | 2 | 3 | 4 | 5 | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | < | ~ | ` | , | # | ^ | > | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_DEAD] = {
+ {XXXXXXX, KC_PERC, KC_AMPR, KC_QUES, KC_PLUS, KC_AT, KC_DLR, KC_UNDS, KC_LBRC, KC_RBRC, KC_EXLM, XXXXXXX},
+ {XXXXXXX, KC_SLSH, KC_LPRN, KC_EQL, KC_0, KC_LCBR, KC_RCBR, KC_1, KC_ASTR, KC_RPRN, KC_MINS, XXXXXXX},
+ {XXXXXXX, KC_6, KC_7, KC_8, KC_9, KC_PIPE, KC_BSLS, KC_2, KC_3, KC_4, KC_5, XXXXXXX},
+ {XXXXXXX, XXXXXXX, KC_LT, KC_TILD, KC_GRV, KC_COMM, KC_COMM, KC_HASH, KC_CIRC, KC_GT, XXXXXXX, XXXXXXX}
+},
+
+/* Qwerty
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | S | D | F | G | H | J | K | L | ; | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | N | M | , | . | / |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Ctrl | RAlt | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_QWERTY] = {
+ {KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC},
+ {KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT},
+ {KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT },
+ {KC_LCTL, KC_RALT, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT}
+},
+
+/* Lower
+ * ,-----------------------------------------------------------------------------------.
+ * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | | Vol+ |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | Prev | Next | Vol- | Play |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_LOWER] = {
+ {KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC},
+ {KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE},
+ {_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS), _______, KC_VOLU, _______},
+ {_______, _______, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_MNXT, KC_VOLD, KC_MPLY}
+},
+
+/* Raise - KWM Interaction
+ * ,-----------------------------------------------------------------------------------.
+ * |Restrt| |TgSplt|Flotng|Parent|FlScrn|InsMrk| InsW | InsS | InsN | InsE | |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | | Mark |Rotate|Prefix| Term | BSP |SwpMrk|SwapW |SwapS |SwapN |SwapE | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | |MarkW |MarkS |MarkN |MarkE |Monocl|Float |FocusW|FocusS|FocusN|FocusE| |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_RAISE] = {
+ {LCAG(KC_Q), XXXXXXX, LCAG(KC_S), LCAG(KC_W), LCAG(KC_D), LCAG(KC_F), LCTL(S(KC_X)), LCTL(S(KC_H)), LCTL(S(KC_J)), LCTL(S(KC_K)), LCTL(S(KC_L)), XXXXXXX},
+ {XXXXXXX, LCAG(KC_M), LGUI(LCTL(KC_R)), LCAG(KC_DOT), LCAG(KC_T), LGUI(LCTL(KC_A)), LCTL(LALT(KC_M)), LCTL(LALT(KC_H)), LCTL(LALT(KC_J)), LCTL(LALT(KC_K)), LCTL(LALT(KC_L)), XXXXXXX},
+ {_______, LCAG(KC_H), LCAG(KC_J), LCAG(KC_K), LCAG(KC_L), LGUI(LCTL(KC_S)), LGUI(LCTL(KC_D)), LGUI(LALT(KC_H)), LGUI(LALT(KC_J)), LGUI(LALT(KC_K)), LGUI(LALT(KC_L)), _______},
+ {_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______}
+},
+
+/* Plover layer (http://opensteno.org)
+ * ,-----------------------------------------------------------------------------------.
+ * | # | # | # | # | # | # | # | # | # | # | # | # |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | | S | T | P | H | * | * | F | P | L | T | D |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * |TogOut| S | K | W | R | * | * | R | B | G | S | Z |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Exit | | | A | O | | E | U | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+
+[_PLOVER] = {
+ {KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1 },
+ {XXXXXXX, KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, KC_SCLN, KC_BSPC},
+ {TOG_PLV, KC_A, KC_S, KC_H, KC_T, KC_G, KC_Y, KC_N, KC_E, KC_O, KC_I, KC_QUOT},
+ {EXT_PLV, XXXXXXX, XXXXXXX, KC_M, KC_C, XXXXXXX, XXXXXXX, KC_L, KC_COMM, XXXXXXX, XXXXXXX, XXXXXXX}
+},
+
+/* Adjust (Lower + Raise)
+ * ,-----------------------------------------------------------------------------------.
+ * | | Reset| | | | | | | | | | Del |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | | | |Aud on|Audoff|AGnorm|AGswap|Qwerty|Workmn|Plover| | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | |Voice-|Voice+|Mus on|Musoff|MIDIon|MIDIof| | | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_ADJUST] = {
+ {_______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL},
+ {_______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, WORKMAN, PLOVER, _______, _______},
+ {_______, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, _______, _______, _______, _______, _______},
+ {_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______}
+}
+
+
+};
+
+#ifdef AUDIO_ENABLE
+
+float tone_startup[][2] = SONG(STARTUP_SOUND);
+float tone_qwerty[][2] = SONG(QWERTY_SOUND);
+float tone_workman[][2] = SONG(WORKMAN_SOUND);
+float tone_plover[][2] = SONG(PLOVER_SOUND);
+float tone_plover_gb[][2] = SONG(PLOVER_GOODBYE_SOUND);
+float music_scale[][2] = SONG(MUSIC_SCALE_SOUND);
+
+float tone_goodbye[][2] = SONG(GOODBYE_SOUND);
+#endif
+
+
+void persistant_default_layer_set(uint16_t default_layer) {
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ case WORKMAN:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_workman, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_WORKMAN);
+ }
+ return false;
+ break;
+ case DEAD:
+ if (record->event.pressed) {
+ layer_on(_DEAD);
+ set_oneshot_layer(_DEAD, ONESHOT_START);
+ clear_oneshot_layer_state(ONESHOT_PRESSED);
+ }
+ return false;
+ break;
+ case QWERTY:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_qwerty, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_QWERTY);
+ }
+ return false;
+ break;
+ case LOWER:
+ if (record->event.pressed) {
+ layer_on(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case RAISE:
+ if (record->event.pressed) {
+ layer_on(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case PLOVER:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ stop_all_notes();
+ PLAY_NOTE_ARRAY(tone_plover, false, 0);
+ #endif
+ layer_off(_RAISE);
+ layer_off(_LOWER);
+ layer_off(_ADJUST);
+ layer_on(_PLOVER);
+ if (!eeconfig_is_enabled()) {
+ eeconfig_init();
+ }
+ keymap_config.raw = eeconfig_read_keymap();
+ keymap_config.nkro = 1;
+ eeconfig_update_keymap(keymap_config.raw);
+ }
+ return false;
+ break;
+ case EXT_PLV:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_plover_gb, false, 0);
+ #endif
+ layer_off(_PLOVER);
+ }
+ return false;
+ break;
+ case TOG_PLV:
+ if (record->event.pressed) {
+ register_code(KC_R);
+ register_code(KC_W);
+ register_code(KC_T);
+ register_code(KC_C);
+ register_code(KC_P);
+ register_code(KC_O);
+ clear_keyboard();
+ }
+ return false;
+ break;
+ }
+ return true;
+}
+
+void matrix_init_user(void) {
+ #ifdef AUDIO_ENABLE
+ startup_user();
+ #endif
+}
+
+#ifdef AUDIO_ENABLE
+
+void startup_user()
+{
+ _delay_ms(20); // gets rid of tick
+ PLAY_NOTE_ARRAY(tone_startup, false, 0);
+}
+
+void shutdown_user()
+{
+ PLAY_NOTE_ARRAY(tone_goodbye, false, 0);
+ _delay_ms(150);
+ stop_all_notes();
+}
+
+void music_on_user(void)
+{
+ music_scale_user();
+}
+
+void music_scale_user(void)
+{
+ PLAY_NOTE_ARRAY(music_scale, false, 0);
+}
+
+#endif
diff --git a/keyboards/planck/keymaps/jhenahan/readme.md b/keyboards/planck/keymaps/jhenahan/readme.md
new file mode 100644
index 0000000000..a80506fc9d
--- /dev/null
+++ b/keyboards/planck/keymaps/jhenahan/readme.md
@@ -0,0 +1,41 @@
+# jhenahan's layout
+
+## Layout
+
+The base layer is based on the
+[Workman Dead](https://github.com/ojbucao/Workman/tree/master/mac) layout. The
+primary interaction layer is a slightly modified Workman layout with a 'dead'
+key on the third row under the middle finger. The dead key activates a layer of
+special characters.
+
+## [Layers](http://www.keyboard-layout-editor.com/#/gists/2b875f7d5d76fe4408c0a5b3bd76ddae)
+### Function Layer
+
+This is very slightly modified from the default, mainly just to rearrange the media keys.
+
+### [KWM](https://github.com/koekeishiya/kwm) Interaction Layer
+
+`kwm` is a tiling window manager for OS X. The keys defined in my keymap
+correspond to the settings I use in
+[my `kwmrc` file](https://github.com/jhenahan/dotfiles/blob/master/kwm/kwmrc).
+
+### QWERTY
+
+Just in case.
+
+### [Plover](http://www.openstenoproject.org/plover/)
+
+This layout functions exactly as a Workman layout unless you're running the Plover
+application. Includes a key for toggling Plover while it's running.
+
+Add this in the appropriate section of your `plover.cfg` to allow this altered layout:
+
+``` ini
+[System: English Stenotype]
+keymap[keyboard] = [["#", ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "-", "="]], ["S-", ["q", "a"]], ["T-", ["d"]], ["K-", ["s"]], ["P-", ["r"]], ["W-", ["h"]], ["H-", ["w"]], ["R-", ["t"]], ["A-", ["m"]], ["O-", ["c"]], ["*", ["y", "g", "j", "b"]], ["-E", ["l"]], ["-U", [","]], ["-F", ["f"]], ["-R", ["n"]], ["-P", ["u"]], ["-B", ["e"]], ["-L", ["p"]], ["-G", ["o"]], ["-T", [";"]], ["-S", ["i"]], ["-D", ["BackSpace"]], ["-Z", ["'"]], ["no-op", ["\\", "]", "x", ".", "/"]], ["arpeggiate", ["space"]]]
+```
+
+### Adjust Layer
+
+This layer is only slightly modified from the default to remove Dvorak and
+Colemak and replace them with Workman.
diff --git a/keyboards/planck/keymaps/pvc/Makefile b/keyboards/planck/keymaps/pvc/Makefile
index 0b2f060de4..b2ff961fa5 100644
--- a/keyboards/planck/keymaps/pvc/Makefile
+++ b/keyboards/planck/keymaps/pvc/Makefile
@@ -1,12 +1,12 @@
# Build Options
-# change to "no" to disable the options, or define them in the Makefile in
+# change to "no" to disable the options, or define them in the Makefile in
# the appropriate keymap folder that will get included automatically
#
-BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
-CONSOLE_ENABLE = no # Console for debug(+400)
+CONSOLE_ENABLE = yes # Console for debug(+400)
COMMAND_ENABLE = yes # Commands for debug and configuration
NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
diff --git a/keyboards/planck/keymaps/pvc/config.h b/keyboards/planck/keymaps/pvc/config.h
index c857a3e89d..1004c8b99f 100644
--- a/keyboards/planck/keymaps/pvc/config.h
+++ b/keyboards/planck/keymaps/pvc/config.h
@@ -59,13 +59,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
)
-/* ws2812 RGB LED */
-#define RGB_DI_PIN D1
-#define RGBLIGHT_TIMER
-#define RGBLED_NUM 28 // Number of LEDs
-#define RGBLIGHT_HUE_STEP 10
-#define RGBLIGHT_SAT_STEP 17
-#define RGBLIGHT_VAL_STEP 17
+#define BACKLIGHT_PIN B7
+#define BACKLIGHT_BREATHING
/*
* Feature disable options
@@ -73,10 +68,18 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/* disable debug print */
-//#define NO_DEBUG
+#ifndef NO_DEBUG
+# define NO_DEBUG
+#endif
/* disable print */
-//#define NO_PRINT
+// #ifndef NO_PRINT
+// # define NO_PRINT
+// #endif
+
+/* Only print user print statements */
+#define USER_PRINT
+
/* disable action features */
//#define NO_ACTION_LAYER
diff --git a/keyboards/planck/keymaps/pvc/keymap.c b/keyboards/planck/keymaps/pvc/keymap.c
index 0bb7f0def2..6ad95832d2 100644
--- a/keyboards/planck/keymaps/pvc/keymap.c
+++ b/keyboards/planck/keymaps/pvc/keymap.c
@@ -2,48 +2,59 @@
#include "action_layer.h"
#include "eeconfig.h"
#include "led.h"
+#include "mousekey.h"
#ifdef AUDIO_ENABLE
#include "audio.h"
#include "song_list.h"
#endif
-#define LAYER_QWERTY 0
-#define LAYER_COLEMAK 1
-#define LAYER_DVORAK 2
-#define LAYER_UPPER 3
-#define LAYER_LOWER 4
-#define LAYER_FUNCTION 5
-#define LAYER_MOUSE 6
-#define LAYER_ADJUST 7
-
-#define MACRO_QWERTY 0
-#define MACRO_COLEMAK 1
-#define MACRO_DVORAK 2
-#define MACRO_UPPER 3
-#define MACRO_LOWER 4
-#define MACRO_FUNCTION 5
-#define MACRO_MOUSE 6
-#define MACRO_TIMBRE_1 7
-#define MACRO_TIMBRE_2 8
-#define MACRO_TIMBRE_3 9
-#define MACRO_TIMBRE_4 10
-#define MACRO_TEMPO_U 11
-#define MACRO_TEMPO_D 12
-#define MACRO_TONE_DEFAULT 13
-#define MACRO_MUSIC_TOGGLE 14
-#define MACRO_AUDIO_TOGGLE 16
-#define MACRO_INC_VOICE 18
-#define MACRO_DEC_VOICE 19
-#define MACRO_BACKLIGHT 20
-#define MACRO_BREATH_TOGGLE 21
-#define MACRO_BREATH_SPEED_INC 23
-#define MACRO_BREATH_SPEED_DEC 24
-#define MACRO_BREATH_DEFAULT 25
+enum keyboard_layers {
+ LAYER_QWERTY = 0,
+ LAYER_UPPER,
+ LAYER_LOWER,
+ LAYER_FUNCTION,
+ LAYER_MOUSE,
+ LAYER_ADJUST,
+};
+enum keyboard_macros {
+ MACRO_QWERTY = 0,
+ MACRO_UPPER,
+ MACRO_LOWER,
+ MACRO_FUNCTION,
+ MACRO_MOUSE,
+ MACRO_TIMBRE_1,
+ MACRO_TIMBRE_2,
+ MACRO_TIMBRE_3,
+ MACRO_TIMBRE_4,
+ MACRO_TEMPO_U,
+ MACRO_TEMPO_D,
+ MACRO_TONE_DEFAULT,
+ MACRO_MUSIC_TOGGLE,
+ MACRO_AUDIO_TOGGLE,
+ MACRO_INC_VOICE,
+ MACRO_DEC_VOICE,
+ MACRO_BACKLIGHT,
+ MACRO_BREATH_TOGGLE,
+ MACRO_BREATH_SPEED_INC,
+ MACRO_BREATH_SPEED_DEC,
+ MACRO_BREATH_DEFAULT,
+ MACRO_MOUSE_MOVE_UL,
+ MACRO_MOUSE_MOVE_UR,
+ MACRO_MOUSE_MOVE_DL,
+ MACRO_MOUSE_MOVE_DR,
+ MACRO_HELP_1,
+ MACRO_HELP_2,
+ MACRO_HELP_3,
+ MACRO_HELP_4,
+ MACRO_HELP_5,
+ MACRO_HELP_6,
+ MACRO_HELP_7,
+ MACRO_HELP_8,
+ MACRO_HELP_9,
+};
#define M_QWRTY M(MACRO_QWERTY)
-#define M_COLMK M(MACRO_COLEMAK)
-#define M_DVORK M(MACRO_DVORAK)
#define M_UPPER M(MACRO_UPPER)
#define M_LOWER M(MACRO_LOWER)
#define M_FUNCT M(MACRO_FUNCTION)
@@ -60,6 +71,19 @@
#define M_BSPDU M(MACRO_BREATH_SPEED_INC)
#define M_BSPDD M(MACRO_BREATH_SPEED_DEC)
#define M_BDFLT M(MACRO_BREATH_DEFAULT)
+#define M_MS_UL M(MACRO_MOUSE_MOVE_UL)
+#define M_MS_UR M(MACRO_MOUSE_MOVE_UR)
+#define M_MS_DL M(MACRO_MOUSE_MOVE_DL)
+#define M_MS_DR M(MACRO_MOUSE_MOVE_DR)
+#define M_HELP1 M(MACRO_HELP_1)
+#define M_HELP2 M(MACRO_HELP_2)
+#define M_HELP3 M(MACRO_HELP_3)
+#define M_HELP4 M(MACRO_HELP_4)
+#define M_HELP5 M(MACRO_HELP_5)
+#define M_HELP6 M(MACRO_HELP_6)
+#define M_HELP7 M(MACRO_HELP_7)
+#define M_HELP8 M(MACRO_HELP_8)
+#define M_HELP9 M(MACRO_HELP_9)
#define VC_UP M(MACRO_INC_VOICE)
@@ -77,6 +101,7 @@
#define SC_ACLS LALT(KC_F4)
#define SC_CCLS LCTL(KC_F4)
+#define TG_NKRO MAGIC_TOGGLE_NKRO
#define OS_SHFT KC_FN0
#define _______ KC_TRNS
@@ -86,146 +111,108 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
-/* QWERTY
- * .-----------------------------------------------------------------------------------------------------------.
- * | TAB | Q | W | E | R | T | Y | U | I | O | P | BACKSP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | ESC | A | S | D | F | G | H | J | K | L | ; | ' |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | LSHIFT | Z | X | C | V | B | N | M | , | . | UP | ENTER |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | LCTRL | LWIN | FN | LALT | UPPER | SPACE | SPACE | LOWER | SHIFT | LEFT | DOWN | RIGHT |
- * '-----------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_QWERTY] = { // QWERTY
- { KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC },
- { KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT },
- { KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_UP, KC_ENT },
- { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_LEFT, KC_DOWN, KC_RGHT },
- },
-
-/* COLEMAK
- * .-----------------------------------------------------------------------------------------------------------.
- * | TAB | Q | W | F | P | G | J | L | U | Y | ; | ESC |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | BACKSP | A | R | S | T | D | H | N | E | I | O | ' |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | LSHIFT | Z | X | C | V | B | K | M | , | . | UP | ENTER |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | LCTRL | LWIN | FN | LALT | UPPER | SPACE | SPACE | LOWER | SHIFT | LEFT | DOWN | RIGHT |
- * '-----------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_COLEMAK] = { // COLEMAK
- { KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_ESC },
- { KC_BSPC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT },
- { KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_UP, KC_ENT },
- { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_LEFT, KC_DOWN, KC_RGHT },
- },
-
-/* DVORAK
- * .-----------------------------------------------------------------------------------------------------------.
- * | TAB | ' | , | . | P | Y | F | G | C | R | L | BACKSP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | ESC | A | O | E | U | I | D | H | T | N | S | / |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | LSHIFT | ; | Q | J | K | X | B | M | W | V | Z | ENTER |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | LCTRL | LWIN | FN | LALT | UPPER | SPACE | SPACE | LOWER | UP | DOWN | LEFT | RIGHT |
- * '-----------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_DVORAK] = { // DVORAK
- { KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_BSPC },
- { KC_ESC, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH },
- { KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_ENT },
- { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, KC_UP, KC_DOWN, KC_LEFT, KC_RGHT },
- },
-
-/* UPPER
- * .-----------------------------------------------------------------------------------------------------------.
- * | PRINT | F1 | F2 | F3 | F4 | NUM LK | / | 7 | 8 | 9 | - | DEL |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | CAP LK | F5 | F6 | F7 | F8 | SCR LK | * | 4 | 5 | 6 | + | INS |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | | F9 | F10 | F11 | F12 | PAUSE | | 1 | 2 | 3 | ENTER | HOME |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | | | | | | 0 | 0 | | RALT | . | ENTER | END |
- * '-----------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_UPPER] = { // UPPER
- { KC_PSCR, KC_F1, KC_F2, KC_F3, KC_F4, KC_NLCK, KC_PSLS, KC_KP_7, KC_KP_8, KC_KP_9, KC_PMNS, KC_DEL },
- { KC_CAPS, KC_F5, KC_F6, KC_F7, KC_F8, KC_SLCK, KC_PAST, KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, KC_INS },
- { _______, KC_F9, KC_F10, KC_F11, KC_F12, KC_PAUS, XXXXXXX, KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, KC_HOME },
- { _______, _______, _______, _______, _______, KC_KP_0, KC_KP_0, _______, KC_RALT, KC_PDOT, KC_PENT, KC_END },
- },
-
-/* LOWER
- * .-----------------------------------------------------------------------------------------------------------.
- * | | $ | { | [ | ( | % | # | ) | ] | } | @ | PG UP |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | | ^ | * | + | - | / | \ | _ | ' | " | ` | PG DN |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | | | | & | ! | ~ | ; | : | = | < | > | ? | HOME |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
- * | | | | | | | | | | | | END |
- * '-----------------------------------------------------------------------------------------------------------'
- */
-
- [LAYER_LOWER] = { // LOWER
- { _______, KC_DLR, KC_LCBR, KC_LBRC, KC_LPRN, KC_PERC, KC_HASH, KC_RPRN, KC_RBRC, KC_RCBR, KC_AT, KC_PGUP },
- { _______, KC_CIRC, KC_ASTR, KC_PPLS, KC_PMNS, KC_SLSH, KC_BSLS, KC_UNDS, KC_QUOT, KC_DQT, KC_GRV, KC_PGDN },
- { _______, KC_PIPE, KC_AMPR, KC_EXLM, KC_TILD, KC_SCLN, KC_COLN, KC_EQL, KC_LT, KC_GT, KC_QUES, KC_HOME },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_END },
- },
-
-
-/* FUNCTION
- * .-----------------------------------------------------------------------------------------------------------.
- * | NUM LK | F13 | F14 | F15 | F16 | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | PAUSE |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | CAP LK | F17 | F18 | F19 | F20 | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | PRINT |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | SCR LK | F21 | F22 | F23 | F24 | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | MUTE |
- * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
- * | LCTRL | LWIN | FN | LALT | UPPER | PLAY | PLAY | LOWER | VOL UP | VOL DN | NEXT | PREV |
- * '-----------------------------------------------------------------------------------------------------------'
- */
- [LAYER_FUNCTION] = { // FUNCTION
- { KC_NLCK, KC_F13, KC_F14, KC_F15, KC_F16, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_PAUS },
- { KC_CAPS, KC_F17, KC_F18, KC_F19, KC_F20, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_PSCR },
- { KC_SLCK, KC_F21, KC_F22, KC_F23, KC_F24, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_MUTE },
- { _______, _______, _______, _______, _______, KC_MPLY, KC_MPLY, _______, KC_VOLU, KC_VOLD, KC_MPRV, KC_MNXT },
- },
-
-#ifdef MOUSEKEY_ENABLE
-
- [LAYER_MOUSE] = { // MOUSE
- { KC_ESC, KC_ACL0, KC_ACL1, KC_ACL2, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_ESC },
- { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
- { _______, KC_BTN5, KC_BTN4, KC_BTN3, KC_BTN2, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_WH_U, KC_WH_D },
- { _______, _______, _______, _______, _______, KC_BTN1, KC_BTN1, _______, KC_MS_U, KC_MS_D, KC_MS_L, KC_MS_R },
- },
-
-#endif
-
- [LAYER_ADJUST] = { // ADJUST
- { _______, TIMBR_1, TIMBR_2, TIMBR_3, TIMBR_4, TMPO_UP, TMPO_DN, TMPO_DF, _______, _______, MU_TOG, AU_TOG },
- { _______, M_QWRTY, M_COLMK, M_DVORK, _______, _______, _______, _______, _______, _______, _______, _______ },
- { _______, _______, _______, _______, M_BACKL, RESET, _______, M_MOUSE, _______, _______, MUV_IN, _______ },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, MUV_DE, _______ },
- },
-
-/*
- [LAYER_EMPTY] = {
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, },
- { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, },
- { _______, _______, _______, _______, _______, ________________, _______, _______, _______, _______, _______, },
- },
+/* LAYER = LAYER_QWERTY
+ .-----------------------------------------------------------------------------------------------------------.
+ | TAB | Q | W | E | R | T | Y | U | I | O | P | BACKSP |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ESC | A | S | D | F | G | H | J | K | L | ; | ' |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | LSHIFT | Z | X | C | V | B | N | M | , | . | UP | ENTER |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | LCTRL | LWIN | FN | LALT | UPPER | SPACE | SPACE | LOWER | OSHIFT | LEFT | DOWN | RIGHT |
+ '-----------------------------------------------------------------------------------------------------------'
*/
+[LAYER_QWERTY] = {
+ { KC_TAB , KC_Q , KC_W , KC_E , KC_R , KC_T , KC_Y , KC_U , KC_I , KC_O , KC_P , KC_BSPC },
+ { KC_ESC , KC_A , KC_S , KC_D , KC_F , KC_G , KC_H , KC_J , KC_K , KC_L , KC_SCLN, KC_QUOT },
+ { KC_LSFT, KC_Z , KC_X , KC_C , KC_V , KC_B , KC_N , KC_M , KC_COMM, KC_DOT , KC_UP , KC_ENT },
+ { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC , KC_SPC , M_LOWER, OS_SHFT, KC_LEFT, KC_DOWN, KC_RGHT }
+},
+/* LAYER = LAYER_UPPER
+ .-----------------------------------------------------------------------------------------------------------.
+ | PRINT | F1 | F2 | F3 | F4 | NUM LK | KP / | KP 7 | KP 8 | KP 9 | KP - | DEL |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | PAUSE | F5 | F6 | F7 | F8 | SCR LK | KP * | KP 4 | KP 5 | KP 6 | KP + | INS |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | F9 | F10 | F11 | F12 | PAUSE | KP 0 | KP 1 | KP 2 | KP 3 | KP ENT | HOME |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | ______ | ______ | UPPER | KP 0 | KP 0 | ______ | RALT | KP . | KP ENT | END |
+ '-----------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_UPPER] = {
+ { KC_PSCR, KC_F1 , KC_F2 , KC_F3 , KC_F4 , KC_NLCK, KC_PSLS, KC_KP_7, KC_KP_8, KC_KP_9, KC_PMNS, KC_DEL },
+ { KC_PAUS, KC_F5 , KC_F6 , KC_F7 , KC_F8 , KC_SLCK, KC_PAST, KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, KC_INS },
+ { _______, KC_F9 , KC_F10 , KC_F11 , KC_F12 , KC_PAUS, KC_KP_0, KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, KC_HOME },
+ { _______, _______, _______, _______, M_UPPER, KC_KP_0, KC_KP_0, _______, KC_RALT, KC_PDOT, KC_PENT, KC_END }
+},
+/* LAYER = LAYER_LOWER
+ .-----------------------------------------------------------------------------------------------------------.
+ | ______ | $ | { | [ | ( | % | # | ) | ] | } | @ | PG UP |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ^ | * | + | - | / | \ | _ | ' | " | ` | PG DN |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | | | & | ! | ~ | ; | : | = | < | > | ? | HOME |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | LOWER | ______ | ______ | ______ | END |
+ '-----------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_LOWER] = {
+ { _______, KC_DLR , KC_LCBR, KC_LBRC, KC_LPRN, KC_PERC, KC_HASH, KC_RPRN, KC_RBRC, KC_RCBR, KC_AT , KC_PGUP },
+ { _______, KC_CIRC, KC_ASTR, KC_PLUS, KC_MINS, KC_SLSH, KC_BSLS, KC_UNDS, KC_QUOT, KC_DQT , KC_GRV , KC_PGDN },
+ { _______, KC_PIPE, KC_AMPR, KC_EXLM, KC_TILD, KC_SCLN, KC_COLN, KC_EQL , KC_LT , KC_GT , KC_QUES, KC_HOME },
+ { _______, _______, _______, _______, _______, _______, _______, M_LOWER, _______, _______, _______, KC_END }
+},
+/* LAYER = LAYER_FUNCTION
+ .-----------------------------------------------------------------------------------------------------------.
+ | XXXXXX | F13 | F14 | F15 | F16 | NUM LK | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | F17 | F18 | F19 | F20 | SCR LK | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | F21 | F22 | F23 | F24 | CAP LK | XXXXXX | XXXXXX | XXXXXX | XXXXXX | VOL UP | MUTE |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | FN | ______ | ______ | PLAY | PLAY | ______ | ______ | PREV | VOL DN | NEXT |
+ '-----------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_FUNCTION] = {
+ { XXXXXXX, KC_F13 , KC_F14 , KC_F15 , KC_F16 , KC_NLCK, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { XXXXXXX, KC_F17 , KC_F18 , KC_F19 , KC_F20 , KC_SLCK, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { _______, KC_F21 , KC_F22 , KC_F23 , KC_F24 , KC_CAPS, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLU, KC_MUTE },
+ { _______, _______, M_FUNCT, _______, _______, KC_MPLY, KC_MPLY, _______, _______, KC_MPRV, KC_VOLD, KC_MNXT }
+},
+/* LAYER = LAYER_MOUSE
+ .-----------------------------------------------------------------------------------------------------------.
+ | ESC | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | MS UL | MS U | MS UR | MS WHL | MS WHR |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | MS BT5 | MS BT4 | MS BT3 | MS BT2 | XXXXXX | XXXXXX | MS L | XXXXXX | MS R | XXXXXX | MS WHU |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | MS DL | MS D | MS DR | MS U | MS WHD |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | ______ | ______ | ______ | ______ | ______ | MS BT1 | MS BT1 | ______ | ______ | MS L | MS D | MS R |
+ '-----------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_MOUSE] = {
+ { KC_ESC , XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_MS_UL, KC_MS_U, M_MS_UR, KC_WH_L, KC_WH_R },
+ { XXXXXXX, KC_BTN5, KC_BTN4, KC_BTN3, KC_BTN2, XXXXXXX, XXXXXXX, KC_MS_L, XXXXXXX, KC_MS_R, XXXXXXX, KC_WH_U },
+ { _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_MS_DL, KC_MS_D, M_MS_DR, KC_MS_U, KC_WH_D },
+ { _______, _______, _______, _______, _______, KC_BTN1, KC_BTN1, _______, _______, KC_MS_L, KC_MS_D, KC_MS_R }
+},
+/* LAYER = LAYER_ADJUST
+ .-----------------------------------------------------------------------------------------------------------.
+ | XXXXXX | HELP 1 | HELP 2 | HELP 3 | HELP 4 | HELP 5 | HELP 6 | HELP 7 | HELP 8 | HELP 9 | MUSIC | AUDIO |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | BRTOG | BRSPD+ | BRSPD- | BRDFLT | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | QWERTY | XXXXXX | XXXXXX | BACKLT | RESET | XXXXXX | MOUSE | XXXXXX | XXXXXX | VOICE+ | XXXXXX |
+ |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | UPPER | XXXXXX | XXXXXX | LOWER | XXXXXX | TEMPO- | VOICE- | TEMPO+ |
+ '-----------------------------------------------------------------------------------------------------------'
+*/
+[LAYER_ADJUST] = {
+ { XXXXXXX, M_HELP1, M_HELP2, M_HELP3, M_HELP4, M_HELP5, M_HELP6, M_HELP7, M_HELP8, M_HELP9, MU_TOG , AU_TOG },
+ { XXXXXXX, M_BRTOG, M_BSPDU, M_BSPDD, M_BDFLT, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
+ { XXXXXXX, M_QWRTY, XXXXXXX, XXXXXXX, M_BACKL, RESET , XXXXXXX, M_MOUSE, XXXXXXX, XXXXXXX, MUV_IN , XXXXXXX },
+ { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_UPPER, XXXXXXX, XXXXXXX, M_LOWER, XXXXXXX, TMPO_DN, MUV_DE , TMPO_UP }
+},
};
@@ -234,10 +221,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
float tone_my_startup[][2] = SONG(ODE_TO_JOY);
float tone_my_goodbye[][2] = SONG(ROCK_A_BYE_BABY);
-float tone_qwerty[][2] = SONG(QWERTY_SOUND);
-float tone_dvorak[][2] = SONG(DVORAK_SOUND);
-float tone_colemak[][2] = SONG(COLEMAK_SOUND);
-
float tone_audio_on[][2] = SONG(CLOSE_ENCOUNTERS_5_NOTE);
float tone_music_on[][2] = SONG(DOE_A_DEER);
float tone_caps_on[][2] = SONG(CAPS_LOCK_ON_SOUND);
@@ -257,7 +240,7 @@ void persistant_default_layer_set(uint16_t default_layer)
}
const uint16_t PROGMEM fn_actions[] = {
- [0] = ACTION_MODS_ONESHOT(MOD_LSFT),
+ [0] = ACTION_MODS_ONESHOT(MOD_RSFT),
};
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
@@ -267,46 +250,101 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
switch(id)
{
- case MACRO_QWERTY:
+ case MACRO_HELP_1:
if (record->event.pressed)
{
- persistant_default_layer_set(1UL<<LAYER_QWERTY);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_qwerty, false, STACCATO);
- #endif /* AUDIO_ENABLE */
+ uprintf("1");
}
break;
- case MACRO_COLEMAK:
+ case MACRO_HELP_2:
if (record->event.pressed)
{
- persistant_default_layer_set(1UL<<LAYER_COLEMAK);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_colemak, false, STACCATO);
- #endif /* AUDIO_ENABLE */
+ uprintf("2");
}
break;
- case MACRO_DVORAK:
+ case MACRO_HELP_3:
if (record->event.pressed)
{
- persistant_default_layer_set(1UL<<LAYER_DVORAK);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_dvorak, false, STACCATO);
- #endif /* AUDIO_ENABLE */
+ uprintf("3");
}
break;
- case MACRO_LOWER:
+ case MACRO_HELP_4:
if (record->event.pressed)
{
- layer_on(LAYER_LOWER);
- update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ uprintf("4");
}
- else
+ break;
+
+ case MACRO_HELP_5:
+ if (record->event.pressed)
{
- layer_off(LAYER_LOWER);
- update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ uprintf("5");
+ }
+ break;
+
+ case MACRO_HELP_6:
+ if (record->event.pressed)
+ {
+ uprintf("6");
+ }
+ break;
+
+ case MACRO_HELP_7:
+ if (record->event.pressed)
+ {
+ uprintf("7");
+ }
+ break;
+
+ case MACRO_HELP_8:
+ if (record->event.pressed)
+ {
+ uprintf("8");
+ }
+ break;
+
+ case MACRO_HELP_9:
+ if (record->event.pressed)
+ {
+ uprintf("9");
+ }
+ break;
+
+ case MACRO_BREATH_TOGGLE:
+ if (record->event.pressed)
+ {
+ breathing_toggle();
+ }
+ break;
+
+ case MACRO_BREATH_SPEED_INC:
+ if (record->event.pressed)
+ {
+ breathing_speed_inc(1);
+ }
+ break;
+
+ case MACRO_BREATH_SPEED_DEC:
+ if (record->event.pressed)
+ {
+ breathing_speed_dec(1);
+ }
+ break;
+
+ case MACRO_BREATH_DEFAULT:
+ if (record->event.pressed)
+ {
+ breathing_defaults();
+ }
+ break;
+
+ case MACRO_QWERTY:
+ if (record->event.pressed)
+ {
+ persistant_default_layer_set(1UL<<LAYER_QWERTY);
}
break;
@@ -314,6 +352,8 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
if (record->event.pressed)
{
layer_on(LAYER_UPPER);
+ breathing_speed_set(2);
+ breathing_pulse();
update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
}
else
@@ -323,13 +363,32 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
}
break;
+ case MACRO_LOWER:
+ if (record->event.pressed)
+ {
+ layer_on(LAYER_LOWER);
+ breathing_speed_set(2);
+ breathing_pulse();
+ update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ }
+ else
+ {
+ layer_off(LAYER_LOWER);
+ update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ }
+ break;
+
case MACRO_FUNCTION:
if (record->event.pressed)
{
+ breathing_speed_set(3);
+ breathing_enable();
layer_on(LAYER_FUNCTION);
}
else
{
+ breathing_speed_set(1);
+ breathing_self_disable();
layer_off(LAYER_FUNCTION);
}
break;
@@ -352,6 +411,58 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
}
break;
+ case MACRO_MOUSE_MOVE_UL:
+ if (record->event.pressed)
+ {
+ mousekey_on(KC_MS_UP);
+ mousekey_on(KC_MS_LEFT);
+ }
+ else
+ {
+ mousekey_off(KC_MS_UP);
+ mousekey_off(KC_MS_LEFT);
+ }
+ break;
+
+ case MACRO_MOUSE_MOVE_UR:
+ if (record->event.pressed)
+ {
+ mousekey_on(KC_MS_UP);
+ mousekey_on(KC_MS_RIGHT);
+ }
+ else
+ {
+ mousekey_off(KC_MS_UP);
+ mousekey_off(KC_MS_RIGHT);
+ }
+ break;
+
+ case MACRO_MOUSE_MOVE_DL:
+ if (record->event.pressed)
+ {
+ mousekey_on(KC_MS_DOWN);
+ mousekey_on(KC_MS_LEFT);
+ }
+ else
+ {
+ mousekey_off(KC_MS_DOWN);
+ mousekey_off(KC_MS_LEFT);
+ }
+ break;
+
+ case MACRO_MOUSE_MOVE_DR:
+ if (record->event.pressed)
+ {
+ mousekey_on(KC_MS_DOWN);
+ mousekey_on(KC_MS_RIGHT);
+ }
+ else
+ {
+ mousekey_off(KC_MS_DOWN);
+ mousekey_off(KC_MS_RIGHT);
+ }
+ break;
+
#endif /* MOUSEKEY_ENABLE */
#ifdef AUDIO_ENABLE
diff --git a/keyboards/planck/keymaps/sgoodwin/Makefile b/keyboards/planck/keymaps/sgoodwin/Makefile
new file mode 100644
index 0000000000..581e08cd02
--- /dev/null
+++ b/keyboards/planck/keymaps/sgoodwin/Makefile
@@ -0,0 +1,25 @@
+
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
+CONSOLE_ENABLE = no # Console for debug(+400)
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+MIDI_ENABLE = no # MIDI controls
+AUDIO_ENABLE = yes # Audio output on port C6
+UNICODE_ENABLE = no # Unicode
+BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/planck/keymaps/sgoodwin/keymap.c b/keyboards/planck/keymaps/sgoodwin/keymap.c
new file mode 100644
index 0000000000..4d5d3d7ef6
--- /dev/null
+++ b/keyboards/planck/keymaps/sgoodwin/keymap.c
@@ -0,0 +1,233 @@
+// This is sgoodwin's layout file for the Quantum project.
+// It doesn't have Plover or Dvorak layers because he doesn't use that.
+// It Also doesn't allow for swapping alt with CMD because that only happens in error.
+
+#include "planck.h"
+#include "action_layer.h"
+#ifdef AUDIO_ENABLE
+ #include "audio.h"
+#endif
+#include "eeconfig.h"
+
+extern keymap_config_t keymap_config;
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _QWERTY 1
+#define _COLEMAK 0
+#define _LOWER 3
+#define _RAISE 4
+#define _ADJUST 16
+
+enum planck_keycodes {
+ COLEMAK = SAFE_RANGE,
+ QWERTY,
+ LOWER,
+ RAISE,
+ BACKLIT,
+};
+
+// Fillers to make layering more clear
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Colemak
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | F | P | G | J | L | U | Y | ; | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | R | S | T | D | H | N | E | I | O | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | K | M | , | . | / |SHEnt |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Hyper| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_COLEMAK] = {
+ {KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC},
+ {KC_ESC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT},
+ {KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, MT(MOD_RSFT, KC_ENT) },
+ {ALL_T(KC_NO), KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT}
+},
+
+/* Qwerty
+ * ,-----------------------------------------------------------------------------------.
+ * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Esc | A | S | D | F | G | H | J | K | L | ; | " |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | Shift| Z | X | C | V | B | N | M | , | . | / |SHEnt |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | Hyper| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_QWERTY] = {
+ {KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC},
+ {KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT},
+ {KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, MT(MOD_RSFT, KC_ENT) },
+ {ALL_T(KC_NO), KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT}
+},
+
+/* Lower
+ * ,-----------------------------------------------------------------------------------.
+ * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | | |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | Next | Vol- | Vol+ | Play |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_LOWER] = {
+ {KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC},
+ {KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE},
+ {_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS),_______, _______, _______},
+ {BACKLIT, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY}
+},
+
+/* Raise
+ * ,-----------------------------------------------------------------------------------.
+ * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | Del | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / | | |Enter |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | Next | Vol- | Vol+ | Play |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_RAISE] = {
+ {KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC},
+ {KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS},
+ {_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, _______, _______, _______},
+ {BACKLIT, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY}
+},
+
+/* Adjust (Lower + Raise)
+ * ,-----------------------------------------------------------------------------------.
+ * | | Reset| | | | | | | | | | Del |
+ * |------+------+------+------+------+-------------+------+------+------+------+------|
+ * | | | |Aud on|Audoff| | |Qwerty|Colemk| | | |
+ * |------+------+------+------+------+------|------+------+------+------+------+------|
+ * | |Voice-|Voice+|Mus on|Musoff|MIDIon|MIDIof| | | | | |
+ * |------+------+------+------+------+------+------+------+------+------+------+------|
+ * | | | | | | | | | | | |
+ * `-----------------------------------------------------------------------------------'
+ */
+[_ADJUST] = {
+ {_______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL},
+ {_______, _______, _______, AU_ON, AU_OFF, _______, _______, QWERTY, COLEMAK, _______, _______, _______},
+ {_______, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, _______, _______, _______, _______, _______},
+ {_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______}
+}
+
+
+};
+
+#ifdef AUDIO_ENABLE
+
+float tone_startup[][2] = SONG(STARTUP_SOUND);
+float tone_qwerty[][2] = SONG(QWERTY_SOUND);
+float tone_colemak[][2] = SONG(COLEMAK_SOUND);
+float music_scale[][2] = SONG(MUSIC_SCALE_SOUND);
+
+float tone_goodbye[][2] = SONG(GOODBYE_SOUND);
+#endif
+
+
+void persistant_default_layer_set(uint16_t default_layer) {
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ case QWERTY:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_qwerty, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_QWERTY);
+ }
+ return false;
+ break;
+ case COLEMAK:
+ if (record->event.pressed) {
+ #ifdef AUDIO_ENABLE
+ PLAY_NOTE_ARRAY(tone_colemak, false, 0);
+ #endif
+ persistant_default_layer_set(1UL<<_COLEMAK);
+ }
+ return false;
+ break;
+ case LOWER:
+ if (record->event.pressed) {
+ layer_on(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case RAISE:
+ if (record->event.pressed) {
+ layer_on(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case BACKLIT:
+ if (record->event.pressed) {
+ register_code(KC_RSFT);
+ #ifdef BACKLIGHT_ENABLE
+ backlight_step();
+ #endif
+ } else {
+ unregister_code(KC_RSFT);
+ }
+ return false;
+ break;
+ }
+ return true;
+}
+
+void matrix_init_user(void) {
+ #ifdef AUDIO_ENABLE
+ startup_user();
+ #endif
+}
+
+#ifdef AUDIO_ENABLE
+
+void startup_user()
+{
+ _delay_ms(20); // gets rid of tick
+ PLAY_NOTE_ARRAY(tone_startup, false, 0);
+}
+
+void shutdown_user()
+{
+ PLAY_NOTE_ARRAY(tone_goodbye, false, 0);
+ _delay_ms(150);
+ stop_all_notes();
+}
+
+void music_on_user(void)
+{
+ music_scale_user();
+}
+
+void music_scale_user(void)
+{
+ PLAY_NOTE_ARRAY(music_scale, false, 0);
+}
+
+#endif
diff --git a/keyboards/planck/keymaps/sgoodwin/readme.md b/keyboards/planck/keymaps/sgoodwin/readme.md
new file mode 100644
index 0000000000..dfa88f380d
--- /dev/null
+++ b/keyboards/planck/keymaps/sgoodwin/readme.md
@@ -0,0 +1,10 @@
+# sgoodwin's Planck Layout
+
+Includes:
+
+1. No Dvorak or Plover
+2. No alt-swapping
+3. Right enter is shift when held down, enter when tapped.
+4. Bottom left corner in normal layers is Hyper and not brightness control.
+5. Brightness is instead in the bottom corner on raise/lower.
+
diff --git a/keyboards/planck/keymaps/tong92/Makefile b/keyboards/planck/keymaps/tong92/Makefile
new file mode 100644
index 0000000000..e6608e74c5
--- /dev/null
+++ b/keyboards/planck/keymaps/tong92/Makefile
@@ -0,0 +1,62 @@
+#----------------------------------------------------------------------------
+# On command line:
+#
+# make all = Make software.
+#
+# make clean = Clean out built project files.
+#
+# make coff = Convert ELF to AVR COFF.
+#
+# make extcoff = Convert ELF to AVR Extended COFF.
+#
+# make program = Download the hex file to the device.
+# Please customize your programmer settings(PROGRAM_CMD)
+#
+# make teensy = Download the hex file to the device, using teensy_loader_cli.
+# (must have teensy_loader_cli installed).
+#
+# make dfu = Download the hex file to the device, using dfu-programmer (must
+# have dfu-programmer installed).
+#
+# make flip = Download the hex file to the device, using Atmel FLIP (must
+# have Atmel FLIP installed).
+#
+# make dfu-ee = Download the eeprom file to the device, using dfu-programmer
+# (must have dfu-programmer installed).
+#
+# make flip-ee = Download the eeprom file to the device, using Atmel FLIP
+# (must have Atmel FLIP installed).
+#
+# make debug = Start either simulavr or avarice as specified for debugging,
+# with avr-gdb or avr-insight as the front end for debugging.
+#
+# make filename.s = Just compile filename.c into the assembler code only.
+#
+# make filename.i = Create a preprocessed source file for use in submitting
+# bug reports to the GCC project.
+#
+# To rebuild project do "make clean" then "make all".
+#----------------------------------------------------------------------------
+# Build Options
+# change to "no" to disable the options, or define them in the makefile.mk in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = no # Audio control and System control(+450)
+CONSOLE_ENABLE = no # Console for debug(+400)
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+MIDI_ENABLE = no # MIDI controls
+AUDIO_ENABLE = no # Audio output on port C6
+UNICODE_ENABLE = no # Unicode
+BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/planck/keymaps/tong92/keymap.c b/keyboards/planck/keymaps/tong92/keymap.c
new file mode 100644
index 0000000000..2be28fb4f6
--- /dev/null
+++ b/keyboards/planck/keymaps/tong92/keymap.c
@@ -0,0 +1,146 @@
+//Author: tong92 <tong92power@gmail.com>
+
+#include "planck.h"
+#ifdef BACKLIGHT_ENABLE
+ #include "backlight.h"
+#endif
+
+// Fillers to make layering more clear
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+#define LOWER M(1)
+#define RAISE M(2)
+#define GO_DEFT M(99)
+#
+
+//MIT Layout
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+/* 0: Qwerty layer (Default)
+* ,-----------------------------------------------------------------------.
+* |Tab | q | w | e | r | t | y | u | i | o | p | BS |
+* |-----------------------------------------------------------------------|
+* |Ctrl | a | s | d | f | g | h | j | k | l | ; |enter|
+* |-----------------------------------------------------------------------|
+* |Shift| z | x | c | v | b | n | m | , | . | / |Shift|
+* |-----------------------------------------------------------------------|
+* | Fn |Ctrl | Win | Alt |Lower| Space |Upper| ' | [ | ] | Alt |
+* `-----------------------------------------------------------------------'
+*/
+[0] ={
+{KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC},
+{KC_LCTL,KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_ENT },
+{KC_LSFT,KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM,KC_DOT, KC_SLSH,KC_RSFT},
+{MO(4), KC_RCTL,KC_LGUI,KC_LALT,LOWER,KC_SPC,KC_SPC,RAISE,KC_QUOT,KC_LBRC,KC_RBRC,KC_RALT}
+},
+/* 1: Lower layer
+* ,-----------------------------------------------------------------------.
+* | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | BS |
+* |-----------------------------------------------------------------------|
+* | | F1 | F2 | F3 | F4 | F5 | F6 | - | + | [ | ] | \ |
+* |-----------------------------------------------------------------------|
+* | | F7 | F8 | F9 | F10 | F11 | F12 | | HOME| PgUp| UP | PgDo|
+* |-----------------------------------------------------------------------|
+* | | | | | | SPACE |mouse| END | LEFT| DOWN|RIGHT|
+* `-----------------------------------------------------------------------'
+*/
+[1] ={
+{KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC },
+{_______,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS,KC_PLUS,KC_LBRC,KC_RBRC,KC_BSLS },
+{_______,KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,KC_F12,_______,KC_HOME,KC_PGUP,KC_UP ,KC_PGDN },
+{XXXXXXX,_______,_______,_______,_______,KC_SPC,KC_SPC,_______,KC_END, KC_LEFT,KC_DOWN,KC_RIGHT}
+},
+/* 2: Upper layer
+* ,-----------------------------------------------------------------------.
+* | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | BS |
+* |-----------------------------------------------------------------------|
+* | | F1 | F2 | F3 | F4 | F5 | F6 | _ | = | { | } | | |
+* |-----------------------------------------------------------------------|
+* | | F7 | F8 | F9 | F10 | F11 | F12 | | HOME| PgUp| UP | PgDo|
+* |-----------------------------------------------------------------------|
+* | | | | |mouse| SPACE | | END | LEFT| DOWN|RIGHT|
+* `-----------------------------------------------------------------------'
+*/
+[2] ={
+{KC_TILD,KC_EXLM,KC_AT, KC_HASH,KC_DLR, KC_PERC,KC_CIRC,KC_AMPR,KC_ASTR,KC_LPRN,KC_RPRN,KC_BSPC },
+{_______,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS,KC_EQL, KC_LCBR,KC_RCBR,KC_PIPE },
+{_______,KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______,KC_HOME,KC_PGUP,KC_UP ,KC_PGDN },
+{XXXXXXX,_______,_______,_______,_______,KC_SPC, KC_SPC, _______,KC_END, KC_LEFT,KC_DOWN,KC_RIGHT}
+},
+/* 4: fn layer (Window shortcuts)
+* ,-----------------------------------------------------------------------.
+* | ESC |WinOf|WinUp| | |Sh+Ca| | PgUp| UP | PgDo|PrtSc| DEL |
+* |-----------------------------------------------------------------------|
+* | |WinLe|WinDo|WinRi| |Al+Ca|CapsL| LEFT| DOWN|RIGHT| | |
+* |-----------------------------------------------------------------------|
+* | |WinLW|WinRW| | |Ct+Ca|ScroL| HOME| | END | | |
+* |-----------------------------------------------------------------------|
+* | |DeskL|DeskR|DeskX|Task | ChangeLang| | | | | LED |
+* `-----------------------------------------------------------------------'
+*/
+[4] ={
+{KC_ESC ,LALT(KC_F4) ,LGUI(KC_UP) ,XXXXXXX ,XXXXXXX ,S(KC_CAPS) ,XXXXXXX,KC_PGUP,KC_UP,KC_PGDN,KC_PSCR,KC_DELT},
+{_______,LGUI(KC_LEFT) ,LGUI(KC_DOWN) ,LGUI(KC_RIGHT) ,XXXXXXX ,LALT(KC_CAPS),KC_CAPS,KC_LEFT,KC_DOWN,KC_RIGHT,XXXXXXX,XXXXXXX},
+{_______,LGUI(LSFT(KC_LEFT)),LGUI(LSFT(KC_RIGHT)),XXXXXXX ,XXXXXXX ,LCTL(KC_CAPS),KC_SLCK,KC_HOME,XXXXXXX,KC_END,XXXXXXX,XXXXXXX},
+{KC_TRNS,LGUI(LCTL(KC_LEFT)),LGUI(LCTL(KC_RIGHT)),LGUI(LCTL(KC_F4)),LCTL(LALT(KC_DELT)),LGUI(KC_SPC),LGUI(KC_SPC),XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,M(0)}
+},
+/* 10: mouse layer
+* ,-----------------------------------------------------------------------.
+* | | | |Mo_Up| | | |M_WhL|M_WhU|M_WhR| |RESET|
+* |-----------------------------------------------------------------------|
+* | | |Mo_Le|Mo_Do|Mo_Ri| | |M_Bt1|M_WhD|M_Bt2| | |
+* |-----------------------------------------------------------------------|
+* | | | | | | | |M_AC0|M_AC1|M_AC2| | |
+* |-----------------------------------------------------------------------|
+* | | | | | | GO_DEFT | | | | | |
+* `-----------------------------------------------------------------------'
+*/
+[10] ={
+{XXXXXXX,XXXXXXX,XXXXXXX,KC_MS_U,XXXXXXX,XXXXXXX,XXXXXXX,KC_WH_L,KC_WH_U,KC_WH_R,XXXXXXX,RESET},
+{XXXXXXX,XXXXXXX,KC_MS_L,KC_MS_D,KC_MS_R,XXXXXXX,XXXXXXX,KC_BTN1,KC_WH_D,KC_BTN2,XXXXXXX,XXXXXXX},
+{XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,KC_ACL0,KC_ACL1,KC_ACL2,XXXXXXX,XXXXXXX},
+{XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,GO_DEFT,GO_DEFT,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX,XXXXXXX}
+}
+
+};
+//Layout END
+
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ switch(id) {
+ case 0:
+ if (record->event.pressed) {
+ #ifdef BACKLIGHT_ENABLE
+ backlight_step();
+ #endif
+ }
+ break;
+ case 1:
+ if (record->event.pressed) {
+ layer_on(1);
+ update_tri_layer(1, 2, 10);
+ } else {
+ layer_off(1);
+ update_tri_layer(1, 2, 10);
+ }
+ break;
+ case 2:
+ if (record->event.pressed) {
+ layer_on(2);
+ update_tri_layer(1, 2, 10);
+ } else {
+ layer_off(2);
+ update_tri_layer(1, 2, 10);
+ }
+ break;
+ case 99:
+ if (record->event.pressed) {
+ layer_off(10);
+ layer_off(1);
+ layer_off(2);
+ layer_on(0);
+ update_tri_layer(0 ,1 ,2);
+ }
+ break;
+ }
+ return MACRO_NONE;
+}; \ No newline at end of file
diff --git a/keyboards/planck/keymaps/tong92/readme.md b/keyboards/planck/keymaps/tong92/readme.md
new file mode 100644
index 0000000000..328d005f6f
--- /dev/null
+++ b/keyboards/planck/keymaps/tong92/readme.md
@@ -0,0 +1,66 @@
+# The Tong92 Layout
+- MIT Layout
+- my keymap for WIndow User
+- Lower && Upper Hold -> Mouse Layer
+- Mouse Layer : space -> Default Layer
+- No Audio
+
+## 1. Default Layer - Qwerty
+
+ ,-----------------------------------------------------------------------.
+ |Tab | q | w | e | r | t | y | u | i | o | p | BS |
+ |-----------------------------------------------------------------------|
+ |Ctrl | a | s | d | f | g | h | j | k | l | ; |enter|
+ |-----------------------------------------------------------------------|
+ |Shift| z | x | c | v | b | n | m | , | . | / |Shift|
+ |-----------------------------------------------------------------------|
+ | Fn |Ctrl | Win | Alt |Lower| Space |Upper| ' | [ | ] | Alt |
+ `-----------------------------------------------------------------------'
+
+## 2. Lower Layer
+
+ ,-----------------------------------------------------------------------.
+ | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | BS |
+ |-----------------------------------------------------------------------|
+ | | F1 | F2 | F3 | F4 | F5 | F6 | - | + | [ | ] | \ |
+ |-----------------------------------------------------------------------|
+ | | F7 | F8 | F9 | F10 | F11 | F12 | | HOME| PgUp| UP | PgDo|
+ |-----------------------------------------------------------------------|
+ | | | | | | SPACE |mouse| END | LEFT| DOWN|RIGHT|
+ `-----------------------------------------------------------------------'
+
+## 3. Upper Layer
+
+ ,-----------------------------------------------------------------------.
+ | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | BS |
+ |-----------------------------------------------------------------------|
+ | | F1 | F2 | F3 | F4 | F5 | F6 | _ | = | { | } | | |
+ |-----------------------------------------------------------------------|
+ | | F7 | F8 | F9 | F10 | F11 | F12 | | HOME| PgUp| UP | PgDo|
+ |-----------------------------------------------------------------------|
+ | | | | |mouse| SPACE | | END | LEFT| DOWN|RIGHT|
+ `-----------------------------------------------------------------------'
+
+## 4. Fn Layer - Window Shortcuts
+
+ ,-----------------------------------------------------------------------.
+ | ESC |WinOf|WinUp| | |Sh+Ca| | PgUp| UP | PgDo|PrtSc| DEL |
+ |-----------------------------------------------------------------------|
+ | |WinLe|WinDo|WinRi| |Al+Ca|CapsL| LEFT| DOWN|RIGHT| | |
+ |-----------------------------------------------------------------------|
+ | |WinLW|WinRW| | |Ct+Ca|ScroL| HOME| | END | | |
+ |-----------------------------------------------------------------------|
+ | |DeskL|DeskR|DeskX|Task | ChangeLang| | | | | LED |
+ `-----------------------------------------------------------------------'
+
+## 5. Mouse Layer
+
+ ,-----------------------------------------------------------------------.
+ | | | |Mo_Up| | | |M_WhL|M_WhU|M_WhR| |RESET|
+ |-----------------------------------------------------------------------|
+ | | |Mo_Le|Mo_Do|Mo_Ri| | |M_Bt1|M_WhD|M_Bt2| | |
+ |-----------------------------------------------------------------------|
+ | | | | | | | |M_AC0|M_AC1|M_AC2| | |
+ |-----------------------------------------------------------------------|
+ | | | | | |GO_DEFAULT | | | | | |
+ `-----------------------------------------------------------------------' \ No newline at end of file
diff --git a/keyboards/planck/readme.md b/keyboards/planck/readme.md
index f89fdeb931..4b24a690e0 100644
--- a/keyboards/planck/readme.md
+++ b/keyboards/planck/readme.md
@@ -13,15 +13,17 @@ Download or clone the whole firmware and navigate to the keyboards/planck folder
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|jack|<name>]
```
+
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
### Notable forks (which some of the keymap files are from)
diff --git a/keyboards/planck/rev3/Makefile b/keyboards/planck/rev3/Makefile
index 3ed1445e43..191c6bb664 100644
--- a/keyboards/planck/rev3/Makefile
+++ b/keyboards/planck/rev3/Makefile
@@ -1,5 +1,3 @@
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/planck/rev3/rules.mk b/keyboards/planck/rev3/rules.mk
new file mode 100644
index 0000000000..3ed1445e43
--- /dev/null
+++ b/keyboards/planck/rev3/rules.mk
@@ -0,0 +1,5 @@
+AUDIO_ENABLE ?= no # Audio output on port C6
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/planck/rev4/Makefile b/keyboards/planck/rev4/Makefile
index ed09f85a4d..191c6bb664 100644
--- a/keyboards/planck/rev4/Makefile
+++ b/keyboards/planck/rev4/Makefile
@@ -1,5 +1,3 @@
-AUDIO_ENABLE ?= yes # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/planck/rev4/rules.mk b/keyboards/planck/rev4/rules.mk
new file mode 100644
index 0000000000..ed09f85a4d
--- /dev/null
+++ b/keyboards/planck/rev4/rules.mk
@@ -0,0 +1,5 @@
+AUDIO_ENABLE ?= yes # Audio output on port C6
+
+ifndef QUANTUM_DIR
+ include ../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/planck/rules.mk b/keyboards/planck/rules.mk
new file mode 100644
index 0000000000..25db53a315
--- /dev/null
+++ b/keyboards/planck/rules.mk
@@ -0,0 +1,67 @@
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no # Audio output on port C6
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend \ No newline at end of file
diff --git a/keyboards/preonic/Makefile b/keyboards/preonic/Makefile
index 08e9205cbf..4e2a6f00fd 100644
--- a/keyboards/preonic/Makefile
+++ b/keyboards/preonic/Makefile
@@ -1,73 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-# Build Options
-# change to "no" to disable the options, or define them in the Makefile in
-# the appropriate keymap folder that will get included automatically
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no # Audio output on port C6
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
-
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
endif \ No newline at end of file
diff --git a/keyboards/preonic/readme.md b/keyboards/preonic/readme.md
index f0be255a09..10763ee97a 100644
--- a/keyboards/preonic/readme.md
+++ b/keyboards/preonic/readme.md
@@ -13,13 +13,15 @@ Download or clone the whole firmware and navigate to the keyboards/preonic folde
Depending on which keymap you would like to use, you will have to compile slightly differently.
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap, create a file in the keymaps folder named `<name>.c` and see keymap document (you can find in top readme.md) and existent keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
+
```
-$ make KEYMAP=[default|jack|<name>]
+$ make [default|jack|<name>]
```
+
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
diff --git a/keyboards/preonic/rules.mk b/keyboards/preonic/rules.mk
new file mode 100644
index 0000000000..d0f3a3a1c0
--- /dev/null
+++ b/keyboards/preonic/rules.mk
@@ -0,0 +1,69 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no # Audio output on port C6
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE ?= no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend \ No newline at end of file
diff --git a/keyboards/readme.md b/keyboards/readme.md
index 4f17962191..81a23c7e55 100644
--- a/keyboards/readme.md
+++ b/keyboards/readme.md
@@ -9,38 +9,47 @@ These keyboards are manufactured by the maintainers of QMK.
What makes OLKB keyboards shine is a combo of lean aesthetics, compact size, and killer tactile feel. These are available through [olkb.com](http://olkb.com) as well as through [Massdrop](http://massdrop.com) from time to time, as easy to assemble kits.
-* [Planck](/keyboards/planck/) - A 40% DIY powerhouse of customizability and modification capability. It's a lean, mean, typing machine.
-* [Preonic](/keyboards/preonic/) - Like the Planck, but bigger. 50%.
-* [Atomic](/keyboards/atomic/) - Imagine the size of the Planck. Now imagine the size of the Preonic. Now imagine _bigger_. That is the Atomic. A 60% keyboard.
+* [Planck](/keyboards/planck/) &mdash; A 40% DIY powerhouse of customizability and modification capability. It's a lean, mean, typing machine.
+* [Preonic](/keyboards/preonic/) &mdash; Like the Planck, but bigger. 50%.
+* [Atomic](/keyboards/atomic/) &mdash; Imagine the size of the Planck. Now imagine the size of the Preonic. Now imagine _bigger_. That is the Atomic. A 60% keyboard.
### ErgoDox EZ - Erez Zukerman
Made in Taiwan using advanced robotic manufacturing, the ErgoDox EZ is a fully-assembled, premium ergonomic keyboard. Its split design allows you to place both halves shoulder width, and its custom-made wrist rests and tilt/tent kit make for incredibly comfortable typing. Available on [ergodox-ez.com](https://ergodox-ez.com).
-* [ErgoDox EZ](/keyboards/ergodox/) - Our one and only product. Yes, it's that awesome. Comes with either printed or blank keycaps, and 7 different keyswitch types.
+* [ErgoDox EZ](/keyboards/ergodox/) &mdash; Our one and only product. Yes, it's that awesome. Comes with either printed or blank keycaps, and 7 different keyswitch types.
### Clueboard - Zach White
Designed and built in Felton, CA, Clueboards keyboard emphasize quality and locally sourced components, available on [clueboard.co](http://clueboard.co)
-* [Clueboard](/keyboards/clueboard/) - The 66% custom keyboard.
-* [Cluepad](/keyboards/cluepad/) - A mechanical numpad with QMK superpowers.
+* [Clueboard](/keyboards/clueboard/) &mdash; The 66% custom keyboard.
+* [Cluecard](/keyboards/cluecard/) &mdash; A small board to help you hack on QMK.
+* [Cluepad](/keyboards/cluepad/) &mdash; A mechanical numpad with QMK superpowers.
## Community-supported QMK Keyboards
These keyboards are part of the QMK repository, but their manufacturers are not official maintainers of the repository.
-* [alps64](/keyboards/alps64/) &mdash; A 60% keyboard for Alps keyswitches.
-* [arrow_pad](/keyboards/arrow_pad) &mdash; A custom creation by IBNobody.
-* [atreus](/keyboards/atreus) &mdash; Made by Technomancy.
-* [bantam44](/keyboards/bantam44) &mdash; It is a 44-key 40% staggered keyboard.
-* [gh60](/keyboards/gh60) &mdash; A 60% Geekhack community-driven project.
-* [hhkb](/keyboards/hhkb) &mdash; The Happy Hacking keyboard can be hacked with a custom controller to run QMK.
-* [jd45](/keyboards/jd45) &mdash; Another Geekhack community project, designed by jdcarpe.
-* [kc60](/keyboards/kc60) &mdash; A programmable Chinese-made keyboard, lost in the mists of time.
-* [kitten_paw](/keyboards/kitten_paw) &mdash; A replacement controller (2016 revision) for the Filco Majestouch by [Bathroom Epiphanies](https://github.com/BathroomEpiphanies)
-* [phantom](/keyboards/phantom) &mdash; A tenkeyless kit by Teel, also from Geekhack.
-* [retro_refit](/keyboards/retro_refit) &mdash; Another creation by IBNobody.
-* [satan](/keyboards/satan) &mdash; A GH60 variant.
-* [sixkeyboard](/keyboards/sixkeyboard) &mdash; A 6-key keyboard made by TechKeys.
+* [Alps64](/keyboards/alps64) &mdash; A 60% keyboard for Alps keyswitches.
+* [AMJ60](/keyboards/amj60) &mdash; DIY/Assembled compact 60% keyboard.
+* [Arrow Pad](/keyboards/arrow_pad) &mdash; A custom creation by IBNobody.
+* [Atreus](/keyboards/atreus) &mdash; Made by Technomancy.
+* [Bantam44](/keyboards/bantam44) &mdash; It is a 44-key 40% staggered keyboard.
+* [Ergodox Infinity](/keyboards/ergodox) - Ergonomic Split Keyboard by Input Club.
+* [GH60](/keyboards/gh60) &mdash; A 60% Geekhack community-driven project.
+* [Happy Hacking Keyboard](/keyboards/hhkb) &mdash; The Happy Hacking keyboard can be hacked with a custom controller to run QMK.
+* [Infinity 60%](/keyboards/infinity60) - &mdash; Compact community keyboard by Input Club.
+* [JD45](/keyboards/jd45) &mdash; Another Geekhack community project, designed by jdcarpe.
+* [KC60](/keyboards/kc60) &mdash; A programmable Chinese-made keyboard, lost in the mists of time.
+* [Kinesis Advantage](/keyboards/kinesis) &mdash; Contoured ergonomic keyboard by Kinesis Computer Ergonomics.
+* [The Kitten Paw](/keyboards/kitten_paw) &mdash; A replacement controller (2016 revision) for the Filco Majestouch by [Bathroom Epiphanies](https://github.com/BathroomEpiphanies).
+* [Lets Split](/keyboards/lets_split) - Split ortholinear 40% keyboard.
+* [Phantom](/keyboards/phantom) &mdash; A tenkeyless kit by Teel, also from Geekhack.
+* [Retro Refit](/keyboards/retro_refit) &mdash; Another creation by IBNobody.
+* [S60-x](/keyboards/s60-x) &mdash; DIY compact keyboard designed by VinnyCordeiro for Sentraq.
+* [Satan](/keyboards/satan) &mdash; A GH60 variant.
+* [SixKeyBoard](/keyboards/sixkeyboard) &mdash; A 6-key keyboard made by TechKeys.
+* [TheVan 44](/keyboars/tv44) &mdash; A 44-key staggered keybard by Evangs.
+* [Vision Division](/keyboards/vision_division) &mdash; Full Size / Split Linear Keyboard by IBNobody.
diff --git a/keyboards/retro_refit/readme.md b/keyboards/retro_refit/readme.md
deleted file mode 100644
index b01a1a9ca9..0000000000
--- a/keyboards/retro_refit/readme.md
+++ /dev/null
@@ -1,24 +0,0 @@
-retro_refit keyboard firmware
-======================
-
-## Quantum MK Firmware
-
-For the full Quantum feature list, see [the parent readme.md](/readme.md).
-
-## Building
-
-Download or clone the whole firmware and navigate to the keyboards/retro_refit folder. Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Teensy Loader to program your .hex file.
-
-Depending on which keymap you would like to use, you will have to compile slightly differently.
-
-### Default
-To build with the default keymap, simply run `make`.
-
-### Other Keymaps
-Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` and see keymap document (you can find in top readme.md) and existent keymap files.
-
-To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
-```
-$ make KEYMAP=[default|jack|<name>]
-```
-Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder. \ No newline at end of file
diff --git a/keyboards/s60-x/Makefile b/keyboards/s60-x/Makefile
index 8b51d4609f..4e2a6f00fd 100644
--- a/keyboards/s60-x/Makefile
+++ b/keyboards/s60-x/Makefile
@@ -1,75 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= no # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
-
+endif \ No newline at end of file
diff --git a/keyboards/s60-x/readme.md b/keyboards/s60-x/readme.md
index 099d586991..94ce829223 100644
--- a/keyboards/s60-x/readme.md
+++ b/keyboards/s60-x/readme.md
@@ -42,9 +42,9 @@ The recommended programs for flashing your keyboard are [Atmel FLIP](http://www.
## Building the firmware
-To build firmware binary hex file with a certain keymap just run `make` with the `keymap` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
- $ make keymap=[custom|poker|poker_set|poker_bit|plain|hasu|spacefn|hhkb|<name>]
+ $ make [custom|poker|poker_set|poker_bit|plain|hasu|spacefn|hhkb|<name>]
For a more detailed explanation of the build process and the environment setup, see the ["Getting Started" section](/readme.md#getting-started).
diff --git a/keyboards/s60-x/rules.mk b/keyboards/s60-x/rules.mk
new file mode 100644
index 0000000000..7ec93933a9
--- /dev/null
+++ b/keyboards/s60-x/rules.mk
@@ -0,0 +1,69 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= no # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6 \ No newline at end of file
diff --git a/keyboards/satan/Makefile b/keyboards/satan/Makefile
index a0879fc9c9..4e2a6f00fd 100644
--- a/keyboards/satan/Makefile
+++ b/keyboards/satan/Makefile
@@ -1,70 +1,3 @@
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-RGBLIGHT_ENABLE ?= yes # Enable keyboard underlight functionality (+4870)
-BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality (+1150)
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
+endif \ No newline at end of file
diff --git a/keyboards/satan/rules.mk b/keyboards/satan/rules.mk
new file mode 100644
index 0000000000..1102584d8a
--- /dev/null
+++ b/keyboards/satan/rules.mk
@@ -0,0 +1,66 @@
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+RGBLIGHT_ENABLE ?= yes # Enable keyboard underlight functionality (+4870)
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality (+1150)
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
diff --git a/keyboards/sixkeyboard/Makefile b/keyboards/sixkeyboard/Makefile
index 6f273064a7..4e2a6f00fd 100644
--- a/keyboards/sixkeyboard/Makefile
+++ b/keyboards/sixkeyboard/Makefile
@@ -1,75 +1,3 @@
-
-
-SRC = matrix.c
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega16u2
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# comment out to disable the options.
-#
-BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= no # Audio control and System control(+450)
-CONSOLE_ENABLE ?= no # Console for debug(+400)
-COMMAND_ENABLE ?= no # Commands for debug and configuration
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-NKRO_ENABLE ?= no # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality
-MIDI_ENABLE ?= no # MIDI controls
-AUDIO_ENABLE ?= no
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-CUSTOM_MATRIX = yes
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
+endif \ No newline at end of file
diff --git a/keyboards/sixkeyboard/rules.mk b/keyboards/sixkeyboard/rules.mk
new file mode 100644
index 0000000000..2c99985a97
--- /dev/null
+++ b/keyboards/sixkeyboard/rules.mk
@@ -0,0 +1,70 @@
+
+
+SRC = matrix.c
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega16u2
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= no # Audio control and System control(+450)
+CONSOLE_ENABLE ?= no # Console for debug(+400)
+COMMAND_ENABLE ?= no # Commands for debug and configuration
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+NKRO_ENABLE ?= no # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+CUSTOM_MATRIX = yes \ No newline at end of file
diff --git a/keyboards/tada68/Makefile b/keyboards/tada68/Makefile
new file mode 100644
index 0000000000..4e2a6f00fd
--- /dev/null
+++ b/keyboards/tada68/Makefile
@@ -0,0 +1,3 @@
+ifndef MAKEFILE_INCLUDED
+ include ../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/tada68/config.h b/keyboards/tada68/config.h
new file mode 100644
index 0000000000..5d8757936d
--- /dev/null
+++ b/keyboards/tada68/config.h
@@ -0,0 +1,97 @@
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef CONFIG_H
+#define CONFIG_H
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0xFEED
+#define PRODUCT_ID 0x6060
+#define DEVICE_VER 0x0003
+#define MANUFACTURER TADA
+#define PRODUCT TADA68
+#define DESCRIPTION QMK keyboard firmware for TADA68 with WS2812 support
+
+/* key matrix size */
+#define MATRIX_ROWS 5
+#define MATRIX_COLS 15
+
+// ROWS: Top to bottom, COLS: Left to right
+
+#define MATRIX_ROW_PINS {D0,D1,F6,F7,D5}
+#define MATRIX_COL_PINS {F0,F1,E6,C7,C6,B7,D4,B1,B0,B5,B4,D7,D6,B3,F4}
+#define UNUSED_PINS
+
+#define BACKLIGHT_PIN B6
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* define if matrix has ghost */
+//#define MATRIX_HAS_GHOST
+
+/* Set 0 if debouncing isn't needed */
+#define DEBOUNCING_DELAY 5
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+/* key combination for command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
+)
+
+/* Backlight configuration
+ */
+#define BACKLIGHT_LEVELS 4
+
+/* Underlight configuration
+ */
+
+/*#define RGB_DI_PIN E2
+#define RGBLIGHT_TIMER
+#define RGBLED_NUM 2 // Number of LEDs
+#define RGBLIGHT_HUE_STEP 10
+#define RGBLIGHT_SAT_STEP 17
+#define RGBLIGHT_VAL_STEP 17*/
+//Disabled while I figure out a suitable pin for RGB support.
+//I've tried F5, D2, D3, and E2 but it's possible the end of my
+//strand is bad. New LEDs on order.
+
+/*
+ * Feature disable options
+ * These options are also useful to firmware size reduction.
+ */
+
+/* disable debug print */
+//#define NO_DEBUG
+
+/* disable print */
+//#define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
+//#define NO_ACTION_MACRO
+//#define NO_ACTION_FUNCTION
+
+#endif
diff --git a/keyboards/tada68/keymaps/default/Makefile b/keyboards/tada68/keymaps/default/Makefile
new file mode 100644
index 0000000000..2a7ff27793
--- /dev/null
+++ b/keyboards/tada68/keymaps/default/Makefile
@@ -0,0 +1,21 @@
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
+CONSOLE_ENABLE = no # Console for debug(+400)
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+MIDI_ENABLE = no # MIDI controls
+AUDIO_ENABLE = no # Audio output on port C6
+UNICODE_ENABLE = no # Unicode
+BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif
diff --git a/keyboards/tada68/keymaps/default/keymap.c b/keyboards/tada68/keymaps/default/keymap.c
new file mode 100644
index 0000000000..da57c0343b
--- /dev/null
+++ b/keyboards/tada68/keymaps/default/keymap.c
@@ -0,0 +1,98 @@
+#include "tada68.h"
+
+
+// Used for SHIFT_ESC
+#define MODS_CTRL_MASK (MOD_BIT(KC_LSHIFT)|MOD_BIT(KC_RSHIFT))
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _BL 0
+#define _FL 1
+
+#define _______ KC_TRNS
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ /* Keymap _BL: (Base Layer) Default Layer
+ * ,----------------------------------------------------------------.
+ * |Esc | 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backsp |~ ` |
+ * |----------------------------------------------------------------|
+ * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \ |Del |
+ * |----------------------------------------------------------------|
+ * |CAPS | A| S| D| F| G| H| J| K| L| ;| '|Return |PgUp|
+ * |----------------------------------------------------------------|
+ * |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift | Up|PgDn|
+ * |----------------------------------------------------------------|
+ * |Ctrl|Win |Alt | Space |Alt| FN|Ctrl|Lef|Dow|Rig |
+ * `----------------------------------------------------------------'
+ */
+[_BL] = KEYMAP_ANSI(
+ KC_ESC, 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_GRV, \
+ 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_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,KC_PGUP, \
+ 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,KC_PGDN, \
+ KC_LCTL, KC_LGUI,KC_LALT, KC_SPC, KC_RALT,MO(_FL),KC_RCTRL, KC_LEFT,KC_DOWN,KC_RGHT),
+
+ /* Keymap _FL: Function Layer
+ * ,----------------------------------------------------------------.
+ * | | | | | | | | | | | | | | RESET| |
+ * |----------------------------------------------------------------|
+ * | | | | | | | | | | | |BL-|BL+|BL | |
+ * |----------------------------------------------------------------|
+ * | | | | | | | | | | | | | |
+ * |----------------------------------------------------------------|
+ * | | F1|F2 | F3|F4 | F5| F6| F7| F8| | | | | |
+ * |----------------------------------------------------------------|
+ * | | | | | | | | | | |
+ * `----------------------------------------------------------------'
+ */
+[_FL] = KEYMAP_ANSI(
+ #ifdef RGBLIGHT_ENABLE
+ _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,RESET,_______, \
+ _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, BL_DEC,BL_INC, BL_TOGG,_______, \
+ _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______, \
+ _______,RGB_TOG,RGB_MOD,RGB_HUI,RGB_HUD,RGB_SAI,RGB_SAD,RGB_VAI,RGB_VAD,_______,_______,_______,_______,_______, \
+ _______,_______,_______, _______, _______,_______,_______,_______,_______, _______),
+ #else
+ _______, _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,RESET,_______, \
+ _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, BL_DEC,BL_INC, BL_TOGG,_______, \
+ _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, _______,_______, \
+ _______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______,_______, \
+ _______,_______,_______, _______, _______,_______,_______,_______,_______, _______),
+ #endif
+};
+
+/*enum function_id {
+ //SHIFT_ESC,
+};
+
+const uint16_t PROGMEM fn_actions[] = {
+ //[0] = ACTION_FUNCTION(SHIFT_ESC),
+};
+
+void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) {
+ static uint8_t shift_esc_shift_mask;
+ switch (id) {
+ case SHIFT_ESC:
+ shift_esc_shift_mask = get_mods()&MODS_CTRL_MASK;
+ if (record->event.pressed) {
+ if (shift_esc_shift_mask) {
+ add_key(KC_GRV);
+ send_keyboard_report();
+ } else {
+ add_key(KC_ESC);
+ send_keyboard_report();
+ }
+ } else {
+ if (shift_esc_shift_mask) {
+ del_key(KC_GRV);
+ send_keyboard_report();
+ } else {
+ del_key(KC_ESC);
+ send_keyboard_report();
+ }
+ }
+ break;
+ }
+}*/
diff --git a/keyboards/tada68/keymaps/default/readme.md b/keyboards/tada68/keymaps/default/readme.md
new file mode 100644
index 0000000000..36760d6b91
--- /dev/null
+++ b/keyboards/tada68/keymaps/default/readme.md
@@ -0,0 +1 @@
+# default TADA68 layout
diff --git a/keyboards/tada68/readme.md b/keyboards/tada68/readme.md
new file mode 100644
index 0000000000..552fdea529
--- /dev/null
+++ b/keyboards/tada68/readme.md
@@ -0,0 +1,4 @@
+TADA68 keyboard firmware
+======================
+
+TODO: to be updated.
diff --git a/keyboards/tada68/rules.mk b/keyboards/tada68/rules.mk
new file mode 100644
index 0000000000..d8ec423655
--- /dev/null
+++ b/keyboards/tada68/rules.mk
@@ -0,0 +1,66 @@
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# comment out to disable the options.
+#
+BOOTMAGIC_ENABLE ?= no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= no # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+NKRO_ENABLE ?= yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+RGBLIGHT_ENABLE ?= no # Enable keyboard underlight functionality (+4870)
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality (+1150)
+MIDI_ENABLE ?= no # MIDI controls
+AUDIO_ENABLE ?= no
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
diff --git a/keyboards/tada68/tada68.c b/keyboards/tada68/tada68.c
new file mode 100644
index 0000000000..24f89048cb
--- /dev/null
+++ b/keyboards/tada68/tada68.c
@@ -0,0 +1,30 @@
+#include "tada68.h"
+#include "led.h"
+
+void matrix_init_kb(void) {
+ // put your keyboard start-up code here
+ // runs once when the firmware starts up
+ matrix_init_user();
+ led_init_ports();
+};
+
+void matrix_scan_kb(void) {
+ // put your looping keyboard code here
+ // runs every cycle (a lot)
+ matrix_scan_user();
+};
+
+void led_init_ports(void) {
+ // * Set our LED pins as output
+ DDRB |= (1<<2);
+}
+
+void led_set_kb(uint8_t usb_led) {
+ if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
+ // Turn capslock on
+ PORTB &= ~(1<<2);
+ } else {
+ // Turn capslock off
+ PORTB |= (1<<2);
+ }
+}
diff --git a/keyboards/tada68/tada68.h b/keyboards/tada68/tada68.h
new file mode 100644
index 0000000000..d0e027a6f4
--- /dev/null
+++ b/keyboards/tada68/tada68.h
@@ -0,0 +1,43 @@
+#ifndef TADA68_H
+#define TADA68_H
+
+#include "quantum.h"
+
+// readability
+#define XXX KC_NO
+
+/* TADA68 ANSI layout
+ * ,----------------------------------------------------------------.
+ * | 00 |01| 02| 03| 04| 05| 06| 07| 08| 09| 0a| 0b| 0c| 0d | 0e |
+ * |----------------------------------------------------------------|
+ * | 10 | 11| 12| 13| 14| 15| 16| 17| 18| 19| 1a| 1b| 1c| 1d | 1e |
+ * |----------------------------------------------------------------|
+ * | 20 | 21| 22| 23| 24| 25| 26| 27| 28| 29| 2a| 2b| 2d | 2e |
+ * |----------------------------------------------------------------|
+ * | 30 | 32| 33| 34| 35| 36| 37| 38| 39| 3a| 3b| 3c| 3d| 3e |
+ * |----------------------------------------------------------------|
+ * | 40 | 41 | 42 | 45 | 49| 4a| 4b| 4c| 4d| 4e |
+ * `----------------------------------------------------------------'
+ */
+// The first section contains all of the arguments
+// The second converts the arguments into a two-dimensional array
+
+#define KEYMAP_ANSI( \
+ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0d, k0e, \
+ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d, k1e, \
+ k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2d, k2e, \
+ k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, k3e, \
+ k40, k41, k42, k45, k49, k4a, k4b, k4c, k4d, k4e \
+) \
+{ \
+ {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0d, k0e}, \
+ {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d, k1e}, \
+ {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, XXX, k2d, k2e}, \
+ {k30, XXX, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, k3e}, \
+ {k40, k41, k42, XXX, XXX, k45, XXX, XXX, XXX, k49, k4a, k4b, k4c, k4d, k4e} \
+}
+
+void matrix_init_user(void);
+void matrix_scan_user(void);
+
+#endif
diff --git a/keyboards/tv44/Makefile b/keyboards/tv44/Makefile
index 45ca127807..4e2a6f00fd 100644
--- a/keyboards/tv44/Makefile
+++ b/keyboards/tv44/Makefile
@@ -1,75 +1,3 @@
-
-
-# MCU name
-#MCU = at90usb1287
-MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=4096
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= yes # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
-
+endif \ No newline at end of file
diff --git a/keyboards/tv44/keymaps/jeebak/Makefile b/keyboards/tv44/keymaps/jeebak/Makefile
new file mode 100644
index 0000000000..f4671a9d11
--- /dev/null
+++ b/keyboards/tv44/keymaps/jeebak/Makefile
@@ -0,0 +1,21 @@
+# Build Options
+# change to "no" to disable the options, or define them in the Makefile in
+# the appropriate keymap folder that will get included automatically
+#
+BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
+CONSOLE_ENABLE = no # Console for debug(+400)
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
+MIDI_ENABLE = no # MIDI controls
+AUDIO_ENABLE = no # Audio output on port C6
+UNICODE_ENABLE = no # Unicode
+BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+
+ifndef QUANTUM_DIR
+ include ../../../../Makefile
+endif \ No newline at end of file
diff --git a/keyboards/tv44/keymaps/jeebak/config.h b/keyboards/tv44/keymaps/jeebak/config.h
new file mode 100644
index 0000000000..a59ef2b70a
--- /dev/null
+++ b/keyboards/tv44/keymaps/jeebak/config.h
@@ -0,0 +1,21 @@
+#ifndef CONFIG_USER_H
+#define CONFIG_USER_H
+
+#include "../../config.h"
+
+/**
+ *TV44 keymap definition macro
+ */
+#define KEYMAP_TV44( \
+ K01, K02, K03, K04, K05, K06, K07, K08, K09, K10, K11, K12, \
+ K13, K14, K15, K16, K17, K18, K19, K20, K21, K22, K23, K24, \
+ K25, K26, K27, K28, K29, K30, K31, K32, K33, K34, K35, K36, \
+ K37, K38, K39, K40, K41, K42, K43, K44 \
+) { \
+ { K01, K02, K03, K04, K05, K06, K07, K08, K09, K10, K11, K12, }, \
+ { K13, K14, K15, K16, K17, K18, K19, K20, K21, K22, K23, K24, }, \
+ { K25, K26, K27, K28, K29, K30, K31, K32, K33, K34, K35, K36, }, \
+ { K37, K38, K39, K40, KC_NO, KC_NO, KC_NO, K41, K42, K43, KC_NO, K44 } \
+}
+
+#endif
diff --git a/keyboards/tv44/keymaps/jeebak/keymap.c b/keyboards/tv44/keymaps/jeebak/keymap.c
new file mode 100644
index 0000000000..1bb1015c36
--- /dev/null
+++ b/keyboards/tv44/keymaps/jeebak/keymap.c
@@ -0,0 +1,425 @@
+#include "tv44.h"
+#include "action_layer.h"
+#include "eeconfig.h"
+
+extern keymap_config_t keymap_config;
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _QWERTY 0
+#define _COLEMAK 1
+#define _DVORAK 2
+#define _LOWER 3
+#define _RAISE 4
+#define _PLOVER 5
+#define _TOUCHCURSOR 6
+#define _MOUSECURSOR 7
+#define _ADJUST 16
+
+// Keycodes
+enum planck_keycodes {
+ QWERTY = SAFE_RANGE,
+ COLEMAK,
+ DVORAK,
+ PLOVER,
+ LOWER,
+ RAISE,
+ BACKLIT,
+ EXT_PLV
+};
+
+enum macro_keycodes {
+ KC_ALT_TAB,
+ KC_CMD_TAB,
+ KC_CTL_TAB,
+ KC_CMD_SLSH,
+ KC_AG_FIND,
+ KC_AG_AGAIN,
+ KC_AG_UNDO,
+ KC_AG_CUT,
+ KC_AG_COPY,
+ KC_AG_PASTE,
+ KC_AG_DESK_L,
+ KC_AG_DESK_R,
+ KC_AG_TAB_C,
+ KC_AG_TAB_N,
+ KC_AG_TAB_R,
+};
+
+// Fillers to make layering more clear
+#define _______ KC_TRNS
+#define XXXXXXX KC_NO
+
+// Custom macros
+#define CTL_ESC CTL_T(KC_ESC) // Tap for Esc, hold for Ctrl
+#define SFT_ENT SFT_T(KC_ENT) // Tap for Enter, hold for Shift
+#define HPR_TAB ALL_T(KC_TAB) // Tap for Tab, hold for Hyper
+#define GUI_SEM GUI_T(KC_SCLN) // Tap for Semicolon, hold for GUI
+#define ALT_QUO ALT_T(KC_QUOT) // Tap for Quote, hold for Alt
+// Requires KC_TRNS/_______ for the trigger key in the destination layer
+#define LT_TC LT(_TOUCHCURSOR, KC_SPC) // L-ayer T-ap T-ouch C-ursor
+#define LT_MC(kc) LT(_MOUSECURSOR, kc) // L-ayer T-ap M-ouse C-ursor
+#define ALT_TAB M(KC_ALT_TAB) // Macro for Alt-Tab
+#define CMD_TAB M(KC_CMD_TAB) // Macro for Cmd-Tab
+#define CTL_TAB M(KC_CTL_TAB) // Macro for Ctl-Tab
+#define CMD_SLSH M(KC_CMD_SLSH) // Macro for Cmd-Slash (personal shortcut to toggle iTerm2 visibility)
+#define AG_FIND M(KC_AG_FIND) // Macros for Cmd-[x] vs Ctrl-[x] based on current AG_NORM or AG_SWAP settings
+#define AG_AGAIN M(KC_AG_AGAIN)
+#define AG_UNDO M(KC_AG_UNDO)
+#define AG_CUT M(KC_AG_CUT)
+#define AG_COPY M(KC_AG_COPY)
+#define AG_PASTE M(KC_AG_PASTE)
+#define AG_D_L M(KC_AG_DESK_L) // For Virtual Desktop Switching: Left, and
+#define AG_D_R M(KC_AG_DESK_R) // Right
+#define AG_T_C M(KC_AG_TAB_C) // For Chrome, etc. Tab Close,
+#define AG_T_N M(KC_AG_TAB_N) // Tab New, and
+#define AG_T_R M(KC_AG_TAB_R) // Tab Reopen Closed
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+/* Qwerty
+ *
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * |Hyper/Tab| Q | W | E | R | T | Y | U | I | O | P | Bksp |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | Ctrl/Esc | A | S | MC/D | F | G | H | J | K | L |GUI/; | Alt/" |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | Shift | Z | X | C | V | B | N | M | , | . | / | Sft/Ent |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | Alt | GUI | Lower | TC/Space | TC/Space | Raise | Vol+ | Play |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+[_QWERTY] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ HPR_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ CTL_ESC , KC_A, KC_S,LT_MC(KC_D), KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, GUI_SEM, ALT_QUO ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ KC_LSFT , KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, SFT_ENT ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ KC_LALT , KC_LGUI , LOWER , LT_TC , LT_TC , RAISE , KC_VOLU , KC_MPLY ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* Colemak
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * |Hyper/Tab| Q | W | F | P | G | J | L | U | Y | ; | Bksp |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | Ctrl/Esc | A | R | MC/S | T | D | H | N | E | I | O | " |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | Shift | Z | X | C | V | B | K | M | , | . | / | Sft/Ent |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | Alt | GUI | Lower | TC/Space | TC/Space | Raise | Vol+ | Play |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+[_COLEMAK] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ HPR_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ CTL_ESC , KC_A, KC_R,LT_MC(KC_S), KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ KC_LSFT , KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, SFT_ENT ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ KC_LALT , KC_LGUI , LOWER , LT_TC , LT_TC , RAISE , KC_VOLU , KC_MPLY ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* Dvorak
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * |Hyper/Tab| " | , | . | P | Y | F | G | C | R | L | Bksp |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | Ctrl/Esc | A | O | MC/E | U | I | D | H | T | N | S | / |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | Shift | ; | Q | J | K | X | B | M | W | V | Z | Sft/Ent |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | Alt | GUI | Lower | TC/Space | TC/Space | Raise | Vol+ | Play |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+[_DVORAK] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ HPR_TAB,KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_BSPC ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ CTL_ESC , KC_A, KC_O,LT_MC(KC_E), KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ KC_LSFT , KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, SFT_ENT ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ KC_LALT , KC_LGUI , LOWER , LT_TC , LT_TC , RAISE , KC_VOLU , KC_MPLY ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* Lower
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | [ | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | "|" |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | ] | F7 | F8 | F9 | F10 | F11 | F12 | - | = | [ | ] | \ |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | Brite | | | | | | Vol- | Mute |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+[_LOWER] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ KC_TILD,KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ KC_LBRC , KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ KC_RBRC , KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ BACKLIT , _______ , _______ , _______ , _______ , _______ , KC_VOLD , KC_MUTE ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* Raise
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | $ | 4 | 5 | 6 | . | + | . | 4 | 5 | 6 | * | "|" |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | = | 7 | 8 | 9 | 0 | - | . | 1 | 2 | 3 | / | \ |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | Brite | | | | | | Vol- | Mute |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+[_RAISE] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ KC_0 , KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ KC_DLR , KC_4, KC_5, KC_6, KC_DOT, KC_PLUS, KC_DOT, KC_4, KC_5, KC_6, KC_ASTR, KC_PIPE ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ KC_EQL , KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_DOT, KC_1, KC_2, KC_3, KC_SLSH, KC_BSLS ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ BACKLIT , _______ , _______ , _______ , _______ , _______ , KC_VOLD , KC_MUTE ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* TouchCursor layer (http://martin-stone.github.io/touchcursor/) plus personal customizations
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * | AltTab |CmdTab|CtlTab| GUI |Shift | ~ |Insert| Home | Up | End | Bksp | |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | | Alt |Space |Tab_C | Find |Again | PgUp | Left | Down |Right |Desk_L| Desk_R |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | | Undo | Cut | Copy |Paste | ` | PgDn | Del |Tab_N |Tab_R |iTerm2| |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | | | | | | | | |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ *
+ * The KC_UNDO, KC_CUT, KC_COPY, KC_PASTE, KC_FIND, and KC_AGAIN keycodes don't
+ * seem to work on Mac. Presumably they'll work under Windows.
+ */
+
+[_TOUCHCURSOR] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ ALT_TAB,CMD_TAB, CTL_TAB, KC_LGUI, KC_LSFT, KC_TILD, KC_INS, KC_HOME, KC_UP, KC_END, KC_BSPC, _______ ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ _______ ,KC_LALT, KC_SPC, AG_T_C, AG_FIND,AG_AGAIN, KC_PGUP, KC_LEFT, KC_DOWN, KC_RGHT, AG_D_L, AG_D_R ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ _______ ,AG_UNDO, AG_CUT, AG_COPY,AG_PASTE, KC_GRV, KC_PGDN, KC_DEL, AG_T_N, AG_T_R,CMD_SLSH, _______ ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ _______ , _______ , _______ , _______ , _______ , _______ , _______ , _______ ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* Mouse Layer
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * | | |ACCL0 | | | | |WHL_L | Up |WHL_R | BTN2 | |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | |ACCL2 | BTN2 | | BTN1 |ACCL1 |WHL_Up| Left | Down |Right | BTN4 | BTN5 |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | | | | | BTN3 | |WHL_Dn| BTN1 | | | BTN3 | |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | | | | | | | | |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+
+[_MOUSECURSOR] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ _______,_______, KC_ACL0, _______, _______, _______, _______, KC_WH_L, KC_MS_U, KC_WH_R, KC_BTN2, _______ ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ _______ ,KC_ACL2, KC_BTN2, _______, KC_BTN1, KC_ACL1, KC_WH_U, KC_MS_L, KC_MS_D, KC_MS_R, KC_BTN4, KC_BTN5 ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ _______ ,_______, _______, _______, KC_BTN3, _______, KC_WH_D, KC_BTN1, _______, _______, KC_BTN3, _______ ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ _______ , _______ , _______ , _______ , _______ , _______ , _______ , _______ ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* Plover layer (http://opensteno.org)
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * | # | # | # | # | # | # | # | # | # | # | # | # |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | | S | T | P | H | * | * | F | P | L | T | D |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | TogOut | S | K | W | R | * | * | R | B | G | S | Z |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | Exit | A | O | | | E | U | |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+
+[_PLOVER] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ KC_1 , KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1 ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ XXXXXXX , KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ XXXXXXX , KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ EXT_PLV , KC_C , KC_V , XXXXXXX , XXXXXXX , KC_N , KC_M , XXXXXXX ),
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+
+/* Adjust (Lower + Raise)
+ * ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ * | | | | | | | | | | | | Del |
+ * |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ * | | | | | |AGnorm|AGswap|Qwerty|Colemk|Dvorak|Plover| |
+ * |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ * | | | | | | | | | | | | |
+ * |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ * | | | | | | | | Reset |
+ * `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+ */
+[_ADJUST] = KEYMAP_TV44(
+/*,--------+-------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------.*/
+ _______,_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL ,
+/*|--------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`-----------------|*/
+ _______ ,_______, _______, _______, _______, AG_NORM, AG_SWAP, QWERTY, COLEMAK, DVORAK, PLOVER, _______ ,
+/*|---------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`----------------|*/
+ _______ ,_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ ,
+/*|----------`-------`--------`--------`--------`--------`--------`--------`--------`--------`--------`---------------|*/
+ _______ , _______ , _______ , _______ , _______ , _______ , _______ , RESET )
+/*`-----------+---------------+---------+-------^^^------+-------^^^-------+---------+-----------------+--------------'*/
+};
+
+void persistant_default_layer_set(uint16_t default_layer) {
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
+}
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ case QWERTY:
+ if (record->event.pressed) {
+ default_layer_set(1UL<<_QWERTY);
+ }
+ return false;
+ break;
+ case COLEMAK:
+ if (record->event.pressed) {
+ default_layer_set(1UL<<_COLEMAK);
+ }
+ return false;
+ break;
+ case DVORAK:
+ if (record->event.pressed) {
+ default_layer_set(1UL<<_DVORAK);
+ }
+ return false;
+ break;
+ case LOWER:
+ if (record->event.pressed) {
+ layer_on(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_LOWER);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case RAISE:
+ if (record->event.pressed) {
+ layer_on(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ } else {
+ layer_off(_RAISE);
+ update_tri_layer(_LOWER, _RAISE, _ADJUST);
+ }
+ return false;
+ break;
+ case BACKLIT:
+ if (record->event.pressed) {
+ register_code(KC_RSFT);
+ #ifdef BACKLIGHT_ENABLE
+ backlight_step();
+ #endif
+ } else {
+ unregister_code(KC_RSFT);
+ }
+ return false;
+ break;
+ case PLOVER:
+ if (record->event.pressed) {
+ layer_off(_RAISE);
+ layer_off(_LOWER);
+ layer_off(_ADJUST);
+ layer_on(_PLOVER);
+ if (!eeconfig_is_enabled()) {
+ eeconfig_init();
+ }
+ keymap_config.raw = eeconfig_read_keymap();
+ keymap_config.nkro = 1;
+ eeconfig_update_keymap(keymap_config.raw);
+ }
+ return false;
+ break;
+ case EXT_PLV:
+ if (record->event.pressed) {
+ layer_off(_PLOVER);
+ }
+ return false;
+ break;
+ }
+ return true;
+}
+
+/*
+ * Macro definition
+ */
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
+{
+ if (!eeconfig_is_enabled()) {
+ eeconfig_init();
+ }
+
+ bool use_cmd = true; // Use, for example, Cmd-Tab, Cmd-C, Cmd-V, etc.
+ // Compare to MAGIC_SWAP_ALT_GUI and MAGIC_UNSWAP_ALT_GUI configs, set in:
+ // quantum/quantum.c
+ if(keymap_config.swap_lalt_lgui == 1 && keymap_config.swap_ralt_rgui == 1) {
+ use_cmd = false; // ... or, Alt-Tab, Ctrl-C, Ctrl-V, etc.
+ }
+
+ switch (id) {
+ case KC_ALT_TAB:
+ if(use_cmd) { return (record->event.pressed ? MACRO( D(LALT), D(TAB), END ) : MACRO( U(TAB), END )); }
+ else { return (record->event.pressed ? MACRO( D(LGUI), D(TAB), END ) : MACRO( U(TAB), END )); }
+ case KC_CMD_TAB:
+ if(use_cmd) { return (record->event.pressed ? MACRO( D(LGUI), D(TAB), END ) : MACRO( U(TAB), END )); }
+ else { return (record->event.pressed ? MACRO( D(LALT), D(TAB), END ) : MACRO( U(TAB), END )); }
+
+ case KC_CTL_TAB:
+ return (record->event.pressed ? MACRO( D(LCTRL), D(TAB), END ) : MACRO( U(TAB), END ));
+ case KC_CMD_SLSH:
+ return (record->event.pressed ? MACRO( D(LGUI), D(SLSH),END ) : MACRO( U(SLSH),END ));
+
+ case KC_AG_FIND:
+ return use_cmd ? MACRODOWN( D(LGUI), T(F), END ) : MACRODOWN( D(LCTRL), T(F), END );
+ case KC_AG_AGAIN:
+ return use_cmd ? MACRODOWN( D(LGUI), T(G), END ) : MACRODOWN( D(LCTRL), T(G), END );
+ case KC_AG_UNDO:
+ return use_cmd ? MACRODOWN( D(LGUI), T(Z), END ) : MACRODOWN( D(LCTRL), T(Z), END );
+ case KC_AG_CUT:
+ return use_cmd ? MACRODOWN( D(LGUI), T(X), END ) : MACRODOWN( D(LCTRL), T(X), END );
+ case KC_AG_COPY:
+ return use_cmd ? MACRODOWN( D(LGUI), T(C), END ) : MACRODOWN( D(LCTRL), T(C), END );
+ case KC_AG_PASTE:
+ return use_cmd ? MACRODOWN( D(LGUI), T(V), END ) : MACRODOWN( D(LCTRL), T(V), END );
+
+ case KC_AG_DESK_L:
+ return use_cmd ? MACRODOWN( D(LGUI), D(LCTRL), T(SCLN), END ) : MACRODOWN( D(LALT), D(LCTRL), T(SCLN), END );
+ case KC_AG_DESK_R:
+ return use_cmd ? MACRODOWN( D(LGUI), D(LCTRL), T(QUOT), END ) : MACRODOWN( D(LALT), D(LCTRL), T(QUOT), END );
+
+ case KC_AG_TAB_C:
+ return use_cmd ? MACRODOWN( D(LGUI), T(W), END ) : MACRODOWN( D(LCTRL), T(W), END );
+ case KC_AG_TAB_N:
+ return use_cmd ? MACRODOWN( D(LGUI), T(T), END ) : MACRODOWN( D(LCTRL), T(T), END );
+ case KC_AG_TAB_R:
+ return use_cmd ? MACRODOWN( D(LGUI), D(LSHIFT), T(T), END ) : MACRODOWN( D(LCTRL), D(LSHIFT), T(T), END );
+ }
+
+ return MACRO_NONE;
+}
diff --git a/keyboards/tv44/keymaps/jeebak/readme.md b/keyboards/tv44/keymaps/jeebak/readme.md
new file mode 100644
index 0000000000..43d20958a6
--- /dev/null
+++ b/keyboards/tv44/keymaps/jeebak/readme.md
@@ -0,0 +1,129 @@
+jeebak's TV44 layout
+=======================
+NOTE: This is a port of jeebak's planck layout, for tv44.
+
+This WIP keymap attempts to minimize fingers straying away from the home row.
+To aid in this endeavor, when additional modifyer keys to switch layers are
+needed, they will be mapped to home row keys. The `keymap.c` file will contain
+the exact changes. The diagrams in this README shows the highlights of the
+changes from the default mappings.
+
+I also decided to change all calls to `persistant_default_layer_set()` to
+`default_layer_set()` since this is my personal perference.
+
+## Macros
+```
+#define ALT_TAB M(KC_ALT_TAB)
+```
+
+## Base Layers (Qwerty/Colemak/Dvorak)
+These base layers are mostly the same as the default mappings. The interesting
+changes are shown below.
+
+- The `Ctrl/Esc`, will emit an `Escape` when tapped, and act as a `Control` key when held,
+- `GUI/;` as `;` and `GUI`,
+- `Alt/"` as `"` and `Alt`,
+- `Sft/Ent` as `Enter` and `Shift`, and
+- `Hyper/Tab` as `Tab` and `Hyper`
+
+A `TODO` item is to see if it can also act as a `CapsLock` when double-tapped.
+The arrow keys, which have been moved to the
+[TouchCursor](http://martin-stone.github.io/touchcursor/) layer, have been
+replaced with the Media keys as shown. The `MC/kc` key activates the
+`MouseCursor` layer when held, and emits the corresponding `kc` for its layer,
+when tapped.
+```
+ ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ |Hyper/Tab| Q | W | E | R | T | Y | U | I | O | P | Bksp |
+ |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ | Ctrl/Esc | A | S | MC/D | F | G | H | J | K | L |GUI/; | Alt/" |
+ |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ | Shift | Z | X | C | V | B | N | M | , | . | / | Sft/Ent |
+ |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ | Alt | GUI | Lower | TC/Space | TC/Space | Raise | Vol+ | Play |
+ `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+```
+
+## Lower Layer (Symbols and Function Keys)
+The symbols and functions keys are essentially the same as the default mapping.
+The most notable changes are that the symbol keys from the `RAISE` layer have
+been moved here. The remaining Media keys replace those that are now on the
+base layers. The `BACKLIT` key has also been moved here.
+```
+ ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
+ |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ | [ | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | "|" |
+ |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ | ] | F7 | F8 | F9 | F10 | F11 | F12 | - | = | [ | ] | \ |
+ |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ | Brite | | | | | | Vol- | Mute |
+ `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+```
+
+## Raise Layer (Numbers and Arithmetic Operators)
+All of the numbers and arithmetic operators are available on this layer. Some
+keys are duplicated for the convenience of their positions. The `0` and `$`
+keys at the far left are for quick access to beginning and end of line in vim.
+```
+ ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
+ |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ | $ | 4 | 5 | 6 | . | + | . | 4 | 5 | 6 | * | "|" |
+ |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ | = | 7 | 8 | 9 | 0 | - | . | 1 | 2 | 3 | / | \ |
+ |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ | Brite | | | | | | Vol- | Mute |
+ `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+```
+
+## TouchCursor layer plus personal customizations
+[TouchCursor](http://martin-stone.github.io/touchcursor/) uses the `Space` key
+as the modifier, with the `IJKL` home row keys representing the inverted-T of
+the arrow keys. All of the default TouchCursor keymappings for the right hand
+are represented below. My personalizations include all of the keys shown for
+the left hand. Having the `Alt` and `Shift` keys (as well as the `Control` key
+from the base layers) readily accessible from the home row allows quick word
+jumps and highlighting when used in conjunction with the arrow keys. The
+`Alt-Tab` macro is not only useful under Windows, but also under Mac when used
+with alternative switchers like [HyperSwitch](https://bahoom.com/hyperswitch).
+The `Cmd-Tab` and `Ctrl-Tab` sequences are duplicated for easy access while in
+this layer. The `KC_UNDO, KC_CUT, KC_COPY, KC_PASTE, KC_FIND,` and `KC_AGAIN`
+keycodes do not seem to work. There are macros in place that'll "automatically"
+choose the correct version (`Cmd-Tab` vs. `Alt-Tab`, `Cmd-C` vs. `Ctrl-C`,
+etc.) depending on which layout you've currently selected (`AG_NORM` or
+`AG_SWAP`) in the `_ADJUST` layer. The `Desk_L` and `Desk_R` macros are what I
+use to switch between Virtual Desktops Left/Right. The `Tab_C`, `Tab_N` and
+`Tab_R` are for "Close Tab," "New Tab" and "Reopen Closed Tab" for apps such as
+Google Chrome.
+```
+ ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ | AltTab |CmdTab|CtlTab| GUI |Shift | ~ |Insert| Home | Up | End | Bksp | |
+ |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ | | Alt |Space |Tab_C | Find |Again | PgUp | Left | Down |Right |Desk_L| Desk_R |
+ |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ | | Undo | Cut | Copy |Paste | ` | PgDn | Del |Tab_N |Tab_R |iTerm2| |
+ |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ | | | | | | | | |
+ `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+```
+
+## Mouse Layer
+The Mouse layer, closely mimics the layout/behaviour of the TouchCursor layer.
+The `D` key (on QWERTY) is used to activate this layer. All 16 keycodes for the
+mouse from the `doc/keycode.txt` file are represented, and logically located,
+IMHO. The left and right click buttons are duplicated; on the right hand side,
+for a quick click here and there, and again on the left hand side for when the
+buttons need to be held for dragging things or highlighting text, thus allowing
+the right hand to be free to use the up/down/left/right actions.
+```
+ ,---------+------+------+------+------+------+------+------+------+------+------+-------------.
+ | | |ACCL0 | | | | |WHL_L | Up |WHL_R | BTN2 | |
+ |---------`------`------`------`------`------`------`------`------`------`------`-------------|
+ | |ACCL2 | BTN2 | | BTN1 |ACCL1 |WHL_Up| Left | Down |Right | BTN4 | BTN5 |
+ |----------`------`------`------`------`------`------`------`------`------`------`------------|
+ | | | | | BTN3 | |WHL_Dn| BTN1 | | | BTN3 | |
+ |-----------`------`------`------`------`-----'-------`------`------`------`------`-----------|
+ | | | | | | | | |
+ `--------+---------+---------+------^^^-------+-----^^^--------+---------+---------+---------'
+```
diff --git a/keyboards/tv44/readme.md b/keyboards/tv44/readme.md
index e3b557fe2d..4f691a4ca0 100644
--- a/keyboards/tv44/readme.md
+++ b/keyboards/tv44/readme.md
@@ -13,16 +13,16 @@ Depending on which keymap you would like to use, you will have to compile slight
### Default
-To build with the default keymap, simply run `make`.
+To build with the default keymap, simply run `make default`.
### Other Keymaps
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create a folder with the name of your keymap in the keymaps folder, and see keymap documentation (you can find in top readme.md) and existant keymap files.
-To build the firmware binary hex file with a keymap just do `make` with `keymap` option like:
+To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
```
-$ make keymap=[default|jack|<name>]
+$ make [default|jack|<name>]
```
Keymaps follow the format **__keymap.c__** and are stored in folders in the `keymaps` folder, eg `keymaps/my_keymap/` \ No newline at end of file
diff --git a/keyboards/tv44/rules.mk b/keyboards/tv44/rules.mk
new file mode 100644
index 0000000000..dbba6bace6
--- /dev/null
+++ b/keyboards/tv44/rules.mk
@@ -0,0 +1,69 @@
+
+
+# MCU name
+#MCU = at90usb1287
+MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=4096
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= yes # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6
diff --git a/keyboards/vision_division/Makefile b/keyboards/vision_division/Makefile
index 4f3130c483..4e2a6f00fd 100644
--- a/keyboards/vision_division/Makefile
+++ b/keyboards/vision_division/Makefile
@@ -1,76 +1,3 @@
-
-
-# MCU name
-MCU = at90usb1286
-# MCU = at90usb1287
-# MCU = atmega32u4
-
-# Processor frequency.
-# This will define a symbol, F_CPU, in all source code files equal to the
-# processor frequency in Hz. You can then use this symbol in your source code to
-# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
-# automatically to create a 32-bit value in your source code.
-#
-# This will be an integer division of F_USB below, as it is sourced by
-# F_USB after it has run through any CPU prescalers. Note that this value
-# does not *change* the processor frequency - it should merely be updated to
-# reflect the processor speed set externally so that the code can use accurate
-# software delays.
-F_CPU = 16000000
-
-
-#
-# LUFA specific
-#
-# Target architecture (see library "Board Types" documentation).
-ARCH = AVR8
-
-# Input clock frequency.
-# This will define a symbol, F_USB, in all source code files equal to the
-# input clock frequency (before any prescaling is performed) in Hz. This value may
-# differ from F_CPU if prescaling is used on the latter, and is required as the
-# raw input clock is fed directly to the PLL sections of the AVR for high speed
-# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
-# at the end, this will be done automatically to create a 32-bit value in your
-# source code.
-#
-# If no clock division is performed on the input clock inside the AVR (via the
-# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
-F_USB = $(F_CPU)
-
-# Interrupt driven control endpoint task(+60)
-OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
-
-
-# Boot Section Size in *bytes*
-# Teensy halfKay 512
-# Teensy++ halfKay 1024
-# Atmel DFU loader 4096
-# LUFA bootloader 4096
-# USBaspLoader 2048
-OPT_DEFS += -DBOOTLOADER_SIZE=1024
-
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
-CONSOLE_ENABLE ?= yes # Console for debug(+400)
-COMMAND_ENABLE ?= yes # Commands for debug and configuration
-# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
-# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE ?= yes # USB Nkey Rollover
-BACKLIGHT_ENABLE ?= no # Enable keyboard backlight functionality on B7 by default
-MIDI_ENABLE ?= no # MIDI controls
-UNICODE_ENABLE ?= no # Unicode
-BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
-AUDIO_ENABLE ?= no # Audio output on port C6
-
-ifndef QUANTUM_DIR
+ifndef MAKEFILE_INCLUDED
include ../../Makefile
-endif
-
-
+endif \ No newline at end of file
diff --git a/keyboards/vision_division/config.h b/keyboards/vision_division/config.h
index f50378ffa8..1f8466a546 100644
--- a/keyboards/vision_division/config.h
+++ b/keyboards/vision_division/config.h
@@ -26,10 +26,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* COL2ROW or ROW2COL */
#define DIODE_DIRECTION ROW2COL
-// #define BACKLIGHT_PIN B7
-// #define BACKLIGHT_BREATHING
-// #define BACKLIGHT_LEVELS 3
-
+#define BACKLIGHT_PIN B7
+#define BACKLIGHT_BREATHING
+#define BACKLIGHT_LEVELS 3
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
#define DEBOUNCING_DELAY 5
@@ -124,10 +123,18 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/* disable debug print */
-//#define NO_DEBUG
+// #ifndef NO_DEBUG
+// # define NO_DEBUG
+// #endif
/* disable print */
-//#define NO_PRINT
+// #ifndef NO_PRINT
+// # define NO_PRINT
+// #endif
+
+/* Only print user print statements */
+// #define USER_PRINT
+
/* disable action features */
//#define NO_ACTION_LAYER
diff --git a/keyboards/vision_division/keymaps/default/Makefile b/keyboards/vision_division/keymaps/default/Makefile
index ecbe7e1ab2..5a930e85ed 100644
--- a/keyboards/vision_division/keymaps/default/Makefile
+++ b/keyboards/vision_division/keymaps/default/Makefile
@@ -2,19 +2,19 @@
# change to "no" to disable the options, or define them in the Makefile in
# the appropriate keymap folder that will get included automatically
#
-BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
-MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
-EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
-CONSOLE_ENABLE = yes # Console for debug(+400)
-COMMAND_ENABLE = yes # Commands for debug and configuration
-NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
-MIDI_ENABLE = no # MIDI controls
-AUDIO_ENABLE = yes # Audio output on port C6
-UNICODE_ENABLE = no # Unicode
-BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
-RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
-SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
+CONSOLE_ENABLE = yes # Console for debug(+400)
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+MIDI_ENABLE = no # MIDI controls
+AUDIO_ENABLE = yes # Audio output on port C6
+UNICODE_ENABLE = no # Unicode
+BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
+RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
ifndef QUANTUM_DIR
include ../../../../Makefile
diff --git a/keyboards/vision_division/keymaps/default/config.h b/keyboards/vision_division/keymaps/default/config.h
index 16740fb15b..efd43f41b4 100644
--- a/keyboards/vision_division/keymaps/default/config.h
+++ b/keyboards/vision_division/keymaps/default/config.h
@@ -4,25 +4,44 @@
#include "../../config.h"
#include "matrix_types.h"
-
/* USB Device descriptor parameter */
#define VENDOR_ID 0xFEED
-#define PRODUCT_ID GET_PID(NUMERIC_NORMAL, HOMING_MAX_TEENSY)
#define DEVICE_VER 0x0001
#define MANUFACTURER IBNobody
#define PRODUCT Vision Division
#define DESCRIPTION Full / Split Keyboard
-
-#define MATRIX_ROWS 6
+#define MATRIX_ROWS 6
#define MATRIX_ROW_PINS { C2, C3, F4, F5, F6, F7 }
-#define MATRIX_COLS GET_MATRIX_COLS(NUMERIC_NORMAL, HOMING_MAX_TEENSY)
-#define MATRIX_COL_PINS GET_MATRIX_COL_PINS(NUMERIC_NORMAL, HOMING_MAX_TEENSY)
+// !!! MAKE SURE THAT THE LEFT/RIGHT PCB DEFINES MATCH ON ALL OF THESE COLUMNS
-#define UNUSED_PINS
+// **LEFT** **RIGHT**
+#define PRODUCT_ID GET_PID( NUMERIC_NORMAL, NUMERIC_MAX_TEENSY)
+#define MATRIX_COLS GET_MATRIX_COLS( NUMERIC_NORMAL, NUMERIC_MAX_TEENSY)
+#define MATRIX_COL_PINS GET_MATRIX_COL_PINS( NUMERIC_NORMAL, NUMERIC_MAX_TEENSY)
-/*#define KEYMAP( \
+#define KEYMAP(MATRIX_LAYER, \
+ k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C, \
+ k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C, \
+ k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C, \
+ k401, k402, k403, k404, k405, k406, k407, k408, k409, k40A, k411, k412, k413, k414, k415, k416, k417, k418, k419, k41A, k41B, k41C, \
+ k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C, \
+ k601, k602, k603, k604, k605, k606, k607, k608, k609, k60A, k611, k612, k613, k614, k615, k616, k617, k618, k619, k61A, k61B, k61C \
+) \
+KEYMAP_MASTER(MATRIX_LAYER, NUMERIC_NORMAL, NUMERIC_MAX_TEENSY, \
+ k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, KC_NO, KC_NO, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C, \
+ k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, KC_NO, KC_NO, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C, \
+ k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, KC_NO, KC_NO, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C, \
+ k401, k402, k403, k404, k405, k406, k407, k408, k409, k40A, KC_NO, KC_NO, k411, k412, k413, k414, k415, k416, k417, k418, k419, k41A, k41B, k41C, \
+ k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, KC_NO, KC_NO, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C, \
+ k601, k602, k603, k604, k605, k606, k607, k608, k609, k60A, KC_NO, KC_NO, k611, k612, k613, k614, k615, k616, k617, k618, k619, k61A, k61B, k61C \
+)
+
+// Example Keymap Macros
+
+/*
+#define KEYMAP(MATRIX_LAYER, \
k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k10B, k10C, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C, \
k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k20B, k20C, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C, \
k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k30B, k30C, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C, \
@@ -30,16 +49,18 @@
k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k50B, k50C, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C, \
k601, k602, k603, k604, k605, k606, k607, k608, k609, k60A, k60B, k60C, k611, k612, k613, k614, k615, k616, k617, k618, k619, k61A, k61B, k61C \
) \
-KEYMAP_MASTER(NUMERIC_MAX_TEENSY, NUMERIC_MAX, \
+KEYMAP_MASTER(MATRIX_LAYER, NUMERIC_MAX_TEENSY, NUMERIC_MAX, \
k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k10B, k10C, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C, \
k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k20B, k20C, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C, \
k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k30B, k30C, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C, \
k401, k402, k403, k404, k405, k406, k407, k408, k409, k40A, k40B, k40C, k411, k412, k413, k414, k415, k416, k417, k418, k419, k41A, k41B, k41C, \
k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k50B, k50C, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C, \
k601, k602, k603, k604, k605, k606, k607, k608, k609, k60A, k60B, k60C, k611, k612, k613, k614, k615, k616, k617, k618, k619, k61A, k61B, k61C \
-)*/
+)
+*/
-#define KEYMAP( \
+/*
+#define KEYMAP(MATRIX_LAYER, \
k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, \
k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, \
k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, \
@@ -47,7 +68,7 @@ KEYMAP_MASTER(NUMERIC_MAX_TEENSY, NUMERIC_MAX, \
k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, \
k601, k602, k603, k604, k605, k606, k607, k608, k609, k60A, k611, k612, k613, k614, k615, k616, k617, k618, k619, k61A, k61B \
) \
-KEYMAP_MASTER(NUMERIC_NORMAL, HOMING_MAX_TEENSY, \
+KEYMAP_MASTER(MATRIX_LAYER, NUMERIC_NORMAL, HOMING_MAX_TEENSY, \
k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, KC_NO, KC_NO, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, KC_NO, \
k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, KC_NO, KC_NO, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, KC_NO, \
k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, KC_NO, KC_NO, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, KC_NO, \
@@ -55,5 +76,6 @@ KEYMAP_MASTER(NUMERIC_NORMAL, HOMING_MAX_TEENSY, \
k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, KC_NO, KC_NO, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, KC_NO, \
k601, k602, k603, k604, k605, k606, k607, k608, k609, k60A, KC_NO, KC_NO, k611, k612, k613, k614, k615, k616, k617, k618, k619, k61A, k61B, KC_NO \
)
+*/
#endif \ No newline at end of file
diff --git a/keyboards/vision_division/keymaps/default/keymap.c b/keyboards/vision_division/keymaps/default/keymap.c
index b8cef9c759..64118abdce 100644
--- a/keyboards/vision_division/keymaps/default/keymap.c
+++ b/keyboards/vision_division/keymaps/default/keymap.c
@@ -8,46 +8,70 @@
#include "song_list.h"
#endif
-#define LAYER_QWERTY 0
-#define LAYER_COLEMAK 1
-#define LAYER_DVORAK 2
-#define LAYER_UPPER 3
-#define LAYER_LOWER 4
-#define LAYER_FUNCTION 5
-#define LAYER_MOUSE 6
-#define LAYER_ADJUST 7
-
-#define MACRO_QWERTY 0
-#define MACRO_COLEMAK 1
-#define MACRO_DVORAK 2
-#define MACRO_UPPER 3
-#define MACRO_LOWER 4
-#define MACRO_FUNCTION 5
-#define MACRO_MOUSE 6
-#define MACRO_TIMBRE_1 7
-#define MACRO_TIMBRE_2 8
-#define MACRO_TIMBRE_3 9
-#define MACRO_TIMBRE_4 10
-#define MACRO_TEMPO_U 11
-#define MACRO_TEMPO_D 12
-#define MACRO_TONE_DEFAULT 13
-#define MACRO_MUSIC_TOGGLE 14
-#define MACRO_AUDIO_TOGGLE 16
-#define MACRO_INC_VOICE 18
-#define MACRO_DEC_VOICE 19
-#define MACRO_BACKLIGHT 20
-#define MACRO_BREATH_TOGGLE 21
-#define MACRO_BREATH_SPEED_INC 23
-#define MACRO_BREATH_SPEED_DEC 24
-#define MACRO_BREATH_DEFAULT 25
+enum keyboard_layers {
+ LAYER_QWERTY = 0,
+ LAYER_UPPER,
+ LAYER_LOWER,
+ LAYER_FUNCTION,
+ LAYER_MOUSE,
+ LAYER_ADJUST,
+};
+enum keyboard_macros {
+ MACRO_QWERTY = 0,
+ MACRO_UPPER,
+ MACRO_LOWER,
+ MACRO_FUNCTION,
+ MACRO_MOUSE,
+ MACRO_TIMBRE_1,
+ MACRO_TIMBRE_2,
+ MACRO_TIMBRE_3,
+ MACRO_TIMBRE_4,
+ MACRO_TEMPO_U,
+ MACRO_TEMPO_D,
+ MACRO_TONE_DEFAULT,
+ MACRO_MUSIC_TOGGLE,
+ MACRO_AUDIO_TOGGLE,
+ MACRO_INC_VOICE,
+ MACRO_DEC_VOICE,
+ MACRO_BACKLIGHT,
+ MACRO_BREATH_TOGGLE,
+ MACRO_BREATH_SPEED_INC,
+ MACRO_BREATH_SPEED_DEC,
+ MACRO_BREATH_DEFAULT,
+ MACRO_MOUSE_MOVE_UL,
+ MACRO_MOUSE_MOVE_UR,
+ MACRO_MOUSE_MOVE_DL,
+ MACRO_MOUSE_MOVE_DR,
+ MACRO_HELP,
+ MACRO_HELP_1,
+ MACRO_HELP_2,
+ MACRO_HELP_3,
+ MACRO_HELP_4,
+ MACRO_HELP_5,
+ MACRO_HELP_6,
+ MACRO_HELP_7,
+ MACRO_HELP_8,
+ MACRO_HELP_9,
+ MACRO_HELP_0,
+ MACRO_GENERAL_1,
+ MACRO_GENERAL_2,
+ MACRO_GENERAL_3,
+ MACRO_GENERAL_4,
+ MACRO_GENERAL_5,
+ MACRO_CURSOR_UL,
+ MACRO_CURSOR_UR,
+ MACRO_CURSOR_DL,
+ MACRO_CURSOR_DR,
+ MACRO_MUTE_APP,
+ MACRO_COPY_CUT,
+};
#define M_QWRTY M(MACRO_QWERTY)
-#define M_COLMK M(MACRO_COLEMAK)
-#define M_DVORK M(MACRO_DVORAK)
#define M_UPPER M(MACRO_UPPER)
#define M_LOWER M(MACRO_LOWER)
#define M_FUNCT M(MACRO_FUNCTION)
#define M_MOUSE M(MACRO_MOUSE)
+
#define TIMBR_1 M(MACRO_TIMBRE_1)
#define TIMBR_2 M(MACRO_TIMBRE_2)
#define TIMBR_3 M(MACRO_TIMBRE_3)
@@ -55,15 +79,47 @@
#define TMPO_UP M(MACRO_TEMPO_U)
#define TMPO_DN M(MACRO_TEMPO_D)
#define TMPO_DF M(MACRO_TONE_DEFAULT)
+
+#define VC_UP M(MACRO_INC_VOICE)
+#define VC_DOWN M(MACRO_DEC_VOICE)
+
#define M_BACKL M(MACRO_BACKLIGHT)
#define M_BRTOG M(MACRO_BREATH_TOGGLE)
#define M_BSPDU M(MACRO_BREATH_SPEED_INC)
#define M_BSPDD M(MACRO_BREATH_SPEED_DEC)
#define M_BDFLT M(MACRO_BREATH_DEFAULT)
+#define M_MS_UL M(MACRO_MOUSE_MOVE_UL)
+#define M_MS_UR M(MACRO_MOUSE_MOVE_UR)
+#define M_MS_DL M(MACRO_MOUSE_MOVE_DL)
+#define M_MS_DR M(MACRO_MOUSE_MOVE_DR)
-#define VC_UP M(MACRO_INC_VOICE)
-#define VC_DOWN M(MACRO_DEC_VOICE)
+#define M_HELP M(MACRO_HELP)
+#define M_HELP1 M(MACRO_HELP_1)
+#define M_HELP2 M(MACRO_HELP_2)
+#define M_HELP3 M(MACRO_HELP_3)
+#define M_HELP4 M(MACRO_HELP_4)
+#define M_HELP5 M(MACRO_HELP_5)
+#define M_HELP6 M(MACRO_HELP_6)
+#define M_HELP7 M(MACRO_HELP_7)
+#define M_HELP8 M(MACRO_HELP_8)
+#define M_HELP9 M(MACRO_HELP_9)
+#define M_HELP0 M(MACRO_HELP_0)
+
+#define M_M1 M(MACRO_GENERAL_1)
+#define M_M2 M(MACRO_GENERAL_2)
+#define M_M3 M(MACRO_GENERAL_3)
+#define M_M4 M(MACRO_GENERAL_4)
+#define M_M5 M(MACRO_GENERAL_5)
+
+#define M_UL M(MACRO_CURSOR_UL)
+#define M_UR M(MACRO_CURSOR_UR)
+#define M_DL M(MACRO_CURSOR_DL)
+#define M_DR M(MACRO_CURSOR_DR)
+
+#define M_MUTEA M(MACRO_MUTE_APP)
+
+#define M_CP_CT M(MACRO_COPY_CUT)
#define SC_UNDO LCTL(KC_Z)
@@ -77,6 +133,7 @@
#define SC_ACLS LALT(KC_F4)
#define SC_CCLS LCTL(KC_F4)
+#define TG_NKRO MAGIC_TOGGLE_NKRO
#define OS_SHFT KC_FN0
#define _______ KC_TRNS
@@ -84,208 +141,128 @@
#define ________________ _______, _______
#define XXXXXXXXXXXXXXXX XXXXXXX, XXXXXXX
-const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
-
-
-KEYMAP( \
- KC_VOLD, KC_MUTE, KC_VOLU, XXXXXXX, KC_F1, KC_F2, KC_F3, KC_F4, XXXXXXX, KC_F5, KC_F6, KC_F7, KC_F8, XXXXXXX, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS, \
- KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, KC_ESC, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, \
- KC_KP_7, KC_KP_8, KC_KP_9, KC_PPLS, KC_TAB, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_MINS, KC_BSLS, KC_DEL, KC_END, KC_PGDN, \
- KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, KC_CAPS, KC_BSPC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, XXXXXXX, XXXXXXX, XXXXXXX, \
- KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, KC_LSFT, 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_RSFT, XXXXXXX, KC_UP, XXXXXXX, \
- KC_KP_0, KC_KP_0, KC_PDOT, KC_PENT, KC_LCTL, KC_LCTL, XXXXXXX, KC_LALT, KC_LGUI, XXXXXXX, KC_SPC, KC_SPC, XXXXXXX, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT \
-)
-
-
-// [LAYER_QWERTY] = { // QWERTY
-// { KC_ESC, 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_BSPC },
-// { 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_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, KC_ENT, KC_PGUP },
-// { 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_RSFT, KC_UP, KC_PGDN },
-// { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT },
-// },
-
-
-// /* Numeric Max / Homing Normal - Traditional
-// * .-----------------------------------. .-----------------------------------. .-----------------_-----------------. .-----------------------------------. .--------------------------.
-// * | | | | | | | | | | | | | | | | | | | | | | | |
-// * '-----------------------------------' '-----------------------------------' '-----------------------------------' '-----------------------------------' '--------------------------'
-// * .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .--------------------------.
-// * | | | | | | ESC | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | | | | | |
-// * |--------+--------+--------+--------| | -------+ -------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------+--------+--------|
-// * | | | | | | TAB | TAB | Q | W | E | R | T | Y | U | I | O | P | [ | | | | | |
-// * |--------+--------+--------+ | o | -------+ -------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| '--------+--------+--------'
-// * | | | | | o | CAPS | CAPS | A | S | D | F | G | H | J | K | L | ; | ' | |
-// * |--------+--------+--------+--------| o | -------+ -------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---+--------| .--------.
-// * | | | | | | LSHIFT | LSHIFT | Z | X | C | V | B | N | M | , | . | / | XXXXXX | | | |
-// * |--------+--------+--------+ | | -------+ -------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+--------+--------| .--------+--------+--------.
-// * | | | | | LCTRL | LCTRL | LWIN | FN | LALT | UPPER | XXXXXX . SPACE | LOWER | SHIFT | RALT | APP | RCTRL | | | | | |
-// * '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '--------------------------'
-// */
-
-
-// /* QWERTY
-// * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
-// * | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | XXXXXX . BACKSP |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
-// * | TAB | Q | W | E | R | T | Y | U | I | O | P | [ | ] | \ | DEL |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
-// * | CAPS | A | S | D | F | G | H | J | K | L | ; | ' | XXXXXX . ENTER | PG UP |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
-// * | LSHIFT | Z | X | C | V | B | N | M | , | . | / | XXXXXX . RSHIFT | UP | PG DN |
-// * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
-// * | LCTRL | LWIN | FN | LALT | UPPER | XXXXXX . SPACE | LOWER | SHIFT | RALT | APP | RCTRL | LEFT | DOWN | RIGHT |
-// * '--------------------------------------------------------------------------------------------------------------------------------------'
-// */
-
-// [LAYER_QWERTY] = { // QWERTY
-// { KC_ESC, 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_BSPC },
-// { 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_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, KC_ENT, KC_PGUP },
-// { 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_RSFT, KC_UP, KC_PGDN },
-// { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT },
-// },
-
-// /* COLEMAK
-// * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
-// * | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | XXXXXX . BACKSP |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
-// * | TAB | Q | W | F | P | G | J | L | U | Y | ; | [ | ] | \ | DEL |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
-// * | BACKSP | A | R | S | T | D | H | N | E | I | O | ' | XXXXXX . ENTER | PG UP |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
-// * | LSHIFT | Z | X | C | V | B | K | M | , | . | / | XXXXXX . RSHIFT | UP | PG DN |
-// * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
-// * | LCTRL | LWIN | FN | LALT | UPPER | XXXXXX . SPACE | LOWER | SHIFT | RALT | APP | RCTRL | LEFT | DOWN | RIGHT |
-// * '--------------------------------------------------------------------------------------------------------------------------------------'
-// */
-
-// [LAYER_COLEMAK] = { // COLEMAK
-// { KC_ESC, 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_BSPC },
-// { KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL },
-// { KC_BSPC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT, KC_ENT, KC_ENT, KC_PGUP },
-// { KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_RSFT, KC_UP, KC_PGDN },
-// { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT },
-// },
-
-// /* DVORAK
-// * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
-// * | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | [ | ] | XXXXXX . BACKSP |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
-// * | TAB | ' | , | . | P | Y | F | G | C | R | L | / | = | \ | DEL |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
-// * | CAPS | A | O | E | U | I | D | H | T | N | S | - | XXXXXX . ENTER | PG UP |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
-// * | LSHIFT | ; | Q | J | K | X | B | M | W | V | Z | XXXXXX . RSHIFT | UP | PG DN |
-// * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
-// * | LCTRL | LWIN | FN | LALT | UPPER | XXXXXX . SPACE | LOWER | SHIFT | RALT | APP | RCTRL | LEFT | DOWN | RIGHT |
-// * '--------------------------------------------------------------------------------------------------------------------------------------'
-// */
-
-// [LAYER_DVORAK] = { // DVORAK
-// { KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_LBRC, KC_RBRC, KC_BSPC, KC_BSPC },
-// { KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLSH, KC_EQL, KC_BSLS, KC_DEL },
-// { KC_CAPS, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_MINS, KC_ENT, KC_ENT, KC_PGUP },
-// { KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_RSFT, KC_RSFT, KC_UP, KC_PGDN },
-// { KC_LCTL, KC_LGUI, M_FUNCT, KC_LALT, M_UPPER, KC_SPC, KC_SPC, M_LOWER, OS_SHFT, KC_RALT, KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT },
-// },
-
-// /* UPPER
-// * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
-// * | PRINT | BR TOG | BR SP+ | BR SP- | BR RST | XXXXXX | XXXXXX | NUM LK | / | * | | NUM LK | SCR LK | XXXXXX . PAUSE |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
-// * | | F1 | F2 | F3 | F4 | | | 7 | 8 | 9 | - | | | | INS |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
-// * | CAP LK | F5 | F6 | F7 | F8 | | | 4 | 5 | 6 | + | | XXXXXX . | HOME |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
-// * | | F9 | F10 | F11 | F12 | | | 1 | 2 | 3 | ENTER | XXXXXX . | | END |
-// * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
-// * | | | | | | 0 | | RALT | . | ENTER | | | | |
-// * '--------------------------------------------------------------------------------------------------------------------------------------'
-// */
-
-// [LAYER_UPPER] = { // UPPER
-// { KC_PSCR, M_BRTOG, M_BSPDU, M_BSPDD, M_BDFLT, XXXXXXX, XXXXXXX, KC_NLCK, KC_PSLS, KC_PAST, XXXXXXX, XXXXXXX, KC_SLCK, KC_PAUS, KC_PAUS },
-// { _______, KC_F1, KC_F2, KC_F3, KC_F4, XXXXXXX, XXXXXXX, KC_KP_7, KC_KP_8, KC_KP_9, KC_PMNS, _______, _______, _______, KC_INS },
-// { KC_CAPS, KC_F5, KC_F6, KC_F7, KC_F8, XXXXXXX, XXXXXXX, KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, _______, ________________, KC_HOME },
-// { _______, KC_F9, KC_F10, KC_F11, KC_F12, XXXXXXX, XXXXXXX, KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, ________________, _______, KC_END },
-// { _______, _______, _______, _______, _______, KC_KP_0, KC_KP_0, _______, KC_RALT, KC_PDOT, KC_PENT, _______, _______, _______, _______ },
-// },
-
-// /* LOWER
-// * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
-// * | | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | XXXXXX . BACKSP |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
-// * | | $ | { | [ | ( | % | # | ) | ] | } | @ | | | | INS |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
-// * | | ^ | * | + | - | / | \ | _ | ' | " | ` | | XXXXXX . | HOME |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
-// * | | | | & | ! | ~ | ; | : | = | < | > | ? | XXXXXX . | | END |
-// * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
-// * | | | | | | | | | | | | | | |
-// * '--------------------------------------------------------------------------------------------------------------------------------------'
-// */
-
-// [LAYER_LOWER] = { // LOWER
-// { _______, 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_DLR, KC_LCBR, KC_LBRC, KC_LPRN, KC_PERC, KC_HASH, KC_RPRN, KC_RBRC, KC_RCBR, KC_AT, _______, _______, _______, KC_INS },
-// { _______, KC_CIRC, KC_ASTR, KC_PPLS, KC_PMNS, KC_SLSH, KC_BSLS, KC_UNDS, KC_QUOT, KC_DQT, KC_GRV, _______, ________________, KC_HOME },
-// { _______, KC_PIPE, KC_AMPR, KC_EXLM, KC_TILD, KC_SCLN, KC_COLN, KC_EQL, KC_LT, KC_GT, KC_QUES, ________________, _______, KC_END },
-// { _______, _______, _______, _______, _______, ________________, _______, _______, _______, _______, _______, _______, _______, _______ },
-// },
-
-// /* FUNCTION
-// * .---------------------------------------------------------------------------------------------------------------------- 2u ------------.
-// * | NUM LK | | | | | | | | | | | | | XXXXXX . |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
-// * | SCR LK | F13 | F14 | F15 | F16 | | | | | | | | | | |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ------------+--------|
-// * | CAP LK | F17 | F18 | F19 | F20 | | | | | | | | XXXXXX . | |
-// * |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+- 2u ---------------------+--------|
-// * | | F21 | F22 | F23 | F24 | | | | | | | XXXXXX . | VOL UP | MUTE |
-// * |--------+--------+--------+--------+--------+- 2u ------------+--------+--------+--------+--------+-----------------+--------+--------|
-// * | | | | | | PLAY/PAUSE | | | | | | PTRACK | VOL DN | NTRACK |
-// * '--------------------------------------------------------------------------------------------------------------------------------------'
-// */
-
-// [LAYER_FUNCTION] = { // FUNCTION
-// { KC_NLCK, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX },
-// { KC_SLCK, KC_F13, KC_F14, KC_F15, KC_F16, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
-// { KC_CAPS, KC_F17, KC_F18, KC_F19, KC_F20, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX, XXXXXXX },
-// { _______, KC_F21, KC_F22, KC_F23, KC_F24, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, ________________, KC_VOLU, KC_MUTE },
-// { _______, _______, _______, _______, _______, KC_MPLY, KC_MPLY, _______, _______, _______, _______, _______, KC_MPRV, KC_VOLD, KC_MNXT },
-// },
-
-// #ifdef MOUSEKEY_ENABLE
-
-// [LAYER_MOUSE] = { // MOUSE
-// { _______, KC_ACL0, KC_ACL1, KC_ACL2, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX },
-// { XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX },
-// { XXXXXXX, KC_BTN5, KC_BTN4, KC_BTN3, KC_BTN2, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXXXXXXXXXXX, KC_WH_U },
-// { _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, ________________, KC_MS_U, KC_WH_D },
-// { _______, _______, _______, _______, _______, KC_BTN1, KC_BTN1, _______, _______, _______, _______, _______, KC_MS_L, KC_MS_D, KC_MS_R },
-// },
-
-// #endif
-
-// [LAYER_ADJUST] = { // ADJUST
-// { _______, TIMBR_1, TIMBR_2, TIMBR_3, TIMBR_4, TMPO_UP, TMPO_DN, TMPO_DF, _______, _______, _______, MU_TOG, AU_TOG, ________________ },
-// { _______, M_QWRTY, M_COLMK, M_DVORK, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ },
-// { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________, _______ },
-// { _______, _______, _______, _______, M_BACKL, RESET, _______, M_MOUSE, _______, _______, _______, ________________, MUV_IN, _______ },
-// { _______, _______, _______, _______, _______, ________________, _______, _______, _______, _______, _______, _______, MUV_DE, _______ },
-// },
-
-
-// /*
-// [LAYER_EMPTY] = { // LAYER
-// { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________ },
-// { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ },
-// { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________, _______ },
-// { _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, ________________, _______, _______ },
-// { _______, _______, _______, _______, _______, ________________, _______, _______, _______, _______, _______, _______, _______, _______ },
-// },
-// */
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] =
+{
+/* LAYER = LAYER_QWERTY
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | FN | PRINT | SCR LK | PAUSE | | F1 | F2 | F3 | F4 | XXXXXX | F5 | F6 | F7 | F8 | XXXXXX | F9 | F10 | F11 | F12 | | VOL DN | MUTE | VOL UP | BACKLT |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | M1 | INS | HOME | PG UP | | ESC | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | = | BACKSP | | NUM LK | KP / | KP * | KP - |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | M2 | DEL | END | PG DN | | TAB | TAB | Q | W | E | R | T | Y | U | I | O | P | - | \ | | KP 7 | KP 8 | KP 9 | KP + |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | M3 | UL | UP | UR | | CAP LK | BACKSP | A | S | D | F | G | H | J | K | L | ; | ' | ENTER | o | KP 4 | KP 5 | KP 6 | KP + |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | M4 | LEFT | CP/CT | RIGHT | | LSHIFT | LSHIFT | Z | X | C | V | B | N | M | , | . | / | RSHIFT | RSHIFT | | KP 1 | KP 2 | KP 3 | KP Ent |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | M5 | DL | DOWN | DR | | LCTRL | XXXXXX | XXXXXX | LWIN | LALT | LOWER | SPACE . SPACE | UPPER | OSHIFT | RALT | APP | XXXXXX | RCTRL | | KP 0 | KP , | KP . | KP Ent |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+*/
+KEYMAP(LAYER_QWERTY, \
+ M_HELP , KC_PSCR, KC_SLCK, KC_PAUS, KC_F1 , KC_F2 , KC_F3 , KC_F4 , XXXXXXX, KC_F5 , KC_F6 , KC_F7 , KC_F8 , XXXXXXX, KC_F9 , KC_F10 , KC_F11 , KC_F12 , KC_VOLD, KC_MUTE, KC_VOLU, M_BACKL, \
+ M_M1 , KC_INS , KC_HOME, KC_PGUP, KC_ESC , KC_GRV , KC_1 , KC_2 , KC_3 , KC_4 , KC_5 , KC_6 , KC_7 , KC_8 , KC_9 , KC_0 , KC_EQL , KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
+ M_M2 , KC_DEL , KC_END , KC_PGDN, KC_TAB , KC_TAB , KC_Q , KC_W , KC_E , KC_R , KC_T , KC_Y , KC_U , KC_I , KC_O , KC_P , KC_MINS, KC_BSLS, KC_KP_7, KC_KP_8, KC_KP_9, KC_PPLS, \
+ M_M3 , M_UL , KC_UP , M_UR , KC_CAPS, KC_BSPC, KC_A , KC_S , KC_D , KC_F , KC_G , KC_H , KC_J , KC_K , KC_L , KC_SCLN, KC_QUOT, KC_ENT , KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, \
+ M_M4 , KC_LEFT, M_CP_CT, KC_RGHT, KC_LSFT, 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_RSFT, KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, \
+ M_M5 , M_DL , KC_DOWN, M_DR , KC_LCTL, XXXXXXX, XXXXXXX, KC_LGUI, KC_LALT, M_LOWER, KC_SPC , KC_SPC , M_UPPER, OS_SHFT, KC_RALT, KC_APP , XXXXXXX, KC_RCTL, KC_KP_0, KC_PCMM, KC_PDOT, KC_PENT \
+),
+/* LAYER = LAYER_LOWER
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | ______ | ______ | ______ | ______ | | F13 | F14 | F15 | F16 | XXXXXX | F17 | F18 | F19 | F20 | XXXXXX | F21 | F22 | F23 | F24 | | ______ | MUTE A | ______ | ______ |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | ______ | $ | { | [ | ( | % | # | ) | ] | } | @ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | ______ | ^ | * | + | - | / | \ | _ | ' | " | ` | ______ | ______ | o | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | ______ | | | & | ! | ~ | ; | : | = | < | > | ? | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | XXXXXX | XXXXXX | ______ | ______ | ______ | ______ . ______ | LOWER | ______ | ______ | ______ | XXXXXX | ______ | | ______ | ______ | ______ | ______ |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+*/
+KEYMAP(LAYER_LOWER, \
+ _______, _______, _______, _______, KC_F13 , KC_F14 , KC_F15 , KC_F16 , XXXXXXX, KC_F17 , KC_F18 , KC_F19 , KC_F20 , XXXXXXX, KC_F21 , KC_F22 , KC_F23 , KC_F24 , _______, M_MUTEA, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, KC_DLR , KC_LCBR, KC_LBRC, KC_LPRN, KC_PERC, KC_HASH, KC_RPRN, KC_RBRC, KC_RCBR, KC_AT , _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, KC_CIRC, KC_ASTR, KC_PLUS, KC_MINS, KC_SLSH, KC_BSLS, KC_UNDS, KC_QUOT, KC_DQT , KC_GRV , _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, KC_PIPE, KC_AMPR, KC_EXLM, KC_TILD, KC_SCLN, KC_COLN, KC_EQL , KC_LT , KC_GT , KC_QUES, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, XXXXXXX, XXXXXXX, _______, _______, _______, _______, _______, M_LOWER, _______, _______, _______, XXXXXXX, _______, _______, _______, _______, _______ \
+),
+/* LAYER = LAYER_UPPER
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | ______ | ______ | ______ | ______ | | F13 | F14 | F15 | F16 | XXXXXX | F17 | F18 | F19 | F20 | XXXXXX | F21 | F22 | F23 | F24 | | ______ | MUTE A | ______ | ______ |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | ______ | F1 | F2 | F3 | F4 | NUM LK | KP / | KP 7 | KP 8 | KP 9 | KP - | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | ______ | F5 | F6 | F7 | F8 | CAP LK | KP * | KP 4 | KP 5 | KP 6 | KP + | ______ | ______ | o | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | ______ | F9 | F10 | F11 | F12 | SCR LK | KP 0 | KP 1 | KP 2 | KP 3 | KP Ent | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | ______ | ______ | ______ | ______ | | ______ | XXXXXX | XXXXXX | ______ | ______ | UPPER | KP 0 . KP 0 | ______ | RALT | KP . | KP Ent | XXXXXX | ______ | | ______ | ______ | ______ | ______ |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+*/
+KEYMAP(LAYER_UPPER, \
+ _______, _______, _______, _______, KC_F13 , KC_F14 , KC_F15 , KC_F16 , XXXXXXX, KC_F17 , KC_F18 , KC_F19 , KC_F20 , XXXXXXX, KC_F21 , KC_F22 , KC_F23 , KC_F24 , _______, M_MUTEA, _______, _______, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, KC_F1 , KC_F2 , KC_F3 , KC_F4 , KC_NLCK, KC_PSLS, KC_KP_7, KC_KP_8, KC_KP_9, KC_PMNS, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, KC_F5 , KC_F6 , KC_F7 , KC_F8 , KC_CAPS, KC_PAST, KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, _______, KC_F9 , KC_F10 , KC_F11 , KC_F12 , KC_SLCK, KC_KP_0, KC_KP_1, KC_KP_2, KC_KP_3, KC_PENT, _______, _______, _______, _______, _______, _______, \
+ _______, _______, _______, _______, _______, XXXXXXX, XXXXXXX, _______, _______, M_UPPER, KC_KP_0, KC_KP_0, _______, KC_RALT, KC_PDOT, KC_PENT, XXXXXXX, _______, _______, _______, _______, _______ \
+),
+/* LAYER = LAYER_MOUSE
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | MS BT1 | MS AC0 | MS WHU | MS AC2 | | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | MS BT2 | MS WHL | MS WHD | MS WHU | | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | MS BT3 | MS UL | MS U | MS UR | | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | o | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | MS BT4 | MS L | MS BT1 | MS R | | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | MS BT5 | MS DL | MS D | MS DR | | ______ | ______ | ______ | ______ | ______ | ______ | ______ . ______ | ______ | ______ | ______ | ______ | ______ | ______ | | ______ | ______ | ______ | ______ |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+*/
+KEYMAP(LAYER_MOUSE, \
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ KC_BTN1, KC_ACL0, KC_WH_U, KC_ACL2, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ KC_BTN2, KC_WH_L, KC_WH_D, KC_WH_U, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ KC_BTN3, M_MS_UL, KC_MS_U, M_MS_UR, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ KC_BTN4, KC_MS_L, KC_BTN1, KC_MS_R, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
+ KC_BTN5, M_MS_DL, KC_MS_D, M_MS_DR, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
+),
+/* LAYER = LAYER_ADJUST
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | HELP 1 | HELP 2 | HELP 3 | HELP 4 | XXXXXX | HELP 5 | HELP 6 | HELP 7 | HELP 8 | XXXXXX | HELP 9 | HELP 0 | XXXXXX | XXXXXX | | VOICE- | AUDIO | VOICE+ | MUSIC |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+ .-----------------------------------. .-----------------------------------------------------------------------------------------------------------------------------. .-----------------------------------.
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | o | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| o |--------|--------|--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | RESET | XXXXXX | MOUSE | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ |--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |--------|--------|--------+--------|
+ | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | UPPER | XXXXXX . XXXXXX | LOWER | XXXXXX | XXXXXX | XXXXXX | XXXXXX | XXXXXX | | XXXXXX | XXXXXX | XXXXXX | XXXXXX |
+ '-----------------------------------' '-----------------------------------------------------------------------------------------------------------------------------' '-----------------------------------'
+*/
+KEYMAP(LAYER_ADJUST, \
+ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_HELP1, M_HELP2, M_HELP3, M_HELP4, XXXXXXX, M_HELP5, M_HELP6, M_HELP7, M_HELP8, XXXXXXX, M_HELP9, M_HELP0, XXXXXXX, XXXXXXX, MUV_DE , AU_TOG , MUV_IN , MU_TOG , \
+ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, \
+ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, \
+ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, \
+ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RESET , XXXXXXX, M_MOUSE, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, \
+ XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, M_UPPER, XXXXXXX, XXXXXXX, M_LOWER, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX \
+),
};
@@ -313,303 +290,290 @@ float tone_scroll_off[][2] = SONG(SCROLL_LOCK_OFF_SOUND);
void persistant_default_layer_set(uint16_t default_layer)
{
- eeconfig_update_default_layer(default_layer);
- default_layer_set(default_layer);
+ eeconfig_update_default_layer(default_layer);
+ default_layer_set(default_layer);
}
const uint16_t PROGMEM fn_actions[] = {
- [0] = ACTION_MODS_ONESHOT(MOD_LSFT),
+ [0] = ACTION_MODS_ONESHOT(MOD_LSFT),
};
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
{
- // MACRODOWN only works in this function
- switch(id)
+ // MACRODOWN only works in this function
+ switch(id)
+ {
+
+ case MACRO_HELP_1:
+ if (record->event.pressed)
+ {
+ uprint("H1");
+ }
+ break;
+
+ case MACRO_HELP_2:
+ if (record->event.pressed)
+ {
+ uprint("H2");
+ }
+ break;
+
+ case MACRO_HELP_3:
+ if (record->event.pressed)
+ {
+ uprint("H3");
+ }
+ break;
+
+ case MACRO_HELP_4:
+ if (record->event.pressed)
+ {
+ uprint("H4");
+ }
+ break;
+
+ case MACRO_HELP_5:
+ if (record->event.pressed)
+ {
+ uprint("H5");
+ }
+ break;
+
+ case MACRO_HELP_6:
+ if (record->event.pressed)
+ {
+ uprint("H6");
+ }
+ break;
+
+ case MACRO_HELP_7:
+ if (record->event.pressed)
+ {
+ uprint("H7");
+ }
+ break;
+
+ case MACRO_HELP_8:
+ if (record->event.pressed)
+ {
+ uprint("H8");
+ }
+ break;
+
+ case MACRO_HELP_9:
+ if (record->event.pressed)
+ {
+ uprint("H9");
+ }
+ break;
+
+ case MACRO_BREATH_TOGGLE:
+ if (record->event.pressed)
+ {
+ breathing_toggle();
+ }
+ break;
+
+ case MACRO_BREATH_SPEED_INC:
+ if (record->event.pressed)
+ {
+ breathing_speed_inc(1);
+ }
+ break;
+
+ case MACRO_BREATH_SPEED_DEC:
+ if (record->event.pressed)
+ {
+ breathing_speed_dec(1);
+ }
+ break;
+
+ case MACRO_BREATH_DEFAULT:
+ if (record->event.pressed)
+ {
+ breathing_defaults();
+ }
+ break;
+
+ case MACRO_QWERTY:
+ if (record->event.pressed)
+ {
+ persistant_default_layer_set(1UL<<LAYER_QWERTY);
+ }
+ break;
+
+ case MACRO_UPPER:
+ if (record->event.pressed)
{
+ layer_on(LAYER_UPPER);
+ breathing_speed_set(2);
+ breathing_pulse();
+ update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ }
+ else
+ {
+ layer_off(LAYER_UPPER);
+ update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ }
+ break;
+
+ case MACRO_LOWER:
+ if (record->event.pressed)
+ {
+ layer_on(LAYER_LOWER);
+ breathing_speed_set(2);
+ breathing_pulse();
+ update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ }
+ else
+ {
+ layer_off(LAYER_LOWER);
+ update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
+ }
+ break;
- // case MACRO_BREATH_TOGGLE:
- // if (record->event.pressed)
- // {
- // breathing_toggle();
- // }
- // break;
-
- // case MACRO_BREATH_SPEED_INC:
- // if (record->event.pressed)
- // {
- // breathing_speed_inc(1);
- // }
- // break;
-
- // case MACRO_BREATH_SPEED_DEC:
- // if (record->event.pressed)
- // {
- // breathing_speed_dec(1);
- // }
- // break;
-
- // case MACRO_BREATH_DEFAULT:
- // if (record->event.pressed)
- // {
- // breathing_defaults();
- // }
- // break;
-
- case MACRO_QWERTY:
- if (record->event.pressed)
- {
- persistant_default_layer_set(1UL<<LAYER_QWERTY);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_qwerty, false, STACCATO);
- #endif /* AUDIO_ENABLE */
- }
- break;
-
- case MACRO_COLEMAK:
- if (record->event.pressed)
- {
- persistant_default_layer_set(1UL<<LAYER_COLEMAK);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_colemak, false, STACCATO);
- #endif /* AUDIO_ENABLE */
- }
- break;
-
- case MACRO_DVORAK:
- if (record->event.pressed)
- {
- persistant_default_layer_set(1UL<<LAYER_DVORAK);
- #ifdef AUDIO_ENABLE
- PLAY_NOTE_ARRAY(tone_dvorak, false, STACCATO);
- #endif /* AUDIO_ENABLE */
- }
- break;
-
- case MACRO_UPPER:
- if (record->event.pressed)
- {
- layer_on(LAYER_UPPER);
- // breathing_speed_set(2);
- // breathing_pulse();
- update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
- }
- else
- {
- layer_off(LAYER_UPPER);
- update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
- }
- break;
-
- case MACRO_LOWER:
- if (record->event.pressed)
- {
- layer_on(LAYER_LOWER);
- // breathing_speed_set(2);
- // breathing_pulse();
- update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
- }
- else
- {
- layer_off(LAYER_LOWER);
- update_tri_layer(LAYER_LOWER, LAYER_UPPER, LAYER_ADJUST);
- }
- break;
-
- case MACRO_FUNCTION:
- if (record->event.pressed)
- {
- // breathing_speed_set(3);
- // breathing_enable();
- layer_on(LAYER_FUNCTION);
- }
- else
- {
- // breathing_speed_set(1);
- // breathing_self_disable();
- layer_off(LAYER_FUNCTION);
- }
- break;
+ case MACRO_FUNCTION:
+ if (record->event.pressed)
+ {
+ breathing_speed_set(3);
+ breathing_enable();
+ layer_on(LAYER_FUNCTION);
+ }
+ else
+ {
+ breathing_speed_set(1);
+ breathing_self_disable();
+ layer_off(LAYER_FUNCTION);
+ }
+ break;
#ifdef MOUSEKEY_ENABLE
- case MACRO_MOUSE:
- if (record->event.pressed)
- {
- layer_invert(LAYER_MOUSE);
- }
- break;
+ case MACRO_MOUSE:
+ if (record->event.pressed)
+ {
+ layer_invert(LAYER_MOUSE);
+ }
+ break;
#endif /* MOUSEKEY_ENABLE */
#ifdef AUDIO_ENABLE
- case MACRO_TIMBRE_1:
- if (record->event.pressed) set_timbre(TIMBRE_12);
- break;
-
- case MACRO_TIMBRE_2:
- if (record->event.pressed) set_timbre(TIMBRE_25);
- break;
-
- case MACRO_TIMBRE_3:
- if (record->event.pressed) set_timbre(TIMBRE_50);
- break;
-
- case MACRO_TIMBRE_4:
- if (record->event.pressed) set_timbre(TIMBRE_75);
- break;
-
- case MACRO_TEMPO_U:
- if (record->event.pressed) increase_tempo(10);
- break;
-
- case MACRO_TEMPO_D:
- if (record->event.pressed) decrease_tempo(10);
- break;
-
- case MACRO_TONE_DEFAULT:
- if (record->event.pressed)
- {
- set_timbre(TIMBRE_DEFAULT);
- set_tempo(TEMPO_DEFAULT);
- }
- break;
-
-/*
- case MACRO_AUDIO_TOGGLE:
- if (record->event.pressed)
- {
- if (is_audio_on())
- {
- audio_off();
- }
- else
- {
- audio_on();
- PLAY_NOTE_ARRAY(tone_audio_on, false, STACCATO);
- }
- }
- break;
-
- case MACRO_MUSIC_TOGGLE:
- if (record->event.pressed)
- {
- if (IS_LAYER_ON(LAYER_MUSIC))
- {
- layer_off(LAYER_MUSIC);
- stop_all_notes();
- }
- else
- {
- PLAY_NOTE_ARRAY(tone_music_on, false, STACCATO);
- layer_on(LAYER_MUSIC);
- }
- }
- break;
- case MACRO_INC_VOICE:
- if (record->event.pressed)
- {
- #ifdef AUDIO_ENABLE
- voice_iterate();
- PLAY_NOTE_ARRAY(music_scale, false, STACCATO);
- #endif
- }
- break;
-
- case MACRO_DEC_VOICE:
- if (record->event.pressed)
- {
- #ifdef AUDIO_ENABLE
- voice_deiterate();
- PLAY_NOTE_ARRAY(music_scale, false, STACCATO);
- #endif
- }
- break;
-*/
+ case MACRO_TIMBRE_1:
+ if (record->event.pressed) set_timbre(TIMBRE_12);
+ break;
+
+ case MACRO_TIMBRE_2:
+ if (record->event.pressed) set_timbre(TIMBRE_25);
+ break;
+
+ case MACRO_TIMBRE_3:
+ if (record->event.pressed) set_timbre(TIMBRE_50);
+ break;
+
+ case MACRO_TIMBRE_4:
+ if (record->event.pressed) set_timbre(TIMBRE_75);
+ break;
+
+ case MACRO_TEMPO_U:
+ if (record->event.pressed) increase_tempo(10);
+ break;
+
+ case MACRO_TEMPO_D:
+ if (record->event.pressed) decrease_tempo(10);
+ break;
+
+ case MACRO_TONE_DEFAULT:
+ if (record->event.pressed)
+ {
+ set_timbre(TIMBRE_DEFAULT);
+ set_tempo(TEMPO_DEFAULT);
+ }
+ break;
#endif /* AUDIO_ENABLE */
#ifdef BACKLIGHT_ENABLE
- case MACRO_BACKLIGHT:
- if (record->event.pressed)
- {
- backlight_step();
- }
-#endif
+ case MACRO_BACKLIGHT:
+ if (record->event.pressed)
+ {
+ backlight_step();
+ }
+ break;
+#endif /* BACKLIGHT_ENABLE */
- default:
- break;
+ default:
+ break;
- }
- return MACRO_NONE;
+}
+return MACRO_NONE;
};
-
#ifdef AUDIO_ENABLE
void matrix_init_user(void)
{
- set_voice(default_voice);
- startup_user();
- println("Matrix Init");
+ set_voice(default_voice);
+ startup_user();
+ println("Matrix Init");
}
void led_set_user(uint8_t usb_led)
{
- static uint8_t old_usb_led = 0;
+ static uint8_t old_usb_led = 0;
- _delay_ms(10); // gets rid of tick
+ _delay_ms(10); // gets rid of tick
- if (!is_playing_notes())
+ if (!is_playing_notes())
+ {
+ if ((usb_led & (1<<USB_LED_CAPS_LOCK)) && !(old_usb_led & (1<<USB_LED_CAPS_LOCK)))
+ {
+ // If CAPS LK LED is turning on...
+ PLAY_NOTE_ARRAY(tone_caps_on, false, LEGATO);
+ }
+ else if (!(usb_led & (1<<USB_LED_CAPS_LOCK)) && (old_usb_led & (1<<USB_LED_CAPS_LOCK)))
+ {
+ // If CAPS LK LED is turning off...
+ PLAY_NOTE_ARRAY(tone_caps_off, false, LEGATO);
+ }
+ else if ((usb_led & (1<<USB_LED_NUM_LOCK)) && !(old_usb_led & (1<<USB_LED_NUM_LOCK)))
+ {
+ // If NUM LK LED is turning on...
+ PLAY_NOTE_ARRAY(tone_numlk_on, false, LEGATO);
+ }
+ else if (!(usb_led & (1<<USB_LED_NUM_LOCK)) && (old_usb_led & (1<<USB_LED_NUM_LOCK)))
{
- if ((usb_led & (1<<USB_LED_CAPS_LOCK)) && !(old_usb_led & (1<<USB_LED_CAPS_LOCK)))
- {
- // If CAPS LK LED is turning on...
- PLAY_NOTE_ARRAY(tone_caps_on, false, LEGATO);
- }
- else if (!(usb_led & (1<<USB_LED_CAPS_LOCK)) && (old_usb_led & (1<<USB_LED_CAPS_LOCK)))
- {
- // If CAPS LK LED is turning off...
- PLAY_NOTE_ARRAY(tone_caps_off, false, LEGATO);
- }
- else if ((usb_led & (1<<USB_LED_NUM_LOCK)) && !(old_usb_led & (1<<USB_LED_NUM_LOCK)))
- {
- // If NUM LK LED is turning on...
- PLAY_NOTE_ARRAY(tone_numlk_on, false, LEGATO);
- }
- else if (!(usb_led & (1<<USB_LED_NUM_LOCK)) && (old_usb_led & (1<<USB_LED_NUM_LOCK)))
- {
- // If NUM LED is turning off...
- PLAY_NOTE_ARRAY(tone_numlk_off, false, LEGATO);
- }
- else if ((usb_led & (1<<USB_LED_SCROLL_LOCK)) && !(old_usb_led & (1<<USB_LED_SCROLL_LOCK)))
- {
- // If SCROLL LK LED is turning on...
- PLAY_NOTE_ARRAY(tone_scroll_on, false, LEGATO);
- }
- else if (!(usb_led & (1<<USB_LED_SCROLL_LOCK)) && (old_usb_led & (1<<USB_LED_SCROLL_LOCK)))
- {
- // If SCROLL LED is turning off...
- PLAY_NOTE_ARRAY(tone_scroll_off, false, LEGATO);
- }
+ // If NUM LED is turning off...
+ PLAY_NOTE_ARRAY(tone_numlk_off, false, LEGATO);
}
+ else if ((usb_led & (1<<USB_LED_SCROLL_LOCK)) && !(old_usb_led & (1<<USB_LED_SCROLL_LOCK)))
+ {
+ // If SCROLL LK LED is turning on...
+ PLAY_NOTE_ARRAY(tone_scroll_on, false, LEGATO);
+ }
+ else if (!(usb_led & (1<<USB_LED_SCROLL_LOCK)) && (old_usb_led & (1<<USB_LED_SCROLL_LOCK)))
+ {
+ // If SCROLL LED is turning off...
+ PLAY_NOTE_ARRAY(tone_scroll_off, false, LEGATO);
+ }
+ }
- old_usb_led = usb_led;
+ old_usb_led = usb_led;
}
-
void startup_user()
{
- _delay_ms(10); // gets rid of tick
- PLAY_NOTE_ARRAY(tone_my_startup, false, STACCATO);
+ _delay_ms(10); // gets rid of tick
+ PLAY_NOTE_ARRAY(tone_my_startup, false, STACCATO);
}
void shutdown_user()
{
- PLAY_NOTE_ARRAY(tone_my_goodbye, false, STACCATO);
- _delay_ms(2000);
- stop_all_notes();
+ PLAY_NOTE_ARRAY(tone_my_goodbye, false, STACCATO);
+ _delay_ms(2000);
+ stop_all_notes();
}
void audio_on_user(void)
diff --git a/keyboards/vision_division/matrix_types.h b/keyboards/vision_division/matrix_types.h
index d40b2079a6..893e5272a3 100644
--- a/keyboards/vision_division/matrix_types.h
+++ b/keyboards/vision_division/matrix_types.h
@@ -139,28 +139,29 @@
// Changable Row Macro
-#define KEYMAP_ROW(LEFT_TYPE, RIGHT_TYPE, \
+#define _KEYMAP_ROW( _LEFT_TYPE, _RIGHT_TYPE, \
k001, k002, k003, k004, k005, k006, k007, k008, k009, k00A, k00B, k00C, k011, k012, k013, k014, k015, k016, k017, k018, k019, k01A, k01B, k01C \
) \
-KEYMAP_ROW_LEFT_ ## LEFT_TYPE(k001, k002, k003, k004, k005, k006, k007, k008, k009, k00A, k00B, k00C), KEYMAP_ROW_RIGHT_ ## RIGHT_TYPE(k011, k012, k013, k014, k015, k016, k017, k018, k019, k01A, k01B, k01C)
+KEYMAP_ROW_LEFT_ ## _LEFT_TYPE( k001, k002, k003, k004, k005, k006, k007, k008, k009, k00A, k00B, k00C ), \
+KEYMAP_ROW_RIGHT_ ## _RIGHT_TYPE( k011, k012, k013, k014, k015, k016, k017, k018, k019, k01A, k01B, k01C )
// Changable Master Macro
-#define KEYMAP_MASTER(LEFT_TYPE, RIGHT_TYPE, \
- k001, k002, k003, k004, k005, k006, k007, k008, k009, k00A, k00B, k00C, k011, k012, k013, k014, k015, k016, k017, k018, k019, k01A, k01B, k01C, \
- k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k10B, k10C, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C, \
- k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k20B, k20C, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C, \
- k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k30B, k30C, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C, \
- k401, k402, k403, k404, k405, k406, k407, k408, k409, k40A, k40B, k40C, k411, k412, k413, k414, k415, k416, k417, k418, k419, k41A, k41B, k41C, \
- k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k50B, k50C, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C \
+#define KEYMAP_MASTER(_MATRIX_LAYER, _LEFT_TYPE, _RIGHT_TYPE, \
+ k001, k002, k003, k004, k005, k006, k007, k008, k009, k00A, k00B, k00C, k011, k012, k013, k014, k015, k016, k017, k018, k019, k01A, k01B, k01C, \
+ k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k10B, k10C, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C, \
+ k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k20B, k20C, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C, \
+ k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k30B, k30C, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C, \
+ k401, k402, k403, k404, k405, k406, k407, k408, k409, k40A, k40B, k40C, k411, k412, k413, k414, k415, k416, k417, k418, k419, k41A, k41B, k41C, \
+ k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k50B, k50C, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C \
) \
-{ \
- { KEYMAP_ROW(LEFT_TYPE, RIGHT_TYPE, k001, k002, k003, k004, k005, k006, k007, k008, k009, k00A, k00B, k00C, k011, k012, k013, k014, k015, k016, k017, k018, k019, k01A, k01B, k01C ) },\
- { KEYMAP_ROW(LEFT_TYPE, RIGHT_TYPE, k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k10B, k10C, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C ) },\
- { KEYMAP_ROW(LEFT_TYPE, RIGHT_TYPE, k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k20B, k20C, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C ) },\
- { KEYMAP_ROW(LEFT_TYPE, RIGHT_TYPE, k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k30B, k30C, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C ) },\
- { KEYMAP_ROW(LEFT_TYPE, RIGHT_TYPE, k401, k402, k403, k404, k405, k406, k407, k408, k409, k40A, k40B, k40C, k411, k412, k413, k414, k415, k416, k417, k418, k419, k41A, k41B, k41C ) },\
- { KEYMAP_ROW(LEFT_TYPE, RIGHT_TYPE, k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k50B, k50C, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C ) },\
+[_MATRIX_LAYER] = { \
+ { _KEYMAP_ROW( _LEFT_TYPE, _RIGHT_TYPE, k001, k002, k003, k004, k005, k006, k007, k008, k009, k00A, k00B, k00C, k011, k012, k013, k014, k015, k016, k017, k018, k019, k01A, k01B, k01C ) },\
+ { _KEYMAP_ROW( _LEFT_TYPE, _RIGHT_TYPE, k101, k102, k103, k104, k105, k106, k107, k108, k109, k10A, k10B, k10C, k111, k112, k113, k114, k115, k116, k117, k118, k119, k11A, k11B, k11C ) },\
+ { _KEYMAP_ROW( _LEFT_TYPE, _RIGHT_TYPE, k201, k202, k203, k204, k205, k206, k207, k208, k209, k20A, k20B, k20C, k211, k212, k213, k214, k215, k216, k217, k218, k219, k21A, k21B, k21C ) },\
+ { _KEYMAP_ROW( _LEFT_TYPE, _RIGHT_TYPE, k301, k302, k303, k304, k305, k306, k307, k308, k309, k30A, k30B, k30C, k311, k312, k313, k314, k315, k316, k317, k318, k319, k31A, k31B, k31C ) },\
+ { _KEYMAP_ROW( _LEFT_TYPE, _RIGHT_TYPE, k401, k402, k403, k404, k405, k406, k407, k408, k409, k40A, k40B, k40C, k411, k412, k413, k414, k415, k416, k417, k418, k419, k41A, k41B, k41C ) },\
+ { _KEYMAP_ROW( _LEFT_TYPE, _RIGHT_TYPE, k501, k502, k503, k504, k505, k506, k507, k508, k509, k50A, k50B, k50C, k511, k512, k513, k514, k515, k516, k517, k518, k519, k51A, k51B, k51C ) },\
}
diff --git a/keyboards/vision_division/readme.md b/keyboards/vision_division/readme.md
index 0a637fd068..de200d7c5b 100644
--- a/keyboards/vision_division/readme.md
+++ b/keyboards/vision_division/readme.md
@@ -1,6 +1,12 @@
vision_division keyboard firmware
======================
+## Keyboard Info
+
+[See this thread.](https://geekhack.org/index.php?topic=83692.msg2227856#msg2227856)
+
+Vision/Division is a full size or split keyboard that can be customized due to its pcb.
+
## Quantum MK Firmware
For the full Quantum feature list, see [the parent readme.md](/doc/readme.md).
diff --git a/keyboards/vision_division/rules.mk b/keyboards/vision_division/rules.mk
new file mode 100644
index 0000000000..6990960bf0
--- /dev/null
+++ b/keyboards/vision_division/rules.mk
@@ -0,0 +1,70 @@
+
+
+# MCU name
+MCU = at90usb1286
+# MCU = at90usb1287
+# MCU = atmega32u4
+
+# Processor frequency.
+# This will define a symbol, F_CPU, in all source code files equal to the
+# processor frequency in Hz. You can then use this symbol in your source code to
+# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
+# automatically to create a 32-bit value in your source code.
+#
+# This will be an integer division of F_USB below, as it is sourced by
+# F_USB after it has run through any CPU prescalers. Note that this value
+# does not *change* the processor frequency - it should merely be updated to
+# reflect the processor speed set externally so that the code can use accurate
+# software delays.
+F_CPU = 16000000
+
+
+#
+# LUFA specific
+#
+# Target architecture (see library "Board Types" documentation).
+ARCH = AVR8
+
+# Input clock frequency.
+# This will define a symbol, F_USB, in all source code files equal to the
+# input clock frequency (before any prescaling is performed) in Hz. This value may
+# differ from F_CPU if prescaling is used on the latter, and is required as the
+# raw input clock is fed directly to the PLL sections of the AVR for high speed
+# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
+# at the end, this will be done automatically to create a 32-bit value in your
+# source code.
+#
+# If no clock division is performed on the input clock inside the AVR (via the
+# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
+F_USB = $(F_CPU)
+
+# Interrupt driven control endpoint task(+60)
+OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
+
+
+# Boot Section Size in *bytes*
+# Teensy halfKay 512
+# Teensy++ halfKay 1024
+# Atmel DFU loader 4096
+# LUFA bootloader 4096
+# USBaspLoader 2048
+OPT_DEFS += -DBOOTLOADER_SIZE=1024
+
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE ?= yes # Virtual DIP switch configuration(+1000)
+MOUSEKEY_ENABLE ?= yes # Mouse keys(+4700)
+EXTRAKEY_ENABLE ?= yes # Audio control and System control(+450)
+CONSOLE_ENABLE ?= yes # Console for debug(+400)
+COMMAND_ENABLE ?= yes # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE ?= yes # USB Nkey Rollover
+BACKLIGHT_ENABLE ?= yes # Enable keyboard backlight functionality on B7 by default
+MIDI_ENABLE ?= no # MIDI controls
+UNICODE_ENABLE ?= no # Unicode
+BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
+AUDIO_ENABLE ?= no # Audio output on port C6 \ No newline at end of file
diff --git a/keyboards/vision_division/vision_division.c b/keyboards/vision_division/vision_division.c
index eb9336fa33..a0e0f449c4 100644
--- a/keyboards/vision_division/vision_division.c
+++ b/keyboards/vision_division/vision_division.c
@@ -24,5 +24,45 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
void led_set_kb(uint8_t usb_led) {
// put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
+ if (usb_led & (1 << USB_LED_CAPS_LOCK))
+ {
+ // HI
+ DDRD |= (1<<4);
+ PORTD |= (1<<4);
+ }
+ else
+ {
+ // Hi-Z
+ DDRD &= ~(1<<4);
+ PORTD &= ~(1<<4);
+ }
+
+ if (usb_led & (1 << USB_LED_NUM_LOCK))
+ {
+ // HI
+ DDRD |= (1<<5);
+ PORTD |= (1<<5);
+ }
+ else
+ {
+ // Hi-Z
+ DDRD &= ~(1<<5);
+ PORTD &= ~(1<<5);
+ }
+
+ if (usb_led & (1 << USB_LED_SCROLL_LOCK))
+ {
+ // HI
+ DDRD |= (1<<6);
+ PORTD |= (1<<6);
+ }
+ else
+ {
+ // Hi-Z
+ DDRD &= ~(1<<6);
+ PORTD &= ~(1<<6);
+ }
+
led_set_user(usb_led);
}
+