diff --git a/openair1/PHY/MODULATION/slot_fep_nr.c b/openair1/PHY/MODULATION/slot_fep_nr.c index 1334c5c99e04da9b99e92259ebfe466bd67c0228..d312e78f139aee5be7c071fc6ac03ae95b7c4621 100644 --- a/openair1/PHY/MODULATION/slot_fep_nr.c +++ b/openair1/PHY/MODULATION/slot_fep_nr.c @@ -145,7 +145,7 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue, if (abs_symbol%(0x7<<frame_parms->numerology_index)) { - rx_offset += nb_prefix_samples0; + rx_offset += nb_prefix_samples; if (rx_offset > (frame_length_samples - frame_parms->ofdm_symbol_size)) memcpy((short*) &common_vars->rxdata[aa][frame_length_samples], (short*) &common_vars->rxdata[aa][0], @@ -170,7 +170,7 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue, } } else { - rx_offset += frame_parms->nb_prefix_samples; + rx_offset += nb_prefix_samples0; if (rx_offset > (frame_length_samples - frame_parms->ofdm_symbol_size)) memcpy((void *) &common_vars->rxdata[aa][frame_length_samples], (void *) &common_vars->rxdata[aa][0], diff --git a/openair1/SCHED_NR/nr_ru_procedures.c b/openair1/SCHED_NR/nr_ru_procedures.c index 1337214cf4813aee537bb81aed80994f53c95e8b..aefeec43e2d55d0cf4f181fe4fa806346bbd920b 100644 --- a/openair1/SCHED_NR/nr_ru_procedures.c +++ b/openair1/SCHED_NR/nr_ru_procedures.c @@ -72,7 +72,7 @@ void nr_feptx0(RU_t *ru,int tti_tx,int first_symbol, int num_symbols, int aa) { int abs_first_symbol = slot*fp->symbols_per_slot; for (uint16_t idx_sym=abs_first_symbol; idx_sym<abs_first_symbol+first_symbol; idx_sym++) - slot_offset += (idx_sym%(0x7<<fp->numerology_index)) ? fp->nb_prefix_samples0 : fp->nb_prefix_samples; + slot_offset += (idx_sym%(0x7<<fp->numerology_index)) ? fp->nb_prefix_samples : fp->nb_prefix_samples0; slot_offset += fp->ofdm_symbol_size*first_symbol; @@ -88,15 +88,7 @@ void nr_feptx0(RU_t *ru,int tti_tx,int first_symbol, int num_symbols, int aa) { else { if (fp->numerology_index != 0) { - if (slot%(fp->slots_per_subframe/2)) { - PHY_ofdm_mod(&ru->common.txdataF_BF[aa][slot_offsetF], - (int*)&ru->common.txdata[aa][slot_offset], - fp->ofdm_symbol_size, - num_symbols, - fp->nb_prefix_samples, - CYCLIC_PREFIX); - } - else { + if (!(slot%(fp->slots_per_subframe/2))&&(first_symbol==0)) { PHY_ofdm_mod(&ru->common.txdataF_BF[aa][slot_offsetF], (int*)&ru->common.txdata[aa][slot_offset], fp->ofdm_symbol_size, @@ -110,6 +102,14 @@ void nr_feptx0(RU_t *ru,int tti_tx,int first_symbol, int num_symbols, int aa) { fp->nb_prefix_samples, CYCLIC_PREFIX); } + else { + PHY_ofdm_mod(&ru->common.txdataF_BF[aa][slot_offsetF], + (int*)&ru->common.txdata[aa][slot_offset], + fp->ofdm_symbol_size, + num_symbols, + fp->nb_prefix_samples, + CYCLIC_PREFIX); + } } else {