This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

One or more sections of your program falls into a memory region that is not writable

Other Parts Discussed in Thread: RM48L950, HALCOGEN

Hi,

I'm working with a RM48 Hercules HDK rev B.

When I start debug in CCSv5 the console says: "CortexR4: GEL Output: Memory Map Setup for Flash @ Address 0x0CortexR4: Loader: One or more sections of your program falls into a memory region that is not writable. These regions will not actually be written to the target. Check your linker configuration and/or memory map."

My project is generated by CCSv5/HalCoGen_v03.06.00  for RM48L950. I've not modified the default project settings of CCS.The HalCoGen setup includes ADC1 and ADC2, Het1, SCi2, RTi drivers. On HalCoGen I've only enabled a pair of interrupts and set the ADC. Debugging a previous simpler project all the chain is working flawless.

What can I control?

  • Matteo,

    Can you share the sys_link.cmd (from the source directory) and the .map file (from the debug directory) so I can have a look to your problem.

    By the way, be sure that the sys_link.cmd (linker command file) is used in your CCS project.

  • Here they are. Meanwhile the older project to has stopped working giving the same message....

    Where should I verify if my project uses the sys_link.cmd?

    RM48_files.zip
  • Matteo,

    Everything look good to me.

    In your CCS project, have you selected the correct part number when you've created the project?

    The next step will be to share your full project so I can try on my setup or at least the out file.

  • My project is in attachment. This one is the first test. Is a "hello word".

    Has worked flawless the first time but now it refuse to start giving the output message on object.

    Let me know.

    Thank you

    RM48_TEST1.zip
  • Hello Matteo,

    Which target configuration are you using to connect?

    Also, give this post a look: http://e2e.ti.com/support/microcontrollers/hercules/f/312/p/292516/1020825.aspx#1020825

  • Matteo,

    As John mentioned in his reply, there is no emulator defined in your project. So we don't know which one you are using.

    Here are some screen shot of your project properties.

    In this one, you can see that under "Connection" nothing is defined.

    Assuming you are using the default XDS100 on the HDK board, this is the definition you have to use.

    Now if you open the target configuration windows and go to project, you should see the following:

    To start your debug session, right click on RM48L950.ccxml and select "Launch Selected Configuration" as shown below.

    Now you should be able to download your code in your device.

    Please let me know if these information are useful to solve your problem.

  • Thank you for the answer. I've now set the connection as "XDS100v2" in the project general properties but runnig the debug session following the way you suggest ("launch selected configuration" on the RM48L950 target) bring to the Debug view as follow:

    where the target is labeled as "disconnected". If i try to connectd the target the situation changes as follow:

    And i I push the "resume" button that's the final situation:

    where my code is given as "running" but I don't see my debug message ("STARTING RM48_TEST1") on the Terminal.

    I've tried also to set the RM48L950.ccxml as default and run the RM48_TEST1 as usual (with the Debug button) but the result is the same as before (same console error message about not writable memory regions).

  • Matteo,

    This is normal. Because your code is programmed in the flash memory, as soon as you power the board the code is already executed.
    When you start your debug session and connect the target, halt the CPU and reset it using the system reset. Now the CPU should point to 0x0000_0000 (Reset exception) and if from their you run the code, you should execute your application. (Assuming there is no problem in your code)

    I will try running the project you've share and see what is going on.