[Nut-upsuser] Return on experience with an Emerson/Liebert GXT3
clepple at gmail.com
Fri Oct 3 13:42:49 UTC 2014
On Oct 3, 2014, at 7:50 AM, paul.chavent at fnac.net wrote:
> On 10/02/2014 02:39 PM, Charles Lepple wrote:> On Oct 1, 2014, at 9:03 PM, paul.chavent at fnac.net wrote:
>>>> There are some fixes that were added in 2.6.4 to try and work around incorrect exponents in the voltages. You can try starting the usbhid-ups driver directly, adding "-DDD" to see if any messages are logged about "assuming correction factor =". It could be that we did not cover all the different ways those values could be wrong.
> I've tried both belkin-hid and liebert-hid drivers. You can finds logs of the belkin-hid in attachment. I don't see any "assuming correction factor =" messages.
This is what I was referring to (from the belkin-hid log):
1.325782 Report[buf]: (5 bytes) => 05 53 00 48 00
1.325799 Path: UPS.PowerSummary.ConfigVoltage, Type: Feature, ReportID: 0x05, Offset: 16, Size: 16, Value: 0
1.325814 ConfigVoltage = 0 -> assuming correction factor = 1e+08
You may need to bump the debug level to 5 to see the full exponent processing (cf get_unit_expo() in libhid.c). Please gzip the log - it will be big.
> However. Could you give me some more hints please ?
> (1) appart the liebert_line_voltage and liebert_config_voltage functions, i don't see any differences in the belkin-hid and liebert-hid drivers.
> Why not move all liebert related functions in the liebert-hid driver ?
I would prefer not to move things around too much, unless we can get people to test the other models. I realize it is annoying that the subdriver names do not match the brands, but the idea is that the matching happens automatically.
> (2) i don't understand how the driver selection is done ? if i just add the vendorid/productid to the liebert_usb_device_table, the lookup seems to stop in the belkin driver (perhaps because belkin_claim got "possibly supported" and that the "productid" value is present ?).
> How do you suggest to implement the addition of this device ?
> (for my tests, i commented the belkin lookup entry to force the usage of the liebert one).
Right, in usbhid-ups.c, the liebert_subdriver entry is after the belkin_subdriver.
> (3) in the hid report, we have several items with the same name (see attached lsusb dump).
> How it is handled by the lookup table ? Is there any indexing possible ?
I will have more time to look at this later, but at a quick glance, I did not see what you were referring to (the lsusb dump, while comprehensive, is hard to parse). Bear in mind that many vendors duplicate Input and Feature HID elements.
> (4) would it be usefull to add missing items to the driver's hid to nu lookup table (even in the the unmapped part) ?
Sure, although the unmapped entries are just for debugging - we will want to eventually rename them to official NUT names, or comment them out again before checking the driver in to version control.
> Do you recommend me to work on the liebert or on the belkin file ?
> Thanks for your help.
Thanks for testing!
clepple at gmail
More information about the Nut-upsuser