springfall2008 / batpred

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

Predbat needs reboot when car unplugged with Ohme integration #1488

Open murkle opened 1 month ago

murkle commented 1 month ago

When the car is unplugged PredBat doesn't update its plan unless Home Assistant is restarted, see https://github.com/dan-r/HomeAssistant-Ohme/issues/91

Not sure if it's the Ohme integration or PredBat at fault - is there anything I can do to help diagnose this? 🙏

springfall2008 commented 1 month ago

Have you tried the switch 'switch.predbat_octopus_intelligent_ignore_unplugged' setting this on should fix it?

murkle commented 1 month ago

Thanks, found that under "Expert mode". Tested that, seems to be the same. Here's what I get after unplugging the car (was unplugged about 8.30pm, charge slot was until 9.20pm) image image image

murkle commented 1 month ago

Then after rebooting Home Assistant it looks OK image

springfall2008 commented 1 month ago

There's something wrong here there is no 'Car' common on your plan, are you sure the car is actually enabled?

murkle commented 1 month ago

The plan changes when I plug the car in - so something is working. What should it look like?

springfall2008 commented 1 month ago

There should be a car column on the plan:

image

murkle commented 1 month ago

Thanks, solved that (num_cars :1 not 0 🤦‍♂️)

Still the same I'm afraid - car unplugged at 21:18 but the plan didn't update to account for that at 21:20 or 21:25

image

murkle commented 1 month ago

... and after rebooting Home Assistant it's OK image

gcoan commented 1 month ago

Thanks, solved that (num_cars :1 not 0 🤦‍♂️)

did you write that the wrong way round? num_cars needs to be set to 1 if you want Predbat to manage or be aware of car charging via IOG, and the car column is omitted if num_cars is zero

murkle commented 1 month ago

Yes it was 0 now I've changed it to 1

springfall2008 commented 1 month ago

Resolving the ticket

murkle commented 1 month ago

@springfall2008 to be clear: the problem is still there after changing num_cars to 1

springfall2008 commented 1 month ago

Did you set 'switch.predbat_octopus_intelligent_ignore_unplugged' to Enabled?

murkle commented 1 month ago

@springfall2008 Yes, here's what I currently have:

image image

springfall2008 commented 1 month ago

What is the car plugged in sensor set to? Can you show your 'config' page on the Predbat Web interface?

murkle commented 1 month ago

Do you mean car_charging_now? These are the sensors pointing to the Ohme plugin: ` car_charging_now:

I've also got this (but that should be ignored with Intelligent I think)

` car_charging_planned:

murkle commented 1 month ago

image image image image image