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.

TDA4VM: DS90UB936 generate RAW12 format pattern

Part Number: TDA4VM

Hi TI members:

Becuase our customer board use DS90UB936 deserializer, 

Right now we try to debug the communication between DS90UB936 and TDA4 CSIRx port0.

For TDA4 Vision_apps capture request,

We need to generate 1920x1080, RAW12, on one CSI lane and CSI speed is 1.6Gbps.

Can someone help to check my configuration

i2cset -y -f 5 0x3d 0x1f 0x00 /* Lane speed set to 1.6Gbps */
i2cset -y -f 5 0x3d 0x20 0x30
i2cset -f -y 5 0x3d 0x33 0x73 /* Enable CSI Skew-Calibration, 1 lane out, continuous clock, CSI output */
i2cset -f -y 5 0x3d 0xB0 0x00
i2cset -f -y 5 0x3d 0xB1 0x02 /* PGEN_CFG : 8 color Bars; Blocksize=3 bytes (2*12bit=3Byte) */
i2cset -f -y 5 0x3d 0xB2 0x33
i2cset -f -y 5 0x3d 0xB1 0x03 /* GEN_CSI_DI : virtual channel=0; CSI-Header dataType=RAW12 (0x2C) */
i2cset -f -y 5 0x3d 0xB2 0x2c  
i2cset -f -y 5 0x3d 0xB1 0x04 /* PGEN_LINE_SIZE1 : MSB of NumBytesPerLine[byte] */
i2cset -f -y 5 0x3d 0xB2 0x0B
i2cset -f -y 5 0x3d 0xB1 0x05 /* PGEN_LINE_SIZE0 : LSB of NumBytesPerLine[byte] : 1920Px * 1.5 = 2880 Byte/Line = 0xB40 */
i2cset -f -y 5 0x3d 0xB2 0x40
i2cset -f -y 5 0x3d 0xB1 0x06 /* PGEN_BAR_SIZE1 : MSB of ColorBar[byte] */
i2cset -f -y 5 0x3d 0xB2 0x01
i2cset -f -y 5 0x3d 0xB1 0x07 /* PGEN_BAR_SIZE0 : LSB of ColorBar[byte] : 120*3 Byte = 360 = 0x168 */
i2cset -f -y 5 0x3d 0xB2 0x68
i2cset -f -y 5 0x3d 0xB1 0x08 /* PGEN_ACT_LPF1 : MSB of ActiveLinesPerFrame */
i2cset -f -y 5 0x3d 0xB2 0x04
i2cset -f -y 5 0x3d 0xB1 0x09 /* PGEN_ACT_LPF0 : LSB of ActiveLinesPerFrame : 1080 Lines = 0x438 */
i2cset -f -y 5 0x3d 0xB2 0x38
i2cset -f -y 5 0x3d 0xB1 0x0A /* PGEN_TOT_LPF1 : MSB of TotalNumberLinesPerFrame */
i2cset -f -y 5 0x3d 0xB2 0x04
i2cset -f -y 5 0x3d 0xB1 0x0B /* PGEN_TOT_LPF0 : LSB of TotalNumberLinesPerFrame: 9 + 1080 + 9 + 2 Lines = 1100 = 0x44c */
i2cset -f -y 5 0x3d 0xB2 0x4C
i2cset -f -y 5 0x3d 0xB1 0x0C /* PGEN_LINE_PD1 : MSB of LinePeriod[10ns] */
i2cset -f -y 5 0x3d 0xB2 0x09
i2cset -f -y 5 0x3d 0xB1 0x0D /* PGEN_LINE_PD0 : LSB of LinePeriod[10ns] : 100M/Fps/totalLines = 100M/38/1100= 2392 = 0x958
i2cset -f -y 5 0x3d 0xB2 0x58
i2cset -f -y 5 0x3d 0xB1 0x0E /* PGEN_VBP : VerticalFrontPorch[Lines] : 9 Line */
i2cset -f -y 5 0x3d 0xB2 0x09
i2cset -f -y 5 0x3d 0xB1 0x0F /* PGEN_VFP : VerticalBackPorch[Lines] : 9 Line */
i2cset -f -y 5 0x3d 0xB2 0x09
i2cset -f -y 5 0x3d 0xB1 0x01
i2cset -f -y 5 0x3d 0xB2 0x01

BR

Sentinen Chen

  • Hi Chen,

    Can you try add below configuration in your test setup? Also please make sure to start CSI only after node is created.

    WriteI2C(0xB0,0x00) # Indirect Pattern Gen Registers
    WriteI2C(0xB1,0x01) # PGEN_CTL
    WriteI2C(0xB2,0x01)
    WriteI2C(0xB1,0x02) # PGEN_CFG
    WriteI2C(0xB2,0x33)
    WriteI2C(0xB1,0x03) # PGEN_CSI_DI
    WriteI2C(0xB2,0x2C)

    You could even find complete test pattern code under _TEST_PATTERN_ENABLE_ in imaging\sensor_drv\src\ar0233\ar0233_serdes_config.h file.

    Regards,

    Brijesh

  • Hi Brijesh:

    Thanks for your reply,

    I would modify my parameter's value by follow ar0233_serdes_config.h file and try again.

    BR

    Sentinen Chen

  • Hi Brijesh:

    I find there is one question about ar0233_serdes_config.h define.

    1. ACTIVE Line big than TOTAL Line. 

    In ar0233_serdes_config.h, it will set active_line as 1280 (define in iss_sensor_ar0233.h) and total_line as 1050(0x41A)

     53     {0xB1, 0x08, 0x10}, // PGEN_ACT_LPF1
     54     {0xB2, AR0233_HEIGHT_HIBYTE, 0x10}, //
     55     {0xB1, 0x09, 0x10}, // PGEN_ACT_LPF0
     56     {0xB2, AR0233_HEIGHT_LOBYTE, 0x10}, //
     57     {0xB1, 0x0A, 0x10}, // PGEN_TOT_LPF1
     58     {0xB2, 0x04, 0x10}, //
     59     {0xB1, 0x0B, 0x10}, // PGEN_TOT_LPF0
     60     {0xB2, 0x1A, 0x10}, //

    
    

    In normal, Active Line should small than Total line. 

    Can you help to check this config again? 

    BR

    Sentinen Chen

  • Hi Chen,

    That's ok, please update the size that you require..

    You could even find pattern generator settings in Board_FpdUb960PGCfg0/Board_FpdUb960PGCfg1 in file \pdk_jacinto_07_00_00\packages\ti\board\src\devices\fpd\ds90ub960.c..

    Rgds,

    Brijesh

  • Hi Brijesh:

    I just follow ds90ub960.c config to charge my three parameters of "VBP, VFP, Total Line per frame",  other parametes keep origin value.

    But I finally can pass vx_app_conformace.out RawImageCapture testcase. 

    BR

    Sentinen Chen

  • Hi Chen,

    You mean it works fine now, are you able to capture color bar images from UB936?

    Please close the thread if question is answered.

    Rgds,

    Brijesh

  • Hi Brijesh:

    You mean it works fine now, are you able to capture color bar images from UB936?

    ==> Yes, we can capture color bar image form UB936 now. 

    But I see there is still some problem when I use RAW data type on CaptureNode and YUV data type on DisplayNode.

    I will close this thread, and discuess with you in origin thread.

    BR

    Sentinen Chen

  • Thank You Mr Chen.