8 Replies Latest reply on Jun 11, 2019 11:52 PM by shun.harada_4101246

    1600x1300 resolution for CX3

    shun.harada_4101246

      Does CX3 support 1600x1300 resolution?

      We are going to use OV2311(1600x1300 RAW10), and want to have setting example to support this resolution.

       

      Best Regards,

        • 1. Re: 1600x1300 resolution for CX3
          KandlaguntaR_36

          Hello,

           

          Yes, CX3 support 1600x1300 RAW 10.

           

          Can you please provide the following to get the MIPI configuration parameters?

           

          1. CSI Clock

          2. Number of Lane

          3. THS Prepare

          4. THS Zero

          5. Frame Rate

          6. HActive - 1600

          7. HBlanking

          8.VActive - 1300

          9. VBlanking

          10. data format - RAW10

          • 2. Re: 1600x1300 resolution for CX3
            shun.harada_4101246

            Hello,

             

            Thank you for the response.

            I'm using following parameter.

             

            1. CSI Clock - 400MHz

            2. Number of Lane - 2

            3. THS Prepare - 70

            4. THS Zero - 90

            5. Frame Rate - 15

            6. HActive - 1600

            7. HBlanking -  2016

            8.VActive - 1300

            9. VBlanking - 174

            10. data format - RAW10

             

            When I use above parameter, I got attached weird output image on eCamView.

            I also tested with VLC, AMcap, I got same result.

             

            Looks like somehow blue square image is overwritten to red square area.

            Even if I use color image from image sensor(OV2311), I saw same behavior.

            image1.png

            image2.png

            I also checked OV2311 register setting, but I could see correct image is outputted from OV2311 eva board.

            So looks like OV2311 setting is okay.

             

            Let me know if you have any suggestion to resolve this issue.

            • 3. Re: 1600x1300 resolution for CX3
              KandlaguntaR_36

              Since you are streaming RAW10 video format, the standard UVC host applications cannot stream RAW10 format. You need to customize the host application as needed.

               

              Please refer this KBA - Streaming RAW10 Format Input Data to 16/24-bit Output Format in CX3 MIPI CSI-2 - KBA224387

               

              Please confirm whether you are using the following MIPI configuration parameters;

               

              /* Example_YUY2_Resolution0 :  */

              CyU3PMipicsiCfg_t Example_YUY2_Resolution0 =

              {

                  CY_U3P_CSI_DF_YUV422_8_2,  /* CyU3PMipicsiDataFormat_t dataFormat */

                  2,                          /* uint8_t numDataLanes */

                  2, /* uint8_t pllPrd */

                  123, /* uint16_t pllFbd */

                  CY_U3P_CSI_PLL_FRS_250_500M, /* CyU3PMipicsiPllClkFrs_t pllFrs */

                  CY_U3P_CSI_PLL_CLK_DIV_4, /* CyU3PMipicsiPllClkDiv_t csiRxClkDiv */

                  CY_U3P_CSI_PLL_CLK_DIV_4, /* CyU3PMipicsiPllClkDiv_t parClkDiv */

                  0,                 /* uint16_t mClkCtl */

                  CY_U3P_CSI_PLL_CLK_DIV_2, /* CyU3PMipicsiPllClkDiv_t mClkRefDiv */

                  1600,         /* uint16_t hResolution */

                  50                         /* uint16_t fifoDelay */

              };

               

              Configure the THS Settle value to 11 using CyU3PMipicsiSetPhyTimeDelay API

              • 4. Re: 1600x1300 resolution for CX3
                shun.harada_4101246

                Hello,

                 

                Thanks for your reply.
                Yes, we have host application which converts YUY2 data to RAW10 video format.
                Even if we use that application, we saw this overlay issue.

                 

                1. We updated our firmware to use your proposed Mipicsi setting and added CyU3PMipicsiSetPhyTimeDelay.
                    With this firmware, camera app showed black screen.
                    And dma callback on CX3 tried to send 2,600,000 bytes data(1600 x 1300 x 10/8).

                    Is this expected behavior?

                 

                2. I added following line after CyU3PMipicsiSetIntfParams(). Is this okay?

                    CyU3PMipicsiSetPhyTimeDelay(1, 11);

                 

                3. When I replaced CY_U3P_CSI_DF_YUV422_8_2 to CY_U3P_CSI_DF_RAW10, I could see video stream on camera app,
                    but output image was same as before. Still seeing overwritten image.(dma callback on CX3 sent 4,160,000 bytes 1600x1300x16/8)

                    Do you think this overwritten image issue is caused by setting difference between YUY2 and RAW10?

                 

                Best Regards,

                • 5. Re: 1600x1300 resolution for CX3
                  shun.harada_4101246

                  Hi KandlaguntaR_36,

                   

                  Any update on this?

                  • 6. Re: 1600x1300 resolution for CX3
                    KandlaguntaR_36

                    Answering your queries:

                     

                    Yes, we have host application which converts YUY2 data to RAW10 video format.

                    Even if we use that application, we saw this overlay issue.

                     

                    >> The host application should consider that the USB device is sending the video in RAW10 format and display the same. The standard UVC application considers the received data as YUY2 and does the conversion.

                     

                    1. We updated our firmware to use your proposed Mipicsi setting and added CyU3PMipicsiSetPhyTimeDelay.
                        With this firmware, camera app showed black screen.
                        And dma callback on CX3 tried to send 2,600,000 bytes data(1600 x 1300 x 10/8).

                        Is this expected behavior?

                     

                    >> Yes, this is expected. You are receiving the exact frame size as per 1600x1300x10 bits. The standard UVC host application decodes the received image as per YUY2 format. You need to write your own code to display RAW10 data.

                     

                    2. I added following line after CyU3PMipicsiSetIntfParams(). Is this okay?

                        CyU3PMipicsiSetPhyTimeDelay(1, 11);

                    >> This is okay. Hope you have passed the second arguments of  CyU3PMipicsiSetIntfParams as CyFalse.

                     

                    3. When I replaced CY_U3P_CSI_DF_YUV422_8_2 to CY_U3P_CSI_DF_RAW10, I could see video stream on camera app,
                        but output image was same as before. Still seeing overwritten image.(dma callback on CX3 sent 4,160,000 bytes 1600x1300x16/8)

                     

                    >> Here, you are receiving 16bits per pixel instead 10 bits per pixel. You need to remove the additional 6 bits per pixel and do the display in your custome application. This is same question 1.

                     

                        Do you think this overwritten image issue is caused by setting difference between YUY2 and RAW10?

                    >> It could be due to host application implementation.

                     

                    Please probe the HSYNC, VSYNC and PCLK test pins and check whether the timings are correct. Measure the HACTIVE, VACTIVE and blanking times.

                    • 7. Re: 1600x1300 resolution for CX3
                      shun.harada_4101246

                      Hello,

                       

                      We use our application to display RAW10 and works properly with "OV2311 sensor + FX3".

                      However, when we use CX3, we have this issue.

                      So I think host application implementation is correct. Issue is coming from CX3 side.

                       

                      We also tried to use CY_U3P_CSI_DF_YUV422_8_2, but this overlay issue was still exist.

                      With FX3, we used MIPI clock free running setting, but somehow free running didn't work on CX3(DMA counter is not incremented), so we change sensor setting to Gate clock.

                       

                      We've already checked CX3 Hardware: Frequently Asked Questions - KBA91295  and our sequence is same  as recommended sequence.

                       

                      Do you think this overlay behavior is caused by this clock setting?

                       

                      Best Regards,

                      • 8. Re: 1600x1300 resolution for CX3
                        shun.harada_4101246

                        Hello,

                         

                        The issue occurs if width is bigger than 1360.

                        Let me know if you have any suggestion.

                         

                        <1360x1300>

                         

                        <1376x1300 RAW10>