linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Frank Praznik <frank.praznik@gmail.com>
To: simon@mungewell.org, Frank Praznik <frank.praznik@oh.rr.com>,
	HID CORE LAYER <linux-input@vger.kernel.org>,
	Jiri Kosina <jkosina@suse.cz>
Subject: Re: Bug: HID-Sony: DS4 touch-pad corrupts Axis0
Date: Mon, 21 Apr 2014 13:30:46 -0400	[thread overview]
Message-ID: <535555C6.5050407@gmail.com> (raw)
In-Reply-To: <23e61b7ee30edafb338935ae40285dce.squirrel@mungewell.org>

On 4/21/2014 12:49, simon@mungewell.org wrote:
> Hi,
> I've noticed a glitch with the Dualshock4 on 3.15rc1 (plus LEDs patch, if
> that makes a difference).
>
> Sometimes everything works as expected, the thumbsticks work OK and the
> touch-pad changes axis 15 & 16 (as reported by jstest). Other times axis
> 15 and 16 do not report changes, instead axis 0 is corrupted/changed when
> the touch-pad is 'swiped'.
>
> Evtest appears to report correctly all the time.
>
> It seems that the controller works first time it is plugged in (after
> boot), but then fails subsequent times. I think that the first time I
> don't get the pop-up message about battery being charged, which occurs on
> other times.
>
> I have not found a trigger yet, but was wondering whether others are
> seeing this. I am using a USB connected DS4 (no BT on this machine). OS is
> Xubuntu 13.10 with patched kernel,
> Simon.
>
> --
> simon@slipstream:~$ jstest /dev/input/js0
> Driver version is 2.1.0.
> Joystick (Sony Computer Entertainment Wireless Controller) has 14 axes (X,
> Y, Z,
> and 14 buttons (BtnX, BtnY, BtnZ, BtnTL, BtnTR, BtnTL2, BtnTR2, BtnSelect,
> BtnSt
> Testing ... (interrupt to exit)
> --
> Apr 21 10:21:01 slipstream kernel: [  818.052095] usb 5-1: USB disconnect,
> devic
> Apr 21 10:21:33 slipstream kernel: [  849.684027] usb 5-1: new full-speed
> USB de
> Apr 21 10:21:33 slipstream kernel: [  849.855036] usb 5-1: New USB device
> found,
> Apr 21 10:21:33 slipstream kernel: [  849.855041] usb 5-1: New USB device
> string
> Apr 21 10:21:33 slipstream kernel: [  849.855045] usb 5-1: Product:
> Wireless Con
> Apr 21 10:21:33 slipstream kernel: [  849.855049] usb 5-1: Manufacturer:
> Sony Co
> Apr 21 10:21:33 slipstream kernel: [  849.861096] sony
> 0003:054C:05C4.0005: Usin
> Apr 21 10:21:33 slipstream kernel: [  849.906141] input: Sony Computer
> Entertain
> Apr 21 10:21:33 slipstream kernel: [  849.906344] sony
> 0003:054C:05C4.0005: inpu
> --
>
>

I've seen this before and it's a bug in jstest and jstest-gtk, not the 
driver or event system.  These programs do their own internal axis 
mapping and don't properly handle axes above ABS_MISC which is where the 
touch axes are.  jstest-gtk just default maps these to 0 and the old 
jstest just doesn't look like it does any bounds checking at all.

  parent reply	other threads:[~2014-04-21 17:31 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-21 16:49 Bug: HID-Sony: DS4 touch-pad corrupts Axis0 simon
2014-04-21 17:18 ` simon
2014-04-21 17:30 ` Frank Praznik [this message]
2014-04-21 20:16   ` Frank Praznik
2014-04-22 16:50     ` simon
2014-04-22 17:31       ` Frank Praznik
2014-04-23  3:21         ` simon

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=535555C6.5050407@gmail.com \
    --to=frank.praznik@gmail.com \
    --cc=frank.praznik@oh.rr.com \
    --cc=jkosina@suse.cz \
    --cc=linux-input@vger.kernel.org \
    --cc=simon@mungewell.org \
    /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).