You are here

Control Endpoint Usage for settings etc? | Cypress Semiconductor

Control Endpoint Usage for settings etc?

Summary: 2 Replies, Latest post by AidenM on 29 Dec 2013 08:21 AM PST
Verified Answers: 0
Last post
Log in to post new comments.
AidenM's picture
9 posts

 Hi there,

On the advice of a user here  I have been advised to use the control endpoint to send settings messages to the FX3 controller.  The concept is simple enough, I want to send different types of messages, have the control endpoint on the FX3 copy them into an appropriate buffer and raise a flag.

1)Ideally I would like to be able to test this in the USB Control Centre, which I hope is possible using the 'Data Transfers' tab?

2) How do I register the control endpoint handler in firmware?  Right now I am trying to work with SlaveFifoAsync since I eventually need to stream data from the board to the PC.

3) If anyone could throw together a simple example of how to say send a 512 byte buffer to the control endpoint, and how to catch it there, I would be very appreciative.

I'm sorry to ask such a basic question, but scanning this forum for the first 100 instances of the word 'control' didn't yield anything conclusive.  If there is an application note that covers this, please let me know.

mady's picture
Cypress Employee
963 posts

 Hi AidenM,

Our example firmwares in SDK demonstrate how to handle the requests sent over the control end point.

Please refer to the BulkLoppAuto Example in our example firmware.

In that the function CyFxSlFifoApplnUSBSetupCB() is used to handle the vendor requests from the PC that is send to the control endpoint.

You can use the data transfers tab in the control center to send this vendor request.

In this case, the request 0x0E is passed in the data transfers tab, and this command is used to reset the device. The handling of 0xE0 is demonstrated in that function.

After downloading the firmware into FX3, select the Control Endpoint in the control center and go to the data transfers Tab.

Enter the values as shown in the attached screnshot and click 'Transfer data'

Now you will see that the device is resettted.



AidenM's picture
9 posts

 Hi there,


Thanks for your input.  I have found the function you are referring to in SlaveFifoAsync but when I try to send the command shown in your attached image I receive an error 997.


I tried both 0xE0 and 0x0E since you showed the former in the image but mentioned both in the post text, but both returned an error 997.


Putting this error code aside for the moment, I see there is a 'bytes to transfer' field.  Does this mean we can send a data packet along with a control message? Is there an example where data is sent along with a control endpoint transfer?


Thanks again.

Log in to post new comments.