GD32W51x User Manual
553
Figure 17-57. Up-counter timechart, change TIMERx_CAR on the go
TIMER_CK
CEN
CNT_CLK(PSC_CLK)
CNT_REG
5E
5F
60
61
62
63
00
01
02
03
04
05
06
07
Update event (UPE)
Update interrupt flag (UPIF)
Auto-reload register
65
63
change CAR Vaule
CNT_REG
5E
5F
60
61
62
63
64
65
00
01
02
62
63
00
Update event (UPE)
Update interrupt flag (UPIF)
Auto-reload register
65
63
change CAR Vaule
65
63
Auto-reload shadow
register
...
Hardware set
Hardware set
Software clear
Hardware set
ARSE = 0
ARSE = 1
Repetition counter
Counter repetition is used to generator update event or updates the timer registers only after
a given number (N+1) of cycles of the counter, where N is CREP in TIMERx_CREP register.
The repetition counter is decremented at each counter overflow in up-counting mode.
Setting the UPG bit in the TIMERx_SWEVG register will reload the content of CREP in
TIMERx_CREP register and generator an update event.