atmega323l ATMEL Corporation, atmega323l Datasheet - Page 25

no-image

atmega323l

Manufacturer Part Number
atmega323l
Description
Atmega323 8-bit Avr Microcontroller With 32k Bytes Of In-system Programmable Flash
Manufacturer
ATMEL Corporation
Datasheet
Reset Sources
1457G–AVR–09/03
When the BOOTRST Fuse is programmed, the boot section size set to 4K bytes and the
IVSEL bit in the GICR Register is set before any interrupts are enabled, the most typical
and general program setup for the Reset and Interrupt Vector Addresses are:
The ATmega323 has five sources of reset:
During Reset, all I/O Registers are set to their initial values, and the program starts exe-
cution from the Reset Vector. The instruction placed at the Reset Vector must be a JMP
an interrupt source, the Interrupt Vectors are not used, and regular program code can
be placed at these locations. This is also the case if the Reset Vector is in the Applica-
tion section while the Interrupt Vectors are in the Boot section or vice versa. The circuit
diagram in Figure 24 shows the Reset Logic. Table 5 and Table 6 define the timing and
electrical parameters of the reset circuitry.
Absolute Jump
$02a
$02b
$02c
;
.org $3800
$3800
Address Labels Code
$000
$001
$002
$003
$004
;
.org $3800
$3800
$3802
$3804
...
$3826
Power-on Reset. The MCU is reset when the supply voltage is below the Power-on
Reset threshold (V
External Reset. The MCU is reset when a low level is present on the RESET pin for
more than 500 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 V
Brown-out Reset threshold (V
JTAG AVR Reset. The MCU is reset as long as there is a logic one in the Reset
Register, one of the scan chains of the JTAG system.
MAIN:
instruction to the reset handling routine. If the program never enables
ldi
out
ldi
out
<instr>
jmp
jmp
jmp
...
jmp
ldi
out
<instr>
jmp
POT
).
r16,high(RAMEND); Main program start
SPH,r16
r16,low(RAMEND)
SPL,r16
RESET
EXT_INT0 ; IRQ0 Handler
EXT_INT1 ; IRQ1 Handler
...
TWSI
r16,low(RAMEND)
SPL,r16
RESET
xxx
xxx
BOT
; Reset handler
;
; Two-wire Serial Interface Interrupt Handler
).
Comments
; Set Stack Pointer to top of RAM
; Reset handler
ATmega323(L)
CC
is below the
25

Related parts for atmega323l