Scroll Wheel Emulation for T-BC21 Marble Mouse Trackball

Questions about hardware and drivers
Forum rules
Before you post please read how to get help
Post Reply
kurtking
Level 1
Level 1
Posts: 39
Joined: Thu Aug 02, 2012 9:51 am

Scroll Wheel Emulation for T-BC21 Marble Mouse Trackball

Post by kurtking » Wed May 01, 2019 6:16 pm

I had been using scroll wheel emulation for my Logitech T-BC21 (USB) Marble Mouse in Betsy for a year with a script to emulate a normal scroll wheel through xorg under the device name of 'Logitech USB Optical Mouse' (id=12) which invoked “evdev” properties. Now in LMDE3 the closest device identification is 'Logitech USB Trackball' (id=8) and most of the properties are “libinput” with a different meaning structure – see with xinput --list-props 8 . This, https://www.mankier.com/4/libinput , is a description of the libinput parameters. Using the new xorg data with xinput test 8 , the button numbering is the same and they have the same events.

Since I can’t find any property about axes, the substance of my scrolling emulation script is down to:
xinput --set-prop 'Logitech USB Trackball' 'libinput Natural Scrolling Enabled' 8
or
xinput --set-prop 8 282 8

Terminal messages using the text parameters:
kurt@cm600-e51-lmde3:~$ kkscroll
Set trackball button to control using ball for scrolling. <== my comment in script
X Error of failed request: BadValue (integer parameter out of range for operation)
Major opcode of failed request: 131 (XInputExtension)
Minor opcode of failed request: 57 ()
Value in failed request: 0x11a
Serial number of failed request: 20
Current serial number in output stream: 21

Terminal messages after changing both strings to the corresponding integers:
kurt@cm600-e51-lmde3:~$ kkscroll
Set trackball button to control using ball for scrolling.
X Error of failed request: BadValue (integer parameter out of range for operation)
Major opcode of failed request: 131 (XInputExtension)
Minor opcode of failed request: 57 ()
Value in failed request: 0x11a
Serial number of failed request: 19
Current serial number in output stream: 20

Mankier lists “Options” for “ScrollButton” (int) and “ScrollMethod” (string) which aren’t quite the same in name or value as the properties exposed in my xinput --list-props command:
libinput Scroll Method Enabled (287): 0, 0, 1 [Multiple, not one. The description more applies to a touchpad.]
libinput Button Scrolling Button (289): 2 [not string]

Even if I’m aiming at the wrong property, I don’t know where the errors, whose points of reference are not in what I wrote, might be documented or how to fix them. Or, since the evdev properties worked before, I would love to make them available again. How?

Thanks in advance,
Kurt

P.S. My computer has m/b MSI 785GM P45 / AMI BIOS Ver 11.5 081010

kurtking
Level 1
Level 1
Posts: 39
Joined: Thu Aug 02, 2012 9:51 am

Re: Scroll Wheel Emulation for T-BC21 Marble Mouse Trackball

Post by kurtking » Fri May 03, 2019 10:19 am

I found what looks like the evdev package, Xserver-xorg-input-evdev for debian stretch (1:2.10.5-1) https://packages.debian.org/stretch/xse ... nput-evdev ( https://manpages.debian.org/stretch/xse ... .4.en.html ) in the standard repo, so I installed it with Synaptic, which now shows the package installed. However, no difference shows in the xinput --list, and the xinput --list-props 8 remains the same - only showing the libinput properties.

How can I tell X to list this new package?

Since the IDs are different it seems there should be no conflict for X to store them. Is there a conflict in accessing them both for pointer device use? I'm reluctant to just delete the package (libinput (xserver-xorg-input-libinput (0.23.0-2), apparently new in Stretch) - possibly breaking some other process.

TIA for any help understanding this.

- Kurt

kurtking
Level 1
Level 1
Posts: 39
Joined: Thu Aug 02, 2012 9:51 am

Re: Scroll Wheel Emulation for T-BC21 Marble Mouse Trackball

Post by kurtking » Fri May 03, 2019 4:15 pm

Continuing to try to nail down the problem I ran across the suggestion to see the log file. Cindy has a logs reader but it didn't show anything I needed for this even in what it called the Hardware log, so I found Xorg in /var/log .

Xorg.0.log Lines 467-469

Code: Select all

[    24.885] (II) config/udev: Adding input device Logitech USB Trackball (/dev/input/event2)
[    24.885] (**) Logitech USB Trackball: Applying InputClass "evdev pointer catchall"
[    24.885] (**) Logitech USB Trackball: Applying InputClass "libinput pointer catchall"
[    24.886] (II) [b]Using input driver[/b] 'libinput' for 'Logitech USB Trackball'
That shows the system at startup saw the evdev package first, but it was ignored in favor of the other. It went on to choose libinput over evdev for Power button, (twice), wired MM keyboard (twice), and screen.

More grist for the analysis mill.

TIA,
-Kurt

kurtking
Level 1
Level 1
Posts: 39
Joined: Thu Aug 02, 2012 9:51 am

Re: [SOLVED] Scroll Wheel Emulation for T-BC21 Marble Mouse Trackball

Post by kurtking » Tue Jul 09, 2019 3:49 pm

Yesterday, I looked again for a solution to my trackball as scroll-wheel programming problem (marble mouse as scroll wheel Debian at DuckDuckGo) and I found https://www.hutsky.cz/blog/2017/02/scro ... -debian-9/

This article started in 2017 with an evdev solution, but then in a 02/2018 update noted that that stopped working (he must have been reading my mail ;-) ) and he went on to write the code (below) for /usr/share/X11/xorg.conf.d/50-trackball.conf . I recognized all the words, noted his debian version didn’t match mine (9.3), but couldn’t have put them together. On his testimony (don’t know how he figured the filename 50-trackball) I created a corresponding file exactly. cat didn’t work for me in sudo so I created a text file in my home and used sudo cp to put it where he said. It didn’t work immediately, but perfectly after a reboot.

Problem solved.

Code: Select all

# sudo cat /usr/share/X11/xorg.conf.d/50-trackball.conf 
Section "InputClass"
        Identifier      "Marble Mouse"
        MatchProduct    "Logitech USB Trackball"
        Driver          "libinput"
        Option          "ScrollMethod" "button"
        Option          "ScrollButton" "8"
        Option	   "MiddleEmulation" "on"
EndSection
Thanks for listening.

Post Reply

Return to “Hardware Support”