diff --git a/lib/include/srsran/phy/gnb/gnb_ul.h b/lib/include/srsran/phy/gnb/gnb_ul.h index 95c37116e..424d068dd 100644 --- a/lib/include/srsran/phy/gnb/gnb_ul.h +++ b/lib/include/srsran/phy/gnb/gnb_ul.h @@ -60,11 +60,12 @@ SRSRAN_API int srsran_gnb_ul_get_pucch(srsran_gnb_ul_t* q, srsran_uci_value_nr_t* uci_value, srsran_csi_trs_measurements_t* meas); -SRSRAN_API uint32_t srsran_gnb_ul_pucch_info(srsran_gnb_ul_t* q, - const srsran_pucch_nr_resource_t* resource, - const srsran_uci_data_nr_t* uci_data, - char* str, - uint32_t str_len); +SRSRAN_API uint32_t srsran_gnb_ul_pucch_info(srsran_gnb_ul_t* q, + const srsran_pucch_nr_resource_t* resource, + const srsran_uci_data_nr_t* uci_data, + const srsran_csi_trs_measurements_t* csi, + char* str, + uint32_t str_len); SRSRAN_API uint32_t srsran_gnb_ul_pusch_info(srsran_gnb_ul_t* q, const srsran_sch_cfg_nr_t* cfg, diff --git a/lib/src/phy/gnb/gnb_ul.c b/lib/src/phy/gnb/gnb_ul.c index bf09799d5..7e2c48847 100644 --- a/lib/src/phy/gnb/gnb_ul.c +++ b/lib/src/phy/gnb/gnb_ul.c @@ -299,11 +299,12 @@ int srsran_gnb_ul_get_pucch(srsran_gnb_ul_t* q, return SRSRAN_SUCCESS; } -uint32_t srsran_gnb_ul_pucch_info(srsran_gnb_ul_t* q, - const srsran_pucch_nr_resource_t* resource, - const srsran_uci_data_nr_t* uci_data, - char* str, - uint32_t str_len) +uint32_t srsran_gnb_ul_pucch_info(srsran_gnb_ul_t* q, + const srsran_pucch_nr_resource_t* resource, + const srsran_uci_data_nr_t* uci_data, + const srsran_csi_trs_measurements_t* csi, + char* str, + uint32_t str_len) { if (q == NULL || uci_data == NULL) { return 0; @@ -311,10 +312,11 @@ uint32_t srsran_gnb_ul_pucch_info(srsran_gnb_ul_t* q, uint32_t len = 0; - len += srsran_pucch_nr_info(resource, uci_data, str, str_len - len); + len += srsran_pucch_nr_info(resource, uci_data, &str[len], str_len - len); - len = srsran_print_check( - str, str_len, len, "snr=%+.1f valid=%c", q->chest_pucch.snr_db, uci_data->value.valid ? 'y' : 'n'); + len += srsran_csi_meas_info_short(csi, &str[len], str_len - len); + + len = srsran_print_check(str, str_len, len, "valid=%c ", uci_data->value.valid ? 'y' : 'n'); return len; } diff --git a/lib/src/phy/phch/dci_nr.c b/lib/src/phy/phch/dci_nr.c index f52ec4fe9..33ebbbcf4 100644 --- a/lib/src/phy/phch/dci_nr.c +++ b/lib/src/phy/phch/dci_nr.c @@ -2072,7 +2072,7 @@ uint32_t srsran_dci_ctx_to_str(const srsran_dci_ctx_t* ctx, char* str, uint32_t len = srsran_print_check(str, str_len, len, - "%s-rnti=%04x dci=%s ss=%s", + "%s-rnti=%04x dci=%s ss=%s ", srsran_rnti_type_str_short(ctx->rnti_type), ctx->rnti, srsran_dci_format_nr_string(ctx->format), diff --git a/srsenb/src/phy/nr/slot_worker.cc b/srsenb/src/phy/nr/slot_worker.cc index dbdf5d5f7..efad85c8b 100644 --- a/srsenb/src/phy/nr/slot_worker.cc +++ b/srsenb/src/phy/nr/slot_worker.cc @@ -195,6 +195,7 @@ bool slot_worker::work_ul() srsran_gnb_ul_pucch_info(&gnb_ul, &pucch.candidates[0].resource, &pucch_info[best_candidate].uci_data, + &pucch_info[best_candidate].csi, str.data(), (uint32_t)str.size()); diff --git a/srsue/src/phy/nr/cc_worker.cc b/srsue/src/phy/nr/cc_worker.cc index ec887cceb..46c26c11c 100644 --- a/srsue/src/phy/nr/cc_worker.cc +++ b/srsue/src/phy/nr/cc_worker.cc @@ -161,22 +161,15 @@ void cc_worker::decode_pdcch_dl() if (logger.debug.enabled()) { for (uint32_t i = 0; i < ue_dl.pdcch_info_count; i++) { const srsran_ue_dl_nr_pdcch_info_t* info = &ue_dl.pdcch_info[i]; - logger.debug( - "PDCCH: dci=%s, %s-rnti=%x, crst_id=%d, ss_type=%s, ncce=%d, al=%d, EPRE=%+.2f, RSRP=%+.2f, corr=%.3f; " - "evm=%f; nof_bits=%d; crc=%s;", - srsran_dci_format_nr_string(info->dci_ctx.format), - srsran_rnti_type_str_short(info->dci_ctx.rnti_type), - info->dci_ctx.rnti, - info->dci_ctx.coreset_id, - srsran_ss_type_str(info->dci_ctx.ss_type), - info->dci_ctx.location.ncce, - info->dci_ctx.location.L, - info->measure.epre_dBfs, - info->measure.rsrp_dBfs, - info->measure.norm_corr, - info->result.evm, - info->nof_bits, - info->result.crc ? "OK" : "KO"); + std::array dci_ctx; + srsran_dci_ctx_to_str(&info->dci_ctx, dci_ctx.data(), (uint32_t)dci_ctx.size()); + logger.debug("PDCCH: %sEPRE=%+.2f, RSRP=%+.2f, corr=%.3f nof_bits=%d crc=%s", + dci_ctx.data(), + info->measure.epre_dBfs, + info->measure.rsrp_dBfs, + info->measure.norm_corr, + info->nof_bits, + info->result.crc ? "OK" : "KO"); } } }