<?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 Re: USB mass storage class - answering to SCSI inquiry ? in ColdFire/68K Microcontrollers and Processors</title>
    <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/USB-mass-storage-class-answering-to-SCSI-inquiry/m-p/163740#M5439</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Using a dedicated endpoint, one for IN and one for OUT solves this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 01 Sep 2011 21:58:50 GMT</pubDate>
    <dc:creator>mickz</dc:creator>
    <dc:date>2011-09-01T21:58:50Z</dc:date>
    <item>
      <title>USB mass storage class - answering to SCSI inquiry ?</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/USB-mass-storage-class-answering-to-SCSI-inquiry/m-p/163739#M5438</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lvr.com%2Fforum%2Findex.php%3Faction%3Dprofile%3Bu%3D1396" rel="nofollow" target="_blank"&gt;&lt;IMG alt="View Profile" border="0" src="http://www.lvr.com/forum/Themes/default/images/icons/profile_sm.gif" title="View Profile" /&gt;&lt;/A&gt;&lt;A href="mailto:micky686@gmail.com"&gt;&lt;IMG alt="Email" border="0" src="http://www.lvr.com/forum/Themes/default/images/email_sm.gif" title="Email" /&gt;&lt;/A&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lvr.com%2Fforum%2Findex.php%3Faction%3Dpm%3Bsa%3Dsend%3Bu%3D1396" rel="nofollow" target="_blank"&gt;&lt;IMG alt="" border="0" src="http://www.lvr.com/forum/Themes/default/images/im_on.gif" /&gt;&lt;/A&gt;&lt;/P&gt;&lt;DIV class="j-rte-table"&gt;&lt;TABLE border="0"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD style="border:0px solid black;"&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lvr.com%2Fforum%2Findex.php%3Ftopic%3D584.msg2028%23msg2028" rel="nofollow" target="_blank"&gt;&lt;IMG alt="" border="0" src="http://www.lvr.com/forum/Themes/default/images/post/xx.gif" /&gt;&lt;/A&gt;&lt;/TD&gt;&lt;TD style="border:0px solid black;"&gt;&lt;DIV&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lvr.com%2Fforum%2Findex.php%3Ftopic%3D584.msg2028%23msg2028" rel="nofollow" target="_blank"&gt;USB mass storage class - answering to SCSI inquiry&lt;/A&gt;&lt;/DIV&gt;&lt;DIV class="smalltext"&gt;« &lt;STRONG&gt;on:&lt;/STRONG&gt; &lt;STRONG&gt;Today&lt;/STRONG&gt; at 01:57:38 am »&lt;/DIV&gt;&lt;/TD&gt;&lt;TD style="border:0px solid black;"&gt;&lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lvr.com%2Fforum%2Findex.php%3Faction%3Dpost%3Bquote%3D2028%3Btopic%3D584.0%3Bnum_replies%3D0%3Bsesc%3D337df4b7dfe88afc5907b7534755aa89" rel="nofollow" target="_blank"&gt;&lt;IMG align="middle" alt="Reply with quote" border="0" src="http://www.lvr.com/forum/Themes/default/images/buttons/quote.gif" /&gt;&lt;STRONG&gt;Quote&lt;/STRONG&gt;&lt;/A&gt; &lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lvr.com%2Fforum%2Findex.php%3Faction%3Dpost%3Bmsg%3D2028%3Btopic%3D584.0%3Bsesc%3D337df4b7dfe88afc5907b7534755aa89" rel="nofollow" target="_blank"&gt;&lt;IMG align="middle" alt="Modify message" border="0" src="http://www.lvr.com/forum/Themes/default/images/buttons/modify.gif" /&gt;&lt;STRONG&gt;Modify&lt;/STRONG&gt;&lt;/A&gt; &lt;A _jive_internal="true" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.lvr.com%2Fforum%2Findex.php%3Faction%3Ddeletemsg%3Btopic%3D584.0%3Bmsg%3D2028%3Bsesc%3D337df4b7dfe88afc5907b7534755aa89" rel="nofollow" target="_blank"&gt;&lt;IMG align="middle" alt="Remove message" border="0" src="http://www.lvr.com/forum/Themes/default/images/buttons/delete.gif" /&gt;&lt;STRONG&gt;Remove&lt;/STRONG&gt;&lt;/A&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;HR /&gt;&lt;DIV class="post"&gt;Hello!&lt;BR /&gt;&lt;BR /&gt;I am trying to implement a mass storage device driver on an mcf5272 processor.&lt;BR /&gt;&lt;BR /&gt;I use the endpoint 2 for bulk input and output, while endpoint 1 is used&lt;BR /&gt;for the HID interface by an example from freescale - motorola.&lt;BR /&gt;Is it possible that endpoint 2 bulk is starved because of endpoint&lt;BR /&gt;1 traffic ?&lt;BR /&gt;&lt;BR /&gt;Currently , the device passes enumeration, and receives the Command Block&lt;BR /&gt;Wrapper CBW on endpoint 2 OUT. I read the CBW: it contains the SCSI Inquiry&lt;BR /&gt;request and an expected length of 36 bytes. The direction bit in the CBW&lt;BR /&gt;message is set to IN.&lt;BR /&gt;&lt;BR /&gt;After the CBW is read, I check the direction in the endpoint 2 status register&lt;BR /&gt;EP2ISR. It says that the endpoint is currently configured in OUT direction.&lt;BR /&gt;&lt;BR /&gt;After this I try 2 approaches:&lt;BR /&gt;1. To wait until there is an interrupt which sets the endpoint 2 to IN&lt;BR /&gt;&amp;nbsp; &amp;nbsp;direction. This seems to be somehow connected with IN EndOfTransfer&lt;BR /&gt;&amp;nbsp; &amp;nbsp;or IN EndOfFrame event.&lt;BR /&gt;&amp;nbsp; &amp;nbsp;However, the IN interrupt for endpoint 2 does not happen,&lt;BR /&gt;&amp;nbsp; &amp;nbsp;altough endpoint 0 changes to IN state many times.&lt;BR /&gt;&lt;BR /&gt;2. To change the direction bit in EP2ISR manually and write the data in the&lt;BR /&gt;&amp;nbsp; &amp;nbsp;endpoint 2 data register EP2DR. The direction does not change however, after&lt;BR /&gt;&amp;nbsp; &amp;nbsp;writing to EP2ISR [DIR]&lt;BR /&gt;&amp;nbsp; &amp;nbsp;I clear the EP2CTL [IN_DONE] after the data is written to the ep2&lt;BR /&gt;&amp;nbsp; &amp;nbsp;data register so the data can be sent to the host.&lt;BR /&gt;&amp;nbsp; &amp;nbsp;[Also I tried to set the EP0CTL [CMD_OVER] bit, to try to ACK&lt;BR /&gt;&amp;nbsp; &amp;nbsp;the CBW command, but this still does not change the direction&lt;BR /&gt;&amp;nbsp; &amp;nbsp;of endpoint 2 to IN. ]&lt;BR /&gt;&lt;BR /&gt;On the output of the USB analyzer it can be seen that the&lt;BR /&gt;OUT transfer of CBW request is completed and ACKed but the IN transfer&lt;BR /&gt;does not happen, altough the data has been written to the FIFO and&lt;BR /&gt;the EP2CFG [IN_DONE] bit has been cleared. On the analyzer it can be seen&lt;BR /&gt;that the host sends IN tokens, but there is no response from the device.&lt;BR /&gt;&lt;BR /&gt;So my question is:&lt;BR /&gt;1. Should I wait for the interrupt that sets endpoint 2 to IN mode&lt;BR /&gt;&amp;nbsp; &amp;nbsp;before trying to write to the data register.&lt;BR /&gt;&lt;BR /&gt;2. Should I manually ACK the host OUT transmission, before the&lt;BR /&gt;&amp;nbsp; &amp;nbsp;IN bytes can be sent.&lt;BR /&gt;&lt;BR /&gt;3. It says in one example that the response to SCSI Inquiry should be&lt;BR /&gt;&amp;nbsp; &amp;nbsp;wrapped inside the Command Status Wrapper of the Mass Storage Class.&lt;BR /&gt;&amp;nbsp; &amp;nbsp;However, the CSW only has 13 Bytes. So I suppose that the SCSI&lt;BR /&gt;&amp;nbsp; &amp;nbsp;response should be sent before sending the CSW and that the CSW message&lt;BR /&gt;&amp;nbsp; &amp;nbsp;should only contain the SCSI request status. Is that correct ?&lt;BR /&gt;&lt;BR /&gt;Thanks for any help.&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Sep 2011 14:09:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/USB-mass-storage-class-answering-to-SCSI-inquiry/m-p/163739#M5438</guid>
      <dc:creator>mickz</dc:creator>
      <dc:date>2011-09-01T14:09:01Z</dc:date>
    </item>
    <item>
      <title>Re: USB mass storage class - answering to SCSI inquiry ?</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/USB-mass-storage-class-answering-to-SCSI-inquiry/m-p/163740#M5439</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Using a dedicated endpoint, one for IN and one for OUT solves this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Sep 2011 21:58:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/USB-mass-storage-class-answering-to-SCSI-inquiry/m-p/163740#M5439</guid>
      <dc:creator>mickz</dc:creator>
      <dc:date>2011-09-01T21:58:50Z</dc:date>
    </item>
  </channel>
</rss>

