DebuggingTouchpadDetection

Differences between revisions 28 and 29
Revision 28 as of 2012-09-05 15:50:03
Size: 12202
Editor: penalvch
Comment: 1) Removed all instances of "$" as it is confusing for users, 2) expand evtest info as confusing.
Revision 29 as of 2012-09-19 20:20:49
Size: 13279
Editor: c-24-22-12-247
Comment:
Deletions are marked like this. Additions are marked like this.
Line 159: Line 159:
=== Enabling right button click for clickpads on Ubuntu 12.04 LTS ===

Ubuntu 12.04 LTS added support for clickpads. The buttons are pressed by pressing the surface of the trackpad itself. All known clickpads, with the exception of the Apple Magic Trackpad, have indications on the trackpad for where the left and right buttons are. Clicking in the right button area should cause a right button click action. However, right button click support was added too late in the 12.04 LTS development cycle to be enabled by default. It is enabled by default in Ubuntu 12.10 and on.

Fortunately, the right click functionality is present and working in the release. It simply needs to be enabled. The attached [[attachment:enable-rightbutton.sh]] script may be used to simplify the process. After downloading the script, execute the following:

{{{
$ chmod a+x enable-rightbutton.sh
$ ./enable-rightbutton.sh <device id|device name>
}}}

Be sure to use the device id or name of your specific trackpad. You can list the devices on your computer using the "xinput" command.

Debugging Central

This page is part of the debugging series — pages with debugging details for a variety of Ubuntu packages.

Introduction

Problems with touchpad detection typically fall into one of these categories:

  1. Your Touchpad doesn't work at all.
  2. Your Touchpad stops working after a while.
  3. Features of Mouse works but features of Touchpad (like Tapping, Scrolling) does not work at all.
  4. Some features of your Touchpad like scrolling, tapping, dragging don't work as expected.

How to file the bug report

Consider this document on filing Touchpad bugs with relevant information. Before filing a bug please check the list of known bugs at the end of this document. If your are unsure to which package the bug should be filed or your problem is not listed in any of the categories then, in general file your touchpad related bugs against xserver-xorg-input-synaptics. If the bug turns out to be a bug related to kernel(linux) or any other package, bug triagers will assign your bug additionally to that package and mark the task related to xserver-xorg-input-synaptics, as invalid.

General information before filing the bug

This information should be provided in the bug description itself:

  1. Laptop model.
  2. Manufacturer of the Touchpad.
  3. When the symptom first appeared.

Sample Description - 'ALPS Touchpad' incorrectly detected as PS/2 mouse in 'Sony Vaio VPCCW16FG' after the kernel upgrade.

However if you think that the bug is a general one with the type of the Touchpad and is irrespective of the Laptop model you could omit mentioning the Laptop model in the description. But only consider doing this, when you are very sure that the bug is affecting all laptops with that Touchpad model.

In case your Touchpad doesn't work at all (No response from the Touchpad)

This is generally a case of kernel(linux) or xorg bug. Check by connecting a mouse that if it works or not.

  • If no, then you should file the bug against HAL and follow the steps below.

    • Switch to a VT using Crtl+Alt+F2 and enter following in your terminal:

      sudo evtest /dev/input/eventX > ~/evtest

      where the "X" in "eventX" is the event number found by typing in a terminal:

      cat /proc/bus/input/devices

      Please see this for help on how to enter VT and log evtest events.

  • Add identifier, Scroll, tap, drag, press buttons and create various other possible events on the Touchpad and then press CTRL+C to exit cp /var/log/Xorg.0.log ~/Xorg.0.log 

  • Press Crtl+Alt+F7 to switch back to X.
  • Add ~/evtest and Xorg.o.log to the bug report in seperate attachments.

  • Check your  cat /proc/bus/input/devices  , if you do not find something like this

    I: Bus=0011 Vendor=0002 Product=0007 Version=01b1
    N: Name="SynPS/2 Synaptics TouchPad"
    P: Phys=isa0060/serio2/input0
    S: Sysfs=/devices/platform/i8042/serio2/input/input8
    U: Uniq=
    H: Handlers=mouse2 event8
    B: EV=b
    B: KEY=420 0 70000 0 0 0 0 0 0 0 0
    B: ABS=11000003 
    • In that case the bug is in the kernel itself and follow these steps:
      1. File the bug against linux

      2. Provide the general information.

      3. Enter the following command in a terminal/console:

        dmesg > ~/dmesg 
      4. Attach ~/dmesg and your /var/log/Xorg.0.log to the bug report in separate attachments.

In case your Touchpad stops working after a while

This is generally a case of kernel(linux) or xorg bug. In this case, in description field, specify the steps to make the touchpad stop working. eg- hit a key, drag or something. Now check by connecting a mouse that if it works or not.

  • If no, then you should file the bug against HAL and follow the steps below.

    1. Switch to a VT using Crtl+Alt+F2 and enter following in your terminal

      sudo evtest /dev/input/eventX > ~/evtest 
      • See this for help on how to enter VT and log evtest events.

  • Add identifier, Scroll, tap, drag, press buttons and create various other possible events on the Touchpad and then press CTRL+C to exit.

    cp /var/log/Xorg.0.log ~/Xorg.0.log 
    1. Press Crtl+Alt+F7 to switch back to X.
    2. Add ~/evtest and Xorg.o.log to the bug report in separate attachments.

  • Check your  cat /proc/bus/input/devices  , if you do not find something like this

    I: Bus=0011 Vendor=0002 Product=0007 Version=01b1
    N: Name="SynPS/2 Synaptics TouchPad"
    P: Phys=isa0060/serio2/input0
    S: Sysfs=/devices/platform/i8042/serio2/input/input8
    U: Uniq=
    H: Handlers=mouse2 event8
    B: EV=b
    B: KEY=420 0 70000 0 0 0 0 0 0 0 0
    B: ABS=11000003 
    • If you do not find a Touchpad in you /proc/bus/inpus/devices, in that case the bug is in the kernel itself and you should follow these steps:
      1. Provide the general information.

      2. Direct after logging in to GNOME, KDE or Xfce open a terminal and enter the following commands:

        dmesg > ~/dmesg_boot
        cp /var/log/Xorg.0.log ~/Xorg.0.log 
      3. Wait until your touchpad stops working.
      4. Open a Virtual Terminal by pressing Ctrl-Alt-F1.
      5. Enter the following commands:

        LANG=C
        dmesg > ~/dmesg
        diff -ns ~/dmesg_boot ~/dmesg > ~/dmesg_diff
        cp /var/log/Xorg.0.log ~/Xorg.0.log_tmp
        diff -ns ~/Xorg.0.log ~/Xorg.0.log_tmp > ~/Xorg.0.log_diff 
      6. Attach ~/dmesg_boot, ~/dmesg_diff, ~/Xorg.0.log and ~/Xorg.0.log_diff to the bug report in separate attachments.

In case Touchpad features like scrolling, tapping, etc do not work at all.

Common symptom is absence of 'Touchpad' Tab is not there in System>Preferences>Mouse.

This may be a wrong detection by the xserver or the kernel itself. So xserver-xorg-input-synaptics has nothing to do with it. In case, filing a bug against the kernel(linux), please note that you should not mark the bug as duplicate even if you can find a closely related bug and you have a strong feeling that the bug should be duplicate. This is a new policy of Kernel Team and it help them to handle the bugs better.

To check whether to report for kernel or not

cat /proc/bus/input/devices >~/devices 

If the output includes the name of your Touchpad eg Name="SynPS/2 Synaptics TouchPad", then kernel has detected it right. In this case, please don't report the bug against the kernel, rather report it against HAL. For more information on reporting bugs against HAL, refer DebuggingHal

In any case, include the outputs of the following commands:

cat /proc/bus/input/devices >~/devices
xinput --list > ~/xinput 
cat /var/log/Xorg.0.log > Xorg.0.log 

Attach all four, to the bug report in separate attachments.

IMP : Please do not file bug against the kernel unless you are very sure that it should be filed and do it only after reading this whole document. If you are unsure, file it against xserver-xorg-input-synaptics, somebody will change to kernel if is so.

In case at least one of Touchpad features works but does not work correctly and as expected

eg - Jumpy cursor, scrolling problems, Touchpad area is misdetected, circular scrolling, buttons not correctly mapped.

  1. Enter the following command in a terminal/console:

    xmodmap -pp >~/xmodmap
    xinput --list-props <id> >~/xinput 
    • In  xinput --list-props <id> , <id> is of your Touchpad in  xinput --list .

  2. Switch to a VT using Crtl+Alt+F2 and enter following in your terminal

    sudo evtest /dev/input/eventX > ~/evtest 
    • See this for help on how to enter VT and log evtest events.

  3. Add identifier, Scroll, tap, drag, press buttons and create various other possible events on the Touchpad and then press CTRL+C to exit.
  4. Press Crtl+Alt+F7 to switch back to X.
  5. Include the xev log.
    • See this for help on how to report xev logs.

  6. Attach ~/xmodmap, ~/xev, ~/xinput and your ~/evtest to the bug report in separate attachments.

In case your multitouch features does not work

This bug is common in Synaptics Touchpad V7.2 where multitouch works perfect in windows but not in linux. This is not a bug related to xserver-xorg-input-synaptics. Multitouch capabilities are not detected but the kernel itself as evident in  xinput --list-props <id of your touchpad>  shows  Synaptics Capabilities (277):       1, 1, 1, 0, 0 

This bug is already known (see the Known bugs below). In this case please don't file any new bugs and instead add a comment in the existing bug for any relevant information that you have.

NOTE : Synaptics is not willing to disclose the protocol it uses for the multitouch support for its newer Touchpads. As soon as Synaptics come up with its protocol, this issue will be fixed. So this is not a bug in general. So it has been classified as a wishlist.

  1. For any other case, include the outputs in the bug report in separate comments.

    xinput --list-props <id> >~/xinput 
    • In  xinput --list-props <id> , <id> is of your touchpad in xinput --list.

  2. Switch to a VT using Crtl+Alt+F2 and enter following in your terminal

    sudo evtest /dev/input/eventX > ~/evtest 
    • See this for help on how to enter VT and log evtest events.

  3. Add identifier, Scroll, tap, drag, press buttons and create various other possible events on the Touchpad and then press CTRL+C to exit.
  4. Press Crtl+Alt+F7 to switch back to X.
  5. Take your pointer in the windows and hold down your two fingers on the Touchpad and raise. Also try to tap with two fingers.

     xev | grep -i button > ~/xev
  6. Attach ~/xev, ~/xinput and your ~/evtest to the bug report in separate attachments.

Before filing new bug please look in the common bugs section.

Enabling right button click for clickpads on Ubuntu 12.04 LTS

Ubuntu 12.04 LTS added support for clickpads. The buttons are pressed by pressing the surface of the trackpad itself. All known clickpads, with the exception of the Apple Magic Trackpad, have indications on the trackpad for where the left and right buttons are. Clicking in the right button area should cause a right button click action. However, right button click support was added too late in the 12.04 LTS development cycle to be enabled by default. It is enabled by default in Ubuntu 12.10 and on.

Fortunately, the right click functionality is present and working in the release. It simply needs to be enabled. The attached enable-rightbutton.sh script may be used to simplify the process. After downloading the script, execute the following:

$ chmod a+x enable-rightbutton.sh
$ ./enable-rightbutton.sh <device id|device name>

Be sure to use the device id or name of your specific trackpad. You can list the devices on your computer using the "xinput" command.

Some general work flow for Triagers

If the features of your Touchpad (like Tapping, Scrolling) do not work at all. In this case, user will not see the Touchpad Tab in System>Administration>Mouse in Main menu. This means that Touchpad is misdetected as PS/2 mouse. Here the following workflow must be followed.

  1. Check whether Kernel has detected the Touchpad or not by the following.

    cat /proc/bus/input/devices 
    • If a Touchpad is detected, then something like following will appear. If Touchpad is not detected then following will appear. In this case the bug must be a kernel issue.
      • Name="ImPS/2 Generic Wheel Mouse"

  2. Check whether xserver has detected the Touchpad correctly by.

    xinput --list 
    • You will see the same name of Touchpad as above.
  3. Check whether synaptics module is correctly loaded in xserver or not in.

    cat /var/log/Xorg.0.log | grep -i synaptics 

For problems such as scrolling area, touch area, button wrong mapping, multitouch try investigating with

  •     evtest /dev/input/eventX
        xev 

Look for name in xinput --list eg - for ↳ TouchPad id=6 [slave pointer (2)], then type

  •     xinput --list-props 6 

Known bugs


CategoryBugSquad CategoryDebugging CategoryCleanup

DebuggingTouchpadDetection (last edited 2019-02-26 09:05:55 by anthonywong)