1. 13 Jun, 2018 1 commit
  2. 29 May, 2018 1 commit
  3. 18 May, 2018 1 commit
  4. 01 Mar, 2018 3 commits
  5. 21 Feb, 2018 2 commits
    • Peter Hutterer's avatar
      touchpad: delay arbitration by 90ms after touch toggle · 2a378bea
      Peter Hutterer authored
      When drawing on a tablet, the hand usually rests on the device, causing touch
      events. The kernel arbitrates for us in most cases, so we get a touch up
      and no events while the stylus is in proximity. When lifting the hand off in a
      natural position, the hand still touches the device when the pen goes out of
      proximity. This is 'immediately' followed by the hand lifting off the device.
      
      When kernel pen/touch arbitration is active, the pen proximity out causes a
      touch begin for the hand still on the pad. This is followed by a touch up when
      the hand lifts which happens to look exactly like a tap-to-click.
      
      Fix this by delaying the 'arbitration is now off' toggle, causing any touch
      that starts immediately after proximity out to be detected as palm and
      ignored for its lifetime.
      
      https://bugs.freedesktop.org/show_bug.cgi?id=104985Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      2a378bea
    • Peter Hutterer's avatar
      touchpad: change the stylus palm arbitration to process touches · da74aab7
      Peter Hutterer authored
      Previously, on touch toggle (invoked by the tablet when a pen goes in
      proximity) the touchpad cleared the state and ignored any events. Since we
      ignore touches that we didn't see the touch begin for, this handled the cases
      of a touch remaining after proximity out.
      
      This code pre-dates palm detection, so let's take the bluetack off and instead
      integrate it with proper palm detectino.
      da74aab7
  6. 20 Feb, 2018 1 commit
  7. 10 Jan, 2018 1 commit
    • Peter Hutterer's avatar
      touchpad: drop the double normalization · 937e6031
      Peter Hutterer authored
      Previously, touchpad deltas were converted to 1000-dpi normalized coordinates
      and handled from there. This changed in bdd4264d (1.6)
      when the filter functions started taking device coordinates instead. Since
      then, we used to convert the device delta to normalized coordinates, then
      (often immediately) convert back to device coordinates, albeit for equal x/y
      resolution. This isn't necessary, we can just convert the device coordinates
      to x/y-equal resolution device coordinates and pass those on.
      Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      937e6031
  8. 20 Nov, 2017 1 commit
    • Peter Hutterer's avatar
      touchpad: work palm detection into the tap state machine · 46eab975
      Peter Hutterer authored
      Unlike the already-existing thumb detection, a touch may be labelled palm at
      any time, not just during the initial touch down. This requires full
      integration into the tap state machine to unwind properly. For most states, a
      palm detection simply ignores the finger and reverts to the most recent state.
      
      One exception is the case of two fingers down, one finger up followed by the
      remaining finger detected as a palm finger. This triggers a single-finger tap
      but with timestamps that may be from the wrong finger. Since we're within a
      short tap timeout anyway this should not matter too much.
      
      The special state PALM_UP is only handled in one condition (DEAD). Once a
      touch is a palm we basically skip over it from then on. If we end up in the
      DEAD state after a button press we still need to handle the palm up events
      accordingly to be able to return to IDLE. That transition also requires us to
      have an accurate count of the real fingers down (palms don't count) so we need
      a separate nfingers_down counter for tapping.
      
      https://bugs.freedesktop.org/show_bug.cgi?id=103210Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      46eab975
  9. 31 Oct, 2017 1 commit
  10. 30 Oct, 2017 3 commits
  11. 05 Sep, 2017 1 commit
  12. 04 Sep, 2017 1 commit
  13. 01 Sep, 2017 2 commits
  14. 11 Jul, 2017 2 commits
  15. 09 Jul, 2017 1 commit
  16. 03 Jul, 2017 1 commit
    • Peter Hutterer's avatar
      touchpad: add pressure-base palm detection · 25d54b90
      Peter Hutterer authored
      If a touch goes past the fixed pressure threshold it is labelled as a palm and
      stays a palm. Default value is one that works well here on a T440 and is
      virtually impossible to trigger by a normal finger or thumb. A udev property
      is exposed so we can handle this in the udev hwdb and the new tool introduce a
      few commits ago can help finding the palm detection threshold.
      
      Unlike the other palm detection features, once a palm goes past the threshold
      it remains a palm until the touch is released. This means palm overrides any
      other palm detection features. For code simplicity, we don't combine the
      states but merely check for pressure before and after the other palm detection
      functions. If the pressure triggers, it will trigger before anything else. And
      if something else is already active (e.g. edge where the pressure doesn't work
      well) it will trigger as soon as the palm is released.
      
      The palm threshold should thus be chosen with some room to spare between the
      highest finger pressure.
      
      https://bugs.freedesktop.org/show_bug.cgi?id=94236Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      25d54b90
  17. 21 Jun, 2017 1 commit
  18. 17 May, 2017 1 commit
  19. 28 Apr, 2017 1 commit
  20. 26 Apr, 2017 1 commit
  21. 21 Apr, 2017 1 commit
  22. 30 Jan, 2017 2 commits
    • Peter Hutterer's avatar
      evdev: improve type-safety on dispatch switches · 60de087e
      Peter Hutterer authored
      Set the dispatch type on creation, then check that whenever we try to get the
      dispatch struct. This avoids a potential mismatch between the backends.
      
      Plus, use of container_of means we're not dependent on the exact layout
      anymore.
      Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      60de087e
    • Peter Hutterer's avatar
      touchpad: use pressure values for touch is-down decision · 568d527c
      Peter Hutterer authored
      Don't rely on BTN_TOUCH for "finger down", the value for that is hardcoded in
      the kernel and not always suitable. Some devices need a different value to
      avoid reacting to accidental touches or hovering fingers.
      
      Implement a basic Schmitt trigger, same as we have in the synaptics driver. We
      also take the default values from there but these will likely see some
      updates.
      
      A special case is when we have more fingers down than slots. Since we can't
      detect the pressure on fake fingers (we only get a bit for 'is down') we
      assume that *all* fingers are down with sufficient pressure. It's too much of
      a niche case to have this work any other way.
      
      This patch drops the handling of ABS_DISTANCE because it's simply not needed
      anymore.
      Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      568d527c
  23. 26 Jan, 2017 2 commits
  24. 23 Jan, 2017 1 commit
  25. 14 Dec, 2016 1 commit
  26. 29 Nov, 2016 1 commit
  27. 12 Sep, 2016 1 commit
  28. 07 Sep, 2016 1 commit
    • Peter Hutterer's avatar
      tablet: add touch arbitration · b519ea4a
      Peter Hutterer authored
      So far we've relied on the wacom kernel module to do touch arbitration for us
      but that won't be the case in upcoming kernels. Implement touch arbitration in
      userspace by pairing the two devices and suspending the touch device whenever
      a tool comes into proximity.
      
      In the future more sophisticated arbitration can be done (e.g. only touches
      which are close to the pen) but let's burn that bridge when we have to cross
      it.
      
      Note that touch arbitration is "device suspend light", i.e. we leave the
      device enabled and the fd is active. Tablet interactions are comparatively
      short-lived, so closing the fd and asking logind for a new one every time the
      pen changes proximity is suboptimal. Instead, we just keep a boolean around
      and discard all events while it is set.
      Signed-off-by: Peter Hutterer's avatarPeter Hutterer <peter.hutterer@who-t.net>
      Reviewed-by: Jason Gerecke's avatarJason Gerecke <jason.gerecke@wacom.com>
      b519ea4a
  29. 14 Aug, 2016 1 commit
  30. 04 Aug, 2016 1 commit
  31. 20 Jul, 2016 1 commit