This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Vadim Yanitskiy gerrit-no-reply at lists.osmocom.orgVadim Yanitskiy has uploaded this change for review. ( https://gerrit.osmocom.org/11390 Change subject: sigProcLib: also detect both TS1 and TS2 RACH synch. sequences ...................................................................... sigProcLib: also detect both TS1 and TS2 RACH synch. sequences According to 3GPP TS 05.02, section 5.2.7, there are three synch. sequences for Access Bursts: - TS0: GSM, GMSK (default), - TS1: EGPRS, 8-PSK, - TS2: EGPRS, GMSK. Until now, we used to detect TS0 only, let's also detect both TS1 and TS2, which are used in extended (11-bit) RACH. Change-Id: I838c21db29c54f1924dd478c2b34b46b70aab2cd Related: OS#3054 --- M GSM/GSMCommon.cpp M GSM/GSMCommon.h M Transceiver52M/radioInterface.cpp M Transceiver52M/sigProcLib.cpp 4 files changed, 38 insertions(+), 21 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-trx refs/changes/90/11390/1 diff --git a/GSM/GSMCommon.cpp b/GSM/GSMCommon.cpp index 8aba3be..711ca70 100644 --- a/GSM/GSMCommon.cpp +++ b/GSM/GSMCommon.cpp @@ -54,7 +54,10 @@ const BitVector GSM::gDummyBurst("0001111101101110110000010100100111000001001000100000001111100011100010111000101110001010111010010100011001100111001111010011111000100101111101010000"); -const BitVector GSM::gRACHSynchSequence("01001011011111111001100110101010001111000"); +/* 3GPP TS 05.02, section 5.2.7 "Access burst (AB)", synch. sequence bits */ +const BitVector GSM::gRACHSynchSequenceTS0("01001011011111111001100110101010001111000"); /* GSM, GMSK (default) */ +const BitVector GSM::gRACHSynchSequenceTS1("01010100111110001000011000101111001001101"); /* EGPRS, 8-PSK */ +const BitVector GSM::gRACHSynchSequenceTS2("11101111001001110101011000001101101110111"); /* EGPRS, GMSK */ // |-head-||---------midamble----------------------||--------------data----------------||t| const BitVector GSM::gRACHBurst("0011101001001011011111111001100110101010001111000110111101111110000111001001010110011000"); diff --git a/GSM/GSMCommon.h b/GSM/GSMCommon.h index 8b8d5e8..f703c30 100644 --- a/GSM/GSMCommon.h +++ b/GSM/GSMCommon.h @@ -52,7 +52,9 @@ extern const BitVector gDummyBurst; /** Random access burst synch. sequence */ -extern const BitVector gRACHSynchSequence; +extern const BitVector gRACHSynchSequenceTS0; +extern const BitVector gRACHSynchSequenceTS1; +extern const BitVector gRACHSynchSequenceTS2; /** Random access burst synch. sequence, GSM 05.02 5.2.7 */ extern const BitVector gRACHBurst; diff --git a/Transceiver52M/radioInterface.cpp b/Transceiver52M/radioInterface.cpp index 0f949d7..6245cfc 100644 --- a/Transceiver52M/radioInterface.cpp +++ b/Transceiver52M/radioInterface.cpp @@ -245,7 +245,7 @@ * Pre-allocate head room for the largest correlation size * so we can later avoid a re-allocation and copy * */ - size_t head = GSM::gRACHSynchSequence.size(); + size_t head = GSM::gRACHSynchSequenceTS0.size(); /* * Form receive bursts and pass up to transceiver. Use repeating diff --git a/Transceiver52M/sigProcLib.cpp b/Transceiver52M/sigProcLib.cpp index 692fbe0..e13282f 100644 --- a/Transceiver52M/sigProcLib.cpp +++ b/Transceiver52M/sigProcLib.cpp @@ -132,7 +132,7 @@ static CorrelationSequence *gMidambles[] = {NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}; static CorrelationSequence *gEdgeMidambles[] = {NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL}; -static CorrelationSequence *gRACHSequence = NULL; +static CorrelationSequence *gRACHSequences[] = {NULL,NULL,NULL}; static PulseSequence *GSMPulse1 = NULL; static PulseSequence *GSMPulse4 = NULL; @@ -150,11 +150,15 @@ delayFilters[i] = NULL; } + for (int i = 0; i < 3; i++) { + delete gRACHSequences[i]; + gRACHSequences[i] = NULL; + } + delete GMSKRotation1; delete GMSKReverseRotation1; delete GMSKRotation4; delete GMSKReverseRotation4; - delete gRACHSequence; delete GSMPulse1; delete GSMPulse4; delete dnsampler; @@ -163,7 +167,6 @@ GMSKRotation4 = NULL; GMSKReverseRotation4 = NULL; GMSKReverseRotation1 = NULL; - gRACHSequence = NULL; GSMPulse1 = NULL; GSMPulse4 = NULL; } @@ -1332,7 +1335,7 @@ return seq; } -static bool generateRACHSequence(int sps) +static bool generateRACHSequence(CorrelationSequence **seq, const BitVector &bv, int sps) { bool status = true; float toa; @@ -1340,13 +1343,14 @@ signalVector *autocorr = NULL; signalVector *seq0 = NULL, *seq1 = NULL, *_seq1 = NULL; - delete gRACHSequence; + if (*seq != NULL) + delete *seq; - seq0 = modulateBurst(gRACHSynchSequence, 0, sps, false); + seq0 = modulateBurst(bv, 0, sps, false); if (!seq0) return false; - seq1 = modulateBurst(gRACHSynchSequence.segment(0, 40), 0, sps, true); + seq1 = modulateBurst(bv.segment(0, 40), 0, sps, true); if (!seq1) { status = false; goto release; @@ -1366,19 +1370,19 @@ goto release; } - gRACHSequence = new CorrelationSequence; - gRACHSequence->sequence = _seq1; - gRACHSequence->buffer = data; - gRACHSequence->gain = peakDetect(*autocorr, &toa, NULL); + *seq = new CorrelationSequence; + (*seq)->sequence = _seq1; + (*seq)->buffer = data; + (*seq)->gain = peakDetect(*autocorr, &toa, NULL); /* For 1 sps only * (Half of correlation length - 1) + midpoint of pulse shaping filer * 20.5 = (40 / 2 - 1) + 1.5 */ if (sps == 1) - gRACHSequence->toa = toa - 20.5; + (*seq)->toa = toa - 20.5; else - gRACHSequence->toa = 0.0; + (*seq)->toa = 0.0; release: delete autocorr; @@ -1388,7 +1392,7 @@ if (!status) { delete _seq1; free(data); - gRACHSequence = NULL; + *seq = NULL; } return status; @@ -1606,10 +1610,15 @@ target = 8 + 40; head = 8; tail = 8 + max_toa; - sync = gRACHSequence; - rc = detectGeneralBurst(burst, threshold, sps, amplitude, toa, - target, head, tail, sync); + for (int i = 0; i < 3; i++) { + sync = gRACHSequences[i]; + + rc = detectGeneralBurst(burst, threshold, sps, amplitude, toa, + target, head, tail, sync); + if (rc > 0) + break; + } return rc; } @@ -1858,7 +1867,10 @@ GSMPulse1 = generateGSMPulse(1); GSMPulse4 = generateGSMPulse(4); - generateRACHSequence(1); + generateRACHSequence(&gRACHSequences[0], gRACHSynchSequenceTS0, 1); + generateRACHSequence(&gRACHSequences[1], gRACHSynchSequenceTS1, 1); + generateRACHSequence(&gRACHSequences[2], gRACHSynchSequenceTS2, 1); + for (int tsc = 0; tsc < 8; tsc++) { generateMidamble(1, tsc); gEdgeMidambles[tsc] = generateEdgeMidamble(tsc); -- To view, visit https://gerrit.osmocom.org/11390 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-MessageType: newchange Gerrit-Change-Id: I838c21db29c54f1924dd478c2b34b46b70aab2cd Gerrit-Change-Number: 11390 Gerrit-PatchSet: 1 Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com> Gerrit-Reviewer: Max <msuraev at sysmocom.de> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20181017/a1a7993f/attachment.htm>