ATtiny261 Atmel Corporation, ATtiny261 Datasheet - Page 83

no-image

ATtiny261

Manufacturer Part Number
ATtiny261
Description
Manufacturer
Atmel Corporation
Datasheets

Specifications of ATtiny261

Flash (kbytes)
2 Kbytes
Pin Count
20
Max. Operating Frequency
20 MHz
Cpu
8-bit AVR
# Of Touch Channels
4
Hardware Qtouch Acquisition
No
Max I/o Pins
16
Ext Interrupts
16
Usb Speed
No
Usb Interface
No
Spi
1
Twi (i2c)
1
Graphic Lcd
No
Video Decoder
No
Camera Interface
No
Adc Channels
11
Adc Resolution (bits)
10
Adc Speed (ksps)
15
Analog Comparators
1
Resistive Touch Screen
No
Temp. Sensor
Yes
Crypto Engine
No
Sram (kbytes)
0.12
Eeprom (bytes)
128
Self Program Memory
YES
Dram Memory
No
Nand Interface
No
Picopower
No
Temp. Range (deg C)
-40 to 85
I/o Supply Class
1.8 to 5.5
Operating Voltage (vcc)
1.8 to 5.5
Fpu
No
Mpu / Mmu
no / no
Timers
2
Output Compare Channels
6
Input Capture Channels
1
Pwm Channels
6
32khz Rtc
No
Calibrated Rc Oscillator
Yes

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
ATtiny261-15MAZ
Manufacturer:
TI
Quantity:
15
Part Number:
ATtiny261-15MZ
Manufacturer:
ATMEL
Quantity:
5 000
Part Number:
ATtiny261-15MZ
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Part Number:
ATtiny261-15XZ
Manufacturer:
Micrel
Quantity:
116
Part Number:
ATtiny261-20MU
Manufacturer:
AVNET
Quantity:
20 000
Part Number:
ATtiny261-20PU
Manufacturer:
ATMEL
Quantity:
256
Part Number:
ATtiny261-20SU
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Part Number:
ATtiny261-XZ
Manufacturer:
ATMEL
Quantity:
5
Company:
Part Number:
ATtiny261A-SU
Quantity:
7 000
Company:
Part Number:
ATtiny261V-10MU
Quantity:
496
Part Number:
ATtiny261V-10SU
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
11.9.1
2588E–AVR–08/10
Reusing the temporary high byte register
The following code examples show how to do an atomic write of the TCNT0H/L register con-
tents. Writing any of the OCR0A/B registers can be done by using the same principle.
Note:
The assembly code example requires that the r17:r16 register pair contains the value to be writ-
ten to TCNT0H/L.
If writing to more than one 16-bit register where the high byte is the same for all registers written,
then the high byte only needs to be written once. However, note that the same rule of atomic
operation described previously also applies in this case.
Assembly Code Example
TIM0_WriteTCNT0:
C Code Example
void TIM0_WriteTCNT0( unsigned int i )
{
}
; Save global interrupt flag
in r18,SREG
; Disable interrupts
cli
; Set TCNT0 to r17:r16
out TCNT0H,r17
out TCNT0L,r16
; Restore global interrupt flag
out SREG,r18
ret
unsigned char sreg;
/* Save global interrupt flag */
sreg = SREG;
/* Disable interrupts */
_CLI();
/* Set TCNT0 to i */
TCNT0H = (i >> 8);
TCNT0L = (unsigned char)i;
/* Restore global interrupt flag */
SREG = sreg;
See
“Code Examples” on page
6.
83

Related parts for ATtiny261