Cypress Perform

Home > Design Support > Cypress Developer CommunityTM > Cypress Forums > USB Controllers > Multiple configuration descriptors with FX2

Bookmark and Share
Cypress Developer CommunityTM
Forums | Videos | Blogs | Training | Rewards Program | Community Components



Multiple configuration descriptors with FX2
Moderator:
RSKV

Post Reply
Follow this topic



Multiple configuration descriptors with FX2

andrewsobotka posted on 03 Apr 2012 11:52 AM PST
Top Contributor
40 Forum Posts

I would like to use multiple configuration descriptors.  One of them would have a DirectSound interface (and that interface would not receive data from the Cypress driver), the other would not have that interface and instead the Cypress driver would provide the data that DirectSound would have using the vendor-defined interface.

I have added the extra configuration descriptor (and associated interface/endpoint descriptors) to dscr.a51.  I also modified SetupCommand(void) so that SC_GET_DESCRIPTOR / GD_CONFIGURATION (and GD_OTHER_SPEED_CONFIGURATION) will return the correct descriptors.  I also modified the ISR's Ures and Highspeed so that they correctly handle switching the configuration types from CONFIG_DSCR to OTHERSPEED_DSCR.

If I manully enter the commands for getting the DirectSound descriptor, I get back the correct descriptor.  However, when I send the command for setting the DirectSound descriptor, nothing happens; I don't see a DirectSound device and no data flows to the FX2.

When I look in the CyConsole or the USB Control Center, I can see two configurations, but they're both "configuration 1".  I know that my DirectSound config descriptor is set correctly - recall that get descriptor works fine, and shows configuration 2.

Do I need to disconnect and reconnect from the USB using USBCS in order for the new DirectSound configuration descriptor to be seen?  Why can't the Control Center or Console see the other configuration descriptor?




Re: Multiple configuration descriptors with FX2

Gayathri posted on 05 Apr 2012 11:25 PM PST
Cypress Employee
428 Forum Posts

 Hi,

 

Cy[press Usb device driver, CyUSB.sys, and our libraries currently doesn't support multiple configurations. It supports only one configuration as of now.  

 

Regards,

Gayathri



Re: Multiple configuration descriptors with FX2

andrewsobotka posted on 05 Apr 2012 08:13 AM PST
Top Contributor
40 Forum Posts

Hi Gayathri, thanks for the information.  A quick google suggests that WinUSB also has a one-configuration limitation.

 

Would it be possible to "fake" multiple configurations by doing what amounts to Re-Numeration?  For example, my descriptors will report that I only have one configuration, but my software will know that I secretly have two configurations.  So it will issue a vendor command which would force a disconnect with USBCS |= 0x80; wait three seconds; change which configuration descriptor I report for enumeration; and then reconnect with USBCS &= ~0x80.

 

I think that will accomplish my goal, but I would be interested to hear if you have any other suggestions.



Re: Multiple configuration descriptors with FX2

aasi posted on 06 Apr 2012 01:17 AM PST
Cypress Employee
1090 Forum Posts

Hi Andrew,

When you say two configuration are they both implementing 2 separate classes or are they both vendor specific class. CyUSB.sys will just pass up the descriptor irrespective of what it contains. It comes down to the matter of being able to set configuration (I remember windows low level drivers not letting us do that). I'll check on that and get back to you.

Regards,

Anand






ALL CONTENT AND MATERIALS ON THIS SITE ARE PROVIDED "AS IS". CYPRESS SEMICONDUCTOR AND ITS RESPECTIVE SUPPLIERS MAKE NO REPRESENTATIONS ABOUT THE SUITABILITY OF THESE MATERIALS FOR ANY PURPOSE AND DISCLAIM ALL WARRANTIES AND CONDITIONS WITH REGARD TO THESE MATERIALS, INCLUDING BUT NOT LIMITED TO, ALL IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT OF ANY THIRD PARTY INTELLECTUAL PROPERTY RIGHT. NO LICENSE, EITHER EXPRESS OR IMPLIED, BY ESTOPPEL OR OTHERWISE, IS GRANTED BY CYPRESS SEMICONDUCTOR. USE OF THE INFORMATION ON THIS SITE MAY REQUIRE A LICENSE FROM A THIRD PARTY, OR A LICENSE FROM CYPRESS SEMICONDUCTOR.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms and Conditions of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms and Conditions of this site. Cypress Semiconductor and its suppliers reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Spec No: None; Sunset Owner: GRAA; Secondary Owner: RAIK; Sunset Date: 01/01/20