3 gpt pwm configuration register (gpwmn), Gpt pwm configuration register (gpwmn) -6, 3 gpt pwm configuration register (gpwm n ) – Freescale Semiconductor MCF5480 User Manual
Page 346

MCF548x Reference Manual, Rev. 3
11-6
Freescale Semiconductor
11.3.3
GPT PWM Configuration Register (GPWMn)
Table 11-3. GCIRn Field Descriptions
Bits
Name Description
31–16
PRE
Prescaler. Prescale amount applied to internal counter (in clocks).
Note that in addition to other enable bits and field settings, the PRE field must be written as
non-zero to enable counter operation for all modes except the simple GPIO mode. A prescale of
0x0001 means one clock per count increment.
15–0
CNT
Count value. Sets number of prescaled counts applied to reference events, as follows:
IC—Field has no effect, internal counter starts at 0.
OC—Number of prescaled counts counted before creating output event.
PWM—Number of prescaled counts defining the PWM output period.
Internal Timer—Number of prescaled counts counted before timer (or watchdog) expires.
Reading this register only returns the programmed value, intermediate values of the internal
counter are not available to software.
31
30
29
28
27
26
25
24
23
22
21
20
19
18
17
16
R
WIDTH
W
Reset
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
R
0
0
0
0
0
0
0
PWM
OP
0
0
0
0
0
0
0
LOAD
W
Reset
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
Reg
Addr
MBAR + 0x808 (GPWM0), 0x818 (GPWM1), 0x828 (GPWM2), 0x838 (GPWM3)
Figure 11-3. GPT PWM Configuration Register (GPWMn)
Table 11-4. GPWMn Field Descriptions
Bits
Name Description
31–16
WIDTH
PWM width. Used in PWM mode only. Defines ON time for output in prescaled counts. Similar to
count value, which defines the period. ON time overlays the period time.
If WIDTH = 0, output is always OFF.
If WIDTH exceeds count value, output is always ON.
ON and OFF polarity is set by the PWMOP bit.
15–9
—
Reserved. Should be cleared.
8
PWMOP
PWM output polarity. Defines PWM output polarity for OFF time. Opposite state is ON time. PWM
cycles begin with ON time.
0 PWM output is low during OFF time
1 PWM output is high during OFF time