Skip to content

Commit

Permalink
Updated documentation
Browse files Browse the repository at this point in the history
Signed-off-by: Jim Easterbrook <jim@jim-easterbrook.me.uk>
  • Loading branch information
jim-easterbrook committed Sep 12, 2018
1 parent a47726b commit bbcc543
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 15 deletions.
11 changes: 5 additions & 6 deletions src/doc/guides/hourlylogging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ These specify what :py:mod:`pywws.hourly` should do when it is run.
Tasks in the ``[live]`` and ``[logged]`` sections are done when there is new logged data, tasks in the ``[hourly]`` section are done every hour, tasks in the ``[12 hourly]`` section are done twice daily and tasks in the ``[daily]`` section are done once per day.

The ``plot`` and ``text`` entries are lists of template files for plots and text files to be processed.
The ``services`` entry is a list of online weather services to upload data and files to.
The ``services`` entry is a list of online weather services to upload data and files to, e.g. ``'underground'`` or ``('ftp', '24hrs.txt')``.
Add the names of your template files and weather services to the appropriate entries, for example::

[logged]
Expand All @@ -98,9 +98,9 @@ Add the names of your template files and weather services to the appropriate ent
text = []

[hourly]
services = [('twitter', 'tweet.txt'), ('ftp', '7days.png'),
('ftp', '24hrs.png'), ('ftp', 'rose_24hrs.png'),
('ftp', '24hrs.txt'), ('ftp', '6hrs.txt'), ('ftp', '7days.txt')]
services = [('twitter', 'tweet.txt'),
('ftp', '7days.png', '24hrs.png', 'rose_24hrs.png',
'24hrs.txt', '6hrs.txt', '7days.txt')]
plot = ['7days.png.xml', '24hrs.png.xml', 'rose_24hrs.png.xml']
text = ['tweet.txt', '24hrs.txt', '6hrs.txt', '7days.txt']

Expand All @@ -110,8 +110,7 @@ Add the names of your template files and weather services to the appropriate ent
text = []

[daily]
services = [('twitter', 'forecast.txt'), ('ftp', '28days.png'),
('ftp', 'allmonths.txt')]
services = [('twitter', 'forecast.txt'), ('ftp', '28days.png', 'allmonths.txt')]
plot = ['28days.png.xml']
text = ['forecast.txt', 'allmonths.txt']

Expand Down
6 changes: 5 additions & 1 deletion src/doc/guides/integration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ How to integrate pywws with various weather services
====================================================

This guide gives brief instructions on how to use pywws with some other weather services and software.
It is not comprehensive, and most services (such as Twitter) are covered in more detail elsewhere.
It is not comprehensive, and most services are covered in more detail elsewhere.

YoWindow
--------
Expand Down Expand Up @@ -101,6 +101,10 @@ The service uploaders are all used in a similar fashion:

[live]
services = ['underground']

Note that some services, such as :py:mod:`pywws.service.copy`, need one or more parameters.
Instead of a single word entry, such as ``underground``, these use a bracketed list, for example ``('copy', 'yowindow.xml')``.

#. Restart pywws live logging.

Some of the services are more complicated to configure.
Expand Down
11 changes: 5 additions & 6 deletions src/doc/guides/livelogging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ In weather.ini you should have a ``[live]`` section similar to the following::
plot = []

This section specifies what pywws should do every time it gets a new reading from the weather station, i.e. every 48 seconds.
The ``services`` entry is a list of online weather services to upload data to, e.g. ``['underground']``.
The ``services`` entry is a list of online weather services to upload data to, e.g. ``'underground'`` or ``('ftp', '24hrs.txt')``.
The ``plot`` and ``text`` entries are lists of template files for plots and text files to be processed.
You should probably leave all of these blank except for ``services``.

Expand All @@ -104,9 +104,9 @@ Add the names of your template files to the appropriate entries, for example::
text = []

[hourly]
services = [('twitter', 'tweet.txt'), ('ftp', '7days.png'),
('ftp', '24hrs.png'), ('ftp', 'rose_24hrs.png'),
('ftp', '24hrs.txt'), ('ftp', '6hrs.txt'), ('ftp', '7days.txt')]
services = [('twitter', 'tweet.txt'),
('ftp', '7days.png', '24hrs.png', 'rose_24hrs.png',
'24hrs.txt', '6hrs.txt', '7days.txt')]
plot = ['7days.png.xml', '24hrs.png.xml', 'rose_24hrs.png.xml']
text = ['tweet.txt', '24hrs.txt', '6hrs.txt', '7days.txt']

Expand All @@ -116,8 +116,7 @@ Add the names of your template files to the appropriate entries, for example::
text = []

[daily]
services = [('twitter', 'forecast.txt'), ('ftp', '28days.png'),
('ftp', 'allmonths.txt')]
services = [('twitter', 'forecast.txt'), ('ftp', '28days.png', 'allmonths.txt')]
plot = ['28days.png.xml']
text = ['forecast.txt', 'allmonths.txt']

Expand Down
5 changes: 5 additions & 0 deletions src/doc/guides/weather_ini.rst
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ live: tasks to be done every 48 seconds
This section specifies tasks that are to be carried out for every data sample during 'live logging', i.e. every 48 seconds.

``services`` is a list of 'services' to upload data to.
Some are just a single word, others have one or more parameters and need to be enclosed in brackets.
Each one listed must have a module in ``pywws.service`` or your modules directory.
See :ref:`integration - other services<guides-integration-other>` for more detail.
pywws will automatically limit the frequency of service uploads according to each service's requirements.
Expand All @@ -152,6 +153,7 @@ logged: tasks to be done every time the station logs a data record
This section specifies tasks that are to be carried out every time a data record is logged when 'live logging' or every time an hourly cron job is run.

``services`` is a list of 'services' to upload data to.
Some are just a single word, others have one or more parameters and need to be enclosed in brackets.
Each one listed must have a module in ``pywws.service`` or your modules directory.
See :ref:`integration - other services<guides-integration-other>` for more detail.

Expand Down Expand Up @@ -209,6 +211,7 @@ hourly: tasks to be done every hour
This section specifies tasks that are to be carried out every hour when 'live logging' or running an hourly cron job.

``services`` is a list of 'services' to upload data to.
Some are just a single word, others have one or more parameters and need to be enclosed in brackets.
Each one listed must have a module in ``pywws.service`` or your modules directory.
See :ref:`integration - other services<guides-integration-other>` for more detail.

Expand All @@ -227,6 +230,7 @@ This section specifies tasks that are to be carried out every 12 hours when 'liv
The tasks are done at your day end hour, and 12 hours later.

``services`` is a list of 'services' to upload data to.
Some are just a single word, others have one or more parameters and need to be enclosed in brackets.
Each one listed must have a module in ``pywws.service`` or your modules directory.
See :ref:`integration - other services<guides-integration-other>` for more detail.

Expand All @@ -245,6 +249,7 @@ This section specifies tasks that are to be carried out every day when 'live log
The tasks are done at your day end hour.

``services`` is a list of 'services' to upload data to.
Some are just a single word, others have one or more parameters and need to be enclosed in brackets.
Each one listed must have a module in ``pywws.service`` or your modules directory.
See :ref:`integration - other services<guides-integration-other>` for more detail.

Expand Down
4 changes: 2 additions & 2 deletions src/pywws/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
__version__ = '18.9.0'
_release = '1632'
_commit = 'ad0d264'
_release = '1633'
_commit = 'a47726b'

0 comments on commit bbcc543

Please sign in to comment.