<?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>Classic/Legacy CodeWarrior中的主题 Re: Re: Issue with the SetPage method in Codewarrior 5.9 targeting HCS08</title>
    <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442095#M6941</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for the assistance. This has been extremely helpful. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 28 Apr 2015 12:59:56 GMT</pubDate>
    <dc:creator>mrcdsmith</dc:creator>
    <dc:date>2015-04-28T12:59:56Z</dc:date>
    <item>
      <title>Issue with the SetPage method in Codewarrior 5.9 targeting HCS08</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442091#M6937</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This question is in regards to CodeWarrior IDE version 5.9.0 targeting processor family HCS08. I am having an issue writing to flash using the methods provided through CodeWarrior. I am reading from and writing to a buffer using the GetBytePage, GetWordPage, SetBytePage, and SetWordPage methods. This buffer is in turn being read from and written to flash using the SetPage and GetPage methods. The problem occurs when I attempt to use the SetPage method: whenever the program attempts to write the buffer to flash, the results are erratic. Sometimes my registers are corrupted, sometimes my microcontroller locks up until the watchdog timer expires. If I comment out the SetPage method, my code functions as expected. Does anyone have a suggestion as to what the problem(s) may be?&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Below is the section of code I am using to read from and write to flash. &lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; const word Buffer_Address = 0xDD00;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Reading from flash&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_DataPtr2Addr(Buffer_Address);&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetPage(Buffer_Address);&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetWordPage(1, &amp;amp;Word1);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetWordPage(3, &amp;amp;Word2);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetWordPage(5, &amp;amp;Word3);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetWordPage(7, &amp;amp;Word4);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetBytePage(9, &amp;amp;Byte1);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetBytePage(10, &amp;amp;Byte2);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_GetBytePage(11, &amp;amp;Byte3);&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Writing to flash&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Flash_DataPtr2Addr(Buffer_Address);&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class="j-rte-table"&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetWordPage(1, Word1);&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetWordPage(3, Word2);&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetWordPage(5, Word3);&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetWordPage(7, Word4);&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetBytePage(9, Byte1);&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetBytePage(10, Byte2);&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetBytePage(11, Byte3);&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;DIV class="j-rte-table"&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_EraseSector(Buffer_Address);&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;DIV class="j-rte-table"&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&amp;nbsp; Flash_SetPage(Buffer_Address);&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style=""&gt; &lt;/TD&gt;&lt;TD style=""&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Apr 2015 13:29:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442091#M6937</guid>
      <dc:creator>mrcdsmith</dc:creator>
      <dc:date>2015-04-24T13:29:47Z</dc:date>
    </item>
    <item>
      <title>Re: Issue with the SetPage method in Codewarrior 5.9 targeting HCS08</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442092#M6938</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Smith,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;what chip do you work with?&lt;/P&gt;&lt;P&gt;can you please upload your demo project so that we can check it directly ? thanks!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Zhang Jun&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Apr 2015 09:19:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442092#M6938</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2015-04-27T09:19:29Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Issue with the SetPage method in Codewarrior 5.9 targeting HCS08</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442093#M6939</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am using Freescale CPU part # MC9S08SH16CTL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can upload a snippet of the code I am working on. This is the section that deals directly with the flash read/write. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Apr 2015 12:19:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442093#M6939</guid>
      <dc:creator>mrcdsmith</dc:creator>
      <dc:date>2015-04-27T12:19:19Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Issue with the SetPage method in Codewarrior 5.9 targeting HCS08</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442094#M6940</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Smith,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the page related methods are only available for the chips that have paged memory. for example 9S08QE128.&lt;/P&gt;&lt;P&gt;for MC9S08SH16, it hasn't page memory. so it doesn't support&amp;nbsp; GetBytePage, GetWordPage, SetBytePage, and SetWordPage methods.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for more information, I suggest you look:&lt;/P&gt;&lt;P&gt;{CW6.3 install}\ProcessorExpert\Projects\Test projects\IntFlash&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can this help you?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Zhang Jun&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Apr 2015 03:07:58 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442094#M6940</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2015-04-28T03:07:58Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Issue with the SetPage method in Codewarrior 5.9 targeting HCS08</title>
      <link>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442095#M6941</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for the assistance. This has been extremely helpful. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Apr 2015 12:59:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Classic-Legacy-CodeWarrior/Issue-with-the-SetPage-method-in-Codewarrior-5-9-targeting-HCS08/m-p/442095#M6941</guid>
      <dc:creator>mrcdsmith</dc:creator>
      <dc:date>2015-04-28T12:59:56Z</dc:date>
    </item>
  </channel>
</rss>

