cancel
Showing results for 
Search instead for 
Did you mean: 

Codesourcery startup and link file for STM32

Kuikui
Associate III
Posted on September 02, 2010 at 21:48

Codesourcery startup and link file for STM32

11 REPLIES 11
Posted on May 17, 2011 at 14:05

MEMORY /* STM32F102R8 64K FLASH, 10K RAM */

{

    FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 64K

    SRAM (rwx) : ORIGIN = 0x20000000, LENGTH = 10K

}

Check also _stack, and _estack in .MAP file generated by the linker. And more generally verify that the RAM based allocations are in the 20000000..200027FF range. The linker should choke if the limits in the script are exceeded, but if those are wrong the CPU will fault as your initialization routines touch memory that is not present.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Kuikui
Associate III
Posted on May 17, 2011 at 14:05

I finally took ride's startup and linker script file, and everything's fine now.

Many thanks to all !