
12. DMAC
12.2
DMA Transfer Time
DMA transfer time can be calculated as follows. (in terms of bus clock)
Any combinations of even or odd transfer read and write addresses are possible.
Table 12.3 lists the number of
DMAC bus cycles.
Table 12.4 lists coefficient j, k (number of the bus clock).
Transfer time = read bus cycle × j + write bus cycle × k
Table 12.3
DMA Transfer Time
i=0 to 3, p=0, 1
Table 12.4
Coefficient j, k
12.3
Channel Priority and DMA Transfer Timing
When multiple DMA requests are generated in one sampling period between one falling edge of the BCLK and the
next falling edge, the DRQ bit in the DMiSL register (i = 0 to 3) is set to 1 (requested) simultaneously. Channel
priority in this case is: DMA0 > DMA1 > DMA2 > DMA3. Leave the following period between each DMA
transfer request generation in the same channel.
DMA request interval
≥ (number of channels set for DMA transfer - 1) × 5 BCLK cycles
Described below is the operation when DMA0 and DMA1 requests are generated in one sampling period.
Figure 12.8 shows an example of a DMA transfer caused by external source.
In
Figure 12.8, DMA0 and DMA1 requests are generated simultaneously. A DMA0 request having higher priority
is acknowledged first to start a transfer. After one DMA0 transfer is completed, a bus privilege is returned to the
CPU. When the CPU has completed one bus access, a DMA1 transfer starts. After one DMA1 transfer is
completed, a privilege is again returned to the CPU.
DMA requests cannot be counted up since each channel has one DRQ bit. If m
ultiple DMA1 requests are
generated before receiving a bus privilege as shown in
Figure 12.8, the DRQ bit is set to 0 as soon as the privilege
is acquired once. The bus privilege is returned to the CPU when one transfer is completed.
Transfer Unit
Bus Width
Access
Address
Read Cycle
Write Cycle
8-bit transfer
(BWi bit in the DMDp
register = 0)
16 bits
Even
1
Odd
1
16-bit transfer
(BWi bit = 1)
16 bits
Even
1
Odd
2
Internal Space
Internal ROM or
internal RAM
SFR area
j=1
k=1
j=2
k=2