I'm working with the MSP430FR5969 and my goal is to have some variables in FRAM that retain their value through a chip reset, that is, they are only initialized when the program is loaded.
I'm working on an Energia project in CCS6.1, so the GCC compiler is used. My CCS project options show that I have 2 choices for compiler:
1) GNU v4.9.1 (Red Hat), and
2) GNU v4.6.3 (MSPGCC)
Is there a "persistent" variable attribute supported by these compilers that can be used in a C/CPP module so it can be linked with the Energia code?
I already tried this in a C file withing the Energia project:
int __attribute__((persistent)) myVar;
but I got a message saying the attribute was ignored.
Alternatively, is it a viable option to use the "persistent" pragma in the TI compiler and link it with the Energia project? Any other possibilities?
Thanks,
John Wygonski