Install and Build an Angstrom Linux Image for the TechNexion Thunder Board

TechNexion Thunderpack Developer Kit


Thunder
Hello dear reader. Recently, I had a chance to work with a kit for a developer, a Taiwanese company called TechNexion Ltd , called Thunderpack, which includes the SOM ( System on module ) TAO-3530 and the Thunder board .
SOM is based on SoC ( System-on-a-Chip ) TI OMAP3530 from Texas Instruments and contains 256 MB DDR RAM, 512 MB NAND Flash, DMS core TMS320C64 +, and may also contain a Wireless LAN module for WiFi support.
In this post I want to talk about my experience with this board.
So, let's begin.
TAO-3530

Install Linux 2.6.37


After a quick reading of the documentation , building, and turning on Thunder, I started installing Linux. I’ll say right away that I couldn’t install through the default installation method. The installation procedure was constantly restarted. So I went to the TechNexion website and downloaded, kindly prepared and uploaded by them, an image containing Linux 2.6.37.
Following the instructions in the documentation (section 9.4.1 Create the SD-card with the rescue image in a Windows environment), I prepared an SD card for installing Linux 2.6.37 and performed the installation.
After installation, the system booted successfully, but I was disappointed because the network did not work. He began to search for information on the network card.
At the end of the documentation for the board, the Thunder diagrams are shown (Section 16.2 Thunder baseboard schematics). The diagram shows that the network card is a USB-Ethernet converter assembled on the Microchip SMSC LAN9500-ABZJ controller . Looking for the driver in the newly installed system, I did not find it. Perhaps they forgot to turn it on during assembly.
image

On the TechNexion website, in addition to ready-made images, the source codes for manually assembling the image are available. Having downloaded "TAO-3530 Linux 2.6.37 / TI PSP 04.02.00.07 XUKR Source code", it turned out that the driver for the network card I needed was present and turned on for assembly. It remains only to rebuild the image.

Build an Angstrom Linux 2.6.37 image


I built the image on Ubuntu 12.04, pre-installing it on VirtualBox. In the Thunder documentation, developers are advised to build using the Toolchain Code Sourcery G ++ 2010.09-50 (gcc 4.5.1). I want to draw attention to the fact that to build the Angstrom Linux 2.6.37 image provided by the TechNexion developers, it is Code Sourcery G ++ 2010.09-50 that should be deployed .
First of all, download arm-2010.09-50-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2 or from the Mentor Graphics website and unpack it into the / opt / codesourcery folder.
$cd /opt
$sudo mkdir codesourcery
$cd codesourcery
$sudo wget ftp://ftp.ru.debian.org/gentoo-distfiles/distfiles/arm-2010.09-50-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
$sudo tar xvf arm-2010.09-50-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

image

Define environment variables. To do this, add the file / etc / environment:
export ARCH=arm
export CROSS_COMPILE=/opt/codesourcery/arm-2010.09/bin/arm-none-linux-gnueabi-


Create the files folder in the root directory, and copy the source codes into it to create the Angstrom Linux 2.6.37 image.
$cd /
$sudo mkdir files
$cd files
$sudo wget http://technexion.com/images/downloads/ARM_CPU_Modules/xukr-20131014-omap3.tar.xz
$sudo tar xvf xukr-20131014-omap3.tar.xz 

image

Install uboot-mkimage.
$sudo apt-get install uboot-mkimage


Now it is necessary to reboot the system in order for the environment variables that we set to work.

It remains to tweak the kernel configuration to include the necessary drivers. Since I will build the image for the Thunder board, the path to the configuration file I need is as follows:
/opt/files/xukr-20131014-omap3/kernel/linux-2.6.37-tn/arch/arm/configs/taotdm_defconfig


The configuration file must be opened in any convenient editor and the options of interest should be included. I edited the standard editor of the Midnight Commander file manager.
The first thing I looked in the configuration file was the presence of the included SMSC95xx network card driver.
CONFIG_USB_NET_SMSC95XX=y

Then I turned on compilation of usb-serial drivers.
CONFIG_USB_SERIAL=y

And he included support for the most common usb-serial PL2303 and CP210x chips.
CONFIG_USB_SERIAL_PL2303=y
CONFIG_USB_SERIAL_CP210X=y

Close the editor, after saving the changes to the file. Now everything is ready to build the kernel.
Go to the directory xukr-20131014-omap3
$cd /opt/files/xukr-20131014-omap3


And run the build script with the platform name.
$sudo ./Build.sh thunder



This script will build the bootloader, the kernel of the OS, copy all the necessary files to a pre-prepared file structure, etc.

Then clean the source code from the created object files.
$sudo ./Clean.sh

And an image building script indicating the name of the platform.
$sudo ./mk_nandimg.sh thunder

Upon successful completion, you can congratulate yourself on creating the Angstrom Linux 2.6.37 image. The image itself will be located in the
/ opt / files / xukr-20131014-omap3 / build / thunder folder .
It remains to prepare the installation SD-disk and install. These steps are described above (see Installing Linux 2.6.37).
After installing the assembled system, I got a network and support for usb-serial devices.
image

Conclusion


TechNexion developers have made a very convenient process for building and creating an image of a bootable SD disk that does not require deep knowledge and experience in building the Linux kernel. The scripts prepared by them do everything automatically.
The only, as usual, the documentation does not keep up with the developers. The last, at the time of this writing, version of the documentation (tao-3530-userguide-097.pdf) contained a description of the assembly for the old sources, which is slightly different.

Thanks for attention. In the next article I will write about setting up Eclipse CDT for compiling programs for arm, running an application on Thunder, and debugging a program in Eclipse.

See you.

Also popular now: