Sonic Alert Boundary Devices Neon Board 28 User Manual

1
User’s Manual for the  
Boundary Devices  
R
Neonboard  
December 28, 2005  
December 28, 2005  
Revision 2.8  
CONTENTS  
3
Contents  
2
5
5
5
5
6
6
8
4.1 Layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .  
4.2 Mounting . . . . . . . . . . . . . . . . . . . . . . . . . . . . .  
4.3 Connector reference . . . . . . . . . . . . . . . . . . . . . . .  
4.4 Electrical characteristics . . . . . . . . . . . . . . . . . . . . .  
9
9
5.1.3 General build steps . . . . . . . . . . . . . . . . . . . . 10  
5.1.5 U-Boot Memory layout . . . . . . . . . . . . . . . . . 12  
5.1.6 U-Boot Init Script . . . . . . . . . . . . . . . . . . . . 13  
5.2 Windows CE . . . . . . . . . . . . . . . . . . . . . . . . . . . 14  
5.2.1 Prerequisites and components . . . . . . . . . . . . . . 14  
5.2.2 BSP Installation . . . . . . . . . . . . . . . . . . . . . 14  
5.2.3 Building the demo . . . . . . . . . . . . . . . . . . . . 15  
5.3 Linux Support . . . . . . . . . . . . . . . . . . . . . . . . . . 16  
5.3.1 Crosstool Linux Toolchain . . . . . . . . . . . . . . . . 16  
5.3.4 Kernel 2.4.19 . . . . . . . . . . . . . . . . . . . . . . . 19  
5.3.5 Kernel 2.6 . . . . . . . . . . . . . . . . . . . . . . . . . 19  
5.3.6 Userland build tool . . . . . . . . . . . . . . . . . . . . 20  
5.3.9 mmcinitrd.u-boot . . . . . . . . . . . . . . . . . . . . . 25  
5.3.10 Javascript stuff . . . . . . . . . . . . . . . . . . . . . . 25  
5.3.11 Login and SSHD support . . . . . . . . . . . . . . . . 25  
26  
6.1 minidebug . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26  
6.1.1 mdebug . . . . . . . . . . . . . . . . . . . . . . . . . . 27  
6.2 JTAG system-level debugger . . . . . . . . . . . . . . . . . . 27  
6.2.1 Requirements . . . . . . . . . . . . . . . . . . . . . . . 28  
6.2.2 Startup Options . . . . . . . . . . . . . . . . . . . . . 28  
December 28, 2005  
Revision 2.8  
CONTENTS  
4
6.2.3 Control Keys . . . . . . . . . . . . . . . . . . . . . . . 30  
6.2.4 Blast protocol . . . . . . . . . . . . . . . . . . . . . . . 30  
6.2.5 Quick-start download and burn . . . . . . . . . . . . . 30  
6.3 TeraTerm blast extensions . . . . . . . . . . . . . . . . . . . . 32  
6.4 Using U-Boot Networking . . . . . . . . . . . . . . . . . . . . 33  
34  
7.1 Display configuration . . . . . . . . . . . . . . . . . . . . . . . 34  
7.1.2 What displays are supported...? . . . . . . . . . . . . . 36  
7.1.3 Select a supported display . . . . . . . . . . . . . . . . 38  
7.1.4 Define and test a new display . . . . . . . . . . . . . . 39  
7.1.5 Saving settings to Flash EEPROM . . . . . . . . . . . 40  
7.2 Memory size configuration . . . . . . . . . . . . . . . . . . . . 40  
7.3 Upgrading U-Boot . . . . . . . . . . . . . . . . . . . . . . . . 41  
7.4 Touch Panel Calibration . . . . . . . . . . . . . . . . . . . . . 42  
7.5 Ethernet MAC Addresses . . . . . . . . . . . . . . . . . . . . 43  
December 28, 2005  
Revision 2.8  
5
2 Intended Audience  
This document aims to provide the information needed to integrate the  
R
Neonboard into your application. As such, it addresses both hardware  
and software integration.  
3 Overview of features  
R
The following are highlights of the Neonboard.  
Available with Windows Ce or Linux Operating Systems  
Full featured Boot Loader for custom startup  
400 MHz Intel PXA-255 CPU  
32 or 64MB SDRAM  
8 or 32MB Intel StrataFlash (tm) EEPROM  
Silicon Motion SM 501 Graphics Controller  
Active Matrix LCD Support,  
Including Full-Motion Video  
STN Passive LCD Display Support  
4 or 5-Wire Resistive Touch-Screen Support  
44KHz Stereo 16-Bit Audio Output, for Headphones or Speakers  
44KHz Monaural Audio Input (microphone)  
1 RS-232 or TTL Serial Port  
1 USB 1.1 Slave Port  
1 USB 1.1 Master Port  
Built-in 10/100 Ethernet Controller,  
Built-in Interface for Magnetic Stripe Readers and Printers  
MMC Slot for Expanded Storage  
General Purpose I/O for Device Control  
Built-in Switching Power Supply for 5V DC Input  
JTAG Interface  
Customized Versions Available  
4 Hardware feature  
4.1 Layout  
R
As shown in Figure 1, the Neonboard contains a wide variety of I/O  
options for use in your application. Note that some of these may not be  
populated on an evaluation or production board.  
December 28, 2005  
Revision 2.8  
       
4.2 Mounting  
6
Figure 1: Neon board  
4.2 Mounting  
R
R
The Neonboard measures 2.75” by 6.75”, slightly larger than the Hitachiꢀ  
6.2” display, to allow for easy mounting.  
There are four mounting holes 1/4” from each edge in each of the four  
corners, and the holes are 1/8” in diameter.  
4.3 Connector reference  
R
The following is a list of all connector part numbers used on the Neonꢀ  
platform for use in identifying mating parts for your application. Note that  
Boundary Deviceswill periodically switch vendors for these parts, but will  
notify you of any changes that require a new mating part.  
December 28, 2005  
Revision 2.8  
     
4.3 Connector reference  
7
1
1
Figure 2: Connector Pin-outs  
Revision 2.8  
December 28, 2005  
 
4.4 Electrical characteristics  
8
Description  
USB Master  
USB Slave  
I2C  
Manufacturer Part  
FCI  
87520-0010B  
KS-001-BNW  
68897-001  
SINGATRON  
FCI  
Stereo Audio  
Backlight inverter Molex  
Halo  
Singatron  
HFJ11-2450E  
2SJ-43723N13  
53048-0210  
MMC/SD  
TFT Display  
Touch Screen  
Serial Port  
JTAG  
AVX  
14 5638 009 511 862  
Molex  
FCI  
Molex  
52207-0590  
68897-001  
53048-0810  
4.4 Electrical characteristics  
December 28, 2005  
Revision 2.8  
 
9
5 Software features  
R
As provided by Boundary Devices, the Neonboard supports either Win-  
R
dows CE 5or Linux.  
To simplify the installation of either, the Das U-Bootboot loader is in-  
stalled on our evaluation boards, and two MMC cards are shipped to allow  
the use of either operating system.  
The Das U-Boot Boot Loader is a full-featured loader for either Linux or  
Windows CE that supports a wide variety of options for loading your Op-  
erating System and application.  
Boundary Devices ships U-Boot both as a binary image and as source  
code in the form of a patch that adds support for either Neon or BD-2003  
devices.  
The binary image may be burned directly to sector zero of the on-board  
flash.  
The source code will require a set of Linux or Cygwin(Windows) tools  
for cross-compilation. The following section will detail the requirements and  
steps for building.  
5.1.1 Requirements for building under Linux  
Since the Das U-Boot project uses GNU tools, most of the required compo-  
nents will generally be available on a GNU/Linux system.  
The three pieces which may not commonly be installed are the bzip2  
and wget packages and an ARM cross compiler.  
Boundary Devices typically uses GCC-2.95.3 to create U-Boot images,  
since that matches what we use to build the Linux image to run on the  
Neon itself, but the binary distribution of GCC-3.4.3 from GNUARM is a  
nice alternative.  
5.1.2 Requirements for building under Windows with Cygwin  
There are two primary requirements for building under Windows.  
The first, Cygwin, provides a set of Unix utilities under the Windows  
operating system. Since the Cygwin installer allows components to be se-  
lected individually, the following list shows the requirements for building a  
R
Das U-Boot image with Neonsupport. Note that this list is probably  
incomplete, but these should be the only required items which differ from  
the Cygwin installation defaults.  
December 28, 2005  
Revision 2.8  
       
10  
Base/diffutils  
Devel/binutils  
Devel/gcc  
Devel/make  
Devel/patchutils  
Utils/bzip2  
Web/wget  
The second requirement for building is the X-Scale cross-compiler itself.  
The GNUARM project provides a wealth of information needed to build a  
cross-compiler for ARM processors. Thankfully, it also provides an installer.  
As of this writing, Boundary Devices currently uses the GCC-3.4.3 package  
for Cygwin.  
5.1.3 General build steps  
Quick start:  
bzcat u-boot-1.1.2.tar.bz2  
|
tar -xvf  
-
gunzip u-boot-2005-10-21.patch.gz  
patch -p0 <u-boot-2005-10-21.patch  
cd u-boot-1.1.2  
CROSS_COMPILE=arm-elf- make neon_config  
-------- U-Boot Boundary Devices Specific Configuration Script --------  
Choose display type (DA640X240 DA320X240 DA800X480 DA640X480 DA240X320 DA1024X768) []: DA1024X768  
answer  
Choose hardware type (NEONB NEON BD2003) [NEON]:  
answer  
Choose software type (WINCE LINUX) []: WINCE  
answer  
Include minidebug (y n) []:  
answer  
y
CPU speed (100 200 300 400) []: 400  
answer  
Configuration successful.  
make  
Explanation.  
The first four lines retrieve and extract the Das U-Boot sources and add  
R
support for the Neonand BD-2003 devices.  
R
The last two lines configure for the Neonboard itself, and finally, build  
a U-Boot binary. The prompts allow you to select the compile-time defaults  
for the display, operating system, and CPU speed. Including minidebug  
in your U-Boot image allows you to access the debugger while developing  
U-Boot scripts.  
When complete, you’ll find a file named u-boot.bin in your u-boot-1.1.2  
directory.  
5.1.4 Tailoring U-Boot for your application  
The Boundary Devices patches (uboot neon bd2003.diff) make a variety of  
decisions about the boot process which may not match with the needs of  
December 28, 2005  
Revision 2.8  
   
your application.  
11  
In general, the file u-boot-1.1.2/include/configs/neon.h defines these  
choices.  
In particular, the distributed copy currently expects a Windows BMP  
file named bdlogo.bmp to be present on the MMC card and writes it to the  
display, then loads an operating system image from a file named nk.nb0 to  
RAM address 0xa0030000 and executes it.  
Both of these are defined by the lines which resemble this:  
#define CONFIG_BOOTCOMMAND  
"mmcinit; " \  
"fatload mmc 0 a0000000 init.scr ; " \  
"autoscr a0000000 ; "  
As mentioned previously, the Das U-Boot Boot Loader is a very capable  
loader with support for USB and network boot, including BOOTP/DHCP,  
and NFS mounting support. Please refer to the Das U-Boot website for  
details.  
December 28, 2005  
Revision 2.8  
12  
5.1.5 U-Boot Memory layout  
The following diagram shows the general layout of RAM within Das U-Boot.  
32K segment used for page tables.  
Unused RAM  
0xA4000000  
Page Tables  
0xA3FF8000  
0xA3FF7FFF  
Unused High  
Tail of 32MB  
Das U-Boot image  
Heap and Stack  
Frame Buffer  
Unused Low  
0xA2000000  
0xA1FFFFFF  
Extra space between Das U-Boot and 32MB  
boundary  
The Das U-Boot image is loaded 1MB below  
the 32MB boundary  
0xA1F00000+  
0xA1F00000  
0xA1EFFFFF  
The heap and stack are allocated in space  
1
preceding the U-Boot image.  
0xA1EFFFFF-  
0xA1EFFFFF-  
Frame Buffer for BD-2003  
Unused Low RAM  
0xA1EFFFFF--  
0xA1EFFFFF--  
0xA0000000  
December 28, 2005  
Revision 2.8  
 
13  
5.1.6 U-Boot Init Script  
The Das U-Boot boot loader comes with scripting facilities in the form of  
the Hush parser and the autoscript command. You should notice when first  
compiling the package that the Boundary Devices sample uses this to defer  
most board initialization to the MMC card. It does this by setting the  
CONFIG BOOTCOMMAND environment variable as follows.  
#define CONFIG_BOOTCOMMAND  
"mmcinit; fatload mmc  
0
a0000000 init.scr  
;
autoscr a0000000  
"
In English, this instructs U-Boot to initialize the MMC/SD card driver,  
load a file named init.scr from the card to address A0000000 (the start of  
RAM), and execute the script from that memory address. This little bit of  
scripting effectively passes all responsibility of what to do at boot time to  
the MMC card.  
Think of it as a Das U-Boot version of AUTOEXEC.BAT.  
The sample script is defined in u-boot-1.1.2/board/neon/init.script and  
performs the following steps.  
1. Loads and displays a logo. The script looks for an image file named  
logo.bmp on the MMC/SD card. If found, it displays the logo on the  
LCD panel. We recommend that you place a splash image of a size  
matching your display on the MMC card. Note that the bitmap must  
be an 8-bit color bitmap.  
2. Loads and runs Windows CE. Next, the script attempts to load  
NK.nb0 from the MMC/SD card and run it.  
As mentioned earlier, the initialization has been mostly deferred to the  
MMC/SD card, so the compiled script (init.scr) must be placed on the  
card itself. The script is compiled using the Das U-Boot mkimage tool  
during the U-Boot build process.  
The following list is a recap the expected content of the MMC/SD card  
when using the Boundary Devices initialization script.  
Filename Description  
init.scr  
logo.bmp 8-bit color splash image  
NK.nb0 Windows CE image  
Compiled initialization script  
December 28, 2005  
Revision 2.8  
 
5.2 Windows CE  
14  
5.2 Windows CE  
R
As mentioned earlier, the Neonboard ships with a runnable Windows CE  
5.0 image on MMC card. A Board Support Package is also available and  
necessary to tailor the operating system for a given application.  
The following sections describe the process of producing an image match-  
R
ing the one shipped with the Neonboard.  
5.2.1 Prerequisites and components  
R
Most of the tools needed to create a bootable Windows CE 5application  
R
for the Neonboard are provided by Microsoft. The following is a complete  
list of components and where they may be obtained.  
R
Windows CE 5ꢀ  
Embedded Visual C++ 4.0  
Embedded Visual C++ Service Pack Microsoft  
R
NeonBoard Support Package  
5.2.2 BSP Installation  
The Neon BSP is made available as a Windows installer file on the Boundary Devices  
website. This file defines a single BSP for the BD2003 and SM501-supporting  
variants. Installation consists of running the .msi file.  
c:\> .\bsp20050413.msi  
Please check the Documentation page for details about the latest revision  
of the Windows CE BSP.  
As a reference tool for the content of the BSP, you should consider using  
MSI2XML to view the content.  
December 28, 2005  
Revision 2.8  
     
5.2 Windows CE  
15  
5.2.3 Building the demo  
The Platform Builder project used to construct our sample image may be  
found on the Boundary Devices web site.  
After installation of the BSP, this project may be copied to a new direc-  
tory within the WINCE500 PBWorkspaces directory and built using Plat-  
form Builder.  
C:\WINCE500\PBWorkspaces>md bdWeb  
C:\WINCE500\PBWorkspaces>cd bdWeb  
=> ‘bdWeb.pbxml’  
Resolving boundarydevices.com... 66.113.228.134  
Connecting to boundarydevices.com[66.113.228.134]:80... connected.  
HTTP request sent, awaiting response... 200 OK  
Length: 45,478 [text/plain]  
100%[============================================================================>] 45,478  
17:37:40 (58.90 KB/s) ‘bdWeb.pbxml’ saved [45478/45478]  
58.90K/s  
-
C:\WINCE500\PBWorkspaces\bdWeb>.\bdWeb.pbxml  
C:\WINCE500\PBWorkspaces\bdWeb>  
After this is done, you should be able to build the sample WinCE  
platform through the Build OS|Sysgen and Build OS|Build and Sysgen  
Current BSP menu options.  
December 28, 2005  
Revision 2.8  
 
5.3 Linux Support  
16  
5.3 Linux Support  
The Linux Environment for Boundary Devices boards consists of four pri-  
mary pieces, a toolchain, the kernel and device drivers, a user-space build  
tool based on PTXDist and a Javascript runtime used to demostrate the  
capabilities of the hardware.  
5.3.1 Crosstool Linux Toolchain  
Before the kernel and applications can be built, it is first necessary to have  
a cross-compiler toolchain.  
The following examples show how we at Boundary Devices set up our  
toolchains. Please refer to the crosstool site for more complete instructions.  
First, you’ll need to download and unpack crosstool;  
$ tar zxvf crosstool-0.37.tar.gz  
As described in the crosstool Quick Start guide, the next step is to choose  
a starting point with one of the demo build scripts. We’re currently using  
demo-arm-xscale.sh with the following settings (GCC 3.4.3 with Glibc  
version 2.3.5):  
TARBALLS_DIR=/armArchives  
RESULT_TOP=/opt/crosstool  
eval ‘cat arm-xscale.dat gcc-3.4.3-glibc-2.3.5.dat‘ sh all.sh --notest  
We also build the compiler to use software floating point in user space,  
rather than hardware floating point (which traps to the kernel). To do this,  
modify arm-xscale.dat and add the --with-soft-float and --without-fp  
flags as shown below.  
GCC_EXTRA_CONFIG="--with-cpu=xscale --enable-cxx-flags=-mcpu=xscale --with-float=soft"  
GLIBC_EXTRA_CONFIG="--without-fp"  
Also, we typically change the TARGET to read as follows:  
TARGET=arm-linux  
because arm-linux-gcc is just too long!  
Having completed these edits, you can execute the script as follows:  
sh demo-arm-xscale.sh  
December 28, 2005  
Revision 2.8  
   
5.3 Linux Support  
17  
Note that this will take a looong time2. Find something else to do while  
you wait.  
When complete, you should find a whole slew of programs in your  
/opt/crosstool/gcc-3.4.3-glibc-2.3.5/arm-xscale-linux-gnu/bin/ di-  
rectory:  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
-rwxr-xr-x  
1
2
2
2
1
1
2
2
2
1
1
1
2
2
1
1
2
1
1
1
2
1
username cvsd 1900724 Jul 18 20:48 arm-linux-addr2line  
username cvsd 1960214 Jul 18 20:48 arm-linux-ar  
username cvsd 3339533 Jul 18 20:48 arm-linux-as  
username cvsd 331791 Jul 18 21:35 arm-linux-c++  
username cvsd 1855723 Jul 18 20:48 arm-linux-c++filt  
username cvsd 331290 Jul 18 21:35 arm-linux-cpp  
username cvsd 331791 Jul 18 21:35 arm-linux-g++  
username cvsd 330887 Jul 18 21:35 arm-linux-gcc  
username cvsd 330887 Jul 18 21:35 arm-linux-gcc-3.4.3  
username cvsd  
16265 Jul 18 21:35 arm-linux-gccbug  
username cvsd 102084 Jul 18 21:35 arm-linux-gcov  
username cvsd 2373278 Jul 18 20:48 arm-linux-gprof  
username cvsd 2622683 Jul 18 20:48 arm-linux-ld  
username cvsd 1937609 Jul 18 20:48 arm-linux-nm  
username cvsd 2454999 Jul 18 20:48 arm-linux-objcopy  
username cvsd 2595563 Jul 18 20:48 arm-linux-objdump  
username cvsd 1960209 Jul 18 20:48 arm-linux-ranlib  
username cvsd 429743 Jul 18 20:48 arm-linux-readelf  
username cvsd 1806673 Jul 18 20:48 arm-linux-size  
username cvsd 1780595 Jul 18 20:48 arm-linux-strings  
username cvsd 2454994 Jul 18 20:48 arm-linux-strip  
username cvsd  
14395 Jul 18 21:47 fix-embedded-paths  
5.3.2 Crosstool Embedded (Das U-Boot) Toolchain  
The instructions above can be followed to create a toolchain suitable for  
cross-compiling Arm-Linux programs on a host machine. The needs for  
building the boot loader are a bit different, though. In particular, the ’glibc’  
reference above refers very specifically to userspace ”C” and ”C++” libraries  
that defer much of their I/O to the Linux kernel itself through the use of  
system calls.  
Under Das U-Boot, no such system calls exist. In order to support this,  
we need to build a Cross-compiler with a different set of switches. Thank-  
fully, the current crosstool distribution supports that as well through the  
use of a small library known as newlib from Red Hat.  
The next couple of steps will do just that.  
First of all, create a file named  
crosstool-0.37/contrib/newlib/arm-elf-newlib-1.12.0.dat  
and paste the following content into it.  
TARGET=arm-elf  
TARGET_CFLAGS="-O2"  
BINUTILS_DIR=binutils-2.14  
NEWLIB_DIR=newlib-1.12.0  
21 hr, 15 minutes on a 1GHz Athlon w/512MB of RAM  
December 28, 2005  
Revision 2.8  
   
5.3 Linux Support  
18  
GCC_DIR=gcc-3.4.3  
GCC_EXTRA_CONFIG=  
Then, create a shell script named  
following content.  
crosstool-0.37/contrib/newlib/arm-elf.sh  
with the  
#!/bin/sh  
set -ex  
TARBALLS_DIR=/armArchives  
RESULT_TOP=/opt/crosstool  
export TARBALLS_DIR RESULT_TOP  
GCC_LANGUAGES="c,c++"  
export GCC_LANGUAGES  
# You should do the mkdir before running this,  
# and chown /opt/crosstool to yourself so you  
# don’t need to run as root.  
mkdir -p $RESULT_TOP  
# Build the toolchain.  
# Takes a couple hours and a couple gigabytes.  
eval ‘cat arm-elf-newlib-1.12.0.dat‘ sh all-newlib.sh --notest  
echo Done.  
Next, edit the contrib/newlib/getandpatch-newlib.sh file and re-  
place the line that says:  
with the following  
Then, run the script like so.  
$ time sh arm-elf.sh  
5.3.3 GNUARM binaries  
The GNUARM site also has binaries for Linux-X86, though we haven’t used  
them.  
December 28, 2005  
Revision 2.8  
 
5.3 Linux Support  
19  
5.3.4 Kernel 2.4.19  
Arm-Linux kernel version 2.4.19 Linux kernel patches for ARM processors  
Intel PXA support for ARM-Linux  
Boundary Devices support  
5.3.5 Kernel 2.6  
bzcat linux-2.6.11.11.tar.bz2 tar xvf  
|
-
cd linux-2.6.11.11  
bzcat ../boundary-2.6.11.11-2005-11-25.patch.bz2  
cp arch/arm/configs/neon_config ./.config  
|
patch -p1  
yes ""  
make ARCH=arm CROSS_COMPILE=arm-linux- uImage  
|
make ARCH=arm CROSS_COMPILE=arm-linux- oldconfig  
Notes:  
Five Wire touch screen support requires setting  
Sound|OSS|Multimedia Capabilities Port drivers|UCB 1400|Five wire  
(or edit .config and set CONFIG_UCB1400_TS_FIVE_WIRE=y)  
December 28, 2005  
Revision 2.8  
   
5.3 Linux Support  
20  
5.3.6 Userland build tool  
As mentioned before, we at Boundary Devices use a variant of an older  
version of the PTXDist tool to keep track of the cross-compilation needs  
for various libraries. This allows inter-library dependencies to be expressed,  
and also allows the canonical source locations to be used during a build.  
This should really be better documented, but the short and simple build  
instructions are as follows.  
$ tar zxvf userland_20051126.tar.gz  
$ cd userland  
$ make menuconfig  
-- at a minimum, you’ll need to set an archive path to  
a writable directory, and validate your kernel and toolchain  
paths.  
$ make cramfs  
Note that this takes a while (over an hour on a typical machine), but  
will result in a cramfs image being created in the userland/ directory.  
Also note that installation of the [[tinylogin]] program requires privileges  
to [[setuid root]]. Because of this, the makefile rules/tinylogin.mak uses the  
[[sudo]] program. If you don’t have sudo installed, this process will fail.  
If you do, you may see a password prompt very near the end of the build  
process (while installing tinylogin into the root filesystem). To avoid this,  
you can either set your [[sudo]] timeout to something large and perform a  
sudo operation before kicking off the build, or do as I do and set it negative  
(no timeout). For reference, refer to this document or [[man sudoers]].  
The choice of cramfs is for illustration (and because it requires that  
everything be compiled and installed). Refer to Section 5.3.8 for more de-  
tails about the choices available and decisions you need to make regarding  
deployment.  
More specifically, the userland build tool is designed to allow repro-  
ducible builds of entire userland filesystems and device nodes for embedded  
Linux distributions.  
The general flow of the make is as follows:  
1. Configure the system through the kconf tool. This step produces a  
file named .config in the userland directory.  
You should save this file for future reference when you have a set of  
choices that meet your needs. By saving it off to say good.config,  
you can copy it back to .config and reproduce the build later.  
2. Get the source code for each component. Since downloading all of  
December 28, 2005  
Revision 2.8  
 
5.3 Linux Support  
21  
the components may take a while, it is often useful to perform this  
step by itself after configuration.  
The get makefile target can be used to perform this step.  
Note that the original web locations are generally used for each library  
supported by the userland build. This is generally a good thing, but  
also means that things sometimes move.  
We try to keep a set of archives on the Boundary Devices website for  
use when the original sources are unavailable.  
Look here if you can’t find something.  
3. Build libraries under build/ the system through the kconf tool.  
As mentioned earlier, the build tool allows you to express inter-library  
dependencies in their makefile packets.  
The packets for each component are stored in userland/rules and  
consist of both a configuration piece *.in and build instructions *.make.  
The install target can be used to simply build the components with-  
out making a root filesystem.  
4. Install libraries into install/. This mingling of various libraries is  
done to allow simplified include file and library references for depen-  
dent packets.  
5. Build a root filesystem under root/. This step gathers all of  
the executable portions (applications and shared libraries) for each  
component into a root filesystem image. Scripts are also commonly  
installed, as are any supporting configuration files (under root/etc).  
The rootfs target can be used to create the root filesystem without  
creating a flattened image.  
6. Build a device table. This step uses the kernel configuration file to  
create devices.txt, suitable for use with genext2fs, mkcramfs, or  
mkfs.jffs2.  
The devices target can be used to create the device table without  
performing any other build steps.  
7. Flatten the root filesystem into any of cramfs, initrd, or JFFS2  
images for placement in flash or SD card.  
December 28, 2005  
Revision 2.8  
5.3 Linux Support  
22  
5.3.7 Userland libraries and applications  
The following libraries and applications are included in the userland build.  
Name  
Description  
Link  
bdScript  
busybox  
cramfs tools  
libcurl  
e2fsprogs  
flash  
freetype  
jpeg  
Javascript  
ID3 Tag Library MP3 ID tag library  
MP3 Library  
libpng  
libungif  
libmpeg2  
openssh  
openssl  
udhcp  
Boundary Devices Javascript Boundary Devices  
Shell and utilities  
Cramfs Utilities  
HTTP library and more  
Ext2 Filesystem Utilities  
GPL’d Flash Library  
FreeType Text Rendering  
JPEG image library  
Javascript library  
MPEG Audio Decoder  
PNG image library  
GIF decompression  
MPEG decoder library  
SSH Application  
SSL Library  
DHCP Client/Server  
zlib compression library  
zlib  
December 28, 2005  
Revision 2.8  
 
5.3 Linux Support  
23  
5.3.8 Notes about userland root filesystems  
Section 5.3.6 refers to the cramfs target without really indicating its’ use.  
The cramfs option is one of three primary ’bundled’ targets:  
1. cramfs - Creates a single file as a read-only, gzip-compressed image of  
a filesystem tree. When you can nail down the content of your filesys-  
tem, this is a great choice, providing the fastest boot time (around 7  
seconds on a PXA-255) and complete immunity to corruption. This  
filesystem is often used in conjunction with read-write filesystems (ram  
disk for volatile data, or VFAT for semi-static data).  
Requires cramfs support in the kernel (Miscellaneous Filesystems—Compressed  
ROM file system support).  
2. jffs2 - Creates a single file as a read-write, gzip-compressed image of  
a filesystem tree. This is useful for placement in flash, and is fairly  
immune to corruption at the cost of extra time for validation at boot  
(typically 30-45 seconds for a 32MB filesystem).  
Requires JFFS2 support in the kernel (Miscellaneous Filesystems—Journalling  
Flash File System v2).  
3. mmcinitrd/mmcinitrd.u-boot - Creates a single file as a read-  
write, uncompressed image of a filesystem tree suitable for use as an  
initial RAM disk (initrd).  
It requires the following options in the kernel:  
Loopback device support  
Device Drivers—Block Devices  
Initial RAM Disk support Device Drivers—Block Devices  
In addition, this target makes a bunch of other choices for you. Since  
this is a bit involved, discussion of the steps is deferred to Section  
5.3.9.  
The Makefile instructions for each of these is at the tail-end of the  
userland Makefile (userland/Makefile).  
Refer to that file for details, but the bundled image for each is created  
by performing a single command specifying an output file (the image), a  
path name to a directory tree, and the devices.txt file.  
Typical usage for the initrd target is to have the boot loader load the  
image into RAM. Das U-Bootprovides support for handing the load address  
to the Linux kernel through the bootm command.  
Both the cramfs and JFFS2 images may also be mounted directly from  
flash EEPROM using Linux MTD block devices. U-Boot’s support for passing  
December 28, 2005  
Revision 2.8  
 
5.3 Linux Support  
24  
Linux boot command line parameters to the kernel also helps here. Typical  
usage includes is of the following form, which supplies both the MTD partition  
information and the root filesystem reference:  
mtdparts=phys_mapped_flash:1024k(armboot),256k(params),-(rootfs1) root=/dev/mtdblock3 rootfstype=cramfs  
In English, this reads as something like:  
MTD partitions are 1MB (named armboot), 256K(named params),  
with the remainder of flash named rootfs1. The root filesystem  
is in the third partition, and its’ type is cramfs.  
Mounting a JFFS2 image is done in the same manner, except the rootfstype  
parameter has a value of jffs2.  
The U-Boot boot loader supports copying data from RAM to flash for  
upgrades and such. Refer to the unprotect, erase, and cp commands for  
details.  
A third means of mounting one of these root filesystems is to use a loop  
device. In Linux jargon, a loop device is a file that contains a filesystem  
within it. Both the initrd and cramfs images may be used in this fashion as  
shown in the following examples.  
Mount a cramfs file (by far the simplest case).  
~ $ sudo mount -o loop -t cramfs ~/cramfs.img /mnt/cramfs  
Mount an ext2 image (Only slightly harder because mmcinitrd is actually  
gzipped and needs to be gunzip’d first).  
~ $ cp -f mmcinitrd mmc.img.gz  
~ $ gunzip mmc.img.gz  
~ $ sudo mount -o loop -t ext2 ~/mmc.img /mnt/ext2  
To mount a JFFS2 image a bit more is needed. Your kernel needs to  
have mtd and mtdblock support compiled in or installed as modules. Then,  
a mtdram device can be created, you can copy the JFFS2 data to it and  
mount the device.  
The Handhelds site has more information on the topic.  
~
~
$
$
sudo /sbin/insmod mtdram total_size=32768 erase_size=256  
Using /lib/modules/2.4.23_pre8-gss-r2/kernel/drivers/mtd/devices/mtdram.o  
sudo dd if=jffs2.img of=/dev/mtd0  
10809+1 records in  
10809+1 records out  
sudo /sbin/insmod mtdblock  
~
$
Using /lib/modules/2.4.23_pre8-gss-r2/kernel/drivers/mtd/mtdblock.o  
sudo mount -r -t jffs2 /dev/mtdblock/0 /mnt/jffs2/  
ls /mnt/jffs2/  
~
~
$
$
bin etc lib linuxrc opt proc sbin sysfs tmp usr var  
December 28, 2005  
Revision 2.8  
5.3 Linux Support  
25  
5.3.9 mmcinitrd.u-boot  
The mmcinitrd.u-boot userland Makefile target has a lot of parts, but its’  
goal is simple  
Provide an application developer a means of staying focused on  
development without the possibility of trashing a flash.  
It presumes the existence of an SD card formatted with the VFAT filesys-  
tem, and a cramfs image on the SD card (in the root as cramfs.img). The  
mmcinitrd.u-boot file is also typically loaded on the SD card, but that isn’t  
strictly necessary, as long as it is available and handed to the Linux kernel.  
Through a series of steps, it links the /bin, /lib, /usr, /var, /sbin,  
and /share directories from within cramfs.img, leaving the root of the  
filesystem read-write (and volatile), with /mmc referring to the root of the  
SD card.  
Furthermore, it presumes the existence of a script or executable named  
linux init in the root directory of the SD card.  
This is done both as an example and as a useful way of nailing down the  
static pieces of a package (in the cramfs.img file) and allowing read-write  
access to the filesystem during application development.  
The linux init script on the SD card may be modified to start an app  
directly, without any risk of boot failure.  
Look at the file /etc/init.d/rcS for the details of how this is accom-  
plished.  
5.3.10 Javascript stuff  
Refer to the Boundary Devices’ Javascript Manual for details of the Bound-  
ary Devices scripting application.  
5.3.11 Login and SSHD support  
By default, the Userland build tool creates a password file /etc/passwd  
with a root password of BoundaryDevices.  
This is only needed when connecting over sshd.  
Use the menuconfig make target to change this.  
December 28, 2005  
Revision 2.8  
     
26  
6 Development Tools  
6.1 minidebug  
minidebug is a small (under 16k) debugger designed to fit completely within  
the instruction cache on the PXA-255 processor to allow testing of boards  
even in the absence of ROM or RAM.  
It also includes features to download over either serial or Ethernet, al-  
lows the display and manupulation of registers and memory, and supports  
controlled execution through breakpoints and data watchpoints.  
Upon entry, minidebug generally displays a dot (.) prompt, sometimes  
pre-pended by a string that looks like $S00#b3. Fear not. The $S00#b3  
string is used to allow minidebug to work in conjunction with the gdb de-  
bugger on the attached system.  
The following is a list of commands that can be issued at the dot prompt.  
Note that this list can also be retrieved through minidebug by entering a  
question mark (?).  
command params  
description  
BC  
BE  
BS  
address  
address  
address  
Breakpoint clear  
Breakpoint examine  
Breakpoint Set  
BURN  
E
D
address range Burn image at address range to flash  
address Examine and modify memory  
address value Deposit  
DL  
DLW  
G
address  
address  
address  
Start XModem for serial download  
Download wireless  
Go  
GL  
GG  
R
SSID  
T
Go Linux  
address  
Go no cache clear  
Display content of registers  
Set Wireless SSID string  
Trace  
TT  
V
Trace no cache clear  
address range Verify content of flash  
WC  
WR  
WRW  
WW  
?
address  
address  
address  
address  
Watch clear  
Watch read  
Watch read/write  
Watch write  
Show this list of commands  
December 28, 2005  
Revision 2.8  
   
6.2 JTAG system-level debugger  
27  
6.1.1 mdebug  
The mdebug image adds Ethernet and wireless download capabilities using  
R
the Blast protocol to the Neon. The SSID and DLW commands above are  
only valid when mdebug is present.  
The following is an example of the use of mdebug and DLW. Note that  
the first commands used download mdebug to address A1C00000 and run it  
from there. Also note that the use of DLW requires a DHCP or BOOTP  
server for IP address assignment.  
DLW example  
. dl a1c00000  
CCCCCCCCCCC  
enter binary file name: mdebug  
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC.....................  
...................................................  
73620 bytes, 72 packets,  
OK A1C00000-A1C12000  
0
retrys  
.
$S00#b3  
g
a1c00000  
Reset A0008000  
R0: 00000000 R1: 0000014C R2: 00000001 R3: 00000060  
R4: A1F1D540 R5: A1F22B1C R6: A1E9BECC R7: 00000002  
R8: A1E9BFDC R9: A1E9BE88 SL: 00000000 FP: A1E9BE10  
IP: A1E9BE14 SP: A0003400 LR: A0008000 PC: A0008000  
CPSR 600000D3 FP0: 0000000000  
.
.
dlw a0008000  
Boundary Devices  
SMC91C11xFD  
1
%s: PHY=LAN83C183 (LAN91C111 Internal)  
%s: PHY remote fault detected  
%s: Ethernet Link Detected  
%s: PHY 100BaseT  
%s: PHY Half Duplex  
valid mac address  
00:50:C2:06:30:8F  
..........DISC:received 0x012C bytes of reply  
done  
REQ:received 0x012C bytes of reply  
done  
router at 192.168.0.1  
DNS server at 68.2.16.25  
DNS server at 68.2.16.30  
DNS server at 68.6.16.30  
DHCP success, using IP 192.168.0.14  
ready to receive file  
enter binary file name: cramfs.img  
...........................................................  
................  
transmitted in 52 seconds  
.[eof]  
lost 0x00000000 packets  
[eof] in 52 seconds  
sent 19783680 bytes of file to 192.168.0.14  
Error free!!!  
0x012DE000 bytes written to buffer at A0008000 A12E6000  
6.2 JTAG system-level debugger  
The jtag executable provided by Boundary Devices is based on the one  
provided by the Open WinCE project.  
Our main goals in developing the jtag program were to aid in hardware  
debugging and to allow the first flash EEPROM image to be burned onto  
December 28, 2005  
Revision 2.8  
   
6.2 JTAG system-level debugger  
28  
a new device. That said, we also use it extensively as a terminal emulator  
during development and have added a number of extensions for that purpose.  
The current release supports the PXA250, PXA255, PXA270, and SA1100  
(lart untested). It checks the IDCODE register and uses the appropriate  
BSDL structure.  
6.2.1 Requirements  
The jtag executable runs either under Linux or Cygwin.  
Under Linux, there are no known dependencies except for libc and lib-  
stdc++.  
Under Cygwin, the jtag executable requires the ioperm driver to be in-  
stalled. This driver makes the ioperm() and iopl() system calls available  
under Windows for access to the serial and parallel ports. Note that after  
the cygwin package is installed, you still need to enable the driver through  
the use of the ioperm executable  
For the cmd.exe inclined:  
c:\> c:\cygwin\bin\ioperm.exe -v -i  
or for the bash-inclined:  
user@machine ~/u-boot-1.1.2  
$ /bin/ioperm.exe -iv  
Either way, the output should be something like the following.  
Installing ioperm.sys...  
OpenSCManager  
CreateService  
OpenService  
ok  
ok  
ok  
ok  
StartService  
ioperm.sys is already running.  
6.2.2 Startup Options  
jtag -t Generate a square wave on the processor pins.  
This option allows pins to be checked in a sequence defined by the  
hardware file. A ’+’ or ’-’ keypress will scroll forward or backward  
through the list. Also, pin name can be entered directly. Entering  
GP0 will generate a square wave on GP0. A ?’ will list matching pin  
names. Entering GP? will list all gpio pins.  
December 28, 2005  
Revision 2.8  
   
6.2 JTAG system-level debugger  
jtag -i Identify the flash part used  
29  
This option tries to identify the part number of the Flash EEPROM.  
Currently supported parts are 28F160F3B, 28F320J3A, 28F128J3A,  
28F320C3B, and 28F320S3, though not all have been tested. It should  
be relatively easy to add new parts.  
jtag -f Generate the appropriate signals to program a flash.  
This option is rarely used, since we normally program the flash through  
the minidebug software.  
jtag -c Download code to the mini and main instruction cache.  
This option is used to load a file into the instruction cache. Usually  
-x, -e, -or -d option is used to load minidebug. The -d option just  
loads minidebug. The -x option then proceed to dowload a file over  
the serial port using xmodem. The -e option dowloads a file using  
ethernet (wireless and wired support.) The -ssid option can be used  
to specify a wireless essid value to pass to minidebug.  
jtag -s Terminal emulator option.  
The parallel port is still searched because [Ctrl A] B can be used to  
send a JTAG break and attempt to return control to minidebug.  
jtag -N Burn the entire flash.  
This option can be used to burn a flash for the first time.  
It first downloads the file mdebug to ram address A1800000.  
Then it executes an ethernet download of the file totalflash.  
If successful, it then burns the flash using the minidebug(mdebug)  
command BALL (burn all).  
December 28, 2005  
Revision 2.8  
6.2 JTAG system-level debugger  
30  
6.2.3 Control Keys  
Once running, the jtag program responds to a number of command se-  
quences, all beginning with [Ctrl A] .  
[Ctrl A] B Send a break  
[Ctrl A] S Send a file using XModem  
[Ctrl A] L Toggle logging to jtag.log  
[Ctrl A] T Send an ascii file  
[Ctrl A] P Choose baud rate  
[Ctrl A] Q Quit  
[Ctrl A] R Hardware reset  
6.2.4 Blast protocol  
When used with the mdebug image, the jtag program recognizes the start-  
of-download request sent by the device, and will prompt the user for a file  
name to send. Refer to the example in the mdebug section for details.  
6.2.5 Quick-start download and burn  
If you have a minidebug for your platform in the current working directory,  
the following sequence shows the process of using it to download and burn  
a new u-boot image.  
Start debugger.  
$
$
cd ..  
./jtag -d  
ioport 3bc wrote 5d read ff  
using printer port at 378  
IDCODE: 69264013  
Halt released  
-
0110 1001001001100100 00000001001  
1
Waiting for stub  
LDIC finished  
This uses the program minidebug on the arm to download to ram  
using the serial port(xmodem protocol) or blast the file using  
ethernet  
^A  
^A  
^A  
Q
I
T
for quit, ^A  
for sending an RGB bitmap with xmodem, ^A  
to send an ascii file  
B
external break, ^A  
S
for sending  
P
a
baudrate  
file with xmodem,  
DBG-Vector Trap A0008000  
R0: 00000000 R1: 0000014C R2: 00000000 R3: 00000003  
R4: 0000001E R5: 81A0F288 R6: AAA00010 R7: 000BD784  
R8: 00000000 R9: 81A18774 SL: AAA0001C FP: 81A1606C  
IP: 80039094 SP: A0003400 LR: 8006C8CC PC: A0008000  
CPSR 600000D3 FP0: 0000000000  
.
To download using serial, use the ’dl address’ command.  
Hit [Ctrl A] S to send the file (assumes u-boot.bin in the current direc-  
tory). After issuing the DL command, the minidebug will begin sending  
C’s. These are the start commands for XModem, and signal the readiness  
December 28, 2005  
Revision 2.8  
     
6.2 JTAG system-level debugger  
31  
to receive a file. Use the [Ctrl A] S sequence to instruct jtag to prompt  
for and send a file using XModem.  
To abort the operation, either when prompting for a filename or before,  
use [ctrl-C].  
. dl a1f00000  
CCCCCCCCCCCCCC  
enter binary file name: u-boot.bin  
CCCCCCCCCCCCCCCC............................................  
....................................  
81292 bytes, 80 packets, 0 retrys  
OK A1F00000-A1F14000  
To burn a range of data from RAM to the start of flash, use the ’burn’  
command like this. Note that the end address was given above at the end  
of the DL response.  
. burn a1f00000 a1f14000  
Sector 04000000 Erasing Programming Verifying...  
Success  
December 28, 2005  
Revision 2.8  
6.3 TeraTerm blast extensions  
32  
6.3 TeraTerm blast extensions  
As an alternative to the jtag executable, Boundary Devices has also pro-  
duced an extension to the TeraTerm open-source terminal emulator with  
R
support for the Blastprotocol.  
It has the following benefits over the use of jtag:  
Does not require Cygwin and ioperm  
R
Because it’s a Windowsgraphical application, it’s a bit simpler to  
use and has a file-chooser dialog.  
The drawback is that it does not support the jtag hardware connection  
or any of the associated features (can’t force a hardware reset, can’t recover  
a machine with a trashed flash).  
We recommend its use only for non-development needs, or when cabling  
the jtag is inconvenient (e.g. during production).  
It can be downloaded here.  
December 28, 2005  
Revision 2.8  
 
6.4 Using U-Boot Networking  
33  
6.4 Using U-Boot Networking  
One of the most useful features of the Das U-Boot loader is its’ ability to  
transfer files across a network. As shown below, the dhcp command is  
typically used to perform both a BOOTP/DHCP request and transfer a file.  
$
$
$
$
set bootfile nk4.nb0  
set serverip 192.168.0.26  
dhcp  
Using MAC Address 00:50:C2:06:30:8F  
BOOTP broadcast  
1
DHCP client bound to address 192.168.0.14  
TFTP from server 192.168.0.26; our IP address is 192.168.0.14  
Filename ’nk4.nb0’.  
Load address: 0xa0030000  
Loading:  
T
T
#################################################################  
#################################################################  
#################################################################  
#################################################################  
#################################################################  
#################################################################  
...  
#################################################################  
#################################################################  
done  
Bytes transferred  
$
=
23068672 (1600000 hex)  
First of all, the bootfile environment variable is used in the example  
above to define the file to transfer. By default, the boot file is computed  
using a hex representation of the IP address assigned to the device.  
’192.168.0.14’  
=> ’0E00A8C0.img’  
Used with a tftp server that allows symlinks, this provides a convenient  
way to define per-device boot files.  
The second thing to note in the example is the use of the serverip  
environment variable. This variable defines the IP address of the TFTP  
server, in this case ’192.168.0.26’. If your DHCP server allows setting of  
the si addr field in the DHCP response (refer to RFC2131 for details), this  
value can be automatically provided.  
The third thing of interest is the load address (0xa0030000). This value  
is defined in neon.h in the CFG LOAD ADDR macro. It may be overridden  
through the use of the loadaddr environment variable.  
The CONFIG EXTRA ENV SETTINGS macro in configs/neon.h may be  
used to assign the proper compile-time defaults for the environment variables  
listed above.  
The DHCP/BOOTP/TFTP process is relatively fast, even using a slow  
protocol like TFTP. The 23MB transfer above took 20 seconds. Much faster  
than swapping MMC cards. Slower than mdebug/jtag under Linux, but  
faster than Cygwin jtag and blast.  
Any server software that supports RFC1350 should work. The stan-  
dard tftpd daemon under Linux is a good choice. Under Windows, the free  
Tftfpd32 by Philippe Jounin is a very nice tool.  
December 28, 2005  
Revision 2.8  
 
34  
7 Configuration Notes  
7.1 Display configuration  
R
The Neonsupports a variety of LCD panels. The following section de-  
scribes the process of configuring the board for a known, currently supported  
display panel as well as a Das U-Boot utility command for testing settings  
on a new panel.  
If you know the type of panel at compile time, you can place a selection  
from the list below in the Das U-Boot configuration file include/configs/neon.h.  
The CONFIG EXTRA ENV SETTINGS macro is used to define a compile-time  
choice. If you are using EEPROM to store environment settings, these can  
be saved in the environment as well as described below.  
Name  
Resolution Description  
qvga portrait  
hitachi qvga  
sharp qvga  
hitachi hvga  
sharp vga  
240 x 320  
320 x 240  
320 x 240  
640 x 240  
640 x 480  
800 x 480  
Hitachi Quarter VGA 3.5” panel  
Hitachi High-Brightness Quarter VGA  
Sharp Quarter VGA  
Hitachi Half VGA  
Sharp 10.4 inch VGA  
Hitachi Half VGA  
hitachi wvga  
crt1024x768  
1024 x 768 HP SVGA  
For example:  
#define CONFIG_EXTRA_ENV_SETTINGS "panel=hitachi_hvga" "\0"  
Note that this is automatically done as a part of the make neon config  
step.  
The boot loader settings for the LCD panel will carry through to the  
Linux and Windows CE drivers.  
R
If you’re using the Neonwith a new panel, you’ll need to determine  
and define the following fields for the panel.  
December 28, 2005  
Revision 2.8  
   
7.1 Display configuration  
35  
field name  
name  
type  
string  
description  
used to identify the panel  
pixclock  
number Divisor for the pixel clock. Generally  
3 for QVGA, 1 for higher resolution.  
number Horizontal pixel count  
xres  
yres  
number Vertical pixel count  
act high  
hsync len  
left margin  
right margin  
vsync len  
number Clock polarity, 0 (default) or 1  
number Horizontal sync pulse  
number Idle pixels before leftmost pixel  
number Idle pixels after rightmost pixel  
number Vertical sync pulse  
upper margin number Idle rows before topmost  
lower margin number Idle rows after bottom  
active  
crt  
rotation  
number Active Matrix (1) or Passive (0)  
number digital LCD(0) or Analog CRT(1)  
number landscape(0) or portrait(90)  
Once you have collected this information, a corresponding entry must be  
added to the list of panels.  
u-boot-1.1.2/common/lcd_panels.c  
To allow the testing of these settings and the use of a different display  
without re-compiling, the lcdp boot loader command is available. It may  
be used in one of the following ways:  
command string description  
lcdp  
Show the current lcd panel settings  
lcdp ?  
Show the list of currently supported lcd panels  
lcdp panelname Select and initialize panelname  
lcdp + Add a new panel (prompts for details)  
Note that the boot loader text display will not be updated properly if  
the X and Y resolution don’t match the current default display. Use the  
bmp commands to test the new panel configuration after using the lcdp +  
command string.  
As always, the source code is available. The two modules used to support  
dynamic display selection are:  
common/cmd lcdpanels.c - defines U-Boot commands  
common/lcd panels.c - display initialization  
7.1.1 What display is currently selected?  
The lcdp command is used for a variety of purposes including querying the  
currently selected display.  
December 28, 2005  
Revision 2.8  
 
7.1 Display configuration  
36  
$ lcdp  
------------------------------------  
name  
pixclock  
xres  
: crt1024x768  
: 65000000  
: 1024  
: 768  
: 1  
: 200  
: 24  
: 161  
: 6  
yres  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 3  
: 29  
: 0  
7.1.2 What displays are supported...?  
The lcdp command followed by a question mark will list the currently sup-  
ported displays. As shown in the following example, the list is extensive  
(and extensible, as we’ll show later).  
$ lcdp ?  
------------------------------------  
name  
: hitachi_qvga  
pixclock  
xres  
yres  
: 0  
: 320  
: 240  
: 1  
: 64  
: 1  
: 16  
: 20  
: 8  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 3  
: 1  
------------------------------------  
name  
pixclock  
xres  
: sharp_qvga  
: 0  
: 320  
: 240  
: 1  
: 8  
: 16  
: 1  
yres  
act_high  
hsync_len  
left_margin  
right_margin  
December 28, 2005  
Revision 2.8  
 
7.1 Display configuration  
37  
vsync_len  
upper_margin  
lower_margin  
active  
: 20  
: 17  
: 3  
: 1  
------------------------------------  
name  
: hitachi_hvga  
pixclock  
xres  
yres  
: 1  
: 640  
: 240  
: 1  
: 64  
: 34  
: 1  
: 20  
: 8  
: 3  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 1  
------------------------------------  
name  
pixclock  
xres  
: sharp_vga  
: 1  
: 640  
: 480  
: 1  
: 64  
: 60  
: 60  
: 20  
yres  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 34  
: 3  
: 1  
------------------------------------  
name  
: hitachi_wvga  
pixclock  
xres  
yres  
: 1  
: 800  
: 480  
: 0  
: 64  
: 1  
: 39  
: 20  
: 8  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 3  
: 1  
------------------------------------  
December 28, 2005 Revision 2.8  
7.1 Display configuration  
38  
name  
: crt1024x768  
pixclock  
xres  
yres  
: 65000000  
: 1024  
: 768  
: 1  
: 200  
: 24  
: 161  
: 6  
: 3  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 29  
: 0  
$
7.1.3 Select a supported display  
If you supply a supported panel name on the lcdp command line, the display  
controller will be reset with the associated parameters.  
$ lcdp hitachi_wvga  
found panel hitachi_wvga  
panel: 800x480x8  
$ lcdp  
------------------------------------  
name  
: hitachi_wvga  
pixclock  
xres  
yres  
: 1  
: 800  
: 480  
: 1  
: 64  
: 1  
: 39  
: 20  
: 8  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 3  
: 1  
The selection takes place immediately, so if you have a panel connected,  
you should see valid output on the display.  
Note that if you change resolutions, the display memory will likely have  
mis-aligned data in it. Displaying a bitmap on the display through the use  
of the fatload and bmp commands will remedy this situation. Refer to  
init.script for an example.  
If you want to make your selection stick through a reset, you can save it  
through the set and save U-Boot commands.  
December 28, 2005  
Revision 2.8  
 
7.1 Display configuration  
39  
$ set panel hitachi_wvga  
$ save  
Saving Environment to Flash...  
Un-Protected 1 sectors  
Erasing Flash...  
Erased 1 sectors  
Writing to Flash... done  
Protected 1 sectors  
$ reset  
resetting ...  
$S00#b3  
Reset A0008000  
U-Boot 1.1.2 (Jun 10 2005 - 22:31:50)  
U-Boot code: A1F00000 -> A1F20500 BSS: -> A1F54520  
RAM Configuration:  
Bank #0: a0000000 64 MB  
Flash: 32 MB  
panel hitachi_wvga found: 800 x 480  
...  
7.1.4 Define and test a new display  
If you add a plus sign to the lcdp command line, you’ll be prompted for all  
of the parameters needed to define a display.  
$ lcdp +  
name: myDisplay  
pixclock: 65000000  
xres: 800  
yres: 600  
act_high: 1  
hsync_len: 200  
left_margin: 24  
right_margin: 161  
vsync_len: 6  
upper_margin: 4  
lower_margin: 29  
active (0|1) : 1  
------------------------------------  
name  
: myDisplay  
December 28, 2005  
Revision 2.8  
 
7.2 Memory size configuration  
40  
pixclock  
xres  
yres  
: 1694498816  
: 800  
: 600  
: 1  
: 200  
: 24  
: 161  
: 6  
: 4  
act_high  
hsync_len  
left_margin  
right_margin  
vsync_len  
upper_margin  
lower_margin  
active  
: 29  
: 1  
As with switching to a known panel, the settings take effect immediately  
upon completion of the command. This can be a very quick way to add  
support for a new display before committing it to the supported list.  
Adding an entry into the lcd panels array in common/lcd panels.c  
will provide boot-time support.  
7.1.5 Saving settings to Flash EEPROM  
All of the descriptions above are useful, but don’t address the issue of persis-  
tence. That is performed through the use of the ’panel’ environment variable  
and the ’saveenv’ Das U-Boot command.  
The following example shows the process.  
$ set panel crt1024x768  
$ save  
Saving Environment to Flash...  
Un-Protected 1 sectors  
Erasing Flash...  
Erased 1 sectors  
Writing to Flash... done  
Protected 1 sectors  
7.2 Memory size configuration  
R
The Neonsupports either 32 or 64MB of RAM.  
Most of the default boot loader configuration assumes at least 32MB of  
RAM is available. In particular, the TEXT BASE variable in board/neon/config.mk  
links the uboot.bin image at 31MB from the start of RAM.  
December 28, 2005  
Revision 2.8  
   
7.3 Upgrading U-Boot  
41  
Use the PHYS SDRAM 1 SIZE variable in include/configs/neon.h to  
specify the actual size for your hardware.  
The Windows CE image supports either, but defaults to 32MB. Set the  
RAM SIZE 64 MB environment variable in your project to indicate that 64MB  
should be present.  
The RAM size set in the boot loader is passed to the Linux kernel.  
7.3 Upgrading U-Boot  
As you might expect, Das U-Boot is stored at offset zero in flash EEPROM  
(i.e. at address zero). If you have a new Das U-Boot image (typically  
u-boot.bin) on an SD/MMC card, you can upgrade it by first unprotecting  
and erasing the first sector of flash, then copying the new image to address  
zero as shown below.  
$ mmcinit  
...  
registering device  
$ fatload mmc 0 a0008000 u-boot-neon.bin  
reading u-boot-neon.bin  
134264 bytes read in 271921 ticks, (73 ms),  
adler == 0xf0cde398 in 24546 ticks, (6 ms)  
$ protect off all  
Un-Protect Flash Bank # 1  
$ erase 0 3ffff  
Erased 1 sectors  
$ cp.b a0008000 0 $filesize  
Copy to Flash... done  
$ cmp.b a0008000 0 $filesize  
Total of 134264 bytes were the same  
$ reset  
After reset, you should see the new build date in the U-Boot banner.  
December 28, 2005  
Revision 2.8  
 
7.4 Touch Panel Calibration  
42  
7.4 Touch Panel Calibration  
Under Linux, the flash sector at address 0x140000 is used to store the touch-  
screen calibration settings. If you’re using bdScript startup code, the cali-  
bration routine will launch upon first boot if not defined.  
Under Windows CE, the touch screen settings are stored on the MMC  
card in a file named touch.txt. You’ll need to use the mouse to launch the  
touch calibration program.  
December 28, 2005  
Revision 2.8  
 
7.5 Ethernet MAC Addresses  
43  
7.5 Ethernet MAC Addresses  
Normally, Neon boards come with their MAC addresses pre-programmed  
during assembly and test. This is done by using the U-Boot mac command  
as shown below.  
Invoked without an argument, the command will display the current  
MAC address. Used with a single parameter (MAC address with colons  
separating each pair of hex digits), the command will allow (re)programming  
of the MAC address.  
$ mac  
mac address ff:ff:ff:ff:ff:ff  
$ mac 00:50:c2:06:30:b8  
setting mac address to 00:50:c2:06:30:b8  
done  
December 28, 2005  
Revision 2.8  
 

Toshiba HDD1744 User Manual
SIIG ID SC0511 S1 User Manual
Seagate CHEETAH ST3600057FC User Manual
Seagate Cheetah ST336854FC User Manual
Saeco Coffee Makers Armonia Type SIN024X User Manual
Polycom SoundPoint IP 600 SIP User Manual
Philips SAC2530 User Manual
Philips JackRabbit JR32RWDV User Manual
Philips AZ1015 User Manual
Pantech 5U000242C0A User Manual