Either this is a recent development or I have an exceptional talent for not noticing things, but today I discovered that XBox 360 pads are supported by GNU/Linux. Unlike the official Windows DirectInput driver, the triggers are mapped to individual axes and the central logo button is accessible.
For those of you who don't already know, PlayStation 3 SIXAXIS pads are also supported and have been for some time now, minus the tilt-sensor functionality. It's even possible to read many of the buttons as axes in order to get pressure-sensitive input, a feature which some of you may recall was supposed to be one of the major innovations of the PlayStation 2 DualShock 2 controllers (and perhaps 3 games actually took advantage of).
I have never managed to get a SIXAXIS pad to work with Windows - the device is detected, but none of the axes or buttons respond to input. I've tried pressing the central PSLOGO button a few times, since that usually does the job when I'm using Trisquel, but it doesn't seem to have any effect.
XBox 360 pads, on the other hand, work just fine on Windows, a fact that will only startle you if you happen to be Pokédex entry number 79.
For convenience, I have documented the button and axis mappings for both pads here, so that anyone planning to include support for these pads in their own game projects can avoid the hassle of having to figure everything out for themselves.
Could you assert that ps2 dualshock (with usb adapter) have the same mapping (minus the new axes of the sixaxis)?
Sadly most dual-axis pc gamepads (dualshock clones) have wildly different mappings (possibly because of their different console heritage or because of just cloning the look without proper re-engineering). Would be awsome if either those vendors could meet a common standard or if there were a wrapper library that could map them to a common standard. The first step to having a wrapper library would be to collect mappings just like you did. And then select the right mapping for the gamepad version/vendor.
...or do some lobbying and ask vendors about their mappings and ask if there is a reason they prefer to go their own way and if they think it is an advantage to be incompatible...thank you for gaming...
I think that could enhance the "user experience" on the pc if one could have console like input support: Plug in some gamepads, startup super tux cart or any other game and have the buttons of all gamepads work in the same way instantly. I would wish that for my game, too.
The mapping of buttons used by PlayStation 2 USB adapters varies, depending on the adapter/driver used and how it is configured. This is because they are all unofficial, third-party devices, meaning that there is no set standard to define how they should function.
XBox 1 pads are actual USB devices - they just have an over-sized, non-standard cable. With the correct cable adapter, it is possible to plug them into a normal-sized USB port. As with the PS2 adapters, though, the button mappings depend on the driver used - and no "official" drivers exist for them.
I believe that they are supported on GNU/Linux systems, probably due to Xebian. I investigated them a while ago and, strangely, there appears to be more than one type of XBox pad - lsusb shows different pads as having different device type identifiers.
As for the idea of a "standard" game-pad controller for PC systems, this seems to be what Microsoft was aiming for with XInput, since as far as I am aware it currently only supports XBox 360 pads (though SIXAXIS controllers do seem to fulfill all of the requirements).
One way of going about this currently is to determine which of the four "driver types" a pad is (GNU/Linux SIXAXIS, GNU/Linux XBOX, Windows XBOX, Other) and then use some clever coding to remap/unify the joypad input events in a way that allows them to be treated in the same manner - except for the "Other" joypads of course, since there's no set standard for those.
Sounds like it's worse with different drivers than with different pc-gamepads. I wish vendors would at least publically print their layout - maybe some well named could be convinced - they could only win: logitech for open source , saitek works better under linux
What annoys me the most is that shoulderpad indexing is sometimes like i=L1, i+1=L2, i+2=R1,i+3=R2 and then sometimes i=L1, i+1=R1, i+2=L2, i+3=R2