Home - ValleyCommunityWorkspace/weather-station-server GitHub Wiki

So much to do!

Requirements

  • Python 3

Installation for development

These were written for MacOS, but probably work fine on Linux.

  1. Clone the repo:
$ git clone https://github.com/ValleyCommunityWorkspace/weather-station-server.git
$ cd weather-station-server
  1. Create and activate Python virtual environment:
weather-station-server $ python3 -m venv py3-venv
weather-station-server $ source py3-venv/bin/activate
  1. Update pip and install requirements:
(py3-venv) weather-station-server $ pip install --upgrade pip
(py3-venv) weather-station-server $ pip install -r requirements.txt
  1. Assuming this will not be used in a production context, create a link to use the development settings:
(py3-venv) weather-station-server $ ln weatherstation/weatherstation/settings-dev.py weatherstation/weatherstation/settings.py
  1. Initialise a local (SQLite) database.
(py3-venv) weather-station-server $ cd weatherstation
(py3-venv) weatherstation $ python manage.py migrate
  1. Start a local server.
(py3-venv) weatherstation $ python manage.py runserver

Workflows

sequence diagram source used at websequencediagrams to make these

Setup

High-ish level overview of setting up a weather station:

UML Sequence Diagram for setting up a weather station

Station RTC sync

Diagram of Weather Station uploading weather data and correcting its RTC

Data upload TODO

Account management