MIPI camera through IPU2

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MIPI camera through IPU2

870 Views
richardwoodham
Contributor I

Suppose I have a MIPI camera connected to my i.MX 6 board and I want to route the video signal through IPU2, what changes do I have to make to the device tree?

Do I have to make any other changes? e.g explicitly enable IPU2 clock?

As it stands, with the supplied device tree I can capture image data through IPU1.  However, all the changes I have made so far end up with:

Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: v4l2 capture: mxc_v4l_dqueue timeout enc_counter 0
ERROR: from element /GstPipeline:pipeline0/GstImxV4l2VideoSrc:imxv4l2videosrc0: Internal data flow error.
Additional debug info:
../../../../gstreamer-1.8.3/libs/gst/base/gstbasesrc.c(2948): gst_base_src_loop (): /GstPipeline:pipeline0/GstImxV4l2VideoSrc:imxv4l2videosrc0:
streaming task paused, reason error (-5)
Execution ended after 0:00:10.097194002

As if something is not switched on or not configured correctly.

Original Attachment has been moved to: TestMIPI_IPU2.patch.zip

Labels (3)
Tags (1)
0 Kudos
2 Replies

596 Views
richardwoodham
Contributor I

I forgot to mention the camera chip I am using.  It is OV5640.  As it turns out there is a bug in the driver ov5640_mipi.c in the function ov5640_set_virtual_channel which uses csi_id (0 or 1) as the argument.  When there are 2 IPUs there are 4 virtual channels and 2 bits in register 0x4814 to be set.  If I hard-code the driver to use vc 2 or 3 I get:

pic_09_44_14.jpeg

which is progress, but not exactly what I wanted.  The image is the right size (720p).

0 Kudos

596 Views
igorpadykov
NXP Employee
NXP Employee

Hi Richard

for dts IPU numbers one can look at "ipu_id" usage, as in examples on

iMX6DQ MAX9286 MIPI CSI2 720P camera surround view solution for Linux BSP 

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

0 Kudos