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.

Ram function in MSP432

working with the msp432, How do i map a function into RAM ?

  • i'd tried it but got the following warning:

    #1173-D unknown attribute "ramfunc" C/C++ Problem

    i have added the --ramfunc=on to the compiler options, but there was no change in the warning. and the routine was still mapped to the flash.
    i'm using CCS version 6.1.2.00015
  • Shai Gigi said:
    i'd tried it but got the following warning:

    #1173-D unknown attribute "ramfunc" C/C++ Problem

    Which version of the compiler are you using?

    The "ramfunc" attribute is available in Ti ARM compiler version 15.6 and greater.

    See http://processors.wiki.ti.com/index.php/Compiler_Updates#Install_new_features for how to get a new compiler version.

  • I have arm compiler version 5.2.8 but when i try to update it , i get "no updates were found" message.......
  • Shai Gigi said:
    I have arm compiler version 5.2.8 but when i try to update it , i get "no updates were found" message

    As explained by Compiler Updates to get a major compiler update you have to either:

    a) Use Help -> Install New Software

    b) Use the CCS App Center

  • Thanks.

    it was already appearing in the compiler list for selection for the project.
    i moved from v5.2 to V16.9. The asmfunc works. But now the debuger (XDS110 on the launchpad) is not working. i turned everything off and on again...but still whenever i try to start a debug session, the debugger window is stuck and shows only red stop button. no pause or start button are available and of course nothing is running....
  • Shai Gigi said:
    but still whenever i try to start a debug session, the debugger window is stuck and shows only red stop button.

    I performed a test of adding __attribute__((ramfunc)) to functions in an existing MSP432 project using the TI v16.9.0 LTS compiler.

    When __attribute__((ramfunc)) was used on the main function, when a debug session was started the program didn't halt at main the the debugger window only showed a red stop button. Since the program did flash a LED could see that the program was actually running. When I selected the "Texas Instruments XDS110 USB Debug Probe/Cortex_M4_0 (Running)" line in the Debug window the pause button became available, and could pause the program.

    In the CCS project properties under Debug -> Misc/Other Options unticked the "Allow software breakpoints to be used". With the use of software breakpoints disabled, when started a debug session the program was halted at the start of the main function (in RAM). Does that resolve your problem?

    Having the main function placed in RAM seems to stop the CCS debugger from running to main when software breakpoints are used - presumably since the act of copying the main function from flash to ram overwrites the software breakpoint.

  • Unfortunately this is not the case.
    i removed the __attribute__((ramfunc)) from my program and i still get the same problem.
    i moved back to compile with the 5.2.8 and everything works fine......
    just the moving from compiler to the new compiler created the problem without even using the asmfunc attribute.....
    the only difference was that i changed the compiler...i'm really surprised....
    BTW. the program didn't work at all when i used the new compiler. itt is not just the debuger, the SW is stuck around the first few insstruction and get reset repeatedly...
  • I have attached a simple example project with the ISR placed in RAM.  Could you test with your setup?

    adc_single_conversion_repeat_timera_source_05.zip

  • Hi.

    Thank you.

    Eventually i uninstall the whole ccs environment. when i installed it again the asmfunc attribute was working without any change in my project.

    I was expecting that TI tools will be more stable and reliable, it was a waist of dozen hours.

     

**Attention** This is a public forum