I would like to set up the slave fifo FLAGB so that it shows "almost full". You mentioned that we have to use CyU3PGpifSocketConfigure() function. I have some questions regarding this function and its application:
1. In the summary of the function, it mentioned that
"This function allows the user to select and configure the active socket in the case
where software is responsible for these actions. The API will respond with an error
if the hardware is taking care of socket configurations."
What does it mean "software" or "hardware"?
2. What number should I write for watermark if I want to support both USB2.0 and USB3.0. In other words, should I write 511 or 1023 to make the flag works as "Almost Full"?
3. What I should write instead of the burst? I would appreciate it if you could be specific and refer me to a number which I can find in the slave fifo project (*.c or *.h file).
2. The watermark value is the difference to full. So you can set up the watermark to 2 samples for example, and the flag goes active 2 samples before the fifo is full, regardless of the fifo size. So you dont have to switch between 2.0 and 3.0
Did you also modified the gpif descriptor to use the flag output as partial flag? For fully correct flag use you have to use both, the full flag and the partial full flag. Using only partial full shows not the real full status if you are transferring short packets and the DMA buffers are full. So you have to monitor both flags for reliable full flag under all conditions.