/weewx-polarwindplot

A weewx extension to generate a polar wind plots

Primary LanguagePythonGNU General Public License v3.0GPL-3.0

Polar Wind Plot Image Generator Extension

Description

The Polar Wind Plot Image Generator extension is a WeeWX extension that generates polar plots of wind related observations from WeeWX archive data. The polar plots are generated as image files suitable for publishing on a web page, inclusion in a WeeWX template or for use elsewhere.

The extension consists of a single WeeWX skin that controls a custom image generator. Various parameters including the plot type, period, source data field, units of measure and colours are available to allow customisation of the generated output.

Pre-requisites

The Polar Wind Plot Image Generator extension requires WeeWX v3.2.0 or greater and will operate under Python 2 or Python 3.

Installation Instructions

Note: Symbolic names are used below to refer to file locations on the WeeWX system. Symbolic names allow a common name to be used to refer to a directory that may be different from system to system. The following symbolic name is used below:

  • HTML_ROOT. The path to the directory where WeeWX generated reports and images are located. This directory varies depending on WeeWX installation method and system or web server configuration and may be set or overridden in the [StdReport] section of weewx.conf. Refer to where to find things in the WeeWX User's Guide for further information.

To install the Polar Wind Plot Image Generator extension:

  1. Download the latest Polar Wind Plot Image Generator extension from the Polar Wind Plot Image Generator extension releases page into a directory accessible from the WeeWX machine.

     $ wget -P /var/tmp https://github.com/gjr80/weewx-polarwindplot/releases/download/v0.1.0/polarwindplot-0.1.0.tar.gz
    
  2. Install the Polar Wind Plot Image Generator extension:

     $ wee_extension --install=/var/tmp/polarwindplot-0.1.0.tar.gz
    

    Note: Depending on your system/installation the above command may need to be prefixed with sudo.

    Note: Depending on your WeeWX installation wee_extension may need to be prefixed with the path to wee_extension.

    This will result in output similar to the following:

     Request to install '/var/tmp/polarwindplot-0.1.0.tar.gz'
     Extracting from tar archive /var/tmp/polarwindplot-0.1.0.tar.gz
     Saving installer file to /home/weewx/bin/user/installer/PolarWindplot
     Saved configuration dictionary. Backup copy at /home/weewx/weewx.conf.20220101124410
     Finished installing extension '/var/tmp/polarwindplot-0.1.0.tar.gz'
    
  3. Modify an existing skin to use the Polar Wind Plot Image Generator or install the Polar Wind Plot Image Generator Demonstration skin.

  4. Restart WeeWX:

     $ sudo /etc/init.d/weewx restart
    

    or

     $ sudo service weewx restart
    

    or

     $ sudo systemctl restart weewx
    

If an existing skin was modified to use the Polar Wind Plot Image Generator this will result in the existing skin generating one or more polar wind plots using the Polar Wind Plot Image Generator. If the Polar Wind Plot Image Generator Demonstration skin was installed the Polar Wind Plot Image Generator Demonstration skin will generate a simple html page, polarplots.html, that displays examples of each of the four polar plots types that can be generated by the Polar Wind Plot Image Generator extension. If the WeeWX machine also includes a web server the example page can be viewed in a browser at http://address/weewx/polarwindplot/polarplots.html where address is the IP address or URL of the WeeWX machine. If no web server is available the individual polar plot files; dayrose.png, dayscatter.png, dayspiral.png and daytrail.png may be found in the HTML_ROOT/polarwindplot directory.

Note: The PolarWindPlotDemo skin can be used as the basis for a new skin if the Polar Wind Plot Image Generator is to be used in a production environment. In such cases the PolarWindPlotDemo skin should be copied and renamed as future updates of the Polar Wind Plot Image Generator extension may overwrite the PolarWindPlotDemo skin.

Support

General support issues may be raised in the Google Groups weewx-user forum. Specific bugs in the Polar Wind Plot Image Generator extension code should be the subject of a new issue raised via the Issues Page.

Licensing

The Polar Wind Plot Image Generator extension is licensed under the GNU Public License v3.