<?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>Kinetis Software Development Kit中的主题 Hires timestamp</title>
    <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Hires-timestamp/m-p/397559#M1329</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We are using K64F12, KDS-2.0, KSDK-1.1.0 in a measurement system. When performing measurements we must have a hi-res timer to time-stamp measurements.&lt;/P&gt;&lt;P&gt;I've used the fsl_hwtimer as timer, but it seems to load the system terribly!!! I must have a timer with resolution 8us, and I've made this test:&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. The CPU is running at 20.9 MHz&lt;/P&gt;&lt;P&gt;2. The fsl_hwtimer is set to a period of 1000 us&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've connected a logic-analyzer to the serial-port and times how long it will take to print 256 x 'a' (115200 baud)&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A: When fsl_timer running at 1000us, the output is done in 81ms&lt;/P&gt;&lt;P&gt;B: When fsl_timer is changed to 10us, the output is done in 1787.9 ms !!!&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It seems that the only source for fsl_timer is PIT.&lt;/P&gt;&lt;P&gt;I don't understand why the change of the timer frequency should slow down the system this much. I thought that how fast the clock was running should not be&lt;/P&gt;&lt;P&gt;noticable for the sw at all?&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What should I do to get my hi-resolution sample-timer, and NOT slow down my sw to a limping run?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 10 Apr 2015 13:27:34 GMT</pubDate>
    <dc:creator>oaf</dc:creator>
    <dc:date>2015-04-10T13:27:34Z</dc:date>
    <item>
      <title>Hires timestamp</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Hires-timestamp/m-p/397559#M1329</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We are using K64F12, KDS-2.0, KSDK-1.1.0 in a measurement system. When performing measurements we must have a hi-res timer to time-stamp measurements.&lt;/P&gt;&lt;P&gt;I've used the fsl_hwtimer as timer, but it seems to load the system terribly!!! I must have a timer with resolution 8us, and I've made this test:&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. The CPU is running at 20.9 MHz&lt;/P&gt;&lt;P&gt;2. The fsl_hwtimer is set to a period of 1000 us&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've connected a logic-analyzer to the serial-port and times how long it will take to print 256 x 'a' (115200 baud)&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A: When fsl_timer running at 1000us, the output is done in 81ms&lt;/P&gt;&lt;P&gt;B: When fsl_timer is changed to 10us, the output is done in 1787.9 ms !!!&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It seems that the only source for fsl_timer is PIT.&lt;/P&gt;&lt;P&gt;I don't understand why the change of the timer frequency should slow down the system this much. I thought that how fast the clock was running should not be&lt;/P&gt;&lt;P&gt;noticable for the sw at all?&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What should I do to get my hi-resolution sample-timer, and NOT slow down my sw to a limping run?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Apr 2015 13:27:34 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Hires-timestamp/m-p/397559#M1329</guid>
      <dc:creator>oaf</dc:creator>
      <dc:date>2015-04-10T13:27:34Z</dc:date>
    </item>
  </channel>
</rss>

