@Robert.Wall my great apologies for taking so long to reply to your most gracious and exceedingly prompt reply to my call for help. You encouraged me greatly, and after a few more stumbles with the Arduino IDE I have gained the confidence to add to my setup and start recording Boiler Feed and Return temperatures on my Gas central heating. Thank you many times over, I am very appreciative of the time you took to write your message.
I now have this new section (within green rounded rectangle) in my emoncms dashboard
My new question is - why are there gaps in the Feed records? You can see the graphs have missing sections. Looking in closer on, for example, the Boiler Feed
You can see gaps in the recorded data, which I do not understand. This page offers a CSV download, resulting in
"Date-time string", "emonth2A:BoilerFeed"
2021-12-20 17:12:50, 59.7
2021-12-20 17:13:50, 58.0
2021-12-20 17:14:50, null
2021-12-20 17:15:50, null
2021-12-20 17:16:50, 53.3
2021-12-20 17:17:50, null
2021-12-20 17:18:50, 50.5
2021-12-20 17:19:50, 50.2
2021-12-20 17:20:50, 53.0
2021-12-20 17:21:50, 56.2
2021-12-20 17:22:50, 59.2
2021-12-20 17:23:50, 60.2
2021-12-20 17:24:50, 58.2
2021-12-20 17:25:50, null
2021-12-20 17:26:50, 54.1
2021-12-20 17:27:50, 57.1
2021-12-20 17:28:50, 54.2
2021-12-20 17:29:50, 52.3
2021-12-20 17:30:50, 54.7
2021-12-20 17:31:50, 57.7
2021-12-20 17:32:50, 60.3
2021-12-20 17:33:50, 60.0
2021-12-20 17:34:50, 57.5
2021-12-20 17:35:50, 55.2
2021-12-20 17:36:50, null
2021-12-20 17:37:50, 52.1
2021-12-20 17:38:50, 50.8
2021-12-20 17:39:50, 51.3
2021-12-20 17:40:50, null
2021-12-20 17:41:50, 54.3
2021-12-20 17:42:50, 57.6
2021-12-20 17:43:50, 60.5
Taking as an example the first 7 data points (recorded as 59.7, 58.0, null, null, 53.3, null, 50.5) , when I go and look in emonhub.log
for 59.7 near 17:12:50 I see (snipping 2 extra lines either side of what I think are relevant)
[Point 1 - csv record is 17:12:50, 59.7] At 17:13:55.793 (ie 65.8 seconds later than timestamp) :-
2021-12-20 17:13:55,725 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:13:55,726 DEBUG MQTT Publishing: emonhub/rx/5/values 26.964,615.357,642.321,236.48390999999998,15.100000000000001,0,0,0,0,0,1567932
2021-12-20 17:13:55,793 DEBUG RFM2Pi 111225 NEW FRAME : OK 23 230 0 85 2 251 1 11 1 181 1 30 0 1 0 0 0 (-71)
2021-12-20 17:13:55,795 DEBUG RFM2Pi 111225 Timestamp : 1640020435.793473
2021-12-20 17:13:55,796 DEBUG RFM2Pi 111225 From Node : 23
2021-12-20 17:13:55,797 DEBUG RFM2Pi 111225 Values : [23, 59.7, 50.7, 26.700000000000003, 43.7, 3, 1]
2021-12-20 17:13:55,798 DEBUG RFM2Pi 111225 RSSI : -71
2021-12-20 17:13:55,798 DEBUG RFM2Pi 111225 Sent to channel(start)' : ToEmonCMS
2021-12-20 17:13:55,799 DEBUG RFM2Pi 111225 Sent to channel(end)' : ToEmonCMS
2021-12-20 17:13:55,939 DEBUG MQTT Publishing: emon/emonth2A/temperature 23
2021-12-20 17:13:55,941 DEBUG MQTT Publishing: emon/emonth2A/exttemp0 59.7
2021-12-20 17:13:55,943 DEBUG MQTT Publishing: emon/emonth2A/exttemp1 50.7
2021-12-20 17:13:55,944 DEBUG MQTT Publishing: emon/emonth2A/exttemp2 26.700000000000003
2021-12-20 17:13:55,948 DEBUG MQTT Publishing: emon/emonth2A/humidity 43.7
2021-12-20 17:13:55,950 DEBUG MQTT Publishing: emon/emonth2A/battery 3
2021-12-20 17:13:55,953 DEBUG MQTT Publishing: emon/emonth2A/pulsecount 1
2021-12-20 17:13:55,955 DEBUG MQTT Publishing: emon/emonth2A/rssi -71
2021-12-20 17:13:55,956 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:13:55,957 DEBUG MQTT Publishing: emonhub/rx/23/values 23,59.7,50.7,26.700000000000003,43.7,3,1,-71
2021-12-20 17:14:00,530 DEBUG RFM2Pi 111226 NEW FRAME : OK 5 41 0 117 2 158 2 210 95 151 0 0 0 0 0 0 0 0 0 0 0 188 236 23 0 (-0)
2021-12-20 17:14:00,532 DEBUG RFM2Pi 111226 Timestamp : 1640020440.529990
My emonth is a V2, which I have named emonth2A and is at default RFID 23. The boiler feed temperature is reported on MQTT topic emon/emonth2A/exttemp0.
[Point 2 - csv record is 17:13:50, 58.0] The next Node : 23 record is at 17:14:58.204 (ie +68.2 seconds compared to the csv timestamp)
2021-12-20 17:14:55,763 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:14:55,764 DEBUG MQTT Publishing: emonhub/rx/5/values 44.298,603.8009999999999,648.0989999999999,236.48390999999998,15.100000000000001,0,0,0,0,0,1567932
2021-12-20 17:14:58,204 DEBUG RFM2Pi 111238 NEW FRAME : OK 23 230 0 68 2 0 2 12 1 181 1 30 0 1 0 0 0 (-70)
2021-12-20 17:14:58,205 DEBUG RFM2Pi 111238 Timestamp : 1640020498.204504
2021-12-20 17:14:58,206 DEBUG RFM2Pi 111238 From Node : 23
2021-12-20 17:14:58,206 DEBUG RFM2Pi 111238 Values : [23, 58, 51.2, 26.8, 43.7, 3, 1]
2021-12-20 17:14:58,206 DEBUG RFM2Pi 111238 RSSI : -70
2021-12-20 17:14:58,207 DEBUG RFM2Pi 111238 Sent to channel(start)' : ToEmonCMS
2021-12-20 17:14:58,207 DEBUG RFM2Pi 111238 Sent to channel(end)' : ToEmonCMS
2021-12-20 17:14:58,380 DEBUG MQTT Publishing: emon/emonth2A/temperature 23
2021-12-20 17:14:58,380 DEBUG MQTT Publishing: emon/emonth2A/exttemp0 58
2021-12-20 17:14:58,381 DEBUG MQTT Publishing: emon/emonth2A/exttemp1 51.2
2021-12-20 17:14:58,382 DEBUG MQTT Publishing: emon/emonth2A/exttemp2 26.8
2021-12-20 17:14:58,383 DEBUG MQTT Publishing: emon/emonth2A/humidity 43.7
2021-12-20 17:14:58,383 DEBUG MQTT Publishing: emon/emonth2A/battery 3
2021-12-20 17:14:58,384 DEBUG MQTT Publishing: emon/emonth2A/pulsecount 1
2021-12-20 17:14:58,385 DEBUG MQTT Publishing: emon/emonth2A/rssi -70
2021-12-20 17:14:58,386 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:14:58,386 DEBUG MQTT Publishing: emonhub/rx/23/values 23,58,51.2,26.8,43.7,3,1,-70
2021-12-20 17:15:00,543 DEBUG RFM2Pi 111239 NEW FRAME : OK 5 26 0 111 2 137 2 241 95 151 0 0 0 0 0 0 0 0 0 0 0 188 236 23 0 (-0)
2021-12-20 17:15:00,546 DEBUG RFM2Pi 111239 Timestamp : 1640020500.543228
[Point 3 - csv record is 17:14:50, null] There is no Node : 23 message approximately one minute later (ie around 17:16:00), so a null record might be expected.
[Point 4 - csv record is 17:15:50, null] There is no Node : 23 message approximately one minute later (ie around 17:17:00), so a second null record might be expected.
[Point 5 - csv record is 17:16:50, 53.3] The next Node : 23 record is timestamped 12.9 seconds later at 17:17:02.915 and reports exttemp0 as 53.30000000000004.
2021-12-20 17:17:00,673 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:17:00,673 DEBUG MQTT Publishing: emonhub/rx/5/values 19.259999999999998,606.6899999999999,625.9499999999999,236.31056999999998,15.100000000000001,0,0,0,0,0,1567932
2021-12-20 17:17:02,915 DEBUG RFM2Pi 111264 NEW FRAME : OK 23 230 0 21 2 241 1 14 1 181 1 30 0 1 0 0 0 (-69)
2021-12-20 17:17:02,918 DEBUG RFM2Pi 111264 Timestamp : 1640020622.915614
2021-12-20 17:17:02,918 DEBUG RFM2Pi 111264 From Node : 23
2021-12-20 17:17:02,919 DEBUG RFM2Pi 111264 Values : [23, 53.300000000000004, 49.7, 27, 43.7, 3, 1]
2021-12-20 17:17:02,919 DEBUG RFM2Pi 111264 RSSI : -69
2021-12-20 17:17:02,920 DEBUG RFM2Pi 111264 Sent to channel(start)' : ToEmonCMS
2021-12-20 17:17:02,920 DEBUG RFM2Pi 111264 Sent to channel(end)' : ToEmonCMS
2021-12-20 17:17:03,096 DEBUG MQTT Publishing: emon/emonth2A/temperature 23
2021-12-20 17:17:03,098 DEBUG MQTT Publishing: emon/emonth2A/exttemp0 53.300000000000004
2021-12-20 17:17:03,099 DEBUG MQTT Publishing: emon/emonth2A/exttemp1 49.7
2021-12-20 17:17:03,100 DEBUG MQTT Publishing: emon/emonth2A/exttemp2 27
2021-12-20 17:17:03,102 DEBUG MQTT Publishing: emon/emonth2A/humidity 43.7
2021-12-20 17:17:03,103 DEBUG MQTT Publishing: emon/emonth2A/battery 3
2021-12-20 17:17:03,104 DEBUG MQTT Publishing: emon/emonth2A/pulsecount 1
2021-12-20 17:17:03,105 DEBUG MQTT Publishing: emon/emonth2A/rssi -69
2021-12-20 17:17:03,106 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:17:03,107 DEBUG MQTT Publishing: emonhub/rx/23/values 23,53.300000000000004,49.7,27,43.7,3,1,-69
2021-12-20 17:17:05,540 DEBUG RFM2Pi 111265 NEW FRAME : OK 5 20 0 113 2 133 2 205 95 151 0 0 0 0 0 0 0 0 0 0 0 188 236 23 0 (-0)
2021-12-20 17:17:05,543 DEBUG RFM2Pi 111265 Timestamp : 1640020625.540560
[Point 6 - csv record is 17:17:50, null] There is no Node : 23 message approximately one minute later (ie around 17:19:00), so a second null record might be expected.
[Point 7 - csv record is 17:18:50, 50.5] The next Node : 23 record is timestamped 17.9 seconds later at 17:19:07.915 and reports exttemp0 as 50.5.
2021-12-20 17:19:05,650 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:19:05,651 DEBUG MQTT Publishing: emonhub/rx/5/values 16.371,605.727,622.098,236.36835,15.100000000000001,0,0,0,0,0,1567933
2021-12-20 17:19:07,635 DEBUG RFM2Pi 111290 NEW FRAME : OK 23 230 0 249 1 224 1 12 1 178 1 30 0 1 0 0 0 (-70)
2021-12-20 17:19:07,637 DEBUG RFM2Pi 111290 Timestamp : 1640020747.635361
2021-12-20 17:19:07,638 DEBUG RFM2Pi 111290 From Node : 23
2021-12-20 17:19:07,639 DEBUG RFM2Pi 111290 Values : [23, 50.5, 48, 26.8, 43.400000000000006, 3, 1]
2021-12-20 17:19:07,639 DEBUG RFM2Pi 111290 RSSI : -70
2021-12-20 17:19:07,640 DEBUG RFM2Pi 111290 Sent to channel(start)' : ToEmonCMS
2021-12-20 17:19:07,640 DEBUG RFM2Pi 111290 Sent to channel(end)' : ToEmonCMS
2021-12-20 17:19:07,774 DEBUG MQTT Publishing: emon/emonth2A/temperature 23
2021-12-20 17:19:07,775 DEBUG MQTT Publishing: emon/emonth2A/exttemp0 50.5
2021-12-20 17:19:07,776 DEBUG MQTT Publishing: emon/emonth2A/exttemp1 48
2021-12-20 17:19:07,777 DEBUG MQTT Publishing: emon/emonth2A/exttemp2 26.8
2021-12-20 17:19:07,778 DEBUG MQTT Publishing: emon/emonth2A/humidity 43.400000000000006
2021-12-20 17:19:07,779 DEBUG MQTT Publishing: emon/emonth2A/battery 3
2021-12-20 17:19:07,780 DEBUG MQTT Publishing: emon/emonth2A/pulsecount 1
2021-12-20 17:19:07,781 DEBUG MQTT Publishing: emon/emonth2A/rssi -70
2021-12-20 17:19:07,782 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:19:07,783 DEBUG MQTT Publishing: emonhub/rx/23/values 23,50.5,48,26.8,43.400000000000006,3,1,-70
2021-12-20 17:19:10,568 DEBUG RFM2Pi 111291 NEW FRAME : OK 5 38 0 108 2 146 2 129 95 152 0 0 0 0 0 0 0 0 0 0 0 189 236 23 0 (-0)
2021-12-20 17:19:10,571 DEBUG RFM2Pi 111291 Timestamp : 1640020750.568060
So it looks like I am genuinely missing RF packets from emonth2A.
There looks to be a sequence ID for RFM2Pi packets, and the logged packets have the following IDs 111225
111238
111264
111290
The increments between are 13, 26 & 26.
The logged timestamps are
17:13:55.793 (1640020435.793s)
17:14:58.204 (1640020498.204s)
17:17:02.915 (1640020622.915s)
17:19:07.635 (1640020747.635s)
The increments between are 62.411s, 124.711s & 124.720s.
In between the emonth2A packets there appear to be around 12 packets per minute from Node : 5, the emonpi, eg packet IDs 11291 & 11292
2021-12-20 17:19:07,782 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:19:07,783 DEBUG MQTT Publishing: emonhub/rx/23/values 23,50.5,48,26.8,43.400000000000006,3,1,-70
2021-12-20 17:19:10,568 DEBUG RFM2Pi 111291 NEW FRAME : OK 5 38 0 108 2 146 2 129 95 152 0 0 0 0 0 0 0 0 0 0 0 189 236 23 0 (-0)
2021-12-20 17:19:10,571 DEBUG RFM2Pi 111291 Timestamp : 1640020750.568060
2021-12-20 17:19:10,571 DEBUG RFM2Pi 111291 From Node : 5
2021-12-20 17:19:10,572 DEBUG RFM2Pi 111291 Values : [36.594, 597.06, 633.654, 235.44387, 15.200000000000001, 0, 0, 0, 0, 0, 1567933]
2021-12-20 17:19:10,573 DEBUG RFM2Pi 111291 Sent to channel(start)' : ToEmonCMS
2021-12-20 17:19:10,573 DEBUG RFM2Pi 111291 Sent to channel(end)' : ToEmonCMS
2021-12-20 17:19:10,600 DEBUG MQTT Publishing: emon/emonpi/power1 36.594
2021-12-20 17:19:10,602 DEBUG MQTT Publishing: emon/emonpi/power2 597.06
2021-12-20 17:19:10,604 DEBUG MQTT Publishing: emon/emonpi/power1pluspower2 633.654
2021-12-20 17:19:10,605 DEBUG MQTT Publishing: emon/emonpi/vrms 235.44387
2021-12-20 17:19:10,607 DEBUG MQTT Publishing: emon/emonpi/t1 15.200000000000001
2021-12-20 17:19:10,608 DEBUG MQTT Publishing: emon/emonpi/t2 0
2021-12-20 17:19:10,610 DEBUG MQTT Publishing: emon/emonpi/t3 0
2021-12-20 17:19:10,611 DEBUG MQTT Publishing: emon/emonpi/t4 0
2021-12-20 17:19:10,613 DEBUG MQTT Publishing: emon/emonpi/t5 0
2021-12-20 17:19:10,614 DEBUG MQTT Publishing: emon/emonpi/t6 0
2021-12-20 17:19:10,616 DEBUG MQTT Publishing: emon/emonpi/pulsecount 1567933
2021-12-20 17:19:10,617 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:19:10,618 DEBUG MQTT Publishing: emonhub/rx/5/values 36.594,597.06,633.654,235.44387,15.200000000000001,0,0,0,0,0,1567933
2021-12-20 17:19:15,602 DEBUG RFM2Pi 111292 NEW FRAME : OK 5 41 0 103 2 144 2 140 95 151 0 0 0 0 0 0 0 0 0 0 0 189 236 23 0 (-0)
2021-12-20 17:19:15,605 DEBUG RFM2Pi 111292 Timestamp : 1640020755.602012
2021-12-20 17:19:15,605 DEBUG RFM2Pi 111292 From Node : 5
2021-12-20 17:19:15,606 DEBUG RFM2Pi 111292 Values : [39.483, 592.245, 631.728, 235.5498, 15.100000000000001, 0, 0, 0, 0, 0, 1567933]
2021-12-20 17:19:15,606 DEBUG RFM2Pi 111292 Sent to channel(start)' : ToEmonCMS
2021-12-20 17:19:15,607 DEBUG RFM2Pi 111292 Sent to channel(end)' : ToEmonCMS
2021-12-20 17:19:15,769 DEBUG MQTT Publishing: emon/emonpi/power1 39.483
2021-12-20 17:19:15,770 DEBUG MQTT Publishing: emon/emonpi/power2 592.245
2021-12-20 17:19:15,772 DEBUG MQTT Publishing: emon/emonpi/power1pluspower2 631.728
2021-12-20 17:19:15,773 DEBUG MQTT Publishing: emon/emonpi/vrms 235.5498
2021-12-20 17:19:15,774 DEBUG MQTT Publishing: emon/emonpi/t1 15.100000000000001
2021-12-20 17:19:15,775 DEBUG MQTT Publishing: emon/emonpi/t2 0
2021-12-20 17:19:15,776 DEBUG MQTT Publishing: emon/emonpi/t3 0
2021-12-20 17:19:15,777 DEBUG MQTT Publishing: emon/emonpi/t4 0
2021-12-20 17:19:15,778 DEBUG MQTT Publishing: emon/emonpi/t5 0
2021-12-20 17:19:15,779 DEBUG MQTT Publishing: emon/emonpi/t6 0
2021-12-20 17:19:15,780 DEBUG MQTT Publishing: emon/emonpi/pulsecount 1567933
2021-12-20 17:19:15,783 INFO MQTT Publishing 'node' formatted msg
2021-12-20 17:19:15,783 DEBUG MQTT Publishing: emonhub/rx/5/values 39.483,592.245,631.728,235.5498,15.100000000000001,0,0,0,0,0,1567933
2021-12-20 17:19:19,719 DEBUG emoncmsorg Buffer size: 7
2021-12-20 17:19:20,557 DEBUG RFM2Pi 111293 NEW FRAME : OK 5 40 0 100 2 140 2 179 95 151 0 0 0 0 0 0 0 0 0 0 0 189 236 23 0 (-0)
2021-12-20 17:19:20,559 DEBUG RFM2Pi 111293 Timestamp : 1640020760.556909
I donât understand why these are RFM2Pi messages - surely the internal Arduino doesnât talk wirelessly to the host Raspberry Pi when thereâs connectivity available to wire up UART to UART?
And the emonth seems to be on too long a timebase, sending out messages just over a minute apart, rather than just under. Where in the sketch should I look to tweak that? Presumably using more sensors (3 external DS18B20âs plus the Si7031 is pushing some critical timing over a tipping point.
I think I need to look at these
// These variables control the transmit timing of the emonTH
const unsigned long WDT_PERIOD = 80; // mseconds.
const unsigned long WDT_MAX_NUMBER = 690; // Data sent after WDT_MAX_NUMBER periods of WDT_PERIOD ms without pulses:
// 690x 80 = 55.2 seconds (it needs to be about 5s less than the record interval in emoncms)
If I get 62s between records with my hardware config and 690 periods of 80ms, can I just set WDT_MAX_NUMBER to 55 / 62 * 690 = 612 ? What else might I break?
Phew - much learning already under my belt, and more to go. Having more fun now than I was
[Side Notes: My 1890âs solid brick suburban semi enjoys the benefit of a floor standing low tech cast iron lump of a boiler complete with 24/7/365 pilot light, but no go-wrong-after-5-year electronics.
I enjoy reading tales of low flow temperatures in condensing boilers, but do not aspire to being forced into owning such a life-limited device. 10, maybe 15, years seems to be a normal lifespan, compared to the unit here, which was I guess already at least that old when we moved in 25 years ago - and has largely been untouched since.
I have toyed with ASHP, but donât fancy the upheaval of replacing many radiators, nor the difficulty of siting a filing cabinet sized external unit in a noise-suitable Permitted Development location.
Also the current potential for disastrous electricity prices that increase by multiples of the underlying gas price increase has rather put that idea out of my head for the time being.]