From Variscite Wiki
VAR-SOM-AM33 Yocto 1.8 (Fido) Distribution User's Guide

1 About this Manual

This document describes how to install Variscite's Yocto release for the VAR-SOM-AM33.

The Yocto distribution provides a fundamental software platform for development, deployment and execution on VAR-SOM-AM33. It abstracts the functionality provided by the hardware.

In this context, the document contains instructions to:

  • Install the release on a development machine.
  • Build the sources included in this release.
  • Instaling the binaries on the VAR-SOM-AM33.
  • Booting the VAR-SOM-AM33.

2 Installing required packages

Follow the link below and install all required packages on your machine.

Please make sure you host PC is running Ubuntu 14.04 and install the following packages:

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

3 Installation

3.1 Prerequisites

Before starting the installation, make sure below system requirements are met:

The Linux host is used for the following:

  • Recompiling U-Boot / kernel.
  • Hosting the NFS server to boot the EVM with NFS as root filesystem.

Either of Windows or Linux host can be used for:

  • Hosting the TFTP server required for downloading the kernel and file-system images from U-Boot using Ethernet.
  • Running a serial console terminal application

Building the Yocto distribution via Bitbake will produce a complete set of downloaded source code + binaries for each component:

  • Yocto build environment
  • Downloaded Linux kernel source code + build kernel binaries (DTB and zImage) for VAR-SOM-AM33.
  • Downloaded U-Boot source code + build U-boot binaries (MLO and U-boot) for VAR-SOM-AM33.
  • Linux root file-system.

3.1.1 Install the Arago toolchain

$ wget --no-check-certificate
$ sudo tar -xvf gcc-linaro-4.9-2015.05-x86_64_arm-linux-gnueabihf.tar.xz -C /opt

3.1.2 Download TI's Yocto Fido Distribution

$ mkdir ~/yocto_varsomam33
$ cd ~/yocto_varsomam33
$ git clone git:// tisdk Downloading VAR-SOM-AM33 Support

Download the VAR-SOM-AM33 Yocto support installation from github:

$ mkdir ~/yocto_varsomam33/tisdk/sources
$ cd ~/yocto_varsomam33/tisdk/sources
$ git clone Downloading the YOCTO Fido 1.8 configuration

Download the YOCTO Fido 1.8 sources as follows:

$ cd ~/yocto_varsomam33/tisdk
$ ./ -f sources/meta-variscite-amx3/conf/var-som-amx3_sdk-02.00.00-config.txt

3.1.3 local.conf customizations

Edit you local.conf file:

$ cd ~/yocto_varsomam33/tisdk/build
$ gedit conf/local.conf 

Change your parallel build and download directory: Parallel build

Set the build parameters to fully utilize your host machine BB_NUMBER_THREADS = '4'
PARALLEL_MAKE = '-j 6' BB_NUMBER_THREADS should be your host machine's number of threads minus 2 or same. PARALLEL_MAKE should be the number of threads your host machine has plus two. Download directory

Recommended to save download time and space. DL_DIR = "/home/<uname>/yocto_dl" TI MIRRORS

One common location for hosting packages,, has recently been decommissioned. This will cause fetch failures for the current and past releases. Please add the following lines to your local.cof to configure the build to obtain these packages from the TI mirror.

MIRRORS += " \
 bzr://.*/.*      ${TI_MIRROR} \n \
 cvs://.*/.*      ${TI_MIRROR} \n \
 git://.*/.*      ${TI_MIRROR} \n \
 gitsm://.*/.*    ${TI_MIRROR} \n \
 hg://.*/.*       ${TI_MIRROR} \n \
 osc://.*/.*      ${TI_MIRROR} \n \
 p4://.*/.*       ${TI_MIRROR} \n \
 npm://.*/.*      ${TI_MIRROR} \n \
 ftp://.*/.*      ${TI_MIRROR} \n \
 https?$://.*/.*  ${TI_MIRROR} \n \
 svn://.*/.*      ${TI_MIRROR} \n \

4 Building the VAR-SOM-AM33 Yocto image

First, change directory to the build directory of Yocto:

$ cd ~/yocto_varsomam33/tisdk/build

The developer can build the tisdk-rootfs-image image as follows:

$ export PATH=/opt/gcc-linaro-4.9-2015.05-x86_64_arm-linux-gnueabihf/bin:$PATH
$ . conf/setenv
$ MACHINE=varsomam33 bitbake tisdk-rootfs-image

After the image was built, all images will be located in: ~/yocto_varsomam33/tisdk/build/arago-tmp-external-linaro-toolchain/deploy/images/ - Specifically:

4.1 Build Results

The resulted images are locaated in tmp/deploy/images/var-som-mx6.

Image Name
How to use
zImage Kernel uncompressed image
zImage-var-som-am33.dtb The VAR-SOM-AM33 kernel device tree
uImage Linux kernel image, same binary for SD-Card or NAND Flash
MLO The MLO is pre-u-boot SW component, required for DDR initialization
u-boot.img U-Boot bootloader
tisdk-rootfs-image-varsomam33.tar.gz Compressed rootfs tarball

If the rootfs directory already exists - Please make sure to erase all its content before extracting a new rootfs image into it:

$ sudo rm -rf ~/yocto_varsomam33/rootfs/*

Extract the rootfs as follows:

 $ sudo mkdir ~/yocto_varsomam33/rootfs
 $ sudo tar xvf ./arago-tmp-external-linaro-toolchain/deploy/images/varsomam33/tisdk-rootfs-image-varsomam33.tar.gz -C ~/yocto_varsomam33/rootfs

This creates a rootfs directory for the Yocto / VAR-SOM-AM33 build.

5 Create a bootable SD-Card

The below procedure will result in a bootable SD-Card:

  • SD-Card will be partitioned into 2 partitions:
    • FAT32 Boot partition: includes MLO and U-boot required for initial boot
    • ext3 file system: includes zImage, kernel device tree and a complete rootfs
  • All NAND flash binaries will be copied to rootfs under /opt/TISDK directory, for NAND Flash burning if required.

Please follow the below steps:

  • Insert a 4GB+ SD-Card to host computer
  • Run dmesg command to identify which /dev/sdX was created
  • To generate the SD-Card - Run script (and choose the correct /dev/sdX of the 4GB SD-Card inserted):
$ cd ~/yocto_varsomam33/tisdk/sources/meta-variscite-amx3/utils
$ sudo ./ ~/yocto_varsomam33/tisdk ~/yocto_varsomam33/rootfs/

6 Boot

The Kernel and root the file-system can be booted either from NAND or SD-Card.

Following sections describe various kernel boot options possible.

Pleaes make sure your target board debug serial is connected to host PC with hyperterminal, as described in the quick-start guide.

6.1 Boot from MMC/SD

For creating a bootable SD , follow instructions on Creating a bootable SD-Card

To boot the bootable SD-Card, follow the steps below:

  • Power-off board
  • Insert the SD card into the SD-Card slot of the custom board
  • Press and hold the boot select switch while powering ON the board. Booting without pressing the boot-select button, CPU will boot from NAND-Flash. While currently our NAND is either empty, or has older revisions.
  • Login as root (no password)

6.2 Boot from NAND

If boot-select button is not pressed at power-up,by default the VAR-SOM-AM33 boots from NAND.
Make sure NAND-Flash binaries were flashed to NAND-Flash : NAND Flash Burning

7 Flash binaries to NAND

Please refer to : NAND Flash Burning

8 Pre-built NAND Recovery SD-Card

Variscite provides a sample bootable NAND-recovery rescue SD-Card
Image can be downloaded and mounted on SD-Card from Variscite's FTP, please refer to :
VAR-SOM-AM33 Yocto NAND Recovery

9 Build U-Boot out of yocto tree

Please refer to : Build u-boot out of yocto tree

10 Building Linux kernel out-of-yocto tree

For manually building the Linux kernel, out of the yocto build system, please refer to :
Build linux kernel out of yocto tree

10.1 Out-of-tree Kernel Modules

Some drivers like the SGX and WLAN drivers are delivered as modules outside of the kernel tree. These drivers binaries are already included in the pre-built root file-systems provided by Variscite.

11 Support carrier boards without a Touch screen

In order to skip the Touch screen calibration on the first boot on carrier boards without a Touch screen -

Please insert the SD-Card to a Linux machine (or VM) after creating the SD-Card and type the following command to disable touch screen calibration at the first boot:

$ sudo touch /media/boot/ws-calibrate.rules