Hitachi H8/3022 Hardware Manual page 242

H8/3022 series hitachi single-chip microcomputer
Table of Contents

Advertisement

Input selection
Select input-capture input
Start counter
Input capture
Figure 8-23 Setup Procedure for Input Capture (Example)
• Examples of input capture
Figure 8-24 illustrates input capture when the falling edge of TIOCB and both edges of TIOCA
are selected as capture edges. TCNT is cleared by input capture into GRB.
TCNT value
H'0180
H'0160
H'0005
H'0000
TIOCB
TIOCA
GRA
GRB
230
1.
Set TIOR to select the input capture function of a
general register and the rising edge, falling edge,
or both edges of the input capture signal. Clear the
port data direction bit to 0 before making these
TIOR settings.
1
2
2.
Set the STR bit to 1 in TSTR to start the timer
counter.
H'0005
Figure 8-24 Input Capture (Example)
Counter cleared by TIOCB
input (falling edge)
H'0160
H'0180
Time

Advertisement

Table of Contents
loading

This manual is also suitable for:

H8/3021H8/3020H8/3022 f-ztat

Table of Contents