25 #ifndef ACE_BUTTON_TIMING_STATS_H 26 #define ACE_BUTTON_TIMING_STATS_H 47 uint16_t getMax()
const {
return mMax; }
49 uint16_t getMin()
const {
return mMin; }
51 uint16_t getAvg()
const {
return (mCount > 0) ? mSum / mCount : 0; }
66 void update(uint16_t duration) {
70 if (duration < mMin) {
73 if (duration > mMax) {
76 mExpDecayAvg = (mExpDecayAvg + duration) / 2;
80 uint16_t mExpDecayAvg;