forked from egnerfl/alfen_wallbox
-
Notifications
You must be signed in to change notification settings - Fork 15
My automation for charging
Tuen Lee edited this page Nov 27, 2023
·
2 revisions
Related to this to add some documentation: https://github.com/leeyuentuen/alfen_wallbox/issues/83
What I've done is put them in 3 automation (only use when I use comfort): first: if the active power of my P1 is higher then 4000, then I will put my wallbox to 0A:
alias: Wall Charge to 0A
description: ""
trigger:
- platform: state
entity_id:
- sensor.p1_meter_3c39e722c91c_active_power
for:
hours: 0
minutes: 0
seconds: 0
condition:
- condition: and
conditions:
- condition: state
entity_id: select.wallbox_solar_charging_mode
state: Comfort
for:
hours: 0
minutes: 0
seconds: 0
- condition: and
conditions:
- condition: numeric_state
entity_id: number.wallbox_power_connector_max_current_socket_1
above: 5
below: 6.9
- condition: numeric_state
entity_id: sensor.p1_meter_3c39e722c91c_active_power
above: 4000
- condition: numeric_state
entity_id: sensor.wallbox_active_power_total_socket_1
above: 1
action:
- service: alfen_wallbox.set_current_limit
data:
entity_id: number.wallbox_power_connector_max_current_socket_1
limit: 0
mode: single
second is put them on 6A if the value is over 3000W
alias: Wall Charge to 6A
description: ""
trigger:
- platform: state
entity_id:
- sensor.p1_meter_3c39e722c91c_active_power
for:
hours: 0
minutes: 0
seconds: 0
from: null
to: null
condition:
- condition: and
conditions:
- condition: state
entity_id: select.wallbox_solar_charging_mode
state: Comfort
for:
hours: 0
minutes: 0
seconds: 0
- condition: and
conditions:
- condition: numeric_state
entity_id: number.wallbox_power_connector_max_current_socket_1
above: 6
- condition: numeric_state
entity_id: sensor.p1_meter_3c39e722c91c_active_power
above: 3300
- condition: numeric_state
entity_id: sensor.wallbox_active_power_total_socket_1
above: 1
action:
- service: alfen_wallbox.set_current_limit
data:
entity_id: number.wallbox_power_connector_max_current_socket_1
limit: 6
mode: single
and third one is if thee value is lower then 1600W, then I set them from 6A to 16A for fully charge,
alias: wallcharge 6A to 16A
description: ""
trigger:
- platform: state
entity_id:
- sensor.p1_meter_3c39e722c91c_active_power
condition:
- condition: and
conditions:
- condition: state
entity_id: select.wallbox_solar_charging_mode
state: Comfort
for:
hours: 0
minutes: 0
seconds: 0
- condition: and
conditions:
- condition: numeric_state
entity_id: number.wallbox_power_connector_max_current_socket_1
below: 17
- condition: numeric_state
entity_id: sensor.p1_meter_3c39e722c91c_active_power
below: 1600
- condition: numeric_state
entity_id: sensor.wallbox_active_power_total_socket_1
above: 1
action:
- service: alfen_wallbox.set_current_limit
data:
entity_id: number.wallbox_power_connector_max_current_socket_1
limit: 16
- delay:
hours: 0
minutes: 0
seconds: 30
milliseconds: 0
mode: single
I've put my wallbox to only charge on 1 phase, so he can max go to 3600W charging