Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
RunTimer2 driver
I don't think anyone else is using my RunTimer2 driver, but I have made a few updates in version 2.23 (attached to Post #1)

I added a QueryTextVal Daily.Days which will return the number of days data has been accumulating.  This allows you to divide the totals and get nice averages.

I also added a new Daily mode: Daily! which will only output data for interesting days (days that had at least one run).  This is ideal for devices that aren't used often.

I also changed the Daily date format to include year (I have 6 years of data for some of my devices).

I just started using it - I have about 1 months of data now tracking my HVAC units.  The reason I wanted it initially was because I know one of the units leaks a little freon, and I added this "Fix a Flat" equivalent, and wanted to see if that would fix it, or if it would continue to leak.  

Unfortunately, I probably missed the Houston heat window, so I may not know until next year whether it fixed it.  I am tracking run times for 3 units, both heating and cooling, so I have 6 items in the driver.  I originally tried the original runtimer, but it didn't provide as much data as your modified driver.

The biggest problem for me was that i wanted to track the last 24 hours (which it has readily available), the last week (which it stores on disk), and the last month (which it stores on disk).  I will eventually probably look at year to year.  The hard part was getting the week/month data from a string list into variables that I could display (I wanted total runtime over that period, the number of runs, and the percentage of time it was running over that period).  I wrote a very long action command that does this and saves it to a persistent variables driver, and so far all is working great. I also am graphing the data using the datalogdb driver and graphamatic.

I will definitely check out your updated one soon.  Thanks for sharing!
Okay, I have been inspired to add some new reporting modes to this driver:
Weekly, Monthly, and Yearly.  These allow you to compare usage across different weeks, months, and years.

I also added a .LastPeriodRuns and .LastPeriodTime QueryText for you.  If you get the Weekly summary report and then get these last period sub fields it will tell you your usage in the current week.  It also works for Month and Year of course (and also Daily, but that would just be silly since you can use the live field for the daily data).

Enjoy -- Bob

P.S.  Here is a yearly log of my FrontDoor:

.jpg   RunTimerPopup.jpg (Size: 29.93 KB / Downloads: 13)
In the seven years I have been tracking only 2016 is complete.  I guess CQC was down at midnight at least one day all the other years.

You can also see that my door has opened 12,025 times in 7 years for a total of 5days 16hrs and 32minutes.  Hard to believe my door is been open for almost a whole day every year!
That is going to be great!  I am definitely going to be using this!
I could also modify the LastPeriod sub fields to NOT include the current day data. That way you could update a variable just after midnight every day, and use the logic server to add the variable to the RunsToday and TimeToday field to achieve a live RunsThisWeek type of field.

Let me know how you want to use it and I can make a simple change for you.

I have just updated the first post with version 2.31 of this driver.

Main addition is comparison types < and > have been added (as well as the default =).  Also comparisons now occur in the data type of the field.

I have also added a hysteresis capability for devices that appear to be running for a moment, but really haven't started yet.  This was all done so I can identify when my Washing machine is running based on how much power it is using.:

LaundryWasher, Power2.RESMON#LaundryWasher~Watts, 6, >, 5, 10
LaundryDryer, Power2-.RESMON#LaundryDryer~Watts, 20, >
PoolHWasher, Power2-.RESMON#PoolHWasher~Watts, 2, >, 25, 2
PoolHDryer, Power2.RESMON#PoolHDryer~Watts, 15, >

The dryers are well behaved, but the LaundryWasher is not considered running until it has used >6 watts for 5 seconds, and it is not considered stopped until it has used <=6 watts for 10seconds.  The PoolHWasher has a lower power threshold, but longer start wait time because it uses some power when starting then idles for 20seconds before finally beginning.

I also converted my <moniker>_<timer>_Daily.log files to .csv files which can be read by standard spreadsheet programs (I now use text dates instead of hex timestamps, etc.).

I now require you to specify which fields need to be polled (and increase poll frequency for those fields to every 10secs).  Thanks to BiDirectional latching triggers (as of 5.3.913), there should be no need for polling whatsoever.  You do need to make sure your trigger thresholds match the config file though...

The Text in your first post has some characters that apparently aren't compatible with MyBB.  Could you please update, or post a text file of the information.

That happened during the move to the new server a while back and the upgrade to the latest MyBB. Not sure what happened. It doesn't affect new posts and didn't affect most old posts.
Dean Roddey
Explorans limites defectum
Okay, first post has been repaired...

Possibly Related Threads…
Thread Author Replies Views Last Post
  Tesla Driver Driver kfly 13 3,412 06-16-2021, 05:43 AM
Last Post: Dean Roddey
  RainMachine Sprinkler Irrigation Controller Driver kblagron 54 11,376 06-04-2021, 01:22 PM
Last Post: Dean Roddey
  Yamaha RX-V673 IP control Driver jdmevo123 22 9,132 03-27-2021, 03:02 PM
Last Post: Spot
  Updated SMS Driver gReatAutomation 0 253 01-28-2021, 12:53 PM
Last Post: gReatAutomation
  Sage Media Server driver (beta) Fonceur 698 309,517 07-26-2020, 04:59 PM
Last Post: sic0048
  Russound MCA-66 on TCP driver 5 1,629 05-24-2020, 06:23 AM
Last Post: gReatAutomation
  Samsung SmartTV Driver George M 0 515 05-20-2020, 09:04 AM
Last Post: George M
  OpenWeatherMap Weather Driver Using OneCall API kblagron 11 2,570 05-18-2020, 04:09 AM
Last Post: dlmorgan999
  JVC D-ILA Driver jokermac 34 11,099 04-13-2020, 01:28 AM
Last Post: Mark Stega
  LIFX Driver bobskie708 15 9,005 01-05-2020, 11:00 AM
Last Post: simplextech

Forum Jump:

Users browsing this thread: 1 Guest(s)