
M451
May. 4, 2018
Page
446
of
1006
Rev.2.08
M4
51
S
E
RI
E
S
T
E
CH
NICA
L RE
F
E
R
E
NC
E
M
A
NU
A
L
CMPDAT DATA0
CMPU
CMPDAT DATA1
PERIOD DATA1
PERIOD DATA2
PERIOD DATA0
CNT
CNT wraparound
0xFFFF
Write
Load
Note:
CMPDAT
PERIOD
PERIOD DATA0
PERIOD DATA1
CMPDAT DATA1
PBUF
PERIOD DATA0
PERIOD DATA1
CMPBUF
CMPDAT DATA1
PERIOD DATA2
PERIOD DATA2
point 1
point 2
point 3
Figure 6.9-13 Immediately Loading in Up-Count Mode
Window Loading Mode
6.9.5.10
If the WINLDENn (PWM_CTL0[13:8]) bit which corresponds to PWM channel n is set to 1, the
channel n window loading mode is enabled. Window loading mode also loads a value from
PERIOD and CMPDAT to their buffer at the end of a period as period loading mode, but CMPDAT
loading to CMPBUF is valid only when load window is opened and PERIOD loading to PBUF at
the end of every PWM period no matter the load window is opened or not. Every channel n’s load
window is opened by setting the corresponding LOADn (PWM_LOAD[5:0]) to 1 and hardware will
close the window at the end of PWM period. Window loading mode can work with center loading
mode and CMPDAT loading time is also valid only at the interval of load window Figure 6.9-14
shows an example and its steps sequence is described below.
1. Software writes CMPDAT DATA1 at point 1, and the load window is not opened at this
period so CMPDAT will not load to CMPBUF.
2. Software writes LOAD to open the load window at point2.
3. Software writes PERIOD DATA1 at point 3.
4. At point 4, load window has been opened, hardware loads PERIOD DATA1 and CMPDAT
DATA1 to their buffer and closes the load window at the end of PWM period.
5. Software writes PERIOD DATA2 at point 5.
6. Hardware loads PERIOD DATA2 to PBUF at the end of PWM period at point 6.
7. Software writes PERIOD DATA3 at point 7.
8. Software writes LOAD to open the load window at point8.
9. Hardware loads PERIOD DATA3 to PBUF and closes the load window at the end of PWM
period at point 9.