i.MX8MPLUS dual camera recording failed

cancel
Showing results for 
Search instead for 
Did you mean: 

i.MX8MPLUS dual camera recording failed

335 Views
george_wang
Contributor I

I use usb hub to connect i.MX8MPLUS and two cameras

I want two camare to record at the same time

I use "bitbake imx-image-full" to create image

single camera recording is working but dual camera recording is not working

My dual camera recording command as follow

gst-launch-1.0 -v v4l2src device=/dev/video0 ! video/x-raw,framerate=20/1 ! videoscale ! videoconvert ! vpuenc_h264 ! avimux ! filesink location=./recording.avi v4l2src device=/dev/video2 ! video/x-raw,framerate=20/1 ! videoscale ! videoconvert ! vpuenc_h264 ! avimux ! filesink location=./recording2.avi

But the following messages appeared

Setting pipeline to PAUSED ...
====== VPUENC: 4.5.4 build on Jun 11 2020 06:40:37. ======
wrapper: 3.0.0 (VPUWRAPPER_ARM64_LINUX Build on Jun 11 2020 04:38:27)
vpulib: 1.1.1
firmware: 1.1.1.43690
====== VPUENC: 4.5.4 build on Jun 11 2020 06:40:37. ======
wrapper: 3.0.0 (VPUWRAPPER_ARM64_LINUX Build on Jun 11 2020 04:38:27)
vpulib: 1.1.1
firmware: 1.1.1.43690
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
/GstPipeline:pipeline0/GstV4l2Src:v4l2src1.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstCapsFilter:capsfilter1.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoScale:videoscale1.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoCo[17297.225159] usb 1-1.4.4.2: Not enough bandwidth for new device state.
[17297.233110] usb 1-1.4.4.2: Not enough bandwidth for altsetting 11
nvert:videoconvert1.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/vpuenc_h264:vpuenc_h264-1.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoConvert:videoconvert1.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoScale:videoscale1.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstCapsFilter:capsfilter1.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstV4l2Src:v4l2src0.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoScale:videoscale0.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoConvert:videoconvert0.GstPad:src: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/vpuenc_h264:vpuenc_h264-0.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoConvert:videoconvert0.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstVideoScale:videoscale0.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
/GstPipeline:pipeline0/GstCapsFilter:capsfilter0.GstPad:sink: caps = video/x-raw, framerate=(fraction)20/1, width=(int)800, height=(int)600, format=(string)YUY2, pixel-aspect-ratio=(fraction)1/1, colorimetry=(string)bt709, interlace-mode=(string)progressive
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Failed to allocate required memory.
Additional debug info:
../../../git/sys/v4l2/gstv4l2src.c(660): gst_v4l2src_decide_allocation (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
Buffer pool activation failed
Execution ended after 0:00:00.115481750
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

Can some one help me?

Thanks a lot !!!!!

0 Kudos
1 Reply

289 Views
igorpadykov
NXP TechSupport
NXP TechSupport

Hi George

from log: "Failed to allocate required memory" one can try to increase in dts "reserved memory"

imx8mp-evk-root.dts\freescale\dts\boot\arm64\arch - linux-imx - i.MX Linux kernel 

imx8mp.dtsi\freescale\dts\boot\arm64\arch - linux-imx - i.MX Linux kernel 


Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos