Hi all,
I have some problem. Since begin this month I changed my energy contract to dynamic, so I changed my configuration to that. But now I have a lot of times that my car isn’t charged in the morning, only something like 50-60%
someone know how to solve this problem?
This is my config:
MPC:
{
"pv_power_forecast": {{
([states('sensor.solar_panel_production_w')|int(0)] +
state_attr('sensor.solcast_pv_forecast_forecast_today', 'detailedForecast')|selectattr('period_start','gt',utcnow()) | map(attribute='pv_estimate')|map('multiply',1000)|map('int')|list +
state_attr('sensor.solcast_pv_forecast_forecast_tomorrow', 'detailedForecast')|selectattr('period_start','gt',utcnow()) | map(attribute='pv_estimate')|map('multiply',1000)|map('int')|list
)| tojson
}},
"load_power_forecast": {{
([states('sensor.power_load_no_var_loads')|int] +
(states('input_text.fi_fo_buffer').split(', ')|map('multiply',1000)|map('int')|list)[1:]
)| tojson
}},
"prediction_horizon": {{
(24 if now().hour <= 15 else 48) - now().hour
}},
"load_cost_forecast": {{
((state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_today') |map(attribute='value') | list + state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_tomorrow') |map(attribute='value')|list)[now().hour:][:48]| tojson )
}},
"prod_price_forecast": {{
((state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_today') |map(attribute='value') | list + state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_tomorrow') |map(attribute='value')|list)[now().hour:][:48]| tojson )
}},
"num_def_loads": 1,
"def_total_hours": [
{% set hours = (5 - states('sensor.volvo_battery_charge_level')|float(0) / 20) * (states('sensor.laadpaal_status_2')|float(0))|int(0) %} {{- hours -}}
],
"P_deferrable_nom": [6400],
"treat_def_as_semi_cont": [0],
"set_def_constant": [0],
"def_start_timestep": {{ [states('sensor.def_0_start_timestep')|int(0)] }},
"def_end_timestep": {{ [states('sensor.def_0_end_timestep')|int(0)] }},
"soc_init": {{ (states('sensor.solaredge_b1_state_of_energy')|int(0))/100 }},
"soc_final": 0.99,
"alpha": 0.75,
"beta": 0.25
}
Day Ahead:
{
"pv_power_forecast": {{
([states('sensor.solar_panel_production_w')|int(0)] + state_attr('sensor.solcast_pv_forecast_forecast_today', 'detailedForecast')|selectattr('period_start','gt',utcnow()) | map(attribute='pv_estimate')|map('multiply',1000)|map('int')|list + state_attr('sensor.solcast_pv_forecast_forecast_tomorrow', 'detailedForecast')|selectattr('period_start','gt',utcnow()) | map(attribute='pv_estimate')|map('multiply',1000)|map('int')|list)[:48]| tojson
}},
"load_cost_forecast": {{
((state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_today') |map(attribute='value') | list + state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_tomorrow') |map(attribute='value')|list)[now().hour:][:48]| tojson )
}},
"prod_price_forecast": {{
((state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_today') |map(attribute='value') | list + state_attr('sensor.nordpool_kwh_be_eur_3_10_0', 'raw_tomorrow') |map(attribute='value')|list)[now().hour:][:48]| tojson )
}},
"prediction_horizon": {{
(24 if now().hour <= 15 else 48) - now().hour
}},
}
def_0_start_timestep:
{% set ts = (((today_at(states('input_datetime.emhass_p_deferrable_0_start_time'))|as_timestamp - now()|as_timestamp)+900)/1800) | round(0) | int(0) %}
{% if states('input_datetime.emhass_p_deferrable_0_start_time') > states('input_datetime.emhass_p_deferrable_0_end_time') %}
{% if now() < today_at(states('input_datetime.emhass_p_deferrable_0_end_time')) %}
{% set ts = ts - 48 %}
{% endif %}
{% endif %}
{{ ts * is_state('input_boolean.emhass_p_deferrable_0_timestep','on') }}
def_0_end_timestep:
{% set ts = (((today_at(states('input_datetime.emhass_p_deferrable_0_end_time'))|as_timestamp - now()|as_timestamp) +900)/1800) | round(0) | int(0) %}
{% if states('input_datetime.emhass_p_deferrable_0_start_time') > states('input_datetime.emhass_p_deferrable_0_end_time') %}
{% if now() > today_at(states('input_datetime.emhass_p_deferrable_0_end_time')) %}
{% set ts = ts + 48 %}
{% endif %}
{% endif %}
{{ ts * is_state('input_boolean.emhass_p_deferrable_0_timestep','on') }}
input_datetime.emhass_p_deferrable_0_start_time: is set on 18:00
input_datetime.emhass_p_deferrable_0_end_time: is set on 06:00