Configuring Alps Touchpad under Ubuntu Linux


The Linux mouse buttons can be remapped for left-handed use by doing:

	$ xmodmap -pp
	There are 5 pointer buttons defined.
	    Physical        Button
	     Button          Code
	        1              1
	        2              2
	        3              3
	        4              4
	        5              5
	$ xmodmap -e "pointer = 3 2 1 4 5"

The first xmodmap shows the mouse button mapping. In the old days, you only had two or three of them. These days, with scrollwheels and other doodads, the mouse is presented to the system with what appears to be additional buttons. The example above is from a two-button, scroll wheel mouse. (Press the wheel signals button 2, scroll it up and down signals 4 and 5.)

The second xmodmap remaps the order of the first three buttons for left-handed use. The pointer list always starts "3 2 1". Then, you extend the list for as many buttons as shown by the first xmodmap.

This all worked fine on hepcat. The problem is that the touchpad tap is tied to physical mouse button one, which I'd just now mapped for left-handed use. So the touchpad tap now brought up a command menu rather than doing a select.

You ought to be able to remedy this problem with the synclient utility. That is used to reconfigure the touchpad. It was written for Synaptics brand touchpads, but it supports the Alps too. Under Ubuntu 5.04 Linux, however, it wouldn't work.

Thanks to this posting, there was some hope that a kernel upgrade might solve my problem. I tried it, and it worked.

Here is a procedure that should work to get the touchpad working. (Be warned, I'm recalling a lot of the specifics from memory. Your mileage may vary.)

  • Make a backup copy of the /etc/apt/sources.list file.
  • Edit your /etc/apt/sources.list file, and change all instances of "hoary" to "breezy".
  • Run: apt-get update
  • Run: aptitude search linux-image-2.6.12
  • That command will display a list of 2.6.12 kernels available in the repository. Pick out the latest one that is appropriate for your CPU. At the time I write this, it is linux-image-2.6.12-3-686.
  • Install the selected kernel by running something like: apt-get install linux-image-2.6.12-3-686
  • A caution on the above. I first tried to install the kernel with the aptitude command. Unfortunately, it wanted to pull in a huge number of files to resolve dependencies. I aborted that and tried apt-get, and the only thing it wanted to pull in was initrd-tools, which I let it do.
  • Restore the "hoary" version of your /etc/apt/sources.list file, and then run: apt-get update
  • Next, get rid of the old touchpad driver by running: aptitude purge xorg-driver-synaptics
  • Download a precompiled, updated version of the touchpad driver from here and install it as: /usr/X11R6/lib/modules/input/synaptics_drv.o
  • Note that at this point, we've replaced the touchpad driver, but not the synclient utility. We'll talk about restoring that in a moment.

  • Edit the /etc/X11/xorg.conf file, and in the "Configured Mouse" section change the line that says:
    Option "CorePointer"
    Option "SendCoreEvents" "true"
  • Replace the "Synaptics Touchpad" section with something like this:
    Section "InputDevice"
            Identifier      "Synaptics Touchpad"
            Driver          "synaptics"
            Option          "CorePointer"
            Option          "Device"                "/dev/psaux"
            Option          "Protocol"              "auto-dev"
            Option          "LeftEdge"              "120"
            Option          "RightEdge"             "830"
            Option          "TopEdge"               "120"
            Option          "BottomEdge"            "650"
            Option          "FingerLow"             "14"
            Option          "FingerHigh"            "15"
            Option          "MaxTapTime"            "180"
            Option          "MaxTapMove"            "110"
            Option          "EmulateMidButtonTime"  "75"
            Option          "VertScrollDelta"       "0"
            Option          "HorizScrollDelta"      "0"
            Option          "MinSpeed"              "0.3"
            Option          "MaxSpeed"              "0.75"
            Option          "AccelFactor"           "0.015"
            Option          "EdgeMotionMinSpeed"    "200"
            Option          "EdgeMotionMaxSpeed"    "200"
            Option          "UpDownScrolling"       "1"
            Option          "CircularScrolling"     "1"
            Option          "CircScrollDelta"       "0.1"
            Option          "CircScrollTrigger"     "2"
            # local additions below
            Option          "SHMConfig"             "on"
            Option          "TapButton1"            "3"
            Option          "TapButton3"            "1"
    The SHMConfig entry is needed to enable the synclient utility. The TapButton1 and TapButton3 entries reconfigure the touchpad for left-handed use. Note that the defaults for the updated touchpad driver do not work well with the Alps touchpad, which is why all of the parameters are specified here.
  • Reboot to the new kernel and restart X.

At this point, your system should start X with the touchpad parameters configured. One way you could check is by setting MaxTapTime to "0" and verifying it disables taps.

If you want to use synclient, you'll need to download and compile the package from here. It build problem-free for me. You'll need to install the libx11-dev package.


Comments have been closed for this entry.

re: Configuring Alps Touchpad under Ubuntu Linux

I trashed (or, more accurately, I allowed Windows to trash) the LVM partition on my laptop, so I'm having to repeat this procedure. The additional packages I needed to install on a fresh system to build synclient are: gcc and libx11-dev.

re: Configuring Alps Touchpad under Ubuntu Linux

I am trying to configure my ubuntu Xwindow and I don't know how to configure my mouse or the Xwindow does anyone know the command for either a two-button or two button with scroll wheel?