您尚未登录。

楼主 # 2023-01-14 19:12:06

alizx
会员
注册时间: 2023-01-14
已发帖子: 10
积分: 115

使用 V3S 进行 USB 摄像头录制

你好。
我想在 3.5" RGB LCD 上显示 usb 摄像头并将其记录到 SD 卡。
一开始我用的是官网现成的荔枝派图片。 然后连接usb camera,但是不识别。 所以我进行了搜索,最后我将设备树中 &usb_otg 的 dr_mode 更改为“主机”。
然后 USB 摄像头被识别但没有驱动程序在那里。 然后我在内核配置中做了一些更改(添加 media_usb_support、V4L2、uvc)并再次编译内核。
现在 uvc 自动识别 usb 摄像头。
我得到 yavta 源代码并交叉编译它并将它添加到 sd 卡。
当我运行 yavta 捕获一些帧时,它返回了一些错误,我无法解决它。
有什么帮助吗?

有满足我要求的现成图像吗? (显示和记录 usb 摄像头)

请帮我。 我处境艰难。

谢谢

离线

楼主 #1 2023-01-14 19:18:03

alizx
会员
注册时间: 2023-01-14
已发帖子: 10
积分: 115

Re: 使用 V3S 进行 USB 摄像头录制

这是输出错误

root@LicheePi:~# ./yavta --capture=25 --file=out.MJPEG /dev/video0

Device /dev/video0 opened.
Device `USB Camera' on `usb-musb-hdrc.1.auto-1' (driver 'uvcvideo') supports video, capture, without mplanes.
Video format: MJPEG (47504a4d) 640x480 (stride 0) field none buffer size 614400
8 buffers requested.
length: 614400 offset: 0 timestamp type/source: mono/SoE
Buffer 0/0 mapped at address 0xb6e10000.
length: 614400 offset: 614400 timestamp type/source: mono/SoE
Buffer 1/0 mapped at address 0xb6d7a000.
length: 614400 offset: 1228800 timestamp type/source: mono/SoE
Buffer 2/0 mapped at address 0xb6ce4000.
length: 614400 offset: 1843200 timestamp type/source: mono/SoE
Buffer 3/0 mapped at address 0xb6c4e000.
length: 614400 offset: 2457600 timestamp type/source: mono/SoE
Buffer 4/0 mapped at address 0xb6bb8000.
length: 614400 offset: 3072000 timestamp type/source: mono/SoE
Buffer 5/0 mapped at address 0xb6b22000.
length: 614400 offset: 3686400 timestamp type/source: mono/SoE
Buffer 6/0 mapped at address 0xb6a8c000.
length: 614400 offset: 4300800 timestamp type/source: mono/SoE
Buffer 7/0 mapped at address 0xb69f6000.
[   67.288909] uvcvideo: Failed to submit URB 0 (-28).
Unable to start streaming: No space left on device (28).
8 buffers released.

离线

#2 2023-01-15 03:01:08

muzhi
会员
注册时间: 2019-12-14
已发帖子: 39
积分: 35.5

Re: 使用 V3S 进行 USB 摄像头录制

urb 错误通常与usb有关,我搜索了Google看起来已经有许多工程师遇到这样同样的报错,看起来该错误是由于USB带宽不足或速率太慢,但大家并没有讨论出可靠的解决方案。供您参考 : https://lore.kernel.org/linux-usb/CAJ+vNU194rZZRjQxSjN6OXXWBEgniHcO1=g==rPwcumKqhh1hA@mail.gmail.com/


The urb error is usually related to usb. I searched Google and it seems that many engineers have encountered the same error. It seems that the error is due to insufficient USB bandwidth or too slow speed, but no reliable solution has been discussed. For your reference: https://lore.kernel.org/linux-usb/CAJ+vNU194rZZRjQxSjN6OXXWBEgniHcO1=g==rPwcumKqhh1hA@mail.gmail.com/

One more question, do you have dma enabled in UVC?

离线

楼主 #3 2023-01-16 08:17:52

alizx
会员
注册时间: 2023-01-14
已发帖子: 10
积分: 115

Re: 使用 V3S 进行 USB 摄像头录制

thanks very much
I saw the link berfore.
Exactly there is no reliable solution for that.

I don't know.
How can I enable DMA for UVC?
Thanks

离线

#4 2023-01-16 13:57:43

muzhi
会员
注册时间: 2019-12-14
已发帖子: 39
积分: 35.5

Re: 使用 V3S 进行 USB 摄像头录制

In another post, I noticed that you are looking for available images, actually, there are many discussions related to V3s Cam here, maybe you can refer to:
https://whycan.com/t_2039.html
https://whycan.com/t_6234.html
https://whycan.com/t_5397.html
https://whycan.com/t_2667.html
https://whycan.com/t_2039.html
https://blog.csdn.net/Jun626/article/details/112969436

Some of these discussions also provide image files, these discussions use mjpg-streamer and ffmpeg and fswebcam as test tools, maybe you can try it.

离线

#5 2023-01-16 14:16:29

muzhi
会员
注册时间: 2019-12-14
已发帖子: 39
积分: 35.5

Re: 使用 V3S 进行 USB 摄像头录制

One more question, have you tried using the -n, -t or -d options in yavta to adjust the number of video buffers, the delay before requeuing buffers and the time per frame?

离线

楼主 #6 2023-01-16 16:22:52

alizx
会员
注册时间: 2023-01-14
已发帖子: 10
积分: 115

Re: 使用 V3S 进行 USB 摄像头录制

thank you so much.
yes I tried -n and -t and -d flags.
I will see your links and write feedback. thanks again

离线

楼主 #7 2023-01-18 03:51:59

alizx
会员
注册时间: 2023-01-14
已发帖子: 10
积分: 115

Re: 使用 V3S 进行 USB 摄像头录制

muzhi 说:

One more question, have you tried using the -n, -t or -d options in yavta to adjust the number of video buffers, the delay before requeuing buffers and the time per frame?

do you live in China? Can I have any number (whatsapp, wechat, telegram, ...) from you?
thanks

离线

#8 2023-02-06 00:33:03

muzhi
会员
注册时间: 2019-12-14
已发帖子: 39
积分: 35.5

Re: 使用 V3S 进行 USB 摄像头录制

alizx 说:
muzhi 说:

One more question, have you tried using the -n, -t or -d options in yavta to adjust the number of video buffers, the delay before requeuing buffers and the time per frame?

do you live in China? Can I have any number (whatsapp, wechat, telegram, ...) from you?
thanks

yes,I live in china
wechat:d3luMDMwNA

离线

#9 2023-04-05 15:53:30

william198757
会员
注册时间: 2019-11-22
已发帖子: 7
积分: 12

Re: 使用 V3S 进行 USB 摄像头录制

请问 这个问题解决了吗?

uvcvideo: Failed to submit URB 0 (-28).
Unable to start streaming: No space left on device (28).

离线

#10 2023-04-15 13:53:12

lz622848
会员
注册时间: 2023-04-07
已发帖子: 4
积分: 4

Re: 使用 V3S 进行 USB 摄像头录制

方便问下你使用的opencv版本吗,听说高版本会有问题吗

离线

页脚

工信部备案:粤ICP备20025096号 Powered by FluxBB

感谢为中文互联网持续输出优质内容的各位老铁们。 QQ: 516333132, 微信(wechat): whycan_cn (哇酷网/挖坑网/填坑网) service@whycan.cn