Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Joystick Initialization in Linux

A topic by N[]NE created Dec 26, 2016 Views: 2,418 Replies: 12
Viewing posts 1 to 6
(2 edits)

The first time I start FPV Freerider with a transmitter I have just plugged in, everything is off center. Then if I close out and restart, everything centers perfectly. This happens with both of my transmitters. It only happens in the Linux version of FPV Freerider and Recharged.

Developer

Thanks for reporting. That's a weird thing, I will keep it in mind in case I manage to find out what might be the cause.

(+1)

To support this, I've also had this anomaly happen in Debian. Have not thoroughly tested the order of operations to find a cause, as the reload generally works.

Same here. Would be nice to know what library the game is using to manage the joystick. Evdev? SDL?

Been thinking about this for a few days as I notice that when I set calibration via /dev/input/js0, the calibration and the mappings are not observed in FPVF.

Developer (2 edits)

Seems like a pretty common problem on Linux. I use Unity for development and basically just have to hope that it works on the different Linux distributions (I'm not a Linux user myself). I tried to search around for more info on this issue but I couldn't really find much. Hopefully some Linux guru will be able to chime in.

Here's one thing a found:

"Had the same issue on two other Unity-games. There is a simple workaround that worked for those games and might work [..]

- You need to callibrate (move the analogs around) before starting the game.

Just do a couple of circles with the analog sticks before starting the game and it should be fine.
As i understand it it's a bug with Unity's controller library under Linux.
"

Thanks. I'll look into what Unity is using (probably SDL). Just thought it was odd that I couldn't actually SEE the data stream anywhere I'd normally look. I figured it had to be evdev, but nada.

Developer

Ok, it will be interesting to hear if you manage to figure something out.

(1 edit)

Moving the sticks around doesn't do anything unless an application is "looking at" them. Either FPV Freerider or jstest-gtk needs to be running in order to recenter the sticks. This is what I have been doing. Move the sticks around and then close and (re)start FPV Freerider.

If I run jstest-gtk first and move the sticks around, then run FPV Freerider, it initializes just fine, but that isn't really a true fix. As long as something initializes the transmitter before running Freerider it works just fine.

Hi,

I have just install FPV freerider however on a fresh Ubuntu 17.04 instal, my transmitter is not working, no signal seemed to be detected.
The transmitter works well: FPV freerider has no issue with it when I tested on Windows; It appears as expected in /dev/input/js0 and also creates an entry in /dev/input/by-id/usb-xxx-event-if00; jstest-gtk works great; Velocidrone is recongnising the transmitter correctly(on the same ubuntu install).
The log only says:
Desktop is 1920 x 1080 @ 60 Hz
Using libudev for joystick management
Importing game controller configs
UnloadTime: 1.813000 ms

Any ideas on where the issue could be or how do I get debug information?
Thanks!
Fabien

After some research, as someone mentioned, some buttons must be emulated otherwise the controller is not recognised by FPVfreerider.

To do that, use the wejoy : https://github.com/Vantskruv/w... and calibrate the original joystick with jscal to get rid of deadzone. Then FPVfreerider is working like a charm!

Developer

Thanks for reporting back. I'm glad you found the solution, I'm sure it will be of help to others!

Anybody with wejoy  config file? I got working just 2 axes.