Embedded Linux on ARM Devices

We got some really nice Hardware from a friendly company, and now we adapt it to our needs:

Have a look at: http://www.micromint.com/index.php/SBC/electrum100.html


It shall be used for measurement and control applications, using a wired link (UDP) or a wireless link (modem, connected via serial- TTL).

You can connect all kind of sensor:

etc using analog (12 bit) or digital inputs.

Because we want to use C++ with the QT library to write the code for this little board, we first need a cross-compiler (a toolchain) for this.

Installing the CodeSourcery toolchain

The following description is based on the tutorial, that I found on the following website: http://holtham.org/content/establishing-build-environment-cross-compiling-embedded-qt-applications-ubuntu

First we download the toolchain, move it to /opt and rename it to CodeSourcery:

cd ~
mkdir Downloads
cd Downloads
wget https://sourcery.mentor.com/sgpp/lite/arm/portal/package8739/public/arm-none-linux-gnueabi/arm-2011.03-41-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
sudo mv arm-2011.03-41-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2 /opt

cd /opt
sudo tar --bzip2 -xvf arm-2011.03-41-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2
sudo mv "arm-2011.03" CodeSourcery
sudo rm arm-2011.03-41-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2 

Add the path /CodeSourcery/bin to the search path and reboot:

cd /etc
sudo joe environment
Add the following path to the first line:

On my computer, it than looks like this:

sudo init 6

Check, if the correct compiler can now be found. Open a terminal and enter:

arm-none-linux-gnueabi-g++ --version

Expected output:

arm-none-linux-gnueabi-g++ (Sourcery G++ Lite 2011.03-41) 4.5.2
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO

On the target computer there must be a directory "/sysroot" be installed. To create it, type:

cd ~
mkdir 00Software
cp -r /opt/CodeSourcery/arm-none-linux-gnueabi/libc .
mv libc sysroot

This sysroot directory has now a size of 1.3 GB. To reduce the size, you can do:

cd sysroot
rm -r armv4t
rm -r thumb2

Now the size is only 459 MB. To further reduce the size, delete all locales, that you don't need, from the folder sysroot/usr/lib/locale. If I delete all but the english locales, the size is reduced to 79 MB.

Now you can pack the sysroot folder into a .tar.gz archive, copy it to the target, move it to the root folder and unpack it there.


You should have a working cross-compiling toolchain now.

Advantages compared to embeddian: You can independently upgrade the toolchain and the operation system. Disadvantage: Higher use of flash-memory on the target device.

Continue with: QT on embedded Linux

Back to FrontPage

KielTech: Embedded Linux on ARM CPU's (last edited 2011-11-09 21:00:01 by UweFechner)