Cypress Perform

Home > Design Support > Cypress Developer CommunityTM > Cypress Forums > USB Controllers > Call CyU3PUsbGetEP0Data function error

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



Call CyU3PUsbGetEP0Data function error
Moderator:
RSKV

Post Reply
Follow this topic



Call CyU3PUsbGetEP0Data function error

CypressFans posted on 07 May 2012 5:35 AM PST
Member
3 Forum Posts
A strange problem , i transfer data to EP0 with CyControl, when CyU3PUsbSendEP0Data is successfull, but CyU3PUsbGetEP0Data is failed, only receive, not transer, why? code: switch (rqt) { case 0xB0: status=CyU3PUsbSendEP0Data (8, (uint8_t *)glEp0Buffer); break; case 0xB1: status=CyU3PUsbGetEP0Data (glEp0BufferLenght,glEp0Buffer,NULL); break;


Re: Call CyU3PUsbGetEP0Data function error

sodafarl posted on 07 May 2012 07:15 AM PST
Top Contributor
128 Forum Posts

The data buffer has to be a mutiple of 16 bytes, the function will then return the actual number of bytes sent by the host. See the FX3APIGUIDE for more details. In your example what is the buffer length?

Sodafarl



Re: Call CyU3PUsbGetEP0Data function error

capiman posted on 07 May 2012 07:31 AM PST
Senior Member
18 Forum Posts

What error value do you get in FX3 (not on PC side) in case of the error?



Re: Call CyU3PUsbGetEP0Data function error

sodafarl posted on 07 May 2012 08:29 AM PST
Top Contributor
128 Forum Posts

I think it would be CY_U3P_ERROR_BAD_ARGUMENT.



Re: Call CyU3PUsbGetEP0Data function error

CypressFans posted on 07 May 2012 06:57 PM PST
Member
3 Forum Posts
I am a Chinese,visit the website of the cypress is very slow,buffer size is 4096 byte




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.