When the BOOTRST Fuse is programmed, the Boot section size set to 2K bytes and the
IVSEL bit in the MCUCR Register is set before any interrupts are enabled, the most typ-
ical and general program setup for the Reset and Interrupt Vector Addresses in
ATmega88 is:
Address Labels Code
Comments
;
.org 0xC00
0xC00
0xC01
0xC02
...
rjmp
rjmp
rjmp
...
RESET
; Reset handler
; IRQ0 Handler
; IRQ1 Handler
;
EXT_INT0
EXT_INT1
...
0xC19
rjmp
SPM_RDY
; Store Program Memory Ready
Handler
;
0xC1A
RESET: ldi
out
r16,high(RAMEND); Main program start
0xC1B
RAM
SPH,r16
; Set Stack Pointer to top of
0xC1C
ldi
r16,low(RAMEND)
SPL,r16
0xC1D
0xC1E
out
sei
; Enable interrupts
0xC1F
<instr> xxx
56
ATmega48/88/168
2545D–AVR–07/04