Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
15 years ago

SOPC export VHDL generic to top

Hi,

is it possible to export a VHDL-generic of a custom SOPC Component to the Top-Level of the SOPC-System (As i do with the conduit signals)? Is there a TCL-command for the coponent to do this? I dont want the generic to appear on the parameters GUI, i want to set the paramters when i instantiate the SOPC-System.

Paddy

2 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi Paddy

    Use the add_parameter command in the custom component *_hw.tcl file.

    For example:

    add_parameter my_param int 100 "parameter value"

    set_parameter_property my_param DISPLAY_NAME My_parameter

    set_parameter_property my_param UNITS NONE

    where my_param is your VHDL generic definition.

    Regards
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi Cris72,

    thats what is in my tcl-file:

    add_parameter my_nbr INTEGER 0

    set_parameter_property my_nbr DEFAULT_VALUE 0

    set_parameter_property my_nbr DISPLAY_NAME my_nbr

    set_parameter_property my_nbr TYPE INTEGER

    set_parameter_property my_nbr UNITS None

    set_parameter_property my_nbr ALLOWED_RANGES -2147483648:2147483647

    set_parameter_property my_nbr AFFECTS_GENERATION false

    set_parameter_property my_nbr HDL_PARAMETER true

    the Parameter my_nbr always appears in the component GUI and the SOPC-Builder geneates a file which wraps the VHDL-File of my component and sets the generic to the value i entered in the GUI. But i want the generic to appear at the top-level of my SOPC-System, so that my other VHDL-Code can set the parameters when i instatiate the SOPC-system.