Created
September 4, 2023 18:03
-
-
Save svewag/0b26212a56601dcd8afd71adb23d07ff to your computer and use it in GitHub Desktop.
Awtrix Automation HA
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias: Awtrix Uhr | |
description: "" | |
trigger: | |
- platform: time_pattern | |
minutes: /1 | |
condition: [] | |
action: | |
- if: | |
- condition: numeric_state | |
entity_id: sensor.tesla_battery | |
below: 30 | |
- condition: state | |
entity_id: binary_sensor.tesla_charging | |
state: "off" | |
- condition: not | |
conditions: | |
- condition: state | |
entity_id: device_tracker.tesla_location_tracker | |
state: not_home | |
then: | |
- service: mqtt.publish | |
data: | |
topic: awtrix/custom/tesla-battery | |
qos: 0 | |
retain: false | |
payload: "{\"icon\": \"13728\", \"text\":\"{{states.sensor.tesla_battery.state}} %\" }" | |
else: | |
- service: mqtt.publish | |
data: | |
topic: awtrix/custom/tesla-battery | |
qos: 0 | |
retain: false | |
payload: "{}" | |
alias: Tesla Akku < 30% | |
mode: single |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment