229 extern FILTER_SO_Handle
FILTER_SO_init(
void *pMemory,
const size_t numBytes);
238 #ifdef __TMS320C28XX_CLA__
239 #pragma FUNC_ALWAYS_INLINE(FILTER_SO_run)
257 float_t y0 = (b0 * inputValue) + (b1 * x1) + (b2 *
x2) - (a1 * y1) - (a2 *
y2);
261 obj->
x1 = inputValue;
288 float_t y0 = (b0 * inputValue) - (a1 * y1) - (a2 *
y2);
319 float_t y0 = (b0 * inputValue) + (b1 * x1) - (a1 *
y1) - (a2 * y2);
323 obj->
x1 = inputValue;
477 #endif // end of _FILTER_SO_H_ definition
static void FILTER_SO_set_b2(FILTER_SO_Handle handle, const float_t b2)
Sets the second-order filter numerator coefficient b2.
float_t y1
the output value at time sample n=-1
void FILTER_SO_setNumCoeffs(FILTER_SO_Handle handle, const float_t b0, const float_t b1, const float_t b2)
Sets the second-order filter numerator coefficients.
Contains the public interface to the types definitions.
static float_t FILTER_SO_get_y2(FILTER_SO_Handle handle)
Gets the second-order filter output value at time sample n=-2.
_iq a1
the denominator filter coefficient value for z^(-1)
FILTER_SO_Handle FILTER_SO_init(void *pMemory, const size_t numBytes)
Initializes the second-order filter.
float_t x2
the input value at time sample n=-2
_iq y1
the output value at time sample n=-1
static float_t FILTER_SO_get_b1(FILTER_SO_Handle handle)
Gets the second-order filter numerator coefficient b1.
float_t y2
the output value at time sample n=-2
static float_t FILTER_SO_run_form_0(FILTER_SO_Handle handle, const float_t inputValue)
Runs a simplified second-order filter of the form y[n] = b0*x[n] - a1*y[n-1] - a2*y[n-2].
static void FILTER_SO_set_b0(FILTER_SO_Handle handle, const float_t b0)
Sets the second-order filter numerator coefficient b0.
static void FILTER_SO_set_a2(FILTER_SO_Handle handle, const float_t a2)
Sets the second-order filter denominator coefficient a2.
float_t a1
the denominator filter coefficient value for z^(-1)
static void FILTER_SO_set_y2(FILTER_SO_Handle handle, const float_t y2)
Sets the second-order filter output value at time sample n=-2.
static float_t FILTER_SO_get_y1(FILTER_SO_Handle handle)
Gets the second-order filter output value at time sample n=-1.
Defines the second-order filter (FILTER_SO) object.
float_t b0
the numerator filter coefficient value for z^0
struct _FILTER_SO_Obj_ FILTER_SO_Obj
Defines the second-order filter (FILTER_SO) object.
static void FILTER_SO_set_x2(FILTER_SO_Handle handle, const float_t x2)
Sets the second-order filter input value at time sample n=-2.
void FILTER_SO_setInitialConditions(FILTER_SO_Handle handle, const float_t x1, const float_t x2, const float_t y1, const float_t y2)
Sets the initial conditions of the second-order filter.
float_t a2
the denominator filter coefficient value for z^(-2)
static float_t FILTER_SO_get_a2(FILTER_SO_Handle handle)
Gets the second-order filter denominator coefficient a2.
static void FILTER_SO_set_x1(FILTER_SO_Handle handle, const float_t x1)
Sets the second-order filter input value at time sample n=-1.
static float_t FILTER_SO_get_x1(FILTER_SO_Handle handle)
Gets the second-order filter input value at time sample n=-1.
static float_t FILTER_SO_get_b2(FILTER_SO_Handle handle)
Gets the second-order filter numerator coefficient b2.
float_t b1
the numerator filter coefficient value for z^(-1)
void FILTER_SO_getInitialConditions(FILTER_SO_Handle handle, float_t *px1, float_t *px2, float_t *py1, float_t *py2)
Gets the initial conditions of the second-order filter.
_iq y2
the output value at time sample n=-2
static void FILTER_SO_set_b1(FILTER_SO_Handle handle, const float_t b1)
Sets the second-order filter numerator coefficient b1.
Defines the second-order filter (FILTER_SO) object.
float_t x1
the input value at time sample n=-1
static float_t FILTER_SO_get_x2(FILTER_SO_Handle handle)
Gets the second-order filter input value at time sample n=-2.
_iq a2
the denominator filter coefficient value for z^(-2)
static float_t FILTER_SO_get_a1(FILTER_SO_Handle handle)
Gets the second-order filter denominator coefficient a1.
float_t b2
the numerator filter coefficient value for z^(-2)
struct _FILTER_SO_Obj_ * FILTER_SO_Handle
Defines the second-order filter (FILTER_SO) handle.
_iq x2
the input value at time sample n=-2
_iq x1
the input value at time sample n=-1
_iq b2
the numerator filter coefficient value for z^(-2)
void FILTER_SO_setDenCoeffs(FILTER_SO_Handle handle, const float_t a1, const float_t a2)
Sets the second-order filter denominator coefficients.
void FILTER_SO_getNumCoeffs(FILTER_SO_Handle handle, float_t *pb0, float_t *pb1, float_t *pb2)
Gets the second-order filter numerator coefficients.
static float_t FILTER_SO_run(FILTER_SO_Handle handle, const float_t inputValue)
Runs a second-order filter of the form y[n] = b0*x[n] + b1*x[n-1] + b2*x[n-2] - a1*y[n-1] - a2*y[n-2]...
static float_t FILTER_SO_run_form_1(FILTER_SO_Handle handle, const float_t inputValue)
Runs a second-order filter of the form y[n] = b0*x[n] + b1*x[n-1] - a1*y[n-1] - a2*y[n-2].
static float_t FILTER_SO_get_b0(FILTER_SO_Handle handle)
Gets the second-order filter numerator coefficient b0.
static void FILTER_SO_set_y1(FILTER_SO_Handle handle, const float_t y1)
Sets the second-order filter output value at time sample n=-1.
_iq b0
the numerator filter coefficient value for z^0
void FILTER_SO_getDenCoeffs(FILTER_SO_Handle handle, float_t *pa1, float_t *pa2)
Gets the second-order filter denominator coefficients.
static void FILTER_SO_set_a1(FILTER_SO_Handle handle, const float_t a1)
Sets the second-order filter denominator coefficient a1.
float float_t
Defines the portable data type for 32 bit, signed floating-point data.
_iq b1
the numerator filter coefficient value for z^(-1)