English
Language : 

UPD784938 Datasheet, PDF (393/733 Pages) NEC – 16-Bit Single-Chip Microcontrollers
CHAPTER 14 WATCH TIMER
Two types of count clocks can be input to the watch timer: main clock (12.58 MHz (MAX.)) and watch clock (32.768 kHz).
These count clocks can be selected by the control register. The watch clock is input only to the watch timer, and not to
the CPU and other peripheral circuits. Therefore, the operating speed of the CPU cannot be slowed down by using the
watch clock.
The watch timer generates an interrupt signal with a 0.5-second interval (INTW) by dividing the count clock. At the same
time, it also sets an interrupt request flag (WIF: bit 7 of interrupt control register (WIC)).
The INTW generation interval can be changed to about 1 ms by changing the mode (fast forward mode: 512 times faster
than the normal mode). Also, the INTW generation interval can be set to 15.6 ms.
When the main clock is selected as the count clock, the watch timer stops at standby in STOP mode. However, it continues
operating in the IDLE and HALT modes. When the watch clock is selected as the count clock, the watch timer can continue
operating in any standby mode (it means any of STOP, IDLE, and HALT modes). The operation of the watch clock oscillator
is controlled by the watch timer mode register (WM).
Figure 14-1 shows the format of WM.
Figure 14-1. Watch Timer Mode Register (WM) Format
7
6
5
4
3
2
1
WM WM7 WM6 0 WM4 WM3 WM2 0
0 Address After reset R/W
0 0FF6FH 00H R/W
WM4 WM2 Watch Timer Operation Mode
0
0 Normal watch mode (generates
INTW at 0.5 s intervals)
1
0 Medium-fast forward mode (32
times faster than normal mode,
generates INTW at 15.6 ms
intervals)
0
1 Fast forward mode (512 times
faster than normal mode, generates
1
1 INTW at 0.98 ms intervals)
WM3
Watch Timer Operation Control
0 Clears division counter and stops counting
1 Starts operation of division counter
WM6 Watch Timer Operation Clock Specification
0 Main clock
1 Watch clock
WM7 Watch Clock Oscillator Operation Control
0 Stops watch clock oscillator
1 Operation watch clock oscillator
Caution The time from when the watch timer is started up until the first INTW occurs is less than 0.5 seconds.
This time becomes 0.5 seconds from the second and subsequent INTW occurrences.
Preliminary User’s Manual U13987EJ1V0UM00
393