🔌 Detect and monitor the state of an appliance based on its power consumption - V2.1.1 - Updated!

What a wonderful piece of work! Thank you @leofabri for the countless hours you must have invested.

I’m experimenting with V3.0.0 because I need the timers.

It is working. However, there are errors in the log:

ERROR (MainThread) [homeassistant] Error doing job: 
Task exception was never retrieved  
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 444, in async_run
raise err

To provide some context, I set up the logger integration as follows:

logger:
  default: warning
  logs:
    homeassistant.components.asm_blueprint: debug

The log results for various experiments are here: https://pastebin.com/guJqnmm6

washing-machine _wit
tumble-dryer_wit
tumble-dryer
washing-machine

Have fun!

2 Likes

Wanted to try this blueprint today. I connected my plug to the socket, added my washing machine to the plug. Set up the helpers, added and configured the blueprint. I then set some wattages rules etc. All going well so far, it knows when it’s running or not.

But after like half an hour it stopped. The smart plug went to ‘off’ so my washing machine got cut off the power. In the HA logs there is nothing directly that caused it as far as I can see. The latest wattage was quite low, while the plug handled the 2200-2300W just fine, later when it returned to just a few watts, it just turned off. Any idea how that can be? I had it connected before and it worked fine without the blueprint.

Hi @leofabri, what might be a fun addition to your blueprint is adding an “unemptied” state that tells you the appliance needs to be emptied. This can be achieved by using a door sensor that detects if the appliance door is opened after the job is completed. This can then be used to for example send an extra message to your phone that you really need to empty the appliance after it is done for an hour or so.

For now I have a couple of automations that control my washer states and I would like to start using your blueprint, but I’m missing this extra state.

Please let me know if this is an option.

These icons look great, thanks! Can you let us know how to implement them?

1 Like

In the custom button card you can use this

  1. upload the gif icons to your www folder (if you don’t have a www folder, create it in the root of HA via File Editor plugin or Studio Code Server
  2. add this in the card after the entity:

show_entity_picture: true

  1. where you want the gif icon to show add this:

entity_picture: /local/wasmachine_3.gif

www == /local in the path, so don’t use www in the path, but /local

1 Like

@millercentral Just tried your 3.1.0, but it seems to always get “stuck” in a paused state when it’s finished. I have set the threshold to 18w and a delay of 300 seconds. Currently, it’s at 11 watts and have been for a while. Last time the ASM-automation ran was 24 minutes ago.

Any idea on how to debug this?

If I setup and use the optional HA_PowerControl addon, how does your blueprint get the pause state exactly? Just by changing the state or what exactly connects both of yours automations?

This is such an amazing blueprint. Do you know if the Govee smart plugs work with this?

" Govee Smart Plug with Energy Monitoring, WiFi Bluetooth Plug Work with Alexa and Google Assistant, 15A Smart Outlets with Timer & Group Controller, No Hub Required, ETL&FCC Certified for Home, 4 Pack"
https://www.amazon.com/Govee-Monitoring-Bluetooth-Assistant-Controller/dp/B0CKM8CF7N/ref=sr_1_7?crid=3KJ1DNRZUZII4&dib=eyJ2IjoiMSJ9.qCgj2Bb17juuzJMgAV5gPyId0IQOMJ6S-Kzr1eg1LNEqDdhc29Ps9IpYYLfcE8PJJn9_ZiYj53S69rCHABk4rULW8c13geNHZU1hXxrrYUAiNtbDEckWytIxrFEG6JsOYIb6R3kWObzE5N1o6ZTHlhoC8owjcRxz7oOE1e9ai166rRC6bIBVo4dX4j9H-oMupGPGgQMReC6QexXM14Z0osfWQmdlM2UFvgbi-xy1NHJLgoeRZzdW2df1V7rNCfjvVRvlzku8QTCqITUJd8HeKJ2YZxaSYGyYmxGR4flq4ME.C7mEzovkISBmunwti0r0OKml5BwLuQ0ZmgMlwA_h460&dib_tag=se&keywords=wifi%2Bsmart%2Bplug%2Bwith%2Benergy%2Bmonitoring&qid=1718451467&sprefix=smart%2Bwifi%2Bplug%2Bwith%2Bener%2Caps%2C111&sr=8-7&th=1

Thanks.

Hello everyone!

I got a power-meter (shelly-em) and hooked it up to my appartment power circuit. My washing machine cycles have a specific pattern, and look like this (the spikes on the right; the thing on the left is two AC units):

Now - I see that most people use a smart plug to track the energy usage of specific appliances. I’d like to ask if it’s possible for this automation (or others) to detect a cycle of my washing machine from the total consumption of the appartment. My guess is it should look for patterns, not absolute values in consumption.

Is anybody doing “pattern matching” on their aggregate consumption data to say if a specific appliance is running?

Thanks!

Bumping this question since i also like to know.

Hello,
I use your blueprint for my washing machine, dryer and dishwasher. I have a W-LED that shows me the status of all 3 machines, for pause detection I use a door sensor on each door. Is it possible for you to integrate a query of the door sensor into your blueprint that detects a pause condition by this door sensor?
So as long as the door is closed the process can run and as soon as the door sensor is opened the state goes into pause mode and when the door is closed the process continues. Another good function would be to execute own actions when pausing and restarting.

Thank you very much, I really admire and appreciate your work

Hi @leofabri , first I want to say thanks for the great Blueprint. I’m trying to turn of the charger of my E-Bike when it get`s an SoC around 90% as there is no official Way for a Bosch BES3 System.

While charging the load is around 180W and when it get’s nearly to 90% SoC then it drops ( in 30 s steps) downwards until it`s fully charged.


(This ‘stepping down’ is good reproducable.)

My Problem is that your Blueprint only accepts a Finishing power threshold Value between 0 - 100 W and any bigger Value is ignored, while I need to set it to around 160 to 165 W to check if the Job has finished.

Is this a lot to change for an upcoming release or can it maybe also be done somewhere inside the actuall 2.11 Blueprint.?

Thx

Perhaps you could try subtracting 100 watt in a template sensor of your Power Sensor!? And then use it for your Finishing power threshold.
You can try it :grin:

I’ve created a Sensor with -100 Watts but the appliance is still not turning off when the consumption goes under 68 Watt.


Today 17:31 but nothing happens. :disappointed_relieved:

At 17:35 when I unpluged the cherger from the bike the automation stops, Message is send and the socket turns off. ( like it should do automatically)

A few days ago I tested the blueprint with lower values ( 10 Watts Start, and under 13W assume it has finished with a Phonecharger ) and there it works.

Today 18:57 ( next Bike beeing charged) the blueprint stopped far to late when the load was around 18,5 Watts.
grafik
But the next thing i realized in the Log/Traces is that it looks like the automation wait’s for the “Delayed Job Completition Timer” ( per default 15 mins.) and then triggers the end of a cycle.

15 minutes befor the STOP the Power was around the desired 72 W.

Maybe I have to shorten this delayed Feature to 1 Minute.

But first I have to empty my Bike tomorrow. :bike: :man_biking:

Today there was a first breakthrough


I changed the values for Starting power and Finishing Power threshold from 20 & 72 Watts to 73 and 72 Watts and I got two automated charging cycles where the socket was turned of as the consumption got lower then 72 W.

After reading the description for multiple times it makes sense setting the Starting point higher then the Finish.
:beers: :man_biking: :call_me_hand:

Did you figure this out in the end? I’m in the exact same situation, and cannot rule out other power consumers to potentially run sometimes inbetween, so I need a detection combination that takes peaks, numbers of peaks and how far apart they are into account. My washing machine basically has one bigger peak in the beginning (for the initial heating up of the water), and 3 tumble peaks towards the end. But if in the middle of the 2.5h cycle the water cooker gets used, I don’t want the automation to assume that the tumbling started :slight_smile:

Not sure if i undestand your Problem. If your taking the actual power consumption of your washing machine with a “measuring-plug” how should the Water cooker ( connected anywhere else in your house ) come into your automation.?

Regarding my search to match a specific power usage pattern from the total home power usage, I managed to do it like this (it’s currently under testing): Get the value of a sensor at a specific time - #13 by Darkwell