GD32F10x User Manual
282
Figure 15-15. Output-compare in three modes
CEN
CNT_REG
00
01
02
03
04
05
.
62
63
Overflow
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.
Based on the counter mode, we can also divide PWM into EAPWM (Edge aligned PWM) and
CAPWM (Centre aligned PWM).
The EAPWM period is determined by TIMERx_CAR and duty cycle is determined by
TIMERx_CHxCV.
Figure 15-16. Timing chart of EAPWM
shows the EAPWM output and
interrupts waveform.
The CAPWM period is determined by 2*TIMERx_CAR, and duty cycle is by
2*TIMERx_CHxCV.
Figure 15-17. Timing chart of CAPWM
shows the CAPWM output 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).
Summary of Contents for GD32F10 Series
Page 63: ...GD32F10x User Manual 63 programmed during the chip production ...
Page 117: ...GD32F10x User Manual 117 010 1 0 011 0 9 ...
Page 416: ...GD32F10x User Manual 416 shadow register updates every update event ...
Page 427: ...GD32F10x User Manual 427 value ...
Page 518: ...GD32F10x User Manual 518 These bits are not used in SPI mode ...