<?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>CodeWarrior for MCUのトピックRe: External SRAM problem in CodeWarrior V4.5 for hCS12</title>
    <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/External-SRAM-problem-in-CodeWarrior-V4-5-for-hCS12/m-p/128941#M841</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;Mr SlyFox&lt;BR /&gt;I appreciate your reply.&lt;BR /&gt;I had a couple of typo's on posting my PRM stuff here.&lt;BR /&gt;RAM is actually at 0x400 to 0x1fff.ERAM is actually at&lt;BR /&gt;0x2000 to 0x7fff.&lt;BR /&gt;Bummer that method 1 doesn't work.The only way that&lt;BR /&gt;I can get my external SRAM to work is by using method 2&lt;BR /&gt;which really limits my application a lot.I wish freescale&lt;BR /&gt;provided a few more code examples of various apps(maybe&lt;BR /&gt;they could check the Zilog website and study it).I would&lt;BR /&gt;definitely like to see a code example where external SRAM is utilized in the banked memory model.On the other&lt;BR /&gt;hand,maybe there are lots of code examples that I haven't&lt;BR /&gt;found.&lt;BR /&gt;Signing off...&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 08 Sep 2006 22:18:55 GMT</pubDate>
    <dc:creator>eddie</dc:creator>
    <dc:date>2006-09-08T22:18:55Z</dc:date>
    <item>
      <title>External SRAM problem in CodeWarrior V4.5 for hCS12</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/External-SRAM-problem-in-CodeWarrior-V4-5-for-hCS12/m-p/128939#M839</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt;Hi&lt;/DIV&gt;&lt;DIV&gt;using&amp;nbsp; Axiom EVB9S12NE64.&lt;/DIV&gt;&lt;DIV&gt;trying to use external SRAM in banked memory model&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;can't bank SRAM in banked memory model.OK&lt;/DIV&gt;&lt;DIV&gt;I can live with 24K&lt;/DIV&gt;&lt;DIV&gt;issue is PRM file&lt;/DIV&gt;&lt;DIV&gt;here's segments &amp;amp; placement:&lt;/DIV&gt;&lt;DIV&gt;SEGMENTS&lt;/DIV&gt;&lt;DIV&gt;RAM=READ_WRITE 0x400 TO 7FFF; //internal SRAM&lt;/DIV&gt;&lt;DIV&gt;ERAM=READ_WRITE 0x200 to 0x7FFF; //24K of external SRAM&lt;/DIV&gt;&lt;DIV&gt;ROM_C000=READ_ONLY 0xC000 to 0x777F; //unbanked flash&lt;/DIV&gt;&lt;DIV&gt;PAGE_3C=READ_ONLY 0x3C8000 to 0x3CBFFF; //banked flash&lt;/DIV&gt;&lt;DIV&gt;END&lt;/DIV&gt;&lt;DIV&gt;PLACEMENT&lt;/DIV&gt;&lt;DIV&gt;_PRESTART,STARTUP,ROM_VAR,STRINGS,VIRTUAL_TABLE_SEGMENT,NON_BANKED,&lt;/DIV&gt;&lt;DIV&gt;COPY INTO ROM_C000;&lt;/DIV&gt;&lt;DIV&gt;DEFAULT_ROM INTO PAGE_3C;&lt;/DIV&gt;&lt;DIV&gt;DEFAULT_RAM INTO RAM,ERAM;&lt;/DIV&gt;&lt;DIV&gt;END&lt;/DIV&gt;&lt;DIV&gt;I try to write/verify to 24K in SRAM(big array)&amp;nbsp;in main()&lt;/DIV&gt;&lt;DIV&gt;Code compiles okay but write/verify doesn't work&lt;/DIV&gt;&lt;DIV&gt;If I modify placement like so,it works if I use a DATA_SEG pragma to reference EXTRAM&lt;/DIV&gt;&lt;DIV&gt;my 24K array is placed inside the DATA_SEG pargma and an END&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;PLACEMENT&lt;/DIV&gt;&lt;DIV&gt;_PRESTART,STARTUP,ROM_VAR,STRINGS,VIRTUAL_TABLE_SEGMENT,NON_BANKED,&lt;/DIV&gt;&lt;DIV&gt;COPY INTO ROM_C000;&lt;/DIV&gt;&lt;DIV&gt;DEFAULT_ROM INTO PAGE_3C;&lt;/DIV&gt;&lt;DIV&gt;DEFAULT_RAM INTO RAM;&lt;/DIV&gt;&lt;DIV&gt;EXTRAM INTO ERAM;&lt;/DIV&gt;&lt;DIV&gt;END&lt;/DIV&gt;&lt;DIV&gt;I'm sure I'm setting up PEAR,MODE,EBICTL,MISC correctly or the second method&lt;/DIV&gt;&lt;DIV&gt;wouldn't work&lt;/DIV&gt;&lt;DIV&gt;My second solution isn't workable for me.I need the compiler to be able to use internal RAM&lt;/DIV&gt;&lt;DIV&gt;and external SRAM contiguously for variables,arrays etc.&lt;/DIV&gt;&lt;DIV&gt;Help!I am going mad.&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2006 04:58:11 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/External-SRAM-problem-in-CodeWarrior-V4-5-for-hCS12/m-p/128939#M839</guid>
      <dc:creator>eddie</dc:creator>
      <dc:date>2006-09-01T04:58:11Z</dc:date>
    </item>
    <item>
      <title>Re: External SRAM problem in CodeWarrior V4.5 for hCS12</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/External-SRAM-problem-in-CodeWarrior-V4-5-for-hCS12/m-p/128940#M840</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt;Hi eddie,&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Is that still a problem?&lt;/DIV&gt;&lt;DIV&gt;I'm assuming you have no overlaps in your SEGMENT definitions (might be typos).&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Then try the following:&lt;/DIV&gt;&lt;DIV&gt;In the first option (PLACEMENT with DEFAULT_RAM INTO RAM,ERAM&lt;IMG alt=":smileywink:" class="emoticon emoticon-smileywink" id="smileywink" src="http://freescale.i.lithium.com/i/smilies/16x16_smiley-wink.gif" title="Smiley Wink" /&gt; the linker fills RAM first then ERAM;&lt;/DIV&gt;&lt;DIV&gt;To place a variable/constant explicitely in the ERAM space define the variable with the @&amp;lt;address&amp;gt; modifier, e.g. unsigend int myvariable @0x2000 =10;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;If you use DATA_SEG pragma with extra segment for ERAM, then you have to switch the memory segment back to default before defining a variable for the RAM area (#pragma DATA_SEG DEFAULT).&lt;/DIV&gt;&lt;DIV&gt;Alternatively, you define the extra segment for ERAM and immediately switch back to default, then you can use the @"&amp;lt;segment&amp;gt;" modifier to define a var for ERAM like this:&lt;/DIV&gt;&lt;DIV&gt;unsigend int myvariable @"EXTRAM" =10;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 04 Sep 2006 19:56:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/External-SRAM-problem-in-CodeWarrior-V4-5-for-hCS12/m-p/128940#M840</guid>
      <dc:creator>slyfox</dc:creator>
      <dc:date>2006-09-04T19:56:00Z</dc:date>
    </item>
    <item>
      <title>Re: External SRAM problem in CodeWarrior V4.5 for hCS12</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/External-SRAM-problem-in-CodeWarrior-V4-5-for-hCS12/m-p/128941#M841</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;Mr SlyFox&lt;BR /&gt;I appreciate your reply.&lt;BR /&gt;I had a couple of typo's on posting my PRM stuff here.&lt;BR /&gt;RAM is actually at 0x400 to 0x1fff.ERAM is actually at&lt;BR /&gt;0x2000 to 0x7fff.&lt;BR /&gt;Bummer that method 1 doesn't work.The only way that&lt;BR /&gt;I can get my external SRAM to work is by using method 2&lt;BR /&gt;which really limits my application a lot.I wish freescale&lt;BR /&gt;provided a few more code examples of various apps(maybe&lt;BR /&gt;they could check the Zilog website and study it).I would&lt;BR /&gt;definitely like to see a code example where external SRAM is utilized in the banked memory model.On the other&lt;BR /&gt;hand,maybe there are lots of code examples that I haven't&lt;BR /&gt;found.&lt;BR /&gt;Signing off...&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Sep 2006 22:18:55 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/External-SRAM-problem-in-CodeWarrior-V4-5-for-hCS12/m-p/128941#M841</guid>
      <dc:creator>eddie</dc:creator>
      <dc:date>2006-09-08T22:18:55Z</dc:date>
    </item>
  </channel>
</rss>

