Renesas SH7781 User Manual

Page 838

Advertising
background image

18. Timer Unit (TMU)

Rev.1.00 Jan. 10, 2008 Page 808 of 1658
REJ09B0261-0100

Bit Bit

Name

Initial
Value R/W Description

7

6

ICPE1*

1

ICPE0*

1

0

0

R/W

R/W

Input Capture Control

These bits, provided in channel 2 only, specify whether
the input capture function is used, and control enabling
or disabling of interrupt generation when the function is
used.

The CKEG bits specify whether the rising edge or falling
edge of the TCLK pin is used to set the TCNT2 value in
TCPR2.

The TCNT2 value is set in TCPR2 only when the ICPF
bit in TCR2 is 0. When the ICPF bit is 1, TCPR2 is not
set in the event of input capture.

00: Input capture function is not used.

01: Reserved (setting prohibited)

10: Input capture function is used, but interrupt due to

input capture (TICPI2) is not enabled.

11: Input capture function is used, and interrupt due to

input capture (TICPI2) is enabled.

5

UNIE

0

R/W

Underflow Interrupt Control

Controls enabling or disabling of interrupt generation
when the UNF status flag is set to 1, indicating TCNT
underflow.

0: Interrupt due to underflow (TUNI) is disabled

1: Interrupt due to underflow (TUNI) is enabled

4

3

CKEG1

CKEG0

0

0

R/W

R/W

Clock Edge 1 and 0

These bits select the external clock input edge when an
external clock that is input from the TCLK pin is selected
or the input capture function is used.

00: Count/input capture register set on rising edge

01: Count/input capture register set on falling edge

1X: Count/input capture register set on both rising and

falling edges

Advertising