Motor Evaluation Kit NEVC-MCTRL-100-t01-1.0.0
Firmware for NEVB-MCTRL-100-01 for trapezoidal control of BLDC motors using Hall-effect sensors
Loading...
Searching...
No Matches
filter.h
Go to the documentation of this file.
1/* This file has been prepared for Doxygen automatic documentation generation.*/
22#ifndef FILTER_H
23#define FILTER_H
24
25// Include standard integer type definitions
26#include "stdint.h"
27
29#define MAX_INT 32767
30
31// Prototypes
32int16_t calculateEMA(uint16_t currentSample, uint16_t previousEMA, uint8_t alphaExponent);
33
34#endif
int16_t calculateEMA(uint16_t currentSample, uint16_t previousEMA, uint8_t alphaExponent)
Exponential Moving Average (EMA) calculation algorithm.
Definition filter.cpp:34