The Timer Counter 0 - Tcnt0; The 8-Bit Timer/Counter1 - Atmel AVR ATtiny15L Advance Information

Microcontroller with 1k bytes flash
Hide thumbs Also See for AVR ATtiny15L:
Table of Contents

Advertisement

The Timer Counter 0 – TCNT0
Bit
7
$32
MSB
Read/Write
R/W
Initial value
0
The Timer/Counter0 is implemented as an up-counter with read and write access. If the Timer/Counter0 is written and a
clock source is present, the Timer/Counter0 continues counting in the timer clock cycle following the write operation.

The 8-bit Timer/Counter1

This module features a high-resolution and a high-accuracy usage with the lower prescaling opportunities. Timer/Counter1
can also be used as an accurate, high speed, 8-bit Pulse-width Modulator using clock speeds up to 25.6 MHz. In this mode,
Timer/Counter1 and the output compare registers serve as a stand-alone PWM. Refer to page 32 for a detailed description
of this function. Similarly, the high-prescaling opportunities make this unit useful for lower-speed functions or exact-timing
functions with infrequent actions.
Figure 21 shows the block diagram for Timer/Counter1.
Figure 21. Timer/Counter1 Block Diagram
8-BIT DATABUS
The two-status flags (overflow and compare match) are found in the Timer/Counter Interrupt Flag Register – TIFR. Control
signals are found in the Timer/Counter Control Register TCCR1. The interrupt enable/disable settings are found in the
Timer/Counter Interrupt Mask Register – TIMSK.
6
5
4
R/W
R/W
R/W
0
0
0
T/C1 OVER-
T/C1 A COMPARE
FLOW IRQ
TIMER INT. MASK
REGISTER (TIMSK)
T/C CLEAR
TIMER/COUNTER1
(TCNT1)
8-BIT COMPARATOR
T/C1 OUTPUT
COMPARE REGISTER A
COMPARE REGISTER B
(OCR1A)
3
2
R/W
R/W
0
0
T/C1 OC1A PIN/
MATCH IRQ
PORT PB1
(PWM OUTPUT)
TIMER INT. FLAG
REGISTER (TIFR)
REGISTER 1 (TCCR1)
T/C1 CONTROL
8-BIT COMPARATOR
T/C1 OUTPUT
(OCR1B)
ATtiny15L
1
0
LSB
TCNT0
R/W
R/W
0
0
T/C CONTROL
SFIOR
LOGIC
CK
PCK
27

Advertisement

Table of Contents
loading

Table of Contents