This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TDA3XEVM: Same sensor (OV10640), different camera module

Part Number: TDA3XEVM

Hi,

I know the OV10640 sensor works with the TDA3x because I have a D3 camera (https://d3engineering.com/store/product/designcore-rcm-ov10640-rugged-camera-module/).

Now, can I use any other camera with a OV10640 sensor (with FAKRA connector)? If not, is there a simple modification needed (like setting an address only)?

Any input is much appreciated,

Thanks,

Morgan,

  • Hi Morgan,

    I have forwarded your question to ISS experts.

    Regards,
    Yordan
  • Hi Morgan,

    Which serializer you are planning to use?
    Please note that it is not just the sensor/serializer. we need to make sure it matches at signalling/electrical level also. Please check with your local TI FAE to help you in this case.

    Regards,
    Brijesh
  • Hi Brijesh,

    It is a FDP-Link III SerDes but I don't know the ref. And the other camera has a FAKRA connector also.
    In the other camera docs, I can read the following for putting it in "active" state (streaming video):
    • Send 0x60 (I2C device address)
    • Send 0x3012 (Register address)
    • Send 0x01 (Setting the LSB in this register to 1 will start streaming from the camera)

    And then, it is mentioned that for further configuration, I should check on OV10640 datasheet and SCCB specifications. Perhaps, I can make it work by modifying the "start" sensor section only (with addresses and value specified previously), can't I? The code might be located at (VISION_SDK/ti_components/drivers/pdk_01_08_00_16/packages/ti/drv/vps/src/devices/ov10640) but I am not sure what to modify...

    Thank you,

    Best regards,

    Morgan,
  • hi Morgan,

    Yes, you could modify the i2c address in the start function. 

    But please note that sensor address is aliased in the deserializer, so you might just want to keep alias address same and change the sensor address in the deserializer configuration.

    Rgds,

    Brijesh

  • Hi Brijesh,

    Thanks for this input. However, I am not sure what you mean by "change the sensor address in the deserializer configuration". Could you please provide me more information on the location of the variable to modify. I am not sure, but you may be able to confirm, that I should change the UB960_SLAVE_ADDR value in ti_components/drivers/pdk_01_08_00_16/packages/ti/drv/vps/examples/bsputils_ub960.h.

    If it helps, I use the following setting: Capture Source : Sensor OV10640 IMI 1280x720 @ 30fps - ISS CSI2, Bayer (TDA3x EVM ONLY). And my usecase is taken from ISS usecase: Stereo capture + ISS ISP + Auto Calibration

    And will the sensor address modification be enough to make it work, considering the previous statement for setting 0x01 at the register address 0x3012?

    I would gladly take any document on I2C communications in TDA in order to understand better what I should do, if you have any.

    Cheers,

    Morgan,

  • Morgan,

    Which deserializer that you are using?
    Also which VSDK usecase that you are using?

    The UB960 and UB914 settings are in the file ti_components\drivers\pdk_01_08_01_00\packages\ti\drv\vps\examples\utility\src\bsputils_ub960.c

    As you can see in this file, there are ub960/914 configuration arrays which configures sensor address and their alias. for example, register 0x5D is for sensor actual address and register 0x65 is for sensor alias address.
    If you have change in the sensor actual i2c address, you will need to change the value in the register 0x5D.
    Similarly there are registers where you can specify serializer's i2c address and its alias. Please go through this file.

    Once this file is changed correctly for your new OV10640 based camera board, there should be no other change required in sw.

    Regards,
    Brijesh
  • Brijesh,

    Thanks again for your inputs, it is very much appreciated.

    The usecase is the ISS usecase: Stereo capture + ISS ISP + Auto Calibration.

    And during the start, the TDA output (serial link) is "Detected 964 v3 DeSerializer". I guess it is this deserializer I am using...

    I will try to modify the value of the register 0x5D to 0x60 then. I will tell you if that works.

    Cheers,

    Morgan,
  • Brijesh,

    Well, I struggle to make it work... I don't really understand why there are aliases also... I have tried the following:

    • Replace the values of register 0x5D in gUb960Cfg_IMI by 0x60... Four lines replaced "{0x5D, 0x60, 0x0}". This outputs the following (when running the usecase)

    src/bsp_deviceI2c.c @ Line 580:
    [IPU1-0]      8.746355 s:  I2C0: DEV 0x74: WR 0x03 = 0xc5 ... ERROR !!!
    [IPU1-0]      8.746446 s: src/bsp_deviceI2c.c @ Line 602:
    [IPU1-0]      8.746538 s:  I2C0: Error timeout 0 ms!!!
    [IPU1-0]      8.746599 s: src/bsputils_ub960.c @ Line 1133:
    [IPU1-0]      8.746690 s: Could not configure UB913 Ser !!!
    [IPU1-0]      8.747239 s: src/bsp_deviceI2c.c @ Line 667:
    [IPU1-0]      8.747331 s:  I2C0: DEV 0x40: ERROR !!!
    [IPU1-0]      8.747422 s: src/bsp_deviceI2c.c @ Line 689:
    [IPU1-0]      8.747514 s:  I2C0: Error timeout 0 ms!!!
    [IPU1-0]      8.747544 s:  Assertion @ Line: 324 in /usr/local/VISION_SDK_03_01_00_00/vision_sdk/apps/src/rtos/iss/src/common/app_util_iss.c: 0 == status : failed !!!

    • Replaced the previous four values (0x60) and the sensor alias address in the file (vision_sdk/apps/src/rtos/iss/src/sensor/iss_sensor_tda3xx.c) from "{0x40, 0x42, 0x44, 0x46}" to "{0x60, 0x62, 0x64, 0x66}" (0x60 for i2c address of sensor... and I reproduced a similar pattern for the other values)  as the previous error mentions a 0x40 and I could track down the i2cAddress in files to these values. When I run the usecase, it does not crash (well... display some of the same errors but without assertion), run the main loop (ask some options), and I am able to exit properly but I have no display on hdmi output...

    I am a bit confused with all these settings when all information given by my new camera documentation is:

    • Send 0x60 (I2C device address)
    • Send 0x3012 (Register address)
    • Send 0x01 (Setting the LSB in this register to 1 will start streaming from the camera)

    Thus, I don't have any idea of the serializer parameters of the camera. As for the TDA serializer, I guess I should not change a thing except for giving him the i2c address of my new camera.

    I hope you have some clues about my issue...

    Thanks for the support,

    Morgan,

  • I modified the i2c address only but it is still crashing. I replaced the values of register 0x5D in gUb960Cfg_IMI by 0x60... Four lines replaced for the following "{0x5D, 0x60, 0x0}"
  • Hi Morgan,

    From the log, it looks like it is not able to communicate the serializer even. It looks like it is not even locking to the input serializer. Can you lock bit in the ub960 deserializer and see if it is locked..

    Regards,
    Brijesh
  • Are you seeing crash or assertion??

    Regards,
    Brijesh
  • I have the following outputs, given different modifications:

    • Test with new camera and no modification:

    [IPU1-0]     12.161288 s:  Detected 964 v3 DeSerializer                        

    [IPU1-0]     12.172238 s: src/bsp_deviceI2c.c @ Line 580:                      

    [IPU1-0]     12.172360 s:  I2C0: DEV 0x74: WR 0x03 = 0xc5 ... ERROR !!!        

    [IPU1-0]     12.172451 s: src/bsp_deviceI2c.c @ Line 602:                      

    [IPU1-0]     12.172512 s:  I2C0: Error timeout 1 ms!!!                          

    [IPU1-0]     12.172604 s: src/bsputils_ub960.c @ Line 1133:                    

    [IPU1-0]     12.172665 s: Could not configure UB913 Ser !!!                    

    [IPU1-0]     12.173244 s: src/bsp_deviceI2c.c @ Line 667:                      

    [IPU1-0]     12.173305 s:  I2C0: DEV 0x40: ERROR !!!                            

    [IPU1-0]     12.173397 s: src/bsp_deviceI2c.c @ Line 689:                      

    [IPU1-0]     12.173488 s:  I2C0: Error timeout 1 ms!!!                          

    [IPU1-0]     12.173549 s:  Assertion @ Line: 326 in /usr/local/VISION_SDK_03_01!

    => Observation: Crash

    • Test with working camera:

    [IPU1-0]     12.657140 s:  Detected 964 v3 DeSerializer

    [IPU1-0]     13.291801 s:  #### Sensor Config time = 964 msec ####

    => Observation: Run properly

    • Test with working camera and i2c address modification in bsputils_ub960.c ( variable (BspUtils_Ub960I2cParams) gUb960Cfg_IMI, modified line: from {0x5D, 0xBA, 0x00} to {0x5D, 0x60, 0x00} ):

    [IPU1-0]     28.473372 s:  Detected 964 v3 DeSerializer

    [IPU1-0]     28.484414 s: src/bsp_deviceI2c.c @ Line 580:

    [IPU1-0]     28.484536 s:  I2C0: DEV 0x74: WR 0x03 = 0xc5 ... ERROR !!!

    [IPU1-0]     28.484627 s: src/bsp_deviceI2c.c @ Line 602:

    [IPU1-0]     28.484688 s:  I2C0: Error timeout 0 ms!!!

    [IPU1-0]     28.484780 s: src/bsputils_ub960.c @ Line 1133:

    [IPU1-0]     28.484841 s: Could not configure UB913 Ser !!!

    [IPU1-0]     29.466144 s: src/bsp_deviceI2c.c @ Line 580:

    [IPU1-0]     29.466266 s:  I2C0: DEV 0x74: WR 0x0d = 0x9d ... ERROR !!!

    [IPU1-0]     29.466357 s: src/bsp_deviceI2c.c @ Line 602:

    [IPU1-0]     29.466418 s:  I2C0: Error timeout 1 ms!!!

    [IPU1-0]     29.466510 s: src/bsputils_ub960.c @ Line 1869:

    [IPU1-0]     29.466571 s: Could not configure UB913 Ser !!!

    [IPU1-0]     29.466632 s:  #### Sensor Config time = 1323 msec ####

    => Observation: Run properly

    • Test with new camera and i2c addresss modification in bsputils_ub960.c ( variable (BspUtils_Ub960I2cParams) gUb960Cfg_IMI, modified line: from {0x5D, 0xBA, 0x00} to {0x5D, 0x60, 0x00} ):

    [IPU1-0]     21.668974 s:  Detected 964 v3 DeSerializer

    [IPU1-0]     21.679954 s: src/bsp_deviceI2c.c @ Line 580:

    [IPU1-0]     21.680046 s:  I2C0: DEV 0x74: WR 0x03 = 0xc5 ... ERROR !!!

    [IPU1-0]     21.680168 s: src/bsp_deviceI2c.c @ Line 602:

    [IPU1-0]     21.680229 s:  I2C0: Error timeout 1 ms!!!

    [IPU1-0]     21.680320 s: src/bsputils_ub960.c @ Line 1133:

    [IPU1-0]     21.680381 s: Could not configure UB913 Ser !!!

    [IPU1-0]     21.680961 s: src/bsp_deviceI2c.c @ Line 667:

    [IPU1-0]     21.681022 s:  I2C0: DEV 0x40: ERROR !!!

    [IPU1-0]     21.681113 s: src/bsp_deviceI2c.c @ Line 689:

    [IPU1-0]     21.681174 s:  I2C0: Error timeout 1 ms!!!

    [IPU1-0]     21.681235 s:  Assertion @ Line: 326 in /usr/local/VISION_SDK_03_01_00_00/vision_sdk/apps/src/rtos/iss/src/common/app_util_iss.c: 0 == status : failed !!!

    => Observation: Crash

    • Test with new camera and i2c address modification in bsputils_ub960.c ( variable (BspUtils_Ub960I2cParams) gUb960Cfg_IMI, modified line: from {0x5D, 0xBA, 0x00} to {0x5D, 0x60, 0x00} ) + sensor alias in iss_sensor_tda3xx.c ( variable (ChainsCommon_SensorIntfInfo) gSensorInterfaceInfo, modified line for SENSOR_OMNIVISION_OV10640_IMI: from {0x40, 0x42, 0x44, 0x46} to {0x60, 0x62, 0x64, 0x66}):

    [IPU1-0]      8.684285 s:  Detected 964 v3 DeSerializer

    [IPU1-0]      8.695296 s: src/bsp_deviceI2c.c @ Line 580:

    [IPU1-0]      8.695418 s:  I2C0: DEV 0x74: WR 0x03 = 0xc5 ... ERROR !!!

    [IPU1-0]      8.695510 s: src/bsp_deviceI2c.c @ Line 602:

    [IPU1-0]      8.695571 s:  I2C0: Error timeout 0 ms!!!

    [IPU1-0]      8.695662 s: src/bsputils_ub960.c @ Line 1133:

    [IPU1-0]      8.695723 s: Could not configure UB913 Ser !!!

    [IPU1-0]      8.701152 s: src/bsp_deviceI2c.c @ Line 580:

    [IPU1-0]      8.701244 s:  I2C0: DEV 0x74: WR 0x0d = 0x9d ... ERROR !!!

    [IPU1-0]      8.701335 s: src/bsp_deviceI2c.c @ Line 602:

    [IPU1-0]      8.701427 s:  I2C0: Error timeout 1 ms!!!

    [IPU1-0]      8.701488 s: src/bsputils_ub960.c @ Line 1869:

    [IPU1-0]      8.701549 s: Could not configure UB913 Ser !!!

    [IPU1-0]      8.701640 s:  #### Sensor Config time = 347 msec ####

    => Observation: Run without displaying output (black screen), output of performance for issCapture link:

    [IPU1-0]    313.383974 s:  ### CPU [IPU1-0], LinkID [ 77],

    [IPU1-0]    313.384035 s:  

    [IPU1-0]    313.384096 s:  [ ISSCAPTURE ] Link Statistics,

    [IPU1-0]    313.384157 s:  ******************************

    [IPU1-0]    313.384218 s:  

    [IPU1-0]    313.384249 s:  Elapsed time       = 3044 msec

    [IPU1-0]    313.384310 s:  

    [IPU1-0]    313.384340 s:  

    [IPU1-0]    313.384371 s:  Input Statistics,

    [IPU1-0]    313.384432 s:  

    [IPU1-0]    313.384462 s:  CH | In Recv | In Drop | In User Drop | In Process

    [IPU1-0]    313.384554 s:     | FPS     | FPS     | FPS          | FPS        

    [IPU1-0]    313.384615 s:  --------------------------------------------------

    [IPU1-0]    313.384676 s:  

    [IPU1-0]    313.384737 s:  Output Statistics,

    [IPU1-0]    313.384889 s:  

    [IPU1-0]    313.384950 s:  CH | Out | Out     | Out Drop | Out User Drop

    [IPU1-0]    313.385011 s:     | ID  | FPS     | FPS      | FPS          

    [IPU1-0]    313.385072 s:  ---------------------------------------------

    [IPU1-0]    313.385164 s:  

    [IPU1-0]    313.385194 s:  [ ISSCAPTURE ] LATENCY,

    [IPU1-0]    313.385255 s:  ********************

    [IPU1-0]    313.385286 s:  

  • Brijesh,

    I don't know how to "lock bit in the ub960 deserializer and see if it is locked". But, I am not sure if these errors are meaningful because when I modify the value of 0x5D to 0x60, and put the former camera module (OV10640), it outputs the following but the usecase runs properly and display my video output :
    [IPU1-0] 28.473372 s: Detected 964 v3 DeSerializer
    [IPU1-0] 28.484414 s: src/bsp_deviceI2c.c @ Line 580:
    [IPU1-0] 28.484536 s: I2C0: DEV 0x74: WR 0x03 = 0xc5 ... ERROR !!!
    [IPU1-0] 28.484627 s: src/bsp_deviceI2c.c @ Line 602:
    [IPU1-0] 28.484688 s: I2C0: Error timeout 0 ms!!!
    [IPU1-0] 28.484780 s: src/bsputils_ub960.c @ Line 1133:
    [IPU1-0] 28.484841 s: Could not configure UB913 Ser !!!
    [IPU1-0] 29.466144 s: src/bsp_deviceI2c.c @ Line 580:
    [IPU1-0] 29.466266 s: I2C0: DEV 0x74: WR 0x0d = 0x9d ... ERROR !!!
    [IPU1-0] 29.466357 s: src/bsp_deviceI2c.c @ Line 602:
    [IPU1-0] 29.466418 s: I2C0: Error timeout 1 ms!!!
    [IPU1-0] 29.466510 s: src/bsputils_ub960.c @ Line 1869:
    [IPU1-0] 29.466571 s: Could not configure UB913 Ser !!!
    [IPU1-0] 29.466632 s: #### Sensor Config time = 1323 msec ####

    Cheers,

    Morgan,
  • You mean, even after this error print, it is able to capture and display images??
    Do you see good image on the display??

    Regards,
    Brijesh
  • Btw, which VSDK release that you are using?
  • Yes, even after this error print, the usecase works as expected (good display of capture video). I have checked another time and I confirm (I did not have the line " Detected 964 v3 DeSerializer" this time...) that the usecase works as expected (good output display).

    I use the VSDK version 3_1.

    Again, if it is of any use, when I change the alias addresses from {0x40, 0x42, 0x44, 0x46} to {0x60, 0x62, 0x64, 0x66} in iss_sensor_tda3xx.c, the usecase does not crash (detailed in a previous answer) but there is no display.

    Thanks,

    Morgan,
  • That's actually good news. looks like i2c configuration for OV10640 goes through even if there are some initial failures. May be it requires slightly more time before probing for OV10640/UB913..

    I2C alias depends on the entire system. Please check if you have any other i2c slave connected to these addresses..

    Regards,
    Brijesh
  • Hi Brijesh,

    I have tried to put some delay with waitAfterPowerOn and waitAfter960Init variables (in bsputils_ub960.c) but it did not make it work...


    However, I now know what the issue might be... The sensor version: my new camera has an OV10640 version 0xDC and the previous (working) camera had the version 0xB4. And, there is a condition that checks for this value in OV10640_imi_Start (iss_sensor_ov10640.c), if it is not equal, it does not send i2c params... I have tried to bypass the condition, it is able to send the i2c parameters, but there is still no image (the usecase starts nominally (with some errors already mentioned) but there is no display).

    Are there some fundamental changes between sensor versions? Can I make it work easily?

    Thanks,

    Morgan,

  • Hi Morgan,

    From my experience, I had seen the differences in register settings between OV10640 revision, so there could be config differences between 0xDC and 0xB4. From VSDK point of view, this is the revision that we support. You will need to contact Omnivision to get the updated configuration for this new revision.

    Regards,
    Brijesh
  • Thanks again for the support, I will see what I can do with Omnivision then.

    Regards,

    Morgan,