[Nut-upsuser] No USB/HID UPS found

Vladimir Botka vlado at botka.homeunix.org
Mon May 8 05:55:22 UTC 2006


Hi Peter,

in FreeBSD usb driver is attached to USB controller. During the "bus 
enumeration" "device generic USB driver" is attached (uhid in our case).

If there is no known working FreeBSD installation I expect that we will 
have to do some lower level debuging which will be more time consuming.

Is there any working *BSD installation ?

  -vlado

*** usb0 and uhid0 attached

root.srv# cat /var/run/dmesg.boot
...
uhci0: <VIA 83C572 USB controller> port 0xe100-0xe11f irq 21 at device 
16.0 on pci0
uhci0: [GIANT-LOCKED]
usb0: <VIA 83C572 USB controller> on uhci0
usb0: USB revision 1.0
uhub0: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhid0: American Power Conversion Back-UPS CS 500 FW:808.q5.I USB FW:q5, 
rev 1.10/0.06, addr 2, iclass 3/0
...

*** debugging output from libusb

root.srv# USB_DEBUG=2 /usr/local/libexec/nut/newhidups -u root -DD auto
Network UPS Tools: New USB/HID UPS driver 0.28 (2.0.3)

debug level is '2'
usb_set_debug: Setting debugging level to 2 (on)
usb_os_find_busses: Found /dev/usb0
usb_os_find_busses: Found /dev/usb1
usb_os_find_busses: Found /dev/usb2
usb_os_find_busses: Found /dev/usb3
No appropriate HID device found
No matching USB/HID UPS found

*** libusb ver.0.1.10

root.srv# ll /var/db/pkg/ | grep usb
drwxr-xr-x  2 root  wheel      512 May  6 08:34 libusb-0.1.10a_2
drwxr-xr-x  2 root  wheel      512 May  6 19:53 nut-usb-2.0.3





On Sun, 7 May 2006, Peter Selinger wrote:

> Hi Vlado,
>
> I don't know what most of this means, but since NUT is not seeing
> anything, this must be a libusb problem. As far as I know, libusb does
> not use /dev/uhid* on *BSD; it uses /dev/usb*. Also, the fact that
> /dev/uhid0 shows the "nutmon" group does not mean that anything is
> attached there.
>
> Could you try re-running the driver with USB_DEBUG=2, as follows
> (assuming a bash shell):
>
> USB_DEBUG=2 newhidups -u root -DD auto
>
> This should produce some debugging output from libusb. Also, I am not
> sure if your libusb is up-to-date or not; make sure you have at least
> libusb-0.1.10a.
>
> Do any BSD people on this list have better advice? -- Peter
>
>
> Vladimir Botka wrote:
>>
>> Hi Peter,
>>
>> ***
>> libusb is installed and cached:
>>
>> root.srv# ldconfig -r | grep libusb
>>          54:-lusbhid.1 => /usr/lib/libusbhid.so.1
>>          138:-lusb-0.1.8 => /usr/local/lib/libusb-0.1.so.8
>>          139:-lusbpp-0.1.8 => /usr/local/lib/libusbpp-0.1.so.8
>>
>> ***
>> I think FreeBSD equivalent of lsusb is usbdevs:
>>
>> root.srv# usbdevs -d -v
>> Controller /dev/usb0:
>> addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
>> VIA(0x0000), rev 1.00
>>    uhub0
>>   port 1 powered
>>   port 2 addr 2: low speed, self powered, config 1, Back-UPS CS 500
>> FW:808.q5.I USB FW:q5(0x0002), American Power Conversion(0x051d), rev 0.06
>>     uhid0
>> Controller /dev/usb1:
>> addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
>> VIA(0x0000), rev 1.00
>>    uhub1
>>   port 1 powered
>>   port 2 powered
>> Controller /dev/usb2:
>> addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
>> VIA(0x0000), rev 1.00
>>    uhub2
>>   port 1 powered
>>   port 2 powered
>> Controller /dev/usb3:
>> addr 1: full speed, self powered, config 1, UHCI root hub(0x0000),
>> VIA(0x0000), rev 1.00
>>    uhub3
>>   port 1 powered
>>   port 2 powered
>>
>> ***
>> the driver is attached:
>>
>> root.srv# ll /dev/ | grep uhid
>> crw-rw----  1 root   nutmon    241,   0 Apr 25 15:47 uhid0
>>
>> but reports only changes:
>>
>> root.srv# usbhidctl -f /dev/uhid0 -v -a
>> usbhidctl: device does not support immediate mode, only changes reported.
>>
>> Thank you for your help. -vlado
>>
>> On Sat, 6 May 2006, Peter Selinger wrote:
>>
>>> Hi Vlado,
>>>
>>> your issue seems to be an issue of lower-level USB support. Not only
>>> does NUT fail to find your ups, but it fails to find *any* USB devices
>>> or controllers. Normal output from "newhidups -u root -DDDDD auto"
>>> should look like this:
>>>
>>> Network UPS Tools: New USB/HID UPS driver 0.28 (2.1.0)
>>>
>>> debug level is '5'
>>> Checking device (0000/0000) (003/001)
>>> - VendorID: 0000
>>> - ProductID: 0000
>>> - Manufacturer: Linux 2.6.11-1.1369_FC4 uhci_hcd
>>> - Product: UHCI Host Controller
>>> - Serial Number: 0000:00:1d.1
>>> - Bus: 003
>>> Trying to match device
>>> Device does not match - skipping
>>> Checking device (0000/0000) (002/001)
>>> - VendorID: 0000
>>> - ProductID: 0000
>>> - Manufacturer: Linux 2.6.11-1.1369_FC4 uhci_hcd
>>> - Product: UHCI Host Controller
>>> - Serial Number: 0000:00:1d.0
>>> - Bus: 002
>>> Trying to match device
>>> Device does not match - skipping
>>> Checking device (04B3/310B) (002/002)
>>> - VendorID: 04b3
>>> - ProductID: 310b
>>> - Manufacturer: unknown
>>> - Product: unknown
>>> - Serial Number: unknown
>>> - Bus: 002
>>> Trying to match device
>>> Device does not match - skipping
>>>
>>> [...]
>>>
>>> No appropriate HID device found
>>> No matching USB/HID UPS found
>>>
>>> Perhaps you don't have libusb installed? Is "lsusb" showing anything
>>> on your system? -- Peter
>>>
>>> Vladimir Botka wrote:
>>>>
>>>> Hello,
>>>>
>>>> Help me please with *newhidups* setup. Does it work for someone on *BSD ?
>>>>
>>>>
>>>> Here is the data.
>>>> ---------------------------------------------------------------
>>>>
>>>> *** FreeBSD
>>>> root.srv# uname -a
>>>> FreeBSD xxxxxx.dyndns.info 5.3-RELEASE FreeBSD 5.3-RELEASE #2: Tue Feb 8
>>>> 07:38:22 UTC 2005
>>>> admin at temp.botka.homeunix.org:/usr/src/sys/i386/compile/SRV  i386
>>>>
>>>> *** NUT ver.2.0.3
>>>> root.srv# ll /var/db/pkg/ | grep nut
>>>> drwxr-xr-x  2 root  wheel      512 May  6 19:53 nut-2.0.3
>>>> drwxr-xr-x  2 root  wheel      512 May  6 19:53 nut-usb-2.0.3
>>>>
>>>> *** usbd can see the UPS on /dev/uhid0
>>>> root.srv# usbdevs -v -d -a 2
>>>> Controller /dev/usb0:
>>>> addr 2: low speed, self powered, config 1, Back-UPS CS 500 FW:808.q5.I USB
>>>> FW:q5(0x0002), American Power Conversion(0x051d), rev 0.06
>>>>    uhid0
>>>> Controller /dev/usb1:
>>>> Controller /dev/usb2:
>>>> Controller /dev/usb3:
>>>>
>>>> *** HERE IS THE PROBLEM
>>>> root.srv# /usr/local/libexec/nut/newhidups -u root -DDDDD auto
>>>> Network UPS Tools: New USB/HID UPS driver 0.28 (2.0.3)
>>>>
>>>> debug level is '5'
>>>> No appropriate HID device found
>>>> No matching USB/HID UPS found
>>>>
>>>> root.srv# /usr/local/libexec/nut/newhidups -a myups -u root -DDDDD /dev/uhid0
>>>> Network UPS Tools: New USB/HID UPS driver 0.28 (2.0.3)
>>>>
>>>> debug level is '5'
>>>> No appropriate HID device found
>>>> No matching USB/HID UPS found
>>>>
>>>> root.srv# cat /usr/local/etc/nut/ups.conf
>>>> [myups]
>>>>          driver = newhidups
>>>>          port = /dev/uhid0
>>>>          desc = "Back-UPS CS 500"
>>>>
>>>> ------------------------------------------------------------------
>>>>
>>>> Thank you for your afford.
>>>>
>>>> Cheers,
>>>>
>>>>   -vlado
>>>>
>>>> _______________________________________________
>>>> Nut-upsuser mailing list
>>>> Nut-upsuser at lists.alioth.debian.org
>>>> http://lists.alioth.debian.org/mailman/listinfo/nut-upsuser
>>>>
>>>
>>>
>>>
>>
>
>
>



More information about the Nut-upsuser mailing list