Theory of Operation
Various data transfer modes of the Blackfin processor's DMA controller
are supported, including descriptor chains, circular buffers (utilizing the
autobuffer capability of the Blackfin processor), and one-shot transfers.
One-dimensional (linear) transfers and two-dimensional (matrix) transfers
are supported.
The DMA manager can be directed to notify the client (through the cli-
ent's callback function) when data transfers complete. Additionally, the
client's callback function is invoked when an unexpected event, such as a
DMA error, occur. As with all system services, the DMA manager allows
the client to specify callbacks to be "live", meaning the client's callback
function is invoked at hardware interrupt time, or "deferred", meaning the
client's callback function is invoked outside the context of the hardware
interrupt.
DMA Manager Initialization
In order to use the DMA manager, the client must first initialize it. The
DMA manager does not use static data, so the initialization step is used to
give the DMA manager memory for use in managing the DMA controller.
The DMA manager requires a small, fixed amount of base memory and a
variable amount of memory, depending the number of simultaneously
open DMA channels the system requires. Note that memory DMA
requires two DMA channels—one channel for the source and another
channel for the destination for each memory DMA stream. Macros are
provided to define the amount of memory (in bytes) required for the base
and channel memory. These macros are
ADI_DMA_CHANNEL_MEMORY
For example, if the client wants to initialize the DMA manager and has at
most four DMA channels and one memory DMA stream open simulta-
neously, the amount of required memory is:
(ADI_DMA_BASE_MEMORY + (ADI_DMA_CHANNEL_MEMORY * 6)).
6-4
ADI_DMA_BASE_MEMORY
.
VisualDSP++ 5.0 Device Drivers and System
Services Manual for Blackfin Processors
and
Need help?
Do you have a question about the VisualDSP++ 5.0 and is the answer not in the manual?