<?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 LPC1115 hangs up after soft reset in Processor Expert Software</title>
    <link>https://community.nxp.com/t5/Processor-Expert-Software/LPC1115-hangs-up-after-soft-reset/m-p/768153#M4142</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 0px 0px 2em;"&gt;We have a device which&amp;nbsp;is used with NXP1115/303 MCU(cortex M0 core). Application doesn't do much, most of the time it sleeps in the deep power mode since the device&amp;nbsp; is on 3V lithium batery. The system do a soft reset every 30sec. Reset is implemented&amp;nbsp;via Reset Control Register by setting&amp;nbsp;SYSRESETREQ attribute(NVIC_SystemReset function):&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px; padding-left: 30px;"&gt;&lt;CODE style="color: #444444;"&gt;__STATIC_INLINE void NVIC_SystemReset(void)&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;{&lt;/CODE&gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; __disable_irq();&lt;CODE style="color: #444444;"&gt;&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;__DSB();&amp;nbsp;&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;SCB-&amp;gt;AIRCR = ((0x5FAUL &amp;lt;&amp;lt; SCB_AIRCR_VECTKEY_Pos) |&amp;nbsp;&lt;/CODE&gt;&lt;CODE style="color: #444444;"&gt;SCB_AIRCR_SYSRESETREQ_Msk);&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;__DSB();&amp;nbsp;&lt;/CODE&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px; padding-left: 30px;"&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;for(;;) /* wait until reset */&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;{&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;__NOP();&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;}&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;}&lt;/CODE&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;&lt;CODE style="color: #444444;"&gt;The Reset Handler looks like this:&lt;/CODE&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px; padding-left: 30px;"&gt;&lt;CODE style="color: #444444;"&gt;Reset_Handler PROC&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; EXPORT Reset_Handler [WEAK]&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; IMPORT __main&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; LDR R0, =__main&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; BX R0&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ENDP&lt;/CODE&gt;&lt;SPAN style="font-weight: bold;"&gt;&lt;STRONG&gt;&lt;CODE style="color: #444444;"&gt;&lt;/CODE&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;SystemInit is at the beggining of the main function.&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;&lt;BR /&gt;The issue is that MCU sometimes hangs up after the reset procedure. But it's not every time. It hangs up quite randomly, approx. 1 out of 100k(or even more) resets. It's clear that it doesn't hang up in the SystemInit or in the main. It's not really clear what is happening with the MCU at the hang up state, but it looks like it is in lock up state.&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;&lt;SPAN&gt;Some known information:&lt;/SPAN&gt;&lt;/P&gt;&lt;UL style="color: #565b5b; background-color: #ffffff; margin: 1em 0px; padding: 0px 0px 0px 2em;"&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;&lt;SPAN&gt;When MCU is hanged up, it can be reseted by full power up or&amp;nbsp;with RESET pin;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;&lt;SPAN&gt;The current consumption is 3,4 mA, wich ussual is for a device when only MCU is working (peripheral is sleeping or turned off);&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;As it can be seen from the code snippet above, before the NVIC reset interrupts are disabled;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;MCU doesn't hang up in the main, it's prior that or during the RESET procedure;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;The external crystal is not used;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;Possibility to occur this case is aprrox. 1 out of &amp;gt;100k resets.&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;The MCU uses IRC (12 MHz).&lt;/LI&gt;&lt;/UL&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;Is there any suggestions which can be tried? Any ideas is welcome!&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;UPDATED: even when reset is made by WDT (feeding the wrong sequence) the same situation occurs.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 22 Feb 2018 14:45:27 GMT</pubDate>
    <dc:creator>mantasdi</dc:creator>
    <dc:date>2018-02-22T14:45:27Z</dc:date>
    <item>
      <title>LPC1115 hangs up after soft reset</title>
      <link>https://community.nxp.com/t5/Processor-Expert-Software/LPC1115-hangs-up-after-soft-reset/m-p/768153#M4142</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 0px 0px 2em;"&gt;We have a device which&amp;nbsp;is used with NXP1115/303 MCU(cortex M0 core). Application doesn't do much, most of the time it sleeps in the deep power mode since the device&amp;nbsp; is on 3V lithium batery. The system do a soft reset every 30sec. Reset is implemented&amp;nbsp;via Reset Control Register by setting&amp;nbsp;SYSRESETREQ attribute(NVIC_SystemReset function):&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px; padding-left: 30px;"&gt;&lt;CODE style="color: #444444;"&gt;__STATIC_INLINE void NVIC_SystemReset(void)&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;{&lt;/CODE&gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; __disable_irq();&lt;CODE style="color: #444444;"&gt;&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;__DSB();&amp;nbsp;&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;SCB-&amp;gt;AIRCR = ((0x5FAUL &amp;lt;&amp;lt; SCB_AIRCR_VECTKEY_Pos) |&amp;nbsp;&lt;/CODE&gt;&lt;CODE style="color: #444444;"&gt;SCB_AIRCR_SYSRESETREQ_Msk);&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;__DSB();&amp;nbsp;&lt;/CODE&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px; padding-left: 30px;"&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;for(;;) /* wait until reset */&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;{&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;__NOP();&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp;}&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;}&lt;/CODE&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;&lt;CODE style="color: #444444;"&gt;The Reset Handler looks like this:&lt;/CODE&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px; padding-left: 30px;"&gt;&lt;CODE style="color: #444444;"&gt;Reset_Handler PROC&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; EXPORT Reset_Handler [WEAK]&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; IMPORT __main&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; LDR R0, =__main&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; BX R0&lt;/CODE&gt;&lt;BR /&gt;&lt;CODE style="color: #444444;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ENDP&lt;/CODE&gt;&lt;SPAN style="font-weight: bold;"&gt;&lt;STRONG&gt;&lt;CODE style="color: #444444;"&gt;&lt;/CODE&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;SystemInit is at the beggining of the main function.&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;&lt;BR /&gt;The issue is that MCU sometimes hangs up after the reset procedure. But it's not every time. It hangs up quite randomly, approx. 1 out of 100k(or even more) resets. It's clear that it doesn't hang up in the SystemInit or in the main. It's not really clear what is happening with the MCU at the hang up state, but it looks like it is in lock up state.&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;&lt;SPAN&gt;Some known information:&lt;/SPAN&gt;&lt;/P&gt;&lt;UL style="color: #565b5b; background-color: #ffffff; margin: 1em 0px; padding: 0px 0px 0px 2em;"&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;&lt;SPAN&gt;When MCU is hanged up, it can be reseted by full power up or&amp;nbsp;with RESET pin;&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;&lt;SPAN&gt;The current consumption is 3,4 mA, wich ussual is for a device when only MCU is working (peripheral is sleeping or turned off);&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;As it can be seen from the code snippet above, before the NVIC reset interrupts are disabled;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;MCU doesn't hang up in the main, it's prior that or during the RESET procedure;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;The external crystal is not used;&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;Possibility to occur this case is aprrox. 1 out of &amp;gt;100k resets.&lt;/LI&gt;&lt;LI style="color: #555a5a; font-size: 1.1em; margin-left: 20px; margin-bottom: 0.5em; padding-left: 10px;"&gt;The MCU uses IRC (12 MHz).&lt;/LI&gt;&lt;/UL&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;Is there any suggestions which can be tried? Any ideas is welcome!&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 1.1em; margin: 2em 0px;"&gt;UPDATED: even when reset is made by WDT (feeding the wrong sequence) the same situation occurs.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Feb 2018 14:45:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Processor-Expert-Software/LPC1115-hangs-up-after-soft-reset/m-p/768153#M4142</guid>
      <dc:creator>mantasdi</dc:creator>
      <dc:date>2018-02-22T14:45:27Z</dc:date>
    </item>
  </channel>
</rss>

