SparkFun_MAX3010x_Sensor_Library icon indicating copy to clipboard operation
SparkFun_MAX3010x_Sensor_Library copied to clipboard

readPointer == writePointer when samples are lost

Open solarjoe opened this issue 6 years ago • 0 comments
trafficstars

This line

int8_t numberOfSamples = sense.head - sense.tail;

or this one

numberOfSamples = writePointer - readPointer;

do not seem to work if samples are lost. In this case both pointers seem so point to the same location and the number of samples results to 0. But the FIFO is full.

solarjoe avatar Jun 05 '19 14:06 solarjoe