请教一些各位大神,MPC5744P中,如何使得在软件复位后指定RAM分区里的数据不丢失?
in MPC5744P,
How to make the data in the specified RAM partition not lost after the software reset?
解決済! 解決策の投稿を見る。
Hi,
Normally after reset are uninitialized variables set to 0 by startup code. You can put your variables into .noinit section. In this case variables will be skipped out from setting to 0:
__attribute__ ((section(".noinit"))) uint16_t my_global_array[100];
Jiri
Hi,
Normally after reset are uninitialized variables set to 0 by startup code. You can put your variables into .noinit section. In this case variables will be skipped out from setting to 0:
__attribute__ ((section(".noinit"))) uint16_t my_global_array[100];
Jiri
hello sir,
more question to me, my aim is to define a bootloader_start_var __, I jut use __attribute__ ((section(".noinit"))) to define my var didn't work, I found there is't .noinit section in the 57xx_flash.ld.
Do i need to define the .noinit section in the .ld files? should I do something in the file startup.s?
I am a totally newbies, thanks for your time!
Oh!Thank you so much,my friend!