English
Language : 

M38002M4 Datasheet, PDF (60/173 Pages) Mitsubishi Electric Semiconductor – 8-BIT SINGLE-CHIP MICROCOMPUTER
APPLICATION
2.2 Timer
(2) Timer application example 1 : Clock function (measurement of 250 ms)
Outline : The input clock is divided by a timer so that the clock counts up every 250 ms.
Specifications : • The clock f(XIN) = 4.19 MHz (222 Hz) is divided by a timer.
• The clock is counted at intervals of 250 ms by the Timer X interrupt.
Figure 2.2.10 shows a connection of timers and a setting of division ratios, Figures 2.2.11 show a
setting of related registers, and Figure 2.2.12 shows a control procedure.
f(XIN) =
4.19 MHz
Fixed
1/16
Prescaler X
1/256
Timer X
Timer X interrupt request bit
The clock is divided by 4 by software.
1/256
0 or 1
250 ms
1/4
1 second
0 : No interrupt request
1 : Interrupt request
Fig. 2.2.10 Connection of timers and setting of division ratios [Clock function]
2-12
3800 GROUP USER’S MANUAL