I recently bought a Logitech Trackman Marble. I found a way by using xinput to turn one of the keys into a scroll key. The script looks like:
xinput set-button-map "Logitech USB Trackball" 1 2 3 4 5 6 7 8 9
xinput set-int-prop "Logitech USB Trackball" "Evdev Wheel Emulation Button" 8 8
xinput set-int-prop "Logitech USB Trackball" "Evdev Wheel Emulation" 8 1
xinput set-int-prop "Logitech USB Trackball" "Evdev Wheel Emulation Axes" 8 6 7 4 5
xinput set-int-prop "Logitech USB Trackball" "Evdev Wheel Emulation X Axis" 8 6When I run this script, the scroll function works for a while, but after some time it stops working and the buttons go back to their original functions.
Now the question is, how can I solve this problem?
2 Answers
xinput set-button-map "Logitech USB Trackball" 1 2 3 4 5 6 7 5 4
the 2 small buttons will be scroll up and down, but only moves a little bit each press
The solution is to update your xorg conf.
Create /etc/X11/xorg.conf.d/10-libinput.conf with the following
Section "InputClass" Identifier "Marble Mouse" MatchProduct "Logitech USB Trackball" Driver "libinput" Option "ScrollMethod" "button" Option "ScrollButton" "8" Option "AccelSpeed" "1" # Option "TransformationMatrix" "2.4 0 0 0 2.4 0 0 0 1" EndSection
This enables scrolling with wheel by clicking on the left small button. The commented TransformationMatrix allows to skip pixels and move faster, but I prefer to change the DPI instead as in .