1 <!-- HTML header for doxygen 1.9.6-->
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
5 <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
6 <meta http-equiv="X-UA-Compatible" content="IE=11"/>
7 <meta name="viewport" content="width=device-width, initial-scale=1"/>
8 <title>CMSIS-Core (Cortex-M): Scatter-Loading description file <device>_ac6.sct</title>
9 <link href="doxygen.css" rel="stylesheet" type="text/css"/>
10 <link href="tabs.css" rel="stylesheet" type="text/css"/>
11 <link href="extra_navtree.css" rel="stylesheet" type="text/css"/>
12 <link href="extra_stylesheet.css" rel="stylesheet" type="text/css"/>
13 <link href="extra_search.css" rel="stylesheet" type="text/css"/>
14 <script type="text/javascript" src="jquery.js"></script>
15 <script type="text/javascript" src="dynsections.js"></script>
16 <script type="text/javascript" src="printComponentTabs.js"></script>
17 <script type="text/javascript" src="footer.js"></script>
18 <script type="text/javascript" src="navtree.js"></script>
19 <link href="navtree.css" rel="stylesheet" type="text/css"/>
20 <script type="text/javascript" src="resize.js"></script>
21 <script type="text/javascript" src="navtreedata.js"></script>
22 <script type="text/javascript" src="navtree.js"></script>
23 <link href="search/search.css" rel="stylesheet" type="text/css"/>
24 <script type="text/javascript" src="search/searchdata.js"></script>
25 <script type="text/javascript" src="search/search.js"></script>
26 <script type="text/javascript">
27 /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
28 $(document).ready(function() { init_search(); });
31 <script type="text/javascript" src="darkmode_toggle.js"></script>
32 <link href="extra_stylesheet.css" rel="stylesheet" type="text/css"/>
33 <link href="extra_navtree.css" rel="stylesheet" type="text/css"/>
34 <link href="extra_search.css" rel="stylesheet" type="text/css"/>
35 <link href="version.css" rel="stylesheet" type="text/css" />
36 <script type="text/javascript" src="../../version.js"></script>
39 <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
41 <table cellspacing="0" cellpadding="0">
43 <tr style="height: 55px;">
44 <td id="projectlogo" style="padding: 1.5em;"><img alt="Logo" src="cmsis_logo_white_small.png"/></td>
45 <td style="padding-left: 1em; padding-bottom: 1em;padding-top: 1em;">
46 <div id="projectname">CMSIS-Core (Cortex-M)
47  <span id="projectnumber"><script type="text/javascript">
49 writeHeader.call(this);
50 writeVersionDropdown.call(this, "CMSIS-Core (Cortex-M)");
55 <div id="projectbrief">CMSIS-Core support for Cortex-M processor-based devices</div>
57 <td> <div id="MSearchBox" class="MSearchBoxInactive">
59 <span id="MSearchSelect" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()"> </span>
60 <input type="text" id="MSearchField" value="" placeholder="Search" accesskey="S"
61 onfocus="searchBox.OnSearchFieldFocus(true)"
62 onblur="searchBox.OnSearchFieldFocus(false)"
63 onkeyup="searchBox.OnSearchFieldChange(event)"/>
64 </span><span class="right">
65 <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
69 <!--END !PROJECT_NAME-->
74 <!-- end header part -->
75 <div id="CMSISnav" class="tabs1">
77 <script type="text/javascript">
78 writeComponentTabs.call(this);
82 <script type="text/javascript">
83 writeSubComponentTabs.call(this);
85 <!-- Generated by Doxygen 1.9.6 -->
86 <script type="text/javascript">
87 /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
88 var searchBox = new SearchBox("searchBox", "search/",'.html');
92 <div id="side-nav" class="ui-resizable side-nav-resizable">
94 <div id="nav-tree-contents">
95 <div id="nav-sync" class="sync"></div>
98 <div id="splitbar" style="-moz-user-select:none;"
99 class="ui-resizable-handle">
102 <script type="text/javascript">
103 /* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
104 $(document).ready(function(){initNavTree('linker_sct_pg.html',''); initResizable(); });
107 <div id="doc-content">
108 <!-- window showing the filter options -->
109 <div id="MSearchSelectWindow"
110 onmouseover="return searchBox.OnSearchSelectShow()"
111 onmouseout="return searchBox.OnSearchSelectHide()"
112 onkeydown="return searchBox.OnSearchSelectKey(event)">
115 <!-- iframe showing the search results (closed by default) -->
116 <div id="MSearchResultsWindow">
117 <div id="MSearchResults">
120 <div id="SRResults"></div>
121 <div class="SRStatus" id="Loading">Loading...</div>
122 <div class="SRStatus" id="Searching">Searching...</div>
123 <div class="SRStatus" id="NoMatches">No Matches</div>
129 <div><div class="header">
130 <div class="headertitle"><div class="title">Scatter-Loading description file <device>_ac6.sct </div></div>
132 <div class="contents">
133 <div class="textblock"><p><a class="anchor" id="md_src_core_linker_sct"></a> A scatter file for linking is required when using a <a class="el" href="startup_c_pg.html">Startup File startup_<Device>.c</a>.</p>
134 <p>The <a class="el" href="linker_sct_pg.html">Scatter-Loading description file <device>_ac6.sct</a> contains regions for:</p>
136 <li>Code (read-only data, execute-only data)</li>
137 <li>RAM (read/write data, zero-initialized data)</li>
140 <li>Stack seal (for Armv8-M/v8.1-M)</li>
141 <li>CMSE veneer (for Armv8-M/v8.1-M)</li>
143 <p>Within the scatter file, the user needs to specify a set of macros. The scatter file is passed through the C preprocessor which uses these macros to calculate the start address and the size of the different regions.</p>
144 <div class="fragment"><div class="line">/*--------------------- Flash Configuration ----------------------------------</div>
145 <div class="line">; <h> Flash Configuration</div>
146 <div class="line">; <o0> Flash Base Address <0x0-0xFFFFFFFF:8></div>
147 <div class="line">; <o1> Flash Size (in Bytes) <0x0-0xFFFFFFFF:8></div>
148 <div class="line">; </h></div>
149 <div class="line"> *----------------------------------------------------------------------------*/</div>
150 <div class="line">#define __ROM_BASE 0x00000000</div>
151 <div class="line">#define __ROM_SIZE 0x00080000</div>
152 <div class="line"> </div>
153 <div class="line">/*--------------------- Embedded RAM Configuration ---------------------------</div>
154 <div class="line">; <h> RAM Configuration</div>
155 <div class="line">; <o0> RAM Base Address <0x0-0xFFFFFFFF:8></div>
156 <div class="line">; <o1> RAM Size (in Bytes) <0x0-0xFFFFFFFF:8></div>
157 <div class="line">; </h></div>
158 <div class="line"> *----------------------------------------------------------------------------*/</div>
159 <div class="line">#define __RAM_BASE 0x20000000</div>
160 <div class="line">#define __RAM_SIZE 0x00040000</div>
161 <div class="line"> </div>
162 <div class="line">/*--------------------- Stack / Heap Configuration ---------------------------</div>
163 <div class="line">; <h> Stack / Heap Configuration</div>
164 <div class="line">; <o0> Stack Size (in Bytes) <0x0-0xFFFFFFFF:8></div>
165 <div class="line">; <o1> Heap Size (in Bytes) <0x0-0xFFFFFFFF:8></div>
166 <div class="line">; </h></div>
167 <div class="line"> *----------------------------------------------------------------------------*/</div>
168 <div class="line">#define __STACK_SIZE 0x00000200</div>
169 <div class="line">#define __HEAP_SIZE 0x00000C00</div>
170 <div class="line"> </div>
171 <div class="line">/*--------------------- CMSE Veneer Configuration ---------------------------</div>
172 <div class="line">; <h> CMSE Veneer Configuration</div>
173 <div class="line">; <o0> CMSE Veneer Size (in Bytes) <0x0-0xFFFFFFFF:32></div>
174 <div class="line">; </h></div>
175 <div class="line"> *----------------------------------------------------------------------------*/</div>
176 <div class="line">#define __CMSEVENEER_SIZE 0x200</div>
177 </div><!-- fragment --><blockquote class="doxtable">
178 <p>‍<b>Note</b></p><ul>
179 <li>The stack is placed at the end of the available RAM and is growing downwards whereas the Heap is placed after the application data and growing upwards. </li>
182 <h1><a class="anchor" id="linker_sct_preproc_sec"></a>
183 Preprocessor command</h1>
184 <p>The scatter file uses following preprocessor command for Arm Compiler v6</p>
185 <div class="fragment"><div class="line">#! armclang -E --target=arm-arm-none-eabi -mcpu=&lt;mcpu&gt; -xc</div>
186 </div><!-- fragment --> </div></div><!-- contents -->
187 </div><!-- PageDoc -->
188 </div><!-- doc-content -->
189 <!-- start footer part -->
190 <div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
193 <script type="text/javascript">
195 writeFooter.call(this);