getreuer / qmk-keymap

My keymap & reusable QMK gems
Apache License 2.0
301 stars 45 forks source link

[Bug] Achordion disables RETRO_TAPPING #51

Closed wolfwood closed 6 months ago

wolfwood commented 7 months ago

Describe the bug

Single mod-tap key holds don't produce the tap key, with RETRO_TAPPING, when Achordion is enabled.

I'm using a new keyboard, which I am much slower to type on. I have previously used Homerow mods quite happily on both QMK and ZMK.

I noticed after enabling homerow mods, eg LALT_T(KC_A), that my normal tapping strokes on the home row weren't reliably producing keystrokes anymore. I read up on QMK's tap-hold implementation and learned that by default mod-tap holds do not register if no second key is pressed. I assumed I was simply holding too long and that was swallowing my keystrokes. RETRO_TAPPING to the rescue. This did what it said and transmitted my tap keys when holds were released, provided no other key was pressed.

However, then I enabled Achordion, and the missing keystrokes on single mod-tap holds returned.

Information

Do the keys involved use any of the following features?

NikGovorov commented 7 months ago

From https://getreuer.info/posts/keyboards/achordion/index.html: Additionally, RETRO_TAP and RETRO_SHIFT aren’t supported. It looks possible, but I haven’t yet implemented them.

NikGovorov commented 7 months ago

Have you tried to increase tapping term?

akaralar commented 7 months ago

I have the same problem. I'm using Retro Tapping for a single key and the key does not register as a tap unless released after Achordion timeout. I saw the blog post says it isn't supported but it also says it should be possible to implement. I checked the code and changing

if (achordion_state == STATE_HOLDING) {

to

if (achordion_state == STATE_HOLDING || IS_RETRO(tap_hold_keycode)) {

on line 135 seems to have fixed it for me. I'm not sure if I'm considering every edge case though, if @getreuer would be so kind to provide some feedback whether it's a viable workaround would be great!

akaralar commented 7 months ago

@wolfwood just so you know I opened (https://github.com/getreuer/qmk-keymap/pull/55) for this if you'd like to try it out. It fixed retro tap keys for me, if you try let me know if it also fixes it for you

wolfwood commented 7 months ago

@akaralar I saw your earlier message about cancelling correct achordion behavior. did you change something to address that?

akaralar commented 7 months ago

@wolfwood it turned out to be unrelated to what I did, as when I took my changes back the issue was still happening, hence I deleted that message. I can't say I know all the bells and whistles of QMK but the plumbing we do takes place after a tap&hold key is released, not sure if things can go very wrong there for Achordion functionality as we have already released the key. When the repo owner checks the code I can say that with more confidence but so far it's working fine for me with Achordion.