3 years, 5 months ago.

How to add a Section with GCC-ARM (mbed 5 CLI)

In CLI ,GCC linker file [ .link_script.ld ] is automatically updated by command [ mbed compile ] So, user cant touch it. How to user add a section (e.g. SDRAM ) to linker directive ? ( mbed 5 ) Thanks for reading.

2 Answers

8 months, 3 weeks ago.

mbed-cli accepts an undocumented -l your_linker_script command line argument that lets you supply your own linker script.

3 years, 5 months ago.

You can edit the linker script file in mbed-os of your local copy. For example:


Well, that would obviusly work, alright. What I'd like to know, and can't seem to find an answer for, would be, if it is possible to write a *.json file like mbed_lib.json or mbed_app.json that when a new project is exported, sufficiently modifies the scatter-file / linker-script or with the help of .mbedignore replaces it by a user-defined script.

posted by Christian B*** 12 Jan 2018