The 'rain' observation value passed in the loop packet is the amount of 
rain accumulated by the sensor since the last loop report.
Sensor: accumulated rain since last loop report) ---> Database: field 'rain'

The 'signal3' observation value passed in the loop packet is the amount of 
rain accumulated by the sensor since midnight (the 'midnight' of the data 
logger).
Sensor: accumulated rain since midnight ---> Database: field 'signal3'

Rain Rate is calculated in software: 
weewx.conf|[StdWXCalculate]|[[Calculations]]|rainRate = software

So on the Seasons report, Current conditions:

Rain Today: 0.0mm
Rain Rate: 0.0 mm/hr

There is a single record in the Database (due to testing and clearing after 
each test).  The fields have:

rain: 0.0
rainRate: 0.0
signal3: 17.87

This is because it was not raining during the testing period, but was 
raining early this morning.  That is why 0 for both rain and rainRate.  But 
signal3 has a value of 17.87 mm, the daily rain accumulated since 
midnight.  So on the seasons report it should look like this:

Rain Today: 17.87 mm
Rain Rate: 0.0 mm/hr

Reading through the documentation I saw several references to the term 
'dayRain'.  So I assumed that was either a constant in weewx or a database 
field, whether hardware or software derived.  I could not find 'dayRain' in 
the database so I posted this query to make sure.  My question then is do I 
make one change to weewx.conf so that all reports will use signal3 as the 
daily rain amount, or do I need to go to each report and change them 
individually.

"Just use $current.signal3"
Do I put this in the weewx.conf file or in the Season skin.conf file?


Craig








On Saturday, September 30, 2023 at 1:57:19 PM UTC+13 gjr80 wrote:

> Given a number of previous threads by the OP related to writing a driver, 
> this could be a report issue or a driver issue. Tom covered off the report 
> issue, but if it is a driver issue then it could be a case of garbage in = 
> garbage out. Your driver should be emitting loop packets and the rain 
> field in each loop packet must be the rainfall seen by the station since 
> the last loop packet. Provided you do this WeeWX will accumulate these loop 
> packet rain values and emit the total rain for the archive period in an 
> archive packet. This is the data you will see stored in the database 
> (appropriately converted given the loop packet unit system and database 
> unit system). Once you know your incoming data is good then I would be 
> worrying about what is appearing in reports.
>
> One other thing, if comparing WeeWX 'day rainfall' to a station provided 
> equivalent remember that WeeWX calculates the 'day rainfall' value from the 
> rain data it has seen on that day, so if you start WeeWX part way through 
> the day and there was rainfall earlier in the day then the WeeWX calculated 
> total will almost certainly be less than the station provided day rainfall 
> value.
>
> Gary
>
> On Saturday, 30 September 2023 at 10:28:27 UTC+10 tke...@gmail.com wrote:
>
>> I don't know exactly what you mean when you say your rain is the "amount 
>> since last report." The field "rain" should be the amount of rain that fell 
>> during the archive period, so perhaps that's what you're already doing.
>>
>> You say, "... the Season report shows the correct rain, as reported by 
>> the station, but sets Rain Today the same as rain." 
>>
>> I'm not sure what you mean by that. The "Rain Today" is the *sum* of 
>> rain since midnight, not the rain during the current archive period. If 
>> what you mean is that it's not the same as what is being emitted by your 
>> hardware as "signal3" (aka "dayRain"), it should be. If not, there's 
>> something wrong in the calculation that derives the field "rain" from 
>> "signal3".
>>
>> Nevertheless, if you want to display exactly what is being emitted by 
>> your hardware, that's simple enough. Just use $current.signal3. But, be 
>> sure your hardware is emitting what you think it's emitting. Is it "rain 
>> since midnight"? Or, "rain over the last 24 hours"? 
>>
>> Final comment: to avoid confusing yourself, why not just use the field 
>> name "dayRain" instead of "signal3"? I know it's not in the database, but 
>> new fields are super easy to add:
>>
>> wee_database --add-column=dayRain
>>
>>
>> -tk
>>
>> On Fri, Sep 29, 2023 at 4:38 PM Craig Young <craig.y...@gmail.com> wrote:
>>
>>> My station (hardware) sends both rain (amount since last report) and 
>>> daily rain (accumulates rain).  Currently I am mapping rain to rain in the 
>>> database and daily rain to signal3 in the database because I could not find 
>>> any 'dayRain' field.  When I run weewx the Season report shows the correct 
>>> rain, as reported by the station, but sets Rain Today the same as rain.
>>> If I want the Seasons report to show the correct daily rain (from the 
>>> hardware) where should I place it in the DB and do I need to change 
>>> weewx.conf or skin.conf to use the value?
>>>
>>> Craig
>>>
>>> -- 
>>> 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 on the web visit 
>>> https://groups.google.com/d/msgid/weewx-user/05844ab4-75a0-435a-a2dd-d85a5ec95d02n%40googlegroups.com
>>>  
>>> <https://groups.google.com/d/msgid/weewx-user/05844ab4-75a0-435a-a2dd-d85a5ec95d02n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/dded09bf-fda0-4542-aa4e-69ce1172ddffn%40googlegroups.com.

Reply via email to