filter clear function
This commit is contained in:
parent
50df1cf9d2
commit
f9745a2e44
@ -17,8 +17,8 @@ float ImuFusion::getAngle(float dT)
|
||||
|
||||
m_angle += dT*rot;
|
||||
|
||||
//float ratio = 0.99;
|
||||
float ratio = 0.95f;
|
||||
float ratio = 0.99;
|
||||
//float ratio = 0.95f;
|
||||
//float ratio = 0.9996;
|
||||
|
||||
float rawAngle = m_pImu->read_acc_deg(axis); // conversion from G to Deg
|
||||
|
@ -16,6 +16,11 @@ float incrementalLPF::filter(float latestValue)
|
||||
return m_filtered;
|
||||
}
|
||||
|
||||
void incrementalLPF::clear()
|
||||
{
|
||||
m_filtered = 0;
|
||||
}
|
||||
|
||||
pt1FilterApply4::pt1FilterApply4(float freqCut)
|
||||
: m_freqCut(freqCut)
|
||||
, m_RC(1.0f / (2.0f * (float)PI * m_freqCut))
|
||||
|
@ -11,6 +11,8 @@ public:
|
||||
|
||||
float filter(float latestValue);
|
||||
|
||||
void clear();
|
||||
|
||||
private:
|
||||
|
||||
float m_filtered;
|
||||
|
Loading…
x
Reference in New Issue
Block a user