cancel
Showing results for 
Search instead for 
Did you mean: 

IAP Jump to application not working

TaronKim
Associate II

Hi, I have some problem about IAP.

It's not working application after jump from custom boot.

 

- MCU : Stm32F446RC

- Board : Custom board

- Boot address : 0x08000000 ~ 0x0801FFFF (128k)

- Application address : 0x08020000 (384k)

 

- Custom Boot Flash.ld

TaronKim_1-1725433034351.png

 

- Application Flash.ld

TaronKim_2-1725433073723.png

 

- Application system_stm32f4xx.c

TaronKim_3-1725433133878.pngTaronKim_4-1725433145803.png

- Jump to App code

TaronKim_0-1725432821639.png

 

I got the problem here

- HAL_Init() -> HAL_InitTick(TICK_INT_PRIORITY) -> HAL_NVIC_EnableIRQ(TIM8_TRG_COM_TIM14_IRQn) in stm32f4xx_hal_timebase_tim.c

TaronKim_5-1725433266485.png

TaronKim_7-1725433294614.png

 

Anyone have some solution?

Please answer me.

 

Thanks.

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Ahh you dont read i write RAM and this is 128k only. Then vector offset cant be 0x20000.

Comment out this and all works

//#define VECT_TAB_SRAM

View solution in original post

8 REPLIES 8
Imen.D
ST Employee

Hello @TaronKim 

What is the value of Application Start address?

I advise you refer to this article: How to jump to system bootloader from application ... - STMicroelectronics Community

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen

>>Anyone have some solution? Please answer me.

Use the Debugger, and step over the code.

Make sure that the vector table has viable content, and not filled with 0xFFFFFFFF

Failure suggests you're jumping anyway, or you reactivate an interrupt and it vectors there. Perhaps validate entire image say with signing or CRC.

Be a bit more circumspect before changing the SCB->VTOR and handing off control. Instrument your code so it's more apparent what's happening and why.

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

Your config cant work . You set RAM vectors with offset to non existed RAM area...

-it's custom bootloader address

TaronKim_0-1725494915837.png

 

-it's application address 

TaronKim_1-1725494966218.png

i got the problem after Jump from boot to application.

bootloader firmware is working well

TaronKim_2-1725495240247.png

TaronKim_3-1725495252917.png

 

 

I thought RC have 256k bytes memory, so it makes problem.

So i changed RC to RE. Re have 512k bytes memory.

But it's same problem..

Ahh you dont read i write RAM and this is 128k only. Then vector offset cant be 0x20000.

Comment out this and all works

//#define VECT_TAB_SRAM

>>But it's same problem..

Define the "problem" better

Show that SCB->VTOR = 0x08020000

Show what's happening as you step into the application

Show the point of failure, with registers and disassembly

Instrument so you can dump peripheral and cpu registers

If failing interrupts, show NVIC, show Vectors

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

Omg.. thanks a lot.

it's working now..

why i did..