Weewx to generate a customized text file every archival period?

79 views
Skip to first unread message

Chotechai Piyavongsiri

unread,
Aug 26, 2020, 4:42:58 AM8/26/20
to weewx-user
I've been running Weewx 4.x with Belchertown skin for quite some time.

I intend to use Weewx, if possible, to generate a text file containing one row of summary data from weewx database. The output file will be replaced every archival period, e.g. every 5 minute:
Sample data (1 row):
1005,2 00:02 1009,9 23:31 1009,5 02:38 1010,8 08:14 316.8,4.3,83.5,0.0,82.8,12.6,795.2,22.7,2132.6,182.9,2091.2,93.6,1901.9,60.5,1058.8,50.8 20

Values description:
Pressure max/min: yesterday and today, each value separated by one space:
yesterday lowest pressure value: 9999.9
yesterday lowest pressure time: hh:mm
yesterday highest pressure value: 9999.9
yesterday lowest pressure time: hh:mm
today lowest pressure value: 9999.9
today lowest pressure time: hh:mm
today highest pressure value: 9999.9
today lowest pressure time: hh:mm
Wind: direction, each value separated by comma (frequency of 16 wind directions in the last 24 hours
Each wind direction encompass 22.5 degrees (360 degree / 16 = 22.5 degree)
North (N) frequency  (wind direction value between 348.75-11.25 degree)
NNE frequency (wind direction value between 11.25-33.75 degree)
NE frequency (wind direction value between 33.75-56.25 degree)
ENE frequency.....
E frequency.....
ESE frequency....
SE frequency....
SSE frequency....
S frequency....
SSW....
SW....
WSW...
W....
WNW....
NW....
NNW....(wind direction value between 326.25 to 348.75)

Can it be done by creating Weewx template; or I have to write some kind of coding to achieve it?

Thank you


Tom Keffer

unread,
Aug 26, 2020, 8:50:00 AM8/26/20
to weewx-user
The pressure values and times are easy. Something like $yesteray.barometer.min $yesterday.barometer.mintime, etc.

The histogram of wind directions does not exist. You'd have to write a search list extension to do that. 

-tk

--
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/256759ee-e5d2-43cc-968b-b6167c3e375bn%40googlegroups.com.

Chotechai Piyavongsiri

unread,
Aug 30, 2020, 12:03:26 AM8/30/20
to weewx-user
Thanks.
Reply all
Reply to author
Forward
0 new messages