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.

CCSTUDIO-C2000: Debug session fails to start with external memory section

Part Number: CCSTUDIO-C2000
Other Parts Discussed in Thread: TMS320F2809, TMDSEMU200-U

Hi Team, 

Starting a debug session in CCS V10.4.0 with my TMS320F2809 project fails because the .out file contains an external memory section defined beyond the FLASH segments . 

Is there a way to get CCS V10.4.0 to ignore this external memory section when a debug session begins?

 ----

Some background information:

  • The project compiles and links a large amount of static data (~200kB).
  • The static data is placed in an external memory section intended to be loaded in an external serial flash IC.
  • I use "hex2000.exe" to extract the static data and produce a binary data file ready for loading into the serial flash IC.
  • Reads and writes to the serial flash are done though an SPI peripheral of the F2809 when the code is running.
  • By manipulating a linker command file, I can get the debug session to start but generation of the static data file fails. That is:
    • I've tried a different MEMORY page (PAGE 2) and
    • I've tried different SECTION options ("type=NOLOAD" or "type=NOINIT") 
  • The project was foundered in CCS V5.
    • Flashing during the start of a debug session would ignore this external memory section.
    • The debug session would start every time.
    • I have successfully imported, compiled and linked the project in CCS V10.4.0.

Thank you.

-Mark

  • Hello Mark,

    fails because the .out file contains an external memory section defined beyond the FLASH segments . 

    Can you describe the failure in more detail? Are you getting a data verification error? Please provide any error messages in verbatim.

    Thanks

    ki

  • Hi Ki,

    The MEMORY and SECTION definitions for the external memory is defined as follows:

     

    MEMORY

                    {

                    PAGE 0:                 DATACARD (RI) :               origin = 0x00400000, length = 0x00020000

                    }

     

    SECTIONS

                    {

                    .menufile:           {VMC_CONST.obj, VMC_MODELS.obj} > DATACARD

                    }

     

    The command file for producing the external memory file is:

     

    IIV52.out

    --binary

    --order MS

     

    SECTIONS

                    {

                    .menufile

                    }

     

    ROMS

                    {

                    datacard              org = 0x00800000, len = 0x40000, romwidth = 8

                                    files = { appI.mnu }

                    }

     

    V5 CCS when starting a debug session with the emulator would produce this message in the ‘console’ view when flashing IIV52.out:

    C28xx: 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.”

     

    V10.4.0 when starting a debug session with the emulator produces this message in the ‘console’ view when flashing IIV52.out:

           “C28xx: File Loader: Verification failed: Attempted to write past the end of memory at 0x400000@Program

    C28xx: GEL: File: IIV52.out: Load failed.”

  • Interesting. In my CCS 10.4 installaton, I get a message similar to what you see in CCSv5.

    Do you have the debugger memory map configured the same for both CCSv5 and CCSv10.4? What are the verification settings for both both CCS versions?

  • Hi Ki,

    "Do you have the debugger memory map configured the same for both CCSv5 and CCSv10.4?"
    Do you mean "Debug Configurations"=>"Target" => "2809 Flash Settings" ? If so yes they are set up the same.

    "What are the verification settings for both both CCS versions?"
    "Debug Configurations"=>"Target" => "Program/Memory Load Options" => "Verification Options" . Both V5 and V10 are set to "Fast verification"

    I assumed the import of a project would configure the new project as close as possible and so I have not interfered with the debug configuration. I've checked the "Debug Configurations" and they mostly the same although V10 has many more options that are non-existent in V5.

    Also, the emulator i'm using with V10 is "Blackhawk TMDSEMU200-U". Could it have a loading check/limitation ?

  • "Do you have the debugger memory map configured the same for both CCSv5 and CCSv10.4?"
    Do you mean "Debug Configurations"=>"Target" => "2809 Flash Settings" ? If so yes they are set up the same.

    Actually, I am referring to:

    https://dev.ti.com/tirex/explore/node?node=APWSb4qHyQsv8ysq7uc1zw__FUz-xrs__LATEST

    Also, the emulator i'm using with V10 is "Blackhawk TMDSEMU200-U". Could it have a loading check/limitation ?

    That message is coming from the debugger so it is likely unrelated to the debug probe.