xlGetReOrderedCoeff - 2023.2 English

Vitis Model Composer User Guide (UG1483)

Document ID
UG1483
Release Date
2023-11-15
Version
2023.2 English

The xlGetReOrderedCoeff function provides the re-ordered coefficient set of a FIR Compiler block.

Syntax


A = xlGetReOrderedCoeff(new_coeff_set, returnType, handle)

Description

Note: All three parameters of this function are required.
new_coeff_set
The new coefficient set that needs to be loaded into an existing FIR Compiler. Must be supplied to the function in the original order.
handle
Provides the scheme by which the cofficients will be re-ordered. This can either be a handle to the FIR Compiler block in the design, or the path to a reload.txt file generated by the IP repository. If a FIR Compiler block is selected on the Simulink canvas, then the handle can be specified as gcbh.
returnType
Specifies whether to return the re-ordered coefficients or just the reload order. This value can be specified as either coeff or index. A coeff return type will modify the required coefficient set and provide the re-arranged coefficient set that can be directly supplied to the FIR compiler block. The index return type provides only the coefficient address vector using the new_coeff_set that needs to be processed manually.

Examples

Example 1:

If A is a row vector of coefficients, then the coefficients sorted in the reload order can be obtained as follows:


reload_order_coefficients = xlGetReOrderedCoeff(A,'coeff', gcbh)

In this example, reload_order_coefficients specifies the order in which coefficients contained in A should be passed to the FIR Compiler through the reload channel.

Alternatively, the reload address vector can be obtained:

reload_order_coefficients = A(xlGetReOrderedCoeff(A,'index',gcbh))

Example 2:

This example shows how to use an text file, generated by the IP repository, to specify the reload order.


reload_order_coefficients = xlGetReOrderedCoeff(A,'coeff','reload_<version>.txt')

See Also

FIR Compiler 7.2 block