snow data

114 views
Skip to first unread message

Wes Witt

unread,
Jul 5, 2020, 7:25:41 PM7/5/20
to weewx-user
Is there an extension for adding snow data to weewx? i'm considering adding an ultrasonic sensor to my weather station which would provide snow depth data. how have people implemented this before? just add a database field for snowdepth? what about snowrate?

just thinking that i may not need to reinvent the wheel if someone has already done this.

-Wes

rich T

unread,
Jul 5, 2020, 8:12:33 PM7/5/20
to weewx-user
If you are using a Maxbotix sensor : https://github.com/matthewwall/weewx-maxbotix

Graham Eddy

unread,
Jul 5, 2020, 11:16:52 PM7/5/20
to weewx...@googlegroups.com
i have added external river depth sensor (pressure not ultrasonic but same principle) - wrote a data service that inserts its readings into weewx loop records; defined new database column for it to persist.
g-eddy

--
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/eeaa42bd-3ec6-4d32-b310-0125445b450fo%40googlegroups.com.

weather list

unread,
Jul 6, 2020, 8:29:47 PM7/6/20
to weewx...@googlegroups.com
I’d be very interested in the details of your setup for the depth sensor if you’re willing to share.

Graham Eddy

unread,
Jul 7, 2020, 12:36:03 AM7/7/20
to weewx...@googlegroups.com
happy to share. haven’t put in github because (a) i need to learn git; and (b) controller i use is now obsolete (but is a useful example). copy of data service code attached

i have an ‘aquagauge' controller with serial interface to host and wireless connections to up to 8 sensors. i am using just one sensor at present, a pressure sensor secured to river bottom that is connected to a box that converts water column pressure to water depth with wireless transmitter to the controller (in principle much the same as ultrasonic sensor fixed above river measuring distance to water)

it follows the weewx acquisition data service pattern:
  • external port (interface to controller) firewalled on other side of a thread to protect main weewx thread
  • service starts by spawning acquisition thread and then binding a callback from weewx for arriving LOOP packets
  • acquisition thread opens port and loops through reading measurements from port and putting them on a queue
  • callback gets any measurements from queue and writes them into current LOOP packet
i could have jammed the measurements into an existing data_type in LOOP packet (e.g. ‘soilMoist3’) and interpreted that data_type downstream (e.g. soilMoist3 graph has label River Level) but instead i created a new data_type ‘riverLevel’ (i.e. a new database column)

some interesting design considerations:
  • open/read failure on port - robustly retry? when to give up, and what to do then?
  • multiple measurements waiting on queue - take last? average them?
  • sensor measurement range - accurately covers [min,max]?
g-eddy
aqua.py

weather list

unread,
Jul 7, 2020, 10:00:37 AM7/7/20
to weewx...@googlegroups.com
Many thanks, nice work. I’m also interested in the hardware, especially which pressure sensor you’re using and the distances from the river to your WeeWx install and network.

-- 
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.

On 7 Jul 2020, at 10:29 am, weather list <dan.hi...@gmail.com> wrote:

I’d be very interested in the details of your setup for the depth sensor if you’re willing to share.

On 5 Jul, 2020, at 23:16, Graham Eddy <graha...@gmail.com> wrote:

i have added external river depth sensor (pressure not ultrasonic but same principle) - wrote a data service that inserts its readings into weewx loop records; defined new database column for it to persist.
g-eddy

On 6 Jul 2020, at 9:25 am, Wes Witt <wes...@gmail.com> wrote:

Is there an extension for adding snow data to weewx? i'm considering adding an ultrasonic sensor to my weather station which would provide snow depth data. how have people implemented this before? just add a database field for snowdepth? what about snowrate?

just thinking that i may not need to reinvent the wheel if someone has already done this.

-Wes


-- 
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.

weather list

unread,
Jul 7, 2020, 10:02:48 AM7/7/20
to weewx...@googlegroups.com
Is that aquagauge this unit?

On 7 Jul, 2020, at 00:35, Graham Eddy <graha...@gmail.com> wrote:

-- 
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.
On 7 Jul 2020, at 10:29 am, weather list <dan.hi...@gmail.com> wrote:

I’d be very interested in the details of your setup for the depth sensor if you’re willing to share.

On 5 Jul, 2020, at 23:16, Graham Eddy <graha...@gmail.com> wrote:

i have added external river depth sensor (pressure not ultrasonic but same principle) - wrote a data service that inserts its readings into weewx loop records; defined new database column for it to persist.
g-eddy

On 6 Jul 2020, at 9:25 am, Wes Witt <wes...@gmail.com> wrote:

Is there an extension for adding snow data to weewx? i'm considering adding an ultrasonic sensor to my weather station which would provide snow depth data. how have people implemented this before? just add a database field for snowdepth? what about snowrate?

just thinking that i may not need to reinvent the wheel if someone has already done this.

-Wes

-- 
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.

Graham Eddy

unread,
Jul 7, 2020, 10:56:49 AM7/7/20
to weewx-user
yep, that’s the product line. mine is not there - mine is the sensor and data-out part of “Aquagauge Differential Pressure Water Level Sensor with Analog and Serial Output” (product discontinued, i see) and the physical interface (wireless) part of “Aquagauge Water Level Data Logger with Wireless Output”. the latter looks like an offline data logger and i have no idea how it would react to being downloaded every 5 mins for weewx

i also got them (the australian agent) to hook up one of their flow meters to a transmitter box and that worked great, except floaties in the river kept fouling the flow meter. when i worked out how to prevent that, it was (ironically) shorted out by flood water soon after, and when i contacted distributor to replace it discovered the product discontinuance :-(

Wes Witt

unread,
Jul 7, 2020, 11:57:32 AM7/7/20
to weewx-user
thanks, i'm aware of that service, but not really what i'm looking for. it does not provide proper integration into weewx.  it stores the snow depth readings as "range" and not as a snow values.

after further investigation i've found that the default schema (wview_extended) includes fields for snow values (snow, snowBatteryStatus, snowDepth, snowMoisture & snowRate). this contradicts the docs at the weewx-maxbotix github page where it says that you need to extend the schema. i guess the docs at the weewx-maxbotix page are just too old. so it seems like a simple matter to just provide snowDepth values in my loop packets and it should work.  i do not see any calculations for snowrate so i'd have to do that myself.

Wes Witt

unread,
Jul 7, 2020, 12:01:04 PM7/7/20
to weewx-user
why wouldn't you just put the sensor values into the existing snowDepth field that is part of the default schema?
Reply all
Reply to author
Forward
0 new messages