[Nut-upsuser] NUT Two Apc UPSes on Windows
Frédéric Bohé
fredericbohe at eaton.com
Wed Mar 7 13:20:56 UTC 2012
Hello Rafal,
On Mon, 2012-03-05 at 01:29 +1100, Rafał Pawłaszek wrote:
> Hi,
>
> I've got a question about managing two UPSes under NUT.
>
> I have two similar model APC usb-connected UPSes to work with, but
> don't know how to manage them simultaneously from under Windows. Long
> story short, my ups.conf looks like this:
>
> --- ups.conf ---
> [ups1]
> driver= usbhid-ups
> port= auto
> serial=AS1054340323
> [ups2]
> driver= usbhid-ups
> port= auto
> serial=AS1026662626
> --- ups.conf ---
>
> I tried all the combinations with vendorid, productid, vendor, product
> as in the manual for usbhid-ups and libusb's test
>
> --- TestLibUsb ---
> - Manufacturer : American Power Conversion
> - Product : Smart-UPS X 1500 FW:COM 03.6 / UPS 03.6
> - Serial Number: AS1054340323
> ...
> idVendor: 051Dh
> idProduct: 0003h
> ...
> - Manufacturer : American Power Conversion
> - Product : Smart-UPS X 1500 FW:COM 03.0 / UPS 03.1
> - Serial Number: AS1026662626
> ...
> idVendor: 051Dh
> idProduct: 0003h
> ...
> --- TestLibUsb ---
>
> and tested them with usbhid-ups -a ups1 or usbhid-ups -a ups2.
> Moreover, the parameter productid included in the specs in ups.conf
> caused error: "GenerateConsoleCtrlEvent error : 87".
>
> Issuing usbhid-ups -a ups1 or usbhid-ups -a ups2 works, but
> 1. exclusively - I can see only one UPS at a time (trying to run
> second ups while the first is running gives: "Can't claim USB device
> [051d:0003]: libusb0-dll:err [claim_interface] could not claim
> interface 0, win error: The requested resource is in use)
> 2. randomly - This means that no matter what I put into ups.conf
> NUT will pick anything that responds first.
> which eventually is useless.
>
> Thus my question is whether it is an error of usblib or NUT's
> usbhid-ups and more importantly: how to overcome this?. usblib itself
> is capable of enumerating the devices that's why I'm issuing my
> question here.
I have just tested this kind of dual USB setup on Windows XP and it
works with latest SVN. That is to say I managed to run 2 usbhid-ups
drivers at the same time connected to 2 different UPS.
It doesn't work with NUT's site binaries because of a bug in regex which
crash the driver.
What version of NUT are you using ?
Have you compiled your own binaries ?
What Windows version are you using.
While trying to mimic your ups.conf I found that you should add
whitespace around the '=' sign in the conf file: you should use
"serial = AS1026662626"
rather than
"serial=AS1026662626".
This is a bug in Windows version, I will check.
Regards,
Fred
>
> Thanks in advance for help,
> Rafal
> _______________________________________________
> Nut-upsuser mailing list
> Nut-upsuser at lists.alioth.debian.org
> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/nut-upsuser
--
Team Open Source Eaton - http://powerquality.eaton.com
--------------------------------------------------------------------------
More information about the Nut-upsuser
mailing list