mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-29 02:21:44 +00:00
Added linear digital filters
Linear digital filter class based on code from FRC team 341 Change-Id: I4c5198e36a089e08a6d054bf1bf80392def27e23
This commit is contained in:
committed by
Peter Johnson
parent
6c89f34e44
commit
e15ca5a414
@@ -63,4 +63,14 @@ class TestBench {
|
||||
/* PCM channels */
|
||||
static const int32_t kSolenoidChannel1 = 0;
|
||||
static const int32_t kSolenoidChannel2 = 1;
|
||||
|
||||
/* Filter constants */
|
||||
static constexpr double kFilterStep = 0.005;
|
||||
static constexpr double kFilterTime = 2.0;
|
||||
static constexpr double kSinglePoleIIRTimeConstant = 0.015915;
|
||||
static constexpr double kSinglePoleIIRExpectedOutput = -3.2172003;
|
||||
static constexpr double kHighPassTimeConstant = 0.006631;
|
||||
static constexpr double kHighPassExpectedOutput = 10.074717;
|
||||
static constexpr int kMovAvgTaps = 6;
|
||||
static constexpr double kMovAvgExpectedOutput = -10.191644;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user