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.

2 VIP instance with TVP7002 and capture inline scaling

Other Parts Discussed in Thread: TVP7002

Hi,

I am capturing from two TVP7002 devices and using both VIP0 and VIP1 instances as follow:

VIP0  - Using in-line scaling two outputs: 1) 1280x720 and 2) 720x480.

VIP1 - 1280x720 output

My link is as follow:

2 Capture (1280x720) => Merge (numInQue = 3) => VPSS Out => IPC Video In => 3 Encoders => IPC Video Bits Out (RTOS) => IPC Video Bits In (HOST) (Dump h264 data)

My issue with this link is, I am able to get data of VIP0 port i.e. both 1280x720 and 720x480. But not able to get data on VIP1 port.

If I don't use inline scaling in VIP0, then I am able to get data on both VIP0 and VIP1 ports.

Is something missing in my link creation? 

Can anyone suggest me what is the issue with this scenario?


Regards,

Anupama 

  • Pls share your usecase file (where links are created and connected) and logs of Vsys_printDetailedStatistics

  • Hi Badri Narayan,

    Thanks for quick revert back.

    Please find attached usecase file.

    I can see that "HDVICP-ID:2" instance is always showing 0 for all statistics, which means something is missing with the created links.

    Can you please help us understand the missing part ?

    Print statistics:

     Enter Choice: i


     [m3vpss ]
     [m3vpss ]  *** Capture Driver Advanced Statistics ***
     [m3vpss ]
     [m3vpss ]  VIP Parser Reset Count : 0
     [m3vpss ]
     [m3vpss ]      |   Total    Even     Odd  Total  Even   Odd  Min /  Max  Min /  Max Dropped Fid Repeat Frame Error Y/C
     [m3vpss ]  CH  |  Fields  Fields  Fields    FPS   FPS   FPS       Width      Height  Fields      Count (Desc Error Y/C)
     [m3vpss ]  ------------------------------------------------------------------------------------------------------------
     [m3vpss ]  000 |    1069    1069       0     50    50     0 1280 / 1280  720 /  720       1          0 0/0 (0/0)
     [m3vpss ]  010 |    1069    1069       0     50    50     0  720 /  720  480 /  480       1          0 0/0 (0/0)
     [m3vpss ]  200 |       1       1       0      0     0     0 65535 /    0 65535 /    0       1          0 0/0 (0/0)
     [m3vpss ]
     [m3vpss ]  VIP Capture Port 0 | DescMissMatch1 = 0, DescMissMatch2 = 0 , DescMissMatch3 = 0
     [m3vpss ]  VIP Capture Port 2 | DescMissMatch1 = 0, DescMissMatch2 = 0 , DescMissMatch3 = 0
     [m3vpss ]
     [m3vpss ]  *** Capture List Manager Advanced Statistics ***
     [m3vpss ]
     [m3vpss ]  List Post Count        : 5349
     [m3vpss ]  List Stall Count       : 0
     [m3vpss ]  List Post Time (ms)    : Max = 0, Min = 0, Avg = 0, Total = 0
     [m3vpss ]  INTC Timeout Count     : (0, 0) (Min timeout value = 986, 1000)
     [m3vpss ]  Descriptor miss found count : 0
     [m3vpss ]
     [m3vpss ]
     [m3vpss ]  VIP and VPDMA registers,
     [m3vpss ]  VIP0 : FIQ_STATUS  : 0x4810551c = 0x00000000
     [m3vpss ]  VIP1 : FIQ_STATUS  : 0x48105a1c = 0x00000000
     [m3vpss ]  VPDMA: LIST_BUSY   : 0x4810d00c = 0x00000000
     [m3vpss ]
     [m3vpss ]
     [m3vpss ]  278258: CAPTURE: Fields = 2136 (fps = 99, CPU Load = 0)
     [m3vpss ]  278258: CAPTURE: Num Resets = 0 (Avg 0 ms per reset)
     [m3vpss ]  278258: SYSTEM  : FREE SPACE : System Heap      = 67704 B, Mbx = 10240 msgs)
     [m3vpss ]  278258: SYSTEM  : FREE SPACE : SR0 Heap         = 9367296 B (8 MB)
     [m3vpss ]  278258: SYSTEM  : FREE SPACE : Frame Buffer     = 193622912 B (184 MB)
     [m3vpss ]  278258: SYSTEM  : FREE SPACE : Bitstream Buffer = 198126464 B (188 MB)
     [m3vpss ]  278258: SYSTEM  : FREE SPACE : Tiler 8-bit      = 134217728 B (128 MB)  - TILER ON
     [m3vpss ]  278259: SYSTEM  : FREE SPACE : Tiler 16-bit     = 134217728 B (128 MB)  - TILER ON
     [m3video]      284255: HDVICP-ID:0
     [m3video] All percentage figures are based off totalElapsedTime
     [m3video]               totalAcquire2wait :0 %
     [m3video]               totalWait2Isr :30 %
     [m3video]               totalIsr2Done :0 %
     [m3video]               totalWait2Done :30 %
     [m3video]               totalDone2Release :0 %
     [m3video]               totalAcquire2Release :30 %
     [m3video]               totalAcq2acqDelay :70 %
     [m3video]               totalElapsedTime in msec :   27334
     [m3video]               numAccessCnt:    1367
     [m3video]              IVA-FPS :      50
     [m3video]              Average time spent per frame in microsec:    5998
     [m3video]      284256: HDVICP-ID:1
     [m3video] All percentage figures are based off totalElapsedTime
     [m3video]               totalAcquire2wait :0 %
     [m3video]               totalWait2Isr :10 %
     [m3video]               totalIsr2Done :0 %
     [m3video]               totalWait2Done :10 %
     [m3video]               totalDone2Release :0 %
     [m3video]               totalAcquire2Release :10 %
     [m3video]               totalAcq2acqDelay :90 %
     [m3video]               totalElapsedTime in msec :   27330
     [m3video]               numAccessCnt:    1368
     [m3video]              IVA-FPS :      50
     [m3video]              Average time spent per frame in microsec:    1997
     [m3video]      284257: HDVICP-ID:2
     [m3video] All percentage figures are based off totalElapsedTime
     [m3video]               totalAcquire2wait :0 %
     [m3video]               totalWait2Isr :0 %
     [m3video]               totalIsr2Done :0 %
     [m3video]               totalWait2Done :0 %
     [m3video]               totalDone2Release :0 %
     [m3video]               totalAcquire2Release :0 %
     [m3video]               totalAcq2acqDelay :0 %
     [m3video]               totalElapsedTime in msec :       0
     [m3video]               numAccessCnt:       0
     [m3video]              IVA-FPS :       0
     [m3video]              Average time spent per frame in microsec:       0
     [m3video]
     [m3video]  *** ENCODE Statistics ***
     [m3video]
     [m3video]  Elasped Time           : 27 secs
     [m3video]
     [m3video]
     [m3video]  CH  | In Recv In Skip In User  Out Latency
     [m3video]  Num | FPS     FPS     Skip FPS FPS Min / Max
     [m3video]  --------------------------------------------
     [m3video]    0 |      50       0        0  50 255 / 249751
     [m3video]    1 |      50       0        0  50 255 / 249747
     [m3video]    2 |       0       0        0   0 255 /   0
     [m3video]
     [m3video] Multi Channel Encode Average Submit Batch Size
     [m3video] Max Submit Batch Size : 24
     [m3video] IVAHD_0 Average Batch Size : 1
     [m3video] IVAHD_0 Max achieved Batch Size : 1
     [m3video] IVAHD_1 Average Batch Size : 1
     [m3video] IVAHD_1 Max achieved Batch Size : 1
     [m3video] IVAHD_2 Average Batch Size : 0
     [m3video] IVAHD_2 Max achieved Batch Size : 0
     [m3video]
     [m3video] Multi Channel Encode Batch break Stats
     [m3video] Total Number of Batches created: 1364
     [m3video] All numbers are based off total number of Batches created
     [m3video]       Batch breaks due to batch sizeexceeding limit: 0 %
     [m3video]       Batch breaks due to ReqObj Que being empty: 100 %
     [m3video]       Batch breaks due to changed resolution class: 0 %
     [m3video]       Batch breaks due to interlace and progressivecontent mix: 0 %
     [m3video]       Batch breaks due to channel repeat: 0 %
     [m3video]       Batch breaks due to different codec: 0 %
     [m3video] Total Number of Batches created: 1364
     [m3video] All numbers are based off total number of Batches created
     [m3video]       Batch breaks due to batch sizeexceeding limit: 0 %
     [m3video]       Batch breaks due to ReqObj Que being empty: 100 %
     [m3video]       Batch breaks due to changed resolution class: 0 %
     [m3video]       Batch breaks due to interlace and progressivecontent mix: 0 %
     [m3video]       Batch breaks due to channel repeat: 0 %
     [m3video]       Batch breaks due to different codec: 0 %
     [m3video] Total Number of Batches created: 0
     [m3video] All numbers are based off total number of Batches created
     [m3video]       Batch breaks due to batch sizeexceeding limit: 0 %
     [m3video]       Batch breaks due to ReqObj Que being empty: 0 %
     [m3video]       Batch breaks due to changed resolution class: 0 %
     [m3video]       Batch breaks due to interlace and progressivecontent mix: 0 %
     [m3video]       Batch breaks due to channel repeat: 0 %
     [m3video]       Batch breaks due to different codec: 0 %
     [m3vpss ]
     [m3vpss ]  286261: LOAD: CPU: 5.1% HWI: 0.9%, SWI:1.1%
     [m3vpss ]
     [m3vpss ]  286262: LOAD: TSK: IPC_OUT_M30         : 0.8%
     [m3vpss ]  286262: LOAD: TSK: CAPTURE             : 0.4%
     [m3vpss ]  286262: LOAD: TSK: MERGE0              : 0.1%
     [m3vpss ]  286262: LOAD: TSK: MISC                : 1.8%
     [m3vpss ]
     [m3video]
     [m3video]  286763: LOAD: CPU: 6.7% HWI: 0.5%, SWI:0.6%
     [m3video]
     [m3video]  286763: LOAD: TSK: IPC_IN_M30          : 0.3%
     [m3video]  286763: LOAD: TSK: IPC_BITS_OUT0       : 0.9%
     [m3video]  286763: LOAD: TSK: ENC0                : 1.7%
     [m3video]  286763: LOAD: TSK: ENC_PROCESS_TSK_0   : 1.2%
     [m3video]  286763: LOAD: TSK: ENC_PROCESS_TSK_1   : 1.0%
     [m3video]  286763: LOAD: TSK: MISC                : 0.5%
     [m3video]
     [c6xdsp ]
     [c6xdsp ]  284686: LOAD: CPU: 0.1% HWI: 0.0%, SWI:0.0%
     [c6xdsp ]
     [c6xdsp ]  284686: LOAD: TSK: MISC                : 0.1%
     [c6xdsp ]

    Regards,
    Sweta

  • The configuration should be :

    vipInstId = 0;
        {
            pCaptureInstPrm                     = &capturePrm.vipInst[vipInstId];
            pCaptureInstPrm->vipInstId          = SYSTEM_CAPTURE_INST_VIP0_PORTA; /* Need to change based on actual HD video decoder */
            pCaptureInstPrm->videoDecoderId     = SYSTEM_DEVICE_VID_DEC_TVP7002_DRV; /* Need to change based on actual HD video decoder */
            pCaptureInstPrm->inDataFormat       = SYSTEM_DF_YUV422P;
            pCaptureInstPrm->standard           = SYSTEM_STD_720P_50; /* Need to change based on actual HD video decoder */
    #if (NO_OF_VIP_INST_CAP_OUT == 1)
            pCaptureInstPrm->numOutput          = 1; /* Need to change based on actual HD video decoder */
    #else
            printf ("================================> Capture Inline scaling ... \n");
    //        pCaptureInstPrm->numChPerOutput        = 2;
            pCaptureInstPrm->numOutput          = 2; /* Need to change based on actual HD video decoder */
    #endif

            pCaptureOutPrm                      = &pCaptureInstPrm->outParams[0];
            pCaptureOutPrm->dataFormat          = SYSTEM_DF_YUV420SP_UV;
            pCaptureOutPrm->scEnable            = FALSE; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->scOutWidth          = 720; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->scOutHeight         = 480; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->outQueId            = 0;

    #if (NO_OF_VIP_INST_CAP_OUT == 2)
            pCaptureOutPrm                      = &pCaptureInstPrm->outParams[1];
            pCaptureOutPrm->dataFormat          = SYSTEM_DF_YUV420SP_UV;
            pCaptureOutPrm->scEnable            = TRUE; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->scOutWidth          = 720; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->scOutHeight         = 480; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->outQueId            = 1;
           // pCaptureOutPrm->outQueId            = 0;
    #endif

        }
        vipInstId = 1;
        {
            pCaptureInstPrm                     = &capturePrm.vipInst[vipInstId];
            pCaptureInstPrm->vipInstId          = SYSTEM_CAPTURE_INST_VIP1_PORTA; /* Need to change based on actual HD video decoder */
            pCaptureInstPrm->videoDecoderId     = SYSTEM_DEVICE_VID_DEC_TVP7002_DRV; /* Need to change based on actual HD video decoder */
            pCaptureInstPrm->inDataFormat       = SYSTEM_DF_YUV422P;
            pCaptureInstPrm->standard           = SYSTEM_STD_720P_50; /* Need to change based on actual HD video decoder */
            pCaptureInstPrm->numOutput          = 1; /* Need to change based on actual HD video decoder */

            pCaptureOutPrm                      = &pCaptureInstPrm->outParams[0];
            pCaptureOutPrm->dataFormat          = /*SYSTEM_DF_YUV422I_YUYV;*/SYSTEM_DF_YUV420SP_UV;
            pCaptureOutPrm->scEnable            = FALSE; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->scOutWidth          = 1280; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->scOutHeight         = 720; /* Need to change based on actual HD video decoder */
            pCaptureOutPrm->outQueId            = 2;
            //pCaptureOutPrm->outQueId            = 1;
        }

    Are you sure the file attached corresponds to the log since the correct code has been commented out.

    Anyhow the VIP 1 is not receiving frames at all. YOu can see from the Capture Advanced statistics that number of frames received for HD channel is only 1 so it is not issue with link connection. Was the HD on VIP1 working if you didnt enable inline scaling ? Can you share that log

  • Hi Badri Narayan,

    Yes, the logs were for same code which I shared. With outQueID 0 for VIP0 (two outs) and outQueId 1 for VIQ1, I got all 3 encoder instances working with inline scaling.

    The issue was with the setup. Thanks for the help.

    I will check with outQueID as 0, 1 and 2 but seems like it may not have any relevance with the output channels.

    Regards,
    Sweta