Skip to content

idowell-hid: add GoldenMate 1000VA/800W LiFePO4 (USB ID 06da:ffff)#3502

Merged
jimklimov merged 2 commits into
networkupstools:masterfrom
bshor:goldenmate-06da-ffff
Jun 28, 2026
Merged

idowell-hid: add GoldenMate 1000VA/800W LiFePO4 (USB ID 06da:ffff)#3502
jimklimov merged 2 commits into
networkupstools:masterfrom
bshor:goldenmate-06da-ffff

Conversation

@bshor

@bshor bshor commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

Summary

GoldenMate ships the same -BMS- firmware with an identical 291-byte HID descriptor across multiple USB vendor/product IDs. The 075d:0300 variant was already added to this subdriver in #3015. This PR adds 06da:ffff (Phoenixtec VID), which was previously falling through to the generic Phoenixtec/Liebert HID subdriver.

Device: GoldenMate 1000VA/800W Sinewave UPS with LiFePO4 Battery (230Wh), USB ID 06da:ffff, manufacturer string -BMS-, product string Smart-Battery.

Problem: Without this change the device matches Phoenixtec/Liebert HID 0.41 and reports battery.runtime = 599940 seconds — a firmware placeholder value. The iDowell subdriver mappings (which were already extended for the identical 075d:0300 firmware) handle this device correctly.

Evidence that HID descriptors are identical: Both devices report the same 291-byte report descriptor (05 84 09 04 a1 01 ...), the same 28 HID objects, and the same LogMax < LogMin quirks in ReportID 0x01 and 0x02.

Tracked in #3501.

Changes

  • drivers/idowell-hid.c: add 06da:ffff to the USB device table
  • data/driver.list.in: split GoldenMate entry into two lines with correct model names, USB IDs, support level 2, and issue links

@github-actions

github-actions Bot commented Jun 23, 2026

Copy link
Copy Markdown

Preparing a ZIP file with standard source tarball and another tarball with pre-built docs for commit 58e1791 ...

@jimklimov jimklimov added USB Phoenixtec (USB 0x06DA/0xFFFF) This USB chip VID/PID is used in many devices, some with different protocols - detection may be hard Incorrect or missing readings On some devices driver-reported values are systemically off (e.g. x10, x0.1, const+Value, etc.) labels Jun 23, 2026
@jimklimov jimklimov added this to the 2.8.6 milestone Jun 23, 2026
@jimklimov jimklimov added the HCL label Jun 23, 2026
@jimklimov

Copy link
Copy Markdown
Member

Hello, thanks for the contribution, but it would not work the way it is originally posted, I think (might hijack devices not intended for this subdriver) - see also mge-hid.c which also deals with PHOENIXTEC_VENDORID.

To make the PR acceptable, you would need to:

  • actually define the vendor ID in the subdriver source (this is used by parser into udev rules, nut-scanner helper data, etc.), and refer to it from the ...device_table[]:
/* Phoenixtec Power Co., Ltd */
#define PHOENIXTEC_VENDORID     0x06da

...
    { USB_DEVICE(PHOENIXTEC_VENDORID, 0xffff), NULL },
  • Revise the idowell_claim() method to do something like what mge_claim() does to pick assumed-handled devices by vendor/product strings, and defer others to liebert-hid as the default sink.
  • Bump the IDOWELL_HID_VERSION
  • Adding a bullet point in NEWS.adoc would be a nice touch :)
  • While at it, adding a Signed-off-by line into the commit comment would be another nice touch, see https://github.com/networkupstools/nut/wiki/Code-contributions,-PRs,-PGP-and-DCO

Looking forward to getting this merged (mergeable) :)

@AppVeyorBot

Copy link
Copy Markdown

Build nut 2.8.5.4863-master completed (commit 1f91f12f6a by @bshor)

@AppVeyorBot

Copy link
Copy Markdown

@bshor bshor force-pushed the goldenmate-06da-ffff branch from e98f778 to 362952e Compare June 23, 2026 18:18
@bshor

bshor commented Jun 23, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the detailed review! I've force-pushed a revision that addresses all the points:

  • Named vendor ID: added #define PHOENIXTEC_VENDORID 0x06da and use it for the 0x06da:0xffff device-table entry instead of the bare literal.
  • Guarded claim: reworked idowell_claim() to mirror mge_claim()'s approach — on the shared PHOENIXTEC_VENDORID it now only claims the GoldenMate by its firmware strings (manufacturer -BMS- / product Smart-Battery) and returns 0 otherwise, so AEG PROTECT NAS still goes to mge-hid and everything else on 0x06da falls through to liebert-hid as the default sink. The 0x075d iDowell VID is unique, so it stays claimed unconditionally. (Probe order is mge -> idowell -> liebert, so this intercepts only GoldenMate before liebert.)
  • Version: bumped IDOWELL_HID_VERSION to 0.21.
  • NEWS.adoc: added a bullet under the usbhid-ups driver updates.
  • DCO: the commit is now Signed-off-by.

I don't have a second 0x06da (AEG/Liebert) device on hand to confirm the deferral empirically, but the string gate is conservative — please let me know if you'd prefer a tighter match (e.g. requiring both strings).

…ther Phoenixtec devices

GoldenMate 1000VA/800W LiFePO4 packs reuse the shared Phoenixtec vendor
ID 0x06da:0xffff with the same -BMS- firmware and HID descriptor as the
existing iDowell 0x075d:0x0300 device, so they fall back to the generic
liebert-hid handler (bogus battery.runtime, etc).

The 0x06da VID is shared: mge-hid claims it for AEG PROTECT NAS and
liebert-hid is its default sink. Probe order is mge -> idowell -> liebert,
so idowell can intercept GoldenMate before liebert provided it does not
grab the other 0x06da devices.

- Add a named PHOENIXTEC_VENDORID define and use it for the 0x06da:0xffff
  device-table entry (feeds the udev/nut-scanner parser).
- Gate idowell_claim() on the device's -BMS-/Smart-Battery strings, like
  mge_claim() does for AEG, returning 0 for non-GoldenMate 0x06da so they
  fall through to liebert-hid / mge-hid.
- Bump IDOWELL_HID_VERSION to 0.21 and add a NEWS.adoc entry.
- List both GoldenMate variants in data/driver.list.in.

Fixes: networkupstools#3501
Signed-off-by: Boris Shor <boris@bshor.com>
@bshor bshor force-pushed the goldenmate-06da-ffff branch from 362952e to 0279a35 Compare June 23, 2026 18:32
@AppVeyorBot

Copy link
Copy Markdown

@AppVeyorBot

Copy link
Copy Markdown

Build nut 2.8.5.4866-master completed (commit 7b439e97bc by @bshor)

@AppVeyorBot

Copy link
Copy Markdown

@jimklimov

Copy link
Copy Markdown
Member

Looks great, thanks!

Out of curiosity, was AI involved in this PR or is it all a manually investigated and made change?

@bshor

bshor commented Jun 24, 2026

Copy link
Copy Markdown
Contributor Author

Definitely AI assisted -- Claude Code Opus. I'm overseeing it, but it's handling most of the work.

@jimklimov jimklimov merged commit da5e3ff into networkupstools:master Jun 28, 2026
2 of 4 checks passed
@jimklimov jimklimov added the AI For good or bad, machine tools are upon us. Humans are still the responsible ones. label Jun 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AI For good or bad, machine tools are upon us. Humans are still the responsible ones. HCL Incorrect or missing readings On some devices driver-reported values are systemically off (e.g. x10, x0.1, const+Value, etc.) Phoenixtec (USB 0x06DA/0xFFFF) This USB chip VID/PID is used in many devices, some with different protocols - detection may be hard USB

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

3 participants