Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

connection to driver xpadneo on raspberry fails with error -22 or only hid-generic is started #100

Closed
gordonsolar opened this issue May 5, 2019 · 14 comments
Labels

Comments

@gordonsolar
Copy link
Contributor

Describe the bug
I try to connect the xbox controller to my raspberry pi 3.
For me it does work with the hid-generic, since i only want to read out buttons and analog sticks with "python evdev"
In order to be able to "rumble" the controller i would like to use the xpadneo driver.
After installation of the xpadneo driver i either get:

[ +0,163060] hid-generic 0005:045E:02FD.0001: unknown main item tag 0x0
[ +0,000071] hid-generic 0005:045E:02FD.0001: unbalanced collection at end of report description
[ +0,000095] hid-generic: probe of 0005:045E:02FD.0001 failed with error -22
[ +0,052215] hid_xpadneo: loading out-of-tree module taints kernel.
[ +0,000973] xpadneo: hello there!
[ +0,002379] xpadneo 0005:045E:02FD.0001: unknown main item tag 0x0
[ +0,000078] xpadneo 0005:045E:02FD.0001: unbalanced collection at end of report description
[ +0,000054] xpadneo 0005:045E:02FD.0001: parse failed
[ +0,000051] xpadneo: probe of 0005:045E:02FD.0001 failed with error -22

with the above situation i do not get any files in /dev/input

or (after turning the controller off/on) the xpadneo driver does not start at all:

[Mai 5 23:33] hid-generic 0005:045E:02FD.0002: unknown main item tag 0x0
[ +0,000512] input: Xbox Wireless Controller as /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0002/input/input0
[ +0,010544] hid-generic 0005:045E:02FD.0002: input,hidraw0: BLUETOOTH HID v9.03 Gamepad [Xbox Wireless Controller] on b8:27:eb:73:c7:4f

but i do have files in /dev/input/:
pi@raspberrypi:~ $ ls /dev/input/
event0 js0
With python i read out event0 with evdev and everything is fine - except the fact, that it does not rumble :-(

To Reproduce
I tried two time to:
remove the device from bluetoothctl
uninstall xpadneo
reboot
install xpadneo
reboot
Install current FW with Win10 (was no update necessary, but something was done to the device)
bluetoothctl scan on, pair mac, trust mac, connect mac

after the FW-update with Windows i could not connect to the device anymore (connect and immediate unconnect). So i uninstalled the xpadneo and tried again, still no connect. Reboot, remove from bluetoothctl, etc. Finally it connected again, but i got the error -22 (see above).
The whole procedure seems to be critical, depending on not so clear steps.

Expected behavior
A rumble and a stable connect :-)

Screenshots/Gifs

System information

  • uname -a :
    Linux raspberrypi 4.14.98-v7+ #1200 SMP Tue Feb 12 20:27:48 GMT 2019 armv7l GNU/Linux

  • dmesg
    see above

  • sudo find "/sys/kernel/debug/hid/" -name "0005:045E:*" -exec sh -c 'echo "{}" && head -1 "{}/rdesc" | tee /dev/tty | cksum && echo' \;
    /sys/kernel/debug/hid/0005:045E:02FD.0002
    05 01 09 05 a1 01 85 01 09 01 a1 00 09 30 09 31 15 00 27 ff ff 00 00 95 02 75 10 81 02 c0 09 01 a1 00 09 32 09 35 15 00 27 ff ff 00 00 95 02 75 10 81 02 c0 05 02 09 c5 15 00 26 ff 03 95 01 75 0a 81 02 15 00 25 00 75 06 95 01 81 03 05 02 09 c4 15 00 26 ff 03 95 01 75 0a 81 02 15 00 25 00 75 06 95 01 81 03 05 01 09 39 15 01 25 08 35 00 46 3b 01 66 14 00 75 04 95 01 81 42 75 04 95 01 15 00 25 00 35 00 45 00 65 00 81 03 05 09 19 01 29 0f 15 00 25 01 75 01 95 0f 81 02 15 00 25 00 75 01 95 01 81 03 05 0c 0a 24 02 15 00 25 01 95 01 75 01 81 02 15 00 25 00 75 07 95 01 81 03 05 0c 09 01 85 02 a1 01 05 0c 0a 23 02 15 00 25 01 95 01 75 01 81 02 15 00 25 00 75 07 95 01 81 03 c0 05 0f 09 21 85 03 a1 02 09 97 15 00 25 01 75 04 95 01 91 02 15 00 25 00 75 04 95 01 91 03 09 70 15 00 25 64 75 08 95 04 91 02 09 50 66 01 10 55 0e 15 00 26 ff 00 75 08 95 01 91 02 09 a7 15 00 26 ff 00 75 08 95 01 91 02 65 00 55 00 09 7c 15 00 26 ff 00 75 08 95 01 91 02 c0 85 04 05 06 09 20 15 00 26 ff 00 75 08 95 01 81 02 c0 00
    2579218694 1006

@gordonsolar
Copy link
Contributor Author

I tried to reproduce the error:
remove the device from bluetoothctl
uninstall xpadneo
reboot
install xpadneo
reboot
Install current FW with Win10 (was no update necessary, but something was done to the device)
bluetoothctl scan on, pair mac, trust mac, connect mac

Then i get the error:
[ +5,203454] hid-generic 0005:045E:02FD.0001: unknown main item tag 0x0
[ +0,000068] hid-generic 0005:045E:02FD.0001: unbalanced collection at end of report description
[ +0,000066] hid-generic: probe of 0005:045E:02FD.0001 failed with error -22
[ +0,052439] hid_xpadneo: loading out-of-tree module taints kernel.
[ +0,001159] xpadneo: hello there!
[ +0,001886] xpadneo 0005:045E:02FD.0001: unknown main item tag 0x0
[ +0,000074] xpadneo 0005:045E:02FD.0001: unbalanced collection at end of report description
[ +0,000067] xpadneo 0005:045E:02FD.0001: parse failed
[ +0,000060] xpadneo: probe of 0005:045E:02FD.0001 failed with error -22

After turning the controller off/on i get again:
[Mai 6 00:13] hid-generic 0005:045E:02FD.0002: unknown main item tag 0x0
[ +0,000750] input: Xbox Wireless Controller as /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11/0005:045E:02FD.0002/input/input0
[ +0,000321] hid-generic 0005:045E:02FD.0002: input,hidraw0: BLUETOOTH HID v9.03 Gamepad [Xbox Wireless Controller] on b8:27:eb:73:c7:4f

so its reproducible ... time to go to bed anyway ...

@atar-axis
Copy link
Owner

atar-axis commented May 5, 2019

Hey! Do you get the 22 error only the first time after updating the fw?

Looks like the udev rule does not work on your machine, once again... Give me a Minute to add instructions here

@atar-axis
Copy link
Owner

atar-axis commented May 5, 2019

#91 (comment)

Please upload this log, one time without xpadneo installed, the other one with :)
thanks!

@atar-axis
Copy link
Owner

atar-axis commented May 6, 2019

Note: It may be possible to simplify the whole udev-rule monster

  • remove /etc/udev/rules.d/xpadneo.sh
  • replace the content of /etc/udev/rules.d/99-xpadneo.rules with the following:
    ACTION=="add", \
    KERNEL=="0005:045E:02FD.*|0005:045E:02E0.*", \
    SUBSYSTEM=="hid", \
    RUN:="/bin/sh -c 'echo xpadneo udev: $kernel > /dev/kmsg; modprobe hid_xpadneo; echo $kernel > /sys/bus/hid/drivers/hid-generic/unbind; echo $kernel > /sys/bus/hid/drivers/microsoft/unbind; echo $kernel > /sys/bus/hid/drivers/xpadneo/bind; echo xpadneo udev: ok > /dev/kmsg'"
    
  • reboot and see it it works

@gordongnarf: If you want, you can give this a try too, but it would be great if you could send me the log anyway.

@gordonsolar
Copy link
Contributor Author

Hey! Do you get the 22 error only the first time after updating the fw?

Looks like the udev rule does not work on your machine, once again... Give me a Minute to add instructions here

Hi, thanks for the quick reply!
It seems that i get the error even without updating the firmware. In order to produce the logs that you want i removed the device from bluetoothctl, unistalled your driver, reboot, then with using log1 i connected to the controller again - see dmesg:

[Mai 6 23:03] Bluetooth: HIDP (Human Interface Emulation) ver 1.2
[ +0,000036] Bluetooth: HIDP socket layer initialized
[ +0,005508] hid-generic 0005:045E:02FD.0001: unknown main item tag 0x0
[ +0,000069] hid-generic 0005:045E:02FD.0001: unbalanced collection at end of report description
[ +0,000080] hid-generic: probe of 0005:045E:02FD.0001 failed with error -22
[Mai 6 23:06] hid-generic 0005:045E:02FD.0002: unknown main item tag 0x0
[ +0,000114] hid-generic 0005:045E:02FD.0002: unbalanced collection at end of report description
[ +0,000088] hid-generic: probe of 0005:045E:02FD.0002 failed with error -22

/tmp/xpadneolog1

monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[8894.393686] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11
DEVTYPE=link
SEQNUM=1198
SUBSYSTEM=bluetooth

UDEV [8894.401583] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11
DEVTYPE=link
SEQNUM=1198
SUBSYSTEM=bluetooth
SYSTEMD_ALIAS=/sys/subsystem/bluetooth/devices/hci0:11
SYSTEMD_WANTS=bluetooth.target
TAGS=:systemd:
USEC_INITIALIZED=8894400825

KERNEL[8903.190409] remove /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11 (bluetooth)
ACTION=remove
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11
DEVTYPE=link
SEQNUM=1199
SUBSYSTEM=bluetooth

UDEV [8903.196005] remove /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11 (bluetooth)
ACTION=remove
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:11
DEVTYPE=link
SEQNUM=1199
SUBSYSTEM=bluetooth
SYSTEMD_ALIAS=/sys/subsystem/bluetooth/devices/hci0:11
SYSTEMD_WANTS=bluetooth.target
TAGS=:systemd:
USEC_INITIALIZED=8894400825

KERNEL[8939.224732] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1200
SUBSYSTEM=bluetooth

UDEV [8939.232688] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1200
SUBSYSTEM=bluetooth
SYSTEMD_ALIAS=/sys/subsystem/bluetooth/devices/hci0:12
SYSTEMD_WANTS=bluetooth.target
TAGS=:systemd:
USEC_INITIALIZED=8939231974

KERNEL[8939.356464] add /module/hidp (module)
ACTION=add
DEVPATH=/module/hidp
SEQNUM=1201
SUBSYSTEM=module

KERNEL[8939.362411] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001 (hid)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001
HID_ID=0005:0000045E:000002FD
HID_NAME=Xbox Wireless Controller
HID_PHYS=b8:27:eb:73:c7:4f
HID_UNIQ=9c:aa:1b:e7:fc:a2
MODALIAS=hid:b0005g0001v0000045Ep000002FD
SEQNUM=1202
SUBSYSTEM=hid

UDEV [8939.362873] add /module/hidp (module)
ACTION=add
DEVPATH=/module/hidp
SEQNUM=1201
SUBSYSTEM=module
USEC_INITIALIZED=8939362236

UDEV [8939.371811] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001 (hid)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001
HID_ID=0005:0000045E:000002FD
HID_NAME=Xbox Wireless Controller
HID_PHYS=b8:27:eb:73:c7:4f
HID_UNIQ=9c:aa:1b:e7:fc:a2
MODALIAS=hid:b0005g0001v0000045Ep000002FD
SEQNUM=1202
SUBSYSTEM=hid
USEC_INITIALIZED=8939371042

now remove device from bluetooth, install your driver again, reboot, udevadm monitor -p > /tmp/xpadneo_log3 and connect controller again:

dmesg (your driver was not used):
[ +0,403628] hid-generic 0005:045E:02FD.0001: unknown main item tag 0x0
[ +0,000696] input: Xbox Wireless Controller as /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0
[ +0,000253] hid-generic 0005:045E:02FD.0001: input,hidraw0: BLUETOOTH HID v9.03 Gamepad [Xbox Wireless Controller] on b8:27:eb:73:c7:4f
[ +0,043226] hid_xpadneo: loading out-of-tree module taints kernel.
[ +0,001025] xpadneo: hello there!

and the log from udevadm monitor:

monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[211.263611] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1198
SUBSYSTEM=bluetooth

UDEV [211.272022] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1198
SUBSYSTEM=bluetooth
SYSTEMD_ALIAS=/sys/subsystem/bluetooth/devices/hci0:12
SYSTEMD_WANTS=bluetooth.target
TAGS=:systemd:
USEC_INITIALIZED=211271252

KERNEL[221.200446] remove /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=remove
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1199
SUBSYSTEM=bluetooth

UDEV [221.206220] remove /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=remove
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1199
SUBSYSTEM=bluetooth
SYSTEMD_ALIAS=/sys/subsystem/bluetooth/devices/hci0:12
SYSTEMD_WANTS=bluetooth.target
TAGS=:systemd:
USEC_INITIALIZED=211271252

KERNEL[258.167536] add /module/hidp (module)
ACTION=add
DEVPATH=/module/hidp
SEQNUM=1200
SUBSYSTEM=module

UDEV [258.174285] add /module/hidp (module)
ACTION=add
DEVPATH=/module/hidp
SEQNUM=1200
SUBSYSTEM=module
USEC_INITIALIZED=258173962

KERNEL[258.264753] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1201
SUBSYSTEM=bluetooth

UDEV [258.272876] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12 (bluetooth)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12
DEVTYPE=link
SEQNUM=1201
SUBSYSTEM=bluetooth
SYSTEMD_ALIAS=/sys/subsystem/bluetooth/devices/hci0:12
SYSTEMD_WANTS=bluetooth.target
TAGS=:systemd:
USEC_INITIALIZED=258272102

KERNEL[258.564354] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001 (hid)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001
HID_ID=0005:0000045E:000002FD
HID_NAME=Xbox Wireless Controller
HID_PHYS=b8:27:eb:73:c7:4f
HID_UNIQ=9c:aa:1b:e7:fc:a2
MODALIAS=hid:b0005g0001v0000045Ep000002FD
SEQNUM=1202
SUBSYSTEM=hid

KERNEL[258.572575] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0 (input)
ABS=30627
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0
EV=1b
KEY=7fff0000 0 0 0 1000 40000000 0 0 0 0
MODALIAS=input:b0005v045Ep02FDe0903-e0,1,3,4,k9E,AC,130,131,132,133,134,135,136,137,138,139,13A,13B,13C,13D,13E,ra0,1,2,5,9,A,10,11,m4,lsfw
MSC=10
NAME="Xbox Wireless Controller"
PHYS="b8:27:eb:73:c7:4f"
PRODUCT=5/45e/2fd/903
PROP=0
SEQNUM=1203
SUBSYSTEM=input
UNIQ="9c:aa:1b:e7:fc:a2"

KERNEL[258.573320] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/hidraw/hidraw0 (hidraw)
ACTION=add
DEVNAME=/dev/hidraw0
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/hidraw/hidraw0
MAJOR=247
MINOR=0
SEQNUM=1204
SUBSYSTEM=hidraw

KERNEL[258.611619] add /module/ff_memless (module)
ACTION=add
DEVPATH=/module/ff_memless
SEQNUM=1206
SUBSYSTEM=module

KERNEL[258.616854] add /module/hid_xpadneo (module)
ACTION=add
DEVPATH=/module/hid_xpadneo
SEQNUM=1207
SUBSYSTEM=module

KERNEL[258.617210] add /bus/hid/drivers/xpadneo (drivers)
ACTION=add
DEVPATH=/bus/hid/drivers/xpadneo
SEQNUM=1208
SUBSYSTEM=drivers

UDEV [258.617702] add /module/ff_memless (module)
ACTION=add
DEVPATH=/module/ff_memless
SEQNUM=1206
SUBSYSTEM=module
USEC_INITIALIZED=258617436

UDEV [258.624246] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001 (hid)
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001
DRIVER=hid-generic
HID_ID=0005:0000045E:000002FD
HID_NAME=Xbox Wireless Controller
HID_PHYS=b8:27:eb:73:c7:4f
HID_UNIQ=9c:aa:1b:e7:fc:a2
MODALIAS=hid:b0005g0001v0000045Ep000002FD
SEQNUM=1202
SUBSYSTEM=hid
USEC_INITIALIZED=258607043

UDEV [258.625913] add /bus/hid/drivers/xpadneo (drivers)
ACTION=add
DEVPATH=/bus/hid/drivers/xpadneo
SEQNUM=1208
SUBSYSTEM=drivers
USEC_INITIALIZED=258625530

UDEV [258.628245] add /module/hid_xpadneo (module)
ACTION=add
DEVPATH=/module/hid_xpadneo
SEQNUM=1207
SUBSYSTEM=module
USEC_INITIALIZED=258627905

UDEV [258.634970] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/hidraw/hidraw0 (hidraw)
ACTION=add
DEVNAME=/dev/hidraw0
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/hidraw/hidraw0
MAJOR=247
MINOR=0
SEQNUM=1204
SUBSYSTEM=hidraw
USEC_INITIALIZED=258634317

KERNEL[258.651879] add /module/joydev (module)
ACTION=add
DEVPATH=/module/joydev
SEQNUM=1209
SUBSYSTEM=module

KERNEL[258.652290] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/js0 (input)
ACTION=add
DEVNAME=/dev/input/js0
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/js0
MAJOR=13
MINOR=0
SEQNUM=1210
SUBSYSTEM=input

UDEV [258.655865] add /module/joydev (module)
ACTION=add
DEVPATH=/module/joydev
SEQNUM=1209
SUBSYSTEM=module
USEC_INITIALIZED=258655427

KERNEL[258.657285] add /module/evdev (module)
ACTION=add
DEVPATH=/module/evdev
SEQNUM=1211
SUBSYSTEM=module

UDEV [258.657795] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0 (input)
ABS=30627
ACTION=add
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0
EV=1b
ID_BUS=bluetooth
ID_FOR_SEAT=input-platform-soc
ID_INPUT=1
ID_INPUT_JOYSTICK=1
ID_INPUT_KEY=1
ID_PATH=platform-soc
ID_PATH_TAG=platform-soc
KEY=7fff0000 0 0 0 1000 40000000 0 0 0 0
MODALIAS=input:b0005v045Ep02FDe0903-e0,1,3,4,k9E,AC,130,131,132,133,134,135,136,137,138,139,13A,13B,13C,13D,13E,ra0,1,2,5,9,A,10,11,m4,lsfw
MSC=10
NAME="Xbox Wireless Controller"
PHYS="b8:27:eb:73:c7:4f"
PRODUCT=5/45e/2fd/903
PROP=0
SEQNUM=1203
SUBSYSTEM=input
TAGS=:seat:
UNIQ="9c:aa:1b:e7:fc:a2"
USEC_INITIALIZED=258633308

KERNEL[258.658486] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/event0 (input)
ACTION=add
DEVNAME=/dev/input/event0
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/event0
MAJOR=13
MINOR=64
SEQNUM=1212
SUBSYSTEM=input

UDEV [258.659783] add /module/evdev (module)
ACTION=add
DEVPATH=/module/evdev
SEQNUM=1211
SUBSYSTEM=module
USEC_INITIALIZED=258659522

KERNEL[258.703611] change /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery (power_supply)
ACTION=change
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_MODEL_NAME=Xbox Wireless Controller
POWER_SUPPLY_NAME=hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_ONLINE=1
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_SCOPE=Device
SEQNUM=1213
SUBSYSTEM=power_supply

UDEV [258.803290] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/js0 (input)
ACTION=add
DEVNAME=/dev/input/js0
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/js0
ID_BUS=bluetooth
ID_FOR_SEAT=input-platform-soc
ID_INPUT=1
ID_INPUT_JOYSTICK=1
ID_INPUT_KEY=1
ID_PATH=platform-soc
ID_PATH_TAG=platform-soc
MAJOR=13
MINOR=0
SEQNUM=1210
SUBSYSTEM=input
TAGS=:seat:uaccess:
USEC_INITIALIZED=258667802

UDEV [258.804893] change /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery (power_supply)
ACTION=change
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_MODEL_NAME=Xbox Wireless Controller
POWER_SUPPLY_NAME=hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_ONLINE=1
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_SCOPE=Device
SEQNUM=1213
SUBSYSTEM=power_supply
USEC_INITIALIZED=258804456

UDEV [258.911701] add /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/event0 (input)
ACTION=add
BACKSPACE=guess
DEVNAME=/dev/input/event0
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/input/input0/event0
ID_BUS=bluetooth
ID_FOR_SEAT=input-platform-soc
ID_INPUT=1
ID_INPUT_JOYSTICK=1
ID_INPUT_KEY=1
ID_PATH=platform-soc
ID_PATH_TAG=platform-soc
LIBINPUT_DEVICE_GROUP=5/45e/2fd/903:b8:27:eb:73:c7:4f
MAJOR=13
MINOR=64
SEQNUM=1212
SUBSYSTEM=input
TAGS=:seat:uaccess:
USEC_INITIALIZED=258806530
XKBLAYOUT=de
XKBMODEL=pc105
XKBOPTIONS=
KERNEL[259.976321] change /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery (power_supply)
ACTION=change
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_CAPACITY=52
POWER_SUPPLY_MODEL_NAME=Xbox Wireless Controller
POWER_SUPPLY_NAME=hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_ONLINE=1
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_SCOPE=Device
POWER_SUPPLY_STATUS=Discharging
SEQNUM=1214
SUBSYSTEM=power_supply

UDEV [259.983524] change /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery (power_supply)
ACTION=change
DEVPATH=/devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:12/0005:045E:02FD.0001/power_supply/hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_CAPACITY=52
POWER_SUPPLY_MODEL_NAME=Xbox Wireless Controller
POWER_SUPPLY_NAME=hid-9c:aa:1b:e7:fc:a2-battery
POWER_SUPPLY_ONLINE=1
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_SCOPE=Device
POWER_SUPPLY_STATUS=Discharging
SEQNUM=1214
SUBSYSTEM=power_supply
USEC_INITIALIZED=259983052

hope you can read the matrix without decoder ;-)

@atar-axis
Copy link
Owner

atar-axis commented May 6, 2019

Thanks! I will take a look later, have you tried the instructions above too? Would be interesting too :)

The other problem, the hid-generic 0005:045E:02FD.0002: unbalanced collection at end of report description message, is a firmware issue. It's not the first time that this problem appears, but it is normally not a permanent thing - updating the gampad does - usually - solve the problem. strange!

@gordonsolar
Copy link
Contributor Author

Note: It may be possible to simplify the whole udev-rule monster

* remove `/etc/udev/rules.d/xpadneo.sh`

* replace the content of `/etc/udev/rules.d/99-xpadneo.rules` with the following:
  ```
  ACTION=="add", \
  KERNEL=="0005:045E:02FD.*|0005:045E:02E0.*", \
  SUBSYSTEM=="hid", \
  RUN:="/bin/sh -c 'echo xpadneo udev: $kernel > /dev/kmsg; modprobe hid_xpadneo; echo $kernel > /sys/bus/hid/drivers/hid-generic/unbind; echo $kernel > /sys/bus/hid/drivers/microsoft/unbind; echo $kernel > /sys/bus/hid/drivers/xpadneo/bind; echo xpadneo udev: ok > /dev/kmsg'"
  ```

@gordongnarf: If you want, you can give this a try too, but it would be great if you could send me the log anyway.

did what you wrote above and i got my rumble :-) see dmesg below
Thanks a lot! hope with my testing i could help you somehow!
If you have further questions, need logs, ... just ask!

[Mai 6 23:47] hid-generic 0005:045E:02FD.0003: unknown main item tag 0x0
[ +0,000746] input: Xbox Wireless Controller as /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:13/0005:045E:02FD.0003/input/input2
[ +0,000711] hid-generic 0005:045E:02FD.0003: input,hidraw0: BLUETOOTH HID v9.03 Gamepad [Xbox Wireless Controller] on b8:27:eb:73:c7:4f
[ +0,011425] xpadneo udev: 0005:045E:02FD.0003
[ +0,142775] xpadneo 0005:045E:02FD.0003: unknown main item tag 0x0
[ +0,000374] input: Xbox Wireless Controller as /devices/platform/soc/3f201000.serial/tty/ttyAMA0/hci0/hci0:13/0005:045E:02FD.0003/input/input3
[ +0,000517] xpadneo 0005:045E:02FD.0003: input,hidraw0: BLUETOOTH HID v9.03 Gamepad [Xbox Wireless Controller] on b8:27:eb:73:c7:4f
[ +0,990708] xpadneo udev: ok

@atar-axis
Copy link
Owner

atar-axis commented May 6, 2019

did what you wrote above and i got my rumble :-) see dmesg below

that's good to hear, it also works on my local machine. But I will have to wait for some others to report back first, if it works for them too then I will merge it into the master 😁

Thanks for testing and reporting the issue!

I will close it for now, if you face other - related - problems then we can reopen it ;)

@gordonsolar
Copy link
Contributor Author

gordonsolar commented May 8, 2019 via email

@atar-axis
Copy link
Owner

Hey Thomas, I am not a well trained python programmer, but I am sure we will find a solution - just open a new issue please ;)

@flagoss
Copy link

flagoss commented May 15, 2019

I have been trying for days to make my controllers use Xpadneo on connection ( Connecting with vibration ) and I have not been able. The only thing that worked for me is using that methode:

* remove `/etc/udev/rules.d/xpadneo.sh`
* replace the content of `/etc/udev/rules.d/99-xpadneo.rules` with the following wich as worked pretty well:

ACTION=="add",
KERNEL=="0005:045E:02FD.|0005:045E:02E0.",
SUBSYSTEM=="hid",
RUN:="/bin/sh -c 'echo xpadneo udev: $kernel > /dev/kmsg; modprobe hid_xpadneo; echo $kernel > /sys/bus/hid/drivers/hid-generic/unbind; echo $kernel > /sys/bus/hid/drivers/microsoft/unbind; echo $kernel > /sys/bus/hid/drivers/xpadneo/bind; echo xpadneo udev: ok > /dev/kmsg'"

I am using a Raspberry Pi 3 B+ and did a fresh install of Retropie. Did a full system update. Uninstalled Xpad. Then I installed Xpadneo.

@atar-axis
Copy link
Owner

@flagoss: Thank you for reporting that! I will Change that in master today

@atar-axis
Copy link
Owner

@flagoss I change the udev rule to the one which where mentioned in the issue you quoted:
f2729dc

Could you please give it a try?

  • ./uninstall.sh
  • clone the new version (master)
  • ./install.sh

@flagoss
Copy link

flagoss commented May 17, 2019

Thank you... I will try that a try tonight

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants