aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorttsou <ttsou@19bc5d8c-e614-43d4-8b26-e1612bc8e597>2013-04-04 23:35:08 +0000
committerttsou <ttsou@19bc5d8c-e614-43d4-8b26-e1612bc8e597>2013-04-04 23:35:08 +0000
commitbec41039bf2ec07c04a6e8b0b586b085ab9cd74c (patch)
treede8c787c525cf3e1d52af6d2bd09cde50fda3a2f
parent2064297aa8ef59dd369b8e76158315ac764ceaa1 (diff)
Transceiver52M: Fix calculation of TS correlation for 2 sps and higher
The correlation starting point for normal burst training sequence calculation should be a scaled value of the same symbol regardless of the samples-per-symbol used. Use of 2 samples-per-symbols double the index values, but yields the following outputs, which results in a late time-of-arrival value at the output of the correlation. This patch modifies the parameter calculation accordingly. 1 sps parameters maxTOA = 3 spanTOA = 5; startIx = 61; endIx = 87; windowLen = 26; corrLen = 7; 2 sps parameters (errant case) maxTOA = 6; spanTOA = 10; startIx = 112; endIx = 184; windowLen = 72; corrLen =13; 2 sps parameters (corrected) maxTOA = 6; spanTOA = 10; startIx = 122; endIx = 174; windowLen = 52; corrLen =13; Signed-off-by: Thomas Tsou <tom@tsou.cc> git-svn-id: http://wush.net/svn/range/software/public/openbts/trunk@5183 19bc5d8c-e614-43d4-8b26-e1612bc8e597
-rw-r--r--Transceiver52M/sigProcLib.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Transceiver52M/sigProcLib.cpp b/Transceiver52M/sigProcLib.cpp
index ae52894..5dc2def 100644
--- a/Transceiver52M/sigProcLib.cpp
+++ b/Transceiver52M/sigProcLib.cpp
@@ -1018,8 +1018,8 @@ bool analyzeTrafficBurst(signalVector &rxBurst,
unsigned spanTOA = maxTOA;
if (spanTOA < 5*samplesPerSymbol) spanTOA = 5*samplesPerSymbol;
- unsigned startIx = (66-spanTOA)*samplesPerSymbol;
- unsigned endIx = (66+16+spanTOA)*samplesPerSymbol;
+ unsigned startIx = 66*samplesPerSymbol-spanTOA;
+ unsigned endIx = (66+16)*samplesPerSymbol+spanTOA;
unsigned windowLen = endIx - startIx;
unsigned corrLen = 2*maxTOA+1;