CX3-UVC device disconnects from Amcap when streaming starts

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

cross mob
lock attach
Attachments are accessible only for community members.
RiBi_4316346
Level 1
Level 1

Hello,

I created a CX3 project to stream video from a MIPI image sensor to a Windows 10 PC using UVC.

The board mounting the sensor and the CX3 is a custom design.

I tried to verify the streaming using Amcap: the streaming works well, but only if I use a USB3.0 hub between the CX3 cable and the USB SS port of the PC.

If I connect directly the CX3 cable to the port there is a strange behaviour: I still can select the CX3-UVC device from the available devices in Amcap, but as soon as I make the sensor start streaming (using a button on the PCB) the streaming in Amcap starts and then fails after a few frames (giving the typical sound of a usb device disconnected).

After this, the CX3-UVC device is not re-enumerated I think, the device is still visible in device manager and in the Amcap available devices: if I select it again in Amcap and repeat the procedure the behaviour is the same as before.

Here is how I obtained the firmware:

I started from a blank project (File->New->Project->Cypress->CX3 Configuration Project), then I modified the cx3config.cycx file according to the sensor video specifications and I generated all the project files.

Then I wrote all the code needed to program our sensor, that is called from the main project file cycx3_uvc.c.

Inside cycx3_uvc.c I didn't change anything from the original file generated using cx3config.cycx.

Can you help me understand what is the issue?

I attach my cycx3_uvc.c file and uart logs obtained in both cases (with and without usb hub) in which I omitted all the initial configuration debug prints.

Thank you,

Riccardo

0 Likes
1 Solution

Hello,

Please try the following:

1. Please download FX3 SDK 1.3.4. This can be downloaded from the following link:

https://www.cypress.com/documentation/software-and-drivers/ez-usb-fx3-software-development-kit

After the SDK installation is complete, import the project into EZ-USB Suite. Then, change the build variable from 1_3_3 to 1_3_4. Now refresh the project and build it again. After this, check if the issue is happening again.

2. As you are using a custom board, please try connecting different boards on the same host and check if the issue is happening on all the boards.

Please try these suggestions. Meanwhile I will look into the USB traces and update the thread with my findings.

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna

View solution in original post

0 Likes
5 Replies
RiBi_4316346
Level 1
Level 1

I forgot to mention that I tried on 3 different PCs and I tried using VLC player instead of Amcap, but the behaviour is the same.

Riccardo

0 Likes

Hello Riccardo,

The CB Failure print in the logs shared occurs because the API CyU3PDmaMultiChannelCommitBuffer() is failing. Please share the following details so that I can debug the issue better.

1. What is the error code when the API CyU3PDmaMultiChannelCommitBuffer() is failing?
2. What was the result when you tested the device on different PCs and host applications?

3. What is the version of FX3 SDK used for building the project? Please confirm this by going to the Project Properties->C/C++ Build->Build Variables of your project.

4. In the UART logs obtained without hub, have you tried to stream the video a second time or stopped after the problem occurred?

5. Also, please share a Wireshark Trace when you use the board without hub. This can be used to understand if the device is getting re-enumerated or not.

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna
0 Likes
lock attach
Attachments are accessible only for community members.

Thank you Jayakrishna,

here are my answers:

1) The error code of the API CyU3PDmaMultiChannelCommitBuffer() is 71

2) On different PCs and host applications (I tested Amcap and VLC ) the result is identical

3) In the path you suggested I read FX3SDKVERSION 1_3_3

4) In the log I shared I stopped after the problem occurred. I attach a new log (log_uart_without_hub_repeat) in which, after the first disconnection, I restarted the stream 3 times

5) Here is a download link to the USB trace obtained with Wireshark:

usb_trace_noHub.pcapng - Box

Thank you,

Riccardo

0 Likes

Hello,

Please try the following:

1. Please download FX3 SDK 1.3.4. This can be downloaded from the following link:

https://www.cypress.com/documentation/software-and-drivers/ez-usb-fx3-software-development-kit

After the SDK installation is complete, import the project into EZ-USB Suite. Then, change the build variable from 1_3_3 to 1_3_4. Now refresh the project and build it again. After this, check if the issue is happening again.

2. As you are using a custom board, please try connecting different boards on the same host and check if the issue is happening on all the boards.

Please try these suggestions. Meanwhile I will look into the USB traces and update the thread with my findings.

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna
0 Likes

Jayakrishna,

I changed the build variable to 1_3_4 as you suggested and built the project again: now the streaming works correctly without hub.

Thank you very much.

Best regards,

RIccardo

0 Likes