|
|
@ -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 "ergodox.h"
|
|
|
|
#include "debug.h"
|
|
|
|
#include "debug.h"
|
|
|
|
#include "action_layer.h"
|
|
|
|
#include "action_layer.h"
|
|
|
@ -18,10 +21,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|
|
|
* |--------+------+------+------+------+------| Hyper| | Meh |------+------+------+------+------+--------|
|
|
|
|
* |--------+------+------+------+------+------| Hyper| | Meh |------+------+------+------+------+--------|
|
|
|
|
* | LShift |Z/Ctrl| X | C | V | B | | | | N | M | , | . |//Ctrl| RShift |
|
|
|
|
* | 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 | | |
|
|
|
|
* | | | Home | | PgUp | | |
|
|
|
|
* |Backsp| Del |------| |------| Enter | Space|
|
|
|
|
* |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_.
|
|
|
|
// If it accepts an argument (i.e, is a function), it doesn't need KC_.
|
|
|
|
// Otherwise, it needs KC_*
|
|
|
|
// Otherwise, it needs KC_*
|
|
|
|
[BASE] = KEYMAP( // layer 0 : default
|
|
|
|
[BASE] = KEYMAP( // layer 0 : default
|
|
|
|
// left hand
|
|
|
|
// left hand
|
|
|
|
KC_EQL, KC_1, KC_2, KC_3, KC_4, KC_5, KC_LGUI,
|
|
|
|
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_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_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_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,
|
|
|
|
KC_FN1, KC_BSLS, LALT(KC_LSFT), KC_LEFT, KC_RGHT,
|
|
|
|
CTL_T(KC_ESC), ALT_T(KC_APP),
|
|
|
|
KC_LGUI, ALT_T(KC_ESC),
|
|
|
|
KC_HOME,
|
|
|
|
KC_HOME,
|
|
|
|
KC_BSPC,KC_DEL,KC_END,
|
|
|
|
KC_BSPC, KC_DEL, KC_END,
|
|
|
|
// right hand
|
|
|
|
// right hand
|
|
|
|
KC_APP, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,
|
|
|
|
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,
|
|
|
|
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,
|
|
|
|
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,
|
|
|
|
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_UP, KC_DOWN, KC_LBRC, KC_RBRC, KC_FN1,
|
|
|
|
KC_LALT, CTL_T(KC_ESC),
|
|
|
|
ALT_T(KC_ESC), KC_RGUI,
|
|
|
|
KC_PGUP,
|
|
|
|
KC_PGUP,
|
|
|
|
KC_PGDN,KC_ENT, KC_SPC
|
|
|
|
KC_PGDN, KC_ENT, KC_SPC
|
|
|
|
),
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
|
|
/* Keymap 1: Symbol Layer
|
|
|
|
/* 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 | \ | |
|
|
|
|
* | | % | ^ | [ | ] | ~ | | | | & | 1 | 2 | 3 | \ | |
|
|
|
|
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
|
|
|
|
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
|
|
|
@ -74,14 +78,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|
|
|
// SYMBOLS
|
|
|
|
// SYMBOLS
|
|
|
|
[SYMB] = KEYMAP(
|
|
|
|
[SYMB] = KEYMAP(
|
|
|
|
// left hand
|
|
|
|
// left hand
|
|
|
|
KC_TRNS,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRNS,
|
|
|
|
KC_PSCR, 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_SLCK, 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_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_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, KC_TRNS,
|
|
|
|
KC_TRNS,
|
|
|
|
KC_TRNS,
|
|
|
|
KC_TRNS,KC_TRNS,KC_TRNS,
|
|
|
|
KC_TRNS, KC_TRNS, KC_TRNS,
|
|
|
|
// right hand
|
|
|
|
// right hand
|
|
|
|
KC_TRNS, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
|
|
|
|
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_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, KC_TRNS
|
|
|
|
KC_TRNS, KC_TRNS, KC_TRNS
|
|
|
|
),
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
|
|
/* Keymap 2: Media and mouse keys
|
|
|
|
/* 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)
|
|
|
|
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// MACRODOWN only works in this function
|
|
|
|
// 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;
|
|
|
|
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.
|
|
|
|
// Runs just one time when the keyboard initializes.
|
|
|
|
void matrix_init_user(void) {
|
|
|
|
void matrix_init_user(void) {
|
|
|
|
|
|
|
|
|
|
|
|