Principle Of Operation - NEC V850E/Dx3 Preliminary User's Manual

32-bit single-chip microcontroller
Table of Contents

Advertisement

Chapter 14
Clock source
4 MHz main osc.
32 KHz sub osc.
240 KHz ring osc.
a)
The maximum period corresponds to a counter load value of 2
480
Downloaded from
Elcodis.com
electronic components distributor

14.1.2 Principle of operation

In order to generate an interrupt every one or two seconds, WTCLK is usually
set to a frequency around 30 KHz. Then, a load value around 2
running time of about 1 s.
(1)
Operation control of WT0
The source and frequency of WTCLK are specified in the Clock Generator
register TCC.
The Clock Generator contains a programmable frequency divider that makes it
possible to scale down the selected clock source.
Note
WTCLK uses the same clock source and clock divider as the LCD Controller/
Driver clock LCDCLK. The frequency f
f
/ 2. For details refer to "Clock Generator" on page 129.
LCDCLK
Typical settings and the resulting maximum time interval between two
interrupts are listed in the table below.
Table 14-1
Typical Settings of WTCLK
Clock divider setting
1 / 128
1
1 / 8
Note that you can double the maximum period by setting TCC.WTSEL1 to 1.
The clock input can be disabled (WT0CTL.WTCE = 0). This stops the Watch
Timer. After reset, the timer is also stopped.
When WT0 is enabled and a non-zero reload value is specified, the counter
decreases with every rising edge of WTCLK. When the counter reaches zero,
the interrupt INTWT0UV is active high for one clock cycle. Upon undeflow, i.e.
with the next clock, the timer reloads its start value and resumes down-
counting. The load value can be freely chosen
(2)
Operation of WT1
Once WT1 is enabled and a non-zero reload value is specified, its counter
decreases with every interrupt INTWT0UV.
When WT1 reaches zero, it generates the interrupt INTWT1UV. Upon
undeflow, i.e. with the next clock, the timer reloads its load value and restarts
down-counting. The load value can be freely chosen.
Starting WT1 requires some attention. For further details refer to "Watch Timer
start-up" on page 486.
Preliminary User's Manual U17566EE1V2UM00
can be the same as f
WTCLK
WTCLK Frequency
Max. period of INTWT0UV
31.25 KHz
32.768 KHz (typ.)
30 KHz (typ.)
16
– 1.
Watch Timer (WT)
15
will yield a
or
LCDCLK
a
2.097 s
2.0 s
2.184533 s

Advertisement

Table of Contents
loading

Table of Contents