
ADSP-BF59x Blackfin Processor Hardware Reference
5-93
Direct Memory Access
rts;
memdma_setup.end:
For simplicity the example shown in
Listing 5-3
polls the DMA status
rather than using interrupts, which is the normal case in a real application.
Listing 5-3. Polling DMA Status
memdma_wait:
[--sp] = r7;
memdma_wait.test:
r7 = w[p0 + MDMA_D0_IRQ_STATUS - MDMA_S0_CONFIG] (z);
CC = bittst (r7, bitpos(DMA_DONE));
if !CC jump memdma_wait.test;
r7 = DMA_DONE (z);
w[p0 + MDMA_D0_IRQ_STATUS - MDMA_S0_CONFIG] = r7;
r7 = [sp++];
rts;
memdma_wait.end:
Initializing Descriptors in Memory
Descriptor-based DMAs expect the descriptor data to be available in
memory by the time the DMA is enabled. Often, the descriptors are pro-
grammed by software at run-time. Many times, however, the
descriptors—or at least large portions of them—can be static and there-
fore initialized at boot time. How to set up descriptors in global memory
depends heavily on the programming language and the tool set used. The
following examples show how this is best performed in the Vi+
tools’ assembly language.
Listing 5-4
uses multiple variables of either 16-bit or 32-bit size to
describe DMA descriptors. This example has two descriptors in small list
flow mode that point to each other. At the end of the second work unit,
an interrupt is generated without discontinuing the DMA processing. The
Содержание ADSP-BF59x Blackfin
Страница 64: ...Development Tools 1 22 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 74: ...Processor Specific MMRs 2 10 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 204: ...Unique Information for the ADSP BF59x Processor 5 104 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 244: ...Programming Examples 6 40 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 345: ...ADSP BF59x Blackfin Processor Hardware Reference 9 9 Core Timer Unique Information for the ADSP BF59x Processor None...
Страница 346: ...Unique Information for the ADSP BF59x Processor 9 10 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 398: ...Unique Information for the ADSP BF59x Processor 11 42 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 622: ...Unique Information for the ADSP BF59x Processor 15 38 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 700: ...Programming Examples 16 78 ADSP BF59x Blackfin Processor Hardware Reference...
Страница 738: ...Boundary Scan Architecture B 8 ADSP BF59x Blackfin Processor Hardware Reference...