GD32A50x User Manual
351
The MCHx_O output is the inverse of the CHx_O output when the MCHxMSEL=2’b11 (and
the MCHxOMCTL bits are not used in the generation of the MCHx_O output). In this case,
CHx_O and MCHx_O signals cannot be set to active level at the same time. The break
sources are system events and other events. When the break event occurs, the outputs is
force at a predefined level (either active or inactive) after a deadtime duration. The break
function is enabled by setting the BRKEN bit in the TIMERx_CCHP register. The break input
polarity is configured by the BRKP bit in TIMERx_CCHP register.
The break event is the result of
logic ORed of all sources. The break function can handle two
types of event sources:
External sources: coming from BRKINx(x=0..3) inputs, and with digital filters and polarity
selection;
Internal sources: system sources(such as: HXTAL stuck event which is generated by
Clock Monitor CKM in RCU, LVD lock event, Cortex
®
-M33 LOCKUP_LOCK event or
SRAM ECC error event), and on-chip comparator events(configured in TRIGSEL module,
input by BRKIN0 pin).
Break events can also be gene
r
ated by software using BRKG bit in the TIMERx_SWEVG
register.
Figure 18-29. Break function diagram
BRK0F
Digital
Filter
BRK0EN
1
0
BRK0P
BRKIN0
...
BRK3F
Digital
Filter
BRK3EN
1
0
BRK3P
BRKIN3
1
0
BRKP
BRKEN
BRKG
Output
Logic
CKM clock monitor
LVD_LOCK event
LOCKUP_LOCK event
SRAM ECC error event
Refer to
Figure 18-29. Break function diagram
, BRKINx(x=0..3) can from the TRIGSEL
module or from the GPIO pins, which can select by
TIMER input source select register
When the MCHxMSEL = 2’b11 and a break occurs, the POEN bit is cleared asynchronously.
As soon as POEN is 0, the level of the CHx_O and MCHx_O outputs are determined by the
ISOx and ISOxN bits in the TIMERx_CTL1 register. If IOS = 0, the timer releases the enable
output, otherwise, the enable output remains high. The complementary outputs are first in the
reset state, and then the dead time generator is reactivated to drive the outputs with the level
programmed in the ISOx and ISOxN bits after a dead time.
When a break occurs, the BRKIF bit in the TIMERx_INTF register will be set. If BRKIE is 1,
an interrupt will be generated.