Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Updated meta-raspberrypi layer, an OpenEmbedded BSP layer for the Raspberry Pi boards.
C BitBake C++ Assembly Other
Branch: master
Pull request Compare This branch is 237 commits ahead, 1 commit behind djwillis:master.

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.


Quick links
Git repository web frontend:
Mailing list (yocto mailing list):
Issues management (redmine):

1. Description
2. Yocto BSP Layer - Raspberry Pi
    2.A. Compressed deployed files
    2.B. GPU memory
    2.C. Add purchased license codecs
    2.D. Disable overscan
    2.E. Set overclocking options
    2.F. Optional - Video camera support with V4L2 drivers
    2.G. Optional - Enable offline compositing support
    2.H. Optional - Enable kgdb over console support
    2.I. Images
    2.J. Boot to U-Boot
    2.K. Image with Initramfs
    2.L. Device tree support
3. Extra apps
    3.A. omxplayer
4. Source code and mirrors
5. Contribution
    5.A. Mailing List
    5.B. Redmine
6. Maintainers

1. OpenEmbedded BSP Layer - RaspberryPi

This is the general hardware specific BSP overlay for the RaspberryPi device.
It should be used with openembedded-core (oe-core, not old-style

More information can be found at:

    (official RPi site)
    (upstream author layer site)

Build scripts patched to support making a firmware image for the RaspberryPi
with Angstrom can be found at:


When not depending on meta-openembedded and not using systemd, you may 
need to mask few recipes requiring systemd or other recipes not included 
in your distribution of choice (note: xorg-openbox image builds without 

You can achieve this by adding something like the following to local.conf:

BBMASK = "meta-raspberrypi/recipes-multimedia/libav|\

You can adjust the BBMASK for any .bbappends that your distribution 
does not contain recipes for.

The core BSP part of meta-raspberrypi should work with different 
OpenEmbedded/Yocto distributions and layer stacks, such as:

* Distro-less (only with OE-Core).
* Angstrom.
* Yocto/Poky (main focus of testing).

2. Yocto BSP Layer - RaspberryPi

This layer depends on:

URI: git://
branch: master
revision: HEAD

URI: git://
layers: meta-oe, meta-multimedia
branch: master
revision: HEAD

How to use it:

1. source poky/oe-init-build-env rpi-build
2. Add needed layers to bblayers.conf:
  (for basic upstream hw image)
    - meta-raspberrypi (replaces meta-yocto-bsp)
    - meta-openembedded/meta-oe
  (for xorg-openbox image)
    - meta-openembedded/meta-gnome
    - meta-openembedded/meta-networking
    - meta-openembedded/meta-multimedia
    - meta-openembedded/meta-efl
    - meta-openembedded/meta-xfce
    - meta-alt-desktop-extras
3  Set MACHINE to raspberrypi in local.conf
4. Set any other desired parameters in local.conf (see following sections)
    - source poky/oe-init-build-env with your build dir again after any changes
5. bitbake [rpi-hwup-image|xorg-openbox-image|console-image-plus]
6. dd the .sdimg file to an SD card
    - sudo dd if=/path/to/rpi.sdimg of=/dev/sdX bs=4M
        - where sdX is your sdcard device
7. Boot your RPi.

2.A. Optional - compressed deployed files:
1. Overwrite IMAGE_FSTYPES in local.conf
    IMAGE_FSTYPES = "tar.bz2 ext3.xz"
2. Overwrite SDIMG_ROOTFS_TYPE in local.conf
    SDIMG_ROOTFS_TYPE = "ext3.xz"
3. Overwrite SDIMG_COMPRESSION in local.conf
*Accommodate the values above to your own needs (ex: ext3 / ext4).

2.B. Optional - GPU memory:
You can also specify the amount of RAM used by the GPU in config.txt:

Variable    : Details
GPU_MEM     : GPU memory in megabyte. Sets the memory split between the ARM and
              GPU. ARM gets the remaining memory. Min 16. Default 64.
GPU_MEM_256 : GPU memory in megabyte for the 256MB Raspberry Pi. Ignored by the
              512MB RP. Overrides gpu_mem. Max 192. Default not set.
GPU_MEM_512 : GPU memory in megabyte for the 512MB Raspberry Pi. Ignored by the
              256MB RP. Overrides gpu_mem. Max 448. Default not set.

2.C. Optional - Set overclocking options:
The Raspberry PI can be overclocked. As of now overclocking up to the "Turbo Mode" is officially supported by the raspbery and does not void warranty. Check the config.txt for a detailed description of options and modes. Example:
# Turbo mode
ARM_FREQ = "1000"
CORE_FREQ = "500"
SDRAM_FREQ = "500"

2.D.Optional - Add purchased license codecs:
To add you own licenses use variables KEY_DECODE_MPG2 and KEY_DECODE_WVC1 in local.conf. Example:
KEY_DECODE_MPG2 = "12345678"
KEY_DECODE_WVC1 = "12345678"
You can supply more licenses separated by comma. Example:
KEY_DECODE_WVC1 = "0x12345678,0xabcdabcd,0x87654321"

2.E. Optional - RPi and Xorg Image Config Parameters in local.conf:
The local.conf file generated by the oe-init-build-env script initially contains only the usual OE build defaults; for example, you should make sure MACHINE is set to raspberrypi, and you may want to customize things like DL_DIR, etc.  There are also RPi-specific options, some in upstream, and some in this fork  The options specific to the RPi are set in config.txt on the RPi and can be changed at any time. Other options generate config parameters in the relevant config files under /etc.

Upstream Layer:
By default the GPU adds a black border around the video output to compensate for TVs which cut off part of the image. To disable this set this variable in local.conf:

This Fork:
You can set the default timezone to any of the valid values in /usr/share/zoneinfo:

You should set the default hdmi_drive audio parameter, since the built-in value didn't seem to produce any sound.  Possible values are 1 (for DVI only) or 2 (for HDMI with audio):

For real-time audio with jack, you need cgroups in order to use RT_GROUP_SCHED:

If you want to expose your RPi package feed with a custom URL, then set both of the following.  Set the first one to "external" and the second to a public URL; the resulting URL is used in /etc/opkg/ in local-feeds.conf:
CUSTOM_FEED_CONFIG = "external"  # possible values are internal or external

2.F. Optional - Video camera support with V4L2 drivers
Set this variable to enable support for the video camera (Linux 3.12.4+ required)

2.G. Optional - Enable offline compositing support

Set this variable to enable support for dispmanx offline compositing

This will enable the firmware to fall back to off-line compositing of
Dispmanx elements. Normally the compositing is done on-line, during scanout,
but cannot handle too many elements. With off-line enabled, an off-screen
buffer is allocated for compositing. When scene complexity (number and sizes
of elements) is high, compositing will happen off-line into the buffer.

Heavily recommended for Wayland/Weston.


2.H. Optional - Enable kgdb over console support
To add the kdbg over console (kgdboc) parameter to the kernel command line,
set this variable in local.conf:

2.I. Images
* rpi-hwup-image
    Hardware up image
* rpi-basic-image
    Based on rpi-hwup-image with some added features (ex: splash)
* rpi-test-image
    Image based on rpi-basic-image which includes most of the packages in this
    layer and some media samples.
* rpi-console-image (this fork)
    Adds package management and hwcodecs (if available) to rpi-basic-image

2.J. Boot to U-Boot
To have u-boot load kernel image, set in your local.conf

This will make kernel.img be u-boot image which will load uImage.
By default, kernel.img is the actual kernel image (ex. Image).

2.K. Image with Initramfs
To build an initramfs image :
    * Set this 3 kernel variables (in for example)
        - kernel_configure_variable BLK_DEV_INITRD y
        - kernel_configure_variable INITRAMFS_SOURCE ""
        - kernel_configure_variable RD_GZIP y
    * Set the yocto variables (in for example)
        - INITRAMFS_IMAGE = "<a name for your initramfs image>"
    * Set the meta-rasberrypi variable (in raspberrypi.conf for example)
        - KERNEL_INITRAMFS = "-initramfs"

2.L. Device tree support
Device tree for RPi is only supported when using linux-raspberrypi 3.18+

    * Set KERNEL_DEVICETREE (in conf/machine/raspberrypi.conf)
        - the trailer is added to the kernel image before kernel install task.
          While creating the SDCard image, this modified kernel is put on
          boot partition (as kernel.img) as well as DeviceTree blobs (.dtb files).

NOTE: KERNEL_DEVICETREE is default enabled for kernel >= 3.18 and always disabled for
      older kernel versions.

3. Extra apps

3.A. omxplayer
omxplayer depends on libav which has a commercial license. So in order to be
able to compile omxplayer you will need to whiteflag the commercial license
adding to you local.conf:


4. Source code and mirrors

Main repo:

Github mirror:

Bitbucket mirror:

5. Contributing

5.A. Mailing list
The main communication tool we use is a mailing list:

Feel free to ask any kind of questions but always prepend your email subject
with "[meta-raspberrypi]". This is because we use the 'yocto' mailing list and
not a perticular 'meta-raspberrypi' mailing list.

To contribute to this layer you should send the patches for review to the
above specified mailing list.
The patches should be compliant with the openembedded patch guidelines:

When creating patches, please use something like:

    git format-patch -s --subject-prefix='meta-raspberrypi][PATCH' origin

When sending patches to mailing list, please use something like:

    git send-email --to <generated patch>

5.B. Redmine
In order to manage and trace the meta-raspberrypi issues, we use redmine:

Here we report, trace and develop bugs, features or support tickets for this
yocto BSP later.

If you push patches which have a redmine issue associated, please provide the
issue number in the commit log just before "Signed-off-by" line(s). Example line
for a bug:
    [Bug #13]

6. Maintainers

    Andrei Gherzan <andrei at>

This fork:
    Steve Arnold <stephen.arnold42 at>

Something went wrong with that request. Please try again.