Siemens C500 User Manual page 91

Microcontroller family
Table of Contents

Advertisement

RET
Function:
Return from subroutine
Description:
RET pops the high and low-order bytes of the PC successively from the stack,
decrementing the stack pointer by two. Program execution continues at the
resulting address, generally the instruction immediately following an ACALL or
LCALL. No flags are affected.
Example:
The stack pointer originally contains the value 0B H . Internal RAM locations 0A H
and 0B H contain the values 23 H and 01 H , respectively. The instruction
RET
will leave the stack pointer equal to the value 09 H . Program execution will continue
at location 0123 H .
Operation:
RET
(PC15-8) ¬ ((SP))
(SP) ¬ (SP) Ð 1
(PC7-0) ¬ ((SP))
(SP) ¬ (SP) Ð 1
Encoding:
0 0 1 0
Bytes:
1
Cycles:
2
Semiconductor Group
0 0 1 0
4-65
Instruction Set
C500 Family
1998-04-01

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents