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.

TDA4VH-Q1: fvid2_dequeue get data for 4 Virtual channel

Part Number: TDA4VH-Q1

Tool/software:

Hi,

Our SDK version:

        linux:  ti-processor-sdk-linux-adas-j784s4-evm-09_01_00_06 

        rtos:  ti-processor-sdk-rtos-j784s4-evm-09_01_00_06

Now we used CSIRX to receive the 4 Virtual channel csi data send by Deserializer,we can change different cameras by modifying "pFrm->chNum", and now, we want to get four pictures at the same time, Before we initialize the "Fvid2_queue", we assigned "frmList.frames" to all four channels , but when we use "Fvid2_dequeue" to get frame, the frmList.numFrames value is always 1, If we want to use "Fvid2_dequeue" to get data for all four channels at once, is there anything else we need to pay attention to?

initialize:

for(int i = 0; i < TIVX_CSIRX_CAPTURE_INIT_FRAME_NUM; i++)
{
    pFrm = (Fvid2_Frame *)&appObj->frames[i];
    pFrm->chNum = i;
    pFrm->addr[0U] = (uint64_t)capture_Buffer[i].buffer;
    pFrm->appData = (void *)appObj;
    frmList.frames[frmList.numFrames] = pFrm;
    frmList.numFrames ++;
}
retVal = Fvid2_queue(appObj->drvHandle, &frmList, 0U);
capture data:
retVal = Fvid2_dequeue(
handle,
&frmList,
0U,
FVID2_TIMEOUT_NONE);

if (FVID2_SOK == retVal) {
    pFrm = frmList.frames[0];
    pFrm->chNum = (empty_cnt/100) % 4;
    buffer_info1.buffer_addr = pFrm->addr[0];
    buffer_info1.u64timeStamp = pFrm->timeStamp64;
    printf("CSI RX1: numFrames:%d, pFrm->chNum:%d, pFrm->addr[0]:%p\n",
    frmList.numFrames, pFrm->chNum, pFrm->addr[0]);
    transFvid2Frame((void *)buffer_info1.buffer_addr, NULL);
} else {
    printf("Fvid2FrameList_init1 failed!!!\n");
}

if (frmList.numFrames > 0U)
{
    retVal = Fvid2_queue(handle, &frmList, 0);
    if (FVID2_SOK != retVal)
    {
        retVal = (vx_status)VX_FAILURE;
        printf(" CbInst1: ERROR: Frame could not be queued !!!\n");
    }
}