]> git.baikalelectronics.ru Git - kernel.git/commit
Input: appletouch - improve finger detection
authorJeremy Huddleston <jeremyhu@freedesktop.org>
Wed, 3 Jun 2009 14:29:39 +0000 (07:29 -0700)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Wed, 3 Jun 2009 14:37:54 +0000 (07:37 -0700)
commit9ce4c7f3d968e41af8919b93b6266290bb6f9ed8
tree7a502c2946359809e3739a7c0f32e1ffcf04373a
parent5056474d1d69c99099810d9910f1f77245ee5fb5
Input: appletouch - improve finger detection

The appletouch driver is prone to reporting multiple fingers when only
one is pressing.  The appletouch driver queries an array of pressure
sensors and counts local maxima in pressure to determine the number of
fingers.  It just does this on the raw values, so a data stream like:

0 100 250 300 299 300 250 100 0

actually registers as 2 fingers.

This patch updates the logic to ignore small dips in pressure that are
less than the threshold.

Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
drivers/input/mouse/appletouch.c