Subversion Repositories Code-Repo

Rev

Rev 249 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
249 Kevin 1
/* ============================================================================ */
2
/* Copyright (c) 2013, Texas Instruments Incorporated                           */
3
/*  All rights reserved.                                                        */
4
/*                                                                              */
5
/*  Redistribution and use in source and binary forms, with or without          */
6
/*  modification, are permitted provided that the following conditions          */
7
/*  are met:                                                                    */
8
/*                                                                              */
9
/*  *  Redistributions of source code must retain the above copyright           */
10
/*     notice, this list of conditions and the following disclaimer.            */
11
/*                                                                              */
12
/*  *  Redistributions in binary form must reproduce the above copyright        */
13
/*     notice, this list of conditions and the following disclaimer in the      */
14
/*     documentation and/or other materials provided with the distribution.     */
15
/*                                                                              */
16
/*  *  Neither the name of Texas Instruments Incorporated nor the names of      */
17
/*     its contributors may be used to endorse or promote products derived      */
18
/*     from this software without specific prior written permission.            */
19
/*                                                                              */
20
/*  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" */
21
/*  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,       */
22
/*  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR      */
23
/*  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR            */
24
/*  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,       */
25
/*  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,         */
26
/*  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; */
27
/*  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,    */
28
/*  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR     */
29
/*  OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,              */
30
/*  EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.                          */
31
/* ============================================================================ */
32
 
33
/******************************************************************************/
34
/* lnk_msp430g2231.cmd - LINKER COMMAND FILE FOR LINKING MSP430G2231 PROGRAMS     */
35
/*                                                                            */
36
/*   Usage:  lnk430 <obj files...>    -o <out file> -m <map file> lnk.cmd     */
37
/*           cl430  <src files...> -z -o <out file> -m <map file> lnk.cmd     */
38
/*                                                                            */
39
/*----------------------------------------------------------------------------*/
40
/* These linker options are for command line linking only.  For IDE linking,  */
41
/* you should set your linker options in Project Properties                   */
42
/* -c                                               LINK USING C CONVENTIONS  */
43
/* -stack  0x0100                                   SOFTWARE STACK SIZE       */
44
/* -heap   0x0100                                   HEAP AREA SIZE            */
45
/*                                                                            */
46
/*----------------------------------------------------------------------------*/
47
 
48
 
49
/****************************************************************************/
50
/* SPECIFY THE SYSTEM MEMORY MAP                                            */
51
/****************************************************************************/
52
 
53
MEMORY
54
{
55
    SFR                     : origin = 0x0000, length = 0x0010
56
    PERIPHERALS_8BIT        : origin = 0x0010, length = 0x00F0
57
    PERIPHERALS_16BIT       : origin = 0x0100, length = 0x0100
58
    RAM                     : origin = 0x0200, length = 0x0080
59
    INFOA                   : origin = 0x10C0, length = 0x0040
60
    INFOB                   : origin = 0x1080, length = 0x0040
61
    INFOC                   : origin = 0x1040, length = 0x0040
62
    INFOD                   : origin = 0x1000, length = 0x0040
63
    FLASH                   : origin = 0xF800, length = 0x07E0
64
    INT00                   : origin = 0xFFE0, length = 0x0002
65
    INT01                   : origin = 0xFFE2, length = 0x0002
66
    INT02                   : origin = 0xFFE4, length = 0x0002
67
    INT03                   : origin = 0xFFE6, length = 0x0002
68
    INT04                   : origin = 0xFFE8, length = 0x0002
69
    INT05                   : origin = 0xFFEA, length = 0x0002
70
    INT06                   : origin = 0xFFEC, length = 0x0002
71
    INT07                   : origin = 0xFFEE, length = 0x0002
72
    INT08                   : origin = 0xFFF0, length = 0x0002
73
    INT09                   : origin = 0xFFF2, length = 0x0002
74
    INT10                   : origin = 0xFFF4, length = 0x0002
75
    INT11                   : origin = 0xFFF6, length = 0x0002
76
    INT12                   : origin = 0xFFF8, length = 0x0002
77
    INT13                   : origin = 0xFFFA, length = 0x0002
78
    INT14                   : origin = 0xFFFC, length = 0x0002
79
    RESET                   : origin = 0xFFFE, length = 0x0002
80
}
81
 
82
/****************************************************************************/
83
/* SPECIFY THE SECTIONS ALLOCATION INTO MEMORY                              */
84
/****************************************************************************/
85
 
86
SECTIONS
87
{
88
    .bss        : {} > RAM                /* GLOBAL & STATIC VARS              */
89
    .data       : {} > RAM                /* GLOBAL & STATIC VARS              */
90
    .sysmem     : {} > RAM                /* DYNAMIC MEMORY ALLOCATION AREA    */
91
    .stack      : {} > RAM (HIGH)         /* SOFTWARE SYSTEM STACK             */
92
 
93
    .text       : {} > FLASH              /* CODE                              */
94
    .cinit      : {} > FLASH              /* INITIALIZATION TABLES             */
95
    .const      : {} > FLASH              /* CONSTANT DATA                     */
96
    .cio        : {} > RAM                /* C I/O BUFFER                      */
97
 
98
    .pinit      : {} > FLASH              /* C++ CONSTRUCTOR TABLES            */
99
    .init_array : {} > FLASH              /* C++ CONSTRUCTOR TABLES            */
100
    .mspabi.exidx : {} > FLASH            /* C++ CONSTRUCTOR TABLES            */
101
    .mspabi.extab : {} > FLASH            /* C++ CONSTRUCTOR TABLES            */
102
 
103
    .infoA     : {} > INFOA              /* MSP430 INFO FLASH MEMORY SEGMENTS */
104
    .infoB     : {} > INFOB
105
    .infoC     : {} > INFOC
106
    .infoD     : {} > INFOD
107
 
108
    /* MSP430 INTERRUPT VECTORS          */
109
    .int00       : {}               > INT00
110
    .int01       : {}               > INT01
111
    PORT1        : { * ( .int02 ) } > INT02 type = VECT_INIT
112
    PORT2        : { * ( .int03 ) } > INT03 type = VECT_INIT
113
    USI          : { * ( .int04 ) } > INT04 type = VECT_INIT
114
    ADC10        : { * ( .int05 ) } > INT05 type = VECT_INIT
115
    .int06       : {}               > INT06
116
    .int07       : {}               > INT07
117
    TIMERA1      : { * ( .int08 ) } > INT08 type = VECT_INIT
118
    TIMERA0      : { * ( .int09 ) } > INT09 type = VECT_INIT
119
    WDT          : { * ( .int10 ) } > INT10 type = VECT_INIT
120
    .int11       : {}               > INT11
121
    .int12       : {}               > INT12
122
    .int13       : {}               > INT13
123
    NMI          : { * ( .int14 ) } > INT14 type = VECT_INIT
124
    .reset       : {}               > RESET  /* MSP430 RESET VECTOR         */ 
125
}
126
 
127
/****************************************************************************/
128
/* INCLUDE PERIPHERALS MEMORY MAP                                           */
129
/****************************************************************************/
130
 
131
-l msp430g2231.cmd
132