Thank you. I will make the change and try that tomorrow.
@Blacky
This is one of the tightest Blueprints I have seen. Granted only switched from HomeSeer 3 months ago. You made me realize what a blueprint can really do. Cant wait till I have spare brain CPU to start looking at your others.
Feature Req:
Issue:
Energy sensors do not normally update as frequently as Power sensors for most setups, to keep down excess traffic.
In my case kWh only updates at a max every 5 min, and I donât want to increase it as it would affect all 45 breakers data. This causes the End kWh reading to be incomplete. I could add a end sensor delay of 5 min, but that delays the audio alert notifications.
Proposed Solution:
Add an option to delay power calc x min after end of cycle message is triggered. This would allow an immediate cycle complete notification, followed by a new message type X min later with accurate power and cost consumption.
Thank you sir
What is the suggested plug / energy sensor for washer/dryer since I donât think a normal one will work.
Can you help me my bleuprint wonât run?
this is my yaml
alias: Wasmachine is klaar
description: ""
use_blueprint:
path: Blackshome/appliance-notifications.yaml
input:
power_sensor: sensor.washing_machine_energieverbruik
include_end_notify: enable_end_notify_options
end_notify_device:
- f277ba0a0deefb9223021a642ddc14ff
end_message: đ§De was is klaarđ§!!!
end_appliance_power: 30
end_notify_data:
- high_priority
include_power_tracking: enable_power_tracking
power_consumption_sensor: sensor.washing_machine_energieverbruik
end_message_kwh: Verbruik
end_message_title: đ§Wasmachine
start_appliance_power: 10
start_time_delay: 1
end_time_delay: 1
Mine update every 30 seconds when it is being used but when it not it can be 2 hours.
Maybe you could run another automation that in 5 min updates your End Number Helper and then do the calculations sending another notification.
Blacky
There are a few things.
- Your Power Sensor entity is not correct. Looks like your using the total kWh. Look for an entity that reports in watts in your device and then use that one.
- In Power Tracking you have not entered in Cost per kWh, Start Number Helper and End Number Helper see the FAQ for this click here
Tip: Use the start notify to set it up and once you got it working you can always disable this option. This helps as it lets you know that the automation was triggered and is now running looking for the end.
Blacky
That works for a lot of appliances, but my Dryer runs on 240 and I monitor with a greeneye system ct loop on the hots in the breaker panel. Greeneye is a push, there is no way to sent an update request.
You did just spark an idea, I can add a sequence block in custom actions end, send the immediate complete message then wait and send second message with power totals. the slick way would be to make some sort of wait loop triggered by next device update
Yeah that will work⌠the wait can be when the power sensor changes or you could delay for 5 min.
Blacky
Thanks for all your work ⌠looks very good, But there is alway a but i need it to Talk over Google Home Assistant Voice PE. Is there a way to could just adjust the like to let us includ the home voice âŚ
Thanks hope to get to use this ASAP
John G.
Tried to make it work but it is showing old power and cost. tried to mimic exactly what you do but I am missing something.
message: >
Data collected: {{end_message}} {% set kwh = states(end_power_consumption) |
float - states(start_power_consumption) | float %}
{{'\n'}}{{end_message_kwh}} {{kwh | round(2) }} kWh {% set cost =
(states(end_power_consumption) | float - states(start_power_consumption) |
float) * (states(cost_per_kwh) | float) %}
{{'\n'}}{{end_message_cost}}{{cost | round(2) }} {% if
include_duration_tracking == "enable_duration_tracking" %} {% set end_time =
now().timestamp() %} {% set duration = (end_time - start_time) | int %} {%
set hours = (duration // 3600) | int %} {% set minutes = ((duration % 3600)
// 60) | int %} {% set seconds = (duration % 60) | int %} {{'\n'}}{{
end_message_duration_tracking }} {{ '%02d' | format(hours) }}:{{ '%02d' |
format(minutes) }}:{{ '%02d' | format(seconds) }} {% endif %}
title: "{{end_message_title}}"
Very new to HA, so forgive me for what is probably a silly question. Getting notifications about completed washing is high on my list of goals for HA, so I was really happy to find this blueprint and will test it out tomorrow!
My question is about custom actions for start/end of a cycle : How would I send an email to myself? Using email to SMS, I could then get a text/SMS message to my phone(s). Guessing I need to set up email somehow in the main part of HA first?
I think we really need a watchdog feature for cases when a device hasnât been turned on for a certain number of hours or days. This would be especially useful for things like water pumps or other equipment that should run periodically and consume electricity â and if it doesnât consume anything for several days, itâs likely broken.
Itâs also important to consider pumps with float switches. If the pump turns on but power consumption is zero â thatâs okay, it just means there was no water to pump (the float triggered but there was nothing to do).
However, if thereâs absolutely no power usage for something like 2 weeks, then itâs very likely that the pump failed.
So the watchdog should fire notification when there is no consumption for XX hours (days and so on).
I get an error for the blueprint:
Fehler: TypeError: unhashable type: âlistâ
Ergebnis:
choice: 0
choose:
- alias: Check if end of notification is enabled
conditions:
- '{{ include_end_notify == ''enable_end_notify_options'' }}'
sequence:
- variables:
message: >-
{% set message = namespace(text='') %} {% if
include_service_reminder == 'enable_service_reminder_and_notify' %}
{% set service_count = states(service_reminder_counter_helper) | int(0) %}
{% set service_threshold = service_reminder_cycles | int %}
{% if service_count >= service_threshold %}
{% set message.text = message.text + '\n' + service_reminder_end_message + '\n' %}
{% endif %}
{% endif %} {% set message.text = message.text + end_message %} {%
if include_power_tracking == 'enable_power_tracking' %}
{% set kwh = (states(end_power_consumption) | float - states(start_power_consumption) | float) %}
{% set message.text = message.text + '\n' + end_message_kwh + ' ' + (kwh | round(2) | string) + ' kWh' %}
{% endif %} {% if include_power_tracking ==
'enable_power_tracking_and_cost' %}
{% set kwh = (states(end_power_consumption) | float - states(start_power_consumption) | float) %}
{% set cost = kwh * (states(cost_per_kwh) | float) %}
{% set message.text = message.text + '\n' + end_message_kwh + ' ' + (kwh | round(2) | string) + ' kWh' %}
{% set message.text = message.text + '\n' + end_message_cost + (cost | round(2) | string) %}
{% endif %} {% if include_duration_tracking ==
'enable_duration_tracking' %}
{% set end_time = now().timestamp() %}
{% set duration = (end_time - start_time) | int %}
{% set hours = (duration // 3600) %}
{% set minutes = ((duration % 3600) // 60) %}
{% set seconds = (duration % 60) %}
{% set message.text = message.text + '\n' + end_message_duration_tracking + ' ' + '%02d:%02d:%02d' | format(hours, minutes, seconds) %}
{% endif %} {% if include_cycle_counter ==
'enable_cycle_counter_and_notify' %}
{% set cycle_count = states(cycle_counter_helper) | int(0) %}
{% set message.text = message.text + '\n' + cycle_counter_end_message + ' ' + (cycle_count | string) %}
{% endif %} {{ message.text }}
- alias: Send a notification to each device
repeat:
for_each:
- cf3099cc85bc3ea995a6e85d689e591a
sequence:
- action: >-
notify.mobile_app_{{ device_attr(repeat.item, 'name') | slugify
}}
data:
title: Waschmaschine fertig
message: |
{{message}}
data: '{{ end_message_data }}'
- choose:
- alias: Check if end reminder notification is enabled
conditions:
- condition: template
value_template: >-
{{ end_reminder_notification == 'enable_reminder_notification'
}}
sequence:
- wait_for_trigger:
- trigger: state
entity_id: []
to: 'on'
timeout:
minutes: 10
- repeat:
while:
- condition: template
value_template: >-
{{ (is_state(end_reminder_notification_entity, 'off'))
and (repeat.index <=
end_reminder_notification_max_count) }}
sequence:
- repeat:
for_each:
- cf3099cc85bc3ea995a6e85d689e591a
sequence:
- action: >-
notify.mobile_app_{{ device_attr(repeat.item,
'name') | slugify }}
data:
title: Waschmaschine fertig
message: >-
Hey! Your fresh laundry is ready, don't leave it
hanging!
data: '{{ end_message_data }}'
- wait_for_trigger:
- trigger: state
entity_id: []
to: 'on'
timeout:
minutes: 10
It happens for this step very late. Any idea?
My config for the automation:
alias: Waschmaschine Papa
description: ""
use_blueprint:
path: Blackshome/appliance-notifications.yaml
input:
power_sensor: sensor.waschmaschine_papa_power
start_appliance_power: 14
start_time_delay: 0.5
running_dead_zone: 5
include_start_notify: enable_start_notify_options
end_time_delay: 2.5
include_duration_tracking: enable_duration_tracking
include_power_tracking: enable_power_tracking
include_end_notify: enable_end_notify_options
end_notify_device:
- cf3099cc85bc3ea995a6e85d689e591a
end_notify_data:
- sticky
end_reminder_notification: disable_reminder_notification
end_message_title: Waschmaschine fertig
end_message: Wäsche ist fertig!
start_title: Waschmaschine gestartet
power_consumption_sensor: sensor.waschmaschine_papa_energy
end_message_cost: Approx Cost âŹ
start_notify_device:
- cf3099cc85bc3ea995a6e85d689e591a
start_message: Die Wäsche läuft.
end_appliance_power: 2
end_repeat_count: 2
end_message_duration_tracking: Dauer
Is it possible, to get End Notification, only if the (Android) Device is at home?
I use a Wireguard Tunnel if Iâm outside. HomeAssistnt knows, the Iâm not at home (WLAN) but the End Notification arrived because of the tunnel and I get Washing Machine ready when Iâm far from home.
Is it possible to delete/clear the the notification triggered by a status of an entity in the custom action?
Lets assume I have activated notify at end of the washing maschine and I have a door sensor on the wasching maschine door.
It would be nice to get rid of the notification on my mobile once I have opened the door.
I have seen somthing similar in that blueprint: đ˛ Contact Sensor (Door or Window) Left Open Notification
Data collected: ?? is this correct?
message: >
Your end message here
{% set kwh = states(end_power_consumption) | float - states(start_power_consumption) | float %}
{{'\n'}}{{end_message_kwh}} {{kwh | round(2) }} kWh
{% set cost = (states(end_power_consumption) | float - states(start_power_consumption) | float) * (states(cost_per_kwh) | float) %}
{{'\n'}}{{end_message_cost}}{{cost | round(2) }}
{% if include_duration_tracking == "enable_duration_tracking" %}
{% set end_time = now().timestamp() %}
{% set duration = (end_time - start_time) | int %}
{% set hours = (duration // 3600) | int %}
{% set minutes = ((duration % 3600) // 60) | int %}
{% set seconds = (duration % 60) | int %}
{{'\n'}}Duration {{ '%02d' | format(hours) }}:{{ '%02d' | format(minutes) }}:{{ '%02d' | format(seconds) }}
{% endif %}
Blacky
Welcome to the community.
I donât send emails through HA. Maybe you can ask on the forum in a separate topic.
Blacky