Skip to content

Commit 3952d6a

Browse files
committed
fix: recover Actions Micro display sessions
1 parent baa21d4 commit 3952d6a

13 files changed

Lines changed: 578 additions & 64 deletions

‎CHANGELOG.md‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## Unreleased
44

5+
- Add dual-hidraw input polling, a missed-heartbeat session watchdog, and a
6+
VID/PID-scoped `USBDEVFS_RESET` before Actions Micro transport reopen.
7+
- Reopen the kernel frame stream after transport recovery, resubmit the newest
8+
frame every two idle seconds, and publish a monotonic ready-file generation.
59
- Add a kernel-version-bound offline Debian package, SHA-256 sidecar, and an
610
explicit installer that never falls back to a network package source.
711
- Add `usbdisplay-check` with human-readable and JSON physical-readiness

‎README.md‎

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -114,12 +114,13 @@ Do not assume the secondary nodes are always numbered `1`; discover them by
114114
the `usbdisplay` framebuffer name and DRM driver name in production scripts.
115115

116116
The daemon writes `/run/usbdisplay/ready` after the selected backend has opened
117-
successfully. The marker contains `pid`, `backend`, and `physical`; only
118-
`physical=1` is a valid gate for a real HDMI consumer. The null and PPM
119-
diagnostic backends intentionally publish `physical=0`. The daemon removes the
120-
marker on disconnect and waits inside the same process for reconnect. The
121-
virtual framebuffer can exist without a USB adapter. `--ready-file PATH` and
122-
`--retry-ms N` customize the marker and retry interval.
117+
successfully. The marker contains `pid`, `generation`, `backend`, and
118+
`physical`; consumers require a positive generation and `physical=1` for a real
119+
HDMI transport. The null and PPM diagnostic backends intentionally publish
120+
`physical=0`. The daemon removes the marker on disconnect, increments the
121+
generation after recovery, and waits inside the same process for reconnect.
122+
The virtual framebuffer can exist without a USB adapter. `--ready-file PATH`
123+
and `--retry-ms N` customize the marker and retry interval.
123124

124125
## Application examples
125126

‎README.zh-CN.md‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -99,12 +99,12 @@ sudo rmmod usbdisplay
9999
第二设备的编号不保证为 `1`。生产脚本应通过 sysfs 中的 `usbdisplay`
100100
framebuffer 名称和 DRM 驱动名称发现节点。
101101

102-
生产守护进程在后端打开成功后写入包含 `pid`、`backend` 和 `physical` 的
103-
`/run/usbdisplay/ready`;只有 `physical=1` 才表示真实物理传输已就绪,`null`
104-
和 `ppm` 诊断后端会明确写入 `physical=0`。HID 断开时清理该文件,并在同一
105-
进程内等待重连。第二屏程序必须校验该文件和守护进程 PID,不能仅凭 `/dev/fb1`
106-
存在就认为 HDMI 已连接。可通过 `--ready-file PATH` 和 `--retry-ms N` 调整路径
107-
与重连间隔。
102+
生产守护进程在后端打开成功后写入包含 `pid`、`generation`、`backend` 和
103+
`physical` 的 `/run/usbdisplay/ready`;只有 `generation>0` 且 `physical=1`
104+
才表示真实物理传输已就绪,`null` 和 `ppm` 诊断后端会明确写入 `physical=0`。
105+
HID 断开时清理该文件,在同一进程内等待重连,并在恢复后递增代数。第二屏程序
106+
必须校验该文件和守护进程 PID,不能仅凭 `/dev/fb1` 存在就认为 HDMI 已连接。
107+
可通过 `--ready-file PATH` 和 `--retry-ms N` 调整路径与重连间隔。
108108

109109
## 应用示例
110110

0 commit comments

Comments
 (0)