STM32F103_MSD_BOOTLOADER
STM32F103_MSD_BOOTLOADER copied to clipboard
Only write the memory range defined in .hex file into flash
I am currently working on a STM32F1 project, which uses the last 2KB of Flash for an EEPROM emulation. When updating the application using MSD_BOOTLOADER, that last 2KB get overwritten, so the config data stored there are deleted.
I guess that this is because the end of flash is hard coded via this line:
#define APP_SIZE (DEV_FLASH_SIZE - APP_OFFSET)
Question: Can we improve the bootloader so it would only write the flash memory range which is defined in the flashed .hex file?