Second year live on Predbat …

1922 comments started 2024-12-21 last 2026-07-25
Home AutomationHome Assistant
G
#1 geoffreycoan

In the first year ‘first night live on Predbat’ has collected nearly 3,200 comments on our collective experiences, questions, answers and discussions on using Predbat to manage our batteries and solar systems.

https://community.givenergy.cloud/d/3696-first-night-live-on-predbat/

That’s an awful lot to read for any newcomers so its time to start the year 2 thread

Always happy to help

Geoffrey

R
#3 Rbor

Well done for starting this 2nd year thread. 👏👏👏

I can't believe that we reached 3,192 comments.
I would never have got to grips with Predbat or HA without so many helpful comments.

Rob

H
#4 Henry3rd

Rbor I completely agree.

D
#5 Daveb01

geoffreycoan
Rbor

Thank you both for helping me get HA etc up and running this year. I would never have been able to do it without your help. Hope you have a great Christmas and a happy New Year. 🎄🍺

R
#6 Rbor

Daveb01 👍

Rob

D
#7 Daveb01

There was a Predbat update this morning, so have said in my mind this will be the last one I will do before Christmas, I pressed the button and all good phew.

D
#8 DD

geoffreycoan That’s an awful lot to read for any newcomers so its time to start the year 2 thread

Err... Either this thread will contain all the same tips, or a newcomer will still need to read the whole of the first thread too .?
Is predbat on 3.0 now? Would that make sense as a more logical split?

G
#9 geoffreycoan

DD Err... Either this thread will contain all the same tips, or a newcomer will still need to read the whole of the first thread too .?

Possibly they would, and that is of course recommended, but for any newcomers I will summarise the 3100 posts on the other thread:

  • Read the documentation, the answer is (probably) in there already

Is predbat on 3.0 now? Would that make sense as a more logical split?

Latest version is v8.8.12. Version 8 was a fairly major update, I think it was the one where the codebase got split into many modules, but the numbering system is a bit ‘Trefor’ so who knows.

We agreed to split onto a new thread at the 1 year mark. It was going to be 3000 posts but we sailed past that. The split has happened, onwards and forward !

T
#10 TX200

So i think the recommendations was to set the metric for export to 5p

Any ideas on the one above it?

G
#12 geoffreycoan

Finally done it, after running Predbat 8.5.3 which has been quite stable for the last two months, I upgraded just now to the latest Predbat version, 8.8.13.

Interesting comparing the plan before and after:

8.5.3 plan, slightly sub-optimal, I have noticed it had a tendency to occasionally freeze charge unnecessarily e.g. 1900, preserving the SoC for no obvious reason when rates were dropping, and not always discharging when it could do eg 23:00

8.8.13 plan, the two issues identified above on the 8.5.3 plan are gone, but a new query over why Predbat doesn’t start releasing the SoC at 15:30. This may have just have been that the plan cutoff prematurely because the latest plan does show the SoC releasing then.


I thought the 8.8.13 Predbat plan wasn’t that good, overall a bit more expensive than the old 8.5.3 plan.

But 10 minutes later, the latest 8.8.13 plan has improved considerably:

And now its forecasting £1.61 by the end of the plan, so just normal predbat flip-flopping.

Don’t like the new Demand status but guess I’ll have to get used to it. 18 inverter writes since installing, so 9 per inverter. Seems quite a lot when the inverters are Idle/Demanding. Hmm

G
#13 Goshiki2

geoffreycoan yes I’ve noticed my plan has started changing massively at times. I go to bed in the knowledge that Predbat has got it all under control with what seems like a clear and logical plan and then wake up to find it’s actioned something totally different. It almost seems to be reactive at the moment rather than proactive. Agile rates have been good today but in one hour I had 14 register writes which seemed totally unnecessary to me as the load prediction was stable and I hadn’t made any changes myself.

G
#14 geoffreycoan

I've found one cause of the extra inverter register writes, the battery pause end time is being repeatedly set to 23:59:00 then 00:00:00 in each Predbat run

Logged as a github issue https://github.com/springfall2008/batpred/issues/1781

Goshiki2 if you see obvious things in the plan changing unnecessarily then do log them as github issues. Waiting for the new 'less inverter writes' logic to settle down was part of the reasons why I hadn't upgraded for a while.

The Predbat plan can change significantly particularly in the long term forecast if one scenario is very close to the same cost as another. Slight changes in house load vs predicted load can cause the plan to flip flop. I tend not to pay too much attention to the longer term plan for just these reasons.
Predbat plans the next 4 hours slightly differently from the longer term plan so the immediate forward plan should be more stable

#15 PianSom

geoffreycoan
This is interesting.

I have been looking though my logs, trying to work out some reason why, at this time of year when I have an empty battery pretty much every evening, Predbat chooses to charge for 15 mins at the start of my cheap IOG period at 23.30, then discharge for 15 mins, before doing a full charge. I had been wondering what "special" thing could be happening at midnight to cause such odd and predictable behaviour. I had been wondering whether the code had a < when it should have a <= .

I wonder if your issue is the one I have been seeking?

eg logs look like this

20174 2024-12-22 18:55:44.883614: Not setting export as we are not yet within the export window - next time is 12-22 23:45:00 - 12-23 00:00:00
20173 2024-12-22 18:55:44.883589: Next export window will be: 2024-12-22 23:45:00+00:00 - 2024-12-23 00:01:00+00:00 at reserve 4
20172 2024-12-22 18:55:44.883531: Adjust demand (idle) time computed is 12:30:00-23:59:00

EDIT - I've seen Trefor's reply. The hunt continues.

G
#16 Goshiki2

geoffreycoan Since Trefor added the register writes entity I’ve been averaging 35 to 45 writes per day as Agile prices have been high and the plan was pretty straightforward. Yesterday when Agile prices plummeted it was 145 writes for the day and that’s when I noticed the plan being more reactive.
From 4pm today when tomorrow’s rates were confirmed, this was a screenshot of the plan with export due to start at 18:00. I had to intervene at 17:55 to delay the export until 19:00 as it was in my opinion discharging the battery unnecessarily early.

Then at 19:05 just after it had started exporting the plan changed to this

I updated to the latest release yesterday so I’m going to go through all the settings to confirm against default but I’ve not really seen this behaviour before.
Edit: and now at 19:40 the plan has changed again:

G
#17 geoffreycoan

Goshiki2 It would be worth looking at the right hand Total cost column to see how it is changing across the different plan iterations. It could be that the benefit of one plan over another is quite small and so the plan can change significantly for small financial gain.

Would expect more inverter writes when the agile activity is “high” but I think I too am seeing instability in the plan. Will keep looking at it.

R
#18 Rbor

Goshiki2 geoffreycoan
Over the 11 months that I have run predbat with Agile, I have learnt that predbat changes the plan often as events happen, whether that be more load than initially planned, disappointing PV, etc.
See comments by geoffreycoan on 'the next 4 hours'. Consequently, I don't worry too much if confronted with strange predbat plan well before Nordpool, 4pm rates and the 'last 4 hours.

I grant predbat permission to control my inverter. I do step in (rarely) with forced charges or exports when I think that 'I know best' but I have learnt to let predbat get on with it.
I am safe in the knowledge that Trefor is in charge of predbat and we help Trefor to improve predbat and to identify bugs with our feedback via GitHub comments.

At the moment, Agile rates are all over the place and predbat is very active, charging during lowest rates and exporting when rates increase. The overall aim is to minimise costs.

'Up and down' Agile rates are always going to lead to an increase in register writes but we have been waiting for such rates! The last 2 days, I have had 187 and 132 daily register writes. But in the doldrums before, I was sometimes getting just 20 daily register writes. I am averaging about 60 register writes since v8.8.0, which introduced register writes entities, 3 weeks ago.

We have one more night of low Agile rates before winds drop and the low rates disappear. I just need some reasonable rates overnight to get battery charged.

Rob

R
#19 Rbor

geoffreycoan I upgraded just now to the latest Predbat version, 8.8.13.

Well done on catching up and even overtaking me as I didn't notice that v8.8.13 had hit the streets.

You missed the fun when Trefor split switch.predbat_calculate_secondary_order_slots into two separate switches in v8.8.10, and then changed their names and defaults in v8.8.11.
I am hopelessly bemused by what these switches are doing and am using the default settings on the basis that "Trefor knows best".
I have read the documentation repeatedly but it remains largely a mystery.
Latest documentation states that defaults for switch.calculate_import_low_export and switch.calculate_export_high_import are True and False respectively but defaults in webUI are True and True. The release notes for v8.8.10 and v8.8.11 confuse me further.

Rob

R
#20 Rbor

PianSom I have added a comment on Github following on from Trefor and Geoffrey.
Could this all linked to the two new switches?:

switch.calculate_import_low_export 
switch.calculate_export_high_import 

Rob

#21 PianSom

Rbor
I don’t think so. This behaviour long pre-dates the new switches 🙁

R
#22 Rbor

I've just seen that Trefor has sent us all an early Xmas present: v8.8.14.

Rob

W
#23 Wavy Davy

Done 2 predbat updates in a row and NO issues. Whoopee and thank you Trefor.
On a different note is there a entity for daily register writes?
Can only find a total one, but would like to know how many per day.

R
#24 Rbor

Try this yaml code in a new 'manual' card:

type: markdown
content: >-
  {{ (as_timestamp(now()) - as_timestamp("2024-12-02 21:28:00")) |
  timestamp_custom("%j")| int }} days

  {{ states('predbat.inverter_register_writes') }} total writes

  {{((states('predbat.inverter_register_writes') | int) / ((as_timestamp(now())
  - as_timestamp("2024-12-02 21:28:00")) | timestamp_custom("%j")| int)) | int
  }} avg per day

Rob

R
#25 Rbor

And another one showing a neat 24 hour running view against status (easy to change the number of hours.)

Here's the yaml which you can just copy into the card.
This one can be improved.

title: History
type: history-graph
hours_to_show: 24
entities:
  - sensor.register_count_daily
  - predbat.status

Rob

W
#26 Wavy Davy

Rbor Cheers Rob.

D
#27 Daveb01

I put my code in the Predbat card so I can see it all in the same place 😀

W
#29 Wavy Davy

Rbor Seems I have a problem with the graph, don't have the entity "sensor.register_count_daily".
Maybe its because I have a hybrid gen 1 inverter?

G
#30 geoffreycoan

I went to 8.8.14 today soon after it was released. Was seeing some weird behaviour with freeze charging when it didn’t make sense to do so, hoping that this release fixes that.

Thanks for sharing the YAML Rbor I have been fiddling around with trying to create a utility meter to give a daily figure. I’ll keep fiddling and if not I may start hacking the code (after the next batch of documentation changes of course …)

3 days so far with the inverter writes being counted, some of the first day was false incrementing of the pause start/end time sensors that don’t work on my inverter firmware, but my average is currently 133 per day, so 65 per inverter.

R
#31 Rbor

Wavy Davy I can't take credit for the code though.
@TX200 contributed the code, 3 weeks ago, on the thread: "For those of us thrashing the inverter" when we were discussing register writes.

Rob

T
#32 TX200

Wavy Davy i think you'd have to create that attribute using a helpers object. Also discussed in the thrashing topic.

T
#33 TX200

I made a slightly better version of the above code, with variables, so you only have to set the date once (the date you upgraded to the version that contains that value)

{% set datediff = (as_timestamp(now()) - as_timestamp("2024-12-02 07:33:00")) | timestamp_custom("%j")| int %}
{% set totalwrites = (states('predbat.inverter_register_writes') | int) %}
{{ datediff }} days
{{ totalwrites }} total writes
{{ (totalwrites / datediff) | int }} avg per day

R
#34 Rbor

TX200 Thanks.
I have adapted my code to accommodate your improved code.
It works!

Rob

R
#35 Rbor

Wavy Davy Trefor introduced the entity with v8.8.0:
Total register writes (all inverters) 'predbat.inverter_register_writes'

It may have been subsequently improved.
I added the code to the 'history card'.

Which version of predbat are you on?

Rob

W
#36 Wavy Davy

Rbor I'm on v8.8.14.
I do have that sensor (predbat.inverter_register_writes) but that is the total writes.
I have followed the posts on the other forum to create a daily sensor, but as yet it isn't showing any writes and the graph isn't appearing. I hope it's just waiting for a value to appear in the daily sensor, as I think it must just increment starting at 0.
According to the plan its due to do a write at 22:30 but may just force a charge to get a write and see if it works.

R
#37 Rbor

Wavy Davy Do you have the history chart in your charts?
If I select the register write entity in devices & services, I get a chart.

I then select 'Show more'. If I select the 3 vertical dots, there is an option to 'add current view as card'. The option isn't there until I 'Show more'
Then try just adding the card to a dashboard.

Rob

W
#38 Wavy Davy

Think I must have done something wrong. I get entity unavailable. So will have a look through what I did and see if I missed something.

R
#39 Rbor

Wavy Davy Strange.
It's the entity I copied a few posts ago.

Rob

W
#40 Wavy Davy

If you mean the entity "predbat.inverter_register_writes" that one is ok. It's the daily one that's unavailable

R
#41 Rbor

Wavy Davy There isn't a daily one! My workaround was to show the chart over 24 hours. I the have to eyeball the number in latest 24 hours as the chart returns to zero at midnight.
My current chart is showing 13/14 writes from midnight to 21:47.
Needs some code to show last complete 24 hours only.

Rob

W
#42 Wavy Davy

have redone it. Now getting the daily writes showing 925 which is the total register writes.
Does it have to reset at midnight to show the daily writes?

W
#43 Wavy Davy

Just seen your last post. I thought the daily sensor reset at midnight? so using the graph with that entity is just the writes that day,

W
#44 Wavy Davy

I ThiNK I have it correct. I have a created a named sensor called "sensor.writes_today". Using this as the graph entity it now shows a 0 reading, which is correct as there has not been a write yet. Will know for certain at 22:30 when it starts a charge.

W
#45 Wavy Davy

Well it has incremented to show 1 write. So I think I need to let it run for a while to see how it goes.

R
#46 Rbor

Have a look at "For those of us thrashing the inverter" posts 125-145.

You will get an idea of the rigmorale that I had to go through!
Hope it all makes sense. I had a lot of help from @geoffreycoan and @PianSom

I had to create a helper of type template.

See if any of this makes sense but that is where my entity came from: sensor.register_count_daily

Rob

W
#47 Wavy Davy

Rbor
Thanks for your help.
That is the posts I used, just took me a little bit to get it working (I think).
I will see if it resets at midnight.

R
#48 Rbor

🤞

Rob

G
#49 geoffreycoan

Rbor OK I have a solution to counting just today’s inverter writes. Bit of a pain because there’s no way in HA/Jinja to update an attribute value without resorting to HACS add-on’s and configuration.yaml changes like this https://github.com/pmazz/ps_hassio_entities

My solution requires one additional helper and an automation:

  1. Create an input_number helper, give it a very large max value:

  2. Create an automation that triggers at midnight to capture the current value of the Predbat inverter register write count:

    alias: "Predbat: Capture midnight inverter register write count"
    description: ""
    triggers:
      - trigger: time
        at: "00:00:00"
    conditions: []
    actions:
      - action: input_number.set_value
        target:
          entity_id: input_number.predbat_midnight_inverter_register_writes
        data_template:
          value: "{{ states('predbat.inverter_register_writes') | int }}"
    mode: single
  3. Amend the dashboard so it can show the count of today’s inverter register writes:

    - type: markdown
      content: >-
        {% set datediff = (as_timestamp(now()) - as_timestamp("2024-12-22
        17:20:00")) | timestamp_custom("%j")| int %}
        {% set totalwrites = (states('predbat.inverter_register_writes') | int) %}
        {{ datediff }} days, total {{ totalwrites }} inverter writes
    
        {{ totalwrites - (states('input_number.predbat_midnight_inverter_register_writes')|int)
        }} inverter writes today
    
        Average {{ (totalwrites / datediff) | int }} inverter writes per day

Merry Christmas !

T
#50 TX200

Anyone upgraded to 8.8.14?

My battery didn't charge overnight, despite the solar forecast being poor.

It planned to charge for 30mins circa 3am, but didn't.

Predicted load is low though, so maybe it thinks it can make it beyond the evening peak.

R
#51 Rbor

TX200 Predicted load is low though, so maybe it thinks it can make it beyond the evening peak.

This could be the case. I am predicted 4.67 kWh today and the sun has recently risen and is visible for me.
My batteries did completely recharge overnight but I do have a heat pump which will likely consume about 15 kWh in today's projected temperature. That is roughly the capacity of my batteries!

Rob

G
#52 geoffreycoan

TX200 Yes I’ve been on 8.8.14 all the way through Christmas. Yesterday all the cooking was much earlier in the day on grid import as Predbat held the battery SoC for the evening peak. I did consider putting some force Demand’s in to use the battery earlier but didn’t want to run out of battery in the peak so didn’t, and of course we ended up with the batteries half full at the end of the peak.

Rates were not great overnight, mainly at 20p on Agile with only a couple of 18p slots so Predbat didn’t do a lot of charging for me either. Today much the same, 23p most of the day, 40p peak. I suspect Predbat didn’t see much financial benefit in charging the battery

T
#53 TX200

Well, I've just updated to HA OS 14.1 from 13.2

I was patient this time, took almost ten minutes for Predbat entities to appear and the status below to clear. Which they did and its now back in demand mode.

Nervous moments lol!

R
#54 Rbor

TX200 It is always a nervous (few) moments updating HA versions.
I am on HAOS 14.0 and Core 12.3
I am glad that it worked out for you.

HA is trying to entice me to update to 14.1 and 12.5 but I will stay where I am for now.
For predbat, I am on v8.8.14

Rob

D
#55 Daveb01

I got bored, have pressed the button. Seems to be working OK 👍

Plus there was an Octopus one.

D
#56 Daveb01

New Shelly advert in Stuff magazine Merry Christmas

G
#57 geoffreycoan

Daveb01 I have a few of the Shelly things already, they integrate very easily to HA via MQTT.

Have:

  • 3 x Shelly EM1’s (2 channels each) CT clamps to monitor my ASHP consumption, FIT generation, hot tub and cooker consumption
  • Shelly 2PM to control the cooling fans under my inverters
  • Shelly 1PM mini to monitor the fridge electricity consumption
  • And a bunch of other 1PM’s intended to make some of the lights like the porch and upstairs landing into smart motion sensor lights, but still not got round to it…

I use Local Bytes smart plugs and Govee T&H BLE sensors, both of which were cheaper than Shelly.

D
#58 Daveb01

Looks like MrBat is saying charging the battery is to close to not being efficient (mine is set to default), Geoffrey I think you said yours is at 4, is your looking similar please?

G
#59 geoffreycoan

Daveb01 I was on 8.8.14 and Predbat was planning to let the battery discharge from the current 14% SoC (one battery is already empty) to both being empty, then fill it up in the slightly cheaper overnight slots, and hold in between:

I then upgraded to 8.8.15, today’s release 😆 and the plan consists of a lot more freeze charging to preserve the SoC, very similar to yours Dave:

This plan makes more sense, the Agile rates are fairly flat tonight and not really enough cheap slots to overcome the 15% combined battery and inverter losses

Mine has probably got more charging than yours Dave as I have less battery capacity than you and with the ASHP a higher daily demand so Predbat wants to fill the batteries up to preserve me from peak draw.

G
#60 geoffreycoan

geoffreycoan Hmm, the plan must be very finely balanced because 20 minutes later and still on 8.8.15, its now decided to release the battery SoC and fill from empty overnight.

If I look at say 5am 100% SoC across the 3 plans they are all within 10p of each other

Upgraded HAOS to 14.1 today, no drama, just installed and everything restarted OK. Gives me a chance to see how well the daily inverter writes utility meter I created in configuration.yaml works

R
#61 Rbor

Tried updating everything this evening and I have lost my status history!
Just have a loop with History loading state history.
Notice the 'i' alongside the 'status'.

See screenshots

I have restored from a full backup earlier today but no luck.

Any ideas?

EDIT: I had upgraded to HA 12.5
With the restore, I was back to 12.3

In desperation, I have updated to 12.5 again and the status history mysteriously reappears.

Another example of a HA update causing issues.
But looks like I am back in action. A 2 hour panic.

Rob

R
#62 Rbor

geoffreycoan I hope I am back in action again with all the latest updates.
My HA update broke two of my integrations along with predbat status. But I seem to now be on 12.5 and 14.1

I have added your code for the daily register count. I have spotted an error:

  • Stage 3 has another superfluous '-' before 'type' in the first line.
  • I deleted the hyphen and unindented all lines.

I will now be able to see if this works at midnight.
But that will be for me to look at tomorrow.

Rob

G
#63 geoffreycoan

Rbor So the status was there, you just couldn’t see the history of the status entity.

Did you look at the HA core logfile, were there any clues as to what HA was doing there?

Sometimes I find event history can be a bit flakey, taking absolutely ages to load history. Changing the time period you look over can result in the data appearing when it was stuck otherwise.

Curious that your status has been freeze charging all day, right through the peak period?

G
#64 geoffreycoan

Rbor I have added your code for the daily register count. I have spotted an error:

Stage 3 has another superfluous '-' before 'type' in the first line.
I deleted the hyphen and unindented all lines.

Yeah it often does this when I copy and paste parts of my dashboard.

The code I provided was a snippet off my dashboard because that’s the easiest way to copy it using the iPad Companion app. If I select an individual card and edit the YAML it often gets copied as rich text with everything on one line and spaces converted to %20 for example.
So I tend to edit the raw dashboard YAML which includes the dashes for the start of the card, and the indenting for where the card is on my dashboard.
B**dy HA.

The helper with an automation to reset at midnight so that the dashboard can calculate a daily sensor is working fine for me. I now have a utility meter working which once I confirm it rolls correctly over midnight, I’ll share as well.
This is probably simpler

R
#65 Rbor

geoffreycoan B**dy HA.

At least I have found that I am good at doing something in HA: hunting down superfluous hyphens and finding out glitches in yaml indentation. I couldn't have done that even a few months ago.

This is what I got overnight from your '3 steps' for daily register write.
I changed the as_timestamp to match when I started my count tally on 2nd December:
as_timestamp("2024-12-02 21:28:00")

Thanks for the code. It nicely summarised everything. I will add a chart to this in my dashboard.

Curious that your status has been freeze charging all day, right through the peak period?

Late last night, I restored HA from a backup from 10:25 am yesterday.
I lost about 12 hours of data but I did get my history working again. Yesterday afternoon, I had worked through the energy dashboard so I have to repeat that work again.

The history glitch has shattered my HA and predbat confidence.
I blame the HA upgrade as everything else was working well including predbat up to v8.8.15.

On the plus side, my PV generation has got a boost recently. Good sunny day yesterday with 7 kWh and, if today stays as it has started, this should be beaten and get my December total into 3 figures.

Rob

G
#67 geoffreycoan

geoffreycoan Alternative solution to counting Predbat daily inverter writes to the solution posted just before Christmas, this creates a utility meter that will automatically reset at midnight.

Unfortunately as pointed out earlier you can’t create a utility meter wrapping around the Predbat ‘total inverter writes’ sensor using the HA user interface as the sensor is in the ‘predbat’ domain not the ‘sensor’ domain and the UI validates the utility meter configuration.

The way round this is to create the utility meter in YAML by adding the following to the configuration.yaml file:

utility_meter:
# Predbat daily inverter writes utility meter
  predbat_daily_inverter_writes:
    source: predbat.inverter_register_writes
    name: Predbat Daily Inverter Writes
    unique_id: predbat_daily_inverter_writes
    cycle: daily

Add this to configuration.yaml and restart HA, and it will create a new entity sensor.predbat_daily_inverter_writes that is automatically updated each time that predbat.inverter_register_writes changes

It won’t include any register writes so far today when you create it, but will count correctly from tomorrow

W
#68 Wavy Davy

geoffreycoan Have to say miracle of miracles 🤞 I am running 8.8.16 without any problems that I'm aware of.

G
#69 geoffreycoan

Wavy Davy Trefor reissued the release so I think its fixed now

#70 PianSom

For those shy, rabbit-like creatures emerging blinking into the daylight of Home Assistant, I have a late Xmas present.

I just came across this list of like-minded programs - self hosted, often open source programs which are currently the state of the art. HA - of course - is on there.

I've played with a few of these and they vary from the absolutely essential (HA and Plex would certainly be on my list there) to the fun to play with (Frigate was impressive). But quite a few look cool and have been added to my 2025 list of things to do (looking at you Syncthing and WUD).

Enjoy! Or ignore!

https://www.osswire.com/r-selfhosted-recommends-essential-self-hosted-tools-of-2024/

R
#71 Rbor

Wavy Davy I thought you might have learnt by now!
But a good upload for you and let's hope that v8.8.16 is sorted now by Trefor.

Rob

R
#72 Rbor

It's not every day that this happens. See below.

That's 2 days on the trot for me with almost wall to wall blue sky and sun. There are advantages in living at 800 feet in the lee of the Pennines. I could look down at the mist over the lowlands.
It won't last of course but brings my December generation >100 kWh.

Rob

R
#73 Rbor

Wavy Davy On your recommendation, I have also updated to v8.8.16 successfully.
After all my problems yesterday with the pesky HA update, that was the least that I deserved.

Rob

R
#74 Rbor

geoffreycoan At long last, I have a register write from the utility meter method.
I set this up mid afternoon and inverter hasn't budged until 22:30pm.

Rob

G
#75 geoffreycoan

Rbor Interesting. I'm averaging about 60 writes per inverter per day, the Agile charge rates were not that contiguous last night nor today, then there's the peak Demand mode turn on for me.
I'm seeing a bit of weird behaviour of Predbat flipping between Charge/Freeze Charge/Hold Charge and today I even saw a NoCharge which I can't remember when I last saw it. Some of these are only lasting for 5 minutes or so. Trying a fixed main version from Trefor at the moment to see if this improves this instability and reduces inverter writes further.

Rbor That's 2 days on the trot for me with almost wall to wall blue sky and sun.

Grey and cloudy for me today, 2.6kW generated and much the same forecast for tomorrow then brightening up. 110kWh generated so far this month

R
#76 Rbor

geoffreycoan Grey and cloudy for me today, 2.6kW generated and much the same forecast for tomorrow then brightening up. 110kWh generated so far this month

This is my breakdown. I like the bar above the chart which shows the different actions with the writes in colours. And I can burrow down easily to get the detailed status.
With the colours, red is demand, purple is hold charging, blue is freeze charging and yellow is charging.

I was on v8.8.15 yesterday and I upgraded to v8.8.16 yesterday evening, which is responsible for today's writes. Your utility meter gives the same daily value.

Yesterday, I even managed to export 2.8 kWh of sunshine during 'Hold charging' (at 100%) despite running a HP! I am hoping for a repeat day today provided that the mist stays in the low lands and valleys. You need to get above the grey in your mechanised 🪁.

I'm up to 103 kWh for December now with 35% of that coming in the last week. So I am catching you up. I know it won't last though

Rob

W
#77 Wavy Davy

Don't know what I've got wrong but my my registry writes was averaging 40. yesterday it was 156 and today at 09:30 it has already done 60. In about 3 or 4 days average has gone from 40 to 51.

C
#78 CW

Rbor December generation >100 kWh

<sigh> only 81 for me this month so far, well, well, well below MCS and PVGIS forcasts for the month 😢

W
#79 Wavy Davy

My generation is only 23kW this month. 😢

H
#80 Henry3rd

So far this month I have achieved 101 with 15 left to harvest.
This is my first month, and my proposal predicted 128. It looks like I'm going to be 12KWh short of target.

C
#81 CW

Henry3rd My MCS forcast was 133kWh and I'm only at 81kWh so just over 50%!

W
#82 Wavy Davy

what is a MCS forecast?

C
#83 CW

Wavy Davy The standard generation forecast provided by MCS installers (Microgeneration Certification Scheme). You need an installation by one of these installers to be able to export energy out to the grid

W
#84 Wavy Davy

I have a MCS certificate didn't know they did a forecast.

G
#85 geoffreycoan

CW Octopus are (or at least were) piloting a scheme for export registration when you didn't have an MCS certificate, e.g. a non-MCS installer. Trouble was they asked IIRC £200 'admin fee' for the extra paperwork.

All feels a bit protectionist this MCS registration thing. You needed an MCS certificate to get the government RHI heat pump installation grant and I presume the BUS grant as well.

MCS is nothing special, it just says you've followed a prescribed methodology for calculating the heat pump sizing/solar generation and there's supposedly transparency on pricing, but seeing my invoices they were clearly bending the system with how they detailed the bill of materials - mine has a 'supply of PV system' with the price and then the breakdown of panels, inverters, installation labour, mounting rails, etc are all zero cost items. Phah.

Anyway, off topic. After studying the quote a lot before install I have never since been back to look at it to see how it compares to reality, so I went to look now ...

My projection didn't have monthly estimates, only 20 years of annual figures.
The year 1 estimate was 7934kWh and my Feb 23-Jan 24 actuals were 7635kWh.
Most recent full year actuals of Dec 23-Nov 24 were 7581kWh.

I'd say they were both within the margin of error.

PVGIS is another website that a number of YouTubers use for their solar forecast, never used it myself.

W
#86 Wavy Davy

geoffreycoan in that case my certificate only has a yearly estimate which is 3900kWh which by a strange coincidence is the similar to the panels capacity of 3.9 kWh.
so far this year generated 3550 kWh. So I suppose just about par.

G
#87 geoffreycoan

Well that was interesting, managed to break Predbat for most of the night by accidentally purging my sensor history too much

2024-12-28 04:15:00.401280: Error: Unable to fetch history for sensor.house_load_today
2024-12-28 04:15:00.422180: Warn: record_status Error: Unable to fetch history from sensor.house_load_today
2024-12-28 04:15:00.422677: Error: Exception raised 
2024-12-28 04:15:00.424191: Error: Traceback (most recent call last):
  File "/config/predbat.py", line 973, in run_time_loop
    self.update_pred(scheduled=True)

Tried multiple attempts to fix it, different sensors that had similar data in them, reducing days_previous, and none of them worked. Had to resort to manually initiating a battery charge this morning to fill the batteries up ahead of today's agile peak.

Eventually resurrected Predbat by swapping to using the GivEnergy cloud data for the sensor load/import/export history instead of the HA sensors https://springfall2008.github.io/batpred/apps-yaml/#givenergy-cloud-data

Never done this before but it worked well and Predbat is now back up and running. Several of my Apex charts are still broken in a weird way but I can live with that.

Always new things to learn with predbat ...

G
#88 geoffreycoan

Wavy Davy In my quote I had projected performance tables like this:

Several of the assumptions made are dubious such as the export rate starting at 5.5p and that 50% of generated energy is used onsite, but I guess these are laid out in the MCS requirements.
I'm getting a much better ROI than they suggested, payback including additional batteries that weren't in the original price will be in about 5 years.

R
#89 Rbor

CW It is definitely luck of the draw with the weather at the moment.
I have had days where I have generated 2 kWh max for the day with some barely 0.5 kWh. If there is a sunny day, it is surprising that some meaningful kWh can be generated, despite the sun being so low in the sky and our panels having to contend with shading from trees and buildings.

Rob

R
#90 Rbor

Henry3rd
101 looks good against your 133 target. Generation varies so much depending on weather.
In Sept 2023, I generated 696 kWh but in 2024, this was down to 543 kWh.
My May generation fell from 1,136 kWh in 2023 to 907 kWh in 2024.
Last December, I generated 111 kWh and this December should just beat it.

For me, this year has been disappointing compared with 2023.

Rob

W
#91 Wavy Davy

My quotation didn't have monthly figures but did have Yearly ones.
This year predicted 3111 against 3550 generated so quite bit better.

W
#92 Wavy Davy

Have to amend the generation figure. its 2758kWh not 3550 so not so good as I thought. 400 less than predicted.

I
#93 Ivan

I've had panels since January 2011 (original FIT scheme). Generation generally varies year to year - with 2024 (3466 kWh) being the worst so far - nearly down 20% on 2022 (4245 kWh). Average annual generation since 2011 has been 3880 kWh - the MCS design figure was 3336 kWh.

My monthly December generations since 2011 have been 107, 85, 77, 91, 80, 106, 139, 114, 109, 85, 73, 121 and 85 kWh - currently at 79 kWh for 2024.

R
#94 Rbor

Ivan Thanks for posting data on your historical PV generation.
It really shows how much PV generation can be different year-by-year.

We are all coming to the conclusion that 2024 will finish up as a poor year for solar generation.

Rob

G
#95 geoffreycoan

Ivan Likewise my annual generation from my 4kW FIT array and FIT payment income each year. Generation either side of 3MW but there’s quite a bit of variation.

2024 figure to start of December, plus a further 36kW so far this month means this year won’t be the worst but also not the best either

D
#96 Daveb01

Hi all, just browsing and spotted this at the top of “Developer Tools - States” any idea why I have 3 and only one is working?

I prefer xxxx_update (without any numbers)

Why is there three Solcast updates (I was expecting just one)

Nothing urgent btw

Just found these after looking further, can I delete the ones with the / through the icon and rename The one working (bottom 3)

G
#97 geoffreycoan

Daveb01 you appear to have multiple solcast automations. Look at your automation list

There's a sensors for each automation of when it last ran etc

C
#98 CW

Wavy Davy For my quote I had a daily average kWh generation by month

D
#99 Daveb01

geoffreycoan

Your right I have three, so can I delete the two not working since Sept and rename the one that is to just _update ?

Or do I need to dig further to see where these extras are on any yaml etc?

H
#100 Henry3rd

It's been a few weeks since I installed predbat, and all seems well. I have started looking at logs and this error comes up. Is it important?

Logger: homeassistant.components.recorder.db_schema
Source: components/recorder/db_schema.py:624
integration: Recorder (documentation, issues)
First occurred: 19:45:19 (13 occurrences)
Last logged: 19:46:15

State attributes for predbat.load_energy exceed maximum size of 16384 bytes. This can cause database performance issues; Attributes will not be stored

G
#101 geoffreycoan

Daveb01 Yep, just delete the two automations that are disabled and the sensors will go as well.

Then rename as you wish. What you are seeing there is the automation name, there is an automation id as well which if you click the 3 bullets and then settings you can change if you want, and also change the icon, e.g. here’s mine:

Henry3rd State attributes for predbat.load_energy exceed maximum size of 16384 bytes. This can cause database performance issues; Attributes will not be stored

This is in the Predbat FAQ’s, you can suppress the warning https://springfall2008.github.io/batpred/faq/#predbat-is-causing-warning-messages-about-exceed-maximum-size-in-the-home-assistant-core-log

#102 PianSom

Deleted as superfluous

H
#103 Henry3rd

geoffreycoan Worked a treat. thanks. My New Years resolution is read the manual cover to cover 🙂

D
#104 Daveb01

geoffreycoan

Thank you sorted, I changed the icon as well.

G
#105 geoffreycoan

Folks, be aware that the latest Predbat release 8.8.17 crashes in freeze charge mode at least on my multi-inverter system.
This release contained bug fixes for mult-inverters where Predbat was getting confused and setting the mode incorrectly, resulting in swapping between freeze charge, hold charge and charging in short order.

Unfortunately it doesn’t seem to be working at least for me so suggest you don’t upgrade just yet https://github.com/springfall2008/batpred/issues/1793

G
#106 geoffreycoan

geoffreycoan fixed version from Trefor ⭐️, 8.8.18 which isn’t crashing in freeze charge mode for me any more. I’m going to see how well it works tonight.

There can’t be many other open source software products that get this quick a bug fix turnaround

R
#107 Rbor

geoffreycoan Agreed. Thanks for keeping us all in the loop.
I just stand back in amazement at Trefor's speed in addressing issues.

I will try this tomorrow.

Rob

T
#108 TX200

Getting nervous here… battery at 3% since 6am

Supposed to be some sun today!

H
#109 Henry3rd

TX200 It's been a rubbish end to the year.

T
#110 TX200

PredBat changed its mind, due to lack of sun, decided to charge to 17% in the lowest of the slots.

Still hoping for some sun, but it's not looking great so far!

T
#111 TX200


Will we get some negative prices Monday evening??? 🤞😀

H
#112 Henry3rd

When I initially set predbat up, I incorrectly followed some original videos which caused me to install Appdaemon. I subsequently followed the manual and realised Appdaemon was no longer required.
I still have the Appdaemon files lurking in my system. I am sorely tempted to delete them for neatness, but I am tempered by the old adage, 'if it ain't broke, etc.'
When you all moved from Appdaemon, did you simply abandon these files to aimlessly wander the ether?

R
#113 Rbor

Henry3rd I removed appdaemon once I had installed Predbat standalone.
But wait for more confirmations before doing likewise on my recommendation alone!

You will find appdaemon lurking as an add on and there are also files alongside the Predbat files accessible using file editor.

Rob

R
#114 Rbor

TX200 Will we get some negative prices Monday evening???

The runes are looking that way. 😄

Rob

D
#115 Daveb01

geoffreycoan

I have a question please, in this version there was an update for “Forcast Planned hours”
Think it was 48 then 24.

I have had a look at apps.yaml and Predbat config, they say both, which is not right.
What do you experts have set please, both 48 or 24?

How come apps.yaml 48 is not the setting (I thought that was the Boss?)

R
#116 Rbor

Daveb01 In apps.yaml, I have 48 hrs, same as you.
But in the webUI, configuration shows default as 24 hrs.

Looking at release notes for v8.8.17, it looks as if 24 hrs is the default for non-expert mode.
I am on expert mode and I have been seeing 24 hours anyway.

So does the apps.yaml line stick at all?
Or is this still buggie? Certainly looks inconsistent.

Rob

D
#117 Daveb01

Rbor

I am in expert mode as well, so would have thought both should be 24 and we have the option to change it to 36 or 48. However apps.yaml never gets changed, but as you say is this line in yaml have any affect?

We will have to wait until Geoffrey has a look and see what he says?

L
#118 Leeshore

Daveb01 Same here.....

D
#119 Daveb01

Rbor

So to keep mine as it was in yaml, I have changed the setting from 24 to 48. Then I can see what people say and decide if I want to change it down.

Both settings are now 48

R
#120 Rbor

I am unsure what my forecast hours are!

My plan goes forwards to 02:30 on Tuesday which looks more like 36 hours!
.... not that is really matters but it would be good if everything tallied.

Rob

R
#121 Rbor

Daveb01 But how many hours does your forward plan show?

Rob

D
#122 Daveb01

Rbor

Now showing Sunday 15:10 - Tue 14:30

Perhaps Predbat is now a car sales man as well.

You have 24 set, yaml says 48 so we shall settle on 36

G
#123 geoffreycoan

Daveb01 It is (like several things) in Predbat-land, complicated… (perhaps more so than it needs to be, but it is what it is)

forecast_hours in apps.yaml is the number of hours that Predbat forecasts ahead https://springfall2008.github.io/batpred/apps-yaml/#forecast_hours

input_number.predbat_forecast_plan_hours is the minimum length of the Predbat charge plan, and is the number of hours after the first charge slot to include in the plan
https://springfall2008.github.io/batpred/customisation/#calculation-options

So think of it as being the apps.yaml is the total length of the Predbat forecast but the input number then is how much plan is produced within that forecast duration.

I have my apps.yaml set to 48 and my input_number to 24. The input_number used to be higher but I reduced it as I didn’t see any value in having an enormous long plan given things will change (not least import prices) and in winter at least I use the whole battery every day. Note that its 24 hours after the first charge, my first charge is at 02:00 tomorrow (Monday) so my plan currently goes up to 01:30 Tuesday.

I think Trefor changed the input_number default for non-expert model in the latest release.

TX200 I’ve got a 3 hour Octopus power up event tomorrow (11-2pm) and have seen a Met Office Wind warning for Wednesday so I think we’re going to see some lower prices this week.

Went flying today, nice to get up, but dodging between cloud layers

Henry3rd I’ve still got my appdaemon installed but shutdown. Since I’ve been running fine on Predbat add-on since early October I have taken the step and uninstalled it today. When you uninstall appdaemon you’ll find there are vestiges of Predbat still in the /config/appdaemon directory which don’t get removed even if you tick the ‘remove data option’. You’ll have to manually delete this directory

D
#124 Daveb01

geoffreycoan

Thank you for explaining, that makes sense, I have changed it back to 48 & 24 same as it was.

Good pic up in the clouds btw.

T
#125 TX200

Seems the sun I was promised yesterday has arrived today instead.

Wonder if I'll end the day on 0p - a good chance with some evening export.

PredBat guessing 4p total by midnight, but that might change.

G
#126 geoffreycoan

Upgraded from HA 2024.12.3 to HA 2024.12.5 just now as I had a long 3 hour power up event so the batteries were charging and I figured I had a bit of time to fix predbat if things broke after upgrade.

Absolutely flawless upgrade process, HA came back up, all the Predbat sensors were unknown and it did complain in the log about the connection to HA:

24302	raise WSServerHandshake Error(
24301	File "/usr/local/lib/pyth on3.10/dist-packages/aiohttp/client.py", line 821, in _ws_connect
24300	self._resp = await self ._coro
24299	File "/usr/local/lib/pyth on3.10/dist-packages/aiohttp/client.py", line 1167, in __aenter__
24298	async with session.ws_c onnect(url) as websocket:
24297	File "/config/ha.py", lin e 184, in socketLoop
24296	2024-12-30 12:42:41.613298: Error: Traceback (most recent call last):
24295	2024-12-30 12:42:41.606054: Error: Web Socket exception in startup: 502, message='Invalid response status', url=URL('http://supervisor/core/api/websocket')
24294	2024-12-30 12:42:41.596716: Info: Start socket for url http://supervisor/core/api/websocket
24293	2024-12-30 12:42:37.080255: Error:
24292	2024-12-30 12:42:37.079799: Info: record_status Error: Exception raised
24291	2024-12-30 12:42:37.078896: Warn: Failed to decode response from http://supervisor/core/api/states/predbat.status
24290	2024-12-30 12:42:37.072690: Warn: Failed to decode response from http://supervisor/core/api/states/predbat.status
24288	ValueError
24287	raise ValueError
24286	File "/config/predbat.py" , line 246, in get_history_wrapper
24285	self.pv_power_hist = se lf.history_attribute(self.base.get_history_wrapper(self.base.prefix + ".pv_power", 7))
24284	File "/config/web.py", li ne 71, in history_update
24283	self.web_interface.hist ory_update()
24282	File "/config/plan.py", l ine 880, in calculate_plan
24281	self.calculate_plan(rec ompute=True)
24280	File "/config/predbat.py" , line 575, in update_pred
24279	self.update_pred(schedu led=True)
24278	File "/config/predbat.py" , line 974, in run_time_loop
24277	2024-12-30 12:42:37.061161: Error: Traceback (most recent call last):
24276	2024-12-30 12:42:37.055060: Error: Exception raised
24275	2024-12-30 12:42:37.054765: Error: Failure to fetch history for predbat.pv_power
24274	2024-12-30 12:42:37.049616: Warn: Failed to decode response from http://supervisor/core/api/history/period/2024-12-23T12:40:00+0000
24273	2024-12-30 12:42:37.042960: Web interface history update
24272	2024-12-30 12:42:37.042569: Warn: Failed to decode response from http://supervisor/core/api/states/predbat.plan_html
24271	2024-12-30 12:42:37.036735: Warn: Failed to decode response from http://supervisor/core/api/states/predbat.plan_html
24270	2024-12-30 12:42:37.024112: Warn: Failed to decode response from http://supervisor/core/api/states/predbat.best_export_end

But Predbat carried on running and the next run through it sorted itself out, populated all the sensors and all the dashboards are looking fine.

The HA upgrade also fixed an issue I had with my Apex charts that some of the entity values in the top row titles were coming up as N/A. But it was random, the current agile rate on the agile price predict, all the solar forecast values were not working, but most of the Predbat charts were OK, home cost prediction no errors but the low and high thresholds on energy rates were N/A but everything else fine. Weird. The HA restart cured that issue so maybe just HA weirdness and a normal restart would have resolved it for me.

But suffered from entity spikes that mucks up the energy dashboard. It seems the problem is related to utility meters; I had turned turned on the 'sensor always available' option on the UM but this didn't fix the issue:

  • both the utility meters that wrap the 'today' givtcp battery discharge entities spiked with negative values at 12:40
  • no spikes on the underlying 'total' or 'today' givtcp battery discharge entities
  • negative value spikes in import utility meter that wraps 'today' import givtcp sensor, both the free and day tariff sensors and the day cost sensor all spiked

Strangely the energy dashboard showed a big spike in battery discharge in the 12-13:00 period even though I'm using the battery discharge total sensors and the actual spike was in the import utility meters that I'm using.
Ultimately may have to move away from using utility meters but I'll still need a way to handle the free/paid Octopus tariff...

R
#127 Rbor

geoffreycoan Went flying today,

Great picture. Hope you were wrapped up warm.
The photo is not dissimilar from the view from my house during the past week, 800' up, looking down on the clouds. My panels have slurped up about 45 kWh (12.7 kWh today so far) and pushed my December production up to 140 kWh, well in excess of last year. My comeuppance will come as I can just as easily be in hill fog or with panels covered in snow with minimal PV generation.

How high up do you fly?

Upgraded from HA 2024.12.3 to HA 2024.12.5

I did the same several days ago and lost my status history. See here: Rbor
I then restored back to 12.3, losing 12 hours of history but got predbat back.
Then back to 12.5 and all was well.

These HA updates can throw up issues. Makes me wonder whether the developers should slow down these updates.

Looks like we will be getting some nice low Agile rates during the next 2 nights. But getting cold later on in the week with some snow forecast for me.

Rob


D
#128 Daveb01

Fyi👍😀🎄

I have been experimenting with - input_number.predbat_metric_min_improvement_export.

I have tried the default - 5
Geoffrey’s - 4
I have also tried - 3 & 6

I have concluded (for me and my system, 2 x AIO and GW) 4 is the best option.

R
#129 Rbor

Daveb01 Thanks.
I had default of 5 set.
Now changed to 4 on the strength of good recommendations.

Rob

R
#130 Rbor

v8.8.19 has just dropped.

Rob

#131 Jase1703

I need to add another EV to my PredBat charging function! Has anyone got good experience living with 2 EV’s that have different battery size? I have the Soc sensor for the second one and know the battery size, it is only temporary as my brother is visiting. I think I just add the sensor into the apps.yaml be
Ow my existing sensor and change the number of cars to 2. Anything else?.

G
#132 geoffreycoan

Rbor Great picture. Hope you were wrapped up warm.

Yes I was, flying suit, heated jacket, heated gloves (motorcycle Gerbing stuff), heated insoles. Quite comfortable.

My panels have slurped up about 45 kWh (12.7 kWh today so far) and pushed my December production up to 140 kWh, well in excess of last year.

6kW for me today and yesterday, haven’t had anything like 12kW since the end of November. I have been tidying up my tracking spreadsheet for the year end and some interesting and quite surprising results. Will wait a couple of days for the year end to finish and my Octopus bill to arrive then will share it.

How high up do you fly?

Typically about 1500-2000’. I was planning on flying around the edge of Luton airspace (Stevenage, St Albans, Dunstable etc) yesterday so that’s all under the London controlled airspace from 2500’ for planes coming into the London Airports. But as I headed south the broken clouds on the photo joined up together to a solid sea of white and I decided that that wasn’t safe as at some point I needed to get back down to the ground. If I’d completed the circumnavigation and the clouds had filled in behind me I’d be in real trouble so I turned back. But about 2200’ most of the time.

Upgraded from HA 2024.12.3 to HA 2024.12.5

I did the same several days ago and lost my status history. See here: Rbor

Yes I saw your tribulations. Strange that I didn’t have any issues at all. It is part of why I don’t upgrade to every release, usually leave it a week or two to settle down and upgrade to the .2 or .3 release rather than the first ones.

Looks like we will be getting some nice low Agile rates during the next 2 nights. But getting cold later on in the week with some snow forecast for me.

Yes looks good, I have another 2.5 hour power up event tomorrow morning and likely to be more if the winds continue. A nice end to the year but then the Agile price prediction goes back up again.

R
#133 Rbor

geoffreycoan Typically about 1500-2000’.

You would safely clear my house but could run into difficulties across the highest parts of Peak District at 2000'. There are quite a few wrecked 2nd World War aircraft that didn't quite make it littering the Peak District 'tops', a bit higher than the Chilterns The western edge of the Peak District is below the main descent flight path for aircraft heading for Manchester airport. Another potential hazard for microlights and hang gliders!

I have another 2.5 hour power up event

Another one! It is about time these power ups were spread out to more regions. They seem to have been quite lucrative for you.
The folk up here is tight with their money and this must rub off on Northern Powergrid.

Anyway, I have drifted way off topic so back to predbat for next contribution.

Rob

B
#134 browellm

@geoffreycoan I have hit exactly the same GiVTCP bug you've reported on Github. Pretty wild that a remote inverter restart doesn't also include a date/time write and that it has to be done separately.

D
#135 Daveb01

Hi all, anyone seeing a weird Predbat plan? This is mine and not happy 😡

Battery is flat, so no emergency power and Predbat is keeping my battery idle?

It plans to charge later in the week but the ready remains at 5%



B
#136 browellm

Spent the last hour reverting VM snapshots as I thought 8.8.19 had screwed something up. I should read other threads on this forum 😃

B
#137 browellm

Daveb01 Looks like you've had the inverter bug too and Predbat is running off cached data. Go into your inverter cloud page and force a manual date/time refresh. We've (nearly) all been affected.

G
#138 geoffreycoan

browellm Yeah it was a fun night last night trying to work out what had happened with Predbat and GivTCP, tried loads of things to fix it before I worked out it was a corrupt date/time and that resetting the time fixed it.

So pleased that I found a fix as I had had to revert to setting up a manual inverter charge, wouldn’t want to do that for too much of the time.

Slept in this morning!

Daveb01 is yours a problem with the date/time as well? Always worth checking the Predbat status, logfile and givtcp log if things go weird

D
#139 Daveb01

I rebooted HA and it looks like it’s all back now, I have also done a time sync as well (thanks for this)
Had a look at the logs and loads of errors started at 04:10. REST connection failure

R
#140 Rbor

This is my predbat status:

My inverter is offline so can't do anything with it. I have spent about 90 minutes trying to go through the horrible dongle setup process with dongle local network dropping out all the time.
I have all the settings as they should be but no luck. My dongle persists in flashing blue rather than steady blue.

Go into your inverter cloud page and force a manual date/time refresh.

So where is the inverter cloud page?
I have tried the normal portal inverter page and have tried resetting inverter, and tried to reset time.
Which page? I have tried remote control but the portal tells me my inverter is offline anyway! Same with the app.

In big panic mode. My batteries were drained last night so I am now on my solar PV inverter. (There are advantages with having an AC coupled inverter). But only got 708 W so far today.

Thanks

Rob

W
#141 Wavy Davy

Looks like I have the same problem.
2024-12-31 11:20:08,260 - GivTCP - read - [ERROR ] - inverter Update failed so using last known good data from cache: ((<class 'ValueError'>, ValueError("time data '2024-12-31T11:20:08.250249+00:00' does not match format '%Y-%m-%dT%H:%M:%S%z'"), <traceback object at 0x7fb720f89c00>), 1687)
2024-12-31 11:20:08,261 - GivTCP - read - [ERROR ] - runAll2 Error processing registers: ('KeyError', 'read.py', 1825)
Have reset inverter to defaults, and inverter time is correct, but predbat is still not displaying correct data. Showing SOC as 4% as it has been since last night. Have restarted predbat and rebooted PC.
What have I missed?
Cant be inverter dongle as I can talk to it via GE Cloud and other apps.

B
#142 browellm

Rbor Rob I guess if your dongle is also borked then the cloud status and config pages will also be inaccessible.

If you manage to get the back up and running your remote inverter control page will of the format
https://www.givenergy.cloud/inverter/SAxxxxxxxx/remote-control

Re-syncing date/time is an option on that page

D
#143 Daveb01

Rbor

I just rebooted HA and everything came back, I then did a time sync.i hope you get things going again soon.

G
#144 geoffreycoan

@Rbor The page details browellm gives above are correct, its the inverter remote control section you need to go into to force a send of date/time from the portal to the inverter.

Curious that a ‘reset to defaults’ from the portal doesn’t re sync the date time, you have to do it separately.

But does need your inverter to be online for this to work, mine was online throughout, I was receiving the inverter meter data in the portal, although I have seen local control fail when the portal connection is OK, so that wasn’t a guarantee of much. I did try wifi network and inverter restarts before finding the date time fix.

As an alternative to using the GivEnergy portal there is the option to ‘set time’ in the BBC basic app. That has a direct connection to your inverter so as long as you are on the same network, it should work and will restore GivTCP local comms

Wavy Davy it is the same problem, the inverter time is fine but the date is corrupted, the inverter thinks it is 1st of the 13th month 2025! You need to resync the time from the givenergy portal and this’ll cure the givtcp error and thence the predbat REST errors

W
#145 Wavy Davy

Resyncing the time worked for me. Like Geoff says strange a reset to default didn't sort it. Anyway back up and running now.
Luckily I noticed it last night about 01:00 and managed to program a charge using the GE cloud app.
Also lucky that there was 5 hours of reasonably cheap slots, so I could use timed export as my inverter only has 1 charge slot.

R
#146 Rbor

Remote control page:

Account settings page:

Notifications:

The dongle setup instructions refers to resetting as follows:

What small button?????

My GE inverter and batteries are useless, batteries 2 big paperweights.

Wish I'd gone with a Solaredge battery. The SE inverter has purred along for 2.5 years without a whimper.

Rob

T
#147 TX200

Rbor the button is on the dongle itself?

Assuming you don't have the one with the inbuilt WiFi? In which case there might be a button near all the various ports.

G
#148 geoffreycoan

Rbor You can regain local control using the BBC app, available for Android, iOS and other platforms
https://community.givenergy.cloud/d/5051-bbc-basic-inverter-app-significant-update

The BBC app makes a direct inverter connection so you just need to be on the same network as your inverter. In the app, do ‘set time’ and it should spring givtcp to life

In terms of resetting your dongle, I’m not familiar with the AC3 but is it similar to the Gen 1 hybrid, there is a white dongle stick plugged in underneath the inverter that points downwards ?

I believe from the instructions that the button is on the bottom of the dongle itself, not the USB port on your inverter.

But if you haven’t changed your home wifi or anything major and givtcp is still connecting to it, then its likely your dongle is still setup fine, its just that its not connecting to the givenergy portal. Shutting down and restarting the inverter can fix this problem.

BTW Solaredge batteries are supported with Predbat but have their own set of challenges about not charging and discharging reliably.

G
#149 geoffreycoan

New version of Predbat add-on just released by Trefor v1.2.2, increases the number of generations of Predbat log files retained. I introduced this change in September but didn’t get the for() loop quite right so its now been fixed by Trefor.

Still testing new versions of the multi-inverter support, a new version every day !

D
#150 Daveb01

So had a look at GE Cloud logs, it seems everything went wrong at about 6am ish, and no connection until I rebooted at 11 ish


D
#151 Daveb01

Another Trevor update 👍🎄🥂

R
#152 Rbor

TX200 geoffreycoan You are both correct, the cover and reset button are at the bottom of the dongle.

Now reset and I need to leave it for a while before going back through connecting to the dongle. I know the steps off by heart now.

As I have had dongle issues before, I assumed that was the source of the problems. When I checked out the inverter, the dongle was flashing blue.

Pesky dongle with no LAN option for this inverter.

The problem with my GE kit is that I have spent a small fortune on it: AC3.0 inverter ('small' amount) but two 8.2 kWh batteries – not cheaper).
And then GE bring out the AIO with no upgrade path, abandoning us early pioneers. Our only solution is really to continue using the GE kit until it is well out of date with technology and/or tariffs.

Rob

W
#153 Wavy Davy

Rbor Other problem is that it has no resale value, as it has to be installed and recommissioned by a registered installer.
I understand the reasons why they do this but it means in the real world no-one wants to buy them second hand.

D
#154 Daveb01

Oh dear, I said it was all working but still something wrong, GE Cloud says OK but HA and GivTCP not sure. AIO-2 is not looking good in HA.

G
#156 geoffreycoan

Daveb01 Oh dear, I said it was all working but still something wrong, GE Cloud says OK but HA and GivTCP not sure. AIO-2 is not looking good in HA.

What's in your givtcp logs and if you look in the logbook do you see your gateway and both AIO's providing regular updates to HA:

Might be you need to reset the date on each AIO and the gateway??

@Rbor glad to hear you are getting there. Yes its frustrating the money we have spent to find it has "fragile moments". I feel we are still on the early adopters part of the curve, as you say GE's focus is now all on the AIO. If I was buying now I would buy the AIO or maybe a Tesla Powerwall 3 (although price premium for that) or Pylontech batteries as I can install them myself.
One big advantage of our kit is the superb predbat and HA software, I don't think there is anything like the same level of control and support for other inverters and batteries and when it works it works brilliantly

D
#157 Daveb01

geoffreycoan

Tried that and it said time and date transferred OK, so went for a AIO-2 reboot, back to normal and charge was the same as AIO-1, both now at 23% and charging, phew

C
#158 CW

geoffreycoan If I was buying now I would buy the AIO or maybe a Tesla Powerwall 3

I have (and love) my AIO, but I think that the AIO is not compatible with the AIO2, so I will be restricted to additional AIO's if I expand. I wish the AIO2 was out when I was looking as I really like the whole design (such a tidier install with the hybrid built in).

R
#160 Rbor

Any ideas for getting me back in action. I have been on this since 8:30 am this morning, done the dongle dance countless times, resting dongle, turning inverter off, disconnecting batteries, rebooting router, replacing ethernet cable from my fibre connection to main router.

app and portal show inverter is 'offline' throughout.

Looks like I may have to get in contact with installer and I bet the earliest they could came out will be sometime next week.

Could I get some action by trying GE cloud on predbat?
Documentation refers to a long API key. Would I need to generate one?
Sadly, I don't see this working.

predbat log just shows failure to write to the inverter.
givtcp log fails to find the old IP address.
My router isn't allocating an IP address any more to inverter.
Scan for inverter in app fails.

I have tried the BBC basic inverter app but this cannot make contact to the inverter.

I can't resync time/date if inverter is offline.

What a disaster! 😠😖😡

Just going to try the dongle thing again now!

Rob

G
#162 geoffreycoan

Rbor The first thing you need is to get your inverter back online onto your router. Without that there is nothing more you can do either locally (with GivTCP or the BBC app) or remotely via the GivEnergy Portal.

Using ge_cloud with Predbat isn’t going to help you as that relies on your inverter talking to the GivEnergy Cloud and it’s not doing so.

As Rubikcube says, follow the steps in the Wifi connection guide, but first, some things to check:

  1. What sort of Wifi have you got, is it a mesh, if so, turn off features like fast-roaming
  2. Make sure that WPA2 is selected as the encryption method on the router
  3. Your inverter ONLY connects to the wifi using the 2.4GHz signal. Quite often your router will be broadcasting both a 5GHz and a 2.4GHz signal using the same SSID and will be setup to ‘prefer’ devices to connect to the 5GHz network. THIS WILL ALMOST CERTAINLY STOP YOUR INVERTER FROM CONNECTING TO WIFI. Turn the 5GHz network off, let your inverter connects to the 2.4, allocate a fixed IP address for it on the router, then you can turn the 5GHz network back on.

When you connect to the inverter wifi hotspot and scan for networks, do you ‘see’ your home wifi network, and what happens when you tell the inverter to connect?

First step is getting the inverter onto the home wifi, anything else comes after that.

T
#163 TX200

Also, when trying to connect to the inverter wifi hotspot, you might find your phone/tablet/computer will try to connect to a better wifi to find Internet that works.

You may be best doing this connection from a laptop and might have to tell the laptop/device to forget (or at least not auto connect to) each wifi that is in range of you.

R
#164 Rbor

Dear All,

Thanks for all your suggestions. I am packing up with this for the day, having spent the best bit of 10 hours trying every possibility. I have used the GE Dongle instructions, I already had an address reservation for the inverter set at the router. I am exhausted and so fed up........

And as for that pesky little reset button.

Rob


G
#165 geoffreycoan

Rbor I already had an address reservation for the inverter set at the router

You might have issues with the DHCP allocation table in the router, might need to purge it.

Try removing the address reservation. I keep mine simple, I leave the inverter configured with dynamic IP allocation so it is not trying to tell the router what address it wants to have, I leave the router to allocate the IP address, and once allocated I change the router so that that device's MAC address has a fixed IP (that it had just allocated).

There's always tomorrow, good luck !

R
#166 Rbor

I hope I am the conveyor of good news.
An old year ending in tears 😭 has had an uptick 😃.

I have finally got my inverter online, connected to HA and gicvTCP and to our beloved predbat.

Although I have been using grid energy since about 1 am last night, there couldn't be a better time to get everything back in action with mostly negative rates overnight:

  • Two 8.2 kWh batteries, both empty.
  • A dishwasher crammed full,
  • washing machine primes
  • EV ready for topping up in the really low spots
  • And HP hot water (topping up a bit higher temp than usual.

I just hope that the steady blue inverter light on the dongle persists.

My technique was:

  • Put on food
  • Then flip off the battery breaker between batteries and inverter.
  • Turn off main red switch to the inverter and leave for 10 minutes.
  • Turn red switch back on whilst holding the reset button of the dongle in until I got a blue flashing light (about 30 seconds).
  • Go through the well-rehearsed dongle dance which rewarded me with a steady blue light.

I could then ping the inverter, log onto an online inverter and update date and time.
I restarted givTCP and predbat and the logs show that they are now behaving normally.

The GE dongle is a real weak part of the setup. It shouldn't be this hard to connect an inverter to wi-fi. In contrast, when I got my new mesh system a couple of months ago, my SE PV inverter just connected itself.

Again, thanks for all your suggestions and support. It hasn't been a good day to put it mildly.

A happy Predmass to all

Rob

H
#167 Henry3rd

Sadly, I could not persuade my wife to wait until 22:30 to heat the mince pies. 🙁

G
#168 geoffreycoan

Rbor Well done Rob, perseverance pays off 🎉🥳👏.
So frustrating but glad you got it sorted to take advantage of tonight’s cheap wind-powered rates.

“Happy Predmas to everyone”, like it!

T
#169 TX200

Rbor well done.

Yeah agree re the dongle. Even the inbuilt wifi on the gen3 was a pain. My installers just couldn't get it to work.

In the end, I got some help direct from the amazing Paul and together we cracked it whilst my installers just tidied up everything.

R
#170 Rbor

Looking back, I first noticed an issue at 8:30 am this morning and reset my inverter.
Unfortunately, I hadn't checked out forum threads and I noticed that my dongle was flashing blue. That prompted me to suspect the dongle which initiated my dongle woes..
I wonder whether the time and date issue prevented me from logging on after resetting the dongle.
Catching up on all the comments now, I can see that I wasn't the only one experiencing problems. And it looks like Libbis have been affected also.

After trying various implements, I discover that could hold the connector at the end a usb C cable between my fingers, making it perfect for depressing the reset button on the dongle.
Screwdrivers, pencils, etc all seem to slip off.

After today, it is good to see my Home mini displaying 12 kW of charging over the next half hour for –4.20/unit. And then Predbat is exporting a chunk of this back at 15p/unit because the import rate is 'only' 2.52 kW/unit. Overnight, Predbat has me making about £1.50. 😊

Rob

T
#171 TX200

I was thinking solcast must be broken.

Prediction of 11kWh tomorrow and the weather looks absolutely shocking.

Then I realised tomorrow is Thursday as it's gone midnight. Today's solcast looks right!

Happy new year all.

😁🤦‍♀️😁

G
#172 geoffreycoan

TX200 Oh wow, yes, what a difference a day makes

Today, 1.6kWh forecast, peak power generation on my East array 120W !
Tomorrow, 14.6kWh, peak power generation 14.6kWh

For the second night in a run, GivTCP is throwing a bucket full of errors at me.

Lost communication to the inverters and timing out all the time.

All the power’s gone off apart from my HA server and the internet which are protected by a UPS that’s now beeping like mad. I just realised that the internet repeater in the garage is of course off in the power cut, but it’s a bit moot because there’s no grid to supply anything anyway!

Just hope the engineers fix it within the predicted 2 hour window, I’ve got loads of cheap electricity to consume tonight…

R
#173 Robgy

geoffreycoan did they fix your power within the window they indicated?
We had a 2 hour power outage on Sunday and although my office is protected by a UPS the EPS from my inverter didn't work and just kept tripping out.
Five hours after our power came back on I got a txt from northern power saying they hope to get the power back soon!

T
#174 TX200

geoffreycoan no EPS socket off the inverters? Assuming the inverters are in the garage too, couldn't the wifi repeater be powered from that?

Although not much you can do with it, no charging or discharging!

Did you find the silence UPS button? Mines got one thankfully, but not sure they all do.

R
#175 Rbor

Firstly, I hope all with power cuts issues are back on line.
Collectively, we have had an 'interesting' time since start of yesterday (31st Dec).

My screenshots from yesterday and today from midnight, summarise my experiences from 'donglegate' yesterday and recovery from about 20:30 pm yesterday and overnight with my batteries going from empty (4%) up to nearly full (and on very low or negative Agile rates).
31st December, all day

1st January midnight – 09:20 am

But we all have our own tales to tell .................

My energy dashboard for yesterday is pure fantasy. Solar shows as a single peak 8pm-9pm when I got my inverter back. I will be able to correct this to spread generation over the day.
........but my energy usage is shown as 2,845 kWh! Thankfully, Octopus shows this in line with my GE chart above with low usage during the times my inverter was down.

After today, the next few days look sunny, I have 14.6 kWh forecast for tomorrow and days are getting longer. ............ although I can so easily lose all solar with just a light dusting of snow.

Rob

G
#176 geoffreycoan

I posted my message above about the power cut at 1:26 and then went to bed, but I could hear the UPS beeping away with increasing frequency as the battery ran down so got up and shutdown my HA server so that it didn’t crash when the UPS ran out.

Maybe a bad move because according to UK Power Networks they restored power at 01:46 which can’t have been that much later on. And that matches what I see in the GivEnergy portal that the inverters started re-sending data to the cloud at 01:46.

I assume Predbat must have already sent the first set of charge up commands to the inverters because they charged up through the night on the cheap electricity. Didn’t get the intermediate exports because the HA server didn’t restart automatically ☹️. Shutting it down to prevent a crash meant it didn’t restart itself when the power resumed. But at least I woke up at 7am and was able to power it back on for Predbat to export ahead of this morning’s power up event from 9-11:30.

R
#177 Rbor

geoffreycoan Glad that you are back in action.
Yesterday, you alerted us all about the date time issue and provided a fix.
You didn't deserve a power cut!!

We now march forwards.
The nordpool predictions are not great but it looks as if Predbat is planning to charge my batteries from my predicted solar PV from Solcast for tomorrow. Solar should increase from now on with less reliance on low grid rates.
....... and the next Agile events will arrive .......

Rob

V
#178 Vestas

Rbor Umm you haven't noticed the snow forecast for most of the UK? Saturday through Monday, we're forecast for stupidly high amounts (20cm+) and that's East Mids.

After the shutdown of the gas pipeline through Ukraine today I reckon its batten down the hatches time again for Agile users from this weekend onwards (99.99p again). Either that or flip tariffs for a couple of weeks if it doesn't affect your standing charges.

B
#179 Boffinboy

Agile has not been great the past month or two… wondering if I should return to Cosy, especially now it has the third low rate slot. Agile was great last winter, but at the moment Cosy is looking very attractive…

G
#180 geoffreycoan

Boffinboy Yeah, Agile prices have had some bad days the last couple of months, but also some good days.

Have a look at https://community.givenergy.cloud/d/3678-making-the-most-of-octopus-agile/524 where @Windy Miller shares his analysis. For him it looks like there would have been a slight saving for Cosy over Agile.

I've done some simple comparison of my own consumption on Cosy vs Agile. For November 24 (excluding any standing charges rate difference), Cosy would have been ~ £18 cheaper, for December 24 would have been ~ £21 more expensive. Approx 10% on my monthly import bill and feels like its in the margin of error to not be worth changing.

Of course everyone's consumption pattern is different.

R
#181 Rbor

Boffinboy Also consider increased SO by changing to Cosy.
Your choice of course but do check out relative actual costs.

In Nov 2024, my average Agile rate has been 14.96 p/unit
In Dec 2024, my average Agile rate has been 10.72 p/unit
(Source Octopus watch reports from 30 min actual costs)

I have looked at Cosy but decided on balance to stick with Agile, as I have done for nearly a year now.

Rob

G
#182 geoffreycoan

Rbor I have just now renewed my Agile for another 12 month term.

December 2023 Agile (I’m on now) standing charge 42.01p
new October 2024 Agile standing charge 48.79p

£25 a year increase

Cosy from 1/1/25 48.788p so for me, not a lot in it (but for Rob in Yorkshire or those in the South West, 66p, and North East its 70p).

R
#183 Rbor

My Yorkshire increase in SO for 2025 equates to £104.90 a year increase! Yikes.
My only saving grace is that my import rates are less than the cheaper SO regions.

Rob

R
#184 Rbor

@geoffreycoan I have just seen your marvellous piece of work on reducing the size of the HA database.
Looks like a long term project for me as I crawl up the HA learning curve.

Thanks so much for this.

Rob

G
#185 geoffreycoan

Rbor Thanks Rob, it’s taken a while and there’s a lot of different techniques in there. But some quick wins on disabling sensors and filtering out sensors you don’t need the history of.

I will put some of the predbat-specific stuff in the documentation but will wait to see what the feedback is first.

Cheers

D
#186 Daveb01

Rbor

As it is my Solar and battery, can I not charge Octopus a standing charge to use it?

I was thinking 50p but will discount it to 48.79p 😎✅

H
#187 Henry3rd

Can anyone point me in the direction of a fix for this error? I have looked at the manual but can't see it (there again, I can't find a tin of beans in the store cupboard!)

"Entity sensor.givtcp_fd2319f635_soc_kwh from integration mqtt has state class total_increasing, but its state is not strictly increasing"

G
#188 geoffreycoan

Henry3rd "Entity sensor.givtcp_fd2319f635_soc_kwh from integration mqtt has state class total_increasing, but its state is not strictly increasing"

It’s a givtcp bug. The battery soc can increase or decrease and the sensor has been incorrectly defined as always increasing by givtcp

B
#189 Boffinboy

Rbor my average rates have been above Cosy for the past few months, occasionally pulled down by the few windy days where Agile goes super low. Last winter Agile was much cheaper than Cosy. Octopus Compare is not loading for me, but plan to check how it thinks they would have compared.

My spreadsheet suggests my average Agile rates in Jan, Mar, May, Nov, and Dec were higher than Cosy. nice thing about the new 3 slot Cosy is the consistency - which means I can also run my A2A and reduce some gas use. The three dips also mean not far of all load would be at the lower rate, but can’t get super low.

D
#190 Daveb01

Just logged in to HA and loads of logs in Predbat.
Plus weird plan in next few hours? No idea what’s going on, I have just rebooted HA and will see if it is still the same in an hour

R
#191 Rbor

Daveb01 My predbat and givTCP logs are fine.

Have a look at your predbat and givtcp addon logs rather than webUI.
You are getting this repeated line:

There is something wrong. Your inverter seems stuck on pause and the have a strange burst of charging Sat 03:30 - 05:00 am.
I am not sure what 'charging pause means!' At night, your cost doesn't change.

Also have a look at your GE dashboard to see if that offers any clues.

In my predbat log, I have a load of Historical day gap warnings but I tidied up my energy dashboard for 31st Dec when my inverter was down and any values were thrown all together at the end of the day.
My status report is clean showing demand at moment and no earlier glitches.
e.g.

So I think there is an issue with your system rather than another givTCP hiccup.

Rob

D
#193 Daveb01

Rbor

This was the GivTCP log just now

This is the Predbat log just now

R
#194 Rbor

Look at the last line in the givTCP log:

The HA discovery isn't working.

Have you tried restarting predbat or mqtt?

This was my starting sequence last time I restarted givTCP. You can see that givTCP is responding as it should after publishing HA discovery messages.

Rob

D
#195 Daveb01

The plan now looks like this. I know it could change but something does not look right and I have not seen this before.





D
#196 Daveb01

Rbor

Rebooted again now get this

G
#197 geoffreycoan

Daveb01 There’s no point in looking at the plan really for Saturday as the rates will change.

But looking at Friday, it looks OK to me

overnight the Agile rates are poor, charging is paused and your battery drops from 75% at 22:20 to 57% by 8:30.

Then from 8:30 onwards your solar prediction is higher than your load prediction and your battery charges from solar from 57% to 83% by 16:00 on Friday. Then the plan is cutoff but your battery is at 53% by Saturday 00:00, compare that to Friday 00:00 where it was 72%, yes its lower but a long way from being empty.

What do you think the plan should be doing?

D
#198 Daveb01

geoffreycoan

I guess it was all the planed charges, even during the peak time and battery at 100%, why would it predict that?
Plus why would it say Charging Paused all night and not demand?

It just did not look right.

G
#199 geoffreycoan

Daveb01 I guess it was all the planed charges, even during the peak time and battery at 100%, why would it predict that?
Plus why would it say Charging Paused all night and not demand?

The Saturday stuff does look weird, and maybe there is a Predbat bug there that you’ve exposed by having a long plan duration (as I said I only run my plan for 24 hours after the charging so I never look that far ahead).

Feel free to raise that on Github because it does look wrong.

As for Charging Paused not Demand, mine does Freeze Charge often at night rather than Demand, I take it as just the way Predbat does its thing….

D
#200 Daveb01

geoffreycoan

Thank you for the reassurance, I have rebooted everything again and something has changed again. It does now not go to Saturday it stops Friday now plus the is thick line after 23:30 today and tomorrow?

Think I will leave it as is now and have a look in the morning. Thank you again for the help 🍺

P.s. I changed my [reduction back to 24 ages ago, do you think the 48 stuck until I repotted a few times?

R
#201 Rbor

For the record and for comparison, here is mine:

Tomorrow (Sat), you can see that my projected PV generation is greater than load and predbat wants to use this to charge my battery.
My problem though is that the ASHP is energy-hungry at these temperatures ..... and there won't be that amount of PV excess to get the battery SOC up to what predbat wants.

Perhaps I should up input_number.predbat_load_scaling up from its default of 1.05.
I was sure that I had increased this to 1.2 but looks like a case of 'predbat knows best'.
I am going to up this to 1.2 and think about 1.5.

Daveb01 Looks like your ERROR line has disappeared from your givTCP log.
It would be nice to see an instruction added as the first HA discovery message but your 1st change in your plan is not until midnight.

Rob

R
#202 Rbor

When you restart HA, I don't think the add ons like givTCP and predbat and MQTT are restarted. @geoffreycoan will put me right if I am wrong here ......

Rob

G
#203 geoffreycoan

Rbor my load scaling is 1.15 already and I could increase it further, but its all a bit moot as my ASHP consumes far more than my battery capacity (e.g. today, ASHP 40kWh).

Predbat basically charges overnight in the cheapest rates it can then holds the battery to the start of the peak. Maybe a bit of pre-peak charging if the batteries have dropped a bit or solar wasn’t enough.

Think we will be in for a few expensive days coming up. Even with a 2 hour powerup earlier today, I’m up to £9.19 today. Hey ho, plenty of account credit still to consume

G
#204 geoffreycoan

Rbor When you restart HA, I don't think the add ons like givTCP and predbat and MQTT are restarted. @geoffreycoan will put me right if I am wrong here ......

You are correct, a ‘default’ restart HA only restarts HA. You have to click on. the ‘Advanced options’ and ‘Reboot’ to restart HA and the addons (Predbat, GivTCP, Mosquitto broker etc)

R
#205 Rbor

geoffreycoan My increase to 1.2 has made hardly any difference.
Today (2nd Jan), my ASHP has eaten 26 kWh with mean temp of –2C (4 defrosts during day)
On 31st Dec, my ASHP consumed 12 kWh with a mean temp of 8C, a mere snack.

What a difference the ∆ of 10C makes across the 2 days.

We need those Agile days to see us through .......
Looking at the new rates, Cosy low slots are up by 0.6p and standard Cosy slots up be about 2p.
As Agile use wholesale prices, they will doubtless creep us.

To be fair to use, should the export rates be increased?

Rob

R
#206 Rbor

geoffreycoan Perhaps I will shortly be able to graduate from my rabbit level, although my 'stupid' comment about linking a PV inverter directly to AC coupled inverters sent me scurrying back to my warren.
My excuse is that I had spent all of 31st Dec sat in front of my inverted and my AC inverter is positioned next to my PV inverter.

Rob

G
#207 geoffreycoan

Rbor Looking at the new rates, Cosy low slots are up by 0.6p and standard Cosy slots up be about 2p.
As Agile use wholesale prices, they will doubtless creep us.

its the other way round. Agile is wholesale prices so we see increases and decreases on a half hourly and daily basis.

The other tariffs are priced based upon predicted wholesale rates for the quarter ahead.

So the quarterly price review and SVT and all the other tariffs going up or down doesn’t affect us on Agile or Tracker, we are already paying the true market rates.
Potentially changes in the electricity model of variable vs fixed parts of the Ofgem charging calculation (i.e. how much of the wholesale costs are levied as variable and how much as fixed standing charge) may filter through to a revised tariff with revised SC, but that seems to be much less frequently than annually, and we’re on a fixed duration tariff anyway so our standing charge doesn’t change until the 12 months is up.

L
#209 Leeshore

Rbor hopefully it is sunnier this year than it was in 2024........

D
#210 Daveb01

Rbor

Looks like everything went back to normal, after the second reboot. Yes I used the reboot HA & apps.

BTW the battery went down to 8.7 deg in the night (it’s in the garage) outside temp went to -3.7 deg here (Fareham). First time below 10-12 deg which is the norm in winter. I hope those with their battery outside did not have any issues.

Thank you both again.

G
#211 geoffreycoan

Daveb01 My battery cell temperatures were between about 15 and 20 degrees overnight and the BMS between about 12 and 32. My batteries are in the garage as well. I have chosen not to upgrade to BMS 3017 from 3015 as 3015 work fine and I know 3017 introduces the temperature rate limiting.

I do have low power charge mode turned on.

My outside porch temperature sensor read 0-1 degrees

Heat pump has not been too bad, 8kW used so far today of which 1.4 was the 3:30 hot water cycle. Looks like the heating came on almost precisely every hour at 4:30, 5:30, 6:30, 7:30 and 8:30 to boost the house temperature back up. Won’t be especially cheap for me for the next few days

H
#212 Henry3rd

Daveb01

Ooh err 5.3 deg :0

R
#213 Rbor

After the plunge rates as the old year changed into the new year, it's looking like an expensive few days on Agile ........... 😠

Solcast is predicting PV generation of 0.0 kW for me on Sunday!

Rob

W
#214 Wavy Davy

Anyone else had a power up message from Octopus with no date or info?
Bit strange.

W
#215 Wavy Davy

Rbor Got you there, I'm forecast 1.72 kWh tomorrow and a whopping 0.36kWh on Sunday.
Mind it forecast 3.1kWh today and I generated 1.5 so less than 50% of forecast.

D
#216 Daveb01

Rbor

Not as bad here down south. Today was only .2 out.


R
#217 Rbor

Daveb01 I was up on forecast for today 😎:

But your subsequent days looks positively tropical compared to mine:

Just look at the state of my predicted Day 2 (Sunday) and Day 3 (Monday)!!!!

From weather forecast, it looks as if I might disappear under snowdrifts. Let's see.

Rob

G
#218 geoffreycoan

I’m still getting some generation, today was forecast as 14.8kWh forecast, I achieved 10.7kW, just scraping in at the 10.7 PV10 forecast which is unusually bad for me.

Tomorrow 5.2 forecast but the Sunday is 1.8.

With the cold weather my ASHP consumption has shot up, you can very clearly see the correlation between average outside air temperature and heat pump consumption

Looking at the power vs temperature I can see that most of the day the heat pump has been trying to recover the house temperature from the 17 degrees overnight setback to 19 degrees target temperature with plenty of 10kW spikes as the heat pumps run at full chat.

So tonight am trying a different strategy, keeping the central thermostat at 19 degrees with no setback. Will be higher consumption overnight but hopefully lower during the day.

Cost of all this on Agile has been £17 so far today. I did a quick envelope calculation, Cosy would be about £15 and SVR £20. Not a massive difference.

No empty power up emails for me BTW, don’t think I’ll see any until maybe late Sunday when its windier

R
#219 Rbor

My HP so far today has eaten 24.5 kWh.
Like energy cost for me today from predbat £6.35.
It's actually above freezing currently and have had some fine drizzly rain – should freeze over treacherously for the morning. 🥶

In your 1st chart, is the x axis date correct as the last bar looks as if it is for 4th Jan, which is tomorrow?

Rob

G
#220 geoffreycoan

Rbor In your 1st chart, is the x axis date correct as the last bar looks as if it is for 4th Jan, which is tomorrow?

Damn, I was hoping that you wouldn’t ever find out I am a time lord ….

Either that or I’ve forgotten to configure the Apex chart to allow for these being day-end total figures.

I keep getting alerts from my battery automations telling me that the battery temperatures are 7.3 and 9.7 degrees C.

R
#221 Rbor

My kit resides in my large porch which had a nice big radiator.
Lowest temperature at night is 19C!
So for me, I don't have a worry about low temperatures affecting battery performance.

Rob

W
#222 Wavy Davy

My inverter is in a cupboard in the porch with the batteries in a alcove underneath. Min. Inverter temp has been 26 and batteries 12.

R
#223 Rbor

My GE inverter gets to min of 31C overnight.

In the early hours last night when inverter was working away, it got up to 55C, with batteries getting up to 28C. The inverter is clearly the workhorse of the setup.

Rob

H
#224 Henry3rd

I have battery temperature envy!

D
#225 Daveb01

Oh dear it’s happened again at 04:30. Battery was idle when I got up this morning.

I have the automation in Predbat that restarts, but GivTCP lost its connection to MQTT for some reason?

I will have another look at the link you sent me Geoffrey.

G
#226 geoffreycoan

Daveb01 what happened after that Dave and what happened in the Predbat log?

In my own GivTCP logs I get the occasional error communicating with the inverter that either gets cleared by GivTCP trying multiple times and then flushing the cache and restarting itself, or Predbat deciding to restart the givtcp addon. And then rarely the givtcp activity monitor deciding that givtcp or mqtt isn’t working and restarting them.

Together this seems robust. I rarely look at the givtcp log, but looking just now I see typically 1 set of noisy errors a day

D
#227 Daveb01

geoffreycoan

MQTT looks ok and carried on as normal.

So just GivTCP and Predbat.

I have this in yaml

G
#228 geoffreycoan

Daveb01 your yaml looks OK but it looks like Predbat didn’t restart GivTCP when it got all those rest failures. You should raise it on GitHub with the log files for Trefor to take a look as I think it should restart GivTCP and that would have cured the problem.
Interesting that its only set discharge rate is failing; at 4:32 in the givtcp log it sets the charge slot OK

If its still persisting, restart givtcp

D
#229 Daveb01

geoffreycoan

Thank you, I restarted GivTCP this morning after I spotted it and it’s been ok since.

G
#230 geoffreycoan

Daveb01 in the logbook were the other givtcp entities updating ok ?

D
#231 Daveb01

geoffreycoan

Had a look in the logbook and can see these, but as I am still a Rabbit, I do, pt quite understand it yet.

G
#232 geoffreycoan

Daveb01 so what I was particularly looking for as the ‘inverter time’ entity changes, these are appearing regularly and show that givtcp is polling the AIO’s and gateway OK (there are a number of sensors shown you could possibly disable, but that’s for another time).

If givtcp is regularly talking to the inverters then my error detection automation won’t detect that givtcp has stopped working, and it looks predbat is only reporting a warning not an error so again the external automation won’t pick that up. It is down to predbat to try the givtcp restart if it keeps failing, and under normal circumstances that’s what I see happen on mine

R
#233 Rbor

Sunday morning 5th January.

At least Solcast was predicting me 0.0 kWh today ........

Rob

D
#234 Daveb01

Rbor

So does Solar radiation (not sun) not work through snow 😛

I am surprised some clever cloggs has not invented windscreen wipers on Solar panels yet?

End of Sunday dad jokes 👍

W
#235 Wavy Davy

OOPS inadvertently pressed "send saving session to predbat" button and now have

and
2025-01-05 11:30:02.051255: Warn: record_status Bad start time 2024-12-12:00 provided in energy rates

How do I get rid of message or will it just clear in time?
Tried restarting predbat and full restart of HA but still there.

T
#236 TX200

The snow had slid off my panels by 9.30am.

Not much sun though, 0.2kWh so far.

D
#237 Daveb01

Slightly off topic but found this article interesting.

However charging a battery from 5% to 60% in 5 mins will give Trevor new year challenge?

V
#238 Vestas

Daveb01 Solid-state batteries are a bit like nuclear fusion - lots of "could be's", "problems scaling up" and "expected to begin" statements in articles 😉

This article sounds like someone in Germany is pumping up expectations which isn't surprising since the Chinese are basically annihilating German car manufacturing (long overdue IMHO).

I wouldn't expect to see volume production inside a decade. If it works.

R
#239 Rbor

TX200 During the day, snow slid of half my panels.
It is always good to exceed predicted solar, even if it is just 0.4 kWh with a max of 0.2 kW.

For the next 2 days, I am predicted 0.17 kWh and 0.94 kWh, ASHP is eating up electricity either generating heat or defrosting.
An expensive few day although it looks as if we will be getting some better overnight Agile rates to fill the batteries.

Rob

T
#240 TX200

Also 0.4kWh here today with heavy rain now.

Tomorrow 1.69kWh predicted and 7.41kWh for solcast day 3 which i assume is Tuesday?

H
#241 Henry3rd


I don't like to rub it in, but....

W
#242 Wavy Davy

Rbor
Me Neither..😆

Managed a whopping 0.7 despite the day long drizzle

D
#243 Daveb01

Oh dear, loads of updates, HA, SolarEdge, HACS, Octopus.

Leave it a few days and see what you guys say? No chance this time button pressed just now.

😜✅

H
#244 Henry3rd

I have updated everything with no apparent issue.

S
#245 SteveCook

Why doesn't someone start an updates discussion about any updates they have uploaded and user experiences.
Call it HA updates

D
#246 Daveb01

SteveCook

Sorry I won’t do it again in this post

#247 Hook

I’m very much a if it’s not broke don’t fix it type of person. I’m still on appdaemon-predbat and am on the latest version v8.10.0.

I just want to check there are no plans to deprecate this version. Are all giv products supported on this version?

I have a gen 1 inverter so pretty basic.

G
#248 geoffreycoan

Hook Trefor has said that he will at some point stop supporting predbat running under appdaemon.

The documentation for the appdaemon-predbat addon has been removed, Trefor saw that as an interim step from appdaemon to the full predbat addon.

I was on appdaemon for ages, only upgraded when I found a replacement for the octoblock app I ran in appdaemon and Trefor introduced the predbat manual API so I could send power up events into predbat.

Wavy Davy How do I get rid of message or will it just clear in time?

It won’t clear as you have set a rate override via the manual API. But its easy to clear it, bring up the select.predbat_manual_api control and just set it to [off] and it will remove all manual API configs. Or you can remove a single entry if you want to.

Rbor During the day, snow slid of half my panels.

Looks from the energy dashboard that my snow must have come off at 11:00 as the solar production jumped from zero to 0.36 across the 3 arrays. Woo. 2.3kW in total.

My experiment with running the heat pump through the night was expensively disastrous, it worked and the house was warm on Saturday but it gobbled so much electricity. Think I had the heat pump turned up too much because I dropped it 2 degrees and flattened the weather curve a bit and consumption dropped dramatically.
Yesterday (Sunday) I started the heat pump back up in the middle of the night on the slightly cheaper electricity and the consumption was quite reasonable. The house reached temperature around lunchtime and the batteries latested to 22:30 which is unheard of for me in winter.
I need to continue fiddling I think ….

R
#249 Rbor

geoffreycoan Helped to clear the road for 4 hours yesterday which was exhausting.
I live on a steep hill and, at one stage, we dug out a 4x4 which couldn't get up. By end of day, snow had slid off most of my panels.
...... then the snow returned overnight, undoing yesterday's hard work. 🥶😩

EDIT: 2 hours later and a very hazy sun has been sighted. I need to do some more snow-shifting and then up a short ladder to brush the snow off my extension panels. Some snow is sliding off anyway.
I need some sun and panels to generate to help to contribute to my energy costs.

Should I clear the snow from the top of my heat pump or leave it on as insulation? I suspect 'clear it off', as it freezes to the top.

I hope you are all coping better than I am.

Rob

Rob

W
#250 Wavy Davy

geoffreycoan Geoff, Where is "select.predbat_manual_api"?
the only reference I can find is in predbat is the GUI. which says it's off but doesn't allow me to change it.

If setting it to off clears it, don't understand why it still shows settings.
Also In the documentation it says you can clear from the selector but you have to set them using a service call. Which maybe explains why I cant now change it manually, but can it be reset it using the command line?. If so what command would I use?

G
#251 geoffreycoan

Rbor it snowed Saturday night into Sunday so white everywhere, then rained for much of the day and all the snow has gone. I’ve got a cold though so laid up not doing very much at all, didn’t go onto the forum until late last night.

Wavy Davy the predbat manual control is in the list of entities the same as any other entity:

you should be able to set the value to ‘off’ (no square brackets, mu mistake)

or I have it added to my predbat control dashboard alongside all the other predbat manual select’s:

or if you want to poke the command manually, go to developer tools/actions and (based on editing the script I wrote to send commands to the predbat manual API for power up events):

    action: select.select_option
    data:
      option: off
    target:
      entity_id: select.predbat_manual_api
W
#252 Wavy Davy

Thanks Geoff, I used the manual command method and that cleared it. Have since added it to my dashboard, although I will try not to cock it up again.
Thanks for the help (as usual)..

J
#253 Josephiah

Is anyone else getting slightly weird plans with Predbat v8.10.0?

Here is the plan under v8.9.3, which looks pretty normal to me (charge from empty to full rate in the cheapest overnight slots):

But v8.10.0 is suggesting this instead (note the strangely low charge rate and prolonged charging periods):

D
#254 Daveb01

Josephiah

I have had two incidents that look similar. My issue was GivTCP was not talking to MQTT and Predbat was then having issues.

If you look at the logs in Predbat and GivTCP you may see some errors, however it will not fix the issue. Restart MQTT, then GivTCP then Predbat. Then wait about ten mins for Predbat to recalculate.

If that does not work reboot HA (under advanced HA and all apps) then wait 10 mins to see if it’s ok. If that works, then you can go back to the logs to see if you can work out what caused it.

If it did not work then you may need to screen shot the logs so the experts on here can help.

R
#255 Rbor

I tend to not look too closely at overnight plan until after 4pm when we get the official rates.
And then, I identify good slots for dishwasher, washing machine, etc

But, as far as predbat is concerned, it can flit around until a relatively stable plan emerges.

Rob

G
#256 Goshiki2

Rbor I’m the same. I’ve got the Nordpool rates indicated but to be fair I don’t think Predbat really does anything with them and they were so far out today that I’m not totally convinced there is any value in adding them. My plan changes regularly and in the morning it’s often charged the battery very differently to how it was predicting before I went to bed but so far it seems to be working well for me.

R
#257 Rbor

Goshiki2 I don't think I have ever seen the 4pm rates so far adrift from Nordpool.
A real disappointment.

Rob

W
#258 Wavy Davy

Rbor Rob, are you looking at the nordpool data on the plan or is there a site that shows them?

#259 Hook

geoffreycoan is there an easy upgrade document?

Or is it starting from scratch again?

G
#260 geoffreycoan

Hook geoffreycoan is there an easy upgrade document?

Assume you are asking about upgrading from appdaemon to the predbat add-on.

Don’t fear, I already have you covered, the steps to follow are in the installation guide part of the documentation https://springfall2008.github.io/batpred/install/#upgrading-from-appdaemon-to-predbat-add-on

Once setup, you can quite easily revert and swap between the predbat addon and appdaemon just by stopping and starting the appropriate addon’s.

J
#261 Josephiah

Daveb01 thanks. Not seeing any obvious errors in the logs for any of those three, either before or after doing the restarts. To me it seems like an algorithm or settings issue rather than a comms one.

The restarts do seem to have solved the apparent slow charge rate thing, so both plans (under v8.9.3 and 8.10.0) are effectively the same thing now, just implemented differently.

However, there's another aspect (affecting both versions) that I've noticed quite a bit lately: why is the algorithm ignoring cheaper slots in favour of more expensive ones (evident in both of previous screenshots, and also highlighted below)? My initial thought was the "combine slots" setting, but that's switched off. Anything else that could be causing this?

G
#262 geoffreycoan

Josephiah why is the algorithm ignoring cheaper slots in favour of more expensive ones (evident in both of previous screenshots, and also highlighted

Have you got switch.predbat_set_charge_freeze turned on or not?

If its not turned on then predbat won’t be able to set charge freeze between these cheaper slots and the next charge period, so after charging up the battery wil then discharge for little financial value

(Nice for once to see someone else’s plan that’s spending more on electric today than me !)

J
#263 Josephiah

geoffreycoan Thanks. Yes, that one is switched on. And it is managing to schedule freeze slots without issue (e.g. 03:00 in the screenshot above). It's a weird one. This is one of the simpler optimisation challenges (fill from empty to full - basically just a case of ranking the slots and picking the cheapest 6 or 7), and yet I can knock 50p off Predbat's suggestion easily. I'm used to it managing far more complex scenarios with apparent ease...

Yeah, the heat pump is not enjoying this sleety weather/temps!
(Edit: you may remember we had a discussion a few months ago about predicting heat pump usage from forecast temperature using a curve fit - that part works nicely, but I've never quite got to the bottom of what Predbat then does with the info fed into load_forecast... I'm pretty sure it does something, but I'm not convinced that it's not double-counting something, as my actual total cost at the end of the day is rarely as bad as the threatened costs look earlier on...)

G
#264 geoffreycoan

Josephiah geoffreycoan Thanks. Yes, that one is switched on. And it is managing to schedule freeze slots without issue (e.g. 03:00 in the screenshot above).

Ah yes, I see it now. I’m not particularly used to the icon version of the predbat plan, I have old skool words on mine as I find it easier to read at a glance.

It's a weird one. This is one of the simpler optimisation challenges (fill from empty to full - basically just a case of ranking the slots and picking the cheapest 6 or 7), and yet I can knock 50p off Predbat's suggestion easily. I'm used to it managing far more complex scenarios with apparent ease...

Predbat does it in a more advanced way than that, it looks at future rates, charge and discharge rates, solar generation, load forecast, etc to optimise the plan.

But anyway, I haven’t upgraded to 8.10.0 yet. The release notes suggest Trefor has made some biggish changes to the optimisation algorithm so perhaps worth you sharing what Predbat is doing in the field with him.

I sometimes throw a few manual overrides in to the plan if I don’t like what it’s doing, but less than 4 hours out from execution it should be getting the plan right.

Yeah, the heat pump is not enjoying this sleety weather/temps!

I’m back to fiddling with my heat pump settings again to see if I can improve it further.
I was running on a 19 degrees inside temperature with 17 degrees setback overnight which was fine, but when it turned really cold the end of last week it took all day for the house to get back to 19 degrees so I’ve been trying variants of the overnight setback. Leaving it on 19 degrees overnight was ruinously high consumption so have tried stepping back to 18 in the middle of the night when the Agile rates are a bit lower so the first hit of the ASHP is on cheaper rates.

Your consumption through the night looks consistently high, do you not set back the temperature overnight?

J
#265 Josephiah

geoffreycoan I have old skool words on mine as I find it easier to read at a glance.

Ah yes, sorry, I've tended to default to that card as I can get it compact enough for my phone screen.

geoffreycoan Predbat does it in a more advanced way than that, it looks at future rates, charge and discharge rates, solar generation, load forecast, etc to optimise the plan.

Yes, I understand that - was making the point that under these conditions (high load, no solar, battery only just enough to convert the agile peak) that's what the problem effectively reduces to. Maybe it's just that that fact makes errors much easier to spot as the plan is (or should be) very intuitive.

geoffreycoan But anyway, I haven’t upgraded to 8.10.0 yet. The release notes suggest Trefor has made some biggish changes to the optimisation algorithm so perhaps worth you sharing what Predbat is doing in the field with him.

I don't know when it started - I first noticed a few oddities a few weeks ago, but assumed it was just some of those "Predbat will sort it out as we move forward through the schedule" things, but I don't think that anymore. It must precede the latest changes - it has exactly the same behaviour when I revert to 8.7.3. Will raise a ticket when I get a moment.

geoffreycoan I’m back to fiddling with my heat pump settings again to see if I can improve it further.
geoffreycoan Your consumption through the night looks consistently high, do you not set back the temperature overnight?

Lots going on here - will come back to this in another thread later when I find a moment.

L
#266 Lincs_Will

Hi all, another Predbat for newbies question. It seems to not charge my battery fully sometimes. This morning it left 2.5hrs to charge my battery (9.5kwh) from empty and it only managed to get to 84% by the 0530 IOG end of cheap rate. These days I need a full battery to just about make it to 2330. If I do any washing/tumble drying then obviously I'll run out of battery early in the vening so I think Predbat should be trying to hit 100% charge at 0530. Battery temp wasn't an issue as it'd charged and discharged from 2330-0300. I've got a battery charge curve setup in the apps.yaml file so I assume it should incorporate the slower rate of charging from 91% in any planning. Is there another setting I should configure? It has been on holiday mode from 24th Dec - 4th Jan. Could that be throwing off Predbat's usge assumptions meaning it thinks it doesnt need to fully charge the battery? I'm using Predbat 8.10 BTW.

G
#267 geoffreycoan

Lincs_Will lots of good questions

first thing is whether you have got predbat setup correctly for your battery

What inverter do you have, its max charge rate, and what BMS are you on? If you have 3017 or 3018 then these slowdown the battery charge rate when the battery cell temperature is below 20 degrees, and unless your battery is in a heated part of the house this could well be affecting your charge rate. You say you don’t think temperature was an issue but were was the battery cell temperatures?

There is a discussion on github about incorporating battery temperature curve logic into predbat because at the moment Predbat doesn’t know that your battery won’t achieve what the inverter says it will.

You can adjust input_number.predbat_battery_rate_max_scaling and limit_battery_charge in apps.yaml to better reflect what your battery/inverter can achieve, e.g. I have my battery_rate_max_scaling set to 0.92 as my battery only ever charges at 2.4kWh not the 2.6 the inverter says it can do.

Yes predbat will incorporate the battery charge curve in the plan so should take account of the slowdown in charge rate from 90%. It might be worth you comparing the charge curve to the actual charging results to see whether the curve is correct, if Predbat generated it, it should be, but still worth checking.

Being in holiday mode previously shouldn’t affect the predbat forecast going forward https://springfall2008.github.io/batpred/customisation/#holiday-mode but if you were away then the historical load will probably be incorrect. Might be worth shortening the duration of days_previous you are using in apps.yaml whilst you build up historical load to match what is more typical.
Have you got load scaling set to a value, this should help Predbat recognise if you are using more than the load forecasts, and turn switch.predbat_load_filter_modal on to ignore the lowest days_previous history

R
#268 Rbor

Josephiah I think I am coping with the current weather reasonably well.
My 10 kW Viessmann ASHP system runs entirely on weather compensation. I have no gas, so solely electricity.
I am in a 1920s detached: typical insulation (except loft) well below modern standards.
My system is set at 20C 6am-9pm and at 17C setback overnight 9pm-6am.

I have an internal temperature sensor in main open plan living room and this settles to 20C daytime (higher if there is any solar gain) and drops only to 18.7C at lowest overnight. The internal sensor does not control the HP at all.

I have experienced minimum temperatures down to –4C and daytime below zero (–0.3C now at 11:15am).
My weather curve is set at 0.6 slope and 0.2 level (not all HPs have level).

Setback certainly saves costs and doesn't seem to affect the established thermal mass much.

My SCOP is 5 but in current cold snap, COP has dropped nearer to 4. I am getting defrost cycles every 2 hours on average. My peak electrical energy input has been 34 kWh and 30 kWh (Sun and Mon) and matches last winter's coldest days.

So worth looking at your HP settings.

With predbat, I do have solar which can help (if panels have no snow on them!).
I am on 8.8.10 and it is too soon to see if this version has affected me. My max daily cost is near to £8, very high for me.
My technique is to let predbat do its own thing. I very rarely intervene, and this has worked well.
There are some current discussions on battery temperature. My batteries are in a large porch where temperature is house temperature, about 20C. But batteries can be adversely affected by cold temperatures which may affect historical data and predbat may respond by predicting a greater load. Your load during the night looks high.

I hope that there is something in my reply to help alongside the replies from @geoffreycoan
My comments are more focussed on your wider setup rather than just predbat.

Rob

L
#269 Lincs_Will

geoffreycoan Thanks! Ive got a Gen 2 5Kw inverter and I'm using BMS 3017. I've checked the logs of battery cells temps. They were all above 20 degrees from 0300-0530 so the temp throttling shouldn't have been an issue.

GIvenergy specs say my inverter should charge/discharge and 3.3/3.6KW and looking at the battery power recorded by GivTCP last night it managed 3.3-3.4kw and charged from 7% SOC to 84% between 0300-0530. I don't know what Predbat thinks my inverter can do as I've not set it anywhere. Maybe it assumes 3.6KW as I think thats what the battery can do? I've changed input_number.predbat_battery_rate_max_scaling to 0.92 as thats the ratio of 3.3KW to 3.6KW and I'll see how that goes.

I do remember discussion in 2023 when I 1st got my system installed about battery calibration and SOC drift. I wonder how the inverter/BMS handles that with Predbat more or less constantly trying to charge & discharge as I think it needed to be left to realign the SOC.

B
#270 browellm

I tried the HA update and did HACS 2.0.2 at the same time and it seemed to break apexcharts (not sure which update did it) so I reverted to this morning's snapshot. Haven't had time to diagnose yet.

G
#271 geoffreycoan

Lincs_Will GIvenergy specs say my inverter should charge/discharge and 3.3/3.6KW and looking at the battery power recorded by GivTCP last night it managed 3.3-3.4kw and charged from 7% SOC to 84% between 0300-0530. I don't know what Predbat thinks my inverter can do as I've not set it anywhere. Maybe it assumes 3.6KW as I think thats what the battery can do? I've changed input_number.predbat_battery_rate_max_scaling to 0.92 as thats the ratio of 3.3KW to 3.6KW and I'll see how that goes.

Predbat assumes what the inverter says it can do unless you override it with the input number or the inverter limit in apps.yaml. It should report the charge and discharge rate its using the in logfile but it does sound like that would be a cause of your issue.

Late tonight do a screenshot of the predbat plan and then look afterwards to see how well it executed it.

Lincs_Will I do remember discussion in 2023 when I 1st got my system installed about battery calibration and SOC drift. I wonder how the inverter/BMS handles that with Predbat more or less constantly trying to charge & discharge as I think it needed to be left to realign the SOC.

Its not the best of behaviour to charge then discharge then charge the battery which is what I think you said predbat is doing to get the most out of IOG. The SoC tracking is improved by letting the battery rest for a bit for the voltage to stabilise.
Maybe periodically set predbat to Control charge only, and turn low power charge on so Predbat doesn’t force export the battery and does a slow and low charge in the overnight period. That would help the battery rest-calibrate itself

R
#272 Rbor

browellm Yesterday, I updated HACS and Octopus which both went fine.

I also tried to update HA and, as is often the case for me, I had problems, one that I hadn't seen before.
When HA come back on stream, I no dashboards would load on my iMac. Everything else worked fine. I tried restarting HA but no luck.
I then tried a different browser and dashboards worked. They also worked using the same browser on a laptop. Dashboards also worked on the iOS app on iPhone and iPad. Predbat, running on my pi4 was still working just fine
I then copied the URL for HA/dashboards from my laptop to my iMac and this worked! It is as if the URL got corrupted.
......... the saga continues .....my history wouldn't load. Left it 30 mins but just a sign telling me that history was being loaded.
I then restored back to previous version of HA (12.5) and history worked.

I hate HA updates and I will delay another attempted update until later versions.

Rob

W
#273 Wavy Davy

Regarding the updates, I don't know if it's coincidence but after the upgrades yesterday, I had 2 hours of free lecky today from 14:00 to 16:00. Predbat saw that and planned for charging during the full 2 hours. However after 1 hour and at about 56%, although it said it was charging it wasn't. I waited for about 7 or 8 minuits no change. Plan said to charge, predbat status said charging but not charging. I set a forced charge until 16:00 and it charged immediately and charged upto 91% without problems.

Z
#274 Zaz

Rbor After most updates all the history-graphs show messages but dont load the graphs. Like you other browsers work but I have to press ctrl-F5 on Chrome to force a refresh ignoring cached items and that reloads the page with everything working. This is on Windows and I don't know iMac but I presume there is a similar thing you can do to get the cache to be ignored on your browser. It might not help but give it a go next time it plays up.

G
#275 geoffreycoan

Wavy Davy two hour power up for me as well today was nice, but tomorrow’s Agile rates, ugh !

R
#276 Rbor

Zaz Thanks. I will do.
I was using Safari, the standard Mac browser, but I only had the problem on one of my Macs.
I tried refreshing but no luck.
Chrome opened the dashboards fine.

I do wonder whether HA are producing too many updates in the time.
I encountered the same 'history graph' issue when I last updated HA and only got the history charts back by restarting HA again. The time before, I had to restore from a previous version to get HA running properly.

Rob

D
#277 Daveb01

Have updated everything and phew no issues. All the graphs are OK as well.

I have started to use Reboot System instead of Restart Home Assistant.

W
#278 Wavy Davy

Zaz On my MacBook if I do an update, quite often I don't get the predbat plan showing, it shows a error message instead.. If I edit the predbat dashboard (pencil icon), edit the predbat plan, it will show the plan in the preview window. I then press either cancel or ok (doesn't matter which), select done for the dashboard edit and all is well.

G
#279 geoffreycoan

Wavy Davy These definitely sound like browser caching issues. I pretty much exclusively use the iPad companion app and it doesn’t seem to have the same disappearing content issues; mind I never clear the cache when updating either

W
#280 Wavy Davy

geoffreycoan I use the app as well on my MacBook and my android tablet and phone. Does seem to be better recently. not done it for a little while, including yesterday and just now.
The message I got was this.

But it didn't seem to clear by itself.

G
#281 geoffreycoan

Wavy Davy Who knows. A not particularly good error message.

I should say, I use the Companion app on my iPad and iPhone but on my Windows PC (that HA runs as a gesture VM) and my Macbook I just use the Edge or Safari browser respectively with no memorable issues.

But then I also never upgrade to the .1 release, I will wait until 2025.1.3 typically before I upgrade. Let someone else debug it. There always seems to be plenty of. bug fixes in each patch release with unintelligible descriptions of what the bugs fixed. Usually ‘xxx bumped to version nnnn’ which means nothing to me

Bhah

W
#282 Wavy Davy

geoffreycoan it's not particularly a problem, as I said it doesn't seem to have happened for a few updates now, and when it does I just use the edit process to sort it. After a restart It does take a minuit or two to get all the messages to clear and start running, but no biggie.

R
#283 Rbor

I restarted HA and it came back OK but additional sidebar icons, such as energy, HACS, etc were not there.
Then magically after about 10 min, they all reappeared!

Rob

J
#284 Josephiah

geoffreycoan Your consumption through the night looks consistently high, do you not set back the temperature overnight?

From a closer look just now, I was right to suspect that Predbat is doing some double counting when it comes to the load_forecast input. Or perhaps more accurately it does nothing to compensate for the the additional predicted load I am adding in by feeding it with an input here, so the final load predicted ends up being historical prediction PLUS load_forecast. There needs to be some kind of ongoing subtraction in there, but I'd have to think about how (or even if) that would work...

So in short: those readings are significant overestimates of actual usage. I've now turned off my Predbat heat pump load_forecast until I can work out a way to deal with it properly - keep meaning to ask Trevor how it is supposed to work!

Rbor So worth looking at your HP settings.

Thanks. Your setup and setting sound very similar to mine. 12kW Vaillant heating a 5-bed house via 22 rads. After a fair bit tinkering during our first winter, last winter, I'm very happy with the performance - SCOP of 5 over the last year, but more like a COP of 4 in the current conditions, similar to you. Heat curve edged down to 0.4, which improved the efficiency massively compared to the installer's setting of 0.75.

I don't use a setback except for coasting across the Agile peak, where I do 20°C target from 1300-1600, 18°C setback from 1600-1900, then 19°C the rest of the time. With the heat curve set so low, the lengthy recovery times from setback render them almost useless. And I figured that the full extra 1.0 of SCOP gained in my settings optimisation goes a long way towards covering the energy saved from an overnight setback, once the post-setback extra recovery energy is factored in.

R
#286 Rbor

geoffreycoan Thanks.
Not seen this one.

It recommends using the installer app. The setup procedure looks a lot more straightforward than following the tiny screens using GE dongle wifi instructions.

As I have my AC3.0 inverter connected, I am not touching it!
But useful info to know.

Rob

T
#287 TX200

I presume predbat uses relative pricing for the colours of each half hour slot? 99.99 is showing as yellow for me, would usually expect it to be red. 🤣

R
#288 Rbor

Josephiah I like your idea of tweaking temperature during the day.
Looking at your 0.4 heating curve slope, I have tweaked mine down from slope 0.6 and level 2 to 0.5 and level 1 (at least for today – hoping to get a bit of solar gain). This has reduced my flow temp from 35C to 32C. I'm interested to see if my load is reduced (it should be) compared with my predbat predictions.

Rob

G
#289 geoffreycoan

Rbor Earlier in the week I saw a definite drop in power consumption from my heat pump when I dropped the weather compensation curve down by 2 degrees. I was getting power peaks up to 8kW rather than 10kW and there was a corresponding drop in energy consumption.

I had been experimenting with reducing the heat pump setback temperature part way through the night so the heat pump first fired up on the relatively cheaper overnight rates. Concluded that this wasn’t making a material difference to things so changed back to a single 2 degrees setback from 23:30 to 10:30 yesterday.
But I accidentally turned the heat pump thermostat off.

I did wonder why the electrical consumption stopped climbing in the evening, I’d assumed that it was because the house was at temperature 🤦…

The results on house temperature were quite surprising though:

The heat pump was yesterday consuming about 10kW every 3 hours. I accidentally turned it off at 19:00 and other than the lounge (where the wood burner is), the individual room temperatures moved less than 1 degree.
You can see when my wife lit the log burner.

So at the moment this is my nuclear plan. Light the wood burner and turn off the heat pump for the afternoon and peak evening.
This is probably what Octopus are trying to get us to do with Agile, reduce our consumption when grid load is high. I’m just slow to react …

G
#290 geoffreycoan

TX200 I presume predbat uses relative pricing for the colours of each half hour slot? 99.99 is showing as yellow for me, would usually expect it to be red. 🤣

Weird, its all red on mine

The colour coding logic is explained in the oh-so-wonderful documentation https://springfall2008.github.io/batpred/predbat-plan-card/ - I had to reverse engineer the code to work out how it works. Its all down to import rate threshold apparently

R
#291 Rbor

TX200 geoffreycoan
Mines all red as well

Had a slight covering of snow last night covering panels. Although there's some hazy sun, the snow isn't budging. There's a bit of PV generation but not much.

And areas outside that melted yesterday are just sheet ice.
External temperature has just risen to –3C (and that is at 11 am!)
🥶🥶🥶

I had been experimenting with reducing the heat pump setback temperature

I have abandoned my experiment of reducing my heating curve settings. Since 8 am, temperature is creeping down in the house. So I have cracked and have moved slope and level back to where they were.

I need some exercise to get warm so off out to shovel some more snow. Temperature forecast to rise over weekend and into next week ..... 😎
But –7C forecast overnight 🥶

Rob

G
#292 geoffreycoan

DFS saving session today https://community.givenergy.cloud/d/5364-dfs-sessions/22

I thought there might be, looked, there wasn’t one announced, and now there is, 5-6pm with 99.99p Agile slots either side.

The session is not appearing in event.octopus_energy_ACCOUNTID_octoplus_saving_session_events either as an available or a joined event so Predbat isn’t scheduling it. It might appear or might be back to using my manual API override script again to program it in.

I turned the weather compensation down another 2 degrees so now its -4 off the curve. The house temperature is slowly rising through. Not warm but not awful either. Think I will still turn the heat pump off to ride the peak

T
#293 TX200

Rbor mines red now, lol 🤣

B
#294 browellm

The good thing is being able to do a rates_export_override and let Predbat do the heavy lifting of working out whether it's worth importing from the grid to my flat battery to export later on. Predbat says no.

R
#295 Rbor

TX200 mines red now, lol 🤣

Good news,
You shouldn't feel out of things now.

Rob

R
#296 Rbor

I got the email from Octopus at about 13:40.
Yes, I dropped in a rates_export_override with 65 as the override into apps.yaml and predbat has come back to me with this:

Looks like my battery will just maintain some juice before 20:30 when the main peak subsides. I will still turn heat pump off during the hour. I have also tweaked my heating curve down again in preparation.

I certainly was asking myself why there was no saving session today as media is going on about possible blackouts.

G
#297 Goshiki2

Rbor Am I being thick ? I can’t find this entity “rates_export_override” at all.
Edit: found it in apps.yaml 🙄

R
#298 Rodmac76

Goshiki2 I think I am am being thick I cannot see the Export override I can see the import. Any pointers what line it should be on please

G
#300 geoffreycoan

Rbor I did mine via the predbat_manual_api via the screen and script I shared for the last DFS session.

I used a rate increment of 72p as I don’t normally export anything in the peak and the Octopus FAQ’s confirm we still get the normal export amount. You might want to set a load_scaling factor as well if you are turning the heat pump off for the DFS hour.

Its actually OK with the heat pump off since lunchtime. Its a bit not-hot in the kitchen but the lounge, hall and upstairs are warm enough from the morning heating and the . Earlier this afternoon the batteries were full and I was actually exporting a bit !
Predbat is planning a 1 hour export for a £4.21 export payment across the two slots. Woo!

G
#301 Goshiki2

I’ve got a strange situation now. All my dashboard cards relating to Predbat apparently do not exist on my iPad. They are all visible and active on my iPhone.
I’ve restarted Predbata number of times but the iPad is not recovering but the phone is absolutely fine. Any help would be appreciated.

J
#302 Josephiah

Anyone else not got tomorrow's Agile prices through yet? All of my various apps are just empty after 11pm...

C
#303 c2ushe2

Josephiah Nothing yet. But nothing on the Octopus app, either.

D
#304 Daveb01

Rbor

Hi Rob, I did not need to charge my battery or use extra electric so did not change the import override this time.

This is my default on yaml. Yours is a little different and you set yours to 65. Can you let me know why you chaged it to 65 please?

When I change the date and time, the rate in the plan goes to zero and charges the battery. So was wondering why you set 65?

#305 Jase1703

Still no agile rates here East Midlands. Must be a complicated balancing mechanism tomorrow, Elexon shows reasonable wind resources.

W
#306 Wavy Davy

Nothing in the south. Says :we normally get them around 16:00, any time now." Think their clocks have stopped...

R
#307 Rbor

geoffreycoan I have checked on Github Code/Templates. Line 378 onwards:
https://github.com/springfall2008/batpred/blob/main/templates/givenergy_givtcp.yaml

rates_export_override isn't shown as an example.
There are introductory comments introducing rates_import_override and rates_export_override but only an import example is shown.

Should a corresponding example for rates_export_override be added to the template?
And of course there are templates for other inverters.

Rob

R
#308 Rbor

Wavy Davy There are only 7 slots left before we run out of official Agile rates. The deadline is 23:00.

It sounds as if NESO were in a real panic today, trying to ensure that there was enough electricity in the system. They were paying ridiculous amounts to get gas power stations switched on.
We lost access to two interconnects as well from France and Netherlands. It looks like France is back up but Netherlands link is on a big fat 0 GW.

Rob


T
#309 TX200

What time does predbat stop checking? 🤣

R
#310 Rbor

Daveb01 Octopus were paying 72p/kWh
72 is a bit less to take into account small amount that my battery might discharge to house.
The Octopus range shown on my plan was 80.00 ± (73.73).

I think that the rate increment has to be positive from export override but negative for import override. But happy to be corrected here.

I have re-read the section in documentation and I am unsure that I really understand rate_increment!
https://springfall2008.github.io/batpred/energy-rates/#manually-over-riding-energy-rates

Rob

T
#311 TX200

Rbor I ended up putting mine in as a 62p increment. Similar, accounting for some usual export.

And yes, it was positive on mine and the maths looked right on the predbat plan.

T
#312 TX200

Rbor prices are live now and have appeared in my predbat plan.

Not the cheapest overnight, but still better than my old intelligent flux off peak rate.

G
#313 geoffreycoan

TX200 thanks, just got my rates in Predbat as well. That’s the latest I think I’ve ever seen them arrive.

My ‘turn the heat pump’ off strategy worked. Not convinced everyone else in the house liked it, but its 15 minutes to the rates getting to a more normal 29p and I’ve still got 1 kWh in one battery, and that’s after exporting 4.7kWh in the DFS sesssion (£3.38 on top of the normal 70p export payment). House temperatures are on 16, 17 degrees and 21.7 in the lounge (wood burner).

There seems to be different opinions of setting the export rate override. There’s two options when specifying the rate to use for the override, either:

  • rate which is the replacement rate to use, or
  • rate_increment which is a delta to add to the rate, can be positive or negative

And setting load_scaling is useful if you expect to change your home consumption during the override period, e.g. 0.1 to indicate you’ll only use 10% of normal.

You get paid the standard export rate plus the 72p DFS supplement so to my mind you either set rate to 87 (72+15) or set rate_increment to 72 which is what I did.

Where this breaks down is that DFS is paid on the extra you export or the less you import. No ealy way to specify that in Predbat. So if you normally export then some of the export won’t get the 72p premium and perhaps then you specify a lower value. If like me you don’t export in the peak then you’ll get the full 72+15.

In terms of the givtcp template not including a rates_export_override Rbor I am trying to reduce the amount of info in the sample apps.yaml and put it in the main documentation. In some cases the apps.yaml explanation was the only source of describing how something worked, and that was by its nature limited in detail, plus as you say it becomes a pain to keep up to date for all the different inverter templates and frequently doesn’t happen.
And of course people never look at the latest apps.yaml template, changes made there get missed.

I much prefer to have more in the documentation and to point people there. I have a plan to restructure the templates and change the way they are maintained which should improve this, but down the road right now.

Daveb01 I think you are getting confused between import_override (reducing what you pay for import, e.g. a free electricity event) and export_override (increasing what you pay for export, e.g. a DFS saving session).

You really don’t want an import rate of 0 for today at all as it will start charging as you found out!

R
#314 Rbor

Goshiki2 I had a similar experience after trying to update to HA 2025.1.
My iMac couldn't open any dashboards but everything else was fine.
My MacBook worked fine, as did companion apps for iPad and iPhone (and the iMac!)
This was using Safari. I tried Chrome on iMac and it worked!

I restored HA back to previous version but no luck.
Eventually, I copied the URL from dashboards on my MacBook and copied this into the iMac.
That worked.
You could try that.

Someone suggested that I clear the cache.
There is a wealth of hints following a Google search on clearing cache on iPad.

Hope this helps.

Rob

G
#315 Goshiki2

Rbor Thanks Rob. After I had restarted everything for the umpteenth time I started digging around more. When I went in to integrations there was an error in HACS and when I clicked on ‘configure’ it told me there was an update available. I did the update, restarted HA and everything is back to normal. I just can’t get my head around why my phone dashboards were unaffected.

D
#316 Daveb01

geoffreycoan

Hi yah, I set up the Voltage card in HA you sent me and had a look to see if the same could be done for Temprature. I thought what you would do, copy the voltage card yaml and create a new card. It then only needed the word voltage changed to temprature.

Note:- there are only 12 temp sensors compared to 24 voltage.

I will do all the others now I know it worked and very easy to set up.

G
#317 geoffreycoan

Daveb01 👌

That’s a crazy amount of cell temperature monitors in the AIO, I only have 4 in each of my batteries.

Mind, I think the 3 phase batteries have 16. Lots of data

Labels are worth getting into (system/areas labels and zones):

Or you can create labels directly from the entity list. You can attach labels to entities and then selecting the label is an easy way to select a number of entities, e.g. in the history graph or logbook

I use these often for adhoc looks at things as well as pre-built dashboards

H
#318 Henry3rd

Could anyone shed any light on why my solar forecast for tomorrow shows the wrong value in the heading? I have looked, but can't see anything unremarkable in the code.

G
#319 geoffreycoan

Henry3rd I think Apex does weird things sometimes. I had a period a week or so ago where some of the heading values came up N/A but some worked. It only cleared when I did a HA update

On that chart BTW I have the following config:

apex_config:
  chart:
    height: 300px
  legend:
    show: false
  xaxis:
    labels:
      format: ddd, dd

So I see day of week rather than just date and legend show: false turns off the useless stuff at the bottom of the chart

H
#320 Henry3rd

geoffreycoan Thanks, I have added your tweaks, and it looks neater.
I shall see what happens when I next update HA.
It's not a big deal, but I am slightly obsessive when something isn't quite right.

R
#321 Rbor

And thanks from me. Really tidies up the chart, removing all the guff.

Rob

J
#322 Josephiah

@geoffreycoan do you know if Predbat had started actively throttling charge rates as part of its plans?
Today of all days woke up to a half-full battery, and found that Predbat 8.10.1 had set the charge rate to 760W:

Switching back to v8.9.3 yields this rather more sensible plan, charging as close to full rate as GE's new temperature profiling will allow. This change happens consistently when I flip between these versions.

Looking at the inverter portal, it is clearly Predbat making these changes.
Actually, let me rephrase my initial question: I know it's doing it - do you know if it's intentional?!

Edit: argh, images not loading, which I can't stop to fix now! First image should show plan taking several hours to get to 100%; second is much more normal looking.

H
#323 Henry3rd

geoffreycoan And just like magic, all is well again.

D
#324 Daveb01

@geoffreycoan

Hi yah, a quick question please on battery temp now I have the graphs. You mentioned Low power mode.

Do you turn this on say for 3 months jan - mar, or do you keep an eye on things and turn it on and off when it indicates it is going to be say below 5 deg outside?

R
#325 Rbor

A snapshot of temperature since start of Thursday 800' up in Yorkshire.

... and how solar OV should come to my rescue during daylight hours:

Rob

R
#326 Rbor

Josephiah Predbat adjusts its plan as more evidence comes in. I think that @geoffreycoan has said that 4 hours before is likely to be the best prediction.

You may have raised this previously but your PV is almost non-existent. Compare with the projected PV in my plan that I have just posted above. It is only 09:25 and I am already getting 1.5 kWh of solar today which is protecting me. You are pulling from the grid to cover your load all the time, pushing up your costs with current rates.

Rob

H
#327 Henry3rd

Rbor My Predbat is throttling the charge to the battery (frzexp).
But the battery is still expected to reach 100%, the slow charge will be helping battery temperatures. But as you say the lack solar seems to be the issue for @Josephiah

R
#328 Rbor

Henry3rd Predbat has tweaked my plan now I am getting the same now with some freeze exporting, same as you.

Rob

G
#329 geoffreycoan

Josephiah I know it's doing it - do you know if it's intentional?!

Have you got ‘set low power charge’ turned on?

I have and I noticed that my plan was similar, charging through the night and into this morning at a low rate. This is better for the batteries than a full rate charge and then idle, and helps keep the temperatures more consistent if its charging all the time rather than sprinting with a full rate charge and then going cold afterwards.

This to me is all deliberate, why its different in an older predbat version I don’t know.

J
#330 Josephiah

Rbor
Henry3rd
Thanks, but I think we may be talking at cross-purposes here. At this point in the year we have high usage (heat pump) and minimal solar, as you say - but this isn't the issue I'm describing.

Expected behaviour (as it has always done, and does under v8.9.x):
charge battery fully at full rate 3.6kW (or a bit lower when colder under GE's new charging profile - at the temps in our garage (12-15°C), this tends to be 2.7kW until it gets over 20°C, then 3.6kW. Fast, anyway!) on the cheaper slots overnight.

Behaviour under v8.10.x:
Predbat has artificially set the charge rate to 760W (and systematically re-applies this if I change it back in the inverter portal), so battery is only partially charged in the morning.
I was curious whether @geoffreycoan had any insight on whether this is intended behaviour? (Edit - ah, sorry, just seen your response, which hadn't refreshed for some reason - will check out the setting you suggest - thanks)
In the meantime, I've reverted to v8.9.3, and will raise an issue with Trefor later.
Thanks all!

J
#331 Josephiah

geoffreycoan
Ah, thank you, this seems to be it - wasn't aware of this setting before.

Totally on board with that in principle for the reasons you mention, but in this particular case it seemed to be throttling very aggressively - particularly noticeable on a day with 9x 99.99p slots! Do you know if there's a way to control how aggressively it throttles the charge rate, or choose the circumstances under which it does so?
(I guess the latter might be fairly readily automate-able by just toggling that setting...)

L
#332 Leeshore

geoffreycoan In 'Words of Caution' in the manual it does suggest:

"Given different inverter designs may have different limits it is a wise precaution to avoid your plan being too busy if it doesn't gain you very much. Things you can do to have a less complex plan include:

Keep calculate export during charge off
Set metric battery cycle to a small non-zero value e.g. 0.5
Ensure inverter losses are set to a representative value
Turn off charge_low_power mode"

What are your thoughts Geoffrey?

G
#333 geoffreycoan

Josephiah No to my knowledge there isn’t any further configurability to this.

I was worried about this myself last night but looking at what actually happened, most of the low rate charging was before 7am when the import rate was 20p or less. The batteries were at 80% at that time so comparatively little was charged at the increasing rates this morning (and from 90% SoC the battery charge rate steps down anyway)

You can simply turn it off of course, and I do that when I have a power up or free electricity event, that’s what I do to ensure that I charge at full rate

G
#334 geoffreycoan

Leeshore Things you can do to have a less complex plan include:

Keep calculate export during charge off
Set metric battery cycle to a small non-zero value e.g. 0.5
Ensure inverter losses are set to a representative value
Turn off charge_low_power mode"

Sensible advice from Trefor. There is no single right answer for everyone, and got to balance inverter writes and the theoretical risk from those vs getting value out of the expensive boxes you have bought. Having them idle does nothing for you.

Of that list, I have:

  • calculate export within charge slots off, this means you have much less charge and discharge in the same 1/2 hour period when Agile rates are less than your import rate
  • metric battery cycle set to 0, I don’t like this as an artificial “cost” on using the battery, I bought it and want to use it, but I do have metric min improvement export set to 4 so I only export if profit over the slot is > 4p
  • inverter losses, I try to get those correct
  • charge low power mode on because of the advantages this brings to keeping the battery warm overnight

Also I’d add to not turn Predbat’s inverter balancing on if you have multiple inverters

Personal choices

D
#335 Daveb01

geoffreycoan

I have just checked my settings and they are the same except for low power mode, I am going to give it a go, not sure how the AIO’s will think about it.

Do you leave it in low power mode say Jan-March or do you switch it on only if it goes below a certain temperature?

Also does this setting get affected with the yaml power curve setting?

(I saw your note about turning it off for power ups etc)

D
#336 Daveb01

I have just thought of another random question, Predbat does not always charge the battery up to 100% when there is plenty of Solar, I understand the money side of things and it’s better to export.

Could you ask Trevor if he is thinking about a switch we can turn on/off to prioritise this over money? Especially if there are grid issues or the rates are very high later, I personally would like a full battery for free from solar rather that the cash?

G
#337 geoffreycoan

Daveb01 Do you leave it in low power mode say Jan-March or do you switch it on only if it goes below a certain temperature?

Also does this setting get affected with the yaml power curve setting?

I personally haven’t given it any specific handling for time of year or temperature. I leave it turned on all the time so Predbat will charge at the slowest rate it can in the charge time period to still achieve batteries at the desired target % by the end. Slow charges are generally better any time of year so I leave it on regardless. YMMV

Yes the power charge curve is then a further overlay if the battery slows down beyond 90% charged. Predbat should include this when working out what the low power charge rate is

Not sure I follow your logic on a potential extra switch, but feel free to add it as a github feature request. I would say though that in general Trefor is trying to avoid adding continually more settings and options as it gets confusing for users and as much as possible its better to let Predbat do things automatically.

L
#338 Leeshore

Daveb01 I’m the same. I’ll try low power mode as it seems sensible to try it

J
#339 Josephiah

Leeshore let us know how you get on - I'll be interested to see if it throttles it as much as mine!

geoffreycoan No to my knowledge there isn’t any further configurability to this.

Interestingly, this entity "low power mode margin" popped up in my controls list, albeit disabled. A future feature that's being worked on, perhaps...? Having this functionality, but with a little more control, would be great.

Currently, I'm not getting any obvious consistency with it - setting it now doesn't seem to be making any noticeable difference - it's just the typical 6-7 slots to get to full charge - which is why this morning's antics were such a surprise.

J
#341 Josephiah

geoffreycoan thanks. As far as I can see, that one is just a kind of safety margin (settable between 0-30mins only) to make sure the final slot actually gets you to full charge, so I'm not sure it helps particularly. I've raised a ticket (not quite sure if it's a bug report or feature request!) regarding the unpredictability of it.

It would be nice if there was a little more control over it, such as being and to set a minimum charge rate, or to manually set a target time it needs to be at 100% for. I wonder if it was the auto-calculation of the target time that was thrown by today's exceptional/weird Agile pricing profile...?

G
#342 geoffreycoan

Josephiah thanks, I saw your ticket and have added some comments to it on my own experience from last night.

D
#343 Daveb01

Got my Topdon thermal camera out today (Christmas present)

B
#344 Boffinboy

Bit the bullet and made the switch to Cosy. Going to give it a go and use the electric heating more extensively for a bit! Hoping Predbat picks it all up smoothly. No doubt sods law means Agile will suddenly become amazing rate wise now, so you’re all welcome if that’s the case 😂

B
#345 Boffinboy

Daveb01 very nice! I’ve thought about getting one, but there is a place here that loans them for free so going to give that a try. Unfortunately it will show all the slot vents that builder stupidly put through the frames of our triple glazed windows 🤦‍♂️

G
#346 geoffreycoan

Boffinboy I did sign up last winter to get a loan thermal camera from Octopus, and they contacted me to say I could borrow one. I had bought a Kaiweets KTI-W01 for £161 which I thought was a good price and works well

They have code return10 for 10% off but I think I got 1/3 off so may be able to find better offer codes than this.

R
#347 Rbor

Great. What is the blue lump in lower right of image at –3.6C?
I have one of those thermal cameras that slots onto phone but has never worked very well. Battery would last for a few minutes and connection was iffy.

So I've spent a bit of time reading reviews on thermal cameras and watching some videos.
I cracked and have ordered a topdon from amazon, arriving tomorrow!
Costly but came with a £40 off voucher. I got the last one!

Hope it's OK. If not, I can always blame @Daveb01 😆

Rob

D
#348 Daveb01

Rbor

That’s the Chest freezer in the garage.

I got this model as I have an iPhone and needed the new USB-C connection. Previously they only did them for Android.

TC002C-for iPhone 15 Series and iPads Onwards.

I don’t think HA and Predbat cater for thermal cameras so sorry for the post😀🎄

Also I think I need to fiddle with the settings as it is not -3.6c in the garage 😀👍

#349 PianSom

I’m having a recurring issue with Predbat. When I have excess charge (like I do today, as I am away) then it decides to export at 7.30pm. But it exports too much, and then I have to import (small, but annoying) before the cheap rate starts at 11.30pm

Anyone got any suggestions?

D
#350 Daveb01

PianSom

Just had a look at mine and it’s not right. I don’t know what to suggest at the moment.

Holding the charge for so long plus planning a charge when the battery is already full. I know in 30 mins it might change again. I will check the logs especially GivTCP.

G
#351 geoffreycoan

PianSom I’m having a recurring issue with Predbat. When I have excess charge (like I do today, as I am away) then it decides to export at 7.30pm. But it exports too much, and then I have to import (small, but annoying) before the cheap rate starts at 11.30pm

Anyone got any suggestions?

it sounds like your calibration/configuration of what the inverter delivers could be wrong.

Predbat will assume that if your inverter does a full rate discharge then it will exactly discharge at that rate.
e.g. my inverter reports a max discharge of 2600W but actually discharges at 2734W (or something like that).

I set 'input_number.predbat_battery_rate_max_scaling_discharge’ to 1.04 so predbat knows about the difference.
And there is a similar scale factor for charging.

Might want to add a bit to best_soc_keep to keep something in reserve and increase best_soc_keep_weighting to give more importance to keeping this.

Assume you have calculate in day adjustment on to adjust the load forecast based on what is happening today?

Daveb01 Just had a look at mine and it’s not right. I don’t know what to suggest at the moment.

Holding the charge for so long plus planning a charge when the battery is already full. I know in 30 mins it might change again. I will check the logs especially GivTCP.

I don’t see anything especially wrong with the plan. The rates are relatively flat so no advantage to charge the battery and equally no advantage to discharge the battery to the home - both will incur inverter conversion losses.
Instead running off grid import will be cheapest and preserve the SoC for later higher periods like at 00:30 when the import rate increases and Predbat starts discharging.

The charging when already full, for a start its most of a day away so things will change, but its much the same, rates are flat so holding the battery full. Charging when 100% SoC is same as freeze charging

#352 PianSom

geoffreycoan it sounds like your calibration/configuration of what the inverter delivers could be wrong.

Thanks Geoffrey - it seems to be exactly that. My AIO 6kW inverter seems to be discharging at 6.35kW.

I will make the necessary adjustments

However, I’d also prefer it if Predbat would delay the discharge until later, in case of unexpected load. I wonder why it decides on 7.30pm?

G
#353 geoffreycoan

PianSom However, I’d also prefer it if Predbat would delay the discharge until later, in case of unexpected load. I wonder why it decides on 7.30pm?

Have you got switch.calculate_export_high_import (expert_mode) turned on https://springfall2008.github.io/batpred/customisation/#calculation-options ?

This should give what you want in terms of delaying the export to as late as possible

In between feeling awful with a cold, almost lost my voice, I am back on updating the documentation again. Lucky me. Added the stuff about utility meter and dashboard for inverter writes, continuing adding the list of tweaks I have accumulated from here and from github issues.
I do need to do something about the whole ‘saving space in the database’ topic but maybe not in this PR

Oh and BTW I am on the latest 8.10.2 Predbat, and was on 8.10.1 until the new release came out. No adverse issues with any of these that I’ve seen

D
#354 Daveb01

geoffreycoan

Thank you again for the reassurance. The only thing I have changed was to select low power mode.

This is what is says this morning, not sure why it says planned charge for so long

G
#355 geoffreycoan

Daveb01 This is what is says this morning, not sure why it says planned charge for so long

Much the same as last night, your forecast solar generation will more or less cover your forecast house load, and there isn’t much variation in rates so again no material benefit to charge or discharge the battery - bearing in mind the 3p or so conversion losses.

If you tweak the input_number.predbat_metric min improvement figures down it might do a bit more, but your plan is pennies across the morning. Get a heat pump and you won’t have this problem, 9am and mine is reporting 22kWh of heat pump consumption overnight already.

My own plan shows not a lot happening, battery in freeze charge for most of the slots, a demand at 10 (but its almost empty anyway), and then start charging at 11:30 when I have a power up event.

Do you have switch.predbat_set_charge_freeze turned on? If not this might be why you are seeing charges at 100% when I see charge freezes

D
#356 Daveb01

geoffreycoan

Thank you again. Yes set charge freeze is on. I will just leave Mr Bat to get on with it as you say.

I hope you feel better soon, and a big thank you for replying to post when you felt crap. I had it over Christmas so was a bit Grinch (so the other half said) 😎

R
#357 Rbor

Daveb01 geoffreycoan For comparison, this is my plan pre-4 pm today.

Compare loads showing contrast with my HP. Not as high as @geoffreycoan – up to 9.10 kWh so far today, but certainly affects costs against no HP (but no gas costs). Not much cost to add though now as I will be emptying battery in the evening. Night is main opportunity to fill battery.

Looks like solar north is predicted to outshine solar south this morning 😎 with PV covering most of my load. And the temperature has risen to –0.5C (up from –6C previous night).

Have you got switch.calculate_export_high_import (expert_mode) turned on

This wasn't aimed at me but mine is switched on.

If you tweak the input_number.predbat_metric min improvement figures down

Mine is on 0, same as default.

Oh and BTW I am on the latest 8.10.2 Predbat, and was on 8.10.1 until the new release came out. No adverse issues with any of these that I’ve seen

Same here. I don't understand what the tweaks are doing or what is in Trefor's mind but no issues with any of recent predbat updates for me anyway.

PS. Other recents: I have:
set charge low power mode OFF and
calculate export slots within charge ON
set charge freeze ON,
Mostly all defaults. My plans are looking good.

Rob

G
#358 geoffreycoan

Daveb01 I hope you feel better soon, and a big thank you for replying to post when you felt crap. I had it over Christmas so was a bit Grinch (so the other half said) 😎

It started last Saturday, I felt better on Tuesday, and now its come back again even worse with a 90-a-day voice to match. Bhah. Just not doing much.

Rbor Compare loads showing contrast with my HP. Not as high as @geoffreycoan – up to 9.10 kWh so far today, but certainly affects costs against no HP (but no gas costs).

As we’ve discussed before your heat geek designed ASHP pays dividends and is cheaper to run than mine. I’ve said before I am convinced mine is over-sized and by connecting into the 15mm radiator run rather than the core 28/22 the flow rate isn’t as good as it could be either.
Anyway it is what it is, in all bar really cold days it costs less than £10 a day to run so paying to get more radiators changed or the pipework altered would be a false economy. Does mean my consumption remains stubbornly high.

Here’s the Apex chart I shared before to look at long term temp vs consumption:

      - type: custom:apexcharts-card
        apex_config:
          chart:
            height: 400px
        span:
          offset: '-1day'
        graph_span: 30d
        series:
          - entity: sensor.ashp_energy_today
            name: ASHP
            type: column
            offset: +1d
            statistics:
              period: day
              type: state
              align: end
            show:
              datalabels: true
              offset_in_name: false
          - entity: sensor.grid_import_today
            name: Grid import
            type: column
            offset: +1d
            statistics:
              period: day
              type: state
              align: end
            show:
              datalabels: true
              offset_in_name: false
          - entity: sensor.porch_temperature
            type: line
            stroke_width: 2
            offset: +1d
            group_by:
              duration: 1d
            statistics:
              period: day
              type: mean
              align: end
            show:
              datalabels: true
              offset_in_name: false

In this cold snap I have turned the weather compensation curve 5 degrees down, is resulting in the house being held at a lower temperature for less electricity consumption. Looks like the forecast is for milder weather coming in the next day or so.

One of the things I find annoying is the lack of heat pump info I have which makes optimising the setup hard - the ASHP control boxes are in the loft so its a pain to go up and change the weather curve or see what the flow temperatures are. I’ve bought some cable to relocate the control boxes downstairs and a couple of DS18B20 temperature probes so that I can get flow temp and HW tank temps into Home Assistant. But not going to be doing those until I feel better….

#359 PianSom

geoffreycoan Have you got switch.calculate_export_high_import (expert_mode) turned on

Sadly, yes I have it on. But still get the early discharge. 🙁

Get well soon!

D
#360 Daveb01

So had (low power mode pn for quite a while to see what it did and how 2 x AIO’s would react. It looks like it Mr Bat was wanting to charge for a lot of 30 mins slots (see above)

It had just planed another 10 slots later in the day. I have decided to turn it off and it’s all gone back to normal.

So my advice at the moment if you have an AIO don’t put on low power mode 🙁

#361 PianSom

geoffreycoan I set 'input_number.predbat_battery_rate_max_scaling_discharge’ to 1.04 so predbat knows about the difference.
And there is a similar scale factor for charging.

Hmm, I had input_number.predbat_battery_rate_max_scaling_discharge set to 0.85, which given that the actual value should it appears be 1.055 explains my. issue.

At some point I set it to 0.85 as I thought this was the input_number used by Predbat to override the GivTCP stated battery size (15.96kWh) to the stated size (13.5kWh). On reading the docs now it is clear that I should be using battery_scaling - which I already am. How odd that I have had the same mistake for so long!

R
#362 Rbor

geoffreycoan I hope you recover quickly from whatever you have caught.
I guess that the microlight that came over my house yesterday wasn't you on a northern foray!

Rob

R
#363 Rbor

geoffreycoan Nice Apex chart.

As we’ve discussed before your heat geek designed ASHP pays dividends and is cheaper to run than mine. I’ve said before I am convinced mine is over-sized and by connecting into the 15mm radiator run rather than the core 28/22 the flow rate isn’t as good as it could be either.

My HP installer split off from the initial core 28/22 after plumbing into water cylinder and only when the 15mm radiator runs split around the house. I don't have a buffer. I have heard that many installers deliberately oversize and use a buffer so that they can't be accused of installing an inadequately sized HP by the owner. 'Less potential hassle' for the installer but less efficiently for the user. I think that Octopus install heat pumps 2 kW greater than the calculated heat loss.

One of the things I find annoying is the lack of heat pump info I have which makes optimising the setup hard

My HP is a Viessmann. The app is adequate but doesn't give info on flow rate, flow and return temperatures. I can get this info from the Viessmann display unit but that is a pain.
However, Viessmann do have a HA integration which provides all this info.
I also have the OpenEnergyMonitor kit which provides all this info and more.
OpenEnergyMonitoring also have a HA integration which provides better info that the Viessmann app.
So I am spoilt for choice here. The OEM kit is expensive although mine wasn't!

Which make is your ASHP?
I have looked on HA and there seem to be few HP manufacturers with integrations. I was surprised that Vaillant, the commonest, is absent.

I am at least above freezing now. There was an almighty thud outside late yesterday evening as the snow finally slid off my last 3 snow-covered panels so PV generation should now finally be back to normal.
Good solar PV over recent days has pushed up my Jan generation and has helped to provide energy for the heat pump. I have even exported 3 kWh of excess PV today!

Defrost cycles are a drawback of a HP in low temperatures. They use up energy and space heating for the house stops until the defrost cycle is complete.

Rob

R
#364 Rbor

PianSom With so many settings, it is not surprising that we lose track of changes that we have made or the reason why we made the changes. It is great to have Geoffrey's excellent documentation to refer back to and knowing that Trefor is striving to look after us all with his incessant improvements to predbat.

I regularly go to the WebUI config page, check what the defaults should be, and the entities/switches that are not defaults.

Things are looking up for us all. We have gained nearly 30 min of daylight since the shortest day and the sun is creeping higher in the sky. So our PV generation should steadily increase.

Rob


G
#366 geoffreycoan

PianSom it is not well worded, and having a look at the code and improving the description is on my list. I had missed the last sentence “by default with this option disabled …”, so yes, does sound like disabling it would give you what you want, even though it is NOT the default.

New Predbat 8.11.0 out today incorporating battery temperature charge curve, i.e. varying the charge curve based on the cell temperature. A brilliant addition from Trefor

#367 PianSom

geoffreycoan does sound like disabling it would give you what you want, even though it is NOT the default.

You'd think, wouldn't you?

Yet here we are, a few hours after turning the switch to off and ... nope. Maybe it will resolve as we get closer.

#368 PianSom

geoffreycoan New Predbat 8.11.0 out today incorporating battery temperature charge curve, i.e. varying the charge curve based on the cell temperature. A brilliant addition from Trefor

Tried updating. Didn't change anything (as I am an AIO user so am less sensitive to battery temperature issues). Predbat fail with repeating errors of "Error: argument of type 'float' is not iterable" type. Reverted to previous version.

Just me?

A
#369 arczi19

PianSom Worked fine for me, although I cant say I fully understand how this battery temperature charge curve works (I havent noticed any difference on the plan on my 9.5kWh battery after adding the config lines).

R
#370 Rbor

PianSom Worked fine for me also.
As my batteries are cosy inside, I have just upgraded.
I presume that I would copy the code into my apps.yaml but it doesn't seem relevant to my setup.
I may add the code to my apps.yaml but would then comment everything out!

Rob

G
#371 Goshiki2

PianSom Just updated mine (running AIO). No problems but I’m not bothering with adding anything to apps.yaml as it doesn’t seem to be affected by temperature.

L
#372 Leeshore

I’ve updated with no issues. My battery in garage so battery temperature does go down to 10C sometimes. Grateful to let Trefor do his stuff. May need to use old duvet

G
#373 geoffreycoan

I haven’t upgraded yet, but from a quick read of the changes https://github.com/springfall2008/batpred/compare/v8.10.2...v8.11.0 , there is:

  • new temperature sensor and battery temperature charge (and discharge) curve configs to add to apps.yaml
  • a new predbat.battery_temperature entity that I am pretty confident will need excluding from the recorder in configuration.yaml
  • a new Apex chart of battery temperature against predicted temperature

Whether you need to configure the temperature curve and what your configuration will be depends on your firmware and battery type. I don’t believe the AIO’s suffer from temperature related battery charging curves, its only the older so called ‘low voltage’ 2.6, 5.2, 5.12, 8.2 and 9.5 batteries
And its something that newer BMS’s 3017 include, so if old firmware such as Gen 1 450/451 then there is no slow down

I do see temperature related battery charge slowdown so for me this will be useful once I work out the config, e.g.:

The 9.5 charges at 2.4kWh even with lower temperatures, but the 5.2 charges at 1.7kWh (blue arrows) until the cell temperature gets above 20 degrees (red arrows) when it too charges at 2.4

#374 PianSom

geoffreycoan I don’t believe the AIO’s suffer from temperature related battery charging curves, its only the older so called ‘low voltage’ 2.6, 5.2, 5.12, 8.2 and 9.5 batteries

It's perhaps worth noting for other AIO users that there is a recent new setting available on the Inverter tab on the portal:

A note on the beta forum reminds us that at the end of the 10 min period Forced Charging is turned off again and so any other forced charging slots will not be actioned.

H
#375 Henry3rd

geoffreycoan Is there any thought that I should use the givtcp_dxetc_battery_temperature sensor or one of the sensor for one of the cell temperatures which seem much stabler?

H
#377 Henry3rd

Henry3rd Option 2

G
#378 geoffreycoan

Henry3rd For this to work you need to use a battery cell temperature. What’s referred to as ‘battery temperature’ is actually the Battery Management System (BMS) Motherboard which gets hot and cold much more quickly with use than the individual cell temperatures

In GivTCP V3 the temperature names have changed and there is a new sensor introduced, but it appears (and I, Trefor and others believe) that the sensor names for BMS and battery cell average have been swapped round https://github.com/britkat1980/giv_tcp/issues/329

So, givtcp v2 use any of the cell_temperatures, for v3 you can also use the cell temperatures or bms_battery_stack_temperature which despite the name we are confident is a cell temperature average

L
#379 Leeshore

geoffreycoan a new predbat.battery_temperature entity that I am pretty confident will need excluding from the recorder in configuration.yaml

I excluded it and the plan just discharged the battery. After removing it from recorder exclusions the plan restored to normal. I have added it to an automation to purge after 1 day....

G
#380 geoffreycoan

Predbat struggling to come up with the optimal plan for me tomorrow morning, planning a slow rate charge from 01:30 to 10:30 despite the rates increasing in the morning peak

Turning low power charge mode off doesn’t fix it, but putting a force demand in at 07:30 seems to ‘break’ the charge activity and then Predbat does more what I’d expect it to do

Added this to an existing ticket about issues with low power charge https://github.com/springfall2008/batpred/issues/1866

R
#381 Rbor

I can't believe that our plans are so different.

This is mine:

I got 10.1 kWh of solar today which helped. Over the last few days, Solcast has predicted way down on my actual (today Solcast predicted just 5 kWh against my actual of 10 kWh).

I am running v8.11.0. I haven't put any of the battery temperature lines into my apps.yaml as my batteries and inverter are above 20C all of the time
Low power mode is OFF (I have never turned it on).
Most of my settings are defaults. Any tweaks are minor.
I do have switch.predbat_calculate_export_oncharge set to true.
I think we have similar inverter and battery setups apart from you have 2 inverters, each serving a battery. I have one AC3 inverter serving 2 daisy chained batteries.

But why are our plans are so different?

Rob

G
#382 geoffreycoan

Rbor they are quite different Rob

The differences probably due to:

  • your slightly higher battery capacity, 16.4 vs 13.7 of mine
  • my higher daily load especially the heat pump, my batteries will generally only last through the evening peak rates so Predbat generally aims to have me at 100% by 4pm (this plan was 92% at 4pm draining to 4% by 19:00) whereas your plan is 54% at 16:00 draining down to 19% by 19:00
  • your rates are about 1.5p/kWh less than mine (but higher SC)

Today I generated much less solar than you, 6.6kWh vs 6.9 forecast, but yesterday was over 10. Fortunately have been helped by power up events today, yesterday and the day before. But unfortunately not tomorrow.

All very strange

R
#383 Rbor

geoffreycoan At 4pm today, my battery was at 95% SOC. I even exported 3.8 kWh during the day.
I have switched my ASHP settings back up to where they should be: 0.6 slope and 2 level. Last week, house was losing thermal mass and I was down to 18C during day. Now back to 20C with temps much higher.
So far today, HP has eaten 15 kWh. Last week it was 25-30 kWh.

Of course, no power ups for me.

I think the Agile prices are really being affected by gas prices, with all the geopolitical influences.
Europe is in a real pickle, losing gas left right and centre, and I have noticed that less electricity is coming to us through the interconnects. I wonder what will happen to SVT come April.

Rob

W
#384 Wavy Davy

a few seconds before I did this screen shot all the blue hold charge's were green charge's.
Will see what it actually does.

W
#385 Wavy Davy

Changes quicker than kier starmer

Think I might downgrade a couple of versions.

R
#386 Rbor

Mine are all green charge still.
Your plan isn't that dissimilar to mine overnight.
My tariff rates definitely win .........

Rob

H
#387 Henry3rd

It's green all the way to 6:30 for me.

D
#388 Daveb01

Just checked HA this morning and looks like Predbat error again at 06:15.

Rebooted and all back. This is the third time 😡 best to keep an eye on things.

G
#389 geoffreycoan

Daveb01 Looks like it is failing with a divide by zero error on battery rate max charge which presumably it gets from givtcp. If that call failed then maybe thats why its getting a zero value.
Anything in the givtcp log at that time?

What happened afterwards, did predbat try to run again 5 minutes later or it remained in a heap? If the latter then you should raise this as a github log because predbat really should be able to recover from transient errors if they occur,

Do you have the predbat error detection automation running, it should restart predbat if it detects it has stopped running.

R
#390 Rbor

Daveb01
geoffreycoan

Is this one for sending Trefor as a 'debug log' in GitHub issues, especially as you have had this problem 3 times now. Trefor seems to like a debug log for spotting predbat problems.

Is this on v8.11.0?

Rob

G
#391 geoffreycoan

Rbor definitely worth always sending a debug log if you can do

the debug log is another of Trefor’s new changes to Predbat, it basically dumps all of your predbat config from apps.yaml and HA entities into a YAML file so Trefor can recreate your predbat configuration and settings. For things like ‘plan not right’ this is invaluable.

Since this has happened just 3 times and from the error I think its a temporary thing caused by bad/missing data from givtcp, the log won’t necessarily be needed, but better to supply if you can do.

I upgraded to v8.11.0 yesterday and there were no untoward surprises. Still working on calibrating the temperature charge curve though.

D
#396 Daveb01

geoffreycoan

MQTTHas no errors in the log.

GivTCP has errors but it seems after 8:00, and the last good write was at 05:30.

I rebooted at about 08:25

D
#397 Daveb01

geoffreycoan What happened afterwards, did predbat try to run again 5 minutes later or it remained in a heap? If the latter then you should raise this as a github log because predbat really should be able to recover from transient errors if they occur,

The log is huge so do not want to post it here really. (I have tried 3 times to do the ‘’’ thing and failed, so not having a good day.

predbat-logout0125.zip
309kB
D
#398 Daveb01

geoffreycoan Do you have the predbat error detection automation running, it should restart predbat if it detects it has stopped running.

I have the one in yaml, but not the other one you posted. So may have to look at that again.
If I restart GivTCP Predbat restarts, if Predbat goes wrong nothing happens it seems.

D
#399 Daveb01

Rbor Is this one for sending Trefor as a 'debug log' in GitHub issues, especially as you have had this problem 3 times now. Trefor seems to like a debug log for spotting predbat problems.

I have never got round to doing anything in GitHub so at the moment I have no idea how to send a log or report an issue to Trevor. You guys have always sorted it or it has never gone wrong for the same thing more that once especially in the night.

Thank you both as always for looking at this and your advice 👍🍺🍺

G
#400 geoffreycoan

Daveb01 looking at the givtcp log it looks like givtcp threw a wobble and predbat didn’t handle it well either.

Think its worth you logging this as a predbat issue in the first instance because if Predbat gets an error from givtcp then it should (via the apps.yaml config) restart givtcp to get things going again. It doesn’t look like this happened so its a predbat thing to look at.

There are two automations I provided in the predbat documentation (output data section). One to check that givtcp and mosquitto are running OK and providing data stream to HA, and one to check that predbat is running and the plan updates regularly.
They are not absolutely bulletproof but they do catch most ‘stopped working’ type errors so worth trying them.

G
#401 geoffreycoan

I’m seeing some unexpected behaviour with the temperature curve and low power charging mode overnight https://github.com/springfall2008/batpred/issues/1875

Interesting discussion on another github issue about how to calculate the temperature charge curves for your inverter. I will be using this to calibrate my own curve and add something to the documentation https://github.com/springfall2008/batpred/issues/1844

Oh, and still ill with this cold and cough. Living the dream….

B
#402 browellm

I would still be into having something like a a very simple predheat-lite control within predbat that takes an external temp sensor and models a % uplift to electricity use.

Use-case for me is a 2kW electric underfloor heating mat in the kitchen which kicks in pretty hard when temps get around 1-2C and below.

D
#403 Daveb01

browellm

So are you say saying your going to treat your battery to a new years present and stand it on a heated mat, incase it gets a bit cold 😜

It will be asking for a beer soon or Champagne 👍

G
#404 geoffreycoan

browellm I would still be into having something like a a very simple predheat-lite control within predbat that takes an external temp sensor and models a % uplift to electricity use.

You can do this with the select.predbat_manual_api

Basically you want to set an import_rate_override for the time period (and date), don’t specify a rate or rate_increment but set a load_scaling_factor for your house load (its a % of current load not a +/- of kW though)

You can manually add this rate override in apps.yaml or write a script that will set select.predbat_manual_api to the override details (I use this technique for handling Octopus power up and free electricity events - see other forum posts on this).

Then just need to trigger an automation based on the external temperature sensor (or a weather prediction of low temperature), the automation calls the script. Just need to work out what the time period is based on the triggering criteria.

Might need to think about why you are telling Predbat about this extra load and what you want Predbat to do about it. In general predbat is for planning longer term battery activity so it’d be better to trigger all this based on forecast weather so predbat can charge the battery ready for the low temperature activity.

Or if you want to trigger it based on ‘its cold and there will be extra load right now’ then the options for predbat are perhaps more limited - do you want to switch predbat to demand mode to let the battery take the extra load, or do you want to set it to freeze charge to stop the battery going into the floor heating and instead keep it for the later peak. If this latter than you might just as well be served by setting the select.predbat_manual_demand or similar manual controls to force predbat into a mode you want

D
#405 Daveb01

So I am loosing faith with Mr Bat, it seems to think my batteries should go into Idle during the peak period.

The only thing I have changed was to upgrade Predbat yesterday.

We have been out for a few hours, checked the logs just now and it looks like it’s Predbat. So going to a backup.

L
#406 Leeshore

geoffreycoan Just reading through the github posts etc about the temperature curve. Think I'll wait until the clever people like you come to a conclusion as I am struggling to understand the technical jargon.

L
#407 Leeshore

Daveb01 Mine seems Ok and up to date with predbat upgrades:

Have low power mode charge to True as the only change from default config

G
#408 geoffreycoan

Daveb01 the predbat log shows the same divide by zero error you had this morning. I’d try restarting predbat and givtcp and this should clear it.

And rather than restoring a backup you can always just downgrade predbat to the last version, select the version you want from select.predbat_version

8.11.0 is running fine for me, doing what it should no crashes

@Leeshore you can run the latest version just don’t update apps.yaml if you don’t want the temperature curve stuff running. The default curve is probably OK, can be improved, but its better than having no curve.
Having said that there are some weird things happening with low power mode and temp curve so as you are using low power mode then perhaps not defining the temperature curve is a good thing until Trefor has taken a look at the reports we’ve made

R
#409 Rbor

Daveb01 When I have had real issues, I have loaded a previous backup.
But first downgrade to a previous version of predbat as @geoffreycoan has suggested.

I have experienced most issues following a HA upgrade. I did try 2025.1 and backtracked to 2024.14.5 which got me back on track.

I have even completely shutdown HA and have got things back then.

It is easy to submit an issue on Github and Trefor often spots the problem from uploaded logs.

Rob

D
#410 Daveb01

Rbor
@geoffreycoan

Thank you both. I restarted everything, Mr Bat was not having that.
Downgraded Mr Bat as suggested, he took the warning and looks like it’s all back. But for how long?

I will now keep an eye on it more often (again). Ahhh is that the issue, I was not looking at it as often as I was, tying to step back a bit and Mr Bat did not like it 😛

P.S - I rebooted GivTCP only to test the auto restart of Predbat and that works, so if MQTT& GivTCP is OK, Predbat does not restart.

R
#411 Rbor

Daveb01 What does your latest predbat log look like?

Rob

N
#412 Northwarks

Evening all - I used Predbat all the way through 2024 on Flux, had zero issues with charging and exporting until late November and then despite subsequent daily plans having charge slots early mornings it failed repeatedly so I essentially dropped it into monitor mode as I could no longer trust it and didn't have the time to troubleshoot. Since then I've upgraded to GivTcp 3, re-installed Predbat as an add-on and the Octopus Energy Integration and I turned it back on this week in charge/discharge and it's been working as expected - phew.

I swapped to Agile yesterday, restarted everything and I started to get a new Predbat plan, it's been charging as you would expect, but what I've not seen, despite the battery at 90-100% is any export in the plan. The config is all defaults and I just can't see what the problem could be. I would just expect it to do some exporting in the plan?

Any pointers would be gratefully received !

H
#413 Henry3rd

I have had no export for a while. Predbat tries to fill the battery to 100% from solar.
It's more cost effective to avoid exporting at 15p when it's costing 20p to charge in the first place plus the losses through conversion.

N
#414 Northwarks

Henry3rd - Now I didn't think of that ... Maybe I just need to wait and see what happens as the days get longer - Thanks

R
#415 Rbor

Northwarks One thing to check:
The Flux tariff incorporates import and export.
The stock Agile tariff is an import tariff.
To export, you need to apply for Outgoing Octopus:
https://octopus.energy/smart/outgoing/
There are two varieties and the usual advice is to enrol onto Outgoing (fixed 15p/kWh), rather than Agile outgoing which usually has lower export rates.

So first check that you are on an export tariff.

If you have already done this, many people have found that export can take a little longer to set up.

Hope that helps.

Rob

T
#416 TX200

Agree re export, hardly any for me in recent weeks, it's not worth it - import Vs export price not great.

Plus import price is fairly high overnight - so PredBat saves the energy for me to use, and I agree. It makes sense.

D
#417 Daveb01

Rbor

Looks good phew

It’s happened again

R
#418 Rbor

Daveb01 Givtcp log?

Have you touched your apps.yaml?

Rob

G
#419 geoffreycoan

Daveb01 the problem is not predbat. Predbat tries to set the discharge rate and gets a bad response back which it rejects.

Its either:

  • givtcp
  • comms from Home Assistant to your AIO gateway
  • your AIO gateway not accepting the responses

Since you have restarted givtcp once already I would hazard a guess that it’s the last of these options. Try doing a ‘reset to defaults’ of your gateway and AIO’s from the givenergy portal and rebooting them all.

You have restarted givtcp before but the other thing to try is to delete all the /config/GivTCP/*.PKL files (cache files) and restart givtcp again. In fact do a complete shutdown and restart of HA and all addons to be sure

D
#420 Daveb01

Rbor

Nope yaml not touched for about 6 months

D
#421 Daveb01

geoffreycoan

Here are the two logs together, so it seems to me it maybe the Gateway?


H
#422 Henry3rd

Daveb01 Just an observation from me. Do you know why Predbat is setting a discharge and charge rate of 0?
in effect telling the invertor to discharge or charge at a rate of zero, which would cause some confusion.
I would expect it to be 3600 or a percentage of your max invertor discharge rate. Is the discharge rate set ok in YAML?
Has the temperature charge curve muddled things? It looks like 0% charging is effected when the battery temp is at zero deg.

D
#423 Daveb01

Henry3rd

The thing is I have not chaged any settings just update HA, Predbat etc. As I have AIO’s I have not updated yaml with Temp curve etc. as not needed.

D
#424 Daveb01

geoffreycoan

So doing one thing at a time:-

Not touching yaml
Have gone back to Predbat 8.10.2
GivTCP rebooted only (will remove cache files next)
MQTTRebooted but no errors in the log so think this is OK.

HA
Core - 2025.1.2
Supervisor - 2024.12.3
Operating System - 14.1
Frontend - 20250109.0

G
#425 geoffreycoan

Henry3rd Just an observation from me. Do you know why Predbat is setting a discharge and charge rate of 0?
in effect telling the invertor to discharge or charge at a rate of zero, which would cause some confusion

I have definitely in the past seen Predbat set charge or discharge rate to zero when it wants to do a freeze operation, but looking at my sensor history I don’t see this happening at the moment so maybe its been optimised out in favour of using PauseDischarge which is used a lot.

Be worth seeing if things settle down on an older Predbat version and then reappear with the latest version which would indicate a predbat bug, although not one I am seeing.

D
#426 Daveb01

Henry3rd

I will keep an eye on this as just seen this again on Predbat Log
This is what the GW settings are and have been for months


D
#427 Daveb01

geoffreycoan

I have deleted all the *.pkl files now.

No more errors at the moment, it not going to sleep well as battery was nearly flat this morning.

R
#428 Rbor

Looking again at the logs, predbat breaks down with:
givTCP breaks with Setting Discharge Rate failed: ( 'ZeroDivisionError', 'write.py, 447)
predbat does the same with Inverter 0 set discharge rate 0 via REST failed got 6000
Previous pause instructions worked fine.

Is it worth looking on the GE portal and looking at the charge and discharge settings?

And in predbat webUI/configuration, are there any rogue settings?

Another observation: When you restarted predbat, immediately after the probate files being 'watched', you are getting warnings:

19:12:49.453722: Warn: Inverter 0 set discharge rate 0 via REST failed got 6000
19:12:49.492214: Warn: record status Warn: Inverter 0 REST at Failed DischargeRate to o got 600
19:13:20.755865: Warn: Inverter 0 set charge rate 0 via REST failed got 9960
19:13:20.797640: Warn: record status Warn: Inverter 0 REST failed to setChargeRate

I don't see anything like this. I go straight from the 'watching' lines to the first instruction with no warnings.

Finally, which version of givTCP are you running?

Rob

G
#429 geoffreycoan

@Daveb01 did these errors only start appearing and continue to appear on Predbat 8.11.0, or are you getting it happening on older Predbat versions as well?

When you upgraded to 8.11.0 I think you said you didn’t define a battery temperature charge curve in apps.yaml?

Did you define anything in apps.yaml at all for the new version, a temperature sensor, temperature history sensor, or just left apps.yaml unchanged?

If there is a strong correlation between this starting to happen on 8.11.0 then I am wondering if this is a side effect of the temperature curve logic, determining from the temperature that it needs to assume a charge and dischare rate of zero which is what causes the fail. Maybe? I know I can set 0 for my inverter charge and discharge rate but maybe the AIO gateway is different?

You could be working yourself up to your first github issue Dave

R
#432 Rbor

Daveb01
Final final thought here:

geoffreycoan
Be worth seeing if things settle down on an older Predbat version and then reappear with the latest version which would indicate a predbat bug,

So try downgrading predbat back to v8.10.2

Rob

D
#433 Daveb01

Rbor

So this maybe because I have these set in GW (see pic above). I noticed Predbat did not change these and was importing exporting at max 12000 even when I set them to lower 9n yaml.

So to sort out this should I put them back to 0 or do what Geoffrey has suggested (reset to defaults?)

D
#434 Daveb01

geoffreycoan

I have only noticed these errors since upgrading to the latest version. I down graded earlier tonight. I have not had any errors since however this 0 setting is still worrying me.

I did not do anything with the new temperature setting in yaml, so it should not have been that.

R
#435 Rbor

Daveb01 I don't know about Gateways and the AIO.

Anyone AIO users out there who may be able to help?

Rob

R
#436 Rbor

Daveb01 So are predbat and givtcp behaving themselves now?

I notice that you are on HA 2015.1
I tried this but it broke my setup.
I got my system back by restoring to my most recent backup: 2014.12.5

But first, see if your setup settles down on predbat v8.10.2.
I must admit that I don't understand what is going on with the battery temperature changes in v8.11.0. Although I am running v8.11.0 myself, I haven't added any of Trefor's code lines to my apps.yaml.

Rob

G
#437 geoffreycoan

Daveb01 So this maybe because I have these set in GW (see pic above). I noticed Predbat did not change these and was importing exporting at max 12000 even when I set them to lower 9n yaml.

So to sort out this should I put them back to 0 or do what Geoffrey has suggested (reset to defaults?)

Predbat should set the discharge and charge rate to the limits specified in apps.yaml, setting the battery charge rate and discharge rate when it needs to. The Charge Rate AC and Discharge Rate AC are I think derived from the raw charge/discharge rate.

But then you say despite what the dashboard says the inverter is going at full rate. The REST errors indicate that predbat was trying to change these to zero but this was rejected and it was getting a response of the original value.

Its hard to tell precisely what is going on, but I suggest a reset to defaults will at least get the inverter into a known clean state, and then either you or predbat can set the battery charge/discharge rate to what you have in apps.yaml and it should then be back to normal.

Daveb01 I did not do anything with the new temperature setting in yaml, so it should not have been that.

No but it may be that Predbat expected you to have configured it in apps.yaml and because you didn’t, it defaulted to an empty temperature charge curve and hence got to setting the rates to zero.

I don’t know for sure, lets try the above and leave it running on 8.10.2 and let it run overnight. Then can try upgrading later on.

T
#438 TX200

Rbor is that an o rather than 0?

"DischargeRate to o got 600"

I don't fully understand this new code as I'm not using it myself (my battery is unlikely to get cold) but that looks a bit suspicious.

D
#439 Daveb01

geoffreycoan

Morning all, thank you for the help so far, and your continued help on the new puzzle.

There were a few issues again in the night (see logs below). I did not have time to reset my system, so that is number 1 on the list today. I looked at Predbat first and can see errors but good to see this time auto restart. It has benn working the rest of the night and still ok at moment. Battery at 100%. Iaw the plan.





G
#440 Goshiki2

Daveb01 According to Predbat you had a time skew of 59.25 minutes to the inverter. Is this related to your problem? Is it worth an inverter time resync first before you move on to anything more drastic?

D
#441 Daveb01

Goshiki2

I saw that, not sure why that happened.

D
#442 Daveb01

The plan looks ok during the day but the goes into planned charge for hours?

Surly Predbat knows the battery will be full and not keep trying to charge?



D
#443 Daveb01

geoffreycoan

I will wait until you have commented on the logs etc, before I reset to defaults as suggested,

G
#444 geoffreycoan

Goshiki2 I was looking at that as well. Its weird:

Daveb01

2025-01-17 23:45:10.083432: Info: record status
2025-01-17 23:50:51. 028724: Info: Freeze charging target 13% record_status Freeze charging target 13%
2025-01-17 23:55:10.595215: Info: record status Freeze charging target 13%
2025-01-18 00:00:40.225126: Warn: Invertor time is 2025-01-18 00:59:56+00:00, Predbat computer time 2025-01-18 00:00:40.224944+00:00, this is 59.25 minutes skewed, Predbat may not function correctly, please fix this by updating your inverter time, checking HA is synchronising with your inverter, or fixing Predbat computer time zone 2025-01-18 00:00:40.261416: Warn: record status Invertor time is 2025-01-18 00:59:56+00:00, Predbat computer time 2025-01- 18 00:00:40.224944+00:00, this is 59.25 minutes skewed, Predbat may not function correctly, please fix this by updating your inverter time, checking HA is synchronising with your inverter, or fixing Predbat computer time zone

Predbat checks the time of the clock it is running under and the inverter clock it gets back via GivTCP to make sure they are in alignment. If they are wildly different then any commands Predbat issues to start charging/discharging at a specific time obviously won’t happen at the time Predbat expects them to occur.

This also serves as a check that GivTCP is correctly polling your inverter and there’s no break in connectivity,

What normally happens with a time check error is that Predbat detects that Predbat time is ahead of inverter time so we’re not getting data from the inverter via GivTCP, and predbat restarts GivTCP to restore the comms.

But the text of the error says that inverter time received from GivTCP is an hour ahead of the predbat time. This is unusual. Tends to suggest that the inverter time zone or the inverter time is set wrong, but there are normal OK transmissions beforehand and then when predbat restarts givtcp its all OK afterwards. If the time/time zone was wrong you’d expect further errors. Very strange.

The POST error at 08:01 I wouldn’t worry about too much, I get those maybe once a day as well and Predbat retries and it carries on working.

G
#445 geoffreycoan

Daveb01 The plan looks ok during the day but the goes into planned charge for hours?

Surly Predbat knows the battery will be full and not keep trying to charge?

This is OK. Firstly you’re looking at the end of the plan more than a day away so all the prices are rolled over and will change, but more, the plan only goes through to 6am when you’ve got very little load, flat Agile rates, and no solar generation so Predbat doesn’t really know what to do with the battery. Given the rates are flat it makes sense to hold the battery full rather than let it discharge. As the plan rolls forward and predbat can ‘see’ your solar generation, load and prices for Sunday it will update to something more meaningful.

My own Sunday plan is much the same except its got a bit more forward window than yours and at 8:30 when (rolled over) rates increase it lets the battery discharge a bit

It’s what I would expect.

Worth you still doing a reset to defaults and resync the time zone & date/time, won’t do any harm

R
#446 Rbor

geoffreycoan
Daveb01
This reminds me of the date change glitch we had on 1st Jan (see back around post 136 onwards).

It won't do any harm going to GE portal and doing a sync time in account settings and then again in remote control.
In screenshot of your predbat log in post 420, there is a green line:
[19:11:17) INFO: Configuring timezone (Europe/London) ...

I don't think predbat is cause here. It looks more likely to be givTCP and/or communications with mosquito broker.

Dare I say that there is an update to mosquito broker (and hacs)! But let's see what is going on here before going there.

Rob

R
#447 Rbor

Daveb01

Looks like you same synchronised suggestion delivered to you just now:

geoffreycoan

Worth you still doing a reset to defaults and resync the time zone & date/time, won’t do any harm

and

Rbor It won't do any harm going to GE portal and doing a sync time in account settings and then again in remote control.

Rob

D
#449 Daveb01

geoffreycoan

Thank you for the comments. I will go and get a cuppa do the reset to defaults and a time sync.

I now have the time of all three devices in my home card and they look good.

D
#451 Daveb01

geoffreycoan

As it looks like yaml auto restart is working most times, I will not touch this. I think you also posted you had extra checks, should I leave it as is at the moment or looks at trying to install these as well?

H
#452 Henry3rd

Goshiki2 According to Predbat you had a time skew of 59.25 minutes to the inverter. Is this related to your problem? Is it worth an inverter time resync first before you move on to anything more drastic?

Does anyone have an automation set up that is able to sync the invertor on a daily/weekly basis?

R
#453 Rbor

Rbor Looks like I have resolved the error reported. HA had changed the name of my iPhone from iPhone to iPhone2.

But doesn't tell me what the exception was caused by. This is predbat log around 7:45 am when exception was raised. Could this be linked to the woes of @Daveb01 ? Although there is a complaining line about battery size which I have highlighted with ** around it? Any ideas?
2025-01-18 07:31:27.266859: Info: record_status Demand
2025-01-18 07:35:12.328554: Info: record_status Demand
2025-01-18 07:41:35.716493: Info: record_status Hold charging target 95%-91%
**2025-01-18 07:45:05.362427: Error: Reported battery size from REST is 0.0, but it must be >0**
2025-01-18 07:45:05.362655: Error: Exception raised
2025-01-18 07:45:05.372372: Error: Traceback (most recent call last):
File "/config/predbat.py", line 994, in run_time_loop
self.update_pred(scheduled=True)
File "/config/predbat.py", line 565, in update_pred
self.fetch_inverter_data()
File "/config/execute.py", line 629, in fetch_inverter_data
inverter = Inverter(self, id)
File "/config/inverter.py", line 354, in __init__
raise ValueError
ValueError
2025-01-18 07:45:05.412828: Info: record_status Error: Exception raised
2025-01-18 07:45:05.413035: Error:
Traceback (most recent call last):
File "/config/hass.py", line 184, in timer_tick
item["callback"](None)
File "/config/predbat.py", line 999, in run_time_loop
raise e
File "/config/predbat.py", line 994, in run_time_loop
self.update_pred(scheduled=True)
File "/config/predbat.py", line 565, in update_pred
self.fetch_inverter_data()
File "/config/execute.py", line 629, in fetch_inverter_data
inverter = Inverter(self, id)
File "/config/inverter.py", line 354, in __init__
raise ValueError
ValueError
2025-01-18 07:51:25.517158: Info: record_status Demand
2025-01-18 07:55:11.617502: Info: record_status Demand

Rob

R
#454 Rbor

Daveb01 Thought you would be interesting in this post with code. From someone on Trefor's predbat page on Facebook, posted at 09:17 this morning:

Any tips on monitoring this situation. It’s happened twice now in as many weeks. Clearly a GivTCP issue but is there anything I can monitor in Predbat to kick GivTCP into touch? Is there a binary status sensor?

Look familiar?
I will keep an eye out to see if anyone has any suggestions.

Rob

D
#455 Daveb01

Rbor

No change to my mobile setting.

D
#456 Daveb01

geoffreycoan
@Rbor

Hi all, have reset to defaults and sync time, hacked the logs in Giv Cloud and all was processed successfully. Phew part one completed.

I took a screen shot of settings before I did reset and a few things have changed. So the question is do I leave them as default and see or put them back to how it was?

Also I hope my batteries charge and discharge at the correct rate as I don’t want to export and import at 12000 (the DNO will have a dicky fit)

Changes:-

Enable AC charge upper % limit - was on now off
In GW control - Enable Charge Target - was on now off

D
#457 Daveb01

Another thing I tried and was successful. I moved the slider for all these settings and Predbat put them back to the correct ones. (So a good hint to try if you get the same issues as me). I have made a note to move them to a random number now and then to see if Predbat moves them back to my yaml settings.

G
#458 geoffreycoan

Henry3rd Does anyone have an automation set up that is able to sync the invertor on a daily/weekly basis?

It shouldn’t of course need it, the inverter should keep reliable enough time, its mains powered and on all the time so its not like its a PC with a button cell battery that fails after a few years.

I believe there is a givtcp command to enable resync but on 31/12/24 when we had all these date issues someone raised a github issue that it didn’t work. I don’t recall seeing any responses to that issue so its probably lower down the priority list.

Interestingly there was a github issue last week about exactly the same failure as occurred on 31/12/24, givtcp falling over due to invalid date conversion. I got the person who had the issue to install the BBC inverter app and he confirmed it was a corrupt date on the AIO. Resyc’d it via the portal and all cured. Weird.

Rbor 2025-01-18 07:41:35.716493: Info: record_status Hold charging target 95%-91%
2025-01-18 07:45:05.362427: Error: Reported battery size from REST is 0.0, but it must be >0

Your error looks like bad inverter data returned from givtcp Rob, Predbat objected, the error monitor picked up the error and tried to send you an alert but couldn’t due to your phone id changing in HA.

R
#459 Rbor

geoffreycoan Your error looks like bad inverter data returned from givtcp Rob, Predbat objected, the error monitor picked up the error and tried to send you an alert but couldn’t due to your phone id changing in HA.

I suppose the exception was just one of those things that happens from time to time. Predbat is working just fine apart from this one exception.
I have fixed the automation (I hope) by correcting the iPhone label. I tested the alert part of the code and an alert happened on my iPhone, or should I say iPhone2.

My next Agile Octopus 12M tariff started today. Here's the bad news from 53.95p 😥

My only compensation is that my unit rates at about 2p less than areas with lower SC. Good news at this time of year but bad news in the summer when I will be importing little.

Rob

G
#460 geoffreycoan

Rbor 28 days left on my current Agile tariff paying 42.01p standing charge then goes up to 48.79p

Have to say I don’t understand the regional variations in standing charge, that it costs 25% more to distribute electricity in Yorkshire than it does in East Anglia? I suppose that unless you are going for a truly national cost base there will be regional differences and they have to be allocated one way or another. Daresay it leads to postcode splits where one side of a street pays less than the other.

As for paying a lot of SC in summer when you are importing less, but you are exporting loads and the cost of providing your grid connection - maintaining the transmission network, NESO, having the field engineers, etc all remains the same year round and you’re not paying an export service charge.

Be interesting to see what happens with the consultation about giving the option for no-SC bills. Whether we will see no SC versions of all the tariffs and then would we be switching between the SC and no SC in winter and summer ?

G
#461 geoffreycoan

Rbor HA had changed the name of my iPhone from iPhone to iPhone2.

If you go to Integrations / Mobile App / select iPhone2 device

You should be able to rename the device and all its entities

R
#462 Rbor

geoffreycoan I have looked back to posts #377 – #379 where we both posted out tariff rates. Looking at rates around 20p/kWh, I was about 1p cheaper than you.

In January so far (17 days), I have imported 500 kWh. Compared with Eastern England, this would have cost me about 500p less.
Taking our new respective SC rates (66.26p against 48.79p), I would have paid nearly 300p more.
So overall, I am about £2 better off.
In the summer, my import costs will be minimal so I would be worst off in the summer.

Over the whole year, I suspect that there would be little difference in our overall energy costs as winter and summer SC would balance out compared with winter import costs.

SC in winter and no SC in summer is an interesting idea!

If there were a tariff with no SC, I wonder how much unit prices would be increased by?

At the back of my mind, I wonder how long the 15p export rate will be maintained. If import unit rates increase, export rates should also increase but ...... If they are kept at 15p, really they are decreasing compared with import costs.

I am glad that I have 9.75 kWp of PV and you have more.

Rob

R
#463 Rbor

geoffreycoan Thanks. I will give this a try and then change the automation back from iPhone2 to iPhone. I guess that this happened when I upgraded my old iPhone nearly 2 years ago.

Rob

D
#464 Daveb01

Daveb01 Enable AC charge upper % limit - was on now off
In GW control - Enable Charge Target - was on now off

@geoffreycoan
@Rbor

Any idea on what I should do with these settings that have changed after the reset to default?iam now not 100% sure what they were actually doing, so may have to go back and look at the posts to see why I changed them in the first place.

  1. Leave them as it now and keep an eye on them
  2. Change them to what they were and keep an eye on them
R
#465 Rbor

Daveb01 Can you get any clues by looking back at the early threads you started:

Basic Config of Predbat (after staring from scratch)
How to use Predbat (from scratch)
Setting up Energy Cardin HA

I will look at this anyway later but you may get some ideas from these threads.

Rob

D
#466 Daveb01

So this is Mr Bat’s plan, not sure I agree with it as normally I am using the battery.
Not going to touch anything btw, just looking 👍

G
#467 geoffreycoan

Daveb01 Enable AC charge upper % limit - was on now off
In GW control - Enable Charge Target - was on now off

Enable AC charge upper % limit is used in conjunction with AC charge upper limit which specifies an upper % you want to do grid charging up to. e.g. 80% if you want to leave some space for solar next day.

My upper limit is set to 100% so Predbat can charge the battery as it wishes, but the switch is off so this feature is disabled.

Enable charge target I can’t see in my GE portal but in HA it is turned off as well. I would guess its something to do with when you are charging up to a target %, but if its working fine and charging OK then I wouldn’t worry about what it was before.

Rbor At the back of my mind, I wonder how long the 15p export rate will be maintained. If import unit rates increase, export rates should also increase but ...... If they are kept at 15p, really they are decreasing compared with import costs.

I have been digging through my emails trying to find what I was originally receiving on Octopus Flux. When I first joined Flux and started receiving export payments in August 2023 the day rate was 19.72p but in September following Ofgem’s rate decreases the daytime export was reduced to 16.932p. Flux peak rate export dropped from 32p to 28.1p.

Since then I’m pretty sure the SVR rates have increased overall but yet Flux in my area would pay 13.64p for day-time export and 27.44p for peak rate export.

Octopus did at least remove the 8p export rate for Go customers, giving them the same 15p rate as available on IOG and other tariffs but I get the feeling that they’re not being as fair as they could be. Eon pay I think 16.5p.

But given that 10-12% of my annual electricity import is on the Power up and Free electricity events this gives a strong impetus for me to remain with Octopus. We shall see I guess

G
#468 geoffreycoan

Daveb01 So this is Mr Bat’s plan, not sure I agree with it as normally I am using the battery.
Not going to touch anything btw, just looking 👍

It looks OK to me. The Agile rates are fairly flat overnight (and expensive again) so there’s little benefit in using the battery, so its being charged in the lower rate period and then held full when rates increase through Sunday afternoon.

The effective import rate with losses (figure in brackets) gives you an idea of whether Predbat will want to use the battery or not. e.g. Sunday 11:30 rate 24.59 effective rate 27.35 - this means that it would cost 27.35p to be replenishing the battery from grid import whereas its only 24.59p to be using direct grid import.

So unless there is a load of cheaper electricity coming up later on in the plan that Predbat can use to refill the battery (which there isn’t) its going to be better to keep the SoC.

After 16 months of looking at the effective rate alongside the actual rates I have gone brave and turned the html debug off so I only see the real rates now.

D
#469 Daveb01

geoffreycoan

Thank you so much, I will leave them off. Good timing btw as I have been searching all the posts for over an hour and had enough.

R
#470 Rbor

Daveb01 I have looked at my controls on my AC3.0.
All my 4 battery charge/discharge are on full buy the AC3.0 means that: 3 kW charge and 3 kW discharge. So no correlation to AIO and I don't think I can help here.
What are your default settings for battery charge and discharge anyway?

My overall conclusion is to let predbat do its stuff. It needs a break as do you.
Bearing in mind the problems you have had over the last couple of days, if your system is working now, just let it work. If you change things now, you could reintroduce the same, or new. issues.

Also look carefully at what @geoffreycoan has just written about losses and the merits at times to work from the grid rather than batteries.
Put a padlock around predbat and report back tomorrow.

Rob

R
#471 Rbor

Rbor Thanks. I tried this but I failed! Whether I should have left things longer or restarted HA, I don't know. 'iPhone' doesn't show up in Developer Tools but iPhone2 does (even after changing). But I have iPhone shown in Devices & Services.

I have gone back to iPhone2 as the name and in the automation. This works and I will live with it.

Rob

R
#472 Rbor

Daveb01 My plan overnight and into tomorrow is much the same as yours.
So don't worry ......

Rob

G
#473 geoffreycoan

Rbor what precisely did you change?

I think its the device name here:

the notification script calls notify.mobile_app_geoffrey_s_iphone_12

I actually have a notification group setup for my ipad, ipad mini and iphone and use that instead so notifications get sent to all my devices, but the principle should be the same for a single device.

If you rename the device in the above screen and then go to developer tools / actions / search for notify what notify services do you get, the new phone name or still the old?

R
#474 Rbor

geoffreycoan I tried changing the name here to iPhone but in the sensors, I lost the BSSID and SSID settings so the iPhone cannot then communicate to my wifi.
In Developer Tools the name was still iPhone2.

I also tried renaming via the 3 dots to the right.

If I do this, BSSID and SSID stay but the name accessible by the pencil doesn't change unless I change this as well.
Either way, Developer Tools keeps the old setting that I had changed.

Anyway, I have just gone back to iPhone2 which works just fine.

Rob

G
#475 geoffreycoan

Rbor I would have thought the BSSID and SSID like all other companion app sensors are just mirroring what is on your phone, so loosing them wouldn’t have affected your phone connectivity?

There are an awful lot of sensors produced by the companion app that TBH I never look at at all. I thought I had disabled some of them in my database reduction quest but don’t seem to have had; they’re really not adding value to me. Other than notifications the only use I have ever seen for these is the geo location stuff, e.g. open the garage door and turn on the outside lights when you are arriving home.

Another way to fix your iphone2 thing could be to uninstall the companion app, delete the device and entities out of HA, reboot HA then reinstall the companion app. The 2 would annoy me!

H
#476 Henry3rd

Has anyone come across this Givtcp error?
Inv1 - sync - [ERROR ] - Connection to (192.168.0.41, 8899) failed: timed out. This is coming up with regularity.

I have just completed an IP scan, and it shows that this device is online and I am able to ping the device which I assume is the invertor.

G
#477 geoffreycoan

Henry3rd If you look on your router you should be able to see what IP your inverter has, it usually has the name HF-A21 or something like that, but it is likely it is your inverter IP.

You shouldn’t be getting repeated connection failures from givtcp to your inverter. It suggests either your inverter is going deaf (a reset to defaults can sometimes cure this), or there’s an underlying network problem such as poor signal strength.

Just to check, how is your HA server connected to your home network? Is it wifi or wired ethernet? I think I used to get timeouts on givtcp when I first started with HA on wifi even though it was less than a metre from the router. I swapped to an ethernet cable and it became a lot more stable.

H
#478 Henry3rd

geoffreycoan we have been having a few network problems lately which has been affecting the TV etc. It could well be that everyone is inside playing on their xboxes.
I shall do a complete shutdown and reset of the router later today.
The invertor is hard wired.

R
#479 Rbor

geoffreycoan I've partly sorted it but in a bizarre way.
But not completely fixed. I wonder whether there is a bug in HA.

On my iPhone/about, the name is iPhone.
I deleted the HA companion app from my iPhone and installed again afresh.

In Devices&Services/Mobile app, if I select the pencil, I can change iPhone2 to iPhone. This changes all the device parts of the entities to iPhone.
BUT the device itself is still called iPhone2. I select the 3 vertical dots to change this to iPhone.

I check configuration.yaml.
default_config is there.
I add iOS: (not really sure what this adds!).
This adds an iOS integration, which I probably don't need. A candidate for removing and purging.

I then restart HA.

BUT the predbat error monitor automation only works with:
action: notify.mobile_app_iPhone2
I have an apple watch and the alert comes through to the watch also
If I change to iPhone, I get this error message. Action notify.mobile_app_iphone not found

In Developer Tools, under action, I see notify.mobile_app_iPhone2 but not notify.mobile_app_iPhone.

I have tried notify.mobile_app_ipad and that works (but Developer Tools shows this action name also)

So something within Actions seems to clinging on to iPhone2. A hidden cache?

Been on this for 2 hours now.

On the plus side, the automation was never going to send me an alert anyway from iPhone, just from iPhone2.

I hope that all makes some sense as I emerge from another HA rabbit hole!
Off out for some fresh air. The murk has reached Yorkshire after 8 days of nearly unbroken sun, averaging nearly 10 kWh daily! From recent weather forecasts, I wonder whether my part of Yorkshire, in the foothills of the Peak District, was the only region in England that escaped grey skies.

Rob

G
#480 geoffreycoan

Rbor So something within Actions seems to clinging on to iPhone2. A hidden cache?

Google is your friend. I haven’t tried this but these two articles cover the same ground, seems a combination of uninstalling the companion app, clearing the companion app cache and restarting HA is needed to get the new device name to be recognised

https://community.home-assistant.io/t/changing-device-name/156812
https://community.home-assistant.io/t/phone-renamed-in-companion-app-notify-service-not-rename-how-to-solve/606568

Rbor I add iOS: (not really sure what this adds!).

according to my configuration.yaml its needed to enable actionable notifications https://www.home-assistant.io/integrations/ios/

Rbor The murk has reached Yorkshire after 8 days of nearly unbroken sun, averaging nearly 10 kWh daily!

Rubbish solar all week, a couple of kW every day. Last decent day was 13th January. Tuesday is forecasting 9kWh. Summer will come one day…

Henry3rd The invertor is hard wired.

Is your Home Assistant server also hard wired? I found it improved stability of my givtcp connection when I hard wired mine

D
#481 Daveb01

@Rbor
@geoffreycoan

As suggested, I did not go into HAafter the reset yesterday. Just gone in and all looks OK.
So the Reset to Defaults & a time sync was a good idea.

Thank you all again I can now have a relaxed Sunday

R
#482 Rbor

👍👍

H
#483 Henry3rd

geoffreycoan Is your Home Assistant server also hard wired? I found it improved stability of my givtcp connection when I hard wired mine.

Yes it is, we have network problems regularly so I hard wire everything if I can.
Interestingly, if I run diagnostics on the network, it shows everything as being perfect! However, when I speak to Sky it seems to fix itself shortly afterwards.
Hmmm!
I have just pulled the plug on the router, so let's see.
I no longer just switch it off at the socket because I don't want to disrupt my pi more than necessary. I need to see how to safely shut it down.

H
#484 Henry3rd

Henry3rd The restart of the router has reduced the number of communication errors. Now just 1 every 6 minutes or so. I shall keep a watching eye out and give Sky a ring on Monday if things deteriorate.

R
#485 Rbor

geoffreycoan I 'think' I have resolved the iPhone/iPhone2 problem.
The HA links you provided to me gave solutions for the Android companion app.
One challenge for me was finding the companion app settings. I found it eventually under 'Home Assistant'/settings on the iPhone. Nothing about the iPhone in the companion app but I did notice 'Server'. In desperation, I selected this, I was greeted by the initial login HA screen for username and password. I completed this and found that I now had 2 inputs, both for 'rob'. On selecting each, one referenced iPhone, the other iPhone 2. I deleted the login in for iPhone2.
For good measure, I restarted HA. In Developer Tools/Actions, I now see iphone and not iphone2.
I then went to the predbat error monitor automation and tested the alert sequence which generated an error message (it still had iphone2 as this was my automation).
I changed the iphone2 to iphone in the automation and the alert worked, sending the alert to my iPhone.

It looks as if this has been an ongoing issue for years!
What a ridiculous way to spend/waste so much time.

While I am on a streak, I may upgrade to HA 2025.1.2. Wish me luck.

Rob

D
#486 Daveb01

Rbor

I bet that’s a weight of your mind getting iPhone 2 sorted. I hope you don’t get any issues like I had.

W
#487 Wavy Davy

Daveb01 Dave re your home card do you have the yaml for it? Like the look of it but cant find the entities such as HA CPU.

G
#488 geoffreycoan

Wavy Davy Dave re your home card do you have the yaml for it? Like the look of it but cant find the entities such as HA CPU.

Have a look at the older threads Dave created on setting up HA and Predbat they should cover the dashboards.

You’ll need to install the system monitor integration for things like CPU https://www.home-assistant.io/integrations/systemmonitor/

Beware these are quite ‘noisy’ and need to be purged in the database regularly

D
#489 Daveb01

Wavy Davy

Here you go, I have tried to paste it in here but the code did not look right and I don’t want to get demoted from Rabbit by Rob. So here is a pdf

home-card.pdf
35kB
R
#490 Rbor

In my lurking capacity over at Trefor's facebook page, I have come across this contribution from Trefor. It helps to explain why predbat sometimes uses the grid when many of us question why predbat isn't charging the battery. Food for thought .....

You can view the actual context for this in Predbat Github issues here:
https://github.com/springfall2008/batpred/issues/1873

Rob

T
#491 TX200

Rbor I haven't set either of those metrics.

I did increase the inverter and battery loss by 1-2% each, didn't want to think everything was perfect but in fact end up having decisions that actually cost me money.

My values are 0.05 for battery charge and battery discharge loss and 0.04 for inverter loss.

20% is often mentioned as the typical round trip loss. The above comes out at 18%. I suspect 13% is a bit low.

D
#492 Daveb01

Rbor

I think we had a discussion about this and we agreed 5 was the best setting. Now I have read this should we put it back to defaults?

My current plan looks like this and it has a few idle at the moment?

G
#493 geoffreycoan

TX200 My values are 0.05 for battery charge and battery discharge loss and 0.04 for inverter loss.

20% is often mentioned as the typical round trip loss. The above comes out at 18%. I suspect 13% is a bit low.

Daveb01 I think we had a discussion about this and we agreed 5 was the best setting. Now I have read this should we put it back to defaults?

Trefor has added the above FB post to the Predbat FAQ’s; the key thing I’d take away from this is the reminder that the inverter loss acts as a double-whammy as you get inverter losses on the way in and the way out of the battery, so be careful of increasing that too much.

I personally think 13% which is what you get with the predbat defaults is a bit too low and we should be more like 15-20%, but what the right figures are, and whether they the same for low voltage AC/Hybrid inverters and batteries and high voltage AIO and 3-phase 🤷‍♂️
The losses do also vary with temperature and with SoC.

I have my inverter loss set to 0.04 and the battery losses to 0.055 and 0.05, so a total of 17.3%.

If you set the overall losses too low then predbat will use the battery too much, losing you money on the conversion in and out, if you set it too high it will use grid more when the battery might have been cheaper.

The best way to get your own answer is to measure the charge in and out but its not made easy by solar generation (having less lossses) and AC vs DC measurement differences in the inverter data. If I look at my total battery charge in December its 715.8 kwh and total discharge its 604.9kWh. (715.8-604.9)/604.9 gives 18.3% total battery losses.
What does this say for sure, I don’t know, but it does err me towards the circa 20% losses than 13%.

L
#494 Leeshore

geoffreycoan The best way to get your own answer is to measure the charge in and out but its not made easy by solar generation (having less lossses) and AC vs DC measurement differences in the inverter data. If I look at my total battery charge in December its 715.8 kwh and total discharge its 604.9kWh. (715.8-604.9)/604.9 gives 18.3% total battery losses.
What does this say for sure, I don’t know, but it does err me towards the circa 20% losses than 13%.

Just looked at my data for last year: Total battery charge is 3176.02, Total battery discharge is 2887.11. So (3176-2887)/2887.11 = 10% for Gen3 3.6 hybrid inverter with 9.5kWh battery

W
#495 Wavy Davy

Geoff, Are you including solar into the battery?
If I do that for December using your formulae my figures are +8%. If I exclude solar into the battery they are -16.67%


This is data from givenergy dashboard.

Something not quite right!

W
#496 Wavy Davy

Sorry not December for the full year...
Senior moment...
Just December figures are

So 8% losses? seems very low.

G
#497 geoffreycoan

Wavy Davy This is where it all starts to become difficult because some of the figures you get out of givtcp and see in the portal are AC figures and some are DC. It depends how they are measured in the inverter.

DC figures will be after inverter losses so should measure the battery losses

I read an article last week from Michael Podesta which I can dig out on how he measured his Tesla powerwall capacity year on year, and he looked at battery in and out but only on days where there was little solar generation. To get a true picture we have to do similar, but this is starting to get a grey area.

Might be worth starting a separate non-predbat discussion because other people have measured it before and I personally don't know whether there is a truly right way or not.

R
#498 Rbor

geoffreycoan
And looking at mine (AC3.0 inverter) for last year using GE Annual summary and your formula
I get: (4983.03–4644.11)/4644.11 = 7.3% which seems very low.

I have my losses all set at 0.04, so using Trefor's formula, I get
0.96x0.96x0.96x0.96 =0.849 and 85%
This is what Predbat will be using for its plan.
If I have debug HTML plan set, the bracketed value agree's with Trefor's formula.

So Trefor's defaults gives 0.97 x 0.96 x 0.96 x 0.97 =0.867 and 87%
0.04 for all gives 0.96 x 0.96 x 0.96 x 0.96 =0.849 and 85%
0.05 for all gives 0.95 x 0.95 x 0.95 x 0.95=0.815 and 81.5%
.... all within same ballpark.

From my annual solar production, only 10% went into my battery, 25% to my home and 65% to the grid, earning me £640 (to get me through Nov-Feb). So nearly all input into my battery is from the grid.

Rob

W
#499 Wavy Davy

geoffreycoan I agree Geoff, have just done the same calc for Jan, Feb, Nov & Dec all of which have a lower solar input, and all give rubbish figures.
I'm using 0.4 and 0.5 on my plan

R
#500 Rbor

geoffreycoan Trefor has added the above FB post to the Predbat FAQ’s; the key thing I’d take away from this is the reminder that the inverter loss acts as a double-whammy as you get inverter losses on the way in and the way out of the battery, so be careful of increasing that too much.

And this is the crunch.

I have looked in the predbat FAQs and the section on losses is excellent, read alongside the main section on losses:https://springfall2008.github.io/batpred/customisation/#battery-loss-options

Losses depend on many factory and any values that we use are at best guesstimates. For me I think 0.04 for charge, discharge and inverter looks 'about right' ... to me.

Rob

R
#502 Rbor

Wavy Davy Same here. My Dec values from GE showed only a 10 kWh difference between charge and discharge, producing rubbish results.
I have looked at GE data sheets and for AC3.0, they claim 97% efficiency. Nothing against batteries.
Using the 'hand test', my inverter gets warm to the touch when really active, much more so than batteries. My Solar Edge PV inverter gets barely warm.
But my setup is in a nice environment where temperature is rarely likely to drop below 20C.

Rob

D
#503 Daveb01

Rbor

I was on 5 all have changed mine to 4 all, looking at the evidence. Very interesting topic.

It would be even more interesting to see someone that has 2 x AIO’s and sets all 4 but gets different results because there in a different part of the country, so solar is not the same, it maybe colder, they use there battery more etc etc.

V
#504 Vestas

Rbor I have looked at GE data sheets and for AC3.0, they claim 97% efficiency. Nothing against batteries.

The batteries are probably close to 97% efficient at an ambient temperature of 25C. ie there's 3% chemical losses.

However that's a minor part of the losses. On a G1 Hybrid....

The charge/discharge circuitry in the inverter is around 85% efficient for AC charge and 90% for solar charge (full rate charge/discharge cycle).

Round trip losses for my usage are 15-20% although this is temperature and load dependent. Edit - they also appear to be increasing slightly as the system ages, but that's a subjective observation for now.

G2/G3 inverters are apparently somewhat better in terms of losses.

W
#505 Wavy Davy

Rbor My setup is a gen 1 hybrid and like yours indoors (in a cupboard in the porch), the batteries are also in the porch in a alcove under the cupboard, so batteries never get below 10, generally runs about 15 to 20 in winter.
Invertor runs a bit hotter, 30 at the moment.
Useful in winter to keep the porch frost free.

D
#507 Daveb01

@Rbor
@geoffreycoan

I have been monitoring things for the past few days and it looks like everything is back to normal.
There was an update for Octopus today, so took the plunge and updated, everything looks OK

I am not not sure about updating Predbat to v8.11.2. What’s you opinions please?
I do not need the temperature curve or settings in yaml.

If I don’t update and Trevor brings out the next update what do I do, as not been in this position before?
(Will the newest update e.g v8.11.3 contain the temperature things, so I can not get away with it?)
(Or can I install v8.11.3 and not worry about v8.11.2?)

W
#508 Wavy Davy

Daveb01 I've updated and no issues except this
2025-01-20 16:25:02.232930: Warn: Historical day 2 has 25 minutes of gap in the data, filled from 9.85 kWh to make new average 10.02 kWh (percent 98%)
which started at 10:00 long before I did the update, so all good.

G
#509 geoffreycoan

Rbor yes that's the article I was referring to. He writes some very interesting articles on heat pumps, batteries and solar panels. Packed full of analysis and detail. I've been a subscriber for a few months now.

Answering your question about 8.11.2 Daveb01 yes each predbat release builds on the one before so if you skip a version or two then when you do upgrade you get all the features of the releases in between.
I'm on 8.11.2 and seen no side effects, will be watching it tonight to see if it fixes some of the 'sawtooth' behaviours on low power charge that I was seeing on 8.11.0

@Rbor did you configure the temperature charge curve in apps.yaml when you upgraded or did you not bother given your batteries and inverter are inside the house? Just from the issues Dave had I was suspecting there might be an issue if the temperature curve isn't configured. I suppose I could remove my own config, but I need to test these fixes in 8.11.2 first

Dave probably worth you leaving it if you see no reason to upgrade and will give us the chance to check that predbat without temp curves being configured works ok

R
#510 Rbor

Wavy Davy I wouldn't worry about this.
I have seen this pattern often and I find that it works its way through the system until the historical day gap move from day to day until the end of the HA limit on historical day records (probably 10 days if you haven't changed this).
The warning should then disappear.

Rob

R
#511 Rbor

geoffreycoan @Rbor did you configure the temperature charge curve in apps.yaml when you upgraded

I have ignored the temperature curves entirely and haven't added them to my apps.yaml.
I judged that nothing would then happen.

In 'What's changed' for v8.11.0, Trefor has written:

Max charge rate temperature curve adjustments by @springfall2008 in #1869
This feature allows you to model temperature dependant charging and discharging of the battery.

I read this as the feature being optional and it was up to me to try it out if I wanted to and I have 'ignored' it. I have updated to v8.11.1 and then 8.11.2 and I haven't noticed anything untoward operating with no temperature curves..

..... I hope I am right! Do we need some guidance from Trefor here?

Rob

D
#512 Daveb01

Rbor

I thought the same, that’s why I upgraded. Bit I was not expecting the issue, so as you know I have down graded.

So we have a good test on the go between the three of us (although we have different batteries)

  1. I have not upgraded
  2. Rob has upgraded but not changed yaml
  3. Geoffrey has upgraded and updated yaml
G
#513 geoffreycoan

Daveb01 correct summary of our situations.

And yes Rob, I believed it was optional to configure the temp curve stuff in apps.yaml, but Dave didn't and had random errors setting charge and discharge rate to zero so I wondered if it was connected

After you reverted Dave, Trefor posted this bug on GivTCP https://github.com/britkat1980/giv_tcp/issues/334 - wondered if this was the same error you saw?

W
#514 Wavy Davy

Daveb01 Dave, like Rob, I've upgraded and not changed the yaml. As I have a Gen 1 Hybrid and its inside just ignored it.

V
#515 Vestas

Rbor Interestingly I sort of know the man he posted about ( https://protonsforbreakfast.wordpress.com/2025/01/05/gordon-edwards-1941-2025/ ).

Way way back in the 1990s a colleague of mine was working on the test/setup procedure for the monitors which went into the UK AWACs aircraft. Prime contractor for the consoles was Siemens and lets just say there was a BIG difference between German and English QA - ie they all got rejected by Siemens when the QA over here couldn't see a problem ("it's good enough" attitude which is still prevalent).

One of the many and varied issues was chromaticity - ie colour. Specifically white.

This ended up with NPL and my colleague investigating over the course of several months whether they needed to redefine what "white" was. The consensus was that they probably did but it'd take several years (if not decades) to get international agreement. At this point the German QA guys relented on chromaticity 😃

D
#516 Daveb01

Daveb01 So we have a good test on the go between the three of us (although we have different batteries)

I have not upgraded
Rob & Davy have upgraded but not changed yaml
Geoffrey has upgraded and updated yaml

T
#517 TX200

I'm on 8.11.1 which I believe includes the temperature curve stuff.

I've not edited the yaml.

Gen3 hybrid.

As far as I'm aware, no issues.

D
#518 Daveb01

Oh no there is now an HA Core update. So what’s the plan guys?

G
#519 geoffreycoan

Daveb01 Have a look at the readme and see if any of the bugfixes covers anything you care about. Probably not.

I will probably wait until the end of the month and upgrade to the last HA patch of the month, or may just wait until mid February and go straight to the 2025.2.2 release. There's no real benefit in taking every single patch upgrade and equally I think its prudent to wait for the first couple of releases of each version to come out to wash out any early bugs

R
#520 Rbor

Daveb01 The plan is to let @Daveb01 install it and see what happens. 😉

Leave it alone! Follow @"geoffreycoan advice above.
You don't need to risk a repeat of your panics last week. We have only just got you up and running after that.

I actually updated HA over the weekend and my system shows this:

So how am I supposed to work out whether I have the latest version of all these HA varieties?

So I don't know whether I am on latest version of Core (I don't see any HA update showing though).
Remember that I had issues with my history charts and ended up restoring back to previous version.

Out of all the updates we see, I have had more issues from HA updates than any other and I would prefer to leave them for a while.

When you do decide to update HA, take a full backup before before doing so.

Rob

H
#521 Henry3rd

I went for it!

P
#522 pacemaker

Can anyone advise how you reduce or eliminate these 15m slots? Someone asked on facebook group but not getting anywhere - want to do the same. To reduce the “on off on off” in such short spans

G
#523 geoffreycoan

pacemaker turn off 'calculate export within charge slots' - this stops most of the split export and charge slots

P
#524 pacemaker

I tried that and it seems not do what I want. It eliminates the 15m slots but then doesn’t export anything at all because it’s cheap rate. I still want it to export, just in 30m increments (assuming that would reduce register writes too?)

From

To

L
#525 Leeshore

Rbor I updated to latest version with no issues 🙂

P
#526 pacemaker

geoffreycoan

to add to my last comment, I changed my plan calculation from 24 hours to 48 hours and its eliminated any planned export slots completely by using that setting. When I set it to 24 hours it at least had export slots following the charge (even though I have NO IDEA why it would plan to do that)

D
#527 Daveb01

geoffreycoan

So leave HA alone for a bit ✅

What about Predbat ? Leave alone until the next update ✅

G
#528 geoffreycoan

pacemaker to add to my last comment, I changed my plan calculation from 24 hours to 48 hours and its eliminated any planned export slots completely by using that setting. When I set it to 24 hours it at least had export slots following the charge (even though I have NO IDEA why it would plan to do that)

I find it best to leave plan calculation on 24 hours.

Have you tried the new Calculate export slots on high import slots first? Turning this on or off?

R
#529 Rbor

Leeshore Thanks. Interesting that you are on 2015.1.3 with same other versions as me for Supervisor, etc. 2025.1.3 wasn't there yesterday for me.
2015.1.2 is fine for now and I will next update when 2015.2.2 or 2025.2.3 comes round.

Rob

D
#530 Daveb01

Well this is a first for me. I was on my iPad and got this, then Predbat updated a win win.

No email from Octopus yet though.


G
#531 Goshiki2

Daveb01 I got the same and my plan looks exactly like yours but I will quite possibly override it as 24p uplift is appalling and it’s also offset by having to use grid supply earlier than normal.

R
#532 Rbor

Same for me. I got the notification and entries in my plan.

Looks like Octopus are getting the hang of this (certainly for exporters).
375 highest bid accepted and October offered 299.

I don't really understand where the 39.00 comes from though!
I will need to tweak down my HP so that I can get the energy back at a cheaper rate.

Rob

G
#533 Goshiki2

Rbor 24+15 =39

L
#534 Leeshore

Goshiki2 Same here in Yorkshire. Glad to see predbat joined it automatically...

G
#535 geoffreycoan

Good to see that the Octopus saving session API is working correctly now and code that Trefor put in last year to automate the joining is all working fine.

Its worth noting in case you ask that Predbat uplifts both the import and the export rate by the DFS amount, to encourage it not to import either.

In my case Predbat has decided “naah, won’t bother”, even with the reduced load in the saving session period its preferring to keep the inverter in Demand mode and let the battery run the house instead of exporting. The rates immediately after the session are 73, 46, 33, 36p so a forced export isn’t going to be profitable.
I will have the heat pump off for the peak period anyway so maybe that will preserve enough for a small export, but its so not worth it.

Tomorrow’s agile rates look high again but strong winds forecast for Friday should mean we’re back to cheapness again

B
#536 browellm

Could I get some help troubleshooting my saving session as it seems Prebat is completely ignoring it. Even if it decided not to export I assume it would reserve some battery to cover demand over the session as the battery will be fully discharged before 11:30pm regardless of it covering the 17:30-18:30 slot.

It's picked up in the Octopus entity

Prebat showing the entity in the watchlist (ignore the Intelligent stuff - that's currently offline due to new car onboarding issues)

No sign anywhere in the plan of an adjustment

R
#537 Rbor

geoffreycoan Predbat is still hoping to export for me but I have more juice in the tank from 5:30pm than you. I plan to turn HP off for 5:30-6:30pm and I have my heating curve tweaked down a couple of notches all day which reduced my flow rate by 3C. At least temperature is higher than last cold spell although only up to 4C (better than –4C!) ... and the sun has just appeared.

With HP off, I hope to get through to 22:30 (22p/kWh) before any charging. So I should save about 30-35p all in! (and have helped the grid).
24p is really pathetic.

Rob

H
#538 Henry3rd

No email but!

G
#539 geoffreycoan

browellm you should have both a binary sensor and an event pointing to the saving session details:

the fact that the binary sensor shows this as a joined event does suggest predbat joined the event automatically for you OK. Nothing in the plan is weird, it should all happen once the event is joined https://springfall2008.github.io/batpred/energy-rates/#octopus-saving-sessions

anything in the predbat logfile indicating a problem?

you can always put a manual rate export and maybe predbat would then hold your battery for the DFS session instead of it running out beforehand. strange

L
#540 Leeshore

geoffreycoan I checked on octoplus website and yes I have been enrolled into the session automatically without the email:

R
#541 Rbor

Leeshore Same for me. No email but down as opted in. A lot easier with predbat automatically picking up saving session (and means I know that it is happening!)

Rob

B
#542 browellm

geoffreycoan

All seems to be as your screenshot

And nothing in the logs that I can see.

G
#544 geoffreycoan

browellm

In my logfile I see the session being joined at 12:45:

2025-01-21 12:45:01.257360: Car charging hold True threshold 6.0
2025-01-21 12:45:01.257382: Current data so far today: load 39.12 kWh import 36.4 kWh export 0.0 kWh pv 6.0 kWh
2025-01-21 12:45:01.316962: Joining Octopus saving event code EVENT_3_210125 Tue 21/01 17:30-18:30 at rate 24.0 p/kWh
2025-01-21 12:45:02.973356: Standing charge is set to 0.0 p
2025-01-21 12:45:02.973442: Fetching futurerate data from https://dataportal-api.nordpoolgroup.com/api/DayAheadPrices?date=DATE&market=N2EX_DayAhead&deliveryArea=UK&currency=GBP

And then in every subsequent run after that from 12:50 onwards:

2025-01-21 12:50:01.176738: Fetched battery temperature history data, current temperature 15.0
2025-01-21 12:50:01.177102: Car charging hold True threshold 6.0
2025-01-21 12:50:01.177142: Current data so far today: load 39.72 kWh import 36.5 kWh export 0.0 kWh pv 6.4 kWh
2025-01-21 12:50:01.237454: Joined Octopus saving session: Tue 21/01 17:30-18:30 at rate 24.0 p/kWh state False
2025-01-21 12:50:01.237528: Standing charge is set to 0.0 p
2025-01-21 12:50:01.237552: Fetching futurerate data from https://dataportal-api.nordpoolgroup.com/api/DayAheadPrices?date=DATE&market=N2EX_DayAhead&deliveryArea=UK&currency=GBP
2025-01-21 12:50:01.237640: Return cached futurerate data for https://dataportal-api.nordpoolgroup.com/api/DayAheadPrices?date=2025-01-21&market=N2EX_DayAhead&deliveryArea=UK&currency=GBP age 130.0 minutes
2025-01-21 12:50:01.237916: Return cached futurerate data for https://dataportal-api.nordpoolgroup.com/api/DayAheadPrices?date=2025-01-22&market=N2EX_DayAhead&deliveryArea=UK&currency=GBP age 130.0 minutes
2025-01-21 12:50:01.240832: Loaded 95 datapoints of futurerate analysis
2025-01-21 12:50:01.387440: Predicted future rates: ['01-21 00:00:00 => 21.35 / 14.43', '01-21 01:00:00 => 21.24 / 14.38', '01-21 02:00:00 => 21.16 / 14.34', '01-21 03:00:00 => 21.03 / 14.28', '01-21 04:00:00 => 20.98 / 14.26', '01-21 05:00:00 => 21.09 / 14.31', '01-21 06:00:00 => 25.42 / 16.28', '01-21 07:00:00 => 35.11 / 20.71', '01-21 08:00:00 => 40.14 / 23.01', '01-21 09:00:00 => 37.45 / 21.78', '01-21 10:00:00 => 34.3 / 20.34', '01-21 11:00:00 => 33.04 / 19.76', '01-21 12:00:00 => 32.12 / 19.34', '01-21 13:00:00 => 33.23 / 19.85', '01-21 14:00:00 => 35.05 / 20.68', '01-21 15:00:00 => 36.55 / 21.37', '01-21 16:00:00 => 53.99 / 27.99', '01-21 17:00:00 => 75.52 / 37.82', '01-21 18:00:00 => 85.46 / 42.36', '01-21 19:00:00 => 60.93 / 32.5', '01-21 20:00:00 => 37.71 / 21.9', '01-21 21:00:00 => 30.9 / 18.79', '01-21 22:00:00 => 25.94 / 16.52', '01-21 23:00:00 => 23.21 / 15.27', '01-22 00:00:00 => 23.06 / 15.21', '01-22 01:00:00 => 22.55 / 14.98', '01-22 02:00:00 => 22.25 / 14.84', '01-22 03:00:00 => 22.14 / 14.79', '01-22 04:00:00 => 22.1 / 14.77', '01-22 05:00:00 => 22.79 / 15.09', '01-22 06:00:00 => 27.93 / 17.43', '01-22 07:00:00 => 34.24 / 20.31', '01-22 08:00:00 => 42.04 / 23.87', '01-22 09:00:00 => 54.16 / 29.41', '01-22 10:00:00 => 61.45 / 32.74', '01-22 11:00:00 => 62.35 / 33.15']
2025-01-21 12:50:01.399046: Setting Octopus saving session in range 01-21 17:30:00 - 01-21 18:30:00 export False rate 24.0
2025-01-21 12:50:01.743080: Rate min forward looking: now 22.03 at end of forecast 22.03
2025-01-21 12:50:01.743244: Import rates min 22.03 max 109.62 average 45.05
2025-01-21 12:50:01.751165: Setting Octopus saving session in range 01-21 17:30:00 - 01-21 18:30:00 export True rate 24.0
2025-01-21 12:50:01.751519: Adding rate rates_export_override: {'start': '16:00:00', 'end': '19:00:00', 'rate_increment': -10} => 01-21 16:00:00 to 01-21 19:00:00 @ -10.0 date None increment True
2025-01-21 12:50:01.752479: Export rates min 5.0 max 29.0 average 14.25
2025-01-21 12:50:01.752518: Rate thresholds (for charge/export) are import 109.12p (0.0) export 5.5p (0.0)

Do you see a similar pattern, firstly the auto joining and secondly then details of the saving session being added to the import and export rates

Is the saving session event enabled and populated in your HA?

B
#545 browellm

geoffreycoan Hi Geoffrey, I can see nothing like that in my log

The saving session even is being picked up

And prebat has the sensor enumerated in the web app config panel

So I really don't know what's happening. I did a manual freeze charge this afternoon and a manual rates export of 39p to simulate the session, but I obviously want to crack the automation if I can.

G
#546 geoffreycoan

browellm I’ve spotted the problem your event name is wrong

According to the documentation https://bottlecapdave.github.io/HomeAssistant-OctopusEnergy/entities/octoplus/ it should be event.octopus_energy{{ACCOUNT_ID}}octoplus_saving_session_events

yours is named event.octoplus_saving_session_events_{{ACCOUNT_ID}}

if its named wrong then this is why predbat can’t find it from the binary sensor

D
#547 Daveb01

@geoffreycoan
@Rbor

While having a cuppa I have noticed something any ideas please?

Predbat set to charge for 4slots but SoC not changing much. Charge is set to 10000/discharge 6000.

Then later charging for 5 slots but SoC looks correct, getting to 100%

R
#548 Rbor

Daveb01 The priority seems to be to get to maximum SOC as late as possible.
Rates tomorrow are high from 07:30 and especially from 09:00.
Rates won't subside until 21:00. Horror show if you don't have a battery/batteries (and we do).

Predbat has decide to go into tick-over late evening and just after midnight before taking off later in the night. There is little difference in ratesthroughout the night.

.... and of course, remember my mantra: This is predbat's plan and he will change the plan to suit circumstances. We are looking forwards a long time in the future. Remember also the 4 hour rule of @geoffreycoan (Hope I am right there!)

So nothing untoward. Leave it alone!

Rob

G
#549 geoffreycoan

Daveb01 this is one of predbat’s oddities in the way it plans ‘do nothing’ activities

you get a mixture of freeze charge (maintaining soc) and planned charge with soc the same as the current soc. They amount to much the same, keep the battery where it is and import from the grid - the agile rates are quite flat and there’s no financial benefit to either discharge or charge the battery until the slightly later cheaper slots at 01:30 and 03:30 when Predbat plans a ‘real’ charge

G
#550 geoffreycoan

Well good news, bad news this evening

Good news is I took the opportunity of the DFS session and the heat pump being turned off to relocate the control panels from the loft above our bedroom to inside my wardrobe. No more having to get the loft ladder out and climbing into the loft to change the flow temperatures.
The inlets from the ashp’s come into our loft, the pipework, pumps, buffer tank, fusebox and electricity meters are all still up there, I just relocated and extended the cables for the controls.

Bad news started off well, Predbat was oblivious to the heat pump being turned off so didn’t feel motivated to export in the DFS session. I thought I’d be OK as long as I kept the heat pump off 8:30 so did a force discharge for the two DFS slots.
And then I saw my son had just come out of the (electric) shower. Argh, peak rate showering, what was he thinking of? Fortunately he started the shower at 6:40 so just missed the DFS session. Imported 0.4kWh though as the shower draws 9kWh.
Clearly going to have to go through the electricity training with the family again…

In the end exported 4.8kWh so a steamy £1.87 coming my way. Really not sure its worth it but I’d have had the heat pump off anyway to save electricity so I suppose it was.

Think I will leave the heating on overnight tonight to get some heat into the fabric of the house and then turn it off for most of the day tomorrow.

W
#551 Wavy Davy

Geoff, I don't have any "states" message regarding saving session, however predbat did discharge for the session and I do have the bottlecap Dave's sensors mentioned, so all good. But reading down I notice that he also has Free Electricity Sessions sensors.
At the moment I don't have these and enrol for them using your dashboard entities. Does Bottlecap Dave's system now do this automatically? if so what do you have to do to include it?

D
#552 Daveb01

geoffreycoan
@Rbor

I now understand what your saying and I should RTFQ, Mr Bat is planning to Charge but may not, he has also seen more slots later that look better. 👍🍺🍺

G
#553 geoffreycoan

Wavy Davy Geoff, I don't have any "states" message regarding saving session, however predbat did discharge for the session and I do have the bottlecap Dave's sensors mentioned, so all good.

There isn’t a special state for the saving session, what you see is an increased import price and export price for the period of the session. Predbat then treats these as price overrides and handles them as normal, avoiding importing in those periods and exporting if it thinks its worth it.

But reading down I notice that he also has Free Electricity Sessions sensors.
At the moment I don't have these and enrol for them using your dashboard entities. Does Bottlecap Dave's system now do this automatically? if so what do you have to do to include it?

Predbat can auto enroll to the free electricity events, note this only covers the national free electricity events, not the regional power up events that occur in the East of England and Scotland.

You’ll need to configure it in apps.yaml as per the documentation https://springfall2008.github.io/batpred/energy-rates/#octopus-free-power-up-events

Personally I don’t do it that way because I (a) have to handle power up events that occur in my region so need my own solution for that, and (b) I like to change the tariff for the grid import utility meter from ‘day’ to ‘free’ so I can account for the free electricity separately in the energy dashboard
I could have probably written something to handle this from the bottle cap dave sensors but the free electricity events are so rare it wasn’t worth it for me.

D
#554 Daveb01

geoffreycoan

So had a look at mine and I only have 2 enabled of 9. Should I have others?
The easy way would be by numbers if you think I need others please. (4 & 9) enabled.

#555 PianSom

geoffreycoan Predbat can auto enroll to the free electricity events, note this only covers the national free electricity events, not the regional power up events that occur in the East of England and Scotland.

And - ta da! - (some of) the North East. For a while anyway.

https://octopus.energy/power-ups-north-east-england/

G
#556 geoffreycoan

PianSom thats good, I didn't know about that. Hope they extend the trial.

2 months seems a short trial though, the Eastern region was initially for a year, and it's been proven in two other regions already

G
#557 geoffreycoan

Daveb01 So had a look at mine and I only have 2 enabled of 9. Should I have others?
The easy way would be by numbers if you think I need others please. (4 & 9) enabled.

I have 5, 6 and 9 enabled. I probably don't need 5 but you definitely need the saving session binary sensor enabled

B
#558 browellm

geoffreycoan Hi Geoffrey, good spot but I haven't changed anything in the Octopus integration or the apps.yaml

I do have both events in my Octopus entities

G
#559 geoffreycoan

browellm Hi Geoffrey, good spot but I haven't changed anything in the Octopus integration or the apps.yaml

I do have both events in my Octopus entities

You have a saving session event and a free electricity event in the screenshot above.

I believe the saving session event being a name that is not as per the Octopus integration documentation (link above) is why Predbat can’t auto-join you and auto-detect the saving session. The apps.yaml contains the saving session binary sensor name, ONLY the binary sensor name, and its from that that Predbat finds the event, but with yours being named wrongly is I strongly suggest the reason for your problem.

Rename the event to the correct name and all should be well.

Why is your event named wrongly, I don’t know, maybe you renamed it by accident, maybe the integration glitched or the naming convention has changed (but I and lots of other people have it all working fine).

T
#560 TX200

It's crazy that I'm running from the grid when it's 28-32p/kWh 🤣

But i guess it's a lot better to do that than run out at 6pm.

Hoping for some cheap prices at the weekend!

G
#561 geoffreycoan

TX200 Yeah crazy, I’ve got freeze charge planned all day now until 4pm.

I had the heat pump turned on overnight to warm the house up and then its going off at 7:30 otherwise I’d be on a £30 import bill.

At least we’ve got storm Eowyn coming on Friday, agile rates predicting to drop to 1.5p then a week of more normal

R
#562 Rbor

Wednesday am: I got up early and have prepared a big pan of home-made vegetable soup by 7:30am to keep below 40p/unit for cooking.
Soup will sit there all day, with some heated up in microwave for dinner after 7pm, if not later.
I have turned my heat pump heating curve down to 0.4 (so HP not off) and I have targeted house temperature down to 19C, which it may not reach.
A bit of an experiment with unit costs over 50p/kWh from 9 am to 7:30 pm.
At 8:30am, predbat went into 'Demand' and is hoping to stay there for 12.5 hours until 9pm, with Solcast predicting 3.4 kWh for today with current generation still at 0kWh!
If it gets too cold 🥶, heating will have to be tweaked up.

I reckon I made just over 50p on DFS yesterday by exporting 2.7 kW in the hour and switching off HP. Looking at today's rates (highest so far), there should be another DFS session today but how high will utilities dare to bid?

Just read an article about how energy costs across interconnectors have shot up, with countries bidding against each other for the energy. The lack wind has affected most of Europe and countries are fighting each other for what is available.
There an interesting graphic showing our live energy flow here https://www.energydashboard.co.uk/live
Winds should start to reappear during tomorrow and then I am hoping we will be 'back to normal' rates (with some plunges?)

Rob

R
#564 Rbor

Nice to see my DFS rates for today from 16:30 to 17:30. Looks like 56p/kWh premium today – better than 24 p.
Looks like Octopus bid 700.

And to celebrate, the sun has come out.
..... and Nordpool rates look good tomorrow – well down but little below 20p (and nothing above 30p)
😃

Rob

G
#565 geoffreycoan

Rbor I'm going to have to create an automation to adjust my predbat load when I turn the heat pump off as predbat obviously knows no different and with both yesterday and today's DFS sessions it decided not to force export and keep the soc to run the house.

With the heating off I've been exporting today. I am sort of wondering if I should go onto Agile export for times like this. Back onto 15p export as we come out of winter but I'm only exporting in exceptional circumstances at the moment so maybe make a bit more whilst I am.

G
#566 geoffreycoan

geoffreycoan

Took me ages to find how to locate the agile export rates.

Eventually found it in https://www.octopriceuk.app/agileOutgoing

And of course as well as getting more when exporting in the day I'll get a higher base export payment for DFS sessions

Also noticed that the Octo Aid app is now showing Agile price predictions. Plunge prices on Friday on Monday 😊

G
#567 geoffreycoan

geoffreycoan I made the leap onto Agile Outgoing!

Messaged Octopus on Twitter and 5 minutes later they replied to say they've made the change.

Decent customer service 👍

Will have to think about the energy dashboard, might just leave it on 15p as its simpler

D
#568 Daveb01

Predbat is very Demanding today (sorry for the pun)

D
#569 Daveb01

geoffreycoan

A question please. I got the HA notification at 12:00 Predbat signed up.
I got the email from Octopus at 14:00 saying do I want to opt in (if I don’t opt in I don’t get Octopoints)

My question is - if I let HA and Predbat do its thing, and don’t press the opt in, in the email will,I miss out.
Is there a way of checking I am auto opted in from the Predbat sign in via Octop app before I press the button again?


T
#570 TX200

You can check via the octopus website, octoplus section.

B
#571 browellm

geoffreycoan If fixed mine earlier today, thanks for the help.

R
#572 Rbor

geoffreycoan mmmm… got me thinking ….
May well do the same through X.

Rob

B
#573 browellm

Rbor @geoffreycoan that seems like a very sensible idea, I export next to nothing during winter.

G
#574 Goshiki2

Quick question: do I need to do anything in apps.yaml for Predbat to pick up the Agile export tariff? I moved from fixed this morning but Predbat is still showing 15p fixed.

T
#575 TX200

Goshiki2

If octopus website shows the new tariff for you, restart home assistant should kick it into life.

Restarting the octopus integration (bottlecapdave) will be what will force it to update quicker, but I can't remember if you can restart that on its own.

I
#576 Ivan

geoffreycoan Are you able to switch back to the fixed 15p/kWh export with out issue? TIA.

T
#577 TX200

Goshiki2

Or if the above doesn't work, you could always add a rate override like below for the specific slots you want to export on

`
rates_export_override:

  • date: '2025-01-22'
    start: '17:30:00'
    end: '18:00:00'
    rate: 90

    For pv estimate, leave... `

G
#578 Goshiki2

TX200 It’s showing on the Octopus app and website but hasn’t updated Predbat on a HA restart.
Edit: it’s just updated. Thanks for the help

R
#579 Rbor

geoffreycoan Still pondering on whether to go to Agile ongoing but I have till end of today as a changed tariff starts at midnight of the day that you change.

I think today could be a one-off for rest of winter and my export is limited in an hour from a single AC3.0 (I got 2.7 kWh yesterday). I could need to change back fairly soon after a change as we enter the real export season.

I always go to energy-stats.uk for tariffs.
See: https://energy-stats.uk/octopus-agile-outgoing-export-yorkshire/
(selecting your region)

Rob

G
#580 geoffreycoan

Rbor I know I jumped quickly today, but I think it’ll be worth it for a few weeks or so to be on agile export. Whilst the heat pump is on and its cold I really don’t export anything at all, its just on these super-high prices or DFS sessions that I will turn the heating off and potentially export a bit. And might as well take the better price available.

Downside is less opportunity to make money from plunge pricing events - but we’re not exactly inundated with those at the moment

Bit weird though, my Octopus account shows I am on the new tariff, the Octo Aid app recognised it as well, but the Octopus integration is still showing me as being on the fixed 15p export - but with some weird start and end dates that make no sense

According to the integration documentation it should update automatically following an API poll of my account data every 60 minutes https://bottlecapdave.github.io/HomeAssistant-OctopusEnergy/faq/
Certainly when I moved from Flux to Agile it all happened automatically and I didn’t need to do anything, reboot HA or anything.

I think I’ll leave it and see how long it takes to change. Nothing in the HA Core logfile. Might be a bug in the integration?

L
#581 Leeshore

geoffreycoan Have you restarted home assistant or the octopus integration? That might update the prices.

G
#582 geoffreycoan

Leeshore No I haven’t done either, and I shouldn’t have to, the Octopus Integration should update with the new tariff automatically. I’ve turned debug on to capture some logs because I suspect this may be a bug.

R
#583 Rbor

geoffreycoan Do keep us all updated on your tariff change.

Rob

B
#584 browellm

geoffreycoan I moved to Outgoing Agile this afternoon too. I didn't have the patience to wait though and restarted the Octopus integration.

I must admit it's nice to have slightly more interesting Predbat plans on the horizon.

#585 PianSom

With another named storm on the way with, I guess, an attendant risk of power outages what settings are Predbat users planning on implementing on Friday morning?

At this time of year I usually start the day fully charged then run down during the day, and start importing in the late afternoon. The forecast for this area is currently for the wind to hit around the middle of the day.

I'm thinking moving input_number.predbat_best_soc_keep to about 75% of capacity, and moving input_number.predbat_best_soc_keep_weight to 90% or more. I'd make the changes first thing in the morning, and revert them to defaults late afternoon (assuming no outages). The net effect should be to move my expected evening grid usage to the morning.

Any thoughts on this?

In particular, what will Predbat do if there is a grid outage? I assume that it will give up on trying to retain charge and just let the battery flow to load?

G
#586 geoffreycoan

PianSom I'm thinking moving input_number.predbat_best_soc_keep to about 75% of capacity, and moving input_number.predbat_best_soc_keep_weight to 90% or more. I'd make the changes first thing in the morning, and revert them to defaults late afternoon (assuming no outages). The net effect should be to move my expected evening grid usage to the morning.

That should work although I’ve not tried the best_soc_keep_weight so I don’t know how effective it is as keeping the soc at a required level.

Another option is to set best_soc_min but side effect of this is that the battery will grid import regardless of rate if your load causes the soc to drop below the specified level

The approach detailed in the documentation is to increase input_number.predbat_set_reserve_min https://springfall2008.github.io/batpred/customisation/#inverter-control-options

PianSom In particular, what will Predbat do if there is a grid outage? I assume that it will give up on trying to retain charge and just let the battery flow to load?

Firstly assuming that your wifi and home assistant server are backed up with your battery so Predbat can keep running! To my knowledge it doesn’t have any ‘grid fail’ detection (maybe this could be a feature request) so it will keep on trying to control the inverter as normal. The inverter will go into EPS mode and will ignore any control commands. You might get some interesting rejections from givtcp that predbat then complains about.

S
#587 SamM

Changing either predbat_best_soc_keep or predbat_best_soc_min seemingly makes no difference to my plan, predbat still intends to use the battery down to 4% (my reserve limit).

Changing predbat_set_reserve_min does do what I intend to do, which is reserve 50% of battery capacity whilst the storm passes.

B
#588 browellm

SamM Changing either predbat_best_soc_keep or predbat_best_soc_min seemingly makes no difference to my plan,

They're used for planning purposes, not to impose hard limits on the battery. See the documentation for further info.

S
#589 SamM

browellm

Changing these values make no difference to my generated plan if I have them set to their defaults (0 for predbat_best_soc_min and 0.5 for predbat_best_soc_keep) or at 6.0 for both (which is the value for both in the plan I've posted a screenshot of above)

#590 PianSom

geoffreycoan Another option is to set best_soc_min but side effect of this is that the battery will grid import regardless of rate if your load causes the soc to drop below the specified level

As I'm on IOG (not Agile) my import rate is known. Even though it's recommended I've always been a bit nervous about input_number.predbat_set_reserve_min not allowing discharge below the value set ever - even in a grid outage. There is no point in saving 75% for a rainy day if it's pouring!

geoffreycoan The inverter will go into EPS mode and will ignore any control commands. You might get some interesting rejections from givtcp that predbat then complains about.

That is interesting, and hadn't occurred to me. Perhaps when the AIO goes in to EPS (aka Island) mode it ignores not only all incoming GivTCP commands, but also ignores the reserves that have been set. Wish there was some docs that GE had produced which set this stuff out.

As ever, thanks for your thoughts.

SamM Changing either predbat_best_soc_keep or predbat_best_soc_min seemingly makes no difference to my plan, predbat still intends to use the battery down to 4% (my reserve limit).

As per Geoffrey/Trefor's docs there should not be any change of plan for the next 4 hours in any case. But as I said, I wonder if best_soc_keep_weight needs to be upped also.

S
#591 SamM

PianSom input_number.predbat_set_reserve_min not allowing discharge below the value set ever

That's not how the GE battery reserve works. The battery will allow the reserve to be used in the event that it is in EPS/Island Mode.

As per Geoffrey/Trefor's docs there should not be any change of plan for the next 4 hours in any case

Yeah, I've read that section of the docs. Which is why I circled in the plan the prediction that the battery will be discharged to the 4% reserve tomorrow (Thursday), well over 4 hours away.

As I say, setting these values doesn't actualy seem to make any difference (versus the default values) to the amount of charge the battery intends to hold (either in the short or long term).

G
#592 geoffreycoan

SamM Changing either predbat_best_soc_keep or predbat_best_soc_min seemingly makes no difference to my plan, predbat still intends to use the battery down to 4% (my reserve limit).

Changing predbat_set_reserve_min does do what I intend to do, which is reserve 50% of battery capacity whilst the storm passes.

Ah OK, I went and re-read the documentation. I knew that best_soc_keep is an advisory soc level to keep and predbat can let the soc level drop below this. As PianSom highlights you can increase the best_soc_keep_weight to increase the requirement to maintain this soc level. Increasing it to a high level may do what you want it to do.

But best_soc_min doesn’t operate quite as I expected it to do, here’s the doc extract:

input_number.predbat_best_soc_min (expert mode) sets the minimum charge level (in kWh) for charging during each slot and the minimum force export level also (set to 0 if you want to skip some slots). If you set this to a non-zero value you will need to use the low rate threshold to control which slots you charge from or you may charge all the time.

So it controls the minimum amount of SoC to charge by or to export down to. House load could cause this to be breached. If you truly want a specific amount to be reserved, set input_number.predbat_set_reserve_min

PianSom That is interesting, and hadn't occurred to me. Perhaps when the AIO goes in to EPS (aka Island) mode it ignores not only all incoming GivTCP commands, but also ignores the reserves that have been set. Wish there was some docs that GE had produced which set this stuff out.

That is my understanding, when the inverter goes into EPS/island mode, the battery reserve is ignored and the batteries will continue to discharge down to the battery cutoff % limit - number.givtcp_INVID_battery_power_cutoff
(which also defaults to 4%)

G
#593 geoffreycoan

Rbor Do keep us all updated on your tariff change.

Rob

Despite leaving it several hours the new export tariff wasn’t coming through to the Octopus Integration, so I tried reloading the integration and this fixed it, its now showing me a wide variety of export rates !

I can see that this isn’t a tariff for normal grid exporting, most of the time the rate is lower than the 15p rate, only in the peak is it better (and I have a -5p rate offset in my apps.yaml to discourage export in the peak period).
The difference between agile import and export isn’t consistent either, its around 10-12p in the day but widens to 20p in the peak, but some of the times it is different. Must be a different supply and demand calculation.

Turns out no changes needed to the Energy dashboard as I am already using ‘entity with the current rate’ (sensor.octopus_energy_electricity_xxxx_export_current_rate) in my dashboard config.

Today I exported 2.5kWh in the first half hour of the DFS session at 94p and 2.3kWh in the second at 57.8p, so I calculate the export income to be £3.68 vs 72p I would have got on fixed outgoing (plus DFS payment of 56*4.8=£2.69 on top). Kinda makes it feel more worthwhile now.

I did look back at my export history and January 2024 I was exporting quite a bit but then there were quite a few free electricity power up days so I think quite a bit of that was from plunge pricing. This month excluding the DFS events I have hardly exported anything, a couple of days a kW or two, but nothing material so at the moment it seems like I’m not missing out.

And as browellm says, it gives Predbat something more to do

H
#594 Henry3rd

I have Nochrg on my plan at the moment, but it is clearly charging. This is not something I have seen before.

H
#595 Henry3rd

Now gone, did I imagine it?

R
#596 Rbor

Predbat thinks every 5 minutes. The plan is a future prediction based on evidence such as solar prediction, rates, etc.
The plan may need to be modified based on what actually happens such as sun coming out, turning on oven for load, etc.

The plan is a prediction which Predbat reviews every 5 minutes …. or at least, this is what I think is happening …..

Rob

G
#597 geoffreycoan

Rbor Correct except

Rbor The plan is a prediction which Predbat reviews every 5 minutes

(Assuming you haven’t changed the default config), Predbat executes the plan every 5 minutes but re-evaluates and re-calculates it every 10 minutes. You can see this in the log with every other run saying something like ‘plan not updated as less than 10 minutes since last update’

R
#598 Rbor

geoffreycoan Thanks. Nice to see that I got something correct here but also that I have learnt a bit more about how predbat works.

I have looked in predbat log and found this repeating pattern every 5 minutes:

2025-01-23 02:30:06.329951: Plan was last updated on 2025-01-23 02:20:00+00:00 and is now 10.0 minutes old
2025-01-23 02:35:06.561986: Plan was last updated on 2025-01-23 02:30:00+00:00 and is now 5.0 minutes old

Coming back to the original query Henry3rd:
In 'What does Predbat mean': https://springfall2008.github.io/batpred/what-does-predbat-do/, we have:

No Charge - A charge where the target SoC % is lower than the current battery SoC level so there will be no charging unless the usage is unexpectedly high.

What does Nochrg really mean? The description sates that it is a 'charge' ..... but then 'no charging' takes place.
Isn't it really just part of the jack-of-all-trades: 'demand'?

Rob

G
#599 geoffreycoan

Rbor What does Nochrg really mean? The description sates that it is a 'charge' ..... but then 'no charging' takes place.
Isn't it really just part of the jack-of-all-trades: 'demand'?

No its different,

Like the example above, assume no solar to complicate things and assume current SoC is 15%.

With a Demand setting Predbat is just going to let the battery discharge according to house load. There is no limit set to a Demand so after the Demand period the SoC will be lower even if its fraction of a % lower.

With a No Charge the action taken by the battery will depend on the house load and the limit that Predbat sets.

Let’s say Predbat sets the No Charge limit to 11% as above. If the house load over the period is 3% then at the end of the period the SoC will be 15-3=12% and no charging will have occurred as SoC is still > limit.

If the house load was 5% then at the end of the period the SoC would (without intervention) have dropped to 15-5=10% but with the No Charge set the battery will charge back to the 11% limit. So there will have been charging.

How useful this is, IDK but its in Predbat’s repertoire

H
#600 Henry3rd

geoffreycoan Thanks, every day's a school day with Predbat

#601 PianSom

geoffreycoan The approach detailed in the documentation is to increase input_number.predbat_set_reserve_min https://springfall2008.github.io/batpred/customisation/#inverter-control-options

In prep for the impending storm I have been playing with this setting this morning. As a reminder -

I set it to 75% and the battery duly supplied load down to that level then switched to grid. I then moved it down to 50% and let the battery supply load until the SoC was 65%, at which point I moved it back to 75%. I was expecting the battery to start charging. But it didn't. Instead it plans to hold at 65% until tonight's overnight charge, then hold at 75% through tomorrow.

Moral - if you are going to follow the suggestion to use this setting for a possible grid outage then be aware that if the current battery level is lower than the setting then it won't top up.

G
#602 geoffreycoan

PianSom I have updated the documentation to make this clearer and advised that you would need to instruct Predbat with manual charges if required https://github.com/gcoan/batpred/blob/main/docs/customisation.md

You might want to submit it as a feature request to Trefor that Predbat takes account of this in creating the charging plan. At least its better explained now

G
#603 geoffreycoan

geoffreycoan BTW I raised a github issue on the Octopus Integration not picking up the new tariffs automatically and only doing so when I reloaded the integration.

Reply back today thanking me for including the debug logs and says he’s identified the bug https://github.com/BottlecapDave/HomeAssistant-OctopusEnergy/issues/1184

Nice low Agile rates overnight tonight, but to my surprise I noticed the predicted import rates were lower than the export rates:

And then I realised that I needed to change the line futurerate_adjust_export: False to ‘True’ in apps.yaml for Predbat to use the norddata prediction of future agile export rates as well as the import rates, and it works well:

The Friday morning export slots will disappear as the plan rolls forward and Predbat realises there is house load and peak rates later on on Friday.

R
#604 Rbor

geoffreycoan And then I realised that I needed to change the line futurerate_adjust_export: False to ‘True’ in apps.yaml for Predbat to use the norddata prediction of future agile export rates as well as the import rates, and it works well:

So is this something that we should all do? (After much deliberation, I stayed with Outgoing 15p fixed)

Thanks

Rob

T
#605 TX200

Rbor yeah 15p would now be variable.

I moved from agile outgoing recently to 15p variable.

G
#606 geoffreycoan

Rbor So is this something that we should all do? (After much deliberation, I stayed with Outgoing 15p fixed)

You only need to change this line in apps.yaml if you are on agile outgoing so Predbat predicts the future export prices based on norddata info. And I’ll need to change it back when I move back to 15p (variable) outgoing

N
#607 Northwarks

geoffreycoan So is this just that single line or the whole section? Then the obvious question is how will I know it's using the data ? 🙂

G
#608 geoffreycoan

Northwarks geoffreycoan So is this just that single line or the whole section? Then the obvious question is how will I know it's using the data ? 🙂

I already had Norddata setup to predict the Agile import rates in my apps.yaml:

  futurerate_url: 'https://dataportal-api.nordpoolgroup.com/api/DayAheadPrices?date=DATE&market=N2EX_DayAhead&deliveryArea=UK&currency=GBP'
  
  # futurerate_url: 'https://data.nordpoolgroup.com/auction/gb-half-hour/prices?currency=GBP'
  # futurerate_url: "https://dataportal-api.nordpoolgroup.com/api/DayAheadPrices/singleAreaHistory?date=2024-10-15&market=N2EX_DayAhead&deliveryArea=UK&currency=GBP"
  # futurerate_url: 'https://www.nordpoolgroup.com/api/marketdata/page/325?currency=GBP'
  futurerate_adjust_import: True
  futurerate_adjust_export: False
  futurerate_peak_start: "16:00:00"
  futurerate_peak_end: "19:00:00"
  futurerate_peak_premium_import: 14
  futurerate_peak_premium_export: 6.5

And in the above plan you can see that once the Norddata prices become available about 10am, the future Agile import rate predictions have a small set of scales symbol next to them - can see in the screenshot above.
However the export rates have just been rolled forward and so have a question mark next to them.
Setting the above line to futurerate_adjust_export: True and Predbat uses norddata for the export rates as well and you can see the export rates change and have the scales alongside them as well.

Explanation of these symbols in the Predbat plan documentation

N
#609 Northwarks

geoffreycoan Yep that's applied a very different plan - Every day a school day ! Thanks 🙂

D
#611 Daveb01

PianSom

Thank you for this, you have explained it very well. As I have 2 x AIO’s I used this method during the last storm as it makes it easier for me.

2 x 13.5 = 27 kWh I have the reserve set to 5% instead of 4%. So I get to use 25 kWh instead of 27. The last storm I just upped the reserve to 50%. Once the storm past I just put it back to 5%. If I had to mess around with to many settings and things did not work or Predbat did things not expected then it would have been a nightmare for me.

So thank you for messing around with settings and explaining them.

#612 PianSom

Daveb01
You are very welcome.

Economic case notwithstanding, I am thinking of finally ordering my second AIO next week. I’m waiting to hear back from my DNO about whether they will increase (or possibly even decrease!) my export limit if I go ahead. Don’t know if they’ll even answer me …

Can I ask what you found the going rate to be for a second unit? I have been quoted slightly over 6k

D
#613 Daveb01

PianSom

I have a good relationship with my Installer (as the misses makes cake when he visits)
As there was a deal at the time, free GE EVC, he just got the AIO and free EVC for £4700.

Then later on did the wiring and commissioning both. £845, as trunking was already there and AIO bolted to wall when delivered.

Have a look at this post as well.

https://community.givenergy.cloud/d/4706-aio-secondthird-battery-install/176

#614 PianSom

geoffreycoan You might want to submit it as a feature request to Trefor that Predbat takes account of this in creating the charging plan.

Done

L
#615 Leeshore

Since the most recent updates the number of registry writes has significantly decreased. Initially I was averaging about 90, more recently 50 but yesterday only had 22. My overall average now since starting is 69....

G
#616 geoffreycoan

Leeshore I wouldn’t say mine has halved because there is still quite a variation day to day, but yes, the number of inverter writes do appear to have dropped a bit

Graph for January - bear in mind that I have two inverters so my numbers are always doubled

Trefor has made some changes in 8.11.2 in response to an issue I raised about the charge rate being changed unnecessarily overnight. Its better but not perfect yet, so I expect there will be further changes that will further reduce the number of writes https://github.com/springfall2008/batpred/issues/1875

D
#617 Daveb01

Predbat had a bit of a fit at 15:10, but looks like it sorted its self by 15:16 phew.

R
#618 Rbor

Leeshore I am averaging 62 writes per day.

My max has been about 180 and min 10-20.
All depends on inverter activity prompted by predbat and slot rates.

Rob

G
#619 geoffreycoan

Had HA go off into the wilderness today for no obvious reason. The companion app and browser both said ‘reconnecting’ but yet the VM showed it appeared to be running.

Fortunately I had got Putty SSH access working at last after ages of not being able to connect (In the HA SSH add-on I had set up private key authentication as well as password authentication and it doesn’t like having both, deleting the private key and it now works).
So was able to SSH and try and poke around and see what was happening.

ha core log didn’t show anything meaningful or obvious

ha core check just hung for ages and never finished; I opened another SSH window and did ha supervisor logs which said that the core check identified problems with the File Editor add-on and was restarting it, and it said core wasn’t running but it said this several times but yet the core check didn’t finish

ha core restart and ha core stop both just gave errors that there was another process already active

ha supervisor restart worked OK

and then I did ha core restart and HA came back

No idea. Yesterday I was running a test HA instance alongside my production one and maybe that caused things to run out of memory, but I’d shut the other VM down last night and HA had run all night and most of the morning without issues so no real idea

D
#620 Daveb01

Hi all, not sure this is the right post (Predbat) for something about SolarEdge, so happy to be told off.

There was an update in HA for SolarEdge Modbus today. I have updated and it needed a HA restart. When HA came back up it had a warning. Very good process and easy to sort, so fyi only if you have SolarEdge Inverter.

G
#621 geoffreycoan

I've seen similar on other integrations that the unit of measure changes and you get the slightly scary 'what do you want to do' alert

R
#622 Rbor

geoffreycoan Weird and no idea.
Just keep this away fro me!

Rob

R
#623 Rbor

Daveb01 Strange.
I have SolarEdge modbus but I only use sensor.solaredge_modbus_ac_energy_kwh.
I did update to solarEdge modbus v2.0.0 today
l do have this ac_var entity but I have it unenabled so didn't come across your 'fix it' screen.

Looking on Github, it looks as if there have been some SolarEdge models issues recently:
https://github.com/binsentsu/home-assistant-solaredge-modbus/issues
I know that there was initially an update to SolarEdge modbus that required HA v2025.1 to work.

Rob

R
#624 Rbor

Nice Solar day today with 15.6 kWh, my highest since 27th October 2024. 😎
I will bank that with Solcast promising me 2–3 kWh for each of the next 4 days. 😨

Rob

H
#625 Henry3rd

With all the predbat changes and temperature curves I have got myself confused over a couple of YAML settings.
Namely.
Inverter max AC limit (one per inverter). E.g for a 3.6kw inverter set to 3600
If you have a second inverter for PV only please add the two values together
inverter_limit:
- 5000

Export limit is a software limit set on your inverter that prevents exporting above a given level
When enabled Predbat will model this limit
export_limit:

  • 3600

Are these settings right? I have a Hybrid Inverter 5.0 Gen 3 with a 9.52 kWh battery version 3017

G
#626 geoffreycoan

Henry3rd inverter limit is correct for your 5kW hybrid inverter

You don't need to set export limit unless your DNO imposed an export limit that your installer configured when commissioning the inverter.
I have this commented out in apps.yaml

T
#627 TX200

Does anyone else see this when their battery is at 100%, lots of small charges?

D
#628 Daveb01

Just seen the latest update. I have a question please.

Will it alert you for all warnings Yellow, Amber and Red?
Will it save your battery for all these events?
Can I modify it to only do Red warnings?

T
#629 TX200

TX200 ...
Could it be the cause of the 100 hidden errors on the inverter menu item in the givenegy portal?

I can't see the errors in the Giv logs, but guessing they are high voltage alerts.

G
#630 geoffreycoan

TX200 Does anyone else see this when their battery is at 100%, lots of small charges?

I see very similar, the SoC bobbles along at 100% and just under, doing small charges even though the battery is set to freeze charge. Probably doesn’t happen as quick as your graph shows but I see it often.

Daveb01 Will it alert you for all warnings Yellow, Amber and Red?
Will it save your battery for all these events?
Can I modify it to only do Red warnings?

I haven’t tried it yet, but from what I read in the documentation and the release note, you configure the apps.yaml to the warnings severity, certainty, events and types you want Predbat to take action on, and the SoC keep level you want to apply. So its entirely configurable as to what you want it to take action on.

I don’t think you can get Predbat alerts on other (non actioning) events/certainties. Might need to do your own REST poll and HA automation for that, but I haven’t looked in detail at it yet.

Looks to be another useful feature in predbat

D
#631 Daveb01

geoffreycoan

I will let you guys have a go first 👍 before I have a go as only Rabbit rating and don’t want to mess it up.

G
#632 geoffreycoan

Daveb01 I turned auto update back on a few days ago so I have already upgraded to 8.13.0, but haven’t configured apps.yaml yet. No adverse behaviour so far.

I expect Rob will upgrade and be trying it out as we speak, he likes living on the edge …

R
#633 Rbor

geoffreycoan I expect Rob will upgrade and be trying it out as we speak, he likes living on the edge …

I have had enough living on the edge recently but, true to form, I am now on v8.13.0 and have tried adding the code to my app.yaml
Initial thoughts

  1. predbat log shows that meteoalarm looks around for alerts every 5 min. This seems overkill.
  2. The list for alerts contains everything. I have trimmed mine down drastically, removing things like tsunami and avalanche.
  3. Knowing how readily the met office now generates alerts, I have trimmed back to just red.
  4. keep at 40 (meaning 40% SOC) could mean that my battery is at a much higher level than needed.

Conclusion
I have run the alerts now for an hour and I am going to comment out all the lines.
I keep an eye on weather events anyway and this is something I will probably police myself.
But the alerts are there if you want them.

Rob

T
#634 TX200

If there's a tsunami coming, I assume the best advice is turn the battery off? Water and batteries don't mix?

All those with loft based systems might be laughing (well, as long as their roof stays on). Yikes.

G
#635 geoffreycoan

I’ve configured mine as well, removing most of the warning types and only leaving those that may cause a power outage.

My apps.yaml is:

  alerts:
    url: "https://feeds.meteoalarm.org/feeds/meteoalarm-legacy-atom-united-kingdom"
    event: "(Red).*(Wind|Snow|Thunderstorm|Storm|Tornado)"
    certainty: "Likely|Expected"
    severity: "Severe|Extreme"
    keep: 40

The logfile shows its working:

2025-01-27 15:30:11.517786: Info: Processing alerts from https://feeds.meteoalarm.org/feeds/meteoalarm-legacy-atom-united-kingdom
2025-01-27 15:30:11.517734: Processing alerts for approx position latitude 52.1 longitude -0.2

I don’t think there is a problem with it running every 5 minutes as that’s how often Predbat runs and executes the plan. Haven’t checked the code but I think its very likely that the API call to meteoalarm will be cached so it only actually retrieves the data every hour or so.

There is explanation of the different awareness levels and hazard types on the metro alarm website https://meteoalarm.org/en/live/page/website-guide#list and I took a punt on the certainty and severity. I’ll have to see how this affects the plan in practice.

There is also a HA integration for Meto Alarm https://www.home-assistant.io/integrations/meteoalarm/ and an Info card https://community.home-assistant.io/t/meteoalarm-info-card/680024 if you want more visibility of the alarms in HA

R
#636 Rbor

geoffreycoan I am having a bad time currently. We now have a power cut! Been off for nearly an hour so far.

Rob

D
#637 Daveb01

geoffreycoan

Hi yah, I have added your yaml, but for the life of me I can not find the log file entries.

Here is the Predbat log and I can see the poles but I am thinking do I really need it every 5 mins, we get plenty of time for a warning. Can I add a setting to say how often I would like it polled please? Say once every hour or every 4 hours and or twice a day etc?

T
#638 TX200

The question is, do you want to make money from agile during a storm or do you want to have a full battery. Or a bit of both.

I guess play (the market) with 60% and keep 40% might not be a bad option.

G
#640 geoffreycoan

Daveb01 you need to look at the full logfile, Predbat web console / Log / All

The log tab only shows the Info, Warning and Error messages not everything

There’s no option at present to change the poll frequency. I expect Predbat only actually checks every few hours and caches the results in between. Could always put in a feature request for this.

Personally I’d prefer to just use the battery as normal and take my chances over a power cuts. But then we do get occasional power cuts here as the power lines are overhead into our village and can be affected by strong winds. I’m not sure they really coincide with red weather warnings though, but we’ll see how it works. If I find I’m getting SoC held too high and importing on high Agile prices then I’ll turn it off.

D
#641 Daveb01

geoffreycoan you need to look at the full logfile, Predbat web console / Log / All

Hi yah, still nothing in log file (all). I have had a look over a15 mins period and still nothing. I have rebooted still nothing.

Here is the yaml entry

Finally this is the first one.

G
#642 geoffreycoan

Daveb01 Click on Log on that screen top row

Then All to filter on all log messages

The alert messages appear just after predbat starts up, identified with a row with ——‘s in it. Read the logfile backwards, newest records at the top

And looking at my own logfile it appears that the metoalert is cached for 30 minutes so predbat only makes a retrieval request every half hour

D
#643 Daveb01

Daveb01 Finally this is the first one.

geoffreycoan

Thank you for this, I restarted again and kept looking and it finally appeared.

R
#644 Rbor

In case you all thought I had abandoned you, my power cuts and connectivity woes continue.
For an update, see https://community.givenergy.cloud/d/5603-lost-communication/10

I have moved predbat to monitor mode but cannot connect to my inverter anyway.
Inverter won't connect and I pings respond with time outs.
I am existing on PV power (when there is PV and also when there is an electricity supply to my house). My lighting is my iPhone flash light and a candle.
My whole street got a new 'super-duper' main electric cable 6 months ago all the way to the sub station.
I am one street in a whole country with a power grid that seems to be falling over.

So woe is me.

PS When I carry out the 'dongle dance', I hear clicks inside my inverter at one stage suggesting that connectivity is being attempted (but fails). I wonder whether the 'power off/power on/off/on' sequences have caused a surge that has wiped out something in the inverter.
My batteries were full when power first went yesterday. They are now half full from lights on front of each battery. Octopus 'usage' on my home mini shows nothing from grid, suggesting that batteries have been used. So something is happening, as long as not connectivity.

Rob

R
#645 Rbor

I'm back!

I am nothing but stubborn .......
Now to start looking at problems from others – I am certainly not the only one who has experienced problems.

😁 .... at least for a while. It is so good to get my predbat back.

Rob

#646 PianSom

Here's an odd one -

I was just looking at the apps.yaml page of Predbat's web interface. Right at the bottom (below the last uncommented item that actually exists in apps.yaml) I see this -

For the avoidance of doubt, neither the word "idle" nor the sensors referenced appear in my apps.yaml. The sensors do - happily - appear in HA, but they don't look like times there - more like integers

G
#647 geoffreycoan

PianSom these are sensors that Predbat creates for you.

Basically as Predbat supports lots of different inverter types now which have different capabilities, Trefor needed a way to easily resolve this complexity. Part of the solution is these dummy sensors that Predbat creates to handle features that your givenergy inverter doesn’t have but other inverters do have.

I raised a defect on this because Predbat was writing to these every single execution run, filling the database up. This is now fixed. I’ve still got adding these to the documentation to explain what they do, but you can ignore them.
There’s also predbat.ge_0_scheduled_discharge_enable

And of course I have all these x2 for two inverters

#648 PianSom

geoffreycoan
Yes, I imagined from the naming that that is sort-of what they are.

But why do they appear on the apps.yaml web page??

R
#649 Rbor

A happy birthday to Predbat, now 1 year old since I first let Predbat loose on my system:

🎂🎉🥳

Rob

G
#650 geoffreycoan

I'm not sure exactly when my Predbat birthday is, sometime in September 2023 I think.

I moved to Flux in June 2023, then ahead of getting my export tariff setup on 10th August 2023 , decided I needed to automate the charge and discharge so bought a Tiny PC in early August.

Watched several speak to the geek videos, he recommended the Palm solar predictor in GivTCP, he didn't really look at Predbat other than mentioning it was very complex.

I know I mucked around with my own automation scripts for a while and then tried Predbat so would have been early September 2023 I think. At the time there was no read only mode, no monitor mode, the documentation was a single page readme on github (admittedly it was a long single page).

So on installing Predbat it started controlling my inverter straight away which was quite frightening. I can remember having no idea what was going on!
Oh and there was no HTML plan either so the only way of understanding what Predbat was doing was the battery prediction Apex charts which have never been that easy to get to grips with.

Lets just say the learning curve was steep. But somehow I persevered enough to decide to move to Agile in October 2023 so I must have been happy with the results.

At the risk of sounding like a Monty Python 3 Yorkshiremen sketch, you don't realise how lucky you are nowadays.

R
#651 Rbor

geoffreycoan At the risk of sounding like a Monty Python 3 Yorkshiremen sketch, you don't realise how lucky you are nowadays.

Well I do live 800' up in Yorkshire although I lived for 18 years in East London prior to heading 'up North' to see what it was like for university.

Rob

R
#652 Rbor

geoffreycoan Trefor was be really proud of what he has created from such small beginnings.
And you appeared just in time to start compiling the wonderful documentation which guides so many of us through the process of setting up Predbat.
That is of course if you RTFM.

I swapped from Cosy to Agile on 18th Jan 2024 and started to look at ways of automating. I tried Octopus R&D labs which worked well when it picked up all the slots. I then found a lot of gossip about Predbat, investigated it and went to 'Control and discharge' several days after installing most of the bits. Predbat then takes over your life!
If you think back at my HA ability in those early days and as I graduated up to my Rabbit status, where I can help others (up to a point).

Rob

G
#653 geoffreycoan

Am trying to decide whether to stay on Agile export for a bit longer in case we get any more cold snaps, DFS days or high Agile prices where it'll be worth me exporting.

Comparing the Energy dashboard for Jan 25 to Jan 24, heat pump consumption is almost the same, the number of 'cold day big import spikes' is similar, solar generation, solar generation is down a touch, but export is massively down which must be due to the higher Agile prices this year. Last year 118KWh exported, this year excluding today, 35kWh exported.

Today was a 2.5 hour Octopus Power up day (managed to import 24kWh of free electricity!) so it skews the numbers as I drained the 5.2 and part drained the 9.5 before the power up and exported 12.4kWh today for £1.34 which is a quarter of the total month's export total. Today would have been £1.86 on Outgoing fixed.

Last year I was exporting 6-8kWh most days from about the middle of January onwards, and more in February. This year, excluding the DFS days and today, its a couple of kWh and only about half the days.

Tomorrow forecast 24.5kWh (today was forecast 16kWh and I generated 12kWh) so its only going to get more acute, I think I will wait a week or two to see

R
#654 Rbor

geoffreycoan 2024 Jan to 28th, I exported only 18 kWh. 2025 Jan to 28th, I have exported 46 kWh, so up.
But I only started Predbat at end of January 2024.
My Heat pump electricity is very similar, about 600 kWh. I have cut down (as you have) on some dates when Agile rates were high.

Rob

K
#655 KamenMacKay

Maybe someone more informed can help me out here. I've been getting unreasonably sunny days (for Scotland in January, that is) yet Predbat is still insisting on charging to 100% so I'm left (sometimes) with a good 30% charge at end of day. I'm on Octopus Go.

G
#656 geoffreycoan

KamenMacKay On Octopus Go isn’t the overnight import rate something like 8p and the export rate 15p?

So its still going to be financially beneficial to you to charge the battery overnight and then export any solar generated in the day. And at the end of the day I’d expect Predbat to discharge the excess battery charge before starting the whole cycle again

K
#657 KamenMacKay

geoffreycoan I had the same thought minutes after posting (I guess it's true what they say that sometimes writing your problem down helps you think it through better). I did have it discharging at the end of the day for a bit but I've recently just have it set to charge to save some cycles on the battery as I wasn't 'making' that much anyways. I'll turn export back on in March when I flip back to Flux. Thanks!

G
#658 geoffreycoan

KamenMacKay No problem

Trouble is there is so many different permutations of what would be the ideal plan for different people which leads to a lot of levers you can pull to control Predbat. At the end of the day its trying to optimise cost but that’s not always obvious as to why the plan is what it is

Cheers

K
#659 KamenMacKay

geoffreycoan Oh but that's the fun of Predbat with all settings you can tweak. I've learned (unlike the noobs on Facebook) to generally ignore the plan during the preceding day and only tweak settings the next morning if I'm not satisfied with the result and hope for the best for the next day!

#660 PianSom

geoffreycoan Today was a 2.5 hour Octopus Power up day

I now know how the rest of the country feels. I haven't had a Power-up since the 10th, and the only other one this month was on the 1st. This is a dramatic change for me since last year, when I had 9 in January.

I guess it is pretty impressive how locally Octopus/UKPN can target surplus energy.

R
#661 Rbor

PianSom I now know how the rest of the country feels.

Welcome to the club!

Rob

L
#662 Leeshore

What’s a power up???🤣

T
#663 TX200

I guess there's some companies that are hard to work with.

Although you'd think Wales, Western, Midlands area would be easy to onboard, given National Grid Customers took over from WPD!

Maybe we don't have enough power rather than too much.

V
#664 Vestas

TX200 Maybe we don't have enough power rather than too much.

East Mids has very little in the way of renewables - few small solar farms and that's about it. Power-Ups are all about Octopus having somewhere "local" to dump their own* windfarm(s) output.

*and ones they're contracted to take a set amount of electricity from

G
#665 geoffreycoan

PianSom I now know how the rest of the country feels. I haven't had a Power-up since the 10th, and the only other one this month was on the 1st. This is a dramatic change for me since last year, when I had 9 in January.

I guess it is pretty impressive how locally Octopus/UKPN can target surplus energy.

Yes they’re getting very localised the power up events. I’ve not had one for a while; had them on the 1st, 2nd, 7th, 12th, 13th, 14th and then yesterday and another today.

Looking at the Agile price forecast I don’t think there’s going to be one tomorrow but maybe there’ll be a DFS session.
Can’t remember when I last had a Free Electricity session, they seem very infrequent

#666 PianSom

geoffreycoan I’ve not had one for a while

My heart bleeds ... 🙂

If you have a mo, please can you explain the release notes for 8.13.1 to us mere mortals?

D
#667 Daveb01

KamenMacKay

One thing I have learned when I was on Flux, as I only had an AIO and 13.5 kw. (With losses) it was about my house load by the end of the day. If I done loads of washing tumble drier or used extra electric my battery did not last. Agile and Predbat sorted this out, but it was still 0n the edge costing me £££. I pushed the boat out and got a second AIO. I stayed on Agile and Predbat. I have thought about trying Flux again. I don’t have a heat pump yet.

Something to think about if your battery is close to what you use.

G
#668 geoffreycoan

PianSom If you have a mo, please can you explain the release notes for 8.13.1 to us mere mortals?

Yes I know what you mean, when I read the release notes https://github.com/springfall2008/batpred/releases/tag/v8.13.1 I wondered what the differences were and turned auto-update off so I could get the chance to understand them better before I let it loose on my Predbat.

What I tend to do is to look at the full differences history that’s always linked from the release https://github.com/springfall2008/batpred/compare/v8.13.0...v8.13.1 and look at what has actually changed in the release. Most of the time tend not to look at the detailed code changes, but focus on what the documentation changes are.

My take on this release is that principally its a set of changes for other inverter types and to give more flexibility to Predbat in controlling inverters that are less like the GivEnergy inverters it started from.

So for example, up to now Predbat required that the charge and discharge rate it would control for the inverter had to be an entity expressed in Watts, now it can alternatively be a entity that expresses these rates as a percentage figure.

Likewise battery SoC used to have to be a kWh figure, now it can be a percentage as an alternative.

Charge start and end time, used to have to be a select entity, can now be a time entity.

The rest of the documentation changes look to be just moving things around so they are more logically grouped in the apps.yaml manual page

I’ve upgraded to 8.13.1 and its working fine for me

R
#669 Rbor

geoffreycoan Thanks for your explanation. I freely admit that I didn't understand 'What's changed' at all!

The rabbit inside me now interprets this as %s rather than values removing issues with units, making it easier for code to be more 'cross-platform' across different inverters.
e.g. % SOC is the same irrespective of whether expressed in W or kW, or Wh, or kWh, etc.

I know that often entities come up asXXXXXX does not have a unique ID, therefore its settings cannot be managed from the UI. See documentation for more detail. So units cannot easily be changed if there is an issue.

Is my explanation along the right lines or should I return to my warren?

Rob

R
#670 Rbor

If anyone has been following my dongle woes disced in various threads during a succession of power cuts over the last few days, I have thankfully endured over 24 hours with no power cut with a solid blue light on my AC3.0 dongle.

I woke up in the middle of last night dreaming/nightmaring of a blue flashing light in an unconnected dongle ......

I am hoping to get back to some normality now. I have caught up on work today that I had not started because all the time spent trying to get my dongle and inverter connected to my network and to GE's systems.
I should now be able to get back to trying to help out/hindering others with their problems on these threads.

Phew. 😮‍💨

Rob

G
#671 geoffreycoan

Rbor making it easier for code to be more 'cross-platform' across different inverters.

Correct, its to enable the entities that Predbat uses to control the inverter to have different data types. Predbat should already accept inverter controls expressed as W ior kW, but by taking in percentages it opens up Predbat to other inverter types that are controlled differently.

I think this is why Trefor released it as a ,1 release because its not a fundamental change.

I know that often entities come up asXXXXXX does not have a unique ID, therefore its settings cannot be managed from the UI. See documentation for more detail. So units cannot easily be changed if there is an issue.

This is really a different issue. This is the way Predbat creates entities in Home Assistant they don't get a unique id so in HA you can't change the unit of measure like you can with most other entities, e.g. the givtcp ones.
I did try to persuade Trefor to change the approach, I found a solution in appdaemon that created unique ids but it would have required all the output entity handling to be changed to use MQTT which Trefor wasn't keen on.
Maybe now we don't run under appdaemon there might be more choice, maybe something to return to.

I've discovered I can upgrade my Windows 10 PC that hosts HA to Windows 11 despite it not having TPM or some of the other pre-requisites that Microsoft upgrade requires you to have.
But before upgrading I wanted to take a backup.

Spent ages a day ago looking at USB thumb drives, NAS drives, specifications, prices, etc, before realising that I could just use a USB3 to SATA adapter and Amazon was selling them for £6 !
Was going to buy a SATA drive before realising I had a couple of spare PCs in my wardrobe that had drives I wasn't using. Spent most of tonight trying to clear stuff off the PC to get down to 320Gb to backup to the SATA. And failed. Then found another laptop with a 1Tb drive in it.

Feel like I've been down one of Rob's rabbit holes tonight

D
#672 Dpe

Can anyone explain the predbat logic here:
I am on an EV tariff so same low rate from 12:30 to 05:00. Combine charge slots is set to true and low power mode is enabled.
When I look at the plan in the evening it seems OK but the plan is changed about 04:00 to increase the demanded SOC. I checked there had been no change in the solar forecast.

givtcp-log.txt
4kB

This is not the first time I have seen this, but seems a bit strange to hold the batteries at a lower SOC most of the night then to charge at nearly the full rate for the last hour?

G
#673 geoffreycoan

[unknown] This is not the first time I have seen this, but seems a bit strange to hold the batteries at a lower SOC most of the night then to charge at nearly the full rate for the last hour?

there are some other people commenting about behaviour on the EV tariffs https://github.com/springfall2008/batpred/issues/1888

if you have low charge mode set then it should do a gentle charge all night. Best raise a github issue

D
#675 Dpe

geoffreycoan
Ok will get a bit more info together

B
#676 browellm

Just checking, but I presume holiday mode does not work with PredAI and I'll need to comment PredAI out for the days I am away for it to work?

G
#677 geoffreycoan

browellm Are they not different things? Predai will calculate your projected load based on historical data but predbat holiday mode will ignore historical projection and take just yesterday’s load as input

B
#678 browellm

[unknown] Could well be Geoffrey, I will have to re-read up the behaviour.

As an aside as I have been fully on PredAI for some time now and with no desire to go back to previous days, I have decided to move my load scaling to 100% from the default 105% which puts full faith in PredAI. Will see how it goes.

D
#679 Dpe

Further to my previous post, I raised a github ticket and noticed another raised about predbat thinking that between 0:00 and 00:30 it thinks the rate is zero so there is a fix in progress for this.
I had assumed that this was why my system tried to charge at full rate every night from 0:00 even though the charge start time was 00:30.
I adjusted my charge start time to midnight, last night I checked the logs to see charging was enabled and a SOC of 40 % was set, so all looked good. Just before midnight status changed to 'hold charging' as the battery SOC was >40%.
At midnight the battery started charging at 3000W, at 60 % SOC I stopped it, but could only do this by putting predbat into monitor only. At first I thought it may be some register in the inverter that was set to an odd setting, checked and as far as I could see all normal, took predbat out of monitor and charging starts again at 3000W. Put predbat back into monitor and stopped the charging, left overnight in monitor. This morning battery was not discharging and in the givtcp logs it says the system was set to pause at 03:00-even though predbat was in monitor at this time - this is exactly the time predbat status changed to 'hold for car' .
It would seem that only I am experiencing this and I am now totally mystified by what is happening. On the one hand the instructions I can see being given in the givtcp logs by Predbat seem OK, but as soon as I enable predbat after midnight it charges the battery at the full rate even though it is above the required SOC and low power mode is enabled. Any suggestions as what I can do to recover this to a working situation? I have tried restarting HA, Restarting GivTCP, Restarting Predbat, and restarting the inverter. I have gone to an earlier predbat version - no change.
AC3
2x 5.2

D
#680 Dpe

Further to my previous post, I raised a github ticket and noticed another raised about predbat thinking that between 0:00 and 00:30 it thinks the rate is zero so there is a fix in progress for this.
I had assumed that this was why my system tried to charge at full rate every night from 0:00 even though the charge start time was 00:30.
I adjusted my charge start time to midnight, last night I checked the logs to see charging was enabled and a SOC of 40 % was set, so all looked good. Just before midnight status changed to 'hold charging' as the battery SOC was >40%.
At midnight the battery started charging at 3000W, at 60 % SOC I stopped it, but could only do this by putting predbat into monitor only. At first I thought it may be some register in the inverter that was set to an odd setting, checked and as far as I could see all normal, took predbat out of monitor and charging starts again at 3000W. Put predbat back into monitor and stopped the charging, left overnight in monitor. This morning battery was not discharging and in the givtcp logs it says the system was set to pause at 03:00-even though predbat was in monitor at this time - this is exactly the time predbat status changed to 'hold for car' .
It would seem that only I am experiencing this and I am now totally mystified by what is happening. On the one hand the instructions I can see being given in the givtcp logs by Predbat seem OK, but as soon as I enable predbat after midnight it charges the battery at the full rate even though it is above the required SOC and low power mode is enabled. Any suggestions as what I can do to recover this to a working situation? I have tried restarting HA, Restarting GivTCP, Restarting Predbat, and restarting the inverter. I have gone to an earlier predbat version - no change.
AC3
2x 5.2

G
#681 geoffreycoan

Dpe It sounds like there is a charge programmed on the inverter. Try doing a reset to defaults on the portal, or or go through and manually check and clear any charging slots. Also check what the battery reserve is set to, it should be 4% - it may have been set higher if Predbat programmed a freeze charge.

BTW you can set predbat to read only mode to stop it executing the plan, simpler than setting monitor mode.

There is a bug fix for the midnight zero issue, install the ‘main’ version (from the select.predbat_update control)

G
#682 geoffreycoan

geoffreycoan Also worth saying I like to have a control panel where I can see what the inverter controls are all set to, and if necessary change them:

D
#683 Dpe

Thanks, will give that a try and see what happens tonight

R
#685 Rubikcube

[unknown]

predbat? - Do you want a "Bread Bap"?

Daisy is so old she remembers when the Guardian had news.

M
#686 matttheotter

Morning All,

Looking for a bit of guidance, I have been reviewing the config of my AIO in Predbat using GivTCPv3 and wanted to check I had the right flags.

Set the following recently to report the right battery size:

battery_scaling:
- 0.85

Turned off Hybrid Inverter.

Spotted this in the log recently:
Warn: REST data reports Battery Capacity kWh as 14.008 but nominal indicates 16.48 - using nominal

Nominal flag is set to false, wondering where I have gone wrong...

G
#687 geoffreycoan

matttheotter Set the following recently to report the right battery size:
battery_scaling:

  • 0.85

might be a cut and paste error, but looks like your battery scaling YAML isn’t correctly indented, it should be:

  battery_scaling:
    - 0.85

0.85 is the correct scaling for an AIO

G
#688 geoffreycoan

Discovered my first ‘wrinkle’ with Predbat and Cosy, I’m bitten this morning by https://github.com/springfall2008/batpred/issues/830

I have two inverters both controlled by Predbat but with dissimilar battery sizes, and Predbat doesn’t take account of this, assuming that because I have two inverters at 2.4kWh charge rate I can charge the batteries at 4.8kWh

Specific example today:

Inverter G with the 9.5 can charge at 2.4kWh an hour, so in 3 hours I can put 7.2kW into the battery. To be completely full by the end of the Cosy period I need to start the charging with the battery SoC at about 25%. The 5.2 (inverter H) is less of a problem, even with the 1.8kWh charge rate I get when its cold I can still fill its 4.2 capacity in 3 hours.

I have had to set predbat to read only so I can change the battery reserve on inverter G to 25%. At the moment there is no way to specify an individual reserve levels per inverter, there is a single global input_number.predbat_set_reserve_min (default to 4%) that is applied to all inverters.

Have raised a feature request to enhance predbat https://github.com/springfall2008/batpred/issues/1974

M
#689 matttheotter

geoffreycoan probably a cut and paste error

#690 PianSom

matttheotter
As Geoffrey says, the setting is correct.

I have an AIO on GivTCP (3..0.4) and do not have that error in my logs. Can I ask what you have in your apps.yaml? I specify both the REST interface and all the individual sensors eg

  load_today:
    - sensor.givtcp_{geserial}_load_energy_today_kwh

What are you doing?

PS to quote yaml properly the trick is to open and close with three back tick marks - ```

G
#693 geoffreycoan

matttheotter that looks OK. Assume you only have a single AIO, so hence only need to set battery scaling for that single AIO.

Its curious. 16.48 x 0.85 is 14.008 so its as if Predbat is applying the scaling factor and then ignoring it.

Do you have a line like this in the logfile (this is from my 5.2 scaled to 80% DoD):

Inverter 1 with soc_max 4.18 kWh nominal_capacity 5.22 kWh battery rate raw 2600 w charge rate 2.6 kW discharge rate 2.6 kW battery_rate_min 0.0 w ac limit 5.0 kW export limit 5.0 kW reserve 4.0 % current_reserve 4.0 % temperature 21.0 c

And switch.predbat_battery_capacity_nominal is definitely off?
https://springfall2008.github.io/batpred/customisation/#scaling-and-weight-options

It sounds like its a bug 🤷‍♂️

R
#694 Rbor

Worth taking a look at Predbat 8.14.0.
I have just installed it but haven’t investigated it yet.

Looks like a nice present from Trefor for us all.

Rob

B
#696 browellm

[unknown] Will have to watch his video, the documentation is 'light' 🙂

#697 PianSom

Friday night glass of wine, so I jumped in with both feet.

  • The update seems to have taken, but also shows as still available (so installed version and latest version are the same - 8.14.0)
  • Hitting the Calculate Now button leads to the first entry being populated but then a repeating error in the logs
    33118 2025-02-07 21:34:23.413397: Error: 'str' object has no attribute 'get'
    33117 2025-02-07 21:34:23.413348: Info: record_status Error: Exception raised 'str' object has no attribute 'get'
    33115 AttributeError: 'str' objec t has no attribute 'get'

    Only cleared by restarting Predbat

That said, looks like a major feature upgrade. Should be wildly useful. Fingers crossed it works tonight at midnight.

L
#698 LewisWatt

[unknown] Yeah I'm getting the same error. Hoping it's just a quick fix

R
#699 Rbor

Same error for me.
I restarted Predbat and the error went away.
Predbat is still indicating that there is a new update.
Mine is v8.14.0 with the new update as V8.14.0 but I assume that I have got it!

I first watched Trefor's new video which enhanced the documentation.
The setup involved just copying Trefor's 'compare template' into apps.yaml and changing the region code. Trefor's documentation includes a link to region codes:
https://energy-stats.uk/dno-region-codes-explained/

Once the WebUI had populated its new Compare tab with the tariffs, I pressed 'compare' and, after a while, I got a blue bar for my current tariff, now to 24 hours in future.
At midnight, the other tariffs should get populated.

What a great feature and one that Trefor soys he is going to enhance.
Just like Xmas day! I won't be staying up for midnight though.

Rob

G
#700 geoffreycoan

There seems to be an issue with the version numbering of 8.14.0 which is causing the update message still to persist
https://github.com/springfall2008/batpred/issues/1978

Am sure Trefor will fix it.

Have been playing around with the new comparison tool, initially it was working fine without a restart, just changing apps.yaml, and then it crashed so had to restart predbat to get it going.

The comparison takes a while to run as it basically has to run the predbat engine for each tariff combination. It is concluding that Cosy is about £5 cheaper than Agile for me, and Fixed export would be about 30p better than my current Agile outgoing.

I’ve created a FR for some observations I had on the new function, feel free to add to it:
https://github.com/springfall2008/batpred/issues/1980

Will need to take a look at what these do in terms of sensors taking up database space. I know the battery temp one needs pruning and I think the weather alert one will do as well.

#701 PianSom

Both issues I had on first install have resolved. This morning there is no second version (or available update) showing, and the midnight run completed successfully (though I did delete the first comparison of price cap/SEG, so that may have helped).

What an interesting analysis!

There may be some quibbles (although he mentions it in the docs, the fact that different plans end the day with different SoC’s is obfuscating) but it’s fascinating to see what might have been. As one of the GitHub comments says, I can’t wait to see some sensitivity analysis of changing Predbat parameters. And also for some kind soul to go and find urls for non-Octopus tariffs. Lots of potential future enhancements present themselves.

In the mean time IOG ftw.

D
#702 Daveb01

I have just watched Trevor’s new video on Tariff compare, but what was very interesting is the new thing he is working on, what the plan looks like if you change a setting. I will be using that a lot.

H
#703 Henry3rd

A really useful development, which on the first run suggests I should be on flux rather than Agile with fixed export.
The upcoming ability to see the effect of altering predbat settings will be interesting. I hope we will be able to model the effect of adding a second battery.

S
#705 SteveCook

Daveb01
Mine just sits there saying "Loading Chart (Please Wait)"

T
#706 TX200

Well, I’ve only just installed it, but predbat says flux is better than agile & fixed export so far.

Circa 40p cheaper.

Will have to watch it for a couple of days then maybe make my move.

I’m on the variable 15p export already so won’t loose the benefit of the fixed 15p export tariff (I was on agile outgoing when they changed the tariff). Also the SC is the same for both my current tariff and flux.

H
#707 Henry3rd

SteveCook I had that initially, but the latest predbat update seems to have fixed it.

W
#708 Wavy Davy

With the compare feature can you just paste the example into your config after changing the area code or do you have to change anything else?
I have done this but after about 30 minuits it still says "loading chart and also running"

H
#709 Henry3rd

Wavy Davy That's all I did, other than deleting tariffs that weren't available to me.
I had to upgrade to the latest version (v8.14.1) and restart a few times before it started working

R
#712 Rbor

When I installed v8.14.0(?) last night, I copied over all of Trefor's tariffs from What's Changed' to apps.yaml.
I was disappointed this morning when I still only had 'current' working.

This morning, I checked my apps.yaml and was pleased with myself that I spotted the 2 missing colons in the 2nd entry. There were still some glitches and v8.14.1 appeared so I updated again.
I also copied Trefor's apps.yaml template within https://github.com/springfall2008/batpred/blob/main/docs/compare.md
I then restarted predbat.

I clicked on Compare in the webUI Compare tab.
I too was presented with 'running' and I went for a walk in the Yorkshire cold srizzle.
On my return, I had all tariffs completed. It took getting on for an hour so do have patience, or at least comment out the tariffs you don't want or need.
I have now got the compare feature working and so much to explore and think about!

Based on 'Compare', my new Cosy tariff will be £3.00 less than my old Agile tariff!
And today, Agile is projected to be 10p more than the SVT.

What a brilliant enhancement to Predbat, which has so much potential.

Rob

D
#713 Daveb01

Rbor

Did you update the letter for the area your in? The default was A. I have changed mine to H? I hope this is the correct place to change it?

Are we all going to post our results after a day or two on here or create a new post? Don’t wan to get told off putting in here 😎

R
#714 Rbor

Thoughts on the Compare feature.

  1. On selecting compare, each tariff plan spans 24 hours but the 1st entry is the same for all tariffs, showing the data from midnight.
    I would like the starting point to be zero, the same as a midnight start.
    I suspect that Trefor is now hard at work dreaming up enhancements.

  2. There has been a lot of debate about whether it is worth getting a 2nd battery.
    e.g. See https://community.givenergy.cloud/d/5596-adding-second-battery

With the compare tool, it is easy to see the maximum SOC range that you need when charging during periods with lower rates, and whether the batteries can take you through to the next period with lower rates.
For example, I have two 8.2 kWh batteries and a single AC3.0 inverter. I have just switched to Cosy from Agile.
The longer cheaper Cosy period is 3 hour, e.g.:

Each 30 minutes gives me 9% SOC, so I can make use of 54% SOC, equivalent to just over 1 battery-worth.
This is with really cold conditions with no sun! I reckon I would be just about OK with one 8.2.kWh battery with my load. Your mileage is bound to be different but revealed in the plan.
I am neglecting losses here to focus on cost

My 24 hour battery SOC range is 40%-95% which looks borderline for needing two 8.2.kWh batteries with Cosy.
With an EV, I have 2 tariffs available with more contiguous cheaper hours and I would definitely need 2 batteries. And even then, my batteries are empty by about 8 pm. With greater load, they will run dry earlier.

For me, 'Compare' shows that Cosy is just cheaper that Go and just more expensive than Intelligent Go.

So a lot of 'fun' analysis to carry out.

*I was disappointed to lose Nordpool info on leaving Agile.
But the Agile plan with 'Compare' displays the Nordpool predicted rates, a real bonus.

Rob

D
#715 Daveb01

R
#716 Rbor

Daveb01 Yes, you have highlighted the correct positions to change the region letters.

Meanwhile, I have posted 'Thoughts on the Compare feature' below.
We could start a new thread but this thread could be appropriate.
The plus with a new thread is that it is then easier to find relevant posts.

Let's see what others think.

Rob

R
#717 Rbor

Daveb01 Sadly, your Compare plan shows Agile currently the most expensive even against SVT (cap_seg).

Your Agile export and Fixed export don't look right. I wouldn't have expected there to be such a difference between them.

Rob

D
#718 Daveb01

[unknown]

I thought the same, so not believing the results yet, I am going to give it a few days first, and possibly updates from Trevor.

G
#719 geoffreycoan

[unknown] Your Agile export and Fixed export don't look right. I wouldn't have expected there to be such a difference between them.

The individual plans all appear below so you can look at where the differences are. On the Agile plans there is very little exporting, probably just a bit of full battery excess solar going out, as with the Agile rates so high there’s little benefit in exporting.

[unknown] On selecting compare, each tariff plan spans 24 hours but the 1st entry is the same for all tariffs, showing the data from midnight.
I would like the starting point to be zero, the same as a midnight start.

This was one one the things I highlighted in my FR on the compare tool, a manual compare included ‘today so far’ and then ran to +24 hours. I felt it should start at midnight with zero like the automatic compares.
Trefor has already changed it and there’s an 8.14.2 out with a lot of other things I suggested.

I haven’t included the EV charger tariffs in my comparison as I don’t have an EV, but maybe I should at least include Go as I believe there isn’t much evidence required.

T
#720 TX200

I wanted to compare intelligent octopus flux which isn't in the documentation - although I do know it won't be quite right as Octopus would be in control rather than Predbat.

I got the list of products via this webpage and searched for intelli-flux

https://api.octopus.energy/v1/products/

I wasn't sure what the -BB tariff was (perhaps business?), I've used the other one.

I found these URLs in the above document, which I hit to get the full details for the pricing

https://api.octopus.energy/v1/products/INTELLI-FLUX-EXPORT-23-07-14/
https://api.octopus.energy/v1/products/INTELLI-FLUX-IMPORT-23-07-14/

Which for region A (the A being the one here: 23-07-14-A/standard) are:

https://api.octopus.energy/v1/products/INTELLI-FLUX-IMPORT-23-07-14/electricity-tariffs/E-1R-INTELLI-FLUX-IMPORT-23-07-14-A/standard-unit-rates
https://api.octopus.energy/v1/products/INTELLI-FLUX-EXPORT-23-07-14/electricity-tariffs/E-1R-INTELLI-FLUX-EXPORT-23-07-14-A/standard-unit-rates

Hopefully that is correct - and hopefully it'll help someone else if they want to do similar?

T
#721 TX200

Seems to be working. Will wait to see what the midnight run says, but so far

Agile and 15p outgoing: 96.93p
Flux: 55.54p
iOF: 95.14p

H
#722 Henry3rd

Agile and 15p outgoing: 225.1p --Existing
Flux: 130.83p --best
IOF: 184.62p
Agile and agile: 223.26p
Eco7: 132.96p

H
#723 Henry3rd

Call me a cynic, but I have a theory that regardless of what tariff you are on, you will end up paying the same as all the others in the long run.

T
#724 TX200

Henry3rd yes and no

For example I saved lots of money by being on tracker for gas for 12 months and I'm now saving lots of money being on a fixed gas contract (so far). It's all about timing and luck!

Agile elec is good when the prices are stable or falling. You get access to the cheaper prices sooner than those on the price cap tariffs.

It's not great when the prices are rising, you get the expensive prices before everyone else.

V
#725 Vestas

TX200 I saved loads of money over 17 years because Scottish Power billed me the wrong way round on economy 7 😃 I told them, they didn't believe me & the muppet they sent out to check the meter treated me like the village idiot so I kept all the emails (including headers) knowing they couldn't back-bill more than a year. They never did sort it out and we moved out over 4 years ago.....

B
#726 browellm

Wonderful stuff. I've just altered the api pointers to the EV-Saver version of Intelligent which explains the discrepancy between 'current tariff' and the baked in IGO/Agile ex version, but otherwise shows just what a good tariff it is for me. This will help me decide when it's best to swap to IGO EV-Saver/Outgoing though. My guess is some time around April but let's see.

G
#727 geoffreycoan

I didn’t include the EV tariffs as I don’t have an EV, but maybe I could say I am “getting one”

Cosy coming out cheapest for me, with Flux in second place after Agile. Glad I swapped from Agile to Cosy

R
#728 Rbor

I am now up to v8.14.3 (at the last count!)

I have selected the 'Compare now' button.
One flaw seems to be that the SOC% column is set against the SOC% of 'current tariff'.
On my current tariff, Cosy, my SOC % is 83% ...... but so are all the others.
If you are running one of the EV tariffs 83%, is way higher than it should be as there would have been no charging since 6am-ish
And the projection for SOC% 24 hours later is only 15%.
So it is worth comparing the SOC now and in 24 hours time. Cosy has 83% now and 84% tomorrow 24 hours later.

I want to see what happens at midnight and to assess whether this gives realistic SOC% and costs until the following midnight.

I am obviously pleased that I finally decided to shift from Agile to Cosy but what will happen to Cosy tariff on 1st April?
It makes me wonder whether there could be a 'custom' facility where you could model future rates and see the effect. So I could increase Cosy rates by say 2p or 3p, etc and .......

Rob

R
#729 Rbor

I am now up to v8.14.3 (at the last count!)

I have selected the 'Compare now' button.
One flaw seems to be that the SOC% column is set against the SOC% of 'current tariff'.
On my current tariff, Cosy, my SOC % is 83% ...... but so are all the others.
If you are running one of the EV tariffs 83%, is way higher than it should be as there would have been no charging since 6am-ish
And the projection for SOC% 24 hours later is only 15%.
So it is worth comparing the SOC now and in 24 hours time. Cosy has 83% now and 84% tomorrow 24 hours later.

I want to see what happens at midnight and to assess whether this gives realistic SOC% and costs until the following midnight.

I am obviously pleased that I finally decided to shift from Agile to Cosy but what will happen to Cosy tariff on 1st April?
It makes me wonder whether there could be a 'custom' facility where you could model future rates and see the effect. So I could increase Cosy rates by say 2p or 3p, etc and .......

Rob

T
#730 TX200

TX200 one comment on Trefor's video - IOF would usually discharge to 20%

So comparing the tariffs including IOF won't be quite right as PredBat would work differently.

Much better than no comparison of course!

G
#731 geoffreycoan

Rbor I have selected the 'Compare now' button.
One flaw seems to be that the SOC% column is set against the SOC% of 'current tariff'.

If you do a manual compare it will run the compare from ‘now’ for the next 24 hours and project the different costs based on your current SoC.
With the midnight run it will run based on the SoC you have at midnight

Yes maybe nice to be able to specify a custom starting SoC but what we have is pretty good and utilises the power oft the predbat optimisation algorithm

Rbor It makes me wonder whether there could be a 'custom' facility where you could model future rates and see the effect. So I could increase Cosy rates by say 2p or 3p, etc and .......

there is https://springfall2008.github.io/batpred/compare/

As well as Octopus rate URLs (rates_import_octopus_url/rates_export_octopus_url) you can use manual rates (rates_import/rates_export)

just manually specify the rates and start and end times over a 24 hour cycle

D
#732 Daveb01

I have just thought of an extra use we could possibly do, if you are thinking of moving for example, you can change the area code and see what the potential saving/extra cost would be if you had the same system?

Or change it to where Geoffrey lives and see if you can beat his rate 😛

W
#733 Wavy Davy

Daveb01 Yes did change mine to H as well. All afternoon still didn't work, never even got the chart showing.

G
#734 geoffreycoan

Wavy Davy Trefor introduced the ability for you to define the area code in the yaml, but it didn’t work in 8.14.2. That’s fixed in 8.14.3 now so if you changed the yaml to match 8.14.2 with the area code defined you need to upgrade to 8.14.3, or if you are using URL’s with embedded area code in them (as in 8.14.0 and 8.14.1) then this shouldn’t matter

W
#735 Wavy Davy

geoffreycoan Thanks Geoff, but I'm on 8.14.3 and its still not working.
Just checked HA entities and no compare entities created.
Does the chart come up straight away?
Have had it running for quite a while now since upgrading to 8.14.3 and still no chart.

W
#736 Wavy Davy

In the log file I get lots of these errors.

18113 2025-02-08 19:48:25.805640: Warn: Web Socket closed, will try to reconnect in 5 seconds
18111 aiohttp.client_exceptions.W SServerHandshakeError: 502, message='Invalid response status', url=URL('http://supervisor/core/api/websocket')
18110 raise WSServerHandshake Error(
18104 2025-02-08 19:48:25.804882: Error: Traceback (most recent call last):
18103 2025-02-08 19:48:25.804175: Error: Web Socket exception in startup: 502, message='Invalid response status', url=URL('http://supervisor/core/api/websocket')
18101 2025-02-08 19:48:20.784672: Warn: Web Socket closed, will try to reconnect in 5 seconds
18099 aiohttp.client_exceptions.W SServerHandshakeError: 502, message='Invalid response status', url=URL('http://supervisor/core/api/websocket')
18098 raise WSServerHandshake Error(

G
#737 geoffreycoan

[unknown] this looks like a web socket failure talking from predbat to HA. Restarting the Predbat addon can usually fix this

However you can still get timeouts after a lot time of running predbat, and advice is to create a long lasting token for Predbat to connect to HA:

G
#738 geoffreycoan

Rbor I am now up to v8.14.3 (at the last count!)

Trefor has released 8.14.4 just now, includes changing the rounding of figures in the table and addition of intelligent flux

and tip, if you don't have an EV, turn car_charging_hold off and the graph won't include 'actual (without car)'

R
#739 Rbor

Thanks.
It has been a hectic day for v8.14.X.
4 updates in a day is going some – I missed v8.14.2, going from .1 to .3 in one update.

I am now on v8.14.4. I like the £ for cost rather than p.
I have updated to the latest 'compare apps.yaml' code, with the much neater of choosing the region letter as a variable, rather than typing the region letter into each tariff code.


My plan is to allow the Compare feature to refresh the tariffs at midnight and then to review the comparisons tomorrow without touching 'Compare Now' all day.

I will finish the day watching Trefor's Compare video again.

Rob

G
#740 geoffreycoan

Rbor My plan is to allow the Compare feature to refresh the tariffs at midnight and then to review the comparisons tomorrow without touching 'Compare Now' all day.

I have run the compare tool again myself during the day and it kinds of mucks up the day to day comparison so I'm going to now not do that and just let it run every night.

And hope it doesn't fill the database up too much with all these extra entities and history...

D
#741 Daveb01

geoffreycoan

I thought the same and here is mine this morning, much different from the one where is pressed the compare button.

G
#742 geoffreycoan

[unknown] Very nice, some negative options on there.

Todays comparison of my ASHP guzzling consumption is on the Agile thread https://community.givenergy.cloud/d/3678-making-the-most-of-octopus-agile/814 but I’m happy enough with a circa £10 a day import bill. Will be a couple of months before I see negative figures when generation increases substantially

T
#743 TX200

Have I done something wrong here, the price is still 15p this evening?

I updated it several hours ago.

R
#744 Rbor

TX200 Is it the indentation.
This is for a similar entry from a month ago in my apps.yaml:

  rates_export_override:
    - date: '2025-01-08'
      start: '17:00:00'
      end: '18:00:00'

So I have 2 spaces before -
Then 1 space after - for each entry.

yaml issues seem to nearly always be caused by incorrect indents.

Rob

T
#745 TX200

[unknown] seemed to be the date field. I removed that just now and it's updated. Strange.

D
#747 Daveb01

geoffreycoan

It’s a shame, I have an EVC but not an EV (yet) as way to expensive. If they signed me up, I think they would notice I was not charging an EV & just batteries quite quickly.

#748 PianSom

Daveb01 It’s a shame, I have an EVC but not an EV (yet) as way to expensive. If they signed me up, I think they would notice I was not charging an EV & just batteries quite quickly.

You may want to read the IOG T+Cs - https://octopus.energy/policies/smart-tariffs-terms-and-condition/#intelligentoctopusgo - and have a think about whether you qualify. Provided that your EVC is compatible so qualifies as "Low Carbon Technology" ie it can be controlled by Octopus, then 2.4.1.6 suggests you are eligible.

On the other hand, 2.4.1.3 suggests you may not be. Although it doesn't explicitly specify that an EV is required ...

Also, see https://octopus.energy/blog/intelligent-go-faqs/

W
#749 Wavy Davy

Still haven't got the compare working, but I'm down to just 2 warnings.
9179 2025-02-09 14:58:16.428161: Warn: Regular expression argument: carbon_intensity unable to match re🙁sensor.carbon_intensity_uk), now will disable
9166 2025-02-09 14:58:16.373492: Warn: Failed to decode response from http://192.168.1.26:8123/addons/self/info

Don't seem to have the carbon sensor, but as it says "now will disable" I think this is not the thing that's stopping it.
For the second one I have created a long lasting key and put in the apps yaml
ha_url: 'http://192.168.1.26:8123'
ha_key: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXxxxxxxxxxxxxx
which I assume is correct?

G
#750 geoffreycoan

Wavy Davy 9179 2025-02-09 14:58:16.428161: Warn: Regular expression argument: carbon_intensity unable to match re🙁sensor.carbon_intensity_uk), now will disable

Have you configured carbon_intensity in apps.yaml at all? It looks like predbat thinks you have but the regular expression to find the carbon intensity sensor is failing [because you haven’t installed the integration)

But this is just a warning, so shouldn’t affect anything.

9166 2025-02-09 14:58:16.373492: Warn: Failed to decode response from http://192.168.1.26:8123/addons/self/info

That is weird. Are t you running docker or predbat in a weird way?

What this is doing is making an API call to the HAOS supervisor to find the id of the addon that predbat is running under, it uses this to then write out pathnames in the logfile correctly, e.g. /addon_configs/6aXXXXXpredbat/predbat_dashboard.yaml

So again its a warning and it not being set it defaults the pathnames that appear in the logfile to /config

Neither of these should affect the compare working. Assume you have it configured in apps.yaml, what happens when you try to access the compare option in the predbat web console?

W
#751 Wavy Davy

geoffreycoan I am running it as a stand alone app. HA is on a dell thin client not in a docker.
I have created a long term token called Predbat and posted the key in apps yaml as mentioned above.
I tried changing the ha key to homeassistant.local:8123 which made the errors worse, so I changed it back.
If I click on the link "http://192.168.1.26:8123/addons/self/info" I get "404 file not found"

#752 PianSom

Wavy Davy
The clue is in the “addons” part of the url. If you are not running HA Add-ons then you will always get this error.

Mine is in Docker, and I get it too.

It’s a very ignorable warning.

W
#753 Wavy Davy

How do I install the carbon intensity sensor, will do that to at least get rid of that error, but it still doesn't seem to be running.

W
#754 Wavy Davy

I still am not getting the chart, but after running "compare now" and looking at predbat logs I get this

Web interface started
2025-02-09 17:07:47.882847: Info: Web Socket active
2025-02-09 17:07:47.929598: Warn: Regular expression argument: carbon_intensity unable to match re🙁sensor.carbon_intensity_uk), now will disable
Watching ['./config.py', './alertfeed.py', './output.py', './execute.py', './energydataservice.py', './fetch.py', './inverter.py', './unit_test.py', './web.py', './download.py', './ha.py', './utils.py', './predheat.py', './predbat.py', './futurerate.py', './solcast.py', './prediction.py', './userinterface.py', './octopus.py', './hass.py', './gecloud.py', './plan.py', './compare.py', './apps.yaml'] for changes
2025-02-09 17:08:15.281777: Info: record_status Demand
2025-02-09 17:10:26.576243: Info: record_status Demand
2025-02-09 17:15:26.132348: Info: record_status Demand
2025-02-09 17:20:26.670181: Info: record_status Demand
2025-02-09 17:22:58.497061: Info: record_status Demand
2025-02-09 17:25:26.665381: Info: record_status Demand
2025-02-09 17:30:26.772411: Info: record_status Demand
2025-02-09 17:35:26.466798: Info: record_status Demand
2025-02-09 17:40:26.040721: Info: record_status Demand

So is it running but not showing the results in the chart?

#756 PianSom

Wavy Davy
It takes a while.

In your apps.yaml you may have these lines:

  # Carbon Intensity data from National grid
  carbon_intensity: 're:(sensor.carbon_intensity_uk)'

Comment out the second one.

W
#757 Wavy Davy

PianSom Thanks that got rid of that error. Just down to one now.
I Will leave it alone for a while and see if the chart appears.

G
#758 geoffreycoan

Wavy Davy I still am not getting the chart, but after running "compare now" and looking at predbat logs I get this

Web interface started
2025-02-09 17:07:47.882847: Info: Web Socket active
2025-02-09 17:07:47.929598: Warn: Regular expression argument: carbon_intensity unable to match re🙁sensor.carbon_intensity_uk), now will disable
Watching ['./config.py', './alertfeed.py', './output.py', './execute.py', './energydataservice.py', './fetch.py', './inverter.py', './unit_test.py', './web.py', './download.py', './ha.py', './utils.py', './predheat.py', './predbat.py', './futurerate.py', './solcast.py', './prediction.py', './userinterface.py', './octopus.py', './hass.py', './gecloud.py', './plan.py', './compare.py', './apps.yaml'] for changes
2025-02-09 17:08:15.281777: Info: record_status Demand
2025-02-09 17:10:26.576243: Info: record_status Demand

That’s not the predbat log, its just a summary log which in HAOS is written to the predbat addon log tab (so not sure where its written in your standalone install)

But anyway, the full predbat log is a file called predbat.log and should be in the /config folder. Its much more verbose about what is actually happening with Predbat

PianSom The clue is in the “addons” part of the url. If you are not running HA Add-ons then you will always get this error.

Mine is in Docker, and I get it too.

Didn’t realise you were getting a warning in docker. I do you get the same ‘failed to decode’ message, I can look to suppress it. And your logs are all written to /config (or wherever you map this to in docker)

#759 PianSom

geoffreycoan
Yup, had that "failed to decode" Warn message for ages. I pretty much immediately worked out that it was because my HA instance knows nothing at all about addons, so I have always just ignored it.

And, yes, predbat logs are written to the folder that I map to Predbat's /config folder. Is that log really more verbose than the one presented in the Predbat ui? I had thought they were the same.

W
#760 Wavy Davy

Yes I have the log in /addon_configs/6adb4f0d_predbat/predbat.1.log
Also have 9 other older logs. Do these get auto deleted after a while or do they just build up until manually deleted?

Still no sign of a chart.

G
#761 geoffreycoan

PianSom I don’t know what you get in docker, but here’s what’s in my predbat.log file:

date=2025-02-10&market=N2EX_DayAhead&deliveryArea=UK&currency=GBP age 136.3 minutes
2025-02-09 12:56:19.491755: Loaded 95 datapoints of futurerate analysis
2025-02-09 12:56:19.741324: Predicted future rates: ['02-09 00:00:00 => 25.66 / 12.91', '02-09 01:00:00 => 25.05 / 12.61', '02-09 02:00:00 => 23.71 / 11.95', '02-09 03:00:00 => 22.72 / 11.46', '02-09 04:00:00 => 22.44 / 11.32', '02-09 05:00:00 => 22.33 / 11.27', '02-09 06:00:00 => 23.22 / 11.71', '02-09 07:00:00 => 25.05 / 12.61', '02-09 08:00:00 => 24.96 / 12.57', '02-09 09:00:00 => 24.05 / 12.12', '02-09 10:00:00 => 23.67 / 11.93', '02-09 11:00:00 => 23.88 / 12.03', '02-09 12:00:00 => 24.16 / 12.17', '02-09 13:00:00 => 23.69 / 11.94', '02-09 14:00:00 => 23.84 / 12.01', '02-09 15:00:00 => 25.09 / 12.63', '02-09 16:00:00 => 37.96 / 20.37', '02-09 17:00:00 => 40.15 / 21.45', '02-09 18:00:00 => 41.16 / 21.96', '02-09 19:00:00 => 28.85 / 14.49', '02-09 20:00:00 => 26.3 / 13.23', '02-09 21:00:00 => 24.2 / 12.19', '02-09 22:00:00 => 23.08 / 11.63', '02-09 23:00:00 => 23.08 / 11.63', '02-10 00:00:00 => 23.18 / 11.69', '02-10 01:00:00 => 22.36 / 11.28', '02-10 02:00:00 => 21.42 / 10.81', '02-10 03:00:00 => 20.72 / 10.47', '02-10 04:00:00 => 20.66 / 10.44', '02-10 05:00:00 => 22.44 / 11.32', '02-10 06:00:00 => 25.52 / 12.84', '02-10 07:00:00 => 28.51 / 14.32', '02-10 08:00:00 => 29.18 / 14.66', '02-10 09:00:00 => 27.68 / 13.91', '02-10 10:00:00 => 26.17 / 13.17', '02-10 11:00:00 => 24.69 / 12.43']
2025-02-09 12:56:20.096084: Rate min forward looking: now 13.23 at end of forecast 13.23
2025-02-09 12:56:20.096592: Import rates min 13.23 max 40.47 average 24.08
2025-02-09 12:56:20.116144: Adding rate rates_export_override: {'start': '16:00:00', 'end': '19:00:00', 'rate_increment': -5} => 02-09 16:00:00 to 02-09 19:00:00 @ -5.0 date None day_of_week [] increment True
2025-02-09 12:56:20.117685: Export rates min 10.37 max 17.44 average 12.81
2025-02-09 12:56:20.118152: Rate thresholds (for charge/export) are import 39.97p (0.0) export 10.87p (0.0)
2025-02-09 12:56:20.125978: High export rate found rates in range 11.06 to 17.44
2025-02-09 12:56:20.129046: Low Import rate found rates in range 13.23 to 26.98
2025-02-09 12:56:20.129211: Battery level now 3.05 -1hr 5.37 midnight 11.25 battery value change hour -33.9 day -119.66 rate_forward 14.59
2025-02-09 12:56:20.129394: Hour energy 1.51 import 1.51 export 0.0 car 0 load 4.49 cost 40.74 import 40.74 export 0.0 car 0.0 carbon 0.0 kG
2025-02-09 12:56:20.194007: Today's energy import 18.8 kWh export 0.0 kWh total 18.8 kWh cost 273.49 p import 273.49 p export 0.0 p carbon 0.0 kg
2025-02-09 12:56:20.194151: Using Solcast integration from inside HA for solar forecast
2025-02-09 12:56:20.194224: PV Data for pv_forecast_today total 8.29 kWh
2025-02-09 12:56:20.194267: PV Data for pv_forecast_tomorrow total 4.55 kWh
2025-02-09 12:56:20.194306: PV Data for pv_forecast_d3 total 6.05 kWh
2025-02-09 12:56:20.194342: PV Data for pv_forecast_d4 total 9.13 kWh
2025-02-09 12:56:20.200821: PV Forecast for today is 8.29 (3.95 10% 13.2 90%) kWh and left today is 3.23 (1.69 10% 4.93 90%) kWh
2025-02-09 12:56:20.221308: PV Forecast for day tomorrow is 4.55 (3.13 10% 6.26 90%) kWh

the HAOS lot tab for the Predbat add-on just shows warnings and state changes:

2025-02-09 19:15:50.464798: Info: record_status Demand
2025-02-09 19:20:01.945501: Warn: Historical day 5 has 10 minutes of gap in the data, filled from 59.09 kWh to make new average 59.5 kWh (percent 99%)
2025-02-09 19:20:04.828225: Warn: Out of range index 1 within item pause_start_time value None
2025-02-09 19:20:04.828336: Warn: Out of range index 1 within item pause_end_time value None
2025-02-09 19:20:04.905039: Info: record_status Demand
2025-02-09 19:25:02.688970: Warn: Historical day 5 has 10 minutes of gap in the data, filled from 59.45 kWh to make new average 59.86 kWh (percent 99%)
2025-02-09 19:25:06.116622: Warn: Out of range index 1 within item pause_start_time value None
2025-02-09 19:25:06.117220: Warn: Out of range index 1 within item pause_end_time value None
2025-02-09 19:25:52.319925: Warn: Out of range index 1 within item pause_start_time value None
2025-02-09 19:25:52.320470: Warn: Out of range index 1 within

Maybe in docker its the same thing, it’s just a question of log level set and by default you are getting something similar to what’s shown in the HAOS add-on log?

W
#762 Wavy Davy

Yes I have the log in /addon_configs/6adb4f0d_predbat/predbat.1.log
Also have 9 other older logs. Do these get auto deleted after a while or do they just build up until manually deleted?

Still no sign of a chart.

G
#763 geoffreycoan

Wavy Davy Yes I have the log in /addon_configs/6adb4f0d_predbat/predbat.1.log
Also have 9 other older logs. Do these get auto deleted after a while or do they just build up until manually deleted?

The logs shuffle along, so when predbat.log is filled it moves predbat.8.log to predbat.9.log, predbat.7.log to predbat.8.log, al the way to predbat.log moves to predbat.1.log and then a new empty predbat.log is created

I think maybe you don’t have your log level set high enough so that’s why you can’t see progress reports from the comparison and can’t see why (if) its failing

What do you see in the predbat web console?

PianSom I’ll look to get the warning suppressed

W
#764 Wavy Davy

geoffreycoan If you mean the compare tab I get this

#765 PianSom

geoffreycoan
Thank you.

But now I am very confused about why @Wavy Davy is getting the warning. I had forgotten that Home Assistant Supervised can run Add-ons, so he shouldn't be getting that error. I'm guessing the addons/self/info url works only for HAOS and not Supervised (nor indeed, obviously, for Container or Core)?

Logs - looks like the Add-on only shows Info/Warn (and - presumably - Error) messages. AFAIK there is no way to choose a log level for a Predbat Docker install, so I get all messages in my predbat.log file. I generally use the Predbat gui to examine logs, which also (I believe) also shows all messages. (Unless you just look at the Warnings or Errors tabs.)

G
#766 geoffreycoan

PianSom But now I am very confused about why @Wavy Davy is getting the warning. I had forgotten that Home Assistant Supervised can run Add-ons, so he shouldn't be getting that error. I'm guessing the addons/self/info url works only for HAOS and not Supervised (nor indeed, obviously, for Container or Core)?

Its a HA supervisor API call https://developers.home-assistant.io/docs/api/supervisor/endpoints/ so yes I would think he shouldn’t get that error.

@Wavy Davy you probably can’t call that endpoint directly from a browser window as you don’t have a supervisor token. But predbat should be able to call it OK

It looks like the problem you are seeing is a problem in loading the chart, not necessarily in generating the data (as described in https://springfall2008.github.io/batpred/compare/ you should have a bunch of entities called predbat.compare_tarrif_id created overnight).
I don’t know what the cause of that is, possibly something to do with the way the dashboard has been coded. I presume the other tabs especially the charts one work OK? Sounding like it’ll have to be a github issue for Trefor

B
#767 BenS

Wavy Davy

I get exactly the same. All the other tabs Dash, Plan, Charts, etc. Seem fine

W
#768 Wavy Davy

geoffreycoan Yes the charts tab displays ok.
Are those entities only created overnight or when manually called? because I don't have them.

W
#769 Wavy Davy

I think I'll also comment out some of the tariffs in apps.yaml so its only checking 2, and see if that helps at all (it shouldn't but will see).

G
#770 geoffreycoan

Wavy Davy Are those entities only created overnight or when manually called? because I don't have them.

they are created at midnight every night, or if you manually click the ‘compare’ button on the compare tab so if you are not getting the entities created then something is failing

Assuming your apps.yaml is formatted OK (just check it carefully, there was an error in the original definition), are you on the latest predbat version 8.14.4? When I added an additional tariff to my apps.yaml I saw it in the table straight away even though there was no comparison done yet.

R
#772 Rbor

Check your apps.yaml.
The original version had 2 typos in the 2nd tariff down.
There were colons missing after rate in lines 4 and 6 below.
This should read:

    - id: 'cap_seg'
      name: 'Price cap import/Seg export'
      rates_import:
         - rate: 24.86
      rates_export:
         - rate: 4.1 

See https://github.com/springfall2008/batpred/blob/main/docs/compare.md

Before I corrected this, I only saw the initial 'current' tariff above 'cap_seg'.

When I first installed v8.14.0, I added all the tariffs listed to apps.yaml.
Today, I commented out tariffs of no interest to me and I noticed that their entries disappeared immediately from the Compare window. I didn't press 'Compare Now' at all (I want to leave just the 'midnight' entries shown for a good day-to-day comparison.
I am now on v8.14.4, the latest version.

Rob

R
#773 Rbor

Wavy Davy Following on from my post above, I have seen your next query in email but it hasn't appeared here!
But looking at the email, your apps.yaml code matches mine.

Rob

R
#774 Rbor

Wavy Davy Following on from my post above, I have seen your next query in email but it hasn't appeared here!
But looking at the email, your apps.yaml code matches mine.

Rob

B
#775 BenS

Wavy Davy

geoffreycoan

Rbor

For me, the error was the wrong indent on the lines below;

octopus_region: "A"
compare_list:

I now have 2 spaces before each and it kicked into life. Wavy Davy I hope formatting fixes it for you too!

W
#777 Wavy Davy

I think your correct its a formatting error, but to get the "green tick" I have to delete 2 spaces from
octopus_region: "A"
compare_list:
so there against the left margin, but the chart doesn't work so I think this is wrong.

W
#778 Wavy Davy

I think your correct, its a formatting fault. But to get the "green tick" I have to delete 2 spaces from
octopus_region: "A"
compare_list:
So that its against the left margin. I don't think this is correct as the chart still doesn't appear

B
#779 BenS

[unknown]
I think that's what I did originally. But then I put the spaces back and it worked!

B
#780 BenS

Rbor i think we are the same!

G
#781 geoffreycoan

[unknown] I think your correct, its a formatting fault. But to get the "green tick" I have to delete 2 spaces from
octopus_region: "A"
compare_list:
So that its against the left margin

No, right at the start of apps.yaml is the predbat module name so everything below that is a sub-component within the predbat module so has to be indented 2 spaces. So octopus_region, compare_list are defined within the scope of predbat module.

Then within compare list you have a list of elements, so again 2 spaces before “- id:” as these are sub-elements within compare_list within predbat at the top.

Can you share your yaml around this point in the file, including the element beforehand because maybe that’s the problem (eg missing close quote, not indented correctly itself) and a few lines afterwards

G
#782 geoffreycoan

In other things, spent a fun afternoon changing the house fusebox for a new one. Long story but its all to do with getting the battery to act as an EPS.

Changing the fusebox was reasonably straight forward, just long winded. Connected up the energy monitor clamps at the end but the heat pump just wasn’t working. Then it read -4.5kW so I swapped the wires round and then it read nothing, nothing, took the wires out, checked them again, electrocuted myself with current coming off the CT clamp, started tracing the current up to the Shelly EM, all good but still not reporting anything to HA.
Eventually resolved it by pushing the screw terminal connectors on the Shelly EM hard back onto the base and re-screwing the CT clamp wires in. And then it read -4kW again to I had to swap the wires around once more.
All working.

And tonight after all that thought I’d have a quiet evening until I investigated the water noise I had kept hearing today. One of the water softener connection pipes under the sink was dripping, constantly, so wall and back of the cupboard all soaking wet. Shutoff valve didn’t seem to work so I had to turn the water off, take the valve off, put a stop end cap on and I’ll go and buy a new shutoff valve tomorrow.

Electrician, Plumber, HA tinkerer, all in a days work !

W
#783 Wavy Davy

[unknown] Thanks Geoff got it sorted thanks to your post.
You said that predbat module name is the main one.
I noticed that above where I was putting the compare code , the module above was also out of line, but still giving me the green tick, I sorted that out, reloaded the compare text and all now seems ok.
Thanks to all who chipped in, much appreciated.
Didn't realise but the module above almost certainly wasn't working either but as it was an meteoalarm alerts module I hadn't realised.

G
#786 geoffreycoan

Wavy Davy I noticed that above where I was putting the compare code , the module above was also out of line, but still giving me the green tick, I sorted that out, reloaded the compare text and all now seems ok.
Thanks to all who chipped in, much appreciated.
Didn't realise but the module above almost certainly wasn't working either but as it was an meteoalarm alerts module I hadn't realised.

YAML formatting is very pernickety, get it slightly wrong and bits get rejected or worst it silently ignores it. Glad you sorted it and a lesson for us all on checking our indents !

Wavy Davy 9166 2025-02-09 14:58:16.373492: Warn: Failed to decode response from http://192.168.1.26:8123/addons/self/info

PianSom But now I am very confused about why @Wavy Davy is getting the warning. I had forgotten that Home Assistant Supervised can run Add-ons, so he shouldn't be getting that error. I'm guessing the addons/self/info url works only for HAOS and not Supervised (nor indeed, obviously, for Container or Core)?

Well thanks folks, been down the rabbit hole of Home Assistant and Python for the last hour.

Thought I’d quickly see how I could suppress the warning message when trying to get the slug id for docker users, added what I thought would work to ha.py but then found that the code wasn’t working at all for me and all of my pathnames in the logfile were defaulting to saying they were in /config rather than /addons_config/…

Here’s the original investigation https://community.home-assistant.io/t/how-to-determine-actual-config-path-in-python/744800/8 I did into how to work out the slug id but the Predbat code is now not working any more for me.

Long story short, if you define ha_url in apps.yaml e.g. to be ‘http://IPaddress:8123’ then the slug id determination doesn’t work and I get exactly the same warning message about failure to decode API call that the docker users get.

If I comment out ha_url and ha_key in my apps.yaml, it all works and you get log messages like this:

2025-02-10 00:32:56.390403: Starting HA interface
2025-02-10 00:32:56.399873: Info: Connected to Home Assistant at http://supervisor/core
2025-02-10 00:32:56.413523: Info: Add-on slug is 6adb4f0d_predbat
2025-02-10 00:32:56.413658: Creating task: <coroutine object HAInterface.socketLoop at 0x7fb794493d80>
2025-02-10 00:32:56.414617: Info: Start socket for url http://supervisor/core/api/websocket
2025-02-10 00:32:56.415660: Info: Web Socket task started
2025-02-10 00:32:56.416207: Starting web interface
2025-02-10 00:32:56.416236: Creating task: <coroutine object WebInterface.start at 0x7fb794493e60>
2025-02-10 00:32:56.417021: Config root is /config and printable config_root_p is now /addon_configs/6adb4f0d_predbat

I think the issue is that ha_url points to HA core and not to the supervisor and the API call needs to go to the supervisor to work out the addon slug id. Maybe this worked in older versions of HA and now it doesn’t.

I’ll have to work out how to get it working again.

#787 PianSom

geoffreycoan
Wow, that is quite the Sunday! What a tale of woe. If only you still had an oil burner you could also have spent a few hours servicing that, while at the same time re-configuring your network as well!! 🙂

geoffreycoan I think the issue is that ha_url points to HA core and not to the supervisor and the API call needs to go to the supervisor to work out the addon slug id. Maybe this worked in older versions of HA and now it doesn’t.

I am not following what it is you are trying to do here, and am a bit confused. As a Docker user I don't have a supervisor (or of course any add-ons). Predbat's config folder is not accessible by the HA Container. As I understand the architecture, there is no concept of a slug id within HA Core/Container (since it is - roughly - the identity of sister docker containers in a supervised environment, which Core isn't).

So, yes - ha_url points to Core (or, more accurately, Container). But there can be no API call to the supervisor, since I don't have a supervisor..

Am I missing the point?

G
#789 geoffreycoan

[unknown] So, yes - ha_url points to Core (or, more accurately, Container). But there can be no API call to the supervisor, since I don't have a supervisor..

Am I missing the point?

Yes!

I had added to the predbat code so that when the API call occurred to ha_url/addons/self/info is executed, if this fails to return a json response then this doesn’t trigger a warning message so those running docker won’t get a spurious message about an API call that will never work.

Scenario 1: docker, no log message, happy days

By default if you don’t set ha_url then Predbat defaults it to http://supervisor/core and when making the get slug API call, it strips off the ‘core’ bit and interrogates http://supervisor/addons/self/info which returns the slug id of the addon predbat is running in.

Secenario 2: HAOS no ha_url, slug id found, happy days

However, I discovered that if you are running HAOS and have set ha_URL to http://IPaddress:8123 because that is more efficient than having to do local DNS calls for every single API call to HA (including all the REST calls to givtcp), then the code tries to make an API call to http://IPaddress:8123/addon/self/info which fails as its calling to HA core not the supervisor.

Scenario 3: HAOS ha_URL set, slug id not found, world has ended, @Wavy Davy gets a warning message he is distressed about, my log files incorrectly report the Predbat path as /config when it isn’t, its all doom and despair

G
#790 geoffreycoan

PianSom So, yes - ha_url points to Core (or, more accurately, Container). But there can be no API call to the supervisor, since I don't have a supervisor..

Am I missing the point?

Yes!

I had added to the predbat code so that when the API call occurred to ha_url/addons/self/info is executed, if this fails to return a json response then this doesn’t trigger a warning message so those running docker won’t get a spurious message about an API call that will never work.

Scenario 1: docker, no log message, happy days

By default if you don’t set ha_url then Predbat defaults it to http://supervisor/core and when making the get slug API call, it strips off the ‘core’ bit and interrogates http://supervisor/addons/self/info which returns the slug id of the addon predbat is running in.

Secenario 2: HAOS no ha_url, slug id found, happy days

However, I discovered that if you are running HAOS and have set ha_URL to http://IPaddress:8123 because that is more efficient than having to do local DNS calls for every single API call to HA (including all the REST calls to givtcp), then the code tries to make an API call to http://IPaddress:8123/addon/self/info which fails as its calling to HA core not the supervisor.

Scenario 3: HAOS ha_URL set, slug id not found, world has ended, @Wavy Davy gets a warning message he is distressed about, my log files incorrectly report the Predbat path as /config when it isn’t, its all doom and despair

R
#791 Rbor

geoffreycoan Electrician, Plumber, HA tinkerer, all in a days work !

Just caught up with last night's late posts.
I think you are missing a trick here. You have heard about Australia's 'Flying Doctors' service.
With your flying kite, you could become our own 'Flying Tinkerer'. We could set up a new thread, say 'First Flight for Predbat', we could supply our GPS coordinates, and you could be with us in no time. On the flight, I am sure you could update the Predbat documentation.

There seem to be no limit of your skills.
We would all be lost without you .............

Thanks

Rob

G
#792 geoffreycoan

Rbor love it!

Good job I have enough time on my hands. I wouldn’t call it spare as it gets filled faster than I get things done

R
#793 Rbor

Wavy Davy But to get the "green tick"

How and where do you get the 'green tick'. I don't think I have ever seen it!

Rob

R
#794 Rbor

geoffreycoan No, right at the start of apps.yaml is the predbat module name so everything below that is a sub-component within the predbat module so has to be indented 2 spaces.

I have checked through the whole of my apps.yaml file and all my entries after the initial 'predbat' line start indented by 2 spaces, but .... (See question below).

Question:
When using a hyphen, there are 2 spaces before the hyphen but one space after the hyphen.
I guess this is just yaml rules.
_I have just noticed that I have just 1 space before a hyphen below (and I have just added a space before the hyphen to each of the 2 lines) _

  # Currency, symbol for main currency second symbol for 1/100s e.g. $ c or £ p or e c
  currency_symbols:
   - '£'
   - 'p'
``` 

Thanks

Rob
W
#795 Wavy Davy

It's in file editor top right. Says it thinks the code is ok and allows you to save the file.

#798 PianSom

geoffreycoan

Thanks, now I understand what you are doing, and see why you are getting the failure with ha_url set.

Other than the obvious (ignore ha_url if a call to ha_url/addons/self/info fails; it is not a method of avoiding DNS calls since it won't work) I have no suggestions.

D
#799 Daveb01

[unknown]

Hi yah, had another look and it looks like if I don’t have an EV they will spot it after a while and move me to a different tariff, plus I am on Fixed Export at 15p, this is not supported either.

So going to stick with Agile at the moment.

G
#800 geoffreycoan

Daveb01 Hi yah, had another look and it looks like if I don’t have an EV they will spot it after a while and move me to a different tariff, plus I am on Fixed Export at 15p, this is not supported either.

I don’t know how Octopus would necessarily spot that you don’t have an EV. If your pattern of behaviour is similar to an EV, charging at high kWh overnight in the cheap period. You don’t need a specific charger or car compatibility (like IOG) and you could use a granny charger.

Of course if they ask for proof of an EV …. don’t want to get swapped to SVT if you’ve been charging overnight etc.

I was a bit unhappy when Octopus swapped me from Flux Export to 15p Fixed export when 6 months after the event they spotted that they’d not changed the export tariff when I moved from Flux to Agile, and I got back-billed for the entire 6 months of ‘flux like exporting’, but when I worked it out it wasn’t that much. Still could have been.

Your Fixed 15p export is Outgoing Octopus. There’s a compatibility table https://octopus.energy/help-and-faqs/articles/which-export-tariff-can-i-combine-with-my-import-tariff/

T
#801 TX200

Is there anything that can be done to make this display nicer on a small screen?

#802 PianSom

Daveb01
I suggested you look at the Intelligent Octopus Go (not Octopus Go, which you have screen-shot) T+Cs

And, as Geoffrey says, both can be used with 15p export anyway.

R
#803 Rbor

TX200 it’s a bit better in landscape but small screen is always going to limited for the bar charts.

The house icon is useful for getting the zoom back to default (for when I get lost)

Rob

T
#804 TX200

[unknown] that was landscape 🤣

D
#805 Daveb01

geoffreycoan

I have a GE EVC I got free with the second AIO, this will be visible in the GE Cloud and my system. If there is no power going though it, it will become obvious I guess.

I clicked the GO tariff to see what’s required and have already got a switch notice if I tick the t&c? Hhhmmmmm what to do now. Do you think if they move me back to a standard tariff I can mot move back to Agile for 30 days?

D
#806 Daveb01

PianSom

With IOG, you have to pick a car and charger, so can mot get that one. My charger will also know if a car is plugged in, especially IOG, as they randomly give you extra slots?

#807 PianSom

[unknown]
Like I said, read the T&Cs and make your own mind up. But iirc the Giv EV charger is not compatible with IOG anyway.

(BTW you can opt out of extra slots, which are not random.)

R
#808 Rbor

Daveb01 What do the tariffs show in the Compare feature.

If your shoes, I would go to Flux for now. I would disregard PV for next week!
In the 3 hour cheap import window, your AIOs should be able to charge up well (certainly compared with my pathetic 2.8 kWh per hour). In Compare, Flux is coming out over £1 cheaper than Agile per day for me.

If I was going to 'risk it' I would see if I could get onto Cosy. The worse that could happen is that you would be told 'that you need a heat pump'. Check the T&C.

Personally, I wouldn't risk things and go for an alternative that I know I would be able to get on.

Flux daytime export is disappointing but you could probably get back any deficit from Outgoing export by doing an hour's Flux export sometime between 4 and 7pm.
What does Compare suggest?

In our hearts, we want to return to Agile but those rates do need to make it worth our while.

Rob

R
#809 Rbor

Wavy Davy I have never noticed the green tick but it is there.

I experimented with my currency symbols code.
With the 2 hyphened currency lines, I got a green tick irrespective of the indent from the currency symbols line above, provided that the two hyphens were aligned one above the other.

It looks as if the green tick has limited use! Try it out, just don't save!

Rob

#810 PianSom

I am looking at the Compare output. In pretty much every line there’s about £1 difference between Cost and Cost 10%. On a day when there’s pretty much no PV forecast (must be under 2kWh) or occurring that seems unlikely.

Just me?

B
#811 browellm

Really impressed with how quickly PredAI has adapted my estimated usage based on us going on holiday only yesterday and our background house load is now only around 180W. Some nice Agile export scheduled between 5:30-6:30pm today to offload the excess battery.

G
#812 geoffreycoan

PianSom looking at the Compare output. In pretty much every line there’s about £1 difference between Cost and Cost 10%. On a day when there’s pretty much no PV forecast (must be under 2kWh) or occurring that seems unlikely.

On mine there is nearly £3 difference on Cosy and over £4 on Flux and Agile.

I assume the cost 10% is based on the 10% scenarios, i.e. PV10% and load_scaling on the house load.

Do find 3 different costs confusing as I don’t know what they all tell me. I should probably watch Trefor’s video and then add it to my to-do to enhance the documentation in this area

R
#813 Rbor

PianSom In his video, Trefor reminds that the True Cost' column is the one to use for comparisons. It tries to compensate for differences from starting from a full battery to an empty battery after 24 hours. Worth watching the video more than once.

My current PV predictions in Predbat are for about 2 kWh in a day. My last 2 days have been 450Wh and 620Wh. So far today (at 2 pm), I have chalked up 578 Wh and my current solar power is 100 W. Hence, I would just forget about PV now, and for the next week. Certainly, any export would have to be forced.
This is my profile for today, taken at midnight (notice that Cosy is just less than Go):

Rob

W
#814 Wavy Davy

Anyone else getting some different plans since the updates?
I seem to be getting long periods of charging.
here's what I had last night, and its similar today.


Seems to have happened since the last updates.

R
#815 Rbor

[unknown] In his video, Trefor goes for the True Cost column.
The video fills in some information gaps!

The starting SOC reading is based on 'Current' for all the tariffs.
The EV tariffs typically finish the day low with the cheap slots overnight.
So if the EV tariff is set at 63% at midnight, same as current, It is probably about 50% over. So the True cost tries to compensate (at to a point), adding costs onto the Cost total. You can see this in the Compare chart I have just posted.
The 10% is like the effect of PV 10% and Load 10% margins.

.... at least that is my understanding, which may be flawed of course!

Rob

R
#816 Rbor

geoffreycoan In his video, Trefor goes for the True Cost column.
The video fills in some information gaps!

The starting SOC reading is based on 'Current' for all the tariffs.
The EV tariffs typically finish the day low with the cheap slots overnight.
So if the EV tariff is set at 63% at midnight, same as current, It is probably about 50% over. So the True cost tries to compensate (at to a point), adding costs onto the Cost total. You can see this in the Compare chart I have just posted.
The 10% is like the effect of PV 10% and Load 10% margins.

.... at least that is my understanding, which may be flawed of course!

Rob

G
#817 geoffreycoan

Phew

Yesterday with the power work the mesh node in the garage was off as was the Octopus mini. HA was still up and Predbat complaining and restarting givtcp because it couldn’t talk to the inverters. So I knew the energy dashboard would miss out a load of data and have a spike when everything came back.

But wasn’t expecting Octopus to have a spike as well

With the Octopus Home Mini not being powered on until just after 4pm, Octopus stuck all my afternoon Cosy import as being in the peak rate

But Octopus compare (using the DCC meter data) shows much more what I’d expect. I waited to be sure that the afternoon charge started at 1pm before I cut the power off, and at the end of the charge period the inverters went back to Eco mode (verified with the BBC app as soon as I got the wifi back on).

Fortunately Octopus has caught up and now has loaded the DCC data over the OHM data. You can see how first one then the other battery runs out in the evening and I start grid importing ahead of the 10pm Cosy slot.

R
#818 Rbor

Wavy Davy With the size of your Agile tariff import rates, Predbat seems to have decided to just use the grid. It is only when the peak Agile rates are hit that behaviour changes.

Rob

G
#819 geoffreycoan

Wavy Davy Anyone else getting some different plans since the updates?
I seem to be getting long periods of charging.

that’s not really charging, its holding the SoC at 100% and grid importing because there’s no benefit to releasing the SoC until the import rate rises.

Have seen it before on flat Agile import rates, the rate variations are not enough to counter the battery losses until the 4pm peak period

#820 PianSom

geoffreycoan i.e. PV10% and load_scaling on the house load.

Rbor The 10% is like the effect of PV 10% and Load 10% margins.

Ah, that'd be it. I thought it was just PV10%.

Thanks, both.

R
#821 Rbor

geoffreycoan This reminds me of my woes trying to get my dongle working again after my power cuts.
You are no different from me, wanting to see instant results. It is good that Octopus did finally catch up, saving you about £4 in the process for yesterday.

Rob

D
#822 Daveb01

As I have reached day 70 on inverter writes I thought I would share.

G
#823 geoffreycoan

[unknown] thats a decent low average per day. Day 51 for me and average 59 per day per inverter. So 4 an hour.

I think there is still some room for improvement in some of the predbat activity, especially seen some weird behaviour in the low charging mode. Think its dropped off Trefor’s radar though 😔

R
#824 Rbor

After 71 days, my average is creeping down and now at 57.
Cosy certainly has far fewer writes than Agile. Today, I have had just 9 writes!

Rob

W
#825 Wavy Davy

73 days and ave 71. Was an ave of 66 just before Xmas, so rising.

W
#827 Wavy Davy

Anyone else getting error messages when posting, then finishing up with a double post?
I get on both my macbook and android tablet.

G
#828 geoffreycoan

Wavy Davy Anyone else getting error messages when posting, then finishing up with a double post?
I get on both my macbook and android tablet

Almost every posting, the post gets an error message about trying again, but pretty much always it does post OK so if you re-post you end up with duplicates.
What I do is post, if I get an error I click on the GivEnergy logo at the top, go back into the thread and see if the first posting has actually worked or not. Most of the time it has so I just click X on the draft post at the bottom so I don’t create a duplicate

B
#829 Boffinboy

I know this is not strictly Predbat related, but wondering if those of you still using gas are staying on tracker as the rates have climbed? I know it’s not easy to switch back and forth but it currently stings a bit given its currently peak heating period. I’m using my A2A as supplemental heat, but can’t / don’t like to use it to cover all heating demand.

#830 PianSom

Boffinboy
It’s a tough one.

I loved gas Tracker most of last year, but gambled and moved to Fixed in November. Turns out it was the right thing to do. See https://agilebuddy.uk/historic/tracker/gas for a comparison.

I too use A2A as supplemental. I’m not sure how cost effective it is - heating a small area for a short time at an expensive import rate (as battery is empty in the evening), compared to running the whole house central heating with (relatively) cheap gas.

But I am getting a bigger battery this week, and with a COP of around 3 and an electric cost of 7p (before losses) the decision will soon be more clear for me. (So sort of Predbat related!)

T
#831 TX200

35 writes here. 72 days of data.

Agile was a bit flat in early Feb and possibly late Jan, so it wasn't doing anything crazy! Now on flux, so I guess it'll continue to drop a bit.

Ended the day with 6% battery (empty) for 30 minutes before the cheap rate charge kicked in. Wasn't any solar to top up the battery yesterday and I did run the washing machine in the evening. Worked out pretty well!

As for gas, I exited tracker in early January and haven't regretted the 5.74p/kWh fix so far!

W
#832 Wavy Davy

I'm on fixed gas with octopus at 5.55 p/kw

W
#833 Wavy Davy

I'm on fixed gas with Octopus at 5.55p/kW

T
#834 The Black Cat

I'm trying to set-up Geoffrey's Saving session automation, [https://community.givenergy.cloud/d/5359-automating-saving-session-events-into-predbat] primarily to allow me to adjust the predbat load for a particular date/time. However, I'm running in to a problem and need to check if I'm doing something daft or there is a bug that has been introduced.
If I set a date and time for the "saver session/load adjustment" then the Manual API is set and it appears in the predbat log file but it does not action.
e.g. Set date 2025-02-11, Start: 16:00, End: 17:00, Rate increment: 20, Load Scaling: 2
Manual API:-

The predbat log files shows:-
2025-02-11 15:15:19.971745: Adding rate rates_export_override: {'index': None, 'date': '2025-02-11', 'start': '16:00:00', 'end': '17:00:00', 'rate_increment': '20', 'load_scaling': '2.0'} => 02-11 16:00:00 to 02-11 17:00:00 @ 20.0 date 2025-02-11 00:00:00 day_of_week [] increment True
But there is no change to the Predbat plan.
However, if I removed the date from the API, the predbat plan showed the correct increments in rates/load.
So I took the API out of play and made the same changes in apps.yaml
With the date included, no changes were made to the plan and with date excluded it worked as expected.

  rates_export_override:
    -  date: '2025-02-11'  
       start: '17:00:00'
       end: '18:00:00'
       rate_increment: 20
       load_scaling: 2```
Predbat logfile:-
2025-02-11 15:22:16.001936: Adding rate rates_export_override: {'date': '2025-02-11', 'start': '17:00:00', 'end': '18:00:00', 'rate_increment': 20, 'load_scaling': 2} => 02-11 17:00:00 to 02-11 18:00:00 @ 20.0 date 2025-02-11 00:00:00 day_of_week [] increment True
```  # To improve on saving sessions avoid export during peak periods
  rates_export_override:
  #  -  date: '2025-02-11'  
    -  start: '17:00:00'
       end: '18:00:00'
       rate_increment: 20
       load_scaling: 2```
Predbat logfile:-
2025-02-11 15:24:57.485849: Adding rate rates_export_override: {'start': '17:00:00', 'end': '18:00:00', 'rate_increment': 20, 'load_scaling': 2} => 02-11 17:00:00 to 02-11 18:00:00 @ 20.0 date None day_of_week [] increment True

So have I missed something with the date or is it not functioning as expected?
T
#835 The Black Cat

I was having problems coping the predbat plans to the forum but have now managed to do it.
Predbat plan with date included:-

Predbat when date excluded:-

G
#836 geoffreycoan

[unknown] I'm trying to set-up Geoffrey's Saving session automation, [https://community.givenergy.cloud/d/5359-automating-saving-session-events-into-predbat] primarily to allow me to adjust the predbat load for a particular date/time. However, I'm running in to a problem and need to check if I'm doing something daft or there is a bug that has been introduced.

Appears there was a bug in setting the rate override https://github.com/springfall2008/batpred/issues/1999

Trefor has fixed it and there’s a new version on main

No power up event for me today ☹️

R
#838 Rbor

Last 6 days of solar generation in kWh:

19.59 kWh was last Thursday.
I am now projected to generate less energy this February than in January.

How much longer is this dreariness with perpetual drizzle going to continue?
Temperature reached a tropical 1C today.
I have forgotten what the sun looks like.
😩
Rob

G
#839 geoffreycoan

Rbor I thought I was doing badly with my solar generation.

5/2 17.2kWh
6/2 14.8kWh
7/2 3.6
8/2 5.3
9/2 4.8
10/2 2.9
11/2 3.1

3.1kWh exported across the 3rd and 4th February. Nothing since then

G
#840 geoffreycoan

Am pleased with the move to Cosy, peaks are lower than they are on Agile, the day-rate is generally a tiny bit higher than Agile so it costs slightly more to run when I run out of battery but this is more than offset by the 8 hours of charging and operation at 13.2p.

The batteries continue to run out in the evening just after the peak is over (a bit more capacity would help here), but they did that on Agile as well. During the day the batteries will last from the morning charge to the afternoon charge if the weather is mild, but if it’s not they do run out. Yesterday they ran out about an hour before the 1pm charge and today it was about 40 minutes before.

I have to switch Predbat into read only every morning and manually set the battery reserve to about 27% on inverter 1. I leave them both in Eco mode but have to stop the inverter with the 9.5 discharging below 27% as otherwise there isn’t enough time in the afternoon charge period to charge the battery fully before the peak - and I need full capacity for the peak. So had to write an automation for this (and setting the tumble dryer off time to coincide with the end of each Cosy period) until Trefor enhances Predbat to enable me to configure this dynamically

R
#841 Rbor

geoffreycoan I think we bailed out of Agile just in time.
Have you seen Agilepredict for the rest of this week?

I still had 0.00 kW PV power at 10 am this morning! So I was lucky to get up to 0.55 kWh for the day.

With its 3 cheap slots, Cosy gets me comfortably through the day without batteries running dry.
Pity that the ASHP reserves one its many defrost cycles for just after 4 pm.

Rob

#842 Windy Miller

Now you've all moved here (and I detect an air of smugness) I'll comment that I can just about get through the day with 6 charge slots with holds lasting for all but the morning and evening peaks (on Agile). Worst charge tomorrow costing me 24.92p. Worst hold is 29.55p. It's tight but as I can't get Cosy nor Go and I don't have a large enough battery to carry me through I'd only be marginally better off on Flux and I hope it's only for this week. When the Sun shines on Friday I should only need 3 or 4 overnight charge slots.

L
#843 Leeshore

Windy Miller I've moved to flux. I'm much more relaxed as I'm not looking at the rates all the time. P.S. don't you have some wind power as well? 🙂

#844 Windy Miller

Leeshore Not much wind for the next 10 days. Sun though from Friday will help me charge the batteries. Temperatures recover a bit from the middle of next week so I'm still sitting tight for the moment (and quite relaxed as before I had the kit I was paying £1500 for my Leccy).

V
#845 Vestas

geoffreycoan I'm not even looking at my PV generation 😃

Grey, no wind, fog in the morning. Rinse/repeat.

H
#846 Henry3rd

There's nothing agile about agile currently!

G
#847 geoffreycoan

[unknown] Have you seen Agilepredict for the rest of this week?

I have, very flat, 26p for most of the week, 46p in the evening peak and lowest predicted price of 22p overnight on the 14th.

The Agile plan in Predbat compare shows it struggling to find cheaper slots with lots of hold charging occurring. In reality if I was on Agile not Cosy I think the price prediction would be worse because when the Predbat compare runs at 00:00, its just after Predbat has part filled my batteries in the 22:00-00:00 Cosy slot. On Agile my batteries would be empty.

But tomorrow, 14kWh of solar predicted ! Predbat is throwing Freeze Exports in for the morning, giving me a massive 4p of export income at the giddy heights of 15.3p export rate. Once the sun gets up it drops back to 12.5p though.

Update: latest forecast is 3p of export income!

H
#848 Henry3rd

[unknown] Update: latest forecast is 3p of export income!

Have you planned to reinvest this unexpected windfall?

B
#850 Boffinboy

PianSom I think I’ve clearly missed the boat on the gas, and it’s been terrible through the whole cold period, so I’ve paid more than I saved through the rest of the year I’m sure…!

I’m in two minds about the effectiveness of the A2A. I am not sure how much it reduces the gas demand, but the COP is meant to be quite high, so I figure it’s worth trying.

#852 PianSom

Boffinboy
I'm not sure what fixed deal is available now from Octopus, but

  • they don't tie you in, so you can switch back to variable at any time at no cost if prices fall
  • the international political situation is not showing much sign of impending stability
  • the trend on wholesale gas prices is clear (for now, at least), see https://tradingeconomics.com/commodity/uk-natural-gas

On the other hand

  • the majority of Winter is behind us
  • you can't get back on to Tracker for quite a while
  • you can't get back on to the version of Tracker you are now on (probably).

So who knows what is best? No crystal ball, sadly.

In my household there is a strong desire to sit in tropical temperatures of an evening. Last year (pre-A2A) that meant central heating or log fires. My gas and log consumption has been dramatically lower this year. But whether it has been cost-reducing I don't know. I suspect so, and I'm sure next Winter - with the new battery - will be better (so giving me an improved, and maybe even acceptable, payback period).

J
#853 Josephiah

Can anyone shed any light on the significance of the changes announced in Predbat v8.15.0 just now...? Does this mean it is losing its dependency on GivTCP?

"Features
Givenergy Cloud is now integrated into Predbat, by setting ge_cloud_direct : True in apps.yaml you can directly control Givenergy inverters with[out?] the need for a seperate integration."

G
#854 geoffreycoan

Josephiah There has been for some time a separate integration Trefor wrote called 'GE Cloud', its on his github page (I have installed it).

This gives another option for talking to your inverters, instead of talking via givtcp you can talk to your inverter via the GivEnergy cloud. The data is only as good as 5 minute timeslots but it does work and I used it as a fallback when I accidentally purged my entire grid import sensor (0 days history) which predbat didn't like.

This release removes the need for the separate integration and brings the code into Predbat. Much as Predheat was a separate addon and is now integrated.

Its just an alternative option I don't see givtcp being removed

T
#855 TX200

Rbor turns out it was a bug in the code. PredBat ignored any rate overrides that had a date. It used to work. Just been fixed in the latest version.

G
#856 geoffreycoan

geoffreycoan

@PianSom @Wavy Davy (and probably @Rbor because he loves to live life on the edge)

You and your b**dy warning messages

Wavy Davy 9166 2025-02-09 14:58:16.373492: Warn: Failed to decode response from http://192.168.1.26:8123/addons/self/info

I have spent far too long on this tonight. URL's, supervisor vs HA tokens, Bhah

If you install this ha.py into your predbat directory, restart predbat, it should now not log a warning message for either of you and @Wavy Davy should get the printable config path correctly determined in the logfile.

If it works OK on docker I will merge it into my next PR. I've tested it on HAOS with and without ha_url set and it works fine (scenarios 1 and 3).

I tried multiple times to upload it to the forum but it kept rejecting the file type, so here it is on my google drive which you should be able to download it from https://drive.google.com/file/d/1C_HyzoX9vOWs4UKnxh4jvNLv2QeaAxb8/view?usp=sharing

R
#857 Rbor

geoffreycoan For once, this hasn't affected me and I don't really understand what the issue is all about!

Rob

G
#858 geoffreycoan

Rbor in the predbat logfile when predbat restarts it works out what the add-on id is and uses that to determine the 'printable config path' that is used when logging things like the name of the predbat dashboard being created, the saved json config, etc.

If you are running in docker you would get a warning message that an API call was failing, and if you were running HAOS but had set ha_url in apps.yaml then you'd also get a warning and predbat would fail to work out the predbat addon id so all the pathnames in the logfile were wrong.

All of these cases are now fixed. If you install the file you should see predbat continue to work unchanged for you

R
#859 Rbor

[unknown] Thanks for your explanation which explain why the issue made no sense to me:

  1. I don't use docker.
  2. ha_url isn't in my apps.yaml. I can see that it is in the apps.yaml template but commented out.

I will leave well alone.

Rob

R
#860 Rbor

geoffreycoan Thanks for your explanation which explain why the issue made no sense to me:

  1. I don't use docker.
  2. ha_url isn't in my apps.yaml. I can see that it is in the apps.yaml template but commented out.

I will leave well alone.

Rob

J
#861 Josephiah

@geoffreycoan #p76011 ah, okay, that makes more sense. Thanks.

W
#862 Wavy Davy

geoffreycoan you know you love us really.....
😄

G
#863 geoffreycoan

last hour spent working out how to migrate home assistant statistics from one sensor to another

From:

to:

This is one of the sensors I created a filter sensor for to reduce the volume of records in the HA database. I created the new sensor on 9th October but there was about a year's worth of historical data on the old sensor that was missing, hence why the graph starts on 9th October.
And now I've moved the history data across, ensuring complete data in the Energy dashboard

#864 PianSom

geoffreycoan
Don’t blame me - it was @Wavy Davy who was whining!

Sadly, I don’t generally build my own docker images, I just pull nipar44/predbat_addon, so don’t have access to the underlying python. Sorry!

If my bloody Pi5, which I have ready to go as a new HA dedicated Energy-vlan machine, would stop silently crashing every 24-48 hours I wouldn’t care about the warning anyway. But that’s another problem.

R
#865 Rbor

[unknown] If my bloody Pi5, which I have ready to go as a new HA dedicated Energy-vlan machine, would stop silently crashing every 24-48 hours I wouldn’t care about the warning anyway.

Strange. I have had pi3, 4 and 5 and they have all been ultra reliable, never missing a beat.
Are you using the proper pi5 plug?
With my pi4, HA was throwing up warnings about a potential dodgy power supply. I found an integration that monitored the power supply, purchased the pi4 plug and warnings stopped.
The pi5 takes more power than older pi's.
https://www.home-assistant.io/integrations/rpi_power
https://shop.pimoroni.com/products/raspberry-pi-27w-usb-c-power-supply?variant=41044500349011

Rob

R
#866 Rbor

PianSom If my bloody Pi5, which I have ready to go as a new HA dedicated Energy-vlan machine, would stop silently crashing every 24-48 hours I wouldn’t care about the warning anyway.

Strange. I have had pi3, 4 and 5 and they have all been ultra reliable, never missing a beat.
Are you using the proper pi5 plug?
With my pi4, HA was throwing up warnings about a potential dodgy power supply. I found an integration that monitored the power supply, purchased the pi4 plug and warnings stopped.
The pi5 takes more power than older pi's.
https://www.home-assistant.io/integrations/rpi_power
https://shop.pimoroni.com/products/raspberry-pi-27w-usb-c-power-supply?variant=41044500349011

Rob

#867 PianSom

Rbor
No plug/PSU. I am using a PoE hat (and a NVMe base). It's almost certainly a hardware issue, and I suspect the base.

I have lots of Pi[x]/PoE hat combos around the place and they are all stable as a table. This hat is specifically for a Pi5.

I'm going to have to reformat everything and run some hardware diags. <sigh>

D
#868 Daveb01

Rbor

Did you get the shopping list from Speak to the Geek? He’s has been helping out Gary does Solar. I like the case as you can put the HDD at the bottom.

K
#869 KamenMacKay

[unknown] I've been using Go with the fixed 15p export for the past two winters and I don't have an EV. They've never checked if I actually do. I think it's worth the risk of switching because worst case they switch you to another tariff and best case you get the best of both worlds with the low rates and the fixed export.

K
#870 KamenMacKay

Daveb01 I've been using Go with the fixed 15p export for the past two winters and I don't have an EV. They've never checked if I actually do. I think it's worth the risk of switching because worst case they switch you to another tariff and best case you get the best of both worlds with the low rates and the fixed export.

R
#871 Rbor

Daveb01 My shopping list is my own, Compiles with the aid of youtube videos.
I like https://www.youtube.com/@ExplainingComputers
Entertaining with a raw sense of humour.
pi5 videos are https://www.youtube.com/playlist?list=PL2m2YvnrOYxIruF90iAnw3LDym1FeNQ2c

I get pi stuff mainly from https://shop.pimoroni.com
Great service and lots of help with setting things up.
For my pi5, I use a pi hat with an NVMe base and SSD drive. Real geek land stuff.
I use an external SSD drive for my pi4.

With most devices now being sealed, I like being able to tinker with a computer, just like we used to do. So a raspberry pi, HA with Predbat fits in nicely with this. A big plus of using a pi is the minimal energy requirement (several watts) for a device that is on 24/7.

I have thought about getting the Argon case as my pi5 sits there with no case!
This case is expensive does have some mixed reviews though which has put me off.
I am sure that yesterday's DFS windfall can start my pi-case fund.

Rob

D
#872 Daveb01

[unknown]

I have swapped to GO with Agile export as get a higher rate from 16:00 - 19:00.
Thank you all 👍😀

D
#873 Daveb01

So day one, hhhmmm not sure.

I am ok with the charging.
I can see 2 Predbat strategies, outgoing Agile and Outgoing fixed.

Outgoing fixed discharges the battery at the end of the day ready to charge again.
Not as much cash but more battery left at end of day.

Outgoing Agile discharges the battery between the peak times, it is a big gap before the charge so battery (tonight) is empty a few hours before and costing to use electric.
A bit more cash than above but no battery for a few hours, that reduces the cash.

Any ideas on what you guys would do please? Stick with it or alter a few things?

Predbat wants to discharge during all of the peak times (with my discharge level) the batteries are nearly flat. If I reduce this would it be better to go back to fixed?

I will stick with it for a week or so to see how it goes but will get worried if battery is flat every day by 9pm & if I start getting SoC drops.




G
#874 geoffreycoan

Daveb01 maybe tweak your best_soc_keep up a bit to encourage predbat to keep more soc in reserve, and/or change input_number.predbat_best_soc_keep_weight to weight the value of keeping the soc (not a setting I have used but Trefor has added it recently)

R
#875 Rbor

Daveb01 It looks pretty good.
Predbat has made sure that it is exporting between 4pm and 7pm at Agile outgoing's peak time.
Give it a few days (you suggest a week).

Now on to mine!
Predbat is now predicting 16.5 kWh of PV generation tomorrow with my first 🌞for 9 days!
I will believe it when I see it and will dust off my shades in anticipation.
Anyway, I am now on Cosy and 15p fixed outgoing.
This is my first chance to see how predbat with cosy deals with PV.

Predbat is exporting PV between 10:00am and 12:30 am @ 15p and then charging between one of Cosy's cheap slots between 13:00 and 16:00. Any bonus to me is probably marginal when losses are considered. I guess with Agile outgoing the exporting would take place between 16:00 and 19:00. I will get a better idea come the midnight compare data.

Rob

G
#876 geoffreycoan

Rbor Predbat is now predicting 16.5 kWh of PV generation tomorrow with my first 🌞for 9 days!
I will believe it when I see it and will dust off my shades in anticipation.

Today was forecast 10.8kWh for me but I only achieved 5.9kWh under cloudy skies. Still, it was reasonable weather so I went flying instead of fiddling with Predbat

Tomorrow forecast to be 18.9kWh, but like you, I remain sceptical.
Octopus must think it’ll be nice because I’ve got a 2 hour powerup event, right across the top of the Cosy afternoon charging period which is handy

D
#877 Daveb01

geoffreycoan

This is what I have set at moment?

G
#878 geoffreycoan

[unknown] doesn’t look like it is honouring that best soc keep as the battery is being drained to empty.
Only costing you about 20p on Thursday night and less on Friday, but still.

Try bumping the weight up a touch to see if it improves the SoC retention

B
#879 Boffinboy

PianSom thank you, this is really useful! I might just stick with the tracker - take the rough with the smooth!

R
#880 Rbor

Daveb01 geoffreycoan
This is what I have set at moment?

My Best SOC keep is set at 0.80 kWh but seems fine on cosy (0.80 was also my setting in Agile).

Rob

T
#881 TX200

PredBat was hoping for more sun. Not sure solcast is right today. Got to 6%, now at 14%.

Doesn't look likely I'll reach 100% with solar as originally planned. 🤣

R
#882 Rbor

TX200 Yesterday, solcast reckoned 16.5 kWh PV for today.
Now down to 13.1 kWh prediction (mine is set up as every 6 hours).
11:16 and I have chalked up 1.77 kWh.
Sky is lighter grey but still to sight the fabled sun.
... and its really very cold today (0.3C) with raw easterly wind🥶

So no export for me today with Predbat grabbing all the Cosy cheaper slots.

Rob

T
#883 TX200

Rbor estimate 7.6 down to 5.4kWh so far.

Actual 1.1kWh so far.

Mine still reckons a bit of export. Will see!

My solcast is set to update on an hourly basis, with slightly randomised minute and second values. I think we get 50 calls a day on the original accounts, so may as well get it updated regularly. New accounts might be 10 per day?

T
#884 TX200

Now that my tariff is all sorted for flux import and export ..

We'll hear that gas prices are dropping.

(Plot twist, apparently that's happening!)

So far PredBat compare says flux was the right decision.

Will have to see how it pans out! 🤣

G
#885 geoffreycoan

Rbor Generating 3.2kWh off my panels at the moment 👍

Waiting for @Wavy Davy to tell me that the fix I made to stop the warning message is working before I upgrade to the latest Predbat. So stuck on a version where the manual API doesn’t work for the powerup.

Manually added the 2 hour zero rate period to apps.yaml and Predbat is now planning some forced export 😁

W
#886 Wavy Davy

[unknown] Sorry Geoff, been a bit busy last few days so not been on here.
Which directory do I install ha.py into, is it the addon configs?

G
#888 geoffreycoan

Wavy Davy yes, just overwrite the existing ha.py in /addon_configs/6xxxxx_predbat

W
#889 Wavy Davy

If I look on GUI log I seem to have more errors than ever.
Struggling to download error file.
I am rebooting HA and will look again.

W
#890 Wavy Davy

W
#891 Wavy Davy

Geoff,
I think it started ok, Here are Predbat addon logs.

6adb4f0d-predbat-2025-02-14t13-07-28602z.txt
6kB

Will have to leave this until tomorrow as I have to go out now.

G
#892 geoffreycoan

Wavy Davy Damn, thanks for testing it, at least I know there is a problem rather than it being merged in by Trefor and failing in the field.

Am surprised by this.

The addon log doesn’t show me much. Could you share either the full predbat.log or the bit around where it starts up with the new code installed.
What’s your ha_url set to in apps.yaml?

T
#893 TX200

Well the good news is octopus have confirmed the flux export will be backdated to the day I applied for flux.

So it was wise for me to edit the tariff in apps.yaml to get the exports to happen.

I originally set an override. But then when we had the saving session I had to change it to a rate increment to get the correct price including the saving session payment!

Then as soon as HA knew about the new tariff I had to remove that increment, otherwise it'd be wrong again! 🤣

R
#894 Rbor

geoffreycoan if you look back Wavy Davy, you will see the relevant ha_url address. Using my freshly-trained eyes, this should be correct.

Rob

G
#895 geoffreycoan

Rbor thanks Rob, the ha_url looks correct as you say.

Looking at Wavy Davy it looks like every single API call to Predbat is failing which I don’t understand why. I added logic to get the supervisor token separately and use that for the initial slug id API call, but the original API logic is unchanged.

@Wavy Davy I’ve added some more logging to the api_call function, updated ha.py via the same link above. If you can try installing this and let me see the predbat logfile, especially just after predbat starts up after the new file is installed it should give me a clue what’s happening.

R
#896 Rbor

Wavy Davy geoffreycoan

When you download and then upload your predbat.log file, make sure you use the most recent version. For me, this is after the 'archive' logs 1–9, like this:

I don't know when it changed!

Rob

G
#897 geoffreycoan

Rbor I don't know when it changed!

Rob

I changed the predbat code to keep 9 log files and changed the file extension. Originally it was only keeping one, called predbat.log.1 which made it difficult to open.

D
#898 Daveb01

Anyone thinking of moving to the new HA backup as it now supports Google Drive and NAS etc, with loads of settings?

R
#899 Rbor

geoffreycoan
When I look back at the earlier ha_url posts Wavy Davy #750, then Predbat.1.log was posted. It wasn’t obvious that the most recent log was the last in the list.

Could 0 be used for the most recent log, which would place the log at the top of the sequence, say Predbat.0.log. ?

Or would that introduce confusion?

Rob

R
#901 Rbor

Daveb01 Anyone thinking of moving to the new HA backup as it now supports Google Drive and NAS etc, with loads of settings?

I am now on 2015.2.2 and have just looked at using Google Drive from Backup.
No link to Google Drive appears and the HA documentation suggests that I need to install a new Google Drive integration.
I am afraid that I do not understand any of the instructions:

I have no idea what 'the Cloud Console' is, nor 'the OAUTH consent screen', etc.
I have tried to set up OAUTH consent but have no idea what I need to input.
Setting up credentials seems to have 16 steps.
This is virtually impenetrable.

...... So I will continue to just use the Google Drive add on.
I have only ever used Google Drive with the HA Google Drive add on which is dead easy to set up.
Has anyone else had any luck here?

Rob

G
#902 geoffreycoan

[unknown] Not tried it yet myself

I will take a look at the new backup options, its improved from what is in 2025.1 but a key thing I would want to see are ability for multiple schedules (e.g. daily, weekly). The add-on handles this very well saying to keep for example 7 daily copies, 4 weekly copies, 12 monthly copies.
From what I have seen the HA backup only offers a single "keep X copies" which is too limiting

What I am thinking of doing though is to setup a monthly backup schedule of all the add-ons using the new backup (and probably a new Google drive account as well). My daily backups don't include the addons (to save backup size) and so I have to change the backup settings each month, do a manual backup of the addons and change the settings back. The HA backup could be easier for doing a separate addon backup schedule

R
#903 Rbor

Got up to 10 kWh solar generation today from a very hazy pm Sun.
That's more than the previous 7 days put together.

Next 2-3 days look grim with potential snow for me.
Then 'spring like conditions by end of next week.

What a grim winter it has been ...............

Rob

G
#905 geoffreycoan

Love the Predbat compare feature?

Find yourself checking it daily?

Fed up with the drudgery of having to make several clicks to navigate to the Compare page of the Predbat Web Console?

….. little solution for you, add the following as a card on your dashboard or in an existing entity list on the dashboard:

- type: entities
  entities:
    - type: weblink
      name: Predbat Web Console
      url: /hassio/ingress/6adb4f0d_predbat
    - type: weblink
      name: Predbat Compare
      url: /hassio/ingress/6adb4f0d_predbat?1

I’ve raised a FR https://github.com/springfall2008/batpred/issues/2015 to have this a bit more logically structured and documented properly, but it does work. I found some other parameters that lead to specific pages

T
#906 TX200

I just added PredBat to the left hand menu.

It seems to remember what page I was last on too.

L
#907 Leeshore

Following on from @geoffreycoan I've just added that to a badge which you can use and alter for yourself:

type: entity
show_name: true
show_state: true
show_icon: true
entity: predbat.cost_today
color: purple
icon: mdi:currency-gbp
name: Electricity Cost Today
tap_action:
action: navigate
navigation_path: /hassio/ingress/6adb4f0d_predbat?1

When you click on it it goes to the predbat webui.

L
#908 Leeshore

TX200 Same here.

R
#909 Rbor

My Trefor Compare table looks broken!

I have run the Compare feature from midnight since 9th February and the data has been consistent. You can see the bars in the bar chart for today are all inflated.
Ignore 8th February as I ran this from mid morning, not midnight
This morning, my chart data looks inflated by about £1 across all tariffs.

In the predbat plans that follow, my 'Current' (which is Cosy with Fixed 150 outgoing) has always started at £0.00 and the 'True Cost' is always been a good match.
But today, I have £4.15 in the Predbat plan but £5.07 as the True Cost in the Chart.
In my 'Actual Predbat plan' for today my 23:30 entry is £4.13.

Is this likely to be a bug which I can report in GitHub?
See how your Compare chart and Compare plans correlate.

Amazingly, I have managed to upload 4 graphics and only had to repeat 2 of them!

Rob

W
#910 Wavy Davy

geoffreycoan Here you go Geoff, looks good to me, no errors at all showing on the GUI log and here's the latest predbat log file.

I am trying to upload the log file but the forum doesn't like either txt or rtf formats. will see if I can get some other way.

R
#911 Rbor

[unknown] Further to my previous Trefor Compare post, I am speculating about a reason for the strange table data.

Here's some thoughts:

  • The compare chart shows a line/curve for the 'Actual'.
  • On Thursday 13th February, Actual was £4.22: Minimal PV
  • On Friday 14th February, Actual was £3.26: 10 kWh PV
  • The difference is about £1.

Is the compare calculation for the table taking into account this historical data from last 2 days?

Rob

W
#914 Wavy Davy

Not sure if there's something wrong with my plan but it's showing 24.95p every slot up to Monday 10:30.
Cant be right?

R
#916 Rbor

Strange GE notification.
I received this notification during yesterday pm.
I have no idea what DCI means!

I have looked through the GE logs for this time and my only clue is this extract.
I am on Cosy and from 16:00, predbat changed to demand for the peak rates.
Between 15:00 and 16:00, stays was 'Hold charging'.

Any ideas. System is working OK.

Rob

R
#917 Rbor

My tale of woes!
I had an exception in the early hours of today (15th Feb) which cleared itself.

Any ideas?
I have saved the relevant predbat.log and can post as an issue on GitHub.

Rob

H
#918 Henry3rd

No, but I had exactly the same yesterday morning.
Sorry, I should say that I am referring to the predbat error.

H
#919 Henry3rd

Henry3rd 2025-02-14 09:12:21.476449: Error: Reported battery size from REST is 0.0, but it must be >0
2025-02-14 09:12:21.476556: Error: Exception raised
2025-02-14 09:12:21.480546: Error: Traceback (most recent call last):
File "/config/predbat.py", line 967, in update_time_loop
self.update_pred(scheduled=False)
File "/config/predbat.py", line 594, in update_pred
self.fetch_inverter_data()
File "/config/execute.py", line 636, in fetch_inverter_data
inverter = Inverter(self, id)
File "/config/inverter.py", line 356, in init
raise ValueError
ValueError
2025-02-14 09:12:21.515728: Info: record_status Error: Exception raised
2025-02-14 09:12:21.515957: Error:
Traceback (most recent call last):
File "/config/hass.py", line 184, in timer_tick
item"callback"
File "/config/predbat.py", line 973, in update_time_loop
raise e
File "/config/predbat.py", line 967, in update_time_loop
self.update_pred(scheduled=False)
File "/config/predbat.py", line 594, in update_pred
self.fetch_inverter_data()
File "/config/execute.py", line 636, in fetch_inverter_data
inverter = Inverter(self, id)
File "/config/inverter.py", line 356, in init
raise ValueError
ValueError

R
#920 Rbor

Henry3rd Interesting and suggests that there could be a predbat bug.
I have posted a bug report of GitHub.
Henry3rd Thanks for this.

Please add your exception report on Github following on from my issue report.
This would be added evidence.
https://github.com/springfall2008/batpred/issues/2018
Title: Exception: Battery size from REST is 0.0

Please also upload the relevant predbat.log to cover the time of your exception.
If possible, please also upload a debug log for your system. You will need to append .txt to the debug filename so that GitHub accepts the file. To generate the debug file, you will need to turn the switch Debug Enable ON. Once generated, turn it off or you will get zillions of debug files!

Thanks

Rob

G
#921 geoffreycoan

Rbor I wouldn’t worry about it guys, it looks like GivTCP didn’t get the data correctly from the inverter, predbat rejected it, but 5 minutes later on the next predbat run it all worked fine and set status to Demand

Trefor might have an idea but I get similar from time to time. Looking at my predbat status it had one at 22:30 last night, and then cleared at 22:35. Nothing in the givtcp logs at the corresponding time.

Our system is stuck together with different bits of software from different suppliers/developers. Sometimes bugs occur between the different bits. It looks like Predbat handled it gracefully and all good on the next run.

This is part of the reason why my predbat error detector doesn’t fire immediately it detects an error, it waits for it to be reporting an error for 15 minutes

W
#923 Wavy Davy

Geoff, Having problems with my system since installing ha.py file.
My predbat plan has every time slot set at 24.98p
This means It is constantly keeping the social at 100%
Is the file stored in HA, because I tried to delete it as a temporary measure but it keeps on re-appearing, even when rebooting the the dell client.

W
#925 Wavy Davy

Forget all above, it seems I've been switched to Flexible Octopus which is 25.98p.
This is news to me....

W
#926 Wavy Davy

Have just switched back, but absolutely didn't do this, and had no emails to say I was being switched.
When I just changed back I had 2 emails confirming what was happening.
Feel a strongly worded email coming on.

T
#927 TX200

Oh how things change...

Just found an old table I made that was to work out how much to charge my battery overnight depending on the estimated solar and wether or not I was working from home the next day.

So much easier with HA and PredBat. 🤣

G
#928 geoffreycoan

Thanks.

Its very strange, but also a bit enlightening

It looks like it starts working fine, gets the slugid for where predbat is installed correctly from the supervisor, then does a run through of predbat making API calls as it goes (all of which work ok), it writes out the predbat config file (with the correct file name in the logfile), and then Predbat should go to sleep, making a websocket asynchronous call - waking up if you change a predbat control sensor, etc.
It is this websocket that fails complaining that the connection is closed. It waits 5 seconds, tries again, fails, etc.

I’ve not changed the websocket code at all.

I have a guess that the failure is caused by predbat initially making an initial call to HA core to check it can talk to HA, then my new code makes a call to the HA supervisor to get the slug id, then goes back to making HA calls which work ok.
But by making the call to the HA supervisor somehow we closed the initial connection to HA core and that’s why websocket fails

I have one more debug version to try https://drive.google.com/file/d/1dE8mXJf_aYsE_6rCPRJUHsdnNSHSYraJ
if you can please

This adds more logging to the API calls (and suppresses a bit from last time that I can see worked OK).

If you can send me the log from this one loading and I would expect crashing again.

I then have a second version with the same logging but commented out the call to the supervisor to see if this then works which would prove or disprove my hypothesis https://drive.google.com/file/d/1C_HyzoX9vOWs4UKnxh4jvNLv2QeaAxb8

Thanks for your help in debugging this

W
#929 Wavy Davy

[unknown] Just uploaded the list log file Geoff, same link.

W
#931 Wavy Davy

Not list Geoff, 1st of the 2

W
#932 Wavy Davy

geoffreycoan And file number 2 again same link.

R
#933 Rbor

The cold weather is forecast to get brushed away this week with ‘Spring like conditions' following.
So this morning, I am greeted with driving snow blown in by a strong easterly wind.
Currently –0.5C.
My February 2025 is odds on to supply less solar generation than January 2025 and less than half that of February 2024.

I hope that you have fared better than me.

Rob

G
#934 geoffreycoan

[unknown] Looks like the weather has turned for me, today’s solar is forecast to be 13kWh and tomorrow 23, the panels are filling the batteries up with 2kWh of generation at the moment.
Slight cloud on the good news is that the Agile export rates are 10/11p for most of today. Predbat compare still giving Cosy+Agile and Cosy+Fixed at the same daily cost as predicted consumption is > predicted generation in each slot.

Similar story to you about the total solar generation, February running total is about half what I achieved in January 2025 whereas in both 2024 and 2023 the February generation was about 150% of January. So unless its mega-sunny I expect I’ll be down as well.

The long term Agile forecast doesn’t look to be changed though, still giving flat rates for the next week. Today’s Agile prices were as low as 21.6p overnight but only in a couple of slots so hardly worth charging the battery

T
#935 TX200

Flux is still winning for me.

Agile + fixed and IOF pretty much the same as each other.

Although who knows with IOF. There's the 20% it doesn't go into and the risk that it might not charge and discharge as much (or when) expected.

T
#936 TX200

What's occuring?

D
#937 Daveb01

TX200

I was just going to say the same thing, looks a bit iffy to me.


H
#938 Henry3rd

This is a bit like Arctic penguins looking into the sea to see if there are any killer whales lurking within.
Eventually, they tire of waiting and nudge one of their own into the abyss to see if they survive,

R
#939 Rbor

Yesterday, I updated Predbat to v8.1.51
And I have just (bravely with no changelog) updated from add-on v1.2.0 to 1.2.4, with no idea what it does!

Is there any significance in the warning below which I saw on updating from v8.15.0 to v8.15.1 and from v1.2.2 to v1.2.4?

2025-02-16 16:06:55.739758: Warn: Failed to decode response <Response [404]> from http://192.168.68.74:8123/addons/self/info

Is this tied up in the mystery world of the slug?

Rob

D
#940 Daveb01

[unknown]

Well if you did it then that mean I have to as well. 🤞

Phew all go so far

D
#941 Daveb01

Rbor

Well if you did it then that means I have to as well. 🤞

Phew all go so far

G
#942 geoffreycoan

[unknown] What's occuring?

This is Trefor updating the Predbat add-on, i.e. the runtime environment not the application.
But in updating the addon you'll also update to the latest Predbat code as the code is bundled within the add-on.

What's changed, I don't know. For reasons unknown to me Trefor never seems to manage to create release notes for the addon. Maybe we should tell him ?

[unknown] Is there any significance in the warning below which I saw on updating from v8.15.0 to v8.15.1 and from v1.2.2 to v1.2.4?

2025-02-16 16:06:55.739758: Warn: Failed to decode response <Response [404]> from http://192.168.68.74:8123/addons/self/info

Is this tied up in the mystery world of the slug?

Yes, this is the slug id that should be populated but isn't. My guess is that you have set ha_url in apps.yaml, and this is why the slug id isn't populated.

I need to look at the last logfile @[deleted] produced to see if my hypothesis as to how to fix his crashing is correct.

R
#943 Rbor

[unknown] Yes, this is the slug id that should be populated but isn't. My guess is that you have set ha_url in apps.yaml, and this is why the slug id isn't populated.

You will probably remember the discussion that we had about this!
In apps.yaml, I replaced homeassistant.local for the ha_url line as below:
ha_url: 'http://192.168.68.74:8123'

As a test, I will try homeassistant.local again, restart predbat, and see if the warning goes away.
Have to do some work now so back in a couple of hours!

Rob

G
#944 geoffreycoan

[unknown] As a test, I will try homeassistant.local again, restart predbat, and see if the warning goes away.
Have to do some work now so back in a couple of hours!

No, you will still get the warning message no matter what ha_url is set, its the nature of setting it that causes this failure to lookup the slug id.
I think I explained why before, but when you set the ha_URL to point to HA (as you need for all predbat API calls to HA), this then stops the API call to the supervisor from working because the supervisor is on another (different) URL, and at the moment the code doesn’t recognise this, tries to interrogate the supervisor on the same URL as HA, and fails.

I have made changes to resolve this, which work perfectly in my HA but fail in @[deleted] ’s setup and am trying to find out why this is.

R
#945 Rbor

[unknown] Thanks.
I will leave my apps.yaml alone.

Rob

G
#946 geoffreycoan

Rbor told you before Rob to not fiddle, glad to hear you’re listening 🤣

W
#947 Wavy Davy

He's like me, he cant help it...😁

R
#948 Rbor

geoffreycoan
Yes boss!

But you get a numpty question now:
What does FR: stand for? 🤔
Rob

G
#949 geoffreycoan

[unknown] Feature Request

T
#950 TX200

So yesterday and today PredBat says IOF is better than Flux. Agile still worst.

But tomorrow the sun disappears again. 🤣

R
#951 Rbor

TX200 I have checked compare.md on Github and I can see that IOF has sneaked onto the list below snug.

I have added IOF to my list of compare tariffs in apps.yaml (beneath flux) and will await tomorrow to see how it compares with the other tariffs.

Yes, today looks like spring has arrived (for a day and the sun is very hazy so may not last).
I just want the temperature to increase.
I am getting 2.5 kW power on my panels at 09:27 am but the temperature is still down to –2C.
Below my heat pump, water on the ground from a defrost cycle has frozen.

Rob

G
#952 geoffreycoan

[unknown] I’m not bothering with adding IOF to the list as I know I can’t get it (Octopus can’t cope with having two inverters on the same GivEnergy account).

Sunny today as you say, 28kWh forecast and my panels are streaming 3.5kW at the moment. Almost keeping up with the heat pump which is on and off at 4.8kW power.

Here’s a new graph I haven’t shown before, heat pump power vs flow temperature. I still don’t have any integration of my heat pump to HA (only the Shelly EM energy monitor) so I’ve installed a half-way proxy of an ESP8266 connected to two DS18B20 temperature probes, one on a long 5m cable I had to run through the loft, ceiling and down into the airing tank to measure the hot water temperature, and one that’s on the buffer tank in the loft.

Its interesting information, am hoping it can lead me to be able to calculate COP based on flow rate (that I’ll have to get off the pump specifications) and temperature change over time.

With all the sun forecast today Predbat decided last night it only wanted to charge the batteries the minimum to see me through the night so I wouldn’t be exporting much today. I’ve also got a 2 hour power up event from 2-4pm so it was planning force exports this morning as well whilst the agile export rates were 15p.
This is where a temperature forecast input to Predbat would be invaluable. I knew the heat pump would be running overnight and most of the day so I needed to charge the batteries more and not export. Had to put lots of manual force_charge and force_demand slots in to get the plan I wanted

R
#953 Rbor

geoffreycoan I’ll have a go at similar graphs of my setup for comparison.

I agree with you about temperature as this is the key factor in ASHP load (in fact any electrical energy load).
Is this a candidate for a FR to Trefor?

Rob

D
#954 Dpe

I am trying to use use car_charging_energy to remove other house load. The instructions indicate
'You can also use car_charging_energy to remove other house load kWh from the data Predbat uses for the forecast, e.g. if you want to remove Mixergy hot water tank heating data from the forecast such as if you sometimes heat on gas, and sometimes electric depending upon import rates.'
I have a sensor that I use currently to remove car charging energy, and the instructions indicate that the next sensor to remove in my case energy used for the immersion should be added on the line below. Can anyone tell me what the format should be as I am unable to get it working.
At the moment I have
car_charging_energy: 're:sensor.car_charge_kwh'

which appears to work for carcharging

Thanks for any assistance

G
#955 geoffreycoan

Dpe try:

car_charging_energy:
  - sensor.car_charge_kwh
  - sensor.mixergy_heating_kwh
etc

i.e. its a YAML list, each entry indented by 2 spaces and a dash

#956 PianSom

I have come across something I can't explain to myself on this afternoon's Predbat plan. Looking for ideas.

I have a twin AIO system, so 2x6kW inverters with a battery stated capacity of 13.5kWh x 2. My batteries are currently at 100% and the plan is to keep them topped up until 5pm, when today's Saving Session starts. Predbat is then planning on doing a dump to grid (in excess of load).

What is confusing me is why Predbat is saying the SoC at 6pm will be 42%. I do not have enough throughput capacity to drop that much - batteries should be able to shed 12kWh or around 45%, leaving > 50% available - surely?

Now I do have input_number.predbat_battery_rate_max_scaling_discharge set to 1.055, but even after taking that into account there is still a big gap. Can confirm that apps.yaml has discharge_rate as 12000.

Anyone got any ideas?

D
#957 Daveb01

[unknown]

Hi yah, all I can say is, I had the same issue, when I initially set mine to 12000, with losses at the high rate one battery should be flat and one full, or both at 50% as you say. I changed mine to discharge at 6000 and charge at 10000 and they seem to be ok with that.

For this one occasion I would let it do it’s thing, then have a look at the power graph to check it was exporting at 12000.

#958 PianSom

Daveb01
It did its thing yesterday, so I am not worried about behaviour.

It's more the mathematical impossibility that bothers me.

EDIT - actually in yesterday's Saving Session the SoC went from 87% to 44% = 43% discharge = 11.6kWh - just right!

D
#959 Daveb01

PianSom

One more thing to consider, Battery scaling. JasonF, has the below setting. I have 0.85.

P.s another thing I have noticed, my first AIO, discharges much quicker than the new one, even though the GW tries to keep them equal. So math sometimes does not work.

#960 PianSom

Daveb01
Ah, that may be it

I too have 0.85 (since in the single AIO the reported size was 15.9kWh, and we needed to reduce it to 13.5kWh - the nominal size). But now I see sensor.givtcp_gw_gwXXXXXXXX_battery_capacity_kwh = 27.0, so I wonder whether this needs to be put back to 1.0?

Where does 1.0059 come from?

G
#961 geoffreycoan

PianSom I thought Daveb01 and I had concluded that battery scaling needed to be set to 0.85 for multiple AIO’s. That’s what’s in the documentation and I’m sure we agreed it was still needed for predbat to work correctly

D
#962 Daveb01

PianSom

That number came from JasonF, I think he did math or got it from GE, I will have to go back to the post and have a look.

Here is what I have done to get the correct Battery sizes etc. in the battery card you can alter the DoD, so messed about with that and got to 82%.


#963 PianSom

Daveb01 P.s another thing I have noticed, my first AIO, discharges much quicker than the new one, even though the GW tries to keep them equal. So math sometimes does not work.

I don't think that matters. The SoC reported by the Gateway (and used by Predbat) is the average of both. The maths works whichever battery is supplying the power.

D
#964 Daveb01

geoffreycoan

We did & mine has been on 0.85, but I know Jason has his 1.0095. I have tried to find the post but can not find it.

@PianSom you have had it at the documented 0.85 as well, please try 1.0095 for a few days and see if you get different results, then we can update the doc’s if needed with an explanation. E.g use 0.85, if your getting issues with xxx try 1.0095?

#965 PianSom

JasonF
Interesting. Yes, it certainly makes sense to use that number, rather than 0.85. (NB @geoffreycoan )

I also see 13.58x2, so I will move to 1.0059.

This will increase my effective battery size from 27 x 0.85 =22.95 (so 45% is 10.3kWh, which would explain why my original Predbat issue) to 27 x 1.0059 = 27.16 (so 45% is 12.2kWh - which is closer to what I expected, and what I observed as being discharged yesterday and today during a 1hr saving session, and is pretty much equal to 12kW inverter output + a bit of discharge scaling).

Thanks @Daveb01

D
#966 Daveb01

[unknown]

So my suggestion would be not to change any other settings, for a few days to see what results you get.
Then please report back. 🤞👍

D
#967 Daveb01

PianSom

So my suggestion would be not to change any other settings, for a few days to see what results you get.
Then please report back. 🤞👍

R
#968 Rbor

geoffreycoan I will need to put together some graphs.
Are yours based on apex charts or similar?

Anyway, this shows my external temperature over the last week up here in sub-arctic Yorkshire.

From the forecast, no more frosts for a while and should give my heat pump a rest from all the defrosting. I have a layer of thick ice at the bottom of the back of my heat pump which can't be helping its efficiency.

Rob

G
#969 geoffreycoan

Rbor the top one was an Apex chart, pulling from long term statistics to give ASHP consumption (max ashp_energy_today) and average outside temperature per day.

The bottom one was just a standard HA history graph of flow temperature vs power. I can share the YAML. I like Apex charts but they are difficult to create and configure in my experience. I've shied away from using Grafana and a separate reporting db as being more complexity and pretty much all the time I get what I want from within HA.

Similar temperature in Bedfordshire but a bit milder:

I've cranked the heat pumps right up for this 2 hour power up event we've got, in order to put some heat into the house. Can see the dramatic increase in power consumption, but also interesting how long it took to raise the flow temperatures, nearly an hour from 35 to 60:

R
#970 Rbor

geoffreycoan Yaml code would be great.

My flow temperatures and power do not look pretty with many defrosts with their associated spikes in consumption.
I will see what I can create.

From my external temperatures, since 13th Feb, I have only been above 2C once and I have had had some time below 0C on every day. This is life 800' up on the edge of the Peak District. The rule of thumb is for a 1C decrease in temperature for every 300'.
If you subtract 3C from all your temperatures, you are not far off my temperature profile (and vice versa).

I am looking forwards to a drop in ASHP energy consumption over the next few days as temperatures rise. I know we moan about this, and I always have to remind myself that I don't have a gas bill, nor gas SC. Recently, I have input about 35 kWh each day with about 25 kWh feeding the heat pump.

Hasn't Cosy worked well? It is far easier to manage energy appliances without searching for the low Agile rates. But I do miss the 'excitement' (and recent disappointment) of seeing the Agile daily rates for the first time.

Rob

L
#972 Lincs_Will

Hi all, is there a way of getting past Predbat plans out of a log file? I'm on IOG and over the weekend I plugged our PHEV in during the day and it charged during the afternoon but our usage in that period has been charged at standard rate, not the IOG off-peak rate. Octopus' reply has been highly sub -optimal so I'd like to show them what their own API spat out because there's either a disconnect between what's planned and what's billed, or the (Zappi) charger under their control will charge the car when it's not supposed to.

T
#973 TX200

[unknown] logbook part of HA?

G
#974 geoffreycoan

Rbor I pop my head into twitter from time to time, one of the things I get notified on is 'agile price predictor'. It predicted that the rates would be sub 12p for tonight, but they're not as good as that, 13.6p cheapest in my area and that's only for a couple of slots.

I keep an eye on the long term agile price forecast in HA still. Earlier in the week it was predicting cheap rates on Sunday, then it wasn't, and now it is again, on Sunday morning.
Looking at the data though I now see that the Agile price forecast is in 30 minute segments with the timing of each one mid-way in the 30 minute slot. Its predicting 17.3p at 9:45, 6.7p at 10:15, 4p at 10:45, 0.8p at 11:15, 3.2p at 11:45 and back to 27p at 12:45 - so maybe a couple of super-cheap slots in the morning but the rest of it is no material difference from what we've had before for the last month.

Trefor compare still pegging Agile at about £3 a day more expensive than Cosy

Hasn't Cosy worked well? It is far easier to manage energy appliances without searching for the low Agile rates. But I do miss the 'excitement' (and recent disappointment) of seeing the Agile daily rates for the first time.

Yes absolutely, much easier to deal with in terms of planning appliances, loving the 3 bites at the cheap cherry. I wasn't convinced it would work for me with my high import consumption but its working out better than I hoped it would.
As well as fitting the thermal probes to my heat pump buffer tank and hot water tank I've spent quite a bit of time lagging all the heat pump pipes in the loft where they come in from outside, into the buffer tank and then down to the rest of the house. Had previously put pipe insulation over the pipes but now I've got a thermal camera I can see how hot all the joints and connectors are so wrapping in foil backed bubble wrap.
That and fixing two leaks in the pipework. Still work in progress.

Rbor From my external temperatures, since 13th Feb, I have only been above 2C once and I have had had some time below 0C on every day. This is life 800' up on the edge of the Peak District. The rule of thumb is for a 1C decrease in temperature for every 300'.
If you subtract 3C from all your temperatures, you are not far off my temperature profile (and vice versa).

The lapse rate (in the troposphere) is actually 1.98 degrees C for every 1000' according to the ISA (International Standard Atmosphere), or 2 degrees to keep the maths simple.
But in reality this can vary between 1 and 3 degrees a 1000 feet.

[Lapse rate, relative humidity and dew point are important to a pilot to predict cloudbase]

#975 PianSom

I was just looking at the excellent Compare page and thinking of other info that might be interesting to see.

One thought was - it would be useful to see how midnight predicted load and PV generation compared to actual load/PV for each day historically. This would help with Predbat tuning, but also allow for an eyeball check on whether a marginal tariff decision might be changed by actual performance.

Anyone got other suggestions? I'm happy to put in a combined feature request (or indeed donate this idea to someone else if they want to do it).

T
#976 TX200

I was thinking I'd be more likely to switch to IOF soon rather than go backwards to agile. Will see I guess. 🤣

As for PredBat compare, I wonder if it could be designed to plan IOF like octopus would, e.g. discharge to exactly 20% most evenings. Charge up to 80% for bigger batteries (or 100% for smaller ones). And treat the grid like a giant lossless battery.

G
#977 geoffreycoan

TX200 trouble with trying to predict/compare IOF is it all depends on what Octopus plans, and I’ve seen mention that the behaviour has varied quite a bit

PianSom I like the idea of being able to compare prediction to actuals more easily, the data is in there in predbat but its not really very accessible. I was thinking something similar the other day, how to look back at yesterday’s PV generation figure and whether that would be useful on a dashboard, probably occasionally but not mainstream.
You could do something with Apex charts to select pv_forecast, load forecast, max(pv_actual), max(cost actual) from statistics, but getting the midnight values isn’t easy and would probably need extra time trigger templates to store pv_forecast, cost_forecast, load_forecast in respective yesterday_xxx sensors at 23:55. All a bit of a faff.

So r/e your idea, I’d like this kind of data to be more accessible (as its a pain to extract from HA/predbat at the moment) but personally I’d like to have them in HA sensors so I could graph/trend myself. Wouldn’t want it locked in a predbat web console as being the only means of access

#978 PianSom

geoffreycoan You could do something with Apex charts to select pv_forecast, load forecast, max(pv_actual), max(cost actual) from statistics

Not sure what you mean by max(cost actual) [or min(cost actual)?] - cost is what it was for any given day on the tariff you are on. Unless you were thinking of dramatically expanding the Compare functionality to retrospectively work out what you would have paid under every plan given the load+pv that actually happened? Which sounds ... complicated. max(pv_actual) - you mean over a period of time, right? - is pretty easily available already, of course.

But, yes, putting the pv_predicted_midnight and load_predicted_midnight values into sensors would be very sensible.

G
#979 geoffreycoan

PianSom Not sure what you mean by max(cost actual) [or min(cost actual)?] - cost is what it was for any given day on the tariff you are on.

I was just outlining how you get get the midnight figures in Apex charts, summarising historical data with a time period of 1 day without going to the trouble of creating additional midnight sensors.
Using max(data entity) would work for an incrementing sensor like pv, load, import and export but not for something dynamic like cost as it goes up and down during the day.

HA doesn’t make it easy to extract history at all, e.g. cost_sensor[‘2025-02-19 00:00’], you can get it from an array of a forward projection, but there’s no way in Jinja to get access to history; would have to start writing Python or create extra helper entities to capture the datapoints.

R
#980 Rbor

[unknown] The lapse rate (in the troposphere) is actually 1.98 degrees C for every 1000' according to the ISA

Thanks for this. Suffice to say, the altitude of my house reduces the ambient temperature compared with sea level.

What a difference a day makes!

Wed 19th Feb at 10 am:

  • External temperature –0.5C
  • ASHP power 1120 W,
  • Energy from midnight: 10.5 kWh

Thu 20th Feb at 10 am:

  • External temperature 10.5C
  • ASHP power 612 W,
  • Energy from midnight: 4.20 kWh

Watch those costs fly down ......
Pity about the PV today though!

Rob

R
#981 Rbor

geoffreycoan > The lapse rate (in the troposphere) is actually 1.98 degrees C for every 1000' according to the ISA

Thanks for this. Suffice to say, the altitude of my house reduces the ambient temperature compared with sea level.

What a difference a day makes!

Wed 19th Feb at 10 am:

  • External temperature –0.5C
  • ASHP power 1120 W,
  • Energy from midnight: 10.5 kWh

Thu 20th Feb at 10 am:

  • External temperature 10.5C
  • ASHP power 612 W,
  • Energy from midnight: 4.20 kWh

Watch those costs fly down ......
Pity about the PV today though!

Rob

G
#982 geoffreycoan

Rbor What a difference a day makes!

I was thinking the same. Today similar outside temperature to you, 10 degrees, yesterday was 3 degrees at 10am but was below freezing at 7am.

The house felt noticeably warmer this morning, heat pump had only used a couple of kW heating the water and the house in the 4-7am Cosy period, and then through this morning the batteries filled up on solar. First time that’s happened for a while, not that there’s much solar today; 6.1kW forecast and 2.0 already generated but now its started raining so that’s the end of that.

D
#983 Daveb01

Hi all, can I clear up the (inverter limit & export limit) please.

The current documentation says add all the inverters together and put that in yaml.
As I have 1 x SolarEdge and 2 x AIO all at 6000w, I should put 18000w (I have had 12000 until now). And thought I would try 18000w to see if there is any difference.

The issue is really the docs say add inverters together e.g battery + PV, AIO + PV =12000
When you get a second AIO the system moves to the GW which is not an Inverter, but would be 18000w. Should I stick with 18000w & can the GW support 18000w?

I am happy with GW discharge 6000w as I have never needed more into the home. This also means the export to the grid is limited to 6000w as well. Should I now change this to 12000w and uncomment “export limit”?

G
#984 geoffreycoan

Daveb01 inverter_limit and export_limit are only used for modelling your inverter throughput and DNO imposed limits - which for most people you won’t hit.

If you have your gateway set to 6000W then set inverter_limit to gateway limit (6000)+solaredge limit (6000) as this is the most you can discharge and get from your solar inverter.

Don’t set export_limit unless you have that imposed by the DNO and configured in your AIO. Predbat will model the effect of that happening, but not control it (that’s the inverters job).

#985 PianSom

@geoffreycoan
Just to confirm my reading - the manual says that inverter_limit_charge/discharge WILL override the standard inverter settings - is that correct?

Because I tried it last night and it didn't ...

G
#986 Goshiki2

Just a quick question. What’s the best or most efficient way of automatically dumping the remaining battery before the start of the next cheap rate period? I changed to Go a couple of weeks ago and I saw a similar question asked on facebook to which Trefor replied to say “ make sure metric battery cycle is set to zero”. This has always been set to zero on my system so I set about adjusting either ‘metric min improvement export’ or ‘metric self sufficiency’ and I can roughly achieve what I want but see similar results using either method.
Oh how I wish for a “dump excess battery before planned charge” function 😂

G
#987 geoffreycoan

PianSom Just to confirm my reading - the manual says that inverter_limit_charge/discharge WILL override the standard inverter settings - is that correct?

Because I tried it last night and it didn't ...

Correct it should do this. Its what @Daveb01 uses. Do you have a power % limit set in the portal because this can mess with things? (I need to add this to the docs)

Goshiki2 What’s the best or most efficient way of automatically dumping the remaining battery before the start of the next cheap rate period?

Predbat should do this automatically for you if it sees that its profitable to do so.

Depends on the high/low charge rates, but in essence Predbat might not decide that its profitable if:

  • battery/inverter losses are too high
  • metric battery cycle (cost of using the battery) is too high
  • metric self sufficiency (focus on keeping stored power not using the battery) too high
  • metric min improvement export (how much extra income in the 30 min period you want to make from exporting & re-importing vs retaining) too high
  • best soc keep / best soc keep weighting to high so predbat keeps charge in the battery
  • ditto best soc min
  • metric battery value scaling (would need to check this one)
  • carbon enable turned on and its higher carbon to import

With Predbat there are several different things that could contribute to not discharging the battery. Generally if you keep things on the default values it should do what you want. I would suggest looking at the losses and battery cycle cost as the first priorities for tuning

G
#988 Goshiki2

[unknown] Thanks Geoffrey. I’m pretty much back to default now on everything apart from:

  • Metric self sufficiency @ 2.0p
  • Combine charge slots - True
  • Combine discharge slots - True
    It seems to be working ok at the moment but it seems that there are multiple ways of achieving the same goal and I wondered which was preferred/ best practice.
#989 PianSom

geoffreycoan Correct it should do this. Its what @Daveb01 uses. Do you have a power % limit set in the portal because this can mess with things?

Are you sure it is what he uses? Compare the screenshot he posted just above (with 9900/6000 limits) to the power chart he posted two days ago in https://community.givenergy.cloud/d/4706-aio-secondthird-battery-install/197 . They don't seem to agree.

EDIT - actually, maybe they do. Just being picky

I don't (I believe!!) have a power% limit set. Though it is entirely possible I set one yesterday by accident when I was changing settings. On reflection, I think that must have been the case ...

D
#990 Daveb01

@PianSom #p76887

If you would like me to screen shot my yaml, Predbat settings etc, GW inverter and GE cloud settings, so you can compare and have a place to start, I am ok with that. I found it very difficult not to fiddle with all the settings, however when it went wrong I had no idea which setting to change.

So with help from the guys on these posts and Geoffrey’s documents I managed to get to a default position, then I clicked expert mode and documented this (separate post) Now I only change one setting at a time leave it for a few days to see what it does. Then ask Geoffrey or Rob their opinion and make a decision. I must admit I have been told off a few times with “this is the second or third time we have said this”. Or RTFQ.

Btw Paul has just updated my AIO’s with new FW and BMS, so defiantly not changing any settings in the near future.

J
#991 JasonF

Hey, I think this has been asked before but I can’t remember the answer:

I have dual AIO, and I’m on IOG, I charge my batteries at night, use it during the day (I have a tiny solar array which I just use) and then I want predbat to plan to dump the rest of the battery before the next cheap slot at 11:30.

But for some reason it likes to plan this:

A random discharge at 7:30am

Discharging early evening rather than later in the evening

I tried a solution with overriding the rates at certain times to influence it, but then I lose some of the dynamic stuff I want - like utilising savings sessions, and extra cheap slots when I plug my car in.

Is there anything to tweak to influence this?

Thanks!

G
#992 geoffreycoan

Dashboard Yaml for the two charts @Rbor

  - title: ASHP Consumption
    path: ashp-consumption
    type: custom:grid-layout
    cards:
      - type: custom:apexcharts-card
        apex_config:
          chart:
            height: 350px
        span:
          offset: '-1day'
        graph_span: 30d
        series:
          - entity: sensor.ashp_energy_today
            name: ASHP
            type: column
            offset: +1d
            statistics:
              period: day
              type: state
              align: end
            show:
              datalabels: true
              offset_in_name: false
          - entity: sensor.porch_temperature
            type: line
            stroke_width: 2
            offset: +1d
            group_by:
              duration: 1d
            statistics:
              period: day
              type: mean
              align: end
            show:
              datalabels: true
              offset_in_name: false
      - type: custom:apexcharts-card
        apex_config:
          chart:
            height: 350px
        header:
          show_states: true
          show: true
        graph_span: 4h
        yaxis:
          - id: power
            decimals: 0
            min: 0
            max: 10
            apex_config:
              tickAmount: 10
              title:
                text: Power (kW)
                rotate: -90
          - id: temperature
            opposite: true
            decimals: 0
            apex_config:
              title:
                text: Temperature
                rotate: 90
                style:
                  color: blue
              labels:
                style:
                  colors: blue
        stacked: false
        series:
          - entity: sensor.ashp_power
            yaxis_id: power
            color: black
            stroke_width: 2
            show:
              in_header: false
              legend_value: false
          - entity: sensor.ashp_flow_temperature
            yaxis_id: temperature
            color: blue
            stroke_width: 2
            show:
              in_header: false
              legend_value: false
              offset_in_name: false
          - entity: sensor.porch_temperature
            show:
              in_chart: false
          - entity: sensor.hall_temperature
            show:
              in_chart: false
G
#993 geoffreycoan

JasonF Is there anything to tweak to influence this?

Is this switch on?

switch.calculate_export_high_import (expert_mode) When True export slots of the same value are sorted by import price (to avoid the low import slots for export). When False they are sorted just by price and then time. The default is True.

By default with this option disabled the latest export slot of the same value will be picked, this is useful for fixed-price export tariffs where you want to export as late in the day as you can.

J
#994 JasonF

geoffreycoan turning that off did this madness:

G
#995 geoffreycoan

JasonF completely mad

Think you’d better create a debug file and raise a GitHub issue for Trefor to look at it

J
#996 JasonF

[unknown] interestingly, when I disable combine charge slots and combine export slots (I don’t need lots of 30 min alternating charge/ discharge as I’m on IOG and fixed export) it moved the slots to end of day, but with it enabled it pushes them earlier into the evening.

J
#997 JasonF

geoffreycoan interestingly, when I disable combine charge slots and combine export slots (I don’t need lots of 30 min alternating charge/ discharge as I’m on IOG and fixed export) it moved the slots to end of day, but with it enabled it pushes them earlier into the evening.

#998 PianSom

JasonF
I don’t really have anything to add, except I share your pain.

Predbat is 90%+ of the way there on IOG but that last little bit is very frustrating. I have never managed to find a combination of settings which actually work optimally, even after many months of trying.

I have two main frustrations with my current combo

  • its strong desire to do a mid-evening export, totally ignoring the fact that load may exceed projections
  • its irrational desire to rapidly switch between charging and discharging in the 11.30pm to midnight slot

I think the fundamental issue is that Trefor is not an IOG user, so has not focussed on the specific ways his optimisation algorithm interacts with the tariff. But whatever.

Predbat - for all its frustrations - is still way ahead of any alternative and really is 90% of the way there. It is a great tool. Sorry not to be able to offer a collection of settings that gets entirely there; if you ever solve it then let me know!

G
#999 geoffreycoan

PianSom it’s probably worth raising this with Trefor again JasonF especially the combine behaviour. I would have thought having both combine switches on is the optimal plan as you have long blocks of rates.

Agree Predbat can tend not to be conservative about exporting, I’d like it to hold SoC for longer until its sure that its not needed

J
#1000 JasonF

[unknown] I do have an idea for a combination I want to try, I’ll let you know if it’s looking promising.

J
#1001 JasonF

PianSom I do have an idea for a combination I want to try, I’ll let you know if it’s looking promising.

J
#1002 JasonF

I’ve broken something because now it wants to do this:

G
#1003 geoffreycoan

JasonF that is optimising your income, charging at 7p, exporting at 15p and leaving you with enough battery to last the day

if you don’t want to exercise the battery like that, turn off ‘calculate export within charge slots’

J
#1004 JasonF

It’s never planned like this before. It should always plan to empty the battery before the cheap slots start because it’s always better to charge fully at 7p then export at 15.

I think I need a factory reset tbh

J
#1005 JasonF

geoffreycoan

It’s never planned like this before. It should always plan to empty the battery before the cheap slots start because it’s always better to charge fully at 7p then export at 15.

I think I need a factory reset tbh

#1006 PianSom

JasonF
Oh dear, you have caught the irrational 11.30pm virus!

(I assume that somewhere in the code is some logic that says "I must minimise the daily bill" - ignoring the fact that that sort of short charge/discharge can't be good for the battery, and is anyway not optimal in a slightly longer timescale.)

I do "exercise my battery" as Geoffrey puts it. I want to get payback on my investment in the shortest period I can. Is your preference not to?

I will post later with the settings I currently use. Most are Trefor's defaults but some are not. Maybe if you and I can get to a place where our frustrations are aligned/coherent we can have a joint approach to Trefor, as Geoffrey suggests?

J
#1007 JasonF

PianSom

Yeah I’ve played with so much I don’t know if something I’ve set is now impacting, so it would be great to align settings. The combine slots functions are definitely interacting weirdly with where the slots get placed.

I plan to maximise all the money I can from this kit! It’s been hampered by BMS10 and 11 and the SOC drops, so I had to turn predbat off for a while because I couldn’t guarantee what the actual state of charge was!

But in normal circumstances I want to charge the battery fully every day, with a short discharge for an hour ish in the cheap period but be back to 100% by 5:30, use it all day then by 11:30 empty it to 4% and start again.

Previously I had this working, but was setting manual rate overrides to force it to pick slots. But it then caused me problems with saving sessions, and additional cheap car slots so I’ve turned all that off again.

Yesterday on BMS 12 I managed to get my total electricity spend at just over £1 including the standing charge, that’s without the short extra discharge overnight. I really hope this BMS works out.

J
#1008 JasonF

JasonF I tried to set it to not export during charge slots, then use the override function to force the two hour discharge at night. But it just went mad. 🙁

#1009 PianSom

JasonF
Given the limited audience for this sub-conversation (2xAIO users who flog the battery), I wonder if we are better DMing over on the other forum?

@geoffreycoan - did you sign up over there? You may want to be party to this too. Or you may not!

J
#1010 JasonF

PianSom I didn’t sign up, I was super confused by there being two forums lol. Link me again and I’ll sign up. Or can use discord or something?

#1012 PianSom

JasonF
BTW I use Discord for my Predbat notifications. Bit of a pain setting it up, but it works well

G
#1013 geoffreycoan

PianSom geoffreycoan - did you sign up over there? You may want to be party to this too. Or you may not!

I am on the new forum, and as ever interested in how we get predbat to work, and give advice to others as to how to use it.

I’m just geoffrey over there

G
#1014 geoffreycoan

geoffreycoan try:

car_charging_energy:

  • sensor.car_charge_kwh
  • sensor.mixergy_heating_kwh
    etc

i.e. its a YAML list, each entry indented by 2 spaces and a dash

Dpe did this work?

G
#1015 geoffreycoan

Wavy Davy

Sorry its taken a bit, I have looked at the logfile but I only had 1 link so only 1 logfile ?

Looking at that logfile it looked like it was coming from the stock ha.py that’s shipped with predbat, there wasn’t any debug info in the log.

geoffreycoan I have a guess that the failure is caused by predbat initially making an initial call to HA core to check it can talk to HA, then my new code makes a call to the HA supervisor to get the slug id, then goes back to making HA calls which work ok.
But by making the call to the HA supervisor somehow we closed the initial connection to HA core and that’s why websocket fails

I have one more debug version to try https://drive.google.com/file/d/1dE8mXJf_aYsE_6rCPRJUHsdnNSHSYraJ
if you can please

This adds more logging to the API calls (and suppresses a bit from last time that I can see worked OK).

If you can send me the log from this one loading and I would expect crashing again.

I then have a second version with the same logging but commented out the call to the supervisor to see if this then works which would prove or disprove my hypothesis https://drive.google.com/file/d/1C_HyzoX9vOWs4UKnxh4jvNLv2QeaAxb8

If you can try installing ha.py from the first google drive link and share the logfile which has extra debugging, I think it will continue to crash after its got the slug id

And then the second google drive link is to ha2.py so will need to be renamed to ha.py, I think this will not crash but won’t get the slug id

#1016 PianSom

geoffreycoan
Sorry - we decamped to Discord. Will circle back

R
#1017 Rbor

[unknown] I spent time this afternoon transferring my HA installation from my old pi4 to my pi5 with NVMe.
I have been trying to catch up on posts and am glad that you haven't all disappeared to the dark side in the meantime.

This evening, I have browsed around on the dark side. I find it harder to find things but perhaps that is familiarity with this forum.
To tell the truth, I prefer it here! We have even attracted some interest from GE staff which is always a good thing.

Early days with double forum browsing but I feel more at home here.

Rob

B
#1018 Boffinboy

Hi everyone, I updated Predbat add on, and various other things. I love it, but am getting fed up that it seems like every time I update I get a bunch of errors and am unable to get it running again… usually I think it’s a REST failure (maybe a network issue) but I have no idea why. It leads to an error of ValueError: time data 'unkn own' does not match format '%H:%M:%S' This happens EVERY time I do an update, and I just can’t seem to figure out how

I am never clear how to get it to work again, but sometimes it just springs back to life…. Does anyone have any suggestions? Could I switch to non-REST communication using the GE API? I saw some changelog notes about that being added. Any advice welcome, as I have to spend ages fiddling and trying to figure out how to get things working each time HA updates, and I can never find a pattern of what I do to fix it!

B
#1019 Boffinboy

Boffinboy it clearly is some kind of networking error on my UniFi network because the BBC inverter control app also can’t connect, but I just have no idea how to fix! Looking in GivTCP logs I see that either the connection times out, or is refused.

And infuriatingly now I’m trying to use GE cloud I get this error: Error downloading GE data from URL https://api.givenergy.cloud/v1/inverter/SERIALNO/data-points/2025-01-31?pageSize=4096

Edit 3…. Seems my API key was revoked, so created a new one… and getting lots of GECloud: Failed to read inverter setting id warnings… Tearing my hair out here! No idea what to do

D
#1020 Dpe

geoffreycoan In the end I did this

car_charging_energy: re:sensor.car_charge_kwh
-re:sensor.immersion_power_sensor

which appears OK

When I tried as a straight list (as above) I got an error on start-up, but this may have been an error on my part

G
#1021 geoffreycoan

Boffinboy I am never clear how to get it to work again, but sometimes it just springs back to life…. Does anyone have any suggestions? Could I switch to non-REST communication using the GE API? I saw some changelog notes about that being added. Any advice welcome, as I have to spend ages fiddling and trying to figure out how to get things working each time HA updates, and I can never find a pattern of what I do to fix it!

In case you weren’t aware, just worth diving briefly into the architecture.

Assuming you are using HAOS, Home Assistant runs as a series of docker containers running on the host, controlled by the supervisor. Home Assistant itself runs as one of those containers, referred to as ‘core’, as do any other add-on’s you have installed (predbat, givtcp, mqtt, Google drive backup, file editor, etc) - they are all individual docker containers. [that’s why under system/logs you can look at all these different log files from each container]

Predbat relies on being able to talk to the HA core container via HA REST API’s, and the GivTCP container either via REST and/or the HA GivTCP control entities. Alternatively Predbat can talk to your inverter via the GivEnergy cloud - this has been an option for a while as a separate integration but is now natively included.

If you upgrade HAOS (currently version 14.2) upgrade the underlying host and as a result everything has to shutdown and be restarted.

If you upgrade HA itself (latest version 2025.2.5) then just the HA core container is updated and restarted.
As Predbat relies on a connection to HA (and a security token), just upgrading HA core can break this connection and you get random errors.

Similarly if you upgrade the Predbat addon (currently 1.2.4) then this also can break the connection to HA.

In either case the fix is to either restart Predbat addon, or do a full shutdown and restart of HA and all the addons - developer tools / restart / advanced options / reboot system

This should come back clean although I have noticed that GivTCP v3 takes longer to start up than v2, Predbat complains about this and often restarts GivTCP itself (if you have the auto-restart configured in apps.yaml).
It usually sorts itself out.

The other problem that seems to be more prevalent is the security token being used by the websocket connection from Predbat to HA can disconnect when its been running for a while. Been a few people reporting this problem on GitHub. Restarting Predbat cures this problem as a new token is created, but a better fix is to create a permanent HA token for Predbat to use https://github.com/gcoan/batpred/blob/main/docs/apps-yaml.md#home-assistant-connection

You can use the GE cloud integration with predbat as an alternative to GivTCP. The data is less granular and it relies on your internet connection, and an API key (I create a permanent one for this).
I’ve used it for a few weeks when I accidentally purged my import history in HA and it worked fine.

W
#1022 Wavy Davy

geoffreycoan Will try that today Geoff, but have a few things to sort out first.

W
#1023 Wavy Davy

geoffreycoan Geoff, Just so I'm clear, which log file do you want, from the file editor, predbat.log or predbat GUI log?

G
#1024 geoffreycoan

Wavy Davy the predbat addon log only contains warnings and errors from the /addon_configs/6a**predbat/predbat.log - its this one I’d like please

however is easy for you to extract it

B
#1025 Boffinboy

[unknown] thank you, this is really helpful! It seems to all be working again now. I still believe there’s some kind of bug with my UniFi networking care that doesn’t pray nice with the inverter.

#1026 PianSom

Boffinboy I still believe there’s some kind of bug with my UniFi networking care that doesn’t pray nice with the inverter.

I recently had a new AIO installed. I had issues getting the wired connection working from my Unifi network to it, until the point where I saw that the installer had left the wifi open and unsecured on it. I locked it down, and then disabled STP network loop checking on the switch port used by the new AIO. All fine since.

Might you be having similar issues?

R
#1027 Rbor

geoffreycoan Thanks for this explanation of the structure of all things HA.
Your explanation 👑 is so much clearer than that offered by Home Assistant documentation.

Rob

W
#1029 Wavy Davy

Just one thing Geoff, have some probate entities that won't now load with V2

G
#1030 geoffreycoan

Wavy Davy thanks for trying, unfortunately the logs didn’t help me diagnose the issue you were getting

So I have pressed ahead with making the change I think is needed to the code to fix the problem I saw you having (of initial HA connection worked, then supervisor lookup of slug id worked, then API calls work, but when Predbat does to sleep for 5 minutes it all falls apart).
I have resequenced the code which I believe will resolve the issue. If it doesn’t, I am out of ideas and back to trying to debug it again ☹️

Here is what should hopefully be a final ha.py https://drive.google.com/file/d/1aeIZSRvhSjsAk1aWvkr8MOpw1S4EUKtg/view?usp=drivesdk

There is a bit of logging in this but not as comprehensive as before, so either the logfile with this running or a screenshot of the log tab on predbat addon should show its working.

As for the errors on v2, hard to tell, they look like either predbat crashed or it needs a browser refresh. I’m hoping this one will be ok

thanks

L
#1031 LewisWatt

I'm having an issue with the Agile side of the Compare feature. I've only just clocked on to this, but my agile rates do not match the API values at all. I've switched the region to N (Southern Scotland), but the values are significantly out of wack.

Here's a snipet of my comparison for today vs what the values should be, as well as the relevant YAML.


Honestly stumped atm, any help is appreciated. Cheers

W
#1032 Wavy Davy

geoffreycoan Geoff, have put your final HA.py file in and all entities now showing, but do have these errors.

G
#1033 geoffreycoan

Wavy Davy It looks like the same error as before is occurring, failing to talk to HA. Damn

Are you able to get me the fuller predbat logfile please, you don’t need to convert it to RTF, just the predbat.log is fine, whatever is easier

W
#1034 Wavy Davy

Where exactly do I get that from.
Is it /addon_configs/6adb4f0d_predbat/predbat.log ?

W
#1035 Wavy Davy

Where exactly do I get that from.
Is it /addon_configs/6adb4f0d_predbat/predbat.log ?
and if so how do I get it?
I've been using file editor and select all, copy and paste into a empty txt file

G
#1036 geoffreycoan

LewisWatt I'm having an issue with the Agile side of the Compare feature. I've only just clocked on to this, but my agile rates do not match the API values at all. I've switched the region to N (Southern Scotland), but the values are significantly out of wack.

Here's a snipet of my comparison for today vs what the values should be, as well as the relevant YAML.

that’s very strange. I checked the URL configured in apps.yaml, opened the JSON and checked the rates and they match what’s on your screen, but not what’s in the plan. The YAML all looks correct, maybe just check that you’ve got spaces in front of each line and not tabs in case that is causing a problem, and maybe try copying in the yaml from the original template, but otherwise I have no idea and it’ll need logging with Trefor.

Anything in the logfile when it was doing the comparison last night?

I looked at my own agile predicted plan and compared the rates on octopus compare for me, and they all match, so for me Predbat is getting the right rates.

G
#1037 geoffreycoan

Wavy Davy Where exactly do I get that from.
Is it /addon_configs/6adb4f0d_predbat/predbat.log ?
and if so how do I get it?
I've been using file editor and select all, copy and paste into a empty txt file

yes that’s correct

I have the samba file share running on my HA which makes it easy to copy files to my ipad or PC, but copy paste from a file editor is fine

W
#1038 Wavy Davy

geoffreycoan I also have file share, forgot about that!!
So here's the file predbat.log, same url as before.

S
#1039 SamM

JasonF

Not sure if you found a solution to the battery holding on to charge rather than exporting it before the cheap off-peak rate on IOG.

I was seeing the same issue in the last 2 days (it's been a while since my battery has had enough charge left to export). I toggled switch.predbat_calculate_export_high_import to On and that corrected the plan to export any charge just before 11:30pm

G
#1040 geoffreycoan

Wavy Davy geoffreycoan I also have file share, forgot about that!!
So here's the file predbat.log, same url as before.

Hi Dave

can you check the link please, the one you sent appears to send me to the share for the 2 original logs, giving me the option to copy to my dropbox rather than being a share of your dropbox folder

R
#1041 Rbor

geoffreycoan I have gone way back here to your charts.
I have adapted your two charts – thanks for the YAML code.

I am finding that the key at the bottom is too high up, overlapping with the chart.

I have copied the bottom part is my chart as I keep getting red error messages for larger graphics. Do you know how I can lower the keys? I have looked in Apex charts documentation on Github and can't find anything. Strangely, the keys are aligned correctly below the x axis on an iPad.
The same thing is happening on all my Apex charts but I think it was fine before!

Rob

B
#1044 Boffinboy

PianSom have an AC3 so on the dongle. I will check STP. Seems to be working again fine for now. I know there was a firmware issue with my APs that didn’t play nice with IoT kit, not just the inverter, but I had thought that was all resolved!

R
#1045 Rbor

Boffinboy I have AC1 with dongle.
I have tried to check my STP in settings. I can't find it in the givTCP3 WebUI.
Where is it? And what does STP stand for??

Rob

#1046 PianSom

Rbor
STP = Spanning Tree Protocol
https://en.wikipedia.org/wiki/Spanning_Tree_Protocol

It's a method in network implementation (nothing to do with the dongle or Givenergy in particular) which spots loops in a network topology and shuts them down eg if you had two network switches with two cables between them it would disable one of the cables. Unifi kit (which both Boffinboy and I use) can sometimes be rather aggressive in shutting down potentially offending network ports - as I found recently.

In almost all cases it can be safely ignored!

R
#1047 Rbor

PianSom Ah yes. It rings a bell now.
When I used Sonos gear, I remember that STP could be a problem.
I have Deco mesh and I cannot find STP in any of the settings.
..... So I can safely ignore this one .....

D
#1048 Daveb01

I have just noticed the number of posts, it’s only February and we are over 1000, so in theory we will get to 6000 by December, but this may be scuppered if we start telling jokes 😀👍😛

T
#1049 TX200

Daveb01 half of those posts are double postings due to the forum errors 😂

L
#1050 LewisWatt

geoffreycoan Took the advice of a clean YAML slate and that seems to have fixed it. Can't say I have any idea what went wrong as the log was clean. Regardless, cheers!

G
#1051 Goshiki2

We’ve got a yellow weather warning in place today until 18:00 so I thought it would be a good opportunity to test out Trefor’s new alert system and check the impact on the plan. The battery is currently 81% full so I set the keep in apps.yaml to 75% hoping it would allow the battery to discharge to that level and then maintain it until 18:00 but I was wrong. I got a notification of “Hold Charging 80% - 75%” and the battery immediately started charging from grid at max rate with the yellow warning notification on the new plan lasting until midnight. I can’t understand why it would need to charge to retain 75% when it was already above that level.

I then reduced the keep to 50 and it changed to this plan which shows the warning in place until 18:00 which is correct but it’s not needing to change the plan as the battery is scheduled to remain above 50% until after that time anyway.

I think more testing may be required.

G
#1052 geoffreycoan

Goshiki2 I got a notification of “Hold Charging 80% - 75%” and the battery immediately started charging from grid at max rate with the yellow warning notification on the new plan lasting until midnight. I can’t understand why it would need to charge to retain 75% when it was already above that level.

You may be the first to actually try this alert logic for real ! I like the blue background and exclamation symbol, and that they work in the predbat table card

It would be useful to see what the underlying inverter charge start/end times and target SoC % were as it could be the way that these were set is what caused the battery to charge rather than hold charge.

If you look at the sensor history you could see what they were set to at the time.

I had a very similar example yesterday, predbat was planning a freeze charge but actually the battery started charging at full rate. I think in my case the problem was the setting of the charge start too early
https://github.com/springfall2008/batpred/issues/2035

Have a look and see if you have the same issue and add to mine.

G
#1053 Goshiki2

geoffreycoan I’ve checked the history for charge slot 1 and it changed from 00:30 (which it normally defaults to) to 11:30. It made this change at 11:41 when I was adjusting the yaml so it would have immediately become active, hence the full rate charging. Target SOC was 100%
I’ve checked GitHub and there are a number of issues similar to yours where freeze charging results in full power charge from grid.

G
#1054 geoffreycoan

Goshiki2 I’ve checked the history for charge slot 1 and it changed from 00:30 (which it normally defaults to) to 11:30. It made this change at 11:41 when I was adjusting the yaml so it would have immediately become active, hence the full rate charging. Target SOC was 100%
I’ve checked GitHub and there are a number of issues similar to yours where freeze charging results in full power charge from grid.

If you’ve still got the predbat logfile then worth adding this and the screenshot above to one of those issues to keep it on Trefor’s radar. I feel sometimes he gets too many issues to deal with

T
#1055 TX200

PredBat failure. Or weather failure!

It reckons I'll get from 23% to 100% by the end of the afternoon.

Hope it stops raining soon! Not exactly sunny. 😭🤣

T
#1056 TX200

At 59% now. The sun is out. Worrying about nothing. 🤣🤣🤣

#1057 PianSom

So this morning at 10.30 I had a silent Predbat crash. The last log entry said

and then nothing. I only noticed because I couldn't understand why the plan hadn't updated.

Restarted the docker container and all was well. Hmmm....

R
#1058 Rbor

Is this linked with Trefor's weather warnings, mentioned also earlier in recent posts?

Rob

T
#1059 The Black Cat

PianSom So this morning at 10.30 I had a silent Predbat crash. The last log entry said

I got exactly the same at 10:30. I had to restart HA to get everything back working when I noticed at 12:30. I was surprised Predbat hadn't reported an error or restarted as I had tested the Predbat error monitor not that long ago. When I investigated, I found I had accidentally put 533ea71a_givtcp in the automation "Predbat Error Monitor" instead of 6adb4f0d_predbat. I think I must have done this when I moved to GivTCP3 at the beginning of February.

T
#1061 The Black Cat

PianSom

Will do

G
#1062 geoffreycoan

The Black Cat the predbat error monitor should spot that the predbat plan is stale and restart predbat, although not if you put the wrong addon details in

PianSom appreciate you can’t restart the docker container from HA core but could you use the error monitor to send an alert instead?

#1063 PianSom

geoffreycoan appreciate you can’t restart the docker container from HA core but could you use the error monitor to send an alert instead?

Yep, could do. TBH stability hasn't really been an issue, so it has never made it to the top of the list of stuff to do.

Remind me - do you get notified when things restart using your script? Just wondering if anyone else has the 10.30 issue.

G
#1064 geoffreycoan

PianSom Yes I do and no I didn’t get alerted today

Had another GivTCP battery_charge_total sensor go awol today, this time on the other inverter. Might think about an automation to detect this

I have quite a few alarm/alert type of automations as I like to know when things stop working

B
#1065 browellm

@PianSom @The Black Cat I had the same silent crash at 10:30. Not using the weather features here. Couldn't see anything at all in the logs.

Restarting predbat sorted it.

How odd!

R
#1066 Rbor

[unknown] [unknown] [unknown]

Is it all connected to v8.13.0 of predbat?: 'New bad weather alert system':
Check out https://github.com/springfall2008/batpred/releases/tag/v8.13.0.
You will see the line of code that looks as if it is causing the issue.

There was some code to be added to apps.yaml
I added this to my apps.yaml but then commented out all the lines as the alarm seemed a bit 'sensitive'.
There is a .py file that was added to our predbat in this update: alertfeed.py
This includes:
https://feeds.meteoalarm.org/feeds/meteoalarm-legacy-atom-united-kingdom

I am doing adding this information to the Github issue that @"PianSom" posted earlier today:
https://github.com/springfall2008/batpred/issues/2043
The log posted here suggests that the url above was initiated my apps.yaml.

Rob

R
#1067 Rbor

PianSom The Black Cat browellm

Is it all connected to v8.13.0 of predbat?: 'New bad weather alert system':
Check out https://github.com/springfall2008/batpred/releases/tag/v8.13.0.
You will see the line of code that looks as if it is causing the issue.

There was some code to be added to apps.yaml
I added this to my apps.yaml but then commented out all the lines as the alarm seemed a bit 'sensitive'.
There is a .py file that was added to our predbat in this update: alertfeed.py
This includes:
https://feeds.meteoalarm.org/feeds/meteoalarm-legacy-atom-united-kingdom

I am adding this information to the Github issue that @"PianSom" posted earlier today:
https://github.com/springfall2008/batpred/issues/2043
The log posted here suggests that the url above was initiated my apps.yaml.

Rob

D
#1068 Dpe

For the car_charging_energy YAML entry what is the requirement for the sensor? I have a sensor that is in Wh, I have converted to kWh as per the instructions, however it seems to reset to zero when the car is unplugged. This means it can reset to zero at nine in the morning and potentially have another charge done in the afternoon. Does this matter or does it need to be an continuously incrementing sensor or one that is set to zero at midnight?

J
#1069 JasonF

When I set a discharge rate on my AIO’s, they actually discharge slightly higher. For example I set 6000 in apps.yaml and this sets 3000 per AIO. But they each actually discharge at 3200.

This means they discharge faster than the predbat plan.

Is there a way to model the inflated rate in the plan? (Without actually setting the inverter to 3200).

Thanks

D
#1070 Daveb01

@JasonF #p77489

Hi yah, mine does the same, but what I did not know is you see the discharge you set plus it adds house load. The other thing that happens but I can not remember the reason, it is rounded up by 50 or something, so 2 x AIO maybe 100. You have to go onto the GE cloud move the slider and it rounds it up or down. I think you mentioned this as well.

So I wanted to import at 10000 (5000 each AIO) but it would only let me set 9960 or 10010.

Have you tried reducing the 6000 to say 5960 or something?

J
#1071 JasonF

[unknown] but it’s the same problem. If I set the inverter limit lower it will still discharge higher. I don’t care that it discharges higher, just wondered if there’s a way to tell predbat that’s what it’s going to do.

J
#1072 JasonF

Daveb01 but it’s the same problem. If I set the inverter limit lower it will still discharge higher. I don’t care that it discharges higher, just wondered if there’s a way to tell predbat that’s what it’s going to do.

R
#1074 Rbor

It's been very quiet this past week from Trefor.
I wonder what he has been cooking up for us?

Rob

J
#1075 JasonF

[unknown] ah yes that makes sense! Thanks!

G
#1076 geoffreycoan

Dpe For the car_charging_energy YAML entry what is the requirement for the sensor? I have a sensor that is in Wh, I have converted to kWh as per the instructions, however it seems to reset to zero when the car is unplugged. This means it can reset to zero at nine in the morning and potentially have another charge done in the afternoon. Does this matter or does it need to be an continuously incrementing sensor or one that is set to zero at midnight?

it sounds like you've got an 'energy this charge' sensor rather than an 'energy charged today' sensor.

The sensor is used by predbat to subtract car charging from the house load so that predbat predicts your load without the car charging artificially inflating it.

To be honest I don't know what the impact of this would be on predbat. It might work OK but it would really depend on how the predbat code deals with the history changes.
I think the best thing is to look at some of your predbat plan projections around the time you were charging the car and compare that to the givtcp load energy history for the same time period (remember it is in 30 minute slots so you'll have to look at the kWh values at the start and end of each period in the history graph and subtract one from the other), and compare that to what's in the predbat plan.
Maybe set days_previous to a small range say '2' otherwise you'll be trying to average things out over several days.

If it doesn't work then you should be able to create a helper utility meter to wrap around your existing sensor.

JasonF the answer given by Ivan is correct, you set battery rate max scaling charge/discharge to reflect any difference in charging/discharging from what Predbat commands to what you actually achieve.

I have my charge set to 0.92 and discharge to 1.04 as I charge at 2.4kWh and discharge at 2.9, not the 2.6 the inverter reports it can deliver.

Daveb01 what I did not know is you see the discharge you set plus it adds house load

shouldn't do, if you set a discharge rate you will get that discharge rate, but any house load is met first with the remainder being exported

Rbor I noticed that. Think he must be away with work. Amazing how much he gets done and still works somehow in-between

D
#1077 Dpe

geoffreycoan
Hi, I was going to create a sensor that does what Predbat wants as the best option.
I guess Predbat is optimised to a Zappi charger, in this case how does the Zappi sensor behave, is it a 'total' of all the charge to the car since it was installed?

G
#1078 geoffreycoan

Dpe Hi, I was going to create a sensor that does what Predbat wants as the best option.

probably safest if you can

it says in the documentation

car_charging_energy - Set in apps.yaml to point to a Home Assistant entity which is the incrementing kWh data for the car charger

So I would take from this that yes, it is a total sensor that increments from zero and never resets

B
#1079 browellm

If the screenshot I've just seen for the future rates of IOG is not fake, Trefor's compare feature is going to be invaluable in the next few weeks 😬

#1080 PianSom

browellm
IOG rates are changing?

V
#1081 Vestas

PianSom Bound to, the price cap is changing.

T
#1082 TX200

The screenshot showed IOG off peak going from 7p to 13.5p/kWh

Quite a jump if it is true. But probably best to treat it with a pinch of salt for now, no idea if it's a trusted source !

V
#1083 Vestas

TX200 TBH that sounds reasonable - Cosy is near enough that price off-peak so clearly the EV tariffs have been heavily subsidised by other customers. Also buying gas generation to support overnight EV charging isn't green - even with the (almost useless) offsetting.

We'll see if its true soon enough.

Edit - I wonder is its going to be like EON/etc - one rate for everyone and a "special" rate for people who got Octopus to install their EV charger/PV/battery/HP....

R
#1084 Rbor

Hopefully late February 2025 gives us good signals for more PV in the coming months.
9:30am and I already have 5 kWh generated. 😎

What a contrast with mid February from 7th to 16th. Today's generation will likely be more than the those 10 days combined with grey skies and sub-zero temperatures 🥶.

Rob

G
#1085 geoffreycoan

Rbor Much better sun today, had peaks up to 5.5kW power, generating 15kWh so far this morning.
Currently exporting at 4kWh ahead of the power up, so I’m not going to be saving all that much as the panels are generating near to my peak charge rate. First world problems

Am thinking that now is going to be a good time to do a recalibration on my 9.5 battery which has been showing signs of voltage disparity and not being able to achieve full capacity. I’ll probably kick one off on the weekend if I’m around and the sun makes it possible

D
#1086 Daveb01

geoffreycoan

That’s such a good idea, I may do that as well.

D
#1087 Daveb01

I am thinking Trevor may need to put something in Predbat like they do for gambling apps, set a limit, take a break etc, for the Compare feature, it’s becoming very addictive 🥴🤷🏼‍♂️

Z
#1088 Zakalwe

Man, I'm getting tired of this:

No changes made, no updates that I am aware of, but still I awoke to a flat battery and this:
Screenshot-2025-02-28-103044.jpg

Screenshot-2025-02-28-103025.jpg

Everything borked overnight. No idea why or how.

L
#1089 Leeshore

Looks like givtcp is not working - try restarting it?

S
#1090 SteveCook

GivTCP2 or GivTCP3?
is one more reliable/stable than the other?

Z
#1093 Zakalwe

GivTCP logs::

                              ^

SyntaxError: unterminated string literal (detected at line 10)
[2025-02-28 10:54:26 +0000] [999] [INFO] Worker exiting (pid: 999)
[2025-02-28 10:54:26 +0000] [1000] [ERROR] Exception in worker process
Traceback (most recent call last):
File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 608, in spawn_worker
worker.init_process()
File "/usr/local/lib/python3.10/site-packages/gunicorn/workers/base.py", line 135, in init_process
self.load_wsgi()
File "/usr/local/lib/python3.10/site-packages/gunicorn/workers/base.py", line 147, in load_wsgi
self.wsgi = self.app.wsgi()
File "/usr/local/lib/python3.10/site-packages/gunicorn/app/base.py", line 66, in wsgi
self.callable = self.load()
File "/usr/local/lib/python3.10/site-packages/gunicorn/app/wsgiapp.py", line 57, in load
return self.load_wsgiapp()
File "/usr/local/lib/python3.10/site-packages/gunicorn/app/wsgiapp.py", line 47, in load_wsgiapp
return util.import_app(self.app_uri)
File "/usr/local/lib/python3.10/site-packages/gunicorn/util.py", line 370, in import_app
mod = importlib.import_module(module)
File "/usr/local/lib/python3.10/importlib/init.py", line 126, in import_module
return bootstrap.gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in gcd_import
File "<frozen importlib.
bootstrap>", line 1027, in find_and_load
File "<frozen importlib.
bootstrap>", line 1006, in find_and_load_unlocked
File "<frozen importlib.
bootstrap>", line 688, in load_unlocked
File "<frozen importlib.
bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/app/GivTCP_1/REST.py", line 6, in <module>
import read as rd #grab passthrough functions from main read file
File "/app/GivTCP_1/read.py", line 12, in <module>
from GivLUT import GivLUT, GivQueue, GivClient, InvType
File "/app/GivTCP_1/GivLUT.py", line 15, in <module>
class GivQueue:
File "/app/GivTCP_1/GivLUT.py", line 18, in GivQueue
from settings import GiV_Settings
File "/app/GivTCP_1/settings.py", line 10
MQTT_Password="[DELETED]""
^
SyntaxError: unterminated string literal (detected at line 10)
[2025-02-28 10:54:26 +0000] [1000] [INFO] Worker exiting (pid: 1000)
[2025-02-28 10:54:26 +0000] [997] [ERROR] Worker (pid:998) exited with code 3
[2025-02-28 10:54:26 +0000] [997] [ERROR] Worker (pid:1000) was sent SIGTERM!
[2025-02-28 10:54:26 +0000] [997] [ERROR] Worker (pid:999) was sent SIGTERM!
[2025-02-28 10:54:26 +0000] [997] [ERROR] Shutting down: Master
[2025-02-28 10:54:26 +0000] [997] [ERROR] Reason: Worker failed to boot.

G
#1094 geoffreycoan

Zakalwe givtcp3 is more reliable, I’ve not seen that set of errors before, looks like its failing to start

if you delete the /config/GivTCP/*.pkl files (these are cache files and can be safely deleted), then restart givtcp

B
#1095 browellm

Was suprised to see it's over a month since I moved over to Agile Outgoing, so today I've swapped back to Fixed Outgoing to take advantage of what looks like the more reliable daily output for the summer.

Z
#1096 Zakalwe

geoffreycoan

I never managed to get GivTCP3 running. The last time I tried it borked the whole thing and I had to reinstall Ver 2.

What I don't get is why it suddenly stopped working. No update, no changes, just stopped.

geoffreycoan if you delete the /config/GivTCP/*.pkl files (these are cache files and can be safely deleted), then restart givtcp

You are talking to an idiot. How do I do that? (Am running HAOS on a Pi)

R
#1097 Rbor

Zakalwe Open File Editor.
The screenshots below show how to find the pkl files.

  1. Select givTCP (red arrow)
  2. Then delete each pkl file, one at a time. (green arrows)

If you don't have File Editor, get it installed as an Add-On. See below for details.
You can attach File Editor to the side bar for ease of running.
https://springfall2008.github.io/batpred/install/

Hope that helps

Rob
A fellow idiot but improving

R
#1098 Rbor

Zakalwe
Another useful tip which can get HA, givTCP and predbat working properly.
Completely reboot HA:

1. Developer Tools

2. Restart

3. Advanced options. Select Reboot system.

Rob

Z
#1099 Zakalwe

[unknown]
Yep, I've done all that.

[unknown]
Not too sure whats happened on mine, but when I go to File Editor I know get this:

Screenshot-2025-02-28-150917.jpg
with no way to get to the files!

I swear that I sometimes think that this thing is laughing at me!

Z
#1100 Zakalwe

Sussed File Editor....for some reason Enforce Basepath had de-selected itself in Settings.

FFS!

R
#1101 Rbor

Zakalwe But you are learning (as I have done).
Just find those pkl files now from my screenshots and zap them.

Rob

Z
#1102 Zakalwe

[unknown]
Yep, done that. No difference.

R
#1103 Rbor

Zakalwe Any changes to the logs?
Did you reboot?

Rob

D
#1104 Daveb01

Has anyone done this? Give it a go.

Go to HA (any page) mine is on my Home page. Then shake your device ( one is an iPad)

Z
#1105 Zakalwe

Rbor

Hi Rob,

Sort of got fed up with it so I chose violence and uninstalled Mosquitto, GivTCP and a few other bits. For some reason GivTCP was not seeing MQTT. I ended up creating a new MQTT user and password, reinstalled GivTCP and finally got it talking to MQTT.
Now managed to get GivTCP ver 3 up and running.

Some data is flowing through, though the Predbat plan isnt worrking yet. And all my graphs and dashboards are still borked.

I
The Predbat Plan is blank though.

R
#1106 Rbor

Zakalwe Sounds like some progress.
Have you gone for 'restart predbat'.
Look at the logs as it restarts and post here.

Do check the givTCP log (and mosquitto) as well.

Rob

G
#1107 geoffreycoan

Interesting day today, I’ll keep it short, you can read the github issue I raised https://github.com/springfall2008/batpred/issues/2062

But in short, if HA loses internet connectivity then you get lots of errors in the HA/core log from things that can’t connect, GivTCP works fine, sending statii and inverter data to HA OK,

BUT Predbat crashes when trying to connect to meteoalarm. Tries again 5 minutes later, no internet connection, crashes again.
This went on for 2 hours of internet outage so my inverter got stuck in forced export mode and didn’t change to charging for the power up and Cosy charging periods until the internet came back some time later.

I have commented meteoalarm out of my apps.yaml for now

R
#1108 Rbor

geoffreycoan I have commented meteoalarm out of my apps.yaml for now

I have just browsed through your tale of woe on Github.

I had meteoalarm active in my apps yaml just for a few hours. I then imagined the alarm going off for all sorts of marginal events. So I commented the lines out almost as soon as I had added them.

From the fun and games that @PianSom has encountered with meteoalarm, this looks to have been a sensible decision by me.
I do make some sensible decisions!

Rob

S
#1109 SteveCook

Switched from ECO7 to Flux today. The import has been pretty quick and the tariff in GivEnergy portal has updated.
Octo says export tariff may take longer to update.
Predbat has spotted the shorter off peak import period, but is still planning to charge at the higher rate from 00:00 until 02:00.
Any ideas please?

S
#1110 SteveCook

Switched from ECO7 to Flux today. The import has been pretty quick and the tariff in GivEnergy portal has updated.
Octo says export tariff may take longer to update.
Predbat has spotted the shorter off peak import period, but is still planning to charge at the higher rate from 00:00 until 02:00.
Any ideas please?

S
#1112 SteveCook

geoffreycoan
Thanks, but that looks scarily difficult
The correct import rates have come through as seen in the screenshot, but predbat is choosing to charge for 2 hours at the higher (non off peak rate)
I am not too worried about the export rates coming through as sun still limited, but i wanted to get signed up so everything is working when the sun finally arrives.
It is import times I really want to get correct

S
#1113 SteveCook

I have not done anything or changed anything, but now it is looking to get 100% charged on normal rate rather than wait for the off peak charge
.

G
#1114 geoffreycoan

SteveCook sorry Steve, I didn’t look at the original plan properly, what was presented is weird, and this one is even weirder. I can’t see any reason why Predbat would charge up in the day rate only to then have a cheaper 14p period that the battery is already full.

Sometimes Predbat does strange things.

I’d suggest you use the manual overrride controls, select.predbat_manual_demand and select in turn 22:00, 22:30, 23:00 … 01:30. This will forced predbat into Demand mode for those slots and thus your battery will continue to drain from 14% to empty until you start grid importing, it will keep the battery empty then until the 02:00 cheaper period.
Alternatively you could do the same on select.predbat_manual_freeze_charge to keep the SoC in the battery until 2am and then the charging starts from a part-full battery.

I can understand the charging shown from 05:00 until 08:30, predbat is basically holding the battery at 100% charge level until the sun comes up and then you’ll start exporting everything generated (minus house load). This is more efficient to earn export straight away at what it thinks is 15p than to let the battery drain (having charged it at 14.32p), incur another set of battery losses, only to then replenish the battery from solar afterwards

S
#1115 SteveCook

Geoffrey. Thanks for helping, but it is Saturday nigh and you should be supping a beer .
I have done nothing, but it seems to have sorted itself out

S
#1116 SteveCook

Geoffrey. Thanks for helping, but it is Saturday night and you should be supping a beer .
I have done nothing, but it seems to have sorted itself out.
Sorry everyone about the multiple posts. This forum is getting very flaky

G
#1118 geoffreycoan

PianSom badge collecting 🤮

L
#1120 Leeshore

[unknown] Just followed your link. Most topics have [unknown] answering them. Can’t get away from him 😆

L
#1121 Leeshore

PianSom Just followed your link. Most topics have geoffreycoan answering them. Can’t get away from him 😆

G
#1122 geoffreycoan

Leeshore You won’t find a @geoffreycoan on the other forum, he doesn’t exist

But he sure is a helpful guy

W
#1123 Wavy Davy

I seem to be having problems with predbat charging my system, despite saying its holding charge it is charging it.
If I restart the system it sorts itself out but otherwise it just keeps charging.
this was the plan.

G
#1125 Goshiki2

Wavy Davy There are a few similar concerns on GitHub. Hold charging actually charging at full rate even though the target SOC is lower than the current.

R
#1126 Rbor

Leeshore [unknown] Just followed your link. Most topics have [unknown] answering them. Can’t get away from him

I am thinking of enrolling onto this forum as another user called 'unknown'.
You will see just how helpful I can be then!

Rob

Z
#1127 Zakalwe

[unknown]

Still struggling with this and am down the rabbit hole. Ive got GivTCP ver 3 up and running, but there seems to be a load of sensors missing. All of the Predbat sensors are blank.

At this stage I am going to wipe Predbat and start from scratch.

This is my biggest gripe with HA. It's all fine until it isn't. You wake up some morning to find it is not working and then you have to be an expert to get it back and running. I've wasted do many hours on this this weekend and have probably lost my sense of humour with it!

G
#1128 geoffreycoan

Zakalwe but there seems to be a load of sensors missing. All of the Predbat sensors are blank.

what sensors are missing, are they battery sensors? There is a problem that both @Rbor and I had in upgrading to GivTCP 3 whereby it kept hold of the v2 battery sensors - you get a load of ‘can’t create duplicate sensor’ messages in the Home Assistant core log. Worth checking if you have this issue. Deleting the old entries with MQTT Exporter or completely removing MQTT an rebooting everything before reinstalling MQTT should cure it.

Blank predbat sensors points to a browser issue (assuming the predbat logs are OK), try with a different browser / clear the cache etc

R
#1129 Rbor

geoffreycoan Is one 'solution' to reinstall Mosquitto?

what sensors are missing, are they battery sensors?

When I had issues, I lost all givTCP battery info: cell voltages, SOC, etc.
I cleared up the problem using MQTT explorer but that was yet another new skill to learn!

Please confirm whether reinstalling Mosquitto is worth trying.

Rob

G
#1130 geoffreycoan

Rbor I never tried it, but uninstalling Mqtt and rebooting HA should break the mqtt to entity link. Might need to delete the entities before reinstalling mqtt.

Mqtt explorer is a fix we both know works

R
#1131 Rbor

geoffreycoan Mqtt explorer is a fix we both know works

Agreed

Rob

Z
#1132 Zakalwe

I had something similar before and ended up deleting Mosquitto and reinstalling it.

Here's where I am now:
GivTCP ver 3 installed and working. I can see output in MQTT Explorer.
Screenshot-2025-03-02-161501.jpg

Mosquitto broker uninstalled and reinstalled.
MQTT User set up.
Solcast set up.
Predbat uninstalled. All old Predbat folders deleted.
Predbat reinstalled.
Apps.yaml filled in as per Predbat documentation.

When creating the Predbat dashboard, none of the sensors are showing.
The predbat plan is also blank and showing "null".

Screenshot-2025-03-02-161819.jpg

Screenshot-2025-03-02-162251.jpg

G
#1133 geoffreycoan

Zakalwe the predbat entities are not created until predbat runs successfully.

What do you see in the Log view of the Predbat addon, or in the logfile /addon_configs/6axxxx_predbat/predbat.log ?

In particular at the end, what messages do you see.

Usual issue is a simple indentation issue in apps.yaml, and hopefully whatever is in the logfile will point you to it.

Z
#1135 Zakalwe

Righto...I think that I have got it back.

I had some mqtt lines in configuration.yaml that was incorrect. Also, there was an error in apps.yaml relating to the Ohme charger.

I still do not understand why everything was working fine until the other night when it all fell over.

G
#1136 geoffreycoan

Zakalwe I was just looking at your long log messages (think you have deleted the post from the thread now), this indicated that predbat wasn’t able to find your inverter number, usually because a givtcp_xxx_soc_kwh sensor didn’t exist (which is what geserial pattern matches on).
The error in the HA log looked like possibly the MQTT broker wasn’t configured or something like that

If you are sorted now, great. I don’t recall having anything configured in configuration.yaml to get mqtt or predbat up and running

Difficult to know what was broken before

Z
#1137 Zakalwe

[unknown]

Thanks Geoffrey.
That log was from the fresh install of Predbat, not the original (I chose violence and wiped the lot and reinstalled it).

It sure does lead you down the garden path this thing. Great when it works, but boy, it's not for the faint-hearted to fix when it all comes crashing down.

G
#1138 geoffreycoan

Zakalwe If only you knew what it was you'd done, you would know not to do it again!

My current annoyance is random GivTCP spikes on the total sensor that then need fixing in long term statistics. Wish I knew why these were happening as well:

The first one was GivTCP spiking, the second was me reloading GivTCP which reverses the spike

Z
#1139 Zakalwe

[unknown] If only you knew what it was you'd done, you would know not to do it again!

Well, there's the rub. I didn't do anything......was working fine on Wednesday night. Woke up on Thursday to a flat battery (dumped into the car) and Predbat and all my dashboards borked. No updates overnight- I have disabled all automatic updates. Total mystery! Must have been a glitch in the Matrix...

Z
#1141 Zakalwe

SamM I'm seeing the same behaviouir now, as predbat has planned a Hold Charge before today's saving session but is instead charging the battery from the grid.

Same here

S
#1142 SteveCook

Dont know where the $rates have come from at 18:00 and 18:30
I switched from Eco7 to Flux over the weekend. The Flux import may take a few weeks to setup (so Octo say), so the old 15p export rate still shows

Any ideas
Thanks in advance

T
#1143 TX200

SteveCook saving session?

S
#1144 SteveCook

TX200
Thanks
But why import at 18:30 at peak rate - even if shown in $

Z
#1145 Zakalwe

Ohme drawing from battery.

So, I have set up app.yaml as per the New Ohme section in the Predbat docs: https://springfall2008.github.io/batpred/devices/#new-ohme. I am using the new Ohme integration: https://www.home-assistant.io/integrations/ohme

I can see output from the various sensors, which tells me that HA can see the charger:
Screenshot-2025-03-03-142029.jpg

However, if the Ohme selects and out-of-off-peak-hours slot, the battery is draining into the car, unless I select a Force Charge.

switch.predbat_octopus_intelligent_ignore_unplugged is On
switch.predbat_car_charging_from_battery is Off

The plan is not recognising that the car is charging as the Car kWh section is blank. It's probably something simple that I am missing.....any ideas?

T
#1146 TX200

SteveCook it's got a down arrow, so discharge?

G
#1147 geoffreycoan

SteveCook But why import at 18:30 at peak rate - even if shown in $

its not importing at 18:30

as TX200 says, its showing a down arrow, so Eco mode discharging

in the right hand cost column you can see +43p, and your load over the half hour period is 2.09kWh. I read from this that Predbat expects (based on previous history) that your house load will exceed your inverter capacity and there will be a small amount of grid import as a result. Hence the +43p because you get penalised for importing in the saving session period.

The $ symbol indicates its a saving session adjusted rate

If you will shift/reduce your load in the saving session then you can set input_number.predbat_load_scaling_saving to indicate what the adjusted load will be, e.g. 0.5=50% reduction

Zakalwe have you configured the Predbat Octopus intelligent sensor in apps.yaml to pick up the list of slots from Ohme? https://springfall2008.github.io/batpred/devices/#new-ohme

Z
#1149 Zakalwe

I've also tried:

Screenshot-2025-03-03-150438.jpg

T
#1150 TX200

How does the baseline value work?

Does it only update the value of a saving session is called?

My data has been the same since 25th Feb and then updated 1130 today.

I guess it's got to be tied to the saving session - seems about the right time?

0.3528 kWh export
0.0112 kWh import

Hopefully I can beat that, otherwise it won't really be worth exporting. That said I get 25.42p for the flux export per kWh, plus up to 13p extra depending on that baseline Vs actual export achieved (maximum is 2.6kWh output, but some for the house and some kept for the evening).

It's estimating 83p gain for the hour.

Although I'm not sure if PredBat considers the baseline when calculating that?

S
#1151 SteveCook

[unknown]

[unknown]

Thanks but my Total cost has gone up by 43p even though it looks like I have exported?

T
#1153 TX200

SteveCook the saving session hasn't started yet has it?

It will depend on your household usage. Are you planning to run any heavy loads like oven at that time?

I guess it thinks you normally do based on previous data.

S
#1154 SteveCook

TX200
Thanks. I guess the load column of 1.97 thinks I am going to put the cooker or dishwasher on or something.
I guess I will have to put off cooking or housework for an hour!!

L
#1155 Leeshore

My export rate for DFS session keeps changing by 13p. Currently on 93p! Have reported on Github....

G
#1156 geoffreycoan

Leeshore My export rate for DFS session keeps changing by 13p. Currently on 93p! Have reported on Github....

somebody else reported this for an earlier session, I think it was due to manually defined rates

TX200 Although I'm not sure if PredBat considers the baseline when calculating that?

No, predbat doesn’t calculate the baseline figure in that income prediction, it’s purely based on the import and export rates and kWh shifted. So if you regularly export in the peak (e.g. on Flux) then it’s not going to be as generous.
TBH if on Flux probably worth trying to do export as early as possible, 4-5pm, as the saving sessions are usually slightly later

L
#1157 Leeshore

geoffreycoan I'm using the octopus api savings thingy.

apps.txt
20kB
R
#1158 Rbor

Early March 2025 sunshine

After our up-and-down February, we deserve these sunny day.
This is mine from today after the last 2 days of 29.6 kWh and 33 kWh

And to think from Feb 7th – 13th, I saw no sun at all with constant grey skies.

Rob

P
#1159 Paul H

Can anybody tell me how to stop this on the energy dashboard?

Everyday at midnight it puts a negative amount in equal to the previous days consumption and screws up the axis.
I suspect it started when I installed GivTCP v3

G
#1161 geoffreycoan

Paul H Can anybody tell me how to stop this on the energy dashboard?

change to using the total sensors instead of the today sensors in the energy dashboard.

With GivTCP 3 it takes a bit longer to reset the today sensors at midnight which screws up the graphs.

T
#1162 TX200

Does anyone else get confusing messages from PredBat.

It sends a message via the app to say it's exporting to 24% but the plan says 34% limit.

Always seems to be 10 out.

R
#1163 Rbor

Warnings in predbat log since installing octopus app for log.
See below. Any ideas?

**** Starting Standalone Predbat ****
2025-03-04 19:52:24.831632: Loading apps.yaml
2025-03-04 19:52:24.893499: Info: Connected to Home Assistant at http://192.168.68.83:8123
2025-03-04 19:52:24.896196: Warn: Failed to decode response <Response [404]> from http://192.168.68.83:8123/addons/self/info
2025-03-04 19:52:24.896365: Creating task: <coroutine object HAInterface.socketLoop at 0x7fafb88660>
2025-03-04 19:52:24.896742: Info: Web Socket task started
2025-03-04 19:52:24.896965: Info: Start socket for url http://192.168.68.83:8123/api/websocket
2025-03-04 19:52:24.897032: Creating task: <coroutine object WebInterface.start at 0x7faf4bfdf0>
Web interface started
2025-03-04 19:52:24.902930: Info: Web Socket active
2025-03-04 19:52:24.951904: Warn: Regular expression argument: octopus_ready_time unable to match re:(time.octopus_energy([0-9a-z_]+|)_intelligent_target_time), now will disable
Watching ['./compare.py', './execute.py', './fetch.py', './web.py', './userinterface.py', './alertfeed.py', './prediction.py', './output.py', './energydataservice.py', './download.py', './ha.py', './gecloud.py', './inverter.py', './unit_test.py', './plan.py', './predbat.py', './utils.py', './config.py', './octopus.py', './apps.yaml', './predheat.py', './hass.py', './solcast.py', './futurerate.py'] for changes
2025-03-04 19:52:28.833645: Warn: Historical day 3 has 40 minutes of gap in the data, filled from 25.96 kWh to make new average 26.7 kWh (percent 97%)
2025-03-04 19:52:28.838684: Warn: Historical day 4 has 15 minutes of gap in the data, filled from 24.21 kWh to make new average 24.46 kWh (percent 99%)
2025-03-04 19:52:41.925138: Info: record_status Demand

Thanks

Rob

G
#1166 geoffreycoan

Rbor
2025-03-04 19:52:24.893499: Info: Connected to Home Assistant at http://192.168.68.83:8123
2025-03-04 19:52:24.896196: Warn: Failed to decode response <Response [404]> from http://192.168.68.83:8123/addons/self/info

This because you have set ha_url in apps.yaml and so the code that then trys to get the slug id doesn’t work. I have a version (linked much earlier in this thread) that works on my setup with/without ha_url configured but crashes on @Wavy Davy ’s which I hadn’t got to the bottom of. Obviously want to get a version that works for everyone

G
#1167 geoffreycoan

Hi Wavy Davy

Back on trying to work out why the code modifications I had made crashed on your HA but work on mine.

I hit on the idea that it might be that you are running a newer predbat version than me, and my editing an older version brought in an incompatibility

So, can you try this version again and share me the logfile please:
https://drive.google.com/file/d/1aeIZSRvhSjsAk1aWvkr8MOpw1S4EUKtg/view?usp=drive_link

(this is the same one from before, based on my predbat 18.14.4

And then this one is the same changes but applied to the latest predbat 18.16.0:
https://drive.google.com/file/d/1G6u6BAo5SUtgDh1u0CV5rbT8DW1ABWph/view?usp=sharing

thanks Geoffrey

R
#1168 Rbor

geoffreycoan This is strange.
The version of ha.py you supplied to me got rid of my error shown above.
I am running predbat v8.15.1

Rob

W
#1169 Wavy Davy

[unknown] Geoff, do you still want m to try this as The last version you gave me has no errors?

D
#1171 Dpe

Now the sun is shining and not much charging is needed overnight I am seeing a significant increase in the number of inverter writes. This seems to be co-incident with the use of the pause mode and I suspect the combination of plan updates and the use of low power mode. Does anyone else see this with a Gen 1 AC3. I am going to try a couple of days with low power mode disabled to see if this has any effect. I guess another alternative would be to comment out the pause in the config Yaml?

G
#1172 geoffreycoan

Dpe have you got the battery pause start and end times commented out in apps.yaml?

The AC3 (and Gen 1 hybrid) inverters with fast response firmware have battery pause support but not the start and end pause entities. It looks like Predbat is repeatedly trying to write to these entities and not getting back the response it expects, so 5 minutes later it tries again

Comment these specific lines out and all should be well

See https://github.com/gcoan/batpred/blob/main/docs/apps-yaml.md#schedule

Wavy Davy Geoff, do you still want m to try this as The last version you gave me has no errors?

Really??? I am confused, I thought it was still crashing!

Can you share me the ha.py that works with no crashes, and if possible the log when predbat starts up (just restart predbat and it'll do the logging I am looking for).
Great news I can get this baked into the next release

D
#1173 Dpe

[unknown]

Yes I have got the pause start and end times commented out in apps.yaml
The only entry not commented out is this:

pause_mode:

  • select.givtcp{geserial}battery_pause_mode
D
#1174 Dpe

geoffreycoan

Yes I have got the pause start and end times commented out in apps.yaml

The only entry not commented out is this:

pause_mode:

  • select.givtcp{geserial}battery_pause_mode
R
#1175 Rbor

Dpe This looks good. I have an AC3.0 running firmware version: D0.205-A0.205
These are my 'pause' apps.yaml entries and I have pause start time and end time entries commented out.:

# Pause mode is not supported by all firmware's and will be ignored if not present
  pause_mode:
    - select.givtcp_{geserial}_battery_pause_mode
#    - select.givtcp_{geserial2}_battery_pause_mode

# Not all firmwares support pause start/end time, delete these if not supported
# to avoid spurious writes/warnings
#  pause_start_time:
#    - select.givtcp_{geserial}_battery_pause_start_time_slot
#    - select.givtcp2_{geserial2}_battery_pause_start_time_slot
#  pause_end_time:
#    - select.givtcp_{geserial}_battery_pause_end_time_slot
#    - select.givtcp2_{geserial2}_battery_pause_end_time_slot

I get an average of 50-60 register writes per day. So about 1 every 25-30 min.

Rob

G
#1176 geoffreycoan

Dpe thanks for confirming, looking at the givtcp log again I think the battery pause is a red herring, what it appears is that Predbat is oscillating every 5 minutes between charging and not charging, and as part of that is setting battery pause mode on and off, but its also toggling charge schedule on and off, all of which are causing the high number of register writes

What’s the plan look like, and what does predbat.status show for this time period, my guess is that it shows oscillation too.

There must be something in the plan config that is causing this. Is switch.predbat_calculate_export_oncharge on, might turn this off.
I don’t think commenting the battery pause out of apps.yaml will cause any material improvement, it will remove the battery pausing, but there’s a bigger issue than that

D
#1177 Dpe

[unknown]
switch.predbat_calculate_export_oncharge is already switched off.
As you say predbat.status shows an oscillation between charging and hold charging every 5 minutes.
The plan for yesterday overnight is pretty much the same as tonights with a HoldChrg 10%.
It seems that when Predbat gets to 10% it is holding the charge by charging and hold charging every 5 mins. The oscillation starts just as the SOC reaches 10%. Would it not be easier just to set the discharge rate of the battery to zero? or the min SOC to 10
Hope this makes sense

D
#1178 Dpe

geoffreycoan

switch.predbat_calculate_export_oncharge is already switched off.
As you say predbat.status shows an oscillation between charging and hold charging every 5 minutes.
The plan for yesterday overnight is pretty much the same as tonights with a HoldChrg 10%.
It seems that when Predbat gets to 10% it is holding the charge by charging and hold charging every 5 mins. The oscillation starts just as the SOC reaches 10%. Would it not be easier just to set the discharge rate of the battery to zero? or the min SOC to 10
Hope this makes sense

D
#1179 Dpe

Rbor
Thanks for this, I think we had this discussion before and my yaml entries are identical. I see about 14 inverter writes a day but I am on a simple tariff with with cheap rate from midnight to 05:00.
I saw about 40 writes yesterday which is excessive based on what I had seen previously, and nearly all of these were between 01:00 and 05:00

G
#1180 geoffreycoan

Dpe there must be a predbat setting thats causing this pattern of behaviour.

Can you turn debug mode on and post the yaml debug file that gets created. Turn debug off afterwards as it generates lots of output

D
#1181 Dpe

[unknown]
I am assuming I would need debug mode on during the night when the problem occurs, is that correct?
After thinking about it last night I restored the low power mode and commented out the "pause" in app.yaml.
Below is the givTCP log showing the result of doing this:

It was not a great test because the time that the battery was not charging or discharging was fairly small, but it does seem to show that with pause disabled things are much more stable. This led me to wonder what the perceived benefit of the pause mode is?

G
#1182 geoffreycoan

Dpe its not a perfect plan still, it swaps between charging (00:53 to 04:00), Idle (04:00-04:40) then charging again (04:40:15-04:40:30), hold charging (04:40-30-04:55)

maybe try changing one thing tonight, either pause mode or low power mode and see what happens.

Answering your question, pause mode will properly pause the battery from discharging on the newer firmware. Without pause mode on this firmware all that Predbat can do is to set discharge rate to zero, which actually doesn’t fully stop discharging, the battery power bus is still activated (which is what gives the ‘fast response’), and the inverter drains at about 200W rate.
Pause mode disables the battery bus and drops discharge rate to about 30W I think

D
#1183 Dpe

[unknown]
So, a bit more information, the battery discharged normally until it reached the set SOC at 04:00, then sat idle until the car charged for for a few minutes 04:40 to 04:55 which caused the hold charging

Sorry for only posting part of the information.

D
#1184 Dpe

geoffreycoan
So, a bit more information, the battery discharged normally until it reached the set SOC at 04:00, then sat idle until the car charged for for a few minutes 04:40 to 04:55 which caused the hold charging

Sorry for only posting part of the information.

Z
#1185 Zakalwe

I see that Trevor had now updated Predbat to include Ohme chargers in ver 8.16.0. I'm hoping that that solves the issue that I have where Predbat is not picking up when the Ohme charge gives out-of-hours slots. This results in the battery draining into the car.

HA can see the Ohme charging times when I run the "Ohme:List charging slots" Action in Develope Tools, but it is not integrating those into the Predbat plan.

I have apps.yaml set as per the guide: https://springfall2008.github.io/batpred/devices/#new-ohme

Screenshot-2025-03-09-102852.jpg

G
#1186 geoffreycoan

Zakalwe have you set

  octopus_intelligent_slot: 'ohme.list_charge_slots'`
  octopus_intelligent_slot_action_config: 'XXX'
  octopus_ready_time: 'time.ohme_{ohme_name}_target_time'
  octopus_charge_limit: 'number.ohme_{ohme_name}_target_percentage'
  switch.predbat_octopus_intelligent_ignore_unplugged to on

and checked that ohme.list_charge_slots is populated by the Ohme integration? Its this that Predbat needs (fed in via octopus_intelligent_slot in apps.yaml)

Z
#1187 Zakalwe

geoffreycoan
Yes, all of that has been set.

I'll test it later when I plug in to charge.

L
#1188 Leeshore

Anyone using the new octopus energy direct feature that Trefor has added yet? Have you stopped/deleted the octopus energy integration?

G
#1189 geoffreycoan

Leeshore Anyone using the new octopus energy direct feature that Trefor has added yet? Have you stopped/deleted the octopus energy integration?

no I haven’t, and I doubt I ever will.

Couple of reasons, firstly would require reconfiguration of the energy dashboard to use new sensors from Predbat, but more importantly for me, I use target rate sensors from the Octopus integration to calculate when the cheapest period is to put the washing machine/dishwasher/tumble dryer on, and how many hours delay to set on the appliances before they start. Would also loose some of my energy charts of rates etc (or maybe have to workout how to find equivalent Predbat sensors)

Its good that Trefor has added this and for new users I can the advantage for a quicker setup, but its a bit like with Solcast, if you want to use more than the basic in-built features in predbat you still need the original integration

A
#1190 arczi19

Might be a silly question, but is there a way to manually force charge/export at given times every day? Something along the lines of predbat_manual_charge but permanent rather than one off.

Z
#1191 Zakalwe

arczi19
Would that not defeat the purpose of Predbat?

T
#1192 TX200

arczi19 I like that question !

It can be handy to export 1600-1630 to reduce the baseload for future saving sessions - guessing that they usually happen after 5pm.

So exporting for half an hour at 4pm empties a bit of the battery and therefore there is less to export later in the peak period (I'm on flux, 4-7 peak).

It's probably a niche thing though.

And there's not much money in it now anyway.

@geoffreycoan thoughts?

T
#1193 TX200

Anyone noticed any issues with PredBat following it's own plan?

PredBat decided to export 1830-1900 yesterday, but it didn't actually export. In the end I did a manual export at 1850hrs for the rest of that block.

It still said it was planning to export at the point I set the manual force export.

Wondering if something broke.

I'm on 8.16.2 and will upgrade to .3 today and see what happens.

G
#1194 geoffreycoan

arczi19 Might be a silly question, but is there a way to manually force charge/export at given times every day? Something along the lines of predbat_manual_charge but permanent rather than one off.

there isn’t a built in feature, but you can achieve what you want by writing an automation that will manually set a charge or export at whatever time you want to.

Here’s one I had from a year ago when I had a problem with Predbat doing a forced export at 3pm every day, I used to just do a forced demand:

alias: "Predbat: stop 3pm discharge"
description: ""
mode: single
triggers:
  - at: "23:00:00"
    trigger: time
actions:
  - data:
      option: "15:00:00"
    target:
      entity_id:
        - select.predbat_manual_demand
    action: select.select_option
  - delay:
      minutes: 1
  - data:
      option: "15:30:00"
    target:
      entity_id: select.predbat_manual_demand
    action: select.select_option

Just adapt this to whatever commands you want to occur at certain times. You could get more sophisticated with logic to set export based on SoC if you wanted.

I ran this at 11pm so the plan was setup correctly for the next day. There’s a short delay between commands so Predbat operates on each one. If you hammer multiple commands in without delays then it can miss them

T
#1195 TX200

geoffreycoan cheers

Created myself an on/off helper toggle.

At 3pm an automation fires unless the toggle is off.

Then I've updated the saving session joiner to set the Export4pm toggle to off - thus it won't override any PredBat saving session activities.

G
#1196 geoffreycoan

TX200 sounds good. These little automations grow arms and legs before you know it !

T
#1197 TX200

geoffreycoan yeah and now I've had to update it. No sun today.

So it won't add the 4pm export if the SoC at 3pm is under 90% OR if the toggle is off.

The toggle gets reset to on at 7pm as part of an end of peak time routine.

R
#1198 Rbor

I have set up a new discussion:
Setting up your EV Charger for the first time with HA and Predbat
https://community.givenergy.cloud/d/5812-setting-up-your-ev-charger-for-the-first-time-with-ha-and-predbat

A lot of recent posts are requesting help in setting up and automating an EV charger using HA and predbat.
This topic has many nuances with different charger, different cars, different tariffs, etc ..........

Please using this new topic for queries related to Car charging with HA and predbat.
This will allow all of us to focus of this topic.

Hope to see you over there!

Rob

#1199 PianSom

I have a guest coming next week, who has an EV. I'd like to let them use my zappi during the day, but I'd prefer them not to drain the battery though I don't mind if they use any solar generation. Say they want to charge for an hour or two.

This isn't something I've had to do before, so just wanted to check: I would set a Manual Force Charge Freeze for the period they are plugged in - correct?

G
#1200 geoffreycoan

PianSom Manual Force Charge Freeze

correct

charge freeze allows the batteries to Charge whilst Freezing the SoC at the current level (i.e. prevents discharge)

https://springfall2008.github.io/batpred/what-does-predbat-do/#predbat-modes

if you are doing a freeze charge then any house load will have to be met from solar or else you will grid import (as the battery is not discharging)

And you'd probably need to change the Zappi configuration (export margin?) to allow it to charge from excess solar, and vary the charge depending on how much solar there is as again you could get grid import

T
#1201 TX200

Not entirely sure what PredBat was up to this morning.

It started to do a four hour timed charge at 8am (at flux daytime rate), then ten minutes later it changed its mind and went to freeze instead.

Wonder if it got confused, thinking it was night time. 🤣

D
#1202 Daveb01

Hi all, I am having an issue with my power graph, it’s been working for over a year. Grid power is showing correctly but the graph red line remains at zero?


G
#1203 geoffreycoan

Daveb01 I was thinking about this, and as I suspected, the cause of the problem is staring at you if you look carefully.

The unit of measure of the Grid sensor is kW whereas all the other entities are in W so in the Apex chart when a grid import of 5.5 gets laid on a scale that goes from 0 to 6000, it appears as if it is zero.

You need all the entities with the same unit of measure, or use a transform function in the Apex chart to multiply the kW value by 1000.

Personally I have standardised all my sensors into kW just because I think its easier to read, but personal choice

🐇

D
#1204 Daveb01

geoffreycoan

Thank you, i had a look and
I have changed it back to W - no difference
I have changed them all to kW - no difference

So I don’t think it is that, I checked the sensor as well when changing and get the correct reading. I have not changed the Apex Card.

I found a post 21 days ago and it was ok then, so I think I have to look at what’s changed on my system to cause this. Which is what I have been doing 🥴



G
#1205 geoffreycoan

Daveb01 Thank you, i had a look and
I have changed it back to W - no difference
I have changed them all to kW - no difference

I think you’ll need to leave the grid sensor on W (or change all the others to kW) and then leave it a day

The graph is showing power over time so if the sensor was recording 3 (as in 3kW) yesterday and the others were recording 3000W then when you change the UoM then the prior state history doesn’t get rewritten (i.e. multiplied by 1000).
Might want to check the statistics and what uom the sensor is being written in. The UoM you change in HA shouldn’t change the statistics as they are written in whatever the sensor was first setup as, but if the source has changed its uom then statistics may stop being collected die to the discrepancy and you’ll have a ‘fix’ to apply.

I’m pretty confident this is the source of your issue, I’ve seen it on other Apex charts

D
#1206 Daveb01

[unknown]

So have taken your advice and spent the last hour, changing everything in HA to kW/kWh with two decimal points. I know have to leave it a day to see what happens.

Will the scaling up the left also change automatically from w to kW?

T
#1207 TX200

TX200

Well it looks like I've managed to bring my baseline down a bit, with those 4pm exports.

Not sure how accurate the data is now though - as there's been a number of saving sessions that octopus were rejected from. Not entirely sure if those days are skipped from the baseline calculation or not.

#1208 PianSom

Daveb01 Will the scaling up the left also change automatically from w to kW?

The HA scaling will change automatically, but you will need to edit the yaml on the y axis field of the Power Graph chart you posted above in black. (I would suggest using min: ~-6 and max: ~6. And maybe try a tick_amount: 6)

D
#1209 Daveb01

PianSom

So looks like mine was set at 12 and 12, I have now duplicated the chart and will change the bottom one and leave the top one alone just incase. I have changed the bottom on to 6 and 6.

So the chart has now stopped when I changed everything to kWh as expected. However the Solar forcast chart has now stopped and it only works when I change it back to w? Any ideas on this one as well (if I change anything I have to look at things as all sorts of things are stopping)


G
#1210 geoffreycoan

Daveb01 Its the same as I explained before.

These graphs work by plotting sensor history over time, in the case of the power chart its the previous 24 hour period, in the case of the solar chart its showing today’s data.

If you change the unit of measurement of a sensor from kW to W or vice versa then the sensor history will start recording the new values with the new UoM. So values that were previously been stored as 3 (with a unit of kW) will now be stored as 3000 (unit of W) and vice versa.

If you change the UoM then previous history does not get re-written. So in the solar forecast chart I’m guessing the chart was expecting the values to be in Watts and in the chart coding there was a transform to multiply the watts value by 0.001 so that it lined up with the solar sensors that are in kW.

I’ll say it again, change the unit of measures to whatever you want, make them all consistent, and then leave it for a day for the new data to replace the old on the chart. If need be you can then add transforms to scale sensors but if you have everything in the same UoM you shouldn’t need to

D
#1211 Daveb01

geoffreycoan

Hi yah, I have just taken the dog out for a walk and thought about what I had said. I had forgot to add that comment would the Solar forcast display the same and need some time to sort. I was going to edit my reply but you had already replied, so sorry again for the misunderstanding and to be patient 🥴👍

G
#1212 geoffreycoan

Daveb01 I was getting less patient if you hadn't noticed ....

I've seen this issue before on the solar forecast chart. On the to-do list to add something to the documentation about spotting and fixing it

R
#1213 Rbor

geoffreycoan Could the issue be units for Solar power.

The GE power entity uses kWh.
The SE power entity uses W (and this is what you use).

BUT Solar edge has 2 integrations and they use different power units (what a mess)!

  • The "SolarEdge modbus" integration uses W in: sensor.solaredge_modbus_ac_power
  • The "SolarEdge" integration uses kW in: sensor.solaredge_current_power

I found that only the energy dashboard allowed the modbus energy entity only!!
I had to get into the SE inverter using its Local IP (I got the method from Speak to the Geek) and I changed an inverter setting to gain access to the Modbus entities.

I want to use the SE modbus entity in my energy dashboard.
If I link to my GE entity and SE modbus entity, my solar data is duplicated.
If I remove my GE entity, I lose all historical solar stats. I am hopeful that @geoffreycoan will provide a solution for moving my GE data to SE!!

Also, as @geoffreycoan has suggested, it is time for using transform in the apex chart yaml?
Or change the unit from kWh to W.
I remember answering a query on this area ages ago and the issue was using kWh and W together.

Apologies if my account sounds confusing......

Rob

D
#1214 Daveb01

Rbor

Hi yah, my new project was to get things working as I see them in the apps or bills, and get them either spot on or as close as possible. I have done the easy ones first, SolarEdge.
I also followed Geoffrey’s advice on setting up the Cost sensors.

  1. I had a look at the app and saw the things I wanted to display. I then installed the SolarEdge entity as I already had the modbus version. I have now got them all working and in my Home card.

  2. Next was the Gas meter. I have got the correct reading for the day and did the Helpers for Utility Meter Month and Year, I have just got to wait to see if the a month one works, then I will be confident I have got is sorted. The year one is a nice to have but not sure it will be correct yet.

  3. Electric Import (same as 2 above)

  4. Electric Export (same as 2 above)

  5. Change all the w to kW/kWh (same as Geoffrey)

G
#1215 geoffreycoan

Rbor If I remove my GE entity, I lose all historical solar stats. I am hopeful that @geoffreycoan will provide a solution for moving my GE data to SE!!

Moving history masterclass is coming. I have moved history between a number of my entities in HA, resolved glitches and spikes in the Energy dashboard, filled in gaps in data when HA or GivTCP stopped working a few times. I've simplified (removed) the multi-tariff export entity I had from my early days of HA, loading all of the historical Export billing from Octopus.
This week I have been developing a new procedure and then bulk loading HA with all the historical GivEnergy data that was in the Portal from before I started using HA.

Here's a part-way through view of the energy dashboard, historical export, solar/charge/discharge for one inverter loaded, but still to do import and the second inverter. You can see when I started with HA on 23/10 (actually I started about a month before but the database corrupted itself and so this was my restart date):

Will be published soon and you'll all be able to dive down a new rabbit hole of data manipulation.

D
#1216 Daveb01

geoffreycoan

Will you do a Rabbitclass as well if I am not good enough to do the Masterclass? 🍺🍺

D
#1217 Daveb01

geoffreycoan

Have you got the power flow + card as well? You can add things and name them, so instead of Gas you can name it ASHP?

It’s a sham ASHP is not in the Energy card yet?

G
#1218 geoffreycoan

Daveb01 Have you got the power flow + card as well? You can add things and name them, so instead of Gas you can name it ASHP?

It’s a sham ASHP is not in the Energy card yet?

I use the power flow card (in fact two cards) to show my instantaneous power flow for each meter.

But in the energy dashboard I have the ASHP as a specific device (along with my other Shelly and Tasmota monitored devices), but to get an overview of the ASHP day by day and hour by hour I have configured it as a ‘gas’ element so I can easily see graphs of ASHP over time. Unfortunately can’t rename the Gas element. Maybe a future HA enhancement

A
#1219 arczi19

Could someone sanity check my understanding of battery_temperature_charge_curve option please? My battery 9.5kWh is back on 3017 firmware, which means when its on 20 Celsius or under its charging at 2.7kWh, does that mean I should set the values20, 19, 18, 17, etc at roughly 0.29? I got this number by dividing 2.7 by 9.5 and rounding up.

D
#1220 Daveb01

geoffreycoan

Morning, all sorted. There were a few things, be patient and wait 24 hrs. I had to change Align to, mine was set to 500, changed it to 1. I also took advice from @PianSom and changed Min/Max/Tick count to 6. I will monitor these and see if they need changing to 7 or 8.



R
#1221 Rbor

I have just posted this as a separate discussion.
https://community.givenergy.cloud/d/5824-the-national-grid-interactive-map
I am also posting here as the post has attracted a lot of interest.

The national grid
This is a link to an interactive map showing the national grid, both present and planned: https://openinframap.org/#6.5/54.747/-3.25

I find this fascinating. You can zoom in to pick out any area in detail, right down to individual houses. The map shows sub-stations, every wind turbine and solar farm.
And you can zoom out to see the whole country with interconnects with Europe and beyond.

Here's a snapshot but you can zoom in and out at your own leisure.

Rob

G
#1223 geoffreycoan

arczi19 My battery 9.5kWh is back on 3017 firmware, which means when its on 20 Celsius or under its charging at 2.7kWh, does that mean I should set the values20, 19, 18, 17, etc at roughly 0.29? I got this number by dividing 2.7 by 9.5 and rounding up.

Yes correct.

The published table that Hoggy shared from Facebook (was I believe originally from GivEnergy) had 0.33 for Gen 2+ inverters on BMS 3017 which would give 3.16kWh, but if you are getting 2.7 then I'd set the curve to what you are actually seeing on the inverter

D
#1224 Daveb01

Hi all, as above, I have been looking at the Apex power and Solar forcast charts. I have changed everything from w to kW/kWh. After waiting 24 hrs I have got them back to how they should be phew.

These questions are about the y axis numbering.

Q1 - does everyone see the numbers changing depending on the readings?
Q2 - I would like the numbering to be 1-2-3-4-5-6 etc (has anyone managed to get this?)
Q3 - I have set min 6, max 6, tick amount 6 When I change these I can get different numbers but not 1-2-3-4-5-6 etc.
Q4 - when I change the number the chart reloads and I can see 1-2-3-4-5-6 (for a second or two) once it has loaded the numbers go back to random ones.

So the main question is - is it possible to get 1-2-3-4-5-6?



#1225 PianSom

Daveb01
EDIT - bloody forum. In the below read TW as the ~ character

It's probably with you looking up the Apex chart manual, but in short -

You have specified y axis min/max as TW6/TW-6 at my suggestion. What the TW means in this context is "use 6, but if the data is bigger than 6 then use a number a bit bigger than that instead". Looking at your chart now - and assuming that these values are a normal day, then you could try TW7/TW-12. (Personally I prefer symmetric axes, so I would use TW12/TW-12)

IIRC "tickAmount" means "show this number of points on the y axis (not counting the 0, or the middle one if that's not 0)". So what it should be depends on what axes values you have, and what actually get displayed if you have used TW. If all your data fitted in to the +6/-6 range (which it doesn't now!) then 12 would work. As you can see from your bottom chart where you have used +12/-12 you just get the even numbers with a tickAmount of 6. If you increased this to 12 then you should see all the numbers (if they fit in, I guess).

D
#1226 Daveb01

[unknown]

Wow your so cleaver, I think you should be promoted from Rabbit as that’s what I am and your much better then me. So it was 12-12-24 that sorted it.


#1227 PianSom

Daveb01
If I was clever I'd have told you to use 24, not 12!

Misread the top (not bottom!) chart as showing even nos, rather than every 4. Doh.

D
#1228 Daveb01

PianSom

So last one for the day, I have tried a few numbers and none work (this is the Solar forcast charts)

There are 2 tick amounts in the top one



#1229 PianSom

Daveb01
I'm not entirely sure sure I know what your question is ...

All three charts show kW axes (the top one has another "Capacity" axis for some reason; it is not used). The top two ask for 10 tick marks and get 10. The bottom one asks for 5 and gets 5.

In no case is a max value specified, so if you wanted integer values on the ticks then you'd have to do that and then set the tickAmount to the same value.

D
#1230 Daveb01

PianSom

Thank you so much, adding Max: sorted it 👍🍺

G
#1231 geoffreycoan

Daveb01 Worth being aware that there are bugs with the latest version of Apex charts, you should be able to auto-scale the Y axis, but this doesn’t work https://github.com/RomRider/apexcharts-card/issues/773

Rather looks as if the author has stopped developing Apex charts for HA as there are a lot of outstanding issues, mostly with no responses.

It is worth reading the readme which explains how most things work https://github.com/RomRider/apexcharts-card and the Apex documentation, especially for setting Options (of which there are lots, not documented in the HA github) https://apexcharts.com/docs/installation/#

T
#1232 TX200

Try Plotly as an alternative?

Here's one I did earlier

G
#1233 geoffreycoan

TX200 Try Plotly as an alternative?

Yeah I did consider that but Apex works OK 99% of the time and I don't want to face the idea of having to change all my charts from Apex to Plotly. I'd want to simplify my HA by standardising on one rather than just make it even more bloated!

D
#1234 Daveb01

Checked the charts first thing this morning after all the changes and all good. I did notice I am now starting to get Solar at 06:20, it’s only going to get better 👍😎

R
#1235 Rbor

In one of Trefor's recent updates to predbat, v8.16.1, the default for Best SOC Keep was changed to 0.0:
Entity:input_number.predbat_best_soc_keep

I had mine set to 0.8, possibly in response to a comment/advice in a post
Can anyone tell me what this entity does?

This is from documentation:
predbat.soc_kw_best - Predicted final state of charge (in kWh) with attributes of the predicted SoC in 5-minute time slots to the end of the best plan, for charting

Thanks

Rob

T
#1236 TX200

[unknown] I think it's the lowest the plan will let the battery get to.

One of them is a strict limit the other is a bit more bendable, e.g. PredBat may go under that limit sometimes.

D
#1237 Daveb01

Hi all, I have been playing with the HA dashboard and cards.

Has anyone set up Gauges? Are they any use really as I can see a lot of stuff in the flow charts. Any recommendations?

Second question, when I set up HA it asked you to set up an account and login. Is there a way to change the user name please?

#1238 PianSom

Daveb01 Second question, when I set up HA it asked you to set up an account and login. Is there a way to change the user name please?

Settings / People

G
#1239 geoffreycoan

Rbor This is from documentation:
predbat.soc_kw_best - Predicted final state of charge (in kWh) with attributes of the predicted SoC in 5-minute time slots to the end of the best plan, for charting

this is the output entity which is the SoC prediction for the predbat (best) plan

the question was about input_number.predbat_best_soc_keep - this is as TX200 says, a lowest SoC level that Predbat will manage your battery to. There are two different entities, best_soc_min which is the minimum level Predbat will always retain in the battery, so if your battery drops below this, predbat will charge the battery regardless of rate - this is best used for EPS buffer but does mean that you are not using your entire battery capacity.

best_soc_keep is an advisory minimum level of SoC to keep in the battery. There is a weighting parameter as well as to what weight Predbat applies to the min SoC level, but Predbat doesn’t keep this as a hard limit, the SoC can drop below it.
Setting the default to 0.0 just means predbat will let you use all the battery range and not keep anything back ‘just in case’. I have mine set to 0.0

Daveb01 I don’t use gauges, I think they take up a lot of room but some people like them for solar tracking, soc, etc.

I use bar graphs for power consumption which is similar:

D
#1241 Daveb01

geoffreycoan

This is what we have discussed at some point and I set it. (Pic 1)
As I want to keep some battery for EPS I have these set (pic 2)

Are these settings still correct? Don’t think I have had them at 0


G
#1242 geoffreycoan

Daveb01 with your decent battery storage the settings look fine and makes sense to keep some back for EPS, you could increase the weight if predbat isn’t keeping it for you. best_soc_min has disadvantages as I mentioned

I got part way through setting up a sankey chart ages ago but never finished it as it required manual config of the hierarchy of devices, the auto config struggled for me.
Where the sankey would be good is removing duplication and showing unknown consumption better, eg extension tracks the extension consumption but then I have several devices individually tracked so nice to see the breakdown.

WHat I like about bar graphs is its easy to see how much solar and what the batteries are doing

L
#1243 LewisWatt

Another post for the Predbat Tech Support thread.

'switch.predbat_set_charge_low_power' is OFF, and always has been on this setup. I've noticed that my plan for the next 48hrs doesn't force any exports at the end of the day, but rather tops up to a reasonably high percentage, but not 100%.

I don't have a screenshot of the typical response, however I'd usually see the plan force export to 4% ahead of that charge window, then do 100% > ~ 60% > 100% in the five hour gap. Car charging does limit when exporting occurs, however it'd still try that response. Additionally it'd be doing so at the max rate for the inverter (6kW), not trickle charging.

Is there an additional parameter that would cause PredBat to plan a slow charge to a specific percentage? I have played around a small amount recently, but only as off this evening have I seen this behaviour.

Trefor has been pushing a number of fixes, but even rolling back to 15.1 doesn't change the plan from below;

Cheers

G
#1244 geoffreycoan

LewisWatt Trefor has been fiddling with the predbat calculations as you say, but if you have reverted back then its not likely to be that.

At a guess your plan is being affected by carbon, do you have switch.predbat_carbon_enable on and a carbon threshold set?

L
#1245 LewisWatt

geoffreycoan Whilst I do have the carbon metric enabled, it's purely decorative for my planning. I did check if disabling it would fix the issue incase the 0p/kW wasn't being read correctly, but there was no change in planning.

What's quite interesting is that it's now happy to export to 46%, but no more.

G
#1246 geoffreycoan

LewisWatt strange

I'm assuming you don't have any of the more 'exotic' plan optimisations like full second pass or tweak second pass turned on.

Is calculate export slots on high import rate slots first on or off, and also calculate import slots on low export rate slots first on or off? (mine are off and on respectively)

Have you tried putting in a force export and force charge to see if that kicks the plan correctly?

L
#1247 LewisWatt

[unknown] Strange indeed, and it really doesn't explain the slow charge rate I'm seeing either.

I did actually have those 'exotic' options enabled, however disabling them did nothing. Also tried your export slot configs with little to no effect on charge rate or charge/discharge slots.

I'll see how it performs tomorrow morning, as it wouldn't be the first time that Predbat has changed it's mind at the initial charge/discharge point, but if I had to guess this might be something on the backend misbehaving as there's no real reason why this slow charging is present.

Thanks Geoffrey

L
#1248 LewisWatt

As expected, looking back at the behaviour of the system, it charged at full rate. Once it hit 100%, it rubberbanded around 90%<>100% until the window was over.

I tried disabling the battery temp curve incase that was messing with it, however it had zero effect. Might need to create a Github ticket at this rate. Just don't want to waste anyone's time if it's something trivial.

J
#1249 Josephiah

Does anyone have a recommended way of automating limiting of grid charging on a sunny morning, to avoid clipping? I'm on Cosy, and have been a little surprised to see Predbat merrily charging to 100% in the mornings even on forecast clear days.
I was hoping that best_soc_max would do the trick, but this seems to also prevent solar charging, i.e. it goes to something close to the target value and freezes there, rather than continuing to allow charging from solar.
What are your methods of achieving this? Setting lots of manual freezes seems a little on the coarse/brute force side...
Thanks,
Jo

J
#1250 Josephiah

Ah, just spotted this thread - will maybe see what I can do with that.

G
#1251 geoffreycoan

[unknown] I have the same issue, because my Cosy import rate is 13.23p (effectively 14.58p after losses), its marginally more profitable for Predbat to charge fully in the cheap periods and then export everything.

This works fine from a cost optimisation perspective which is what Predbat does, but doesn't take account of solar clipping.

There is a long running github thread on this https://github.com/springfall2008/batpred/issues/1206 which looks like you've found.

My solution last year was to put predbat in read only mode and then manually manage the givtcp battery pause mode and battery charge rate entities to allow the battery to trickle charge during the day. This year I have just started trying to use the predbat manual API (setting inverter_limit_charge) see if I can manage things within Predbat instead.

Have found one new predbat bug with setting inverter_limit_charge but early indications are that this will work. I'll post my automation code when I've tested it more today

G
#1252 geoffreycoan

Josephiah I have the same issue, because my Cosy import rate is 13.23p (effectively 14.58p after losses), its marginally more profitable for Predbat to charge fully in the cheap periods and then export everything.

This works fine from a cost optimisation perspective which is what Predbat does, but doesn't take account of solar clipping.

There is a long running github thread on this https://github.com/springfall2008/batpred/issues/1206 which looks like you've found.

My solution last year was to put predbat in read only mode and then manually manage the givtcp battery pause mode and battery charge rate entities to allow the battery to trickle charge during the day. This year I have just started trying to use the predbat manual API (setting inverter_limit_charge) see if I can manage things within Predbat instead.

Have found one new predbat bug with setting inverter_limit_charge but early indications are that this will work. I'll post my automation code when I've tested it more today

J
#1253 Josephiah

geoffreycoan
Thanks. I've just been trying with a variant of your method here (same method, just with a different trigger, and two sequential output actions). However, it only seems to partially work, setting only the first slot specified.

So the following is supposed to check solcast at the chosen time, then if the day's forecast is above my chosen threshold, it should freeze charging from 4-5.30 and set to demand from 5.30-7. However, this results in only the first slot in each list (4:00 and 5:30 respectively) being set; the following times listed are ignored.

I built this one up using the automation UI, but the resulting code looks equivalent to your automation as far as I can see... Any suggestions? (I can always brute force it slot by slot as a workaround, but that feels a little inelegant!)

alias: Skip morning Cosy charge
  description: ''
  triggers:
  - trigger: time
    at: 03:45:00
  conditions:
  - condition: numeric_state
    entity_id: sensor.solcast_pv_forecast_forecast_today
    attribute: c606-da06-16f6-1990
    above: 15
  actions:
  - action: select.select_option
    metadata: {}
    data:
      option: 04:00:00,04:30:00,05:00:00
    target:
      entity_id: select.predbat_manual_freeze_charge
  - action: select.select_option
    metadata: {}
    data:
      option: 05:30:00,06:00:00,06:30:00
    target:
      entity_id: select.predbat_manual_demand
  mode: single

EDIT: Also, trying to programme something like this on the day before the clocks go forward is not conducive to debugging! Maybe I'll come back to this...

EDIT 2: Workaround of just sequentially adding an action block per slot works fine for me:

  actions:
  - action: select.select_option
    metadata: {}
    data:
      option: 04:00:00
    target:
      entity_id: select.predbat_manual_freeze_charge
  - action: select.select_option
    metadata: {}
    data:
      option: 04:30:00
    target:
      entity_id: select.predbat_manual_freeze_charge
  - action: select.select_option
    metadata: {}
    data:
      option: 05:00:00
    target:
      entity_id: select.predbat_manual_freeze_charge
G
#1254 geoffreycoan

Josephiah I have something very similar that I wrote last night to bulk set freeze discharges across the whole of the 4am cosy charge period:

only difference is that I have the entity id underneath as a single line list and I deleted the metadata line as its not needed

curiously the editor highlights the last two 00 in orange as if it doesn't think this is part of the option being set

that's what I ran last night and it worked fine.

The automation for tonight is:

      - conditions:
          - condition: trigger
            id:
              - sunset-stop-cross-charging
        sequence:
          - action: script.set_predbat_inverter_limit_charge_twin_inverters
            data:
              g_charge_rate: 700
              h_charge_rate: 0
          - action: select.select_option
            target:
              entity_id:
                - select.predbat_manual_demand
            data:
              option: >-
                00:00:00,00:30:00,01:00:00,01:30:00,02:00:00,02:30:00,03:00:00,03:30:00
          - action: select.select_option
            target:
              entity_id:
                - select.predbat_manual_freeze_export
            data:
              option: 04:00:00,04:30:00,05:00:00,05:30:00,06:00:00,06:30:00

I had to put it in demand mode from midnight to stop predbat holding the charge unnecessarily.

I haven't put any condition in to check the pv forecast but was planning on doing the same

B
#1255 browellm

Anyone on Agile import and Fixed Outgoing had a hell of a day yesterday according to Predbat Compare 😃

G
#1256 geoffreycoan

browellm I had my battery charge rate ramped right down to only do a bit of overnight trickle charging so didn't see as much benefit as others, but yes, super-cheap rates last night

The Agile forecast is for rates back in the 18-21p overnight range from tonight so I'm not changing yet. Looking back I was paying around 10p/kWh on Agile this time last year

J
#1257 Josephiah

geoffreycoan I have the same issue, because my Cosy import rate is 13.23p (effectively 14.58p after losses), its marginally more profitable for Predbat to charge fully in the cheap periods and then export everything.

My experiments so far have yielded some pretty odd results - my forced freezes/demand to override the early morning Cosy slot charge seemed to work fine, but it then resulted in some strange (to my eyes anyway) behaviour in the plan over the course of the late morning/early afternoon - lots of "freeze export" instead of demand. But thinking about it some more, I think it's probably the same phenomenon as you're describing above - Predbat views it as mildly beneficial to always charge and then export due to the pricing.

So, is there any way to tweak the pricing? I'm guessing the loss figures and metric_battery_cycle_cost don't help us here, as they will apply to battery cycles regardless of whether the source is grid or PV...? Or am I missing something with those?

#1258 Hook

Predbat seems to want to go back to exporting during peak periods again which I used to switch off using:

"Calculate secondary order slots"

This doesn't seem to exist anymore, but I'd like to get it to export at the end of the day. Any ideas?

G
#1259 geoffreycoan

Josephiah lots of "freeze export" instead of demand. But thinking about it some more, I think it's probably the same phenomenon as you're describing above - Predbat views it as mildly beneficial to always charge and then export due to the pricing.

correct, at the rates at the moment its about 1/2p beneficial to charge the batteries on Cosy and export less. With the new Cosy rates from tomorrow I expect the behaviour will change.

I had the same issue with Predbat wanting to freeze export during the day, so I turned freeze export off, there’s a switch for that: switch.predbat_set_export_freeze

Hook I'd like to get it to export at the end of the day. Any ideas?

By default Predbat should do this if the rates make it favourable to do so. Check switch.predbat_calculate_export_high_import is off and switch.predbat_calculate_import_low_export is on

Have to say this is one of the less well explained bits of new features!

S
#1260 SteveCook

just installed update and it has killed everything predbat related
i have installed full HAA backups but no joy
i have uninstalled predbat and reinstalled but no joy.
in the pedbat logs it starts and then fails and goes to sleep for 20 seconds.

AttributeError: 'HAInterface' object has no attribute 'api_errors'
2025-03-31 19:23:04.173567: Error: set_state_wrapper - No HA interface available
2025-03-31 19:23:04.173698: Info: record_status Error: Exception raised 'HAInterface' object has no attribute 'api_errors'
Error: Failed to initialize predbat 'HAInterface' object has no attribute 'api_errors'
Traceback (most recent call last):
File "/usr/local/lib/python3.10/dist-packages/requests/models.py", line 974, in json
return complexjson.loads(self.text, **kwargs)
File "/usr/lib/python3.10/json/init.py", line 346, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3.10/json/decoder.py", line 340, in decode
raise JSONDecodeError("Extra data", s, end)
json.decoder.JSONDecodeError: Extra data: line 1 column 5 (char 4)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/config/ha.py", line 539, in api_call
data = response.json()
File "/usr/local/lib/python3.10/dist-packages/requests/models.py", line 978, in json
raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
requests.exceptions.JSONDecodeError: Extra data: line 1 column 5 (char 4)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/config/hass.py", line 49, in main
p_han.initialize()
File "/config/predbat.py", line 932, in initialize
raise e
File "/config/predbat.py", line 884, in initialize
self.ha_interface = HAInterface(self)
File "/config/ha.py", line 87, in init
check = self.api_call("/api/")
File "/config/ha.py", line 543, in api_call
self.api_errors += 1
AttributeError: 'HAInterface' object has no attribute 'api_errors'
2025-03-31 19:23:04.175019: Stopping Predbat
Shutdown, sleeping 20 seconds before restarting

G
#1261 geoffreycoan

@[deleted] has just reported what I was just about to post to warn everyone of

There appears to be a bug in HA Supervisor 2025.03.4 that kills Predbat.

In the Predbat it checks it can talk to Home Assistant (making a proxy call via the HA supervisor), and the supervisor is reporting a server error 500 which kills predbat.

Further details on this github issue: https://github.com/springfall2008/batpred/issues/2171

I have tried to fix it with a new version of ha.py https://drive.google.com/file/d/10bd2zR1EpperUBUyh3ANrb2K5qQ_96Z6/view?usp=drive_link but this does not work (it does however supress some other errors you can get)

The workaround is to define ha_url and ha_key in apps.yaml, see https://springfall2008.github.io/batpred/apps-yaml/#home-assistant-connection

D
#1262 Daveb01

geoffreycoan

should I do the lottery this week. I updated HA plus Predbat, no issues so far 🤞

T
#1263 TX200

I appear to be on supervisor 2025.03.04

Not noticing any issues with PredBat so far. Some errors re sockets being closed but only around the time of a PredBat update.

I'm on OS 14.2 - wonder if it's a v15 issue?

Or am I just so far lucky and it might hit me soon... 🤞

#1264 Hook

FFS, I wondered what was going on. Carnage!

I uninstalled it to reinstall and it won't reinstall predbat addon from the repository:

"Failed to install add-on
The command '/bin/bash -o pipefail -c apk add --no-cache --virtual .build-dependencies build-base=0.5-r3 python3-dev=3.11.9-r0 && echo "Step1"' returned a non-zero code: 60"

G
#1265 geoffreycoan

Hook I uninstalled it to reinstall and it won't reinstall predbat addon from the repository:

it might be that you need to shutdown and restart HA completely before you can reinstall the addon?

Could be a HAOS 15.0 + supervisor 2025.03.4 issue, I only upgraded HAOS yesterday but Predbat was working fine, I'm pretty sure it only started failing when the supervisor upgrade installed and predbat next tried to start up again

M
#1266 matttheotter

[unknown] I just updated my parents install v8.17.2 and its not gone well...

[21:46:14] INFO: [32mPredbat init script running[0m
Running Predbat inside Add-on
Your API key is:  removed
Bootstrap Predbat
Startup
Predbat files are installed correctly for version v8.17.2
**** Starting Standalone Predbat ****
2025-03-31 21:46:15.526805: Loading apps.yaml
2025-03-31 21:46:15.572020: Warn: Failed to decode response <Response [500]> from http://supervisor/core/api/
2025-03-31 21:46:15.572151: Warn: Unable to connect directly to Home Assistant at http://supervisor/core, please check your configuration of ha_url/ha_key
2025-03-31 21:46:15.572215: Error: Exception raised 
2025-03-31 21:46:15.572667: Error: Traceback (most recent call last):
  File "/config/predbat.py", line 1177, in initialize
    self.ha_interface = HAInterface(self)
  File "/config/ha.py", line 92, in __init__
    raise ValueError
ValueError

2025-03-31 21:46:15.572805: Error: set_state_wrapper - No HA interface available
2025-03-31 21:46:15.572838: Info: record_status Error: Exception raised 
2025-03-31 21:46:15.572866: Error: Exception raised 
2025-03-31 21:46:15.572976: Error: Traceback (most recent call last):
  File "/config/predbat.py", line 1182, in initialize
    raise e
  File "/config/predbat.py", line 1177, in initialize
    self.ha_interface = HAInterface(self)
  File "/config/ha.py", line 92, in __init__
    raise ValueError
ValueError

2025-03-31 21:46:15.573099: Error: set_state_wrapper - No HA interface available
2025-03-31 21:46:15.573128: Info: record_status Error: Exception raised 
Error: Failed to initialize predbat 
Traceback (most recent call last):
  File "/config/hass.py", line 49, in main
    p_han.initialize()
  File "/config/predbat.py", line 1226, in initialize
    raise e
  File "/config/predbat.py", line 1182, in initialize
    raise e
  File "/config/predbat.py", line 1177, in initialize
    self.ha_interface = HAInterface(self)
  File "/config/ha.py", line 92, in __init__
    raise ValueError
ValueError
G
#1269 geoffreycoan

matttheotter yep, Trefor has changed the API call made to the HA supervisor and Predbat now works fine without having to define ha_url and ha_key in apps.yaml

Just upgrade to 8.17.3

Or change the line in ha.py from:

check = self.api_call("/api/")

to

check = self.api_call("/api/services")

I did try upgrading to HAOS 15.1 that just came out, but that didn't fix it

M
#1270 matttheotter

geoffreycoan put the LLATs into the config to get them booted, just updated to .3 and removed commented out the tokens 😃

I have been delaying upgrades for a few weeks on my parents install, hadn't noticed mine wasn't working before I did their updates.

G
#1271 geoffreycoan

matttheotter there are a couple of advantages to defining ha_key (to the LLAT) and ha_url to http://IPaddress:8123

Firstly there have been a few people reporting that after a while the HA websocket disconnects, requiring predbat to be rebooted. Creating the LLAT fixes this.

And defining the ha_url as the HA IP address means that every API call predbat makes is a bit faster as it doesn't need to do a local DNS lookup of the HA supervisor first

But both approaches now work

R
#1272 Rbor

geoffreycoan At the risk of sounding stupid, just for a change,
What does LLAT stand for?

Thanks

Rob

#1274 Hook

[unknown]

No joy.

I hung on valiantly to appdaemon-predbat as it worked perfectly. Looks like I'll have to get around to upgrading to predbat.

T
#1275 TX200

Well, this is where I say bye to PredBat for a while.

Just successfully on boarded to IOF again

Tariff switch requested, waiting for that to complete.

PredBat is in monitor mode/read only for now. Guess it makes sense to leave it installer ready for next autumn!

S
#1276 SteveCook

[unknown]
Tried that, but the config screen for predbat just says "dummy" so I no longer see the menu that I used to be able to play with.
The predbat UI where I used to get to yaml will not run.
Where/which app.yaml do I edit using file editor to fix this.
Thanks all for trying to help a dimwit like me

S
#1277 SteveCook

matttheotter
Tried that, but the config screen for predbat just says "dummy" so I no longer see the menu that I used to be able to play with.
The predbat UI where I used to get to yaml will not run.
Where/which app.yaml do I edit using file editor to fix this.
Thanks all for trying to help a dimwit like me

S
#1278 SteveCook

i am in file editor and I think in the right place?
I have done a text search for key and there are 3 entries,
I cannot find ha_key in apps.yaml

FFS when wil someone fix this forum so images post without having to try 10 times

M
#1279 ma9mwah

mines just under the threads section:

  # If you are using Predbat outside of HA then set the HA URL and Key (long lived access token here)
  ha_url: 'http://homeassistant.local:8123'
  ha_key: '********'
S
#1280 SteveCook

well
i uninstalled predbat
Restarted HA
Went and found predbat addon and installed it
Followed Trefors youtube guide

Still no joy. the logs shows it runs for 20 seconds and then stops

S
#1281 SteveCook

ma9mwah
Thanks, I used the recommended add-on in Home Assistant

S
#1282 SteveCook

Generated and pasted the key in and restarted predbat.
in the logs it keeps restarting and then stopping.
The error that keeps appearing seems to be

AttributeError: 'HAInterface' object has no attribute 'api_errors'
2025-04-01 10:26:21.424733: Stopping Predbat
Shutdown, sleeping 20 seconds before restarting

I have tried to go to config at the add-on but all i get is Dummy in the options. It will not run the UI

G
#1283 geoffreycoan

SteveCook Went and found predbat addon and installed it
Followed Trefors youtube guide

Still no joy. the logs shows it runs for 20 seconds and then stops

the predbat addon will probably come with an older version of predbat, you need to upgrade to the latest version 8.17.3 - Home Assistant should prompt you or you can use the select.predbat_update control to manually force an upgrade (but if predbat is not running this may not work ….?)

If you don’t get prompted with an update there is one line to change in ha.py as described above which will fix the issue. Use file editor to navigate to /addon_configs/6abxxxx_predbat and open ha.py. Search for ‘check’ and change the line as above

G
#1284 geoffreycoan

SteveCook I have tried to go to config at the add-on but all i get is Dummy in the options. It will not run the UI

that configuration screen is just a dummy, it doesn’t do anything, and never has. You need to use the ‘web console’ option on the addon to open the predbat web interface but since the addon is failing to start I doubt you can do.

Follow my instructions above to edit ha.py and it should then start ok

S
#1285 SteveCook

[unknown]
Geoffrey. Thanks. sorry to be stoopid. I am in /addon_configs/6abxxxx_predbat.
done the search for check.
what do i change to what.
Ta

S
#1286 SteveCook

geoffreycoan
Geoffrey. Thanks. sorry to be stoopid. I am in /addon_configs/6abxxxx_predbat.
done the search for check.
what do i change to what.
Ta

This
Or change the line in ha.py from:

check = self.api_call("/api/")

to

check = self.api_call("/api/services")

I did try upgrading to HAOS 15.1 that just came out, but that didn't fix it

S
#1287 SteveCook

Eureka.
It has now suggetsted an update to predbat v8.17.3

G
#1288 geoffreycoan

SteveCook sounds like you are there now

you are in the right folder

open the file ha.py and edit the line ‘check = self.api_call(“/api/“)’ and to /api/services and predbat should start for you

or if HA is suggesting to update to 8.17.3 then take that upgrade, it does the same thing as my manual fix above

S
#1289 SteveCook

all working. Geoffrey thankyou very much. xxx

D
#1290 Daveb01

So I have looking and This is why I was not affected, I have it commented out, as I don’t use Predbat outside HA

G
#1291 geoffreycoan

Daveb01 So I have looking and This is why I was not affected, I have it commented out, as I don’t use Predbat outside HA

You would be affected Dave once your supervisor is auto-upgraded and the next time predbat starts, it will crash if you are not on 8.17.3. The workaround to stop the crash (if you don't upgrade) is to set ha_url and ha_key

J
#1292 Josephiah

geoffreycoan correct, at the rates at the moment its about 1/2p beneficial to charge the batteries on Cosy and export less. With the new Cosy rates from tomorrow I expect the behaviour will change.

Came on here to say exactly this. Plan today is radically different, and pretty close to what I would programme myself, and pretty sure it's that subtle shift in the price balance that has caused it. Gotta love a chaotic system!

B
#1293 browellm

Using the apps.yaml checker I have been able to comment out some un-needed entries (second inverter) and typos (replaced numberwith sensorin pv_load) so that I only have one error, which I think is unavoidable due to the way the v2 Hypervolt charger reports total energy

⚠car_charging_energy sensor.hypervolt_session_energy_total_increasing = unknown

S
#1294 SteveCook

browellm
I only have one inverter, but should I edit these references to inverter tcp2 in the yaml file out?
The yaml says number of inverters 1
I still get errors about inverter 2

D
#1295 Daveb01

SteveCook

That would be my advice as I was advised to do this as well.

#1296 Hook

Anyone have an idea what this means?

S
#1297 SteveCook

Daveb01
Thanks
Done that, hit save, done 2 restarts and still get this

S
#1298 SteveCook

deleted all the lines with ref to TCP2 rather than just a # at the start of the line and restarted
Still getting the same tcp2 errors even though I cannot find any reference to tcp2 in yaml

D
#1299 Daveb01

SteveCook

So it looks like the lines are still there, maybe a spacing thing. Can you screen shot the yaml again please?

S
#1300 SteveCook

i have been to add-ons predbat and to the config tab.
The only option i see is "dummy".
I swear this used to have lots of options.
Am i doing something wrong?

D
#1301 Daveb01

[unknown]

I have deleted all the same entries to match yours, looks good my end?

G
#1302 geoffreycoan

SteveCook you are looking in the wrong place, the predbat addon (and appdaemon predecessors) have NEVER had anything in the options configuration. You are probably thinking about GivTCP which used to use the options in v2, and now with v3 uses the Web Console option.

Predbat until recently had no UI, it does now, accessible via the Web Console option on the add-on.

But you can’t edit apps.yaml from there, only see errors on it. You will need to use a file editor (details in the apps.yaml documentation) to edit it.

In the screen shot above you only show battery pause errors. If you have a gen 1 or an AC coupled inverter then your firmware may not have these options - details in the inverter setup https://springfall2008.github.io/batpred/apps-yaml/#schedule

Hook Anyone have an idea what this means?

was that a one-off error or is it happening all the time? Rather looks as if predbat is trying to report when the discharging is due to start but the sensor is empty. Might just be a givtcp glitch?

D
#1303 Daveb01

SteveCook

Same as mine

#1304 Hook

Hook I think I've sorted myself out now.

Had to reload the mqtt broker. Wasn't picking up the Giv figures.

I still have 3 errors in my apps.yaml, but I now have a plan and it's controlling my battery.

RIP appdaemon-predbat...taken too soon. What a time we had together.

S
#1305 SteveCook

geoffreycoan
Thanks

I have used file editor in yaml and searched for "pause" as the guidance link you posted above.
There is only one "pause" and it is in comments as opposed to a setting
Predbat is working but I would like to get rid of the "errors"?

G
#1306 geoffreycoan

SteveCook the errors indicate there is a battery_pause_start_time and battery_pause_end_time configure in apps.yaml. Just comment these lines out or delete them entirely

S
#1307 SteveCook

geoffreycoan
Thanks but I cannot find them even with search

SORRY. Helps to be in the correct predbat yaml file!!

Fixed. I have a this still in my system with a yaml file /homeassistant/appdaemon/apps

WORKING and errors gone.. Thanks

R
#1308 Rbor

geoffreycoan Every day is a school day …

I prefer this to LLAT.

Rob

R
#1309 Rbor

SteveCook I have one inverter and I have commented out all the givtcp2 lines.

Rob

#1310 Hook

geoffreycoan Seems like it still wants to export during prime time after making the recommended changes.


G
#1311 geoffreycoan

Hook yes in your case it would be better to hold onto the SoC until just before your cheap charging period before discharging it

see what happens with the plan execution, whether predbat actually executes this or changes its mind. There is a 4 hour window within which it does things slightly differently so you may find the export gets deferred repeatedly through the evening

otherwise then best to raise a bug on it because it should be delaying discharge until the end of the day

#1312 Hook

geoffreycoan One night it exported during peak and then as the night got cooler, my heat pump fired up and I ran out of battery.

Haven't people been asking this question for a while as to why it wants to export during prime time? Has Trefor ever mentioned why?

G
#1313 Goshiki2

Hook I moved on to Octopus Go a couple of months ago and you would think it would be a very simple tariff for Predbat to run but it still has some very strange and frustrating quirks. Overnight charging to 100%, export solar all day and then dump the remaining just before the overnight charging again.
Almost all of my settings have now been returned to default but every day it seems to plan (and sometimes carry out) a 5 minute export about 4pm. There just seems no logic to it at all.
I love that it looks at previous load, predicted PV and it automates savings sessions to maximise income but I would be more than happy with a “lite” version that didn’t have all the confusing options available.

G
#1314 geoffreycoan

Hook One night it exported during peak and then as the night got cooler, my heat pump fired up and I ran out of battery.

Haven't people been asking this question for a while as to why it wants to export during prime time? Has Trefor ever mentioned why?

@PianSom was I think running an issue with Trefor about similar problems, trying to persuade Predbat to hold onto the charge as long as possible in case there are last minute load requirements before the peak. Might be able to find the github issue and add to it?
Sometimes I don't know what it does, but mine isn't (at the moment) doing such quirks!

Do you have an export rate override in the peak period @Hook ? I have a -5p override to dissuade predbat from discharging where there might be DFS sessions, maybe that would help?
Otherwise just stick an automation in to do force demand at the same fixed time every day if its a repeatable pattern.

'Predbat lite' is an interesting idea Goshiki2. In the 18 months or so I've been using it, it has gained ever more richness in response to user feedback and Trefor's enhancements. Part of the complexity is that there is so many variables and variations for different people. You could always write an automation to instruct givtcp directly, that's what I did before I got predbat and I still use the scripts occasionally if I have predbat in read only mode

G
#1315 Goshiki2

[unknown] I have actually created an automation to force export before my charge period as it was sometimes inconsistent in the level it discharged to but I don’t really want to intervene too much if possible. Overall I love it but feel that sometimes it’s unnecessarily complicated.

#1316 PianSom

geoffreycoan
There was an issue, though I don't think it was mine. I'm happy to share my settings @Hook but I have a strong suspicion that they will be pretty bespoke to my own situation and of very little use to you.

I don't get the mid-evening discharge very often these days, and when one is it tends to get corrected before implementation.

That said, I did an EV charge last night, and Predbat decided to dump the batteries by 10.30pm when a bonus IOG slot was scheduled. It was then cancelled by Octopus and I was left importing, which was rather frustrating. But a "later discharge is better" bias would still be a Good Thing.

+1 for the concept of a basic Predbat - maybe an "easy" mode, rather like the antithesis of the "advanced" mode. Hiding even more of the options. But I wonder whether in practise it will end up being too "easy" for anyone to actually use it?

B
#1317 Boffinboy

Haven’t posted in ages as things have been blissfully stable. Noticed battery empty this AM and realised Predbat stuck on plan from last night and nothing happening. No auto restart, nothing! Unsure why that wouldn’t have happened. Virgin Media has been down on and off.

Then couldn’t get Predbat to run after a restart - issue connecting to HA - so added a key to allow that.

Then back to the irritating failure of REST that I seem to get, which I’m convinced is due to Unifi networking gear. Think I need to revert to Giv Cloud.

Predbat is wonderful but also deeply frustrating when it goes wrong and you’re unsure how to troubleshoot!

#1318 Hook

[unknown] I’m considering unifi to replace my aging netgear orbis. What’s your issue with it?

D
#1319 Daveb01

Another Predbat error, spotted just not as battery was in Idle. So installed took the change to update Predabat, then rebooted HA and apps. Back to normal.

Not sure why Predbat has a dicky fit when asking GivTCP to set 0, GivTCP has replied 0 already set. Predbat I am not listening to you I am telling you to set 0. Hhhhmmmm

S
#1320 SteveCook

v8.17.5 predbat core update is showing.
I hit the update button and nothing happens

D
#1321 Daveb01

SteveCook

I only do it in Predbat I don’t use HA update as this happens sometimes.
I have the Predbat card so just click the down arrow and choose the version I want, it then installs or you can go back.

S
#1322 SteveCook

Daveb01
Thanks. i have that with the drop down but what di I do
i have selected 17.5 and then restarted

D
#1323 Daveb01

SteveCook

It should say updating, if it has already updated it won’t do anything. If you wanted you can select 8.17.4, let it do its thing, then select 8.17.5 to check its installed. You don’t need to reboot.

S
#1324 SteveCook

Daveb01
Thanks. I used the dropdown and selected v8.17.5 and left everything all night.
Checked this morning and I am still on v8.17.4

T
#1325 TX200

SteveCook I did the same, via the drop down menu. Mine shows the right version .5

S
#1326 SteveCook

[unknown]
That's good news for you. Dont know why mine does not. I have the notifications but no joy.

D
#1328 Daveb01

SteveCook

So I would now do this (if it was me)

Settings/3 dots top right/reboot HA system (the red one)

Then try updating Predbat again

S
#1329 SteveCook

Thanks. Seems to be doing something now

Result. Updated Thankyou

W
#1330 Wavy Davy

Anyone else getting lots of "Auto-restart triggered" due to rest failure messages?
I've had 17 so far today. Not sure how to find out what's causing them.

#1332 PianSom

Wavy Davy
Have you updated GivTCP? I think I saw a similar report about the recent release ...

W
#1333 Wavy Davy

I'm on v3.1.6

W
#1334 Wavy Davy

In the mean time I've rem'd out "action: notify.mobile_app_sm_x810" to try and stop getting messages every few minuits.

W
#1335 Wavy Davy

Well that didn't work, so will look at another way of disabling notifications.

#1336 PianSom

Wavy Davy
I’m not following this closely, but I think a new version has been released to address the issue …

W
#1337 Wavy Davy

[unknown] Where are you seeing this?
Had a look on Givtcp GitHub and britkat Github and cant see it.

#1340 PianSom

Wavy Davy
Apologies, yes - 3.1.6 is the update from 3.1.5 that I was thinking about.

W
#1341 Wavy Davy

Well settled down a bit, only 3 today and 1 of those was due to a HA update. after which predbat mode said "Changed to Error: Exception raised Auto-restart triggered:. which I'm sure Geoff said was safe to ignore.

D
#1343 Dpe

Upgraded yesterday to 8.18.2. Overnight last night the 'hold for car ' setting did not seem to work, car was charging at greater than the setpoint with the battery still discharging. Anyone else seen this?

T
#1344 TX200

Anyone got warnings in their apps.yaml today?

E.g. charge_rate, battery_power, soc_max, load_today, pv_today etc

Invalid type in element sensor.givtcp_fa...kwh, expected float.

R
#1345 Rbor

TX200 No warnings with me. I am on v8.18.3

Rob

T
#1346 TX200

Rbor just restarted the PredBat add-on, warnings gone (hopefully for good!)

S
#1347 SteveCook

v8.18.4 just installed. No problems, but if I navigate HA away from Predbat and come back the screen is black until I hit refresh or reload

R
#1348 Rbor

SteveCook And now we are on v8.18.5 (I missed v8.18.4).
But the Predbat Table Card looks to be broken now!

Rob

S
#1349 SteveCook

my v8.18.5 working fine other than I have to reload the HA predbat dashboard in the sidebar I setup each time i navigate back to it.
Not the predbat one with the jigsaw Icon that can be setup in the addon config page

I dont think it is a predbat issue, though I think it started with v8.18.4. I will keep looking in HA help

W
#1350 Wavy Davy

Going back to my hassio-rest problem, still getting them, but not as often, but just noticed the message says
"Inverter 0 read bad REST data from http://homeassistant.local:6345/runAll - REST will be disabled"
that http is not my system address. which maybe explains the error.
Where is that set?

W
#1351 Wavy Davy

Going back to my hassio-rest problem, still getting them, but not as often, but just noticed the message says
"Inverter 0 read bad REST data from http://homeassistant.local:XXXX/runAll - REST will be disabled"
that http is not my system address. which maybe explains the error.
Where is that set?

Although on checking the http: it does give my battery details.

S
#1352 SteveCook

Wavy Davy
I am no expert, but from memory it is in YAML using file editor in /addon_configs/6adb4f0d_predbat/apps.yaml

W
#1353 Wavy Davy

[unknown] Thanks Steve, but no luck. Changed it to my local address, stay ill didn't work, noticed that the message in apps.yaml had a slightly different address, so changed it to that, still getting the messages.

S
#1354 SteveCook

[unknown]
Sorry. Geoffrey is the man, but I hope he is having an Easter break form this forum

G
#1355 Goshiki2

[unknown] I’m getting the same after upgrading GivTCP to the latest version.

G
#1356 geoffreycoan

I get these REST failures periodically as well, had a failure to set charge rate yesterday evening, the same (at about the same time) the day before, and then a bunch of the above 'bad REST data - REST will be disabled' on the 17th.

If it happens every now and again then you can ignore it, predbat usually recovers and the next 5 minute predbat run it tries to talk to givtcp it works OK - which is what is seen in your log Goshiki2

One thing you can do to reduce the error frequency is to replace the 'homeassistant.local' bit of the givtcp config in apps.yaml with the IP address of your HA server. This means predbat doesn't have to do a DNS lookup every time it wants to talk to givtcp (and it talks a lot!)

There are three other things I'd advocate:

  1. the givtcp (and predbat) error monitors in the predbat documentation, they should detect either of the addons not running properly and restart them. (checks for things like stale status data, the addon not running, etc)
  2. configuring the auto restart of givtcp in predbat's apps.yaml so if predbat detects a problem it can restart givtcp itself. This can be a bit trigger happy I've found, especially with GivTCP 3 which takes longer to startup, and predbat can often restart givtcp before it had got going
  3. in HA /config/GivTCP/allsettings.json set "auto_scan": false (default is true). This stops givtcp from scanning the network to find your inverters when it starts up, so it starts quicker. You do need to have configured "invertorIP_1": "192.168.1.160" etc with the IP address of your inverters though
#1357 ProximusAl

[unknown]

“ in HA /config/GivTCP/allsettings.json set "auto_scan": false (default is true)”

I assume this is only for the add on and not docker?
My GivTcp all settings doesn’t have auto_scan in docker.

W
#1358 Wavy Davy

geoffreycoan Thanks Geoff,
It's driving me mad. Yesterday I had 10 auto restart service Hassio/addon errors and 7 predbat status issues. All of which send a message to my mobile and tablet.
Will try what you suggest, but can you tell me how to stop the messages. I've had a look and can't see what is actually sending them. I cant see if it's predbat, Givtcp or HA that's generates them.

W
#1360 Wavy Davy

Looking at the Givtcp logs it's dozens like this.
"2025-04-19 15:30:01,612 - read - [ERROR] - Error getting data from cache: ('AttributeError', 'read.py', 2167)"

#1361 PianSom

ProximusAl
I’m a Docker user and my allsettings.json does contain “autoscan: true”

W
#1362 Wavy Davy

Also the startup log has several of these errors
"2025-04-20 00:21:21,706 - startup - [ERROR] - Self Run loop process stuck. Killing and restarting...
2025-04-20 00:21:21,708 - startup - [INFO] - Restarting Invertor read loop every 30s"

W
#1363 Wavy Davy

This is getting ridiculous. Have had 19 rest errors today.
Have managed to disable HA messages on phone so not getting plagued by them.
If it helps anyone (Geoff?) here's the status log

status-log.txt
4kB
#1364 ProximusAl

PianSom interesting. I may try to manually add it.

G
#1365 geoffreycoan

ProximusAl

“ in HA /config/GivTCP/allsettings.json set "auto_scan": false (default is true)”

I assume this is only for the add on and not docker?
My GivTcp all settings doesn’t have auto_scan in docker.

I would assume it’s part of the core givtcp code that runs the same whether an addon or docker - you are on v3 of givtcp?
But no harm in manually adding it to the json config file. It should make givtcp load faster

Wavy Davy It's driving me mad. Yesterday I had 10 auto restart service Hassio/addon errors and 7 predbat status issues. All of which send a message to my mobile and tablet.

You shouldn’t be getting that many. There must be something more fundamental causing the repeated errors.

How is your HA connected to your network, wifi or wired? Strongly suggest you make it wired, even though my server was right next to my router I kept getting givtcp errors which definitely reduced when I used an ethernet cable.

The run loop errors in givtcp suggest its a problem between givtcp and the inverter, so either:

  • HA to network (as above)
  • network to inverter (signal strength?)
  • inverter not wanting to talk modbus (reset to defaults and restart inverter, possibly firmware version upgrade)
  • givtcp problem (delete the /config/GivTCP/*.pkl files and restart givtcp)

You are getting restart/error messages from one of two places:

  1. Predbat itself
  2. The predbat error check automation

If the predbat status automation is detecting predbat in error state too quickly you can increase the duration for that trigger, e.g. increase to 15 minutes to give predbat a chance to sort itself out

You can comment the mobile alert out of the predbat automation or apps.yaml

Finally, there’s the option to change predbat to use HA controls for writing to givtcp (comment the givtcp_rest lines out of apps.yaml) but I think predbat does all the reads via REST regardless

But if you are getting as many errors as you are then there is something more fundamental causing the problems and need to find and fix that

W
#1366 Wavy Davy

[unknown] I think your right about the HA network being the problem.
It's got dramatically worse since I change the local to direct ip address. Will try changing the network its using first to see if that helps.

W
#1367 Wavy Davy

geoffreycoan I think your right about the HA network being the problem.
It's got dramatically worse since I change the local to direct ip address, and happening every few minuits.. Will try changing the network it's using first to see if that helps.

W
#1368 Wavy Davy

Sorry Geoff, just seen your message re ip address and corrected that. Will see how it goes now.

G
#1369 geoffreycoan

Wavy Davy Sorry Geoff, just seen your message re ip address and corrected that. Will see how it goes now.

thinking about the error you were getting with the IP address, am wondering if you’d made another misconfiguration?

there are two places in apps.yaml where URL’s are configured:

  1. ha_key which points to the HA server, used then predbat wants to talk to HA
  2. givtcp_rest which points to the REST address for the GivTCP add-on

Both of these are normally http://homeassistant.local and can be replaced with the IP address of your HA server BUT where they differ is the port number at the end

ha_key points to the HA server itself on port 8123
givtcp_rest points to the GivTCP addon which is port 6345 for the first inverter, 6346 for the second

your error messages were

2025-04-20 13:35:01.768057: Warn: record_status Inverter 0 unable to read REST data from http://192.168.1.26:8123//readData - REST will be disabled
2025-04-20 13:35:51.897372: Warn: Inverter 0 unable to read REST data from http://192.168.1.26:8123//readData - REST will be disabled

which looks like it was trying to get inverter REST data from the HA server (port 8123), not the givtcp addon (port 6345)

I think you have set givtcp_rest to port 8123 not port 6345

As ever, docs give further details https://springfall2008.github.io/batpred/apps-yaml/#home-assistant-connection and https://springfall2008.github.io/batpred/apps-yaml/#rest-interface-inverter-control

W
#1370 Wavy Davy

geoffreycoan Thanks Geoff,
Yes you were correct(as usual). It was set to 8123. Have changed it to 6345 as you suggest. Although I haven't had a error since taking the / out about an hour ago.

B
#1371 browellm

OK, someone is going to have to explain 8.18.10 to me, preferably with crayons and short words 😃

R
#1372 Rbor

[unknown] Trefor has had a field week with 10 updates in a week.

I have updated all the way on the basis that 'Trefor knows best' and 'If something gets broken, Trefor will fix it in double quick time'. He is usually responding to feedback.

I am afraid, I haven't explained v8.10.0 at all! The changes look relatively minor and they should improve predbat.

Rob

W
#1373 Wavy Davy

Well, still getting rest errors, not as many, but 7 since tea time yesterday.
Their all the same
"Auto-restart service hassio/addon_restart called due to: REST read failure"

G
#1374 geoffreycoan

[unknown] someone is going to have to explain 8.18.10 to me, preferably with crayons and short words

8.18.10 came about because of a change Trefor introduced to give Predbat more intelligence about deciding whether to export or not. In conversation with Trefor I am still getting my head around it and am not convinced that the default True value of the new setting inverter_can_charge_during_export makes sense for us with GivEnergy inverters, I think we may need to set it to False

G
#1375 geoffreycoan

browellm someone is going to have to explain 8.18.10 to me, preferably with crayons and short words

8.18.10 came about because of a change Trefor introduced to give Predbat more intelligence about deciding whether to export or not. In conversation with Trefor I am still getting my head around it and am not convinced that the default True value of the new setting inverter_can_charge_during_export makes sense for us with GivEnergy inverters, I think we may need to set it to False

D
#1376 Daveb01

Mr Bat has a good plan today plus the Octopus event ✅

G
#1377 Goshiki2

[unknown] One thing you can do to reduce the error frequency is to replace the 'homeassistant.local' bit of the givtcp config in apps.yaml with the IP address of your HA server. This means predbat doesn't have to do a DNS lookup every time it wants to talk to givtcp (and it talks a lot!)

Thanks Geoffrey. I changed homeassistant.local to my HA IP address and I’ve had no REST errors in 24hours so it’s looking good.

#1378 Hook

So following my oddities with Predbat insisting on exporting during peak every day, I followed @geoffreycoan 's suggestion and added:

rates_export_override:
- start: '22:30:00'
end: '23:30:00'
rate_increment: 10

That changed this:

To this:

I've tried variations of it and it only seems to affect the import price and my peak export stays stubbornly in place.

#1379 PianSom

Hook
I haven't been following your discussion with Geoffrey, but ...

My Predbat is now working pretty regularly the way I want it. I want to avoid silly discharge/charges like yours, but I also want to do a charge/discharge/charge cycle every night. (To avoid the latter just play with my settings below.)

I am on IOG, and use Predbat v8.18.10 and my config entries are as per defaults, expect

  • (irrelevant) I have optimised some scalings for PV and load and charge/discharge rates and inverter/battery loss etc
  • Metric Min Improvement Export = 6p
  • Calculate Export within charge slots = True
  • Calculate export slots on high import rate slots first = False
  • Combine Charge Slots = True
  • Combine Export Slots = True

I don't think this is relevant any more (looking at the Compare plans) but in the past I was having issues with the import not starting until after midnight so I included the following in my apps.yaml to highly disincentivise discharging then:

  rates_export_override:
    - start: "23:30:00"
      end: "00:00:00"
      rate: 0

Maybe try those and see if you get a plan closer to your goal?

G
#1380 geoffreycoan

Hook I followed @geoffreycoan 's suggestion and added:

rates_export_override:
- start: '22:30:00'
end: '23:30:00'
rate_increment: 10

you want an override something like this to prevent peak rate exporting:

  rates_export_override:
    - start: '16:00:00'
      end: '19:00:00'
      rate_increment: -5

make sure you get the YAML indentation correct as this catch you out. Key point is I am making the export rate 5p less in the peak period so predbat doesn't want to export then. You had your rate increment positive and later on so Predbat would be encouraged to export then

#1381 Hook

@geoffreycoan

Cheers, that looks like it's definitely fixed it.

#1382 Hook

Ok 2 days in. Nearly there.

Last 2 days I’m running out of battery between 23.00-23.30 after the export in the previous slots.

I’ll extend the export period by 30 mins to see if that fixes it.

G
#1383 geoffreycoan

[unknown] Last 2 days I’m running out of battery between 23.00-23.30 after the export in the previous slots.

If you are running out prematurely then there are things you can do about it.

What days are you using for days_previous? I’d always suggest using a number of days to give a better average than just say 7, 14.

Load scaling can be increased to say 1.1 or 1.15 to give more contingency by uplifting the load

Check your battery charge and discharge scaling is accurate

Likewise, look at your loss rates, maybe predbat is under-calling the discharge losses?

Set a best_soc_keep to keep more soc in hand

Cheers

A
#1384 arczi19

I've just had an unusual behaviour from Predbat - for the last 2 weeks or so, I have a script that sets Manual Force Demand at 23:30 every night and its been working fine until last night, where after 10 minutes Predbat decided to ignore it started exporting after 10 minutes!

I can see in the logs:

2025-05-01 23:30:00.155516: select_event: manual_demand, select.predbat_manual_demand = 23:30:00

And then 10 minutes later

2025-05-01 23:40:04.452203: Adjust demand (idle) time computed is 23:30:00-23:59:00
2025-05-01 23:40:04.767255: Set inverter 0 charge schedule False via REST successful on retry 0
2025-05-01 23:40:04.767314: Inverter 0 Turning off scheduled charge
2025-05-01 23:40:04.767384: Include original export start 05-01 21:50:00 with our start which is 05-01 21:50:00 (charge start 05-03 00:00:00 end 05-03 00:00:00)
2025-05-01 23:40:04.767425: Next export window will be: 2025-05-01 21:50:00+01:00 - 2025-05-02 00:01:00+01:00 at reserve 4
2025-05-01 23:40:04.767449: Exporting now - current SoC 0.86 and target 0.38 power adjust 1.0
2025-05-01 23:40:04.767491: Inverter 0 Adjust force export to True, change times from 21:50:00 - 00:01:00 to 21:50:00 - 00:01:00
2025-05-01 23:40:04.767504: Adjust idle time, charge 00:00:00-00:00:00 discharge 21:50:00-00:01:00
2025-05-01 23:40:04.767615: Adjust demand (idle) time computed is 00:00:00-00:00:00

Does anyone have any idea why this has happened? I thought setting any of the Manual options would override everything else for the duration of the 30m slot. Im on the latest version of Predbat.

G
#1385 geoffreycoan

arczi19 I have I think noticed some similar behaviour. I set 3 force exports and Predbat recorded two of them as a forced export and one as a force export freeze. I had a couple of things like that but didn’t get into looking at it further

I would suggest you set the manual command a bit in advance though, e.g. run the automation at 23:15 so that Predbat has time to process the request. It looks like you set it at 23:30 and Predbat can take 5 minutes to do a full plan recalc

A
#1386 arczi19

[unknown] Good idea, thank you! Will give it a go tonight and see

T
#1387 TX200

There's a bug in PredBat, but think it's only for those using monitor mode.

File "/config/plan.py", line 54, in find_price_levels
highest_price_charge_level = price_set[-1]
~~~~~~~~~^^^^IndexError: list index out of range

https://github.com/springfall2008/batpred/issues/2340

PredBat couldn't load all the entities and wouldn't show the plan or graphs as a result. Downgrade fixed it for now.

G
#1388 geoffreycoan

TX200 yes there’s a couple of people reporting problems with monitor mode in the last few releases

B
#1389 browellm

Wonder if someone can suggest a fix for what's happened here. My solar forecast chart is stuck showing the estimate from about 6/7 days ago but if I click into the tooltip, it shows the correct forecast.

B
#1390 browellm

Wonder if someone can suggest a fix for this visual(?) issue. My solar forecast chart is stuck showing the estimate from about 6/7 days ago but if I click into the tooltip, it shows the correct forecast.

The sensor is sensor.predbat_pv_today

G
#1391 geoffreycoan

browellm It is probably caching in the UI that’s causing this. A refresh of the browser window or shutting HA down and restarting it can fix that

H
#1392 Henry3rd

Has anyone experienced a Predbat error monitor issue similar to mine? 'Predbat status.last_updated has not changed for 20 minutes" It always happens after midnight and seems to not recognise an update from before midnight. it's probably a simple fix for someone who has the knowledge.

G
#1393 geoffreycoan

[unknown] I'm getting it occasionally as well, its I think due to the predbat compare taking 20 minutes or so to run at midnight

could extend the time in the automation to 25 minutes but I was also going to look to see if I could make it more intelligent around midnight

R
#1394 Rbor

[unknown] Has anyone experienced a Predbat error monitor issue similar to mine?

I had one just after midnight 2 days ago.
I had just upgraded HA and thought that may the cause. Predbat Compare is an interesting idea.

Rob

H
#1395 Henry3rd

geoffreycoan That makes sense. I did extend the time in the automation out to 30 mins, but the error remained. I have now added a condition that the time must be after 01:00 to avoid the Predbat compare issue.

G
#1396 Goshiki2

Something has definitely changed with v8.19.10. I’ve had weeks of stability with Predbat only planning to discharge just before the Octopus Go cheap rate window. Last night I upgraded from 19.9 to 19.10 and today I’ve just come home to find it has dumped a good portion of battery to grid between 19:00 and 20:00.
Looking on Facebook, others have experienced the same thing so I’ve reverted back to 19.9

G
#1397 geoffreycoan

Goshiki2 1 thanks for reporting it. I haven't seen any issues reported on Github but some people send feedback to Trefor only on Facebook

Not upgraded yet myself, was going to writeup the new text summary plan in the documentation, but that got stuck behind writing up the Predbat web console which also wasn't documented ...

J
#1398 Josephiah

Hi folks, is anyone else seeing this?
I've noticed over the last couple of weeks that the final 2330 slot in the load prediction has an unrealistically high value, which is then skewing the plans. My load prediction input takes in 8 days of data; having looked carefully back over the last week's worth of actual energy data, this spike does not exist on any day, so I don't understand where this is coming from.
Not only that, but it appears to be increasing gradually in size over time, to the point that it is getting towards a scarcely believable value (at first I assumed it was just the dishwasher hitting the drying cycle or something).
Any suggestions...?

G
#1399 geoffreycoan

Josephiah I don’t see anything similar in my own load prediction, in fact for me 23:30 is similar to 00:00 and is lower than 23:00, which is what I’d logically expect.

So suggests it isn’t a bug in the date filtering, either a config or load sensor issue with your setup.

What do you have as your load sensor, and you say you have days_previous set to average 8 days of data, what is it set to? (and any days_previous_weighting?)

D
#1400 Daveb01

[unknown] not seeing the same either.


J
#1401 Josephiah

geoffreycoan Thanks, think I've tracked it down, but no idea what to do with it.

My load sensor is baseload_energy_today_kwh, a custom template helper which is calculated by subtracting my heat pump consumption from givtcp_xxxx_load_energy_today_kwh. I can see a spike in this just on midnight (actually from 00:00:00 to 00:00:30ish). My custom sensors all change on the dot of midnight, but the givtcp sensor* is changing at 30s(ish) past the hour - so for that short duration I get a spike.

*in fact, all the givtcp sensors are changing together at some point between 00:00:00 and 00:00:40 - the time varies a little each night, but they all change together.

It still doesn't quite makes sense to me, as I would expect this consumption to show up in the 00:00-00:30 slot, not 23:30-00:00...

G
#1402 geoffreycoan

Josephiah you will get some variation in when precisely the givtcp daily sensors reset to zero because givtcp only polls the inverter every 30 seconds (or whenever you have set the poll frequency).
Plus I think GivTCP 3 is slower to reset things than v2.

I too use a custom template sensor for predbat, but I calculate the house load myself from import - export + generation - charge + discharge as the givtcp load sensor is rubbish with two inverters.
I have a separate sensor that subtracts ASHP load from house load but that's only used on a dashboard, I use the total house load as input for predbat.

I also update my sensors on a time trigger basis, every 5 minutes, and I don't see any spikes at all. I think I saw spikes when I just had an ordinary template trigger and this was caused by different things resetting at slightly different times. Also a template would fire every single underlying state change so fills lots in the database. Mine updates every 5 minutes and so is less noisy.

As a suggestion try using the direct load sensor in predbat and see what that looks like.

What precisely is days_previous set to?

J
#1403 Josephiah

geoffreycoan Thanks, that's a good shout to try time triggered sensors - am I right in thinking you have to write those in configuration.yaml rather than using the template sensor UI...?

days_previous is set to:
days_previous:
- 2
- 3
- 4
- 5
- 6
- 7
- 8

days_previous_weight:
- 0.75
- 0.75
- 0.75
- 0.75
- 0.75
- 1
- 0.75

G
#1404 geoffreycoan

Josephiah yes they have to go in configuration.yaml, you can't (at present) create these sensors in the UI.

In my configuration.yaml I have

template: !include templates.yaml

So all my template sensors are in a separate file. Likewise for climate sensors, history sensors, and recorder exclusions.

And in template.yaml:

- trigger:
    - platform: time_pattern
      minutes: "/5"
  sensor:
    - name: "House Load Today"
      unique_id: "house_load_today"
      unit_of_measurement: kWh
      state_class: total
      device_class: energy
      state: >
        {% set x=(states('sensor.g_solar_energy_today')|float(0)
          + states('sensor.h_solar_energy_today')|float(0)
          + states('sensor.fit_solar_energy_today')|float(0)
          + states('sensor.total_battery_discharge_today')|float(0)
          - states('sensor.total_battery_charge_today')|float(0) 
          + states('sensor.grid_import_today')|float(0)
          - states('sensor.g_sd2237g182_export_energy_today_kwh')|float(0) ) 
        %}
        {{ max(x,0)|round(2) }}

# Home consumption excluding ASHP, updated every 15 minutes
- trigger:
    - platform: time_pattern
      minutes: "/15"
  sensor:
    - name: "House Load ex ASHP Today"
      unique_id: "house_net_load_today"
      unit_of_measurement: kWh
      state_class: total
      device_class: energy
      state: >
        {% set x=(states('sensor.house_load_today')|float(0) 
          - states('sensor.ashp_energy_today')|float(0) )
        %}
        {{ max(x,0)|round(1) }}

I have two sensors, one for self-calculated house load, updated every 5 minutes and one for house load net of ASHP which is every 15 minutes because its only used on a dashboard. If I were using it in predbat I'd do this every 5 minutes. The max() at the end removes any negative spikes due to rounding or midnight reset issues.

Your days_previous looks fine, not using days_previous of 1 which can cause weirdness

R
#1405 Robgy

geoffreycoan calculate the house load myself from import - export + generation - charge + discharge as the givtcp load sensor is rubbish

Please could you help me setting up something like this.
I have home assistant up and running but I'm struggling to figure out how to set-up calculations

J
#1407 Josephiah

geoffreycoan

Hmm, will come back to this. It occurred to me that the spikes I'm seeing are far too short duration (and therefore for too small a contribution) to be causing the large value in the 23:30 slot*.

Had a bit more of a poke around and discovered a pair of errors in apps.yaml, relating to the pv_power and load_power entities (mine were number. rather than sensor.) - presumably I missed a 'breaking change' memo at some point. If it hasn't been reading those in properly for however long, then I'm surprised it's been functioning properly at all. Anyway, will see how it fares over the next week or two as the days_previous history gets cleared out and see if things look more sensible before tinkering with anything else.

Thanks for the pointers anyway - will revisit in due course.

EDIT: * hmm, unless predbat was reading the value at the top of the spike and applying that to the whole half-hour slot...

G
#1408 geoffreycoan

Robgy geoffreycoan calculate the house load myself from import - export + generation - charge + discharge as the givtcp load sensor is rubbish

Please could you help me setting up something like this.
I have home assistant up and running but I'm struggling to figure out how to set-up calculations

I assume you have GivTCP (or GivLocal) already installed and working to poll your inverter for data.
If you haven't, there's an overview of the process in the Predbat installation instructions https://springfall2008.github.io/batpred/inverter-setup/#givenergy-with-givtcp
You don't need to follow the rest of the instructions for predbat, but the above links to setting up Mosquitto and GivTCP.

First question is whether you need to setup a custom sensor or not.
If you just have a single inverter then the standard givtcp sensor.givtcp_xxxx_load_energy_today_kwh sensor should be a pretty good value to use for your house load. Its calculated by the inverter based on the same inputs and outputs I mentioned above.

I have two inverters so they share the load so each inverter sensor isn't accurate for house load and I have to create my own.

I use a custom time based trigger that's defined in configuration.yaml as described in the post above https://community.givenergy.cloud/d/5411-second-year-live-on-predbat/1404

J
#1409 Josephiah

geoffreycoan
A couple more pieces of evidence:

  1. switching back to:
    load_today:
        - sensor.givtcp_{geserial}_load_energy_today_kwh
    and commenting out my heat pump load prediction calculation gets the plan looking more sensible.
  2. Keeping load_today as above and adding the heat pump load prediction back in still leaves the plan looking sensible, albeit now it's double-counting the heat pump load.

So I think this takes me back to assuming the spikes in my baseload calc are the issue, and to try your time trigger method...

G
#1410 Goshiki2

A question for the collective: has anyone successfully added a non Octopus dual rate tariff to the compare function?
I’m moving to Eon Next Drive next week and I’ve been looking at my apps.yaml to get prepared.
By commenting out “metric_octopus_import” and “metric_octopus_export” and uncommenting “rates_import” and “rates_export” my actual plan displays everything perfectly but if I add the same information to the compare function it only displays the higher rate for import in the plan and ignores the cheaper rate. It’s either related to apps.yaml spacing or my incompetence but I’ve tried lots of spacing variations and can’t get it to display more than one rate. Help……..

G
#1411 geoffreycoan

Goshiki2 I think its your indentation, the second set of rates are not part of the id

Trefor's example is:

  compare_list:
    - id: 'cap_seg'
      name: 'Price cap import/Seg export'
      rates_import:
        - rate: 24.86
      rates_export:
        - rate: 4.1  

So expanding it:

  compare_list:
    - id: 'eon_next_drive'  # note no spaces in the id
      name: 'Eon Next Drive import/fixed export"'
      rates_import:
        - rate: 6.7
          start: "00:00:00"
          end: "07:00:00"
        - rate: 24.86
          start: "07:00:00"
          end: "24:00:00"
      rates_export:
        - rate: 16.5  
G
#1412 Goshiki2

geoffreycoan Thanks Geoffrey. I’ll give it a go.
Edit: it worked perfectly. Many thanks

G
#1413 geoffreycoan

Goshiki2 I’ll update the documentation to add this as another example

J
#1414 Josephiah

geoffreycoan

Well, that was an interesting experiment:

  1. Using a time-trigger template (with 1min timing for now) did offer better control over the timing; however, the main effect is (of course, once I'd thought about it) is to lengthen the spike to exactly 1 minute, instead of the ~ 20-30s it was before). It helped the values in the plan initially, but this is just an artefact of there being no history yet in my new sensor. Once we'd crossed midnight, the odd value in the 23:30 slot started appearing again. So I think this confirms I'm on the right track.
  2. Instead, what I think I need to do is to make a helper which takes the givtcp_load_energy_today_kwh sensor and artificially zeroes it at midnight, bringing it into line with the other sensors. Templating/jinja, here we come.
B
#1415 browellm

Oh that new Predbat Table Card with the weather symbols & temps is 10/10. Love it.

G
#1416 geoffreycoan

Submitted a Predbat PR

Biggest change is documenting the facilities and views for the Predbat web interface. Also a bunch of other documentation and code tweaks as things have been raised on github

R
#1417 Rodmac76

Looking for some advice I have been running predbat and all is working well, I have although now been looking closer and with the octopus app showing Day/night charges I have noticed that I am generally using Day rate between 00:00-00::30. I am on the Octopus Go tarrif is there an adjustment to prvent this as the plan always generally shows me Exporting during these hours.

#1418 PianSom

Rodmac76
On Go, isn't exporting during 00:00-00:30 the right thing to do? Dump the charge to make money before the cheap period starts at 00:30, when you can. charge up again?

I am on IOG, and find that Predbat plans get a bit off around midnight. I want to import from 11.30pm, and find that Predbat often prefers to export then even though it is cheap for me. So I set the export rate to zero for that period in apps.yaml, and this seems to do the trick for me.

I have this in my apps.yaml:

# Add in highly incentivised 11.30pm export

  rates_export_override:
    - start: "23:30:00"
      end: "00:00:00"
      rate: 0
R
#1419 Rodmac76

Thank You PianSom I will add that for my Go Tarriff with the times 00:00-00:30. Hoping to get my charger next few weeks so move to IOG so will also keep this in mind.

#1420 PianSom

Rodmac76
Just to be clear - if you add that for the midnight slot then Predbat will not export then, but could easily do it earlier. So you could be importing from midnight at the higher rate.

Is that what you want?

R
#1421 Rodmac76

PianSom No I dont want to import at the higher rate, would rather avoid as its costing me between 50-90p was hoping my battery would cover this. would adjusting the battery reserve limit higer prevent this? At the moment set to 4%?

#1422 PianSom

Rodmac76
No, adjusting the battery reserve isn't the right thing to do.

You need to tune Predbat so that the usual nightly discharge finishes at 00:30. But you said " the plan always generally shows me Exporting during these hours." so I am assuming your export finishes early? If so this is what you should be investigating. When does your export finish normally?

A
#1423 arczi19

Is there a way to ensure predbat only ever plans to export at the end of the day? I could have swore this used to be the case normally, but with the latest version of predbat I seem to be getting random exports during the day and the plan would typically see my battery get flat by midnight when my cheap import starts.

G
#1424 geoffreycoan

Rodmac76 and arczi19 it sounds like both of you need to check (a) your losses and (b) the load history (days_previous) you are using for predbat so it comes up with a more accurate plan to stop you running out of battery prematurely. It shouldn’t then matter if there are earlier exports.

You can also increase load scaling to be a bit more pessimistic about load and increase metric battery cycle cost a touch to value stored charge at higher value

A
#1425 arczi19

[unknown] Thank you. That would work for most days indeed, however if one day I randomly decide to bake at 9pm, I will run of battery - exporting excess at the end of the day seems to me like the safest approach to avoid any surprises.

G
#1426 geoffreycoan

[unknown] am not disagreeing, other people have made similar comments about newer versions of predbat can discharge earlier than they used to do

Make sure switch.calculate_export_high_import is set to true (the description in the docs is confusing, one for me to look at)

A
#1428 arczi19

Looks like new version of predbat might improve things relating to exporting at the end of the day.

R
#1429 Rodmac76

[unknown]

For some reason I am using the below consumption for the last half hour generally. This is when I am exporting the last of the battery. I have no other heavy devices working just general house load of about 450W. @[deleted] you were correct increasing the reserve does not make a difference. I am hopefull the new version will rectify some of the issues with final export.

Consumption (kwh) Estimated Cost Inc. Tax (p) Start End
3.162 86.06927637 2025-05-19T00:00:00+01:00 2025-05-19T00:30:00+01:00
3.135 85.33433948 2025-05-20T00:00:00+01:00 2025-05-20T00:30:00+01:00
3.27 89.00902395 2025-05-21T00:00:00+01:00 2025-05-21T00:30:00+01:00
3.198 87.04919223 2025-05-22T00:00:00+01:00 2025-05-22T00:30:00+01:00
3.157 85.93317695 2025-05-23T00:00:00+01:00 2025-05-23T00:30:00+01:00
3.157 85.93317695 2025-05-24T00:00:00+01:00 2025-05-24T00:30:00+01:00
3.155 85.87873718 2025-05-25T00:00:00+01:00 2025-05-25T00:30:00+01:00

J
#1430 Josephiah

geoffreycoan

Josephiah I've noticed over the last couple of weeks that the final 2330 slot in the load prediction has an unrealistically high value.

Josephiah Instead, what I think I need to do is to make a helper which takes the givtcp_load_energy_today_kwh sensor and artificially zeroes it at midnight, bringing it into line with the other sensors. Templating/jinja, here we come.

Just to round off this one: it took a while for the history with the spikes in to propagate out, but now that it has, the 23.30 slot is looking much more sensible. The workaround was just to add a line in my template sensor zeroing the data within the first minute after midnight, killing the spikes. Thanks for the pointers, got there in the end!

G
#1431 geoffreycoan

Rodmac76 For some reason I am using the below consumption for the last half hour generally. This is when I am exporting the last of the battery.

If I read your Octopus download correctly, you are saying that your predbat plan has you exporting the last of the battery, but Octopus are billing you for import in that time slot, and looks to be about 3kWh a day.

My first reaction was whether you have the time slots setup correctly in apps.yaml, or your smart meter has the time wrong (fun fact, smart meters are deliberately set with the wrong time, I have heard they can be up to 10 minutes out! This is so that people using high loads such as EV charging that may be set to come on at say 1am, don't all start at the same immediate microsecond and overload the grid with the power surge).

But looking again, I wonder if you are reading the data wrong ....

Those times are 00:00-00:30 but +1 hour for BST, i.e. 01:00-01:30 BST

So they are when predbat has swapped to charging your battery after discharging it to empty

M
#1432 ma9mwah

Does anyone know how to downgrade to a version that is no longer on the drop down list within predbat? The new version still doesn't seem right and I want to go back to version 8.19.9

R
#1433 Rodmac76

geoffreycoan Thank You for taking the time respond. You may be up to something with octopus timing I have asked them to take a look. Last night I had the message below from predbat before I went to sleep, so I set to charge only about 10pm and still looked to have used 3kw. Looking back it’s very consistent through the months and when I got my EV on a granny charger on the 19th April it increased again suggesting it may be out an hour. The smart meter does show the correct time and apps.yaml timezone is Europe/London.

R
#1434 Rbor

ma9mwah Does anyone know how to downgrade to a version that is no longer on the drop down list within predbat?
Try this: .....

In 'Status', click on the mark shown by the red arrow (See below).
You will then see recent versions.
Just select one of these and predbat will downgrade for you.

Rob

R
#1435 Rodmac76

[unknown] Thank you for your wisdom, the time is 32 minutes out this explains the extra charge. I looked at the IHD which was correct but the smart meter shows the discrepancy

G
#1436 geoffreycoan

Rodmac76 glad you have found the issue. Unusual I have never heard of a smart meter being that far out. Good luck with sorting that out (and the billing out) with Octopus ...

ma9mwah Does anyone know how to downgrade to a version that is no longer on the drop down list within predbat? The new version still doesn't seem right and I want to go back to version 8.19.9

  • Go to predbat releases on github https://github.com/springfall2008/batpred/releases
  • Find the release you want
  • Download the zip file of the release
  • Unzip it
  • Copy all the .py files into the /addon_configs/6adb4f0d_predbat folder in Home Assistant. Samba share makes this fairly easy
Y
#1437 Yossarian

Todays saving session has gone in for me at 8pm rather than 7pm. Anyone else? Assume it might be a daylight savings issue but cant work out the issue.

I join it using bottlecapdaves blueprint and then predbat picks it up.

T
#1439 TX200

Octopus webpage says 8pm.

Y
#1440 Yossarian

Ah that explains it, thanks. I get a telegram alert which said 19:00-19:30. That has since also been updated.

R
#1441 Rodmac76

geoffreycoan Thanks again, They have sorted my meter out now took them a couple of days. I would advise everyone to check there meter i did see on Reddit someoene was 4hr 11min out. Sorting the billing will take a bit longer, my guess its has been wrong for a couple of years.

#1442 Hook

Rodmac76 "#p81678 I have the following courtesy of @geoffreycoan "#3002 in my apps.yaml.

rates_export_override:
start: '14:00:00'
end: '19:30:00'
rate_increment: -5

This means it pushes my export to the end of the day before my iog period at 11.30pm. Stops it happening during peak time and leaving me short on a few occasions.

R
#1443 Rodmac76

Hi now I have my timing sorted I am looking to finally get some of my sensor errors sorted this may be why the battery exports and it takes some peak power for house load at the end.is this a MQTT error if so can you recommend the best way to resolve?

W
#1444 Wavy Davy

Been off the board for a while and just now noticed that my predbat table has changed.
Is there a new list of things like "state"? I have got a new message "Demand [Alert]" which is also on Predbat status.
Don't think it's a problem, but can someone tell me what it means?

W
#1445 Wavy Davy

Been off the board for a while and just now noticed that my predbat table has changed.
Is there a new list of things like "state"? I have got a new predbat table status message "Demand [Alert]" which is also on Predbat status.
Don't think it's a problem, but can someone tell me what it means?

G
#1446 Goshiki2

Has anyone tried Trefor’s latest Metric Min Improvement Swap function to move the export later in the day? ( something that used to happen by default anyway before recent updates)
I’ve tried various values from +1 to -5 but the plan always seems to leave a one hour gap before the cheap rate period starts whereby if any unexpected loads are used, it would result in grid usage at high rate.
There are so many confusing functions now that it’s getting out of control. As I’ve said before, it really needs a Predbat Lite option for simple people on simple tariffs 😂

Edit: I left the plan alone to see if it would change as it grew nearer the time but it stayed the same so I’ve reverted back to using an automation to force export in the later slots. It’s the only way I can consistently keep export as late as possible.

D
#1447 Daveb01

[unknown]

I found the same & moved back to v .10. I hope Trevor sorts it out.

S
#1448 SteveCook

Been using Predbat over a year and very pleased, but just looking at prediction, what is this strange charge for 57p at 00:00 using standard rate power, when it could/should wait 2 hours for off peak.
The battery prediction is 54%, so no need to do this

L
#1450 Leeshore

SteveCook Think that’s your standing charge

S
#1451 SteveCook

Leeshore Thanks for explaining

R
#1452 rjp

Just updated to the latest Predbat - The "Solar Calibration" is interesting as we've got noticeable shading in early evening which solcast doesn't understand.

R
#1453 Rbor

rjp Agreed.
It will be interesting over the next few days to see how pv calibration responds to actual influences such as tree shading at different times during the day.

B
#1454 browellm

I’ll have to make a manual import override tomorrow as the auto opt in to the Octopus Free Electricity session has me down for free import during this and wants to dump some battery beforehand, then charge. Being on IOG means this isn’t correct.

S
#1455 shawry

[unknown] did you get an answer to this, as several of my entities show entity not found, including the 3 you show here.

S
#1456 shawry

Rodmac76 did you get an answer to this, as several of my entities show entity not found, including the 3 you show here.

R
#1457 Rodmac76

shawry I noticed in the facebook Predbat forum that someone had commented that the HYbrid version 2 did not support these. Just looked and cannot now find the comment. If you find a fix please let me know, I think it only appeared after upgrading GIVTCP to V3

K
#1458 KamenMacKay

Just had a Vaillant Aerotherm 5kwh ashp installed and got the integration up and going in Home Assistant. I'm also running PredAi so can someone give me an example of how to subtract the iBoost energy consumed data from the general Predai prediction inside the PredAI configuration. Separate sensor maybe?
A broader question: while I love scrolling through the comments here and picking up little tidbits of knowledge here and there about Predbat, is there a 'cookbook' somewhere that lists settings/configs that aren't listed in the Predbat docs. Perhaps the Predbat docs needs a section like this? I would love to see stuff related to various inverters/heatpumps and various tips and tricks for those.

J
#1459 Josephiah

An interesting switch in Predbat strategy as a result of this month's price decrease: there is now enough of a differential between the cheap Cosy blocks (12.65p/kWh) and export at 15p/kWh, that Predbat is just going for a full on top-up charge in every cheap block, and directly exporting all our excess solar.

Makes sense, I suppose, but pondering just turning Predbat off for the summer and switching to Eco mode might be almost as good, and less wearing on the battery...

#1460 PianSom

Josephiah pondering just turning Predbat off for the summer and switching to Eco mode might be almost as good, and less wearing on the battery...

Alternatively, you might want to tune Predbat to require a better return from exporting. Eg I have input_number.predbat_metric_min_improvement_export set to 6p

J
#1461 Josephiah

PianSom isn't that setting to do with forced exports? I'm not quite sure which setting would help here...

#1462 PianSom

Josephiah isn't that setting to do with forced exports?

Oops - you are not wrong. A combo of an ageing memory and Trefor's unique naming conventions. Sorry.

Maybe increase the conversion loss settings (input_number.predbat_battery_loss input_number.predbat_battery_loss_discharge and input_number.predbat_inverter_loss)?

J
#1463 Josephiah

PianSom yeah, those were my next thought too. The system is complex enough that it's far from an obvious cause and effect. I tried bumping up predbat_metric_battery_cycle to 5p (from 1p) and that was enough to make it just stay at 100% except for the evening peak. Will try some more subtle changes and see what happens, but I guess it may just be such a fundamental shift from "optimise on cost" that it'll never do what I expect...

S
#1464 SteveCook

Since the update last week i get these errors about entities not being found.
I have not changed any of my installation. I dont have an EV car.
I think they are about an EV, and I presume i could edit the configuration table and take the lines out, but because I might get an EV one day, I dont want to do that.
I thought that up to last week, if i had toggled that I did not have an EV, the table would "know" not to try and find info that did not exist.
Any comments?
Thanks

#1465 Jase1703

Been seeing a bunch of warnings of missing or gaps in data since update to Givtcp v3. I did have both Gateway and AiO selected as inverters in Givtcp config, I’ve now deselected gateway in the config to see if that makes a difference. Am I missing something simple or does inverter need a reboot? No other yaml errors.

#1466 Jase1703

Been seeing a bunch of warnings of missing or gaps in data since update to Givtcp v3. I did have both Gateway and AiO selected as inverters in Givtcp config, I’ve now deselected gateway in the config to see if that makes a difference. Am I missing something simple or does inverter need a reboot? No other yaml errors.

#1467 PianSom

Jase1703
Looks odd.

Has your home network been stable? I think I'd be looking at that rather than GivTCP or your AIO

#1468 Jase1703

[unknown] good point thanks. Major reboot of everything incoming.

R
#1470 Rbor

[unknown] Been seeing a bunch of warnings of missing or gaps in data

I have had patterns like this for months. Your looks almost like a carbon copy of mine.
I have an AC3.0 inverter.

At times, I find the missing data disappears as the historical days advance but the missing data seems to then start up again.
I have tried increasing this setting in apps.yaml:
load_filter_threshold: 30
Increasing to 60 seems to have little effect.
I have tried 480 which does reduce the warnings but seems drastic.

I am currently running PredAI and I don't then get the warnings at all! I have no idea why.
If I then revert back to normal, the historical warnings all come back.

I would be certainly be interested if anyone does have a solution.
I am running givTCP 3 but I think I got the warnings before when I was still running givTCP 2.

My network has been stable throughout, the latest version of HA and Predbat v8.23.1

Rob

R
#1471 Rbor

Jase1703 Been seeing a bunch of warnings of missing or gaps in data

I have had patterns like this for months. Your looks almost like a carbon copy of mine.
I have an AC3.0 inverter.

At times, I find the missing data disappears as the historical days advance but the missing data seems to then start up again.
I have tried increasing this setting in apps.yaml:
load_filter_threshold: 30
Increasing to 60 seems to have little effect.
I have tried 480 which does reduce the warnings but seems drastic.

I am currently running PredAI and I don't then get the warnings at all! I have no idea why.
If I then revert back to normal, the historical warnings all come back.

I would be certainly be interested if anyone does have a solution.
I am running givTCP 3 but I think I got the warnings before when I was still running givTCP 2.

My network has been stable throughout, the latest version of HA and Predbat v8.23.1

Rob

S
#1472 shawry

Wondered if anyone can tell me if I should have to do anything to make use of the free electricity slots that Octopus are putting out?

I would have expected predbat to set my batteries to discharge, then charge during the slot?

S
#1473 SteveCook

[unknown]
I dont know if predbat "receives" any information from the Octo API telling it there is free electricity.
I guess they are worried we all charge up 2-3pm and then sell after 4pm

S
#1474 SteveCook

shawry
I dont know if predbat "receives" any information from the Octo API telling it there is free electricity.
I guess they are worried we all charge up 2-3pm and then sell after 4pm.
I think you may have to force a manual charge from 2-3

R
#1475 Rbor

shawry
It depends!
There are settings in apps.yaml:

 # Octopus free session points to the free session Sensor in the Octopus plugin
  # Note: You must enable this event sensor in the Octopus Integration in Home Assistant for it to work
#  octopus_free_session: 're:(event.octopus_energy_([0-9a-z_]+|)_octoplus_free_electricity_session_events)'

  # Alternative scraper from Octopus web site if the above is not working
  # octopus_free_url: 'http://octopus.energy/free-electricity'

I have not set these. I did for the last session and I think that Predbat did pick this up.
I do have the respective setting set in apps.yaml for savings sessions which Predbat has always found and added to my plan.

Do you have solar panels and/or an EV?
Do you make use of the Octopus Energy Integration?

If you set batteries to charge, they would do so first from PV generation which would be exporting and potentially paying you (I get 15p/kWh exported)
And EV charging will come first from PV generation.

You get the bonus from these events providing that you can use free energy from the grid.

I have both solar panels and an EV, charged from a Zappi.
During the last Free session, the Zappi used PV generation and was topped it up with grid electricity.

It is very much up to you and dependent on your set up.
I am still experimenting myself with the most appropriate tactic to use.
With today's session starting in 2 hours time, you need to make a decision!

Rob

T
#1476 TX200

Bonus for me, I'm on IOF, so I just let it do what it wants to do.

Got the dishwasher on, second high draw of power will happen just after 2pm

Plus a wash load ready to go too.

(iOF and iOG customers DO now get credit for extra household usage).

S
#1477 shawry

Rbor

With extra usage now being paid, Ive incorporated it, your steps got it sorted, thankyou 🙂

shame Im not home though, so I could charge car too!

#1478 Hook

Predbat confuses me sometimes.

I’m usually on iog. Why would it empty my battery to put me on mains electricity instead of just using the battery to supply load until the cheaper charging period? 🤔

#1479 Hook

W
#1480 Wavy Davy

I'm having difficulty understanding predbat at the moment.
It discharged the batteries during last night, then when I got up it was charging them up at full power.
OK the rate was low, but there was free electricity coming up in a couple of hours. During those hours it is just going to hold charge at 100%
I know it could change its schedule, but it doesn't seem to make sense.
It happened last weekend as well.
Have switched it onto monitor only and stopped the charging. Will turn it back on when it's free.

W
#1482 Wavy Davy

Meant to add I'm on agile, and my config is pretty much default values.

W
#1483 Wavy Davy

Is anyone using a helper called "below rate value"?
If so what value are you using? cant find any info on this.

S
#1485 Stever

I would love to upgrade my predbat (8.21.3) install and run a later version with all the UI changes/improvements but every time I try it "breaks" my plan and removes the overnight discharge/charge cycle so I have to downgrade again. I've not made any changes post upgrade so it's definitely the logic, it's just a shame the UI changes are tied to them.

I guess the if it ain't broke don't fix it rule applies. I know I could write my own automation to force it to export and then recharge overnight, it's just annoying that upgrading always changes the plan logic for the worse (for me).

#1486 PianSom

Stever it's just annoying that upgrading always changes the plan logic for the worse (for me).

Me too.

I have bitten the bullet and am living with a worse plan than I had before the changes of a couple of months ago

G
#1487 Goshiki2

Does anyone know how I can stop random 10 minute exports during the overnight cheap charging period? I’m on Eon NextDrive V7 so it’s always been a very simple plan with full charge between midnight and 7am and then export all solar and dump the remaining battery before starting the cycle again.
It’s never done it until last week and I’ve made no config changes recently. I go to bed with a plan indicating nothing unusual and wake up to something completely different. Config is pretty much default settings. I might have to roll back a few versions as it never used to do it.

S
#1488 SteveCook

Why does my prebat do a grid import/charge each night at 00:00 rather than wait 2 hours and do it off peak at half the price?

D
#1489 Dpe

I do not see a charge at 0:00, I think the +54p is due to the standing charge being added for the next day (unless I have misunderstood the question)

L
#1490 Leeshore

[unknown] yes it’s the standing charge

L
#1491 Leeshore

SteveCook it’s the standing charge you can see

S
#1492 SteveCook

Leeshore
Thankyou for telling me about the standing charge.
i apologize, because someone had told me that before, but I had forgotten (age thing!)

K
#1493 KamenMacKay

I'm getting the Givenergy charger installed in a few days. If anyone has this setup in Predbat, it would be great if you could share your configuration (in apps.yaml)...this is what I have so far but maybe there's some additional tweaks that make it work a little bit better?

num_cars: 1
car_charging_battery_size: 42.0
car_charging_limit: 'sensor.i3_120_charging_target'
car_charging_soc: 'sensor.i3_120_remaining_battery_percent'

#1495 PianSom

KamenMacKay
Looks good to me, and just like mine for my i3.

You may want to check the list in car_charging_planned_response: - the defaults work with my zappi, but I don't know what the GE charger responds with.

K
#1496 KamenMacKay

PianSom Would you mind sharing the rest of your car charging config? I've been simulating car_charging and set smart_plan to True but it insists on charging on the rest of the slots for the day and only at midnight does it start charging at low rates (2:00 - 5:30). I do have it set to charge to 100% so maybe that's part of the problem.
Also, a question for other ev users who export during the summer to build up credit: do you switch to Go/fixed export during the summer or just stay on Flux import/export and 'eat' the increased import tariff on the days that the car needs a big charge overnight?
I'm loving the i3, btw...what a nice little car!

#1497 PianSom

KamenMacKay
I have a somewhat eccentric charging regime - I am on Octopus Intelligent Go but have Smart Control switched off. So I use Predbat-led charging, and do not get any "bonus" slots. This allows me for more granular battery management, rather than being dependent on the timing of charging slots set up by Octopus. As the days get shorter the attraction of more cheap slots will become greater and I may move to Octopus-led charging - we shall see.

Are you on Octopus Flex (though I thought that was 02:00-05:00 cheap)? Wouldn't you be better off using Octopus Intelligent Go (with Fixed export)?

Generally, my settings are as set out in the Predbat manual, though I have written a set of automations to allow me to switch easily between Predbat-led and Octopus-led charging.

I am loving the i3, had it for just a few months. My first EV, and it's a perfect little runaround town car - which is what I got it for. I generally charge it up every few days (to 100%), so that it is always topped up.

K
#1498 KamenMacKay

PianSom Ah, I see. By turning smart-charge off, it's pretty much just like Go but 1p/kwh cheaper.
Any chance you care to share your automations for easily switching between Predbat-lead and Octopus-led?

#1499 PianSom

KamenMacKay
For sure.

First set up a new Helper - a Dropdown called "Car charge control" and give it the options "Octopus-led" and "Predbat-led" (these names are used in the automations, so don't change them). You can give it a car icon, or similar, if you want to. This will create an entity called input_select.car_charge_control. You can put this on a dashboard somewhere.

Then add three automations. For each you will need to replace your own Octopus account number, and amend the zappi controls to whatever the Giv charger uses:

alias: >-
  Car charging 1 - on startup and when "Car charge control" changes adjust
  Predbat + Octopus
description: >-
  When car charging mode changes between Octopus-led and Predbat-led make
  necessary changes. 


  If unknown status eg on startup then status is set by reference to the Octopus
  Intelligent Smart Charge setting (on => Octopus-led)
triggers:
  - trigger: state
    entity_id:
      - input_select.car_charge_control
  - trigger: homeassistant
    event: start
conditions: []
actions:
  - choose:
      - conditions:
          - condition: state
            entity_id: input_select.car_charge_control
            state: Octopus-led
        sequence:
          - action: switch.turn_on
            metadata: {}
            data: {}
            target:
              entity_id: switch.predbat_octopus_intelligent_charging
            alias: Put Predbat into Octopus-led mode
          - action: select.select_option
            metadata: {}
            data:
              option: Eco+
            target:
              entity_id: select.myenergi_zappi_XXXXXXX_charge_mode
            alias: Put zappi into Eco+
          - action: switch.turn_on
            metadata: {}
            data: {}
            target:
              entity_id: switch.octopus_energy_a_XXXXXXX_intelligent_smart_charge
            alias: Put Octopus into Smart Charge mode
      - conditions:
          - condition: state
            entity_id: input_select.car_charge_control
            state: Predbat-led
        sequence:
          - action: switch.turn_off
            metadata: {}
            data: {}
            target:
              entity_id: switch.predbat_octopus_intelligent_charging
            alias: Put Predbat into Octopus-led mode
          - action: switch.turn_off
            metadata: {}
            data: {}
            target:
              entity_id: switch.octopus_energy_a_XXXXXXX_intelligent_smart_charge
            alias: Put Octopus into non-Smart Charge mode
          - alias: If EV is Plugged then zappi to Stopped
            if:
              - condition: state
                entity_id: sensor.myenergi_zappi_XXXXXXXX_plug_status
                state: EV Connected
            then:
              - action: select.select_option
                metadata: {}
                data:
                  option: Stopped
                target:
                  entity_id: select.myenergi_zappi_XXXXXXX_charge_mode
                alias: Move zappi to Stopped
      - conditions:
          - condition: state
            entity_id: input_select.car_charge_control
            state: unknown
          - condition: state
            entity_id: input_select.car_charge_control
            state: unavailable
        sequence:
          - choose:
              - conditions:
                  - condition: state
                    entity_id: switch.octopus_energy_a_XXXXXXX_intelligent_smart_charge
                    state: "off"
                sequence:
                  - action: input_select.select_option
                    metadata: {}
                    data:
                      option: Predbat-led
                    target:
                      entity_id: input_select.car_charge_control
                    alias: Move Car charge Control to Predbat-led
                  - alias: If EV is Connected then zappi to Stopped
                    if:
                      - condition: state
                        entity_id: sensor.myenergi_zappi_XXXXXXX_plug_status
                        state: EV Connected
                    then:
                      - action: select.select_option
                        metadata: {}
                        data:
                          option: Stopped
                        target:
                          entity_id: select.myenergi_zappi_XXXXXXX_charge_mode
                        alias: Move zappi to Stopped
              - conditions:
                  - condition: state
                    entity_id: switch.octopus_energy_a_XXXXXXXX_intelligent_smart_charge
                    state: "on"
                sequence:
                  - action: input_select.select_option
                    metadata: {}
                    data:
                      option: Octopus-led
                    target:
                      entity_id: input_select.car_charge_control
                    alias: Move Car charge control to Octopus-led
                  - action: select.select_option
                    metadata: {}
                    data:
                      option: Eco+
                    target:
                      entity_id: select.myenergi_zappi_XXXXXXX_charge_mode
                    alias: Put zappi into Eco+
        alias: If Car charge control is Unknown/Unavailable
mode: single

and

alias: >-
  Car charging 2 -  if Predbat-led when zappi changes plug status then change
  zappi mode 
description: >-
  If we are Predbat-led and the zappi moves to "EV Connected" (ie the car is
  plugged in) then this moves zappi to Stopped. Also moves zappi to Eco+ on "EV
  Disconnected" status. Other status changes (eg "Charging", "Waiting for EV")
  are ignored. 


  Note that a change to EV Connected status can happen when the car is plugged
  in AND if the car is plugged in and the zappi does something else to change
  its status.


  (May be "better" to leave in Eco+, but 1 - may lead to unpredictable behaviour
  depending on Myenergi setup; and 2 - see
  https://myenergi.info/zappi-control-with-home-assistant-t13629-s30.html which
  implies charge cancelling is problematic.) 
triggers:
  - trigger: state
    entity_id:
      - sensor.myenergi_zappi_XXXXXXX_plug_status
conditions:
  - condition: state
    entity_id: input_select.car_charge_control
    state: Predbat-led
actions:
  - choose:
      - conditions:
          - condition: state
            entity_id: sensor.myenergi_zappi_XXXXXXXX_plug_status
            state: EV Connected
        sequence:
          - data:
              option: Stopped
            target:
              entity_id: select.myenergi_zappi_XXXXXXXX_charge_mode
            action: select.select_option
            alias: Move zappi to Stopped
      - conditions:
          - condition: state
            entity_id: sensor.myenergi_zappi_XXXXXXX_plug_status
            state: EV Disconnected
        sequence:
          - data:
              option: Eco+
            target:
              entity_id: select.myenergi_zappi_XXXXXXX_charge_mode
            action: select.select_option
            alias: Move zappi to Eco+
mode: single

and

alias: Car charging 3 - if Predbat-led then do zappi actions when instructed
description: >+
  If we are Predbat-led then start/stop car charging based on Predbat determined
  slots. Moves zappi to Stopped when not charging. Moves zappi to Fast when
  charging. (NB i3 users suggest leaving charging even when full occasionally.
  If this is desired then do not move back to Stopped - as a manual edit.)


  We do not look at initial state of zappi, we only action when Predbat moves to
  On, or to Off



triggers:
  - trigger: state
    entity_id:
      - binary_sensor.predbat_car_charging_slot
    to: "on"
    id: To On
  - trigger: state
    entity_id:
      - binary_sensor.predbat_car_charging_slot
    to: "off"
    id: To Off
conditions:
  - condition: state
    entity_id: input_select.car_charge_control
    state: Predbat-led
actions:
  - choose:
      - conditions:
          - condition: state
            entity_id: binary_sensor.predbat_car_charging_slot
            state: "on"
        sequence:
          - data:
              option: Fast
            target:
              entity_id: select.myenergi_zappi_XXXXXXXX_charge_mode
            action: select.select_option
            alias: Move zappi to Fast
      - conditions:
          - condition: state
            entity_id: binary_sensor.predbat_car_charging_slot
            state: "off"
        sequence:
          - alias: Move zappi to Stopped (EDIT TO Fast IF LOOKING FOR LONG CHARGE)
            data:
              option: Stopped
            target:
              entity_id: select.myenergi_zappi_XXXXXXXX_charge_mode
            action: select.select_option
mode: single

Then if the car is plugged in

  • if in Octopus-led mode Octopus will take charge of my zappi and charge the car when they want to
  • if in Predbat-led mode then (when the plan is next updated) Predbat will take charge by changing one of its input_selects when it wants to charge
Z
#1500 Zakalwe

Woke up to a discharged battery and Predbat throwing an "Exception raised"error. The plan is null.

Any ideas why it would suddenly do this? It's fully up to date and was working fine when I went to bed.

Partial Error Log:
22124 2025-08-27 14:30:12.482068: Error:
22123 2025-08-27 14:30:12.481867: Info: record_status Error: Exception raised
22121 ValueError
22120 raise ValueError
22112 2025-08-27 14:30:12.453951: Error: Traceback (most recent call last):
22111 2025-08-27 14:30:12.450789: Error: Exception raised
22110 2025-08-27 14:30:12.450575: Warn: record_status Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
22109 2025-08-27 14:30:12.425683: Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
22041 2025-08-27 14:25:12.465007: Error:
22040 2025-08-27 14:25:12.464822: Info: record_status Error: Exception raised
22038 ValueError
22037 raise ValueError
22029 2025-08-27 14:25:12.442011: Error: Traceback (most recent call last):
22028 2025-08-27 14:25:12.439393: Error: Exception raised
22027 2025-08-27 14:25:12.439212: Warn: record_status Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
22026 2025-08-27 14:25:12.418982: Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
21958 2025-08-27 14:20:11.250447: Error:
21957 2025-08-27 14:20:11.250265: Info: record_status Error: Exception raised
21955 ValueError
21954 raise ValueError
21946 2025-08-27 14:20:11.225280: Error: Traceback (most recent call last):
21945 2025-08-27 14:20:11.222377: Error: Exception raised
21944 2025-08-27 14:20:11.222174: Warn: record_status Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
21943 2025-08-27 14:20:11.199875: Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
21875 2025-08-27 14:15:11.927270: Error:
21874 2025-08-27 14:15:11.927063: Info: record_status Error: Exception raised
21872 ValueError
21871 raise ValueError
21863 2025-08-27 14:15:11.899696: Error: Traceback (most recent call last):
21862 2025-08-27 14:15:11.896631: Error: Exception raised
21861 2025-08-27 14:15:11.896423: Warn: record_status Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
21860 2025-08-27 14:15:11.866752: Error: Inverter 0 unable to read charge window time as charge_start_time or charge_end_time is None
21792 2025-08-27 14:10:10.715030: Error:
21791 2025-08-27 14:10:10.714828: Info: record_status Error: Exception raised
21789 ValueError
21788 raise ValueError

C
#1501 c2ushe2

[unknown] I updated part of Home Assistant and then Predbat threw a bunch of exception errors. Did a full reboot so that everything restarted and Predbat gradually picked up all it needed and was happy again.

Z
#1502 Zakalwe

[unknown]

Yeah, I've rebooted a dozen times and its still borked.

#1503 PianSom

Zakalwe
I'd be looking first at GivTCP here. What do those logs say?

M
#1504 Mouton

[unknown] GivTCP 3.2 has recently been released - coincidence?

Z
#1505 Zakalwe

[unknown]
I didn't upgrade to the latest version before it borked itself.

I took a gamble yesterday and did the GivTCP upgrade. A whole pile of reboots later and still no Predbat plan (I have found that I have to do multiple reboots to get it working). I left it in disgust, then came back a couple of hours later and, hey presto, the Predbat plan had appeared.

Go figure. I've no idea what caused it to fall over in the middle of the night and I've no idea what brought it back online.

K
#1506 KamenMacKay

[unknown] Awesome sauce! I took the liberty of throwing this at Claude so it could make it into one automation. I've tested it by changing the drop-down from Predbat-led to Octopus-led and it behaves as expected (octopus-led prods octopus into generating a smart plan which is then reflected in Predbat) and Predbat-led disables smart charging (as seen in the Octopus app) and plans its own charge slot for the car. I went to the hassle of getting Givenergy to enable local control of the car charger through givtcp and so I'll paste what I have here for future Givenergy evc owners

`alias: Car charging control - Combined Octopus + Predbat management
description: >-
Combined automation that handles: 1. Switching between Octopus-led and
Predbat-led charging modes 2. Managing zappi charger states based on plug
status when Predbat-led 3. Managing zappi charger states based on Predbat
charging slots

On startup or unknown status, mode is determined by Octopus Intelligent Smart
Charge setting
triggers:

  • trigger: state
    entity_id: input_select.car_charge_control
    id: mode_change
  • trigger: homeassistant
    event: start
    id: startup
  • trigger: state
    entity_id: binary_sensor.predbat_car_charging_slot
    to: "on"
    id: charging_slot_on
  • trigger: state
    entity_id: binary_sensor.predbat_car_charging_slot
    to: "off"
    id: charging_slot_off
  • trigger: state
    entity_id: sensor.givevc_11288853519270_connection_status
    id: plug_status_change
    conditions: []
    actions:
  • choose:
    • conditions:
      • condition: trigger
        id: mode_change
        • condition: state
          entity_id: input_select.car_charge_control
          state: Octopus-led
          sequence:
        • action: switch.turn_on
          target:
          entity_id: switch.predbat_octopus_intelligent_charging
          alias: Put Predbat into Octopus-led mode
          data: {}
        • action: select.select_option
          data:
          option: Ready
          target:
          entity_id: select.givevc_11288853519270_charge_control
          alias: Put GivEV into Ready mode
        • action: switch.turn_on
          target:
          entity_id: switch.octopus_energy_a_c8d27ff0_intelligent_smart_charge
          alias: Put Octopus into Smart Charge mode
          data: {}
      • conditions:
        • condition: trigger
          id: mode_change
        • condition: state
          entity_id: input_select.car_charge_control
          state: Predbat-led
          sequence:
        • action: switch.turn_off
          target:
          entity_id: switch.predbat_octopus_intelligent_charging
          alias: Put Predbat into non-Octopus mode
          data: {}
        • action: switch.turn_off
          target:
          entity_id: switch.octopus_energy_a_c8d27ff0_intelligent_smart_charge
          alias: Put Octopus into non-Smart Charge mode
          data: {}
        • alias: If EV is Plugged then zappi to Stopped
          if:
          • condition: state
            entity_id: sensor.givevc_11288853519270_connection_status
            state: EV Connected
            then:
          • action: select.select_option
            data:
            option: Stop
            target:
            entity_id: select.givevc_11288853519270_charge_control
            alias: Move GivEV to Stop
      • conditions:
        • condition: or
          conditions:
          • condition: trigger
            id: startup
          • condition: and
            conditions:
            • condition: trigger
              id: mode_change
            • condition: or
              conditions:
              • condition: state
                entity_id: input_select.car_charge_control
                state: unknown
              • condition: state
                entity_id: input_select.car_charge_control
                state: unavailable
                sequence:
        • choose:
          • conditions:
            • condition: state
              entity_id: switch.octopus_energy_a_c8d27ff0_intelligent_smart_charge
              state: "off"
              sequence:
            • action: input_select.select_option
              data:
              option: Predbat-led
              target:
              entity_id: input_select.car_charge_control
              alias: Set Car charge Control to Predbat-led
            • alias: If EV is Connected then zappi to Stopped
              if:
              • condition: state
                entity_id: sensor.givevc_11288853519270_connection_status
                state: EV Connected
                then:
              • action: select.select_option
                data:
                option: Stop
                target:
                entity_id: select.givevc_11288853519270_charge_control
                alias: Move GivEV to Stop
          • conditions:
            • condition: state
              entity_id: switch.octopus_energy_a_c8d27ff0_intelligent_smart_charge
              state: "on"
              sequence:
            • action: input_select.select_option
              data:
              option: Octopus-led
              target:
              entity_id: input_select.car_charge_control
              alias: Set Car charge control to Octopus-led
            • action: select.select_option
              data:
              option: Ready
              target:
              entity_id: select.givevc_11288853519270_charge_control
              alias: Put GivEV into Ready mode
      • conditions:
        • condition: trigger
          id: charging_slot_on
        • condition: state
          entity_id: input_select.car_charge_control
          state: Predbat-led
          sequence:
        • action: select.select_option
          data:
          option: Start
          target:
          entity_id: select.givevc_11288853519270_charge_control
          alias: Move GivEV to Start
      • conditions:
        • condition: trigger
          id: charging_slot_off
        • condition: state
          entity_id: input_select.car_charge_control
          state: Predbat-led
          sequence:
        • action: select.select_option
          data:
          option: Stop
          target:
          entity_id: select.givevc_11288853519270_charge_control
          alias: Move GivEV to Stop
      • conditions:
        • condition: trigger
          id: plug_status_change
        • condition: state
          entity_id: input_select.car_charge_control
          state: Predbat-led
          sequence:
        • choose:
          • conditions:
            • condition: state
              entity_id: sensor.givevc_11288853519270_connection_status
              state: EV Connected
              sequence:
            • action: select.select_option
              data:
              option: Stopped
              target:
              entity_id: select.myenergi_zappi_XXXXXXXX_charge_mode
              alias: Move zappi to Stopped
          • conditions:
            • condition: state
              entity_id: sensor.givevc_11288853519270_connection_status
              state: EV Disconnected
              sequence:
            • action: select.select_option
              data:
              option: Eco+
              target:
              entity_id: select.myenergi_zappi_XXXXXXX_charge_mode
              alias: Move zappi to Eco+
              mode: single
              `
#1508 PianSom

KamenMacKay
Top tip - when pasting blocks of code start and end with three back-ticks

Also, looks like you have some leftover zappi code towards the end.

K
#1509 KamenMacKay

[unknown] Yah, I only saw that (bad code formatting and the zappi references) after I posted it but it appears I can't edit or delete this post so I'm looking into that but thanks anyways!

B
#1511 browellm

Seeing a few errors popping up myself today

2500	2025-08-29 18:00:05.712578: Error: Traceback (most recent call last):
2499	2025-08-29 18:00:05.710739: Error: Exception raised 'entity_id'
2357	2025-08-29 17:55:05.166572: Error: 'entity_id'
2356	2025-08-29 17:55:05.166475: Info: record_status Error: Exception raised 'entity_id'
2354	KeyError: 'entity_id'

Which is also seems to stop a couple of my charts being rendered

Traceback (most recent call last): File "/config/predbat.py", line 1522, in run_time_loop self.update_pred(scheduled=True) File "/config/predbat.py", line 691, in update_pred recompute = self.calculate_plan(recompute=recompute) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/plan.py", line 1073, in calculate_plan self.web_interface.history_update() File "/config/web.py", line 99, in history_update self.compare_hist[id]["cost"] = self.base.history_attribute(self.base.get_history_wrapper(result["entity_id"], 28), daily=True, pounds=True) ~~~~~~^^^^^^^^^^^^^ KeyError: 'entity_id'

B
#1512 browellm

[unknown] resolved with a full HAOS reboot.

#1515 Hook

Anything changed with predbat and IOG? Doesn’t seem to be picking up smart slots and charging the battery anymore. I’ve been on agile for a while.

#1516 Hook

Did the recent bottlecap Dave update change anything?

#1517 PianSom

Hook
Not here

#1518 Hook

https://predbat.com/ Taking on beta testers at the moment Trefor has licensed a cloud version for those who don't host their own HA.

T
#1519 TX200

Anyone noticed the units for solar PV now have changed?

I decided to delete the previous statistics as I assume previous values of "now" aren't that handy.

The other option was convert the unit but not the value, which seemed wrong!

B
#1520 browellm

Some new tablecard options have popped up. I'm trying to get this going
https://github.com/pacemaker82/PV-Card-Preview

However having a fail at the moment and can't read or pinpoint the error in the .yaml

If you decide to try this and get it going let me know if you changed anything about the sensors from the defaults. They all seem to be present in my system

K
#1521 KamenMacKay

Has anyone successfully managed to run Predbat and PredAi in a docker-compose configuration? My pi4 is a tad slow for it and I do have a nuc I could run it on so then I don't have to buy new equipment. I'm having a go at it with Claude but if somebody has something already working...

#1523 PianSom

Sorry, that’s predai

I’ve been running predbat in Docker for … ages

K
#1524 KamenMacKay

PianSom Care to share your docker config for predbat? I played with predai for an hour or so but the predai code is hardcoded to reach out to the local supervisor in HAOS (I guess?). I tried patching it but to no avail. Lots of rainy days coming up so I'll keep poking at it...

#1525 PianSom

KamenMacKay
It's not very exciting ...

  hass:
    container_name: hass
    image: homeassistant/home-assistant:latest
    volumes:
      - /data/docker/hass:/config
# next line added to allow for predbat/givtcp restart from hass
      - /var/run/docker.sock:/var/run/docker.sock
    environment:
      - TZ=${TZ}
      - /etc/localtime:/etc/localtime:ro
    restart: unless-stopped
    privileged: true
    ports:
      - "8123:8123"
K
#1526 KamenMacKay

[unknown] Oh, I meant your docker-compose config for Predbat or are you running a separate home-assistant instance in docker and then running predbat through that solely for the purpose of just running predbat and nothing else?

#1527 PianSom

KamenMacKay
Of course you did. How stupid of me.

It's not any more interesting, I'm afraid. I'm not sure the depends_on is either necessary or useful. The port map is a personal preference.

  predbat:
    container_name: predbat
    image: nipar44/predbat_addon:latest
    restart: unless-stopped
    environment:
      - TZ=${TZ}
    depends_on:
      givtcp3:
        condition: service_started
      hass:
        condition: service_started
    volumes:
      - /data/docker/predbat/config:/config
      - /etc/localtime:/etc/localtime:ro
    ports:
      - 8045:5052
T
#1528 TX200

I'm back!!!

Requested a switch to agile as it looks like the weather won't be great for intelligent Octopus Flux over the next 10 days and presumably beyond apart from the odd few days.

So I've disconnected octopus from the app and turned PredBat back on.

Just waiting for the emails from octopus to accept the switches (agile plus outgoing flat rate).

I've put an override in for the export for now (yaml config, 15p).

Did contemplate putting overrides in for the import too, but as long as I avoid the 4-7pm period I think that's enough until the tariff updates (import hopefully will be done in a few hours based on previous experience, export perhaps 2 days).

T
#1529 TX200

3hrs later and PredBat knows I'm on agile.

L
#1530 Leeshore

[unknown] I did this a couple of weeks age as compare function suggested agile was better

T
#1531 TX200

There was about 2-3 days where agile was cheaper for me in the last month. But I guess it depends on usage patterns and solar size.

Hoping for a cheap weekend! Looks windy?! 🤞

V
#1532 Vestas

TX200 Might be too windy.

Fairly major storm on the way - doubtless there will be a lot of turbines powering down as winds are forecast for over 55mph (cutout speed for most turbines).

T
#1533 TX200

One thing... I'm going to have to block Home Assistant notifications going to my smart watch. PredBat is too chatty.

M
#1534 MikeyHaz

[unknown]

You can turn off the notifications from predbat - but it stops all notifications, not just to the smart watch. It was one of my first predbat modifications once I was confident in it.

#1535 PianSom

TX200
Just point them somewhere else. I have mine going to a Discord channel, so I can see after the event what has been going on.

T
#1536 TX200

Rates heading in the right direction end of tomorrow!

W
#1537 Wavy Davy

Anyone had problems with custom:predbat-table-card not displaying?
Mines suddenly decided not to show.

This is the setup which hasn't changed.

W
#1538 Wavy Davy

Just deleted and re downloaded it and just the same.
Also custom:html-template-card displays ok.

W
#1539 Wavy Davy

Wavy Davy Well it's decided to work now. Didn't change anything, it just started working. Maybe it was just sulking over something.... 🤣

T
#1540 TX200

Anyone ever seen this where predbat compare doesn't compare all the tariffs? Tried a compare now too, still doesn't show.

I'm running v8.24.2 due to the bug in the later versions.

T
#1541 TX200

Upgraded to latest predbat and ran compare now again, no change.

L
#1542 Leeshore

Are the feeds from octopus incorrect in apps.yaml??

T
#1543 TX200

yeah, I think that's the issue - spotted a github issue earlier saying that. I think the flat export rate API URL has changed, plus my flux export name had a -BB in it - doesn't seem to be valid now.

Replacing it and hoping PredBat compare works again (I might need to downgrade again as compare is a bit dodgy in the latest major versions).

G
#1544 geoffreycoan

Hi all, sorry been away doing other things, and somehow haven't been on this thread since June. 110 posts made it a bit daunting, but I have caught up now.

TX200 yes there are a number of issues with the URL's in the compare config, the -BB URL's all stopped working on 1st October.

I have updated the documentation with the correct URLs in my fork: https://github.com/gcoan/batpred/blob/main/docs/compare.md

There are some interesting side effects with the latest predbat version 8.25.5, issues are on git hub but:

  • PV forecast totals not appearing on the PV/PV7 chart
  • attributes missing from predbat.xxxx_power entities
  • predbat turns real time registers on if you have gecloud configured but not enabled
  • daily cost gives wrong values some of the time

But 8.25.4 and .5 do fix the compare and PV charts not working at all which was an issue on 8.25.1-3

#1545 Hook

My battery no longer charges/pauses discharge when I get an off plan IOG slot.
It used to pick it up automatically. I 'think' something changed with the Bottlecap Dave integration.
I've made this change in my apps.yaml, but still no luck. Have I done it right?
octopus_intelligent_slot: 're: (binary_sensor.octopus_energy_a_1b234c5d_intelligent_dispatching)'
octopus_ready_time: 're: (time.octopus_energy_a_1b234c5d_intelligent_ready_time)'
octopus_charge_limit: 're: (number.octopus_energy_a_1b234c5d_intelligent_charge_limit)'

#1546 PianSom

Hook
For the last one I have ..._intelligent_charge_target for the last

I don't recall if this changed in the integration, but it worked for me yesterday ...

G
#1547 geoffreycoan

Hook I've made this change in my apps.yaml, but still no luck. Have I done it right?
octopus_intelligent_slot: 're: (binary_sensor.octopus_energy_a_1b234c5d_intelligent_dispatching)'
octopus_ready_time: 're: (time.octopus_energy_a_1b234c5d_intelligent_ready_time)'
octopus_charge_limit: 're: (number.octopus_energy_a_1b234c5d_intelligent_charge_limit)'

From the template apps.yaml:

  # If you have Octopus intelligent, enable the intelligent slot information to add to pricing
  # Will automatically disable if not found, or comment out to disable fully
  # When enabled it overrides the 'car_charging_planned' feature and predict the car charging based on the intelligent plan (unless octopus intelligent charging is False)
  # This matches either the intelligent slot from the Octopus Plugin or from the Intelligent plugin
  octopus_intelligent_slot: 're:(binary_sensor.octopus_intelligent_slot|re:binary_sensor.octopus_energy_intelligent_dispatching)'
  octopus_ready_time: 're:(time.octopus_energy_([0-9a-z_]+|)_intelligent_target_time)'
  octopus_charge_limit: 're:(number.octopus_energy([0-9a-z_]+|)_intelligent_charge_target)'

Looks like the slot sensor and the charge limit sensor name have changed

You can always check in the predbat log what sensors are being picked up when apps.yaml evaluates. Or look in the web console at the apps.yaml config

#1548 Hook

Cheers, I'll give it a test.

G
#1549 geoffreycoan

In case you hadn’t seen, there are issues with givtcp and HA 2025.10 https://github.com/britkat1980/giv_tcp/issues/421

In short givtcp is using an old method for a couple of HA switches which still work but cause continual errors to appear in the HA log. It will be fixed in the next givtcp release.
Not clear whether this stops givtcp working or not, one person said it does, but the log indicates it’s just a warning.

I’m not upgrading my HA until the givtcp fix comes out

R
#1550 Rbor

[unknown]
These are the lines that I have in my apps.yaml.

  octopus_intelligent_slot: 're:(binary_sensor.octopus_energy([0-9a-z_]+|)_intelligent_dispatching)'
  octopus_ready_time: 're:(time.octopus_energy([0-9a-z_]+|)_intelligent_target_time)'
  octopus_charge_limit: 're:(number.octopus_energy([0-9a-z_]+|)_intelligent_charge_target)'

I can't remember the 'slot' line changing as in templates.apps.yaml. It seems strange that the slot line doesn't include a link to my Octopus account number, as the others do.
I also have target rather than limit in the octopus_charge_limit line (as does @[deleted] above)
In https://bottlecapdave.github.io/HomeAssistant-OctopusEnergy/entities/intelligent/ the line shown is:

binary_sensor.octopus_energy_{{ACCOUNT_ID}}_intelligent_dispatching

I have checked in my predbat.log for the 'slot' and 'limit' lines. I see this where X is for my Octopus account no.:

Regular expression argument octopus_intelligent_slot matched ^(binary_sensor.octopus_energy([0-9a-z_]+|)_intelligent_dispatching)$ with binary_sensor.octopus_energy_X_XXXXXXX_intelligent_dispatching

IOG charging works for me with these 3 lines in my apps.yaml

NOTE Things are not matching up
Documentation has this.
https://springfall2008.github.io/batpred/devices/#octopus-energy
For Octopus Intelligent GO

  octopus_intelligent_slot: 're:(binary_sensor.octopus_energy([0-9a-z_]+|)_intelligent_dispatching)'
  octopus_ready_time: 're:(time.octopus_energy([0-9a-z_]+|)_intelligent_ready_time)'
  octopus_charge_limit: 're:(number.octopus_energy([0-9a-z_]+|)_intelligent_charge_limit)'

I think that limit should be target as the last word in the 3rd line which then agrees with bottlecapdave.
But Predbat uses octopus_charge_limit: at the start.

Rob

R
#1551 Rbor

geoffreycoan From the template apps.yaml:

Hook Cheers, I'll give it a test.

I think there is an issue with the 3 IOG lines in template apps.yaml.

My 3 lines are shown below. They work and are supported by evidence from my predbat.log:

  octopus_intelligent_slot: 're:(binary_sensor.octopus_energy([0-9a-z_]+|)_intelligent_dispatching)'
  octopus_ready_time: 're:(time.octopus_energy([0-9a-z_]+|)_intelligent_target_time)'
  octopus_charge_limit: 're:(number.octopus_energy([0-9a-z_]+|)_intelligent_charge_target)'

Compared with your extract from templates apps.yaml, the 1st line is different.
It seems strange that there is no link in to the account number as with the other 2 lines.
Also the 3rd line finishes with ‘target’ for me (and also for @PianSom)
See also bottlecapdave information here:
https://bottlecapdave.github.io/HomeAssistant-OctopusEnergy/entities/intelligent/

Note that Predbat refers to the 3rd line at the start as octopus_charge_limit.

NOTE Things are not matching up
Documentation has this.
https://springfall2008.github.io/batpred/devices/#octopus-energy

For Octopus Intelligent GO

  octopus_intelligent_slot: 're:(binary_sensor.octopus_energy([0-9a-z_]+|)_intelligent_dispatching)'
  octopus_ready_time: 're:(time.octopus_energy([0-9a-z_]+|)_intelligent_ready_time)'
  octopus_charge_limit: 're:(number.octopus_energy([0-9a-z_]+|)_intelligent_charge_limit)'

I think that limit should be target as the last word in the 3rd line which then agrees with bottlecapdave.
But Predbat uses octopus_charge_limit: at the start.

Rob

L
#1552 Leeshore

[unknown] I've updated and have had no issues

B
#1553 browellm

Could someone remind me the best way to bias the algorithm toward self-consumption a little more? I'm aware there a few levers I can twiddle here that will probably achieve it but I wonder which is 'best'.

I want to tweak it to reduce the amount of "charging paused" slots that Predbat calculates at this time of year and skew it toward keeping the battery topped up.

B
#1554 Boffinboy

Hi All, have been periodically updating Predbat in the background and testing my hair out when my network leads to REST errors and half a day of messing around trying to fix it. I am sure it’s a bug with Unifi kit.

I noticed an update that talks about using GE Cloud for full control - does that mean it’s possible to switch over to GE cloud fully for actual control? I am considering doing that, even if it has other downsides.

B
#1555 Boffinboy

Hi All, have been periodically updating Predbat in the background and tearing my hair out when my network leads to REST errors and half a day of messing around trying to fix it. I am sure it’s a bug with Unifi kit.

I noticed an update that talks about using GE Cloud for full control - does that mean it’s possible to switch over to GE cloud fully for actual control? I am considering doing that, even if it has other downsides.

R
#1556 Rbor

Boffinboy
REST errors have affected many of us.
One option to 'turn off REST' by commenting out the 2 lines in apps.yaml below which instruct predbat to use REST.

  # When set use the REST API rather than HA entity for control, should be more reliable/faster to control
  givtcp_rest:
    - http://homeassistant.local:6345
``` 
The control lines below prefaced by these comments will be used.
  # If not using REST then instead set the Control here (one for each inverter)
  # - you can delete this section if using REST 

I don't use GE Cloud but that could be an alternative to try.

Rob
S
#1557 SteveCook

Rbor
Thanks
This is my YAML. How do i turn off REST please?
Do I just comment out the IP address line?

B
#1558 Boffinboy

Does anyone know if you can have multiple approaches enabled for redundancy? Ie leave it as default but also use GE cloud if communication issues?

Z
#1559 Zakalwe

[unknown]

Same here and it's doing my head in.

Z
#1560 Zakalwe

I'm getting lots of errors...damn thing is falling over every other day.
I've disabled REST and am now getting errors like this:
Error: Exception raised 'NoneType' object has no attribute 'strftime'

WTF is that about?

R
#1561 Rbor

SteveCook Do I just comment out the IP address line?

I comment out the address line and the line above.

I would also restart givTCP after making the change.

Rob

Z
#1562 Zakalwe

Woke up to a half empty battery as Predbst failed to charge last night.
After a couple of good years Im at the stage where I think that I now need to disable Predbst. Im getting too many errors and failures and am spending too long baby-sitting it.

Shame, but I think that it's trying too hard and has become unstable as it grows in complexity.

W
#1563 Wavy Davy

I've also been getting lots of rest errors so I've disabled it and will see what happens.
Also have had this error showing on the predbat status for a week or two now.


Anyone got an idea how to get rid of it?

W
#1564 Wavy Davy

I've also been getting lots of rest errors so I've disabled it and will see what happens.
Also have had this error showing on the predbat status for a week or two now.


Anyone got an idea how to get rid of it?

#1565 Hook

Fixed it!

octopus_intelligent_slot: 're:(binary_sensor.octopus_intelligent_slot|re:binary_sensor.octopus_energy_intelligent_dispatching)'
octopus_ready_time: 're:(time.octopus_energy_([0-9a-z_]+|)_intelligent_target_time)'
octopus_charge_limit: 're:(number.octopus_energy([0-9a-z_]+|)_intelligent_charge_target)'

Now picking up the slots.

B
#1566 Boffinboy

Zakalwe I get similar. This is why I was thinking of using the giv cloud approach

Z
#1567 Zakalwe

If I comment out these lines:

I get this error:
Error: Exception raised 'NoneType' object has no attribute 'strftime'
And I get "Null" in the Predbat plan.

G
#1568 geoffreycoan

Hook Fixed it!

  octopus_intelligent_slot: 're:(binary_sensor.octopus_intelligent_slot|re:binary_sensor.octopus_energy_intelligent_dispatching)'
  octopus_ready_time: 're:(time.octopus_energy_([0-9a-z_]+|)_intelligent_target_time)'
  octopus_charge_limit: 're:(number.octopus_energy([0-9a-z_]+|)_intelligent_charge_target)'

thanks

before I start changing the templates to match, in Octopus integration 17.0.0 the name of the intelligent despatching sensor has changed to include the device id so this pattern match won’t work https://github.com/springfall2008/batpred/issues/2754

Anyone upgraded and can advise what the new intelligent dispatching sensor id is?

The REST errors several are experiencing. I think it is some incompatibility between the inverter data and givtcp (it’s not directly a predbat issue). There are some circumstances where the inverter returns data that givtcp doesn’t like, and it rejects it, this manifests as Predbat getting a REST error.

I get it all the time and cannot use REST at all as a result.

The workaround is to comment out the givtcp_rest line and the following line/lines with the HA server name and port in.

BUT in order for this to work then predbat needs to communicate with givtcp via the Home Assistant entities. So all of the other inverter configuration lines in apps.yaml (the ones with geserial in) need to be uncommented out and need to correctly point to the right givtcp entities.
As long as this part of apps.yaml is configured correctly then the REST commenting out will mean predbat carries on directly talking to your inverter via givtcp.

As an alternative, it has been an option for a while, but predbat can talk to your inverter via the GivEnergy cloud. Trefor has been fixing bugs and making improvements to this recently so perhaps this is why it’s more visible.
Details in the apps.yaml documentation but you basically create an API key for predbat in the givenergy portal and configure that in apps.yaml.

This then means you don’t need givtcp at all, and for those on newer inverters (3 phase, high voltage stackable hybrids) that are not yet fully supported by givtcp, it could give a way to use predbat.

The primary advantage is no givtcp, so simpler HA install.
Primary disadvantage is that everything to communicate with your inverter now goes via the GivEnergy cloud not local, so all commands take a longer round trip, it relies on your internet and inverters being online, and there is less granularity on things like house load, PV generation, etc.

Z
#1569 Zakalwe

[unknown] Primary disadvantage is that everything to communicate with your inverter now goes via the GivEnergy cloud not local, so all commands take a longer round trip, it relies on your internet and inverters being online, and there is less granularity on things like house load, PV generation, etc.

Thanks for taking the time to share the knowledge Geoffrey. Having to rely on Internet Cloud data is contrary to the aims of Home Assistant, I feel.

#1570 Hook

geoffreycoan

I updated to 17 before I got it working.

Z
#1571 Zakalwe

geoffreycoan BUT in order for this to work then predbat needs to communicate with givtcp via the Home Assistant entities. So all of the other inverter configuration lines in apps.yaml (the ones with geserial in) need to be uncommented out and need to correctly point to the right givtcp entities.
As long as this part of apps.yaml is configured correctly then the REST commenting out will mean predbat carries on directly talking to your inverter via givtcp.

geoffreycoan BUT in order for this to work then predbat needs to communicate with givtcp via the Home Assistant entities. So all of the other inverter configuration lines in apps.yaml (the ones with geserial in) need to be uncommented out and need to correctly point to the right givtcp entities.
As long as this part of apps.yaml is configured correctly then the REST commenting out will mean predbat carries on directly talking to your inverter via givtcp.

If I disable REST then I am getting all sorts of errors (as above). If I enable it, then I randomly get errors with Predbat "freezing" and GivTCP not updating (which seems to tally with what you said). Or the Predbat plan has no pricing info in it.

My apps.yaml is configured like this:

S
#1572 SteveCook

Rbor I comment out the address line and the line above.

I would also restart givTCP after making the change.

Rob

Thanks. I did that and now have Zero errors in my log

G
#1573 geoffreycoan

Wavy Davy Also have had this error showing on the predbat status for a week or two now.


Anyone got an idea how to get rid of it?

sounds like a problem with your energy rates configuration. What do you have in apps.yamlm is it a manual rate bands configuration?

G
#1574 geoffreycoan

Zakalwe thanks, I haven't checked them line by line, but your givtcp entity expressions all look OK.

You said you were getting an error:

Error: Exception raised 'NoneType' object has no attribute 'strftime'

Couple more things to check. Be useful if I can see the context of some more lines before the error to narrow down what predbat was trying to read when it errored.

What do you have set for the geserial line in apps.yaml, and what inverter type do you have (because there are specific instructions for some inverters for this the regular expression that works out the serial number to work properly).

Worth looking in the predbat web console on what it says for apps.yaml, that is a good place to look for potential configuration errors.

Another possible area is the battery pause lines immediately after the bit you copied in, are these commented in or out, some early inverters don't support battery pause mode, or don't support it fully.

Boffinboy Does anyone know if you can have multiple approaches enabled for redundancy? Ie leave it as default but also use GE cloud if communication issues?

unfortunately not really. If you have REST configured then predbat will fallback to non-REST (using the HA entities) if REST fails, but if you configure a GE cloud key it will use that all the time

browellm Could someone remind me the best way to bias the algorithm toward self-consumption a little more? I'm aware there a few levers I can twiddle here that will probably achieve it but I wonder which is 'best'.

I want to tweak it to reduce the amount of "charging paused" slots that Predbat calculates at this time of year and skew it toward keeping the battery topped up.

there isn't really a magic bullet. things you can try:

  • increasing best soc keep and best soc keep weighting, to tell predbat to retain more in the battery in case its needed for unexpected load. This can have the consequence of charging when there's still plenty in the battery so I personally don't use this
  • increasing load scaling to weight today's house load higher than the history might suggest. I use 1.05 to do this
  • you can turn set charge freeze or set export freeze off, e.g. in an automation for some periods of the day/night so predbat can't use this. Usually charge freeze appears overnight when rates are such that its cheaper to use off grid than the battery, but not worth charging the battery. Export freeze appears in the day when the battery is held and solar is exported
B
#1575 browellm

[unknown] Thank you, I had forgotton charge_freeze and export_freeze were switches.

G
#1576 geoffreycoan

[unknown] another thing you can change to make the plan more pessimistic is to increase input_number.predbat_pv_metric10_weight. This is the weighting applied to the PV10 PV generation vs the PV50 forecast. With this protracted overcast high pressure I have just changed my metric from 0.15 to 0.35 which should make the PV forecasting more pessimistic and tend to increase the battery level to compensate for poor solar generation

Z
#1577 Zakalwe

[unknown] Couple more things to check. Be useful if I can see the context of some more lines before the error to narrow down what predbat was trying to read when it errored.

Here's some of the error log:
35904 2025-10-12 18:14:43.745392: Info: record_status Error: Exception raised HTTPConnectionPool(host='homeassistant.local', port=8123): Max retries exceeded with url: /api/services (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fbbccb200>: Failed to establish a new connection: [Errno 22] Invalid argument'))
35903 2025-10-12 18:14:43.745164: Error: set_state_wrapper - No HA interface available
35901 requests.exceptions.Connect ionError: HTTPConnectionPool(host='homeassistant.local', port=8123): Max retries exceeded with url: /api/services (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fbbccb200>: Failed to establish a new connection: [Errno 22] Invalid argument'))
35900 raise ConnectionError(e , request=request)
35871 urllib3.exceptions.MaxRetry Error: HTTPConnectionPool(host='homeassistant.local', port=8123): Max retries exceeded with url: /api/services (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fbbccb200>: Failed to establish a new connection: [Errno 22] Invalid argument'))
35869 raise MaxRetryError(_po ol, url, reason) from reason # type: ignore[arg-type]
35857 urllib3.exceptions.NewConne ctionError: <urllib3.connection.HTTPConnection object at 0x7fbbccb200>: Failed to establish a new connection: [Errno 22] Invalid argument
35856 raise NewConnectionErro r(
35834 OSError: [Errno 22] Invalid argument
35826 2025-10-12 18:14:43.737639: Error: Traceback (most recent call last):
35825 2025-10-12 18:14:43.709266: Error: Exception raised HTTPConnectionPool(host='homeassistant.local', port=8123): Max retries exceeded with url: /api/services (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fbbccb200>: Failed to establish a new connection: [Errno 22] Invalid argument'))
35808 2025-10-12 18:10:11.070241: Error: 'NoneType' object has no attribute 'strftime'
35807 2025-10-12 18:10:11.069839: Info: record_status Error: Exception raised 'NoneType' object has no attribute 'strftime'
35805 AttributeError: 'NoneType' object has no attribute 'strftime'
35795 2025-10-12 18:10:11.038253: Error: Traceback (most recent call last):
35794 2025-10-12 18:10:11.032235: Error: Exception raised 'NoneType' object has no attribute 'strftime'
35730 2025-10-12 18:05:30.537949: Error: 'NoneType' object has no attribute 'strftime'
35729 2025-10-12 18:05:30.537753: Info: record_status Error: Exception raised 'NoneType' object has no attribute 'strftime'
35727 AttributeError: 'NoneType' object has no attribute 'strftime'
35717 2025-10-12 18:05:30.510953: Error: Traceback (most recent call last):
35716 2025-10-12 18:05:30.502669: Error: Exception raised 'NoneType' object has no attribute 'strftime'
35650 2025-10-12 18:05:21.546835: Error: Validation of apps.yaml found 6 configuration errors
35633 2025-10-12 18:05:17.559166: Error: Validation of apps.yaml found 6 configuration errors
35581 2025-10-12 18:01:42.801031: Info: record_status Error: Exception raised 'data'
35580 2025-10-12 18:01:42.800850: Error: set_state_wrapper - No HA interface available
35578 KeyError: 'data'
35569 2025-10-12 18:01:42.798188: Error: Traceback (most recent call last):
35568 2025-10-12 18:01:42.793018: Error: Exception raised 'data'
35554 2025-10-12 18:01:14.668863: Error: 'NoneType' object has no attribute 'strftime'
35553 2025-10-12 18:01:14.668653: Info: record_status Error: Exception raised 'NoneType' object has no attribute 'strftime'
35551 AttributeError: 'NoneType' object has no attribute 'strftime'
35541 2025-10-12 18:01:14.639517: Error: Traceback (most recent call last):
35540 2025-10-12 18:01:14.630005: Error: Exception raised 'NoneType' object has no attribute 'strftime'
35477 2025-10-12 18:01:06.096654: Error: Validation of apps.yaml found 7 configuration errors
35458 2025-10-12 18:01:02.703454: Error: Validation of apps.yaml found 7 configuration errors
35223 2025-10-12 17:57:16.701194: Error: 'NoneType' object has no attribute 'strftime'
35222 2025-10-12 17:57:16.700998: Info: record_status Error: Exception raised 'NoneType' object has no attribute 'strftime'
35220 AttributeError: 'NoneType' object has no attribute 'strftime'
35210 2025-10-12 17:57:16.675057: Error: Traceback (most recent call last):
35209 2025-10-12 17:57:16.666660: Error: Exception raised 'NoneType' object has no attribute 'strftime'
35202 2025-10-12 17:57:16.642161: Error: Exception raised HTTPConnectionPool(host='homeassistant.local', port=6345): Max retries exceeded with url: /readData (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fb074af30>: Failed to establish a new connection: [Errno 22] Invalid argument'))
35191 2025-10-12 17:57:16.544740: Error: Exception raised HTTPConnectionPool(host='homeassistant.local', port=6345): Max retries exceeded with url: /readData (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fb074a330>: Failed to establish a new connection: [Errno 22] Invalid argument'))
35134 2025-10-12 17:57:07.549440: Error: Validation of apps.yaml found 7 configuration errors
35115 2025-10-12 17:57:03.361650: Error: Validation of apps.yaml found 7 configuration errors
35064 2025-10-12 17:50:12.217998: Error: 'NoneType' object has no attribute 'strftime'
35063 2025-10-12 17:50:12.217801: Info: record_status Error: Exception raised 'NoneType' object has no attribute 'strftime'
35061 AttributeError: 'NoneType' object has no attribute 'strftime'

[unknown] What do you have set for the geserial line in apps.yaml, and what inverter type do you have (because there are specific instructions for some inverters for this the regular expression that works out the serial number to work properly).
I have the inverter serial number in geserial. Gen 1 HY5 inverter
Again, this has been working fine for ages

[unknown] Worth looking in the predbat web console on what it says for apps.yaml, that is a good place to look for potential configuration errors.
There's six errors in apps.yaml:

[unknown] Another possible area is the battery pause lines immediately after the bit you copied in, are these commented in or out, some early inverters don't support battery pause mode, or don't support it fully.

Pause mode, pause start/end time and target SOC are all commented out.

G
#1578 geoffreycoan

Zakalwe thanks, an impressive series of errors and crashes from predbat

I see your problem from the screenshot, the entity names that predbat is looking for (from apps.yaml) are, e.g.

sensor.givtcp_SD2137G122_soc_kwh but this doesn’t exist (hence in red with a question mark).

Entity names in HA are entirely in lower case so it should be

sensor.givtcp_sd137g122_soc_kWh

In your apps.yaml fragment I can see that the sensor names are being evaluated based upon geserial. Predbat should auto detect what the serial number is, but, per the installation instructions if you have a 3 phase inverter or an AIO then you have to manually set geserial in apps.yaml.

You said that you have manually set geserial but I think you have put it in upper case not lower case as predbat needs it to be which is why your apps.yaml is throwing errors and why predbat won’t work. You could just leave the auto detect (from the template apps.yaml) in for a Gen 1 hybrid, or change it to lower case.

Z
#1579 Zakalwe

[unknown] You said that you have manually set geserial but I think you have put it in upper case not lower case as predbat needs it to be which is why your apps.yaml is throwing errors and why predbat won’t work.

Which is why I bloody hate yaml. Indentation, no caps..... yada yad yada
:-)

I have changed it to lower case and it made zero difference to the errors that Predbat is reporting:

#1580 ChrisLav

You still have an upper-case 'G' in the entity! Disclaimer: I know absolutely nothing about Predbat or yaml but GC seems to know his stuff...

Z
#1581 Zakalwe

[unknown]

I am a numpty!

Z
#1582 Zakalwe

Right, ever onwards.

I corrected the lower case issue in the inverter name. Still getting the same 6 errors though,

S
#1583 SteveCook

have you a typo how you spell inverter? There is no "o

S
#1584 SteveCook

The lines that are OK (blue) the text is all underlined.
Your errors (red) are not underlined

Z
#1585 Zakalwe

[unknown]

Interesting spot!

I found one mis-spelling in here. I can't ever remember touching these, so this must have been in there from the start.

charge_rate:
- number.givtcp{geserial}battery_charge_rate
discharge_rate:
- number.givtcp{geserial}battery_discharge_rate
battery_power:
- sensor.givtcp{geserial}battery_power
pv_power:
- sensor.givtcp{geserial}pv_power
load_power:
- sensor.givtcp{geserial}load_power
soc_kw:
- sensor.givtcp{geserial}soc_kwh
soc_max:
- sensor.givtcp{geserial}battery_capacity_kwh
reserve:
- number.givtcp{geserial}battery_power_reserve
inverter_mode:
- select.givtcp{geserial}mode
inverter_time:
- sensor.givtcp{geserial}inverter_time
charge_start_time:
- select.givtcp{geserial}charge_start_time_slot_1
charge_end_time:
- select.givtcp{geserial}charge_end_time_slot_1
charge_limit:
- number.givtcp{geserial}target_soc
scheduled_charge_enable:
- switch.givtcp{geserial}enable_charge_schedule
scheduled_discharge_enable:
- switch.givtcp{geserial}enable_discharge_schedule
discharge_start_time:
- select.givtcp{geserial}discharge_start_time_slot_1
discharge_end_time:
- select.givtcp{geserial}discharge_end_time_slot_1

G
#1586 geoffreycoan

SteveCook have you a typo how you spell inverter? There is no "o

no, that's the way the default sensor name comes from GivTCP.

It was a typo in GivTCP (or possibly the original GivEnergy code that formed GivTCP). I spotted it ages ago and went to raise it as an issue, then found in the givtcp documentation that this was being retained as spelt this way so that people didn't have to deal with a change in entity name.

Anyway, back to Zakalwe problem, it is weird that some entity names (e.g. target soc) have matched OK, others (e.g. soc_kwh) have not. Very weird.

The default givtcp template (which as far as I can see you are using) should find the entity names produced by givtcp. So either the entity names are not created, they've been renamed, or they're disabled.
We need to track down the correct entity names,

In HA, go to Devices & Services / Entities tab and search for part of the entity name that is trying to be matched, e.g. searching for 'charge_start_time' on mine brings up:

I have two inverters and I have changed the prefix on mine from the default 'givtcp' and 'givtcp2' to 'g' and 'h', so you see six results for me, 3 from each inverter, the charge start time for slot 1 and discharge start time for slots 1 and 2 (and note the no entry against slot 2 which I have disabled).

Let's see what you get when you try similar

W
#1587 Wavy Davy

[unknown] Geoff, Not sure which bit of apps.yaml you mean.
Can you point me to the correct entry you mean?

G
#1589 geoffreycoan

Wavy Davy your error is coming from a bad end date on your energy rates, how have you defined these in apps.yaml?

Z
#1590 Zakalwe

geoffreycoan It was a typo in GivTCP (or possibly the original GivEnergy code that formed GivTCP). I spotted it ages ago and went to raise it as an issue, then found in the givtcp documentation that this was being retained as spelt this way so that people didn't have to deal with a change in entity name.

Yep.....I spotted that and thought I was going mad!

geoffreycoan Anyway, back to Zakalwe problem, it is weird that some entity names (e.g. target soc) have matched OK, others (e.g. soc_kwh) have not. Very weird.

The default givtcp template (which as far as I can see you are using) should find the entity names produced by givtcp. So either the entity names are not created, they've been renamed, or they're disabled.
We need to track down the correct entity names,

Right, with people's help on here (thank you all!), a mixture of cursing, swearing and good luck, I've managed to remove all of the errors in apps.yaml. A couple were undoubtedly caused by the use of capitals, which I was totally unaware of. Secondly, I re-ran the GivTCP configuration tool and renamed the Inverter Friendly Name from "GivTCP" to "givtcp". I've no idea if that makes any difference, but it cant do any harm.
The other thing that I spotted was an error in the Octopus_intelligent_slot. The Ohme naming was incorrect, which stemmed from an earlier error in the documentation.

Now that it seems to be behaving itself (though I am not sure that I fully trust it at the moment) I've gone back and disabled REST by commenting out these lines

Previously this would result in all sorts of errors and instability, probably because it wasn't reading GivTCP correctly. It now (touch wood) seems to be behaving itself.

Thanks again to everyone for putting up with my frustrations with this system. I am not a coder and have zero interest in becoming one, so this yaml malarkay is very frustrating.

W
#1591 Wavy Davy

looking at my app.yaml I cant see energy rates defined.anywhere.
maybe that's the problem.

W
#1592 Wavy Davy

Geoff I think you have the correct diagnosis.
Looking at the predbat logs there are these errors many times.
2025-10-13 18:35:01.630575: Warn: record_status Bad start time 2025-01-05:00 provided in energy rates.
2025-10-13 18:55:55.665046: Completed run status Demand with Errors reported (check log)

#1594 Jase1703

[unknown] that’s a bit outdated, technology has moved on a bit, most offshore turbines have High Wind Ride Through which keeps them running in higher winds and allows them to cut in and out much quicker. Can deal with 30m/s or 67mph sustained wind speed before de rating. True that in early days they would stop and only come back online when the wind dropped.

W
#1595 Wavy Davy

Geoff,
Have gone through the setup on the energy rates link.
I have put the energy direct details in my apps.yaml.
I did have the Octopus Energy integration set up already, but have checked the details which seem correct.
All the listed events are enabled.
Still have the status error

G
#1596 geoffreycoan

Wavy Davy it sounds like a misconfiguration still

its saying ‘bad start time 2025-01-05:00 provided in energy rates’. That looks like a date and time squashed together

can you try searching for that string 2025-01-05 in your apps.yaml, or 05:00

check you don’t have any rates_import_override or _export_override also configured as well as Octopus direct or the Octopus Integration.

W
#1597 Wavy Davy

[unknown]
I don't have either strings but I do have an override, but not 2025-01 etc.

rates_export_override:

  • date: '2023-09-10'
    start: '14:00:00'
    end: '14:30:00'
    rate: 112
    load_scaling: 0.8

Will disable and see if that cures it

W
#1598 Wavy Davy

Nope, just the same.
Will leave that override commented out though, as I don't see it being used now.

W
#1599 Wavy Davy

Meant to add there was also an import override which i also disabled. same result

G
#1600 geoffreycoan

Wavy Davy very strange. Can you attach a snippet of your logfile showing the lines coming up to the error being reported, or the whole logfile, and your apps.yaml (you’ll need to rename to apps.txt) so I can try to work out what is happening.

W
#1601 Wavy Davy
apps.txt
20kB

still trying to upload the predbat log

W
#1602 Wavy Davy

Geoff
this is part of it, will try to get the rest tomorrow.

predbat.pdf
151kB
M
#1603 ma9mwah

I currently run prebat to look after my Solar / AIO system and its works 100%. I am going to be installing a EV charger soon for my new EV. I have a couple of general questions.

I have the option to have the power on the load or grid side of the gateway. If I have it on the load side, is predbat clever enough to detect that the car is charging (mostly likely on IOG) and charge the battery at the same time? or would I need additional automations to sort that out?

Does predbat assume that if a IOG slot is schedule then it will happen, or does it wait until it sees the car charging?

#1604 PianSom

ma9mwah If I have it on the load side, is predbat clever enough to detect that the car is charging (mostly likely on IOG) and charge the battery at the same time? or would I need additional automations to sort that out?

Yes, Predbat will infer that a charge is taking place from the state of the Octopus integration sensor (the Intelligent Dispatching binary_sensor). However, you can also specify a sensor if you wish (see the manual https://springfall2008.github.io/batpred/car-charging/ car_charging_now)

ma9mwah Does predbat assume that if a IOG slot is schedule then it will happen, or does it wait until it sees the car charging?

For planning purposes it will assume the charge schedule (the Attributes of the binary_sensor) which is returned by Octopus. Note that, in my experience at least, this changes frequently and at the last minute, so things can very occasionally get out of whack for a short period. It doesn't look at whether the car is charging; rather it looks at the value returned by the Octopus integration to see if "now" is a cheap slot (ie the state of the binary_sensor mentioned above).

FWIW I use both Octopus-led and Predbat-led charging. I use Octopus-led if I am trying to pick up some extra slots for recharging my house batteries. I use Predbat-led to optimise my overnight battery management, and avoid the last minute changes.

T
#1605 TX200

Well, that's a bit of a fail, not much sun, sitting at 27% battery

Just enough to cook dinner in the air fryer hopefully!

I'd have hoped for some grid charging in the absence of the sun to make sure it gets through the evening peak!

G
#1606 geoffreycoan

Wavy Davy thank you, that’s enough for me to be going with ….

Not part of the problem, but I did notice:

2025-10-14 17:50:45.671612: Find charge curve with sensors
sensor.givtcp_sa2244g426_soc_kwh and
number.givtcp_sa2244g426_battery_charge_rate and predbat.status and
sensor.givtcp_sa2244g426_battery_power
2025-10-14 17:50:46.313944: Find charge curve has 3.0 days of data, max days 3
2025-10-14 17:50:46.328693: Note: Cannot find battery charge curve (no final
curve), one of the required settings for predbat.status, soc_kw, battery_power and
charge_rate do not have history, check apps.yaml

Which is strange. Do you purge the history from these sensors? predbat should normally be able to read the history and create the battery charge curve, which when produced you can copy into apps.yaml to stop it trying to create it each time it runs

Anyway, onto your error

From the PDF, bottom of page 21 predbat is adding your historic rates_import_override, and that works OK, but then on p22 it tries to add the rates_export_override and you get:

2025-10-14 17:55:02.060853: Note: API Overridden arg rates_export_override value
[{'date': '2025-01-05', 'start': '2025-01-05', 'end': '16:49:00', 'rate_increment': '1'}]
index 0
2025-10-14 17:55:02.061352: Basic rate API override items for
rates_export_override are [{'index': None, 'value': {'date': '2025-01-05', 'start':
'2025-01-05', 'end': '16:49:00', 'rate_increment': '1'}}]
2025-10-14 17:55:02.061440: Warn: Bad start time 2025-01-05:00 provided in
energy rates
2025-10-14 17:55:02.070294: Warn: record_status Bad start time 2025-01-05:00
provided in energy rates
2025-10-14 17:55:02.070536: Adding rate rates_export_override: {'index': None,
'value': {'date': '2025-01-05', 'start': '2025-01-05', 'end': '16:49:00', 'rate_increment':
'1'}} => 10-14 00:00:00 to 10-15 00:00:00 @ 0.0 date None day_of_week []

Looking at your apps.yaml (thank you) I can see several things wrong with it, and frankly I am a bit surprised that Predbat works at all.

On the “teach people to fish” analogy I am not telling you line buy line what is wrong, but recommend you re-read the section of the documentation on apps.yaml structure https://springfall2008.github.io/batpred/apps-yaml/#warning-appsyaml-file-format watch the linked youtube video and have a good hard look at your config file.

Two clues:

  • indentation
  • commenting things out
W
#1607 Wavy Davy

[unknown] Geoff,
No I don't purge any sensors, but will have a look as you suggest.
I think part of the problem is accumulating changes over time.
anyway will have a look at the doc you linked and the video, see if I can make any sense of it, but doubt I'll have time before the weekend.
Thanks for taking the time to look.

G
#1608 geoffreycoan

Wavy Davy Yes your apps.yaml definitely looks like it has accumulated things over time. The sequence of things is not critical but I can see things have been appended almost a bit randomly in there which is causing some of the indentation problems

You might find it simpler to start from the base GivTCP apps.yaml https://raw.githubusercontent.com/springfall2008/batpred/main/templates/givenergy_givtcp.yaml which contains all the fixes and improvements that have occurred, and reconfigure that to your specific setup. You will need to copy in all the compare entries as well, but again these were changed recently as several Octopus URLs had been retired

If you get completely stuck do come back and share where you are up to and I will of course assist you

S
#1609 SteveCook

Just installed Predbat Core 8.25.12 and had to roll back. The UI would not run, no matter how many restarts and reboots of HA

#1610 PianSom

SteveCook
There's a comment on Facebook with the same issue, resolved by commenting out the 3 GE Cloud lines from apps.yaml

S
#1611 SteveCook

PianSom
Thanks
You make it sound so easy........ha ha
Do i install the update and then comment out the 3 lines using file editor and then restart?

#1612 PianSom

SteveCook
I haven't yet updated myself, and I don't use GE Cloud! 🙂

If you use GE Cloud then don't update. If you don't use it then I suggest you comment out from apps.yaml the following and then do the update:

  ge_cloud_data: false
  ge_cloud_serial: '{geserial}'
  ge_cloud_key: 'xxxx'

Or - like me - wait for the next version!

W
#1613 Wavy Davy

SteveCook

I think I just had the same problem.
Just finished re-writing the apps.yaml file as per Geoffs suggestion, and did the core update.
Now cant get any predbat entities. I don't believe predbat is running.

W
#1614 Wavy Davy

PianSom I had ge cloud enabled so have taken your suggestion and commented out.
Now have everything back, except I have a rest problem and a few others including the original bad start time error.
predbat error logs report "Error: Validation of apps.yaml found 3 configuration errors".
Have to go out in about an hour so will have a quick look but probably have to work on it tomorrow.

S
#1615 SteveCook

PianSom
I dont use GE Cloud for HA as far as I am aware, how would I know?
I have GivTCP3 and GivEnergy local on my HA

#1616 Hook

Just hash out the lines:

#ge_cloud_data: False
#ge_cloud_serial: '{geserial}'
#ge_cloud_key: 'xxxx'

Otherwise it won't start.

G
#1619 geoffreycoan

Inverter register writes

Just under a year ago there was a hoo-hah about the number of inverter register writes being made, with Predbat being singled out (unfairly in my view). Trefor made some changes to Predbat to record how many register writes were being made by predbat, and made some code changes to reduce the number of writes.

GivEnergy introduced "real time control" for those that are making lots and lots of inverter changes (e.g. those with plant systems where they are trying to balance multi-inverters or stop them cross charging), to move most of the inverter registers to volatile rather than non-volatile storage. Impact being that if you turn RTC on then then you're no longer writing repeatedly to flash memory that has a limited life, but side effect that if your inverter ever loses power it forgets a lot of its settings.

More recently givtcp introduced register write counts as well, separated between the normal (non volatile) registers and the safe (volatile) registers if RTC is turned on. The givtcp register writes should therefore be more accurate than the predbat register writes as its givtcp that actually knows what commands get translated to what inverter registers.

Anyway, an update on my register stats....

Since December 2024 when the Predbat register count feature was introduced, I have executed 31,239 writes across my two GivEnergy inverters, and most of this time I have been on Octopus Agile. This equates to an average of 51 register writes per inverter per day, which is well within the GivEnergy recommended limits. I haven't turned RTC on.

I thought I would compare the Predbat count of register writes to the GivTCP count of register writes (again summed across both inverters):

Basically pretty good correlation, only a few days where the givtcp count is slightly higher.

M
#1620 matttheotter

Spotted some odd issues with my parents AIO.

When on Control Charge they get the following plan showing charging but the battery SoC doesn't show it increasing:

When I put it Control Charge & Discharge they get a plan I would expect to see:

M
#1621 matttheotter

[unknown] omg it was my error and I fixed it lol

G
#1622 geoffreycoan

matttheotter potted some odd issues with my parents AIO.

When on Control Charge they get the following plan showing charging but the battery SoC doesn't show it increasing:

that's odd. It looks like its doing a freeze charge overnight, holding the charge at the current level and just running off grid import.

(if you look at the Trefor raw plan rather than the table card reformatted plan would be able to just confirm this)

have you actually let it run in Control Charge mode to see if it does charge overnight and its just a plan display problem, or a plan creation problem? It definitely looks like a bug either way, the overnight charge rate is lower than the export rate so its always better to charge overnight.

If you're worried about leaving your parents with an empty battery, you can set Predbat to control charge mode to confirm the behaviour, and put an automation in to change the mode to Control Charge and Discharge at say 2am to fill the AIO

G
#1623 geoffreycoan

matttheotter omg it was my error and I fixed it lol

what was it you did?

W
#1624 Wavy Davy

Geoff,
I have re-done the apps.yaml and hopefully sorted out the indent and other problems.
It passes the "green tick" test on file editor and also visual studio doesn't show any errors.
However predbat log shows 3 configuration errors are present but doesn't say what they are. the bad start time is also present.
How do I find out what the errors are?
this is a snapshot of the log screen and the apps.yaml file ( on a separate reply).

W
#1625 Wavy Davy
app-yaml.pdf
77kB
G
#1626 geoffreycoan

Wavy Davy the errors in apps.yaml should be highlighted in the predbat web console under the apps tab.

Looking at your apps.yaml PDF, its sometimes difficult to check the indentation of entries which is the problem you had before, so I would double check that as the first thing.

Each sub entry must be indented by two spaces to be considered as the child element of the element above,

so for example,

  load_today:
   - sensor.givtcp_{geserial}_load_energy_today_kwh

looks like it is just 1 space, not two, it should be

  load_today:
    - sensor.givtcp_{geserial}_load_energy_today_kwh

load_today is indented 2 spaces (as its a child of pred_bat at the top
and then ‘- sensor.givtcp_xxxx’ is a further 2 spaces indented (so 4 in total)

some observed bits that look right/wrong

  • inverter_limit value looks correct, 4 spaces
  • export_limit value looks to be 3 spaces
  • inverter_limit_charge and inverter_limit_discharge the values appear to be just 2 spaces indented, not 4, so are not appearing as children of the parent tag
  • car_charging? You have num_cars set to zero which is fine, but have car_charging_planned configured for a zappi or wall box charger, this can be commented out if you don’t have them
  • but car_charging_planned_response you have the tag but then all the values underneath are commented out. This will cause a problem. Comment the header entry out as well if you don’t want it in apps.yaml
  • ditto car_charging_now_response
  • days_previous is set to 14. So you are telling predbat to take your house load prediction from just a single day, 2 weeks ago. Why 2 weeks, why not 1 week ago? Sounds unusual. Most people have a range of days to average things out better
  • if you don’t need them for an automation, comment out export_triggers
  • your octopus compare is using a whole load of old tariff codes that don’t work any more. Get the latest tariff codes from the documentation, and comment out any tariffs you are not interested in, you have a lot of tariffs I suspect you will never use (like Snug)
  • octopus api and account key is mis-indented. If you are using this not the octopus integration then you can comment out the octopus integration rate lines earlier in apps.yaml

Looks much like the prior version TBH ….

M
#1627 matttheotter

[unknown] set best_min_soc to 2kW

W
#1628 Wavy Davy

geoffreycoan
Ok had another go and sorted out your points, but..
Cant get compare to work properly. It seems that anything with an export fixed rate doesn't work.
Have tried using the http: method and also tried
rates_export:
- rate: 15
neither seem to display tariffs which have fixed exports.

at present this is my compare list.

compare-rates.pdf
24kB

Also still have the status error

checking predbat logs it has

2025-10-26 11:20:02.115933: Warn: Bad start time 2025-01-05:00 provided in energy rates
2025-10-26 11:20:02.124301: Warn: record_status Bad start time 2025-01-05:00 provided in energy rates

R
#1629 Rbor

Wavy Davy Some of your tariffs are out of date.
For example, those with BB are old Bulb line.
Check the latest, all listed in documentation:
https://springfall2008.github.io/batpred/compare/#comparing-energy-tariffs
You should be able to paste these into your apps.yaml to replace your list.
Carefully check spacing.

If you run Compare in WebUI straightaway, you will be able to see if this works, although the 'starting time' will be the time of this run.
If this works, the next Compare run just after midnight should run fine.

Rob

R
#1630 Rbor

Wavy Davy Look at givTCP logs also.
Remember that clocks changed and may have affected running overnight.
You may need to restart givTCP followed by Predbat restart.

Also check GE Web portal time.
There is a button for 'Sync time' in 'Accounts'.

Rob

G
#1631 geoffreycoan

Wavy Davy as Rob says, your compare rate URL’s are out of date, get the latest versions from the predbat documentation. Octopus retired a load of rates on 1st October including all the -BB (ex Bulb) ones and the compare stopped working for many people. The correct URLs are in the documentation plus instructions how to find new URLs.

I still don’t quite understand why you are getting this status error on the energy rates, can you post your whole apps.yaml so I can take another look.

W
#1632 Wavy Davy

Rbor Rob, Geoff,
That's the links I used.
All the rates seem to work except Agile export. attached is the compare screen.


will also upload my apps.yaml to a separate post.

W
#1634 Wavy Davy
appsyaml.txt
26kB
R
#1635 Rbor

Wavy Davy The issue seems to be the label you have to the dno region, "H"
You have octopus_region: "H"
In each tariff line, you need to refer to the label in the same way.
Most of the lines use {octopus_region} BUT some use {dno_region}, including:

    - id: 'agile_fixed'
      name: 'Agile import/Fixed export'
      rates_import_octopus_url: 'https://api.octopus.energy/v1/products/AGILE-24-10-01/electricity-tariffs/E-1R-AGILE-24-10-01-{dno_region}/standard-unit-rates/'
      rates_export_octopus_url: 'https://api.octopus.energy/v1/products/OUTGOING-VAR-24-10-26/electricity-tariffs/E-1R-OUTGOING-VAR-24-10-26-{dno_region}/standard-unit-rates/'

You also still have some lines using the old BB bulb lines.
Documentation uses {dno_region}
It doesn't actually matter whether you use {dno_region} or {octopus_region} as long as you are consistent.

You have so many commented out lines, this is difficult to follow.

I recommend that you take a copy of your current apps.yaml.
Then delete the compare tariff lines in your working apps.yaml completely and copy in the documentation lines.
Documentation uses dno_region consistently.
Change the dno region label to point to your region, H, and it should all work.

Hope that gets compare working for you

Rob

W
#1636 Wavy Davy

Rbor thanks Rob, done but no different.
All my references use dno region. Some work others don't.
Have taken all tariffs out except agile import/fixed export and agile import/agile export which I copied from the file.
agile import/agile export works and agile import/fixed export doesn't.
the import line on the agile import/fixed export tariff was different to the other one so I copied the second one to it but again no different.
I just find it so frustrating.

R
#1637 Rbor

Wavy Davy Can you copy the whole compare section from your apps.yaml here:
Copy within ```, i.e
<Insert 3 back ticks>
<COMPARE LINES>
<Insert 3 back ticks>
We will then be able to the code clearly including spacing.
We will get it sorted!

Thanks

Rob

W
#1638 Wavy Davy
  # Tariff comparison feature
  #
  # Adjust this list to the tariffs you want to compare, include your current tariff also
  # DNO region code (see https://energy-stats.uk/dno-region-codes-explained/)
  dno_region: "H"
  compare_list:
    - id: 'current'
      name: 'Agile import/Fixed export'

    - id: 'agile_fixed'
      name: 'Agile import/Fixed export'
      rates_import_octopus_url: 'https://api.octopus.energy/v1/products/AGILE-24-10-01/electricity-tariffs/E-1R-AGILE-24-10-01-{dno_region}/standard-unit-rates/'
      rates_export_octopus_url: 'https://api.octopus.energy/v1/products/OUTGOING-VAR-24-10-26/electricity-tariffs/E-1R-OUTGOING-VAR-24-10-26-H/standard-unit-rates/'
    - id: 'agile_agile'
      name: 'Agile import/Agile export'
      rates_import_octopus_url: 'https://api.octopus.energy/v1/products/AGILE-24-10-01/electricity-tariffs/E-1R-AGILE-24-10-01-{dno_region}/standard-unit-rates/'
      rates_export_octopus_url: 'https://api.octopus.energy/v1/products/AGILE-OUTGOING-19-05-13/electricity-tariffs/E-1R-AGILE-OUTGOING-19-05-13-{dno_region}/standard-unit-rates/'

have done the one with just the 2 tariffs to make it easier

R
#1639 Rbor

PS Did you click on the red 'Compare Now' button in WebUI to get Predbat to recalculate everything from now?

It will take a while to work through each one.

Rob

W
#1640 Wavy Davy

Rob,
Yes, just get no data for fixed export version.

R
#1641 Rbor

This line is wrong!

      rates_export_octopus_url: 'https://api.octopus.energy/v1/products/OUTGOING-VAR-24-10-26/electricity-tariffs/E-1R-OUTGOING-VAR-24-10-26-H/standard-unit-rates/'

The ending should be:

VAR-24-10-26-{dno_region}/standard-unit-rates/'

As I said,
Copy everything from the documentation lines after deleting your original lines!

This 'fixed' line is repeated several times for every 'Fixed Outgoing tariff'

Rob

W
#1642 Wavy Davy

Thanks Rob
it's working now.
Will add the other tariffs shortly, but have to go out for about half hour, so will do it then.

W
#1643 Wavy Davy

I didn't use the calculate now button, what a dummy....

G
#1644 geoffreycoan

Wavy Davy just to add to all the helpful advice given, and yes, clicking compare now to run a compare is critical, otherwise you have to wait for the next scheduled compare that runs at midnight each night

It doesn't matter as Rob says whether you use dno_region, octopus_region, or don't bother and hard code the region codes in yourself, as long as its consistent.

In the YAML the code is set (to H for WavyDavy), and then in the URL it is expanded by the {dno_region}.

Rbor You can do away with this region code expansion, and that's what I've done, I have -A on the end of all my URLs as I am in region A.
You can also test that the URL is correct by directly putting it into a browser, making sure you enter the DNO code. The resultant JSON should (a) appear and (b) not have an end date in the past. That's what was happening for all the -BB codes

Wavy Davy looking at your apps.yaml:

  • suggest you don't set your inverter_limit_charge to 2400, it might be that thats what your inverter actually charges at, but set it to 2600, the inverter maximum and tell predbat that your inverter doesn't charge at full rate by setting input_number.predbat_battery_rate_max_scaling to 0.92. Otherwise your way of doing it Predbat will set your inverter to only charge at 2400 and you'll only get 92% of that figure
    You might set the similar discharge scaling if you get more than 2600W discharge rate. Mine is set to 1.04 as I can get up to 2.9kWh

  • The metric_octopus_import and export look fine (and match mine) and I don't see any other obvious reason in apps.yaml for the continued error. My guess is that its a problem with the Octopus energy integration sensors. Either some of the events that predbat needs to read or some of the entities are mis-named. Have a look at the energy rates documentation https://springfall2008.github.io/batpred/energy-rates/#octopus-energy-home-assistant-integration

  • you have said in the past that you set the Octopus integration up but then you swapped to Octopus direct to try to resolve your energy rates warning. You actually haven't set Octopus direct up correctly.

Your config setting:

    - id: 'iflux'
      name: 'Intelligent Flux import/Export'
      rates_import_octopus_url: 'https://api.octopus.energy/v1/products/INTELLI-FLUX-IMPORT-23-07-14/electricity-tariffs/E-1R-INTELLI-FLUX-IMPORT-23-07-14-{octopus_region}/standard-unit-rates/'
      rates_export_octopus_url: 'https://api.octopus.energy/v1/products/INTELLI-FLUX-EXPORT-23-07-14/electricity-tariffs/E-1R-INTELLI-FLUX-EXPORT-23-07-14-{octopus_region}/standard-unit-rates/'   

      octopus_api_account: ÔXXXXXX
      octopus_api_key: ÔXXXX

has octopus_api_account and api_key indented in line with the iflux entry of the compare configuration, so these config items are being treated as children of iflux which is itself a child of compare_list which is a child of pred_bat at the start of the apps.yaml file

I have said it many many times, I have written it in the documentation, I have linked a youtube video that explains how yaml indentation works, but STILL people get it wrong. Even when I tell them to check the indentation.

As well as this bit being incorrectly indented, double check everything else is indented correctly

W
#1645 Wavy Davy

Geoff, one question, should the entities for the meters include the supply number as well as the meter number
event.octopus_energy_electricity_21e5284972_2000003857896_previous_day_rates (which is what I had) or just the meter number on its own?
I've just tried taking out the supply number but it doesn't seem right.

B
#1646 browellm

I seem to be have a GivTCP-related issue which has happened since moving to 3.4 and I believe the messages about sensor types that HA threw up are something to do with it.,
I have moved on to the dev branch 3.4.14 to see if it helps.

Something has happened with the sensors that PredAI uses/creates

You can see here all OK up to and including 22 Oct then in the early hours of 23rd onwards AI Load Source has gone.
sensor.givtcp_sa2049g040_load_energy_today_kwh_prediction
which I believe is derived from sensor.givtcp_sa2049g040_load_energy_today_kwh

It's already having an impact on my Predbat load forecast which is now very low for the next 24h. I could disable PredAI as a workaround but has anyone else has issues with those sensors that the latest version of GivTCP has changed?

B
#1647 browellm

And as an aside, say I wanted to downgrade to GivTCP 3.3 (or lower) could someone point to where I need to put the source code in the HA folder structure so that the earlier version is recognised as something I can downgrade to?

L
#1648 Leeshore

browellm mine did the same for 24 hours but as now settled down. I would wait for a few days to see if settles. I don’t think it (load energy today sensor) reset correctly at midnight for one night. You may be able to change the values in statistics in developer tools if you wished.

B
#1649 browellm

Leeshore ah thanks. Perhaps hit a perfect storm of new givtcp, octopus free sessions and end of BST. Will see what happens after midnight.

L
#1650 Leeshore

Still getting same errors today so have raised it as an issue on givtcp github page

W
#1651 Wavy Davy

Wavy Davy forget that Geoff, Have checked and the entities seem ok and all have history data.

B
#1652 browellm

Leeshore have commented too. If I could just understand where I would need to drop the v3.2 tar file in Home Assistant for it to be pickked up as a new version, I would downgrade to see if that fixes it.

B
#1653 browellm

OK I've worked out how to install addons locally, but the source code for v3.2 and v3.3 are both v2.4.9

W
#1654 Wavy Davy

Geoff came across this predbat config entry. Not sure if it helps or not.


G
#1655 geoffreycoan

browellm Leeshore there was a fix made by Mark in GivTCP 3.4 to ensure that the XXX today sensors reset at precisely midnight, as they were resetting near to midnight but not precisely, which was causing problems with the Energy dashboard.
I spotted a problem with 3.4 that the load energy sensor had I think the wrong state class and Mark fixed that in 3.4.1

But it looks like with all this somehow he has broken the load energy today sensor, a number of people are reporting that its not resetting at all at midnight.

I personally don't use load energy today, I have my own custom load energy sensor as I have two inverters and the load gets shared between them, so the sensors provided by the inverter are useless to me, which is why I hadn't spotted it, but I too see the load today sensors not resetting.

The only fix is to restore a backup of a previous version of GivTCP, there is no way through the UI to install an old version (that I know of).

You did take a backup of givtcp when upgrading? Or if you have a partial or full HA backup you can restore just that specific add-on.

Wavy Davy Geoff came across this predbat config entry. Not sure if it helps or not.


Dave that is exactly what your energy rates problem is, its an export rate override, but is malformed, the start TIME is set to a date, so no wonder it doesn't work!
Select the value 'off' from the dropdown to turn it off and your persistent problem should go away

Nothing to do with the Octopus sensors

W
#1656 Wavy Davy

geoffreycoan That's sorted that out. Now to start on the other errors the log is showing up.!!

B
#1657 browellm

geoffreycoan HA only keeps the previous version and the problem started in 3.4 so no roll back via that route. I keep 5 days of virtual machine back ups and unfortunately as the problem started on 23rd for me, the non-existent 6th day backup is what I'd need to roll back completely. I'll have to hope it's fixed in a future release.

G
#1658 geoffreycoan

browellm HA only keeps the previous version and the problem started in 3.4 so no roll back via that route. I keep 5 days of virtual machine back ups and unfortunately as the problem started on 23rd for me, the non-existent 6th day backup is what I'd need to roll back completely. I'll have to hope it's fixed in a future release.

ah, that's a pain

I'm still using the google drive backup, taking 7 days of daily backups and about 18 months of monthly backups.
The google drive backup keeps all old addon backups for me, I have to manually delete them (probably because of the above retention policy)

ad0cb356.tar
10kB

I've hopefully uploaded above my backup of GivTCP 3.3

And restoring givtcp from a backup won't fix your HA history that predbat uses, you'll have to just wait for history to build up again (reducing days_previous if need be) or swap to using the GE cloud for historical data

L
#1659 Leeshore

geoffreycoan Presume can create utility helper based on givtcp.load energy total sensor with daily reset to do the same

G
#1660 geoffreycoan

Leeshore yes good idea, and this would avoid having to restore from an earlier givtcp backup

only draw back from this is that the new daily reset utility meter would have no history to it from when you create it, so you’d still be stuck with no load history in Predbat until the UM had built up history.

I personally have the load total energy kWh sensor disabled in HA as it’s a completely useless figure for me (2 inverters). I thought I had disabled the load today as well but looking back I haven’t, not sure why, but mine shows it not resetting since I upgraded givtcp

R
#1661 rjp

Quick Q: I'm running HA/Predbat on a RaspPi, with the GivTCP add-on. I just realised that despite the add-on having AutoUpdate enabled, it's claiming to be running 2.4.9 - I couldn't see any instructions for updating to 3?

I've got the GivTCP 3 addon in the addon store now, and 2.4.9 is already using MQTT...

G
#1662 geoffreycoan

rjp I've got the GivTCP 3 addon in the addon store now, and 2.4.9 is already using MQTT...

you simply stop givtcp 2 addon, untick the ‘start on boot’, and start the givtcp 3 addon. It’s as simple as that.

Check that your battery entities are working OK, some people (me included) had problems with the upgrade

R
#1663 rjp

geoffreycoan Cheers. I'll give it a go. In the words of bigclive, "One moment, please..."

... and that seems to be working fine. Thanks very much!

B
#1664 browellm

Leeshore Thanks for this. Didn't have a clue what I was doing but put some stuff into ChatGPT which I have to say is amazing for this sort of thing, and I have it set up. Just need to get through the pain of it populating the dataset. I've put predbat on control charge only for a while just to stop errant exporting while it gets back up to speed.

G
#1665 geoffreycoan

I would be very careful about what ChatGPT says, @Daveb01 has found that it makes things up VERY frequently.

Its always confident but some of its suggestions are completely false.

B
#1666 browellm

geoffreycoan True but needs must when the devil vomits into your kettle (or the dev releases a build that borks a nightly reset)

H
#1667 Henry3rd

I'm back!! Having been on Iflux for the summer. But all is not well. Predbat stops recording my actual load data from midnight onwards.
If I restart, all is well until midnight again. I have searched the forum but cant find any reference to others having this problem.
Help!
<Thanks in anticipation

B
#1668 browellm

Henry3rd It sounds like you are having the GivTCP 3.3 or newer problem that's been discussed here the last week. Read up.

H
#1669 Henry3rd

browellm Thanks

G
#1670 geoffreycoan

It does sound like the GivTCP 3.4 problem where load data is just completely messed up.

I use my own custom load sensor as having two inverters that share the load, the individual load sensors are meaningless (they’re both showing negative values for today!) so this issue doesn’t affect me, but for other it has.

If you have an older backup, go back to GivTCP 3.3 or 3.1.6.

I’ve been running GivTCP dev 3.4.15 for a while and it’s been rock solid with no REST errors that had plagued me for ages. An upgrade 3.4.16 arrived tonight which might include a fix for the load sensor, certainly my load sensor changed after I upgraded.

If you can, stick to an older version of GivTCP. If you can’t and don’t have a backup of an old version, try the latest dev release

H
#1672 Henry3rd

My HA has crashed at midnight for the last two nights and the only repair is to pull the plug on my pi. Is this part of the GivTCP problem?

G
#1673 geoffreycoan

Henry3rd My HA has crashed at midnight for the last two nights and the only repair is to pull the plug on my pi. Is this part of the GivTCP problem?

Hard to tell. Sounds something more serious, the GivTCP problems are (1) a whole load of warning messages in the HA log when you start GivTCP if on HA 2025.10, and (2) a number of the xxxx_energy_today_kwh sensors not resetting correctly at midnight. I've not heard of anybody having HA crash

Do you have any more information, what's in the HA log and what's in the supervisor log?

H
#1674 Henry3rd

There is a big gap in my supervisor log from about 5pm yesterday. The HA log is not showing anything obvious but that might be due to me clearing the log thois morning. I shall see what happens tonight and see if I can identify anything obvious.

G
#1675 godfreym

Henry3rd That sounds like a system problem.
If your running a Raspberry Pi are you using a SD card or an ssd drive?
It could be corruption of the data if its and SD card

G
#1676 geoffreycoan

godfreym agreed, it sounds more like a system crash not related to givtcp.

Definitely you don't want to be using an SD card for running Home Assistant

H
#1677 Henry3rd

Well... I installed the latest version of HA to see whether that would fix any gremlins. But it completely killed my pi5.
It wasn't running on an SD card.
So I have reverted back to my pi4 (SD card for the moment ) and all seems well. If it survives the witching hour, then I can eliminate a software problem.

G
#1678 geoffreycoan

Henry3rd its rather sounding like a HAOS corruption somewhere

Do you have a backup of your HA, can you install a clean HAOS build on your pi5 and then restore the HA database into that?

R
#1679 Rbor

I run HA and Predbat, givTCP, etc on a pi5 (and formerly on a pi4).
You need to get HA running on an SSD. Predbat is writing all the time to an SD card and it will likely become corrupted and stop working.

When I setup an SSD for HA, I followed an old Speak to the Geek video for pi4 and pi3:
https://www.youtube.com/watch?v=WAolAvektlw&t=332s

There's a more recent one for pi5
https://www.youtube.com/watch?v=wLgP4mu00MM&t=618s

I had a Samsung T7 sat around and doing nothing. I installed HA directly onto the SSD from Raspberry Pi Disk Imager: https://www.raspberrypi.com/software/

I then attached my ssd to USB port on my pi with no SD card.
The pi fired up and I was taken to HA log in page.
After adding username and password, there is an option to 'Restore from Backup'
You do have a backup I hope.

You should then be up and running. I would do this on pi5 which is significantly faster than pi4. The speed increase from SD card is amazing.

I remember that I went from pi4 to pi5 by taking a backup from pi4 and then starting from scratch on pi5 using the Restore from Backup option. It isn't instant (20 min?) but should work.

Hope that helps. There are plenty of videos to help. Just Google Raspberry Pi disk imager.

Best of luck

Rob

H
#1680 Henry3rd

geoffreycoan Assuming there is no issue with the Pi4 tonight, I shall rebuild the pi5 and restore from a backup. This is my job for tomorrow.

H
#1681 Henry3rd

Rbor Thanks Rob, I copied your fine example when I first set the pi5 up.

H
#1682 Henry3rd

It does seem that I have a corrupt pi5, as the pi4 is running with no errors (touches wood!) I will just replace the SD card with my SSD module and consign the pi5 to the subs bench.

G
#1683 geoffreycoan

Shout out to my Predbat error monitor that correctly restored predbat running after a HA upgrade.

Upgraded just now from HA 2025.10.4 to HA 2025.11.1 and in the process Predbat stopped working.

When you do a HA upgrade it only affects the HA docker container, the other add-ons (including Predbat) running under the HAOS supervisor continue to run.

Predbat talks to HA via a web socket but as HA was being restarted the web socket connection broke:

Predbat keeps retrying the web socket up to 5 times, it fails repeatedly, gives more diagnostics and then starts the whole process again:

Predbat won’t ever get out of this loop.

My predbat error automation handler detected that whilst the addon was running, it hadn’t populated the plan and output entities:

The automation restarts predbat, and 2 minutes later its all working perfectly again:

Latest version of the error handler including the half-hour heartbeat check which is what detected this failure is in the predbat documentation https://springfall2008.github.io/batpred/output-data/#automated-monitoring-that-predbat-and-givtcp-are-running-ok

L
#1684 Leeshore

geoffreycoan Just copied the latest version last week. Thanks for your continued help

T
#1685 thevilla

I've recently noticed my predbat energy forecast is not working consistently:

Load energy is set to sensor.givtcp2_chxxxxg094_load_energy_today_kwh but when I look at this in HA it is not incrementing properly:

Seems odd. Any ideas why this would be happening please?

G
#1686 geoffreycoan

thevilla Load energy is set to sensor.givtcp2_chxxxxg094_load_energy_today_kwh but when I look at this in HA it is not incrementing properly:

Seems odd. Any ideas why this would be happening please?

There is a bug in GivTCP 3.4, the load energy sensor is not incrementing (or resetting) properly. A fix is coming, I’ve been using the dev release of GivTCP and its now working fine for me, so swap over to GivTCP Dev, or obtain an API key from the givenergy portal and set Predbat to use the gecloud data in apps.yaml as an interim until the production release of GivTCP comes out

T
#1687 thevilla

geoffreycoan thank you for your very prompt reply. I'll try the dev version as suggested.

Edit: v3.5 has just been offered to me as an upgrade which claims to fix the issue. I'm giving that a go now.

G
#1688 geoffreycoan

thevilla yes I was just coming here to announce that GivTCP 3.5 is published. I’ve installed it and it seems to be working fine.

Bear in mind that your load today history will still be messed up by the givtcp bug, so it’ll take a while for predbat to get past that with its processing of history. You might consider adjusting days_previous in apps.yaml to a smaller value to speed this up

P
#1689 pwdst

I had toggled cloud data on temporarily to work around this bug. Now that I have updated GivTCP and it should be fixed do you think it's safe to toggle cloud data off or should I wait a couple of days?

G
#1690 geoffreycoan

pwdst had toggled cloud data on temporarily to work around this bug. Now that I have updated GivTCP and it should be fixed do you think it's safe to toggle cloud data off or should I wait a couple of days?

Depends what you have your days_previous set to for Predbat to determine your average consumption from. I have mine set to days 2 through 8, so I would suggest leaving it a few days to get some “good” history built up in the givtcp sensor before swapping back. There’s no real issue with running with the gecloud data, it is of course dependent on your internet connection and the gecloud, and the data isn’t as granular as directly reading it from the inverter, but it isn’t as screwed up as the load history was.

T
#1691 thevilla

geoffreycoan Thanks. At this time of year with a ASHP and relatively small PV array my battery charges to 100% every night. (I'm on FIT). I really run predbat to step in for extra cheap OIG sessions or free electric sessions so messed up history is tolerable. It took me a while to catch on it was faulty : -)

H
#1692 Henry3rd

pwdst Since switching to cloud data, I am for the first time ever, running with no data gaps. I'm going to stick with the cloud data.

S
#1693 SteveCook

Everything working fine for me, but when I go to the predbat UI log, I get this in the "Error" tab. Error: Validation of apps.yaml found 4 configuration errors.
When I look in the apps.yaml I cannot see anything that is highlighted or points me in any directions?
Any suggestions would be welcomed how I might find what is wrong. I have not edited or changed anything (AFAIK)
Thanks Steve

L
#1694 Leeshore

Have you tried restarting predbat?

S
#1695 SteveCook

Leeshore
Yes done all that and system reboots. All works OK, but I just dont know what this error is. It does not seem to cause any issues, but maybe I am just worrying about nothing, but I like things to be "right" and I dont know how to fix things to get rid of it

L
#1696 Leeshore

I know if I have issues the errors are highlighted in red in the Apps part of the UI

S
#1697 SteveCook

Aaah thanks. I will take a look at these

G
#1698 geoffreycoan

SteveCook The warnings should be logged in the predbat log as well, but I have seen that the UI can be a bit more zealous than the predbat app when finding things to complain about.

It looks like all those are just lines you can comment out of apps.yaml if you are not using them - 1 inverter, no EV, not on IOG, no carbon setup, etc

S
#1699 SteveCook

Just commented a load out. Down to 3 errors from 4.
Just have to keep looking
Too tired now, i want a beer

G
#1700 Guybrush-Threepwood

geoffreycoan does that mean you’ve entered 2,3,4,5,6,7,8 into your apps.yaml?

What’s the advantage of doing all those days vs just -7 or -7 & -14?

G
#1701 geoffreycoan

Guybrush-Threepwood does that mean you’ve entered 2,3,4,5,6,7,8 into your apps.yaml?

What’s the advantage of doing all those days vs just -7 or -7 & -14?

yes that’s what my days_previous is, days 2 through to 8

if you only have one day, - 7 for example, then predbat will estimate the load from a single day a week ago. But was that a typical day, did you do a load of washing, baking, tumble dryer, etc that day? Same with -7 and -14 which is better, it’s an average of 2 days of data.

By telling predbat to average the last 7 days of data I take the view that this will iron out the peaks and troughs of daily life better to give a more accurate house load prediction.

I’m retired, at home most of the time, so every day is just another day for me, there isn’t a real difference between weekdays and weekends. If you worked away from home 5 days a week so had a very different pattern weekday and weekend then this averaging probably wouldn’t work for you. But even when I was working away the house load didn’t vary that much each day.

My house load excluding heat pump varies quite a bit day to day anyway:

Since the heating went on (you can spot when), the heat pump demand causes the house load to vary even more based on outside air temperature, so taking a broader average helps to smooth these variations out:

S
#1702 SteveCook

Leeshore
Fresh cup of tea this morning.
Thanks for guidance in looking in Apps tab. I have edited my yaml and all errors gone.

T
#1703 TX200

It appears solcast is broken, no data updates since 9pm yesterday.

Good job it's late November. 🤣

G
#1704 geoffreycoan

TX200 likewise, no API polls since about midnight for me https://github.com/BJReplay/ha-solcast-solar/issues/390

It’ll come back, and the Solcast integration downloads the next 14 forward days anyway so we have a forecast, it’s just progressively less accurate.

Today 2.24kWh generated, over triple yesterday’s 0.69kWh which is my all-time lowest generation since the panels were installed in January 2023. Amazing.

R
#1705 Rubikcube

TX200 Good job it's late November.

Solcast originated in Sydney, Australia, so just coming into summer ... oh dear.

W
#1706 Wavy Davy

Was wondering why I got this.

G
#1707 geoffreycoan

Wavy Davy Solcast currently not accepting API requests, returning error code 429 since Friday

See https://github.com/BJReplay/ha-solcast-solar/discussions/278 and https://github.com/BJReplay/ha-solcast-solar/issues/390

Don’t do anything. Don’t create a new API key, don’t uninstall or reinstall solcast, don’t delete any config files, just wait for it to come back, probably tomorrow.

Things are not broken, HA and Predbat still has the prior forecasts that were retrieved from Solcast, they’re just a bit less accurate as they’re not being refreshed

T
#1708 TX200

Does PredBat have a way to take solar forecasts from any other sources?

Guess it's not too important given the season and it's likely to be fixed on Monday I reckon.

G
#1709 geoffreycoan

TX200 Does PredBat have a way to take solar forecasts from any other sources?

RTFM as ever

Yes, Predbat direct can retrieve solar forecasts from forecast.solar, pretty straight forward to configure in apps.yaml https://springfall2008.github.io/batpred/install/#predbat-direct-to-forecastsolar

Limitations as per the documentation.

Maybe worth setting it up as a fallback; but this is the worst 429 storm I’ve seen with Solcast, just unfortunate it started on a Friday when everyone at Solcast would have gone home.

G
#1710 Guybrush-Threepwood

Solcast. Which has been 429’ing all weekend has just updated.

L
#1711 Leeshore

geoffreycoan I use direct forecasts and it works well for me

G
#1713 geoffreycoan

TX200 well, cheers for swearing at me.

I only asked a question

And I had read the configuration guide which talked about the solcast setup and doesn't appear to mention any other methods

Maybe this page needs a FU (that's a something update!)

https://springfall2008.github.io/batpred/configuration-guide/

You would not believe the number of questions that get asked on here and on github from people who do not read the documentation and try to work things out themselves. I try to help, but my patience is not limitless.

I've had a look at the linked configuration guide, it says "First, get the basics set up, ... and the solar forecast is in place." which links you to the Solcast setup in the install guide.

First and second paragraphs of that part of the install guide:

"If you do have solar panels it's recommended to use the Solcast integration to retrieve your forecast solar generation.
If you do not want to use Solcast you can also use Forecast.solar (less accurate) - see below."

Personally I think this is pretty clear signposting as to what the options are.

The only other reference to Solcast in the configuration guide is one mention of "Solcast forecast", I have changed this to "Solar forecast" to be less specific.

Happy as ever to take any suggested improvements and will incorporate them.

Thanks Guybrush-Threepwood thanks for letting us know, just done a manual update and brilliant, solcast updated forecasts again. Took my forecast for tomorrow from 16.7kWh to 17.2kWh, which isn't much of a difference; shows the quality of their original 2 day old forecast.

Z
#1714 Zakalwe

One for the Ohme users. All of my Ohme integration sensors went off-line yesterday at 11:11. The Ohme app still works, but it looks like Ohme are doing something to restrict API access.

https://github.com/home-assistant/core/issues/156753

Z
#1716 Zakalwe

The 2025.11.3 update seems to solve the problem, bar the CT current sensor.

G
#1717 geoffreycoan

Zakalwe and predbat 8.27.27 includes the same fixes so Predbat Ohme direct should now be working again

L
#1718 Leeshore

I'm sure this has been on before but i'm wondering which battery sensor to use when callibrating predbat. I can see two:

  1. sensor.givtcp_battery_stack_1_bms_temperature - which is what i have always used - temperature currently 22C
  2. sensor.givtcp_xxxxxxxxxxx_battery_temperature - current value 36.6C
G
#1719 geoffreycoan

Leeshore I believe there is a fault in givtcp where it reports the temperatures the wrong way round.
I have raised this as a bug, but other priorities I guess.

Have a look at how the two sensors change. On mine the battery temperature changes rapidly, indicating it is the BMS temperature, and the BMS slowly, indicating its the battery temperature. Based on your current temps I’d say the same for you

G
#1720 geoffreycoan

New version of the predbat table card out just now, provides the ability to reset the running total to zero at midnight instead of it rolling over https://github.com/pacemaker82/PredBat-Table-Card/releases/tag/v1.9.5

I’ve been working on some enhancements to Predbat myself that I will get PR’d in soon:

  • detect calibration status for GivTCP v3 (it currently only detects GivTCP v2)
  • ability to set per-inverter reserve limits instead of a single global limit. This is useful for me to stop batteries discharging down too far during the day and then not being able to charge back up in the 3 hour Cosy cheap period
  • prevent overnight cross charging by setting the inverter into Freeze export rather than Demand mode
  • Predbat status messages now show each inverter SoC level and target rather than just the last inverter
  • loads of documentation changes

Probably some more things that I have forgotten about. These are all on my fork if you are interested.

B
#1721 browellm

geoffreycoan Looks good. I tried updating this morning and couldn't get the card to display at all despite clearing the browser cache and a HA restart. I reverted to 1.9.4 for the time being until I can spend the time working out what's going wrong.

R
#1722 Rbor

browellm I checked this out and pacemaker82 has now updated the card to v1.9.6.
I have upgraded and the revised card has loaded just fine.
Worth a look.

Rob

G
#1723 geoffreycoan

browellm I had no problems with 1.9.5 or 1.9.6.

If it still doesn't display properly then suggests its something else on that dashboard that is conflicting with the latest table card version. You can try putting the card on its own view to confirm this, and if it is the case, then raise a bug

B
#1724 browellm

geoffreycoan
Thanks Geoffrey. The card is already on its own view, so I'm not quite sure what's going on, especially as I also have a 'mini' predbat table card on my HA home page which continued to display correctly. I will see if 1.9.6 installs correctly tomorrow.

G
#1725 geoffreycoan

browellm Thinking about it, its probably a bug in the latest version caused by the specific combination of columns and settings you have turned on which is why I don’t see it.
The change in 1.9.6 was to introduce a total to the grand total column if ‘reset totals at midnight’ is turned on as otherwise you won’t see what the end of day total is.

Try it again and then raise a bug with @pacemaker giving your full yaml configuration

T
#1726 The Black Cat

browellm
When I upgraded, my plan would not show. I found that if I removed the "options-column" from the list of columns, it worked after that.

B
#1727 browellm

The Black Cat Thank you that has fixed it. I will add that to my ticket to see if options-column can be made compatible with v1.9.5 and above

G
#1728 geoffreycoan

The Black Cat I just looked and I’m not using options-column so that must be it:

type: conditional
conditions:
  - condition: screen
    media_query: "(min-width: 0px) and (max-width: 767px)"
card:
  type: custom:predbat-table-card
  entity: predbat.plan_html
  columns:
    - time-column
    - soc-column
    - state-column
    - limit-column
    - import-column
    - pv-column
    - load-column
    - cost-column
    - total-column
  old_skool_columns:
    - soc-column
    - state-column
  odd_row_colour: "#181f2a"
  even_row_colour: "#2a3240"
  table_width: 100
  stack_pills: false
  force_single_line: true
  fill_empty_cells: true
  show_day_totals: true
  reset_day_totals: true
B
#1729 browellm

All fixed in 1.9.7

B
#1730 browellm

What would cause the cost bump here?

B
#1731 browellm

Looks like a glitch possibly caused by the midnight reset option since the raw Predbat html plan has no such cost bump.

I've logged a ticket for a possible bug.

#1732 hoggy

I don't use Predbat but this may be useful/need folding in to its plans.

If your on Axle VPP there is now an endpoint that identifies when the grid events will be. See: https://vpp.axle.energy/landing/home-assistant

& the responses are structured as:

{
"start_time": "2025-12-04T16:30:00+00:00",
"end_time": "2025-12-04T17:30:00+00:00",
"import_export": "export",
"updated_at": "2025-12-03T18:57:40.999222+00:00"
}

Someone (Geoffrey?) who may have Predbats ear may need to pass that on.

#1733 PianSom

hoggy
Please share your referral link (if you want to) so we can thank you for suggesting this.

G
#1735 geoffreycoan

hoggy I don't use Predbat but this may be useful/need folding in to its plans.

If your on Axle VPP there is now an endpoint that identifies when the grid events will be. See: https://vpp.axle.energy/landing/home-assistant

& the responses are structured as:

...

Thanks for sharing hoggy I don't have Axle so I can't do any testing myself, but my immediate thought is that knowing when the sessions are is of some use, but its also not all we need to know.

I see that the linked page provides details of how to create a REST template sensor to retrieve the Axle VPP details, that's exactly what I was thinking of to get the the data into HA.

Once its in HA, and if you are using Predbat, could either use the date/time to set overrides in predbat so predbat does the same as what Axle is going to program on the inverter, i.e. import or export the battery.

What might be better is to set predbat to read only at the start time (or start time - 5 minutes) so Axle can takeover the inverter operation for the event, then set predbat back to taking control at the end time.

Where I see difficulties is that the Axle data structure only appears to provide a single import or export event, so where Axle does an import before a DFS and then an export, that couldn't be planned in advance. I also have questions about how far in advance of the event does Axle program the inverter and will Predbat relinquishing control 5 minutes before be sufficient for Axle to then program the event, or does it need to be earlier.

But given the rest config given it would be easy enough to create an automation for this to wrap around predbat.

My gut reaction is to not add this into predbat core given the limited user base and if we can wrap it around predbat easily enough then that would meet the need

G
#1736 geoffreycoan

Thanks hoggy, I’ve signed up to Axle, used your referral code, and created the HA REST sensor. I just need to restart HA and then start writing an automation to relinquish Predbat control around these sessions.

G
#1737 geoffreycoan

Quick automation written to alert when there is a new Axle VPP event. It’s an extension of existing alerts I have for Octopus Power up and Free electricity.

I’m going to run with this for a while to see how it goes, what pre-notice I get, and then I can look at further automating Predbat activity/read only mode.

alias: Octopus/Axle New Alert
description: Alert when new Octopus Power up, Free Electricity or Axle VPP event
triggers:
  - trigger: state
    entity_id:
      - sensor.octopus_free_electricity_times
    from: "[{\"start\":null,\"end\":null}]"
    variables:
      alert_title: Octopus Electricity session
      alert_text: New Free Electricity times
      date: >-
        {% set dt=state_attr('sensor.octopus_free_electricity_times','start') %}
        {% if dt != None %}
          {{ as_timestamp(dt)|timestamp_custom('%a %-I:%M %p') }}
        {% else %}
          unknown date
        {% endif %}
  - trigger: state
    entity_id:
      - sensor.octopus_power_up_times
    from: "[{\"start\":null,\"end\":null}]"
    variables:
      alert_title: Octopus Electricity session
      alert_text: New Power up electricity times
      date: >-
        {% set dt=state_attr('sensor.octopus_power_up_times','start') %} {% if
        dt != None %}
          {{ as_timestamp(dt)|timestamp_custom('%a %-I:%M %p') }}
        {% else %}
          unknown date
        {% endif %}
  - trigger: state
    entity_id:
      - sensor.axle_event
    variables:
      alert_title: Axle session
      date: >-
        {% set dt=state_attr('sensor.axle_event','start_time') %} {% if dt !=
        None %}
          {{ as_timestamp(dt)|timestamp_custom('%a %-I:%M %p') }}
        {% else %}
          unknown date
        {% endif %}
      session_type: >-
        {% set st=state_attr('sensor.axle_event','import_export') %} {% if st !=
        None %}
          {{ st }}
        {% else %}
          unknown session
        {% endif %}
      alert_text: New Axle VPP {{ session_type }} event
conditions:
  - condition: template
    value_template: "{{ date }} <> \"unknown date\""
actions:
  - data:
      title:
        "[object Object]": null
      message: "INFO: {{ alert_text }} starting at {{ date }}"
      url: /dashboard-givenergy/powerup
    action: script.notify_all_devices
mode: single
#1738 hoggy

geoffreycoan for Axle (Events only) you'll get notified the day before.
Given the timing (I got notified at 15:51) I have a hunch (and they've cottoned on to what I run as a hobby so not that forthcoming about confirming it) it's related to the GB30 Auction which happens to close at 15:30 each day: https://www.epexspot.com/en/market-results?market_area=GB&auction=30-call-GB&trading_date=2025-12-03&delivery_date=2025-12-04&underlying_year=&modality=Auction&sub_modality=DayAhead&technology=&data_mode=graph&period=&production_period=

G
#1739 geoffreycoan

hoggy interesting. Day ahead is great notice, be happy with that.

If I read this correctly, shows prices peaking above £1/kWh in the evening peak period, which I guess is how they can afford to pay us such rates for operating as a VPP

Yet tomorrow’s Agile rates are nothing like that, in fact they’re lower than today’s rates (today colder than tomorrow’s forecast):

Anyway, interesting

#1740 hoggy

geoffreycoan yes I think over £1/kwh is the magic number. Today's Axle event was 16:30 to 17:30 so fit perfectly with the GB30 peak. (I don't think you'll have taken part in that if you've only joined today)

Just a hunch but they haven't triggered a notification for tomorrow and the peak is just shy of £1.

G
#1741 geoffreycoan

hoggy I’ve moved to Agile outgoing for the winter as I am self consuming all that I generate, and if its especially sunny I just won’t import quite as much in the Cosy 4-7am period. My thinking being that the only time I would export would be in a DFS event when it’s worthwhile exporting anyway.

Today the Agile export rates from 16:30-17:30 were 18.96p and 17.96p, which would be marginally worth exporting in if I didn’t run out of battery before the 22:00 Cosy cheap period, which I’m likely to do, so my threshold to export is about 31p.

Axle give notification the day before, do you know at what time roughly they send the instructions to the inverter?

I just did a test, setting a future time discharge slot, and as Predbat doesn’t have any exporting planned, it just ignored it which is good, so Axle can send that to the inverter and it will get programmed. So I might just need to set Predbat to read only about 5 minutes before an Axle slot and then Axle can send the ‘enable discharge schedule’ command - assuming they send that at the slot start time.
If not might need some more juggling around. A fun new challenge.

#1742 hoggy

geoffreycoan they sent instruction to mine at 16:31, which as the event started at 16.30 is a little slow off the mark, but they did admit they would get better with timings in the beta group I'm in.
I guess they have to stagger things a bit if they get thousands signed up it would be a lot for the API to handle all in one lump.

L
#1743 Leeshore

Not sure I’ll bother as despite prior warning of an event my wife will have the oven, washing machine, tumble dryer and usually the dishwasher on during the time slot…..

G
#1744 geoffreycoan

Leeshore Mrs C has a piece of paper with the cheap Cosy times on and is good at asking me to set the washing machine, dishwasher and tumble dryer going when its cheaper rate

But as for shifting the cooking, no chance

K
#1745 KamenMacKay

So the backstory is that Predbat always keeps my battery at 5% and never actually reaches 4%. It moves onto the next time block with 5% SOC projected to go down to 4% but it never actually gets there. The settings for the reserve for the battery are 4% so obviously I'd like to run it down to 4% and squeeze every last bit of savings out of it. I've done a inverter/battery reset but it stubbornly stays stuck at 5%. Does anyone know how to fix this?

G
#1746 geoffreycoan

KamenMacKay So the backstory is that Predbat always keeps my battery at 5% and never actually reaches 4%. It moves onto the next time block with 5% SOC projected to go down to 4% but it never actually gets there. The settings for the reserve for the battery are 4% so obviously I'd like to run it down to 4% and squeeze every last bit of savings out of it. I've done a inverter/battery reset but it stubbornly stays stuck at 5%. Does anyone know how to fix this?

The predbat plan shows that predbat is taking the battery to empty and then running off grid.

Your issue is not predbat, it’s your battery that is mis-representing its state of charge.

Batteries can’t measure state of charge, all they can do is to measure the voltage when they are full and empty and interpolate between the two what that means in terms of SoC. When you do a calibration these high and low voltage points are captured by the BMS and that’s what it then uses to record 100%, 4% and everything else in between.

So when your battery reports 5% SoC, what it is saying is that based on the last calibration voltage it used to be able to squeeze a bit more out of the battery, which is why it thinks its empty at 5% not 4%.
Over time the battery cells degrade so this could account for the discrepancy, or more likely your last calibration was done when it was warmer weather as temperature also affects the battery chemistry and what you can get in and out of the battery.

If you run a new calibration then it will reset the high and low marks, but TBH I wouldn’t worry too much about it. Mine stops at 5% or 6% most of the time, but looking now they have stopped at 4% and 3% in the last week so maybe my last calibrations were done in colder weather 🤷‍♂️

S
#1747 SteveCook

KamenMacKay
My battery is set for 5% minimum. Some nights before charge it reports 3%, other nights 4, 5 or 6%. I don't think it is worth worrying about.
My battery is a 9.5 kWH. So 1% is 0.096kWH.
I buy off peak at 14.31 and peak at 30.99 (difference 16.68p per kWH)
So me not squeezing out another 1% overnight arguably costs me 16.68 x 0.096 = 1.6p

K
#1748 KamenMacKay

geoffreycoan Thanks for the great explanation! I do remember, early in my home battery journey, regarding the inaccuracy of estimating SOC. And, of course, Predbat only reads the SOC from the battery and then makes predictions based on that. I thought it might've been a weighting issue or similar but as @SteveCook points out perhaps I am being a bit pedantic trying to squeeze out that extra oomph for so little benefit.

G
#1749 geoffreycoan

Useful new feature coming soon in Predbat, written by Copilot AI on Trefor’s behalf, the ability to manually override the target SoC by a specific time https://github.com/springfall2008/batpred/pull/3041

Interesting looking at the code and documentation it produces, the draft code was then sent for review, Trefor made a comment and it updated the code accordingly.

G
#1750 geoffreycoan

r/e Axle events. So far no events seen by me, but then its been quite windy so would imagine the grid wouldn't need it

Someone has put a feature request into Predbat to add support for Axle VPP events in Predbat. I hadn't done that as I didn't think it was mass-market enough.

Anyway, I have written an automation to convert the Axle VPP event into a series of manual export overrides for Predbat so when I do get an Axle event it should automatically program Predbat to handle the export.

See https://github.com/springfall2008/batpred/issues/3051

B
#1751 browellm

WTF, has someone just spun up a website at predbat dot com?

G
#1752 geoffreycoan

browellm predbat dot com has been out there for a few months

What Trefor has explained is:

  • it is a separate entity from the Predbat Home Assistant app
  • he was approached by some people who wanted to setup this commercial offering and they have licenced the core Predbat engine from him
  • predbat as we are using it will remain freely available and contributions continue to be welcomed

Trefor hasn’t publicly said but I suspect that a number of the recent changes that have been made to Predat, the splitting into component modules, the changes to tracking the cost benefits of Predbat vs a baseline, the many many fixes for GE Cloud and Fox Cloud integration, …. have been in a large part driven by the online version

My understanding is that there are users already on the web version and they’ve reported good results. It’s certainly easier to setup than HA, etc.

B
#1753 browellm

geoffreycoan Interesting, thanks for the background. I am glad it is Trefor sanctioned and not someone trying to rip him off xD

#1754 PianSom

hoggy I didn't really do much & I don't normally care about those kind of things, but if it helps fund some more amusing battery / inverter dismantling escapades them they can try: https://vpp.axle.energy/landing?ref=R-ZSBFJSXH

FINALLY I got around to signing up - hopefully your reward is now in cash rather than (or as well as?) in heaven @hoggy

#1755 hoggy

PianSom oh wow thank-you very much! I'm half way towards recouping my £100 Givenergy battery misfire now!

#1757 hoggy

geoffreycoan yes but your holey battery story gave us on here a good amount of amusement and that's all that matters....to us... 🤣

G
#1758 geoffreycoan

useful new feature in latest predbat release 8.29.14, not highlighted that much (and no additional documentation!), now have the ability to select multiple predbat entities and their attributes in the web console / entities view, and compare them over time periods, e.g. I selected the cost 10 from predbat compare of my current tariff to cost 10 of agile import/fixed export, so over time I can see which was more profitable:

T
#1759 TX200

Anyone seeing an error with PredBat setting pause mode to disabled? AND a frequent entry in the giv logs saying setting pause mode to disabled success?

I'm on the latest home assistant and PredBat versions.

T
#1760 TX200

Just restarted the PredBat add-on and it's gone back to status: demand mode.

Hopefully it stays that way... Fingers crossed

G
#1761 geoffreycoan

TX200 no such errors in my predbat or givtcp, its setting itself to pause discharge in the charge sessions then back to demand ok.

Sometimes giving everything a complete reboot, HA and all addons can cure such issues. Also rebooting the inverter if it’s just not listening to givtcp.

Predbat’s generally behaving itself for me although I do see occasional spots where it plans to sit in demand mode in the cheap period, letting the SoC drop, rather than freeze charging or charging. It usually gets the right idea in the end but since my consumption is so dependent upon the outside temperature I bung in a load of force charges to ensure the battery is filled.

I was just looking back, this thread was started on 21st December 2024, the 1 year anniversary of ‘first night live on predbat’ which had accumulated 3200 comments in a year. So we’ve missed the year 3 anniversary and since we “only” have 1700 comments then I guess we’ll have to wait until year 4 before starting a new thread

H
#1762 Henry3rd

Can I ask if there has been an programme change that has affected historical data again?
I can't see anything in the forum but I am now getting the following warnings.

"Warn: Historical day 'x' has no load history data," This started on historical day 4

Thanks in advance

G
#1763 geoffreycoan

Henry3rd I can't see anything in the forum but I am now getting the following warnings.

"Warn: Historical day 'x' has no load history data," This started on historical day 4

There was a minor change made about 2 weeks ago but this should have improved history loading rather than caused a problem. Other than that I’m not aware of any specific changes in this area, but Predbat is sensitive to load/import/pv energy today being set correctly and having history that ‘behaves’. Is Predbat complaining that there is no history for just that day or multiple days, or is it complaining about a gap in the history?

What sensor are you using for your load today? Have a look at the sensor history in HA, does it have any anomalous jumps down in value where there shouldn’t be (this can cause predbat to ignore the jump down so it treats a period of time as having no history), does the sensor reset properly at midnight? There are still ongoing issues with givtcp xxx_energy_today sensors not always reliably resetting at midnight and this can throw Predbat off.

If your HA data is messed up (due to givtcp problems) you can either edit the days_previous it exclude the errant days, or swap to using GE cloud data which wouldn’t have such issues. Its also worth turning on modal load history so Predbat automatically discards the lowest history value when working out the average historical load.

H
#1764 Henry3rd

Thanks #geoffreycoan
There are multiple days now (3) that have no history.
Its using "sensor.givtcp_FD2319F635_load_energy_today_kwh" I have looked at the historical data and all seems ok for the last few days. Its setting ok at midnight.
That said; we had multiple internal fuse tripping prior to the 24th Dec. Hopefully it was not a coincidence that UK power networks found an underground fault which they fixed on the 24th also. No further trips since.
I am running off GE cloud data already but I take your point that the missing data (pre 24th) might be the issue.
I'll change the days_previous to -2 and see if that cures the issue.

H
#1765 Henry3rd

It seems that my GE cloud data has gone AWOL
"Warn: No GE Cloud data returned from GECloudData component"
I have set my ge_cloud_data to false and all is well once more.
Any idea on why the cloud data would no longer work?

H
#1766 Henry3rd

ooh err, I just looked at my cloud dashboard for the first time in ages - no data.
I shall scan the rest of the forum to see if anyone else had had this issue

H
#1767 Henry3rd

I have tried restarting the inverter, but control is locked by Octopus!!
I have sent an email, as this should have been relinquished when I switched back from IOF.
These things are sent to try us.

H
#1768 Henry3rd

I'm getting there, it seems to be an IP issue, obviously it was given a new one when restarted following our power outage. Now working on the app, just the dashboard to go.

G
#1769 geoffreycoan

Henry3rd You should be able to restart the inverter from givtcp. If your inverter has a new IP address then edit /config/GivTCP/allsettings.json and add the new IP address. It’s worth you setting your inverter to a fixed IP address on the router to stop this happening (appears usually as device HF-21 or similar).

But a power cut and your inverter getting a new IP address shouldn’t affect data getting to the GE cloud, as long as the inverter connects to your wifi it should push the data through OK

H
#1770 Henry3rd

I managed to log into the inverter from my web browser and do a module restart. We are now back online, hoorah!
If in doubt- turn it off and on again. 🙂

T
#1771 TX200

PredBat seems very indecisive these days.

Notification says it'll charge 31-100% at 1330

Notification at 1331 says it'll freeze charge.

It put 0.1kWh into the battery in that minute or two.

Not sure it's worth the extra writes.

Not the first time I've seen instructions change within minutes.

G
#1772 geoffreycoan

TX200 I don't see such similar behaviour myself but every person's setup is different. It could be that the plan was just "on the edge" of being financially better to charge or to Freeze Charge, so after a tiny charge Predbat changed the plan. But that does seem a bit odd, Predbat normally only plans every 10 minutes so if the programming changed at 13:31 then that must have been from the 13:30 plan.

You could try tweaking up the metric min improvement configuration options, these determine what financial improvement there has to be for predbat to change the plan. So setting these to a few pence will dampen down major plan changes https://springfall2008.github.io/batpred/customisation/#battery-margins-and-metrics-options

P
#1773 Paul H

I had a HA update failure and unknown to me the backups had become password protected so I've had to start from scratch 😢

I used Developer Tools > Statistics to set savings_total_pvbat and savings_total_predbat to roughly where they were before the crash but neither are now incrementing

The yesterday savings sensors are working fine.

I can't find either of these sensors in tools > stats now either which seems really odd.

Does anybody have any idea how I can get these to increment again?

G
#1774 geoffreycoan

Paul H I used Developer Tools > Statistics to set savings_total_pvbat and savings_total_predbat to roughly where they were before the crash but neither are now incrementing

That won’t do you any good.

In Home Assistant you have entities and their history, and long term statistics. Entity history gets purged after a period of time (default 10 days). Long term statistics are an hourly summary of the entity history that are kept forever.

Developer tools/statistics are what is used to power the Energy dashboard, or if you look at a history graph more than. 10 days of history ago.

Predbat only uses the entity history to get historical values. From my looking at the code it never uses statistics.
In general the code gets yesterday’s midnight entity history value and adds todays value to it to increment the total figures.

There isn’t a direct way to manipulate entity history either, you can change an entity current value and that’s probably the best way of forcing it to take on a new value, and then waiting until the history rolls on to next day.

I don’t know why Predbat is no longer incrementing the savings for you, its possible it can’t find the entity history for yesterday and this will resolve itself tomorrow?

And yes, Home Assistant backups changed some time ago to encrypted by default. You can turn the encryption off for local backups and you can save the backup encryption key. It’s definitely worth watching HA update videos (e.g. Smart Home Junkie) and read the release notes for each release as they come out

H
#1775 Henry3rd

Firstly; happy new year to fellow predbaters.
Secondly; who will be bringing in the New Year by watching for system errors when the year ticks over? 🙂

#1776 ChrisLav

Henry3rd who will be bringing in the New Year by watching for system errors when the year ticks over?

Been there, done that. NYE 1999 (after 6 months of chasing suppliers worldwide to make sure their systems were compliant!) 🙂
Jan 2nd 2000:
Everyone sitting round me in the office: 'Well, nothing happened. What a waste of time'
Me: 'Thank you. 6 months time well invested'

B
#1777 browellm

Can I reduce this type of activity via config? It just seems unneccesary

2026-01-02 04:30:37,428 - GivTCP - write       -  [INFO    ] - Setting battery reserve 85 was a success
2026-01-02 04:35:04,930 - GivTCP - write       -  [INFO    ] - Setting battery reserve 88 was a success
2026-01-02 04:35:37,801 - GivTCP - write       -  [INFO    ] - Setting battery reserve 89 was a success
2026-01-02 04:40:03,977 - GivTCP - write       -  [INFO    ] - Setting battery reserve 92 was a success
2026-01-02 04:45:03,421 - GivTCP - write       -  [INFO    ] - Setting battery reserve 95 was a success
2026-01-02 04:45:20,214 - GivTCP - write       -  [INFO    ] - Setting battery reserve 96 was a success
2026-01-02 04:50:04,565 - GivTCP - write       -  [INFO    ] - Setting battery reserve 100 was a success
G
#1778 geoffreycoan

there isn't a config that I know of that would change this behaviour in charging periods

I have in the past raised and seen other similar issues about predbat inverter writes that could be optimised, e.,g. charge rates on low power charging discharge end time written repeatedly discharge start time and they've had some, but limited traction

Looking at my own logs I don't see reserve being changed, but I do see charge target set every predbat execution cycle:

2026-01-03 06:30:10,853 - G - write       -  [INFO    ] - Setting Charge Target 82 was a success
2026-01-03 06:35:12,190 - G - write       -  [INFO    ] - Setting Charge Target 83 was a success
2026-01-03 06:40:12,036 - G - write       -  [INFO    ] - Setting Charge Target 84 was a success
2026-01-03 06:45:11,076 - G - write       -  [INFO    ] - Setting Charge Target 85 was a success
2026-01-03 06:50:10,457 - G - write       -  [INFO    ] - Setting Charge Target 86 was a success
2026-01-03 06:55:10,930 - G - write       -  [INFO    ] - Setting Charge Target 87 was a success

and with low power charging it keeps being varied:

2026-01-03 14:00:09,173 - H - write       -  [INFO    ] - Setting battery charge rate 1500 was a success
2026-01-03 14:45:09,398 - H - write       -  [INFO    ] - Setting battery charge rate 1200 was a success
2026-01-03 15:10:09,396 - H - write       -  [INFO    ] - Setting battery charge rate 800 was a success
2026-01-03 15:30:54,820 - H - write       -  [INFO    ] - Setting battery charge rate 400 was a success
2026-01-03 15:35:16,714 - H - write       -  [INFO    ] - Setting battery charge rate 2600 was a success

I can only suggest raising it as a predbat github issue, and maybe reference the others above. There is opportunity to improve certainly, doesn't seem to be top priority?

H
#1779 ham

All,

Hope you can help:

I'm trying to calculate my inverter losses in order to set predbat_inverter_loss by making sense of the different givtcp energy sensors available.

It seems fairly clear that I can calculate my AC to DC conversion loss as follows:
(sensor.givtcp_[...]_ac_charge_energy_total_kwh - sensor.givtcp_[...]_battery_charge_energy_total_kwh) / (sensor.givtcp_[...]_ac_charge_energy_total_kwh)
In my case, this gives me a 2.3% AC to DC loss.

To calculate the DC to AC conversion loss doesn't seem so clear-cut due to the naming of the related sensors. Specifically, I believe that the sensor.givtcp_[...]_invertor_energy_total_kwh sensor records the total AC energy output by the Inverter (i.e. converted from DC from the battery), however can anyone confirm this? If yes, then using a similar formula, i.e.:
(sensor.givtcp_[...]_battery_discharge_energy_total_kwh - sensor.givtcp_[...]_invertor_energy_total_kwh) / (sensor.givtcp_[...]_battery_discharge_energy_total_kwh)
In my case, this gives me a 6.1% DC to AC loss, larger than the AC to DC loss, but perhaps that is to be expected.

Assuming the above calculations are valid, I am therefore using the average of the two values for my predbat_inverter_loss value, which in my case is 4.2%.

Incidentally I also calculated by battery round trip loss using the following formula (as per the discussions above in this thread), and came up with 11.4% round trip loss, making the total round trip loss including the inverter around 19%.
(sensor.givtcp_[...]_battery_charge_energy_total_kwh - sensor.givtcp_[...]_battery_discharge_energy_total_kwh) / (sensor.givtcp_[...]_battery_charge_energy_total_kwh)

Viewing the history for the four sensors for as long as I have data in home assistance (ca. 9 months), you can see (the distance between the amber and the red lines) that the battery round trip loss has actually increased from ca. 7% to around 11%, which I wasn't expecting (I was expecting the battery round trip loss to stay more or less constant). Has anyone else seen anything similar? It is true that at the start of that period I have started to use predbat, not that I am blaming it or anything, it might just be a coincidence, or might be due to battery wear, or a bug in the inverter energy measurements perhaps?

Sorry, the image is really hard to read. The time frame is from April to December 2025.
The top blue line is the AC charge energy total, the next amber line is the Battery Charge Energy Total, the next red line is the Battery Discharge Energy Total and the bottom green line is the "Invertor Energy Total".

Some data, in case it helps: Inverter Model: GIV-AC3.0 Battery Model: 9.5 kWh. Inverter was installed in December 2023, and this battery was installed (replacing a faulty one) on September 2024.

G
#1780 geoffreycoan

ham Your logic seems sound. I’ve personally never tried to measure my losses to work out what they are, but instead settled on a set of losses that give me a good correlation of predbat’s plan against actual activity (i.e. SoC was where Predbat predicted it to be), but I did that by tweaking the numbers until the plan was reasonably accurate.

GivEnergy do publish conversion losses on the data sheet so that’s another starting point you can use.

Other people on this forum have measured their losses and arrived at battery round trip figures of 10-20%. I’ve always felt that its towards the upper end of that range, and if you want a rule of thumb then 15 or 20% is fair which is similar to what you are calculating.

One thing to be aware of that conversion losses are not a single factor, they vary based on load. So if you are drawing 200W from the battery the losses will be higher than if you are drawing 2200W.

For comparison my battery charging loss is 5.5%, discharge is 5% and inverter 4%. In practice if they sum up to around 15-20% then you’re in the right ball park. The only time the breakout of losses really makes a difference is if you have a hybrid inverter and are solar charging.

H
#1781 ham

geoffreycoan thanks for the quick response. Good to hear that the values that I calculated are in line with others...

I'm curious: how do you separate out the battery charge losses from the battery discharge losses to calculate different values? Using my approach based on battery charge total and battery discharge total values, I can only derive a round trip loss value.

Also, your point about the losses varying with load is pertinent one. In my case, the inverter DC to AC loss seems to be higher than the inverter AC to DC loss, and perhaps this could be due to different profiles (e.g. if the average battery charge power is higher than the average discharge power)...

I'll do some further investigating...

D
#1782 Daveb01

Should we now start a new thread 3rd year live on Predbat?

S
#1784 SteveCook

Hi. Gen1 Hy5.0 and 9.5 battery
With the weather warnings on Saturday and possible power cuts, I set Best SOC keep to 5kWh and Set Reserve Min (inverter 1) to 50%.
Predbat Plan for Sun and Mon shows the battery not going below 50%, but for the last 2 days late afternoon and evening up to the midnight (Eco7) off peak charge slot, the battery drained to 4%.

Any ideas please? TIA steve

D
#1785 Daveb01

geoffreycoan understand but it only just into Jan 2026, and it’s much easier to read new posts rather than trailing though nearly 2000? Up to you your the Boss 😀👍

D
#1786 DD

Daveb01 or just call it predbat 2026? Not everyone posting will have using it for 2 years.

G
#1787 geoffreycoan

SteveCook With the weather warnings on Saturday and possible power cuts, I set Best SOC keep to 5kWh and Set Reserve Min (inverter 1) to 50%.
Predbat Plan for Sun and Mon shows the battery not going below 50%, but for the last 2 days late afternoon and evening up to the midnight (Eco7) off peak charge slot, the battery drained to 4%.

best soc keep and set reserve min do different things, but if you set them both I am surprised that your battery discharged to empty.

best soc keep ADVISES predbat of the minimum soc you'd like to keep in the battery and it will try to honour that. But if house load is greater than predicted or solar lower, or it just can't do so in a cost effective way, the soc can drop below the level you set.

If you definitely (regardless of the cost) wanted predbat to plan to keep soc in reserve the setting best_soc_min or set_reserve_min would achieve it. Setting best_soc_min I'd personally not recommend because if your house load exceeds the plan and your soc drops below what you set, then predbat will charge the battery regardless of the rate you are on to ensure that you retain the minimum soc specified.

set_reserve_min sets the soc reserve level. Defaults to 4% but you can change it to a higher value. Unlike the best_soc_xxx which affect the plan, predbat sends the set_reserve_min to the inverter and then the inverter won't let the soc level drop below the minimum. Once the battery reaches the reserve soc all house load will come from grid import.
I use this myself (in an automation) to retain my battery in the morning and overnight so I am able to charge the battery fully in the Cosy cheap periods. i.e. I only let the battery soc drop to 4% in the evening peak. It works fine for me, am surprised it didn't work for you.

S
#1788 SteveCook

geoffreycoan
Thanks. I have put 40% into set_reserve_min and i will see what happens

S
#1789 SteveCook

SteveCook
Nope. Put 40% into predbat. Plan showed 40%, but battery now down to 9%
Inverter getting the predbat message and updating it's settings, but then seems to ignore it

sat at 40% until 16:3 and then stared discharge?
I have looked at pervious days and 16:30 seems to be the mystery time!!
I have checked HA and all automations are OFF

G
#1790 geoffreycoan

You’ll need to dig deeper Steve, your snapshot of the settings history shows the reserve being set to 40%, but what happens after that, at 16:30. Does it change in the portal? What do you see for the predbat set_reserve_min and givtcp reserve values, do either of these change?

Have you setup the auto tariff card in the portal, got any discharge slots programmed, even if disabled?

Here is from my own plan today, you can see set_reserve_min gets set to 31 for most of the day, I changed it to 4% for the Axle event this morning, then changed it back, and as you can see the battery reserve gets set to the same value (the reserve and set_reserve_min lines are on top of each other), and the inverter stops the battery SoC from discharging, it appears to stop 31% then gradually drop a little, was at 29% by the end of the demand period, but basically its working fine for me.

S
#1791 SteveCook

Geoffrey Thanks. Was out all day yester (Wed) on grandparent duties, so will tray and start digging today and tomorrow.
I have checked as many places I can think of and there are no automations anywhere. I think I setup the tariff card about 18 months ago, but then got rid of it. I will look to see if there is anything legacy kicking around there.

S
#1793 SteveCook

I have 2 API keys in my GivEnergy account. Octopus and Solcast. TBH I really dont want to delete anything and the whole system die unless I really know what I am doing.
Does GivEnergy need these accounts and why? Maybe something in them is the issue?

P
#1794 pwdst

GivEnergy will use the Solcast API key to produce the solar forecast on the Portal. If you have already removed the card they don't need it and it can safely be deleted.
GivEnergy use the Octopus API key as part of their Smart Tariff functionality. In the original incarnation it would just show income and cost of energy based on the time of use, both a spot time (current cost £0.26/hr) and cumulatively (cost today £3.84). In the newer iteration of the Smart Tariff card they add automation to control the batteries for the cheapest cost. I have found it doesn't work very well and if you already use PredBat you definitely don't want that. A ship can only have one captain.

G
#1795 geoffreycoan

agree with the above, and if you are using Predbat and Solcast then having Solcast configured in the GivEnergy portal will mean you run out of API calls quicker as each will be consuming them

Old accounts had a limit of 50 a day, newer are 10, and if two arrays then each uses an API call for the solar forecast so you only get 5 updates a day

S
#1796 SteveCook

geoffreycoan
I deleted the Solcast and Octopus APIs from my account in the GivEnergy portal page.
I have restarted the GivEnergy inverter and it is showing online, with battery at 24% discharging
Battery reserve % on GivEnergy portal say 40%, but seems to be ignored
Bobbed along again today at 40% until 16:30, but there is nothing in the remote control history showing any signal to change things

G
#1797 geoffreycoan

SteveCook the fact that it changes behaviour at a consistent time makes me think it is something to do with your charge/discharge slots and not something remotely changing your settings.

Can you look at these again, click the little wheel to retrieve the start and end times from the inverter, in particular look at any Discharge (as opposed to Export) slots. As well as forcing a retrieve from the inverter, try changing the times, then changing back to 00:00 for any unused slots.

Final idea, try a reset to defaults of the inverter

G
#1798 Goshiki2

During yesterdays and today’s weather alert Predbat maintained 40% of my battery throughout the duration in case of power cuts and it all worked exactly as expected. Discharging normally until the 40% limit was reached and then running off grid until the midnight cheap date period when it charged back up to 100%.
I would like to use the status of the weather alert as a condition in an automation so I found the entity “sensor.predbat_alertfeed_status” and expected a simple Active or Inactive state but that’s not the case.
What I did find was “Keep” and “Alerts” as attributes.
Am I correct in thinking that “Keep” which is currently zero would change to a value of 40 (in my case) in case of an active alert? If so I could therefore use this information as my automation condition.
If not, if anyone has an idea of how to add a condition for an active weather alert to an automation I would appreciate the help.

S
#1799 SteveCook

Deleted APIs from GivEnergy portal yesterday PM, restarted inverter. Have checked all other settings.
Run along nicely today at 40% until 16:30 and now discharging!!??
No strange commands on remote control history, the last being turning off ECO7 charge at 07:30


I have now hit the "reset to deafult" and will see what happens. Predbat set to 40% reserve

G
#1800 geoffreycoan

Goshiki2 I would like to use the status of the weather alert as a condition in an automation so I found the entity “sensor.predbat_alertfeed_status” and expected a simple Active or Inactive state but that’s not the case.
What I did find was “Keep” and “Alerts” as attributes.

I don’t know, I’ll have to look at the code and see how it works, and update the documentation with what I find!

If the attributes are not obvious I can see about adding some more as to make it easier to use. Glad to hear it worked so well for you. Personally its turned off for me because I found it crashed predbat when it couldn’t connect to the alert service - fixing that is on my to-do list as well …

G
#1801 Goshiki2

geoffreycoan Thank you. It worked perfectly this time. I was very pleased with it so if it could be tied in to automations it will be extremely configurable.

G
#1802 geoffreycoan

Goshiki2 OK so a quick look at the code (its alertfeed.,py for those following along at home)

the line that writes the status entity is line 147:

self.dashboard_item("sensor." + self.prefix + "_alertfeed_status", state=active_alert_text, attributes={"friendly_name": "Weather alerts", "icon": "mdi:alert-outline", "keep": alert_keep, "alerts": alert_show}, app="alertfeed")

so sensor.predbat_alertfeed_status as you have found

state is the textual description of the alert
ignoring the icon attribute, friendly name and app name, the attributes are keep and alerts

Goshiki2 Am I correct in thinking that “Keep” which is currently zero would change to a value of 40 (in my case) in case of an active alert? If so I could therefore use this information as my automation condition.

You are correct, if an event is active NOW then keep will be set to the keep % you configured in apps.yaml, otherwise it will be zero.

alerts is a dictionary containing details of any current or future events that match your lat & long, severity, alert type, certainty, etc. The dict contains a list of fields for the event (severity, certainty, area, onset time, expiry time, etc)

I'll write something up in the documentation

G
#1803 Goshiki2

geoffreycoan Perfect. So I can use the keep value as a condition. Many thanks for your help. It’s much appreciated.

S
#1805 SteveCook

With my Gen1 Hy5.0 inverter showing reserve set at 40% and predbat set to monitor, Things bobbed along at 40% until 16;30 and then battery started discharging to deal with house load - not a max rate discharge. There is nothing else set anywhere, and nothing in remote control logs telling the inverter to ignore the 40% and continue in Eco mode

G
#1806 geoffreycoan

SteveCook I think we’ve exhausted all ideas Steve, time for GivEnergy support?

It seems inverter time slot related if it consistently occurs at 16:30 and there’s nothing in the logs to indicate a command was sent to the inverter. You’ve done a reset to defaults of the inverter, have you tried setting the discharge 1 and 2 slots to 00:00 start and end time to disable them? There’s only 2 slots so can’t be anywhere else

S
#1807 SteveCook

geoffreycoan
Geoffrey
Thanks
I will try sending something to GivEnergy, but expect many questions coming back rather than an answer.
Just checked and I had previously set the 2 discharge slots to 00:00 start and 00:00 end.
That is what they are both now showing.

G
#1808 Goshiki2

SteveCook At the risk of repeating previous advice, have you actually pressed the small arrow to “read” the value in the portal rather than just viewing it as 00:00?
I say this because I had a similar problem when my system was new and it turned out to be a rogue setting that was displayed as 00:00 but was actually displaying something completely different after I had read it.
Apologies if you have tried that, I’m only trying to help.

S
#1809 SteveCook

Goshiki2
Thanks
Yes I have, but will do it again to make sure
I have changed % reserve from 40% to 45%, hit save and then gone back to 40% and hit save.

EDIT
Done them all again and and portal says "read successfully" for times and "written successfully" for % reserve

G
#1810 Goshiki2

SteveCook Just a thought, if you read or change the times are the read / writes actually being shown in the logs?
It might also be worth joining the GIVTCP Facebook group and posting there as a few Giv employees are quite active and often give good advice.

S
#1811 SteveCook

Goshiki2
In the logs, the battery reserve is shown changing from 45% to 40%, but there is no log for DC discharge changing.
Maybe nothing records if I change from 00:00 to 00:00, as there is no change?
I will put in something like 00:30 and then change it back and see if it is logged

EDIT #1
The change to 00:30 is logged
I will now put it back to 00:00

EDIT #2
Change back to 00:00 is logged

G
#1812 geoffreycoan

SteveCook I think I had suggested that you change the times to something else and then back to 00:00 to be sure that this value was being written to the inverter

you've done eveyrthing I can think of. As Goshiki says you may get a faster response from the facebook group than support if this doesn't work. Very strange

G
#1813 Goshiki2

SteveCook Very strange. It might be worth waiting until 4:30 when it starts to discharge and then doing a very short force charge to see if it then tries to override it. That way at least the change should appear in the log to give you a bit more information to go on.

S
#1814 SteveCook

Thanks. For the last week I have used to phone app to force a charge at around 18:00 to get back towards 40% unless there is a power cut. The force charge appears and works.

S
#1815 SteveCook

geoffreycoan
Geoffrey. I think I had done this (cant remember as I have tried so many things). Anyway, I know I have done it now and it is logged on the inverter.
Wait until later this PM

EDIT #1
13:30 now and holding flat at 40% and importing from the grid

EDIT #2
16:30 and battery just started discharging to to power house demand
No commands in remote control history since 12 ish when i set the times to make sure they stuck
"Enable DC Discharge" slider is OFF in the remote control section of the portal

Hitting the + button on the phone app starts charging and registers in the portal history

EDIT #3
Question posted on GivEnergy Facebook site.

G
#1816 geoffreycoan

SteveCook hope you get an answer on the facebook post. Enable DC Discharge is only on when you are doing a force export. For Eco mode its not on

Could you post a screenshot of your settings in the portal just in case anything jumps out.
And (not that I think this is the issue), can you check the inverter time? Either the BBC basic app, Android rubik cube app or givtcp should give you this.

S
#1817 SteveCook

geoffreycoan
Geoffrey. Inverter time seems correct as portal graph matches real time through the day and I have seen charge kick in and out in real time. I looked in GivTCP and my inverter time matches my PC clock

G
#1818 geoffreycoan

there’s nothing there that looks wrong Steve. Truly a mystery

S
#1819 SteveCook

Well, I call that good customer service, I only posted the question on the GivEnergy beta forum 2 hours ago and The Dragon has replied.

My current setup. I will post what happens

S
#1820 SteveCook

That was quick. Now on DO499-AO499

G
#1821 geoffreycoan

SteveCook Excellent, if you get Paul’s attention then he’s very quick and positive, if sometimes a bit brief in details. I’ve never heard of a bug with the Gen 1 ignoring reserve value.

Since you’ve had your inverter firmware upgraded you may well find that you now have battery pause functionality as well as the fast response function. These have been in the Gen 1 beta versions for ages but for some reason never released (I’m on 187/187 but was on 191/193 for a long while)

P
#1822 pwdst

Sounds like we should all start hanging around on the beta forum. I miss having staff involvement as even with the very knowledgeable people here there are always going to be gaps on what is publicly known and system access.

T
#1823 The Black Cat

pwdst Sounds like we should all start hanging around on the beta forum.

How do we get access to the beta forum?

S
#1825 SteveCook

Strange why it worked during the day and then stopped holding the reserve at 16:30 each day.
Oh well we will see later

EDIT #1
Battery just hit 40% and inverter gone to idle and house now running on grid - all good

T
#1827 The Black Cat

Thanks SteveCook and PianSom. I've registered with the beta forum.

S
#1828 SteveCook

SteveCook
16:45 come and gone and battery still holding 40% and grid import is supporting house load.
The 16:30 unwanted battery drain appears to be over
Looks like the Dragon's firmware update has fixed things

#1829 Hook

Had a weird error show up the last few days: "Note: Cannot find battery discharge curve (no final curve found for battery to empty), one of the required settings for soc_kwh, discharge_rate, battery_power and predbat.status do not have history, check apps.yaml"

Never seen that before. It's all set to auto, so I've never had to mess around with battery curves.

Can't see anything obvious.

G
#1830 geoffreycoan

Hook I've had a few people struggle with the same error in the last month or so, so ended up digging into the code and then updated the documentation https://springfall2008.github.io/batpred/apps-yaml/#battery-chargedischarge-curves

If predbat can't generate the charge or discharge curves then it means that in the history it looked at (usually 8 days or so), it couldn't find a charge (or discharge) to near full (or near empty) that was at least at 95% of the full inverter charge/discharge rate - this last bit is crucial. The charge/discharge curves are to identify tail off of charge/discharge performance at full/empty, and predbat can only measure that if your inverter is going at full whack, if its just gently discharging in Eco mode to empty the battery then it won't be able to measure if there is any discharge slowdown.

Its recommended that you don't need to leave it on auto, just let it run in auto, find the discharge/charge curves which are displayed in the logfile and then copy these into apps.yaml.
If predbat has started doing this then look back to find old curves, or TBH our inverters don't tend to have a discharge tailoff so set it just to

  battery_discharge_power_curve:
    20: 1.0
#1831 Hook

geoffreycoan

battery_discharge_power_curve:
20: 1.0

What does the 20 mean?

I copied the setting from the default apps.yaml which had a 4.

battery_discharge_power_curve:
4: 1.0

P
#1832 pwdst

As I understand it he is expressing that at 20% State Of Charge (SOC) the battery will expect discharge at the maximum rate per https://springfall2008.github.io/batpred/apps-yaml/#battery-chargedischarge-curves rather than reducing as the State Of Charge approaches the minimum.
In this respect it is fairly arbitrary if 4 or 20 is used, although it might be configured like this if a reserve is retained for backup or arbitrage purposes.

G
#1833 geoffreycoan

pwdst yes, correct. Any number will do really, its just to populate the battery_discharge_power_curve with something to stop Predbat keep on trying to generate the curve when it can't. Any missing percentage values are assumed to be 1.0, so whether you use 4, 5, 10 or 20, it'll all have the same effect.

Other manufacturer inverters have higher hard limits. The Solis inverters have a hard lower limit of 10% and warnings that doom will happen if you go below that. Our GivEnergy inverters seem better protected in that respect

#1834 Hook

Thanks, at least it's making better estimates now on it's predictions.

G
#1835 Guybrush-Threepwood

Has anyone else had their Boolean toggles in config all reset to default in a recent update?

I noticed I was now getting mobile notifications when it switched modes. Checked the config and the numerical changes I’ve made are fine. But the toggles like auto update. Expert mode. Hybrid and others have all reset to default

L
#1836 Leeshore

Guybrush-Threepwood I have just checked and yes every setting has gone to default. I also noted yesterday that Predbat had changed to ‘monitor’ as well.

G
#1837 geoffreycoan

good practice (not that I had done it for months, but have done now) is to save your predbat settings select.predbat_saverestore - makes for easy restore if ever required

R
#1838 Rodmac76

Anyone able to advise how to rectify. So discovered it fails to Pause my battery?

Web Socket result failed {'id': 26, 'type': 'result', 'success': False, 'error': {'code': 'home_assistant_error', 'message': 'Device not connected to local push notifications'}}
14997 2026-01-14 05:30:12.250144: Warn: Web Socket result failed {'id': 106, 'type': 'result', 'success': False, 'error': {'code': 'home_assistant_error', 'message': 'Device not connected to local push notifications'}}
13310 2026-01-14 05:01:17.099004: Warn: Web Socket result failed {'id': 105, 'type': 'result', 'success': False, 'error': {'code': 'home_assistant_error', 'message': 'Device not connected to local push notifications'}}
12730 2026-01-14 04:50:32.780164: Warn: Web Socket result failed {'id': 100, 'type': 'result', 'success': False, 'error': {'code': 'home_assistant_error', 'message': 'Device not connected to local push notifications'}}
10101 2026-01-14 04:01:51.921014: Warn: Web Socket result failed {'id': 93, 'type': 'result', 'success': False, 'error': {'code': 'home_assistant_error', 'message': 'Device not connected to local push notifications'}}

G
#1839 geoffreycoan

Rodmac76 I am wondering if that is a secondary error from Home Assistant trying to send a push alert to your mobile device but failing to do so?

Have you set the mobile alerts in apps.yaml and installed the HA companion app on a mobile device?

You say predbat is failing to pause your battery. What type of inverter and firmware are you running, only newer inverters support battery pause functionality.

R
#1840 Rodmac76

geoffreycoan thanks I have a HY Gen 2 all been working ok for a while I must have changed something when I tried to configure my HyperVolt charger. I set up my mobile in the companion app to see if the error would cease, but I have never had updates setup.

G
#1841 geoffreycoan

Rodmac76 I’ve not seen that error before, but as it mentions push notifications I thought it was probably from the mobile alerting

for mobile alerting, configure your mobile device id in apps.yaml https://springfall2008.github.io/batpred/apps-yaml/#notify_devices

and there are switches to determine what alerts you get https://springfall2008.github.io/batpred/customisation/#notifications

Battery pause is all configured in apps.yaml https://springfall2008.github.io/batpred/apps-yaml/#schedule pause_mode, pause_start_time and pause_end_time all point to the appropriate givtcp entity names

I would check the predbat logfile that there are not other errors/warnings around the time you get these push notification errors from HA

R
#1842 Rodmac76

Thanks @geoffreycoan managed to setup my mobile device and this has rectified the issue. Really appreciate your support on this channel.

B
#1843 browellm

Anyone else updated to Home Assistant OS17 and noticed their predbat plan updates are now much faster? Mine have gone from mid-late 20s to somewhere between 3-18s!

Word of caution regarding this option:

I took a snapshot of my VM before trying this. It didn't go well, with my predai container throwing an error meant it wouldn't start and I didn't have the first idea how to fix. I reverted to my snapshot.

#1844 Hook

I have noticed that it’s changing my plan a lot more often.

Today it’s been shifting around my export all over the place.

G
#1846 Goshiki2

Hook I upgraded this morning and my export slots are all over the place. When I went into the config I found a number of switches had reset to default including combine charge slots and combine export slots. All sorted now.

G
#1847 geoffreycoan

Goshiki2 there's been a few people reporting other similar things. Worth saving your settings before upgrading. Maybe the new HAOS causes something to get reset in HA?

B
#1848 browellm

geoffreycoan That was helpful info. I re-ran the docker migration command and it's come back up gracefully this time. Seems like I hadn't given OS17 enough time to settle down before running it the first time around.

B
#1849 browellm

Goshiki2 Well that's my speedy plan calculations accounted for 🙂

G
#1850 geoffreycoan

I’ve upgraded to the Predbat 8.32.8 and didn’t experience any issues that others have reported with settings getting corrupted.

What I did notice is that predbat.cost_today isn’t increasing, it’s stuck on -0.01p all day. I upgraded the Predbat release last night at about 10pm and cost_today increased fine through the evening Cosy charge period, but the overnight charge 4-7am when there wasn’t any upgrades, cost_today didn’t increase.

I tried reverting back to 8.32.3 and cost_today still not incrementing. Went back to .8, then .9 and .10 as they came out today and it’s still not working. Very weird. Predbat is getting the rates from Octopus correct, the rates entity contains the right right, the Octopus integration accumulated cost is increasing, but cost_today that I have on my home dashboard seems stuck.

Very strange.

I haven’t upgraded the HAOS version yet, seems that the docker container upgrade can take a while. Think I’ll wait until HAOS 17.1

L
#1851 Leeshore

geoffreycoan Predbat.cost_today is correctly working for me. I’m on HAOS 17.0 and predbat is up to date.

G
#1852 Guybrush-Threepwood

My issues with Predbat toggles resetting seems to be after a restart of HA and was happening prior to HAOS 17.0. I started a couple of predbat updates ago. Restarting addon doesnt cause it, just a restart of HA after updating an integration or something similar.

For those having it and tired of setting up again goto the Config tab in Predbat and search for saverestore. With this you can save the config and restore after the reboot borks things

G
#1853 geoffreycoan

Leeshore it seems that the problem with cost_today not incrementing was caused by GivTCP import_today not incrementing https://github.com/springfall2008/batpred/issues/3273#issuecomment-3789189412

I raised an issue on it and Trefor pointed me in the right direction. Curiously it was working fine today, so something went wrong in givtcp yesterday and that sensor stopped updating from the inverter. The portal had the right sensor values so the inverters were fine, but not givtcp in HA entities or via REST. Maybe if I'd restarted givtcp then that would have cured it.

Weird.

Guybrush-Threepwood For those having it and tired of setting up again goto the Config tab in Predbat and search for saverestore. With this you can save the config and restore after the reboot borks things

Don't know why its doing this, makes me wonder if its some kind of corruption in the settings somewhere that predbat is complaining about. Is there anything in the predbat logfile or the predbat addon log to indicate a problem?

G
#1854 Guybrush-Threepwood

geoffreycoan ill have a check of the logs next time it happens. No warnings or errors

T
#1855 TX200

Thought PredBat was broken post HA update

Looks like some entities have been renamed, had to copy the dashboard from the PredBat directory via file editor into the dashboard itself.

Fine after that.

G
#1856 geoffreycoan

TX200 strange. Was this a HA update to 2026.1 or the HAOS 17 update?

I’ve been running HA 2026.1 with no ill effects but not done the HAOS upgrade, but that is changing the run-time environment that HA runs in, it shouldn’t affect HA entities at all? Maybe some of the control entities that are used to indicate givtcp or predbat addons are running might change?

T
#1857 TX200

geoffreycoan from 15.x to 16.3 I think it was. Not done the HAOS 17 yet.
I don't think it was home assistant, got to be PredBat, unless the dashboard got corrupted by the HA upgrade. Most of the entities after predheat were broken.

T
#1858 TX200

Not sure what was going on this evening

After the saving session export, PredBat said it was in demand mode, but I was importing from the grid (battery circa 20% left).

Tried turning eco mode and DC discharge on in the GivEnergy portal, but after a short while something turned it off.

Restarted PredBat, but it didn't help. Put it in read only mode, didn't help. Stopped PredBat (monitor mode).

Spotted that the control mode was timed demand, so switched that to ECO. Hoping it'll behave itself now!

G
#1859 geoffreycoan

TX200 you shouldn't need to turn DC discharge on on the portal, that's only on when the battery is exporting, as long as Eco mode is on, that should be enough,

Timed demand is an odd one, its not a mode that Predbat ever sets. Maybe it got set when you turned DC discharge on, strange though.

I have a set of givtcp controls on my dashboard so I can easily double check that Predbat has set the right modes and I can quickly change them (well, until 5 minutes later when predbat overwrites!). Might be worth doing similar. The detailed charge/discharge settings are in a collapsible section so it reduces dashboard size:

T
#1860 TX200

geoffreycoan to be fair, I might have turned DC charge mode on in error. But deffo had to turn Eco on first time I spotted the issue.

I've got a controls panel similar to yours, but I didn't spot the mode was in timed discharge. I guess maybe the mode changed as a result of me trying to sort the problem.

T
#1861 TX200

TX200
According to HA activity log

5:31:46 mode changed to timed export (DFS!)
6:31:08 mode changed to eco
6:31:54 mode changed to timed export
6:35:29 mode changed to eco (probably me)
6:35:43 mode changed to timed export
6:35:59 mode changed to timed demand (probably me)
6:37:37 mode changed to timed export
6:42:17 mode changed to eco (me again?)
6:42:44 mode changed to timed export
6:43:59 mode changed to timed demand
6:44:37 mode changed to timed export
6:45:42 mode changed to timed demand
6:47:10 mode changed to eco (at which point PredBat had been restarted, put into monitor mode and givtcp restarted too!)

It's been fine since. PredBat is back in full control mode.

G
#1862 geoffreycoan

TX200 so looks like Predbat wanted to remain in timed export mode. Are you on agile outgoing which would have made it worthwhile to continue to export?

I didn't have any such issues, predbat only exported for the DFS session and went back to Demand afterwards

BTW, if you find Predbat is in the wrong mode, the easiest way to overwrite it is to just do a manual override of the plan. Either use the select.predbat_manual_xxxx controls, or click on the slot time in the plan (either the plan in the web console, or the pacemaker82 predbat table card has this functionality to easily choose a different plan activity)

T
#1863 TX200

geoffreycoan it's strange as the PredBat plan showed the little diagonal down arrow (use the battery?) and the status at the bottom of the PredBat card said demand.

I'm on the static 15p export rate.

G
#1864 geoffreycoan

Experienced Predbat getting itself into Monitor mode tonight. Others have reported similar behaviour, although looking at my configuration, only predbat mode got changed, all the other settings remain as I had them.

I restarted HA this evening at 21:30, Predbat would have had some errors in the background because it couldn't connect to HA at the time, and ordinarily it sorts itself out so I didn't even check it was working OK.

At 22:30 I happened to notice that the battery wasn't charging as it should have been from 22:00 in the Cosy cheap period. Predbat was in Demand status even though I had some force charges set to ensure the battery charges for the full 2 hours to see me through the night in case it is unexpectedly cold and the heat pump comes on.

In the Predbat log I could see the websocket errors that occurred when I restarted HA, and after a while Predbat restarted itself as HA wasn't available, and there were lots of apps.yaml validation errors as HA wasn't fully running, but then it had settled down with the following warnings repeating:

2026-02-04 22:22:10.662661: Warn: can not resolve soc_kw value sensor.h_{geserial2}_soc_kwh
2026-02-04 22:24:25.073594: Warn: can not resolve soc_kw value sensor.h_{geserial2}_soc_kwh
2026-02-04 22:25:00.473573: Warn: can not resolve load_power value sensor.g_{geserial}_load_power
2026-02-04 22:25:00.473698: Warn: can not resolve load_power value sensor.h_{geserial2}_load_power
2026-02-04 22:25:00.473732: Warn: No power data provided to fill_load_from_power
2026-02-04 22:25:00.473769: Warn: can not resolve import_today value sensor.g_{geserial}_import_energy_today_kwh
2026-02-04 22:25:00.473803: Warn: can not resolve export_today value sensor.g_{geserial}_export_energy_today_kwh
2026-02-04 22:25:01.456635: Warn: can not resolve pause_mode value select.g_{geserial}_battery_pause_mode
2026-02-04 22:25:01.482550: Warn: can not resolve pause_mode value select.h_{geserial2}_battery_pause_mode
2026-02-04 22:25:01.494613: Warn: can not resolve soc_kw value sensor.h_{geserial2}_soc_kwh
2026-02-04 22:25:02.937223: Info: record_status Demand

Wasn't sorting itself out so I restarted the Predbat addon which cured these warnings, but predbat went back into Demand mode despite what the plan said.

Then I realised that predbat mode was set to Monitor at around 21:35 when it was failing to connect to HA

Changed it back to Control charge and discharge and it immediately started charging the battery. Very odd. One to watch, and also to try to work out how to trap it if it reoccurs

L
#1866 Leeshore

geoffreycoan I have written an automation. After every restart my Predbat goes into monitor mode. My automation warns me and then resets all of my values.

` alias: Predbat - Auto Exit Monitor Mode (iOS Critical)
description: If Predbat enters monitor mode, sends critical alert and returns state
back to Control charge & discharge
triggers:

  • trigger: state
    entity_id:
    • select.predbat_mode
      for:
      hours: 0
      minutes: 0
      seconds: 10
      conditions: []
      actions:
  • action: notify.mobile_app_xxxxxxx
    metadata: {}
    data:
    message: "\U0001F6A8 Predbat in Monitor Mode"
    title: Predbat entered Monitor mode. Reverting to Control (charge & discharge
    data:
    push:
    sound:
    name: default
    critical: 1
    volume: 1
  • action: switch.turn_on
    metadata: {}
    target:
    entity_id: switch.predbat_expert_mode
    data: {}
  • action: select.select_option
    metadata: {}
    target:
    entity_id: select.predbat_mode
    data:
    option: Control charge & discharge
  • action: number.set_value
    target:
    entity_id: input_number.predbat_metric_min_improvement_export
    data:
    value: '3'
  • action: number.set_value
    target:
    entity_id: input_number.predbat_metric_battery_cycle
    data:
    value: '1'
  • action: number.set_value
    target:
    entity_id: input_number.predbat_inverter_loss
    data:
    value: '0.06'
    mode: single`
G
#1867 geoffreycoan

Leeshore I have written an automation. After every restart my Predbat goes into monitor mode. My automation warns me and then resets all of my values.

Interesting that your Predbat is consistently going into monitor mode. People that have mentioned it before, it seemed to be a one-off (as I assumed it was for me). I did think about writing an automation or extending the existing error detection automation, but will wait to see if it happens again.

But if this happens consistently for you, then do raise a bug on it as it shouldn't be doing that. I assume there is some kind of race condition occurring between Predbat and HA starting, Predbat starts slightly quicker, can't get a connection to HA so initialises its settings with the out of the box defaults not what you have set to in HA.
If you restart Predbat does it sort out its settings correctly?

G
#1869 Guybrush-Threepwood

My problem seems to be when HA is restarted. Predbat comes back, default settings, loads the "Previous settings" but those are just the default. I have a yaml saved using the saverestore and that brings me back. Not logged it yet as I was trying to figure out the actual conditions to re-create it.

G
#1870 geoffreycoan

Guybrush-Threepwood please do add to the above ticket. I added my own analysis and log files last night, there definitely seems to be a new bug in this area

G
#1871 geoffreycoan

Just updated to HA 2025.2.1, the upgrade works fine but when HA was unavailable Predbat wasn't happy, restarted itself, decided my solar wasn't configured and then sulked giving no solar forecast for tomorrow. Everything else in Predbat was running fine, I was getting a plan, just with no solar.
Restarting the solar component didn't fix it, but a full predbat restart did.

I've been using custom sidebar icons for ages in HA, making it easy to navigate straight to Integrations, Add-on's and Automations. Here's an updated version for Add-ons now being renamed as Apps (but the control panel has also moved inside HA rather than being a supervisor function so the URL changes), and a new entry for Developer Tools which has moved to a sub-menu in Settings.

# Custom side-bar entries
panel_custom:
  - name: ha_integ
    sidebar_title: Integrations
    sidebar_icon: mdi:chip
    js_url: /api/hassio/app/entrypoint.js
    url_path: "config/integrations"
    embed_iframe: true
    require_admin: true
    config:
      ingress: core_configurator
  - name: ha_auto
    sidebar_title: Automations
    sidebar_icon: mdi:cog-outline
    js_url: /api/hassio/app/entrypoint.js
    url_path: "config/automation"
    embed_iframe: true
    require_admin: true
    config:
      ingress: core_configurator
  - name: ha_app
    sidebar_title: Apps
    sidebar_icon: mdi:content-save-cog-outline
    js_url: /api/hassio/app/entrypoint.js
    url_path: "config/apps"
    embed_iframe: true
    require_admin: true
    config:
      ingress: core_configurator
  - name: ha_dev
    sidebar_title: Developer Tools
    sidebar_icon: mdi:developer-board
    js_url: /api/hassio/app/entrypoint.js
    url_path: "config/developer-tools"
    embed_iframe: true
    require_admin: true
    config:
      ingress: core_configurator

add the above lines to your configuration.yaml and restart HA

R
#1872 Rbor

Thanks you for the code for your sidebar 'shortcuts'.
I once again have Developer Tools one mouse click away in the Sidebar.

The developers must have had a good reason for hiding Developer Tools away.
I can't understand the logic of doing so.

Rob

G
#1873 geoffreycoan

Rbor I think the move is about making it simpler for new users, hiding complexity away.

In the release notes for 2025.2 it says they are exploring ways to make the side bar customisable, so at least they realise that one size doesn't fit all and people want quick access to things they want to do in HA.

There's also mention that the Energy dashboard now supports power sensors in other formats, so you can configure that the grid power sensor has an inverse sense to what HA is expecting:

Great I thought, that means I can do away with the template helper entity sensor.grid_power I'd had to create to inverse the grid power entity from givtcp. Turns out that the Energy dashboard creates its own entity called 'grid_power_inverted' to store the inverted value required by the Energy dashboard. So no saving on entities in HA, just a more out of the box way of doing it than creating a template sensor. Phah

W
#1874 wrighar

I notice 'Settings' is no longer in the scrolling portion of the left bar, great for when I'm on my old laptop with a small screen as terminal, to-do lists and setting used to be off the bottom of the screen.

R
#1875 Rbor

wrighar I notice 'Settings' is no longer in the scrolling portion of the left bar, great for when I'm on my old laptop with a small screen as terminal, to-do lists and setting used to be off the bottom of the screen.

Yes, this is a good change. It saves having to scroll down the sidebar to reach 'Settings'. It didn't seem possible to move 'Settings' up the order before.

geoffreycoan Rbor I think the move is about making it simpler for new users, hiding complexity away.

In the release notes for 2025.2 it says they are exploring ways to make the side bar customisable, so at least they realise that one size doesn't fit all and people want quick access to things they want to do in HA.

I went all the way through the release notes for 2026.2.1 this morning.
Half of the release notes contains user comments. There are many complaining about Developer Tools being moves. there are also many comments about the new Home database and changing the name of 'Add-ons' to 'Apps'. I spent a long time last night trying to get to grips with this Home database. It was in the Database page but not in my sidebar. I then discovered, by accident, that you have to select the Home Database option to see another window with options within it. I didn't select any of the options but at least the Home database then appeared in the sidebar. My 'databases' also now had two databases named 'Overview, something that I thought wasn't allowed by HA. The new Home database had also been changed to the 'default' despite it not appearing in the sidebar.
The Home database looks very much like the Areas database which I have now deleted.

In the Settings page, there are two really important buttons for System and Developer Tools. To reach these, I have to first scroll down the page. There is no way of changing the order.
Above System and Developer Tools, I see buttons to the HA Cloud, Areas, Voice Assistants and Tags, which I have never used.
I think the only way to restart HA is via the Systems button or Developer Tools button.

I hope that the developers do introduce options for the content of the Sidebar in a future release.

Sorry for appearing to diss Home Assistant.
It is a remarkable tool but it is difficult that I depend on.
I get frustrated when features that I have learnt get moved. I would welcome a short 'Key features' file summarising the key changes in a release, without having to wade through the very long release notes that accompany each release. I rely heavily on Smart Home Junkie's videos to alert me and comments on community sites, such as this.

Rob

G
#1876 geoffreycoan

Rbor On the bottom of the release notes you get the community feedback on the release notes. They are sometimes interesting, but often not. It is worth reading though the release notes to see what has happened as well as watch smart home junkie and other similar videos.

The new Home dashboard replaces the old 'Overview' dashboard, and is a huge improvement in terms of usability because the Overview was just a list of all your devices and then all their entities, so rapidly became unusable, especially with things like givtcp creating 10 devices.

I watched a Bearded Tinker video about the new release, interestingly different, His takeaway message was that HA is moving in the direction of dashboards being largely irrelevant to a smart home, other than setup and initial configuration, the smart home should just be 'smart' and shouldn't need you to interact with it, and he saw that as being the clear direction HA was going in. The new intent automations being another example of making the smart home easier to create and maintain.

I countered with a comment that it depends on how you use Home Assistant. If its smart devices like lights, windows, alarms; then yes, you don't really need a dashboard, but if its informational like home solar production and battery storage management then dashboards still are needed.

Today I went through and updated the Predbat documentation for HA 2026.2. Developer Tools was easy as its only referred to about 6 times in the documentation. Add-on's had over 130 mentions ....

R
#1877 Rbor

geoffreycoan I watched a Bearded Tinker video about the new release, interestingly different, His takeaway message was that HA is moving in the direction of dashboards being largely irrelevant to a smart home, other than setup and initial configuration, the smart home should just be 'smart' and shouldn't need you to interact with it, and he saw that as being the clear direction HA was going in.

Thanks. I have watched the Bearded Tinker video and he gives an interesting perspective on 2026.2 and where HA may be moving in the future. There are a few bugs. I could see 'Apps' and 'Add-ons' on different screens. I will read through the release notes of 2026.2 again.
I tried Everything Smart Home but he was flipping between screens so quickly, I was going dizzy. I could actually see what he selecting (at which point I gave up). Smart Home Junkie was much better.

geoffreycoan Today I went through and updated the Predbat documentation for HA 2026.2. Developer Tools was easy as its only referred to about 6 times in the documentation. Add-on's had over 130 mentions ....

This reminds me of when I was trying to learn HA before I found Predbat.
I found some videos but the screens and options were all different from what I could see. The chopping and changing of headings and names makes HA doubly difficult to master and support videos to rapidly go out of date.

I did find a HACS application today called 'Custom Sidebar'.
I installed it, which had to be done manually, via www and configuration.yaml, I restarted HA but I couldn't work out how to run the application! I couldn't see anything in the Readme on Github. So I gave up ........ Another wasted half an hour!

Rob

L
#1878 Leeshore

Total amount of solar so far in February in sunny Yorkshire is 19kWh. Amount predicted for Saturday is 20.9kWh. 5.16kW array!

R
#1879 Rbor

Leeshore Fellow Yorkshire resident. 800' up to West of Sheffield in foothills of Pennines.
9.75 kWh array.
Feb 1st-11th have produced 26.5 kWh with 7.5 kWh of that yesterday.
For most of this year, I have been in hill fog with perpetual drizzle or rain. I have had many days below 0.5kWh
On Saturday 14th, Predbat predicts 23.6 kWh for me. Let's see ...
If even a hazy sun appears, there is PV generation as the sun's altitude had increased markedly (Midday altitude now 23 degrees against 12 degrees on 21 Dec).
In January 2026, I generated 130 kWh.
In January 2025, I generated 219 kWh.
Grim!

Rob

G
#1880 Goshiki2

Following on from my previous posts regarding the active weather alerts function, I have confirmed during tonight’s alert for my area that the ‘keep’ attribute does indeed change to the preset value stored in apps.yaml and can therefore be used in automations if necessary. Very useful for me and working perfectly.
I have a couple of daily force export and force demand automations which can now be disabled during active weather alerts by adding a condition that ‘keep is <1’

B
#1881 browellm

Slightly out of the loop on new features. Is Load ML intended to replace PredAI?

R
#1882 Rbor

browellm
I have Predbat v8.33.1 installed with ML and Temperature running.
Charts look good and I have data.
And importantly, the Predbat plan looks sensible.

As an ASHP user, I do like the idea of temperature influencing the plan.
That was my main attraction to using ML.

Read the ML documentation very carefully (again and again).
https://springfall2008.github.io/batpred/load-ml/

And take heed of this:

- Ensure you have a least a weeks worth of data before enabling load_ml_source.
- Make sure you do not have PredAI enabled at the same time
- Disable in day adjustment (switch.predbat_calculate_inday_adjustment) as the AI model will do that for you.

I think it should be sufficient just to stop predai from running.
I have uninstalled it from my installation.
Form running Predai, you will be aware of its large footprint, as demonstrated in the Predai logs.
With ML, you hardly know it is there.

It is early days and ML has had limited testing.

When first setting it up, think about setting load_ml_source: to false, as explained here in the documentation:

 # Enable ML load prediction
  load_ml_enable: True
  # Use the output data in Predbat (can be False to explore the use without using the data)
  load_ml_source: True

In the webUI, You get extra charts and entries in Dash.

Rob

G
#1883 geoffreycoan

browellm yes I think that's the strategy. Its lighter weight and quicker to run, more directly integrated into Predbat.

I never tried PredAI but have been testing and now running with Load ML for the past few days, Raised and got fixed an issue in it (specific to my twin GivEnergy inverter setup) and its been working great.

The big thing missing for me in Predbat load forecasting was that it had no idea of temperature, so with a heat pump that uses more energy when its colder, the forecast would be either over or under optimistic. I found I had to set a bunch of manual force charges to ensure that Predbat always charged the battery in the cheap periods in case it was a colder night and the heat pump was running. So far with Load ML I have found it gives a better plan and I've been able to remove the force charges and let Predbat plan itself.

Yesterday was pretty accurate (cold day), today is weird. It was forecasting 10kWh to end of the day, now its down to 5kWh which doesn't accord with the plan, strange

B
#1884 browellm

Rbor Read the ML documentation very carefully (again and again).

Jesus, I read the docs twice and missed that! Thank you.

I totally agree with you about the temperature integration. I don't have a heat pump but my electricity usage is still very much correlated to external temps - general house load and electric underfloor heating in the kitchen.

R
#1885 Rbor

browellm You will find that you already have some settings in your apps.yaml.
I found the only settings I had to add were those of load_ml and for temperature_enable

It is nice having something really new in Predbat and fun to investigate ML.

Rob

B
#1886 browellm

Rbor I used PredAI and enjoyed it but this does look like an enhancement. I will need to do some clean up of the charts that sit outside of predbat once this is settled in.

G
#1887 geoffreycoan

re the above, it seems despite yesterday's loadML forecast being great and a better plan, today its having a bad day and every time I turn load ML source to True I get an artificially low load forecast (as above). Have raised a bug https://github.com/springfall2008/batpred/issues/3367 and turned load ML source to off for now

B
#1888 browellm

geoffreycoan Could it be some glitched historical data from the recent REST issue you raised into Trefor?

G
#1889 geoffreycoan

browellm its possible but I'm not sure. The issue I had was affecting predbat.load_power being artificially high. Trefor tried to fix it on Friday and made it worse, that was then fixed later on Friday (top graph):

the inverter power (bottom blue) I only hold a couple of days history in predbat, and was planning on swapping to my new custom load power sensor (bottom yellow) once I had some history built up, but since I now have more history than of the inverter load, I have changed apps.yaml to use it

The load ML instructions only refer to needing a decent load_today (energy) sensor and that was OK and hasn't been changed at all https://springfall2008.github.io/batpred/load-ml/#step-1-verify-prerequisites

R
#1890 Rbor

geoffreycoan I have added my logs, charts, etc to your latest issue on Github.
I am not experiencing your problems but this is a new run started just after 10 am this morning.
I finally found the correct log file (predbat.log) that contained all my ML data.
I had never seen this but I was looking at the predbat addon log and WebUI log.
My ML load_forecast is on a different order of magnitude from yours.
In my apps.yaml, I have just set the defaults for load_today and load_power,
i.e.

  load_today:
    - sensor.givtcp_{geserial}_load_energy_today_kwh
  load_power:
    - sensor.givtcp_{geserial}_load_power

See:
https://github.com/springfall2008/batpred/issues/3367

This is my load power chart (I am in W) for the last 24 hours.

Rob

G
#1891 geoffreycoan

Rbor I don't know what is going on with load ML. First few days it produced sensible load projections, even when there was an over-stating of predbat.load_power. There's part of me thinks it is related to partial sensor history (I generally aggressively purge my sensors to keep the database under control) and the false 'gaps in load_today' that get reported, but that doesn't explain why it was fine for the first few days when if anything there was less history present.

I suspect a new bug in 8.33.1 that wasn't there in .0, but I don't know.

Its back to creating completely wrong forecasts now:

G
#1892 geoffreycoan

geoffreycoan I suspect a new bug in 8.33.1 that wasn't there in .0, but I don't know.

my hypothesis appears to be correct. With 8.33.0 the load ML predictions look sensible and its repeatable, 8.33.1=artifically low forecast, 8.33.0=OK forecast. I’m now not the only one on github. reporting this issue.

T
#1893 The Black Cat

If I check the predbat_ml_model.npz file it has then following:-
'utf-8' codec can't decode byte 0xb8 in position 14: invalid start byte

Any ideas on what might be causing this?

G
#1894 geoffreycoan

The Black Cat what do you mean ‘check the file’ ?

As far as I know its a predbat internal file format.

I was able to open it with Runestone editor on my ipad, it appears to contain a bunch of binary characters followed by JSON data:

PK-!璏Aÿÿÿÿÿÿÿÿmetadata_json.npyX0X0“NUMPYv{'descr': '<U35830', 'fortran_order': False, 'shape': (), }
{"model_version": 5, "lookback_steps": 288, "output_steps": 1, "predict_horizon": 576, "hidden_sizes": [512, 256, 128, 64], "training_timestamp": "2026-02-15T17:53:18.675927+00:00", "validation_mae": 0.07118836223736864, "epochs_trained": 76, "learning_rate": 0.001, "max_load_kw": 50.0, "feature_mean": [0.11556433141231537, 0.11564196646213531, 0.11565732210874557, 0.11567238718271255, 0.11568774282932281, 0.11570309847593307, 0.11571816354990005, 0.11573351919651031, 0.11579985916614532, 0.11586619913578033, 0.11593253910541534, 0.11599916964769363, 0.11606550961732864, 0.11613184958696365, 0.116153284907341, 0.11617443710565567, 0.11619587242603302, 0.11621701717376709, 0.11623845994472504, 0.1162596046924591, 0.11634071916341782, 0.11642182618379593, 0.11650294065475464, 0.11658405512571335, 0.11666516214609146, 0.11674627661705017, 0.11677263677120209, 0.1167990043759346,

Do you get this error in predbat or were you just trying to open it with a file editor?

T
#1895 The Black Cat

geoffreycoan
Sorry, I used the file editor on HA. I can see the entries if I use the "Browse" option on the predbat web interface, so it seems to be working OK.

G
#1896 geoffreycoan

The Black Cat I get the same error in HA File Editor. I can open it in Notepad on a windows PC. Guess it is an internal format, not for us to be fiddling with !

R
#1897 Rbor

geoffreycoan I see the same message when trying to open the files in HA File Editor.
Some other files give the same message, which is unhelpful.
I don't know how I might access the file in predbat.

I did download the file and tried using various text editor but I just saw gobbledegook, looking like binary characters.
So I gave up.

Rob

T
#1898 The Black Cat

On my "LoadML Power" chart on the Predbat web interface, it shows temperature now (15:00) of 7.1 degrees on the green graph line which is about right, but in the heading it shows 3.2 degrees. Do we know what that is supposed to be referring to?

G
#1899 geoffreycoan

The Black Cat in the heading it shows 3.2 degrees. Do we know what that is supposed to be referring to?

its the way these charts work, the header shows the last value in the data series. So if you look at the PV charts which show a whole day of PV forecast, then the header values are always zero because unsurprisingly there is no solar generation at midnight.

There is a github issue raised on this on the PV chart as it’s confusing. I did look at the code and try to work out how how to suppress the header info as its not that useful on PV, but whilst the charts are Apex charts, the code is quite different from the Apex component for HA and there isn’t as far as I can tell a way of changing the headers.
I went down a rabbit hole on this one and got stopped.

A
#1900 arczi19

I’m on a cheap tariff between 00:30 and 5:30, export tariff of 15p and predbat normally would export everything before 00:30 and then charge to 100% overnight. However, I’m now part of the Axel events and there is one tomorrow at 18:00 - for some reason predbat decided that it won’t be exporting tonight at all. I was able to override it by setting the Axel export rate to 0 from the default 100, but obviously that’s not ideal. Has anyone seen similar behaviour?

R
#1901 Rbor

arczi19 Check that your mode is 'charge and discharge'.

Twice recently, Predbat has unilaterally changed my mode to just 'charge' and I have the same problem.
I have no idea why!
I changed the mode to 'charge and discharge' and Predbat behaved itself again.

Rob

G
#1902 geoffreycoan

arczi19 there are a couple of people who have reported weird behaviour in their plan with axle or weather alert events https://github.com/springfall2008/batpred/issues/3188

Have a look and if its the same, add your plan and log to the issue

At the moment I can only recommend setting manual override export and imports with predbat to get the behaviour you normally see. Strange thing is that I don't have any such bad behaviour with predbat so its suspected its related to the import/export differential and how predbat sets the threshold limits; I'm on Cosy so don't normally force export at all whereas on an EV tariff you will tend to

W
#1903 Wavy Davy

Just had a panic moment, Haven't check predbat for a couple days, but did tonight and the invertor was on min of 4% and the plan had the same value (28.72p) for all the entries.
After checking everything on predbat then restarting HA, I checked my octopus account and found they've switched me from Agile to Flexible Octopus. No warning or anything.
Have filled form in to go back to Agile, but really annoyed with them.
This is the second time the've done this. They did it about 12 months ago if I remember correctly.
I think they just do this at the end of the contract time.

G
#1904 geoffreycoan

Wavy Davy I find a get a quick response from customer service if you message them on twitter, I swapped from Agile Outgoing to Outgoing Variable last week by doing that

Can't blame predbat for your rates being wrong ....

Bit naughty of Octopus, you should have had an email about the tariff coming to an end. Maybe in spam folder?

W
#1905 Wavy Davy

Hi Geoff, Wasn't blaming predbat, .... well I did at first until I checked everything.
I will contact them in the morning but I suspect it won't come to anything.
Nothing in any folder, last email from them was last Oct about free energy.

K
#1906 KamenMacKay

Does anyone else have the Givenergy EV charger? I had one installed back in August and it works alright (except for the incompatibility with IOG part). I'm noticing an issue with Predbat where I've set it to low power charge mode and it appears the EV Charger communicates with the inverter and resets it to a default of 3600W. My evidence of this is this line repeatedly occurring in my Givenergy logs:

2026-03-03 08:42:11.975 Server Battery Discharge Power Written Successfully 3600 3600 3600 EV Charger Inverter Control
2026-03-03 08:40:06.269 Server Battery Discharge Power Read Successfully 0 3600 External Change Detected (Predbat?)

I've gone into the portal and changed it to operate in Standalone mode (which I think should do the trick) but perhaps someone can provide more insight on whats happening here?

G
#1907 geoffreycoan

KamenMacKay yes its the EV charger that is doing this, trying to be too intelligent in controlling the inverter

K
#1908 KamenMacKay

geoffreycoan I suspect it sees the car charging and assumes its a cheap slot so trying to be helpful it sets the inverter to 3600W so the battery will also charge as fast as possible as well. Does anyone know if there is a way to disable this or do we have to message Paul Landregan on Facebook (this seems to be the only way to get things done these days with Givenergy tech support) to get this sorted?
I can report success with setting the EVC to Standalone mode as the "EV Charger Inverter control" messages are no longer appearing in my Givenergy logs.

G
#1909 geoffreycoan

KamenMacKay I don’t have the GE charger so second hand experience, but there is a mode that stops the charge rate being varied. Sounds like you have found it

Cheers

L
#1910 Lincs_Will


I'm a bit confused. Predbat doesn't seem to be making the most sensible plan for ROI on IOG. In the above it does nothing with the 1st 30 mins off peak and then charges the battery to 100% twice but the charge curve would mean its a waste of time charging at slower rates until a final top up when time approaches 0530. I've not changed any settings in ages so is this the result of some updates? Surely it should be constantly charging/discharging and avoiding 90% until the final charge?

Gen 2 5kw inverter and 9.5kwh battery.

G
#1911 geoffreycoan

Lincs_Will its quite possible that predbat has reverted one of your settings to the default value and this is causing your plan to be different. There's an intermittent problem with predbat doing this, it happened to me earlier in the week, seems to happen when HA is upgraded or restarted and predbat can't connect that it restores settings to the defaults

In my case expert mode was turned off and a number of things like battery loss were changed from what I had them set to.

You should be able to restore your settings to the last backup you took https://springfall2008.github.io/batpred/customisation/#saving-and-restoring-predbat-settings

Check your logs for any configuration warnings as well

T
#1912 TX200

Anyone had a "PredBat joined saving session" alert today?

According to octopus I've not auto joined. It said opt in.

Also the PredBat plan isn't showing anything different for that time (circa 22 mins since the alert).

Strange

(The octopus dfs blueprint normally opts me in, rather than PredBat).

G
#1913 geoffreycoan

TX200 I was just looking into the same issue myself

Got a notification but nothing on the plan

in the logfile I can see predbat tried to join, but it failed:

51778	2026-03-09 12:35:02.089502: Warn: Service call octopus_energy/join_octoplus_saving_session_event data {'event_code': 'EVENT_23_090326', 'entity_id': 'event.octopus_energy_a_b09db615_octoplus_saving_session_events'} failed
51777	2026-03-09 12:35:02.084946: Warn: Web Socket result failed {'id': 14, 'type': 'result', 'success': False, 'error': {'code': 'unknown_error', 'message': 'Saving Sessions event not found'}}
51776	2026-03-09 12:35:01.601940: Octopus: Joining Octopus saving event code EVENT_23_090326 Mon 09/03 17:30-18:30 at rate 11.875 p/kWh

and the event shows as available but not joined

its not showing as an available event in the octopus app, so not really sure what is happening

T
#1914 TX200

Strange.

I managed to join it via the octopus web page, rather than app.

PredBat is now showing the increase in export in the plan.

It's not going to export (as it currently stands, it might change it's mind later) as it thinks I'll run out of battery before my off peak IOG starts.

T
#1915 TX200

geoffreycoan looks like it's not available in all regions, only some.

Guessing that might be why it's failed. Perhaps the API has changed slightly.

R
#1916 Rbor

TX200 I wondered whether this was connected to my Octopus_energy update last night.

I then tried checking out Octoplus on the website and found this:

I selected 'were splitting things up regionally this year but couldn't find an explanation from the link'.

But this would explain why some of us are not getting the saving session.

Meanwhile, I am receiving a notification every 15 minutes (linked to predbat I think) to alert me of the savings session! Perhaps Predbat will need to check out eligibility of regions.

Rob

G
#1917 geoffreycoan

Rbor I have the same, not getting notifications every 15 minutes though, only had the single notification when predbat tried to join. Your notifications sound like they are from another automation?

The issue is I think with Octopus API that makes the saving session available but then doesn’t let us join it.

There is details in the saving session event as to what is available for our region, so predbat tries to join.

I’ve raised an octopus integration bug but its probably Octopus API

https://github.com/BottlecapDave/HomeAssistant-OctopusEnergy/issues/1674

#1918 PianSom

For many of us it is worth checking out the updated FAQs. eg

T
#1919 TX200

TX200 and as expected, because I've not used as much as it thought I would, there's room for a saving session export. Currently predicting an export down to 57%.

G
#1920 geoffreycoan

PianSom it is interesting how there is more being highlighted from Octopus about being on different demand flexibility services.

The current DFS session that I can't join as its not in my region, says it is paying 95 Octopoints/kWh, equivalent to 11.9p/kWh. Plus the 12p export rate making a grand total of 23.9p, before battery discharge losses so any export would be limited to what I can export and still run through to the next cheap charging period (10pm in my case on Cosy).

Yet to hear what Axle's offer is once the beta trial finishes this month, but given the choice, I'd opt out of Octopus DFS in favour of Axle given the increased frequency and rates they have offered over Octopus.

#1921 PianSom

geoffreycoan
I thought what was especially interesting was the tacit admission that many customers (presumably including those on Intelligent tariffs) are signed up to other providers - even though this is not permitted under the Intelligent T+Cs.

T
#1922 TX200

Post saving session, playing up again!
Had to restart PredBat app like last time.
The system was left in timed export mode and was pulling from the grid rather than using my battery. Tried changing it to eco mode, but it kept going back to timed export, despite PredBat status saying it was in demand mode.

V
#1923 Vestas

geoffreycoan Its worth reading Octopus' T&Cs for smart tariffs.

You'll be able to see where we're heading in terms of third parties controlling all your "low carbon technology".

This what I was warning about a while back - its already the wild west and it'll get worse. You don't need any infrastructure, just a server and some APIs. What could possibly go wrong with that? Couple of wide boys set it up <cough bulb cough> and next thing you know we're all paying for it. Again.

R
#1924 Rbor

geoffreycoan
I am going to see what happens this month.

If there is another Octopus saving session (that I qualify for), I will move away from Axle.
It would be good though to see Axle's rates going forward from March.

A case of 'watch and see'

Rob

G
#1925 geoffreycoan

Vestas Its worth reading Octopus' T&Cs for smart tariffs.

You'll be able to see where we're heading in terms of third parties controlling all your "low carbon technology".

Yes agreed. This was touched upon on the Axle VPP thread, but for everyone else, the Octopus smart tariff terms and conditions https://octopus.energy/policies/smart-tariffs-terms-and-condition/ give Octopus exclusive access to enrol you in NESO’s demand flexibility services, and you agree that you will not join your household into any other DFS service.
This restriction explicitly applies to:

  • Octopus Intelligent Go
  • Octopus Intelligent Flux
  • Octopus Snug
  • Power pack and drive pack bolt-on’s
  • Octopus Zero tariff

This restriction does not apply to:

  • Cosy
  • Go
  • Flux
  • Agile
    (or presumably non-smart tariffs)

And if you are on one of the tariffs that isn’t allowed to sign up to Axle or any other DFS then Octopus would be within their rights to rebill you at the standard variable rate.

B
#1926 browellm

Very impressed with Load ML. Having the temperature component has made a material difference to my setup and don't even have a heat pump. I would imagine for ASHP users it's a total game changer.

G
#1927 geoffreycoan

For those using Load ML, make sure you turn off switch.predbat_calculate_inday_adjustment as inday adjustment and load ML will both do the same thing, update your load forecast based on in-day energy consumption and you'll get double counting. I have made this much more explicit in the documentation (PR coming)

Also, if you use the Octopus energy integration you will probably have seen this repair notice

the saving session binary sensor that Predbat uses in apps.yaml is being removed in a month or so.

The fix is easy, change the apps.yaml entry from:

  octopus_saving_session: 're:(binary_sensor.octopus_energy([0-9a-z_]+|)_saving_session(s|))'

to:

  octopus_saving_session: 're:(event.octopus_energy([0-9a-z_]+|)_saving_session_event(s|))'

And predbat will happily carry on working. The event entity isn't being deprecated

T
#1928 The Black Cat

geoffreycoan For those using Load ML, make sure you turn off switch.predbat_calculate_inday_adjustment as inday adjustment and load ML will both do the same thing, update your load forecast based on in-day energy consumption and you'll get double counting.

My LoadML is always reporting way too high a load each day, in the region of double but I’ve had switch.predbat_calculate_inday_adjustment turned off just about since the start of using LoadML.

This shows the “Actual Load” and “LoadML” for the last few days (I’ve blanked out the 1h and 8h forecasts for clarity) from the web charts section:-

It shows a load of around 20kWh per day, yet I only average around 10kWh per day with the max being 13kWh and min being 7kWh during that period. The only temperature dependent electrical item I’ve got is a heater in the conservatory on frost-stat and this only comes on when the outside temperature gets below 1 degree, which hasn’t really happened since LoadML was set running (60 days of data).

If I look at yesterday’s load, it was actually 10 not the 25 shown on the graph. The metrics tab does show the correct load figure.

I’m at a loss to know why this is happening and have had to turn off the use of LoadML and go back to the original, which is reasonable.

Any suggestions of what might be causing the problem.

G
#1929 geoffreycoan

The Black Cat Have you got an EV and have set predbat up to exclude EV charging maybe?

Not heard of anyone else having their forecast so wrong.

What have you set load_today and load_power to in apps.yaml, and if you look at the history of these sensors, what do you see each day, 10 or 20kWh?

T
#1930 The Black Cat

geoffreycoan

Thanks for your reply:-

I don’t have an EV, I’ve got num_cars set to zero.

Load today is sensor.givtcp_xxxxxx_load_energy_today_kwh which is currently at 4.5kWh whereas the LoadML chart is showing 13.4. The graph for the last month shows around 10kWh most days.

Load power is sensor.givtcp_xxxxxxx_load_power and that just shows the current power being used, the graph of that entity doesn’t really show that much.

#1931 PianSom

geoffreycoan the saving session binary sensor that Predbat uses in apps.yaml is being removed in a month or so.

I haven't actually seen that error yet, oddly. Does the deprecation (and fix) carry over to other apps.yaml entries? eg

  octopus_intelligent_slot: 're:(binary_sensor.octopus_energy([0-9a-z_]+|)_intelligent_dispatching)'
  octoplus_free_electricity: 're:(binary_sensor.octopus_energy([0-9a-z_]+|)_octoplus_free_electricity_session)'
L
#1932 Lincs_Will

geoffreycoan

Confused (not unusual). Just followed the update for deprecated saving session sensor and now tonight's saving session has disappeared from my Predbat plan. Is that because the notification had already gone out? Guess I can do any manual export for this one butbwould like confirmation the next one will work automatically.

L
#1933 Leeshore

PianSom According to the documentation the free one has changed

G
#1934 geoffreycoan

PianSom free events you should already have been using the event https://springfall2008.github.io/batpred/energy-rates/#octopus-free-power-up-events - but clearly the binary_sensor also works (at the moment). The repair notice came about 4 months ago from Octopus Integration v17 onwards

The Black Cat Load today is sensor.givtcp_xxxxxx_load_energy_today_kwh which is currently at 4.5kWh whereas the LoadML chart is showing 13.4. The graph for the last month shows around 10kWh most days.

I do see a slight jump up and down on load_today a couple of days ago, but that shouldn't be enough to mess it up.

There probably is a configuration issue but I can't see immediately what it is, can you log a github issue please and include these graphs, your debug file and your logfile

Octopus intelligent slot isn't changing

G
#1935 geoffreycoan

Lincs_Will Confused (not unusual). Just followed the update for deprecated saving session sensor and now tonight's saving session has disappeared from my Predbat plan

no it should still have been appearing in the plan even when you have registered for the event. In short the binary_sensor was being used to find the event sensor and then predbat was using that, so removing the binary_sensor and pointing direct to the event sensor just removes a processing step in the code, the code doesn't need to change (as I initially thought it did). Check you have the regular expression correct, in particular the event name matches your saving session event entity name

L
#1936 Lincs_Will

geoffreycoan

Thanks. I'd edited on my phone and made a mess of it. Corrected my poor cut & paste job via a laptop this morning. Hopefully all good for the next one!

M
#1937 MikeyHaz

So loadml isn't removing my car load in it's predictions - see those big spikes on the 8 hour predictions ... but I can't figure out why.

But - my car settings are set correctly (as far as I can see):

And the two sensors are set:

Both sensors are custom ones - but are recording and resetting at midnight appropriately.

For clarity - I'm using IOG led charging.

What am I missing?

#1938 Hook

For some reason predbat has flagged up my auto setting for battery curve calculation.

Anyone else had this? It's not an issue, it's just odd.

K
#1939 KamenMacKay

So....with the news of Givenergy's demise, how can we optimize the longevity of our systems? @TheDragon (GivEnergy) had a post on Facebook about limiting the charge and discharge to 85% and keeping the battery at 10% reserve (set once a week to 4% so it can calibrate properly) so the first two for Predbat are:
(I have a 3.6 kw gen2 inverter)
inverter_limit_charge:
- 3060
inverter_limit_discharge:
- 3060
And (thanks to MCP), I found set_reserve_min but perhaps other folks here have other suggestions for how to optimize for longevity.
Pretty sure the next battery after this one is going be V2G....

#1940 Jase1703

I’ll be running my AIO into the ground or to failure now, then use it as a boat anchor. By that time V2G(L or X) will be commonplace in vehicles.

V
#1941 Vestas

KamenMacKay Personally I have little to no faith in the SoC.

On a LV battery I have HA/GivTCP automations to prevent the battery going below 48V on discharge or above 55V on charge.

I also have an automation to deal with the SoC dropping to "1%" when the battery voltage clearly indicates that's nonsense.

#1942 Hook

I’d rather realise my roi sooner rather than later. I’m not protecting my kit to extend its longevity. Tbf it’s been rock sold in the 3 years I’ve had it.

If it goes pop, I’ll negotiate with my installer a favourable rate to replace it. He won’t want me to call on the warranty.

G
#1943 Guybrush-Threepwood

I know speak to the geek has done his video on setting up Home Assistant and he used a Raspberry Pi but I can highly recommend the Home Assistant Green box.

It’s a ready to go home assistant server that has performed wonderfully for the last year. No building required. Plug in, enter the web address and start installing the required addons.

https://shop.pimoroni.com/products/home-assistant-green?variant=54863020130683

#1944 Hook

One thing I’ve never sorted out has been my iog slots. Predbat seems to class them as historical house load.

They get picked up from my Octopus API and when active show the load in the car column.

K
#1945 KamenMacKay

Hook What a coincidence! I was looking at this today and I think I sorted it out.
You have to take your Charge Session Energy and use a helper called Utility Meter which adds up all the charging from the given sessions in a day to give you a total and then resets to 0 at midnight.
How to set it up:

Go to Settings > Devices & Services > Helpers.

Click Create Helper > Utility Meter.

Name: EV Daily Energy

Input Sensor: sensor.givevc_serial#_charge_session_energy

Meter Reset Cycle: Daily.

Leave "Net Consumption" and "Delta Values" OFF.

and then throw that sensor into your config for predbat:
car_charging_energy:

  • sensor.ev_daily_energy

Predbat will throw an error in apps.yaml until the next time you charge the car but this should work. I just implemented it today so I guess we'll see

#1946 Hook

KamenMacKay great let me know how it works.

R
#1947 Rbor

I have just checked GE app. I can see the flowchart under Home but nothing under Away.
So has the Cloud shutdown started? Or have I just checked at a bad time?

Check yours and see what you see.
Portal seems OK for me but the GE app was OK earlier.

Rob

T
#1948 ToothyChris

Rbor I fear it may have gone for good. Been off for about 5 hours now.

A
#1950 arczi19

Might be a silly question, but does anyone know how to get an API key for kraken for the predbat integration with EDF?

G
#1951 geoffreycoan

arczi19 Might be a silly question, but does anyone know how to get an API key for kraken for the predbat integration with EDF?

there is documentation for the Kraken integration in the Kraken component https://springfall2008.github.io/batpred/components/#kraken-energy-kraken but it assumes you have an API key for your account. If its not obvious in your EDF account maybe need to ask EDF?

KamenMacKay What a coincidence! I was looking at this today and I think I sorted it out.
You have to take your Charge Session Energy and use a helper called Utility Meter which adds up all the charging from the given sessions in a day to give you a total and then resets to 0 at midnight.

Yes, predbat needs to know what energy is car charging energy to subtract it from house load. Using a sensor on the EV charger integration is the usual way to do this. The documentation does describe how predbat needs the sensor to behave, and a utility meter might be needed if your EV charger integration doesn’t do what predbat wants it to

W
#1952 Wavy Davy

The only thing I use the GE Cloud portal for is to download the half hourly data (solar to home, solar to grid etc).
I know that GivTCP logs this but can I download this data so I can put it into my spreadsheet?
If so How?

D
#1953 Daveb01

Wavy Davy

Have a look at your Solar entities, any one will do to start. Then pick a time/date. Then clock the three dots top right and download 😀😎👍

G
#1954 geoffreycoan

Wavy Davy yes you can.

You can download entity history from the history view

  1. Select the time range
  2. select the entities
  3. download the data

There are a couple of things to be aware of:

a. The history screen shows two things, the entity history itself and long term statistics depending on the time range you select
b. Entity history consists of every state change for the purge_keep_days time period (default 10 days) whereas long term statistics are a single record every hour

If you wanted half hour records then you’d need to do the download every 10 days, and then filter the spreadsheet to just get the half hour values, or you could create an automation or a filter entity to capture one reading every 30 minutes.

Using the long term statistics would be simplest but that would be hourly data, but probably not a great loss really

W
#1955 Wavy Davy

geoffreycoan , Daveb01
Thanks for the replies. Managed to download, but the data is quite messy especially compared to the cloud app. Will wait until it stops working for free and then decide how to proceed.
Things like the solar to Battery don't seem to have an entry if there is no data (like at night) so importing them into excel is not straight forward. Also Data over a 7 day period is roughly every 30 secs

R
#1956 Rbor

Wavy Davy A lot of us have gone over to discord.
Some of us will be checking the GE community site (here) also.
It would be a pity if you are abandoned!
If you want to join, here's an invite:
https://discord.gg/y3R4aYBa

Rob

G
#1957 geoffreycoan

Wavy Davy Things like the solar to Battery don't seem to have an entry if there is no data (like at night) so importing them into excel is not straight forward. Also Data over a 7 day period is roughly every 30 secs

Correct, they are state changes you are downloading so there won’t be any state changes at night, and if you are downloading the entity history then you will get an update potentially every 30 seconds when givtcp polls the inverter. But for energy entities at 0.1kWh granularity they wouldn’t be changing that frequently.
That’s why I suggested looking at long term statistics, e.g. download March data, as that will only be hourly snapshots.
You’re still going to have to deal with data gaps though. All depends what you want to do with the data I suppose. Personally I’ve never had any interest in those X to X (solar/grid/home) energy entities, they’re approximations at best, or just plain wrong at worst.
Consequently those entities are all disabled in my HA.

I only track monthly generation/import/export/home load figures in a spreadsheet so it’s pretty easy to pull the latest total and subtract it from the end of prior month figure. That’s good enough to work out payback etc.

Another approach is to use the Energy dashboard, if you configure your battery and inverter energy and power sensors in there you can see its view of battery to home etc flows. Useful for visualisation but not as easy to get into a spreadsheet

C
#1958 ChrisRowe

Rbor I can’t get the link to work. I get a message saying Safari can’t open the page as the address is invalid?

T
#1959 TX200

Anyone seeing lunchtime forced exports these days (like last 1-2 weeks).

Not entirely sure why PredBat is now doing that. May as well keep the battery at 100% for evening usage and export, rather than export a little bit, fill up again and empty again.

V
#1960 Vestas

TX200 Negative Agile rates.

T
#1961 TX200

Vestas I'm on IOG and it knows that. And fixed 12p export. 🤣

V
#1962 Vestas

TX200 That's the only reason I can see for "lunchtime" exports, there's been a few days over the last 2-3 weeks with negative rates late morning/early afternoon.

Edit - unless its trying to prevent clipping or some such?

T
#1963 TX200

Vestas hmm, that is an interesting idea re the clipping. Could well be that.

G
#1964 geoffreycoan

TX200 I was going to say that, it’s almost certainly predicting clipping so is exporting from the battery to give some room to enable solar charging. If you look at the plan in debug mode you can see the clipping kWh column

T
#1965 TX200

geoffreycoan yeah looks to be the answer. It shows 0.01 in the clipping column for the 11.30am and 12.00pm slots (export 11am-12.30pm).

G
#1966 geoffreycoan

If you have buttons on your dashboard to navigate to the Predbat web console, then in HA 2025.5, the destination URL has changed and you’ll need to edit the dashboard for the button to continue working.

Change the destination URL from /hassio/ingress/6adb4f0d_predbat to /app/6adb4f0d_predbat

T
#1967 TX200

PredBat says it opted me into a saving session tonight.

But it doesn't exist in my region.

Guess octopus have changed something again, breaking the APIs.

T
#1969 thevilla

I'm experiencing an issue with givtcp v3.5. The load_energy_today sensor is not changing to zero at midnight unless I restart givtcp or use the givenergy portal to restart the AIO battery inverter. Predbat reports demand (unhealthy) and the plan indicates zero demand. I'm not sure when this started but it has been a week or so.

Any one able to advise how I fix this please? I'm considering restarting the AIO and gateway but I'm nervous given the dodgy warranty status.
Thanks.

#1970 Maxwell

@thevilla No AIO/Gateway here, just a gen 3 hybrid. But using 3.5 givtcp and nothing obviously wrong with load energy today figures here. I'm not using HA.

M
#1971 MikeyHaz

I'm using a gen1 hybrid and it does happen to me - the load today figure will get stuck, randomly jump etc. There have been various attempts to fix it. I just made my own in Home Assistant with a helper and switched predbat to using that.

L
#1972 Lincs_Will

Hi, is there a way I can add some temperature compensation or a switch to Predbat? I'm using the ML load prediction and its exporting power quite early in the day even though I've got input_number.predbat_metric_min_improvement_swap set to -0.5p. I'd prefer it to keep the battery charged up until I either use the power for a portable air con unit, or export it so the battery is empty at 2330 in time to recharge on IOG.

#1973 Jase1703

Compared to last year on PredBat when Octopus export was worth 15p, this year since the drop to 12p PredBat has been very conservative on exporting excess battery to the grid. I’ve tried a few setting changes but no difference. Can anyone suggest the best setting to change, I keep seeing no less than 66%soc so plenty of capacity left over that could be exported. PredBat obviously seeing no value in exporting this excess but have can I change this?

S
#1974 SteveCook

Have you checked that you dont have a setting in predbat config holding you at a minimum of 66%
I think this is it.

#1975 Jase1703

SteveCook same value as you have Steve, 4%.

L
#1976 LewisWatt

If you turn on HTML Debug, it'll probably reveal that the round trip losses are basically break-even, and therefore aren't worth it.

W
#1977 wrighar

Looks like you export is less than import, so it's better 'onsite'.

Mine is barely worth selling from battery as there is only 1.9p/kWh difference.

For me it's better to charge the battery overnight and use it when solar is less than home load, don't charge the battery during the day from solar, just export it without the battery 2 way conversion losses and export any remaining just before 00:30

L
#1978 Lincs_Will

Predbat is still exporting early in the evening and leaving me short of battery. Ive got
input_number.predbat_metric_min_improvement_swap set to -1.0 but it doesn't seem to make any difference. Is there anything else I can change?


L
#1979 Lincs_Will


All I can say at them moment is erm? This is mostly due to my present location being a beer festival.

#1980 Maxwell

Lincs_Will Is that a new feature request. Optimise my charge/discharge to allow me to pay for an upcoming drinking sessions 😉

L
#1981 Lincs_Will

Maxwell If only. No idea why it'd planned to charge through 32p/kwh import rate. No hope of making money back on that.

#1982 Windy Miller

Lincs_Will What we can't see there is the SOC column so it is possible all that means is hold charge at 100% to export it at 6pm when the export rate doubles. Means that between 3pm and 6pm all your house load will be met by the solar and grid with nothing from the battery.