Trying to wrap my head around rule machine - washing machine "done" notification


I am relatively new to Hubitat. I am trying to set up a rule to alert me when my washing machine is done.

I have a Smartthings mutli sensor connected to Hubitat. I am trying to build a rule like

If acceleration became active, and then became inactive for at least 10 minutes, alert me.

Here's what I have right now:

It definitely doesn't work. It alerts every couple of minutes, for like, ever.

It seems like there is something I am fundamentally misunderstanding. Any help?

You have enabled cancel, but nothin IS canceling

There is a pretty good app for this that works and has some nice filtering and wattage settings that are helpful to reduce false triggers that you might want to try.

You're going to run into problems here because your washing machine stops frequently during the cycle. When it goes to fill and rinse, I would be surprised if the accelleration sensor reads anything. So, instead of getting a notification that the cycle is complete, it will notify you when it starts to rinse. For washing machines, the only truly fool-proof methods to detect if it is done is energy monitoring or a photo-sensor tied to a "Done" led on the washing machine. I've not heard of any other reliable method for washing machines.



You have enabled cancel, but nothin IS canceling

I am not actually sure how to specify what to cancel. The UI seems to just have a toggle, but no way to associate it to anything?

All that does is enable the potential for cancelling.

RM is wonderfully complex now... you can have 10 items in an action. Maybe only 3 of them have a need to be cancelled. You would enable cancel on those 3, leave it not enabled on the other 7 and then when you actually issue a Cancel.. those 3 will stop.

In RM 2->3 that switch was "Cancel on truth change" -- RM 4 doesn't have "truth change" anymore. So you have to actively provide the Cancel action.


On the other hand, I do kinda like @neonturbo suggestion of Better Laundry Monitor. (I'm certainly biased, since I am actively updating that app right now.)

Hubitat-BetterLaundryMonitor <-- click there :slight_smile:

Hm. I guess what I have are two questions:

  1. how do I do this thing with my washing machine. You all are recommending a power monitoring outlet, which seems reasonable.

But #2, the meta-question: how do I build complex rules in rule machine? I just don't see how you built that IF/ELSE statement in the UI I am looking at @csteele

I was hoping to use an Iris 3210-L to monitor my washing machine. But the 3210-L max amperage is 12 amps and my washing machine rates at 15 amp. ( according to the nomenclature plate )

A washing machine finished notification would be nice.

Select conditional actions. The ifthen/elsif/else functionality is in there.

@Angus_M I feel like I must just be missing something super obvious, but I don't see that. Can you show me a screenshot of where you see conditional actions?

In RM 4.0, this is how I handle Washer/Dryer notifications based on the Power usage dropping below a threshold (e.g. 3.0 Watts) for a certain period of time (e.g 32 seconds.) If the power level goes back up above the threshold within those 32 seconds, everything resets and waits for the power to drop below the threshold again.

You have to play around with the Power Threshold and the Delay Time to prevent false alarms for your particular washer and dryer.


@ogiewon I was trying to follow your example on RM4.0 Power level Washer and get the following error? Is there something else that I need to do?

2019-08-18 10:07:00.004 am errorjava.util.NoSuchElementException: Cannot pop() an empty List on line 5640 (delayedActs)

@leeonestop I have no idea what would cause that error. Maybe delete the rule and start over? It’s a fairly basic rule, nothing too fancy. It uses Private Boolean (for This Rule) to prevent the rule from constantly sending notifications.

I'm getting basically the same error, on a different line with the same Rule as in post 11


When the washer first ended, I received 2 messages 5 seconds apart, then 1 min later got it again, then it stopped.

Any suggestions to how this can be optimized?

I actually tweaked my RM4 rule as follows to try to prevent multiple notifications.

Note the change in the ELSEIF section, where I moved the PB line to be first.

Updated version


I tested this by taking a bunch of screenshots whilst the meter was running.
Then wrote this one up and it worked last night. I realise all machines will have different programmed cycles/etc.

This is mine, mostly yours.
I changed the first trigger because the machine is using a small amount of energy while idle and I don't want to cut entirely the power (zooz zen15) - WAF...

I also added a way to measure the maximum power used by the wash machine, using a global variable and a connector to display it on my dashboard.

Btw, is my way to add the IF-THEN loop correct ? It works (I received my first notification after the wash was done) but your comment on this is welcome.


@PPz is this code working for you? I have a dryer and washer that goes through different cycle and the power is up and down and I get false readings but after looking at your rule It looks like it may stop the false readings changing the max power is that correct?

The code is working for me. I realy don't think the Wmax loop does anything on this because it records only (while washing) the max power used by my machine and nothing else.
Probably the difficulty for any rule is to define exactly the perfect trigger.

In my case, the initial rule ("power changed") is not acceptable because my Zooz monitors a very small amount of energy, so always changing.
In iddle mode, the power is all the same inferior to 2 watts, that was my first trigger to initiate the rule.
when the machine is washing, the power is always higher than 5 watts until the end.

But writing this, my wife loaded a machine and I received a notification after 5 minutes, that means I need to fine-tune this rule too (probably the delay - too short) :unamused:

Thanks for the reply. Yes I'm still refining.