EDGE: Add random burst generator filler option
When EDGE is enabled with the '-e' option, the random burst generator switches from GMSK normal bursts to 8-PSK EDGE bursts. $ ./osmo-trx -e -r 7 Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
This commit is contained in:
parent
8ee2f38a87
commit
af717b2d3c
|
@ -84,9 +84,12 @@ bool TransceiverState::init(int filler, size_t sps, float scale, size_t rtsc)
|
|||
case Transceiver::FILLER_DUMMY:
|
||||
burst = generateDummyBurst(sps, n);
|
||||
break;
|
||||
case Transceiver::FILLER_RAND:
|
||||
case Transceiver::FILLER_NORM_RAND:
|
||||
burst = genRandNormalBurst(rtsc, sps, n);
|
||||
break;
|
||||
case Transceiver::FILLER_EDGE_RAND:
|
||||
burst = generateEdgeBurst(rtsc);
|
||||
break;
|
||||
case Transceiver::FILLER_ZERO:
|
||||
default:
|
||||
burst = generateEmptyBurst(sps, n);
|
||||
|
@ -96,8 +99,10 @@ bool TransceiverState::init(int filler, size_t sps, float scale, size_t rtsc)
|
|||
fillerTable[i][n] = burst;
|
||||
}
|
||||
|
||||
if (filler == Transceiver::FILLER_RAND)
|
||||
chanType[n] = Transceiver::TSC;
|
||||
if ((filler == Transceiver::FILLER_NORM_RAND) ||
|
||||
(filler == Transceiver::FILLER_EDGE_RAND)) {
|
||||
chanType[n] = Transceiver::TSC;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
|
@ -154,7 +154,8 @@ public:
|
|||
enum FillerType {
|
||||
FILLER_DUMMY,
|
||||
FILLER_ZERO,
|
||||
FILLER_RAND,
|
||||
FILLER_NORM_RAND,
|
||||
FILLER_EDGE_RAND,
|
||||
};
|
||||
|
||||
private:
|
||||
|
|
|
@ -181,9 +181,12 @@ bool trx_setup_config(struct trx_config *config)
|
|||
case Transceiver::FILLER_ZERO:
|
||||
fillstr = "Disabled";
|
||||
break;
|
||||
case Transceiver::FILLER_RAND:
|
||||
case Transceiver::FILLER_NORM_RAND:
|
||||
fillstr = "Normal busrts with random payload";
|
||||
break;
|
||||
case Transceiver::FILLER_EDGE_RAND:
|
||||
fillstr = "EDGE busrts with random payload";
|
||||
break;
|
||||
}
|
||||
|
||||
std::ostringstream ost("");
|
||||
|
@ -376,7 +379,7 @@ static void handle_options(int argc, char **argv, struct trx_config *config)
|
|||
break;
|
||||
case 'r':
|
||||
config->rtsc = atoi(optarg);
|
||||
config->filler = Transceiver::FILLER_RAND;
|
||||
config->filler = Transceiver::FILLER_NORM_RAND;
|
||||
break;
|
||||
case 'R':
|
||||
config->rssi_offset = atof(optarg);
|
||||
|
@ -394,6 +397,9 @@ static void handle_options(int argc, char **argv, struct trx_config *config)
|
|||
}
|
||||
}
|
||||
|
||||
if (config->edge && (config->filler == Transceiver::FILLER_NORM_RAND))
|
||||
config->filler = Transceiver::FILLER_EDGE_RAND;
|
||||
|
||||
if ((config->tx_sps != 1) && (config->tx_sps != 4)) {
|
||||
printf("Unsupported samples-per-symbol %i\n\n", config->tx_sps);
|
||||
print_help();
|
||||
|
|
Loading…
Reference in New Issue