Re: [PATCH 5/7] elantech: report position also with 3 fingers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Eric,

On Mon, Jun 21, 2010 at 11:07:24PM +0200, Éric Piel wrote:
> 
> The 6-byte protocol supports reporting the position when three fingers
> are pressed, exactly like when one finger is pressed. Report this.
> 
> In addition, it is also distinguishes between 3 and 4 fingers pressed.
> 
> Signed-off-by: Éric Piel <eric.piel@xxxxxxxxxxxxxxxx>
> ---
>  drivers/input/mouse/elantech.c |   10 ++++++++++
>  1 files changed, 10 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/input/mouse/elantech.c b/drivers/input/mouse/elantech.c
> index b09b458..633f100 100644
> --- a/drivers/input/mouse/elantech.c
> +++ b/drivers/input/mouse/elantech.c
> @@ -257,6 +257,14 @@ static void elantech_report_absolute_v2(struct psmouse *psmouse)
>  	input_report_key(dev, BTN_TOUCH, fingers != 0);
>   	switch (fingers) {
> +	case 3:
> +		/*
> +		 * Same as one finger, except report of more than 3 fingers:
> +		 * byte 3:  n4  .   w1  w0   .   .   .   .
> +		 */
> +		if (packet[3] & 0x80)
> +			fingers = 4;
> +		/* pass through... */

Are we certain it is 4-finger and not equivalent of "palm detect" flag?
I could not locate the equivalent in Ubutu sources, where did you get
this data?

-- 
Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux