pub struct DsiDpi<'d> { /* private fields */ }Expand description
Video-mode (DPI) streaming handle.
Consumes the MipiDsi bus and drives the DSI host in video mode,
continuously streaming frame buffers via VDMA.
Implementations§
Source§impl<'d> DsiDpi<'d>
impl<'d> DsiDpi<'d>
Sourcepub fn framebuffer_mut(&mut self) -> &mut [u8] ⓘ
pub fn framebuffer_mut(&mut self) -> &mut [u8] ⓘ
Returns a mutable slice to the back (not-currently-displayed) frame buffer.
With a single frame buffer this is the same buffer the DMA may be reading — the caller is responsible for synchronisation in that case.
Sourcepub fn commit(&mut self)
pub fn commit(&mut self)
Flip the back buffer to the display.
Flushes the rendered back buffer from CPU cache to PSRAM, then updates the source address in every LLI so the DMA switches to the new pixels on its next block boundary.
LLI_VALID re-arming is handled entirely by the vdma_block_done_isr
interrupt handler, which fires after every frame block and keeps the
DMA channel running indefinitely without software restarts.
Sourcepub fn wait_for_vsync(&mut self)
pub fn wait_for_vsync(&mut self)
Block until the DSI bridge signals the start of the next vertical blank.
Use this to pace rendering to the display refresh rate. Any vsync event that is already pending (i.e. fired while the CPU was busy rendering) will be returned immediately.
Sourcepub fn wait_for_vsync_async(&mut self) -> impl Future<Output = ()>
pub fn wait_for_vsync_async(&mut self) -> impl Future<Output = ()>
Async: yield until the next vsync event.