Laundry monitor with power meter piston - anyone?


@mrgneissguy - I had the same really annoying issue w/consumption all over the place with my washer, but my problem was worse in that the washer did this both during and after ending the load. Even just sitting there after the load was finished, my washer’s consumption would go up and down, hitting similar low watt levels that it experienced when actually running. Really frustrating.

So my final working washer solution was based on the fact that we run the same load type 99% of the time, and it takes about 52-ish minutes to complete. So I watch for initial start of the washer (provided by a virtual button tied to energy consumption) and then set a 53 minute timer to indicate when the load is finished. Not as elegant as using consumption, but at least it works great. :slight_smile:

I have some timers in as well (door contact must be closed <10 minutes) and a washer running variable to avoid false-start alarms, which were happening in some cases due to the washer throwing out “I’m starting” consumption levels when just sitting there. Making sure the washer door has only been closed for <10 minutes helps ensure that it’s actually got laundry in it (wasn’t sitting for hours since the last load w/the door closed), and the “running” variable is another back-stop to block false positives.

I also have a looping reminder piston in case we don’t respond to the initial “laundry done” messages. The washer and dryer have door sensors on them - when they are opened that kills the reminders. Luckily the dryer is “normal” and I can use consumption for the start and end.


Washer reminder loop:


Dryer Reminder Loop:


Correct :slight_smile: never trust the English written by a Norwegian snowman


Ha ha, thanks for the clarification @Einars (and @Danabw)

I am really new to all of this and have never done any programming, so the learning curve is really steep for this old dog. After looking at different people’s pistons I find it really interesting seeing just how many different ways there are to achieve the same thing. The level of support and help in the community is outstanding as well.


@Danabw, just to clarify, you have one piston which tracks the washing, which alerts you to it being complete. Within that piston, you have a variable {WetClothesInWasher} that gets set to true. Your reminder loop picks up this change and activates (and keeps repeating) until the variable changes to false.

Did you have to set up that variable centrally somewhere, or is just having it any non-paused piston enough? As I said, I am very new to all of this and trying to educate myself.

Is the loop piston immediately stopped once the variable is changed to false? In my one (cobbled together from a couple of other people’s pistons), I have the issue where the loop plays one more time (it seems like it is already in a queue), before finally stopping.



In adapting your piston, can you see any issues with what I have? (I might not be able to test for a week)


Reminder Loop


You can set up a global variable in any piston - then (as far as I know) it lives outside that piston and other pistons and is usable by any piston.

My loop ends immediately as far as I can tell. My son did a couple loads of laundry today, and let the loop run four times after his last dryer load (yes, I was getting tired of hearing the reminder :slight_smile: ) and when he finally went in and opened the dryer door to unload the laundry, the reminder piston stopped.


I am probably the last person to guide someone else creating a piston, as mine are built through begging, borrowing, and stealing stuff from others who really understand this stuff. :slight_smile:

One thing I did notice is that you don’t have any global variables - if you want to connect from your first to reminder piston you’re going to need to use a global variable in both pistons - e.g., @dryerHasFinished. The @ sign makes it a global variable that multiple pistons can use. I assume you know this, but wanted to mention it just in case. Right now your first piston isn’t communicating anything to your second piston.

I am curious what the send email line in your first piston is for - I’ve never seen or used that in a piston. What does that do?

I don’t see any issues w/your piston other than that. Hopefully other more smarter :slight_smile: piston makers will chime in.


Thanks for the feedback.

When I was looking at yours and playing with mine (that doesn’t sound quite right), I tried to add an @ symbol but each time I did, it changed to an underscore. So I don’t know how to get the @ symbol there. Also, no, I don’t know anything about global variables/how to create them?? How they are different to non-global (??) variables. I am all ears though. :slight_smile:


Ah. Sorry - should have told you.

Edit your piston. Look at the right side of the screen - you’ll see “Global Variables.” Select the “+ Add a new Global Variable” option.

32 PM

Global variables can be used in multiple pistons, e.g., you can set the variable value in one piston and then use that same variable in another piston to guide actions.


Thanks for that. I hadn’t even noticed it there. As a dumb follow up question, should they be set as false?


Email: location Send email… allows you to enter a recipient, Subject and body and it simply sends an email to you (or whoever), with whatever message you want. I really put it in there just playing around and to test out what can be done.

Updated Dryer Reminder.

Updated Dryer has finished.

I am just about to give it a quick test…


I believe you want to set them how you want them to start out, and from then on let the piston control their value (unless while you’re testing they get out of whack, and then you can reset them again).


Yeah, looked up and there it was so I removed the line. Both typing too fast. :slight_smile:

Good luck w/your test.


Quick test seems to have worked properly - it stopped the loop from repeating an extra time after the contact opened event. Thanks very much for your help.

Wish I could test more, but have to jump in the pool with the kids. It is 36c here today!


Out of interest-
Can someone point me to the device handler that you are using with these pistons?

I have watts setup as an attribute which appears to disqualify me from using < or > logic


The data is probably coming in as text, try integer(data) and see if gives you the comparison you’re looking for.


I changed it from string to number but didnt see an update in Webcore. Is there a refresh I have to do to have it update the device info ?

Here is the code
Definition (name: “In-progress update of Maxwell’s Aeon HEM V1 Laundry DTH”, namespace: “MikeMaxwell”, author: “Mike Maxwell”)
capability “Configuration”
capability “Switch”
capability “Button”
capability “Energy Meter”
capability “Power Meter”
capability “Actuator”
capability “Holdable Button”
capability “Sensor”
capability “Refresh”
capability “Polling”
attribute “washerWatts”, “number”
attribute “dryerWatts”, “number” //changed this for Core
attribute “washerState”, “string”
attribute “dryerState”, “string”
command “configure”
fingerprint deviceId: “0x2101”, inClusters: " 0x70,0x31,0x72,0x86,0x32,0x80,0x85,0x60"


Try to do it within webcore if possible so you don’t have to mess with the dh. I’m on mobile at the moment but try this…

set variable temp var = integer([yourDevicename:attribute])


I follow you!! Thanks a ton!


Is there a way to have the piston make an echo speaks announcement so all my echos say the laundry is done at the same time? I have my echo dots added individually and they speak at different times. I know echo speaks has an announcement setting I just don’t know how to get there with webcore.