cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F030 Bootloader Go

klaus2
Associate II

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.

0690X000008iKqSQAU.jpg

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 ?

1 ACCEPTED SOLUTION

Accepted Solutions

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.

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..

View solution in original post

5 REPLIES 5

I thought it was the base of the vector table and it loads SP/PC from there

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..

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 ?

klaus2
Associate II

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 ?

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.

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
klaus2
Associate II

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.