Getting mouse buttons to work

Getting mouse buttons to work

Yedidyah Bar-David linux-il at didi.bardavid.org
Tue Feb 15 11:19:03 IST 2011


On Tue, Feb 15, 2011 at 10:44:08AM +0200, Dotan Cohen wrote:
> Hi all, first off I must confess that this is a crosspost. I posted a
> similar question to the Debian list, then to the Fedora list, but it's
> not getting very far and I know that there are some smart folks here
> who could probably help.
> 
> I have a nice new Teac OX-1100 mouse with two extra multimedia buttons
> that supposedly perform the Zoom functions in Windows. When I try to
> get the scancodes with "xev", "xbindkeys -k", "showkey", or "showkey
> -s" then I see no output. There are some other functional keys on this
> mouse which also show no output with those tools, such as the side
> scroll feature, so I suspect that there must be _some_ way to get the
> codes.
> 
> Other than Xev, Xbindkeys, and Showkey, what tools can I use? I
> specifically bought this mouse because of the location of the two
> extra keys, as I have a manual disability and cannot use the special
> keys of regular mice.
> 
> This is the rodent:
> ✈ganymede:~$ grep -i mouse /var/log/Xorg.0.log
> [    15.197] (==) RADEON(0): Silken mouse enabled
> [    15.289] (II) Microsoft Natural® Ergonomic Keyboard 4000: Found 1
> mouse buttons
> [    15.289] (II) Microsoft Natural® Ergonomic Keyboard 4000:
> Configuring as mouse
> [    15.292] (II) config/udev: Adding input device MLK OX-1100
> wireless Laser Mouse (/dev/input/event2)
> [    15.292] (**) MLK OX-1100 wireless Laser Mouse: Applying
> InputClass "evdev pointer catchall"
> [    15.292] (**) MLK OX-1100 wireless Laser Mouse: Applying
> InputClass "evdev keyboard catchall"
> [    15.292] (**) MLK OX-1100 wireless Laser Mouse: always reports core events
> [    15.292] (**) MLK OX-1100 wireless Laser Mouse: Device: "/dev/input/event2"
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Found 9 mouse buttons
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Found scroll wheel(s)
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Found relative axes
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Found x and y relative axes
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Found absolute axes
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Found keys
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Configuring as mouse
> [    15.300] (II) MLK OX-1100 wireless Laser Mouse: Configuring as keyboard
> [    15.300] (**) MLK OX-1100 wireless Laser Mouse: YAxisMapping:
> buttons 4 and 5
> [    15.300] (**) MLK OX-1100 wireless Laser Mouse:
> EmulateWheelButton: 4, EmulateWheelInertia: 10, EmulateWheelTimeout:
> 200
> [    15.300] (II) XINPUT: Adding extended input device "MLK OX-1100
> wireless Laser Mouse" (type: KEYBOARD)
> [    15.301] (II) MLK OX-1100 wireless Laser Mouse: initialized for
> relative axes.
> [    15.301] (WW) MLK OX-1100 wireless Laser Mouse: ignoring absolute axes.
> [    15.301] (II) config/udev: Adding input device MLK OX-1100
> wireless Laser Mouse (/dev/input/mouse0)
> 
> 
> However, 10 of the 12 buttons work, not just the 9 that it found. I've
> tried to google a picture of the mouse, I see no info on Teac mice
> even on the Teac website. The buttons are "zoom" buttons that I
> suppose are activated by a Windows driver on the OS that the package
> states that it "supports".
> 
> Thanks in advance for any advice on how to continue!

I have no idea about the specific mouse or issue, but other places you
can check are:

1. Outside of X, do
od -tx1 /dev/input/mice
then press various buttons and see what happens.

2. Try playing with acpi/acpid. E.g., from the examples of acpid
- look at /usr/share/doc/acpid/examples/default{,.sh}
(or at least that's where they are on my laptop - Debian Lenny).
I personally managed to make "Fn F7" move between internal/external
monitor by playing with it and an example I once found on google -
I think it was this one:
http://www.thinkwiki.org/wiki/Sample_Fn-F7_script

I have no idea if you can get acpi events from "normal" keys (not Fn)
and did not try this (yet?).
-- 
Didi




More information about the Linux-il mailing list