Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dualshock 3's motion sensors overwrite analog stick #759

Closed
SDLBugzilla opened this issue Feb 10, 2021 · 0 comments
Closed

Dualshock 3's motion sensors overwrite analog stick #759

SDLBugzilla opened this issue Feb 10, 2021 · 0 comments

Comments

@SDLBugzilla
Copy link
Collaborator

This bug report was migrated from our old Bugzilla tracker.

These attachments are available in the static archive:

Reported in version: 1.2.15
Reported for operating system, platform: Linux, x86_64

Comments on the original bug report:

On 2015-12-03 16:40:26 +0000, wrote:

Created attachment 2320
src/joystick/linux/SDL_sysjoystick.patch

The Dualshock 3's motion sensors don't seem to be reported by the call to EVIOCGBIT but they still send EV_ABS events. Because they're not reported by EVIOCGBIT they're not assigned a proper axis ids and the default of 0 is used, which is the valid id for the left analog sticks left/right axis.

The attached patch sets the default axis id to ABS_MAX, and then checks the axis id before performing the update. This will protect against EV_ABS events for axes that aren't reported or handled correctly.

On 2018-07-31 10:51:17 +0000, Ozkan Sezer wrote:

Created attachment 3275
linux sys_joystick patch

The original patch does not apply because it is whitespace-mangled.
Attaching a one that applies to current SDL-1.2 branch.

Has anyone tried this anyway?

On 2018-08-07 03:13:12 +0000, wrote:

I only know of one other person to use the patch and it seemed to fix their problem as well (https://forums.pcsx2.net/Thread-OnePAD-Dualshock-3-on-Linux?pid=490821#pid490821).

Considering that this bug report and patch is over 3 years old now, I don't know if the problem still persists for the Dualshock 3. Maybe the motion sensors are correctly reported now, I don't have a setup to test with currently.

In general though the patch protects against any axis that isn't reported by EVIOCGBIT but still sends EV_ABS events; It's not specific to the Dualshock 3.

On 2018-08-07 07:10:50 +0000, Ozkan Sezer wrote:

This patch is in: https://hg.libsdl.org/SDL/rev/3e05d58dc84f

Thanks. Closing as fixed.

On 2018-11-14 21:38:17 +0000, Sam Lantinga wrote:

This is fixed for SDL 2.0 here:
https://hg.libsdl.org/SDL/rev/a7ee81795c75

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant