The static parameters of the FIR define how the FIR IP is parameterized and specifies non-dynamic items such as the input and output widths, the number of fractional bits, the coefficient values, the interpolation and decimation rates. Most of these configurations have default values: there are no default values for the coefficients.
The hls_fir.h header file defines a struct hls::ip_fir::params_t
that can be used to set
the default values for most of the static parameters.
In this example, a new user struct my_config
is defined and with a new value for the coefficients. The coefficients are specified as residing in array coeff_vec
. All other parameters to the FIR use the default values.
struct myconfig : hls::ip_fir::params_t {
static const double coeff_vec[sg_fir_srrc_coeffs_len];
};
static hls::FIR<myconfig> fir1;
fir1.run(fir_in, fir_out);
FIR Static Parameters describes the parameters used for the parametrization struct
hls::ip_fir::params_t
. FIR Struct Parameter Values provides the default values for the
parameters and a list of possible values.