cancel
Showing results for 
Search instead for 
Did you mean: 

Main application running at address 0x08040000

Thomas Carrié
Associate
Posted on December 11, 2017 at 20:34

Hi,

I'm using a STM32F417 on which I want to have a bootloader (at the beginning of the flash, i.e. address 0x08000000) and two applications using FreeRTOS (one at address 0x08004000 and the other one at address 0x08040000). The bootloader and the first application are working fine, but when it comes to jump to the second application, the programm crashes. To try to find where the problem comes from, I have loaded only application 1 (without bootlaoder) at address 0x08004000 : that works. Then application 1 at address 0x08040000 : programm crashes. I have of course relocated interrupt vector (using VTOR) at address 0x08040000, and I have changed my linker accordingly. When I go in debug mode, I can see that programm never crashes at the same point. Going further, I tried to load application at addresse 0x08006000 (it's working), 0x08008000 (it's working) and 0x0800A000. With this last test, the programm seems to work but strange behavior starts to appear when I use printf : the output shows some format arguments instead of values (i.e. '[%u/%u/%u-%u:%u:%u UTC]' instead of '[11/12/17-19:28:30 UTC]'). With application at address 0x0800F000 this behavior appears more often, and with application at address 0x08020000 program crashes.

Does it exist a limit address when we can start an application/relocate interrupt vector ? If not, it is maybe something linked with FreeRTOS... Has anyone already faced this kind of behavior ?

Thanks,

Thomas

1 ACCEPTED SOLUTION

Accepted Solutions
Thomas Carrié
Associate
Posted on December 12, 2017 at 17:57

I've just figured out the problem: the value for flash latency was wrong (according to my supply voltage and the value of the HCLK I use).

I don't really understand why it was working for low flash address though, but anyway it's working fine now!

View solution in original post

1 REPLY 1
Thomas Carrié
Associate
Posted on December 12, 2017 at 17:57

I've just figured out the problem: the value for flash latency was wrong (according to my supply voltage and the value of the HCLK I use).

I don't really understand why it was working for low flash address though, but anyway it's working fine now!