Fix various typos and minor issues

Some typos in the comments/error messages.
A couple of minor bugs (should not have any impact in the performance).
This commit is contained in:
dvdgrgrtt 2021-12-07 15:45:29 +01:00 committed by dvdgrgrtt
parent 1390eeea88
commit 3fad800ef6
3 changed files with 8 additions and 5 deletions

View File

@ -251,7 +251,7 @@ uint32_t srsran_sch_cfg_nr_info(const srsran_sch_cfg_nr_t* sch_cfg, char* str, u
// Append SCH information
len += phch_cfg_sch_to_str(&sch_cfg->sch_cfg, &str[len], str_len - len);
// Append SCH information
// Append reserved RE information
len += phch_cfg_rvd_to_str(&sch_cfg->rvd_re, &str[len], str_len - len);
// UCI configuration

View File

@ -626,6 +626,7 @@ int srsran_ra_nr_fill_tb(const srsran_sch_cfg_nr_t* pdsch_cfg,
uint32_t N_re_rvd = srsran_re_pattern_list_count(&pdsch_cfg->rvd_re, grant->S, grant->S + grant->L, grant->prb_idx);
// Steps 2,3,4
tb->mcs = mcs_idx;
tb->tbs = (int)srsran_ra_nr_tbs(N_re, S, R, Qm, tb->N_L);
tb->R = R;
tb->mod = m;

View File

@ -156,7 +156,7 @@ int main(int argc, char** argv)
goto clean_exit;
}
// Set PDSCH grant without considering any procedure
// Set PUSCH grant without considering any procedure
pusch_cfg.grant.nof_dmrs_cdm_groups_without_data = 1; // No need for MIMO
pusch_cfg.grant.nof_layers = carrier.max_mimo_layers;
pusch_cfg.grant.dci_format = srsran_dci_format_nr_1_0;
@ -196,7 +196,7 @@ int main(int argc, char** argv)
pusch_cfg.grant.dci_format = srsran_dci_format_nr_0_0;
if (srsran_ra_nr_fill_tb(&pusch_cfg, &pusch_cfg.grant, mcs, &pusch_cfg.grant.tb[0]) < SRSRAN_SUCCESS) {
ERROR("Error filing tb");
ERROR("Error filling tb");
goto clean_exit;
}
@ -270,10 +270,12 @@ int main(int argc, char** argv)
// Check symbols Mean Square Error (MSE)
uint32_t nof_re = srsran_ra_dl_nr_slot_nof_re(&pusch_cfg, &pusch_cfg.grant);
if (nof_re * pusch_cfg.grant.nof_layers > 0) {
float mse = 0.0f;
float mse = 0.0f;
float mse_tmp = 0.0f;
for (uint32_t i = 0; i < pusch_cfg.grant.nof_layers; i++) {
for (uint32_t j = 0; j < nof_re; j++) {
mse += cabsf(pusch_tx.d[i][j] - pusch_rx.d[i][j]);
mse_tmp = cabsf(pusch_tx.d[i][j] - pusch_rx.d[i][j]);
mse += mse_tmp * mse_tmp;
}
}
mse = mse / (nof_re * pusch_cfg.grant.nof_layers);