Commit 5b916128 authored by francescomani's avatar francescomani

printing gNB MIMO stats only when reported

parent 1268b27c
...@@ -821,6 +821,7 @@ static void extract_pucch_csi_report(NR_CSI_MeasConfig_t *csi_MeasConfig, ...@@ -821,6 +821,7 @@ static void extract_pucch_csi_report(NR_CSI_MeasConfig_t *csi_MeasConfig,
evaluate_rsrp_report(UE,sched_ctrl,csi_report_id,payload,&cumul_bits,reportQuantity_type); evaluate_rsrp_report(UE,sched_ctrl,csi_report_id,payload,&cumul_bits,reportQuantity_type);
break; break;
case NR_CSI_ReportConfig__reportQuantity_PR_cri_RI_CQI: case NR_CSI_ReportConfig__reportQuantity_PR_cri_RI_CQI:
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.print_report = true;
cri_bitlen = csi_report->csi_meas_bitlen.cri_bitlen; cri_bitlen = csi_report->csi_meas_bitlen.cri_bitlen;
if(cri_bitlen) if(cri_bitlen)
evaluate_cri_report(payload,cri_bitlen,cumul_bits,sched_ctrl); evaluate_cri_report(payload,cri_bitlen,cumul_bits,sched_ctrl);
...@@ -834,6 +835,7 @@ static void extract_pucch_csi_report(NR_CSI_MeasConfig_t *csi_MeasConfig, ...@@ -834,6 +835,7 @@ static void extract_pucch_csi_report(NR_CSI_MeasConfig_t *csi_MeasConfig,
evaluate_cqi_report(payload,csi_report,cumul_bits,r_index,UE,cqi_table); evaluate_cqi_report(payload,csi_report,cumul_bits,r_index,UE,cqi_table);
break; break;
case NR_CSI_ReportConfig__reportQuantity_PR_cri_RI_PMI_CQI: case NR_CSI_ReportConfig__reportQuantity_PR_cri_RI_PMI_CQI:
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.print_report = true;
cri_bitlen = csi_report->csi_meas_bitlen.cri_bitlen; cri_bitlen = csi_report->csi_meas_bitlen.cri_bitlen;
if(cri_bitlen) if(cri_bitlen)
evaluate_cri_report(payload,cri_bitlen,cumul_bits,sched_ctrl); evaluate_cri_report(payload,cri_bitlen,cumul_bits,sched_ctrl);
...@@ -850,6 +852,7 @@ static void extract_pucch_csi_report(NR_CSI_MeasConfig_t *csi_MeasConfig, ...@@ -850,6 +852,7 @@ static void extract_pucch_csi_report(NR_CSI_MeasConfig_t *csi_MeasConfig,
evaluate_cqi_report(payload,csi_report,cumul_bits,r_index,UE,cqi_table); evaluate_cqi_report(payload,csi_report,cumul_bits,r_index,UE,cqi_table);
break; break;
case NR_CSI_ReportConfig__reportQuantity_PR_cri_RI_LI_PMI_CQI: case NR_CSI_ReportConfig__reportQuantity_PR_cri_RI_LI_PMI_CQI:
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.print_report = true;
cri_bitlen = csi_report->csi_meas_bitlen.cri_bitlen; cri_bitlen = csi_report->csi_meas_bitlen.cri_bitlen;
if(cri_bitlen) if(cri_bitlen)
evaluate_cri_report(payload,cri_bitlen,cumul_bits,sched_ctrl); evaluate_cri_report(payload,cri_bitlen,cumul_bits,sched_ctrl);
......
...@@ -109,14 +109,15 @@ size_t dump_mac_stats(gNB_MAC_INST *gNB, char *output, size_t strlen, bool reset ...@@ -109,14 +109,15 @@ size_t dump_mac_stats(gNB_MAC_INST *gNB, char *output, size_t strlen, bool reset
avg_rsrp, avg_rsrp,
stats->num_rsrp_meas); stats->num_rsrp_meas);
output += snprintf(output, if(sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.print_report)
end - output, output += snprintf(output,
"UE %04x: CQI %d, RI %d, PMI (%d,%d)\n", end - output,
UE->rnti, "UE %04x: CQI %d, RI %d, PMI (%d,%d)\n",
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.wb_cqi_1tb, UE->rnti,
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.ri+1, sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.wb_cqi_1tb,
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.pmi_x1, sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.ri+1,
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.pmi_x2); sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.pmi_x1,
sched_ctrl->CSI_report.cri_ri_li_pmi_cqi_report.pmi_x2);
if (stats->srs_stats[0] != '\0') { if (stats->srs_stats[0] != '\0') {
output += snprintf(output, end - output, "UE %04x: %s\n", UE->rnti, stats->srs_stats); output += snprintf(output, end - output, "UE %04x: %s\n", UE->rnti, stats->srs_stats);
......
...@@ -467,10 +467,6 @@ typedef struct NR_bler_stats { ...@@ -467,10 +467,6 @@ typedef struct NR_bler_stats {
*/ */
#define MAX_NR_OF_REPORTED_RS 4 #define MAX_NR_OF_REPORTED_RS 4
typedef enum NR_CSI_Report_Config {
CSI_Report_PR_cri_ri_li_pmi_cqi_report,
CSI_Report_PR_ssb_cri_report
} NR_CSI_Report_Config_PR;
struct CRI_RI_LI_PMI_CQI { struct CRI_RI_LI_PMI_CQI {
uint8_t cri; uint8_t cri;
uint8_t ri; uint8_t ri;
...@@ -481,6 +477,7 @@ struct CRI_RI_LI_PMI_CQI { ...@@ -481,6 +477,7 @@ struct CRI_RI_LI_PMI_CQI {
uint8_t wb_cqi_2tb; uint8_t wb_cqi_2tb;
uint8_t cqi_table; uint8_t cqi_table;
uint8_t csi_report_id; uint8_t csi_report_id;
bool print_report;
}; };
typedef struct CRI_SSB_RSRP { typedef struct CRI_SSB_RSRP {
......
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