diff --git a/middleware/simple_ema.c b/middleware/simple_ema.c index c1912a0..567b107 100644 --- a/middleware/simple_ema.c +++ b/middleware/simple_ema.c @@ -1,6 +1,6 @@ #include +#include "simple_ema.h" -// Exponential Moving Average Lowpass Filter void ema_filter(float current_value, float *previous_ema, float alpha) { *previous_ema = diff --git a/middleware/simple_ema.h b/middleware/simple_ema.h new file mode 100644 index 0000000..901e787 --- /dev/null +++ b/middleware/simple_ema.h @@ -0,0 +1,7 @@ +#ifndef SIMPLE_EMA +#define SIMPLE_EMA + +// Exponential Moving Average Lowpass Filter +ema_filter(float current_value, float *previous_ema, float alpha); + +#endif /* SIMPLE_EMA */ \ No newline at end of file