AnsweredAssumed Answered

Failed to collect MT9P006 12-bit Bayer raw data from imx6Q CSI

Question asked by Robbie Jiang on Sep 13, 2015
Latest reply on Sep 14, 2015 by Wigros Sun

I have been recently working on supporting MT9P006 image sensor on Linux/MX6Q platform.


In our design, MT9P006 is connected to IPU1 CSI1 DATA[19~8] pins.

The output data from MT9P006 are 12 bit bayer raw data,

and the image size is 2592 x1944 (as indicated by the SENS_FRM_SIZE register).

To make  things easy, we configure csi data width as 16 bit Bayer /Generic data.

Because the inputs are only 12bits, the bit[3~0] will have to be discarded when the CSI data width is 16bits.

And the input path  is CSI->SMFC->IDMAC->Mem.

Following is the CSI related register settings:


IPU1_CSI1_CONF =     0x0400CB0B

IPU1_CSI1_SENS_FRM_SIZE =     0x07970A1F

IPU1_CSI1_ACT_FRM_SIZE =     0x07970A1F


And we also set the IDMAC CPMEM as follows:

imx-ipuv3 imx-ipuv3.1: ch 0 word 0 - 00000000 00000000 00000000 E0001800 001E5D43

imx-ipuv3 imx-ipuv3.1: ch 0 word 1 - 02800000 00500000 00C7C000 00050FC0 00000000

imx-ipuv3 imx-ipuv3.1: PFS 0x6,       // generic data

imx-ipuv3 imx-ipuv3.1: BPP 0x3,      // 16 bits per pixel

imx-ipuv3 imx-ipuv3.1: NPB 0x1f,    // burst size 31

imx-ipuv3 imx-ipuv3.1: FW 2591,

imx-ipuv3 imx-ipuv3.1: FH 1943,

imx-ipuv3 imx-ipuv3.1: EBA0 0x14000000

imx-ipuv3 imx-ipuv3.1: EBA1 0x14000000

imx-ipuv3 imx-ipuv3.1: Stride 5183



With the above settings, when MT9P006 is set to work in WALK 1's test pattern,

we can get some data from CSI, and the VS/HS/PIXCLK outputs seem correct.

but the data is not the expected data (walk 1s).


Anything wrong with my CSI/CPMEM settings?