MSPM0L1306: IAR linker flash region settings

Part Number: MSPM0L1306

Tool/software:

Hi team,

My customer would like to change the flash region configuration on IAR.

They want to add another region for their data parameter.

Currently the settings available only for code and vector region.

How could we add another region on the IAR ?

Best regards,

Kenley

  • Hello Kenley,

    So in your meaning, the IROM1 is the vector region and the IROM2 is the code region, and you want to add another region, right? Maybe you need to modify the icf file, and I recommend you to contact with IAR engineer on their website, they can teach you how to modify the icf files to add more region.

    Best Regards,

    Janz Bai

  • Hi Janz

    Yes that’s right.

    I have tried to contact engineer of IAR in Japan but they are saying that TI are the one who set this and ask me to confirm internally.

    best regards,

    Kenley

  • Hello Kenley,

    It is amazing. In fact, this function is not needed in MSP but in other MCU competitors, I believe. And I think they know how to complete this function setting. Fine, I can help you to contact with Chinese IAR engineer by email and I  think he will reply to me soon next Monday

    Best Regards,

    Janz Bai

  • Hello Kenley,

    You can refer to this response from IAR technical engineer:

    In IAR ILINKER, you can define a new region to represent a flash region, for example:

    define region ROM3 = Mem:[from 0x00000 size 0x10000];

     

    Then you can put a block or section into that region:

    define region FUNC_region = mem:[ from 0x70000 to 0x70FFF ];
    place in FUNC_region { readonly section MY_FUNC };

     

    define region UTILITIES_region = mem:[ from 0x71000 to 0x71FFF ];
    place in UTILITIES_region { readonly object Utilities.o };

    You can learn more on the Help->C/C++ Development Guide -> Chapter: Linking using ILINK 

    Best Regards,

    Janz Bai

  • Hi Janz

    Thank you for your support.

    Noted.

    Let me share them to customer.

    Best regards,

    Kenley

  • Hello Kenley,

    You are welcome and I will close this E2E.

    Best Regards,

    Janz Bai

  • Hi Janz,

    Sorry but i have additional question regarding this thread.

    Do you know whether customer would get a warning if they write their code over than memory defined ?

    Let's say they define the ROM3 as following but the code they are writing on that region, it is more than 0x10000~. Will they get any warning when flashing and blocked ?

    define region ROM3 = Mem:[from 0x00000 size 0x10000];

    Best regards,

    Kenley

  • Hello Kenley,

    I recommend customer set the memory size according to their factual usage and don't over the memory defined. And if you must know whether it would get a warning, I recommend you can contact IAR engineer and ask for more detailed information from them.

    Best Regards,

    Janz Bai