I couldn't find any better place to post this - oh beloved ninjas! Give this naive a scratchpad!!
This is my current rundown on the linux HID (human interface devices) situation, relative to
the crossover-games situations and the games titles that can/use things like joysticks etc etc...
Mouse and keyboard always work mostly, sometimes a 8 buttoned mouse would be handy...
Firstly -- the game title itself => be considerate of the fact that many (older) game titles,
may have only ever been programmed for keyboard/mouse/analog|digital joysticks...(the ones
that used to plug into your 'gameport' on older model soundcards/mainboards). This was of
course long before the advent of the USB ports. Although 'certain measures' are taken into
account within the linux driver codes here, to offer some form of 'backwards compatibility'
with older style HID events, YMMV wildly depending on what the actual game itself, is coded
to understand....ie; an axis of RX-yaxis is complete nonsense to some games. With this in
mind, and sometimes in very extra-ordinary cases, you might find a game *.ini file you can
manually edit to accept different event names...again, YMMV and luck required...
Note: [u]You'll need get/install the linux joystick-tools package for this lot below. Most
mainstream distros have a package for such.[/u]
-
'Standard' 2 axis / 4 button / HAT / throttle-wheel gameport joystick. I've not had any
issues with these at all, except in some cases where the button functions aren't mapped
the way I'd like them - you can change this by reading this test. -
Same as above, but USB connected. Not as good responsive wise compared to the above,
a bit too abrupt or quick...hard to explain. If you can lower the sensitivity in the
game options themselves, that helps.
[todo: cal procedure]
-
Hardware-hacked Xbox 360 gamepad -- usb-debug is throwing useful but cryptic messages
about the device not accepting device enumeration blablablah. I haven't checked the code,
but this might be (in english) "how dare you plug me into a USB-2.0 port!".... -
Logitech 'Precision' USB gamepad. This thing works - type the following, you should see;
bash-3.2$ jstest /dev/js0
Driver version is 2.1.0.
Joystick (Logitech Logitech(R) Precision(TM) Gamepad) has 2 axes (X, Y)
and 10 buttons (Trigger, ThumbBtn, ThumbBtn2, TopBtn, TopBtn2, PinkieBtn, BaseBtn, BaseBtn2, BaseBtn3, BaseBtn4).
Testing ... (interrupt to exit)
Axes: 0:-32767 1:-32767 Buttons: 0:off 1:off 2:off 3:off 4:off 5:off 6:off 7:off 8:off 9:off
You can press buttons and fool with things to familiarize yourself with the control layout. Once finished,
hit Crtl-C to quit jstest. Now, you have to (auto) calibrate the device - type the following ;
bash-3.2$ jscal /dev/js0
Joystick has 2 axes and 10 buttons.
Correction for axis 0 is broken line, precision is 0.
Coeficients are: 112, 142, 5534751, 5534751
Correction for axis 1 is broken line, precision is 0.
Coeficients are: 112, 142, 5534751, 5534751
That's it! Now start your game of choice, go into the game's options menu, and setup things
to your likings.
- 'GT-4' Boxxer Steering wheel/pedals/gearshift/handbrake unit. Built for PS/PS1/PS2 but
comes with PS=>USB adapter (and windows driver disc) for PC use. The linux USBHID driver
interprets the situation thusly ;
bash-3.2$ jstest /dev/js2
Driver version is 2.1.0.
Joystick (USB Wheel ) has 7 axes (X, Y, Z, Rx, Ry, Hat0X, Hat0Y)
and 12 buttons (Trigger, ThumbBtn, ThumbBtn2, TopBtn, TopBtn2, PinkieBtn, BaseBtn, BaseBtn2, BaseBtn3, BaseBtn4, BaseBtn5, BaseBtn6).
Testing ... (interrupt to exit)
Axes: 0:-32767 1: 0 2: 0 3: 0 4: 0 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
The unit has 3 different modes of operation - Digital | Analog | Race
There is currently no possible way for me to post the amount of data jstest
spews out here with this device, nor show you how/what the relative modes
do to the mapping layouts/values once selected.
A jscal run looked something like this ;
bash-3.2$ jscal -c /dev/js2
Joystick has 7 axes and 12 buttons.
Correction for axis 0 is none (raw), precision is 0.
Correction for axis 1 is none (raw), precision is 0.
Correction for axis 2 is none (raw), precision is 0.
Correction for axis 3 is none (raw), precision is 0.
Correction for axis 4 is none (raw), precision is 0.
Correction for axis 5 is none (raw), precision is 0.
Correction for axis 6 is none (raw), precision is 0.
Calibrating precision: wait and don't touch the joystick.
Done. Precision is: 127, 128 Axis 4: 127, 128 Axis 5: 0, 0 Axis 6: 0, 0
Axis: 0: 0
Axis: 1: 1
Axis: 2: 1
Axis: 3: 1
Axis: 4: 1
Axis: 5: 0
Axis: 6: 0
Move axis 0 to minimum position and push any button.
Hold ... OK.
Move axis 0 to center position and push any button.
Hold ... OK.
Move axis 0 to maximum position and push any button.
Hold ... OK.
Move axis 1 to minimum position and push any button.
Hold ... OK.
Move axis 1 to center position and push any button.
Hold ... OK.
Move axis 1 to maximum position and push any button.
Hold ... OK.
Move axis 2 to minimum position and push any button.
Hold ... OK.
Move axis 2 to center position and push any button.
Hold ... OK.
Move axis 2 to maximum position and push any button.
Hold ... OK.
Move axis 3 to minimum position and push any button.
Hold ... OK.
Move axis 3 to center position and push any button.
Hold ... OK.
Move axis 3 to maximum position and push any button.
Hold ... OK.
Move axis 4 to minimum position and push any button.
Hold ... OK.
Move axis 4 to center position and push any button.
Hold ... OK.
Move axis 4 to maximum position and push any button.
Hold ... OK.
Move axis 5 to minimum position and push any button.
Hold ... OK.
Move axis 5 to center position and push any button.
Hold ... OK.
Move axis 5 to maximum position and push any button.
Hold ... OK.
Move axis 6 to minimum position and push any button.
Hold ... OK.
Move axis 6 to center position and push any button.
Hold ... OK.
Move axis 6 to maximum position and push any button.
Hold ... OK.
Setting correction to:
Correction for axis 0: broken line, precision: 0.
Coeficients: 1, 1, -2147483648, -2147483648
Correction for axis 1: broken line, precision: 1.
Coeficients: 128, 128, -2147483648, -2147483648
Correction for axis 2: broken line, precision: 1.
Coeficients: 128, 128, -2147483648, -2147483648
Correction for axis 3: broken line, precision: 1.
Coeficients: 128, 128, 4194176, 4227201
Correction for axis 4: broken line, precision: 1.
Coeficients: 128, 128, -2147483648, -2147483648
Correction for axis 5: broken line, precision: 0.
Coeficients: 1, 1, 268427264, -2147483648
Correction for axis 6: broken line, precision: 0.
Coeficients: 0, 0, -536854528, -536854528
This was done with the thing set in 'analog' mode. Most of the
'magic' here is working out exactly what Axis number relates to
which actual control...ie; Axis 1 actually maps to the brake
pedal for instance, other axis maps to HAT type pad, you'll
have fun setting this one up.....
When I get some sane approach happening, I'll add more, but it
=should= try to work in linux.