USB2 & apcupsd
Hans Petter Selasky
hselasky at c2i.net
Fri Feb 13 01:58:57 PST 2009
On Friday 13 February 2009, Noriyoshi Kawano wrote:
> Hi,
>
> I want to use apcupsd under USB2.
>
> [dmesg]
> ugen0.2: <American Power Conversion> at usbus0
> uhid0: <American Power Conversion Uninterruptible Power Supply, class 0/0,
> rev 1.10/1.06, addr 2> on usbus0 Symlink: uhid0 -> usb0.2.0.16
>
> 1. I recompile apcupsd to use the generic USB drvier.
>
> --- /usr/ports/sysutils/apcupsd/Makefile: line 109 ----
> CONFIGURE_ARGS+= --enable-usb --with-generic-usb
> --------------------------------------------------------
>
> 2. I use libmap.conf to make apcupsd use libusb20.
>
> --- /etc/libmap.conf -------
> [apcupsd]
> libusb-0.1.so.8 libusb20.so
>
> [apctest]
> libusb-0.1.so.8 libusb20.so
>
> [apcaccess]
> libusb-0.1.so.8 libusb20.so
> ----------------------------
>
> It seems to work. But ups communication is interrupted repeatedly.
>
> [/var/log/message]
> Feb 13 11:20:33 brain kernel: uhid0: at ushub0, port 1, addr 2
> (disconnected) Feb 13 11:20:34 brain kernel: uhid0: <American Power
> Conversion Uninterruptible Power Supply, class 0/0, rev 1.10/1.06, addr 2>
> on usbus0 Feb 13 11:20:34 brain kernel: Symlink: uhid0 -> usb0.2.0.16
> Feb 13 11:20:35 brain apcupsd[5846]: Communications with UPS restored.
> Feb 13 11:21:41 brain kernel: uhid0: at ushub0, port 1, addr 2
> (disconnected) Feb 13 11:21:42 brain kernel: uhid0: <American Power
> Conversion Uninterruptible Power Supply, class 0/0, rev 1.10/1.06, addr 2>
> on usbus0 Feb 13 11:21:42 brain kernel: Symlink: uhid0 -> usb0.2.0.16
> Feb 13 11:21:43 brain apcupsd[5846]: Communications with UPS restored.
>
>
> Of course, it works fine under old usb stack.
> Any suggestion ?
Turn on debugging:
sysctl hw.usb2.uhid.debug=15
sysctl hw.usb2.uhub.debug=15
And send me dmesg.
I see that the interval is relativly long, so it might be problem to trace.
--HPS
More information about the freebsd-usb
mailing list