Cypress Perform

Home > Design Support > Cypress Developer CommunityTM > Cypress Forums > USB Controllers > Error Code 997

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



Error Code 997
Moderator:
RSKV

Post Reply
Follow this topic



Error Code 997

monkeyking posted on 04 Oct 2011 9:31 AM PST
Member
9 Forum Posts

Hi,

I am developing the USB communication between PC and PSoC3. The PSoC3 board I am using is CY8KIT-030, PC OS is Windows 7, development language is C#.  The interface I am using is CyUSB.dll.

When I send the single command from PC to PSoC3, everything is well. The PSoC could receive the command and do the response. But when I sent a serial commands, the PC program died. When I added some delay time (50ms) between the two commands, it was doing well.

I also tried the sample projects downloaded from Cypress. The PSoC projects is "USBFS_Bulk_Wraparound", while the C# project is "CyControlVS2010.csproj". When I click the mouse button with a long time interval, it was doing well, but if I clicked the mouse button very quickly, the same thing happened, and it had a error code 997. Please refer to the attched picture.

By the way, I did not have the administrator privilege on Windows 7. Is it possible the reason?

Thank you.




Re: Error Code 997

aasi posted on 04 Oct 2011 10:48 AM PST
Cypress Employee
1090 Forum Posts

The error code 997 refers I/O pending for the overlapped to http://msdn.microsoft.com/en-us/library/windows/desktop/ms681388(v=vs.85).aspx. PSoC3 has a full-speed USB. You're most probably sending a big transfer and clicking transfer again before the previous one completes.

Regards,

Anand



Re: Error Code 997

monkeyking posted on 04 Oct 2011 10:58 AM PST
Member
9 Forum Posts

Thanks for your reply.

But the bytes I am transfering is just 8 bytes. I think it is not a too big transfer.

Thank you.



Re: Error Code 997

aasi posted on 04 Oct 2011 09:28 PM PST
Cypress Employee
1090 Forum Posts

I see only 64 byte transfers in the screenshot. One other thing I wanted to check is, is there enough buffer on the device side to consume the packet that you sent?

Have you hooked up a CATC to see what is going on in the bus.

Regards,

Anand



Re: Error Code 997

monkeyking posted on 05 Oct 2011 05:57 AM PST
Member
9 Forum Posts

Hi Anand,

Yes,o n that screenshot, it was 64bytes. Actually, when I changed data length to 8bytes, it still got such error code. The buffer size on the device side I used is 64bytes. I am new to develop USB, is CATC a USB analyzer?

 

Thank you.



Re: Error Code 997

aasi posted on 09 Oct 2011 12:40 PM PST
Cypress Employee
1090 Forum Posts

Yes. It is a USB analyzer. What i meant to ask is when you send data does the device have a free buffer to store that data or not?

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: KXP; Secondary Owner: VWA; Sunset Date: 01/01/20