summaryrefslogtreecommitdiff
path: root/keyboards/ergodox
diff options
context:
space:
mode:
authordbroqua <dbroqua@mousur.org>2016-12-17 22:28:56 +0100
committerdbroqua <dbroqua@mousur.org>2016-12-17 22:28:56 +0100
commitc3469b8d2175cd5a6f3c922d478222bf3908516e (patch)
tree98123b52d6ce2938d424339417e2c54864e15260 /keyboards/ergodox
parentdf50bee5a88cacbd1f5fab98b26c2068646b61c0 (diff)
parentc9803f78b2409cfaf6a1be0a4b6c1a37778a3f37 (diff)
Merge branch 'master' of https://github.com/Dbroqua/qmk_firmware
Diffstat (limited to 'keyboards/ergodox')
-rw-r--r--keyboards/ergodox/ez/config.h2
-rw-r--r--keyboards/ergodox/keymaps/default/keymap.c12
-rw-r--r--keyboards/ergodox/keymaps/dvorak_programmer/Makefile2
-rw-r--r--keyboards/ergodox/keymaps/dvorak_programmer/README.md16
-rw-r--r--keyboards/ergodox/keymaps/dvorak_programmer/keymap.c71
-rw-r--r--keyboards/ergodox/keymaps/pvinis/keymap.c171
-rw-r--r--keyboards/ergodox/keymaps/reset_eeprom/keymap.c140
7 files changed, 318 insertions, 96 deletions
diff --git a/keyboards/ergodox/ez/config.h b/keyboards/ergodox/ez/config.h
index c2750a321f..a3dc5bf152 100644
--- a/keyboards/ergodox/ez/config.h
+++ b/keyboards/ergodox/ez/config.h
@@ -56,6 +56,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* Set 0 if debouncing isn't needed */
#define DEBOUNCE 5
+#define USB_MAX_POWER_CONSUMPTION 50
+
/*
* Feature disable options
* These options are also useful to firmware size reduction.
diff --git a/keyboards/ergodox/keymaps/default/keymap.c b/keyboards/ergodox/keymaps/default/keymap.c
index 4eff280850..4477cab310 100644
--- a/keyboards/ergodox/keymaps/default/keymap.c
+++ b/keyboards/ergodox/keymaps/default/keymap.c
@@ -22,7 +22,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
* | Del | Q | W | E | R | T | L1 | | L1 | Y | U | I | O | P | \ |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
- * | BkSp | A | S | D | F | G |------| |------| H |J/Alt | K | L |; / L2|' / Cmd |
+ * | 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 |
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
@@ -49,11 +49,11 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
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, ALT_T(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_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_PGDN,KC_TAB, KC_ENT
diff --git a/keyboards/ergodox/keymaps/dvorak_programmer/Makefile b/keyboards/ergodox/keymaps/dvorak_programmer/Makefile
index 1fd6cb9ffd..3c65e25e19 100644
--- a/keyboards/ergodox/keymaps/dvorak_programmer/Makefile
+++ b/keyboards/ergodox/keymaps/dvorak_programmer/Makefile
@@ -5,4 +5,4 @@ FORCE_NKRO ?= yes
DEBUG_ENABLE = no
CONSOLE_ENABLE = no
TAP_DANCE_ENABLE = yes
-MOUSEKEY_ENABLE = no
+MOUSEKEY_ENABLE = yes
diff --git a/keyboards/ergodox/keymaps/dvorak_programmer/README.md b/keyboards/ergodox/keymaps/dvorak_programmer/README.md
index a4580fe064..3e4a2545b8 100644
--- a/keyboards/ergodox/keymaps/dvorak_programmer/README.md
+++ b/keyboards/ergodox/keymaps/dvorak_programmer/README.md
@@ -11,5 +11,19 @@ Layers
* KEY_NAV: arrow key movement with backward/forward word support, and copy/paste.
* KEY_SEL: same as above, but every movement shift-selects.
* NUMBER: keypad layer.
-* SYMBOL: all the symbols as well as brackets at the bottom.
+* SYMBOL: all the symbols.
+* BRACKET: special brackets-only layer for programming
* SHORTCUTS: sends Hyper keys for Autohotkey to interpret. I use this to switch between specific apps.
+* MOUSE: use mouse keys
+
+Updates
+-------
+
+2016/12/10:
+* toggle for brackets layer is now on left thumb cluster.
+
+2016/11/05:
+* removed brackets anywhere but in brackets layer
+* added mouse layer back in
+* put semicolon-newline and end-newline on symbol layer
+* replaced all HYPR with MEH, added more shortcut keys \ No newline at end of file
diff --git a/keyboards/ergodox/keymaps/dvorak_programmer/keymap.c b/keyboards/ergodox/keymaps/dvorak_programmer/keymap.c
index 5100115a64..f3d02f688d 100644
--- a/keyboards/ergodox/keymaps/dvorak_programmer/keymap.c
+++ b/keyboards/ergodox/keymaps/dvorak_programmer/keymap.c
@@ -13,6 +13,7 @@
#define SYMBOL 6
#define BRACKETS 7
#define SHORTCUTS 8
+#define MOUSE 9
// macros
#define MC_COPY_LINE 0
@@ -57,13 +58,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[BASE] = KEYMAP( // layer 0 : default
// left hand
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6,
- LT(BRACKETS,KC_TAB), KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, MO(KEY_SEL),
+ LT(MOUSE,KC_TAB), KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, MO(KEY_SEL),
MO(SHELL_NAV), KC_A, KC_O, KC_E, KC_U, KC_I,
KC_FN3, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, MO(KEY_NAV),
OSL(SHORTCUTS),KC_FN4, KC_FN5,OSL(SYMBOL),MO(NUMBER),
// thumb cluster
- RCTL(KC_F), RCTL(KC_S),
- RCTL(KC_DEL),
+ MO(BRACKETS), RCTL(KC_S),
+ RCTL(KC_DEL),
KC_BSPC,RCTL(KC_BSPC),KC_DEL,
// right hand
KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_BSLS,
@@ -71,9 +72,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_D, KC_H, KC_T, KC_N, KC_S, KC_MINS,
KC_PGDN, KC_B, KC_M, KC_W, KC_V, KC_Z, TD(TD_SHIFT_CAPSLOCK),
// lower keys - browser tab control
- RSFT(RCTL(KC_TAB)), RCTL(KC_TAB), RCTL(KC_T), RCTL(KC_K), RCTL(KC_W),
+ RSFT(RCTL(KC_TAB)), RCTL(KC_TAB), RCTL(KC_T), LALT(KC_LEFT), RCTL(KC_W),
// thumb cluster
- M(SEMICOLON_NEWLINE), M(END_NEWLINE),
+ KC_HOME,KC_END,
KC_UP,
KC_DOWN,KC_ENT, KC_SPC
),
@@ -96,7 +97,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
RCTL(KC_L), RCTL(KC_W), KC_HOME, KC_UP, KC_END, LALT(KC_D), RCTL(KC_R),
LALT(KC_B), KC_LEFT, KC_DOWN, KC_RIGHT, LALT(KC_F), LALT(KC_DOT),
- RCTL(KC_C), RCTL(KC_U), M(SCREEN_COPY_MODE), M(SCREEN_PASTE), HYPR(KC_V), RCTL(KC_K), M(SHELL_RECALL_LAST_ARG_REMOVE_FIRST_COMMAND),
+ RCTL(KC_C), RCTL(KC_U), M(SCREEN_COPY_MODE), M(SCREEN_PASTE), MEH(KC_V), RCTL(KC_K), M(SHELL_RECALL_LAST_ARG_REMOVE_FIRST_COMMAND),
// bottom row
M(SCREEN_TAB_LEFT), M(SCREEN_TAB_RIGHT), M(SCREEN_NEW_TAB), KC_TRNS, KC_TRNS,
// thumb cluster
@@ -187,21 +188,21 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[SYMBOL] = KEYMAP(
// left hand
- KC_NO,KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6,
- KC_TRNS,KC_TRNS, M(OPEN_CLOSE_PAREN), KC_LPRN, KC_RPRN, KC_TRNS, KC_TRNS,
- KC_TRNS,KC_TRNS, M(OPEN_CLOSE_BRACKET), KC_LBRC, KC_RBRC, M(OPEN_CLOSE_DOUBLE_QUOTE),
- KC_TRNS,M(SEMICOLON_NEWLINE),M(OPEN_CLOSE_CURLY), KC_LCBR, KC_RCBR, M(OPEN_CLOSE_SINGLE_QUOTE),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,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_LPRN, KC_RPRN, KC_LBRC, KC_RBRC, KC_LCBR, KC_RCBR, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_PLUS, KC_AMPR, KC_ASTR, KC_GRAVE,KC_TILD, KC_TRNS,
KC_MINS, KC_DLR, KC_PERC, KC_CIRC, KC_PIPE, KC_TRNS,
KC_TRNS, KC_EQUAL,KC_EXLM, KC_AT, KC_HASH, KC_TRNS, KC_TRNS,
- KC_LBRC, KC_RBRC, TD(TD_BRK_LEFT), TD(TD_BRK_RIGHT), KC_TRNS,
- KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ M(SEMICOLON_NEWLINE), M(END_NEWLINE),
KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS
),
@@ -229,26 +230,46 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[SHORTCUTS] = KEYMAP(
// left hand
- KC_NO, HYPR(KC_F1), HYPR(KC_F2), HYPR(KC_F3), HYPR(KC_F4), HYPR(KC_F5), HYPR(KC_F6),
+ KC_NO, MEH(KC_F1), MEH(KC_F2), MEH(KC_F3), MEH(KC_F4), MEH(KC_F5), MEH(KC_F6),
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,
- KC_TRNS,KC_TRNS,KC_TRNS,
+ MEH(KC_0),MEH(KC_1),
+ MEH(KC_2),
+ MEH(KC_3),MEH(KC_4),MEH(KC_5),
// right hand
- HYPR(KC_F7), HYPR(KC_F8), HYPR(KC_F9), HYPR(KC_F10), HYPR(KC_F11), HYPR(KC_F12), M(SWITCH_NDS),
- KC_TRNS, HYPR(KC_A), HYPR(KC_B), HYPR(KC_C), HYPR(KC_D), HYPR(KC_E), HYPR(KC_F),
- HYPR(KC_G), HYPR(KC_H), HYPR(KC_I), HYPR(KC_J), HYPR(KC_K), HYPR(KC_L),
- KC_TRNS, HYPR(KC_M), HYPR(KC_N), HYPR(KC_O), HYPR(KC_P), HYPR(KC_Q), HYPR(KC_R),
- LALT(KC_LEFT),LALT(KC_RIGHT),KC_F5, LCTL(LGUI(KC_LEFT)), LCTL(LGUI(KC_RIGHT)),
+ MEH(KC_F7), MEH(KC_F8), MEH(KC_F9), MEH(KC_F10), MEH(KC_F11), MEH(KC_F12), M(SWITCH_NDS),
+ KC_TRNS, MEH(KC_A), MEH(KC_B), MEH(KC_C), MEH(KC_D), MEH(KC_E), MEH(KC_F),
+ MEH(KC_G), MEH(KC_H), MEH(KC_I), MEH(KC_J), MEH(KC_K), MEH(KC_L),
+ KC_TRNS, MEH(KC_M), MEH(KC_N), MEH(KC_O), MEH(KC_P), MEH(KC_Q), MEH(KC_R),
+ MEH(KC_S), MEH(KC_T), MEH(KC_U), MEH(KC_V), MEH(KC_X),
+ MEH(KC_6), MEH(KC_7),
+ MEH(KC_8),
+ MEH(KC_9), MEH(KC_Y), MEH(KC_Z)
+),
+
+
+[MOUSE] = KEYMAP(
+ 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, 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_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_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_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS,
KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS
+ KC_TRNS, KC_BTN1, KC_BTN2
),
-
};
diff --git a/keyboards/ergodox/keymaps/pvinis/keymap.c b/keyboards/ergodox/keymaps/pvinis/keymap.c
index df906201a8..87ad70c919 100644
--- a/keyboards/ergodox/keymaps/pvinis/keymap.c
+++ b/keyboards/ergodox/keymaps/pvinis/keymap.c
@@ -13,20 +13,16 @@ enum {
QWERTY,
CARPALX,
SYSCTL,
+ MOUSE,
};
// extra keys
enum {
NONE = 0,
- // mouse
- MS_UL, // up left
- MS_UR, // up right
- MS_DL, // down left
- MS_DR, // down right
-
// tap dance
TD_FLSH, // flash keyboard
+ TD_LAYR, // SYSCTL and MOUSE layer switch
};
// application selection
@@ -52,7 +48,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* | | | | | | | | | | | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
- * |BEGIN |QWERTY| |SYSCTL| |
+ * |BEGIN |QWERTY| | | |
* ,------|------|------| |------+--------+------.
* | | |CARPAL| |Slack | | |
* |Backsp|LShift|------| |------| Enter |Space |
@@ -66,9 +62,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
- ,TG(BEGIN) ,TG(QWERTY)
- ,TG(CARPALX)
- ,KC_BSPC ,KC_LSFT ,TG(SYSCTL)
+ ,TG(BEGIN) ,TD(TD_LAYR)
+ ,TG(MOUSE)
+ ,KC_BSPC ,KC_LSFT ,TD(TD_LAYR)
,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
@@ -85,7 +81,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* a beginner's keymap i currently use.
*
* ,--------------------------------------------------. ,--------------------------------------------------.
- * | | 1 | 2 | 3 | 4 | 5 | 6 | | 6 | 7 | 8 | 9 | 0 | - | = |
+ * | | 1 | 2 | 3 | 4 | 5 | opt | | 6 | 7 | 8 | 9 | 0 | - | = |
* |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
* | Tab | Q | W | E | R | T | [ | | ] | Y | U | I | O | P | \ |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
@@ -104,7 +100,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* `--------------------' `----------------------'
*/
[BEGIN] = KEYMAP(
- KC_TRNS ,KC_1 ,KC_2 ,KC_3 ,KC_4 ,KC_5 ,KC_6
+ KC_TRNS ,KC_1 ,KC_2 ,KC_3 ,KC_4 ,KC_5 ,KC_LALT
,KC_TAB ,KC_Q ,KC_W ,KC_E ,KC_R ,KC_T ,KC_LBRC
,CTL_T(KC_ESC) ,KC_A ,KC_S ,KC_D ,KC_F ,KC_G
,KC_LSFT ,KC_Z ,KC_X ,KC_C ,KC_V ,KC_B ,KC_LPRN
@@ -213,30 +209,73 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
,KC_TRNS ,KC_TRNS ,KC_TRNS
),
-
/* SYSCTL
* a keymap to control my system.
*
+ * ,--------------------------------------------------. ,------------------------------------------------------.
+ * | ^ | | | | | | | | | | | | | | |
+ * |--------+------+------+------+------+-------------| |------+------+------+----------+------+------+--------|
+ * | | | | | | | | | | Mute | Home | Up | End | | |
+ * |--------+------+------+------+------+------| | | |------+------+----------+------+------+--------|
+ * | | | | | | |------| |------|VolUp | Left | Down |Right | | Lock |
+ * |--------+------+------+------+------+------| | | |------+------+----------+------+------+--------|
+ * | | | | | | | | | |VolDn | Prev |Play/Pause| Next | | Sleep |
+ * `--------+------+------+------+------+-------------' `-------------+------+----------+------+------+--------'
+ * | | | | | | | | | | | Power|
+ * `----------------------------------' `--------------------------------------'
+ * ,-------------. ,-------------.
+ * | | | | | |
+ * ,------|------|------| |------+------+------.
+ * | | | | | | | |
+ * | | |------| |------| | |
+ * | | | ^ | | | | |
+ * `--------------------' `--------------------'
+ */
+[SYSCTL] = KEYMAP(
+ KC_TRNS ,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
+ ,KC_NO ,KC_NO ,KC_TRNS
+
+ /*,KC_POP /// */,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+ /* /// ,KC_PTRN*/,KC_NO ,KC_MUTE ,KC_HOME ,KC_UP ,KC_END ,KC_NO ,KC_NO
+ ,KC_VOLU ,KC_LEFT ,KC_DOWN ,KC_RGHT ,KC_NO ,LCTL(LSFT(KC_PWR))
+ ,KC_NO ,KC_VOLD ,KC_MPRV ,KC_MPLY ,KC_MNXT ,KC_NO ,KC_SLEP
+ ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_PWR
+
+ ,KC_NO ,KC_NO
+ ,KC_NO
+ ,KC_NO ,KC_NO ,KC_NO
+),
+
+/* MOUSE
+ * a keymap to control my system.
+ *
* ,--------------------------------------------------. ,--------------------------------------------------.
- * | | | | | | | | | | | | Mute |VolDn |VolUp | |
+ * | ^ | | | | | | | | | | | | | | |
* |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------|
- * | | | | | | | | | | |MsUpL | MsUp |MsUpR | | |
+ * | | | | | | | | | | | | MsUp | | | |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
- * | | | | | | |------| |------| |MsLeft| MsDn |MsRght| | Lock |
+ * | | | | | | |------| |------| |MsLeft| MsDn |MsRght| | |
* |--------+------+------+------+------+------| | | |------+------+------+------+------+--------|
- * | | | | | | | | | | |MsDnL | MsDn | | | Sleep |
+ * | | | | | | | | | | | | | | | |
* `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------'
- * | | | | | | | | | | | Power|
+ * | | | | | | | | | | | |
* `----------------------------------' `----------------------------------'
* ,-------------. ,-------------.
* | | | | |MidClk|
* ,------|------|------| |------+------+------.
* | | | | | |Left |Right |
* | | |------| |------| Click| Click|
- * | | | | | | | |
+ * | | | ^ | | | | |
* `--------------------' `--------------------'
*/
-[SYSCTL] = KEYMAP(
+[MOUSE] = KEYMAP(
KC_TRNS ,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
@@ -245,13 +284,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
,KC_NO ,KC_NO
,KC_NO
- ,KC_NO ,KC_NO ,KC_NO
+ ,KC_NO ,KC_NO ,KC_TRNS
- /*,KC_POP*/,KC_NO ,KC_NO ,KC_NO ,KC_MUTE ,KC_VOLD ,KC_VOLU ,KC_NO
- /*,KC_PTRN*/,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
- ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,LCTL(LSFT(KC_PWR))
- ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_SLEP
- ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_PWR
+ ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO ,KC_NO
+ ,KC_NO ,KC_NO ,KC_NO ,KC_MS_U ,KC_NO ,KC_NO ,KC_NO
+ ,KC_NO ,KC_MS_L ,KC_MS_D ,KC_MS_R ,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
@@ -341,48 +380,29 @@ void matrix_init_user() {
ergodox_led_all_off();
}
-// extra keys
-const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
- switch (id) {
+// light up leds based on the layer
+void matrix_scan_user(void) {
+ uint8_t layer = biton32(layer_state);
- // mouse
- case MS_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 MS_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);
- }
+ switch(layer) {
+ case SYSCTL:
+ ergodox_right_led_3_on();
break;
- case MS_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);
- }
+ case MOUSE:
+ ergodox_right_led_2_on();
break;
- case MS_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);
- }
+ default:
+ ergodox_right_led_1_off();
+ ergodox_right_led_2_off();
+ ergodox_right_led_3_off();
break;
}
+}
+
+// extra keys
+const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
+ switch (id) {
+ }
return MACRO_NONE;
}
@@ -425,6 +445,31 @@ void flash_dance_reset(qk_tap_dance_state_t *state, void *user_data) {
ergodox_right_led_3_off();
}
+// SYSCTL on first tap, MOUSE ON second tap
+void layers_dance_finished(qk_tap_dance_state_t *state, void *user_data) {
+ uint8_t layer = biton32(layer_state);
+
+ switch(state->count) {
+ case 1:
+ switch(layer) {
+ case SYSCTL:
+ layer_off(SYSCTL);
+ break;
+ case MOUSE:
+ layer_off(MOUSE);
+ break;
+ default:
+ layer_on(SYSCTL);
+ break;
+ }
+ break;
+ case 2:
+ layer_on(MOUSE);
+ break;
+ }
+}
+
qk_tap_dance_action_t tap_dance_actions[] = {
[TD_FLSH] = ACTION_TAP_DANCE_FN_ADVANCED( flash_each_tap, flash_dance_finished, flash_dance_reset ),
+ [TD_LAYR] = ACTION_TAP_DANCE_FN_ADVANCED( NULL, layers_dance_finished, NULL ),
};
diff --git a/keyboards/ergodox/keymaps/reset_eeprom/keymap.c b/keyboards/ergodox/keymaps/reset_eeprom/keymap.c
new file mode 100644
index 0000000000..f708454ce2
--- /dev/null
+++ b/keyboards/ergodox/keymaps/reset_eeprom/keymap.c
@@ -0,0 +1,140 @@
+#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
+
+enum custom_keycodes {
+ PLACEHOLDER = SAFE_RANGE, // can always be here
+ EPRM,
+ VRSN,
+ RGB_SLD
+};
+
+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|
+ * ,------|------|------| |------+--------+------.
+ * | | | 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
+ EPRM, EPRM, EPRM, EPRM, EPRM, EPRM, EPRM,
+ EPRM, EPRM, EPRM, EPRM, EPRM, EPRM, EPRM,
+ EPRM, EPRM, EPRM, EPRM, EPRM, EPRM,
+ EPRM, EPRM, EPRM, EPRM, EPRM, EPRM, EPRM,
+ EPRM, EPRM, EPRM, EPRM,EPRM,
+ EPRM, EPRM,
+ EPRM,
+ EPRM,EPRM,EPRM,
+ // right hand
+ EPRM, EPRM, EPRM, EPRM, EPRM, EPRM, EPRM,
+ EPRM, EPRM, EPRM, EPRM, EPRM, EPRM, EPRM,
+ EPRM, EPRM, EPRM, EPRM, EPRM,EPRM,
+ EPRM,EPRM, EPRM, EPRM,EPRM, EPRM, EPRM,
+ EPRM, EPRM,EPRM,EPRM, EPRM,
+ EPRM, EPRM,
+ EPRM,
+ EPRM,EPRM, EPRM
+ )
+};
+
+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;
+ case 1:
+ if (record->event.pressed) { // For resetting EEPROM
+ eeconfig_init();
+ }
+ break;
+ }
+ return MACRO_NONE;
+};
+
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ // dynamically generate these.
+ case EPRM:
+ if (record->event.pressed) {
+ eeconfig_init();
+ }
+ return false;
+ break;
+ case VRSN:
+ if (record->event.pressed) {
+ SEND_STRING (QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION);
+ }
+ return false;
+ break;
+ case RGB_SLD:
+ if (record->event.pressed) {
+ #ifdef RGBLIGHT_ENABLE
+ rgblight_mode(1);
+ #endif
+ }
+ return false;
+ break;
+ }
+ return true;
+}
+
+// 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;
+ }
+
+};