15 lines
3.0 KiB
JSON
15 lines
3.0 KiB
JSON
[
|
|
{
|
|
"id": "EVCC-Communication-Tesla-BLE-original-nicht-löschen",
|
|
"result": {
|
|
"structured": "TRIGGER: When an MQTT message is received on topic ha-evcc/1/wb-enable-request OR when an MQTT message is received on topic ha-evcc/1/max-charge-requested OR every 10 seconds (time_pattern). CONDITIONS: None. ACTIONS: Choose based on trigger: 1. If trigger is time_pattern (every 10 seconds), then publish multiple MQTT messages with sensor data: Tesla charge limit [sensor.tesla_ble_f549c4_charge_limit], Tesla range [sensor.tesla_ble_f549c4_range], Tesla charge status (mapped from Tesla charging state [sensor.tesla_ble_f549c4_charging_state]), Tesla odometer [sensor.tesla_ble_f549c4_odometer], Tesla minutes to limit [sensor.tesla_ble_f549c4_minutes_to_limit] (as a future timestamp), Tesla charge level [sensor.tesla_ble_f549c4_charge_level], Tesla charger state (boolean from Tesla charging state [sensor.tesla_ble_f549c4_charging_state]), Tesla charge power [sensor.tesla_ble_f549c4_charge_power], Tesla energy added [sensor.tesla_ble_f549c4_charge_energy_added], Tesla charge current [sensor.tesla_ble_f549c4_charge_current]. 2. If trigger is MQTT on topic ha-evcc/1/wb-enable-request, then if the payload is truthy, turn on Tesla charger switch [switch.tesla_ble_f549c4_charger]; else if the payload is falsy AND Tesla charger switch [switch.tesla_ble_f549c4_charger] is on, turn it off. 3. If trigger is MQTT on topic ha-evcc/1/max-charge-requested AND Tesla charging state [sensor.tesla_ble_f549c4_charging_state] is Charging, then set Tesla charging amps [number.tesla_ble_f549c4_charging_amps] to the integer payload value.",
|
|
"natural_language": {
|
|
"trigger": "This automation runs in three situations: when a message arrives on the MQTT topic 'ha-evcc/1/wb-enable-request', when a message arrives on the MQTT topic 'ha-evcc/1/max-charge-requested', or automatically every 10 seconds.",
|
|
"conditions": "There are no global conditions that must be met for the automation to run.",
|
|
"action": "The automation performs different actions depending on what triggered it. If it was triggered by the 10-second timer, it publishes a series of MQTT messages containing the current state of various Tesla vehicle sensors, such as the charge limit, range, odometer, and charging status. If it was triggered by a message on the 'wb-enable-request' topic, it interprets the message payload: if the payload indicates a request to enable, it turns on the Tesla charger switch [switch.tesla_ble_f549c4_charger]; otherwise, if the charger is currently on, it turns it off. If the trigger was a message on the 'max-charge-requested' topic, and the vehicle is currently in a 'Charging' state, it sets the charging amperage [number.tesla_ble_f549c4_charging_amps] to the value provided in the message."
|
|
},
|
|
"human_like": "This automation acts as a communication bridge between Home Assistant and an EVCC system, regularly publishing Tesla charging data and responding to remote commands to control the charger and adjust charging settings.",
|
|
"complexity": "high"
|
|
}
|
|
}
|
|
] |