MC68HC912B32MFU8 MOTOROLA [Motorola, Inc], MC68HC912B32MFU8 Datasheet - Page 69

no-image

MC68HC912B32MFU8

Manufacturer Part Number
MC68HC912B32MFU8
Description
16-Bit Microcontroller
Manufacturer
MOTOROLA [Motorola, Inc]
Datasheet
PWCNTx — PWM Channel Counters
PWPERx — PWM Channel Period Registers
MC68HC912B32
MC68HC912B32TS/D
PWCNT0
PWCNT1
PWCNT2
PWCNT3
PWPER0
PWPER1
PWPER2
PWPER3
RESET:
RESET:
Read and write anytime. A write will cause the PWM counter to reset to $00.
In special mode, if DISCR = 1, a write does not reset the PWM counter.
Each counter may be read any time without affecting the count or the operation of the corresponding
PWM channel. Writes to a counter cause the counter to be reset to $00 and force an immediate load of
both duty and period registers with new values. To avoid a truncated PWM period, write to a counter
while the counter is disabled. In left-aligned output mode, resetting the counter and starting the wave-
form output is controlled by a match between the period register and the value in the counter. In center-
aligned output mode the counters operate as up/down counters, where a match in period changes the
counter direction. The duty register changes the state of the output during the period to determine the
duty.
When a channel is enabled, the associated PWM counter starts at the count in the PWCNTx register
using the clock selected for that channel.
In special mode, when DISCP = 1 and configured for left-aligned output, a match of period does not
reset the associated PWM counter, and when configured center-aligned-output mode, a match of period
does not change the associated PWM counter direction.
Read and write anytime.
The value in the period register determines the period of the associated PWM channel. If written while
the channel is enabled, the new value will not take effect until the existing period terminates, forcing the
counter to reset. The new period is then latched and is used until a new period value is written. Reading
this register returns the most recent value written. To start a new period immediately, write the new pe-
riod value and then write the counter forcing a new period to start with the new period value.
Period = Channel-Clock-Period (PWPER
Period = Channel-Clock-Period (2
Bit 7
Bit 7
Bit 7
Bit 7
Bit 7
Bit 7
Bit 7
Bit 7
Bit 7
Bit 7
0
0
6
6
6
6
6
0
6
6
6
6
6
0
5
5
5
5
5
0
5
5
5
5
5
0
(PWPER
4
4
4
4
4
0
4
4
4
4
4
0
1)
1))
3
3
3
3
3
0
3
3
3
3
3
0
2
2
2
2
2
0
2
2
2
2
2
0
(CENTR = 0)
(CENTR = 1)
1
1
1
1
1
0
1
1
1
1
1
0
Bit 0
Bit 0
Bit 0
Bit 0
Bit 0
Bit 0
Bit 0
Bit 0
Bit 0
Bit 0
0
0
MOTOROLA
$004A
$004B
$004C
$004D
$004E
$0048
$0049
$004F
69

Related parts for MC68HC912B32MFU8