Oolite Bulletins

For information and discussion about Oolite.
It is currently Thu Sep 21, 2017 8:27 am

All times are UTC




Post new topic  Reply to topic  [ 10 posts ] 
Author Message
PostPosted: Fri Sep 25, 2015 10:28 pm 
Offline
Mostly Harmless
Mostly Harmless

Joined: Fri Sep 25, 2015 10:11 pm
Posts: 3
I have sussed this issue out, it all comes down to SDL, and the quick fix is:-
Quote:
I added the following line to my /etc/environment:-
Code:
SDL_JOYSTICK_DEVICE="/dev/input/js0"
and everything now works as expected.
Original thread below
####################################

Hi all, first post here as I'm having issues with my joystick.

When I push my joystick hard left, the roll indicator on the HUD only shows it as halfway to the left. When I push right, it shows full right.

Likewise, when going full back, the pitch indicator only shows it as halfway back, but going fully forward shows it as full.


I've tried using both jscal & jstest-gtk to calibrate the stick, and jstest-gtk shows it going full range on all axis' (axises?) - however when I go into Oolite I'm not getting the same response.


Has anyone else had this issue? Is there something I'm missing?

Only way to escape anyone is diving to the right at the moment!

I've had a look through these forums but can't see anybody having the same problems...

Thanks in advance,
Category


Last edited by Getafix on Thu Oct 01, 2015 7:24 am, edited 2 times in total.
Updated the 'Solved' tag format


Top
   
PostPosted: Sat Sep 26, 2015 1:28 pm 
Offline
Sharp Shooter Spam Assassin
Sharp Shooter Spam Assassin
User avatar

Joined: Sat Jul 04, 2009 9:31 pm
Posts: 12774
Location: Corke's Drift
Welcome aboard, Commander - hopefully, a joystick-aware penguinista will be along at some time.

_________________
The only good fnord is a dead fnord!


Top
   
PostPosted: Sat Sep 26, 2015 5:03 pm 
Offline
Retired Assassin
Retired Assassin
User avatar

Joined: Tue Feb 09, 2010 11:31 am
Posts: 8282
Location: Disunited Kingdom
<grabs joystick and puts penguin suit on...>
Not much help here I'm afraid, other than 'old age' effects my joystick is working fine on Mint 17.1. I hope somebody more helpful comes along soon.

_________________
Commander Smivs, the friendliest Gourd this side of Riedquat.


Top
   
PostPosted: Sun Sep 27, 2015 9:37 am 
Offline
Commodore
Commodore
User avatar

Joined: Thu Nov 07, 2013 10:21 pm
Posts: 281
Working fine here, too. I did wonder if precision mode was borked and only working on half of each axis, but that's working as well.

You haven't got anything weird set up in your joystick profiles, have you?


Top
   
PostPosted: Mon Sep 28, 2015 8:11 pm 
Offline
Mostly Harmless
Mostly Harmless

Joined: Fri Sep 25, 2015 10:11 pm
Posts: 3
Well, I can't seem to find the issue. Before calibrating my joystick in jstest-gtk, it does seem to have the same dead areas as in game... Which leads me to believe that Oolite is paying no attention to calibration settings at all, and just taking the raw values.

As a workaround though, I've done some editing of the splines in Oolite to get something approximating this:-

Image
(Apologies for dodgy picture, can't upload from the PC at the moment)

This workaround allows me to get full range on the stick, however going right or diving now hits full range at around 60% movement on the stick. Not perfect, but at least I can pull up and roll left fully!

So if Oolite does just use raw joystick input, is there an internal calibration tool anywhere?

Or is there a different linux calibration app I should be using for Oolite to pick up the changes?


Top
   
PostPosted: Tue Sep 29, 2015 8:50 pm 
Offline
Mostly Harmless
Mostly Harmless

Joined: Fri Sep 25, 2015 10:11 pm
Posts: 3
I've done a lot more digging now, as my dirty hack of a workaround generally sucked. However, after lots of digging I found the culprit - SDL.

Where jscal and the kernel usb joystick drivers calibrated, and gave me proper response, SDL itself was still getting raw input from the evdev device drivers. With one environment variable (either in /etc/environment file, or .bashrc startup script), you can force SDL to use the "real" joystick driver for input.

I added the following line to my /etc/environment:-
Code:
SDL_JOYSTICK_DEVICE="/dev/input/js0"
and everything now works as expected.

This single line has solved all my issues - might be worth adding to the wiki?

I suggest anyone having similar calibration issues to do the same!


Top
   
PostPosted: Wed Sep 30, 2015 1:50 am 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon Apr 06, 2009 12:20 pm
Posts: 6178
Location: Aboard the Pitviper S.E. "Blackwidow"
Congratulations on the fix!
Quote:
after lots of digging I found the culprit - SDL.
Ahh.. now that I check, yes, SDL has been implicated in a number of Linux joystick issues..
Quote:
This single line has solved all my issues - might be worth adding to the wiki?
Good idea.. I'll see about making up an entry for it.

_________________
Most games have some sort of paddling-pool-and-water-wings beginning to ease you in: Oolite takes the rather more Darwinian approach of heaving you straight into the ocean, often with a brick or two in your pockets for luck. ~ Disembodied


Top
   
PostPosted: Wed Sep 30, 2015 5:38 am 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon Apr 06, 2009 12:20 pm
Posts: 6178
Location: Aboard the Pitviper S.E. "Blackwidow"
I've made a Wiki page on the subject.. borrowing from your description of the probable cause. See what you think:

http://wiki.alioth.net/index.php/Joysti ... ms_(Linux)

I've also added a link to it on the Wiki's [EliteWiki] Oolite Instruction Manual page.

_________________
Most games have some sort of paddling-pool-and-water-wings beginning to ease you in: Oolite takes the rather more Darwinian approach of heaving you straight into the ocean, often with a brick or two in your pockets for luck. ~ Disembodied


Top
   
PostPosted: Thu Oct 01, 2015 1:50 am 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Wed Aug 08, 2007 10:59 pm
Posts: 545
Location: Netherlands
Added a note to Discusssion for that wiki page.

_________________
OS : Arch Linux 64-bit - rolling release

OXPs : My user page

I am subscribed to the threads for my oxps, if you need my attention just post in them or send a pm.


Top
   
PostPosted: Thu Oct 01, 2015 3:11 am 
Offline
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Mon Apr 06, 2009 12:20 pm
Posts: 6178
Location: Aboard the Pitviper S.E. "Blackwidow"
Quote:
Added a note to Discusssion for that wiki page.
Thanks, Lone_Wolf. I've added an entry for that case now.

_________________
Most games have some sort of paddling-pool-and-water-wings beginning to ease you in: Oolite takes the rather more Darwinian approach of heaving you straight into the ocean, often with a brick or two in your pockets for luck. ~ Disembodied


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 10 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
cron
Powered by phpBB® Forum Software © phpBB Limited