BULk out data and UART in control center at the same time

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

cross mob
E_521156
Level 4
Level 4
100 sign-ins 50 replies posted 50 sign-ins


Hi,
I am sending stream data from the bulk endpoint to GPIF(BULK OUT). At the same time, I am sending/receiving data through UART (register mode) by Teraterm to FX3. Now I need to use Control Center(CC) to see whatever I got from Teraterm(stream data) or use CC to send TX data to Teraterm. I mean I want to change the firmware and maybe Visual C project somehow that Bulk OUT and UART traffic be able to send concurrently at the same time and can be accessible by Control Center. 

I am doing some research to find a good way to transfer UART data to CC without any corruption on Bulk out data and vise versa. Based on KBA92475(of course, it is for BULH IN), Bulk transfers are found to corrupt control endpoint data, causing errors in the control pipe.

So my question is that is there any suggestion for this goal? which kind of endpoints would be more reliable and helpful to transfer from/to UART to CC to avoid any corruption when I am using BULK out endpoint at the same time? Is there any example to help me on that?

Thanks

0 Likes
1 Solution
Rashi_Vatsa
Moderator
Moderator
Moderator
5 likes given 500 solutions authored 1000 replies posted

Hello Elham,

From the description I understand that you need to send data from  USB to UART (BULK OUT) and also from UART to USB (BULK IN).

You can refer to UsbUart example of the SDK. Please note that the example  implementation adheres to the
CDC-ACM class and allows data communication from USB through to the UART port on the FX3 device. You would need to change the USB descriptors to Vendor Class descriptors so that the device can be accessed from Control Center.

 Based on KBA92475(of course, it is for BULH IN), Bulk transfers are found to corrupt control endpoint data, causing errors in the control pipe.

>> The issue mentioned in this KBA is only for USB 2.0 and is resolved in SDK 1.3.4

So my question is that is there any suggestion for this goal? which kind of endpoints would be more reliable and helpful to transfer from/to UART to CC to avoid any corruption when I am using BULK out endpoint at the same time?

>> You can use BULK endpoints as used in the USB UART example of the SDK

Regards,
Rashi

View solution in original post

0 Likes
3 Replies
Rashi_Vatsa
Moderator
Moderator
Moderator
5 likes given 500 solutions authored 1000 replies posted

Hello Elham,

From the description I understand that you need to send data from  USB to UART (BULK OUT) and also from UART to USB (BULK IN).

You can refer to UsbUart example of the SDK. Please note that the example  implementation adheres to the
CDC-ACM class and allows data communication from USB through to the UART port on the FX3 device. You would need to change the USB descriptors to Vendor Class descriptors so that the device can be accessed from Control Center.

 Based on KBA92475(of course, it is for BULH IN), Bulk transfers are found to corrupt control endpoint data, causing errors in the control pipe.

>> The issue mentioned in this KBA is only for USB 2.0 and is resolved in SDK 1.3.4

So my question is that is there any suggestion for this goal? which kind of endpoints would be more reliable and helpful to transfer from/to UART to CC to avoid any corruption when I am using BULK out endpoint at the same time?

>> You can use BULK endpoints as used in the USB UART example of the SDK

Regards,
Rashi
0 Likes

Hi, 
I replaced the CDC data interface with vendor and the same endpoints, but I couldn't see any thing in Control center. should I do any other changes?

/* Interface descriptor */
0x09, /* Descriptor size */
CY_U3P_USB_INTRFC_DESCR, /* Interface Descriptor type */
0x01, /* Interface number */
0x00, /* Alternate setting number */
0x02, /* Number of end points */
0xFF, /* Interface class */
0x00, /* Interface sub class */
0x00, /* Interface protocol code */
0x00, /* Interface descriptor string index */

-Can we have data in USB and CC at the same time(both CDC and vendor descriptors )? 
For uartlpregmode and uartlpdmamode, can we add these descriptors?

0 Likes
Rashi_Vatsa
Moderator
Moderator
Moderator
5 likes given 500 solutions authored 1000 replies posted

Hello Elham,

Please let me know the VID and PID used in the USB descriptors. You can use the VID and PID of the bulksrcsink firmware or share the USB descriptors file for me to check.

Can we have data in USB and CC at the same time(both CDC and vendor descriptors )? 
For uartlpregmode and uartlpdmamode, can we add these descriptors?

>> Yes, both the interface can be added. You can refer to this KBA Adding Communication Device Class Interface to FX3... - Cypress Developer Community  for the changes needed for adding CDC interface to FX3 vendor class firmware. To send the same data to both the interface i.e. CDC and vendor interface, we would need two DMA channels associated to single interface. 

Regards,
Rashi
0 Likes