From deb0be39c201a04643102ac7902f966679ccb1bc Mon Sep 17 00:00:00 2001 From: David Protzman Date: Sun, 28 Aug 2022 09:21:18 -0400 Subject: [PATCH] Removed normalization requirement There's no reason it must be normalized, and Octave doesn't support normalization with xcorr --- matlab/updated_scripts/find_sto_cp.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/matlab/updated_scripts/find_sto_cp.m b/matlab/updated_scripts/find_sto_cp.m index cda2c1e..57d5805 100644 --- a/matlab/updated_scripts/find_sto_cp.m +++ b/matlab/updated_scripts/find_sto_cp.m @@ -46,7 +46,7 @@ function [start_offset] = find_sto_cp(samples, sample_rate) right = window(end - cp_len + 1:end); % Correlate the two windows - scores(cp_idx) = abs(xcorr(left, right, 0, 'normalized')); + scores(cp_idx) = abs(xcorr(left, right, 0)); % Move the sample pointer forward by the full symbol size offset = offset + cp_len + fft_size;