I tried changing $current.co2 to $last.co2 but it only printed "$last.co2" 
on the web page.

Adding the  [Accumulator] section to weewx.conf only caused an error and 
exit when I restarted weewx. I tried adding this in several places but none 
seems to let weewx restart without an exit error.  Is there a special place 
to add this? Couldn't find anything in the doc about placement.  Thanks

On Saturday, December 4, 2021 at 8:55:25 AM UTC-5 [email protected] wrote:

> If Vince's suggestion does not help, try adding the following to your 
> weewx.conf:
>
> [Accumulator]
>     [[co2]]
>         accumulator = firstlast
>         extractor = last
>
> On Friday, December 3, 2021 at 6:24:46 PM UTC-5 vince wrote:
>
>> See if $last rather than $current helps (untested)
>>
>> On Friday, December 3, 2021 at 2:53:22 PM UTC-8 [email protected] wrote:
>>
>>> Hello,
>>> With lots of good help from the group, I have my Seeed CO2 monitor 
>>> (LoRa) sending data to my weewx.sdb archive. I have weewx 4.5.1 (setup.py) 
>>> on Focus Ubuntu.
>>>
>>> The sensor sends data only every 60 minutes and my archive update is 
>>> every15 minutes.
>>> Looking at weewx.sdb, I have a reading recorded every hour but a null 
>>> every 15 minutes when there is no new data.
>>>
>>> co2 column
>>> 417.0
>>> null
>>> null
>>> null
>>> 390.0
>>> null
>>> null
>>> null
>>> 394.0
>>>
>>> My settings in (Standard) index.html.tmpl are:
>>> Current Conditions
>>>       <td class="stats_label">CO2 level</td>
>>>       <td class="stats_data">$current.co2</td>
>>> Sometimes I get a data reading and others just "N/A"
>>>
>>> My settings in weewx.conf:
>>> [MQTTSubscribeService]
>>>     # Turn the service on and off.
>>>     enable = true    
>>>     binding = loop
>>>  [[[mytopic]]]
>>>     ignore = true
>>>  [[[[CO2_Value_PPM]]]]
>>>      name = co2
>>>      ignore = false
>>>      contains total = false
>>>      conversion type = float
>>>
>>> Since everything seems to be working, the "$current.co2" may not be the 
>>> correct form to use here as the display needs to retain the last value 
>>> until it's replaced with a new reading coming every 60 minutes from the 
>>> sensor.
>>>
>>> Much appreciated if someone could point out my mistake in configuration 
>>> here.
>>> The display can be seen at: http://grattans.org/wx
>>>
>>> Cheers,
>>> Bob
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/52d60026-86b0-4fd8-bd10-8b5ffbd355aen%40googlegroups.com.

Reply via email to