Maybe I ask in not correct place.. I need to place some functions from cstartup.s to RAM.
Does any one know right way for this?
The problem here is that ‘something’ needs to initialise the RAM with the executable code that you want to execute.
The IAR C runtime initialisation takes care of that when you use __ramfunc.
You would not be able to call these type of functions before reaching main().
If I interpret your question as “How do I run an assembler function from RAM”, then here is an example of one. (not clear if interworking will be handled though).
You should not call it before reaching main() so not sure if it meets your requirements.
#define SHT_PROGBITS 0x1#define SHF_WRITE 0x1#define SHF_EXECINSTR 0x4
SECTION_TYPE SHT_PROGBITS, SHF_WRITE | SHF_EXECINSTR
BX R3 ;; return
Can you expand more on the problem that you are trying to solve?
Thank you for your answer! The answer is exactly what I need, I could not find the correct type of sections. I want to do nested interrupts, running from RAM and I had to reimplement IRQ_Nested_Interrupt_Setup.
Retrieving data ...