Hi Everyone,
I am facing some strange behavior. To evaluate the amount of solar power used to charge my car I have create a template sensor that should determine it.
{% set gemini_energy = states('sensor.goecharger_go_e_gemini_p_all') | float %}
{% set solar_power = states('sensor.total_solar_power') | float %}
{% if gemini_energy > 1 %}
{% if solar_power > gemini_energy %}
{{ gemini_energy }}
{% else %}
{{ solar_power }}
{% endif %}
{% else %}
{{ 0 }}
{% endif %}
checking if there is charging going on I am checking gemini_energy, if that is the case I check if the solar_power available exceeds the charging energy. if that is the case it means I want to calculate the whole charging as solar charged so the output of the sensor is the full charging energy. otherwise it outputs the solar power that is lower than charging so only part of the charging is delivered by solar.
to calculate the monthly energy coming from solar to charge the car I used the template sensor in a integral sum.
now to the strange part. I noticed already in two months out of 8 I am running this that compared to the total charged energy (reported by the charger) the solar energy (which should only be part of it due to the way I set it up) exceeds the total.
blue is total charged and orange solar part.
Does anyone have a idea how that is possible?