Setting a Dependency Expression - 2024.1 English

Vivado Design Suite User Guide: Creating and Packaging Custom IP (UG1118)

Document ID
Release Date
2024.1 English

In the Vivado IP packager, you can use an expression for the following methods:

  • Enabling or disabling ports or interfaces
  • Enabling or disabling customization parameters
  • Calculating the value of a customization parameter
  • Calculating the width of a port

The syntax that evaluates the expression can reference parameters defined through the Customization Parameters page in the Package IP window.

The variable name of the parameter in the expression view is the parameter name. The variable name is case-sensitive and requires a ($) sigil prefix before the variable name. For example, a parameter named BAUD_RATE has an expression variable reference of $BAUD_RATE.

To create a functioning enablement or an editable expression, use the variable names with numeric and comparison operators to form a Boolean expression. For example:

$BAUD_RATE == 115200 || $BAUD_RATE == 57600

To create a functioning dependency expression, use the variable names to form a mathematical expression to generate a value. For example:

Table 1. Variable Names to Generate a Value
Expression Type Valid Operations
Operators "div", "or", "and", "mod"
Functions "number", "sum", "floor", "ceiling", "round", "not"
Literals "true", "false"
Spirit Functions "spirit:pow", "spirit:log", "xilinx:max"
Note: All dependency expressions are evaluated as a Tcl expr code.