<?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 KL25Z pinmap mis-match error in Kinetis Microcontrollers</title>
    <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KL25Z-pinmap-mis-match-error/m-p/672210#M41290</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to use an SPI interface to talk to 8 slaves using a KL25Z. I figured that using the same MISO pin for all the eight boards was not working out, so I used different pins. Everything was working well when suddenly today the board decided to start misbehaving. This is the relevant part of my code(or so I believe) -&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#include "mbed.h"&lt;BR /&gt;#include &amp;lt;spi_functions.h&amp;gt;&lt;BR /&gt;#include &amp;lt;vector&amp;gt;&lt;BR /&gt;#include &amp;lt;string&amp;gt;&lt;/P&gt;&lt;P&gt;void doCommands(string command[3]);&lt;BR /&gt;using namespace std;&lt;/P&gt;&lt;P&gt;// DEFINE SERIAL INTERFACE AND PINS USED BY THE SPI PROTOCOL&lt;BR /&gt;Serial pc(USBTX, USBRX); // tx, rx&lt;BR /&gt;SPI dac_port1(PTD2, PTD3, PTD1); //mosi, miso, sclk&lt;BR /&gt;SPI dac_port2(PTD2, PTE3, PTD1);&lt;BR /&gt;SPI dac_port3(PTD2, PTC7, PTD1);&lt;BR /&gt;SPI dac_port4(PTD2, PTC6, PTD1);//was PTD6&lt;BR /&gt;SPI dac_port5(PTD2, PTA17, PTD1);&lt;BR /&gt;SPI dac_port6(PTD2, PTD7, PTD1);&lt;BR /&gt;SPI dac_port7(PTD2, PTE1, PTD1);&lt;BR /&gt;SPI dac_port8(PTD2, PTA16, PTD1);&lt;BR /&gt;DigitalOut sync1(PTD5, 1);// Board 1 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync2(PTD0, 1); // Board 2 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync3(PTC5, 1); // Board 3 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync4(PTB11, 1);// Board 4 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync5(PTB10, 1); // Board 5 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync6(PTE2, 1);// Board 6 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync7(PTD4, 1);// Board 7 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync8(PTC4, 1); // Board 8 slave select. Initialize to high&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can someone help in this regard?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 23 Jun 2017 15:35:42 GMT</pubDate>
    <dc:creator>sagaraddepalli</dc:creator>
    <dc:date>2017-06-23T15:35:42Z</dc:date>
    <item>
      <title>KL25Z pinmap mis-match error</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KL25Z-pinmap-mis-match-error/m-p/672210#M41290</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to use an SPI interface to talk to 8 slaves using a KL25Z. I figured that using the same MISO pin for all the eight boards was not working out, so I used different pins. Everything was working well when suddenly today the board decided to start misbehaving. This is the relevant part of my code(or so I believe) -&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#include "mbed.h"&lt;BR /&gt;#include &amp;lt;spi_functions.h&amp;gt;&lt;BR /&gt;#include &amp;lt;vector&amp;gt;&lt;BR /&gt;#include &amp;lt;string&amp;gt;&lt;/P&gt;&lt;P&gt;void doCommands(string command[3]);&lt;BR /&gt;using namespace std;&lt;/P&gt;&lt;P&gt;// DEFINE SERIAL INTERFACE AND PINS USED BY THE SPI PROTOCOL&lt;BR /&gt;Serial pc(USBTX, USBRX); // tx, rx&lt;BR /&gt;SPI dac_port1(PTD2, PTD3, PTD1); //mosi, miso, sclk&lt;BR /&gt;SPI dac_port2(PTD2, PTE3, PTD1);&lt;BR /&gt;SPI dac_port3(PTD2, PTC7, PTD1);&lt;BR /&gt;SPI dac_port4(PTD2, PTC6, PTD1);//was PTD6&lt;BR /&gt;SPI dac_port5(PTD2, PTA17, PTD1);&lt;BR /&gt;SPI dac_port6(PTD2, PTD7, PTD1);&lt;BR /&gt;SPI dac_port7(PTD2, PTE1, PTD1);&lt;BR /&gt;SPI dac_port8(PTD2, PTA16, PTD1);&lt;BR /&gt;DigitalOut sync1(PTD5, 1);// Board 1 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync2(PTD0, 1); // Board 2 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync3(PTC5, 1); // Board 3 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync4(PTB11, 1);// Board 4 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync5(PTB10, 1); // Board 5 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync6(PTE2, 1);// Board 6 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync7(PTD4, 1);// Board 7 slave select. Initialize to high&lt;BR /&gt;DigitalOut sync8(PTC4, 1); // Board 8 slave select. Initialize to high&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can someone help in this regard?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 23 Jun 2017 15:35:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/KL25Z-pinmap-mis-match-error/m-p/672210#M41290</guid>
      <dc:creator>sagaraddepalli</dc:creator>
      <dc:date>2017-06-23T15:35:42Z</dc:date>
    </item>
    <item>
      <title>Re: KL25Z pinmap mis-match error</title>
      <link>https://community.nxp.com/t5/Kinetis-Microcontrollers/KL25Z-pinmap-mis-match-error/m-p/672211#M41291</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am quite curious with your select the SPI MISO pins.&lt;/P&gt;&lt;P&gt;I check you select the PTD2 as MOSI, which belongs to SPI0 module.&lt;/P&gt;&lt;P&gt;While, the PTD3/PTD7/PTE1/PTE3 as MISO function belongs to SPI1 module.&lt;/P&gt;&lt;P&gt;Please make sure the SPI slave doesn't be selected at the same time to output data to SPI master.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Have a great day,&lt;BR /&gt;Ma Hui&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Jul 2017 08:04:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Microcontrollers/KL25Z-pinmap-mis-match-error/m-p/672211#M41291</guid>
      <dc:creator>Hui_Ma</dc:creator>
      <dc:date>2017-07-11T08:04:06Z</dc:date>
    </item>
  </channel>
</rss>

