0 votes
asked by (12 points)

Summary: X-Plane 10 doest not detect joystick on Linux

Symptoms:

Device is not available in X-Plane 10, "Axis" screen is empty.

Hardware tested:

  • Bus 001 Device 011: ID 046d:c20d Logitech, Inc. WingMan Attack 2
  • Bus 001 Device 010: ID 06a3:0762 Saitek PLC Saitek X52 Pro Flight Control System
  • Bus 001 Device 009: ID 06a3:0763 Saitek PLC Pro Flight Rudder Pedals

Steps taken:

  • Every tested hardware creates /dev/input/jsX device.
  • Every hardware has correct permissions (problem exists after chmod 777 /dev/input/js*).

$ ls -la /dev/input/js0
crwxrwxrwx 1 root input 13, 0 Nov 13 13:19 /dev/input/js0

  • Every hardware has been tested with jstest - all axes are usable.

$ jstest /dev/input/js0
Driver version is 2.1.0.
Joystick (Saitek Saitek Pro Flight Rudder Pedals) has 3 axes (X, Y, Rz)
and 0 buttons ().
Testing ... (interrupt to exit)
Axes:  0:-32767  1:-32767  2:     0

  • When running Steam under strace, the following is reported about /dev/js0:

[pid 21283] open("/dev/input/js0", O_RDONLY <unfinished ...>
[pid 21283] <... open resumed> )        = 85
[pid 21283] ioctl(85, 0x80804506, 0xffc09058) = -1 EINVAL (Invalid argument)
[pid 21283] close(85 <unfinished ...>
[pid 21283] <... close resumed> )       = 0

 

commented by (10 points)
This may be a problem unique to Linux.  But under Windows (3.1, 7, and 8.1) I have a pair of CH Pro Pedals that are never initialized on boot.  If I unplug / plug them in, they work fine, so that is part of my pre-flight check - calibrate all controllers.  I don't know if it is a function of the pedals or if there is a USB port initialization limit on boot.
commented by (12 points)
I've tried every possible connect/disconnect pattern without any success. However - thanks for your reply!

1 Answer

0 votes
answered by (148 points)
X-Plane does not use /dev/input/jsX for joystick input - we use the more modern /dev/input/eventX interfaces.

Therefore, no amount of testing or permissions hacking on js0 will help with this problem.

Check file permissions on /dev/input/eventX - if the raw event interface for your joystick is not user-accessible (e.g. it requires root permissions) _do not_ run X-Plane sudo.  You'll need to edit your udev rules.

http://developer.x-plane.com/2012/09/linux-joystick-permissions/

If it turns out that the udev rules that ship with your distro make eventN for your gaming hardware unavailable to regular users, I strongly encourage you to file a bug with the distro.  Things are going to remain user-hostile in Linux until you can do things like use the full event interface with consumer hardware without special permissions.

(And to answer the question as to why we use event and not js, it's because we want a more fine grained and detailed view of the joystick, so that when we implement automatic axis assignment and other features, they "just work" on Linux instead of having Linux be a second-class citizen.)
commented by (14 points)
for me with my CH-Pro gear I've had to create a Udeve rule as per http://thegnuflyer.blogspot.co.uk/2014/12/ch-pro-pedals-and-linux-x-plane.html

once that is in place and rebooted they work without fail

Welcome to X-Plane Q&A, where you can ask support questions and get answers from members of the community.

This site is for X-Plane support questions only. Please search for existing answers before posting your question. Off-topic questions will be locked.

If you’re new, you’ll need to register before asking your first question.

If your question is answered, click on the check mark to select the best response.

Categories

...