B166Er 的窝

Happy coding

触摸板的Snaptics驱动可实现multi-touch

需要在 /etc/X11/xorg.conf 中使用 snaptics 的触摸板驱动。目前我的 T42 2374-ER8 的 xorg.conf 是这样的:

 

 # xorg.conf (X.Org X Window System server configuration file)
#
# This file was generated by dexconf, the Debian X Configuration tool, using
# values from the debconf database.
#
# Edit this file with caution, and see the xorg.conf manual page.
# (Type "man xorg.conf" at the shell prompt.)
#
# This file is automatically updated on xserver-xorg package upgrades *only*
# if it has not been modified since the last upgrade of the xserver-xorg
# package.
#
# If you have edited this file but would like it to be automatically updated
# again, run the following command:
#   sudo dpkg-reconfigure -phigh xserver-xorg

Section "InputDevice"
    Identifier    "Generic Keyboard"
    Driver        "kbd"
    Option        "XkbRules"    "xorg"
    Option        "XkbModel"    "pc104"
    Option        "XkbLayout"    "us"
EndSection

#Section "InputDevice"
#    Identifier    "Configured Mouse"
#    Driver        "mouse"
#EndSection

# added from website

Section "InputDevice"
    Identifier "Configured Mouse"
    Driver "mouse"
    Option "CorePointer"
    Option "Device"         "/dev/input/mice"
    Option "Protocol"         "ImPS/2"
    Option "ZAxisMapping"         "4 5"
    Option "Emulate3Buttons"     "true"
EndSection

Section "InputDevice"
    Identifier "Synaptics Touchpad"
    Driver "synaptics"
    Option "SendCoreEvents"     "true"
    Option "Device"         "/dev/psaux"
    Option "Protocol"         "auto-dev"
    Option "HorizScrollDelta"     "0"
    Option "SHMConfig"         "on"
EndSection


Section "InputDevice"
  Driver        "wacom"
  Identifier    "stylus"
  Option        "Device"        "/dev/input/tablet-bamboo1"   # USB ONLY
  Option        "Type"          "stylus"
  Option        "USB"           "on"                  # USB ONLY
EndSection

Section "InputDevice"
  Driver        "wacom"
  Identifier    "eraser"
  Option        "Device"        "/dev/input/tablet-bamboo1"   # USB ONLY
  Option        "Type"          "eraser"
  Option        "USB"           "on"                  # USB ONLY
EndSection

Section "InputDevice"
  Driver        "wacom"
  Identifier    "cursor"
  Option        "Device"        "/dev/input/tablet-bamboo1"   # USB ONLY
  Option        "Type"          "cursor"
  Option        "USB"           "on"                  # USB ONLY
EndSection

# This section is for Intuos3, CintiqV5, Graphire4, or Bamboo
#Section "InputDevice"
#  Driver        "wacom"
#  Identifier    "pad"
#  Option        "Device"        "/dev/input/tablet-bamboo1"   # USB ONLY
#  Option        "Type"          "pad"
#  Option        "USB"           "on"                  # USB ONLY
#EndSection

Section "Device"
    Identifier    "Configured Video Device"
EndSection

Section "Monitor"
    Identifier    "Configured Monitor"
EndSection

Section "Screen"
    Identifier    "Default Screen"
    Monitor        "Configured Monitor"
EndSection


Section "ServerLayout"
    Identifier     "Default Layout"
    Screen         "Default Screen" 0 0
    InputDevice    "Generic Keyboard"     "CoreKeyboard"
    InputDevice    "Configured Mouse"    "CorePointer"
    InputDevice       "Synaptics TouchPad"    "SendCoreEvents"

    InputDevice    "stylus"    "SendCoreEvents" # For Bamboo1
    InputDevice    "eraser"    "SendCoreEvents"
    InputDevice    "cursor"    "SendCoreEvents"
EndSection

然后 synclient -m 100 就可以看 synaptics 的输出信息, 若想实现multi-touch, 需要用 perl 对这个输出信息加以筛选处理。请看:

www.ibm.com/developerworks/library/os-touchpad/