dee2eR wrote: ↑Mon Apr 24, 2023 9:37 am
What program was that output from?
>./mamearcade -v >joy.txt
The ordering makes no sense at all as the hotkeys (xboxdrv) start up after the other joysticks, it definately shouldn't be js1 (ever).
Is the order of /dev/input/js0 through js3 changing too?
I dont know how/where to check, Im assuming jtest? If so see below
ie GPIO player 1 inputs become js2 at the Linux kernel level? If the order of /dev/input/js[whatever] is changing with the use of the yoke it may be possible to write a script to re-order the joysticks by renaming them if the yoke is detected at startup... I just renamed js0 to js5 as a test and it seems to work, although I don't know if it will actually work in practice.
I then found this:
https://ubuntuforums.org/showthread.php?t=1595666
and made this rule called "99-starwars.rules"
KERNEL=="js?", ENV{ID_VENDOR}=="Baolian_industry_Co._Ltd.", ENV{ID_MODEL}=="BL_flight_yoke_#1", NAME="input/js4"
and put it here:
\etc\udev\rules.d
Rebooted and I tried it and it doesnt work
I also used lsusb to get ID numbers
Bus002 Device 001: ID1d6b:0003 Linux Foundation 3.0 root hub
Bus001 Device 006: IDd209:15a1 Ultimarc
Bus001 Device 005: IDd209:15a2 Ultimarc
Bus001 Device 004: ID32be:1402
(Im pretty sure this is the flight yoke)
Bus001 Device 003: IDc0f4:02b0
(Im pretty sure this is the USB wired keyboard)
Bus001 Device 002: ID2103:3431 VIA Labs, Inc. Hub
(assuming either pi or your board)
Bus001 Device 001: ID1d6b:0002 Linux Foundation 2.0 root hub
Also ran jstest /dev/input/js0 and so forth:
tested and got these results below:
js0
joystick (Baolian Industry Co. Ltd. BL Flight yoke#1) 2 axis x, y 15 buttons
js0 does react to movements of the flight yoke and buttons
js1
joystick (Baolian Industry Co. Ltd. BL Flight yoke#1) 2 axis x, y 3 buttons
js1 no reactions at all (maybe when in mouse mode, I didnt try)
js2
joystick (GPIO Controller1) 2 axis x,y 9 buttons
js2 does react to movements to jamma joystick and buttons on left of control panel
js3
joystick (GPIO Controller2) 2 axis x,y 9 buttons
js3 does react to movements to jamma joystick and buttons on right of control panel
js4
joystick (xbox Gamepad (userspace driver)) 4 axis x, y, gas, brake 15 buttons
js4 no reactions at all
nothing above js5
Now that I read all this again the above rule wont work because js4 is already assigned Im assuming... So I removed it for now.
on another forum I was told try this (numbers are from lsusb results) and I havent done anything with it yet because they didnt say how or where to use:
ATTRS{idVendor}=="32be", ATTRS{idProduct}=="1402", MODE="0666"