feat: independent fullscreen kiosk display foundation (#1)

Kiosk process owns its display lifecycle: waits for X11, keeps the
fullscreen black canvas below video, stops deterministically on signal.
Supervisor starts it before video, restarts only on process death, and
shuts the whole process group down; X11 downtime never restarts the
supervisor. Per-target opener/template abstractions for future MIPI.
This commit is contained in:
2026-09-30 23:12:06 +02:00
parent 0360f23f0a
commit a31bed8aeb
15 changed files with 1266 additions and 78 deletions
+14 -3
View File
@@ -7,20 +7,31 @@ Orange Pi Zero 3W application for the custom OpenIPC/WFB ground station.
- receives framed GX12 RC channel data over the dedicated AUX1 UART at 115200 8N1;
- validates protocol version, frame length and CRC-16;
- logs final mixed channel values;
- can start the existing `fpv-video` launcher for the Viture primary display.
- starts an independent kiosk display process that maps a fullscreen black canvas on `DISPLAY=:0` before video, tolerates X11 downtime without restarting the supervisor, and stops deterministically on shutdown;
- video keeps rendering priority: the kiosk canvas stays below the `fpv-video` window, and future display targets (MIPI/touch) get their own target-specific templates instead of one global layout.
The first baseline is intentionally small. It does **not** yet control an AUX, manipulate the flight-control link, or replace the primary video pipeline.
## Run
```bash
# Hardware UART mode (device path will be confirmed during Orange Pi bring-up)
groundstation -serial /dev/ttyS1 -start-video
# Supervisor (YAML configuration, default /etc/groundstation/config.yml;
# hardware UART paths live in the config file)
groundstation -config /etc/groundstation/config.yml
# Test input mode
groundstation -stdin
# Kiosk canvas alone (the supervisor starts it; standalone for debugging)
groundstation-display -target x11
```
## Runtime dependencies
- an X11 session on `:0` owned by the `orangepi` desktop user (the kiosk waits for X11 to appear and reconnects after display-manager restarts);
- `wmctrl` for the fullscreen/below kiosk window state — without it the canvas still maps but stays a plain window (logged);
- `runuser` from util-linux (base install) for the unprivileged kiosk launch.
## Protocol
The v1 protocol is described in `AGENTS.md` once the repository policy file is approved. It carries 16 final EdgeTX channel outputs as a binary framed message with CRC.