Epson S1C63000 Personal Computer User Manual


 
82 EPSON S1C63000 CORE CPU MANUAL
CHAPTER 4: INSTRUCTION SET
CALR [addr6] Call subroutine at relative location [addr6] 2 cycles
Function: ([(SP1-1)*4+3]~[(SP1-1)*4]) PC + 1, SP1 SP1 - 1, PC PC + [addr6] + 1
(addr6 = 0000H–003FH)
Saves the address next to this instruction to the stack as a return address, then adds the content
of the data memory (0000H–003FH) specified with the addr6 to that address to unconditionally
call the subroutine started from the address. Branch destination range is the next address of
this instruction +0 to 15.
Code:
Mnemonic MSB LSB
CALR [addr6] 1111100a5a4a3a2a1a01F00H–1F3FH
Flags: EICZ
–––
Mode: 6-bit absolute
Extended addressing: Invalid
CALR sign8 Call subroutine at relative location sign8 1 cycle
Function: ([(SP1-1)*4+3]~[(SP1-1)*4]) PC + 1, SP1 SP1 - 1, PC PC + sign8 + 1 (sign8 = -128~127)
Saves the address next to this instruction to the stack as a return address, then adds the related
address specified with the sign8 to that address to unconditionally call the subroutine started
from the address. Branch destination range is the next address of this instruction -128 to +127.
Code:
Mnemonic MSB LSB
CALR sign8 00010s7s6s5s4s3s2s1s00200H–02FFH
Flags: EICZ
–––
Mode: Signed 8-bit PC relative
Extended addressing: Valid
Extended LDB %EXT,imm8
operation: CALR sign8 ([(SP1-1)4+3]~[(SP1-1)4]) PC + 1, SP1 SP1 - 1,
PC PC + sign16 + 1
(sign16 = -32768 to 32767, upper 8-bit: imm8, lower 8-bit: sign8)