phy: pass number PRBs from the correct cell config into the channel emulator when running NR standalone mode

master
yagoda 3 years ago committed by Justin Tallon
parent d5909a306f
commit 66b5b6c236

@ -46,10 +46,11 @@ bool phy_common::init(const phy_cell_cfg_list_t& cell_list_,
// Instantiate DL channel emulator
if (params.dl_channel_args.enable) {
int channel_prbs = (cell_list_lte.empty()) ? cell_list_nr[0].carrier.nof_prb : cell_list_lte[0].cell.nof_prb;
dl_channel = srsran::channel_ptr(
new srsran::channel(params.dl_channel_args, get_nof_rf_channels(), srslog::fetch_basic_logger("PHY")));
dl_channel->set_srate((uint32_t)srsran_sampling_freq_hz(cell_list_lte[0].cell.nof_prb));
dl_channel->set_signal_power_dBfs(srsran_enb_dl_get_maximum_signal_power_dBfs(cell_list_lte[0].cell.nof_prb));
dl_channel->set_srate((uint32_t)srsran_sampling_freq_hz(channel_prbs));
dl_channel->set_signal_power_dBfs(srsran_enb_dl_get_maximum_signal_power_dBfs(channel_prbs));
}
// Create grants
@ -58,7 +59,9 @@ bool phy_common::init(const phy_cell_cfg_list_t& cell_list_,
}
// Set UE PHY data-base stack and configuration
ue_db.init(stack, params, cell_list_lte);
if (!cell_list_lte.empty()) {
ue_db.init(stack, params, cell_list_lte);
}
if (mcch_configured) {
build_mch_table();
build_mcch_table();

Loading…
Cancel
Save