Keil™, An ARM® Company

Technical Support

AX51: LOCATING AN ECODE SEGMENT AT A FIXED ADDRESS


Information in this article applies to:

  • C51 Version 7.00

QUESTION

I'm creating a small assembly program for the Philipx MX and I'm trying to locate code in the extended code space at a specific address. How should I do that?

ANSWER

The following example demonstrates one way to locate an ECODE segment at a specific address.

                CSEG    AT 0
                LJMP    RESET

MY_CODE_SEG     SEGMENT   CODE
RSEG    MY_CODE_SEG

RESET:
                EJMP    ECODE_FUNC


MY_ECODE_SEG    SEGMENT   ECODE   AT   0x820000
RSEG    MY_ECODE_SEG

ECODE_FUNC:
                INC     R0
                INC     R1
                JMP     ECODE_FUNC

                END

Last Reviewed: Wednesday, May 15, 2002


Did this article provide the answer you needed?
 
Yes
No
Not Sure