18.3.2.11 Up/Down-count (Dual-slope) PWM
If the counter is set to up-down count and the Compare/Capture channel is put in PWM mode, dual slope PWM output will be generated
by
Figure 18.29 TIMER Up/Down-count PWM Generation on page 594
.The resolution (in bits) is given by
Down-count PWM Resolution Equation on page 594
.
0
TIMERn_TOP
TIMERn_CCx_CCV
TIMn_CCx
Overflow
Compare match
Buffer update
Figure 18.29. TIMER Up/Down-count PWM Generation
R
PWM
up/down
= log(TOP+1)/log(2)
Figure 18.30. TIMER Up/Down-count PWM Resolution Equation
Figure 18.31 TIMER Up/Down-count PWM Frequency Equation on page 594
f
PWM
up/down
= f
HFPERCLK
/ ( 2^(PRESC+1) x TOP))
Figure 18.31. TIMER Up/Down-count PWM Frequency Equation
The high duty cycle is given by
Figure 18.32 TIMER Up/Down-count Duty Cycle Equation on page 594
DS
up/down
= CCVx/TOP
Figure 18.32. TIMER Up/Down-count Duty Cycle Equation
The figure below provides cycle accurate timing and event genration information for up-count mode.
TIMERn_TOP =
TIMERn_CCx_CCV =
TIMn_CCx
Overflow
Compare match
Buffer update
1
2
3
4
0
TIMERn_CCx
Figure 18.33. TIMER Up/Down-count PWM Generation
EFM32JG1 Reference Manual
TIMER - Timer/Counter
silabs.com
| Smart. Connected. Energy-friendly.
Preliminary Rev. 0.6 | 594