Saturday, November 06, 2004
USB Logitech MX310 & PS/2 Mouse
Spent some effort updating my xorg.conf file to support a logitech mx310 mouse. This solution uses the event manager in the kernel (evdev).
Definition of the InputDevice in the xorg.conf file:
Section "InputDevice" # cat /proc/bus/input/devices Identifier "UsbMouse" Driver "mouse" Option "Protocol" "evdev" Option "Dev Name" "Logitech USB-PS/2 Optical Mouse" Option "Dev Phys" "usb-*/input0" Option "Device" "/dev/input/mouse1" Option "Buttons" "8" Option "ZAxisMapping" "7 8" Option "Resolution" "800" EndSectionDefinition of the ServerLayout in xorg.conf file. Note that I have dual screens and two mice (other mouse is stick integrated into keyboard).
Section "ServerLayout" Identifier "Simple Layout" Screen 0 "Screen 0" 0 0 Screen 1 "Screen 1" RightOf "Screen 0" Option "Xinerama" "on" Option "CloneDisplay" "off" InputDevice "UsbMouse" "Core Pointer" InputDevice "KeyboardMouse" "SendCoreEvents" InputDevice "Keyboard1" "CoreKeyboard" EndSectionAfter playing with xev determined that this switches the buttons around correctly. Note that your have to swap 4-7, 5-8, not just move them forward in the sequence.
xmodmap -e "pointer = 1 2 3 7 8 6 4 5"Created a .Xmodmap (or .xmodmaprc) with the following line:
pointer = 1 2 3 7 8 6 4 5After wondering why it wasn't called found from this post that KDM ignores it :-(. So I followed the suggestion and created the xinit.sh script in ~/.kde/AutoStart
#!/bin/sh xmodmap $HOME/.XmodmapNote that you need to make it executable. References linuX-gamers.net-How-Tos - Get all mouse buttons working