update debugger

This commit is contained in:
ahadi
2021-12-13 14:04:57 +01:00
parent b1cb0c463c
commit c63960c0f2
2 changed files with 13 additions and 18 deletions
+13 -13
View File
@@ -4,8 +4,8 @@
#include "PHY/NR_REFSIG/nr_refsig.h"
#include "PHY/sse_intrin.h"
#define DEBUG_PRS_MOD
//#define DEBUG_PRS_MAP
//#define DEBUG_PRS_MOD
#define DEBUG_PRS_MAP
extern short nr_qpsk_mod_table[8];
@@ -59,21 +59,21 @@ int nr_generate_prs(uint32_t **nr_gold_prs,
mod_prs[(m<<1)+1] = nr_qpsk_mod_table[(idx<<1) + 1];
#ifdef DEBUG_PRS_MOD
printf("m %d idx %d gold seq %d mod_prs %d %d\n", m, idx, nr_gold_prs[l][(m<<1)>>5], mod_prs[m<<1], mod_prs[(m<<1)+1]);
#endif
printf("m %d idx %d gold seq %d mod_prs %d %d\n", m, idx, nr_gold_prs[l][(m<<1)>>5], mod_prs[m<<1], mod_prs[(m<<1)+1]);
#endif
#ifdef DEBUG_PRS_MAP
printf("m %d at k %d of l %d\n", m, k, l);
#endif
#ifdef DEBUG_PRS_MAP
printf("m %d at k %d of l %d\n", m, k, l);
#endif
((int16_t *)txdataF)[(l*frame_parms->ofdm_symbol_size + k)<<1] = (amp * mod_prs[m<<1]) >> 15;
((int16_t *)txdataF)[((l*frame_parms->ofdm_symbol_size + k)<<1) + 1] = (amp * mod_prs[(m<<1) + 1]) >> 15;
#ifdef DEBUG_PRS_MAP
printf("(%d,%d)\n",
((int16_t *)txdataF)[(l*frame_parms->ofdm_symbol_size + k)<<1],
((int16_t *)txdataF)[((l*frame_parms->ofdm_symbol_size + k)<<1)+1]);
#endif
#ifdef DEBUG_PRS_MAP
printf("(%d,%d)\n",
((int16_t *)txdataF)[(l*frame_parms->ofdm_symbol_size + k)<<1],
((int16_t *)txdataF)[((l*frame_parms->ofdm_symbol_size + k)<<1)+1]);
#endif
k = k + prs_data->CombSize;
@@ -81,6 +81,6 @@ int nr_generate_prs(uint32_t **nr_gold_prs,
k-=frame_parms->ofdm_symbol_size;
}
}
LOG_M("nr_prs.m", "prs",(int16_t *)&txdataF[0],frame_parms->samples_per_slot_wCP, 1, 1);
return 0;
}
@@ -94,8 +94,6 @@ void nr_common_signal_procedures (PHY_VARS_gNB *gNB,int frame,int slot,nfapi_nr_
nr_generate_pss(gNB->d_pss, &txdataF[0][txdataF_offset], AMP, ssb_start_symbol, cfg, fp);
nr_generate_sss(gNB->d_sss, &txdataF[0][txdataF_offset], AMP, ssb_start_symbol, cfg, fp);
//nr_generate_prs(gNB->nr_gold_prs[n_hf][ssb_index&7],&txdataF[0][txdataF_offset], AMP, ssb_start_symbol, cfg, fp);
if (cfg->carrier_config.num_tx_ant.value <= 4)
nr_generate_pbch_dmrs(gNB->nr_gold_pbch_dmrs[n_hf][ssb_index&7],&txdataF[0][txdataF_offset], AMP, ssb_start_symbol, cfg, fp);
@@ -116,8 +114,6 @@ void nr_common_signal_procedures (PHY_VARS_gNB *gNB,int frame,int slot,nfapi_nr_
prs_data.PRSResourceRepetition=1;
prs_data.PRSResourceTimeGap=1;
prs_data.NPRSID=0;
//printf(" before Combsize %d \n", prs_data.CombSize);
// tbc
nr_generate_prs(gNB->nr_gold_prs[slot],&txdataF[0][txdataF_offset], AMP, &prs_data, cfg, fp);
@@ -249,7 +245,6 @@ void phy_procedures_gNB_TX(PHY_VARS_gNB *gNB,
prs_data.PRSResourceRepetition=1;
prs_data.PRSResourceTimeGap=1;
prs_data.NPRSID=0;
//printf(" before %p \n",&prs_data);
// tbc