Keil™, An ARM® Company

Technical Support

BL51: LEAVING HOLES IN CODE SPACE


Information in this article applies to:

  • C51 Version 5.50

QUESTION


How do I locate one group of segments starting at one address, and another group starting at another address? Basically, I need to leave a hole in my CODE address space.

ANSWER

  1. Create a Linker Command File. In µVision, select Options | BL51 Code-Banking Linker | Files and set the check box for "use external linker command file". Then click the CREATE button to see the format that µVision expects. Don't place your OBJ files in the linker command file, µVision will add them from the Project dialog box.
  2. Add a line like the following to the linker command file:
    .......& /* line continuation character */
    CODE(?PR?myseg1(3000),?PR?myseg2,?PR?myseg3, ?PR?myseg4(8000h), ?PR?myseg5, ?PR?myseg6)
    

    This places myseg1(), myseg2(), and myseg3() in order starting at 0x3000, and the other named segments in order starting at 0x8000.

Last Reviewed: Saturday, July 09, 2005


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