[yocto] [meta-raspberrypi] Using the camera

Alex J Lennon ajlennon at dynamicdevices.co.uk
Sun Jun 1 14:35:33 PDT 2014


On 01/06/2014 22:22, Alexandru Vaduva wrote:
> This are indeed some very good news Alex J Lennon.
> I have some questions, but those maybe can be answered by the
> maintainers of the meta-raspberrypi layer:
> Why was this change done?
>      -PREFERRED_PROVIDER_virtual/egl ?= "vc-graphics-hardfp"
>      -PREFERRED_PROVIDER_virtual/libgles2 ?= "vc-graphics-hardfp"
>      +PREFERRED_PROVIDER_virtual/egl ?= "userland"
>      +PREFERRED_PROVIDER_virtual/libgles2 ?= "userland"
> How it may affect other applications?
> Andrei: Do you have any input on this?
>
>

The maintainers would know better than I, but if I had to guess, it
might have been to replace the binary
only proprietary licensed vc-graphics with the replacement userland
source code when Broadcom opened it,

i.e. http://www.raspberrypi.org/open-source-arm-userspace/

I'm going to have a go at compiling userland on Raspbian to see if it
might be a cross-compilation issue.

Cheers,

Alex

> Thanks,
> Alex
>
>
>
>
>
> On Mon, Jun 2, 2014 at 12:07 AM, Alex J Lennon
> <ajlennon at dynamicdevices.co.uk <mailto:ajlennon at dynamicdevices.co.uk>>
> wrote:
>
>
>     On 26/05/2014 19:40, Alexandru Vaduva wrote:
>     > It`s really hard to just offer impressions or suggestion.
>     > Also I agree with the fact that the camera is ok cause I also tested
>     > it with raspbian. No problems there.
>     > But never the less I hope to keep me posted on any progress and
>     > observations.
>     > When I will have the time I will try some things of my own.
>     >
>     > Alex
>
>     I've made a certain amount of progress with this Alex.
>
>     1) I've been comparing Raspbian with a Yocto meta-raspberrypi armhf
>     build, as raspivid works for me with Raspbian, but not with my
>     meta-raspberrypi poky build.
>
>          To cut a long story short the raspivid in Raspian is v1.3.9
>     and it
>     comes from raspiberrypi/firmware which as you know is the binary-only
>     release
>
>          If I copy only the raspivid executable from the Raspbian
>     installation over to the Yocto installation then raspivid runs up ok,
>     shows the cam onscreen and so forth.
>          (so shared libs, config and so forth all would seem to be fine)
>
>          I tried building the same v1.3.9 version of raspivid from the
>     userland repository, but I get the same error as before,
>
>     root at raspberrypi:~# raspivid -o test
>     mmal: mmal_component_create_core: could not find component
>     'vc.ril.camera'
>     mmal: Failed to create camera component
>     mmal: main: Failed to create camera component
>     mmal: Failed to run camera app. Please check for firmware updates
>
>          So it looks to me as though there's something different
>     between the
>     firmware binary release and the more recent open-sourced userland code
>
>         I can show that by just doing my armhf build then pulling down the
>     binary, which runs up,
>
>
>     https://github.com/raspberrypi/firmware/raw/master/hardfp/opt/vc/bin/raspivid
>
>         Looking back through the meta-raspberrypi commit logs it looks as
>     though userland replaced vc-graphics-hardfp back at 33d2e1d7
>
>     -PREFERRED_PROVIDER_virtual/egl ?= "vc-graphics-hardfp"
>     -PREFERRED_PROVIDER_virtual/libgles2 ?= "vc-graphics-hardfp"
>     +PREFERRED_PROVIDER_virtual/egl ?= "userland"
>     +PREFERRED_PROVIDER_virtual/libgles2 ?= "userland"
>
>         If I build with vc-graphics-hardfp I get a raspivid that runs up
>
>     2) I was wrong about the Bellagio support. Instead there are a set of
>     library mappings in /etc/xdg/gstomx.conf
>       These need to be modified to point to libopenmaxil.so not the
>     bellagio
>     library
>
>     e.g.
>
>     [omxh264enc]
>     type-name=GstOMXH264Enc
>     core-name=/opt/vc/lib/libopenmaxil.so
>     component-name=OMX.broadcom.video_encode
>     rank=256
>     in-port-index=200
>     out-port-index=201
>     hacks=no-component-role
>
>       With this in place we can do some hardware encoding of h.264 video
>     with gstreamer-1.0, both to file and via RTP over UDP.
>
>     3) I believe gstreamer1.0-omx may need to be configured to target RPi
>     not Bellagio
>
>     e.g. GSTREAMER_1_0_OMX_TARGET="rpi"
>
>     https://github.com/openembedded/oe-core/blob/master/meta/recipes-multimedia/gstreamer/gstreamer1.0-omx.inc
>
>     There's also a patch needed in gstreamer1.0-omx.inc as the RPi headers
>     are as incomplete as the Bellagio headers .
>
>     4) There are some issues using the v4l2 driver with gstreamer. It
>     seems
>     to block on polling
>
>     As v4l2src doesn't currently support h.264 for Gstreamer1.0 inherently
>     (my reading is that there's some uvch264_src code for this in
>     development) I'm concentrating on getting raspivid working for now and
>     then piping into an Gstreamer1.0 fdsrc which works for me on Raspbian,
>     and I'll see what the overhead is with that approach.
>
>     Cheers,
>
>     Alex
>
>

-- 

Dynamic Devices Ltd <http://www.dynamicdevices.co.uk/>

Alex J Lennon / Director
1 Queensway, Liverpool L22 4RA

mobile: +44 (0)7956 668178

Linkedin <http://www.linkedin.com/in/alexjlennon> Skype
<skype:alexjlennon?add>

This e-mail message may contain confidential or legally privileged
information and is intended only for the use of the intended
recipient(s). Any unauthorized disclosure, dissemination, distribution,
copying or the taking of any action in reliance on the information
herein is prohibited. E-mails are not secure and cannot be guaranteed to
be error free as they can be intercepted, amended, or contain viruses.
Anyone who communicates with us by e-mail is deemed to have accepted
these risks. Company Name is not responsible for errors or omissions in
this message and denies any responsibility for any damage arising from
the use of e-mail. Any opinion and other statement contained in this
message and any attachment are solely those of the author and do not
necessarily represent those of the company.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20140601/ccc308e5/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ddlogo-4.png
Type: image/png
Size: 3997 bytes
Desc: not available
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20140601/ccc308e5/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: linkedin.png
Type: image/png
Size: 631 bytes
Desc: not available
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20140601/ccc308e5/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: skype.png
Type: image/png
Size: 800 bytes
Desc: not available
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20140601/ccc308e5/attachment-0002.png>


More information about the yocto mailing list