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.

CCS/TMS320F28335: CCS9 Won't put code in RAML2 or RAML3 when RAML1 is full. Please help.

Part Number: TMS320F28335
Other Parts Discussed in Thread: C2000WARE

Tool/software: Code Composer Studio

Hi Guys, I've created an new project for my F28335 standalone board. CCS9 creates a 28335_RAM_lnk.cmd file.

The F28335 has RAML0, RAML1, RAML2 and RAML3 banks all 4K in size.

My C program now exceeds the 4K limit and CCS9 won't write the rest of my code into the other banks of ram.

In the .cmd file I have done this:

.text            : > RAML1 | RAML2 | RAML3,     PAGE = 0

This should tell the linker to continue writing the code to the other banks when one bank is full but it doesn't do it.

Have I left something out?

When I build my code now I get this error message:

<Linking>

"../28335_RAM_lnk.cmd", line 133: error #10099-D: program will not fit into available memory.  placement with alignment/blocking fails for section ".text" size 0x12a5 page 0.  Available memory ranges:

   RAML1        size: 0x1000       unused: 0x1000       max hole: 0x1000    

   RAML2        size: 0x1000       unused: 0x1000       max hole: 0x1000    

   RAML3        size: 0x1000       unused: 0x1000       max hole: 0x1000

Any help here would be greatly appreciated.

Thanks, Peter

Peter

  • There are two solutions to consider.  One is section splitting.  The other is combining memory ranges to form a larger memory range.

    The file 28335_RAM_lnk.cmd that comes with C2000Ware v3.03.00.00 uses section splitting.

       .text            : >> RAML1 | RAML2,     PAGE = 0

    Compare that to your code ...

    Peter Adamcik said:
    .text            : > RAML1 | RAML2 | RAML3,     PAGE = 0

    Notice the >> instead of >.  The >> means section splitting.  The > means allocate the output section in the first memory range which can completely contain it.  For more details on section splitting, please see the Split an Output Section Across Multiple Memory Ranges part of the larger article Linker Command File Primer.

    The C2000Ware linker command file also contains this comment ...

             Contiguous SARAM memory blocks can be combined
             if required to create a larger memory block.

    This means you could replace ...

       RAML0      : origin = 0x008000, length = 0x001000
       RAML1      : origin = 0x009000, length = 0x001000
       RAML2      : origin = 0x00A000, length = 0x001000
       RAML3      : origin = 0x00B000, length = 0x001000

    With something like ...

       RAML0L1L2L3 : origin = 0x008000, length = 0x004000

    Then allocate the .text section into it ...

        .text > RAML0L1L2L3, PAGE = 0

    Thanks and regards,

    -George

  • Hi George, thank you for the info, very much appreciated.

    I've combined RAML0,L1,L2,L3,L4,L5,L6 as one continuous RAM BANK and left RAML7 for .ebss variables. 

    Seems to working now. Thank you :)

    OH, quick question. If I wanted to download my code to FLASHA to FLASHH do I do the same to combine FLASHA to FLASHH as one FLASH_MEMORY?

    Peter

  • Peter,

    Yes, you can combine the Flash sectors in to one if you need.

    Thanks and regards,
    Vamsi