English
Language : 

MC9S12T64 Datasheet, PDF (137/608 Pages) Motorola, Inc – Specification
Freescale Semiconductor, Inc.
Module Mapping Control (MMC)
Functional Description
modes, the new page value is provided by an immediate operand in the
instruction. In indexed-indirect variations of CALL, a pointer specifies
memory locations where the new page value and the address of the
called subroutine are stored. Using indirect addressing for both the new
page value and the address within the page allows values calculated at
run time rather than immediate values that must be known at the time of
assembly.
The RTC instruction terminates subroutines invoked by a CALL
instruction. RTC unstacks the PPAGE value and the return address and
refills the queue. Execution resumes with the next instruction after the
CALL.
During the execution of an RTC instruction, the CPU:
• Pulls the old PPAGE value from the stack
• Pulls the 16-bit return address from the stack and loads it into the
PC
• Writes the old PPAGE value into the PPAGE register
• Refills the queue and resumes execution at the return address
This sequence is uninterruptable; an RTC can be executed from
anywhere in memory, even from a different page of extended memory in
the expansion window.
The CALL and RTC instructions behave like JSR and RTS, except they
use more execution cycles. Therefore, routinely substituting CALL/RTC
for JSR/RTS is not recommended. JSR and RTS can be used to access
subroutines that are on the same page in expanded memory. However,
a subroutine in expanded memory that can be called from other pages
must be terminated with an RTC. And the RTC unstacks a PPAGE
value. So any access to the subroutine, even from the same page, must
use a CALL instruction so that the correct PPAGE value is in the stack.
Module Mapping Control (MMC)
For More Information On This Product,
Go to: www.freescale.com
MC9S12T64Revision 1.1.1