Skip to content

Commit

Permalink
update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
gavinying committed Sep 19, 2021
1 parent bf7c9d8 commit cfcca64
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 10 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ This program is tested on python 3.6+.
- Connect to Modbus TCP device and publish data to MQTT broker

```bash
modpoll --tcp modsim.topmaker.net --config examples/modsim.csv --mqtt-host iot.eclipse.org
modpoll --tcp modsim.topmaker.net --config examples/modsim.csv --mqtt-host iot.topmaker.net

```

Expand Down
15 changes: 10 additions & 5 deletions docs/example.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Examples
========

Commandline Examples
---------------------
Commandline
------------

- Connect to Modbus TCP device

Expand All @@ -21,7 +21,7 @@ Commandline Examples

.. code-block:: shell
modpoll --tcp modsim.topmaker.net --config examples/modsim.csv --mqtt-host iot.eclipse.org
modpoll --tcp modsim.topmaker.net --config examples/modsim.csv --mqtt-host iot.topmaker.net
- Connect to Modbus TCP device and export data to local csv file
Expand All @@ -31,6 +31,9 @@ Commandline Examples
modpoll --tcp modsim.topmaker.net --config examples/modsim.csv --export data.csv
Run in docker
--------------

- Check app version (in docker)

.. code-block:: shell
Expand All @@ -40,6 +43,8 @@ Commandline Examples
- Connect to our online Modbus TCP device simulator (in docker)

To load the modbus register configure file, user may need to mount the volume to container, for example, if the child folder `examples` contains the config file `modsim.csv`, we can mount it using the following command,

.. code-block:: shell
docker run -v $(pwd)/examples:/app/examples helloysd/modpoll modpoll --tcp modsim.topmaker.net --config /app/examples/modsim.csv
Expand All @@ -59,7 +64,7 @@ Here is the basic structure of modbus configure file.
:linenos:


Configuration Example 1: Online Modbus Device Simulator (Modbus TCP)
Example 1: Online Modbus Device Simulator (Modbus TCP)
--------------------------------------------------------

This online Modbus TCP device simulator is designed for user to quickly test our modpoll functions.
Expand All @@ -71,7 +76,7 @@ Here is an example of modbus configure file for modsim.
:linenos:


Configuration Example 2: SCPM-S6 Power Meter (Modbus RTU)
Example 2: SCPM-S6 Power Meter (Modbus RTU)
---------------------------------------------

SCPM-S6 is designed as a sub-circuit power meter to monitor multiple electrical circuit power consumptions.
Expand Down
8 changes: 4 additions & 4 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit cfcca64

Please sign in to comment.