diff --git a/lib/src/asn1/rrc_nr.cc b/lib/src/asn1/rrc_nr.cc index 3988b94c..761661a9 100644 --- a/lib/src/asn1/rrc_nr.cc +++ b/lib/src/asn1/rrc_nr.cc @@ -48632,15 +48632,433 @@ SRSASN_CODE cell_group_cfg_s::unpack(cbit_ref& bref) SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { - // TO-DO: assume input only dl bwp list; write other part parsing of master cell group + // TO-DO: Currently assume input only dl+ul bwp lists; write other part parsing of master cell group + + // Assume we load those hidden bwp configs only once, so essentially everything is treated + // as ADD (NOT MOD), and hence we just need to append to array, rather than search if the + // config might already exist and modify accordingly + + /** + * + * NON-INITIAL UL BWP(S) CONFIG EXTRACTION + * + */ + if (js_in["spCellConfigDedicated"].contains("uplinkConfig")) { + sp_cell_cfg.sp_cell_cfg_ded.ul_cfg_present = true; + // printf("[9/21] trigger 3.1\n"); + } + if (js_in["spCellConfigDedicated"]["uplinkConfig"]["uplinkBWP-ToAddModList"].is_array()) { + auto& ul_bwp_to_add_mod_list = sp_cell_cfg.sp_cell_cfg_ded.ul_cfg.ul_bwp_to_add_mod_list; + json js_ul_bwp_to_add_mod_list = js_in["spCellConfigDedicated"]["uplinkConfig"]["uplinkBWP-ToAddModList"]; + + /* uplinkBWP-ToAddModList */ + for (auto& js_cur_ul_bwp_el : js_ul_bwp_to_add_mod_list.items()) { + // printf("[9/21] trigger 3.2\n"); + json js_cur_ul_bwp = js_cur_ul_bwp_el.value(); + bwp_ul_s cur_ul_bwp; + cur_ul_bwp.bwp_id = js_cur_ul_bwp["bwp-Id"]; + + /* bwp-Common */ + cur_ul_bwp.bwp_common_present = js_cur_ul_bwp.contains("bwp-Common"); + + /* bwp-Common -- genericParameters */ + json js_cur_ul_bwp_common_generic = js_cur_ul_bwp["bwp-Common"]["genericParameters"]; + + cur_ul_bwp.bwp_common.generic_params.location_and_bw = js_cur_ul_bwp_common_generic["locationAndBandwidth"]; + cur_ul_bwp.bwp_common.generic_params.subcarrier_spacing = (asn1::rrc_nr::subcarrier_spacing_e)js_cur_ul_bwp_common_generic["subcarrierSpacing"]; + + /* bwp-Common -- rach-ConfigCommon */ + cur_ul_bwp.bwp_common.rach_cfg_common_present = js_cur_ul_bwp["bwp-Common"].contains("rach-ConfigCommon"); + // skip rach-related config copy as it's not related to DCI computation + + /* bwp-Common -- pusch-ConfigCommon */ + cur_ul_bwp.bwp_common.pusch_cfg_common_present = js_cur_ul_bwp["bwp-Common"].contains("pusch-ConfigCommon"); + if (cur_ul_bwp.bwp_common.pusch_cfg_common_present) { + json js_cur_ul_bwp_common_pusch_common = js_cur_ul_bwp["bwp-Common"]["pusch-ConfigCommon"]; + + json js_cur_ul_bwp_common_pusch_common_time_alloc_list = js_cur_ul_bwp_common_pusch_common["pusch-TimeDomainAllocationList"]; + cur_ul_bwp.bwp_common.pusch_cfg_common.set_setup().pusch_time_domain_alloc_list; + for (auto& js_cur_ul_bwp_common_pusch_common_time_alloc_el : js_cur_ul_bwp_common_pusch_common_time_alloc_list.items()) { + json js_cur_ul_bwp_common_pusch_common_time_alloc = js_cur_ul_bwp_common_pusch_common_time_alloc_el.value()["PUSCH-TimeDomainResourceAllocation"]; + pusch_time_domain_res_alloc_s cur_ul_bwp_common_pusch_common_time_alloc; + cur_ul_bwp_common_pusch_common_time_alloc.k2_present = true; + cur_ul_bwp_common_pusch_common_time_alloc.k2 = js_cur_ul_bwp_common_pusch_common_time_alloc["k2"]; + cur_ul_bwp_common_pusch_common_time_alloc.map_type = (asn1::rrc_nr::pusch_time_domain_res_alloc_s::map_type_e_)js_cur_ul_bwp_common_pusch_common_time_alloc["mappingType"]; + cur_ul_bwp_common_pusch_common_time_alloc.start_symbol_and_len = js_cur_ul_bwp_common_pusch_common_time_alloc["startSymbolAndLength"]; + + cur_ul_bwp.bwp_common.pusch_cfg_common.set_setup().pusch_time_domain_alloc_list.push_back(cur_ul_bwp_common_pusch_common_time_alloc); + } + + cur_ul_bwp.bwp_common.pusch_cfg_common.set_setup().msg3_delta_preamb_present = js_cur_ul_bwp_common_pusch_common.contains("msg3-DeltaPreamble"); + if (cur_ul_bwp.bwp_common.pusch_cfg_common.setup().msg3_delta_preamb_present) { + cur_ul_bwp.bwp_common.pusch_cfg_common.set_setup().msg3_delta_preamb = js_cur_ul_bwp_common_pusch_common["msg3-DeltaPreamble"]; + } + + cur_ul_bwp.bwp_common.pusch_cfg_common.set_setup().p0_nominal_with_grant_present = js_cur_ul_bwp_common_pusch_common.contains("p0-NominalWithGrant"); + if (cur_ul_bwp.bwp_common.pusch_cfg_common.setup().p0_nominal_with_grant_present) { + cur_ul_bwp.bwp_common.pusch_cfg_common.set_setup().p0_nominal_with_grant = js_cur_ul_bwp_common_pusch_common["p0-NominalWithGrant"]; + } + } + // printf("[9/21] trigger 3.3\n"); + + /* bwp-Common -- pucch-ConfigCommon */ + cur_ul_bwp.bwp_common.pucch_cfg_common_present = js_cur_ul_bwp["bwp-Common"].contains("pucch-ConfigCommon"); + if (cur_ul_bwp.bwp_common.pucch_cfg_common_present) { + json js_cur_ul_bwp_common_pucch_common = js_cur_ul_bwp["bwp-Common"]["pucch-ConfigCommon"]; + + cur_ul_bwp.bwp_common.pucch_cfg_common.set_setup().pucch_res_common_present = js_cur_ul_bwp_common_pucch_common.contains("pucch-ResourceCommon"); + if (cur_ul_bwp.bwp_common.pucch_cfg_common.setup().pucch_res_common_present) { + cur_ul_bwp.bwp_common.pucch_cfg_common.set_setup().pucch_res_common = js_cur_ul_bwp_common_pucch_common["pucch-ResourceCommon"]; + } + cur_ul_bwp.bwp_common.pucch_cfg_common.set_setup().pucch_group_hop = (asn1::rrc_nr::pucch_cfg_common_s::pucch_group_hop_e_)js_cur_ul_bwp_common_pucch_common["pucch-GroupHopping"]; + + cur_ul_bwp.bwp_common.pucch_cfg_common.set_setup().p0_nominal_present = js_cur_ul_bwp_common_pucch_common.contains("p0-nominal"); + + if (cur_ul_bwp.bwp_common.pucch_cfg_common.setup().p0_nominal_present) { + cur_ul_bwp.bwp_common.pucch_cfg_common.set_setup().p0_nominal = js_cur_ul_bwp_common_pucch_common["p0-nominal"]; + } + } + // printf("[9/21] trigger 3.4\n"); + + /* bwp-Dedicated */ + cur_ul_bwp.bwp_ded_present = js_cur_ul_bwp.contains("bwp-Dedicated"); + + /* bwp-Dedicated -- pucch-Config */ + cur_ul_bwp.bwp_ded.pucch_cfg_present = js_cur_ul_bwp["bwp-Dedicated"].contains("pucch-Config"); + if (cur_ul_bwp.bwp_ded.pucch_cfg_present) { + json js_cur_ul_bwp_ded_pucch = js_cur_ul_bwp["bwp-Dedicated"]["pucch-Config"]; + + /* resourceSetToAddModList */ + for (auto& js_cur_ul_bwp_ded_pucch_res_set_el : js_cur_ul_bwp_ded_pucch["resourceSetToAddModList"].items()) { + json js_cur_ul_bwp_ded_pucch_res_set = js_cur_ul_bwp_ded_pucch_res_set_el.value(); + pucch_res_set_s cur_ul_bwp_ded_pucch_res_set; + + cur_ul_bwp_ded_pucch_res_set.pucch_res_set_id = js_cur_ul_bwp_ded_pucch_res_set["PUCCH-ResourceSetId"]; + for (auto& js_cur_ul_bwp_ded_pucch_res_set_res_el : js_cur_ul_bwp_ded_pucch_res_set["resourceList"].items()) { + json js_cur_res_id = js_cur_ul_bwp_ded_pucch_res_set_res_el.value(); + cur_ul_bwp_ded_pucch_res_set.res_list.push_back(js_cur_res_id); + } + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().res_set_to_add_mod_list.push_back(cur_ul_bwp_ded_pucch_res_set); + } + + // printf("[9/21] trigger 3.41\n"); + + /* resourceToAddModList */ + for (auto& js_cur_ul_bwp_ded_pucch_res_el : js_cur_ul_bwp_ded_pucch["resourceToAddModList"].items()) { + json js_cur_ul_bwp_ded_pucch_res = js_cur_ul_bwp_ded_pucch_res_el.value(); + pucch_res_s cur_ul_bwp_ded_pucch_res; + + cur_ul_bwp_ded_pucch_res.pucch_res_id = js_cur_ul_bwp_ded_pucch_res["pucch-ResourceId"]; + cur_ul_bwp_ded_pucch_res.start_prb = js_cur_ul_bwp_ded_pucch_res["startingPRB"]; + + // Need to distinguish/infer format type + /* Format 0 */ + if (js_cur_ul_bwp_ded_pucch_res["format"].contains("initialCyclicShift")) { + cur_ul_bwp_ded_pucch_res.format.set_format0().init_cyclic_shift = js_cur_ul_bwp_ded_pucch_res["format"]["initialCyclicShift"]; + cur_ul_bwp_ded_pucch_res.format.set_format0().nrof_symbols = js_cur_ul_bwp_ded_pucch_res["format"]["nrofSymbols"]; + cur_ul_bwp_ded_pucch_res.format.set_format0().start_symbol_idx = js_cur_ul_bwp_ded_pucch_res["format"]["startingSymbolIndex"]; + } + + /* Format 2 */ + if (js_cur_ul_bwp_ded_pucch_res["format"].contains("nrofPRBs")) { + cur_ul_bwp_ded_pucch_res.format.set_format2().nrof_prbs = js_cur_ul_bwp_ded_pucch_res["format"]["nrofPRBs"]; + cur_ul_bwp_ded_pucch_res.format.set_format2().nrof_symbols = js_cur_ul_bwp_ded_pucch_res["format"]["nrofSymbols"]; + cur_ul_bwp_ded_pucch_res.format.set_format2().start_symbol_idx = js_cur_ul_bwp_ded_pucch_res["format"]["startingSymbolIndex"]; + } + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().res_to_add_mod_list.push_back(cur_ul_bwp_ded_pucch_res); + } + + // printf("[9/21] trigger 3.42\n"); + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().format2_present = js_cur_ul_bwp_ded_pucch.contains("format2"); + if (cur_ul_bwp.bwp_ded.pucch_cfg.setup().format2_present) { + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().format2.set_setup().max_code_rate = (asn1::rrc_nr::pucch_max_code_rate_e)js_cur_ul_bwp_ded_pucch["format2"]["maxCodeRate"]; + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().format2.set_setup().simul_harq_ack_csi_present = js_cur_ul_bwp_ded_pucch["format2"]["simultaneousHARQ-ACK-CSI"] == 0 ? true : false; + } + + // printf("[9/21] trigger 3.43\n"); + + /* schedulingRequestResourceToAddModList */ + for (auto& js_cur_ul_bwp_ded_pucch_sch_req_res_el : js_cur_ul_bwp_ded_pucch["schedulingRequestResourceToAddModList"].items()) { + json js_cur_ul_bwp_ded_pucch_sch_req_res = js_cur_ul_bwp_ded_pucch_sch_req_res_el.value(); + sched_request_res_cfg_s cur_ul_bwp_ded_pucch_sch_req_res; + cur_ul_bwp_ded_pucch_sch_req_res.sched_request_res_id = js_cur_ul_bwp_ded_pucch_sch_req_res["schedulingRequestResourceId"]; + cur_ul_bwp_ded_pucch_sch_req_res.sched_request_id = js_cur_ul_bwp_ded_pucch_sch_req_res["schedulingRequestID"]; + cur_ul_bwp_ded_pucch_sch_req_res.periodicity_and_offset_present = js_cur_ul_bwp_ded_pucch_sch_req_res.contains("periodicityAndOffset"); + if (cur_ul_bwp_ded_pucch_sch_req_res.periodicity_and_offset_present) { + // Hardcode for now + // TO-DO: fix this + cur_ul_bwp_ded_pucch_sch_req_res.periodicity_and_offset.set_sl80(); + } + cur_ul_bwp_ded_pucch_sch_req_res.res_present = js_cur_ul_bwp_ded_pucch_sch_req_res.contains("resource"); + if (cur_ul_bwp_ded_pucch_sch_req_res.res_present) { + cur_ul_bwp_ded_pucch_sch_req_res.res = js_cur_ul_bwp_ded_pucch_sch_req_res["resource"]; + } + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().sched_request_res_to_add_mod_list.push_back(cur_ul_bwp_ded_pucch_sch_req_res); + } + + // printf("[9/21] trigger 3.44\n"); + + /* multi-CSI-PUCCH-ResourceList */ + for (auto& js_cur_ul_bwp_ded_pucch_mul_csi_pucch_res_el : js_cur_ul_bwp_ded_pucch["multi-CSI-PUCCH-ResourceList"].items()) { + json js_cur_ul_bwp_ded_pucch_mul_csi_pucch_res = js_cur_ul_bwp_ded_pucch_mul_csi_pucch_res_el.value(); + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().multi_csi_pucch_res_list.push_back(js_cur_ul_bwp_ded_pucch_mul_csi_pucch_res); + } + + // printf("[9/21] trigger 3.45\n"); + + /* dl-DataToUL-ACK */ + for (auto& js_cur_ul_bwp_ded_pucch_dl_data_to_ul_ack_el : js_cur_ul_bwp_ded_pucch["dl-DataToUL-ACK"].items()) { + json js_cur_ul_bwp_ded_pucch_dl_data_to_ul_ack = js_cur_ul_bwp_ded_pucch_dl_data_to_ul_ack_el.value(); + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().dl_data_to_ul_ack.push_back(js_cur_ul_bwp_ded_pucch_dl_data_to_ul_ack); + } + + // printf("[9/21] trigger 3.46\n"); + + /* pucch-PowerControl */ + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().pucch_pwr_ctrl_present = js_cur_ul_bwp_ded_pucch.contains("pucch-PowerControl"); + if (cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl_present) { + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().pucch_pwr_ctrl.delta_f_pucch_f0_present = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"].contains("deltaF-PUCCH-f0"); + if (cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f0_present) { + cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f0 = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"]["deltaF-PUCCH-f0"]; + } + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().pucch_pwr_ctrl.delta_f_pucch_f1_present = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"].contains("deltaF-PUCCH-f1"); + if (cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f1_present) { + cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f1 = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"]["deltaF-PUCCH-f1"]; + } + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().pucch_pwr_ctrl.delta_f_pucch_f2_present = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"].contains("deltaF-PUCCH-f2"); + if (cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f2_present) { + cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f2 = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"]["deltaF-PUCCH-f2"]; + } + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().pucch_pwr_ctrl.delta_f_pucch_f3_present = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"].contains("deltaF-PUCCH-f3"); + if (cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f3_present) { + cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f3 = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"]["deltaF-PUCCH-f3"]; + } + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().pucch_pwr_ctrl.delta_f_pucch_f4_present = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"].contains("deltaF-PUCCH-f4"); + if (cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f4_present) { + cur_ul_bwp.bwp_ded.pucch_cfg.setup().pucch_pwr_ctrl.delta_f_pucch_f4 = js_cur_ul_bwp_ded_pucch["pucch-PowerControl"]["deltaF-PUCCH-f4"]; + } + + for (auto& js_cur_ul_bwp_ded_pucch_pc_p0_el : js_cur_ul_bwp_ded_pucch["pucch-PowerControl"]["p0-Set"].items()) { + json js_cur_ul_bwp_ded_pucch_pc_p0 = js_cur_ul_bwp_ded_pucch_pc_p0_el.value(); + + p0_pucch_s cur_ul_bwp_ded_pucch_pc_p0; + cur_ul_bwp_ded_pucch_pc_p0.p0_pucch_id = js_cur_ul_bwp_ded_pucch_pc_p0["p0-PUCCH-Id"]; + cur_ul_bwp_ded_pucch_pc_p0.p0_pucch_value = js_cur_ul_bwp_ded_pucch_pc_p0["p0-PUCCH-Value"]; + + cur_ul_bwp.bwp_ded.pucch_cfg.set_setup().pucch_pwr_ctrl.p0_set.push_back(cur_ul_bwp_ded_pucch_pc_p0); + } + + } + + // printf("[9/21] trigger 3.47\n"); + } + // printf("[9/21] trigger 3.5\n"); + + /* bwp-Dedicated -- pusch-Config */ + cur_ul_bwp.bwp_ded.pusch_cfg_present = js_cur_ul_bwp["bwp-Dedicated"].contains("pusch-Config"); + if (cur_ul_bwp.bwp_ded.pusch_cfg_present) { + json js_cur_ul_bwp_ded_pusch = js_cur_ul_bwp["bwp-Dedicated"]["pusch-Config"]; + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().data_scrambling_id_pusch_present = js_cur_ul_bwp_ded_pusch.contains("dataScramblingIdentityPUSCH"); + + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().data_scrambling_id_pusch_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().data_scrambling_id_pusch = js_cur_ul_bwp_ded_pusch["dataScramblingIdentityPUSCH"]; + } + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().tx_cfg_present = js_cur_ul_bwp_ded_pusch.contains("txConfig"); + + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().tx_cfg_present) { + if (js_cur_ul_bwp_ded_pusch["txConfig"].contains("codebook")) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().tx_cfg = asn1::rrc_nr::pusch_cfg_s::tx_cfg_e_::codebook; + } + + // For non_codebook and nulltype, will add here once encountered + } + + /* dmrs-UplinkForPUSCH-MappingTypeA */ + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().dmrs_ul_for_pusch_map_type_a_present = js_cur_ul_bwp_ded_pusch.contains("dmrs-UplinkForPUSCH-MappingTypeA"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().dmrs_ul_for_pusch_map_type_a_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().dmrs_ul_for_pusch_map_type_a.set_setup().dmrs_add_position_present = js_cur_ul_bwp_ded_pusch["dmrs-UplinkForPUSCH-MappingTypeA"].contains("dmrs-AdditionalPosition"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().dmrs_ul_for_pusch_map_type_a.setup().dmrs_add_position_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().dmrs_ul_for_pusch_map_type_a.set_setup().dmrs_add_position = + (asn1::rrc_nr::dmrs_ul_cfg_s::dmrs_add_position_e_)js_cur_ul_bwp_ded_pusch["dmrs-UplinkForPUSCH-MappingTypeA"]["dmrs-AdditionalPosition"]; + } + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().dmrs_ul_for_pusch_map_type_a.set_setup().transform_precoding_disabled_present = js_cur_ul_bwp_ded_pusch["dmrs-UplinkForPUSCH-MappingTypeA"].contains("transformPrecodingDisabled"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().dmrs_ul_for_pusch_map_type_a.setup().transform_precoding_disabled_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().dmrs_ul_for_pusch_map_type_a.set_setup().transform_precoding_disabled.scrambling_id0_present = + js_cur_ul_bwp_ded_pusch["dmrs-UplinkForPUSCH-MappingTypeA"]["transformPrecodingDisabled"].contains("scramblingID0"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().dmrs_ul_for_pusch_map_type_a.setup().transform_precoding_disabled.scrambling_id0_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().dmrs_ul_for_pusch_map_type_a.set_setup().transform_precoding_disabled.scrambling_id0 = + js_cur_ul_bwp_ded_pusch["dmrs-UplinkForPUSCH-MappingTypeA"]["transformPrecodingDisabled"]["scramblingID0"]; + } + } + } + + // printf("[9/21] trigger 3.51\n"); + + /* pusch-PowerControl */ + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().pusch_pwr_ctrl_present = js_cur_ul_bwp_ded_pusch.contains("pusch-PowerControl"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().pusch_pwr_ctrl_present) { + // printf("[9/21] trigger 3.510\n"); + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().pusch_pwr_ctrl.tpc_accumulation_present = js_cur_ul_bwp_ded_pusch["pusch-PowerControl"]["tpc-Accumulation"] == 1 ? true : false; + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().pusch_pwr_ctrl.msg3_alpha_present = js_cur_ul_bwp_ded_pusch["pusch-PowerControl"].contains("msg3-Alpha"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().pusch_pwr_ctrl.msg3_alpha_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().pusch_pwr_ctrl.msg3_alpha = (asn1::rrc_nr::alpha_e)js_cur_ul_bwp_ded_pusch["pusch-PowerControl"]["msg3-Alpha"]; + } + + // printf("[9/21] trigger 3.511\n"); + + for (auto& js_cur_ul_bwp_ded_pusch_pc_p0_el : js_cur_ul_bwp_ded_pusch["pusch-PowerControl"]["p0-AlphaSets"].items()) { + json js_cur_ul_bwp_ded_pusch_pc_p0 = js_cur_ul_bwp_ded_pusch_pc_p0_el.value(); + p0_pusch_alpha_set_s cur_ul_bwp_ded_pusch_pc_p0; + cur_ul_bwp_ded_pusch_pc_p0.p0_pusch_alpha_set_id = js_cur_ul_bwp_ded_pusch_pc_p0["p0-PUSCH-AlphaSetId"]; + cur_ul_bwp_ded_pusch_pc_p0.p0_present = js_cur_ul_bwp_ded_pusch_pc_p0.contains("p0"); + if (cur_ul_bwp_ded_pusch_pc_p0.p0_present) { + cur_ul_bwp_ded_pusch_pc_p0.p0 = js_cur_ul_bwp_ded_pusch_pc_p0["p0"]; + } + + // printf("[9/21] trigger 3.5111\n"); + + cur_ul_bwp_ded_pusch_pc_p0.alpha_present = js_cur_ul_bwp_ded_pusch_pc_p0.contains("alpha"); + if (cur_ul_bwp_ded_pusch_pc_p0.alpha_present) { + cur_ul_bwp_ded_pusch_pc_p0.alpha = (asn1::rrc_nr::alpha_e)js_cur_ul_bwp_ded_pusch_pc_p0["alpha"]; + } + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().pusch_pwr_ctrl.p0_alpha_sets.push_back(cur_ul_bwp_ded_pusch_pc_p0); + } + + // printf("[9/21] trigger 3.512\n"); + } + + // printf("[9/21] trigger 3.52\n"); + + /* resourceAllocation */ + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().res_alloc = (asn1::rrc_nr::pusch_cfg_s::res_alloc_e_)js_cur_ul_bwp_ded_pusch["resourceAllocation"]; + + /* pusch-TimeDomainAllocationList */ + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().pusch_time_domain_alloc_list_present = js_cur_ul_bwp_ded_pusch.contains("pusch-TimeDomainAllocationList"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().pusch_time_domain_alloc_list_present) { + + for (auto& js_cur_ul_bwp_ded_pusch_time_alloc_el : js_cur_ul_bwp_ded_pusch["pusch-TimeDomainAllocationList"].items()) { + json js_cur_ul_bwp_ded_pusch_time_alloc = js_cur_ul_bwp_ded_pusch_time_alloc_el.value()["PUSCH-TimeDomainResourceAllocation"]; + pusch_time_domain_res_alloc_s cur_ul_bwp_ded_pusch_time_alloc; + cur_ul_bwp_ded_pusch_time_alloc.k2_present = js_cur_ul_bwp_ded_pusch_time_alloc.contains("K2"); + if (cur_ul_bwp_ded_pusch_time_alloc.k2_present) { + cur_ul_bwp_ded_pusch_time_alloc.k2 = js_cur_ul_bwp_ded_pusch_time_alloc["k2"]; + } + + cur_ul_bwp_ded_pusch_time_alloc.map_type = (asn1::rrc_nr::pusch_time_domain_res_alloc_s::map_type_e_)js_cur_ul_bwp_ded_pusch_time_alloc["mappingType"]; + cur_ul_bwp_ded_pusch_time_alloc.start_symbol_and_len = js_cur_ul_bwp_ded_pusch_time_alloc["startSymbolAndLength"]; + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().pusch_time_domain_alloc_list.set_setup().push_back(cur_ul_bwp_ded_pusch_time_alloc); + } + } + + // printf("[9/21] trigger 3.53\n"); + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().mcs_table_present = js_cur_ul_bwp_ded_pusch.contains("mcs-Table"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().mcs_table_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().mcs_table = (asn1::rrc_nr::pusch_cfg_s::mcs_table_e_)js_cur_ul_bwp_ded_pusch["mcs-Table"]; + } + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().transform_precoder_present = js_cur_ul_bwp_ded_pusch.contains("transformPrecoder"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().transform_precoder_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().transform_precoder = (asn1::rrc_nr::pusch_cfg_s::transform_precoder_e_)js_cur_ul_bwp_ded_pusch["transformPrecoder"]; + } + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().codebook_subset_present = js_cur_ul_bwp_ded_pusch.contains("codebookSubset"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().codebook_subset_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().codebook_subset = (asn1::rrc_nr::pusch_cfg_s::codebook_subset_e_)js_cur_ul_bwp_ded_pusch["codebookSubset"]; + } + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().max_rank_present = js_cur_ul_bwp_ded_pusch.contains("maxRank"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().max_rank_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().max_rank = js_cur_ul_bwp_ded_pusch["maxRank"]; + } + + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().uci_on_pusch_present = js_cur_ul_bwp_ded_pusch.contains("uci-OnPUSCH"); + if (cur_ul_bwp.bwp_ded.pusch_cfg.setup().uci_on_pusch_present) { + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().uci_on_pusch.set_setup().beta_offsets_present = true; + cur_ul_bwp.bwp_ded.pusch_cfg.set_setup().uci_on_pusch.set_setup().scaling = (asn1::rrc_nr::uci_on_pusch_s::scaling_e_)js_cur_ul_bwp_ded_pusch["uci-OnPUSCH"]["scaling"]; + } + } + // printf("[9/21] trigger 3.6\n"); + + /* bwp-Dedicated -- srs-Config */ + cur_ul_bwp.bwp_ded.srs_cfg_present = js_cur_ul_bwp["bwp-Dedicated"].contains("srs-Config"); + if (cur_ul_bwp.bwp_ded.srs_cfg_present) { + json js_cur_ul_bwp_ded_srs = js_cur_ul_bwp["bwp-Dedicated"]["srs-Config"]; + + cur_ul_bwp.bwp_ded.srs_cfg.set_setup().srs_res_set_to_add_mod_list; + + /* srs-ResourceSetToAddModList */ + for (auto& js_cur_ul_bwp_ded_srs_res_set_el : js_cur_ul_bwp_ded_srs["srs-ResourceSetToAddModList"].items()) { + json js_cur_ul_bwp_ded_srs_res_set = js_cur_ul_bwp_ded_srs_res_set_el.value()["SRS-ResourceSet"]; + srs_res_set_s cur_ul_bwp_ded_srs_res_set; + cur_ul_bwp_ded_srs_res_set.srs_res_set_id = js_cur_ul_bwp_ded_srs_res_set["srs-ResourceSetId"]; + if (js_cur_ul_bwp_ded_srs_res_set["resourceType"].contains("aperiodicSRS-ResourceTrigger")) { + cur_ul_bwp_ded_srs_res_set.res_type.set_aperiodic().aperiodic_srs_res_trigger = + js_cur_ul_bwp_ded_srs_res_set["resourceType"]["aperiodicSRS-ResourceTrigger"]; + } + + for (auto& js_cur_ul_bwp_ded_srs_res_set_res_id_el : js_cur_ul_bwp_ded_srs_res_set["srs-ResourceIdList"].items()) { + json js_cur_ul_bwp_ded_srs_res_set_res_id = js_cur_ul_bwp_ded_srs_res_set_res_id_el.value(); + cur_ul_bwp_ded_srs_res_set.srs_res_id_list.push_back(js_cur_ul_bwp_ded_srs_res_set_res_id); + } + + cur_ul_bwp_ded_srs_res_set.usage = (asn1::rrc_nr::srs_res_set_s::usage_e_)js_cur_ul_bwp_ded_srs_res_set["usage"]; + + cur_ul_bwp_ded_srs_res_set.p0_present = js_cur_ul_bwp_ded_srs_res_set.contains("p0"); + if (cur_ul_bwp_ded_srs_res_set.p0_present) { + cur_ul_bwp_ded_srs_res_set.p0 = js_cur_ul_bwp_ded_srs_res_set["p0"]; + } + + cur_ul_bwp.bwp_ded.srs_cfg.set_setup().srs_res_set_to_add_mod_list.push_back(cur_ul_bwp_ded_srs_res_set); + } + + /* srs-ResourceToAddModList */ + for (auto& js_cur_ul_bwp_ded_srs_res_el : js_cur_ul_bwp_ded_srs["srs-ResourceToAddModList"].items()) { + json js_cur_ul_bwp_ded_srs_res = js_cur_ul_bwp_ded_srs_res_el.value()["SRS-Resource"]; + srs_res_s cur_ul_bwp_ded_srs_res; + cur_ul_bwp_ded_srs_res.srs_res_id = js_cur_ul_bwp_ded_srs_res["srs-ResourceId"]; + // Just add the id for now + + cur_ul_bwp.bwp_ded.srs_cfg.set_setup().srs_res_to_add_mod_list.push_back(cur_ul_bwp_ded_srs_res); + } + + } /* bwp-Dedicated -- srs-Config End */ + // printf("[9/21] trigger 3.7\n"); + + /* Done processing this new ul bwp; store... */ + ul_bwp_to_add_mod_list.push_back(cur_ul_bwp); + } /* uplinkBWP-ToAddModList End */ + } + + /** + * + * NON-INITIAL DL BWP(S) CONFIG EXTRACTION + * + */ // TO-DO: a lot of exists check needed before accessing fields - if (js_in["downlinkBWP-ToAddModList"].is_array()) { - printf("[9/16] trigger 1.1\n"); + if (js_in["spCellConfigDedicated"]["downlinkBWP-ToAddModList"].is_array()) { + // printf("[9/16] trigger 1.1\n"); auto& dl_bwp_to_add_mod_list = sp_cell_cfg.sp_cell_cfg_ded.dl_bwp_to_add_mod_list; - json js_dl_bwp_to_add_mod_list = js_in["downlinkBWP-ToAddModList"]; + json js_dl_bwp_to_add_mod_list = js_in["spCellConfigDedicated"]["downlinkBWP-ToAddModList"]; for (auto& js_cur_dl_bwp_el : js_dl_bwp_to_add_mod_list.items()) { - printf("[9/16] trigger 1.2\n"); + // printf("[9/16] trigger 1.2\n"); json js_cur_dl_bwp = js_cur_dl_bwp_el.value(); bwp_dl_s cur_dl_bwp; cur_dl_bwp.bwp_id = js_cur_dl_bwp["bwp-Id"]; @@ -48653,16 +49071,16 @@ SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { cur_dl_bwp.bwp_common.generic_params.location_and_bw = js_cur_dl_bwp_common_generic["locationAndBandwidth"]; assert(js_cur_dl_bwp_common_generic["subcarrierSpacing"].is_number()); cur_dl_bwp.bwp_common.generic_params.subcarrier_spacing = (asn1::rrc_nr::subcarrier_spacing_e)js_cur_dl_bwp_common_generic["subcarrierSpacing"]; - printf("[9/16] trigger 1.3\n"); + // printf("[9/16] trigger 1.3\n"); /* bwp-Common -- pdsch-ConfigCommon */ json js_cur_dl_bwp_common_pdsch_time_alloc_list = js_cur_dl_bwp["bwp-Common"]["pdsch-ConfigCommon"]["pdsch-TimeDomainAllocationList"]; assert(js_cur_dl_bwp_common_pdsch_time_alloc_list.is_array()); for (auto& js_cur_dl_bwp_common_pdsch_time_alloc_el : js_cur_dl_bwp_common_pdsch_time_alloc_list.items()) { - printf("[9/16] trigger 1.4\n"); + // printf("[9/16] trigger 1.4\n"); json js_cur_dl_bwp_common_pdsch_time_alloc = js_cur_dl_bwp_common_pdsch_time_alloc_el.value()["PDSCH-TimeDomainResourceAllocation"]; - printf("[9/16] trigger 1.41\n"); + // printf("[9/16] trigger 1.41\n"); pdsch_time_domain_res_alloc_s cur_pdsch_time_alloc; cur_pdsch_time_alloc.k0_present = js_cur_dl_bwp_common_pdsch_time_alloc.contains("k0"); @@ -48675,7 +49093,7 @@ SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { cur_dl_bwp.bwp_common.pdsch_cfg_common.set_setup().pdsch_time_domain_alloc_list.push_back(cur_pdsch_time_alloc); } - printf("[9/16] trigger 1.5\n"); + // printf("[9/16] trigger 1.5\n"); /* bwp-Dedicated */ cur_dl_bwp.bwp_ded_present = js_cur_dl_bwp.contains("bwp-Dedicated"); @@ -48685,7 +49103,7 @@ SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { /* bwp-Dedicated -- pdcch-Config -- controlResourceSetToAddModList */ json js_cur_dl_bwp_dedicated_pdcch_coreset_list = js_cur_dl_bwp_dedicated_pdcch["controlResourceSetToAddModList"]; - printf("[9/16] trigger 1.6\n"); + // printf("[9/16] trigger 1.6\n"); for (auto& js_cur_dl_bwp_dedicated_pdcch_coreset_el : js_cur_dl_bwp_dedicated_pdcch_coreset_list.items()) { json js_cur_dl_bwp_dedicated_pdcch_coreset = js_cur_dl_bwp_dedicated_pdcch_coreset_el.value(); ctrl_res_set_s cur_dl_bwp_dedicated_pdcch_coreset; @@ -48719,7 +49137,7 @@ SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { cur_dl_bwp.bwp_ded.pdcch_cfg.set_setup().ctrl_res_set_to_add_mod_list.push_back(cur_dl_bwp_dedicated_pdcch_coreset); } - printf("[9/16] trigger 1.7\n"); + // printf("[9/16] trigger 1.7\n"); /* bwp-Dedicated -- pdcch-Config -- searchSpacesToAddModList */ json js_cur_dl_bwp_dedicated_pdcch_searchspace_list = js_cur_dl_bwp_dedicated_pdcch["searchSpacesToAddModList"]; @@ -48765,7 +49183,7 @@ SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { cur_dl_bwp.bwp_ded.pdcch_cfg.set_setup().search_spaces_to_add_mod_list.push_back(cur_dl_bwp_dedicated_pdcch_searchspace); } - printf("[9/16] trigger 1.8\n"); + // printf("[9/16] trigger 1.8\n"); /* bwp-Dedicated -- pdsch-Config */ cur_dl_bwp.bwp_ded.pdsch_cfg_present = js_cur_dl_bwp["bwp-Dedicated"].contains("pdsch-Config"); @@ -48788,7 +49206,7 @@ SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { } } - printf("[9/16] trigger 1.9\n"); + // printf("[9/16] trigger 1.9\n"); cur_dl_bwp.bwp_ded.pdsch_cfg.set_setup().res_alloc = (asn1::rrc_nr::pdsch_cfg_s::res_alloc_e_)js_cur_dl_bwp_dedicated_pdsch["resourceAllocation"]; @@ -48822,7 +49240,7 @@ SRSASN_CODE cell_group_cfg_s::from_json(json js_in) { /* Done processing this new dl bwp; store... */ dl_bwp_to_add_mod_list.push_back(cur_dl_bwp); - printf("[9/16] trigger 1.10\n"); + // printf("[9/16] trigger 1.10\n"); } } diff --git a/nrscope/config/config.yaml b/nrscope/config/config.yaml index 6f4255b8..e6290214 100644 --- a/nrscope/config/config.yaml +++ b/nrscope/config/config.yaml @@ -1,7 +1,7 @@ nof_usrp_dev: 1 usrp_setting_0: ssb_freq: 3488160000 #1989850000 #1970450000 #3489600000 #3649440000 #3650880000 # 1970450000 #2600040000 #3488160000 #3685440000 #3561600000 #1842050000 #2528550000 #3565920000 #2524950000 #2523750000 # 3565920000 # 2527350000 #3408960000 # should be set to the ssb frequency of the cell - rf_args: "clock=external,type=x300,master_clock_rate=200000000,sampling_rate=25000000" #"type=x300" #"clock=external" for TwinRX + rf_args: "clock=external,serial=32B0F2F,type=x300,master_clock_rate=200000000,sampling_rate=25000000" #"type=x300" #"clock=external" for TwinRX # rf_args: "clock=external,type=x300,sampling_rate=23040000" #"type=x300" #"clock=external" for CBX rx_gain: 90 # for x310 CBX, max rx gain is 31.5, for b210, it's around 80, for x310 TwinRX, max rx gain is 90 srate_hz: 25000000 #11520000 #11520000 #23040000 (CBX) diff --git a/nrscope/hidden_bwp_db/369.txt b/nrscope/hidden_bwp_db/369.txt index 26d34377..ae9beb66 100644 --- a/nrscope/hidden_bwp_db/369.txt +++ b/nrscope/hidden_bwp_db/369.txt @@ -1,107 +1,558 @@ { - "downlinkBWP-ToAddModList": [ - { - "bwp-Id": 1, - "bwp-Common": { - "genericParameters": { - "locationAndBandwidth": 28875, - "subcarrierSpacing": 1 + "spCellConfigDedicated": { + "downlinkBWP-ToAddModList": [ + { + "bwp-Id": 1, + "bwp-Common": { + "genericParameters": { + "locationAndBandwidth": 28875, + "subcarrierSpacing": 1 + }, + "pdsch-ConfigCommon": { + "pdsch-TimeDomainAllocationList": [ + { + "PDSCH-TimeDomainResourceAllocation": { + "k0": 0, + "mappingType": 0, + "startSymbolAndLength": 40 + } + }, + { + "PDSCH-TimeDomainResourceAllocation": { + "k0": 0, + "mappingType": 0, + "startSymbolAndLength": 54 + } + }, + { + "PDSCH-TimeDomainResourceAllocation": { + "k0": 0, + "mappingType": 0, + "startSymbolAndLength": 57 + } + } + ] + } }, - "pdsch-ConfigCommon": { - "pdsch-TimeDomainAllocationList": [ - { - "PDSCH-TimeDomainResourceAllocation": { - "k0": 0, - "mappingType": 0, - "startSymbolAndLength": 40 + "bwp-Dedicated": { + "pdcch-Config": { + "controlResourceSetToAddModList": [ + { + "controlResourceSetId": 2, + "frequencyDomainResources": "FF FF 80 00 00 00", + "duration": 1, + "cce-REG-MappingType": "NULL", + "precoderGranularity": 1, + "tci-StatesPDCCH-ToAddList": [0], + "pdcch-DMRS-ScramblingID": 369 } - }, - { - "PDSCH-TimeDomainResourceAllocation": { - "k0": 0, - "mappingType": 0, - "startSymbolAndLength": 54 + ], + "searchSpacesToAddModList": [ + { + "searchSpaceId": 3, + "controlResourceSetId": 2, + "monitoringSlotPeriodicityAndOffset": "sl1 NULL", + "monitoringSymbolsWithinSlot": "80 00", + "nrofCandidates": { + "aggregationLevel1": 4, + "aggregationLevel2": 4, + "aggregationLevel4": 2, + "aggregationLevel8": 1, + "aggregationLevel16": 0 + }, + "searchSpaceType": { + "dci-Formats": 1 + } } + ] + }, + "pdsch-Config": { + "dataScramblingIdentityPDSCH": 369, + "dmrs-DownlinkForPDSCH-MappingTypeA": { + "dmrs-AdditionalPosition": 1 }, - { - "PDSCH-TimeDomainResourceAllocation": { - "k0": 0, - "mappingType": 0, - "startSymbolAndLength": 57 + "resourceAllocation": 1, + "pdsch-TimeDomainAllocationList": [ + { + "PDSCH-TimeDomainResourceAllocation": { + "k0": 0, + "mappingType": 0, + "startSymbolAndLength": 40 + } + }, + { + "PDSCH-TimeDomainResourceAllocation": { + "k0": 0, + "mappingType": 0, + "startSymbolAndLength": 54 + } + }, + { + "PDSCH-TimeDomainResourceAllocation": { + "k0": 0, + "mappingType": 0, + "startSymbolAndLength": 57 + } } + ], + "rbg-Size": 0, + "mcs-Table": 0, + "maxNrofCodeWordsScheduledByDCI": 0, + "prb-BundlingType": { + "bundleSize": 1 } - ] + } } - }, - "bwp-Dedicated": { - "pdcch-Config": { - "controlResourceSetToAddModList": [ - { - "controlResourceSetId": 2, - "frequencyDomainResources": "FF FF 80 00 00 00", - "duration": 1, - "cce-REG-MappingType": "NULL", - "precoderGranularity": 1, - "tci-StatesPDCCH-ToAddList": [0], - "pdcch-DMRS-ScramblingID": 369 - } - ], - "searchSpacesToAddModList": [ - { - "searchSpaceId": 3, - "controlResourceSetId": 2, - "monitoringSlotPeriodicityAndOffset": "sl1 NULL", - "monitoringSymbolsWithinSlot": "80 00", - "nrofCandidates": { - "aggregationLevel1": 4, - "aggregationLevel2": 4, - "aggregationLevel4": 2, - "aggregationLevel8": 1, - "aggregationLevel16": 0 + } + ], + + "uplinkConfig": { + "uplinkBWP-ToAddModList": [ + { + "bwp-Id": 1, + "bwp-Common": { + "genericParameters": { + "locationAndBandwidth": 28875, + "subcarrierSpacing": 1 + }, + "rach-ConfigCommon": { + "rach-ConfigGeneric": { + "prach-ConfigurationIndex": 154, + "msg1-FDM": 0, + "msg1-FrequencyStart": 0, + "zeroCorrelationZoneConfig": 12, + "preambleReceivedTargetPower": -104, + "preambleTransMax": 6, + "powerRampingStep": 1, + "ra-ResponseWindow": 7 }, - "searchSpaceType": { - "dci-Formats": 1 - } + "ssb-perRACH-OccasionAndCB-PreamblesPerSSB": 0, + "groupBconfigured": { + "ra-Msg3SizeGroupA": 0, + "messagePowerOffsetGroupB": 1, + "numberOfRA-PreamblesGroupA": 1 + }, + "ra-ContentionResolutionTimer": 4, + "rsrp-ThresholdSSB": 0, + "prach-RootSequenceIndex": 0, + "msg1-SubcarrierSpacing": 1, + "restrictedSetConfig": 0 + }, + "pusch-ConfigCommon": { + "pusch-TimeDomainAllocationList": [ + {"PUSCH-TimeDomainResourceAllocation": { "k2": 5, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 6, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 7, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 8, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 9, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 10, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 11, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 12, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 13, "mappingType": 0, "startSymbolAndLength": 55 }}, + {"PUSCH-TimeDomainResourceAllocation": { "k2": 14, "mappingType": 0, "startSymbolAndLength": 55 }} + ], + "msg3-DeltaPreamble": 0, + "p0-NominalWithGrant": -76 + }, + "pucch-ConfigCommon": { + "pucch-ResourceCommon": 3, + "pucch-GroupHopping": 0, + "p0-nominal": -80 } - ] - }, - "pdsch-Config": { - "dataScramblingIdentityPDSCH": 369, - "dmrs-DownlinkForPDSCH-MappingTypeA": { - "dmrs-AdditionalPosition": 1 }, - "resourceAllocation": 1, - "pdsch-TimeDomainAllocationList": [ - { - "PDSCH-TimeDomainResourceAllocation": { - "k0": 0, - "mappingType": 0, - "startSymbolAndLength": 40 + "bwp-Dedicated": { + "pucch-Config": { + "resourceSetToAddModList": [ + { + "PUCCH-ResourceSetId": 0, + "resourceList": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13] + }, + { + "PUCCH-ResourceSetId": 1, + "resourceList": [15, 16, 17, 18, 19, 20, 21, 22] + } + ], + "resourceToAddModList": [ + { + "pucch-ResourceId": 0, + "startingPRB": 16, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 1, + "startingPRB": 16, + "format": { + "initialCyclicShift": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 2, + "startingPRB": 16, + "format": { + "initialCyclicShift": 2, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 3, + "startingPRB": 16, + "format": { + "initialCyclicShift": 3, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 4, + "startingPRB": 16, + "format": { + "initialCyclicShift": 4, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 5, + "startingPRB": 16, + "format": { + "initialCyclicShift": 5, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 6, + "startingPRB": 17, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 7, + "startingPRB": 17, + "format": { + "initialCyclicShift": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 8, + "startingPRB": 17, + "format": { + "initialCyclicShift": 2, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 9, + "startingPRB": 17, + "format": { + "initialCyclicShift": 3, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 10, + "startingPRB": 17, + "format": { + "initialCyclicShift": 4, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 11, + "startingPRB": 17, + "format": { + "initialCyclicShift": 5, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 12, + "startingPRB": 18, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 13, + "startingPRB": 18, + "format": { + "initialCyclicShift": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 14, + "startingPRB": 12, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 15, + "startingPRB": 19, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 16, + "startingPRB": 20, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 17, + "startingPRB": 21, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 18, + "startingPRB": 22, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 19, + "startingPRB": 23, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 20, + "startingPRB": 24, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 21, + "startingPRB": 25, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 22, + "startingPRB": 26, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + } + ], + "format2": { + "maxCodeRate": 6, + "simultaneousHARQ-ACK-CSI": 0 + }, + "schedulingRequestResourceToAddModList": [ + { "schedulingRequestResourceId": 1, "schedulingRequestID": 0, "periodicityAndOffset": 5, "resource": 14 } + ], + "multi-CSI-PUCCH-ResourceList": [22], + "dl-DataToUL-ACK": [4, 5, 6, 7, 8, 9, 10, 11], + "pucch-PowerControl": { + "deltaF-PUCCH-f0": 0, + "deltaF-PUCCH-f1": 0, + "deltaF-PUCCH-f2": 0, + "deltaF-PUCCH-f3": 0, + "deltaF-PUCCH-f4": 0, + "p0-Set": [ + { + "p0-PUCCH-Id": 1, + "p0-PUCCH-Value": 0 + } + ] } }, - { - "PDSCH-TimeDomainResourceAllocation": { - "k0": 0, - "mappingType": 0, - "startSymbolAndLength": 54 + "pusch-Config": { + "dataScramblingIdentityPUSCH": 369, + "txConfig": { + "codebook": 0 + }, + "dmrs-UplinkForPUSCH-MappingTypeA": { + "dmrs-AdditionalPosition": 1, + "transformPrecodingDisabled": { + "scramblingID0": 369 + } + }, + "pusch-PowerControl": { + "tpc-Accumulation": 0, + "msg3-Alpha": 7, + "p0-AlphaSets": [ + { + "p0-PUSCH-AlphaSetId": 0, + "p0": 0, + "alpha": 7 + } + ], + "deltaMCS": 0 + }, + "resourceAllocation": 1, + "pusch-TimeDomainAllocationList": [ + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 4, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 5, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 6, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 7, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 8, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 9, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 10, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 11, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 12, + "mappingType": 0, + "startSymbolAndLength": 55 + } + } + ], + "mcs-Table": 0, + "transformPrecoder": 1, + "codebookSubset": 2, + "maxRank": 1, + "uci-OnPUSCH": { + "betaOffsets": { + "betaOffsetACK-Index1": 0, + "betaOffsetACK-Index2": 0, + "betaOffsetACK-Index3": 0 + }, + "scaling": 0 } }, - { - "PDSCH-TimeDomainResourceAllocation": { - "k0": 0, - "mappingType": 0, - "startSymbolAndLength": 57 - } + "srs-Config": { + "srs-ResourceSetToAddModList": [ + { + "SRS-ResourceSet": { + "srs-ResourceSetId": 0, + "srs-ResourceIdList": [0], + "resourceType": { + "aperiodicSRS-ResourceTrigger": 1 + }, + "usage": 1, + "p0": 0 + } + } + ], + "srs-ResourceToAddModList": [ + { + "SRS-Resource": { + "srs-ResourceId": 0, + "nrofSRS-Ports": 0, + "transmissionComb": { + "combOffset-n2": 0, + "cyclicShift-n2": 0 + }, + "resourceMapping": { + "startPosition": 0, + "nrofSymbols": 0, + "repetitionFactor": 0 + }, + "freqDomainPosition": 0, + "freqDomainShift": 0, + "freqHopping": { + "c-SRS": 25, + "b-SRS": 0, + "b-hop": 0 + }, + "groupOrSequenceHopping": 0, + "resourceType": { + "sequenceId": 0 + } + } + } + ], + "tpc-Accumulation": 0 } - ], - "rbg-Size": 0, - "mcs-Table": 0, - "maxNrofCodeWordsScheduledByDCI": 0, - "prb-BundlingType": { - "bundleSize": 1 } } - } + ] } - ] + } } \ No newline at end of file diff --git a/nrscope/hidden_bwp_db/369_ul.txt b/nrscope/hidden_bwp_db/369_ul.txt new file mode 100644 index 00000000..c4aab2bc --- /dev/null +++ b/nrscope/hidden_bwp_db/369_ul.txt @@ -0,0 +1,446 @@ +{ + "uplinkBWP-ToAddModList": { + "BWP-Uplink": { + "bwp-Id": 1, + "bwp-Common": { + "genericParameters": { + "locationAndBandwidth": 28875, + "subcarrierSpacing": 1 + }, + "rach-ConfigCommon": { + "rach-ConfigGeneric": { + "prach-ConfigurationIndex": 154, + "msg1-FDM": 0, + "msg1-FrequencyStart": 0, + "zeroCorrelationZoneConfig": 12, + "preambleReceivedTargetPower": -104, + "preambleTransMax": 6, + "powerRampingStep": 1, + "ra-ResponseWindow": 7 + }, + "ssb-perRACH-OccasionAndCB-PreamblesPerSSB": 0, + "groupBconfigured": { + "ra-Msg3SizeGroupA": 0, + "messagePowerOffsetGroupB": 1, + "numberOfRA-PreamblesGroupA": 1 + }, + "ra-ContentionResolutionTimer": 4, + "rsrp-ThresholdSSB": 0, + "prach-RootSequenceIndex": 0, + "msg1-SubcarrierSpacing": 1, + "restrictedSetConfig": 0 + }, + "pusch-ConfigCommon": { + "pusch-TimeDomainAllocationList": [ + { "k2": 5, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 6, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 7, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 8, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 9, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 10, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 11, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 12, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 13, "mappingType": 0, "startSymbolAndLength": 55 }, + { "k2": 14, "mappingType": 0, "startSymbolAndLength": 55 } + ], + "msg3-DeltaPreamble": 0, + "p0-NominalWithGrant": -76 + }, + "pucch-ConfigCommon": { + "pucch-ResourceCommon": 3, + "pucch-GroupHopping": 0, + "p0-nominal": -80 + } + }, + "bwp-Dedicated": { + "pucch-Config": { + "resourceSetToAddModList": [ + { + "PUCCH-ResourceSetId": 0, + "resourceList": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13] + }, + { + "PUCCH-ResourceSetId": 1, + "resourceList": [15, 16, 17, 18, 19, 20, 21, 22] + } + ], + "resourceToAddModList": [ + { + "pucch-ResourceId": 0, + "startingPRB": 16, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 1, + "startingPRB": 16, + "format": { + "initialCyclicShift": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 2, + "startingPRB": 16, + "format": { + "initialCyclicShift": 2, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 3, + "startingPRB": 16, + "format": { + "initialCyclicShift": 3, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 4, + "startingPRB": 16, + "format": { + "initialCyclicShift": 4, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 5, + "startingPRB": 16, + "format": { + "initialCyclicShift": 5, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 6, + "startingPRB": 17, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 7, + "startingPRB": 17, + "format": { + "initialCyclicShift": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 8, + "startingPRB": 17, + "format": { + "initialCyclicShift": 2, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 9, + "startingPRB": 17, + "format": { + "initialCyclicShift": 3, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 10, + "startingPRB": 17, + "format": { + "initialCyclicShift": 4, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 11, + "startingPRB": 17, + "format": { + "initialCyclicShift": 5, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 12, + "startingPRB": 18, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 13, + "startingPRB": 18, + "format": { + "initialCyclicShift": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 14, + "startingPRB": 12, + "format": { + "initialCyclicShift": 0, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 15, + "startingPRB": 19, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 16, + "startingPRB": 20, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 17, + "startingPRB": 21, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 18, + "startingPRB": 22, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 19, + "startingPRB": 23, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 20, + "startingPRB": 24, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 21, + "startingPRB": 25, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + }, + { + "pucch-ResourceId": 22, + "startingPRB": 26, + "format": { + "nrofPRBs": 1, + "nrofSymbols": 1, + "startingSymbolIndex": 12 + } + } + ], + "maxCodeRate": 6, + "simultaneousHARQ-ACK-CSI": 0, + "schedulingRequestResourceToAddModList": [ + { "schedulingRequestResourceId": 1, "schedulingRequestID": 0, "periodicityAndOffset": 5, "resource": 14 } + ], + "resource": [22], + "dl-DataToUL-ACK": [4, 5, 6, 7, 8, 9, 10, 11], + "pucch-PowerControl": { + "deltaF-PUCCH-f0": 0, + "deltaF-PUCCH-f1": 0, + "deltaF-PUCCH-f2": 0, + "deltaF-PUCCH-f3": 0, + "deltaF-PUCCH-f4": 0, + "p0-Set": { + "P0-PUCCH": { + "p0-PUCCH-Id": 1, + "p0-PUCCH-Value": 0 + } + } + } + }, + "pusch-Config": { + "dataScramblingIdentityPUSCH": 369, + "txConfig": { + "codebook": 0 + }, + "dmrs-UplinkForPUSCH-MappingTypeA": { + "dmrs-AdditionalPosition": 1, + "transformPrecodingDisabled": { + "scramblingID0": 369 + } + }, + "pusch-PowerControl": { + "tpc-Accumulation": 0, + "msg3-Alpha": 7, + "p0-AlphaSets": { + "P0-PUSCH-AlphaSet": { + "p0-PUSCH-AlphaSetId": 0, + "p0": 0, + "alpha": 7 + } + }, + "deltaMCS": 0 + }, + "resourceAllocation": 1, + "pusch-TimeDomainAllocationList": [ + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 4, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 5, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 6, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 7, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 8, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 9, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 10, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 11, + "mappingType": 0, + "startSymbolAndLength": 55 + } + }, + { + "PUSCH-TimeDomainResourceAllocation": { + "k2": 12, + "mappingType": 0, + "startSymbolAndLength": 55 + } + } + ], + "mcs-Table": 0, + "transformPrecoder": 1, + "codebookSubset": 2, + "maxRank": 1, + "uci-OnPUSCH": { + "betaOffsets": { + "betaOffsetACK-Index1": 0, + "betaOffsetACK-Index2": 0, + "betaOffsetACK-Index3": 0 + }, + "scaling": 0 + } + }, + "srs-Config": { + "srs-ResourceSetToAddModList": [ + { + "SRS-ResourceSet": { + "srs-ResourceSetId": 0, + "srs-ResourceIdList": [0], + "resourceType": { + "aperiodicSRS-ResourceTrigger": 1 + }, + "usage": 1, + "p0": 0 + } + } + ], + "srs-ResourceToAddModList": [ + { + "SRS-Resource": { + "srs-ResourceId": 0, + "nrofSRS-Ports": 0, + "transmissionComb": { + "combOffset-n2": 0, + "cyclicShift-n2": 0 + }, + "resourceMapping": { + "startPosition": 0, + "nrofSymbols": 0, + "repetitionFactor": 0 + }, + "freqDomainPosition": 0, + "freqDomainShift": 0, + "freqHopping": { + "c-SRS": 25, + "b-SRS": 0, + "b-hop": 0 + }, + "groupOrSequenceHopping": 0, + "resourceType": { + "sequenceId": 0 + } + } + } + ], + "tpc-Accumulation": 0 + } + } + } + } +}