Input: ads7846 - debouncing and rudimentary sample filtering
Some touchscreens seem to oscillate heavily for a while after touching the screen. Implement support for sampling the screen until we get two consecutive values that are close enough. Signed-off-by: Imre Deak <imre.deak@nokia.com> Signed-off-by: Juha Yrjola <juha.yrjola@nokia.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
This commit is contained in:
committed by
Dmitry Torokhov
parent
53a0ef89e9
commit
0b7018aae7
@@ -14,5 +14,8 @@ struct ads7846_platform_data {
|
||||
u16 x_min, x_max;
|
||||
u16 y_min, y_max;
|
||||
u16 pressure_min, pressure_max;
|
||||
|
||||
u16 debounce_max; /* max number of readings per sample */
|
||||
u16 debounce_tol; /* tolerance used for filtering */
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user