Pwm Output Operations - NEC mPD780208 Subseries User Manual

8-bit single-chip microcontrollers
Table of Contents

Advertisement

6.5.2 PWM output operations

By setting bits 1 to 3 (TMC01 to TMC03) of the 16-bit timer mode control register (TMC0) to 1, 0, 0, the 16-bit timer/
event counter operates as PWM output. Pulses with a duty determined by the value set in the 16-bit compare register
(CR00) beforehand are output from the TO0/P30 pin.
Set the active level width of the PWM pulse to the higher 14 bits of CR00. Select the active level using bit 1 (TOC01)
of the 16-bit timer output control register (TOC0).
This PWM pulse has a 14-bit resolution. The pulse can be converted to an analog voltage by integrating it with
an external low-pass filter (LPF). The PWM pulse has a combination of the basic cycle determined by 2
sub-cycle determined by 2
be selected using bits 4 to 6 (TCL04 to TCL06) of timer clock select register 0 (TCL0).
PWM output enable/disable can be selected using bit 0 (TOE0) of TOC0.
Cautions 1. CR00 should be set after selecting the PWM operation mode.
2. Be sure to write 0 to bits 0 and 1 of CR00.
3. Do not select the PWM operation mode when an external clock is input from the TI0/P00 pin.
By integrating 14-bit resolution PWM pulses with an external low-pass filter, they can be converted to an analog
voltage and used for electronic tuning and D/A converter applications, etc.
The analog output voltage (V
Compare register (CR00) value
V
= V
x
AN
REF
V
: External switching circuit reference voltage
REF
Figure 6-12. Example of D/A Converter Configuration with PWM Output
µ
PD780205
TO0/P30
CHAPTER 6 16-BIT TIMER/EVENT COUNTER
/ φ so that the time constant of the external LPF can be shortened. Count clock φ can
14
) used for D/A conversion with the configuration shown in Figure 6-12 is as follows.
AN
16
2
V
REF
PWM
signal
Switching
circuit
User's Manual U11302EJ4V0UM
Analog output (V
Low-pass filter
/ φ and the
8
)
AN
137

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mpd780204Mpd780206Mpd780208Mpd78p0208Mpd780204aMpd780205a ... Show all

Table of Contents