Skip to content
Snippets Groups Projects
Commit 4989c0f0 authored by Florian Kaltenberger's avatar Florian Kaltenberger Committed by Rohit Gupta
Browse files

fix for TDD: TX is powered on a few samples earlier to allow it to settle before start of DL

parent 55f0fc30
No related branches found
No related tags found
12 merge requests!508Develop integration 2019 week 07 v2,!507Develop integration 2019 week 07,!475Nr pdsch,!438NR_PDSCH test for regressions,!409Resolve "compilation fail for 256 UE",!371WIP: Resolve "MAC and RRC trace segv",!352WIP: Resolve "fix T_IDs.h issue for PHY_MEX",!346WIP: Resolve "I/Q replay without mmap() usage",!316Resolve "IQ record/playback bug fixes",!253WIP: Resolve "Fix IQ record/playback explicit filename segv",!252WIP: Resolve "fix IQ record playback explicit file name bug",!231Bugfix tdd usrp
......@@ -948,12 +948,11 @@ void rx_rf(PHY_VARS_eNB *eNB,int *frame,int *subframe) {
lte_subframe_t SF_type = subframe_select(fp,(proc->subframe_rx+tx_sfoffset)%10);
lte_subframe_t prevSF_type = subframe_select(fp,(proc->subframe_rx+tx_sfoffset+9)%10);
lte_subframe_t nextSF_type = subframe_select(fp,(proc->subframe_rx+tx_sfoffset+1)%10);
int sf_extension = 0;
if ((SF_type == SF_DL) ||
(SF_type == SF_S)) {
for (i=0; i<fp->nb_antennas_tx; i++)
txp[i] = (void*)&eNB->common_vars.txdata[0][i][((proc->subframe_rx+tx_sfoffset)%10)*fp->samples_per_tti];
int siglen=fp->samples_per_tti,flags=1;
if (SF_type == SF_S) {
......@@ -962,22 +961,29 @@ void rx_rf(PHY_VARS_eNB *eNB,int *frame,int *subframe) {
}
if ((fp->frame_type == TDD) &&
(SF_type == SF_DL)&&
(prevSF_type == SF_UL) &&
(nextSF_type == SF_DL))
(prevSF_type == SF_UL) &&
(nextSF_type == SF_DL)) {
flags = 2; // start of burst
//sf_extension = eNB->N_TA_offset<<1;
}
if ((fp->frame_type == TDD) &&
(SF_type == SF_DL)&&
(prevSF_type == SF_UL) &&
(nextSF_type == SF_UL))
(nextSF_type == SF_UL)) {
flags = 4; // start of burst and end of burst (only one DL SF between two UL)
//sf_extension = eNB->N_TA_offset<<1;
}
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE, 1 );
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_TRX_WRITE_FLAGS,flags);
for (i=0; i<fp->nb_antennas_tx; i++)
txp[i] = (void*)&eNB->common_vars.txdata[0][i][((proc->subframe_rx+tx_sfoffset)%10)*fp->samples_per_tti-sf_extension];
txs = eNB->rfdevice.trx_write_func(&eNB->rfdevice,
proc->timestamp_rx+eNB->ts_offset+(tx_sfoffset*fp->samples_per_tti)-openair0_cfg[0].tx_sample_advance,
proc->timestamp_rx+eNB->ts_offset+(tx_sfoffset*fp->samples_per_tti)-openair0_cfg[0].tx_sample_advance-sf_extension,
txp,
siglen,
siglen+sf_extension,
fp->nb_antennas_tx,
flags);
clock_gettime( CLOCK_MONOTONIC, &end_rf);
......@@ -991,7 +997,7 @@ void rx_rf(PHY_VARS_eNB *eNB,int *frame,int *subframe) {
if (txs != siglen) {
if (txs != siglen+sf_extension) {
LOG_E(PHY,"TX : Timeout (sent %d/%d)\n",txs, fp->samples_per_tti);
exit_fun( "problem transmitting samples" );
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment