Technical information
2-18
3800 GROUP USER’S MANUAL
APPLICATION
2.2 Timer
Fig. 2.2.18 Setting of related registers [Measurement of frequency]
0
PREY
Prescaler Y (Address : 26
16)
Set “division ratio – 1”
255
TY
Timer Y (Address : 27
16)
Set “255” to this register immediately before
counting pulse.
(After a certain time, this value is decreased by
the number of input pulses)
1
Timer Y interrupt enable bit : Interrupt disabled
ICON1
Interrupt control register 1 (Address : 3E
16)
0
Judgment of Timer Y interrupt request bit
(When this bit is set to “1” at reading out
the count value of the Timer Y (address : 27
16),
256 pulses or more are input (at setting 255 to
the Timer Y).)
IREQ1
Interrupt request register 1 (Address : 3C
16)
1
CNTR1 active edge switch bits : Count at falling edge
Timer Y count stop bit : Count stop
Set to “0” at starting to count.
Timer Y operating mode bit : Event counter mode
TM
Timer XY mode register (Address : 23
16)
b7 b0
01
Prescaler 12 (Address : 2016)
b7 b0
63
PRE12
7
T1
Timer 1 (Address : 21
16)
b7 b0
b7 b0
b7 b0
b7 b0
0
Timer 1 interrupt enable bit : Interrupt enabled
b7 b0
1