Multitouch touchpad with xinput

Just as the name says, here is where you can post tips and tricks to share with other users of MEPIS.
Message
Author
User avatar
Arjen
Forum Novice
Forum  Novice
Posts: 69
Age: 42
Joined: Tue Mar 23, 2010 1:04 pm

Multitouch touchpad with xinput

#1 Postby Arjen » Thu Nov 17, 2011 12:13 pm

One of the nice things of the Liquorix kernel is, that it enabled multitouch on the touchpad of my laptop - configurable through System Settings > Input Devices > Touchpad. However I had an issue with the Liquorix kernel that made me switch back to the default MEPIS kernel. When running the default kernel, "two finger horizontal/vertical" scrolling are greyed out in System Settings, as well as two/three finger tap. So no multitouch. :-(

I've tried all sorts of settings in xorg.conf - without effect. I don't know if I did something wrong or if it's just not possible. :-\

Then I read this post at the Ubuntu forums with instruction on getting multitouch to work with the xinput tool, and... it just works!

What I did:

  • Install xinput
  • Run xinput --list and xinput --list-props "SynPS/2 Synaptics TouchPad", and set some properties manually to see if it works. (Note that the device name will be different if you have another type of touchpad!)
  • Create a script as given in the url above, make it executable (chmod 755 touchpad.sh).
  • Run the script to see if it works
  • Add the script to KDE auto-start: System Settings > Startup and shutdown > Autostart > Add script and add as symlink. You can also just copy or move the script to ~/.kde/Autostart/.

Here's my script, it's almost the same as the original: (I also enabled horizontal two-finger scrolling)

Code: Select all

#!/bin/bash

xinput --set-prop --type=int --format=32 "SynPS/2 Synaptics TouchPad" "Synaptics Two-Finger Pressure" 4

# Below width 1 finger touch, above width simulate 2 finger touch. - value=pad-pixels
xinput --set-prop --type=int --format=32 "SynPS/2 Synaptics TouchPad" "Synaptics Two-Finger Width" 8

# vertical scrolling, horizontal scrolling - values: 0=disable 1=enable
xinput --set-prop --type=int --format=8  "SynPS/2 Synaptics TouchPad" "Synaptics Two-Finger Scrolling" 1 1

# vertical, horizontal, corner - values: 0=disable  1=enable
xinput --set-prop --type=int --format=8  "SynPS/2 Synaptics TouchPad" "Synaptics Edge Scrolling" 0 0 0

# stabilize 2 finger actions - value=pad-pixels
xinput --set-prop --type=int --format=32 "SynPS/2 Synaptics TouchPad" "Synaptics Jumpy Cursor Threshold" 250

# pad corners rt rb lt lb tap fingers 1 2 3 (can't simulate more then 2 tap fingers AFAIK) - values: 0=disable 1=left 2=middle 3=right etc. (in FF 8=back 9=forward)
xinput --set-prop --type=int --format=8  "SynPS/2 Synaptics TouchPad" "Synaptics Tap Action" 0 0 0 0 1 2 3   

exit


Now I have two finger vertical and horizontal scrolling, and a two finger tap simulates a middle mouse click. Cool! The only thing that doesn't work is a three finger tap for right click (which did work with Liquorix) - but I can live without that, and I feel pretty weird touching my touchpad with three fingers at the same time anyway. :-D

Edit: changed two-finger width to 6 and jumpy cursor threshold to 100 for more sensitivity. (Not modified in the script above.) Works great in combination with smooth scrolling in Firefox! But some people may find these values too sensitive, so adjust to your own liking.
HP Probook 4310s - Intel Core2 Duo T6670, 3GB memory, Intel GMA 4500MHD grapics, Intel wifi - MEPIS 11 (32 bits), kernel 2.6.36-1-mepis-smp, KDE 4.7.4

User avatar
lucky9
Forum Veteran
Forum Veteran
Posts: 12272
Age: 70
Joined: Wed Jul 12, 2006 5:54 am

Re: Multitouch touchpad with xinput

#2 Postby lucky9 » Sun Nov 20, 2011 1:19 am

It might be worth a lot to put a slightly edited version of your post in the Wiki.
Yes, even I am dishonest. Not in many ways, but in some. Forty-one, I think it is.
--Mark Twain

User avatar
Arjen
Forum Novice
Forum  Novice
Posts: 69
Age: 42
Joined: Tue Mar 23, 2010 1:04 pm

Re: Multitouch touchpad with xinput

#3 Postby Arjen » Mon Nov 21, 2011 1:15 pm

Done! Any comments welcome.
HP Probook 4310s - Intel Core2 Duo T6670, 3GB memory, Intel GMA 4500MHD grapics, Intel wifi - MEPIS 11 (32 bits), kernel 2.6.36-1-mepis-smp, KDE 4.7.4

User avatar
lucky9
Forum Veteran
Forum Veteran
Posts: 12272
Age: 70
Joined: Wed Jul 12, 2006 5:54 am

Re: Multitouch touchpad with xinput

#4 Postby lucky9 » Mon Nov 21, 2011 1:43 pm

Looks great!
It's not necessary to be root?
Yes, even I am dishonest. Not in many ways, but in some. Forty-one, I think it is.
--Mark Twain

User avatar
Arjen
Forum Novice
Forum  Novice
Posts: 69
Age: 42
Joined: Tue Mar 23, 2010 1:04 pm

Re: Multitouch touchpad with xinput

#5 Postby Arjen » Mon Nov 21, 2011 1:51 pm

Thanks! Everything described can be run as a regular user - I'll clarify in the wiki.
HP Probook 4310s - Intel Core2 Duo T6670, 3GB memory, Intel GMA 4500MHD grapics, Intel wifi - MEPIS 11 (32 bits), kernel 2.6.36-1-mepis-smp, KDE 4.7.4

User avatar
Jerry3904
Forum Veteran
Forum Veteran
Posts: 15031
Joined: Wed Jul 19, 2006 6:13 am

Re: Multitouch touchpad with xinput

#6 Postby Jerry3904 » Mon Nov 21, 2011 2:18 pm

Good job! I added a Touchpad entry under the Hardware link off the home page, and a redirect for a search on "touchpad"
Production: 4.2.0-0.bpo.1-amd64, MX-15 RC1, AMD FX-4130 Quad-Core, GeForce GT 630/PCIe/SSE2, 8 GB, Kingston SSD 120 GB and WesternDigital 1TB
Testing: AAO 722: 3.16-0-4-686-pae. MX-15, AMD C-60 APU, 4 GB

User avatar
Frank D. Hubeny
Forum Regular
Forum Regular
Posts: 250
Age: 63
Joined: Fri Sep 10, 2010 3:30 pm

Re: Multitouch touchpad with xinput

#7 Postby Frank D. Hubeny » Mon Nov 21, 2011 3:36 pm

Good Afternoon Arjen;

I think you should be commended for the work you did and the fact that you added it here and to the Wiki for us all to use. Others should take notice. So you are hear by officially commended. That and a few dollars or more should enable you to buy a cup of coffee, hot chocolate, or tea perhaps.
Until the next time we meet thank you for taking the time out of your day to visit
with me. I enjoyed spending time with you.

Frank D. Hubeny

User avatar
Arjen
Forum Novice
Forum  Novice
Posts: 69
Age: 42
Joined: Tue Mar 23, 2010 1:04 pm

Re: Multitouch touchpad with xinput

#8 Postby Arjen » Mon Nov 21, 2011 4:05 pm

Thank you for the nice words, Frank!
HP Probook 4310s - Intel Core2 Duo T6670, 3GB memory, Intel GMA 4500MHD grapics, Intel wifi - MEPIS 11 (32 bits), kernel 2.6.36-1-mepis-smp, KDE 4.7.4


Return to “Tips&Tricks”

Who is online

Users browsing this forum: No registered users and 2 guests