feat: cam and slience detect sleep

This commit is contained in:
0Xiao0
2026-06-17 15:02:16 +08:00
parent 154ce461d7
commit a8c6c62c92
9 changed files with 564 additions and 163 deletions

View File

@ -29,9 +29,14 @@ Recommended minimum set:
Fatigue reminder:
- Add `wakeup.gif` or `wakeup.png` to make the idle-fatigue reminder show a custom idol animation.
- The reminder defaults to `wakeup` after 12 seconds of idle time or listening silence, then waits 60 seconds before it can trigger again.
- The reminder defaults to `wakeup` when camera drowsiness is detected, then waits 60 seconds before it can trigger again.
- Optional NVS settings in namespace `fatigue`:
- `enabled` (`bool`, default `true`)
- `camera_enabled` (`bool`, default `true`)
- `camera_debug_preview` (`bool`, default `true`; shows the sampled frame with the eye ROI box)
- `camera_interval_sec` (`int`, default `3`)
- `camera_closed_samples` (`int`, default `2`)
- `silence_enabled` (`bool`, default `false`)
- `idle_timeout_sec` (`int`, default `12`)
- `listening_timeout_sec` (`int`, default `12`)
- `cooldown_sec` (`int`, default `60`)