Adding some instructions for using the sim, also improving the --help

output to be more consistent
This commit is contained in:
Rob Emery committed 2026-10-28 11:23:14 +00:00
1 parent f22bf9cf82
commit 8d20af475e
2 files changed
+32 -8

No files matched your search

+28 -4
View File
@@ -103,11 +103,11 @@ Build host tools only:
docker run --rm -v $(pwd):/workspace rtlplayground-dev make -C tools
```
Run the web-interface simulator locally:
Run the web-interface simulator through docker:
```
docker run --rm -p 8080:8080 -v $(pwd):/workspace rtlplayground-dev \
tools/output/httpd_sim /workspace/html
docker run --rm -p 8081:8081 -v $(pwd):/workspace rtlplayground-dev \
tools/output/httpd_sim.py /workspace/html
```
Edit `config.txt` on your host, then re-run `make` — the
@@ -362,7 +362,31 @@ session xxxx = Web session timeout in seconds (default 200)
Enjoy playing!
## (11) Other documents
## (13) HTTP Simulator for front-end development
The simulator is available in tools as `./httpd_sim.py`
By default it will serve the content in the current working directory so the easiest way to run this is to:
```
cd ./html
../tools/httpd_sim.py
```
And the simulator will be available on http://127.0.0.1:8081
There are commandline options available:
```
usage: httpd_sim.py [-h] [--machine MACHINE] [--port PORT] [--bindaddr BINDADDR] [--verbose]
options:
-h, --help show this help message and exit
--machine MACHINE path to machine.c or .h file to parse (optional)
--port PORT port to bind to (default 8081)
--bindaddr BINDADDR address to bind (default 127.0.0.1)
--verbose enable verbose output
```
The machine parsing is somewhat experimental.
## (12) Other documents
The following documents give further documentation on specific features of the RTL837x SoCs:
- [Adding a new device](doc/adding-a-device.md)