
- •Features
- •Pin Configuration
- •Disclaimer
- •Description
- •Pin Descriptions
- •AVCC
- •Port A (PA7..PA0)
- •Port B (PB7..PB0)
- •XTAL1
- •XTAL2
- •SRAM Data Memory
- •I/O Direct
- •Data Direct
- •Data Indirect with Displacement
- •Data Indirect
- •EEPROM Data Memory
- •I/O Memory
- •Status Register – SREG
- •Stack Pointer – SP
- •Reset Sources
- •Power-on Reset
- •External Reset
- •Brown-out Detection
- •Watchdog Reset
- •Clock Systems and their Distribution
- •CPU Clock – clkCPU
- •I/O Clock – clkI/O
- •Flash Clock – clkFLASH
- •ADC Clock – clkADC
- •Internal PLL for Fast Peripheral Clock Generation – clkPCK
- •Clock Sources
- •Crystal Oscillator
- •External RC Oscillator
- •External Clock
- •Interrupt Handling
- •Interrupt Response Time
- •External Interrupt
- •Pin Change Interrupt
- •Idle Mode
- •ADC Noise Reduction Mode
- •Power-down Mode
- •Standby Mode
- •Analog to Digital Converter
- •Analog Comparator
- •Brown-out Detector
- •Internal Voltage Reference
- •Watchdog Timer
- •Port Pins
- •Timer/Counters
- •Timer/Counter0 Prescaler
- •Timer/Counter1 Prescaler
- •8-bit Timer/Counter0
- •Timer/Counter0 – TCNT0
- •8-bit Timer/Counter1
- •Timer/Counter1 – TCNT1
- •Timer/Counter1 in PWM Mode
- •Watchdog Timer
- •Overview
- •Register Descriptions
- •USI Data Register – USIDR
- •USI Status Register – USISR
- •USI Control Register – USICR
- •Functional Descriptions
- •Three-wire Mode
- •SPI Slave Operation Example
- •Two-wire Mode
- •Start Condition Detector
- •Alternative USI Usage
- •4-bit Counter
- •12-bit Timer/Counter
- •Software Interrupt
- •Analog Comparator
- •Analog to Digital Converter
- •Features
- •Operation
- •ADC Conversion Result
- •ADLAR = 0
- •ADLAR = 1
- •I/O Ports
- •Introduction
- •Configuring the Pin
- •Reading the Pin Value
- •Alternate Port Functions
- •Alternate Functions of Port A
- •Alternate Functions Of Port B
- •Register Description for I/O Ports
- •Port A Data Register – PORTA
- •Port B Data Register – PORTB
- •Fuse Bits
- •Latching of Fuses
- •Signature Bytes
- •Calibration Byte
- •Signal Names
- •Parallel Programming
- •Enter Programming Mode
- •Chip Erase
- •Programming the Flash
- •Programming the EEPROM
- •Reading the Flash
- •Reading the EEPROM
- •Programming the Lock Bits
- •Reading the Signature Bytes
- •Reading the Calibration Byte
- •Serial Downloading
- •Data Polling Flash
- •Data Polling EEPROM
- •Electrical Characteristics
- •Absolute Maximum Ratings*
- •External Clock Drive Waveforms
- •External Clock Drive
- •ADC Characteristics – Preliminary Data
- •ATtiny26/L Register Summary
- •Ordering Information(1)
- •Packaging Information
- •Data Sheet Change Log for ATtiny26
- •Changes from Rev. 1477A-03/02 to Rev. 1477B-04/02
- •Table of Contents

ATtiny26(L)
Reset Sources |
The ATtiny26/L provides four sources of reset: |
||||||
|
• Power-on Reset. The MCU is reset when the supply voltage is below the Power-on |
||||||
|
Reset threshold (VPOT). |
||||||
|
|
|
|
|
|
pin as an External Reset, instead of I/O pin, |
|
|
• External Reset. To use the PB7/RESET |
||||||
|
unprogram (“1”) the RSTDISBL Fuse. The MCU is reset when a low level is present |
||||||
|
on the |
RESET |
pin for more than 50 ns. |
||||
|
• Watchdog Reset. The MCU is reset when the Watchdog timer period expires and |
||||||
|
the Watchdog is enabled. |
||||||
|
• Brown-out Reset. The MCU is reset when the supply voltage VCC is below the |
||||||
|
Brown-out Reset threshold (VBOT). |
||||||
|
During reset, all I/O Registers are then set to their initial values, and the program starts |
||||||
|
execution from address $000. The instruction placed in address $000 must be an RJMP |
||||||
|
– Relative Jump – instruction to the reset handling routine. If the program never enables |
||||||
|
an interrupt source, the interrupt vectors are not used, and regular program code can be |
||||||
|
placed at these locations. Figure 20 shows the reset logic for the ATtiny26/L. Table 3 |
||||||
|
shows the timing and electrical parameters of the reset circuitry for ATtiny26/L. |
||||||
|
Figure 20. Reset Logic for the ATtiny26/L |
||||||
|
|
|
|
|
|
DATA BUS |
|
MCU Status
Register (MCUSR)
PORF |
BORF |
EXTRF |
WDRF |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Brown-Out |
|
|
|
||
|
BODEN |
|
|
|
|
|
|
|
|
|
|
||||||
|
|
|
|
|
|
|
|
Reset Circuit |
|
|
|
||||||
BODLEVEL |
|
|
|
|
|
|
|
|
|
|
|||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Clock |
CK |
Delay Counters |
|
|
|
||||
Generator |
|
|
TIMEOUT |
|
|
|
|
|
|
CKSEL[3:0]
21
1477B–AVR–04/02

0
Table 3. |
Reset Characteristics |
|
|
|
|
|
|||
Symbol |
|
|
Parameter |
Condition |
Min |
Typ |
Max |
Units |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Power-on Reset Threshold |
|
|
1.4 |
2.3 |
V |
|
|
|
|
Voltage (rising) |
|
|
||||
VPOT |
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
|
|
|
|
Power-on Reset Threshold |
|
|
1.3 |
2.3 |
V |
||
|
|
|
|
|
|||||
|
|
|
Voltage (falling)(1) |
|
|
||||
|
|
|
|
|
|
|
|
||
VRST |
|
|
|
Pin Threshold Voltage |
|
0.1 |
|
0.9 |
VCC |
|
|
RESET |
|
|
|||||
tRST |
|
|
Minimum pulse width on |
|
|
50 |
|
ns |
|
|
|
RESET |
Pin |
|
|
|
|||
VBOT |
|
|
Brown-out Reset Threshold |
BODLEVEL = 1 |
2.5 |
2.7 |
3.2 |
V |
|
|
|
Voltage(2) |
|
|
|
|
|||
|
|
BODLEVEL = 0 |
3.7 |
4.0 |
4.2 |
||||
|
|
|
|
|
|
||||
|
|
|
|
|
|
|
|
|
|
tBOD |
|
|
Minimum low voltage period for |
BODLEVEL = 1 |
|
2 |
|
µs |
|
|
|
Brown-out Detection |
|
|
|
|
|
||
|
|
BODLEVEL = 0 |
|
2 |
|
µs |
|||
|
|
|
|
|
|
|
|||
|
|
|
|
|
|
|
|
|
|
VHYST |
|
|
Brown-out Detector hysteresis |
|
|
130 |
|
mV |
Notes: 1. The Power-on Reset will not work unless the supply voltage has been below VPOT (falling)
2.VBOT may be below nominal minimum operating voltage for some devices. For devices where this is the case, the device is tested down to VCC = VBOT during the production test. This guarantees that a Brown-out Reset will occur before VCC drops to a voltage where correct operation of the microcontroller is no longer guaranteed. The test is performed using BODLEVEL=1 for ATtiny26L and BODLEVEL=0 for ATtiny26. BODLEVEL=1 is not applicable for ATtiny26.
See start-up times from reset from “System Clock and Clock Options” on page 25. When the CPU wakes up from Power-down, only the clock counting part of the start-up time is used. The Watchdog Oscillator is used for timing the real-time part of the start-up time.
Power-on Reset |
A Power-on Reset (POR) pulse is generated by an On-chip Detection circuit. The detec- |
|
tion level is defined in Table 3 The POR is activated whenever VCC is below the |
|
detection level. The POR circuit can be used to trigger the Start-up Reset, as well as |
|
detect a failure in supply voltage. |
|
The Power-on Reset (POR) circuit ensures that the device is reset from Power-on. |
|
Reaching the Power-on Reset threshold voltage invokes a delay counter, which deter- |
|
mines the delay, for which the device is kept in RESET after VCC rise. The time-out |
|
period of the delay counter can be defined by the user through the CKSEL Fuses. The |
|
different selections for the delay period are presented in “System Clock and Clock |
|
Options” on page 25. The RESET signal is activated again, without any delay, when the |
|
VCC decreases below detection level. |
22 ATtiny26(L)
1477B–AVR–04/02

ATtiny26(L)
Figure 21. MCU Start-up, RESET Tied to VCC
|
|
|
|
|
|
|
VPOT |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
VCC |
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||
|
|
|
|
|
|
|
VRST |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|||
|
|
RESET |
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||
|
TIME-OUT |
|
|
|
tTOUT |
|
|
|
|
|
|
|
|
|
|||||||
|
|
|
|
|
|
|
|
|
|
|
|
||||||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||
|
INTERNAL |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||
|
RESET |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||
|
Figure 22. MCU Start-up, |
|
|
|
Controlled Externally |
||||||||||||||||
|
RESET |
||||||||||||||||||||
|
|
|
|
|
|
|
VPOT |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
VCC |
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
VRST |
|||||||
|
|
RESET |
|
|
|
|
|||||||||||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|||||||
|
TIME-OUT |
|
|
|
|
|
|
|
tTOUT |
|
|
|
|
||||||||
|
|
|
|
|
|
|
|
|
|
||||||||||||
|
|
|
|
|
|
|
|
|
|
||||||||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|||||||
|
INTERNAL |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||||
External Reset |
RESET |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|||||
An External Reset is generated by a low level on the |
|
|
|
pin. Reset pulses longer |
|||||||||||||||||
RESET |
|||||||||||||||||||||
|
than 500 ns will generate a reset, even if the clock is not running. Shorter pulses are not |
||||||||||||||||||||
|
guaranteed to generate a reset. When the applied signal reaches the Reset Threshold |
||||||||||||||||||||
|
Voltage – VRST – on its positive edge, the delay timer starts the MCU after the Time-out |
||||||||||||||||||||
|
period tTOUT has expired. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|||||||
|
Figure 23. External Reset During Operation |
VCC
RESET
VRST
t TOUT
TIME-OUT
INTERNAL
RESET
23
1477B–AVR–04/02

Brown-out Detection |
|
|
|
|
|
|
|
|
|
|
|
|
|
ATtiny26/L has an On-chip Brown-out Detection (BOD) circuit for monitoring the VCC |
||||||
|
level during the operation. The BOD circuit can be enabled/disabled by the fuse |
|||||
|
BODEN. When the BOD is enabled (BODEN programmed), and VCC decreases below |
|||||
|
the trigger level, the Brown-out Reset is immediately activated. When VCC increases |
|||||
|
above the trigger level, the Brown-out Reset is deactivated after a delay. The delay is |
|||||
|
defined by the user in the same way as the delay of POR signal, in Table 2. The trigger |
|||||
|
level for the BOD can be selected by the fuse BODLEVEL to be 2.7V (BODLEVEL |
|||||
|
unprogrammed), or 4.0V (BODLEVEL programmed). The trigger level has a hysteresis |
|||||
|
of 50 mV to ensure spike free Brown-out Detection. |
|
||||
|
The BOD circuit will only detect a drop in VCC if the voltage stays below the trigger level |
|||||
|
for longer than tBOD given in Table 3. |
|
||||
|
Figure 24. Brown-out Reset During Operation |
|
||||
|
VCC |
|
VBOT- |
VBOT+ |
||
|
|
|
|
|||
|
RESET |
|
|
|
|
|
|
TIME-OUT |
|
|
|
|
tTOUT |
|
INTERNAL |
|
|
|
|
|
|
RESET |
|
|
|
|
|
Watchdog Reset |
When the Watchdog times out, it will generate a short reset pulse of one CK cycle dura- |
|||||
|
tion. On the falling edge of this pulse, the delay timer starts counting the Time-out period |
|||||
|
tTOUT. Refer to page 58 for details on operation of the Watchdog. |
Figure 25. Watchdog Time-out
1 CK Cycle
24 ATtiny26(L)
1477B–AVR–04/02