2023-02-06 06:36 AM
Hi
I'm using STM32H750VBT6 with W25Q32 QSPI external flash memory from Winbond and I'm using Keil Microvision IDE with ARM_CC Compiler.
I'm trying to execute my whole project from the QSPI flash directly (which is called XIP). I know that I have to configure QuadSPI peripheral properly before executing code from the memory mapped QSPI flash and I'm doing it in SystemInit() function, so I have to map the SystemInit or system_stm32h7xx.c file to the default internal flash address and change the main() address to the QSPI flash (which is 0x90000000 in my case).
The problem is, how I can change the main() base address and execute it from the QSPI flash after configuring QuadSPI in SystemInit().
And what should I do with VTOR? Do I have to leave it with the default value?
Regards
Farbod
Solved! Go to Solution.
2023-02-06 06:48 AM
What you are trying to do doesn't seem to be a good idea - you will get slow and non-deterministic interrupt response.
I you have to do it, treat it as two distinct programs in two separate projects: the bootloader in internal Flash, initializing QSPI access and jumping to the application in QSPI. Search the forum for posts on bootloader - you will see many interesting remarks. You will need to set VTOR in the bootloader (recommended) or in the app.
2023-02-06 06:48 AM
What you are trying to do doesn't seem to be a good idea - you will get slow and non-deterministic interrupt response.
I you have to do it, treat it as two distinct programs in two separate projects: the bootloader in internal Flash, initializing QSPI access and jumping to the application in QSPI. Search the forum for posts on bootloader - you will see many interesting remarks. You will need to set VTOR in the bootloader (recommended) or in the app.
2023-02-06 06:54 AM
Thanks a lot:thumbs_up: