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.

GstV4l2Src:v4l2src0: Could not negotiate format

Other Parts Discussed in Thread: TVP7002

Hi,

I'm new to this Mistral eval board stuff, so please accept my apologies up front if this is too simple or vague of a question.

I have a Mistral DM814x/AM387x Evaluation Module, TMDXEVM8148 which I'm attempting to use for some video processing with GStreamer.

I'm running version 5.04.00.11 of EZSDK.

I'm trying to capture some 1080p30 video coming in on the component inputs. If I run the Matrix demo I can execute the multimedia capture and encode demo and that all works fine. I can see the input on the LCD and it generates a file for me. I can not get the inputs to do anything so far with GStreamer.

I have changed theload firmware script using this command:
    root@dm814x-evm:~# cp /usr/share/ti/ti-media-controller-utils/load-hd-v4l2-firmware.sh /etc/init.d/load-hd-firmware.sh
and repaired the I2C mode according to this post:
    http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/717/p/187108/673606.aspx
and rebooted my board. After doing that I have several /dev/video devices which were not there before:
    root@dm814x-evm:~# ls /dev/video*
    /dev/video0  /dev/video1  /dev/video2  /dev/video3  /dev/video4  /dev/video5  /dev/video6

Whenever I try to construct a pipeline with a V4L2 source I get a format error. I'm not really sure how to understand what this means...
root@dm814x-evm:~# gst-launch v4l2src ! fakesink
Setting pipeline to PAUSED ...

 Mode set is 0
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Could not negotiate format
Additional debug info:
gstbasesrc.c(2778): gst_base_src_start (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
Check your filtered caps, if any
Setting pipeline to NULL ...
Freeing pipeline ...
root@dm814x-evm:~#

I've tried to specify various devices and use various cap filters to no avail...

Different device same error....

root@dm814x-evm:~# gst-launch v4l2src device="/dev/video6" ! fakesink
Setting pipeline to PAUSED ...

 Mode set is 0
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Could not negotiate format
Additional debug info:
gstbasesrc.c(2778): gst_base_src_start (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
Check your filtered caps, if any
Setting pipeline to NULL ...
Freeing pipeline ...
root@dm814x-evm:~#

And with a cap filter...

root@dm814x-evm:~# gst-launch v4l2src ! video/x-raw-yuv,format="(fourcc)UYVY" ! fakesink
Setting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Could not negotiate format
Additional debug info:
gstbasesrc.c(2778): gst_base_src_start (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
Check your filtered caps, if any
Setting pipeline to NULL ...
Freeing pipeline ...
root@dm814x-evm:~#

Any pointers would greatly be appreciated.

Thank you,

Gary

  • Should mention, my original goal was to get the video captured and encoded into a compressed file and/or onto the LCD.

    I trimmed the pipeline down to the simple one shown when I got the same error from more complex pipelines which would have done more than just bitbucket the data.

    If anyone has an example pipeline which passes the video to the LCD and/or to a compressed file I would love to see what you are doing!

    Thanks,

    Gary

  • With a height and width I get a new error. Don't understand why the fake sink would give this error though, so I kinda expect that something not so obvious is happening.

    root@dm814x-evm:~# gst-launch v4l2src ! video/x-raw-yuv,format=NV12,width=1920,height=1080 ! fakesink
    WARNING: erroneous pipeline: could not link v4l2src0 to fakesink0
    root@dm814x-evm:~# gst-launch v4l2src ! video/x-raw-yuv,format=UYVY,width=1920,height=1080 ! fakesink
    WARNING: erroneous pipeline: could not link v4l2src0 to fakesink0
    root@dm814x-evm:~#

    Thanks,

    Gary

  • Hi,

    TVP7002 driver doesn't support 1080P30, you need to either give 720P60 or 1080P60 for source to be detected.

  • I've got 720P60 coming in now on the red. green and blue wires and I'm still getting the same error...

    root@dm814x-evm:~# gst-launch v4l2src ! fakesink
    Setting pipeline to PAUSED ...

     Mode set is 0
    ERROR: Pipeline doesn't want to pause.
    ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Could not negotiate format
    Additional debug info:
    gstbasesrc.c(2778): gst_base_src_start (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
    Check your filtered caps, if any
    Setting pipeline to NULL ...
    Freeing pipeline ...
    root@dm814x-evm:~#

    I'm not sure how I would be able to tell which modes the driver supports based on the error?

    Gary

  • Nor sure how to tell even which input device I should be using for the component input.

    I tried all three input devices "/dev/video0", "/dev/video4", "/dev/video5" & "/dev/video6" with the same error?

    Gary

  • Hi,

    Can you please try with capture sample examples. You have connected component input right with proper color coding right? You can see below thread on how to connect component input

    http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/717/p/135286/753837.aspx#753837

  • Not sure what example you are talking about? The Matrix demo does work great with my setup.

    My boards do not look anything like the boards pictured in that link?

    Gary

  • I am facing the same problem, but currently I am just using a USB Webcam (Logitech 9000 Pro) that is registered as /dev/video0

    When trying to get some frames out of it I either get the "Could not negotiate format" or, if I use full caps "could not link v4l2src0 to fakesink0":

    root@dm814x-evm:~# gst-launch v4l2src device=/dev/video0 ! video/x-raw-yuv,width=320,height=240,framerate=30/1,format=\(fourcc\)YUYV,color-matrix=\"sdtv\" ! fakesink            
    WARNING: erroneous pipeline: could not link v4l2src0 to fakesink0
    root@dm814x-evm:~#

    I also changed the firmware to use the v4l2 version and got a lot of video devices in /dev/video*

    So how is it possible to use GStreamer v4l2src element on DM814x ?

  • I also can't capture component input from tvp7002 using gstreamer. I have searched in many topic but I can't get any solutions. I post in here, hope anyone help me ?
  • Hello,

    This is very old topic (5 years old).
    So I would recommend you to open a new topic with details like:
    Software version;
    Hardware platform;
    Gstreamer pipeline that you are using;
    The issue (errors) that you are observing etc.

    BR
    Margarita