On Dec 16, 2018, at 6:07 PM, James <[email protected]> wrote:

>> Which driver is this?
> 
...
> device.mfr: CPS
> device.model: UPS CP850AVRLCD
> device.type: ups
> driver.name: usbhid-ups

For a USB HID PDC (Power Device Class) UPS like this, "ups.test.result" comes 
straight from the spec:

https://github.com/networkupstools/nut/blob/v2.7.4/drivers/usbhid-ups.c#L383-L392
 
<https://github.com/networkupstools/nut/blob/v2.7.4/drivers/usbhid-ups.c#L383-L392>

https://www.usb.org/document-library/power-device-class-document-10 
<https://www.usb.org/document-library/power-device-class-document-10> page 26

It is possible to check around for other status bits, but if they are 
non-standard, mapping them back to useful names might be difficult.

I think it would be useful to have a debug dump from before and after replacing 
the battery, if you have the time. Basically, you can kill the driver out from 
under NUT ("killall usbhid-ups" as root), then restart it with "-DDD". If your 
system uses paths similar to Debian/Ubuntu, it will be something like this:

# /lib/nut/usbhid-ups -a desktop_ups -DDD 2>&1 | tee 
/tmp/CP850AVRLCD.debug.old-battery.txt

Let it run for a few seconds, and once it starts looping, you can kill it with 
Ctrl-C. If the log is larger than a few kB, please gzip it before sending.

You can start the driver again with "/lib/nut/usbhid-ups -a desktop_ups", or by 
restarting the whole NUT service if things are not looking right.
_______________________________________________
Nut-upsuser mailing list
[email protected]
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser

Reply via email to