added basic analytics for PDSCH measurements
This commit is contained in:
@@ -181,7 +181,7 @@ int main(int argc, char **argv)
|
||||
|
||||
//unsigned char frame_type = 0;
|
||||
|
||||
int frame=0,slot=1;
|
||||
int frame=1,slot=1;
|
||||
int frame_length_complex_samples;
|
||||
int frame_length_complex_samples_no_prefix;
|
||||
NR_DL_FRAME_PARMS *frame_parms;
|
||||
@@ -716,6 +716,8 @@ int main(int argc, char **argv)
|
||||
reset_meas(&gNB->tparity);
|
||||
reset_meas(&gNB->toutput);
|
||||
|
||||
clear_pdsch_stats(gNB);
|
||||
|
||||
n_errors = 0;
|
||||
effRate = 0;
|
||||
//n_errors2 = 0;
|
||||
@@ -956,6 +958,7 @@ int main(int argc, char **argv)
|
||||
(float) n_errors / (float) n_trials);
|
||||
printf("*****************************************\n");
|
||||
printf("\n");
|
||||
dump_pdsch_stats(gNB);
|
||||
printf("SNR %f : n_errors (negative CRC) = %d/%d, Avg round %.2f, Channel BER %e, Eff Rate %.4f bits/slot, Eff Throughput %.2f, TBS %d bits/slot\n", SNR, n_errors, n_trials,roundStats[snrRun],(double)errors_scrambling/available_bits/n_trials,effRate,effRate/TBS*100,TBS);
|
||||
printf("\n");
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
//#include "openair1/SIMULATION/NR_PHY/nr_dummy_functions.c"
|
||||
#include "openair2/LAYER2/NR_MAC_UE/mac_proto.h"
|
||||
#include "openair2/LAYER2/NR_MAC_gNB/mac_proto.h"
|
||||
|
||||
#include "openair1/NR_REFSIG/pss_nr.h"
|
||||
#define inMicroS(a) (((double)(a))/(cpu_freq_GHz*1000.0))
|
||||
#include "SIMULATION/LTE_PHY/common_sim.h"
|
||||
|
||||
@@ -707,6 +707,7 @@ int main(int argc, char **argv)
|
||||
|
||||
crc_status = 1;
|
||||
errors_decoding = 0;
|
||||
memset((void*)roundStats,0,50*sizeof(roundStats[0]));
|
||||
while (round<max_rounds && crc_status) {
|
||||
round_trials[round]++;
|
||||
ulsch_ue[0]->harq_processes[harq_pid]->round = round;
|
||||
@@ -1028,7 +1029,8 @@ int main(int argc, char **argv)
|
||||
printf("*****************************************\n");
|
||||
printf("SNR %f: n_errors (%d/%d,%d/%d,%d/%d,%d/%d) (negative CRC), false_positive %d/%d, errors_scrambling (%u/%u,%u/%u,%u/%u,%u/%u\n", SNR, n_errors[0], round_trials[0],n_errors[1], round_trials[1],n_errors[2], round_trials[2],n_errors[3], round_trials[3], n_false_positive, n_trials, errors_scrambling[0],available_bits*n_trials,errors_scrambling[1],available_bits*n_trials,errors_scrambling[2],available_bits*n_trials,errors_scrambling[3],available_bits*n_trials);
|
||||
printf("\n");
|
||||
printf("SNR %f: Channel BLER (%e,%e,%e,%e), Channel BER (%e,%e,%e,%e) Avg round %.2f, Eff Rate %.4f bits/slot, Eff Throughput %.2f, TBS %d bits/slot\n", SNR,
|
||||
printf("SNR %f: Channel BLER (%e,%e,%e,%e), Channel BER (%e,%e,%e,%e) Avg round %.2f, Eff Rate %.4f bits/slot, Eff Throughput %.2f, TBS %d bits/slot\n",
|
||||
SNR,
|
||||
(double)n_errors[0]/round_trials[0],
|
||||
(double)n_errors[1]/round_trials[0],
|
||||
(double)n_errors[2]/round_trials[0],
|
||||
|
||||
Reference in New Issue
Block a user