English
Language : 

GMS81504 Datasheet, PDF (31/54 Pages) List of Unclassifed Manufacturers – CMOS SINGLE-CHIP 8-BIT MICROCONTROLLER
HYUNDAI MicroElectronics
GMS81504
8-bit Capture Mode
The Timer 0 capture mode is set by bit CAP0 of timer
mode register TM0 as shown in Figure 19. In this
mode, Timer 1 still operates as an 8-bit timer/counter.
In 8-bit capture mode, Timer 1 can not be used as
capture mode.
The Timer/Counter register is incremented in response
internal or external input. This counting function is
same with normal timer mode, but Timer interrupt is
not generated. Timer/Counter still does the above, but
with the added feature that a edge transition at external
input INT0 pin causes the current value in the Timer 0
register T0, to be captured into registers CDR0, respec-
tively. After captured, Timer 0 register T0 is cleared
and restarts by hardware.
Caution:
The CDRx and TDRx are in same address.
In the capture mode, reading operation is read the
CDRx, not TDRx because path is opened to the
CDRx.
It has three transition modes: "falling edge", "rising
edge", "both edge" which are selected by interrupt
edge selection register IEDS (Refer to External inter-
rupt section). In addition, the transition at INT0 pin
generates an interrupt signal.
EC0 PIN
XIN PIN
TM0
MSB
CAP0
1
T1ST
X
T1SL1 T1SL0
≠0
≠0
T0ST
X
T0CN
X
T0SL1
X
LSB
T0SL0
X
ADDRESS: E2H
RESET VALUE: 00H
T0SL[1:0]
EDGE DETECTOR
÷4
÷ 16
÷ 64
PRESCALER
MUX
TIMER 0
0
1
T0CN
T0ST
0: Stop
1: Clear and Start
T0 (8-BITS)
CAPTURE
CDR0 (8-BITS)
INT0 PIN
IEDS[1:0]
T1SL[1:0] ≠ 00
MUX
T1ST
0: Stop
1: Clear and Start
T1 (8-BITS)
CLEAR
INT0IF
INT0
INTERRUPT
TIMER 1
COMPARATOR
TDR1 (8-BITS)
T1IF
F/F
TIMER 1
INTERRUPT
T1O PIN
Figure 19. 8-bit Capture Mode
31