-
-
Save hrosenbauer/c8fba698c06dbf3a9289e3ee9bbcbfe2 to your computer and use it in GitHub Desktop.
This file contains hidden or 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: "[Washing] Done" | |
| description: "" | |
| trigger: | |
| - platform: numeric_state | |
| entity_id: sensor.washing_machine_power | |
| for: | |
| hours: 0 | |
| minutes: 0 | |
| seconds: 0 | |
| above: "500" | |
| condition: [] | |
| action: | |
| - variables: | |
| start_energy: "{{ states('sensor.washing_machine_energy') }}" | |
| - wait_for_trigger: | |
| - platform: state | |
| entity_id: | |
| - sensor.washing_machine_power | |
| to: "0" | |
| for: | |
| hours: 0 | |
| minutes: 5 | |
| seconds: 0 | |
| continue_on_timeout: false | |
| - variables: | |
| end_energy: "{{ states('sensor.washing_machine_energy') }}" | |
| - service: notify.everyone | |
| data: | |
| title: 🫧 So Fresh and So Clean | |
| message: Washing is done. Used {{ (end_energy - start_energy)|round(2) }}kWh. | |
| mode: single |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment