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/TMS320F28377S: creating output section ".scratchpad" without a SECTIONS specification cla_general

Part Number: TMS320F28377S

Tool/software: Code Composer Studio

I am using clamath.h library, its the latest version .

But when I am using CLAacos and CLaasin functions I am getting above warning.

I tried to modify .cmd file based on the previous threads posted by others but it didn,t work. I have attached the .cmd file. please let me know why I am getting this warning.New Microsoft Word Document.docx

  • .scratchpad
    *          1    00000002    00000016     UNINITIALIZED
                      00000002    00000004     CLAacos.obj (.scratchpad:Cla1Prog:_CLAacos_spc)
                      00000002    0000000c     toggle.obj (.scratchpad:Cla1Prog:_control_loop)
                      0000000e    00000006     toggle.obj (.scratchpad:Cla1Prog:_pll_run)
                      0000000e    00000004     toggle.obj (.scratchpad:Cla1Prog:_picontrol)
                      00000014    00000004     CLAacos.obj (.scratchpad:Cla1Prog:_CLAacos)
                      00000014    00000004     CLAasin.obj (.scratchpad:Cla1Prog:_CLAasin)

    In .map file .scratchpad section is uninitialized. how can I initialize this?

  • Hi

    Regarding first question, either remove #ifdef CLA_C /#endif from cmd file, or go to linker settings, Advanced Options, Command Line Preprocessing and add to predefine window CLA_C.

    Regarding 2nd, on boot all the RAM is initialized to 0. For debugging purposes you may initialize this section from C2000 code. Example for CPU initialized bss section:

    In CMD file:
    .ebss : > RAMGS01 PAGE = 1 , RUN_START(_EbssStart), RUN_SIZE(_EbssSize)

    In any C file add this routine:

    #include <string.h>

     int _system_pre_init(void)
    {
    extern int EbssSize, EbssStart;

    memset(&EbssStart, 0, (size_t)&EbssSize);

    return 1;
    }

    Edward

  • Hi,

    Edward's response should be helpful. I think you need to define CLA_C in the linker settings.

    Please see the CLA Math Library examples as well.

    Hope this helps.
    sal