Skip to content

to get SRS signal iq data

I try to print the SRS signal's real and imaginary parts using the debugging part of nr_ul_channel_estimation.c.

#ifdef SRS_DEBUG
        int subcarrier_log = subcarrier-subcarrier_offset;
        if(subcarrier_log < 0) {
          subcarrier_log = subcarrier_log + frame_parms->ofdm_symbol_size;
        }
        if(subcarrier_log%12 == 0) {
          LOG_I(NR_PHY,"------------------------------------ %d ------------------------------------\n", subcarrier_log/12);
          LOG_I(NR_PHY,"\t  __genRe________genIm__|____rxRe_________rxIm__|____lsRe________lsIm_\n");
        }
        LOG_I(NR_PHY,"(%4i) %6i\t%6i  |  %6i\t%6i  |  %6i\t%6i\n",
              subcarrier_log,
              ((c16_t*)srs_generated_signal[p_index])[subcarrier].r, ((c16_t*)srs_generated_signal[p_index])[subcarrier].i,
              ((c16_t*)srs_received_signal[ant])[subcarrier].r, ((c16_t*)srs_received_signal[ant])[subcarrier].i,
              ls_estimated[0], ls_estimated[1]);
#endif

But the results had bad correlation with the SRS iq data from other software like matlab nr tool. is there any further process need to be done on srs_received_signal, or it has been processed and it already not a pure siganl iq data or i should look up to some other script?

Edited by Robert Schmidt