Personal tools

VisionSOM renesas-meta-somlabs-dunfell

From SomLabs Wiki

Revision as of 19:32, 27 September 2023 by KrzysztofChojnowski (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

VisionSOM renesas-meta-somlabs layer for Renesas Yocto Dunfell


This tutorial explains how to build the Renesas Yocto Dunfell 3.0.3 system for the SoMLabs modules. The Yocto system uses the following kernel and u-boot repositories:

Introduction

Meta-somlabs is a layer providing the VisionSOM-x2L module (with RZ/G2L or RZ/V2L processor) and VisionCB-G2L/V2L-STD carrier board hardware support for Yocto Dunfell Renesas Linux system.

Host system prerequisites

This tutorial was prepared for the Ubuntu 18.04.5 LTS host operating system. All of the files required for system image compilation may require up to 120 GB of the disk space. The SDK build requires additional 25 GB (145 GB in total).

The following packages need to be installed before the building process:

sudo apt-get install gawk wget git diffstat unzip texinfo gcc-multilib build-essential chrpath socat libsdl1.2-dev xterm sed cvs subversion coreutils texi2html docbook-utils python-pysqlite2 help2man make gcc g++ desktop-file-utils libgl1-mesa-dev libglu1-mesa-dev mercurial autoconf automake groff curl lzop asciidoc u-boot-tools liblz4-tool zstd

The source code will be obtained using git, so it needs to be configured by setting the user name and email with correctly set values:

git config --global user.email "you@example.com"
git config --global user.name "Your Name"

A new repo tool version is also required. It may be downloaded directly from the project site. The repo binary needs to be available in the system PATH variable and have the execution privilege:

wget https://storage.googleapis.com/git-repo-downloads/repo
sudo mv repo /usr/bin/repo
sudo chmod a+x /usr/bin/repo

System image

This layer should be used in order to build the system image. This layer adds a new example image called somlabs-image. It includes the SoMLabs demo application using the GTK and GStreamer libraries.

Building the system image

The general description of the building process is described in the Renesas Yocto Start-Up Guide document:

https://www.renesas.com/eu/en/document/mas/rzg2-group-yocto-recipe-start-guide-vlp-v300

The summary of required steps including the meta-somlabs layer and helper scripts shown below:

mkdir renesas-yocto-dunfell
cd renesas-yocto-dunfell
repo init -u https://github.com/SoMLabs/renesas-meta-somlabs -b dunfell-3.0.3 -m renesas-somlabs-dunfell-3.0.3.xml
repo sync

System building may be configured for one of the available machine configurations:

  • visionsom-g2l-cb - VisionSOM-x2L module with RZ/G2L processor and VisionCB-G2L/V2L-STD carrier board
  • visionsom-v2l-cb - VisionSOM-x2L module with RZ/V2L processor and VisionCB-G2L/V2L-STD carrier board

System building may be started by the following commands:

MACHINE=<SELECTED_MACHINE> BUILD=<BUILD_DIRECTORY> source somlabs-setup-release.sh
bitbake somlabs-image

The somlabs-setup-release.sh script creates the build directory and initializes the configuration files. In order to configure the shell without overwriting the existing settings the following command may be executed:

source poky/oe-init-build-env <BUILD_DIRECTORY>

The output files are created in the build subdirectory <BUILD_DIRECTORY>/tmp/deploy/images/<SELECTED_MACHINE>:

  • bl2_bp-<SELECTED_MACHINE>.bin - first stage loader binary
  • fip-<SELECTED_MACHINE>.bin - bootloader binary
  • somlabs-image-<SELECTED_MACHINE>.wic.bz2 - compressed system image

The instruction for the eMMC memory image installation may be found on the following wiki page:

GPU support

The default system image does not contain modules and drivers required for GPU support. The needed recipes are available to download through Renesas website. The evaluation version may be downloaded after creating an account. The full version requires a contact with Renesas support.

https://renesas.info/wiki/RZ-G/RZ-G2_BSP https://www.renesas.com/eu/en/products/microcontrollers-microprocessors/rz-arm-based-high-end-32-64-bit-mpus/rzg2l-mali-graphic-library-evaluation-version https://www.renesas.com/eu/en/software-tool/rz-mpu-video-codec-library-evaluation-version-rzg2l

GPU drivers and codec library should be compatible with BSP version 3.0.3.

After obtaning the source, the meta layers should be added to the main project directory with meta-somlabs and meta-renesas layers. They should be placed in the meta-rz-features directory.

Renesas-meta-features.png

The details about meta-rz-features layer can be found in the Renesas Yocto Start-Up Guide document:

https://www.renesas.com/eu/en/document/mas/rzg2-group-yocto-recipe-start-guide-vlp-v300

NXP Partner ST Partner Renesas Partner