2025-09-18 5:23 AM
Hi,
Please help me sort this out.
I am trying to port a custom bootloader originally written for the SAMD21 Arm chip to the STM32U385VGT6. We are upgrading our current product with an STM32 Chip. I am having problems with switching from the bootloader to the application binary. My bootloader is loaded at address 0x08000000. The application binary is compiled to run from 0x08010000. I edited the linker script files to locate the binaries properly and tested opening the binary file with a hex editor. All seems situated correctly. Here is my function to jump to the application. APP_CODE_START is set to 0x08010000. I get "jumping to application" in my debug terminal. But the application code is not running.
2025-09-18 5:33 AM
Do you ever re-enable interrupts?
You should disable interrupts individually so they do not immediately fire after the jump.
2025-09-18 8:02 AM
What TDK said.
And: __disable_irq(); does not actually disable any interrupts, it just prevents the MCU from entering any ISRs.
So better clear the Interrupt Enable and Pending registers. In H7 that's several NVIC->ICER[n] and NVIC->ICPR[n] .