2019-06-06 10:21 AM
I have the following situation. I use a STM32F030F4 flashed with a programm created with Keil uVision. I use startupfile provided from ST. Flashtool and Target dialog are configured in "default". The address for the app inside the flash starts at 0x08000000. So nothing special with the application code. When I flash the device putting the Boot0 pin to GND the application starts as expected.
But when I try to start the application via the bootloader putting the Boot0 pin to VCC. I can not get it running.Here is a figure how far I come with bootloader.
I talk with the bootloader via Uart and erverything is accepted but I fail to provide the right flashaddress to start the application. I thought it should be the address of the reset handler which is 0x08000139. Do I miss something here or is the approach correct ?
Solved! Go to Solution.
2019-06-11 05:53 AM
They might be using a watchdog.
Make sure your code explicitly sets SCB->VTOR properly on chips that have it, and on those that require the zero remap of FLASH via SYSCFG, that you do that in your app also.
2019-06-06 10:35 AM
I thought it was the base of the vector table and it loads SP/PC from there
2019-06-06 10:41 PM
Thanks for your quick reply!
Do I understand you correct that the address should be 0x00000000 because the vector table is located there per default ?
2019-06-11 05:28 AM
Ok address 0x08000000 seems to work. The application starts.
But it fails as soon the the DMA IRQ from the ADC is fired.
Disabling the DMA IRQ and all other works well so far. What could be the reason that it now has problems with the DMA IRQ when starting the application via the bootloader Go command instead of the procedurce setting boot0 0 to GND ?
2019-06-11 05:53 AM
They might be using a watchdog.
Make sure your code explicitly sets SCB->VTOR properly on chips that have it, and on those that require the zero remap of FLASH via SYSCFG, that you do that in your app also.
2019-06-11 08:04 AM
Thanks now it works with the IRQs as well.
Now I clear the MEM_MODE[1:0] bits inside the Syscfgr1 register during SystemInit() function to overwrite the values set by the sampling of Boot0 pin. Because this sampling has mapped the system memory at 0x00000000 instead of the flash.