KMKfw / kmk_firmware

Clackety Keyboards Powered by Python
https://kmkfw.zulipchat.com
Other
1.32k stars 458 forks source link

[BUG] Adding KC.HT() or KC.TD() crashes CircuitPython into safe mode #990

Closed anventia closed 2 weeks ago

anventia commented 2 weeks ago

Describe the bug When I create a HoldTap or TapDance key, either in my keymap grid or as a variable, CircuitPython crashes and enters safe mode.

To Reproduce Steps to reproduce the behavior:

  1. Import HoldTap or TapDance
    from kmk.modules.holdtap import HoldTap
    from kmk.modules.tapdance import TapDance
  2. Initialize HoldTap or TapDance
    holdtap = HoldTap()
    tapdance = TapDance()
    keyboard.modules.append(holdtap)
    keyboard.modules.append(tapdance)
  3. Try adding a HoldTap or TapDance to the keymap or as a variable
    holdtap1 = KC.HT(KC.A, KC.B)
    tapdance1 = KC.TD(KC.A, KC.B)

Expected behavior HoldTap and TapDance to function as expected

Debug output

Running in safe mode! Not running saved code.

You are in safe mode because:
CircuitPython core code crashed hard. Whoops!
Hard fault: memory access or instruction error.
Please file an issue with your program at github.com/adafruit/circuitpython/issues.
Press reset to exit safe mode.

Additional context I was following the official documentation on how to set up these modules, I'm testing a simple implementation with just two different letters and without any of the optional paramters.

My board is a Waveshare RP2040-Zero, running CircuitPython 9.0.5

anventia commented 2 weeks ago

Issue solved, I wasn't quite on the latest version of KMK, although I didn't download it too long ago.