![GigaDevice Semiconductor GD32E23 Series User Manual Download Page 357](http://html.mh-extra.com/html/gigadevice-semiconductor/gd32e23-series/gd32e23-series_user-manual_2225794357.webp)
GD32E23x User Manual
357
Figure 14-62. Output-compare in three modes
CEN
CNT_REG
00
01
02
03
04
05
…
.
62
63
Overf low
match toggle
CNT_CLK
OxCPRE
00
01
02
03
04
05
…
.
62
63
01
02
03
04
05
…
.
00
match set
match clear
OxCPRE
OxCPRE
Output PWM function
In the output PWM function
(by setting the CHxCOMCTL bits to 3’b110 (PWM mode0) or to
3’b 111(PWM mode1), the channel can generate PWM waveform according to the
TIMERx_CAR registers and TIMERx_CHxCV registers.
The period is determined by TIMERx_CAR and duty cycle is determined by TIMERx_CHxCV.
Figure 14-63. PWM mode timechart
shows the PWM output mode and interrupts
waveform.
If TIMERx_CHxCV is greater than TIMERx_CAR, the output will be always active under
PWM
mode0 (CHxCOMCTL==3’b110).
And if TIMERx_CHxCV is equal to zero, the output will be always inactive under PWM
mode0 (CHxCOMCTL==3’b110).