Requirements
-------------

* Python 3.8 or later.
* Python Twisted or Tornado (if not using asyncio for async client and server),
remark Twisted and Tornado are in maintenance mode, and might either be dropped or supplied as plugins in the future.

* Pyserial

On Windows pywin32 is recommended (this is built in to ActivePython,
so no need to reinstall if you use it instead of standard Python):

    https://github.com/mhammond/pywin32

The Windows IOCP reactor requires pywin32 build 205 or later.


Installation
-------------

To install the package from pypi, use pip:

    pip install -U pymodbus

Or to install a specific release:

    pip install -U pymodbus==X.Y.Z

As with other Python packages, the standard way of installing from source
is (as root or administrator):

    https://github.com/riptideio/pymodbus.git
    git checkout master
    python setup.py install


Running Tests
--------------

The tests can be run with the built in unittest module, however, it is
much easier to run with the nose package.  With that installed, you can
use either of the following::

    python setup.py test
    pytest


Building Documentation
----------------------

The documentation is written in restructured text using the sphinx module.
Building it is as simple as::

    python setup build_sphinx

The API documents can be generated using one of four programs:

* epydoc
* pydoc
* pydoctor
* doxygen

To build these, simply run the following command and the available
packages will sipmly be built::

    python setup.py build_apidocs


Quality Tests
----------------------

There are a number of quality tests that can be run against the code base
aside from unit tests::

    python setup.py pep8       # run a pop8 standards test
    python setup.py lint       # run a lint test

