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.

AM69A: Sensor integration via csi in evaluation board

Part Number: AM69A

Hello,

I'm currently working with this board to try to bring up a camera with a imx577 sensor. I'm using the imx412 driver native from linux kernel that is compatible with this sensor. In the board im currently using a pre build image provided by TI.

First question it's how much GBs are supported in CSI lanes? I believe theres some errors in the datasheets because some say 1.5Gbs per each lane, and others say 2.5Gbs. Please clarify that.

Although the driver comes to a running state, we cannot obtain no good data from it (using gstreamer or any other tool). We trying to configure media-ctl pipeline manually, but it seems to have some restrictions that seem to be imposed by TI CSI2 RX driver.

Also do you have software support for VPAC and ISP? VPAC and ISP are necessary for a working camera sensor output raw data?

Hope my questions are clear enough. And thank you in advance for the help.

  • Hello Marlene,

    I believe CSI2RX supports up to 2.5gbps per lane speed but I will get confirmation from our hardware team and correct this discrepancy in the documents.

    Could you share the steps you have taken to enable the sensor thus far?

    Please see the following application for more information on software support for VPAC and ISP: https://www.ti.com/lit/an/sprad86/sprad86.pdf

    Let me know if you have any follow up questions and I will get back to you when I hear back on my team about the data lane rate.

    Thank you,

    Fabiana

  • Hello,

    I cross compile the imx412 driver has in the documentation. Adapted the imx219 device tree overlay for it. Loaded everything to the board, driver recognizes the sensor and seems everything correct. Media-ctl -p also seems correct. Tho when trying to run any instance of gstreamer it just fails with memory_allocation error. 

    Since the sensor outputs Raw data it means we need to use the ISP correct? And for doing so we need to use this tiovxisp plugin, correct?

    Also, its seems to me weird that i cannot see any type of data from none of the /dev, this is supposed to happen?

    Thank you for the help!

    Marlene  

  • Hi Marlene,

    Can you confirm that you are using SDK version 9.1 and could you share the output from media-ctl -p?

    Could you also run the following command with the correct video device name and formats and share the output?

    v4l2-ctl --verbose -d /dev/videoX --set-fmt-video=width=1920,height=1080,pixelformat=RGGB --stream-mmap

    Since the sensor outputs Raw data it means we need to use the ISP correct? And for doing so we need to use this tiovxisp plugin, correct?

    Yes, please follow the ISP tuning guide to generate the DCC binaries required for the GStreamer pipeline.

    Thank you,

    Fabiana

  • Media device information
    ------------------------
    driver          j721e-csi2rx
    model           TI-CSI2RX
    serial          
    bus info        platform:4500000.ticsi2rx
    hw revision     0x1
    driver version  6.1.46
    
    Device topology
    - entity 1: 4500000.ticsi2rx (9 pads, 9 links, 1 route)
                type V4L2 subdev subtype Unknown flags 0
                device node name /dev/v4l-subdev0
            routes:
                    0/0 -> 1/0 [ACTIVE]
            pad0: Sink
                    [stream:0 fmt:UYVY8_1X16/640x480 field:none colorspace:srgb xfer:srgb ycbcr:601 quantization:lim-range]
                    <- "cdns_csi2rx.4504000.csi-bridge":1 [ENABLED,IMMUTABLE]
            pad1: Source
                    [stream:0 fmt:UYVY8_1X16/640x480 field:none colorspace:srgb xfer:srgb ycbcr:601 quantization:lim-range]
                    -> "4500000.ticsi2rx context 0":0 [ENABLED,IMMUTABLE]
            pad2: Source
                    -> "4500000.ticsi2rx context 1":0 [ENABLED,IMMUTABLE]
            pad3: Source
                    -> "4500000.ticsi2rx context 2":0 [ENABLED,IMMUTABLE]
            pad4: Source
                    -> "4500000.ticsi2rx context 3":0 [ENABLED,IMMUTABLE]
            pad5: Source
                    -> "4500000.ticsi2rx context 4":0 [ENABLED,IMMUTABLE]
            pad6: Source
                    -> "4500000.ticsi2rx context 5":0 [ENABLED,IMMUTABLE]
            pad7: Source
                    -> "4500000.ticsi2rx context 6":0 [ENABLED,IMMUTABLE]
            pad8: Source
                    -> "4500000.ticsi2rx context 7":0 [ENABLED,IMMUTABLE]
    
    - entity 11: cdns_csi2rx.4504000.csi-bridge (5 pads, 2 links, 1 route)
                 type V4L2 subdev subtype Unknown flags 0
                 device node name /dev/v4l-subdev1
            routes:
                    0/0 -> 1/0 [ACTIVE]
            pad0: Sink
                    [stream:0 fmt:UYVY8_1X16/640x480 field:none colorspace:srgb xfer:srgb ycbcr:601 quantization:lim-range]
                    <- "imx412 4-0010":0 [ENABLED,IMMUTABLE]
            pad1: Source
                    [stream:0 fmt:UYVY8_1X16/640x480 field:none colorspace:srgb xfer:srgb ycbcr:601 quantization:lim-range]
                    -> "4500000.ticsi2rx":0 [ENABLED,IMMUTABLE]
            pad2: Source
            pad3: Source
            pad4: Source
    
    - entity 17: imx412 4-0010 (1 pad, 1 link, 0 route)
                 type V4L2 subdev subtype Sensor flags 0
                 device node name /dev/v4l-subdev2
            pad0: Source
                    [stream:0 fmt:SRGGB10_1X10/4056x3040 field:none colorspace:raw xfer:none]
                    -> "cdns_csi2rx.4504000.csi-bridge":0 [ENABLED,IMMUTABLE]
    
    - entity 23: 4500000.ticsi2rx context 0 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video4
            pad0: Sink
                    <- "4500000.ticsi2rx":1 [ENABLED,IMMUTABLE]
    
    - entity 29: 4500000.ticsi2rx context 1 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video5
            pad0: Sink
                    <- "4500000.ticsi2rx":2 [ENABLED,IMMUTABLE]
    
    - entity 35: 4500000.ticsi2rx context 2 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video6
            pad0: Sink
                    <- "4500000.ticsi2rx":3 [ENABLED,IMMUTABLE]
    
    - entity 41: 4500000.ticsi2rx context 3 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video7
            pad0: Sink
                    <- "4500000.ticsi2rx":4 [ENABLED,IMMUTABLE]
    
    - entity 47: 4500000.ticsi2rx context 4 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video8
            pad0: Sink
                    <- "4500000.ticsi2rx":5 [ENABLED,IMMUTABLE]
    
    - entity 53: 4500000.ticsi2rx context 5 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video9
            pad0: Sink
                    <- "4500000.ticsi2rx":6 [ENABLED,IMMUTABLE]
    
    - entity 59: 4500000.ticsi2rx context 6 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video10
            pad0: Sink
                    <- "4500000.ticsi2rx":7 [ENABLED,IMMUTABLE]
    
    - entity 65: 4500000.ticsi2rx context 7 (1 pad, 1 link, 0 route)
                 type Node subtype V4L flags 0
                 device node name /dev/video11
            pad0: Sink
                    <- "4500000.ticsi2rx":8 [ENABLED,IMMUTABLE]
    

    VIDIOC_QUERYCAP: ok
    VIDIOC_G_FMT: ok
    VIDIOC_S_FMT: ok
    Format Video Capture:
            Width/Height      : 4056/3040
            Pixel Format      : 'GB10' (10-bit Bayer GBGB/RGRG)
            Field             : None
            Bytes per Line    : 8112
            Size Image        : 24660480
            Colorspace        : sRGB
            Transfer Function : Default (maps to sRGB)
            YCbCr/HSV Encoding: Default (maps to ITU-R 601)
            Quantization      : Default (maps to Full Range)
            Flags             : 
                    VIDIOC_REQBUFS returned 0 (Success)
                    VIDIOC_QUERYBUF returned 0 (Success)
                    VIDIOC_QUERYBUF returned 0 (Success)
                    VIDIOC_QUERYBUF returned 0 (Success)
                    VIDIOC_QUERYBUF returned 0 (Success)
                    VIDIOC_QBUF returned 0 (Success)
                    VIDIOC_QBUF returned 0 (Success)
                    VIDIOC_QBUF returned 0 (Success)
                    VIDIOC_QBUF returned 0 (Success)
                    VIDIOC_STREAMON returned -1 (Broken pipe)
    

    Hello,

    Here it is the output of the 2 requested commands. Can you see something wrong?

    I'm following the isp tunning guide!

    Thank you for the help,

    Marlene

  • Hi Marlene,

    I have gotten confirmation from our hardware team that CSI indeed supports up to 2.5 Gbps per data lane.

    How are you setting the format for your sensor? I would recommend creating a new function for imx412 in the following camera setup script: /opt/edgeai-gst-apps/scripts/setup_cameras.sh 

    Based on your media-ctl -p output, could you try running the following?

    v4l2-ctl --verbose -d /dev/video2 --set-fmt-video=width=4056,height=3040,pixelformat=RGGB10 --stream-mmap

    Thank you,

    Fabiana

  • Hello Fabiana,

    After following the ISP/VPAC documentation, I really believe the problem of memory allocation from Gstreamer side. I think it tries to allocated outside of the dma space.

    There's anyway I can give more allocate more space for dma?

    Also, TI ever tried to implement a camera sensor with such a big resolution like this one (12MP)?

    Thank you,

    Marlene