Visible to Intel only — GUID: mwh1416946765079
Ixiasoft
Visible to Intel only — GUID: mwh1416946765079
Ixiasoft
7.2. The Nios® II Embedded Project Structure
Every HAL-based Nios® II program consists of two Nios® II projects.
For more information, refer to the figure above. Your application-specific code is contained in one project (the user application project), and it depends on a separate BSP project (the HAL BSP).
The application project contains all the code you develop. The executable image for your program ultimately results from building both projects.
With the Nios® II SBT for Eclipse, the tools create the HAL BSP project when you create your application project. In the Nios® II SBT command line flow, you create the BSP using nios2-bsp or a related tool.
The HAL BSP project contains all information needed to interface your program to the hardware. The HAL drivers relevant to your hardware system are incorporated in the BSP project.
The BSP project depends on the hardware system, defined by a SOPC Information File (.sopcinfo). The Nios® II SBT can keep your BSP up-to-date with the hardware system. This project dependency structure isolates your program from changes to the underlying hardware, and you can develop and debug code without concern about whether your program matches the target hardware.
You can use the Nios® II SBT to update your BSP to match updated hardware. You control whether and when these updates occur.
For more information about how the SBT keeps your BSP up-to-date with your hardware system, refer to “Revising Your BSP” in the " Nios® II Software Build Tools" chapter.
In summary, when your program is based on a HAL BSP, you can always keep it synchronized with the target hardware with a few simple SBT commands.