We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 657 - sdl fakes stuck joystick
Summary: sdl fakes stuck joystick
Status: RESOLVED INVALID
Alias: None
Product: SDL
Classification: Unclassified
Component: joystick (show other bugs)
Version: HG 1.2
Hardware: x86 Linux
: P2 normal
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords: target-1.2.14
Depends on:
Blocks:
 
Reported: 2008-12-27 01:13 UTC by Sam Liddicott
Modified: 2009-09-14 00:46 UTC (History)
0 users

See Also:


Attachments
stk steering stuck (30.01 KB, text/plain)
2008-12-27 01:31 UTC, Sam Liddicott
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sam Liddicott 2008-12-27 01:13:22 UTC
supertuxkart 0.5 and 0.6rc1 have had a problem pinned down to libsdl where libsdl reports a joystick axis stuck hard right or left.

When quiting supertuxkart when it is stuck and running jstest it shows not-stuck which suggests an sdl problem.

The in-game "fix" is to steer in the stuck direction which releases it. Steering opposite does not fix the stuckness but does cause the kart to steer in the correct direction (whether stuck on left or right). 

This seems to suggest a "default" axis value that can be overridden by a real position (left or right). 

I have the problem with a Saitek 8 axis gamepad and a and Logic3 8 axis rumble gamepad.

See: http://forum.freegamedev.net/index.php?t=msg&th=1088&goto=15407#msg_15407 and the whole thread.

Is there any debugging I can do against libsdl to see what is being read from /dev/input/js? 

I'll do some more tests with --gamepad-debug on supertuxkart and see if I can get any intermediate values when stuck by moving partly in the reverse-stuck direction, and see what value same-stuck-direction fix it.
Comment 1 Sam Liddicott 2008-12-27 01:31:20 UTC
Created attachment 285 [details]
stk steering stuck

Shows steering get stuck to 32767 (hard right).
Can be overridden to varying left values but doesn't go to 0.
[reads log again before posting]
Interesting pair of lines:
axis motion: which 0 axis 3 value 0
steering: steer_val 32767   set to: 0.848000

suggest perhaps a supertuxkart bug after all..., I'll point them to this bug to comment on
Comment 2 Ryan C. Gordon 2009-09-13 16:33:18 UTC
Tagging this bug with "target-1.2.14" so we can try to resolve it for SDL 1.2.14.

Please note that we may choose to resolve it as WONTFIX. This tag is largely so we have a comprehensive wishlist of bugs to examine for 1.2.14 (and so we can close bugs that we'll never fix, rather than have them live forever in Bugzilla).

--ryan.
Comment 3 Sam Liddicott 2009-09-14 00:27:39 UTC
Sam Liddicott (who was having Bugzilla login problems at the time), sent me this email...

> This bug was fixed in 0.6, see: 
> http://www.headshotgamer.com/review.aspx?id=106
> 
> "** Fixed 'joystick locks' (kart would turn even if the joystick is in 
> neutral), thanks to Samjam for the patch."

...so I'm closing this as INVALID, as it wasn't an SDL issue.

--ryan.
Comment 4 Ryan C. Gordon 2009-09-14 00:46:06 UTC
(err, and when fixing his login, I forgot to change back to my user, so that last comment from Sam is really from me. Sorry about that.)

--ryan.