Hi all I'm currently trying to port the compute through power loss library for the FRAM boards (Testing on fr5739, 5969, 6989).
I read in another thread that to port it I'd need to do the following:
"The two components that would need to be ported from the TI compiler to GCC are the the linker files (placing all RAM data into FRAM with the exception of the stack) and the low-level assembly routine. The remainder of the source code is C and should be compatible with GCC."
I thought I had a decent grasp on the assembly file and (after some reading) the linker script, but it seems I'm still having some problems.
I'm using the 5969 as my testing board at the moment. I'm trying to get the example ctpl_ex4_adc12_b_monitor_msp-exp430fr5969.c code working with the gcc compiler (I'm trying to use the latest TI backed GCC at the moment).
I tried putting all the .bss section and the .data section in FRAM, but it didn't work out so well for me. I then tried to split the FRAM in to two sections one R/W capable and mapped it sections of memory under .cptl label. I then put all the the variables that should persist in to that section using the attribute directives.
I was able to test that I could R/W to this FRAM section by storing a value and checking it over power cycles, but when trying the full example, the code never seems to restore state properly. It just performs the normal operations.
Any ideas or could someone look at ctpl_low_level.S and msp430fr5969.ld and see if I've done something blatantly wrong?
Their corresponding CCS equivalents are also attached.
Please let me know if I could provide any more information. I've spent a decent amount of time solo debugging and I've reached a near stopping point.
I've attached the files Ive changed and the .asm file I converted to .S @ctpl.zip