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

Bad axes recognition #587

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

Bad axes recognition #587

SDLBugzilla opened this issue Feb 10, 2021 · 0 comments

Comments

@SDLBugzilla
Copy link
Collaborator

SDLBugzilla commented Feb 10, 2021

This bug report was migrated from our old Bugzilla tracker.

Reported in version: 1.2.14
Reported for operating system, platform: Linux, x86

Comments on the original bug report:

On 2010-08-08 18:53:08 +0000, Mauricio Coto wrote:

Hello,

I have a Ps3 Rock Band guitar, my system recognizes all buttons ok, but it recognizes only 1 axis. So when y call an event of other axis the software prints these error:

Segmentation fault (core dumped)

I put these print in a little program:

fprintf(stdout,"Axes: %1$d", SDL_JoystickNumAxes(joystick));

Result:

Axes: 1

When i try using jstest /dev/input/js0

It prints:

Joystick (Licensed by Sony Computer Entertainment America Harmonix Guitar for PlayStation®3) has 6 axes and 13 buttons. Driver version is 2.1.0.
Testing ... (interrupt to exit)

Any clue??

On 2010-08-18 03:27:00 +0000, Markus S. wrote:

Same here but not with a PS3 guitar.

When I press on the d-pad of my game controller, any application that uses SDL
immediately crashes with a segfault.

Extreme TuxRacer prints:

%%% etracer warning: joystick y axis mapped to axis 1 but joystick only has 1 axes
Segmentation fault


# jstest /dev/input/js0
Driver version is 2.1.0.
Joystick (PS2700 Rumble Pad) has 7 axes (X, Y, Z, Rx, Rz, Hat0X, Hat0Y)
and 13 buttons (Trigger, ThumbBtn, ThumbBtn2, TopBtn, TopBtn2, PinkieBtn, BaseBtn, BaseBtn2, BaseBtn3, BaseBtn4, BaseBtn5, BaseBtn6, BtnDead).
Testing ... (interrupt to exit)
Axes:  0:-32767  1:-32767  2:-32767  3:-32767  4:-32767  5:     0  6:     0 Buttons:  0:off  1:off  2:off  3:off  4:off  5:off  6:off  7:off  8:off  9:off 10:off 11:off 12:off

On 2010-10-10 15:33:10 +0000, Sheng Long Gradilla wrote:

This problem occurs with the Linux Input Event Interface or whatever it's called. If I chmod 0000 the corresponding /dev/input/event* files for my gamepads, SDL uses the old /dev/input/js* and works fine.

Might want to check the code for handling that part.

On 2010-11-20 16:46:02 +0000, Sheng Long Gradilla wrote:

Ok, found the problem.
The fix was commited long ago by Sam Latinga, but there hasn't been a new release of SDL 1.2, so those using the latest release (1.2.14) are having problems.

We need a new release!!

Here is the patch that fixed it:
http://hg.libsdl.org/SDL/rev/42012a6afb5b

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