Furnace Filter Countdown Timer

I wanted to have a tile on my dashboard that counted down the days till I needed to change the filter, I also wanted a tile beside this countdown tile to reset the timer. (Did not want to do it with any add on apps, just RM). Got it done, works great, wondering if there is a way to do it without creating so many global variables (Current Unix Time, Furnace Filter Change Time, Days to Change Furnace Filter Unix, Days to Change Furnace Filter #, Furnace Filter) Thanks for any feedback.dashboard%20tile

1 Like

I like what you have done with this. That is should a great idea. Thanks. Does this change color when it needs to be change? or give you a text?

Adding "send a message" to the rule is easy, having a tile change color based on its value, I do not believe is possible. Would love to be proven wrong.

How did you create the Furnace Filter tile? I having no luck?

Basically it is all shown above, If you want to do it like I did, you need to create the five global variables shown in the above screen shot. Make the variable you want shown on the dashboard as a connector, so it shows up in your device list as a global variable connector. Be aware of the variable I called "Furnace Filter" that is a string variable with the value "Replace in: %Days to Change Furnace Filter #% days"
Yours should have the exact name of your variable between the two % symbols. i.e. "Replace in: %the name of your global variable% days"

You may want to wait awhile before trying to duplicate, this may not have been the easiest way to do this, someone smarter than me might chime in with an easier way. LOL

You don't have to use a separate variable for each function, you can have variable math set a variable where it uses itself in the calculation. I can see you being able to eliminate 2 variables from this. I would have variables for the following:

  • Time in seconds when the filter is going to be changed.
  • Time in days between now and the filter requiring a change.
  • Message for the tile.

You don't need the current unix or the days to change in unix.

This would also be a very easy custom driver to write. I wrote something very similar for a programmed delay switch for different virtual switches I had. Time can sometimes be a PITA to work with but it really gives you an understanding how the system works.

1 Like

Thanks for the feedback Ryan. Changed the rule to 3 GV based on your tip, another tool in the bag. Thanks again for your help.

1 Like

@Stephan.J can you show the changes that you made? Thanks


The first 3 actions in the rule do something to the GV I call "Days to Change Furnace Filter #"

  1. Sets it to current unix time
  2. Sets it to unix time difference between itself and a GV I call "Furnace Filter Change Time"
  3. Sets it from a unix time value to an integer of days remaining
    and the last action updates a GV string variable I called Furnace Filter (that I have as a connector) so it displays the correct number of days.
1 Like

@Stephan.J I been looking and trying to understand what you did and I have a couple of question? Where did you get the 86400.0 number from and the one that you add to the Current Unix Time which is 2.0736E7? I been on the net looking at the different programming on time and couldn't find them? I'm not a programmer but trying to learn a little. Thanks

When you set a variable to current time. It sets it to current Unix time. (the amount of seconds since Jan. 1 1970) The current Unix time as I write this is 1570932881
86400 = number of seconds in a day
20,736,000 = number of seconds in 240 days

Thanks I found the 86400 and thought that what it was but did not think about multiply it by the number of days thanks for the info.

@Stephan.J I would like to thank you for helping me understanding your rule and sharing it with others in the community. I never really heard of Unix Time before your use of it. I now have a better understanding of how to use it. Thanks for your help and patience.

Hi all,
how can I get current unix time in rm 4.0

You could use Brian's app 'Notifier Plus"