Not getting full frame speed from a USB3 camera

Post Reply
iamjoonkoo
Posts: 5
Joined: Fri Oct 16, 2020 6:35 am
languages_spoken: english
ODROIDs: C4
Has thanked: 0
Been thanked: 0
Contact:

Not getting full frame speed from a USB3 camera

Post by iamjoonkoo »

Hi.

I have bought a USB3 camera to do some image analysis using my recently purchased Odroid C4.
https://www.aliexpress.com/item/3288092 ... 30ee4iNMtH

When I tested the camera on my Ubuntu laptop it gives a full frame speed at the highest resolution.
However, I can't get the full speed at the highest resolution when I connect the camera to my C4.
I have contacted the camera manufacturer about this and I was told that this could be due to insufficient current
from the USB3.0 port.
The camera requires 5VDC and 170-210 mA working current.

So here are my questions.
Is this really due to insufficient current or is there other things I could try to fix?

Regards,

Scott

crashoverride
Posts: 5144
Joined: Tue Dec 30, 2014 8:42 pm
languages_spoken: english
ODROIDs: C1
Has thanked: 0
Been thanked: 381 times
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by crashoverride »

iamjoonkoo wrote:
Fri Oct 16, 2020 6:48 am
When I tested the camera on my Ubuntu laptop it gives a full frame speed at the highest resolution.
However, I can't get the full speed at the highest resolution when I connect the camera to my C4.
What method/program is used to test? Are you measuring the camera capture rate, the display rate, or the image processing rate?

iamjoonkoo
Posts: 5
Joined: Fri Oct 16, 2020 6:35 am
languages_spoken: english
ODROIDs: C4
Has thanked: 0
Been thanked: 0
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by iamjoonkoo »

Hi.

I am using qv4l2 and I am testing the capturing speed.

It appears that the camera is found as a USB3.0 camera device but
not getting the full pfs at the highest resolution (frame size:1920x1080, Capture image format:YUYV).


Hope this helps.

Regards

iamjoonkoo
Posts: 5
Joined: Fri Oct 16, 2020 6:35 am
languages_spoken: english
ODROIDs: C4
Has thanked: 0
Been thanked: 0
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by iamjoonkoo »

In addition, I have also tested the same USB3.0 camera on my Odroid XU-4 and it delivers the full capturing speed.

User avatar
odroid
Site Admin
Posts: 35602
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English, Korean
ODROIDs: ODROID
Has thanked: 1204 times
Been thanked: 879 times
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by odroid »

It seems to be a display rate problem since there is no GPU acceleration on the C4/N2 Mate(x11) desktop.
I assume the test application qv4l2 is based on the Qt.
Our XU4 Mate image has a customized Qt libraries which has a GPU acceleration capability and qv4l2 should work fine.

Because the current C4/N2 Ubuntu Mate desktop can't use the GPU acceleration, consider trying @tobetter's Gnome desktop OS image with the upstream kernel.
viewtopic.php?p=291635#p291635

iamjoonkoo
Posts: 5
Joined: Fri Oct 16, 2020 6:35 am
languages_spoken: english
ODROIDs: C4
Has thanked: 0
Been thanked: 0
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by iamjoonkoo »

Hi.
Thank you for your reply.

The issue is that I can't even SET to the full fps when I connect the USB3.0 camera to C4 while I can for XU-4 and other machine.
When I use qv4l2 on XU-4 and other machine, I can select the full fps from a drop-down menu, in this case, 60 fps.
However, on C4, I can't even set to 60 fps because there is only 5 fps available to choose from the drop-down menu.
It is not that the capturing and displaying slow down but rather I can't even choose the full fps because it is simply not available on C4 with qv4l2

I hope this helps.

User avatar
odroid
Site Admin
Posts: 35602
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English, Korean
ODROIDs: ODROID
Has thanked: 1204 times
Been thanked: 879 times
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by odroid »

Since we don't have the same camera device, it is hard to know a possible root cause.
I just guess the camera seems to be detected as a USB 2.0 device instead of USB 3.0.
Check "lsusb -t" and "dmesg" outputs to find a clue whether it is a USB or UVC driver problem or not.
Also compare "lsmod" outputs between C4 and XU4.

iamjoonkoo
Posts: 5
Joined: Fri Oct 16, 2020 6:35 am
languages_spoken: english
ODROIDs: C4
Has thanked: 0
Been thanked: 0
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by iamjoonkoo »

Hi.

Here is the output from XU-4.

Code: Select all

odroid@odroid:~$ lsusb -t
/:  Bus 06.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Vendor Specific Class, Driver=r8152, 5000M
/:  Bus 05.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/2p, 5000M
        |__ Port 1: Dev 3, If 0, Class=Video, Driver=uvcvideo, 5000M
        |__ Port 1: Dev 3, If 1, Class=Video, Driver=uvcvideo, 5000M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/2p, 480M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=exynos-ohci/3p, 12M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=exynos-ehci/3p, 480M
And dmesg
[ 8.319742] input: 3.0 USB Camera: 3.0 USB Camera as /devices/platform/soc/soc:usb3-0/12000000.dwc3/xhci-hcd.3.auto/usb4/4-1/4-1.1/4-1.1:1.0/input/input1


Now, here is the output from C4.

Code: Select all

odroid@lfar-dev3:~$ lsusb -t
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/4p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/2p, 480M
    |__ Port 1: Dev 2, If 0, Class=Hub, Driver=hub/4p, 480M
        |__ Port 2: Dev 6, If 0, Class=Video, Driver=uvcvideo, 480M
        |__ Port 2: Dev 6, If 1, Class=Video, Driver=uvcvideo, 480M
    |__ Port 2: Dev 3, If 0, Class=Human Interface Device, Driver=dwav_usb_mt, 12M
And dmesg
[ 156.275488] input: 3.0 USB Camera as /devices/platform/ff500000.dwc3/xhci-hcd.0.auto/usb1/1-1/1-1.2/1-1.2:1.0/input/input2

I have used the same camera and the same cable for these output.

Let me know if you need more info.
Many thanks,

User avatar
odroid
Site Admin
Posts: 35602
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English, Korean
ODROIDs: ODROID
Has thanked: 1204 times
Been thanked: 879 times
Contact:

Re: Not getting full frame speed from a USB3 camera

Post by odroid »

C4 detected the camera as a USB 2.0 device according to the 'lsusb -t' output.
Clean the USB host ports something like this.
viewtopic.php?f=147&t=30446&p=218401#p218401
Also try other USB 3.0 cables just in case.

Post Reply

Return to “Ubuntu”

Who is online

Users browsing this forum: No registered users and 1 guest