Compiling for a particular way of updating application

Comments

2 comments

  • Avatar
    Jon Elliott

    You can change where your program is placed in memory by modifying the memory segment definitions in your memory map files. So for example, you could reduce the size of the FLASH memory segment to half the size in both your bootloader and application memory map files and in your application memory map file you would increase the start address of the FLASH segment appropriately.

    See http://www.rowleydownload.co.uk/arm/documentation/ide_section_placement.htm for more information on memory map and section placement files.

    0
    Comment actions Permalink
  • Avatar
    Shotaro Kikugawa

    Thanks for responding.

    This is what I am doing now, where I'm allocating some memory in flash program space for bootloader and the rest for the application. But I think I need to add more details on what I want to do.

    I have a 128K part, so I have 8K for bootloader. I want to split the remaining 120K into two 60K chunks. The compiling process will generate a .hex file for uploading. But I don't want to have two hex files for say the lower 60K and the upper 60K. I was wondering if it was possible to make just one hex file that will run fine on either half.

    I'm also aware of the -fpic flag, I've been using that.

    0
    Comment actions Permalink

Please sign in to leave a comment.