<?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 SPI interbyte delay on K26/K65 in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714942#M43917</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Working on optimizing transfer rates to s SPI flash I have observed quite large inter byte/word delay on the SPI bus.&lt;/P&gt;&lt;P&gt;My system is running 120 MHz system clock and 30 MHz SPI clock, and i am using the standard fsl_dspi_edma driver.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When transmitting multiples bytes via DMA, i see that the transfer of the each 8 data bits take about 266ns as expected, but between bytes i see a delay of &amp;nbsp;~100 ns. &amp;nbsp; Transfer is done with&amp;nbsp;kDSPI_MasterPcsContinuous set.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was initially using SPI1, and as i was suspecting the delay being related to the missing FIFO on this channel i moved to SPI0 that has 4 level FIFO. &amp;nbsp;However i see the same timing the channel.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Are there any ways to control interword timing on SPI transfers or is the interbyte delay expected behaviour?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="scope_2.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/29896i13B5D0A6A8A39AAB/image-size/large?v=v2&amp;amp;px=999" role="button" title="scope_2.png" alt="scope_2.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 05 Sep 2017 09:04:44 GMT</pubDate>
    <dc:creator>aescov</dc:creator>
    <dc:date>2017-09-05T09:04:44Z</dc:date>
    <item>
      <title>SPI interbyte delay on K26/K65</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714942#M43917</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Working on optimizing transfer rates to s SPI flash I have observed quite large inter byte/word delay on the SPI bus.&lt;/P&gt;&lt;P&gt;My system is running 120 MHz system clock and 30 MHz SPI clock, and i am using the standard fsl_dspi_edma driver.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When transmitting multiples bytes via DMA, i see that the transfer of the each 8 data bits take about 266ns as expected, but between bytes i see a delay of &amp;nbsp;~100 ns. &amp;nbsp; Transfer is done with&amp;nbsp;kDSPI_MasterPcsContinuous set.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was initially using SPI1, and as i was suspecting the delay being related to the missing FIFO on this channel i moved to SPI0 that has 4 level FIFO. &amp;nbsp;However i see the same timing the channel.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Are there any ways to control interword timing on SPI transfers or is the interbyte delay expected behaviour?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="scope_2.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/29896i13B5D0A6A8A39AAB/image-size/large?v=v2&amp;amp;px=999" role="button" title="scope_2.png" alt="scope_2.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Sep 2017 09:04:44 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714942#M43917</guid>
      <dc:creator>aescov</dc:creator>
      <dc:date>2017-09-05T09:04:44Z</dc:date>
    </item>
    <item>
      <title>Re: SPI interbyte delay on K26/K65</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714943#M43918</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;'For better or worse' Tpcssck, Tpasc, and Tdt apply between transfers, whether there are CS edges or not.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That being said, I have been unable to squeeze out '1.5 clocks' of internal transfer delay either.&amp;nbsp; I show an extra 50ns below (317ns/byte, rather than 'ideal' 267).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BTW, I hope all that 'ringing' on your clock is due to poor scope grounding --- else you should be looking into some signal termination!&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/28126i2CA48AB296929485/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Sep 2017 11:40:38 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714943#M43918</guid>
      <dc:creator>egoodii</dc:creator>
      <dc:date>2017-09-05T11:40:38Z</dc:date>
    </item>
    <item>
      <title>Re: SPI interbyte delay on K26/K65</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714944#M43919</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Earl&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First of all the ringing on SCK is due to my measurement setup.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What did you do reduce the interbyte gap to 50ns.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;From the formulas in the reference manual i would expect something like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;System clock 120 MHz - &amp;nbsp;Bus Clock 60 Mhz&amp;nbsp;&lt;/P&gt;&lt;P&gt;PCSSCK=0, CSSCk=0 --&amp;gt; tcsc=(1/60M)*1*2=33,3ns&lt;BR /&gt;PASS=0, ASC=0, tasc=(1/60M)*1*2=33,3ns&lt;/P&gt;&lt;P&gt;PDT=0, DT=0, tdt=(1/60M)*1*2=33,3ns&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Whith continous PCS only tasc and tcsc components should be in effect, resulting in 66,7ns&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/28241i07A8D3481C970EE1/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However with these settings I stil get ~100ns gaps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Sep 2017 06:36:18 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714944#M43919</guid>
      <dc:creator>aescov</dc:creator>
      <dc:date>2017-09-06T06:36:18Z</dc:date>
    </item>
    <item>
      <title>Re: SPI interbyte delay on K26/K65</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714945#M43920</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just to be clear, the diagram you inserted times from one falling-edge to the ensuing rising, which in my picture is indeed 66.7ns --- my calculation is '50ns extra' above the &lt;EM&gt;required&lt;/EM&gt; 1/2-clock 'low' period.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All I can immediately say is that I am actually NOT running a DMA operation --- I have 'nothing else to do at the time' so this is a program loop transfer (which simultaneously drops the words into the CRC engine to net a CRC-check of the upload).&amp;nbsp; Admittedly, it is 'quite hard' to keep up with &amp;gt;3Mtransfers/sec, and I only get this 50ns while the loop can indeed keep the FIFO ahead of 'need'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you know that this DMA-based driver enables full FIFO depth on this channel?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Sep 2017 10:41:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/SPI-interbyte-delay-on-K26-K65/m-p/714945#M43920</guid>
      <dc:creator>egoodii</dc:creator>
      <dc:date>2017-09-06T10:41:03Z</dc:date>
    </item>
  </channel>
</rss>

