You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Some of the reference designs from Trenz Electronics include a preconfigured yocto bsp layer that can be used to generate a Linux image and a prebuilt yocto linux image, that can be copied directly to sd card.

Generate image with predefined yocto BSP layer


The yocto bsp layer will be generated with the quartus project in the <project name>/os/yocto/meta-<module> folder. The generated layers depends on the meta-altera layer (for more information see: Yocto KICKstart#Used source files).

  1. Download a reference design that includes yocto bsp layer
  2. Generate the quartus project as described in the wiki description of the downloaded reference design or in Project Delivery - Intel devices#Quick Start
  3. Copy the generated meta-<module> folder from <project name>/os/yocto/meta-<module> to the path/to/yocto/poky/ directory
  4. Follow the steps from Yocto KICKstart#Create a project for an Intel FPGA device without running the 'bitbake' command
  5. Add the generated bsp layer meta-<machine> to /yocto/poky/build/conf/bblayers.conf with:

    bitbake-layers add-layer ../meta-<module>
  6. Redefine the variable MACHINE with '<module>-<Board-Part-Short-Name>' in path/to//yocto/poky/build/conf/local.conf 
    1. A list with the correct MACHINE names can be found in the wiki description of the reference design: Overview→Requirements→Hardware
    2. run following commands to redefine 'MACHINE':

      sed -i '/^MACHINE/s/MACHINE/#MACHINE/g' conf/local.conf
      echo -e '\nMACHINE = "<module>-<Board-Part-Short-Name>"' >> conf/local.conf
  7. Build the image with following command (the image recipes are located in meta-<module>/recipes-images/yocto/):

    bitbake <module>-image-minimal

Copy image to SD card


With the command above Yocto generates a full sd card image with u-boot, zImage, rootfs etc. included.

The generated image is stored in path/to/yocto/poky/build/tmp/deploy/images/<machine>/<image_name>.wic.

If you downloaded a reference design with prebuilt files, you can find a generated yocto linux image in <project name>/prebuilt/Board_Part_Short_Name/os/yocto/images/.

Do following steps to copy the image to the SD card:

  1. Insert the sd card into a sd card reader connected to the computer
  2. Run following command to get the device name of the SD card  (e.g. /dev/sdx):

    lsblk
  3. Copy the generated *.wic image to the sd card (replace 'sdx' in 'of=/dev/sdx' with the correct sd card device name:

    sudo dd if=path/to/yocto_image/<image_name>.wic of=/dev/sdx bs=1M seek=0
  4. Insert the SD card into your board, set boot mode to sd card (if the setting is available) and boot it.


Table of contents


  • No labels