Skip to content

Commit

Permalink
AMJKeyboard AMJ84 Develop Touch-Up (qmk#21645)
Browse files Browse the repository at this point in the history
* [style] refactor default keymap, phase 1

- grid-align keycodes
- use QMK-native keycode aliases
- update box drawings

* [refactor] refactor default keymap, phase 2

- move position [5, 8] to the top row
  - update keycode grid alignment

* [refactor] refactor default keymap, phase 3

- remove matrix position [5, 9]
  • Loading branch information
noroadsleft authored and akeep committed Oct 2, 2023
1 parent e785969 commit 2e168ff
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 42 deletions.
7 changes: 3 additions & 4 deletions keyboards/amjkeyboard/amj84/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
{"matrix": [0, 11], "x": 11, "y": 0},
{"matrix": [0, 12], "x": 12, "y": 0},
{"matrix": [0, 13], "x": 13, "y": 0},
{"matrix": [5, 8], "x": 14, "y": 0},
{"matrix": [0, 14], "x": 15, "y": 0},

{"matrix": [1, 0], "x": 0, "y": 1},
Expand Down Expand Up @@ -110,10 +111,8 @@
{"matrix": [5, 1], "x": 1.25, "y": 5, "w": 1.25},
{"matrix": [5, 2], "x": 2.5, "y": 5, "w": 1.25},
{"matrix": [5, 5], "x": 3.75, "y": 5, "w": 6.25},
{"matrix": [5, 8], "x": 14, "y": 0},
{"matrix": [5, 9], "x": 10, "y": 5},
{"matrix": [5, 10], "x": 11, "y": 5},
{"matrix": [5, 11], "x": 12, "y": 5},
{"matrix": [5, 10], "x": 10, "y": 5, "w": 1.5},
{"matrix": [5, 11], "x": 11.5, "y": 5, "w": 1.5},
{"matrix": [5, 12], "x": 13, "y": 5},
{"matrix": [5, 13], "x": 14, "y": 5},
{"matrix": [5, 14], "x": 15, "y": 5}
Expand Down
80 changes: 42 additions & 38 deletions keyboards/amjkeyboard/amj84/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,51 +3,55 @@

#include QMK_KEYBOARD_H



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

/* Base */
/* Keymap 0: Default Layer
* ,----------------------------------------------------------------.
* |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Home |Del|
* |------------------------------------------------------------|---|
* |` | 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backsp |PgU|
* |------------------------------------------------------------|---|
* |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \ |PgD|
* |------------------------------------------------------------|---|
* |Caps | A| S| D| F| G| H| J| K| L| ;| '|Return |Ins|
* |------------------------------------------------------------|---|
* |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift |Up |Fn0|
* |------------------------------------------------------------|---|
* |Ctrl|Win |Alt | Space |END|Alt |Ctrl|Left |Down|Rig|
* `----------------------------------------------------------------'
* ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┐
* Esc│F1 │F2 │F3 │F4 │F5 │F6 │F7 │F8 │F9 │F10F11F12│Hm │End│Del
* ├───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┴───┼───┤
* │ ` │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ - │ = │Bkspc │PgU
* ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┼───┤
* Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │ \ │PgD
* ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬────┼───┤
* Caps │ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │ │Ent │Ins
* ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┴┬───┼───┤
* │Sft │ │ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │Shift Up │Fn │
* ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┤
* Ctrl│GUI │Alt │Space Alt Ctrl │Lft│Dwn│Rig
* └────┴────┴────┴────────────────────────┴─────┴─────┴───┴───┴───┘
*/
[0] = LAYOUT_all(
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_HOME,KC_DEL,
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS,KC_EQL, KC_BSPC,KC_PGUP,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC,KC_RBRC,KC_BSLS,KC_PGDN,
KC_CAPS,KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT,KC_NO, KC_ENT, KC_INS,
KC_LSFT,KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM,KC_DOT, KC_SLSH,KC_RSFT,KC_UP, MO(1),
KC_LCTL,KC_LGUI,KC_LALT, KC_SPC, KC_END, KC_NO, KC_RALT,KC_RCTL,KC_LEFT,KC_DOWN,KC_RIGHT),
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_HOME, KC_END, KC_DEL,
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_PGUP,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_PGDN,
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NO, KC_ENT, KC_INS,
KC_LSFT, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, MO(1),
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT
),

/* Keymap 1: Fn Layer
* ,-----------------------------------------------------------.
* | `| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delete |
* |-----------------------------------------------------------|
* | | |Up | | | |Cal| |Ins| |Psc|Slk|Pau| |
* |-----------------------------------------------------------|
* | |Lef|Dow|Rig| | | | | | |Hom|PgU| |
* |-----------------------------------------------------------|
* | | |App| | | |VoD|VoU|Mut|End|PgD| | |
* |-----------------------------------------------------------|
* | | | | | | | | |
* `-----------------------------------------------------------'
* ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┐
* │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
* ├───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┼───┴───┼───┤
* │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
* ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┼───┤
* │ │ │Up │ │ │ │Cal│ │Ins│ │PSc│SLk│Pau│ │ │
* ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬────┼───┤
* │BBrtg │Lft│Dwn│Rgh│ │ │ │ │ │ │Hm │PgU│ │ │ │
* ├────┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┴┬───┼───┤
* │BStp│ │ │App│ │ │ │Vl-│Vl+│Mut│End│PgD│ │ │ │
* ├────┼───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┴┬──┴──┬───┼───┼───┤
* │Slp │ │ │ │ │ │ │ │ │
* └────┴────┴────┴────────────────────────┴─────┴─────┴───┴───┴───┘
*/
[1] = LAYOUT_all(
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_UP, KC_TRNS,KC_TRNS,KC_TRNS,KC_CALC,KC_TRNS,KC_INS, KC_TRNS,KC_PSCR,KC_SCRL,KC_PAUS,KC_TRNS,KC_TRNS,
BL_BRTG,KC_LEFT,KC_DOWN,KC_RGHT,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_HOME,KC_PGUP,KC_TRNS,KC_TRNS,KC_TRNS,
BL_STEP,KC_NO, KC_TRNS,KC_APP, KC_TRNS,KC_TRNS,KC_TRNS,KC_VOLD,KC_VOLU,KC_MUTE,KC_END, KC_PGDN,KC_TRNS,KC_TRNS,KC_TRNS,
KC_SLEP,KC_TRNS,KC_TRNS, KC_TRNS, KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS)
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, KC_UP, _______, _______, _______, KC_CALC, _______, KC_INS, _______, KC_PSCR, KC_SCRL, KC_PAUS, _______, _______,
BL_BRTG, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_HOME, KC_PGUP, _______, _______, _______,
BL_STEP, KC_NO, _______, KC_APP, _______, _______, _______, KC_VOLD, KC_VOLU, KC_MUTE, KC_END, KC_PGDN, _______, _______, _______,
KC_SLEP, _______, _______, _______, _______, _______, _______, _______, _______
)

};

0 comments on commit 2e168ff

Please sign in to comment.