AT90LS2343 ATMEL [ATMEL Corporation], AT90LS2343 Datasheet - Page 19

no-image

AT90LS2343

Manufacturer Part Number
AT90LS2343
Description
8-Bit Microcontroller with 2K Bytes of In-System Programmable Flash
Manufacturer
ATMEL [ATMEL Corporation]
Datasheets

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
AT90LS2343-4SI
Manufacturer:
FUJI
Quantity:
12
Stack Pointer – SPL
Reset and Interrupt
Handling
1004D–09/01
• Bit 0 – C: Carry Flag
The carry flag C indicates a carry in an arithmetical or logical operation. See the Instruc-
tion Set description for detailed information.
Note that the Status Register is not automatically stored when entering an interrupt rou-
tine and restored when returning from an interrupt routine. This must be handled by
software.
An 8- bit r egister at I/O addres s $3D ( $5D) for ms the stack pointer of the
AT90S2323/2343. Eight bits are used to address the 128 bytes of SRAM in locations
$60 - $DF.
The Stack Pointer points to the data SRAM stack area where the Subroutine and Inter-
rupt stacks are located. This stack space in the data SRAM must be defined by the
program before any subroutine calls are executed or interrupts are enabled. The Stack
Pointer must be set to point above $60. The Stack Pointer is decremented by 1 when
data is pushed onto the Stack with the PUSH instruction and it is decremented by 2
when an address is pushed onto the stack with subroutine calls and interrupts. The
Stack Pointer is incremented by 1 when data is popped from the stack with the POP
instruction and it is incremented by 2 when an address is popped from the stack with
return from subroutine RET or return from interrupt RETI.
The AT90S2323/2343 provides two interrupt sources. These interrupts and the separate
reset vector each have a separate program vector in the program memory space. Both
interrupts are assigned individual enable bits that must be set (one) together with the
I-bit in the Status Register in order to enable the interrupt.
The lowest addresses in the program memory space are automatically defined as the
Reset and Interrupt vectors. The complete list of vectors is shown in Table 3. The list
also determines the priority levels of the interrupts. The lower the address, the higher
the priority level. RESET has the highest priority, and next is INT0 (the External Interrupt
Request 0), etc.
Table 3. Reset and Interrupt Vectors
Bit
$3D ($5D)
Read/Write
Initial Value
Vector No.
1
2
3
Program Address
R/W
SP7
7
0
$000
$001
$002
SP6
R/W
6
0
SP5
R/W
5
0
Source
RESET
INT0
TIMER0, OVF0
SP4
R/W
4
0
SP3
R/W
AT90S/LS2323/2343
3
0
Interrupt Definition
Hardware Pin, Power-on Reset and
Watchdog Reset
External Interrupt Request 0
Timer/Counter0 Overflow
R/W
SP2
2
0
SP1
R/W
1
0
SP0
R/W
0
0
SPL
19

Related parts for AT90LS2343