springfall2008 / batpred

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

Accomodation of GivTCP data glitches #1251

Open mpartington opened 1 week ago

mpartington commented 1 week ago

Describe the bug This is not Predbat driven, but perhaps could be accommodated as part off the data filtering. I've recently noticed that if I restart HA, I momentarily get spikes or drops on various parameters. This impacts Predbats calculations, for example it over counts export, which then overestimates the savings.

The screenshot shows the actual export as 9kWh (GivTCP) Vs 25kWh (incorrect - Predbat)

I suspect the same happens with load, but I have a custom sensor set for that, which is not affected

Expected behavior For GivTCP to pass good data (have reported on Beta chat), however failing that is it possible for Predbat to ignore the glitches?

I think you may have accommodated the down spikes in a previous release, so hopefully it's possible to do similar on the upward spike.

Predbat version 8.1.2

GivTCP beta 2.4.324

Environment details

Screenshots

Screenshot_2024-06-25-07-16-33-759_io homeassistant companion android

Screenshot_2024-06-24-22-12-49-902_io homeassistant companion android

Log file Not sure it will capture anything else, but will.provide if needed

mpartington commented 1 week ago

Had to restart again today, and the spike added 4kWh into Predbats export, which spuriously knocked 60p off my accumulated cost for the day.

Screenshot_2024-06-28-05-58-12-001_io homeassistant companion android~2

gcoan commented 1 week ago

I raised a potentially linked issue a couple of days ago #1253, the predbat import and export figures are not correctly being calculated. I'm not seeing spikes but the values were not the same as the givtcp sensors