cancel
Showing results for 
Search instead for 
Did you mean: 

Interrupts not working with Bootloader

Marco Burgener
Associate

Dear Community,

I'm working on a bootloader project using an STM32L071. I was able to start the main application using the code below:

 

void HalSys_BootMainApplication()
{
    /* Set address to jump to*/
    volatile uint32_t jumpAddress = *(uint32_t*)(0x08008000 + 4);
    pFunction jump = (pFunction)jumpAddress;

    /* Set stack pointer to new initial value, located at the start of the new application */
    __set_MSP(*(uint32_t*)0x08008000);

    /* Jump to application */
    jump();
}

 

The main application start successfully (I get a lot of logs over UART) but apparently the interrupts are not working. After having searched for a solution in the forum, I came across the SCB->VTOR which apparently must be set correctly in the main application such that it can find the correct interrupt addresses. So in the main application's system_init, I'm setting it to 0x08008000, but then the application doesn't even start at all. Any idea?

Many thanks in advance and best,

Marco

0 REPLIES 0