INA2XX: Permit startup without reset of counters #3322
Replies: 2 comments 2 replies
-
|
i will take care of this |
Beta Was this translation helpful? Give feedback.
2 replies
-
|
PRs submitted: |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Component name
INA2xx
Link to component documentation on our website
https://esphome.io/components/sensor/ina2xx/
Describe the enhancement
Currently, every time the system boots up, counters of the INAXXX device are reset. This fits the standard implementation of the INA chips, where a power loss resets the counters. However, in my case I would like to build the system so that these counters are never reset except on total power-off.
I'd like to request the ability to initialize the component without resetting counters, so that values can persist even through an ESP32 restart as long as the INA chip itself does not lose power. Ideally as some sort of configuration flag in the YAML which can be set to bypass https://github.com/esphome/esphome/blob/3a233b2fd01e7eb525c3ce4575cafad5ceccbb17/esphome/components/ina2xx_base/ina2xx_base.cpp#L261 and ensure counters will remain consistent through ESP32 (re)boots.
Use cases
This would allow me to properly monitor the INAXXX power values long term, without having unrelated ESP32 restarts completely reset the counters.
Anything else?
No response
Beta Was this translation helpful? Give feedback.
All reactions