Bring in ferris sweep
This commit is contained in:
parent
2e99ece8e0
commit
6f28a078ac
87
keyboards/qmk/keymaps/ferris/combos.c
Normal file
87
keyboards/qmk/keymaps/ferris/combos.c
Normal file
@ -0,0 +1,87 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
|
||||
#define MAKE_COMBO_INPUTS(name, inputs...) const uint16_t PROGMEM combo_inputs_##name[] = {inputs, COMBO_END};
|
||||
|
||||
|
||||
// Combo tokens. These are used to identify combos for later processing if needed.
|
||||
enum combos {
|
||||
// Combo that uses both pinky fingers to produce an <enter> keypress
|
||||
COMBO_PINKY_ENTER,
|
||||
// Combo that uses both ring fingers to produce a <backspace> keypress
|
||||
// COMBO_RING_BACKSPC,
|
||||
// Combo that uses the ring fingers to send a semicolon
|
||||
COMBO_RING_SCLN,
|
||||
// Copbo that uses the pinky fingers to send escape
|
||||
COMBO_PINKY_ESC,
|
||||
|
||||
// ASETNIOP
|
||||
ASETNIOP_AE_Q,
|
||||
ASETNIOP_RA_W,
|
||||
ASETNIOP_RE_Z,
|
||||
ASETNIOP_SA_X,
|
||||
ASETNIOP_SR_F,
|
||||
ASETNIOP_TA_P,
|
||||
ASETNIOP_TR_C,
|
||||
ASETNIOP_TS_D,
|
||||
ASETNIOP_TN_B,
|
||||
ASETNIOP_TE_V,
|
||||
ASETNIOP_TI_G,
|
||||
ASETNIOP_NA_J,
|
||||
ASETNIOP_NR_K,
|
||||
ASETNIOP_NS_M,
|
||||
ASETNIOP_NE_H,
|
||||
ASETNIOP_NO_L,
|
||||
ASETNIOP_EI_U,
|
||||
ASETNIOP_IN_Y,
|
||||
};
|
||||
|
||||
// Define all the input combinations needed for the combos
|
||||
MAKE_COMBO_INPUTS(COMBO_PINKY_ENTER, KC_A, KC_O)
|
||||
MAKE_COMBO_INPUTS(COMBO_RING_SCLN, KC_R, KC_I)
|
||||
MAKE_COMBO_INPUTS(COMBO_PINKY_ESC, KC_Q, KC_BSPC)
|
||||
// MAKE_COMBO_INPUTS(COMBO_RING_BACKSPC, KC_R, KC_I)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_AE_Q, KC_A, KC_E)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_RA_W, KC_R, KC_A)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_RE_Z, KC_R, KC_E)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_SA_X, KC_S, KC_A)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_SR_F, KC_S, KC_R)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_TA_P, KC_T, KC_A)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_TR_C, KC_T, KC_R)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_TS_D, KC_T, KC_S)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_TN_B, KC_T, KC_N)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_TE_V, KC_T, KC_E)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_TI_G, KC_T, KC_I)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_NA_J, KC_N, KC_A)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_NR_K, KC_N, KC_R)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_NS_M, KC_N, KC_S)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_NE_H, KC_N, KC_E)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_NO_L, KC_N, KC_O)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_EI_U, KC_E, KC_I)
|
||||
MAKE_COMBO_INPUTS(ASETNIOP_IN_Y, KC_I, KC_N)
|
||||
|
||||
// Map everything together
|
||||
combo_t key_combos[COMBO_COUNT] = {
|
||||
[COMBO_PINKY_ENTER] = COMBO(combo_inputs_COMBO_PINKY_ENTER, KC_ENT),
|
||||
[COMBO_RING_SCLN] = COMBO(combo_inputs_COMBO_RING_SCLN, KC_SCLN),
|
||||
[COMBO_PINKY_ESC] = COMBO(combo_inputs_COMBO_PINKY_ESC, KC_ESC),
|
||||
// [COMBO_RING_BACKSPC] = COMBO(combo_inputs_COMBO_RING_BACKSPC, KC_BSPC),
|
||||
[ASETNIOP_AE_Q] = COMBO(combo_inputs_ASETNIOP_AE_Q, KC_Q),
|
||||
[ASETNIOP_RA_W] = COMBO(combo_inputs_ASETNIOP_RA_W, KC_W),
|
||||
[ASETNIOP_RE_Z] = COMBO(combo_inputs_ASETNIOP_RE_Z, KC_Z),
|
||||
[ASETNIOP_SA_X] = COMBO(combo_inputs_ASETNIOP_SA_X, KC_X),
|
||||
[ASETNIOP_SR_F] = COMBO(combo_inputs_ASETNIOP_SR_F, KC_F),
|
||||
[ASETNIOP_TA_P] = COMBO(combo_inputs_ASETNIOP_TA_P, KC_P),
|
||||
[ASETNIOP_TR_C] = COMBO(combo_inputs_ASETNIOP_TR_C, KC_C),
|
||||
[ASETNIOP_TS_D] = COMBO(combo_inputs_ASETNIOP_TS_D, KC_D),
|
||||
[ASETNIOP_TN_B] = COMBO(combo_inputs_ASETNIOP_TN_B, KC_B),
|
||||
[ASETNIOP_TE_V] = COMBO(combo_inputs_ASETNIOP_TE_V, KC_V),
|
||||
[ASETNIOP_TI_G] = COMBO(combo_inputs_ASETNIOP_TI_G, KC_G),
|
||||
[ASETNIOP_NA_J] = COMBO(combo_inputs_ASETNIOP_NA_J, KC_J),
|
||||
[ASETNIOP_NR_K] = COMBO(combo_inputs_ASETNIOP_NR_K, KC_K),
|
||||
[ASETNIOP_NS_M] = COMBO(combo_inputs_ASETNIOP_NS_M, KC_M),
|
||||
[ASETNIOP_NE_H] = COMBO(combo_inputs_ASETNIOP_NE_H, KC_H),
|
||||
[ASETNIOP_NO_L] = COMBO(combo_inputs_ASETNIOP_NO_L, KC_L),
|
||||
[ASETNIOP_EI_U] = COMBO(combo_inputs_ASETNIOP_EI_U, KC_U),
|
||||
[ASETNIOP_IN_Y] = COMBO(combo_inputs_ASETNIOP_IN_Y, KC_Y),
|
||||
};
|
28
keyboards/qmk/keymaps/ferris/config.h
Normal file
28
keyboards/qmk/keymaps/ferris/config.h
Normal file
@ -0,0 +1,28 @@
|
||||
#pragma once
|
||||
|
||||
// Tapdance settings
|
||||
#define TAPPING_TERM 50
|
||||
#define TAPPING_TERM_PER_KEY
|
||||
#define RETRO_TAPPING // https://docs.qmk.fm/#/tap_hold?id=retro-tapping
|
||||
|
||||
// Space cadet on control key
|
||||
#define LCPO_KEYS KC_LCTL, KC_LSFT, KC_0
|
||||
|
||||
// // Force constant-speed controls for mouse movement
|
||||
// #define MK_3_SPEED
|
||||
// #define MK_MOMENTARY_ACCEL
|
||||
|
||||
// // Override the mode-2 speed
|
||||
// #define MK_C_OFFSET_1 4 // Defaut: 4
|
||||
|
||||
// Bootloader settings
|
||||
#define BOOTMAGIC_LITE_ROW 0
|
||||
#define BOOTMAGIC_LITE_COLUMN 0
|
||||
|
||||
// Chording config
|
||||
#define FORCE_NKRO
|
||||
// #define COMBO_COUNT 3
|
||||
#define COMBO_COUNT 21
|
||||
|
||||
// Settings for enabling experiments
|
||||
#define ENABLE_ASETNIOP
|
82
keyboards/qmk/keymaps/ferris/keymap.c
Normal file
82
keyboards/qmk/keymaps/ferris/keymap.c
Normal file
@ -0,0 +1,82 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
// Combo magic
|
||||
#include "combos.c"
|
||||
|
||||
// Layer definitions
|
||||
enum ferris_layers {
|
||||
_MODMAK,
|
||||
_NUMERIC,
|
||||
_UTILITY,
|
||||
_MACROS,
|
||||
_RAINBOW,
|
||||
};
|
||||
|
||||
// Shorthands
|
||||
#define LD_TERM LGUI(KC_ENT)
|
||||
#define CC_QUIT LGUI(LSFT(KC_Q))
|
||||
#define CC_COMM LCTL(KC_SLSH)
|
||||
#define CC_FMT LCTL(LSFT(KC_I))
|
||||
|
||||
// clang-format off
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_MODMAK] = LAYOUT(
|
||||
KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_BSPC,
|
||||
KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O,
|
||||
KC_LCTL, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_M, KC_K, KC_COMM, KC_DOT,
|
||||
KC_LSFT, MO(_MACROS), LT(_UTILITY, KC_SPACE), LT(_NUMERIC, KC_SPACE)
|
||||
),
|
||||
|
||||
[_NUMERIC] = LAYOUT(
|
||||
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, /**/ KC_F6, KC_F7, KC_F8, KC_F9, KC_F10,
|
||||
KC_1, KC_2, KC_3, KC_4, KC_5, /**/ KC_6, KC_7, KC_8, KC_9, KC_0,
|
||||
KC_LALT, KC_NO, KC_NO, KC_NO, TO(_MODMAK), /**/ KC_LGUI, KC_EQL, KC_MINS, KC_F11, KC_F12,
|
||||
KC_LSFT, KC_LCTL, /**/ KC_NO, KC_NO
|
||||
),
|
||||
|
||||
[_UTILITY] = LAYOUT(
|
||||
KC_Q, KC_VOLD, KC_VOLU, KC_NO, KC_PSCR, /**/ LD_TERM, KC_HOME, KC_PGUP, KC_PGDN, KC_DEL,
|
||||
KC_MPRV, KC_MPLY, KC_MNXT, KC_NO, KC_TAB, /**/ KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_END,
|
||||
KC_NO, KC_NO, KC_NO, CC_FMT, CC_COMM, /**/ KC_QUOTE, KC_SLSH, KC_LBRC, KC_RBRC, KC_BSLS,
|
||||
KC_LSFT, KC_LCTL, /**/ KC_NO, KC_LGUI
|
||||
),
|
||||
|
||||
[_MACROS] = LAYOUT(
|
||||
KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, TO(_RAINBOW),
|
||||
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
|
||||
),
|
||||
|
||||
[_RAINBOW] = LAYOUT(
|
||||
KC_ESC, KC_Q, KC_W, KC_E, KC_5, TO(_MODMAK), KC_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_LSFT, KC_A, KC_S, KC_D, KC_G, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_LCTL, KC_Z, KC_X, KC_C, KC_V, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_SPACE, KC_X, KC_NO, KC_NO
|
||||
)
|
||||
};
|
||||
// clang-format on
|
||||
|
||||
/** THIS IS FOR CREATING A NEW KEYMAP **
|
||||
[_UNSET_] = LAYOUT(
|
||||
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_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_NO, KC_NO, KC_NO, KC_NO
|
||||
)
|
||||
*/
|
||||
|
||||
// Overrides for the tapping terms.
|
||||
uint16_t get_tapping_term(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
// Space cadet needs to be much slower than my default
|
||||
case SC_LSPO:
|
||||
case SC_LCPO:
|
||||
return 200;
|
||||
case LT(_NUMERIC, KC_SPACE):
|
||||
return 1000;
|
||||
default:
|
||||
return TAPPING_TERM;
|
||||
}
|
||||
}
|
9
keyboards/qmk/keymaps/ferris/rules.mk
Normal file
9
keyboards/qmk/keymaps/ferris/rules.mk
Normal file
@ -0,0 +1,9 @@
|
||||
# Override the default bootloader since I am using a non-standard MCU
|
||||
BOOTLOADER = qmk-dfu
|
||||
|
||||
# Enable bootloader keys
|
||||
BOOTMAGIC_ENABLE = yes
|
||||
|
||||
# Set up chording support
|
||||
FORCE_NKRO = yes
|
||||
COMBO_ENABLE = yes
|
@ -119,7 +119,7 @@ def main() -> int:
|
||||
ap.add_argument(
|
||||
"keyboard",
|
||||
help="Keyboard to build/flash",
|
||||
choices=["tg4x"],
|
||||
choices=["tg4x", "ferris/sweep"],
|
||||
)
|
||||
ap.add_argument("--flash-mode", "-f", help="Flash mode to use", default="flash")
|
||||
ap.add_argument(
|
||||
@ -141,8 +141,11 @@ def main() -> int:
|
||||
# Refresh the QMK repository
|
||||
refresh_qmk_repo()
|
||||
|
||||
# Figure out the keymap name
|
||||
keymap = args.keyboard.split("/")[0]
|
||||
|
||||
# Copy the keymap
|
||||
copy_keymap(args.keyboard)
|
||||
copy_keymap(keymap)
|
||||
|
||||
# Handle the modes
|
||||
if args.mode == "build":
|
||||
|
Loading…
x
Reference in New Issue
Block a user