ATtiny13 Atmel Corporation, ATtiny13 Datasheet - Page 158
![no-image](/images/manufacturer_photos/0/0/79/atmel_corporation_sml.jpg)
ATtiny13
Manufacturer Part Number
ATtiny13
Description
Manufacturer
Atmel Corporation
Specifications of ATtiny13
Flash (kbytes)
1 Kbytes
Pin Count
8
Max. Operating Frequency
20 MHz
Cpu
8-bit AVR
Hardware Qtouch Acquisition
No
Max I/o Pins
6
Ext Interrupts
6
Usb Speed
No
Usb Interface
No
Graphic Lcd
No
Video Decoder
No
Camera Interface
No
Adc Channels
4
Adc Resolution (bits)
10
Adc Speed (ksps)
15
Analog Comparators
1
Resistive Touch Screen
No
Temp. Sensor
No
Crypto Engine
No
Sram (kbytes)
0.06
Eeprom (bytes)
64
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
1
Output Compare Channels
2
Pwm Channels
2
32khz Rtc
No
Calibrated Rc Oscillator
Yes
Available stocks
Company
Part Number
Manufacturer
Quantity
Price
Part Number:
ATtiny13-10SSU
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Part Number:
ATtiny13-12SI
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Part Number:
ATtiny13-16PI
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Part Number:
ATtiny13-20MI
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Company:
Part Number:
ATtiny13-20PU
Manufacturer:
NXP
Quantity:
2 000
Company:
Part Number:
ATtiny13-20PU
Manufacturer:
Atmel
Quantity:
37 287
Part Number:
ATtiny13-20SSI
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Company:
Part Number:
ATtiny13-20SSU-SL383
Manufacturer:
ATMEL
Quantity:
4 132
Company:
Part Number:
ATtiny13A-MMU
Manufacturer:
DP
Quantity:
34 000
Company:
Part Number:
ATtiny13A-MMUR
Manufacturer:
TI
Quantity:
4 430
21. Instruction Set Summary
158
Mnemonics
RCALL
BREQ
BRCC
BRGE
BRHC
ADIW
RJMP
ICALL
CPSE
SBRC
SBRS
BRBS
BRBC
BRNE
BRCS
BRSH
BRLO
BRPL
BRHS
BRTS
BRTC
BRVS
BRVC
SBIW
ANDI
BRMI
BRLT
BRID
SUBI
SBCI
EOR
COM
NEG
IJMP
RETI
SBIC
SBIS
BRIE
ADD
ADC
SUB
SBC
AND
SBR
CBR
DEC
CLR
SER
RET
CPC
ROL
ORI
TST
LSL
LSR
INC
CPI
SBI
CBI
OR
CP
ATtiny13
Operands
Rd, Rr
Rd, Rr
Rd, Rr
Rd, Rr
Rd, Rr
Rd, Rr
Rd, Rr
Rd,Rr
Rd,Rr
Rd,Rr
Rdl,K
Rd, K
Rd, K
Rdl,K
Rd, K
Rd, K
Rd,K
Rd,K
Rd,K
Rr, b
Rr, b
P, b
P, b
s, k
s, k
P,b
P,b
Rd
Rd
Rd
Rd
Rd
Rd
Rd
Rd
Rd
Rd
k
k
k
k
k
k
k
k
k
k
k
k
k
k
k
k
k
k
k
k
ARITHMETIC AND LOGIC INSTRUCTIONS
BIT AND BIT-TEST INSTRUCTIONS
BRANCH INSTRUCTIONS
Subtract with Carry Constant from Reg.
Logical AND Register and Constant
Logical OR Register and Constant
Branch if Greater or Equal, Signed
Branch if Overflow Flag is Cleared
Compare Register with Immediate
Subtract with Carry two Registers
Branch if Less Than Zero, Signed
Skip if Bit in I/O Register Cleared
Branch if Half Carry Flag Cleared
Subtract Constant from Register
Subtract Immediate from Word
Skip if Bit in I/O Register is Set
Branch if Overflow Flag is Set
Skip if Bit in Register Cleared
Branch if Status Flag Cleared
Add with Carry two Registers
Branch if Half Carry Flag Set
Skip if Bit in Register is Set
Branch if Interrupt Disabled
Branch if Interrupt Enabled
Rotate Left Through Carry
Branch if Same or Higher
Branch if Status Flag Set
Branch if T Flag Cleared
Relative Subroutine Call
Add Immediate to Word
Exclusive OR Registers
Branch if Carry Cleared
Clear Bit in I/O Register
Compare, Skip if Equal
Subtract two Registers
Logical AND Registers
Clear Bit(s) in Register
Test for Zero or Minus
Set Bit in I/O Register
Logical OR Registers
Set Bit(s) in Register
Compare with Carry
Branch if T Flag Set
One’s Complement
Two’s Complement
Indirect Jump to (Z)
Branch if Not Equal
Branch if Carry Set
Add two Registers
Subroutine Return
Indirect Call to (Z)
Logical Shift Right
Description
Logical Shift Left
Interrupt Return
Branch if Lower
Branch if Minus
Branch if Equal
Clear Register
Relative Jump
Branch if Plus
Set Register
Decrement
Increment
Compare
if (SREG(s) = 1) then PC←PC+k + 1
if (SREG(s) = 0) then PC←PC+k + 1
Rd(0)←C,Rd(n+1)← Rd(n),C←Rd(7)
if (N ⊕ V= 0) then PC ← PC + k + 1
if (N ⊕ V= 1) then PC ← PC + k + 1
if (T = 1) then PC ← PC + k + 1
if (C = 1) then PC ← PC + k + 1
if (C = 0) then PC ← PC + k + 1
if (C = 0) then PC ← PC + k + 1
if (C = 1) then PC ← PC + k + 1
if (N = 1) then PC ← PC + k + 1
if (N = 0) then PC ← PC + k + 1
if (H = 1) then PC ← PC + k + 1
if (H = 0) then PC ← PC + k + 1
if (Z = 1) then PC ← PC + k + 1
if (Z = 0) then PC ← PC + k + 1
if (T = 0) then PC ← PC + k + 1
if (V = 1) then PC ← PC + k + 1
if (V = 0) then PC ← PC + k + 1
if ( I = 1) then PC ← PC + k + 1
if ( I = 0) then PC ← PC + k + 1
if (Rd = Rr) PC ← PC + 2 or 3
if (Rr(b)=0) PC ← PC + 2 or 3
if (Rr(b)=1) PC ← PC + 2 or 3
Rd(n+1) ← Rd(n), Rd(0) ← 0
Rd(n) ← Rd(n+1), Rd(7) ← 0
if (P(b)=0) PC ← PC + 2 or 3
if (P(b)=1) PC ← PC + 2 or 3
Rdh:Rdl ← Rdh:Rdl + K
Rdh:Rdl ← Rdh:Rdl - K
Rd ← Rd • (0xFF - K)
Rd ← Rd + Rr + C
Rd ← Rd - Rr - C
PC ← PC + k + 1
PC ← PC + k + 1
Rd ← 0xFF − Rd
Rd ← 0x00 − Rd
Rd ← Rd - K - C
Rd ← Rd ⊕ Rd
Rd ← Rd ⊕ Rr
Rd ← Rd • Rd
Operation
Rd ← Rd + Rr
Rd ← Rd • Rr
Rd ← Rd v Rr
PC ← STACK
PC ← STACK
Rd ← Rd - Rr
Rd ← Rd • K
Rd ← Rd v K
Rd ← Rd v K
Rd ← Rd + 1
Rd ← Rd − 1
Rd ← Rd - K
I/O(P,b) ← 1
I/O(P,b) ← 0
Rd ← 0xFF
Rd − Rr − C
PC ← Z
PC ← Z
Rd − Rr
Rd − K
Z, N,V,C,H
Z, N,V,C,H
Z, N,V,C,H
Z,C,N,V,H
Z,C,N,V,H
Z,C,N,V,S
Z,C,N,V,H
Z,C,N,V,H
Z,C,N,V,H
Z,C,N,V,H
Z,C,N,V,S
Z,C,N,V,H
Z,C,N,V
Z,C,N,V
Z,C,N,V
Z,C,N,V
Flags
Z,N,V
Z,N,V
Z,N,V
Z,N,V
Z,N,V
Z,N,V
Z,N,V
Z,N,V
Z,N,V
Z,N,V
Z,N,V
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
I
2535J–AVR–08/10
#Clocks
1/2/3
1/2/3
1/2/3
1/2/3
1/2/3
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1/2
1
1
2
1
1
1
1
2
1
1
1
1
1
1
1
1
1
1
1
1
1
1
2
2
3
3
4
4
1
1
1
2
2
1
1
1