How to capture image in the RAW10 Bayer format

custom_board
mezzanine

#1

How to capture image in the RAW10 Bayer format.

I am able do the following steps successfully.

sudo media-ctl -d /dev/media1 -l '“msm_csiphy0”:1->“msm_csid0”:0[1],“msm_csid0”:1->“msm_ispif0”:0[1],“msm_ispif0”:1->“msm_vfe0_rdi0”:0[1]'
sudo media-ctl -d /dev/media1 -V ‘“ov7251 1-00c0”:0[fmt:SRGGB10/640x480],“msm_csiphy0”:0[fmt:SRGGB10/640x480],“msm_csid0”:0[fmt:SRGGB10/640x480],“msm_ispif0”:0[fmt:SRGGB10/640x480],“msm_vfe0_rdi0”:0[fmt:SRGGB10/640x480]’

Please can you suggest me after above steps, how to capture snapshot in RAW10 Bayer format.


#2

what about:

# Show video stream
$ gst-launch-1.0 v4l2src device=/dev/video0 ! 'video/x-bayer,format=rggb,width=640,height=480' ! glimagesink

or

# Capture image
gst-launch-1.0 v4l2src device=/dev/video0 num-buffers=1 ! 'video/x-bayer,format=rggb,width=640,height=480' ! jpegenc ! filesink location=image01.jpg

Note that you need to be sure your camera (ov7251) output is configured to generate RAW10 Bayer format.


#3

I am looking to do a raw capture of 640x480 SRGGB_1X8 stream source is not a camera output but from a lattice mipi to CSI converter, can you help me with this


#4

I tried the following steps
sudo media-ctl -d /dev/media0 -l ‘“msm_csid0”:1->“msm_ispif0”:0[1],“msm_ispif0”:1->“msm_vfe0_rdi0”:0[1]’

linaro@linaro-alip:~$ sudo media-ctl -d /dev/media0 -V ‘“msm_csid0”:1[fmt:SRGGB8_1X8/640x480 field:none],“msm_ispif0”:0[fmt:SRGGB8_1X8/640x480 field:none],“msm_vfe0_rdi0”:0[fmt:SRGGB8_1X8/640x480 field:none]’
linaro@linaro-alip:~$ gst-launch-1.0 v4l2src device=/dev/video0 ! ‘video/x-bayer,format=rggb,width=640,height=480’ ! glimagesink
WARNING: erroneous pipeline: could not link v4l2src0 to glimagesinkbin0, glimagesinkbin0 can’t handle caps video/x-bayer, format=(string)rggb, width=(int)640, height=(int)480


#5

Try to add bayer2rgb before sink element:

e.g. on my side with test source:

gst-launch-1.0 videotestsrc ! video/x-bayer,format=rggb,width=640,height=480 ! bayer2rgb ! autovideosink

#6

Hi Loic ,
Thanks for your reply , I need one more help.
Requirement
we are using qcom camera sensor for capturing a data from lattice MachX02 cpld device. The device outputs 24 bit raw 640x480 frame. Can you help us which will be the correct busformat and pipe line configuration for camss. T=


#7

Hi Loic,
This is a different question , this is about the dtsi configuration and mipi csi driver I am writing for my particular application. we are getting the clock on <0> and data-lane<0 1>. and pixel rate is 88.669998 MHz and format is MEDIA_BUS_FMT_UYVY8_2X8. I am suspecting is the lane configuration is fine. Because I see that one of the data-lane is masking of the clock-lane. I am just trying to understand if the hardware lane configuration for clock and data should be mutually exclusive, can you confirm my suspiscion