Skip to content

Commit 587c657

Browse files
committed
add MKL25Z4 project template
1 parent fb8a830 commit 587c657

File tree

10 files changed

+1585
-0
lines changed

10 files changed

+1585
-0
lines changed
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
#! armcc -E
2+
/*
3+
** ###################################################################
4+
** Processors: MKL25Z128VFM4
5+
** MKL25Z128VFT4
6+
** MKL25Z128VLH4
7+
** MKL25Z128VLK4
8+
**
9+
** Compiler: Keil ARM C/C++ Compiler
10+
** Reference manual: KL25P80M48SF0RM, Rev.3, Sep 2012
11+
** Version: rev. 2.5, 2015-02-19
12+
** Build: b170214
13+
**
14+
** Abstract:
15+
** Linker file for the Keil ARM C/C++ Compiler
16+
**
17+
** Copyright 2016 Freescale Semiconductor, Inc.
18+
** Copyright 2016-2017 NXP
19+
** Redistribution and use in source and binary forms, with or without modification,
20+
** are permitted provided that the following conditions are met:
21+
**
22+
** o Redistributions of source code must retain the above copyright notice, this list
23+
** of conditions and the following disclaimer.
24+
**
25+
** o Redistributions in binary form must reproduce the above copyright notice, this
26+
** list of conditions and the following disclaimer in the documentation and/or
27+
** other materials provided with the distribution.
28+
**
29+
** o Neither the name of the copyright holder nor the names of its
30+
** contributors may be used to endorse or promote products derived from this
31+
** software without specific prior written permission.
32+
**
33+
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
34+
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
35+
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
36+
** DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
37+
** ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
38+
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
39+
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
40+
** ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
41+
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
42+
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
43+
**
44+
** http: www.nxp.com
45+
** mail: support@nxp.com
46+
**
47+
** ###################################################################
48+
*/
49+
50+
#if (defined(__ram_vector_table__))
51+
#define __ram_vector_table_size__ 0x00000200
52+
#else
53+
#define __ram_vector_table_size__ 0x00000000
54+
#endif
55+
56+
#define m_interrupts_start 0x00000000
57+
#define m_interrupts_size 0x00000200
58+
59+
#define m_flash_config_start 0x00000400
60+
#define m_flash_config_size 0x00000010
61+
62+
#define m_text_start 0x00000410
63+
#define m_text_size 0x0001FBF0
64+
65+
#define m_interrupts_ram_start 0x1FFFF000
66+
#define m_interrupts_ram_size __ram_vector_table_size__
67+
68+
#define m_data_start (m_interrupts_ram_start + m_interrupts_ram_size)
69+
#define m_data_size (0x00004000 - m_interrupts_ram_size)
70+
71+
/* Sizes */
72+
#if (defined(__stack_size__))
73+
#define Stack_Size __stack_size__
74+
#else
75+
#define Stack_Size 0x0400
76+
#endif
77+
78+
#if (defined(__heap_size__))
79+
#define Heap_Size __heap_size__
80+
#else
81+
#define Heap_Size 0x0400
82+
#endif
83+
84+
LR_m_text m_interrupts_start m_text_start+m_text_size-m_interrupts_start { ; load region size_region
85+
VECTOR_ROM m_interrupts_start m_interrupts_size { ; load address = execution address
86+
* (RESET,+FIRST)
87+
}
88+
ER_m_flash_config m_flash_config_start FIXED m_flash_config_size { ; load address = execution address
89+
* (FlashConfig)
90+
}
91+
ER_m_text m_text_start m_text_size { ; load address = execution address
92+
* (InRoot$$Sections)
93+
.ANY (+RO)
94+
}
95+
96+
#if (defined(__ram_vector_table__))
97+
VECTOR_RAM m_interrupts_ram_start EMPTY m_interrupts_ram_size {
98+
}
99+
#else
100+
VECTOR_RAM m_interrupts_start EMPTY 0 {
101+
}
102+
#endif
103+
RW_m_data m_data_start m_data_size-Stack_Size-Heap_Size { ; RW data
104+
.ANY (+RW +ZI)
105+
}
106+
ARM_LIB_HEAP +0 EMPTY Heap_Size { ; Heap region growing up
107+
}
108+
ARM_LIB_STACK m_data_start+m_data_size EMPTY -Stack_Size { ; Stack region growing down
109+
}
110+
}
111+
Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
#! armcc -E
2+
/*
3+
** ###################################################################
4+
** Processors: MKL25Z128VFM4
5+
** MKL25Z128VFT4
6+
** MKL25Z128VLH4
7+
** MKL25Z128VLK4
8+
**
9+
** Compiler: Keil ARM C/C++ Compiler
10+
** Reference manual: KL25P80M48SF0RM, Rev.3, Sep 2012
11+
** Version: rev. 2.5, 2015-02-19
12+
** Build: b170214
13+
**
14+
** Abstract:
15+
** Linker file for the Keil ARM C/C++ Compiler
16+
**
17+
** Copyright 2016 Freescale Semiconductor, Inc.
18+
** Copyright 2016-2017 NXP
19+
** Redistribution and use in source and binary forms, with or without modification,
20+
** are permitted provided that the following conditions are met:
21+
**
22+
** o Redistributions of source code must retain the above copyright notice, this list
23+
** of conditions and the following disclaimer.
24+
**
25+
** o Redistributions in binary form must reproduce the above copyright notice, this
26+
** list of conditions and the following disclaimer in the documentation and/or
27+
** other materials provided with the distribution.
28+
**
29+
** o Neither the name of the copyright holder nor the names of its
30+
** contributors may be used to endorse or promote products derived from this
31+
** software without specific prior written permission.
32+
**
33+
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
34+
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
35+
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
36+
** DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
37+
** ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
38+
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
39+
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
40+
** ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
41+
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
42+
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
43+
**
44+
** http: www.nxp.com
45+
** mail: support@nxp.com
46+
**
47+
** ###################################################################
48+
*/
49+
50+
#define m_interrupts_start 0x1FFFF000
51+
#define m_interrupts_size 0x00000200
52+
53+
#define m_data_start 0x1FFFF200
54+
#define m_data_size 0x00000E00
55+
56+
#define m_text_start 0x20000000
57+
#define m_text_size 0x00003000
58+
59+
/* Sizes */
60+
#if (defined(__stack_size__))
61+
#define Stack_Size __stack_size__
62+
#else
63+
#define Stack_Size 0x0400
64+
#endif
65+
66+
#if (defined(__heap_size__))
67+
#define Heap_Size __heap_size__
68+
#else
69+
#define Heap_Size 0x0400
70+
#endif
71+
72+
LR_m_text m_text_start m_text_size { ; load region size_region
73+
ER_m_text m_text_start m_text_size { ; load address = execution address
74+
* (InRoot$$Sections)
75+
.ANY (+RO)
76+
}
77+
78+
RW_m_data m_data_start m_data_size-Stack_Size-Heap_Size { ; RW data
79+
.ANY (+RW +ZI)
80+
}
81+
ARM_LIB_HEAP +0 EMPTY Heap_Size { ; Heap region growing up
82+
}
83+
ARM_LIB_STACK m_data_start+m_data_size EMPTY -Stack_Size { ; Stack region growing down
84+
}
85+
}
86+
87+
LR_m_interrupts m_interrupts_start m_interrupts_size {
88+
VECTOR_ROM m_interrupts_start m_interrupts_size { ; load address = execution address
89+
* (RESET,+FIRST)
90+
}
91+
}
92+
93+
LR_m_interrupts_ram m_interrupts_start m_interrupts_size {
94+
VECTOR_RAM m_interrupts_start m_interrupts_size { ; load address = execution address
95+
.ANY (.m_interrupts_ram)
96+
}
97+
}
98+

0 commit comments

Comments
 (0)