This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static autoCorr_t | |
_auto_corr(samples_t const samples, samplesLag_t const lag) | |
{ | |
autoCorr_t ac = 0; | |
for (sample_cnt_t ii = 0; ii < CONFIG_MIDIMIKE_WINDOW_SIZE - lag; ii++) { | |
ac += ((int16_t)samples[ii] * samples[ii + lag]); | |
} | |
return ac; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment