I am using an imx8mn board in which i have the attached CSI pipeline configured.
I have enabled pattern in ar0144 image sensor and configured the deserializer and serializer appropriately.
I configure the route and formats with the below commands.
media-ctl -d /dev/media0 --link '"ds90ub960 2-003d":4 -> "csis-32e30000.mipi-csi":0 [1]' && media-ctl -V '"csis-32e30000.mipi-csi":0 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"csis-32e30000.mipi-csi":1 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"crossbar":2 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"crossbar":0 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"mxc_isi.0":1 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"ds90ub953 2-000c":1 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"ds90ub960 2-003d":0 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"ds90ub960 2-003d":4 [SBGGR12_1X12/1280x800 field:none]' && media-ctl -V '"AR0144 4-0010":0 [SBGGR12_1X12/1280x800 field:none]'
v4l2-ctl --device /dev/video0 --set-fmt-video=width=1280,height=800,pixelformat=BG12
And I could capture an image with the command below,
v4l2-ctl --device /dev/video0 --stream-mmap --stream-to=demo.raw --stream-count=1
But the image that was captured has a very low brightness.
1. The sensor output has been validated, and I am generating a valid test pattern directly from the sensor.
2. I have tried to disable the test pattern and tried to capture a live image. That too has the same brightness issue.
3. The image captured has a size of 2048000. However, upon analyzing the raw data, the maximum pixel value observed is 255. Does this indicate that the data is truncated to 8 bit somewhere in the pipeline?
Attaching the captured image for reference.
Hi,
Making the below change fixed the issue.
Hi,
Could you please share the register dump for isi register, on both kernel versions you are referring.
Regards,
Akshay
Hello,
for imx8mp, ar0144 is used as monochrome sensor, and uses 8mplus isp directly and bypasses the oncamera isp,
and on 8mplus it does support yuy2 format,
Regards
I am trying to port the kernel version from 5.4 to 6.9, with which I noticed there are changes in the NXP drivers.
I set the format as SBGGR12_1X12.
With the 5.4 kernel version, I capture image from the image sensor and I see proper image captured.
On examining the raw image captured from 5.4 kernel version, I see the below value.
*
01f35f0 0000 0000 0000 0000 f700 f700 f700 f700
01f3600 f700 f700 f700 f700 f700 f700 f700 f700
*
01f3730 f700 f700 f700 f700 0000 f700 0000 f700
01f3740 0000 f700 0000 f700 0000 f700 0000 f700
*
01f3870 0000 f700 0000 f700 f700 f700 f700 f700
01f3880 f700 f700 f700 f700 f700 f700 f700 f700
*
But With 6.9 kernel version, the image looks very dark.
I see the hexdump of captured image (6.9 version) as below,
*
01f3730 0f70 0f70 0f70 0f70 0000 0f70 0000 0f70
01f3740 0000 0f70 0000 0f70 0000 0f70 0000 0f70
*
01f3870 0000 0f70 0000 0f70 0f70 0f70 0f70 0f70
01f3880 0f70 0f70 0f70 0f70 0f70 0f70 0f70 0f70
*
01f39b0 0f70 0f70 0f70 0f70 0000 0f70 0000 0f70
01f39c0 0000 0f70 0000 0f70 0000 0f70 0000 0f70
*
01f3af0 0000 0f70 0000 0f70 0f70 0000 0f70 0000
01f3b00 0f70 0000 0f70 0000 0f70 0000 0f70 0000
*
Is the pixel value not getting shifted by 4 bits in case of RAW12 format in 6.9 kernel version imx drivers?
I also saw the below comment in file /drivers/media/platform/nxp/imx8-isi/imx8-isi-video.c
Could you please share the register dump for isi register, on both kernel versions you are referring.
Regards