]> git.friedersdorff.com Git - max/tmk_keyboard.git/blob - keyboard/gh60/keymap_hasu.c
ibmpc: Add ibmpc_host_clear_isr
[max/tmk_keyboard.git] / keyboard / gh60 / keymap_hasu.c
1 #include "keymap_common.h"
2
3 /*
4  * Hasu
5  */
6 const uint8_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
7     /* Keymap 0: Default Layer
8      * ,-----------------------------------------------------------.
9      * |Esc|  1|  2|  3|  4|  5|  6|  7|  8|  9|  0|  -|  =|Backsp |
10      * |-----------------------------------------------------------|
11      * |Tab  |  Q|  W|  E|  R|  T|  Y|  U|  I|  O|  P|  [|  ]|    \|
12      * |-----------------------------------------------------------|
13      * |Caps  |  A|  S|  D|  F|  G|  H|  J|  K|  L|Fn3|  '|Return  |
14      * |-----------------------------------------------------------|
15      * |Shift   |  Z|  X|  C|  V|  B|  N|  M|  ,|  .|Fn2|Shift     |
16      * |-----------------------------------------------------------|
17      * |Ctrl|Gui |Alt |      Space             |Alt |Fn4 |Fn4 |Fn1 |
18      * `-----------------------------------------------------------'
19      */
20     KEYMAP_ANSI(
21         ESC, 1,   2,   3,   4,   5,   6,   7,   8,   9,   0,   MINS,EQL, BSPC, \
22         TAB, Q,   W,   E,   R,   T,   Y,   U,   I,   O,   P,   LBRC,RBRC,BSLS, \
23         LCTL,A,   S,   D,   F,   G,   H,   J,   K,   L,   FN2, QUOT,     ENT,  \
24         LSFT,Z,   X,   C,   V,   B,   N,   M,   COMM,DOT, FN1,           FN9,  \
25         LCTL,LGUI,LALT,          SPC,                     RALT,FN3, FN3, FN0),
26     /* Keymap 1: colemak */
27     KEYMAP_ANSI(
28         GRV, 1,   2,   3,   4,   5,   6,   7,   8,   9,   0,   MINS,EQL, BSPC, \
29         TAB, Q,   W,   F,   P,   G,   J,   L,   U,   Y,   SCLN,LBRC,RBRC,BSLS, \
30         BSPC,A,   R,   S,   T,   D,   H,   N,   E,   I,   O,   QUOT,     ENT,  \
31         LSFT,Z,   X,   C,   V,   B,   K,   M,   COMM,DOT, SLSH,          RSFT, \
32         LCTL,LGUI,LALT,          SPC,                     RALT,RGUI,APP, FN0),
33     /* Keymap 2: dvorak */
34     KEYMAP_ANSI(
35         GRV, 1,   2,   3,   4,   5,   6,   7,   8,   9,   0,   LBRC,RBRC,BSPC, \
36         TAB, QUOT,COMM,DOT, P,   Y,   F,   G,   C,   R,   L,   SLSH,EQL, BSLS, \
37         CAPS,A,   O,   E,   U,   I,   D,   H,   T,   N,   S,   MINS,     ENT,  \
38         LSFT,SCLN,Q,   J,   K,   X,   B,   M,   W,   V,   Z,             RSFT, \
39         LCTL,LGUI,LALT,          SPC,                     RALT,RGUI,APP, FN0),
40     /* Keymap 3: workman */
41     KEYMAP_ANSI(
42         GRV, 1,   2,   3,   4,   5,   6,   7,   8,   9,   0,   MINS,EQL, BSPC, \
43         TAB, Q,   D,   R,   W,   B,   J,   F,   U,   P,   SCLN,LBRC,RBRC,BSLS, \
44         BSPC,A,   S,   H,   T,   G,   Y,   N,   E,   O,   I,   QUOT,     ENT,  \
45         LSFT,Z,   X,   M,   C,   V,   K,   L,   COMM,DOT, SLSH,          RSFT, \
46         LCTL,LGUI,LALT,          SPC,                     RALT,RGUI,APP, FN0),
47
48     /* Overlay 4: HHKB mode
49      * ,-----------------------------------------------------------.
50      * |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delete |
51      * |-----------------------------------------------------------|
52      * |Caps |   |   |   |   |   |   |   |Psc|Slk|Pus|Up |   |Inser|
53      * |-----------------------------------------------------------|
54      * |Contro|VoD|VoU|Mut|   |   |  *|  /|Hom|PgU|Lef|Rig|Enter   |
55      * |-----------------------------------------------------------|
56      * |Shift   |   |   |   |   |   |  +|  -|End|PgD|Dow|Shift     |
57      * |-----------------------------------------------------------|
58      * |Ctrl|Gui |Alt |      Space             |Alt |Gui |App |    |
59      * `-----------------------------------------------------------'
60      */
61     KEYMAP_ANSI(
62         GRV, F1,  F2,  F3,  F4,  F5,  F6,  F7,  F8,  F9,  F10, F11, F12, DEL,  \
63         CAPS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,PSCR,SLCK,PAUS,UP,  TRNS,INS,  \
64         LCTL,VOLD,VOLU,MUTE,TRNS,TRNS,PAST,PSLS,HOME,PGUP,LEFT,RGHT,     ENT,  \
65         LSFT,TRNS,TRNS,TRNS,TRNS,TRNS,PPLS,PMNS,END, PGDN,DOWN,          RSFT, \
66         LCTL,LGUI,LALT,          SPC,                     RALT,RGUI,FN4, TRNS),
67     /* Overlay 5: Vi mode (Slash)
68      * ,-----------------------------------------------------------.
69      * |  `| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Backsp |
70      * |-----------------------------------------------------------|
71      * |Tab  |Hom|PgD|Up |PgU|End|Hom|PgD|PgU|End|   |   |   |     |
72      * |-----------------------------------------------------------|
73      * |Contro|   |Lef|Dow|Rig|   |Lef|Dow|Up |Rig|   |   |Return  |
74      * |-----------------------------------------------------------|
75      * |Shift   |   |   |   |   |   |Hom|PgD|PgU|End|   |Shift     |
76      * |-----------------------------------------------------------|
77      * |Ctrl|Gui |Alt |      Space             |Alt |Gui |App |Ctrl|
78      * `-----------------------------------------------------------'
79      */
80     KEYMAP_ANSI(
81         GRV, F1,  F2,  F3,  F4,  F5,  F6,  F7,  F8,  F9,  F10, F11, F12, BSPC, \
82         TAB, HOME,PGDN,UP,  PGUP,END, HOME,PGDN,PGUP,END, TRNS,TRNS,TRNS,TRNS, \
83         LCTL,TRNS,LEFT,DOWN,RGHT,TRNS,LEFT,DOWN,UP,  RGHT,TRNS,TRNS,     ENT,  \
84         LSFT,TRNS,TRNS,TRNS,TRNS,TRNS,HOME,PGDN,PGUP,END, TRNS,          RSFT, \
85         LCTL,LGUI,LALT,          SPC,                     RALT,RGUI,APP, RCTL),
86     /* Overlay 6: Mouse mode (Semicolon/App)
87      * ,-----------------------------------------------------------.
88      * |  `| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Backsp |
89      * |-----------------------------------------------------------|
90      * |Tab  |   |   |   |   |   |MwL|MwD|MwU|MwR|   |   |   |     |
91      * |-----------------------------------------------------------|
92      * |Contro|   |Ac0|Ac1|Ac1|   |McL|McD|McU|McR|   |   |Return  |
93      * |-----------------------------------------------------------|
94      * |Shift   |   |   |   |   |Mb3|Mb2|Mb1|Mb4|Mb5|   |Shift     |
95      * |-----------------------------------------------------------|
96      * |Ctrl|Gui |Alt |      Space             |    |    |    |    |
97      * `-----------------------------------------------------------'
98      * Mc: Mouse Cursor / Mb: Mouse Button / Mw: Mouse Wheel
99      */
100     KEYMAP_ANSI(
101         GRV, F1,  F2,  F3,  F4,  F5,  F6,  F7,  F8,  F9,  F10, F11, F12, BSPC, \
102         TAB, TRNS,TRNS,TRNS,TRNS,TRNS,WH_L,WH_D,WH_U,WH_R,TRNS,TRNS,TRNS,TRNS, \
103         LCTL,TRNS,ACL0,ACL1,ACL2,TRNS,MS_L,MS_D,MS_U,MS_R,TRNS,TRNS,     ENT,  \
104         LSFT,TRNS,TRNS,TRNS,TRNS,BTN3,BTN2,BTN1,BTN4,BTN5,TRNS,          RSFT, \
105         LCTL,LGUI,LALT,          BTN1,                    TRNS,TRNS,TRNS,RCTL),
106     /* Overlay 7: Layout selector
107      * ,-----------------------------------------------------------.
108      * | Lq| Lc| Ld| Lw|   |   |   |   |   |   |   |   |   |       |
109      * |-----------------------------------------------------------|
110      * |     |Lq |Lw |   |   |   |   |   |   |   |   |   |   |     |
111      * |-----------------------------------------------------------|
112      * |      |   |   |Ld |   |   |   |   |   |   |   |   |        |
113      * |-----------------------------------------------------------|
114      * |        |   |   |Lc |   |   |   |   |   |   |   |          |
115      * |-----------------------------------------------------------|
116      * |    |    |    |                        |    |    |    |    |
117      * `-----------------------------------------------------------'
118      * Lq: set Qwerty layout
119      * Lc: set Colemak layout
120      * Ld: set Dvorak layout
121      * Lw: set Workman layout
122      */
123     KEYMAP_ANSI(
124         FN5, FN6, FN7, FN8, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
125         TRNS,FN5, FN8, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
126         TRNS,TRNS,TRNS,FN7, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,     TRNS, \
127         TRNS,TRNS,TRNS,FN6, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,          TRNS, \
128         TRNS,TRNS,TRNS,          TRNS,                    TRNS,TRNS,TRNS,TRNS),
129 };
130
131 /*
132  * Fn action definition
133  */
134 const action_t PROGMEM fn_actions[] = {
135     [0] = ACTION_LAYER_MOMENTARY(4),
136     [1] = ACTION_LAYER_TAP_KEY(5, KC_SLASH),
137     [2] = ACTION_LAYER_TAP_KEY(6, KC_SCLN),
138     [3] = ACTION_LAYER_MOMENTARY(6),
139     [4] = ACTION_LAYER_MOMENTARY(7),   // to Layout selector
140     [5] = ACTION_DEFAULT_LAYER_SET(0),  // set qwerty layout
141     [6] = ACTION_DEFAULT_LAYER_SET(1),  // set colemak layout
142     [7] = ACTION_DEFAULT_LAYER_SET(2),  // set dvorak layout
143     [8] = ACTION_DEFAULT_LAYER_SET(3),  // set workman layout
144     [9] = ACTION_MODS_TAP_KEY(MOD_RSFT, KC_GRV),
145 };