External Clock Mode - Epson S1C17001 Technical Manual

Cmos 16-bit single chip microcontroller
Table of Contents

Advertisement

11.2.2 External Clock Mode

External clock mode uses the clock and pulses input via the input/output port as a count clock. These inputs can
also be used as an event counter. Timer operations other than the input clock are the same as for internal clock
mode.
External clock input port
The following input ports are used for external clock or pulse input.
Confirm that the input/output ports used for external clock or pulse input are set to input mode (the default set-
ting). No pin function selection is needed. While the input/output ports function as general purpose inputs, the
input signal is also sent to the 16-bit timer.
The P07 and P06 ports used by 16-bit timer Ch.1 and Ch.2 incorporate chattering filter circuits and can also be
used as EXCLx inputs. For instructions on controlling chattering filter circuits, see "10.6 P0 Port Chattering
Filter Function."
Signal polarity selection
CKACTV (D10/T16_CTLx register) is used in this mode to select the falling edge or rising edge of the input
signal for counting.
∗ CKACTV: External Clock Active Level Select Bit in the 16-bit Timer Ch.x Control (T16_CTLx) Register
(D10/0x4226/0x4246/0x4266)
Counting down uses the rising edge when CKACTV is 1 (default) and uses the falling edge when set to 0.
External input clock
PRUN
Counter (CKACTV = 1)
Counter (CKACTV = 0)
The 16-bit timer does not use the prescaler in this mode. If no other peripheral modules use the prescaler clock, the
prescaler can be stopped to reduce current consumption. (The prescaler clock is used for P0 port chattering filter-
ing.)
S1C17001 TECHNICAL MANUAL
Table 11.2.2.1: External clock input port
Timer channel
Input signal name
Ch.0
Ch.1
Ch.2
n
n-1 n-2 n-3 n-4 n-5 n-6 n-7 n-8 n-9 n-10
n
n-1 n-2 n-3 n-4 n-5 n-6 n-7 n-8 n-9 n-10
Figure 11.2.2.1: External clock mode count
Input/output port pin
EXCL0
EXCL1
EXCL2
EPSON
11 16-BIT TIMER (T16)
P16
P07
P06
109

Advertisement

Table of Contents
loading

Table of Contents