Andrew Tridgell
cd1f5ca494
Filter: use CLASS_NO_COPY
2021-06-08 11:14:52 +10:00
Andrew Tridgell
6cae97446a
Filter: added auto-init to LowPassFilter
...
make sure initial filter returns are not a long way off if filtered
input is far from zero
2021-04-15 06:57:16 +10:00
Andrew Tridgell
b165e025d9
Filter: added new constructor for 1p filter
...
allow both sample rate and cutoff to be specified in constructor
2016-11-25 17:49:57 +11:00
Andrew Tridgell
f94e4b4375
Filter: allow 1P LowPassFilter to work without alpha recalc per sample
...
this makes the 1P filter optionally syntax compatible with the 2P
filter and much more CPU efficient.
2016-11-10 11:43:29 +11:00
Mathieu OTHACEHE
152edf7189
Global: remove mode line from headers
...
Using a global .dir-locals.el file is a better alternative than
reincluding the same emacs header in every file of the project.
2016-10-24 09:42:01 -02:00
Lucas De Marchi
98904825cb
Filter: replace header guard with pragma once
2016-02-18 14:52:35 -02:00
Tom Pittenger
4ee2fb6c7a
Filter: compiler warnings - unused template <double>
2015-12-07 15:50:00 +09:00
dgrat
58e2ac4e56
Filter: Template implementation for <Filter>
...
There are implementations for float, Vector2f and Vector3f for the Low
Pass Filter and the *2p filter. I tried to implement these filters
with one common template implementation. This implementation saves
some lines of code and reduced the redundancy. One could save even
more code if the currently overloaded isinf/isnan functions and checks
can be removed.
Signed-off-by: Daniel Frenzel <dgdanielf@gmail.com>
2015-08-23 11:17:02 +10:00
Gustavo Jose de Sousa
a1af0c2051
Filter: standardize inclusion of libaries headers
...
This commit changes the way libraries headers are included in source files:
- If the header is in the same directory the source belongs to, so the
notation '#include ""' is used with the path relative to the directory
containing the source.
- If the header is outside the directory containing the source, then we use
the notation '#include <>' with the path relative to libraries folder.
Some of the advantages of such approach:
- Only one search path for libraries headers.
- OSs like Windows may have a better lookup time.
2015-08-11 16:38:24 +10:00
Randy Mackay
1289208244
LowPassFilter: add get method
2015-06-12 21:36:24 +09:00
Randy Mackay
151707cb0a
Filter: replace 2*M_PI_F with M_2PI_F
2015-05-05 14:22:52 +09:00
Randy Mackay
99a9a88529
Filter: dt check fix for LPF
2015-04-17 10:59:03 +09:00
Jonathan Challinger
f20a91ec95
Filter: add dt<0 check to LPF
2015-04-17 10:47:06 +09:00
Randy Mackay
22e1156c31
Filter: add some comments to LowPassFilter
2015-04-17 10:47:04 +09:00
Jonathan Challinger
76da2868d0
Filter: rework LowPassFilter
2015-04-17 10:46:42 +09:00
Randy Mackay
ca92821445
Filter: LowPassFilter gets another div-by-zero check
2015-04-01 10:34:28 -07:00
Jonathan Challinger
57f8a4d29d
Filter: add get_cutoff_frequency
2015-04-01 10:15:07 -07:00
Randy Mackay
4b78b2ce80
Filter: add get method to LowPassFilter
2015-03-03 15:48:58 +09:00
Randy Mackay
cf35bd3f42
LowPassFilter: add div by zero check
2014-09-21 17:33:59 +09:00
Randy Mackay
a0369b85d1
LowPassFilter: make methods non-virtual
...
No classes inherit from this class so no need for set_cutoff_frequency,
set_time_constant and reset(T) to be declared virtual. Saves 6 bytes of
RAM.
2014-02-10 20:47:05 +09:00
Andrew Tridgell
97b7130bb9
libraries: update license header to GPLv3
...
we switched to GPLv3 a long time ago, but neglected to update the
per-file license headers
2013-08-30 13:01:39 +10:00
James Bielman
5631f865b2
Update floating point calculations to use floats instead of doubles.
...
- Allows use of hardware floating point on the Cortex-M4.
- Added "f" suffix to floating point literals.
- Call floating point versions of stdlib math functions.
2013-01-16 13:52:01 +11:00
Andrew Tridgell
30b50a858d
Filter: fixed a warning on PX4
2013-01-11 21:17:34 +11:00
Pat Hickey
84e0dd406e
Filter: ported to AP_HAL
2012-12-20 14:51:25 +11:00
rmackay9
957d366cca
Filter: improved low pass filter allows setting gain using time_step and cutoff freq
2012-11-19 01:06:06 +09:00
uncrustify
406abb3fa0
uncrustify libraries/Filter/LowPassFilter.h
2012-08-21 19:04:30 -07:00
rmackay9
2b2dbf2a7f
Filter - added simple LowPassFilter (simple but it's possible to make errors with simple stuff too so might as well have one)
2012-03-25 16:15:25 +09:00