Skip to content

mge-hid: add Eaton 5P Gen2 models to mge_model_names - #3617

Open
setnicka wants to merge 1 commit into
networkupstools:masterfrom
setnicka:eaton-5p-gen2
Open

mge-hid: add Eaton 5P Gen2 models to mge_model_names#3617
setnicka wants to merge 1 commit into
networkupstools:masterfrom
setnicka:eaton-5p-gen2

Conversation

@setnicka

@setnicka setnicka commented Sep 4, 2026

Copy link
Copy Markdown

Adds the Eaton 5P Gen2 model strings to mge_model_names[].

The Gen2 units report iModel strings like "650iR G2", which match no entry in the table, so mge_type stays MGE_DEFAULT. Both mge_battery_voltage_fun() and mge_battery_voltage_nominal_fun() return NULL for unknown types, so battery.voltage and battery.voltage.nominal are dropped although UPS.PowerSummary.Voltage and .ConfigVoltage are parsed fine. Same mechanism as #2380, different models.

Tested against an Eaton 5P 650iR G2 (0463:ffff, iProduct "Eaton 5P", firmware 00.04.0015). Before the change:

get_model_name(Eaton 5P, 650iR G2)
[D2] Path: UPS.PowerSummary.Voltage, Type: Feature, ReportID: 0x07,
     Offset: 40, Size: 16, Value: 13.7
[D5] Lookup [13.7] failed for [battery.voltage]

so upsc showed device.model: Eaton 5P 650iR G2 (the concatenation fallback, i.e. nothing matched) and no battery.voltage. After the change both battery.voltage and battery.voltage.nominal are reported.

Only "650iR G2" is confirmed from hardware. The other entries are guesses at the VA ratings and the rack ("iR") / tower ("i") form factors of the Gen2 range, similarly as the existing 5PX and 5SC blocks. Corrections from anyone with other Gen2 units are welcome. Names are left NULL so ups.model keeps the iProduct + iModel concatenation.

Checklist notes:

  • MGE_HID_VERSION bumped to "MGE HID 1.61".
  • NEWS.adoc bullet added; make spellcheck clean, no docs/nut.dict change.
  • data/driver.list.in untouched: Eaton "5P" / "USB port" / usbhid-ups is already listed at series level.
  • scripts/upower/95-upower-hid.hwdb untouched: usb:v0463pFFFF* is already covered.

Happy to post a NUT DDL dump for this unit if that is useful.

AI disclosure per the template: the initial debug (why the voltage isn't showing) also as the initial draft of the patch was done using Claude Code (Claude Opus 5) and reviewed and tuned manually. The hardware evidence above is from my own unit.

The Gen2 units report iModel strings like "650iR G2", which match no entry
in mge_model_names[], so mge_type stays MGE_DEFAULT. Both
mge_battery_voltage_fun() and mge_battery_voltage_nominal_fun() return NULL
for unknown types, so battery.voltage and battery.voltage.nominal are
dropped although their UPS.PowerSummary.Voltage and .ConfigVoltage source
paths are parsed fine.

Names are assumed per the VA numbers and form factors of the Gen2 range,
as was done before for the 5PX and 5SC series. Bump the subdriver version
so driver.version.data reflects the extended mapping table.

Signed-off-by: Jiří Setnička <setnicka@seznam.cz>
@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown

A ZIP file with standard source tarball and another tarball with pre-built docs for commit 10ee119 is temporarily available: NUT-tarballs-PR-3617.zip.

@jimklimov

Copy link
Copy Markdown
Member

Thanks! CCing @arnaudquette-eaton for cross-check or more ideas

@jimklimov jimklimov added Eaton USB MGE MGE branded devices and (USB) chipsets, now part of Eaton; mostly bcmxcp drivers Incorrect or missing readings On some devices driver-reported values are systemically off (e.g. x10, x0.1, const+Value, etc.) labels Sep 4, 2026
@jimklimov jimklimov added this to the 2.8.6 milestone Sep 4, 2026
@AppVeyorBot

Copy link
Copy Markdown

Build nut 2.8.5.5216-master completed (commit bfff731d6e by @setnicka)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Eaton Incorrect or missing readings On some devices driver-reported values are systemically off (e.g. x10, x0.1, const+Value, etc.) MGE MGE branded devices and (USB) chipsets, now part of Eaton; mostly bcmxcp drivers USB

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants