Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/alfrdmalr/keymap update #8174

Merged
merged 44 commits into from
Mar 3, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
5d01cdf
WIP do not merge
alfrdmalr Dec 29, 2019
a8af5bd
first pass at custom preonic layout
alfrdmalr Jan 7, 2020
99ec959
add auto shift and reset via leader key
alfrdmalr Jan 7, 2020
a03b69b
revert WIP changes
alfrdmalr Jan 7, 2020
9a929ca
Update readme
alfrdmalr Jan 12, 2020
01dc84d
update copyright notice
alfrdmalr Jan 12, 2020
795e328
formatting changes
alfrdmalr Jan 13, 2020
e4558f7
fix: use MO instead of process_record_user
alfrdmalr Jan 13, 2020
48b1828
added backslash and moved grave position
alfrdmalr Jan 13, 2020
0b8d7f3
remove extraneous 'j' characer in NUMPAD template
alfrdmalr Jan 13, 2020
3ef6a5a
update template formatting
alfrdmalr Jan 13, 2020
d53a51d
remove process_record_user
alfrdmalr Jan 20, 2020
d58470a
swap "!" with "@"
alfrdmalr Jan 20, 2020
9788639
fix readme formatting
alfrdmalr Jan 20, 2020
2aac6cb
update readme layout image
alfrdmalr Jan 20, 2020
c75f0a3
restore settings layer
alfrdmalr Jan 21, 2020
12eb00b
add windows minimize sequence
alfrdmalr Jan 23, 2020
c723fb9
Merge branch 'master' into feature/userspace-alfrdmalr
alfrdmalr Jan 23, 2020
de7c5ad
fix: switch to correct seq function for three-key sequence
alfrdmalr Jan 23, 2020
d2e50e3
fix: missing semicolon
alfrdmalr Jan 23, 2020
2f0fbb1
refactor: move keymap to userspace and generic 5x12 layout
alfrdmalr Jan 27, 2020
bc10b60
add numlock to numpad layer
alfrdmalr Jan 27, 2020
acd1002
add readme
alfrdmalr Jan 27, 2020
e25cde7
update readme formatting
alfrdmalr Jan 28, 2020
33d160e
Merge branch 'master' into feature/userspace-alfrdmalr
alfrdmalr Jan 28, 2020
b98c72e
remove unused wrappers from layout keymap
alfrdmalr Jan 28, 2020
0a9eacc
update readme title to reflect new location
alfrdmalr Jan 28, 2020
cc035dd
remove alfrdmalr directory from preonic/keymaps
alfrdmalr Jan 28, 2020
d1b7855
add ortho 4x12 support
alfrdmalr Jan 31, 2020
dca932c
add 'trilayer' settings and update keymap
alfrdmalr Feb 4, 2020
13895d4
update SYMBOLS layer to SYMBOL
alfrdmalr Feb 4, 2020
5b48ab7
remove minimize sequence
alfrdmalr Feb 6, 2020
757a627
clean up user config
alfrdmalr Feb 6, 2020
cb9d629
Merge pull request #1 from alfrdmalr/feature/userspace-alfrdmalr
alfrdmalr Feb 6, 2020
95df5f4
Merge branch 'feature/userspace-alfrdmalr' into feature/alfrdmalr/tri…
alfrdmalr Feb 6, 2020
457ff88
add brightness controls
alfrdmalr Feb 7, 2020
d14bc31
Merge branch 'master' of https://github.com/alfrdmalr/qmk_firmware
alfrdmalr Feb 13, 2020
3f9c300
Merge branch 'master' into feature/layouts/community/ortho4x12/alfrdmalr
alfrdmalr Feb 13, 2020
c487df7
Merge branch 'master' into feature/alfrdmalr/trilayer-settings
alfrdmalr Feb 13, 2020
a050a33
Merge pull request #2 from alfrdmalr/feature/layouts/community/ortho4…
alfrdmalr Feb 13, 2020
5948fce
Merge branch 'master' into feature/alfrdmalr/trilayer-settings
alfrdmalr Feb 13, 2020
1e66ac6
Merge pull request #3 from alfrdmalr/feature/alfrdmalr/trilayer-settings
alfrdmalr Feb 13, 2020
2f86688
update settings ascii
alfrdmalr Feb 13, 2020
f68b26f
moved some symbols around to make vim/linux smoother
alfrdmalr Feb 13, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add auto shift and reset via leader key
  • Loading branch information
alfrdmalr committed Jan 7, 2020
commit 99ec959eff7cabf62e6030cee8b466ad19c5f218
3 changes: 3 additions & 0 deletions keyboards/preonic/keymaps/alfrdmalr/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,6 @@

/* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
//#define MIDI_TONE_KEYCODE_OCTAVES 2

#define LEADER_TIMEOUT 400
#define LEADER_PER_KEY_TIMING
97 changes: 32 additions & 65 deletions keyboards/preonic/keymaps/alfrdmalr/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ enum preonic_keycodes {
SETTINGS
};

#define NUMSPACE LT(_NUMPAD, KC_SPC)
#define CTRLSHFT C(KC_LSFT)

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {

/* Qwerty
Expand All @@ -48,17 +51,17 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | NAV | A | S | D | F | G | H | J | K | L | ; | " |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | SHIFT| Z | X | C | V | B | N | M | , | . | / |SHIFT |
* | SHFT | Z | X | C | V | B | N | M | , | . | / | SHFT |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | CTRL | HYPR | LGUI | LALT | SYMB | SPACE/NUM | SYMB | RALT | num? |mu tog| CTRL |
* | CTRL | C/S | LGUI | LALT | SYMB | SPACE/NUM | SYMB | RALT | SETT |mu tog| LEAD |
* `-----------------------------------------------------------------------------------'
*/
[_QWERTY] = LAYOUT_preonic_grid( \
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, \
NAVIGATION, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, \
KC_LCTL, NUMPAD, KC_LGUI, KC_LALT, SYMBOLS, LT(_NUMPAD, KC_SPC), LT(_NUMPAD, KC_SPC), SYMBOLS, KC_RALT, SETTINGS, MU_TOG, KC_RCTRL \
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, \
NAVIGATION, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, \
KC_LCTL, CTRLSHFT, KC_LGUI, KC_LALT, SYMBOLS, NUMSPACE, NUMSPACE, SYMBOLS, KC_RALT, SETTINGS, MU_TOG, KC_LEAD \
),

/* SYMBOLS
Expand All @@ -67,9 +70,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | Tab | # | $ | { | } | | | ^ | * | | | ~ | Del |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | Esc | < | > | ( | ) | | | - | + | & | ` |ENTER |
* | Esc | < | > | ( | ) | | | - | + | & | ` | ENTR |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | Shift| @ | ! | [ | ] | | | _ | = | % | / |SHIFT |
* | Shift| @ | ! | [ | ] | | | _ | = | % | / | SHFT |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS |
* `-----------------------------------------------------------------------------------'
Expand All @@ -86,26 +89,24 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* ,-----------------------------------------------------------------------------------.
* | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | TRNS | | | SPC | F5 | | | HOME | END | TAB | | Del |
* | TRNS | | | SPC | F5 | | INS | HOME | END | TAB | | Del |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | NAV | SHIFT| CTRl | ALT | GUI | | LEFT | DOWN | UP | RIGHT| | ENTER|
* | NAV | SHIFT| CTRl | ALT | GUI | | LEFT | DOWN | UP | RIGHT| | ENTR |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | SHIFT| | CUT | COPY | PASTE| | SPC | PGDO | PGUP | | | SHIFT|
* | SHFT | UNDO | CUT | COPY | PASTE| | SPC | PGDO | PGUP | | | SHFT |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | TRNS | TRNS | TRNS | TRNS | TRNS | ESC | TRNS | TRNS | TRNS | TRNS | TRNS |
* `-----------------------------------------------------------------------------------'
*/
[_NAVIGATION] = LAYOUT_preonic_grid( \
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
KC_TRNS, KC_NO, KC_NO, KC_SPC, KC_F5, KC_NO, KC_NO, KC_HOME, KC_END, KC_TAB, KC_NO, KC_DEL, \
KC_TRNS, KC_LSFT, KC_LCTRL, KC_LALT, KC_LGUI, KC_NO, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_NO, KC_ENT, \
KC_TRNS, KC_UNDO, KC_CUT, KC_COPY, KC_PASTE, KC_NO, KC_SPC, KC_PGDN, KC_PGUP, KC_NO, KC_NO, KC_TRNS, \
KC_TRNS, KC_NO, KC_NO, KC_SPC, KC_F5, KC_NO, KC_INS, KC_HOME, KC_END, KC_TAB, KC_NO, KC_DEL, \
KC_TRNS, KC_LSFT, KC_LCTRL, KC_LALT, KC_LGUI, KC_NO, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_NO, KC_ENT, \
KC_TRNS, C(KC_Z), C(KC_X), C(KC_C), C(KC_V), KC_NO, KC_SPC, KC_PGDN, KC_PGUP, KC_NO, KC_NO, KC_TRNS, \
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_ESC, KC_ESC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS \
),

/* NUMPAD
* By not having r5/c11 be transparent, we can soft lock the layer by using that key from the base
* layer to get here. can always untoggle with one of the other keys (space, r5/c2)
* ,-----------------------------------------------------------------------------------.
* | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
* |------+------+------+------+------+------+------+------+------+------+------+------|
Expand All @@ -115,7 +116,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | TRNS | F1 | F2 | F3 | F4 | ALT | CAPS | 1 | 2 | 3 | / | TRNS |
* |------+------+------+------+------+------+------+------+------+------+------+------|
*j | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS | 0 | , | . | * | TRNS |
*j | TRNS | TRNS | TRNS | TRNS | TRNS | TRNS | 0 | , | . | * | TRNS |
* `-----------------------------------------------------------------------------------'
*/
[_NUMPAD] = LAYOUT_preonic_grid( \
Expand All @@ -130,20 +131,20 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* ,-----------------------------------------------------------------------------------.
* | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | Reset| | | | | | | | | | Del |
* | | | | | | | | | | | | Del |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | | |Aud on|AudOff|AGnorm|AGswap|Qwerty|Colemk|Dvorak| | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | |Voice-|Voice+|Mus on|MusOff|MidiOn|MidOff| | | | | |
* | ASTG |Voice-|Voice+|Mus on|MusOff|MidiOn|MidOff| | | | | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_SETTINGS] = LAYOUT_preonic_grid( \
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, \
_______, RESET, DEBUG, _______, _______, _______, _______, TERM_ON, TERM_OFF,_______, _______, KC_DEL, \
_______, _______, DEBUG, _______, _______, _______, _______, TERM_ON, TERM_OFF,_______, _______, KC_DEL, \
_______, _______, MU_MOD, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, _______, _______, _______, _______, \
_______, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, _______, _______, _______, _______, _______, \
KC_ASTG, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
)
};
Expand Down Expand Up @@ -228,49 +229,7 @@ uint16_t muse_counter = 0;
uint8_t muse_offset = 70;
uint16_t muse_tempo = 50;

// void encoder_update_user(uint8_t index, bool clockwise) {
// if (muse_mode) {
// if (IS_LAYER_ON(_RAISE)) {
// if (clockwise) {
// muse_offset++;
// } else {
// muse_offset--;
// }
// } else {
// if (clockwise) {
// muse_tempo+=1;
// } else {
// muse_tempo-=1;
// }
// }
// } else {
// if (clockwise) {
// register_code(KC_PGDN);
// unregister_code(KC_PGDN);
// } else {
// register_code(KC_PGUP);
// unregister_code(KC_PGUP);
// }
// }
// }

void dip_switch_update_user(uint8_t index, bool active) {
switch (index) {
case 0:
// if (active) {
// layer_on(_ADJUST);
// } else {
// layer_off(_ADJUST);
// }
break;
case 1:
if (active) {
muse_mode = true;
} else {
muse_mode = false;
}
}
}
LEADER_EXTERNS();

void matrix_scan_user(void) {
#ifdef AUDIO_ENABLE
Expand All @@ -291,6 +250,14 @@ void matrix_scan_user(void) {
}
}
#endif

LEADER_DICTIONARY() {
leading = false;
SEQ_FIVE_KEYS(KC_R, KC_E, KC_S, KC_E, KC_T) {
reset_keyboard();
}
leader_end();
}
}

bool music_mask_user(uint16_t keycode) {
Expand Down
2 changes: 2 additions & 0 deletions keyboards/preonic/keymaps/alfrdmalr/rules.mk
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
SRC += muse.c
AUTO_SHIFT_ENABLE = yes
LEADER_ENABLE = yes