Discussion Board

Page 1 of 2 12 LastLast
Results 1 to 15 of 28
  1. #1
    Registered User pierreq's Avatar
    Join Date
    Jan 2010
    Posts
    13
    Hi. I am using Maemo SDK5 on Ubuntu 10.4.
    I need to develop application using camera on Scratchbox.
    Can I redirect the webcam in the laptop so that it will be used as a device camera? How to do it? I have working camera in Ubuntu at /dev/video0. The scratchbox camera at /scratchbox/dev/video0 doesn't work when I try it from outside of scratchbox (mplayer tv:// -tv driver=v4l2:width=640:height=480:device=/scratchbox/dev/video0). When I run Xephyr I don't see camera entry, why?
    I am also getting this error when running af-sb-init.sh start
    http://pastebin.com/uUiQurAf

    I don't have the device all the time and I need this camera support in Scratchbox.
    I'm beginner.
    Last edited by pierreq; 2010-06-11 at 12:53.

  2. #2
    Nokia Developer Moderator divanov's Avatar
    Join Date
    Oct 2009
    Posts
    4,326
    /dev/video0 should be created inside scratchbox filesystem when you connect camera to the PC.
    This is not an error, but just create a directory
    mkdir -p /home/piotr/MyDocs/.camera

    It's actually quite strange since .camera was changed to DCIM some year ago.

  3. #3
    Registered User pierreq's Avatar
    Join Date
    Jan 2010
    Posts
    13
    Thank you for your reply.
    Why then the camera is not in the menu in Xephyr? http://img10.imageshack.us/img10/8158/screenshotjtf.png

    How to check that camera is working?

    Maybe this will be useful: http://pastebin.com/0MFnZaKR
    It is the full log of af-sb-init.sh start (the .camera problem was removed with command you suggested). I'm observing many other errors (with hal etc.)
    Last edited by pierreq; 2010-06-11 at 13:24.

  4. #4
    Nokia Developer Moderator divanov's Avatar
    Join Date
    Oct 2009
    Posts
    4,326
    Quote Originally Posted by pierreq View Post
    Why then the camera is not in the menu in Xephyr?
    Because camera-ui is not installed?
    Code:
    apt-get install camera-ui

  5. #5
    Registered User pierreq's Avatar
    Join Date
    Jan 2010
    Posts
    13
    Thank you. There is some error when I try to install the package:
    Code:
    [sbox-FREMANTLE_X86: ~] > fakeroot apt-get install camera-ui.*
    Reading package lists... Done
    Building dependency tree... Done
    Note, selecting osso-camera-ui-l10n-zhhk for regex 'camera-ui.*'
    0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
    1 not fully installed or removed.
    Need to get 0B of archives.
    After unpacking 0B of additional disk space will be used.
    Do you want to continue [Y/n]? Y
    Setting up camkeyd (0.0.2-2) ...
    start: Unable to send message: Connection refused
    dpkg: error processing camkeyd (--configure):
     subprocess post-installation script returned error exit status 1
    Errors were encountered while processing:
     camkeyd
    E: Sub-process /scratchbox/devkits/debian-etch/bin/dpkg returned an error code (1)
    and when I try to run camkeyd I got an error:
    Code:
    [sbox-FREMANTLE_X86: ~] > camkeyd
    system dbus init fail
    when the emulation is stopped and
    Code:
    hal init fail: (null)
    when it is started
    Last edited by pierreq; 2010-06-11 at 13:45.

  6. #6
    Nokia Developer Moderator divanov's Avatar
    Join Date
    Oct 2009
    Posts
    4,326
    Quote Originally Posted by pierreq View Post
    [sbox-FREMANTLE_X86: ~] > fakeroot apt-get install camera-ui.*
    You don't need dot and asterisk.

  7. #7
    Registered User pierreq's Avatar
    Join Date
    Jan 2010
    Posts
    13
    Yea that's strange but it doesn't work without it:
    Code:
    [sbox-FREMANTLE_X86: ~] > fakeroot apt-get install camera-ui  
    Reading package lists... Done
    Building dependency tree... Done
    E: Couldn't find package camera-ui
    and I have the repos:
    Code:
    [sbox-FREMANTLE_X86: ~] > cat /etc/apt/sources.list                 
    deb http://repository.maemo.org/ fremantle/sdk free non-free
    deb-src http://repository.maemo.org/ fremantle/sdk free
    deb http://repository.maemo.org/ fremantle/tools free non-free
    deb-src http://repository.maemo.org/ fremantle/tools free
    deb http://repository.maemo.org/ fremantle/4bc37c7c77ebe90177c050b805a8dc79 nokia-binaries
    deb http://repository.maemo.org/extras-devel/ fremantle free non-free
    deb-src http://repository.maemo.org/extras-devel/ fremantle free
    deb http://repository.maemo.org/extras/ fremantle free non-free
    deb-src http://repository.maemo.org/extras/ fremantle free

  8. #8
    Nokia Developer Moderator gnuton's Avatar
    Join Date
    Mar 2009
    Posts
    1,024
    It doesn't work because the camera-ui package cannot be downloaded from any repository.
    It's shipped with the device.
    Anyway this doesn't prevent you from making your camera application.

  9. #9
    Nokia Developer Moderator divanov's Avatar
    Join Date
    Oct 2009
    Posts
    4,326
    Ok, it's not in public repository for some reason.

  10. #10
    Registered User pierreq's Avatar
    Join Date
    Jan 2010
    Posts
    13
    Hi gulton.
    Your post made me lost. It is not consistent with previous indications given from divanov.
    Can you say more about it?

    I am complete beginner and I dont have the device at the moment to test. I must develop this application on Scratchbox.

  11. #11
    Nokia Developer Moderator divanov's Avatar
    Join Date
    Oct 2009
    Posts
    4,326
    camera-ui is only camera application, you don't need it for developing your own camera application. That's what Antonio was trying to say.

  12. #12
    Nokia Developer Moderator gnuton's Avatar
    Join Date
    Mar 2009
    Posts
    1,024
    Quote Originally Posted by divanov View Post
    camera-ui is only camera application, you don't need it for developing your own camera application. That's what Antonio was trying to say.
    correct! ;D

  13. #13
    Registered User pierreq's Avatar
    Join Date
    Jan 2010
    Posts
    13
    Thank you but I still have problem.
    I compiled the examples (including example_camera) from http://maemo.org/development/sdks/maemo_5_examples/

    I am getting the following error on scratchbox:
    Code:
    run-standalone.sh ./example_camera
    hildon-desktop[8952]: GLIB WARNING ** ClutterX11 - clutter_x11_texture_pixmap_sync_window: Got X error but pixmap is still set
    hildon-desktop[8952]: GLIB WARNING ** ClutterX11 - Unable to query pixmap: e0003d
    and on the emulator screen I see the message "Failed to initialize pipeline" from the file http://vcs.maemo.org/svn/maemoexampl...ample_camera.c.

    Last edited by pierreq; 2010-06-12 at 11:34.

  14. #14
    Nokia Developer Moderator divanov's Avatar
    Join Date
    Oct 2009
    Posts
    4,326
    The former two are warnings from hildon-desktop. You can put more g_critical calls to initialize_pipeline function to find exact place where GStreamer pipeline creation fails.

  15. #15
    Registered User pierreq's Avatar
    Join Date
    Jan 2010
    Posts
    13
    When I changed the driver to: #define VIDEO_SRC "videotestsrc"
    I got this error:

    Code:
    [sbox-FREMANTLE_X86: ~/examples/maemo-examples] > run-standalone.sh ./example_camera
    OIL: ERROR liboiltest.c 405: oil_test_check_impl(): function mas10_u8_mmx_2 in class mas10_u8_l15 failed check (9034 > 0) || (outside=0)
    example_camera[13526]: GLIB WARNING ** default - GST error: Internal data flow error., gstbasesrc.c(2378): gst_base_src_loop (): /GstPipeline:test-camera/GstVideoTestSrc:camera_src:
    streaming task paused, reason not-linked (-1)
    My video driver is basically this one: #define VIDEO_SRC "v4l2" (tested on mplayer outside scratchbox) when I use this in example_camera the error message in emulator is again : "Failed to initialize pipeline" and program doesn't terminate, the xterm shows:
    Code:
    [sbox-FREMANTLE_X86: ~/examples/maemo-examples] > run-standalone.sh ./example_camera
    example_camera[13671]: GLIB CRITICAL ** default - Couldn't create pipeline elements
    and the camera LED is still offline in laptop.
    Last edited by pierreq; 2010-06-12 at 11:43.

Page 1 of 2 12 LastLast

Similar Threads

  1. Simcard on Scratchbox
    By Pallavi_K in forum Nokia N9
    Replies: 3
    Last Post: 2010-06-01, 07:39
  2. Replies: 1
    Last Post: 2010-06-01, 07:32
  3. Replies: 9
    Last Post: 2010-01-20, 15:07
  4. QT4.6 and scratchbox incompatability
    By davidmct in forum Nokia N9
    Replies: 8
    Last Post: 2010-01-12, 09:47
  5. Not able to access bluetooth dongle from Maemo Scratchbox
    By nagendraravuri in forum Bluetooth Technology
    Replies: 0
    Last Post: 2008-04-21, 06:45

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved