Kensington Trackball button setup

I have switched from a mouse to a Kensington Expert Wireless Trackball. KDE Plasma detects it and settings work OK except for one thing.

The top-right button works as Back and I wanted to use ‘Configure Extra Buttons’ in Settings to set top-left button to work as Forward. But ‘Add binding’ doesn’t detect anything when I click that button. All other buttons are detected as expected. Strangely, in applications the top-left button does what the left-bottom does (ie the mouse equivalent of a left-click: it selects).

Any ideas how I can set up the top-left button to do a Forward? At the moment, it is just wasted.

(Debian 13)

was this devise ever connected to a windows session where any proprietary kensingon software was being used on it.

these programs can change firmware settings on devices so that they no longer conform to HID standards and therefor linux will not recognize the reprogrammed buttons or keys.

the only solution is to go back into that proprietary software and reset the buttons to their factory settings, which would mean you would need to connect it to a windows machine that has the software installed.

That would never have crossed my mind! Yes, it was connected to a Windows system where I used the maker’s software to customise the buttons. I don’t have access to that system but I discovered there is a hardware reset method using the buttons.

Problem is it hasn’t changed anything. That button works exactly as before. I have discovered that it actually generates a middle-click in applications (which is the factory default) and that’s how KDE Plasma reads it. The odd thing is that Plasma Settings ignores the specific key-press when I try to add a key binding.

This link may help you get started

The buttons are positioned like this:
KEYBOARD__KEY_90003 KEYBOARD__KEY_90004
KEYBOARD__KEY_90001 KEYBOARD__KEY_90002

You can install a command line program called “evtest” that shows the codes generated when you press the buttons. It also works for other devices. For example, you could select your keyboard. Press a key, note the code and put it in the /etc/udev/hwdb.d/90-kensington-expert-trackball-remap.hwdb file to assign it to a trackball button.

I remapped my buttons using the above in Kubuntu 25.04 (not sure if the was X or Wayland) I am currently on 26.04 but not using that trackball … however, after reading your post, I might have to try it again.

i would not rely on that YT video to reset the firmware, it may only reset it back to whatever the firmware has been set to… it doesn’t seem to be firmware reflash.

for that you will need the software installed on a windows machine but you can also make a bootable live USB for windows and temporarily install the proprietary software so you can reflash the firmware.

otherwise you are stuck remapping whatever it is putting out.

a good tool GUI tool for that is input-remapper

This is fantastic, looks nice and solved the problem. Many thanks.

I may try to reset the firmware later, but I doubt it’s worth the trouble because all documentations state the factory default for the top-left button is BTN_MIDDLE, which is how it is working now, and what evtest reports. Apparently, the device has no settings memory and the Windows software doesn’t seem to have a reset option. Not sure what the hardware reset routine in the YT video does though.

For anyone else reading this, the mouse code for ‘forward’ is BTN_EXTRA. For ‘back’, it is BTN_SIDE.

EDIT: One side-effect is that ‘Press left and right buttons for middle-click’ in Plasma Settings has no effect. But you can set it in input-remapper. If input-remapper can do all this and reassign the top-left button, surely, Plasma Setting could do it too. Not sure if this is Plasma bug or a missing feature.

FWIW, that approach definitely works on Wayland. It works perfectly for my Elecom trackball on both Fedora KDE and KDE Linux.

evtest is a nice tool to have. I nearly completed the tests and remapping , and learned a lot but then I tried input-remapper and within seconds it was all done. Thanks.