This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

how to execute function from RAM

Hi,

I apologize if this question has been asked before but I couldn't find an answer.

I want to clear GPNVM2 bit but to do that I need to copy the function that does that to RAM and run it from RAM.
Has anyone done this before?
I've seen few posts about setting/clearing GPNVM bits so these people figured out how to copy function to RAM. IAR uses __ramfunc but that is only for IAR.

Do I just have to copy function from flash to RAM and it would work? using memcpy()?

Thanks

0