HT46RU67 Holtek Semiconductor Inc., HT46RU67 Datasheet - Page 27

no-image

HT46RU67

Manufacturer Part Number
HT46RU67
Description
Ht46ru67/ht46cu67 -- A/d Type 8-bit Mcu With Lcd
Manufacturer
Holtek Semiconductor Inc.
Datasheet
Rev. 1.00
7+1 PWM mode
Each full PWM cycle, as it is controlled by an 8-bit
PWM register, has 256 clock periods. However, in the
7+1 PWM mode, each PWM cycle is subdivided into
two individual sub-cycles known as modulation cycle 0
and modulation cycle 1, denoted as i in the table.
Each one of these two sub-cycles contains 128 clock
cycles. In this mode, a modulation frequency increase
of two is achieved. The 8-bit PWM register value, which
represents the overall duty cycle of the PWM wave-
form, is divided into two groups. The first group which
consists of bit1~bit7 is denoted here as the DC value.
The second group which consists of bit0 is known as
the AC value. In the 7+1 PWM mode, the duty cycle
value of each of the two modulation sub-cycles is
shown in the following table.
PWM output control
On all devices, the PWM outputs are pin-shared with
the Port D I/O pins. To operate as PWM outputs and not
as I/O pins, the correct PWM configuration options
must be selected. A 0 must also be written to the cor-
responding bits in the I/O port control register PDC to
ensure that the required PWM output pins are setup as
outputs. After these two initial steps have been carried
out, and of course after the required PWM value has
been written into the PWM register, writing a 1 to the
corresponding bit in the PD output data register will en-
(7+1) PWM Mode Output Waveform
7+1 Mode PWM Register
27
The following diagram illustrates the waveforms asso-
ciated with the 7+1 mode PWM operation. It is impor-
tant to note how the single PWM cycle is subdivided
into 2 individual modulation cycles, numbered 0 and 1
and how the AC value is related to the PWM value.
able the PWM data to appear on the pin. Writing a 0
to the corresponding bit in the PD output data register
will disable the PWM output function and force the out-
put low. In this way, the Port D data output register can
be used as an on/off control for the PWM function. Note
that if the configuration options have selected the PWM
function, but a 1 has been written to its corresponding
bit in the PDC control register to configure the pin as an
input, then the pin can still function as a normal input
line, with pull-high resistor options.
Modulation cycle i
Parameter
7+1 Mode Modulation Cycle Values
(i=0~1)
HT46RU67/HT46CU67
AC (0~1)
i<AC
i AC
February 27, 2008
Duty Cycle
DC + 1
128
128
DC

Related parts for HT46RU67