USB Mouse not working

Jorg

New Member


Messages: 6

Hi,

Fresh install FreeBSD 11.1 (Guided ZFS Stripe MBR Bios),
usb wired mouse is not working.

There isn't any /dev/ums* device.

USB Dump:
Code:
usbconfig -u 4 -a 2 dump_info
ugen4.2: <vendor 0x275d USB OPTICAL MOUSE> at usbus4, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (100mA)

usbconfig -u 4 -a 2 dump_curr_config_desc
ugen4.2: <vendor 0x275d USB OPTICAL MOUSE> at usbus4, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (100mA)


 Configuration index 0

    bLength = 0x0009
    bDescriptorType = 0x0002
    wTotalLength = 0x0022
    bNumInterfaces = 0x0001
    bConfigurationValue = 0x0001
    iConfiguration = 0x0000  <no string>
    bmAttributes = 0x00a0
    bMaxPower = 0x0032

    Interface 0
      bLength = 0x0009
      bDescriptorType = 0x0004
      bInterfaceNumber = 0x0000
      bAlternateSetting = 0x0000
      bNumEndpoints = 0x0001
      bInterfaceClass = 0x0003  <HID device>
      bInterfaceSubClass = 0x0001
      bInterfaceProtocol = 0x0002
      iInterface = 0x0000  <no string>

      Additional Descriptor

      bLength = 0x09
      bDescriptorType = 0x21
      bDescriptorSubType = 0x11
       RAW dump:
       0x00 | 0x09, 0x21, 0x11, 0x01, 0x00, 0x01, 0x22, 0x40,
       0x08 | 0x00

     Endpoint 0
        bLength = 0x0007
        bDescriptorType = 0x0005
        bEndpointAddress = 0x0081  <IN>
        bmAttributes = 0x0003  <INTERRUPT>
        wMaxPacketSize = 0x0005
        bInterval = 0x000a
        bRefresh = 0x0000
        bSynchAddress = 0x0000
/var/log/message
Code:
Jan 22 13:08:25 skalar kernel: Rebooting...
Jan 22 13:08:25 skalar kernel: cpu_reset: Stopping other CPUs
Jan 22 13:08:25 skalar kernel: Copyright (c) 1992-2017 The FreeBSD Project.
Jan 22 13:08:25 skalar kernel: Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
Jan 22 13:08:25 skalar kernel: The Regents of the University of California. All rights reserved.
Jan 22 13:08:25 skalar kernel: FreeBSD is a registered trademark of The FreeBSD Foundation.
Jan 22 13:08:25 skalar kernel: FreeBSD 11.1-RELEASE #0 r321309: Fri Jul 21 02:08:28 UTC 2017
Jan 22 13:08:25 skalar kernel: root@releng2.nyi.freebsd.org:/usr/obj/usr/src/sys/GENERIC amd64
Jan 22 13:08:25 skalar kernel: FreeBSD clang version 4.0.0 (tags/RELEASE_400/final 297347) (based on LLVM 4.0.0)
...
Jan 22 13:08:25 skalar kernel: uhub4: 2 ports with 2 removable, self powered
Jan 22 13:08:25 skalar kernel: uhub0: 2 ports with 2 removable, self powered
Jan 22 13:08:25 skalar kernel: uhub6: 2 ports with 2 removable, self powered
Jan 22 13:08:25 skalar kernel: uhub1: 2 ports with 2 removable, self powered
Jan 22 13:08:25 skalar kernel: Trying to mount root from zfs:zroot/ROOT/default []...
Jan 22 13:08:25 skalar kernel: uhub5: 2 ports with 2 removable, self powered
Jan 22 13:08:25 skalar kernel: uhub3: 2 ports with 2 removable, self powered
Jan 22 13:08:25 skalar kernel: Root mount waiting for: usbus7 usbus3
Jan 22 13:08:25 skalar kernel: Root mount waiting for: usbus7 usbus3
Jan 22 13:08:25 skalar kernel: uhub2: 6 ports with 6 removable, self powered
Jan 22 13:08:25 skalar kernel: uhub7: 6 ports with 6 removable, self powered
Jan 22 13:08:25 skalar kernel: Root mount waiting for: usbus7 usbus3
Jan 22 13:08:25 skalar kernel: ugen4.2: <vendor 0x275d USB OPTICAL MOUSE> at usbus4
Jan 22 13:08:25 skalar kernel: ugen0.2: <Microsoft Wired Keyboard 600> at usbus0
Jan 22 13:08:25 skalar kernel: ukbd0 on uhub6
Jan 22 13:08:25 skalar kernel: ukbd0: <Microsoft Wired Keyboard 600, class 0/0, rev 2.00/3.00, addr 2> on usbus0
Jan 22 13:08:25 skalar kernel: kbd2 at ukbd0
Jan 22 13:08:25 skalar kernel: re0: link state changed to DOWN
Jan 22 13:08:25 skalar kernel: re0: link state changed to UP
Jan 22 13:08:28 skalar dbus[622]: [system] Activating service name='org.freedesktop.ConsoleKit' (using servicehelper)
Jan 22 13:08:28 skalar dbus[622]: [system] Activating service name='org.freedesktop.PolicyKit1' (using servicehelper)
Jan 22 13:08:28 skalar dbus[622]: [system] Successfully activated service 'org.freedesktop.ConsoleKit'
Jan 22 13:08:28 skalar dbus[622]: [system] Successfully activated service 'org.freedesktop.PolicyKit1'
And /etc/rc.conf

Code:
sendmail_enable="NONE"
hostname="skalar"
keymap="pl_PL.ISO8859-2.kbd"
ifconfig_re0="DHCP"
sshd_enable="YES"
#moused_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="AUTO"
zfs_enable="YES"
dbus_enable="YES"
hald_enable="YES"
It's strange for me (I'm not advanced user) but I can't find /boot/loader.conf.

Can you help me?
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 6,971
Messages: 28,968

If you run tail -f /var/log/messages and unplug and re-plug the mouse, what messages do you see?
 

iSiek

New Member

Reaction score: 5
Messages: 14

Jan 22 13:08:25 skalar kernel: ugen4.2: <vendor 0x275d USB OPTICAL MOUSE> at usbus4
I can see in your /var/log/messages that mouse is discovered but probably not identified as vendor 0x275d hex manufacturer code is displayed instead of its name.

additionally in /etc/rc.conf file, you have commented out moused deamon. Can you try to uncomment this line?
Code:
---> #moused_enable="YES"
remove leading # sign and save changes
Code:
moused_enable="YES"
Regards,
Krzysztof
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 6,971
Messages: 28,968

additionally in /etc/rc.conf file, you have commented out moused deamon. Can you try to uncomment this line?
Enabling it is only required for PS/2 mice, for USB mice it's automatically loaded by devd(8). If it's correctly recognized.
 
OP
OP
Jorg

Jorg

New Member


Messages: 6

If you run tail -f /var/log/messages and unplug and re-plug the mouse, what messages do you see?
Code:
Jan 22 16:48:59 skalar kernel: ugen4.2: <vendor 0x275d USB OPTICAL MOUSE> at usbus4 (disconnected)
Jan 22 16:49:06 skalar kernel: ugen4.2: <vendor 0x275d USB OPTICAL MOUSE> at usbus4
 
OP
OP
Jorg

Jorg

New Member


Messages: 6

I went back to the installer and noticed that mouse did work there. Reinstall.
And again mouse is not working.

I took also wireless keyboard with mousepad - logitech k400 plus - which I was using with FreeBSD 10.x without any problem.

Keyboard is working touchpad not.

usbconfig -u 4 -a 2 dump_curr_config_desc resulted:

Code:
ugen4.2: <Logitech USB Receiver> at usbus4, cfg=0 md=HOST spd=FULL (12Mbps) pwr=ON (98mA)


 Configuration index 0

    bLength = 0x0009
    bDescriptorType = 0x0002
    wTotalLength = 0x0054
    bNumInterfaces = 0x0003
    bConfigurationValue = 0x0001
    iConfiguration = 0x0004  <RQR24.01_B0023>
    bmAttributes = 0x00a0
    bMaxPower = 0x0031

    Interface 0
      bLength = 0x0009
      bDescriptorType = 0x0004
      bInterfaceNumber = 0x0000
      bAlternateSetting = 0x0000
      bNumEndpoints = 0x0001
      bInterfaceClass = 0x0003  <HID device>
      bInterfaceSubClass = 0x0001
      bInterfaceProtocol = 0x0001
      iInterface = 0x0000  <no string>

      Additional Descriptor

      bLength = 0x09
      bDescriptorType = 0x21
      bDescriptorSubType = 0x11
       RAW dump:
       0x00 | 0x09, 0x21, 0x11, 0x01, 0x00, 0x01, 0x22, 0x3b,
       0x08 | 0x00

     Endpoint 0
        bLength = 0x0007
        bDescriptorType = 0x0005
        bEndpointAddress = 0x0081  <IN>
        bmAttributes = 0x0003  <INTERRUPT>
        wMaxPacketSize = 0x0008
        bInterval = 0x0008
        bRefresh = 0x0000
        bSynchAddress = 0x0000


    Interface 1
      bLength = 0x0009
      bDescriptorType = 0x0004
      bInterfaceNumber = 0x0001
      bAlternateSetting = 0x0000
      bNumEndpoints = 0x0001
      bInterfaceClass = 0x0003  <HID device>
      bInterfaceSubClass = 0x0001
      bInterfaceProtocol = 0x0002
      iInterface = 0x0000  <no string>

      Additional Descriptor

      bLength = 0x09
      bDescriptorType = 0x21
      bDescriptorSubType = 0x11
       RAW dump:
       0x00 | 0x09, 0x21, 0x11, 0x01, 0x00, 0x01, 0x22, 0x94,
       0x08 | 0x00

     Endpoint 0
        bLength = 0x0007
        bDescriptorType = 0x0005
        bEndpointAddress = 0x0082  <IN>
        bmAttributes = 0x0003  <INTERRUPT>
        wMaxPacketSize = 0x0008
        bInterval = 0x0002
        bRefresh = 0x0000
        bSynchAddress = 0x0000


    Interface 2
      bLength = 0x0009
      bDescriptorType = 0x0004
      bInterfaceNumber = 0x0002
      bAlternateSetting = 0x0000
      bNumEndpoints = 0x0001
      bInterfaceClass = 0x0003  <HID device>
      bInterfaceSubClass = 0x0000
      bInterfaceProtocol = 0x0000
      iInterface = 0x0000  <no string>

      Additional Descriptor

      bLength = 0x09
      bDescriptorType = 0x21
      bDescriptorSubType = 0x11
       RAW dump:
       0x00 | 0x09, 0x21, 0x11, 0x01, 0x00, 0x01, 0x22, 0x62,
       0x08 | 0x00

     Endpoint 0
        bLength = 0x0007
        bDescriptorType = 0x0005
        bEndpointAddress = 0x0083  <IN>
        bmAttributes = 0x0003  <INTERRUPT>
        wMaxPacketSize = 0x0020
        bInterval = 0x0002
        bRefresh = 0x0000
        bSynchAddress = 0x0000
I read USB Device class specification: http://www.usb.org/developers/hidpage/HID1_11.pdf
Description by usbconfig:
Code:
Inteface # 0 - default // ok
Interface # 1:
      bInterfaceClass = 0x0003  <HID device> // ok
      bInterfaceSubClass = 0x0001 // devices requiring BIOS support
      bInterfaceProtocol = 0x0002 // mouse???
Interface # 2:
      bInterfaceClass = 0x0003  <HID device> //ok
      bInterfaceSubClass = 0x0000 // No subclass
      bInterfaceProtocol = 0x0000 // protocol none???
However according to specification - protocol Codes:
Code:
Protocol Code
0 None
1 Keyboard
2 Mouse
3 - 255
Reserved
My conclusion is - data presented by usbconfig are not consistent.
It should looks like:
Code:
Interface # 1:
      bInterfaceClass = 0x0003  <HID device> // ok
      bInterfaceSubClass = 0x0001 // devices requiring BIOS support
      bInterfaceProtocol = 0x0001 // keyboard

Interface # 2:
      bInterfaceClass = 0x0003  <HID device> //ok
      bInterfaceSubClass = 0x0000 // No subclass
      bInterfaceProtocol = 0x0002 // mouse
Can someone tell me how to check which interface is connected to /dev/ukbd node?
 
OP
OP
Jorg

Jorg

New Member


Messages: 6

I went back to installer again to check if it my mouse problem was related to zfs installation.

I installed FreeBSD with standard configuration. And mouse is working now.
I connected also wireless keyboard with touchpad and is working too.

ls /dev/u* results:
Code:
...
/dev/uhid0
/dev/uhid1
/dev/ukbd0
/dev/ukbd1
/dev/ums0
/dev/ums1
...
So it is something related to zfs installation.
And I did zfs installation to benchmark it and check how it works as desktop.
What shall I do next ? Who should I ask for help?
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 6,971
Messages: 28,968

So it is something related to zfs installation.
I can assure you that the type of filesystem being used is completely irrelevant.
 

tobik@

Daemon
Developer

Reaction score: 1,361
Messages: 1,909

Mousepads respective touchpads are NO mice!
Read this please.
I'm using the Logitech K400 right now to type this message and I can assure you that the touchpad on it is presented as a normal USB mouse to the system.
 

ILUXA

Aspiring Daemon

Reaction score: 411
Messages: 649

After upgrade from 10.4 to 12.0 via # freebsd-update,
my USB mouse stopped working... I see nothing strange or unusual
in /var/log/messages / # dmesg, OS recognizes it well, but it isn't working…
Anyone had this issue? Mouse isn't working in console also.
 

jb_fvwm2

Daemon

Reaction score: 181
Messages: 1,692

I've had that happen once, not due to a reinstall though, and either rebooted the machine, or re-plugged in the mouse. Sorry if no help. here.
 

ILUXA

Aspiring Daemon

Reaction score: 411
Messages: 649

Thanks, but I tried to plug/unplug, reboot, spells, black magic... :D
But none of this helped.
 

ILUXA

Aspiring Daemon

Reaction score: 411
Messages: 649

Noticed that moused is unable to start.
When I'm trying to start it manually it prints
Code:
Starting default mousedmoused: unable to open /dev/psm0: No such file or directory
Now the only info that I can find about my mouse via # dmesg is
Code:
Dec 19 03:09:52 HOME kernel: ugen4.2: <PixArt USB Optical Mouse> at usbus4
P.S.: mouse works fine - 100%, tested on another machine.
 

Martin Paredes

Member

Reaction score: 20
Messages: 69

I can't help you, if you don't cooperate (I ask you for some output)

When I'm trying to start it manually it prints
Code:
Starting default mousedmoused: unable to open /dev/psm0: No such file or directory
What command did you use?

/dev/psm0 is a device file for PS/2 mouse, your is USB, it requires /dev/ums0

Now the only info that I can find about my mouse via # dmesg is
Code:
Dec 19 03:09:52 HOME kernel: ugen4.2: <PixArt USB Optical Mouse> at usbus4
With the mouse connected, what is the output of dmesg | grep ^ums

USB mice are initialized by devd(8), try removing everything related to moused in /etc/rc.conf and reboot
 

ILUXA

Aspiring Daemon

Reaction score: 411
Messages: 649

With the mouse connected, what is the output of dmesg | grep ^ums

USB mouses are initialized by devd(8), try removing everything related to moused in /etc/rc.conf and reboot
1. Empty output.

2. I already tried that, the situation is the same.

BTW, google search suggestions shows "freebsd 12 mouse", so probably someone had this problem, but I cannot find any solution.
 

Martin Paredes

Member

Reaction score: 20
Messages: 69

1. Empty output.
It seems that FreeBSD is not attaching a driver (it is no recognizing your mouse)

Unplug the mouse, go to the console (Ctrl + Alt + F1)

What is printed when you connect your mouse?

Try with another mouse (one more generic) to check if ums(4) is working
 

ILUXA

Aspiring Daemon

Reaction score: 411
Messages: 649

SOLVED :D
The solution was very easy, I just had to execute # kldload ums.

So, it seems, starting from 12-RELEASE, this kernel module is not in GENERIC kernel anymore
(why? may be it is a bug?).

So, if someone also have this issue, add ums_load="YES" to /boot/loader.conf and reboot.
 
Last edited:

trev

Aspiring Daemon

Reaction score: 127
Messages: 665

Same problem - same solution. Upgraded from an old (working) 12-CURRENT to 12-STABLE and the mouse device failed to be populated in /dev/ ... kldload ums fixes it.

Code:
Feb 10 22:44:29 citadel kernel: ums0 on uhub3
Feb 10 22:44:29 citadel kernel: ums0: <EP2> on usbus0
Feb 10 22:44:29 citadel kernel: ums0: 3 buttons and [XYZ] coordinates ID=0
 
Top