ads1115 only

Fork of mbed by mbed official

Committer:
Kojto
Date:
Wed Apr 29 10:16:23 2015 +0100
Revision:
98:8ab26030e058
Parent:
88:9327015d4013
Child:
99:dbbf35b96557
Release 98 of the mbed library

Changes:
- Silabs new targets (Giant, Zero, Happy, Leopard, Wonder Geckos)
- Asynchronous SPI, I2C, Serial
- LowPower classes
- Nordic - nordic SDK v8.0 update
- Teensy - gcc arm fix for startup
- Nucleo F411 - usb freq fix

Who changed what in which revision?

UserRevisionLine numberNew contents of line
bogdanm 88:9327015d4013 1 /* Linker script to configure memory regions. */
bogdanm 88:9327015d4013 2
bogdanm 88:9327015d4013 3 MEMORY
bogdanm 88:9327015d4013 4 {
Kojto 98:8ab26030e058 5 FLASH (rx) : ORIGIN = 0x00018000, LENGTH = 0x28000
bogdanm 88:9327015d4013 6 RAM (rwx) : ORIGIN = 0x20002000, LENGTH = 0x2000
bogdanm 88:9327015d4013 7 }
bogdanm 88:9327015d4013 8
bogdanm 88:9327015d4013 9 OUTPUT_FORMAT ("elf32-littlearm", "elf32-bigarm", "elf32-littlearm")
bogdanm 88:9327015d4013 10
bogdanm 88:9327015d4013 11 /* Linker script to place sections and symbol values. Should be used together
bogdanm 88:9327015d4013 12 * with other linker script that defines memory regions FLASH and RAM.
bogdanm 88:9327015d4013 13 * It references following symbols, which must be defined in code:
bogdanm 88:9327015d4013 14 * Reset_Handler : Entry of reset handler
bogdanm 88:9327015d4013 15 *
bogdanm 88:9327015d4013 16 * It defines following symbols, which code can use without definition:
bogdanm 88:9327015d4013 17 * __exidx_start
bogdanm 88:9327015d4013 18 * __exidx_end
bogdanm 88:9327015d4013 19 * __etext
bogdanm 88:9327015d4013 20 * __data_start__
bogdanm 88:9327015d4013 21 * __preinit_array_start
bogdanm 88:9327015d4013 22 * __preinit_array_end
bogdanm 88:9327015d4013 23 * __init_array_start
bogdanm 88:9327015d4013 24 * __init_array_end
bogdanm 88:9327015d4013 25 * __fini_array_start
bogdanm 88:9327015d4013 26 * __fini_array_end
bogdanm 88:9327015d4013 27 * __data_end__
bogdanm 88:9327015d4013 28 * __bss_start__
bogdanm 88:9327015d4013 29 * __bss_end__
bogdanm 88:9327015d4013 30 * __end__
bogdanm 88:9327015d4013 31 * end
bogdanm 88:9327015d4013 32 * __HeapLimit
bogdanm 88:9327015d4013 33 * __StackLimit
bogdanm 88:9327015d4013 34 * __StackTop
bogdanm 88:9327015d4013 35 * __stack
bogdanm 88:9327015d4013 36 */
bogdanm 88:9327015d4013 37 ENTRY(Reset_Handler)
bogdanm 88:9327015d4013 38
bogdanm 88:9327015d4013 39 SECTIONS
bogdanm 88:9327015d4013 40 {
bogdanm 88:9327015d4013 41 .text :
bogdanm 88:9327015d4013 42 {
bogdanm 88:9327015d4013 43 KEEP(*(.Vectors))
bogdanm 88:9327015d4013 44 *(.text*)
bogdanm 88:9327015d4013 45
bogdanm 88:9327015d4013 46 KEEP(*(.init))
bogdanm 88:9327015d4013 47 KEEP(*(.fini))
bogdanm 88:9327015d4013 48
bogdanm 88:9327015d4013 49 /* .ctors */
bogdanm 88:9327015d4013 50 *crtbegin.o(.ctors)
bogdanm 88:9327015d4013 51 *crtbegin?.o(.ctors)
bogdanm 88:9327015d4013 52 *(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors)
bogdanm 88:9327015d4013 53 *(SORT(.ctors.*))
bogdanm 88:9327015d4013 54 *(.ctors)
bogdanm 88:9327015d4013 55
bogdanm 88:9327015d4013 56 /* .dtors */
bogdanm 88:9327015d4013 57 *crtbegin.o(.dtors)
bogdanm 88:9327015d4013 58 *crtbegin?.o(.dtors)
bogdanm 88:9327015d4013 59 *(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors)
bogdanm 88:9327015d4013 60 *(SORT(.dtors.*))
bogdanm 88:9327015d4013 61 *(.dtors)
bogdanm 88:9327015d4013 62
bogdanm 88:9327015d4013 63 *(.rodata*)
bogdanm 88:9327015d4013 64
bogdanm 88:9327015d4013 65 KEEP(*(.eh_frame*))
bogdanm 88:9327015d4013 66 } > FLASH
bogdanm 88:9327015d4013 67
bogdanm 88:9327015d4013 68
bogdanm 88:9327015d4013 69 .ARM.extab :
bogdanm 88:9327015d4013 70 {
bogdanm 88:9327015d4013 71 *(.ARM.extab* .gnu.linkonce.armextab.*)
bogdanm 88:9327015d4013 72 } > FLASH
bogdanm 88:9327015d4013 73
bogdanm 88:9327015d4013 74 __exidx_start = .;
bogdanm 88:9327015d4013 75 .ARM.exidx :
bogdanm 88:9327015d4013 76 {
bogdanm 88:9327015d4013 77 *(.ARM.exidx* .gnu.linkonce.armexidx.*)
bogdanm 88:9327015d4013 78 } > FLASH
bogdanm 88:9327015d4013 79 __exidx_end = .;
bogdanm 88:9327015d4013 80
bogdanm 88:9327015d4013 81 __etext = .;
bogdanm 88:9327015d4013 82
bogdanm 88:9327015d4013 83 .data : AT (__etext)
bogdanm 88:9327015d4013 84 {
bogdanm 88:9327015d4013 85 __data_start__ = .;
bogdanm 88:9327015d4013 86 *(vtable)
bogdanm 88:9327015d4013 87 *(.data*)
bogdanm 88:9327015d4013 88
bogdanm 88:9327015d4013 89 . = ALIGN(4);
bogdanm 88:9327015d4013 90 /* preinit data */
bogdanm 88:9327015d4013 91 PROVIDE_HIDDEN (__preinit_array_start = .);
bogdanm 88:9327015d4013 92 KEEP(*(.preinit_array))
bogdanm 88:9327015d4013 93 PROVIDE_HIDDEN (__preinit_array_end = .);
bogdanm 88:9327015d4013 94
bogdanm 88:9327015d4013 95 . = ALIGN(4);
bogdanm 88:9327015d4013 96 /* init data */
bogdanm 88:9327015d4013 97 PROVIDE_HIDDEN (__init_array_start = .);
bogdanm 88:9327015d4013 98 KEEP(*(SORT(.init_array.*)))
bogdanm 88:9327015d4013 99 KEEP(*(.init_array))
bogdanm 88:9327015d4013 100 PROVIDE_HIDDEN (__init_array_end = .);
bogdanm 88:9327015d4013 101
bogdanm 88:9327015d4013 102
bogdanm 88:9327015d4013 103 . = ALIGN(4);
bogdanm 88:9327015d4013 104 /* finit data */
bogdanm 88:9327015d4013 105 PROVIDE_HIDDEN (__fini_array_start = .);
bogdanm 88:9327015d4013 106 KEEP(*(SORT(.fini_array.*)))
bogdanm 88:9327015d4013 107 KEEP(*(.fini_array))
bogdanm 88:9327015d4013 108 PROVIDE_HIDDEN (__fini_array_end = .);
bogdanm 88:9327015d4013 109
bogdanm 88:9327015d4013 110 *(.jcr)
bogdanm 88:9327015d4013 111 . = ALIGN(4);
bogdanm 88:9327015d4013 112 /* All data end */
bogdanm 88:9327015d4013 113 __data_end__ = .;
bogdanm 88:9327015d4013 114
bogdanm 88:9327015d4013 115 } > RAM
bogdanm 88:9327015d4013 116
bogdanm 88:9327015d4013 117 .bss :
bogdanm 88:9327015d4013 118 {
bogdanm 88:9327015d4013 119 . = ALIGN(4);
bogdanm 88:9327015d4013 120 __bss_start__ = .;
bogdanm 88:9327015d4013 121 *(.bss*)
bogdanm 88:9327015d4013 122 *(COMMON)
bogdanm 88:9327015d4013 123 . = ALIGN(4);
bogdanm 88:9327015d4013 124 __bss_end__ = .;
bogdanm 88:9327015d4013 125 } > RAM
bogdanm 88:9327015d4013 126
bogdanm 88:9327015d4013 127 .heap (COPY):
bogdanm 88:9327015d4013 128 {
bogdanm 88:9327015d4013 129 __end__ = .;
bogdanm 88:9327015d4013 130 end = __end__;
bogdanm 88:9327015d4013 131 *(.heap*)
bogdanm 88:9327015d4013 132 __HeapLimit = .;
bogdanm 88:9327015d4013 133 } > RAM
bogdanm 88:9327015d4013 134
bogdanm 88:9327015d4013 135 /* .stack_dummy section doesn't contains any symbols. It is only
bogdanm 88:9327015d4013 136 * used for linker to calculate size of stack sections, and assign
bogdanm 88:9327015d4013 137 * values to stack symbols later */
bogdanm 88:9327015d4013 138 .stack_dummy (COPY):
bogdanm 88:9327015d4013 139 {
bogdanm 88:9327015d4013 140 *(.stack*)
bogdanm 88:9327015d4013 141 } > RAM
bogdanm 88:9327015d4013 142
bogdanm 88:9327015d4013 143 /* Set stack top to end of RAM, and stack limit move down by
bogdanm 88:9327015d4013 144 * size of stack_dummy section */
bogdanm 88:9327015d4013 145 __StackTop = ORIGIN(RAM) + LENGTH(RAM);
bogdanm 88:9327015d4013 146 __StackLimit = __StackTop - SIZEOF(.stack_dummy);
bogdanm 88:9327015d4013 147 PROVIDE(__stack = __StackTop);
bogdanm 88:9327015d4013 148
bogdanm 88:9327015d4013 149 /* Check if data + heap + stack exceeds RAM limit */
bogdanm 88:9327015d4013 150 ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack")
bogdanm 88:9327015d4013 151 }