<?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>i.MX Processors中的主题 spi clock comfiguration</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/spi-clock-comfiguration/m-p/1633667#M204201</link>
    <description>&lt;P&gt;hi eveyone i configured the LPSPI4 in rt1170 as below the baudarate which i had taken from example but&lt;/P&gt;&lt;P&gt;1) iam not getting how to calculate the baudrate&amp;nbsp;&lt;/P&gt;&lt;P&gt;2)as i configured below iam getting clock frequency 500khz but i need to increase spi clock frequency to 10mhz how can i do it&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;#define LPSPI_MASTER_CLK_FREQ (CLOCK_GetFreqFromObs(CCM_OBS_LPSPI4_CLK_ROOT))&lt;BR /&gt;PRINTF("\r\nSPI INTERFACE CALLED");&lt;BR /&gt;#if 1&lt;BR /&gt;uint32_t srcClock_Hz;&lt;BR /&gt;lpspi_master_config_t masterConfig;&lt;BR /&gt;masterConfig.baudRate =500000;&lt;BR /&gt;masterConfig.bitsPerFrame=8;&lt;BR /&gt;masterConfig.cpol=kLPSPI_ClockPolarityActiveHigh;&lt;BR /&gt;masterConfig.cpha = kLPSPI_ClockPhaseFirstEdge;&lt;BR /&gt;masterConfig.direction = kLPSPI_MsbFirst;&lt;BR /&gt;masterConfig.pcsToSckDelayInNanoSec=1000;&lt;BR /&gt;masterConfig.lastSckToPcsDelayInNanoSec=1000;&lt;BR /&gt;masterConfig.betweenTransferDelayInNanoSec=1000;&lt;BR /&gt;masterConfig.whichPcs = kLPSPI_Pcs1;&lt;BR /&gt;masterConfig.pinCfg = kLPSPI_SdiInSdoOut;&lt;BR /&gt;masterConfig.dataOutConfig=kLpspiDataOutRetained;&lt;BR /&gt;masterConfig.pcsActiveHighOrLow=kLPSPI_SdiInSdoOut;&lt;BR /&gt;srcClock_Hz = LPSPI_MASTER_CLK_FREQ;&lt;BR /&gt;LPSPI_MasterInit(LPSPI4, &amp;amp;masterConfig, srcClock_Hz);&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="i_MXRT1170Processor_0-1681454111692.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/219254i3C9FAA03828E209F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="i_MXRT1170Processor_0-1681454111692.png" alt="i_MXRT1170Processor_0-1681454111692.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 14 Apr 2023 06:35:23 GMT</pubDate>
    <dc:creator>sandeep_c</dc:creator>
    <dc:date>2023-04-14T06:35:23Z</dc:date>
    <item>
      <title>spi clock comfiguration</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/spi-clock-comfiguration/m-p/1633667#M204201</link>
      <description>&lt;P&gt;hi eveyone i configured the LPSPI4 in rt1170 as below the baudarate which i had taken from example but&lt;/P&gt;&lt;P&gt;1) iam not getting how to calculate the baudrate&amp;nbsp;&lt;/P&gt;&lt;P&gt;2)as i configured below iam getting clock frequency 500khz but i need to increase spi clock frequency to 10mhz how can i do it&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;#define LPSPI_MASTER_CLK_FREQ (CLOCK_GetFreqFromObs(CCM_OBS_LPSPI4_CLK_ROOT))&lt;BR /&gt;PRINTF("\r\nSPI INTERFACE CALLED");&lt;BR /&gt;#if 1&lt;BR /&gt;uint32_t srcClock_Hz;&lt;BR /&gt;lpspi_master_config_t masterConfig;&lt;BR /&gt;masterConfig.baudRate =500000;&lt;BR /&gt;masterConfig.bitsPerFrame=8;&lt;BR /&gt;masterConfig.cpol=kLPSPI_ClockPolarityActiveHigh;&lt;BR /&gt;masterConfig.cpha = kLPSPI_ClockPhaseFirstEdge;&lt;BR /&gt;masterConfig.direction = kLPSPI_MsbFirst;&lt;BR /&gt;masterConfig.pcsToSckDelayInNanoSec=1000;&lt;BR /&gt;masterConfig.lastSckToPcsDelayInNanoSec=1000;&lt;BR /&gt;masterConfig.betweenTransferDelayInNanoSec=1000;&lt;BR /&gt;masterConfig.whichPcs = kLPSPI_Pcs1;&lt;BR /&gt;masterConfig.pinCfg = kLPSPI_SdiInSdoOut;&lt;BR /&gt;masterConfig.dataOutConfig=kLpspiDataOutRetained;&lt;BR /&gt;masterConfig.pcsActiveHighOrLow=kLPSPI_SdiInSdoOut;&lt;BR /&gt;srcClock_Hz = LPSPI_MASTER_CLK_FREQ;&lt;BR /&gt;LPSPI_MasterInit(LPSPI4, &amp;amp;masterConfig, srcClock_Hz);&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="i_MXRT1170Processor_0-1681454111692.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/219254i3C9FAA03828E209F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="i_MXRT1170Processor_0-1681454111692.png" alt="i_MXRT1170Processor_0-1681454111692.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Apr 2023 06:35:23 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/spi-clock-comfiguration/m-p/1633667#M204201</guid>
      <dc:creator>sandeep_c</dc:creator>
      <dc:date>2023-04-14T06:35:23Z</dc:date>
    </item>
    <item>
      <title>Re: spi clock comfiguration</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/spi-clock-comfiguration/m-p/1653583#M206153</link>
      <description>&lt;P&gt;Did solve this? I currently have the same problem with 500 kHz SPI clock frequency although I configured 1 MHz.&lt;/P&gt;</description>
      <pubDate>Fri, 19 May 2023 07:02:51 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/spi-clock-comfiguration/m-p/1653583#M206153</guid>
      <dc:creator>nxpuser98</dc:creator>
      <dc:date>2023-05-19T07:02:51Z</dc:date>
    </item>
    <item>
      <title>Re: spi clock comfiguration</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/spi-clock-comfiguration/m-p/1653758#M206171</link>
      <description>yes its solved&lt;BR /&gt;</description>
      <pubDate>Fri, 19 May 2023 09:52:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/spi-clock-comfiguration/m-p/1653758#M206171</guid>
      <dc:creator>sandeep_c</dc:creator>
      <dc:date>2023-05-19T09:52:46Z</dc:date>
    </item>
  </channel>
</rss>

