EFM32 Gecko Software Documentation
efm32g-doc-5.1.2
|
RAM code support.
This module provides support for executing code from RAM. A unified method to manage RAM code across all supported tools is provided.
In your .h file:
#include "em_ramfunc.h" SL_RAMFUNC_DECLARATOR void MyPrint(const char* string);
Issues have been observed with armgcc when there is no declarator. It is recommended to have a declarator also for internal functions, but move the declarator to the .c file.
In your .c file:
#include "em_ramfunc.h" SL_RAMFUNC_DEFINITION_BEGIN void MyPrint(const char* string) { ... } SL_RAMFUNC_DEFINITION_END
Macros | |
#define | SL_RAMFUNC_DECLARATOR |
Compiler ported function declarator for RAM code. | |
#define | SL_RAMFUNC_DEFINITION_BEGIN |
Compiler ported function definition begin marker for RAM code. | |
#define | SL_RAMFUNC_DEFINITION_END |
Compiler ported function definition end marker for RAM code. | |
#define | SL_RAMFUNC_DISABLE |
This define is not present by default. By compiling with the define SL_RAMFUNC_DISABLE, code placed in RAM by the SL_RAMFUNC macros will be placed in default code space (Flash) instead. More... | |
#define SL_RAMFUNC_DISABLE |
This define is not present by default. By compiling with the define SL_RAMFUNC_DISABLE, code placed in RAM by the SL_RAMFUNC macros will be placed in default code space (Flash) instead.
Definition at line 107 of file em_ramfunc.h.