Tapdance spamming uncontrollably

Plugin name: TapDance
Documentation: https://github.com/keyboardio/Kaleidoscope/blob/master/docs/plugins/TapDance.md

Description:
On the left side I am trying to map the LED key to the (, [ and { keys .
On the right half I am trying to map the any key to ), ], and }.

But I am running into a minor annoyance. At first impression it seems to work but I would like to increase the time-out from the default 5 cycles to 8, but when doing this it started to spam the ( symbol. I changed the time-out back to 5 cycles but the problem is still present it just requires a longer press of the key before it starts spamming. The spamming gets so bad that I even tried unplugging the keyboard and reconnecting but it seems that after a second or 15 it stops by itself.

I have looked at the example included in the documentation and checked @algernon’s [Model01 sketch| https://github.com/algernon/Model01-sketch] but I can’t find any major problems with my sketch.

Model01-Firmware.ino (23.4 KB)
(Sorry if this is not the most convenient way to share my sketch, if there is a better way I’d love to hear it.)

Has anyone experienced similar problems with the TapDance plugin?

Ouch. I’ve reproduced the problem. Looks like tapDanceActionKeys() does not handle the repeat stuff on hold well. I seem to remember seeing this before, but there’s no issue about this on GitHub yet. Can you open one, or should I? (I need a GitHub issue to not forget about it the next time I’m hacking on TapDance.)

Oh, also, the documentation is outdated: TapDance.time_out is in milliseconds nowadays, not iterations, and is 200ms by default. Not sure how I failed to update the docs when we switched away from iteration counting a long long time ago…

1 Like

I’ve created a new issue.

If I have time today I will try if a a more sensible time-out of 300ms makes a difference.

1 Like

So I tried 300ms and I prefer this time-out setting but the problem with spamming still persists.