linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: chris@cnpbagwell.com
Cc: linux-input@vger.kernel.org, pingc@wacom.com
Subject: Re: [PATCH 3/4] input: wacom - Add support for Bamboo Pen
Date: Wed, 8 Sep 2010 21:14:22 -0700	[thread overview]
Message-ID: <20100909041422.GA11747@core.coreip.homeip.net> (raw)
In-Reply-To: <1284004952-12701-4-git-send-email-chris@cnpbagwell.com>

On Wed, Sep 08, 2010 at 11:02:31PM -0500, chris@cnpbagwell.com wrote:
> From: Chris Bagwell <chris@cnpbagwell.com>
> 
> This adds support for Pen on Bamboo Pen and Bamboo Pen&Touch
> devices.  Touchpad is handled by previous Bamboo Touch
> logic.
> 
> Signed-off-by: Chris Bagwell <chris@cnpbagwell.com>
> ---
>  drivers/input/tablet/wacom_wac.c |   75 ++++++++++++++++++++++++++++++++++++++
>  1 files changed, 75 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
> index 2f7ed9a..9cc0cf0 100644
> --- a/drivers/input/tablet/wacom_wac.c
> +++ b/drivers/input/tablet/wacom_wac.c
> @@ -904,10 +904,71 @@ static int wacom_bpt_touch(struct wacom_wac *wacom)
>  	return 0;
>  }
>  
> +static int wacom_bpt_pen(struct wacom_wac *wacom)
> +{
> +	struct input_dev *input = wacom->input;
> +	unsigned char *data = wacom->data;
> +	int prox = 0, x = 0, y = 0, p = 0, d = 0, pen = 0, btn1 = 0, btn2 = 0;
> +
> +	prox = (data[1] & 0x10) && (data[1] & 0x20);

	prox = (data[1] & 0x30) == 0x30;

?

-- 
Dmitry

  reply	other threads:[~2010-09-09  4:14 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-09  4:02 [PATCH 0/4] input: wacom - And Bamboo Pen Support chris
2010-09-09  4:02 ` [PATCH 1/4] input: wacom - Request tablet data for Bamboo Pens chris
2010-09-09  4:02 ` [PATCH 2/4] input: wacom - move Bamboo Touch irq to own function chris
2010-09-09  4:02 ` [PATCH 3/4] input: wacom - Add support for Bamboo Pen chris
2010-09-09  4:14   ` Dmitry Torokhov [this message]
2010-09-09 21:34     ` Chris Bagwell
2010-09-09 21:46       ` Dmitry Torokhov
2010-09-10  3:02         ` Chris Bagwell
2010-09-10  8:28           ` Ping Cheng
2010-09-09  4:02 ` [PATCH 4/4] input: wacom - disable Bamboo touchpad when pen is being used chris

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100909041422.GA11747@core.coreip.homeip.net \
    --to=dmitry.torokhov@gmail.com \
    --cc=chris@cnpbagwell.com \
    --cc=linux-input@vger.kernel.org \
    --cc=pingc@wacom.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).