pub unsafe fn set_destination_circular_buffer<E>(
    chan: &mut Channel,
    destination: &mut [E]
)
where E: Element,
Expand description

Set a circular buffer as the destination for a DMA transfer

When the transfer completes, the DMA channel remain at the next element in the circular buffer.

Safety

Caller must ensure that the destination is valid for the lifetime of the transfer, and for all subsequent transfers performed by this DMA channel with this buffer.

Panics

Panics if

  • the capacity is not a power of two
  • the alignment is not a multiple of the buffer’s size in bytes