The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.

Dependents:   hello SerialTestv11 SerialTestv12 Sierpinski ... more

mbed 2

This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.

Committer:
Kojto
Date:
Tue May 10 12:23:43 2016 -0500
Revision:
120:7c328cabac7e
Child:
130:d75b3fe1f5cb
Release 120 of the mbed library

Changes:
- ST - STMF3XX/F4XX - directories removal
- STMF3 - pwm range fix
- STMF1 - Cube driver update
- Renesas - RZ_A1H - async i2c, serial and spi addition
- Freescale - KSDK2 update

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Kojto 120:7c328cabac7e 1 /*
Kojto 120:7c328cabac7e 2 ** ###################################################################
Kojto 120:7c328cabac7e 3 ** Processors: MK64FN1M0VDC12
Kojto 120:7c328cabac7e 4 ** MK64FN1M0VLL12
Kojto 120:7c328cabac7e 5 ** MK64FN1M0VLQ12
Kojto 120:7c328cabac7e 6 ** MK64FN1M0VMD12
Kojto 120:7c328cabac7e 7 **
Kojto 120:7c328cabac7e 8 ** Compiler: IAR ANSI C/C++ Compiler for ARM
Kojto 120:7c328cabac7e 9 ** Reference manual: K64P144M120SF5RM, Rev.2, January 2014
Kojto 120:7c328cabac7e 10 ** Version: rev. 2.8, 2015-02-19
Kojto 120:7c328cabac7e 11 ** Build: b151009
Kojto 120:7c328cabac7e 12 **
Kojto 120:7c328cabac7e 13 ** Abstract:
Kojto 120:7c328cabac7e 14 ** Linker file for the IAR ANSI C/C++ Compiler for ARM
Kojto 120:7c328cabac7e 15 **
Kojto 120:7c328cabac7e 16 ** Copyright (c) 2015 Freescale Semiconductor, Inc.
Kojto 120:7c328cabac7e 17 ** All rights reserved.
Kojto 120:7c328cabac7e 18 **
Kojto 120:7c328cabac7e 19 ** Redistribution and use in source and binary forms, with or without modification,
Kojto 120:7c328cabac7e 20 ** are permitted provided that the following conditions are met:
Kojto 120:7c328cabac7e 21 **
Kojto 120:7c328cabac7e 22 ** o Redistributions of source code must retain the above copyright notice, this list
Kojto 120:7c328cabac7e 23 ** of conditions and the following disclaimer.
Kojto 120:7c328cabac7e 24 **
Kojto 120:7c328cabac7e 25 ** o Redistributions in binary form must reproduce the above copyright notice, this
Kojto 120:7c328cabac7e 26 ** list of conditions and the following disclaimer in the documentation and/or
Kojto 120:7c328cabac7e 27 ** other materials provided with the distribution.
Kojto 120:7c328cabac7e 28 **
Kojto 120:7c328cabac7e 29 ** o Neither the name of Freescale Semiconductor, Inc. nor the names of its
Kojto 120:7c328cabac7e 30 ** contributors may be used to endorse or promote products derived from this
Kojto 120:7c328cabac7e 31 ** software without specific prior written permission.
Kojto 120:7c328cabac7e 32 **
Kojto 120:7c328cabac7e 33 ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
Kojto 120:7c328cabac7e 34 ** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
Kojto 120:7c328cabac7e 35 ** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
Kojto 120:7c328cabac7e 36 ** DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
Kojto 120:7c328cabac7e 37 ** ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
Kojto 120:7c328cabac7e 38 ** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
Kojto 120:7c328cabac7e 39 ** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
Kojto 120:7c328cabac7e 40 ** ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
Kojto 120:7c328cabac7e 41 ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
Kojto 120:7c328cabac7e 42 ** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Kojto 120:7c328cabac7e 43 **
Kojto 120:7c328cabac7e 44 ** http: www.freescale.com
Kojto 120:7c328cabac7e 45 ** mail: support@freescale.com
Kojto 120:7c328cabac7e 46 **
Kojto 120:7c328cabac7e 47 ** ###################################################################
Kojto 120:7c328cabac7e 48 */
Kojto 120:7c328cabac7e 49 define symbol __ram_vector_table__ = 1;
Kojto 120:7c328cabac7e 50
Kojto 120:7c328cabac7e 51 /* Heap 1/4 of ram and stack 1/8 */
Kojto 120:7c328cabac7e 52 define symbol __stack_size__=0x8000;
Kojto 120:7c328cabac7e 53 define symbol __heap_size__=0x10000;
Kojto 120:7c328cabac7e 54
Kojto 120:7c328cabac7e 55 define symbol __ram_vector_table_size__ = isdefinedsymbol(__ram_vector_table__) ? 0x00000400 : 0;
Kojto 120:7c328cabac7e 56 define symbol __ram_vector_table_offset__ = isdefinedsymbol(__ram_vector_table__) ? 0x000003FF : 0;
Kojto 120:7c328cabac7e 57
Kojto 120:7c328cabac7e 58 define symbol m_interrupts_start = 0x00000000;
Kojto 120:7c328cabac7e 59 define symbol m_interrupts_end = 0x000003FF;
Kojto 120:7c328cabac7e 60
Kojto 120:7c328cabac7e 61 define symbol m_flash_config_start = 0x00000400;
Kojto 120:7c328cabac7e 62 define symbol m_flash_config_end = 0x0000040F;
Kojto 120:7c328cabac7e 63
Kojto 120:7c328cabac7e 64 define symbol m_text_start = 0x00000410;
Kojto 120:7c328cabac7e 65 define symbol m_text_end = 0x000FFFFF;
Kojto 120:7c328cabac7e 66
Kojto 120:7c328cabac7e 67 define symbol m_interrupts_ram_start = 0x1FFF0000;
Kojto 120:7c328cabac7e 68 define symbol m_interrupts_ram_end = 0x1FFF0000 + __ram_vector_table_offset__;
Kojto 120:7c328cabac7e 69
Kojto 120:7c328cabac7e 70 define symbol m_data_start = m_interrupts_ram_start + __ram_vector_table_size__;
Kojto 120:7c328cabac7e 71 define symbol m_data_end = 0x1FFFFFFF;
Kojto 120:7c328cabac7e 72
Kojto 120:7c328cabac7e 73 define symbol m_data_2_start = 0x20000000;
Kojto 120:7c328cabac7e 74 define symbol m_data_2_end = 0x2002FFFF;
Kojto 120:7c328cabac7e 75
Kojto 120:7c328cabac7e 76 /* Sizes */
Kojto 120:7c328cabac7e 77 if (isdefinedsymbol(__stack_size__)) {
Kojto 120:7c328cabac7e 78 define symbol __size_cstack__ = __stack_size__;
Kojto 120:7c328cabac7e 79 } else {
Kojto 120:7c328cabac7e 80 define symbol __size_cstack__ = 0x0400;
Kojto 120:7c328cabac7e 81 }
Kojto 120:7c328cabac7e 82
Kojto 120:7c328cabac7e 83 if (isdefinedsymbol(__heap_size__)) {
Kojto 120:7c328cabac7e 84 define symbol __size_heap__ = __heap_size__;
Kojto 120:7c328cabac7e 85 } else {
Kojto 120:7c328cabac7e 86 define symbol __size_heap__ = 0x0400;
Kojto 120:7c328cabac7e 87 }
Kojto 120:7c328cabac7e 88
Kojto 120:7c328cabac7e 89 define exported symbol __VECTOR_TABLE = m_interrupts_start;
Kojto 120:7c328cabac7e 90 define exported symbol __VECTOR_RAM = isdefinedsymbol(__ram_vector_table__) ? m_interrupts_ram_start : m_interrupts_start;
Kojto 120:7c328cabac7e 91 define exported symbol __RAM_VECTOR_TABLE_SIZE = __ram_vector_table_size__;
Kojto 120:7c328cabac7e 92
Kojto 120:7c328cabac7e 93 define memory mem with size = 4G;
Kojto 120:7c328cabac7e 94 define region m_flash_config_region = mem:[from m_flash_config_start to m_flash_config_end];
Kojto 120:7c328cabac7e 95 define region TEXT_region = mem:[from m_interrupts_start to m_interrupts_end]
Kojto 120:7c328cabac7e 96 | mem:[from m_text_start to m_text_end];
Kojto 120:7c328cabac7e 97 define region DATA_region = mem:[from m_data_start to m_data_end]
Kojto 120:7c328cabac7e 98 | mem:[from m_data_2_start to m_data_2_end-__size_cstack__];
Kojto 120:7c328cabac7e 99 define region CSTACK_region = mem:[from m_data_2_end-__size_cstack__+1 to m_data_2_end];
Kojto 120:7c328cabac7e 100 define region m_interrupts_ram_region = mem:[from m_interrupts_ram_start to m_interrupts_ram_end];
Kojto 120:7c328cabac7e 101
Kojto 120:7c328cabac7e 102 define block CSTACK with alignment = 8, size = __size_cstack__ { };
Kojto 120:7c328cabac7e 103 define block HEAP with alignment = 8, size = __size_heap__ { };
Kojto 120:7c328cabac7e 104 define block RW { readwrite };
Kojto 120:7c328cabac7e 105 define block ZI { zi };
Kojto 120:7c328cabac7e 106
Kojto 120:7c328cabac7e 107 initialize by copy { readwrite, section .textrw };
Kojto 120:7c328cabac7e 108 do not initialize { section .noinit };
Kojto 120:7c328cabac7e 109
Kojto 120:7c328cabac7e 110 place at address mem: m_interrupts_start { readonly section .intvec };
Kojto 120:7c328cabac7e 111 place in m_flash_config_region { section FlashConfig };
Kojto 120:7c328cabac7e 112 place in TEXT_region { readonly };
Kojto 120:7c328cabac7e 113 place in DATA_region { block RW };
Kojto 120:7c328cabac7e 114 place in DATA_region { block ZI };
Kojto 120:7c328cabac7e 115 place in DATA_region { last block HEAP };
Kojto 120:7c328cabac7e 116 place in CSTACK_region { block CSTACK };
Kojto 120:7c328cabac7e 117 place in m_interrupts_ram_region { section m_interrupts_ram };
Kojto 120:7c328cabac7e 118