Skip to content

Record LED panel animations → video - #84

Open
electronicbites wants to merge 5 commits into
mainfrom
task/recorder
Open

Record LED panel animations → video#84
electronicbites wants to merge 5 commits into
mainfrom
task/recorder

Conversation

@electronicbites

@electronicbites electronicbites commented Jul 12, 2026

Copy link
Copy Markdown
Collaborator

Adds an optional subsystem to record the frames sent to the LED panels and convert them to video. Recording is off by default and designed to never affect the running installation.

What's included

  • Recorder (Octopus.Recording + PanelRecorder): passively subscribes to the mixer's frame feed and writes an append-only .octorec file. Safe by design — passive PubSub subscriber, subscribe-only-while-active, per-frame try/rescue, and drop-on-overload so it can never block or crash the app.
  • Pluggable sinks (Sink behaviour):
    • Sink.File — local file
    • Sink.Remote — stream to a TCP server (bounded connect/send timeouts)
    • Sink.Gzip — optional gzip compression via built-in :zlib (no native deps; runs on the Raspberry Pi). Typically 1.3× smaller for busy content, 10–1000× for sparse/dark.
  • Encoder (mix octopus.recording.encode): offline ffmpeg step producing one video per panel plus a mixed video; reads .gz transparently.
  • Docs: docs/recording.md (usage, storage sizing, compression) and docs/recording_architecture.md (design & rationale).

Usage

Octopus.Recording.start()                 # or start(compress: true)
Octopus.Recording.stop()
mix octopus.recording.encode recordings/panels-<stamp>.octorec

Enable via config :octopus, Octopus.Recording, enabled: true, compress: true.

Notes

  • Only additive change to existing code: a new Mixer.unsubscribe/0 and wiring the supervisor into the app tree.
  • Tests cover the format, recorder, both encoders, and the file/remote/gzip sinks (ffmpeg-dependent tests tagged :ffmpeg).

@electronicbites
electronicbites marked this pull request as ready for review July 15, 2026 16:13
@electronicbites electronicbites changed the title Task/recorder Record LED panel animations → video Jul 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant