Nios II Custom Instruction User Guide

ID 683242
Date 4/27/2020
Public
Document Table of Contents

4.1.8. Configuring the Custom Instruction Signal Type

To configure the custom instruction signal type, follow these steps:

  1. In the View menu, click Signals to open the Signals tab.
    Figure 18. Custom Instruction Signal Types
  2. For each signal in the list, follow these steps:
    1. Select the signal name.
    2. In the Interface column, select the name of the interface to which you want to assign the signal.
      In the design example, select nios_custom_instruction_slave for all signals. These selections ensure that the signals appear together on a single interface, and that the interface corresponds to the design example files in the crc_hw folder.
    3. In the Signal Type column, select one of the standard hardware ports listed in “Custom Instruction Types”. In the design example, each signal must be mapped to the signal type of the same name.
  3. Open the Signals and Interfaces tab.
    Figure 19. Signals and Interfaces
    The parameters for Clock Cycle Type automatically change to "Variable" because the design example builds a variable multicycle type custom instruction. For other designs, you enter the correct clock cycle type for your custom instruction design:
    • "Variable" for a variable multicycle type custom instruction
    • "Multicycle" for a fixed multicycle type custom instruction
    • "Combinatorial" for a combinational type custom instruction.

    If the interface does not include a clk signal, the component editor automatically infers that the interface is a combinational type interface. If the interface includes a clk signal, the component editor automatically infers that the interface is a multicycle interface. If the interface does not include a done signal, the component editor infers that the interface is a fixed multicycle type interface. If the interface includes a done signal, the component editor infers that the interface is a variable multicycle type interface.