weewx station registry
31jan2013 mwall

this is a quick hack to enable weewx stations to phone home so they can be
plotted on a google map.  stations phone home periodically with their url,
location, lat/lon, and station type.  these data are plotted on a map.  if
a station does not phone home after a certain period of time it will be
removed from the map.

register.cgi - runs on the web server, accepts connections from stations

register.py - weewx extension that enables a station to register

mksites.pl - generate the html page by injecting station data into template

stations.html.in - template html page


to configure the server:

apt-get install libdbd-sqlite3-perl
cp register.cgi /var/lib/cgi-bin
mkdir /var/lib/weewx
chown www-data /var/lib/weewx
crontab -u www-data crontab.reg


to enable this in weewx, copy register.py to bin/weewx then add the following
to the weewx.conf file:

[StdRESTful]
  [[StationRegistry]]
    description = My Little Weather Station
    station_url = http://example.com/weather/
    driver = weewx.register.StationRegistry
