firfilt_crcf
Variants: firfilt_cccf, firfilt_crcf, firfilt_rrrf
Finite impulse response (FIR) filter
Public Functions
firfilt_crcf | firfilt_crcf_create( |
firfilt_crcf | firfilt_crcf_create_kaiser( |
firfilt_crcf | firfilt_crcf_create_rnyquist( |
firfilt_crcf | firfilt_crcf_create_firdespm( |
firfilt_crcf | firfilt_crcf_create_rect( |
firfilt_crcf | firfilt_crcf_create_dc_blocker( |
firfilt_crcf | firfilt_crcf_create_notch( |
firfilt_crcf | firfilt_crcf_recreate( |
firfilt_crcf | firfilt_crcf_copy( |
int | firfilt_crcf_destroy( |
int | firfilt_crcf_reset( |
int | firfilt_crcf_print( |
int | firfilt_crcf_set_scale( |
int | firfilt_crcf_get_scale( |
int | firfilt_crcf_push( |
int | firfilt_crcf_write( |
int | firfilt_crcf_execute( |
int | firfilt_crcf_execute_one( |
int | firfilt_crcf_execute_block( |
unsigned int | firfilt_crcf_get_length( |
const float * | firfilt_crcf_get_coefficients( |
int | firfilt_crcf_copy_coefficients( |
int | firfilt_crcf_freqresponse( |
float | firfilt_crcf_groupdelay( |
Interfaces
firfilt_crcf firfilt_crcf_create(
Create a finite impulse response filter (firfilt) object by directly specifying the filter coefficients in an array
- _h : filter coefficients, shape: (_n, 1)
- _n : number of filter coefficients, 0 < _n
firfilt_crcf firfilt_crcf_create_kaiser(
Create object using Kaiser-Bessel windowed sinc method
- _n : filter length, 0 < _n
- _fc : filter normalized cut-off frequency, 0 < _fc < 0.5
- _as : filter stop-band attenuation [dB], 0 < _as
- _mu : fractional sample offset, -0.5 < _mu < 0.5
firfilt_crcf firfilt_crcf_create_rnyquist(
Create object from square-root Nyquist prototype. The filter length will be \(2 k m + 1 \) samples long with a delay of \( k m + 1 \) samples.
- _type : filter type (e.g. LIQUID_FIRFILT_RRC)
- _k : nominal samples per symbol, 1 < _k
- _m : filter delay [symbols], 0 < _m
- _beta : rolloff factor, 0 < beta <= 1
- _mu : fractional sample offset [samples], -0.5 < _mu < 0.5
firfilt_crcf firfilt_crcf_create_firdespm(
Create object from Parks-McClellan algorithm prototype
- _h_len : filter length, 0 < _h_len
- _fc : cutoff frequency, 0 < _fc < 0.5
- _as : stop-band attenuation [dB], 0 < _as
firfilt_crcf firfilt_crcf_create_rect(
Create rectangular filter prototype; that is \( \vec{h} = \{ 1, 1, 1, \ldots 1 \} \)
- _n : length of filter [samples], 0 < _n <= 1024
firfilt_crcf firfilt_crcf_create_dc_blocker(
Create DC blocking filter from prototype
- _m : prototype filter semi-length such that filter length is 2*m+1
- _as : prototype filter stop-band attenuation [dB], 0 < _as
firfilt_crcf firfilt_crcf_create_notch(
Create notch filter from prototype
- _m : prototype filter semi-length such that filter length is 2*m+1
- _as : prototype filter stop-band attenuation [dB], 0 < _as
- _f0 : center frequency for notch, _fc in [-0.5, 0.5]
firfilt_crcf firfilt_crcf_recreate(
Re-create filter object of potentially a different length with different coefficients. If the length of the filter does not change, not memory reallocation is invoked.
- _q : original filter object
- _h : pointer to filter coefficients, shape: (_n, 1)
- _n : filter length, 0 < _n
firfilt_crcf firfilt_crcf_copy(
Copy object including all internal objects and state
int firfilt_crcf_destroy(
Destroy filter object and free all internal memory
int firfilt_crcf_reset(
Reset filter object's internal buffer
int firfilt_crcf_print(
Print filter object information to stdout
int firfilt_crcf_set_scale(
Set output scaling for filter
- _q : filter object
- _scale : scaling factor to apply to each output sample
int firfilt_crcf_get_scale(
Get output scaling for filter
- _q : filter object
- _scale : scaling factor applied to each output sample
int firfilt_crcf_push(
Push sample into filter object's internal buffer
- _q : filter object
- _x : single input sample
int firfilt_crcf_write(
Write block of samples into filter object's internal buffer
- _q : filter object
- _x : buffer of input samples, shape: (_n, 1)
- _n : number of input samples
int firfilt_crcf_execute(
Execute vector dot product on the filter's internal buffer and coefficients
- _q : filter object
- _y : pointer to single output sample
int firfilt_crcf_execute_one(
Execute filter on one sample, equivalent to push() and execute()
- _q : filter object
- _x : single input sample
- _y : pointer to single output sample
int firfilt_crcf_execute_block(
Execute the filter on a block of input samples; in-place operation is permitted (_x and _y may point to the same place in memory)
- _q : filter object
- _x : pointer to input array, shape: (_n, 1)
- _n : number of input, output samples
- _y : pointer to output array, shape: (_n, 1)
unsigned int firfilt_crcf_get_length(
Get length of filter object (number of internal coefficients)
const float * firfilt_crcf_get_coefficients(
Get pointer to coefficients array
int firfilt_crcf_copy_coefficients(
Copy internal coefficients to external buffer
- _q : filter object
- _h : pointer to output coefficients array, shape: (_n, 1)
int firfilt_crcf_freqresponse(
Compute complex frequency response of filter object
- _q : filter object
- _fc : normalized frequency for evaluation
- _H : pointer to output complex frequency response
float firfilt_crcf_groupdelay(
Compute and return group delay of filter object
- _q : filter object
- _fc : frequency to evaluate