[rrd-users] need help with figuring out how many minutes furnace is on
Simon Hobson
linux at thehobsons.co.uk
Tue Nov 6 20:45:37 CET 2012
Haroon Rafique wrote:
>I have a iComfort Lennox thermostat and a website which allows me to
>gather some thermostat statistics (probably against their terms of
>service - mea culpa). You can see an example here:
> http://haroon.sis.utoronto.ca/perl/rrd.cgi/home_stats/temp.html
>You can look at the source of one of the graphics here:
> http://haroon.sis.utoronto.ca/perl/rrd.cgi/home_stats/temp-day.src
>
>I would like to know how to display how many minutes (or seconds or
>percentage of time), the furnace or A/C is on. The mode DS returns 0
>for idle, 1 for heating and 2 (yet to be tested) for cooling.
I'd suggest you want a DS for heating which is either 0 (off) or 1
(on), and update this as often as you can. And have a separate DS for
cooling, again 0 or 1.
The problem with a combined DS is that you cannot consolidate it and
keep anything meaningful. For example, if you had the cooling on for
50% of the time, then after consolidating you'll have an average of 1
which could mean you have 50% cooling, or it could mean you had 100%
heating !
So just update frequently, even if your primary data points are some
time apart. If the stat is on (and calling for heat) then set the
heating to 1 else set it to 0, ditto for the cooling. Over a period
it will give a good approximation to the level of heating and
cooling. For example ...
Suppose the heating is cycling on a 50% duty cycle and with a period
measured in a small number of minutes, your PDPs are 5 minutes apart,
and you sample every minute. On average, you're likely to get 2 or 3
updates with a 1, and 3 or 2 updates with a 0 during each PDP period
- to give an average of either 0.4 or 0.6. Over several PDPs, the
average will converge on about 0.5.
By the time you average over a say, the short term variations will
disappear and you'll get a fairly accurate indication of how long the
heating or cooling has been running.
If the heating or cooling output is variable, then ideally you'd want
to have an indication of how much heat/cool you are getting. Eg, if
the heating is running at 50% of max, then update with 0.5. Absent a
better interface than a thermostat, that's probably not practical.
--
Simon Hobson
Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.
More information about the rrd-users
mailing list