cancel
Showing results for 
Search instead for 
Did you mean: 

USB Superspeed Peripherals

New Contributor II

Hi and thanks for this amazing community I have learned so much already.

Recently our company got interested in the CX3 MIPI to USB bridge and we are testing one for our system. The Denebola RDK is the one we went with.  The issue is the camera that comes with it does not meet our requirements as we need a much better Sony CSI-2 Sensor.

So my question is how hard is it to interface your own camera with the CX3?

I am a bit confused because the Application note AN90369 states that this is what I need to adjust manually in the code:

"For other sensors the cyu3imagesnesors.c needs to be changed with the few helper functions.

Image sensor is configured using CX3's I2C interface the following functions SensorWrite2B, SensorWrite, SensorRead2B and SensorRead can be used to write and read image sensor configurations.

  • The Write functions call CyU3PI2cTransmitBytes standard API to write data to the sensor.
  • The Read functions call CyU3PI2cRecieveBytes standard API to read data from the sensor. "

BUT, I can see that the FX3 SDK allows Low-level control of image sensor using the CX3 configuration tool shown here: CX3 Firmware: Frequently Asked Questions - KBA91297​​ So I do not understand which one is the correct approach for configuration of a separate image sensor.

Finally, regarding the MIPI CSI2 inputs from the image sensor (image attached)? Is this something we find from the register map of the sensor it self and if so how does one get this register map? From what I understand it is not so easy to get these parameters due to NDA etc. Am I right?

0 Likes
Reply
1 Solution
Moderator
Moderator

Hello,

Please refer to the following KBA which documents the steps to setup a MIPI CSI Camera Solution with CX3.

Steps to Setup up MIPI CSI Camera Solution with CX3 – KBA225748

Generally for setting up a MIPI CSI Camera using CX3, you need to configure the MIPI receiver on CX3 and the image sensor which is basically the MIPI transmitter. For configuring the image sensor, the sensor configuration settings are to be written from CX3 to the image sensor over I2C. The sensor configuration settings are obtained from the image sensor vendor and may require you to sign an NDA.

Once the sensor configuration settings for a particular resolution, pixel depth, frame rate etc are obtained from the sensor vendor, you can configure the CX3 MIPI Receiver by following the steps in the KBA mentioned above.

Please note that the streaming will work properly only if the sensor configuration settings and CX3 receiver configurations match properly.

Please let me know if you have any queries on this.

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna

View solution in original post

3 Replies
Moderator
Moderator

Hello,

Please refer to the following KBA which documents the steps to setup a MIPI CSI Camera Solution with CX3.

Steps to Setup up MIPI CSI Camera Solution with CX3 – KBA225748

Generally for setting up a MIPI CSI Camera using CX3, you need to configure the MIPI receiver on CX3 and the image sensor which is basically the MIPI transmitter. For configuring the image sensor, the sensor configuration settings are to be written from CX3 to the image sensor over I2C. The sensor configuration settings are obtained from the image sensor vendor and may require you to sign an NDA.

Once the sensor configuration settings for a particular resolution, pixel depth, frame rate etc are obtained from the sensor vendor, you can configure the CX3 MIPI Receiver by following the steps in the KBA mentioned above.

Please note that the streaming will work properly only if the sensor configuration settings and CX3 receiver configurations match properly.

Please let me know if you have any queries on this.

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna

View solution in original post

New Contributor II

Hi JayakrishnaT_76,

Thanks a lot for the response. The guide you put helps a lot. Regarding the camera configuration settings I managed to get it from the sensor vendor. That said I am still unsure about the following points and would appreciate your help:

1) Will the steps shown in KBA225748 be all I need to set up my sensor with CX3? From my understanding those parameters are only the physical parameters of the sensor itself. What If I want to set exposure or shutter speed and other parameters. Given that the Sensor we are interested in does not have a ISP in it we need to do these commands over I2C correct? Therefore we need the register map of the sensor itself to know where to read from and write to.
To perform these I2C writes and reads we adjust the  helper functions from cyu3imagesnesors.c
and flash the code again Right?

According to AN90369  "Image sensor is configured using CX3's I2C interface the following functions SensorWrite2B, SensorWrite, SensorRead2B and SensorRead"

Is there a way to set these settings on the fly for the cameras?

2) Will the CX3 chip allow for multiple camera (4 cameras) setups with a different sensor? Given that we have 4 MIPI lanes in CX3 am I right to say we can have up to 4 CSI-2 Sensor connections? note we only want images from these 4 sensors and not video streams

3) Given this multi camera set up is there a way to trigger all these sensors synchronously ? I read in the data sheets that you can use GPIOs to trigger the cameras with an external synchronous event. Do you by any chance have a resource for how to do this ?

Thanks A lot this community rocks!

Cheers
Ali

0 Likes
Reply
Moderator
Moderator

Hello,

Please find my comments for your questions below:

1. According to my understanding, your application is UVC compliant. A UVC device reports its capabilities to the host using the descriptors. A UVC device has a Video streaming interface and Video Control interface. In the Video Control Interface, the device can report that it supports different controls (brightness,contrast etc). When the host enumerates the device, it can understand the supported control features  and the details by sending appropriate requests. After discovering the supported capabilities, the host can issue appropriate request to change the values of these controls (brightness, contrast etc). Once this request is received by CX3, it need to configure the sensor by writing into the appropriate registers. The firmware need to be modified for this. Please refer to section 2.3.2 of AN75779 to understand more about handling UVC requests. The link to the same is given below:

https://www.cypress.com/file/123506/download

You can also refer to the following thread which discusses brightness control with CX3:

Brightness control with KBA225062

2. For supporting multiple image sensors, we need an ISP or an FPGA between CX3 and the sensors and the FPGA/ISP is to be configured in such a way that it connects one sensor with CX3 at a time. Please refer to the question 6 of the KBA whose link is given below:

CX3 Hardware: Frequently Asked Questions - KBA91295

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna