Which system do you use? Android, Ubuntu, OOWOW or others?
Ubuntu
Which version of system do you use? Please provide the version of the system here:
Ubuntu 24.04, Kernel 5.15.119
Please describe your issue below:
I have 2 identical USB webcams connected to the 2 USB ports of the VIM4. I can execute a gstreamer that shows each of them individually but cannot use both simultaneously. I have tried both a gstreamer compositor and also and OpenCV python script consuming both as gstreamer cameras.
Post a console log of your issue below:
GST_DEBUG=3 gst-launch-1.0 compositor name=comp \
sink_0::xpos=0 sink_0::ypos=0 sink_0::width=640 sink_0::height=480 \
sink_1::xpos=0 sink_1::ypos=480 sink_1::width=640 sink_1::height=480 \
! queue ! amlvenc ! rtph264pay ! udpsink port=5001 host=192.168.2.236 \
v4l2src device=/dev/video0 ! image/jpeg,width=640,height=480,framerate=60/1 ! jpegdec ! queue ! comp.sink_0 \
v4l2src device=/dev/video2 ! image/jpeg,width=640,height=480,framerate=60/1 ! jpegdec ! queue ! comp.sink_1
Setting pipeline to PAUSED ...
[API:aml_v4l2src_connect:271]Enter, devname : /dev/video0
driver : uvcvideo
device : Global Shutter Camera: Global S
bus_info : usb-xhci-hcd.0.auto-1.1
version : 331639
strcmp cap.driver: uvcvideo
[API:aml_v4l2src_connect:298]Exit, USB camera
devname : /dev/video0
driver : uvcvideo
device : Global Shutter Camera: Global S
bus_info : usb-xhci-hcd.0.auto-1.1
version : 331639
error tvin-port use -1
[API:aml_v4l2src_connect:271]Enter, devname : /dev/video2
driver : uvcvideo
device : Global Shutter Camera: Global S
bus_info : usb-xhci-hcd.0.auto-1.2
version : 331639
strcmp cap.driver: uvcvideo
[API:aml_v4l2src_connect:298]Exit, USB camera
devname : /dev/video2
driver : uvcvideo
device : Global Shutter Camera: Global S
bus_info : usb-xhci-hcd.0.auto-1.2
version : 331639
error tvin-port use -1
0:00:02.440399610 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src0> Can't give latency since framerate isn't fixated !
0:00:02.441030891 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src1> Can't give latency since framerate isn't fixated !
0:00:02.441160889 3982 0x7f88000d50 WARN aggregator gstaggregator.c:2283:gst_aggregator_query_latency_unlocked:<comp> Latency query failed
[API:aml_v4l2src_streamon:373]Enter
[API:aml_v4l2src_streamon:376]Exit
[API:aml_v4l2src_streamon:373]Enter
[API:aml_v4l2src_streamon:376]Exit
0:00:02.442164872 3982 0x7f880012f0 FIXME videodecoder gstvideodecoder.c:1193:gst_video_decoder_drain_out:<jpegdec0> Sub-class should implement drain()
0:00:02.442706696 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src0> Can't give latency since framerate isn't fixated !
Pipeline is live and does not need PREROLL ...
0:00:02.442761196 3982 0x7f880014d0 FIXME videodecoder gstvideodecoder.c:1193:gst_video_decoder_drain_out:<jpegdec1> Sub-class should implement drain()
0:00:02.442916610 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src1> Can't give latency since framerate isn't fixated !
0:00:02.443112398 3982 0x7f88000d50 WARN aggregator gstaggregator.c:2283:gst_aggregator_query_latency_unlocked:<comp> Latency query failed
0:00:02.443481225 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src0> Can't give latency since framerate isn't fixated !
0:00:02.443626431 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src1> Can't give latency since framerate isn't fixated !
0:00:02.443736179 3982 0x7f88000d50 WARN aggregator gstaggregator.c:2283:gst_aggregator_query_latency_unlocked:<comp> Latency query failed
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
0:00:02.447227579 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src0> Can't give latency since framerate isn't fixated !
0:00:02.447410867 3982 0x7f88000d50 WARN v4l2src gstv4l2src.c:1005:gst_v4l2src_query:<v4l2src1> Can't give latency since framerate isn't fixated !
0:00:02.447522574 3982 0x7f88000d50 WARN aggregator gstaggregator.c:2283:gst_aggregator_query_latency_unlocked:<comp> Latency query failed
New clock: GstSystemClock
0:00:02.477358740 3982 0x7f880012f0 WARN v4l2 gstv4l2object.c:4802:gst_v4l2_object_set_crop:<v4l2src0:src> VIDIOC_S_CROP failed
0:00:02.478660343 3982 0x7f880014d0 WARN v4l2 gstv4l2object.c:4802:gst_v4l2_object_set_crop:<v4l2src1:src> VIDIOC_S_CROP failed
0:00:02.541860365 3982 0x7f880012f0 WARN v4l2 gstv4l2object.c:3472:gst_v4l2_object_reset_compose_region:<v4l2src0:src> Failed to get default compose rectangle with VIDIOC_G_SELECTION: Invalid argument
0:00:02.543179718 3982 0x7f880014d0 WARN v4l2 gstv4l2object.c:3472:gst_v4l2_object_reset_compose_region:<v4l2src1:src> Failed to get default compose rectangle with VIDIOC_G_SELECTION: Invalid argument
0:00:02.547730391 3982 0x7f880012f0 WARN v4l2bufferpool gstv4l2bufferpool.c:853:gst_v4l2_buffer_pool_start:<v4l2src0:pool0:src> Uncertain or not enough buffers, enabling copy threshold
0:00:02.549753149 3982 0x7f880014d0 WARN v4l2bufferpool gstv4l2bufferpool.c:853:gst_v4l2_buffer_pool_start:<v4l2src1:pool0:src> Uncertain or not enough buffers, enabling copy threshold
0:00:02.556557160 3982 0x7f880014d0 ERROR v4l2bufferpool gstv4l2bufferpool.c:717:gst_v4l2_buffer_pool_streamon:<v4l2src1:pool0:src> error with STREAMON 28 (No space left on device)
0:00:02.556645992 3982 0x7f880014d0 ERROR bufferpool gstbufferpool.c:572:gst_buffer_pool_set_active:<v4l2src1:pool0:src> start failed
0:00:02.557494103 3982 0x7f880014d0 WARN v4l2src gstv4l2src.c:968:gst_v4l2src_decide_allocation:<v4l2src1> error: Failed to allocate required memory.
0:00:02.557579851 3982 0x7f880014d0 WARN v4l2src gstv4l2src.c:968:gst_v4l2src_decide_allocation:<v4l2src1> error: Buffer pool activation failed
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src1: Failed to allocate required memory.
Additional debug info:
../sys/v4l2/gstv4l2src.c(968): gst_v4l2src_decide_allocation (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src1:
Buffer pool activation failed
0:00:02.558145758 3982 0x7f880014d0 WARN basesrc gstbasesrc.c:3397:gst_base_src_prepare_allocation:<v4l2src1> Subclass failed to decide allocation
0:00:02.558273339 3982 0x7f880014d0 WARN basesrc gstbasesrc.c:3177:gst_base_src_lExecution ended after 0:00:00.111846747
oop:<v4l2src1> error: Internal data stream error.
Setting pipeline to NULL ...
0:00:02.558352921 3982 0x7f880014d0 WARN basesrc gstbasesrc.c:3177:gst_base_src_loop:<v4l2src1> error: streaming stopped, reason not-negotiated (-4)
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src1: Internal data stream error.
Additional debug info:
../libs/gst/base/gstbasesrc.c(3177): gst_base_src_loop (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src1:
streaming stopped, reason not-negotiated (-4)
0:00:02.563403712 3982 0x7f88000d50 WARN aggregator gstaggregator.c:648:gst_aggregator_push_mandatory_events:<comp:src> Sending stream start event failed
0:00:02.563540668 3982 0x7f88000d50 WARN aggregator gstaggregator.c:658:gst_aggregator_push_mandatory_events:<comp:src> Sending caps event failed
0:00:02.563774789 3982 0x7f88000d50 WARN aggregator gstaggregator.c:658:gst_aggregator_push_mandatory_events:<comp:src> Sending caps event failed
[API:aml_v4l2src_streamoff:381]Enter
[API:aml_v4l2src_streamoff:384]Exit
[API:aml_v4l2src_disconnect:363]Enter
change_divide_framerate, L69, dev , change_frame 0
[API:aml_v4l2src_disconnect:368]Exit
[API:aml_v4l2src_streamoff:381]Enter
[API:aml_v4l2src_streamoff:384]Exit
[API:aml_v4l2src_disconnect:363]Enter
change_divide_framerate, L69, dev , change_frame 0
[API:aml_v4l2src_disconnect:368]Exit
Freeing pipeline ...