![Intel 8XC196NT User Manual Download Page 80](http://html1.mh-extra.com/html/intel/8xc196nt/8xc196nt_user-manual_2072210080.webp)
4-13
MEMORY PARTITIONS
4.2.5.1
General-purpose Register RAM
The lower register file contains general-purpose register RAM. The stack pointer locations can
also be used as general-purpose register RAM when stack operations are not being performed.
The RALU can access this memory directly, using direct addressing.
The upper register file also contains general-purpose register RAM. The RALU normally uses
indirect or indexed addressing to access the RAM in the upper register file. Windowing enables
the RALU to use direct addressing to access this memory. (See Chapter 3, “Programming Con-
siderations,” for a discussion of addressing modes.) Windowing provides fast context switching
of interrupt tasks and faster program execution. (See “Windowing” on page 4-15.) PTS control
blocks and the stack are most efficient when located in the upper register file.
4.2.5.2
Stack Pointer (SP)
Memory locations 0018H and 0019H contain the stack pointer (SP). The SP contains the address
of the stack. The SP must point to a word (even) address that is two bytes (for 64-Kbyte mode)
or four bytes (for 1-Mbyte mode) greater than the desired starting address. Before the CPU exe-
cutes a subroutine call or interrupt service routine, it decrements the SP (by two in 64-Kbyte
mode; by four in 1-Mbyte mode). Next, it copies (PUSHes) the address of the next instruction
from the program counter onto the stack. It then loads the address of the subroutine or interrupt
service routine into the program counter. When it executes the return-from-subroutine (RET) in-
struction at the end of the subroutine or interrupt service routine, the CPU loads (POPs) the con-
tents of the top of the stack (that is, the return address) into the program counter. Finally, it
increments the SP (by two in 64-Kbyte mode; by four in 1-Mbyte mode).
Table 4-7. Register File Memory Addresses
Address
Range
Description
Addressing Modes
03FFH
0100H
General-purpose register RAM
(upper register file)
Indirect or indexed addressing; direct addressing if windowed
00FFH
001AH
General-purpose register RAM
(lower register file)
Direct, indirect, or indexed addressing
0019H
0018H
Stack pointer (SP)
(lower register file)
Direct,indirect, or indexed addressing
0017H
0000H
CPU SFRs
(lower register file)
Direct,indirect, or indexed addressing
Summary of Contents for 8XC196NT
Page 1: ...8XC196NT Microcontroller User s Manual...
Page 2: ...8XC196NT Microcontroller User s Manual June 1995 Order Number 272317 003...
Page 22: ...1 Guide to This Manual...
Page 23: ......
Page 35: ......
Page 36: ...2 Architectural Overview...
Page 37: ......
Page 49: ......
Page 50: ...3 Programming Considerations...
Page 51: ......
Page 66: ...4 Memory Partitions...
Page 67: ......
Page 104: ...5 Standard and PTS Interrupts...
Page 105: ......
Page 147: ......
Page 148: ...6 I O Ports...
Page 149: ......
Page 176: ...7 Serial I O SIO Port...
Page 177: ......
Page 194: ...8 Synchronous Serial I O SSIO Port...
Page 195: ......
Page 211: ......
Page 212: ...9 Slave Port...
Page 213: ......
Page 231: ......
Page 232: ...10 Event Processor Array EPA...
Page 233: ......
Page 270: ...11 Analog to digital Converter...
Page 271: ......
Page 291: ......
Page 292: ...12 Minimum Hardware Considerations...
Page 293: ......
Page 306: ...13 Special Operating Modes...
Page 307: ......
Page 317: ......
Page 318: ...14 Interfacing with External Memory...
Page 319: ......
Page 362: ...15 Programming the Nonvolatile Memory...
Page 363: ......
Page 408: ...A Instruction Set Reference...
Page 409: ......
Page 476: ...B Signal Descriptions...
Page 477: ......
Page 493: ......
Page 494: ...C Registers...
Page 495: ......
Page 565: ......
Page 566: ...Glossary...
Page 567: ......
Page 580: ...Index...
Page 581: ......
Page 597: ......