VISTA Knock Filter
This MotoHawk™ block updates the Filter Coefficients to the named Knock Device.
Block ID
VISTA Knock Filter
Library
MotoHawk_lib/Knock Blocks
Description
Filter Form
The VISTA IIR filter coefficients describe 4 cascaded Bi-quads like so:
The filter has the form:
h(z) = | b0A+b1Az-1+b2Az-2 | X | b0B+b1Bz-1+b2Bz-2 | X | b0C+b1Cz-1+b2Cz-2 | X | b0D+b1Dz-1+b2Dz-2 |
1+a1Az-1+a2Az-2 | 1+a1Bz-1+a2Bz-2 | 1+a1Cz-1+a2Cz-2 | 1+a1Dz-1+a2Dz-2 |
Note:
b0A represents the b0 numerator coefficient for biquad A
a2D represents the a2 denominator coefficient for biquad D
Sampling Frequency
The sampling frequency of the VISTA device is 156.25kHz. This directly influences coefficient calculation.
Filter Update
Thus, from above, a filter coefficient definition is represented by a vector of 20 int16 coefficients (5 for each bi-quad). They have a fixed point scaling scaled where 4.0 is equivalent to 32768. An update executes when triggered, but the coefficients will only be applied to the device if they have changed. The update is skipped if the coefficients have not changed. Note that updating the coefficients invalidates knock detection for time while the filter "settles" to account for the new coefficient set.
Vector Index | Coefficient |
---|---|
0 | a1A |
1 | a2A |
2 | b0A |
3 | b1A |
4 | b2A |
5 | a1B |
6 | a2B |
7 | b0B |
8 | b1B |
9 | b2B |
10 | a1C |
11 | a2C |
12 | b0C |
13 | b1C |
14 | b2C |
15 | a1D |
16 | a2D |
17 | b0D |
18 | b1D |
19 | b2D |
The Knock IIR Filter Calibration block provides a convenient mechanism to define the coefficients in a manner suitable for use with this block.
Block Parameters
Parameter Field | Values | Comments/Description |
---|---|---|
Name | Alpha-numeric text, single-quote enclosed | Name of the VISTA knock device to be affected. |