Analogue Camera Adapter V2.0A on Linux

I am trying to connect the Analog Camera Adapter (ACA V2.0A) with the Colibri Evaluation Board (Rev 3.2) using a Colibri T20 512 MB IT. I have compiled the latest revision of Kernel (kernel git branch “tegra” - tagged Colibri-T20_LXDE-Image_2.8b4.129-20181005) following this, and followed the details as described on here for enabling the analog camera support in Kernel.

1- Compile the kernel…OK

2- Deploy the kernel modules to rootfs folder of the previously extracted update package image

2- Prepare an SD card as described in Flashing Embedded Linux to Tegra…OK (I used this image with the updated rootfs)

3- Copy the kernel directly to sdcard (as i’m using a 2.8 linux image) with this

cp ~/linux-toradex/arch/arm/boot/zImage /media/<path-to-partition-1>/colibri-t20/

4- Update the module like this:

run setupdate
run prepare_ubi
run update_kernel
run update_rootfs

After restart VGA display shows nothing and through serial port I can see a console for login.
I attached the bootloader log from from restart:

log from restart

So I lost display and only see the console login through serial port. Any ideas?

Two observations:

  1. You seem to have a corrupt factory configuration block. Please use the cfgblock create U-Boot command as e.g. outlined here.
  2. You seem to have some I2C wiring issue as not even the RTC on your carrier board is detected.

Concerning your display: Are you talking about analogue VGA or a parallel RGB panel? You may need rewiring the display enable and/or backlight PWM signals as they are used by the parallel camera.

Config block seems to be ok now.

IC2 seems to be ok now (I had 2 jumpers disconnected from eval board)

I’m using VGA port from Colibri Evaluation Board.

Beyond having lost display image through VGA, if I try to load the kernel modules from serial console it seems to be ok.

I attached a new debug log from start to trying to load kernel modules.

log

Config block seems to be ok now.

Perfect.

IC2 seems to be ok now (I had 2 jumpers disconnected from eval board)

Very well.

I’m using VGA port from Colibri Evaluation Board.

Beyond having lost display image through VGA,

As mentioned above this is more or less as per design due to BL_ON signal being shared. Just remove the BL_ON jumper X8-46 and wire X7-46 to 3.3 volts (or any other GPIO of your liking).

if I try to load the kernel modules from serial console it seems to be ok.

So the camera is working now, right?

I attached a new debug log from start to trying to load kernel modules.

Looks good.

When I removed the BL_ON jumper the VGA started working.
The load of the kernel modules seems ok, but when I run

gst-launch v4l2src ! nv_omx_videomixer ! nv_gl_eglimagesink

I can’t see camera image. In the log I can see some issues with address 0x21 of I2C when kernel modules are loaded.

I attached a log and some pics.

[upload|ilDhh7iceuIRLvf7zU5fB9s9hJc=]

[upload|XgXWB2vf3RJhNrjgVMkIMrSvMpI=]

log

I can’t see camera image.

And what kind of an analogue camera source did you connect to which input? I assume you proceeded according to the following article on our developer website:

http://developer.toradex.com/knowledge-base/how-to-use-analogue-camera-module-on-embedded-linux

In the log I can see some issues with address 0x21 of I2C when kernel modules are loaded.

Whether or not that has to do with the ACA I am not quite sure. What does lsmod say?

The analogue camera and the ACA both are working because I test this setup on WEC7 image.

I assume you proceeded according to the following article on our developer website:

http://developer.toradex.com/knowledge-base/how-to-use-analogue-camera-module-on-embedded-linux

Yes, of course.

Here is the log again.

lsmod:

sh-4.4# lsmod
Module                  Size  Used by
tegra_v4l2_camera      17278  0
adv7280                 5066  1
videobuf2_dma_nvmap     3331  1 tegra_v4l2_camera
videobuf2_memops        2560  1 videobuf2_dma_nvmap
atmel_mxt_ts           17931  0

The analogue camera and the ACA both are working because I test this setup on WEC7 image.

Sure, but I don’t know nothing about any WEC7 and what kind of format and/or input it may or may not default to. So would you please be so kind and answer my previous question?

If you are not using any capacitive touch screen panel you may scrap the atmel_mxt_ts driver as it will just produce I2C errors making the reading of log files rather confusing.

Sure, but I don’t know nothing about any WEC7 and what kind of format and/or input it may > may not default to. So would you please be so kind and answer my previous question?

Sorry, I forgot to answear that. I’m using a NTSC signal camera connected to input number one.

If you are not using any capacitive touch screen panel you may scrap the atmel_mxt_ts
driver as it will just produce I2C errors making the reading of log files rather confusing.

Ok, here is a new log

And the shell output after starting gstreamer pipeline:

 sh-4.4# ./startCam.sh 
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
WARNING: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: 
Could not get parameters on device '/dev/video0'
Additional debug info:
../../../gst-plugins-good-0.10.31/sys/v4l2/v4l2src_calls.c(235): 
gst_v4l2src_set_capture (): 
/GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
system error: Invalid argument
Setting pipeline to PLAYING ...
New clock: GstSystemClock

(gst-launch-0.10:477): GLib-GObject-WARNING **: invalid cast from 
'GstBuffer' to 'GstNvOmxBuffer'

startCam.sh is just

gst-launch v4l2src ! nv_omx_videomixer ! nv_gl_eglimagesink

Hm, NTSC. I don’t think that is supported by default. I heard some rumors, the ADV7280 may be configured to support this as well but do not know what exactly is required. I guess you may search for NTSC in this very forum to get some more suggestions on that matter.

ok, what is the format supported by default under Linux? so I can test the module without making any change.

PD: if there are no camera source input, a test pattern shouldn’t be seen on the display? Because I even don’t see it.

Usually NTSC is supported out of box for iMX6 Modules but not for Tegra Modules, since there is an Issue as reported here. However there is a Workaround, which is described here.

ok.

PD: if there are no camera source input, a test pattern shouldn’t be seen on the display? Because > I even don’t see it.

Shouldn’t I see this pattern despite there is no a camera connected?

I am not sure what did you mean? So you expect a demo image, even if the camera is not connected or not working?

I’m talking about this answer where it says that despite the camera is not connected I should see a test pattern like

Ok, this is a test pattern coming for De-interlace chip on the Adapter. You can check the Adv7280 driver if the command for test pattern is sent or not. Alternatively you can send i2c commands to the ADV7280. The commands are described on the page 36 in the Ref. Manual of ADV7280.