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.

omtb script question

Help!!!

this is my omtb script ,but it doesn't work

omx omtb_dbg_lvl 0x10
omx omtb_dbg_lvl 0x08
omx api init

#omx setp 0 vfdc inbufsize_flag enable

omx api gethandle vfdc 0 0
omx api gethandle dc 0 0


#SET ALL THE PARAMS FOR DC#0
omx setp 0 dc OMX_TI_IndexParamVFDCDriverInstId nDrvInstID 0
omx setp 0 dc OMX_TI_IndexParamVFDCDriverInstId eDispVencMode 1080p60
omx api setparam  dc 0 0 0 OMX_TI_IndexParamVFDCDriverInstId
omx api sendcommand state dc 0 idle
omx api sendcommand state dc 0 waitforsem
omx api sendcommand state vfdc 0 idle
omx api sendcommand state vfdc 0 waitforsem
omx api sendcommand state dc 0 exec
omx api sendcommand state dc 0 waitforsem
omx api sendcommand state vfdc 0 exec
omx api sendcommand state vfdc 0 waitforsem

follow is the omtb log

OMTB> omx omtb_dbg_lvl 0x10
OK
    
OMTB> omx omtb_dbg_lvl 0x08
OK
    
OMTB> omx api init
OMTB-OMX_ErrorNone
OK
    
OMTB>
    
OMTB> #omx setp 0 vfdc inbufsize_flag enable
    
OMTB>
    
OMTB> omx api gethandle vfdc 0 0
OMTB-Entering <Function , instance #> : <VPSSVFDC_GetHandle , 0>
OMTB-Component Name is:OMX.TI.VPSSM3.VFDC
OMTB-Input File is:vpssvfdc_sample.yuv
OMTB-Entering <Function , instance #> : <VPSSVFDC_AllocateMemory , 0>
OMTB-Leaving <Function , instance #> : <VPSSVFDC_AllocateMemory , 0>
     

OMTB-VPSS VFDC Instance #: 0

OMTB-Leaving <Function , instance #> : <VPSSVFDC_GetHandle , 0>
OMTB-Entering <Function , instance #> : <VPSSVFDC_SetPortDefinition , 0>
OMTB-Entering <Function , instance #> : <VPSSVFDC_SetInputPortDefinition , 0>
OMTB-Leaving <Function , instance #> : <VPSSVFDC_SetInputPortDefinition , 0>
OMTB-Leaving <Function , instance #> : <VPSSVFDC_SetPortDefinition , 0>
OK
    
OMTB> omx api gethandle dc 0 0
OMTB-Entering <Function , instance #> : <VPSSDC_GetHandle , 0>
OMTB-Component Name is:OMX.TI.VPSSM3.CTRL.DC
OMTB-Input File is:vpssdc_sample.yuv
OMTB-Entering <Function , instance #> : <VPSSDC_AllocateMemory , 0>
OMTB-Leaving <Function , instance #> : <VPSSDC_AllocateMemory , 0>
     

OMTB-VPSS DC Instance #: 0

OMTB-Leaving <Function , instance #> : <VPSSDC_GetHandle , 0>
OK
    
OMTB>
    
OMTB>
    
OMTB> #SET ALL THE PARAMS FOR DC#0
    
OMTB> omx setp 0 dc OMX_TI_IndexParamVFDCDriverInstId nDrvInstID 0
OK
    
OMTB> omx setp 0 dc OMX_TI_IndexParamVFDCDriverInstId eDispVencMode 1080p60
OK
    
OMTB> omx api setparam  dc 0 0 0 OMX_TI_IndexParamVFDCDriverInstId
OMTB-OMX_ErrorNone
OK
    
OMTB> omx api sendcommand state dc 0 idle
OMTB-OMX_ErrorNone
OMTB-Entering <Function , instance #> : <VPSSDC_AllocateResources , 0>
OMTB-Leaving <Function , instance #> : <VPSSDC_AllocateResources , 0>
OK
    
OMTB> omx api sendcommand state dc 0 waitforsem
OMTB-Entering <Callback , instance #> : <VPSSDC_EventHandler , 0>
OMTB-In VPSSDC_EventHandler: OMX_EventCmdComplete -  OMX_CommandStateSet
OMTB-OMX_StateIdle
OMTB-Leaving <Callback , instance #> : <VPSSDC_EventHandler , 0>
OMTB-In <VPSSDC_OmxSendCommandState>: Obtained completion event of state transition
OK
    
OMTB> omx api sendcommand state vfdc 0 idle
OMTB-OMX_ErrorNone
OMTB-Entering <Function , instance #> : <OMTB_ClientAllocateResources , 0>
OMTB-Entering <Function , instance #> : <OMTB_ClientAllocateInputResources , 0>
OMTB- Input port index of the component, 0
OMTB- Number of input buffers needed by the component is , 1
OMTB- Input buffer size needed by the component is , 4147488
OMTB-Entering <Callback , instance #> : <VPSSVFDC_EventHandler , 0>
OMTB-In VPSSVFDC_EventHandler: OMX_EventCmdComplete -  OMX_CommandStateSet
OMTB-OMX_StateIdle
OMTB-Leaving <Callback , instance #> : <VPSSVFDC_EventHandler , 0>
OMTB- Input port index of the component, 1
OMTB- Number of input buffers needed by the component is , 1
OMTB- Input buffer size needed by the component is , 4147488
OMTB-Leaving <Function , instance #> : <OMTB_ClientAllocateInputResources , 0>
OMTB-Entering <Function , instance #> : <OMTB_ClientAllocateOutputResources , 0>
OMTB-Leaving <Function , instance #> : <OMTB_ClientAllocateOutputResources , 0>
OMTB-Leaving <Function , instance #> : <OMTB_ClientAllocateResources , 0>
OK
    
OMTB> omx api sendcommand state vfdc 0 waitforsem
OMTB-In <VPSSVFDC_OmxSendCommandState>: Obtained completion event of state transition
OK
    
OMTB> omx api sendcommand state dc 0 exec
OMTB-OMX_ErrorNone
OMTB-Entering <Callback , instance #> : <VPSSDC_EventHandler , 0>
OMTB-In VPSSDC_EventHandler: OMX_EventCmdComplete -  OMX_CommandStateSet
OMTB-OMX_StateExecuting
OMTB-Leaving <Callback , instance #> : <VPSSDC_EventHandler , 0>
OK
    
OMTB> omx api sendcommand state dc 0 waitforsem
OMTB-In <VPSSDC_OmxSendCommandState>: Obtained completion event of state transition
OK
    
OMTB> omx api sendcommand state vfdc 0 exec
OMTB-Entering <Thread , instance #> : <VPSSDC_ApiTsk , 0>
OMTB-VPSSDC_ApiTsk: VPSS DC API Mode Create Count: 1
OMTB-OMX_ErrorNone
OK
    
OMTB> omx api sendcommand state vfdc 0 waitforsem
OMTB-Entering <Thread , instance #> : <OMTB_ClientApiTsk , 0>
OMTB-Leaving <Thread , instance #> : <OMTB_ClientApiTsk , 0>
OMTB-Entering <Callback , instance #> : <VPSSVFDC_EventHandler , 0>
OMTB-In VPSSVFDC_EventHandler: OMX_EventError - 80001005
OMTB-FAIL: OMX_ErrorBadParameter

OMTB-Leaving <Callback , instance #> : <VPSSVFDC_EventHandler , 0>

 

why???      all I used is  default  value, I just want to know each param's mean and role.

 

 

 

  • What TI product or TI software are you using so I can place this question in the correct forum?

    Foe

  • hi,

    they are sdk5.02 omtb_01_00_00_02 for dm8168

  • Please find the attached omtb scrtipt which will demonstrate the following usecase.

    File Read -> Display

    Input YUV file should be in 422YUYV format.

    #omx omtb_dbg_lvl 0x10
    #omx omtb_dbg_lvl 0x08
    omx api init
    omx setp 0 vfdc frame_width 1920
    omx setp 0 vfdc frame_height 1080
    omx setp 0 vfdc ip_chromat_format 422YUYV
    omx setp 0 vfdc numinbuf 8 
    omx setp 0 vfdc inbufalign 0
    omx setp 0 vfdc inbuf_contig disable
    omx setp 0 vfdc inbufsize 4147200 
    omx setp 0 vfdc inbuf allocate
    omx setp 0 vfdc graphics_flag disable
    #omx setp 0 vfdc vcdemo_flag enable
    # YUV422 interleaved format file, 422YUYV format
    omx setp 0 vfdc infile /ST/venc_in/amelie_1080p_422.yuv
    omx setp 0 vfdc data_ipmode file
    omx setp 0 vfdc inbuf allocate
    omx setp 0 vfdc inbufsize_flag enable
    omx setp 0 dc insmod_hdmi disable
    omx setp 0 vfdc mosaic_window_config vs
    omx api gethandle vfdc 0 0
    omx api gethandle dc 0 0
    omx api getparam  vfdc 0 0 0 OMX_IndexParamPortDefinition
    omx setp 0 vfdc OMX_IndexParamPortDefinition nBufferSize 4147200
    omx setp 0 vfdc OMX_IndexParamPortDefinition video.nStride 3840
    omx setp 0 vfdc OMX_IndexParamPortDefinition video.nFrameWidth 1920
    omx setp 0 vfdc OMX_IndexParamPortDefinition video.nFrameHeight 1080
    omx api setparam  vfdc 0 0 0 OMX_IndexParamPortDefinition
    omx setp 0 vfdc OMX_TI_IndexParamVFDCDriverInstId nDrvInstID 0
    omx setp 0 vfdc OMX_TI_IndexParamVFDCDriverInstId eDispVencMode 1080p60
    omx api setparam  vfdc 0 0 0 OMX_TI_IndexParamVFDCDriverInstId
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout winStartX 0
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout winStartY 0
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout winWidth 1920
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout winHeight 1080
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout pitch.VFDC_YUV_INT_ADDR_IDX 3840
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout pitch.VFDC_YUV_SP_Y_ADDR_IDX 3840
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout pitch.VFDC_YUV_SP_CBCR_ADDR_IDX 3840
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout dataFormat 422I_YUYV
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout bpp bits16
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout priority 0
    omx setp 0 vfdc OMX_TI_IndexParamVFDCCreateMosaicLayout nLayoutId 0
    omx setp 0 vfdc mosaicNumRows 1
    omx setp 0 vfdc mosaicNumCols 1
    omx setp 0 vfdc mosaicDispWindowWidth 1920
    omx setp 0 vfdc mosaicDispWindowHeight 1080
    omx api setparam  vfdc 0 0 0 OMX_TI_IndexParamVFDCCreateMosaicLayout
    omx setp 0 vfdc OMX_TI_IndexConfigVFDCMosaicPort2WinMap nLayoutId 0
    omx api setconfig vfdc 0 0 0 OMX_TI_IndexConfigVFDCMosaicPort2WinMap 1 0 
    omx setp 0 vfdc OMX_TI_IndexParamBuffMemType eBufMemoryType default
    omx setp 0 vfdc OMX_IndexParamCompBufferSupplier eBufferSupplier unspecified
    omx setp 0 vfdc OMX_IndexParamVideoInit nPorts 1
    omx setp 0 vfdc OMX_IndexParamVideoInit nStartPortNumber 0
    #************************************************************
    #SET ALL THE PARAMS FOR DC#0
    omx setp 0 dc OMX_TI_IndexParamVFDCDriverInstId nDrvInstID 0
    omx setp 0 dc OMX_TI_IndexParamVFDCDriverInstId eDispVencMode 1080p60
    omx api setparam  dc 0 0 0 OMX_TI_IndexParamVFDCDriverInstId
    omx api setparam  vfdc 0 0 0 OMX_IndexParamPortDefinition
    omx api sendcommand port vfdc 0 enable 0
    omx api sendcommand port vfdc 0 waitforsem 0
    omx api sendcommand state dc 0 idle
    omx api sendcommand state dc 0 waitforsem
    omx api sendcommand state vfdc 0 idle
    omx api sendcommand state vfdc 0 waitforsem
    omx api sendcommand state dc 0 exec
    omx api sendcommand state dc 0 waitforsem
    omx api sendcommand state vfdc 0 exec
    omx api sendcommand state vfdc 0 waitforsem
    sleep 30000
    omx api sendcommand state dc 0 idle
    omx api sendcommand state dc 0 waitforsem
    omx api sendcommand state vfdc 0 idle
    omx api sendcommand state vfdc 0 waitforsem
    omx api sendcommand state dc 0 loaded
    omx api sendcommand state dc 0 waitforsem
    omx api sendcommand state vfdc 0 loaded
    omx api sendcommand state vfdc 0 waitforsem
    #Free the Handles
    omx api freehandle dc 0
    omx api freehandle vfdc 0
    omx api uninit
    

    Thanks,

    Srinivas

  • hi,Srinivas!

    thanks very much !!!  haha