AN 717: Nios II Gen2 Hardware Development Tutorial

ID 683615
Date 9/22/2014
Public
Document Table of Contents

1.4.4. Developing Software with the Software Build Tools for Eclipse

You can perform all software development tasks for your processor system using the Software Build Tools (SBT) for Eclipse™.

After you generate the system with , you can begin designing your C/C++ application code immediately with the SBT for Eclipse. provides component drivers and a hardware abstraction layer (HAL) which allows you to write programs quickly and independently of the low-level hardware details. In addition to your application code, you can design and reuse custom libraries in your SBT for Eclipse projects.

To create a new C/C++ application project, the SBT for Eclipse uses information from the .sopcinfo file. You also need the .sof file to configure the FPGA before running and debugging the application project on target hardware.

The SBT for Eclipse can produce several outputs, listed below. Not all projects require all of these outputs.

Table 2.   SBT for Eclipse OutputsThe SBT for Eclipse can produce several outputs but not all projects require all of these outputs.
Output Description
system.h file
  • Defines symbols for referencing the hardware in the system.
  • The SBT for Eclipse automatically create this file when you create a new board support package (BSP).
Executable and Linking Format File (.elf) Is the result of compiling a C/C++ application project, that you can download directly to the processor.
Hexadecimal (-Format) File (.hex)
  • Contains initialization information for on-chip memories.
  • The SBT for Eclipse generate these initialization files for on-chip memories that support initialization of contents.
Flash memory programming data
  • Boot code and other arbitrary data you might write to flash memory.
  • The flash programmer adds appropriate boot code to allow your program to boot from flash memory.
  • The SBT for Eclipse includes a flash programmer to allow you to write your program or arbitrary data to flash memory.

This tutorial focuses on downloading only the .elf directly to the system.