invzim
Champion
It's a little complicated I guess, the main problem is that different controllers report different stuff, and in such a way that it is no way predictable. So even if linux has names that are supposed to be deterministic, documented here:
https://www.kernel.org/doc/Documentation/input/gamepad.txt
it doesn't work at all in practice, thus the need to have pr-device definitions.
Some variations I've come across:
etc.. same goes for analog axis.
I'll see if I can throw together a small utility to read the mappings needed interactively.
https://www.kernel.org/doc/Documentation/input/gamepad.txt
it doesn't work at all in practice, thus the need to have pr-device definitions.
Some variations I've come across:
Code:
.button1 = BTN_TOP,
.button2 = BTN_THUMB2,
.button3 = BTN_TOP2,
.button4 = BTN_THUMB,
.button5 = BTN_TRIGGER,
.button6 = BTN_PINKIE,
.button1 = BTN_DEAD,
.button2 = 300,
.button3 = BTN_BASE5,
.button4 = 302,
.button5 = 301,
.button6 = BTN_BASE6,
.button1 = BTN_SOUTH,
.button2 = BTN_NORTH,
.button3 = BTN_WEST,
.button4 = BTN_EAST,
.button5 = BTN_C,
.button6 = BTN_Z,
I'll see if I can throw together a small utility to read the mappings needed interactively.