<?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>S32KのトピックRe: Flah ECC INJECTION</title>
    <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1421290#M14212</link>
    <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;Sorry for dragging this too long and appreciate your patience.&lt;/P&gt;&lt;P&gt;Lets talk about the HARD_FAULT handler and just forget about the BUS_FAULT handler( I'll start a new thread about that)&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;My current code, injects an ECC flash error .It'd&amp;nbsp; sets the DFDIF bit in the&amp;nbsp;FERSTAT register and&amp;nbsp; after a read to the location where the error was injected, would triggers a &lt;STRONG&gt;hard_fault exception&lt;/STRONG&gt;&lt;/SPAN&gt;&amp;nbsp;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My question is :&lt;/P&gt;&lt;P&gt;Is it typical that an ECC FLASH error to trigger HARD_FAULT exception, right after a read to the location responsible for the error ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it possible to recover from a hard_fault exception or not?&lt;/P&gt;&lt;P&gt;I probably need to look at your link more carefully for the answer to 2nd question&lt;/P&gt;&lt;P&gt;BR, Koorosh&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&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&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;?&lt;/P&gt;&lt;P&gt;I need to look at the link you sent more carefully&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 01 Mar 2022 15:22:41 GMT</pubDate>
    <dc:creator>hajianik</dc:creator>
    <dc:date>2022-03-01T15:22:41Z</dc:date>
    <item>
      <title>Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1417592#M14090</link>
      <description>&lt;P&gt;HI,.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The function below writes 8 bytes to a flash location 0X0D2660 (0XAA,0X55,,,) which is 64bit aligned and then it erases it and writes 0x14,0x13,0x12......to the same location&lt;/P&gt;&lt;P&gt;then I read the location 0x0d2660&amp;nbsp; and I observe FTFC_FERSTAT remains 0 ( does not report an error)after the read to the location.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This function&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;flsh_ecc&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;(please see below)&lt;/SPAN&gt;run out of RAM from 0x1FFE0000 which is at top of the ram also&amp;nbsp; the debugger shows me the 1st phrase is written and then erased and rewritten with a new phrase correctly.&lt;/P&gt;&lt;P&gt;then I read the location:&lt;/P&gt;&lt;P&gt;myvar = *((unsigned long long*)0xd2660);&lt;/P&gt;&lt;P&gt;the only thing which is notable is :the code triggers a BUS FAULT exception and won't run anymore.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;void flsh_ecc(void)&lt;BR /&gt;{&lt;BR /&gt;//while((FTFC-&amp;gt;FSTAT &amp;amp; FTFC_FSTAT_CCIF_MASK) != FTFC_FSTAT_CCIF_MASK); /* Wait until any ongoing flash operation is completed */&lt;BR /&gt;#pragma asm&lt;BR /&gt;;ldr r1, =0x40020000 (0x1fff027c &amp;lt;run_ocs_volt_once..C.3A.5CFramework_ZERV_v00.2E02.5CApplications.5CZERV_Framework.5CAppl.5Cobj.5CINF_CDD.&amp;gt;)&lt;BR /&gt;movw r1,0x0000&lt;BR /&gt;movt r1,0x4002&lt;BR /&gt;movs r0, #128 ; 0x80&lt;BR /&gt;strb r0, [r1, #0]&lt;BR /&gt;L1:&lt;BR /&gt;ldrb r0, [r1, #0]&lt;BR /&gt;lsls r0, r0, #24&lt;BR /&gt;bpl L1&lt;BR /&gt;#pragma endasm&lt;BR /&gt;//FTFC-&amp;gt;FSTAT = FTFC_FSTAT_ACCERR_MASK | FTFC_FSTAT_FPVIOL_MASK;&lt;BR /&gt;&lt;BR /&gt;FTFC-&amp;gt;FCCOB[3] = 0x07;//a_cmd; //Program Phrase command (0x07)&lt;BR /&gt;FTFC-&amp;gt;FCCOB[2] = 0x0d;//v_AddrVec[0]; //Flash address [23:16]&lt;BR /&gt;FTFC-&amp;gt;FCCOB[1] =0x26; //v_AddrVec[1]; //Flash address [15:08]&lt;BR /&gt;FTFC-&amp;gt;FCCOB[0] =0x60; //v_AddrVec[2]; //Flash address [7:0]&lt;BR /&gt;&lt;BR /&gt;// if (a_pageBuffer != NULL) {&lt;BR /&gt;FTFC-&amp;gt;FCCOB[7] =0x55; //a_pageBuffer[0]; //data&lt;BR /&gt;FTFC-&amp;gt;FCCOB[6] = 0xaa;//a_pageBuffer[1];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[5] = 0x55;//a_pageBuffer[2];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[4] =0xaa; //a_pageBuffer[3];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[11] =0x55; //a_pageBuffer[4];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[10] =0xaa; //a_pageBuffer[5];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[9] =0x55; //a_pageBuffer[6];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[8] =0xaa; //a_pageBuffer[7];&lt;BR /&gt;// }&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;FTFC-&amp;gt;FSTAT = FTFC_FSTAT_CCIF_MASK; //launch command&lt;BR /&gt;//while((FTFC-&amp;gt;FSTAT &amp;amp; FTFC_FSTAT_CCIF_MASK) != FTFC_FSTAT_CCIF_MASK);&lt;BR /&gt;#pragma asm&lt;BR /&gt;;ldr r1, =0x40020000 (0x1fff027c &amp;lt;run_ocs_volt_once..C.3A.5CFramework_ZERV_v00.2E02.5CApplications.5CZERV_Framework.5CAppl.5Cobj.5CINF_CDD.&amp;gt;)&lt;BR /&gt;movw r1,0x0000&lt;BR /&gt;movt r1,0x4002&lt;BR /&gt;movs r0, #128 ; 0x80&lt;BR /&gt;strb r0, [r1, #0]&lt;BR /&gt;L2:&lt;BR /&gt;ldrb r0, [r1, #0]&lt;BR /&gt;lsls r0, r0, #24&lt;BR /&gt;bpl L2&lt;BR /&gt;#pragma endasm&lt;BR /&gt;&lt;BR /&gt;FTFC-&amp;gt;FCCOB[3] = 0x09;//a_cmd; //Program Phrase command (0x07)&lt;BR /&gt;FTFC-&amp;gt;FCCOB[2] = 0x0d;//v_AddrVec[0]; //Flash address [23:16]&lt;BR /&gt;FTFC-&amp;gt;FCCOB[1] =0x26; //v_AddrVec[1]; //Flash address [15:08]&lt;BR /&gt;FTFC-&amp;gt;FCCOB[0] =0x60; //v_AddrVec[2]; //Flash address [7:0]&lt;BR /&gt;FTFC-&amp;gt;FSTAT = FTFC_FSTAT_CCIF_MASK; //launch command&lt;BR /&gt;#pragma asm&lt;BR /&gt;;ldr r1, =0x40020000 (0x1fff027c &amp;lt;run_ocs_volt_once..C.3A.5CFramework_ZERV_v00.2E02.5CApplications.5CZERV_Framework.5CAppl.5Cobj.5CINF_CDD.&amp;gt;)&lt;BR /&gt;movw r1,0x0000&lt;BR /&gt;movt r1,0x4002&lt;BR /&gt;movs r0, #128 ; 0x80&lt;BR /&gt;strb r0, [r1, #0]&lt;BR /&gt;L3:&lt;BR /&gt;ldrb r0, [r1, #0]&lt;BR /&gt;lsls r0, r0, #24&lt;BR /&gt;bpl L3&lt;BR /&gt;#pragma endasm&lt;BR /&gt;FTFC-&amp;gt;FCCOB[3] = 0x07;//a_cmd; //Program Phrase command (0x07)&lt;BR /&gt;FTFC-&amp;gt;FCCOB[2] = 0x0d;//v_AddrVec[0]; //Flash address [23:16]&lt;BR /&gt;FTFC-&amp;gt;FCCOB[1] =0x26; //v_AddrVec[1]; //Flash address [15:08]&lt;BR /&gt;FTFC-&amp;gt;FCCOB[0] =0x60; //v_AddrVec[2]; //Flash address [7:0]&lt;BR /&gt;&lt;BR /&gt;// if (a_pageBuffer != NULL) {&lt;BR /&gt;FTFC-&amp;gt;FCCOB[7] =0x10; //a_pageBuffer[0]; //data&lt;BR /&gt;FTFC-&amp;gt;FCCOB[6] = 0x12;//a_pageBuffer[1];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[5] = 0x13;//a_pageBuffer[2];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[4] =0x14; //a_pageBuffer[3];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[11] =0x15; //a_pageBuffer[4];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[10] =0x16; //a_pageBuffer[5];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[9] =0x17; //a_pageBuffer[6];&lt;BR /&gt;FTFC-&amp;gt;FCCOB[8] =0x18; //a_pageBuffer[7];&lt;BR /&gt;//INT_SYS_EnableIRQGlobal();&lt;BR /&gt;FTFC-&amp;gt;FSTAT = FTFC_FSTAT_CCIF_MASK; //launch command&lt;BR /&gt;#pragma asm&lt;BR /&gt;;ldr r1, =0x40020000 (0x1fff027c &amp;lt;run_ocs_volt_once..C.3A.5CFramework_ZERV_v00.2E02.5CApplications.5CZERV_Framework.5CAppl.5Cobj.5CINF_CDD.&amp;gt;)&lt;BR /&gt;movw r1,0x0000&lt;BR /&gt;movt r1,0x4002&lt;BR /&gt;movs r0, #128 ; 0x80&lt;BR /&gt;strb r0, [r1, #0]&lt;BR /&gt;L4:&lt;BR /&gt;ldrb r0, [r1, #0]&lt;BR /&gt;lsls r0, r0, #24&lt;BR /&gt;bpl L4&lt;BR /&gt;#pragma endasm&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;Just wondering beside the register FTFC-FEPRT, is it some else to check.&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Koorosh Hajiani&lt;/P&gt;</description>
      <pubDate>Tue, 22 Feb 2022 15:50:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1417592#M14090</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-02-22T15:50:53Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419181#M14145</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/138997"&gt;@hajianik&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Please correct me if I'm wrong, but you erase the sector between the Program Phrase commands.&lt;/P&gt;
&lt;P&gt;So, why do you expect an ECC error there?&lt;/P&gt;
&lt;P&gt;You would get an ECC error if the phrase was not erased.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 15:11:55 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419181#M14145</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-02-24T15:11:55Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419343#M14152</link>
      <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;you're correct, don't know what I was thinking!!&lt;/P&gt;&lt;P&gt;now I write a phrase&amp;nbsp; and then wit out the erase I write a different phrase to same location ,I read the location&lt;/P&gt;&lt;P&gt;At that point the&amp;nbsp; DFDIF bit in FTFC-FERSTAT&amp;nbsp; reports an error.&lt;/P&gt;&lt;P&gt;however the code hits an exception not like the BUS FAULT exception and seems never to recover.&lt;/P&gt;&lt;P&gt;I don't mean it to be a long thread but this brings out 2 questions:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Is the FLASH ECC double bit error is recoverable?&lt;/LI&gt;&lt;LI&gt;WHY IN THE FIRST INSTANCE THAT i DID&amp;nbsp; THE SEQUENCEWRITE-ERASE-WRITE, IT'LL TRIGGER ABUS FAULT ECEPTIN?&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Koorosh Hajiani&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 20:38:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419343#M14152</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-02-24T20:38:41Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419388#M14153</link>
      <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;just to be precise, I wrote in my last post:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;however the code hits an exception not like the BUS FAULT exception and seems never to recover.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;The version when I set the double_bit on&amp;nbsp;in ftfc_ferstat, I found out the exception it triggers is a HARD_FAULT.&lt;/P&gt;&lt;P&gt;WHEN I WAS DOING&amp;nbsp; WRITE_ERASE_WRITE SEQUENCE, IT NEVER SET THE FAULT AND YET TRIGGERS BUS_FAULT EXCEPTION&lt;/P&gt;&lt;P&gt;WHEN DOING WRITE-WRITE SEQUENCE , IT SETS THE FLAG AND TRIGGERS HARD_FAULT.&lt;/P&gt;&lt;P&gt;The question is why do these exceptions are triggered and recoverable?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Koorosh&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Feb 2022 23:24:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419388#M14153</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-02-24T23:24:03Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419882#M14177</link>
      <description>&lt;P&gt;Hi Koorosh,&lt;/P&gt;
&lt;P&gt;I would need to have more information about the "not like the BUS FAULT exception".&lt;/P&gt;
&lt;P&gt;Can you please try to debug it following the steps here:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.nxp.com/t5/S32K-Knowledge-Base/Fault-handling-on-S32K14x/ta-p/1114447" target="_blank"&gt;https://community.nxp.com/t5/S32K-Knowledge-Base/Fault-handling-on-S32K14x/ta-p/1114447&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BR, Daniel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Feb 2022 15:25:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419882#M14177</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-02-25T15:25:27Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419928#M14181</link>
      <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;I'll go to the link you posted.&lt;/P&gt;&lt;P&gt;I think my English is the issue.&lt;/P&gt;&lt;P&gt;when I mentioned&amp;nbsp; "NO BUS FAULT " exception I'm referring to the code which, wrote a phrase then erase the phrase and finally writes a different phrase and you corrected me by saying you shouldn't erase in between&amp;nbsp; phrases writes. This code hits the bus_fault exception and set no error in the&amp;nbsp;FERSTAT register.&lt;/P&gt;&lt;P&gt;When I did the phrase write and write a different phrase (same location of course) code, this code sets the fault DFDIF in the&amp;nbsp;FERSTAT register and then triggers a hard_fault exception and not a bus_fault exception.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now why would&amp;nbsp; I trigger&amp;nbsp; a bus _fault exception in the first instance of the code?&lt;/P&gt;&lt;P&gt;and why I trigger a hard_fault exception in the second instance of the code(when it sets the error flg)?&lt;/P&gt;&lt;P&gt;and is it possible to recover from&amp;nbsp; ecc error on flash?&lt;/P&gt;&lt;P&gt;I hope this would more clear.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Koorosh&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Feb 2022 18:17:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1419928#M14181</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-02-25T18:17:32Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1421230#M14210</link>
      <description>&lt;P&gt;Hi Koorosh,&lt;/P&gt;
&lt;P&gt;This is still very confusing to me.&lt;/P&gt;
&lt;P&gt;I understand that you have two handler in the project (HardFault and BusFault) and the BusFault is enabled. Then, any bus fault should be handled by the BusFault handler only with the exception of faults detected within the BusFault handler or exception vector featching.&lt;/P&gt;
&lt;P&gt;Anyway, what bus fault is it? Imprecise or Precise? Is BFAR valid? If so, what is the address there.&lt;/P&gt;
&lt;P&gt;If not, please disable the write buffer as suggested in the document I was referering to in my last response.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2022 12:50:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1421230#M14210</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-03-01T12:50:26Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1421290#M14212</link>
      <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;Sorry for dragging this too long and appreciate your patience.&lt;/P&gt;&lt;P&gt;Lets talk about the HARD_FAULT handler and just forget about the BUS_FAULT handler( I'll start a new thread about that)&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;My current code, injects an ECC flash error .It'd&amp;nbsp; sets the DFDIF bit in the&amp;nbsp;FERSTAT register and&amp;nbsp; after a read to the location where the error was injected, would triggers a &lt;STRONG&gt;hard_fault exception&lt;/STRONG&gt;&lt;/SPAN&gt;&amp;nbsp;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My question is :&lt;/P&gt;&lt;P&gt;Is it typical that an ECC FLASH error to trigger HARD_FAULT exception, right after a read to the location responsible for the error ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it possible to recover from a hard_fault exception or not?&lt;/P&gt;&lt;P&gt;I probably need to look at your link more carefully for the answer to 2nd question&lt;/P&gt;&lt;P&gt;BR, Koorosh&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt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lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;?&lt;/P&gt;&lt;P&gt;I need to look at the link you sent more carefully&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Mar 2022 15:22:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1421290#M14212</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-03-01T15:22:41Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1421947#M14233</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/138997"&gt;@hajianik&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I just tested it on S32K144 EVB.&lt;/P&gt;
&lt;P&gt;It is a precise bus fault.&lt;/P&gt;
&lt;P&gt;It feaches the BusFault_Hnadler provided it is enabled (in SHCSR).&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_0-1646231713778.png" style="width: 752px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/172290i50CF7A21724A9CD6/image-dimensions/752x313?v=v2" width="752" height="313" role="button" title="danielmartynek_0-1646231713778.png" alt="danielmartynek_0-1646231713778.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Regarding a possible recovery solution, it would need to be reporgrammed or the application would need to overwrite the context on the stack.&lt;/P&gt;
&lt;P&gt;There is an example in AN12522 on page 8.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.nxp.com/docs/en/application-note/AN12522.pdf" target="_blank"&gt;https://www.nxp.com/docs/en/application-note/AN12201.pdfhttps://www.nxp.com/docs/en/application-note/AN12522.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Mar 2022 14:40:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1421947#M14233</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-03-02T14:40:27Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1422221#M14237</link>
      <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;Thanks so much for helping me on this.&lt;/P&gt;&lt;P&gt;I get identical reporting on the registers that you posted in your last reply.&lt;/P&gt;&lt;P&gt;However when I do the following I get HARD_ FAULT_ exception&amp;nbsp; rather than a BUS_FAULT_ exception.&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&amp;nbsp;&lt;STRONG&gt;writing a program phrase to a location in flash(64bit&amp;nbsp;&lt;/STRONG&gt;&lt;STRONG&gt;aligned)&lt;/STRONG&gt;&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;without erasing the sector, I write a different program phrase to the same location.&lt;/STRONG&gt;&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;when I read the location ,it&amp;nbsp; will&amp;nbsp; set the double fault bit&amp;nbsp; in FTFC_FERSTAT and generates a hard_fault exception even when bus_fault is enabled in SCB_SHCSR register !!!!!&lt;/STRONG&gt;&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;SCB_CFSR REPORTS THE SAME VALUE AS YOU POSTED IN YOUR LATEST REPLY!!!!&lt;/STRONG&gt;&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;I do enable the DFDIE in FTFC-FERCNFG register but it never&amp;nbsp;triggers because of the HARD_FAULT EXCEPTION&amp;nbsp;triggers.&lt;/STRONG&gt;&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;When inside the hard_fault exception I have a valid stack( R13 and r13_MSR are pointing to the main stack and are identical however R14 points to 0xfffffff9 which is la la land.&lt;/STRONG&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;At this point I'm confused&amp;nbsp;why the hard_fault exception triggers&amp;nbsp;rather than the bus_fault when it is enabled?&lt;/P&gt;&lt;P&gt;I understand that all disabled exception will elevate to hard_fault which is enabled by default.&lt;/P&gt;&lt;P&gt;I read the application note you sent , there is no page 8 on that, it has only 5 pages. I believe you sent me a link on how to recover from an exception in an earlier post.&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Koorosh&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Mar 2022 20:46:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1422221#M14237</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-03-02T20:46:40Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1423406#M14263</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I took an S32K example project and modified the code to demonstrate the points made in my last post.&lt;/P&gt;&lt;P&gt;Please see the attachment.&lt;/P&gt;&lt;P&gt;The name of the project is misleading (&lt;STRONG&gt;ADC_s32k144&lt;/STRONG&gt;) as this one has nothing todo with the ADC.&lt;/P&gt;&lt;P&gt;This code set the BUS_FAULT enabled , it sets the DFDIE (Interrupt enable bit) In FERCNFG register.&lt;/P&gt;&lt;P&gt;I run this on s32k148 eval board ,It will set DFDIF in FERSTAT register and When the location(where the fault was injected) is read , it keeps triggering HARD_FAULT exception handler and since LINK REGISTER is -7(0xfffffff9) it is stuck in the handler.&lt;/P&gt;&lt;P&gt;This is contrary to the statement in AN12522:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;3.2 ECC for non-correctable errors&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;The S32K14x and S32K11x devices handle the non-correctable error in the same way. The Flash Memory Module ( FTFC ) can&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;generate an interrupt (if enabled) to notify a multiple -bit error event which can be enabled setting the FERCNFG[DFDIE] bit to 1.&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;• S32K1xx Error Handling: When the fault occurs, the FERSTAT[DFDIF] flag is set notifying that a double bit fault was&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;detected. The flash controller will generate a AHB error response resulting in a bus fault (if enabled). After serving the bus&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;fault, jump to the Flash Memory Module ( FTFC ) interrupt handler (if enabled). The software can handle the error depending&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;on whether the error occurred in Code Space or Data Space.&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;• If an uncorrectable error fault occurs during execution of a machine exception, a safe state shall be entered.&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;• The bus fault is disabled by default. Therefore, it will be getting escalated to hard fault.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;So either I'm doing something wrong and( please correct me) or the AN12522 is wrong and that needs to be corrected too.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Koorosh&lt;/P&gt;</description>
      <pubDate>Fri, 04 Mar 2022 17:36:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1423406#M14263</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-03-04T17:36:29Z</dc:date>
    </item>
    <item>
      <title>Re: Flah ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1423875#M14282</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/138997"&gt;@hajianik&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I'm sorry, I meant AN12201, p8&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.nxp.com/docs/en/application-note/AN12201.pdf" target="_blank"&gt;https://www.nxp.com/docs/en/application-note/AN12201.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have just brieflly gone through the example you posted.&lt;/P&gt;
&lt;P&gt;You enable the FTFC fault interrupt in the FTFC controller and in NVIC but you did not implement the handler in the project.&lt;/P&gt;
&lt;LI-CODE lang="c"&gt;void FTFC_Fault_IRQHandler(void){}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You have FTF&lt;STRONG&gt;E&lt;/STRONG&gt; handler though.&lt;/P&gt;
&lt;LI-CODE lang="c"&gt;void FTFE_Fault_IRQHandler(void){}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This would explain the HardFault there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BR, Daniel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Mar 2022 10:48:43 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1423875#M14282</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-03-07T10:48:43Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1435003#M14647</link>
      <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;sorry for a late response. I was on vacation.&lt;/P&gt;&lt;P&gt;you are correct, I had a typo, however when I changed it to&amp;nbsp;&amp;nbsp;&lt;STRONG&gt;void FTFC_Fault_IRQHandler(void) &lt;/STRONG&gt;I still hit a hard_fault handler. This happens when I read the memory at fault.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Koorosh Hajiani&lt;/P&gt;</description>
      <pubDate>Mon, 28 Mar 2022 20:13:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1435003#M14647</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-03-28T20:13:13Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1436026#M14683</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/138997"&gt;@hajianik&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I don't have the board today.&lt;/P&gt;
&lt;P&gt;Can you please debug this fault again:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.nxp.com/t5/S32K-Knowledge-Base/Fault-handling-on-S32K14x/ta-p/1114447" target="_blank" rel="noopener"&gt;https://community.nxp.com/t5/S32K-Knowledge-Base/Fault-handling-on-S32K14x/ta-p/1114447&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;What is the content of the CFSR / BFAR registers?&lt;/P&gt;
&lt;P&gt;Can you find the instruction that triggers the fault?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;BR, Daniel&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 08:59:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1436026#M14683</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-03-30T08:59:13Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1436500#M14698</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Below is a snapshot of the registers.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="hajianik_0-1648670518249.png" style="width: 790px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/175338iAD24370EE9E6BAF1/image-dimensions/790x390?v=v2" width="790" height="390" role="button" title="hajianik_0-1648670518249.png" alt="hajianik_0-1648670518249.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;also the instruction that'll trigger Hardfault_handler&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="hajianik_1-1648670757500.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/175339iB88E01C3903379AD/image-size/medium?v=v2&amp;amp;px=400" role="button" title="hajianik_1-1648670757500.png" alt="hajianik_1-1648670757500.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Koorosh&lt;/P&gt;&lt;P&gt;That's when I try to read the address at fault(0xD2680 that's what BFAR is showing.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 20:12:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1436500#M14698</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-03-30T20:12:47Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1437761#M14733</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/138997"&gt;@hajianik&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;There is an obvious error, the address that you are writing to is no implemented on S32K144.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_0-1648828167285.png" style="width: 731px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/175663i197048C9FE8D637C/image-dimensions/731x191?v=v2" width="731" height="191" role="button" title="danielmartynek_0-1648828167285.png" alt="danielmartynek_0-1648828167285.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;But even with this being fixed, it does not workm and I can't find out why.&lt;/P&gt;
&lt;P&gt;Anyway, the test project attached works as expected.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regadrs,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 01 Apr 2022 15:51:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1437761#M14733</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-04-01T15:51:22Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1438467#M14766</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;So my target is S32K148. the address 0XD2680 is implemented on this version.&lt;/P&gt;&lt;P&gt;I can not find any error in my code as you looked at it AND COME TO THE SAME CONCLUSIN.&lt;/P&gt;&lt;P&gt;Will I be correct in response to the customer(GM) inquires to say:&lt;/P&gt;&lt;P&gt;NXP STATEMENT (REGARDING FLASH ECC ERROR)IN THEIR APPLICATION NOTE AND LITRITURE IS AT BEST MISLEADING.. IN FACT THIS ERROR TRIGGERS A HARD_FAULT EXCEPTION AND THERE IS NO RECOVERY FROM THAT.&lt;/P&gt;&lt;P&gt;Please correct me if I'm wrong.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 04 Apr 2022 16:13:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1438467#M14766</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-04-04T16:13:10Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1438923#M14790</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/138997"&gt;@hajianik&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;You posted an example ported on S32K144.&lt;/P&gt;
&lt;P&gt;I tested that example on an S32K144 EVB.&lt;/P&gt;
&lt;P&gt;The example that I posted works on that EVB, it goes to BusFault_Handler as expected.&lt;/P&gt;
&lt;P&gt;Can you test it?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;BR, Daniel&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2022 13:51:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1438923#M14790</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-04-05T13:51:03Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1439120#M14794</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Your example works fine on my s32k148 eval board. It triggers the&amp;nbsp;FTFC_Fault_IRQHandler&amp;nbsp; AND THEN TRIGGERS A BUS_FAULT handler.&lt;/P&gt;&lt;P&gt;I almost made my code identical to yours in spite of the fact I couldn't find any differences in the first place.&lt;/P&gt;&lt;P&gt;It is now identical to yours except the data for the&amp;nbsp;Program Phrase command . same address like yours 0x00070000 and yet when I run my code it still hit the HARD_FAULT_HANDLER.&lt;/P&gt;&lt;P&gt;THIS IS A REAL MYSTRY TO ME EVEN&amp;nbsp; the "err"&amp;nbsp; in err=flsh_ecc(); is the same as yours which is 4.&lt;/P&gt;&lt;P&gt;Don't know what the deal is. it is exactly except for the program phrase data.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;KOOROSH&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2022 20:02:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1439120#M14794</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-04-05T20:02:22Z</dc:date>
    </item>
    <item>
      <title>Re: Flash ECC INJECTION</title>
      <link>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1439149#M14796</link>
      <description>&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;Sorry for posting again. I noticed in my code I did not enable the BUS_FAULT exception, used the wrong mask 0x2000 which ought've been 0x20000.when I corrected that, I keep hitting the bus fault and no FTFC_Fault_IRQHandler is triggered. it was hitting the HARD_FAULT handler since all the unable are escalated to the hard_fault.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2022 20:52:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Flah-ECC-INJECTION/m-p/1439149#M14796</guid>
      <dc:creator>hajianik</dc:creator>
      <dc:date>2022-04-05T20:52:18Z</dc:date>
    </item>
  </channel>
</rss>

