10 years, 8 months ago.

NUCLEO_F401 now has GCC. I need help with how to port to L152RE..WIP

HI all. Thanks to the guys that sorted out porting ARM_GCC to the NUCLEO F401. Very useful indeed and now I would like to port GCC to NUCLEO_L152 . Here are the steps I have tried so far: I have changed the .ld file in C:\mbed_NUCLEO\libraries\mbed\targets\cmsis\TARGET_STM\TARGET_NUCLEO_L152RE\TOOLCHAIN_ARM_GCC so it now has these memory definitions which I took from the .sct file:

FLASH (rx) : ORIGIN = 0x08000000, LENGTH = 512K CCM (rwx) : ORIGIN = 0x10000000, LENGTH = 64K RAM (rwx) : ORIGIN = 0x20000124, LENGTH = 0x14000-0x124

and I have changed the .s file in the same folder to have the same vectors as the file in the ARM_STD folder changing the structure of the stm32f407 file. I can get the tests to compile and I DO change the pin numbers in main.cpp to reflect the board I am using but it still isn't working.. Should the .ld and .s files also go in the C:\mbed_NUCLEO\build\mbed\TARGET_NUCLEO_L152RE\TOOLCHAIN_GCC_ARM folder also? It compiles without them being there... Also, should I have to change anything else? Could someone give me a few pointers? Any help appreciated. Cheers .:) Steve.

yes, the linker command file and the startup should be in TOOLCHAIN_ folder.

posted by Martin Kojtal 28 Mar 2014
Be the first to answer this question.