<?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 S32K312 SPI CPOL AND CPHA in S32K</title>
    <link>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2016665#M44392</link>
    <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="e14e2ef92135fa426ab6c5ab735a765.png" style="width: 999px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316582iDD507CE5B6FE576A/image-size/large?v=v2&amp;amp;px=999" role="button" title="e14e2ef92135fa426ab6c5ab735a765.png" alt="e14e2ef92135fa426ab6c5ab735a765.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="627ea8982685076da496a77ffe40817.png" style="width: 864px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316583iA3B50F8D58DE0704/image-size/large?v=v2&amp;amp;px=999" role="button" title="627ea8982685076da496a77ffe40817.png" alt="627ea8982685076da496a77ffe40817.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="977a3a3834b0b78627bca213ddf1533.jpg" style="width: 999px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316584i682F4F2E29B8A9CF/image-size/large?v=v2&amp;amp;px=999" role="button" title="977a3a3834b0b78627bca213ddf1533.jpg" alt="977a3a3834b0b78627bca213ddf1533.jpg" /&gt;&lt;/span&gt;I think there is something wrong with my SPI, I don't know where the configuration is wrong, can you tell me?First of all, the SPI of the chip follows CPOL=0 and CPHA=1. I think this should be idle SCK for low level, collecting data at falling edge.So I configured the "SPI" ShiftClockidleLevel for Spi in my S32DS to LOW and "SpiDataShiftEdge" to TRAILING for me given in the graph.However, I captured the waveform diagram of SCK and MOSI through my oscilloscope, and what I can tell you is that the corresponding data of my first 8 SCKS is "00001110". You can see that the MOSI corresponding to the SCK in this waveform is clearly collected for the rising edge. I don't think it's right.You can also see the communication waveform diagram of the chip I gave you. Can you move the corresponding time of SCK or MOSI here, so that the falling edge of SCK corresponds to the data of MOSI? Or you can tell me what I set up wrong, what needs to be changed, or you can give me a correct example. Looking forward to your reply&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="3cb9c812a336a6c85c66f6bae5468a6.png" style="width: 895px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316585i79A01657735DADDC/image-size/large?v=v2&amp;amp;px=999" role="button" title="3cb9c812a336a6c85c66f6bae5468a6.png" alt="3cb9c812a336a6c85c66f6bae5468a6.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 19 Dec 2024 00:39:41 GMT</pubDate>
    <dc:creator>chenyh</dc:creator>
    <dc:date>2024-12-19T00:39:41Z</dc:date>
    <item>
      <title>S32K312 SPI CPOL AND CPHA</title>
      <link>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2016665#M44392</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="e14e2ef92135fa426ab6c5ab735a765.png" style="width: 999px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316582iDD507CE5B6FE576A/image-size/large?v=v2&amp;amp;px=999" role="button" title="e14e2ef92135fa426ab6c5ab735a765.png" alt="e14e2ef92135fa426ab6c5ab735a765.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="627ea8982685076da496a77ffe40817.png" style="width: 864px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316583iA3B50F8D58DE0704/image-size/large?v=v2&amp;amp;px=999" role="button" title="627ea8982685076da496a77ffe40817.png" alt="627ea8982685076da496a77ffe40817.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="977a3a3834b0b78627bca213ddf1533.jpg" style="width: 999px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316584i682F4F2E29B8A9CF/image-size/large?v=v2&amp;amp;px=999" role="button" title="977a3a3834b0b78627bca213ddf1533.jpg" alt="977a3a3834b0b78627bca213ddf1533.jpg" /&gt;&lt;/span&gt;I think there is something wrong with my SPI, I don't know where the configuration is wrong, can you tell me?First of all, the SPI of the chip follows CPOL=0 and CPHA=1. I think this should be idle SCK for low level, collecting data at falling edge.So I configured the "SPI" ShiftClockidleLevel for Spi in my S32DS to LOW and "SpiDataShiftEdge" to TRAILING for me given in the graph.However, I captured the waveform diagram of SCK and MOSI through my oscilloscope, and what I can tell you is that the corresponding data of my first 8 SCKS is "00001110". You can see that the MOSI corresponding to the SCK in this waveform is clearly collected for the rising edge. I don't think it's right.You can also see the communication waveform diagram of the chip I gave you. Can you move the corresponding time of SCK or MOSI here, so that the falling edge of SCK corresponds to the data of MOSI? Or you can tell me what I set up wrong, what needs to be changed, or you can give me a correct example. Looking forward to your reply&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="3cb9c812a336a6c85c66f6bae5468a6.png" style="width: 895px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316585i79A01657735DADDC/image-size/large?v=v2&amp;amp;px=999" role="button" title="3cb9c812a336a6c85c66f6bae5468a6.png" alt="3cb9c812a336a6c85c66f6bae5468a6.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Dec 2024 00:39:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2016665#M44392</guid>
      <dc:creator>chenyh</dc:creator>
      <dc:date>2024-12-19T00:39:41Z</dc:date>
    </item>
    <item>
      <title>Re: S32K312 SPI CPOL AND CPHA</title>
      <link>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2017137#M44421</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/242454"&gt;@chenyh&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Based on the waveform you posted, the protocol you configured is CPOL = 0, CPHA = 0&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_1-1734602210538.png" style="width: 636px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/316700i2771430E3DF9BB8D/image-dimensions/636x256?v=v2" width="636" height="256" role="button" title="danielmartynek_1-1734602210538.png" alt="danielmartynek_1-1734602210538.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Read the Transmit Command Register (TCR).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Dec 2024 10:05:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2017137#M44421</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2024-12-19T10:05:42Z</dc:date>
    </item>
    <item>
      <title>Re: S32K312 SPI CPOL AND CPHA</title>
      <link>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2017509#M44451</link>
      <description>How should I configure SpiDataShiftEdge and ShiftClockidleLevel? Please take a careful look at my requirements and thank you very much.</description>
      <pubDate>Fri, 20 Dec 2024 00:09:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2017509#M44451</guid>
      <dc:creator>chenyh</dc:creator>
      <dc:date>2024-12-20T00:09:06Z</dc:date>
    </item>
    <item>
      <title>Re: S32K312 SPI CPOL AND CPHA</title>
      <link>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2018631#M44543</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/242454"&gt;@chenyh&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;If you need CPOL = 0, CPHA = 1,&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_2-1734964538359.png" style="width: 501px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/317089i5EE62401E853C803/image-dimensions/501x432?v=v2" width="501" height="432" role="button" title="danielmartynek_2-1734964538359.png" alt="danielmartynek_2-1734964538359.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_1-1734964531591.png" style="width: 655px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/317088i547A3151550A5B59/image-dimensions/655x131?v=v2" width="655" height="131" role="button" title="danielmartynek_1-1734964531591.png" alt="danielmartynek_1-1734964531591.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 23 Dec 2024 14:37:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/S32K312-SPI-CPOL-AND-CPHA/m-p/2018631#M44543</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2024-12-23T14:37:19Z</dc:date>
    </item>
  </channel>
</rss>

