Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob

FX3: USB transfers do not occur even after data is committed to USB socket – KBA231898

FX3: USB transfers do not occur even after data is committed to USB socket – KBA231898

ChaitanyaV_61
Employee
Employee
50 questions asked 25 likes received 25 sign-ins

Version: **

In FX3 SDK 1.3.4, if the DMA channel associated with a USB socket is created before setting up the USB connection using the CyU3PConnectState () API, USB transfers may not occur even after successfully committing the data to the USB socket (CyU3PDmaChannelCommitBuffer () or CyU3PDmaMultiChannelCommitBuffer () API returns CY_U3P_SUCCESS). An example scenario is shown in Figure 1 and Figure 2.

 

Figure 1. UART Debug Prints showing DMA buffers committed to USB Socket

UART Debug Prints showing DMA buffers committed to USB Socket.png

 

Figure 2. USB IN Transfer fails from USB Control Center

USB IN Transfer fails from USB Control Center.png

 

Notes:

  1. Error Code 997 is the timeout error which occurs when FX3 does not have data to transfer to the USB host.
  2. For information on FX3 DMA channel, DMA Buffers and Sockets, see the EZ-USB FX3 Technical Reference Manual.
  3. See AN75705: Getting started with EZ-USB FX3 for information on programming and performing data transfer to FX3 using USB Control Center.

This problem can be due to the known issue listed in the FX3 SDK Release Notes, which mentions that the settings for the DMA channels associated with USB sockets may be invalidated during the USB device mode connection startup.

To avoid this problem, you must reset the DMA channel using CyU3PDmaChannelReset () or CyU3PDma-MultiChannelReset () API and re-enable after each enumeration cycle. This can be done when the CY_U3P_USB_EVENT_SETCONF event occurs, indicating that the USB device has enumerated successfully. You should not use the DMA channel associated with the USB socket before the CY_U3P_USB_EVENT_SETCONF event.

0 Likes
620 Views