summaryrefslogtreecommitdiff
path: root/keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2')
-rwxr-xr-xkeyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/keymap.c216
-rwxr-xr-xkeyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/readme.md79
2 files changed, 295 insertions, 0 deletions
diff --git a/keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/keymap.c b/keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/keymap.c
new file mode 100755
index 0000000000..1583392a48
--- /dev/null
+++ b/keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/keymap.c
@@ -0,0 +1,216 @@
+/* Copyright 2020 lmlask
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include QMK_KEYBOARD_H
+#include <keymap_brazilian_abnt2.h>
+
+enum layers {
+ _WORKMAN,
+ _QWERTY,
+ _DVORAK,
+ _COLEMAK,
+ _MIDI,
+ _GAME,
+
+ _SYM,
+ _FUNCTION,
+ _NAV,
+ _NUM,
+ _ADJUST,
+ _MOUSE,
+
+ _CPY,
+ _SWP
+};
+
+enum planck_keycodes {
+ WORKMAN = QK_USER,
+ QWERTY,
+ DVORAK,
+ COLEMAK,
+ MIDI,
+ GAME,
+ TOG_CPY,
+ TOG_SWP,
+};
+
+#define NAVTAB LT(_NAV, KC_TAB)
+#define SYM LT(_SYM, KC_BSPC)
+#define NUM LT(_NUM, KC_DEL)
+#define FUN MO(_FUNCTION)
+#define CTL_ENT RCTL_T(KC_ENT)
+
+//Hand swap config, similar to Planck
+const keypos_t PROGMEM hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
+ {{11, 0}, {10, 0}, {9, 0}, {8, 0}, {7, 0}, {6, 0}, {5, 0}, {4, 0}, {3, 0}, {2, 0}, {1, 0}, {0, 0} },
+ {{11, 1}, {10, 1}, {9, 1}, {8, 1}, {7, 1}, {6, 1}, {5, 1}, {4, 1}, {3, 1}, {2, 1}, {1, 1}, {0, 1} },
+ {{11, 2}, {10, 2}, {9, 2}, {8, 2}, {7, 2}, {6, 2}, {5, 2}, {4, 2}, {3, 2}, {2, 2}, {1, 2}, {0, 2} },
+ {{0, 3}, {1, 3}, {2, 3}, {3, 3}, {4, 3}, {5, 3}, {6, 3}, {7, 3}, {8, 3}, {9, 3}, {10, 3}},
+};
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+
+//BASE LAYERS
+[_QWERTY] = LAYOUT_planck_mit(
+ KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, BR_ACUT,
+ NAVTAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, BR_CCED, BR_TILD,
+ SC_LSPO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, BR_SLSH, SC_RSPC,
+ KC_LCTL, KC_LGUI, KC_LALT, KC_MEH, NUM, KC_SPC, SYM, FUN, KC_RALT, KC_HYPR, CTL_ENT
+),
+[_WORKMAN] = LAYOUT_planck_mit(
+ KC_ESC, KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, BR_CCED, BR_ACUT,
+ NAVTAB, KC_A, KC_S, KC_H, KC_T, KC_G, KC_Y, KC_N, KC_E, KC_O, KC_I, BR_TILD,
+ SC_LSPO, KC_Z, KC_X, KC_M, KC_C, KC_V, KC_K, KC_L, KC_COMM, KC_DOT, BR_SLSH, SC_RSPC,
+ KC_LCTL, KC_LGUI, KC_LALT, KC_MEH, NUM, KC_SPC, SYM, FUN, KC_RALT, KC_HYPR, CTL_ENT
+),
+[_DVORAK] = LAYOUT_planck_mit(
+ KC_ESC, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, BR_SLSH, BR_ACUT,
+ NAVTAB, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, BR_TILD,
+ SC_LSPO, BR_CCED, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, SC_RSPC,
+ KC_LCTL, KC_LGUI, KC_LALT, KC_MEH, NUM, KC_SPC, SYM, FUN, KC_RALT, KC_HYPR, CTL_ENT
+),
+[_COLEMAK] = LAYOUT_planck_mit(
+ KC_ESC, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, BR_CCED, BR_ACUT,
+ NAVTAB, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, BR_TILD,
+ SC_LSPO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, BR_SLSH, SC_RSPC,
+ KC_LCTL, KC_LGUI, KC_LALT, KC_MEH, NUM, KC_SPC, SYM, FUN, KC_RALT, KC_HYPR, CTL_ENT
+),
+
+//UTILITY LAYERS - SHORTCUT (CPY), SWAP HANDS (SWP)
+[_CPY] = LAYOUT_planck_mit(
+ _______, KC_PGUP, KC_HOME, KC_UP, KC_END, _______, _______, _______, _______, _______, _______, _______,
+ _______, KC_PGDN, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, _______,
+ _______, C(KC_Z), C(KC_X), C(KC_C), C(KC_V), _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
+),
+[_SWP] = LAYOUT_planck_mit(
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, NUM, SH_T(KC_BSPC),_______, _______, _______, _______, _______, _______
+),
+//AUX LAYERS (NAV, SYM, NUM, FN)
+[_NAV] = LAYOUT_planck_mit(
+ KC_CAPS, KC_F1, KC_F2, KC_F3, KC_F4, _______, KC_PGUP, KC_HOME, KC_UP, KC_END, C(KC_V), C(KC_Z),
+ _______, KC_LALT, KC_LGUI, KC_LSFT, KC_LCTL, _______, KC_PGDN, KC_LEFT, KC_DOWN, KC_RGHT, C(KC_C), C(KC_X),
+ _______, _______, _______, _______, _______, _______, KC_ENT, KC_BSPC, KC_DEL, KC_VOLD, KC_VOLU, _______,
+ _______, _______, _______, _______, _______, KC_ENT, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT
+),
+[_SYM] = LAYOUT_planck_mit(
+ BR_DQUO, BR_EXLM, BR_AT, BR_HASH, BR_DLR, BR_PERC, BR_DIAE, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, _______,
+ BR_QUOT, BR_BSLS, BR_SCLN, KC_MINS, BR_QUOT, _______, _______, KC_PLUS, _______, BR_LBRC, BR_RBRC, _______,
+ _______, BR_PIPE, BR_COLN, KC_UNDS, BR_DQUO, _______, _______, KC_EQL, _______, BR_LCBR, BR_RCBR, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
+),
+[_NUM] = LAYOUT_planck_mit(
+ _______, _______, _______, _______, _______, _______, _______, KC_7, KC_8, KC_9, BR_SLSH, BR_MINS,
+ _______, BR_SLSH, KC_ASTR, KC_MINS, KC_PLUS, _______, _______, KC_4, KC_5, KC_6, BR_ASTR, BR_PLUS,
+ _______, BR_PERC, KC_EQL, KC_DOT, KC_COMM, _______, _______, KC_1, KC_2, KC_3, BR_COLN, BR_DOT,
+ _______, _______, _______, _______, _______, _______, KC_0, KC_BSPC, BR_COMM, BR_EQL, KC_ENT
+),
+[_FUNCTION] = LAYOUT_planck_mit(
+ _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_SCRL, _______, KC_F13, KC_F14, KC_F15, KC_F16, KC_INS,
+ _______, KC_F5, KC_F6, KC_F7, KC_F8, KC_NUM, _______, KC_F17, KC_F18, KC_F19, KC_F20, KC_PAUS,
+ _______, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, _______, KC_F21, KC_F22, KC_F23, KC_F24, KC_APP,
+ _______, _______, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT
+),
+//ADJUST LAYER FOR KEYBOARD CONTROL
+[_ADJUST] = LAYOUT_planck_mit(
+ QK_BOOT, RGB_MOD, RGB_HUI, RGB_SAI, RGB_VAI, RGB_SPI, _______, MIDI, GAME, _______, _______, _______,
+ KC_CAPS, RGB_RMOD,RGB_HUD, RGB_SAD, RGB_VAD, RGB_SPD, _______, QWERTY, DVORAK, COLEMAK, WORKMAN, _______,
+ QK_RBT, _______, _______, _______, _______, _______, _______, TOG_CPY, TOG_SWP, _______, _______, _______,
+ RGB_TOG, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
+),
+//MOUSE LAYER
+[_MOUSE] = LAYOUT_planck_mit(
+ KC_ESC, KC_BTN6, KC_NO, KC_NO, KC_NO, KC_NO, KC_WH_U, KC_WH_L, KC_MS_U, KC_WH_R, KC_BTN6, KC_NO,
+ _______, KC_BTN4, KC_BTN2, KC_BTN3, KC_BTN1, KC_NO, KC_WH_D, KC_MS_L, KC_MS_D, KC_MS_R, KC_BTN4, KC_NO,
+ _______, KC_BTN5, KC_ACL2, KC_ACL1, KC_ACL0, KC_NO, KC_BTN7, KC_BTN1, KC_BTN3, KC_BTN2, KC_BTN5, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
+),
+//MIDI
+[_MIDI] = LAYOUT_planck_mit(
+ MI_Cs, MI_Ds, MI_F, MI_Fs, MI_Gs, MI_As, MI_C, MI_Cs1, MI_Ds1, MI_F1, MI_Fs1, MI_Gs1,
+ MI_C, MI_D, MI_E, MI_F, MI_G, MI_A, MI_B, MI_C1, MI_D1, MI_E, MI_F1, MI_G1,
+ MI_BNDU, MI_OCTU, MI_TRSU, MI_VELU, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, MI_MODU,MI_CHNU, MI_TOGG,
+ MI_BNDD, MI_OCTD, MI_TRSD, MI_VELD, MI_SOFT, MI_SUST, SYM, FUN, MI_MODD,MI_CHND, MI_AOFF
+),
+//GAME
+[_GAME] = LAYOUT_planck_mit(
+ KC_ESC, JS_0, JS_1, JS_2, JS_3, JS_4, JS_5, JS_6, JS_7, JS_8, JS_9, KC_P,
+ KC_TAB, JS_10, JS_11, JS_12, JS_13, JS_14, JS_15, JS_16, JS_17, JS_18, JS_19, KC_O,
+ KC_LSFT, JS_20, JS_21, JS_22, JS_23, JS_24, JS_25, JS_26, JS_27, JS_28, JS_29, KC_L,
+ KC_LCTL, KC_LGUI, KC_LALT, KC_MEH, NUM, KC_SPC, SYM, FUN, KC_RALT, KC_HYPR, CTL_ENT
+),
+};
+
+//Custom keycodes code for layer switching
+bool process_record_user(uint16_t keycode, keyrecord_t *record) {
+ switch (keycode) {
+ case QWERTY:
+ if (record->event.pressed) {
+ set_single_persistent_default_layer(_QWERTY);
+ }
+ return false;
+ case WORKMAN:
+ if (record->event.pressed) {
+ set_single_persistent_default_layer(_WORKMAN);
+ }
+ return false;
+ case DVORAK:
+ if (record->event.pressed) {
+ set_single_persistent_default_layer(_DVORAK);
+ }
+ return false;
+ case COLEMAK:
+ if (record->event.pressed) {
+ set_single_persistent_default_layer(_COLEMAK);
+ }
+ return false;
+ case MIDI:
+ if (record->event.pressed) {
+ set_single_persistent_default_layer(_MIDI);
+ }
+ return false;
+ case GAME:
+ if (record->event.pressed) {
+ set_single_persistent_default_layer(_GAME);
+ }
+ return false;
+ case TOG_CPY:
+ if (record->event.pressed) {
+ layer_invert(_CPY);
+ }
+ return false;
+ case TOG_SWP:
+ if (record->event.pressed) {
+ layer_invert(_SWP);
+ }
+ return false;
+ }
+ return true;
+}
+
+//ADJUST and MOUSE layers activation code
+layer_state_t layer_state_set_user(layer_state_t state) {
+ state = update_tri_layer_state(state, _FUNCTION, _SYM, _ADJUST);
+ state = update_tri_layer_state(state, _NAV, _NUM, _MOUSE);
+ return state;
+}
+
+
+
+
diff --git a/keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/readme.md b/keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/readme.md
new file mode 100755
index 0000000000..69130dbfec
--- /dev/null
+++ b/keyboards/kprepublic/bm40hsrgb/rev1/keymaps/wolff_abnt2/readme.md
@@ -0,0 +1,79 @@
+# Brazilian keymap for the BM40RGB keyboard
+
+![photo](https://user-images.githubusercontent.com/62627597/228396721-b38ea064-6e80-4aff-90ec-01164d0515ae.jpg)
+
+This keymap deviates somewhat from the generally used conventions of Planck style keyboards.
+It's built on the following principles:
+
+1. Availability of different base layouts. QWERTY, Dvorak, Colemak and Workman are available. They can be chosen with the four right hand home row keys on the ADJUST layer (NAV + NUM keys). The base layout you choose gets stored on the keyboard EEPROM, so it will still be set if you unplug or reset the keyboard.
+2. Frequent use of navigation keys such as the arrow keys, home, end, and hotkeys using those keycodes. For that reason, it keeps the navigation keys on a dedicated nav layer, on the home row, under the right hand. The nav layer is activated by the first button of the home row (the usual caps lock position). I find this much better than using dedicated arrow keys on the bottom right of the keyboard, as the very reason I swapped to a 40% is to move my hands less.
+3. Accessibility of the ´ ` ^ ~ ç symbols. There are several blank spaces left on the symbols layer, if you need access to other symbols or diacritics.
+4. Proper touch typing, and hotkey access, with the Shift key on both sides. I found my hands very much expect Ctrl to be on the edge of the keyboard, and as such I've kept both bottom corner keys as Ctrl. The right Ctrl will act as an Enter key if tapped.
+5. Numbers and navigation keys should be slightly more accessible than symbols and function keys. If you use symbols more often, consider swapping the NUM and SYM layer toggle keys.
+6. It's easier to remember layers when they make sense conceptually, so no "lower" and "raise" layers. Instead, there are dedicated layers for navigation/utility (NAV), numbers (NUM), symbols (SYM) and function keys (FN). There's also dedicated MIDI layers, a layer for one-hand typing, a mouse-emulating layer, and a layer for one-hand navigation and copy-pasting.
+7. Tap hold is a good tool and you should use it if you can. Backspace and Delete are set as tap functions on the two more accessible layer toggle keys. The bottom right Ctrl behaves as Enter when tapped. The Nav layer button is Tab when tapped.
+8. Easy-to-access shortcut modifiers. This layout includes a Master key (Shift+Ctrl+Alt) and a Hyper key (Shift+Ctrl+Alt+Super) for configuring system shortcuts.
+
+It will only work as intended if your system keyboard layout is set to Brazilian ABNT2. It may work with other international layouts, but some keys, including brackets and the ´ ` ~ ^ keys, will get broken. If your system layout is another one, it should be relatively easy to change keymap.c (search and replace each key with the equivalent one from the international keymaps file).
+
+# Base Layers
+
+These are selected as the base by a button in the Adjust layer.
+
+## Normal
+
+![bm40rgb-wolff-base](https://user-images.githubusercontent.com/62627597/228848191-cb403c12-c090-4aeb-b207-506e5c80c547.png)
+
+QWERTY, Dvorak, Colemak and Workman are built-in.
+
+## MIDI
+
+![bm40rgb-wolff-midi](https://user-images.githubusercontent.com/62627597/228708182-5ba2b9f4-e1f4-4e10-be6e-58ff373f274a.png)
+
+One and a half octaves piano on the top rows, control signals in the bottom rows. SYM and FUN remain accessible so the ADJ layer can be accessed.
+
+## Joystick
+
+![bm40rgb-wolff-game](https://user-images.githubusercontent.com/62627597/228849208-9fb10cf3-0a11-4799-877a-48eafe811078.png)
+
+Emulates a 32-button joystick for using as a button-box or dedicated game controller.
+
+# Modifier layers
+
+These are activated by holding down modifier keys.
+
+## Navigation Layer (NAV)
+
+![bm40rgb-wolff-nav](https://user-images.githubusercontent.com/62627597/228853095-6c254027-adfb-4afb-9536-4f00e11ab3cb.png)
+
+The layer you'll access most often. Navigation keys right on the right-hand homerow, plus a few common utilities.
+
+## Functions Layer (FUN)
+
+![bm40rgb-wolff-fun](https://user-images.githubusercontent.com/62627597/228852255-3c12d3c8-733a-4680-888c-35a4162cd3a3.png)
+
+## Mouse Layer
+
+![bm40rgb-wolff-mouse](https://user-images.githubusercontent.com/62627597/228853517-08934862-ca70-444d-a6bc-9dec584c6bb5.png)
+
+Emulates mouse actions so you can perform simple tasks without reaching for the mouse.
+
+## Adjust Layer (SYM + FUN)
+
+![bm40rgb-wolff-adj](https://user-images.githubusercontent.com/62627597/228851675-ec61ad2b-95a9-402b-933a-009e9f52fbd3.png)
+
+# Additional/utility layers
+
+These are utility overlays toggled by a key in the Adjust layer.
+
+## Handswap Layer
+
+![bm40rgb-swap-hands](https://user-images.githubusercontent.com/62627597/228849174-e3bca496-9f5a-49d6-a41e-9b65adbc6c34.png)
+
+For one-hand typing. The three top rows are mirrorred when SWAP is held down.
+
+## CPY Layer (One-hand navigation layer)
+
+![bm40rgb-copy](https://user-images.githubusercontent.com/62627597/228847641-4caa777e-c368-4921-a0a4-10c47afa2537.png)
+
+For general navigation and quick copy-paste one-handed stuff. I don't like using it, but my job demands it sometimes.