docs: write CLI docs for all 12 previously undocumented tools
Add docs/cli/ entries for: transport_cli, discovery_cli, config_cli, protocol_cli, query_cli, test_image_cli, xorg_cli, v4l2_view_cli, stream_send_cli, stream_recv_cli, reconciler_cli, controller_cli Each doc covers: description, build instructions, full usage with all options and defaults, example output, and a relationship note pointing to related tools. controller_cli includes the display control IDs table and notes its temporary status. README.md: convert all CLI tool entries to links. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
64
docs/cli/stream_send_cli.md
Normal file
64
docs/cli/stream_send_cli.md
Normal file
@@ -0,0 +1,64 @@
|
||||
# stream_send_cli
|
||||
|
||||
Captures MJPEG from a V4L2 device and streams it to a receiver over TCP as `VIDEO_FRAME` protocol messages. Prints per-stream throughput statistics. Pair with [`stream_recv_cli`](stream_recv_cli.md) to test an end-to-end stream without running a full node.
|
||||
|
||||
---
|
||||
|
||||
## Build
|
||||
|
||||
From the repository root:
|
||||
|
||||
```sh
|
||||
make cli
|
||||
```
|
||||
|
||||
The binary is placed in `build/cli/`.
|
||||
|
||||
---
|
||||
|
||||
## Usage
|
||||
|
||||
```sh
|
||||
./stream_send_cli [--device PATH] [--host HOST] [--port PORT] [--stream-id N]
|
||||
```
|
||||
|
||||
| Option | Default | Description |
|
||||
|---|---|---|
|
||||
| `--device PATH` | `/dev/video0` | V4L2 capture device |
|
||||
| `--host HOST` | `127.0.0.1` | Receiver hostname or IP |
|
||||
| `--port PORT` | `7700` | Receiver TCP port |
|
||||
| `--stream-id N` | `1` | Stream ID embedded in each `VIDEO_FRAME` message |
|
||||
|
||||
### Example
|
||||
|
||||
```sh
|
||||
# Terminal 1 — start a receiver
|
||||
./stream_recv_cli --port 7700
|
||||
|
||||
# Terminal 2 — start the sender
|
||||
./stream_send_cli --device /dev/video0 --host 127.0.0.1 --port 7700 --stream-id 1
|
||||
```
|
||||
|
||||
### Statistics output
|
||||
|
||||
Printed to stderr every 0.5 seconds:
|
||||
|
||||
```
|
||||
stream 1: 30.2 fps 18.4 Mbps
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Notes
|
||||
|
||||
- The tool opens the device and selects the highest-FPS MJPEG mode automatically.
|
||||
- Frames are sent as-is (raw MJPEG from the kernel) wrapped in `VIDEO_FRAME` messages — no re-encoding.
|
||||
- The connection is outbound: `stream_send_cli` connects to the receiver, not the other way around. This mirrors the node's START_INGEST behaviour.
|
||||
|
||||
---
|
||||
|
||||
## Relationship to the Video Routing System
|
||||
|
||||
`stream_send_cli` tests the source end of the ingest pipeline: V4L2 capture → transport send → `VIDEO_FRAME` messages. The node's ingest module performs the same operation, but driven by `START_INGEST` commands over the control channel.
|
||||
|
||||
See also: [`stream_recv_cli.md`](stream_recv_cli.md) for the receive side; [`v4l2_view_cli.md`](v4l2_view_cli.md) for local-only viewing.
|
||||
Reference in New Issue
Block a user