Phytec phyCORE-XScale/PXA255 Installation and operating instructions

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 1/8
phyCORE-XScale/PXA255 Development Kit
(KPCM-022)
Loading a Linux Image
This Application Note provides instructions on how to start-up the
phyCORE-PXA255, mounted on the PHYTEC Development Board,
and how to download a Linux kernel via FF-UART RS-232 serial
connection from a Linux-based machine.
Please refer to the phyCORE-PXA255 and Development Board for
phyCORE-PXA255 Hardware Manual for specific information on
such board-level features as jumper configuration, memory mapping,
and pinout.
1System Description
1.1 Hardware Description
The following hardware is necessary for start-up of the
phyCORE-PXA255:
•phyCORE-PXA255 (part # PCM-022-200E)
•Development Board for phyCORE-PXA255 (PCM-990)
•Interface Expansion Board (PCM-985)
•AC adapter supplying 12 VDC, 3.3A, center positive
•RS-232 null-modem cable
•cross-over Ethernet cable1
•host-PC running Linux
1: You may also use a straight Ethernet cable connected to a hub to establish network
connection between the phyCORE-PXA255 hardware and the host-PC.

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 2/8
All PHYTEC hardware components are included in the
phyCORE-PXA255 Basic Development Kit (part #
KPCM-022-200E-B).
1.2 Software Description and Requirements
This Application Note for the phyCORE-PXA255 requires the use of
a terminal program on the host-PC, such as Komport or Minicom for
Linux, together with TFTP services.
The Bootloader used for downloading the Linux kernel is the
Universal Bootloader U-Boot. The Bootloader is pre-installed on the
phyCORE-PXA255 and resides in the on-board Flash memory from
address 0 to 0x40000.
A description of this Bootloader can be found at:
http://sourceforge.net/projects/u-boot/

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 3/8
2Getting Started
2.1 Interfacing the phyCORE-PXA255 to a Host-PC
Downloading a Linux kernel over the Ethernet from a Linux host-PC
to the phyCORE-PXA255/Development Board combination (also
referred to as target hardware) requires use of a terminal program,
such as Minicom or Komport, and the TFTP networking service
installed and activated.
•Copy the folder Linux from the included Tools CD to the root of
your Linux machine.
•Open your terminal program of choice.
•Specify the correct serial interface settings for your system.
•Configure the terminal program to 115200 baud, 8 data bits, no
parity, 1 stop bit, no hardware handshake.
•Connect the included null modem cable from the serial port on
your host-PC to P1 on the Development Board.
•Connect the RJ-45 socket at X23 on the Development Board to the
Linux-based host-PC using a cross-over Ethernet cable1.
•Connect the included 12 VDC power adapter to the power socket
X1 on the Development Board. In the terminal window, you will
see U-Boot startup messages attempting to tftpboot over the
network once power is applied to the target hardware.
•Hit any key to stop tftpboot autoboot, as the environment settings
for the target hardware must first be configured.
1: You may also use a straight Ethernet cable connected to a hub to establish network
connection between the phyCORE-PXA255 hardware and the host-PC.

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 4/8
2.2 Configuring Environmental Variables
•At the PCM022> command prompt, enter the following
environment variable command to view current settings:
PCM022> printenv
A complete list of currently supported U-Boot commands is displayed
after entering "help" in the command line.
•Configure U-Boot environmental variables using the following
commands:
Note:
Be sure to enter the IP address specific to your TFTP server (Linux
machine) and phyCORE-PXA255 module. The values shown below
are used as examples.
PCM022> setenv serverip 192.168.3.10
(IP address of your TFTP server)
PCM022> setenv ipaddr 192.168.3.11
(IP address of the module)
PCM022> setenv netmask 255.255.255.0
(net mask of the network system)
The MAC address of the SMSC91111 Ethernet controller at U7 has
not been programmed into the EEPROM on the module. The PXA255
will read the contents of the EEPROM as FF:FF:FF:FF:FF:FF. U-Boot
will use the MAC address given by the environment variable ethaddr.
•Set the value of ethaddr to the MAC-ID address on the serial
number sticker on phyCORE-PXA255 module (example values
shown below):
PCM022> setenv ethaddr 00:50:C2:32:AE:92

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 5/8
•Set the boot arguments to be passed to the Linux kernel as
described below. Copy and paste the bootargs argument from the
Bootargs.txt file, located in the Linux folder on the PHYTEC
Tool-CD, into the terminal. Example ip addresses shown, be sure
to edit these numbers to match your settings, all arguments must
be in one line:
setenv bootargs root=/dev/mtdblock2 rw
ip=192.168.3.11:192.168.3.10:192.168.3.11:255.255.255.0::eth0:
mem=64M console=ttyS0,115200n8 ide0=0xf6000000,0xf6000800
ide1=0xf7000000,0xf7000800
•Save environment settings with the following command:
PCM022> saveenv
•Print the environment variables to double-check your settings:
PCM022> printenv
Environment variables that appear in the terminal window should be
similar as follows (ipaddr, serverip and ethaddr are example values):
bootdelay=3
baudrate=115200
ethaddr=00:50:C2:32:AE:9D
filesize = 1000000
netmask = 255.255.255.0
ipaddr = 192.168.3.11
serverip = 192.168.3.10
bootargs=root=/dev/mtdblock2 rw
ip=192.168.3.11:192.168.3.10:192.168.3.11:255.255.255.0::eth0:
mem=64M console=ttyS0,115200n8 ide0=0xf6000000,0xf6000800
ide1=0xf7000000,0xf7000800
stdin=serial
stdout=serial
stderr=serial
Environment size: 383/1020 bytes

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 6/8
2.3 Downloading the Linux Kernel and File System
•The following command loads the kernel binary into RAM,
starting at address 0xA3000000:
PCM022> tftpboot a3000000 phyImage
Download is indicated by a status bar in the terminal window and will
take several seconds, depending on the speed of your system.
Please note that a "Warning! MAC addresses don’t match" message
will appear in the terminal window. This can be ignored. The reason
for the message is that the hardware MAC address depends on the
corresponding value stored in the EEPROM connected to the
SMSC91111 Ethernet controller. Upon delivery, the MAC address is
not programmed into the EEPROM, so memory content is
FF:FF:FF:FF:FF:FF, which does not match the MAC-ID on the
module. U-Boot will use the MAC address entered into environmental
variable ethaddr, as described above.
•Erase the required Flash memory area, sector 1-8, in bank #1
(0x40000 – 0x23FFFF) by entering the following command:
PCM022> erase 1:1-8
You will see a sector-by-sector erase of the specified Flash sectors in
the terminal window.
•Copy the kernel from RAM address 0xA3000000 to Flash memory
area 0x40000 – 0x240000 with 0x1FFFFF length:
PCM022> cp.b a3000000 40000 1FFFFF

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 7/8
The copy process will take up to a minute, depending on the speed of
your system. Once the image is copied, a "Copy to Flash… done" or
similar message should appear in the terminal window.
•The following command loads the file system, lu.jffs2, into RAM
starting at address 0xA3000000:
PCM022> tftpboot a3000000 lu.jffs2
Likewise, load of the file system can take about 30 seconds,
depending on the speed of your system.
•Erase Flash memory area, sector 9-127, in bank #1 (0x240000 –
0x2000000).
PCM022> erase 1:9-127
You will again see a sector-by-sector erase of the specified Flash
sectors in the terminal window.
•Back at the command prompt, copy the file system from RAM
address 0xA3000000 to Flash memory area 0x240000 –
0x2000000 with 0x1FFFFF length.
PCM022> cp.b a3000000 240000 1000000
Copying the file system from RAM to Flash will take about ten
minutes given the 16 MByte file size.

Application Note
PHYTEC Technologie Holding AG 2004
Europe: Support Hotline: +49 (6131) 9221-31 http://www.phytec.de
North America: Support Hotline: 1-800-278-9913 http://www.phytec.com
LAN-032e_2 8/8
2.4 Booting from On-Board Flash
•Set the bootcmd variable to boot the kernel image from Flash
memory 0x40000. Upon a reset the Linux kernel will boot from
Flash.
PCM022> setenv bootcmd bootm 40000
PCM022> saveenv
•To boot the kernel from Flash through the Minicom terminal
program without resetting the target hardware, enter the following
command:
PCM022> bootm 40000
•Successful kernel start-up will return a boot-up message in the
terminal window showing the complete system configuration
information. At the end of these initialization messages you will
find the Linux login prompt. For the Login type root and simply
press <Enter> for password:
Login: root
Password: ’press <Enter>’
Now you have successfully downloaded the kernel and file system
over a tftp Ethernet connection into RAM, copied the Linux kernel
and file system from RAM into Flash, and set the environment
variables to automatically boot the kernel from Flash upon a reset.
This manual suits for next models
1
Table of contents
Other Phytec Microcontroller manuals

Phytec
Phytec phyCORE-SC520 User manual

Phytec
Phytec nanoModul-164 Programming manual

Phytec
Phytec miniMODUL-537 User manual

Phytec
Phytec i.MX6UR User manual

Phytec
Phytec phyCORE-LPC3250 Programming manual

Phytec
Phytec IoT-Enablement-Kit 1 User manual

Phytec
Phytec phyCORE-MPC5200B tiny User manual

Phytec
Phytec SYS TEC ELECTRONIC CANopen Chip164 Programming manual

Phytec
Phytec Linux-Kit phyCARD-M Programming manual

Phytec
Phytec phyCORE-167CS User manual