AnsweredAssumed Answered

AN2606 System memory boot mode - Jumping to bootloader

Question asked by seabrook.bob on May 5, 2016
Latest reply on May 6, 2016 by seabrook.bob
I am using a stm32f4discovery. When SB18 is removed (underside) to make boot0=1, to boot from system-bootloader, my windows7 sucessfully detects the USB DFU interface (it appears in Device manager in the "Universal Serial Bus Controllers" node as "STM Device in DFU Mode". Great!).

Next, I replaced SB18 to boot from user flash at 0x08000000.  

AN2606 revision 27 page 20 clearly states that "..user can execute bootloader by performing a jump to system memory from user code." Exactly what address do I jump to.????   Page 93 says says bootloader starts at 0x1fff0000 (size 30688 bytes). However this is vector table. containing an intial SP and PC of 20001d80 and 1fff3da1. In my usercode I have NOT enables any PLL,interrupts, peripherals, so right at the start of main() I simply jump to 1fff3da1 (1fff3da0 in thumb2 mode) using instructions;
       __ASM volatile ("b 0x1fff3da1\n");

 but my windows7 does NOT detect the USB DFU interface. Can anyone tell me how to make this work?

What actually happens is that I get hard-fault because when I jump to 0x1fff3da1 the debugger takes me to "*ABS*0x1fff3da0_veneer" at 0x08005f28. 

I have tried jumping to 1fff3da0. Same result.

I am using GNU C++ in SW4STM32.