GD32A50x User Manual
248
Note:
The NBR[4:0] bits value shall only be written by software when both synchronization
enable bit SYNCEN and event generation enable EVGEN bit of the corresponding request
multiplexer channel x are disabled.
When
synchronization mode is enabled
A channel x in synchronization mode, when a rising/falling edge on the selected
synchronization input is detected, the pending selected input DMA request line is routed to
the multiplexer channel x output. Each time the connected DMAMUX request is served by the
DMA controller, the served DMA request is de-asserted, and the built-in DMAMUX request
multiplexer counter is decremented. At the request multiplexer counter underrun, the input
DMA request line is disconnected from the request multiplexer channel x output, and the built-
in DMAMUX request multiplexer counter is automatically loaded with the value in NBR[4:0]
bits of the DMAMUX_RM_CHxCFG register. The number of DMA requests transferred to the
request multiplexer channel x output following a detected synchronization event is NBR[4:0]
+ 1.
Figure 12-2. Synchronization mode
shows an example when NBR[4:0]=4, SYNCEN=1,
EVGEN=1, SYNCP[1:0]=01.
Figure 12-2. Synchronization mode
The selected Reqx_in
Syncx_in
Evtx_out
4
3
2
1
Reqx_out
0
DMAMUX request
multiplexer counter
4
Pending DMA request
DMA request served
Synchronization event occurs
Counter underrun event occurs
DMAMUX request multiplexer channel x can be synchronized by setting the synchronization
enable bit SYNCEN in the DMAMUX_RM_CHxCFG register. The synchronization input is
selected by SYNCID[4:0] bits in the DMAMUX_RM_CHxCFG register, the sources can refer
Table 12-5. Synchronization input mapping
. The synchronization input valid edge is
configured by the SYNCP[1:0] bits of the DMAMUX_RM_CHxCFG register.
Note:
If a synchronization input event occurs when there is no pending selected input DMA
request line, the input event is discarded. The following asserted input request lines will not