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.

Using Variables in FRAM

Other Parts Discussed in Thread: MSP430FR5849

I am trying to allocate a 4K array in FRAM used for data logging and have followed the procedure from "Creating MSP430 FRAM Variables Using CCS" post.

It appears to allocate the buffer but I am getting the following linker warning:

warning #10247-D: creating output section ".fram_vars" without a SECTIONS specification

In the linker command file "lnk_msp430fr5849.cmd" I have made the following entries:

MEMORY
{
   
    //FRAM                    : origin = 0x4400, length = 0xBB80
    FRAM_VARS (RW)           : origin = 0x4400, length = 0x1000

    FRAM                    : origin = 0x5400, length = 0xAB80


 }

 

SECTIONS

{

.fram_vars : {} > FRAM_VARS type=NOINIT

}

In my code I have the following:

#pragma SET_DATA_SECTION(".fram_vars")
unsigned char Data_Log[4096];
#pragma SET_DATA_SECTION()

Why am I getting this warning about not specifying the SECTIONS specification?

  • Dave,

    place a "," in here:

    .fram_vars : {} > FRAM_VARS  type=NOINIT
    .fram_vars : {} > FRAM_VARS, type=NOINIT

    I'm not entirely sure if this solves your issue, but this is the first thing I see, that is different from what I'm used to.

    Dennis

  • Hi Dennis,

    That did not make any difference.

    All the other similar statements in the .cmd file do not have a comma either.

    For some reason the linker is completely ignoring my statement but I cannot see any syntax problems with what I have done.

  • Hi Dennis,
    I have solved my problem. I used the browse button on the project properties window to find the location of the linker .cmd file but that did not lead me to the correct place. I did not realise that the project made its own copy of the linker cmd file and placed it into the project folder.Duh!!
    So consequently I was modifying the wrong .cmd file.
    Everything is now working. User error!!!
  • I deleted the "," in my command file and it did not make any difference - no compiler warning/error, so it does not seem to be that important. Glad it works for you now!

**Attention** This is a public forum