40 virtual int16_t
last() = 0;
AbstractSampler(const uint8_t pin, const uint16_t periodMs)
virtual void update()=0
Update - must be implemented in derived classes.
const uint8_t _pin
pin to read data from
virtual ~AbstractSampler()
Destructor.
const uint16_t _periodMs
minimum ms
virtual float average()=0
Implement (and document!) in derived classes.
uint8_t pin()
Accessor for the pin which is geting read from.
virtual int16_t last()=0
Get the most recent sample - derived classes must implement.
Base class for analog pin sampling classes.