Hi,
starting next month, I will be using an electricity-tariff with a high-price (27ct/kWh) Time (5:00-24:00) and a low-price (17,5ct/kWh).
I own a photovoltaic system with home storage and an electric car.
It would be nice to start charging the car and filling the home storage in the cheap time.
Electricity from the PV certainly is even cheaper, so the home storage shouldn’t be full in the morning if there will be lots of sun. The PV-forecast should therefore check the available PV-energy for the next day (already working with Sol cast-Integration) and calculate how much Energy should be added.
Also the car shouldn’t be charged to full every night. But I think that’s an issue for EVCC, which controls charging the car.
But could anyone help how to automate the first part?
I’ve got Solcast-Integration working and Solax-Integration for my PV also is working.
Hi,
I have exactly the same issue. Here is the sensor I created for the price (6am-midnight = 0.33594, midnight to 6am 0.08)
- sensor:
- name: Electricity Costs
unique_id: electricity_costs
unit_of_measurement: AUD/kWh
state: >
{% if now().hour >= 6 and now().hour <= 23 %}
{{ '0.33594'|float }}
{% else %}
{{ '0.0800'|float }}
{% endif %}
I also have a binary sensor that checks that the house battery is full and the solar if generating power.
- binary_sensor:
- name: Excess Solar Production
unique_id: excess_solar_production
state: >
{% set value = states('sensor.al4001019060224_instantaneous_grid_i_o_total') | float %}
{% set soc = states('sensor.al4001019060224_instantaneous_battery_soc') | float %}
{% if (value < -1800 and soc > 99) %}
On
{% else %}
Off
{% endif %}
# adds a ten minute delay to the on state.
delay_on: 00:10:00
delay_off: 00:01:00
icon: mdi:solar-power
I don’t trust the solar projection, so I have been experimenting with an average calculation to more accurately predict solar output availability. This is a UI statistic based on the last 8 hours of data received.
For some reason, I am not able to automate the plugging in of the car to take the excess solar, so I have an automation that sends me a notification that the solar is now in excess.
alias: Excess Solar Notification
description: ""
trigger:
- platform: state
entity_id:
- binary_sensor.excess_solar_production
to: "on"
condition:
- condition: not
conditions:
- condition: state
entity_id: timer.excess_solar_notification_timer
state: active
action:
- action: notify.mobile_app_nokia_x30_5g
metadata: {}
data:
message: Excess Solar Production available.
title: Excess Solar Production
- action: timer.start
metadata: {}
data: {}
target:
entity_id: timer.excess_solar_notification_timer
mode: single
the timer ensures a single notification per day.
Just some thoughts on a similar issue. Hope you find this helpful.
I have made a big step forward and learned a lot!
I created a slider for the desired SOC of the Tesla.
At night, it calculates how much kWh needs to be charged for this SOC after subtracting the expected PV output and 7 kWh for the average household consumption, and that amount is then charged.
Since my car usually stays home during the day, any surplus PV can still be charged into the car. If it doesn’t quite match by the end of the day, that’s fine; it just means more will be charged the next night.
I had to create helpers that convert the current Tesla and home battery SOC into kWh, convert the desired SOC into kWh, and calculate the available expected PV output. The automation only starts if not enough PV is expected for the following day.
If someone is interested in any part of this, feel free to ask and I would share what I’ve got!