Small tool to send AIS-Catcher JSON output to an ERDDAP service #184
cricalix
started this conversation in
Show and tell
Replies: 1 comment
-
That is a cool application! Thanks for sharing. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Allo folks.
First off, thank you Jasper for creating AIS-catcher; I've been poking it a bit to work out if it will let me solve a problem, and it will :)
Some context on the problem I'm solving before I do the show-and-tell bit:
The organisation responsible for lighthouses and other aids to navigation in Ireland is Irish Lights. For many years, they piped the AIS type 8/dac 200/fid 31 (meteorology and hydrology data) every 20 minutes or so to Twitter for stations like the Kish Lighthouse. Sailors in Dublin Bay relied on this data to get an idea of what was going on in the bay - some of them live an hour or more away, and it's nice to know what the wind is like before setting out.
With Twitter's changes (I'm not calling it by its new name) to their APIs, the tweets have stopped. It turns out Irish Lights run a scientific data server, but only post hourly averaged data to it, and it's usually several hours late. The sailing club I'm a member of (and IT person for) has an IP camera that looks out over Dublin Bay, and it has a weather feed along the bottom - it's not great when that feed is several hours old! (https://slipcam.dmyc.ie)
I've wanted to learn Rust for a few months now, and decided to tackle a program that can listen on an HTTP port, receive the JSON POST from AIS-catcher, run the field names through a filter (lat/lon have to be called latitude/longitude for instance), and then make an HTTP GET to the scientific data server to write the data. Yes, HTTP GET to write data is silly, but that's what ERDDAP accepts, so I've got to work with it. I can then read back from the ERDDAP server (I already do this for the tide data on that IP camera image), and have a weather readout that's only a few minutes old (the buoy and lighthouse in the bay broadcast every few minutes).
I intend to package up a Raspberry Pi with an RTL-SDR antenna and a 10 inch display, and run the catcher and feeder software on it. It'll be mounted somewhere in the clubhouse, so members can look at the map view, and perhaps I'll be able to get Firefox to rotate tabs so that it flips between the map view and a gauges view of the weather data.
My repo for this project is https://github.com/cricalix/erddap-feeder - it's still a work in progress, and I need to add a bit more documentation about getting an ERDDAP server running and configured. I'm also not sure about the config file design at the moment, and things might get rearranged.
So, if you're interested in long-term storage of meteorological data, you might want to look at ERDDAP and my program :) Theoretically, you could configure an ERDDAP table to hold other data from AIS broadcasts, such as vessel information.
Some sample data in ERDDAP:

Beta Was this translation helpful? Give feedback.
All reactions