Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- STM32F4.ld
- Development board: STM32F407VGT6
- */
- /* Entry Point */
- ENTRY(RESET);
- /* Highest address of the user mode stack */
- _end_stack = 0x10010000;
- /* Generate a link error if the stack doesn't fit into ccm */
- _min_stack_size = 0x1000;
- /* Specify the memory areas */
- MEMORY
- {
- FLASH (rx) : ORIGIN = 0x08000000, LENGTH = 1024K
- CCM (xrw) : ORIGIN = 0X10000000, LENGTH = 64K
- BUFFER1 (xrw) : ORIGIN = 0x20000000, LENGTH = 112K
- BUFFER2 (xrw) : ORIGIN = 0x2001C000, LENGTH = 16K
- FPGA (rw) : ORIGIN = 0x60000000, LENGTH = 0K
- }
- /* Define output sections */
- SECTIONS
- {
- /* Startup code first in flash */
- .isr_vector :
- {
- . = ALIGN(4);
- KEEP(*(.isr_vector)) /* Startup Code */
- . = ALIGN(4);
- } >FLASH
- /* Program code and data located in flash */
- .text :
- {
- . = ALIGN(4);
- *(.text) /* .text sections (code) */
- *(.text*) /* .text* sections (code) */
- *(.rodata) /* .rodata sections (constants, strings, etc.) */
- *(.rodata*) /* .rodata* sections (constants, strings, etc.) */
- *(.glue_7) /* glue arm to thumb code */
- *(.glue_7t) /* glue thumb to arm code */
- . = ALIGN(4);
- _etext = .; /* define a global symbols at end of code */
- } >FLASH
- _start_ram = .;
- /* Initialized data section */
- .data : AT (_start_ram)
- {
- . = ALIGN(4);
- _start_data = .;
- *(.data)
- *(.data*)
- _end_data = .;
- } >CCM
- /* Unintialized data section */
- .bss (NOLOAD) :
- {
- . = ALIGN(4);
- _start_bss = .;
- *(.bss)
- *(.bss*)
- *(COMMON)
- _end_bss = .;
- } >CCM
- /* Use this code to check that there is at least 4KB left for the stack */
- ._stack :
- {
- . = ALIGN(4);
- . = . + _min_stack_size;
- . = ALIGN(4);
- } >CCM
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement