~vcs-imports/nut:openups-rmk

Last commit made on 2018-03-04
Get this branch:
git clone -b openups-rmk https://git.launchpad.net/~vcs-imports/nut

Branch merges

Branch information

Name:
openups-rmk
Repository:
lp:~vcs-imports/nut

Recent commits

07abb7a... by Charles Lepple <email address hidden>

Merge branch 'fix_instcmd_fallback_logging' into openups-rmk

e34d94a... by Charles Lepple <email address hidden>

usbhid-ups: fix instcmd logging before fallback check

The hidups_item pointer needs to be checked for NULL before dereferencing.

985164c... by Charles Lepple <email address hidden>

usbhid-ups: document new hid_descriptor option

b89fd70... by Jim Klimov

Fix the recently added update for Avocent support (#532)

* Problem: snmp-ups segfaults

Solution: base_snmp_template_index() prevented from processing empty argument

Signed-off-by: Barbora Stepankova <email address hidden>

* Problem: index has to be counted for any device not just for daisychain

Solution: counted for both

Signed-off-by: Barbora Stepankova <email address hidden>

* Problem: debug info needs improvement

Solution: added

Signed-off-by: Barbora Stepankova <email address hidden>

* drivers/snmp-ups.c : bump the version for public-release driver fix

* snmp-ups.c : Fix indentation for recent fixes

d173d7a... by Russell King <email address hidden>

OpenUPS: fix current calculations

Monitoring the input and output currents reported through upsc for an
OpenUPS device suggests that it is an energy creation device - the
power out is greater than the power into the system once the battery
is fully charged.

Analysis and measurement reveals several issues:

1. "UPS.PowerStatus.Output.Current" is scaled for NUTs "output.current"
   value, which should be the output current from the UPS.

   However, the value reported for "UPS.PowerStatus.Output.Current" is
   not the output from the UPS terminals to the load, but is the
   current into the LTC3780 buck-boost converter on the output. The
   evidence for this is that with a known constant load, the current
   reported is dependent on whether we are using battery voltage or
   input voltage, and varies as one would expect if it were reporting
   the current supplied to the LTC3780.

2. "UPS.PowerStatus.Input.Current" is scaled for NUTs "input.current"
   value, which should be the input current to the UPS.

   The value reported for "UPS.PowerStatus.Input.Current" follows and
   matches the current supplied to the battery while charging is taking
   place, whether bulk charging or floating.

In order to fix these issues, the general principle of switch mode
power conversion is employed:

  Power out = Power in * Efficiency (where Efficiency is between 0..1)

The fix for "output.current" involves knowing whether the UPS was
powered from the battery or the input voltage (which is the voltage
fed to the LTC3780), calculating the power into the LTC3780 converter,
and using the above equation to refer it to the output.

Fixing "input.current" requires a similar process, except in reverse.
We calculate the power being supplied into the battery, and refer that
back to the input terminals, remembering to sum the current draw from
the LTC3780.

(see https://github.com/networkupstools/nut/issues/516 -- @clepple)

c8dd9e7... by Russell King <email address hidden>

Add generic facility to override HID report descriptor in usbhid-ups

Some UPSes contain HID report descriptors that fail to correctly
describe the contents of reports. For example, the OpenUPS
descriptor fails to set the units, logical maximum and logical
minimum before the corresponding `main item' as required by the HID
specification.

This commit allows an override HID report descriptor to be given to
usbhid-ups which replaces the one produced by the UPS, allowing the
report descriptors to be properly parsed.

With an appropriately fixed report descriptor, OpenUPS reports correct
battery current (+ve for charging, -ve for discharging.)

(see https://github.com/networkupstools/nut/issues/516 -- @clepple)

fe0cc3e... by Russell King <email address hidden>

Skip non-feature HID reports

Input and Output reports are used for interrupt endpoints rather than
control endpoints. HIDGetItemData() only ever requests feature
report IDs, and requesting non-feature report IDs as feature IDs may
lead to undesirable results and errors.

aa4c2bd... by Arnaud Quette

snmp-ups: Add support for Emerson Avocent PM3000 PDU

Signed-off-by: Arnaud Quette <email address hidden>

b16867f... by Arnaud Quette

snmp-ups: various improvements

This prepares the addition of newer devices

Signed-off-by: Arnaud Quette <email address hidden>

51320fb... by Charles Lepple <email address hidden>

Fix AC_MSG_*() quoting

The autoconf quote characters are `[` and `]` - no need for `"`.