Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 29 Oct 2020 15:27:39 +0000
From:      bugzilla-noreply@freebsd.org
To:        usb@FreeBSD.org
Subject:   [Bug 250724] USB gamepads are tagged as a mouse by udev
Message-ID:  <bug-250724-19105@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D250724

            Bug ID: 250724
           Summary: USB gamepads are tagged as a mouse by udev
           Product: Base System
           Version: Unspecified
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: usb
          Assignee: usb@FreeBSD.org
          Reporter: doctorwhoguy@gmail.com

I have tested several USB gamecontrollers with FreeBSD, and there is someth=
ing
apparently wrong with either evdev or udev because the USB game controllers=
 are
being detected as mice instead of joysticks. I have tried both webcamd and
iichid to get them working with FreeBSD. For this example, I'll use my Logi=
tech
Dual Action Controller.

If I plug it in, dmesg will show the device detected and attach it as a uhid
device:

uhid0 on uhub2
uhid0: <Logitech Logitech Dual Action, class 0/0, rev 1.10/3.00, addr 3> on
usbus3

If I load the iichid kernel module and plug in the controller, dmesg will s=
how
the following output showing that it has been attached as an hid device:

ugen3.3: <Logitech Logitech Dual Action> at usbus3
usbhid0 on uhub2
usbhid0: <Logitech Logitech Dual Action, class 0/0, rev 1.10/3.00, addr 3> =
on
usbus3
hidbus0: <HID bus> on usbhid0
hgame0: <Logitech Logitech Dual Action Joystick> on hidbus0
hidraw0: <Logitech Logitech Dual Action Raw HID Device> on hidbus0

And /var/log/Xorg.0.log will show the following output:

[  1145.679] (II) config/udev: Adding input device Logitech Logitech Dual
Action Joystick (/dev/input/event6)
[  1145.679] (**) Logitech Logitech Dual Action Joystick: Applying InputCla=
ss
"evdev pointer catchall"
[  1145.679] (**) Logitech Logitech Dual Action Joystick: Applying InputCla=
ss
"libinput pointer catchall"
[  1145.679] (II) Using input driver 'libinput' for 'Logitech Logitech Dual
Action Joystick'
[  1145.679] (**) Logitech Logitech Dual Action Joystick: always reports co=
re
events
[  1145.679] (**) Option "Device" "/dev/input/event6"
[  1145.679] (**) Option "_source" "server/udev"
[  1145.682] (II) event6  - Logitech Logitech Dual Action Joystick: is tagg=
ed
by udev as: Mouse
[  1145.683] (II) event6  - Logitech Logitech Dual Action Joystick: device =
is a
pointer
[  1145.684] (II) event6  - Logitech Logitech Dual Action Joystick: device
removed
[  1145.684] (**) Option "config_info" "udev:/dev/input/event6"
[  1145.685] (II) XINPUT: Adding extended input device "Logitech Logitech D=
ual
Action Joystick" (type: MOUSE, id 12)
[  1145.691] (**) Option "AccelerationScheme" "none"
[  1145.695] (**) Logitech Logitech Dual Action Joystick: (accel) selected
scheme none/0
[  1145.695] (**) Logitech Logitech Dual Action Joystick: (accel) accelerat=
ion
factor: 2.000
[  1145.695] (**) Logitech Logitech Dual Action Joystick: (accel) accelerat=
ion
threshold: 4
[  1145.698] (II) event6  - Logitech Logitech Dual Action Joystick: is tagg=
ed
by udev as: Mouse
[  1145.699] (II) event6  - Logitech Logitech Dual Action Joystick: device =
is a
pointer

If I unload iichid and run "webcamd -N Logitech-Logitech-Dual-Action -S unk=
nown
-M 0", it will also show the same output in Xorg.0.log. Udev is capable of
tagging devices specifically as joysticks, but USB game controllers are bei=
ng
tagged as mice instead. As a result, the only functionality from the contro=
ller
is that the left joystick moves the mouse cursor. So I don't know if FreeBS=
D's
evdev support lacks support for joysticks or if maybe there's just a problem
with correctly detecting these devices and giving them the proper tag.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-250724-19105>