diff options
Diffstat (limited to 'keyboards')
-rw-r--r-- | keyboards/hotdox/keymaps/bliss/keymap.c | 173 | ||||
-rw-r--r-- | keyboards/hotdox/keymaps/bliss/readme.md | 8 | ||||
-rw-r--r-- | keyboards/hotdox/keymaps/bliss/rules.mk | 5 |
3 files changed, 186 insertions, 0 deletions
diff --git a/keyboards/hotdox/keymaps/bliss/keymap.c b/keyboards/hotdox/keymaps/bliss/keymap.c new file mode 100644 index 000000000..0076718fc --- /dev/null +++ b/keyboards/hotdox/keymaps/bliss/keymap.c | |||
@@ -0,0 +1,173 @@ | |||
1 | /* Copyright 2021 Benjamin Chausse | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | |||
17 | #include QMK_KEYBOARD_H | ||
18 | #include "version.h" | ||
19 | |||
20 | enum layer_names { | ||
21 | BASE, // default layer | ||
22 | FUNC, // functions keys, numbpad, and arrows | ||
23 | }; | ||
24 | |||
25 | enum custom_keycodes { | ||
26 | VRSN = SAFE_RANGE, | ||
27 | RGB_SLD | ||
28 | }; | ||
29 | |||
30 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
31 | /* Keymap 0: default layer | ||
32 | * | ||
33 | * ,--------------------------------------------------. ,--------------------------------------------------. | ||
34 | * | ` | 1 | 2 | 3 | 4 | 5 | 6 | | 7 | 8 | 9 | 0 | - | = | BkSp | | ||
35 | * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| | ||
36 | * | Tab | Q | W | E | R | T | { | | } | Y | U | I | O | P | \ | | ||
37 | * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| | ||
38 | * | TUX | A | S | D | F | G |------| |------| H | J | K | L | ; | '/TUX | | ||
39 | * |--------+------+------+------+------+------| ^ | | & |------+------+------+------+------+--------| | ||
40 | * | Shft/( | Z | X | C | V | B | | | | N | M | , | . | / | Shft/) | | ||
41 | * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' | ||
42 | * | Ctrl | Alt | Caps | MP1 | FUNC | | MR1 | MS1 | [ | ] | TFUNC | | ||
43 | * `----------------------------------' `----------------------------------' | ||
44 | * ,-------------. ,---------------. | ||
45 | * | | Prnt | | INS | HOME | | ||
46 | * ,------|------|------| |------+--------+------. | ||
47 | * | | | Vol+ | | PgUp | | | | ||
48 | * | Space|Backsp|------| |------| Enter | : | | ||
49 | * | |ace | Vol- | | PgDn | | | | ||
50 | * `--------------------' `----------------------' | ||
51 | * | ||
52 | * MR1: Record macro 1 Prnt: Print Screen | ||
53 | * MS1: Stop recording macro 1 INS: INSERT | ||
54 | * MP1: Play macro 1 TFUNC: Goto FUNC only while pressed | ||
55 | * FUNC: Set FUNC as default layer | ||
56 | * | ||
57 | * | ||
58 | */ | ||
59 | |||
60 | /* If it accepts an argument (i.e, is a function), it doesn't need KC_. */ | ||
61 | /* Otherwise, it needs KC_* */ | ||
62 | [BASE] = LAYOUT_ergodox( /* layer 0: default */ | ||
63 | /* Left hand */ | ||
64 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, | ||
65 | KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, LSFT(KC_LBRC), | ||
66 | MT(MOD_LGUI, KC_ESC), KC_A, KC_S, KC_D, KC_F, KC_G, | ||
67 | KC_LSPO, KC_Z, KC_X, KC_C, KC_V, KC_B, LSFT(KC_6), | ||
68 | KC_LCTL, KC_LALT, KC_CAPS, DM_PLY1, DF(1), | ||
69 | |||
70 | KC_NO, KC_PSCR, | ||
71 | KC_VOLU, | ||
72 | KC_SPC, KC_BSPC, KC_VOLD, | ||
73 | |||
74 | /* right hand */ | ||
75 | KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, | ||
76 | RSFT(KC_RBRC), KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS, | ||
77 | KC_H, KC_J, KC_K, KC_L, KC_SCLN, MT(MOD_RGUI, KC_QUOT), | ||
78 | RSFT(KC_7), KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSPC, | ||
79 | DM_REC1, DM_RSTP, KC_LBRC, KC_RBRC, MO(1), | ||
80 | |||
81 | KC_INS, KC_HOME, | ||
82 | KC_PGUP, | ||
83 | KC_PGDN, KC_ENT, RSFT(KC_SCLN)), | ||
84 | |||
85 | /* Keymap 1: function keys, numpad, and arrows | ||
86 | * | ||
87 | * ,--------------------------------------------------. ,--------------------------------------------------. | ||
88 | * | | F1 | F2 | F3 | F4 | F5 | F6 | | F7 | F8 | F9 | F10 | F11 | F12 | | | ||
89 | * |--------+------+------+------+------+-------------| |------+------+------+------+------+------+--------| | ||
90 | * | | | | UP | | | | | | / | 7 | 8 | 9 | - | \ | | ||
91 | * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| | ||
92 | * | | | LEFT | DOWN |RIGHT | |------| |------| * | 4 | 5 | 6 | + | | | ||
93 | * |--------+------+------+------+------+------| | | |------+------+------+------+------+--------| | ||
94 | * | | | | | | | | | | % | 1 | 2 | 3 | , | Shft/) | | ||
95 | * `--------+------+------+------+------+-------------' `-------------+------+------+------+------+--------' | ||
96 | * | Ctrl | Alt | Caps | | MAIN | | 0 | . | [ | ] | | | ||
97 | * `----------------------------------' `----------------------------------' | ||
98 | * ,-------------. ,---------------. | ||
99 | * | | Prnt | | Ins | Home | | ||
100 | * ,------|------|------| |------+--------+------. | ||
101 | * | | | Vol+ | | PgUp | | | | ||
102 | * | Space|Backsp|------| |------| Enter | Equal| | ||
103 | * | |ace | Vol- | | PgDn | | | | ||
104 | * `--------------------' `----------------------' | ||
105 | */ | ||
106 | |||
107 | [FUNC] = LAYOUT_ergodox( /* layer 1: func */ | ||
108 | /* left hand */ | ||
109 | KC_NO, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, | ||
110 | KC_NO, KC_NO, KC_NO, KC_UP, KC_NO, KC_NO, KC_NO, | ||
111 | KC_NO, KC_NO, KC_LEFT, KC_DOWN, KC_RGHT, KC_NO, | ||
112 | KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, | ||
113 | KC_LCTL, KC_LALT, KC_CAPS, KC_NO, DF(0), | ||
114 | |||
115 | KC_NO, KC_PSCR, | ||
116 | KC_VOLU, | ||
117 | KC_SPC, KC_BSPC, KC_VOLD, | ||
118 | |||
119 | /* right hand */ | ||
120 | KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NO, | ||
121 | KC_NO, KC_PSLS, KC_P7, KC_P8, KC_P9, KC_PMNS, KC_BSLS, | ||
122 | KC_PAST, KC_P4, KC_P5, KC_P6, KC_PPLS, KC_NO, | ||
123 | KC_NO, LSFT(KC_5), KC_P1, KC_P2, KC_P3, KC_PCMM, KC_RSPC, | ||
124 | KC_P0, KC_PDOT, KC_LBRC, KC_RBRC, KC_NO, | ||
125 | |||
126 | KC_INS, KC_HOME, | ||
127 | KC_PGUP, | ||
128 | KC_PGDN, KC_ENT, KC_PEQL) | ||
129 | }; | ||
130 | |||
131 | bool process_record_user(uint16_t keycode, keyrecord_t *record) { | ||
132 | switch (keycode) { | ||
133 | // dynamically generate these. | ||
134 | case VRSN: | ||
135 | if (record->event.pressed) { | ||
136 | SEND_STRING (QMK_KEYBOARD "/" QMK_KEYMAP " @ " QMK_VERSION); | ||
137 | } | ||
138 | return false; | ||
139 | break; | ||
140 | case RGB_SLD: | ||
141 | if (record->event.pressed) { | ||
142 | #ifdef RGBLIGHT_ENABLE | ||
143 | rgblight_mode(1); | ||
144 | #endif | ||
145 | } | ||
146 | return false; | ||
147 | break; | ||
148 | } | ||
149 | return true; | ||
150 | } | ||
151 | |||
152 | |||
153 | // Runs constantly in the background, in a loop. | ||
154 | void matrix_scan_user(void) { | ||
155 | |||
156 | uint8_t layer = get_highest_layer(layer_state); | ||
157 | |||
158 | ergodox_right_led_1_off(); | ||
159 | ergodox_right_led_2_off(); | ||
160 | ergodox_right_led_3_off(); | ||
161 | switch (layer) { | ||
162 | // TODO: Make this relevant to the ErgoDox EZ. | ||
163 | case 1: | ||
164 | ergodox_right_led_1_on(); | ||
165 | break; | ||
166 | case 2: | ||
167 | ergodox_right_led_2_on(); | ||
168 | break; | ||
169 | default: | ||
170 | // none | ||
171 | break; | ||
172 | } | ||
173 | }; | ||
diff --git a/keyboards/hotdox/keymaps/bliss/readme.md b/keyboards/hotdox/keymaps/bliss/readme.md new file mode 100644 index 000000000..a31ee2826 --- /dev/null +++ b/keyboards/hotdox/keymaps/bliss/readme.md | |||
@@ -0,0 +1,8 @@ | |||
1 | # Bliss for Hotdox | ||
2 | |||
3 | This keymap for the ergodox hotdox is a take on a development setup I quite | ||
4 | enjoy. Developers constantly use brackets and they should therefore be | ||
5 | accessible instead of hidden away behind a shift key. Also this setup aims to minimize hand travel with a layer containing a numpad as well as arrows. Finally, | ||
6 | this setup incorporates a dynamic macro recorder for an easy, software agnostic way to program macros. | ||
7 | |||
8 | All keybinding diagrams can be read in the `keymap.c` file. It is quite well documented. | ||
diff --git a/keyboards/hotdox/keymaps/bliss/rules.mk b/keyboards/hotdox/keymaps/bliss/rules.mk new file mode 100644 index 000000000..ca616d75e --- /dev/null +++ b/keyboards/hotdox/keymaps/bliss/rules.mk | |||
@@ -0,0 +1,5 @@ | |||
1 | VIA_ENABLE = yes | ||
2 | LTO_ENABLE = yes | ||
3 | |||
4 | EXTRAKEY_ENABLE = yes | ||
5 | DYNAMIC_MACRO_ENABLE = yes | ||