<?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>LPC MicrocontrollersのトピックGlitch in RTC high-resolution/wake-up timer</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1270181#M44844</link>
    <description>&lt;P&gt;I am developing LPC540xxx project that uses the RTC high-resolution/wake-up timer (1kHz) as a tick.&lt;/P&gt;&lt;P&gt;This program often shows an abnormal value in the wake-up register. I found a description of another 1Hz RTC counter register having a glitch. There is no description about glitches in the 1kHz register, but I put the same deglitch code in RTC_GetWakeupCount() of the fsl_rtc driver as in RTC_GetSecondsTimerCount(), and it seems to work.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;It seems that RTC_GetWakeupCount() needs to be modified.&lt;/P&gt;</description>
    <pubDate>Thu, 29 Apr 2021 08:11:20 GMT</pubDate>
    <dc:creator>yo_ku_</dc:creator>
    <dc:date>2021-04-29T08:11:20Z</dc:date>
    <item>
      <title>Glitch in RTC high-resolution/wake-up timer</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1270181#M44844</link>
      <description>&lt;P&gt;I am developing LPC540xxx project that uses the RTC high-resolution/wake-up timer (1kHz) as a tick.&lt;/P&gt;&lt;P&gt;This program often shows an abnormal value in the wake-up register. I found a description of another 1Hz RTC counter register having a glitch. There is no description about glitches in the 1kHz register, but I put the same deglitch code in RTC_GetWakeupCount() of the fsl_rtc driver as in RTC_GetSecondsTimerCount(), and it seems to work.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;It seems that RTC_GetWakeupCount() needs to be modified.&lt;/P&gt;</description>
      <pubDate>Thu, 29 Apr 2021 08:11:20 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1270181#M44844</guid>
      <dc:creator>yo_ku_</dc:creator>
      <dc:date>2021-04-29T08:11:20Z</dc:date>
    </item>
    <item>
      <title>Re: Glitch in RTC high-resolution/wake-up timer</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1270652#M44859</link>
      <description>&lt;P&gt;Hi, Yosuke,&lt;/P&gt;
&lt;P&gt;As far as I know that the 1KHz RTC high resolution RTC counter driving clock&amp;nbsp; is an internal clock signal, there is not any external pad, how did you&amp;nbsp; deglitch the 1kHz signal?&lt;/P&gt;
&lt;P&gt;Can you share the code of RTC_GetWakeupCount()&amp;nbsp; api function so that we can have a review?&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Fri, 30 Apr 2021 05:19:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1270652#M44859</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-04-30T05:19:53Z</dc:date>
    </item>
    <item>
      <title>Re: Glitch in RTC high-resolution/wake-up timer</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1271095#M44873</link>
      <description>&lt;P&gt;Hi ,&lt;SPAN&gt;XiangJun Rong&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;My "glitch" is not a glitch in the clock waveform. It is that I get an abnormal value when I access an out-of-sync register on the bus.&lt;BR /&gt;The code is as follows,&amp;nbsp;It gets the register value twice, just like RTC_GetSecondsTimerCount().&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;static inline uint16_t RTC_GetWakeupCount(RTC_Type *base)&lt;BR /&gt;{&lt;BR /&gt;uint32_t a, b;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;/* Follow the RF document to read the RTC default seconds timer (1HZ) counter value. */&lt;BR /&gt;do&lt;BR /&gt;{&lt;BR /&gt;a = base-&amp;gt;WAKE;&lt;BR /&gt;b = base-&amp;gt;WAKE;&lt;BR /&gt;} while (a != b);&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;return (uint16_t)((b &amp;amp; RTC_WAKE_VAL_MASK) &amp;gt;&amp;gt; RTC_WAKE_VAL_SHIFT);&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;B.R.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 02 May 2021 11:03:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1271095#M44873</guid>
      <dc:creator>yo_ku_</dc:creator>
      <dc:date>2021-05-02T11:03:06Z</dc:date>
    </item>
    <item>
      <title>Re: Glitch in RTC high-resolution/wake-up timer</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1272571#M44894</link>
      <description>&lt;P&gt;Hi, Yosuke,&lt;/P&gt;
&lt;P&gt;As you know that reading the base-&amp;gt;WAKE; register is faster than counting the base-&amp;gt;WAKE; register, so it is difficult to meet the condition while (a != b);&lt;/P&gt;
&lt;P&gt;Hope it can help you&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Thu, 06 May 2021 02:37:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/Glitch-in-RTC-high-resolution-wake-up-timer/m-p/1272571#M44894</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-05-06T02:37:26Z</dc:date>
    </item>
  </channel>
</rss>

