Commit f1dbbd08 authored by magounak's avatar magounak

Merge branch 'ru_rau_enhancement-external-timing' of...

Merge branch 'ru_rau_enhancement-external-timing' of https://gitlab.eurecom.fr/oai/openairinterface5g into ru_rau_enhancement-external-timing
parents c8c6b9e9 f97c7b95
......@@ -682,7 +682,7 @@ int ru_sync_time(RU_t *ru,
}
avg0/=(length/4);
int dmrsoffset = 2*(frame_parms->ofdm_symbol_size+frame_parms->nb_prefix_samples) + frame_parms->nb_prefix_samples0;
int dmrsoffset = 3*(frame_parms->ofdm_symbol_size+frame_parms->nb_prefix_samples) + frame_parms->nb_prefix_samples0;
if ((int64_t)maxlev0 > (5*avg0)) {*lev = maxlev0; *avg=avg0; return((length+maxpos0-dmrsoffset)%length);}
......
......@@ -101,6 +101,7 @@ void feptx0(RU_t *ru,int slot) {
"ru->generate_dmrs_sync should not be set, frame_type %d, is_slave %d\n",
fp->frame_type,ru->is_slave);
*/
if (ru->generate_dmrs_sync == 1 && slot == 0 && subframe == 1 && aa==0) {
int32_t dmrs[ru->frame_parms.ofdm_symbol_size*14] __attribute__((aligned(32)));
int32_t *dmrsp[2] = {&dmrs[(3-ru->frame_parms.Ncp)*ru->frame_parms.ofdm_symbol_size],NULL};
......@@ -128,12 +129,18 @@ void feptx0(RU_t *ru,int slot) {
1,
fp);
*/
} else {
normal_prefix_mod(&ru->common.txdataF_BF[aa][slot*slot_sizeF],
(int*)&ru->common.txdata[aa][slot_offset],
7,
fp);
}
normal_prefix_mod(&ru->common.txdataF_BF[aa][slot*slot_sizeF],
(int*)&ru->common.txdata[aa][slot_offset],
3,
fp);
}
else {
normal_prefix_mod(&ru->common.txdataF_BF[aa][slot*slot_sizeF],
(int*)&ru->common.txdata[aa][slot_offset],
7,
fp);
}
}
/*
len = fp->samples_per_tti>>1;
......
......@@ -521,7 +521,7 @@ int wakeup_txfh(eNB_rxtx_proc_t *proc,PHY_VARS_eNB *eNB) {
exit_fun( "error locking mutex_eNB" );
return(-1);
}
printf("waking up for frame %d subframe %d for RU TX \n", proc->frame_tx, proc->subframe_tx);
++ru_proc->instance_cnt_eNBs;
ru_proc->timestamp_tx = proc->timestamp_tx;
ru_proc->subframe_tx = proc->subframe_tx;
......
......@@ -422,7 +422,7 @@ void fh_if4p5_north_asynch_in(RU_t *ru,int *frame,int *subframe) {
LOG_D(PHY,"fh_if4p5_north_asynch_in: RU %d, frame %d, subframe %d\n",ru->idx,*frame,*subframe);
do {
recv_IF4p5(ru, &frame_tx, &subframe_tx, &packet_type, &symbol_number);
//printf("income frame.subframe %d.%d, our frame.subframe %d.%d\n",frame_tx,subframe_tx,*frame,*subframe);
LOG_D(PHY,"income frame.subframe %d.%d, our frame.subframe %d.%d.%d (symbol mask %x)\n",frame_tx,subframe_tx,*frame,*subframe,symbol_number,symbol_mask);
if (ru->cmd == STOP_RU){
LOG_E(PHY,"Got STOP_RU\n");
pthread_mutex_lock(&proc->mutex_ru);
......@@ -796,9 +796,10 @@ void tx_rf(RU_t *ru) {
ru->nb_tx,
flags);
ru->south_out_cnt++;
LOG_D(PHY,"[TXPATH] RU %d tx_rf, writing to TS %llu, frame %d, unwrapped_frame %d, subframe %d\n",ru->idx,
(long long unsigned int)proc->timestamp_tx,proc->frame_tx,proc->frame_tx_unwrap,proc->subframe_tx);
//int se = dB_fixed(signal_energy(txp[0],siglen+sf_extension));
//LOG_D(PHY,"[TXPATH] RU %d tx_rf (en %d,len %d), writing to TS %llu, frame %d, unwrapped_frame %d, subframe %d\n",ru->idx,se,siglen+sf_extension,
// (long long unsigned int)proc->timestamp_tx,proc->frame_tx,proc->frame_tx_unwrap,proc->subframe_tx);
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE, 0 );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment