Page 2 of 3

RE: Multitouch?

Posted: 04 Sep 2009, 23:51
by cout
A little more information. Reading here:

http://who-t.blogspot.com/2009/04/synap ... d-can.html

indicates that the additional fingers are not detected through the multifinger mechanism but through two additional buttons (double and triple). So I installed the latest synaptics driver (1.1.3). I check my Xorg.0.log and I see:

Code: Select all

cout@sapphire:/var/log$ egrep 'Syna.*(version|buttons)' Xorg.0.log
(II) Synaptics touchpad driver version 1.1.3
(II) SynPS/2 Synaptics TouchPad: buttons: left right middle double triple
But synclient -m 1 does not report any difference :(

RE: Multitouch?

Posted: 05 Sep 2009, 01:10
by voria
That's really strange. I've just installed the synaptics driver 1.1.3, and this is what I see in my logs:

Code: Select all

voria@sheep:~$ egrep 'Syna.*(version|buttons)' /var/log/Xorg.0.log
(II) Synaptics touchpad driver version 1.1.3
(II) SynPS/2 Synaptics TouchPad: buttons: left right middle
and I have exactly the same model as yours. From dmesg:

Code: Select all

[    9.995921] Synaptics Touchpad, model: 1, fw: 7.2, id: 0x1c0b1, caps: 0xd04731/0xa40000

RE: Multitouch?

Posted: 05 Sep 2009, 01:19
by cout
Voria, I assume you are running your 2.6.31 kernel? Maybe that makes a difference? (I am running Ubuntu's 2.6.28)

Does multitouch work for you on the newer kernel or does it make no difference?

RE: Multitouch?

Posted: 05 Sep 2009, 01:25
by voria
Yes, I'm using kernel 2.6.31, and there is no multitouch here.

RE: Multitouch?

Posted: 05 Sep 2009, 01:54
by cout
Looks like the older kernels always set double and triple tap.

2.6.28:

Code: Select all

 543        set_bit(EV_KEY, dev->evbit);
 544        set_bit(BTN_TOUCH, dev->keybit);
 545        set_bit(BTN_TOOL_FINGER, dev->keybit);
 546        set_bit(BTN_TOOL_DOUBLETAP, dev->keybit);
 547        set_bit(BTN_TOOL_TRIPLETAP, dev->keybit);
2.6.30:

Code: Select all

 540        set_bit(EV_KEY, dev->evbit);
 541        set_bit(BTN_TOUCH, dev->keybit);
 542        set_bit(BTN_TOOL_FINGER, dev->keybit);
 543        set_bit(BTN_LEFT, dev->keybit);
 544        set_bit(BTN_RIGHT, dev->keybit);
 545
 546        if (SYN_CAP_MULTIFINGER(priv->capabilities)) {
 547                set_bit(BTN_TOOL_DOUBLETAP, dev->keybit);
 548                set_bit(BTN_TOOL_TRIPLETAP, dev->keybit);
 549        }
BTW, I figured out what the extended capability bits from query 0x9 mean:
  • ext w mode (byte 0 bit 2 set)
  • peak detect (byte 0 bit 5 set)
  • reserved bit set (byte 0 bit 7 set)
  • no extended buttons (bits 14..12 in byte 1 not set)
Of those, peak detect sounds interesting:
Most modern Synaptics TouchPads use the peak interpolation method to locate the finger. This method first estimates the finger position by finding the grid conductor with maximum finger capacitance. Then it refines the position by comparing to the capacitances of adjacent conductors. If a second finger or an accidental palm contact touches the TouchPad, this method preferentially tracks the original finger to keep the X and Y coordinates stable. Only if the original finger leaves the pad while another finger remains will the X and Y coordinates jump to track a different finger. A host driver using Absolute mode may wish to suppress cursor motion on any packet for which the finger count changes (see section 3.2.6) to prevent this jump in coordinates from affecting the cursor.
How could the pad support peak detect without supporting multifinger? Odd...

(maybe the pad supports multifinger but doesn't set the right capability bit? could try forcing those bits to 1 in the kernel...)

RE: Multitouch?

Posted: 05 Sep 2009, 03:02
by cout
I just realized that two finger scroll is working. I don't know if it started working before or after I upgraded the xinput synaptics driver.

I had a while ago followed the instructions here:

http://ubuntu-snippets.blogspot.com/200 ... ptics.html

turns out that my fingers don't press down hard enough all the time to cross the MinZ threshold. Turning the threshold down to below 90 would mean that some of my single finger clicks would be interpreted as multi finger clicks. However, the latest driver also has a MinW option (not sure which version this was added in; it could have been there before but just not in the man page).

So I set MinZ to 70 and MinW to 7. My /etc/hal/fdi/policy/11-x11-synaptics.fdi now looks like this:

Code: Select all

<?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>
       <merge key="input.x11_options.SHMConfig" type="string">On</merge>
       <merge key="input.x11_options.EmulateTwoFingerMinZ" type="string">70</merge>
       <merge key="input.x11_options.EmulateTwoFingerMinW" type="string">7</merge>
       <merge key="input.x11_options.VertTwoFingerScroll" type="string">1</merge>
       <merge key="input.x11_options.HorizTwoFingerScroll" type="string">1</merge>
       <merge key="input.x11_options.TapButton1" type="string">1</merge>
       <merge key="input.x11_options.TapButton2" type="string">3</merge>  <!--two finger tap -> middle clieck(3) -->
       <merge key="input.x11_options.TapButton3" type="string">2</merge>  <!--three finger tap -> right click(2). almost impossible to click -->
   </match>
 </device>
</deviceinfo>
I would rather use circular scrolling than two finger scrolling, and have the two fingers be used for pasting. So I set the TwoFingerScrollLines to 0 and add lines for circular scroll. Two fingers still doesn't paste, and it turns out those TapButton lines are wrong, so I switch them. And since PalmDetect is off by default (why?) I turn it on:

Code: Select all

<?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>
       <merge key="input.x11_options.SHMConfig" type="string">On</merge>
       <merge key="input.x11_options.EmulateTwoFingerMinZ" type="string">70</merge>
       <merge key="input.x11_options.EmulateTwoFingerMinW" type="string">7</merge>
       <merge key="input.x11_options.VertTwoFingerScroll" type="string">0</merge>
       <merge key="input.x11_options.HorizTwoFingerScroll" type="string">0</merge>
       <merge key="input.x11_options.TapButton1" type="string">1</merge>
       <merge key="input.x11_options.TapButton2" type="string">2</merge>
       <merge key="input.x11_options.TapButton3" type="string">3</merge>
       <merge key="input.x11_options.CircularScrolling" type="string">1</merge>
       <merge key="input.x11_options.CircularPad" type="string">1</merge>
       <merge key="input.x11_options.CircScrollTrigger" type="string">3</merge>
       <merge key="input.x11_options.PalmDetect" type="string">1</merge>
   </match>
 </device>
</deviceinfo>
Also shm isn't necessary anymore on the latest client, but I'm leaving it on in case my driver gets reverted somehow.

Now if the machine really does support multitouch as advertised, it should be possible to get pinch and such to work as well, but I'm not going to hold my breath.

A few hours spent that I don't feel I should have had to, but I am much happier now!

RE: Multitouch?

Posted: 05 Sep 2009, 10:53
by voria
Following your tests, I've added a new synaptics driver on my experimental repository, based on latest snapshot from git.

It works nice here with both 2.6.28 and 2.6.31 kernels, the only problem is that the vertical sensitivity can't be set with 2.6.28, resulting in the well know problem of egg shaped circles, while it's automatically set with 2.6.31 (a new feature on this kernel version).
That's strange: from synaptics man page there should be two new options to set sensitivity on both vertical and horizontal axis (namely VertResolution and HorizResolution), but it appears that synclient does not recognize them.

This is the changelog:

Code: Select all

xserver-xorg-input-synaptics (1.1.3+git20090903~ppa1~nc10~jaunty~test1) jaunty; urgency=low

  * Update from git (commit id a629e9fb42433c01daf2278381dcf5bbe1557c16).
  * Keep the following patches from the official ubuntu karmic package:
    - 01-synaptics-dont-grab-if-not-on-current-VT.patch
    - 103_enable_cornertapping.patch
    - 104_always_enable_tapping.patch
    - 106_always_enable_vert_edge_scroll.patch
    - 112_jumpy_cursor_quirks.patch
  * debian/control: disable unneeded architectures.
  * Replace original '11-x11-synaptics.fdi' (thanks cout).
    More info at:
    http://www.voria.org/forum/showthread.php?tid=142&pid=1903#pid1903

 -- Fortunato Ventre (voRia) <email address hidden>   Sat, 05 Sep 2009 11:04:43 +0000

RE: Multitouch?

Posted: 08 Sep 2009, 10:45
by voria
In few hours will be available on my experimental repository the synaptics driver version 1.1.99.1.

Re: Multitouch?

Posted: 17 Sep 2009, 15:19
by jay
Is the only patch to this driver the different fdi? Or did you change also something in the sources (and if so: what?)?

I'd like to reproduce your steps for my gentoo installation, dmesg says that the touchpad of N510 is exactly the same:

patbook ~ # dmesg | grep Synaptics
[ 1.615668] Synaptics Touchpad, model: 1, fw: 7.2, id: 0x1c0b1, caps: 0xd04731/0xa40000
[ 1.658332] input: SynPS/2 Synaptics TouchPad as /devices/platform/i8042/serio4/input/input6

Thanks!

Re: Multitouch?

Posted: 17 Sep 2009, 15:21
by jay
OK, now I read your repository comments, if I understand right there are ubuntu patches and your changed fdi, correct? So I'll have to diff the ubuntu patches with my gentoo package - I need good luck...

Re: Multitouch?

Posted: 17 Sep 2009, 15:43
by voria
I think you can safely ignore the ubuntu patches, none of them is really needed to get full functionalities from your touchpad (most of them just modify the default values for some options).

The only useful thing is the .fdi file, it enables the touchpad to work as described by cout some post above.

Re: Multitouch?

Posted: 12 Oct 2009, 18:26
by scaltro
I've some problem with enabling multitouch...
Now i'm running last updated Karmic with your experimental repository included.

Perphaps when I try to enable two-finger scrolling from GSynaptic, it doesn't work.
And I got the same problem also modifying .fdi config file.

When I run synclinet -m 100 I got always only one finger recognized.

my netbook is a NC10 (first version).

Re: Multitouch?

Posted: 13 Oct 2009, 09:40
by voria
As reported in the above posts, it seems that NC10 has no real multitouch support.
The only way to have it is by emulating it, setting the 'EmulateTwoFingerMinZ' and 'EmulateTwoFingerMinW' options accordly.

Check this post for more info.

Re: Multitouch?

Posted: 07 Nov 2009, 20:47
by martenn
Hi,

It seems that this configuration (fdi) does not work on my n140 and unr 9.10. Touchpad seems to differ from that in nc10. Of course multitouch in n140 does not work out of the box (on WinXP zoom worked properly with two fingers).

Regards,
martenn

Re: Multitouch?

Posted: 17 Nov 2009, 13:50
by FabriceV
From Fedora 10...
Multitouch will appear... one day...

* Multi-Pointer X - The update to X.Org server 1.7 introduces the X Input Extension version 2.0 (XI2), with much work contributed by Red Hat's Peter Hutterer. This extension provides a new client API for handling input devices and also Multi-Pointer X (MPX) functionality. MPX functionality allows X to cope with many inputs of arbitrary types simultaneously, a prerequisite for (among others) multitouch-based desktops and multi-user interaction on a single screen. This is low-level work that applications and desktop environments will incrementally take advantage of in future releases. More details are available in the Release Notes and in the XI2 tag of Peter Hutterer's blog at http://who-t.blogspot.com/search/label/xi2