Graphing of time measured events



  • Needing guidance from those who have doubtless hit the same problem, how to track time duration events, in this case for boiler run times?
    I set up two devices to report to Domoticz, one to signify the boiler had been turned on/off as in a binary switch, the other as a cumulative value of time since starting, in the later case reporting as gas (as in m3) solely because I had no experience beyond quantifiable objects. Running-time would not appear be a required measurement, so right now I have 147.000m3 o fboiler running time. It is spot on for minutes, but is isn't minutes.
    The trigger for both depends on the ADC level of a resistance ladder (24v -> 1.1v, 0v->0v) from the central heating controller
    Any pointers please...
    The Switch Log does crazy shit presently, starting from January on the bottom graph, but the immediate "On" graph persist until it's "Off", when it disappears into the ether aside requiring separate analysis of the data.
    I realise the above is a glitch pending a new stable release, but since this has persisted since May 2019 and the issue will not be unique, suggestions please on alternative sensor type etc as have found nothing....



  • @zboblamont I am not really clear on what you need the graphs to show. But I use Mycontroller and have attached DS18B20's to the 'flow' and 'return' pipes at the boiler.

    From this I see graphs in Mycontroller of temperature against time. Useful to see if it is working normally.

    Mycontroller pi is currently in a crashed state and I need to power cycle it to get it going again. I can post a typical graphs after about 24 hours if it interests you.



  • @skywatch Thanks but no need, the temp side has more or less worked flawlessly with 12 DS18B20 on a single Cat5e for over 2 years now, quite intriguing to see temp variations over two years...
    The next pair is for this Node, the same as you did for flow return temps, once the order arrives. Having put Heimeier constant flow thermo valves on the radiators last year I managed to draw the return temp right down from roasting to warm at peak, but it would be good to quantify. It lopped 10% off the gas so that tweak already paid for itself, and kept the place +/- 0.5 degrees... 😉

    The graphing question is more a case of recording boiler burn times as an integer for the CH such that daily minute durations are built and retained up to say a year. Currently I send a binary to a "Switch" and a cumulative read as "Gas". The former has a glitch and limited time retained, the latter is a temporary solution to display a bar graph, and build/retain a daily record for up to a year.
    It's not ideal, and as the same Node will also soon begin recording power cuts, a better solution is doubtless available to MySensors/Domoticz, I just can't find it...



  • You could set up an influxdb server and have domoticz send updates to it. I do that for some things that I want to track for more than a year. Then you can use grafana to set up graphs you like. Domoticz has a setting you can use to pick readings to send to influxdb.



  • @nagelc True, but this is more a question of what format should be used to natively record it in Domoticz.
    The binary V_STATUS and S_HEATER works ok, but V_VOLUME and S_GAS was used simply as a temporary solution. The Gas Meter already reports in this format, so knew it summated hourly and graphed natively. I know that the displayed 82.000m3 really means 82 minutes burn time, but it's not neat.

    I have to look into infuxdb later to combine and analyse different datasets, but for now I'm hoping someone can point me to what I'm obviously not seeing in the documentation.



  • @zboblamont Have you looked at grafana.com?



  • @skywatch I haven't looked at anything external yet, haven't even gotten round to trying out NodeRed... 😢



  • @zboblamont
    Yeah .... I see the problem. I have several sensors that measure levels that I report as voltage, because I just want to send a float number, and S_Voltage handles that. A nice feature would be to be able to override the units display, but I haven't figured out how to do that.



  • @nagelc It appears after further reading and research that it is neither a possibility nor on Domoticz's radar to handle time dependant events.
    I found an excellent discussion and working LUA strategies using Dummy sensors which satisfied those who had used it to solve pump run-time queries, but it disintegrated upon arrival of a much earlier version of Domoticz than today.
    I must presume that because time is perceived as a datum against which Domoticz contrasts events, time duration such as "pump running" is not on their agenda and is well off-field for future consideration..
    Going to investigate LUAs, already dimly acquainted with the LUAS...



  • Domoticz has a nice dummy counter or dummy incremental counter, where you can enter the unit quantity.

    0_1572638711080_2019-11-01-205153_1920x1080_scrot.png

    MySensors unfortunately is unable to send data to these counters.
    I am using them with ESP8266 to send energy consumption of my floor heating or number of actions of my relays.
    So I recommend to use DzVents scripts in Domoticz instead of node-red.
    I see two ways.

    Send from node for example in watts or m3 or litters.
    With DzVents translate this value to time in minutes in Domoticz created dummy counter.

    Write DzVents script for your switch, which saves time for ON action and when OFF action occurs, calculate time interval and adds minutes to dummy counter.

    Then you can see the beautiful statistics for each day of the entire year back and the actual total value too.

    For example here for my relay actions:
    ( "zapnuti" = "relay on" )

    0_1572639186614_2019-11-01-210910_1920x1080_scrot.png

    0_1572639199194_2019-11-01-211001_1920x1080_scrot.png

    0_1572639211192_2019-11-01-211015_1920x1080_scrot.png



  • @kimot Thank you very much indeed.
    Was already looking at such a strategy but your explanation confirms it is not only viable but you already have a working solution as extensively exampled.
    It is an odd omission by the Domoticz team that it requires a workaround, but your solution is neatly done.


 

231
Online

8.9k
Users

9.6k
Topics

100.8k
Posts