Cypress Perform

Home > Design Support > Cypress Developer CommunityTM > Cypress Forums > USB Controllers > How to detect USB unconfigured state

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



How to detect USB unconfigured state
Moderator:
RSKV

Post Reply
Follow this topic



How to detect USB unconfigured state

dadeur posted on 13 Dec 2011 6:01 AM PST
Member
7 Forum Posts

Hello all,

I'm working with a fx2lp and i've to detect the "USB unconfigured" state in order to reduce to <100mA the power requirement (as for USB-IF compliance).

I believed that the solution was to look at configuration index = 0 after SetConfiguration but it doesn't work...

Any idea?

 

Thanks a lot!

DaX




Re: How to detect USB unconfigured state

Chris R. posted on 13 Dec 2011 06:20 AM PST
Top Contributor
135 Forum Posts

In my FX2 firmware I activate the high power hardware on SetConfiguration event and in TD_Resume() function. And switch off the hardware on firmware start and on USB Sleep command. It works fine.



Re: How to detect USB unconfigured state

dadeur posted on 13 Dec 2011 07:59 AM PST
Member
7 Forum Posts
Chris R. posted on 13 Dec 2011 06:20 AM PST
Top Contributor
57 Forum Posts
 
 

In my FX2 firmware I activate the high power hardware on SetConfiguration event and in TD_Resume() function. And switch off the hardware on firmware start and on USB Sleep command. It works fine.

 

Hi Chris, thanks for your reply.

But you, in SetConfiguration event, explicitly check for condition index != (not equal) 0 to enable power?

Because, as far as understand, if host set configuration 0 means "unconfigure device" so power must be <100mA.

 

Regards,

DaX



Re: How to detect USB unconfigured state

Chris R. posted on 14 Dec 2011 11:52 PM PST
Top Contributor
135 Forum Posts

No, I don´t check this explicitely. Connecting the device on a bus-powered hub the set configuration event don´t appear and so I don´t switch on the high power part. Also on Windows boot the set configuration and sleep states are altered some times, and while installing the driver also the set configuration will appear only after complet install and enough power from hub/host. i think this is OK, but I did not perform compliance tests. Maybe the spec is not completely covered by our firmware.






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