springfall2008 / batpred

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

Discharge with Octopus Intelligent and Export tariff #91

Closed SheriffOfNotts closed 11 months ago

SheriffOfNotts commented 11 months ago

Hi Trefor,

As per FB, last night there was 69% battery remains at 21:43, with the Intelligent off-peak rate starting at 23:30.

Any idea why it wasn't discharging? Logs from today enclosed. I will update when it happens again.

EA43D431-888E-4E0B-81BC-87791AAC72E2_1_105_c

appdaemon.log

springfall2008 commented 11 months ago

Looking at your log you had a few errors with some data timeouts, but they seemed to go away.

You don't have much discharge planned now as you are due to run out of battery.

If this evening you have spare battery please snapshot the battery chart and the log again and post it here

SheriffOfNotts commented 11 months ago

Hi Trefor, same again last night - see enclosed logs and photos.. Appreciate you looking into it..

IMG_1532 IMG_1536 appdaemon3.log appdaemon2.log appdaemon1.log appdaemon.log

springfall2008 commented 11 months ago

Unfortunately the logs only show from this morning onwards.

For tonight i see a planned discharge in the log, can you post the Predbat battery chart?

Next discharge window will be: 2023-09-23 22:55:00+01:00 - 2023-09-23 23:00:00+01:00 at reserve 39.0

SheriffOfNotts commented 11 months ago

Hi, current chart enclosed..

image
springfall2008 commented 11 months ago

So now it's not predicting a discharge today as the batter level expected must be below your minimum. What do you have metric_soc_min and metric_soc_keep set to?

SheriffOfNotts commented 11 months ago

I can't see those exact entities - are these the ones?..

image
springfall2008 commented 11 months ago

So your plan seemed correct, that is the keep was 2.7 and it was ending around 2.7

If you can capture the log for the hour before the charge window I can check further

SheriffOfNotts commented 11 months ago

I had a forced discharge period last night which discharged the battery to 27%. Do you know why it wouldn't be discharging to the defined 4%?

Unfortunately the logs look to have been reset to this morning - can I check my config is correct? I have tried log_generations, but this just seems to spread the logs across multiple files rather that chronologically?

logs: error_log: filename: /config/appdaemon/logs/error.log main_log: filename: /config/appdaemon/logs/appdaemon.log log_size: 8192 access_log: filename: /config/appdaemon/logs/access.log diag_log: filename: /config/appdaemon/logs/diag.log

springfall2008 commented 11 months ago

You have Best SOC Keep set to 2.7 so that would be the target discharge level, if you reduce this you should get more.

One thing I did wonder about adding as a feature is some sort of scaling of SOC keep so as it gets closer to a charge slot it scales down .

SheriffOfNotts commented 11 months ago

Thank you - I'll update it. The approach sounds spot on :)

Can I check the log configuration is correct?

springfall2008 commented 11 months ago

I just set the main_log, this contains all the Predbat stuff. Then if there is an error I check in System/Logs/AppDeamon in the HA gui to see any more details.

logs: main_log: filename: /config/appdaemon.log

SheriffOfNotts commented 11 months ago

Thank you

springfall2008 commented 11 months ago

Closing for now, feel free to open a new ticket if you get further issues