Merge branch 'develop' into feature-59-tm4
This commit is contained in:
@@ -308,10 +308,10 @@ void* multicast_link_main_loop (void *param)
|
||||
}
|
||||
|
||||
void multicast_link_start(void (*rx_handlerP) (unsigned int, char *),
|
||||
unsigned char multicast_group, char *multicast_ifname)
|
||||
unsigned char _multicast_group, char *multicast_ifname)
|
||||
{
|
||||
rx_handler = rx_handlerP;
|
||||
multicast_group = multicast_group;
|
||||
multicast_group = _multicast_group;
|
||||
multicast_if = multicast_ifname;
|
||||
LOG_I(EMU, "[MULTICAST] LINK START on interface=%s for group=%d: handler=%p\n",
|
||||
(multicast_if == NULL) ? "not specified" : multicast_if, multicast_group,
|
||||
|
||||
@@ -1301,7 +1301,7 @@ int main(int argc, char **argv)
|
||||
unsigned int ret;
|
||||
unsigned int coded_bits_per_codeword=0,nsymb; //,tbs=0;
|
||||
|
||||
unsigned int tx_lev=0,tx_lev_dB=0,trials,errs[4]= {0,0,0,0},errs2[4]= {0,0,0,0},round_trials[4]= {0,0,0,0},dci_errors=0;//,num_layers;
|
||||
unsigned int tx_lev=0,tx_lev_dB=0,trials,errs[4]= {0,0,0,0},errs2[4]= {0,0,0,0},round_trials[4]= {0,0,0,0},dci_errors[4]={0,0,0,0};//,num_layers;
|
||||
//int re_allocated;
|
||||
char fname[32],vname[32];
|
||||
FILE *bler_fd;
|
||||
@@ -1341,7 +1341,7 @@ int main(int argc, char **argv)
|
||||
//int iii;
|
||||
|
||||
int ch_realization;
|
||||
int pmi_feedback=0;
|
||||
//int pmi_feedback=0;
|
||||
int hold_channel=0;
|
||||
|
||||
// void *data;
|
||||
@@ -1379,6 +1379,7 @@ int main(int argc, char **argv)
|
||||
uint8_t Kmimo;
|
||||
uint8_t ue_category=4;
|
||||
uint32_t Nsoft;
|
||||
int sf;
|
||||
|
||||
|
||||
|
||||
@@ -1390,7 +1391,7 @@ int main(int argc, char **argv)
|
||||
|
||||
FILE *csv_fd=NULL;
|
||||
char csv_fname[32];
|
||||
int dci_flag=1;
|
||||
//int dci_flag=1;
|
||||
int two_thread_flag=0;
|
||||
int DLSCH_RB_ALLOC = 0;
|
||||
|
||||
@@ -1452,9 +1453,9 @@ int main(int argc, char **argv)
|
||||
Nid_cell = atoi(optarg);
|
||||
break;
|
||||
|
||||
case 'd':
|
||||
dci_flag = 1;
|
||||
break;
|
||||
//case 'd':
|
||||
// dci_flag = 1;
|
||||
// break;
|
||||
|
||||
case 'D':
|
||||
frame_type=TDD;
|
||||
@@ -1481,7 +1482,7 @@ int main(int argc, char **argv)
|
||||
case 'i':
|
||||
input_fd = fopen(optarg,"r");
|
||||
input_file=1;
|
||||
dci_flag = 1;
|
||||
//dci_flag = 1;
|
||||
break;
|
||||
|
||||
case 'I':
|
||||
@@ -1998,7 +1999,7 @@ int main(int argc, char **argv)
|
||||
}
|
||||
*/
|
||||
|
||||
UE->pdcch_vars[0][0]->crnti = n_rnti;
|
||||
UE->pdcch_vars[subframe & 0x1][0]->crnti = n_rnti;
|
||||
|
||||
// Fill in UL_alloc
|
||||
UL_alloc_pdu.type = 0;
|
||||
@@ -2104,15 +2105,22 @@ int main(int argc, char **argv)
|
||||
}
|
||||
}
|
||||
|
||||
for (i=0; i<2; i++) {
|
||||
UE->dlsch[subframe&0x1][0][i] = new_ue_dlsch(Kmimo,8,Nsoft,MAX_TURBO_ITERATIONS,N_RB_DL,0);
|
||||
/* allocate memory for both subframes (only one is really used
|
||||
* but there is now "copy_harq_proc_struct" which needs both
|
||||
* to be valid)
|
||||
* TODO: refine this somehow (necessary?)
|
||||
*/
|
||||
for (sf = 0; sf < 2; sf++) {
|
||||
for (i=0; i<2; i++) {
|
||||
UE->dlsch[sf][0][i] = new_ue_dlsch(Kmimo,8,Nsoft,MAX_TURBO_ITERATIONS,N_RB_DL,0);
|
||||
|
||||
if (!UE->dlsch[subframe&0x1][0][i]) {
|
||||
printf("Can't get ue dlsch structures\n");
|
||||
exit(-1);
|
||||
if (!UE->dlsch[sf][0][i]) {
|
||||
printf("Can't get ue dlsch structures\n");
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
UE->dlsch[sf][0][i]->rnti = n_rnti;
|
||||
}
|
||||
|
||||
UE->dlsch[subframe&0x1][0][i]->rnti = n_rnti;
|
||||
}
|
||||
|
||||
UE->dlsch_SI[0] = new_ue_dlsch(1,1,Nsoft,MAX_TURBO_ITERATIONS,N_RB_DL,0);
|
||||
@@ -2246,7 +2254,10 @@ int main(int argc, char **argv)
|
||||
round_trials[2] = 0;
|
||||
round_trials[3] = 0;
|
||||
|
||||
dci_errors=0;
|
||||
dci_errors[0]=0;
|
||||
dci_errors[1]=0;
|
||||
dci_errors[2]=0;
|
||||
dci_errors[3]=0;
|
||||
// avg_ber = 0;
|
||||
|
||||
round=0;
|
||||
@@ -2314,10 +2325,10 @@ int main(int argc, char **argv)
|
||||
// printf("Trial %d, round %d\n",trials,round);
|
||||
round_trials[round]++;
|
||||
|
||||
if(transmission_mode>=5)
|
||||
pmi_feedback=1;
|
||||
else
|
||||
pmi_feedback=0;
|
||||
//if(transmission_mode>=5)
|
||||
// pmi_feedback=1;
|
||||
//else
|
||||
// pmi_feedback=0;
|
||||
|
||||
if (abstx) {
|
||||
if (trials==0 && round==0 && SNR==snr0) //generate a new channel
|
||||
@@ -2499,6 +2510,9 @@ int main(int argc, char **argv)
|
||||
|
||||
if (UE->dlsch[subframe&0x1][0][0]->active == 0) {
|
||||
//printf("DCI not received\n");
|
||||
dci_errors[round]++;
|
||||
UE->dlsch_errors[0] = 1;
|
||||
|
||||
/*
|
||||
write_output("pdcchF0_ext.m","pdcchF_ext", UE->pdcch_vars[eNB_id]->rxdataF_ext[0],2*3*UE->frame_parms.ofdm_symbol_size,1,1);
|
||||
write_output("pdcch00_ch0_ext.m","pdcch00_ch0_ext",UE->pdcch_vars[eNB_id]->dl_ch_estimates_ext[0],12*UE->frame_parms.N_RB_DL*3,1,1);
|
||||
@@ -2837,13 +2851,13 @@ int main(int argc, char **argv)
|
||||
double std_phy_proc_rx_demod=0;
|
||||
double std_phy_proc_rx_dec=0;
|
||||
|
||||
effective_rate = ((double)(round_trials[0]-dci_errors)/((double)round_trials[0] + round_trials[1] + round_trials[2] + round_trials[3]));
|
||||
effective_rate = 1.0-((double)(errs[0]+errs[1]+errs[2]+errs[3])/((double)round_trials[0] + round_trials[1] + round_trials[2] + round_trials[3]));
|
||||
|
||||
printf("\n**********************SNR = %f dB (tx_lev %f)**************************\n",
|
||||
SNR,
|
||||
(double)tx_lev_dB+10*log10(UE->frame_parms.ofdm_symbol_size/(NB_RB*12)));
|
||||
|
||||
printf("Errors (%d(%d)/%d %d/%d %d/%d %d/%d), Pe = (%e,%e,%e,%e), dci_errors %d/%d, Pe = %e => effective rate %f (%2.1f%%,%f, %f), normalized delay %f (%f)\n",
|
||||
printf("Errors (%d(%d)/%d %d/%d %d/%d %d/%d), Pe = (%e,%e,%e,%e), dci_errors %d/%d, Pe = %e => effective rate %f, normalized delay %f (%f)\n",
|
||||
errs[0],
|
||||
errs2[0],
|
||||
round_trials[0],
|
||||
@@ -2857,13 +2871,13 @@ int main(int argc, char **argv)
|
||||
(double)errs[1]/(round_trials[0]),
|
||||
(double)errs[2]/(round_trials[0]),
|
||||
(double)errs[3]/(round_trials[0]),
|
||||
dci_errors,
|
||||
round_trials[0],
|
||||
(double)dci_errors/(round_trials[0]),
|
||||
rate*effective_rate,
|
||||
dci_errors[0]+dci_errors[1]+dci_errors[2]+dci_errors[3],
|
||||
round_trials[0]+round_trials[1]+round_trials[2]+round_trials[3],
|
||||
(double)(dci_errors[0]+dci_errors[1]+dci_errors[2]+dci_errors[3])/(round_trials[0]+round_trials[1]+round_trials[2]+round_trials[3]),
|
||||
//rate*effective_rate,
|
||||
100*effective_rate,
|
||||
rate,
|
||||
rate*get_Qm(UE->dlsch[subframe&0x1][0][0]->harq_processes[UE->dlsch[subframe&0x1][0][0]->current_harq_pid]->mcs),
|
||||
//rate,
|
||||
//rate*get_Qm(UE->dlsch[subframe&0x1][0][0]->harq_processes[UE->dlsch[subframe&0x1][0][0]->current_harq_pid]->mcs),
|
||||
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0])/
|
||||
(double)eNB->dlsch[0][0]->harq_processes[0]->TBS,
|
||||
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0]));
|
||||
@@ -2986,7 +3000,7 @@ int main(int argc, char **argv)
|
||||
round_trials[2],
|
||||
errs[3],
|
||||
round_trials[3],
|
||||
dci_errors);
|
||||
dci_errors[0]);
|
||||
} else {
|
||||
fprintf(bler_fd,"%f;%d;%d;%d;%d;%f;%d;%d;%d;%d;%d;%d;%d;%d;%d\n",
|
||||
SNR,
|
||||
@@ -3002,7 +3016,7 @@ int main(int argc, char **argv)
|
||||
round_trials[2],
|
||||
errs[3],
|
||||
round_trials[3],
|
||||
dci_errors);
|
||||
dci_errors[0]);
|
||||
}
|
||||
|
||||
|
||||
@@ -3035,7 +3049,7 @@ int main(int argc, char **argv)
|
||||
round_trials[2],
|
||||
errs[3],
|
||||
round_trials[3],
|
||||
dci_errors);
|
||||
dci_errors[0]);
|
||||
|
||||
//fprintf(time_meas_fd,"SNR; MCS; TBS; rate; DL_DECOD_ITER; err0; trials0; err1; trials1; err2; trials2; err3; trials3; PE; dci_err;PE;ND;\n");
|
||||
fprintf(time_meas_fd,"%f;%d;%d;%f; %2.1f%%;%f;%f;%d;%d;%d;%d;%d;%d;%d;%d;%e;%e;%e;%e;%d;%d;%e;%f;%f;",
|
||||
@@ -3058,9 +3072,9 @@ int main(int argc, char **argv)
|
||||
(double)errs[1]/(round_trials[0]),
|
||||
(double)errs[2]/(round_trials[0]),
|
||||
(double)errs[3]/(round_trials[0]),
|
||||
dci_errors,
|
||||
dci_errors[0],
|
||||
round_trials[0],
|
||||
(double)dci_errors/(round_trials[0]),
|
||||
(double)dci_errors[0]/(round_trials[0]),
|
||||
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0])/
|
||||
(double)eNB->dlsch[0][0]->harq_processes[0]->TBS,
|
||||
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0]));
|
||||
@@ -3079,7 +3093,7 @@ int main(int argc, char **argv)
|
||||
round_trials[2],
|
||||
errs[3],
|
||||
round_trials[3],
|
||||
dci_errors);
|
||||
dci_errors[0]);
|
||||
|
||||
//fprintf(time_meas_fd,"SNR; MCS; TBS; rate; DL_DECOD_ITER; err0; trials0; err1; trials1; err2; trials2; err3; trials3; PE; dci_err;PE;ND;\n");
|
||||
fprintf(time_meas_fd,"%f;%d;%d;%d;%d;%f;%2.1f;%f;%f;%d;%d;%d;%d;%d;%d;%d;%d;%e;%e;%e;%e;%d;%d;%e;%f;%f;",
|
||||
@@ -3103,9 +3117,9 @@ int main(int argc, char **argv)
|
||||
(double)errs[1]/(round_trials[0]),
|
||||
(double)errs[2]/(round_trials[0]),
|
||||
(double)errs[3]/(round_trials[0]),
|
||||
dci_errors,
|
||||
dci_errors[0],
|
||||
round_trials[0],
|
||||
(double)dci_errors/(round_trials[0]),
|
||||
(double)dci_errors[0]/(round_trials[0]),
|
||||
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0])/
|
||||
(double)eNB->dlsch[0][0]->harq_processes[0]->TBS,
|
||||
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0]));
|
||||
|
||||
@@ -653,6 +653,7 @@ int main(int argc, char **argv)
|
||||
printf("-h This message\n");
|
||||
printf("-a Use AWGN channel and not multipath\n");
|
||||
printf("-c TDD config\n");
|
||||
printf("-S Subframe number (0..9)\n");
|
||||
printf("-R N_RB_DL\n");
|
||||
printf("-F use FDD frame\n");
|
||||
printf("-p Use extended prefix mode\n");
|
||||
|
||||
@@ -85,11 +85,13 @@ int main(int argc, char **argv)
|
||||
|
||||
// double pucch_sinr;
|
||||
uint8_t osf=1,N_RB_DL=25;
|
||||
uint32_t pucch_tx=0,pucch1_missed=0,pucch1_false=0,sig;
|
||||
uint32_t pucch_tx=0,pucch1_missed=0,pucch1_false=0,pucch3_false=0,sig;
|
||||
PUCCH_FMT_t pucch_format = pucch_format1;
|
||||
PUCCH_CONFIG_DEDICATED pucch_config_dedicated;
|
||||
uint8_t subframe=0;
|
||||
uint8_t pucch_payload,pucch_payload_rx;
|
||||
uint8_t pucch3_payload_size=7;
|
||||
uint8_t pucch3_payload[21],pucch3_payload_rx[21];
|
||||
double tx_gain=1.0;
|
||||
int32_t stat;
|
||||
double stat_no_sig,stat_sig;
|
||||
@@ -98,6 +100,9 @@ int main(int argc, char **argv)
|
||||
|
||||
uint16_t n1_pucch = 0;
|
||||
uint16_t n2_pucch = 0;
|
||||
uint16_t n3_pucch = 20;
|
||||
|
||||
uint16_t n_rnti=0x1234;
|
||||
|
||||
number_of_cards = 1;
|
||||
|
||||
@@ -118,6 +123,8 @@ int main(int argc, char **argv)
|
||||
pucch_format = pucch_format1a;
|
||||
else if (atoi(optarg)==2)
|
||||
pucch_format = pucch_format1b;
|
||||
else if (atoi(optarg)==6) // 3,4,5 is reserved for format2,2a,2b
|
||||
pucch_format = pucch_format3;
|
||||
else {
|
||||
printf("Unsupported pucch_format %d\n",atoi(optarg));
|
||||
exit(-1);
|
||||
@@ -282,7 +289,7 @@ int main(int argc, char **argv)
|
||||
printf("-N Noise variance in dB\n");
|
||||
printf("-R N_RB_DL\n");
|
||||
printf("-O oversampling factor (1,2,4,8,16)\n");
|
||||
printf("-f PUCCH format (0=1,1=1a,2=1b), formats 2/2a/2b not supported\n");
|
||||
printf("-f PUCCH format (0=1,1=1a,2=1b,6=3), formats 2/2a/2b not supported\n");
|
||||
printf("-F Input filename (.txt format) for RX conformance testing\n");
|
||||
exit (-1);
|
||||
break;
|
||||
@@ -362,18 +369,34 @@ int main(int argc, char **argv)
|
||||
UE->frame_parms.pucch_config_common.nRB_CQI = 4;
|
||||
UE->frame_parms.pucch_config_common.nCS_AN = 6;
|
||||
|
||||
pucch_payload = 0;
|
||||
|
||||
generate_pucch1x(UE->common_vars.txdataF,
|
||||
frame_parms,
|
||||
UE->ncs_cell,
|
||||
pucch_format,
|
||||
&pucch_config_dedicated,
|
||||
n1_pucch,
|
||||
0, //shortened_format,
|
||||
&pucch_payload,
|
||||
AMP, //amp,
|
||||
subframe); //subframe
|
||||
if( (pucch_format == pucch_format1) || (pucch_format == pucch_format1a) || (pucch_format == pucch_format1b) ){
|
||||
pucch_payload = 0;
|
||||
generate_pucch1x(UE->common_vars.txdataF,
|
||||
frame_parms,
|
||||
UE->ncs_cell,
|
||||
pucch_format,
|
||||
&pucch_config_dedicated,
|
||||
n1_pucch,
|
||||
0, //shortened_format,
|
||||
&pucch_payload,
|
||||
AMP, //amp,
|
||||
subframe); //subframe
|
||||
}else if( pucch_format == pucch_format3){
|
||||
for(i=0;i<pucch3_payload_size;i++)
|
||||
pucch3_payload[i]=(uint8_t)(taus()&0x1);
|
||||
generate_pucch3x(UE->common_vars.txdataF,
|
||||
frame_parms,
|
||||
UE->ncs_cell,
|
||||
pucch_format,
|
||||
&pucch_config_dedicated,
|
||||
n3_pucch,
|
||||
0, //shortened_format,
|
||||
pucch3_payload,
|
||||
AMP, //amp,
|
||||
subframe, //subframe
|
||||
n_rnti); //rnti
|
||||
}
|
||||
write_output("txsigF0.m","txsF0", &UE->common_vars.txdataF[0][2*subframe*nsymb*OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES_NO_PREFIX],OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES_NO_PREFIX*nsymb,1,1);
|
||||
|
||||
tx_lev = 0;
|
||||
@@ -429,6 +452,7 @@ int main(int argc, char **argv)
|
||||
pucch_tx = 0;
|
||||
pucch1_missed=0;
|
||||
pucch1_false=0;
|
||||
pucch3_false=0;
|
||||
|
||||
stat_no_sig = 0;
|
||||
stat_sig = 0;
|
||||
@@ -540,7 +564,7 @@ int main(int argc, char **argv)
|
||||
n1_pucch,
|
||||
n2_pucch,
|
||||
0, //shortened_format,
|
||||
&pucch_payload_rx, //payload,
|
||||
(pucch_format==pucch_format3) ? pucch3_payload_rx : &pucch_payload_rx, //payload,
|
||||
0 /* frame not defined, let's pass 0 */,
|
||||
subframe,
|
||||
pucch1_thres);
|
||||
@@ -561,8 +585,15 @@ int main(int argc, char **argv)
|
||||
printf("EXIT\n");
|
||||
exit(-1);
|
||||
}*/
|
||||
} else {
|
||||
} else if( (pucch_format==pucch_format1a) || (pucch_format==pucch_format1b) ) {
|
||||
pucch1_false = (pucch_payload_rx != pucch_payload) ? (pucch1_false+1) : pucch1_false;
|
||||
} else if (pucch_format==pucch_format3){
|
||||
for(i=0;i<pucch3_payload_size;i++){
|
||||
if(pucch3_payload[i]!=pucch3_payload_rx[i]){
|
||||
pucch3_false = (pucch3_false+1);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// printf("sig %d\n",sig);
|
||||
@@ -576,7 +607,8 @@ int main(int argc, char **argv)
|
||||
printf("pucch_trials %d : pucch1a_errors %d\n",pucch_tx,pucch1_false);
|
||||
else if (pucch_format==pucch_format1b)
|
||||
printf("pucch_trials %d : pucch1b_errors %d\n",pucch_tx,pucch1_false);
|
||||
|
||||
else if (pucch_format==pucch_format3)
|
||||
printf("pucch_trials %d : pucch3_errors %d\n",pucch_tx,pucch3_false);
|
||||
}
|
||||
|
||||
if (n_frames==1) {
|
||||
|
||||
@@ -253,7 +253,7 @@ int main(int argc, char **argv)
|
||||
|
||||
uint8_t N_RB_DL=25,osf=1;
|
||||
|
||||
uint8_t cyclic_shift = 0;
|
||||
//uint8_t cyclic_shift = 0;
|
||||
uint8_t cooperation_flag = 0; //0 no cooperation, 1 delay diversity, 2 Alamouti
|
||||
uint8_t beta_ACK=0,beta_RI=0,beta_CQI=2;
|
||||
uint8_t tdd_config=3,frame_type=FDD;
|
||||
@@ -275,6 +275,7 @@ int main(int argc, char **argv)
|
||||
uint8_t max_turbo_iterations=4;
|
||||
uint8_t parallel_flag=0;
|
||||
int nb_rb_set = 0;
|
||||
int sf;
|
||||
|
||||
int threequarter_fs=0;
|
||||
int ndi;
|
||||
@@ -462,9 +463,9 @@ int main(int argc, char **argv)
|
||||
first_rb = atoi(optarg);
|
||||
break;
|
||||
|
||||
case 'c':
|
||||
cyclic_shift = atoi(optarg);
|
||||
break;
|
||||
//case 'c':
|
||||
// cyclic_shift = atoi(optarg);
|
||||
// break;
|
||||
|
||||
case 'E':
|
||||
threequarter_fs=1;
|
||||
@@ -556,7 +557,9 @@ int main(int argc, char **argv)
|
||||
|
||||
case 'h':
|
||||
default:
|
||||
printf("%s -h(elp) -a(wgn on) -m mcs -n n_frames -s snr0 -t delay_spread -p (extended prefix on) -r nb_rb -f first_rb -c cyclic_shift -o (srs on) -g channel_model [A:M] Use 3GPP 25.814 SCM-A/B/C/D('A','B','C','D') or 36-101 EPA('E'), EVA ('F'),ETU('G') models (ignores delay spread and Ricean factor), Rayghleigh8 ('H'), Rayleigh1('I'), Rayleigh1_corr('J'), Rayleigh1_anticorr ('K'), Rice8('L'), Rice1('M'), -d Channel delay, -D maximum Doppler shift \n",
|
||||
/* option "-c cyclic_shift" is not used, let's remove from documentation */
|
||||
//printf("%s -h(elp) -a(wgn on) -m mcs -n n_frames -s snr0 -t delay_spread -p (extended prefix on) -r nb_rb -f first_rb -c cyclic_shift -o (srs on) -g channel_model [A:M] Use 3GPP 25.814 SCM-A/B/C/D('A','B','C','D') or 36-101 EPA('E'), EVA ('F'),ETU('G') models (ignores delay spread and Ricean factor), Rayghleigh8 ('H'), Rayleigh1('I'), Rayleigh1_corr('J'), Rayleigh1_anticorr ('K'), Rice8('L'), Rice1('M'), -d Channel delay, -D maximum Doppler shift \n",
|
||||
printf("%s -h(elp) -a(wgn on) -m mcs -n n_frames -s snr0 -t delay_spread -p (extended prefix on) -r nb_rb -f first_rb -o (srs on) -g channel_model [A:M] Use 3GPP 25.814 SCM-A/B/C/D('A','B','C','D') or 36-101 EPA('E'), EVA ('F'),ETU('G') models (ignores delay spread and Ricean factor), Rayghleigh8 ('H'), Rayleigh1('I'), Rayleigh1_corr('J'), Rayleigh1_anticorr ('K'), Rice8('L'), Rice1('M'), -d Channel delay, -D maximum Doppler shift \n",
|
||||
argv[0]);
|
||||
exit(1);
|
||||
break;
|
||||
@@ -709,22 +712,27 @@ int main(int argc, char **argv)
|
||||
// Create transport channel structures for 2 transport blocks (MIMO)
|
||||
for (i=0; i<2; i++) {
|
||||
eNB->dlsch[0][i] = new_eNB_dlsch(1,8,1827072,N_RB_DL,0,&eNB->frame_parms);
|
||||
UE->dlsch[subframe&1][0][i] = new_ue_dlsch(1,8,1827072,MAX_TURBO_ITERATIONS,N_RB_DL,0);
|
||||
|
||||
if (!eNB->dlsch[0][i]) {
|
||||
printf("Can't get eNB dlsch structures\n");
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
if (!UE->dlsch[subframe&1][0][i]) {
|
||||
printf("Can't get ue dlsch structures\n");
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
eNB->dlsch[0][i]->rnti = 14;
|
||||
UE->dlsch[subframe&1][0][i]->rnti = 14;
|
||||
|
||||
}
|
||||
}
|
||||
/* allocate memory for both subframes (only one is really used
|
||||
* but there is now "copy_harq_proc_struct" which needs both
|
||||
* to be valid)
|
||||
* TODO: refine this somehow (necessary?)
|
||||
*/
|
||||
for (sf = 0; sf < 2; sf++) {
|
||||
for (i=0; i<2; i++) {
|
||||
UE->dlsch[sf][0][i] = new_ue_dlsch(1,8,1827072,MAX_TURBO_ITERATIONS,N_RB_DL,0);
|
||||
if (!UE->dlsch[sf][0][i]) {
|
||||
printf("Can't get ue dlsch structures\n");
|
||||
exit(-1);
|
||||
}
|
||||
UE->dlsch[sf][0][i]->rnti = 14;
|
||||
}
|
||||
}
|
||||
|
||||
UE->dlsch_SI[0] = new_ue_dlsch(1,1,1827072,MAX_TURBO_ITERATIONS,N_RB_DL,0);
|
||||
UE->dlsch_ra[0] = new_ue_dlsch(1,1,1827072,MAX_TURBO_ITERATIONS,N_RB_DL,0);
|
||||
|
||||
@@ -101,7 +101,7 @@ void fill_channel_desc(channel_desc_t *chan_desc,
|
||||
|
||||
LOG_D(OCM,"[CHANNEL] Filling a (nb_taps %d)\n",nb_taps);
|
||||
for (i = 0; i<nb_taps; i++) {
|
||||
LOG_D(OCM,"tap %d (%p,%d)\n",i,&chan_desc->a[i],nb_tx*nb_rx * sizeof(struct complex));
|
||||
LOG_D(OCM,"tap %d (%p,%zu)\n",i,&chan_desc->a[i],nb_tx*nb_rx * sizeof(struct complex));
|
||||
chan_desc->a[i] = (struct complex*) malloc(nb_tx*nb_rx * sizeof(struct complex));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user