You are here

FX3 Video stream + UART comport | Cypress Semiconductor

FX3 Video stream + UART comport

Summary: 3 Replies, Latest post by wu.zhijian_1557526 on 18 Jul 2016 03:21 AM PDT
Verified Answers: 0
Last post
Log in to post new comments.
joel norell's picture
2 posts

I am currently working on my bachelor thesis and i am wondering if you have any examples or tips how you can run a video stream along side a UART communication link. Our goal is to have a video stream coming into the FX3 then out to the host pc and the control channel goes both ways.  

PC -> FX3 -> camera/other device 
camera/other device -> FX3 -> PC

What i understand is that we need to use some sort of composite device to get drivers for both the comport and the video device but im not really sure how? We found fireware with drivers for the two function but they only work by them self.

I'm thankful for all help!

Regards Joel 

mady's picture
Cypress Employee
964 posts


Please find the project attached. UVC along with UART communication has been implemented. Please note that in this project, only after the video has started playing (i.e STREAM_EVENT is received from the host), the UART Communication will be active.

The firmware comes up as two devices in your device manager (i) a UVC Camera (ii) COM Port. In addition to these, you will notice a common "USB Composite Device" under the list of USB Controllers in your device manager.

For the COM Port interface, you can get the driver from here:


-Madhu Sudhan

joel norell's picture
2 posts

Thanks for the reply!

I tried your fireware but it didn't come up as either a UVC Camera or a COM port and the drivers you linked doesn't seem to help(probably doing something wrong on my side),

We found another project where we got a FX3 image device and a COM port but the problem with that is that the UART only loopback from the processor and doesn't sent or receive anything from the external UART pins on the FX3 superspeed explorer kit. 
So now i wonder if you know where i can modify so that it send the UART communication thru the external pins instead.

maybe doing something with this?:
CY_U3P_LPP_SOCKET_UART_CONS,                /**< Outgoing data to UART peer. */ 

I've attached two files:

uvc + uart_proj is the original files

USBVideoClass, is a modified version where we still get a loopback but also managed to transmit but not receive the UART.

Thankful for any help!


I saw now that the second file i attached isnt working now, If you change to following you should be able to find the devices.

/* Create a DMA_AUTO channel between usb producer socket and uart consumer socket */
    dmaCfg.size = size;
    dmaCfg.count = 8;
    dmaCfg.prodSckId = CY_FX_EP_PRODUCER1_SOCKET;
    dmaCfg.consSckId = CY_U3P_LPP_SOCKET_UART_CONS; --> change to CY_FX_EP_CONSUMER1_SOCKET
    dmaCfg.dmaMode = CY_U3P_DMA_MODE_BYTE;
    dmaCfg.notification = 0;
    dmaCfg.cb = NULL;
    dmaCfg.prodHeader = 0;
    dmaCfg.prodFooter = 0;
    dmaCfg.consHeader = 0;
    dmaCfg.prodAvailCount = 0;

/* Create a DMA_MANUAL channel between uart producer socket and usb consumer socket */
    /* Use a smaller buffer size (32 bytes) to ensure that packets get filled in a short time. */
    dmaCfg.size         = size;
    dmaCfg.prodSckId    = CY_U3P_LPP_SOCKET_UART_PROD;
    dmaCfg.consSckId    = CY_FX_EP_CONSUMER2_SOCKET;
    dmaCfg.notification = CY_U3P_DMA_CB_PROD_EVENT; --> Change to CY_FX_EP_PRODUCER2_SOCKET
    dmaCfg.cb           = CyFxUSBUARTDmaCallback;
//    dmaCfg.notification = 0;//CY_U3P_DMA_CB_PROD_EVENT;
//    dmaCfg.cb           = NULL;//CyFxUSBUARTDmaCallback;


Thanks again!

wu.zhijian_1557526's picture
1 post

try close debug uart port

Log in to post new comments.