BB.NSK.Display.Viewport (bb_nsk v0.1.2)

Copy Markdown View Source

The Emerge renderer behind the panel.

Holds the last BB.NSK.Status it was shown and renders BB.NSK.Display.Dashboard from it, into BB.NSK.Display.FrameSink as a packed frame. Arbitrary screens can be put up with show/2, which is what BB.NSK.Display.TestCard uses; the next status update replaces them.

Rendering is a push: show/2 hands over a screen and returns, and the frame arrives at the sink some time later. Nothing here waits for the panel, which takes seconds — BB.NSK.Display.Controller decides when to redraw and the sink decides what reaches the panel.

The renderer runs on the host too, with no panel behind it, so a screen can be previewed without hardware.

Summary

Functions

Render a status, or any screen, and send the frame to the sink.

Functions

child_spec(opts)

show(viewport \\ __MODULE__, screen)

@spec show(GenServer.server(), BB.NSK.Status.t() | Emerge.tree()) :: :ok

Render a status, or any screen, and send the frame to the sink.

start_link(opts \\ [])