Skip to content

Commit 4340d35

Browse files
update Docker compose usage section for new RTU compose file, relates to #47
1 parent 18023c0 commit 4340d35

File tree

1 file changed

+20
-7
lines changed

1 file changed

+20
-7
lines changed

docs/USAGE.md

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -843,14 +843,21 @@ failed.
843843

844844
#### Docker compose
845845

846-
The following command uses the setup defined in the `docker-compose.yaml` file
847-
to act as two MicroPython devices communicating via TCP. The container
848-
`micropython-host` defined by `Dockerfile.host` acts as host and sets/gets
849-
data at/from the client as defined by `tcp_host_example.py`. On the other hand
850-
the container `micropython-client` defined by `Dockerfile.client` acts as
851-
client and provides data for the host as defined by `tcp_client_example.py`.
846+
The following command uses the setup defined in the individual
847+
`docker-compose-*-test.yaml` file to act as two MicroPython devices
848+
communicating via TCP or RTU. The container `micropython-host-*` defined by
849+
`Dockerfile.host_*` acts as host and sets/gets data at/from the client as
850+
defined by `*_host_example.py`. On the other hand the container
851+
`micropython-client-*` defined by `Dockerfile.client_*` acts as client and
852+
provides data for the host as defined by `*_client_example.py`.
853+
852854
The port defined in `tcp_host_example.py` and `tcp_client_example.py` has to
853-
be open and optionally exposed in the `docker-compose.yaml` file.
855+
be open and optionally exposed in the `docker-compose-tcp-example.yaml` file.
856+
857+
As the [MicroPython containers](https://hub.docker.com/r/micropython/unix/tags)
858+
does not have a UART interface with is additionally not connectable via two
859+
containers a UART fake has been implemented. It is using a socket connection
860+
to exchange all the data.
854861

855862
```bash
856863
docker compose up --build --exit-code-from micropython-host
@@ -865,6 +872,12 @@ the containers. All "dynamic" data is shared via `volumes`
865872
docker compose -f docker-compose-tcp-test.yaml up --build --exit-code-from micropython-host
866873
```
867874

875+
##### Test for RTU example
876+
877+
```bash
878+
docker compose -f docker-compose-rtu-test.yaml up --build --exit-code-from micropython-host-rtu
879+
```
880+
868881
## Documentation
869882

870883
The documentation is automatically generated on every merge to the develop

0 commit comments

Comments
 (0)