Hi again,
I’d like to summarize my findings so far.
Work Environment:
Kernel: 3.7.10-x13 → git://github.com/RobertCNelson/stable-kernel.git
Ubuntu: 12.10 (with minimal lxde desktop) → http://rcn-ee.net/deb/rootfs/quantal/ubuntu-12.10-console-armhf-2013-06-14.tar.xz
Webcam: LI5M03 (mt9p031) enabled in uEnv.txt by adding the following line: camera=li5m03
At first I tried the camera with mplayer and I confirm that the camera video is on my monitor screen connected to BB-xM via HDMI.
The configuration used:
sudo media-ctl -r -l ‘“mt9p031 2-0048”:0->“OMAP3 ISP CCDC”:0[1]’
sudo media-ctl -l ‘“OMAP3 ISP CCDC”:2->“OMAP3 ISP preview”:0[1]’
sudo media-ctl -l ‘“OMAP3 ISP preview”:1->“OMAP3 ISP resizer”:0[1]’
sudo media-ctl -l ‘“OMAP3 ISP resizer”:1->“OMAP3 ISP resizer output”:0[1]’
sudo media-ctl -V ‘“mt9p031 2-0048”:0 [SGRBG10 640x480]’
sudo media-ctl -V ‘“OMAP3 ISP CCDC”:2 [SGRBG10 640x480]’
sudo media-ctl -V ‘“OMAP3 ISP preview”:1 [UYVY 640x480]’
sudo media-ctl -V ‘“OMAP3 ISP resizer”:1 [UYVY 640x480]’
The command Iine:
#sudo mplayer tv:// -tv driver=v4l2:device=/dev/video6:outfmt=uyvy:width=640:height=480
Then I started trying to use GStreamer and faced with the following issues.
#sudo gst-launch v4l2src device=/dev/video6 ! ffmpegcolorspace ! filesink location=./test.data
#sudo gst-launch v4l2src device=/dev/video6 ! ffmpegcolorspace ! fbdevsink
#sudo gst-launch v4l2src device=/dev/video6 ! ffmpegcolorspace ! autovideosink
#sudo gst-launch v4l2src device=/dev/video6 ! ffmpegcolorspace ! ximagesink
These command lines give the following error:
ERROR: Pipeline doesn’t want to pause.
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Device ‘/dev/video6’ cannot capture in the specified format
Additional debug info:
gstv4l2object.c(2218): gst_v4l2_object_set_format (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
Tried to capture in YU12, but device returned format UYVY
#sudo gst-launch v4l2src device=/dev/video6 ! ffmpegcolorspace ! cacasink
#sudo gst-launch v4l2src device=/dev/video6 ! ffmpegcolorspace ! dfbvideosink
These command lines give the following error:
ERROR: Pipeline doesn’t want to pause.
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Device ‘/dev/video6’ cannot capture in the specified format
Additional debug info:
gstv4l2object.c(2218): gst_v4l2_object_set_format (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
Tried to capture in RGB3, but device returned format UYVY
Then I tried to run the command line:
#sudo gst-launch v4l2src device=/dev/video6 ! video/x-raw-yuv,format=(fourcc)UYVY ! ffmpegcolorspace ! fbdevsink
#sudo GST_DEBUG=3 gst-launch v4l2src device=/dev/video6 ! video/x-raw-yuv,format=(fourcc)UYVY ! ffmpegcolorspace ! fbdevsink
I got the following:
v4l2 gstv4l2object.c:1105:gst_v4l2_object_fill_format_list: got 4 format(s):
v4l2 gstv4l2object.c:1111:gst_v4l2_object_fill_format_list: YU12 (emulated)
v4l2 gstv4l2object.c:1111:gst_v4l2_object_fill_format_list: YV12 (emulated)
v4l2 gstv4l2object.c:1111:gst_v4l2_object_fill_format_list: BGR3 (emulated)
v4l2 gstv4l2object.c:1111:gst_v4l2_object_fill_format_list: RGB3 (emulated)
basesrc gstbasesrc.c:2830:gst_base_src_start: error: Could not negotiate format
ERROR: Pipeline doesn’t want to pause.
ERROR: from element /GstPipeline:pipeline0/GstV4l2Src:v4l2src0: Could not negotiate format
LI5M03 (mt9p031) supports UYVY / YUYV outputs only and it seems gst-v4l2 is expecting a source in one of the followings: YU12, YV12, BGR3 or RGB3. Surprisingly I read that TI DSP supports only UYVY input which is exactly what LI5M03 generates as an output. So, I need your comment/idea/opinion to proceed in order to get the issues resolved.
Any help? Your reply will be greatly appreciated.
In addition, mplayer seems working with LI5M03 but also some warnings seen while running the command. I have copied them below.
Regards,
Ozkan.
#sudo mplayer tv:// -tv driver=v4l2:device=/dev/video6:outfmt=uyvy:width=640:height=480
Selected driver: v4l2
name: Video 4 Linux 2 input
author: Martin Olschewski olschewski@zpr.uni-koeln.de
comment: first try, more to come 
v4l2: ioctl get standard failed: Invalid argument
Selected device: OMAP3 ISP resizer output
Capabilities: video capture streaming
supported norms:
inputs: 0 = camera;
Current input: 0
Current format: unknown (0x0)
tv.c: norm_from_string(pal): Bogus norm parameter, setting default.
v4l2: ioctl enum norm failed: Inappropriate ioctl for device
Error: Cannot set norm!
Selected input hasn’t got a tuner!
v4l2: ioctl set mute failed: Inappropriate ioctl for device
v4l2: ioctl query control failed: Inappropriate ioctl for device
v4l2: ioctl query control failed: Inappropriate ioctl for device
v4l2: ioctl query control failed: Inappropriate ioctl for device
v4l2: ioctl query control failed: Inappropriate ioctl for device
[VO_XV] It seems there is no Xvideo support for your video card available.
[VO_XV] Run ‘xvinfo’ to verify its Xv support and read
[VO_XV] DOCS/HTML/en/video.html#xv!
[VO_XV] See ‘mplayer -vo help’ for other (non-xv) video out drivers.
[VO_XV] Try -vo x11.