
GD32A50x User Manual
394
101~111: Reserved.
7
MCH0COMCEN
Multi mode channel 0 output compare clear enable.
When this bit is set, if the ETIFP signal is detected as high level, the MO0CPRE
signal will be cleared.
0: Multi mode channel 0 output compare clear disabled.
1: Multi mode channel 0 output compare clear enabled.
6:4
MCH0COMCTL
[2:0]
Multi mode channel 0 output compare control
When multi mode channel 0 is configured in output mode, and the MCH0MSEL[1:0]
= 2b’00, this bit-field controls the behavior of MO0CPRE which drives MCH0_O.
The active level of MO0CPRE is high, while the active level of MCH0_O depends
on MCH0FP[1:0] bits.
Note
: When multi mode channel 0 is configured in output mode, and the
MCH0MSEL[1:0] = 2b’11, the CH0COMCTL[2:0] bit-field controls the behavior of
O0CPRE which drives CH0_O and MCH0_O, while the active level of CH0_O and
MCH0_O depends on CH0P and MCH0P bits.
000: Timing mode. The MO0CPRE signal keeps stable, independent of the
comparison between the register TIMERx_MCH0CV and the counter
TIMERx_CNT.
001: Set the channel output on match. MO0CPRE signal is forced high when the
counter is equals tothe output compare register TIMERx_MCH0CV.
010: Clear the channel output on match. MO0CPRE signal is forced low when the
counter is equals tothe output compare register TIMERx_MCH0CV.
011: Toggle on match. MO0CPRE toggles when the counter is equals to the output
compare register TIMERx_MCH0CV.
100: Force low. MO0CPRE is forced to low level.
101: Force high. MO0CPRE is forced to high level.
110: PWM mode 0. When counting up, MO0CPRE is active as long as the counter
is smaller than TIMERx_MCH0CV, otherwise it is inactive. When counting down,
MO0CPRE is inactive as long as the counter is larger than TIMERx_MCH0CV,
otherwise it is active.
111: PWM mode 1. When counting up, MO0CPRE is inactive as long as the counter
is smaller than TIMERx_MCH0CV, otherwise it is active. When counting down,
MO0CPRE is active as long as the counter is larger than TIMERx_MCH0CV,
otherwise it is inactive.
If configured in PWM mode, the MO0CPRE level changes only when the output
compare mode is adjusted from
“Timing” mode to “PWM” mode or the comparison
result changes.
This bit cannot be modified when PROT[1:0] bit-field in TIMERx_CCHP register is
11 and CH0NMS bit-field is 00(compare mode).
3
MCH0COMSEN
Multi mode channel 0 output compare shadow enable
When this bit is set, the shadow register of TIMERx_MCH0CV register which
updates at each update event will be enabled.