You are not logged in.

#1 2004-10-08 03:44:16

dlanor78
Member
Registered: 2004-09-24
Posts: 23

Extra mouse buttons question

I have one of those mice with the back and forward buttons.  It has left and right buttons, 2 side buttons (forward and back usually) and 2 scroll wheels.  In linux speak this would make it a 9 button mouse I guess.  It's made by GE.

I don't really care if the 2 scroll wheels do different things, but I do want to get the back and forward buttons working in firefox.  This is possible in linux, because Mandrake had it set up right by default.  Any ideas how to get this working?  Here's the mouse sections from my xorg.conf as made by hwd:

Section "InputDevice"
    Identifier  "Serial Mouse"
    Driver      "mouse"
    Option      "Protocol" "Microsoft"
    Option      "Device" "/dev/ttyS0"
    Option      "Emulate3Buttons" "true"
    Option      "Emulate3Timeout" "70"
    Option        "SendCoreEvents"  "true"
EndSection

Section "InputDevice"
    Identifier  "PS/2 Mouse"
    Driver      "mouse"
    Option      "Protocol" "PS/2"
    Option      "Device" "/dev/psaux"
    Option      "Emulate3Buttons" "true"
    Option      "Emulate3Timeout" "70"
    Option        "SendCoreEvents"  "true"
EndSection

Section "InputDevice"
        Identifier      "USB Mouse"
        Driver          "mouse"
        Option          "Device"                "/dev/input/mice"
    Option        "SendCoreEvents"    "true"
        Option          "Protocol"              "IMPS/2"
        Option          "ZAxisMapping"          "4 5"
        Option          "Buttons"               "5"
EndSection

I have my mouse plugged into the ps/2 port so I tried deleting the sections that didn't say PS/2 in them and adding the ZAxis stuff to the PS/2 sections, but I couldn't log into X after that.   I think I need to specify  Option "Protocol" "ExplorerPS/2" in there somewhere, but where?

Would I be better off using xorgcfg -textmode to make the xorg.conf instead of the one made by hwd?

Offline

#2 2004-10-08 07:57:45

Mr Green
Forum Fellow
From: U.K.
Registered: 2003-12-21
Posts: 5,750

Re: Extra mouse buttons question

you say Mandrake had mouse set up by default .. why can you not use section (mouse) from it ?

imwheel might help (do a google)

HTH


Mr Green

Offline

#3 2004-10-08 08:14:34

lanrat
Member
From: Poland
Registered: 2003-10-28
Posts: 1,274

Re: Extra mouse buttons question

Try Get all mouse buttons working howto from linux-gamers.net.

Offline

#4 2004-10-08 08:19:28

Mr Green
Forum Fellow
From: U.K.
Registered: 2003-12-21
Posts: 5,750

Re: Extra mouse buttons question

Nice  tongue


Mr Green

Offline

#5 2004-10-08 09:19:18

dlanor78
Member
Registered: 2004-09-24
Posts: 23

Re: Extra mouse buttons question

I'll check out that link and I'll look into imwheel.

The reason I don't use Mandrake's config is because I trashed Mandrake to install Arch smile  And besides a few little things like this I'm really liking it.

Offline

#6 2004-10-09 20:38:56

enderst
Member
Registered: 2004-06-28
Posts: 69

Re: Extra mouse buttons question

i have a logitech ifeel mouseman

XF86Config

Section "InputDevice"
        Identifier  "Mouse0"
        Driver      "mouse"
        Option      "Protocol" "ExplorerPS/2"
        Option      "Device" "/dev/usbmouse"
        Option      "Buttons" "6"
        Option      "ZAxisMapping" "5 6"
EndSection

my mouse script that i placed in ~/.kde/Autostart so my buttons/scroll work when i login to kde

#!/bin/sh
/usr/X11R6/bin/xmodmap -e "pointer = 1 6 3 2 4 5"

Offline

#7 2004-10-13 10:08:27

dlanor78
Member
Registered: 2004-09-24
Posts: 23

Re: Extra mouse buttons question

Thanks for your post enderst.  It didn't work for me however.  I couldn't log into x at all after that, so it's back to the man pages and google to see what I did wrong.

And I still haven't looked into imwheel yet.  So maybe that's what I need.

I'm sure I'll figure it out, just gotta get more time to read more docs.  Thanks for you time you guys.

Offline

#8 2004-10-13 10:51:24

lanrat
Member
From: Poland
Registered: 2003-10-28
Posts: 1,274

Re: Extra mouse buttons question

1. Check for errors (lines with EE) in your x log in /var/log.
2. Search gentoo.org forums - they have lots of config examples for different mouses there.
3. Post full mouse name and model number (and search for it in google too).

Are you sure your problems are mouse related ? Can you use x with standard mouse settings (no extra buttons)? Or maybe add

Option "AllowMouseOpenFail" "true"

to server flags section in your xorg.conf. Check http://freedesktop.org/~xorg/X11R6.8.0/ … onf.5.html for more info.

I'm sure it must be something simple because recently I bought logitech mx700 mouse (8 buttons) and I could use it without changing my xorg.conf at all (previously I had a4tech 5 buttons mouse). And 7 buttons (including two back and forward buttons) were working properly in opera and x without touching anything else. It seems that if you don't make any syntax errors, x should be smart enough to use your mouse with standard config.

Offline

#9 2004-10-13 15:31:14

dlanor78
Member
Registered: 2004-09-24
Posts: 23

Re: Extra mouse buttons question

My mouse does to most things correctly on its own.  In firefox (the browser I usually use) the forward button opens the right click context menu.  The back button seems to do a middle click (pasting from clipboard) when I use that.

Besides that, everything else works like a charm.  Like middle clicking somewhere on the page give me that double up/down arrow thing where I move my mouse up or down to scroll (autoscroll?).

All I really have to do is figure out what mandrake does to get this working correctly.  I'm not sure if it's an xorg.conf thing, or if they install imwheel....

I have a spare hd I'm thinking about throwning Mandrake on to see if I can pinpoint it.  Although I'm pretty sure I can get it working with imwheel if I just take/find the time to read up on it.

In the mean time it's not that big of a deal.  I'm just sticking mostly to mouse gestures for back and forward navigation.  Still better than going all the way to the top to click the arrows wink

I do seem to have a pretty obscure mouse.  It's a GE 97769 and I even had problems finding the fancy windows drivers for it (the ones that make the buttons easily configurable to do other stuff).

Thanks for pointing out the gentoo forums.  I had no idea they had a good section on mice.  I will check it out asap.

Offline

#10 2004-11-05 21:15:22

luke
Member
From: US
Registered: 2004-06-22
Posts: 54

Re: Extra mouse buttons question

Any news on this one. I've followed the article in the Wiki and it works for me, but I want to understand it better so I can tweek it. (This is Linux after all.)

Any info would be helpful.

Offline

#11 2004-11-05 22:01:03

lanrat
Member
From: Poland
Registered: 2003-10-28
Posts: 1,274

Re: Extra mouse buttons question

I'm not sure what do you want to know and what do you want to tweak?
Anyway there were other posts about mouse configuration in the forums during last few days (search for mouse).

Offline

#12 2004-11-06 05:29:59

colnago
Member
From: Victoria, BC
Registered: 2004-03-25
Posts: 438

Re: Extra mouse buttons question

I have a 7 button that works nicely.  All i needed was:

~/.imwheel

".*"
None, Up, Alt_R|Left
None, Down, Alt_R|Right

started with 'imwheel -b "0067"'

...and in xorg.conf:

Section "InputDevice"
    Identifier  "Mouse1"
    Driver      "mouse"
    Option "Protocol"    "ExplorerPS/2"
    Option "Device"      "/dev/mouse"
    Option "Buttons" "7"
    Option "ZAxisMapping" "4 5"
EndSection

If you do it this way you don't have to fool with the button mapping, which you do if you set ZAxisMapping "6 7".  'mouse' is a symlink setup in my udev rules.

Offline

#13 2004-11-06 14:23:56

luke
Member
From: US
Registered: 2004-06-22
Posts: 54

Re: Extra mouse buttons question

lanrat wrote:

I'm not sure what do you want to know and what do you want to tweak?
Anyway there were other posts about mouse configuration in the forums during last few days (search for mouse).

Well specifically, I want to change which buttons do what. I have 7 buttons right now and they are working fine.

xmodmap -pp yields:

There are 7 pointer buttons defined.

    Physical        Button
     Button          Code
        1              1
        2              2
        3              3
        4              6
        5              7
        6              4
        7              5

I would like to set it so that the furthest right button is the normal right click and the top thumb button works as the back button. Something like:

Physical        Button
     Button          Code
        1              1
        2              2
        3              5
        4              6
        5              7
        6              4
        7              3

I tried to just switching .xinitrc's relevant code from:

xmodmap -e "pointer = 1 2 3 6 7 4 5"
imwheel -k -b "67"

to:

xmodmap -e "pointer = 1 2 5 6 7 4 3"
imwheel -k -b "67"

but that didn't seem to work.

I seem to be missing something basic in my understanding. Is there an easy way to see what button code is sent when you press a specific button? I'm wondering if I am messing up the order of the physical buttons.

Oh and my mouse section of xorg.conf is:

Section "InputDevice"
    Identifier  "Mouse1"
    Driver      "mouse"
    Option      "Protocol"         "ExplorerPS/2"
    Option      "Device"           "/dev/input/mice"
    Option      "Emulate3Buttons"  "false"
    Option      "ZAxisMapping"     "6 7"
    Option      "Buttons"          "7"
    Option      "CorePointer"
EndSection

Offline

#14 2004-11-06 15:05:37

lanrat
Member
From: Poland
Registered: 2003-10-28
Posts: 1,274

Re: Extra mouse buttons question

You can use xev to check button codes and play with xmodmap settings.

Also take a look at lineakd and/or xbindkeys and/or xhkeys and maybe xvkbd (I posted pkgbuilds for the last two in the "new and requested packages" forum. The first two are already available in arch repos). They can be used to bind keys and mouse buttons to programs or other keys (similar to imwheel).

Many working examples for different settings can be found on gentoo forums.

Sorry for not posting details but there are many possibilites and my time is limited today. Anyway I hope this helps you somehow.

Offline

#15 2004-11-06 19:58:13

oscar
Member
From: Linköping, Sweden
Registered: 2004-08-13
Posts: 457

Re: Extra mouse buttons question

echo 'pointer = 1 2 3 6 7 4 5' >> /etc/X11/Xmodmap

and

xmodmap /etc/X11/Xmodmap

in your .xinitrc


To err is human... to really foul up requires the root password.

Offline

#16 2004-11-06 20:00:59

Mr Green
Forum Fellow
From: U.K.
Registered: 2003-12-21
Posts: 5,750

Re: Extra mouse buttons question

err

xmodmap ~/.Xmodmap 

Mr Green

Offline

#17 2004-11-24 01:32:32

Skee
Member
From: Bucuresti, Romania
Registered: 2004-10-29
Posts: 23
Website

Re: Extra mouse buttons question

Having xmodmap and imwheel do their thing from .xinitrc worked fine until now, but now i switched to default runlevel 5 and gdm and i don't know where to move the calls to xmodmap and imwheel, so they can be executed every time i start X. Some help?

i need sleep

Offline

#18 2004-11-24 13:38:14

Mr Green
Forum Fellow
From: U.K.
Registered: 2003-12-21
Posts: 5,750

Re: Extra mouse buttons question

I use kdm to log in ... so I made a script to call openbox-start

which does all the setting up before starting openbox

look for session files for your WM ;-)

HTH


Mr Green

Offline

#19 2005-04-13 20:21:23

dlanor78
Member
Registered: 2004-09-24
Posts: 23

Re: Extra mouse buttons question

I never did get my mouse completely working, but I did discover something interesting because of Knoppix.

If I boot knoppix with the default 2.4.x kernel, all the buttons work but aren't mapped correctly (which should be fixable).  If I boot with the 2.6.x kernel, my second scroll wheel isn't even seen anymore (in browsers and xev at least).

So, I guess the only option for now is to go back to a 2.4 kernel if you want all mouse buttons to work.

Well anyway, just wanted to post back so no one thinks I found the solution and just forgot to post it.  I hate those ppl tongue

Offline

#20 2005-04-13 20:31:41

shadowhand
Member
From: MN, USA
Registered: 2004-02-19
Posts: 1,142
Website

Re: Extra mouse buttons question

I have a Logitech Mx510 (10 button) mouse and all of my buttons work fine. The relevant stuff:

Follow here:
http://bbs.archlinux.org/viewtopic.php? … v+logitech

in my .xinitrc:

xmodmap -e "pointer = 1 2 3 6 7 8 9 10 4 5" &

relevant in xorg.conf:

Section "InputDevice"
    Identifier  "Mouse0"
    Driver      "mouse"
        Option      "Protocol" "evdev"
        Option        "Dev Name" "Logitech USB-PS/2 Optical Mouse" 
        Option        "Dev Phys" "usb-*/input0" 
        Option        "Device" "/dev/input/mice" 
        Option      "Buttons" "10"
        Option        "ZAxisMapping" "9 10"
        Option      "Resolution" "800"
EndSection

That's more specific to my Logitech mouse, but it should work for you too. I don't know if your mouse is capable of the 800 resoultion, but if so, you will also want a program called Logitech Applet. PKGBUILD here.

In my rc.local to make the scroll wheel/buttons work right:

logitech_applet -s800 -e

The first (forward) side mouse button is forward in Firefox, the second button is back. The scrollwheel works and the scroll buttons (above and below the scroll wheel) do what they are supposed to.

Good luck. smile


·¬»· i am shadowhand, powered by webfaction

Offline

#21 2005-04-14 02:10:57

dlanor78
Member
Registered: 2004-09-24
Posts: 23

Re: Extra mouse buttons question

Thanks a bunch shadowhand.  Because of your post I did some research on evdev and found a great post that helped me solve this.  Go  here.
and read the post by JohnQ to see what helped the most.

I just copied his xorg.conf info and altered it to my needs.  Didn't even have to mess with xmodmap or whatever.

Thanks again shadowhand and a thanks to JohnQ if he ever reads this.

Offline

#22 2005-04-14 08:07:25

shadowhand
Member
From: MN, USA
Registered: 2004-02-19
Posts: 1,142
Website

Re: Extra mouse buttons question

No problem. smile That's what we're here for.


·¬»· i am shadowhand, powered by webfaction

Offline

Board footer

Powered by FluxBB