Hello, I found this post looking for how to turn my dishwasher smart without having to touch the dishwasher installation, so an external sensor would be ideal, searching on amazon I found this:
https://www.amazon.com/Aeotec-SmartThings-multiusos-temperatura-perfecto/dp/B095TPSQ3S?ref_=ast_sto_dp
It is a Zigbee sensor that exposes 3 sensors to Home Assistant: Door Opening, Vibration and Temperature.
I tend to complicate things a bit but Iām very happy with the end result, so I decided to share my process:
I created a helper (input_boolean.dishwasher_is_washing) that tells me if the dishwasher is washing based on the information from the vibration sensor because the vibration sensor turns on and off frequently during the wash cycle and this was the way I found to solve this problem.
Then I created an automation that turns the helper from the previous step on or off, if it detects vibration for more than a minute then the dishwasher is washing, if it stops detecting vibration for more than 7 minutes then it stopped washing
alias: Define if the dishwasher is washing
description: ""
trigger:
- platform: state
entity_id:
- binary_sensor.dishwasher_accelerometer
to: "on"
for:
hours: 0
minutes: 1
seconds: 0
ID: on
- platform: state
entity_id:
- binary_sensor.dishwasher_accelerometer
to: "off"
for:
hours: 0
minutes: 7
seconds: 0
ID: off
condition: []
action:
- choose:
- conditions:
- condition: trigger
id:
-on
sequence:
- service: input_boolean.turn_on
metadata: {}
data: {}
target:
entity_id: input_boolean.dishwasher_is_washing
- conditions:
- condition: trigger
id:
-off
sequence:
- service: input_boolean.turn_off
target:
entity_id:
- input_boolean.dishwasher_is_washing
data: {}
mode: single
Then I created a sensor that determines if the dishwasherās heating element has been activated, what I call āthe heat phaseā and for this I used the trend platform:
- platform: trend
sensors:
dishwasher_heat_phase:
friendly_name: "Dishwasher Heat Phase"
max_samples: 5
entity_id: sensor.dishwasher_temperature
sample_duration: 1200
min_gradient: 0.001667
device_class: heat
Finally I created another sensor (input_select.dishwasher_status) that informs me the status of the dishwasher, in my case I chose the following phases: Dirty Dishes, Washing, Heat Phase, Drying, Clean Dishes.
The logic is that if the helper input_boolean.dishwasher_is_washing is activated and the door is closed, the dishwasher is washing. If the dishwasher_heat_phase sensor is on and input_boolean.dishwasher_is_washing is on, then it switches to heat phase, otherwise it switches to Drying.
When the dishwasher_heat_phase sensor is turned off and input_boolean.dishwasher_is_washing is off, it changes to āClean Dishesā and remains in this state until the door is opened and then it switches to dirty dishes.
Hereās the automation that updates the status of the dishwasher:
alias: Dishwasher Status
description: ""
trigger:
- platform: state
entity_id:
- input_boolean.dishwasher_is_washing
to: "on"
ID: Washing
from: "off"
- platform: state
entity_id:
- input_boolean.dishwasher_is_washing
to: "off"
ID: Deodoraver
from: "on"
- platform: state
entity_id:
- binary_sensor.dishwasher_heat_phase
to: "on"
from: "off"
id: fasecalor
- platform: state
entity_id:
- binary_sensor.dishwasher_heat_phase
to: "off"
from: "on"
id: terminocalor
for:
hours: 0
minutes: 0
seconds: 0
- platform: state
entity_id:
- binary_sensor.dishwasher_opening
from: "off"
to: "on"
id: dirty dishes
condition: []
action:
- choose:
- conditions:
- condition: trigger
id:
-Washing
sequence:
- service: input_select.select_option
metadata: {}
data:
option: Lavando
target:
entity_id: dishwasher_condition input_select
- conditions:
- condition: trigger
id:
- Heat Phase
sequence:
- if:
- condition: state
entity_id: input_boolean.dishwasher_is_washing
state: "on"
then:
- service: input_select.select_option
metadata: {}
data:
option: Calor Fase
target:
entity_id: dishwasher_condition input_select
else:
- service: input_select.select_option
metadata: {}
data:
option: Secando
target:
entity_id: dishwasher_condition input_select
- conditions:
- condition: trigger
id:
- Deyodelavar
sequence:
- if:
- condition: state
entity_id: binary_sensor.dishwasher_heat_phase
state: "on"
then:
- service: input_select.select_option
metadata: {}
data:
option: Secando
target:
entity_id: dishwasher_condition input_select
- conditions:
- condition: trigger
id:
- terminocalor
sequence:
- if:
- condition: state
entity_id: input_boolean.dishwasher_is_washing
state: "on"
then:
- service: input_select.select_option
metadata: {}
data:
option: Lavando
target:
entity_id: dishwasher_condition input_select
else:
- service: input_select.select_option
metadata: {}
data:
option: Clean Dishes
target:
entity_id: dishwasher_condition input_select
- conditions:
- condition: trigger
id:
- Dirty dishes
sequence:
- service: input_select.select_option
metadata: {}
data:
option: Dirty Dishes
target:
entity_id: dishwasher_condition input_select
mode: single
I hope it can be useful to someone and I apologize in advance if there is inconsistency with the names of some sensors or helpers since I did everything in Spanish and tried to translate it as best as possible into English but there may be errors.