2015-09-10 02:46 PM
Hello all,
I am looking how I can flash my firmware to sector 4 (0x0802 0000) and jump to it to execute the code. I am using Keil uVision 5 as development environment.I know that I must changed the address in the option byte but not sure how I can do it in the UI.Anyone has already done it? #stm32f7-startup-flash2015-09-14 08:19 AM
Hi Keaven,
For booting from sector 4 of the flash: 1-Modify the linker file by putting the address of sector 4LR_IROM1 0x08020000 0x00100000 { ; load region size_region
ER_IROM1 0x08020000 0x00100000 { ; load address = execution address
-Choose the option byte that defines the boot memory base address , BOOT_ADD0 or BOOT_ADD1 by setting MEM_BOOT field of SYSCFG_MEMRMP register (section 7.2.1 of RM0385)
-Using ST-Link Utility, configure the chosen option byte by putting the value 0x2008 in it (this value correspond to address[29:14]- section 3.4.1 of RM0385)
-Develop your code, and when you load it the boot will be executed in sector 4.
-Shahrzad-
2015-09-17 02:08 PM
I ended up doing almost like you suggest. The only difference is that I used an assembly file to configure the option bytes and load it with my project. I am using our own board with STM32F7 cores and cannot use st-link utility software with an ulink-pro.
Thank you Shahrzad for giving me pointers to find my way out.