Ideas on how to monitor elapsed time since last event

Hey Guys,

I have a couple of Wall Plugs that are able to be Tasmota'd (is that a new dictionary word i wonder ?) - they provide energy monitoring as well as remote control.

I plan on using them on my Washing machine and dryer to monitor when their cycles are finished and to provide email and Telegram alerts.

The units will provide an update every minute of energy used that day - based on manual observation of the dryer and washing machine it appears they do not pause for any longer than 5 minutes at any point in their cycles before they are finished. So i will use 5 minutes of little or no energy consumption as the inital benchmark and then tweak from there.

So how would people approach this

  1. I will need to work out when a cycle starts - my thought would be to find the initial "baseload/standby" power draw over (say) a 5 minute period and to store that away

  2. Keep a running tally of each 5 minute window of power useage and when that number "jumps" (metric to be confirmed at this point) - can assume a cycle has commenced.

  3. Continue to monitor each minute and build that baseload power draw as a 5 minute sliding window - once that falls back to near the baseload/Standby power metric assume the cycle has finished and notify accordingly

Does anyone else do this type of thing and have any words of wisdom as to how they approached it ?

What would be the best way of calculating when the running tally gets "near" the baseload - just look at a percentage differential to allow for some flexibility or is there a node that will do some mathematical shenannigans for me ?

Craig

Hi Craig.

Something like this?

[{"id":"3a1f7e51.20bc72","type":"inject","z":"b9924a74.4d98f8","name":"From Tasmota device","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":180,"y":4090,"wires":[["d9300f32.bd4a18"]]},{"id":"d9300f32.bd4a18","type":"switch","z":"b9924a74.4d98f8","name":"Value","property":"payload","propertyType":"msg","rules":[{"t":"gt","v":"(number value for inuse power consumption)","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":400,"y":4090,"wires":[["f778eff5.354018"]]},{"id":"f778eff5.354018","type":"trigger","z":"b9924a74.4d98f8","op1":"In use","op2":"Done","op1type":"str","op2type":"str","duration":"250","extend":true,"units":"ms","reset":"","bytopic":"all","name":"","x":560,"y":4090,"wires":[["b8c164de.b7abe8"]]},{"id":"b8c164de.b7abe8","type":"debug","z":"b9924a74.4d98f8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":760,"y":4090,"wires":[]}]

Hey Andrew - that looks like it might give me a starting point - thanks

Craig

No problems.

All the best.

...in addition to what already has been suggested...I'd never try and tweak the trigger signal near the (5min) baseload but rather would double the window (to at least 10min) before alerting someone. Unless you are required to run a business, keeping the machines busy, this would save you (or someone else in the household) from some disappointing "empty runs".

...and make sure that the wall plugs can handle the power draw...I'd not allow them to go anywhere near the advertised max current. The better ones also have an overheating protecting kill-switch.

Good points thanks - will check as to the power rating of the devices

Craig

I really could do with knowing when the washing machine has finished as I'm terrible at remembering to get the clothes to dry :frowning:

What make/model of switches are these?

Personally, I would rather do the timing in the ESP device not in Node-RED. But maybe Tasmota isn't flexible enough for that? One of several reasons I tend to end up going back to my own code.

Just a thought about other approaches as well. Most versions of this kind of monitoring that I've seen previously on the web have used vibration sensors instead of power monitors.

Also, do other people have issues with smart switches failing? Out of about the 10 or so I use at home, I'll typically be getting at least 1 fail each year. I need to find some time to take them apart to see what is failing in them whether it is an internal fuse or the relay. Only just got the specialist screwdriver tips though - took 6m to arrive from China, a record I think :upside_down_face: I currently use a mix of LightwaveRF, HomeEasy and SONOFF switches.

I tried using a cheap sound sensor last year but that had too many false positives so may look at that route as well

I think I have had two Sonoff devices fail over the several years. About 8 installed I think. One of those was a 10 Amp TH10 driving a 2kW fan heater (8A) cycling once a minute when proportioning to control the temperature. It lasted a few months then the relay contacts failed. I wasn't too surprised by that. The 16A version seems ok so far. The other was probably faulty from new, but I didn't realise till I tried to use it with a greenhouse heater, which has to control at 3C. Then it turned out that that it crashes when it gets down to about 3.5C. Luckily no plants were frozen as it wan't too cold the first time it happened. A replacement has been working fine since then and the faulty one repurposed for inside use.

1 Like

I am in Australia so these are Kogan devices - benefit is they can be Tuya OTA so very easy to convert to Tasmota and they provide 2 x USB ports so you can add a NodeMCU (or whatever) to do any other monitoring

I am going to monitor the energy levels on them - they are supposedly rated for 10AMPs - not sure how much the dryer will pull - may have to go t a Sonoff PowR2

Craig

Yeah - i have that as a fallback option - but these came up for cheap and looked good so thought it worth a try first off

Craig

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.