ads1115 only

Fork of mbed by mbed official

Committer:
Kojto
Date:
Thu Jul 07 14:34:11 2016 +0100
Revision:
122:f9eeca106725
Parent:
108:34e6b704fe68
Child:
132:9baf128c2fab
Release 122 of the mbed library

Changes:
- new targets - Nucleo L432KC, Beetle, Nucleo F446ZE, Nucleo L011K4
- Thread safety addition - mbed API should contain a statement about thread safety
- critical section API addition
- CAS API (core_util_atomic_incr/decr)
- DEVICE_ are generated from targets.json file, device.h deprecated
- Callback replaces FunctionPointer to provide std like interface
- mbed HAL API docs improvements
- toolchain - prexif attributes with MBED_
- add new attributes - packed, weak, forcedinline, align
- target.json - contains targets definitions
- ST - L1XX - Cube update to 1.5
- SPI clock selection fix (clock from APB domain)
- F7 - Cube update v1.4.0
- L0 - baudrate init fix
- L1 - Cube update v1.5
- F3 - baudrate init fix, 3 targets CAN support
- F4 - Cube update v1.12.0, 3 targets CAN support
- L4XX - Cube update v1.5.1
- F0 - update Cube to v1.5.0
- L4 - 2 targets (L476RG/VG) CAN support
- NXP - pwm clock fix for KSDK2 MCU
- LPC2368 - remove ARM toolchain support - due to regression
- KSDK2 - fix SPI , I2C address and repeat start
- Silabs - some fixes backported from mbed 3
- Renesas - RZ_A1H - SystemCoreClockUpdate addition

Who changed what in which revision?

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