...
Info |
---|
Note: Despite the name, Layout Variables are designed to work with Module Arguments, not Module Variables. |
Defining Layout Variables
To open the Layout Variables dialog, select ‘Layout->Layout Variables’ from the Designer menu.
...
There are three sections: predefined variables, user variables, and variable usage.
Predefined Variables
The predefined variables section automatically defines symbols derived from the layout’s HW input pin. If the HW input attributes are changed, these symbol values will also change to match. The TOP convention is used in these variables to indicate that they represent the top level input and output pin values.
TOP_SAMPLERATE — the sample rate of the HW input pin
TOP_BLOCKSIZE — block size in samples of the HW input pin
TOP_BLOCKRATE — HW input sample rate divided by the HW input block size
TOP_NUMIN — HW input pin number of channels
TOP_NUMOUT — HW output pin number of channels
User Variables
The user variables section is where arbitrary symbols can be defined by the user. Symbols must be entered as <SYMBOL> = <VALUE>, one per line. Symbol names must begin with a letter. Symbol characters must be upper or lower case letters, digits, or underscore characters. No other characters or special symbols are allowed. If other text or spaces are entered they will be stripped out when the dialog is closed. For example, a user might define a symbol like “SIGNAL_NOISE_RATIO_THRESH”, and then use it in any module argument field in the layout anywhere that SNR is evaluated.
Variable Usage
The variable usage section shows which module arguments are implementing a given symbol. If a symbol is deleted from the user variables section, the user may refer to the variable usage section to find which modules relied on that symbol. The user can then manually delete/replace the symbol for each of the afflicted module arguments.
Saving User Variables
User Variables are typically saved within the layout, however Designer also supports a separate User Variables file.
...
Info |
---|
Loading user variables from a file will overwrite any existing user variables. |
Using Layout Variables
To use a layout variable precede the symbol with a ‘$’.
...