Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trackball not working with qmk>= 0.18.0 #162

Closed
zhyu opened this issue Nov 23, 2022 · 5 comments
Closed

Trackball not working with qmk>= 0.18.0 #162

zhyu opened this issue Nov 23, 2022 · 5 comments

Comments

@zhyu
Copy link

zhyu commented Nov 23, 2022

The last qmk version which works well with my keyball39 is 0.17.9.

There are some minor changes needed to compile with qmk 0.18.0, e.g., RESET to QK_BOOT migration, but I still managed to compile keyball firmware with qmk 0.18.0. However, after flashing the firmware, the movement of the trackball is not recognized at all. Maybe it's related to the pointing device improvements mentioned in the changelog.

Why update?

There would be a nice feature coming in the next breaking release of qmk that allows automatically activate the mouse layer when the mouse cursor is moved (qmk/qmk_firmware#17962).

Btw, as #126 pointed out, SAFE_RANGE has been changed. From my experience, the special keycodes of keyball should be +1 (e.g., 0x5DA5 -> 0x5DA6) in qmk 0.16.x. And it should be +8 (e.g., 0x5DA5 -> 0x5DAD) in qmk 0.17.x.

@zhyu
Copy link
Author

zhyu commented Dec 3, 2022

I have tried to build various commits between qmk 0.17.9 and 0.18.0, and it seems qmk/qmk_firmware#17840 is the change that causing the issue.

Confirmed the trackball works fine with qmk 0.18.0 after reverting the above commit. I don't quite understand why it breaks the trackball of keyball though, the crc checksum should be handled all in the common lib 🤔

Also, the SAFE_RANGE has been changed in 0.18.0 as well, the special keycodes of keyball should be +4 from the codes working for qmk 0.17.x, which means the current documented keycodes need to be +12 to work in 0.18.0 (e.g., 0x5DA5, 0x5DB1).

@zhyu
Copy link
Author

zhyu commented Dec 3, 2022

Confirmed the trackball works fine with qmk 0.18.17 (the last release before 0.19.0) after reverting the commit causing issues.

I tried to build qmk 0.19.0 as well. The trackball still works fine, however, the keymap is no longer recognized by REMAP any more. I guess it could be related to the VIA V3 update: qmk/qmk_firmware#18222

@zhyu
Copy link
Author

zhyu commented Dec 3, 2022

Cherrypicked the auto mouse layer feature on qmk 0.18.17, and everything works as expected. So I'm happy with it right now.

If I could find time and fix the trackball issue without reverting the upstream commit, I could send a PR to make keyball firmwares compatible with qmk 0.18.x.

@Yowkees
Copy link
Owner

Yowkees commented Dec 3, 2022

I am sorry I haven't had any action about this issue, because of I am quiet busy lately.
This PR will be helpful to catch up QMK.

Thank you so much for your cooperation;-)

@zhyu
Copy link
Author

zhyu commented Dec 4, 2022

Since the issue preventing the trackball from working is about RPC, as a workaround, instead of reverting the corresponding commit, plugging the USB cable to the side with the trackball also works.

This way, the trackball is on the master side, so no slave-to-master trackball reporting is needed, then no RPC issues :)

Finally resolved the issue. Since the breaking change is RPC requiring CRC checksum that prevents the trackball info from being transported from the slave side to the master side, we need to flash the firmware to both sides.

What will work:

  • the trackball is on the slave side: both the master side and the slave side require CRC checksum
  • the trackball is on the slave side: none of the master side and the slave side require CRC checksum
  • the trackball is on the master side (no RPC so no issues)

What will not work:

  • the trackball is on the slave side: only one of the master side and the slave side requires CRC checksum

@koron koron closed this as completed Jan 22, 2023
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

No branches or pull requests

3 participants