UV, Solar and Theoretical Max graph help.

171 views
Skip to first unread message

O S

unread,
Apr 11, 2026, 6:47:48 AMApr 11
to weewx-user
Hello,

I am trying to get the above graph to work using the Belchertown skin. if I use the example from the Wiki:

[[solarRadGraph]]
    title = Solar Radiation and  UV Index
    [[[radiation]]]
       name = Solar Radiation
       zIndex = 1
       color = "#ffc83f"
    [[[maxSolarRad]]]
        name = Theoretical Max Solar Radiation
        type = area
        color = "#f7f2b4"
        yAxis_label = "W/m2"
    [[[UV]]]
        yAxis = 1
        yAxis_min = 0
        yAxis_max = 14
        color = "#90ed7d"
        yAxis_label = "UV"
        name = UV Index
        zIndex = 2

I only get max theoretical and UV index plotted. My weewx outputs show:

uvradaiation
UV

...and I uderstand that maxSolarRad is calculated by weewx itself.

When I save graphs.conf with the above modification, it appears to plot only max theoretical and UV, there is no record of solar radiation.

Any help very much appreciated as usual, I'm running weewx 5.2.

DR

unread,
Apr 11, 2026, 8:56:19 AMApr 11
to weewx...@googlegroups.com
For what little my experience might be worth, I had the same problem (I
have no  UV sensor so I removed that from the listing.)

When I looked at the database, the 'radiation' field were all blank, for
some reason which I've not found an easy fix for, the old station is not
sending the solar value over to WeeWx, and therefore it isn't being
saved as a value.  To test it, in the driver forced a fixed value into
the radiation field and it plots but of course is not the value being
recorded.  My problem is the driver not reading the value for radiation
because the station isn't sending it in the communication string. Yet.


Dale


O S

unread,
Apr 23, 2026, 1:03:35 PM (8 days ago) Apr 23
to weewx...@googlegroups.com
I think i have the wrong value here in graphs.conf. If I run weewxd, these are the outputs I see related to solar (not the in my previous message):

luminosity: 22930.0 
maxSolarRad: 272.3303172138379
UV: 2
uvradiation: 54.0

If I divide luminosity (22930.0) by 126.7, I get: 181, which appears to agree with my ecowitt dashboard value of 181Wm2.

So, should I replace  [[[radiation]]], with  [[[luminosity]]]?

Thank you :)

--
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 weewx-user+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/weewx-user/60c8e4bd-64dc-449c-acb5-29b4658241f0n%40googlegroups.com.

Greg Troxel

unread,
Apr 23, 2026, 1:41:52 PM (8 days ago) Apr 23
to O S, weewx...@googlegroups.com
O S <oliver...@gmail.com> writes:

> I think i have the wrong value here in graphs.conf. If I run weewxd, these
> are the outputs I see related to solar (not the in my previous message):
>
> luminosity: 22930.0
> maxSolarRad: 272.3303172138379
> UV: 2
> uvradiation: 54.0
>
> If I divide luminosity (22930.0) by 126.7, I get: 181, which appears to
> agree with my ecowitt dashboard value of 181Wm2.
>
> So, should I replace [[[radiation]]], with [[[luminosity]]]?

My recommendation would be to understand
- what these measurements mean
- that "luminosity" is a bogus historical term
- that you really cannot convert illuminance to irradiance
- how formulas for maxSolarRad are approximations and that the reality
is "it's more complicated than you think".

There is a weewx wiki page on illuminance/irradiance.


You didn't explain what kind of weather station you have, what ir
really atters, and what the internet's opinion of calibration/accuracy
is.

O S

unread,
Apr 23, 2026, 3:29:59 PM (8 days ago) Apr 23
to weewx-user
Hello Greg,

Thanks for your reply. It all sounds a bit too complicated then so perhaps I won't bother. From what I had read, it was a simple conversion made by weewx to the tune of luminosity/126.7, and that agreed with the ecowitt dashboard, but perhaps that's wrong as well. I mean I know that luminosity is "brightness" and solar radiation is "the strength of the sun"; too basic, perhaps. Luminosity is bogus? OK, a quick search doesn't lead me to a page full of results to support that, but I am sure you're right.

Likewise, the wiki page you mention does not come to me easily. The weather station I have is an Ecowitt WS68 Wireless Solar Anemometer with Light & UV Sensor.

Anyway, like I say, all sounds too complicated until I maybe find and read up everything as you have suggested.

Thanks,
Nick.

R

unread,
Apr 24, 2026, 1:00:50 AM (8 days ago) Apr 24
to weewx-user
If you are using either of the drivers based on the Ecowitt gateway device APIs then the lack of ‘radiation’ is likely due to the APIs (and thus the driver) not directly providing a ‘radiation’ value. Rather, the APIs provide a value in Lux which the APIs refer rather loosely to as ‘Light’. This is what the driver passes on in the ‘luminosity’ or ‘illuminance’ field (depending on the driver). The Ecowitt devices approximate ‘radiation’ by dividing the ‘Light’ value by 126.7. If you want WeeWX to similarly approximate ‘radiation’ you need to have WeeWX, not the driver, perform the calculation. If using the more recent local device HTTP API based driver you do this by adding the following line under the [StdCalibrate] [[Corrections]] stanza in weewx.conf:

        radiation = illuminance/126.7 if illuminance is not None else None

or if using the older telnet based API driver, aka the GW1000 driver, you want something like the following instead:

        radiation = luminosity/126.7 if luminosity is not None else None

I make no comment either way on the accuracy of this approximation nor the correctness of the use of the fields luminosity and illuminance.

R

O S

unread,
Apr 26, 2026, 4:00:18 PM (5 days ago) Apr 26
to weewx-user
Many thanks for this, R.

I have this:
Extension name        Version      Description
GW1000                      0.6.3           WeeWX driver for devices using the Ecowitt LAN/Wi-Fi Gateway API.

So, I added 

        radiation = luminosity/126.7 if luminosity is not None else None

under the [StdCalibrate] [[Corrections]] stanza in weewx.conf.

Do I still need to replace  [[[radiation]]], with  [[[luminosity]]], as per my message above?

Thanks,

Vince Skahan

unread,
Apr 26, 2026, 5:18:30 PM (5 days ago) Apr 26
to weewx-user
What sensors do you have ? What do they natively measure ?

O S

unread,
Apr 26, 2026, 5:52:01 PM (5 days ago) Apr 26
to weewx-user
Hello Vince,

i have a Ecowitt WS68 Wireless Solar Anemometer with Light & UV Sensor.

Thanks.

O S

unread,
Apr 26, 2026, 5:53:15 PM (5 days ago) Apr 26
to weewx-user
... the manual says it measures:

  • UV-Index range: 0 - 15
  • Light range: 0 – 120 kLux

R

unread,
Apr 26, 2026, 6:06:16 PM (5 days ago) Apr 26
to weewx-user
The name within the [[[]]] is the name of the WeeWX field so be plotted, so If you wish to plot ‘radiation’ you need to use [[[radiation]]].

If after a WeeWX restart you still get no ‘radiation’ plot you need to run WeeWX directly (so you can see the loop packets and archive records) so you can confirm ‘radiation’ is being calculated and included in the packets/records.

R

Vince Skahan

unread,
Apr 26, 2026, 7:19:22 PM (5 days ago) Apr 26
to weewx-user
Your sensor measures illuminance (lux) not radiation (W/m2) so I would use illuminance which is in the schema.

You do not have a radiation sensor.  An example of a station that 'does' have one is the WF Tempest which 'also' has an illuminance sensor but it is a far more expensive and different beast.

A quick google search says you cannot directly convert between the two measurements with one stable multiplier.

Greg Troxel

unread,
Apr 26, 2026, 7:45:49 PM (5 days ago) Apr 26
to Vince Skahan, weewx-user
Vince Skahan <vince...@gmail.com> writes:

> Your sensor measures illuminance (lux) not radiation (W/m2) so I would use
> illuminance which is in the schema.
>
> You do not have a radiation sensor. An example of a station that 'does'
> have one is the WF Tempest which 'also' has an illuminance sensor but it is
> a far more expensive and different beast.
>
> A quick google search says you cannot directly convert between the two
> measurements with one stable multiplier.

Indeed, one cannot. There is even vintage ranting about this:

https://github.com/weewx/weewx/wiki/Watts-and-lux

R

unread,
Apr 26, 2026, 8:28:14 PM (5 days ago) Apr 26
to weewx-user
This is all being made way too complicated. No Ecowitt sensor measures solar irradiance, they only measure illuminance in Lux. Any Ecowitt device or API that provides a solar irradiance value is calculating this value from the measured illuminance value. If you have an Ecowitt station and you want to display solar irradiance, or what WeeWX terms 'radiation', you really have two choices; display the Ecowitt approximated value of illuminance/126.7 or display nothing. Of course you could display some other approximation, but I doubt that will be any more 'accurate'.

If using the original GW1000 driver the illuminance value is emitted by the driver in the WeeWX field 'luminosity' (I suspect because of the age of the driver and the confusion at the time over luminosity/illuminance/luminance and the then WeeWX schema). Sure you can map the illuminance value in the 'luminosity' field to a field called 'illuminance', but if the aim is to plot 'radiation' you then need to approximate 'radiation' from 'illuminance' under [StdCalibrate]. Why bother with the added complexity and why not just use the existing 'luminosity' field for the approximation instead.

R

Vince Skahan

unread,
Apr 26, 2026, 8:36:37 PM (5 days ago) Apr 26
to weewx-user
So......

Store the native sensor reading in the field that matches the native sensor. Store any derived values in whichever field matches the derived value.

That about it ?

R

unread,
Apr 26, 2026, 9:18:47 PM (5 days ago) Apr 26
to weewx-user
More or less, the trick is under standing what is emitted by the device/driver, what is calculated/derived all with a good mix of approximation and illuminance/luminosity confusion thrown in. Simple.

And to get back to the OPs question, plotting a field that exists in the database and is being populated.

R

Reply all
Reply to author
Forward
0 new messages