|
msp_status | msp_biquad_df1_q15 (const msp_biquad_df1_q15_params *params, const _q15 *src, _q15 *dst) |
| Second-order direct form 1 biquad filter. More...
|
|
msp_status | msp_biquad_cascade_df1_q15 (const msp_biquad_cascade_df1_q15_params *params, const _q15 *src, _q15 *dst) |
| Cascaded direct form 1 biquad filter. More...
|
|
msp_status | msp_biquad_df2_q15 (const msp_biquad_df2_q15_params *params, const _q15 *src, _q15 *dst) |
| Second-order direct form 2 biquad filter. More...
|
|
msp_status | msp_biquad_cascade_df2_q15 (const msp_biquad_cascade_df2_q15_params *params, const _q15 *src, _q15 *dst) |
| Cascaded direct form 2 biquad filter. More...
|
|
msp_status | msp_biquad_df2_ext_q15 (const msp_biquad_df2_ext_q15_params *params, const _q15 *src, _q15 *dst) |
| Second-order direct form 2 biquad filter extended with DC bias and minimum and maximum tracking. More...
|
|
msp_status | msp_biquad_cascade_df2_ext_q15 (const msp_biquad_cascade_df2_ext_q15_params *params, const _q15 *src, _q15 *dst) |
| Cascaded direct form 2 biquad filter extended with DC bias and minimum and maximum tracking. More...
|
|
Functions for performing real Infinite Impulse Response (IIR) filters.
Cascaded direct form 1 biquad filter.
- Details
- Cascaded biquad filter with direct form 1 implementation. The coefficients are passed as an array of second-order sections (SOS matrix) and each section is passed to msp_biquad_df1_q15 to filter the input.
Example filter with three DF1 stages
- LEA Support
- This function is supported by LEA and requires data to be placed into shared LEA memory with 4-byte alignment.
- Parameters
-
params | Pointer to the cascaded biquad direct form 1 parameter structure. |
src | Pointer to the source data to filter. |
dst | Pointer to the destination vector. |
- Returns
- Status of the operation.
- Examples:
- filter_ex3_biquad_cascade_df1_q15.c.
Cascaded direct form 2 biquad filter extended with DC bias and minimum and maximum tracking.
- Details
- Cascaded biquad filter with direct form 2 implementation extended to include bias and minimum and maximum state tracking. The coefficients are passed as an array of second-order sections (SOS matrix) and each section is passed to msp_biquad_df2_ext_q15 to filter the input.
Example filter with three DF2 stages
- LEA Support
- This function is supported by LEA and requires data to be placed into shared LEA memory with 4-byte alignment.
- Parameters
-
params | Pointer to the cascaded biquad direct form 2 parameter structure. |
src | Pointer to the source data to filter. |
dst | Pointer to the destination vector. |
- Returns
- Status of the operation.
- Examples:
- filter_ex5_biquad_cascade_df2_ext_q15.c.
Cascaded direct form 2 biquad filter.
- Details
- Cascaded biquad filter with direct form 2 implementation. The coefficients are passed as an array of second-order sections (SOS matrix) and each section is passed to msp_biquad_df1_q15 to filter the input.
Example filter with three DF2 stages
- LEA Support
- This function is supported by LEA and requires data to be placed into shared LEA memory with 4-byte alignment.
- Parameters
-
params | Pointer to the cascaded biquad direct form 2 parameter structure. |
src | Pointer to the source data to filter. |
dst | Pointer to the destination vector. |
- Returns
- Status of the operation.
- Examples:
- filter_ex4_biquad_cascade_df2_q15.c.
Second-order direct form 1 biquad filter.
- Details
- Second-order biquad filter with direct form 1 implementation. Q15 multiplication is performed with a 32-bit accumulator to avoid intermediate overflow with saturation to Q15 when storing the result.
Biquad DF1 structure
- Pseudo code
y[n] = b0 * x[n] + b1 * x[n-1] + b2 * x[n-2] + a1 * y[n-1] + a2 * y[n-2]
- LEA Support
- This function is supported by LEA and requires data to be placed into shared LEA memory with 4-byte alignment.
- Parameters
-
params | Pointer to the biquad direct form 1 parameter structure. |
src | Pointer to the source data to filter. |
dst | Pointer to the destination vector. |
- Returns
- Status of the operation.
Second-order direct form 2 biquad filter extended with DC bias and minimum and maximum tracking.
- Details
- Second-order direct form 2 biquad filter extended to include bias and minimum and maximum state tracking. Q15 multiplication is performed with a 32-bit accumulator to avoid intermediate overflow with saturation to Q15 when storing the result. The maximum and minimum of the intermediate states are stored in the state structure.
Biquad DF2 structure (extended)
- Pseudo code
y[n] = b0 * w[n] + b1 * w[n-1] + b2 * w[n-2]
w[n] = a0 * x[n] + a1 * x[n-1] + a2 * x[n-2]
- LEA Support
- This function is supported by LEA and requires data to be placed into shared LEA memory with 4-byte alignment.
- Parameters
-
params | Pointer to the biquad direct form 2 parameter structure. |
src | Pointer to the source data to filter. |
dst | Pointer to the destination vector. |
- Returns
- Status of the operation.
Second-order direct form 2 biquad filter.
- Details
- Second-order direct form 2 biquad filter. Q15 multiplication is performed with a 32-bit accumulator to avoid intermediate overflow with saturation to Q15 when storing the result.
Biquad DF2 structure
- Pseudo code
y[n] = b0 * w[n] + b1 * w[n-1] + b2 * w[n-2]
w[n] = a0 * x[n] + a1 * x[n-1] + a2 * x[n-2]
- LEA Support
- This function is supported by LEA and requires data to be placed into shared LEA memory with 4-byte alignment.
- Parameters
-
params | Pointer to the biquad direct form 2 parameter structure. |
src | Pointer to the source data to filter. |
dst | Pointer to the destination vector. |
- Returns
- Status of the operation.