<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: S12XF512 - big array is not initialized correctly in S12 / MagniV Microcontrollers</title>
    <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12XF512-big-array-is-not-initialized-correctly/m-p/165167#M5360</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thank you for your help and advices.&lt;/P&gt;&lt;P&gt;Now I mapped my array to the mapped RAM...&lt;/P&gt;&lt;P&gt;There it is working.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;greetings Philipp&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Nov 2010 17:13:23 GMT</pubDate>
    <dc:creator>philipp_k</dc:creator>
    <dc:date>2010-11-26T17:13:23Z</dc:date>
    <item>
      <title>S12XF512 - big array is not initialized correctly</title>
      <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12XF512-big-array-is-not-initialized-correctly/m-p/165165#M5358</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Everybody,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in the file blubb.c I have defined and initialized an array of structures. The array is called "Msg_List".&lt;/P&gt;&lt;P&gt;&amp;nbsp;But if I step through my code only the items of the array located below the adress 0x3000 are initialized correctly.&lt;/P&gt;&lt;P&gt;All items in this structure following from adress 0x3000 have values I did not entered in the source code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using banked memory model. And I get no errors on compiling.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any ideas why this is happening ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks Philipp&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is an excerpt from the map file:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;OBJECT-ALLOCATION SECTION&lt;BR /&gt;&amp;nbsp; Name &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Module &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Addr &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;hSize &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;dSize &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Ref Section &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;RLIB&lt;BR /&gt;---------------------------------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;MODULE: &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;-- blubb.c.o --&lt;BR /&gt;- PROCEDURES:&lt;BR /&gt;- VARIABLES:&lt;BR /&gt;&amp;nbsp; Msg_List &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 2E3F &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 47C &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1148 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; .data &amp;nbsp;&lt;BR /&gt;&amp;nbsp; Frame_Config &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 32BB &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;70 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 112 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; .data&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Nov 2010 01:10:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12XF512-big-array-is-not-initialized-correctly/m-p/165165#M5358</guid>
      <dc:creator>philipp_k</dc:creator>
      <dc:date>2010-11-25T01:10:24Z</dc:date>
    </item>
    <item>
      <title>Re: S12XF512 - big array is not initialized correctly</title>
      <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12XF512-big-array-is-not-initialized-correctly/m-p/165166#M5359</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Works for me &lt;IMG alt="Smiley Wink" class="emoticon emoticon-smileywink" id="smileywink" src="https://community.nxp.com/i/smilies/16x16_smiley-wink.png" title="Smiley Wink" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here's what I tried:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;#include &amp;lt;hidef.h&amp;gt;#include "derivative.h"#define CHARS_10 "1234567890"#define CHARS_20 CHARS_10 CHARS_10#define CHARS_40 CHARS_20 CHARS_20#define CHARS_100 CHARS_40 CHARS_40 CHARS_20#define CHARS_200 CHARS_100 CHARS_100#define CHARS_400 CHARS_200 CHARS_200#define CHARS_800 CHARS_400 CHARS_400char Msg_List[1148] @ 0x2E3F =CHARS_800 CHARS_200 CHARS_100 CHARS_40 "1234567";void main(void) {  for(;;) {    _FEED_COP();  }}&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is the boundary of the incorrect initialization at exact 0x3000?&lt;/P&gt;&lt;P&gt;There is no boundary at that address if the RAM is accessed using its unpaged address, I assume you use the 0x2000 ram unpaged (say not with its 0xFE1000'L or 0xFE000'G alias addresses).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;Also have a look at the COPYDOWN SECTION in the map file, it shows what the startup code should be initializing.&lt;/DIV&gt;&lt;DIV&gt;&lt;PRE&gt;*********************************************************************************************COPYDOWN SECTION---------------------------------------------------------------------------------------------------- ROM-ADDRESS: 0xC031 ---- SIZE       4 ---Filling bytes inserted 1F402100------- ROM-ADDRESS: 0xC035 ---- RAM-ADDRESS: 0x2100 ---- SIZE    8000 ---Name of initialized Object : Msg_List1 3132333435 3637383930 3132333435&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;Anything else special (like using define&amp;nbsp;__FAR_DATA, special prm file, adapted startup code,....)?&lt;/DIV&gt;&lt;DIV&gt;Daniel&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Oct 2020 09:11:28 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12XF512-big-array-is-not-initialized-correctly/m-p/165166#M5359</guid>
      <dc:creator>CompilerGuru</dc:creator>
      <dc:date>2020-10-29T09:11:28Z</dc:date>
    </item>
    <item>
      <title>Re: S12XF512 - big array is not initialized correctly</title>
      <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12XF512-big-array-is-not-initialized-correctly/m-p/165167#M5360</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thank you for your help and advices.&lt;/P&gt;&lt;P&gt;Now I mapped my array to the mapped RAM...&lt;/P&gt;&lt;P&gt;There it is working.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;greetings Philipp&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Nov 2010 17:13:23 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/S12XF512-big-array-is-not-initialized-correctly/m-p/165167#M5360</guid>
      <dc:creator>philipp_k</dc:creator>
      <dc:date>2010-11-26T17:13:23Z</dc:date>
    </item>
  </channel>
</rss>

