Chapter 19 Pulse-Width Modulator (S12PWM8B8CV1)
MC9S12XE-Family Reference Manual , Rev. 1.19
708
Freescale Semiconductor
Duty Cycle = [PWMDTYx / PWMPERx] * 100%
For boundary case programming values, please refer to
Section 19.4.2.8, “PWM Boundary Cases”
.
Read: Anytime
Write: Anytime
19.3.2.15 PWM Shutdown Register (PWMSDN)
The PWMSDN register provides for the shutdown functionality of the PWM module in the emergency
cases. For proper operation, channel 7 must be driven to the active level for a minimum of two bus clocks.
Read: Anytime
Write: Anytime
Module Base + 0x001C = PWMDTY0, 0x001D = PWMDTY1, 0x001E = PWMDTY2, 0x001F = PWMDTY3
Module Base + 0x0020 = PWMDTY4, 0x0021 = PWMDTY5, 0x0022 = PWMDTY6, 0x0023 = PWMDTY7
7
6
5
4
3
2
1
0
R
Bit 7
6
5
4
3
2
1
Bit 0
W
Reset
1
1
1
1
1
1
1
1
Figure 19-16. PWM Channel Duty Registers (PWMDTYx)
Module Base + 0x0024
7
6
5
4
3
2
1
0
R
PWMIF
PWMIE
0
PWMLVL
0
PWM7IN
PWM7INL
PWM7ENA
W
PWMRSTRT
Reset
0
0
0
0
0
0
0
0
= Unimplemented or Reserved
Figure 19-17. PWM Shutdown Register (PWMSDN)
Field
Description
7
PWMIF
PWM Interrupt Flag
— Any change from passive to asserted (active) state or from active to passive state will
be flagged by setting the PWMIF flag = 1. The flag is cleared by writing a logic 1 to it. Writing a 0 has no effect.
0 No change on PWM7IN input.
1 Change on PWM7IN input
6
PWMIE
PWM Interrupt Enable
— If interrupt is enabled an interrupt to the CPU is asserted.
0 PWM interrupt is disabled.
1 PWM interrupt is enabled.
5
PWMRSTRT
PWM Restart
— The PWM can only be restarted if the PWM channel input 7 is de-asserted. After writing a logic
1 to the PWMRSTRT bit (trigger event) the PWM channels start running after the corresponding counter passes
next “counter == 0” phase. Also, if the PWM7ENA bit is reset to 0, the PWM do not start before the counter
passes $00. The bit is always read as “0”.
Because
of
an
order
from
the
United
States
International
Trade
Commission,
BGA-packaged
product
lines
and
part
numbers
indicated
here
currently
are
not
available
from
Freescale
for
import
or
sale
in
the
United
States
prior
to
September
2010:
S12XE
products
in
208
MAPBGA
packages