Because of the Thanksgiving holiday in the U.S., TI E2E™ design support forum responses may be delayed from November 25 through December 2. Thank you for your patience.

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.

480i video capture using TVP5147 decoder

Other Parts Discussed in Thread: TVP5147, TVP7002, TVP5151

Hi ,

I am doing a composite video capture (480i ) using TVP5147 video decoder on DM8148 EVM  . I am using EZSDK 5.04 .

We have added a  TVP5147 driver in the hdvpss source . We are able to do 480i video capture successfully using chains application  .  The chains application captures 480i video on VIP Capture Port 2 and displays on SD display .

here is the Capture driver Statistics is chains application .

[Cortex_M3_ISS]  *** Capture Driver Advanced Statistics ***
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  VIP Parser Reset Count : 0
[Cortex_M3_ISS]  
[Cortex_M3_ISS]      |   Total    Even     Odd  Total  Even   Odd  Min /  Max  Min /  Max Dropped Fid Repeat Frame Error Y/C
[Cortex_M3_ISS]  CH  |  Fields  Fields  Fields    FPS   FPS   FPS       Width      Height  Fields      Count (Desc Error Y/C)
[Cortex_M3_ISS]  ------------------------------------------------------------------------------------------------------------
[Cortex_M3_ISS]  200 |    3623    1813    1813     60    30    30  768 /  768  262 /  263       0          0 0/0 (0/0)
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  VIP Capture Port 2 | DescMissMatch1 = 0, DescMissMatch2 = 0 , DescMissMatch3 = 0
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  *** Capture List Manager Advanced Statistics ***
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  List Post Count        : 7563
[Cortex_M3_ISS]  List Stall Count       : 0
[Cortex_M3_ISS]  List Post Time (ms)    : Max = 0, Min = 0, Avg = 0, Total = 0
[Cortex_M3_ISS]  INTC Timeout Count     : (0, 0) (Min timeout value = 983, 991)
[Cortex_M3_ISS]  Descriptor miss found count : 0
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  VIP and VPDMA registers,
[Cortex_M3_ISS]  VIP0 : FIQ_STATUS  : 0x4810551c = 0x00000000
[Cortex_M3_ISS]  VIP1 : FIQ_STATUS  : 0x48105a1c = 0x00000000
[Cortex_M3_ISS]  VPDMA: LIST_BUSY   : 0x4810d00c = 0x00000000
[Cortex_M3_ISS]  VPDMA: PERF_MON34 = 0x4305ffff, PERF_MON35 = 0x4305ffff, PERF_MON38 = 0x4305ffff, PERF_MON39 = 0x4305ffff

This is the snapshot taken when the chains application is running ,its all fine with the display except the colors are not proper .

Now when I do a 480i  capture using OMX application ,I see only half of the display clearly and the other half is noise . The OMX application has got only capture and display components . capture_display omx app does the 480i capture on VIP port 2 and displays on SD display . The OMX CTRL component is able to configure TVP5147 video decoder correctly as i can see from the logs .

Capture driver advanced Statistics for OMX capture_display application .

[Cortex_M3_ISS]  *** Capture Driver Advanced Statistics ***
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  VIP Parser Reset Count : 4
[Cortex_M3_ISS]  
[Cortex_M3_ISS]      |   Total    Even     Odd  Total  Even   Odd  Min /  Max  Min /  Max Dropped Fid Repeat Frame Error Y/C
[Cortex_M3_ISS]  CH  |  Fields  Fields  Fields    FPS   FPS   FPS       Width      Height  Fields      Count (Desc Error Y/C)
[Cortex_M3_ISS]  ------------------------------------------------------------------------------------------------------------
[Cortex_M3_ISS]  200 |    6216    6208       8      0     0     0    0 /  858    0 /  263    3116       6204 0/0 (4/0)
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  VIP Capture Port 2 | DescMissMatch1 = 0, DescMissMatch2 = 0 , DescMissMatch3 = 0
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  *** Capture List Manager Advanced Statistics ***
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  List Post Count        : 13272
[Cortex_M3_ISS]  List Stall Count       : 0
[Cortex_M3_ISS]  List Post Time (ms)    : Max = 0, Min = 0, Avg = 0, Total = 0
[Cortex_M3_ISS]  INTC Timeout Count     : (0, 0) (Min timeout value = 981, 991)
[Cortex_M3_ISS]  Descriptor miss found count : 0
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  
[Cortex_M3_ISS]  VIP and VPDMA registers,
[Cortex_M3_ISS]  VIP0 : FIQ_STATUS  : 0x4810551c = 0x00000000
[Cortex_M3_ISS]  VIP1 : FIQ_STATUS  : 0x48105a1c = 0x00000000
[Cortex_M3_ISS]  VPDMA: LIST_BUSY   : 0x4810d00c = 0x00060000
[Cortex_M3_ISS]  VPDMA: PERF_MON34 = 0x4305ffff, PERF_MON35 = 0x4305ffff, PERF_MON38 = 0x4305ffff, PERF_MON39 = 0x4305ffff
[Cortex_M3_ISS] 

As we can see from the above data ,the odd fields are continuously dropped and only even fields are captured .

This is the snapshot taken when doing a 480i video capture using OMX application  .  As we can see only top half of the display is clear and the bottom half is noise . What could be the reason for odd fields getting dropped when doing capture with OMX application .

I have set pVFCCComPvt->bFieldMerged = OMX_TRUE; 

storagePrms.bufferFmt = FVID2_BUF_FMT_FIELD ; (for a field based capture )  ,when i set storagePrms.bufferFmt = FVID2_BUF_FMT_FRAME , I am able to capture only two frames and the application hangs .

Can anyone help us out in understanding the above problem ? what would be the problem in the OMX framework ? any  help is appreciated  .

Thanks,

N Sivaramkrishna .

  • Hi TI ,

    We are expecting Frame Capture mode to work ,as it worked in case of 1080i video capture from the OMX application . But the OMX application hangs for 480i composite video capture . In Field capture mode ,we see that odd fields are continuously dropped using the same OMX application .

    Below is the log where the application hangs ,in Frame capture mode .

    N:VPSS  P:2 #:00924 T:00000010ea329d83 S:VIP-1 PORT-A Dropped Frame Count :1 Total Capture Frame Count 0
    N:VPSS  P:2 #:00925 T:00000010ea944f9d S:VIP-1 PORT-A Dropped Frame Count :2 Total Capture Frame Count 0
    N:VPSS  P:2 #:00926 T:00000010eaf62be1 S:VIP-1 PORT-A Dropped Frame Count :3 Total Capture Frame Count 0
    N:VPSS  P:2 #:00927 T:00000010eb58009d S:VIP-1 PORT-A Dropped Frame Count :4 Total Capture Frame Count 0
    N:VPSS  P:2 #:00928 T:00000010ebb98f43 S:VIP-1 PORT-A Dropped Frame Count :5 Total Capture Frame Count 0
    N:VPSS  P:2 #:00929 T:00000010ec4bb757 S:FVID_CAPTURE_FRAME_TS_INFO:: 0 , time : 115955
    N:VPSS  P:2 #:00930 T:00000010ec4c3a3f S:FVID_CAPTURE_FRAME_INFO:: ch:2,0,0, fid: 0, 858x262, addr:<not printed> , PixVal:<not printed>
    N:VPSS  P:2 #:00931 T:00000010ec4cda87 S:FVID_DEQUEUE_INFO:: OmxPortIndex:0 , FvidFramePtr :@9f19fb84 , FvidFrameBufPtr : @b3d00100 , OmxHdr:@9f19ff40 , FQHdr : @9f2092d8
    N:VPSS  P:2 #:00932 T:00000010ec4e55ab S:Rcm_Exec for fxnId:2144342018
    N:VPSS  P:2 #:00933 T:00000010ec51ee33 S:OmxRpc_rcmIfSkelOmxApi:Entered..Cmd:13
    N:VPSS  P:2 #:00934 T:00000010ec525aad S:PROCESS_EmptyThisBuffer: Entered Function
    N:VPSS  P:2 #:00935 T:00000010ec52b467 S:ETB: filledLen  282960
    N:VPSS  P:2 #:00936 T:00000010ec53e087 S:OmxRpc_rcmIfSkelOmxApi:Exiting..Cmd:13
    N:VPSS  P:2 #:00937 T:00000010ec555ab7 S:result = 0
    N:VPSS  P:2 #:00938 T:00000010ee95a9a7 S:FVID_CAPTURE_FRAME_TS_INFO:: 0 , time : 116051
    N:VPSS  P:2 #:00939 T:00000010ee962b73 S:FVID_CAPTURE_FRAME_INFO:: ch:2,0,0, fid: 0, 858x262, addr:<not printed> , PixVal:<not printed>
    N:VPSS  P:2 #:00940 T:00000010ee96cf75 S:FVID_DEQUEUE_INFO:: OmxPortIndex:0 , FvidFramePtr :@9f19fc38 , FvidFrameBufPtr : @b3e7c200 , OmxHdr:@9f1a00c0 , FQHdr : @9f209338
    N:VPSS  P:2 #:00941 T:00000010ee9851bb S:Rcm_Exec for fxnId:2144342018
    N:VPSS  P:2 #:00942 T:00000010ee9b76ad S:OmxRpc_rcmIfSkelOmxApi:Entered..Cmd:13
    N:VPSS  P:2 #:00943 T:00000010ee9bdcff S:PROCESS_EmptyThisBuffer: Entered Function
    N:VPSS  P:2 #:00944 T:00000010ee9c3917 S:ETB: filledLen  282960
    N:VPSS  P:2 #:00945 T:00000010ee9cf313 S:OmxRpc_rcmIfSkelOmxApi:Exiting..Cmd:13
    N:VPSS  P:2 #:00946 T:00000010ee9e50d5 S:result = 0
    N:VPSS  P:2 #:00947 T:00000010f0b96107 S:Rcm_Exec for fxnId:2145390593
    N:VPSS  P:2 #:00948 T:00000010f0bccedb S:OmxRpc_rcmIfSkelOmxApi:Entered..Cmd:14
    N:VPSS  P:2 #:00949 T:00000010f0bd2ed5 S:Entered Function :omxrpc_skel_fillthisbuffer
    N:VPSS  P:2 #:00950 T:00000010f0bddacf S:OmxRpc_rcmIfSkelOmxApi:Exiting..Cmd:14
    N:VPSS  P:2 #:00951 T:00000010f0bf4419 S:result = 0

    Thanks,

    N Sivaramkrishna .

  • Siva,

    Please check the height parameter passed to driver, for field merged mode, it would be full frame height. I believe for getting half frame , that would be issue. Check if omx is detecting any board, and setting the max number of lines for some number say 240 ?

    Regards

    Vimal

  • Hi Vimal,

    I am passing height=480 from the OMX application ,also in the OMX driver omx_vfcc_drvif.c  file i am setting pOutInfo->maxOutHeight = VPS_CAPT_MAX_OUT_HEIGHT_576_LINES;

    I have stepped into the OMX code using CCS and checked the Height in both _OMX_VFCCDrvCreate() and _OMX_VFCCDrvStart() functions . I think its full frame height that's passed to the hdvpss capture driver .

    Thanks

    Siva .

  • Hi Vimal,

    In case of 1080i Capture too ,I can see the height as half  in the log captured using logdump utility  .

    N:VPSS  P:2 #:01172 T:000000220e97d40f S:VIP-0 PORT-A Dropped Frame Count :8 Total Capture Frame Count 13
    N:VPSS  P:2 #:01173 T:000000220ef98b33 S:VIP-0 PORT-A Dropped Frame Count :9 Total Capture Frame Count 13
    N:VPSS  P:2 #:01174 T:000000220f5b2e47 S:VIP-0 PORT-A Dropped Frame Count :10 Total Capture Frame Count 13
    N:VPSS  P:2 #:01175 T:000000220fbd0ad6 S:FVID_CAPTURE_FRAME_TS_INFO:: 0 , time : 325338
    N:VPSS  P:2 #:01176 T:000000220fbee765 S:FVID_CAPTURE_FRAME_INFO:: ch:0,0,0, fid: 0, 1920x540, addr:<not printed> , PixVal:<not printed>
    N:VPSS  P:2 #:01177 T:000000220fc0db73 S:FVID_DEQUEUE_INFO:: OmxPortIndex:0 , FvidFramePtr :@9f19fb84 , FvidFrameBufPtr : @b3d00100 , OmxHdr:@9f19ff40 , FQHdr : @9f1d5dc8
    N:VPSS  P:2 #:01178 T:000000220fc2c129 S:Rcm_Exec for fxnId:2144342018
    N:VPSS  P:2 #:01179 T:000000220fc5f261 S:result = 0
    N:VPSS  P:2 #:01180 T:00000022108142ff S:VFCC Capture_drvOverflowDetectAndReset::Line 3687::VIP Reset Happend, reset count:: 4 portId : 0
    N:VPSS  P:2 #:01181 T:000000221081e4ed S:VFCC VIP Id:0
    N:VPSS  P:2 #:01182 T:0000002210ffeed7 S:RESET Count:: 4 , curTime:: 325361
    N:VPSS  P:2 #:01183 T:000000221215259f S:OmxRpc_rcmIfSkelOmxApi:Entered..Cmd:14
    N:VPSS  P:2 #:01184 T:000000221215a495 S:Entered Function :omxrpc_skel_fillthisbuffer
    N:VPSS  P:2 #:01185 T:0000002212165945 S:OmxRpc_rcmIfSkelOmxApi:Exiting..Cmd:14
    N:VPSS  P:2 #:01186 T:00000022122bc5c9 S:FVID_CAPTURE_FRAME_TS_INFO:: 0 , time : 325410
    N:VPSS  P:2 #:01187 T:00000022122dab7f S:FVID_CAPTURE_FRAME_INFO:: ch:0,0,0, fid: 0, 1920x540, addr:<not printed> , PixVal:<not printed>

    From this log I can see that hdvpss capture driver is providing fields  even in field merged mode (Frame capture mode ) . Is field merged is supported in OMX media framework . Can the capture driver provide frames in interlaced capture ?What would be the reason for getting only two fields captured and the OMX application hangs ? Please Comment .

    Thanks,

    Siva .

  • Adding to the above inputs ,We have also confirmed that chains application for Composite video capture (480i) using TVP5147 in Field Merged mode is working .

    In the chains application (See the logs below) ,the height and width was same as OMX capture application in Field Merged mode . However, in chains application we were seeing the odd and even fields displayed .

    [Cortex_M3_ISS]  modified to add TVP5147 testing  5075: CHAINS  : Starting 1 of 1 !!!
    [Cortex_M3_ISS]  5075: SYSTEM : Descriptor Heap Free Space (Current = 1947552 bytes, Minimum = 1947552 bytes)
    [Cortex_M3_ISS]  5075: SYSTEM : Heap Free Space (System = 76712 bytes, Buffer = 243481600 bytes, Mbx = 10240 msgs)
    [Cortex_M3_ISS]  5075: CAPTURE: Create in progress !!!
    [Cortex_M3_ISS]  5111: CAPTURE: VIP1 PortA capture mode is [16-bit, Non-mux Discrete Sync (HSYNC/VSYNC)] !!!
    [Cortex_M3_ISS]  Entered tvp5147/src/vpsdrv_tvp5147Api.c:Vps_tvp5147Create:129 !!!
    [Cortex_M3_ISS]  Leaving tvp5147/src/vpsdrv_tvp5147Api.c:Vps_tvp5147Create:163 !!!
    [Cortex_M3_ISS] chip id = 0x5147
    [Cortex_M3_ISS] chip revision = 0x7
    [Cortex_M3_ISS]  5155: CAPTURE: VIP 2: VID DEC 1027 (0x5c): 5147:0007:0000
    [Cortex_M3_ISS]  5155: CAPTURE: Create Done !!!
    [Cortex_M3_ISS]  5155: CAPTURE: Detect video in progress !!!
    [Cortex_M3_ISS] vaishnavi:dev addr=0x5c, 166: Vps_tvp5147SetVideoMode in tvp5147/src/vpsdrv_tvp5147I2c.c

    [Cortex_M3_ISS] devId = 0, tvp5147/src/vpsdrv_tvp5147I2c.c:Vps_tvp5147GetVideoStatus:639


    [Cortex_M3_ISS] Status reg 1 = 0x1f; Status reg 2 = 0xa0, VID STD Status = 0x81
    [Cortex_M3_ISS] Status isVideoDetect=1, 702:Vps_tvp5147GetVideoStatus in tvp5147/src/vpsdrv_tvp5147I2c.c

    [Cortex_M3_ISS]  5295: CAPTURE: Detected video at CH0 (720x525@59Hz, 0)!!!

    [Cortex_M3_ISS]  5295: CAPTURE: Detect video Done !!!
    [Cortex_M3_ISS]  6359: DISPLAY: Create in progress !!!
    [Cortex_M3_ISS]  6363: DISPLAY: Create Done !!!
    [Cortex_M3_ISS]  6364: SYSTEM : Descriptor Heap Free Space (Current = 1947552 bytes, Minimum = 1947552 bytes)
    [Cortex_M3_ISS]  6364: SYSTEM : Heap Free Space (System = 76424 bytes, Buffer = 231844864 bytes, Mbx = 10240 msgs)
    [Cortex_M3_ISS]  6364: DISPLAY: Start in progress !!!
    [Cortex_M3_ISS]  6410: DISPLAY: Start Done !!!
    [Cortex_M3_ISS]  6410: CAPTURE: Start in progress !!!
    [Cortex_M3_ISS]  6411: CAPTURE: Start Done !!!
    [Cortex_M3_ISS]  67930: CAPTURE: Stop in progress !!!
    [Cortex_M3_ISS]  67930: CAPTURE: Stop Done !!!
    [Cortex_M3_ISS]  67931: DISPLAY: Stop in progress !!!
    [Cortex_M3_ISS]  67972: DISPLAY: Stop Done !!!
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  *** Capture Driver Advanced Statistics ***
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  VIP Parser Reset Count : 0
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]      |   Total    Even     Odd  Total  Even   Odd  Min /  Max  Min /  Max Dropped Fid Repeat Frame Error Y/C
    [Cortex_M3_ISS]  CH  |  Fields  Fields  Fields    FPS   FPS   FPS       Width      Height  Fields      Count (Desc Error Y/C)
    [Cortex_M3_ISS]  ------------------------------------------------------------------------------------------------------------
    [Cortex_M3_ISS]  200 |    3623    1813    1813     60    30    30  768 /  768  262 /  263       0          0 0/0 (0/0)
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  VIP Capture Port 2 | DescMissMatch1 = 0, DescMissMatch2 = 0 , DescMissMatch3 = 0
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  *** Capture List Manager Advanced Statistics ***
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  List Post Count        : 7563
    [Cortex_M3_ISS]  List Stall Count       : 0
    [Cortex_M3_ISS]  List Post Time (ms)    : Max = 0, Min = 0, Avg = 0, Total = 0
    [Cortex_M3_ISS]  INTC Timeout Count     : (0, 0) (Min timeout value = 983, 991)
    [Cortex_M3_ISS]  Descriptor miss found count : 0
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  VIP and VPDMA registers,
    [Cortex_M3_ISS]  VIP0 : FIQ_STATUS  : 0x4810551c = 0x00000000
    [Cortex_M3_ISS]  VIP1 : FIQ_STATUS  : 0x48105a1c = 0x00000000
    [Cortex_M3_ISS]  VPDMA: LIST_BUSY   : 0x4810d00c = 0x00000000
    [Cortex_M3_ISS]  VPDMA: PERF_MON34 = 0x4305ffff, PERF_MON35 = 0x4305ffff, PERF_MON38 = 0x4305ffff, PERF_MON39 = 0x4305ffff
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  
    [Cortex_M3_ISS]  67974: CAPTURE: Fields = 1811 (fps = 29, CPU Load = 4)
    [Cortex_M3_ISS]  67974: CAPTURE: Num Resets = 0 (Avg 0 ms per reset)
    [Cortex_M3_ISS]  67974: CAPTURE: Delete in progress !!!
    [Cortex_M3_ISS]  67974: CAPTURE: Delete Done !!!
    [Cortex_M3_ISS]  67975: DISPLAY: Frames = 1816 (fps = 29) !!!
    [Cortex_M3_ISS]  67975: DISPLAY: Delete in progress !!!
    [Cortex_M3_ISS]  67975: DISPLAY: Delete Done !!!
    [Cortex_M3_ISS]  67975: DISPLAY: UNDERFLOW COUNT: HDMI(BP0) 3781, HDDAC(BP0) 0, DVO2(BP1) 3781, SDDAC(SEC1) 3637
    [Cortex_M3_ISS]
    [Cortex_M3_ISS]  67976: LOAD: CPU: 3 HWI: 0, SWI:0
    [Cortex_M3_ISS]
    [Cortex_M3_ISS]  67976: SYSTEM : Descriptor Heap Free Space (Current = 1947552 bytes, Minimum = 1947008 bytes)
    [Cortex_M3_ISS]  67976: SYSTEM : Heap Free Space (System = 76712 bytes, Buffer = 243481600 bytes, Mbx = 10240 msgs)
    [Cortex_M3_ISS]  67976: CHAINS  : Stopped 1 of 1 !!!

    If the chains application  is working fine ,what might be wrong with OMX capture application ?

  • Siva,

    Can you check if VPSS-M3 is not crashing ? there was an issue in following function, where It might post a semaphore for non created one in DM8148. 

    Capture_drvOverflowDetectAndReset; 

    Also filedmergemode parameter is proper for driver creation ? W had issues in these in last release, so interlace field mode capture was not possible.

    Regards

    Vimal

  • Hi Vimal,

    Thanks for the reply .

    I have seen VPSS-M3 crashed sometimes throwing exception and most of the times it just hangs without throwing exception .

    The logs show only two Fields captured  . In CCS when I halt the VPSS_M3 core ,i can see its entering into the function VpsHal_vipInstChkOverflowAndDisable() everytime .

    Can you check if VPSS-M3 is not crashing ? there was an issue in following function, where It might post a semaphore for non created one in DM8148. 

    Capture_drvOverflowDetectAndReset;

    What do you mean by non created one in DM8148 ? what i have to to avoid crash and do a 480i video capture ?


    Also fieldmergemode parameter is proper for driver creation ?

    I can confirm that fieldmergedmode has been set , i have set at two lines

    pVFCCComPvt->bFieldMerged == OMX_TRUE ;        

    storagePrms.fieldMerged = TRUE;

    Can you confirm me that frame capture mode is supported for Interlaced capture in OMX media framework ? what could be done for a successful 480i video capture in fieldmerged mode ?

    Thanks,

    Siva .

  • Hi Vimal,

    As you pointed out the function Capture_drvOverflowDetectAndReset , I have disabled the OverflowDetection in the capture driver using the below flag .

    g_vip_overflow.enableCheckOverflowDetect = FALSE;

    With the above change i did a 480i capture  and the result is the same , two fields got captured and the application hangs .

    I have also identified the line in  Capture_drvOverflowDetectAndReset where the semaphore is posted  [ System_unlockM2m(SYSTEM_VIP_1) ] . However we see that only the VFPC component pend [ System_lockM2m(SYSTEM_VIP_1) ] . Does this mean that if its a 480i interlaced capture ,should we include DEI component also in the OMX application ? Please clarify .

    As mentioned in the above post , I believe that fieldmerged mode is set to true and passed for driver creation .

    Thanks,

    Siva .

  • Siva,

    DEI is not required. If you can run just the capture, It is easier to isolate the issue. Display supports only field merge mode display.

    Regards

    Vimal

  • Hi Vimal ,

    I have also tried composite video capture ( 480i ) using only Capture component . The OMX app has got only Capture component ,It captures and stores into a yuv file .

    I see the same output ,two fields got captured  and the application got stuck  . This capture is done in field merged mode  . Below is the log .

    N:VPSS  P:2 #:00483 T:0000000618162fb1 S:FVID_CAPTURE_FRAME_TS_INFO:: 0 , time : 60743
    N:VPSS  P:2 #:00484 T:000000061816a545 S:FVID_CAPTURE_FRAME_INFO:: ch:2,0,0, fid: 0, 858x263, addr:<not printed> , PixVal:<not printed>
    N:VPSS  P:2 #:00485 T:000000061817426b S:FVID_DEQUEUE_INFO:: OmxPortIndex:0 , FvidFramePtr :@9f19fb74 , FvidFrameBufPtr : @b3d00100 , OmxHdr:@9f19ff30 , FQHdr : @9f1d5db8
    N:VPSS  P:2 #:00486 T:000000061818c46d S:Rcm_Exec for fxnId:2144342018
    N:VPSS  P:2 #:00487 T:00000006181bd4c9 S:result = 0
    N:VPSS  P:2 #:00488 T:0000000618959615 S:OmxRpc_rcmIfSkelOmxApi:Entered..Cmd:14
    N:VPSS  P:2 #:00489 T:00000006189607ed S:Entered Function :omxrpc_skel_fillthisbuffer
    N:VPSS  P:2 #:00490 T:000000061896b8d7 S:OmxRpc_rcmIfSkelOmxApi:Exiting..Cmd:14
    N:VPSS  P:2 #:00491 T:000000061a601b37 S:FVID_CAPTURE_FRAME_TS_INFO:: 0 , time : 60839
    N:VPSS  P:2 #:00492 T:000000061a60a433 S:FVID_CAPTURE_FRAME_INFO:: ch:2,0,0, fid: 0, 858x263, addr:<not printed> , PixVal:<not printed>
    N:VPSS  P:2 #:00493 T:000000061a613da7 S:FVID_DEQUEUE_INFO:: OmxPortIndex:0 , FvidFramePtr :@9f19fc28 , FvidFrameBufPtr : @b3e7c200 , OmxHdr:@9f1a00b0 , FQHdr : @9f1d5e18
    N:VPSS  P:2 #:00494 T:000000061a62c0c1 S:Rcm_Exec for fxnId:2144342018
    N:VPSS  P:2 #:00495 T:000000061a658fd3 S:result = 0
    N:VPSS  P:2 #:00496 T:000000061ae5728d S:OmxRpc_rcmIfSkelOmxApi:Entered..Cmd:14
    N:VPSS  P:2 #:00497 T:000000061ae5e719 S:Entered Function :omxrpc_skel_fillthisbuffer
    N:VPSS  P:2 #:00498 T:000000061ae6a03b S:OmxRpc_rcmIfSkelOmxApi:Exiting..Cmd:14

    I see something wrong with the OMX capture component itself . Chains application for TVP5147 composite capture (480i) in field merged mode worked fine for us . Can you tell us where we can look into to solve the problem .

    Thanks,

    Siva .

  • Vimal,

    As you can see in my first post in this thread , the odd fields are dropped and only even fields are captured .  It was a field based capture . I have done the field based capture for 1080i using TVP7002 as video decoder and in this case i see both the odd and even fields are present .

    I think first we should look into why the odd fields are dropped and only even fields are captured . Can you tell us what may be the reason for odd fields getting dropped in case of TVP5147 composite video capture .

    Please look into the first post in this thread .

    Thanks ,

    Siva .

  • Good Morning,

    I'm also trying to get the TVP5147 (on the DM8168 EVM btw) up and running but am having some issues getting the correct data out of the 5147 (or perhaps into the 8168). As you'll see in the attached image, when configured with (VPS_CAPT_VIDEO_CAPTURE_MODE_SINGLE_CH_NON_MUX_EMBEDDED_SYNC + VPS_CAPT_VIDEO_IF_MODE_16BIT) the data is all green and seems to be 'double-width'.

    Looking at the logs in this post (thank you) it seems that the DM81XX_VIP connnected to the TVP5147 as  "VIP1 PortA capture mode is [16-bit, Non-mux Discrete Sync (HSYNC/VSYNC)" (which I believe to be VPS_CAPT_VIDEO_CAPTURE_MODE_SINGLE_CH_NON_MUX_DISCRETE_SYNC_HSYNC_VSYNC + VPS_CAPT_VIDEO_IF_MODE_16BIT).

    If this is the case, perhaps you could share how you have configured the TVP5147 registers (eg 0x33 == output mode, others?)

    If it's of any help, below is how I currently have things configured:

    snippet_from_ua_create_capture()
    {
    // CaptureLink_CreateParams capturePrm;
    capturePrm.isPalMode = FALSE;
    capturePrm.fakeHdMode = FALSE;
    capturePrm.doCropInCapture = FALSE;
    capturePrm.tilerEnable = FALSE;
    capturePrm.enableSdCrop = FALSE;

    capturePrm.vipInst[x].vipInstId = SYSTEM_CAPTURE_INST_VIP1_PORTA; // == defined as 2u
    capturePrm.vipInst[x].videoDecoderId = SYSTEM_DEVICE_VID_DEC_TVP5147VCL_DRV; // == custom, see below
    capturePrm.vipInst[x].inDataFormat = SYSTEM_DF_YUV422P;
    capturePrm.vipInst[x].standard = SYSTEM_STD_480I;
    capturePrm.vipInst[x].numOutput = 1;
    capturePrm.vipInst[x].outParams[0].dataFormat = SYSTEM_DF_YUV422I_YUYV;
    capturePrm.vipInst[x].outParams[0].scEnable = FALSE;
    capturePrm.vipInst[x].outParams[0].scOutWidth = 0;
    capturePrm.vipInst[x].outParams[0].scOutHeight = 0;
    capturePrm.vipInst[x].outParams[0].outQueId = 0;

    ## snip ##
    }

    Int32 CaptureLink_drvCreateInst(CaptureLink_Obj * pObj, UInt16 instId)
    {
    ## snip ##
    else if (pInstPrm->videoDecoderId == FVID2_VPS_VID_DEC_TVP5147VCL_DRV) {
    switch (pInstPrm->standard)
    {
    case FVID2_STD_NTSC:
    Vps_printf("%s():%d| pInstPrm->standard:%d == FVID2_STD_NTSC, trying FVID2_STD_480I instead \n",
    __FUNCTION__, __LINE__, pInstPrm->standard);
    case FVID2_STD_480I:
    pVipCreateArgs->inScanFormat = FVID2_SF_INTERLACED;
    pInst->maxWidth = 720;
    pInst->maxHeight = 240;
    inWidth = pInst->maxWidth;
    inHeight = pInst->maxHeight;
    Vps_printf("%s():%d| pInstPrm->standard:%d == FVID2_STD_480I--> inWidth:%d inHeight:%d, inDataFormat:%d \n",
    __FUNCTION__, __LINE__, pInstPrm->standard, inWidth, inHeight, pVipCreateArgs->inDataFormat);
    break;
    default:
    Vps_printf("%s():%d| pInstPrm->standard:%d == UNHANDLED \n",
    __FUNCTION__, __LINE__, pInstPrm->standard);
    UTILS_assert(0);
    break;
    }

    pVipCreateArgs->numCh = 1;

    /* produces 'double-width', green image */
    pVipCreateArgs->videoCaptureMode = VPS_CAPT_VIDEO_CAPTURE_MODE_SINGLE_CH_NON_MUX_EMBEDDED_SYNC;
    pVipCreateArgs->videoIfMode = VPS_CAPT_VIDEO_IF_MODE_16BIT;
    #if 0
    /* does not produce an image ?! */
    pVipCreateArgs->videoCaptureMode = VPS_CAPT_VIDEO_CAPTURE_MODE_SINGLE_CH_NON_MUX_EMBEDDED_SYNC;
    pVipCreateArgs->videoIfMode = VPS_CAPT_VIDEO_IF_MODE_8BIT;
    #endif
    }
    ## snip ##
    }

  • I'm trying to add support for the TVP5151 standard definition decoder to OMX, I already have it working as a V4L2 device. Could you tell me where you went to add the TVP5147 support and code snippets you've mentioned above? I don't see it as part of the EZSDK 5.04. Do you have get some additional sources for this stuff to work?

    ~Ashwin

  • Hi,

    EZSDK controls external interfaces like TVP7002 through media controller binary. So if you dont have media controller binary you have to do following things to make TVP5147 work with EZSDK.

    1. Add the proper configuration for VIP in VFCC capture component.

    2. Disable I2C access from media controller.

    3. Control external devices through Linux I2C utility. You can use open source I2C utility to control external devices.

    Regards,

    Hardik Shah

  • hello Hardik,

    2. Disable I2C access from media controller.

    ==> May I know how to do that??

  • Hi,

       In the DM8168-EVM we got the TVP5147 working with V4L2, you can find more info here:

    http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/717/p/326172/1170437.aspx#1170437

    -David

  • HI ,

    Is this issue resolved.

    In our project too, we are trying to capture a frame using omx_camera component from an NTSC stream with FieldMerged option but not working

    Please provide the status

    Regards

    Shatath

  • Hello Shatath,

    This is the old e2e topic, please open a new one with the information about the software release etc.

    BR
    Margarita