Samsung KS57C2308 Manual page 24

Single-chip cmos microcontroller
Table of Contents

Advertisement

ADDRESS SPACES
PROGRAM COUNTER (PC)
A 13-bit program counter (PC) stores addresses for instruction fetches during program execution (KS57C2316
microcontroller has 14-bit program counter, PC0–PC13). Whenever a reset operation or an interrupt occurs, bits
PC12 through PC0 (PC13 through PC0 for KS57C2316) are set to the vector address.
Usually, the PC is incremented by the number of bytes of the instruction being fetched. One exception is the
1-byte REF instruction which is used to reference instructions stored in the ROM.
PROGRAM STATUS WORD (PSW)
The program status word (PSW) is an 8-bit word that defines system status and program execution status and
which permits an interrupted process to resume operation after an interrupt request has been serviced. PSW
values are mapped as follows:
(MSB)
FB0H
IS1
FB1H
C
The PSW can be manipulated by 1-bit or 4-bit read/write and by 8-bit read instructions, depending on the specific
bit or bits being addressed. The PSW can be addressed during program execution regardless of the current value
of the enable memory bank (EMB) flag.
Part or all of the PSW is saved to stack prior to execution of a subroutine call or hardware interrupt. After the
interrupt has been processed, the PSW values are popped from the stack back to the PSW address.
When a
is generated, the EMB and ERB values are set according to the
RESET
carry flag is left undefined (or the current value is retained). PSW bits IS0, IS1, SC0, SC1, and SC2 are all
cleared to logical zero.
PSW Bit Identifier
IS1, IS0
EMB
ERB
C
SC2, SC1, SC0
2-16
IS0
EMB
SC2
SC1
Table 2-5. Program Status Word Bit Descriptions
Description
Interrupt status flags
Enable memory bank flag
Enable register bank flag
Carry flag
Program skip flags
(LSB)
ERB
SC0
RESET
Bit Addressing
1, 4
1
1
1
8
KS57C2308/P2308/C2316/P2316
vector address, and the
Read/Write
R/W
R/W
R/W
R/W
R

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

P2308C2316P2316Ks57p2308Ks57c2316Ks57p2316

Table of Contents