Hi
I am working on STM32G4 with Keil, ARMCompiler6.13.
There is critical code executing in CCMRAM (start address is 0x10000000) , I want to load this region once when cold boot (my program is able to detemine cold boot or upgrade boot), and will not be changed after even firmware upgrade.
But when the program jumps to the Reset_Handler after firmware upgrade, the CCMRAM was refreshed.I want to keep CCMRAM remain not change during startup.
Then I tried to add "UNINIT" to the CCMRAM region in .sct file, but it doesn't work.
I checked the "Application Note 241 ARM Compiler C Library Startup and Initialization", found the ram is initialized by "__scatterload()" function, then I tried to override this function, but looks it is impossible because there is compressed data in RW region, I don't know how to decompress it.
could someone help on this? could user customize the load function for CCMRAM?
thanks!
UNINIT applies only to data sections.
Ronan,
Thanks again.I will set "--datacompressor=off" and make my own "__scatterload()" function.