4 #include <BufferedSampler.h> 22 const uint16_t r1KOhm,
23 const uint16_t r2KOhm,
25 const uint16_t periodMs=10,
26 const uint8_t samples=10);
virtual float averageVolts()
Get the mean value in the sample set.
Buffered voltage divider based voltage sampler.
uint8_t pin()
Accessor for the pin which is geting read from.
virtual float lastVolts()
Get the most recent voltage value.
BufferedVDivSampler(const uint8_t pin, const uint16_t r1KOhm, const uint16_t r2KOhm, const float vRef=5.0, const uint16_t periodMs=10, const uint8_t samples=10)
Ringbuffer-based sampler for analog values.