![Rabbit Rabbit 4000 Скачать руководство пользователя страница 249](http://html1.mh-extra.com/html/rabbit/rabbit-4000/rabbit-4000_user-manual_3116714249.webp)
Chapter 23 Pulse Width Modulator
239
23. P
ULSE
W
IDTH
M
ODULATOR
23.1 Overview
The Pulse Width Modulator (PWM) consists of a 10-bit free running counter and four
width registers. A PWM output consists of a train of periodic pulses within a 1024-count
frame with a duty cycle that varies from 1/1024 to 1024/1024. Each PWM output is high
for
n
+ 1 counts out of the 1024-clock count cycle, where
n
is the value held in the width
register. The PWM is clocked by the output of Timer A9 which is used to set the period.
Each PWM output high time can optionally be spread throughout the cycle to reduce rip-
ple on the externally filtered PWM output. The PWM outputs can be passed through a fil-
ter and used as a 10-bit D/A converter. The outputs can also be used to directly drive
devices such as motors or solenoids that have intrinsic filtering.
The PWM outputs can trigger a PWM interrupt on every PWM cycle, every other cycle,
every fourth cycle, or every eighth cycle. In addition, the PWM output can be suppressed
every other cycle, three out of every four cycles, or seven out of every eight cycles. These
options provide support for driving servos and to generate audio signals. The setup for this
interrupt is done in the PWL0R and PWL1R registers. The timing is shown below.
0
1
2
3
4
5
6
7
ITERATION
1/8
OUTPUT
1/4
OUTPUT
1/2
OUTPUT
1/2
INTERRUPT
1/4
INTERRUPT
1/8
INTERRUPT
Содержание Rabbit 4000
Страница 1: ...Rabbit 4000 Microprocessor User s Manual 019 0152 070720 H...
Страница 18: ...8 Rabbit 4000 Microprocessor User s Manual...
Страница 40: ...30 Rabbit 4000 Microprocessor User s Manual...
Страница 74: ...64 Rabbit 4000 Microprocessor User s Manual...
Страница 82: ...72 Rabbit 4000 Microprocessor User s Manual...
Страница 86: ...76 Rabbit 4000 Microprocessor User s Manual...
Страница 96: ...86 Rabbit 4000 Microprocessor User s Manual...
Страница 182: ...172 Rabbit 4000 Microprocessor User s Manual...
Страница 240: ...230 Rabbit 4000 Microprocessor User s Manual...
Страница 248: ...238 Rabbit 4000 Microprocessor User s Manual...
Страница 256: ...246 Rabbit 4000 Microprocessor User s Manual...
Страница 310: ...300 Rabbit 4000 Microprocessor User s Manual...
Страница 330: ...320 Rabbit 4000 Microprocessor User s Manual...
Страница 348: ...338 Rabbit 4000 Microprocessor User s Manual...