Skip to content

# Class evam::MedianDecor

template <class Motor, unsigned short kWindowSize>

ClassList > evam > MedianDecor

Decorator that applies median filtering with fixed time base. More...

- `#include <evamMedianDecor.h>`

Inherits the following classes: Heartbeat, Motor

## Public Functions

Type | Name
--- | ---
void | Go (signed short aValue)
| MedianDecor ()
void | Reset ()

## Protected Functions

Type | Name
--- | ---
void | onHeartbeat () override

## Detailed Description

Samples the input at regular intervals and applies median filtering to remove spikes and noise. Output updates at the sampling rate.

Template parameters:

- `Motor` Base motor class (must implement Go(signed short))
- `kWindowSize` Filter window size (odd number). Default: 5

## Public Functions Documentation

### function Go

    inline void evam::MedianDecor::Go (
        signed short aValue
    )

### function MedianDecor

    inline evam::MedianDecor::MedianDecor ()

### function Reset

    inline void evam::MedianDecor::Reset ()

## Protected Functions Documentation

### function onHeartbeat

    inline void evam::MedianDecor::onHeartbeat () override

The documentation for this class was generated from the following file `src/evamMedianDecor.h`