Timer/Counter2
Prescaler
Figure 73. Prescaler for Timer/Counter2
AS2
EXCLK
clkI/O
Enable
TOSC2
TOSC1
0
1
clkT2S
32 kHz
Oscillator
10-BIT T/C PRESCALER
0
1
Clear
EXCLK
AS2
0
PSR2
CS20
CS21
CS22
TIMER/COUNTER2 CLOCK SOURCE
clkT2
The clock source for Timer/Counter2 is named clkT2S. clkT2S is by default connected to
the main system I/O clock clkIO. By setting the AS2 bit in ASSR, Timer/Counter2 is asyn-
chronously clocked from the TOSC oscillator or TOSC1 pin. This enables use of
Timer/Counter2 as a Real Time Counter (RTC).
A crystal can then be connected between the TOSC1 and TOSC2 pins to serve as an
independent clock source for Timer/Counter2. The Oscillator is optimized for use with a
32.768 kHz crystal. Setting AS2 and resetting EXCLK enables the TOSC oscillator.
Figure 74. Timer/Counter2 Crystal Oscillator Connections
12 - 22 pF
TOSC2
32.768 KHz
TOSC1
12 - 22 pF
GND
A external clock can also be used using TOSC1 as input. Setting AS2 and EXCLK
enables this configuration.
Figure 75. Timer/Counter2 External Clock Connections
TOSC2
TOSC1
NC
External
Clock
Signal
158
AT90CAN128
4250E–CAN–12/04