LI-5M03 camera on Beagleboard-xM

LI-5M03 is a 5 MP camera module form Leopard Imaging. If you don’t know, Beagleboard-xM has a camera connector and a number of camera modules from Leopard Imaging can be connected to it. The main advantage of this type of cameras comparing to usual web cameras is speed. Cameras from LI are connected directly to the Camera Image Signal Processor module on DM3730 and, thus, data from camera can be handled much faster that in case of using USB camera driver.Linux kernel for Beagleboard-xM already has drivers for VGA, 2 MP and 3 MP camera modules from LI, but I’m interested in 5 MP module based on MT9P031 image sensor form Aptina. There are two cameras based on this image sensor – LI-5M03 (75$) and LI-5M03CS (79$). The only difference between these cameras is that LI-5M03 already has a lens installed and LI-5M03CS doesn’t have one but only CS mount connector (you can see unprotected image sensor on the picture). Thus, any lens with CS mount (or C mount with C->CS adapter) can be used. I decided to try lens H1214FICS from Computar (1/2″, monofocal, 12mm, f1.4, manual iris). As size of MT9P031 sensor is 1/2.5″ you have to use lens with size not less than 1/2.5″ (1/2″, 2/3″ etc.). Also you can use lenses with digital zoom or/and auto-iris, so for me LI-5M03CS is the best choice (for my project I need to use camera outdoor and I have to use auto-iris lens only). I also purchased camera extension cable (2″)from LI. It’s a bit expensive (35$), but camera module with external lens can be quite heavy and it’s not a good idea to put all the load to the camera connector on Beagleboard-xM, so I’ll make some external base frame to secure the camera + lens construction.

So, we have a camera module but what about drivers? The good news is that guys from Aptina implemented Linux driver (thanks guys!) and you can find it on Aptina’s github repository. However, this driver is for Angstrom kernel, but I merged it into the Jason Kridner’s Beagleboard validation 2.6.32 kernel and made a patch. If you want to add support for LI-5M03/LI-5M03CS please use the next patch:

0001-ARM-OMAP-beagle-add-support-for-MT9P031-Aptina-image-sensor.patch

You can try precompiled kernel image with MT9P031 driver added:

uImage

P.S. If you see some I2C errors in kernel traces like the next one:

i2c_omap i2c_omap.2: Arbitration lost
mt9p031 2-0048: Unable to detect sensor 

You need to add proper I2C lines initialisation (pullups) to the U-Boot. Normal traces should be as following:

mt9p031 2-0048: mt9p031 chip ID 1801

78 thoughts on “LI-5M03 camera on Beagleboard-xM

  1. I m using SAKOMAN(like Angstrom) on my Beagleboard-xm.i used Uimage (precompiled kernel image with MT9P031 driver added),given by you.
    but after that if i try to run facedetect program(Opencv sample program), it is giving me error:->

    can't capture video from CAM0

    previously this same prog. was running perfectly(using USB camera).

    can you tell me HOW to use Patch ,to add support for LI-5M03 (with my orginal Uimage )??

    Thank you

  2. Hi,

    1. Can you see "/dev/video0"?
    2. Can you see some strange linux boot logs in "/var/log/messages" like "i2c_omap i2c_omap.2: Arbitration lost"?
    3. Which kernel version are you using?
    4. Patch can be applied using "git apply " or "patch -p1 < " commands. This patch is for 2.6.32 Beagleboard validation kernel _only_.
    5. You can make your own patch for any linux kernel using files from Aptina github repo.

  3. Hi Max,

    Any idea about the frame capture rates with the LI cam? I use USB cam with 720MHz Beagleboard ( running Angstrom) and I get about 10fps with 320×240. With some Hough circle detection, it comes down to 4-5fps.

    Thank you.

  4. Hi Karthik,

    Frame rate is not high, it,s about 15fps @ 640×480, but i think it's some issue in MT9P031 configuration in linux driver. At the moment I'm trying to debug image sensor initialisation.

  5. Maulik,

    I'm not interesting in traces from your kernel as it doesn't have this driver, I asked about traces from my uImage.

    How to do patch for your kernel… It's easy! First of all analyze all the files from Aptina repo, then analyze linux kernel folders responsible for SOC cameras and BB related folders. After that copy necessary files to the corresponding folders and merge some makefiles and board-omap3beagle.c.

  6. Sounds great! Unfortunately, my C4 version does not support LI cam modules. I am thinking of writing my own driver to use the GPIO pins.

  7. Hello Max
    I'm working on BB_XM camera too and facing the low frame rate problem. Could you please point me about the solution of 30fps bug. Thank you.

  8. Hi stevegigijoe,

    Sure:

    https://docs.google.com/leaf?id=0BywvSqtpDKuCNTExZGZkMDEtZTMyNC00NDc2LTljN2EtZmIyODY4MDQyYmY1&hl=en

    There is a couple of unresolved problems (for example, even for 320×240 resolution v4l2 system driver still uses "better" HD capturing mode 1280×720) and driver looks _very_ raw. But I want to merge aptina driver to the 2.6.39 kernel and resolve all of the issues (+ add all supported resolutions and FPS modes) in new kernel.

  9. Hi max,
    I am sarin from India. I am also working with Beagle board xm, i was not founding an option to use the camera module. and
    really your blog made my job easy. can you please provide an image taken by LI-5M03CS? so i would get good idea about the clarity of the sensor. Is there any provision to attach more lens in front of H1214FICS?. What is the maximum resolution that can be provided by LI-5M03CS?

  10. Hi Max:

    I'm trying to do a kernel compile using OpenEmbedded and BitBake. I just keep getting the most obscure errors, it's driving me up the wall. What package are you using to coross compile. Can you point me in the direction of what build instructions you used to make your cross compile environment?

    Thanks
    Andrew

  11. Hi SaRin,

    Sensor is very good, you can attach any lens with CS mount – zoom/filter/microscope/telescope, any, it's just an image sensor like in digital cameras. Maximal resolution is 2592×1944 (5MP, please see datasheet for MT9P031). I'll add test images later.

  12. Hi Max:

    What I did was obtain the kernel source and then applied the patch. I made the kernel, on the beagle board, and the modules and am able to insmod mt9p031.ko. However, nothing happens when I insert the module into the kernel with the leopard board installed.

    Looking at the module code, I notice that on insertion the module is running i2c_add_driver() and not mt9p031_init_camera( const struct i2c_client *client).

    By my pinheaded understanding we should be running mt9p031_init_camera on insertion into the kernel.

    Am I wrong? If not, where do I get the client pointer from?

    Thanks!

    Andrew

  13. Hi Andrew,

    mt9p031_init_camera is called after we start working with sensor i.e. after opening corresponding device ("/dev/video0").

  14. Ah, that makes sense. Then what is causing the creation of /dev/video0? It seems to me the presence of the leopard board on I2c causes this to happen, but what exactly? I know it happens quite early, even before any run level inits are run. So is there another piece of software that on bootup is creating the /dev/video0 device and starting mt0p031_init_camera? It seems so as I don't see any obvious (to my pea brain) in the driver that does this.

  15. Please see board-omap3beagle.c and board-omap3beagle-camera.c in arch/arm/mach-omap2 folder (search for mt9p031). Also you can be interested in drivers/base/devtmpfs.c.

    P.S. Is there any reason to compile driver as a separate module?

  16. sir Im using Angstrom distribution on my BB xM and Im trying to get the LI5M03 works on it.

    I'm a pure beginner so can you tell me how to install the driver from the Aptina'repo since it seems that I can't hg/git anything coz there's no Mercurial package in Angstrom distro.

    Also if you can plz give me the command lines to install the driver. I know this is too much to ask but plz help coz I'm beginning to learn everything here

    Thank you very much for this post !!

  17. Hi max can you help me?
    I am having a DC auto iris lense from computar. I am not able to find any info about interfacing it with beagle board. please share if you have any info about this

  18. I tried the precompiled uImage you gave above. I used a simple show image openCV program and I got

    VIDIOC_QUERYMENU: Invalid argument

    The window showed up with 320-240 resolutions I think. But it's all pitch black.

    Can you tell me what's the problem? I can see there's /dev/video0 (Even when I hadn't plugged the li-5m03 in", also there's no "messages" in /var/log as well

    plz help

  19. Hi Tran Dinh Khoi,

    You have to patch your kernel. Just get sources for your kernel and try to apply patch from this post. If you can't see any messages in kernel logs please check your i2c configuration in U-Boot.

  20. Hi Max,
    How to install this driver to beagle board angstrom.
    please give a hint at least.
    can I install it to an existing built image? I am using build from narcissus

    Thanks in advance.

  21. i am using begalboard-xm with angstrom(kernel 2.6.32)
    now i have perches leopard imaging LI-5M03.
    i have replace the uimage with the uimage provided by you now i can see the video0 (at /dev/video0)
    now how can i test this camera

    Nilesh mane

  22. yes i have tested in m player its working.
    now i want to use this driver from my c code.

    i.e. i want to capture image from my c code.

    how can i do this.

  23. For those of you that don't get a /dev/video0, remember to add

    camera=lbcm5m03

    to uEnv.txt on the first SD card partition

    or run:

    setenv camera lbcm5m03

    in u-boot.

    This tells the kernel initialization which camera chip is connected.

  24. Hi mariusko,
    That helps,
    But do you know how to integrate the kernel module corresponding to the camera with angstrom build image, i meant to make our own uImage.

  25. Thanks to max for sharing this information this elaborately and
    Thanks for the author of Aptina driver too.
    The readme file has updated with kernal module integration help…

  26. It is already integrated. If the module is missing, run:

    opkg update
    opkg install kernel-module-mt9p031

    The only problem I have now is that it seems like something is stopping capture of more than 2048×1536 (3 mpx instead of 5 mpx).

  27. How can i use mt9p031 / mt9v032 on angstrom (linux kernel 2.6.37)

    i have tested board with prcompiled uimage given by u(2.6.32) it works very well.

  28. Well, I thought the build system already applied the patch, but maybe it does for 2.6.32 kernel. Is there something else you need from 2.6.37?

  29. Hello Max & Others
    Could anyone please tell where can I find driver for the Following Camera module board from LeopardImaging :
    The 2 Mega-Pixel LI-LBCM2M1
    The 1.3 Mega-Pixel LI-LBCM1M1
    The VGA Camera mdule LI-LBCMVGA
    I asked the company and they said that it could be found on beagleBoard forum .I guess this is the place here !
    Also , please tell for which Linux version it is compatible ?
    Regards
    Gideon

  30. Hi Max,

    i have patched 2.6.32 with "0001-ARM-OMAP-beagle-add-support-for-MT9P031-Aptina-image-sensor.patch" provided by you. and the output is as follows.

    please tell me what is wrong?

    user@ubuntu:~/beagle_valid/beagleboard-validation-linux$ patch -p1 < /mnt/hgfs/share/0001-ARM-OMAP-beagle-add-support-for-MT9P031-Aptina-image-sensor.patch
    patching file arch/arm/configs/omap3_beagle_defconfig
    Hunk #1 FAILED at 1.
    Hunk #2 FAILED at 1737.
    2 out of 3 hunks FAILED — saving rejects to file arch/arm/configs/omap3_beagle_defconfig.rej
    patching file arch/arm/mach-omap2/Makefile
    Reversed (or previously applied) patch detected! Assume -R? [n]
    Apply anyway? [n]
    Skipping patch.
    1 out of 1 hunk ignored — saving rejects to file arch/arm/mach-omap2/Makefile.rej
    The next patch would create the file arch/arm/mach-omap2/board-omap3beagle-camera.c,
    which already exists! Assume -R? [n]
    Apply anyway? [n]
    Skipping patch.
    1 out of 1 hunk ignored
    patching file arch/arm/mach-omap2/board-omap3beagle.c
    Hunk #1 succeeded at 401 with fuzz 2 (offset 330 lines).
    Hunk #2 succeeded at 470 with fuzz 1 (offset 62 lines).
    Hunk #3 FAILED at 543.
    Hunk #4 FAILED at 587.
    Hunk #5 FAILED at 709.
    Hunk #6 FAILED at 763.
    4 out of 6 hunks FAILED — saving rejects to file arch/arm/mach-omap2/board-omap3beagle.c.rej
    patching file drivers/media/video/Kconfig
    Hunk #1 succeeded at 832 (offset 16 lines).
    patching file drivers/media/video/Makefile
    Hunk #1 succeeded at 79 (offset 1 line).
    patching file drivers/media/video/mt9p031.c
    patching file include/media/mt9p031.h
    patching file include/media/v4l2-chip-ident.h
    Hunk #1 FAILED at 267.
    1 out of 1 hunk FAILED — saving rejects to file include/media/v4l2-chip-ident.h.rej
    user@ubuntu:~/beagle_valid/beagleboard-validation-linux$

  31. Hi all,

    Sorry for the long delay, I was on holidays. Ok, what about mt9p031 driver. The good news is that according to the messages from Beagleboard google group mt9p031 driver implemented/improved by Javier Martin is on the final stage of development (it can be found in Laurent Pinchart's tree). And it seems that soon (well, may be not in the next release) this driver will appear in linux kernel mainline. Thus, I decided to stop working with drivers from Aptina repo and wait for the proper driver in kernel.

    Cheers,
    Max.

  32. Hmm, where is that Laurent Pinchart's tree? I can't find it (at least one that contains the patches). And where is the group post that says this?

  33. But his tree is maybe not published somewhere. Seems I need to try to build the patches on top of some other kernel and test the Ångström build scripts that takes forever…

  34. As I said before, I'm not working with these patches now, I'm waiting for the final version of mt9p031 drivers for mainline linux. If you are really interested in patches, I guess it's better to ask Javier Martin (javier.martin@vista-silicon.com) about current status of driver.

  35. Dear Max Galemin,

    I tried your uImage binary on my Beagleboard XM and it works quite well, however i want to make some adjustments in the driver, so i prefer the driver to be a kernel module instead of fixed into the kernel image.

    I took the kernel source from Jasons validation kernel(2.6.32) and applied your patch. I compiled them and the camera works just like your uImage, so far so good.

    Then i changed the SOC_CAMERA_MT9P031=y to =m, recompiled to kernel, compiled the modules, copied to module to my rootfs.

    When i try to insert the mt9p031.ko it does like:

    root@beagleboard:/lib/modules/2.6.32/kernel/drivers/video# insmod mt9p031.ko
    root@beagleboard:/lib/modules/2.6.32/kernel/drivers/video#

    No message is put, not even in dmesg and /dev/video0 is NOT present.

    Do i need to put some arguments after insmod? Do i need to manually mknod
    the /dev/video char device?

    Kind regards,
    Mathijs van den Berg
    Mathijs

    • Hi Mathijs,

      Are you trying to insert mt9p031.ko module to the clean 2.6.32 kernel from Jason’s repo or to the kernel patched with patch from this post?

      Cheers,
      Max.

      • Hi Max,

        I try to insert the mt9p031.ko from the clean 2.6.32 WITH the patch applied ( 0001-ARM-OMAP…… ). After the patch, i modified the omap3_beagle_defconfig file, and changed the SOC_CAMERA_MT9P031 line to ‘=m’ instead of ‘=y’ so it will be available as kernel module instead of baked into the kernel.

        FYI: As i noted in my first post, i also tried compiling the kernel with the patch applied (0001-ARM…) without changing anything, and that one worked fine, just like your uImage.so there is nothing wrong with the compilation afaik.

        Greets,

        Mathijs

  36. Attractive section of content. I just stumbled upon your web site and in accession capital to assert that I acquire in fact enjoyed account your blog posts. Any way I’ll be subscribing to your feeds and even I achievement you access consistently fast.

  37. Just tried with image from narcissius added the camera= in uEnv.txt and the module is automatically loaded on boot.. however when i gst-launch v4l2src ! video/x-raw-yuv,widht=640,height=480 ! xvimagesink i get a black output..

    im on 2.6.32 angstrom kernel which includes the module..

    Any ideas as to why i am not getting any picture at all. ?

  38. Getting go through this I assumed it absolutely was extremely beneficial. I value you taking time and work to place this informative article with each other. I as soon as once again locate myself paying approach to significantly time the two studying and commenting. But so what, it absolutely was nonetheless worthwhile!

  39. Hi,
    I just got this sensor and I’m really confused about what combination of kernel to use.
    I downloaded the OpenEmbedded distribution, is this correct to use?
    I need to know how to apply this patch. Does the patch itself contain the driver or the commands to download the driver or do I need to have the driver and the patch in the same directory? What directory do I need to run the patch from?
    If I compile successfully or use your pre-compiled uimage.bin, what rootfs do I need to pair it with? Angstrom? Will it appear as a webcam once it’s installed? Do I just need to find an application to test it with?
    Thanks,
    Please be as detailed as possible, I’ve only used linux for a month. Thanks,

  40. Hi Max,

    Have you tried to make this work on 3.2-rc2 kernel?

    I’ve got it to compile for my BeagleBoard-xM rev C, using Ubuntu. I have the driver loaded and it creates a video device, but when I go to try to capture an image I get errors from VLC, mplayer, yavta, streamer, and a bunch of other tools I’ve tried.

    Any suggestions on debugging this?

    Thanks

    • Hi misham,

      mt9p031 driver is already in kernel mainline (which is very good) but I didn’t try to compile 3.2 (rc) yet as atm I’m busy with another project. I’m planning to play with a kernel and to update my buildroot repo after 3.2 is released (i.e. after a couple of months).

      Cheers,
      Max.

  41. Hi Group.

    I’m running kernel 2.6.39 on bbxm with LI-5M03, attempting to run v4l2 video capture example found at http://v4l2spec.bytesex.org/spec/capture-example.html.

    Attempting the binary w -u flag (selects user pointer buffers) gets:
    VIDIOC_STREAMON error 22, Invalid argument. Memory map buffer request fails similarly.

    VIDIOC_ENUM_INPUT gives Current input: camera.

    Querying /dev/video1 with ioctl VIDEOC_QUERYCAP gives:
    vcap: driver name: ispvideo
    vcap: device name: OMAP3 ISP CCP2 input
    vcap: businfo name: media
    vcap: version name: 0.0.1
    vcap: capabilties: 4000002 (streaming, input capture device)

    I’m pretty sure driver is present, dmesg shows:
    [ 5.209655] omap-iommu omap-iommu.0: isp: version 1.1
    [ 5.215118] omap3isp omap3isp: hist: DMA channel = 0
    [ 5.227813] omap3isp omap3isp: isp_set_xclk(): cam_xclka set to 21600000 Hz
    [ 5.244506] mt9p031 2-0048: Detected a MT9P031 chip ID 1801
    [ 5.259063] omap3isp omap3isp: isp_set_xclk(): cam_xclka set to 0 Hz

    Does anyone see any clue as to why STREAMON request fails?
    Can anyone say if this example program should or should not be able to run if driver is installed?
    Is the 0 Hz for cam_xclka a problem?

    Thanks for any help.

  42. Hi All,

    I am very new to U-Boot for Beagle Board XM.
    I have Beagle Board XM with LI-5M03 Camera module from leopard.

    Using Beagle board XM U-Boot, i would like to detct attached I2C device.
    U-Boot is having I2C command utility where it can the detect attached
    I2C device on I2C bus as per my understanding.

    Board is having Camera module attached on P10 Pin header. I have ran the
    following commands to detect the Camera module, but this utility not able
    to detect camere module.

    1. i2c dev [i2c bus number] – set i2c bus number
    2. i2c probe – detect attached device and return address of that device

    Can any one tell me, what can be reason? is there any hardware problem?

    I have gone throught the Beagle board XM schematic, where board is not populated
    with pull-ups resister on I2C2 bus. (R160 and R155) is this a reson, board not able
    detect i2c device?

    Please, find the logs for more detail.

    #################################################################
    Texas Instruments X-Loader 1.5.0 (Mar 27 2011 – 17:37:56)
    Beagle xM
    Reading boot sector
    Loading u-boot.bin from mmc

    U-Boot 2011.03-rc1-00000-g9a3cc57-dirty (Apr 01 2011 – 17:41:42)

    OMAP36XX/37XX-GP ES2.1, CPU-OPP2, L3-165MHz, Max CPU Clock 1 Ghz
    OMAP3 Beagle board + LPDDR/NAND
    I2C: ready
    DRAM: 512 MiB
    NAND: 0 MiB
    MMC: OMAP SD/MMC: 0
    *** Warning – readenv() failed, using default environment

    In: serial
    Out: serial
    Err: serial
    Beagle xM Rev C
    No EEPROM on expansion board
    Die ID #526c00029ff80000016830100f02902a
    Hit any key to stop autoboot: 0
    OMAP3 beagleboard.org # i2c dev 0
    Setting bus to 0
    OMAP3 beagleboard.org # i2c probe
    Valid chip addresses: 48 49 4A 4B
    Excluded chip addresses: 00
    OMAP3 beagleboard.org # i2c dev 1
    Setting bus to 1
    OMAP3 beagleboard.org # i2c probe
    Valid chip addresses:
    Excluded chip addresses:
    OMAP3 beagleboard.org # i2c dev 2
    Setting bus to 2
    OMAP3 beagleboard.org # i2c probe
    Valid chip addresses:
    Excluded chip addresses:
    OMAP3 beagleboard.org # i2c dev 3
    Setting bus to 3
    Bad bus: 3
    Failure changing bus number (-1)
    ################################################################

    Thanks in advance for reading this.
    Please, do hlep me to solve this proble.

    Thanks,

  43. We are trying to use a LBCM5M1 leopard imaging board on a Beagleboard
    xm.
    To get Angstrom on the BB we took a precompiled uImage from
    http://blog.galemin.com/2011/04/li-5m03-camera-on-beagleboard-xm/
    MLO, uBoot.bin files and the root file system from
    http://www.angstrom-distribution.org/demo/beagleboard/
    When the camera is attached, /dev/video0 doesn’t appear. We made the
    following change in the uEnv.txt file:
    camera=”lbcm5m1″ but this doesn’t work. We also installed the kernel
    module for the mt9p031 driver from Angstrom repository, but still /dev/
    video0 doesn’t appear.
    Please help us out. We are new to this and extremely frustrated!! We
    would be grateful for any help!!
    here is the raw data we got when booting the beagleboard
    http://pastebin.com/gfRum16q
    Gaurav
    Rohit

  44. Hello everybody,

    i have set up a beagleboard xm with the mt9p031 sensor. In laboratory it works fine, but outside i have problems with the brightness. My pics are to bright
    I’m not sure whether my i2c bus works correctly.

    /****************************************************************************************/
    /* My start-up has following problem “timed out in wait_for_bb: I2C_STAT=1000″ */
    /****************************************************************************************/
    Loaded environment from uEnv.txt
    Importing environment from mmc …
    Loading file “/boot/uImage” from mmc device 0:2 (xxa2)
    U-Boot SPL 2011.12-00010-ga3eb89c (Jan 29 2012 – 14:53:43)
    Texas Instruments Revision detection unimplemented
    OMAP SD/MMC: 0
    timed out in wait_for_bb: I2C_STAT=1000
    reading u-boot.img
    reading u-boot.img

    Has my u-boot.img or my uImage this problem?

    /****************************************************************************************/
    /* My mplayer has following problem “v4l2: ioctl set mute failed: Invalid argument*/
    /****************************************************************************************/

    root@beagleboard:~# mplayer -fps 50 -vf scale=259:195 tv:// -tv driver=v4l2:d
    evice=/dev/video0:height=2594:width=1944:brightness=0
    MPlayer UNKNOWN-4.3.3 (C) 2000-2010 MPlayer Team

    Playing tv://.
    TV file format detected.
    Selected driver: v4l2
    name: Video 4 Linux 2 input
    author: Martin Olschewski
    comment: first try, more to come ;-)
    v4l2: your device driver does not support VIDIOC_G_STD ioctl, VIDIOC_G_PARM was used instead.
    Selected device: omap3/mt9p031//
    Capabilities: video capture streaming
    supported norms:
    inputs: 0 = camera;
    Current input: 0
    Current format: YUYV
    tv.c: norm_from_string(pal): Bogus norm parameter, setting default.
    v4l2: ioctl enum norm failed: Invalid argument
    Error: Cannot set norm!
    Selected input hasn’t got a tuner!
    v4l2: ioctl set mute failed: Invalid argument
    v4l2: ioctl query control failed: Invalid argument
    v4l2: ioctl query control failed: Invalid argument
    Opening video filter: [scale w=259 h=195]
    ==========================================================================
    Opening video decoder: [raw] RAW Uncompressed Video
    Movie-Aspect is undefined – no prescaling applied.
    [swscaler @ 0xecf570] BICUBIC scaler, from yuyv422 to yuyv422 using C
    VO: [xv] 260×195 => 260×261 Packed YUY2
    [VO_XV] Shared memory not supported
    Reverting to normal Xv.
    [VO_XV] Shared memory not supported
    Reverting to normal Xv.
    Selected video codec: [rawyuy2] vfm: raw (RAW YUY2)
    ==========================================================================
    Audio: no sound
    FPS forced to be 50.000 (ftime: 0.020).
    Starting playback…
    V: 0.3 161/161 0% 2456% 0.0% 0 0

    MPlayer interrupted by signal 2 in module: filter_video
    V: 0.3 162/162 0% 2455% 0.0% 0 0
    v4l2: ioctl set mute failed: Invalid argument
    v4l2: 163 frames successfully processed, 713 frames dropped.

    I’ve reduced the brightness with v4l2 to the value 0, but the pics are too bright.
    What can i do to decrease the brightness for outside use? Is it a beagle board xm problem or is it an optical problem? Ideas?

  45. Hi Max,

    i have an objective/lens from enico ??? (I don’t know the exact model.). It has a 4-pin connector. I think it has two inductivities. One has an resistance of about 200 ohms and the other of 1100 ohms. Could it be the drive and damping coil? The damping coil is very sensitive to voltage and current changes. I’m not sure whether the damping coil could be used for set the brightness?

    Regards, HKN

  46. Max,

    I am a very green Linux and beagle-board user. I have installed Ubuntu 11.04 with kernel 3.0.4 -x3 installed on beagle board xM Rec C. with a LI-5M03CS. I have set that parameters camera=lbcm5m03 to uEnv.txt on the first SD card partition and as far as i can tell installed the drivers. I have not been able to get MPlayer to recognize the LI-5M03CS as video0. If i plug in a usb camera i can capture screen shots and get video in both mplayer and cheese this shows that the drivers are working correct?

    Do you have nay sugestions

    Cheers
    -Nathan

  47. The mt9p031 is a raw sensor. So, it gives Raw Bayer output, so You need to use the complete OMAP3ISP pipeline(i.e CCDC->Previewer-> Resizer)
    But, as in the highlighted text, you are setting the pipeline for just CCDC, and you are not using Previewer and Resizer. Basically previewer is the component which will do the, format conversion and other stuff. So, you need to change your media-ctl commands. FYI, I am providing the media-ctl commands .

    $ ./media-ctl -r -l ‘”mt9p031 2-0048″:0->”OMAP3 ISP CCDC”:0[1], “OMAP3 ISP CCDC”:2->”OMAP3 ISP preview”:0[1], “OMAP3 ISP preview”:1->”OMAP3 ISP resizer”:0[1], “OMAP3 ISP resizer”:1->”OMAP3 ISP resizer output”:0[1]‘
    $./media-ctl -f ‘” mt9p031 2-0048″:0[SGRBG12 320x240], “OMAP3 ISP CCDC”:2[SGRBG8 320x240], “OMAP3 ISP preview”:1[UYVY 320x240], “OMAP3 ISP resizer”:1[UYVY 320x240]‘

    And you need to take output from “OMAP3 ISP resizer output” pad.

  48. Hi Max,
    I’m using the LI-5M03 (not the CS one) with angstrom on a 2.6.32 kernel. I need to use it outdoor. The indoor images are fine (i can get it ok by adjusting the gains) all i can get outdoor is a white image (too bright) even with gains and exposure set to minimal. Do you know if is there any way to reduce even more the brightness, or do i need to use an auto-iris lens?
    Thank you very much.

Leave a Reply