Dear Support.
I'm trying to understand how the M3 design kit's "bootloader.hex" and "hello" firmware "image.hex" are work.
When I ran Hello example, I got the message as the below
51630 ns UART: 57030 ns UART: CMSDK Boot Loader 61010 ns UART: - load flash 64990 ns UART: - DSB start 68690 ns UART: - ISB start 76030 ns UART: - FlashLoader_ASM start 203210 ns UART: Hello world 225090 ns UART: ** TEST PASSED ** 227110 ns UART: Test Ended
First of all, Boot Loader executed then Hello world execute. But I want to know how magically hello example's "image.hex" execute after bootloader's "bootloader.hex".
As I know, CM3 RTL has BOOT_LOADER_PRESERNT==1, so firstly CM3 will boot at the 0x0100_0000. there is loaded "bootloader.hex" In 0x0100_0000 boot memory,
In the bootloader.c, it gets the initial MSP and initial PC (Reset_Handler address).
In the Reset_Handler, it goes to "main" then FlashLoader() executed with Clear remap and get initial MSP value and initial PC value.. There is no doubt until here. but what after this ?
But How does hello's "image.hex" execute from bootloader.hex? I can't find any connection between "image.hex" and "bootloader.hex".
From now on, I'm very confused