springfall2008 / batpred

Home battery prediction and charging automation for Home Assistant, supporting many inverter types
https://springfall2008.github.io/batpred/
130 stars 44 forks source link

(Automatic?) Conversion between units (watts and kilowatts, but possibly others?) #1643

Open davidarkemp opened 1 week ago

davidarkemp commented 1 week ago

Is your feature request related to a problem? Please describe. Different parts of predbat require input at different scales (pv_power is in watts, for example)

Describe the solution you'd like Where possible, I'd like predbat to use the unit of the sensor to determine how to scale the output. As a sidle effect of this, predbat could also issue warnings when the input isn't an expected unit.

Describe alternatives you've considered At the moment, I'm using a template sensor to convert the value before input to predbat, but this requires extra storage in the db history.

Additional context As a new user, understanding this all has been the major hurdle to getting something setup. At some point, it would be great if there was a UI for all of this that only allowed likely inputs, like the HA Energy Dashboard does.

springfall2008 commented 5 days ago

In some cases Predbat already converts between watts and kw, which case are you refering to?

davidarkemp commented 4 days ago

Specifically: pv_power Until I used a template sensor that does the conversion, predbat.pv_power seemed to be incorrect