Skip to main content

Thread: Howto: Configuring Touchpad


this guide not updated after maverick meerkat 10.10 unless message removed.

if have elantech touchpad being detected "imps/2 logitech wheel mouse" allurgroceries has created fix here:
http://ubuntuforums.org/showthread.php?p=9175201

have not seen simple howto guide on adjusting touchpad settings making one.
lucid there special instructions since not use hal configuration. lucid users should synclient values step 3 go straight step 4b. maverick seems reverting xorg.conf maverick users can check out section 4c. purple syntax used placeholder should replaced proper syntax.

step 1: research
open terminal , read or scan through manuals may pertain problem.
code:
man synaptics #synaptics touchpad input driver manual. man synclient #command line utility query , modify synaptics driver options. man xinput #configures input devices including touchpad man syndaemon #a program monitors keyboard activity , disables touchpad when keyboard being used.

step 2: update synaptics driver

step unnecessary ensure have latest driver.

code:
sudo apt-get update sudo apt-get install xserver-xorg-input-synaptics

step 3: testing touchpad options

open terminal , type:
code:
synclient -l
you should see values assigned touchpad options here. should not have 'shmconfig error' latest synaptics driver if please let me know it.
can adjust settings temporarily through synclient typing in terminal
code:
synclient option=value
open synaptics manual 'man synaptics' see different options do. there range of possible values given option need play determine are.
in order adjust these values permanently must enter them permanent configuration files.

step 4: permanent configuration
a: hal configuration karmic 9.10 , earlier
references input device should removed xorg.conf in order continue.
use the following command bring location of hal configuration file
code:
sudo find /usr/share/hal /etc/hal -name *synaptics.fdi
the first line of output list path hal configuration file if exists , should similar 1 of these:
/usr/share/hal/fdi/policy/20thirdparty/11-x11-synaptics.fdi
/usr/share/hal/fdi/policy/10osvendor/11-x11-synaptics.fdi
/etc/hal/fdi/policy/11-x11-synaptics.fdi
open program launcher pressing alt/f2 , type following, substituting in actual path configuration file.
code:
sudo gedit "path configuration file"
enter options , values found work step 3 in following form same above outside <!--example section--> , within <match key> section recreating line many times necessary cover desired options , values:
code:
<merge key="input.x11_options.option" type="string">value</merge>
save , done. configuration implemented next time reboot or restart touchpad driver modprobe. can check values "synclient -l".

b: udev configuration lucid 10.04
way have found configure touchpad in lucid may not work ealier releases.
need create file include udev rules use alt/f2:
code:
gksudo gedit /etc/udev/rules.d/touchpad.rules
now should have blank slate here configure udev. if have code in touchpad.rules should able append following code below it:
code:
action!="add|change", goto="touchpad_end" kernel!="event*", goto="touchpad_end" env{id_input_touchpad}!="1", goto="touchpad_end" env{x11_options.option}="value" env{x11_options.option}="value" env{x11_options.option}="value" label="touchpad_end"
in line: "env{x11_options.option}="value" want change option , value ones found work in step 3 , make 1 or recreate many more of these lines need cover of settings want.

c: xorg.conf maverick 10.10
need edit xorg.conf in folder /etc/x11.
code:
sudo gedit /etc/x11/xorg.conf
and add "inputclass" section using identifier want , matching touchpad insert configuration options.
code:
section "inputclass"     identifier "touchpad"     matchistouchpad "on"     matchdevicepath "/dev/input/event*"     option "option" "value" endsection
here examples of configuration options can inserted in "inputclass" section copied user documentation xserver.
option "leftedge" "1700"
option "rightedge" "5300"
option "topedge" "1700"
option "bottomedge" "4200"
option "fingerlow" "25"
option "fingerhigh" "30"
option "maxtaptime" "180"
option "maxtapmove" "220"
option "vertscrolldelta" "100"
option "minspeed" "0.06"
option "maxspeed" "0.12"
option "accelfactor" "0.0010"
option "repeater" "/dev/ps2mouse"

step 5: failsafe

a: synclient on startup
have followed guide end , settings still not being held after reboot, there still hope. using synclient commands step 3, can place run them in script , place in /usr/bin can run anytime or place shortcut in startup applications. if script works not @ statrtup need add delay @ beginning, such "sleep 10;" executed after boot process complete.
go system / preferences / startupapplications, click "add" button, "name" enter whatever want, , "command" enter name of script
b: xinput on startup
can change settings through xinput also. first @ touchpad properties:
code:
xinput list --short | grep -i 'touchpad' | grep -o '=[0-9]*' | cut -d'=' -f2 | xargs -t xinput list-props
for more interactive approach can use first part of command:
code:
xinput list --short
followed
code:
xinput list-props 'id of touchpad'
each property has bit size of 8,16 or 32 have try each bit size when setting value. values seperated space set them use following example:
code:
xinput set-int-prop  'name of touchpad in single quotes' 'name of property in single quotes' bitsize valuea valueb ........
and of course substitute proper syntax "'name of touchpad in single quotes' 'name of property in single quotes' bitsize valuea valueb ......."
place setting in executable file in /usr/bin , create startup command it. if script works not @ statrtup need add delay @ beginning, such "sleep 10;" executed after boot process complete.

addendum
a: toggle while typing
this option should available under system's menu mouse preferences on touchpad tab.
can use syndaemon command disable touchpad while typing startup applications:
code:
syndaemon -i 1 -d -k
as startup command cause touchpad disabled while typing except when using modifier keys.
way disable touchpad while typing on gnome desktop in configuration editor. use gconfig gui menu or use command see touchpad settings:
code:
gconftool -r /desktop/gnome/peripherals/touchpad
use set disable_while_typing true:
code:
gconftool -s -t bool /desktop/gnome/peripherals/touchpad/disable_while_typing true
b: toggle shortcut
communitydocs
place script in file, make executable , place in /usr/bin/ can start 'run application' dialog box.
code:
# toggle synaptic touchpad on/off  # current state synstate=$(synclient -l | grep touchpadoff | awk '{ print $3 }')  # change other state if [ $synstate = 0 ];     synclient touchpadoff=1 elif [ $synstate = 1 ];     synclient touchpadoff=0 else     echo "couldn't touchpad status synclient"     exit 1 fi exit 0
this script accomplish same goal except designed toggle touchpad through xinput:
code:
# toggle synaptic touchpad on/off synstate=$(xinput list-props "synps/2 synaptics touchpad" | grep enabled | grep -eo '.$') if [ $synstate = 0 ]; xinput set-int-prop "synps/2 synaptics touchpad" "device enabled" 8 1 else xinput set-int-prop "synps/2 synaptics touchpad" "device enabled" 8 0; fi

you can toggle script through keypress using keyboard shortcuts. instance, press alt/f2 , type "gnome-keybinding-properties" click add , name enter whatever want , command enter path script me "/usr/bin/syntoggle.sh". click apply , can set whatever key combination wish.

c: toggle when using usbmouse
make script disable touchpad , 1 enable called "synkill.sh" , "synwake.sh". convenience these can run command line.
code:
display=:0 xinput list --short | grep -i 'touchpad' | grep -o '=[0-9]*' | cut -d'=' -f2 | display=:0 xargs -i nero xinput set-int-prop nero 'device enabled' 8 0
code:
display=:0 xinput list --short | grep -i 'touchpad' | grep -o '=[0-9]*' | cut -d'=' -f2 | display=:0 xargs -i nero xinput set-int-prop nero 'device enabled' 8 1
now create udev rule enact script when mouse changed , place in /etc/udev/rules.d/:
html code:
action=="add", subsystems=="usb", id_class="mouse", run+="/bin/sh -c /usr/bin/synkill.sh" action=="remove", subsystems=="usb", id_class="mouse",  run+="/bin/sh -c /usr/bin/synwake.sh"
that concludes guide. update if find there more add. luck.

thanks doing this. i'm running 9.04 64bit on 2 y.o. toshiba laptop. had issues touchpad , typing.

sure i'm configured through hal.

code:
radtek@radtek-laptop:~$ sudo find /usr/share/hal /etc/hal -name *synaptics.fdi -print0 | xargs -0 -t cat  [sudo] password radtek:   cat /usr/share/hal/fdi/policy/20thirdparty/11-x11-synaptics.fdi   <?xml version="1.0" encoding="iso-8859-1"?>  <deviceinfo version="0.2">    <device>      <match key="info.capabilities" contains="input.touchpad">          <merge key="input.x11_driver" type="string">synaptics</merge>          <!-- arbitrary options can passed driver using               input.x11_options property since xorg-server-1.5. -->          <!-- example:          <merge key="input.x11_options.leftedge" type="string">120</merge>          -->      </match>    </device>  </deviceinfo>
then fun tried this:

code:
radtek@radtek-laptop:~$ synclient -l  can't access shared memory area. shmconfig disabled?  radtek@radtek-laptop:~$ syndaemon -d -t -i 1  x error of failed request:  baddevice, invalid or uninitialized input device    major opcode of failed request:  141 (xinputextension)    minor opcode of failed request:  3 (x_opendevice)    serial number of failed request:  12    current serial number in output stream:  12  radtek@radtek-laptop:~$ synclient touchpadoff=1  can't access shared memory area. shmconfig disabled?
any ideas?


Forum The Ubuntu Forum Community Ubuntu Official Flavours Support Hardware [ubuntu] Howto: Configuring Touchpad


Ubuntu

Comments

Popular posts from this blog

Error compiling for board Arduino/Genuino Uno.

Installation database is corrupt

esp8266 (nodemcu 0.9) client.write très lent ???