参数资料
型号: S3C72N5XX-QW
元件分类: 微控制器/微处理器
英文描述: 4-BIT, MROM, 6 MHz, MICROCONTROLLER, PQFP80
封装: 14 X 20 MM, QFP-80
文件页数: 124/215页
文件大小: 1419K
代理商: S3C72N5XX-QW
第1页第2页第3页第4页第5页第6页第7页第8页第9页第10页第11页第12页第13页第14页第15页第16页第17页第18页第19页第20页第21页第22页第23页第24页第25页第26页第27页第28页第29页第30页第31页第32页第33页第34页第35页第36页第37页第38页第39页第40页第41页第42页第43页第44页第45页第46页第47页第48页第49页第50页第51页第52页第53页第54页第55页第56页第57页第58页第59页第60页第61页第62页第63页第64页第65页第66页第67页第68页第69页第70页第71页第72页第73页第74页第75页第76页第77页第78页第79页第80页第81页第82页第83页第84页第85页第86页第87页第88页第89页第90页第91页第92页第93页第94页第95页第96页第97页第98页第99页第100页第101页第102页第103页第104页第105页第106页第107页第108页第109页第110页第111页第112页第113页第114页第115页第116页第117页第118页第119页第120页第121页第122页第123页当前第124页第125页第126页第127页第128页第129页第130页第131页第132页第133页第134页第135页第136页第137页第138页第139页第140页第141页第142页第143页第144页第145页第146页第147页第148页第149页第150页第151页第152页第153页第154页第155页第156页第157页第158页第159页第160页第161页第162页第163页第164页第165页第166页第167页第168页第169页第170页第171页第172页第173页第174页第175页第176页第177页第178页第179页第180页第181页第182页第183页第184页第185页第186页第187页第188页第189页第190页第191页第192页第193页第194页第195页第196页第197页第198页第199页第200页第201页第202页第203页第204页第205页第206页第207页第208页第209页第210页第211页第212页第213页第214页第215页
ADDRESS SPACES
S3C72N8/P72N8/C72N5/P72N5
2-12
STACK OPERATIONS
STACK POINTER (SP)
The stack pointer (SP) is an 8-bit register that stores the address used to access the stack, an area of data
memory set aside for temporary storage of data and addresses. The SP can be read or written by 8-bit control
instructions. When addressing the SP, bit 0 must always remain cleared to logic zero.
F80H
SP3
SP2
SP1
"0"
F81H
SP7
SP6
SP5
SP4
There are two basic stack operations: writing to the top of the stack (push), and reading from the top of the stack
(pop). A push decrements the SP and a pop increments it so that the SP always points to the top address of the
last data to be written to the stack.
The program counter contents and program status word are stored in the stack area prior to the execution of a
CALL or a PUSH instruction, or during interrupt service routines. Stack operation is a LIFO (Last In-First Out)
type. The stack area is located in general-purpose data memory bank 0.
During an interrupt or a subroutine, the PC value and the PSW are saved to the stack area. When the routine has
completed, the stack pointer is referenced to restore the PC and PSW, and the next instruction is executed.
The SP can address stack registers in bank 0 (addresses 000H-0FFH) regardless of the current value of the
enable memory bank (EMB) flag and the select memory bank (SMB) flag. Although general-purpose register
areas can be used for stack operations, be careful to avoid data loss due to simultaneous use of the same
register(s).
Since the RESET value of the stack pointer is not defined in firmware, we recommend that you initialize the stack
pointer by program code to location 00H. This sets the first register of the stack area to 0FFH.
NOTE
A subroutine call occupies six nibbles in the stack; an interrupt requires six. When subroutine nesting or
interrupt routines are used continuously, the stack area should be set in accordance with the maximum
number of subroutine levels. To do this, estimate the number of nibbles that will be used for the
subroutines or interrupts and set the stack area correspondingly.
+
+ PROGRAMMING TIP — Initializing the Stack Pointer
To initialize the stack pointer (SP):
1.
When EMB = "1":
SMB
15
; Select memory bank 15
LD
EA,#00H
; Bit 0 of SP is always cleared to "0"
LD
SP,EA
; Stack area initial address (0FFH)
← (SP) – 1
2.
When EMB = "0":
LD
EA,#00H
LD
SP,EA
; Memory addressing area (00H–7FH, F80H–FFFH)
相关PDF资料
PDF描述
S3P72P9-QX 4-BIT, OTPROM, 6 MHz, MICROCONTROLLER, PQFP100
S3P7434-QZ 4-BIT, OTPROM, 6 MHz, MICROCONTROLLER, PQFP44
S3P7544-SM 4-BIT, OTPROM, 6 MHz, MICROCONTROLLER, PDSO24
S3C7544XX-AM 4-BIT, MROM, 6 MHz, MICROCONTROLLER, PDIP24
S3P8075XX-AT 8-BIT, OTPROM, 12 MHz, MICROCONTROLLER, PDIP64
相关代理商/技术参数
参数描述
S3C72N8 制造商:SAMSUNG 制造商全称:Samsung semiconductor 功能描述:single-chip CMOS microcontroller
S3C72P9 制造商:SAMSUNG 制造商全称:Samsung semiconductor 功能描述:SINGLE-CHIP MICROCONTROLLER HAS BEEN DESIGNED FOR HIGH PERFORMANCE USING
S3C72Q5 制造商:SAMSUNG 制造商全称:Samsung semiconductor 功能描述:4?BIT CMOS MICROCONTROLLER USERS MANUAL
S3C7324 制造商:SAMSUNG 制造商全称:Samsung semiconductor 功能描述:The S3C7324 single-chip CMOS microcontroller has been designed for high performance using Samsungs newest 4-bit CPU core, SAM47
S3C7335 制造商:SAMSUNG 制造商全称:Samsung semiconductor 功能描述:The S3C7335 single-chip CMOS microcontroller has been designed for high performance using Samsungs newest 4-bit CPU core, SAM47