Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Scroll Documents: Update page title prefix

About This Application Note

The Getting and Setting Parameters and Arrays Application Note describes the ParamGet, ParamSet and ArraySet modules, and their respective usage.

...

These modules can be found in the ‘Misc’ module folder in Audio Weaver Designer’s module palette on the left-hand side of the Designer window:

...

Param Set Module

The ParamSet module takes a signal from an input wire and writes the incoming value to an instance variable in another module:

Image RemovedImage Added

This module is useful for controlling the behavior of other modules in response to control signals or audio signals. This module can set parameters of any type of module, which eliminates the need to use and/or create controllable permutations of each module. The input wire can have any number of channels and any block size. The module only uses the first value in the wire and ignores all others. Internally the module uses two pointers. The first points to the base of the module being controlled. The second pointer points at the variable being written.

...

To set which module and variable the ParamSet module controls, right click on the ParamSet module while Audio Weaver is in Design Mode, and select ‘View Properties’ in the context menu:

Image RemovedImage Added


The ParamSet module’s properties menu will appear at the bottom of the Audio Weaver Designer window. Navigate to the ‘Arguments’ tab to assign the desired module and variable you wish to control:

...

An example layout (‘ParamSet_Example.awd’) further explaining the ParamSet module usage can be found in the ‘C:\DSP Concepts\<AWE Designer>\Examples\Module_Usage’ folder of the default Audio Weaver Designer installation path.

Param Get Module

Similar to the ParamSet module but opposite in functionality, the ParamGet module reads the value of a parameter from an existing module and outputs it on a wire for use elsewhere in the system.

...

An example layout (‘ParamGet_Example.awd’) further explaining the ParamSet module usage can be found in the ‘C:\DSP Concepts\<AWE Designer>\Examples\Module_Usage’ folder of the default Audio Weaver Designer installation path.


Array Set & Param Set Table Modules

Similar to the ParamSet and ParamGet modules which act on scalar values, Audio Weaver also features modules for setting array values. At the time of this application note writing, Audio Weaver does not feature an ArrayGet module. Typically, if a user needs to know the values of an array, outputting the array to a Sink Module or a .csv satisfies any ArrayGet use cases.

Array Set Module

The ArraySet module can set array values of another module, with data from input wire.

...

Table 3: ArraySet setBehavior Values


Param Set Table Module

The ParamSet Table module is similar to the ArraySet module but offers slightly different features for different use cases. The ParamSet Table module writes the values of one column of a statically defined table to an internal array of another module. A common use case is to update the coefficients of an FIR module based on changing conditions in the system.

...

  • dataType

  • numRows

  • numCols

  • modVar

Image RemovedImage Added

The dataType argument specifies the data type of the values in the coeffs array, defined in the module’s ‘Array:coeff’ Properties tab (float, int, fract32).

...

The ParamSet Table module features options to either load a coeff table from a .csv file or save the current table to a .csv file:

Image RemovedImage Added

...

...

Lastly, any time a change is made to the coeff table in the ‘Array: coeff’ tab, Audio Weaver Designer will prompt to either save or discard the changes made to the array:

...

Figure 22: ParamSet Table Coeff Array Save/Cancel Changes


Modules Controlled by the Get/Set Modules

Any module controlled by one of the get/set modules described in this application note, will visually change and display which module it is controlled by in the Audio Weaver Designer canvas, in text under the module. As seen below in Figure 23, the FIR1 module has a dashed outline instead of a solid border, and the text under the module indicate that it’s coeffs array variable is controlled by the CoeffTable1 module:

...