add 2nd order low pass block

This commit is contained in:
Thomas Gubler
2015-09-06 15:46:59 +02:00
parent b7847e13a6
commit 040d1da8a1
2 changed files with 36 additions and 0 deletions
+8
View File
@@ -198,6 +198,14 @@ int blockHighPassTest()
return 0;
}
float BlockLowPass2::update(float input)
{
if (_lp.get_cutoff_freq() != getFCutParam()) {
_lp.set_cutoff_frequency(_fs, getFCutParam());
}
return _lp.apply(input);
}
float BlockIntegral::update(float input)
{
// trapezoidal integration