This is working for me. I have a test database setup to capture Lightning
strikes. I also have the ability to send adhoc strikes for testing.
Here we can see my tests are being saved:
Mar 5 16:14:08 serverlab weewx[12374] INFO weewx.manager: Added record 2020
-03-05 16:14:08 EST (1583442848) to database 'lightning.sdb'
Mar 5 16:14:08 serverlab weewx[12374] INFO weewx.manager: Added record 2020
-03-05 16:14:08 EST (1583442848) to daily summary in 'lightning.sdb'
Then using this graphs.conf config:
[[lightning_binding_test]]
title = Lightning Binding
data_binding = lightning_binding
yAxisLabel = ""
time_length = year
xAxis_groupby = day
[[[distance_km]]]
name = Lightning Distance KM
type = column
yAxisLabel = Lightning Count
[[[distance_mi]]]
name = Lightning Distance (mi)
type = column
I get these results which are from my tests (image attached).
Notice how my data_binding is below the 2 square bracket section. Then the
3 square bracket observations match the column name within that custom
database.
On Thursday, March 5, 2020 at 2:48:41 PM UTC-5, weather list wrote:
>
> Doesn't seem to work in that format, or as:
>
> [[chart6]]
> title = Water level
> [[[leafTemp2]]]
> $data_binding='sdr_binding'
> yAxis_tickInterval = 6
> name = Water level
>
> The contents of leafTemp2 are in the form: 62.9921259843
>
> Perhaps all those decimal places cause issues? I am unsure how to
> eliminate them.
>
> The sensor map is thus:
>
> [SDR]
> # This section is for the software-defined radio driver.
>
> # The driver to use
> driver = user.sdr
> log_unknown_sensors = False
> log_unmapped_sensors = False
> [[sensor_map]]
> leafTemp2 = depth.*.TSFT002Packet # height in cm
>
> The logs show no errors.
>
> Console output of sir.conf:
>
> REC: 2020-03-05 14:40:00 EST (1583437200) dateTime: 1583437200.0, ET:
> None, extraTemp2: 82.74, interval: 5, leafTemp2: 62.9921259843,
> maxSolarRad: 750.99796387, rainRate: 0.0, usUnits: 1
>
> LOOP: 2020-03-05 14:44:57 EST (1583437497) dateTime: 1583437497,
> leafTemp2: 62.9921259843, maxSolarRad: 731.5138454, rainRate: 0, usUnits: 1
>
> On Wednesday, March 4, 2020 at 8:12:02 AM UTC-5, Pat wrote:
>>
>> Yes, this should be supported. It's similar to the ImageGenerator
>> settings... try this
>>
>> [[chart6]]
>> title = Water level
>> [[[leafTemp2]]]
>> data_binding = sdr_binding
>> yAxis_tickInterval = 6
>> name = Water level
>>
>>
>>
>> On Tuesday, March 3, 2020 at 8:27:28 AM UTC-5, Dan'l B wrote:
>>>
>>> Following the excellent instructions I’ve managed to add a new chart but
>>> cannot work out how to get the data I need into it.
>>>
>>> The value in question is from an SDR device mapped to leafTemp2 (I’m
>>> running two instances of weewx: weewx.conf and sir.conf), so I usually use
>>> it as ‘$latest($data_binding='sdr_binding').leafTemp2’, for example.
>>>
>>> In my new chart, that doesn’t appear to work:
>>>
>>> [[chart6]]
>>> title = Water level
>>> [[[($data_binding='sdr_binding').leafTemp2]]]
>>> yAxis_tickInterval = 6
>>> name = Water level
>>>
>>> How do I retrieve that value for the chart?
>>
>>
--
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/2059b8f5-1d3e-44a5-9145-648312e33bff%40googlegroups.com.