Yocto
Please note that you can find more detailed information about image generation using Yocto directly in the README of the meta-wifx github page.
Prerequisites
The toolchain concerned by this document has been created using Yocto project 2.1.2 and has been tested on Ubuntu 16.04 LTS (the host).
The following packages must be installed on the host prior to begin:
Sources location
Wifx
meta-wifx
URI: git://github.com/Wifx/meta-wifx.git
URI: https://github.com/Wifx/meta-wifx.git
Branch: krogoth
Dependencies
meta-openembedded
URI: git://git.openembedded.org/meta-openembedded
URI: http://cgit.openembedded.org/meta-openembedded/
Branch: krogoth
meta-golang
URI: git://github.com/Wifx/meta-golang.git
URI: https://github.com/Wifx/meta-golang.git
Branch: master
meta-maker
URI: git://git.yoctoproject.org/meta-maker
URI: https://git.yoctoproject.org/git/meta-maker
Branch: master
Download
Begin by creating a working directoy:
Then download the various layers
Clone meta-maker layer with the proper branch ready
Configure
Enter the poky directory to configure the build system and start the build process
Initialize build directory
Add the various layers to bblayer configuration file
Edit local.conf to specify the machine, location of source archived, package type (rpm, deb or ipk). Here is an example:
Customize
The Wifx image recipe file is under ${BSPDIR}/meta-wifx/recipes-wifx/images/wifx-base.inc. This file describes the packages which will be included into the image. You can add for example the python packages by adding the following in the IMAGE_INSTALL variable:
Build
Build Wifx standard image:
Or build the devel image which contains also the app headers
Or build the SDK image which contains in addition the kernel headers and debug utilities:
Toolchain
You can create a toolchain installer, not depending on the image you choose to create using the command "bitbake {image} -c populate_sdk", for example:
In all cases, the toolchain installer is then located in build-wifx/tmp/deploy/sdk under the form poky-wifx-glibc-x86_64-{image name}-cortexa5hf-neon-toolchain-2.1.2.sh
Its installation is explained in the Toolchain page.
Image
The resulting images are availlable in /build-wifx/tmp/deploy/images/sama5d4-lorix-one:
- sama5d4_lorix_one-nandflashboot-uboot-{version}.bin
This is the AT91 bootstrap pre-bootloader binary which load U-Boot from NAND
Commonly used by SAM-BA script as at91bootstrap.bin - u-boot-sama5d4-lorix-one-{version}-{package revision}.bin
This is the U-Boot binary which load the Linux kernel
Commonly used by SAM-BA script as u-boot.bin - zImage--{version}-{package revision}-at91-sama5d4_lorix_one-{date code}.dtb
This is the device tree image binary used by the Linux kernel
Commonly used by the SAM-BA script at91-sama5d4_lorix_one.dtb - zImage--{version}-{package revision}-sama5d4-lorix-one-{date code}.bin
This is the Linux kernel image
Commonly used by the SAM-BA script as zImage
The programming of these binaries is explained in the page NAND Programming.