Datasheet
Table Of Contents
- List of Sections
- Table of Contents
- General Description
- Central Processing Unit (CPU)
- Pinout and Signal Description
- System Configuration
- Registers
- Operating Modes
- Resource Mapping
- Bus Control and Input/Output
- Resets and Interrupts
- Voltage Regulator (VREG)
- Flash EEPROM 256K
- EEPROM 4K
- Port Integration Module
- Clocks and Reset Generator (CRG)
- Pulse Width Modulator (PWM)
- Enhanced Capture Timer (ECT)
- Serial Communications Interface (SCI)
- Serial Peripheral Interface (SPI)
- Inter-IC Bus (IIC)
- MSCAN
- Analog to Digital Converter
- Byte Data Link Controller Module
- Contents
- Overview
- Features
- Block Diagram
- Register Map
- Functional Description
- Register Descriptions
- External Pin Descriptions
- Reset Initialization/Basic Operation
- Transmitting A Message
- Receiving A Message
- Transmitting An In-Frame Response (IFR)
- Receiving An In-Frame Response (IFR)
- Special BDLC Operations
- Modes of Operation
- Interrupt Operation
- Low Power Options
- Background Debug Module (BDM)
- Breakpoint (BKP) Module
- Revision History
- Glossary
- Literature Updates

Pulse Width Modulator (PWM)
Functional Description
MC9S12DP256 — Revision 1.1
Pulse Width Modulator (PWM)
edge. When the channel is disabled (PWMEx=0), the counter for the
channel does not count.
PWM Polarity Each channel has a polarity bit to allow starting a waveform cycle with a
high or low signal. This is shown on the block diagram as a mux select
of either the Q output or the Q
output of the PWM output flip flop. When
one of the bits in the PWMPOL register is set, the associated PWM
channel output is high at the beginning of the waveform, then goes low
when the duty count is reached. Conversely, if the polarity bit is zero, the
output starts low and then goes high when the duty count is reached.
PWM Period and
Duty
Dedicated period and duty registers exist for each channel and are
double buffered so that if they change while the channel is enabled, the
change will NOT take effect until one of the following occurs:
• The effective period ends
• The counter is written (counter resets to $00)
• The channel is disabled
In this way, the output of the PWM will always be either the old waveform
or the new waveform, not some variation in between. If the channel is
not enabled, then writes to the period and duty registers will go directly
to the latches as well as the buffer.
A change in duty or period can be forced into effect ‘immediately’ by
writing the new value to the duty and/or period registers and then writing
to the counter. This forces the counter to reset and the new duty and/or
period values to be latched. In addition, since the counter is readable it
is possible to know where the count is with respect to the duty value and
software can be used to make adjustments
CAUTION:
When forcing a new period or duty into effect immediately, an irregular
PWM cycle can occur.
NOTE:
Depending on the polarity bit, the duty registers will contain the count of
either the high time or the low time.
Freescale Semiconductor, I
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com
nc...