43
4.3.3 Filters
Set_Filtering(Filter1, Filter2, Decimator)
Filter1 (Integer): 2 – 256 or 0.
Filter2 (Integer): 2 – 256 or 0.
Decimator (long): 1 – 1000 or 0.
(Refer to the ‘Filtering’ square in the variables table above.)
Set_Filtering supplies a faster way to change the filtering parameters when
more that one of them has to be changed, as the change operation causes
board reset which is time consuming; individual activations of
Set_Variable would require this time more than once. Specify ‘0’ for a
parameter that needs no change.
For example, in order to set Filter1, Filter2 & Decimator to 11, 22 & 33,
respectively, apply Set_Filtering(11, 22, 33). Now in order to change
Filter1 & Filter2 to 10 & 20, respectively, and leave Decimator unchanged,
apply Set_Filtering(10, 20, 0). Finally, in order to leave both Filter1 &
Decimator unchanged and set Filter2 to 2, apply either Set_Filtering(0, 2,
0), or Set_Variable(wFilter2, 2).
Get_Filtering(Filter1, Filter2, Decimator)
Filter1 (Integer): 2 – 256.
Filter2 (Integer): 2 – 256.
Decimator (long): 1 – 1000.
(Refer to the ‘Filtering’ square in the variables table above.)
The Get_Filtering is functionally equivalent to
Filter1 = Get_Variable(rFilter1)
Filter2 = Get_Variable(rFilter2)
Decimator = Get_Variable(rDecimator)
and has no time advantage, as the get operation does not cause board
reset; the Get_Filtering function has been supplied just for symmetry with
Set_Filtering.