Skip to content

Commit

Permalink
Switch bcat Chrome OS media keys workaround from mouse keys to NKRO (q…
Browse files Browse the repository at this point in the history
…mk#9790)

* Switch Chrome OS mouse keys workaround to NKRO

* Add NKRO toggle to keymaps

* USE NK_TOGG keycode instead of defining my own
  • Loading branch information
bcat authored Jul 23, 2020
1 parent 35a902b commit 7073b26
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 11 deletions.
2 changes: 1 addition & 1 deletion layouts/community/60_ansi_split_bs_rshift/bcat/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Function 2 layer: http://www.keyboard-layout-editor.com/#/gists/6e1068e4f91bbacccaf5ac0acbeec79c */
[LAYER_FUNCTION_2] = LAYOUT_60_ansi_split_bs_rshift(
_______, 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_INS, KC_DEL,
_______, _______, KC_MPLY, KC_VOLU, KC_MSTP, BL_BRTG, EEP_RST, RESET, _______, _______, _______, RGB_VAI, _______, _______,
_______, NK_TOGG, KC_MPLY, KC_VOLU, KC_MSTP, BL_BRTG, EEP_RST, RESET, _______, _______, _______, RGB_VAI, _______, _______,
_______, _______, KC_MPRV, KC_VOLD, KC_MNXT, BL_INC, _______, RGB_SPI, RGB_HUI, RGB_SAI, RGB_RMOD, RGB_MOD, RGB_TOG,
_______, _______, _______, KC_MUTE, _______, BL_DEC, _______, RGB_SPD, RGB_HUD, RGB_SAD, RGB_VAD, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______
Expand Down
2 changes: 1 addition & 1 deletion layouts/community/60_ansi_split_bs_rshift/bcat/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ layout](https://github.com/qmk/qmk_firmware/tree/master/layouts/community/60_tsa

## Function 2 layer

![Function 2 layer layout](https://i.imgur.com/WRvsEuZ.png)
![Function 2 layer layout](https://i.imgur.com/vJaCzVo.png)

([KLE](http://www.keyboard-layout-editor.com/#/gists/6e1068e4f91bbacccaf5ac0acbeec79c))
2 changes: 1 addition & 1 deletion layouts/community/60_tsangan_hhkb/bcat/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Function 2 layer: http://www.keyboard-layout-editor.com/#/gists/65ac939caec878401603bc36290852d4 */
[LAYER_FUNCTION_2] = LAYOUT_60_tsangan_hhkb(
_______, 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_INS, KC_DEL,
_______, _______, KC_MPLY, KC_VOLU, KC_MSTP, BL_BRTG, EEP_RST, RESET, _______, _______, _______, RGB_VAI, _______, _______,
_______, NK_TOGG, KC_MPLY, KC_VOLU, KC_MSTP, BL_BRTG, EEP_RST, RESET, _______, _______, _______, RGB_VAI, _______, _______,
_______, _______, KC_MPRV, KC_VOLD, KC_MNXT, BL_INC, _______, RGB_SPI, RGB_HUI, RGB_SAI, RGB_RMOD, RGB_MOD, RGB_TOG,
_______, _______, _______, KC_MUTE, _______, BL_DEC, _______, RGB_SPD, RGB_HUD, RGB_SAD, RGB_VAD, _______, _______,
_______, _______, _______, _______, _______, _______, _______
Expand Down
2 changes: 1 addition & 1 deletion layouts/community/60_tsangan_hhkb/bcat/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,6 @@ and/or blockers, so there aren't switches installed in those positions.

## Function 2 layer

![Function 2 layer layout](https://i.imgur.com/37APm7c.png)
![Function 2 layer layout](https://i.imgur.com/vdNpFae.png)

([KLE](http://www.keyboard-layout-editor.com/#/gists/65ac939caec878401603bc36290852d4))
2 changes: 1 addition & 1 deletion layouts/community/65_ansi_blocker_split_bs/bcat/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Function layer: http://www.keyboard-layout-editor.com/#/gists/f29128427f674c43777f045e363d1b44 */
[LAYER_FUNCTION] = LAYOUT_65_ansi_blocker_split_bs(
_______, 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_INS, KC_DEL, _______,
KC_CAPS, _______, KC_MPLY, KC_VOLU, KC_MSTP, _______, EEP_RST, RESET, KC_PSCR, KC_SLCK, KC_PAUS, _______, _______, _______, _______,
KC_CAPS, NK_TOGG, KC_MPLY, KC_VOLU, KC_MSTP, _______, EEP_RST, RESET, KC_PSCR, KC_SLCK, KC_PAUS, _______, _______, _______, _______,
_______, _______, KC_MPRV, KC_VOLD, KC_MNXT, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, KC_APP, _______, KC_MUTE, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______
Expand Down
2 changes: 1 addition & 1 deletion layouts/community/65_ansi_blocker_split_bs/bcat/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ keys, an HHKB-style (split) backspace, and media controls in the function layer

## Function layer

![Function layer layout](https://i.imgur.com/Q304GlI.png)
![Function layer layout](https://i.imgur.com/CsxfVfd.png)

([KLE](http://www.keyboard-layout-editor.com/#/gists/f29128427f674c43777f045e363d1b44))
15 changes: 10 additions & 5 deletions users/bcat/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,31 @@ SRC += bcat.c
# Enable Bootmagic Lite to consistently reset to bootloader and clear EEPROM.
BOOTMAGIC_ENABLE = lite

# Enable media keys on all keyboards. (Even though I don't use mouse keys, they
# seem to be required for media keys to register on Chrome OS.)
# Enable media keys on all keyboards.
EXTRAKEY_ENABLE = yes
MOUSEKEY_ENABLE = yes

# Enable N-key rollover on all keyboards. In addition to its intended
# functionality, as of July 2020, this is required for Chrome OS to process
# media keys. (It appears that Chrome OS filters out key events from the second
# USB endpoint's consumer and system control devices unless that endpoint also
# reports a keyboard or mouse device.)
NKRO_ENABLE = yes

# Enable link-time optimization to reduce binary size.
LINK_TIME_OPTIMIZATION_ENABLE = yes

# Disable unused build options on all keyboards.
COMMAND_ENABLE = no
CONSOLE_ENABLE = no
NKRO_ENABLE = no
MOUSEKEY_ENABLE = no
TERMINAL_ENABLE = no

# Disable unused hardware options on all keyboards.
FAUXCLICKY_ENABLE = no
MIDI_ENABLE = no
SLEEP_LED_ENABLE = no

# Disable unused other options.
# Disable other unused options on all keyboards.
API_SYSEX_ENABLE = no
AUTO_SHIFT_ENABLE = no
COMBO_ENABLE = no
Expand Down

0 comments on commit 7073b26

Please sign in to comment.