Enhanced Modular Input/Output Subsystem (eMIOS200)
Freescale Semiconductor
23-51
PXR40 Microcontroller Reference Manual, Rev. 1
23.4.1.1.16
Center-Aligned Output PWM Buffered with Dead Time (OPWMCB) Mode
The OPWMCB mode generates a center-aligned PWM with dead time insertion to the leading or trailing
edge. A1 and B1 registers are double-buffered to allow smooth output signal generation when changing
A2 or B2 registers values on the fly.
The BSL bits select the time base. The time base selected for a channel configured to OPWMCB mode
should be a channel configured to MCB Up/Down mode, as shown in
start the MCB channel time base after the OPWMCB mode is entered in order to avoid missing A matches
at the very first duty cycle.
Register A1 contains the ideal duty cycle for the PWM signal and is compared with the selected time base.
Register B1 contains the dead time value and is compared against the internal counter. For a leading edge
dead time insertion, the output PWM duty cycle is equal to the difference between register A1 and register
B1. For a trailing edge dead time insertion, the output PWM duty cycle is equal to the sum of register A1
and register B1. Mode[6] selects between trailing and leading dead time insertion.
NOTE
The internal counter runs in the internal prescaler ratio, while the selected
time base may be running in a different prescaler ratio.
When OPWMCB mode is entered (coming out of GPIO mode), the output flip-flop is set to the
complement of the EDPOL bit in the EMIOS_CCR[
n
] register.
The following basic steps summarize proper OPWMCB startup, assuming the channels are initially in
GPIO mode:
1.
[global]
Disable Global Prescaler.
2.
[MCB channel]
Disable Channel Prescaler.
3.
[MCB channel]
Write $1 at internal counter.
4.
[MCB channel]
Set A register.
5.
[MCB channel]
Set channel to MCB Up mode.
6.
[MCB channel]
Set prescaler ratio.
7.
[MCB channel]
Enable Channel Prescaler.
8.
[OPWMCB channel]
Disable Channel Prescaler.
9.
[OPWMCB channel]
Set A register.
10.
[OPWMCB channel]
Set B register.
11.
[OPWMCB channel]
Select time base input through BSL[1:0] bits.
12.
[OPWMCB channel]
Enter OPWMCB mode.
13.
[OPWMCB channel]
Set prescaler ratio.
14.
[OPWMCB channel]
Enable Channel Prescaler.
15.
[global]
Enable Global Prescaler.
shows the load of A1 and B1 registers, which occurs when the selected counter bus
transitions from 0x00_0002 to 0x00_0001. This event defines the cycle boundary. Values written to A2 or
Summary of Contents for PXR4030
Page 1: ...PXR40 Microcontroller Reference Manual Devices Supported PXR4030 PXR4040 PXR40RM Rev 1 06 2011...
Page 30: ...PXR40 Microcontroller Reference Manual Rev 1 Freescale Semiconductor xxx...
Page 40: ...PXR40 Microcontroller Reference Manual Rev 1 xl Freescale Semiconductor...
Page 66: ...Memory Map PXR40 Microcontroller Reference Manual Rev 1 2 4 Freescale Semiconductor...
Page 120: ...Signal Descriptions 3 54 Freescale Semiconductor PXR40 Microcontroller Reference Manual Rev 1...
Page 860: ...FlexCAN Module 24 50 Freescale Semiconductor PXR40 Microcontroller Reference Manual Rev 1...
Page 1167: ...Decimation Filter Freescale Semiconductor 28 53 PXR40 Microcontroller Reference Manual Rev 1...
Page 1168: ...Decimation Filter 28 54 Freescale Semiconductor PXR40 Microcontroller Reference Manual Rev 1...