-
-
Notifications
You must be signed in to change notification settings - Fork 413
EATON HID: add missing usages and paths (addon) - ABM Statuses #2660
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EATON HID: add missing usages and paths (addon) - ABM Statuses #2660
Conversation
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
|
@arnaudquette-eaton is last commits OK for adding status ? UPS.BatterySystem.Charger.Status |
seems good, though
|
Thanks, if all fine from statuses perspective, I will try to combine them in one function with |
….status for bath in one functions Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Please look at 2 last commits combined to one functions, should look better now. @jimklimov can we merge it also or to merge it in eco branch? |
I think two PRs for two goals are okay. Does this one fully include the commits of the "eco branch"? If yes, merging this one will automatically close that PR as achieved in one shot. |
Yes it is |
but not include conversations ? Sorry still not good enough with git :( |
|
Not sure I fully understand the question. Conversations will remain in github (if they are not part of Git committed code, e.g. new comments about logic), in respective issue/PR discussions. For easier history research later, I'll add a cross-link between these. |
Sorry , i meaned converation like here is 8 only , and in #2637 was 110 and also comments of the code . |
drivers/mge-hid.c
Outdated
| /* ABM (Advanced Battery Monitoring) processing | ||
| * Must be processed before the BOOL status */ | ||
| /* Not published, just to store in internal var. advanced_battery_monitoring */ | ||
| { "battery.charger.abm.status", 0, 0, "UPS.BatterySystem.Charger.ABMEnable", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_enabled_info }, | ||
| { "battery.charger.abm.status", 0, 0, "UPS.BatterySystem.Charger.Status", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_status_enabled_info }, | ||
| { "battery.charger.status", 0, 0, "UPS.BatterySystem.Charger.ABMEnable", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_enabled_info }, | ||
| { "battery.charger.status", 0, 0, "UPS.BatterySystem.Charger.Status", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_enabled_info }, | ||
| /* Same as the one above, but for legacy units */ | ||
| /* Refer to Note 1 (This point will need more clarification!) | ||
| { "battery.charger.status", 0, 0, "UPS.BatterySystem.Charger.PresentStatus.Used", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_enabled_legacy_info }, */ | ||
| /* This data is the actual ABM status information */ | ||
| { "battery.charger.mode", 0, 0, "UPS.BatterySystem.Charger.Mode", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_mode_info }, /* needs both ? from https://github.com/networkupstools/nut/pull/2637#discussion_r1772730590 */ | ||
| { "battery.charger.status", 0, 0, "UPS.BatterySystem.Charger.Status", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_status_info }, /* checked on Eaton 9E Model */ | ||
| { "battery.charger.mode", 0, 0, "UPS.BatterySystem.Charger.Mode", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_info }, /* needs both ? from https://github.com/networkupstools/nut/pull/2637#discussion_r1772730590 */ | ||
| { "battery.charger.status", 0, 0, "UPS.BatterySystem.Charger.Status", NULL, "%.0f", HU_FLAG_QUICK_POLL, eaton_abm_info }, /* checked on Eaton 9E Model */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@arnaudquette-eaton : I am offline today and feel a bit vague on how the mapping tables are processed.
From this commit, it seems we can set battery.charger.status from several sources above (once from the same UPS.BatterySystem.Charger.Status source, but with eaton_abm_enabled_info instead of eaton_abm_info)... Would this line even work (or would the loop finish at first hit... and what counts as a hit - seeing a reading from the source, or specifically a non-NULL return (so both referenced functions have a chance to run even this way)?
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
|
❌ Build nut 2.8.2.2256-master failed (commit d7d9767a3e by @masterwishx) |
Signed-off-by: DaRK AnGeL <28630321+masterwishx@users.noreply.github.com>
| * Synthesis table | ||
| * HID data | Charger in ABM mode | Charger in Constant mode | Error | Good | | ||
| * UPS.BatterySystem.Charger.ABMEnable | 1 | 0 | | | | ||
| * UPS.BatterySystem.Charger.ChargerType | 4 | 5 | | | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just for context: I removed this in my PR because it suggests that ABM is enabled when the charger type is ABM-capable (4), as opposed to ABM-incapable (5). In reality ABM enabled/disabled seems to be controlled only through UPS.BatterySystem.Charger.ABMEnable and not UPS.BatterySystem.Charger.ChargerType. My logic is that an ABM-capable charger type (4) could still have ABM disabled (by the user), so I felt that putting UPS.BatterySystem.Charger.ChargerType here with "Charger in ABM mode" is misleading as it's likely merely ABM-capable and not in fact explicitly in ABM mode (enabled). In general UPS.BatterySystem.Charger.ChargerType seems to be only the textual representation of the charger capabilities, and not the ABM state itself?
if you will have time , still interesting if your ups in ABM disabled mode will always send x.Charging =1 even in 100% charged ? |
5P850I - ABM disabled - 5P850I - ABM enabled - So we can see that in constant charge mode (with ABM disabled), we have
|
Thanks a lot, we will not let decide its just for the info of variable in table: From copilot: |
Yeah i see , but maybe in other Eaton models with ABM it switch to |
battery.charge != 100 ? |
Maybe, we'll have to wait for more data on this (I think), so I'd keep it only as informational variable (for now).
battery.charge = 100 (floating is applying charge so |
Thanks got it |
we can leave as is for now or add something like: Line 1629 in 18e1375
but |
drivers/mge-hid.c
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure what happened here during the merge, but this doesn't seem right. Now we're missing the published UPS.BatterySystem.Charger.ChargerType and have another published UPS.BatterySystem.Charger.Mode entry (but which was already published before)? Can you revert this change? I think it was fine as it was before.
bbeeea6 to
5c202f7
Compare
|
Maybe @jimklimov can help out here with the merge/rebase so that nothing ABM-related is lost. 🙂 |
Fixed |
Please check now |
Looks good - thanks for fixing! |
|
@desertwitch not sure where the error ... |
I can't see any specific error in the logs, although I'm no expert navigating the CI, maybe something unrelated to this PR. |
Yes, sorry it's about CI so @jimklimov can help? I saw some new prs for CI |
Signed-off-by: desertwitch <24509509+desertwitch@users.noreply.github.com>
|
Minor follow up to my code contributions: masterwishx#5 (if possible please merge into this PR) |
…tatus+mode drivers/mge-hid.c: reset ABM path when ABM not enabled
|
CC @jimklimov please check when you will have time if can be merged |
ABM Statuses + Adding Missing usages and paths
See also: https://www.eaton.com/content/dam/eaton/products/backup-power-ups-surge-it-power-distribution/backup-power-ups/power-xpert-9395/Eaton-ABM-White-Paper-AP162001EN.pdf
Continue work/addon for #2637
Added:
Added ABM statuses for Eaton Models with next paths: