Skip to content

fix(launcher): keep every modifier in multi-modifier mod-taps - #14

Open
garyng wants to merge 1 commit into
Keychron:keychron_bprofrom
garyng:keychron_bpro
Open

garyng wants to merge 1 commit into
Keychron:keychron_bprofrom
garyng:keychron_bpro

Conversation

@garyng

@garyng garyng commented Nov 7, 2026

Copy link
Copy Markdown

A mod-tap set from Launcher or VIA with several modifiers, such as MT(MOD_MEH, KC_CAPS), held only the lowest one. MEH sent Ctrl alone.

mod_to_zmk_keycode() returned the keycode of the first modifier bit it found and dropped the rest. Its uint8_t return type could not carry modifier flags either.

Return the first modifier's keycode with the remaining modifiers in the top byte, the same encoding as LC(LS(LALT)). ZMK treats those as explicit modifiers when the keycode is itself a modifier, so all of them are held.

Tested on a B6 Pro ANSI (PID 0x076B, keychron_b6_usn).

PR check-list

  • Branch has a clean commit history
  • Additional tests are included, if changing behaviors/core code that is testable.
  • Proper Copyright + License headers added to applicable files (Generally, we stick to "The ZMK Contributors" for copyrights to help avoid churn when files get edited)
  • Pre-commit used to check formatting of files, commit messages, etc.
  • Includes any necessary documentation changes.

A mod-tap set from Launcher or VIA with several modifiers, such as
MT(MOD_MEH, KC_CAPS), held only the lowest one. MEH sent Ctrl alone.

mod_to_zmk_keycode() returned the keycode of the first modifier bit it
found and dropped the rest. Its uint8_t return type could not carry
modifier flags either.

Return the first modifier's keycode with the remaining modifiers in the
top byte, the same encoding as LC(LS(LALT)). ZMK treats those as explicit
modifiers when the keycode is itself a modifier, so all of them are held.

Tested on a B6 Pro ANSI (PID 0x076B, keychron_b6_usn).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant