<?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: LPC55S16 Watchdog Warning interrupt in LPC Microcontrollers</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1968784#M56966</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;DIV&gt;Pls try to enlarge the led on time with the code:&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN class="test-id__field-value slds-form-element__static slds-grow word-break-ie11"&gt;wdtFreq = CLOCK_GetWdtClkFreq() / 1;&lt;/SPAN&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;what is the result?&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;BR&lt;/DIV&gt;
&lt;DIV&gt;XiangJun Rong&lt;/DIV&gt;</description>
    <pubDate>Tue, 08 Oct 2024 09:26:45 GMT</pubDate>
    <dc:creator>xiangjun_rong</dc:creator>
    <dc:date>2024-10-08T09:26:45Z</dc:date>
    <item>
      <title>LPC55S16 Watchdog Warning interrupt</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1966799#M56953</link>
      <description>&lt;P&gt;I did modify the WDT example to generate a warning interrupt before the CPU is reseted but i couldn't get the GREEN led on or that the interrupt is called before the WTD resets the CPU.&lt;/P&gt;&lt;P&gt;The warning is configured for 2 second and the timeout with 6 seconds.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;config.timeoutValue = wdtFreq * 6;
config.warningValue = wdtFreq * 2;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If i disable the reset then the interrupt was called after 6 seconds with the warning flag set instead of the timeout flag.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone help me here with this problem?&lt;/P&gt;</description>
      <pubDate>Fri, 04 Oct 2024 07:57:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1966799#M56953</guid>
      <dc:creator>szempy</dc:creator>
      <dc:date>2024-10-04T07:57:49Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55S16 Watchdog Warning interrupt</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1968784#M56966</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;DIV&gt;Pls try to enlarge the led on time with the code:&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN class="test-id__field-value slds-form-element__static slds-grow word-break-ie11"&gt;wdtFreq = CLOCK_GetWdtClkFreq() / 1;&lt;/SPAN&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;what is the result?&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;BR&lt;/DIV&gt;
&lt;DIV&gt;XiangJun Rong&lt;/DIV&gt;</description>
      <pubDate>Tue, 08 Oct 2024 09:26:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1968784#M56966</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2024-10-08T09:26:45Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55S16 Watchdog Warning interrupt</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1969012#M56971</link>
      <description>Same result with 4 times longer.&lt;BR /&gt;You do understand my problem right?&lt;BR /&gt;The WTD warning interrupt is not called as it supposed to be.</description>
      <pubDate>Tue, 08 Oct 2024 14:25:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1969012#M56971</guid>
      <dc:creator>szempy</dc:creator>
      <dc:date>2024-10-08T14:25:35Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55S16 Watchdog Warning interrupt</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1972077#M57030</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;DIV&gt;I have tested your code, these are the register value of WDT.&lt;/DIV&gt;
&lt;DIV&gt;It appears that you do not set up the WINDOW register, but you use the &lt;SPAN&gt;delayWwdtWindow() condition to feed dog.&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;am I right?&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;Note that the WARNINT reg is a 10 bits register&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;
&lt;DIV id="tinyMceEditorxiangjun_rong_0" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xiangjun_rong_1-1728639532451.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/304205iFB318C8DCA6429BD/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xiangjun_rong_1-1728639532451.png" alt="xiangjun_rong_1-1728639532451.png" /&gt;&lt;/span&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;BR clear="none" /&gt;
&lt;DIV style="background-color: #ffffff; padding: 0px 0px 0px 2px;"&gt;
&lt;DIV style="color: #000000; background-color: #ffffff; font-family: 'Consolas'; font-size: 10pt; white-space: pre;"&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt;void&lt;/SPAN&gt; &lt;SPAN&gt;delayWwdtWindow&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;void&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt;/* For the TV counter register value will decrease after feed watch dog,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt; * we can use it to as delay. But in user scene, user need feed watch dog&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt; * in the time period after enter Window but before warning &lt;/SPAN&gt;&lt;SPAN&gt;intterupt&lt;/SPAN&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt; */&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt;while&lt;/SPAN&gt;&lt;SPAN&gt; (WWDT-&amp;gt;&lt;/SPAN&gt;&lt;SPAN&gt;TV&lt;/SPAN&gt;&lt;SPAN&gt; &amp;gt; WWDT-&amp;gt;&lt;/SPAN&gt;&lt;SPAN&gt;WINDOW&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt; {&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt; __NOP();&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt; }&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0px;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
You have to set up the TC,WINDOW and WARNINT registers to a proper value. so that the TV can reach down to the WARNINT reg.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Pls try to set up the above three reg to a proper value.&lt;/DIV&gt;
&lt;DIV&gt;Hope it can help you&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Regard&lt;/DIV&gt;
&lt;DIV&gt;XiangJun Rong&lt;/DIV&gt;</description>
      <pubDate>Fri, 11 Oct 2024 09:40:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1972077#M57030</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2024-10-11T09:40:01Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55S16 Watchdog Warning interrupt</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1977888#M57118</link>
      <description>&lt;P&gt;It seams that you don't really understand how this example works.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The first time when the program starts the&amp;nbsp;&lt;SPAN&gt;timeOutResetEnable is set to true. If there is a watchdog reset then it will feed the Watchdog.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If the&amp;nbsp;timeOutResetEnable is true then the Watchdog won't be feed.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I have changed now the settings to:&lt;/SPAN&gt;&lt;/P&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;config.timeoutValue = wdtFreq * 6;
config.warningValue = 510;
config.windowValue = wdtFreq * 6;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So this are the set values:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot_12.jpg" style="width: 472px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/305776i4AB4572D4B7EDCEC/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot_12.jpg" alt="Screenshot_12.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;What i want is that before the processor is resettled that the&amp;nbsp;&lt;SPAN&gt;WDT_BOD_IRQHandler is called and i can do some things before the reset.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Can you give me some example how can achieve that?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 21 Oct 2024 07:34:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1977888#M57118</guid>
      <dc:creator>szempy</dc:creator>
      <dc:date>2024-10-21T07:34:50Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55S16 Watchdog Warning interrupt</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1987809#M57211</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;CLOCK_SetClkDiv(kCLOCK_DivWdtClk, 64U, true);

config.warningValue = 0x3FF;​&lt;/LI-CODE&gt;&lt;P&gt;You were right, the interrupt is working, but the time frame between the interrupt and the watchdog reset was so short that I didn't notice when he led turned on and when the watchdog reseted the board the led was off again, and the debugger didn't stop in the interrupt as well for the same reason.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;After putting the divider for the timer to the maximum of 64 and setting the warning value to the maximum 1023 the debugger did stop in the interrupt.&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Thank you for your help again.&lt;/DIV&gt;</description>
      <pubDate>Tue, 05 Nov 2024 08:34:59 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55S16-Watchdog-Warning-interrupt/m-p/1987809#M57211</guid>
      <dc:creator>szempy</dc:creator>
      <dc:date>2024-11-05T08:34:59Z</dc:date>
    </item>
  </channel>
</rss>

