3

I recently bought a new Dell XPS 15 and installed Debian on it. It previously ran Windows 10, and the palm detection/rejection worked perfectly, just as I would have expected. But now, running Debian and using libinput, palm detection is (as far as I can tell) non-existant/completely broken.

Output of xinput | grep -i touchpad:

⎜   ↳ SynPS/2 Synaptics TouchPad                id=13   [slave  pointer  (2)]

Output of xinput list-props 13:

Device 'SynPS/2 Synaptics TouchPad':
    Device Enabled (116):   1
    Coordinate Transformation Matrix (118): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
    libinput Tapping Enabled (269): 1
    libinput Tapping Enabled Default (270): 0
    libinput Tapping Drag Enabled (271):    1
    libinput Tapping Drag Enabled Default (272):    1
    libinput Tapping Drag Lock Enabled (273):   0
    libinput Tapping Drag Lock Enabled Default (274):   0
    libinput Tapping Button Mapping Enabled (275):  1, 0
    libinput Tapping Button Mapping Default (276):  1, 0
    libinput Accel Speed (251): 0.000000
    libinput Accel Speed Default (252): 0.000000
    libinput Natural Scrolling Enabled (256):   0
    libinput Natural Scrolling Enabled Default (257):   0
    libinput Send Events Modes Available (236): 1, 1
    libinput Send Events Mode Enabled (237):    0, 0
    libinput Send Events Mode Enabled Default (238):    0, 0
    libinput Left Handed Enabled (258): 0
    libinput Left Handed Enabled Default (259): 0
    libinput Scroll Methods Available (260):    1, 1, 0
    libinput Scroll Method Enabled (261):   1, 0, 0
    libinput Scroll Method Enabled Default (262):   1, 0, 0
    libinput Click Methods Available (277): 1, 1
    libinput Click Method Enabled (278):    1, 0
    libinput Click Method Enabled Default (279):    1, 0
    libinput Middle Emulation Enabled (265):    0
    libinput Middle Emulation Enabled Default (266):    0
    libinput Disable While Typing Enabled (280):    1
    libinput Disable While Typing Enabled Default (281):    1
    Device Node (239):  "/dev/input/event1"
    Device Product ID (240):    2, 7
    libinput Drag Lock Buttons (267):   <no items>
    libinput Horizontal Scroll Enabled (268):   1

My /etc/X11/xorg.conf.d/40-libinput.conf file:

Section "InputClass"
        Identifier      "libinput touchpad catchall"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
        Driver          "libinput"
        Option          "Tapping"                       "on"
        Option          "TappingDrag"                   "on"
EndSection

A sample of input events generated with sudo evemu-record /dev/input/event1 >> eventlog-finger.log, using my finger on the touchpad as I do during normal usage.

A sample of input events generated with sudo evemu-record /dev/input/event1 >> eventlog-palm.log, using my palm on the touchpad as happens while I try to type.

If you look at the event logs, you'll see that ABS_TOOL_WIDTH only appears once at the beginning of each log. From what I've found, here and here, this is a (somewhat) known issue where ABS_TOOL_WIDTH is never reported as anything other than 0. This apparently breaks palm detection using synaptics drivers, and I'm assuming in libinput as well.

Trying to do anything on my laptop without plugging in an external mouse and disabling the touchpad is almost impossible, the mouse jumps and more troubling, sometimes my palm can click the touchpad, making me type somewhere unpredictable or nowhere at all.

If anyone knows anything at all as to how to even start fixing this, it would be greatly appreciated.

Edit 1:

I should mention that I have already tried using Synaptics touchpad drivers, including doing the following:

apt install -y xserver-xorg-input-synaptics
synclient PalmDetect=1

and then by messing with the following settings to no avail:

synclient PalmMinWidth=4
synclient PalmMinZ=80

I've tried everything between 0 and 15 for PalmMinWidth and 50 through 150 for PalmMinZ. Nothing works. But if it wasn't already clear - I already know that this is because ABS_TOOL_WIDTH is not reported. That much I'm sure of, and therefore that is not the basis of my question - my question pertains to how I would go about fixing the reporting of ABS_TOOL_WIDTH or another workaround that would yield a similar result.

2

Create file /etc/X11/xorg.conf.d/50-synaptics.conf with the content:

Section "InputClass"
        Identifier      "touchpad catchall"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
        Driver          "synaptics"
        Option          "PalmDetect"          "1"
        Option          "PalmMinWidth"        "5"
        Option          "PalmMinZ"            "100"
EndSection

Reboot your laptop afterwards to apply new configuration. Play with PalmMinWidth option to achieve best result - try values 3, 4 etc.

Another way is to set properties temporarily, just execute in terminal:

xinput set-prop 13 "Synaptics Palm Detection" 1
xinput set-prop 13 "Synaptics Palm Dimensions" 5, 5

Try different values for Synaptics Palm Dimensions.

Read additionally synaptics - Synaptics touchpad input driver.

  • Nope - I've already tried Synaptics drivers any it makes no difference. As I noted in my post, Synaptics Palm detectioncompletely breaks when ABS_TOOL_WIDTH isn't reported. I've tested the above settings while using Synaptics drivers and they do not work to fix palm detection. – Trevor Sears Aug 19 '18 at 17:08
  • I should also note that with Synaptics drivers you don't need to reboot the machine, if you directly edit the config file you can just restart your desktop manager (for me, lightdm, so I would use systemctl restart lightdm, but substitute in your desktop manager), or even just use synclient if you're making temporary/test changes to the touchpad driver properties. But either way, if possible you should be using libinput as it is an overall better and more well maintained driver package. – Trevor Sears Aug 19 '18 at 18:32
  • 1
    @TrevorSears I know, but one person uses lightdm, another person - gdm etc., this is the reason why I have suggested to reboot - the way is universal. – Bob Aug 19 '18 at 18:35
  • if you want a canonicalized version, you could just kill X. – Trevor Sears Aug 19 '18 at 19:44
1

Many weeks of major annoyances and I finally came to the stupidly simple solution of:

just upgrade the packages.

I downloaded the following 4 packages:

  • libinput10_1.11.3-1_amd64.deb
  • libinput-bin_1.11.3-1_amd64.deb
  • libwacom2_0.30-1_amd64.deb
  • libwacom-common_0.30-1_all.deb

And installed them with dpkg as follows:

trevor@xps:~$ cd ~/downloads/
trevor@xps:~$ sudo dpkg -i libwacom-common_0.30-1_all.deb
...dpkg runs...
trevor@xps:~$ sudo dpkg -i libwacom2_0.30-1_amd64.deb
...dpkg runs...
trevor@xps:~$ sudo dpkg -i libinput-bin_1.11.3-1_amd64.deb
...dpkg runs...
trevor@xps:~$ sudo dpkg -i libinput10_1.11.3-1_amd64.deb
...dpkg runs...

And restarted my system (restarting X should work as well). After my laptop booted back up, palm detection worked like a charm.

0

libinput does pressure-based palm detection but it needs the thresholds, see his link here: https://wayland.freedesktop.org/libinput/doc/latest/touchpad-pressure-debugging.html

That's all you can do here because the tool width is never set (though libinput doesn't look at that anyway), but chances are high that once you set the pressure in a quirk file (or hwdb if you're on libinput <= 1.11) it'll work.

File a bug please once you have identified the pressure threshold.

  • I'm fairly certain I have a really old version of libinput, I have no libinput command. – Trevor Sears Sep 4 '18 at 23:03
  • right, your version is around a year old then, which means there's a high chance it's been fixed upstream. already anway. – whot Sep 10 '18 at 3:01
  • Your answer guided me to my eventual solution - I just ended up (somewhat dangerously) directly upgrading the necessary libinput packages and their dependencies as noted in my answer. – Trevor Sears Sep 10 '18 at 17:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.