cancel
Showing results for 
Search instead for 
Did you mean: 

Restart from SRAM after Bootloader with problems

infoinfo978
Associate II
Posted on June 30, 2012 at 09:40

Hi guys,

i managed to flash my stm32f107vc via the internal bootloader, but i have problems to get the program running after it.

When I reset the MCU the PC is somewhere at the beginning of SRAM i think (0x20000000).

I found out, that if I set the PC to 0x8003000 manually, i can let the sw run and everything including interrupts works fine.

Can someone help me how to manage to jump from 0x20000000 to 0x8003000 after reset?

I am using a linkerfile as seen below:

....

LR_IROM1 0x08003000 0x00080000-0x3000

{

   ER_IROM1 0x08003000 0x00080000-0x3000

   {

      * (RESET, +First)

      .ANY (+RO)

   }

   IRAM 0x20000000 0xD800 ; 55296 Byte (10K also 10 Pages sind dahinter noch Platz)

   {

      *(STACK)

      .ANY2 (+RW +ZI)

   }

....

before configuring the NVIC i call:

NVIC_SetVectorTable(NVIC_VectTab_FLASH, 0x3000);

thanks for your support guys!

Toby

 

2 REPLIES 2
stforum.tormod9
Associate II
Posted on June 30, 2012 at 11:05

Have you wired BOOT0 and BOOT1 correctly? They can be configured to boot from FLASH, embedded RAM or the ROM (''system memory'') boot loader. Please see AN2606, section 3.1.

Tormod

infoinfo978
Associate II
Posted on June 30, 2012 at 23:02

yes, sure. I have a jumper to select boot 0, boot 1.