Creating your own ready-to- run applications, Creating your own ready-to-run applications –5, Creating your own ready-to-run applications – Altera Embedded Systems Development Kit, Cyclone III Edition User Manual

Page 37

Advertising
background image

5–5

Development Board Version 1.0.

Altera Corporation

Altera Embedded Systems Development Kit, Cyclone III Edition

July 2010

Creating your own Ready-to-Run Applications

Creating your
own Ready-to-
Run
Applications

Designs that you create can also be made selectable by the application
selector i.e. made into a ready-to-run application. To create a ready-to-run
application from your design you will need:

A hardware image (SRAM Object File or SOF)

A software image which runs on that hardware (an Executable and
Linkable format file or .ELF file).

1

This .ELF file is not required if your demo is hardware only
and has no software application associated with it.

The only restrictions are:
a.

The .SOF file must contain a CFI flash component.

b.

The .SOF file must contain a Nios II CPU whose reset address is
set to CFI Flash at offset 0x00000000.

c.

The size of the software image must be no larger than 20
MBytes.

1.

Once you have your working .SOF and .ELF file pair, perform the
following steps to convert them to a loadable application selector-
compatible application.

2.

Copy both the .SOF and .ELF files into a common directory of your
choosing. This directory is where you will convert the files.

3.

Copy the script entitled n2c3.sh located in your development kit in
the <install_dir>/:
examples/application_selector/application_utilities/
flash_file_conversion_script

folder

to the directory where you copied your .SOF and .ELF files.
Optionally, copy it to a directory in the Nios II Command Shell
search path i.e. <nios2 install>/bin

4.

From Start menu, select All Programs, Altera, Nios II EDS, Nios II
<version> Command Shell to open the Nios II Command Shell and

and change to the directory where you copied the .SOF and .ELF
files.

5.

In the Nios II Command Shell type the command
./n2c3.sh <elf_file>.elf <sof_file>.sof

The n2c3.sh script runs the Nios II Command Line utilities sof2flash
and elf2flash to convert the .SOF and .ELF files to application
selector-compatible .FLASH files.

Advertising