<?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>ColdFire/68K Microcontrollers and ProcessorsのトピックProblem with the QSPI module.</title>
    <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Problem-with-the-QSPI-module/m-p/131515#M927</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi, I'm trying to use the QSPI-module on the MCF52235, be i can't get more than one byte transferred even though i put four bytes in the queue. If i put a oscilloscope to the data out, chip select and the clock-pin i see that the first byte gets transmitted, but the chip select is low (active low) for a 4 bit transfer. This is the code that i wrote:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QMR = 0x51C4;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Select the Command ram position and set up the command queue.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QAR = 0x0020;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Select the TRANSMT RAM and write the byte to transfer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QAR = 0x0000;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xAAAA;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xBBBB;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xCCCC;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xDDDD;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Set up the write queue pointers&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QWR = MCF_QSPI_QWR_ENDQP(4) | MCF_QSPI_QWR_NEWQP(0x00);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;//Set the command to start the spi transfer;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDLYR |= MCF_QSPI_QDLYR_SPE;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Wait until the operation has been completed&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;while (!(MCF_QSPI_QIR &amp;amp; MCF_QSPI_QIR_SPIF));&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Select the Receive RAM and get the result&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QAR = 0x0010;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This code shuld work i think, but like i said, i only get one byte transferred. Doe's anyone know what's wrong?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Best Wishes&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Johnny Karlsson&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 27 Sep 2006 15:22:29 GMT</pubDate>
    <dc:creator>J_karlsson</dc:creator>
    <dc:date>2006-09-27T15:22:29Z</dc:date>
    <item>
      <title>Problem with the QSPI module.</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Problem-with-the-QSPI-module/m-p/131515#M927</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi, I'm trying to use the QSPI-module on the MCF52235, be i can't get more than one byte transferred even though i put four bytes in the queue. If i put a oscilloscope to the data out, chip select and the clock-pin i see that the first byte gets transmitted, but the chip select is low (active low) for a 4 bit transfer. This is the code that i wrote:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QMR = 0x51C4;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Select the Command ram position and set up the command queue.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QAR = 0x0020;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0x8200;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Select the TRANSMT RAM and write the byte to transfer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QAR = 0x0000;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xAAAA;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xBBBB;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xCCCC;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDR = 0xDDDD;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Set up the write queue pointers&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QWR = MCF_QSPI_QWR_ENDQP(4) | MCF_QSPI_QWR_NEWQP(0x00);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;//Set the command to start the spi transfer;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QDLYR |= MCF_QSPI_QDLYR_SPE;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Wait until the operation has been completed&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;while (!(MCF_QSPI_QIR &amp;amp; MCF_QSPI_QIR_SPIF));&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//Select the Receive RAM and get the result&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;MCF_QSPI_QAR = 0x0010;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;*result++ = MCF_QSPI_QDR;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This code shuld work i think, but like i said, i only get one byte transferred. Doe's anyone know what's wrong?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Best Wishes&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Johnny Karlsson&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 15:22:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Problem-with-the-QSPI-module/m-p/131515#M927</guid>
      <dc:creator>J_karlsson</dc:creator>
      <dc:date>2006-09-27T15:22:29Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with the QSPI module.</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Problem-with-the-QSPI-module/m-p/131516#M928</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;one possible problem:&lt;BR /&gt;see Reference Manual Ch. 25.3.1 Table 25-3 bit 15:&lt;BR /&gt;MSTR : 1 The QSPI is in master mode. Must be set for the QSPI module to operate correctly.&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;stzari&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 21:33:31 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Problem-with-the-QSPI-module/m-p/131516#M928</guid>
      <dc:creator>stzari</dc:creator>
      <dc:date>2006-09-27T21:33:31Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with the QSPI module.</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Problem-with-the-QSPI-module/m-p/131517#M929</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;Hi, thanks for the suggestion but i found the problem be myself just after&lt;BR /&gt;posting this question :smileyhappy:. The problem was that i hadn't cleared the&lt;BR /&gt;MCF_QSPI_QIR_SPIF bit in the QIR register. So when the code starts checking&lt;BR /&gt;for the MCF_QSPI_QIR_SPIF bit it would have immediately returned true.&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 Sep 2006 21:39:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Problem-with-the-QSPI-module/m-p/131517#M929</guid>
      <dc:creator>J_karlsson</dc:creator>
      <dc:date>2006-09-27T21:39:40Z</dc:date>
    </item>
  </channel>
</rss>

