Nios II Classic Software Developer’s Handbook

ID 683282
Date 5/14/2015
Public
Document Table of Contents

2.12.2.1. Preparing your Software for ModelSim

Creating the software projects is nearly the same as when you run the project on hardware. To prepare your software for ModelSim simulation, perform the following steps:
  1. Create your software project.

    If you need to initialize a user-defined memory, you must take special steps to create memory initialization files correctly.

  2. Build your software project.
  3. Create a ModelSim launch configuration with the following steps:
    1. Right-click the application project name, point to Run As, and click Run Configurations. In the Run Configurations dialog box, select Nios II ModelSim, and click the New button.
    2. In the Main tab, ensure that the correct software project name and .elf file are selected.
    3. Click Apply to save the launch configuration.
    4. Click Close to close the dialog box.

      If you are simulating multiple processors, create a launch configuration for each processor, and create a launch group.

  4. Open the run configuration you previously created. Click Run. The Nios II SBT for Eclipse performs a make mem_init_generate command to create memory initialization files, and launches ModelSim.
  5. At the ModelSim command prompt, type ldr.