Instance Counting for Fuel Steams


#1

1) Give a description of the problem
I have energy monitors that alert us on washing machine, dryer, dishwasher, etc, cycles. My wife was curious how many cycles of each she does a month. So, every time a cycle is complete I want to add to a fuel stream so I can see how many are done per month. All I seem to be able to get it to do is show a ‘1’.

2) What is the expected behavior?
A cumulative total in fuel stream rather than just a single ‘1’

3) What is happening/not happening?
I just get a single ‘1’ rather than a cumulative total.

4) Post a Green Snapshot of the pistonimage
(UPLOAD YOUR IMAGE HERE)

5) Attach any logs (From ST IDE and by turning logging level to Full)
(PASTE YOUR LOGS HERE BETWEEN THE MARKS THEN HIGHLIGHT ALL OF THE LOGS SND CLICK ON THE </> ICON TO FORMAT THEM)

REMOVE BELOW AFTER READING
If a solution is found for your question then please mark the post as the solution.


#2

This is my first time helping anyone as I’m fairly new, so forgive me if this is rubbish, but I think this could work.

Set ‘Switch 4’ to be whatever your washing machine is. i.e. set it to when it turns off after drawing power for more than 30 minutes…?

Checking the local variables, every time I’m turning the virtual switch off on the smartthings app, the total count is increasing, so I think it’s working.

If you wanted to seriously geek out, and if your energy alert can tell you much how power is passing, you could log how much power that machine uses each month, and then maybe cost etc etc

I might now use this at home myself!


#3

@onslowhjr has the right idea.
I would think you could create a variable.
The use the cycle done alert you get to increment the variable by one.

If cycle done alert on
Then Setvariable cycle count (cycle count + 1).

Then at end of month send a notification with the total and reset the variable to zero.

I do this with a piston that counts the motion events then sends me notification at the end of the day with the total events. I will try to share but I’m away from my computer so harder for me to do on a time phone.


#4

Here is an image of my motion counting piston.