IMX8MP CSI RAW12 data shifting

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

IMX8MP CSI RAW12 data shifting

2,396件の閲覧回数
jjiimmyy
Contributor II

Hi,

Our sensor is sending RAW 12 ,but only 10 bits are valid. So

data need to be shift left by 2 bits. 

video pipeline is currently setup as, sensor -> csi -> isp.

How and where can I have data shifted left by 2 bits in this video pipeline?

Thanks

 

0 件の賞賛
返信
3 返答(返信)

2,367件の閲覧回数
malik_cisse
Senior Contributor I

Hi
Did you try to declare the video to be Bit in the kernel driver and in the isp-imx wrapper?
I suppose the Bayer pixel will be transmitted as 16bit/pixel anyway and the IP will do the shifting automatically according to the bit depth you have declared in the driver.

0 件の賞賛
返信

2,363件の閲覧回数
jjiimmyy
Contributor II

malik_cisse,

 

Thanks for the suggestion.

How do you  "declare the video to be Bit in the kernel driver and in the isp-imx wrapper"?

Could you point out the files and format?

Thanks

0 件の賞賛
返信

2,272件の閲覧回数
malik_cisse
Senior Contributor I

Hi,
The full steps to port a new camera driver are described here:
https://community.nxp.com/pwmxy87654/attachments/pwmxy87654/imx-processors/225459/1/AN13713(8MP%20IS...

As for the bit depth in the sensor kernel driver, here is an example for ar1335 sensor:
https://github.com/nxp-imx/isp-vvcam/blob/2102360b58d9d1b36bc0c654c8301e4014b33951/vvcam/v4l2/sensor...

.bit_width also needs to be set as shown in this example:
in isp_imx\isp-imx-4.2.2.11.0\units\isi\drv\OV2775\source\OV2775.c
static struct vvcam_mode_info pov2775_mode_info[] = {
{
.index = 0,
.width = 1920,
.height = 1080,
.fps = 30,
.hdr_mode = SENSOR_MODE_LINEAR,
.bit_width = 12,
.bayer_pattern = BAYER_GBRG,
},

Note that no git repo exis for isp-imx. Only binary is provided as explained in pdf doc above. See example yocto recipe:
https://github.com/Freescale/meta-freescale/tree/master/recipes-bsp/isp-imx

IMHO these are the two only code where bit depth is set.
Experts, please correct if I am wrong!

0 件の賞賛
返信