aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIvan Kluchnikov <kluchnikovi@gmail.com>2013-03-28 21:34:53 +0400
committerAlexander Chemeris <Alexander.Chemeris@gmail.com>2013-06-24 01:46:33 +0400
commitc707f42396f85352c479ba08c03047def0c5b9f2 (patch)
tree04a6b61b8a197025cf5de3a06fd5b21cb0de991a
parent00ed1441a1a0edfc8e6ba7450475982464d6e4e0 (diff)
Modified fillerTable usage in pushRadioVector function.
Now we put to fillerTable only frames of BEACON channels, all others frames in fillerTable are dummy bursts.
-rw-r--r--Transceiver52M/Transceiver.cpp25
1 files changed, 21 insertions, 4 deletions
diff --git a/Transceiver52M/Transceiver.cpp b/Transceiver52M/Transceiver.cpp
index d030a48..df7c619 100644
--- a/Transceiver52M/Transceiver.cpp
+++ b/Transceiver52M/Transceiver.cpp
@@ -159,15 +159,25 @@ void Transceiver::pushRadioVector(GSM::Time &nowTime)
{
// dump stale bursts, if any
+ unsigned BCCH_SCH_FCCH_CCCH_Frames[26] = {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,30,31,40,41};
+
while (radioVector* staleBurst = mTransmitPriorityQueue.getStaleBurst(nowTime)) {
// Even if the burst is stale, put it in the fillter table.
// (It might be an idle pattern.)
+ // Now we do it only for BEACON channels.
LOG(NOTICE) << "dumping STALE burst in TRX->USRP interface";
const GSM::Time& nextTime = staleBurst->getTime();
int TN = nextTime.TN();
int modFN = nextTime.FN() % fillerModulus[TN];
- delete fillerTable[modFN][TN];
- fillerTable[modFN][TN] = staleBurst;
+ if (TN==0) {
+ for (unsigned i =0; i < 26; i++) {
+ if(BCCH_SCH_FCCH_CCCH_Frames[i] == modFN) {
+ delete fillerTable[modFN][TN];
+ fillerTable[modFN][TN] = staleBurst;
+ break;
+ }
+ }
+ }
}
int TN = nowTime.TN();
@@ -176,8 +186,15 @@ void Transceiver::pushRadioVector(GSM::Time &nowTime)
// if queue contains data at the desired timestamp, stick it into FIFO
if (radioVector *next = (radioVector*) mTransmitPriorityQueue.getCurrentBurst(nowTime)) {
LOG(DEBUG) << "transmitFIFO: wrote burst " << next << " at time: " << nowTime;
- delete fillerTable[modFN][TN];
- fillerTable[modFN][TN] = new signalVector(*(next));
+ if (TN==0) {
+ for (unsigned i =0; i < 26; i++) {
+ if(BCCH_SCH_FCCH_CCCH_Frames[i] == modFN) {
+ delete fillerTable[modFN][TN];
+ fillerTable[modFN][TN] = new signalVector(*(next));
+ break;
+ }
+ }
+ }
mRadioInterface->driveTransmitRadio(*(next),(mChanType[TN]==NONE)); //fillerTable[modFN][TN]));
delete next;
#ifdef TRANSMIT_LOGGING