Is there a way to capture with v4l2-ctl using tx2's onboard camera, ov5693? It's in BG10 format, but how do I check if the raw image comes out?

Hello,

Is there a way to capture with v4l2-ctl using tx2’s onboard camera, ov5693?
It’s in BG10 format, but how do I check if the raw image comes out?

Thank you.

Save to file by below command and use tools to check it. However need to check how the raw data in VI pixel memory layout from the TRM.

v4l2-ctl --set-fmt-video=width=1920,height=1080,pixelformat=RG10 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=1 --stream-to=ov1080.raw -d /dev/video0 
1 Like

Hello,


I am checking the output raw image file at rawpixels.net.
How can I set the settings to check the captured image?

Thank you.

Hello,

What is TRM?
And the camera pixel format is BG10.
Why did you set pixelformat-=RG10 in the above command?

nvidia@nvidia-desktop:~/coding$ v4l2-ctl --list-formats-ex
ioctl: VIDIOC_ENUM_FMT
Index : 0
Type : Video Capture
Pixel Format: ‘BG10’
Name : 10-bit Bayer BGBG/GRGR
Size: Discrete 2592x1944
Interval: Discrete 0.033s (30.000 fps)
Size: Discrete 2592x1458
Interval: Discrete 0.033s (30.000 fps)
Size: Discrete 1280x720
Interval: Discrete 0.008s (120.000 fps)

Thank you.

Yes, you should change it BG10 and I would suggest to use 7yuv to check it.

Hello,

Where are the applications or tools for validating and testing the v4l2 driver interface?

Thank you.

It’s v4l-utils(v4l2-ctl …)

1 Like

Hello,

v4l2-ctl --set-fmt-video=width=1920,height=1080,pixelformat=BG10 --stream-mmap --stream-count=1 -d /dev/video0 --stream-to=ov5693_1.raw
save it with the above command
I checked it like below using 7yuv.

How do I make adjustments to get an accurate image?

Thank you.

What’s your version?
After adjust the width/height even 8 bpp should be able see the image.
Attached is capture from my ov5693

ov1080.raw (4.0 MB)

1 Like

Hello,

What version are you talking about?
At what resolution should your image be viewed?

Your ov1080.raw file looks like this

Thank you.

Hello,

Can you send me the same command you used to save the raw file in tx2?

Thank you.

nvidia@nvidia-desktop:~$ v4l2-ctl --set-fmt-video=width=1920,height=1080,pixelformat=RG10 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=1 --stream-to=ov1080.raw -d /dev/video0
<

nvidia@nvidia-desktop:~$ v4l2-ctl --list-formats-ext
ioctl: VIDIOC_ENUM_FMT
Index : 0
Type : Video Capture
Pixel Format: ‘RG10’
Name : 10-bit Bayer RGRG/GBGB
Size: Discrete 3264x2464
Interval: Discrete 0.048s (21.000 fps)
Size: Discrete 3264x1848
Interval: Discrete 0.036s (28.000 fps)
Size: Discrete 1920x1080
Interval: Discrete 0.033s (30.000 fps)
Size: Discrete 1280x720
Interval: Discrete 0.017s (60.000 fps)
Size: Discrete 1280x720
Interval: Discrete 0.017s (60.000 fps)

1 Like

Hello,

nvidia@nvidia-desktop:~$ v4l2-ctl --list-formats-ext
ioctl: VIDIOC_ENUM_FMT
Index : 0
Type : Video Capture
Pixel Format: ‘BG10’
Name : 10-bit Bayer BGBG/GRGR
Size: Discrete 2592x1944
Interval: Discrete 0.033s (30.000 fps)
Size: Discrete 2592x1458
Interval: Discrete 0.033s (30.000 fps)
Size: Discrete 1280x720
Interval: Discrete 0.008s (120.000 fps)

Thank you.

Have a try this command. Add --stream-skip=30

v4l2-ctl --set-fmt-video=width=1920,height=1080,pixelformat=BG10 --set-ctrl bypass_mode=0 --stream-skip=30 --stream-mmap --stream-count=1 --stream-to=ov1080.raw -d /dev/video0
1 Like

Hello,

Thank you.

Hello,

I adjusted the Bits and it came out like this.
But I want it to come out perfect.

Thank you.

Could you try 2592x1944

Get the 2592x1944 raw image and adjust the align to 128 in 7yuv configure.

Hello,


What format should I choose?

Thank you.

What’s your version? The stride should be 2688
cat /etc/nv_tegra_release

1 Like