Armadillo J Development Environment


Compiler Collection


Applications were compiled for the Armadillo J using the Gnu Compiler Collection which is provided here and on the Armadillo J development CD:


arm-elf-tools-20030314.sh

arm-elf-tools-20030314.sh.md5sum


The tools are installed in /usr/local/bin and start with arm-elf-


Linking object files requires the -elf2flt flag.


Armadillo J Linux Distribution


Initial communication with the Armadillo J and the development PC is done via a -cross over serial cable. The factory image installed on the Armadillo J does not have serial console support and client NFS support so the first step is to build and install a new image.


The Embedded Linux distribution uClinux which is provided here and on the Armadillo J development CD:


uClinux-dist-aj20050421.tar.gz


Unpack,


$cd uClinux-dist

$make menuconfig

“Target Platform Selection” ---> select “AtmarkTechno/Armadillo-J.Base”

select “Customize Kernel Settings” and “Customize Kernel Settings”

“Exit”

“Exit”

Save new kernel configuration “Yes”

“File systems” ---> “Network File Systems” ---> select “NFS system support” unselect “NFS server support”

“Exit”

“Exit”

“Exit”

Save new kernel configuration “Yes”


“Network Applications “ ---> unselect “ftpd”

“Exit”

“BusyBox” ---> select “reboot”

“Exit”

“Exit”

Save new kernel configuration “Yes”


$make dep

$make


After it is done image.bin will be in uClinux-dist/images.


First some jumpers must be set to upload the image. See page 11 of the Armadillo J User Guide or simply close all four jumpers, connect a cross-over serial cable between the Armadillo J and the PC and do the following:


Install the hermit utility deb rpm tgz


$hermit download -i image.bin -r user –-port <serial port device>


When it is finished unplug the Armadillo J and put the jumpers back to serial console mode. See page 15 of the Armadillo J Hardware Manual. Basically close JP1, JP2, and JP3


Start Minicom or a similar program, setup the serial port settings, see 6.1 Before Booting of the Armadillo J User Guide


The root password is root. By default the network is configured to use DHCP, you can override this by editing the /etc/config/network file. If you do so the state of the file system must be saved to the flash memory. This is done by sending the USR1 signal to flatfsd, e.g.

$killall -USR1 flatfsd


Development is much easer if the Armadillo J mounts a NFS.


Because the Armadillo kernel was not compiled with NFS V3.0 support, you have to mount like this:

# mount -t nfs -o nfsvers=2,nolock 192.168.1.1:/opt /home/guest/


Remote Debugging


Attempted the following to build gdbserver from gdb-6.3


$tar xzvf gdb-6.3.tar.gz
$cd gdb-6.3/gdb/gdbserver
$chmod 777 configure

$LDFLAGS=-elf2flt CC=arm-elf-gcc ./configure arm-elf
$make


Copied gdbserver and gdbreplay to the bin directory on the Armadillo.

But when I tried to execute gdbserver on the Armadillo, I got:

# ./gdbserver

Illegal instruction


I downloaded and installed a pre compiled version: http://www.uclinux.org/~bkuhn/Toolchain/20020920/gdbserver.bz2

on the Armadillo. The Armadillo was able to execute this binary.


Attempted to execute arm-elf-gdb from the cross-tools install from the Armadillo J CD but got this message:

./arm-elf-gdb: error while loading shared libraries: libncurses.so.4: cannot open shared object file: No such file or directory


Compiled arm-elf-gdb from the gdb-6.3 source code like this:

./configure --target=arm-elf –prefix=/usr/local/gdb/