aboutsummaryrefslogtreecommitdiff
path: root/keyboards
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards')
-rw-r--r--keyboards/levinson/keymaps/mmacdougall/README.md21
-rw-r--r--keyboards/levinson/keymaps/mmacdougall/keymap/config.h20
-rw-r--r--keyboards/levinson/keymaps/mmacdougall/keymap/keymap.c201
-rw-r--r--keyboards/levinson/keymaps/mmacdougall/keymap/rules.mk2
4 files changed, 244 insertions, 0 deletions
diff --git a/keyboards/levinson/keymaps/mmacdougall/README.md b/keyboards/levinson/keymaps/mmacdougall/README.md
new file mode 100644
index 000000000..bae8c8a4b
--- /dev/null
+++ b/keyboards/levinson/keymaps/mmacdougall/README.md
@@ -0,0 +1,21 @@
1mmacdougall's Levinson Layout
2============================
3
4Similar to default layout, however RGB & backlight controls are mapped to adjust layer
5
6## Layouts
7
8### Adjust (Lower + Raise)
9
10```
11/* Adjust (Lower + Raise)
12 ,-----------------------------------------------------------------------------------.
13 | | Reset| | | | | | | | | | Del |
14 |------+------+------+------+------+-------------+------+------+------+------+------|
15 | | | |Aud on|Audoff|AGnorm|AGswap|Qwerty|Colemk|Dvorak| | |
16 |------+------+------+------+------+------|------+------+------+------+------+------|
17 |B Step|RGB Tg|RGB Md|Hue Up|Hue Dn|Sat Up|Sat Dn|Val Up|Val Dn| | | |
18 |------+------+------+------+------+------+------+------+------+------+------+------|
19 | | | | | | | | | | | |
20 `-----------------------------------------------------------------------------------'
21```
diff --git a/keyboards/levinson/keymaps/mmacdougall/keymap/config.h b/keyboards/levinson/keymaps/mmacdougall/keymap/config.h
new file mode 100644
index 000000000..63dd5bc88
--- /dev/null
+++ b/keyboards/levinson/keymaps/mmacdougall/keymap/config.h
@@ -0,0 +1,20 @@
1#pragma once
2
3/* Use I2C or Serial, not both */
4
5#define USE_SERIAL
6// #define USE_I2C
7
8/* Select hand configuration */
9
10#define MASTER_LEFT
11// #define MASTER_RIGHT
12// #define EE_HANDS
13
14
15#undef RGBLED_NUM
16#define RGBLIGHT_ANIMATIONS
17#define RGBLED_NUM 12
18#define RGBLIGHT_HUE_STEP 8
19#define RGBLIGHT_SAT_STEP 8
20#define RGBLIGHT_VAL_STEP 8
diff --git a/keyboards/levinson/keymaps/mmacdougall/keymap/keymap.c b/keyboards/levinson/keymaps/mmacdougall/keymap/keymap.c
new file mode 100644
index 000000000..dec47a761
--- /dev/null
+++ b/keyboards/levinson/keymaps/mmacdougall/keymap/keymap.c
@@ -0,0 +1,201 @@
1#include QMK_KEYBOARD_H
2
3extern keymap_config_t keymap_config;
4
5// Each layer gets a name for readability, which is then used in the keymap matrix below.
6// The underscores don't mean anything - you can have a layer called STUFF or any other name.
7// Layer names don't all need to be of the same length, obviously, and you can also skip them
8// entirely and just use numbers.
9#define _QWERTY 0
10#define _COLEMAK 1
11#define _DVORAK 2
12#define _LOWER 3
13#define _RAISE 4
14#define _ADJUST 16
15
16enum custom_keycodes {
17 QWERTY = SAFE_RANGE,
18 COLEMAK,
19 DVORAK,
20 LOWER,
21 RAISE,
22 ADJUST,
23};
24
25// Fillers to make layering more clear
26#define _______ KC_TRNS
27#define XXXXXXX KC_NO
28
29const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
30
31/* Qwerty
32 * ,-----------------------------------------------------------------------------------.
33 * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp |
34 * |------+------+------+------+------+-------------+------+------+------+------+------|
35 * | Esc | A | S | D | F | G | H | J | K | L | ; | " |
36 * |------+------+------+------+------+------|------+------+------+------+------+------|
37 * | Shift| Z | X | C | V | B | N | M | , | . | / |Enter |
38 * |------+------+------+------+------+------+------+------+------+------+------+------|
39 * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
40 * `-----------------------------------------------------------------------------------'
41 */
42[_QWERTY] = LAYOUT_ortho_4x12( \
43 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
44 KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
45 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
46 ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
47),
48
49/* Colemak
50 * ,-----------------------------------------------------------------------------------.
51 * | Tab | Q | W | F | P | G | J | L | U | Y | ; | Bksp |
52 * |------+------+------+------+------+-------------+------+------+------+------+------|
53 * | Esc | A | R | S | T | D | H | N | E | I | O | " |
54 * |------+------+------+------+------+------|------+------+------+------+------+------|
55 * | Shift| Z | X | C | V | B | K | M | , | . | / |Enter |
56 * |------+------+------+------+------+------+------+------+------+------+------+------|
57 * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
58 * `-----------------------------------------------------------------------------------'
59 */
60[_COLEMAK] = LAYOUT_ortho_4x12( \
61 KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC, \
62 KC_ESC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT, \
63 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , \
64 ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
65),
66
67/* Dvorak
68 * ,-----------------------------------------------------------------------------------.
69 * | Tab | " | , | . | P | Y | F | G | C | R | L | Bksp |
70 * |------+------+------+------+------+-------------+------+------+------+------+------|
71 * | Esc | A | O | E | U | I | D | H | T | N | S | / |
72 * |------+------+------+------+------+------|------+------+------+------+------+------|
73 * | Shift| ; | Q | J | K | X | B | M | W | V | Z |Enter |
74 * |------+------+------+------+------+------+------+------+------+------+------+------|
75 * |Adjust| Ctrl | Alt | GUI |Lower |Space |Space |Raise | Left | Down | Up |Right |
76 * `-----------------------------------------------------------------------------------'
77 */
78[_DVORAK] = LAYOUT_ortho_4x12( \
79 KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_BSPC, \
80 KC_ESC, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH, \
81 KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_ENT , \
82 ADJUST, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
83),
84
85/* Lower
86 * ,-----------------------------------------------------------------------------------.
87 * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
88 * |------+------+------+------+------+-------------+------+------+------+------+------|
89 * | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | | \ | | |
90 * |------+------+------+------+------+------|------+------+------+------+------+------|
91 * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | | |Enter |
92 * |------+------+------+------+------+------+------+------+------+------+------+------|
93 * | | | | | | | | Next | Vol- | Vol+ | Play |
94 * `-----------------------------------------------------------------------------------'
95 */
96[_LOWER] = LAYOUT_ortho_4x12( \
97 KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, \
98 KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, \
99 _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS),_______, _______, _______, \
100 _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
101),
102
103/* Raise
104 * ,-----------------------------------------------------------------------------------.
105 * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
106 * |------+------+------+------+------+-------------+------+------+------+------+------|
107 * | Del | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ |
108 * |------+------+------+------+------+------|------+------+------+------+------+------|
109 * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / | | |Enter |
110 * |------+------+------+------+------+------+------+------+------+------+------+------|
111 * | | | | | | | | Next | Vol- | Vol+ | Play |
112 * `-----------------------------------------------------------------------------------'
113 */
114[_RAISE] = LAYOUT_ortho_4x12( \
115 KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
116 KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, \
117 _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, _______, _______, _______, \
118 _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
119),
120
121/* Adjust (Lower + Raise)
122 * ,-----------------------------------------------------------------------------------.
123 * | | Reset| | | | | | | | | | Del |
124 * |------+------+------+------+------+-------------+------+------+------+------+------|
125 * | | | |Aud on|Audoff|AGnorm|AGswap|Qwerty|Colemk|Dvorak| | |
126 * |------+------+------+------+------+------|------+------+------+------+------+------|
127 * |B Step|RGB Tg|RGB Md|Hue Up|Hue Dn|Sat Up|Sat Dn|Val Up|Val Dn| | | |
128 * |------+------+------+------+------+------+------+------+------+------+------+------|
129 * | | | | | | | | | | | |
130 * `-----------------------------------------------------------------------------------'
131 */
132[_ADJUST] = LAYOUT_ortho_4x12( \
133 _______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL, \
134 _______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, COLEMAK, DVORAK, _______, _______, \
135 BL_STEP, RGB_TOG, RGB_MOD, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, RGB_VAD, RGB_VAI, _______, _______, _______, \
136 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
137)
138
139
140};
141
142bool process_record_user(uint16_t keycode, keyrecord_t *record) {
143 switch (keycode) {
144 case QWERTY:
145 if (record->event.pressed) {
146 #ifdef AUDIO_ENABLE
147 PLAY_SONG(tone_qwerty);
148 #endif
149 set_single_persistent_default_layer(_QWERTY);
150 }
151 return false;
152 break;
153 case COLEMAK:
154 if (record->event.pressed) {
155 #ifdef AUDIO_ENABLE
156 PLAY_SONG(tone_colemak);
157 #endif
158 set_single_persistent_default_layer(_COLEMAK);
159 }
160 return false;
161 break;
162 case DVORAK:
163 if (record->event.pressed) {
164 #ifdef AUDIO_ENABLE
165 PLAY_SONG(tone_dvorak);
166 #endif
167 set_single_persistent_default_layer(_DVORAK);
168 }
169 return false;
170 break;
171 case LOWER:
172 if (record->event.pressed) {
173 layer_on(_LOWER);
174 update_tri_layer(_LOWER, _RAISE, _ADJUST);
175 } else {
176 layer_off(_LOWER);
177 update_tri_layer(_LOWER, _RAISE, _ADJUST);
178 }
179 return false;
180 break;
181 case RAISE:
182 if (record->event.pressed) {
183 layer_on(_RAISE);
184 update_tri_layer(_LOWER, _RAISE, _ADJUST);
185 } else {
186 layer_off(_RAISE);
187 update_tri_layer(_LOWER, _RAISE, _ADJUST);
188 }
189 return false;
190 break;
191 case ADJUST:
192 if (record->event.pressed) {
193 layer_on(_ADJUST);
194 } else {
195 layer_off(_ADJUST);
196 }
197 return false;
198 break;
199 }
200 return true;
201}
diff --git a/keyboards/levinson/keymaps/mmacdougall/keymap/rules.mk b/keyboards/levinson/keymaps/mmacdougall/keymap/rules.mk
new file mode 100644
index 000000000..d7463419b
--- /dev/null
+++ b/keyboards/levinson/keymaps/mmacdougall/keymap/rules.mk
@@ -0,0 +1,2 @@
1RGBLIGHT_ENABLE = yes
2BACKLIGHT_ENABLE = yes