Tuesday, March 22, 2005

Logitech Mx700 Mouse

Confident after setting up Samba.. Next thing is to get my keyboard and mouse working.. I miss using the thumb buttons to go Back and Forward Webpages when online and using the media buttons.

After googling around heres what I've done. Following instructions on this page How to set up a Logitech MX500 and this one Getting the most of Microsoft Explorer mouse I got the mouse navigate buttons to work. What I mostly did was..

1. I uninstalled the old version of imwheel from YaST and installed the latest version of imwheel from the imwheel homepage. Check the INSTALL file for installation details
..update you might need to install the X11 Library files from YaST.

2. Changed the 'Xconfig' file (/etc/X11), after making a backup, to look like this:

Section "InputDevice"
Driver "mouse"
Identifier "Mouse[1]"
Option "ButtonNumber" "7"
Option "Buttons" "7"
Option "Device" "/dev/mouse"
Option "Name" "Automatic"
Option "Protocol" "ExplorerPS/2"
Option "ZAxisMapping" "6 7"
EndSection

3. Restarted Machine.. The scroll wheel wont work now but the thumb buttons will trigger scrolling. Thats coz programs usually recognise buttons 4 & 5 as scroll buttons and when we change the number of buttons to 7, the thumb buttons become button 4-5 and the scroll wheel become 6 & 7.
The scroll wheel is counted as 2 buttons that invoke the page up and page down keystrokes. A better explination of all this is in the links above.
You can use the console command 'xev' that reports mouse events to see what button corresponds to what #. (This should be useful when configuring the Keyboard)

4. Logged in as root and in the console window swapped the 4 & 5 buttons for the 6 & 7 buttons using xmodmap to get the scroll wheel to work correctly.

xmodmap -pp
xmodmap -e "pointer = 1 2 3 6 7 4 5"
xmodmap -pp

5. Edited imwheelrc (/etc/X11/imwheel), after making a copy. Added these lines to invoke the Alt+LeftArrow & Alt+RightArrow keystrokes that are shortcuts to move back & forward webpages in most browsers. The .* indicates that this key even should be invoked in and program.

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

Thats where I stopped last night coz Arati needed me to help her make her scrumptous Prawn Biryani.. yum!

6. Today I ran these commands in the console. And the navigation buttons work..

imwheel -p -b "67"

..update
7. Next created a startup script for X windows that would run two commands at startup so that the changes are permanent. Made changes in /etc/X11/xinit/ to the 'xinitrc' file. Added these lines at the top of the file

#-----------imwheel mousewheel hack------------
[ -r /etc/sysconfig/mouse ] && . /etc/sysconfig/mouse
/usr/X11R6/bin/xmodmap -e "pointer = 1 2 3 6 7 4 5"
BINARY=$(which imwheel)
BINARY= $-p -b "67"
#-----------imwheel mousewheel hack ends -------


Thats It!!

Research Links :
http://linux.netpimpz.com/mx700/
http://www.glaurung.demon.co.uk/info/linux.mx500.howto.html
http://kryz.org/linux.html
http://www.groundhog1.com/mouse/MSExplorer.html
Discussions about Suse Linux List (suse-linux-e-help@suse.com)

No comments: