I would like to compile an unmanaged bootloader and an application using mbed cli2 (mbed-tools) for an NUCLEO_F429ZI board.
Between bootloader and application I would like to place a configuration space of > 16KB.
My understanding is that I need to create two mbed projects, one for the bootloader and another one for the application. Now I am struggling with defining a new start address for the application.
After reading the documentation:
An unmanaged bootloader build is a method of controlling the link location of a program within Mbed OS. There are two configuration options available for changing the link location:
target.mbed_app_start
andtarget.mbed_app_size
.
I concluded that I can change the start address of my application by stating these parameters in a mbed_app.json, here shifted by 64K as the default FLASH start is at 0x8000000.
{
"target_overrides": {
"*": {
"target.mbed_app_start": "0x08010000",
"target.mbed_app_size": "0x40000"
}
}
}
The parameter explanation tells that e.g. for target.mbed_app_start:
The value of this parameter is available to C and C++ as
APPLICATION_ADDR
and to the linker asMBED_APP_START
.
But when applying the the commands:
$mbed-tools configure -m NUCLEO_F429ZI -t GCC_ARM
$mbed-tools compile -m NUCLEO_F429ZI -t GCC_ARM
I do not get any compilation error, but I also do not find these parameters reflected in the build, neither in the generated mbed-stm32f429xi.link_script.ld (program start is still the default).
Also I did not find the parameter MBED_APPLICATION_ADDR defined in the generated build.ninja - I also cannot a compile source files using that parameter as the parameter (“…was not declared in this scope”) . Also the generated map file confirms the unchanged default application start address.
It seems that I miss a fundamental issue. Can anyone help?
Best regards
cdelfs