Integrating custom camera sensor with i.MX8M

cancel
Showing results for 
Search instead for 
Did you mean: 

Integrating custom camera sensor with i.MX8M

111 Views
kunal_003
Contributor III

Hi NXP Team,

I am integrating the sony i.MX219 sensor with i.MX8M Plus. It is a RAW10 and RAW8 sensor, for now we are not targetting ISP and just focusing on capturing raw images.

Some Insights:

  1. We are using only MIPI lines and I2C lines in our design. There is no other reset, power down or master clock line associated with camera.
  2. As the camera is RAW sensor, I have added the support of RAW10 and RAW8 in ISI and MIPI CSI driver. (Changes are in attachment)
  3. Using the "mx8_v4l2_cap_drm.out" utility available in "unit-test/V4L2" to verify the RAW10/RAW8 dump. It was not supporting RAW10 and RAW8, so I have also modified the utility as well to support RAW format. (Changes are in attachment)

Command used for raw dump:

  1. ./mx8_v4l2_cap_drm.out -cam 1 -d /dev/video1 -num 1 -of -ow 640 -oh 480 -fr 30 -fmt GBRG10
  2. ./mx8_v4l2_cap_drm.out -cam 1 -d /dev/video1 -num 1 -of -ow 640 -oh 480 -fr 30 -fmt GBRG8

Attachment:

  1. dts.txt - Device tree node for sensor and MIPI CSI.
  2. imx219_logs.txt - Kernel mipi logs and media-ctl, v4l2 related device information
  3. 0001-Added-support-of-RAW10-and-RAW8-in-MIPI-CSI-and-ISI.patch - Changes in Kernel Driver
  4. 0001-Modified-mx8_v4l2_cap_drm-utility-for-adding-RAW-sen.patch - Changes in mx8_v4l2_cap_drm.c utility.
  5. 0.GBRG8_480p.raw - Image with RAW8 dump
  6. 0.GBRG10_480p - Image with RAW10 dump

Questions:

  1. In device tree, we have this "csis-hs-settle", "csis-clk-settle" and "csis-wclk" property. Can you please help us in identifying which value should be placed here? I found the Table for mipi clock frequency in forum, however, that was for i.MX7D and not i.MX8MPlus. Can you suggest which value should we keep here?
  2. For RAW10 I have modified in ISI and the depth is kept as 16 bit. Is it proper? Is anything needs to be added anywhere in kernel to add support for RAW10/RAW8 sensor apart form the changes I did?
  3. From the RAW dump file you can see that out of 480p I am only able to get the 120 lines. Rest of the image lines are totally black. Can it be due to hs-settle configuration?
  4. Is the utility appropriate to test the RAW dump, or some other commands/method should be used?

Any In-line pointers on above questions will be much helpful, as I am stuck with ISI and looking for suggestions ASAP. Thanks in advance.

 

Regards,

Kunal

0 Kudos
1 Reply

89 Views
kunal_003
Contributor III

Hi Team,

 

After adding the support for RAW in ISI and MIPI driver with some modifications I am able to capture the image. We can close this ticket.

 

Regards,

Kunal

0 Kudos