denilsonsa / udev-joystick-blacklist

Fix for keyboard/mouse/tablet being detected as joystick in Linux
118 stars 27 forks source link

Here is what solved for me #31

Open weberkai opened 7 years ago

weberkai commented 7 years ago

Hi!

I also had this ghost joystick problem... Usb device 045e:0750. Then I started to search for a solution. First I was looking for what is causing troubles...

My usb keyboard have 2 interfaces: First one is a normal keyboard and second one is used only for multimedia keys. I think others keyboards like internet keyboards works the same way.

The problem is: The second interface is a complete joystick + keyboard interface. So it is detected as a joystick sending 0 to both X and Y absolute axes (ghost joystick). But if I disable completely second interface... Then multimedia keys will stop working. It is a bad idea.

Tried this: 1) boot flags: usbhid.quirks=0x045e:0x0750:0x00000020 (BAD GAME PAD) failed... 2) changed eudev and joydev sources: If I found some keys, like multimedia keys, then I force to not detect as pointer device (worked, but this is not good, maybe someday someone will create a device with both axes and multimedia keys...)

What I did then?

I want both /dev/input/eventXX from keyboard working, but I don't want joydev to atach to second /dev/input/eventXX and create /dev/input/js0.

So I just remove /dev/input/js0 after creation.

I updated your eudev rules to this one: KERNEL=="js[0-9]*", SUBSYSTEM=="input", ATTRS{idVendor}=="045e", ATTRS{idProduct}=="0750", RUN+="/bin/rm $env{DEVNAME}"

This way I still have both keyboard interfaces working and just don't have joystick.

I think the others devices from the list can be updated like this also.