<?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: Ask a question about UsageFault abnormal interruption</title>
    <link>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1482788#M16153</link>
    <description>&lt;P&gt;&lt;SPAN&gt;The customer has only two boards in the INVSTATE state, which leads to the abnormal interruption of the UsageFault. The other same boards are running normally. Is it a software problem or a hardware problem?&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 30 Jun 2022 13:04:45 GMT</pubDate>
    <dc:creator>caiguanyun</dc:creator>
    <dc:date>2022-06-30T13:04:45Z</dc:date>
    <item>
      <title>Ask a question about UsageFault abnormal interruption</title>
      <link>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1481122#M16109</link>
      <description>&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;Hello everyone, I would like to ask a question about the abnormal interruption of UsageFault. There are two S32K144 boards in the mass-produced products of the customer that are constantly reset (there is a watchdog) (the boards of other products are normal, and it is normal to burn the same set of software to other boards.&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;SPAN class=""&gt;&lt;SPAN class=""&gt;) There is a UsageFault abnormal interrupt, we use Lauterbach to locate the error in the INVSTATE status bit and cause the UsageFault abnormal interrupt.&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;SPAN class=""&gt;&lt;SPAN class=""&gt;What is the reason for the error of the INVSTATE status bit?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;The following is the analysis test situation:&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;We got the HEX file that the customer gave to close the watchdog, and burned it to the abnormal chip for testing.&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;SPAN class=""&gt;&lt;SPAN class=""&gt;Use Lauterbach to read the core register of S32K144, after running at full speed, it is stuck at address 0x478.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_1-1656409658524.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/184873iC6F74EFF419A41E2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_1-1656409658524.png" alt="caiguanyun_1-1656409658524.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Check the kernel register and find the UsageFault interrupt exception, and check the kernel register and find that the Error in the INVSTATE status bit causes the UsageFault interrupt exception.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_2-1656409708250.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/184874i0AA1631EC3D0B7BB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_2-1656409708250.png" alt="caiguanyun_2-1656409708250.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The following figure is the description of the status bit&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_3-1656409742380.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/184875i060E9B8C6DC913A6/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_3-1656409742380.png" alt="caiguanyun_3-1656409742380.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;According to the description in the following figure, it can be seen that when EPSR.T==0, attempting to execute the instruction results in a UsageFault&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_4-1656409764278.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/184876i5B74EDF2E029590E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_4-1656409764278.png" alt="caiguanyun_4-1656409764278.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_5-1656409770914.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/184877iE3523C8E33B20250/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_5-1656409770914.png" alt="caiguanyun_5-1656409770914.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_6-1656409778634.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/184878i5C4CEFDAE0336E77/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_6-1656409778634.png" alt="caiguanyun_6-1656409778634.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2022 09:57:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1481122#M16109</guid>
      <dc:creator>caiguanyun</dc:creator>
      <dc:date>2022-06-28T09:57:12Z</dc:date>
    </item>
    <item>
      <title>Re: Ask a question about UsageFault abnormal interruption</title>
      <link>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1481726#M16129</link>
      <description>&lt;P&gt;Hello &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/194479"&gt;@caiguanyun&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;The instruction &lt;STRONG&gt;b.w 0x478&lt;/STRONG&gt; at 0x478 can be something like while(1){}.&lt;/P&gt;
&lt;P&gt;I don't think this is the root cause here.&lt;/P&gt;
&lt;P&gt;Can you halt the execution in the Hard Fault handler (or Usage Fault handler if enabled) and read the Stack?&lt;/P&gt;
&lt;P&gt;You should find the fault instruction on the stack.&lt;/P&gt;
&lt;P&gt;Please follow this document / sample code:&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;Regards,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Jun 2022 09:29:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1481726#M16129</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-06-29T09:29:40Z</dc:date>
    </item>
    <item>
      <title>Re: Ask a question about UsageFault abnormal interruption</title>
      <link>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1482788#M16153</link>
      <description>&lt;P&gt;&lt;SPAN&gt;The customer has only two boards in the INVSTATE state, which leads to the abnormal interruption of the UsageFault. The other same boards are running normally. Is it a software problem or a hardware problem?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2022 13:04:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1482788#M16153</guid>
      <dc:creator>caiguanyun</dc:creator>
      <dc:date>2022-06-30T13:04:45Z</dc:date>
    </item>
    <item>
      <title>Re: Ask a question about UsageFault abnormal interruption</title>
      <link>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1483287#M16162</link>
      <description>&lt;P&gt;Hello &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/194479"&gt;@caiguanyun&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Hard to say at this moment.&lt;/P&gt;
&lt;P&gt;Please find the the PC address of the fault exception on the stack.&lt;/P&gt;
&lt;P&gt;The code that you showed is probably while(1){} loop in the UsageFault_Handler() and the MCU is waiting for WDOG reset, correct?&lt;/P&gt;
&lt;P&gt;If so, you should be able to open the memory window, locate the Stack and the PC address of the fault instruction on the Stack.&lt;/P&gt;
&lt;P&gt;Then, in Disassembly window, you can find the instruction.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BR, Daniel&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 07:32:28 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1483287#M16162</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2022-07-01T07:32:28Z</dc:date>
    </item>
    <item>
      <title>Re: Ask a question about UsageFault abnormal interruption</title>
      <link>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1483654#M16170</link>
      <description>&lt;P&gt;&lt;SPAN&gt;No, because I don't have the client code, I can't debug it, so I can only ask the client to turn off the watchdog of the program. When the program runs away abnormally, I can use Lauterbach to check the kernel register value.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;The following picture shows the whole process of customer debug debugging and analysis. By viewing the disassembly window, it is found that it is caused by the use of addresses outside the SRAM area.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_0-1656844916273.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/185369i05449FAA957E30E2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_0-1656844916273.png" alt="caiguanyun_0-1656844916273.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_1-1656844932566.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/185370i0C646C1C4A18217B/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_1-1656844932566.png" alt="caiguanyun_1-1656844932566.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_2-1656844943672.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/185371iDED1C5AD5C313D61/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_2-1656844943672.png" alt="caiguanyun_2-1656844943672.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_3-1656844954035.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/185372i75756D9587D997A7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_3-1656844954035.png" alt="caiguanyun_3-1656844954035.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="caiguanyun_4-1656844964191.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/185373i3267410B9E64D1BA/image-size/medium?v=v2&amp;amp;px=400" role="button" title="caiguanyun_4-1656844964191.png" alt="caiguanyun_4-1656844964191.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Also please help to analyze the reason, thank you very much，&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;If you have any questions, please email me,&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;SPAN class=""&gt;&lt;SPAN class=""&gt;Email: caiguanyun@zlgmcu.com&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 03 Jul 2022 10:46:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Ask-a-question-about-UsageFault-abnormal-interruption/m-p/1483654#M16170</guid>
      <dc:creator>caiguanyun</dc:creator>
      <dc:date>2022-07-03T10:46:10Z</dc:date>
    </item>
  </channel>
</rss>

