<?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: Watchdog timeout calculation in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188452#M58926</link>
    <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;There is a 3 bit pre-scaler which defaults to 4 (divide by 5) and so the time is correct without needing to also adjust this when the 5 is taken into account.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mjbcswitzerland_0-1606255566267.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/130898i386A8DB08869920E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="mjbcswitzerland_0-1606255566267.png" alt="mjbcswitzerland_0-1606255566267.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Notice that the macro sets the most significant half word of the compare register to 0 since it already works for up to 320s and greater values would only be of use when the bus clock were used instead. &lt;EM&gt;Typically a couple seconds are used for the watchdog timeout.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Mark&lt;BR /&gt;&lt;EM&gt;[uTasker project developer for Kinetis and i.MX RT]&lt;/EM&gt;&lt;BR /&gt;&lt;FONT color="#999999"&gt;Contact me by personal message or on the uTasker web site to discuss professional training, solutions to problems or product development requirements&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 24 Nov 2020 22:11:02 GMT</pubDate>
    <dc:creator>mjbcswitzerland</dc:creator>
    <dc:date>2020-11-24T22:11:02Z</dc:date>
    <item>
      <title>Watchdog timeout calculation</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188380#M58916</link>
      <description>&lt;P&gt;I`m a newbie. Working with&amp;nbsp;&lt;A href="https://www.nxp.com/files/32bit/doc/ref_manual/K20P81M100SF2V2RM.pdf" rel="nofollow" target="_blank"&gt;MK20DN512VLK10&lt;/A&gt;. Please, advice the formula for the watchdog timeout calculation. If possible, to have seconds. Plan to use LPO clock.&lt;/P&gt;&lt;P&gt;Thank you very much. My first project.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Nov 2020 18:04:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188380#M58916</guid>
      <dc:creator>Oleksii</dc:creator>
      <dc:date>2020-11-24T18:04:33Z</dc:date>
    </item>
    <item>
      <title>Re: Watchdog timeout calculation</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188433#M58921</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;For your device and the watchdog clocked from LPO:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;// Watchdog enable and configure macro&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;//&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;#define ENABLE_WATCHDOG_TIMEOUT_SECONDS(time)&amp;nbsp; \&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;UNLOCK_WDOG();\&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;WDOG_TOVALL = (time * 1000/5);\&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;WDOG_TOVALH = 0;\&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;WDOG_STCTRLH = (WDOG_STCTRLH_STNDBYEN | WDOG_STCTRLH_WAITEN | WDOG_STCTRLH_STOPEN | WDOG_STCTRLH_WDOGEN)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In code use this for 1 second timeout&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ENABLE_WATCHDOG_TIMEOUT_SECONDS(1); // watchdog enabled to generate reset on 1s timeout (no further updates allowed)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;From open source uTasker project with Kinetis simulation - for faster learning and faster developments at &lt;A href="https://github.com/uTasker/uTasker-Kinetis" target="_blank" rel="noopener"&gt;https://github.com/uTasker/uTasker-Kinetis&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Mark&lt;BR /&gt;&lt;EM&gt;[uTasker project developer for Kinetis and i.MX RT]&lt;/EM&gt;&lt;BR /&gt;&lt;FONT color="#999999"&gt;Contact me by personal message or on the uTasker web site to discuss professional training, solutions to problems or product development requirements&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Nov 2020 21:07:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188433#M58921</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2020-11-24T21:07:26Z</dc:date>
    </item>
    <item>
      <title>Re: Watchdog timeout calculation</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188442#M58924</link>
      <description>&lt;P&gt;Hi Mark, thank you very much for the reply. Can I ask you to clarify why do we need devision by 5 in&amp;nbsp;&lt;STRONG&gt;WDOG_TOVALL = (time * 1000/5).&lt;BR /&gt;&lt;/STRONG&gt;Just want to be fully aware of the logic.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;Thank you.&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Nov 2020 21:27:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188442#M58924</guid>
      <dc:creator>Oleksii</dc:creator>
      <dc:date>2020-11-24T21:27:00Z</dc:date>
    </item>
    <item>
      <title>Re: Watchdog timeout calculation</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188443#M58925</link>
      <description>&lt;P&gt;Hi Mark, thank you very much for the reply.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can I ask you to clarify why do we need devision by 5 in&amp;nbsp;&lt;STRONG&gt;WDOG_TOVALL = (time * 1000/5).&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Just want to be fully aware of the logic.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;Thank you.&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Nov 2020 21:44:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188443#M58925</guid>
      <dc:creator>Oleksii</dc:creator>
      <dc:date>2020-11-24T21:44:33Z</dc:date>
    </item>
    <item>
      <title>Re: Watchdog timeout calculation</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188452#M58926</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;There is a 3 bit pre-scaler which defaults to 4 (divide by 5) and so the time is correct without needing to also adjust this when the 5 is taken into account.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mjbcswitzerland_0-1606255566267.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/130898i386A8DB08869920E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="mjbcswitzerland_0-1606255566267.png" alt="mjbcswitzerland_0-1606255566267.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Notice that the macro sets the most significant half word of the compare register to 0 since it already works for up to 320s and greater values would only be of use when the bus clock were used instead. &lt;EM&gt;Typically a couple seconds are used for the watchdog timeout.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Mark&lt;BR /&gt;&lt;EM&gt;[uTasker project developer for Kinetis and i.MX RT]&lt;/EM&gt;&lt;BR /&gt;&lt;FONT color="#999999"&gt;Contact me by personal message or on the uTasker web site to discuss professional training, solutions to problems or product development requirements&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 Nov 2020 22:11:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188452#M58926</guid>
      <dc:creator>mjbcswitzerland</dc:creator>
      <dc:date>2020-11-24T22:11:02Z</dc:date>
    </item>
    <item>
      <title>Re: Watchdog timeout calculation</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188455#M58928</link>
      <description>&lt;P&gt;Thank you very much for the detailed explanation.&lt;/P&gt;</description>
      <pubDate>Tue, 24 Nov 2020 22:20:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/Watchdog-timeout-calculation/m-p/1188455#M58928</guid>
      <dc:creator>Oleksii</dc:creator>
      <dc:date>2020-11-24T22:20:45Z</dc:date>
    </item>
  </channel>
</rss>

