I'm testing ADXL357 evaluation board with a 159Hz 1G shaker. The amplitude looks right, but the 1x frequency after FFT is always between 156-157Hz instead of 159Hz. I have tried both reading FIFO and XYZ data register with DRDY pin interrupt. The results were similar. I measured the execution time of my data collection function, it was constant and always slightly shorter than calculated. If I calculate frequency based on execution time instead of directly taking the set value of ADXL357, the 1x frequency will be corrected to 159Hz.
For example, I have attached a set of 4096 data points taken when ADXL357 ODR was set to 2000Hz. Calculated 1x frequency is 156.74Hz. Execution time measured is 2.016s.
What could be the issue? How do I fix it? Thanks