Contents

1. Warp7 Yocto Part1 <-- You are here

2. Warp7 Yocto Part2

3. Warp7 Sensors demo - mpl3115a2

4. Warp7 Sensors demo - fxos8700cq

5. Warp7 IoT demo

 

The Warp7 is a next generation Wearable and IoT development platform.

plz refer  NXP and element14 website for more platform related information.

 

Warp7 Board

fd53fb.jpg

CPU Board

34nmm39.jpg

IO Board

2dkfsao.jpg

 

In this blog we will

1. Download warp7 yocto sources.

2. Setup required environment.

3. add/customise warp7 machine configs.

4. Compile and generate binaries.

 

 

A bit on yocto before we start :

oq9937.jpg

 

If you are new to yocto , plz make sure to check the yocto project before proceeding.

 

Platform Setup:

I am using Ubuntu 14.04 x86_64 for the build process. you can use do this from a Virtual Machine (vmware, virtualbox) also.

 

We need to install some packages on which yocto depends for the build process.

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

 

vr90kz.jpg

 

Download repo:

We need to have a repo tool to pull yocto sources.

 

mkdir ~/bin
curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
chmod a+x ~/bin/repo
export PATH=~/bin:$PATH

 

Download Yocto:

following steps will help download yocto sources from NXP(Freescale) official repository:

 

mkdir warp7_yocto
cd warp7_yocto
repo init -u https://github.com/Freescale/fsl-community-bsp-platform -b krogoth
repo sync

 

Before building the yocto bsp we need to update the yocto build with warp7 config.

To configure we need to pass the proper MACHINE name as a macro.

 

Determine machine name:

echo; ls sources/*/conf/machine/*.conf | sed s/\.conf//g | sed -r 's/^.+\///' | xargs -I% echo -e "\t%" | grep imx

 

1444o6p.jpg

 

The Warp7 machine name is imx7s-warp .

 

 

Setting up the environment:

 

MACHINE=imx7s-warp source setup-environment build

 

2useno7.jpg

 

Select "Y" to accept the EULA license and complete the machine config setup.

 

9bi39u.jpg

 

Now a build directory is created under ~/warp7_yocto directory.

It contains the build system settings for warp7 machine(i.e local.conf) and yocto bitbake layers path information (i.e bblayers.conf).

 

local.conf

1z4a4vn.jpg

 

bblayers.conf

141tfeq.jpg

 

 

Customise warp7 machine config:

Now edit the kernel source in warp7 machine configuration file.

 

in ~/warp7_yocto/sources/meta-fsl-arm-extra/conf/machine/imx7s-warp.conf file, edit as below.

Replace

PREFERRED_PROVIDER_virtual/kernel ?= "linux-fslc-imx"

with

PREFERRED_PROVIDER_virtual/kernel ?= "linux-warp"

 

Now the kernel source will be pulled from the linux-warp%%  bitbake recipe.

Create a directory named "linux-warp7-4.1" and recipe named "linux-warp7_4.1.bb" in below path.

~/warp7_yocto/sources/meta-fsl-arm-extra/recipes-kernel/linux/

 

mkdir ~/warp7_yocto/sources/meta-fsl-arm-extra/recipes-kernel/linux/linux-warp7-4.1
touch ~/warp7_yocto/sources/meta-fsl-arm-extra/recipes-kernel/linux/linux-warp7_4.1.bb

 

 

Populating warp7 recipe:

populate the recipe "linux-warp7_4.1.bb" with below contents.

# Released under the MIT license (see COPYING.MIT for the terms)

 

include recipes-kernel/linux/linux-imx.inc

include recipes-kernel/linux/linux-dtb.inc

 

DEPENDS += "lzop-native bc-native"

 

SRCBRANCH = "4.1-1.0.x-imx"

SRCREV = "fa571312b4271e368ca99ffcdf7992247d534e55"

 

SRC_URI = "git://github.com/WaRP7/linux-fslc.git;branch=${SRCBRANCH} \

           file://defconfig"

 

COMPATIBLE_MACHINE = "(imx7s-warp)"

 

In above recipe we setup 4.1-1.0.x-imx as source branch for our kernel and file defconfig will be the default kernel config file.

Next copy the defconfig file (in attachment) into the linux-warp7-4.1 directory.

 

 

Downloading yocto packages:

If you want to build images offline, its a good idea to download the packages first.

bitbake core-image-minimal -c fetchall

 

 

Build:

bitbake core-image-minimal

 

Now build, it will take several hours to complete depending on your PC configuration.

 

While kernel build is in process you might encounter an error wrt imx7s-warp.dtb.

This will happen is there is no imx7s-warp.dts file in below directory.

~/warp7_yocto/build/tmp/work/imx7s_warp-poky-linux-gnueabi/linux-warp7/4.1-r0/git/arch/arm/boot/dts

 

below is a snapshot from the log file that captured the above  error.

90avr7.jpg

 

In that case copy the imx7s-warp.dts from the attachments to the below directory:

~/warp7_yocto/build/tmp/work/imx7s_warp-poky-linux-gnueabi/linux-warp7/4.1-r0/git/arch/arm/boot/dts

 

2s7dqv4.jpg

 

Now hit build again.

 

After build completed, the images build are found in ~/warp7_yocto/build/tmp/deploy/images/imx7s-warp

noajk7.jpg

 

 

Let us know any challenges faced during build procedure through comments.

 

Next time we will flash the generated images.

 

Happy Warping.