cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F407 Backup SRAM backup regulator needed ?

YWilk.1
Associate II

Hi

i would like to use the backup SRAM of the STM32F407 MCU to share boot flags between the bootloader and main firmware.

The flag should be used to signal a "boot into bootloader" requested by the main firmware.

To boot into the bootloader the main firmware will set the boot flag in the SRAM memory and afterwards execute NVIC_SystemReset() to perform a soft reset.

Is it necessary to enable the SRAM backup regulator if the MCU is only reset by a software reset while VCC stays stable ?

Is the backup SRAM powered from VCC as long as the backup SRAM regulator is disabled ?

Best regards

Yannic

2 REPLIES 2

0693W000007Z7xhQAC.pngJW

GLASS
Senior

You can also use the SRam​ instead of BackupRam. You only need to allocate a dedicated section in LD file of both bootloader and app, so asm startup will not erase those variables. Be carefull, you also need to put attribut in C declaration of flags so they will be located in this New section. This code must not rely on C initialisation...

See resulting map file to be sure you got the correct mapping.