2 ;***************************************************************************
\r
3 ;* A P P L I C A T I O N N O T E F O R T H E A V R F A M I L Y
\r
6 ;* File Name :"tn12.inc"
\r
7 ;* Title :Register/Bit Definitions for the ATtiny12
\r
10 ;* Support telephone :+47 72 88 43 88 (ATMEL Norway)
\r
11 ;* Support fax :+47 72 88 43 99 (ATMEL Norway)
\r
12 ;* Support E-mail :avr@atmel.com
\r
13 ;* Target MCU :ATtiny12
\r
16 ;* When including this file in the assembly program file, all I/O register
\r
17 ;* names and I/O register bit names appearing in the data book can be used.
\r
18 ;* In addition, the two registers forming the data pointer Z have been
\r
19 ;* assigned names ZL - ZH.
\r
21 ;* The Register names are represented by their hexadecimal address.
\r
23 ;* The Register Bit names are represented by their bit number (0-7).
\r
25 ;* Please observe the difference in using the bit names with instructions
\r
26 ;* such as "sbr"/"cbr" (set/clear bit in register) and "sbrs"/"sbrc"
\r
27 ;* (skip if bit in register set/cleared). The following example illustrates
\r
30 ;* in r16,PORTB ;read PORTB latch
\r
31 ;* sbr r16,(1<<PB6)+(1<<PB5) ;set PB6 and PB5 (use masks, not bit#)
\r
32 ;* out PORTB,r16 ;output to PORTB
\r
34 ;* in r16,TIFR ;read the Timer Interrupt Flag Register
\r
35 ;* sbrc r16,TOV0 ;test the overflow flag (use bit#)
\r
36 ;* rjmp TOV0_is_set ;jump if set
\r
37 ;* ... ;otherwise do something else
\r
38 ;***************************************************************************
\r
40 ;***** Specify Device
\r
43 ;***** I/O Register Definitions
\r
63 ;***** Bit Definitions
\r
143 .equ INT0addr=$001 ;External Interrupt0 Vector Address
\r
144 .equ PCINTaddr=$002 ;Pin change Interrupt Vector Address
\r
145 .equ OVF0addr=$003 ;Overflow0 Interrupt Vector Address
\r
146 .equ ERDYaddr =$004 ;EEPROM Interrupt Vector Address
\r
147 .equ ACIaddr =$005 ;Analog Comparator Interrupt Vector Address
\r