Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
5 years, 5 months ago.
managed bootloader not padding binary per target.restrict_size setting (mbed-os-5.11.1)
I have an Mbed application (mbed-os-5.11.1) based on the STM32L471QG and using the GCC compiler. I am trying to implement a managed bootloader, but the target.restrict_size setting in mbed_app.json is not padding the generated .bin file out to the requested size. It appears that there is already an issue filed for this problem but no action that I am aware of.
What is the best workaround for this? I already have a custom linker script, so maybe there is a way to force the requisite padding in the linker script?
Can anyone suggest how to accomplish this? Is there a better workaround?
For the moment I am simply hardcoding the address at which my application will be linked so that it will be where the bootloader expects it to be. Obviously I would prefer the linker be able to figure this out by pulling in the correctly padded binary via the target.bootloader_img setting in it's mbed_app.json file.