Modular Input/Output Subsystem (MIOS14)
MPC561/MPC563 Reference Manual, Rev. 1.2
Freescale Semiconductor
17-51
For example, with 0x00FF in the counter and 0x0002 in MPWMPULR2, the period is 255 PWM clock
count and the pulse width is 2 PWM clock counts.
For a given system clock frequency, with a given counter divide ratio and clock selection divide ratio, the
output pulse width is given by the following equation:
where V
MPWMB2
is the value in the register B2
In such conditions, the minimum output pulse width that can be obtained is given by:
and the maximum pulse width by:
17.10.3.5 Duty Cycles (0% and 100%)
The 0% and 100% duty cycles are special cases to give flexibility to the software to create a full range of
outputs. The “always set” and “always clear” conditions of the output flip-flop are established by the value
in register MPWMPULR2. These boundary conditions are generated by software, just like another pulse.
When the PWM output is being used to generate an analog level, the 0% and 100% represent the full scale
values.
The 0% output is created with a 0x0000 in register MPWMPULR2, which prevents the output flip-flop
from ever being set.
The 100% output is created when the content of register MPWMPULR2 is equal to or greater than the
content of register MPWMPERR. Thus, the width register match occurs on counter reload. The state
sequencer provides the timing to ensure that the first appearance of a 100% value in register
MPWMPULR2 causes a glitchless always-set condition of the output flip-flop when TRSP = ‘0’.
NOTE
Even if the output is forced to 100%, the 16-bit up counter continues its
counting and that output changes to or from the 100% value are done
synchronously to the selected period.
NOTE
When a PWM output period is selected to be 65536 PWM clocks by loading
0x0000 in the period register, it is not possible to have an 100% duty cycle
output signal. In this case, the maximum duty cycle available is of
65535/65536.
Pulse_Width
N
MCPSM
N
MPWMSM
²
V
MPWMB2
²
f
SYS
---------------------------------------------------------------------------------------------------------
=
Minimum_Pulse_Width
N
MCPSM
N
MPWMSM
²
f
SYS
-------------------------------------------------------------------
=
Maximum_Pulse_Width
N
MCPSM
N
MPWMSM
²
2
Bit_of_Resolution
1
–
(
)
²
f
SYS
-----------------------------------------------------------------------------------------------------------------------------------------
=
Summary of Contents for MPC561
Page 84: ...MPC561 MPC563 Reference Manual Rev 1 2 lxxxiv Freescale Semiconductor...
Page 144: ...Signal Descriptions MPC561 MPC563 Reference Manual Rev 1 2 2 46 Freescale Semiconductor...
Page 206: ...Central Processing Unit MPC561 MPC563 Reference Manual Rev 1 2 3 62 Freescale Semiconductor...
Page 302: ...Reset MPC561 MPC563 Reference Manual Rev 1 2 7 14 Freescale Semiconductor...
Page 854: ...Time Processor Unit 3 MPC561 MPC563 Reference Manual Rev 1 2 19 24 Freescale Semiconductor...
Page 968: ...Development Support MPC561 MPC563 Reference Manual Rev 1 2 23 54 Freescale Semiconductor...
Page 1144: ...Internal Memory Map MPC561 MPC563 Reference Manual Rev 1 2 B 34 Freescale Semiconductor...
Page 1212: ...TPU3 ROM Functions MPC561 MPC563 Reference Manual Rev 1 2 D 60 Freescale Semiconductor...
Page 1216: ...Memory Access Timing MPC561 MPC563 Reference Manual Rev 1 2 E 4 Freescale Semiconductor...