<?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: why erase FLASH failed? in Digital Signal Controllers</title>
    <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1389356#M2355</link>
    <description />
    <pubDate>Mon, 20 Dec 2021 07:35:43 GMT</pubDate>
    <dc:creator>cabl</dc:creator>
    <dc:date>2021-12-20T07:35:43Z</dc:date>
    <item>
      <title>why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1342060#M2259</link>
      <description>&lt;P&gt;#define MY_FLASH_LOCATION 0x00007C00 /* Flash memory location the data will be written to */&lt;/P&gt;&lt;P&gt;volatile bool DataWrittenFlg = FALSE;&lt;BR /&gt;LDD_TError Error;&lt;BR /&gt;LDD_FLASH_TOperationStatus OpStatus;&lt;BR /&gt;LDD_TDeviceData *MyFLASH_Ptr;&lt;BR /&gt;//UInt16 DataTest[] = {0,1,2,3,4,5,6,7,8,9};&lt;BR /&gt;//UInt16 *pClbrtData = 0;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;void SaveClbrtData(void)&lt;BR /&gt;{&lt;BR /&gt;static UInt16 Cnt = 0;&lt;BR /&gt;&lt;BR /&gt;MyFLASH_Ptr = FLASH1_Init(NULL); /* Initialization of FLASH1 component */&lt;BR /&gt;Error = FLASH1_Erase(MyFLASH_Ptr, MY_FLASH_LOCATION, 1024); /* Start erase to the flash memory */&lt;BR /&gt;/* Here some other application code can be placed */&lt;BR /&gt;while (!DataWrittenFlg)&lt;BR /&gt;{ /* Wait until the data are written */&lt;BR /&gt;FLASH1_Main(MyFLASH_Ptr); /* Run the main method */&lt;BR /&gt;Cnt++;&lt;BR /&gt;if(Cnt &amp;gt; 300)&lt;BR /&gt;{&lt;BR /&gt;break;&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;Device: MC56F82748&lt;/P&gt;&lt;P&gt;dear NXP expert,&amp;nbsp;&lt;/P&gt;&lt;P&gt;i try to erase a sector&amp;nbsp;.p_FlashData (RWX) : ORIGIN = 0x00007C00, LENGTH = 0x00000400,&lt;/P&gt;&lt;P&gt;i am sure the&amp;nbsp;FTFA_PDD_SetFCCOBCommand and&amp;nbsp;FTFA_PDD_SetFCCOBAddress set as expected, no memory protected,&amp;nbsp;FTFA_FPROTn bits are all 1.But i the memory corresponding no change to 0xFFFF, is there any operation need further?&lt;/P&gt;&lt;P&gt;thanks.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 08:33:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1342060#M2259</guid>
      <dc:creator>terrybogard</dc:creator>
      <dc:date>2021-09-17T08:33:42Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1342078#M2260</link>
      <description>&lt;P&gt;if (DeviceDataPrv-&amp;gt;CurrentOperation != LDD_FLASH_READ) {&lt;BR /&gt;FTFA_PDD_SetFCCOBCommand(FTFA_BASE_PTR, DeviceDataPrv-&amp;gt;CurrentCommand); /* Set the desired flash operation command */&lt;BR /&gt;FTFA_PDD_SetFCCOBAddress(FTFA_BASE_PTR, ((uint32_t)(DeviceDataPrv-&amp;gt;CurrentFlashAddress - DstAddrOffset))); /* Set an address of the flash memory location for the current flash operation command */&lt;BR /&gt;/* {Default RTOS Adapter} Critical section begin, general PE function is used */&lt;BR /&gt;EnterCritical();&lt;BR /&gt;DeviceDataPrv-&amp;gt;SafeRoutineInCodePtr(); /* Run the Safe routine */&lt;BR /&gt;/* {Default RTOS Adapter} Critical section end, general PE function is used */&lt;BR /&gt;ExitCritical();&lt;BR /&gt;}&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 08:45:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1342078#M2260</guid>
      <dc:creator>terrybogard</dc:creator>
      <dc:date>2021-09-17T08:45:34Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1343584#M2262</link>
      <description>&lt;P&gt;Hi, Alexander,&lt;/P&gt;
&lt;P&gt;I suggest you use another flash bean rather than the one you use.&lt;/P&gt;
&lt;P&gt;I attach an simple example to write flash based on MC56F82748 and PE, hope it can help you.&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Wed, 22 Sep 2021 02:37:21 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1343584#M2262</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-09-22T02:37:21Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1343634#M2263</link>
      <description>&lt;P&gt;hi xiangjun,&lt;/P&gt;&lt;P&gt;why you suggest use another flash bean.&lt;/P&gt;&lt;P&gt;I test your code, that's work well.&lt;/P&gt;&lt;P&gt;thanks a lot.&lt;/P&gt;</description>
      <pubDate>Wed, 22 Sep 2021 03:28:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1343634#M2263</guid>
      <dc:creator>terrybogard</dc:creator>
      <dc:date>2021-09-22T03:28:06Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1343892#M2264</link>
      <description>&lt;P&gt;and how can i write the struct type to the destination?&lt;/P&gt;</description>
      <pubDate>Wed, 22 Sep 2021 09:40:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1343892#M2264</guid>
      <dc:creator>terrybogard</dc:creator>
      <dc:date>2021-09-22T09:40:32Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1344563#M2265</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;As you know that a struct includes multiple data type, for example byte, word, long word..., but the flash writing requires standard 16 bits data type(word type), so I think you can define a word array, copy the struct variable to the standard array.&lt;/P&gt;
&lt;P&gt;Hope it can help you&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Thu, 23 Sep 2021 03:09:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1344563#M2265</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-09-23T03:09:53Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1389347#M2354</link>
      <description>&lt;P&gt;Hi evreybody,&lt;/P&gt;&lt;P&gt;I´m using a 56F82646 part and having some trouble with this component. To my understanding there´s something odd in the PE code for the SafeRoutineCaller:&lt;/P&gt;&lt;P&gt;- when stack location where&amp;nbsp;SaveRoutineStackSpace is placed is under 0x7FF (RAM address), SafeRoutineInDataPtr gets a value under 0xFFF (double of SaveRoutineStackSpace address), and&amp;nbsp;SafeRoutineInCodePtr=0xF000 +&amp;nbsp;SafeRoutineInDataPtr is a valid address under 0xFFFF and everything works fine. At least this es what I can see in the debugger.&lt;/P&gt;&lt;P&gt;- when stack&amp;nbsp;location where&amp;nbsp;SaveRoutineStackSpace is placed is over 0x7FF, SafeRoutineInDataPtr gets a value over 0xFFF and&amp;nbsp;SafeRoutineInCodePtr=0xF000 +&amp;nbsp;SafeRoutineInDataPtr is a INVALID address (over 0xFFFF). Now it does not work.&lt;/P&gt;&lt;P&gt;If I force&amp;nbsp;SaveRoutineStackSpace to be global and be placed at low RAM addresses it always work fine, without any other change in the code, just the&amp;nbsp;SaveRoutineStackSpace position.&lt;/P&gt;&lt;P&gt;This behaviour seems to be independent of the memory model and width of the pointer used in the project options.&lt;/P&gt;&lt;P&gt;Am I not understanding something here?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Dec 2021 07:11:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1389347#M2354</guid>
      <dc:creator>cabl</dc:creator>
      <dc:date>2021-12-20T07:11:48Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1389356#M2355</link>
      <description />
      <pubDate>Mon, 20 Dec 2021 07:35:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1389356#M2355</guid>
      <dc:creator>cabl</dc:creator>
      <dc:date>2021-12-20T07:35:43Z</dc:date>
    </item>
    <item>
      <title>Re: why erase FLASH failed?</title>
      <link>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1390962#M2358</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;Pls try to use large data mode and have a try.&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Thu, 23 Dec 2021 01:05:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Digital-Signal-Controllers/why-erase-FLASH-failed/m-p/1390962#M2358</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-12-23T01:05:56Z</dc:date>
    </item>
  </channel>
</rss>

