Are there linux camera drivers for imx8?
The following module works out of the box with the Apalis iMX8 QM 4.9.51 BSP. (Note that you need the V1.1B as the Apalis iMX8 QM is not able to provide a master clock)
AFAIK no other camera driver is part of the kernel sources, so one would have to implement a driver for anything else.
When trying to take a still photo with the OV5640 V1.1B and Linux version 4.9.51-imx_4.9.51_8qm I run following command (as in High performance, low power Embedded Computing Systems | Toradex Developer Center) :
gst-launch-1.0 v4l2src num-buffers=1 device=/dev/video1 ! jpegenc ! filesink location=test.jpg
However I am getting error:
Setting pipeline to PAUSED ... Pipeline is live and does not need PREROLL ...[ 795.704643] mxc_isi.1: Can't find subdev Setting pipeline to PLAYING ... New clock: GstSystemClock [ 795.717861] mxc_isi.1: Can't find subdev [ 795.721966] mxc_isi.1: Can't find subdev [ 795.726107] mxc_isi.1: Can't find subdev [ 795.730220] mxc_isi.1: Can't find subdev [ 795.734323] mxc_isi.1: Can't find subdev [ 795.738856] (null): mxc_isi_source_fmt_init, No remote pad found! [ 795.744987] input fmt RGBP [ 795.747701] output fmt YUYV [ 795.750535] mxc-isi 58110000.isi: input_size(0,0), output_size(200,320) [ 795.757186] mxc_isi.1: Can't find subdev
Am I doing something wrong? Thanks in advance.
Have you done any changes to the Software? If yes, could you provide these changes?
Could you provide also the dmesg log in file?
What is the output of
v4l2-ctl -D -d /dev/video1?
I didn’t do any changes to the code, it is the image shipped with the board (Linux apalis-imx8 4.9.51-imx_4.9.51_8qm_beta2_toradex)
Output from the command:
root@apalis-imx8:~# v4l2-ctl -D -d /dev/video1 Driver Info (not using libv4l2): Driver name : mxc-isi Card type : mxc-isi Bus info : platform:58110000.isi.1 Driver version: 4.9.51 Capabilities : 0x84201000 Video Capture Multiplanar Streaming Extended Pix Format Device Capabilities Device Caps : 0x04201000 Video Capture Multiplanar Streaming Extended Pix Format
Could you provide the dmesg log in a file? Thanks.
Edited my prev msg. Thanks
Thanks for the files. We will look into this issue and come back to you in some days.
@marcel.tx Thank you for the log. What is different in mine is the lack of messages:
[ 2.669280] camera ov5640_mipi is found, ret: 0 [ 2.676461] mxc-mipi-csi2 58247000.csi: mipi_csi2_probe [ 2.698864] mxc-mipi-csi2 58247000.csi: lanes: 2, name: mxc-mipi-csi2.1
I tried it with two V1.1B cameras, no success with both. Please let me know if you know anything that could help.
And you are on the Apalis Evaluation Board or Ixora? I assume you double checked the flat cable and it’s contacts/pinning. By chance you have an Apalis iMX6D/Q you may try?
@marcel.tx It is on Ixora board. Double checked the ribbon cable. I also checked on Ixora with TK1 and the camera module worked.
Strange. And you are really running the exact same U-Boot, SCFW, device tree and Linux kernel?
@marcel.tx Yes, it is the default image shipped with the board. No changes to U-Boot, SCFW, device tree and Linux kernel.
Well, I’m not quite sure what may have shipped at one point or another with this early access stuff. As it works with Apalis iMX6 it does not look like a hardware issue unless your module somehow does not have a properly working oscillator despite it being a V1.1B revision.
@marcel.tx Thanks for your inputs. Do you know if there is an easy way to verify the camera discovery procedure at boot time (e.g. using oscilloscope)?
I guess one could even toggle the power/reset GPIOs from within U-Boot and subsequently do an active
@marcel.tx I connected logic analyzer to all GPIOs and I2C bus connected to the camera. When booting I can’t see any communication, except for CAM_IC_DETECT and I2C lines going to ‘High’ level. Running i2cdetect on the dev/i2c-2 seems to drive the SCL and SDA pins correctly.
The thing that looks worrying is the CSI_GPIO0_RST (iMX GPIO1) being low all the time…
This seems to be strange. Just one thing, could you create the SD card using the image mentioned on this site and check again, if you still have this issue?
@jaski.tx I temporarily stopped working with the iMX8 board. I will update you when I will come back and still have this problem. Thank you for your help!