syssi / homeassistant-goecharger-mqtt

go-eCharger integration for Home Assistant using the MQTT API
Apache License 2.0
88 stars 18 forks source link

PV Surplus Charging - what happens when pGrid gets "unavailable"? #125

Closed parkflyer closed 9 months ago

parkflyer commented 11 months ago

My MQTT based grid sensor is WLAN based and there is the possibility that the "Power Saldo" which I use for pGrid in the "PV Surplus Charging" automation could get unavailable (e. g. no data received for 60 sec due to WLAN problems). What will then happen to the charging process?

Cheers, parkflyer

OhneNik commented 11 months ago

Hey,

just do the good old |float(0) template.

{{ “unavailable”|float(0) }} returns the default 0 in the template.

I think what really happens is, that the go-e does not accept the input and ignores the value.

parkflyer commented 11 months ago

Thanks, OhneNik! I assume

has_value('sensor.my_sensor')

would also work, correct?

Also I believe a default value of e.g. 1000 (positive value) would be better as it indicates to the wallbox that no surplus PV power is available.

OhneNik commented 11 months ago

Yep all templating functionality is working there.

But if you like to alter the pGrid values on multiple heuristics I‘d prefer doing something like this

syssi commented 9 months ago

Let's close this issue. It looks like it's resolved.