diff --git a/lib/include/srslte/asn1/rrc_nr.h b/lib/include/srslte/asn1/rrc_nr.h index 9fe07451e..b71ea9f06 100644 --- a/lib/include/srslte/asn1/rrc_nr.h +++ b/lib/include/srslte/asn1/rrc_nr.h @@ -12,7 +12,7 @@ /******************************************************************************* * - * 3GPP TS ASN1 RRC NR v15.5.0 (2019-03) + * 3GPP TS ASN1 RRC NR v15.11.0 (2020-10) * ******************************************************************************/ @@ -143,7 +143,6 @@ namespace rrc_nr { #define ASN1_RRC_NR_MAX_DRB 29 #define ASN1_RRC_NR_MAX_FREQ 8 #define ASN1_RRC_NR_MAX_FREQ_IDC_MRDC 32 -#define ASN1_RRC_NR_MAX_NROF_CSI_RS 64 #define ASN1_RRC_NR_MAX_NROF_CANDIDATE_BEAMS 16 #define ASN1_RRC_NR_MAX_NROF_PCIS_PER_SMTC 64 #define ASN1_RRC_NR_MAX_NROF_QFIS 64 @@ -153,7 +152,6 @@ namespace rrc_nr { #define ASN1_RRC_NR_MAX_NROF_SPATIAL_RELATION_INFOS 8 #define ASN1_RRC_NR_MAX_NROF_IDXES_TO_REPORT 32 #define ASN1_RRC_NR_MAX_NROF_IDXES_TO_REPORT2 64 -#define ASN1_RRC_NR_MAX_NROF_SSBS 64 #define ASN1_RRC_NR_MAX_NROF_SSBS_MINUS1 63 #define ASN1_RRC_NR_MAX_NROF_S_NSSAI 8 #define ASN1_RRC_NR_MAX_NROF_TCI_STATES_PDCCH 64 @@ -434,7 +432,7 @@ struct eutra_freq_neigh_cell_info_s { bool q_rx_lev_min_offset_cell_present = false; bool q_qual_min_offset_cell_present = false; uint16_t pci = 0; - eutra_q_offset_range_e q_offset_cell; + eutra_q_offset_range_e dummy; uint8_t q_rx_lev_min_offset_cell = 1; uint8_t q_qual_min_offset_cell = 1; @@ -2371,8 +2369,8 @@ struct scs_specific_carrier_s { uint16_t carrier_bw = 1; // ... // group 0 - bool tx_direct_current_location_v1530_present = false; - uint16_t tx_direct_current_location_v1530 = 0; + bool tx_direct_current_location_present = false; + uint16_t tx_direct_current_location = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -3999,7 +3997,7 @@ struct sib1_s { struct sys_info_s { struct crit_exts_c_ { struct types_opts { - enum options { sys_info_r15, crit_exts_future, nulltype } value; + enum options { sys_info, crit_exts_future, nulltype } value; std::string to_string() const; }; @@ -4016,19 +4014,19 @@ struct sys_info_s { SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - sys_info_ies_s& sys_info_r15() + sys_info_ies_s& sys_info() { - assert_choice_type("systemInformation-r15", type_.to_string(), "criticalExtensions"); + assert_choice_type("systemInformation", type_.to_string(), "criticalExtensions"); return c.get(); } - const sys_info_ies_s& sys_info_r15() const + const sys_info_ies_s& sys_info() const { - assert_choice_type("systemInformation-r15", type_.to_string(), "criticalExtensions"); + assert_choice_type("systemInformation", type_.to_string(), "criticalExtensions"); return c.get(); } - sys_info_ies_s& set_sys_info_r15() + sys_info_ies_s& set_sys_info() { - set(types::sys_info_r15); + set(types::sys_info); return c.get(); } @@ -4161,167 +4159,315 @@ struct bcch_dl_sch_msg_s { void to_json(json_writer& j) const; }; -// Alpha ::= ENUMERATED -struct alpha_opts { - enum options { alpha0, alpha04, alpha05, alpha06, alpha07, alpha08, alpha09, alpha1, nulltype } value; - typedef float number_type; +// UL-DataSplitThreshold ::= ENUMERATED +struct ul_data_split_thres_opts { + enum options { + b0, + b100, + b200, + b400, + b800, + b1600, + b3200, + b6400, + b12800, + b25600, + b51200, + b102400, + b204800, + b409600, + b819200, + b1228800, + b1638400, + b2457600, + b3276800, + b4096000, + b4915200, + b5734400, + b6553600, + infinity, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef int32_t number_type; std::string to_string() const; - float to_number() const; - std::string to_number_string() const; -}; -typedef enumerated alpha_e; - -// BFR-CSIRS-Resource ::= SEQUENCE -struct bfr_csirs_res_s { - using ra_occasion_list_l_ = dyn_array; - - // member variables - bool ext = false; - bool ra_occasion_list_present = false; - bool ra_preamb_idx_present = false; - uint8_t csi_rs = 0; - ra_occasion_list_l_ ra_occasion_list; - uint8_t ra_preamb_idx = 0; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BFR-SSB-Resource ::= SEQUENCE -struct bfr_ssb_res_s { - bool ext = false; - uint8_t ssb = 0; - uint8_t ra_preamb_idx = 0; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BetaOffsets ::= SEQUENCE -struct beta_offsets_s { - bool beta_offset_ack_idx1_present = false; - bool beta_offset_ack_idx2_present = false; - bool beta_offset_ack_idx3_present = false; - bool beta_offset_csi_part1_idx1_present = false; - bool beta_offset_csi_part1_idx2_present = false; - bool beta_offset_csi_part2_idx1_present = false; - bool beta_offset_csi_part2_idx2_present = false; - uint8_t beta_offset_ack_idx1 = 0; - uint8_t beta_offset_ack_idx2 = 0; - uint8_t beta_offset_ack_idx3 = 0; - uint8_t beta_offset_csi_part1_idx1 = 0; - uint8_t beta_offset_csi_part1_idx2 = 0; - uint8_t beta_offset_csi_part2_idx1 = 0; - uint8_t beta_offset_csi_part2_idx2 = 0; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + int32_t to_number() const; }; +typedef enumerated ul_data_split_thres_e; -// CSI-FrequencyOccupation ::= SEQUENCE -struct csi_freq_occupation_s { - bool ext = false; - uint16_t start_rb = 0; - uint16_t nrof_rbs = 24; - // ... +// CipheringAlgorithm ::= ENUMERATED +struct ciphering_algorithm_opts { + enum options { nea0, nea1, nea2, nea3, spare4, spare3, spare2, spare1, /*...*/ nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + std::string to_string() const; + uint8_t to_number() const; }; +typedef enumerated ciphering_algorithm_e; -// P0-PUCCH ::= SEQUENCE -struct p0_pucch_s { - uint8_t p0_pucch_id = 1; - int8_t p0_pucch_value = -16; +// IntegrityProtAlgorithm ::= ENUMERATED +struct integrity_prot_algorithm_opts { + enum options { nia0, nia1, nia2, nia3, spare4, spare3, spare2, spare1, /*...*/ nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + std::string to_string() const; + uint8_t to_number() const; }; +typedef enumerated integrity_prot_algorithm_e; -// P0-PUSCH-AlphaSet ::= SEQUENCE -struct p0_pusch_alpha_set_s { - bool p0_present = false; - bool alpha_present = false; - uint8_t p0_pusch_alpha_set_id = 0; - int8_t p0 = -16; - alpha_e alpha; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; +// PDCP-Config ::= SEQUENCE +struct pdcp_cfg_s { + struct drb_s_ { + struct discard_timer_opts { + enum options { + ms10, + ms20, + ms30, + ms40, + ms50, + ms60, + ms75, + ms100, + ms150, + ms200, + ms250, + ms300, + ms500, + ms750, + ms1500, + infinity, + nulltype + } value; + typedef int16_t number_type; -// PTRS-UplinkConfig ::= SEQUENCE -struct ptrs_ul_cfg_s { - struct transform_precoder_disabled_s_ { - using freq_density_l_ = std::array; - using time_density_l_ = std::array; - struct max_nrof_ports_opts { - enum options { n1, n2, nulltype } value; + std::string to_string() const; + int16_t to_number() const; + }; + typedef enumerated discard_timer_e_; + struct pdcp_sn_size_ul_opts { + enum options { len12bits, len18bits, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated max_nrof_ports_e_; - struct res_elem_offset_opts { - enum options { offset01, offset10, offset11, nulltype } value; - typedef float number_type; + typedef enumerated pdcp_sn_size_ul_e_; + struct pdcp_sn_size_dl_opts { + enum options { len12bits, len18bits, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; - float to_number() const; - std::string to_number_string() const; + uint8_t to_number() const; }; - typedef enumerated res_elem_offset_e_; - struct ptrs_pwr_opts { - enum options { p00, p01, p10, p11, nulltype } value; - typedef float number_type; + typedef enumerated pdcp_sn_size_dl_e_; + struct hdr_compress_c_ { + struct rohc_s_ { + struct profiles_s_ { + bool profile0x0001 = false; + bool profile0x0002 = false; + bool profile0x0003 = false; + bool profile0x0004 = false; + bool profile0x0006 = false; + bool profile0x0101 = false; + bool profile0x0102 = false; + bool profile0x0103 = false; + bool profile0x0104 = false; + }; - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated ptrs_pwr_e_; + // member variables + bool max_cid_present = false; + bool drb_continue_rohc_present = false; + uint16_t max_cid = 1; + profiles_s_ profiles; + }; + struct ul_only_rohc_s_ { + struct profiles_s_ { + bool profile0x0006 = false; + }; - // member variables - bool freq_density_present = false; - bool time_density_present = false; - bool res_elem_offset_present = false; - freq_density_l_ freq_density; - time_density_l_ time_density; - max_nrof_ports_e_ max_nrof_ports; - res_elem_offset_e_ res_elem_offset; - ptrs_pwr_e_ ptrs_pwr; - }; - struct transform_precoder_enabled_s_ { - using sample_density_l_ = std::array; + // member variables + bool max_cid_present = false; + bool drb_continue_rohc_present = false; + uint16_t max_cid = 1; + profiles_s_ profiles; + }; + struct types_opts { + enum options { not_used, rohc, ul_only_rohc, /*...*/ nulltype } value; - // member variables - bool time_density_transform_precoding_present = false; - sample_density_l_ sample_density; - }; + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + hdr_compress_c_() = default; + hdr_compress_c_(const hdr_compress_c_& other); + hdr_compress_c_& operator=(const hdr_compress_c_& other); + ~hdr_compress_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rohc_s_& rohc() + { + assert_choice_type("rohc", type_.to_string(), "headerCompression"); + return c.get(); + } + ul_only_rohc_s_& ul_only_rohc() + { + assert_choice_type("uplinkOnlyROHC", type_.to_string(), "headerCompression"); + return c.get(); + } + const rohc_s_& rohc() const + { + assert_choice_type("rohc", type_.to_string(), "headerCompression"); + return c.get(); + } + const ul_only_rohc_s_& ul_only_rohc() const + { + assert_choice_type("uplinkOnlyROHC", type_.to_string(), "headerCompression"); + return c.get(); + } + rohc_s_& set_rohc() + { + set(types::rohc); + return c.get(); + } + ul_only_rohc_s_& set_ul_only_rohc() + { + set(types::ul_only_rohc); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + bool discard_timer_present = false; + bool pdcp_sn_size_ul_present = false; + bool pdcp_sn_size_dl_present = false; + bool integrity_protection_present = false; + bool status_report_required_present = false; + bool out_of_order_delivery_present = false; + discard_timer_e_ discard_timer; + pdcp_sn_size_ul_e_ pdcp_sn_size_ul; + pdcp_sn_size_dl_e_ pdcp_sn_size_dl; + hdr_compress_c_ hdr_compress; + }; + struct more_than_one_rlc_s_ { + struct primary_path_s_ { + bool cell_group_present = false; + bool lc_ch_present = false; + uint8_t cell_group = 0; + uint8_t lc_ch = 1; + }; + + // member variables + bool ul_data_split_thres_present = false; + bool pdcp_dupl_present = false; + primary_path_s_ primary_path; + ul_data_split_thres_e ul_data_split_thres; + bool pdcp_dupl = false; + }; + struct t_reordering_opts { + enum options { + ms0, + ms1, + ms2, + ms4, + ms5, + ms8, + ms10, + ms15, + ms20, + ms30, + ms40, + ms50, + ms60, + ms80, + ms100, + ms120, + ms140, + ms160, + ms180, + ms200, + ms220, + ms240, + ms260, + ms280, + ms300, + ms500, + ms750, + ms1000, + ms1250, + ms1500, + ms1750, + ms2000, + ms2250, + ms2500, + ms2750, + ms3000, + spare28, + spare27, + spare26, + spare25, + spare24, + spare23, + spare22, + spare21, + spare20, + spare19, + spare18, + spare17, + spare16, + spare15, + spare14, + spare13, + spare12, + spare11, + spare10, + spare09, + spare08, + spare07, + spare06, + spare05, + spare04, + spare03, + spare02, + spare01, + nulltype + } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated t_reordering_e_; // member variables - bool ext = false; - bool transform_precoder_disabled_present = false; - bool transform_precoder_enabled_present = false; - transform_precoder_disabled_s_ transform_precoder_disabled; - transform_precoder_enabled_s_ transform_precoder_enabled; + bool ext = false; + bool drb_present = false; + bool more_than_one_rlc_present = false; + bool t_reordering_present = false; + drb_s_ drb; + more_than_one_rlc_s_ more_than_one_rlc; + t_reordering_e_ t_reordering; // ... + // group 0 + bool ciphering_disabled_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4329,79 +4475,110 @@ struct ptrs_ul_cfg_s { void to_json(json_writer& j) const; }; -// PUCCH-MaxCodeRate ::= ENUMERATED -struct pucch_max_code_rate_opts { - enum options { zero_dot08, zero_dot15, zero_dot25, zero_dot35, zero_dot45, zero_dot60, zero_dot80, nulltype } value; - typedef float number_type; +// SDAP-Config ::= SEQUENCE +struct sdap_cfg_s { + struct sdap_hdr_dl_opts { + enum options { present, absent, nulltype } value; - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; + std::string to_string() const; + }; + typedef enumerated sdap_hdr_dl_e_; + struct sdap_hdr_ul_opts { + enum options { present, absent, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated sdap_hdr_ul_e_; + using mapped_qos_flows_to_add_l_ = dyn_array; + using mapped_qos_flows_to_release_l_ = dyn_array; + + // member variables + bool ext = false; + bool mapped_qos_flows_to_add_present = false; + bool mapped_qos_flows_to_release_present = false; + uint16_t pdu_session = 0; + sdap_hdr_dl_e_ sdap_hdr_dl; + sdap_hdr_ul_e_ sdap_hdr_ul; + bool default_drb = false; + mapped_qos_flows_to_add_l_ mapped_qos_flows_to_add; + mapped_qos_flows_to_release_l_ mapped_qos_flows_to_release; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated pucch_max_code_rate_e; -// PUCCH-PathlossReferenceRS ::= SEQUENCE -struct pucch_pathloss_ref_rs_s { - struct ref_sig_c_ { +// DRB-ToAddMod ::= SEQUENCE +struct drb_to_add_mod_s { + struct cn_assoc_c_ { struct types_opts { - enum options { ssb_idx, csi_rs_idx, nulltype } value; + enum options { eps_bearer_id, sdap_cfg, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - ref_sig_c_() = default; - ref_sig_c_(const ref_sig_c_& other); - ref_sig_c_& operator=(const ref_sig_c_& other); - ~ref_sig_c_() { destroy_(); } + cn_assoc_c_() = default; + cn_assoc_c_(const cn_assoc_c_& other); + cn_assoc_c_& operator=(const cn_assoc_c_& other); + ~cn_assoc_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& ssb_idx() + uint8_t& eps_bearer_id() { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + assert_choice_type("eps-BearerIdentity", type_.to_string(), "cnAssociation"); return c.get(); } - uint8_t& csi_rs_idx() + sdap_cfg_s& sdap_cfg() { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("sdap-Config", type_.to_string(), "cnAssociation"); + return c.get(); } - const uint8_t& ssb_idx() const + const uint8_t& eps_bearer_id() const { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + assert_choice_type("eps-BearerIdentity", type_.to_string(), "cnAssociation"); return c.get(); } - const uint8_t& csi_rs_idx() const + const sdap_cfg_s& sdap_cfg() const { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("sdap-Config", type_.to_string(), "cnAssociation"); + return c.get(); } - uint8_t& set_ssb_idx() + uint8_t& set_eps_bearer_id() { - set(types::ssb_idx); + set(types::eps_bearer_id); return c.get(); } - uint8_t& set_csi_rs_idx() + sdap_cfg_s& set_sdap_cfg() { - set(types::csi_rs_idx); - return c.get(); + set(types::sdap_cfg); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; // member variables - uint8_t pucch_pathloss_ref_rs_id = 0; - ref_sig_c_ ref_sig; + bool ext = false; + bool cn_assoc_present = false; + bool reestablish_pdcp_present = false; + bool recover_pdcp_present = false; + bool pdcp_cfg_present = false; + cn_assoc_c_ cn_assoc; + uint8_t drb_id = 1; + pdcp_cfg_s pdcp_cfg; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4409,11 +4586,15 @@ struct pucch_pathloss_ref_rs_s { void to_json(json_writer& j) const; }; -// PUCCH-format0 ::= SEQUENCE -struct pucch_format0_s { - uint8_t init_cyclic_shift = 0; - uint8_t nrof_symbols = 1; - uint8_t start_symbol_idx = 0; +// SRB-ToAddMod ::= SEQUENCE +struct srb_to_add_mod_s { + bool ext = false; + bool reestablish_pdcp_present = false; + bool discard_on_pdcp_present = false; + bool pdcp_cfg_present = false; + uint8_t srb_id = 1; + pdcp_cfg_s pdcp_cfg; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4421,12 +4602,13 @@ struct pucch_format0_s { void to_json(json_writer& j) const; }; -// PUCCH-format1 ::= SEQUENCE -struct pucch_format1_s { - uint8_t init_cyclic_shift = 0; - uint8_t nrof_symbols = 4; - uint8_t start_symbol_idx = 0; - uint8_t time_domain_occ = 0; +// SecurityAlgorithmConfig ::= SEQUENCE +struct security_algorithm_cfg_s { + bool ext = false; + bool integrity_prot_algorithm_present = false; + ciphering_algorithm_e ciphering_algorithm; + integrity_prot_algorithm_e integrity_prot_algorithm; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4434,11 +4616,31 @@ struct pucch_format1_s { void to_json(json_writer& j) const; }; -// PUCCH-format2 ::= SEQUENCE -struct pucch_format2_s { - uint8_t nrof_prbs = 1; - uint8_t nrof_symbols = 1; - uint8_t start_symbol_idx = 0; +// DRB-ToAddModList ::= SEQUENCE (SIZE (1..29)) OF DRB-ToAddMod +using drb_to_add_mod_list_l = dyn_array; + +// DRB-ToReleaseList ::= SEQUENCE (SIZE (1..29)) OF INTEGER (1..32) +using drb_to_release_list_l = bounded_array; + +// SRB-ToAddModList ::= SEQUENCE (SIZE (1..2)) OF SRB-ToAddMod +using srb_to_add_mod_list_l = dyn_array; + +// SecurityConfig ::= SEQUENCE +struct security_cfg_s { + struct key_to_use_opts { + enum options { master, secondary, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated key_to_use_e_; + + // member variables + bool ext = false; + bool security_algorithm_cfg_present = false; + bool key_to_use_present = false; + security_algorithm_cfg_s security_algorithm_cfg; + key_to_use_e_ key_to_use; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4446,11 +4648,19 @@ struct pucch_format2_s { void to_json(json_writer& j) const; }; -// PUCCH-format3 ::= SEQUENCE -struct pucch_format3_s { - uint8_t nrof_prbs = 1; - uint8_t nrof_symbols = 4; - uint8_t start_symbol_idx = 0; +// RadioBearerConfig ::= SEQUENCE +struct radio_bearer_cfg_s { + bool ext = false; + bool srb_to_add_mod_list_present = false; + bool srb3_to_release_present = false; + bool drb_to_add_mod_list_present = false; + bool drb_to_release_list_present = false; + bool security_cfg_present = false; + srb_to_add_mod_list_l srb_to_add_mod_list; + drb_to_add_mod_list_l drb_to_add_mod_list; + drb_to_release_list_l drb_to_release_list; + security_cfg_s security_cfg; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4458,30 +4668,27 @@ struct pucch_format3_s { void to_json(json_writer& j) const; }; -// PUCCH-format4 ::= SEQUENCE -struct pucch_format4_s { - struct occ_len_opts { - enum options { n2, n4, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated occ_len_e_; - struct occ_idx_opts { - enum options { n0, n1, n2, n3, nulltype } value; - typedef uint8_t number_type; +// RRCReject-IEs ::= SEQUENCE +struct rrc_reject_ies_s { + bool wait_time_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + uint8_t wait_time = 1; + dyn_octstring late_non_crit_ext; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated occ_idx_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - uint8_t nrof_symbols = 4; - occ_len_e_ occ_len; - occ_idx_e_ occ_idx; - uint8_t start_symbol_idx = 0; +// RRCSetup-IEs ::= SEQUENCE +struct rrc_setup_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + radio_bearer_cfg_s radio_bearer_cfg; + dyn_octstring master_cell_group; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4489,68 +4696,52 @@ struct pucch_format4_s { void to_json(json_writer& j) const; }; -// PUSCH-PathlossReferenceRS ::= SEQUENCE -struct pusch_pathloss_ref_rs_s { - struct ref_sig_c_ { +// RRCReject ::= SEQUENCE +struct rrc_reject_s { + struct crit_exts_c_ { struct types_opts { - enum options { ssb_idx, csi_rs_idx, nulltype } value; + enum options { rrc_reject, crit_exts_future, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - ref_sig_c_() = default; - ref_sig_c_(const ref_sig_c_& other); - ref_sig_c_& operator=(const ref_sig_c_& other); - ~ref_sig_c_() { destroy_(); } + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& ssb_idx() - { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); - return c.get(); - } - uint8_t& csi_rs_idx() - { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); - return c.get(); - } - const uint8_t& ssb_idx() const - { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); - return c.get(); - } - const uint8_t& csi_rs_idx() const + rrc_reject_ies_s& rrc_reject() { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("rrcReject", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& set_ssb_idx() + const rrc_reject_ies_s& rrc_reject() const { - set(types::ssb_idx); - return c.get(); + assert_choice_type("rrcReject", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& set_csi_rs_idx() + rrc_reject_ies_s& set_rrc_reject() { - set(types::csi_rs_idx); - return c.get(); + set(types::rrc_reject); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; // member variables - uint8_t pusch_pathloss_ref_rs_id = 0; - ref_sig_c_ ref_sig; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4558,22 +4749,53 @@ struct pusch_pathloss_ref_rs_s { void to_json(json_writer& j) const; }; -// SRI-PUSCH-PowerControl ::= SEQUENCE -struct sri_pusch_pwr_ctrl_s { - struct sri_pusch_closed_loop_idx_opts { - enum options { i0, i1, nulltype } value; - typedef uint8_t number_type; +// RRCSetup ::= SEQUENCE +struct rrc_setup_s { + struct crit_exts_c_ { + struct types_opts { + enum options { rrc_setup, crit_exts_future, nulltype } value; - std::string to_string() const; - uint8_t to_number() const; + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_setup_ies_s& rrc_setup() + { + assert_choice_type("rrcSetup", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const rrc_setup_ies_s& rrc_setup() const + { + assert_choice_type("rrcSetup", type_.to_string(), "criticalExtensions"); + return c.get(); + } + rrc_setup_ies_s& set_rrc_setup() + { + set(types::rrc_setup); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); }; - typedef enumerated sri_pusch_closed_loop_idx_e_; // member variables - uint8_t sri_pusch_pwr_ctrl_id = 0; - uint8_t sri_pusch_pathloss_ref_rs_id = 0; - uint8_t sri_p0_pusch_alpha_set_id = 0; - sri_pusch_closed_loop_idx_e_ sri_pusch_closed_loop_idx; + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -4581,448 +4803,229 @@ struct sri_pusch_pwr_ctrl_s { void to_json(json_writer& j) const; }; -// SRS-PeriodicityAndOffset ::= CHOICE -struct srs_periodicity_and_offset_c { - struct types_opts { - enum options { - sl1, - sl2, - sl4, - sl5, - sl8, - sl10, - sl16, - sl20, - sl32, - sl40, - sl64, - sl80, - sl160, - sl320, - sl640, - sl1280, - sl2560, - nulltype - } value; - typedef uint16_t number_type; +// DL-CCCH-MessageType ::= CHOICE +struct dl_ccch_msg_type_c { + struct c1_c_ { + struct types_opts { + enum options { rrc_reject, rrc_setup, spare2, spare1, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + c1_c_() = default; + c1_c_(const c1_c_& other); + c1_c_& operator=(const c1_c_& other); + ~c1_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_reject_s& rrc_reject() + { + assert_choice_type("rrcReject", type_.to_string(), "c1"); + return c.get(); + } + rrc_setup_s& rrc_setup() + { + assert_choice_type("rrcSetup", type_.to_string(), "c1"); + return c.get(); + } + const rrc_reject_s& rrc_reject() const + { + assert_choice_type("rrcReject", type_.to_string(), "c1"); + return c.get(); + } + const rrc_setup_s& rrc_setup() const + { + assert_choice_type("rrcSetup", type_.to_string(), "c1"); + return c.get(); + } + rrc_reject_s& set_rrc_reject() + { + set(types::rrc_reject); + return c.get(); + } + rrc_setup_s& set_rrc_setup() + { + set(types::rrc_setup); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + struct types_opts { + enum options { c1, msg_class_ext, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; - uint16_t to_number() const; + uint8_t to_number() const; }; typedef enumerated types; // choice methods - srs_periodicity_and_offset_c() = default; - srs_periodicity_and_offset_c(const srs_periodicity_and_offset_c& other); - srs_periodicity_and_offset_c& operator=(const srs_periodicity_and_offset_c& other); - ~srs_periodicity_and_offset_c() { destroy_(); } + dl_ccch_msg_type_c() = default; + dl_ccch_msg_type_c(const dl_ccch_msg_type_c& other); + dl_ccch_msg_type_c& operator=(const dl_ccch_msg_type_c& other); + ~dl_ccch_msg_type_c() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& sl2() - { - assert_choice_type("sl2", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl4() - { - assert_choice_type("sl4", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl5() - { - assert_choice_type("sl5", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl8() - { - assert_choice_type("sl8", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl10() - { - assert_choice_type("sl10", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl16() - { - assert_choice_type("sl16", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl20() - { - assert_choice_type("sl20", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl32() - { - assert_choice_type("sl32", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl40() - { - assert_choice_type("sl40", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl64() - { - assert_choice_type("sl64", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl80() - { - assert_choice_type("sl80", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& sl160() - { - assert_choice_type("sl160", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint16_t& sl320() - { - assert_choice_type("sl320", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint16_t& sl640() - { - assert_choice_type("sl640", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint16_t& sl1280() - { - assert_choice_type("sl1280", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint16_t& sl2560() - { - assert_choice_type("sl2560", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl2() const - { - assert_choice_type("sl2", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl4() const - { - assert_choice_type("sl4", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl5() const - { - assert_choice_type("sl5", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl8() const - { - assert_choice_type("sl8", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl10() const - { - assert_choice_type("sl10", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl16() const - { - assert_choice_type("sl16", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl20() const - { - assert_choice_type("sl20", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl32() const - { - assert_choice_type("sl32", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl40() const - { - assert_choice_type("sl40", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl64() const - { - assert_choice_type("sl64", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl80() const - { - assert_choice_type("sl80", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint8_t& sl160() const - { - assert_choice_type("sl160", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint16_t& sl320() const - { - assert_choice_type("sl320", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint16_t& sl640() const - { - assert_choice_type("sl640", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint16_t& sl1280() const - { - assert_choice_type("sl1280", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - const uint16_t& sl2560() const - { - assert_choice_type("sl2560", type_.to_string(), "SRS-PeriodicityAndOffset"); - return c.get(); - } - uint8_t& set_sl2() + c1_c_& c1() { - set(types::sl2); - return c.get(); + assert_choice_type("c1", type_.to_string(), "DL-CCCH-MessageType"); + return c.get(); } - uint8_t& set_sl4() + const c1_c_& c1() const { - set(types::sl4); - return c.get(); + assert_choice_type("c1", type_.to_string(), "DL-CCCH-MessageType"); + return c.get(); } - uint8_t& set_sl5() + c1_c_& set_c1() { - set(types::sl5); - return c.get(); - } - uint8_t& set_sl8() - { - set(types::sl8); - return c.get(); - } - uint8_t& set_sl10() - { - set(types::sl10); - return c.get(); - } - uint8_t& set_sl16() - { - set(types::sl16); - return c.get(); - } - uint8_t& set_sl20() - { - set(types::sl20); - return c.get(); - } - uint8_t& set_sl32() - { - set(types::sl32); - return c.get(); - } - uint8_t& set_sl40() - { - set(types::sl40); - return c.get(); - } - uint8_t& set_sl64() - { - set(types::sl64); - return c.get(); - } - uint8_t& set_sl80() - { - set(types::sl80); - return c.get(); - } - uint8_t& set_sl160() - { - set(types::sl160); - return c.get(); - } - uint16_t& set_sl320() - { - set(types::sl320); - return c.get(); - } - uint16_t& set_sl640() - { - set(types::sl640); - return c.get(); - } - uint16_t& set_sl1280() - { - set(types::sl1280); - return c.get(); - } - uint16_t& set_sl2560() - { - set(types::sl2560); - return c.get(); + set(types::c1); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; -// SRS-SpatialRelationInfo ::= SEQUENCE -struct srs_spatial_relation_info_s { - struct ref_sig_c_ { - struct srs_s_ { - uint8_t res_id = 0; - uint8_t ul_bwp = 0; - }; +// DL-CCCH-Message ::= SEQUENCE +struct dl_ccch_msg_s { + dl_ccch_msg_type_c msg; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CSI-RS-Resource-Mobility ::= SEQUENCE +struct csi_rs_res_mob_s { + struct slot_cfg_c_ { struct types_opts { - enum options { ssb_idx, csi_rs_idx, srs, nulltype } value; + enum options { ms4, ms5, ms10, ms20, ms40, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; typedef enumerated types; // choice methods - ref_sig_c_() = default; - ref_sig_c_(const ref_sig_c_& other); - ref_sig_c_& operator=(const ref_sig_c_& other); - ~ref_sig_c_() { destroy_(); } + slot_cfg_c_() = default; + slot_cfg_c_(const slot_cfg_c_& other); + slot_cfg_c_& operator=(const slot_cfg_c_& other); + ~slot_cfg_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& ssb_idx() + uint8_t& ms4() { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + assert_choice_type("ms4", type_.to_string(), "slotConfig"); return c.get(); } - uint8_t& csi_rs_idx() + uint8_t& ms5() { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + assert_choice_type("ms5", type_.to_string(), "slotConfig"); return c.get(); } - srs_s_& srs() + uint8_t& ms10() { - assert_choice_type("srs", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("ms10", type_.to_string(), "slotConfig"); + return c.get(); } - const uint8_t& ssb_idx() const + uint8_t& ms20() { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + assert_choice_type("ms20", type_.to_string(), "slotConfig"); return c.get(); } - const uint8_t& csi_rs_idx() const + uint16_t& ms40() { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + assert_choice_type("ms40", type_.to_string(), "slotConfig"); + return c.get(); + } + const uint8_t& ms4() const + { + assert_choice_type("ms4", type_.to_string(), "slotConfig"); return c.get(); } - const srs_s_& srs() const + const uint8_t& ms5() const { - assert_choice_type("srs", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("ms5", type_.to_string(), "slotConfig"); + return c.get(); } - uint8_t& set_ssb_idx() + const uint8_t& ms10() const { - set(types::ssb_idx); + assert_choice_type("ms10", type_.to_string(), "slotConfig"); return c.get(); } - uint8_t& set_csi_rs_idx() + const uint8_t& ms20() const { - set(types::csi_rs_idx); + assert_choice_type("ms20", type_.to_string(), "slotConfig"); return c.get(); } - srs_s_& set_srs() + const uint16_t& ms40() const { - set(types::srs); - return c.get(); + assert_choice_type("ms40", type_.to_string(), "slotConfig"); + return c.get(); + } + uint8_t& set_ms4() + { + set(types::ms4); + return c.get(); + } + uint8_t& set_ms5() + { + set(types::ms5); + return c.get(); + } + uint8_t& set_ms10() + { + set(types::ms10); + return c.get(); + } + uint8_t& set_ms20() + { + set(types::ms20); + return c.get(); + } + uint16_t& set_ms40() + { + set(types::ms40); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; - - // member variables - bool serving_cell_id_present = false; - uint8_t serving_cell_id = 0; - ref_sig_c_ ref_sig; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CG-UCI-OnPUSCH ::= CHOICE -struct cg_uci_on_pusch_c { - using dynamic_l_ = dyn_array; - struct types_opts { - enum options { dynamic_type, semi_static, nulltype } value; - - std::string to_string() const; + struct associated_ssb_s_ { + uint8_t ssb_idx = 0; + bool is_quasi_colocated = false; }; - typedef enumerated types; - - // choice methods - cg_uci_on_pusch_c() = default; - cg_uci_on_pusch_c(const cg_uci_on_pusch_c& other); - cg_uci_on_pusch_c& operator=(const cg_uci_on_pusch_c& other); - ~cg_uci_on_pusch_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - dynamic_l_& dynamic_type() - { - assert_choice_type("dynamic", type_.to_string(), "CG-UCI-OnPUSCH"); - return c.get(); - } - beta_offsets_s& semi_static() - { - assert_choice_type("semiStatic", type_.to_string(), "CG-UCI-OnPUSCH"); - return c.get(); - } - const dynamic_l_& dynamic_type() const - { - assert_choice_type("dynamic", type_.to_string(), "CG-UCI-OnPUSCH"); - return c.get(); - } - const beta_offsets_s& semi_static() const - { - assert_choice_type("semiStatic", type_.to_string(), "CG-UCI-OnPUSCH"); - return c.get(); - } - dynamic_l_& set_dynamic_type() - { - set(types::dynamic_type); - return c.get(); - } - beta_offsets_s& set_semi_static() - { - set(types::semi_static); - return c.get(); - } - -private: - types type_; - choice_buffer_t c; - - void destroy_(); -}; - -// CSI-RS-ResourceMapping ::= SEQUENCE -struct csi_rs_res_map_s { struct freq_domain_alloc_c_ { struct types_opts { - enum options { row1, row2, row4, other, nulltype } value; + enum options { row1, row2, nulltype } value; typedef uint8_t number_type; std::string to_string() const; @@ -5051,17 +5054,7 @@ struct csi_rs_res_map_s { assert_choice_type("row2", type_.to_string(), "frequencyDomainAllocation"); return c.get >(); } - fixed_bitstring<3>& row4() - { - assert_choice_type("row4", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } - fixed_bitstring<6>& other() - { - assert_choice_type("other", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } - const fixed_bitstring<4>& row1() const + const fixed_bitstring<4>& row1() const { assert_choice_type("row1", type_.to_string(), "frequencyDomainAllocation"); return c.get >(); @@ -5071,16 +5064,6 @@ struct csi_rs_res_map_s { assert_choice_type("row2", type_.to_string(), "frequencyDomainAllocation"); return c.get >(); } - const fixed_bitstring<3>& row4() const - { - assert_choice_type("row4", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } - const fixed_bitstring<6>& other() const - { - assert_choice_type("other", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } fixed_bitstring<4>& set_row1() { set(types::row1); @@ -5091,16 +5074,6 @@ struct csi_rs_res_map_s { set(types::row2); return c.get >(); } - fixed_bitstring<3>& set_row4() - { - set(types::row4); - return c.get >(); - } - fixed_bitstring<6>& set_other() - { - set(types::other); - return c.get >(); - } private: types type_; @@ -5108,78 +5081,96 @@ struct csi_rs_res_map_s { void destroy_(); }; - struct nrof_ports_opts { - enum options { p1, p2, p4, p8, p12, p16, p24, p32, nulltype } value; - typedef uint8_t number_type; - std::string to_string() const; - uint8_t to_number() const; + // member variables + bool ext = false; + bool associated_ssb_present = false; + uint8_t csi_rs_idx = 0; + slot_cfg_c_ slot_cfg; + associated_ssb_s_ associated_ssb; + freq_domain_alloc_c_ freq_domain_alloc; + uint8_t first_ofdm_symbol_in_time_domain = 0; + uint16_t seq_generation_cfg = 0; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CSI-RS-CellMobility ::= SEQUENCE +struct csi_rs_cell_mob_s { + struct csi_rs_meas_bw_s_ { + struct nrof_prbs_opts { + enum options { size24, size48, size96, size192, size264, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated nrof_prbs_e_; + + // member variables + nrof_prbs_e_ nrof_prbs; + uint16_t start_prb = 0; }; - typedef enumerated nrof_ports_e_; - struct cdm_type_opts { - enum options { no_cdm, fd_cdm2, cdm4_fd2_td2, cdm8_fd2_td4, nulltype } value; + struct density_opts { + enum options { d1, d3, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated cdm_type_e_; - struct density_c_ { - struct dot5_opts { - enum options { even_prbs, odd_prbs, nulltype } value; + typedef enumerated density_e_; + using csi_rs_res_list_mob_l_ = dyn_array; - std::string to_string() const; - }; - typedef enumerated dot5_e_; - struct types_opts { - enum options { dot5, one, three, spare, nulltype } value; - typedef uint8_t number_type; + // member variables + bool density_present = false; + uint16_t cell_id = 0; + csi_rs_meas_bw_s_ csi_rs_meas_bw; + density_e_ density; + csi_rs_res_list_mob_l_ csi_rs_res_list_mob; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // choice methods - density_c_() = default; - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - dot5_e_& dot5() - { - assert_choice_type("dot5", type_.to_string(), "density"); - return c; - } - const dot5_e_& dot5() const - { - assert_choice_type("dot5", type_.to_string(), "density"); - return c; - } - dot5_e_& set_dot5() - { - set(types::dot5); - return c; - } +// Q-OffsetRangeList ::= SEQUENCE +struct q_offset_range_list_s { + bool rsrp_offset_ssb_present = false; + bool rsrq_offset_ssb_present = false; + bool sinr_offset_ssb_present = false; + bool rsrp_offset_csi_rs_present = false; + bool rsrq_offset_csi_rs_present = false; + bool sinr_offset_csi_rs_present = false; + q_offset_range_e rsrp_offset_ssb; + q_offset_range_e rsrq_offset_ssb; + q_offset_range_e sinr_offset_ssb; + q_offset_range_e rsrp_offset_csi_rs; + q_offset_range_e rsrq_offset_csi_rs; + q_offset_range_e sinr_offset_csi_rs; - private: - types type_; - dot5_e_ c; - }; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CSI-RS-ResourceConfigMobility ::= SEQUENCE +struct csi_rs_res_cfg_mob_s { + using csi_rs_cell_list_mob_l_ = dyn_array; // member variables - bool ext = false; - bool first_ofdm_symbol_in_time_domain2_present = false; - freq_domain_alloc_c_ freq_domain_alloc; - nrof_ports_e_ nrof_ports; - uint8_t first_ofdm_symbol_in_time_domain = 0; - uint8_t first_ofdm_symbol_in_time_domain2 = 2; - cdm_type_e_ cdm_type; - density_c_ density; - csi_freq_occupation_s freq_band; + bool ext = false; + subcarrier_spacing_e subcarrier_spacing; + csi_rs_cell_list_mob_l_ csi_rs_cell_list_mob; // ... + // group 0 + bool ref_serv_cell_idx_present = false; + uint8_t ref_serv_cell_idx = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -5187,237 +5178,267 @@ struct csi_rs_res_map_s { void to_json(json_writer& j) const; }; -// CSI-ResourcePeriodicityAndOffset ::= CHOICE -struct csi_res_periodicity_and_offset_c { +// CellsToAddMod ::= SEQUENCE +struct cells_to_add_mod_s { + uint16_t pci = 0; + q_offset_range_list_s cell_individual_offset; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// FilterCoefficient ::= ENUMERATED +struct filt_coef_opts { + enum options { + fc0, + fc1, + fc2, + fc3, + fc4, + fc5, + fc6, + fc7, + fc8, + fc9, + fc11, + fc13, + fc15, + fc17, + fc19, + spare1, + /*...*/ nulltype + } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; +}; +typedef enumerated filt_coef_e; + +// MeasReportQuantity ::= SEQUENCE +struct meas_report_quant_s { + bool rsrp = false; + bool rsrq = false; + bool sinr = false; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MeasTriggerQuantity ::= CHOICE +struct meas_trigger_quant_c { struct types_opts { - enum options { - slots4, - slots5, - slots8, - slots10, - slots16, - slots20, - slots32, - slots40, - slots64, - slots80, - slots160, - slots320, - slots640, - nulltype - } value; - typedef uint16_t number_type; + enum options { rsrp, rsrq, sinr, nulltype } value; std::string to_string() const; - uint16_t to_number() const; }; typedef enumerated types; // choice methods - csi_res_periodicity_and_offset_c() = default; - csi_res_periodicity_and_offset_c(const csi_res_periodicity_and_offset_c& other); - csi_res_periodicity_and_offset_c& operator=(const csi_res_periodicity_and_offset_c& other); - ~csi_res_periodicity_and_offset_c() { destroy_(); } + meas_trigger_quant_c() = default; + meas_trigger_quant_c(const meas_trigger_quant_c& other); + meas_trigger_quant_c& operator=(const meas_trigger_quant_c& other); + ~meas_trigger_quant_c() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& slots4() + uint8_t& rsrp() { - assert_choice_type("slots4", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantity"); return c.get(); } - uint8_t& slots5() + uint8_t& rsrq() { - assert_choice_type("slots5", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantity"); return c.get(); } - uint8_t& slots8() + uint8_t& sinr() { - assert_choice_type("slots8", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantity"); return c.get(); } - uint8_t& slots10() + const uint8_t& rsrp() const { - assert_choice_type("slots10", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots16() - { - assert_choice_type("slots16", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots20() - { - assert_choice_type("slots20", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots32() - { - assert_choice_type("slots32", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots40() - { - assert_choice_type("slots40", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots64() - { - assert_choice_type("slots64", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots80() - { - assert_choice_type("slots80", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots160() - { - assert_choice_type("slots160", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint16_t& slots320() - { - assert_choice_type("slots320", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint16_t& slots640() - { - assert_choice_type("slots640", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots4() const - { - assert_choice_type("slots4", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantity"); return c.get(); } - const uint8_t& slots5() const + const uint8_t& rsrq() const { - assert_choice_type("slots5", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantity"); return c.get(); } - const uint8_t& slots8() const + const uint8_t& sinr() const { - assert_choice_type("slots8", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantity"); return c.get(); } - const uint8_t& slots10() const + uint8_t& set_rsrp() { - assert_choice_type("slots10", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + set(types::rsrp); return c.get(); } - const uint8_t& slots16() const + uint8_t& set_rsrq() { - assert_choice_type("slots16", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + set(types::rsrq); return c.get(); } - const uint8_t& slots20() const + uint8_t& set_sinr() { - assert_choice_type("slots20", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + set(types::sinr); return c.get(); } - const uint8_t& slots32() const + +private: + types type_; + pod_choice_buffer_t c; + + void destroy_(); +}; + +// MeasTriggerQuantityEUTRA ::= CHOICE +struct meas_trigger_quant_eutra_c { + struct types_opts { + enum options { rsrp, rsrq, sinr, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + meas_trigger_quant_eutra_c() = default; + meas_trigger_quant_eutra_c(const meas_trigger_quant_eutra_c& other); + meas_trigger_quant_eutra_c& operator=(const meas_trigger_quant_eutra_c& other); + ~meas_trigger_quant_eutra_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + uint8_t& rsrp() { - assert_choice_type("slots32", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityEUTRA"); return c.get(); } - const uint8_t& slots40() const + uint8_t& rsrq() { - assert_choice_type("slots40", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityEUTRA"); return c.get(); } - const uint8_t& slots64() const + uint8_t& sinr() { - assert_choice_type("slots64", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityEUTRA"); return c.get(); } - const uint8_t& slots80() const + const uint8_t& rsrp() const { - assert_choice_type("slots80", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityEUTRA"); return c.get(); } - const uint8_t& slots160() const + const uint8_t& rsrq() const { - assert_choice_type("slots160", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityEUTRA"); return c.get(); } - const uint16_t& slots320() const - { - assert_choice_type("slots320", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - const uint16_t& slots640() const - { - assert_choice_type("slots640", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); - return c.get(); - } - uint8_t& set_slots4() + const uint8_t& sinr() const { - set(types::slots4); + assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityEUTRA"); return c.get(); } - uint8_t& set_slots5() + uint8_t& set_rsrp() { - set(types::slots5); + set(types::rsrp); return c.get(); } - uint8_t& set_slots8() + uint8_t& set_rsrq() { - set(types::slots8); + set(types::rsrq); return c.get(); } - uint8_t& set_slots10() + uint8_t& set_sinr() { - set(types::slots10); + set(types::sinr); return c.get(); } - uint8_t& set_slots16() + +private: + types type_; + pod_choice_buffer_t c; + + void destroy_(); +}; + +// MeasTriggerQuantityOffset ::= CHOICE +struct meas_trigger_quant_offset_c { + struct types_opts { + enum options { rsrp, rsrq, sinr, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + meas_trigger_quant_offset_c() = default; + meas_trigger_quant_offset_c(const meas_trigger_quant_offset_c& other); + meas_trigger_quant_offset_c& operator=(const meas_trigger_quant_offset_c& other); + ~meas_trigger_quant_offset_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + int8_t& rsrp() { - set(types::slots16); - return c.get(); + assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityOffset"); + return c.get(); } - uint8_t& set_slots20() + int8_t& rsrq() { - set(types::slots20); - return c.get(); + assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityOffset"); + return c.get(); } - uint8_t& set_slots32() + int8_t& sinr() { - set(types::slots32); - return c.get(); + assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityOffset"); + return c.get(); } - uint8_t& set_slots40() + const int8_t& rsrp() const { - set(types::slots40); - return c.get(); + assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityOffset"); + return c.get(); } - uint8_t& set_slots64() + const int8_t& rsrq() const { - set(types::slots64); - return c.get(); + assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityOffset"); + return c.get(); } - uint8_t& set_slots80() + const int8_t& sinr() const { - set(types::slots80); - return c.get(); + assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityOffset"); + return c.get(); } - uint8_t& set_slots160() + int8_t& set_rsrp() { - set(types::slots160); - return c.get(); + set(types::rsrp); + return c.get(); } - uint16_t& set_slots320() + int8_t& set_rsrq() { - set(types::slots320); - return c.get(); + set(types::rsrq); + return c.get(); } - uint16_t& set_slots640() + int8_t& set_sinr() { - set(types::slots640); - return c.get(); + set(types::sinr); + return c.get(); } private: @@ -5427,146 +5448,48 @@ private: void destroy_(); }; -// DMRS-UplinkConfig ::= SEQUENCE -struct dmrs_ul_cfg_s { - struct dmrs_add_position_opts { - enum options { pos0, pos1, pos3, nulltype } value; - typedef uint8_t number_type; +// NR-RS-Type ::= ENUMERATED +struct nr_rs_type_opts { + enum options { ssb, csi_rs, nulltype } value; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated dmrs_add_position_e_; - struct transform_precoding_disabled_s_ { - bool ext = false; - bool scrambling_id0_present = false; - bool scrambling_id1_present = false; - uint32_t scrambling_id0 = 0; - uint32_t scrambling_id1 = 0; - // ... - }; - struct transform_precoding_enabled_s_ { - bool ext = false; - bool npusch_id_present = false; - bool seq_group_hop_present = false; - bool seq_hop_present = false; - uint16_t npusch_id = 0; - // ... - }; - - // member variables - bool ext = false; - bool dmrs_type_present = false; - bool dmrs_add_position_present = false; - bool phase_tracking_rs_present = false; - bool max_len_present = false; - bool transform_precoding_disabled_present = false; - bool transform_precoding_enabled_present = false; - dmrs_add_position_e_ dmrs_add_position; - setup_release_c phase_tracking_rs; - transform_precoding_disabled_s_ transform_precoding_disabled; - transform_precoding_enabled_s_ transform_precoding_enabled; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// INT-ConfigurationPerServingCell ::= SEQUENCE -struct int_cfg_per_serving_cell_s { - uint8_t serving_cell_id = 0; - uint8_t position_in_dci = 0; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + std::string to_string() const; }; +typedef enumerated nr_rs_type_e; -// PRACH-ResourceDedicatedBFR ::= CHOICE -struct prach_res_ded_bfr_c { - struct types_opts { - enum options { ssb, csi_rs, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - prach_res_ded_bfr_c() = default; - prach_res_ded_bfr_c(const prach_res_ded_bfr_c& other); - prach_res_ded_bfr_c& operator=(const prach_res_ded_bfr_c& other); - ~prach_res_ded_bfr_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - bfr_ssb_res_s& ssb() - { - assert_choice_type("ssb", type_.to_string(), "PRACH-ResourceDedicatedBFR"); - return c.get(); - } - bfr_csirs_res_s& csi_rs() - { - assert_choice_type("csi-RS", type_.to_string(), "PRACH-ResourceDedicatedBFR"); - return c.get(); - } - const bfr_ssb_res_s& ssb() const - { - assert_choice_type("ssb", type_.to_string(), "PRACH-ResourceDedicatedBFR"); - return c.get(); - } - const bfr_csirs_res_s& csi_rs() const - { - assert_choice_type("csi-RS", type_.to_string(), "PRACH-ResourceDedicatedBFR"); - return c.get(); - } - bfr_ssb_res_s& set_ssb() - { - set(types::ssb); - return c.get(); - } - bfr_csirs_res_s& set_csi_rs() - { - set(types::csi_rs); - return c.get(); - } - -private: - types type_; - choice_buffer_t c; +// ReportInterval ::= ENUMERATED +struct report_interv_opts { + enum options { + ms120, + ms240, + ms480, + ms640, + ms1024, + ms2048, + ms5120, + ms10240, + ms20480, + ms40960, + min1, + min6, + min12, + min30, + nulltype + } value; + typedef uint16_t number_type; - void destroy_(); + std::string to_string() const; + uint16_t to_number() const; }; +typedef enumerated report_interv_e; -// PTRS-DownlinkConfig ::= SEQUENCE -struct ptrs_dl_cfg_s { - using freq_density_l_ = std::array; - using time_density_l_ = std::array; - struct res_elem_offset_opts { - enum options { offset01, offset10, offset11, nulltype } value; - typedef float number_type; - - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated res_elem_offset_e_; - - // member variables - bool ext = false; - bool freq_density_present = false; - bool time_density_present = false; - bool epre_ratio_present = false; - bool res_elem_offset_present = false; - freq_density_l_ freq_density; - time_density_l_ time_density; - uint8_t epre_ratio = 0; - res_elem_offset_e_ res_elem_offset; +// SSB-ConfigMobility ::= SEQUENCE +struct ssb_cfg_mob_s { + bool ext = false; + bool ssb_to_measure_present = false; + bool ss_rssi_meas_present = false; + setup_release_c ssb_to_measure; + bool derive_ssb_idx_from_cell = false; + ss_rssi_meas_s ss_rssi_meas; // ... // sequence methods @@ -5575,26 +5498,41 @@ struct ptrs_dl_cfg_s { void to_json(json_writer& j) const; }; -// PUCCH-FormatConfig ::= SEQUENCE -struct pucch_format_cfg_s { - struct nrof_slots_opts { - enum options { n2, n4, n8, nulltype } value; - typedef uint8_t number_type; +// TimeToTrigger ::= ENUMERATED +struct time_to_trigger_opts { + enum options { + ms0, + ms40, + ms64, + ms80, + ms100, + ms128, + ms160, + ms256, + ms320, + ms480, + ms512, + ms640, + ms1024, + ms1280, + ms2560, + ms5120, + nulltype + } value; + typedef uint16_t number_type; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated nrof_slots_e_; + std::string to_string() const; + uint16_t to_number() const; +}; +typedef enumerated time_to_trigger_e; - // member variables - bool interslot_freq_hop_present = false; - bool add_dmrs_present = false; - bool max_code_rate_present = false; - bool nrof_slots_present = false; - bool pi2_bpsk_present = false; - bool simul_harq_ack_csi_present = false; - pucch_max_code_rate_e max_code_rate; - nrof_slots_e_ nrof_slots; +// CellsToAddModList ::= SEQUENCE (SIZE (1..32)) OF CellsToAddMod +using cells_to_add_mod_list_l = dyn_array; + +// EUTRA-BlackCell ::= SEQUENCE +struct eutra_black_cell_s { + uint8_t cell_idx_eutra = 1; + eutra_pci_range_s pci_range; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -5602,29 +5540,11 @@ struct pucch_format_cfg_s { void to_json(json_writer& j) const; }; -// PUCCH-PowerControl ::= SEQUENCE -struct pucch_pwr_ctrl_s { - using p0_set_l_ = dyn_array; - using pathloss_ref_rss_l_ = dyn_array; - - // member variables - bool ext = false; - bool delta_f_pucch_f0_present = false; - bool delta_f_pucch_f1_present = false; - bool delta_f_pucch_f2_present = false; - bool delta_f_pucch_f3_present = false; - bool delta_f_pucch_f4_present = false; - bool p0_set_present = false; - bool pathloss_ref_rss_present = false; - bool two_pucch_pc_adjustment_states_present = false; - int8_t delta_f_pucch_f0 = -16; - int8_t delta_f_pucch_f1 = -16; - int8_t delta_f_pucch_f2 = -16; - int8_t delta_f_pucch_f3 = -16; - int8_t delta_f_pucch_f4 = -16; - p0_set_l_ p0_set; - pathloss_ref_rss_l_ pathloss_ref_rss; - // ... +// EUTRA-Cell ::= SEQUENCE +struct eutra_cell_s { + uint8_t cell_idx_eutra = 1; + uint16_t pci = 0; + eutra_q_offset_range_e cell_individual_offset; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -5632,135 +5552,194 @@ struct pucch_pwr_ctrl_s { void to_json(json_writer& j) const; }; -// PUCCH-Resource ::= SEQUENCE -struct pucch_res_s { - struct format_c_ { - struct types_opts { - enum options { format0, format1, format2, format3, format4, nulltype } value; - typedef uint8_t number_type; +// EUTRA-CellIndexList ::= SEQUENCE (SIZE (1..32)) OF INTEGER (1..32) +using eutra_cell_idx_list_l = bounded_array; - std::string to_string() const; - uint8_t to_number() const; +// EventTriggerConfig ::= SEQUENCE +struct event_trigger_cfg_s { + struct event_id_c_ { + struct event_a1_s_ { + meas_trigger_quant_c a1_thres; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; }; - typedef enumerated types; - - // choice methods - format_c_() = default; - format_c_(const format_c_& other); - format_c_& operator=(const format_c_& other); - ~format_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - pucch_format0_s& format0() - { - assert_choice_type("format0", type_.to_string(), "format"); - return c.get(); + struct event_a2_s_ { + meas_trigger_quant_c a2_thres; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; + }; + struct event_a3_s_ { + meas_trigger_quant_offset_c a3_offset; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; + bool use_white_cell_list = false; + }; + struct event_a4_s_ { + meas_trigger_quant_c a4_thres; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; + bool use_white_cell_list = false; + }; + struct event_a5_s_ { + meas_trigger_quant_c a5_thres1; + meas_trigger_quant_c a5_thres2; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; + bool use_white_cell_list = false; + }; + struct event_a6_s_ { + meas_trigger_quant_offset_c a6_offset; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; + bool use_white_cell_list = false; + }; + struct types_opts { + enum options { event_a1, event_a2, event_a3, event_a4, event_a5, event_a6, /*...*/ nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + event_id_c_() = default; + event_id_c_(const event_id_c_& other); + event_id_c_& operator=(const event_id_c_& other); + ~event_id_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + event_a1_s_& event_a1() + { + assert_choice_type("eventA1", type_.to_string(), "eventId"); + return c.get(); } - pucch_format1_s& format1() + event_a2_s_& event_a2() { - assert_choice_type("format1", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA2", type_.to_string(), "eventId"); + return c.get(); } - pucch_format2_s& format2() + event_a3_s_& event_a3() { - assert_choice_type("format2", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA3", type_.to_string(), "eventId"); + return c.get(); } - pucch_format3_s& format3() + event_a4_s_& event_a4() { - assert_choice_type("format3", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA4", type_.to_string(), "eventId"); + return c.get(); } - pucch_format4_s& format4() + event_a5_s_& event_a5() { - assert_choice_type("format4", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA5", type_.to_string(), "eventId"); + return c.get(); } - const pucch_format0_s& format0() const + event_a6_s_& event_a6() { - assert_choice_type("format0", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA6", type_.to_string(), "eventId"); + return c.get(); } - const pucch_format1_s& format1() const + const event_a1_s_& event_a1() const { - assert_choice_type("format1", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA1", type_.to_string(), "eventId"); + return c.get(); } - const pucch_format2_s& format2() const + const event_a2_s_& event_a2() const { - assert_choice_type("format2", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA2", type_.to_string(), "eventId"); + return c.get(); } - const pucch_format3_s& format3() const + const event_a3_s_& event_a3() const { - assert_choice_type("format3", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA3", type_.to_string(), "eventId"); + return c.get(); } - const pucch_format4_s& format4() const + const event_a4_s_& event_a4() const { - assert_choice_type("format4", type_.to_string(), "format"); - return c.get(); + assert_choice_type("eventA4", type_.to_string(), "eventId"); + return c.get(); } - pucch_format0_s& set_format0() + const event_a5_s_& event_a5() const { - set(types::format0); - return c.get(); + assert_choice_type("eventA5", type_.to_string(), "eventId"); + return c.get(); } - pucch_format1_s& set_format1() + const event_a6_s_& event_a6() const { - set(types::format1); - return c.get(); + assert_choice_type("eventA6", type_.to_string(), "eventId"); + return c.get(); } - pucch_format2_s& set_format2() + event_a1_s_& set_event_a1() { - set(types::format2); - return c.get(); + set(types::event_a1); + return c.get(); } - pucch_format3_s& set_format3() + event_a2_s_& set_event_a2() { - set(types::format3); - return c.get(); + set(types::event_a2); + return c.get(); } - pucch_format4_s& set_format4() + event_a3_s_& set_event_a3() { - set(types::format4); - return c.get(); + set(types::event_a3); + return c.get(); + } + event_a4_s_& set_event_a4() + { + set(types::event_a4); + return c.get(); + } + event_a5_s_& set_event_a5() + { + set(types::event_a5); + return c.get(); + } + event_a6_s_& set_event_a6() + { + set(types::event_a6); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; + struct report_amount_opts { + enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; + typedef int8_t number_type; - // member variables - bool intra_slot_freq_hop_present = false; - bool second_hop_prb_present = false; - uint8_t pucch_res_id = 0; - uint16_t start_prb = 0; - uint16_t second_hop_prb = 0; - format_c_ format; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PUCCH-ResourceSet ::= SEQUENCE -struct pucch_res_set_s { - using res_list_l_ = bounded_array; + std::string to_string() const; + int8_t to_number() const; + }; + typedef enumerated report_amount_e_; // member variables - bool max_payload_minus1_present = false; - uint8_t pucch_res_set_id = 0; - res_list_l_ res_list; - uint16_t max_payload_minus1 = 4; + bool ext = false; + bool report_quant_rs_idxes_present = false; + bool max_nrof_rs_idxes_to_report_present = false; + bool report_add_neigh_meas_present = false; + event_id_c_ event_id; + nr_rs_type_e rs_type; + report_interv_e report_interv; + report_amount_e_ report_amount; + meas_report_quant_s report_quant_cell; + uint8_t max_report_cells = 1; + meas_report_quant_s report_quant_rs_idxes; + uint8_t max_nrof_rs_idxes_to_report = 1; + bool include_beam_meass = false; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -5768,100 +5747,101 @@ struct pucch_res_set_s { void to_json(json_writer& j) const; }; -// PUCCH-SpatialRelationInfo ::= SEQUENCE -struct pucch_spatial_relation_info_s { - struct ref_sig_c_ { - struct srs_s_ { - uint8_t res = 0; - uint8_t ul_bwp = 0; +// EventTriggerConfigInterRAT ::= SEQUENCE +struct event_trigger_cfg_inter_rat_s { + struct event_id_c_ { + struct event_b1_s_ { + bool ext = false; + meas_trigger_quant_eutra_c b1_thres_eutra; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; + // ... + }; + struct event_b2_s_ { + bool ext = false; + meas_trigger_quant_c b2_thres1; + meas_trigger_quant_eutra_c b2_thres2_eutra; + bool report_on_leave = false; + uint8_t hysteresis = 0; + time_to_trigger_e time_to_trigger; + // ... }; struct types_opts { - enum options { ssb_idx, csi_rs_idx, srs, nulltype } value; + enum options { event_b1, event_b2, /*...*/ nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - ref_sig_c_() = default; - ref_sig_c_(const ref_sig_c_& other); - ref_sig_c_& operator=(const ref_sig_c_& other); - ~ref_sig_c_() { destroy_(); } + event_id_c_() = default; + event_id_c_(const event_id_c_& other); + event_id_c_& operator=(const event_id_c_& other); + ~event_id_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& ssb_idx() + event_b1_s_& event_b1() { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("eventB1", type_.to_string(), "eventId"); + return c.get(); } - uint8_t& csi_rs_idx() + event_b2_s_& event_b2() { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("eventB2", type_.to_string(), "eventId"); + return c.get(); } - srs_s_& srs() + const event_b1_s_& event_b1() const { - assert_choice_type("srs", type_.to_string(), "referenceSignal"); - return c.get(); - } - const uint8_t& ssb_idx() const - { - assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); - return c.get(); - } - const uint8_t& csi_rs_idx() const - { - assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); - return c.get(); - } - const srs_s_& srs() const - { - assert_choice_type("srs", type_.to_string(), "referenceSignal"); - return c.get(); + assert_choice_type("eventB1", type_.to_string(), "eventId"); + return c.get(); } - uint8_t& set_ssb_idx() + const event_b2_s_& event_b2() const { - set(types::ssb_idx); - return c.get(); + assert_choice_type("eventB2", type_.to_string(), "eventId"); + return c.get(); } - uint8_t& set_csi_rs_idx() + event_b1_s_& set_event_b1() { - set(types::csi_rs_idx); - return c.get(); + set(types::event_b1); + return c.get(); } - srs_s_& set_srs() + event_b2_s_& set_event_b2() { - set(types::srs); - return c.get(); + set(types::event_b2); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct closed_loop_idx_opts { - enum options { i0, i1, nulltype } value; - typedef uint8_t number_type; + struct report_amount_opts { + enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; + typedef int8_t number_type; std::string to_string() const; - uint8_t to_number() const; + int8_t to_number() const; }; - typedef enumerated closed_loop_idx_e_; + typedef enumerated report_amount_e_; // member variables - bool serving_cell_id_present = false; - uint8_t pucch_spatial_relation_info_id = 1; - uint8_t serving_cell_id = 0; - ref_sig_c_ ref_sig; - uint8_t pucch_pathloss_ref_rs_id = 0; - uint8_t p0_pucch_id = 1; - closed_loop_idx_e_ closed_loop_idx; + bool ext = false; + event_id_c_ event_id; + nr_rs_type_e rs_type; + report_interv_e report_interv; + report_amount_e_ report_amount; + meas_report_quant_s report_quant; + uint8_t max_report_cells = 1; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -5869,32 +5849,14 @@ struct pucch_spatial_relation_info_s { void to_json(json_writer& j) const; }; -// PUSCH-PowerControl ::= SEQUENCE -struct pusch_pwr_ctrl_s { - using p0_alpha_sets_l_ = dyn_array; - using pathloss_ref_rs_to_add_mod_list_l_ = dyn_array; - using pathloss_ref_rs_to_release_list_l_ = bounded_array; - using sri_pusch_map_to_add_mod_list_l_ = dyn_array; - using sri_pusch_map_to_release_list_l_ = bounded_array; - - // member variables - bool tpc_accumulation_present = false; - bool msg3_alpha_present = false; - bool p0_nominal_without_grant_present = false; - bool p0_alpha_sets_present = false; - bool pathloss_ref_rs_to_add_mod_list_present = false; - bool pathloss_ref_rs_to_release_list_present = false; - bool two_pusch_pc_adjustment_states_present = false; - bool delta_mcs_present = false; - bool sri_pusch_map_to_add_mod_list_present = false; - bool sri_pusch_map_to_release_list_present = false; - alpha_e msg3_alpha; - int16_t p0_nominal_without_grant = -202; - p0_alpha_sets_l_ p0_alpha_sets; - pathloss_ref_rs_to_add_mod_list_l_ pathloss_ref_rs_to_add_mod_list; - pathloss_ref_rs_to_release_list_l_ pathloss_ref_rs_to_release_list; - sri_pusch_map_to_add_mod_list_l_ sri_pusch_map_to_add_mod_list; - sri_pusch_map_to_release_list_l_ sri_pusch_map_to_release_list; +// FilterConfig ::= SEQUENCE +struct filt_cfg_s { + bool filt_coef_rsrp_present = false; + bool filt_coef_rsrq_present = false; + bool filt_coef_rs_sinr_present = false; + filt_coef_e filt_coef_rsrp; + filt_coef_e filt_coef_rsrq; + filt_coef_e filt_coef_rs_sinr; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -5902,79 +5864,47 @@ struct pusch_pwr_ctrl_s { void to_json(json_writer& j) const; }; -// QCL-Info ::= SEQUENCE -struct qcl_info_s { - struct ref_sig_c_ { - struct types_opts { - enum options { csi_rs, ssb, nulltype } value; +// PCI-List ::= SEQUENCE (SIZE (1..32)) OF INTEGER (0..1007) +using pci_list_l = bounded_array; - std::string to_string() const; - }; - typedef enumerated types; +// PCI-RangeElement ::= SEQUENCE +struct pci_range_elem_s { + uint8_t pci_range_idx = 1; + pci_range_s pci_range; - // choice methods - ref_sig_c_() = default; - ref_sig_c_(const ref_sig_c_& other); - ref_sig_c_& operator=(const ref_sig_c_& other); - ~ref_sig_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - uint8_t& csi_rs() - { - assert_choice_type("csi-rs", type_.to_string(), "referenceSignal"); - return c.get(); - } - uint8_t& ssb() - { - assert_choice_type("ssb", type_.to_string(), "referenceSignal"); - return c.get(); - } - const uint8_t& csi_rs() const - { - assert_choice_type("csi-rs", type_.to_string(), "referenceSignal"); - return c.get(); - } - const uint8_t& ssb() const - { - assert_choice_type("ssb", type_.to_string(), "referenceSignal"); - return c.get(); - } - uint8_t& set_csi_rs() - { - set(types::csi_rs); - return c.get(); - } - uint8_t& set_ssb() - { - set(types::ssb); - return c.get(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - pod_choice_buffer_t c; +// PCI-RangeIndexList ::= SEQUENCE (SIZE (1..8)) OF INTEGER (1..8) +using pci_range_idx_list_l = bounded_array; - void destroy_(); - }; - struct qcl_type_opts { - enum options { type_a, type_b, type_c, type_d, nulltype } value; +// PeriodicalReportConfig ::= SEQUENCE +struct periodical_report_cfg_s { + struct report_amount_opts { + enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; + typedef int8_t number_type; std::string to_string() const; + int8_t to_number() const; }; - typedef enumerated qcl_type_e_; + typedef enumerated report_amount_e_; // member variables - bool ext = false; - bool cell_present = false; - bool bwp_id_present = false; - uint8_t cell = 0; - uint8_t bwp_id = 0; - ref_sig_c_ ref_sig; - qcl_type_e_ qcl_type; + bool ext = false; + bool report_quant_rs_idxes_present = false; + bool max_nrof_rs_idxes_to_report_present = false; + nr_rs_type_e rs_type; + report_interv_e report_interv; + report_amount_e_ report_amount; + meas_report_quant_s report_quant_cell; + uint8_t max_report_cells = 1; + meas_report_quant_s report_quant_rs_idxes; + uint8_t max_nrof_rs_idxes_to_report = 1; + bool include_beam_meass = false; + bool use_white_cell_list = false; // ... // sequence methods @@ -5983,30 +5913,23 @@ struct qcl_info_s { void to_json(json_writer& j) const; }; -// RA-Prioritization ::= SEQUENCE -struct ra_prioritization_s { - struct pwr_ramp_step_high_prio_opts { - enum options { db0, db2, db4, db6, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated pwr_ramp_step_high_prio_e_; - struct scaling_factor_bi_opts { - enum options { zero, dot25, dot5, dot75, nulltype } value; - typedef uint8_t number_type; +// PeriodicalReportConfigInterRAT ::= SEQUENCE +struct periodical_report_cfg_inter_rat_s { + struct report_amount_opts { + enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; + typedef int8_t number_type; std::string to_string() const; - uint8_t to_number() const; + int8_t to_number() const; }; - typedef enumerated scaling_factor_bi_e_; + typedef enumerated report_amount_e_; // member variables - bool ext = false; - bool scaling_factor_bi_present = false; - pwr_ramp_step_high_prio_e_ pwr_ramp_step_high_prio; - scaling_factor_bi_e_ scaling_factor_bi; + bool ext = false; + report_interv_e report_interv; + report_amount_e_ report_amount; + meas_report_quant_s report_quant; + uint8_t max_report_cells = 1; // ... // sequence methods @@ -6015,227 +5938,176 @@ struct ra_prioritization_s { void to_json(json_writer& j) const; }; -// SRS-Resource ::= SEQUENCE -struct srs_res_s { - struct nrof_srs_ports_opts { - enum options { port1, ports2, ports4, nulltype } value; - typedef uint8_t number_type; +// RAN-AreaConfig ::= SEQUENCE +struct ran_area_cfg_s { + using ran_area_code_list_l_ = bounded_array; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated nrof_srs_ports_e_; - struct ptrs_port_idx_opts { - enum options { n0, n1, nulltype } value; - typedef uint8_t number_type; + // member variables + bool ran_area_code_list_present = false; + fixed_bitstring<24> tac; + ran_area_code_list_l_ ran_area_code_list; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated ptrs_port_idx_e_; - struct tx_comb_c_ { - struct n2_s_ { - uint8_t comb_offset_n2 = 0; - uint8_t cyclic_shift_n2 = 0; - }; - struct n4_s_ { - uint8_t comb_offset_n4 = 0; - uint8_t cyclic_shift_n4 = 0; - }; - struct types_opts { - enum options { n2, n4, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; +// ReferenceSignalConfig ::= SEQUENCE +struct ref_sig_cfg_s { + bool ssb_cfg_mob_present = false; + bool csi_rs_res_cfg_mob_present = false; + ssb_cfg_mob_s ssb_cfg_mob; + setup_release_c csi_rs_res_cfg_mob; - // choice methods - tx_comb_c_() = default; - tx_comb_c_(const tx_comb_c_& other); - tx_comb_c_& operator=(const tx_comb_c_& other); - ~tx_comb_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - n2_s_& n2() - { - assert_choice_type("n2", type_.to_string(), "transmissionComb"); - return c.get(); - } - n4_s_& n4() - { - assert_choice_type("n4", type_.to_string(), "transmissionComb"); - return c.get(); - } - const n2_s_& n2() const - { - assert_choice_type("n2", type_.to_string(), "transmissionComb"); - return c.get(); - } - const n4_s_& n4() const - { - assert_choice_type("n4", type_.to_string(), "transmissionComb"); - return c.get(); - } - n2_s_& set_n2() - { - set(types::n2); - return c.get(); - } - n4_s_& set_n4() - { - set(types::n4); - return c.get(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - choice_buffer_t c; +// ReportCGI ::= SEQUENCE +struct report_cgi_s { + bool ext = false; + uint16_t cell_for_which_to_report_cgi = 0; + // ... - void destroy_(); - }; - struct res_map_s_ { - struct nrof_symbols_opts { - enum options { n1, n2, n4, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated nrof_symbols_e_; - struct repeat_factor_opts { - enum options { n1, n2, n4, nulltype } value; - typedef uint8_t number_type; +// ReportCGI-EUTRA ::= SEQUENCE +struct report_cgi_eutra_s { + bool ext = false; + uint16_t cell_for_which_to_report_cgi = 0; + // ... - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated repeat_factor_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - uint8_t start_position = 0; - nrof_symbols_e_ nrof_symbols; - repeat_factor_e_ repeat_factor; - }; - struct freq_hop_s_ { - uint8_t c_srs = 0; - uint8_t b_srs = 0; - uint8_t b_hop = 0; - }; - struct group_or_seq_hop_opts { - enum options { neither, group_hop, seq_hop, nulltype } value; +// ReportSFTD-EUTRA ::= SEQUENCE +struct report_sftd_eutra_s { + bool ext = false; + bool report_sftd_meas = false; + bool report_rsrp = false; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// ReportSFTD-NR ::= SEQUENCE +struct report_sftd_nr_s { + using cells_for_which_to_report_sftd_l_ = bounded_array; + + // member variables + bool ext = false; + bool report_sftd_meas = false; + bool report_rsrp = false; + // ... + // group 0 + bool report_sftd_neigh_meas_present = false; + bool drx_sftd_neigh_meas_present = false; + copy_ptr cells_for_which_to_report_sftd; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SSB-MTC2 ::= SEQUENCE +struct ssb_mtc2_s { + using pci_list_l_ = dyn_array; + struct periodicity_opts { + enum options { sf5, sf10, sf20, sf40, sf80, spare3, spare2, spare1, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated group_or_seq_hop_e_; - struct res_type_c_ { - struct aperiodic_s_ { - bool ext = false; - // ... - }; - struct semi_persistent_s_ { - bool ext = false; - srs_periodicity_and_offset_c periodicity_and_offset_sp; - // ... - }; - struct periodic_s_ { - bool ext = false; - srs_periodicity_and_offset_c periodicity_and_offset_p; - // ... - }; + typedef enumerated periodicity_e_; + + // member variables + bool pci_list_present = false; + pci_list_l_ pci_list; + periodicity_e_ periodicity; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MRDC-SecondaryCellGroupConfig ::= SEQUENCE +struct mrdc_secondary_cell_group_cfg_s { + struct mrdc_secondary_cell_group_c_ { struct types_opts { - enum options { aperiodic, semi_persistent, periodic, nulltype } value; + enum options { nr_scg, eutra_scg, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - res_type_c_() = default; - res_type_c_(const res_type_c_& other); - res_type_c_& operator=(const res_type_c_& other); - ~res_type_c_() { destroy_(); } + mrdc_secondary_cell_group_c_() = default; + mrdc_secondary_cell_group_c_(const mrdc_secondary_cell_group_c_& other); + mrdc_secondary_cell_group_c_& operator=(const mrdc_secondary_cell_group_c_& other); + ~mrdc_secondary_cell_group_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - aperiodic_s_& aperiodic() - { - assert_choice_type("aperiodic", type_.to_string(), "resourceType"); - return c.get(); - } - semi_persistent_s_& semi_persistent() - { - assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); - return c.get(); - } - periodic_s_& periodic() - { - assert_choice_type("periodic", type_.to_string(), "resourceType"); - return c.get(); - } - const aperiodic_s_& aperiodic() const + dyn_octstring& nr_scg() { - assert_choice_type("aperiodic", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("nr-SCG", type_.to_string(), "mrdc-SecondaryCellGroup"); + return c.get(); } - const semi_persistent_s_& semi_persistent() const + dyn_octstring& eutra_scg() { - assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("eutra-SCG", type_.to_string(), "mrdc-SecondaryCellGroup"); + return c.get(); } - const periodic_s_& periodic() const + const dyn_octstring& nr_scg() const { - assert_choice_type("periodic", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("nr-SCG", type_.to_string(), "mrdc-SecondaryCellGroup"); + return c.get(); } - aperiodic_s_& set_aperiodic() + const dyn_octstring& eutra_scg() const { - set(types::aperiodic); - return c.get(); + assert_choice_type("eutra-SCG", type_.to_string(), "mrdc-SecondaryCellGroup"); + return c.get(); } - semi_persistent_s_& set_semi_persistent() + dyn_octstring& set_nr_scg() { - set(types::semi_persistent); - return c.get(); + set(types::nr_scg); + return c.get(); } - periodic_s_& set_periodic() + dyn_octstring& set_eutra_scg() { - set(types::periodic); - return c.get(); + set(types::eutra_scg); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; // member variables - bool ext = false; - bool ptrs_port_idx_present = false; - bool spatial_relation_info_present = false; - uint8_t srs_res_id = 0; - nrof_srs_ports_e_ nrof_srs_ports; - ptrs_port_idx_e_ ptrs_port_idx; - tx_comb_c_ tx_comb; - res_map_s_ res_map; - uint8_t freq_domain_position = 0; - uint16_t freq_domain_shift = 0; - freq_hop_s_ freq_hop; - group_or_seq_hop_e_ group_or_seq_hop; - res_type_c_ res_type; - uint16_t seq_id = 0; - srs_spatial_relation_info_s spatial_relation_info; - // ... + bool mrdc_release_and_add_present = false; + mrdc_secondary_cell_group_c_ mrdc_secondary_cell_group; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -6243,198 +6115,449 @@ struct srs_res_s { void to_json(json_writer& j) const; }; -// SRS-ResourceSet ::= SEQUENCE -struct srs_res_set_s { - using srs_res_id_list_l_ = bounded_array; - struct res_type_c_ { - struct aperiodic_s_ { - using aperiodic_srs_res_trigger_list_v1530_l_ = bounded_array; - - // member variables - bool ext = false; - bool csi_rs_present = false; - bool slot_offset_present = false; - uint8_t aperiodic_srs_res_trigger = 1; - uint8_t csi_rs = 0; - uint8_t slot_offset = 1; - // ... - // group 0 - copy_ptr aperiodic_srs_res_trigger_list_v1530; +// MeasObjectEUTRA ::= SEQUENCE +struct meas_obj_eutra_s { + using cells_to_add_mod_list_eutran_l_ = dyn_array; + using black_cells_to_add_mod_list_eutran_l_ = dyn_array; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - }; - struct semi_persistent_s_ { - bool ext = false; - bool associated_csi_rs_present = false; - uint8_t associated_csi_rs = 0; - // ... - }; - struct periodic_s_ { - bool ext = false; - bool associated_csi_rs_present = false; - uint8_t associated_csi_rs = 0; - // ... - }; + // member variables + bool ext = false; + bool cells_to_rem_list_eutran_present = false; + bool cells_to_add_mod_list_eutran_present = false; + bool black_cells_to_rem_list_eutran_present = false; + bool black_cells_to_add_mod_list_eutran_present = false; + bool eutra_q_offset_range_present = false; + uint32_t carrier_freq = 0; + eutra_allowed_meas_bw_e allowed_meas_bw; + eutra_cell_idx_list_l cells_to_rem_list_eutran; + cells_to_add_mod_list_eutran_l_ cells_to_add_mod_list_eutran; + eutra_cell_idx_list_l black_cells_to_rem_list_eutran; + black_cells_to_add_mod_list_eutran_l_ black_cells_to_add_mod_list_eutran; + bool eutra_presence_ant_port1 = false; + eutra_q_offset_range_e eutra_q_offset_range; + bool wideband_rsrq_meas = false; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MeasObjectNR ::= SEQUENCE +struct meas_obj_nr_s { + using black_cells_to_add_mod_list_l_ = dyn_array; + using white_cells_to_add_mod_list_l_ = dyn_array; + struct meas_cycle_scell_opts { + enum options { sf160, sf256, sf320, sf512, sf640, sf1024, sf1280, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated meas_cycle_scell_e_; + + // member variables + bool ext = false; + bool ssb_freq_present = false; + bool ssb_subcarrier_spacing_present = false; + bool smtc1_present = false; + bool smtc2_present = false; + bool ref_freq_csi_rs_present = false; + bool abs_thresh_ss_blocks_consolidation_present = false; + bool abs_thresh_csi_rs_consolidation_present = false; + bool nrof_ss_blocks_to_average_present = false; + bool nrof_csi_rs_res_to_average_present = false; + bool cells_to_rem_list_present = false; + bool cells_to_add_mod_list_present = false; + bool black_cells_to_rem_list_present = false; + bool black_cells_to_add_mod_list_present = false; + bool white_cells_to_rem_list_present = false; + bool white_cells_to_add_mod_list_present = false; + uint32_t ssb_freq = 0; + subcarrier_spacing_e ssb_subcarrier_spacing; + ssb_mtc_s smtc1; + ssb_mtc2_s smtc2; + uint32_t ref_freq_csi_rs = 0; + ref_sig_cfg_s ref_sig_cfg; + thres_nr_s abs_thresh_ss_blocks_consolidation; + thres_nr_s abs_thresh_csi_rs_consolidation; + uint8_t nrof_ss_blocks_to_average = 2; + uint8_t nrof_csi_rs_res_to_average = 2; + uint8_t quant_cfg_idx = 1; + q_offset_range_list_s offset_mo; + pci_list_l cells_to_rem_list; + cells_to_add_mod_list_l cells_to_add_mod_list; + pci_range_idx_list_l black_cells_to_rem_list; + black_cells_to_add_mod_list_l_ black_cells_to_add_mod_list; + pci_range_idx_list_l white_cells_to_rem_list; + white_cells_to_add_mod_list_l_ white_cells_to_add_mod_list; + // ... + // group 0 + bool freq_band_ind_nr_present = false; + bool meas_cycle_scell_present = false; + uint16_t freq_band_ind_nr = 1; + meas_cycle_scell_e_ meas_cycle_scell; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// OverheatingAssistanceConfig ::= SEQUENCE +struct overheat_assist_cfg_s { + struct overheat_ind_prohibit_timer_opts { + enum options { + s0, + s0dot5, + s1, + s2, + s5, + s10, + s20, + s30, + s60, + s90, + s120, + s300, + s600, + spare3, + spare2, + spare1, + nulltype + } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated overheat_ind_prohibit_timer_e_; + + // member variables + overheat_ind_prohibit_timer_e_ overheat_ind_prohibit_timer; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PLMN-RAN-AreaCell ::= SEQUENCE +struct plmn_ran_area_cell_s { + using ran_area_cells_l_ = bounded_array, 32>; + + // member variables + bool plmn_id_present = false; + plmn_id_s plmn_id; + ran_area_cells_l_ ran_area_cells; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PLMN-RAN-AreaConfig ::= SEQUENCE +struct plmn_ran_area_cfg_s { + using ran_area_l_ = dyn_array; + + // member variables + bool plmn_id_present = false; + plmn_id_s plmn_id; + ran_area_l_ ran_area; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// QuantityConfigRS ::= SEQUENCE +struct quant_cfg_rs_s { + filt_cfg_s ssb_filt_cfg; + filt_cfg_s csi_rs_filt_cfg; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// ReportConfigInterRAT ::= SEQUENCE +struct report_cfg_inter_rat_s { + struct report_type_c_ { struct types_opts { - enum options { aperiodic, semi_persistent, periodic, nulltype } value; + enum options { periodical, event_triggered, report_cgi, /*...*/ report_sftd, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - res_type_c_() = default; - res_type_c_(const res_type_c_& other); - res_type_c_& operator=(const res_type_c_& other); - ~res_type_c_() { destroy_(); } + report_type_c_() = default; + report_type_c_(const report_type_c_& other); + report_type_c_& operator=(const report_type_c_& other); + ~report_type_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - aperiodic_s_& aperiodic() + periodical_report_cfg_inter_rat_s& periodical() { - assert_choice_type("aperiodic", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("periodical", type_.to_string(), "reportType"); + return c.get(); } - semi_persistent_s_& semi_persistent() + event_trigger_cfg_inter_rat_s& event_triggered() { - assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("eventTriggered", type_.to_string(), "reportType"); + return c.get(); } - periodic_s_& periodic() + report_cgi_eutra_s& report_cgi() { - assert_choice_type("periodic", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("reportCGI", type_.to_string(), "reportType"); + return c.get(); } - const aperiodic_s_& aperiodic() const + report_sftd_eutra_s& report_sftd() { - assert_choice_type("aperiodic", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("reportSFTD", type_.to_string(), "reportType"); + return c.get(); } - const semi_persistent_s_& semi_persistent() const + const periodical_report_cfg_inter_rat_s& periodical() const { - assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("periodical", type_.to_string(), "reportType"); + return c.get(); } - const periodic_s_& periodic() const + const event_trigger_cfg_inter_rat_s& event_triggered() const { - assert_choice_type("periodic", type_.to_string(), "resourceType"); - return c.get(); + assert_choice_type("eventTriggered", type_.to_string(), "reportType"); + return c.get(); } - aperiodic_s_& set_aperiodic() + const report_cgi_eutra_s& report_cgi() const { - set(types::aperiodic); - return c.get(); + assert_choice_type("reportCGI", type_.to_string(), "reportType"); + return c.get(); } - semi_persistent_s_& set_semi_persistent() + const report_sftd_eutra_s& report_sftd() const { - set(types::semi_persistent); - return c.get(); + assert_choice_type("reportSFTD", type_.to_string(), "reportType"); + return c.get(); } - periodic_s_& set_periodic() + periodical_report_cfg_inter_rat_s& set_periodical() { - set(types::periodic); - return c.get(); + set(types::periodical); + return c.get(); + } + event_trigger_cfg_inter_rat_s& set_event_triggered() + { + set(types::event_triggered); + return c.get(); + } + report_cgi_eutra_s& set_report_cgi() + { + set(types::report_cgi); + return c.get(); + } + report_sftd_eutra_s& set_report_sftd() + { + set(types::report_sftd); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t + c; void destroy_(); }; - struct usage_opts { - enum options { beam_management, codebook, non_codebook, ant_switching, nulltype } value; - std::string to_string() const; - }; - typedef enumerated usage_e_; - struct pathloss_ref_rs_c_ { - struct types_opts { - enum options { ssb_idx, csi_rs_idx, nulltype } value; + // member variables + report_type_c_ report_type; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// ReportConfigNR ::= SEQUENCE +struct report_cfg_nr_s { + struct report_type_c_ { + struct types_opts { + enum options { periodical, event_triggered, /*...*/ report_cgi, report_sftd, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - pathloss_ref_rs_c_() = default; - pathloss_ref_rs_c_(const pathloss_ref_rs_c_& other); - pathloss_ref_rs_c_& operator=(const pathloss_ref_rs_c_& other); - ~pathloss_ref_rs_c_() { destroy_(); } + report_type_c_() = default; + report_type_c_(const report_type_c_& other); + report_type_c_& operator=(const report_type_c_& other); + ~report_type_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& ssb_idx() + periodical_report_cfg_s& periodical() { - assert_choice_type("ssb-Index", type_.to_string(), "pathlossReferenceRS"); - return c.get(); + assert_choice_type("periodical", type_.to_string(), "reportType"); + return c.get(); } - uint8_t& csi_rs_idx() + event_trigger_cfg_s& event_triggered() { - assert_choice_type("csi-RS-Index", type_.to_string(), "pathlossReferenceRS"); - return c.get(); + assert_choice_type("eventTriggered", type_.to_string(), "reportType"); + return c.get(); } - const uint8_t& ssb_idx() const + report_cgi_s& report_cgi() { - assert_choice_type("ssb-Index", type_.to_string(), "pathlossReferenceRS"); - return c.get(); + assert_choice_type("reportCGI", type_.to_string(), "reportType"); + return c.get(); } - const uint8_t& csi_rs_idx() const + report_sftd_nr_s& report_sftd() { - assert_choice_type("csi-RS-Index", type_.to_string(), "pathlossReferenceRS"); - return c.get(); + assert_choice_type("reportSFTD", type_.to_string(), "reportType"); + return c.get(); } - uint8_t& set_ssb_idx() + const periodical_report_cfg_s& periodical() const { - set(types::ssb_idx); - return c.get(); + assert_choice_type("periodical", type_.to_string(), "reportType"); + return c.get(); } - uint8_t& set_csi_rs_idx() + const event_trigger_cfg_s& event_triggered() const { - set(types::csi_rs_idx); - return c.get(); + assert_choice_type("eventTriggered", type_.to_string(), "reportType"); + return c.get(); + } + const report_cgi_s& report_cgi() const + { + assert_choice_type("reportCGI", type_.to_string(), "reportType"); + return c.get(); + } + const report_sftd_nr_s& report_sftd() const + { + assert_choice_type("reportSFTD", type_.to_string(), "reportType"); + return c.get(); + } + periodical_report_cfg_s& set_periodical() + { + set(types::periodical); + return c.get(); + } + event_trigger_cfg_s& set_event_triggered() + { + set(types::event_triggered); + return c.get(); + } + report_cgi_s& set_report_cgi() + { + set(types::report_cgi); + return c.get(); + } + report_sftd_nr_s& set_report_sftd() + { + set(types::report_sftd); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct srs_pwr_ctrl_adjustment_states_opts { - enum options { same_as_fci2, separate_closed_loop, nulltype } value; + + // member variables + report_type_c_ report_type; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// FreqPriorityEUTRA ::= SEQUENCE +struct freq_prio_eutra_s { + bool cell_resel_sub_prio_present = false; + uint32_t carrier_freq = 0; + uint8_t cell_resel_prio = 0; + cell_resel_sub_prio_e cell_resel_sub_prio; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// FreqPriorityNR ::= SEQUENCE +struct freq_prio_nr_s { + bool cell_resel_sub_prio_present = false; + uint32_t carrier_freq = 0; + uint8_t cell_resel_prio = 0; + cell_resel_sub_prio_e cell_resel_sub_prio; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// GapConfig ::= SEQUENCE +struct gap_cfg_s { + struct mgl_opts { + enum options { ms1dot5, ms3, ms3dot5, ms4, ms5dot5, ms6, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated mgl_e_; + struct mgrp_opts { + enum options { ms20, ms40, ms80, ms160, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated srs_pwr_ctrl_adjustment_states_e_; + typedef enumerated mgrp_e_; + struct mgta_opts { + enum options { ms0, ms0dot25, ms0dot5, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated mgta_e_; + struct ref_serv_cell_ind_opts { + enum options { pcell, pscell, mcg_fr2, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated ref_serv_cell_ind_e_; // member variables - bool ext = false; - bool srs_res_id_list_present = false; - bool alpha_present = false; - bool p0_present = false; - bool pathloss_ref_rs_present = false; - bool srs_pwr_ctrl_adjustment_states_present = false; - uint8_t srs_res_set_id = 0; - srs_res_id_list_l_ srs_res_id_list; - res_type_c_ res_type; - usage_e_ usage; - alpha_e alpha; - int16_t p0 = -202; - pathloss_ref_rs_c_ pathloss_ref_rs; - srs_pwr_ctrl_adjustment_states_e_ srs_pwr_ctrl_adjustment_states; + bool ext = false; + uint8_t gap_offset = 0; + mgl_e_ mgl; + mgrp_e_ mgrp; + mgta_e_ mgta; // ... + // group 0 + bool ref_serv_cell_ind_present = false; + ref_serv_cell_ind_e_ ref_serv_cell_ind; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -6442,239 +6565,91 @@ struct srs_res_set_s { void to_json(json_writer& j) const; }; -// SchedulingRequestResourceConfig ::= SEQUENCE -struct sched_request_res_cfg_s { - struct periodicity_and_offset_c_ { +// MeasGapSharingScheme ::= ENUMERATED +struct meas_gap_sharing_scheme_opts { + enum options { scheme00, scheme01, scheme10, scheme11, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; +}; +typedef enumerated meas_gap_sharing_scheme_e; + +// MeasIdToAddMod ::= SEQUENCE +struct meas_id_to_add_mod_s { + uint8_t meas_id = 1; + uint8_t meas_obj_id = 1; + uint8_t report_cfg_id = 1; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MeasObjectToAddMod ::= SEQUENCE +struct meas_obj_to_add_mod_s { + struct meas_obj_c_ { struct types_opts { - enum options { - sym2, - sym6or7, - sl1, - sl2, - sl4, - sl5, - sl8, - sl10, - sl16, - sl20, - sl40, - sl80, - sl160, - sl320, - sl640, - nulltype - } value; + enum options { meas_obj_nr, /*...*/ meas_obj_eutra, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - periodicity_and_offset_c_() = default; - periodicity_and_offset_c_(const periodicity_and_offset_c_& other); - periodicity_and_offset_c_& operator=(const periodicity_and_offset_c_& other); - ~periodicity_and_offset_c_() { destroy_(); } + meas_obj_c_() = default; + meas_obj_c_(const meas_obj_c_& other); + meas_obj_c_& operator=(const meas_obj_c_& other); + ~meas_obj_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& sl2() + meas_obj_nr_s& meas_obj_nr() { - assert_choice_type("sl2", type_.to_string(), "periodicityAndOffset"); - return c.get(); + assert_choice_type("measObjectNR", type_.to_string(), "measObject"); + return c.get(); } - uint8_t& sl4() + meas_obj_eutra_s& meas_obj_eutra() { - assert_choice_type("sl4", type_.to_string(), "periodicityAndOffset"); - return c.get(); + assert_choice_type("measObjectEUTRA", type_.to_string(), "measObject"); + return c.get(); } - uint8_t& sl5() + const meas_obj_nr_s& meas_obj_nr() const { - assert_choice_type("sl5", type_.to_string(), "periodicityAndOffset"); - return c.get(); + assert_choice_type("measObjectNR", type_.to_string(), "measObject"); + return c.get(); } - uint8_t& sl8() + const meas_obj_eutra_s& meas_obj_eutra() const { - assert_choice_type("sl8", type_.to_string(), "periodicityAndOffset"); - return c.get(); + assert_choice_type("measObjectEUTRA", type_.to_string(), "measObject"); + return c.get(); } - uint8_t& sl10() + meas_obj_nr_s& set_meas_obj_nr() { - assert_choice_type("sl10", type_.to_string(), "periodicityAndOffset"); - return c.get(); + set(types::meas_obj_nr); + return c.get(); } - uint8_t& sl16() - { - assert_choice_type("sl16", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - uint8_t& sl20() - { - assert_choice_type("sl20", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - uint8_t& sl40() - { - assert_choice_type("sl40", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - uint8_t& sl80() - { - assert_choice_type("sl80", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - uint8_t& sl160() - { - assert_choice_type("sl160", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - uint16_t& sl320() - { - assert_choice_type("sl320", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - uint16_t& sl640() - { - assert_choice_type("sl640", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl2() const - { - assert_choice_type("sl2", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl4() const - { - assert_choice_type("sl4", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl5() const - { - assert_choice_type("sl5", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl8() const - { - assert_choice_type("sl8", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl10() const - { - assert_choice_type("sl10", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl16() const - { - assert_choice_type("sl16", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl20() const - { - assert_choice_type("sl20", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl40() const - { - assert_choice_type("sl40", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl80() const - { - assert_choice_type("sl80", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint8_t& sl160() const - { - assert_choice_type("sl160", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint16_t& sl320() const - { - assert_choice_type("sl320", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - const uint16_t& sl640() const - { - assert_choice_type("sl640", type_.to_string(), "periodicityAndOffset"); - return c.get(); - } - uint8_t& set_sl2() - { - set(types::sl2); - return c.get(); - } - uint8_t& set_sl4() - { - set(types::sl4); - return c.get(); - } - uint8_t& set_sl5() - { - set(types::sl5); - return c.get(); - } - uint8_t& set_sl8() - { - set(types::sl8); - return c.get(); - } - uint8_t& set_sl10() - { - set(types::sl10); - return c.get(); - } - uint8_t& set_sl16() - { - set(types::sl16); - return c.get(); - } - uint8_t& set_sl20() - { - set(types::sl20); - return c.get(); - } - uint8_t& set_sl40() - { - set(types::sl40); - return c.get(); - } - uint8_t& set_sl80() - { - set(types::sl80); - return c.get(); - } - uint8_t& set_sl160() - { - set(types::sl160); - return c.get(); - } - uint16_t& set_sl320() - { - set(types::sl320); - return c.get(); - } - uint16_t& set_sl640() + meas_obj_eutra_s& set_meas_obj_eutra() { - set(types::sl640); - return c.get(); + set(types::meas_obj_eutra); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; // member variables - bool periodicity_and_offset_present = false; - bool res_present = false; - uint8_t sched_request_res_id = 1; - uint8_t sched_request_id = 0; - periodicity_and_offset_c_ periodicity_and_offset; - uint8_t res = 0; + uint8_t meas_obj_id = 1; + meas_obj_c_ meas_obj; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -6682,76 +6657,123 @@ struct sched_request_res_cfg_s { void to_json(json_writer& j) const; }; -// UCI-OnPUSCH ::= SEQUENCE -struct uci_on_pusch_s { - struct beta_offsets_c_ { - using dynamic_l_ = std::array; +// OtherConfig-v1540 ::= SEQUENCE +struct other_cfg_v1540_s { + bool ext = false; + bool overheat_assist_cfg_present = false; + setup_release_c overheat_assist_cfg; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PLMN-RAN-AreaCellList ::= SEQUENCE (SIZE (1..8)) OF PLMN-RAN-AreaCell +using plmn_ran_area_cell_list_l = dyn_array; + +// PLMN-RAN-AreaConfigList ::= SEQUENCE (SIZE (1..8)) OF PLMN-RAN-AreaConfig +using plmn_ran_area_cfg_list_l = dyn_array; + +// QuantityConfigNR ::= SEQUENCE +struct quant_cfg_nr_s { + bool quant_cfg_rs_idx_present = false; + quant_cfg_rs_s quant_cfg_cell; + quant_cfg_rs_s quant_cfg_rs_idx; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RAT-Type ::= ENUMERATED +struct rat_type_opts { + enum options { nr, eutra_nr, eutra, spare1, /*...*/ nulltype } value; + + std::string to_string() const; +}; +typedef enumerated rat_type_e; + +// RRCReconfiguration-v1560-IEs ::= SEQUENCE +struct rrc_recfg_v1560_ies_s { + bool mrdc_secondary_cell_group_cfg_present = false; + bool radio_bearer_cfg2_present = false; + bool sk_counter_present = false; + bool non_crit_ext_present = false; + setup_release_c mrdc_secondary_cell_group_cfg; + dyn_octstring radio_bearer_cfg2; + uint32_t sk_counter = 0; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// ReportConfigToAddMod ::= SEQUENCE +struct report_cfg_to_add_mod_s { + struct report_cfg_c_ { struct types_opts { - enum options { dynamic_type, semi_static, nulltype } value; + enum options { report_cfg_nr, /*...*/ report_cfg_inter_rat, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - beta_offsets_c_() = default; - beta_offsets_c_(const beta_offsets_c_& other); - beta_offsets_c_& operator=(const beta_offsets_c_& other); - ~beta_offsets_c_() { destroy_(); } + report_cfg_c_() = default; + report_cfg_c_(const report_cfg_c_& other); + report_cfg_c_& operator=(const report_cfg_c_& other); + ~report_cfg_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - dynamic_l_& dynamic_type() + report_cfg_nr_s& report_cfg_nr() { - assert_choice_type("dynamic", type_.to_string(), "betaOffsets"); - return c.get(); + assert_choice_type("reportConfigNR", type_.to_string(), "reportConfig"); + return c.get(); } - beta_offsets_s& semi_static() + report_cfg_inter_rat_s& report_cfg_inter_rat() { - assert_choice_type("semiStatic", type_.to_string(), "betaOffsets"); - return c.get(); + assert_choice_type("reportConfigInterRAT", type_.to_string(), "reportConfig"); + return c.get(); } - const dynamic_l_& dynamic_type() const + const report_cfg_nr_s& report_cfg_nr() const { - assert_choice_type("dynamic", type_.to_string(), "betaOffsets"); - return c.get(); + assert_choice_type("reportConfigNR", type_.to_string(), "reportConfig"); + return c.get(); } - const beta_offsets_s& semi_static() const + const report_cfg_inter_rat_s& report_cfg_inter_rat() const { - assert_choice_type("semiStatic", type_.to_string(), "betaOffsets"); - return c.get(); + assert_choice_type("reportConfigInterRAT", type_.to_string(), "reportConfig"); + return c.get(); } - dynamic_l_& set_dynamic_type() + report_cfg_nr_s& set_report_cfg_nr() { - set(types::dynamic_type); - return c.get(); + set(types::report_cfg_nr); + return c.get(); } - beta_offsets_s& set_semi_static() + report_cfg_inter_rat_s& set_report_cfg_inter_rat() { - set(types::semi_static); - return c.get(); + set(types::report_cfg_inter_rat); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct scaling_opts { - enum options { f0p5, f0p65, f0p8, f1, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated scaling_e_; // member variables - bool beta_offsets_present = false; - beta_offsets_c_ beta_offsets; - scaling_e_ scaling; + uint8_t report_cfg_id = 1; + report_cfg_c_ report_cfg; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -6759,51 +6781,63 @@ struct uci_on_pusch_s { void to_json(json_writer& j) const; }; -// BeamFailureRecoveryConfig ::= SEQUENCE -struct beam_fail_recovery_cfg_s { - using candidate_beam_rs_list_l_ = dyn_array; - struct ssb_per_rach_occasion_opts { - enum options { one_eighth, one_fourth, one_half, one, two, four, eight, sixteen, nulltype } value; - typedef float number_type; +// CarrierInfoNR ::= SEQUENCE +struct carrier_info_nr_s { + bool ext = false; + bool smtc_present = false; + uint32_t carrier_freq = 0; + subcarrier_spacing_e ssb_subcarrier_spacing; + ssb_mtc_s smtc; + // ... - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated ssb_per_rach_occasion_e_; - struct beam_fail_recovery_timer_opts { - enum options { ms10, ms20, ms40, ms60, ms80, ms100, ms150, ms200, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated beam_fail_recovery_timer_e_; +// DRB-CountMSB-Info ::= SEQUENCE +struct drb_count_msb_info_s { + uint8_t drb_id = 1; + uint32_t count_msb_ul = 0; + uint32_t count_msb_dl = 0; - // member variables - bool ext = false; - bool root_seq_idx_bfr_present = false; - bool rach_cfg_bfr_present = false; - bool rsrp_thres_ssb_present = false; - bool candidate_beam_rs_list_present = false; - bool ssb_per_rach_occasion_present = false; - bool ra_ssb_occasion_mask_idx_present = false; - bool recovery_search_space_id_present = false; - bool ra_prioritization_present = false; - bool beam_fail_recovery_timer_present = false; - uint8_t root_seq_idx_bfr = 0; - rach_cfg_generic_s rach_cfg_bfr; - uint8_t rsrp_thres_ssb = 0; - candidate_beam_rs_list_l_ candidate_beam_rs_list; - ssb_per_rach_occasion_e_ ssb_per_rach_occasion; - uint8_t ra_ssb_occasion_mask_idx = 0; - uint8_t recovery_search_space_id = 0; - ra_prioritization_s ra_prioritization; - beam_fail_recovery_timer_e_ beam_fail_recovery_timer; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// FreqPriorityListEUTRA ::= SEQUENCE (SIZE (1..8)) OF FreqPriorityEUTRA +using freq_prio_list_eutra_l = dyn_array; + +// FreqPriorityListNR ::= SEQUENCE (SIZE (1..8)) OF FreqPriorityNR +using freq_prio_list_nr_l = dyn_array; + +// MasterKeyUpdate ::= SEQUENCE +struct master_key_upd_s { + bool ext = false; + bool nas_container_present = false; + bool key_set_change_ind = false; + uint8_t next_hop_chaining_count = 0; + dyn_octstring nas_container; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MeasGapConfig ::= SEQUENCE +struct meas_gap_cfg_s { + bool ext = false; + bool gap_fr2_present = false; + setup_release_c gap_fr2; // ... // group 0 - bool msg1_subcarrier_spacing_v1530_present = false; - subcarrier_spacing_e msg1_subcarrier_spacing_v1530; + copy_ptr > gap_fr1; + copy_ptr > gap_ue; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -6811,82 +6845,90 @@ struct beam_fail_recovery_cfg_s { void to_json(json_writer& j) const; }; -// CSI-AssociatedReportConfigInfo ::= SEQUENCE -struct csi_associated_report_cfg_info_s { - struct res_for_ch_c_ { - struct nzp_csi_rs_s_ { - using qcl_info_l_ = bounded_array; +// MeasGapSharingConfig ::= SEQUENCE +struct meas_gap_sharing_cfg_s { + bool ext = false; + bool gap_sharing_fr2_present = false; + setup_release_c gap_sharing_fr2; + // ... + // group 0 + copy_ptr > gap_sharing_fr1; + copy_ptr > gap_sharing_ue; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MeasIdToAddModList ::= SEQUENCE (SIZE (1..64)) OF MeasIdToAddMod +using meas_id_to_add_mod_list_l = dyn_array; + +// MeasIdToRemoveList ::= SEQUENCE (SIZE (1..64)) OF INTEGER (1..64) +using meas_id_to_rem_list_l = dyn_array; + +// MeasObjectToAddModList ::= SEQUENCE (SIZE (1..64)) OF MeasObjectToAddMod +using meas_obj_to_add_mod_list_l = dyn_array; + +// MeasObjectToRemoveList ::= SEQUENCE (SIZE (1..64)) OF INTEGER (1..64) +using meas_obj_to_rem_list_l = dyn_array; + +// OtherConfig ::= SEQUENCE +struct other_cfg_s { + struct delay_budget_report_cfg_c_ { + struct setup_s_ { + struct delay_budget_report_prohibit_timer_opts { + enum options { s0, s0dot4, s0dot8, s1dot6, s3, s6, s12, s30, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated delay_budget_report_prohibit_timer_e_; // member variables - bool qcl_info_present = false; - uint8_t res_set = 1; - qcl_info_l_ qcl_info; + delay_budget_report_prohibit_timer_e_ delay_budget_report_prohibit_timer; }; struct types_opts { - enum options { nzp_csi_rs, csi_ssb_res_set, nulltype } value; + enum options { release, setup, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - res_for_ch_c_() = default; - res_for_ch_c_(const res_for_ch_c_& other); - res_for_ch_c_& operator=(const res_for_ch_c_& other); - ~res_for_ch_c_() { destroy_(); } + delay_budget_report_cfg_c_() = default; void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - nzp_csi_rs_s_& nzp_csi_rs() - { - assert_choice_type("nzp-CSI-RS", type_.to_string(), "resourcesForChannel"); - return c.get(); - } - uint8_t& csi_ssb_res_set() - { - assert_choice_type("csi-SSB-ResourceSet", type_.to_string(), "resourcesForChannel"); - return c.get(); - } - const nzp_csi_rs_s_& nzp_csi_rs() const - { - assert_choice_type("nzp-CSI-RS", type_.to_string(), "resourcesForChannel"); - return c.get(); - } - const uint8_t& csi_ssb_res_set() const + setup_s_& setup() { - assert_choice_type("csi-SSB-ResourceSet", type_.to_string(), "resourcesForChannel"); - return c.get(); + assert_choice_type("setup", type_.to_string(), "delayBudgetReportingConfig"); + return c; } - nzp_csi_rs_s_& set_nzp_csi_rs() + const setup_s_& setup() const { - set(types::nzp_csi_rs); - return c.get(); + assert_choice_type("setup", type_.to_string(), "delayBudgetReportingConfig"); + return c; } - uint8_t& set_csi_ssb_res_set() + setup_s_& set_setup() { - set(types::csi_ssb_res_set); - return c.get(); + set(types::setup); + return c; } private: - types type_; - choice_buffer_t c; - - void destroy_(); + types type_; + setup_s_ c; }; // member variables - bool ext = false; - bool csi_im_res_for_interference_present = false; - bool nzp_csi_rs_res_for_interference_present = false; - uint8_t report_cfg_id = 0; - res_for_ch_c_ res_for_ch; - uint8_t csi_im_res_for_interference = 1; - uint8_t nzp_csi_rs_res_for_interference = 1; - // ... + bool delay_budget_report_cfg_present = false; + delay_budget_report_cfg_c_ delay_budget_report_cfg; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -6894,166 +6936,98 @@ struct csi_associated_report_cfg_info_s { void to_json(json_writer& j) const; }; -// ConfiguredGrantConfig ::= SEQUENCE -struct cfgured_grant_cfg_s { - struct freq_hop_opts { - enum options { intra_slot, inter_slot, nulltype } value; +// PeriodicRNAU-TimerValue ::= ENUMERATED +struct periodic_rnau_timer_value_opts { + enum options { min5, min10, min20, min30, min60, min120, min360, min720, nulltype } value; + typedef uint16_t number_type; - std::string to_string() const; - }; - typedef enumerated freq_hop_e_; - struct mcs_table_opts { - enum options { qam256, qam64_low_se, nulltype } value; - typedef uint16_t number_type; + std::string to_string() const; + uint16_t to_number() const; +}; +typedef enumerated periodic_rnau_timer_value_e; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated mcs_table_e_; - struct mcs_table_transform_precoder_opts { - enum options { qam256, qam64_low_se, nulltype } value; - typedef uint16_t number_type; +// QuantityConfig ::= SEQUENCE +struct quant_cfg_s { + using quant_cfg_nr_list_l_ = dyn_array; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated mcs_table_transform_precoder_e_; - struct res_alloc_opts { - enum options { res_alloc_type0, res_alloc_type1, dynamic_switch, nulltype } value; - typedef uint8_t number_type; + // member variables + bool ext = false; + bool quant_cfg_nr_list_present = false; + quant_cfg_nr_list_l_ quant_cfg_nr_list; + // ... + // group 0 + copy_ptr quant_cfg_eutra; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated res_alloc_e_; - struct pwr_ctrl_loop_to_use_opts { - enum options { n0, n1, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated pwr_ctrl_loop_to_use_e_; - struct transform_precoder_opts { - enum options { enabled, disabled, nulltype } value; +// RAN-NotificationAreaInfo ::= CHOICE +struct ran_notif_area_info_c { + struct types_opts { + enum options { cell_list, ran_area_cfg_list, /*...*/ nulltype } value; std::string to_string() const; }; - typedef enumerated transform_precoder_e_; - struct rep_k_opts { - enum options { n1, n2, n4, n8, nulltype } value; - typedef uint8_t number_type; + typedef enumerated types; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated rep_k_e_; - struct rep_k_rv_opts { - enum options { s1_minus0231, s2_minus0303, s3_minus0000, nulltype } value; - typedef uint8_t number_type; + // choice methods + ran_notif_area_info_c() = default; + ran_notif_area_info_c(const ran_notif_area_info_c& other); + ran_notif_area_info_c& operator=(const ran_notif_area_info_c& other); + ~ran_notif_area_info_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + plmn_ran_area_cell_list_l& cell_list() + { + assert_choice_type("cellList", type_.to_string(), "RAN-NotificationAreaInfo"); + return c.get(); + } + plmn_ran_area_cfg_list_l& ran_area_cfg_list() + { + assert_choice_type("ran-AreaConfigList", type_.to_string(), "RAN-NotificationAreaInfo"); + return c.get(); + } + const plmn_ran_area_cell_list_l& cell_list() const + { + assert_choice_type("cellList", type_.to_string(), "RAN-NotificationAreaInfo"); + return c.get(); + } + const plmn_ran_area_cfg_list_l& ran_area_cfg_list() const + { + assert_choice_type("ran-AreaConfigList", type_.to_string(), "RAN-NotificationAreaInfo"); + return c.get(); + } + plmn_ran_area_cell_list_l& set_cell_list() + { + set(types::cell_list); + return c.get(); + } + plmn_ran_area_cfg_list_l& set_ran_area_cfg_list() + { + set(types::ran_area_cfg_list); + return c.get(); + } - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated rep_k_rv_e_; - struct periodicity_opts { - enum options { - sym2, - sym7, - sym1x14, - sym2x14, - sym4x14, - sym5x14, - sym8x14, - sym10x14, - sym16x14, - sym20x14, - sym32x14, - sym40x14, - sym64x14, - sym80x14, - sym128x14, - sym160x14, - sym256x14, - sym320x14, - sym512x14, - sym640x14, - sym1024x14, - sym1280x14, - sym2560x14, - sym5120x14, - sym6, - sym1x12, - sym2x12, - sym4x12, - sym5x12, - sym8x12, - sym10x12, - sym16x12, - sym20x12, - sym32x12, - sym40x12, - sym64x12, - sym80x12, - sym128x12, - sym160x12, - sym256x12, - sym320x12, - sym512x12, - sym640x12, - sym1280x12, - sym2560x12, - nulltype - } value; +private: + types type_; + choice_buffer_t c; - std::string to_string() const; - }; - typedef enumerated periodicity_e_; - struct rrc_cfgured_ul_grant_s_ { - bool ext = false; - bool dmrs_seq_initization_present = false; - bool srs_res_ind_present = false; - bool freq_hop_offset_present = false; - uint16_t time_domain_offset = 0; - uint8_t time_domain_alloc = 0; - fixed_bitstring<18> freq_domain_alloc; - uint8_t ant_port = 0; - uint8_t dmrs_seq_initization = 0; - uint8_t precoding_and_nof_layers = 0; - uint8_t srs_res_ind = 0; - uint8_t mcs_and_tbs = 0; - uint16_t freq_hop_offset = 1; - uint8_t pathloss_ref_idx = 0; - // ... - }; + void destroy_(); +}; - // member variables - bool ext = false; - bool freq_hop_present = false; - bool mcs_table_present = false; - bool mcs_table_transform_precoder_present = false; - bool uci_on_pusch_present = false; - bool rbg_size_present = false; - bool transform_precoder_present = false; - bool rep_k_rv_present = false; - bool cfgured_grant_timer_present = false; - bool rrc_cfgured_ul_grant_present = false; - freq_hop_e_ freq_hop; - dmrs_ul_cfg_s cg_dmrs_cfg; - mcs_table_e_ mcs_table; - mcs_table_transform_precoder_e_ mcs_table_transform_precoder; - setup_release_c uci_on_pusch; - res_alloc_e_ res_alloc; - pwr_ctrl_loop_to_use_e_ pwr_ctrl_loop_to_use; - uint8_t p0_pusch_alpha = 0; - transform_precoder_e_ transform_precoder; - uint8_t nrof_harq_processes = 1; - rep_k_e_ rep_k; - rep_k_rv_e_ rep_k_rv; - periodicity_e_ periodicity; - uint8_t cfgured_grant_timer = 1; - rrc_cfgured_ul_grant_s_ rrc_cfgured_ul_grant; - // ... +// RRCReconfiguration-v1540-IEs ::= SEQUENCE +struct rrc_recfg_v1540_ies_s { + bool other_cfg_v1540_present = false; + bool non_crit_ext_present = false; + other_cfg_v1540_s other_cfg_v1540; + rrc_recfg_v1560_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7061,30 +7035,21 @@ struct cfgured_grant_cfg_s { void to_json(json_writer& j) const; }; -// DMRS-DownlinkConfig ::= SEQUENCE -struct dmrs_dl_cfg_s { - struct dmrs_add_position_opts { - enum options { pos0, pos1, pos3, nulltype } value; +// RedirectedCarrierInfo-EUTRA ::= SEQUENCE +struct redirected_carrier_info_eutra_s { + struct cn_type_opts { + enum options { epc, five_gc, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated dmrs_add_position_e_; + typedef enumerated cn_type_e_; // member variables - bool ext = false; - bool dmrs_type_present = false; - bool dmrs_add_position_present = false; - bool max_len_present = false; - bool scrambling_id0_present = false; - bool scrambling_id1_present = false; - bool phase_tracking_rs_present = false; - dmrs_add_position_e_ dmrs_add_position; - uint32_t scrambling_id0 = 0; - uint32_t scrambling_id1 = 0; - setup_release_c phase_tracking_rs; - // ... + bool cn_type_present = false; + uint32_t eutra_freq = 0; + cn_type_e_ cn_type; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7092,24 +7057,18 @@ struct dmrs_dl_cfg_s { void to_json(json_writer& j) const; }; -// DownlinkPreemption ::= SEQUENCE -struct dl_preemption_s { - struct time_freq_set_opts { - enum options { set0, set1, nulltype } value; - typedef uint8_t number_type; +// ReportConfigToAddModList ::= SEQUENCE (SIZE (1..64)) OF ReportConfigToAddMod +using report_cfg_to_add_mod_list_l = dyn_array; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated time_freq_set_e_; - using int_cfg_per_serving_cell_l_ = dyn_array; +// ReportConfigToRemoveList ::= SEQUENCE (SIZE (1..64)) OF INTEGER (1..64) +using report_cfg_to_rem_list_l = dyn_array; - // member variables - bool ext = false; - uint32_t int_rnti = 0; - time_freq_set_e_ time_freq_set; - uint8_t dci_payload_size = 0; - int_cfg_per_serving_cell_l_ int_cfg_per_serving_cell; +// UE-CapabilityRAT-Request ::= SEQUENCE +struct ue_cap_rat_request_s { + bool ext = false; + bool cap_request_filt_present = false; + rat_type_e rat_type; + dyn_octstring cap_request_filt; // ... // sequence methods @@ -7118,140 +7077,117 @@ struct dl_preemption_s { void to_json(json_writer& j) const; }; -// EUTRA-MBSFN-SubframeConfig ::= SEQUENCE -struct eutra_mbsfn_sf_cfg_s { - struct radioframe_alloc_period_opts { - enum options { n1, n2, n4, n8, n16, n32, nulltype } value; +// CellReselectionPriorities ::= SEQUENCE +struct cell_resel_priorities_s { + struct t320_opts { + enum options { min5, min10, min20, min30, min60, min120, min180, spare1, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated radioframe_alloc_period_e_; - struct sf_alloc1_c_ { - struct types_opts { - enum options { one_frame, four_frames, nulltype } value; - typedef uint8_t number_type; + typedef enumerated t320_e_; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; + // member variables + bool ext = false; + bool freq_prio_list_eutra_present = false; + bool freq_prio_list_nr_present = false; + bool t320_present = false; + freq_prio_list_eutra_l freq_prio_list_eutra; + freq_prio_list_nr_l freq_prio_list_nr; + t320_e_ t320; + // ... - // choice methods - sf_alloc1_c_() = default; - sf_alloc1_c_(const sf_alloc1_c_& other); - sf_alloc1_c_& operator=(const sf_alloc1_c_& other); - ~sf_alloc1_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<6>& one_frame() - { - assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation1"); - return c.get >(); - } - fixed_bitstring<24>& four_frames() - { - assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation1"); - return c.get >(); - } - const fixed_bitstring<6>& one_frame() const - { - assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation1"); - return c.get >(); - } - const fixed_bitstring<24>& four_frames() const - { - assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation1"); - return c.get >(); - } - fixed_bitstring<6>& set_one_frame() - { - set(types::one_frame); - return c.get >(); - } - fixed_bitstring<24>& set_four_frames() - { - set(types::four_frames); - return c.get >(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - choice_buffer_t > c; +// DRB-CountMSB-InfoList ::= SEQUENCE (SIZE (1..29)) OF DRB-CountMSB-Info +using drb_count_msb_info_list_l = dyn_array; - void destroy_(); - }; - struct sf_alloc2_c_ { +// MeasConfig ::= SEQUENCE +struct meas_cfg_s { + struct s_measure_cfg_c_ { struct types_opts { - enum options { one_frame, four_frames, nulltype } value; - typedef uint8_t number_type; + enum options { ssb_rsrp, csi_rsrp, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; typedef enumerated types; // choice methods - sf_alloc2_c_() = default; - sf_alloc2_c_(const sf_alloc2_c_& other); - sf_alloc2_c_& operator=(const sf_alloc2_c_& other); - ~sf_alloc2_c_() { destroy_(); } + s_measure_cfg_c_() = default; + s_measure_cfg_c_(const s_measure_cfg_c_& other); + s_measure_cfg_c_& operator=(const s_measure_cfg_c_& other); + ~s_measure_cfg_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - fixed_bitstring<2>& one_frame() + uint8_t& ssb_rsrp() { - assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation2"); - return c.get >(); + assert_choice_type("ssb-RSRP", type_.to_string(), "s-MeasureConfig"); + return c.get(); } - fixed_bitstring<8>& four_frames() + uint8_t& csi_rsrp() { - assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation2"); - return c.get >(); + assert_choice_type("csi-RSRP", type_.to_string(), "s-MeasureConfig"); + return c.get(); } - const fixed_bitstring<2>& one_frame() const + const uint8_t& ssb_rsrp() const { - assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation2"); - return c.get >(); + assert_choice_type("ssb-RSRP", type_.to_string(), "s-MeasureConfig"); + return c.get(); } - const fixed_bitstring<8>& four_frames() const + const uint8_t& csi_rsrp() const { - assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation2"); - return c.get >(); + assert_choice_type("csi-RSRP", type_.to_string(), "s-MeasureConfig"); + return c.get(); } - fixed_bitstring<2>& set_one_frame() + uint8_t& set_ssb_rsrp() { - set(types::one_frame); - return c.get >(); + set(types::ssb_rsrp); + return c.get(); } - fixed_bitstring<8>& set_four_frames() + uint8_t& set_csi_rsrp() { - set(types::four_frames); - return c.get >(); + set(types::csi_rsrp); + return c.get(); } private: - types type_; - choice_buffer_t > c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; // member variables - bool ext = false; - bool sf_alloc2_present = false; - radioframe_alloc_period_e_ radioframe_alloc_period; - uint8_t radioframe_alloc_offset = 0; - sf_alloc1_c_ sf_alloc1; - sf_alloc2_c_ sf_alloc2; + bool ext = false; + bool meas_obj_to_rem_list_present = false; + bool meas_obj_to_add_mod_list_present = false; + bool report_cfg_to_rem_list_present = false; + bool report_cfg_to_add_mod_list_present = false; + bool meas_id_to_rem_list_present = false; + bool meas_id_to_add_mod_list_present = false; + bool s_measure_cfg_present = false; + bool quant_cfg_present = false; + bool meas_gap_cfg_present = false; + bool meas_gap_sharing_cfg_present = false; + meas_obj_to_rem_list_l meas_obj_to_rem_list; + meas_obj_to_add_mod_list_l meas_obj_to_add_mod_list; + report_cfg_to_rem_list_l report_cfg_to_rem_list; + report_cfg_to_add_mod_list_l report_cfg_to_add_mod_list; + meas_id_to_rem_list_l meas_id_to_rem_list; + meas_id_to_add_mod_list_l meas_id_to_add_mod_list; + s_measure_cfg_c_ s_measure_cfg; + quant_cfg_s quant_cfg; + meas_gap_cfg_s meas_gap_cfg; + meas_gap_sharing_cfg_s meas_gap_sharing_cfg; // ... // sequence methods @@ -7260,55 +7196,26 @@ struct eutra_mbsfn_sf_cfg_s { void to_json(json_writer& j) const; }; -// MultiFrequencyBandListNR ::= SEQUENCE (SIZE (1..8)) OF INTEGER (1..1024) -using multi_freq_band_list_nr_l = bounded_array; - -// PUCCH-Config ::= SEQUENCE -struct pucch_cfg_s { - using res_set_to_add_mod_list_l_ = dyn_array; - using res_set_to_release_list_l_ = bounded_array; - using res_to_add_mod_list_l_ = dyn_array; - using res_to_release_list_l_ = dyn_array; - using sched_request_res_to_add_mod_list_l_ = dyn_array; - using sched_request_res_to_release_list_l_ = bounded_array; - using multi_csi_pucch_res_list_l_ = bounded_array; - using dl_data_to_ul_ack_l_ = bounded_array; - using spatial_relation_info_to_add_mod_list_l_ = dyn_array; - using spatial_relation_info_to_release_list_l_ = bounded_array; +// RRCReconfiguration-v1530-IEs ::= SEQUENCE +struct rrc_recfg_v1530_ies_s { + using ded_nas_msg_list_l_ = bounded_array; // member variables - bool ext = false; - bool res_set_to_add_mod_list_present = false; - bool res_set_to_release_list_present = false; - bool res_to_add_mod_list_present = false; - bool res_to_release_list_present = false; - bool format1_present = false; - bool format2_present = false; - bool format3_present = false; - bool format4_present = false; - bool sched_request_res_to_add_mod_list_present = false; - bool sched_request_res_to_release_list_present = false; - bool multi_csi_pucch_res_list_present = false; - bool dl_data_to_ul_ack_present = false; - bool spatial_relation_info_to_add_mod_list_present = false; - bool spatial_relation_info_to_release_list_present = false; - bool pucch_pwr_ctrl_present = false; - res_set_to_add_mod_list_l_ res_set_to_add_mod_list; - res_set_to_release_list_l_ res_set_to_release_list; - res_to_add_mod_list_l_ res_to_add_mod_list; - res_to_release_list_l_ res_to_release_list; - setup_release_c format1; - setup_release_c format2; - setup_release_c format3; - setup_release_c format4; - sched_request_res_to_add_mod_list_l_ sched_request_res_to_add_mod_list; - sched_request_res_to_release_list_l_ sched_request_res_to_release_list; - multi_csi_pucch_res_list_l_ multi_csi_pucch_res_list; - dl_data_to_ul_ack_l_ dl_data_to_ul_ack; - spatial_relation_info_to_add_mod_list_l_ spatial_relation_info_to_add_mod_list; - spatial_relation_info_to_release_list_l_ spatial_relation_info_to_release_list; - pucch_pwr_ctrl_s pucch_pwr_ctrl; - // ... + bool master_cell_group_present = false; + bool full_cfg_present = false; + bool ded_nas_msg_list_present = false; + bool master_key_upd_present = false; + bool ded_sib1_delivery_present = false; + bool ded_sys_info_delivery_present = false; + bool other_cfg_present = false; + bool non_crit_ext_present = false; + dyn_octstring master_cell_group; + ded_nas_msg_list_l_ ded_nas_msg_list; + master_key_upd_s master_key_upd; + dyn_octstring ded_sib1_delivery; + dyn_octstring ded_sys_info_delivery; + other_cfg_s other_cfg; + rrc_recfg_v1540_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7316,14 +7223,11 @@ struct pucch_cfg_s { void to_json(json_writer& j) const; }; -// PUCCH-TPC-CommandConfig ::= SEQUENCE -struct pucch_tpc_cmd_cfg_s { - bool ext = false; - bool tpc_idx_pcell_present = false; - bool tpc_idx_pucch_scell_present = false; - uint8_t tpc_idx_pcell = 1; - uint8_t tpc_idx_pucch_scell = 1; - // ... +// RRCRelease-v1540-IEs ::= SEQUENCE +struct rrc_release_v1540_ies_s { + bool wait_time_present = false; + bool non_crit_ext_present = false; + uint8_t wait_time = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7331,101 +7235,82 @@ struct pucch_tpc_cmd_cfg_s { void to_json(json_writer& j) const; }; -// PUSCH-Config ::= SEQUENCE -struct pusch_cfg_s { - struct tx_cfg_opts { - enum options { codebook, non_codebook, nulltype } value; +// RRCResume-v1560-IEs ::= SEQUENCE +struct rrc_resume_v1560_ies_s { + bool radio_bearer_cfg2_present = false; + bool sk_counter_present = false; + bool non_crit_ext_present = false; + dyn_octstring radio_bearer_cfg2; + uint32_t sk_counter = 0; - std::string to_string() const; - }; - typedef enumerated tx_cfg_e_; - struct freq_hop_opts { - enum options { intra_slot, inter_slot, nulltype } value; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - }; - typedef enumerated freq_hop_e_; - using freq_hop_offset_lists_l_ = bounded_array; - struct res_alloc_opts { - enum options { res_alloc_type0, res_alloc_type1, dynamic_switch, nulltype } value; - typedef uint8_t number_type; +// RedirectedCarrierInfo ::= CHOICE +struct redirected_carrier_info_c { + struct types_opts { + enum options { nr, eutra, /*...*/ nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; - typedef enumerated res_alloc_e_; - struct pusch_aggregation_factor_opts { - enum options { n2, n4, n8, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated pusch_aggregation_factor_e_; - struct mcs_table_opts { - enum options { qam256, qam64_low_se, nulltype } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated mcs_table_e_; - struct mcs_table_transform_precoder_opts { - enum options { qam256, qam64_low_se, nulltype } value; - typedef uint16_t number_type; + typedef enumerated types; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated mcs_table_transform_precoder_e_; - struct transform_precoder_opts { - enum options { enabled, disabled, nulltype } value; + // choice methods + redirected_carrier_info_c() = default; + redirected_carrier_info_c(const redirected_carrier_info_c& other); + redirected_carrier_info_c& operator=(const redirected_carrier_info_c& other); + ~redirected_carrier_info_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + carrier_info_nr_s& nr() + { + assert_choice_type("nr", type_.to_string(), "RedirectedCarrierInfo"); + return c.get(); + } + redirected_carrier_info_eutra_s& eutra() + { + assert_choice_type("eutra", type_.to_string(), "RedirectedCarrierInfo"); + return c.get(); + } + const carrier_info_nr_s& nr() const + { + assert_choice_type("nr", type_.to_string(), "RedirectedCarrierInfo"); + return c.get(); + } + const redirected_carrier_info_eutra_s& eutra() const + { + assert_choice_type("eutra", type_.to_string(), "RedirectedCarrierInfo"); + return c.get(); + } + carrier_info_nr_s& set_nr() + { + set(types::nr); + return c.get(); + } + redirected_carrier_info_eutra_s& set_eutra() + { + set(types::eutra); + return c.get(); + } - std::string to_string() const; - }; - typedef enumerated transform_precoder_e_; - struct codebook_subset_opts { - enum options { fully_and_partial_and_non_coherent, partial_and_non_coherent, non_coherent, nulltype } value; +private: + types type_; + choice_buffer_t c; - std::string to_string() const; - }; - typedef enumerated codebook_subset_e_; + void destroy_(); +}; - // member variables - bool ext = false; - bool data_scrambling_id_pusch_present = false; - bool tx_cfg_present = false; - bool dmrs_ul_for_pusch_map_type_a_present = false; - bool dmrs_ul_for_pusch_map_type_b_present = false; - bool pusch_pwr_ctrl_present = false; - bool freq_hop_present = false; - bool freq_hop_offset_lists_present = false; - bool pusch_time_domain_alloc_list_present = false; - bool pusch_aggregation_factor_present = false; - bool mcs_table_present = false; - bool mcs_table_transform_precoder_present = false; - bool transform_precoder_present = false; - bool codebook_subset_present = false; - bool max_rank_present = false; - bool rbg_size_present = false; - bool uci_on_pusch_present = false; - bool tp_pi2_bpsk_present = false; - uint16_t data_scrambling_id_pusch = 0; - tx_cfg_e_ tx_cfg; - setup_release_c dmrs_ul_for_pusch_map_type_a; - setup_release_c dmrs_ul_for_pusch_map_type_b; - pusch_pwr_ctrl_s pusch_pwr_ctrl; - freq_hop_e_ freq_hop; - freq_hop_offset_lists_l_ freq_hop_offset_lists; - res_alloc_e_ res_alloc; - setup_release_c > pusch_time_domain_alloc_list; - pusch_aggregation_factor_e_ pusch_aggregation_factor; - mcs_table_e_ mcs_table; - mcs_table_transform_precoder_e_ mcs_table_transform_precoder; - transform_precoder_e_ transform_precoder; - codebook_subset_e_ codebook_subset; - uint8_t max_rank = 1; - setup_release_c uci_on_pusch; +// SecurityConfigSMC ::= SEQUENCE +struct security_cfg_smc_s { + bool ext = false; + security_algorithm_cfg_s security_algorithm_cfg; // ... // sequence methods @@ -7434,15 +7319,17 @@ struct pusch_cfg_s { void to_json(json_writer& j) const; }; -// PUSCH-TPC-CommandConfig ::= SEQUENCE -struct pusch_tpc_cmd_cfg_s { - bool ext = false; - bool tpc_idx_present = false; - bool tpc_idx_sul_present = false; - bool target_cell_present = false; - uint8_t tpc_idx = 1; - uint8_t tpc_idx_sul = 1; - uint8_t target_cell = 0; +// SuspendConfig ::= SEQUENCE +struct suspend_cfg_s { + bool ext = false; + bool ran_notif_area_info_present = false; + bool t380_present = false; + fixed_bitstring<40> full_i_rnti; + fixed_bitstring<24> short_i_rnti; + paging_cycle_e ran_paging_cycle; + ran_notif_area_info_c ran_notif_area_info; + periodic_rnau_timer_value_e t380; + uint8_t next_hop_chaining_count = 0; // ... // sequence methods @@ -7451,77 +7338,53 @@ struct pusch_tpc_cmd_cfg_s { void to_json(json_writer& j) const; }; -// RadioLinkMonitoringRS ::= SEQUENCE -struct radio_link_monitoring_rs_s { - struct purpose_opts { - enum options { beam_fail, rlf, both, nulltype } value; +// UE-CapabilityRAT-RequestList ::= SEQUENCE (SIZE (1..8)) OF UE-CapabilityRAT-Request +using ue_cap_rat_request_list_l = dyn_array; - std::string to_string() const; - }; - typedef enumerated purpose_e_; - struct detection_res_c_ { - struct types_opts { - enum options { ssb_idx, csi_rs_idx, nulltype } value; +// CounterCheck-IEs ::= SEQUENCE +struct counter_check_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + drb_count_msb_info_list_l drb_count_msb_info_list; + dyn_octstring late_non_crit_ext; - std::string to_string() const; - }; - typedef enumerated types; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // choice methods - detection_res_c_() = default; - detection_res_c_(const detection_res_c_& other); - detection_res_c_& operator=(const detection_res_c_& other); - ~detection_res_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - uint8_t& ssb_idx() - { - assert_choice_type("ssb-Index", type_.to_string(), "detectionResource"); - return c.get(); - } - uint8_t& csi_rs_idx() - { - assert_choice_type("csi-RS-Index", type_.to_string(), "detectionResource"); - return c.get(); - } - const uint8_t& ssb_idx() const - { - assert_choice_type("ssb-Index", type_.to_string(), "detectionResource"); - return c.get(); - } - const uint8_t& csi_rs_idx() const - { - assert_choice_type("csi-RS-Index", type_.to_string(), "detectionResource"); - return c.get(); - } - uint8_t& set_ssb_idx() - { - set(types::ssb_idx); - return c.get(); - } - uint8_t& set_csi_rs_idx() - { - set(types::csi_rs_idx); - return c.get(); - } +// DLInformationTransfer-IEs ::= SEQUENCE +struct dl_info_transfer_ies_s { + bool ded_nas_msg_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring ded_nas_msg; + dyn_octstring late_non_crit_ext; - private: - types type_; - pod_choice_buffer_t c; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - void destroy_(); +// MobilityFromNRCommand-IEs ::= SEQUENCE +struct mob_from_nr_cmd_ies_s { + struct target_rat_type_opts { + enum options { eutra, spare3, spare2, spare1, /*...*/ nulltype } value; + + std::string to_string() const; }; + typedef enumerated target_rat_type_e_; // member variables - bool ext = false; - uint8_t radio_link_monitoring_rs_id = 0; - purpose_e_ purpose; - detection_res_c_ detection_res; - // ... + bool nas_security_param_from_nr_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + target_rat_type_e_ target_rat_type; + dyn_octstring target_rat_msg_container; + dyn_octstring nas_security_param_from_nr; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7529,280 +7392,74 @@ struct radio_link_monitoring_rs_s { void to_json(json_writer& j) const; }; -// RateMatchPattern ::= SEQUENCE -struct rate_match_pattern_s { - struct pattern_type_c_ { - struct bitmaps_s_ { - struct symbols_in_res_block_c_ { - struct types_opts { - enum options { one_slot, two_slots, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; - - // choice methods - symbols_in_res_block_c_() = default; - symbols_in_res_block_c_(const symbols_in_res_block_c_& other); - symbols_in_res_block_c_& operator=(const symbols_in_res_block_c_& other); - ~symbols_in_res_block_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<14>& one_slot() - { - assert_choice_type("oneSlot", type_.to_string(), "symbolsInResourceBlock"); - return c.get >(); - } - fixed_bitstring<28>& two_slots() - { - assert_choice_type("twoSlots", type_.to_string(), "symbolsInResourceBlock"); - return c.get >(); - } - const fixed_bitstring<14>& one_slot() const - { - assert_choice_type("oneSlot", type_.to_string(), "symbolsInResourceBlock"); - return c.get >(); - } - const fixed_bitstring<28>& two_slots() const - { - assert_choice_type("twoSlots", type_.to_string(), "symbolsInResourceBlock"); - return c.get >(); - } - fixed_bitstring<14>& set_one_slot() - { - set(types::one_slot); - return c.get >(); - } - fixed_bitstring<28>& set_two_slots() - { - set(types::two_slots); - return c.get >(); - } - - private: - types type_; - choice_buffer_t > c; - - void destroy_(); - }; - struct periodicity_and_pattern_c_ { - struct types_opts { - enum options { n2, n4, n5, n8, n10, n20, n40, nulltype } value; - typedef uint8_t number_type; +// RRCReconfiguration-IEs ::= SEQUENCE +struct rrc_recfg_ies_s { + bool radio_bearer_cfg_present = false; + bool secondary_cell_group_present = false; + bool meas_cfg_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + radio_bearer_cfg_s radio_bearer_cfg; + dyn_octstring secondary_cell_group; + meas_cfg_s meas_cfg; + dyn_octstring late_non_crit_ext; + rrc_recfg_v1530_ies_s non_crit_ext; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // choice methods - periodicity_and_pattern_c_() = default; - periodicity_and_pattern_c_(const periodicity_and_pattern_c_& other); - periodicity_and_pattern_c_& operator=(const periodicity_and_pattern_c_& other); - ~periodicity_and_pattern_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<2>& n2() - { - assert_choice_type("n2", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - fixed_bitstring<4>& n4() - { - assert_choice_type("n4", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - fixed_bitstring<5>& n5() - { - assert_choice_type("n5", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - fixed_bitstring<8>& n8() - { - assert_choice_type("n8", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - fixed_bitstring<10>& n10() - { - assert_choice_type("n10", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - fixed_bitstring<20>& n20() - { - assert_choice_type("n20", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - fixed_bitstring<40>& n40() - { - assert_choice_type("n40", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - const fixed_bitstring<2>& n2() const - { - assert_choice_type("n2", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - const fixed_bitstring<4>& n4() const - { - assert_choice_type("n4", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - const fixed_bitstring<5>& n5() const - { - assert_choice_type("n5", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - const fixed_bitstring<8>& n8() const - { - assert_choice_type("n8", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - const fixed_bitstring<10>& n10() const - { - assert_choice_type("n10", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - const fixed_bitstring<20>& n20() const - { - assert_choice_type("n20", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - const fixed_bitstring<40>& n40() const - { - assert_choice_type("n40", type_.to_string(), "periodicityAndPattern"); - return c.get >(); - } - fixed_bitstring<2>& set_n2() - { - set(types::n2); - return c.get >(); - } - fixed_bitstring<4>& set_n4() - { - set(types::n4); - return c.get >(); - } - fixed_bitstring<5>& set_n5() - { - set(types::n5); - return c.get >(); - } - fixed_bitstring<8>& set_n8() - { - set(types::n8); - return c.get >(); - } - fixed_bitstring<10>& set_n10() - { - set(types::n10); - return c.get >(); - } - fixed_bitstring<20>& set_n20() - { - set(types::n20); - return c.get >(); - } - fixed_bitstring<40>& set_n40() - { - set(types::n40); - return c.get >(); - } +// RRCReestablishment-IEs ::= SEQUENCE +struct rrc_reest_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + uint8_t next_hop_chaining_count = 0; + dyn_octstring late_non_crit_ext; - private: - types type_; - choice_buffer_t > c; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - void destroy_(); - }; +// RRCRelease-IEs ::= SEQUENCE +struct rrc_release_ies_s { + struct depriorit_req_s_ { + struct depriorit_type_opts { + enum options { freq, nr, nulltype } value; - // member variables - bool ext = false; - bool periodicity_and_pattern_present = false; - fixed_bitstring<275> res_blocks; - symbols_in_res_block_c_ symbols_in_res_block; - periodicity_and_pattern_c_ periodicity_and_pattern; - // ... + std::string to_string() const; }; - struct types_opts { - enum options { bitmaps, ctrl_res_set, nulltype } value; + typedef enumerated depriorit_type_e_; + struct depriorit_timer_opts { + enum options { min5, min10, min15, min30, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated types; + typedef enumerated depriorit_timer_e_; - // choice methods - pattern_type_c_() = default; - pattern_type_c_(const pattern_type_c_& other); - pattern_type_c_& operator=(const pattern_type_c_& other); - ~pattern_type_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - bitmaps_s_& bitmaps() - { - assert_choice_type("bitmaps", type_.to_string(), "patternType"); - return c.get(); - } - uint8_t& ctrl_res_set() - { - assert_choice_type("controlResourceSet", type_.to_string(), "patternType"); - return c.get(); - } - const bitmaps_s_& bitmaps() const - { - assert_choice_type("bitmaps", type_.to_string(), "patternType"); - return c.get(); - } - const uint8_t& ctrl_res_set() const - { - assert_choice_type("controlResourceSet", type_.to_string(), "patternType"); - return c.get(); - } - bitmaps_s_& set_bitmaps() - { - set(types::bitmaps); - return c.get(); - } - uint8_t& set_ctrl_res_set() - { - set(types::ctrl_res_set); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - struct dummy_opts { - enum options { dynamic_value, semi_static, nulltype } value; - - std::string to_string() const; + // member variables + depriorit_type_e_ depriorit_type; + depriorit_timer_e_ depriorit_timer; }; - typedef enumerated dummy_e_; // member variables - bool ext = false; - bool subcarrier_spacing_present = false; - uint8_t rate_match_pattern_id = 0; - pattern_type_c_ pattern_type; - subcarrier_spacing_e subcarrier_spacing; - dummy_e_ dummy; - // ... + bool redirected_carrier_info_present = false; + bool cell_resel_priorities_present = false; + bool suspend_cfg_present = false; + bool depriorit_req_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + redirected_carrier_info_c redirected_carrier_info; + cell_resel_priorities_s cell_resel_priorities; + suspend_cfg_s suspend_cfg; + depriorit_req_s_ depriorit_req; + dyn_octstring late_non_crit_ext; + rrc_release_v1540_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7810,72 +7467,32 @@ struct rate_match_pattern_s { void to_json(json_writer& j) const; }; -struct rate_match_pattern_group_item_c_ { - struct types_opts { - enum options { cell_level, bwp_level, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; +// RRCResume-IEs ::= SEQUENCE +struct rrc_resume_ies_s { + bool radio_bearer_cfg_present = false; + bool master_cell_group_present = false; + bool meas_cfg_present = false; + bool full_cfg_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + radio_bearer_cfg_s radio_bearer_cfg; + dyn_octstring master_cell_group; + meas_cfg_s meas_cfg; + dyn_octstring late_non_crit_ext; + rrc_resume_v1560_ies_s non_crit_ext; - // choice methods - rate_match_pattern_group_item_c_() = default; - rate_match_pattern_group_item_c_(const rate_match_pattern_group_item_c_& other); - rate_match_pattern_group_item_c_& operator=(const rate_match_pattern_group_item_c_& other); - ~rate_match_pattern_group_item_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } + // sequence methods SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; - // getters - uint8_t& cell_level() - { - assert_choice_type("cellLevel", type_.to_string(), "RateMatchPatternGroup-item"); - return c.get(); - } - uint8_t& bwp_level() - { - assert_choice_type("bwpLevel", type_.to_string(), "RateMatchPatternGroup-item"); - return c.get(); - } - const uint8_t& cell_level() const - { - assert_choice_type("cellLevel", type_.to_string(), "RateMatchPatternGroup-item"); - return c.get(); - } - const uint8_t& bwp_level() const - { - assert_choice_type("bwpLevel", type_.to_string(), "RateMatchPatternGroup-item"); - return c.get(); - } - uint8_t& set_cell_level() - { - set(types::cell_level); - return c.get(); - } - uint8_t& set_bwp_level() - { - set(types::bwp_level); - return c.get(); - } - -private: - types type_; - pod_choice_buffer_t c; - - void destroy_(); }; -// RateMatchPatternGroup ::= SEQUENCE (SIZE (1..8)) OF RateMatchPatternGroup-item -using rate_match_pattern_group_l = dyn_array; - -// SRS-CC-SetIndex ::= SEQUENCE -struct srs_cc_set_idx_s { - bool cc_set_idx_present = false; - bool cc_idx_in_one_cc_set_present = false; - uint8_t cc_set_idx = 0; - uint8_t cc_idx_in_one_cc_set = 0; +// SecurityModeCommand-IEs ::= SEQUENCE +struct security_mode_cmd_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + security_cfg_smc_s security_cfg_smc; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7883,25 +7500,13 @@ struct srs_cc_set_idx_s { void to_json(json_writer& j) const; }; -// SRS-Config ::= SEQUENCE -struct srs_cfg_s { - using srs_res_set_to_release_list_l_ = bounded_array; - using srs_res_set_to_add_mod_list_l_ = dyn_array; - using srs_res_to_release_list_l_ = dyn_array; - using srs_res_to_add_mod_list_l_ = dyn_array; - - // member variables - bool ext = false; - bool srs_res_set_to_release_list_present = false; - bool srs_res_set_to_add_mod_list_present = false; - bool srs_res_to_release_list_present = false; - bool srs_res_to_add_mod_list_present = false; - bool tpc_accumulation_present = false; - srs_res_set_to_release_list_l_ srs_res_set_to_release_list; - srs_res_set_to_add_mod_list_l_ srs_res_set_to_add_mod_list; - srs_res_to_release_list_l_ srs_res_to_release_list; - srs_res_to_add_mod_list_l_ srs_res_to_add_mod_list; - // ... +// UECapabilityEnquiry-IEs ::= SEQUENCE +struct ue_cap_enquiry_ies_s { + bool late_non_crit_ext_present = false; + bool ue_cap_enquiry_ext_present = false; + ue_cap_rat_request_list_l ue_cap_rat_request_list; + dyn_octstring late_non_crit_ext; + dyn_octstring ue_cap_enquiry_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7909,31 +7514,53 @@ struct srs_cfg_s { void to_json(json_writer& j) const; }; -// SRS-TPC-CommandConfig ::= SEQUENCE -struct srs_tpc_cmd_cfg_s { - bool ext = false; - bool start_bit_of_format2_minus3_present = false; - bool field_type_format2_minus3_present = false; - uint8_t start_bit_of_format2_minus3 = 1; - uint8_t field_type_format2_minus3 = 0; - // ... - // group 0 - bool start_bit_of_format2_minus3_sul_v1530_present = false; - uint8_t start_bit_of_format2_minus3_sul_v1530 = 1; +// CounterCheck ::= SEQUENCE +struct counter_check_s { + struct crit_exts_c_ { + struct types_opts { + enum options { counter_check, crit_exts_future, nulltype } value; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + }; + typedef enumerated types; -// SlotFormatCombination ::= SEQUENCE -struct slot_format_combination_s { - using slot_formats_l_ = dyn_array; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + counter_check_ies_s& counter_check() + { + assert_choice_type("counterCheck", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const counter_check_ies_s& counter_check() const + { + assert_choice_type("counterCheck", type_.to_string(), "criticalExtensions"); + return c.get(); + } + counter_check_ies_s& set_counter_check() + { + set(types::counter_check); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; // member variables - uint16_t slot_format_combination_id = 0; - slot_formats_l_ slot_formats; + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7941,14 +7568,53 @@ struct slot_format_combination_s { void to_json(json_writer& j) const; }; -// TCI-State ::= SEQUENCE -struct tci_state_s { - bool ext = false; - bool qcl_type2_present = false; - uint8_t tci_state_id = 0; - qcl_info_s qcl_type1; - qcl_info_s qcl_type2; - // ... +// DLInformationTransfer ::= SEQUENCE +struct dl_info_transfer_s { + struct crit_exts_c_ { + struct types_opts { + enum options { dl_info_transfer, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + dl_info_transfer_ies_s& dl_info_transfer() + { + assert_choice_type("dlInformationTransfer", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const dl_info_transfer_ies_s& dl_info_transfer() const + { + assert_choice_type("dlInformationTransfer", type_.to_string(), "criticalExtensions"); + return c.get(); + } + dl_info_transfer_ies_s& set_dl_info_transfer() + { + set(types::dl_info_transfer); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7956,30 +7622,53 @@ struct tci_state_s { void to_json(json_writer& j) const; }; -// ZP-CSI-RS-Resource ::= SEQUENCE -struct zp_csi_rs_res_s { - bool ext = false; - bool periodicity_and_offset_present = false; - uint8_t zp_csi_rs_res_id = 0; - csi_rs_res_map_s res_map; - csi_res_periodicity_and_offset_c periodicity_and_offset; - // ... +// MobilityFromNRCommand ::= SEQUENCE +struct mob_from_nr_cmd_s { + struct crit_exts_c_ { + struct types_opts { + enum options { mob_from_nr_cmd, crit_exts_future, nulltype } value; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + }; + typedef enumerated types; -// ZP-CSI-RS-ResourceSet ::= SEQUENCE -struct zp_csi_rs_res_set_s { - using zp_csi_rs_res_id_list_l_ = bounded_array; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + mob_from_nr_cmd_ies_s& mob_from_nr_cmd() + { + assert_choice_type("mobilityFromNRCommand", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const mob_from_nr_cmd_ies_s& mob_from_nr_cmd() const + { + assert_choice_type("mobilityFromNRCommand", type_.to_string(), "criticalExtensions"); + return c.get(); + } + mob_from_nr_cmd_ies_s& set_mob_from_nr_cmd() + { + set(types::mob_from_nr_cmd); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; // member variables - bool ext = false; - uint8_t zp_csi_rs_res_set_id = 0; - zp_csi_rs_res_id_list_l_ zp_csi_rs_res_id_list; - // ... + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -7987,37 +7676,53 @@ struct zp_csi_rs_res_set_s { void to_json(json_writer& j) const; }; -// BWP-UplinkDedicated ::= SEQUENCE -struct bwp_ul_ded_s { - bool ext = false; - bool pucch_cfg_present = false; - bool pusch_cfg_present = false; - bool cfgured_grant_cfg_present = false; - bool srs_cfg_present = false; - bool beam_fail_recovery_cfg_present = false; - setup_release_c pucch_cfg; - setup_release_c pusch_cfg; - setup_release_c cfgured_grant_cfg; - setup_release_c srs_cfg; - setup_release_c beam_fail_recovery_cfg; - // ... +// RRCReconfiguration ::= SEQUENCE +struct rrc_recfg_s { + struct crit_exts_c_ { + struct types_opts { + enum options { rrc_recfg, crit_exts_future, nulltype } value; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + }; + typedef enumerated types; -// CFRA-CSIRS-Resource ::= SEQUENCE -struct cfra_csirs_res_s { - using ra_occasion_list_l_ = dyn_array; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_recfg_ies_s& rrc_recfg() + { + assert_choice_type("rrcReconfiguration", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const rrc_recfg_ies_s& rrc_recfg() const + { + assert_choice_type("rrcReconfiguration", type_.to_string(), "criticalExtensions"); + return c.get(); + } + rrc_recfg_ies_s& set_rrc_recfg() + { + set(types::rrc_recfg); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; // member variables - bool ext = false; - uint8_t csi_rs = 0; - ra_occasion_list_l_ ra_occasion_list; - uint8_t ra_preamb_idx = 0; - // ... + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -8025,12 +7730,53 @@ struct cfra_csirs_res_s { void to_json(json_writer& j) const; }; -// CFRA-SSB-Resource ::= SEQUENCE -struct cfra_ssb_res_s { - bool ext = false; - uint8_t ssb = 0; - uint8_t ra_preamb_idx = 0; - // ... +// RRCReestablishment ::= SEQUENCE +struct rrc_reest_s { + struct crit_exts_c_ { + struct types_opts { + enum options { rrc_reest, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_reest_ies_s& rrc_reest() + { + assert_choice_type("rrcReestablishment", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const rrc_reest_ies_s& rrc_reest() const + { + assert_choice_type("rrcReestablishment", type_.to_string(), "criticalExtensions"); + return c.get(); + } + rrc_reest_ies_s& set_rrc_reest() + { + set(types::rrc_reest); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -8038,14 +7784,53 @@ struct cfra_ssb_res_s { void to_json(json_writer& j) const; }; -// CSI-AperiodicTriggerState ::= SEQUENCE -struct csi_aperiodic_trigger_state_s { - using associated_report_cfg_info_list_l_ = dyn_array; +// RRCRelease ::= SEQUENCE +struct rrc_release_s { + struct crit_exts_c_ { + struct types_opts { + enum options { rrc_release, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_release_ies_s& rrc_release() + { + assert_choice_type("rrcRelease", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const rrc_release_ies_s& rrc_release() const + { + assert_choice_type("rrcRelease", type_.to_string(), "criticalExtensions"); + return c.get(); + } + rrc_release_ies_s& set_rrc_release() + { + set(types::rrc_release); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; // member variables - bool ext = false; - associated_report_cfg_info_list_l_ associated_report_cfg_info_list; - // ... + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -8053,203 +7838,53 @@ struct csi_aperiodic_trigger_state_s { void to_json(json_writer& j) const; }; -// CSI-ReportPeriodicityAndOffset ::= CHOICE -struct csi_report_periodicity_and_offset_c { - struct types_opts { - enum options { - slots4, - slots5, - slots8, - slots10, - slots16, - slots20, - slots40, - slots80, - slots160, - slots320, - nulltype - } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated types; +// RRCResume ::= SEQUENCE +struct rrc_resume_s { + struct crit_exts_c_ { + struct types_opts { + enum options { rrc_resume, crit_exts_future, nulltype } value; - // choice methods - csi_report_periodicity_and_offset_c() = default; - csi_report_periodicity_and_offset_c(const csi_report_periodicity_and_offset_c& other); - csi_report_periodicity_and_offset_c& operator=(const csi_report_periodicity_and_offset_c& other); - ~csi_report_periodicity_and_offset_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - uint8_t& slots4() - { - assert_choice_type("slots4", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots5() - { - assert_choice_type("slots5", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots8() - { - assert_choice_type("slots8", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots10() - { - assert_choice_type("slots10", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots16() - { - assert_choice_type("slots16", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots20() - { - assert_choice_type("slots20", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots40() - { - assert_choice_type("slots40", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots80() - { - assert_choice_type("slots80", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& slots160() - { - assert_choice_type("slots160", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint16_t& slots320() - { - assert_choice_type("slots320", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots4() const - { - assert_choice_type("slots4", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots5() const - { - assert_choice_type("slots5", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots8() const - { - assert_choice_type("slots8", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots10() const - { - assert_choice_type("slots10", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots16() const - { - assert_choice_type("slots16", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots20() const - { - assert_choice_type("slots20", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots40() const - { - assert_choice_type("slots40", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots80() const - { - assert_choice_type("slots80", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint8_t& slots160() const - { - assert_choice_type("slots160", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - const uint16_t& slots320() const - { - assert_choice_type("slots320", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); - return c.get(); - } - uint8_t& set_slots4() - { - set(types::slots4); - return c.get(); - } - uint8_t& set_slots5() - { - set(types::slots5); - return c.get(); - } - uint8_t& set_slots8() - { - set(types::slots8); - return c.get(); - } - uint8_t& set_slots10() - { - set(types::slots10); - return c.get(); - } - uint8_t& set_slots16() - { - set(types::slots16); - return c.get(); - } - uint8_t& set_slots20() - { - set(types::slots20); - return c.get(); - } - uint8_t& set_slots40() - { - set(types::slots40); - return c.get(); - } - uint8_t& set_slots80() - { - set(types::slots80); - return c.get(); - } - uint8_t& set_slots160() - { - set(types::slots160); - return c.get(); - } - uint16_t& set_slots320() - { - set(types::slots320); - return c.get(); - } + std::string to_string() const; + }; + typedef enumerated types; -private: - types type_; - pod_choice_buffer_t c; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_resume_ies_s& rrc_resume() + { + assert_choice_type("rrcResume", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const rrc_resume_ies_s& rrc_resume() const + { + assert_choice_type("rrcResume", type_.to_string(), "criticalExtensions"); + return c.get(); + } + rrc_resume_ies_s& set_rrc_resume() + { + set(types::rrc_resume); + return c.get(); + } - void destroy_(); -}; + private: + types type_; + choice_buffer_t c; -// CSI-SemiPersistentOnPUSCH-TriggerState ::= SEQUENCE -struct csi_semi_persistent_on_pusch_trigger_state_s { - bool ext = false; - uint8_t associated_report_cfg_info = 0; - // ... + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -8257,962 +7892,531 @@ struct csi_semi_persistent_on_pusch_trigger_state_s { void to_json(json_writer& j) const; }; -// CodebookConfig ::= SEQUENCE -struct codebook_cfg_s { - struct codebook_type_c_ { - struct type1_s_ { - struct sub_type_c_ { - struct type_i_single_panel_s_ { - struct nr_of_ant_ports_c_ { - struct two_s_ { - fixed_bitstring<6> two_tx_codebook_subset_restrict; - }; - struct more_than_two_s_ { - struct n1_n2_c_ { - struct types_opts { - enum options { - two_one_type_i_single_panel_restrict, - two_two_type_i_single_panel_restrict, - four_one_type_i_single_panel_restrict, - three_two_type_i_single_panel_restrict, - six_one_type_i_single_panel_restrict, - four_two_type_i_single_panel_restrict, - eight_one_type_i_single_panel_restrict, - four_three_type_i_single_panel_restrict, - six_two_type_i_single_panel_restrict, - twelve_one_type_i_single_panel_restrict, - four_four_type_i_single_panel_restrict, - eight_two_type_i_single_panel_restrict, - sixteen_one_type_i_single_panel_restrict, - nulltype - } value; +// SecurityModeCommand ::= SEQUENCE +struct security_mode_cmd_s { + struct crit_exts_c_ { + struct types_opts { + enum options { security_mode_cmd, crit_exts_future, nulltype } value; - std::string to_string() const; - }; - typedef enumerated types; + std::string to_string() const; + }; + typedef enumerated types; - // choice methods - n1_n2_c_() = default; - n1_n2_c_(const n1_n2_c_& other); - n1_n2_c_& operator=(const n1_n2_c_& other); - ~n1_n2_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<8>& two_one_type_i_single_panel_restrict() - { - assert_choice_type("two-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<64>& two_two_type_i_single_panel_restrict() - { - assert_choice_type("two-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<16>& four_one_type_i_single_panel_restrict() - { - assert_choice_type("four-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<96>& three_two_type_i_single_panel_restrict() - { - assert_choice_type("three-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<24>& six_one_type_i_single_panel_restrict() - { - assert_choice_type("six-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<128>& four_two_type_i_single_panel_restrict() - { - assert_choice_type("four-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<32>& eight_one_type_i_single_panel_restrict() - { - assert_choice_type("eight-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<192>& four_three_type_i_single_panel_restrict() - { - assert_choice_type("four-three-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<192>& six_two_type_i_single_panel_restrict() - { - assert_choice_type("six-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<48>& twelve_one_type_i_single_panel_restrict() - { - assert_choice_type("twelve-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<256>& four_four_type_i_single_panel_restrict() - { - assert_choice_type("four-four-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<256>& eight_two_type_i_single_panel_restrict() - { - assert_choice_type("eight-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<64>& sixteen_one_type_i_single_panel_restrict() - { - assert_choice_type("sixteen-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<8>& two_one_type_i_single_panel_restrict() const - { - assert_choice_type("two-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<64>& two_two_type_i_single_panel_restrict() const - { - assert_choice_type("two-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<16>& four_one_type_i_single_panel_restrict() const - { - assert_choice_type("four-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<96>& three_two_type_i_single_panel_restrict() const - { - assert_choice_type("three-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<24>& six_one_type_i_single_panel_restrict() const - { - assert_choice_type("six-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<128>& four_two_type_i_single_panel_restrict() const - { - assert_choice_type("four-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<32>& eight_one_type_i_single_panel_restrict() const - { - assert_choice_type("eight-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<192>& four_three_type_i_single_panel_restrict() const - { - assert_choice_type("four-three-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<192>& six_two_type_i_single_panel_restrict() const - { - assert_choice_type("six-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<48>& twelve_one_type_i_single_panel_restrict() const - { - assert_choice_type("twelve-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<256>& four_four_type_i_single_panel_restrict() const - { - assert_choice_type("four-four-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<256>& eight_two_type_i_single_panel_restrict() const - { - assert_choice_type("eight-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - const fixed_bitstring<64>& sixteen_one_type_i_single_panel_restrict() const - { - assert_choice_type("sixteen-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); - return c.get >(); - } - fixed_bitstring<8>& set_two_one_type_i_single_panel_restrict() - { - set(types::two_one_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<64>& set_two_two_type_i_single_panel_restrict() - { - set(types::two_two_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<16>& set_four_one_type_i_single_panel_restrict() - { - set(types::four_one_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<96>& set_three_two_type_i_single_panel_restrict() - { - set(types::three_two_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<24>& set_six_one_type_i_single_panel_restrict() - { - set(types::six_one_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<128>& set_four_two_type_i_single_panel_restrict() - { - set(types::four_two_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<32>& set_eight_one_type_i_single_panel_restrict() - { - set(types::eight_one_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<192>& set_four_three_type_i_single_panel_restrict() - { - set(types::four_three_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<192>& set_six_two_type_i_single_panel_restrict() - { - set(types::six_two_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<48>& set_twelve_one_type_i_single_panel_restrict() - { - set(types::twelve_one_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<256>& set_four_four_type_i_single_panel_restrict() - { - set(types::four_four_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<256>& set_eight_two_type_i_single_panel_restrict() - { - set(types::eight_two_type_i_single_panel_restrict); - return c.get >(); - } - fixed_bitstring<64>& set_sixteen_one_type_i_single_panel_restrict() - { - set(types::sixteen_one_type_i_single_panel_restrict); - return c.get >(); - } + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + security_mode_cmd_ies_s& security_mode_cmd() + { + assert_choice_type("securityModeCommand", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const security_mode_cmd_ies_s& security_mode_cmd() const + { + assert_choice_type("securityModeCommand", type_.to_string(), "criticalExtensions"); + return c.get(); + } + security_mode_cmd_ies_s& set_security_mode_cmd() + { + set(types::security_mode_cmd); + return c.get(); + } - private: - types type_; - choice_buffer_t > c; + private: + types type_; + choice_buffer_t c; - void destroy_(); - }; + void destroy_(); + }; - // member variables - bool type_i_single_panel_codebook_subset_restrict_i2_present = false; - n1_n2_c_ n1_n2; - fixed_bitstring<16> type_i_single_panel_codebook_subset_restrict_i2; - }; - struct types_opts { - enum options { two, more_than_two, nulltype } value; - typedef uint8_t number_type; + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; - - // choice methods - nr_of_ant_ports_c_() = default; - nr_of_ant_ports_c_(const nr_of_ant_ports_c_& other); - nr_of_ant_ports_c_& operator=(const nr_of_ant_ports_c_& other); - ~nr_of_ant_ports_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - two_s_& two() - { - assert_choice_type("two", type_.to_string(), "nrOfAntennaPorts"); - return c.get(); - } - more_than_two_s_& more_than_two() - { - assert_choice_type("moreThanTwo", type_.to_string(), "nrOfAntennaPorts"); - return c.get(); - } - const two_s_& two() const - { - assert_choice_type("two", type_.to_string(), "nrOfAntennaPorts"); - return c.get(); - } - const more_than_two_s_& more_than_two() const - { - assert_choice_type("moreThanTwo", type_.to_string(), "nrOfAntennaPorts"); - return c.get(); - } - two_s_& set_two() - { - set(types::two); - return c.get(); - } - more_than_two_s_& set_more_than_two() - { - set(types::more_than_two); - return c.get(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - choice_buffer_t c; +// UECapabilityEnquiry ::= SEQUENCE +struct ue_cap_enquiry_s { + struct crit_exts_c_ { + struct types_opts { + enum options { ue_cap_enquiry, crit_exts_future, nulltype } value; - void destroy_(); - }; + std::string to_string() const; + }; + typedef enumerated types; - // member variables - nr_of_ant_ports_c_ nr_of_ant_ports; - fixed_bitstring<8> type_i_single_panel_ri_restrict; - }; - struct type_i_multi_panel_s_ { - struct ng_n1_n2_c_ { - struct types_opts { - enum options { - two_two_one_type_i_multi_panel_restrict, - two_four_one_type_i_multi_panel_restrict, - four_two_one_type_i_multi_panel_restrict, - two_two_two_type_i_multi_panel_restrict, - two_eight_one_type_i_multi_panel_restrict, - four_four_one_type_i_multi_panel_restrict, - two_four_two_type_i_multi_panel_restrict, - four_two_two_type_i_multi_panel_restrict, - nulltype - } value; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + ue_cap_enquiry_ies_s& ue_cap_enquiry() + { + assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const ue_cap_enquiry_ies_s& ue_cap_enquiry() const + { + assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "criticalExtensions"); + return c.get(); + } + ue_cap_enquiry_ies_s& set_ue_cap_enquiry() + { + set(types::ue_cap_enquiry); + return c.get(); + } - std::string to_string() const; - }; - typedef enumerated types; + private: + types type_; + choice_buffer_t c; - // choice methods - ng_n1_n2_c_() = default; - ng_n1_n2_c_(const ng_n1_n2_c_& other); - ng_n1_n2_c_& operator=(const ng_n1_n2_c_& other); - ~ng_n1_n2_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<8>& two_two_one_type_i_multi_panel_restrict() - { - assert_choice_type("two-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<16>& two_four_one_type_i_multi_panel_restrict() - { - assert_choice_type("two-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<8>& four_two_one_type_i_multi_panel_restrict() - { - assert_choice_type("four-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<64>& two_two_two_type_i_multi_panel_restrict() - { - assert_choice_type("two-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<32>& two_eight_one_type_i_multi_panel_restrict() - { - assert_choice_type("two-eight-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<16>& four_four_one_type_i_multi_panel_restrict() - { - assert_choice_type("four-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<128>& two_four_two_type_i_multi_panel_restrict() - { - assert_choice_type("two-four-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<64>& four_two_two_type_i_multi_panel_restrict() - { - assert_choice_type("four-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<8>& two_two_one_type_i_multi_panel_restrict() const - { - assert_choice_type("two-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<16>& two_four_one_type_i_multi_panel_restrict() const - { - assert_choice_type("two-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<8>& four_two_one_type_i_multi_panel_restrict() const - { - assert_choice_type("four-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<64>& two_two_two_type_i_multi_panel_restrict() const - { - assert_choice_type("two-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<32>& two_eight_one_type_i_multi_panel_restrict() const - { - assert_choice_type("two-eight-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<16>& four_four_one_type_i_multi_panel_restrict() const - { - assert_choice_type("four-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<128>& two_four_two_type_i_multi_panel_restrict() const - { - assert_choice_type("two-four-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - const fixed_bitstring<64>& four_two_two_type_i_multi_panel_restrict() const - { - assert_choice_type("four-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); - return c.get >(); - } - fixed_bitstring<8>& set_two_two_one_type_i_multi_panel_restrict() - { - set(types::two_two_one_type_i_multi_panel_restrict); - return c.get >(); - } - fixed_bitstring<16>& set_two_four_one_type_i_multi_panel_restrict() - { - set(types::two_four_one_type_i_multi_panel_restrict); - return c.get >(); - } - fixed_bitstring<8>& set_four_two_one_type_i_multi_panel_restrict() - { - set(types::four_two_one_type_i_multi_panel_restrict); - return c.get >(); - } - fixed_bitstring<64>& set_two_two_two_type_i_multi_panel_restrict() - { - set(types::two_two_two_type_i_multi_panel_restrict); - return c.get >(); - } - fixed_bitstring<32>& set_two_eight_one_type_i_multi_panel_restrict() - { - set(types::two_eight_one_type_i_multi_panel_restrict); - return c.get >(); - } - fixed_bitstring<16>& set_four_four_one_type_i_multi_panel_restrict() - { - set(types::four_four_one_type_i_multi_panel_restrict); - return c.get >(); - } - fixed_bitstring<128>& set_two_four_two_type_i_multi_panel_restrict() - { - set(types::two_four_two_type_i_multi_panel_restrict); - return c.get >(); - } - fixed_bitstring<64>& set_four_two_two_type_i_multi_panel_restrict() - { - set(types::four_two_two_type_i_multi_panel_restrict); - return c.get >(); - } + void destroy_(); + }; - private: - types type_; - choice_buffer_t > c; + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; - void destroy_(); - }; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - ng_n1_n2_c_ ng_n1_n2; - fixed_bitstring<4> ri_restrict; - }; - struct types_opts { - enum options { type_i_single_panel, type_i_multi_panel, nulltype } value; +// DL-DCCH-MessageType ::= CHOICE +struct dl_dcch_msg_type_c { + struct c1_c_ { + struct types_opts { + enum options { + rrc_recfg, + rrc_resume, + rrc_release, + rrc_reest, + security_mode_cmd, + dl_info_transfer, + ue_cap_enquiry, + counter_check, + mob_from_nr_cmd, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; - std::string to_string() const; - }; - typedef enumerated types; + std::string to_string() const; + }; + typedef enumerated types; - // choice methods - sub_type_c_() = default; - sub_type_c_(const sub_type_c_& other); - sub_type_c_& operator=(const sub_type_c_& other); - ~sub_type_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - type_i_single_panel_s_& type_i_single_panel() - { - assert_choice_type("typeI-SinglePanel", type_.to_string(), "subType"); - return c.get(); - } - type_i_multi_panel_s_& type_i_multi_panel() - { - assert_choice_type("typeI-MultiPanel", type_.to_string(), "subType"); - return c.get(); - } - const type_i_single_panel_s_& type_i_single_panel() const - { - assert_choice_type("typeI-SinglePanel", type_.to_string(), "subType"); - return c.get(); - } - const type_i_multi_panel_s_& type_i_multi_panel() const - { - assert_choice_type("typeI-MultiPanel", type_.to_string(), "subType"); - return c.get(); - } - type_i_single_panel_s_& set_type_i_single_panel() - { - set(types::type_i_single_panel); - return c.get(); - } - type_i_multi_panel_s_& set_type_i_multi_panel() - { - set(types::type_i_multi_panel); - return c.get(); - } + // choice methods + c1_c_() = default; + c1_c_(const c1_c_& other); + c1_c_& operator=(const c1_c_& other); + ~c1_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_recfg_s& rrc_recfg() + { + assert_choice_type("rrcReconfiguration", type_.to_string(), "c1"); + return c.get(); + } + rrc_resume_s& rrc_resume() + { + assert_choice_type("rrcResume", type_.to_string(), "c1"); + return c.get(); + } + rrc_release_s& rrc_release() + { + assert_choice_type("rrcRelease", type_.to_string(), "c1"); + return c.get(); + } + rrc_reest_s& rrc_reest() + { + assert_choice_type("rrcReestablishment", type_.to_string(), "c1"); + return c.get(); + } + security_mode_cmd_s& security_mode_cmd() + { + assert_choice_type("securityModeCommand", type_.to_string(), "c1"); + return c.get(); + } + dl_info_transfer_s& dl_info_transfer() + { + assert_choice_type("dlInformationTransfer", type_.to_string(), "c1"); + return c.get(); + } + ue_cap_enquiry_s& ue_cap_enquiry() + { + assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "c1"); + return c.get(); + } + counter_check_s& counter_check() + { + assert_choice_type("counterCheck", type_.to_string(), "c1"); + return c.get(); + } + mob_from_nr_cmd_s& mob_from_nr_cmd() + { + assert_choice_type("mobilityFromNRCommand", type_.to_string(), "c1"); + return c.get(); + } + const rrc_recfg_s& rrc_recfg() const + { + assert_choice_type("rrcReconfiguration", type_.to_string(), "c1"); + return c.get(); + } + const rrc_resume_s& rrc_resume() const + { + assert_choice_type("rrcResume", type_.to_string(), "c1"); + return c.get(); + } + const rrc_release_s& rrc_release() const + { + assert_choice_type("rrcRelease", type_.to_string(), "c1"); + return c.get(); + } + const rrc_reest_s& rrc_reest() const + { + assert_choice_type("rrcReestablishment", type_.to_string(), "c1"); + return c.get(); + } + const security_mode_cmd_s& security_mode_cmd() const + { + assert_choice_type("securityModeCommand", type_.to_string(), "c1"); + return c.get(); + } + const dl_info_transfer_s& dl_info_transfer() const + { + assert_choice_type("dlInformationTransfer", type_.to_string(), "c1"); + return c.get(); + } + const ue_cap_enquiry_s& ue_cap_enquiry() const + { + assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "c1"); + return c.get(); + } + const counter_check_s& counter_check() const + { + assert_choice_type("counterCheck", type_.to_string(), "c1"); + return c.get(); + } + const mob_from_nr_cmd_s& mob_from_nr_cmd() const + { + assert_choice_type("mobilityFromNRCommand", type_.to_string(), "c1"); + return c.get(); + } + rrc_recfg_s& set_rrc_recfg() + { + set(types::rrc_recfg); + return c.get(); + } + rrc_resume_s& set_rrc_resume() + { + set(types::rrc_resume); + return c.get(); + } + rrc_release_s& set_rrc_release() + { + set(types::rrc_release); + return c.get(); + } + rrc_reest_s& set_rrc_reest() + { + set(types::rrc_reest); + return c.get(); + } + security_mode_cmd_s& set_security_mode_cmd() + { + set(types::security_mode_cmd); + return c.get(); + } + dl_info_transfer_s& set_dl_info_transfer() + { + set(types::dl_info_transfer); + return c.get(); + } + ue_cap_enquiry_s& set_ue_cap_enquiry() + { + set(types::ue_cap_enquiry); + return c.get(); + } + counter_check_s& set_counter_check() + { + set(types::counter_check); + return c.get(); + } + mob_from_nr_cmd_s& set_mob_from_nr_cmd() + { + set(types::mob_from_nr_cmd); + return c.get(); + } - private: - types type_; - choice_buffer_t c; + private: + types type_; + choice_buffer_t + c; - void destroy_(); - }; + void destroy_(); + }; + struct types_opts { + enum options { c1, msg_class_ext, nulltype } value; + typedef uint8_t number_type; - // member variables - sub_type_c_ sub_type; - uint8_t codebook_mode = 1; - }; - struct type2_s_ { - struct sub_type_c_ { - struct type_ii_s_ { - struct n1_n2_codebook_subset_restrict_c_ { - struct types_opts { - enum options { - two_one, - two_two, - four_one, - three_two, - six_one, - four_two, - eight_one, - four_three, - six_two, - twelve_one, - four_four, - eight_two, - sixteen_one, - nulltype - } value; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - std::string to_string() const; - }; - typedef enumerated types; + // choice methods + dl_dcch_msg_type_c() = default; + dl_dcch_msg_type_c(const dl_dcch_msg_type_c& other); + dl_dcch_msg_type_c& operator=(const dl_dcch_msg_type_c& other); + ~dl_dcch_msg_type_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + c1_c_& c1() + { + assert_choice_type("c1", type_.to_string(), "DL-DCCH-MessageType"); + return c.get(); + } + const c1_c_& c1() const + { + assert_choice_type("c1", type_.to_string(), "DL-DCCH-MessageType"); + return c.get(); + } + c1_c_& set_c1() + { + set(types::c1); + return c.get(); + } - // choice methods - n1_n2_codebook_subset_restrict_c_() = default; - n1_n2_codebook_subset_restrict_c_(const n1_n2_codebook_subset_restrict_c_& other); - n1_n2_codebook_subset_restrict_c_& operator=(const n1_n2_codebook_subset_restrict_c_& other); - ~n1_n2_codebook_subset_restrict_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<16>& two_one() - { - assert_choice_type("two-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<43>& two_two() - { - assert_choice_type("two-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<32>& four_one() - { - assert_choice_type("four-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<59>& three_two() - { - assert_choice_type("three-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<48>& six_one() - { - assert_choice_type("six-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<75>& four_two() - { - assert_choice_type("four-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<64>& eight_one() - { - assert_choice_type("eight-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<107>& four_three() - { - assert_choice_type("four-three", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<107>& six_two() - { - assert_choice_type("six-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<96>& twelve_one() - { - assert_choice_type("twelve-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<139>& four_four() - { - assert_choice_type("four-four", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<139>& eight_two() - { - assert_choice_type("eight-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<128>& sixteen_one() - { - assert_choice_type("sixteen-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<16>& two_one() const - { - assert_choice_type("two-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<43>& two_two() const - { - assert_choice_type("two-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<32>& four_one() const - { - assert_choice_type("four-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<59>& three_two() const - { - assert_choice_type("three-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<48>& six_one() const - { - assert_choice_type("six-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<75>& four_two() const - { - assert_choice_type("four-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<64>& eight_one() const - { - assert_choice_type("eight-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<107>& four_three() const - { - assert_choice_type("four-three", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<107>& six_two() const - { - assert_choice_type("six-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<96>& twelve_one() const - { - assert_choice_type("twelve-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<139>& four_four() const - { - assert_choice_type("four-four", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<139>& eight_two() const - { - assert_choice_type("eight-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - const fixed_bitstring<128>& sixteen_one() const - { - assert_choice_type("sixteen-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); - return c.get >(); - } - fixed_bitstring<16>& set_two_one() - { - set(types::two_one); - return c.get >(); - } - fixed_bitstring<43>& set_two_two() - { - set(types::two_two); - return c.get >(); - } - fixed_bitstring<32>& set_four_one() - { - set(types::four_one); - return c.get >(); - } - fixed_bitstring<59>& set_three_two() - { - set(types::three_two); - return c.get >(); - } - fixed_bitstring<48>& set_six_one() - { - set(types::six_one); - return c.get >(); - } - fixed_bitstring<75>& set_four_two() - { - set(types::four_two); - return c.get >(); - } - fixed_bitstring<64>& set_eight_one() - { - set(types::eight_one); - return c.get >(); - } - fixed_bitstring<107>& set_four_three() - { - set(types::four_three); - return c.get >(); - } - fixed_bitstring<107>& set_six_two() - { - set(types::six_two); - return c.get >(); - } - fixed_bitstring<96>& set_twelve_one() - { - set(types::twelve_one); - return c.get >(); - } - fixed_bitstring<139>& set_four_four() - { - set(types::four_four); - return c.get >(); - } - fixed_bitstring<139>& set_eight_two() - { - set(types::eight_two); - return c.get >(); - } - fixed_bitstring<128>& set_sixteen_one() - { - set(types::sixteen_one); - return c.get >(); - } +private: + types type_; + choice_buffer_t c; - private: - types type_; - choice_buffer_t > c; + void destroy_(); +}; - void destroy_(); - }; +// DL-DCCH-Message ::= SEQUENCE +struct dl_dcch_msg_s { + dl_dcch_msg_type_c msg; - // member variables - n1_n2_codebook_subset_restrict_c_ n1_n2_codebook_subset_restrict; - fixed_bitstring<2> type_ii_ri_restrict; - }; - struct type_ii_port_sel_s_ { - struct port_sel_sampling_size_opts { - enum options { n1, n2, n3, n4, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated port_sel_sampling_size_e_; +// PagingUE-Identity ::= CHOICE +struct paging_ue_id_c { + struct types_opts { + enum options { ng_minus5_g_s_tmsi, full_i_rnti, /*...*/ nulltype } value; + typedef int8_t number_type; - // member variables - bool port_sel_sampling_size_present = false; - port_sel_sampling_size_e_ port_sel_sampling_size; - fixed_bitstring<2> type_ii_port_sel_ri_restrict; - }; - struct types_opts { - enum options { type_ii, type_ii_port_sel, nulltype } value; + std::string to_string() const; + int8_t to_number() const; + }; + typedef enumerated types; - std::string to_string() const; - }; - typedef enumerated types; + // choice methods + paging_ue_id_c() = default; + paging_ue_id_c(const paging_ue_id_c& other); + paging_ue_id_c& operator=(const paging_ue_id_c& other); + ~paging_ue_id_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<48>& ng_minus5_g_s_tmsi() + { + assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "PagingUE-Identity"); + return c.get >(); + } + fixed_bitstring<40>& full_i_rnti() + { + assert_choice_type("fullI-RNTI", type_.to_string(), "PagingUE-Identity"); + return c.get >(); + } + const fixed_bitstring<48>& ng_minus5_g_s_tmsi() const + { + assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "PagingUE-Identity"); + return c.get >(); + } + const fixed_bitstring<40>& full_i_rnti() const + { + assert_choice_type("fullI-RNTI", type_.to_string(), "PagingUE-Identity"); + return c.get >(); + } + fixed_bitstring<48>& set_ng_minus5_g_s_tmsi() + { + set(types::ng_minus5_g_s_tmsi); + return c.get >(); + } + fixed_bitstring<40>& set_full_i_rnti() + { + set(types::full_i_rnti); + return c.get >(); + } - // choice methods - sub_type_c_() = default; - sub_type_c_(const sub_type_c_& other); - sub_type_c_& operator=(const sub_type_c_& other); - ~sub_type_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - type_ii_s_& type_ii() - { - assert_choice_type("typeII", type_.to_string(), "subType"); - return c.get(); - } - type_ii_port_sel_s_& type_ii_port_sel() - { - assert_choice_type("typeII-PortSelection", type_.to_string(), "subType"); - return c.get(); - } - const type_ii_s_& type_ii() const - { - assert_choice_type("typeII", type_.to_string(), "subType"); - return c.get(); - } - const type_ii_port_sel_s_& type_ii_port_sel() const - { - assert_choice_type("typeII-PortSelection", type_.to_string(), "subType"); - return c.get(); - } - type_ii_s_& set_type_ii() - { - set(types::type_ii); - return c.get(); - } - type_ii_port_sel_s_& set_type_ii_port_sel() - { - set(types::type_ii_port_sel); - return c.get(); - } +private: + types type_; + choice_buffer_t > c; - private: - types type_; - choice_buffer_t c; + void destroy_(); +}; - void destroy_(); - }; - struct phase_alphabet_size_opts { - enum options { n4, n8, nulltype } value; - typedef uint8_t number_type; +// PagingRecord ::= SEQUENCE +struct paging_record_s { + bool ext = false; + bool access_type_present = false; + paging_ue_id_c ue_id; + // ... - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated phase_alphabet_size_e_; - struct nof_beams_opts { - enum options { two, three, four, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated nof_beams_e_; +// PagingRecordList ::= SEQUENCE (SIZE (1..32)) OF PagingRecord +using paging_record_list_l = dyn_array; - // member variables - sub_type_c_ sub_type; - phase_alphabet_size_e_ phase_alphabet_size; - bool subband_amplitude = false; - nof_beams_e_ nof_beams; - }; +// Paging ::= SEQUENCE +struct paging_s { + bool paging_record_list_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + paging_record_list_l paging_record_list; + dyn_octstring late_non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PCCH-MessageType ::= CHOICE +struct pcch_msg_type_c { + struct c1_c_ { struct types_opts { - enum options { type1, type2, nulltype } value; - typedef uint8_t number_type; + enum options { paging, spare1, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; typedef enumerated types; // choice methods - codebook_type_c_() = default; - codebook_type_c_(const codebook_type_c_& other); - codebook_type_c_& operator=(const codebook_type_c_& other); - ~codebook_type_c_() { destroy_(); } + c1_c_() = default; void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - type1_s_& type1() - { - assert_choice_type("type1", type_.to_string(), "codebookType"); - return c.get(); - } - type2_s_& type2() - { - assert_choice_type("type2", type_.to_string(), "codebookType"); - return c.get(); - } - const type1_s_& type1() const - { - assert_choice_type("type1", type_.to_string(), "codebookType"); - return c.get(); - } - const type2_s_& type2() const + paging_s& paging() { - assert_choice_type("type2", type_.to_string(), "codebookType"); - return c.get(); + assert_choice_type("paging", type_.to_string(), "c1"); + return c; } - type1_s_& set_type1() + const paging_s& paging() const { - set(types::type1); - return c.get(); + assert_choice_type("paging", type_.to_string(), "c1"); + return c; } - type2_s_& set_type2() + paging_s& set_paging() { - set(types::type2); - return c.get(); + set(types::paging); + return c; } private: - types type_; - choice_buffer_t c; - - void destroy_(); + types type_; + paging_s c; }; + struct types_opts { + enum options { c1, msg_class_ext, nulltype } value; + typedef uint8_t number_type; - // member variables - codebook_type_c_ codebook_type; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - // sequence methods + // choice methods + pcch_msg_type_c() = default; + pcch_msg_type_c(const pcch_msg_type_c& other); + pcch_msg_type_c& operator=(const pcch_msg_type_c& other); + ~pcch_msg_type_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; -}; - -// EUTRA-MBSFN-SubframeConfigList ::= SEQUENCE (SIZE (1..8)) OF EUTRA-MBSFN-SubframeConfig -using eutra_mbsfn_sf_cfg_list_l = dyn_array; + // getters + c1_c_& c1() + { + assert_choice_type("c1", type_.to_string(), "PCCH-MessageType"); + return c.get(); + } + const c1_c_& c1() const + { + assert_choice_type("c1", type_.to_string(), "PCCH-MessageType"); + return c.get(); + } + c1_c_& set_c1() + { + set(types::c1); + return c.get(); + } -// FrequencyInfoDL ::= SEQUENCE -struct freq_info_dl_s { - using scs_specific_carrier_list_l_ = dyn_array; +private: + types type_; + choice_buffer_t c; - // member variables - bool ext = false; - bool absolute_freq_ssb_present = false; - uint32_t absolute_freq_ssb = 0; - multi_freq_band_list_nr_l freq_band_list; - uint32_t absolute_freq_point_a = 0; - scs_specific_carrier_list_l_ scs_specific_carrier_list; - // ... + void destroy_(); +}; + +// PCCH-Message ::= SEQUENCE +struct pcch_msg_s { + pcch_msg_type_c msg; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -9220,56 +8424,97 @@ struct freq_info_dl_s { void to_json(json_writer& j) const; }; -// FrequencyInfoUL ::= SEQUENCE -struct freq_info_ul_s { - using scs_specific_carrier_list_l_ = dyn_array; +// EstablishmentCause ::= ENUMERATED +struct establishment_cause_opts { + enum options { + emergency, + high_prio_access, + mt_access, + mo_sig, + mo_data, + mo_voice_call, + mo_video_call, + mo_sms, + mps_prio_access, + mcs_prio_access, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; - // member variables - bool ext = false; - bool freq_band_list_present = false; - bool absolute_freq_point_a_present = false; - bool add_spec_emission_present = false; - bool p_max_present = false; - bool freq_shift7p5khz_present = false; - multi_freq_band_list_nr_l freq_band_list; - uint32_t absolute_freq_point_a = 0; - scs_specific_carrier_list_l_ scs_specific_carrier_list; - uint8_t add_spec_emission = 0; - int8_t p_max = -30; - // ... + std::string to_string() const; +}; +typedef enumerated establishment_cause_e; - // sequence methods +// InitialUE-Identity ::= CHOICE +struct init_ue_id_c { + struct types_opts { + enum options { ng_minus5_g_s_tmsi_part1, random_value, nulltype } value; + typedef int8_t number_type; + + std::string to_string() const; + int8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + init_ue_id_c() = default; + init_ue_id_c(const init_ue_id_c& other); + init_ue_id_c& operator=(const init_ue_id_c& other); + ~init_ue_id_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; -}; + // getters + fixed_bitstring<39>& ng_minus5_g_s_tmsi_part1() + { + assert_choice_type("ng-5G-S-TMSI-Part1", type_.to_string(), "InitialUE-Identity"); + return c.get >(); + } + fixed_bitstring<39>& random_value() + { + assert_choice_type("randomValue", type_.to_string(), "InitialUE-Identity"); + return c.get >(); + } + const fixed_bitstring<39>& ng_minus5_g_s_tmsi_part1() const + { + assert_choice_type("ng-5G-S-TMSI-Part1", type_.to_string(), "InitialUE-Identity"); + return c.get >(); + } + const fixed_bitstring<39>& random_value() const + { + assert_choice_type("randomValue", type_.to_string(), "InitialUE-Identity"); + return c.get >(); + } + fixed_bitstring<39>& set_ng_minus5_g_s_tmsi_part1() + { + set(types::ng_minus5_g_s_tmsi_part1); + return c.get >(); + } + fixed_bitstring<39>& set_random_value() + { + set(types::random_value); + return c.get >(); + } -// PDCCH-Config ::= SEQUENCE -struct pdcch_cfg_s { - using ctrl_res_set_to_add_mod_list_l_ = dyn_array; - using ctrl_res_set_to_release_list_l_ = bounded_array; - using search_spaces_to_add_mod_list_l_ = dyn_array; - using search_spaces_to_release_list_l_ = bounded_array; +private: + types type_; + choice_buffer_t > c; - // member variables - bool ext = false; - bool ctrl_res_set_to_add_mod_list_present = false; - bool ctrl_res_set_to_release_list_present = false; - bool search_spaces_to_add_mod_list_present = false; - bool search_spaces_to_release_list_present = false; - bool dl_preemption_present = false; - bool tpc_pusch_present = false; - bool tpc_pucch_present = false; - bool tpc_srs_present = false; - ctrl_res_set_to_add_mod_list_l_ ctrl_res_set_to_add_mod_list; - ctrl_res_set_to_release_list_l_ ctrl_res_set_to_release_list; - search_spaces_to_add_mod_list_l_ search_spaces_to_add_mod_list; - search_spaces_to_release_list_l_ search_spaces_to_release_list; - setup_release_c dl_preemption; - setup_release_c tpc_pusch; - setup_release_c tpc_pucch; - setup_release_c tpc_srs; - // ... + void destroy_(); +}; + +// ReestabUE-Identity ::= SEQUENCE +struct reestab_ue_id_s { + uint32_t c_rnti = 0; + uint16_t pci = 0; + fixed_bitstring<16> short_mac_i; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -9277,240 +8522,164 @@ struct pdcch_cfg_s { void to_json(json_writer& j) const; }; -// PDSCH-Config ::= SEQUENCE -struct pdsch_cfg_s { - using tci_states_to_add_mod_list_l_ = dyn_array; - using tci_states_to_release_list_l_ = dyn_array; - struct vrb_to_prb_interleaver_opts { - enum options { n2, n4, nulltype } value; - typedef uint8_t number_type; +// ReestablishmentCause ::= ENUMERATED +struct reest_cause_opts { + enum options { recfg_fail, ho_fail, other_fail, spare1, nulltype } value; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated vrb_to_prb_interleaver_e_; - struct res_alloc_opts { - enum options { res_alloc_type0, res_alloc_type1, dynamic_switch, nulltype } value; - typedef uint8_t number_type; + std::string to_string() const; +}; +typedef enumerated reest_cause_e; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated res_alloc_e_; - struct pdsch_aggregation_factor_opts { - enum options { n2, n4, n8, nulltype } value; - typedef uint8_t number_type; +// ResumeCause ::= ENUMERATED +struct resume_cause_opts { + enum options { + emergency, + high_prio_access, + mt_access, + mo_sig, + mo_data, + mo_voice_call, + mo_video_call, + mo_sms, + rna_upd, + mps_prio_access, + mcs_prio_access, + spare1, + spare2, + spare3, + spare4, + spare5, + nulltype + } value; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated pdsch_aggregation_factor_e_; - using rate_match_pattern_to_add_mod_list_l_ = dyn_array; - using rate_match_pattern_to_release_list_l_ = bounded_array; - struct rbg_size_opts { - enum options { cfg1, cfg2, nulltype } value; - typedef uint8_t number_type; + std::string to_string() const; +}; +typedef enumerated resume_cause_e; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated rbg_size_e_; - struct mcs_table_opts { - enum options { qam256, qam64_low_se, nulltype } value; - typedef uint16_t number_type; +// RRCReestablishmentRequest-IEs ::= SEQUENCE +struct rrc_reest_request_ies_s { + reestab_ue_id_s ue_id; + reest_cause_e reest_cause; + fixed_bitstring<1> spare; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated mcs_table_e_; - struct max_nrof_code_words_sched_by_dci_opts { - enum options { n1, n2, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_nrof_code_words_sched_by_dci_e_; - struct prb_bundling_type_c_ { - struct static_bundling_s_ { - struct bundle_size_opts { - enum options { n4, wideband, nulltype } value; - typedef uint8_t number_type; +// RRCResumeRequest-IEs ::= SEQUENCE +struct rrc_resume_request_ies_s { + fixed_bitstring<24> resume_id; + fixed_bitstring<16> resume_mac_i; + resume_cause_e resume_cause; + fixed_bitstring<1> spare; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated bundle_size_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool bundle_size_present = false; - bundle_size_e_ bundle_size; - }; - struct dynamic_bundling_s_ { - struct bundle_size_set1_opts { - enum options { n4, wideband, n2_wideband, n4_wideband, nulltype } value; +// RRCSetupRequest-IEs ::= SEQUENCE +struct rrc_setup_request_ies_s { + init_ue_id_c ue_id; + establishment_cause_e establishment_cause; + fixed_bitstring<1> spare; - std::string to_string() const; - }; - typedef enumerated bundle_size_set1_e_; - struct bundle_size_set2_opts { - enum options { n4, wideband, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated bundle_size_set2_e_; +// RRCSystemInfoRequest-IEs ::= SEQUENCE +struct rrc_sys_info_request_ies_s { + fixed_bitstring<32> requested_si_list; + fixed_bitstring<12> spare; - // member variables - bool bundle_size_set1_present = false; - bool bundle_size_set2_present = false; - bundle_size_set1_e_ bundle_size_set1; - bundle_size_set2_e_ bundle_size_set2; - }; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RRCReestablishmentRequest ::= SEQUENCE +struct rrc_reest_request_s { + rrc_reest_request_ies_s rrc_reest_request; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RRCResumeRequest ::= SEQUENCE +struct rrc_resume_request_s { + rrc_resume_request_ies_s rrc_resume_request; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RRCSetupRequest ::= SEQUENCE +struct rrc_setup_request_s { + rrc_setup_request_ies_s rrc_setup_request; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RRCSystemInfoRequest ::= SEQUENCE +struct rrc_sys_info_request_s { + struct crit_exts_c_ { struct types_opts { - enum options { static_bundling, dynamic_bundling, nulltype } value; + enum options { rrc_sys_info_request, crit_exts_future, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - prb_bundling_type_c_() = default; - prb_bundling_type_c_(const prb_bundling_type_c_& other); - prb_bundling_type_c_& operator=(const prb_bundling_type_c_& other); - ~prb_bundling_type_c_() { destroy_(); } + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - static_bundling_s_& static_bundling() - { - assert_choice_type("staticBundling", type_.to_string(), "prb-BundlingType"); - return c.get(); - } - dynamic_bundling_s_& dynamic_bundling() - { - assert_choice_type("dynamicBundling", type_.to_string(), "prb-BundlingType"); - return c.get(); - } - const static_bundling_s_& static_bundling() const - { - assert_choice_type("staticBundling", type_.to_string(), "prb-BundlingType"); - return c.get(); - } - const dynamic_bundling_s_& dynamic_bundling() const + rrc_sys_info_request_ies_s& rrc_sys_info_request() { - assert_choice_type("dynamicBundling", type_.to_string(), "prb-BundlingType"); - return c.get(); + assert_choice_type("rrcSystemInfoRequest", type_.to_string(), "criticalExtensions"); + return c.get(); } - static_bundling_s_& set_static_bundling() + const rrc_sys_info_request_ies_s& rrc_sys_info_request() const { - set(types::static_bundling); - return c.get(); + assert_choice_type("rrcSystemInfoRequest", type_.to_string(), "criticalExtensions"); + return c.get(); } - dynamic_bundling_s_& set_dynamic_bundling() + rrc_sys_info_request_ies_s& set_rrc_sys_info_request() { - set(types::dynamic_bundling); - return c.get(); + set(types::rrc_sys_info_request); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - using zp_csi_rs_res_to_add_mod_list_l_ = dyn_array; - using zp_csi_rs_res_to_release_list_l_ = bounded_array; - using aperiodic_zp_csi_rs_res_sets_to_add_mod_list_l_ = dyn_array; - using aperiodic_zp_csi_rs_res_sets_to_release_list_l_ = bounded_array; - using sp_zp_csi_rs_res_sets_to_add_mod_list_l_ = dyn_array; - using sp_zp_csi_rs_res_sets_to_release_list_l_ = bounded_array; - - // member variables - bool ext = false; - bool data_scrambling_id_pdsch_present = false; - bool dmrs_dl_for_pdsch_map_type_a_present = false; - bool dmrs_dl_for_pdsch_map_type_b_present = false; - bool tci_states_to_add_mod_list_present = false; - bool tci_states_to_release_list_present = false; - bool vrb_to_prb_interleaver_present = false; - bool pdsch_time_domain_alloc_list_present = false; - bool pdsch_aggregation_factor_present = false; - bool rate_match_pattern_to_add_mod_list_present = false; - bool rate_match_pattern_to_release_list_present = false; - bool rate_match_pattern_group1_present = false; - bool rate_match_pattern_group2_present = false; - bool mcs_table_present = false; - bool max_nrof_code_words_sched_by_dci_present = false; - bool zp_csi_rs_res_to_add_mod_list_present = false; - bool zp_csi_rs_res_to_release_list_present = false; - bool aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present = false; - bool aperiodic_zp_csi_rs_res_sets_to_release_list_present = false; - bool sp_zp_csi_rs_res_sets_to_add_mod_list_present = false; - bool sp_zp_csi_rs_res_sets_to_release_list_present = false; - bool p_zp_csi_rs_res_set_present = false; - uint16_t data_scrambling_id_pdsch = 0; - setup_release_c dmrs_dl_for_pdsch_map_type_a; - setup_release_c dmrs_dl_for_pdsch_map_type_b; - tci_states_to_add_mod_list_l_ tci_states_to_add_mod_list; - tci_states_to_release_list_l_ tci_states_to_release_list; - vrb_to_prb_interleaver_e_ vrb_to_prb_interleaver; - res_alloc_e_ res_alloc; - setup_release_c > pdsch_time_domain_alloc_list; - pdsch_aggregation_factor_e_ pdsch_aggregation_factor; - rate_match_pattern_to_add_mod_list_l_ rate_match_pattern_to_add_mod_list; - rate_match_pattern_to_release_list_l_ rate_match_pattern_to_release_list; - rate_match_pattern_group_l rate_match_pattern_group1; - rate_match_pattern_group_l rate_match_pattern_group2; - rbg_size_e_ rbg_size; - mcs_table_e_ mcs_table; - max_nrof_code_words_sched_by_dci_e_ max_nrof_code_words_sched_by_dci; - prb_bundling_type_c_ prb_bundling_type; - zp_csi_rs_res_to_add_mod_list_l_ zp_csi_rs_res_to_add_mod_list; - zp_csi_rs_res_to_release_list_l_ zp_csi_rs_res_to_release_list; - aperiodic_zp_csi_rs_res_sets_to_add_mod_list_l_ aperiodic_zp_csi_rs_res_sets_to_add_mod_list; - aperiodic_zp_csi_rs_res_sets_to_release_list_l_ aperiodic_zp_csi_rs_res_sets_to_release_list; - sp_zp_csi_rs_res_sets_to_add_mod_list_l_ sp_zp_csi_rs_res_sets_to_add_mod_list; - sp_zp_csi_rs_res_sets_to_release_list_l_ sp_zp_csi_rs_res_sets_to_release_list; - setup_release_c p_zp_csi_rs_res_set; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PUCCH-CSI-Resource ::= SEQUENCE -struct pucch_csi_res_s { - uint8_t ul_bw_part_id = 0; - uint8_t pucch_res = 0; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PUSCH-CodeBlockGroupTransmission ::= SEQUENCE -struct pusch_code_block_group_tx_s { - struct max_code_block_groups_per_transport_block_opts { - enum options { n2, n4, n6, n8, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_code_block_groups_per_transport_block_e_; // member variables - bool ext = false; - max_code_block_groups_per_transport_block_e_ max_code_block_groups_per_transport_block; - // ... + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -9518,61 +8687,96 @@ struct pusch_code_block_group_tx_s { void to_json(json_writer& j) const; }; -// PortIndexFor8Ranks ::= CHOICE -struct port_idx_for8_ranks_c { - struct port_idx8_s_ { - using rank2_minus8_l_ = std::array; - using rank3_minus8_l_ = std::array; - using rank4_minus8_l_ = std::array; - using rank5_minus8_l_ = std::array; - using rank6_minus8_l_ = std::array; - using rank7_minus8_l_ = std::array; - using rank8_minus8_l_ = std::array; +// UL-CCCH-MessageType ::= CHOICE +struct ul_ccch_msg_type_c { + struct c1_c_ { + struct types_opts { + enum options { rrc_setup_request, rrc_resume_request, rrc_reest_request, rrc_sys_info_request, nulltype } value; - // member variables - bool rank1_minus8_present = false; - bool rank2_minus8_present = false; - bool rank3_minus8_present = false; - bool rank4_minus8_present = false; - bool rank5_minus8_present = false; - bool rank6_minus8_present = false; - bool rank7_minus8_present = false; - bool rank8_minus8_present = false; - uint8_t rank1_minus8 = 0; - rank2_minus8_l_ rank2_minus8; - rank3_minus8_l_ rank3_minus8; - rank4_minus8_l_ rank4_minus8; - rank5_minus8_l_ rank5_minus8; - rank6_minus8_l_ rank6_minus8; - rank7_minus8_l_ rank7_minus8; - rank8_minus8_l_ rank8_minus8; - }; - struct port_idx4_s_ { - using rank2_minus4_l_ = std::array; - using rank3_minus4_l_ = std::array; - using rank4_minus4_l_ = std::array; + std::string to_string() const; + }; + typedef enumerated types; - // member variables - bool rank1_minus4_present = false; - bool rank2_minus4_present = false; - bool rank3_minus4_present = false; - bool rank4_minus4_present = false; - uint8_t rank1_minus4 = 0; - rank2_minus4_l_ rank2_minus4; - rank3_minus4_l_ rank3_minus4; - rank4_minus4_l_ rank4_minus4; - }; - struct port_idx2_s_ { - using rank2_minus2_l_ = std::array; + // choice methods + c1_c_() = default; + c1_c_(const c1_c_& other); + c1_c_& operator=(const c1_c_& other); + ~c1_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_setup_request_s& rrc_setup_request() + { + assert_choice_type("rrcSetupRequest", type_.to_string(), "c1"); + return c.get(); + } + rrc_resume_request_s& rrc_resume_request() + { + assert_choice_type("rrcResumeRequest", type_.to_string(), "c1"); + return c.get(); + } + rrc_reest_request_s& rrc_reest_request() + { + assert_choice_type("rrcReestablishmentRequest", type_.to_string(), "c1"); + return c.get(); + } + rrc_sys_info_request_s& rrc_sys_info_request() + { + assert_choice_type("rrcSystemInfoRequest", type_.to_string(), "c1"); + return c.get(); + } + const rrc_setup_request_s& rrc_setup_request() const + { + assert_choice_type("rrcSetupRequest", type_.to_string(), "c1"); + return c.get(); + } + const rrc_resume_request_s& rrc_resume_request() const + { + assert_choice_type("rrcResumeRequest", type_.to_string(), "c1"); + return c.get(); + } + const rrc_reest_request_s& rrc_reest_request() const + { + assert_choice_type("rrcReestablishmentRequest", type_.to_string(), "c1"); + return c.get(); + } + const rrc_sys_info_request_s& rrc_sys_info_request() const + { + assert_choice_type("rrcSystemInfoRequest", type_.to_string(), "c1"); + return c.get(); + } + rrc_setup_request_s& set_rrc_setup_request() + { + set(types::rrc_setup_request); + return c.get(); + } + rrc_resume_request_s& set_rrc_resume_request() + { + set(types::rrc_resume_request); + return c.get(); + } + rrc_reest_request_s& set_rrc_reest_request() + { + set(types::rrc_reest_request); + return c.get(); + } + rrc_sys_info_request_s& set_rrc_sys_info_request() + { + set(types::rrc_sys_info_request); + return c.get(); + } - // member variables - bool rank1_minus2_present = false; - bool rank2_minus2_present = false; - uint8_t rank1_minus2 = 0; - rank2_minus2_l_ rank2_minus2; + private: + types type_; + choice_buffer_t c; + + void destroy_(); }; struct types_opts { - enum options { port_idx8, port_idx4, port_idx2, port_idx1, nulltype } value; + enum options { c1, msg_class_ext, nulltype } value; typedef uint8_t number_type; std::string to_string() const; @@ -9581,101 +8785,42 @@ struct port_idx_for8_ranks_c { typedef enumerated types; // choice methods - port_idx_for8_ranks_c() = default; - port_idx_for8_ranks_c(const port_idx_for8_ranks_c& other); - port_idx_for8_ranks_c& operator=(const port_idx_for8_ranks_c& other); - ~port_idx_for8_ranks_c() { destroy_(); } + ul_ccch_msg_type_c() = default; + ul_ccch_msg_type_c(const ul_ccch_msg_type_c& other); + ul_ccch_msg_type_c& operator=(const ul_ccch_msg_type_c& other); + ~ul_ccch_msg_type_c() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - port_idx8_s_& port_idx8() - { - assert_choice_type("portIndex8", type_.to_string(), "PortIndexFor8Ranks"); - return c.get(); - } - port_idx4_s_& port_idx4() - { - assert_choice_type("portIndex4", type_.to_string(), "PortIndexFor8Ranks"); - return c.get(); - } - port_idx2_s_& port_idx2() - { - assert_choice_type("portIndex2", type_.to_string(), "PortIndexFor8Ranks"); - return c.get(); - } - const port_idx8_s_& port_idx8() const - { - assert_choice_type("portIndex8", type_.to_string(), "PortIndexFor8Ranks"); - return c.get(); - } - const port_idx4_s_& port_idx4() const - { - assert_choice_type("portIndex4", type_.to_string(), "PortIndexFor8Ranks"); - return c.get(); - } - const port_idx2_s_& port_idx2() const - { - assert_choice_type("portIndex2", type_.to_string(), "PortIndexFor8Ranks"); - return c.get(); - } - port_idx8_s_& set_port_idx8() + c1_c_& c1() { - set(types::port_idx8); - return c.get(); + assert_choice_type("c1", type_.to_string(), "UL-CCCH-MessageType"); + return c.get(); } - port_idx4_s_& set_port_idx4() + const c1_c_& c1() const { - set(types::port_idx4); - return c.get(); + assert_choice_type("c1", type_.to_string(), "UL-CCCH-MessageType"); + return c.get(); } - port_idx2_s_& set_port_idx2() + c1_c_& set_c1() { - set(types::port_idx2); - return c.get(); + set(types::c1); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; -// RadioLinkMonitoringConfig ::= SEQUENCE -struct radio_link_monitoring_cfg_s { - using fail_detection_res_to_add_mod_list_l_ = dyn_array; - using fail_detection_res_to_release_list_l_ = bounded_array; - struct beam_fail_instance_max_count_opts { - enum options { n1, n2, n3, n4, n5, n6, n8, n10, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated beam_fail_instance_max_count_e_; - struct beam_fail_detection_timer_opts { - enum options { pbfd1, pbfd2, pbfd3, pbfd4, pbfd5, pbfd6, pbfd8, pbfd10, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated beam_fail_detection_timer_e_; - - // member variables - bool ext = false; - bool fail_detection_res_to_add_mod_list_present = false; - bool fail_detection_res_to_release_list_present = false; - bool beam_fail_instance_max_count_present = false; - bool beam_fail_detection_timer_present = false; - fail_detection_res_to_add_mod_list_l_ fail_detection_res_to_add_mod_list; - fail_detection_res_to_release_list_l_ fail_detection_res_to_release_list; - beam_fail_instance_max_count_e_ beam_fail_instance_max_count; - beam_fail_detection_timer_e_ beam_fail_detection_timer; - // ... +// UL-CCCH-Message ::= SEQUENCE +struct ul_ccch_msg_s { + ul_ccch_msg_type_c msg; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -9683,43 +8828,12 @@ struct radio_link_monitoring_cfg_s { void to_json(json_writer& j) const; }; -// SPS-Config ::= SEQUENCE -struct sps_cfg_s { - struct periodicity_opts { - enum options { - ms10, - ms20, - ms32, - ms40, - ms64, - ms80, - ms128, - ms160, - ms320, - ms640, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated periodicity_e_; - - // member variables - bool ext = false; - bool n1_pucch_an_present = false; - bool mcs_table_present = false; - periodicity_e_ periodicity; - uint8_t nrof_harq_processes = 1; - uint8_t n1_pucch_an = 0; - // ... +// RRCResumeRequest1-IEs ::= SEQUENCE +struct rrc_resume_request1_ies_s { + fixed_bitstring<40> resume_id; + fixed_bitstring<16> resume_mac_i; + resume_cause_e resume_cause; + fixed_bitstring<1> spare; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -9727,13 +8841,9 @@ struct sps_cfg_s { void to_json(json_writer& j) const; }; -// SRS-TPC-PDCCH-Config ::= SEQUENCE -struct srs_tpc_pdcch_cfg_s { - using srs_cc_set_idxlist_l_ = dyn_array; - - // member variables - bool srs_cc_set_idxlist_present = false; - srs_cc_set_idxlist_l_ srs_cc_set_idxlist; +// RRCResumeRequest1 ::= SEQUENCE +struct rrc_resume_request1_s { + rrc_resume_request1_ies_s rrc_resume_request1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -9741,270 +8851,246 @@ struct srs_tpc_pdcch_cfg_s { void to_json(json_writer& j) const; }; -// SlotFormatCombinationsPerCell ::= SEQUENCE -struct slot_format_combinations_per_cell_s { - using slot_format_combinations_l_ = dyn_array; - - // member variables - bool ext = false; - bool subcarrier_spacing2_present = false; - bool slot_format_combinations_present = false; - bool position_in_dci_present = false; - uint8_t serving_cell_id = 0; - subcarrier_spacing_e subcarrier_spacing; - subcarrier_spacing_e subcarrier_spacing2; - slot_format_combinations_l_ slot_format_combinations; - uint8_t position_in_dci = 0; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BWP-DownlinkDedicated ::= SEQUENCE -struct bwp_dl_ded_s { - bool ext = false; - bool pdcch_cfg_present = false; - bool pdsch_cfg_present = false; - bool sps_cfg_present = false; - bool radio_link_monitoring_cfg_present = false; - setup_release_c pdcch_cfg; - setup_release_c pdsch_cfg; - setup_release_c sps_cfg; - setup_release_c radio_link_monitoring_cfg; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BWP-Uplink ::= SEQUENCE -struct bwp_ul_s { - bool ext = false; - bool bwp_common_present = false; - bool bwp_ded_present = false; - uint8_t bwp_id = 0; - bwp_ul_common_s bwp_common; - bwp_ul_ded_s bwp_ded; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CFRA ::= SEQUENCE -struct cfra_s { - struct occasions_s_ { - struct ssb_per_rach_occasion_opts { - enum options { one_eighth, one_fourth, one_half, one, two, four, eight, sixteen, nulltype } value; - typedef float number_type; - - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated ssb_per_rach_occasion_e_; - - // member variables - bool ssb_per_rach_occasion_present = false; - rach_cfg_generic_s rach_cfg_generic; - ssb_per_rach_occasion_e_ ssb_per_rach_occasion; - }; - struct res_c_ { - struct ssb_s_ { - using ssb_res_list_l_ = dyn_array; - - // member variables - ssb_res_list_l_ ssb_res_list; - uint8_t ra_ssb_occasion_mask_idx = 0; - }; - struct csirs_s_ { - using csirs_res_list_l_ = dyn_array; - - // member variables - csirs_res_list_l_ csirs_res_list; - uint8_t rsrp_thres_csi_rs = 0; - }; - struct types_opts { - enum options { ssb, csirs, nulltype } value; +// UL-CCCH1-MessageType ::= CHOICE +struct ul_ccch1_msg_type_c { + struct c1_c_ { + struct types_opts { + enum options { rrc_resume_request1, spare3, spare2, spare1, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; typedef enumerated types; // choice methods - res_c_() = default; - res_c_(const res_c_& other); - res_c_& operator=(const res_c_& other); - ~res_c_() { destroy_(); } + c1_c_() = default; void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - ssb_s_& ssb() - { - assert_choice_type("ssb", type_.to_string(), "resources"); - return c.get(); - } - csirs_s_& csirs() - { - assert_choice_type("csirs", type_.to_string(), "resources"); - return c.get(); - } - const ssb_s_& ssb() const - { - assert_choice_type("ssb", type_.to_string(), "resources"); - return c.get(); - } - const csirs_s_& csirs() const + rrc_resume_request1_s& rrc_resume_request1() { - assert_choice_type("csirs", type_.to_string(), "resources"); - return c.get(); + assert_choice_type("rrcResumeRequest1", type_.to_string(), "c1"); + return c; } - ssb_s_& set_ssb() + const rrc_resume_request1_s& rrc_resume_request1() const { - set(types::ssb); - return c.get(); + assert_choice_type("rrcResumeRequest1", type_.to_string(), "c1"); + return c; } - csirs_s_& set_csirs() + rrc_resume_request1_s& set_rrc_resume_request1() { - set(types::csirs); - return c.get(); + set(types::rrc_resume_request1); + return c; } private: - types type_; - choice_buffer_t c; - - void destroy_(); + types type_; + rrc_resume_request1_s c; }; + struct types_opts { + enum options { c1, msg_class_ext, nulltype } value; + typedef uint8_t number_type; - // member variables - bool ext = false; - bool occasions_present = false; - occasions_s_ occasions; - res_c_ res; - // ... - // group 0 - bool total_nof_ra_preambs_v1530_present = false; - uint8_t total_nof_ra_preambs_v1530 = 1; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - // sequence methods + // choice methods + ul_ccch1_msg_type_c() = default; + ul_ccch1_msg_type_c(const ul_ccch1_msg_type_c& other); + ul_ccch1_msg_type_c& operator=(const ul_ccch1_msg_type_c& other); + ~ul_ccch1_msg_type_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; -}; + // getters + c1_c_& c1() + { + assert_choice_type("c1", type_.to_string(), "UL-CCCH1-MessageType"); + return c.get(); + } + const c1_c_& c1() const + { + assert_choice_type("c1", type_.to_string(), "UL-CCCH1-MessageType"); + return c.get(); + } + c1_c_& set_c1() + { + set(types::c1); + return c.get(); + } -// CSI-AperiodicTriggerStateList ::= SEQUENCE (SIZE (1..128)) OF CSI-AperiodicTriggerState -using csi_aperiodic_trigger_state_list_l = dyn_array; +private: + types type_; + choice_buffer_t c; -// CSI-IM-Resource ::= SEQUENCE -struct csi_im_res_s { - struct csi_im_res_elem_pattern_c_ { - struct pattern0_s_ { - struct subcarrier_location_p0_opts { - enum options { s0, s2, s4, s6, s8, s10, nulltype } value; - typedef uint8_t number_type; + void destroy_(); +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated subcarrier_location_p0_e_; +// UL-CCCH1-Message ::= SEQUENCE +struct ul_ccch1_msg_s { + ul_ccch1_msg_type_c msg; - // member variables - subcarrier_location_p0_e_ subcarrier_location_p0; - uint8_t symbol_location_p0 = 0; - }; - struct pattern1_s_ { - struct subcarrier_location_p1_opts { - enum options { s0, s4, s8, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated subcarrier_location_p1_e_; +// MeasQuantityResults ::= SEQUENCE +struct meas_quant_results_s { + bool rsrp_present = false; + bool rsrq_present = false; + bool sinr_present = false; + uint8_t rsrp = 0; + uint8_t rsrq = 0; + uint8_t sinr = 0; - // member variables - subcarrier_location_p1_e_ subcarrier_location_p1; - uint8_t symbol_location_p1 = 0; - }; - struct types_opts { - enum options { pattern0, pattern1, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; +// PLMN-Identity-EUTRA-5GC ::= CHOICE +struct plmn_id_eutra_minus5_gc_c { + struct types_opts { + enum options { plmn_id_eutra_minus5_gc, plmn_idx, nulltype } value; + typedef int8_t number_type; - // choice methods - csi_im_res_elem_pattern_c_() = default; - csi_im_res_elem_pattern_c_(const csi_im_res_elem_pattern_c_& other); - csi_im_res_elem_pattern_c_& operator=(const csi_im_res_elem_pattern_c_& other); - ~csi_im_res_elem_pattern_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - pattern0_s_& pattern0() - { - assert_choice_type("pattern0", type_.to_string(), "csi-IM-ResourceElementPattern"); - return c.get(); - } - pattern1_s_& pattern1() - { - assert_choice_type("pattern1", type_.to_string(), "csi-IM-ResourceElementPattern"); - return c.get(); - } - const pattern0_s_& pattern0() const - { - assert_choice_type("pattern0", type_.to_string(), "csi-IM-ResourceElementPattern"); - return c.get(); - } - const pattern1_s_& pattern1() const - { - assert_choice_type("pattern1", type_.to_string(), "csi-IM-ResourceElementPattern"); - return c.get(); - } - pattern0_s_& set_pattern0() - { - set(types::pattern0); - return c.get(); - } - pattern1_s_& set_pattern1() - { - set(types::pattern1); - return c.get(); - } + std::string to_string() const; + int8_t to_number() const; + }; + typedef enumerated types; - private: - types type_; - choice_buffer_t c; + // choice methods + plmn_id_eutra_minus5_gc_c() = default; + plmn_id_eutra_minus5_gc_c(const plmn_id_eutra_minus5_gc_c& other); + plmn_id_eutra_minus5_gc_c& operator=(const plmn_id_eutra_minus5_gc_c& other); + ~plmn_id_eutra_minus5_gc_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + plmn_id_s& plmn_id_eutra_minus5_gc() + { + assert_choice_type("plmn-Identity-EUTRA-5GC", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); + return c.get(); + } + uint8_t& plmn_idx() + { + assert_choice_type("plmn-index", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); + return c.get(); + } + const plmn_id_s& plmn_id_eutra_minus5_gc() const + { + assert_choice_type("plmn-Identity-EUTRA-5GC", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); + return c.get(); + } + const uint8_t& plmn_idx() const + { + assert_choice_type("plmn-index", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); + return c.get(); + } + plmn_id_s& set_plmn_id_eutra_minus5_gc() + { + set(types::plmn_id_eutra_minus5_gc); + return c.get(); + } + uint8_t& set_plmn_idx() + { + set(types::plmn_idx); + return c.get(); + } - void destroy_(); +private: + types type_; + choice_buffer_t c; + + void destroy_(); +}; + +// CellIdentity-EUTRA-5GC ::= CHOICE +struct cell_id_eutra_minus5_gc_c { + struct types_opts { + enum options { cell_id_eutra, cell_id_idx, nulltype } value; + + std::string to_string() const; }; + typedef enumerated types; - // member variables - bool ext = false; - bool csi_im_res_elem_pattern_present = false; - bool freq_band_present = false; - bool periodicity_and_offset_present = false; - uint8_t csi_im_res_id = 0; - csi_im_res_elem_pattern_c_ csi_im_res_elem_pattern; - csi_freq_occupation_s freq_band; - csi_res_periodicity_and_offset_c periodicity_and_offset; - // ... + // choice methods + cell_id_eutra_minus5_gc_c() = default; + cell_id_eutra_minus5_gc_c(const cell_id_eutra_minus5_gc_c& other); + cell_id_eutra_minus5_gc_c& operator=(const cell_id_eutra_minus5_gc_c& other); + ~cell_id_eutra_minus5_gc_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<28>& cell_id_eutra() + { + assert_choice_type("cellIdentity-EUTRA", type_.to_string(), "CellIdentity-EUTRA-5GC"); + return c.get >(); + } + uint8_t& cell_id_idx() + { + assert_choice_type("cellId-index", type_.to_string(), "CellIdentity-EUTRA-5GC"); + return c.get(); + } + const fixed_bitstring<28>& cell_id_eutra() const + { + assert_choice_type("cellIdentity-EUTRA", type_.to_string(), "CellIdentity-EUTRA-5GC"); + return c.get >(); + } + const uint8_t& cell_id_idx() const + { + assert_choice_type("cellId-index", type_.to_string(), "CellIdentity-EUTRA-5GC"); + return c.get(); + } + fixed_bitstring<28>& set_cell_id_eutra() + { + set(types::cell_id_eutra); + return c.get >(); + } + uint8_t& set_cell_id_idx() + { + set(types::cell_id_idx); + return c.get(); + } + +private: + types type_; + choice_buffer_t > c; + + void destroy_(); +}; + +// MultiFrequencyBandListNR ::= SEQUENCE (SIZE (1..8)) OF INTEGER (1..1024) +using multi_freq_band_list_nr_l = bounded_array; + +// PLMN-IdentityList-EUTRA-5GC ::= SEQUENCE (SIZE (1..12)) OF PLMN-Identity-EUTRA-5GC +using plmn_id_list_eutra_minus5_gc_l = dyn_array; + +// PLMN-IdentityList-EUTRA-EPC ::= SEQUENCE (SIZE (1..12)) OF PLMN-Identity +using plmn_id_list_eutra_epc_l = dyn_array; + +// ResultsPerCSI-RS-Index ::= SEQUENCE +struct results_per_csi_rs_idx_s { + bool csi_rs_results_present = false; + uint8_t csi_rs_idx = 0; + meas_quant_results_s csi_rs_results; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -10012,14 +9098,33 @@ struct csi_im_res_s { void to_json(json_writer& j) const; }; -// CSI-IM-ResourceSet ::= SEQUENCE -struct csi_im_res_set_s { - using csi_im_res_l_ = bounded_array; +// ResultsPerSSB-Index ::= SEQUENCE +struct results_per_ssb_idx_s { + bool ssb_results_present = false; + uint8_t ssb_idx = 0; + meas_quant_results_s ssb_results; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CGI-InfoNR ::= SEQUENCE +struct cgi_info_nr_s { + struct no_sib1_s_ { + uint8_t ssb_subcarrier_offset = 0; + pdcch_cfg_sib1_s pdcch_cfg_sib1; + }; // member variables - bool ext = false; - uint8_t csi_im_res_set_id = 0; - csi_im_res_l_ csi_im_res; + bool ext = false; + bool plmn_id_info_list_present = false; + bool freq_band_list_present = false; + bool no_sib1_present = false; + plmn_id_info_list_l plmn_id_info_list; + multi_freq_band_list_nr_l freq_band_list; + no_sib1_s_ no_sib1; // ... // sequence methods @@ -10028,645 +9133,157 @@ struct csi_im_res_set_s { void to_json(json_writer& j) const; }; -// CSI-ReportConfig ::= SEQUENCE -struct csi_report_cfg_s { - struct report_cfg_type_c_ { - struct periodic_s_ { - using pucch_csi_res_list_l_ = dyn_array; +// CellAccessRelatedInfo-EUTRA-5GC ::= SEQUENCE +struct cell_access_related_info_eutra_minus5_gc_s { + bool ranac_minus5gc_present = false; + plmn_id_list_eutra_minus5_gc_l plmn_id_list_eutra_minus5gc; + fixed_bitstring<24> tac_eutra_minus5gc; + uint16_t ranac_minus5gc = 0; + cell_id_eutra_minus5_gc_c cell_id_eutra_minus5gc; - // member variables - csi_report_periodicity_and_offset_c report_slot_cfg; - pucch_csi_res_list_l_ pucch_csi_res_list; - }; - struct semi_persistent_on_pucch_s_ { - using pucch_csi_res_list_l_ = dyn_array; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - csi_report_periodicity_and_offset_c report_slot_cfg; - pucch_csi_res_list_l_ pucch_csi_res_list; - }; - struct semi_persistent_on_pusch_s_ { - struct report_slot_cfg_opts { - enum options { sl5, sl10, sl20, sl40, sl80, sl160, sl320, nulltype } value; - typedef uint16_t number_type; +// CellAccessRelatedInfo-EUTRA-EPC ::= SEQUENCE +struct cell_access_related_info_eutra_epc_s { + plmn_id_list_eutra_epc_l plmn_id_list_eutra_epc; + fixed_bitstring<16> tac_eutra_epc; + fixed_bitstring<28> cell_id_eutra_epc; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated report_slot_cfg_e_; - using report_slot_offset_list_l_ = bounded_array; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - report_slot_cfg_e_ report_slot_cfg; - report_slot_offset_list_l_ report_slot_offset_list; - uint8_t p0alpha = 0; - }; - struct aperiodic_s_ { - using report_slot_offset_list_l_ = bounded_array; +// MultiBandInfoListEUTRA ::= SEQUENCE (SIZE (1..8)) OF INTEGER (1..256) +using multi_band_info_list_eutra_l = bounded_array; - // member variables - report_slot_offset_list_l_ report_slot_offset_list; - }; - struct types_opts { - enum options { periodic, semi_persistent_on_pucch, semi_persistent_on_pusch, aperiodic, nulltype } value; +// ResultsPerCSI-RS-IndexList ::= SEQUENCE (SIZE (1..64)) OF ResultsPerCSI-RS-Index +using results_per_csi_rs_idx_list_l = dyn_array; - std::string to_string() const; - }; - typedef enumerated types; +// ResultsPerSSB-IndexList ::= SEQUENCE (SIZE (1..64)) OF ResultsPerSSB-Index +using results_per_ssb_idx_list_l = dyn_array; - // choice methods - report_cfg_type_c_() = default; - report_cfg_type_c_(const report_cfg_type_c_& other); - report_cfg_type_c_& operator=(const report_cfg_type_c_& other); - ~report_cfg_type_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - periodic_s_& periodic() - { - assert_choice_type("periodic", type_.to_string(), "reportConfigType"); - return c.get(); - } - semi_persistent_on_pucch_s_& semi_persistent_on_pucch() - { - assert_choice_type("semiPersistentOnPUCCH", type_.to_string(), "reportConfigType"); - return c.get(); - } - semi_persistent_on_pusch_s_& semi_persistent_on_pusch() - { - assert_choice_type("semiPersistentOnPUSCH", type_.to_string(), "reportConfigType"); - return c.get(); - } - aperiodic_s_& aperiodic() - { - assert_choice_type("aperiodic", type_.to_string(), "reportConfigType"); - return c.get(); - } - const periodic_s_& periodic() const - { - assert_choice_type("periodic", type_.to_string(), "reportConfigType"); - return c.get(); - } - const semi_persistent_on_pucch_s_& semi_persistent_on_pucch() const - { - assert_choice_type("semiPersistentOnPUCCH", type_.to_string(), "reportConfigType"); - return c.get(); - } - const semi_persistent_on_pusch_s_& semi_persistent_on_pusch() const - { - assert_choice_type("semiPersistentOnPUSCH", type_.to_string(), "reportConfigType"); - return c.get(); - } - const aperiodic_s_& aperiodic() const - { - assert_choice_type("aperiodic", type_.to_string(), "reportConfigType"); - return c.get(); - } - periodic_s_& set_periodic() - { - set(types::periodic); - return c.get(); - } - semi_persistent_on_pucch_s_& set_semi_persistent_on_pucch() - { - set(types::semi_persistent_on_pucch); - return c.get(); - } - semi_persistent_on_pusch_s_& set_semi_persistent_on_pusch() - { - set(types::semi_persistent_on_pusch); - return c.get(); - } - aperiodic_s_& set_aperiodic() - { - set(types::aperiodic); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; +// CGI-InfoEUTRA ::= SEQUENCE +struct cgi_info_eutra_s { + struct cgi_info_epc_s_ { + using cgi_info_epc_list_l_ = dyn_array; - void destroy_(); + // member variables + bool cgi_info_epc_list_present = false; + cell_access_related_info_eutra_epc_s cgi_info_epc_legacy; + cgi_info_epc_list_l_ cgi_info_epc_list; }; - struct report_quant_c_ { - struct cri_ri_i1_cqi_s_ { - struct pdsch_bundle_size_for_csi_opts { - enum options { n2, n4, nulltype } value; - typedef uint8_t number_type; + using cgi_info_minus5_gc_l_ = dyn_array; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated pdsch_bundle_size_for_csi_e_; + // member variables + bool cgi_info_epc_present = false; + bool cgi_info_minus5_gc_present = false; + bool multi_band_info_list_present = false; + bool freq_band_ind_prio_present = false; + cgi_info_epc_s_ cgi_info_epc; + cgi_info_minus5_gc_l_ cgi_info_minus5_gc; + uint16_t freq_band_ind = 1; + multi_band_info_list_eutra_l multi_band_info_list; - // member variables - bool pdsch_bundle_size_for_csi_present = false; - pdsch_bundle_size_for_csi_e_ pdsch_bundle_size_for_csi; - }; - struct types_opts { - enum options { - none, - cri_ri_pmi_cqi, - cri_ri_i1, - cri_ri_i1_cqi, - cri_ri_cqi, - cri_rsrp, - ssb_idx_rsrp, - cri_ri_li_pmi_cqi, - nulltype - } value; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - }; - typedef enumerated types; +// MeasQuantityResultsEUTRA ::= SEQUENCE +struct meas_quant_results_eutra_s { + bool rsrp_present = false; + bool rsrq_present = false; + bool sinr_present = false; + uint8_t rsrp = 0; + uint8_t rsrq = 0; + uint8_t sinr = 0; - // choice methods - report_quant_c_() = default; - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - cri_ri_i1_cqi_s_& cri_ri_i1_cqi() - { - assert_choice_type("cri-RI-i1-CQI", type_.to_string(), "reportQuantity"); - return c; - } - const cri_ri_i1_cqi_s_& cri_ri_i1_cqi() const - { - assert_choice_type("cri-RI-i1-CQI", type_.to_string(), "reportQuantity"); - return c; - } - cri_ri_i1_cqi_s_& set_cri_ri_i1_cqi() - { - set(types::cri_ri_i1_cqi); - return c; - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - cri_ri_i1_cqi_s_ c; +// MeasResultNR ::= SEQUENCE +struct meas_result_nr_s { + struct meas_result_s_ { + struct cell_results_s_ { + bool results_ssb_cell_present = false; + bool results_csi_rs_cell_present = false; + meas_quant_results_s results_ssb_cell; + meas_quant_results_s results_csi_rs_cell; + }; + struct rs_idx_results_s_ { + bool results_ssb_idxes_present = false; + bool results_csi_rs_idxes_present = false; + results_per_ssb_idx_list_l results_ssb_idxes; + results_per_csi_rs_idx_list_l results_csi_rs_idxes; + }; + + // member variables + bool rs_idx_results_present = false; + cell_results_s_ cell_results; + rs_idx_results_s_ rs_idx_results; }; - struct report_freq_cfg_s_ { - struct cqi_format_ind_opts { - enum options { wideband_cqi, subband_cqi, nulltype } value; - std::string to_string() const; - }; - typedef enumerated cqi_format_ind_e_; - struct pmi_format_ind_opts { - enum options { wideband_pmi, subband_pmi, nulltype } value; + // member variables + bool ext = false; + bool pci_present = false; + uint16_t pci = 0; + meas_result_s_ meas_result; + // ... + // group 0 + copy_ptr cgi_info; - std::string to_string() const; - }; - typedef enumerated pmi_format_ind_e_; - struct csi_report_band_c_ { - struct types_opts { - enum options { - subbands3, - subbands4, - subbands5, - subbands6, - subbands7, - subbands8, - subbands9, - subbands10, - subbands11, - subbands12, - subbands13, - subbands14, - subbands15, - subbands16, - subbands17, - subbands18, - // ... - subbands19_v1530, - nulltype - } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; +// MeasResultEUTRA ::= SEQUENCE +struct meas_result_eutra_s { + bool ext = false; + bool cgi_info_present = false; + uint16_t eutra_pci = 0; + meas_quant_results_eutra_s meas_result; + cgi_info_eutra_s cgi_info; + // ... - // choice methods - csi_report_band_c_() = default; - csi_report_band_c_(const csi_report_band_c_& other); - csi_report_band_c_& operator=(const csi_report_band_c_& other); - ~csi_report_band_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<3>& subbands3() - { - assert_choice_type("subbands3", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<4>& subbands4() - { - assert_choice_type("subbands4", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<5>& subbands5() - { - assert_choice_type("subbands5", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<6>& subbands6() - { - assert_choice_type("subbands6", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<7>& subbands7() - { - assert_choice_type("subbands7", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<8>& subbands8() - { - assert_choice_type("subbands8", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<9>& subbands9() - { - assert_choice_type("subbands9", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<10>& subbands10() - { - assert_choice_type("subbands10", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<11>& subbands11() - { - assert_choice_type("subbands11", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<12>& subbands12() - { - assert_choice_type("subbands12", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<13>& subbands13() - { - assert_choice_type("subbands13", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<14>& subbands14() - { - assert_choice_type("subbands14", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<15>& subbands15() - { - assert_choice_type("subbands15", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<16>& subbands16() - { - assert_choice_type("subbands16", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<17>& subbands17() - { - assert_choice_type("subbands17", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<18>& subbands18() - { - assert_choice_type("subbands18", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<19>& subbands19_v1530() - { - assert_choice_type("subbands19-v1530", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<3>& subbands3() const - { - assert_choice_type("subbands3", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<4>& subbands4() const - { - assert_choice_type("subbands4", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<5>& subbands5() const - { - assert_choice_type("subbands5", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<6>& subbands6() const - { - assert_choice_type("subbands6", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<7>& subbands7() const - { - assert_choice_type("subbands7", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<8>& subbands8() const - { - assert_choice_type("subbands8", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<9>& subbands9() const - { - assert_choice_type("subbands9", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<10>& subbands10() const - { - assert_choice_type("subbands10", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<11>& subbands11() const - { - assert_choice_type("subbands11", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<12>& subbands12() const - { - assert_choice_type("subbands12", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<13>& subbands13() const - { - assert_choice_type("subbands13", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<14>& subbands14() const - { - assert_choice_type("subbands14", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<15>& subbands15() const - { - assert_choice_type("subbands15", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<16>& subbands16() const - { - assert_choice_type("subbands16", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<17>& subbands17() const - { - assert_choice_type("subbands17", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<18>& subbands18() const - { - assert_choice_type("subbands18", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - const fixed_bitstring<19>& subbands19_v1530() const - { - assert_choice_type("subbands19-v1530", type_.to_string(), "csi-ReportingBand"); - return c.get >(); - } - fixed_bitstring<3>& set_subbands3() - { - set(types::subbands3); - return c.get >(); - } - fixed_bitstring<4>& set_subbands4() - { - set(types::subbands4); - return c.get >(); - } - fixed_bitstring<5>& set_subbands5() - { - set(types::subbands5); - return c.get >(); - } - fixed_bitstring<6>& set_subbands6() - { - set(types::subbands6); - return c.get >(); - } - fixed_bitstring<7>& set_subbands7() - { - set(types::subbands7); - return c.get >(); - } - fixed_bitstring<8>& set_subbands8() - { - set(types::subbands8); - return c.get >(); - } - fixed_bitstring<9>& set_subbands9() - { - set(types::subbands9); - return c.get >(); - } - fixed_bitstring<10>& set_subbands10() - { - set(types::subbands10); - return c.get >(); - } - fixed_bitstring<11>& set_subbands11() - { - set(types::subbands11); - return c.get >(); - } - fixed_bitstring<12>& set_subbands12() - { - set(types::subbands12); - return c.get >(); - } - fixed_bitstring<13>& set_subbands13() - { - set(types::subbands13); - return c.get >(); - } - fixed_bitstring<14>& set_subbands14() - { - set(types::subbands14); - return c.get >(); - } - fixed_bitstring<15>& set_subbands15() - { - set(types::subbands15); - return c.get >(); - } - fixed_bitstring<16>& set_subbands16() - { - set(types::subbands16); - return c.get >(); - } - fixed_bitstring<17>& set_subbands17() - { - set(types::subbands17); - return c.get >(); - } - fixed_bitstring<18>& set_subbands18() - { - set(types::subbands18); - return c.get >(); - } - fixed_bitstring<19>& set_subbands19_v1530() - { - set(types::subbands19_v1530); - return c.get >(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - choice_buffer_t > c; +// MeasResultListNR ::= SEQUENCE (SIZE (1..8)) OF MeasResultNR +using meas_result_list_nr_l = dyn_array; - void destroy_(); - }; +// UplinkTxDirectCurrentBWP ::= SEQUENCE +struct ul_tx_direct_current_bwp_s { + uint8_t bwp_id = 0; + bool shift7dot5k_hz = false; + uint16_t tx_direct_current_location = 0; - // member variables - bool cqi_format_ind_present = false; - bool pmi_format_ind_present = false; - bool csi_report_band_present = false; - cqi_format_ind_e_ cqi_format_ind; - pmi_format_ind_e_ pmi_format_ind; - csi_report_band_c_ csi_report_band; - }; - struct time_restrict_for_ch_meass_opts { - enum options { cfgured, not_cfgured, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated time_restrict_for_ch_meass_e_; - struct time_restrict_for_interference_meass_opts { - enum options { cfgured, not_cfgured, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated time_restrict_for_interference_meass_e_; - struct dummy_opts { - enum options { n1, n2, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated dummy_e_; - struct group_based_beam_report_c_ { - struct disabled_s_ { - struct nrof_reported_rs_opts { - enum options { n1, n2, n3, n4, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated nrof_reported_rs_e_; - - // member variables - bool nrof_reported_rs_present = false; - nrof_reported_rs_e_ nrof_reported_rs; - }; - struct types_opts { - enum options { enabled, disabled, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - group_based_beam_report_c_() = default; - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - disabled_s_& disabled() - { - assert_choice_type("disabled", type_.to_string(), "groupBasedBeamReporting"); - return c; - } - const disabled_s_& disabled() const - { - assert_choice_type("disabled", type_.to_string(), "groupBasedBeamReporting"); - return c; - } - disabled_s_& set_disabled() - { - set(types::disabled); - return c; - } - - private: - types type_; - disabled_s_ c; - }; - struct cqi_table_opts { - enum options { table1, table2, table3, spare1, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated cqi_table_e_; - struct subband_size_opts { - enum options { value1, value2, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated subband_size_e_; - using non_pmi_port_ind_l_ = dyn_array; - struct semi_persistent_on_pusch_v1530_s_ { - struct report_slot_cfg_v1530_opts { - enum options { sl4, sl8, sl16, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated report_slot_cfg_v1530_e_; - - // member variables - report_slot_cfg_v1530_e_ report_slot_cfg_v1530; - }; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool ext = false; - bool carrier_present = false; - bool csi_im_res_for_interference_present = false; - bool nzp_csi_rs_res_for_interference_present = false; - bool report_freq_cfg_present = false; - bool codebook_cfg_present = false; - bool dummy_present = false; - bool cqi_table_present = false; - bool non_pmi_port_ind_present = false; - uint8_t report_cfg_id = 0; - uint8_t carrier = 0; - uint8_t res_for_ch_meas = 0; - uint8_t csi_im_res_for_interference = 0; - uint8_t nzp_csi_rs_res_for_interference = 0; - report_cfg_type_c_ report_cfg_type; - report_quant_c_ report_quant; - report_freq_cfg_s_ report_freq_cfg; - time_restrict_for_ch_meass_e_ time_restrict_for_ch_meass; - time_restrict_for_interference_meass_e_ time_restrict_for_interference_meass; - codebook_cfg_s codebook_cfg; - dummy_e_ dummy; - group_based_beam_report_c_ group_based_beam_report; - cqi_table_e_ cqi_table; - subband_size_e_ subband_size; - non_pmi_port_ind_l_ non_pmi_port_ind; +// EUTRA-RSTD-Info ::= SEQUENCE +struct eutra_rstd_info_s { + bool ext = false; + uint32_t carrier_freq = 0; + uint8_t meas_prs_offset = 0; // ... - // group 0 - copy_ptr semi_persistent_on_pusch_v1530; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -10674,88 +9291,34 @@ struct csi_report_cfg_s { void to_json(json_writer& j) const; }; -// CSI-ResourceConfig ::= SEQUENCE -struct csi_res_cfg_s { - struct csi_rs_res_set_list_c_ { - struct nzp_csi_rs_ssb_s_ { - using nzp_csi_rs_res_set_list_l_ = bounded_array; - using csi_ssb_res_set_list_l_ = std::array; - - // member variables - bool nzp_csi_rs_res_set_list_present = false; - bool csi_ssb_res_set_list_present = false; - nzp_csi_rs_res_set_list_l_ nzp_csi_rs_res_set_list; - csi_ssb_res_set_list_l_ csi_ssb_res_set_list; - }; - using csi_im_res_set_list_l_ = bounded_array; - struct types_opts { - enum options { nzp_csi_rs_ssb, csi_im_res_set_list, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - csi_rs_res_set_list_c_() = default; - csi_rs_res_set_list_c_(const csi_rs_res_set_list_c_& other); - csi_rs_res_set_list_c_& operator=(const csi_rs_res_set_list_c_& other); - ~csi_rs_res_set_list_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - nzp_csi_rs_ssb_s_& nzp_csi_rs_ssb() - { - assert_choice_type("nzp-CSI-RS-SSB", type_.to_string(), "csi-RS-ResourceSetList"); - return c.get(); - } - csi_im_res_set_list_l_& csi_im_res_set_list() - { - assert_choice_type("csi-IM-ResourceSetList", type_.to_string(), "csi-RS-ResourceSetList"); - return c.get(); - } - const nzp_csi_rs_ssb_s_& nzp_csi_rs_ssb() const - { - assert_choice_type("nzp-CSI-RS-SSB", type_.to_string(), "csi-RS-ResourceSetList"); - return c.get(); - } - const csi_im_res_set_list_l_& csi_im_res_set_list() const - { - assert_choice_type("csi-IM-ResourceSetList", type_.to_string(), "csi-RS-ResourceSetList"); - return c.get(); - } - nzp_csi_rs_ssb_s_& set_nzp_csi_rs_ssb() - { - set(types::nzp_csi_rs_ssb); - return c.get(); - } - csi_im_res_set_list_l_& set_csi_im_res_set_list() - { - set(types::csi_im_res_set_list); - return c.get(); - } +// MIMO-LayersDL ::= ENUMERATED +struct mimo_layers_dl_opts { + enum options { two_layers, four_layers, eight_layers, nulltype } value; + typedef uint8_t number_type; - private: - types type_; - choice_buffer_t c; + std::string to_string() const; + uint8_t to_number() const; +}; +typedef enumerated mimo_layers_dl_e; - void destroy_(); - }; - struct res_type_opts { - enum options { aperiodic, semi_persistent, periodic, nulltype } value; +// MIMO-LayersUL ::= ENUMERATED +struct mimo_layers_ul_opts { + enum options { one_layer, two_layers, four_layers, nulltype } value; + typedef uint8_t number_type; - std::string to_string() const; - }; - typedef enumerated res_type_e_; + std::string to_string() const; + uint8_t to_number() const; +}; +typedef enumerated mimo_layers_ul_e; - // member variables - bool ext = false; - uint8_t csi_res_cfg_id = 0; - csi_rs_res_set_list_c_ csi_rs_res_set_list; - uint8_t bwp_id = 0; - res_type_e_ res_type; +// MeasResult2EUTRA ::= SEQUENCE +struct meas_result2_eutra_s { + bool ext = false; + bool meas_result_serving_cell_present = false; + bool meas_result_best_neigh_cell_present = false; + uint32_t carrier_freq = 0; + meas_result_eutra_s meas_result_serving_cell; + meas_result_eutra_s meas_result_best_neigh_cell; // ... // sequence methods @@ -10764,14 +9327,17 @@ struct csi_res_cfg_s { void to_json(json_writer& j) const; }; -// CSI-SSB-ResourceSet ::= SEQUENCE -struct csi_ssb_res_set_s { - using csi_ssb_res_list_l_ = dyn_array; - - // member variables - bool ext = false; - uint8_t csi_ssb_res_set_id = 0; - csi_ssb_res_list_l_ csi_ssb_res_list; +// MeasResult2NR ::= SEQUENCE +struct meas_result2_nr_s { + bool ext = false; + bool ssb_freq_present = false; + bool ref_freq_csi_rs_present = false; + bool meas_result_serving_cell_present = false; + bool meas_result_neigh_cell_list_nr_present = false; + uint32_t ssb_freq = 0; + uint32_t ref_freq_csi_rs = 0; + meas_result_nr_s meas_result_serving_cell; + meas_result_list_nr_l meas_result_neigh_cell_list_nr; // ... // sequence methods @@ -10780,16 +9346,27 @@ struct csi_ssb_res_set_s { void to_json(json_writer& j) const; }; -// CSI-SemiPersistentOnPUSCH-TriggerStateList ::= SEQUENCE (SIZE (1..64)) OF CSI-SemiPersistentOnPUSCH-TriggerState -using csi_semi_persistent_on_pusch_trigger_state_list_l = dyn_array; - -// DownlinkConfigCommon ::= SEQUENCE -struct dl_cfg_common_s { - bool ext = false; - bool freq_info_dl_present = false; - bool init_dl_bwp_present = false; - freq_info_dl_s freq_info_dl; - bwp_dl_common_s init_dl_bwp; +// MeasResultCellSFTD-NR ::= SEQUENCE +struct meas_result_cell_sftd_nr_s { + bool rsrp_result_present = false; + uint16_t pci = 0; + uint16_t sfn_offset_result = 0; + int16_t frame_boundary_offset_result = -30720; + uint8_t rsrp_result = 0; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MeasResultServMO ::= SEQUENCE +struct meas_result_serv_mo_s { + bool ext = false; + bool meas_result_best_neigh_cell_present = false; + uint8_t serv_cell_id = 0; + meas_result_nr_s meas_result_serving_cell; + meas_result_nr_s meas_result_best_neigh_cell; // ... // sequence methods @@ -10798,30 +9375,42 @@ struct dl_cfg_common_s { void to_json(json_writer& j) const; }; -// NZP-CSI-RS-Resource ::= SEQUENCE -struct nzp_csi_rs_res_s { - struct pwr_ctrl_offset_ss_opts { - enum options { db_minus3, db0, db3, db6, nulltype } value; - typedef int8_t number_type; +// ReducedAggregatedBandwidth ::= ENUMERATED +struct reduced_aggregated_bw_opts { + enum options { + mhz0, + mhz10, + mhz20, + mhz30, + mhz40, + mhz50, + mhz60, + mhz80, + mhz100, + mhz200, + mhz300, + mhz400, + nulltype + } value; + typedef uint16_t number_type; - std::string to_string() const; - int8_t to_number() const; - }; - typedef enumerated pwr_ctrl_offset_ss_e_; + std::string to_string() const; + uint16_t to_number() const; +}; +typedef enumerated reduced_aggregated_bw_e; + +// UplinkTxDirectCurrentCell ::= SEQUENCE +struct ul_tx_direct_current_cell_s { + using ul_direct_current_bwp_l_ = dyn_array; + using ul_direct_current_bwp_sul_l_ = dyn_array; // member variables - bool ext = false; - bool pwr_ctrl_offset_ss_present = false; - bool periodicity_and_offset_present = false; - bool qcl_info_periodic_csi_rs_present = false; - uint8_t nzp_csi_rs_res_id = 0; - csi_rs_res_map_s res_map; - int8_t pwr_ctrl_offset = -8; - pwr_ctrl_offset_ss_e_ pwr_ctrl_offset_ss; - uint16_t scrambling_id = 0; - csi_res_periodicity_and_offset_c periodicity_and_offset; - uint8_t qcl_info_periodic_csi_rs = 0; + bool ext = false; + uint8_t serv_cell_idx = 0; + ul_direct_current_bwp_l_ ul_direct_current_bwp; // ... + // group 0 + copy_ptr ul_direct_current_bwp_sul; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -10829,26 +9418,40 @@ struct nzp_csi_rs_res_s { void to_json(json_writer& j) const; }; -// NZP-CSI-RS-ResourceSet ::= SEQUENCE -struct nzp_csi_rs_res_set_s { - using nzp_csi_rs_res_l_ = dyn_array; - struct repeat_opts { - enum options { on, off, nulltype } value; +// DRB-CountInfo ::= SEQUENCE +struct drb_count_info_s { + uint8_t drb_id = 1; + uint64_t count_ul = 0; + uint64_t count_dl = 0; - std::string to_string() const; - }; - typedef enumerated repeat_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool ext = false; - bool repeat_present = false; - bool aperiodic_trigger_offset_present = false; - bool trs_info_present = false; - uint8_t nzp_csi_res_set_id = 0; - nzp_csi_rs_res_l_ nzp_csi_rs_res; - repeat_e_ repeat; - uint8_t aperiodic_trigger_offset = 0; - // ... +// EUTRA-RSTD-InfoList ::= SEQUENCE (SIZE (1..3)) OF EUTRA-RSTD-Info +using eutra_rstd_info_list_l = dyn_array; + +// MeasResultCellListSFTD-NR ::= SEQUENCE (SIZE (1..3)) OF MeasResultCellSFTD-NR +using meas_result_cell_list_sftd_nr_l = dyn_array; + +// MeasResultFreqList ::= SEQUENCE (SIZE (1..8)) OF MeasResult2NR +using meas_result_freq_list_l = dyn_array; + +// MeasResultFreqListFailMRDC ::= SEQUENCE (SIZE (1..8)) OF MeasResult2EUTRA +using meas_result_freq_list_fail_mrdc_l = dyn_array; + +// MeasResultListEUTRA ::= SEQUENCE (SIZE (1..8)) OF MeasResultEUTRA +using meas_result_list_eutra_l = dyn_array; + +// MeasResultSFTD-EUTRA ::= SEQUENCE +struct meas_result_sftd_eutra_s { + bool rsrp_result_present = false; + uint16_t eutra_pci = 0; + uint16_t sfn_offset_result = 0; + int16_t frame_boundary_offset_result = -30720; + uint8_t rsrp_result = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -10856,22 +9459,49 @@ struct nzp_csi_rs_res_set_s { void to_json(json_writer& j) const; }; -// PDSCH-CodeBlockGroupTransmission ::= SEQUENCE -struct pdsch_code_block_group_tx_s { - struct max_code_block_groups_per_transport_block_opts { - enum options { n2, n4, n6, n8, nulltype } value; - typedef uint8_t number_type; +// MeasResultServFreqListEUTRA-SCG ::= SEQUENCE (SIZE (1..32)) OF MeasResult2EUTRA +using meas_result_serv_freq_list_eutra_scg_l = dyn_array; - std::string to_string() const; - uint8_t to_number() const; +// MeasResultServFreqListNR-SCG ::= SEQUENCE (SIZE (1..32)) OF MeasResult2NR +using meas_result_serv_freq_list_nr_scg_l = dyn_array; + +// MeasResultServMOList ::= SEQUENCE (SIZE (1..32)) OF MeasResultServMO +using meas_result_serv_mo_list_l = dyn_array; + +// OverheatingAssistance ::= SEQUENCE +struct overheat_assist_s { + struct reduced_max_ccs_s_ { + uint8_t reduced_ccs_dl = 0; + uint8_t reduced_ccs_ul = 0; + }; + struct reduced_max_bw_fr1_s_ { + reduced_aggregated_bw_e reduced_bw_fr1_dl; + reduced_aggregated_bw_e reduced_bw_fr1_ul; + }; + struct reduced_max_bw_fr2_s_ { + reduced_aggregated_bw_e reduced_bw_fr2_dl; + reduced_aggregated_bw_e reduced_bw_fr2_ul; + }; + struct reduced_max_mimo_layers_fr1_s_ { + mimo_layers_dl_e reduced_mimo_layers_fr1_dl; + mimo_layers_ul_e reduced_mimo_layers_fr1_ul; + }; + struct reduced_max_mimo_layers_fr2_s_ { + mimo_layers_dl_e reduced_mimo_layers_fr2_dl; + mimo_layers_ul_e reduced_mimo_layers_fr2_ul; }; - typedef enumerated max_code_block_groups_per_transport_block_e_; // member variables - bool ext = false; - max_code_block_groups_per_transport_block_e_ max_code_block_groups_per_transport_block; - bool code_block_group_flush_ind = false; - // ... + bool reduced_max_ccs_present = false; + bool reduced_max_bw_fr1_present = false; + bool reduced_max_bw_fr2_present = false; + bool reduced_max_mimo_layers_fr1_present = false; + bool reduced_max_mimo_layers_fr2_present = false; + reduced_max_ccs_s_ reduced_max_ccs; + reduced_max_bw_fr1_s_ reduced_max_bw_fr1; + reduced_max_bw_fr2_s_ reduced_max_bw_fr2; + reduced_max_mimo_layers_fr1_s_ reduced_max_mimo_layers_fr1; + reduced_max_mimo_layers_fr2_s_ reduced_max_mimo_layers_fr2; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -10879,30 +9509,69 @@ struct pdsch_code_block_group_tx_s { void to_json(json_writer& j) const; }; -// PUSCH-ServingCellConfig ::= SEQUENCE -struct pusch_serving_cell_cfg_s { - struct xoverhead_opts { - enum options { xoh6, xoh12, xoh18, nulltype } value; - typedef uint8_t number_type; +// RRCReconfigurationComplete-v1560-IEs ::= SEQUENCE +struct rrc_recfg_complete_v1560_ies_s { + struct scg_resp_c_ { + struct types_opts { + enum options { nr_scg_resp, eutra_scg_resp, nulltype } value; - std::string to_string() const; - uint8_t to_number() const; + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + scg_resp_c_() = default; + scg_resp_c_(const scg_resp_c_& other); + scg_resp_c_& operator=(const scg_resp_c_& other); + ~scg_resp_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + dyn_octstring& nr_scg_resp() + { + assert_choice_type("nr-SCG-Response", type_.to_string(), "scg-Response"); + return c.get(); + } + dyn_octstring& eutra_scg_resp() + { + assert_choice_type("eutra-SCG-Response", type_.to_string(), "scg-Response"); + return c.get(); + } + const dyn_octstring& nr_scg_resp() const + { + assert_choice_type("nr-SCG-Response", type_.to_string(), "scg-Response"); + return c.get(); + } + const dyn_octstring& eutra_scg_resp() const + { + assert_choice_type("eutra-SCG-Response", type_.to_string(), "scg-Response"); + return c.get(); + } + dyn_octstring& set_nr_scg_resp() + { + set(types::nr_scg_resp); + return c.get(); + } + dyn_octstring& set_eutra_scg_resp() + { + set(types::eutra_scg_resp); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); }; - typedef enumerated xoverhead_e_; // member variables - bool ext = false; - bool code_block_group_tx_present = false; - bool rate_matching_present = false; - bool xoverhead_present = false; - setup_release_c code_block_group_tx; - xoverhead_e_ xoverhead; - // ... - // group 0 - bool max_mimo_layers_present = false; - bool processing_type2_enabled_present = false; - uint8_t max_mimo_layers = 1; - bool processing_type2_enabled = false; + bool scg_resp_present = false; + bool non_crit_ext_present = false; + scg_resp_c_ scg_resp; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -10910,158 +9579,87 @@ struct pusch_serving_cell_cfg_s { void to_json(json_writer& j) const; }; -// PollByte ::= ENUMERATED -struct poll_byte_opts { - enum options { - kb1, - kb2, - kb5, - kb8, - kb10, - kb15, - kb25, - kb50, - kb75, - kb100, - kb125, - kb250, - kb375, - kb500, - kb750, - kb1000, - kb1250, - kb1500, - kb2000, - kb3000, - kb4000, - kb4500, - kb5000, - kb5500, - kb6000, - kb6500, - kb7000, - kb7500, - mb8, - mb9, - mb10, - mb11, - mb12, - mb13, - mb14, - mb15, - mb16, - mb17, - mb18, - mb20, - mb25, - mb30, - mb40, - infinity, - spare20, - spare19, - spare18, - spare17, - spare16, - spare15, - spare14, - spare13, - spare12, - spare11, - spare10, - spare9, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; +// UE-CapabilityRAT-Container ::= SEQUENCE +struct ue_cap_rat_container_s { + rat_type_e rat_type; + dyn_octstring ue_cap_rat_container; - std::string to_string() const; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated poll_byte_e; -// PollPDU ::= ENUMERATED -struct poll_pdu_opts { - enum options { - p4, - p8, - p16, - p32, - p64, - p128, - p256, - p512, - p1024, - p2048, - p4096, - p6144, - p8192, - p12288, - p16384, - p20480, - p24576, - p28672, - p32768, - p40960, - p49152, - p57344, - p65536, - infinity, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef int32_t number_type; +// UplinkTxDirectCurrentList ::= SEQUENCE (SIZE (1..32)) OF UplinkTxDirectCurrentCell +using ul_tx_direct_current_list_l = dyn_array; - std::string to_string() const; - int32_t to_number() const; -}; -typedef enumerated poll_pdu_e; +// DRB-CountInfoList ::= SEQUENCE (SIZE (0..29)) OF DRB-CountInfo +using drb_count_info_list_l = dyn_array; -// RateMatchPatternLTE-CRS ::= SEQUENCE -struct rate_match_pattern_lte_crs_s { - struct carrier_bw_dl_opts { - enum options { n6, n15, n25, n50, n75, n100, spare2, spare1, nulltype } value; - typedef uint8_t number_type; +// DelayBudgetReport ::= CHOICE +struct delay_budget_report_c { + struct type1_opts { + enum options { + ms_minus1280, + ms_minus640, + ms_minus320, + ms_minus160, + ms_minus80, + ms_minus60, + ms_minus40, + ms_minus20, + ms0, + ms20, + ms40, + ms60, + ms80, + ms160, + ms320, + ms640, + ms1280, + nulltype + } value; + typedef int16_t number_type; std::string to_string() const; - uint8_t to_number() const; + int16_t to_number() const; }; - typedef enumerated carrier_bw_dl_e_; - struct nrof_crs_ports_opts { - enum options { n1, n2, n4, nulltype } value; + typedef enumerated type1_e_; + struct types_opts { + enum options { type1, /*...*/ nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated nrof_crs_ports_e_; - struct v_shift_opts { - enum options { n0, n1, n2, n3, n4, n5, nulltype } value; - typedef uint8_t number_type; + typedef enumerated types; + + // choice methods + types type() const { return types::type1; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + type1_e_& type1() { return c; } + const type1_e_& type1() const { return c; } + +private: + type1_e_ c; +}; + +// FailureInfoRLC-Bearer ::= SEQUENCE +struct fail_info_rlc_bearer_s { + struct fail_type_opts { + enum options { rlc_fail, spare3, spare2, spare1, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; - typedef enumerated v_shift_e_; + typedef enumerated fail_type_e_; // member variables - bool mbsfn_sf_cfg_list_present = false; - uint16_t carrier_freq_dl = 0; - carrier_bw_dl_e_ carrier_bw_dl; - eutra_mbsfn_sf_cfg_list_l mbsfn_sf_cfg_list; - nrof_crs_ports_e_ nrof_crs_ports; - v_shift_e_ v_shift; + uint8_t cell_group_id = 0; + uint8_t lc_ch_id = 1; + fail_type_e_ fail_type; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11069,103 +9667,189 @@ struct rate_match_pattern_lte_crs_s { void to_json(json_writer& j) const; }; -// SN-FieldLengthAM ::= ENUMERATED -struct sn_field_len_am_opts { - enum options { size12, size18, nulltype } value; - typedef uint8_t number_type; +// FailureReportSCG ::= SEQUENCE +struct fail_report_scg_s { + struct fail_type_opts { + enum options { + t310_expiry, + random_access_problem, + rlc_max_num_retx, + synch_recfg_fail_scg, + scg_recfg_fail, + srb3_integrity_fail, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; - std::string to_string() const; - uint8_t to_number() const; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated fail_type_e_; + + // member variables + bool ext = false; + bool meas_result_freq_list_present = false; + bool meas_result_scg_fail_present = false; + fail_type_e_ fail_type; + meas_result_freq_list_l meas_result_freq_list; + dyn_octstring meas_result_scg_fail; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated sn_field_len_am_e; -// SN-FieldLengthUM ::= ENUMERATED -struct sn_field_len_um_opts { - enum options { size6, size12, nulltype } value; - typedef uint8_t number_type; +// FailureReportSCG-EUTRA ::= SEQUENCE +struct fail_report_scg_eutra_s { + struct fail_type_opts { + enum options { + t313_expiry, + random_access_problem, + rlc_max_num_retx, + scg_change_fail, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; - std::string to_string() const; - uint8_t to_number() const; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated fail_type_e_; + + // member variables + bool ext = false; + bool meas_result_freq_list_mrdc_present = false; + bool meas_result_scg_fail_mrdc_present = false; + fail_type_e_ fail_type; + meas_result_freq_list_fail_mrdc_l meas_result_freq_list_mrdc; + dyn_octstring meas_result_scg_fail_mrdc; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated sn_field_len_um_e; -// SRS-CarrierSwitching ::= SEQUENCE -struct srs_carrier_switching_s { - struct srs_switch_from_carrier_opts { - enum options { sul, nul, nulltype } value; +// LocationMeasurementInfo ::= CHOICE +struct location_meas_info_c { + struct types_opts { + enum options { eutra_rstd, /*...*/ eutra_fine_timing_detection, nulltype } value; std::string to_string() const; }; - typedef enumerated srs_switch_from_carrier_e_; - struct srs_tpc_pdcch_group_c_ { - using type_a_l_ = dyn_array; + typedef enumerated types; + + // choice methods + location_meas_info_c() = default; + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + eutra_rstd_info_list_l& eutra_rstd() + { + assert_choice_type("eutra-RSTD", type_.to_string(), "LocationMeasurementInfo"); + return c; + } + const eutra_rstd_info_list_l& eutra_rstd() const + { + assert_choice_type("eutra-RSTD", type_.to_string(), "LocationMeasurementInfo"); + return c; + } + eutra_rstd_info_list_l& set_eutra_rstd() + { + set(types::eutra_rstd); + return c; + } + +private: + types type_; + eutra_rstd_info_list_l c; +}; + +// MeasResults ::= SEQUENCE +struct meas_results_s { + struct meas_result_neigh_cells_c_ { struct types_opts { - enum options { type_a, type_b, nulltype } value; + enum options { meas_result_list_nr, /*...*/ meas_result_list_eutra, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - srs_tpc_pdcch_group_c_() = default; - srs_tpc_pdcch_group_c_(const srs_tpc_pdcch_group_c_& other); - srs_tpc_pdcch_group_c_& operator=(const srs_tpc_pdcch_group_c_& other); - ~srs_tpc_pdcch_group_c_() { destroy_(); } + meas_result_neigh_cells_c_() = default; + meas_result_neigh_cells_c_(const meas_result_neigh_cells_c_& other); + meas_result_neigh_cells_c_& operator=(const meas_result_neigh_cells_c_& other); + ~meas_result_neigh_cells_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - type_a_l_& type_a() + meas_result_list_nr_l& meas_result_list_nr() { - assert_choice_type("typeA", type_.to_string(), "srs-TPC-PDCCH-Group"); - return c.get(); + assert_choice_type("measResultListNR", type_.to_string(), "measResultNeighCells"); + return c.get(); } - srs_tpc_pdcch_cfg_s& type_b() + meas_result_list_eutra_l& meas_result_list_eutra() { - assert_choice_type("typeB", type_.to_string(), "srs-TPC-PDCCH-Group"); - return c.get(); + assert_choice_type("measResultListEUTRA", type_.to_string(), "measResultNeighCells"); + return c.get(); } - const type_a_l_& type_a() const + const meas_result_list_nr_l& meas_result_list_nr() const { - assert_choice_type("typeA", type_.to_string(), "srs-TPC-PDCCH-Group"); - return c.get(); + assert_choice_type("measResultListNR", type_.to_string(), "measResultNeighCells"); + return c.get(); } - const srs_tpc_pdcch_cfg_s& type_b() const + const meas_result_list_eutra_l& meas_result_list_eutra() const { - assert_choice_type("typeB", type_.to_string(), "srs-TPC-PDCCH-Group"); - return c.get(); + assert_choice_type("measResultListEUTRA", type_.to_string(), "measResultNeighCells"); + return c.get(); } - type_a_l_& set_type_a() + meas_result_list_nr_l& set_meas_result_list_nr() { - set(types::type_a); - return c.get(); + set(types::meas_result_list_nr); + return c.get(); } - srs_tpc_pdcch_cfg_s& set_type_b() + meas_result_list_eutra_l& set_meas_result_list_eutra() { - set(types::type_b); - return c.get(); + set(types::meas_result_list_eutra); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - using monitoring_cells_l_ = bounded_array; // member variables - bool ext = false; - bool srs_switch_from_serv_cell_idx_present = false; - bool srs_tpc_pdcch_group_present = false; - bool monitoring_cells_present = false; - uint8_t srs_switch_from_serv_cell_idx = 0; - srs_switch_from_carrier_e_ srs_switch_from_carrier; - srs_tpc_pdcch_group_c_ srs_tpc_pdcch_group; - monitoring_cells_l_ monitoring_cells; + bool ext = false; + bool meas_result_neigh_cells_present = false; + uint8_t meas_id = 1; + meas_result_serv_mo_list_l meas_result_serving_mo_list; + meas_result_neigh_cells_c_ meas_result_neigh_cells; // ... + // group 0 + copy_ptr meas_result_serv_freq_list_eutra_scg; + copy_ptr meas_result_serv_freq_list_nr_scg; + copy_ptr meas_result_sftd_eutra; + copy_ptr meas_result_sftd_nr; + // group 1 + copy_ptr meas_result_cell_list_sftd_nr; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11173,20 +9857,12 @@ struct srs_carrier_switching_s { void to_json(json_writer& j) const; }; -// SlotFormatIndicator ::= SEQUENCE -struct slot_format_ind_s { - using slot_format_comb_to_add_mod_list_l_ = dyn_array; - using slot_format_comb_to_release_list_l_ = bounded_array; - - // member variables - bool ext = false; - bool slot_format_comb_to_add_mod_list_present = false; - bool slot_format_comb_to_release_list_present = false; - uint32_t sfi_rnti = 0; - uint8_t dci_payload_size = 1; - slot_format_comb_to_add_mod_list_l_ slot_format_comb_to_add_mod_list; - slot_format_comb_to_release_list_l_ slot_format_comb_to_release_list; - // ... +// RRCReconfigurationComplete-v1530-IEs ::= SEQUENCE +struct rrc_recfg_complete_v1530_ies_s { + bool ul_tx_direct_current_list_present = false; + bool non_crit_ext_present = false; + ul_tx_direct_current_list_l ul_tx_direct_current_list; + rrc_recfg_complete_v1560_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11194,250 +9870,108 @@ struct slot_format_ind_s { void to_json(json_writer& j) const; }; -// T-PollRetransmit ::= ENUMERATED -struct t_poll_retx_opts { - enum options { - ms5, - ms10, - ms15, - ms20, - ms25, - ms30, - ms35, - ms40, - ms45, - ms50, - ms55, - ms60, - ms65, - ms70, - ms75, - ms80, - ms85, - ms90, - ms95, - ms100, - ms105, - ms110, - ms115, - ms120, - ms125, - ms130, - ms135, - ms140, - ms145, - ms150, - ms155, - ms160, - ms165, - ms170, - ms175, - ms180, - ms185, - ms190, - ms195, - ms200, - ms205, - ms210, - ms215, - ms220, - ms225, - ms230, - ms235, - ms240, - ms245, - ms250, - ms300, - ms350, - ms400, - ms450, - ms500, - ms800, - ms1000, - ms2000, - ms4000, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; +// RegisteredAMF ::= SEQUENCE +struct registered_amf_s { + bool plmn_id_present = false; + plmn_id_s plmn_id; + fixed_bitstring<24> amf_id; - std::string to_string() const; - uint16_t to_number() const; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated t_poll_retx_e; -// T-Reassembly ::= ENUMERATED -struct t_reassembly_opts { - enum options { - ms0, - ms5, - ms10, - ms15, - ms20, - ms25, - ms30, - ms35, - ms40, - ms45, - ms50, - ms55, - ms60, - ms65, - ms70, - ms75, - ms80, - ms85, - ms90, - ms95, - ms100, - ms110, - ms120, - ms130, - ms140, - ms150, - ms160, - ms170, - ms180, - ms190, - ms200, - spare1, - nulltype - } value; - typedef uint8_t number_type; +// S-NSSAI ::= CHOICE +struct s_nssai_c { + struct types_opts { + enum options { sst, sst_sd, nulltype } value; - std::string to_string() const; - uint8_t to_number() const; -}; -typedef enumerated t_reassembly_e; + std::string to_string() const; + }; + typedef enumerated types; -// T-StatusProhibit ::= ENUMERATED -struct t_status_prohibit_opts { - enum options { - ms0, - ms5, - ms10, - ms15, - ms20, - ms25, - ms30, - ms35, - ms40, - ms45, - ms50, - ms55, - ms60, - ms65, - ms70, - ms75, - ms80, - ms85, - ms90, - ms95, - ms100, - ms105, - ms110, - ms115, - ms120, - ms125, - ms130, - ms135, - ms140, - ms145, - ms150, - ms155, - ms160, - ms165, - ms170, - ms175, - ms180, - ms185, - ms190, - ms195, - ms200, - ms205, - ms210, - ms215, - ms220, - ms225, - ms230, - ms235, - ms240, - ms245, - ms250, - ms300, - ms350, - ms400, - ms450, - ms500, - ms800, - ms1000, - ms1200, - ms1600, - ms2000, - ms2400, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; + // choice methods + s_nssai_c() = default; + s_nssai_c(const s_nssai_c& other); + s_nssai_c& operator=(const s_nssai_c& other); + ~s_nssai_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<8>& sst() + { + assert_choice_type("sst", type_.to_string(), "S-NSSAI"); + return c.get >(); + } + fixed_bitstring<32>& sst_sd() + { + assert_choice_type("sst-SD", type_.to_string(), "S-NSSAI"); + return c.get >(); + } + const fixed_bitstring<8>& sst() const + { + assert_choice_type("sst", type_.to_string(), "S-NSSAI"); + return c.get >(); + } + const fixed_bitstring<32>& sst_sd() const + { + assert_choice_type("sst-SD", type_.to_string(), "S-NSSAI"); + return c.get >(); + } + fixed_bitstring<8>& set_sst() + { + set(types::sst); + return c.get >(); + } + fixed_bitstring<32>& set_sst_sd() + { + set(types::sst_sd); + return c.get >(); + } - std::string to_string() const; - uint16_t to_number() const; +private: + types type_; + choice_buffer_t > c; + + void destroy_(); }; -typedef enumerated t_status_prohibit_e; -// TDD-UL-DL-SlotConfig ::= SEQUENCE -struct tdd_ul_dl_slot_cfg_s { - struct symbols_c_ { - struct explicit_s_ { - bool nrof_dl_symbols_present = false; - bool nrof_ul_symbols_present = false; - uint8_t nrof_dl_symbols = 1; - uint8_t nrof_ul_symbols = 1; - }; - struct types_opts { - enum options { all_dl, all_ul, explicit_type, nulltype } value; +// SCGFailureInformation-v1590-IEs ::= SEQUENCE +struct scg_fail_info_v1590_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring late_non_crit_ext; - std::string to_string() const; - }; - typedef enumerated types; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // choice methods - symbols_c_() = default; - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - explicit_s_& explicit_type() - { - assert_choice_type("explicit", type_.to_string(), "symbols"); - return c; - } - const explicit_s_& explicit_type() const - { - assert_choice_type("explicit", type_.to_string(), "symbols"); - return c; - } - explicit_s_& set_explicit_type() - { - set(types::explicit_type); - return c; - } +// SCGFailureInformationEUTRA-v1590-IEs ::= SEQUENCE +struct scg_fail_info_eutra_v1590_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring late_non_crit_ext; - private: - types type_; - explicit_s_ c; - }; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - uint16_t slot_idx = 0; - symbols_c_ symbols; +// UE-CapabilityRAT-ContainerList ::= SEQUENCE (SIZE (0..8)) OF UE-CapabilityRAT-Container +using ue_cap_rat_container_list_l = dyn_array; + +// UEAssistanceInformation-v1540-IEs ::= SEQUENCE +struct ueassist_info_v1540_ies_s { + bool overheat_assist_present = false; + bool non_crit_ext_present = false; + overheat_assist_s overheat_assist; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11445,57 +9979,26 @@ struct tdd_ul_dl_slot_cfg_s { void to_json(json_writer& j) const; }; -// UL-DataSplitThreshold ::= ENUMERATED -struct ul_data_split_thres_opts { - enum options { - b0, - b100, - b200, - b400, - b800, - b1600, - b3200, - b6400, - b12800, - b25600, - b51200, - b102400, - b204800, - b409600, - b819200, - b1228800, - b1638400, - b2457600, - b3276800, - b4096000, - b4915200, - b5734400, - b6553600, - infinity, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef int32_t number_type; +// CounterCheckResponse-IEs ::= SEQUENCE +struct counter_check_resp_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + drb_count_info_list_l drb_count_info_list; + dyn_octstring late_non_crit_ext; - std::string to_string() const; - int32_t to_number() const; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated ul_data_split_thres_e; -// UplinkConfigCommon ::= SEQUENCE -struct ul_cfg_common_s { - bool freq_info_ul_present = false; - bool init_ul_bwp_present = false; - freq_info_ul_s freq_info_ul; - bwp_ul_common_s init_ul_bwp; - time_align_timer_e dummy; +// FailureInformation-IEs ::= SEQUENCE +struct fail_info_ies_s { + bool fail_info_rlc_bearer_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + fail_info_rlc_bearer_s fail_info_rlc_bearer; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11503,15 +10006,12 @@ struct ul_cfg_common_s { void to_json(json_writer& j) const; }; -// BWP-Downlink ::= SEQUENCE -struct bwp_dl_s { - bool ext = false; - bool bwp_common_present = false; - bool bwp_ded_present = false; - uint8_t bwp_id = 0; - bwp_dl_common_s bwp_common; - bwp_dl_ded_s bwp_ded; - // ... +// LocationMeasurementIndication-IEs ::= SEQUENCE +struct location_meas_ind_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + setup_release_c meas_ind; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11519,61 +10019,12 @@ struct bwp_dl_s { void to_json(json_writer& j) const; }; -// CSI-MeasConfig ::= SEQUENCE -struct csi_meas_cfg_s { - using nzp_csi_rs_res_to_add_mod_list_l_ = dyn_array; - using nzp_csi_rs_res_to_release_list_l_ = dyn_array; - using nzp_csi_rs_res_set_to_add_mod_list_l_ = dyn_array; - using nzp_csi_rs_res_set_to_release_list_l_ = dyn_array; - using csi_im_res_to_add_mod_list_l_ = dyn_array; - using csi_im_res_to_release_list_l_ = bounded_array; - using csi_im_res_set_to_add_mod_list_l_ = dyn_array; - using csi_im_res_set_to_release_list_l_ = dyn_array; - using csi_ssb_res_set_to_add_mod_list_l_ = dyn_array; - using csi_ssb_res_set_to_add_release_list_l_ = dyn_array; - using csi_res_cfg_to_add_mod_list_l_ = dyn_array; - using csi_res_cfg_to_release_list_l_ = dyn_array; - using csi_report_cfg_to_add_mod_list_l_ = dyn_array; - using csi_report_cfg_to_release_list_l_ = dyn_array; - - // member variables - bool ext = false; - bool nzp_csi_rs_res_to_add_mod_list_present = false; - bool nzp_csi_rs_res_to_release_list_present = false; - bool nzp_csi_rs_res_set_to_add_mod_list_present = false; - bool nzp_csi_rs_res_set_to_release_list_present = false; - bool csi_im_res_to_add_mod_list_present = false; - bool csi_im_res_to_release_list_present = false; - bool csi_im_res_set_to_add_mod_list_present = false; - bool csi_im_res_set_to_release_list_present = false; - bool csi_ssb_res_set_to_add_mod_list_present = false; - bool csi_ssb_res_set_to_add_release_list_present = false; - bool csi_res_cfg_to_add_mod_list_present = false; - bool csi_res_cfg_to_release_list_present = false; - bool csi_report_cfg_to_add_mod_list_present = false; - bool csi_report_cfg_to_release_list_present = false; - bool report_trigger_size_present = false; - bool aperiodic_trigger_state_list_present = false; - bool semi_persistent_on_pusch_trigger_state_list_present = false; - nzp_csi_rs_res_to_add_mod_list_l_ nzp_csi_rs_res_to_add_mod_list; - nzp_csi_rs_res_to_release_list_l_ nzp_csi_rs_res_to_release_list; - nzp_csi_rs_res_set_to_add_mod_list_l_ nzp_csi_rs_res_set_to_add_mod_list; - nzp_csi_rs_res_set_to_release_list_l_ nzp_csi_rs_res_set_to_release_list; - csi_im_res_to_add_mod_list_l_ csi_im_res_to_add_mod_list; - csi_im_res_to_release_list_l_ csi_im_res_to_release_list; - csi_im_res_set_to_add_mod_list_l_ csi_im_res_set_to_add_mod_list; - csi_im_res_set_to_release_list_l_ csi_im_res_set_to_release_list; - csi_ssb_res_set_to_add_mod_list_l_ csi_ssb_res_set_to_add_mod_list; - csi_ssb_res_set_to_add_release_list_l_ csi_ssb_res_set_to_add_release_list; - csi_res_cfg_to_add_mod_list_l_ csi_res_cfg_to_add_mod_list; - csi_res_cfg_to_release_list_l_ csi_res_cfg_to_release_list; - csi_report_cfg_to_add_mod_list_l_ csi_report_cfg_to_add_mod_list; - csi_report_cfg_to_release_list_l_ csi_report_cfg_to_release_list; - uint8_t report_trigger_size = 0; - setup_release_c > aperiodic_trigger_state_list; - setup_release_c > - semi_persistent_on_pusch_trigger_state_list; - // ... +// MeasurementReport-IEs ::= SEQUENCE +struct meas_report_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + meas_results_s meas_results; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11581,86 +10032,129 @@ struct csi_meas_cfg_s { void to_json(json_writer& j) const; }; -// CipheringAlgorithm ::= ENUMERATED -struct ciphering_algorithm_opts { - enum options { nea0, nea1, nea2, nea3, spare4, spare3, spare2, spare1, /*...*/ nulltype } value; - typedef uint8_t number_type; +// RRCReconfigurationComplete-IEs ::= SEQUENCE +struct rrc_recfg_complete_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring late_non_crit_ext; + rrc_recfg_complete_v1530_ies_s non_crit_ext; - std::string to_string() const; - uint8_t to_number() const; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated ciphering_algorithm_e; -// CrossCarrierSchedulingConfig ::= SEQUENCE -struct cross_carrier_sched_cfg_s { - struct sched_cell_info_c_ { - struct own_s_ { - bool cif_presence = false; - }; - struct other_s_ { - uint8_t sched_cell_id = 0; - uint8_t cif_in_sched_cell = 1; - }; +// RRCReestablishmentComplete-IEs ::= SEQUENCE +struct rrc_reest_complete_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring late_non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RRCResumeComplete-IEs ::= SEQUENCE +struct rrc_resume_complete_ies_s { + bool ded_nas_msg_present = false; + bool sel_plmn_id_present = false; + bool ul_tx_direct_current_list_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring ded_nas_msg; + uint8_t sel_plmn_id = 1; + ul_tx_direct_current_list_l ul_tx_direct_current_list; + dyn_octstring late_non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RRCSetupComplete-IEs ::= SEQUENCE +struct rrc_setup_complete_ies_s { + struct guami_type_opts { + enum options { native, mapped, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated guami_type_e_; + using s_nssai_list_l_ = dyn_array; + struct ng_minus5_g_s_tmsi_value_c_ { struct types_opts { - enum options { own, other, nulltype } value; + enum options { ng_minus5_g_s_tmsi, ng_minus5_g_s_tmsi_part2, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - sched_cell_info_c_() = default; - sched_cell_info_c_(const sched_cell_info_c_& other); - sched_cell_info_c_& operator=(const sched_cell_info_c_& other); - ~sched_cell_info_c_() { destroy_(); } + ng_minus5_g_s_tmsi_value_c_() = default; + ng_minus5_g_s_tmsi_value_c_(const ng_minus5_g_s_tmsi_value_c_& other); + ng_minus5_g_s_tmsi_value_c_& operator=(const ng_minus5_g_s_tmsi_value_c_& other); + ~ng_minus5_g_s_tmsi_value_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - own_s_& own() + fixed_bitstring<48>& ng_minus5_g_s_tmsi() { - assert_choice_type("own", type_.to_string(), "schedulingCellInfo"); - return c.get(); + assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "ng-5G-S-TMSI-Value"); + return c.get >(); } - other_s_& other() + fixed_bitstring<9>& ng_minus5_g_s_tmsi_part2() { - assert_choice_type("other", type_.to_string(), "schedulingCellInfo"); - return c.get(); + assert_choice_type("ng-5G-S-TMSI-Part2", type_.to_string(), "ng-5G-S-TMSI-Value"); + return c.get >(); } - const own_s_& own() const + const fixed_bitstring<48>& ng_minus5_g_s_tmsi() const { - assert_choice_type("own", type_.to_string(), "schedulingCellInfo"); - return c.get(); + assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "ng-5G-S-TMSI-Value"); + return c.get >(); } - const other_s_& other() const + const fixed_bitstring<9>& ng_minus5_g_s_tmsi_part2() const { - assert_choice_type("other", type_.to_string(), "schedulingCellInfo"); - return c.get(); + assert_choice_type("ng-5G-S-TMSI-Part2", type_.to_string(), "ng-5G-S-TMSI-Value"); + return c.get >(); } - own_s_& set_own() + fixed_bitstring<48>& set_ng_minus5_g_s_tmsi() { - set(types::own); - return c.get(); + set(types::ng_minus5_g_s_tmsi); + return c.get >(); } - other_s_& set_other() + fixed_bitstring<9>& set_ng_minus5_g_s_tmsi_part2() { - set(types::other); - return c.get(); + set(types::ng_minus5_g_s_tmsi_part2); + return c.get >(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t > c; void destroy_(); }; // member variables - bool ext = false; - sched_cell_info_c_ sched_cell_info; - // ... + bool registered_amf_present = false; + bool guami_type_present = false; + bool s_nssai_list_present = false; + bool ng_minus5_g_s_tmsi_value_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + uint8_t sel_plmn_id = 1; + registered_amf_s registered_amf; + guami_type_e_ guami_type; + s_nssai_list_l_ s_nssai_list; + dyn_octstring ded_nas_msg; + ng_minus5_g_s_tmsi_value_c_ ng_minus5_g_s_tmsi_value; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11668,12 +10162,12 @@ struct cross_carrier_sched_cfg_s { void to_json(json_writer& j) const; }; -// DL-AM-RLC ::= SEQUENCE -struct dl_am_rlc_s { - bool sn_field_len_present = false; - sn_field_len_am_e sn_field_len; - t_reassembly_e t_reassembly; - t_status_prohibit_e t_status_prohibit; +// SCGFailureInformation-IEs ::= SEQUENCE +struct scg_fail_info_ies_s { + bool fail_report_scg_present = false; + bool non_crit_ext_present = false; + fail_report_scg_s fail_report_scg; + scg_fail_info_v1590_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11681,11 +10175,12 @@ struct dl_am_rlc_s { void to_json(json_writer& j) const; }; -// DL-UM-RLC ::= SEQUENCE -struct dl_um_rlc_s { - bool sn_field_len_present = false; - sn_field_len_um_e sn_field_len; - t_reassembly_e t_reassembly; +// SCGFailureInformationEUTRA-IEs ::= SEQUENCE +struct scg_fail_info_eutra_ies_s { + bool fail_report_scg_eutra_present = false; + bool non_crit_ext_present = false; + fail_report_scg_eutra_s fail_report_scg_eutra; + scg_fail_info_eutra_v1590_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11693,22 +10188,23 @@ struct dl_um_rlc_s { void to_json(json_writer& j) const; }; -// IntegrityProtAlgorithm ::= ENUMERATED -struct integrity_prot_algorithm_opts { - enum options { nia0, nia1, nia2, nia3, spare4, spare3, spare2, spare1, /*...*/ nulltype } value; - typedef uint8_t number_type; +// SecurityModeComplete-IEs ::= SEQUENCE +struct security_mode_complete_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring late_non_crit_ext; - std::string to_string() const; - uint8_t to_number() const; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated integrity_prot_algorithm_e; -// PDCCH-ServingCellConfig ::= SEQUENCE -struct pdcch_serving_cell_cfg_s { - bool ext = false; - bool slot_format_ind_present = false; - setup_release_c slot_format_ind; - // ... +// SecurityModeFailure-IEs ::= SEQUENCE +struct security_mode_fail_ies_s { + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11716,251 +10212,58 @@ struct pdcch_serving_cell_cfg_s { void to_json(json_writer& j) const; }; -// PDCP-Config ::= SEQUENCE -struct pdcp_cfg_s { - struct drb_s_ { - struct discard_timer_opts { - enum options { - ms10, - ms20, - ms30, - ms40, - ms50, - ms60, - ms75, - ms100, - ms150, - ms200, - ms250, - ms300, - ms500, - ms750, - ms1500, - infinity, - nulltype - } value; - typedef int16_t number_type; - - std::string to_string() const; - int16_t to_number() const; - }; - typedef enumerated discard_timer_e_; - struct pdcp_sn_size_ul_opts { - enum options { len12bits, len18bits, nulltype } value; - typedef uint8_t number_type; +// UEAssistanceInformation-IEs ::= SEQUENCE +struct ueassist_info_ies_s { + bool delay_budget_report_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + delay_budget_report_c delay_budget_report; + dyn_octstring late_non_crit_ext; + ueassist_info_v1540_ies_s non_crit_ext; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated pdcp_sn_size_ul_e_; - struct pdcp_sn_size_dl_opts { - enum options { len12bits, len18bits, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated pdcp_sn_size_dl_e_; - struct hdr_compress_c_ { - struct rohc_s_ { - struct profiles_s_ { - bool profile0x0001 = false; - bool profile0x0002 = false; - bool profile0x0003 = false; - bool profile0x0004 = false; - bool profile0x0006 = false; - bool profile0x0101 = false; - bool profile0x0102 = false; - bool profile0x0103 = false; - bool profile0x0104 = false; - }; +// UECapabilityInformation-IEs ::= SEQUENCE +struct ue_cap_info_ies_s { + bool ue_cap_rat_container_list_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + ue_cap_rat_container_list_l ue_cap_rat_container_list; + dyn_octstring late_non_crit_ext; - // member variables - bool max_cid_present = false; - bool drb_continue_rohc_present = false; - uint16_t max_cid = 1; - profiles_s_ profiles; - }; - struct ul_only_rohc_s_ { - struct profiles_s_ { - bool profile0x0006 = false; - }; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool max_cid_present = false; - bool drb_continue_rohc_present = false; - uint16_t max_cid = 1; - profiles_s_ profiles; - }; - struct types_opts { - enum options { not_used, rohc, ul_only_rohc, /*...*/ nulltype } value; +// ULInformationTransfer-IEs ::= SEQUENCE +struct ul_info_transfer_ies_s { + bool ded_nas_msg_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring ded_nas_msg; + dyn_octstring late_non_crit_ext; - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - hdr_compress_c_() = default; - hdr_compress_c_(const hdr_compress_c_& other); - hdr_compress_c_& operator=(const hdr_compress_c_& other); - ~hdr_compress_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rohc_s_& rohc() - { - assert_choice_type("rohc", type_.to_string(), "headerCompression"); - return c.get(); - } - ul_only_rohc_s_& ul_only_rohc() - { - assert_choice_type("uplinkOnlyROHC", type_.to_string(), "headerCompression"); - return c.get(); - } - const rohc_s_& rohc() const - { - assert_choice_type("rohc", type_.to_string(), "headerCompression"); - return c.get(); - } - const ul_only_rohc_s_& ul_only_rohc() const - { - assert_choice_type("uplinkOnlyROHC", type_.to_string(), "headerCompression"); - return c.get(); - } - rohc_s_& set_rohc() - { - set(types::rohc); - return c.get(); - } - ul_only_rohc_s_& set_ul_only_rohc() - { - set(types::ul_only_rohc); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - - // member variables - bool discard_timer_present = false; - bool pdcp_sn_size_ul_present = false; - bool pdcp_sn_size_dl_present = false; - bool integrity_protection_present = false; - bool status_report_required_present = false; - bool out_of_order_delivery_present = false; - discard_timer_e_ discard_timer; - pdcp_sn_size_ul_e_ pdcp_sn_size_ul; - pdcp_sn_size_dl_e_ pdcp_sn_size_dl; - hdr_compress_c_ hdr_compress; - }; - struct more_than_one_rlc_s_ { - struct primary_path_s_ { - bool cell_group_present = false; - bool lc_ch_present = false; - uint8_t cell_group = 0; - uint8_t lc_ch = 1; - }; - - // member variables - bool ul_data_split_thres_present = false; - bool pdcp_dupl_present = false; - primary_path_s_ primary_path; - ul_data_split_thres_e ul_data_split_thres; - bool pdcp_dupl = false; - }; - struct t_reordering_opts { - enum options { - ms0, - ms1, - ms2, - ms4, - ms5, - ms8, - ms10, - ms15, - ms20, - ms30, - ms40, - ms50, - ms60, - ms80, - ms100, - ms120, - ms140, - ms160, - ms180, - ms200, - ms220, - ms240, - ms260, - ms280, - ms300, - ms500, - ms750, - ms1000, - ms1250, - ms1500, - ms1750, - ms2000, - ms2250, - ms2500, - ms2750, - ms3000, - spare28, - spare27, - spare26, - spare25, - spare24, - spare23, - spare22, - spare21, - spare20, - spare19, - spare18, - spare17, - spare16, - spare15, - spare14, - spare13, - spare12, - spare11, - spare10, - spare09, - spare08, - spare07, - spare06, - spare05, - spare04, - spare03, - spare02, - spare01, - nulltype - } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated t_reordering_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool ext = false; - bool drb_present = false; - bool more_than_one_rlc_present = false; - bool t_reordering_present = false; - drb_s_ drb; - more_than_one_rlc_s_ more_than_one_rlc; - t_reordering_e_ t_reordering; - // ... - // group 0 - bool ciphering_disabled_present = false; +// ULInformationTransferMRDC-IEs ::= SEQUENCE +struct ul_info_transfer_mrdc_ies_s { + bool ul_dcch_msg_nr_present = false; + bool ul_dcch_msg_eutra_present = false; + bool late_non_crit_ext_present = false; + bool non_crit_ext_present = false; + dyn_octstring ul_dcch_msg_nr; + dyn_octstring ul_dcch_msg_eutra; + dyn_octstring late_non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -11968,41 +10271,53 @@ struct pdcp_cfg_s { void to_json(json_writer& j) const; }; -// PDSCH-ServingCellConfig ::= SEQUENCE -struct pdsch_serving_cell_cfg_s { - struct xoverhead_opts { - enum options { xoh6, xoh12, xoh18, nulltype } value; - typedef uint8_t number_type; +// CounterCheckResponse ::= SEQUENCE +struct counter_check_resp_s { + struct crit_exts_c_ { + struct types_opts { + enum options { counter_check_resp, crit_exts_future, nulltype } value; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated xoverhead_e_; - struct nrof_harq_processes_for_pdsch_opts { - enum options { n2, n4, n6, n10, n12, n16, nulltype } value; - typedef uint8_t number_type; + std::string to_string() const; + }; + typedef enumerated types; - std::string to_string() const; - uint8_t to_number() const; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + counter_check_resp_ies_s& counter_check_resp() + { + assert_choice_type("counterCheckResponse", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const counter_check_resp_ies_s& counter_check_resp() const + { + assert_choice_type("counterCheckResponse", type_.to_string(), "criticalExtensions"); + return c.get(); + } + counter_check_resp_ies_s& set_counter_check_resp() + { + set(types::counter_check_resp); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); }; - typedef enumerated nrof_harq_processes_for_pdsch_e_; // member variables - bool ext = false; - bool code_block_group_tx_present = false; - bool xoverhead_present = false; - bool nrof_harq_processes_for_pdsch_present = false; - bool pucch_cell_present = false; - setup_release_c code_block_group_tx; - xoverhead_e_ xoverhead; - nrof_harq_processes_for_pdsch_e_ nrof_harq_processes_for_pdsch; - uint8_t pucch_cell = 0; - // ... - // group 0 - bool max_mimo_layers_present = false; - bool processing_type2_enabled_present = false; - uint8_t max_mimo_layers = 1; - bool processing_type2_enabled = false; + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -12010,49 +10325,52 @@ struct pdsch_serving_cell_cfg_s { void to_json(json_writer& j) const; }; -// RACH-ConfigDedicated ::= SEQUENCE -struct rach_cfg_ded_s { - bool ext = false; - bool cfra_present = false; - bool ra_prioritization_present = false; - cfra_s cfra; - ra_prioritization_s ra_prioritization; - // ... +// FailureInformation ::= SEQUENCE +struct fail_info_s { + struct crit_exts_c_ { + struct types_opts { + enum options { fail_info, crit_exts_future, nulltype } value; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + }; + typedef enumerated types; -// SDAP-Config ::= SEQUENCE -struct sdap_cfg_s { - struct sdap_hdr_dl_opts { - enum options { present, absent, nulltype } value; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fail_info_ies_s& fail_info() + { + assert_choice_type("failureInformation", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const fail_info_ies_s& fail_info() const + { + assert_choice_type("failureInformation", type_.to_string(), "criticalExtensions"); + return c.get(); + } + fail_info_ies_s& set_fail_info() + { + set(types::fail_info); + return c.get(); + } - std::string to_string() const; - }; - typedef enumerated sdap_hdr_dl_e_; - struct sdap_hdr_ul_opts { - enum options { present, absent, nulltype } value; + private: + types type_; + choice_buffer_t c; - std::string to_string() const; + void destroy_(); }; - typedef enumerated sdap_hdr_ul_e_; - using mapped_qos_flows_to_add_l_ = dyn_array; - using mapped_qos_flows_to_release_l_ = dyn_array; // member variables - bool ext = false; - bool mapped_qos_flows_to_add_present = false; - bool mapped_qos_flows_to_release_present = false; - uint16_t pdu_session = 0; - sdap_hdr_dl_e_ sdap_hdr_dl; - sdap_hdr_ul_e_ sdap_hdr_ul; - bool default_drb = false; - mapped_qos_flows_to_add_l_ mapped_qos_flows_to_add; - mapped_qos_flows_to_release_l_ mapped_qos_flows_to_release; - // ... + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -12060,30 +10378,52 @@ struct sdap_cfg_s { void to_json(json_writer& j) const; }; -// SchedulingRequestToAddMod ::= SEQUENCE -struct sched_request_to_add_mod_s { - struct sr_prohibit_timer_opts { - enum options { ms1, ms2, ms4, ms8, ms16, ms32, ms64, ms128, nulltype } value; - typedef uint8_t number_type; +// LocationMeasurementIndication ::= SEQUENCE +struct location_meas_ind_s { + struct crit_exts_c_ { + struct types_opts { + enum options { location_meas_ind, crit_exts_future, nulltype } value; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated sr_prohibit_timer_e_; - struct sr_trans_max_opts { - enum options { n4, n8, n16, n32, n64, spare3, spare2, spare1, nulltype } value; - typedef uint8_t number_type; + std::string to_string() const; + }; + typedef enumerated types; - std::string to_string() const; - uint8_t to_number() const; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + location_meas_ind_ies_s& location_meas_ind() + { + assert_choice_type("locationMeasurementIndication", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const location_meas_ind_ies_s& location_meas_ind() const + { + assert_choice_type("locationMeasurementIndication", type_.to_string(), "criticalExtensions"); + return c.get(); + } + location_meas_ind_ies_s& set_location_meas_ind() + { + set(types::location_meas_ind); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); }; - typedef enumerated sr_trans_max_e_; // member variables - bool sr_prohibit_timer_present = false; - uint8_t sched_request_id = 0; - sr_prohibit_timer_e_ sr_prohibit_timer; - sr_trans_max_e_ sr_trans_max; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -12091,135 +10431,52 @@ struct sched_request_to_add_mod_s { void to_json(json_writer& j) const; }; -// ServingCellConfigCommon ::= SEQUENCE -struct serving_cell_cfg_common_s { - struct n_timing_advance_offset_opts { - enum options { n0, n25600, n39936, nulltype } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated n_timing_advance_offset_e_; - struct ssb_positions_in_burst_c_ { +// MeasurementReport ::= SEQUENCE +struct meas_report_s { + struct crit_exts_c_ { struct types_opts { - enum options { short_bitmap, medium_bitmap, long_bitmap, nulltype } value; + enum options { meas_report, crit_exts_future, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - ssb_positions_in_burst_c_() = default; - ssb_positions_in_burst_c_(const ssb_positions_in_burst_c_& other); - ssb_positions_in_burst_c_& operator=(const ssb_positions_in_burst_c_& other); - ~ssb_positions_in_burst_c_() { destroy_(); } + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - fixed_bitstring<4>& short_bitmap() - { - assert_choice_type("shortBitmap", type_.to_string(), "ssb-PositionsInBurst"); - return c.get >(); - } - fixed_bitstring<8>& medium_bitmap() - { - assert_choice_type("mediumBitmap", type_.to_string(), "ssb-PositionsInBurst"); - return c.get >(); - } - fixed_bitstring<64>& long_bitmap() - { - assert_choice_type("longBitmap", type_.to_string(), "ssb-PositionsInBurst"); - return c.get >(); - } - const fixed_bitstring<4>& short_bitmap() const - { - assert_choice_type("shortBitmap", type_.to_string(), "ssb-PositionsInBurst"); - return c.get >(); - } - const fixed_bitstring<8>& medium_bitmap() const - { - assert_choice_type("mediumBitmap", type_.to_string(), "ssb-PositionsInBurst"); - return c.get >(); - } - const fixed_bitstring<64>& long_bitmap() const - { - assert_choice_type("longBitmap", type_.to_string(), "ssb-PositionsInBurst"); - return c.get >(); - } - fixed_bitstring<4>& set_short_bitmap() + meas_report_ies_s& meas_report() { - set(types::short_bitmap); - return c.get >(); + assert_choice_type("measurementReport", type_.to_string(), "criticalExtensions"); + return c.get(); } - fixed_bitstring<8>& set_medium_bitmap() + const meas_report_ies_s& meas_report() const { - set(types::medium_bitmap); - return c.get >(); + assert_choice_type("measurementReport", type_.to_string(), "criticalExtensions"); + return c.get(); } - fixed_bitstring<64>& set_long_bitmap() + meas_report_ies_s& set_meas_report() { - set(types::long_bitmap); - return c.get >(); + set(types::meas_report); + return c.get(); } private: - types type_; - choice_buffer_t > c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct ssb_periodicity_serving_cell_opts { - enum options { ms5, ms10, ms20, ms40, ms80, ms160, spare2, spare1, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated ssb_periodicity_serving_cell_e_; - struct dmrs_type_a_position_opts { - enum options { pos2, pos3, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated dmrs_type_a_position_e_; - using rate_match_pattern_to_add_mod_list_l_ = dyn_array; - using rate_match_pattern_to_release_list_l_ = bounded_array; // member variables - bool ext = false; - bool pci_present = false; - bool dl_cfg_common_present = false; - bool ul_cfg_common_present = false; - bool supplementary_ul_cfg_present = false; - bool n_timing_advance_offset_present = false; - bool ssb_positions_in_burst_present = false; - bool ssb_periodicity_serving_cell_present = false; - bool lte_crs_to_match_around_present = false; - bool rate_match_pattern_to_add_mod_list_present = false; - bool rate_match_pattern_to_release_list_present = false; - bool ssb_subcarrier_spacing_present = false; - bool tdd_ul_dl_cfg_common_present = false; - uint16_t pci = 0; - dl_cfg_common_s dl_cfg_common; - ul_cfg_common_s ul_cfg_common; - ul_cfg_common_s supplementary_ul_cfg; - n_timing_advance_offset_e_ n_timing_advance_offset; - ssb_positions_in_burst_c_ ssb_positions_in_burst; - ssb_periodicity_serving_cell_e_ ssb_periodicity_serving_cell; - dmrs_type_a_position_e_ dmrs_type_a_position; - setup_release_c lte_crs_to_match_around; - rate_match_pattern_to_add_mod_list_l_ rate_match_pattern_to_add_mod_list; - rate_match_pattern_to_release_list_l_ rate_match_pattern_to_release_list; - subcarrier_spacing_e ssb_subcarrier_spacing; - tdd_ul_dl_cfg_common_s tdd_ul_dl_cfg_common; - int8_t ss_pbch_block_pwr = -60; - // ... + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -12227,176 +10484,53 @@ struct serving_cell_cfg_common_s { void to_json(json_writer& j) const; }; -// TAG ::= SEQUENCE -struct tag_s { - bool ext = false; - uint8_t tag_id = 0; - time_align_timer_e time_align_timer; - // ... +// RRCReconfigurationComplete ::= SEQUENCE +struct rrc_recfg_complete_s { + struct crit_exts_c_ { + struct types_opts { + enum options { rrc_recfg_complete, crit_exts_future, nulltype } value; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// TDD-UL-DL-ConfigDedicated ::= SEQUENCE -struct tdd_ul_dl_cfg_ded_s { - using slot_specific_cfgs_to_add_mod_list_l_ = dyn_array; - using slot_specific_cfgs_torelease_list_l_ = dyn_array; - - // member variables - bool ext = false; - bool slot_specific_cfgs_to_add_mod_list_present = false; - bool slot_specific_cfgs_torelease_list_present = false; - slot_specific_cfgs_to_add_mod_list_l_ slot_specific_cfgs_to_add_mod_list; - slot_specific_cfgs_torelease_list_l_ slot_specific_cfgs_torelease_list; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// UL-AM-RLC ::= SEQUENCE -struct ul_am_rlc_s { - struct max_retx_thres_opts { - enum options { t1, t2, t3, t4, t6, t8, t16, t32, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_retx_thres_e_; - - // member variables - bool sn_field_len_present = false; - sn_field_len_am_e sn_field_len; - t_poll_retx_e t_poll_retx; - poll_pdu_e poll_pdu; - poll_byte_e poll_byte; - max_retx_thres_e_ max_retx_thres; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// UL-UM-RLC ::= SEQUENCE -struct ul_um_rlc_s { - bool sn_field_len_present = false; - sn_field_len_um_e sn_field_len; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// UplinkConfig ::= SEQUENCE -struct ul_cfg_s { - using ul_bwp_to_release_list_l_ = bounded_array; - using ul_bwp_to_add_mod_list_l_ = dyn_array; - using ul_ch_bw_per_scs_list_l_ = dyn_array; - - // member variables - bool ext = false; - bool init_ul_bwp_present = false; - bool ul_bwp_to_release_list_present = false; - bool ul_bwp_to_add_mod_list_present = false; - bool first_active_ul_bwp_id_present = false; - bool pusch_serving_cell_cfg_present = false; - bool carrier_switching_present = false; - bwp_ul_ded_s init_ul_bwp; - ul_bwp_to_release_list_l_ ul_bwp_to_release_list; - ul_bwp_to_add_mod_list_l_ ul_bwp_to_add_mod_list; - uint8_t first_active_ul_bwp_id = 0; - setup_release_c pusch_serving_cell_cfg; - setup_release_c carrier_switching; - // ... - // group 0 - bool pwr_boost_pi2_bpsk_present = false; - bool pwr_boost_pi2_bpsk = false; - copy_ptr ul_ch_bw_per_scs_list; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BSR-Config ::= SEQUENCE -struct bsr_cfg_s { - struct periodic_bsr_timer_opts { - enum options { - sf1, - sf5, - sf10, - sf16, - sf20, - sf32, - sf40, - sf64, - sf80, - sf128, - sf160, - sf320, - sf640, - sf1280, - sf2560, - infinity, - nulltype - } value; - typedef int16_t number_type; + std::string to_string() const; + }; + typedef enumerated types; - std::string to_string() const; - int16_t to_number() const; - }; - typedef enumerated periodic_bsr_timer_e_; - struct retx_bsr_timer_opts { - enum options { - sf10, - sf20, - sf40, - sf80, - sf160, - sf320, - sf640, - sf1280, - sf2560, - sf5120, - sf10240, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_recfg_complete_ies_s& rrc_recfg_complete() + { + assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const rrc_recfg_complete_ies_s& rrc_recfg_complete() const + { + assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "criticalExtensions"); + return c.get(); + } + rrc_recfg_complete_ies_s& set_rrc_recfg_complete() + { + set(types::rrc_recfg_complete); + return c.get(); + } - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated retx_bsr_timer_e_; - struct lc_ch_sr_delay_timer_opts { - enum options { sf20, sf40, sf64, sf128, sf512, sf1024, sf2560, spare1, nulltype } value; - typedef uint16_t number_type; + private: + types type_; + choice_buffer_t c; - std::string to_string() const; - uint16_t to_number() const; + void destroy_(); }; - typedef enumerated lc_ch_sr_delay_timer_e_; // member variables - bool ext = false; - bool lc_ch_sr_delay_timer_present = false; - periodic_bsr_timer_e_ periodic_bsr_timer; - retx_bsr_timer_e_ retx_bsr_timer; - lc_ch_sr_delay_timer_e_ lc_ch_sr_delay_timer; - // ... + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -12404,75 +10538,53 @@ struct bsr_cfg_s { void to_json(json_writer& j) const; }; -// DRB-ToAddMod ::= SEQUENCE -struct drb_to_add_mod_s { - struct cn_assoc_c_ { +// RRCReestablishmentComplete ::= SEQUENCE +struct rrc_reest_complete_s { + struct crit_exts_c_ { struct types_opts { - enum options { eps_bearer_id, sdap_cfg, nulltype } value; + enum options { rrc_reest_complete, crit_exts_future, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - cn_assoc_c_() = default; - cn_assoc_c_(const cn_assoc_c_& other); - cn_assoc_c_& operator=(const cn_assoc_c_& other); - ~cn_assoc_c_() { destroy_(); } + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& eps_bearer_id() - { - assert_choice_type("eps-BearerIdentity", type_.to_string(), "cnAssociation"); - return c.get(); - } - sdap_cfg_s& sdap_cfg() - { - assert_choice_type("sdap-Config", type_.to_string(), "cnAssociation"); - return c.get(); - } - const uint8_t& eps_bearer_id() const - { - assert_choice_type("eps-BearerIdentity", type_.to_string(), "cnAssociation"); - return c.get(); - } - const sdap_cfg_s& sdap_cfg() const + rrc_reest_complete_ies_s& rrc_reest_complete() { - assert_choice_type("sdap-Config", type_.to_string(), "cnAssociation"); - return c.get(); + assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& set_eps_bearer_id() + const rrc_reest_complete_ies_s& rrc_reest_complete() const { - set(types::eps_bearer_id); - return c.get(); + assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "criticalExtensions"); + return c.get(); } - sdap_cfg_s& set_sdap_cfg() + rrc_reest_complete_ies_s& set_rrc_reest_complete() { - set(types::sdap_cfg); - return c.get(); + set(types::rrc_reest_complete); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; // member variables - bool ext = false; - bool cn_assoc_present = false; - bool reestablish_pdcp_present = false; - bool recover_pdcp_present = false; - bool pdcp_cfg_present = false; - cn_assoc_c_ cn_assoc; - uint8_t drb_id = 1; - pdcp_cfg_s pdcp_cfg; - // ... + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -12480,764 +10592,971 @@ struct drb_to_add_mod_s { void to_json(json_writer& j) const; }; -// DRX-Config ::= SEQUENCE -struct drx_cfg_s { - struct drx_on_dur_timer_c_ { - struct milli_seconds_opts { - enum options { - ms1, - ms2, - ms3, - ms4, - ms5, - ms6, - ms8, - ms10, - ms20, - ms30, - ms40, - ms50, - ms60, - ms80, - ms100, - ms200, - ms300, - ms400, - ms500, - ms600, - ms800, - ms1000, - ms1200, - ms1600, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; +// RRCResumeComplete ::= SEQUENCE +struct rrc_resume_complete_s { + struct crit_exts_c_ { + struct types_opts { + enum options { rrc_resume_complete, crit_exts_future, nulltype } value; std::string to_string() const; - uint16_t to_number() const; }; - typedef enumerated milli_seconds_e_; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rrc_resume_complete_ies_s& rrc_resume_complete() + { + assert_choice_type("rrcResumeComplete", type_.to_string(), "criticalExtensions"); + return c.get(); + } + const rrc_resume_complete_ies_s& rrc_resume_complete() const + { + assert_choice_type("rrcResumeComplete", type_.to_string(), "criticalExtensions"); + return c.get(); + } + rrc_resume_complete_ies_s& set_rrc_resume_complete() + { + set(types::rrc_resume_complete); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RRCSetupComplete ::= SEQUENCE +struct rrc_setup_complete_s { + struct crit_exts_c_ { struct types_opts { - enum options { sub_milli_seconds, milli_seconds, nulltype } value; + enum options { rrc_setup_complete, crit_exts_future, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - drx_on_dur_timer_c_() = default; - drx_on_dur_timer_c_(const drx_on_dur_timer_c_& other); - drx_on_dur_timer_c_& operator=(const drx_on_dur_timer_c_& other); - ~drx_on_dur_timer_c_() { destroy_(); } + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& sub_milli_seconds() + rrc_setup_complete_ies_s& rrc_setup_complete() { - assert_choice_type("subMilliSeconds", type_.to_string(), "drx-onDurationTimer"); - return c.get(); + assert_choice_type("rrcSetupComplete", type_.to_string(), "criticalExtensions"); + return c.get(); } - milli_seconds_e_& milli_seconds() + const rrc_setup_complete_ies_s& rrc_setup_complete() const { - assert_choice_type("milliSeconds", type_.to_string(), "drx-onDurationTimer"); - return c.get(); + assert_choice_type("rrcSetupComplete", type_.to_string(), "criticalExtensions"); + return c.get(); } - const uint8_t& sub_milli_seconds() const + rrc_setup_complete_ies_s& set_rrc_setup_complete() { - assert_choice_type("subMilliSeconds", type_.to_string(), "drx-onDurationTimer"); - return c.get(); + set(types::rrc_setup_complete); + return c.get(); } - const milli_seconds_e_& milli_seconds() const + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SCGFailureInformation ::= SEQUENCE +struct scg_fail_info_s { + struct crit_exts_c_ { + struct types_opts { + enum options { scg_fail_info, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + scg_fail_info_ies_s& scg_fail_info() { - assert_choice_type("milliSeconds", type_.to_string(), "drx-onDurationTimer"); - return c.get(); + assert_choice_type("scgFailureInformation", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& set_sub_milli_seconds() + const scg_fail_info_ies_s& scg_fail_info() const { - set(types::sub_milli_seconds); - return c.get(); + assert_choice_type("scgFailureInformation", type_.to_string(), "criticalExtensions"); + return c.get(); } - milli_seconds_e_& set_milli_seconds() + scg_fail_info_ies_s& set_scg_fail_info() { - set(types::milli_seconds); - return c.get(); + set(types::scg_fail_info); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct drx_inactivity_timer_opts { - enum options { - ms0, - ms1, - ms2, - ms3, - ms4, - ms5, - ms6, - ms8, - ms10, - ms20, - ms30, - ms40, - ms50, - ms60, - ms80, - ms100, - ms200, - ms300, - ms500, - ms750, - ms1280, - ms1920, - ms2560, - spare9, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated drx_inactivity_timer_e_; - struct drx_retx_timer_dl_opts { - enum options { - sl0, - sl1, - sl2, - sl4, - sl6, - sl8, - sl16, - sl24, - sl33, - sl40, - sl64, - sl80, - sl96, - sl112, - sl128, - sl160, - sl320, - spare15, - spare14, - spare13, - spare12, - spare11, - spare10, - spare9, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; + // member variables + crit_exts_c_ crit_exts; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated drx_retx_timer_dl_e_; - struct drx_retx_timer_ul_opts { - enum options { - sl0, - sl1, - sl2, - sl4, - sl6, - sl8, - sl16, - sl24, - sl33, - sl40, - sl64, - sl80, - sl96, - sl112, - sl128, - sl160, - sl320, - spare15, - spare14, - spare13, - spare12, - spare11, - spare10, - spare9, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated drx_retx_timer_ul_e_; - struct drx_long_cycle_start_offset_c_ { +// SCGFailureInformationEUTRA ::= SEQUENCE +struct scg_fail_info_eutra_s { + struct crit_exts_c_ { struct types_opts { - enum options { - ms10, - ms20, - ms32, - ms40, - ms60, - ms64, - ms70, - ms80, - ms128, - ms160, - ms256, - ms320, - ms512, - ms640, - ms1024, - ms1280, - ms2048, - ms2560, - ms5120, - ms10240, - nulltype - } value; - typedef uint16_t number_type; + enum options { scg_fail_info_eutra, crit_exts_future, nulltype } value; std::string to_string() const; - uint16_t to_number() const; }; typedef enumerated types; // choice methods - drx_long_cycle_start_offset_c_() = default; - drx_long_cycle_start_offset_c_(const drx_long_cycle_start_offset_c_& other); - drx_long_cycle_start_offset_c_& operator=(const drx_long_cycle_start_offset_c_& other); - ~drx_long_cycle_start_offset_c_() { destroy_(); } + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& ms10() + scg_fail_info_eutra_ies_s& scg_fail_info_eutra() { - assert_choice_type("ms10", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("scgFailureInformationEUTRA", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& ms20() + const scg_fail_info_eutra_ies_s& scg_fail_info_eutra() const { - assert_choice_type("ms20", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("scgFailureInformationEUTRA", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& ms32() + scg_fail_info_eutra_ies_s& set_scg_fail_info_eutra() { - assert_choice_type("ms32", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + set(types::scg_fail_info_eutra); + return c.get(); } - uint8_t& ms40() + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SecurityModeComplete ::= SEQUENCE +struct security_mode_complete_s { + struct crit_exts_c_ { + struct types_opts { + enum options { security_mode_complete, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + security_mode_complete_ies_s& security_mode_complete() { - assert_choice_type("ms40", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("securityModeComplete", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& ms60() + const security_mode_complete_ies_s& security_mode_complete() const { - assert_choice_type("ms60", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("securityModeComplete", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& ms64() + security_mode_complete_ies_s& set_security_mode_complete() { - assert_choice_type("ms64", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + set(types::security_mode_complete); + return c.get(); } - uint8_t& ms70() + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SecurityModeFailure ::= SEQUENCE +struct security_mode_fail_s { + struct crit_exts_c_ { + struct types_opts { + enum options { security_mode_fail, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + security_mode_fail_ies_s& security_mode_fail() { - assert_choice_type("ms70", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("securityModeFailure", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& ms80() + const security_mode_fail_ies_s& security_mode_fail() const { - assert_choice_type("ms80", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("securityModeFailure", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint8_t& ms128() + security_mode_fail_ies_s& set_security_mode_fail() { - assert_choice_type("ms128", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + set(types::security_mode_fail); + return c.get(); } - uint8_t& ms160() + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UEAssistanceInformation ::= SEQUENCE +struct ueassist_info_s { + struct crit_exts_c_ { + struct types_opts { + enum options { ue_assist_info, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + ueassist_info_ies_s& ue_assist_info() { - assert_choice_type("ms160", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ueAssistanceInformation", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint16_t& ms256() + const ueassist_info_ies_s& ue_assist_info() const { - assert_choice_type("ms256", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ueAssistanceInformation", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint16_t& ms320() + ueassist_info_ies_s& set_ue_assist_info() { - assert_choice_type("ms320", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + set(types::ue_assist_info); + return c.get(); } - uint16_t& ms512() + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UECapabilityInformation ::= SEQUENCE +struct ue_cap_info_s { + struct crit_exts_c_ { + struct types_opts { + enum options { ue_cap_info, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + ue_cap_info_ies_s& ue_cap_info() { - assert_choice_type("ms512", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ueCapabilityInformation", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint16_t& ms640() + const ue_cap_info_ies_s& ue_cap_info() const { - assert_choice_type("ms640", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ueCapabilityInformation", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint16_t& ms1024() + ue_cap_info_ies_s& set_ue_cap_info() { - assert_choice_type("ms1024", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + set(types::ue_cap_info); + return c.get(); } - uint16_t& ms1280() + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + uint8_t rrc_transaction_id = 0; + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// ULInformationTransfer ::= SEQUENCE +struct ul_info_transfer_s { + struct crit_exts_c_ { + struct types_opts { + enum options { ul_info_transfer, crit_exts_future, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + ul_info_transfer_ies_s& ul_info_transfer() { - assert_choice_type("ms1280", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ulInformationTransfer", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint16_t& ms2048() + const ul_info_transfer_ies_s& ul_info_transfer() const { - assert_choice_type("ms2048", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ulInformationTransfer", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint16_t& ms2560() + ul_info_transfer_ies_s& set_ul_info_transfer() { - assert_choice_type("ms2560", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + set(types::ul_info_transfer); + return c.get(); } - uint16_t& ms5120() + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// ULInformationTransferMRDC ::= SEQUENCE +struct ul_info_transfer_mrdc_s { + struct crit_exts_c_ { + struct c1_c_ { + struct types_opts { + enum options { ul_info_transfer_mrdc, spare3, spare2, spare1, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + c1_c_() = default; + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + ul_info_transfer_mrdc_ies_s& ul_info_transfer_mrdc() + { + assert_choice_type("ulInformationTransferMRDC", type_.to_string(), "c1"); + return c; + } + const ul_info_transfer_mrdc_ies_s& ul_info_transfer_mrdc() const + { + assert_choice_type("ulInformationTransferMRDC", type_.to_string(), "c1"); + return c; + } + ul_info_transfer_mrdc_ies_s& set_ul_info_transfer_mrdc() + { + set(types::ul_info_transfer_mrdc); + return c; + } + + private: + types type_; + ul_info_transfer_mrdc_ies_s c; + }; + struct types_opts { + enum options { c1, crit_exts_future, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + crit_exts_c_() = default; + crit_exts_c_(const crit_exts_c_& other); + crit_exts_c_& operator=(const crit_exts_c_& other); + ~crit_exts_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + c1_c_& c1() { - assert_choice_type("ms5120", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("c1", type_.to_string(), "criticalExtensions"); + return c.get(); } - uint16_t& ms10240() + const c1_c_& c1() const { - assert_choice_type("ms10240", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("c1", type_.to_string(), "criticalExtensions"); + return c.get(); } - const uint8_t& ms10() const + c1_c_& set_c1() { - assert_choice_type("ms10", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + set(types::c1); + return c.get(); } - const uint8_t& ms20() const + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + crit_exts_c_ crit_exts; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UL-DCCH-MessageType ::= CHOICE +struct ul_dcch_msg_type_c { + struct c1_c_ { + struct types_opts { + enum options { + meas_report, + rrc_recfg_complete, + rrc_setup_complete, + rrc_reest_complete, + rrc_resume_complete, + security_mode_complete, + security_mode_fail, + ul_info_transfer, + location_meas_ind, + ue_cap_info, + counter_check_resp, + ue_assist_info, + fail_info, + ul_info_transfer_mrdc, + scg_fail_info, + scg_fail_info_eutra, + nulltype + } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + c1_c_() = default; + c1_c_(const c1_c_& other); + c1_c_& operator=(const c1_c_& other); + ~c1_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + meas_report_s& meas_report() { - assert_choice_type("ms20", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("measurementReport", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms32() const + rrc_recfg_complete_s& rrc_recfg_complete() { - assert_choice_type("ms32", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms40() const + rrc_setup_complete_s& rrc_setup_complete() { - assert_choice_type("ms40", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("rrcSetupComplete", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms60() const + rrc_reest_complete_s& rrc_reest_complete() { - assert_choice_type("ms60", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms64() const + rrc_resume_complete_s& rrc_resume_complete() { - assert_choice_type("ms64", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("rrcResumeComplete", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms70() const + security_mode_complete_s& security_mode_complete() { - assert_choice_type("ms70", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("securityModeComplete", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms80() const + security_mode_fail_s& security_mode_fail() { - assert_choice_type("ms80", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("securityModeFailure", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms128() const + ul_info_transfer_s& ul_info_transfer() { - assert_choice_type("ms128", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ulInformationTransfer", type_.to_string(), "c1"); + return c.get(); } - const uint8_t& ms160() const + location_meas_ind_s& location_meas_ind() { - assert_choice_type("ms160", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("locationMeasurementIndication", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms256() const + ue_cap_info_s& ue_cap_info() { - assert_choice_type("ms256", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ueCapabilityInformation", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms320() const + counter_check_resp_s& counter_check_resp() { - assert_choice_type("ms320", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("counterCheckResponse", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms512() const + ueassist_info_s& ue_assist_info() { - assert_choice_type("ms512", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ueAssistanceInformation", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms640() const + fail_info_s& fail_info() { - assert_choice_type("ms640", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("failureInformation", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms1024() const + ul_info_transfer_mrdc_s& ul_info_transfer_mrdc() { - assert_choice_type("ms1024", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("ulInformationTransferMRDC", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms1280() const + scg_fail_info_s& scg_fail_info() { - assert_choice_type("ms1280", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("scgFailureInformation", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms2048() const + scg_fail_info_eutra_s& scg_fail_info_eutra() { - assert_choice_type("ms2048", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("scgFailureInformationEUTRA", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms2560() const + const meas_report_s& meas_report() const { - assert_choice_type("ms2560", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("measurementReport", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms5120() const + const rrc_recfg_complete_s& rrc_recfg_complete() const { - assert_choice_type("ms5120", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "c1"); + return c.get(); } - const uint16_t& ms10240() const + const rrc_setup_complete_s& rrc_setup_complete() const { - assert_choice_type("ms10240", type_.to_string(), "drx-LongCycleStartOffset"); - return c.get(); + assert_choice_type("rrcSetupComplete", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms10() + const rrc_reest_complete_s& rrc_reest_complete() const { - set(types::ms10); - return c.get(); + assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms20() + const rrc_resume_complete_s& rrc_resume_complete() const { - set(types::ms20); - return c.get(); + assert_choice_type("rrcResumeComplete", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms32() + const security_mode_complete_s& security_mode_complete() const { - set(types::ms32); - return c.get(); + assert_choice_type("securityModeComplete", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms40() + const security_mode_fail_s& security_mode_fail() const { - set(types::ms40); - return c.get(); + assert_choice_type("securityModeFailure", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms60() + const ul_info_transfer_s& ul_info_transfer() const { - set(types::ms60); - return c.get(); + assert_choice_type("ulInformationTransfer", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms64() + const location_meas_ind_s& location_meas_ind() const { - set(types::ms64); - return c.get(); + assert_choice_type("locationMeasurementIndication", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms70() + const ue_cap_info_s& ue_cap_info() const { - set(types::ms70); - return c.get(); + assert_choice_type("ueCapabilityInformation", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms80() + const counter_check_resp_s& counter_check_resp() const { - set(types::ms80); - return c.get(); + assert_choice_type("counterCheckResponse", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms128() + const ueassist_info_s& ue_assist_info() const { - set(types::ms128); - return c.get(); + assert_choice_type("ueAssistanceInformation", type_.to_string(), "c1"); + return c.get(); } - uint8_t& set_ms160() + const fail_info_s& fail_info() const { - set(types::ms160); - return c.get(); + assert_choice_type("failureInformation", type_.to_string(), "c1"); + return c.get(); } - uint16_t& set_ms256() + const ul_info_transfer_mrdc_s& ul_info_transfer_mrdc() const { - set(types::ms256); - return c.get(); + assert_choice_type("ulInformationTransferMRDC", type_.to_string(), "c1"); + return c.get(); } - uint16_t& set_ms320() + const scg_fail_info_s& scg_fail_info() const { - set(types::ms320); - return c.get(); + assert_choice_type("scgFailureInformation", type_.to_string(), "c1"); + return c.get(); } - uint16_t& set_ms512() + const scg_fail_info_eutra_s& scg_fail_info_eutra() const { - set(types::ms512); - return c.get(); + assert_choice_type("scgFailureInformationEUTRA", type_.to_string(), "c1"); + return c.get(); } - uint16_t& set_ms640() + meas_report_s& set_meas_report() { - set(types::ms640); - return c.get(); + set(types::meas_report); + return c.get(); } - uint16_t& set_ms1024() + rrc_recfg_complete_s& set_rrc_recfg_complete() { - set(types::ms1024); - return c.get(); + set(types::rrc_recfg_complete); + return c.get(); } - uint16_t& set_ms1280() + rrc_setup_complete_s& set_rrc_setup_complete() { - set(types::ms1280); - return c.get(); + set(types::rrc_setup_complete); + return c.get(); } - uint16_t& set_ms2048() + rrc_reest_complete_s& set_rrc_reest_complete() { - set(types::ms2048); - return c.get(); + set(types::rrc_reest_complete); + return c.get(); } - uint16_t& set_ms2560() + rrc_resume_complete_s& set_rrc_resume_complete() { - set(types::ms2560); - return c.get(); + set(types::rrc_resume_complete); + return c.get(); } - uint16_t& set_ms5120() + security_mode_complete_s& set_security_mode_complete() { - set(types::ms5120); - return c.get(); + set(types::security_mode_complete); + return c.get(); } - uint16_t& set_ms10240() + security_mode_fail_s& set_security_mode_fail() { - set(types::ms10240); - return c.get(); + set(types::security_mode_fail); + return c.get(); + } + ul_info_transfer_s& set_ul_info_transfer() + { + set(types::ul_info_transfer); + return c.get(); + } + location_meas_ind_s& set_location_meas_ind() + { + set(types::location_meas_ind); + return c.get(); + } + ue_cap_info_s& set_ue_cap_info() + { + set(types::ue_cap_info); + return c.get(); + } + counter_check_resp_s& set_counter_check_resp() + { + set(types::counter_check_resp); + return c.get(); + } + ueassist_info_s& set_ue_assist_info() + { + set(types::ue_assist_info); + return c.get(); + } + fail_info_s& set_fail_info() + { + set(types::fail_info); + return c.get(); + } + ul_info_transfer_mrdc_s& set_ul_info_transfer_mrdc() + { + set(types::ul_info_transfer_mrdc); + return c.get(); + } + scg_fail_info_s& set_scg_fail_info() + { + set(types::scg_fail_info); + return c.get(); + } + scg_fail_info_eutra_s& set_scg_fail_info_eutra() + { + set(types::scg_fail_info_eutra); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; - - void destroy_(); - }; - struct short_drx_s_ { - struct drx_short_cycle_opts { - enum options { - ms2, - ms3, - ms4, - ms5, - ms6, - ms7, - ms8, - ms10, - ms14, - ms16, - ms20, - ms30, - ms32, - ms35, - ms40, - ms64, - ms80, - ms128, - ms160, - ms256, - ms320, - ms512, - ms640, - spare9, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated drx_short_cycle_e_; + types type_; + choice_buffer_t + c; - // member variables - drx_short_cycle_e_ drx_short_cycle; - uint8_t drx_short_cycle_timer = 1; + void destroy_(); }; + struct types_opts { + enum options { c1, msg_class_ext, nulltype } value; + typedef uint8_t number_type; - // member variables - bool short_drx_present = false; - drx_on_dur_timer_c_ drx_on_dur_timer; - drx_inactivity_timer_e_ drx_inactivity_timer; - uint8_t drx_harq_rtt_timer_dl = 0; - uint8_t drx_harq_rtt_timer_ul = 0; - drx_retx_timer_dl_e_ drx_retx_timer_dl; - drx_retx_timer_ul_e_ drx_retx_timer_ul; - drx_long_cycle_start_offset_c_ drx_long_cycle_start_offset; - short_drx_s_ short_drx; - uint8_t drx_slot_offset = 0; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - // sequence methods + // choice methods + ul_dcch_msg_type_c() = default; + ul_dcch_msg_type_c(const ul_dcch_msg_type_c& other); + ul_dcch_msg_type_c& operator=(const ul_dcch_msg_type_c& other); + ~ul_dcch_msg_type_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; -}; + // getters + c1_c_& c1() + { + assert_choice_type("c1", type_.to_string(), "UL-DCCH-MessageType"); + return c.get(); + } + const c1_c_& c1() const + { + assert_choice_type("c1", type_.to_string(), "UL-DCCH-MessageType"); + return c.get(); + } + c1_c_& set_c1() + { + set(types::c1); + return c.get(); + } -// DataInactivityTimer ::= ENUMERATED -struct data_inactivity_timer_opts { - enum options { s1, s2, s3, s5, s7, s10, s15, s20, s40, s50, s60, s80, s100, s120, s150, s180, nulltype } value; - typedef uint8_t number_type; +private: + types type_; + choice_buffer_t c; - std::string to_string() const; - uint8_t to_number() const; + void destroy_(); }; -typedef enumerated data_inactivity_timer_e; -// LogicalChannelConfig ::= SEQUENCE -struct lc_ch_cfg_s { - struct ul_specific_params_s_ { - struct prioritised_bit_rate_opts { - enum options { - kbps0, - kbps8, - kbps16, - kbps32, - kbps64, - kbps128, - kbps256, - kbps512, - kbps1024, - kbps2048, - kbps4096, - kbps8192, - kbps16384, - kbps32768, - kbps65536, - infinity, - nulltype - } value; - typedef int32_t number_type; +// UL-DCCH-Message ::= SEQUENCE +struct ul_dcch_msg_s { + ul_dcch_msg_type_c msg; - std::string to_string() const; - int32_t to_number() const; - }; - typedef enumerated prioritised_bit_rate_e_; - struct bucket_size_dur_opts { - enum options { - ms5, - ms10, - ms20, - ms50, - ms100, - ms150, - ms300, - ms500, - ms1000, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated bucket_size_dur_e_; - using allowed_serving_cells_l_ = bounded_array; - using allowed_scs_list_l_ = bounded_array; - struct max_pusch_dur_opts { - enum options { ms0p02, ms0p04, ms0p0625, ms0p125, ms0p25, ms0p5, spare2, spare1, nulltype } value; +// BFR-CSIRS-Resource ::= SEQUENCE +struct bfr_csirs_res_s { + using ra_occasion_list_l_ = dyn_array; - std::string to_string() const; - }; - typedef enumerated max_pusch_dur_e_; - struct bit_rate_query_prohibit_timer_opts { - enum options { s0, s0dot4, s0dot8, s1dot6, s3, s6, s12, s30, nulltype } value; - typedef float number_type; + // member variables + bool ext = false; + bool ra_occasion_list_present = false; + bool ra_preamb_idx_present = false; + uint8_t csi_rs = 0; + ra_occasion_list_l_ ra_occasion_list; + uint8_t ra_preamb_idx = 0; + // ... - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated bit_rate_query_prohibit_timer_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool ext = false; - bool allowed_serving_cells_present = false; - bool allowed_scs_list_present = false; - bool max_pusch_dur_present = false; - bool cfgured_grant_type1_allowed_present = false; - bool lc_ch_group_present = false; - bool sched_request_id_present = false; - uint8_t prio = 1; - prioritised_bit_rate_e_ prioritised_bit_rate; - bucket_size_dur_e_ bucket_size_dur; - allowed_serving_cells_l_ allowed_serving_cells; - allowed_scs_list_l_ allowed_scs_list; - max_pusch_dur_e_ max_pusch_dur; - uint8_t lc_ch_group = 0; - uint8_t sched_request_id = 0; - bool lc_ch_sr_mask = false; - bool lc_ch_sr_delay_timer_applied = false; - // ... - bool bit_rate_query_prohibit_timer_present = false; - bit_rate_query_prohibit_timer_e_ bit_rate_query_prohibit_timer; +// BFR-SSB-Resource ::= SEQUENCE +struct bfr_ssb_res_s { + bool ext = false; + uint8_t ssb = 0; + uint8_t ra_preamb_idx = 0; + // ... - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - }; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool ext = false; - bool ul_specific_params_present = false; - ul_specific_params_s_ ul_specific_params; +// CSI-FrequencyOccupation ::= SEQUENCE +struct csi_freq_occupation_s { + bool ext = false; + uint16_t start_rb = 0; + uint16_t nrof_rbs = 24; // ... // sequence methods @@ -13246,48 +11565,167 @@ struct lc_ch_cfg_s { void to_json(json_writer& j) const; }; -// PHR-Config ::= SEQUENCE -struct phr_cfg_s { - struct phr_periodic_timer_opts { - enum options { sf10, sf20, sf50, sf100, sf200, sf500, sf1000, infinity, nulltype } value; - typedef int16_t number_type; - - std::string to_string() const; - int16_t to_number() const; +// CSI-RS-ResourceMapping ::= SEQUENCE +struct csi_rs_res_map_s { + struct freq_domain_alloc_c_ { + struct types_opts { + enum options { row1, row2, row4, other, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + freq_domain_alloc_c_() = default; + freq_domain_alloc_c_(const freq_domain_alloc_c_& other); + freq_domain_alloc_c_& operator=(const freq_domain_alloc_c_& other); + ~freq_domain_alloc_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<4>& row1() + { + assert_choice_type("row1", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + fixed_bitstring<12>& row2() + { + assert_choice_type("row2", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + fixed_bitstring<3>& row4() + { + assert_choice_type("row4", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + fixed_bitstring<6>& other() + { + assert_choice_type("other", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + const fixed_bitstring<4>& row1() const + { + assert_choice_type("row1", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + const fixed_bitstring<12>& row2() const + { + assert_choice_type("row2", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + const fixed_bitstring<3>& row4() const + { + assert_choice_type("row4", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + const fixed_bitstring<6>& other() const + { + assert_choice_type("other", type_.to_string(), "frequencyDomainAllocation"); + return c.get >(); + } + fixed_bitstring<4>& set_row1() + { + set(types::row1); + return c.get >(); + } + fixed_bitstring<12>& set_row2() + { + set(types::row2); + return c.get >(); + } + fixed_bitstring<3>& set_row4() + { + set(types::row4); + return c.get >(); + } + fixed_bitstring<6>& set_other() + { + set(types::other); + return c.get >(); + } + + private: + types type_; + choice_buffer_t > c; + + void destroy_(); }; - typedef enumerated phr_periodic_timer_e_; - struct phr_prohibit_timer_opts { - enum options { sf0, sf10, sf20, sf50, sf100, sf200, sf500, sf1000, nulltype } value; - typedef uint16_t number_type; + struct nrof_ports_opts { + enum options { p1, p2, p4, p8, p12, p16, p24, p32, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; - uint16_t to_number() const; + uint8_t to_number() const; }; - typedef enumerated phr_prohibit_timer_e_; - struct phr_tx_pwr_factor_change_opts { - enum options { db1, db3, db6, infinity, nulltype } value; - typedef int8_t number_type; + typedef enumerated nrof_ports_e_; + struct cdm_type_opts { + enum options { no_cdm, fd_cdm2, cdm4_fd2_td2, cdm8_fd2_td4, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; - int8_t to_number() const; + uint8_t to_number() const; }; - typedef enumerated phr_tx_pwr_factor_change_e_; - struct phr_mode_other_cg_opts { - enum options { real, virtual_value, nulltype } value; + typedef enumerated cdm_type_e_; + struct density_c_ { + struct dot5_opts { + enum options { even_prbs, odd_prbs, nulltype } value; - std::string to_string() const; + std::string to_string() const; + }; + typedef enumerated dot5_e_; + struct types_opts { + enum options { dot5, one, three, spare, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + density_c_() = default; + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + dot5_e_& dot5() + { + assert_choice_type("dot5", type_.to_string(), "density"); + return c; + } + const dot5_e_& dot5() const + { + assert_choice_type("dot5", type_.to_string(), "density"); + return c; + } + dot5_e_& set_dot5() + { + set(types::dot5); + return c; + } + + private: + types type_; + dot5_e_ c; }; - typedef enumerated phr_mode_other_cg_e_; // member variables - bool ext = false; - phr_periodic_timer_e_ phr_periodic_timer; - phr_prohibit_timer_e_ phr_prohibit_timer; - phr_tx_pwr_factor_change_e_ phr_tx_pwr_factor_change; - bool multiple_phr = false; - bool dummy = false; - bool phr_type2_other_cell = false; - phr_mode_other_cg_e_ phr_mode_other_cg; + bool ext = false; + bool first_ofdm_symbol_in_time_domain2_present = false; + freq_domain_alloc_c_ freq_domain_alloc; + nrof_ports_e_ nrof_ports; + uint8_t first_ofdm_symbol_in_time_domain = 0; + uint8_t first_ofdm_symbol_in_time_domain2 = 2; + cdm_type_e_ cdm_type; + density_c_ density; + csi_freq_occupation_s freq_band; // ... // sequence methods @@ -13296,151 +11734,282 @@ struct phr_cfg_s { void to_json(json_writer& j) const; }; -// RLC-Config ::= CHOICE -struct rlc_cfg_c { - struct am_s_ { - ul_am_rlc_s ul_am_rlc; - dl_am_rlc_s dl_am_rlc; - }; - struct um_bi_dir_s_ { - ul_um_rlc_s ul_um_rlc; - dl_um_rlc_s dl_um_rlc; - }; - struct um_uni_dir_ul_s_ { - ul_um_rlc_s ul_um_rlc; - }; - struct um_uni_dir_dl_s_ { - dl_um_rlc_s dl_um_rlc; - }; +// CSI-ResourcePeriodicityAndOffset ::= CHOICE +struct csi_res_periodicity_and_offset_c { struct types_opts { - enum options { am, um_bi_dir, um_uni_dir_ul, um_uni_dir_dl, /*...*/ nulltype } value; + enum options { + slots4, + slots5, + slots8, + slots10, + slots16, + slots20, + slots32, + slots40, + slots64, + slots80, + slots160, + slots320, + slots640, + nulltype + } value; + typedef uint16_t number_type; std::string to_string() const; + uint16_t to_number() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - rlc_cfg_c() = default; - rlc_cfg_c(const rlc_cfg_c& other); - rlc_cfg_c& operator=(const rlc_cfg_c& other); - ~rlc_cfg_c() { destroy_(); } + csi_res_periodicity_and_offset_c() = default; + csi_res_periodicity_and_offset_c(const csi_res_periodicity_and_offset_c& other); + csi_res_periodicity_and_offset_c& operator=(const csi_res_periodicity_and_offset_c& other); + ~csi_res_periodicity_and_offset_c() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - am_s_& am() + uint8_t& slots4() { - assert_choice_type("am", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots4", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - um_bi_dir_s_& um_bi_dir() + uint8_t& slots5() { - assert_choice_type("um-Bi-Directional", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots5", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - um_uni_dir_ul_s_& um_uni_dir_ul() + uint8_t& slots8() { - assert_choice_type("um-Uni-Directional-UL", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots8", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - um_uni_dir_dl_s_& um_uni_dir_dl() + uint8_t& slots10() { - assert_choice_type("um-Uni-Directional-DL", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots10", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - const am_s_& am() const + uint8_t& slots16() { - assert_choice_type("am", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots16", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - const um_bi_dir_s_& um_bi_dir() const + uint8_t& slots20() { - assert_choice_type("um-Bi-Directional", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots20", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - const um_uni_dir_ul_s_& um_uni_dir_ul() const + uint8_t& slots32() { - assert_choice_type("um-Uni-Directional-UL", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots32", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - const um_uni_dir_dl_s_& um_uni_dir_dl() const + uint8_t& slots40() { - assert_choice_type("um-Uni-Directional-DL", type_.to_string(), "RLC-Config"); - return c.get(); + assert_choice_type("slots40", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - am_s_& set_am() + uint8_t& slots64() { - set(types::am); - return c.get(); + assert_choice_type("slots64", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - um_bi_dir_s_& set_um_bi_dir() + uint8_t& slots80() { - set(types::um_bi_dir); - return c.get(); + assert_choice_type("slots80", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - um_uni_dir_ul_s_& set_um_uni_dir_ul() + uint8_t& slots160() { - set(types::um_uni_dir_ul); - return c.get(); + assert_choice_type("slots160", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); } - um_uni_dir_dl_s_& set_um_uni_dir_dl() + uint16_t& slots320() { - set(types::um_uni_dir_dl); - return c.get(); + assert_choice_type("slots320", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + uint16_t& slots640() + { + assert_choice_type("slots640", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots4() const + { + assert_choice_type("slots4", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots5() const + { + assert_choice_type("slots5", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots8() const + { + assert_choice_type("slots8", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots10() const + { + assert_choice_type("slots10", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots16() const + { + assert_choice_type("slots16", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots20() const + { + assert_choice_type("slots20", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots32() const + { + assert_choice_type("slots32", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots40() const + { + assert_choice_type("slots40", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots64() const + { + assert_choice_type("slots64", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots80() const + { + assert_choice_type("slots80", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots160() const + { + assert_choice_type("slots160", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint16_t& slots320() const + { + assert_choice_type("slots320", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + const uint16_t& slots640() const + { + assert_choice_type("slots640", type_.to_string(), "CSI-ResourcePeriodicityAndOffset"); + return c.get(); + } + uint8_t& set_slots4() + { + set(types::slots4); + return c.get(); + } + uint8_t& set_slots5() + { + set(types::slots5); + return c.get(); + } + uint8_t& set_slots8() + { + set(types::slots8); + return c.get(); + } + uint8_t& set_slots10() + { + set(types::slots10); + return c.get(); + } + uint8_t& set_slots16() + { + set(types::slots16); + return c.get(); + } + uint8_t& set_slots20() + { + set(types::slots20); + return c.get(); + } + uint8_t& set_slots32() + { + set(types::slots32); + return c.get(); + } + uint8_t& set_slots40() + { + set(types::slots40); + return c.get(); + } + uint8_t& set_slots64() + { + set(types::slots64); + return c.get(); + } + uint8_t& set_slots80() + { + set(types::slots80); + return c.get(); + } + uint8_t& set_slots160() + { + set(types::slots160); + return c.get(); + } + uint16_t& set_slots320() + { + set(types::slots320); + return c.get(); + } + uint16_t& set_slots640() + { + set(types::slots640); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; -// RLF-TimersAndConstants ::= SEQUENCE -struct rlf_timers_and_consts_s { - struct t310_opts { - enum options { ms0, ms50, ms100, ms200, ms500, ms1000, ms2000, ms4000, ms6000, nulltype } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated t310_e_; - struct n310_opts { - enum options { n1, n2, n3, n4, n6, n8, n10, n20, nulltype } value; - typedef uint8_t number_type; +// INT-ConfigurationPerServingCell ::= SEQUENCE +struct int_cfg_per_serving_cell_s { + uint8_t serving_cell_id = 0; + uint8_t position_in_dci = 0; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated n310_e_; - struct n311_opts { - enum options { n1, n2, n3, n4, n5, n6, n8, n10, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated n311_e_; - struct t311_v1530_opts { - enum options { ms1000, ms3000, ms5000, ms10000, ms15000, ms20000, ms30000, nulltype } value; - typedef uint16_t number_type; +// PTRS-DownlinkConfig ::= SEQUENCE +struct ptrs_dl_cfg_s { + using freq_density_l_ = std::array; + using time_density_l_ = std::array; + struct res_elem_offset_opts { + enum options { offset01, offset10, offset11, nulltype } value; + typedef float number_type; std::string to_string() const; - uint16_t to_number() const; + float to_number() const; + std::string to_number_string() const; }; - typedef enumerated t311_v1530_e_; + typedef enumerated res_elem_offset_e_; // member variables - bool ext = false; - t310_e_ t310; - n310_e_ n310; - n311_e_ n311; + bool ext = false; + bool freq_density_present = false; + bool time_density_present = false; + bool epre_ratio_present = false; + bool res_elem_offset_present = false; + freq_density_l_ freq_density; + time_density_l_ time_density; + uint8_t epre_ratio = 0; + res_elem_offset_e_ res_elem_offset; // ... - // group 0 - t311_v1530_e_ t311_v1530; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -13448,84 +12017,80 @@ struct rlf_timers_and_consts_s { void to_json(json_writer& j) const; }; -// ReconfigurationWithSync ::= SEQUENCE -struct recfg_with_sync_s { - struct t304_opts { - enum options { ms50, ms100, ms150, ms200, ms500, ms1000, ms2000, ms10000, nulltype } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated t304_e_; - struct rach_cfg_ded_c_ { +// QCL-Info ::= SEQUENCE +struct qcl_info_s { + struct ref_sig_c_ { struct types_opts { - enum options { ul, supplementary_ul, nulltype } value; + enum options { csi_rs, ssb, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - rach_cfg_ded_c_() = default; - rach_cfg_ded_c_(const rach_cfg_ded_c_& other); - rach_cfg_ded_c_& operator=(const rach_cfg_ded_c_& other); - ~rach_cfg_ded_c_() { destroy_(); } - void set(types::options e = types::nulltype); + ref_sig_c_() = default; + ref_sig_c_(const ref_sig_c_& other); + ref_sig_c_& operator=(const ref_sig_c_& other); + ~ref_sig_c_() { destroy_(); } + void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - rach_cfg_ded_s& ul() + uint8_t& csi_rs() { - assert_choice_type("uplink", type_.to_string(), "rach-ConfigDedicated"); - return c.get(); + assert_choice_type("csi-rs", type_.to_string(), "referenceSignal"); + return c.get(); } - rach_cfg_ded_s& supplementary_ul() + uint8_t& ssb() { - assert_choice_type("supplementaryUplink", type_.to_string(), "rach-ConfigDedicated"); - return c.get(); + assert_choice_type("ssb", type_.to_string(), "referenceSignal"); + return c.get(); } - const rach_cfg_ded_s& ul() const + const uint8_t& csi_rs() const { - assert_choice_type("uplink", type_.to_string(), "rach-ConfigDedicated"); - return c.get(); + assert_choice_type("csi-rs", type_.to_string(), "referenceSignal"); + return c.get(); } - const rach_cfg_ded_s& supplementary_ul() const + const uint8_t& ssb() const { - assert_choice_type("supplementaryUplink", type_.to_string(), "rach-ConfigDedicated"); - return c.get(); + assert_choice_type("ssb", type_.to_string(), "referenceSignal"); + return c.get(); } - rach_cfg_ded_s& set_ul() + uint8_t& set_csi_rs() { - set(types::ul); - return c.get(); + set(types::csi_rs); + return c.get(); } - rach_cfg_ded_s& set_supplementary_ul() + uint8_t& set_ssb() { - set(types::supplementary_ul); - return c.get(); + set(types::ssb); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; + struct qcl_type_opts { + enum options { type_a, type_b, type_c, type_d, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated qcl_type_e_; // member variables - bool ext = false; - bool sp_cell_cfg_common_present = false; - bool rach_cfg_ded_present = false; - serving_cell_cfg_common_s sp_cell_cfg_common; - uint32_t new_ue_id = 0; - t304_e_ t304; - rach_cfg_ded_c_ rach_cfg_ded; + bool ext = false; + bool cell_present = false; + bool bwp_id_present = false; + uint8_t cell = 0; + uint8_t bwp_id = 0; + ref_sig_c_ ref_sig; + qcl_type_e_ qcl_type; // ... - // group 0 - copy_ptr smtc; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -13533,14 +12098,29 @@ struct recfg_with_sync_s { void to_json(json_writer& j) const; }; -// SRB-ToAddMod ::= SEQUENCE -struct srb_to_add_mod_s { - bool ext = false; - bool reestablish_pdcp_present = false; - bool discard_on_pdcp_present = false; - bool pdcp_cfg_present = false; - uint8_t srb_id = 1; - pdcp_cfg_s pdcp_cfg; +// DMRS-DownlinkConfig ::= SEQUENCE +struct dmrs_dl_cfg_s { + struct dmrs_add_position_opts { + enum options { pos0, pos1, pos3, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated dmrs_add_position_e_; + + // member variables + bool ext = false; + bool dmrs_type_present = false; + bool dmrs_add_position_present = false; + bool max_len_present = false; + bool scrambling_id0_present = false; + bool scrambling_id1_present = false; + bool phase_tracking_rs_present = false; + dmrs_add_position_e_ dmrs_add_position; + uint32_t scrambling_id0 = 0; + uint32_t scrambling_id1 = 0; + setup_release_c phase_tracking_rs; // ... // sequence methods @@ -13549,16 +12129,25 @@ struct srb_to_add_mod_s { void to_json(json_writer& j) const; }; -// SchedulingRequestConfig ::= SEQUENCE -struct sched_request_cfg_s { - using sched_request_to_add_mod_list_l_ = dyn_array; - using sched_request_to_release_list_l_ = bounded_array; +// DownlinkPreemption ::= SEQUENCE +struct dl_preemption_s { + struct time_freq_set_opts { + enum options { set0, set1, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated time_freq_set_e_; + using int_cfg_per_serving_cell_l_ = dyn_array; // member variables - bool sched_request_to_add_mod_list_present = false; - bool sched_request_to_release_list_present = false; - sched_request_to_add_mod_list_l_ sched_request_to_add_mod_list; - sched_request_to_release_list_l_ sched_request_to_release_list; + bool ext = false; + uint32_t int_rnti = 0; + time_freq_set_e_ time_freq_set; + uint8_t dci_payload_size = 0; + int_cfg_per_serving_cell_l_ int_cfg_per_serving_cell; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -13566,12 +12155,13 @@ struct sched_request_cfg_s { void to_json(json_writer& j) const; }; -// SecurityAlgorithmConfig ::= SEQUENCE -struct security_algorithm_cfg_s { - bool ext = false; - bool integrity_prot_algorithm_present = false; - ciphering_algorithm_e ciphering_algorithm; - integrity_prot_algorithm_e integrity_prot_algorithm; +// PUCCH-TPC-CommandConfig ::= SEQUENCE +struct pucch_tpc_cmd_cfg_s { + bool ext = false; + bool tpc_idx_pcell_present = false; + bool tpc_idx_pucch_scell_present = false; + uint8_t tpc_idx_pcell = 1; + uint8_t tpc_idx_pucch_scell = 1; // ... // sequence methods @@ -13580,284 +12170,78 @@ struct security_algorithm_cfg_s { void to_json(json_writer& j) const; }; -// ServingCellConfig ::= SEQUENCE -struct serving_cell_cfg_s { - using dl_bwp_to_release_list_l_ = bounded_array; - using dl_bwp_to_add_mod_list_l_ = dyn_array; - struct bwp_inactivity_timer_opts { - enum options { - ms2, - ms3, - ms4, - ms5, - ms6, - ms8, - ms10, - ms20, - ms30, - ms40, - ms50, - ms60, - ms80, - ms100, - ms200, - ms300, - ms500, - ms750, - ms1280, - ms1920, - ms2560, - spare10, - spare9, - spare8, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; +// PUSCH-TPC-CommandConfig ::= SEQUENCE +struct pusch_tpc_cmd_cfg_s { + bool ext = false; + bool tpc_idx_present = false; + bool tpc_idx_sul_present = false; + bool target_cell_present = false; + uint8_t tpc_idx = 1; + uint8_t tpc_idx_sul = 1; + uint8_t target_cell = 0; + // ... - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated bwp_inactivity_timer_e_; - struct scell_deactivation_timer_opts { - enum options { - ms20, - ms40, - ms80, - ms160, - ms200, - ms240, - ms320, - ms400, - ms480, - ms520, - ms640, - ms720, - ms840, - ms1280, - spare2, - spare1, - nulltype - } value; - typedef uint16_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated scell_deactivation_timer_e_; - struct pathloss_ref_linking_opts { - enum options { pcell, scell, nulltype } value; +// RadioLinkMonitoringRS ::= SEQUENCE +struct radio_link_monitoring_rs_s { + struct purpose_opts { + enum options { beam_fail, rlf, both, nulltype } value; std::string to_string() const; }; - typedef enumerated pathloss_ref_linking_e_; - using rate_match_pattern_to_add_mod_list_l_ = dyn_array; - using rate_match_pattern_to_release_list_l_ = bounded_array; - using dl_ch_bw_per_scs_list_l_ = dyn_array; - - // member variables - bool ext = false; - bool tdd_ul_dl_cfg_ded_present = false; - bool init_dl_bwp_present = false; - bool dl_bwp_to_release_list_present = false; - bool dl_bwp_to_add_mod_list_present = false; - bool first_active_dl_bwp_id_present = false; - bool bwp_inactivity_timer_present = false; - bool default_dl_bwp_id_present = false; - bool ul_cfg_present = false; - bool supplementary_ul_present = false; - bool pdcch_serving_cell_cfg_present = false; - bool pdsch_serving_cell_cfg_present = false; - bool csi_meas_cfg_present = false; - bool scell_deactivation_timer_present = false; - bool cross_carrier_sched_cfg_present = false; - bool dummy_present = false; - bool pathloss_ref_linking_present = false; - bool serving_cell_mo_present = false; - tdd_ul_dl_cfg_ded_s tdd_ul_dl_cfg_ded; - bwp_dl_ded_s init_dl_bwp; - dl_bwp_to_release_list_l_ dl_bwp_to_release_list; - dl_bwp_to_add_mod_list_l_ dl_bwp_to_add_mod_list; - uint8_t first_active_dl_bwp_id = 0; - bwp_inactivity_timer_e_ bwp_inactivity_timer; - uint8_t default_dl_bwp_id = 0; - ul_cfg_s ul_cfg; - ul_cfg_s supplementary_ul; - setup_release_c pdcch_serving_cell_cfg; - setup_release_c pdsch_serving_cell_cfg; - setup_release_c csi_meas_cfg; - scell_deactivation_timer_e_ scell_deactivation_timer; - cross_carrier_sched_cfg_s cross_carrier_sched_cfg; - uint8_t tag_id = 0; - pathloss_ref_linking_e_ pathloss_ref_linking; - uint8_t serving_cell_mo = 1; - // ... - // group 0 - copy_ptr > lte_crs_to_match_around; - copy_ptr rate_match_pattern_to_add_mod_list; - copy_ptr rate_match_pattern_to_release_list; - copy_ptr dl_ch_bw_per_scs_list; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// TAG-Config ::= SEQUENCE -struct tag_cfg_s { - using tag_to_release_list_l_ = bounded_array; - using tag_to_add_mod_list_l_ = dyn_array; - - // member variables - bool tag_to_release_list_present = false; - bool tag_to_add_mod_list_present = false; - tag_to_release_list_l_ tag_to_release_list; - tag_to_add_mod_list_l_ tag_to_add_mod_list; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// DRB-ToAddModList ::= SEQUENCE (SIZE (1..29)) OF DRB-ToAddMod -using drb_to_add_mod_list_l = dyn_array; - -// DRB-ToReleaseList ::= SEQUENCE (SIZE (1..29)) OF INTEGER (1..32) -using drb_to_release_list_l = bounded_array; - -// MAC-CellGroupConfig ::= SEQUENCE -struct mac_cell_group_cfg_s { - bool ext = false; - bool drx_cfg_present = false; - bool sched_request_cfg_present = false; - bool bsr_cfg_present = false; - bool tag_cfg_present = false; - bool phr_cfg_present = false; - setup_release_c drx_cfg; - sched_request_cfg_s sched_request_cfg; - bsr_cfg_s bsr_cfg; - tag_cfg_s tag_cfg; - setup_release_c phr_cfg; - bool skip_ul_tx_dynamic = false; - // ... - // group 0 - bool csi_mask_v1530_present = false; - bool csi_mask_v1530 = false; - copy_ptr > data_inactivity_timer_v1530; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PhysicalCellGroupConfig ::= SEQUENCE -struct phys_cell_group_cfg_s { - struct pdsch_harq_ack_codebook_opts { - enum options { semi_static, dynamic_value, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated pdsch_harq_ack_codebook_e_; - struct xscale_opts { - enum options { db0, db6, spare2, spare1, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated xscale_e_; - - // member variables - bool ext = false; - bool harq_ack_spatial_bundling_pucch_present = false; - bool harq_ack_spatial_bundling_pusch_present = false; - bool p_nr_fr1_present = false; - bool tpc_srs_rnti_present = false; - bool tpc_pucch_rnti_present = false; - bool tpc_pusch_rnti_present = false; - bool sp_csi_rnti_present = false; - bool cs_rnti_present = false; - int8_t p_nr_fr1 = -30; - pdsch_harq_ack_codebook_e_ pdsch_harq_ack_codebook; - uint32_t tpc_srs_rnti = 0; - uint32_t tpc_pucch_rnti = 0; - uint32_t tpc_pusch_rnti = 0; - uint32_t sp_csi_rnti = 0; - setup_release_c > cs_rnti; - // ... - // group 0 - bool mcs_c_rnti_present = false; - bool p_ue_fr1_present = false; - uint32_t mcs_c_rnti = 0; - int8_t p_ue_fr1 = -30; - // group 1 - bool xscale_present = false; - xscale_e_ xscale; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// RLC-BearerConfig ::= SEQUENCE -struct rlc_bearer_cfg_s { - struct served_radio_bearer_c_ { - struct types_opts { - enum options { srb_id, drb_id, nulltype } value; + typedef enumerated purpose_e_; + struct detection_res_c_ { + struct types_opts { + enum options { ssb_idx, csi_rs_idx, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - served_radio_bearer_c_() = default; - served_radio_bearer_c_(const served_radio_bearer_c_& other); - served_radio_bearer_c_& operator=(const served_radio_bearer_c_& other); - ~served_radio_bearer_c_() { destroy_(); } + detection_res_c_() = default; + detection_res_c_(const detection_res_c_& other); + detection_res_c_& operator=(const detection_res_c_& other); + ~detection_res_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& srb_id() + uint8_t& ssb_idx() { - assert_choice_type("srb-Identity", type_.to_string(), "servedRadioBearer"); + assert_choice_type("ssb-Index", type_.to_string(), "detectionResource"); return c.get(); } - uint8_t& drb_id() + uint8_t& csi_rs_idx() { - assert_choice_type("drb-Identity", type_.to_string(), "servedRadioBearer"); + assert_choice_type("csi-RS-Index", type_.to_string(), "detectionResource"); return c.get(); } - const uint8_t& srb_id() const + const uint8_t& ssb_idx() const { - assert_choice_type("srb-Identity", type_.to_string(), "servedRadioBearer"); + assert_choice_type("ssb-Index", type_.to_string(), "detectionResource"); return c.get(); } - const uint8_t& drb_id() const + const uint8_t& csi_rs_idx() const { - assert_choice_type("drb-Identity", type_.to_string(), "servedRadioBearer"); + assert_choice_type("csi-RS-Index", type_.to_string(), "detectionResource"); return c.get(); } - uint8_t& set_srb_id() + uint8_t& set_ssb_idx() { - set(types::srb_id); + set(types::ssb_idx); return c.get(); } - uint8_t& set_drb_id() + uint8_t& set_csi_rs_idx() { - set(types::drb_id); + set(types::csi_rs_idx); return c.get(); } @@ -13869,15 +12253,10 @@ struct rlc_bearer_cfg_s { }; // member variables - bool ext = false; - bool served_radio_bearer_present = false; - bool reestablish_rlc_present = false; - bool rlc_cfg_present = false; - bool mac_lc_ch_cfg_present = false; - uint8_t lc_ch_id = 1; - served_radio_bearer_c_ served_radio_bearer; - rlc_cfg_c rlc_cfg; - lc_ch_cfg_s mac_lc_ch_cfg; + bool ext = false; + uint8_t radio_link_monitoring_rs_id = 0; + purpose_e_ purpose; + detection_res_c_ detection_res; // ... // sequence methods @@ -13886,252 +12265,280 @@ struct rlc_bearer_cfg_s { void to_json(json_writer& j) const; }; -// SCellConfig ::= SEQUENCE -struct scell_cfg_s { - bool ext = false; - bool scell_cfg_common_present = false; - bool scell_cfg_ded_present = false; - uint8_t scell_idx = 1; - serving_cell_cfg_common_s scell_cfg_common; - serving_cell_cfg_s scell_cfg_ded; - // ... - // group 0 - copy_ptr smtc; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; +// RateMatchPattern ::= SEQUENCE +struct rate_match_pattern_s { + struct pattern_type_c_ { + struct bitmaps_s_ { + struct symbols_in_res_block_c_ { + struct types_opts { + enum options { one_slot, two_slots, nulltype } value; + typedef uint8_t number_type; -// SRB-ToAddModList ::= SEQUENCE (SIZE (1..2)) OF SRB-ToAddMod -using srb_to_add_mod_list_l = dyn_array; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; -// SecurityConfig ::= SEQUENCE -struct security_cfg_s { - struct key_to_use_opts { - enum options { master, secondary, nulltype } value; + // choice methods + symbols_in_res_block_c_() = default; + symbols_in_res_block_c_(const symbols_in_res_block_c_& other); + symbols_in_res_block_c_& operator=(const symbols_in_res_block_c_& other); + ~symbols_in_res_block_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<14>& one_slot() + { + assert_choice_type("oneSlot", type_.to_string(), "symbolsInResourceBlock"); + return c.get >(); + } + fixed_bitstring<28>& two_slots() + { + assert_choice_type("twoSlots", type_.to_string(), "symbolsInResourceBlock"); + return c.get >(); + } + const fixed_bitstring<14>& one_slot() const + { + assert_choice_type("oneSlot", type_.to_string(), "symbolsInResourceBlock"); + return c.get >(); + } + const fixed_bitstring<28>& two_slots() const + { + assert_choice_type("twoSlots", type_.to_string(), "symbolsInResourceBlock"); + return c.get >(); + } + fixed_bitstring<14>& set_one_slot() + { + set(types::one_slot); + return c.get >(); + } + fixed_bitstring<28>& set_two_slots() + { + set(types::two_slots); + return c.get >(); + } - std::string to_string() const; - }; - typedef enumerated key_to_use_e_; + private: + types type_; + choice_buffer_t > c; - // member variables - bool ext = false; - bool security_algorithm_cfg_present = false; - bool key_to_use_present = false; - security_algorithm_cfg_s security_algorithm_cfg; - key_to_use_e_ key_to_use; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// SpCellConfig ::= SEQUENCE -struct sp_cell_cfg_s { - bool ext = false; - bool serv_cell_idx_present = false; - bool recfg_with_sync_present = false; - bool rlf_timers_and_consts_present = false; - bool rlm_in_sync_out_of_sync_thres_present = false; - bool sp_cell_cfg_ded_present = false; - uint8_t serv_cell_idx = 0; - recfg_with_sync_s recfg_with_sync; - setup_release_c rlf_timers_and_consts; - serving_cell_cfg_s sp_cell_cfg_ded; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CellGroupConfig ::= SEQUENCE -struct cell_group_cfg_s { - using rlc_bearer_to_add_mod_list_l_ = dyn_array; - using rlc_bearer_to_release_list_l_ = bounded_array; - using scell_to_add_mod_list_l_ = dyn_array; - using scell_to_release_list_l_ = bounded_array; - - // member variables - bool ext = false; - bool rlc_bearer_to_add_mod_list_present = false; - bool rlc_bearer_to_release_list_present = false; - bool mac_cell_group_cfg_present = false; - bool phys_cell_group_cfg_present = false; - bool sp_cell_cfg_present = false; - bool scell_to_add_mod_list_present = false; - bool scell_to_release_list_present = false; - uint8_t cell_group_id = 0; - rlc_bearer_to_add_mod_list_l_ rlc_bearer_to_add_mod_list; - rlc_bearer_to_release_list_l_ rlc_bearer_to_release_list; - mac_cell_group_cfg_s mac_cell_group_cfg; - phys_cell_group_cfg_s phys_cell_group_cfg; - sp_cell_cfg_s sp_cell_cfg; - scell_to_add_mod_list_l_ scell_to_add_mod_list; - scell_to_release_list_l_ scell_to_release_list; - // ... - // group 0 - bool report_ul_tx_direct_current_v1530_present = false; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// RadioBearerConfig ::= SEQUENCE -struct radio_bearer_cfg_s { - bool ext = false; - bool srb_to_add_mod_list_present = false; - bool srb3_to_release_present = false; - bool drb_to_add_mod_list_present = false; - bool drb_to_release_list_present = false; - bool security_cfg_present = false; - srb_to_add_mod_list_l srb_to_add_mod_list; - drb_to_add_mod_list_l drb_to_add_mod_list; - drb_to_release_list_l drb_to_release_list; - security_cfg_s security_cfg; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + void destroy_(); + }; + struct periodicity_and_pattern_c_ { + struct types_opts { + enum options { n2, n4, n5, n8, n10, n20, n40, nulltype } value; + typedef uint8_t number_type; -// RRCReject-IEs ::= SEQUENCE -struct rrc_reject_ies_s { - bool wait_time_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - uint8_t wait_time = 1; - dyn_octstring late_non_crit_ext; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // choice methods + periodicity_and_pattern_c_() = default; + periodicity_and_pattern_c_(const periodicity_and_pattern_c_& other); + periodicity_and_pattern_c_& operator=(const periodicity_and_pattern_c_& other); + ~periodicity_and_pattern_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<2>& n2() + { + assert_choice_type("n2", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + fixed_bitstring<4>& n4() + { + assert_choice_type("n4", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + fixed_bitstring<5>& n5() + { + assert_choice_type("n5", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + fixed_bitstring<8>& n8() + { + assert_choice_type("n8", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + fixed_bitstring<10>& n10() + { + assert_choice_type("n10", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + fixed_bitstring<20>& n20() + { + assert_choice_type("n20", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + fixed_bitstring<40>& n40() + { + assert_choice_type("n40", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + const fixed_bitstring<2>& n2() const + { + assert_choice_type("n2", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + const fixed_bitstring<4>& n4() const + { + assert_choice_type("n4", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + const fixed_bitstring<5>& n5() const + { + assert_choice_type("n5", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + const fixed_bitstring<8>& n8() const + { + assert_choice_type("n8", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + const fixed_bitstring<10>& n10() const + { + assert_choice_type("n10", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + const fixed_bitstring<20>& n20() const + { + assert_choice_type("n20", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + const fixed_bitstring<40>& n40() const + { + assert_choice_type("n40", type_.to_string(), "periodicityAndPattern"); + return c.get >(); + } + fixed_bitstring<2>& set_n2() + { + set(types::n2); + return c.get >(); + } + fixed_bitstring<4>& set_n4() + { + set(types::n4); + return c.get >(); + } + fixed_bitstring<5>& set_n5() + { + set(types::n5); + return c.get >(); + } + fixed_bitstring<8>& set_n8() + { + set(types::n8); + return c.get >(); + } + fixed_bitstring<10>& set_n10() + { + set(types::n10); + return c.get >(); + } + fixed_bitstring<20>& set_n20() + { + set(types::n20); + return c.get >(); + } + fixed_bitstring<40>& set_n40() + { + set(types::n40); + return c.get >(); + } -// RRCSetup-IEs ::= SEQUENCE -struct rrc_setup_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - radio_bearer_cfg_s radio_bearer_cfg; - dyn_octstring master_cell_group; - dyn_octstring late_non_crit_ext; + private: + types type_; + choice_buffer_t > c; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + void destroy_(); + }; -// RRCReject ::= SEQUENCE -struct rrc_reject_s { - struct crit_exts_c_ { + // member variables + bool ext = false; + bool periodicity_and_pattern_present = false; + fixed_bitstring<275> res_blocks; + symbols_in_res_block_c_ symbols_in_res_block; + periodicity_and_pattern_c_ periodicity_and_pattern; + // ... + }; struct types_opts { - enum options { rrc_reject, crit_exts_future, nulltype } value; + enum options { bitmaps, ctrl_res_set, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } + pattern_type_c_() = default; + pattern_type_c_(const pattern_type_c_& other); + pattern_type_c_& operator=(const pattern_type_c_& other); + ~pattern_type_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - rrc_reject_ies_s& rrc_reject() + bitmaps_s_& bitmaps() { - assert_choice_type("rrcReject", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("bitmaps", type_.to_string(), "patternType"); + return c.get(); } - const rrc_reject_ies_s& rrc_reject() const + uint8_t& ctrl_res_set() { - assert_choice_type("rrcReject", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("controlResourceSet", type_.to_string(), "patternType"); + return c.get(); } - rrc_reject_ies_s& set_rrc_reject() + const bitmaps_s_& bitmaps() const { - set(types::rrc_reject); - return c.get(); + assert_choice_type("bitmaps", type_.to_string(), "patternType"); + return c.get(); } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - - // member variables - crit_exts_c_ crit_exts; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// RRCSetup ::= SEQUENCE -struct rrc_setup_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_setup, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_setup_ies_s& rrc_setup() + const uint8_t& ctrl_res_set() const { - assert_choice_type("rrcSetup", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("controlResourceSet", type_.to_string(), "patternType"); + return c.get(); } - const rrc_setup_ies_s& rrc_setup() const + bitmaps_s_& set_bitmaps() { - assert_choice_type("rrcSetup", type_.to_string(), "criticalExtensions"); - return c.get(); + set(types::bitmaps); + return c.get(); } - rrc_setup_ies_s& set_rrc_setup() + uint8_t& set_ctrl_res_set() { - set(types::rrc_setup); - return c.get(); + set(types::ctrl_res_set); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; + struct dummy_opts { + enum options { dynamic_value, semi_static, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated dummy_e_; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool ext = false; + bool subcarrier_spacing_present = false; + uint8_t rate_match_pattern_id = 0; + pattern_type_c_ pattern_type; + subcarrier_spacing_e subcarrier_spacing; + dummy_e_ dummy; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -14139,110 +12546,77 @@ struct rrc_setup_s { void to_json(json_writer& j) const; }; -// DL-CCCH-MessageType ::= CHOICE -struct dl_ccch_msg_type_c { - struct c1_c_ { - struct types_opts { - enum options { rrc_reject, rrc_setup, spare2, spare1, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - c1_c_() = default; - c1_c_(const c1_c_& other); - c1_c_& operator=(const c1_c_& other); - ~c1_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_reject_s& rrc_reject() - { - assert_choice_type("rrcReject", type_.to_string(), "c1"); - return c.get(); - } - rrc_setup_s& rrc_setup() - { - assert_choice_type("rrcSetup", type_.to_string(), "c1"); - return c.get(); - } - const rrc_reject_s& rrc_reject() const - { - assert_choice_type("rrcReject", type_.to_string(), "c1"); - return c.get(); - } - const rrc_setup_s& rrc_setup() const - { - assert_choice_type("rrcSetup", type_.to_string(), "c1"); - return c.get(); - } - rrc_reject_s& set_rrc_reject() - { - set(types::rrc_reject); - return c.get(); - } - rrc_setup_s& set_rrc_setup() - { - set(types::rrc_setup); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; +struct rate_match_pattern_group_item_c_ { struct types_opts { - enum options { c1, msg_class_ext, nulltype } value; - typedef uint8_t number_type; + enum options { cell_level, bwp_level, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; typedef enumerated types; // choice methods - dl_ccch_msg_type_c() = default; - dl_ccch_msg_type_c(const dl_ccch_msg_type_c& other); - dl_ccch_msg_type_c& operator=(const dl_ccch_msg_type_c& other); - ~dl_ccch_msg_type_c() { destroy_(); } + rate_match_pattern_group_item_c_() = default; + rate_match_pattern_group_item_c_(const rate_match_pattern_group_item_c_& other); + rate_match_pattern_group_item_c_& operator=(const rate_match_pattern_group_item_c_& other); + ~rate_match_pattern_group_item_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - c1_c_& c1() + uint8_t& cell_level() { - assert_choice_type("c1", type_.to_string(), "DL-CCCH-MessageType"); - return c.get(); + assert_choice_type("cellLevel", type_.to_string(), "RateMatchPatternGroup-item"); + return c.get(); } - const c1_c_& c1() const + uint8_t& bwp_level() { - assert_choice_type("c1", type_.to_string(), "DL-CCCH-MessageType"); - return c.get(); + assert_choice_type("bwpLevel", type_.to_string(), "RateMatchPatternGroup-item"); + return c.get(); } - c1_c_& set_c1() + const uint8_t& cell_level() const { - set(types::c1); - return c.get(); + assert_choice_type("cellLevel", type_.to_string(), "RateMatchPatternGroup-item"); + return c.get(); + } + const uint8_t& bwp_level() const + { + assert_choice_type("bwpLevel", type_.to_string(), "RateMatchPatternGroup-item"); + return c.get(); + } + uint8_t& set_cell_level() + { + set(types::cell_level); + return c.get(); + } + uint8_t& set_bwp_level() + { + set(types::bwp_level); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; -// DL-CCCH-Message ::= SEQUENCE -struct dl_ccch_msg_s { - dl_ccch_msg_type_c msg; +// RateMatchPatternGroup ::= SEQUENCE (SIZE (1..8)) OF RateMatchPatternGroup-item +using rate_match_pattern_group_l = dyn_array; + +// SRS-TPC-CommandConfig ::= SEQUENCE +struct srs_tpc_cmd_cfg_s { + bool ext = false; + bool start_bit_of_format2_minus3_present = false; + bool field_type_format2_minus3_present = false; + uint8_t start_bit_of_format2_minus3 = 1; + uint8_t field_type_format2_minus3 = 0; + // ... + // group 0 + bool start_bit_of_format2_minus3_sul_present = false; + uint8_t start_bit_of_format2_minus3_sul = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -14250,183 +12624,28 @@ struct dl_ccch_msg_s { void to_json(json_writer& j) const; }; -// CSI-RS-Resource-Mobility ::= SEQUENCE -struct csi_rs_res_mob_s { - struct slot_cfg_c_ { - struct types_opts { - enum options { ms4, ms5, ms10, ms20, ms40, nulltype } value; - typedef uint8_t number_type; +// TCI-State ::= SEQUENCE +struct tci_state_s { + bool ext = false; + bool qcl_type2_present = false; + uint8_t tci_state_id = 0; + qcl_info_s qcl_type1; + qcl_info_s qcl_type2; + // ... - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // choice methods - slot_cfg_c_() = default; - slot_cfg_c_(const slot_cfg_c_& other); - slot_cfg_c_& operator=(const slot_cfg_c_& other); - ~slot_cfg_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - uint8_t& ms4() - { - assert_choice_type("ms4", type_.to_string(), "slotConfig"); - return c.get(); - } - uint8_t& ms5() - { - assert_choice_type("ms5", type_.to_string(), "slotConfig"); - return c.get(); - } - uint8_t& ms10() - { - assert_choice_type("ms10", type_.to_string(), "slotConfig"); - return c.get(); - } - uint8_t& ms20() - { - assert_choice_type("ms20", type_.to_string(), "slotConfig"); - return c.get(); - } - uint16_t& ms40() - { - assert_choice_type("ms40", type_.to_string(), "slotConfig"); - return c.get(); - } - const uint8_t& ms4() const - { - assert_choice_type("ms4", type_.to_string(), "slotConfig"); - return c.get(); - } - const uint8_t& ms5() const - { - assert_choice_type("ms5", type_.to_string(), "slotConfig"); - return c.get(); - } - const uint8_t& ms10() const - { - assert_choice_type("ms10", type_.to_string(), "slotConfig"); - return c.get(); - } - const uint8_t& ms20() const - { - assert_choice_type("ms20", type_.to_string(), "slotConfig"); - return c.get(); - } - const uint16_t& ms40() const - { - assert_choice_type("ms40", type_.to_string(), "slotConfig"); - return c.get(); - } - uint8_t& set_ms4() - { - set(types::ms4); - return c.get(); - } - uint8_t& set_ms5() - { - set(types::ms5); - return c.get(); - } - uint8_t& set_ms10() - { - set(types::ms10); - return c.get(); - } - uint8_t& set_ms20() - { - set(types::ms20); - return c.get(); - } - uint16_t& set_ms40() - { - set(types::ms40); - return c.get(); - } - - private: - types type_; - pod_choice_buffer_t c; - - void destroy_(); - }; - struct associated_ssb_s_ { - uint8_t ssb_idx = 0; - bool is_quasi_colocated = false; - }; - struct freq_domain_alloc_c_ { - struct types_opts { - enum options { row1, row2, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; - - // choice methods - freq_domain_alloc_c_() = default; - freq_domain_alloc_c_(const freq_domain_alloc_c_& other); - freq_domain_alloc_c_& operator=(const freq_domain_alloc_c_& other); - ~freq_domain_alloc_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<4>& row1() - { - assert_choice_type("row1", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } - fixed_bitstring<12>& row2() - { - assert_choice_type("row2", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } - const fixed_bitstring<4>& row1() const - { - assert_choice_type("row1", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } - const fixed_bitstring<12>& row2() const - { - assert_choice_type("row2", type_.to_string(), "frequencyDomainAllocation"); - return c.get >(); - } - fixed_bitstring<4>& set_row1() - { - set(types::row1); - return c.get >(); - } - fixed_bitstring<12>& set_row2() - { - set(types::row2); - return c.get >(); - } - - private: - types type_; - choice_buffer_t > c; - - void destroy_(); - }; - - // member variables - bool ext = false; - bool associated_ssb_present = false; - uint8_t csi_rs_idx = 0; - slot_cfg_c_ slot_cfg; - associated_ssb_s_ associated_ssb; - freq_domain_alloc_c_ freq_domain_alloc; - uint8_t first_ofdm_symbol_in_time_domain = 0; - uint16_t seq_generation_cfg = 0; +// ZP-CSI-RS-Resource ::= SEQUENCE +struct zp_csi_rs_res_s { + bool ext = false; + bool periodicity_and_offset_present = false; + uint8_t zp_csi_rs_res_id = 0; + csi_rs_res_map_s res_map; + csi_res_periodicity_and_offset_c periodicity_and_offset; // ... // sequence methods @@ -14435,59 +12654,15 @@ struct csi_rs_res_mob_s { void to_json(json_writer& j) const; }; -// CSI-RS-CellMobility ::= SEQUENCE -struct csi_rs_cell_mob_s { - struct csi_rs_meas_bw_s_ { - struct nrof_prbs_opts { - enum options { size24, size48, size96, size192, size264, nulltype } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated nrof_prbs_e_; - - // member variables - nrof_prbs_e_ nrof_prbs; - uint16_t start_prb = 0; - }; - struct density_opts { - enum options { d1, d3, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated density_e_; - using csi_rs_res_list_mob_l_ = dyn_array; +// ZP-CSI-RS-ResourceSet ::= SEQUENCE +struct zp_csi_rs_res_set_s { + using zp_csi_rs_res_id_list_l_ = bounded_array; // member variables - bool density_present = false; - uint16_t cell_id = 0; - csi_rs_meas_bw_s_ csi_rs_meas_bw; - density_e_ density; - csi_rs_res_list_mob_l_ csi_rs_res_list_mob; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// Q-OffsetRangeList ::= SEQUENCE -struct q_offset_range_list_s { - bool rsrp_offset_ssb_present = false; - bool rsrq_offset_ssb_present = false; - bool sinr_offset_ssb_present = false; - bool rsrp_offset_csi_rs_present = false; - bool rsrq_offset_csi_rs_present = false; - bool sinr_offset_csi_rs_present = false; - q_offset_range_e rsrp_offset_ssb; - q_offset_range_e rsrq_offset_ssb; - q_offset_range_e sinr_offset_ssb; - q_offset_range_e rsrp_offset_csi_rs; - q_offset_range_e rsrq_offset_csi_rs; - q_offset_range_e sinr_offset_csi_rs; + bool ext = false; + uint8_t zp_csi_rs_res_set_id = 0; + zp_csi_rs_res_id_list_l_ zp_csi_rs_res_id_list; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -14495,18 +12670,32 @@ struct q_offset_range_list_s { void to_json(json_writer& j) const; }; -// CSI-RS-ResourceConfigMobility ::= SEQUENCE -struct csi_rs_res_cfg_mob_s { - using csi_rs_cell_list_mob_l_ = dyn_array; +// PDCCH-Config ::= SEQUENCE +struct pdcch_cfg_s { + using ctrl_res_set_to_add_mod_list_l_ = dyn_array; + using ctrl_res_set_to_release_list_l_ = bounded_array; + using search_spaces_to_add_mod_list_l_ = dyn_array; + using search_spaces_to_release_list_l_ = bounded_array; // member variables - bool ext = false; - subcarrier_spacing_e subcarrier_spacing; - csi_rs_cell_list_mob_l_ csi_rs_cell_list_mob; + bool ext = false; + bool ctrl_res_set_to_add_mod_list_present = false; + bool ctrl_res_set_to_release_list_present = false; + bool search_spaces_to_add_mod_list_present = false; + bool search_spaces_to_release_list_present = false; + bool dl_preemption_present = false; + bool tpc_pusch_present = false; + bool tpc_pucch_present = false; + bool tpc_srs_present = false; + ctrl_res_set_to_add_mod_list_l_ ctrl_res_set_to_add_mod_list; + ctrl_res_set_to_release_list_l_ ctrl_res_set_to_release_list; + search_spaces_to_add_mod_list_l_ search_spaces_to_add_mod_list; + search_spaces_to_release_list_l_ search_spaces_to_release_list; + setup_release_c dl_preemption; + setup_release_c tpc_pusch; + setup_release_c tpc_pucch; + setup_release_c tpc_srs; // ... - // group 0 - bool ref_serv_cell_idx_v1530_present = false; - uint8_t ref_serv_cell_idx_v1530 = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -14514,567 +12703,206 @@ struct csi_rs_res_cfg_mob_s { void to_json(json_writer& j) const; }; -// CellsToAddMod ::= SEQUENCE -struct cells_to_add_mod_s { - uint16_t pci = 0; - q_offset_range_list_s cell_individual_offset; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// FilterCoefficient ::= ENUMERATED -struct filt_coef_opts { - enum options { - fc0, - fc1, - fc2, - fc3, - fc4, - fc5, - fc6, - fc7, - fc8, - fc9, - fc11, - fc13, - fc15, - fc17, - fc19, - spare1, - /*...*/ nulltype - } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; -}; -typedef enumerated filt_coef_e; - -// MeasReportQuantity ::= SEQUENCE -struct meas_report_quant_s { - bool rsrp = false; - bool rsrq = false; - bool sinr = false; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// MeasTriggerQuantity ::= CHOICE -struct meas_trigger_quant_c { - struct types_opts { - enum options { rsrp, rsrq, sinr, nulltype } value; +// PDSCH-Config ::= SEQUENCE +struct pdsch_cfg_s { + using tci_states_to_add_mod_list_l_ = dyn_array; + using tci_states_to_release_list_l_ = dyn_array; + struct vrb_to_prb_interleaver_opts { + enum options { n2, n4, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated types; - - // choice methods - meas_trigger_quant_c() = default; - meas_trigger_quant_c(const meas_trigger_quant_c& other); - meas_trigger_quant_c& operator=(const meas_trigger_quant_c& other); - ~meas_trigger_quant_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - uint8_t& rsrp() - { - assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantity"); - return c.get(); - } - uint8_t& rsrq() - { - assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantity"); - return c.get(); - } - uint8_t& sinr() - { - assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantity"); - return c.get(); - } - const uint8_t& rsrp() const - { - assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantity"); - return c.get(); - } - const uint8_t& rsrq() const - { - assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantity"); - return c.get(); - } - const uint8_t& sinr() const - { - assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantity"); - return c.get(); - } - uint8_t& set_rsrp() - { - set(types::rsrp); - return c.get(); - } - uint8_t& set_rsrq() - { - set(types::rsrq); - return c.get(); - } - uint8_t& set_sinr() - { - set(types::sinr); - return c.get(); - } + typedef enumerated vrb_to_prb_interleaver_e_; + struct res_alloc_opts { + enum options { res_alloc_type0, res_alloc_type1, dynamic_switch, nulltype } value; + typedef uint8_t number_type; -private: - types type_; - pod_choice_buffer_t c; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated res_alloc_e_; + struct pdsch_aggregation_factor_opts { + enum options { n2, n4, n8, nulltype } value; + typedef uint8_t number_type; - void destroy_(); -}; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated pdsch_aggregation_factor_e_; + using rate_match_pattern_to_add_mod_list_l_ = dyn_array; + using rate_match_pattern_to_release_list_l_ = bounded_array; + struct rbg_size_opts { + enum options { cfg1, cfg2, nulltype } value; + typedef uint8_t number_type; -// MeasTriggerQuantityEUTRA ::= CHOICE -struct meas_trigger_quant_eutra_c { - struct types_opts { - enum options { rsrp, rsrq, sinr, nulltype } value; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated rbg_size_e_; + struct mcs_table_opts { + enum options { qam256, qam64_low_se, nulltype } value; + typedef uint16_t number_type; std::string to_string() const; + uint16_t to_number() const; }; - typedef enumerated types; + typedef enumerated mcs_table_e_; + struct max_nrof_code_words_sched_by_dci_opts { + enum options { n1, n2, nulltype } value; + typedef uint8_t number_type; - // choice methods - meas_trigger_quant_eutra_c() = default; - meas_trigger_quant_eutra_c(const meas_trigger_quant_eutra_c& other); - meas_trigger_quant_eutra_c& operator=(const meas_trigger_quant_eutra_c& other); - ~meas_trigger_quant_eutra_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - uint8_t& rsrp() - { - assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityEUTRA"); - return c.get(); - } - uint8_t& rsrq() - { - assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityEUTRA"); - return c.get(); - } - uint8_t& sinr() - { - assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityEUTRA"); - return c.get(); - } - const uint8_t& rsrp() const - { - assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityEUTRA"); - return c.get(); - } - const uint8_t& rsrq() const - { - assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityEUTRA"); - return c.get(); - } - const uint8_t& sinr() const - { - assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityEUTRA"); - return c.get(); - } - uint8_t& set_rsrp() - { - set(types::rsrp); - return c.get(); - } - uint8_t& set_rsrq() - { - set(types::rsrq); - return c.get(); - } - uint8_t& set_sinr() - { - set(types::sinr); - return c.get(); - } + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_nrof_code_words_sched_by_dci_e_; + struct prb_bundling_type_c_ { + struct static_bundling_s_ { + struct bundle_size_opts { + enum options { n4, wideband, nulltype } value; + typedef uint8_t number_type; -private: - types type_; - pod_choice_buffer_t c; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated bundle_size_e_; - void destroy_(); -}; + // member variables + bool bundle_size_present = false; + bundle_size_e_ bundle_size; + }; + struct dynamic_bundling_s_ { + struct bundle_size_set1_opts { + enum options { n4, wideband, n2_wideband, n4_wideband, nulltype } value; -// MeasTriggerQuantityOffset ::= CHOICE -struct meas_trigger_quant_offset_c { - struct types_opts { - enum options { rsrp, rsrq, sinr, nulltype } value; + std::string to_string() const; + }; + typedef enumerated bundle_size_set1_e_; + struct bundle_size_set2_opts { + enum options { n4, wideband, nulltype } value; + typedef uint8_t number_type; - std::string to_string() const; - }; - typedef enumerated types; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated bundle_size_set2_e_; - // choice methods - meas_trigger_quant_offset_c() = default; - meas_trigger_quant_offset_c(const meas_trigger_quant_offset_c& other); - meas_trigger_quant_offset_c& operator=(const meas_trigger_quant_offset_c& other); - ~meas_trigger_quant_offset_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - int8_t& rsrp() - { - assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityOffset"); - return c.get(); - } - int8_t& rsrq() - { - assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityOffset"); - return c.get(); - } - int8_t& sinr() - { - assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityOffset"); - return c.get(); - } - const int8_t& rsrp() const - { - assert_choice_type("rsrp", type_.to_string(), "MeasTriggerQuantityOffset"); - return c.get(); - } - const int8_t& rsrq() const - { - assert_choice_type("rsrq", type_.to_string(), "MeasTriggerQuantityOffset"); - return c.get(); - } - const int8_t& sinr() const - { - assert_choice_type("sinr", type_.to_string(), "MeasTriggerQuantityOffset"); - return c.get(); - } - int8_t& set_rsrp() - { - set(types::rsrp); - return c.get(); - } - int8_t& set_rsrq() - { - set(types::rsrq); - return c.get(); - } - int8_t& set_sinr() - { - set(types::sinr); - return c.get(); - } - -private: - types type_; - pod_choice_buffer_t c; - - void destroy_(); -}; - -// NR-RS-Type ::= ENUMERATED -struct nr_rs_type_opts { - enum options { ssb, csi_rs, nulltype } value; - - std::string to_string() const; -}; -typedef enumerated nr_rs_type_e; - -// ReportInterval ::= ENUMERATED -struct report_interv_opts { - enum options { - ms120, - ms240, - ms480, - ms640, - ms1024, - ms2048, - ms5120, - ms10240, - ms20480, - ms40960, - min1, - min6, - min12, - min30, - nulltype - } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; -}; -typedef enumerated report_interv_e; - -// SSB-ConfigMobility ::= SEQUENCE -struct ssb_cfg_mob_s { - bool ext = false; - bool ssb_to_measure_present = false; - bool ss_rssi_meas_present = false; - setup_release_c ssb_to_measure; - bool derive_ssb_idx_from_cell = false; - ss_rssi_meas_s ss_rssi_meas; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// TimeToTrigger ::= ENUMERATED -struct time_to_trigger_opts { - enum options { - ms0, - ms40, - ms64, - ms80, - ms100, - ms128, - ms160, - ms256, - ms320, - ms480, - ms512, - ms640, - ms1024, - ms1280, - ms2560, - ms5120, - nulltype - } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; -}; -typedef enumerated time_to_trigger_e; - -// CellsToAddModList ::= SEQUENCE (SIZE (1..32)) OF CellsToAddMod -using cells_to_add_mod_list_l = dyn_array; - -// EUTRA-BlackCell ::= SEQUENCE -struct eutra_black_cell_s { - uint8_t cell_idx_eutra = 1; - eutra_pci_range_s pci_range; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// EUTRA-Cell ::= SEQUENCE -struct eutra_cell_s { - uint8_t cell_idx_eutra = 1; - uint16_t pci = 0; - eutra_q_offset_range_e cell_individual_offset; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// EUTRA-CellIndexList ::= SEQUENCE (SIZE (1..32)) OF INTEGER (1..32) -using eutra_cell_idx_list_l = bounded_array; - -// EventTriggerConfig ::= SEQUENCE -struct event_trigger_cfg_s { - struct event_id_c_ { - struct event_a1_s_ { - meas_trigger_quant_c a1_thres; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - }; - struct event_a2_s_ { - meas_trigger_quant_c a2_thres; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - }; - struct event_a3_s_ { - meas_trigger_quant_offset_c a3_offset; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - bool use_white_cell_list = false; - }; - struct event_a4_s_ { - meas_trigger_quant_c a4_thres; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - bool use_white_cell_list = false; - }; - struct event_a5_s_ { - meas_trigger_quant_c a5_thres1; - meas_trigger_quant_c a5_thres2; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - bool use_white_cell_list = false; - }; - struct event_a6_s_ { - meas_trigger_quant_offset_c a6_offset; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - bool use_white_cell_list = false; + // member variables + bool bundle_size_set1_present = false; + bool bundle_size_set2_present = false; + bundle_size_set1_e_ bundle_size_set1; + bundle_size_set2_e_ bundle_size_set2; }; struct types_opts { - enum options { event_a1, event_a2, event_a3, event_a4, event_a5, event_a6, /*...*/ nulltype } value; - typedef uint8_t number_type; + enum options { static_bundling, dynamic_bundling, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - event_id_c_() = default; - event_id_c_(const event_id_c_& other); - event_id_c_& operator=(const event_id_c_& other); - ~event_id_c_() { destroy_(); } + prb_bundling_type_c_() = default; + prb_bundling_type_c_(const prb_bundling_type_c_& other); + prb_bundling_type_c_& operator=(const prb_bundling_type_c_& other); + ~prb_bundling_type_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - event_a1_s_& event_a1() + static_bundling_s_& static_bundling() { - assert_choice_type("eventA1", type_.to_string(), "eventId"); - return c.get(); + assert_choice_type("staticBundling", type_.to_string(), "prb-BundlingType"); + return c.get(); } - event_a2_s_& event_a2() + dynamic_bundling_s_& dynamic_bundling() { - assert_choice_type("eventA2", type_.to_string(), "eventId"); - return c.get(); + assert_choice_type("dynamicBundling", type_.to_string(), "prb-BundlingType"); + return c.get(); } - event_a3_s_& event_a3() + const static_bundling_s_& static_bundling() const { - assert_choice_type("eventA3", type_.to_string(), "eventId"); - return c.get(); + assert_choice_type("staticBundling", type_.to_string(), "prb-BundlingType"); + return c.get(); } - event_a4_s_& event_a4() + const dynamic_bundling_s_& dynamic_bundling() const { - assert_choice_type("eventA4", type_.to_string(), "eventId"); - return c.get(); + assert_choice_type("dynamicBundling", type_.to_string(), "prb-BundlingType"); + return c.get(); } - event_a5_s_& event_a5() + static_bundling_s_& set_static_bundling() { - assert_choice_type("eventA5", type_.to_string(), "eventId"); - return c.get(); - } - event_a6_s_& event_a6() - { - assert_choice_type("eventA6", type_.to_string(), "eventId"); - return c.get(); - } - const event_a1_s_& event_a1() const - { - assert_choice_type("eventA1", type_.to_string(), "eventId"); - return c.get(); - } - const event_a2_s_& event_a2() const - { - assert_choice_type("eventA2", type_.to_string(), "eventId"); - return c.get(); - } - const event_a3_s_& event_a3() const - { - assert_choice_type("eventA3", type_.to_string(), "eventId"); - return c.get(); - } - const event_a4_s_& event_a4() const - { - assert_choice_type("eventA4", type_.to_string(), "eventId"); - return c.get(); - } - const event_a5_s_& event_a5() const - { - assert_choice_type("eventA5", type_.to_string(), "eventId"); - return c.get(); - } - const event_a6_s_& event_a6() const - { - assert_choice_type("eventA6", type_.to_string(), "eventId"); - return c.get(); - } - event_a1_s_& set_event_a1() - { - set(types::event_a1); - return c.get(); - } - event_a2_s_& set_event_a2() - { - set(types::event_a2); - return c.get(); - } - event_a3_s_& set_event_a3() - { - set(types::event_a3); - return c.get(); - } - event_a4_s_& set_event_a4() - { - set(types::event_a4); - return c.get(); - } - event_a5_s_& set_event_a5() - { - set(types::event_a5); - return c.get(); + set(types::static_bundling); + return c.get(); } - event_a6_s_& set_event_a6() + dynamic_bundling_s_& set_dynamic_bundling() { - set(types::event_a6); - return c.get(); + set(types::dynamic_bundling); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct report_amount_opts { - enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; - typedef int8_t number_type; - - std::string to_string() const; - int8_t to_number() const; - }; - typedef enumerated report_amount_e_; + using zp_csi_rs_res_to_add_mod_list_l_ = dyn_array; + using zp_csi_rs_res_to_release_list_l_ = bounded_array; + using aperiodic_zp_csi_rs_res_sets_to_add_mod_list_l_ = dyn_array; + using aperiodic_zp_csi_rs_res_sets_to_release_list_l_ = bounded_array; + using sp_zp_csi_rs_res_sets_to_add_mod_list_l_ = dyn_array; + using sp_zp_csi_rs_res_sets_to_release_list_l_ = bounded_array; // member variables - bool ext = false; - bool report_quant_rs_idxes_present = false; - bool max_nrof_rs_idxes_to_report_present = false; - bool report_add_neigh_meas_present = false; - event_id_c_ event_id; - nr_rs_type_e rs_type; - report_interv_e report_interv; - report_amount_e_ report_amount; - meas_report_quant_s report_quant_cell; - uint8_t max_report_cells = 1; - meas_report_quant_s report_quant_rs_idxes; - uint8_t max_nrof_rs_idxes_to_report = 1; - bool include_beam_meass = false; + bool ext = false; + bool data_scrambling_id_pdsch_present = false; + bool dmrs_dl_for_pdsch_map_type_a_present = false; + bool dmrs_dl_for_pdsch_map_type_b_present = false; + bool tci_states_to_add_mod_list_present = false; + bool tci_states_to_release_list_present = false; + bool vrb_to_prb_interleaver_present = false; + bool pdsch_time_domain_alloc_list_present = false; + bool pdsch_aggregation_factor_present = false; + bool rate_match_pattern_to_add_mod_list_present = false; + bool rate_match_pattern_to_release_list_present = false; + bool rate_match_pattern_group1_present = false; + bool rate_match_pattern_group2_present = false; + bool mcs_table_present = false; + bool max_nrof_code_words_sched_by_dci_present = false; + bool zp_csi_rs_res_to_add_mod_list_present = false; + bool zp_csi_rs_res_to_release_list_present = false; + bool aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present = false; + bool aperiodic_zp_csi_rs_res_sets_to_release_list_present = false; + bool sp_zp_csi_rs_res_sets_to_add_mod_list_present = false; + bool sp_zp_csi_rs_res_sets_to_release_list_present = false; + bool p_zp_csi_rs_res_set_present = false; + uint16_t data_scrambling_id_pdsch = 0; + setup_release_c dmrs_dl_for_pdsch_map_type_a; + setup_release_c dmrs_dl_for_pdsch_map_type_b; + tci_states_to_add_mod_list_l_ tci_states_to_add_mod_list; + tci_states_to_release_list_l_ tci_states_to_release_list; + vrb_to_prb_interleaver_e_ vrb_to_prb_interleaver; + res_alloc_e_ res_alloc; + setup_release_c > pdsch_time_domain_alloc_list; + pdsch_aggregation_factor_e_ pdsch_aggregation_factor; + rate_match_pattern_to_add_mod_list_l_ rate_match_pattern_to_add_mod_list; + rate_match_pattern_to_release_list_l_ rate_match_pattern_to_release_list; + rate_match_pattern_group_l rate_match_pattern_group1; + rate_match_pattern_group_l rate_match_pattern_group2; + rbg_size_e_ rbg_size; + mcs_table_e_ mcs_table; + max_nrof_code_words_sched_by_dci_e_ max_nrof_code_words_sched_by_dci; + prb_bundling_type_c_ prb_bundling_type; + zp_csi_rs_res_to_add_mod_list_l_ zp_csi_rs_res_to_add_mod_list; + zp_csi_rs_res_to_release_list_l_ zp_csi_rs_res_to_release_list; + aperiodic_zp_csi_rs_res_sets_to_add_mod_list_l_ aperiodic_zp_csi_rs_res_sets_to_add_mod_list; + aperiodic_zp_csi_rs_res_sets_to_release_list_l_ aperiodic_zp_csi_rs_res_sets_to_release_list; + sp_zp_csi_rs_res_sets_to_add_mod_list_l_ sp_zp_csi_rs_res_sets_to_add_mod_list; + sp_zp_csi_rs_res_sets_to_release_list_l_ sp_zp_csi_rs_res_sets_to_release_list; + setup_release_c p_zp_csi_rs_res_set; // ... // sequence methods @@ -15083,130 +12911,38 @@ struct event_trigger_cfg_s { void to_json(json_writer& j) const; }; -// EventTriggerConfigInterRAT ::= SEQUENCE -struct event_trigger_cfg_inter_rat_s { - struct event_id_c_ { - struct event_b1_s_ { - bool ext = false; - meas_trigger_quant_eutra_c b1_thres_eutra; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - // ... - }; - struct event_b2_s_ { - bool ext = false; - meas_trigger_quant_c b2_thres1; - meas_trigger_quant_eutra_c b2_thres2_eutra; - bool report_on_leave = false; - uint8_t hysteresis = 0; - time_to_trigger_e time_to_trigger; - // ... - }; - struct types_opts { - enum options { event_b1, event_b2, /*...*/ nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; - - // choice methods - event_id_c_() = default; - event_id_c_(const event_id_c_& other); - event_id_c_& operator=(const event_id_c_& other); - ~event_id_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - event_b1_s_& event_b1() - { - assert_choice_type("eventB1", type_.to_string(), "eventId"); - return c.get(); - } - event_b2_s_& event_b2() - { - assert_choice_type("eventB2", type_.to_string(), "eventId"); - return c.get(); - } - const event_b1_s_& event_b1() const - { - assert_choice_type("eventB1", type_.to_string(), "eventId"); - return c.get(); - } - const event_b2_s_& event_b2() const - { - assert_choice_type("eventB2", type_.to_string(), "eventId"); - return c.get(); - } - event_b1_s_& set_event_b1() - { - set(types::event_b1); - return c.get(); - } - event_b2_s_& set_event_b2() - { - set(types::event_b2); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; +// RadioLinkMonitoringConfig ::= SEQUENCE +struct radio_link_monitoring_cfg_s { + using fail_detection_res_to_add_mod_list_l_ = dyn_array; + using fail_detection_res_to_release_list_l_ = bounded_array; + struct beam_fail_instance_max_count_opts { + enum options { n1, n2, n3, n4, n5, n6, n8, n10, nulltype } value; + typedef uint8_t number_type; - void destroy_(); + std::string to_string() const; + uint8_t to_number() const; }; - struct report_amount_opts { - enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; - typedef int8_t number_type; + typedef enumerated beam_fail_instance_max_count_e_; + struct beam_fail_detection_timer_opts { + enum options { pbfd1, pbfd2, pbfd3, pbfd4, pbfd5, pbfd6, pbfd8, pbfd10, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; - int8_t to_number() const; + uint8_t to_number() const; }; - typedef enumerated report_amount_e_; + typedef enumerated beam_fail_detection_timer_e_; // member variables - bool ext = false; - event_id_c_ event_id; - nr_rs_type_e rs_type; - report_interv_e report_interv; - report_amount_e_ report_amount; - meas_report_quant_s report_quant; - uint8_t max_report_cells = 1; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// FilterConfig ::= SEQUENCE -struct filt_cfg_s { - bool filt_coef_rsrp_present = false; - bool filt_coef_rsrq_present = false; - bool filt_coef_rs_sinr_present = false; - filt_coef_e filt_coef_rsrp; - filt_coef_e filt_coef_rsrq; - filt_coef_e filt_coef_rs_sinr; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PCI-List ::= SEQUENCE (SIZE (1..32)) OF INTEGER (0..1007) -using pci_list_l = bounded_array; - -// PCI-RangeElement ::= SEQUENCE -struct pci_range_elem_s { - uint8_t pci_range_idx = 1; - pci_range_s pci_range; + bool ext = false; + bool fail_detection_res_to_add_mod_list_present = false; + bool fail_detection_res_to_release_list_present = false; + bool beam_fail_instance_max_count_present = false; + bool beam_fail_detection_timer_present = false; + fail_detection_res_to_add_mod_list_l_ fail_detection_res_to_add_mod_list; + fail_detection_res_to_release_list_l_ fail_detection_res_to_release_list; + beam_fail_instance_max_count_e_ beam_fail_instance_max_count; + beam_fail_detection_timer_e_ beam_fail_detection_timer; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15214,33 +12950,42 @@ struct pci_range_elem_s { void to_json(json_writer& j) const; }; -// PCI-RangeIndexList ::= SEQUENCE (SIZE (1..8)) OF INTEGER (1..8) -using pci_range_idx_list_l = bounded_array; - -// PeriodicalReportConfig ::= SEQUENCE -struct periodical_report_cfg_s { - struct report_amount_opts { - enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; - typedef int8_t number_type; +// SPS-Config ::= SEQUENCE +struct sps_cfg_s { + struct periodicity_opts { + enum options { + ms10, + ms20, + ms32, + ms40, + ms64, + ms80, + ms128, + ms160, + ms320, + ms640, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; std::string to_string() const; - int8_t to_number() const; + uint16_t to_number() const; }; - typedef enumerated report_amount_e_; + typedef enumerated periodicity_e_; // member variables - bool ext = false; - bool report_quant_rs_idxes_present = false; - bool max_nrof_rs_idxes_to_report_present = false; - nr_rs_type_e rs_type; - report_interv_e report_interv; - report_amount_e_ report_amount; - meas_report_quant_s report_quant_cell; - uint8_t max_report_cells = 1; - meas_report_quant_s report_quant_rs_idxes; - uint8_t max_nrof_rs_idxes_to_report = 1; - bool include_beam_meass = false; - bool use_white_cell_list = false; + bool ext = false; + bool n1_pucch_an_present = false; + bool mcs_table_present = false; + periodicity_e_ periodicity; + uint8_t nrof_harq_processes = 1; + uint8_t n1_pucch_an = 0; // ... // sequence methods @@ -15249,23 +12994,17 @@ struct periodical_report_cfg_s { void to_json(json_writer& j) const; }; -// PeriodicalReportConfigInterRAT ::= SEQUENCE -struct periodical_report_cfg_inter_rat_s { - struct report_amount_opts { - enum options { r1, r2, r4, r8, r16, r32, r64, infinity, nulltype } value; - typedef int8_t number_type; - - std::string to_string() const; - int8_t to_number() const; - }; - typedef enumerated report_amount_e_; - - // member variables - bool ext = false; - report_interv_e report_interv; - report_amount_e_ report_amount; - meas_report_quant_s report_quant; - uint8_t max_report_cells = 1; +// BWP-DownlinkDedicated ::= SEQUENCE +struct bwp_dl_ded_s { + bool ext = false; + bool pdcch_cfg_present = false; + bool pdsch_cfg_present = false; + bool sps_cfg_present = false; + bool radio_link_monitoring_cfg_present = false; + setup_release_c pdcch_cfg; + setup_release_c pdsch_cfg; + setup_release_c sps_cfg; + setup_release_c radio_link_monitoring_cfg; // ... // sequence methods @@ -15274,14 +13013,15 @@ struct periodical_report_cfg_inter_rat_s { void to_json(json_writer& j) const; }; -// RAN-AreaConfig ::= SEQUENCE -struct ran_area_cfg_s { - using ran_area_code_list_l_ = bounded_array; - - // member variables - bool ran_area_code_list_present = false; - fixed_bitstring<24> tac; - ran_area_code_list_l_ ran_area_code_list; +// BWP-Downlink ::= SEQUENCE +struct bwp_dl_s { + bool ext = false; + bool bwp_common_present = false; + bool bwp_ded_present = false; + uint8_t bwp_id = 0; + bwp_dl_common_s bwp_common; + bwp_dl_ded_s bwp_ded; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15289,12 +13029,33 @@ struct ran_area_cfg_s { void to_json(json_writer& j) const; }; -// ReferenceSignalConfig ::= SEQUENCE -struct ref_sig_cfg_s { - bool ssb_cfg_mob_present = false; - bool csi_rs_res_cfg_mob_present = false; - ssb_cfg_mob_s ssb_cfg_mob; - setup_release_c csi_rs_res_cfg_mob; +// Alpha ::= ENUMERATED +struct alpha_opts { + enum options { alpha0, alpha04, alpha05, alpha06, alpha07, alpha08, alpha09, alpha1, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; +}; +typedef enumerated alpha_e; + +// BetaOffsets ::= SEQUENCE +struct beta_offsets_s { + bool beta_offset_ack_idx1_present = false; + bool beta_offset_ack_idx2_present = false; + bool beta_offset_ack_idx3_present = false; + bool beta_offset_csi_part1_idx1_present = false; + bool beta_offset_csi_part1_idx2_present = false; + bool beta_offset_csi_part2_idx1_present = false; + bool beta_offset_csi_part2_idx2_present = false; + uint8_t beta_offset_ack_idx1 = 0; + uint8_t beta_offset_ack_idx2 = 0; + uint8_t beta_offset_ack_idx3 = 0; + uint8_t beta_offset_csi_part1_idx1 = 0; + uint8_t beta_offset_csi_part1_idx2 = 0; + uint8_t beta_offset_csi_part2_idx1 = 0; + uint8_t beta_offset_csi_part2_idx2 = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15302,11 +13063,10 @@ struct ref_sig_cfg_s { void to_json(json_writer& j) const; }; -// ReportCGI ::= SEQUENCE -struct report_cgi_s { - bool ext = false; - uint16_t cell_for_which_to_report_cgi = 0; - // ... +// P0-PUCCH ::= SEQUENCE +struct p0_pucch_s { + uint8_t p0_pucch_id = 1; + int8_t p0_pucch_value = -16; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15314,11 +13074,13 @@ struct report_cgi_s { void to_json(json_writer& j) const; }; -// ReportCGI-EUTRA ::= SEQUENCE -struct report_cgi_eutra_s { - bool ext = false; - uint16_t cell_for_which_to_report_cgi = 0; - // ... +// P0-PUSCH-AlphaSet ::= SEQUENCE +struct p0_pusch_alpha_set_s { + bool p0_present = false; + bool alpha_present = false; + uint8_t p0_pusch_alpha_set_id = 0; + int8_t p0 = -16; + alpha_e alpha; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15326,22 +13088,63 @@ struct report_cgi_eutra_s { void to_json(json_writer& j) const; }; -// SSB-MTC2 ::= SEQUENCE -struct ssb_mtc2_s { - using pci_list_l_ = dyn_array; - struct periodicity_opts { - enum options { sf5, sf10, sf20, sf40, sf80, spare3, spare2, spare1, nulltype } value; - typedef uint8_t number_type; +// PTRS-UplinkConfig ::= SEQUENCE +struct ptrs_ul_cfg_s { + struct transform_precoder_disabled_s_ { + using freq_density_l_ = std::array; + using time_density_l_ = std::array; + struct max_nrof_ports_opts { + enum options { n1, n2, nulltype } value; + typedef uint8_t number_type; - std::string to_string() const; - uint8_t to_number() const; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_nrof_ports_e_; + struct res_elem_offset_opts { + enum options { offset01, offset10, offset11, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated res_elem_offset_e_; + struct ptrs_pwr_opts { + enum options { p00, p01, p10, p11, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated ptrs_pwr_e_; + + // member variables + bool freq_density_present = false; + bool time_density_present = false; + bool res_elem_offset_present = false; + freq_density_l_ freq_density; + time_density_l_ time_density; + max_nrof_ports_e_ max_nrof_ports; + res_elem_offset_e_ res_elem_offset; + ptrs_pwr_e_ ptrs_pwr; + }; + struct transform_precoder_enabled_s_ { + using sample_density_l_ = std::array; + + // member variables + bool time_density_transform_precoding_present = false; + sample_density_l_ sample_density; }; - typedef enumerated periodicity_e_; // member variables - bool pci_list_present = false; - pci_list_l_ pci_list; - periodicity_e_ periodicity; + bool ext = false; + bool transform_precoder_disabled_present = false; + bool transform_precoder_enabled_present = false; + transform_precoder_disabled_s_ transform_precoder_disabled; + transform_precoder_enabled_s_ transform_precoder_enabled; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15349,89 +13152,79 @@ struct ssb_mtc2_s { void to_json(json_writer& j) const; }; -// MeasObjectEUTRA ::= SEQUENCE -struct meas_obj_eutra_s { - using cells_to_add_mod_list_eutran_l_ = dyn_array; - using black_cells_to_add_mod_list_eutran_l_ = dyn_array; - - // member variables - bool ext = false; - bool cells_to_rem_list_eutran_present = false; - bool cells_to_add_mod_list_eutran_present = false; - bool black_cells_to_rem_list_eutran_present = false; - bool black_cells_to_add_mod_list_eutran_present = false; - bool eutra_q_offset_range_present = false; - uint32_t carrier_freq = 0; - eutra_allowed_meas_bw_e allowed_meas_bw; - eutra_cell_idx_list_l cells_to_rem_list_eutran; - cells_to_add_mod_list_eutran_l_ cells_to_add_mod_list_eutran; - eutra_cell_idx_list_l black_cells_to_rem_list_eutran; - black_cells_to_add_mod_list_eutran_l_ black_cells_to_add_mod_list_eutran; - bool eutra_presence_ant_port1 = false; - eutra_q_offset_range_e eutra_q_offset_range; - bool wideband_rsrq_meas = false; - // ... +// PUCCH-MaxCodeRate ::= ENUMERATED +struct pucch_max_code_rate_opts { + enum options { zero_dot08, zero_dot15, zero_dot25, zero_dot35, zero_dot45, zero_dot60, zero_dot80, nulltype } value; + typedef float number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; }; +typedef enumerated pucch_max_code_rate_e; -// MeasObjectNR ::= SEQUENCE -struct meas_obj_nr_s { - using black_cells_to_add_mod_list_l_ = dyn_array; - using white_cells_to_add_mod_list_l_ = dyn_array; - struct meas_cycle_scell_v1530_opts { - enum options { sf160, sf256, sf320, sf512, sf640, sf1024, sf1280, nulltype } value; - typedef uint16_t number_type; +// PUCCH-PathlossReferenceRS ::= SEQUENCE +struct pucch_pathloss_ref_rs_s { + struct ref_sig_c_ { + struct types_opts { + enum options { ssb_idx, csi_rs_idx, nulltype } value; - std::string to_string() const; - uint16_t to_number() const; + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + ref_sig_c_() = default; + ref_sig_c_(const ref_sig_c_& other); + ref_sig_c_& operator=(const ref_sig_c_& other); + ~ref_sig_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + uint8_t& ssb_idx() + { + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + uint8_t& csi_rs_idx() + { + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + const uint8_t& ssb_idx() const + { + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + const uint8_t& csi_rs_idx() const + { + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + uint8_t& set_ssb_idx() + { + set(types::ssb_idx); + return c.get(); + } + uint8_t& set_csi_rs_idx() + { + set(types::csi_rs_idx); + return c.get(); + } + + private: + types type_; + pod_choice_buffer_t c; + + void destroy_(); }; - typedef enumerated meas_cycle_scell_v1530_e_; // member variables - bool ext = false; - bool ssb_freq_present = false; - bool ssb_subcarrier_spacing_present = false; - bool smtc1_present = false; - bool smtc2_present = false; - bool ref_freq_csi_rs_present = false; - bool abs_thresh_ss_blocks_consolidation_present = false; - bool abs_thresh_csi_rs_consolidation_present = false; - bool nrof_ss_blocks_to_average_present = false; - bool nrof_csi_rs_res_to_average_present = false; - bool cells_to_rem_list_present = false; - bool cells_to_add_mod_list_present = false; - bool black_cells_to_rem_list_present = false; - bool black_cells_to_add_mod_list_present = false; - bool white_cells_to_rem_list_present = false; - bool white_cells_to_add_mod_list_present = false; - uint32_t ssb_freq = 0; - subcarrier_spacing_e ssb_subcarrier_spacing; - ssb_mtc_s smtc1; - ssb_mtc2_s smtc2; - uint32_t ref_freq_csi_rs = 0; - ref_sig_cfg_s ref_sig_cfg; - thres_nr_s abs_thresh_ss_blocks_consolidation; - thres_nr_s abs_thresh_csi_rs_consolidation; - uint8_t nrof_ss_blocks_to_average = 2; - uint8_t nrof_csi_rs_res_to_average = 2; - uint8_t quant_cfg_idx = 1; - q_offset_range_list_s offset_mo; - pci_list_l cells_to_rem_list; - cells_to_add_mod_list_l cells_to_add_mod_list; - pci_range_idx_list_l black_cells_to_rem_list; - black_cells_to_add_mod_list_l_ black_cells_to_add_mod_list; - pci_range_idx_list_l white_cells_to_rem_list; - white_cells_to_add_mod_list_l_ white_cells_to_add_mod_list; - // ... - // group 0 - bool freq_band_ind_nr_v1530_present = false; - bool meas_cycle_scell_v1530_present = false; - uint16_t freq_band_ind_nr_v1530 = 1; - meas_cycle_scell_v1530_e_ meas_cycle_scell_v1530; + uint8_t pucch_pathloss_ref_rs_id = 0; + ref_sig_c_ ref_sig; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15439,38 +13232,24 @@ struct meas_obj_nr_s { void to_json(json_writer& j) const; }; -// OverheatingAssistanceConfig ::= SEQUENCE -struct overheat_assist_cfg_s { - struct overheat_ind_prohibit_timer_opts { - enum options { - s0, - s0dot5, - s1, - s2, - s5, - s10, - s20, - s30, - s60, - s90, - s120, - s300, - s600, - spare3, - spare2, - spare1, - nulltype - } value; - typedef float number_type; +// PUCCH-format0 ::= SEQUENCE +struct pucch_format0_s { + uint8_t init_cyclic_shift = 0; + uint8_t nrof_symbols = 1; + uint8_t start_symbol_idx = 0; - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated overheat_ind_prohibit_timer_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - overheat_ind_prohibit_timer_e_ overheat_ind_prohibit_timer; +// PUCCH-format1 ::= SEQUENCE +struct pucch_format1_s { + uint8_t init_cyclic_shift = 0; + uint8_t nrof_symbols = 4; + uint8_t start_symbol_idx = 0; + uint8_t time_domain_occ = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15478,14 +13257,11 @@ struct overheat_assist_cfg_s { void to_json(json_writer& j) const; }; -// PLMN-RAN-AreaCell ::= SEQUENCE -struct plmn_ran_area_cell_s { - using ran_area_cells_l_ = bounded_array, 32>; - - // member variables - bool plmn_id_present = false; - plmn_id_s plmn_id; - ran_area_cells_l_ ran_area_cells; +// PUCCH-format2 ::= SEQUENCE +struct pucch_format2_s { + uint8_t nrof_prbs = 1; + uint8_t nrof_symbols = 1; + uint8_t start_symbol_idx = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15493,14 +13269,11 @@ struct plmn_ran_area_cell_s { void to_json(json_writer& j) const; }; -// PLMN-RAN-AreaConfig ::= SEQUENCE -struct plmn_ran_area_cfg_s { - using ran_area_l_ = dyn_array; - - // member variables - bool plmn_id_present = false; - plmn_id_s plmn_id; - ran_area_l_ ran_area; +// PUCCH-format3 ::= SEQUENCE +struct pucch_format3_s { + uint8_t nrof_prbs = 1; + uint8_t nrof_symbols = 4; + uint8_t start_symbol_idx = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15508,10 +13281,30 @@ struct plmn_ran_area_cfg_s { void to_json(json_writer& j) const; }; -// QuantityConfigRS ::= SEQUENCE -struct quant_cfg_rs_s { - filt_cfg_s ssb_filt_cfg; - filt_cfg_s csi_rs_filt_cfg; +// PUCCH-format4 ::= SEQUENCE +struct pucch_format4_s { + struct occ_len_opts { + enum options { n2, n4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated occ_len_e_; + struct occ_idx_opts { + enum options { n0, n1, n2, n3, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated occ_idx_e_; + + // member variables + uint8_t nrof_symbols = 4; + occ_len_e_ occ_len; + occ_idx_e_ occ_idx; + uint8_t start_symbol_idx = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15519,191 +13312,68 @@ struct quant_cfg_rs_s { void to_json(json_writer& j) const; }; -// ReportConfigInterRAT ::= SEQUENCE -struct report_cfg_inter_rat_s { - struct report_type_c_ { +// PUSCH-PathlossReferenceRS ::= SEQUENCE +struct pusch_pathloss_ref_rs_s { + struct ref_sig_c_ { struct types_opts { - enum options { periodical, event_triggered, report_cgi, /*...*/ nulltype } value; + enum options { ssb_idx, csi_rs_idx, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - report_type_c_() = default; - report_type_c_(const report_type_c_& other); - report_type_c_& operator=(const report_type_c_& other); - ~report_type_c_() { destroy_(); } + ref_sig_c_() = default; + ref_sig_c_(const ref_sig_c_& other); + ref_sig_c_& operator=(const ref_sig_c_& other); + ~ref_sig_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - periodical_report_cfg_inter_rat_s& periodical() + uint8_t& ssb_idx() { - assert_choice_type("periodical", type_.to_string(), "reportType"); - return c.get(); + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); } - event_trigger_cfg_inter_rat_s& event_triggered() + uint8_t& csi_rs_idx() { - assert_choice_type("eventTriggered", type_.to_string(), "reportType"); - return c.get(); - } - report_cgi_eutra_s& report_cgi() - { - assert_choice_type("reportCGI", type_.to_string(), "reportType"); - return c.get(); - } - const periodical_report_cfg_inter_rat_s& periodical() const - { - assert_choice_type("periodical", type_.to_string(), "reportType"); - return c.get(); - } - const event_trigger_cfg_inter_rat_s& event_triggered() const - { - assert_choice_type("eventTriggered", type_.to_string(), "reportType"); - return c.get(); - } - const report_cgi_eutra_s& report_cgi() const - { - assert_choice_type("reportCGI", type_.to_string(), "reportType"); - return c.get(); - } - periodical_report_cfg_inter_rat_s& set_periodical() - { - set(types::periodical); - return c.get(); - } - event_trigger_cfg_inter_rat_s& set_event_triggered() - { - set(types::event_triggered); - return c.get(); - } - report_cgi_eutra_s& set_report_cgi() - { - set(types::report_cgi); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - - // member variables - report_type_c_ report_type; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// ReportConfigNR ::= SEQUENCE -struct report_cfg_nr_s { - struct report_type_c_ { - struct types_opts { - enum options { periodical, event_triggered, /*...*/ report_cgi, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - report_type_c_() = default; - report_type_c_(const report_type_c_& other); - report_type_c_& operator=(const report_type_c_& other); - ~report_type_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - periodical_report_cfg_s& periodical() - { - assert_choice_type("periodical", type_.to_string(), "reportType"); - return c.get(); - } - event_trigger_cfg_s& event_triggered() - { - assert_choice_type("eventTriggered", type_.to_string(), "reportType"); - return c.get(); - } - report_cgi_s& report_cgi() - { - assert_choice_type("reportCGI", type_.to_string(), "reportType"); - return c.get(); - } - const periodical_report_cfg_s& periodical() const - { - assert_choice_type("periodical", type_.to_string(), "reportType"); - return c.get(); - } - const event_trigger_cfg_s& event_triggered() const - { - assert_choice_type("eventTriggered", type_.to_string(), "reportType"); - return c.get(); + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); } - const report_cgi_s& report_cgi() const + const uint8_t& ssb_idx() const { - assert_choice_type("reportCGI", type_.to_string(), "reportType"); - return c.get(); + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); } - periodical_report_cfg_s& set_periodical() + const uint8_t& csi_rs_idx() const { - set(types::periodical); - return c.get(); + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); } - event_trigger_cfg_s& set_event_triggered() + uint8_t& set_ssb_idx() { - set(types::event_triggered); - return c.get(); + set(types::ssb_idx); + return c.get(); } - report_cgi_s& set_report_cgi() + uint8_t& set_csi_rs_idx() { - set(types::report_cgi); - return c.get(); + set(types::csi_rs_idx); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; // member variables - report_type_c_ report_type; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// FreqPriorityEUTRA ::= SEQUENCE -struct freq_prio_eutra_s { - bool cell_resel_sub_prio_present = false; - uint32_t carrier_freq = 0; - uint8_t cell_resel_prio = 0; - cell_resel_sub_prio_e cell_resel_sub_prio; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// FreqPriorityNR ::= SEQUENCE -struct freq_prio_nr_s { - bool cell_resel_sub_prio_present = false; - uint32_t carrier_freq = 0; - uint8_t cell_resel_prio = 0; - cell_resel_sub_prio_e cell_resel_sub_prio; + uint8_t pusch_pathloss_ref_rs_id = 0; + ref_sig_c_ ref_sig; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15711,42 +13381,22 @@ struct freq_prio_nr_s { void to_json(json_writer& j) const; }; -// GapConfig ::= SEQUENCE -struct gap_cfg_s { - struct mgl_opts { - enum options { ms1dot5, ms3, ms3dot5, ms4, ms5dot5, ms6, nulltype } value; - typedef float number_type; - - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated mgl_e_; - struct mgrp_opts { - enum options { ms20, ms40, ms80, ms160, nulltype } value; +// SRI-PUSCH-PowerControl ::= SEQUENCE +struct sri_pusch_pwr_ctrl_s { + struct sri_pusch_closed_loop_idx_opts { + enum options { i0, i1, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated mgrp_e_; - struct mgta_opts { - enum options { ms0, ms0dot25, ms0dot5, nulltype } value; - typedef float number_type; - - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated mgta_e_; + typedef enumerated sri_pusch_closed_loop_idx_e_; // member variables - bool ext = false; - uint8_t gap_offset = 0; - mgl_e_ mgl; - mgrp_e_ mgrp; - mgta_e_ mgta; - // ... + uint8_t sri_pusch_pwr_ctrl_id = 0; + uint8_t sri_pusch_pathloss_ref_rs_id = 0; + uint8_t sri_p0_pusch_alpha_set_id = 0; + sri_pusch_closed_loop_idx_e_ sri_pusch_closed_loop_idx; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15754,122 +13404,1567 @@ struct gap_cfg_s { void to_json(json_writer& j) const; }; -// MeasGapSharingScheme ::= ENUMERATED -struct meas_gap_sharing_scheme_opts { - enum options { scheme00, scheme01, scheme10, scheme11, nulltype } value; - typedef float number_type; - - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; -}; -typedef enumerated meas_gap_sharing_scheme_e; +// SRS-PeriodicityAndOffset ::= CHOICE +struct srs_periodicity_and_offset_c { + struct types_opts { + enum options { + sl1, + sl2, + sl4, + sl5, + sl8, + sl10, + sl16, + sl20, + sl32, + sl40, + sl64, + sl80, + sl160, + sl320, + sl640, + sl1280, + sl2560, + nulltype + } value; + typedef uint16_t number_type; -// MeasIdToAddMod ::= SEQUENCE -struct meas_id_to_add_mod_s { - uint8_t meas_id = 1; - uint8_t meas_obj_id = 1; - uint8_t report_cfg_id = 1; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated types; - // sequence methods + // choice methods + srs_periodicity_and_offset_c() = default; + srs_periodicity_and_offset_c(const srs_periodicity_and_offset_c& other); + srs_periodicity_and_offset_c& operator=(const srs_periodicity_and_offset_c& other); + ~srs_periodicity_and_offset_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; -}; - -// MeasObjectToAddMod ::= SEQUENCE -struct meas_obj_to_add_mod_s { - struct meas_obj_c_ { - struct types_opts { - enum options { meas_obj_nr, /*...*/ meas_obj_eutra, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - meas_obj_c_() = default; - meas_obj_c_(const meas_obj_c_& other); - meas_obj_c_& operator=(const meas_obj_c_& other); - ~meas_obj_c_() { destroy_(); } + // getters + uint8_t& sl2() + { + assert_choice_type("sl2", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl4() + { + assert_choice_type("sl4", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl5() + { + assert_choice_type("sl5", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl8() + { + assert_choice_type("sl8", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl10() + { + assert_choice_type("sl10", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl16() + { + assert_choice_type("sl16", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl20() + { + assert_choice_type("sl20", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl32() + { + assert_choice_type("sl32", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl40() + { + assert_choice_type("sl40", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl64() + { + assert_choice_type("sl64", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl80() + { + assert_choice_type("sl80", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& sl160() + { + assert_choice_type("sl160", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint16_t& sl320() + { + assert_choice_type("sl320", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint16_t& sl640() + { + assert_choice_type("sl640", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint16_t& sl1280() + { + assert_choice_type("sl1280", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint16_t& sl2560() + { + assert_choice_type("sl2560", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl2() const + { + assert_choice_type("sl2", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl4() const + { + assert_choice_type("sl4", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl5() const + { + assert_choice_type("sl5", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl8() const + { + assert_choice_type("sl8", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl10() const + { + assert_choice_type("sl10", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl16() const + { + assert_choice_type("sl16", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl20() const + { + assert_choice_type("sl20", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl32() const + { + assert_choice_type("sl32", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl40() const + { + assert_choice_type("sl40", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl64() const + { + assert_choice_type("sl64", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl80() const + { + assert_choice_type("sl80", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint8_t& sl160() const + { + assert_choice_type("sl160", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint16_t& sl320() const + { + assert_choice_type("sl320", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint16_t& sl640() const + { + assert_choice_type("sl640", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint16_t& sl1280() const + { + assert_choice_type("sl1280", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + const uint16_t& sl2560() const + { + assert_choice_type("sl2560", type_.to_string(), "SRS-PeriodicityAndOffset"); + return c.get(); + } + uint8_t& set_sl2() + { + set(types::sl2); + return c.get(); + } + uint8_t& set_sl4() + { + set(types::sl4); + return c.get(); + } + uint8_t& set_sl5() + { + set(types::sl5); + return c.get(); + } + uint8_t& set_sl8() + { + set(types::sl8); + return c.get(); + } + uint8_t& set_sl10() + { + set(types::sl10); + return c.get(); + } + uint8_t& set_sl16() + { + set(types::sl16); + return c.get(); + } + uint8_t& set_sl20() + { + set(types::sl20); + return c.get(); + } + uint8_t& set_sl32() + { + set(types::sl32); + return c.get(); + } + uint8_t& set_sl40() + { + set(types::sl40); + return c.get(); + } + uint8_t& set_sl64() + { + set(types::sl64); + return c.get(); + } + uint8_t& set_sl80() + { + set(types::sl80); + return c.get(); + } + uint8_t& set_sl160() + { + set(types::sl160); + return c.get(); + } + uint16_t& set_sl320() + { + set(types::sl320); + return c.get(); + } + uint16_t& set_sl640() + { + set(types::sl640); + return c.get(); + } + uint16_t& set_sl1280() + { + set(types::sl1280); + return c.get(); + } + uint16_t& set_sl2560() + { + set(types::sl2560); + return c.get(); + } + +private: + types type_; + pod_choice_buffer_t c; + + void destroy_(); +}; + +// SRS-SpatialRelationInfo ::= SEQUENCE +struct srs_spatial_relation_info_s { + struct ref_sig_c_ { + struct srs_s_ { + uint8_t res_id = 0; + uint8_t ul_bwp = 0; + }; + struct types_opts { + enum options { ssb_idx, csi_rs_idx, srs, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + ref_sig_c_() = default; + ref_sig_c_(const ref_sig_c_& other); + ref_sig_c_& operator=(const ref_sig_c_& other); + ~ref_sig_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + uint8_t& ssb_idx() + { + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + uint8_t& csi_rs_idx() + { + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + srs_s_& srs() + { + assert_choice_type("srs", type_.to_string(), "referenceSignal"); + return c.get(); + } + const uint8_t& ssb_idx() const + { + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + const uint8_t& csi_rs_idx() const + { + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + const srs_s_& srs() const + { + assert_choice_type("srs", type_.to_string(), "referenceSignal"); + return c.get(); + } + uint8_t& set_ssb_idx() + { + set(types::ssb_idx); + return c.get(); + } + uint8_t& set_csi_rs_idx() + { + set(types::csi_rs_idx); + return c.get(); + } + srs_s_& set_srs() + { + set(types::srs); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + bool serving_cell_id_present = false; + uint8_t serving_cell_id = 0; + ref_sig_c_ ref_sig; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CG-UCI-OnPUSCH ::= CHOICE +struct cg_uci_on_pusch_c { + using dynamic_l_ = dyn_array; + struct types_opts { + enum options { dynamic_type, semi_static, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + cg_uci_on_pusch_c() = default; + cg_uci_on_pusch_c(const cg_uci_on_pusch_c& other); + cg_uci_on_pusch_c& operator=(const cg_uci_on_pusch_c& other); + ~cg_uci_on_pusch_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + dynamic_l_& dynamic_type() + { + assert_choice_type("dynamic", type_.to_string(), "CG-UCI-OnPUSCH"); + return c.get(); + } + beta_offsets_s& semi_static() + { + assert_choice_type("semiStatic", type_.to_string(), "CG-UCI-OnPUSCH"); + return c.get(); + } + const dynamic_l_& dynamic_type() const + { + assert_choice_type("dynamic", type_.to_string(), "CG-UCI-OnPUSCH"); + return c.get(); + } + const beta_offsets_s& semi_static() const + { + assert_choice_type("semiStatic", type_.to_string(), "CG-UCI-OnPUSCH"); + return c.get(); + } + dynamic_l_& set_dynamic_type() + { + set(types::dynamic_type); + return c.get(); + } + beta_offsets_s& set_semi_static() + { + set(types::semi_static); + return c.get(); + } + +private: + types type_; + choice_buffer_t c; + + void destroy_(); +}; + +// DMRS-UplinkConfig ::= SEQUENCE +struct dmrs_ul_cfg_s { + struct dmrs_add_position_opts { + enum options { pos0, pos1, pos3, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated dmrs_add_position_e_; + struct transform_precoding_disabled_s_ { + bool ext = false; + bool scrambling_id0_present = false; + bool scrambling_id1_present = false; + uint32_t scrambling_id0 = 0; + uint32_t scrambling_id1 = 0; + // ... + }; + struct transform_precoding_enabled_s_ { + bool ext = false; + bool npusch_id_present = false; + bool seq_group_hop_present = false; + bool seq_hop_present = false; + uint16_t npusch_id = 0; + // ... + }; + + // member variables + bool ext = false; + bool dmrs_type_present = false; + bool dmrs_add_position_present = false; + bool phase_tracking_rs_present = false; + bool max_len_present = false; + bool transform_precoding_disabled_present = false; + bool transform_precoding_enabled_present = false; + dmrs_add_position_e_ dmrs_add_position; + setup_release_c phase_tracking_rs; + transform_precoding_disabled_s_ transform_precoding_disabled; + transform_precoding_enabled_s_ transform_precoding_enabled; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PRACH-ResourceDedicatedBFR ::= CHOICE +struct prach_res_ded_bfr_c { + struct types_opts { + enum options { ssb, csi_rs, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + prach_res_ded_bfr_c() = default; + prach_res_ded_bfr_c(const prach_res_ded_bfr_c& other); + prach_res_ded_bfr_c& operator=(const prach_res_ded_bfr_c& other); + ~prach_res_ded_bfr_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + bfr_ssb_res_s& ssb() + { + assert_choice_type("ssb", type_.to_string(), "PRACH-ResourceDedicatedBFR"); + return c.get(); + } + bfr_csirs_res_s& csi_rs() + { + assert_choice_type("csi-RS", type_.to_string(), "PRACH-ResourceDedicatedBFR"); + return c.get(); + } + const bfr_ssb_res_s& ssb() const + { + assert_choice_type("ssb", type_.to_string(), "PRACH-ResourceDedicatedBFR"); + return c.get(); + } + const bfr_csirs_res_s& csi_rs() const + { + assert_choice_type("csi-RS", type_.to_string(), "PRACH-ResourceDedicatedBFR"); + return c.get(); + } + bfr_ssb_res_s& set_ssb() + { + set(types::ssb); + return c.get(); + } + bfr_csirs_res_s& set_csi_rs() + { + set(types::csi_rs); + return c.get(); + } + +private: + types type_; + choice_buffer_t c; + + void destroy_(); +}; + +// PUCCH-FormatConfig ::= SEQUENCE +struct pucch_format_cfg_s { + struct nrof_slots_opts { + enum options { n2, n4, n8, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated nrof_slots_e_; + + // member variables + bool interslot_freq_hop_present = false; + bool add_dmrs_present = false; + bool max_code_rate_present = false; + bool nrof_slots_present = false; + bool pi2_bpsk_present = false; + bool simul_harq_ack_csi_present = false; + pucch_max_code_rate_e max_code_rate; + nrof_slots_e_ nrof_slots; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PUCCH-PowerControl ::= SEQUENCE +struct pucch_pwr_ctrl_s { + using p0_set_l_ = dyn_array; + using pathloss_ref_rss_l_ = dyn_array; + + // member variables + bool ext = false; + bool delta_f_pucch_f0_present = false; + bool delta_f_pucch_f1_present = false; + bool delta_f_pucch_f2_present = false; + bool delta_f_pucch_f3_present = false; + bool delta_f_pucch_f4_present = false; + bool p0_set_present = false; + bool pathloss_ref_rss_present = false; + bool two_pucch_pc_adjustment_states_present = false; + int8_t delta_f_pucch_f0 = -16; + int8_t delta_f_pucch_f1 = -16; + int8_t delta_f_pucch_f2 = -16; + int8_t delta_f_pucch_f3 = -16; + int8_t delta_f_pucch_f4 = -16; + p0_set_l_ p0_set; + pathloss_ref_rss_l_ pathloss_ref_rss; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PUCCH-Resource ::= SEQUENCE +struct pucch_res_s { + struct format_c_ { + struct types_opts { + enum options { format0, format1, format2, format3, format4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + format_c_() = default; + format_c_(const format_c_& other); + format_c_& operator=(const format_c_& other); + ~format_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + pucch_format0_s& format0() + { + assert_choice_type("format0", type_.to_string(), "format"); + return c.get(); + } + pucch_format1_s& format1() + { + assert_choice_type("format1", type_.to_string(), "format"); + return c.get(); + } + pucch_format2_s& format2() + { + assert_choice_type("format2", type_.to_string(), "format"); + return c.get(); + } + pucch_format3_s& format3() + { + assert_choice_type("format3", type_.to_string(), "format"); + return c.get(); + } + pucch_format4_s& format4() + { + assert_choice_type("format4", type_.to_string(), "format"); + return c.get(); + } + const pucch_format0_s& format0() const + { + assert_choice_type("format0", type_.to_string(), "format"); + return c.get(); + } + const pucch_format1_s& format1() const + { + assert_choice_type("format1", type_.to_string(), "format"); + return c.get(); + } + const pucch_format2_s& format2() const + { + assert_choice_type("format2", type_.to_string(), "format"); + return c.get(); + } + const pucch_format3_s& format3() const + { + assert_choice_type("format3", type_.to_string(), "format"); + return c.get(); + } + const pucch_format4_s& format4() const + { + assert_choice_type("format4", type_.to_string(), "format"); + return c.get(); + } + pucch_format0_s& set_format0() + { + set(types::format0); + return c.get(); + } + pucch_format1_s& set_format1() + { + set(types::format1); + return c.get(); + } + pucch_format2_s& set_format2() + { + set(types::format2); + return c.get(); + } + pucch_format3_s& set_format3() + { + set(types::format3); + return c.get(); + } + pucch_format4_s& set_format4() + { + set(types::format4); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + bool intra_slot_freq_hop_present = false; + bool second_hop_prb_present = false; + uint8_t pucch_res_id = 0; + uint16_t start_prb = 0; + uint16_t second_hop_prb = 0; + format_c_ format; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PUCCH-ResourceSet ::= SEQUENCE +struct pucch_res_set_s { + using res_list_l_ = bounded_array; + + // member variables + bool max_payload_size_present = false; + uint8_t pucch_res_set_id = 0; + res_list_l_ res_list; + uint16_t max_payload_size = 4; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PUCCH-SpatialRelationInfo ::= SEQUENCE +struct pucch_spatial_relation_info_s { + struct ref_sig_c_ { + struct srs_s_ { + uint8_t res = 0; + uint8_t ul_bwp = 0; + }; + struct types_opts { + enum options { ssb_idx, csi_rs_idx, srs, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + ref_sig_c_() = default; + ref_sig_c_(const ref_sig_c_& other); + ref_sig_c_& operator=(const ref_sig_c_& other); + ~ref_sig_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + uint8_t& ssb_idx() + { + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + uint8_t& csi_rs_idx() + { + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + srs_s_& srs() + { + assert_choice_type("srs", type_.to_string(), "referenceSignal"); + return c.get(); + } + const uint8_t& ssb_idx() const + { + assert_choice_type("ssb-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + const uint8_t& csi_rs_idx() const + { + assert_choice_type("csi-RS-Index", type_.to_string(), "referenceSignal"); + return c.get(); + } + const srs_s_& srs() const + { + assert_choice_type("srs", type_.to_string(), "referenceSignal"); + return c.get(); + } + uint8_t& set_ssb_idx() + { + set(types::ssb_idx); + return c.get(); + } + uint8_t& set_csi_rs_idx() + { + set(types::csi_rs_idx); + return c.get(); + } + srs_s_& set_srs() + { + set(types::srs); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + struct closed_loop_idx_opts { + enum options { i0, i1, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated closed_loop_idx_e_; + + // member variables + bool serving_cell_id_present = false; + uint8_t pucch_spatial_relation_info_id = 1; + uint8_t serving_cell_id = 0; + ref_sig_c_ ref_sig; + uint8_t pucch_pathloss_ref_rs_id = 0; + uint8_t p0_pucch_id = 1; + closed_loop_idx_e_ closed_loop_idx; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PUSCH-PowerControl ::= SEQUENCE +struct pusch_pwr_ctrl_s { + using p0_alpha_sets_l_ = dyn_array; + using pathloss_ref_rs_to_add_mod_list_l_ = dyn_array; + using pathloss_ref_rs_to_release_list_l_ = bounded_array; + using sri_pusch_map_to_add_mod_list_l_ = dyn_array; + using sri_pusch_map_to_release_list_l_ = bounded_array; + + // member variables + bool tpc_accumulation_present = false; + bool msg3_alpha_present = false; + bool p0_nominal_without_grant_present = false; + bool p0_alpha_sets_present = false; + bool pathloss_ref_rs_to_add_mod_list_present = false; + bool pathloss_ref_rs_to_release_list_present = false; + bool two_pusch_pc_adjustment_states_present = false; + bool delta_mcs_present = false; + bool sri_pusch_map_to_add_mod_list_present = false; + bool sri_pusch_map_to_release_list_present = false; + alpha_e msg3_alpha; + int16_t p0_nominal_without_grant = -202; + p0_alpha_sets_l_ p0_alpha_sets; + pathloss_ref_rs_to_add_mod_list_l_ pathloss_ref_rs_to_add_mod_list; + pathloss_ref_rs_to_release_list_l_ pathloss_ref_rs_to_release_list; + sri_pusch_map_to_add_mod_list_l_ sri_pusch_map_to_add_mod_list; + sri_pusch_map_to_release_list_l_ sri_pusch_map_to_release_list; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// RA-Prioritization ::= SEQUENCE +struct ra_prioritization_s { + struct pwr_ramp_step_high_prio_opts { + enum options { db0, db2, db4, db6, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated pwr_ramp_step_high_prio_e_; + struct scaling_factor_bi_opts { + enum options { zero, dot25, dot5, dot75, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scaling_factor_bi_e_; + + // member variables + bool ext = false; + bool scaling_factor_bi_present = false; + pwr_ramp_step_high_prio_e_ pwr_ramp_step_high_prio; + scaling_factor_bi_e_ scaling_factor_bi; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SRS-Resource ::= SEQUENCE +struct srs_res_s { + struct nrof_srs_ports_opts { + enum options { port1, ports2, ports4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated nrof_srs_ports_e_; + struct ptrs_port_idx_opts { + enum options { n0, n1, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated ptrs_port_idx_e_; + struct tx_comb_c_ { + struct n2_s_ { + uint8_t comb_offset_n2 = 0; + uint8_t cyclic_shift_n2 = 0; + }; + struct n4_s_ { + uint8_t comb_offset_n4 = 0; + uint8_t cyclic_shift_n4 = 0; + }; + struct types_opts { + enum options { n2, n4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + tx_comb_c_() = default; + tx_comb_c_(const tx_comb_c_& other); + tx_comb_c_& operator=(const tx_comb_c_& other); + ~tx_comb_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + n2_s_& n2() + { + assert_choice_type("n2", type_.to_string(), "transmissionComb"); + return c.get(); + } + n4_s_& n4() + { + assert_choice_type("n4", type_.to_string(), "transmissionComb"); + return c.get(); + } + const n2_s_& n2() const + { + assert_choice_type("n2", type_.to_string(), "transmissionComb"); + return c.get(); + } + const n4_s_& n4() const + { + assert_choice_type("n4", type_.to_string(), "transmissionComb"); + return c.get(); + } + n2_s_& set_n2() + { + set(types::n2); + return c.get(); + } + n4_s_& set_n4() + { + set(types::n4); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + struct res_map_s_ { + struct nrof_symbols_opts { + enum options { n1, n2, n4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated nrof_symbols_e_; + struct repeat_factor_opts { + enum options { n1, n2, n4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated repeat_factor_e_; + + // member variables + uint8_t start_position = 0; + nrof_symbols_e_ nrof_symbols; + repeat_factor_e_ repeat_factor; + }; + struct freq_hop_s_ { + uint8_t c_srs = 0; + uint8_t b_srs = 0; + uint8_t b_hop = 0; + }; + struct group_or_seq_hop_opts { + enum options { neither, group_hop, seq_hop, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated group_or_seq_hop_e_; + struct res_type_c_ { + struct aperiodic_s_ { + bool ext = false; + // ... + }; + struct semi_persistent_s_ { + bool ext = false; + srs_periodicity_and_offset_c periodicity_and_offset_sp; + // ... + }; + struct periodic_s_ { + bool ext = false; + srs_periodicity_and_offset_c periodicity_and_offset_p; + // ... + }; + struct types_opts { + enum options { aperiodic, semi_persistent, periodic, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + res_type_c_() = default; + res_type_c_(const res_type_c_& other); + res_type_c_& operator=(const res_type_c_& other); + ~res_type_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + aperiodic_s_& aperiodic() + { + assert_choice_type("aperiodic", type_.to_string(), "resourceType"); + return c.get(); + } + semi_persistent_s_& semi_persistent() + { + assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); + return c.get(); + } + periodic_s_& periodic() + { + assert_choice_type("periodic", type_.to_string(), "resourceType"); + return c.get(); + } + const aperiodic_s_& aperiodic() const + { + assert_choice_type("aperiodic", type_.to_string(), "resourceType"); + return c.get(); + } + const semi_persistent_s_& semi_persistent() const + { + assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); + return c.get(); + } + const periodic_s_& periodic() const + { + assert_choice_type("periodic", type_.to_string(), "resourceType"); + return c.get(); + } + aperiodic_s_& set_aperiodic() + { + set(types::aperiodic); + return c.get(); + } + semi_persistent_s_& set_semi_persistent() + { + set(types::semi_persistent); + return c.get(); + } + periodic_s_& set_periodic() + { + set(types::periodic); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + bool ext = false; + bool ptrs_port_idx_present = false; + bool spatial_relation_info_present = false; + uint8_t srs_res_id = 0; + nrof_srs_ports_e_ nrof_srs_ports; + ptrs_port_idx_e_ ptrs_port_idx; + tx_comb_c_ tx_comb; + res_map_s_ res_map; + uint8_t freq_domain_position = 0; + uint16_t freq_domain_shift = 0; + freq_hop_s_ freq_hop; + group_or_seq_hop_e_ group_or_seq_hop; + res_type_c_ res_type; + uint16_t seq_id = 0; + srs_spatial_relation_info_s spatial_relation_info; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SRS-ResourceSet ::= SEQUENCE +struct srs_res_set_s { + using srs_res_id_list_l_ = bounded_array; + struct res_type_c_ { + struct aperiodic_s_ { + using aperiodic_srs_res_trigger_list_l_ = bounded_array; + + // member variables + bool ext = false; + bool csi_rs_present = false; + bool slot_offset_present = false; + uint8_t aperiodic_srs_res_trigger = 1; + uint8_t csi_rs = 0; + uint8_t slot_offset = 1; + // ... + // group 0 + copy_ptr aperiodic_srs_res_trigger_list; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + }; + struct semi_persistent_s_ { + bool ext = false; + bool associated_csi_rs_present = false; + uint8_t associated_csi_rs = 0; + // ... + }; + struct periodic_s_ { + bool ext = false; + bool associated_csi_rs_present = false; + uint8_t associated_csi_rs = 0; + // ... + }; + struct types_opts { + enum options { aperiodic, semi_persistent, periodic, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + res_type_c_() = default; + res_type_c_(const res_type_c_& other); + res_type_c_& operator=(const res_type_c_& other); + ~res_type_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + aperiodic_s_& aperiodic() + { + assert_choice_type("aperiodic", type_.to_string(), "resourceType"); + return c.get(); + } + semi_persistent_s_& semi_persistent() + { + assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); + return c.get(); + } + periodic_s_& periodic() + { + assert_choice_type("periodic", type_.to_string(), "resourceType"); + return c.get(); + } + const aperiodic_s_& aperiodic() const + { + assert_choice_type("aperiodic", type_.to_string(), "resourceType"); + return c.get(); + } + const semi_persistent_s_& semi_persistent() const + { + assert_choice_type("semi-persistent", type_.to_string(), "resourceType"); + return c.get(); + } + const periodic_s_& periodic() const + { + assert_choice_type("periodic", type_.to_string(), "resourceType"); + return c.get(); + } + aperiodic_s_& set_aperiodic() + { + set(types::aperiodic); + return c.get(); + } + semi_persistent_s_& set_semi_persistent() + { + set(types::semi_persistent); + return c.get(); + } + periodic_s_& set_periodic() + { + set(types::periodic); + return c.get(); + } + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + struct usage_opts { + enum options { beam_management, codebook, non_codebook, ant_switching, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated usage_e_; + struct pathloss_ref_rs_c_ { + struct types_opts { + enum options { ssb_idx, csi_rs_idx, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + pathloss_ref_rs_c_() = default; + pathloss_ref_rs_c_(const pathloss_ref_rs_c_& other); + pathloss_ref_rs_c_& operator=(const pathloss_ref_rs_c_& other); + ~pathloss_ref_rs_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + uint8_t& ssb_idx() + { + assert_choice_type("ssb-Index", type_.to_string(), "pathlossReferenceRS"); + return c.get(); + } + uint8_t& csi_rs_idx() + { + assert_choice_type("csi-RS-Index", type_.to_string(), "pathlossReferenceRS"); + return c.get(); + } + const uint8_t& ssb_idx() const + { + assert_choice_type("ssb-Index", type_.to_string(), "pathlossReferenceRS"); + return c.get(); + } + const uint8_t& csi_rs_idx() const + { + assert_choice_type("csi-RS-Index", type_.to_string(), "pathlossReferenceRS"); + return c.get(); + } + uint8_t& set_ssb_idx() + { + set(types::ssb_idx); + return c.get(); + } + uint8_t& set_csi_rs_idx() + { + set(types::csi_rs_idx); + return c.get(); + } + + private: + types type_; + pod_choice_buffer_t c; + + void destroy_(); + }; + struct srs_pwr_ctrl_adjustment_states_opts { + enum options { same_as_fci2, separate_closed_loop, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated srs_pwr_ctrl_adjustment_states_e_; + + // member variables + bool ext = false; + bool srs_res_id_list_present = false; + bool alpha_present = false; + bool p0_present = false; + bool pathloss_ref_rs_present = false; + bool srs_pwr_ctrl_adjustment_states_present = false; + uint8_t srs_res_set_id = 0; + srs_res_id_list_l_ srs_res_id_list; + res_type_c_ res_type; + usage_e_ usage; + alpha_e alpha; + int16_t p0 = -202; + pathloss_ref_rs_c_ pathloss_ref_rs; + srs_pwr_ctrl_adjustment_states_e_ srs_pwr_ctrl_adjustment_states; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SchedulingRequestResourceConfig ::= SEQUENCE +struct sched_request_res_cfg_s { + struct periodicity_and_offset_c_ { + struct types_opts { + enum options { + sym2, + sym6or7, + sl1, + sl2, + sl4, + sl5, + sl8, + sl10, + sl16, + sl20, + sl40, + sl80, + sl160, + sl320, + sl640, + nulltype + } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + periodicity_and_offset_c_() = default; + periodicity_and_offset_c_(const periodicity_and_offset_c_& other); + periodicity_and_offset_c_& operator=(const periodicity_and_offset_c_& other); + ~periodicity_and_offset_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - meas_obj_nr_s& meas_obj_nr() + uint8_t& sl2() { - assert_choice_type("measObjectNR", type_.to_string(), "measObject"); - return c.get(); + assert_choice_type("sl2", type_.to_string(), "periodicityAndOffset"); + return c.get(); } - meas_obj_eutra_s& meas_obj_eutra() + uint8_t& sl4() { - assert_choice_type("measObjectEUTRA", type_.to_string(), "measObject"); - return c.get(); + assert_choice_type("sl4", type_.to_string(), "periodicityAndOffset"); + return c.get(); } - const meas_obj_nr_s& meas_obj_nr() const + uint8_t& sl5() { - assert_choice_type("measObjectNR", type_.to_string(), "measObject"); - return c.get(); + assert_choice_type("sl5", type_.to_string(), "periodicityAndOffset"); + return c.get(); } - const meas_obj_eutra_s& meas_obj_eutra() const + uint8_t& sl8() { - assert_choice_type("measObjectEUTRA", type_.to_string(), "measObject"); - return c.get(); + assert_choice_type("sl8", type_.to_string(), "periodicityAndOffset"); + return c.get(); } - meas_obj_nr_s& set_meas_obj_nr() + uint8_t& sl10() { - set(types::meas_obj_nr); - return c.get(); + assert_choice_type("sl10", type_.to_string(), "periodicityAndOffset"); + return c.get(); } - meas_obj_eutra_s& set_meas_obj_eutra() + uint8_t& sl16() { - set(types::meas_obj_eutra); - return c.get(); + assert_choice_type("sl16", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + uint8_t& sl20() + { + assert_choice_type("sl20", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + uint8_t& sl40() + { + assert_choice_type("sl40", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + uint8_t& sl80() + { + assert_choice_type("sl80", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + uint8_t& sl160() + { + assert_choice_type("sl160", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + uint16_t& sl320() + { + assert_choice_type("sl320", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + uint16_t& sl640() + { + assert_choice_type("sl640", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl2() const + { + assert_choice_type("sl2", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl4() const + { + assert_choice_type("sl4", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl5() const + { + assert_choice_type("sl5", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl8() const + { + assert_choice_type("sl8", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl10() const + { + assert_choice_type("sl10", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl16() const + { + assert_choice_type("sl16", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl20() const + { + assert_choice_type("sl20", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl40() const + { + assert_choice_type("sl40", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl80() const + { + assert_choice_type("sl80", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint8_t& sl160() const + { + assert_choice_type("sl160", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint16_t& sl320() const + { + assert_choice_type("sl320", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + const uint16_t& sl640() const + { + assert_choice_type("sl640", type_.to_string(), "periodicityAndOffset"); + return c.get(); + } + uint8_t& set_sl2() + { + set(types::sl2); + return c.get(); + } + uint8_t& set_sl4() + { + set(types::sl4); + return c.get(); + } + uint8_t& set_sl5() + { + set(types::sl5); + return c.get(); + } + uint8_t& set_sl8() + { + set(types::sl8); + return c.get(); + } + uint8_t& set_sl10() + { + set(types::sl10); + return c.get(); + } + uint8_t& set_sl16() + { + set(types::sl16); + return c.get(); + } + uint8_t& set_sl20() + { + set(types::sl20); + return c.get(); + } + uint8_t& set_sl40() + { + set(types::sl40); + return c.get(); + } + uint8_t& set_sl80() + { + set(types::sl80); + return c.get(); + } + uint8_t& set_sl160() + { + set(types::sl160); + return c.get(); + } + uint16_t& set_sl320() + { + set(types::sl320); + return c.get(); + } + uint16_t& set_sl640() + { + set(types::sl640); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; // member variables - uint8_t meas_obj_id = 1; - meas_obj_c_ meas_obj; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// OtherConfig-v1540 ::= SEQUENCE -struct other_cfg_v1540_s { - bool ext = false; - bool overheat_assist_cfg_present = false; - setup_release_c overheat_assist_cfg; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PLMN-RAN-AreaCellList ::= SEQUENCE (SIZE (1..8)) OF PLMN-RAN-AreaCell -using plmn_ran_area_cell_list_l = dyn_array; - -// PLMN-RAN-AreaConfigList ::= SEQUENCE (SIZE (1..8)) OF PLMN-RAN-AreaConfig -using plmn_ran_area_cfg_list_l = dyn_array; - -// QuantityConfigNR ::= SEQUENCE -struct quant_cfg_nr_s { - bool quant_cfg_rs_idx_present = false; - quant_cfg_rs_s quant_cfg_cell; - quant_cfg_rs_s quant_cfg_rs_idx; + bool periodicity_and_offset_present = false; + bool res_present = false; + uint8_t sched_request_res_id = 1; + uint8_t sched_request_id = 0; + periodicity_and_offset_c_ periodicity_and_offset; + uint8_t res = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -15877,123 +14972,294 @@ struct quant_cfg_nr_s { void to_json(json_writer& j) const; }; -// RAT-Type ::= ENUMERATED -struct rat_type_opts { - enum options { nr, eutra_nr, eutra, spare1, /*...*/ nulltype } value; - - std::string to_string() const; -}; -typedef enumerated rat_type_e; - -// ReportConfigToAddMod ::= SEQUENCE -struct report_cfg_to_add_mod_s { - struct report_cfg_c_ { +// UCI-OnPUSCH ::= SEQUENCE +struct uci_on_pusch_s { + struct beta_offsets_c_ { + using dynamic_l_ = std::array; struct types_opts { - enum options { report_cfg_nr, /*...*/ report_cfg_inter_rat, nulltype } value; + enum options { dynamic_type, semi_static, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - report_cfg_c_() = default; - report_cfg_c_(const report_cfg_c_& other); - report_cfg_c_& operator=(const report_cfg_c_& other); - ~report_cfg_c_() { destroy_(); } + beta_offsets_c_() = default; + beta_offsets_c_(const beta_offsets_c_& other); + beta_offsets_c_& operator=(const beta_offsets_c_& other); + ~beta_offsets_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - report_cfg_nr_s& report_cfg_nr() + dynamic_l_& dynamic_type() { - assert_choice_type("reportConfigNR", type_.to_string(), "reportConfig"); - return c.get(); + assert_choice_type("dynamic", type_.to_string(), "betaOffsets"); + return c.get(); } - report_cfg_inter_rat_s& report_cfg_inter_rat() + beta_offsets_s& semi_static() { - assert_choice_type("reportConfigInterRAT", type_.to_string(), "reportConfig"); - return c.get(); + assert_choice_type("semiStatic", type_.to_string(), "betaOffsets"); + return c.get(); } - const report_cfg_nr_s& report_cfg_nr() const + const dynamic_l_& dynamic_type() const { - assert_choice_type("reportConfigNR", type_.to_string(), "reportConfig"); - return c.get(); + assert_choice_type("dynamic", type_.to_string(), "betaOffsets"); + return c.get(); } - const report_cfg_inter_rat_s& report_cfg_inter_rat() const + const beta_offsets_s& semi_static() const { - assert_choice_type("reportConfigInterRAT", type_.to_string(), "reportConfig"); - return c.get(); + assert_choice_type("semiStatic", type_.to_string(), "betaOffsets"); + return c.get(); } - report_cfg_nr_s& set_report_cfg_nr() + dynamic_l_& set_dynamic_type() { - set(types::report_cfg_nr); - return c.get(); + set(types::dynamic_type); + return c.get(); } - report_cfg_inter_rat_s& set_report_cfg_inter_rat() + beta_offsets_s& set_semi_static() { - set(types::report_cfg_inter_rat); - return c.get(); + set(types::semi_static); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; + struct scaling_opts { + enum options { f0p5, f0p65, f0p8, f1, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated scaling_e_; + + // member variables + bool beta_offsets_present = false; + beta_offsets_c_ beta_offsets; + scaling_e_ scaling; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// BeamFailureRecoveryConfig ::= SEQUENCE +struct beam_fail_recovery_cfg_s { + using candidate_beam_rs_list_l_ = dyn_array; + struct ssb_per_rach_occasion_opts { + enum options { one_eighth, one_fourth, one_half, one, two, four, eight, sixteen, nulltype } value; + typedef float number_type; + + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated ssb_per_rach_occasion_e_; + struct beam_fail_recovery_timer_opts { + enum options { ms10, ms20, ms40, ms60, ms80, ms100, ms150, ms200, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated beam_fail_recovery_timer_e_; + + // member variables + bool ext = false; + bool root_seq_idx_bfr_present = false; + bool rach_cfg_bfr_present = false; + bool rsrp_thres_ssb_present = false; + bool candidate_beam_rs_list_present = false; + bool ssb_per_rach_occasion_present = false; + bool ra_ssb_occasion_mask_idx_present = false; + bool recovery_search_space_id_present = false; + bool ra_prioritization_present = false; + bool beam_fail_recovery_timer_present = false; + uint8_t root_seq_idx_bfr = 0; + rach_cfg_generic_s rach_cfg_bfr; + uint8_t rsrp_thres_ssb = 0; + candidate_beam_rs_list_l_ candidate_beam_rs_list; + ssb_per_rach_occasion_e_ ssb_per_rach_occasion; + uint8_t ra_ssb_occasion_mask_idx = 0; + uint8_t recovery_search_space_id = 0; + ra_prioritization_s ra_prioritization; + beam_fail_recovery_timer_e_ beam_fail_recovery_timer; + // ... + // group 0 + bool msg1_subcarrier_spacing_present = false; + subcarrier_spacing_e msg1_subcarrier_spacing; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// ConfiguredGrantConfig ::= SEQUENCE +struct cfgured_grant_cfg_s { + struct freq_hop_opts { + enum options { intra_slot, inter_slot, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated freq_hop_e_; + struct mcs_table_opts { + enum options { qam256, qam64_low_se, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated mcs_table_e_; + struct mcs_table_transform_precoder_opts { + enum options { qam256, qam64_low_se, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated mcs_table_transform_precoder_e_; + struct res_alloc_opts { + enum options { res_alloc_type0, res_alloc_type1, dynamic_switch, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated res_alloc_e_; + struct pwr_ctrl_loop_to_use_opts { + enum options { n0, n1, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated pwr_ctrl_loop_to_use_e_; + struct transform_precoder_opts { + enum options { enabled, disabled, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated transform_precoder_e_; + struct rep_k_opts { + enum options { n1, n2, n4, n8, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated rep_k_e_; + struct rep_k_rv_opts { + enum options { s1_minus0231, s2_minus0303, s3_minus0000, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated rep_k_rv_e_; + struct periodicity_opts { + enum options { + sym2, + sym7, + sym1x14, + sym2x14, + sym4x14, + sym5x14, + sym8x14, + sym10x14, + sym16x14, + sym20x14, + sym32x14, + sym40x14, + sym64x14, + sym80x14, + sym128x14, + sym160x14, + sym256x14, + sym320x14, + sym512x14, + sym640x14, + sym1024x14, + sym1280x14, + sym2560x14, + sym5120x14, + sym6, + sym1x12, + sym2x12, + sym4x12, + sym5x12, + sym8x12, + sym10x12, + sym16x12, + sym20x12, + sym32x12, + sym40x12, + sym64x12, + sym80x12, + sym128x12, + sym160x12, + sym256x12, + sym320x12, + sym512x12, + sym640x12, + sym1280x12, + sym2560x12, + nulltype + } value; + + std::string to_string() const; + }; + typedef enumerated periodicity_e_; + struct rrc_cfgured_ul_grant_s_ { + bool ext = false; + bool dmrs_seq_initization_present = false; + bool srs_res_ind_present = false; + bool freq_hop_offset_present = false; + uint16_t time_domain_offset = 0; + uint8_t time_domain_alloc = 0; + fixed_bitstring<18> freq_domain_alloc; + uint8_t ant_port = 0; + uint8_t dmrs_seq_initization = 0; + uint8_t precoding_and_nof_layers = 0; + uint8_t srs_res_ind = 0; + uint8_t mcs_and_tbs = 0; + uint16_t freq_hop_offset = 1; + uint8_t pathloss_ref_idx = 0; + // ... + }; // member variables - uint8_t report_cfg_id = 1; - report_cfg_c_ report_cfg; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CarrierInfoNR ::= SEQUENCE -struct carrier_info_nr_s { - bool ext = false; - bool smtc_present = false; - uint32_t carrier_freq = 0; - subcarrier_spacing_e ssb_subcarrier_spacing; - ssb_mtc_s smtc; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// DRB-CountMSB-Info ::= SEQUENCE -struct drb_count_msb_info_s { - uint8_t drb_id = 1; - uint32_t count_msb_ul = 0; - uint32_t count_msb_dl = 0; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// FreqPriorityListEUTRA ::= SEQUENCE (SIZE (1..8)) OF FreqPriorityEUTRA -using freq_prio_list_eutra_l = dyn_array; - -// FreqPriorityListNR ::= SEQUENCE (SIZE (1..8)) OF FreqPriorityNR -using freq_prio_list_nr_l = dyn_array; - -// MasterKeyUpdate ::= SEQUENCE -struct master_key_upd_s { - bool ext = false; - bool nas_container_present = false; - bool key_set_change_ind = false; - uint8_t next_hop_chaining_count = 0; - dyn_octstring nas_container; + bool ext = false; + bool freq_hop_present = false; + bool mcs_table_present = false; + bool mcs_table_transform_precoder_present = false; + bool uci_on_pusch_present = false; + bool rbg_size_present = false; + bool transform_precoder_present = false; + bool rep_k_rv_present = false; + bool cfgured_grant_timer_present = false; + bool rrc_cfgured_ul_grant_present = false; + freq_hop_e_ freq_hop; + dmrs_ul_cfg_s cg_dmrs_cfg; + mcs_table_e_ mcs_table; + mcs_table_transform_precoder_e_ mcs_table_transform_precoder; + setup_release_c uci_on_pusch; + res_alloc_e_ res_alloc; + pwr_ctrl_loop_to_use_e_ pwr_ctrl_loop_to_use; + uint8_t p0_pusch_alpha = 0; + transform_precoder_e_ transform_precoder; + uint8_t nrof_harq_processes = 1; + rep_k_e_ rep_k; + rep_k_rv_e_ rep_k_rv; + periodicity_e_ periodicity; + uint8_t cfgured_grant_timer = 1; + rrc_cfgured_ul_grant_s_ rrc_cfgured_ul_grant; // ... // sequence methods @@ -16002,31 +15268,52 @@ struct master_key_upd_s { void to_json(json_writer& j) const; }; -// MeasGapConfig ::= SEQUENCE -struct meas_gap_cfg_s { - bool ext = false; - bool gap_fr2_present = false; - setup_release_c gap_fr2; - // ... - // group 0 - copy_ptr > gap_fr1; - copy_ptr > gap_ue; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; +// PUCCH-Config ::= SEQUENCE +struct pucch_cfg_s { + using res_set_to_add_mod_list_l_ = dyn_array; + using res_set_to_release_list_l_ = bounded_array; + using res_to_add_mod_list_l_ = dyn_array; + using res_to_release_list_l_ = dyn_array; + using sched_request_res_to_add_mod_list_l_ = dyn_array; + using sched_request_res_to_release_list_l_ = bounded_array; + using multi_csi_pucch_res_list_l_ = bounded_array; + using dl_data_to_ul_ack_l_ = bounded_array; + using spatial_relation_info_to_add_mod_list_l_ = dyn_array; + using spatial_relation_info_to_release_list_l_ = bounded_array; -// MeasGapSharingConfig ::= SEQUENCE -struct meas_gap_sharing_cfg_s { - bool ext = false; - bool gap_sharing_fr2_present = false; - setup_release_c gap_sharing_fr2; + // member variables + bool ext = false; + bool res_set_to_add_mod_list_present = false; + bool res_set_to_release_list_present = false; + bool res_to_add_mod_list_present = false; + bool res_to_release_list_present = false; + bool format1_present = false; + bool format2_present = false; + bool format3_present = false; + bool format4_present = false; + bool sched_request_res_to_add_mod_list_present = false; + bool sched_request_res_to_release_list_present = false; + bool multi_csi_pucch_res_list_present = false; + bool dl_data_to_ul_ack_present = false; + bool spatial_relation_info_to_add_mod_list_present = false; + bool spatial_relation_info_to_release_list_present = false; + bool pucch_pwr_ctrl_present = false; + res_set_to_add_mod_list_l_ res_set_to_add_mod_list; + res_set_to_release_list_l_ res_set_to_release_list; + res_to_add_mod_list_l_ res_to_add_mod_list; + res_to_release_list_l_ res_to_release_list; + setup_release_c format1; + setup_release_c format2; + setup_release_c format3; + setup_release_c format4; + sched_request_res_to_add_mod_list_l_ sched_request_res_to_add_mod_list; + sched_request_res_to_release_list_l_ sched_request_res_to_release_list; + multi_csi_pucch_res_list_l_ multi_csi_pucch_res_list; + dl_data_to_ul_ack_l_ dl_data_to_ul_ack; + spatial_relation_info_to_add_mod_list_l_ spatial_relation_info_to_add_mod_list; + spatial_relation_info_to_release_list_l_ spatial_relation_info_to_release_list; + pucch_pwr_ctrl_s pucch_pwr_ctrl; // ... - // group 0 - copy_ptr > gap_sharing_fr1; - copy_ptr > gap_sharing_ue; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16034,74 +15321,102 @@ struct meas_gap_sharing_cfg_s { void to_json(json_writer& j) const; }; -// MeasIdToAddModList ::= SEQUENCE (SIZE (1..64)) OF MeasIdToAddMod -using meas_id_to_add_mod_list_l = dyn_array; - -// MeasIdToRemoveList ::= SEQUENCE (SIZE (1..64)) OF INTEGER (1..64) -using meas_id_to_rem_list_l = dyn_array; - -// MeasObjectToAddModList ::= SEQUENCE (SIZE (1..64)) OF MeasObjectToAddMod -using meas_obj_to_add_mod_list_l = dyn_array; +// PUSCH-Config ::= SEQUENCE +struct pusch_cfg_s { + struct tx_cfg_opts { + enum options { codebook, non_codebook, nulltype } value; -// MeasObjectToRemoveList ::= SEQUENCE (SIZE (1..64)) OF INTEGER (1..64) -using meas_obj_to_rem_list_l = dyn_array; + std::string to_string() const; + }; + typedef enumerated tx_cfg_e_; + struct freq_hop_opts { + enum options { intra_slot, inter_slot, nulltype } value; -// OtherConfig ::= SEQUENCE -struct other_cfg_s { - struct delay_budget_report_cfg_c_ { - struct setup_s_ { - struct delay_budget_report_prohibit_timer_opts { - enum options { s0, s0dot4, s0dot8, s1dot6, s3, s6, s12, s30, nulltype } value; - typedef float number_type; + std::string to_string() const; + }; + typedef enumerated freq_hop_e_; + using freq_hop_offset_lists_l_ = bounded_array; + struct res_alloc_opts { + enum options { res_alloc_type0, res_alloc_type1, dynamic_switch, nulltype } value; + typedef uint8_t number_type; - std::string to_string() const; - float to_number() const; - std::string to_number_string() const; - }; - typedef enumerated delay_budget_report_prohibit_timer_e_; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated res_alloc_e_; + struct pusch_aggregation_factor_opts { + enum options { n2, n4, n8, nulltype } value; + typedef uint8_t number_type; - // member variables - delay_budget_report_prohibit_timer_e_ delay_budget_report_prohibit_timer; - }; - struct types_opts { - enum options { release, setup, nulltype } value; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated pusch_aggregation_factor_e_; + struct mcs_table_opts { + enum options { qam256, qam64_low_se, nulltype } value; + typedef uint16_t number_type; - std::string to_string() const; - }; - typedef enumerated types; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated mcs_table_e_; + struct mcs_table_transform_precoder_opts { + enum options { qam256, qam64_low_se, nulltype } value; + typedef uint16_t number_type; - // choice methods - delay_budget_report_cfg_c_() = default; - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - setup_s_& setup() - { - assert_choice_type("setup", type_.to_string(), "delayBudgetReportingConfig"); - return c; - } - const setup_s_& setup() const - { - assert_choice_type("setup", type_.to_string(), "delayBudgetReportingConfig"); - return c; - } - setup_s_& set_setup() - { - set(types::setup); - return c; - } + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated mcs_table_transform_precoder_e_; + struct transform_precoder_opts { + enum options { enabled, disabled, nulltype } value; - private: - types type_; - setup_s_ c; + std::string to_string() const; + }; + typedef enumerated transform_precoder_e_; + struct codebook_subset_opts { + enum options { fully_and_partial_and_non_coherent, partial_and_non_coherent, non_coherent, nulltype } value; + + std::string to_string() const; }; + typedef enumerated codebook_subset_e_; // member variables - bool delay_budget_report_cfg_present = false; - delay_budget_report_cfg_c_ delay_budget_report_cfg; + bool ext = false; + bool data_scrambling_id_pusch_present = false; + bool tx_cfg_present = false; + bool dmrs_ul_for_pusch_map_type_a_present = false; + bool dmrs_ul_for_pusch_map_type_b_present = false; + bool pusch_pwr_ctrl_present = false; + bool freq_hop_present = false; + bool freq_hop_offset_lists_present = false; + bool pusch_time_domain_alloc_list_present = false; + bool pusch_aggregation_factor_present = false; + bool mcs_table_present = false; + bool mcs_table_transform_precoder_present = false; + bool transform_precoder_present = false; + bool codebook_subset_present = false; + bool max_rank_present = false; + bool rbg_size_present = false; + bool uci_on_pusch_present = false; + bool tp_pi2_bpsk_present = false; + uint16_t data_scrambling_id_pusch = 0; + tx_cfg_e_ tx_cfg; + setup_release_c dmrs_ul_for_pusch_map_type_a; + setup_release_c dmrs_ul_for_pusch_map_type_b; + pusch_pwr_ctrl_s pusch_pwr_ctrl; + freq_hop_e_ freq_hop; + freq_hop_offset_lists_l_ freq_hop_offset_lists; + res_alloc_e_ res_alloc; + setup_release_c > pusch_time_domain_alloc_list; + pusch_aggregation_factor_e_ pusch_aggregation_factor; + mcs_table_e_ mcs_table; + mcs_table_transform_precoder_e_ mcs_table_transform_precoder; + transform_precoder_e_ transform_precoder; + codebook_subset_e_ codebook_subset; + uint8_t max_rank = 1; + setup_release_c uci_on_pusch; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16109,27 +15424,62 @@ struct other_cfg_s { void to_json(json_writer& j) const; }; -// PeriodicRNAU-TimerValue ::= ENUMERATED -struct periodic_rnau_timer_value_opts { - enum options { min5, min10, min20, min30, min60, min120, min360, min720, nulltype } value; - typedef uint16_t number_type; +// SRS-Config ::= SEQUENCE +struct srs_cfg_s { + using srs_res_set_to_release_list_l_ = bounded_array; + using srs_res_set_to_add_mod_list_l_ = dyn_array; + using srs_res_to_release_list_l_ = dyn_array; + using srs_res_to_add_mod_list_l_ = dyn_array; - std::string to_string() const; - uint16_t to_number() const; + // member variables + bool ext = false; + bool srs_res_set_to_release_list_present = false; + bool srs_res_set_to_add_mod_list_present = false; + bool srs_res_to_release_list_present = false; + bool srs_res_to_add_mod_list_present = false; + bool tpc_accumulation_present = false; + srs_res_set_to_release_list_l_ srs_res_set_to_release_list; + srs_res_set_to_add_mod_list_l_ srs_res_set_to_add_mod_list; + srs_res_to_release_list_l_ srs_res_to_release_list; + srs_res_to_add_mod_list_l_ srs_res_to_add_mod_list; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -typedef enumerated periodic_rnau_timer_value_e; -// QuantityConfig ::= SEQUENCE -struct quant_cfg_s { - using quant_cfg_nr_list_l_ = dyn_array; +// BWP-UplinkDedicated ::= SEQUENCE +struct bwp_ul_ded_s { + bool ext = false; + bool pucch_cfg_present = false; + bool pusch_cfg_present = false; + bool cfgured_grant_cfg_present = false; + bool srs_cfg_present = false; + bool beam_fail_recovery_cfg_present = false; + setup_release_c pucch_cfg; + setup_release_c pusch_cfg; + setup_release_c cfgured_grant_cfg; + setup_release_c srs_cfg; + setup_release_c beam_fail_recovery_cfg; + // ... - // member variables - bool ext = false; - bool quant_cfg_nr_list_present = false; - quant_cfg_nr_list_l_ quant_cfg_nr_list; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// BWP-Uplink ::= SEQUENCE +struct bwp_ul_s { + bool ext = false; + bool bwp_common_present = false; + bool bwp_ded_present = false; + uint8_t bwp_id = 0; + bwp_ul_common_s bwp_common; + bwp_ul_ded_s bwp_ded; // ... - // group 0 - copy_ptr quant_cfg_eutra; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16137,69 +15487,183 @@ struct quant_cfg_s { void to_json(json_writer& j) const; }; -// RAN-NotificationAreaInfo ::= CHOICE -struct ran_notif_area_info_c { +// CA-BandwidthClassEUTRA ::= ENUMERATED +struct ca_bw_class_eutra_opts { + enum options { a, b, c, d, e, f, /*...*/ nulltype } value; + + std::string to_string() const; +}; +typedef enumerated ca_bw_class_eutra_e; + +// CA-BandwidthClassNR ::= ENUMERATED +struct ca_bw_class_nr_opts { + enum options { a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, /*...*/ nulltype } value; + + std::string to_string() const; +}; +typedef enumerated ca_bw_class_nr_e; + +// BandParameters ::= CHOICE +struct band_params_c { + struct eutra_s_ { + bool ca_bw_class_dl_eutra_present = false; + bool ca_bw_class_ul_eutra_present = false; + uint16_t band_eutra = 1; + ca_bw_class_eutra_e ca_bw_class_dl_eutra; + ca_bw_class_eutra_e ca_bw_class_ul_eutra; + }; + struct nr_s_ { + bool ca_bw_class_dl_nr_present = false; + bool ca_bw_class_ul_nr_present = false; + uint16_t band_nr = 1; + ca_bw_class_nr_e ca_bw_class_dl_nr; + ca_bw_class_nr_e ca_bw_class_ul_nr; + }; struct types_opts { - enum options { cell_list, ran_area_cfg_list, /*...*/ nulltype } value; + enum options { eutra, nr, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated types; // choice methods - ran_notif_area_info_c() = default; - ran_notif_area_info_c(const ran_notif_area_info_c& other); - ran_notif_area_info_c& operator=(const ran_notif_area_info_c& other); - ~ran_notif_area_info_c() { destroy_(); } + band_params_c() = default; + band_params_c(const band_params_c& other); + band_params_c& operator=(const band_params_c& other); + ~band_params_c() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - plmn_ran_area_cell_list_l& cell_list() + eutra_s_& eutra() { - assert_choice_type("cellList", type_.to_string(), "RAN-NotificationAreaInfo"); - return c.get(); + assert_choice_type("eutra", type_.to_string(), "BandParameters"); + return c.get(); } - plmn_ran_area_cfg_list_l& ran_area_cfg_list() + nr_s_& nr() { - assert_choice_type("ran-AreaConfigList", type_.to_string(), "RAN-NotificationAreaInfo"); - return c.get(); + assert_choice_type("nr", type_.to_string(), "BandParameters"); + return c.get(); } - const plmn_ran_area_cell_list_l& cell_list() const + const eutra_s_& eutra() const { - assert_choice_type("cellList", type_.to_string(), "RAN-NotificationAreaInfo"); - return c.get(); + assert_choice_type("eutra", type_.to_string(), "BandParameters"); + return c.get(); } - const plmn_ran_area_cfg_list_l& ran_area_cfg_list() const + const nr_s_& nr() const { - assert_choice_type("ran-AreaConfigList", type_.to_string(), "RAN-NotificationAreaInfo"); - return c.get(); + assert_choice_type("nr", type_.to_string(), "BandParameters"); + return c.get(); } - plmn_ran_area_cell_list_l& set_cell_list() + eutra_s_& set_eutra() { - set(types::cell_list); - return c.get(); + set(types::eutra); + return c.get(); } - plmn_ran_area_cfg_list_l& set_ran_area_cfg_list() + nr_s_& set_nr() { - set(types::ran_area_cfg_list); - return c.get(); + set(types::nr); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; -// RRCReconfiguration-v1540-IEs ::= SEQUENCE -struct rrc_recfg_v1540_ies_s { - bool other_cfg_v1540_present = false; - bool non_crit_ext_present = false; - other_cfg_v1540_s other_cfg_v1540; +// CA-ParametersEUTRA ::= SEQUENCE +struct ca_params_eutra_s { + bool ext = false; + bool multiple_timing_advance_present = false; + bool simul_rx_tx_present = false; + bool supported_naics_minus2_crs_ap_present = false; + bool add_rx_tx_performance_req_present = false; + bool ue_ca_pwr_class_n_present = false; + bool supported_bw_combination_set_eutra_v1530_present = false; + bounded_bitstring<1, 8> supported_naics_minus2_crs_ap; + bounded_bitstring<1, 32> supported_bw_combination_set_eutra_v1530; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CA-ParametersNR ::= SEQUENCE +struct ca_params_nr_s { + struct supported_num_tag_opts { + enum options { n2, n3, n4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated supported_num_tag_e_; + + // member variables + bool ext = false; + bool dummy_present = false; + bool parallel_tx_srs_pucch_pusch_present = false; + bool parallel_tx_prach_srs_pucch_pusch_present = false; + bool simul_rx_tx_inter_band_ca_present = false; + bool simul_rx_tx_sul_present = false; + bool diff_numerology_across_pucch_group_present = false; + bool diff_numerology_within_pucch_group_smaller_scs_present = false; + bool supported_num_tag_present = false; + supported_num_tag_e_ supported_num_tag; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// MRDC-Parameters ::= SEQUENCE +struct mrdc_params_s { + struct ul_sharing_eutra_nr_opts { + enum options { tdm, fdm, both, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated ul_sharing_eutra_nr_e_; + struct ul_switching_time_eutra_nr_opts { + enum options { type1, type2, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated ul_switching_time_eutra_nr_e_; + struct intra_band_endc_support_opts { + enum options { non_contiguous, both, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated intra_band_endc_support_e_; + + // member variables + bool ext = false; + bool single_ul_tx_present = false; + bool dynamic_pwr_sharing_endc_present = false; + bool tdm_pattern_present = false; + bool ul_sharing_eutra_nr_present = false; + bool ul_switching_time_eutra_nr_present = false; + bool simul_rx_tx_inter_band_endc_present = false; + bool async_intra_band_endc_present = false; + ul_sharing_eutra_nr_e_ ul_sharing_eutra_nr; + ul_switching_time_eutra_nr_e_ ul_switching_time_eutra_nr; + // ... + // group 0 + bool dual_pa_architecture_present = false; + bool intra_band_endc_support_present = false; + bool ul_timing_align_eutra_nr_present = false; + intra_band_endc_support_e_ intra_band_endc_support; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16207,21 +15671,22 @@ struct rrc_recfg_v1540_ies_s { void to_json(json_writer& j) const; }; -// RedirectedCarrierInfo-EUTRA ::= SEQUENCE -struct redirected_carrier_info_eutra_s { - struct cn_type_opts { - enum options { epc, five_gc, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated cn_type_e_; +// BandCombination ::= SEQUENCE +struct band_combination_s { + using band_list_l_ = dyn_array; // member variables - bool cn_type_present = false; - uint32_t eutra_freq = 0; - cn_type_e_ cn_type; + bool ca_params_eutra_present = false; + bool ca_params_nr_present = false; + bool mrdc_params_present = false; + bool supported_bw_combination_set_present = false; + bool pwr_class_v1530_present = false; + band_list_l_ band_list; + uint16_t feature_set_combination = 0; + ca_params_eutra_s ca_params_eutra; + ca_params_nr_s ca_params_nr; + mrdc_params_s mrdc_params; + bounded_bitstring<1, 32> supported_bw_combination_set; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16229,19 +15694,66 @@ struct redirected_carrier_info_eutra_s { void to_json(json_writer& j) const; }; -// ReportConfigToAddModList ::= SEQUENCE (SIZE (1..64)) OF ReportConfigToAddMod -using report_cfg_to_add_mod_list_l = dyn_array; +// SRS-SwitchingTimeEUTRA ::= SEQUENCE +struct srs_switching_time_eutra_s { + struct switching_time_dl_opts { + enum options { + n0, + n0dot5, + n1, + n1dot5, + n2, + n2dot5, + n3, + n3dot5, + n4, + n4dot5, + n5, + n5dot5, + n6, + n6dot5, + n7, + nulltype + } value; + typedef float number_type; -// ReportConfigToRemoveList ::= SEQUENCE (SIZE (1..64)) OF INTEGER (1..64) -using report_cfg_to_rem_list_l = dyn_array; + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated switching_time_dl_e_; + struct switching_time_ul_opts { + enum options { + n0, + n0dot5, + n1, + n1dot5, + n2, + n2dot5, + n3, + n3dot5, + n4, + n4dot5, + n5, + n5dot5, + n6, + n6dot5, + n7, + nulltype + } value; + typedef float number_type; -// UE-CapabilityRAT-Request ::= SEQUENCE -struct ue_cap_rat_request_s { - bool ext = false; - bool cap_request_filt_present = false; - rat_type_e rat_type; - dyn_octstring cap_request_filt; - // ... + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated switching_time_ul_e_; + + // member variables + bool switching_time_dl_present = false; + bool switching_time_ul_present = false; + switching_time_dl_e_ switching_time_dl; + switching_time_ul_e_ switching_time_ul; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16249,26 +15761,30 @@ struct ue_cap_rat_request_s { void to_json(json_writer& j) const; }; -// CellReselectionPriorities ::= SEQUENCE -struct cell_resel_priorities_s { - struct t320_opts { - enum options { min5, min10, min20, min30, min60, min120, min180, spare1, nulltype } value; - typedef uint8_t number_type; +// SRS-SwitchingTimeNR ::= SEQUENCE +struct srs_switching_time_nr_s { + struct switching_time_dl_opts { + enum options { n0us, n30us, n100us, n140us, n200us, n300us, n500us, n900us, nulltype } value; + typedef uint16_t number_type; std::string to_string() const; - uint8_t to_number() const; + uint16_t to_number() const; }; - typedef enumerated t320_e_; + typedef enumerated switching_time_dl_e_; + struct switching_time_ul_opts { + enum options { n0us, n30us, n100us, n140us, n200us, n300us, n500us, n900us, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated switching_time_ul_e_; // member variables - bool ext = false; - bool freq_prio_list_eutra_present = false; - bool freq_prio_list_nr_present = false; - bool t320_present = false; - freq_prio_list_eutra_l freq_prio_list_eutra; - freq_prio_list_nr_l freq_prio_list_nr; - t320_e_ t320; - // ... + bool switching_time_dl_present = false; + bool switching_time_ul_present = false; + switching_time_dl_e_ switching_time_dl; + switching_time_ul_e_ switching_time_ul; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16276,91 +15792,136 @@ struct cell_resel_priorities_s { void to_json(json_writer& j) const; }; -// DRB-CountMSB-InfoList ::= SEQUENCE (SIZE (1..29)) OF DRB-CountMSB-Info -using drb_count_msb_info_list_l = dyn_array; +// BandParameters-v1540 ::= SEQUENCE +struct band_params_v1540_s { + struct srs_carrier_switch_c_ { + struct nr_s_ { + using srs_switching_times_list_nr_l_ = dyn_array; -// MeasConfig ::= SEQUENCE -struct meas_cfg_s { - struct s_measure_cfg_c_ { + // member variables + srs_switching_times_list_nr_l_ srs_switching_times_list_nr; + }; + struct eutra_s_ { + using srs_switching_times_list_eutra_l_ = dyn_array; + + // member variables + srs_switching_times_list_eutra_l_ srs_switching_times_list_eutra; + }; struct types_opts { - enum options { ssb_rsrp, csi_rsrp, nulltype } value; + enum options { nr, eutra, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - s_measure_cfg_c_() = default; - s_measure_cfg_c_(const s_measure_cfg_c_& other); - s_measure_cfg_c_& operator=(const s_measure_cfg_c_& other); - ~s_measure_cfg_c_() { destroy_(); } + srs_carrier_switch_c_() = default; + srs_carrier_switch_c_(const srs_carrier_switch_c_& other); + srs_carrier_switch_c_& operator=(const srs_carrier_switch_c_& other); + ~srs_carrier_switch_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - uint8_t& ssb_rsrp() + nr_s_& nr() { - assert_choice_type("ssb-RSRP", type_.to_string(), "s-MeasureConfig"); - return c.get(); + assert_choice_type("nr", type_.to_string(), "srs-CarrierSwitch"); + return c.get(); } - uint8_t& csi_rsrp() + eutra_s_& eutra() { - assert_choice_type("csi-RSRP", type_.to_string(), "s-MeasureConfig"); - return c.get(); + assert_choice_type("eutra", type_.to_string(), "srs-CarrierSwitch"); + return c.get(); } - const uint8_t& ssb_rsrp() const + const nr_s_& nr() const { - assert_choice_type("ssb-RSRP", type_.to_string(), "s-MeasureConfig"); - return c.get(); + assert_choice_type("nr", type_.to_string(), "srs-CarrierSwitch"); + return c.get(); } - const uint8_t& csi_rsrp() const + const eutra_s_& eutra() const { - assert_choice_type("csi-RSRP", type_.to_string(), "s-MeasureConfig"); - return c.get(); + assert_choice_type("eutra", type_.to_string(), "srs-CarrierSwitch"); + return c.get(); } - uint8_t& set_ssb_rsrp() + nr_s_& set_nr() { - set(types::ssb_rsrp); - return c.get(); + set(types::nr); + return c.get(); } - uint8_t& set_csi_rsrp() + eutra_s_& set_eutra() { - set(types::csi_rsrp); - return c.get(); + set(types::eutra); + return c.get(); } private: - types type_; - pod_choice_buffer_t c; + types type_; + choice_buffer_t c; + + void destroy_(); + }; + struct srs_tx_switch_s_ { + struct supported_srs_tx_port_switch_opts { + enum options { t1r2, t1r4, t2r4, t1r4_t2r4, t1r1, t2r2, t4r4, not_supported, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated supported_srs_tx_port_switch_e_; + + // member variables + bool tx_switch_impact_to_rx_present = false; + bool tx_switch_with_another_band_present = false; + supported_srs_tx_port_switch_e_ supported_srs_tx_port_switch; + uint8_t tx_switch_impact_to_rx = 1; + uint8_t tx_switch_with_another_band = 1; + }; + + // member variables + bool srs_carrier_switch_present = false; + bool srs_tx_switch_present = false; + srs_carrier_switch_c_ srs_carrier_switch; + srs_tx_switch_s_ srs_tx_switch; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CA-ParametersNR-v1540 ::= SEQUENCE +struct ca_params_nr_v1540_s { + struct csi_rs_im_reception_for_feedback_per_band_comb_s_ { + bool max_num_simul_nzp_csi_rs_act_bwp_all_cc_present = false; + bool total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present = false; + uint8_t max_num_simul_nzp_csi_rs_act_bwp_all_cc = 1; + uint16_t total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc = 2; + }; + + // member variables + bool simul_srs_assoc_csi_rs_all_cc_present = false; + bool csi_rs_im_reception_for_feedback_per_band_comb_present = false; + bool simul_csi_reports_all_cc_present = false; + bool dual_pa_architecture_present = false; + uint8_t simul_srs_assoc_csi_rs_all_cc = 5; + csi_rs_im_reception_for_feedback_per_band_comb_s_ csi_rs_im_reception_for_feedback_per_band_comb; + uint8_t simul_csi_reports_all_cc = 5; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - void destroy_(); - }; +// BandCombination-v1540 ::= SEQUENCE +struct band_combination_v1540_s { + using band_list_v1540_l_ = dyn_array; // member variables - bool ext = false; - bool meas_obj_to_rem_list_present = false; - bool meas_obj_to_add_mod_list_present = false; - bool report_cfg_to_rem_list_present = false; - bool report_cfg_to_add_mod_list_present = false; - bool meas_id_to_rem_list_present = false; - bool meas_id_to_add_mod_list_present = false; - bool s_measure_cfg_present = false; - bool quant_cfg_present = false; - bool meas_gap_cfg_present = false; - bool meas_gap_sharing_cfg_present = false; - meas_obj_to_rem_list_l meas_obj_to_rem_list; - meas_obj_to_add_mod_list_l meas_obj_to_add_mod_list; - report_cfg_to_rem_list_l report_cfg_to_rem_list; - report_cfg_to_add_mod_list_l report_cfg_to_add_mod_list; - meas_id_to_rem_list_l meas_id_to_rem_list; - meas_id_to_add_mod_list_l meas_id_to_add_mod_list; - s_measure_cfg_c_ s_measure_cfg; - quant_cfg_s quant_cfg; - meas_gap_cfg_s meas_gap_cfg; - meas_gap_sharing_cfg_s meas_gap_sharing_cfg; - // ... + bool ca_params_nr_v1540_present = false; + band_list_v1540_l_ band_list_v1540; + ca_params_nr_v1540_s ca_params_nr_v1540; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16368,26 +15929,19 @@ struct meas_cfg_s { void to_json(json_writer& j) const; }; -// RRCReconfiguration-v1530-IEs ::= SEQUENCE -struct rrc_recfg_v1530_ies_s { - using ded_nas_msg_list_l_ = bounded_array; +// CA-ParametersNR-v1550 ::= SEQUENCE +struct ca_params_nr_v1550_s { + bool dummy_present = false; - // member variables - bool master_cell_group_present = false; - bool full_cfg_present = false; - bool ded_nas_msg_list_present = false; - bool master_key_upd_present = false; - bool ded_sib1_delivery_present = false; - bool ded_sys_info_delivery_present = false; - bool other_cfg_present = false; - bool non_crit_ext_present = false; - dyn_octstring master_cell_group; - ded_nas_msg_list_l_ ded_nas_msg_list; - master_key_upd_s master_key_upd; - dyn_octstring ded_sib1_delivery; - dyn_octstring ded_sys_info_delivery; - other_cfg_s other_cfg; - rrc_recfg_v1540_ies_s non_crit_ext; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// BandCombination-v1550 ::= SEQUENCE +struct band_combination_v1550_s { + ca_params_nr_v1550_s ca_params_nr_v1550; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16395,11 +15949,9 @@ struct rrc_recfg_v1530_ies_s { void to_json(json_writer& j) const; }; -// RRCRelease-v1540-IEs ::= SEQUENCE -struct rrc_release_v1540_ies_s { - bool wait_time_present = false; - bool non_crit_ext_present = false; - uint8_t wait_time = 1; +// CA-ParametersNR-v1560 ::= SEQUENCE +struct ca_params_nr_v1560_s { + bool diff_numerology_within_pucch_group_larger_scs_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16407,69 +15959,56 @@ struct rrc_release_v1540_ies_s { void to_json(json_writer& j) const; }; -// RedirectedCarrierInfo ::= CHOICE -struct redirected_carrier_info_c { - struct types_opts { - enum options { nr, eutra, /*...*/ nulltype } value; +// CA-ParametersEUTRA-v1560 ::= SEQUENCE +struct ca_params_eutra_v1560_s { + bool fd_mimo_total_weighted_layers_present = false; + uint8_t fd_mimo_total_weighted_layers = 2; - std::string to_string() const; - }; - typedef enumerated types; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // choice methods - redirected_carrier_info_c() = default; - redirected_carrier_info_c(const redirected_carrier_info_c& other); - redirected_carrier_info_c& operator=(const redirected_carrier_info_c& other); - ~redirected_carrier_info_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } +// CA-ParametersNRDC ::= SEQUENCE +struct ca_params_nrdc_s { + bool ca_params_nr_for_dc_present = false; + bool ca_params_nr_for_dc_v1540_present = false; + bool ca_params_nr_for_dc_v1550_present = false; + bool ca_params_nr_for_dc_v1560_present = false; + bool feature_set_combination_dc_present = false; + ca_params_nr_s ca_params_nr_for_dc; + ca_params_nr_v1540_s ca_params_nr_for_dc_v1540; + ca_params_nr_v1550_s ca_params_nr_for_dc_v1550; + ca_params_nr_v1560_s ca_params_nr_for_dc_v1560; + uint16_t feature_set_combination_dc = 0; + + // sequence methods SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; - // getters - carrier_info_nr_s& nr() - { - assert_choice_type("nr", type_.to_string(), "RedirectedCarrierInfo"); - return c.get(); - } - redirected_carrier_info_eutra_s& eutra() - { - assert_choice_type("eutra", type_.to_string(), "RedirectedCarrierInfo"); - return c.get(); - } - const carrier_info_nr_s& nr() const - { - assert_choice_type("nr", type_.to_string(), "RedirectedCarrierInfo"); - return c.get(); - } - const redirected_carrier_info_eutra_s& eutra() const - { - assert_choice_type("eutra", type_.to_string(), "RedirectedCarrierInfo"); - return c.get(); - } - carrier_info_nr_s& set_nr() - { - set(types::nr); - return c.get(); - } - redirected_carrier_info_eutra_s& set_eutra() - { - set(types::eutra); - return c.get(); - } +}; -private: - types type_; - choice_buffer_t c; +// BandCombination-v1560 ::= SEQUENCE +struct band_combination_v1560_s { + bool ne_dc_bc_present = false; + bool ca_params_nrdc_present = false; + bool ca_params_eutra_v1560_present = false; + bool ca_params_nr_v1560_present = false; + ca_params_nrdc_s ca_params_nrdc; + ca_params_eutra_v1560_s ca_params_eutra_v1560; + ca_params_nr_v1560_s ca_params_nr_v1560; - void destroy_(); + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -// SecurityConfigSMC ::= SEQUENCE -struct security_cfg_smc_s { - bool ext = false; - security_algorithm_cfg_s security_algorithm_cfg; - // ... +// CA-ParametersEUTRA-v1570 ::= SEQUENCE +struct ca_params_eutra_v1570_s { + bool dl_minus1024_qam_total_weighted_layers_present = false; + uint8_t dl_minus1024_qam_total_weighted_layers = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16477,18 +16016,9 @@ struct security_cfg_smc_s { void to_json(json_writer& j) const; }; -// SuspendConfig ::= SEQUENCE -struct suspend_cfg_s { - bool ext = false; - bool ran_notif_area_info_present = false; - bool t380_present = false; - fixed_bitstring<40> full_i_rnti; - fixed_bitstring<24> short_i_rnti; - paging_cycle_e ran_paging_cycle; - ran_notif_area_info_c ran_notif_area_info; - periodic_rnau_timer_value_e t380; - uint8_t next_hop_chaining_count = 0; - // ... +// BandCombination-v1570 ::= SEQUENCE +struct band_combination_v1570_s { + ca_params_eutra_v1570_s ca_params_eutra_v1570; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16496,15 +16026,19 @@ struct suspend_cfg_s { void to_json(json_writer& j) const; }; -// UE-CapabilityRAT-RequestList ::= SEQUENCE (SIZE (1..8)) OF UE-CapabilityRAT-Request -using ue_cap_rat_request_list_l = dyn_array; +// MRDC-Parameters-v1580 ::= SEQUENCE +struct mrdc_params_v1580_s { + bool dynamic_pwr_sharing_nedc_present = false; -// CounterCheck-IEs ::= SEQUENCE -struct counter_check_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - drb_count_msb_info_list_l drb_count_msb_info_list; - dyn_octstring late_non_crit_ext; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// BandCombination-v1580 ::= SEQUENCE +struct band_combination_v1580_s { + mrdc_params_v1580_s mrdc_params_v1580; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16512,13 +16046,9 @@ struct counter_check_ies_s { void to_json(json_writer& j) const; }; -// DLInformationTransfer-IEs ::= SEQUENCE -struct dl_info_transfer_ies_s { - bool ded_nas_msg_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - dyn_octstring ded_nas_msg; - dyn_octstring late_non_crit_ext; +// MRDC-Parameters-v1590 ::= SEQUENCE +struct mrdc_params_v1590_s { + bool inter_band_contiguous_mrdc_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16526,23 +16056,54 @@ struct dl_info_transfer_ies_s { void to_json(json_writer& j) const; }; -// MobilityFromNRCommand-IEs ::= SEQUENCE -struct mob_from_nr_cmd_ies_s { - struct target_rat_type_opts { - enum options { eutra, spare3, spare2, spare1, /*...*/ nulltype } value; +// BandCombination-v1590 ::= SEQUENCE +struct band_combination_v1590_s { + bool supported_bw_combination_set_intra_endc_present = false; + bounded_bitstring<1, 32> supported_bw_combination_set_intra_endc; + mrdc_params_v1590_s mrdc_params_v1590; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// BandCombinationList ::= SEQUENCE (SIZE (1..65536)) OF BandCombination +using band_combination_list_l = dyn_array; + +// BandCombinationList-v1540 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1540 +using band_combination_list_v1540_l = dyn_array; + +// BandCombinationList-v1550 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1550 +using band_combination_list_v1550_l = dyn_array; + +// BandCombinationList-v1560 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1560 +using band_combination_list_v1560_l = dyn_array; + +// BandCombinationList-v1570 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1570 +using band_combination_list_v1570_l = dyn_array; + +// BandCombinationList-v1580 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1580 +using band_combination_list_v1580_l = dyn_array; + +// BandCombinationList-v1590 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1590 +using band_combination_list_v1590_l = dyn_array; + +// SupportedCSI-RS-Resource ::= SEQUENCE +struct supported_csi_rs_res_s { + struct max_num_tx_ports_per_res_opts { + enum options { p2, p4, p8, p12, p16, p24, p32, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated target_rat_type_e_; + typedef enumerated max_num_tx_ports_per_res_e_; // member variables - bool nas_security_param_from_nr_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - target_rat_type_e_ target_rat_type; - dyn_octstring target_rat_msg_container; - dyn_octstring nas_security_param_from_nr; - dyn_octstring late_non_crit_ext; + max_num_tx_ports_per_res_e_ max_num_tx_ports_per_res; + uint8_t max_num_res_per_band = 1; + uint16_t total_num_tx_ports_per_band = 2; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16550,18 +16111,54 @@ struct mob_from_nr_cmd_ies_s { void to_json(json_writer& j) const; }; -// RRCReconfiguration-IEs ::= SEQUENCE -struct rrc_recfg_ies_s { - bool radio_bearer_cfg_present = false; - bool secondary_cell_group_present = false; - bool meas_cfg_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - radio_bearer_cfg_s radio_bearer_cfg; - dyn_octstring secondary_cell_group; - meas_cfg_s meas_cfg; - dyn_octstring late_non_crit_ext; - rrc_recfg_v1530_ies_s non_crit_ext; +// BeamManagementSSB-CSI-RS ::= SEQUENCE +struct beam_management_ssb_csi_rs_s { + struct max_num_ssb_csi_rs_res_one_tx_opts { + enum options { n0, n8, n16, n32, n64, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_ssb_csi_rs_res_one_tx_e_; + struct max_num_csi_rs_res_opts { + enum options { n0, n4, n8, n16, n32, n64, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_csi_rs_res_e_; + struct max_num_csi_rs_res_two_tx_opts { + enum options { n0, n4, n8, n16, n32, n64, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_csi_rs_res_two_tx_e_; + struct supported_csi_rs_density_opts { + enum options { one, three, one_and_three, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated supported_csi_rs_density_e_; + struct max_num_aperiodic_csi_rs_res_opts { + enum options { n0, n1, n4, n8, n16, n32, n64, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_aperiodic_csi_rs_res_e_; + + // member variables + bool supported_csi_rs_density_present = false; + max_num_ssb_csi_rs_res_one_tx_e_ max_num_ssb_csi_rs_res_one_tx; + max_num_csi_rs_res_e_ max_num_csi_rs_res; + max_num_csi_rs_res_two_tx_e_ max_num_csi_rs_res_two_tx; + supported_csi_rs_density_e_ supported_csi_rs_density; + max_num_aperiodic_csi_rs_res_e_ max_num_aperiodic_csi_rs_res; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16569,12 +16166,12 @@ struct rrc_recfg_ies_s { void to_json(json_writer& j) const; }; -// RRCReestablishment-IEs ::= SEQUENCE -struct rrc_reest_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - uint8_t next_hop_chaining_count = 0; - dyn_octstring late_non_crit_ext; +// CSI-RS-ForTracking ::= SEQUENCE +struct csi_rs_for_tracking_s { + uint8_t max_burst_len = 1; + uint8_t max_simul_res_sets_per_cc = 1; + uint8_t max_cfgured_res_sets_per_cc = 1; + uint16_t max_cfgured_res_sets_all_cc = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16582,42 +16179,23 @@ struct rrc_reest_ies_s { void to_json(json_writer& j) const; }; -// RRCRelease-IEs ::= SEQUENCE -struct rrc_release_ies_s { - struct depriorit_req_s_ { - struct depriorit_type_opts { - enum options { freq, nr, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated depriorit_type_e_; - struct depriorit_timer_opts { - enum options { min5, min10, min15, min30, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated depriorit_timer_e_; +// CSI-RS-IM-ReceptionForFeedback ::= SEQUENCE +struct csi_rs_im_reception_for_feedback_s { + struct max_cfg_num_csi_im_per_cc_opts { + enum options { n1, n2, n4, n8, n16, n32, nulltype } value; + typedef uint8_t number_type; - // member variables - depriorit_type_e_ depriorit_type; - depriorit_timer_e_ depriorit_timer; + std::string to_string() const; + uint8_t to_number() const; }; + typedef enumerated max_cfg_num_csi_im_per_cc_e_; // member variables - bool redirected_carrier_info_present = false; - bool cell_resel_priorities_present = false; - bool suspend_cfg_present = false; - bool depriorit_req_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - redirected_carrier_info_c redirected_carrier_info; - cell_resel_priorities_s cell_resel_priorities; - suspend_cfg_s suspend_cfg; - depriorit_req_s_ depriorit_req; - dyn_octstring late_non_crit_ext; - rrc_release_v1540_ies_s non_crit_ext; + uint8_t max_cfg_num_nzp_csi_rs_per_cc = 1; + uint16_t max_cfg_num_ports_across_nzp_csi_rs_per_cc = 2; + max_cfg_num_csi_im_per_cc_e_ max_cfg_num_csi_im_per_cc; + uint8_t max_num_simul_nzp_csi_rs_per_cc = 1; + uint16_t total_num_ports_simul_nzp_csi_rs_per_cc = 2; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16625,18 +16203,12 @@ struct rrc_release_ies_s { void to_json(json_writer& j) const; }; -// RRCResume-IEs ::= SEQUENCE -struct rrc_resume_ies_s { - bool radio_bearer_cfg_present = false; - bool master_cell_group_present = false; - bool meas_cfg_present = false; - bool full_cfg_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - radio_bearer_cfg_s radio_bearer_cfg; - dyn_octstring master_cell_group; - meas_cfg_s meas_cfg; - dyn_octstring late_non_crit_ext; +// CSI-RS-ProcFrameworkForSRS ::= SEQUENCE +struct csi_rs_proc_framework_for_srs_s { + uint8_t max_num_periodic_srs_assoc_csi_rs_per_bwp = 1; + uint8_t max_num_aperiodic_srs_assoc_csi_rs_per_bwp = 1; + uint8_t max_num_sp_srs_assoc_csi_rs_per_bwp = 0; + uint8_t simul_srs_assoc_csi_rs_per_cc = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16644,25 +16216,26 @@ struct rrc_resume_ies_s { void to_json(json_writer& j) const; }; -// SecurityModeCommand-IEs ::= SEQUENCE -struct security_mode_cmd_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - security_cfg_smc_s security_cfg_smc; - dyn_octstring late_non_crit_ext; +// CSI-ReportFramework ::= SEQUENCE +struct csi_report_framework_s { + struct max_num_aperiodic_csi_trigger_state_per_cc_opts { + enum options { n3, n7, n15, n31, n63, n128, nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_aperiodic_csi_trigger_state_per_cc_e_; -// UECapabilityEnquiry-IEs ::= SEQUENCE -struct ue_cap_enquiry_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - ue_cap_rat_request_list_l ue_cap_rat_request_list; - dyn_octstring late_non_crit_ext; + // member variables + uint8_t max_num_periodic_csi_per_bwp_for_csi_report = 1; + uint8_t max_num_aperiodic_csi_per_bwp_for_csi_report = 1; + uint8_t max_num_semi_persistent_csi_per_bwp_for_csi_report = 0; + uint8_t max_num_periodic_csi_per_bwp_for_beam_report = 1; + uint8_t max_num_aperiodic_csi_per_bwp_for_beam_report = 1; + max_num_aperiodic_csi_trigger_state_per_cc_e_ max_num_aperiodic_csi_trigger_state_per_cc; + uint8_t max_num_semi_persistent_csi_per_bwp_for_beam_report = 0; + uint8_t simul_csi_reports_per_cc = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16670,107 +16243,90 @@ struct ue_cap_enquiry_ies_s { void to_json(json_writer& j) const; }; -// CounterCheck ::= SEQUENCE -struct counter_check_s { - struct crit_exts_c_ { - struct types_opts { - enum options { counter_check, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; +// CodebookParameters ::= SEQUENCE +struct codebook_params_s { + struct type1_s_ { + struct single_panel_s_ { + using supported_csi_rs_res_list_l_ = dyn_array; + struct modes_opts { + enum options { mode1, mode1and_mode2, nulltype } value; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - counter_check_ies_s& counter_check() - { - assert_choice_type("counterCheck", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const counter_check_ies_s& counter_check() const - { - assert_choice_type("counterCheck", type_.to_string(), "criticalExtensions"); - return c.get(); - } - counter_check_ies_s& set_counter_check() - { - set(types::counter_check); - return c.get(); - } + std::string to_string() const; + }; + typedef enumerated modes_e_; - private: - types type_; - choice_buffer_t c; + // member variables + supported_csi_rs_res_list_l_ supported_csi_rs_res_list; + modes_e_ modes; + uint8_t max_num_csi_rs_per_res_set = 1; + }; + struct multi_panel_s_ { + using supported_csi_rs_res_list_l_ = dyn_array; + struct modes_opts { + enum options { mode1, mode2, both, nulltype } value; + typedef uint8_t number_type; - void destroy_(); - }; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated modes_e_; + struct nrof_panels_opts { + enum options { n2, n4, nulltype } value; + typedef uint8_t number_type; - // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated nrof_panels_e_; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + supported_csi_rs_res_list_l_ supported_csi_rs_res_list; + modes_e_ modes; + nrof_panels_e_ nrof_panels; + uint8_t max_num_csi_rs_per_res_set = 1; + }; -// DLInformationTransfer ::= SEQUENCE -struct dl_info_transfer_s { - struct crit_exts_c_ { - struct types_opts { - enum options { dl_info_transfer, crit_exts_future, nulltype } value; + // member variables + bool multi_panel_present = false; + single_panel_s_ single_panel; + multi_panel_s_ multi_panel; + }; + struct type2_s_ { + using supported_csi_rs_res_list_l_ = dyn_array; + struct amplitude_scaling_type_opts { + enum options { wideband, wideband_and_subband, nulltype } value; std::string to_string() const; }; - typedef enumerated types; + typedef enumerated amplitude_scaling_type_e_; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - dl_info_transfer_ies_s& dl_info_transfer() - { - assert_choice_type("dlInformationTransfer", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const dl_info_transfer_ies_s& dl_info_transfer() const - { - assert_choice_type("dlInformationTransfer", type_.to_string(), "criticalExtensions"); - return c.get(); - } - dl_info_transfer_ies_s& set_dl_info_transfer() - { - set(types::dl_info_transfer); - return c.get(); - } + // member variables + bool amplitude_subset_restrict_present = false; + supported_csi_rs_res_list_l_ supported_csi_rs_res_list; + uint8_t param_lx = 2; + amplitude_scaling_type_e_ amplitude_scaling_type; + }; + struct type2_port_sel_s_ { + using supported_csi_rs_res_list_l_ = dyn_array; + struct amplitude_scaling_type_opts { + enum options { wideband, wideband_and_subband, nulltype } value; - private: - types type_; - choice_buffer_t c; + std::string to_string() const; + }; + typedef enumerated amplitude_scaling_type_e_; - void destroy_(); + // member variables + supported_csi_rs_res_list_l_ supported_csi_rs_res_list; + uint8_t param_lx = 2; + amplitude_scaling_type_e_ amplitude_scaling_type; }; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool type2_present = false; + bool type2_port_sel_present = false; + type1_s_ type1; + type2_s_ type2; + type2_port_sel_s_ type2_port_sel; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16778,53 +16334,35 @@ struct dl_info_transfer_s { void to_json(json_writer& j) const; }; -// MobilityFromNRCommand ::= SEQUENCE -struct mob_from_nr_cmd_s { - struct crit_exts_c_ { - struct types_opts { - enum options { mob_from_nr_cmd, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; +// DummyG ::= SEQUENCE +struct dummy_g_s { + struct max_num_ssb_csi_rs_res_one_tx_opts { + enum options { n8, n16, n32, n64, nulltype } value; + typedef uint8_t number_type; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - mob_from_nr_cmd_ies_s& mob_from_nr_cmd() - { - assert_choice_type("mobilityFromNRCommand", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const mob_from_nr_cmd_ies_s& mob_from_nr_cmd() const - { - assert_choice_type("mobilityFromNRCommand", type_.to_string(), "criticalExtensions"); - return c.get(); - } - mob_from_nr_cmd_ies_s& set_mob_from_nr_cmd() - { - set(types::mob_from_nr_cmd); - return c.get(); - } + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_ssb_csi_rs_res_one_tx_e_; + struct max_num_ssb_csi_rs_res_two_tx_opts { + enum options { n0, n4, n8, n16, n32, n64, nulltype } value; + typedef uint8_t number_type; - private: - types type_; - choice_buffer_t c; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_ssb_csi_rs_res_two_tx_e_; + struct supported_csi_rs_density_opts { + enum options { one, three, one_and_three, nulltype } value; - void destroy_(); + std::string to_string() const; }; + typedef enumerated supported_csi_rs_density_e_; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + max_num_ssb_csi_rs_res_one_tx_e_ max_num_ssb_csi_rs_res_one_tx; + max_num_ssb_csi_rs_res_two_tx_e_ max_num_ssb_csi_rs_res_two_tx; + supported_csi_rs_density_e_ supported_csi_rs_density; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16832,53 +16370,12 @@ struct mob_from_nr_cmd_s { void to_json(json_writer& j) const; }; -// RRCReconfiguration ::= SEQUENCE -struct rrc_recfg_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_recfg, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_recfg_ies_s& rrc_recfg() - { - assert_choice_type("rrcReconfiguration", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_recfg_ies_s& rrc_recfg() const - { - assert_choice_type("rrcReconfiguration", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_recfg_ies_s& set_rrc_recfg() - { - set(types::rrc_recfg); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - - // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; +// DummyH ::= SEQUENCE +struct dummy_h_s { + uint8_t burst_len = 1; + uint8_t max_simul_res_sets_per_cc = 1; + uint8_t max_cfgured_res_sets_per_cc = 1; + uint8_t max_cfgured_res_sets_all_cc = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16886,53 +16383,13 @@ struct rrc_recfg_s { void to_json(json_writer& j) const; }; -// RRCReestablishment ::= SEQUENCE -struct rrc_reest_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_reest, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_reest_ies_s& rrc_reest() - { - assert_choice_type("rrcReestablishment", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_reest_ies_s& rrc_reest() const - { - assert_choice_type("rrcReestablishment", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_reest_ies_s& set_rrc_reest() - { - set(types::rrc_reest); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - - // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; +// PTRS-DensityRecommendationDL ::= SEQUENCE +struct ptrs_density_recommendation_dl_s { + uint16_t freq_density1 = 1; + uint16_t freq_density2 = 1; + uint8_t time_density1 = 0; + uint8_t time_density2 = 0; + uint8_t time_density3 = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16940,53 +16397,57 @@ struct rrc_reest_s { void to_json(json_writer& j) const; }; -// RRCRelease ::= SEQUENCE -struct rrc_release_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_release, crit_exts_future, nulltype } value; +// PTRS-DensityRecommendationUL ::= SEQUENCE +struct ptrs_density_recommendation_ul_s { + uint16_t freq_density1 = 1; + uint16_t freq_density2 = 1; + uint8_t time_density1 = 0; + uint8_t time_density2 = 0; + uint8_t time_density3 = 0; + uint16_t sample_density1 = 1; + uint16_t sample_density2 = 1; + uint16_t sample_density3 = 1; + uint16_t sample_density4 = 1; + uint16_t sample_density5 = 1; - std::string to_string() const; - }; - typedef enumerated types; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_release_ies_s& rrc_release() - { - assert_choice_type("rrcRelease", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_release_ies_s& rrc_release() const - { - assert_choice_type("rrcRelease", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_release_ies_s& set_rrc_release() - { - set(types::rrc_release); - return c.get(); - } +// SpatialRelations ::= SEQUENCE +struct spatial_relations_s { + struct max_num_cfgured_spatial_relations_opts { + enum options { n4, n8, n16, n32, n64, n96, nulltype } value; + typedef uint8_t number_type; - private: - types type_; - choice_buffer_t c; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_cfgured_spatial_relations_e_; + struct max_num_active_spatial_relations_opts { + enum options { n1, n2, n4, n8, n14, nulltype } value; + typedef uint8_t number_type; - void destroy_(); + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_active_spatial_relations_e_; + struct max_num_dl_rs_qcl_type_d_opts { + enum options { n1, n2, n4, n8, n14, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; }; + typedef enumerated max_num_dl_rs_qcl_type_d_e_; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool add_active_spatial_relation_pucch_present = false; + max_num_cfgured_spatial_relations_e_ max_num_cfgured_spatial_relations; + max_num_active_spatial_relations_e_ max_num_active_spatial_relations; + max_num_dl_rs_qcl_type_d_e_ max_num_dl_rs_qcl_type_d; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -16994,161 +16455,260 @@ struct rrc_release_s { void to_json(json_writer& j) const; }; -// RRCResume ::= SEQUENCE -struct rrc_resume_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_resume, crit_exts_future, nulltype } value; +// MIMO-ParametersPerBand ::= SEQUENCE +struct mimo_params_per_band_s { + struct tci_state_pdsch_s_ { + struct max_num_cfgured_tcistates_per_cc_opts { + enum options { n4, n8, n16, n32, n64, n128, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated types; + typedef enumerated max_num_cfgured_tcistates_per_cc_e_; + struct max_num_active_tci_per_bwp_opts { + enum options { n1, n2, n4, n8, nulltype } value; + typedef uint8_t number_type; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_resume_ies_s& rrc_resume() - { - assert_choice_type("rrcResume", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_resume_ies_s& rrc_resume() const - { - assert_choice_type("rrcResume", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_resume_ies_s& set_rrc_resume() - { - set(types::rrc_resume); - return c.get(); - } + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_active_tci_per_bwp_e_; - private: - types type_; - choice_buffer_t c; + // member variables + bool max_num_cfgured_tcistates_per_cc_present = false; + bool max_num_active_tci_per_bwp_present = false; + max_num_cfgured_tcistates_per_cc_e_ max_num_cfgured_tcistates_per_cc; + max_num_active_tci_per_bwp_e_ max_num_active_tci_per_bwp; + }; + struct pusch_trans_coherence_opts { + enum options { non_coherent, partial_coherent, full_coherent, nulltype } value; - void destroy_(); + std::string to_string() const; }; + typedef enumerated pusch_trans_coherence_e_; + struct max_num_rx_tx_beam_switch_dl_s_ { + struct scs_minus15k_hz_opts { + enum options { n4, n7, n14, nulltype } value; + typedef uint8_t number_type; - // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus15k_hz_e_; + struct scs_minus30k_hz_opts { + enum options { n4, n7, n14, nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus30k_hz_e_; + struct scs_minus60k_hz_opts { + enum options { n4, n7, n14, nulltype } value; + typedef uint8_t number_type; -// SecurityModeCommand ::= SEQUENCE -struct security_mode_cmd_s { - struct crit_exts_c_ { - struct types_opts { - enum options { security_mode_cmd, crit_exts_future, nulltype } value; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus60k_hz_e_; + struct scs_minus120k_hz_opts { + enum options { n4, n7, n14, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated types; + typedef enumerated scs_minus120k_hz_e_; + struct scs_minus240k_hz_opts { + enum options { n4, n7, n14, nulltype } value; + typedef uint8_t number_type; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - security_mode_cmd_ies_s& security_mode_cmd() - { - assert_choice_type("securityModeCommand", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const security_mode_cmd_ies_s& security_mode_cmd() const - { - assert_choice_type("securityModeCommand", type_.to_string(), "criticalExtensions"); - return c.get(); - } - security_mode_cmd_ies_s& set_security_mode_cmd() - { - set(types::security_mode_cmd); - return c.get(); - } + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus240k_hz_e_; - private: - types type_; - choice_buffer_t c; + // member variables + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + bool scs_minus240k_hz_present = false; + scs_minus15k_hz_e_ scs_minus15k_hz; + scs_minus30k_hz_e_ scs_minus30k_hz; + scs_minus60k_hz_e_ scs_minus60k_hz; + scs_minus120k_hz_e_ scs_minus120k_hz; + scs_minus240k_hz_e_ scs_minus240k_hz; + }; + struct max_num_non_group_beam_report_opts { + enum options { n1, n2, n4, nulltype } value; + typedef uint8_t number_type; - void destroy_(); + std::string to_string() const; + uint8_t to_number() const; }; + typedef enumerated max_num_non_group_beam_report_e_; + struct ul_beam_management_s_ { + struct max_num_srs_res_per_set_bm_opts { + enum options { n2, n4, n8, n16, nulltype } value; + typedef uint8_t number_type; - // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_num_srs_res_per_set_bm_e_; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + max_num_srs_res_per_set_bm_e_ max_num_srs_res_per_set_bm; + uint8_t max_num_srs_res_set = 1; + }; + struct beam_report_timing_s_ { + struct scs_minus15k_hz_opts { + enum options { sym2, sym4, sym8, nulltype } value; + typedef uint8_t number_type; -// UECapabilityEnquiry ::= SEQUENCE -struct ue_cap_enquiry_s { - struct crit_exts_c_ { - struct types_opts { - enum options { ue_cap_enquiry, crit_exts_future, nulltype } value; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus15k_hz_e_; + struct scs_minus30k_hz_opts { + enum options { sym4, sym8, sym14, sym28, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus30k_hz_e_; + struct scs_minus60k_hz_opts { + enum options { sym8, sym14, sym28, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus60k_hz_e_; + struct scs_minus120k_hz_opts { + enum options { sym14, sym28, sym56, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated scs_minus120k_hz_e_; + + // member variables + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + scs_minus15k_hz_e_ scs_minus15k_hz; + scs_minus30k_hz_e_ scs_minus30k_hz; + scs_minus60k_hz_e_ scs_minus60k_hz; + scs_minus120k_hz_e_ scs_minus120k_hz; + }; + struct ptrs_density_recommendation_set_dl_s_ { + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + ptrs_density_recommendation_dl_s scs_minus15k_hz; + ptrs_density_recommendation_dl_s scs_minus30k_hz; + ptrs_density_recommendation_dl_s scs_minus60k_hz; + ptrs_density_recommendation_dl_s scs_minus120k_hz; + }; + struct ptrs_density_recommendation_set_ul_s_ { + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + ptrs_density_recommendation_ul_s scs_minus15k_hz; + ptrs_density_recommendation_ul_s scs_minus30k_hz; + ptrs_density_recommendation_ul_s scs_minus60k_hz; + ptrs_density_recommendation_ul_s scs_minus120k_hz; + }; + struct beam_switch_timing_s_ { + struct scs_minus60k_hz_opts { + enum options { sym14, sym28, sym48, sym224, sym336, nulltype } value; + typedef uint16_t number_type; std::string to_string() const; + uint16_t to_number() const; }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - ue_cap_enquiry_ies_s& ue_cap_enquiry() - { - assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const ue_cap_enquiry_ies_s& ue_cap_enquiry() const - { - assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "criticalExtensions"); - return c.get(); - } - ue_cap_enquiry_ies_s& set_ue_cap_enquiry() - { - set(types::ue_cap_enquiry); - return c.get(); - } + typedef enumerated scs_minus60k_hz_e_; + struct scs_minus120k_hz_opts { + enum options { sym14, sym28, sym48, sym224, sym336, nulltype } value; + typedef uint16_t number_type; - private: - types type_; - choice_buffer_t c; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated scs_minus120k_hz_e_; - void destroy_(); + // member variables + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + scs_minus60k_hz_e_ scs_minus60k_hz; + scs_minus120k_hz_e_ scs_minus120k_hz; }; + using srs_assoc_csi_rs_l_ = dyn_array; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool ext = false; + bool tci_state_pdsch_present = false; + bool add_active_tci_state_pdcch_present = false; + bool pusch_trans_coherence_present = false; + bool beam_correspondence_without_ul_beam_sweeping_present = false; + bool periodic_beam_report_present = false; + bool aperiodic_beam_report_present = false; + bool sp_beam_report_pucch_present = false; + bool sp_beam_report_pusch_present = false; + bool dummy1_present = false; + bool max_num_rx_beam_present = false; + bool max_num_rx_tx_beam_switch_dl_present = false; + bool max_num_non_group_beam_report_present = false; + bool group_beam_report_present = false; + bool ul_beam_management_present = false; + bool max_num_csi_rs_bfd_present = false; + bool max_num_ssb_bfd_present = false; + bool max_num_csi_rs_ssb_cbd_present = false; + bool dummy2_present = false; + bool two_ports_ptrs_ul_present = false; + bool dummy5_present = false; + bool dummy3_present = false; + bool beam_report_timing_present = false; + bool ptrs_density_recommendation_set_dl_present = false; + bool ptrs_density_recommendation_set_ul_present = false; + bool dummy4_present = false; + bool aperiodic_trs_present = false; + tci_state_pdsch_s_ tci_state_pdsch; + pusch_trans_coherence_e_ pusch_trans_coherence; + dummy_g_s dummy1; + uint8_t max_num_rx_beam = 2; + max_num_rx_tx_beam_switch_dl_s_ max_num_rx_tx_beam_switch_dl; + max_num_non_group_beam_report_e_ max_num_non_group_beam_report; + ul_beam_management_s_ ul_beam_management; + uint8_t max_num_csi_rs_bfd = 1; + uint8_t max_num_ssb_bfd = 1; + uint16_t max_num_csi_rs_ssb_cbd = 1; + srs_res_s dummy5; + uint8_t dummy3 = 1; + beam_report_timing_s_ beam_report_timing; + ptrs_density_recommendation_set_dl_s_ ptrs_density_recommendation_set_dl; + ptrs_density_recommendation_set_ul_s_ ptrs_density_recommendation_set_ul; + dummy_h_s dummy4; + // ... + // group 0 + bool dummy6_present = false; + copy_ptr beam_management_ssb_csi_rs; + copy_ptr beam_switch_timing; + copy_ptr codebook_params; + copy_ptr csi_rs_im_reception_for_feedback; + copy_ptr csi_rs_proc_framework_for_srs; + copy_ptr csi_report_framework; + copy_ptr csi_rs_for_tracking; + copy_ptr srs_assoc_csi_rs; + copy_ptr spatial_relations; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -17156,592 +16716,368 @@ struct ue_cap_enquiry_s { void to_json(json_writer& j) const; }; -// DL-DCCH-MessageType ::= CHOICE -struct dl_dcch_msg_type_c { - struct c1_c_ { +// BandNR ::= SEQUENCE +struct band_nr_s { + struct bwp_same_numerology_opts { + enum options { upto2, upto4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated bwp_same_numerology_e_; + struct ue_pwr_class_opts { + enum options { pc1, pc2, pc3, pc4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated ue_pwr_class_e_; + struct ch_bws_dl_c_ { + struct fr1_s_ { + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + fixed_bitstring<10> scs_minus15k_hz; + fixed_bitstring<10> scs_minus30k_hz; + fixed_bitstring<10> scs_minus60k_hz; + }; + struct fr2_s_ { + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + fixed_bitstring<3> scs_minus60k_hz; + fixed_bitstring<3> scs_minus120k_hz; + }; struct types_opts { - enum options { - rrc_recfg, - rrc_resume, - rrc_release, - rrc_reest, - security_mode_cmd, - dl_info_transfer, - ue_cap_enquiry, - counter_check, - mob_from_nr_cmd, - spare7, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; + enum options { fr1, fr2, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; typedef enumerated types; // choice methods - c1_c_() = default; - c1_c_(const c1_c_& other); - c1_c_& operator=(const c1_c_& other); - ~c1_c_() { destroy_(); } + ch_bws_dl_c_() = default; + ch_bws_dl_c_(const ch_bws_dl_c_& other); + ch_bws_dl_c_& operator=(const ch_bws_dl_c_& other); + ~ch_bws_dl_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - rrc_recfg_s& rrc_recfg() - { - assert_choice_type("rrcReconfiguration", type_.to_string(), "c1"); - return c.get(); - } - rrc_resume_s& rrc_resume() - { - assert_choice_type("rrcResume", type_.to_string(), "c1"); - return c.get(); - } - rrc_release_s& rrc_release() - { - assert_choice_type("rrcRelease", type_.to_string(), "c1"); - return c.get(); - } - rrc_reest_s& rrc_reest() - { - assert_choice_type("rrcReestablishment", type_.to_string(), "c1"); - return c.get(); - } - security_mode_cmd_s& security_mode_cmd() - { - assert_choice_type("securityModeCommand", type_.to_string(), "c1"); - return c.get(); - } - dl_info_transfer_s& dl_info_transfer() - { - assert_choice_type("dlInformationTransfer", type_.to_string(), "c1"); - return c.get(); - } - ue_cap_enquiry_s& ue_cap_enquiry() - { - assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "c1"); - return c.get(); - } - counter_check_s& counter_check() - { - assert_choice_type("counterCheck", type_.to_string(), "c1"); - return c.get(); - } - mob_from_nr_cmd_s& mob_from_nr_cmd() - { - assert_choice_type("mobilityFromNRCommand", type_.to_string(), "c1"); - return c.get(); - } - const rrc_recfg_s& rrc_recfg() const - { - assert_choice_type("rrcReconfiguration", type_.to_string(), "c1"); - return c.get(); - } - const rrc_resume_s& rrc_resume() const - { - assert_choice_type("rrcResume", type_.to_string(), "c1"); - return c.get(); - } - const rrc_release_s& rrc_release() const - { - assert_choice_type("rrcRelease", type_.to_string(), "c1"); - return c.get(); - } - const rrc_reest_s& rrc_reest() const - { - assert_choice_type("rrcReestablishment", type_.to_string(), "c1"); - return c.get(); - } - const security_mode_cmd_s& security_mode_cmd() const - { - assert_choice_type("securityModeCommand", type_.to_string(), "c1"); - return c.get(); - } - const dl_info_transfer_s& dl_info_transfer() const - { - assert_choice_type("dlInformationTransfer", type_.to_string(), "c1"); - return c.get(); - } - const ue_cap_enquiry_s& ue_cap_enquiry() const - { - assert_choice_type("ueCapabilityEnquiry", type_.to_string(), "c1"); - return c.get(); + fr1_s_& fr1() + { + assert_choice_type("fr1", type_.to_string(), "channelBWs-DL"); + return c.get(); } - const counter_check_s& counter_check() const + fr2_s_& fr2() { - assert_choice_type("counterCheck", type_.to_string(), "c1"); - return c.get(); + assert_choice_type("fr2", type_.to_string(), "channelBWs-DL"); + return c.get(); } - const mob_from_nr_cmd_s& mob_from_nr_cmd() const + const fr1_s_& fr1() const { - assert_choice_type("mobilityFromNRCommand", type_.to_string(), "c1"); - return c.get(); + assert_choice_type("fr1", type_.to_string(), "channelBWs-DL"); + return c.get(); } - rrc_recfg_s& set_rrc_recfg() + const fr2_s_& fr2() const { - set(types::rrc_recfg); - return c.get(); + assert_choice_type("fr2", type_.to_string(), "channelBWs-DL"); + return c.get(); } - rrc_resume_s& set_rrc_resume() + fr1_s_& set_fr1() { - set(types::rrc_resume); - return c.get(); + set(types::fr1); + return c.get(); } - rrc_release_s& set_rrc_release() + fr2_s_& set_fr2() { - set(types::rrc_release); - return c.get(); + set(types::fr2); + return c.get(); } - rrc_reest_s& set_rrc_reest() + + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + struct ch_bws_ul_c_ { + struct fr1_s_ { + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + fixed_bitstring<10> scs_minus15k_hz; + fixed_bitstring<10> scs_minus30k_hz; + fixed_bitstring<10> scs_minus60k_hz; + }; + struct fr2_s_ { + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + fixed_bitstring<3> scs_minus60k_hz; + fixed_bitstring<3> scs_minus120k_hz; + }; + struct types_opts { + enum options { fr1, fr2, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; + + // choice methods + ch_bws_ul_c_() = default; + ch_bws_ul_c_(const ch_bws_ul_c_& other); + ch_bws_ul_c_& operator=(const ch_bws_ul_c_& other); + ~ch_bws_ul_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fr1_s_& fr1() { - set(types::rrc_reest); - return c.get(); + assert_choice_type("fr1", type_.to_string(), "channelBWs-UL"); + return c.get(); } - security_mode_cmd_s& set_security_mode_cmd() + fr2_s_& fr2() { - set(types::security_mode_cmd); - return c.get(); + assert_choice_type("fr2", type_.to_string(), "channelBWs-UL"); + return c.get(); } - dl_info_transfer_s& set_dl_info_transfer() + const fr1_s_& fr1() const { - set(types::dl_info_transfer); - return c.get(); + assert_choice_type("fr1", type_.to_string(), "channelBWs-UL"); + return c.get(); } - ue_cap_enquiry_s& set_ue_cap_enquiry() + const fr2_s_& fr2() const { - set(types::ue_cap_enquiry); - return c.get(); + assert_choice_type("fr2", type_.to_string(), "channelBWs-UL"); + return c.get(); } - counter_check_s& set_counter_check() + fr1_s_& set_fr1() { - set(types::counter_check); - return c.get(); + set(types::fr1); + return c.get(); } - mob_from_nr_cmd_s& set_mob_from_nr_cmd() + fr2_s_& set_fr2() { - set(types::mob_from_nr_cmd); - return c.get(); + set(types::fr2); + return c.get(); } private: - types type_; - choice_buffer_t - c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct types_opts { - enum options { c1, msg_class_ext, nulltype } value; + struct max_ul_duty_cycle_pc2_fr1_opts { + enum options { n60, n70, n80, n90, n100, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated types; - - // choice methods - dl_dcch_msg_type_c() = default; - dl_dcch_msg_type_c(const dl_dcch_msg_type_c& other); - dl_dcch_msg_type_c& operator=(const dl_dcch_msg_type_c& other); - ~dl_dcch_msg_type_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - c1_c_& c1() - { - assert_choice_type("c1", type_.to_string(), "DL-DCCH-MessageType"); - return c.get(); - } - const c1_c_& c1() const - { - assert_choice_type("c1", type_.to_string(), "DL-DCCH-MessageType"); - return c.get(); - } - c1_c_& set_c1() - { - set(types::c1); - return c.get(); - } - -private: - types type_; - choice_buffer_t c; - - void destroy_(); -}; - -// DL-DCCH-Message ::= SEQUENCE -struct dl_dcch_msg_s { - dl_dcch_msg_type_c msg; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PagingUE-Identity ::= CHOICE -struct paging_ue_id_c { - struct types_opts { - enum options { ng_minus5_g_s_tmsi, full_i_rnti, /*...*/ nulltype } value; - typedef int8_t number_type; - - std::string to_string() const; - int8_t to_number() const; - }; - typedef enumerated types; - - // choice methods - paging_ue_id_c() = default; - paging_ue_id_c(const paging_ue_id_c& other); - paging_ue_id_c& operator=(const paging_ue_id_c& other); - ~paging_ue_id_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<48>& ng_minus5_g_s_tmsi() - { - assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "PagingUE-Identity"); - return c.get >(); - } - fixed_bitstring<40>& full_i_rnti() - { - assert_choice_type("fullI-RNTI", type_.to_string(), "PagingUE-Identity"); - return c.get >(); - } - const fixed_bitstring<48>& ng_minus5_g_s_tmsi() const - { - assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "PagingUE-Identity"); - return c.get >(); - } - const fixed_bitstring<40>& full_i_rnti() const - { - assert_choice_type("fullI-RNTI", type_.to_string(), "PagingUE-Identity"); - return c.get >(); - } - fixed_bitstring<48>& set_ng_minus5_g_s_tmsi() - { - set(types::ng_minus5_g_s_tmsi); - return c.get >(); - } - fixed_bitstring<40>& set_full_i_rnti() - { - set(types::full_i_rnti); - return c.get >(); - } - -private: - types type_; - choice_buffer_t > c; - - void destroy_(); -}; - -// PagingRecord ::= SEQUENCE -struct paging_record_s { - bool ext = false; - bool access_type_present = false; - paging_ue_id_c ue_id; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PagingRecordList ::= SEQUENCE (SIZE (1..32)) OF PagingRecord -using paging_record_list_l = dyn_array; - -// Paging ::= SEQUENCE -struct paging_s { - bool paging_record_list_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - paging_record_list_l paging_record_list; - dyn_octstring late_non_crit_ext; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// PCCH-MessageType ::= CHOICE -struct pcch_msg_type_c { - struct c1_c_ { + typedef enumerated max_ul_duty_cycle_pc2_fr1_e_; + struct max_ul_duty_cycle_fr2_opts { + enum options { n15, n20, n25, n30, n40, n50, n60, n70, n80, n90, n100, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated max_ul_duty_cycle_fr2_e_; + struct ch_bws_dl_v1590_c_ { + struct fr1_s_ { + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + fixed_bitstring<16> scs_minus15k_hz; + fixed_bitstring<16> scs_minus30k_hz; + fixed_bitstring<16> scs_minus60k_hz; + }; + struct fr2_s_ { + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + fixed_bitstring<8> scs_minus60k_hz; + fixed_bitstring<8> scs_minus120k_hz; + }; struct types_opts { - enum options { paging, spare1, nulltype } value; + enum options { fr1, fr2, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; typedef enumerated types; // choice methods - c1_c_() = default; + ch_bws_dl_v1590_c_() = default; + ch_bws_dl_v1590_c_(const ch_bws_dl_v1590_c_& other); + ch_bws_dl_v1590_c_& operator=(const ch_bws_dl_v1590_c_& other); + ~ch_bws_dl_v1590_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - paging_s& paging() + fr1_s_& fr1() { - assert_choice_type("paging", type_.to_string(), "c1"); - return c; + assert_choice_type("fr1", type_.to_string(), "channelBWs-DL-v1590"); + return c.get(); } - const paging_s& paging() const + fr2_s_& fr2() { - assert_choice_type("paging", type_.to_string(), "c1"); - return c; + assert_choice_type("fr2", type_.to_string(), "channelBWs-DL-v1590"); + return c.get(); } - paging_s& set_paging() + const fr1_s_& fr1() const { - set(types::paging); - return c; + assert_choice_type("fr1", type_.to_string(), "channelBWs-DL-v1590"); + return c.get(); + } + const fr2_s_& fr2() const + { + assert_choice_type("fr2", type_.to_string(), "channelBWs-DL-v1590"); + return c.get(); + } + fr1_s_& set_fr1() + { + set(types::fr1); + return c.get(); + } + fr2_s_& set_fr2() + { + set(types::fr2); + return c.get(); } private: - types type_; - paging_s c; - }; - struct types_opts { - enum options { c1, msg_class_ext, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; - - // choice methods - pcch_msg_type_c() = default; - pcch_msg_type_c(const pcch_msg_type_c& other); - pcch_msg_type_c& operator=(const pcch_msg_type_c& other); - ~pcch_msg_type_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - c1_c_& c1() - { - assert_choice_type("c1", type_.to_string(), "PCCH-MessageType"); - return c.get(); - } - const c1_c_& c1() const - { - assert_choice_type("c1", type_.to_string(), "PCCH-MessageType"); - return c.get(); - } - c1_c_& set_c1() - { - set(types::c1); - return c.get(); - } - -private: - types type_; - choice_buffer_t c; - - void destroy_(); -}; - -// PCCH-Message ::= SEQUENCE -struct pcch_msg_s { - pcch_msg_type_c msg; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// EstablishmentCause ::= ENUMERATED -struct establishment_cause_opts { - enum options { - emergency, - high_prio_access, - mt_access, - mo_sig, - mo_data, - mo_voice_call, - mo_video_call, - mo_sms, - mps_prio_access, - mcs_prio_access, - spare6, - spare5, - spare4, - spare3, - spare2, - spare1, - nulltype - } value; - - std::string to_string() const; -}; -typedef enumerated establishment_cause_e; - -// InitialUE-Identity ::= CHOICE -struct init_ue_id_c { - struct types_opts { - enum options { ng_minus5_g_s_tmsi_part1, random_value, nulltype } value; - typedef int8_t number_type; + types type_; + choice_buffer_t c; - std::string to_string() const; - int8_t to_number() const; + void destroy_(); }; - typedef enumerated types; - - // choice methods - init_ue_id_c() = default; - init_ue_id_c(const init_ue_id_c& other); - init_ue_id_c& operator=(const init_ue_id_c& other); - ~init_ue_id_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<39>& ng_minus5_g_s_tmsi_part1() - { - assert_choice_type("ng-5G-S-TMSI-Part1", type_.to_string(), "InitialUE-Identity"); - return c.get >(); - } - fixed_bitstring<39>& random_value() - { - assert_choice_type("randomValue", type_.to_string(), "InitialUE-Identity"); - return c.get >(); - } - const fixed_bitstring<39>& ng_minus5_g_s_tmsi_part1() const - { - assert_choice_type("ng-5G-S-TMSI-Part1", type_.to_string(), "InitialUE-Identity"); - return c.get >(); - } - const fixed_bitstring<39>& random_value() const - { - assert_choice_type("randomValue", type_.to_string(), "InitialUE-Identity"); - return c.get >(); - } - fixed_bitstring<39>& set_ng_minus5_g_s_tmsi_part1() - { - set(types::ng_minus5_g_s_tmsi_part1); - return c.get >(); - } - fixed_bitstring<39>& set_random_value() - { - set(types::random_value); - return c.get >(); - } - -private: - types type_; - choice_buffer_t > c; - - void destroy_(); -}; - -// ReestabUE-Identity ::= SEQUENCE -struct reestab_ue_id_s { - uint32_t c_rnti = 0; - uint16_t pci = 0; - fixed_bitstring<16> short_mac_i; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// ReestablishmentCause ::= ENUMERATED -struct reest_cause_opts { - enum options { recfg_fail, ho_fail, other_fail, spare1, nulltype } value; - - std::string to_string() const; -}; -typedef enumerated reest_cause_e; - -// ResumeCause ::= ENUMERATED -struct resume_cause_opts { - enum options { - emergency, - high_prio_access, - mt_access, - mo_sig, - mo_data, - mo_voice_call, - mo_video_call, - mo_sms, - rna_upd, - mps_prio_access, - mcs_prio_access, - spare1, - spare2, - spare3, - spare4, - spare5, - nulltype - } value; - - std::string to_string() const; -}; -typedef enumerated resume_cause_e; + struct ch_bws_ul_v1590_c_ { + struct fr1_s_ { + bool scs_minus15k_hz_present = false; + bool scs_minus30k_hz_present = false; + bool scs_minus60k_hz_present = false; + fixed_bitstring<16> scs_minus15k_hz; + fixed_bitstring<16> scs_minus30k_hz; + fixed_bitstring<16> scs_minus60k_hz; + }; + struct fr2_s_ { + bool scs_minus60k_hz_present = false; + bool scs_minus120k_hz_present = false; + fixed_bitstring<8> scs_minus60k_hz; + fixed_bitstring<8> scs_minus120k_hz; + }; + struct types_opts { + enum options { fr1, fr2, nulltype } value; + typedef uint8_t number_type; -// RRCReestablishmentRequest-IEs ::= SEQUENCE -struct rrc_reest_request_ies_s { - reestab_ue_id_s ue_id; - reest_cause_e reest_cause; - fixed_bitstring<1> spare; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // choice methods + ch_bws_ul_v1590_c_() = default; + ch_bws_ul_v1590_c_(const ch_bws_ul_v1590_c_& other); + ch_bws_ul_v1590_c_& operator=(const ch_bws_ul_v1590_c_& other); + ~ch_bws_ul_v1590_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fr1_s_& fr1() + { + assert_choice_type("fr1", type_.to_string(), "channelBWs-UL-v1590"); + return c.get(); + } + fr2_s_& fr2() + { + assert_choice_type("fr2", type_.to_string(), "channelBWs-UL-v1590"); + return c.get(); + } + const fr1_s_& fr1() const + { + assert_choice_type("fr1", type_.to_string(), "channelBWs-UL-v1590"); + return c.get(); + } + const fr2_s_& fr2() const + { + assert_choice_type("fr2", type_.to_string(), "channelBWs-UL-v1590"); + return c.get(); + } + fr1_s_& set_fr1() + { + set(types::fr1); + return c.get(); + } + fr2_s_& set_fr2() + { + set(types::fr2); + return c.get(); + } -// RRCResumeRequest-IEs ::= SEQUENCE -struct rrc_resume_request_ies_s { - fixed_bitstring<24> resume_id; - fixed_bitstring<16> resume_mac_i; - resume_cause_e resume_cause; - fixed_bitstring<1> spare; + private: + types type_; + choice_buffer_t c; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + void destroy_(); + }; -// RRCSetupRequest-IEs ::= SEQUENCE -struct rrc_setup_request_ies_s { - init_ue_id_c ue_id; - establishment_cause_e establishment_cause; - fixed_bitstring<1> spare; + // member variables + bool ext = false; + bool modified_mpr_behaviour_present = false; + bool mimo_params_per_band_present = false; + bool extended_cp_present = false; + bool multiple_tci_present = false; + bool bwp_without_restrict_present = false; + bool bwp_same_numerology_present = false; + bool bwp_diff_numerology_present = false; + bool cross_carrier_sched_same_scs_present = false; + bool pdsch_minus256_qam_fr2_present = false; + bool pusch_minus256_qam_present = false; + bool ue_pwr_class_present = false; + bool rate_matching_lte_crs_present = false; + bool ch_bws_dl_present = false; + bool ch_bws_ul_present = false; + uint16_t band_nr = 1; + fixed_bitstring<8> modified_mpr_behaviour; + mimo_params_per_band_s mimo_params_per_band; + bwp_same_numerology_e_ bwp_same_numerology; + ue_pwr_class_e_ ue_pwr_class; + ch_bws_dl_c_ ch_bws_dl; + ch_bws_ul_c_ ch_bws_ul; + // ... + // group 0 + bool max_ul_duty_cycle_pc2_fr1_present = false; + max_ul_duty_cycle_pc2_fr1_e_ max_ul_duty_cycle_pc2_fr1; + // group 1 + bool pucch_spatial_rel_info_mac_ce_present = false; + bool pwr_boosting_pi2_bpsk_present = false; + // group 2 + bool max_ul_duty_cycle_fr2_present = false; + max_ul_duty_cycle_fr2_e_ max_ul_duty_cycle_fr2; + // group 3 + copy_ptr ch_bws_dl_v1590; + copy_ptr ch_bws_ul_v1590; + // group 4 + bool asymmetric_bw_combination_set_present = false; + bounded_bitstring<1, 32> asymmetric_bw_combination_set; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -17749,10 +17085,16 @@ struct rrc_setup_request_ies_s { void to_json(json_writer& j) const; }; -// RRCSystemInfoRequest-r15-IEs ::= SEQUENCE -struct rrc_sys_info_request_r15_ies_s { - fixed_bitstring<32> requested_si_list; - fixed_bitstring<12> spare; +// CFRA-CSIRS-Resource ::= SEQUENCE +struct cfra_csirs_res_s { + using ra_occasion_list_l_ = dyn_array; + + // member variables + bool ext = false; + uint8_t csi_rs = 0; + ra_occasion_list_l_ ra_occasion_list; + uint8_t ra_preamb_idx = 0; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -17760,9 +17102,12 @@ struct rrc_sys_info_request_r15_ies_s { void to_json(json_writer& j) const; }; -// RRCReestablishmentRequest ::= SEQUENCE -struct rrc_reest_request_s { - rrc_reest_request_ies_s rrc_reest_request; +// CFRA-SSB-Resource ::= SEQUENCE +struct cfra_ssb_res_s { + bool ext = false; + uint8_t ssb = 0; + uint8_t ra_preamb_idx = 0; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -17770,72 +17115,104 @@ struct rrc_reest_request_s { void to_json(json_writer& j) const; }; -// RRCResumeRequest ::= SEQUENCE -struct rrc_resume_request_s { - rrc_resume_request_ies_s rrc_resume_request; +// CFRA ::= SEQUENCE +struct cfra_s { + struct occasions_s_ { + struct ssb_per_rach_occasion_opts { + enum options { one_eighth, one_fourth, one_half, one, two, four, eight, sixteen, nulltype } value; + typedef float number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + float to_number() const; + std::string to_number_string() const; + }; + typedef enumerated ssb_per_rach_occasion_e_; -// RRCSetupRequest ::= SEQUENCE -struct rrc_setup_request_s { - rrc_setup_request_ies_s rrc_setup_request; + // member variables + bool ssb_per_rach_occasion_present = false; + rach_cfg_generic_s rach_cfg_generic; + ssb_per_rach_occasion_e_ ssb_per_rach_occasion; + }; + struct res_c_ { + struct ssb_s_ { + using ssb_res_list_l_ = dyn_array; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + ssb_res_list_l_ ssb_res_list; + uint8_t ra_ssb_occasion_mask_idx = 0; + }; + struct csirs_s_ { + using csirs_res_list_l_ = dyn_array; -// RRCSystemInfoRequest ::= SEQUENCE -struct rrc_sys_info_request_s { - struct crit_exts_c_ { + // member variables + csirs_res_list_l_ csirs_res_list; + uint8_t rsrp_thres_csi_rs = 0; + }; struct types_opts { - enum options { rrc_sys_info_request_r15, crit_exts_future, nulltype } value; + enum options { ssb, csirs, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } + res_c_() = default; + res_c_(const res_c_& other); + res_c_& operator=(const res_c_& other); + ~res_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - rrc_sys_info_request_r15_ies_s& rrc_sys_info_request_r15() + ssb_s_& ssb() + { + assert_choice_type("ssb", type_.to_string(), "resources"); + return c.get(); + } + csirs_s_& csirs() + { + assert_choice_type("csirs", type_.to_string(), "resources"); + return c.get(); + } + const ssb_s_& ssb() const + { + assert_choice_type("ssb", type_.to_string(), "resources"); + return c.get(); + } + const csirs_s_& csirs() const { - assert_choice_type("rrcSystemInfoRequest-r15", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("csirs", type_.to_string(), "resources"); + return c.get(); } - const rrc_sys_info_request_r15_ies_s& rrc_sys_info_request_r15() const + ssb_s_& set_ssb() { - assert_choice_type("rrcSystemInfoRequest-r15", type_.to_string(), "criticalExtensions"); - return c.get(); + set(types::ssb); + return c.get(); } - rrc_sys_info_request_r15_ies_s& set_rrc_sys_info_request_r15() + csirs_s_& set_csirs() { - set(types::rrc_sys_info_request_r15); - return c.get(); + set(types::csirs); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; // member variables - crit_exts_c_ crit_exts; + bool ext = false; + bool occasions_present = false; + occasions_s_ occasions; + res_c_ res; + // ... + // group 0 + bool total_nof_ra_preambs_present = false; + uint8_t total_nof_ra_preambs = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -17843,140 +17220,97 @@ struct rrc_sys_info_request_s { void to_json(json_writer& j) const; }; -// UL-CCCH-MessageType ::= CHOICE -struct ul_ccch_msg_type_c { - struct c1_c_ { +// CSI-AssociatedReportConfigInfo ::= SEQUENCE +struct csi_associated_report_cfg_info_s { + struct res_for_ch_c_ { + struct nzp_csi_rs_s_ { + using qcl_info_l_ = bounded_array; + + // member variables + bool qcl_info_present = false; + uint8_t res_set = 1; + qcl_info_l_ qcl_info; + }; struct types_opts { - enum options { rrc_setup_request, rrc_resume_request, rrc_reest_request, rrc_sys_info_request, nulltype } value; + enum options { nzp_csi_rs, csi_ssb_res_set, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - c1_c_() = default; - c1_c_(const c1_c_& other); - c1_c_& operator=(const c1_c_& other); - ~c1_c_() { destroy_(); } + res_for_ch_c_() = default; + res_for_ch_c_(const res_for_ch_c_& other); + res_for_ch_c_& operator=(const res_for_ch_c_& other); + ~res_for_ch_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - rrc_setup_request_s& rrc_setup_request() - { - assert_choice_type("rrcSetupRequest", type_.to_string(), "c1"); - return c.get(); - } - rrc_resume_request_s& rrc_resume_request() - { - assert_choice_type("rrcResumeRequest", type_.to_string(), "c1"); - return c.get(); - } - rrc_reest_request_s& rrc_reest_request() - { - assert_choice_type("rrcReestablishmentRequest", type_.to_string(), "c1"); - return c.get(); - } - rrc_sys_info_request_s& rrc_sys_info_request() - { - assert_choice_type("rrcSystemInfoRequest", type_.to_string(), "c1"); - return c.get(); - } - const rrc_setup_request_s& rrc_setup_request() const - { - assert_choice_type("rrcSetupRequest", type_.to_string(), "c1"); - return c.get(); - } - const rrc_resume_request_s& rrc_resume_request() const - { - assert_choice_type("rrcResumeRequest", type_.to_string(), "c1"); - return c.get(); - } - const rrc_reest_request_s& rrc_reest_request() const + nzp_csi_rs_s_& nzp_csi_rs() { - assert_choice_type("rrcReestablishmentRequest", type_.to_string(), "c1"); - return c.get(); + assert_choice_type("nzp-CSI-RS", type_.to_string(), "resourcesForChannel"); + return c.get(); } - const rrc_sys_info_request_s& rrc_sys_info_request() const + uint8_t& csi_ssb_res_set() { - assert_choice_type("rrcSystemInfoRequest", type_.to_string(), "c1"); - return c.get(); + assert_choice_type("csi-SSB-ResourceSet", type_.to_string(), "resourcesForChannel"); + return c.get(); } - rrc_setup_request_s& set_rrc_setup_request() + const nzp_csi_rs_s_& nzp_csi_rs() const { - set(types::rrc_setup_request); - return c.get(); + assert_choice_type("nzp-CSI-RS", type_.to_string(), "resourcesForChannel"); + return c.get(); } - rrc_resume_request_s& set_rrc_resume_request() + const uint8_t& csi_ssb_res_set() const { - set(types::rrc_resume_request); - return c.get(); + assert_choice_type("csi-SSB-ResourceSet", type_.to_string(), "resourcesForChannel"); + return c.get(); } - rrc_reest_request_s& set_rrc_reest_request() + nzp_csi_rs_s_& set_nzp_csi_rs() { - set(types::rrc_reest_request); - return c.get(); + set(types::nzp_csi_rs); + return c.get(); } - rrc_sys_info_request_s& set_rrc_sys_info_request() + uint8_t& set_csi_ssb_res_set() { - set(types::rrc_sys_info_request); - return c.get(); + set(types::csi_ssb_res_set); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; - struct types_opts { - enum options { c1, msg_class_ext, nulltype } value; - typedef uint8_t number_type; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; + // member variables + bool ext = false; + bool csi_im_res_for_interference_present = false; + bool nzp_csi_rs_res_for_interference_present = false; + uint8_t report_cfg_id = 0; + res_for_ch_c_ res_for_ch; + uint8_t csi_im_res_for_interference = 1; + uint8_t nzp_csi_rs_res_for_interference = 1; + // ... - // choice methods - ul_ccch_msg_type_c() = default; - ul_ccch_msg_type_c(const ul_ccch_msg_type_c& other); - ul_ccch_msg_type_c& operator=(const ul_ccch_msg_type_c& other); - ~ul_ccch_msg_type_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } + // sequence methods SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; - // getters - c1_c_& c1() - { - assert_choice_type("c1", type_.to_string(), "UL-CCCH-MessageType"); - return c.get(); - } - const c1_c_& c1() const - { - assert_choice_type("c1", type_.to_string(), "UL-CCCH-MessageType"); - return c.get(); - } - c1_c_& set_c1() - { - set(types::c1); - return c.get(); - } - -private: - types type_; - choice_buffer_t c; - - void destroy_(); }; -// UL-CCCH-Message ::= SEQUENCE -struct ul_ccch_msg_s { - ul_ccch_msg_type_c msg; +// CSI-AperiodicTriggerState ::= SEQUENCE +struct csi_aperiodic_trigger_state_s { + using associated_report_cfg_info_list_l_ = dyn_array; + + // member variables + bool ext = false; + associated_report_cfg_info_list_l_ associated_report_cfg_info_list; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -17984,34 +17318,42 @@ struct ul_ccch_msg_s { void to_json(json_writer& j) const; }; -// RRCResumeRequest1-IEs ::= SEQUENCE -struct rrc_resume_request1_ies_s { - fixed_bitstring<40> resume_id; - fixed_bitstring<16> resume_mac_i; - resume_cause_e resume_cause; - fixed_bitstring<1> spare; +// CSI-AperiodicTriggerStateList ::= SEQUENCE (SIZE (1..128)) OF CSI-AperiodicTriggerState +using csi_aperiodic_trigger_state_list_l = dyn_array; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; +// CSI-IM-Resource ::= SEQUENCE +struct csi_im_res_s { + struct csi_im_res_elem_pattern_c_ { + struct pattern0_s_ { + struct subcarrier_location_p0_opts { + enum options { s0, s2, s4, s6, s8, s10, nulltype } value; + typedef uint8_t number_type; -// RRCResumeRequest1 ::= SEQUENCE -struct rrc_resume_request1_s { - rrc_resume_request1_ies_s rrc_resume_request1; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated subcarrier_location_p0_e_; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + subcarrier_location_p0_e_ subcarrier_location_p0; + uint8_t symbol_location_p0 = 0; + }; + struct pattern1_s_ { + struct subcarrier_location_p1_opts { + enum options { s0, s4, s8, nulltype } value; + typedef uint8_t number_type; -// UL-CCCH1-MessageType ::= CHOICE -struct ul_ccch1_msg_type_c { - struct c1_c_ { + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated subcarrier_location_p1_e_; + + // member variables + subcarrier_location_p1_e_ subcarrier_location_p1; + uint8_t symbol_location_p1 = 0; + }; struct types_opts { - enum options { rrc_resume_request1, spare3, spare2, spare1, nulltype } value; + enum options { pattern0, pattern1, nulltype } value; typedef uint8_t number_type; std::string to_string() const; @@ -18020,79 +17362,64 @@ struct ul_ccch1_msg_type_c { typedef enumerated types; // choice methods - c1_c_() = default; + csi_im_res_elem_pattern_c_() = default; + csi_im_res_elem_pattern_c_(const csi_im_res_elem_pattern_c_& other); + csi_im_res_elem_pattern_c_& operator=(const csi_im_res_elem_pattern_c_& other); + ~csi_im_res_elem_pattern_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - rrc_resume_request1_s& rrc_resume_request1() + pattern0_s_& pattern0() { - assert_choice_type("rrcResumeRequest1", type_.to_string(), "c1"); - return c; + assert_choice_type("pattern0", type_.to_string(), "csi-IM-ResourceElementPattern"); + return c.get(); } - const rrc_resume_request1_s& rrc_resume_request1() const + pattern1_s_& pattern1() { - assert_choice_type("rrcResumeRequest1", type_.to_string(), "c1"); - return c; + assert_choice_type("pattern1", type_.to_string(), "csi-IM-ResourceElementPattern"); + return c.get(); } - rrc_resume_request1_s& set_rrc_resume_request1() + const pattern0_s_& pattern0() const { - set(types::rrc_resume_request1); - return c; + assert_choice_type("pattern0", type_.to_string(), "csi-IM-ResourceElementPattern"); + return c.get(); + } + const pattern1_s_& pattern1() const + { + assert_choice_type("pattern1", type_.to_string(), "csi-IM-ResourceElementPattern"); + return c.get(); + } + pattern0_s_& set_pattern0() + { + set(types::pattern0); + return c.get(); + } + pattern1_s_& set_pattern1() + { + set(types::pattern1); + return c.get(); } private: - types type_; - rrc_resume_request1_s c; - }; - struct types_opts { - enum options { c1, msg_class_ext, nulltype } value; - typedef uint8_t number_type; + types type_; + choice_buffer_t c; - std::string to_string() const; - uint8_t to_number() const; + void destroy_(); }; - typedef enumerated types; - - // choice methods - ul_ccch1_msg_type_c() = default; - ul_ccch1_msg_type_c(const ul_ccch1_msg_type_c& other); - ul_ccch1_msg_type_c& operator=(const ul_ccch1_msg_type_c& other); - ~ul_ccch1_msg_type_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - c1_c_& c1() - { - assert_choice_type("c1", type_.to_string(), "UL-CCCH1-MessageType"); - return c.get(); - } - const c1_c_& c1() const - { - assert_choice_type("c1", type_.to_string(), "UL-CCCH1-MessageType"); - return c.get(); - } - c1_c_& set_c1() - { - set(types::c1); - return c.get(); - } -private: - types type_; - choice_buffer_t c; - - void destroy_(); -}; - -// UL-CCCH1-Message ::= SEQUENCE -struct ul_ccch1_msg_s { - ul_ccch1_msg_type_c msg; + // member variables + bool ext = false; + bool csi_im_res_elem_pattern_present = false; + bool freq_band_present = false; + bool periodicity_and_offset_present = false; + uint8_t csi_im_res_id = 0; + csi_im_res_elem_pattern_c_ csi_im_res_elem_pattern; + csi_freq_occupation_s freq_band; + csi_res_periodicity_and_offset_c periodicity_and_offset; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -18100,14 +17427,15 @@ struct ul_ccch1_msg_s { void to_json(json_writer& j) const; }; -// MeasQuantityResults ::= SEQUENCE -struct meas_quant_results_s { - bool rsrp_present = false; - bool rsrq_present = false; - bool sinr_present = false; - uint8_t rsrp = 0; - uint8_t rsrq = 0; - uint8_t sinr = 0; +// CSI-IM-ResourceSet ::= SEQUENCE +struct csi_im_res_set_s { + using csi_im_res_l_ = bounded_array; + + // member variables + bool ext = false; + uint8_t csi_im_res_set_id = 0; + csi_im_res_l_ csi_im_res; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -18115,71 +17443,203 @@ struct meas_quant_results_s { void to_json(json_writer& j) const; }; -// PLMN-Identity-EUTRA-5GC ::= CHOICE -struct plmn_id_eutra_minus5_gc_c { +// CSI-ReportPeriodicityAndOffset ::= CHOICE +struct csi_report_periodicity_and_offset_c { struct types_opts { - enum options { plmn_id_eutra_minus5_gc, plmn_idx, nulltype } value; - typedef int8_t number_type; + enum options { + slots4, + slots5, + slots8, + slots10, + slots16, + slots20, + slots40, + slots80, + slots160, + slots320, + nulltype + } value; + typedef uint16_t number_type; std::string to_string() const; - int8_t to_number() const; + uint16_t to_number() const; }; typedef enumerated types; // choice methods - plmn_id_eutra_minus5_gc_c() = default; - plmn_id_eutra_minus5_gc_c(const plmn_id_eutra_minus5_gc_c& other); - plmn_id_eutra_minus5_gc_c& operator=(const plmn_id_eutra_minus5_gc_c& other); - ~plmn_id_eutra_minus5_gc_c() { destroy_(); } + csi_report_periodicity_and_offset_c() = default; + csi_report_periodicity_and_offset_c(const csi_report_periodicity_and_offset_c& other); + csi_report_periodicity_and_offset_c& operator=(const csi_report_periodicity_and_offset_c& other); + ~csi_report_periodicity_and_offset_c() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - plmn_id_s& plmn_id_eutra_minus5_gc() + uint8_t& slots4() { - assert_choice_type("plmn-Identity-EUTRA-5GC", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); - return c.get(); + assert_choice_type("slots4", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); } - uint8_t& plmn_idx() + uint8_t& slots5() { - assert_choice_type("plmn-index", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); + assert_choice_type("slots5", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); return c.get(); } - const plmn_id_s& plmn_id_eutra_minus5_gc() const + uint8_t& slots8() { - assert_choice_type("plmn-Identity-EUTRA-5GC", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); - return c.get(); + assert_choice_type("slots8", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); } - const uint8_t& plmn_idx() const + uint8_t& slots10() { - assert_choice_type("plmn-index", type_.to_string(), "PLMN-Identity-EUTRA-5GC"); + assert_choice_type("slots10", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); return c.get(); } - plmn_id_s& set_plmn_id_eutra_minus5_gc() + uint8_t& slots16() { - set(types::plmn_id_eutra_minus5_gc); - return c.get(); + assert_choice_type("slots16", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); } - uint8_t& set_plmn_idx() + uint8_t& slots20() { - set(types::plmn_idx); + assert_choice_type("slots20", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + uint8_t& slots40() + { + assert_choice_type("slots40", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + uint8_t& slots80() + { + assert_choice_type("slots80", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + uint8_t& slots160() + { + assert_choice_type("slots160", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + uint16_t& slots320() + { + assert_choice_type("slots320", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots4() const + { + assert_choice_type("slots4", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots5() const + { + assert_choice_type("slots5", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots8() const + { + assert_choice_type("slots8", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots10() const + { + assert_choice_type("slots10", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots16() const + { + assert_choice_type("slots16", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots20() const + { + assert_choice_type("slots20", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots40() const + { + assert_choice_type("slots40", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots80() const + { + assert_choice_type("slots80", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint8_t& slots160() const + { + assert_choice_type("slots160", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + const uint16_t& slots320() const + { + assert_choice_type("slots320", type_.to_string(), "CSI-ReportPeriodicityAndOffset"); + return c.get(); + } + uint8_t& set_slots4() + { + set(types::slots4); + return c.get(); + } + uint8_t& set_slots5() + { + set(types::slots5); + return c.get(); + } + uint8_t& set_slots8() + { + set(types::slots8); + return c.get(); + } + uint8_t& set_slots10() + { + set(types::slots10); + return c.get(); + } + uint8_t& set_slots16() + { + set(types::slots16); return c.get(); } + uint8_t& set_slots20() + { + set(types::slots20); + return c.get(); + } + uint8_t& set_slots40() + { + set(types::slots40); + return c.get(); + } + uint8_t& set_slots80() + { + set(types::slots80); + return c.get(); + } + uint8_t& set_slots160() + { + set(types::slots160); + return c.get(); + } + uint16_t& set_slots320() + { + set(types::slots320); + return c.get(); + } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; -// ResultsPerCSI-RS-Index ::= SEQUENCE -struct results_per_csi_rs_idx_s { - bool csi_rs_results_present = false; - uint8_t csi_rs_idx = 0; - meas_quant_results_s csi_rs_results; +// CSI-SemiPersistentOnPUSCH-TriggerState ::= SEQUENCE +struct csi_semi_persistent_on_pusch_trigger_state_s { + bool ext = false; + uint8_t associated_report_cfg_info = 0; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -18187,268 +17647,940 @@ struct results_per_csi_rs_idx_s { void to_json(json_writer& j) const; }; -// ResultsPerSSB-Index ::= SEQUENCE -struct results_per_ssb_idx_s { - bool ssb_results_present = false; - uint8_t ssb_idx = 0; - meas_quant_results_s ssb_results; +// CodebookConfig ::= SEQUENCE +struct codebook_cfg_s { + struct codebook_type_c_ { + struct type1_s_ { + struct sub_type_c_ { + struct type_i_single_panel_s_ { + struct nr_of_ant_ports_c_ { + struct two_s_ { + fixed_bitstring<6> two_tx_codebook_subset_restrict; + }; + struct more_than_two_s_ { + struct n1_n2_c_ { + struct types_opts { + enum options { + two_one_type_i_single_panel_restrict, + two_two_type_i_single_panel_restrict, + four_one_type_i_single_panel_restrict, + three_two_type_i_single_panel_restrict, + six_one_type_i_single_panel_restrict, + four_two_type_i_single_panel_restrict, + eight_one_type_i_single_panel_restrict, + four_three_type_i_single_panel_restrict, + six_two_type_i_single_panel_restrict, + twelve_one_type_i_single_panel_restrict, + four_four_type_i_single_panel_restrict, + eight_two_type_i_single_panel_restrict, + sixteen_one_type_i_single_panel_restrict, + nulltype + } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + n1_n2_c_() = default; + n1_n2_c_(const n1_n2_c_& other); + n1_n2_c_& operator=(const n1_n2_c_& other); + ~n1_n2_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<8>& two_one_type_i_single_panel_restrict() + { + assert_choice_type("two-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<64>& two_two_type_i_single_panel_restrict() + { + assert_choice_type("two-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<16>& four_one_type_i_single_panel_restrict() + { + assert_choice_type("four-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<96>& three_two_type_i_single_panel_restrict() + { + assert_choice_type("three-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<24>& six_one_type_i_single_panel_restrict() + { + assert_choice_type("six-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<128>& four_two_type_i_single_panel_restrict() + { + assert_choice_type("four-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<32>& eight_one_type_i_single_panel_restrict() + { + assert_choice_type("eight-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<192>& four_three_type_i_single_panel_restrict() + { + assert_choice_type("four-three-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<192>& six_two_type_i_single_panel_restrict() + { + assert_choice_type("six-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<48>& twelve_one_type_i_single_panel_restrict() + { + assert_choice_type("twelve-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<256>& four_four_type_i_single_panel_restrict() + { + assert_choice_type("four-four-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<256>& eight_two_type_i_single_panel_restrict() + { + assert_choice_type("eight-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<64>& sixteen_one_type_i_single_panel_restrict() + { + assert_choice_type("sixteen-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<8>& two_one_type_i_single_panel_restrict() const + { + assert_choice_type("two-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<64>& two_two_type_i_single_panel_restrict() const + { + assert_choice_type("two-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<16>& four_one_type_i_single_panel_restrict() const + { + assert_choice_type("four-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<96>& three_two_type_i_single_panel_restrict() const + { + assert_choice_type("three-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<24>& six_one_type_i_single_panel_restrict() const + { + assert_choice_type("six-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<128>& four_two_type_i_single_panel_restrict() const + { + assert_choice_type("four-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<32>& eight_one_type_i_single_panel_restrict() const + { + assert_choice_type("eight-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<192>& four_three_type_i_single_panel_restrict() const + { + assert_choice_type("four-three-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<192>& six_two_type_i_single_panel_restrict() const + { + assert_choice_type("six-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<48>& twelve_one_type_i_single_panel_restrict() const + { + assert_choice_type("twelve-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<256>& four_four_type_i_single_panel_restrict() const + { + assert_choice_type("four-four-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<256>& eight_two_type_i_single_panel_restrict() const + { + assert_choice_type("eight-two-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + const fixed_bitstring<64>& sixteen_one_type_i_single_panel_restrict() const + { + assert_choice_type("sixteen-one-TypeI-SinglePanel-Restriction", type_.to_string(), "n1-n2"); + return c.get >(); + } + fixed_bitstring<8>& set_two_one_type_i_single_panel_restrict() + { + set(types::two_one_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<64>& set_two_two_type_i_single_panel_restrict() + { + set(types::two_two_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<16>& set_four_one_type_i_single_panel_restrict() + { + set(types::four_one_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<96>& set_three_two_type_i_single_panel_restrict() + { + set(types::three_two_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<24>& set_six_one_type_i_single_panel_restrict() + { + set(types::six_one_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<128>& set_four_two_type_i_single_panel_restrict() + { + set(types::four_two_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<32>& set_eight_one_type_i_single_panel_restrict() + { + set(types::eight_one_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<192>& set_four_three_type_i_single_panel_restrict() + { + set(types::four_three_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<192>& set_six_two_type_i_single_panel_restrict() + { + set(types::six_two_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<48>& set_twelve_one_type_i_single_panel_restrict() + { + set(types::twelve_one_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<256>& set_four_four_type_i_single_panel_restrict() + { + set(types::four_four_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<256>& set_eight_two_type_i_single_panel_restrict() + { + set(types::eight_two_type_i_single_panel_restrict); + return c.get >(); + } + fixed_bitstring<64>& set_sixteen_one_type_i_single_panel_restrict() + { + set(types::sixteen_one_type_i_single_panel_restrict); + return c.get >(); + } + + private: + types type_; + choice_buffer_t > c; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + void destroy_(); + }; -// CGI-Info ::= SEQUENCE -struct cgi_info_s { - struct no_sib1_s_ { - uint8_t ssb_subcarrier_offset = 0; - pdcch_cfg_sib1_s pdcch_cfg_sib1; - }; + // member variables + bool type_i_single_panel_codebook_subset_restrict_i2_present = false; + n1_n2_c_ n1_n2; + fixed_bitstring<16> type_i_single_panel_codebook_subset_restrict_i2; + }; + struct types_opts { + enum options { two, more_than_two, nulltype } value; + typedef uint8_t number_type; - // member variables - bool ext = false; - bool plmn_id_info_list_present = false; - bool freq_band_list_present = false; - bool no_sib1_present = false; - plmn_id_info_list_l plmn_id_info_list; - multi_freq_band_list_nr_l freq_band_list; - no_sib1_s_ no_sib1; - // ... + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // choice methods + nr_of_ant_ports_c_() = default; + nr_of_ant_ports_c_(const nr_of_ant_ports_c_& other); + nr_of_ant_ports_c_& operator=(const nr_of_ant_ports_c_& other); + ~nr_of_ant_ports_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + two_s_& two() + { + assert_choice_type("two", type_.to_string(), "nrOfAntennaPorts"); + return c.get(); + } + more_than_two_s_& more_than_two() + { + assert_choice_type("moreThanTwo", type_.to_string(), "nrOfAntennaPorts"); + return c.get(); + } + const two_s_& two() const + { + assert_choice_type("two", type_.to_string(), "nrOfAntennaPorts"); + return c.get(); + } + const more_than_two_s_& more_than_two() const + { + assert_choice_type("moreThanTwo", type_.to_string(), "nrOfAntennaPorts"); + return c.get(); + } + two_s_& set_two() + { + set(types::two); + return c.get(); + } + more_than_two_s_& set_more_than_two() + { + set(types::more_than_two); + return c.get(); + } -// CellIdentity-EUTRA-5GC ::= CHOICE -struct cell_id_eutra_minus5_gc_c { - struct types_opts { - enum options { cell_id_eutra, cell_id_idx, nulltype } value; + private: + types type_; + choice_buffer_t c; - std::string to_string() const; - }; - typedef enumerated types; + void destroy_(); + }; - // choice methods - cell_id_eutra_minus5_gc_c() = default; - cell_id_eutra_minus5_gc_c(const cell_id_eutra_minus5_gc_c& other); - cell_id_eutra_minus5_gc_c& operator=(const cell_id_eutra_minus5_gc_c& other); - ~cell_id_eutra_minus5_gc_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<28>& cell_id_eutra() - { - assert_choice_type("cellIdentity-EUTRA", type_.to_string(), "CellIdentity-EUTRA-5GC"); - return c.get >(); - } - uint8_t& cell_id_idx() - { - assert_choice_type("cellId-index", type_.to_string(), "CellIdentity-EUTRA-5GC"); - return c.get(); - } - const fixed_bitstring<28>& cell_id_eutra() const - { - assert_choice_type("cellIdentity-EUTRA", type_.to_string(), "CellIdentity-EUTRA-5GC"); - return c.get >(); - } - const uint8_t& cell_id_idx() const - { - assert_choice_type("cellId-index", type_.to_string(), "CellIdentity-EUTRA-5GC"); - return c.get(); - } - fixed_bitstring<28>& set_cell_id_eutra() - { - set(types::cell_id_eutra); - return c.get >(); - } - uint8_t& set_cell_id_idx() - { - set(types::cell_id_idx); - return c.get(); - } + // member variables + nr_of_ant_ports_c_ nr_of_ant_ports; + fixed_bitstring<8> type_i_single_panel_ri_restrict; + }; + struct type_i_multi_panel_s_ { + struct ng_n1_n2_c_ { + struct types_opts { + enum options { + two_two_one_type_i_multi_panel_restrict, + two_four_one_type_i_multi_panel_restrict, + four_two_one_type_i_multi_panel_restrict, + two_two_two_type_i_multi_panel_restrict, + two_eight_one_type_i_multi_panel_restrict, + four_four_one_type_i_multi_panel_restrict, + two_four_two_type_i_multi_panel_restrict, + four_two_two_type_i_multi_panel_restrict, + nulltype + } value; -private: - types type_; - choice_buffer_t > c; + std::string to_string() const; + }; + typedef enumerated types; - void destroy_(); -}; + // choice methods + ng_n1_n2_c_() = default; + ng_n1_n2_c_(const ng_n1_n2_c_& other); + ng_n1_n2_c_& operator=(const ng_n1_n2_c_& other); + ~ng_n1_n2_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<8>& two_two_one_type_i_multi_panel_restrict() + { + assert_choice_type("two-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<16>& two_four_one_type_i_multi_panel_restrict() + { + assert_choice_type("two-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<8>& four_two_one_type_i_multi_panel_restrict() + { + assert_choice_type("four-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<64>& two_two_two_type_i_multi_panel_restrict() + { + assert_choice_type("two-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<32>& two_eight_one_type_i_multi_panel_restrict() + { + assert_choice_type("two-eight-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<16>& four_four_one_type_i_multi_panel_restrict() + { + assert_choice_type("four-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<128>& two_four_two_type_i_multi_panel_restrict() + { + assert_choice_type("two-four-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<64>& four_two_two_type_i_multi_panel_restrict() + { + assert_choice_type("four-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<8>& two_two_one_type_i_multi_panel_restrict() const + { + assert_choice_type("two-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<16>& two_four_one_type_i_multi_panel_restrict() const + { + assert_choice_type("two-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<8>& four_two_one_type_i_multi_panel_restrict() const + { + assert_choice_type("four-two-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<64>& two_two_two_type_i_multi_panel_restrict() const + { + assert_choice_type("two-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<32>& two_eight_one_type_i_multi_panel_restrict() const + { + assert_choice_type("two-eight-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<16>& four_four_one_type_i_multi_panel_restrict() const + { + assert_choice_type("four-four-one-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<128>& two_four_two_type_i_multi_panel_restrict() const + { + assert_choice_type("two-four-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + const fixed_bitstring<64>& four_two_two_type_i_multi_panel_restrict() const + { + assert_choice_type("four-two-two-TypeI-MultiPanel-Restriction", type_.to_string(), "ng-n1-n2"); + return c.get >(); + } + fixed_bitstring<8>& set_two_two_one_type_i_multi_panel_restrict() + { + set(types::two_two_one_type_i_multi_panel_restrict); + return c.get >(); + } + fixed_bitstring<16>& set_two_four_one_type_i_multi_panel_restrict() + { + set(types::two_four_one_type_i_multi_panel_restrict); + return c.get >(); + } + fixed_bitstring<8>& set_four_two_one_type_i_multi_panel_restrict() + { + set(types::four_two_one_type_i_multi_panel_restrict); + return c.get >(); + } + fixed_bitstring<64>& set_two_two_two_type_i_multi_panel_restrict() + { + set(types::two_two_two_type_i_multi_panel_restrict); + return c.get >(); + } + fixed_bitstring<32>& set_two_eight_one_type_i_multi_panel_restrict() + { + set(types::two_eight_one_type_i_multi_panel_restrict); + return c.get >(); + } + fixed_bitstring<16>& set_four_four_one_type_i_multi_panel_restrict() + { + set(types::four_four_one_type_i_multi_panel_restrict); + return c.get >(); + } + fixed_bitstring<128>& set_two_four_two_type_i_multi_panel_restrict() + { + set(types::two_four_two_type_i_multi_panel_restrict); + return c.get >(); + } + fixed_bitstring<64>& set_four_two_two_type_i_multi_panel_restrict() + { + set(types::four_two_two_type_i_multi_panel_restrict); + return c.get >(); + } -// PLMN-IdentityList-EUTRA-5GC ::= SEQUENCE (SIZE (1..12)) OF PLMN-Identity-EUTRA-5GC -using plmn_id_list_eutra_minus5_gc_l = dyn_array; + private: + types type_; + choice_buffer_t > c; -// PLMN-IdentityList-EUTRA-EPC ::= SEQUENCE (SIZE (1..12)) OF PLMN-Identity -using plmn_id_list_eutra_epc_l = dyn_array; + void destroy_(); + }; -// ResultsPerCSI-RS-IndexList ::= SEQUENCE (SIZE (1..64)) OF ResultsPerCSI-RS-Index -using results_per_csi_rs_idx_list_l = dyn_array; + // member variables + ng_n1_n2_c_ ng_n1_n2; + fixed_bitstring<4> ri_restrict; + }; + struct types_opts { + enum options { type_i_single_panel, type_i_multi_panel, nulltype } value; -// ResultsPerSSB-IndexList ::= SEQUENCE (SIZE (1..64)) OF ResultsPerSSB-Index -using results_per_ssb_idx_list_l = dyn_array; + std::string to_string() const; + }; + typedef enumerated types; -// CellAccessRelatedInfo-EUTRA-5GC ::= SEQUENCE -struct cell_access_related_info_eutra_minus5_gc_s { - bool ranac_minus5gc_present = false; - plmn_id_list_eutra_minus5_gc_l plmn_id_list_eutra_minus5gc; - fixed_bitstring<24> tac_eutra_minus5gc; - uint16_t ranac_minus5gc = 0; - cell_id_eutra_minus5_gc_c cell_id_eutra_minus5gc; + // choice methods + sub_type_c_() = default; + sub_type_c_(const sub_type_c_& other); + sub_type_c_& operator=(const sub_type_c_& other); + ~sub_type_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + type_i_single_panel_s_& type_i_single_panel() + { + assert_choice_type("typeI-SinglePanel", type_.to_string(), "subType"); + return c.get(); + } + type_i_multi_panel_s_& type_i_multi_panel() + { + assert_choice_type("typeI-MultiPanel", type_.to_string(), "subType"); + return c.get(); + } + const type_i_single_panel_s_& type_i_single_panel() const + { + assert_choice_type("typeI-SinglePanel", type_.to_string(), "subType"); + return c.get(); + } + const type_i_multi_panel_s_& type_i_multi_panel() const + { + assert_choice_type("typeI-MultiPanel", type_.to_string(), "subType"); + return c.get(); + } + type_i_single_panel_s_& set_type_i_single_panel() + { + set(types::type_i_single_panel); + return c.get(); + } + type_i_multi_panel_s_& set_type_i_multi_panel() + { + set(types::type_i_multi_panel); + return c.get(); + } - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + private: + types type_; + choice_buffer_t c; -// CellAccessRelatedInfo-EUTRA-EPC ::= SEQUENCE -struct cell_access_related_info_eutra_epc_s { - plmn_id_list_eutra_epc_l plmn_id_list_eutra_epc; - fixed_bitstring<16> tac_eutra_epc; - fixed_bitstring<28> cell_id_eutra_epc; + void destroy_(); + }; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + sub_type_c_ sub_type; + uint8_t codebook_mode = 1; + }; + struct type2_s_ { + struct sub_type_c_ { + struct type_ii_s_ { + struct n1_n2_codebook_subset_restrict_c_ { + struct types_opts { + enum options { + two_one, + two_two, + four_one, + three_two, + six_one, + four_two, + eight_one, + four_three, + six_two, + twelve_one, + four_four, + eight_two, + sixteen_one, + nulltype + } value; -// MeasQuantityResultsEUTRA ::= SEQUENCE -struct meas_quant_results_eutra_s { - bool rsrp_present = false; - bool rsrq_present = false; - bool sinr_present = false; - uint8_t rsrp = 0; - uint8_t rsrq = 0; - uint8_t sinr = 0; + std::string to_string() const; + }; + typedef enumerated types; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // choice methods + n1_n2_codebook_subset_restrict_c_() = default; + n1_n2_codebook_subset_restrict_c_(const n1_n2_codebook_subset_restrict_c_& other); + n1_n2_codebook_subset_restrict_c_& operator=(const n1_n2_codebook_subset_restrict_c_& other); + ~n1_n2_codebook_subset_restrict_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<16>& two_one() + { + assert_choice_type("two-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<43>& two_two() + { + assert_choice_type("two-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<32>& four_one() + { + assert_choice_type("four-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<59>& three_two() + { + assert_choice_type("three-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<48>& six_one() + { + assert_choice_type("six-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<75>& four_two() + { + assert_choice_type("four-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<64>& eight_one() + { + assert_choice_type("eight-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<107>& four_three() + { + assert_choice_type("four-three", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<107>& six_two() + { + assert_choice_type("six-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<96>& twelve_one() + { + assert_choice_type("twelve-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<139>& four_four() + { + assert_choice_type("four-four", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<139>& eight_two() + { + assert_choice_type("eight-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<128>& sixteen_one() + { + assert_choice_type("sixteen-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<16>& two_one() const + { + assert_choice_type("two-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<43>& two_two() const + { + assert_choice_type("two-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<32>& four_one() const + { + assert_choice_type("four-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<59>& three_two() const + { + assert_choice_type("three-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<48>& six_one() const + { + assert_choice_type("six-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<75>& four_two() const + { + assert_choice_type("four-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<64>& eight_one() const + { + assert_choice_type("eight-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<107>& four_three() const + { + assert_choice_type("four-three", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<107>& six_two() const + { + assert_choice_type("six-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<96>& twelve_one() const + { + assert_choice_type("twelve-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<139>& four_four() const + { + assert_choice_type("four-four", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<139>& eight_two() const + { + assert_choice_type("eight-two", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + const fixed_bitstring<128>& sixteen_one() const + { + assert_choice_type("sixteen-one", type_.to_string(), "n1-n2-codebookSubsetRestriction"); + return c.get >(); + } + fixed_bitstring<16>& set_two_one() + { + set(types::two_one); + return c.get >(); + } + fixed_bitstring<43>& set_two_two() + { + set(types::two_two); + return c.get >(); + } + fixed_bitstring<32>& set_four_one() + { + set(types::four_one); + return c.get >(); + } + fixed_bitstring<59>& set_three_two() + { + set(types::three_two); + return c.get >(); + } + fixed_bitstring<48>& set_six_one() + { + set(types::six_one); + return c.get >(); + } + fixed_bitstring<75>& set_four_two() + { + set(types::four_two); + return c.get >(); + } + fixed_bitstring<64>& set_eight_one() + { + set(types::eight_one); + return c.get >(); + } + fixed_bitstring<107>& set_four_three() + { + set(types::four_three); + return c.get >(); + } + fixed_bitstring<107>& set_six_two() + { + set(types::six_two); + return c.get >(); + } + fixed_bitstring<96>& set_twelve_one() + { + set(types::twelve_one); + return c.get >(); + } + fixed_bitstring<139>& set_four_four() + { + set(types::four_four); + return c.get >(); + } + fixed_bitstring<139>& set_eight_two() + { + set(types::eight_two); + return c.get >(); + } + fixed_bitstring<128>& set_sixteen_one() + { + set(types::sixteen_one); + return c.get >(); + } -// MeasResultNR ::= SEQUENCE -struct meas_result_nr_s { - struct meas_result_s_ { - struct cell_results_s_ { - bool results_ssb_cell_present = false; - bool results_csi_rs_cell_present = false; - meas_quant_results_s results_ssb_cell; - meas_quant_results_s results_csi_rs_cell; - }; - struct rs_idx_results_s_ { - bool results_ssb_idxes_present = false; - bool results_csi_rs_idxes_present = false; - results_per_ssb_idx_list_l results_ssb_idxes; - results_per_csi_rs_idx_list_l results_csi_rs_idxes; - }; + private: + types type_; + choice_buffer_t > c; - // member variables - bool rs_idx_results_present = false; - cell_results_s_ cell_results; - rs_idx_results_s_ rs_idx_results; - }; + void destroy_(); + }; - // member variables - bool ext = false; - bool pci_present = false; - uint16_t pci = 0; - meas_result_s_ meas_result; - // ... - // group 0 - copy_ptr cgi_info; + // member variables + n1_n2_codebook_subset_restrict_c_ n1_n2_codebook_subset_restrict; + fixed_bitstring<2> type_ii_ri_restrict; + }; + struct type_ii_port_sel_s_ { + struct port_sel_sampling_size_opts { + enum options { n1, n2, n3, n4, nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated port_sel_sampling_size_e_; -// MultiBandInfoListEUTRA ::= SEQUENCE (SIZE (1..8)) OF INTEGER (1..256) -using multi_band_info_list_eutra_l = bounded_array; + // member variables + bool port_sel_sampling_size_present = false; + port_sel_sampling_size_e_ port_sel_sampling_size; + fixed_bitstring<2> type_ii_port_sel_ri_restrict; + }; + struct types_opts { + enum options { type_ii, type_ii_port_sel, nulltype } value; -// UplinkTxDirectCurrentBWP ::= SEQUENCE -struct ul_tx_direct_current_bwp_s { - uint8_t bwp_id = 0; - bool shift7dot5k_hz = false; - uint16_t tx_direct_current_location = 0; + std::string to_string() const; + }; + typedef enumerated types; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // choice methods + sub_type_c_() = default; + sub_type_c_(const sub_type_c_& other); + sub_type_c_& operator=(const sub_type_c_& other); + ~sub_type_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + type_ii_s_& type_ii() + { + assert_choice_type("typeII", type_.to_string(), "subType"); + return c.get(); + } + type_ii_port_sel_s_& type_ii_port_sel() + { + assert_choice_type("typeII-PortSelection", type_.to_string(), "subType"); + return c.get(); + } + const type_ii_s_& type_ii() const + { + assert_choice_type("typeII", type_.to_string(), "subType"); + return c.get(); + } + const type_ii_port_sel_s_& type_ii_port_sel() const + { + assert_choice_type("typeII-PortSelection", type_.to_string(), "subType"); + return c.get(); + } + type_ii_s_& set_type_ii() + { + set(types::type_ii); + return c.get(); + } + type_ii_port_sel_s_& set_type_ii_port_sel() + { + set(types::type_ii_port_sel); + return c.get(); + } -// EUTRA-RSTD-Info ::= SEQUENCE -struct eutra_rstd_info_s { - bool ext = false; - uint32_t carrier_freq = 0; - uint8_t meas_prs_offset = 0; - // ... + private: + types type_; + choice_buffer_t c; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + void destroy_(); + }; + struct phase_alphabet_size_opts { + enum options { n4, n8, nulltype } value; + typedef uint8_t number_type; -// MIMO-LayersDL ::= ENUMERATED -struct mimo_layers_dl_opts { - enum options { two_layers, four_layers, eight_layers, nulltype } value; - typedef uint8_t number_type; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated phase_alphabet_size_e_; + struct nof_beams_opts { + enum options { two, three, four, nulltype } value; + typedef uint8_t number_type; - std::string to_string() const; - uint8_t to_number() const; -}; -typedef enumerated mimo_layers_dl_e; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated nof_beams_e_; -// MIMO-LayersUL ::= ENUMERATED -struct mimo_layers_ul_opts { - enum options { one_layer, two_layers, four_layers, nulltype } value; - typedef uint8_t number_type; + // member variables + sub_type_c_ sub_type; + phase_alphabet_size_e_ phase_alphabet_size; + bool subband_amplitude = false; + nof_beams_e_ nof_beams; + }; + struct types_opts { + enum options { type1, type2, nulltype } value; + typedef uint8_t number_type; - std::string to_string() const; - uint8_t to_number() const; -}; -typedef enumerated mimo_layers_ul_e; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; -// MeasResultEUTRA ::= SEQUENCE -struct meas_result_eutra_s { - struct cgi_info_s_ { - struct cgi_info_epc_s_ { - using cgi_info_epc_list_l_ = dyn_array; + // choice methods + codebook_type_c_() = default; + codebook_type_c_(const codebook_type_c_& other); + codebook_type_c_& operator=(const codebook_type_c_& other); + ~codebook_type_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + type1_s_& type1() + { + assert_choice_type("type1", type_.to_string(), "codebookType"); + return c.get(); + } + type2_s_& type2() + { + assert_choice_type("type2", type_.to_string(), "codebookType"); + return c.get(); + } + const type1_s_& type1() const + { + assert_choice_type("type1", type_.to_string(), "codebookType"); + return c.get(); + } + const type2_s_& type2() const + { + assert_choice_type("type2", type_.to_string(), "codebookType"); + return c.get(); + } + type1_s_& set_type1() + { + set(types::type1); + return c.get(); + } + type2_s_& set_type2() + { + set(types::type2); + return c.get(); + } - // member variables - bool cgi_info_epc_list_present = false; - cell_access_related_info_eutra_epc_s cgi_info_epc_legacy; - cgi_info_epc_list_l_ cgi_info_epc_list; - }; - using cgi_info_minus5_gc_l_ = dyn_array; + private: + types type_; + choice_buffer_t c; - // member variables - bool cgi_info_epc_present = false; - bool cgi_info_minus5_gc_present = false; - bool multi_band_info_list_present = false; - bool freq_band_ind_prio_present = false; - cgi_info_epc_s_ cgi_info_epc; - cgi_info_minus5_gc_l_ cgi_info_minus5_gc; - uint16_t freq_band_ind = 1; - multi_band_info_list_eutra_l multi_band_info_list; + void destroy_(); }; // member variables - bool ext = false; - bool cgi_info_present = false; - uint16_t eutra_pci = 0; - meas_quant_results_eutra_s meas_result; - cgi_info_s_ cgi_info; - // ... + codebook_type_c_ codebook_type; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -18456,14 +18588,10 @@ struct meas_result_eutra_s { void to_json(json_writer& j) const; }; -// MeasResultServMO ::= SEQUENCE -struct meas_result_serv_mo_s { - bool ext = false; - bool meas_result_best_neigh_cell_present = false; - uint8_t serv_cell_id = 0; - meas_result_nr_s meas_result_serving_cell; - meas_result_nr_s meas_result_best_neigh_cell; - // ... +// PUCCH-CSI-Resource ::= SEQUENCE +struct pucch_csi_res_s { + uint8_t ul_bw_part_id = 0; + uint8_t pucch_res = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -18471,496 +18599,771 @@ struct meas_result_serv_mo_s { void to_json(json_writer& j) const; }; -// ReducedAggregatedBandwidth ::= ENUMERATED -struct reduced_aggregated_bw_opts { - enum options { - mhz0, - mhz10, - mhz20, - mhz30, - mhz40, - mhz50, - mhz60, - mhz80, - mhz100, - mhz200, - mhz300, - mhz400, - nulltype - } value; - typedef uint16_t number_type; - - std::string to_string() const; - uint16_t to_number() const; -}; -typedef enumerated reduced_aggregated_bw_e; +// PortIndexFor8Ranks ::= CHOICE +struct port_idx_for8_ranks_c { + struct port_idx8_s_ { + using rank2_minus8_l_ = std::array; + using rank3_minus8_l_ = std::array; + using rank4_minus8_l_ = std::array; + using rank5_minus8_l_ = std::array; + using rank6_minus8_l_ = std::array; + using rank7_minus8_l_ = std::array; + using rank8_minus8_l_ = std::array; -// UplinkTxDirectCurrentCell ::= SEQUENCE -struct ul_tx_direct_current_cell_s { - using ul_direct_current_bwp_l_ = dyn_array; + // member variables + bool rank1_minus8_present = false; + bool rank2_minus8_present = false; + bool rank3_minus8_present = false; + bool rank4_minus8_present = false; + bool rank5_minus8_present = false; + bool rank6_minus8_present = false; + bool rank7_minus8_present = false; + bool rank8_minus8_present = false; + uint8_t rank1_minus8 = 0; + rank2_minus8_l_ rank2_minus8; + rank3_minus8_l_ rank3_minus8; + rank4_minus8_l_ rank4_minus8; + rank5_minus8_l_ rank5_minus8; + rank6_minus8_l_ rank6_minus8; + rank7_minus8_l_ rank7_minus8; + rank8_minus8_l_ rank8_minus8; + }; + struct port_idx4_s_ { + using rank2_minus4_l_ = std::array; + using rank3_minus4_l_ = std::array; + using rank4_minus4_l_ = std::array; - // member variables - bool ext = false; - uint8_t serv_cell_idx = 0; - ul_direct_current_bwp_l_ ul_direct_current_bwp; - // ... + // member variables + bool rank1_minus4_present = false; + bool rank2_minus4_present = false; + bool rank3_minus4_present = false; + bool rank4_minus4_present = false; + uint8_t rank1_minus4 = 0; + rank2_minus4_l_ rank2_minus4; + rank3_minus4_l_ rank3_minus4; + rank4_minus4_l_ rank4_minus4; + }; + struct port_idx2_s_ { + using rank2_minus2_l_ = std::array; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + bool rank1_minus2_present = false; + bool rank2_minus2_present = false; + uint8_t rank1_minus2 = 0; + rank2_minus2_l_ rank2_minus2; + }; + struct types_opts { + enum options { port_idx8, port_idx4, port_idx2, port_idx1, nulltype } value; + typedef uint8_t number_type; -// DRB-CountInfo ::= SEQUENCE -struct drb_count_info_s { - uint8_t drb_id = 1; - uint64_t count_ul = 0; - uint64_t count_dl = 0; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; - // sequence methods + // choice methods + port_idx_for8_ranks_c() = default; + port_idx_for8_ranks_c(const port_idx_for8_ranks_c& other); + port_idx_for8_ranks_c& operator=(const port_idx_for8_ranks_c& other); + ~port_idx_for8_ranks_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; -}; - -// EUTRA-RSTD-InfoList ::= SEQUENCE (SIZE (1..3)) OF EUTRA-RSTD-Info -using eutra_rstd_info_list_l = dyn_array; - -// MeasResultListEUTRA ::= SEQUENCE (SIZE (1..8)) OF MeasResultEUTRA -using meas_result_list_eutra_l = dyn_array; + // getters + port_idx8_s_& port_idx8() + { + assert_choice_type("portIndex8", type_.to_string(), "PortIndexFor8Ranks"); + return c.get(); + } + port_idx4_s_& port_idx4() + { + assert_choice_type("portIndex4", type_.to_string(), "PortIndexFor8Ranks"); + return c.get(); + } + port_idx2_s_& port_idx2() + { + assert_choice_type("portIndex2", type_.to_string(), "PortIndexFor8Ranks"); + return c.get(); + } + const port_idx8_s_& port_idx8() const + { + assert_choice_type("portIndex8", type_.to_string(), "PortIndexFor8Ranks"); + return c.get(); + } + const port_idx4_s_& port_idx4() const + { + assert_choice_type("portIndex4", type_.to_string(), "PortIndexFor8Ranks"); + return c.get(); + } + const port_idx2_s_& port_idx2() const + { + assert_choice_type("portIndex2", type_.to_string(), "PortIndexFor8Ranks"); + return c.get(); + } + port_idx8_s_& set_port_idx8() + { + set(types::port_idx8); + return c.get(); + } + port_idx4_s_& set_port_idx4() + { + set(types::port_idx4); + return c.get(); + } + port_idx2_s_& set_port_idx2() + { + set(types::port_idx2); + return c.get(); + } -// MeasResultListNR ::= SEQUENCE (SIZE (1..8)) OF MeasResultNR -using meas_result_list_nr_l = dyn_array; +private: + types type_; + choice_buffer_t c; -// MeasResultServMOList ::= SEQUENCE (SIZE (1..32)) OF MeasResultServMO -using meas_result_serv_mo_list_l = dyn_array; + void destroy_(); +}; -// OverheatingAssistance ::= SEQUENCE -struct overheat_assist_s { - struct reduced_max_ccs_s_ { - uint8_t reduced_ccs_dl = 0; - uint8_t reduced_ccs_ul = 0; - }; - struct reduced_max_bw_fr1_s_ { - reduced_aggregated_bw_e reduced_bw_fr1_dl; - reduced_aggregated_bw_e reduced_bw_fr1_ul; - }; - struct reduced_max_bw_fr2_s_ { - reduced_aggregated_bw_e reduced_bw_fr2_dl; - reduced_aggregated_bw_e reduced_bw_fr2_ul; - }; - struct reduced_max_mimo_layers_fr1_s_ { - mimo_layers_dl_e reduced_mimo_layers_fr1_dl; - mimo_layers_ul_e reduced_mimo_layers_fr1_ul; - }; - struct reduced_max_mimo_layers_fr2_s_ { - mimo_layers_dl_e reduced_mimo_layers_fr2_dl; - mimo_layers_ul_e reduced_mimo_layers_fr2_ul; - }; +// CSI-ReportConfig ::= SEQUENCE +struct csi_report_cfg_s { + struct report_cfg_type_c_ { + struct periodic_s_ { + using pucch_csi_res_list_l_ = dyn_array; - // member variables - bool reduced_max_ccs_present = false; - bool reduced_max_bw_fr1_present = false; - bool reduced_max_bw_fr2_present = false; - bool reduced_max_mimo_layers_fr1_present = false; - bool reduced_max_mimo_layers_fr2_present = false; - reduced_max_ccs_s_ reduced_max_ccs; - reduced_max_bw_fr1_s_ reduced_max_bw_fr1; - reduced_max_bw_fr2_s_ reduced_max_bw_fr2; - reduced_max_mimo_layers_fr1_s_ reduced_max_mimo_layers_fr1; - reduced_max_mimo_layers_fr2_s_ reduced_max_mimo_layers_fr2; + // member variables + csi_report_periodicity_and_offset_c report_slot_cfg; + pucch_csi_res_list_l_ pucch_csi_res_list; + }; + struct semi_persistent_on_pucch_s_ { + using pucch_csi_res_list_l_ = dyn_array; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + csi_report_periodicity_and_offset_c report_slot_cfg; + pucch_csi_res_list_l_ pucch_csi_res_list; + }; + struct semi_persistent_on_pusch_s_ { + struct report_slot_cfg_opts { + enum options { sl5, sl10, sl20, sl40, sl80, sl160, sl320, nulltype } value; + typedef uint16_t number_type; -// UE-CapabilityRAT-Container ::= SEQUENCE -struct ue_cap_rat_container_s { - rat_type_e rat_type; - dyn_octstring ue_cap_rat_container; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated report_slot_cfg_e_; + using report_slot_offset_list_l_ = bounded_array; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + report_slot_cfg_e_ report_slot_cfg; + report_slot_offset_list_l_ report_slot_offset_list; + uint8_t p0alpha = 0; + }; + struct aperiodic_s_ { + using report_slot_offset_list_l_ = bounded_array; -// UplinkTxDirectCurrentList ::= SEQUENCE (SIZE (1..32)) OF UplinkTxDirectCurrentCell -using ul_tx_direct_current_list_l = dyn_array; + // member variables + report_slot_offset_list_l_ report_slot_offset_list; + }; + struct types_opts { + enum options { periodic, semi_persistent_on_pucch, semi_persistent_on_pusch, aperiodic, nulltype } value; -// DRB-CountInfoList ::= SEQUENCE (SIZE (0..29)) OF DRB-CountInfo -using drb_count_info_list_l = dyn_array; + std::string to_string() const; + }; + typedef enumerated types; -// DelayBudgetReport ::= CHOICE -struct delay_budget_report_c { - struct type1_opts { - enum options { - ms_minus1280, - ms_minus640, - ms_minus320, - ms_minus160, - ms_minus80, - ms_minus60, - ms_minus40, - ms_minus20, - ms0, - ms20, - ms40, - ms60, - ms80, - ms160, - ms320, - ms640, - ms1280, - nulltype - } value; - typedef int16_t number_type; + // choice methods + report_cfg_type_c_() = default; + report_cfg_type_c_(const report_cfg_type_c_& other); + report_cfg_type_c_& operator=(const report_cfg_type_c_& other); + ~report_cfg_type_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + periodic_s_& periodic() + { + assert_choice_type("periodic", type_.to_string(), "reportConfigType"); + return c.get(); + } + semi_persistent_on_pucch_s_& semi_persistent_on_pucch() + { + assert_choice_type("semiPersistentOnPUCCH", type_.to_string(), "reportConfigType"); + return c.get(); + } + semi_persistent_on_pusch_s_& semi_persistent_on_pusch() + { + assert_choice_type("semiPersistentOnPUSCH", type_.to_string(), "reportConfigType"); + return c.get(); + } + aperiodic_s_& aperiodic() + { + assert_choice_type("aperiodic", type_.to_string(), "reportConfigType"); + return c.get(); + } + const periodic_s_& periodic() const + { + assert_choice_type("periodic", type_.to_string(), "reportConfigType"); + return c.get(); + } + const semi_persistent_on_pucch_s_& semi_persistent_on_pucch() const + { + assert_choice_type("semiPersistentOnPUCCH", type_.to_string(), "reportConfigType"); + return c.get(); + } + const semi_persistent_on_pusch_s_& semi_persistent_on_pusch() const + { + assert_choice_type("semiPersistentOnPUSCH", type_.to_string(), "reportConfigType"); + return c.get(); + } + const aperiodic_s_& aperiodic() const + { + assert_choice_type("aperiodic", type_.to_string(), "reportConfigType"); + return c.get(); + } + periodic_s_& set_periodic() + { + set(types::periodic); + return c.get(); + } + semi_persistent_on_pucch_s_& set_semi_persistent_on_pucch() + { + set(types::semi_persistent_on_pucch); + return c.get(); + } + semi_persistent_on_pusch_s_& set_semi_persistent_on_pusch() + { + set(types::semi_persistent_on_pusch); + return c.get(); + } + aperiodic_s_& set_aperiodic() + { + set(types::aperiodic); + return c.get(); + } - std::string to_string() const; - int16_t to_number() const; - }; - typedef enumerated type1_e_; - struct types_opts { - enum options { type1, /*...*/ nulltype } value; - typedef uint8_t number_type; + private: + types type_; + choice_buffer_t c; - std::string to_string() const; - uint8_t to_number() const; + void destroy_(); }; - typedef enumerated types; - - // choice methods - types type() const { return types::type1; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - type1_e_& type1() { return c; } - const type1_e_& type1() const { return c; } + struct report_quant_c_ { + struct cri_ri_i1_cqi_s_ { + struct pdsch_bundle_size_for_csi_opts { + enum options { n2, n4, nulltype } value; + typedef uint8_t number_type; -private: - type1_e_ c; -}; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated pdsch_bundle_size_for_csi_e_; -// FailureInfoRLC-Bearer ::= SEQUENCE -struct fail_info_rlc_bearer_s { - struct fail_type_opts { - enum options { dupl, spare3, spare2, spare1, nulltype } value; + // member variables + bool pdsch_bundle_size_for_csi_present = false; + pdsch_bundle_size_for_csi_e_ pdsch_bundle_size_for_csi; + }; + struct types_opts { + enum options { + none, + cri_ri_pmi_cqi, + cri_ri_i1, + cri_ri_i1_cqi, + cri_ri_cqi, + cri_rsrp, + ssb_idx_rsrp, + cri_ri_li_pmi_cqi, + nulltype + } value; - std::string to_string() const; - }; - typedef enumerated fail_type_e_; + std::string to_string() const; + }; + typedef enumerated types; - // member variables - uint8_t cell_group_id = 0; - uint8_t lc_ch_id = 1; - fail_type_e_ fail_type; + // choice methods + report_quant_c_() = default; + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + cri_ri_i1_cqi_s_& cri_ri_i1_cqi() + { + assert_choice_type("cri-RI-i1-CQI", type_.to_string(), "reportQuantity"); + return c; + } + const cri_ri_i1_cqi_s_& cri_ri_i1_cqi() const + { + assert_choice_type("cri-RI-i1-CQI", type_.to_string(), "reportQuantity"); + return c; + } + cri_ri_i1_cqi_s_& set_cri_ri_i1_cqi() + { + set(types::cri_ri_i1_cqi); + return c; + } - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + private: + types type_; + cri_ri_i1_cqi_s_ c; + }; + struct report_freq_cfg_s_ { + struct cqi_format_ind_opts { + enum options { wideband_cqi, subband_cqi, nulltype } value; -// LocationMeasurementInfo ::= CHOICE -struct location_meas_info_c { - struct types_opts { - enum options { eutra_rstd, /*...*/ eutra_fine_timing_detection, nulltype } value; + std::string to_string() const; + }; + typedef enumerated cqi_format_ind_e_; + struct pmi_format_ind_opts { + enum options { wideband_pmi, subband_pmi, nulltype } value; - std::string to_string() const; - }; - typedef enumerated types; + std::string to_string() const; + }; + typedef enumerated pmi_format_ind_e_; + struct csi_report_band_c_ { + struct types_opts { + enum options { + subbands3, + subbands4, + subbands5, + subbands6, + subbands7, + subbands8, + subbands9, + subbands10, + subbands11, + subbands12, + subbands13, + subbands14, + subbands15, + subbands16, + subbands17, + subbands18, + // ... + subbands19_v1530, + nulltype + } value; + typedef uint8_t number_type; - // choice methods - location_meas_info_c() = default; - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - eutra_rstd_info_list_l& eutra_rstd() - { - assert_choice_type("eutra-RSTD", type_.to_string(), "LocationMeasurementInfo"); - return c; - } - const eutra_rstd_info_list_l& eutra_rstd() const - { - assert_choice_type("eutra-RSTD", type_.to_string(), "LocationMeasurementInfo"); - return c; - } - eutra_rstd_info_list_l& set_eutra_rstd() - { - set(types::eutra_rstd); - return c; - } + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated types; -private: - types type_; - eutra_rstd_info_list_l c; -}; + // choice methods + csi_report_band_c_() = default; + csi_report_band_c_(const csi_report_band_c_& other); + csi_report_band_c_& operator=(const csi_report_band_c_& other); + ~csi_report_band_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<3>& subbands3() + { + assert_choice_type("subbands3", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<4>& subbands4() + { + assert_choice_type("subbands4", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<5>& subbands5() + { + assert_choice_type("subbands5", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<6>& subbands6() + { + assert_choice_type("subbands6", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<7>& subbands7() + { + assert_choice_type("subbands7", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<8>& subbands8() + { + assert_choice_type("subbands8", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<9>& subbands9() + { + assert_choice_type("subbands9", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<10>& subbands10() + { + assert_choice_type("subbands10", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<11>& subbands11() + { + assert_choice_type("subbands11", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<12>& subbands12() + { + assert_choice_type("subbands12", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<13>& subbands13() + { + assert_choice_type("subbands13", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<14>& subbands14() + { + assert_choice_type("subbands14", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<15>& subbands15() + { + assert_choice_type("subbands15", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<16>& subbands16() + { + assert_choice_type("subbands16", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<17>& subbands17() + { + assert_choice_type("subbands17", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<18>& subbands18() + { + assert_choice_type("subbands18", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<19>& subbands19_v1530() + { + assert_choice_type("subbands19-v1530", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<3>& subbands3() const + { + assert_choice_type("subbands3", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<4>& subbands4() const + { + assert_choice_type("subbands4", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<5>& subbands5() const + { + assert_choice_type("subbands5", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<6>& subbands6() const + { + assert_choice_type("subbands6", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<7>& subbands7() const + { + assert_choice_type("subbands7", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<8>& subbands8() const + { + assert_choice_type("subbands8", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<9>& subbands9() const + { + assert_choice_type("subbands9", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<10>& subbands10() const + { + assert_choice_type("subbands10", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<11>& subbands11() const + { + assert_choice_type("subbands11", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<12>& subbands12() const + { + assert_choice_type("subbands12", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<13>& subbands13() const + { + assert_choice_type("subbands13", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<14>& subbands14() const + { + assert_choice_type("subbands14", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<15>& subbands15() const + { + assert_choice_type("subbands15", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<16>& subbands16() const + { + assert_choice_type("subbands16", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<17>& subbands17() const + { + assert_choice_type("subbands17", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<18>& subbands18() const + { + assert_choice_type("subbands18", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + const fixed_bitstring<19>& subbands19_v1530() const + { + assert_choice_type("subbands19-v1530", type_.to_string(), "csi-ReportingBand"); + return c.get >(); + } + fixed_bitstring<3>& set_subbands3() + { + set(types::subbands3); + return c.get >(); + } + fixed_bitstring<4>& set_subbands4() + { + set(types::subbands4); + return c.get >(); + } + fixed_bitstring<5>& set_subbands5() + { + set(types::subbands5); + return c.get >(); + } + fixed_bitstring<6>& set_subbands6() + { + set(types::subbands6); + return c.get >(); + } + fixed_bitstring<7>& set_subbands7() + { + set(types::subbands7); + return c.get >(); + } + fixed_bitstring<8>& set_subbands8() + { + set(types::subbands8); + return c.get >(); + } + fixed_bitstring<9>& set_subbands9() + { + set(types::subbands9); + return c.get >(); + } + fixed_bitstring<10>& set_subbands10() + { + set(types::subbands10); + return c.get >(); + } + fixed_bitstring<11>& set_subbands11() + { + set(types::subbands11); + return c.get >(); + } + fixed_bitstring<12>& set_subbands12() + { + set(types::subbands12); + return c.get >(); + } + fixed_bitstring<13>& set_subbands13() + { + set(types::subbands13); + return c.get >(); + } + fixed_bitstring<14>& set_subbands14() + { + set(types::subbands14); + return c.get >(); + } + fixed_bitstring<15>& set_subbands15() + { + set(types::subbands15); + return c.get >(); + } + fixed_bitstring<16>& set_subbands16() + { + set(types::subbands16); + return c.get >(); + } + fixed_bitstring<17>& set_subbands17() + { + set(types::subbands17); + return c.get >(); + } + fixed_bitstring<18>& set_subbands18() + { + set(types::subbands18); + return c.get >(); + } + fixed_bitstring<19>& set_subbands19_v1530() + { + set(types::subbands19_v1530); + return c.get >(); + } -// MeasResults ::= SEQUENCE -struct meas_results_s { - struct meas_result_neigh_cells_c_ { - struct types_opts { - enum options { meas_result_list_nr, /*...*/ meas_result_list_eutra, nulltype } value; + private: + types type_; + choice_buffer_t > c; - std::string to_string() const; + void destroy_(); }; - typedef enumerated types; - - // choice methods - meas_result_neigh_cells_c_() = default; - meas_result_neigh_cells_c_(const meas_result_neigh_cells_c_& other); - meas_result_neigh_cells_c_& operator=(const meas_result_neigh_cells_c_& other); - ~meas_result_neigh_cells_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - meas_result_list_nr_l& meas_result_list_nr() - { - assert_choice_type("measResultListNR", type_.to_string(), "measResultNeighCells"); - return c.get(); - } - meas_result_list_eutra_l& meas_result_list_eutra() - { - assert_choice_type("measResultListEUTRA", type_.to_string(), "measResultNeighCells"); - return c.get(); - } - const meas_result_list_nr_l& meas_result_list_nr() const - { - assert_choice_type("measResultListNR", type_.to_string(), "measResultNeighCells"); - return c.get(); - } - const meas_result_list_eutra_l& meas_result_list_eutra() const - { - assert_choice_type("measResultListEUTRA", type_.to_string(), "measResultNeighCells"); - return c.get(); - } - meas_result_list_nr_l& set_meas_result_list_nr() - { - set(types::meas_result_list_nr); - return c.get(); - } - meas_result_list_eutra_l& set_meas_result_list_eutra() - { - set(types::meas_result_list_eutra); - return c.get(); - } - private: - types type_; - choice_buffer_t c; - - void destroy_(); + // member variables + bool cqi_format_ind_present = false; + bool pmi_format_ind_present = false; + bool csi_report_band_present = false; + cqi_format_ind_e_ cqi_format_ind; + pmi_format_ind_e_ pmi_format_ind; + csi_report_band_c_ csi_report_band; }; - - // member variables - bool ext = false; - bool meas_result_neigh_cells_present = false; - uint8_t meas_id = 1; - meas_result_serv_mo_list_l meas_result_serving_mo_list; - meas_result_neigh_cells_c_ meas_result_neigh_cells; - // ... - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// RRCReconfigurationComplete-v1530-IEs ::= SEQUENCE -struct rrc_recfg_complete_v1530_ies_s { - bool ul_tx_direct_current_list_present = false; - bool non_crit_ext_present = false; - ul_tx_direct_current_list_l ul_tx_direct_current_list; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// RegisteredAMF ::= SEQUENCE -struct registered_amf_s { - bool plmn_id_present = false; - plmn_id_s plmn_id; - fixed_bitstring<24> amf_id; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// S-NSSAI ::= CHOICE -struct s_nssai_c { - struct types_opts { - enum options { sst, sst_sd, nulltype } value; + struct time_restrict_for_ch_meass_opts { + enum options { cfgured, not_cfgured, nulltype } value; std::string to_string() const; }; - typedef enumerated types; - - // choice methods - s_nssai_c() = default; - s_nssai_c(const s_nssai_c& other); - s_nssai_c& operator=(const s_nssai_c& other); - ~s_nssai_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fixed_bitstring<8>& sst() - { - assert_choice_type("sst", type_.to_string(), "S-NSSAI"); - return c.get >(); - } - fixed_bitstring<32>& sst_sd() - { - assert_choice_type("sst-SD", type_.to_string(), "S-NSSAI"); - return c.get >(); - } - const fixed_bitstring<8>& sst() const - { - assert_choice_type("sst", type_.to_string(), "S-NSSAI"); - return c.get >(); - } - const fixed_bitstring<32>& sst_sd() const - { - assert_choice_type("sst-SD", type_.to_string(), "S-NSSAI"); - return c.get >(); - } - fixed_bitstring<8>& set_sst() - { - set(types::sst); - return c.get >(); - } - fixed_bitstring<32>& set_sst_sd() - { - set(types::sst_sd); - return c.get >(); - } - -private: - types type_; - choice_buffer_t > c; - - void destroy_(); -}; - -// UE-CapabilityRAT-ContainerList ::= SEQUENCE (SIZE (0..8)) OF UE-CapabilityRAT-Container -using ue_cap_rat_container_list_l = dyn_array; - -// UEAssistanceInformation-v1540-IEs ::= SEQUENCE -struct ueassist_info_v1540_ies_s { - bool overheat_assist_present = false; - bool non_crit_ext_present = false; - overheat_assist_s overheat_assist; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CounterCheckResponse-IEs ::= SEQUENCE -struct counter_check_resp_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - drb_count_info_list_l drb_count_info_list; - dyn_octstring late_non_crit_ext; + typedef enumerated time_restrict_for_ch_meass_e_; + struct time_restrict_for_interference_meass_opts { + enum options { cfgured, not_cfgured, nulltype } value; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + }; + typedef enumerated time_restrict_for_interference_meass_e_; + struct dummy_opts { + enum options { n1, n2, nulltype } value; + typedef uint8_t number_type; -// FailureInformation-IEs ::= SEQUENCE -struct fail_info_ies_s { - bool fail_info_rlc_bearer_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - fail_info_rlc_bearer_s fail_info_rlc_bearer; - dyn_octstring late_non_crit_ext; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated dummy_e_; + struct group_based_beam_report_c_ { + struct disabled_s_ { + struct nrof_reported_rs_opts { + enum options { n1, n2, n3, n4, nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated nrof_reported_rs_e_; -// LocationMeasurementIndication-IEs ::= SEQUENCE -struct location_meas_ind_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - setup_release_c meas_ind; - dyn_octstring late_non_crit_ext; + // member variables + bool nrof_reported_rs_present = false; + nrof_reported_rs_e_ nrof_reported_rs; + }; + struct types_opts { + enum options { enabled, disabled, nulltype } value; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + }; + typedef enumerated types; -// MeasurementReport-IEs ::= SEQUENCE -struct meas_report_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - meas_results_s meas_results; - dyn_octstring late_non_crit_ext; + // choice methods + group_based_beam_report_c_() = default; + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + disabled_s_& disabled() + { + assert_choice_type("disabled", type_.to_string(), "groupBasedBeamReporting"); + return c; + } + const disabled_s_& disabled() const + { + assert_choice_type("disabled", type_.to_string(), "groupBasedBeamReporting"); + return c; + } + disabled_s_& set_disabled() + { + set(types::disabled); + return c; + } - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + private: + types type_; + disabled_s_ c; + }; + struct cqi_table_opts { + enum options { table1, table2, table3, spare1, nulltype } value; + typedef uint8_t number_type; -// RRCReconfigurationComplete-IEs ::= SEQUENCE -struct rrc_recfg_complete_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - dyn_octstring late_non_crit_ext; - rrc_recfg_complete_v1530_ies_s non_crit_ext; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated cqi_table_e_; + struct subband_size_opts { + enum options { value1, value2, nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated subband_size_e_; + using non_pmi_port_ind_l_ = dyn_array; + struct semi_persistent_on_pusch_v1530_s_ { + struct report_slot_cfg_v1530_opts { + enum options { sl4, sl8, sl16, nulltype } value; + typedef uint8_t number_type; -// RRCReestablishmentComplete-IEs ::= SEQUENCE -struct rrc_reest_complete_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - dyn_octstring late_non_crit_ext; + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated report_slot_cfg_v1530_e_; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + // member variables + report_slot_cfg_v1530_e_ report_slot_cfg_v1530; + }; -// RRCResumeComplete-IEs ::= SEQUENCE -struct rrc_resume_complete_ies_s { - bool ded_nas_msg_present = false; - bool sel_plmn_id_present = false; - bool ul_tx_direct_current_list_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - dyn_octstring ded_nas_msg; - uint8_t sel_plmn_id = 1; - ul_tx_direct_current_list_l ul_tx_direct_current_list; - dyn_octstring late_non_crit_ext; + // member variables + bool ext = false; + bool carrier_present = false; + bool csi_im_res_for_interference_present = false; + bool nzp_csi_rs_res_for_interference_present = false; + bool report_freq_cfg_present = false; + bool codebook_cfg_present = false; + bool dummy_present = false; + bool cqi_table_present = false; + bool non_pmi_port_ind_present = false; + uint8_t report_cfg_id = 0; + uint8_t carrier = 0; + uint8_t res_for_ch_meas = 0; + uint8_t csi_im_res_for_interference = 0; + uint8_t nzp_csi_rs_res_for_interference = 0; + report_cfg_type_c_ report_cfg_type; + report_quant_c_ report_quant; + report_freq_cfg_s_ report_freq_cfg; + time_restrict_for_ch_meass_e_ time_restrict_for_ch_meass; + time_restrict_for_interference_meass_e_ time_restrict_for_interference_meass; + codebook_cfg_s codebook_cfg; + dummy_e_ dummy; + group_based_beam_report_c_ group_based_beam_report; + cqi_table_e_ cqi_table; + subband_size_e_ subband_size; + non_pmi_port_ind_l_ non_pmi_port_ind; + // ... + // group 0 + copy_ptr semi_persistent_on_pusch_v1530; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -18968,86 +19371,89 @@ struct rrc_resume_complete_ies_s { void to_json(json_writer& j) const; }; -// RRCSetupComplete-IEs ::= SEQUENCE -struct rrc_setup_complete_ies_s { - struct guami_type_opts { - enum options { native, mapped, nulltype } value; +// CSI-ResourceConfig ::= SEQUENCE +struct csi_res_cfg_s { + struct csi_rs_res_set_list_c_ { + struct nzp_csi_rs_ssb_s_ { + using nzp_csi_rs_res_set_list_l_ = bounded_array; + using csi_ssb_res_set_list_l_ = std::array; - std::string to_string() const; - }; - typedef enumerated guami_type_e_; - using s_nssai_list_l_ = dyn_array; - struct ng_minus5_g_s_tmsi_value_c_ { + // member variables + bool nzp_csi_rs_res_set_list_present = false; + bool csi_ssb_res_set_list_present = false; + nzp_csi_rs_res_set_list_l_ nzp_csi_rs_res_set_list; + csi_ssb_res_set_list_l_ csi_ssb_res_set_list; + }; + using csi_im_res_set_list_l_ = bounded_array; struct types_opts { - enum options { ng_minus5_g_s_tmsi, ng_minus5_g_s_tmsi_part2, nulltype } value; + enum options { nzp_csi_rs_ssb, csi_im_res_set_list, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - ng_minus5_g_s_tmsi_value_c_() = default; - ng_minus5_g_s_tmsi_value_c_(const ng_minus5_g_s_tmsi_value_c_& other); - ng_minus5_g_s_tmsi_value_c_& operator=(const ng_minus5_g_s_tmsi_value_c_& other); - ~ng_minus5_g_s_tmsi_value_c_() { destroy_(); } + csi_rs_res_set_list_c_() = default; + csi_rs_res_set_list_c_(const csi_rs_res_set_list_c_& other); + csi_rs_res_set_list_c_& operator=(const csi_rs_res_set_list_c_& other); + ~csi_rs_res_set_list_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - fixed_bitstring<48>& ng_minus5_g_s_tmsi() + nzp_csi_rs_ssb_s_& nzp_csi_rs_ssb() { - assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "ng-5G-S-TMSI-Value"); - return c.get >(); + assert_choice_type("nzp-CSI-RS-SSB", type_.to_string(), "csi-RS-ResourceSetList"); + return c.get(); } - fixed_bitstring<9>& ng_minus5_g_s_tmsi_part2() + csi_im_res_set_list_l_& csi_im_res_set_list() { - assert_choice_type("ng-5G-S-TMSI-Part2", type_.to_string(), "ng-5G-S-TMSI-Value"); - return c.get >(); + assert_choice_type("csi-IM-ResourceSetList", type_.to_string(), "csi-RS-ResourceSetList"); + return c.get(); } - const fixed_bitstring<48>& ng_minus5_g_s_tmsi() const + const nzp_csi_rs_ssb_s_& nzp_csi_rs_ssb() const { - assert_choice_type("ng-5G-S-TMSI", type_.to_string(), "ng-5G-S-TMSI-Value"); - return c.get >(); + assert_choice_type("nzp-CSI-RS-SSB", type_.to_string(), "csi-RS-ResourceSetList"); + return c.get(); } - const fixed_bitstring<9>& ng_minus5_g_s_tmsi_part2() const + const csi_im_res_set_list_l_& csi_im_res_set_list() const { - assert_choice_type("ng-5G-S-TMSI-Part2", type_.to_string(), "ng-5G-S-TMSI-Value"); - return c.get >(); + assert_choice_type("csi-IM-ResourceSetList", type_.to_string(), "csi-RS-ResourceSetList"); + return c.get(); } - fixed_bitstring<48>& set_ng_minus5_g_s_tmsi() + nzp_csi_rs_ssb_s_& set_nzp_csi_rs_ssb() { - set(types::ng_minus5_g_s_tmsi); - return c.get >(); + set(types::nzp_csi_rs_ssb); + return c.get(); } - fixed_bitstring<9>& set_ng_minus5_g_s_tmsi_part2() + csi_im_res_set_list_l_& set_csi_im_res_set_list() { - set(types::ng_minus5_g_s_tmsi_part2); - return c.get >(); + set(types::csi_im_res_set_list); + return c.get(); } private: - types type_; - choice_buffer_t > c; + types type_; + choice_buffer_t c; void destroy_(); }; + struct res_type_opts { + enum options { aperiodic, semi_persistent, periodic, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated res_type_e_; // member variables - bool registered_amf_present = false; - bool guami_type_present = false; - bool s_nssai_list_present = false; - bool ng_minus5_g_s_tmsi_value_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - uint8_t sel_plmn_id = 1; - registered_amf_s registered_amf; - guami_type_e_ guami_type; - s_nssai_list_l_ s_nssai_list; - dyn_octstring ded_nas_msg; - ng_minus5_g_s_tmsi_value_c_ ng_minus5_g_s_tmsi_value; - dyn_octstring late_non_crit_ext; + bool ext = false; + uint8_t csi_res_cfg_id = 0; + csi_rs_res_set_list_c_ csi_rs_res_set_list; + uint8_t bwp_id = 0; + res_type_e_ res_type; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19055,11 +19461,15 @@ struct rrc_setup_complete_ies_s { void to_json(json_writer& j) const; }; -// SecurityModeComplete-IEs ::= SEQUENCE -struct security_mode_complete_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - dyn_octstring late_non_crit_ext; +// CSI-SSB-ResourceSet ::= SEQUENCE +struct csi_ssb_res_set_s { + using csi_ssb_res_list_l_ = dyn_array; + + // member variables + bool ext = false; + uint8_t csi_ssb_res_set_id = 0; + csi_ssb_res_list_l_ csi_ssb_res_list; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19067,26 +19477,33 @@ struct security_mode_complete_ies_s { void to_json(json_writer& j) const; }; -// SecurityModeFailure-IEs ::= SEQUENCE -struct security_mode_fail_ies_s { - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - dyn_octstring late_non_crit_ext; +// CSI-SemiPersistentOnPUSCH-TriggerStateList ::= SEQUENCE (SIZE (1..64)) OF CSI-SemiPersistentOnPUSCH-TriggerState +using csi_semi_persistent_on_pusch_trigger_state_list_l = dyn_array; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; +// NZP-CSI-RS-Resource ::= SEQUENCE +struct nzp_csi_rs_res_s { + struct pwr_ctrl_offset_ss_opts { + enum options { db_minus3, db0, db3, db6, nulltype } value; + typedef int8_t number_type; -// UEAssistanceInformation-IEs ::= SEQUENCE -struct ueassist_info_ies_s { - bool delay_budget_report_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - delay_budget_report_c delay_budget_report; - dyn_octstring late_non_crit_ext; - ueassist_info_v1540_ies_s non_crit_ext; + std::string to_string() const; + int8_t to_number() const; + }; + typedef enumerated pwr_ctrl_offset_ss_e_; + + // member variables + bool ext = false; + bool pwr_ctrl_offset_ss_present = false; + bool periodicity_and_offset_present = false; + bool qcl_info_periodic_csi_rs_present = false; + uint8_t nzp_csi_rs_res_id = 0; + csi_rs_res_map_s res_map; + int8_t pwr_ctrl_offset = -8; + pwr_ctrl_offset_ss_e_ pwr_ctrl_offset_ss; + uint16_t scrambling_id = 0; + csi_res_periodicity_and_offset_c periodicity_and_offset; + uint8_t qcl_info_periodic_csi_rs = 0; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19094,13 +19511,26 @@ struct ueassist_info_ies_s { void to_json(json_writer& j) const; }; -// UECapabilityInformation-IEs ::= SEQUENCE -struct ue_cap_info_ies_s { - bool ue_cap_rat_container_list_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - ue_cap_rat_container_list_l ue_cap_rat_container_list; - dyn_octstring late_non_crit_ext; +// NZP-CSI-RS-ResourceSet ::= SEQUENCE +struct nzp_csi_rs_res_set_s { + using nzp_csi_rs_res_l_ = dyn_array; + struct repeat_opts { + enum options { on, off, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated repeat_e_; + + // member variables + bool ext = false; + bool repeat_present = false; + bool aperiodic_trigger_offset_present = false; + bool trs_info_present = false; + uint8_t nzp_csi_res_set_id = 0; + nzp_csi_rs_res_l_ nzp_csi_rs_res; + repeat_e_ repeat; + uint8_t aperiodic_trigger_offset = 0; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19108,13 +19538,61 @@ struct ue_cap_info_ies_s { void to_json(json_writer& j) const; }; -// ULInformationTransfer-IEs ::= SEQUENCE -struct ul_info_transfer_ies_s { - bool ded_nas_msg_present = false; - bool late_non_crit_ext_present = false; - bool non_crit_ext_present = false; - dyn_octstring ded_nas_msg; - dyn_octstring late_non_crit_ext; +// CSI-MeasConfig ::= SEQUENCE +struct csi_meas_cfg_s { + using nzp_csi_rs_res_to_add_mod_list_l_ = dyn_array; + using nzp_csi_rs_res_to_release_list_l_ = dyn_array; + using nzp_csi_rs_res_set_to_add_mod_list_l_ = dyn_array; + using nzp_csi_rs_res_set_to_release_list_l_ = dyn_array; + using csi_im_res_to_add_mod_list_l_ = dyn_array; + using csi_im_res_to_release_list_l_ = bounded_array; + using csi_im_res_set_to_add_mod_list_l_ = dyn_array; + using csi_im_res_set_to_release_list_l_ = dyn_array; + using csi_ssb_res_set_to_add_mod_list_l_ = dyn_array; + using csi_ssb_res_set_to_release_list_l_ = dyn_array; + using csi_res_cfg_to_add_mod_list_l_ = dyn_array; + using csi_res_cfg_to_release_list_l_ = dyn_array; + using csi_report_cfg_to_add_mod_list_l_ = dyn_array; + using csi_report_cfg_to_release_list_l_ = dyn_array; + + // member variables + bool ext = false; + bool nzp_csi_rs_res_to_add_mod_list_present = false; + bool nzp_csi_rs_res_to_release_list_present = false; + bool nzp_csi_rs_res_set_to_add_mod_list_present = false; + bool nzp_csi_rs_res_set_to_release_list_present = false; + bool csi_im_res_to_add_mod_list_present = false; + bool csi_im_res_to_release_list_present = false; + bool csi_im_res_set_to_add_mod_list_present = false; + bool csi_im_res_set_to_release_list_present = false; + bool csi_ssb_res_set_to_add_mod_list_present = false; + bool csi_ssb_res_set_to_release_list_present = false; + bool csi_res_cfg_to_add_mod_list_present = false; + bool csi_res_cfg_to_release_list_present = false; + bool csi_report_cfg_to_add_mod_list_present = false; + bool csi_report_cfg_to_release_list_present = false; + bool report_trigger_size_present = false; + bool aperiodic_trigger_state_list_present = false; + bool semi_persistent_on_pusch_trigger_state_list_present = false; + nzp_csi_rs_res_to_add_mod_list_l_ nzp_csi_rs_res_to_add_mod_list; + nzp_csi_rs_res_to_release_list_l_ nzp_csi_rs_res_to_release_list; + nzp_csi_rs_res_set_to_add_mod_list_l_ nzp_csi_rs_res_set_to_add_mod_list; + nzp_csi_rs_res_set_to_release_list_l_ nzp_csi_rs_res_set_to_release_list; + csi_im_res_to_add_mod_list_l_ csi_im_res_to_add_mod_list; + csi_im_res_to_release_list_l_ csi_im_res_to_release_list; + csi_im_res_set_to_add_mod_list_l_ csi_im_res_set_to_add_mod_list; + csi_im_res_set_to_release_list_l_ csi_im_res_set_to_release_list; + csi_ssb_res_set_to_add_mod_list_l_ csi_ssb_res_set_to_add_mod_list; + csi_ssb_res_set_to_release_list_l_ csi_ssb_res_set_to_release_list; + csi_res_cfg_to_add_mod_list_l_ csi_res_cfg_to_add_mod_list; + csi_res_cfg_to_release_list_l_ csi_res_cfg_to_release_list; + csi_report_cfg_to_add_mod_list_l_ csi_report_cfg_to_add_mod_list; + csi_report_cfg_to_release_list_l_ csi_report_cfg_to_release_list; + uint8_t report_trigger_size = 0; + setup_release_c > aperiodic_trigger_state_list; + setup_release_c > + semi_persistent_on_pusch_trigger_state_list; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19122,106 +19600,168 @@ struct ul_info_transfer_ies_s { void to_json(json_writer& j) const; }; -// CounterCheckResponse ::= SEQUENCE -struct counter_check_resp_s { - struct crit_exts_c_ { +// EUTRA-MBSFN-SubframeConfig ::= SEQUENCE +struct eutra_mbsfn_sf_cfg_s { + struct radioframe_alloc_period_opts { + enum options { n1, n2, n4, n8, n16, n32, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated radioframe_alloc_period_e_; + struct sf_alloc1_c_ { struct types_opts { - enum options { counter_check_resp, crit_exts_future, nulltype } value; + enum options { one_frame, four_frames, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; typedef enumerated types; // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } + sf_alloc1_c_() = default; + sf_alloc1_c_(const sf_alloc1_c_& other); + sf_alloc1_c_& operator=(const sf_alloc1_c_& other); + ~sf_alloc1_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - counter_check_resp_ies_s& counter_check_resp() + fixed_bitstring<6>& one_frame() { - assert_choice_type("counterCheckResponse", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation1"); + return c.get >(); } - const counter_check_resp_ies_s& counter_check_resp() const + fixed_bitstring<24>& four_frames() { - assert_choice_type("counterCheckResponse", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation1"); + return c.get >(); } - counter_check_resp_ies_s& set_counter_check_resp() + const fixed_bitstring<6>& one_frame() const { - set(types::counter_check_resp); - return c.get(); + assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation1"); + return c.get >(); + } + const fixed_bitstring<24>& four_frames() const + { + assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation1"); + return c.get >(); + } + fixed_bitstring<6>& set_one_frame() + { + set(types::one_frame); + return c.get >(); + } + fixed_bitstring<24>& set_four_frames() + { + set(types::four_frames); + return c.get >(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t > c; void destroy_(); }; - - // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// FailureInformation ::= SEQUENCE -struct fail_info_s { - struct crit_exts_c_ { + struct sf_alloc2_c_ { struct types_opts { - enum options { fail_info, crit_exts_future, nulltype } value; + enum options { one_frame, four_frames, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; typedef enumerated types; // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } + sf_alloc2_c_() = default; + sf_alloc2_c_(const sf_alloc2_c_& other); + sf_alloc2_c_& operator=(const sf_alloc2_c_& other); + ~sf_alloc2_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - fail_info_ies_s& fail_info() + fixed_bitstring<2>& one_frame() { - assert_choice_type("failureInformation", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation2"); + return c.get >(); } - const fail_info_ies_s& fail_info() const + fixed_bitstring<8>& four_frames() { - assert_choice_type("failureInformation", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation2"); + return c.get >(); } - fail_info_ies_s& set_fail_info() + const fixed_bitstring<2>& one_frame() const { - set(types::fail_info); - return c.get(); + assert_choice_type("oneFrame", type_.to_string(), "subframeAllocation2"); + return c.get >(); + } + const fixed_bitstring<8>& four_frames() const + { + assert_choice_type("fourFrames", type_.to_string(), "subframeAllocation2"); + return c.get >(); + } + fixed_bitstring<2>& set_one_frame() + { + set(types::one_frame); + return c.get >(); + } + fixed_bitstring<8>& set_four_frames() + { + set(types::four_frames); + return c.get >(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t > c; void destroy_(); }; // member variables - crit_exts_c_ crit_exts; + bool ext = false; + bool sf_alloc2_present = false; + radioframe_alloc_period_e_ radioframe_alloc_period; + uint8_t radioframe_alloc_offset = 0; + sf_alloc1_c_ sf_alloc1; + sf_alloc2_c_ sf_alloc2; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SRS-CC-SetIndex ::= SEQUENCE +struct srs_cc_set_idx_s { + bool cc_set_idx_present = false; + bool cc_idx_in_one_cc_set_present = false; + uint8_t cc_set_idx = 0; + uint8_t cc_idx_in_one_cc_set = 0; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// SlotFormatCombination ::= SEQUENCE +struct slot_format_combination_s { + using slot_formats_l_ = dyn_array; + + // member variables + uint16_t slot_format_combination_id = 0; + slot_formats_l_ slot_formats; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19229,52 +19769,21 @@ struct fail_info_s { void to_json(json_writer& j) const; }; -// LocationMeasurementIndication ::= SEQUENCE -struct location_meas_ind_s { - struct crit_exts_c_ { - struct types_opts { - enum options { location_meas_ind, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - location_meas_ind_ies_s& location_meas_ind() - { - assert_choice_type("locationMeasurementIndication", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const location_meas_ind_ies_s& location_meas_ind() const - { - assert_choice_type("locationMeasurementIndication", type_.to_string(), "criticalExtensions"); - return c.get(); - } - location_meas_ind_ies_s& set_location_meas_ind() - { - set(types::location_meas_ind); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; +// EUTRA-MBSFN-SubframeConfigList ::= SEQUENCE (SIZE (1..8)) OF EUTRA-MBSFN-SubframeConfig +using eutra_mbsfn_sf_cfg_list_l = dyn_array; - void destroy_(); - }; +// FrequencyInfoDL ::= SEQUENCE +struct freq_info_dl_s { + using scs_specific_carrier_list_l_ = dyn_array; // member variables - crit_exts_c_ crit_exts; + bool ext = false; + bool absolute_freq_ssb_present = false; + uint32_t absolute_freq_ssb = 0; + multi_freq_band_list_nr_l freq_band_list; + uint32_t absolute_freq_point_a = 0; + scs_specific_carrier_list_l_ scs_specific_carrier_list; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19282,52 +19791,45 @@ struct location_meas_ind_s { void to_json(json_writer& j) const; }; -// MeasurementReport ::= SEQUENCE -struct meas_report_s { - struct crit_exts_c_ { - struct types_opts { - enum options { meas_report, crit_exts_future, nulltype } value; +// FrequencyInfoUL ::= SEQUENCE +struct freq_info_ul_s { + using scs_specific_carrier_list_l_ = dyn_array; - std::string to_string() const; - }; - typedef enumerated types; + // member variables + bool ext = false; + bool freq_band_list_present = false; + bool absolute_freq_point_a_present = false; + bool add_spec_emission_present = false; + bool p_max_present = false; + bool freq_shift7p5khz_present = false; + multi_freq_band_list_nr_l freq_band_list; + uint32_t absolute_freq_point_a = 0; + scs_specific_carrier_list_l_ scs_specific_carrier_list; + uint8_t add_spec_emission = 0; + int8_t p_max = -30; + // ... - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - meas_report_ies_s& meas_report() - { - assert_choice_type("measurementReport", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const meas_report_ies_s& meas_report() const - { - assert_choice_type("measurementReport", type_.to_string(), "criticalExtensions"); - return c.get(); - } - meas_report_ies_s& set_meas_report() - { - set(types::meas_report); - return c.get(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - choice_buffer_t c; +// PUSCH-CodeBlockGroupTransmission ::= SEQUENCE +struct pusch_code_block_group_tx_s { + struct max_code_block_groups_per_transport_block_opts { + enum options { n2, n4, n6, n8, nulltype } value; + typedef uint8_t number_type; - void destroy_(); + std::string to_string() const; + uint8_t to_number() const; }; + typedef enumerated max_code_block_groups_per_transport_block_e_; // member variables - crit_exts_c_ crit_exts; + bool ext = false; + max_code_block_groups_per_transport_block_e_ max_code_block_groups_per_transport_block; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19335,53 +19837,35 @@ struct meas_report_s { void to_json(json_writer& j) const; }; -// RRCReconfigurationComplete ::= SEQUENCE -struct rrc_recfg_complete_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_recfg_complete, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; +// SRS-TPC-PDCCH-Config ::= SEQUENCE +struct srs_tpc_pdcch_cfg_s { + using srs_cc_set_idxlist_l_ = dyn_array; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_recfg_complete_ies_s& rrc_recfg_complete() - { - assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_recfg_complete_ies_s& rrc_recfg_complete() const - { - assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_recfg_complete_ies_s& set_rrc_recfg_complete() - { - set(types::rrc_recfg_complete); - return c.get(); - } + // member variables + bool srs_cc_set_idxlist_present = false; + srs_cc_set_idxlist_l_ srs_cc_set_idxlist; - private: - types type_; - choice_buffer_t c; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - void destroy_(); - }; +// SlotFormatCombinationsPerCell ::= SEQUENCE +struct slot_format_combinations_per_cell_s { + using slot_format_combinations_l_ = dyn_array; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool ext = false; + bool subcarrier_spacing2_present = false; + bool slot_format_combinations_present = false; + bool position_in_dci_present = false; + uint8_t serving_cell_id = 0; + subcarrier_spacing_e subcarrier_spacing; + subcarrier_spacing_e subcarrier_spacing2; + slot_format_combinations_l_ slot_format_combinations; + uint8_t position_in_dci = 0; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19389,53 +19873,37 @@ struct rrc_recfg_complete_s { void to_json(json_writer& j) const; }; -// RRCReestablishmentComplete ::= SEQUENCE -struct rrc_reest_complete_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_reest_complete, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; +// DownlinkConfigCommon ::= SEQUENCE +struct dl_cfg_common_s { + bool ext = false; + bool freq_info_dl_present = false; + bool init_dl_bwp_present = false; + freq_info_dl_s freq_info_dl; + bwp_dl_common_s init_dl_bwp; + // ... - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_reest_complete_ies_s& rrc_reest_complete() - { - assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_reest_complete_ies_s& rrc_reest_complete() const - { - assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_reest_complete_ies_s& set_rrc_reest_complete() - { - set(types::rrc_reest_complete); - return c.get(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - choice_buffer_t c; +// PDSCH-CodeBlockGroupTransmission ::= SEQUENCE +struct pdsch_code_block_group_tx_s { + struct max_code_block_groups_per_transport_block_opts { + enum options { n2, n4, n6, n8, nulltype } value; + typedef uint8_t number_type; - void destroy_(); + std::string to_string() const; + uint8_t to_number() const; }; + typedef enumerated max_code_block_groups_per_transport_block_e_; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool ext = false; + max_code_block_groups_per_transport_block_e_ max_code_block_groups_per_transport_block; + bool code_block_group_flush_ind = false; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19443,53 +19911,30 @@ struct rrc_reest_complete_s { void to_json(json_writer& j) const; }; -// RRCResumeComplete ::= SEQUENCE -struct rrc_resume_complete_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_resume_complete, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_resume_complete_ies_s& rrc_resume_complete() - { - assert_choice_type("rrcResumeComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_resume_complete_ies_s& rrc_resume_complete() const - { - assert_choice_type("rrcResumeComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_resume_complete_ies_s& set_rrc_resume_complete() - { - set(types::rrc_resume_complete); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; +// PUSCH-ServingCellConfig ::= SEQUENCE +struct pusch_serving_cell_cfg_s { + struct xoverhead_opts { + enum options { xoh6, xoh12, xoh18, nulltype } value; + typedef uint8_t number_type; - void destroy_(); + std::string to_string() const; + uint8_t to_number() const; }; + typedef enumerated xoverhead_e_; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool ext = false; + bool code_block_group_tx_present = false; + bool rate_matching_present = false; + bool xoverhead_present = false; + setup_release_c code_block_group_tx; + xoverhead_e_ xoverhead; + // ... + // group 0 + bool max_mimo_layers_present = false; + bool processing_type2_enabled_present = false; + uint8_t max_mimo_layers = 1; + bool processing_type2_enabled = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19497,53 +19942,158 @@ struct rrc_resume_complete_s { void to_json(json_writer& j) const; }; -// RRCSetupComplete ::= SEQUENCE -struct rrc_setup_complete_s { - struct crit_exts_c_ { - struct types_opts { - enum options { rrc_setup_complete, crit_exts_future, nulltype } value; +// PollByte ::= ENUMERATED +struct poll_byte_opts { + enum options { + kb1, + kb2, + kb5, + kb8, + kb10, + kb15, + kb25, + kb50, + kb75, + kb100, + kb125, + kb250, + kb375, + kb500, + kb750, + kb1000, + kb1250, + kb1500, + kb2000, + kb3000, + kb4000, + kb4500, + kb5000, + kb5500, + kb6000, + kb6500, + kb7000, + kb7500, + mb8, + mb9, + mb10, + mb11, + mb12, + mb13, + mb14, + mb15, + mb16, + mb17, + mb18, + mb20, + mb25, + mb30, + mb40, + infinity, + spare20, + spare19, + spare18, + spare17, + spare16, + spare15, + spare14, + spare13, + spare12, + spare11, + spare10, + spare9, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; - std::string to_string() const; - }; - typedef enumerated types; + std::string to_string() const; +}; +typedef enumerated poll_byte_e; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - rrc_setup_complete_ies_s& rrc_setup_complete() - { - assert_choice_type("rrcSetupComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const rrc_setup_complete_ies_s& rrc_setup_complete() const - { - assert_choice_type("rrcSetupComplete", type_.to_string(), "criticalExtensions"); - return c.get(); - } - rrc_setup_complete_ies_s& set_rrc_setup_complete() - { - set(types::rrc_setup_complete); - return c.get(); - } +// PollPDU ::= ENUMERATED +struct poll_pdu_opts { + enum options { + p4, + p8, + p16, + p32, + p64, + p128, + p256, + p512, + p1024, + p2048, + p4096, + p6144, + p8192, + p12288, + p16384, + p20480, + p24576, + p28672, + p32768, + p40960, + p49152, + p57344, + p65536, + infinity, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef int32_t number_type; - private: - types type_; - choice_buffer_t c; + std::string to_string() const; + int32_t to_number() const; +}; +typedef enumerated poll_pdu_e; - void destroy_(); +// RateMatchPatternLTE-CRS ::= SEQUENCE +struct rate_match_pattern_lte_crs_s { + struct carrier_bw_dl_opts { + enum options { n6, n15, n25, n50, n75, n100, spare2, spare1, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated carrier_bw_dl_e_; + struct nrof_crs_ports_opts { + enum options { n1, n2, n4, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; }; + typedef enumerated nrof_crs_ports_e_; + struct v_shift_opts { + enum options { n0, n1, n2, n3, n4, n5, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated v_shift_e_; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool mbsfn_sf_cfg_list_present = false; + uint16_t carrier_freq_dl = 0; + carrier_bw_dl_e_ carrier_bw_dl; + eutra_mbsfn_sf_cfg_list_l mbsfn_sf_cfg_list; + nrof_crs_ports_e_ nrof_crs_ports; + v_shift_e_ v_shift; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19551,53 +20101,103 @@ struct rrc_setup_complete_s { void to_json(json_writer& j) const; }; -// SecurityModeComplete ::= SEQUENCE -struct security_mode_complete_s { - struct crit_exts_c_ { +// SN-FieldLengthAM ::= ENUMERATED +struct sn_field_len_am_opts { + enum options { size12, size18, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; +}; +typedef enumerated sn_field_len_am_e; + +// SN-FieldLengthUM ::= ENUMERATED +struct sn_field_len_um_opts { + enum options { size6, size12, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; +}; +typedef enumerated sn_field_len_um_e; + +// SRS-CarrierSwitching ::= SEQUENCE +struct srs_carrier_switching_s { + struct srs_switch_from_carrier_opts { + enum options { sul, nul, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated srs_switch_from_carrier_e_; + struct srs_tpc_pdcch_group_c_ { + using type_a_l_ = dyn_array; struct types_opts { - enum options { security_mode_complete, crit_exts_future, nulltype } value; + enum options { type_a, type_b, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } + srs_tpc_pdcch_group_c_() = default; + srs_tpc_pdcch_group_c_(const srs_tpc_pdcch_group_c_& other); + srs_tpc_pdcch_group_c_& operator=(const srs_tpc_pdcch_group_c_& other); + ~srs_tpc_pdcch_group_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - security_mode_complete_ies_s& security_mode_complete() + type_a_l_& type_a() { - assert_choice_type("securityModeComplete", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("typeA", type_.to_string(), "srs-TPC-PDCCH-Group"); + return c.get(); } - const security_mode_complete_ies_s& security_mode_complete() const + srs_tpc_pdcch_cfg_s& type_b() { - assert_choice_type("securityModeComplete", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("typeB", type_.to_string(), "srs-TPC-PDCCH-Group"); + return c.get(); } - security_mode_complete_ies_s& set_security_mode_complete() + const type_a_l_& type_a() const { - set(types::security_mode_complete); - return c.get(); + assert_choice_type("typeA", type_.to_string(), "srs-TPC-PDCCH-Group"); + return c.get(); + } + const srs_tpc_pdcch_cfg_s& type_b() const + { + assert_choice_type("typeB", type_.to_string(), "srs-TPC-PDCCH-Group"); + return c.get(); + } + type_a_l_& set_type_a() + { + set(types::type_a); + return c.get(); + } + srs_tpc_pdcch_cfg_s& set_type_b() + { + set(types::type_b); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + choice_buffer_t c; void destroy_(); }; + using monitoring_cells_l_ = bounded_array; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool ext = false; + bool srs_switch_from_serv_cell_idx_present = false; + bool srs_tpc_pdcch_group_present = false; + bool monitoring_cells_present = false; + uint8_t srs_switch_from_serv_cell_idx = 0; + srs_switch_from_carrier_e_ srs_switch_from_carrier; + srs_tpc_pdcch_group_c_ srs_tpc_pdcch_group; + monitoring_cells_l_ monitoring_cells; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19605,53 +20205,20 @@ struct security_mode_complete_s { void to_json(json_writer& j) const; }; -// SecurityModeFailure ::= SEQUENCE -struct security_mode_fail_s { - struct crit_exts_c_ { - struct types_opts { - enum options { security_mode_fail, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - security_mode_fail_ies_s& security_mode_fail() - { - assert_choice_type("securityModeFailure", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const security_mode_fail_ies_s& security_mode_fail() const - { - assert_choice_type("securityModeFailure", type_.to_string(), "criticalExtensions"); - return c.get(); - } - security_mode_fail_ies_s& set_security_mode_fail() - { - set(types::security_mode_fail); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; +// SlotFormatIndicator ::= SEQUENCE +struct slot_format_ind_s { + using slot_format_comb_to_add_mod_list_l_ = dyn_array; + using slot_format_comb_to_release_list_l_ = bounded_array; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + bool ext = false; + bool slot_format_comb_to_add_mod_list_present = false; + bool slot_format_comb_to_release_list_present = false; + uint32_t sfi_rnti = 0; + uint8_t dci_payload_size = 1; + slot_format_comb_to_add_mod_list_l_ slot_format_comb_to_add_mod_list; + slot_format_comb_to_release_list_l_ slot_format_comb_to_release_list; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19659,106 +20226,250 @@ struct security_mode_fail_s { void to_json(json_writer& j) const; }; -// UEAssistanceInformation ::= SEQUENCE -struct ueassist_info_s { - struct crit_exts_c_ { - struct types_opts { - enum options { ue_assist_info, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; +// T-PollRetransmit ::= ENUMERATED +struct t_poll_retx_opts { + enum options { + ms5, + ms10, + ms15, + ms20, + ms25, + ms30, + ms35, + ms40, + ms45, + ms50, + ms55, + ms60, + ms65, + ms70, + ms75, + ms80, + ms85, + ms90, + ms95, + ms100, + ms105, + ms110, + ms115, + ms120, + ms125, + ms130, + ms135, + ms140, + ms145, + ms150, + ms155, + ms160, + ms165, + ms170, + ms175, + ms180, + ms185, + ms190, + ms195, + ms200, + ms205, + ms210, + ms215, + ms220, + ms225, + ms230, + ms235, + ms240, + ms245, + ms250, + ms300, + ms350, + ms400, + ms450, + ms500, + ms800, + ms1000, + ms2000, + ms4000, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - ueassist_info_ies_s& ue_assist_info() - { - assert_choice_type("ueAssistanceInformation", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const ueassist_info_ies_s& ue_assist_info() const - { - assert_choice_type("ueAssistanceInformation", type_.to_string(), "criticalExtensions"); - return c.get(); - } - ueassist_info_ies_s& set_ue_assist_info() - { - set(types::ue_assist_info); - return c.get(); - } + std::string to_string() const; + uint16_t to_number() const; +}; +typedef enumerated t_poll_retx_e; - private: - types type_; - choice_buffer_t c; +// T-Reassembly ::= ENUMERATED +struct t_reassembly_opts { + enum options { + ms0, + ms5, + ms10, + ms15, + ms20, + ms25, + ms30, + ms35, + ms40, + ms45, + ms50, + ms55, + ms60, + ms65, + ms70, + ms75, + ms80, + ms85, + ms90, + ms95, + ms100, + ms110, + ms120, + ms130, + ms140, + ms150, + ms160, + ms170, + ms180, + ms190, + ms200, + spare1, + nulltype + } value; + typedef uint8_t number_type; - void destroy_(); - }; + std::string to_string() const; + uint8_t to_number() const; +}; +typedef enumerated t_reassembly_e; - // member variables - crit_exts_c_ crit_exts; +// T-StatusProhibit ::= ENUMERATED +struct t_status_prohibit_opts { + enum options { + ms0, + ms5, + ms10, + ms15, + ms20, + ms25, + ms30, + ms35, + ms40, + ms45, + ms50, + ms55, + ms60, + ms65, + ms70, + ms75, + ms80, + ms85, + ms90, + ms95, + ms100, + ms105, + ms110, + ms115, + ms120, + ms125, + ms130, + ms135, + ms140, + ms145, + ms150, + ms155, + ms160, + ms165, + ms170, + ms175, + ms180, + ms185, + ms190, + ms195, + ms200, + ms205, + ms210, + ms215, + ms220, + ms225, + ms230, + ms235, + ms240, + ms245, + ms250, + ms300, + ms350, + ms400, + ms450, + ms500, + ms800, + ms1000, + ms1200, + ms1600, + ms2000, + ms2400, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + std::string to_string() const; + uint16_t to_number() const; }; +typedef enumerated t_status_prohibit_e; -// UECapabilityInformation ::= SEQUENCE -struct ue_cap_info_s { - struct crit_exts_c_ { +// TDD-UL-DL-SlotConfig ::= SEQUENCE +struct tdd_ul_dl_slot_cfg_s { + struct symbols_c_ { + struct explicit_s_ { + bool nrof_dl_symbols_present = false; + bool nrof_ul_symbols_present = false; + uint8_t nrof_dl_symbols = 1; + uint8_t nrof_ul_symbols = 1; + }; struct types_opts { - enum options { ue_cap_info, crit_exts_future, nulltype } value; + enum options { all_dl, all_ul, explicit_type, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } + symbols_c_() = default; void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - ue_cap_info_ies_s& ue_cap_info() + explicit_s_& explicit_type() { - assert_choice_type("ueCapabilityInformation", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("explicit", type_.to_string(), "symbols"); + return c; } - const ue_cap_info_ies_s& ue_cap_info() const + const explicit_s_& explicit_type() const { - assert_choice_type("ueCapabilityInformation", type_.to_string(), "criticalExtensions"); - return c.get(); + assert_choice_type("explicit", type_.to_string(), "symbols"); + return c; } - ue_cap_info_ies_s& set_ue_cap_info() + explicit_s_& set_explicit_type() { - set(types::ue_cap_info); - return c.get(); + set(types::explicit_type); + return c; } private: - types type_; - choice_buffer_t c; - - void destroy_(); + types type_; + explicit_s_ c; }; // member variables - uint8_t rrc_transaction_id = 0; - crit_exts_c_ crit_exts; + uint16_t slot_idx = 0; + symbols_c_ symbols; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19766,52 +20477,13 @@ struct ue_cap_info_s { void to_json(json_writer& j) const; }; -// ULInformationTransfer ::= SEQUENCE -struct ul_info_transfer_s { - struct crit_exts_c_ { - struct types_opts { - enum options { ul_info_transfer, crit_exts_future, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated types; - - // choice methods - crit_exts_c_() = default; - crit_exts_c_(const crit_exts_c_& other); - crit_exts_c_& operator=(const crit_exts_c_& other); - ~crit_exts_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - ul_info_transfer_ies_s& ul_info_transfer() - { - assert_choice_type("ulInformationTransfer", type_.to_string(), "criticalExtensions"); - return c.get(); - } - const ul_info_transfer_ies_s& ul_info_transfer() const - { - assert_choice_type("ulInformationTransfer", type_.to_string(), "criticalExtensions"); - return c.get(); - } - ul_info_transfer_ies_s& set_ul_info_transfer() - { - set(types::ul_info_transfer); - return c.get(); - } - - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - - // member variables - crit_exts_c_ crit_exts; +// UplinkConfigCommon ::= SEQUENCE +struct ul_cfg_common_s { + bool freq_info_ul_present = false; + bool init_ul_bwp_present = false; + freq_info_ul_s freq_info_ul; + bwp_ul_common_s init_ul_bwp; + time_align_timer_e dummy; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -19819,306 +20491,202 @@ struct ul_info_transfer_s { void to_json(json_writer& j) const; }; -// UL-DCCH-MessageType ::= CHOICE -struct ul_dcch_msg_type_c { - struct c1_c_ { - struct types_opts { - enum options { - meas_report, - rrc_recfg_complete, - rrc_setup_complete, - rrc_reest_complete, - rrc_resume_complete, - security_mode_complete, - security_mode_fail, - ul_info_transfer, - location_meas_ind, - ue_cap_info, - counter_check_resp, - ue_assist_info, - fail_info, - spare3, - spare2, - spare1, - nulltype - } value; +// CrossCarrierSchedulingConfig ::= SEQUENCE +struct cross_carrier_sched_cfg_s { + struct sched_cell_info_c_ { + struct own_s_ { + bool cif_presence = false; + }; + struct other_s_ { + uint8_t sched_cell_id = 0; + uint8_t cif_in_sched_cell = 1; + }; + struct types_opts { + enum options { own, other, nulltype } value; std::string to_string() const; }; typedef enumerated types; // choice methods - c1_c_() = default; - c1_c_(const c1_c_& other); - c1_c_& operator=(const c1_c_& other); - ~c1_c_() { destroy_(); } + sched_cell_info_c_() = default; + sched_cell_info_c_(const sched_cell_info_c_& other); + sched_cell_info_c_& operator=(const sched_cell_info_c_& other); + ~sched_cell_info_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - meas_report_s& meas_report() - { - assert_choice_type("measurementReport", type_.to_string(), "c1"); - return c.get(); - } - rrc_recfg_complete_s& rrc_recfg_complete() - { - assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "c1"); - return c.get(); - } - rrc_setup_complete_s& rrc_setup_complete() - { - assert_choice_type("rrcSetupComplete", type_.to_string(), "c1"); - return c.get(); - } - rrc_reest_complete_s& rrc_reest_complete() - { - assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "c1"); - return c.get(); - } - rrc_resume_complete_s& rrc_resume_complete() - { - assert_choice_type("rrcResumeComplete", type_.to_string(), "c1"); - return c.get(); - } - security_mode_complete_s& security_mode_complete() - { - assert_choice_type("securityModeComplete", type_.to_string(), "c1"); - return c.get(); - } - security_mode_fail_s& security_mode_fail() - { - assert_choice_type("securityModeFailure", type_.to_string(), "c1"); - return c.get(); - } - ul_info_transfer_s& ul_info_transfer() - { - assert_choice_type("ulInformationTransfer", type_.to_string(), "c1"); - return c.get(); - } - location_meas_ind_s& location_meas_ind() - { - assert_choice_type("locationMeasurementIndication", type_.to_string(), "c1"); - return c.get(); - } - ue_cap_info_s& ue_cap_info() - { - assert_choice_type("ueCapabilityInformation", type_.to_string(), "c1"); - return c.get(); - } - counter_check_resp_s& counter_check_resp() - { - assert_choice_type("counterCheckResponse", type_.to_string(), "c1"); - return c.get(); - } - ueassist_info_s& ue_assist_info() - { - assert_choice_type("ueAssistanceInformation", type_.to_string(), "c1"); - return c.get(); - } - fail_info_s& fail_info() - { - assert_choice_type("failureInformation", type_.to_string(), "c1"); - return c.get(); - } - const meas_report_s& meas_report() const - { - assert_choice_type("measurementReport", type_.to_string(), "c1"); - return c.get(); - } - const rrc_recfg_complete_s& rrc_recfg_complete() const - { - assert_choice_type("rrcReconfigurationComplete", type_.to_string(), "c1"); - return c.get(); - } - const rrc_setup_complete_s& rrc_setup_complete() const - { - assert_choice_type("rrcSetupComplete", type_.to_string(), "c1"); - return c.get(); - } - const rrc_reest_complete_s& rrc_reest_complete() const - { - assert_choice_type("rrcReestablishmentComplete", type_.to_string(), "c1"); - return c.get(); - } - const rrc_resume_complete_s& rrc_resume_complete() const - { - assert_choice_type("rrcResumeComplete", type_.to_string(), "c1"); - return c.get(); - } - const security_mode_complete_s& security_mode_complete() const - { - assert_choice_type("securityModeComplete", type_.to_string(), "c1"); - return c.get(); - } - const security_mode_fail_s& security_mode_fail() const - { - assert_choice_type("securityModeFailure", type_.to_string(), "c1"); - return c.get(); - } - const ul_info_transfer_s& ul_info_transfer() const - { - assert_choice_type("ulInformationTransfer", type_.to_string(), "c1"); - return c.get(); - } - const location_meas_ind_s& location_meas_ind() const - { - assert_choice_type("locationMeasurementIndication", type_.to_string(), "c1"); - return c.get(); - } - const ue_cap_info_s& ue_cap_info() const - { - assert_choice_type("ueCapabilityInformation", type_.to_string(), "c1"); - return c.get(); - } - const counter_check_resp_s& counter_check_resp() const - { - assert_choice_type("counterCheckResponse", type_.to_string(), "c1"); - return c.get(); - } - const ueassist_info_s& ue_assist_info() const - { - assert_choice_type("ueAssistanceInformation", type_.to_string(), "c1"); - return c.get(); - } - const fail_info_s& fail_info() const - { - assert_choice_type("failureInformation", type_.to_string(), "c1"); - return c.get(); - } - meas_report_s& set_meas_report() - { - set(types::meas_report); - return c.get(); - } - rrc_recfg_complete_s& set_rrc_recfg_complete() - { - set(types::rrc_recfg_complete); - return c.get(); - } - rrc_setup_complete_s& set_rrc_setup_complete() - { - set(types::rrc_setup_complete); - return c.get(); - } - rrc_reest_complete_s& set_rrc_reest_complete() - { - set(types::rrc_reest_complete); - return c.get(); - } - rrc_resume_complete_s& set_rrc_resume_complete() - { - set(types::rrc_resume_complete); - return c.get(); - } - security_mode_complete_s& set_security_mode_complete() - { - set(types::security_mode_complete); - return c.get(); - } - security_mode_fail_s& set_security_mode_fail() - { - set(types::security_mode_fail); - return c.get(); - } - ul_info_transfer_s& set_ul_info_transfer() + own_s_& own() { - set(types::ul_info_transfer); - return c.get(); + assert_choice_type("own", type_.to_string(), "schedulingCellInfo"); + return c.get(); } - location_meas_ind_s& set_location_meas_ind() + other_s_& other() { - set(types::location_meas_ind); - return c.get(); + assert_choice_type("other", type_.to_string(), "schedulingCellInfo"); + return c.get(); } - ue_cap_info_s& set_ue_cap_info() + const own_s_& own() const { - set(types::ue_cap_info); - return c.get(); + assert_choice_type("own", type_.to_string(), "schedulingCellInfo"); + return c.get(); } - counter_check_resp_s& set_counter_check_resp() + const other_s_& other() const { - set(types::counter_check_resp); - return c.get(); + assert_choice_type("other", type_.to_string(), "schedulingCellInfo"); + return c.get(); } - ueassist_info_s& set_ue_assist_info() + own_s_& set_own() { - set(types::ue_assist_info); - return c.get(); + set(types::own); + return c.get(); } - fail_info_s& set_fail_info() + other_s_& set_other() { - set(types::fail_info); - return c.get(); + set(types::other); + return c.get(); } - private: - types type_; - choice_buffer_t - c; + private: + types type_; + choice_buffer_t c; + + void destroy_(); + }; + + // member variables + bool ext = false; + sched_cell_info_c_ sched_cell_info; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// DL-AM-RLC ::= SEQUENCE +struct dl_am_rlc_s { + bool sn_field_len_present = false; + sn_field_len_am_e sn_field_len; + t_reassembly_e t_reassembly; + t_status_prohibit_e t_status_prohibit; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// DL-UM-RLC ::= SEQUENCE +struct dl_um_rlc_s { + bool sn_field_len_present = false; + sn_field_len_um_e sn_field_len; + t_reassembly_e t_reassembly; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PDCCH-ServingCellConfig ::= SEQUENCE +struct pdcch_serving_cell_cfg_s { + bool ext = false; + bool slot_format_ind_present = false; + setup_release_c slot_format_ind; + // ... - void destroy_(); + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// PDSCH-ServingCellConfig ::= SEQUENCE +struct pdsch_serving_cell_cfg_s { + struct xoverhead_opts { + enum options { xoh6, xoh12, xoh18, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; }; - struct types_opts { - enum options { c1, msg_class_ext, nulltype } value; + typedef enumerated xoverhead_e_; + struct nrof_harq_processes_for_pdsch_opts { + enum options { n2, n4, n6, n10, n12, n16, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated types; + typedef enumerated nrof_harq_processes_for_pdsch_e_; - // choice methods - ul_dcch_msg_type_c() = default; - ul_dcch_msg_type_c(const ul_dcch_msg_type_c& other); - ul_dcch_msg_type_c& operator=(const ul_dcch_msg_type_c& other); - ~ul_dcch_msg_type_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } + // member variables + bool ext = false; + bool code_block_group_tx_present = false; + bool xoverhead_present = false; + bool nrof_harq_processes_for_pdsch_present = false; + bool pucch_cell_present = false; + setup_release_c code_block_group_tx; + xoverhead_e_ xoverhead; + nrof_harq_processes_for_pdsch_e_ nrof_harq_processes_for_pdsch; + uint8_t pucch_cell = 0; + // ... + // group 0 + bool max_mimo_layers_present = false; + bool processing_type2_enabled_present = false; + uint8_t max_mimo_layers = 1; + bool processing_type2_enabled = false; + + // sequence methods SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; - // getters - c1_c_& c1() - { - assert_choice_type("c1", type_.to_string(), "UL-DCCH-MessageType"); - return c.get(); - } - const c1_c_& c1() const - { - assert_choice_type("c1", type_.to_string(), "UL-DCCH-MessageType"); - return c.get(); - } - c1_c_& set_c1() - { - set(types::c1); - return c.get(); - } +}; -private: - types type_; - choice_buffer_t c; +// RACH-ConfigDedicated ::= SEQUENCE +struct rach_cfg_ded_s { + bool ext = false; + bool cfra_present = false; + bool ra_prioritization_present = false; + cfra_s cfra; + ra_prioritization_s ra_prioritization; + // ... - void destroy_(); + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; -// UL-DCCH-Message ::= SEQUENCE -struct ul_dcch_msg_s { - ul_dcch_msg_type_c msg; +// SchedulingRequestToAddMod ::= SEQUENCE +struct sched_request_to_add_mod_s { + struct sr_prohibit_timer_opts { + enum options { ms1, ms2, ms4, ms8, ms16, ms32, ms64, ms128, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated sr_prohibit_timer_e_; + struct sr_trans_max_opts { + enum options { n4, n8, n16, n32, n64, spare3, spare2, spare1, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; + }; + typedef enumerated sr_trans_max_e_; + + // member variables + bool sr_prohibit_timer_present = false; + uint8_t sched_request_id = 0; + sr_prohibit_timer_e_ sr_prohibit_timer; + sr_trans_max_e_ sr_trans_max; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20126,105 +20694,147 @@ struct ul_dcch_msg_s { void to_json(json_writer& j) const; }; -// CA-BandwidthClassEUTRA ::= ENUMERATED -struct ca_bw_class_eutra_opts { - enum options { a, b, c, d, e, f, /*...*/ nulltype } value; +// ServingCellConfigCommon ::= SEQUENCE +struct serving_cell_cfg_common_s { + struct n_timing_advance_offset_opts { + enum options { n0, n25600, n39936, nulltype } value; + typedef uint16_t number_type; - std::string to_string() const; -}; -typedef enumerated ca_bw_class_eutra_e; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated n_timing_advance_offset_e_; + struct ssb_positions_in_burst_c_ { + struct types_opts { + enum options { short_bitmap, medium_bitmap, long_bitmap, nulltype } value; -// CA-BandwidthClassNR ::= ENUMERATED -struct ca_bw_class_nr_opts { - enum options { a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, /*...*/ nulltype } value; + std::string to_string() const; + }; + typedef enumerated types; - std::string to_string() const; -}; -typedef enumerated ca_bw_class_nr_e; + // choice methods + ssb_positions_in_burst_c_() = default; + ssb_positions_in_burst_c_(const ssb_positions_in_burst_c_& other); + ssb_positions_in_burst_c_& operator=(const ssb_positions_in_burst_c_& other); + ~ssb_positions_in_burst_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + fixed_bitstring<4>& short_bitmap() + { + assert_choice_type("shortBitmap", type_.to_string(), "ssb-PositionsInBurst"); + return c.get >(); + } + fixed_bitstring<8>& medium_bitmap() + { + assert_choice_type("mediumBitmap", type_.to_string(), "ssb-PositionsInBurst"); + return c.get >(); + } + fixed_bitstring<64>& long_bitmap() + { + assert_choice_type("longBitmap", type_.to_string(), "ssb-PositionsInBurst"); + return c.get >(); + } + const fixed_bitstring<4>& short_bitmap() const + { + assert_choice_type("shortBitmap", type_.to_string(), "ssb-PositionsInBurst"); + return c.get >(); + } + const fixed_bitstring<8>& medium_bitmap() const + { + assert_choice_type("mediumBitmap", type_.to_string(), "ssb-PositionsInBurst"); + return c.get >(); + } + const fixed_bitstring<64>& long_bitmap() const + { + assert_choice_type("longBitmap", type_.to_string(), "ssb-PositionsInBurst"); + return c.get >(); + } + fixed_bitstring<4>& set_short_bitmap() + { + set(types::short_bitmap); + return c.get >(); + } + fixed_bitstring<8>& set_medium_bitmap() + { + set(types::medium_bitmap); + return c.get >(); + } + fixed_bitstring<64>& set_long_bitmap() + { + set(types::long_bitmap); + return c.get >(); + } -// BandParameters ::= CHOICE -struct band_params_c { - struct eutra_s_ { - bool ca_bw_class_dl_eutra_present = false; - bool ca_bw_class_ul_eutra_present = false; - uint16_t band_eutra = 1; - ca_bw_class_eutra_e ca_bw_class_dl_eutra; - ca_bw_class_eutra_e ca_bw_class_ul_eutra; + private: + types type_; + choice_buffer_t > c; + + void destroy_(); }; - struct nr_s_ { - bool ca_bw_class_dl_nr_present = false; - bool ca_bw_class_ul_nr_present = false; - uint16_t band_nr = 1; - ca_bw_class_nr_e ca_bw_class_dl_nr; - ca_bw_class_nr_e ca_bw_class_ul_nr; + struct ssb_periodicity_serving_cell_opts { + enum options { ms5, ms10, ms20, ms40, ms80, ms160, spare2, spare1, nulltype } value; + typedef uint8_t number_type; + + std::string to_string() const; + uint8_t to_number() const; }; - struct types_opts { - enum options { eutra, nr, nulltype } value; + typedef enumerated ssb_periodicity_serving_cell_e_; + struct dmrs_type_a_position_opts { + enum options { pos2, pos3, nulltype } value; + typedef uint8_t number_type; std::string to_string() const; + uint8_t to_number() const; }; - typedef enumerated types; + typedef enumerated dmrs_type_a_position_e_; + using rate_match_pattern_to_add_mod_list_l_ = dyn_array; + using rate_match_pattern_to_release_list_l_ = bounded_array; + + // member variables + bool ext = false; + bool pci_present = false; + bool dl_cfg_common_present = false; + bool ul_cfg_common_present = false; + bool supplementary_ul_cfg_present = false; + bool n_timing_advance_offset_present = false; + bool ssb_positions_in_burst_present = false; + bool ssb_periodicity_serving_cell_present = false; + bool lte_crs_to_match_around_present = false; + bool rate_match_pattern_to_add_mod_list_present = false; + bool rate_match_pattern_to_release_list_present = false; + bool ssb_subcarrier_spacing_present = false; + bool tdd_ul_dl_cfg_common_present = false; + uint16_t pci = 0; + dl_cfg_common_s dl_cfg_common; + ul_cfg_common_s ul_cfg_common; + ul_cfg_common_s supplementary_ul_cfg; + n_timing_advance_offset_e_ n_timing_advance_offset; + ssb_positions_in_burst_c_ ssb_positions_in_burst; + ssb_periodicity_serving_cell_e_ ssb_periodicity_serving_cell; + dmrs_type_a_position_e_ dmrs_type_a_position; + setup_release_c lte_crs_to_match_around; + rate_match_pattern_to_add_mod_list_l_ rate_match_pattern_to_add_mod_list; + rate_match_pattern_to_release_list_l_ rate_match_pattern_to_release_list; + subcarrier_spacing_e ssb_subcarrier_spacing; + tdd_ul_dl_cfg_common_s tdd_ul_dl_cfg_common; + int8_t ss_pbch_block_pwr = -60; + // ... - // choice methods - band_params_c() = default; - band_params_c(const band_params_c& other); - band_params_c& operator=(const band_params_c& other); - ~band_params_c() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } + // sequence methods SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; - // getters - eutra_s_& eutra() - { - assert_choice_type("eutra", type_.to_string(), "BandParameters"); - return c.get(); - } - nr_s_& nr() - { - assert_choice_type("nr", type_.to_string(), "BandParameters"); - return c.get(); - } - const eutra_s_& eutra() const - { - assert_choice_type("eutra", type_.to_string(), "BandParameters"); - return c.get(); - } - const nr_s_& nr() const - { - assert_choice_type("nr", type_.to_string(), "BandParameters"); - return c.get(); - } - eutra_s_& set_eutra() - { - set(types::eutra); - return c.get(); - } - nr_s_& set_nr() - { - set(types::nr); - return c.get(); - } - -private: - types type_; - choice_buffer_t c; - - void destroy_(); }; -// CA-ParametersEUTRA ::= SEQUENCE -struct ca_params_eutra_s { - bool ext = false; - bool multiple_timing_advance_present = false; - bool simul_rx_tx_present = false; - bool supported_naics_minus2_crs_ap_present = false; - bool add_rx_tx_performance_req_present = false; - bool ue_ca_pwr_class_n_present = false; - bool supported_bw_combination_set_eutra_v1530_present = false; - bounded_bitstring<1, 8> supported_naics_minus2_crs_ap; - bounded_bitstring<1, 32> supported_bw_combination_set_eutra_v1530; +// TAG ::= SEQUENCE +struct tag_s { + bool ext = false; + uint8_t tag_id = 0; + time_align_timer_e time_align_timer; // ... // sequence methods @@ -20233,28 +20843,17 @@ struct ca_params_eutra_s { void to_json(json_writer& j) const; }; -// CA-ParametersNR ::= SEQUENCE -struct ca_params_nr_s { - struct supported_num_tag_opts { - enum options { n2, n3, n4, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated supported_num_tag_e_; +// TDD-UL-DL-ConfigDedicated ::= SEQUENCE +struct tdd_ul_dl_cfg_ded_s { + using slot_specific_cfgs_to_add_mod_list_l_ = dyn_array; + using slot_specific_cfgs_to_release_list_l_ = dyn_array; // member variables - bool ext = false; - bool multiple_timing_advances_present = false; - bool parallel_tx_srs_pucch_pusch_present = false; - bool parallel_tx_prach_srs_pucch_pusch_present = false; - bool simul_rx_tx_inter_band_ca_present = false; - bool simul_rx_tx_sul_present = false; - bool diff_numerology_across_pucch_group_present = false; - bool diff_numerology_within_pucch_group_present = false; - bool supported_num_tag_present = false; - supported_num_tag_e_ supported_num_tag; + bool ext = false; + bool slot_specific_cfgs_to_add_mod_list_present = false; + bool slot_specific_cfgs_to_release_list_present = false; + slot_specific_cfgs_to_add_mod_list_l_ slot_specific_cfgs_to_add_mod_list; + slot_specific_cfgs_to_release_list_l_ slot_specific_cfgs_to_release_list; // ... // sequence methods @@ -20263,46 +20862,24 @@ struct ca_params_nr_s { void to_json(json_writer& j) const; }; -// MRDC-Parameters ::= SEQUENCE -struct mrdc_params_s { - struct ul_sharing_eutra_nr_opts { - enum options { tdm, fdm, both, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated ul_sharing_eutra_nr_e_; - struct ul_switching_time_eutra_nr_opts { - enum options { type1, type2, nulltype } value; +// UL-AM-RLC ::= SEQUENCE +struct ul_am_rlc_s { + struct max_retx_thres_opts { + enum options { t1, t2, t3, t4, t6, t8, t16, t32, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated ul_switching_time_eutra_nr_e_; - struct intra_band_endc_support_v1540_opts { - enum options { non_contiguous, both, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated intra_band_endc_support_v1540_e_; + typedef enumerated max_retx_thres_e_; // member variables - bool ext = false; - bool single_ul_tx_present = false; - bool dynamic_pwr_sharing_present = false; - bool tdm_pattern_present = false; - bool ul_sharing_eutra_nr_present = false; - bool ul_switching_time_eutra_nr_present = false; - bool simul_rx_tx_inter_band_endc_present = false; - bool async_intra_band_endc_present = false; - ul_sharing_eutra_nr_e_ ul_sharing_eutra_nr; - ul_switching_time_eutra_nr_e_ ul_switching_time_eutra_nr; - // ... - // group 0 - bool dual_pa_architecture_present = false; - bool intra_band_endc_support_v1540_present = false; - bool ul_timing_align_eutra_nr_present = false; - intra_band_endc_support_v1540_e_ intra_band_endc_support_v1540; + bool sn_field_len_present = false; + sn_field_len_am_e sn_field_len; + t_poll_retx_e t_poll_retx; + poll_pdu_e poll_pdu; + poll_byte_e poll_byte; + max_retx_thres_e_ max_retx_thres; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20310,22 +20887,42 @@ struct mrdc_params_s { void to_json(json_writer& j) const; }; -// BandCombination ::= SEQUENCE -struct band_combination_s { - using band_list_l_ = dyn_array; +// UL-UM-RLC ::= SEQUENCE +struct ul_um_rlc_s { + bool sn_field_len_present = false; + sn_field_len_um_e sn_field_len; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UplinkConfig ::= SEQUENCE +struct ul_cfg_s { + using ul_bwp_to_release_list_l_ = bounded_array; + using ul_bwp_to_add_mod_list_l_ = dyn_array; + using ul_ch_bw_per_scs_list_l_ = dyn_array; // member variables - bool ca_params_eutra_present = false; - bool ca_params_nr_present = false; - bool mrdc_params_present = false; - bool supported_bw_combination_set_present = false; - bool pwr_class_v1530_present = false; - band_list_l_ band_list; - uint16_t feature_set_combination = 0; - ca_params_eutra_s ca_params_eutra; - ca_params_nr_s ca_params_nr; - mrdc_params_s mrdc_params; - bounded_bitstring<1, 32> supported_bw_combination_set; + bool ext = false; + bool init_ul_bwp_present = false; + bool ul_bwp_to_release_list_present = false; + bool ul_bwp_to_add_mod_list_present = false; + bool first_active_ul_bwp_id_present = false; + bool pusch_serving_cell_cfg_present = false; + bool carrier_switching_present = false; + bwp_ul_ded_s init_ul_bwp; + ul_bwp_to_release_list_l_ ul_bwp_to_release_list; + ul_bwp_to_add_mod_list_l_ ul_bwp_to_add_mod_list; + uint8_t first_active_ul_bwp_id = 0; + setup_release_c pusch_serving_cell_cfg; + setup_release_c carrier_switching; + // ... + // group 0 + bool pwr_boost_pi2_bpsk_present = false; + bool pwr_boost_pi2_bpsk = false; + copy_ptr ul_ch_bw_per_scs_list; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20333,66 +20930,76 @@ struct band_combination_s { void to_json(json_writer& j) const; }; -// SRS-SwitchingTimeEUTRA ::= SEQUENCE -struct srs_switching_time_eutra_s { - struct switching_time_dl_opts { +// BSR-Config ::= SEQUENCE +struct bsr_cfg_s { + struct periodic_bsr_timer_opts { enum options { - n0, - n0dot5, - n1, - n1dot5, - n2, - n2dot5, - n3, - n3dot5, - n4, - n4dot5, - n5, - n5dot5, - n6, - n6dot5, - n7, + sf1, + sf5, + sf10, + sf16, + sf20, + sf32, + sf40, + sf64, + sf80, + sf128, + sf160, + sf320, + sf640, + sf1280, + sf2560, + infinity, nulltype } value; - typedef float number_type; + typedef int16_t number_type; std::string to_string() const; - float to_number() const; - std::string to_number_string() const; + int16_t to_number() const; }; - typedef enumerated switching_time_dl_e_; - struct switching_time_ul_opts { + typedef enumerated periodic_bsr_timer_e_; + struct retx_bsr_timer_opts { enum options { - n0, - n0dot5, - n1, - n1dot5, - n2, - n2dot5, - n3, - n3dot5, - n4, - n4dot5, - n5, - n5dot5, - n6, - n6dot5, - n7, + sf10, + sf20, + sf40, + sf80, + sf160, + sf320, + sf640, + sf1280, + sf2560, + sf5120, + sf10240, + spare5, + spare4, + spare3, + spare2, + spare1, nulltype } value; - typedef float number_type; + typedef uint16_t number_type; std::string to_string() const; - float to_number() const; - std::string to_number_string() const; + uint16_t to_number() const; }; - typedef enumerated switching_time_ul_e_; + typedef enumerated retx_bsr_timer_e_; + struct lc_ch_sr_delay_timer_opts { + enum options { sf20, sf40, sf64, sf128, sf512, sf1024, sf2560, spare1, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated lc_ch_sr_delay_timer_e_; // member variables - bool switching_time_dl_present = false; - bool switching_time_ul_present = false; - switching_time_dl_e_ switching_time_dl; - switching_time_ul_e_ switching_time_ul; + bool ext = false; + bool lc_ch_sr_delay_timer_present = false; + periodic_bsr_timer_e_ periodic_bsr_timer; + retx_bsr_timer_e_ retx_bsr_timer; + lc_ch_sr_delay_timer_e_ lc_ch_sr_delay_timer; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20400,323 +21007,642 @@ struct srs_switching_time_eutra_s { void to_json(json_writer& j) const; }; -// SRS-SwitchingTimeNR ::= SEQUENCE -struct srs_switching_time_nr_s { - struct switching_time_dl_opts { - enum options { n0us, n30us, n100us, n140us, n200us, n300us, n500us, n900us, nulltype } value; +// DRX-Config ::= SEQUENCE +struct drx_cfg_s { + struct drx_on_dur_timer_c_ { + struct milli_seconds_opts { + enum options { + ms1, + ms2, + ms3, + ms4, + ms5, + ms6, + ms8, + ms10, + ms20, + ms30, + ms40, + ms50, + ms60, + ms80, + ms100, + ms200, + ms300, + ms400, + ms500, + ms600, + ms800, + ms1000, + ms1200, + ms1600, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated milli_seconds_e_; + struct types_opts { + enum options { sub_milli_seconds, milli_seconds, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated types; + + // choice methods + drx_on_dur_timer_c_() = default; + drx_on_dur_timer_c_(const drx_on_dur_timer_c_& other); + drx_on_dur_timer_c_& operator=(const drx_on_dur_timer_c_& other); + ~drx_on_dur_timer_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + uint8_t& sub_milli_seconds() + { + assert_choice_type("subMilliSeconds", type_.to_string(), "drx-onDurationTimer"); + return c.get(); + } + milli_seconds_e_& milli_seconds() + { + assert_choice_type("milliSeconds", type_.to_string(), "drx-onDurationTimer"); + return c.get(); + } + const uint8_t& sub_milli_seconds() const + { + assert_choice_type("subMilliSeconds", type_.to_string(), "drx-onDurationTimer"); + return c.get(); + } + const milli_seconds_e_& milli_seconds() const + { + assert_choice_type("milliSeconds", type_.to_string(), "drx-onDurationTimer"); + return c.get(); + } + uint8_t& set_sub_milli_seconds() + { + set(types::sub_milli_seconds); + return c.get(); + } + milli_seconds_e_& set_milli_seconds() + { + set(types::milli_seconds); + return c.get(); + } + + private: + types type_; + pod_choice_buffer_t c; + + void destroy_(); + }; + struct drx_inactivity_timer_opts { + enum options { + ms0, + ms1, + ms2, + ms3, + ms4, + ms5, + ms6, + ms8, + ms10, + ms20, + ms30, + ms40, + ms50, + ms60, + ms80, + ms100, + ms200, + ms300, + ms500, + ms750, + ms1280, + ms1920, + ms2560, + spare9, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; typedef uint16_t number_type; std::string to_string() const; uint16_t to_number() const; }; - typedef enumerated switching_time_dl_e_; - struct switching_time_ul_opts { - enum options { n0us, n30us, n100us, n140us, n200us, n300us, n500us, n900us, nulltype } value; + typedef enumerated drx_inactivity_timer_e_; + struct drx_retx_timer_dl_opts { + enum options { + sl0, + sl1, + sl2, + sl4, + sl6, + sl8, + sl16, + sl24, + sl33, + sl40, + sl64, + sl80, + sl96, + sl112, + sl128, + sl160, + sl320, + spare15, + spare14, + spare13, + spare12, + spare11, + spare10, + spare9, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; typedef uint16_t number_type; std::string to_string() const; uint16_t to_number() const; }; - typedef enumerated switching_time_ul_e_; - - // member variables - bool switching_time_dl_present = false; - bool switching_time_ul_present = false; - switching_time_dl_e_ switching_time_dl; - switching_time_ul_e_ switching_time_ul; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BandParameters-v1540 ::= SEQUENCE -struct band_params_v1540_s { - struct srs_carrier_switch_c_ { - struct nr_s_ { - using srs_switching_times_list_nr_l_ = dyn_array; - - // member variables - srs_switching_times_list_nr_l_ srs_switching_times_list_nr; - }; - struct eutra_s_ { - using srs_switching_times_list_eutra_l_ = dyn_array; + typedef enumerated drx_retx_timer_dl_e_; + struct drx_retx_timer_ul_opts { + enum options { + sl0, + sl1, + sl2, + sl4, + sl6, + sl8, + sl16, + sl24, + sl33, + sl40, + sl64, + sl80, + sl96, + sl112, + sl128, + sl160, + sl320, + spare15, + spare14, + spare13, + spare12, + spare11, + spare10, + spare9, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; - // member variables - srs_switching_times_list_eutra_l_ srs_switching_times_list_eutra; - }; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated drx_retx_timer_ul_e_; + struct drx_long_cycle_start_offset_c_ { struct types_opts { - enum options { nr, eutra, nulltype } value; + enum options { + ms10, + ms20, + ms32, + ms40, + ms60, + ms64, + ms70, + ms80, + ms128, + ms160, + ms256, + ms320, + ms512, + ms640, + ms1024, + ms1280, + ms2048, + ms2560, + ms5120, + ms10240, + nulltype + } value; + typedef uint16_t number_type; std::string to_string() const; + uint16_t to_number() const; }; typedef enumerated types; // choice methods - srs_carrier_switch_c_() = default; - srs_carrier_switch_c_(const srs_carrier_switch_c_& other); - srs_carrier_switch_c_& operator=(const srs_carrier_switch_c_& other); - ~srs_carrier_switch_c_() { destroy_(); } + drx_long_cycle_start_offset_c_() = default; + drx_long_cycle_start_offset_c_(const drx_long_cycle_start_offset_c_& other); + drx_long_cycle_start_offset_c_& operator=(const drx_long_cycle_start_offset_c_& other); + ~drx_long_cycle_start_offset_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - nr_s_& nr() + uint8_t& ms10() + { + assert_choice_type("ms10", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms20() + { + assert_choice_type("ms20", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms32() + { + assert_choice_type("ms32", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms40() + { + assert_choice_type("ms40", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms60() + { + assert_choice_type("ms60", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms64() + { + assert_choice_type("ms64", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms70() + { + assert_choice_type("ms70", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms80() + { + assert_choice_type("ms80", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms128() + { + assert_choice_type("ms128", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint8_t& ms160() + { + assert_choice_type("ms160", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms256() + { + assert_choice_type("ms256", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms320() + { + assert_choice_type("ms320", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms512() + { + assert_choice_type("ms512", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms640() + { + assert_choice_type("ms640", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms1024() + { + assert_choice_type("ms1024", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms1280() + { + assert_choice_type("ms1280", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms2048() + { + assert_choice_type("ms2048", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms2560() + { + assert_choice_type("ms2560", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms5120() + { + assert_choice_type("ms5120", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + uint16_t& ms10240() + { + assert_choice_type("ms10240", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms10() const + { + assert_choice_type("ms10", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms20() const + { + assert_choice_type("ms20", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms32() const + { + assert_choice_type("ms32", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms40() const + { + assert_choice_type("ms40", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms60() const + { + assert_choice_type("ms60", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms64() const + { + assert_choice_type("ms64", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms70() const + { + assert_choice_type("ms70", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms80() const + { + assert_choice_type("ms80", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms128() const + { + assert_choice_type("ms128", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint8_t& ms160() const + { + assert_choice_type("ms160", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms256() const + { + assert_choice_type("ms256", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms320() const + { + assert_choice_type("ms320", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms512() const + { + assert_choice_type("ms512", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms640() const + { + assert_choice_type("ms640", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms1024() const + { + assert_choice_type("ms1024", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms1280() const + { + assert_choice_type("ms1280", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms2048() const + { + assert_choice_type("ms2048", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms2560() const + { + assert_choice_type("ms2560", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); + } + const uint16_t& ms5120() const { - assert_choice_type("nr", type_.to_string(), "srs-CarrierSwitch"); - return c.get(); + assert_choice_type("ms5120", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); } - eutra_s_& eutra() + const uint16_t& ms10240() const { - assert_choice_type("eutra", type_.to_string(), "srs-CarrierSwitch"); - return c.get(); + assert_choice_type("ms10240", type_.to_string(), "drx-LongCycleStartOffset"); + return c.get(); } - const nr_s_& nr() const + uint8_t& set_ms10() { - assert_choice_type("nr", type_.to_string(), "srs-CarrierSwitch"); - return c.get(); + set(types::ms10); + return c.get(); } - const eutra_s_& eutra() const + uint8_t& set_ms20() { - assert_choice_type("eutra", type_.to_string(), "srs-CarrierSwitch"); - return c.get(); + set(types::ms20); + return c.get(); } - nr_s_& set_nr() + uint8_t& set_ms32() { - set(types::nr); - return c.get(); + set(types::ms32); + return c.get(); } - eutra_s_& set_eutra() + uint8_t& set_ms40() { - set(types::eutra); - return c.get(); + set(types::ms40); + return c.get(); + } + uint8_t& set_ms60() + { + set(types::ms60); + return c.get(); + } + uint8_t& set_ms64() + { + set(types::ms64); + return c.get(); + } + uint8_t& set_ms70() + { + set(types::ms70); + return c.get(); + } + uint8_t& set_ms80() + { + set(types::ms80); + return c.get(); + } + uint8_t& set_ms128() + { + set(types::ms128); + return c.get(); + } + uint8_t& set_ms160() + { + set(types::ms160); + return c.get(); + } + uint16_t& set_ms256() + { + set(types::ms256); + return c.get(); + } + uint16_t& set_ms320() + { + set(types::ms320); + return c.get(); + } + uint16_t& set_ms512() + { + set(types::ms512); + return c.get(); + } + uint16_t& set_ms640() + { + set(types::ms640); + return c.get(); + } + uint16_t& set_ms1024() + { + set(types::ms1024); + return c.get(); + } + uint16_t& set_ms1280() + { + set(types::ms1280); + return c.get(); + } + uint16_t& set_ms2048() + { + set(types::ms2048); + return c.get(); + } + uint16_t& set_ms2560() + { + set(types::ms2560); + return c.get(); + } + uint16_t& set_ms5120() + { + set(types::ms5120); + return c.get(); + } + uint16_t& set_ms10240() + { + set(types::ms10240); + return c.get(); } - private: - types type_; - choice_buffer_t c; - - void destroy_(); - }; - struct srs_tx_switch_v1540_s_ { - struct supported_srs_tx_port_switch_opts { - enum options { t1r2, t1r4, t2r4, t1r4_t2r4, t1r1, t2r2, t4r4, not_supported, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated supported_srs_tx_port_switch_e_; - - // member variables - bool tx_switch_impact_to_rx_present = false; - bool tx_switch_with_another_band_present = false; - supported_srs_tx_port_switch_e_ supported_srs_tx_port_switch; - uint8_t tx_switch_impact_to_rx = 1; - uint8_t tx_switch_with_another_band = 1; - }; - - // member variables - bool srs_carrier_switch_present = false; - bool srs_tx_switch_v1540_present = false; - srs_carrier_switch_c_ srs_carrier_switch; - srs_tx_switch_v1540_s_ srs_tx_switch_v1540; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CA-ParametersNR-v1540 ::= SEQUENCE -struct ca_params_nr_v1540_s { - struct csi_rs_im_reception_for_feedback_per_band_comb_s_ { - bool max_num_simul_nzp_csi_rs_act_bwp_all_cc_present = false; - bool total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present = false; - uint8_t max_num_simul_nzp_csi_rs_act_bwp_all_cc = 1; - uint16_t total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc = 2; - }; - - // member variables - bool simul_srs_assoc_csi_rs_all_cc_present = false; - bool csi_rs_im_reception_for_feedback_per_band_comb_present = false; - bool simul_csi_reports_all_cc_present = false; - bool dual_pa_architecture_present = false; - uint8_t simul_srs_assoc_csi_rs_all_cc = 5; - csi_rs_im_reception_for_feedback_per_band_comb_s_ csi_rs_im_reception_for_feedback_per_band_comb; - uint8_t simul_csi_reports_all_cc = 5; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BandCombination-v1540 ::= SEQUENCE -struct band_combination_v1540_s { - using band_list_v1540_l_ = dyn_array; - - // member variables - bool ca_params_nr_v1540_present = false; - band_list_v1540_l_ band_list_v1540; - ca_params_nr_v1540_s ca_params_nr_v1540; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CA-ParametersNR-v1550 ::= SEQUENCE -struct ca_params_nr_v1550_s { - bool aperiodic_csi_diff_scs_present = false; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BandCombination-v1550 ::= SEQUENCE -struct band_combination_v1550_s { - ca_params_nr_v1550_s ca_params_nr_v1550; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BandCombinationList ::= SEQUENCE (SIZE (1..65536)) OF BandCombination -using band_combination_list_l = dyn_array; - -// BandCombinationList-v1540 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1540 -using band_combination_list_v1540_l = dyn_array; - -// BandCombinationList-v1550 ::= SEQUENCE (SIZE (1..65536)) OF BandCombination-v1550 -using band_combination_list_v1550_l = dyn_array; - -// SupportedCSI-RS-Resource ::= SEQUENCE -struct supported_csi_rs_res_s { - struct max_num_tx_ports_per_res_opts { - enum options { p2, p4, p8, p12, p16, p24, p32, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_num_tx_ports_per_res_e_; - - // member variables - max_num_tx_ports_per_res_e_ max_num_tx_ports_per_res; - uint8_t max_num_res_per_band = 1; - uint16_t total_num_tx_ports_per_band = 2; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// BeamManagementSSB-CSI-RS ::= SEQUENCE -struct beam_management_ssb_csi_rs_s { - struct max_num_ssb_csi_rs_res_one_tx_opts { - enum options { n0, n8, n16, n32, n64, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_num_ssb_csi_rs_res_one_tx_e_; - struct max_num_csi_rs_res_opts { - enum options { n0, n4, n8, n16, n32, n64, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_num_csi_rs_res_e_; - struct max_num_csi_rs_res_two_tx_opts { - enum options { n0, n4, n8, n16, n32, n64, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_num_csi_rs_res_two_tx_e_; - struct supported_csi_rs_density_opts { - enum options { one, three, one_and_three, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated supported_csi_rs_density_e_; - struct max_num_aperiodic_csi_rs_res_opts { - enum options { n0, n1, n4, n8, n16, n32, n64, nulltype } value; - typedef uint8_t number_type; + private: + types type_; + pod_choice_buffer_t c; - std::string to_string() const; - uint8_t to_number() const; + void destroy_(); }; - typedef enumerated max_num_aperiodic_csi_rs_res_e_; - - // member variables - bool supported_csi_rs_density_present = false; - max_num_ssb_csi_rs_res_one_tx_e_ max_num_ssb_csi_rs_res_one_tx; - max_num_csi_rs_res_e_ max_num_csi_rs_res; - max_num_csi_rs_res_two_tx_e_ max_num_csi_rs_res_two_tx; - supported_csi_rs_density_e_ supported_csi_rs_density; - max_num_aperiodic_csi_rs_res_e_ max_num_aperiodic_csi_rs_res; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CSI-RS-ForTracking ::= SEQUENCE -struct csi_rs_for_tracking_s { - uint8_t max_burst_len = 1; - uint8_t max_simul_res_sets_per_cc = 1; - uint8_t max_cfgured_res_sets_per_cc = 1; - uint16_t max_cfgured_res_sets_all_cc = 1; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; + struct short_drx_s_ { + struct drx_short_cycle_opts { + enum options { + ms2, + ms3, + ms4, + ms5, + ms6, + ms7, + ms8, + ms10, + ms14, + ms16, + ms20, + ms30, + ms32, + ms35, + ms40, + ms64, + ms80, + ms128, + ms160, + ms256, + ms320, + ms512, + ms640, + spare9, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; -// CSI-RS-IM-ReceptionForFeedback ::= SEQUENCE -struct csi_rs_im_reception_for_feedback_s { - struct max_cfg_num_csi_im_per_cc_opts { - enum options { n1, n2, n4, n8, n16, n32, nulltype } value; - typedef uint8_t number_type; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated drx_short_cycle_e_; - std::string to_string() const; - uint8_t to_number() const; + // member variables + drx_short_cycle_e_ drx_short_cycle; + uint8_t drx_short_cycle_timer = 1; }; - typedef enumerated max_cfg_num_csi_im_per_cc_e_; // member variables - uint8_t max_cfg_num_nzp_csi_rs_per_cc = 1; - uint16_t max_cfg_num_ports_across_nzp_csi_rs_per_cc = 2; - max_cfg_num_csi_im_per_cc_e_ max_cfg_num_csi_im_per_cc; - uint8_t max_num_simul_nzp_csi_rs_per_cc = 1; - uint16_t total_num_ports_simul_nzp_csi_rs_per_cc = 2; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// CSI-RS-ProcFrameworkForSRS ::= SEQUENCE -struct csi_rs_proc_framework_for_srs_s { - uint8_t max_num_periodic_srs_assoc_csi_rs_per_bwp = 1; - uint8_t max_num_aperiodic_srs_assoc_csi_rs_per_bwp = 1; - uint8_t max_num_sp_srs_assoc_csi_rs_per_bwp = 0; - uint8_t simul_srs_assoc_csi_rs_per_cc = 1; + bool short_drx_present = false; + drx_on_dur_timer_c_ drx_on_dur_timer; + drx_inactivity_timer_e_ drx_inactivity_timer; + uint8_t drx_harq_rtt_timer_dl = 0; + uint8_t drx_harq_rtt_timer_ul = 0; + drx_retx_timer_dl_e_ drx_retx_timer_dl; + drx_retx_timer_ul_e_ drx_retx_timer_ul; + drx_long_cycle_start_offset_c_ drx_long_cycle_start_offset; + short_drx_s_ short_drx; + uint8_t drx_slot_offset = 0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20724,117 +21650,122 @@ struct csi_rs_proc_framework_for_srs_s { void to_json(json_writer& j) const; }; -// CSI-ReportFramework ::= SEQUENCE -struct csi_report_framework_s { - struct max_num_aperiodic_csi_trigger_state_per_cc_opts { - enum options { n3, n7, n15, n31, n63, n128, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_num_aperiodic_csi_trigger_state_per_cc_e_; - - // member variables - uint8_t max_num_periodic_csi_per_bwp_for_csi_report = 1; - uint8_t max_num_aperiodic_csi_per_bwp_for_csi_report = 1; - uint8_t max_num_semi_persistent_csi_per_bwp_for_csi_report = 0; - uint8_t max_num_periodic_csi_per_bwp_for_beam_report = 1; - uint8_t max_num_aperiodic_csi_per_bwp_for_beam_report = 1; - max_num_aperiodic_csi_trigger_state_per_cc_e_ max_num_aperiodic_csi_trigger_state_per_cc; - uint8_t max_num_semi_persistent_csi_per_bwp_for_beam_report = 0; - uint8_t simul_csi_reports_per_cc = 1; +// DataInactivityTimer ::= ENUMERATED +struct data_inactivity_timer_opts { + enum options { s1, s2, s3, s5, s7, s10, s15, s20, s40, s50, s60, s80, s100, s120, s150, s180, nulltype } value; + typedef uint8_t number_type; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + std::string to_string() const; + uint8_t to_number() const; }; +typedef enumerated data_inactivity_timer_e; -// CodebookParameters ::= SEQUENCE -struct codebook_params_s { - struct type1_s_ { - struct single_panel_s_ { - using supported_csi_rs_res_list_l_ = dyn_array; - struct modes_opts { - enum options { mode1, mode1and_mode2, nulltype } value; - - std::string to_string() const; - }; - typedef enumerated modes_e_; - - // member variables - supported_csi_rs_res_list_l_ supported_csi_rs_res_list; - modes_e_ modes; - uint8_t max_num_csi_rs_per_res_set = 1; - }; - struct multi_panel_s_ { - using supported_csi_rs_res_list_l_ = dyn_array; - struct modes_opts { - enum options { mode1, mode2, both, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated modes_e_; - struct nrof_panels_opts { - enum options { n2, n4, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated nrof_panels_e_; +// LogicalChannelConfig ::= SEQUENCE +struct lc_ch_cfg_s { + struct ul_specific_params_s_ { + struct prioritised_bit_rate_opts { + enum options { + kbps0, + kbps8, + kbps16, + kbps32, + kbps64, + kbps128, + kbps256, + kbps512, + kbps1024, + kbps2048, + kbps4096, + kbps8192, + kbps16384, + kbps32768, + kbps65536, + infinity, + nulltype + } value; + typedef int32_t number_type; - // member variables - supported_csi_rs_res_list_l_ supported_csi_rs_res_list; - modes_e_ modes; - nrof_panels_e_ nrof_panels; - uint8_t max_num_csi_rs_per_res_set = 1; + std::string to_string() const; + int32_t to_number() const; }; + typedef enumerated prioritised_bit_rate_e_; + struct bucket_size_dur_opts { + enum options { + ms5, + ms10, + ms20, + ms50, + ms100, + ms150, + ms300, + ms500, + ms1000, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; - // member variables - bool multi_panel_present = false; - single_panel_s_ single_panel; - multi_panel_s_ multi_panel; - }; - struct type2_s_ { - using supported_csi_rs_res_list_l_ = dyn_array; - struct amplitude_scaling_type_opts { - enum options { wideband, wideband_and_subband, nulltype } value; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated bucket_size_dur_e_; + using allowed_serving_cells_l_ = bounded_array; + using allowed_scs_list_l_ = bounded_array; + struct max_pusch_dur_opts { + enum options { ms0p02, ms0p04, ms0p0625, ms0p125, ms0p25, ms0p5, spare2, spare1, nulltype } value; std::string to_string() const; }; - typedef enumerated amplitude_scaling_type_e_; - - // member variables - bool amplitude_subset_restrict_present = false; - supported_csi_rs_res_list_l_ supported_csi_rs_res_list; - uint8_t param_lx = 2; - amplitude_scaling_type_e_ amplitude_scaling_type; - }; - struct type2_port_sel_s_ { - using supported_csi_rs_res_list_l_ = dyn_array; - struct amplitude_scaling_type_opts { - enum options { wideband, wideband_and_subband, nulltype } value; + typedef enumerated max_pusch_dur_e_; + struct bit_rate_query_prohibit_timer_opts { + enum options { s0, s0dot4, s0dot8, s1dot6, s3, s6, s12, s30, nulltype } value; + typedef float number_type; std::string to_string() const; + float to_number() const; + std::string to_number_string() const; }; - typedef enumerated amplitude_scaling_type_e_; + typedef enumerated bit_rate_query_prohibit_timer_e_; // member variables - supported_csi_rs_res_list_l_ supported_csi_rs_res_list; - uint8_t param_lx = 2; - amplitude_scaling_type_e_ amplitude_scaling_type; + bool ext = false; + bool allowed_serving_cells_present = false; + bool allowed_scs_list_present = false; + bool max_pusch_dur_present = false; + bool cfgured_grant_type1_allowed_present = false; + bool lc_ch_group_present = false; + bool sched_request_id_present = false; + uint8_t prio = 1; + prioritised_bit_rate_e_ prioritised_bit_rate; + bucket_size_dur_e_ bucket_size_dur; + allowed_serving_cells_l_ allowed_serving_cells; + allowed_scs_list_l_ allowed_scs_list; + max_pusch_dur_e_ max_pusch_dur; + uint8_t lc_ch_group = 0; + uint8_t sched_request_id = 0; + bool lc_ch_sr_mask = false; + bool lc_ch_sr_delay_timer_applied = false; + // ... + bool bit_rate_query_prohibit_timer_present = false; + bit_rate_query_prohibit_timer_e_ bit_rate_query_prohibit_timer; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; }; // member variables - bool type2_present = false; - bool type2_port_sel_present = false; - type1_s_ type1; - type2_s_ type2; - type2_port_sel_s_ type2_port_sel; + bool ext = false; + bool ul_specific_params_present = false; + ul_specific_params_s_ ul_specific_params; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20842,35 +21773,49 @@ struct codebook_params_s { void to_json(json_writer& j) const; }; -// DummyG ::= SEQUENCE -struct dummy_g_s { - struct max_num_ssb_csi_rs_res_one_tx_opts { - enum options { n8, n16, n32, n64, nulltype } value; - typedef uint8_t number_type; +// PHR-Config ::= SEQUENCE +struct phr_cfg_s { + struct phr_periodic_timer_opts { + enum options { sf10, sf20, sf50, sf100, sf200, sf500, sf1000, infinity, nulltype } value; + typedef int16_t number_type; std::string to_string() const; - uint8_t to_number() const; + int16_t to_number() const; }; - typedef enumerated max_num_ssb_csi_rs_res_one_tx_e_; - struct max_num_ssb_csi_rs_res_two_tx_opts { - enum options { n0, n4, n8, n16, n32, n64, nulltype } value; - typedef uint8_t number_type; + typedef enumerated phr_periodic_timer_e_; + struct phr_prohibit_timer_opts { + enum options { sf0, sf10, sf20, sf50, sf100, sf200, sf500, sf1000, nulltype } value; + typedef uint16_t number_type; std::string to_string() const; - uint8_t to_number() const; + uint16_t to_number() const; }; - typedef enumerated max_num_ssb_csi_rs_res_two_tx_e_; - struct supported_csi_rs_density_opts { - enum options { one, three, one_and_three, nulltype } value; + typedef enumerated phr_prohibit_timer_e_; + struct phr_tx_pwr_factor_change_opts { + enum options { db1, db3, db6, infinity, nulltype } value; + typedef int8_t number_type; std::string to_string() const; + int8_t to_number() const; }; - typedef enumerated supported_csi_rs_density_e_; + typedef enumerated phr_tx_pwr_factor_change_e_; + struct phr_mode_other_cg_opts { + enum options { real, virtual_value, nulltype } value; + + std::string to_string() const; + }; + typedef enumerated phr_mode_other_cg_e_; // member variables - max_num_ssb_csi_rs_res_one_tx_e_ max_num_ssb_csi_rs_res_one_tx; - max_num_ssb_csi_rs_res_two_tx_e_ max_num_ssb_csi_rs_res_two_tx; - supported_csi_rs_density_e_ supported_csi_rs_density; + bool ext = false; + phr_periodic_timer_e_ phr_periodic_timer; + phr_prohibit_timer_e_ phr_prohibit_timer; + phr_tx_pwr_factor_change_e_ phr_tx_pwr_factor_change; + bool multiple_phr = false; + bool dummy = false; + bool phr_type2_other_cell = false; + phr_mode_other_cg_e_ phr_mode_other_cg; + // ... // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20878,84 +21823,151 @@ struct dummy_g_s { void to_json(json_writer& j) const; }; -// DummyH ::= SEQUENCE -struct dummy_h_s { - uint8_t burst_len = 1; - uint8_t max_simul_res_sets_per_cc = 1; - uint8_t max_cfgured_res_sets_per_cc = 1; - uint8_t max_cfgured_res_sets_all_cc = 1; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; +// RLC-Config ::= CHOICE +struct rlc_cfg_c { + struct am_s_ { + ul_am_rlc_s ul_am_rlc; + dl_am_rlc_s dl_am_rlc; + }; + struct um_bi_dir_s_ { + ul_um_rlc_s ul_um_rlc; + dl_um_rlc_s dl_um_rlc; + }; + struct um_uni_dir_ul_s_ { + ul_um_rlc_s ul_um_rlc; + }; + struct um_uni_dir_dl_s_ { + dl_um_rlc_s dl_um_rlc; + }; + struct types_opts { + enum options { am, um_bi_dir, um_uni_dir_ul, um_uni_dir_dl, /*...*/ nulltype } value; -// PTRS-DensityRecommendationDL ::= SEQUENCE -struct ptrs_density_recommendation_dl_s { - uint16_t freq_density1 = 1; - uint16_t freq_density2 = 1; - uint8_t time_density1 = 0; - uint8_t time_density2 = 0; - uint8_t time_density3 = 0; + std::string to_string() const; + }; + typedef enumerated types; - // sequence methods + // choice methods + rlc_cfg_c() = default; + rlc_cfg_c(const rlc_cfg_c& other); + rlc_cfg_c& operator=(const rlc_cfg_c& other); + ~rlc_cfg_c() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; -}; + // getters + am_s_& am() + { + assert_choice_type("am", type_.to_string(), "RLC-Config"); + return c.get(); + } + um_bi_dir_s_& um_bi_dir() + { + assert_choice_type("um-Bi-Directional", type_.to_string(), "RLC-Config"); + return c.get(); + } + um_uni_dir_ul_s_& um_uni_dir_ul() + { + assert_choice_type("um-Uni-Directional-UL", type_.to_string(), "RLC-Config"); + return c.get(); + } + um_uni_dir_dl_s_& um_uni_dir_dl() + { + assert_choice_type("um-Uni-Directional-DL", type_.to_string(), "RLC-Config"); + return c.get(); + } + const am_s_& am() const + { + assert_choice_type("am", type_.to_string(), "RLC-Config"); + return c.get(); + } + const um_bi_dir_s_& um_bi_dir() const + { + assert_choice_type("um-Bi-Directional", type_.to_string(), "RLC-Config"); + return c.get(); + } + const um_uni_dir_ul_s_& um_uni_dir_ul() const + { + assert_choice_type("um-Uni-Directional-UL", type_.to_string(), "RLC-Config"); + return c.get(); + } + const um_uni_dir_dl_s_& um_uni_dir_dl() const + { + assert_choice_type("um-Uni-Directional-DL", type_.to_string(), "RLC-Config"); + return c.get(); + } + am_s_& set_am() + { + set(types::am); + return c.get(); + } + um_bi_dir_s_& set_um_bi_dir() + { + set(types::um_bi_dir); + return c.get(); + } + um_uni_dir_ul_s_& set_um_uni_dir_ul() + { + set(types::um_uni_dir_ul); + return c.get(); + } + um_uni_dir_dl_s_& set_um_uni_dir_dl() + { + set(types::um_uni_dir_dl); + return c.get(); + } -// PTRS-DensityRecommendationUL ::= SEQUENCE -struct ptrs_density_recommendation_ul_s { - uint16_t freq_density1 = 1; - uint16_t freq_density2 = 1; - uint8_t time_density1 = 0; - uint8_t time_density2 = 0; - uint8_t time_density3 = 0; - uint16_t sample_density1 = 1; - uint16_t sample_density2 = 1; - uint16_t sample_density3 = 1; - uint16_t sample_density4 = 1; - uint16_t sample_density5 = 1; +private: + types type_; + choice_buffer_t c; - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; + void destroy_(); }; -// SpatialRelations ::= SEQUENCE -struct spatial_relations_s { - struct max_num_cfgured_spatial_relations_opts { - enum options { n4, n8, n16, n32, n64, n96, nulltype } value; +// RLF-TimersAndConstants ::= SEQUENCE +struct rlf_timers_and_consts_s { + struct t310_opts { + enum options { ms0, ms50, ms100, ms200, ms500, ms1000, ms2000, ms4000, ms6000, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated t310_e_; + struct n310_opts { + enum options { n1, n2, n3, n4, n6, n8, n10, n20, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated max_num_cfgured_spatial_relations_e_; - struct max_num_active_spatial_relations_opts { - enum options { n1, n2, n4, n8, n14, nulltype } value; + typedef enumerated n310_e_; + struct n311_opts { + enum options { n1, n2, n3, n4, n5, n6, n8, n10, nulltype } value; typedef uint8_t number_type; std::string to_string() const; uint8_t to_number() const; }; - typedef enumerated max_num_active_spatial_relations_e_; - struct max_num_dl_rs_qcl_type_d_opts { - enum options { n1, n2, n4, n8, n14, nulltype } value; - typedef uint8_t number_type; + typedef enumerated n311_e_; + struct t311_opts { + enum options { ms1000, ms3000, ms5000, ms10000, ms15000, ms20000, ms30000, nulltype } value; + typedef uint16_t number_type; std::string to_string() const; - uint8_t to_number() const; + uint16_t to_number() const; }; - typedef enumerated max_num_dl_rs_qcl_type_d_e_; + typedef enumerated t311_e_; // member variables - bool add_active_spatial_relation_pucch_present = false; - max_num_cfgured_spatial_relations_e_ max_num_cfgured_spatial_relations; - max_num_active_spatial_relations_e_ max_num_active_spatial_relations; - max_num_dl_rs_qcl_type_d_e_ max_num_dl_rs_qcl_type_d; + bool ext = false; + t310_e_ t310; + n310_e_ n310; + n311_e_ n311; + // ... + // group 0 + t311_e_ t311; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -20963,260 +21975,326 @@ struct spatial_relations_s { void to_json(json_writer& j) const; }; -// MIMO-ParametersPerBand ::= SEQUENCE -struct mimo_params_per_band_s { - struct tci_state_pdsch_s_ { - struct max_num_cfgured_tcistates_per_cc_opts { - enum options { n4, n8, n16, n32, n64, n128, nulltype } value; - typedef uint8_t number_type; +// ReconfigurationWithSync ::= SEQUENCE +struct recfg_with_sync_s { + struct t304_opts { + enum options { ms50, ms100, ms150, ms200, ms500, ms1000, ms2000, ms10000, nulltype } value; + typedef uint16_t number_type; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_num_cfgured_tcistates_per_cc_e_; - struct max_num_active_tci_per_bwp_opts { - enum options { n1, n2, n4, n8, nulltype } value; - typedef uint8_t number_type; + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated t304_e_; + struct rach_cfg_ded_c_ { + struct types_opts { + enum options { ul, supplementary_ul, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; - typedef enumerated max_num_active_tci_per_bwp_e_; + typedef enumerated types; - // member variables - bool max_num_cfgured_tcistates_per_cc_present = false; - bool max_num_active_tci_per_bwp_present = false; - max_num_cfgured_tcistates_per_cc_e_ max_num_cfgured_tcistates_per_cc; - max_num_active_tci_per_bwp_e_ max_num_active_tci_per_bwp; - }; - struct pusch_trans_coherence_opts { - enum options { non_coherent, partial_coherent, full_coherent, nulltype } value; + // choice methods + rach_cfg_ded_c_() = default; + rach_cfg_ded_c_(const rach_cfg_ded_c_& other); + rach_cfg_ded_c_& operator=(const rach_cfg_ded_c_& other); + ~rach_cfg_ded_c_() { destroy_(); } + void set(types::options e = types::nulltype); + types type() const { return type_; } + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; + // getters + rach_cfg_ded_s& ul() + { + assert_choice_type("uplink", type_.to_string(), "rach-ConfigDedicated"); + return c.get(); + } + rach_cfg_ded_s& supplementary_ul() + { + assert_choice_type("supplementaryUplink", type_.to_string(), "rach-ConfigDedicated"); + return c.get(); + } + const rach_cfg_ded_s& ul() const + { + assert_choice_type("uplink", type_.to_string(), "rach-ConfigDedicated"); + return c.get(); + } + const rach_cfg_ded_s& supplementary_ul() const + { + assert_choice_type("supplementaryUplink", type_.to_string(), "rach-ConfigDedicated"); + return c.get(); + } + rach_cfg_ded_s& set_ul() + { + set(types::ul); + return c.get(); + } + rach_cfg_ded_s& set_supplementary_ul() + { + set(types::supplementary_ul); + return c.get(); + } - std::string to_string() const; + private: + types type_; + choice_buffer_t c; + + void destroy_(); }; - typedef enumerated pusch_trans_coherence_e_; - struct max_num_rx_tx_beam_switch_dl_s_ { - struct scs_minus15k_hz_opts { - enum options { n4, n7, n14, nulltype } value; - typedef uint8_t number_type; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus15k_hz_e_; - struct scs_minus30k_hz_opts { - enum options { n4, n7, n14, nulltype } value; - typedef uint8_t number_type; + // member variables + bool ext = false; + bool sp_cell_cfg_common_present = false; + bool rach_cfg_ded_present = false; + serving_cell_cfg_common_s sp_cell_cfg_common; + uint32_t new_ue_id = 0; + t304_e_ t304; + rach_cfg_ded_c_ rach_cfg_ded; + // ... + // group 0 + copy_ptr smtc; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus30k_hz_e_; - struct scs_minus60k_hz_opts { - enum options { n4, n7, n14, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus60k_hz_e_; - struct scs_minus120k_hz_opts { - enum options { n4, n7, n14, nulltype } value; - typedef uint8_t number_type; +// SchedulingRequestConfig ::= SEQUENCE +struct sched_request_cfg_s { + using sched_request_to_add_mod_list_l_ = dyn_array; + using sched_request_to_release_list_l_ = bounded_array; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus120k_hz_e_; - struct scs_minus240k_hz_opts { - enum options { n4, n7, n14, nulltype } value; - typedef uint8_t number_type; + // member variables + bool sched_request_to_add_mod_list_present = false; + bool sched_request_to_release_list_present = false; + sched_request_to_add_mod_list_l_ sched_request_to_add_mod_list; + sched_request_to_release_list_l_ sched_request_to_release_list; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus240k_hz_e_; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - // member variables - bool scs_minus15k_hz_present = false; - bool scs_minus30k_hz_present = false; - bool scs_minus60k_hz_present = false; - bool scs_minus120k_hz_present = false; - bool scs_minus240k_hz_present = false; - scs_minus15k_hz_e_ scs_minus15k_hz; - scs_minus30k_hz_e_ scs_minus30k_hz; - scs_minus60k_hz_e_ scs_minus60k_hz; - scs_minus120k_hz_e_ scs_minus120k_hz; - scs_minus240k_hz_e_ scs_minus240k_hz; +// ServingCellConfig ::= SEQUENCE +struct serving_cell_cfg_s { + using dl_bwp_to_release_list_l_ = bounded_array; + using dl_bwp_to_add_mod_list_l_ = dyn_array; + struct bwp_inactivity_timer_opts { + enum options { + ms2, + ms3, + ms4, + ms5, + ms6, + ms8, + ms10, + ms20, + ms30, + ms40, + ms50, + ms60, + ms80, + ms100, + ms200, + ms300, + ms500, + ms750, + ms1280, + ms1920, + ms2560, + spare10, + spare9, + spare8, + spare7, + spare6, + spare5, + spare4, + spare3, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated bwp_inactivity_timer_e_; + struct scell_deactivation_timer_opts { + enum options { + ms20, + ms40, + ms80, + ms160, + ms200, + ms240, + ms320, + ms400, + ms480, + ms520, + ms640, + ms720, + ms840, + ms1280, + spare2, + spare1, + nulltype + } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; }; - struct max_num_non_group_beam_report_opts { - enum options { n1, n2, n4, nulltype } value; - typedef uint8_t number_type; + typedef enumerated scell_deactivation_timer_e_; + struct pathloss_ref_linking_opts { + enum options { sp_cell, scell, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; - typedef enumerated max_num_non_group_beam_report_e_; - struct ul_beam_management_s_ { - struct max_num_srs_res_per_set_bm_opts { - enum options { n2, n4, n8, n16, nulltype } value; - typedef uint8_t number_type; + typedef enumerated pathloss_ref_linking_e_; + using rate_match_pattern_to_add_mod_list_l_ = dyn_array; + using rate_match_pattern_to_release_list_l_ = bounded_array; + using dl_ch_bw_per_scs_list_l_ = dyn_array; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_num_srs_res_per_set_bm_e_; + // member variables + bool ext = false; + bool tdd_ul_dl_cfg_ded_present = false; + bool init_dl_bwp_present = false; + bool dl_bwp_to_release_list_present = false; + bool dl_bwp_to_add_mod_list_present = false; + bool first_active_dl_bwp_id_present = false; + bool bwp_inactivity_timer_present = false; + bool default_dl_bwp_id_present = false; + bool ul_cfg_present = false; + bool supplementary_ul_present = false; + bool pdcch_serving_cell_cfg_present = false; + bool pdsch_serving_cell_cfg_present = false; + bool csi_meas_cfg_present = false; + bool scell_deactivation_timer_present = false; + bool cross_carrier_sched_cfg_present = false; + bool dummy_present = false; + bool pathloss_ref_linking_present = false; + bool serving_cell_mo_present = false; + tdd_ul_dl_cfg_ded_s tdd_ul_dl_cfg_ded; + bwp_dl_ded_s init_dl_bwp; + dl_bwp_to_release_list_l_ dl_bwp_to_release_list; + dl_bwp_to_add_mod_list_l_ dl_bwp_to_add_mod_list; + uint8_t first_active_dl_bwp_id = 0; + bwp_inactivity_timer_e_ bwp_inactivity_timer; + uint8_t default_dl_bwp_id = 0; + ul_cfg_s ul_cfg; + ul_cfg_s supplementary_ul; + setup_release_c pdcch_serving_cell_cfg; + setup_release_c pdsch_serving_cell_cfg; + setup_release_c csi_meas_cfg; + scell_deactivation_timer_e_ scell_deactivation_timer; + cross_carrier_sched_cfg_s cross_carrier_sched_cfg; + uint8_t tag_id = 0; + pathloss_ref_linking_e_ pathloss_ref_linking; + uint8_t serving_cell_mo = 1; + // ... + // group 0 + copy_ptr > lte_crs_to_match_around; + copy_ptr rate_match_pattern_to_add_mod_list; + copy_ptr rate_match_pattern_to_release_list; + copy_ptr dl_ch_bw_per_scs_list; - // member variables - max_num_srs_res_per_set_bm_e_ max_num_srs_res_per_set_bm; - uint8_t max_num_srs_res_set = 1; - }; - struct beam_report_timing_s_ { - struct scs_minus15k_hz_opts { - enum options { sym2, sym4, sym8, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus15k_hz_e_; - struct scs_minus30k_hz_opts { - enum options { sym4, sym8, sym14, sym28, nulltype } value; - typedef uint8_t number_type; +// TAG-Config ::= SEQUENCE +struct tag_cfg_s { + using tag_to_release_list_l_ = bounded_array; + using tag_to_add_mod_list_l_ = dyn_array; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus30k_hz_e_; - struct scs_minus60k_hz_opts { - enum options { sym8, sym14, sym28, nulltype } value; - typedef uint8_t number_type; + // member variables + bool tag_to_release_list_present = false; + bool tag_to_add_mod_list_present = false; + tag_to_release_list_l_ tag_to_release_list; + tag_to_add_mod_list_l_ tag_to_add_mod_list; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus60k_hz_e_; - struct scs_minus120k_hz_opts { - enum options { sym14, sym28, sym56, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated scs_minus120k_hz_e_; +// MAC-CellGroupConfig ::= SEQUENCE +struct mac_cell_group_cfg_s { + bool ext = false; + bool drx_cfg_present = false; + bool sched_request_cfg_present = false; + bool bsr_cfg_present = false; + bool tag_cfg_present = false; + bool phr_cfg_present = false; + setup_release_c drx_cfg; + sched_request_cfg_s sched_request_cfg; + bsr_cfg_s bsr_cfg; + tag_cfg_s tag_cfg; + setup_release_c phr_cfg; + bool skip_ul_tx_dynamic = false; + // ... + // group 0 + bool csi_mask_present = false; + bool csi_mask = false; + copy_ptr > data_inactivity_timer; - // member variables - bool scs_minus15k_hz_present = false; - bool scs_minus30k_hz_present = false; - bool scs_minus60k_hz_present = false; - bool scs_minus120k_hz_present = false; - scs_minus15k_hz_e_ scs_minus15k_hz; - scs_minus30k_hz_e_ scs_minus30k_hz; - scs_minus60k_hz_e_ scs_minus60k_hz; - scs_minus120k_hz_e_ scs_minus120k_hz; - }; - struct ptrs_density_recommendation_set_dl_s_ { - bool scs_minus15k_hz_present = false; - bool scs_minus30k_hz_present = false; - bool scs_minus60k_hz_present = false; - bool scs_minus120k_hz_present = false; - ptrs_density_recommendation_dl_s scs_minus15k_hz; - ptrs_density_recommendation_dl_s scs_minus30k_hz; - ptrs_density_recommendation_dl_s scs_minus60k_hz; - ptrs_density_recommendation_dl_s scs_minus120k_hz; - }; - struct ptrs_density_recommendation_set_ul_s_ { - bool scs_minus15k_hz_present = false; - bool scs_minus30k_hz_present = false; - bool scs_minus60k_hz_present = false; - bool scs_minus120k_hz_present = false; - ptrs_density_recommendation_ul_s scs_minus15k_hz; - ptrs_density_recommendation_ul_s scs_minus30k_hz; - ptrs_density_recommendation_ul_s scs_minus60k_hz; - ptrs_density_recommendation_ul_s scs_minus120k_hz; - }; - struct beam_switch_timing_s_ { - struct scs_minus60k_hz_opts { - enum options { sym14, sym28, sym48, sym224, sym336, nulltype } value; - typedef uint16_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated scs_minus60k_hz_e_; - struct scs_minus120k_hz_opts { - enum options { sym14, sym28, sym48, sym224, sym336, nulltype } value; - typedef uint16_t number_type; +// PhysicalCellGroupConfig ::= SEQUENCE +struct phys_cell_group_cfg_s { + struct pdsch_harq_ack_codebook_opts { + enum options { semi_static, dynamic_value, nulltype } value; - std::string to_string() const; - uint16_t to_number() const; - }; - typedef enumerated scs_minus120k_hz_e_; + std::string to_string() const; + }; + typedef enumerated pdsch_harq_ack_codebook_e_; + struct xscale_opts { + enum options { db0, db6, spare2, spare1, nulltype } value; + typedef uint8_t number_type; - // member variables - bool scs_minus60k_hz_present = false; - bool scs_minus120k_hz_present = false; - scs_minus60k_hz_e_ scs_minus60k_hz; - scs_minus120k_hz_e_ scs_minus120k_hz; + std::string to_string() const; + uint8_t to_number() const; }; - using srs_assoc_csi_rs_l_ = dyn_array; + typedef enumerated xscale_e_; // member variables - bool ext = false; - bool tci_state_pdsch_present = false; - bool add_active_tci_state_pdcch_present = false; - bool pusch_trans_coherence_present = false; - bool beam_correspondence_without_ul_beam_sweeping_present = false; - bool periodic_beam_report_present = false; - bool aperiodic_beam_report_present = false; - bool sp_beam_report_pucch_present = false; - bool sp_beam_report_pusch_present = false; - bool dummy1_present = false; - bool max_num_rx_beam_present = false; - bool max_num_rx_tx_beam_switch_dl_present = false; - bool max_num_non_group_beam_report_present = false; - bool group_beam_report_present = false; - bool ul_beam_management_present = false; - bool max_num_csi_rs_bfd_present = false; - bool max_num_ssb_bfd_present = false; - bool max_num_csi_rs_ssb_cbd_present = false; - bool dummy2_present = false; - bool two_ports_ptrs_ul_present = false; - bool dummy5_present = false; - bool dummy3_present = false; - bool beam_report_timing_present = false; - bool ptrs_density_recommendation_set_dl_present = false; - bool ptrs_density_recommendation_set_ul_present = false; - bool dummy4_present = false; - bool aperiodic_trs_present = false; - tci_state_pdsch_s_ tci_state_pdsch; - pusch_trans_coherence_e_ pusch_trans_coherence; - dummy_g_s dummy1; - uint8_t max_num_rx_beam = 2; - max_num_rx_tx_beam_switch_dl_s_ max_num_rx_tx_beam_switch_dl; - max_num_non_group_beam_report_e_ max_num_non_group_beam_report; - ul_beam_management_s_ ul_beam_management; - uint8_t max_num_csi_rs_bfd = 1; - uint8_t max_num_ssb_bfd = 1; - uint16_t max_num_csi_rs_ssb_cbd = 1; - srs_res_s dummy5; - uint8_t dummy3 = 1; - beam_report_timing_s_ beam_report_timing; - ptrs_density_recommendation_set_dl_s_ ptrs_density_recommendation_set_dl; - ptrs_density_recommendation_set_ul_s_ ptrs_density_recommendation_set_ul; - dummy_h_s dummy4; + bool ext = false; + bool harq_ack_spatial_bundling_pucch_present = false; + bool harq_ack_spatial_bundling_pusch_present = false; + bool p_nr_fr1_present = false; + bool tpc_srs_rnti_present = false; + bool tpc_pucch_rnti_present = false; + bool tpc_pusch_rnti_present = false; + bool sp_csi_rnti_present = false; + bool cs_rnti_present = false; + int8_t p_nr_fr1 = -30; + pdsch_harq_ack_codebook_e_ pdsch_harq_ack_codebook; + uint32_t tpc_srs_rnti = 0; + uint32_t tpc_pucch_rnti = 0; + uint32_t tpc_pusch_rnti = 0; + uint32_t sp_csi_rnti = 0; + setup_release_c > cs_rnti; // ... // group 0 - bool beam_correspondence_ca_present = false; - copy_ptr beam_management_ssb_csi_rs; - copy_ptr beam_switch_timing; - copy_ptr codebook_params; - copy_ptr csi_rs_im_reception_for_feedback; - copy_ptr csi_rs_proc_framework_for_srs; - copy_ptr csi_report_framework; - copy_ptr csi_rs_for_tracking; - copy_ptr srs_assoc_csi_rs; - copy_ptr spatial_relations; + bool mcs_c_rnti_present = false; + bool p_ue_fr1_present = false; + uint32_t mcs_c_rnti = 0; + int8_t p_ue_fr1 = -30; + // group 1 + bool xscale_present = false; + xscale_e_ xscale; + // group 2 + copy_ptr > > pdcch_blind_detection; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -21224,207 +22302,148 @@ struct mimo_params_per_band_s { void to_json(json_writer& j) const; }; -// BandNR ::= SEQUENCE -struct band_nr_s { - struct bwp_same_numerology_opts { - enum options { upto2, upto4, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated bwp_same_numerology_e_; - struct ue_pwr_class_opts { - enum options { pc1, pc2, pc3, pc4, nulltype } value; - typedef uint8_t number_type; - - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated ue_pwr_class_e_; - struct ch_bws_dl_v1530_c_ { - struct fr1_s_ { - bool scs_minus15k_hz_present = false; - bool scs_minus30k_hz_present = false; - bool scs_minus60k_hz_present = false; - fixed_bitstring<10> scs_minus15k_hz; - fixed_bitstring<10> scs_minus30k_hz; - fixed_bitstring<10> scs_minus60k_hz; - }; - struct fr2_s_ { - bool scs_minus60k_hz_present = false; - bool scs_minus120k_hz_present = false; - fixed_bitstring<3> scs_minus60k_hz; - fixed_bitstring<3> scs_minus120k_hz; - }; +// RLC-BearerConfig ::= SEQUENCE +struct rlc_bearer_cfg_s { + struct served_radio_bearer_c_ { struct types_opts { - enum options { fr1, fr2, nulltype } value; - typedef uint8_t number_type; + enum options { srb_id, drb_id, nulltype } value; std::string to_string() const; - uint8_t to_number() const; }; typedef enumerated types; // choice methods - ch_bws_dl_v1530_c_() = default; - ch_bws_dl_v1530_c_(const ch_bws_dl_v1530_c_& other); - ch_bws_dl_v1530_c_& operator=(const ch_bws_dl_v1530_c_& other); - ~ch_bws_dl_v1530_c_() { destroy_(); } + served_radio_bearer_c_() = default; + served_radio_bearer_c_(const served_radio_bearer_c_& other); + served_radio_bearer_c_& operator=(const served_radio_bearer_c_& other); + ~served_radio_bearer_c_() { destroy_(); } void set(types::options e = types::nulltype); types type() const { return type_; } SRSASN_CODE pack(bit_ref& bref) const; SRSASN_CODE unpack(cbit_ref& bref); void to_json(json_writer& j) const; // getters - fr1_s_& fr1() + uint8_t& srb_id() { - assert_choice_type("fr1", type_.to_string(), "channelBWs-DL-v1530"); - return c.get(); + assert_choice_type("srb-Identity", type_.to_string(), "servedRadioBearer"); + return c.get(); } - fr2_s_& fr2() + uint8_t& drb_id() { - assert_choice_type("fr2", type_.to_string(), "channelBWs-DL-v1530"); - return c.get(); + assert_choice_type("drb-Identity", type_.to_string(), "servedRadioBearer"); + return c.get(); } - const fr1_s_& fr1() const + const uint8_t& srb_id() const { - assert_choice_type("fr1", type_.to_string(), "channelBWs-DL-v1530"); - return c.get(); + assert_choice_type("srb-Identity", type_.to_string(), "servedRadioBearer"); + return c.get(); } - const fr2_s_& fr2() const + const uint8_t& drb_id() const { - assert_choice_type("fr2", type_.to_string(), "channelBWs-DL-v1530"); - return c.get(); + assert_choice_type("drb-Identity", type_.to_string(), "servedRadioBearer"); + return c.get(); } - fr1_s_& set_fr1() + uint8_t& set_srb_id() { - set(types::fr1); - return c.get(); + set(types::srb_id); + return c.get(); } - fr2_s_& set_fr2() + uint8_t& set_drb_id() { - set(types::fr2); - return c.get(); + set(types::drb_id); + return c.get(); } private: - types type_; - choice_buffer_t c; + types type_; + pod_choice_buffer_t c; void destroy_(); }; - struct ch_bws_ul_v1530_c_ { - struct fr1_s_ { - bool scs_minus15k_hz_present = false; - bool scs_minus30k_hz_present = false; - bool scs_minus60k_hz_present = false; - fixed_bitstring<10> scs_minus15k_hz; - fixed_bitstring<10> scs_minus30k_hz; - fixed_bitstring<10> scs_minus60k_hz; - }; - struct fr2_s_ { - bool scs_minus60k_hz_present = false; - bool scs_minus120k_hz_present = false; - fixed_bitstring<3> scs_minus60k_hz; - fixed_bitstring<3> scs_minus120k_hz; - }; - struct types_opts { - enum options { fr1, fr2, nulltype } value; - typedef uint8_t number_type; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated types; + // member variables + bool ext = false; + bool served_radio_bearer_present = false; + bool reestablish_rlc_present = false; + bool rlc_cfg_present = false; + bool mac_lc_ch_cfg_present = false; + uint8_t lc_ch_id = 1; + served_radio_bearer_c_ served_radio_bearer; + rlc_cfg_c rlc_cfg; + lc_ch_cfg_s mac_lc_ch_cfg; + // ... - // choice methods - ch_bws_ul_v1530_c_() = default; - ch_bws_ul_v1530_c_(const ch_bws_ul_v1530_c_& other); - ch_bws_ul_v1530_c_& operator=(const ch_bws_ul_v1530_c_& other); - ~ch_bws_ul_v1530_c_() { destroy_(); } - void set(types::options e = types::nulltype); - types type() const { return type_; } - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; - // getters - fr1_s_& fr1() - { - assert_choice_type("fr1", type_.to_string(), "channelBWs-UL-v1530"); - return c.get(); - } - fr2_s_& fr2() - { - assert_choice_type("fr2", type_.to_string(), "channelBWs-UL-v1530"); - return c.get(); - } - const fr1_s_& fr1() const - { - assert_choice_type("fr1", type_.to_string(), "channelBWs-UL-v1530"); - return c.get(); - } - const fr2_s_& fr2() const - { - assert_choice_type("fr2", type_.to_string(), "channelBWs-UL-v1530"); - return c.get(); - } - fr1_s_& set_fr1() - { - set(types::fr1); - return c.get(); - } - fr2_s_& set_fr2() - { - set(types::fr2); - return c.get(); - } + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - private: - types type_; - choice_buffer_t c; +// SCellConfig ::= SEQUENCE +struct scell_cfg_s { + bool ext = false; + bool scell_cfg_common_present = false; + bool scell_cfg_ded_present = false; + uint8_t scell_idx = 1; + serving_cell_cfg_common_s scell_cfg_common; + serving_cell_cfg_s scell_cfg_ded; + // ... + // group 0 + copy_ptr smtc; - void destroy_(); - }; - struct max_ul_duty_cycle_pc2_fr1_opts { - enum options { n60, n70, n80, n90, n100, nulltype } value; - typedef uint8_t number_type; + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; - std::string to_string() const; - uint8_t to_number() const; - }; - typedef enumerated max_ul_duty_cycle_pc2_fr1_e_; +// SpCellConfig ::= SEQUENCE +struct sp_cell_cfg_s { + bool ext = false; + bool serv_cell_idx_present = false; + bool recfg_with_sync_present = false; + bool rlf_timers_and_consts_present = false; + bool rlm_in_sync_out_of_sync_thres_present = false; + bool sp_cell_cfg_ded_present = false; + uint8_t serv_cell_idx = 0; + recfg_with_sync_s recfg_with_sync; + setup_release_c rlf_timers_and_consts; + serving_cell_cfg_s sp_cell_cfg_ded; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CellGroupConfig ::= SEQUENCE +struct cell_group_cfg_s { + using rlc_bearer_to_add_mod_list_l_ = dyn_array; + using rlc_bearer_to_release_list_l_ = bounded_array; + using scell_to_add_mod_list_l_ = dyn_array; + using scell_to_release_list_l_ = bounded_array; // member variables - bool ext = false; - bool modified_mpr_behaviour_present = false; - bool mimo_params_per_band_present = false; - bool extended_cp_present = false; - bool multiple_tci_present = false; - bool bwp_without_restrict_present = false; - bool bwp_same_numerology_present = false; - bool bwp_diff_numerology_present = false; - bool cross_carrier_sched_same_scs_present = false; - bool pdsch_minus256_qam_fr2_present = false; - bool pusch_minus256_qam_present = false; - bool ue_pwr_class_present = false; - bool rate_matching_lte_crs_present = false; - bool ch_bws_dl_v1530_present = false; - bool ch_bws_ul_v1530_present = false; - uint16_t band_nr = 1; - fixed_bitstring<8> modified_mpr_behaviour; - mimo_params_per_band_s mimo_params_per_band; - bwp_same_numerology_e_ bwp_same_numerology; - ue_pwr_class_e_ ue_pwr_class; - ch_bws_dl_v1530_c_ ch_bws_dl_v1530; - ch_bws_ul_v1530_c_ ch_bws_ul_v1530; + bool ext = false; + bool rlc_bearer_to_add_mod_list_present = false; + bool rlc_bearer_to_release_list_present = false; + bool mac_cell_group_cfg_present = false; + bool phys_cell_group_cfg_present = false; + bool sp_cell_cfg_present = false; + bool scell_to_add_mod_list_present = false; + bool scell_to_release_list_present = false; + uint8_t cell_group_id = 0; + rlc_bearer_to_add_mod_list_l_ rlc_bearer_to_add_mod_list; + rlc_bearer_to_release_list_l_ rlc_bearer_to_release_list; + mac_cell_group_cfg_s mac_cell_group_cfg; + phys_cell_group_cfg_s phys_cell_group_cfg; + sp_cell_cfg_s sp_cell_cfg; + scell_to_add_mod_list_l_ scell_to_add_mod_list; + scell_to_release_list_l_ scell_to_release_list; // ... // group 0 - bool max_ul_duty_cycle_pc2_fr1_present = false; - max_ul_duty_cycle_pc2_fr1_e_ max_ul_duty_cycle_pc2_fr1; - // group 1 - bool pucch_spatial_rel_info_mac_ce_present = false; - bool pwr_boosting_pi2_bpsk_present = false; + bool report_ul_tx_direct_current_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -21441,6 +22460,8 @@ struct eutra_params_common_s { bool rs_sinr_meas_eutra_present = false; fixed_bitstring<32> modified_mpr_behavior_eutra; // ... + // group 0 + bool ne_dc_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -22095,6 +23116,17 @@ struct feature_set_dl_v1540_s { void to_json(json_writer& j) const; }; +// FeatureSetDownlink-v15a0 ::= SEQUENCE +struct feature_set_dl_v15a0_s { + bool supported_srs_res_present = false; + srs_res_s supported_srs_res; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // ModulationOrder ::= ENUMERATED struct mod_order_opts { enum options { bpsk_halfpi, bpsk, qpsk, qam16, qam64, qam256, nulltype } value; @@ -22386,6 +23418,7 @@ struct feature_sets_s { using feature_sets_dl_v1540_l_ = dyn_array; using feature_sets_ul_v1540_l_ = dyn_array; using feature_sets_ul_per_cc_v1540_l_ = dyn_array; + using feature_sets_dl_v15a0_l_ = dyn_array; // member variables bool ext = false; @@ -22402,6 +23435,8 @@ struct feature_sets_s { copy_ptr feature_sets_dl_v1540; copy_ptr feature_sets_ul_v1540; copy_ptr feature_sets_ul_per_cc_v1540; + // group 1 + copy_ptr feature_sets_dl_v15a0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -22535,6 +23570,8 @@ struct ims_params_common_s { bool ext = false; bool voice_over_eutra_minus5_gc_present = false; // ... + // group 0 + bool voice_over_scg_bearer_eutra_minus5_gc_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -22660,6 +23697,11 @@ struct meas_and_mob_params_common_s { max_num_csi_rs_rrm_rs_sinr_e_ max_num_csi_rs_rrm_rs_sinr; // group 2 bool nr_cgi_report_endc_present = false; + // group 3 + bool eutra_cgi_report_nedc_present = false; + bool eutra_cgi_report_nrdc_present = false; + bool nr_cgi_report_nedc_present = false; + bool nr_cgi_report_nrdc_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -22687,9 +23729,9 @@ struct meas_and_mob_params_frx_diff_s { bool csi_rs_rlm_present = false; // ... // group 0 - bool ho_inter_f_present = false; - bool ho_lte_present = false; - bool ho_e_lte_present = false; + bool ho_inter_f_present = false; + bool ho_lte_epc_present = false; + bool ho_lte_minus5_gc_present = false; // group 1 bool max_num_res_csi_rs_rlm_present = false; max_num_res_csi_rs_rlm_e_ max_num_res_csi_rs_rlm; @@ -22709,9 +23751,12 @@ struct meas_and_mob_params_xdd_diff_s { bool event_a_meas_and_report_present = false; // ... // group 0 - bool ho_inter_f_present = false; - bool ho_lte_present = false; - bool ho_e_lte_present = false; + bool ho_inter_f_present = false; + bool ho_lte_epc_present = false; + bool ho_lte_minus5_gc_present = false; + // group 1 + bool sftd_meas_nr_neigh_present = false; + bool sftd_meas_nr_neigh_drx_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -22780,18 +23825,9 @@ struct meas_and_mob_params_mrdc_s { void to_json(json_writer& j) const; }; -// MeasResult2NR ::= SEQUENCE -struct meas_result2_nr_s { - bool ext = false; - bool ssb_freq_present = false; - bool ref_freq_csi_rs_present = false; - bool meas_result_serving_cell_present = false; - bool meas_result_neigh_cell_list_nr_present = false; - uint32_t ssb_freq = 0; - uint32_t ref_freq_csi_rs = 0; - meas_result_nr_s meas_result_serving_cell; - meas_result_list_nr_l meas_result_neigh_cell_list_nr; - // ... +// MeasAndMobParametersMRDC-XDD-Diff-v1560 ::= SEQUENCE +struct meas_and_mob_params_mrdc_xdd_diff_v1560_s { + bool sftd_meas_ps_cell_nedc_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -22799,13 +23835,10 @@ struct meas_result2_nr_s { void to_json(json_writer& j) const; }; -// MeasResultCellSFTD ::= SEQUENCE -struct meas_result_cell_sftd_s { - bool rsrp_result_present = false; - uint16_t pci = 0; - uint16_t sfn_offset_result = 0; - int16_t frame_boundary_offset_result = -30720; - uint8_t rsrp_result = 0; +// MeasAndMobParametersMRDC-v1560 ::= SEQUENCE +struct meas_and_mob_params_mrdc_v1560_s { + bool meas_and_mob_params_mrdc_xdd_diff_v1560_present = false; + meas_and_mob_params_mrdc_xdd_diff_v1560_s meas_and_mob_params_mrdc_xdd_diff_v1560; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -22813,8 +23846,8 @@ struct meas_result_cell_sftd_s { void to_json(json_writer& j) const; }; -// MeasResultCellListSFTD ::= SEQUENCE (SIZE (1..3)) OF MeasResultCellSFTD -using meas_result_cell_list_sftd_l = dyn_array; +// MeasResultCellListSFTD-EUTRA ::= SEQUENCE (SIZE (1..3)) OF MeasResultSFTD-EUTRA +using meas_result_cell_list_sftd_eutra_l = dyn_array; // MeasResultList2NR ::= SEQUENCE (SIZE (1..8)) OF MeasResult2NR using meas_result_list2_nr_l = dyn_array; @@ -22831,6 +23864,86 @@ struct meas_result_scg_fail_s { void to_json(json_writer& j) const; }; +// GeneralParametersMRDC-XDD-Diff ::= SEQUENCE +struct general_params_mrdc_xdd_diff_s { + bool ext = false; + bool split_srb_with_one_ul_path_present = false; + bool split_drb_with_ul_both_mcg_scg_present = false; + bool srb3_present = false; + bool v2x_eutra_present = false; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UE-MRDC-CapabilityAddFRX-Mode ::= SEQUENCE +struct ue_mrdc_cap_add_frx_mode_s { + meas_and_mob_params_mrdc_frx_diff_s meas_and_mob_params_mrdc_frx_diff; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UE-MRDC-CapabilityAddXDD-Mode ::= SEQUENCE +struct ue_mrdc_cap_add_xdd_mode_s { + bool meas_and_mob_params_mrdc_xdd_diff_present = false; + bool general_params_mrdc_xdd_diff_present = false; + meas_and_mob_params_mrdc_xdd_diff_s meas_and_mob_params_mrdc_xdd_diff; + general_params_mrdc_xdd_diff_s general_params_mrdc_xdd_diff; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// NRDC-Parameters ::= SEQUENCE +struct nrdc_params_s { + bool meas_and_mob_params_nrdc_present = false; + bool general_params_nrdc_present = false; + bool fdd_add_ue_nrdc_cap_present = false; + bool tdd_add_ue_nrdc_cap_present = false; + bool fr1_add_ue_nrdc_cap_present = false; + bool fr2_add_ue_nrdc_cap_present = false; + bool late_non_crit_ext_present = false; + bool dummy_present = false; + meas_and_mob_params_mrdc_s meas_and_mob_params_nrdc; + general_params_mrdc_xdd_diff_s general_params_nrdc; + ue_mrdc_cap_add_xdd_mode_s fdd_add_ue_nrdc_cap; + ue_mrdc_cap_add_xdd_mode_s tdd_add_ue_nrdc_cap; + ue_mrdc_cap_add_frx_mode_s fr1_add_ue_nrdc_cap; + ue_mrdc_cap_add_frx_mode_s fr2_add_ue_nrdc_cap; + dyn_octstring late_non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CarrierAggregationVariant ::= SEQUENCE +struct carrier_aggregation_variant_s { + bool fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_fdd_present = false; + bool fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_tdd_present = false; + bool fr1fdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present = false; + bool fr1fdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present = false; + bool fr1tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present = false; + bool fr1tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present = false; + bool fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present = false; + bool fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present = false; + bool fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present = false; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // Phy-ParametersCommon ::= SEQUENCE struct phy_params_common_s { struct bwp_switching_delay_opts { @@ -22886,6 +23999,8 @@ struct phy_params_common_s { bool max_num_search_spaces_present = false; bool rate_matching_ctrl_resrc_set_dynamic_present = false; bool max_layers_mimo_ind_present = false; + // group 2 + copy_ptr sp_cell_placement; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23020,6 +24135,10 @@ struct phy_params_frx_diff_s { bool same_symbol_present = false; bool diff_symbol_present = false; }; + struct pdcch_blind_detection_nrdc_s_ { + uint8_t pdcch_blind_detection_mcg_ue = 1; + uint8_t pdcch_blind_detection_scg_ue = 1; + }; // member variables bool ext = false; @@ -23038,8 +24157,8 @@ struct phy_params_frx_diff_s { bool pucch_f2_with_fh_present = false; bool pucch_f3_with_fh_present = false; bool pucch_f4_with_fh_present = false; - bool freq_hop_pucch_f0_minus2_present = false; - bool freq_hop_pucch_f1_minus3_minus4_present = false; + bool pucch_f0_minus2_without_fh_present = false; + bool pucch_f1_minus3_minus4_without_fh_present = false; bool mux_sr_harq_ack_csi_pucch_multi_per_slot_present = false; bool uci_code_block_segmentation_present = false; bool one_pucch_long_and_short_format_present = false; @@ -23085,6 +24204,9 @@ struct phy_params_frx_diff_s { copy_ptr csi_rs_proc_framework_for_srs; copy_ptr csi_report_framework; copy_ptr mux_sr_harq_ack_csi_pucch_once_per_slot; + // group 1 + bool mux_harq_ack_pusch_diff_symbol_present = false; + copy_ptr pdcch_blind_detection_nrdc; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23180,6 +24302,8 @@ struct phy_params_mrdc_s { bool naics_cap_list_present = false; naics_cap_list_l_ naics_cap_list; // ... + // group 0 + copy_ptr sp_cell_placement; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23204,6 +24328,8 @@ struct rf_params_s { copy_ptr supported_band_combination_list_v1540; // group 1 copy_ptr supported_band_combination_list_v1550; + // group 2 + copy_ptr supported_band_combination_list_v1560; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23213,6 +24339,20 @@ struct rf_params_s { // RF-ParametersMRDC ::= SEQUENCE struct rf_params_mrdc_s { + struct supported_band_combination_list_nedc_only_v15a0_s_ { + bool supported_band_combination_list_v1540_present = false; + bool supported_band_combination_list_v1560_present = false; + bool supported_band_combination_list_v1570_present = false; + bool supported_band_combination_list_v1580_present = false; + bool supported_band_combination_list_v1590_present = false; + band_combination_list_v1540_l supported_band_combination_list_v1540; + band_combination_list_v1560_l supported_band_combination_list_v1560; + band_combination_list_v1570_l supported_band_combination_list_v1570; + band_combination_list_v1580_l supported_band_combination_list_v1580; + band_combination_list_v1590_l supported_band_combination_list_v1590; + }; + + // member variables bool ext = false; bool supported_band_combination_list_present = false; bool applied_freq_band_list_filt_present = false; @@ -23224,6 +24364,17 @@ struct rf_params_mrdc_s { copy_ptr supported_band_combination_list_v1540; // group 1 copy_ptr supported_band_combination_list_v1550; + // group 2 + copy_ptr supported_band_combination_list_v1560; + copy_ptr supported_band_combination_list_nedc_only; + // group 3 + copy_ptr supported_band_combination_list_v1570; + // group 4 + copy_ptr supported_band_combination_list_v1580; + // group 5 + copy_ptr supported_band_combination_list_v1590; + // group 6 + copy_ptr supported_band_combination_list_nedc_only_v15a0; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23255,14 +24406,10 @@ struct ue_cap_request_filt_nr_s { void to_json(json_writer& j) const; }; -// GeneralParametersMRDC-XDD-Diff ::= SEQUENCE -struct general_params_mrdc_xdd_diff_s { - bool ext = false; - bool split_srb_with_one_ul_path_present = false; - bool split_drb_with_ul_both_mcg_scg_present = false; - bool srb3_present = false; - bool v2x_eutra_v1530_present = false; - // ... +// UE-MRDC-CapabilityAddXDD-Mode-v1560 ::= SEQUENCE +struct ue_mrdc_cap_add_xdd_mode_v1560_s { + bool meas_and_mob_params_mrdc_xdd_diff_v1560_present = false; + meas_and_mob_params_mrdc_xdd_diff_v1560_s meas_and_mob_params_mrdc_xdd_diff_v1560; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23281,22 +24428,17 @@ struct pdcp_params_mrdc_s { void to_json(json_writer& j) const; }; -// UE-MRDC-CapabilityAddFRX-Mode ::= SEQUENCE -struct ue_mrdc_cap_add_frx_mode_s { - meas_and_mob_params_mrdc_frx_diff_s meas_and_mob_params_mrdc_frx_diff; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - -// UE-MRDC-CapabilityAddXDD-Mode ::= SEQUENCE -struct ue_mrdc_cap_add_xdd_mode_s { - bool meas_and_mob_params_mrdc_xdd_diff_present = false; - bool general_params_mrdc_xdd_diff_present = false; - meas_and_mob_params_mrdc_xdd_diff_s meas_and_mob_params_mrdc_xdd_diff; - general_params_mrdc_xdd_diff_s general_params_mrdc_xdd_diff; +// UE-MRDC-Capability-v1560 ::= SEQUENCE +struct ue_mrdc_cap_v1560_s { + bool rx_filts_present = false; + bool meas_and_mob_params_mrdc_v1560_present = false; + bool fdd_add_ue_mrdc_cap_v1560_present = false; + bool tdd_add_ue_mrdc_cap_v1560_present = false; + bool non_crit_ext_present = false; + dyn_octstring rx_filts; + meas_and_mob_params_mrdc_v1560_s meas_and_mob_params_mrdc_v1560; + ue_mrdc_cap_add_xdd_mode_v1560_s fdd_add_ue_mrdc_cap_v1560; + ue_mrdc_cap_add_xdd_mode_v1560_s tdd_add_ue_mrdc_cap_v1560; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23331,6 +24473,44 @@ struct ue_mrdc_cap_s { feature_set_combinations_l_ feature_set_combinations; pdcp_params_mrdc_s pdcp_params_mrdc_v1530; dyn_octstring late_non_crit_ext; + ue_mrdc_cap_v1560_s non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// NRDC-Parameters-v1570 ::= SEQUENCE +struct nrdc_params_v1570_s { + bool sfn_sync_nrdc_present = false; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UE-NR-Capability-v1570 ::= SEQUENCE +struct ue_nr_cap_v1570_s { + bool nrdc_params_v1570_present = false; + bool non_crit_ext_present = false; + nrdc_params_v1570_s nrdc_params_v1570; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UE-NR-Capability-v1560 ::= SEQUENCE +struct ue_nr_cap_v1560_s { + bool nrdc_params_present = false; + bool rx_filts_present = false; + bool non_crit_ext_present = false; + nrdc_params_s nrdc_params; + dyn_octstring rx_filts; + ue_nr_cap_v1570_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23352,8 +24532,9 @@ struct sdap_params_s { // UE-NR-Capability-v1550 ::= SEQUENCE struct ue_nr_cap_v1550_s { - bool reduced_cp_latency_present = false; - bool non_crit_ext_present = false; + bool reduced_cp_latency_present = false; + bool non_crit_ext_present = false; + ue_nr_cap_v1560_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23573,11 +24754,52 @@ struct ue_nr_cap_s { void to_json(json_writer& j) const; }; +// UE-CapabilityRequestFilterCommon ::= SEQUENCE +struct ue_cap_request_filt_common_s { + struct mrdc_request_s_ { + bool omit_en_dc_present = false; + bool include_nr_dc_present = false; + bool include_ne_dc_present = false; + }; + + // member variables + bool ext = false; + bool mrdc_request_present = false; + mrdc_request_s_ mrdc_request; + // ... + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// UECapabilityEnquiry-v1560-IEs ::= SEQUENCE +struct ue_cap_enquiry_v1560_ies_s { + bool cap_request_filt_common_present = false; + bool non_crit_ext_present = false; + ue_cap_request_filt_common_s cap_request_filt_common; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // AS-Config ::= SEQUENCE struct as_cfg_s { bool ext = false; dyn_octstring rrc_recfg; // ... + // group 0 + bool source_rb_sn_cfg_present = false; + bool source_scg_nr_cfg_present = false; + bool source_scg_eutra_cfg_present = false; + dyn_octstring source_rb_sn_cfg; + dyn_octstring source_scg_nr_cfg; + dyn_octstring source_scg_eutra_cfg; + // group 1 + bool source_scg_cfgured_present = false; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23617,6 +24839,20 @@ using band_combination_info_list_l = dyn_array; // ReestabNCellInfoList ::= SEQUENCE (SIZE (1..32)) OF ReestabNCellInfo using reestab_ncell_info_list_l = dyn_array; +// SelectedBandEntriesMN ::= SEQUENCE (SIZE (1..32)) OF INTEGER (0..32) +using sel_band_entries_mn_l = bounded_array; + +// BandCombinationInfoSN ::= SEQUENCE +struct band_combination_info_sn_s { + uint32_t band_combination_idx = 1; + uint8_t requested_feature_sets = 1; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // ConfigRestrictInfoSCG ::= SEQUENCE struct cfg_restrict_info_scg_s { struct pwr_coordination_fr1_s_ { @@ -23631,20 +24867,32 @@ struct cfg_restrict_info_scg_s { uint8_t low_bound = 0; uint8_t up_bound = 0; }; + using sel_band_entries_mn_list_l_ = dyn_array; // member variables - bool ext = false; - bool allowed_bc_list_mrdc_present = false; - bool pwr_coordination_fr1_present = false; - bool serv_cell_idx_range_scg_present = false; - bool max_meas_freqs_scg_nr_present = false; - bool max_meas_identities_scg_nr_present = false; + bool ext = false; + bool allowed_bc_list_mrdc_present = false; + bool pwr_coordination_fr1_present = false; + bool serv_cell_idx_range_scg_present = false; + bool max_meas_freqs_scg_present = false; + bool dummy_present = false; band_combination_info_list_l allowed_bc_list_mrdc; pwr_coordination_fr1_s_ pwr_coordination_fr1; serv_cell_idx_range_scg_s_ serv_cell_idx_range_scg; - uint8_t max_meas_freqs_scg_nr = 1; - uint8_t max_meas_identities_scg_nr = 1; + uint8_t max_meas_freqs_scg = 1; + uint8_t dummy = 1; // ... + // group 0 + bool pdcch_blind_detection_scg_present = false; + bool max_num_rohc_context_sessions_sn_present = false; + copy_ptr sel_band_entries_mn_list; + uint8_t pdcch_blind_detection_scg = 1; + uint16_t max_num_rohc_context_sessions_sn = 0; + // group 1 + bool max_intra_freq_meas_identities_scg_present = false; + bool max_inter_freq_meas_identities_scg_present = false; + uint8_t max_intra_freq_meas_identities_scg = 1; + uint8_t max_inter_freq_meas_identities_scg = 1; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23678,6 +24926,8 @@ struct as_context_s { // group 1 bool ue_assist_info_present = false; dyn_octstring ue_assist_info; + // group 2 + copy_ptr sel_band_combination_sn; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23732,17 +24982,6 @@ struct affected_carrier_freq_comb_info_mrdc_s { void to_json(json_writer& j) const; }; -// BandCombinationInfoSN ::= SEQUENCE -struct band_combination_info_sn_s { - uint32_t band_combination_idx = 1; - uint8_t requested_feature_sets = 1; - - // sequence methods - SRSASN_CODE pack(bit_ref& bref) const; - SRSASN_CODE unpack(cbit_ref& bref); - void to_json(json_writer& j) const; -}; - // PH-UplinkCarrierSCG ::= SEQUENCE struct ph_ul_carrier_scg_s { struct ph_type1or3_opts { @@ -23765,6 +25004,27 @@ struct ph_ul_carrier_scg_s { void to_json(json_writer& j) const; }; +// CG-Config-v1590-IEs ::= SEQUENCE +struct cg_cfg_v1590_ies_s { + using scell_frequencies_sn_nr_l_ = bounded_array; + using scell_frequencies_sn_eutra_l_ = bounded_array; + + // member variables + bool scell_frequencies_sn_nr_present = false; + bool scell_frequencies_sn_eutra_present = false; + bool non_crit_ext_present = false; + scell_frequencies_sn_nr_l_ scell_frequencies_sn_nr; + scell_frequencies_sn_eutra_l_ scell_frequencies_sn_eutra; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + +// CandidateServingFreqListEUTRA ::= SEQUENCE (SIZE (1..32)) OF INTEGER (0..262143) +using candidate_serving_freq_list_eutra_l = bounded_array; + // PH-InfoSCG ::= SEQUENCE struct ph_info_scg_s { bool ext = false; @@ -23780,6 +25040,42 @@ struct ph_info_scg_s { void to_json(json_writer& j) const; }; +// CG-Config-v1560-IEs ::= SEQUENCE +struct cg_cfg_v1560_ies_s { + struct report_cgi_request_eutra_s_ { + struct requested_cell_info_eutra_s_ { + uint32_t eutra_freq = 0; + uint16_t cell_for_which_to_report_cgi_eutra = 0; + }; + + // member variables + bool requested_cell_info_eutra_present = false; + requested_cell_info_eutra_s_ requested_cell_info_eutra; + }; + + // member variables + bool pscell_freq_eutra_present = false; + bool scg_cell_group_cfg_eutra_present = false; + bool candidate_cell_info_list_sn_eutra_present = false; + bool candidate_serving_freq_list_eutra_present = false; + bool need_for_gaps_present = false; + bool drx_cfg_scg_present = false; + bool report_cgi_request_eutra_present = false; + bool non_crit_ext_present = false; + uint32_t pscell_freq_eutra = 0; + dyn_octstring scg_cell_group_cfg_eutra; + dyn_octstring candidate_cell_info_list_sn_eutra; + candidate_serving_freq_list_eutra_l candidate_serving_freq_list_eutra; + drx_cfg_s drx_cfg_scg; + report_cgi_request_eutra_s_ report_cgi_request_eutra; + cg_cfg_v1590_ies_s non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // FR-Info ::= SEQUENCE struct fr_info_s { struct fr_type_opts { @@ -23819,7 +25115,7 @@ using ph_type_list_scg_l = dyn_array; // CG-Config-v1540-IEs ::= SEQUENCE struct cg_cfg_v1540_ies_s { - struct report_cgi_request_s_ { + struct report_cgi_request_nr_s_ { struct requested_cell_info_s_ { uint32_t ssb_freq = 0; uint16_t cell_for_which_to_report_cgi = 0; @@ -23831,13 +25127,14 @@ struct cg_cfg_v1540_ies_s { }; // member variables - bool pscell_freq_present = false; - bool report_cgi_request_present = false; - bool ph_info_scg_present = false; - bool non_crit_ext_present = false; - uint32_t pscell_freq = 0; - report_cgi_request_s_ report_cgi_request; - ph_type_list_scg_l ph_info_scg; + bool pscell_freq_present = false; + bool report_cgi_request_nr_present = false; + bool ph_info_scg_present = false; + bool non_crit_ext_present = false; + uint32_t pscell_freq = 0; + report_cgi_request_nr_s_ report_cgi_request_nr; + ph_type_list_scg_l ph_info_scg; + cg_cfg_v1560_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -23856,6 +25153,11 @@ struct cfg_restrict_mod_req_scg_s { band_combination_info_sn_s requested_bc_mrdc; int8_t requested_p_max_fr1 = -30; // ... + // group 0 + bool requested_pdcch_blind_detection_scg_present = false; + bool requested_p_max_eutra_present = false; + uint8_t requested_pdcch_blind_detection_scg = 1; + int8_t requested_p_max_eutra = -30; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -24302,7 +25604,7 @@ struct cg_cfg_ies_s { bool drx_info_scg_present = false; bool candidate_cell_info_list_sn_present = false; bool meas_cfg_sn_present = false; - bool sel_band_combination_nr_present = false; + bool sel_band_combination_present = false; bool fr_info_list_scg_present = false; bool candidate_serving_freq_list_nr_present = false; bool non_crit_ext_present = false; @@ -24312,7 +25614,7 @@ struct cg_cfg_ies_s { drx_info_s drx_info_scg; dyn_octstring candidate_cell_info_list_sn; meas_cfg_sn_s meas_cfg_sn; - band_combination_info_sn_s sel_band_combination_nr; + band_combination_info_sn_s sel_band_combination; fr_info_list_l fr_info_list_scg; candidate_serving_freq_list_nr_l candidate_serving_freq_list_nr; cg_cfg_v1540_ies_s non_crit_ext; @@ -24414,6 +25716,21 @@ struct cg_cfg_s { void to_json(json_writer& j) const; }; +// CG-ConfigInfo-v1590-IEs ::= SEQUENCE +struct cg_cfg_info_v1590_ies_s { + using serv_frequencies_mn_nr_l_ = bounded_array; + + // member variables + bool serv_frequencies_mn_nr_present = false; + bool non_crit_ext_present = false; + serv_frequencies_mn_nr_l_ serv_frequencies_mn_nr; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // PH-UplinkCarrierMCG ::= SEQUENCE struct ph_ul_carrier_mcg_s { struct ph_type1or3_opts { @@ -24436,6 +25753,27 @@ struct ph_ul_carrier_mcg_s { void to_json(json_writer& j) const; }; +// SFTD-FrequencyList-EUTRA ::= SEQUENCE (SIZE (1..3)) OF INTEGER (0..262143) +using sftd_freq_list_eutra_l = bounded_array; + +// SFTD-FrequencyList-NR ::= SEQUENCE (SIZE (1..3)) OF INTEGER (0..3279165) +using sftd_freq_list_nr_l = bounded_array; + +// CG-ConfigInfo-v1570-IEs ::= SEQUENCE +struct cg_cfg_info_v1570_ies_s { + bool sftd_freq_list_nr_present = false; + bool sftd_freq_list_eutra_present = false; + bool non_crit_ext_present = false; + sftd_freq_list_nr_l sftd_freq_list_nr; + sftd_freq_list_eutra_l sftd_freq_list_eutra; + cg_cfg_info_v1590_ies_s non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // PH-InfoMCG ::= SEQUENCE struct ph_info_mcg_s { bool ext = false; @@ -24451,15 +25789,63 @@ struct ph_info_mcg_s { void to_json(json_writer& j) const; }; +// CG-ConfigInfo-v1560-IEs ::= SEQUENCE +struct cg_cfg_info_v1560_ies_s { + struct scg_fail_info_eutra_s_ { + struct fail_type_eutra_opts { + enum options { t313_expiry, random_access_problem, rlc_max_num_retx, scg_change_fail, nulltype } value; + typedef uint16_t number_type; + + std::string to_string() const; + uint16_t to_number() const; + }; + typedef enumerated fail_type_eutra_e_; + + // member variables + fail_type_eutra_e_ fail_type_eutra; + dyn_octstring meas_result_scg_eutra; + }; + struct meas_result_report_cgi_eutra_s_ { + uint32_t eutra_freq = 0; + uint16_t cell_for_which_to_report_cgi_eutra = 0; + cgi_info_eutra_s cgi_info_eutra; + }; + + // member variables + bool candidate_cell_info_list_mn_eutra_present = false; + bool candidate_cell_info_list_sn_eutra_present = false; + bool source_cfg_scg_eutra_present = false; + bool scg_fail_info_eutra_present = false; + bool drx_cfg_mcg_present = false; + bool meas_result_report_cgi_eutra_present = false; + bool meas_result_cell_list_sftd_eutra_present = false; + bool fr_info_list_mcg_present = false; + bool non_crit_ext_present = false; + dyn_octstring candidate_cell_info_list_mn_eutra; + dyn_octstring candidate_cell_info_list_sn_eutra; + dyn_octstring source_cfg_scg_eutra; + scg_fail_info_eutra_s_ scg_fail_info_eutra; + drx_cfg_s drx_cfg_mcg; + meas_result_report_cgi_eutra_s_ meas_result_report_cgi_eutra; + meas_result_cell_list_sftd_eutra_l meas_result_cell_list_sftd_eutra; + fr_info_list_l fr_info_list_mcg; + cg_cfg_info_v1570_ies_s non_crit_ext; + + // sequence methods + SRSASN_CODE pack(bit_ref& bref) const; + SRSASN_CODE unpack(cbit_ref& bref); + void to_json(json_writer& j) const; +}; + // PH-TypeListMCG ::= SEQUENCE (SIZE (1..32)) OF PH-InfoMCG using ph_type_list_mcg_l = dyn_array; // CG-ConfigInfo-v1540-IEs ::= SEQUENCE struct cg_cfg_info_v1540_ies_s { struct meas_result_report_cgi_s_ { - uint32_t ssb_freq = 0; - uint16_t cell_for_which_to_report_cgi = 0; - cgi_info_s cgi_info; + uint32_t ssb_freq = 0; + uint16_t cell_for_which_to_report_cgi = 0; + cgi_info_nr_s cgi_info; }; // member variables @@ -24468,6 +25854,7 @@ struct cg_cfg_info_v1540_ies_s { bool non_crit_ext_present = false; ph_type_list_mcg_l ph_info_mcg; meas_result_report_cgi_s_ meas_result_report_cgi; + cg_cfg_info_v1560_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -24511,6 +25898,8 @@ struct meas_cfg_mn_s { setup_release_c meas_gap_cfg; gap_purpose_e_ gap_purpose; // ... + // group 0 + copy_ptr > meas_gap_cfg_fr2; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -24544,32 +25933,32 @@ struct cg_cfg_info_ies_s { }; // member variables - bool ue_cap_info_present = false; - bool candidate_cell_info_list_mn_present = false; - bool candidate_cell_info_list_sn_present = false; - bool meas_result_cell_list_sftd_present = false; - bool scg_fail_info_present = false; - bool cfg_restrict_info_present = false; - bool drx_info_mcg_present = false; - bool meas_cfg_mn_present = false; - bool source_cfg_scg_present = false; - bool scg_rb_cfg_present = false; - bool mcg_rb_cfg_present = false; - bool mrdc_assist_info_present = false; - bool non_crit_ext_present = false; - dyn_octstring ue_cap_info; - meas_result_list2_nr_l candidate_cell_info_list_mn; - dyn_octstring candidate_cell_info_list_sn; - meas_result_cell_list_sftd_l meas_result_cell_list_sftd; - scg_fail_info_s_ scg_fail_info; - cfg_restrict_info_scg_s cfg_restrict_info; - drx_info_s drx_info_mcg; - meas_cfg_mn_s meas_cfg_mn; - dyn_octstring source_cfg_scg; - dyn_octstring scg_rb_cfg; - dyn_octstring mcg_rb_cfg; - mrdc_assist_info_s mrdc_assist_info; - cg_cfg_info_v1540_ies_s non_crit_ext; + bool ue_cap_info_present = false; + bool candidate_cell_info_list_mn_present = false; + bool candidate_cell_info_list_sn_present = false; + bool meas_result_cell_list_sftd_nr_present = false; + bool scg_fail_info_present = false; + bool cfg_restrict_info_present = false; + bool drx_info_mcg_present = false; + bool meas_cfg_mn_present = false; + bool source_cfg_scg_present = false; + bool scg_rb_cfg_present = false; + bool mcg_rb_cfg_present = false; + bool mrdc_assist_info_present = false; + bool non_crit_ext_present = false; + dyn_octstring ue_cap_info; + meas_result_list2_nr_l candidate_cell_info_list_mn; + dyn_octstring candidate_cell_info_list_sn; + meas_result_cell_list_sftd_nr_l meas_result_cell_list_sftd_nr; + scg_fail_info_s_ scg_fail_info; + cfg_restrict_info_scg_s cfg_restrict_info; + drx_info_s drx_info_mcg; + meas_cfg_mn_s meas_cfg_mn; + dyn_octstring source_cfg_scg; + dyn_octstring scg_rb_cfg; + dyn_octstring mcg_rb_cfg; + mrdc_assist_info_s mrdc_assist_info; + cg_cfg_info_v1540_ies_s non_crit_ext; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -24912,6 +26301,8 @@ struct rrm_cfg_s { ue_inactive_time_e_ ue_inactive_time; meas_result_list2_nr_l candidate_cell_info_list; // ... + // group 0 + copy_ptr candidate_cell_info_list_sn_eutra; // sequence methods SRSASN_CODE pack(bit_ref& bref) const; @@ -25044,7 +26435,7 @@ struct meas_timing_s { // ... // group 0 bool pci_present = false; - copy_ptr ssb_to_measure_v1540; + copy_ptr ssb_to_measure; uint16_t pci = 0; // sequence methods diff --git a/lib/src/asn1/rrc_nr.cc b/lib/src/asn1/rrc_nr.cc index c9e2a3e5b..2499cdf64 100644 --- a/lib/src/asn1/rrc_nr.cc +++ b/lib/src/asn1/rrc_nr.cc @@ -377,7 +377,7 @@ SRSASN_CODE eutra_freq_neigh_cell_info_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(q_qual_min_offset_cell_present, 1)); HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)503u)); - HANDLE_CODE(q_offset_cell.pack(bref)); + HANDLE_CODE(dummy.pack(bref)); if (q_rx_lev_min_offset_cell_present) { HANDLE_CODE(pack_integer(bref, q_rx_lev_min_offset_cell, (uint8_t)1u, (uint8_t)8u)); } @@ -393,7 +393,7 @@ SRSASN_CODE eutra_freq_neigh_cell_info_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(q_qual_min_offset_cell_present, 1)); HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)503u)); - HANDLE_CODE(q_offset_cell.unpack(bref)); + HANDLE_CODE(dummy.unpack(bref)); if (q_rx_lev_min_offset_cell_present) { HANDLE_CODE(unpack_integer(q_rx_lev_min_offset_cell, bref, (uint8_t)1u, (uint8_t)8u)); } @@ -407,7 +407,7 @@ void eutra_freq_neigh_cell_info_s::to_json(json_writer& j) const { j.start_obj(); j.write_int("physCellId", pci); - j.write_str("q-OffsetCell", q_offset_cell.to_string()); + j.write_str("dummy", dummy.to_string()); if (q_rx_lev_min_offset_cell_present) { j.write_int("q-RxLevMinOffsetCell", q_rx_lev_min_offset_cell); } @@ -1144,8 +1144,8 @@ ssb_mtc_s::periodicity_and_offset_c_::periodicity_and_offset_c_(const ssb_mtc_s: log_invalid_choice_id(type_, "ssb_mtc_s::periodicity_and_offset_c_"); } } -ssb_mtc_s::periodicity_and_offset_c_& ssb_mtc_s::periodicity_and_offset_c_:: - operator=(const ssb_mtc_s::periodicity_and_offset_c_& other) +ssb_mtc_s::periodicity_and_offset_c_& +ssb_mtc_s::periodicity_and_offset_c_::operator=(const ssb_mtc_s::periodicity_and_offset_c_& other) { if (this == &other) { return *this; @@ -1597,8 +1597,9 @@ search_space_s::monitoring_slot_periodicity_and_offset_c_::monitoring_slot_perio log_invalid_choice_id(type_, "search_space_s::monitoring_slot_periodicity_and_offset_c_"); } } -search_space_s::monitoring_slot_periodicity_and_offset_c_& search_space_s::monitoring_slot_periodicity_and_offset_c_:: - operator=(const search_space_s::monitoring_slot_periodicity_and_offset_c_& other) +search_space_s::monitoring_slot_periodicity_and_offset_c_& +search_space_s::monitoring_slot_periodicity_and_offset_c_::operator=( + const search_space_s::monitoring_slot_periodicity_and_offset_c_& other) { if (this == &other) { return *this; @@ -1947,8 +1948,8 @@ search_space_s::search_space_type_c_::search_space_type_c_(const search_space_s: log_invalid_choice_id(type_, "search_space_s::search_space_type_c_"); } } -search_space_s::search_space_type_c_& search_space_s::search_space_type_c_:: - operator=(const search_space_s::search_space_type_c_& other) +search_space_s::search_space_type_c_& +search_space_s::search_space_type_c_::operator=(const search_space_s::search_space_type_c_& other) { if (this == &other) { return *this; @@ -3158,8 +3159,8 @@ pdcch_cfg_common_s::first_pdcch_monitoring_occasion_of_po_c_::first_pdcch_monito } } pdcch_cfg_common_s::first_pdcch_monitoring_occasion_of_po_c_& -pdcch_cfg_common_s::first_pdcch_monitoring_occasion_of_po_c_:: -operator=(const pdcch_cfg_common_s::first_pdcch_monitoring_occasion_of_po_c_& other) +pdcch_cfg_common_s::first_pdcch_monitoring_occasion_of_po_c_::operator=( + const pdcch_cfg_common_s::first_pdcch_monitoring_occasion_of_po_c_& other) { if (this == &other) { return *this; @@ -3769,8 +3770,8 @@ rach_cfg_common_s::ssb_per_rach_occasion_and_cb_preambs_per_ssb_c_::ssb_per_rach } } rach_cfg_common_s::ssb_per_rach_occasion_and_cb_preambs_per_ssb_c_& -rach_cfg_common_s::ssb_per_rach_occasion_and_cb_preambs_per_ssb_c_:: -operator=(const rach_cfg_common_s::ssb_per_rach_occasion_and_cb_preambs_per_ssb_c_& other) +rach_cfg_common_s::ssb_per_rach_occasion_and_cb_preambs_per_ssb_c_::operator=( + const rach_cfg_common_s::ssb_per_rach_occasion_and_cb_preambs_per_ssb_c_& other) { if (this == &other) { return *this; @@ -4071,8 +4072,8 @@ rach_cfg_common_s::prach_root_seq_idx_c_::prach_root_seq_idx_c_(const rach_cfg_c log_invalid_choice_id(type_, "rach_cfg_common_s::prach_root_seq_idx_c_"); } } -rach_cfg_common_s::prach_root_seq_idx_c_& rach_cfg_common_s::prach_root_seq_idx_c_:: - operator=(const rach_cfg_common_s::prach_root_seq_idx_c_& other) +rach_cfg_common_s::prach_root_seq_idx_c_& +rach_cfg_common_s::prach_root_seq_idx_c_::operator=(const rach_cfg_common_s::prach_root_seq_idx_c_& other) { if (this == &other) { return *this; @@ -4170,15 +4171,15 @@ SRSASN_CODE scs_specific_carrier_s::pack(bit_ref& bref) const if (ext) { ext_groups_packer_guard group_flags; - group_flags[0] |= tx_direct_current_location_v1530_present; + group_flags[0] |= tx_direct_current_location_present; group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(tx_direct_current_location_v1530_present, 1)); - if (tx_direct_current_location_v1530_present) { - HANDLE_CODE(pack_integer(bref, tx_direct_current_location_v1530, (uint16_t)0u, (uint16_t)4095u)); + HANDLE_CODE(bref.pack(tx_direct_current_location_present, 1)); + if (tx_direct_current_location_present) { + HANDLE_CODE(pack_integer(bref, tx_direct_current_location, (uint16_t)0u, (uint16_t)4095u)); } } } @@ -4198,9 +4199,9 @@ SRSASN_CODE scs_specific_carrier_s::unpack(cbit_ref& bref) if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.unpack(tx_direct_current_location_v1530_present, 1)); - if (tx_direct_current_location_v1530_present) { - HANDLE_CODE(unpack_integer(tx_direct_current_location_v1530, bref, (uint16_t)0u, (uint16_t)4095u)); + HANDLE_CODE(bref.unpack(tx_direct_current_location_present, 1)); + if (tx_direct_current_location_present) { + HANDLE_CODE(unpack_integer(tx_direct_current_location, bref, (uint16_t)0u, (uint16_t)4095u)); } } } @@ -4213,8 +4214,8 @@ void scs_specific_carrier_s::to_json(json_writer& j) const j.write_str("subcarrierSpacing", subcarrier_spacing.to_string()); j.write_int("carrierBandwidth", carrier_bw); if (ext) { - if (tx_direct_current_location_v1530_present) { - j.write_int("txDirectCurrentLocation-v1530", tx_direct_current_location_v1530); + if (tx_direct_current_location_present) { + j.write_int("txDirectCurrentLocation", tx_direct_current_location); } } j.end_obj(); @@ -4741,8 +4742,8 @@ pcch_cfg_s::nand_paging_frame_offset_c_::nand_paging_frame_offset_c_( log_invalid_choice_id(type_, "pcch_cfg_s::nand_paging_frame_offset_c_"); } } -pcch_cfg_s::nand_paging_frame_offset_c_& pcch_cfg_s::nand_paging_frame_offset_c_:: - operator=(const pcch_cfg_s::nand_paging_frame_offset_c_& other) +pcch_cfg_s::nand_paging_frame_offset_c_& +pcch_cfg_s::nand_paging_frame_offset_c_::operator=(const pcch_cfg_s::nand_paging_frame_offset_c_& other) { if (this == &other) { return *this; @@ -4973,8 +4974,8 @@ pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_::first_pdcch_monitoring_occ log_invalid_choice_id(type_, "pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_"); } } -pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_& pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_:: - operator=(const pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_& other) +pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_& pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_::operator=( + const pcch_cfg_s::first_pdcch_monitoring_occasion_of_po_c_& other) { if (this == &other) { return *this; @@ -6543,8 +6544,8 @@ uac_barr_per_plmn_s::uac_ac_barr_list_type_c_::uac_ac_barr_list_type_c_( log_invalid_choice_id(type_, "uac_barr_per_plmn_s::uac_ac_barr_list_type_c_"); } } -uac_barr_per_plmn_s::uac_ac_barr_list_type_c_& uac_barr_per_plmn_s::uac_ac_barr_list_type_c_:: - operator=(const uac_barr_per_plmn_s::uac_ac_barr_list_type_c_& other) +uac_barr_per_plmn_s::uac_ac_barr_list_type_c_& +uac_barr_per_plmn_s::uac_ac_barr_list_type_c_::operator=(const uac_barr_per_plmn_s::uac_ac_barr_list_type_c_& other) { if (this == &other) { return *this; @@ -7093,8 +7094,8 @@ sys_info_ies_s::sib_type_and_info_item_c_::sib_type_and_info_item_c_( log_invalid_choice_id(type_, "sys_info_ies_s::sib_type_and_info_item_c_"); } } -sys_info_ies_s::sib_type_and_info_item_c_& sys_info_ies_s::sib_type_and_info_item_c_:: - operator=(const sys_info_ies_s::sib_type_and_info_item_c_& other) +sys_info_ies_s::sib_type_and_info_item_c_& +sys_info_ies_s::sib_type_and_info_item_c_::operator=(const sys_info_ies_s::sib_type_and_info_item_c_& other) { if (this == &other) { return *this; @@ -7646,8 +7647,8 @@ sib1_s::uac_barr_info_s_::uac_access_category1_sel_assist_info_c_::uac_access_ca } } sib1_s::uac_barr_info_s_::uac_access_category1_sel_assist_info_c_& -sib1_s::uac_barr_info_s_::uac_access_category1_sel_assist_info_c_:: -operator=(const sib1_s::uac_barr_info_s_::uac_access_category1_sel_assist_info_c_& other) +sib1_s::uac_barr_info_s_::uac_access_category1_sel_assist_info_c_::operator=( + const sib1_s::uac_barr_info_s_::uac_access_category1_sel_assist_info_c_& other) { if (this == &other) { return *this; @@ -7753,7 +7754,7 @@ void sys_info_s::to_json(json_writer& j) const void sys_info_s::crit_exts_c_::destroy_() { switch (type_) { - case types::sys_info_r15: + case types::sys_info: c.destroy(); break; default: @@ -7765,7 +7766,7 @@ void sys_info_s::crit_exts_c_::set(types::options e) destroy_(); type_ = e; switch (type_) { - case types::sys_info_r15: + case types::sys_info: c.init(); break; case types::crit_exts_future: @@ -7780,7 +7781,7 @@ sys_info_s::crit_exts_c_::crit_exts_c_(const sys_info_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::sys_info_r15: + case types::sys_info: c.init(other.c.get()); break; case types::crit_exts_future: @@ -7798,7 +7799,7 @@ sys_info_s::crit_exts_c_& sys_info_s::crit_exts_c_::operator=(const sys_info_s:: } set(other.type()); switch (type_) { - case types::sys_info_r15: + case types::sys_info: c.set(other.c.get()); break; case types::crit_exts_future: @@ -7815,8 +7816,8 @@ void sys_info_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::sys_info_r15: - j.write_fieldname("systemInformation-r15"); + case types::sys_info: + j.write_fieldname("systemInformation"); c.get().to_json(j); break; case types::crit_exts_future: @@ -7830,7 +7831,7 @@ SRSASN_CODE sys_info_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::sys_info_r15: + case types::sys_info: HANDLE_CODE(c.get().pack(bref)); break; case types::crit_exts_future: @@ -7847,7 +7848,7 @@ SRSASN_CODE sys_info_s::crit_exts_c_::unpack(cbit_ref& bref) e.unpack(bref); set(e); switch (type_) { - case types::sys_info_r15: + case types::sys_info: HANDLE_CODE(c.get().unpack(bref)); break; case types::crit_exts_future: @@ -7861,7 +7862,7 @@ SRSASN_CODE sys_info_s::crit_exts_c_::unpack(cbit_ref& bref) std::string sys_info_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"systemInformation-r15", "criticalExtensionsFuture"}; + static const char* options[] = {"systemInformation", "criticalExtensionsFuture"}; return convert_enum_idx(options, 2, value, "sys_info_s::crit_exts_c_::types"); } @@ -8148,1614 +8149,1837 @@ void bcch_dl_sch_msg_s::to_json(json_writer& j) const j.end_array(); } -// Alpha ::= ENUMERATED -std::string alpha_opts::to_string() const -{ - static const char* options[] = {"alpha0", "alpha04", "alpha05", "alpha06", "alpha07", "alpha08", "alpha09", "alpha1"}; - return convert_enum_idx(options, 8, value, "alpha_e"); -} -float alpha_opts::to_number() const +// UL-DataSplitThreshold ::= ENUMERATED +std::string ul_data_split_thres_opts::to_string() const { - static const float options[] = {0.0, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1.0}; - return map_enum_number(options, 8, value, "alpha_e"); + static const char* options[] = {"b0", "b100", "b200", "b400", "b800", "b1600", "b3200", + "b6400", "b12800", "b25600", "b51200", "b102400", "b204800", "b409600", + "b819200", "b1228800", "b1638400", "b2457600", "b3276800", "b4096000", "b4915200", + "b5734400", "b6553600", "infinity", "spare8", "spare7", "spare6", "spare5", + "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 32, value, "ul_data_split_thres_e"); } -std::string alpha_opts::to_number_string() const +int32_t ul_data_split_thres_opts::to_number() const { - static const char* options[] = {"0", "0.4", "0.5", "0.6", "0.7", "0.8", "0.9", "1"}; - return convert_enum_idx(options, 8, value, "alpha_e"); + static const int32_t options[] = {0, 100, 200, 400, 800, 1600, 3200, 6400, + 12800, 25600, 51200, 102400, 204800, 409600, 819200, 1228800, + 1638400, 2457600, 3276800, 4096000, 4915200, 5734400, 6553600, -1}; + return map_enum_number(options, 24, value, "ul_data_split_thres_e"); } -// BFR-CSIRS-Resource ::= SEQUENCE -SRSASN_CODE bfr_csirs_res_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ra_occasion_list_present, 1)); - HANDLE_CODE(bref.pack(ra_preamb_idx_present, 1)); - - HANDLE_CODE(pack_integer(bref, csi_rs, (uint8_t)0u, (uint8_t)191u)); - if (ra_occasion_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ra_occasion_list, 1, 64, integer_packer(0, 511))); - } - if (ra_preamb_idx_present) { - HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE bfr_csirs_res_s::unpack(cbit_ref& bref) +// CipheringAlgorithm ::= ENUMERATED +std::string ciphering_algorithm_opts::to_string() const { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ra_occasion_list_present, 1)); - HANDLE_CODE(bref.unpack(ra_preamb_idx_present, 1)); - - HANDLE_CODE(unpack_integer(csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); - if (ra_occasion_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ra_occasion_list, bref, 1, 64, integer_packer(0, 511))); - } - if (ra_preamb_idx_present) { - HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); - } - - return SRSASN_SUCCESS; + static const char* options[] = {"nea0", "nea1", "nea2", "nea3", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 8, value, "ciphering_algorithm_e"); } -void bfr_csirs_res_s::to_json(json_writer& j) const +uint8_t ciphering_algorithm_opts::to_number() const { - j.start_obj(); - j.write_int("csi-RS", csi_rs); - if (ra_occasion_list_present) { - j.start_array("ra-OccasionList"); - for (const auto& e1 : ra_occasion_list) { - j.write_int(e1); - } - j.end_array(); - } - if (ra_preamb_idx_present) { - j.write_int("ra-PreambleIndex", ra_preamb_idx); - } - j.end_obj(); + static const uint8_t options[] = {0, 1, 2, 3}; + return map_enum_number(options, 4, value, "ciphering_algorithm_e"); } -// BFR-SSB-Resource ::= SEQUENCE -SRSASN_CODE bfr_ssb_res_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, ssb, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE bfr_ssb_res_s::unpack(cbit_ref& bref) +// IntegrityProtAlgorithm ::= ENUMERATED +std::string integrity_prot_algorithm_opts::to_string() const { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(ssb, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); - - return SRSASN_SUCCESS; + static const char* options[] = {"nia0", "nia1", "nia2", "nia3", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 8, value, "integrity_prot_algorithm_e"); } -void bfr_ssb_res_s::to_json(json_writer& j) const +uint8_t integrity_prot_algorithm_opts::to_number() const { - j.start_obj(); - j.write_int("ssb", ssb); - j.write_int("ra-PreambleIndex", ra_preamb_idx); - j.end_obj(); + static const uint8_t options[] = {0, 1, 2, 3}; + return map_enum_number(options, 4, value, "integrity_prot_algorithm_e"); } -// BetaOffsets ::= SEQUENCE -SRSASN_CODE beta_offsets_s::pack(bit_ref& bref) const +// PDCP-Config ::= SEQUENCE +SRSASN_CODE pdcp_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(beta_offset_ack_idx1_present, 1)); - HANDLE_CODE(bref.pack(beta_offset_ack_idx2_present, 1)); - HANDLE_CODE(bref.pack(beta_offset_ack_idx3_present, 1)); - HANDLE_CODE(bref.pack(beta_offset_csi_part1_idx1_present, 1)); - HANDLE_CODE(bref.pack(beta_offset_csi_part1_idx2_present, 1)); - HANDLE_CODE(bref.pack(beta_offset_csi_part2_idx1_present, 1)); - HANDLE_CODE(bref.pack(beta_offset_csi_part2_idx2_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(drb_present, 1)); + HANDLE_CODE(bref.pack(more_than_one_rlc_present, 1)); + HANDLE_CODE(bref.pack(t_reordering_present, 1)); - if (beta_offset_ack_idx1_present) { - HANDLE_CODE(pack_integer(bref, beta_offset_ack_idx1, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_ack_idx2_present) { - HANDLE_CODE(pack_integer(bref, beta_offset_ack_idx2, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_ack_idx3_present) { - HANDLE_CODE(pack_integer(bref, beta_offset_ack_idx3, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_csi_part1_idx1_present) { - HANDLE_CODE(pack_integer(bref, beta_offset_csi_part1_idx1, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_csi_part1_idx2_present) { - HANDLE_CODE(pack_integer(bref, beta_offset_csi_part1_idx2, (uint8_t)0u, (uint8_t)31u)); + if (drb_present) { + HANDLE_CODE(bref.pack(drb.discard_timer_present, 1)); + HANDLE_CODE(bref.pack(drb.pdcp_sn_size_ul_present, 1)); + HANDLE_CODE(bref.pack(drb.pdcp_sn_size_dl_present, 1)); + HANDLE_CODE(bref.pack(drb.integrity_protection_present, 1)); + HANDLE_CODE(bref.pack(drb.status_report_required_present, 1)); + HANDLE_CODE(bref.pack(drb.out_of_order_delivery_present, 1)); + if (drb.discard_timer_present) { + HANDLE_CODE(drb.discard_timer.pack(bref)); + } + if (drb.pdcp_sn_size_ul_present) { + HANDLE_CODE(drb.pdcp_sn_size_ul.pack(bref)); + } + if (drb.pdcp_sn_size_dl_present) { + HANDLE_CODE(drb.pdcp_sn_size_dl.pack(bref)); + } + HANDLE_CODE(drb.hdr_compress.pack(bref)); } - if (beta_offset_csi_part2_idx1_present) { - HANDLE_CODE(pack_integer(bref, beta_offset_csi_part2_idx1, (uint8_t)0u, (uint8_t)31u)); + if (more_than_one_rlc_present) { + HANDLE_CODE(bref.pack(more_than_one_rlc.ul_data_split_thres_present, 1)); + HANDLE_CODE(bref.pack(more_than_one_rlc.pdcp_dupl_present, 1)); + HANDLE_CODE(bref.pack(more_than_one_rlc.primary_path.cell_group_present, 1)); + HANDLE_CODE(bref.pack(more_than_one_rlc.primary_path.lc_ch_present, 1)); + if (more_than_one_rlc.primary_path.cell_group_present) { + HANDLE_CODE(pack_integer(bref, more_than_one_rlc.primary_path.cell_group, (uint8_t)0u, (uint8_t)3u)); + } + if (more_than_one_rlc.primary_path.lc_ch_present) { + HANDLE_CODE(pack_integer(bref, more_than_one_rlc.primary_path.lc_ch, (uint8_t)1u, (uint8_t)32u)); + } + if (more_than_one_rlc.ul_data_split_thres_present) { + HANDLE_CODE(more_than_one_rlc.ul_data_split_thres.pack(bref)); + } + if (more_than_one_rlc.pdcp_dupl_present) { + HANDLE_CODE(bref.pack(more_than_one_rlc.pdcp_dupl, 1)); + } } - if (beta_offset_csi_part2_idx2_present) { - HANDLE_CODE(pack_integer(bref, beta_offset_csi_part2_idx2, (uint8_t)0u, (uint8_t)31u)); + if (t_reordering_present) { + HANDLE_CODE(t_reordering.pack(bref)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= ciphering_disabled_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(ciphering_disabled_present, 1)); + } + } return SRSASN_SUCCESS; } -SRSASN_CODE beta_offsets_s::unpack(cbit_ref& bref) +SRSASN_CODE pdcp_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(beta_offset_ack_idx1_present, 1)); - HANDLE_CODE(bref.unpack(beta_offset_ack_idx2_present, 1)); - HANDLE_CODE(bref.unpack(beta_offset_ack_idx3_present, 1)); - HANDLE_CODE(bref.unpack(beta_offset_csi_part1_idx1_present, 1)); - HANDLE_CODE(bref.unpack(beta_offset_csi_part1_idx2_present, 1)); - HANDLE_CODE(bref.unpack(beta_offset_csi_part2_idx1_present, 1)); - HANDLE_CODE(bref.unpack(beta_offset_csi_part2_idx2_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(drb_present, 1)); + HANDLE_CODE(bref.unpack(more_than_one_rlc_present, 1)); + HANDLE_CODE(bref.unpack(t_reordering_present, 1)); - if (beta_offset_ack_idx1_present) { - HANDLE_CODE(unpack_integer(beta_offset_ack_idx1, bref, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_ack_idx2_present) { - HANDLE_CODE(unpack_integer(beta_offset_ack_idx2, bref, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_ack_idx3_present) { - HANDLE_CODE(unpack_integer(beta_offset_ack_idx3, bref, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_csi_part1_idx1_present) { - HANDLE_CODE(unpack_integer(beta_offset_csi_part1_idx1, bref, (uint8_t)0u, (uint8_t)31u)); - } - if (beta_offset_csi_part1_idx2_present) { - HANDLE_CODE(unpack_integer(beta_offset_csi_part1_idx2, bref, (uint8_t)0u, (uint8_t)31u)); + if (drb_present) { + HANDLE_CODE(bref.unpack(drb.discard_timer_present, 1)); + HANDLE_CODE(bref.unpack(drb.pdcp_sn_size_ul_present, 1)); + HANDLE_CODE(bref.unpack(drb.pdcp_sn_size_dl_present, 1)); + HANDLE_CODE(bref.unpack(drb.integrity_protection_present, 1)); + HANDLE_CODE(bref.unpack(drb.status_report_required_present, 1)); + HANDLE_CODE(bref.unpack(drb.out_of_order_delivery_present, 1)); + if (drb.discard_timer_present) { + HANDLE_CODE(drb.discard_timer.unpack(bref)); + } + if (drb.pdcp_sn_size_ul_present) { + HANDLE_CODE(drb.pdcp_sn_size_ul.unpack(bref)); + } + if (drb.pdcp_sn_size_dl_present) { + HANDLE_CODE(drb.pdcp_sn_size_dl.unpack(bref)); + } + HANDLE_CODE(drb.hdr_compress.unpack(bref)); } - if (beta_offset_csi_part2_idx1_present) { - HANDLE_CODE(unpack_integer(beta_offset_csi_part2_idx1, bref, (uint8_t)0u, (uint8_t)31u)); + if (more_than_one_rlc_present) { + HANDLE_CODE(bref.unpack(more_than_one_rlc.ul_data_split_thres_present, 1)); + HANDLE_CODE(bref.unpack(more_than_one_rlc.pdcp_dupl_present, 1)); + HANDLE_CODE(bref.unpack(more_than_one_rlc.primary_path.cell_group_present, 1)); + HANDLE_CODE(bref.unpack(more_than_one_rlc.primary_path.lc_ch_present, 1)); + if (more_than_one_rlc.primary_path.cell_group_present) { + HANDLE_CODE(unpack_integer(more_than_one_rlc.primary_path.cell_group, bref, (uint8_t)0u, (uint8_t)3u)); + } + if (more_than_one_rlc.primary_path.lc_ch_present) { + HANDLE_CODE(unpack_integer(more_than_one_rlc.primary_path.lc_ch, bref, (uint8_t)1u, (uint8_t)32u)); + } + if (more_than_one_rlc.ul_data_split_thres_present) { + HANDLE_CODE(more_than_one_rlc.ul_data_split_thres.unpack(bref)); + } + if (more_than_one_rlc.pdcp_dupl_present) { + HANDLE_CODE(bref.unpack(more_than_one_rlc.pdcp_dupl, 1)); + } } - if (beta_offset_csi_part2_idx2_present) { - HANDLE_CODE(unpack_integer(beta_offset_csi_part2_idx2, bref, (uint8_t)0u, (uint8_t)31u)); + if (t_reordering_present) { + HANDLE_CODE(t_reordering.unpack(bref)); } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(ciphering_disabled_present, 1)); + } + } return SRSASN_SUCCESS; } -void beta_offsets_s::to_json(json_writer& j) const +void pdcp_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (beta_offset_ack_idx1_present) { - j.write_int("betaOffsetACK-Index1", beta_offset_ack_idx1); - } - if (beta_offset_ack_idx2_present) { - j.write_int("betaOffsetACK-Index2", beta_offset_ack_idx2); - } - if (beta_offset_ack_idx3_present) { - j.write_int("betaOffsetACK-Index3", beta_offset_ack_idx3); - } - if (beta_offset_csi_part1_idx1_present) { - j.write_int("betaOffsetCSI-Part1-Index1", beta_offset_csi_part1_idx1); + if (drb_present) { + j.write_fieldname("drb"); + j.start_obj(); + if (drb.discard_timer_present) { + j.write_str("discardTimer", drb.discard_timer.to_string()); + } + if (drb.pdcp_sn_size_ul_present) { + j.write_str("pdcp-SN-SizeUL", drb.pdcp_sn_size_ul.to_string()); + } + if (drb.pdcp_sn_size_dl_present) { + j.write_str("pdcp-SN-SizeDL", drb.pdcp_sn_size_dl.to_string()); + } + j.write_fieldname("headerCompression"); + drb.hdr_compress.to_json(j); + if (drb.integrity_protection_present) { + j.write_str("integrityProtection", "enabled"); + } + if (drb.status_report_required_present) { + j.write_str("statusReportRequired", "true"); + } + if (drb.out_of_order_delivery_present) { + j.write_str("outOfOrderDelivery", "true"); + } + j.end_obj(); } - if (beta_offset_csi_part1_idx2_present) { - j.write_int("betaOffsetCSI-Part1-Index2", beta_offset_csi_part1_idx2); + if (more_than_one_rlc_present) { + j.write_fieldname("moreThanOneRLC"); + j.start_obj(); + j.write_fieldname("primaryPath"); + j.start_obj(); + if (more_than_one_rlc.primary_path.cell_group_present) { + j.write_int("cellGroup", more_than_one_rlc.primary_path.cell_group); + } + if (more_than_one_rlc.primary_path.lc_ch_present) { + j.write_int("logicalChannel", more_than_one_rlc.primary_path.lc_ch); + } + j.end_obj(); + if (more_than_one_rlc.ul_data_split_thres_present) { + j.write_str("ul-DataSplitThreshold", more_than_one_rlc.ul_data_split_thres.to_string()); + } + if (more_than_one_rlc.pdcp_dupl_present) { + j.write_bool("pdcp-Duplication", more_than_one_rlc.pdcp_dupl); + } + j.end_obj(); } - if (beta_offset_csi_part2_idx1_present) { - j.write_int("betaOffsetCSI-Part2-Index1", beta_offset_csi_part2_idx1); + if (t_reordering_present) { + j.write_str("t-Reordering", t_reordering.to_string()); } - if (beta_offset_csi_part2_idx2_present) { - j.write_int("betaOffsetCSI-Part2-Index2", beta_offset_csi_part2_idx2); + if (ext) { + if (ciphering_disabled_present) { + j.write_str("cipheringDisabled", "true"); + } } j.end_obj(); } -// CSI-FrequencyOccupation ::= SEQUENCE -SRSASN_CODE csi_freq_occupation_s::pack(bit_ref& bref) const +std::string pdcp_cfg_s::drb_s_::discard_timer_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, start_rb, (uint16_t)0u, (uint16_t)274u)); - HANDLE_CODE(pack_integer(bref, nrof_rbs, (uint16_t)24u, (uint16_t)276u)); - - return SRSASN_SUCCESS; + static const char* options[] = {"ms10", + "ms20", + "ms30", + "ms40", + "ms50", + "ms60", + "ms75", + "ms100", + "ms150", + "ms200", + "ms250", + "ms300", + "ms500", + "ms750", + "ms1500", + "infinity"}; + return convert_enum_idx(options, 16, value, "pdcp_cfg_s::drb_s_::discard_timer_e_"); } -SRSASN_CODE csi_freq_occupation_s::unpack(cbit_ref& bref) +int16_t pdcp_cfg_s::drb_s_::discard_timer_opts::to_number() const { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(start_rb, bref, (uint16_t)0u, (uint16_t)274u)); - HANDLE_CODE(unpack_integer(nrof_rbs, bref, (uint16_t)24u, (uint16_t)276u)); + static const int16_t options[] = {10, 20, 30, 40, 50, 60, 75, 100, 150, 200, 250, 300, 500, 750, 1500, -1}; + return map_enum_number(options, 16, value, "pdcp_cfg_s::drb_s_::discard_timer_e_"); +} - return SRSASN_SUCCESS; +std::string pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_opts::to_string() const +{ + static const char* options[] = {"len12bits", "len18bits"}; + return convert_enum_idx(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_e_"); } -void csi_freq_occupation_s::to_json(json_writer& j) const +uint8_t pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_opts::to_number() const { - j.start_obj(); - j.write_int("startingRB", start_rb); - j.write_int("nrofRBs", nrof_rbs); - j.end_obj(); + static const uint8_t options[] = {12, 18}; + return map_enum_number(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_e_"); } -// P0-PUCCH ::= SEQUENCE -SRSASN_CODE p0_pucch_s::pack(bit_ref& bref) const +std::string pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, p0_pucch_id, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(pack_integer(bref, p0_pucch_value, (int8_t)-16, (int8_t)15)); - - return SRSASN_SUCCESS; + static const char* options[] = {"len12bits", "len18bits"}; + return convert_enum_idx(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_e_"); } -SRSASN_CODE p0_pucch_s::unpack(cbit_ref& bref) +uint8_t pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_opts::to_number() const { - HANDLE_CODE(unpack_integer(p0_pucch_id, bref, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(unpack_integer(p0_pucch_value, bref, (int8_t)-16, (int8_t)15)); - - return SRSASN_SUCCESS; + static const uint8_t options[] = {12, 18}; + return map_enum_number(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_e_"); } -void p0_pucch_s::to_json(json_writer& j) const + +void pdcp_cfg_s::drb_s_::hdr_compress_c_::destroy_() { - j.start_obj(); - j.write_int("p0-PUCCH-Id", p0_pucch_id); - j.write_int("p0-PUCCH-Value", p0_pucch_value); - j.end_obj(); + switch (type_) { + case types::rohc: + c.destroy(); + break; + case types::ul_only_rohc: + c.destroy(); + break; + default: + break; + } } - -// P0-PUSCH-AlphaSet ::= SEQUENCE -SRSASN_CODE p0_pusch_alpha_set_s::pack(bit_ref& bref) const +void pdcp_cfg_s::drb_s_::hdr_compress_c_::set(types::options e) { - HANDLE_CODE(bref.pack(p0_present, 1)); - HANDLE_CODE(bref.pack(alpha_present, 1)); - - HANDLE_CODE(pack_integer(bref, p0_pusch_alpha_set_id, (uint8_t)0u, (uint8_t)29u)); - if (p0_present) { - HANDLE_CODE(pack_integer(bref, p0, (int8_t)-16, (int8_t)15)); + destroy_(); + type_ = e; + switch (type_) { + case types::not_used: + break; + case types::rohc: + c.init(); + break; + case types::ul_only_rohc: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); } - if (alpha_present) { - HANDLE_CODE(alpha.pack(bref)); +} +pdcp_cfg_s::drb_s_::hdr_compress_c_::hdr_compress_c_(const pdcp_cfg_s::drb_s_::hdr_compress_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::not_used: + break; + case types::rohc: + c.init(other.c.get()); + break; + case types::ul_only_rohc: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); } - - return SRSASN_SUCCESS; } -SRSASN_CODE p0_pusch_alpha_set_s::unpack(cbit_ref& bref) +pdcp_cfg_s::drb_s_::hdr_compress_c_& +pdcp_cfg_s::drb_s_::hdr_compress_c_::operator=(const pdcp_cfg_s::drb_s_::hdr_compress_c_& other) { - HANDLE_CODE(bref.unpack(p0_present, 1)); - HANDLE_CODE(bref.unpack(alpha_present, 1)); - - HANDLE_CODE(unpack_integer(p0_pusch_alpha_set_id, bref, (uint8_t)0u, (uint8_t)29u)); - if (p0_present) { - HANDLE_CODE(unpack_integer(p0, bref, (int8_t)-16, (int8_t)15)); + if (this == &other) { + return *this; } - if (alpha_present) { - HANDLE_CODE(alpha.unpack(bref)); + set(other.type()); + switch (type_) { + case types::not_used: + break; + case types::rohc: + c.set(other.c.get()); + break; + case types::ul_only_rohc: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); } - return SRSASN_SUCCESS; + return *this; } -void p0_pusch_alpha_set_s::to_json(json_writer& j) const +void pdcp_cfg_s::drb_s_::hdr_compress_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_int("p0-PUSCH-AlphaSetId", p0_pusch_alpha_set_id); - if (p0_present) { - j.write_int("p0", p0); - } - if (alpha_present) { - j.write_str("alpha", alpha.to_string()); - } - j.end_obj(); -} + switch (type_) { + case types::not_used: + break; + case types::rohc: + j.write_fieldname("rohc"); + j.start_obj(); + if (c.get().max_cid_present) { + j.write_int("maxCID", c.get().max_cid); + } + j.write_fieldname("profiles"); + j.start_obj(); + j.write_bool("profile0x0001", c.get().profiles.profile0x0001); + j.write_bool("profile0x0002", c.get().profiles.profile0x0002); + j.write_bool("profile0x0003", c.get().profiles.profile0x0003); + j.write_bool("profile0x0004", c.get().profiles.profile0x0004); + j.write_bool("profile0x0006", c.get().profiles.profile0x0006); + j.write_bool("profile0x0101", c.get().profiles.profile0x0101); + j.write_bool("profile0x0102", c.get().profiles.profile0x0102); + j.write_bool("profile0x0103", c.get().profiles.profile0x0103); + j.write_bool("profile0x0104", c.get().profiles.profile0x0104); + j.end_obj(); + if (c.get().drb_continue_rohc_present) { + j.write_str("drb-ContinueROHC", "true"); + } + j.end_obj(); + break; + case types::ul_only_rohc: + j.write_fieldname("uplinkOnlyROHC"); + j.start_obj(); + if (c.get().max_cid_present) { + j.write_int("maxCID", c.get().max_cid); + } + j.write_fieldname("profiles"); + j.start_obj(); + j.write_bool("profile0x0006", c.get().profiles.profile0x0006); + j.end_obj(); + if (c.get().drb_continue_rohc_present) { + j.write_str("drb-ContinueROHC", "true"); + } + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + } + j.end_obj(); +} +SRSASN_CODE pdcp_cfg_s::drb_s_::hdr_compress_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::not_used: + break; + case types::rohc: + HANDLE_CODE(bref.pack(c.get().max_cid_present, 1)); + HANDLE_CODE(bref.pack(c.get().drb_continue_rohc_present, 1)); + if (c.get().max_cid_present) { + HANDLE_CODE(pack_integer(bref, c.get().max_cid, (uint16_t)1u, (uint16_t)16383u)); + } + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0001, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0002, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0003, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0004, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0006, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0101, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0102, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0103, 1)); + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0104, 1)); + break; + case types::ul_only_rohc: + HANDLE_CODE(bref.pack(c.get().max_cid_present, 1)); + HANDLE_CODE(bref.pack(c.get().drb_continue_rohc_present, 1)); + if (c.get().max_cid_present) { + HANDLE_CODE(pack_integer(bref, c.get().max_cid, (uint16_t)1u, (uint16_t)16383u)); + } + HANDLE_CODE(bref.pack(c.get().profiles.profile0x0006, 1)); + break; + default: + log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE pdcp_cfg_s::drb_s_::hdr_compress_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::not_used: + break; + case types::rohc: + HANDLE_CODE(bref.unpack(c.get().max_cid_present, 1)); + HANDLE_CODE(bref.unpack(c.get().drb_continue_rohc_present, 1)); + if (c.get().max_cid_present) { + HANDLE_CODE(unpack_integer(c.get().max_cid, bref, (uint16_t)1u, (uint16_t)16383u)); + } + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0001, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0002, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0003, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0004, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0006, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0101, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0102, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0103, 1)); + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0104, 1)); + break; + case types::ul_only_rohc: + HANDLE_CODE(bref.unpack(c.get().max_cid_present, 1)); + HANDLE_CODE(bref.unpack(c.get().drb_continue_rohc_present, 1)); + if (c.get().max_cid_present) { + HANDLE_CODE(unpack_integer(c.get().max_cid, bref, (uint16_t)1u, (uint16_t)16383u)); + } + HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0006, 1)); + break; + default: + log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} -// PTRS-UplinkConfig ::= SEQUENCE -SRSASN_CODE ptrs_ul_cfg_s::pack(bit_ref& bref) const +std::string pdcp_cfg_s::drb_s_::hdr_compress_c_::types_opts::to_string() const +{ + static const char* options[] = {"notUsed", "rohc", "uplinkOnlyROHC"}; + return convert_enum_idx(options, 3, value, "pdcp_cfg_s::drb_s_::hdr_compress_c_::types"); +} + +std::string pdcp_cfg_s::t_reordering_opts::to_string() const +{ + static const char* options[] = { + "ms0", "ms1", "ms2", "ms4", "ms5", "ms8", "ms10", "ms15", "ms20", "ms30", + "ms40", "ms50", "ms60", "ms80", "ms100", "ms120", "ms140", "ms160", "ms180", "ms200", + "ms220", "ms240", "ms260", "ms280", "ms300", "ms500", "ms750", "ms1000", "ms1250", "ms1500", + "ms1750", "ms2000", "ms2250", "ms2500", "ms2750", "ms3000", "spare28", "spare27", "spare26", "spare25", + "spare24", "spare23", "spare22", "spare21", "spare20", "spare19", "spare18", "spare17", "spare16", "spare15", + "spare14", "spare13", "spare12", "spare11", "spare10", "spare09", "spare08", "spare07", "spare06", "spare05", + "spare04", "spare03", "spare02", "spare01"}; + return convert_enum_idx(options, 64, value, "pdcp_cfg_s::t_reordering_e_"); +} +uint16_t pdcp_cfg_s::t_reordering_opts::to_number() const +{ + static const uint16_t options[] = {0, 1, 2, 4, 5, 8, 10, 15, 20, 30, 40, 50, + 60, 80, 100, 120, 140, 160, 180, 200, 220, 240, 260, 280, + 300, 500, 750, 1000, 1250, 1500, 1750, 2000, 2250, 2500, 2750, 3000}; + return map_enum_number(options, 36, value, "pdcp_cfg_s::t_reordering_e_"); +} + +// SDAP-Config ::= SEQUENCE +SRSASN_CODE sdap_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(transform_precoder_disabled_present, 1)); - HANDLE_CODE(bref.pack(transform_precoder_enabled_present, 1)); + HANDLE_CODE(bref.pack(mapped_qos_flows_to_add_present, 1)); + HANDLE_CODE(bref.pack(mapped_qos_flows_to_release_present, 1)); - if (transform_precoder_disabled_present) { - HANDLE_CODE(bref.pack(transform_precoder_disabled.freq_density_present, 1)); - HANDLE_CODE(bref.pack(transform_precoder_disabled.time_density_present, 1)); - HANDLE_CODE(bref.pack(transform_precoder_disabled.res_elem_offset_present, 1)); - if (transform_precoder_disabled.freq_density_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(transform_precoder_disabled.freq_density)[0], - transform_precoder_disabled.freq_density.size(), - integer_packer(1, 276))); - } - if (transform_precoder_disabled.time_density_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(transform_precoder_disabled.time_density)[0], - transform_precoder_disabled.time_density.size(), - integer_packer(0, 29))); - } - HANDLE_CODE(transform_precoder_disabled.max_nrof_ports.pack(bref)); - if (transform_precoder_disabled.res_elem_offset_present) { - HANDLE_CODE(transform_precoder_disabled.res_elem_offset.pack(bref)); - } - HANDLE_CODE(transform_precoder_disabled.ptrs_pwr.pack(bref)); + HANDLE_CODE(pack_integer(bref, pdu_session, (uint16_t)0u, (uint16_t)255u)); + HANDLE_CODE(sdap_hdr_dl.pack(bref)); + HANDLE_CODE(sdap_hdr_ul.pack(bref)); + HANDLE_CODE(bref.pack(default_drb, 1)); + if (mapped_qos_flows_to_add_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, mapped_qos_flows_to_add, 1, 64, integer_packer(0, 63))); } - if (transform_precoder_enabled_present) { - HANDLE_CODE(bref.pack(transform_precoder_enabled.time_density_transform_precoding_present, 1)); - HANDLE_CODE(pack_fixed_seq_of(bref, - &(transform_precoder_enabled.sample_density)[0], - transform_precoder_enabled.sample_density.size(), - integer_packer(1, 276))); + if (mapped_qos_flows_to_release_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, mapped_qos_flows_to_release, 1, 64, integer_packer(0, 63))); } return SRSASN_SUCCESS; } -SRSASN_CODE ptrs_ul_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE sdap_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(transform_precoder_disabled_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoder_enabled_present, 1)); + HANDLE_CODE(bref.unpack(mapped_qos_flows_to_add_present, 1)); + HANDLE_CODE(bref.unpack(mapped_qos_flows_to_release_present, 1)); - if (transform_precoder_disabled_present) { - HANDLE_CODE(bref.unpack(transform_precoder_disabled.freq_density_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoder_disabled.time_density_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoder_disabled.res_elem_offset_present, 1)); - if (transform_precoder_disabled.freq_density_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(transform_precoder_disabled.freq_density)[0], - bref, - transform_precoder_disabled.freq_density.size(), - integer_packer(1, 276))); - } - if (transform_precoder_disabled.time_density_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(transform_precoder_disabled.time_density)[0], - bref, - transform_precoder_disabled.time_density.size(), - integer_packer(0, 29))); - } - HANDLE_CODE(transform_precoder_disabled.max_nrof_ports.unpack(bref)); - if (transform_precoder_disabled.res_elem_offset_present) { - HANDLE_CODE(transform_precoder_disabled.res_elem_offset.unpack(bref)); - } - HANDLE_CODE(transform_precoder_disabled.ptrs_pwr.unpack(bref)); + HANDLE_CODE(unpack_integer(pdu_session, bref, (uint16_t)0u, (uint16_t)255u)); + HANDLE_CODE(sdap_hdr_dl.unpack(bref)); + HANDLE_CODE(sdap_hdr_ul.unpack(bref)); + HANDLE_CODE(bref.unpack(default_drb, 1)); + if (mapped_qos_flows_to_add_present) { + HANDLE_CODE(unpack_dyn_seq_of(mapped_qos_flows_to_add, bref, 1, 64, integer_packer(0, 63))); } - if (transform_precoder_enabled_present) { - HANDLE_CODE(bref.unpack(transform_precoder_enabled.time_density_transform_precoding_present, 1)); - HANDLE_CODE(unpack_fixed_seq_of(&(transform_precoder_enabled.sample_density)[0], - bref, - transform_precoder_enabled.sample_density.size(), - integer_packer(1, 276))); + if (mapped_qos_flows_to_release_present) { + HANDLE_CODE(unpack_dyn_seq_of(mapped_qos_flows_to_release, bref, 1, 64, integer_packer(0, 63))); } return SRSASN_SUCCESS; } -void ptrs_ul_cfg_s::to_json(json_writer& j) const +void sdap_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (transform_precoder_disabled_present) { - j.write_fieldname("transformPrecoderDisabled"); - j.start_obj(); - if (transform_precoder_disabled.freq_density_present) { - j.start_array("frequencyDensity"); - for (const auto& e1 : transform_precoder_disabled.freq_density) { - j.write_int(e1); - } - j.end_array(); - } - if (transform_precoder_disabled.time_density_present) { - j.start_array("timeDensity"); - for (const auto& e1 : transform_precoder_disabled.time_density) { - j.write_int(e1); - } - j.end_array(); - } - j.write_str("maxNrofPorts", transform_precoder_disabled.max_nrof_ports.to_string()); - if (transform_precoder_disabled.res_elem_offset_present) { - j.write_str("resourceElementOffset", transform_precoder_disabled.res_elem_offset.to_string()); + j.write_int("pdu-Session", pdu_session); + j.write_str("sdap-HeaderDL", sdap_hdr_dl.to_string()); + j.write_str("sdap-HeaderUL", sdap_hdr_ul.to_string()); + j.write_bool("defaultDRB", default_drb); + if (mapped_qos_flows_to_add_present) { + j.start_array("mappedQoS-FlowsToAdd"); + for (const auto& e1 : mapped_qos_flows_to_add) { + j.write_int(e1); } - j.write_str("ptrs-Power", transform_precoder_disabled.ptrs_pwr.to_string()); - j.end_obj(); + j.end_array(); } - if (transform_precoder_enabled_present) { - j.write_fieldname("transformPrecoderEnabled"); - j.start_obj(); - j.start_array("sampleDensity"); - for (const auto& e1 : transform_precoder_enabled.sample_density) { + if (mapped_qos_flows_to_release_present) { + j.start_array("mappedQoS-FlowsToRelease"); + for (const auto& e1 : mapped_qos_flows_to_release) { j.write_int(e1); } j.end_array(); - if (transform_precoder_enabled.time_density_transform_precoding_present) { - j.write_str("timeDensityTransformPrecoding", "d2"); - } - j.end_obj(); } j.end_obj(); } -std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_opts::to_string() const -{ - static const char* options[] = {"n1", "n2"}; - return convert_enum_idx(options, 2, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_e_"); -} -uint8_t ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_opts::to_number() const -{ - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_e_"); -} - -std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_opts::to_string() const -{ - static const char* options[] = {"offset01", "offset10", "offset11"}; - return convert_enum_idx(options, 3, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_e_"); -} -float ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_opts::to_number() const -{ - static const float options[] = {0.1, 1.0, 1.1}; - return map_enum_number(options, 3, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_e_"); -} -std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_opts::to_number_string() const +std::string sdap_cfg_s::sdap_hdr_dl_opts::to_string() const { - static const char* options[] = {"0.1", "1.0", "1.1"}; - return convert_enum_idx(options, 3, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_e_"); + static const char* options[] = {"present", "absent"}; + return convert_enum_idx(options, 2, value, "sdap_cfg_s::sdap_hdr_dl_e_"); } -std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_opts::to_string() const -{ - static const char* options[] = {"p00", "p01", "p10", "p11"}; - return convert_enum_idx(options, 4, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_e_"); -} -float ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_opts::to_number() const -{ - static const float options[] = {0.0, 0.1, 1.0, 1.1}; - return map_enum_number(options, 4, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_e_"); -} -std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_opts::to_number_string() const +std::string sdap_cfg_s::sdap_hdr_ul_opts::to_string() const { - static const char* options[] = {"0.0", "0.1", "1.0", "1.1"}; - return convert_enum_idx(options, 4, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_e_"); + static const char* options[] = {"present", "absent"}; + return convert_enum_idx(options, 2, value, "sdap_cfg_s::sdap_hdr_ul_e_"); } -// PUCCH-MaxCodeRate ::= ENUMERATED -std::string pucch_max_code_rate_opts::to_string() const -{ - static const char* options[] = { - "zeroDot08", "zeroDot15", "zeroDot25", "zeroDot35", "zeroDot45", "zeroDot60", "zeroDot80"}; - return convert_enum_idx(options, 7, value, "pucch_max_code_rate_e"); -} -float pucch_max_code_rate_opts::to_number() const -{ - static const float options[] = {0.08, 0.15, 0.25, 0.35, 0.45, 0.6, 0.8}; - return map_enum_number(options, 7, value, "pucch_max_code_rate_e"); -} -std::string pucch_max_code_rate_opts::to_number_string() const +// DRB-ToAddMod ::= SEQUENCE +SRSASN_CODE drb_to_add_mod_s::pack(bit_ref& bref) const { - static const char* options[] = {"0.08", "0.15", "0.25", "0.35", "0.45", "0.60", "0.80"}; - return convert_enum_idx(options, 7, value, "pucch_max_code_rate_e"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(cn_assoc_present, 1)); + HANDLE_CODE(bref.pack(reestablish_pdcp_present, 1)); + HANDLE_CODE(bref.pack(recover_pdcp_present, 1)); + HANDLE_CODE(bref.pack(pdcp_cfg_present, 1)); -// PUCCH-PathlossReferenceRS ::= SEQUENCE -SRSASN_CODE pucch_pathloss_ref_rs_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, pucch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(ref_sig.pack(bref)); + if (cn_assoc_present) { + HANDLE_CODE(cn_assoc.pack(bref)); + } + HANDLE_CODE(pack_integer(bref, drb_id, (uint8_t)1u, (uint8_t)32u)); + if (pdcp_cfg_present) { + HANDLE_CODE(pdcp_cfg.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_pathloss_ref_rs_s::unpack(cbit_ref& bref) +SRSASN_CODE drb_to_add_mod_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(pucch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(ref_sig.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(cn_assoc_present, 1)); + HANDLE_CODE(bref.unpack(reestablish_pdcp_present, 1)); + HANDLE_CODE(bref.unpack(recover_pdcp_present, 1)); + HANDLE_CODE(bref.unpack(pdcp_cfg_present, 1)); + + if (cn_assoc_present) { + HANDLE_CODE(cn_assoc.unpack(bref)); + } + HANDLE_CODE(unpack_integer(drb_id, bref, (uint8_t)1u, (uint8_t)32u)); + if (pdcp_cfg_present) { + HANDLE_CODE(pdcp_cfg.unpack(bref)); + } return SRSASN_SUCCESS; } -void pucch_pathloss_ref_rs_s::to_json(json_writer& j) const +void drb_to_add_mod_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("pucch-PathlossReferenceRS-Id", pucch_pathloss_ref_rs_id); - j.write_fieldname("referenceSignal"); - ref_sig.to_json(j); + if (cn_assoc_present) { + j.write_fieldname("cnAssociation"); + cn_assoc.to_json(j); + } + j.write_int("drb-Identity", drb_id); + if (reestablish_pdcp_present) { + j.write_str("reestablishPDCP", "true"); + } + if (recover_pdcp_present) { + j.write_str("recoverPDCP", "true"); + } + if (pdcp_cfg_present) { + j.write_fieldname("pdcp-Config"); + pdcp_cfg.to_json(j); + } j.end_obj(); } -void pucch_pathloss_ref_rs_s::ref_sig_c_::destroy_() {} -void pucch_pathloss_ref_rs_s::ref_sig_c_::set(types::options e) +void drb_to_add_mod_s::cn_assoc_c_::destroy_() +{ + switch (type_) { + case types::sdap_cfg: + c.destroy(); + break; + default: + break; + } +} +void drb_to_add_mod_s::cn_assoc_c_::set(types::options e) { destroy_(); type_ = e; + switch (type_) { + case types::eps_bearer_id: + break; + case types::sdap_cfg: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); + } } -pucch_pathloss_ref_rs_s::ref_sig_c_::ref_sig_c_(const pucch_pathloss_ref_rs_s::ref_sig_c_& other) +drb_to_add_mod_s::cn_assoc_c_::cn_assoc_c_(const drb_to_add_mod_s::cn_assoc_c_& other) { type_ = other.type(); switch (type_) { - case types::ssb_idx: + case types::eps_bearer_id: c.init(other.c.get()); break; - case types::csi_rs_idx: - c.init(other.c.get()); + case types::sdap_cfg: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); } } -pucch_pathloss_ref_rs_s::ref_sig_c_& pucch_pathloss_ref_rs_s::ref_sig_c_:: - operator=(const pucch_pathloss_ref_rs_s::ref_sig_c_& other) +drb_to_add_mod_s::cn_assoc_c_& drb_to_add_mod_s::cn_assoc_c_::operator=(const drb_to_add_mod_s::cn_assoc_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb_idx: + case types::eps_bearer_id: c.set(other.c.get()); break; - case types::csi_rs_idx: - c.set(other.c.get()); + case types::sdap_cfg: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); } return *this; } -void pucch_pathloss_ref_rs_s::ref_sig_c_::to_json(json_writer& j) const +void drb_to_add_mod_s::cn_assoc_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb_idx: - j.write_int("ssb-Index", c.get()); + case types::eps_bearer_id: + j.write_int("eps-BearerIdentity", c.get()); break; - case types::csi_rs_idx: - j.write_int("csi-RS-Index", c.get()); + case types::sdap_cfg: + j.write_fieldname("sdap-Config"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); } j.end_obj(); } -SRSASN_CODE pucch_pathloss_ref_rs_s::ref_sig_c_::pack(bit_ref& bref) const +SRSASN_CODE drb_to_add_mod_s::cn_assoc_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + case types::eps_bearer_id: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); break; - case types::csi_rs_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + case types::sdap_cfg: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_pathloss_ref_rs_s::ref_sig_c_::unpack(cbit_ref& bref) +SRSASN_CODE drb_to_add_mod_s::cn_assoc_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); + case types::eps_bearer_id: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); break; - case types::csi_rs_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + case types::sdap_cfg: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string pucch_pathloss_ref_rs_s::ref_sig_c_::types_opts::to_string() const +std::string drb_to_add_mod_s::cn_assoc_c_::types_opts::to_string() const { - static const char* options[] = {"ssb-Index", "csi-RS-Index"}; - return convert_enum_idx(options, 2, value, "pucch_pathloss_ref_rs_s::ref_sig_c_::types"); + static const char* options[] = {"eps-BearerIdentity", "sdap-Config"}; + return convert_enum_idx(options, 2, value, "drb_to_add_mod_s::cn_assoc_c_::types"); } -// PUCCH-format0 ::= SEQUENCE -SRSASN_CODE pucch_format0_s::pack(bit_ref& bref) const +// SRB-ToAddMod ::= SEQUENCE +SRSASN_CODE srb_to_add_mod_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, init_cyclic_shift, (uint8_t)0u, (uint8_t)11u)); - HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)13u)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(reestablish_pdcp_present, 1)); + HANDLE_CODE(bref.pack(discard_on_pdcp_present, 1)); + HANDLE_CODE(bref.pack(pdcp_cfg_present, 1)); + + HANDLE_CODE(pack_integer(bref, srb_id, (uint8_t)1u, (uint8_t)3u)); + if (pdcp_cfg_present) { + HANDLE_CODE(pdcp_cfg.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_format0_s::unpack(cbit_ref& bref) +SRSASN_CODE srb_to_add_mod_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(init_cyclic_shift, bref, (uint8_t)0u, (uint8_t)11u)); - HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)13u)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(reestablish_pdcp_present, 1)); + HANDLE_CODE(bref.unpack(discard_on_pdcp_present, 1)); + HANDLE_CODE(bref.unpack(pdcp_cfg_present, 1)); + + HANDLE_CODE(unpack_integer(srb_id, bref, (uint8_t)1u, (uint8_t)3u)); + if (pdcp_cfg_present) { + HANDLE_CODE(pdcp_cfg.unpack(bref)); + } return SRSASN_SUCCESS; } -void pucch_format0_s::to_json(json_writer& j) const +void srb_to_add_mod_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("initialCyclicShift", init_cyclic_shift); - j.write_int("nrofSymbols", nrof_symbols); - j.write_int("startingSymbolIndex", start_symbol_idx); - j.end_obj(); + j.write_int("srb-Identity", srb_id); + if (reestablish_pdcp_present) { + j.write_str("reestablishPDCP", "true"); + } + if (discard_on_pdcp_present) { + j.write_str("discardOnPDCP", "true"); + } + if (pdcp_cfg_present) { + j.write_fieldname("pdcp-Config"); + pdcp_cfg.to_json(j); + } + j.end_obj(); } -// PUCCH-format1 ::= SEQUENCE -SRSASN_CODE pucch_format1_s::pack(bit_ref& bref) const +// SecurityAlgorithmConfig ::= SEQUENCE +SRSASN_CODE security_algorithm_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, init_cyclic_shift, (uint8_t)0u, (uint8_t)11u)); - HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)4u, (uint8_t)14u)); - HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)10u)); - HANDLE_CODE(pack_integer(bref, time_domain_occ, (uint8_t)0u, (uint8_t)6u)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(integrity_prot_algorithm_present, 1)); + + HANDLE_CODE(ciphering_algorithm.pack(bref)); + if (integrity_prot_algorithm_present) { + HANDLE_CODE(integrity_prot_algorithm.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_format1_s::unpack(cbit_ref& bref) +SRSASN_CODE security_algorithm_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(init_cyclic_shift, bref, (uint8_t)0u, (uint8_t)11u)); - HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)4u, (uint8_t)14u)); - HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)10u)); - HANDLE_CODE(unpack_integer(time_domain_occ, bref, (uint8_t)0u, (uint8_t)6u)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(integrity_prot_algorithm_present, 1)); + + HANDLE_CODE(ciphering_algorithm.unpack(bref)); + if (integrity_prot_algorithm_present) { + HANDLE_CODE(integrity_prot_algorithm.unpack(bref)); + } return SRSASN_SUCCESS; } -void pucch_format1_s::to_json(json_writer& j) const +void security_algorithm_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("initialCyclicShift", init_cyclic_shift); - j.write_int("nrofSymbols", nrof_symbols); - j.write_int("startingSymbolIndex", start_symbol_idx); - j.write_int("timeDomainOCC", time_domain_occ); + j.write_str("cipheringAlgorithm", ciphering_algorithm.to_string()); + if (integrity_prot_algorithm_present) { + j.write_str("integrityProtAlgorithm", integrity_prot_algorithm.to_string()); + } j.end_obj(); } -// PUCCH-format2 ::= SEQUENCE -SRSASN_CODE pucch_format2_s::pack(bit_ref& bref) const +// SecurityConfig ::= SEQUENCE +SRSASN_CODE security_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, nrof_prbs, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)13u)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(security_algorithm_cfg_present, 1)); + HANDLE_CODE(bref.pack(key_to_use_present, 1)); + + if (security_algorithm_cfg_present) { + HANDLE_CODE(security_algorithm_cfg.pack(bref)); + } + if (key_to_use_present) { + HANDLE_CODE(key_to_use.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_format2_s::unpack(cbit_ref& bref) +SRSASN_CODE security_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(nrof_prbs, bref, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)13u)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(security_algorithm_cfg_present, 1)); + HANDLE_CODE(bref.unpack(key_to_use_present, 1)); + + if (security_algorithm_cfg_present) { + HANDLE_CODE(security_algorithm_cfg.unpack(bref)); + } + if (key_to_use_present) { + HANDLE_CODE(key_to_use.unpack(bref)); + } return SRSASN_SUCCESS; } -void pucch_format2_s::to_json(json_writer& j) const +void security_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("nrofPRBs", nrof_prbs); - j.write_int("nrofSymbols", nrof_symbols); - j.write_int("startingSymbolIndex", start_symbol_idx); + if (security_algorithm_cfg_present) { + j.write_fieldname("securityAlgorithmConfig"); + security_algorithm_cfg.to_json(j); + } + if (key_to_use_present) { + j.write_str("keyToUse", key_to_use.to_string()); + } j.end_obj(); } -// PUCCH-format3 ::= SEQUENCE -SRSASN_CODE pucch_format3_s::pack(bit_ref& bref) const +std::string security_cfg_s::key_to_use_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, nrof_prbs, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)4u, (uint8_t)14u)); - HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)10u)); + static const char* options[] = {"master", "secondary"}; + return convert_enum_idx(options, 2, value, "security_cfg_s::key_to_use_e_"); +} + +// RadioBearerConfig ::= SEQUENCE +SRSASN_CODE radio_bearer_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(srb_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(srb3_to_release_present, 1)); + HANDLE_CODE(bref.pack(drb_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(drb_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(security_cfg_present, 1)); + + if (srb_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, srb_to_add_mod_list, 1, 2)); + } + if (drb_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, drb_to_add_mod_list, 1, 29)); + } + if (drb_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, drb_to_release_list, 1, 29, integer_packer(1, 32))); + } + if (security_cfg_present) { + HANDLE_CODE(security_cfg.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_format3_s::unpack(cbit_ref& bref) +SRSASN_CODE radio_bearer_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(nrof_prbs, bref, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)4u, (uint8_t)14u)); - HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)10u)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(srb_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(srb3_to_release_present, 1)); + HANDLE_CODE(bref.unpack(drb_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(drb_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(security_cfg_present, 1)); + + if (srb_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(srb_to_add_mod_list, bref, 1, 2)); + } + if (drb_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(drb_to_add_mod_list, bref, 1, 29)); + } + if (drb_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(drb_to_release_list, bref, 1, 29, integer_packer(1, 32))); + } + if (security_cfg_present) { + HANDLE_CODE(security_cfg.unpack(bref)); + } return SRSASN_SUCCESS; } -void pucch_format3_s::to_json(json_writer& j) const +void radio_bearer_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("nrofPRBs", nrof_prbs); - j.write_int("nrofSymbols", nrof_symbols); - j.write_int("startingSymbolIndex", start_symbol_idx); + if (srb_to_add_mod_list_present) { + j.start_array("srb-ToAddModList"); + for (const auto& e1 : srb_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (srb3_to_release_present) { + j.write_str("srb3-ToRelease", "true"); + } + if (drb_to_add_mod_list_present) { + j.start_array("drb-ToAddModList"); + for (const auto& e1 : drb_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (drb_to_release_list_present) { + j.start_array("drb-ToReleaseList"); + for (const auto& e1 : drb_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (security_cfg_present) { + j.write_fieldname("securityConfig"); + security_cfg.to_json(j); + } j.end_obj(); } -// PUCCH-format4 ::= SEQUENCE -SRSASN_CODE pucch_format4_s::pack(bit_ref& bref) const +// RRCReject-IEs ::= SEQUENCE +SRSASN_CODE rrc_reject_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)4u, (uint8_t)14u)); - HANDLE_CODE(occ_len.pack(bref)); - HANDLE_CODE(occ_idx.pack(bref)); - HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)10u)); + HANDLE_CODE(bref.pack(wait_time_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (wait_time_present) { + HANDLE_CODE(pack_integer(bref, wait_time, (uint8_t)1u, (uint8_t)16u)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_format4_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_reject_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)4u, (uint8_t)14u)); - HANDLE_CODE(occ_len.unpack(bref)); - HANDLE_CODE(occ_idx.unpack(bref)); - HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)10u)); + HANDLE_CODE(bref.unpack(wait_time_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (wait_time_present) { + HANDLE_CODE(unpack_integer(wait_time, bref, (uint8_t)1u, (uint8_t)16u)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } return SRSASN_SUCCESS; } -void pucch_format4_s::to_json(json_writer& j) const +void rrc_reject_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("nrofSymbols", nrof_symbols); - j.write_str("occ-Length", occ_len.to_string()); - j.write_str("occ-Index", occ_idx.to_string()); - j.write_int("startingSymbolIndex", start_symbol_idx); + if (wait_time_present) { + j.write_int("waitTime", wait_time); + } + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } j.end_obj(); } -std::string pucch_format4_s::occ_len_opts::to_string() const +// RRCSetup-IEs ::= SEQUENCE +SRSASN_CODE rrc_setup_ies_s::pack(bit_ref& bref) const { - static const char* options[] = {"n2", "n4"}; - return convert_enum_idx(options, 2, value, "pucch_format4_s::occ_len_e_"); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + HANDLE_CODE(radio_bearer_cfg.pack(bref)); + HANDLE_CODE(master_cell_group.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t pucch_format4_s::occ_len_opts::to_number() const +SRSASN_CODE rrc_setup_ies_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {2, 4}; - return map_enum_number(options, 2, value, "pucch_format4_s::occ_len_e_"); -} + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); -std::string pucch_format4_s::occ_idx_opts::to_string() const -{ - static const char* options[] = {"n0", "n1", "n2", "n3"}; - return convert_enum_idx(options, 4, value, "pucch_format4_s::occ_idx_e_"); + HANDLE_CODE(radio_bearer_cfg.unpack(bref)); + HANDLE_CODE(master_cell_group.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t pucch_format4_s::occ_idx_opts::to_number() const +void rrc_setup_ies_s::to_json(json_writer& j) const { - static const uint8_t options[] = {0, 1, 2, 3}; - return map_enum_number(options, 4, value, "pucch_format4_s::occ_idx_e_"); + j.start_obj(); + j.write_fieldname("radioBearerConfig"); + radio_bearer_cfg.to_json(j); + j.write_str("masterCellGroup", master_cell_group.to_string()); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); } -// PUSCH-PathlossReferenceRS ::= SEQUENCE -SRSASN_CODE pusch_pathloss_ref_rs_s::pack(bit_ref& bref) const +// RRCReject ::= SEQUENCE +SRSASN_CODE rrc_reject_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, pusch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(ref_sig.pack(bref)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE pusch_pathloss_ref_rs_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_reject_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(pusch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(ref_sig.unpack(bref)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void pusch_pathloss_ref_rs_s::to_json(json_writer& j) const +void rrc_reject_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("pusch-PathlossReferenceRS-Id", pusch_pathloss_ref_rs_id); - j.write_fieldname("referenceSignal"); - ref_sig.to_json(j); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -void pusch_pathloss_ref_rs_s::ref_sig_c_::destroy_() {} -void pusch_pathloss_ref_rs_s::ref_sig_c_::set(types::options e) +void rrc_reject_s::crit_exts_c_::destroy_() +{ + switch (type_) { + case types::rrc_reject: + c.destroy(); + break; + default: + break; + } +} +void rrc_reject_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; + switch (type_) { + case types::rrc_reject: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); + } } -pusch_pathloss_ref_rs_s::ref_sig_c_::ref_sig_c_(const pusch_pathloss_ref_rs_s::ref_sig_c_& other) +rrc_reject_s::crit_exts_c_::crit_exts_c_(const rrc_reject_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::ssb_idx: - c.init(other.c.get()); + case types::rrc_reject: + c.init(other.c.get()); break; - case types::csi_rs_idx: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); } } -pusch_pathloss_ref_rs_s::ref_sig_c_& pusch_pathloss_ref_rs_s::ref_sig_c_:: - operator=(const pusch_pathloss_ref_rs_s::ref_sig_c_& other) +rrc_reject_s::crit_exts_c_& rrc_reject_s::crit_exts_c_::operator=(const rrc_reject_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb_idx: - c.set(other.c.get()); + case types::rrc_reject: + c.set(other.c.get()); break; - case types::csi_rs_idx: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); } return *this; } -void pusch_pathloss_ref_rs_s::ref_sig_c_::to_json(json_writer& j) const +void rrc_reject_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb_idx: - j.write_int("ssb-Index", c.get()); + case types::rrc_reject: + j.write_fieldname("rrcReject"); + c.get().to_json(j); break; - case types::csi_rs_idx: - j.write_int("csi-RS-Index", c.get()); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE pusch_pathloss_ref_rs_s::ref_sig_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_reject_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + case types::rrc_reject: + HANDLE_CODE(c.get().pack(bref)); break; - case types::csi_rs_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE pusch_pathloss_ref_rs_s::ref_sig_c_::unpack(cbit_ref& bref) +SRSASN_CODE rrc_reject_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); + case types::rrc_reject: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::csi_rs_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); + log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string pusch_pathloss_ref_rs_s::ref_sig_c_::types_opts::to_string() const +std::string rrc_reject_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"ssb-Index", "csi-RS-Index"}; - return convert_enum_idx(options, 2, value, "pusch_pathloss_ref_rs_s::ref_sig_c_::types"); + static const char* options[] = {"rrcReject", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_reject_s::crit_exts_c_::types"); } -// SRI-PUSCH-PowerControl ::= SEQUENCE -SRSASN_CODE sri_pusch_pwr_ctrl_s::pack(bit_ref& bref) const +// RRCSetup ::= SEQUENCE +SRSASN_CODE rrc_setup_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, sri_pusch_pwr_ctrl_id, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(pack_integer(bref, sri_pusch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pack_integer(bref, sri_p0_pusch_alpha_set_id, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(sri_pusch_closed_loop_idx.pack(bref)); + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE sri_pusch_pwr_ctrl_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_setup_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(sri_pusch_pwr_ctrl_id, bref, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(unpack_integer(sri_pusch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(unpack_integer(sri_p0_pusch_alpha_set_id, bref, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(sri_pusch_closed_loop_idx.unpack(bref)); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void sri_pusch_pwr_ctrl_s::to_json(json_writer& j) const +void rrc_setup_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("sri-PUSCH-PowerControlId", sri_pusch_pwr_ctrl_id); - j.write_int("sri-PUSCH-PathlossReferenceRS-Id", sri_pusch_pathloss_ref_rs_id); - j.write_int("sri-P0-PUSCH-AlphaSetId", sri_p0_pusch_alpha_set_id); - j.write_str("sri-PUSCH-ClosedLoopIndex", sri_pusch_closed_loop_idx.to_string()); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -std::string sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_opts::to_string() const -{ - static const char* options[] = {"i0", "i1"}; - return convert_enum_idx(options, 2, value, "sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_e_"); -} -uint8_t sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_opts::to_number() const +void rrc_setup_s::crit_exts_c_::destroy_() { - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_e_"); + switch (type_) { + case types::rrc_setup: + c.destroy(); + break; + default: + break; + } } - -// SRS-PeriodicityAndOffset ::= CHOICE -void srs_periodicity_and_offset_c::destroy_() {} -void srs_periodicity_and_offset_c::set(types::options e) +void rrc_setup_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; -} -srs_periodicity_and_offset_c::srs_periodicity_and_offset_c(const srs_periodicity_and_offset_c& other) -{ - type_ = other.type(); switch (type_) { - case types::sl1: - break; - case types::sl2: - c.init(other.c.get()); - break; - case types::sl4: - c.init(other.c.get()); - break; - case types::sl5: - c.init(other.c.get()); - break; - case types::sl8: - c.init(other.c.get()); - break; - case types::sl10: - c.init(other.c.get()); - break; - case types::sl16: - c.init(other.c.get()); - break; - case types::sl20: - c.init(other.c.get()); - break; - case types::sl32: - c.init(other.c.get()); - break; - case types::sl40: - c.init(other.c.get()); - break; - case types::sl64: - c.init(other.c.get()); - break; - case types::sl80: - c.init(other.c.get()); - break; - case types::sl160: - c.init(other.c.get()); + case types::rrc_setup: + c.init(); break; - case types::sl320: - c.init(other.c.get()); + case types::crit_exts_future: break; - case types::sl640: - c.init(other.c.get()); + case types::nulltype: break; - case types::sl1280: - c.init(other.c.get()); + default: + log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); + } +} +rrc_setup_s::crit_exts_c_::crit_exts_c_(const rrc_setup_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::rrc_setup: + c.init(other.c.get()); break; - case types::sl2560: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); } } -srs_periodicity_and_offset_c& srs_periodicity_and_offset_c::operator=(const srs_periodicity_and_offset_c& other) +rrc_setup_s::crit_exts_c_& rrc_setup_s::crit_exts_c_::operator=(const rrc_setup_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::sl1: + case types::rrc_setup: + c.set(other.c.get()); break; - case types::sl2: - c.set(other.c.get()); - break; - case types::sl4: - c.set(other.c.get()); - break; - case types::sl5: - c.set(other.c.get()); - break; - case types::sl8: - c.set(other.c.get()); - break; - case types::sl10: - c.set(other.c.get()); - break; - case types::sl16: - c.set(other.c.get()); - break; - case types::sl20: - c.set(other.c.get()); - break; - case types::sl32: - c.set(other.c.get()); - break; - case types::sl40: - c.set(other.c.get()); - break; - case types::sl64: - c.set(other.c.get()); - break; - case types::sl80: - c.set(other.c.get()); - break; - case types::sl160: - c.set(other.c.get()); - break; - case types::sl320: - c.set(other.c.get()); - break; - case types::sl640: - c.set(other.c.get()); - break; - case types::sl1280: - c.set(other.c.get()); - break; - case types::sl2560: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); } return *this; } -void srs_periodicity_and_offset_c::to_json(json_writer& j) const +void rrc_setup_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::sl1: - break; - case types::sl2: - j.write_int("sl2", c.get()); - break; - case types::sl4: - j.write_int("sl4", c.get()); - break; - case types::sl5: - j.write_int("sl5", c.get()); - break; - case types::sl8: - j.write_int("sl8", c.get()); - break; - case types::sl10: - j.write_int("sl10", c.get()); - break; - case types::sl16: - j.write_int("sl16", c.get()); - break; - case types::sl20: - j.write_int("sl20", c.get()); - break; - case types::sl32: - j.write_int("sl32", c.get()); - break; - case types::sl40: - j.write_int("sl40", c.get()); - break; - case types::sl64: - j.write_int("sl64", c.get()); - break; - case types::sl80: - j.write_int("sl80", c.get()); - break; - case types::sl160: - j.write_int("sl160", c.get()); - break; - case types::sl320: - j.write_int("sl320", c.get()); - break; - case types::sl640: - j.write_int("sl640", c.get()); - break; - case types::sl1280: - j.write_int("sl1280", c.get()); + case types::rrc_setup: + j.write_fieldname("rrcSetup"); + c.get().to_json(j); break; - case types::sl2560: - j.write_int("sl2560", c.get()); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE srs_periodicity_and_offset_c::pack(bit_ref& bref) const +SRSASN_CODE rrc_setup_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::sl1: - break; - case types::sl2: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)1u)); - break; - case types::sl4: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); - break; - case types::sl5: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); - break; - case types::sl8: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); - break; - case types::sl10: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); - break; - case types::sl16: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); - break; - case types::sl20: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); - break; - case types::sl32: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); - break; - case types::sl40: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); - break; - case types::sl64: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); - break; - case types::sl80: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); - break; - case types::sl160: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); - break; - case types::sl320: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); - break; - case types::sl640: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); - break; - case types::sl1280: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)1279u)); + case types::rrc_setup: + HANDLE_CODE(c.get().pack(bref)); break; - case types::sl2560: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)2559u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE srs_periodicity_and_offset_c::unpack(cbit_ref& bref) +SRSASN_CODE rrc_setup_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::sl1: - break; - case types::sl2: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)1u)); - break; - case types::sl4: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); - break; - case types::sl5: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); - break; - case types::sl8: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); - break; - case types::sl10: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); - break; - case types::sl16: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); - break; - case types::sl20: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); - break; - case types::sl32: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); - break; - case types::sl40: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); - break; - case types::sl64: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); - break; - case types::sl80: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); - break; - case types::sl160: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); - break; - case types::sl320: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); - break; - case types::sl640: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); - break; - case types::sl1280: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)1279u)); + case types::rrc_setup: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::sl2560: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)2559u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string srs_periodicity_and_offset_c::types_opts::to_string() const -{ - static const char* options[] = {"sl1", - "sl2", - "sl4", - "sl5", - "sl8", - "sl10", - "sl16", - "sl20", - "sl32", - "sl40", - "sl64", - "sl80", - "sl160", - "sl320", - "sl640", - "sl1280", - "sl2560"}; - return convert_enum_idx(options, 17, value, "srs_periodicity_and_offset_c::types"); -} -uint16_t srs_periodicity_and_offset_c::types_opts::to_number() const -{ - static const uint16_t options[] = {1, 2, 4, 5, 8, 10, 16, 20, 32, 40, 64, 80, 160, 320, 640, 1280, 2560}; - return map_enum_number(options, 17, value, "srs_periodicity_and_offset_c::types"); -} - -// SRS-SpatialRelationInfo ::= SEQUENCE -SRSASN_CODE srs_spatial_relation_info_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(serving_cell_id_present, 1)); - - if (serving_cell_id_present) { - HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(ref_sig.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE srs_spatial_relation_info_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(serving_cell_id_present, 1)); - - if (serving_cell_id_present) { - HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(ref_sig.unpack(bref)); - - return SRSASN_SUCCESS; -} -void srs_spatial_relation_info_s::to_json(json_writer& j) const +std::string rrc_setup_s::crit_exts_c_::types_opts::to_string() const { - j.start_obj(); - if (serving_cell_id_present) { - j.write_int("servingCellId", serving_cell_id); - } - j.write_fieldname("referenceSignal"); - ref_sig.to_json(j); - j.end_obj(); + static const char* options[] = {"rrcSetup", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_setup_s::crit_exts_c_::types"); } -void srs_spatial_relation_info_s::ref_sig_c_::destroy_() +// DL-CCCH-MessageType ::= CHOICE +void dl_ccch_msg_type_c::destroy_() { switch (type_) { - case types::srs: - c.destroy(); + case types::c1: + c.destroy(); break; default: break; } } -void srs_spatial_relation_info_s::ref_sig_c_::set(types::options e) +void dl_ccch_msg_type_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ssb_idx: - break; - case types::csi_rs_idx: + case types::c1: + c.init(); break; - case types::srs: - c.init(); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); } } -srs_spatial_relation_info_s::ref_sig_c_::ref_sig_c_(const srs_spatial_relation_info_s::ref_sig_c_& other) +dl_ccch_msg_type_c::dl_ccch_msg_type_c(const dl_ccch_msg_type_c& other) { type_ = other.type(); switch (type_) { - case types::ssb_idx: - c.init(other.c.get()); - break; - case types::csi_rs_idx: - c.init(other.c.get()); + case types::c1: + c.init(other.c.get()); break; - case types::srs: - c.init(other.c.get()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); } } -srs_spatial_relation_info_s::ref_sig_c_& srs_spatial_relation_info_s::ref_sig_c_:: - operator=(const srs_spatial_relation_info_s::ref_sig_c_& other) +dl_ccch_msg_type_c& dl_ccch_msg_type_c::operator=(const dl_ccch_msg_type_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb_idx: - c.set(other.c.get()); - break; - case types::csi_rs_idx: - c.set(other.c.get()); + case types::c1: + c.set(other.c.get()); break; - case types::srs: - c.set(other.c.get()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); } return *this; } -void srs_spatial_relation_info_s::ref_sig_c_::to_json(json_writer& j) const +void dl_ccch_msg_type_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb_idx: - j.write_int("ssb-Index", c.get()); - break; - case types::csi_rs_idx: - j.write_int("csi-RS-Index", c.get()); + case types::c1: + j.write_fieldname("c1"); + c.get().to_json(j); break; - case types::srs: - j.write_fieldname("srs"); - j.start_obj(); - j.write_int("resourceId", c.get().res_id); - j.write_int("uplinkBWP", c.get().ul_bwp); - j.end_obj(); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); } j.end_obj(); } -SRSASN_CODE srs_spatial_relation_info_s::ref_sig_c_::pack(bit_ref& bref) const +SRSASN_CODE dl_ccch_msg_type_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); - break; - case types::csi_rs_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + case types::c1: + HANDLE_CODE(c.get().pack(bref)); break; - case types::srs: - HANDLE_CODE(pack_integer(bref, c.get().res_id, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_integer(bref, c.get().ul_bwp, (uint8_t)0u, (uint8_t)4u)); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE srs_spatial_relation_info_s::ref_sig_c_::unpack(cbit_ref& bref) +SRSASN_CODE dl_ccch_msg_type_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); - break; - case types::csi_rs_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + case types::c1: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::srs: - HANDLE_CODE(unpack_integer(c.get().res_id, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_integer(c.get().ul_bwp, bref, (uint8_t)0u, (uint8_t)4u)); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string srs_spatial_relation_info_s::ref_sig_c_::types_opts::to_string() const -{ - static const char* options[] = {"ssb-Index", "csi-RS-Index", "srs"}; - return convert_enum_idx(options, 3, value, "srs_spatial_relation_info_s::ref_sig_c_::types"); -} - -// CG-UCI-OnPUSCH ::= CHOICE -void cg_uci_on_pusch_c::destroy_() +void dl_ccch_msg_type_c::c1_c_::destroy_() { switch (type_) { - case types::dynamic_type: - c.destroy(); + case types::rrc_reject: + c.destroy(); break; - case types::semi_static: - c.destroy(); + case types::rrc_setup: + c.destroy(); break; default: break; } } -void cg_uci_on_pusch_c::set(types::options e) +void dl_ccch_msg_type_c::c1_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::dynamic_type: - c.init(); + case types::rrc_reject: + c.init(); break; - case types::semi_static: - c.init(); + case types::rrc_setup: + c.init(); + break; + case types::spare2: + break; + case types::spare1: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); } } -cg_uci_on_pusch_c::cg_uci_on_pusch_c(const cg_uci_on_pusch_c& other) +dl_ccch_msg_type_c::c1_c_::c1_c_(const dl_ccch_msg_type_c::c1_c_& other) { type_ = other.type(); switch (type_) { - case types::dynamic_type: - c.init(other.c.get()); + case types::rrc_reject: + c.init(other.c.get()); break; - case types::semi_static: - c.init(other.c.get()); + case types::rrc_setup: + c.init(other.c.get()); + break; + case types::spare2: + break; + case types::spare1: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); } } -cg_uci_on_pusch_c& cg_uci_on_pusch_c::operator=(const cg_uci_on_pusch_c& other) +dl_ccch_msg_type_c::c1_c_& dl_ccch_msg_type_c::c1_c_::operator=(const dl_ccch_msg_type_c::c1_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::dynamic_type: - c.set(other.c.get()); + case types::rrc_reject: + c.set(other.c.get()); break; - case types::semi_static: - c.set(other.c.get()); + case types::rrc_setup: + c.set(other.c.get()); + break; + case types::spare2: + break; + case types::spare1: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); } return *this; } -void cg_uci_on_pusch_c::to_json(json_writer& j) const +void dl_ccch_msg_type_c::c1_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::dynamic_type: - j.start_array("dynamic"); - for (const auto& e1 : c.get()) { - e1.to_json(j); - } - j.end_array(); + case types::rrc_reject: + j.write_fieldname("rrcReject"); + c.get().to_json(j); break; - case types::semi_static: - j.write_fieldname("semiStatic"); - c.get().to_json(j); + case types::rrc_setup: + j.write_fieldname("rrcSetup"); + c.get().to_json(j); + break; + case types::spare2: + break; + case types::spare1: break; default: - log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); } j.end_obj(); } -SRSASN_CODE cg_uci_on_pusch_c::pack(bit_ref& bref) const +SRSASN_CODE dl_ccch_msg_type_c::c1_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::dynamic_type: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 4)); + case types::rrc_reject: + HANDLE_CODE(c.get().pack(bref)); break; - case types::semi_static: - HANDLE_CODE(c.get().pack(bref)); + case types::rrc_setup: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::spare2: + break; + case types::spare1: break; default: - log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE cg_uci_on_pusch_c::unpack(cbit_ref& bref) +SRSASN_CODE dl_ccch_msg_type_c::c1_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::dynamic_type: - HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 4)); + case types::rrc_reject: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::semi_static: - HANDLE_CODE(c.get().unpack(bref)); + case types::rrc_setup: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::spare2: + break; + case types::spare1: break; default: - log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string cg_uci_on_pusch_c::types_opts::to_string() const +std::string dl_ccch_msg_type_c::c1_c_::types_opts::to_string() const { - static const char* options[] = {"dynamic", "semiStatic"}; - return convert_enum_idx(options, 2, value, "cg_uci_on_pusch_c::types"); + static const char* options[] = {"rrcReject", "rrcSetup", "spare2", "spare1"}; + return convert_enum_idx(options, 4, value, "dl_ccch_msg_type_c::c1_c_::types"); } -// CSI-RS-ResourceMapping ::= SEQUENCE -SRSASN_CODE csi_rs_res_map_s::pack(bit_ref& bref) const +std::string dl_ccch_msg_type_c::types_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(first_ofdm_symbol_in_time_domain2_present, 1)); - - HANDLE_CODE(freq_domain_alloc.pack(bref)); - HANDLE_CODE(nrof_ports.pack(bref)); - HANDLE_CODE(pack_integer(bref, first_ofdm_symbol_in_time_domain, (uint8_t)0u, (uint8_t)13u)); - if (first_ofdm_symbol_in_time_domain2_present) { - HANDLE_CODE(pack_integer(bref, first_ofdm_symbol_in_time_domain2, (uint8_t)2u, (uint8_t)12u)); - } - HANDLE_CODE(cdm_type.pack(bref)); - HANDLE_CODE(density.pack(bref)); - HANDLE_CODE(freq_band.pack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"c1", "messageClassExtension"}; + return convert_enum_idx(options, 2, value, "dl_ccch_msg_type_c::types"); } -SRSASN_CODE csi_rs_res_map_s::unpack(cbit_ref& bref) +uint8_t dl_ccch_msg_type_c::types_opts::to_number() const +{ + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "dl_ccch_msg_type_c::types"); +} + +// DL-CCCH-Message ::= SEQUENCE +SRSASN_CODE dl_ccch_msg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(msg.pack(bref)); + + bref.align_bytes_zero(); + + return SRSASN_SUCCESS; +} +SRSASN_CODE dl_ccch_msg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(msg.unpack(bref)); + + bref.align_bytes(); + + return SRSASN_SUCCESS; +} +void dl_ccch_msg_s::to_json(json_writer& j) const +{ + j.start_array(); + j.start_obj(); + j.start_obj("DL-CCCH-Message"); + j.write_fieldname("message"); + msg.to_json(j); + j.end_obj(); + j.end_obj(); + j.end_array(); +} + +// CSI-RS-Resource-Mobility ::= SEQUENCE +SRSASN_CODE csi_rs_res_mob_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(associated_ssb_present, 1)); + + HANDLE_CODE(pack_integer(bref, csi_rs_idx, (uint8_t)0u, (uint8_t)95u)); + HANDLE_CODE(slot_cfg.pack(bref)); + if (associated_ssb_present) { + HANDLE_CODE(pack_integer(bref, associated_ssb.ssb_idx, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(bref.pack(associated_ssb.is_quasi_colocated, 1)); + } + HANDLE_CODE(freq_domain_alloc.pack(bref)); + HANDLE_CODE(pack_integer(bref, first_ofdm_symbol_in_time_domain, (uint8_t)0u, (uint8_t)13u)); + HANDLE_CODE(pack_integer(bref, seq_generation_cfg, (uint16_t)0u, (uint16_t)1023u)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_rs_res_mob_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(first_ofdm_symbol_in_time_domain2_present, 1)); + HANDLE_CODE(bref.unpack(associated_ssb_present, 1)); + HANDLE_CODE(unpack_integer(csi_rs_idx, bref, (uint8_t)0u, (uint8_t)95u)); + HANDLE_CODE(slot_cfg.unpack(bref)); + if (associated_ssb_present) { + HANDLE_CODE(unpack_integer(associated_ssb.ssb_idx, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(bref.unpack(associated_ssb.is_quasi_colocated, 1)); + } HANDLE_CODE(freq_domain_alloc.unpack(bref)); - HANDLE_CODE(nrof_ports.unpack(bref)); HANDLE_CODE(unpack_integer(first_ofdm_symbol_in_time_domain, bref, (uint8_t)0u, (uint8_t)13u)); - if (first_ofdm_symbol_in_time_domain2_present) { - HANDLE_CODE(unpack_integer(first_ofdm_symbol_in_time_domain2, bref, (uint8_t)2u, (uint8_t)12u)); - } - HANDLE_CODE(cdm_type.unpack(bref)); - HANDLE_CODE(density.unpack(bref)); - HANDLE_CODE(freq_band.unpack(bref)); + HANDLE_CODE(unpack_integer(seq_generation_cfg, bref, (uint16_t)0u, (uint16_t)1023u)); return SRSASN_SUCCESS; } -void csi_rs_res_map_s::to_json(json_writer& j) const +void csi_rs_res_mob_s::to_json(json_writer& j) const { j.start_obj(); + j.write_int("csi-RS-Index", csi_rs_idx); + j.write_fieldname("slotConfig"); + slot_cfg.to_json(j); + if (associated_ssb_present) { + j.write_fieldname("associatedSSB"); + j.start_obj(); + j.write_int("ssb-Index", associated_ssb.ssb_idx); + j.write_bool("isQuasiColocated", associated_ssb.is_quasi_colocated); + j.end_obj(); + } j.write_fieldname("frequencyDomainAllocation"); freq_domain_alloc.to_json(j); - j.write_str("nrofPorts", nrof_ports.to_string()); j.write_int("firstOFDMSymbolInTimeDomain", first_ofdm_symbol_in_time_domain); - if (first_ofdm_symbol_in_time_domain2_present) { - j.write_int("firstOFDMSymbolInTimeDomain2", first_ofdm_symbol_in_time_domain2); + j.write_int("sequenceGenerationConfig", seq_generation_cfg); + j.end_obj(); +} + +void csi_rs_res_mob_s::slot_cfg_c_::destroy_() {} +void csi_rs_res_mob_s::slot_cfg_c_::set(types::options e) +{ + destroy_(); + type_ = e; +} +csi_rs_res_mob_s::slot_cfg_c_::slot_cfg_c_(const csi_rs_res_mob_s::slot_cfg_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::ms4: + c.init(other.c.get()); + break; + case types::ms5: + c.init(other.c.get()); + break; + case types::ms10: + c.init(other.c.get()); + break; + case types::ms20: + c.init(other.c.get()); + break; + case types::ms40: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); + } +} +csi_rs_res_mob_s::slot_cfg_c_& csi_rs_res_mob_s::slot_cfg_c_::operator=(const csi_rs_res_mob_s::slot_cfg_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::ms4: + c.set(other.c.get()); + break; + case types::ms5: + c.set(other.c.get()); + break; + case types::ms10: + c.set(other.c.get()); + break; + case types::ms20: + c.set(other.c.get()); + break; + case types::ms40: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); + } + + return *this; +} +void csi_rs_res_mob_s::slot_cfg_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::ms4: + j.write_int("ms4", c.get()); + break; + case types::ms5: + j.write_int("ms5", c.get()); + break; + case types::ms10: + j.write_int("ms10", c.get()); + break; + case types::ms20: + j.write_int("ms20", c.get()); + break; + case types::ms40: + j.write_int("ms40", c.get()); + break; + default: + log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); } - j.write_str("cdm-Type", cdm_type.to_string()); - j.write_fieldname("density"); - density.to_json(j); - j.write_fieldname("freqBand"); - freq_band.to_json(j); j.end_obj(); } +SRSASN_CODE csi_rs_res_mob_s::slot_cfg_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::ms4: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); + break; + case types::ms5: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); + break; + case types::ms10: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); + break; + case types::ms20: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + break; + case types::ms40: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + break; + default: + log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_rs_res_mob_s::slot_cfg_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ms4: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); + break; + case types::ms5: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); + break; + case types::ms10: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); + break; + case types::ms20: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + break; + case types::ms40: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + break; + default: + log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} -void csi_rs_res_map_s::freq_domain_alloc_c_::destroy_() +std::string csi_rs_res_mob_s::slot_cfg_c_::types_opts::to_string() const +{ + static const char* options[] = {"ms4", "ms5", "ms10", "ms20", "ms40"}; + return convert_enum_idx(options, 5, value, "csi_rs_res_mob_s::slot_cfg_c_::types"); +} +uint8_t csi_rs_res_mob_s::slot_cfg_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {4, 5, 10, 20, 40}; + return map_enum_number(options, 5, value, "csi_rs_res_mob_s::slot_cfg_c_::types"); +} + +void csi_rs_res_mob_s::freq_domain_alloc_c_::destroy_() { switch (type_) { case types::row1: @@ -9764,17 +9988,11 @@ void csi_rs_res_map_s::freq_domain_alloc_c_::destroy_() case types::row2: c.destroy >(); break; - case types::row4: - c.destroy >(); - break; - case types::other: - c.destroy >(); - break; default: break; } } -void csi_rs_res_map_s::freq_domain_alloc_c_::set(types::options e) +void csi_rs_res_mob_s::freq_domain_alloc_c_::set(types::options e) { destroy_(); type_ = e; @@ -9785,19 +10003,13 @@ void csi_rs_res_map_s::freq_domain_alloc_c_::set(types::options e) case types::row2: c.init >(); break; - case types::row4: - c.init >(); - break; - case types::other: - c.init >(); - break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); } } -csi_rs_res_map_s::freq_domain_alloc_c_::freq_domain_alloc_c_(const csi_rs_res_map_s::freq_domain_alloc_c_& other) +csi_rs_res_mob_s::freq_domain_alloc_c_::freq_domain_alloc_c_(const csi_rs_res_mob_s::freq_domain_alloc_c_& other) { type_ = other.type(); switch (type_) { @@ -9807,20 +10019,14 @@ csi_rs_res_map_s::freq_domain_alloc_c_::freq_domain_alloc_c_(const csi_rs_res_ma case types::row2: c.init(other.c.get >()); break; - case types::row4: - c.init(other.c.get >()); - break; - case types::other: - c.init(other.c.get >()); - break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); } } -csi_rs_res_map_s::freq_domain_alloc_c_& csi_rs_res_map_s::freq_domain_alloc_c_:: - operator=(const csi_rs_res_map_s::freq_domain_alloc_c_& other) +csi_rs_res_mob_s::freq_domain_alloc_c_& +csi_rs_res_mob_s::freq_domain_alloc_c_::operator=(const csi_rs_res_mob_s::freq_domain_alloc_c_& other) { if (this == &other) { return *this; @@ -9833,21 +10039,15 @@ csi_rs_res_map_s::freq_domain_alloc_c_& csi_rs_res_map_s::freq_domain_alloc_c_:: case types::row2: c.set(other.c.get >()); break; - case types::row4: - c.set(other.c.get >()); - break; - case types::other: - c.set(other.c.get >()); - break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); } return *this; } -void csi_rs_res_map_s::freq_domain_alloc_c_::to_json(json_writer& j) const +void csi_rs_res_mob_s::freq_domain_alloc_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { @@ -9857,18 +10057,12 @@ void csi_rs_res_map_s::freq_domain_alloc_c_::to_json(json_writer& j) const case types::row2: j.write_str("row2", c.get >().to_string()); break; - case types::row4: - j.write_str("row4", c.get >().to_string()); - break; - case types::other: - j.write_str("other", c.get >().to_string()); - break; default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); } j.end_obj(); } -SRSASN_CODE csi_rs_res_map_s::freq_domain_alloc_c_::pack(bit_ref& bref) const +SRSASN_CODE csi_rs_res_mob_s::freq_domain_alloc_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { @@ -9878,19 +10072,13 @@ SRSASN_CODE csi_rs_res_map_s::freq_domain_alloc_c_::pack(bit_ref& bref) const case types::row2: HANDLE_CODE(c.get >().pack(bref)); break; - case types::row4: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::other: - HANDLE_CODE(c.get >().pack(bref)); - break; default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_rs_res_map_s::freq_domain_alloc_c_::unpack(cbit_ref& bref) +SRSASN_CODE csi_rs_res_mob_s::freq_domain_alloc_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); @@ -9902,2543 +10090,2305 @@ SRSASN_CODE csi_rs_res_map_s::freq_domain_alloc_c_::unpack(cbit_ref& bref) case types::row2: HANDLE_CODE(c.get >().unpack(bref)); break; - case types::row4: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::other: - HANDLE_CODE(c.get >().unpack(bref)); - break; default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_rs_res_map_s::freq_domain_alloc_c_::types_opts::to_string() const +std::string csi_rs_res_mob_s::freq_domain_alloc_c_::types_opts::to_string() const { - static const char* options[] = {"row1", "row2", "row4", "other"}; - return convert_enum_idx(options, 4, value, "csi_rs_res_map_s::freq_domain_alloc_c_::types"); + static const char* options[] = {"row1", "row2"}; + return convert_enum_idx(options, 2, value, "csi_rs_res_mob_s::freq_domain_alloc_c_::types"); } -uint8_t csi_rs_res_map_s::freq_domain_alloc_c_::types_opts::to_number() const +uint8_t csi_rs_res_mob_s::freq_domain_alloc_c_::types_opts::to_number() const { - static const uint8_t options[] = {1, 2, 4}; - return map_enum_number(options, 3, value, "csi_rs_res_map_s::freq_domain_alloc_c_::types"); + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "csi_rs_res_mob_s::freq_domain_alloc_c_::types"); } -std::string csi_rs_res_map_s::nrof_ports_opts::to_string() const -{ - static const char* options[] = {"p1", "p2", "p4", "p8", "p12", "p16", "p24", "p32"}; - return convert_enum_idx(options, 8, value, "csi_rs_res_map_s::nrof_ports_e_"); -} -uint8_t csi_rs_res_map_s::nrof_ports_opts::to_number() const +// CSI-RS-CellMobility ::= SEQUENCE +SRSASN_CODE csi_rs_cell_mob_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {1, 2, 4, 8, 12, 16, 24, 32}; - return map_enum_number(options, 8, value, "csi_rs_res_map_s::nrof_ports_e_"); -} + HANDLE_CODE(bref.pack(density_present, 1)); -std::string csi_rs_res_map_s::cdm_type_opts::to_string() const -{ - static const char* options[] = {"noCDM", "fd-CDM2", "cdm4-FD2-TD2", "cdm8-FD2-TD4"}; - return convert_enum_idx(options, 4, value, "csi_rs_res_map_s::cdm_type_e_"); + HANDLE_CODE(pack_integer(bref, cell_id, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(csi_rs_meas_bw.nrof_prbs.pack(bref)); + HANDLE_CODE(pack_integer(bref, csi_rs_meas_bw.start_prb, (uint16_t)0u, (uint16_t)2169u)); + if (density_present) { + HANDLE_CODE(density.pack(bref)); + } + HANDLE_CODE(pack_dyn_seq_of(bref, csi_rs_res_list_mob, 1, 96)); + + return SRSASN_SUCCESS; } -uint8_t csi_rs_res_map_s::cdm_type_opts::to_number() const +SRSASN_CODE csi_rs_cell_mob_s::unpack(cbit_ref& bref) { - switch (value) { - case fd_cdm2: - return 2; - case cdm4_fd2_td2: - return 4; - case cdm8_fd2_td4: - return 8; - default: - invalid_enum_number(value, "csi_rs_res_map_s::cdm_type_e_"); + HANDLE_CODE(bref.unpack(density_present, 1)); + + HANDLE_CODE(unpack_integer(cell_id, bref, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(csi_rs_meas_bw.nrof_prbs.unpack(bref)); + HANDLE_CODE(unpack_integer(csi_rs_meas_bw.start_prb, bref, (uint16_t)0u, (uint16_t)2169u)); + if (density_present) { + HANDLE_CODE(density.unpack(bref)); } - return 0; -} + HANDLE_CODE(unpack_dyn_seq_of(csi_rs_res_list_mob, bref, 1, 96)); -void csi_rs_res_map_s::density_c_::set(types::options e) -{ - type_ = e; + return SRSASN_SUCCESS; } -void csi_rs_res_map_s::density_c_::to_json(json_writer& j) const +void csi_rs_cell_mob_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::dot5: - j.write_str("dot5", c.to_string()); - break; - case types::one: - break; - case types::three: - break; - case types::spare: - break; - default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::density_c_"); - } + j.write_int("cellId", cell_id); + j.write_fieldname("csi-rs-MeasurementBW"); + j.start_obj(); + j.write_str("nrofPRBs", csi_rs_meas_bw.nrof_prbs.to_string()); + j.write_int("startPRB", csi_rs_meas_bw.start_prb); j.end_obj(); -} -SRSASN_CODE csi_rs_res_map_s::density_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::dot5: - HANDLE_CODE(c.pack(bref)); - break; - case types::one: - break; - case types::three: - break; - case types::spare: - break; - default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::density_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + if (density_present) { + j.write_str("density", density.to_string()); } - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_rs_res_map_s::density_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::dot5: - HANDLE_CODE(c.unpack(bref)); - break; - case types::one: - break; - case types::three: - break; - case types::spare: - break; - default: - log_invalid_choice_id(type_, "csi_rs_res_map_s::density_c_"); - return SRSASN_ERROR_DECODE_FAIL; + j.start_array("csi-rs-ResourceList-Mobility"); + for (const auto& e1 : csi_rs_res_list_mob) { + e1.to_json(j); } - return SRSASN_SUCCESS; + j.end_array(); + j.end_obj(); } -std::string csi_rs_res_map_s::density_c_::dot5_opts::to_string() const +std::string csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_opts::to_string() const { - static const char* options[] = {"evenPRBs", "oddPRBs"}; - return convert_enum_idx(options, 2, value, "csi_rs_res_map_s::density_c_::dot5_e_"); + static const char* options[] = {"size24", "size48", "size96", "size192", "size264"}; + return convert_enum_idx(options, 5, value, "csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_e_"); +} +uint16_t csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_opts::to_number() const +{ + static const uint16_t options[] = {24, 48, 96, 192, 264}; + return map_enum_number(options, 5, value, "csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_e_"); } -std::string csi_rs_res_map_s::density_c_::types_opts::to_string() const +std::string csi_rs_cell_mob_s::density_opts::to_string() const { - static const char* options[] = {"dot5", "one", "three", "spare"}; - return convert_enum_idx(options, 4, value, "csi_rs_res_map_s::density_c_::types"); + static const char* options[] = {"d1", "d3"}; + return convert_enum_idx(options, 2, value, "csi_rs_cell_mob_s::density_e_"); } -uint8_t csi_rs_res_map_s::density_c_::types_opts::to_number() const +uint8_t csi_rs_cell_mob_s::density_opts::to_number() const { - static const uint8_t options[] = {5, 1, 3}; - return map_enum_number(options, 3, value, "csi_rs_res_map_s::density_c_::types"); + static const uint8_t options[] = {1, 3}; + return map_enum_number(options, 2, value, "csi_rs_cell_mob_s::density_e_"); } -// CSI-ResourcePeriodicityAndOffset ::= CHOICE -void csi_res_periodicity_and_offset_c::destroy_() {} -void csi_res_periodicity_and_offset_c::set(types::options e) +// Q-OffsetRangeList ::= SEQUENCE +SRSASN_CODE q_offset_range_list_s::pack(bit_ref& bref) const { - destroy_(); - type_ = e; + HANDLE_CODE(bref.pack(rsrp_offset_ssb_present, 1)); + HANDLE_CODE(bref.pack(rsrq_offset_ssb_present, 1)); + HANDLE_CODE(bref.pack(sinr_offset_ssb_present, 1)); + HANDLE_CODE(bref.pack(rsrp_offset_csi_rs_present, 1)); + HANDLE_CODE(bref.pack(rsrq_offset_csi_rs_present, 1)); + HANDLE_CODE(bref.pack(sinr_offset_csi_rs_present, 1)); + + if (rsrp_offset_ssb_present) { + HANDLE_CODE(rsrp_offset_ssb.pack(bref)); + } + if (rsrq_offset_ssb_present) { + HANDLE_CODE(rsrq_offset_ssb.pack(bref)); + } + if (sinr_offset_ssb_present) { + HANDLE_CODE(sinr_offset_ssb.pack(bref)); + } + if (rsrp_offset_csi_rs_present) { + HANDLE_CODE(rsrp_offset_csi_rs.pack(bref)); + } + if (rsrq_offset_csi_rs_present) { + HANDLE_CODE(rsrq_offset_csi_rs.pack(bref)); + } + if (sinr_offset_csi_rs_present) { + HANDLE_CODE(sinr_offset_csi_rs.pack(bref)); + } + + return SRSASN_SUCCESS; } -csi_res_periodicity_and_offset_c::csi_res_periodicity_and_offset_c(const csi_res_periodicity_and_offset_c& other) +SRSASN_CODE q_offset_range_list_s::unpack(cbit_ref& bref) { - type_ = other.type(); - switch (type_) { - case types::slots4: - c.init(other.c.get()); - break; - case types::slots5: - c.init(other.c.get()); - break; - case types::slots8: - c.init(other.c.get()); - break; - case types::slots10: - c.init(other.c.get()); - break; - case types::slots16: - c.init(other.c.get()); - break; - case types::slots20: - c.init(other.c.get()); - break; - case types::slots32: - c.init(other.c.get()); - break; - case types::slots40: - c.init(other.c.get()); - break; - case types::slots64: + HANDLE_CODE(bref.unpack(rsrp_offset_ssb_present, 1)); + HANDLE_CODE(bref.unpack(rsrq_offset_ssb_present, 1)); + HANDLE_CODE(bref.unpack(sinr_offset_ssb_present, 1)); + HANDLE_CODE(bref.unpack(rsrp_offset_csi_rs_present, 1)); + HANDLE_CODE(bref.unpack(rsrq_offset_csi_rs_present, 1)); + HANDLE_CODE(bref.unpack(sinr_offset_csi_rs_present, 1)); + + if (rsrp_offset_ssb_present) { + HANDLE_CODE(rsrp_offset_ssb.unpack(bref)); + } + if (rsrq_offset_ssb_present) { + HANDLE_CODE(rsrq_offset_ssb.unpack(bref)); + } + if (sinr_offset_ssb_present) { + HANDLE_CODE(sinr_offset_ssb.unpack(bref)); + } + if (rsrp_offset_csi_rs_present) { + HANDLE_CODE(rsrp_offset_csi_rs.unpack(bref)); + } + if (rsrq_offset_csi_rs_present) { + HANDLE_CODE(rsrq_offset_csi_rs.unpack(bref)); + } + if (sinr_offset_csi_rs_present) { + HANDLE_CODE(sinr_offset_csi_rs.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void q_offset_range_list_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (rsrp_offset_ssb_present) { + j.write_str("rsrpOffsetSSB", rsrp_offset_ssb.to_string()); + } + if (rsrq_offset_ssb_present) { + j.write_str("rsrqOffsetSSB", rsrq_offset_ssb.to_string()); + } + if (sinr_offset_ssb_present) { + j.write_str("sinrOffsetSSB", sinr_offset_ssb.to_string()); + } + if (rsrp_offset_csi_rs_present) { + j.write_str("rsrpOffsetCSI-RS", rsrp_offset_csi_rs.to_string()); + } + if (rsrq_offset_csi_rs_present) { + j.write_str("rsrqOffsetCSI-RS", rsrq_offset_csi_rs.to_string()); + } + if (sinr_offset_csi_rs_present) { + j.write_str("sinrOffsetCSI-RS", sinr_offset_csi_rs.to_string()); + } + j.end_obj(); +} + +// CSI-RS-ResourceConfigMobility ::= SEQUENCE +SRSASN_CODE csi_rs_res_cfg_mob_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(subcarrier_spacing.pack(bref)); + HANDLE_CODE(pack_dyn_seq_of(bref, csi_rs_cell_list_mob, 1, 96)); + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= ref_serv_cell_idx_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(ref_serv_cell_idx_present, 1)); + if (ref_serv_cell_idx_present) { + HANDLE_CODE(pack_integer(bref, ref_serv_cell_idx, (uint8_t)0u, (uint8_t)31u)); + } + } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_rs_res_cfg_mob_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(subcarrier_spacing.unpack(bref)); + HANDLE_CODE(unpack_dyn_seq_of(csi_rs_cell_list_mob, bref, 1, 96)); + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(ref_serv_cell_idx_present, 1)); + if (ref_serv_cell_idx_present) { + HANDLE_CODE(unpack_integer(ref_serv_cell_idx, bref, (uint8_t)0u, (uint8_t)31u)); + } + } + } + return SRSASN_SUCCESS; +} +void csi_rs_res_cfg_mob_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_str("subcarrierSpacing", subcarrier_spacing.to_string()); + j.start_array("csi-RS-CellList-Mobility"); + for (const auto& e1 : csi_rs_cell_list_mob) { + e1.to_json(j); + } + j.end_array(); + if (ext) { + if (ref_serv_cell_idx_present) { + j.write_int("refServCellIndex", ref_serv_cell_idx); + } + } + j.end_obj(); +} + +// CellsToAddMod ::= SEQUENCE +SRSASN_CODE cells_to_add_mod_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(cell_individual_offset.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE cells_to_add_mod_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(cell_individual_offset.unpack(bref)); + + return SRSASN_SUCCESS; +} +void cells_to_add_mod_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("physCellId", pci); + j.write_fieldname("cellIndividualOffset"); + cell_individual_offset.to_json(j); + j.end_obj(); +} + +// FilterCoefficient ::= ENUMERATED +std::string filt_coef_opts::to_string() const +{ + static const char* options[] = {"fc0", + "fc1", + "fc2", + "fc3", + "fc4", + "fc5", + "fc6", + "fc7", + "fc8", + "fc9", + "fc11", + "fc13", + "fc15", + "fc17", + "fc19", + "spare1"}; + return convert_enum_idx(options, 16, value, "filt_coef_e"); +} +uint8_t filt_coef_opts::to_number() const +{ + static const uint8_t options[] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 13, 15, 17, 19}; + return map_enum_number(options, 15, value, "filt_coef_e"); +} + +// MeasReportQuantity ::= SEQUENCE +SRSASN_CODE meas_report_quant_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(rsrp, 1)); + HANDLE_CODE(bref.pack(rsrq, 1)); + HANDLE_CODE(bref.pack(sinr, 1)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE meas_report_quant_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(rsrp, 1)); + HANDLE_CODE(bref.unpack(rsrq, 1)); + HANDLE_CODE(bref.unpack(sinr, 1)); + + return SRSASN_SUCCESS; +} +void meas_report_quant_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_bool("rsrp", rsrp); + j.write_bool("rsrq", rsrq); + j.write_bool("sinr", sinr); + j.end_obj(); +} + +// MeasTriggerQuantity ::= CHOICE +void meas_trigger_quant_c::destroy_() {} +void meas_trigger_quant_c::set(types::options e) +{ + destroy_(); + type_ = e; +} +meas_trigger_quant_c::meas_trigger_quant_c(const meas_trigger_quant_c& other) +{ + type_ = other.type(); + switch (type_) { + case types::rsrp: c.init(other.c.get()); break; - case types::slots80: + case types::rsrq: c.init(other.c.get()); break; - case types::slots160: + case types::sinr: c.init(other.c.get()); break; - case types::slots320: - c.init(other.c.get()); - break; - case types::slots640: - c.init(other.c.get()); - break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_c"); } } -csi_res_periodicity_and_offset_c& csi_res_periodicity_and_offset_c:: - operator=(const csi_res_periodicity_and_offset_c& other) +meas_trigger_quant_c& meas_trigger_quant_c::operator=(const meas_trigger_quant_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::slots4: - c.set(other.c.get()); - break; - case types::slots5: - c.set(other.c.get()); - break; - case types::slots8: - c.set(other.c.get()); - break; - case types::slots10: - c.set(other.c.get()); - break; - case types::slots16: - c.set(other.c.get()); - break; - case types::slots20: - c.set(other.c.get()); - break; - case types::slots32: - c.set(other.c.get()); - break; - case types::slots40: - c.set(other.c.get()); - break; - case types::slots64: + case types::rsrp: c.set(other.c.get()); break; - case types::slots80: + case types::rsrq: c.set(other.c.get()); break; - case types::slots160: + case types::sinr: c.set(other.c.get()); break; - case types::slots320: - c.set(other.c.get()); - break; - case types::slots640: - c.set(other.c.get()); - break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_c"); } return *this; } -void csi_res_periodicity_and_offset_c::to_json(json_writer& j) const +void meas_trigger_quant_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::slots4: - j.write_int("slots4", c.get()); + case types::rsrp: + j.write_int("rsrp", c.get()); break; - case types::slots5: - j.write_int("slots5", c.get()); + case types::rsrq: + j.write_int("rsrq", c.get()); break; - case types::slots8: - j.write_int("slots8", c.get()); + case types::sinr: + j.write_int("sinr", c.get()); break; - case types::slots10: - j.write_int("slots10", c.get()); + default: + log_invalid_choice_id(type_, "meas_trigger_quant_c"); + } + j.end_obj(); +} +SRSASN_CODE meas_trigger_quant_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::rsrp: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); break; - case types::slots16: - j.write_int("slots16", c.get()); + case types::rsrq: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); break; - case types::slots20: - j.write_int("slots20", c.get()); + case types::sinr: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); break; - case types::slots32: - j.write_int("slots32", c.get()); + default: + log_invalid_choice_id(type_, "meas_trigger_quant_c"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE meas_trigger_quant_c::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::rsrp: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); break; - case types::slots40: - j.write_int("slots40", c.get()); + case types::rsrq: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); break; - case types::slots64: - j.write_int("slots64", c.get()); + case types::sinr: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); break; - case types::slots80: - j.write_int("slots80", c.get()); + default: + log_invalid_choice_id(type_, "meas_trigger_quant_c"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string meas_trigger_quant_c::types_opts::to_string() const +{ + static const char* options[] = {"rsrp", "rsrq", "sinr"}; + return convert_enum_idx(options, 3, value, "meas_trigger_quant_c::types"); +} + +// MeasTriggerQuantityEUTRA ::= CHOICE +void meas_trigger_quant_eutra_c::destroy_() {} +void meas_trigger_quant_eutra_c::set(types::options e) +{ + destroy_(); + type_ = e; +} +meas_trigger_quant_eutra_c::meas_trigger_quant_eutra_c(const meas_trigger_quant_eutra_c& other) +{ + type_ = other.type(); + switch (type_) { + case types::rsrp: + c.init(other.c.get()); break; - case types::slots160: - j.write_int("slots160", c.get()); + case types::rsrq: + c.init(other.c.get()); break; - case types::slots320: - j.write_int("slots320", c.get()); + case types::sinr: + c.init(other.c.get()); break; - case types::slots640: - j.write_int("slots640", c.get()); + case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); } - j.end_obj(); } -SRSASN_CODE csi_res_periodicity_and_offset_c::pack(bit_ref& bref) const +meas_trigger_quant_eutra_c& meas_trigger_quant_eutra_c::operator=(const meas_trigger_quant_eutra_c& other) { - type_.pack(bref); + if (this == &other) { + return *this; + } + set(other.type()); switch (type_) { - case types::slots4: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); - break; - case types::slots5: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); - break; - case types::slots8: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); - break; - case types::slots10: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); + case types::rsrp: + c.set(other.c.get()); break; - case types::slots16: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); + case types::rsrq: + c.set(other.c.get()); break; - case types::slots20: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); + case types::sinr: + c.set(other.c.get()); break; - case types::slots32: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); + case types::nulltype: break; - case types::slots40: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); + default: + log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); + } + + return *this; +} +void meas_trigger_quant_eutra_c::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::rsrp: + j.write_int("rsrp", c.get()); break; - case types::slots64: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + case types::rsrq: + j.write_int("rsrq", c.get()); break; - case types::slots80: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); + case types::sinr: + j.write_int("sinr", c.get()); break; - case types::slots160: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + default: + log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); + } + j.end_obj(); +} +SRSASN_CODE meas_trigger_quant_eutra_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::rsrp: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)97u)); break; - case types::slots320: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + case types::rsrq: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)34u)); break; - case types::slots640: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); + case types::sinr: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); break; default: - log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_res_periodicity_and_offset_c::unpack(cbit_ref& bref) +SRSASN_CODE meas_trigger_quant_eutra_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::slots4: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); - break; - case types::slots5: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); - break; - case types::slots8: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); - break; - case types::slots10: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); - break; - case types::slots16: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); - break; - case types::slots20: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); - break; - case types::slots32: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); - break; - case types::slots40: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); - break; - case types::slots64: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); - break; - case types::slots80: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); - break; - case types::slots160: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + case types::rsrp: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)97u)); break; - case types::slots320: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + case types::rsrq: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)34u)); break; - case types::slots640: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); + case types::sinr: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); break; default: - log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_res_periodicity_and_offset_c::types_opts::to_string() const +std::string meas_trigger_quant_eutra_c::types_opts::to_string() const { - static const char* options[] = {"slots4", - "slots5", - "slots8", - "slots10", - "slots16", - "slots20", - "slots32", - "slots40", - "slots64", - "slots80", - "slots160", - "slots320", - "slots640"}; - return convert_enum_idx(options, 13, value, "csi_res_periodicity_and_offset_c::types"); + static const char* options[] = {"rsrp", "rsrq", "sinr"}; + return convert_enum_idx(options, 3, value, "meas_trigger_quant_eutra_c::types"); } -uint16_t csi_res_periodicity_and_offset_c::types_opts::to_number() const + +// MeasTriggerQuantityOffset ::= CHOICE +void meas_trigger_quant_offset_c::destroy_() {} +void meas_trigger_quant_offset_c::set(types::options e) { - static const uint16_t options[] = {4, 5, 8, 10, 16, 20, 32, 40, 64, 80, 160, 320, 640}; - return map_enum_number(options, 13, value, "csi_res_periodicity_and_offset_c::types"); + destroy_(); + type_ = e; } - -// DMRS-UplinkConfig ::= SEQUENCE -SRSASN_CODE dmrs_ul_cfg_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(dmrs_type_present, 1)); - HANDLE_CODE(bref.pack(dmrs_add_position_present, 1)); - HANDLE_CODE(bref.pack(phase_tracking_rs_present, 1)); - HANDLE_CODE(bref.pack(max_len_present, 1)); - HANDLE_CODE(bref.pack(transform_precoding_disabled_present, 1)); - HANDLE_CODE(bref.pack(transform_precoding_enabled_present, 1)); - - if (dmrs_add_position_present) { - HANDLE_CODE(dmrs_add_position.pack(bref)); - } - if (phase_tracking_rs_present) { - HANDLE_CODE(phase_tracking_rs.pack(bref)); - } - if (transform_precoding_disabled_present) { - bref.pack(transform_precoding_disabled.ext, 1); - HANDLE_CODE(bref.pack(transform_precoding_disabled.scrambling_id0_present, 1)); - HANDLE_CODE(bref.pack(transform_precoding_disabled.scrambling_id1_present, 1)); - if (transform_precoding_disabled.scrambling_id0_present) { - HANDLE_CODE(pack_integer(bref, transform_precoding_disabled.scrambling_id0, (uint32_t)0u, (uint32_t)65535u)); - } - if (transform_precoding_disabled.scrambling_id1_present) { - HANDLE_CODE(pack_integer(bref, transform_precoding_disabled.scrambling_id1, (uint32_t)0u, (uint32_t)65535u)); - } - } - if (transform_precoding_enabled_present) { - bref.pack(transform_precoding_enabled.ext, 1); - HANDLE_CODE(bref.pack(transform_precoding_enabled.npusch_id_present, 1)); - HANDLE_CODE(bref.pack(transform_precoding_enabled.seq_group_hop_present, 1)); - HANDLE_CODE(bref.pack(transform_precoding_enabled.seq_hop_present, 1)); - if (transform_precoding_enabled.npusch_id_present) { - HANDLE_CODE(pack_integer(bref, transform_precoding_enabled.npusch_id, (uint16_t)0u, (uint16_t)1007u)); - } - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE dmrs_ul_cfg_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(dmrs_type_present, 1)); - HANDLE_CODE(bref.unpack(dmrs_add_position_present, 1)); - HANDLE_CODE(bref.unpack(phase_tracking_rs_present, 1)); - HANDLE_CODE(bref.unpack(max_len_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoding_disabled_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoding_enabled_present, 1)); - - if (dmrs_add_position_present) { - HANDLE_CODE(dmrs_add_position.unpack(bref)); - } - if (phase_tracking_rs_present) { - HANDLE_CODE(phase_tracking_rs.unpack(bref)); - } - if (transform_precoding_disabled_present) { - bref.unpack(transform_precoding_disabled.ext, 1); - HANDLE_CODE(bref.unpack(transform_precoding_disabled.scrambling_id0_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoding_disabled.scrambling_id1_present, 1)); - if (transform_precoding_disabled.scrambling_id0_present) { - HANDLE_CODE(unpack_integer(transform_precoding_disabled.scrambling_id0, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (transform_precoding_disabled.scrambling_id1_present) { - HANDLE_CODE(unpack_integer(transform_precoding_disabled.scrambling_id1, bref, (uint32_t)0u, (uint32_t)65535u)); - } - } - if (transform_precoding_enabled_present) { - bref.unpack(transform_precoding_enabled.ext, 1); - HANDLE_CODE(bref.unpack(transform_precoding_enabled.npusch_id_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoding_enabled.seq_group_hop_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoding_enabled.seq_hop_present, 1)); - if (transform_precoding_enabled.npusch_id_present) { - HANDLE_CODE(unpack_integer(transform_precoding_enabled.npusch_id, bref, (uint16_t)0u, (uint16_t)1007u)); - } - } - - return SRSASN_SUCCESS; -} -void dmrs_ul_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (dmrs_type_present) { - j.write_str("dmrs-Type", "type2"); - } - if (dmrs_add_position_present) { - j.write_str("dmrs-AdditionalPosition", dmrs_add_position.to_string()); - } - if (phase_tracking_rs_present) { - j.write_fieldname("phaseTrackingRS"); - phase_tracking_rs.to_json(j); - } - if (max_len_present) { - j.write_str("maxLength", "len2"); - } - if (transform_precoding_disabled_present) { - j.write_fieldname("transformPrecodingDisabled"); - j.start_obj(); - if (transform_precoding_disabled.scrambling_id0_present) { - j.write_int("scramblingID0", transform_precoding_disabled.scrambling_id0); - } - if (transform_precoding_disabled.scrambling_id1_present) { - j.write_int("scramblingID1", transform_precoding_disabled.scrambling_id1); - } - j.end_obj(); - } - if (transform_precoding_enabled_present) { - j.write_fieldname("transformPrecodingEnabled"); - j.start_obj(); - if (transform_precoding_enabled.npusch_id_present) { - j.write_int("nPUSCH-Identity", transform_precoding_enabled.npusch_id); - } - if (transform_precoding_enabled.seq_group_hop_present) { - j.write_str("sequenceGroupHopping", "disabled"); - } - if (transform_precoding_enabled.seq_hop_present) { - j.write_str("sequenceHopping", "enabled"); - } - j.end_obj(); - } - j.end_obj(); -} - -std::string dmrs_ul_cfg_s::dmrs_add_position_opts::to_string() const -{ - static const char* options[] = {"pos0", "pos1", "pos3"}; - return convert_enum_idx(options, 3, value, "dmrs_ul_cfg_s::dmrs_add_position_e_"); -} -uint8_t dmrs_ul_cfg_s::dmrs_add_position_opts::to_number() const -{ - static const uint8_t options[] = {0, 1, 3}; - return map_enum_number(options, 3, value, "dmrs_ul_cfg_s::dmrs_add_position_e_"); -} - -// INT-ConfigurationPerServingCell ::= SEQUENCE -SRSASN_CODE int_cfg_per_serving_cell_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(pack_integer(bref, position_in_dci, (uint8_t)0u, (uint8_t)125u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE int_cfg_per_serving_cell_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(unpack_integer(position_in_dci, bref, (uint8_t)0u, (uint8_t)125u)); - - return SRSASN_SUCCESS; -} -void int_cfg_per_serving_cell_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("servingCellId", serving_cell_id); - j.write_int("positionInDCI", position_in_dci); - j.end_obj(); -} - -// PRACH-ResourceDedicatedBFR ::= CHOICE -void prach_res_ded_bfr_c::destroy_() -{ - switch (type_) { - case types::ssb: - c.destroy(); - break; - case types::csi_rs: - c.destroy(); - break; - default: - break; - } -} -void prach_res_ded_bfr_c::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::ssb: - c.init(); - break; - case types::csi_rs: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); - } -} -prach_res_ded_bfr_c::prach_res_ded_bfr_c(const prach_res_ded_bfr_c& other) +meas_trigger_quant_offset_c::meas_trigger_quant_offset_c(const meas_trigger_quant_offset_c& other) { type_ = other.type(); switch (type_) { - case types::ssb: - c.init(other.c.get()); + case types::rsrp: + c.init(other.c.get()); break; - case types::csi_rs: - c.init(other.c.get()); + case types::rsrq: + c.init(other.c.get()); + break; + case types::sinr: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); } } -prach_res_ded_bfr_c& prach_res_ded_bfr_c::operator=(const prach_res_ded_bfr_c& other) +meas_trigger_quant_offset_c& meas_trigger_quant_offset_c::operator=(const meas_trigger_quant_offset_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb: - c.set(other.c.get()); + case types::rsrp: + c.set(other.c.get()); break; - case types::csi_rs: - c.set(other.c.get()); + case types::rsrq: + c.set(other.c.get()); + break; + case types::sinr: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); } return *this; } -void prach_res_ded_bfr_c::to_json(json_writer& j) const +void meas_trigger_quant_offset_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb: - j.write_fieldname("ssb"); - c.get().to_json(j); + case types::rsrp: + j.write_int("rsrp", c.get()); break; - case types::csi_rs: - j.write_fieldname("csi-RS"); - c.get().to_json(j); + case types::rsrq: + j.write_int("rsrq", c.get()); + break; + case types::sinr: + j.write_int("sinr", c.get()); break; default: - log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); } j.end_obj(); } -SRSASN_CODE prach_res_ded_bfr_c::pack(bit_ref& bref) const +SRSASN_CODE meas_trigger_quant_offset_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb: - HANDLE_CODE(c.get().pack(bref)); + case types::rsrp: + HANDLE_CODE(pack_integer(bref, c.get(), (int8_t)-30, (int8_t)30)); break; - case types::csi_rs: - HANDLE_CODE(c.get().pack(bref)); + case types::rsrq: + HANDLE_CODE(pack_integer(bref, c.get(), (int8_t)-30, (int8_t)30)); + break; + case types::sinr: + HANDLE_CODE(pack_integer(bref, c.get(), (int8_t)-30, (int8_t)30)); break; default: - log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE prach_res_ded_bfr_c::unpack(cbit_ref& bref) +SRSASN_CODE meas_trigger_quant_offset_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb: - HANDLE_CODE(c.get().unpack(bref)); + case types::rsrp: + HANDLE_CODE(unpack_integer(c.get(), bref, (int8_t)-30, (int8_t)30)); break; - case types::csi_rs: - HANDLE_CODE(c.get().unpack(bref)); + case types::rsrq: + HANDLE_CODE(unpack_integer(c.get(), bref, (int8_t)-30, (int8_t)30)); + break; + case types::sinr: + HANDLE_CODE(unpack_integer(c.get(), bref, (int8_t)-30, (int8_t)30)); break; default: - log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); + log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string prach_res_ded_bfr_c::types_opts::to_string() const +std::string meas_trigger_quant_offset_c::types_opts::to_string() const { - static const char* options[] = {"ssb", "csi-RS"}; - return convert_enum_idx(options, 2, value, "prach_res_ded_bfr_c::types"); + static const char* options[] = {"rsrp", "rsrq", "sinr"}; + return convert_enum_idx(options, 3, value, "meas_trigger_quant_offset_c::types"); } -// PTRS-DownlinkConfig ::= SEQUENCE -SRSASN_CODE ptrs_dl_cfg_s::pack(bit_ref& bref) const +// NR-RS-Type ::= ENUMERATED +std::string nr_rs_type_opts::to_string() const +{ + static const char* options[] = {"ssb", "csi-rs"}; + return convert_enum_idx(options, 2, value, "nr_rs_type_e"); +} + +// ReportInterval ::= ENUMERATED +std::string report_interv_opts::to_string() const +{ + static const char* options[] = {"ms120", + "ms240", + "ms480", + "ms640", + "ms1024", + "ms2048", + "ms5120", + "ms10240", + "ms20480", + "ms40960", + "min1", + "min6", + "min12", + "min30"}; + return convert_enum_idx(options, 14, value, "report_interv_e"); +} +uint16_t report_interv_opts::to_number() const +{ + static const uint16_t options[] = {120, 240, 480, 640, 1024, 2048, 5120, 10240, 20480, 40960, 1, 6, 12, 30}; + return map_enum_number(options, 14, value, "report_interv_e"); +} + +// SSB-ConfigMobility ::= SEQUENCE +SRSASN_CODE ssb_cfg_mob_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(freq_density_present, 1)); - HANDLE_CODE(bref.pack(time_density_present, 1)); - HANDLE_CODE(bref.pack(epre_ratio_present, 1)); - HANDLE_CODE(bref.pack(res_elem_offset_present, 1)); + HANDLE_CODE(bref.pack(ssb_to_measure_present, 1)); + HANDLE_CODE(bref.pack(ss_rssi_meas_present, 1)); - if (freq_density_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, &(freq_density)[0], freq_density.size(), integer_packer(1, 276))); - } - if (time_density_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, &(time_density)[0], time_density.size(), integer_packer(0, 29))); - } - if (epre_ratio_present) { - HANDLE_CODE(pack_integer(bref, epre_ratio, (uint8_t)0u, (uint8_t)3u)); + if (ssb_to_measure_present) { + HANDLE_CODE(ssb_to_measure.pack(bref)); } - if (res_elem_offset_present) { - HANDLE_CODE(res_elem_offset.pack(bref)); + HANDLE_CODE(bref.pack(derive_ssb_idx_from_cell, 1)); + if (ss_rssi_meas_present) { + HANDLE_CODE(ss_rssi_meas.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE ptrs_dl_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE ssb_cfg_mob_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(freq_density_present, 1)); - HANDLE_CODE(bref.unpack(time_density_present, 1)); - HANDLE_CODE(bref.unpack(epre_ratio_present, 1)); - HANDLE_CODE(bref.unpack(res_elem_offset_present, 1)); + HANDLE_CODE(bref.unpack(ssb_to_measure_present, 1)); + HANDLE_CODE(bref.unpack(ss_rssi_meas_present, 1)); - if (freq_density_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(freq_density)[0], bref, freq_density.size(), integer_packer(1, 276))); - } - if (time_density_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(time_density)[0], bref, time_density.size(), integer_packer(0, 29))); - } - if (epre_ratio_present) { - HANDLE_CODE(unpack_integer(epre_ratio, bref, (uint8_t)0u, (uint8_t)3u)); + if (ssb_to_measure_present) { + HANDLE_CODE(ssb_to_measure.unpack(bref)); } - if (res_elem_offset_present) { - HANDLE_CODE(res_elem_offset.unpack(bref)); + HANDLE_CODE(bref.unpack(derive_ssb_idx_from_cell, 1)); + if (ss_rssi_meas_present) { + HANDLE_CODE(ss_rssi_meas.unpack(bref)); } return SRSASN_SUCCESS; } -void ptrs_dl_cfg_s::to_json(json_writer& j) const +void ssb_cfg_mob_s::to_json(json_writer& j) const { j.start_obj(); - if (freq_density_present) { - j.start_array("frequencyDensity"); - for (const auto& e1 : freq_density) { - j.write_int(e1); - } - j.end_array(); - } - if (time_density_present) { - j.start_array("timeDensity"); - for (const auto& e1 : time_density) { - j.write_int(e1); - } - j.end_array(); - } - if (epre_ratio_present) { - j.write_int("epre-Ratio", epre_ratio); + if (ssb_to_measure_present) { + j.write_fieldname("ssb-ToMeasure"); + ssb_to_measure.to_json(j); } - if (res_elem_offset_present) { - j.write_str("resourceElementOffset", res_elem_offset.to_string()); + j.write_bool("deriveSSB-IndexFromCell", derive_ssb_idx_from_cell); + if (ss_rssi_meas_present) { + j.write_fieldname("ss-RSSI-Measurement"); + ss_rssi_meas.to_json(j); } j.end_obj(); } -std::string ptrs_dl_cfg_s::res_elem_offset_opts::to_string() const -{ - static const char* options[] = {"offset01", "offset10", "offset11"}; - return convert_enum_idx(options, 3, value, "ptrs_dl_cfg_s::res_elem_offset_e_"); -} -float ptrs_dl_cfg_s::res_elem_offset_opts::to_number() const +// TimeToTrigger ::= ENUMERATED +std::string time_to_trigger_opts::to_string() const { - static const float options[] = {0.1, 1.0, 1.1}; - return map_enum_number(options, 3, value, "ptrs_dl_cfg_s::res_elem_offset_e_"); + static const char* options[] = {"ms0", + "ms40", + "ms64", + "ms80", + "ms100", + "ms128", + "ms160", + "ms256", + "ms320", + "ms480", + "ms512", + "ms640", + "ms1024", + "ms1280", + "ms2560", + "ms5120"}; + return convert_enum_idx(options, 16, value, "time_to_trigger_e"); } -std::string ptrs_dl_cfg_s::res_elem_offset_opts::to_number_string() const +uint16_t time_to_trigger_opts::to_number() const { - static const char* options[] = {"0.1", "1.0", "1.1"}; - return convert_enum_idx(options, 3, value, "ptrs_dl_cfg_s::res_elem_offset_e_"); + static const uint16_t options[] = {0, 40, 64, 80, 100, 128, 160, 256, 320, 480, 512, 640, 1024, 1280, 2560, 5120}; + return map_enum_number(options, 16, value, "time_to_trigger_e"); } -// PUCCH-FormatConfig ::= SEQUENCE -SRSASN_CODE pucch_format_cfg_s::pack(bit_ref& bref) const +// EUTRA-BlackCell ::= SEQUENCE +SRSASN_CODE eutra_black_cell_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(interslot_freq_hop_present, 1)); - HANDLE_CODE(bref.pack(add_dmrs_present, 1)); - HANDLE_CODE(bref.pack(max_code_rate_present, 1)); - HANDLE_CODE(bref.pack(nrof_slots_present, 1)); - HANDLE_CODE(bref.pack(pi2_bpsk_present, 1)); - HANDLE_CODE(bref.pack(simul_harq_ack_csi_present, 1)); - - if (max_code_rate_present) { - HANDLE_CODE(max_code_rate.pack(bref)); - } - if (nrof_slots_present) { - HANDLE_CODE(nrof_slots.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, cell_idx_eutra, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(pci_range.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE pucch_format_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE eutra_black_cell_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(interslot_freq_hop_present, 1)); - HANDLE_CODE(bref.unpack(add_dmrs_present, 1)); - HANDLE_CODE(bref.unpack(max_code_rate_present, 1)); - HANDLE_CODE(bref.unpack(nrof_slots_present, 1)); - HANDLE_CODE(bref.unpack(pi2_bpsk_present, 1)); - HANDLE_CODE(bref.unpack(simul_harq_ack_csi_present, 1)); - - if (max_code_rate_present) { - HANDLE_CODE(max_code_rate.unpack(bref)); - } - if (nrof_slots_present) { - HANDLE_CODE(nrof_slots.unpack(bref)); - } + HANDLE_CODE(unpack_integer(cell_idx_eutra, bref, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(pci_range.unpack(bref)); return SRSASN_SUCCESS; } -void pucch_format_cfg_s::to_json(json_writer& j) const +void eutra_black_cell_s::to_json(json_writer& j) const { j.start_obj(); - if (interslot_freq_hop_present) { - j.write_str("interslotFrequencyHopping", "enabled"); - } - if (add_dmrs_present) { - j.write_str("additionalDMRS", "true"); - } - if (max_code_rate_present) { - j.write_str("maxCodeRate", max_code_rate.to_string()); - } - if (nrof_slots_present) { - j.write_str("nrofSlots", nrof_slots.to_string()); - } - if (pi2_bpsk_present) { - j.write_str("pi2BPSK", "enabled"); - } - if (simul_harq_ack_csi_present) { - j.write_str("simultaneousHARQ-ACK-CSI", "true"); - } + j.write_int("cellIndexEUTRA", cell_idx_eutra); + j.write_fieldname("physCellIdRange"); + pci_range.to_json(j); j.end_obj(); } -std::string pucch_format_cfg_s::nrof_slots_opts::to_string() const +// EUTRA-Cell ::= SEQUENCE +SRSASN_CODE eutra_cell_s::pack(bit_ref& bref) const { - static const char* options[] = {"n2", "n4", "n8"}; - return convert_enum_idx(options, 3, value, "pucch_format_cfg_s::nrof_slots_e_"); + HANDLE_CODE(pack_integer(bref, cell_idx_eutra, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(cell_individual_offset.pack(bref)); + + return SRSASN_SUCCESS; } -uint8_t pucch_format_cfg_s::nrof_slots_opts::to_number() const +SRSASN_CODE eutra_cell_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {2, 4, 8}; - return map_enum_number(options, 3, value, "pucch_format_cfg_s::nrof_slots_e_"); + HANDLE_CODE(unpack_integer(cell_idx_eutra, bref, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(cell_individual_offset.unpack(bref)); + + return SRSASN_SUCCESS; +} +void eutra_cell_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("cellIndexEUTRA", cell_idx_eutra); + j.write_int("physCellId", pci); + j.write_str("cellIndividualOffset", cell_individual_offset.to_string()); + j.end_obj(); } -// PUCCH-PowerControl ::= SEQUENCE -SRSASN_CODE pucch_pwr_ctrl_s::pack(bit_ref& bref) const +// EventTriggerConfig ::= SEQUENCE +SRSASN_CODE event_trigger_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(delta_f_pucch_f0_present, 1)); - HANDLE_CODE(bref.pack(delta_f_pucch_f1_present, 1)); - HANDLE_CODE(bref.pack(delta_f_pucch_f2_present, 1)); - HANDLE_CODE(bref.pack(delta_f_pucch_f3_present, 1)); - HANDLE_CODE(bref.pack(delta_f_pucch_f4_present, 1)); - HANDLE_CODE(bref.pack(p0_set_present, 1)); - HANDLE_CODE(bref.pack(pathloss_ref_rss_present, 1)); - HANDLE_CODE(bref.pack(two_pucch_pc_adjustment_states_present, 1)); + HANDLE_CODE(bref.pack(report_quant_rs_idxes_present, 1)); + HANDLE_CODE(bref.pack(max_nrof_rs_idxes_to_report_present, 1)); + HANDLE_CODE(bref.pack(report_add_neigh_meas_present, 1)); - if (delta_f_pucch_f0_present) { - HANDLE_CODE(pack_integer(bref, delta_f_pucch_f0, (int8_t)-16, (int8_t)15)); + HANDLE_CODE(event_id.pack(bref)); + HANDLE_CODE(rs_type.pack(bref)); + HANDLE_CODE(report_interv.pack(bref)); + HANDLE_CODE(report_amount.pack(bref)); + HANDLE_CODE(report_quant_cell.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); + if (report_quant_rs_idxes_present) { + HANDLE_CODE(report_quant_rs_idxes.pack(bref)); } - if (delta_f_pucch_f1_present) { - HANDLE_CODE(pack_integer(bref, delta_f_pucch_f1, (int8_t)-16, (int8_t)15)); - } - if (delta_f_pucch_f2_present) { - HANDLE_CODE(pack_integer(bref, delta_f_pucch_f2, (int8_t)-16, (int8_t)15)); - } - if (delta_f_pucch_f3_present) { - HANDLE_CODE(pack_integer(bref, delta_f_pucch_f3, (int8_t)-16, (int8_t)15)); - } - if (delta_f_pucch_f4_present) { - HANDLE_CODE(pack_integer(bref, delta_f_pucch_f4, (int8_t)-16, (int8_t)15)); - } - if (p0_set_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, p0_set, 1, 8)); - } - if (pathloss_ref_rss_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, pathloss_ref_rss, 1, 4)); + if (max_nrof_rs_idxes_to_report_present) { + HANDLE_CODE(pack_integer(bref, max_nrof_rs_idxes_to_report, (uint8_t)1u, (uint8_t)32u)); } + HANDLE_CODE(bref.pack(include_beam_meass, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE pucch_pwr_ctrl_s::unpack(cbit_ref& bref) +SRSASN_CODE event_trigger_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(delta_f_pucch_f0_present, 1)); - HANDLE_CODE(bref.unpack(delta_f_pucch_f1_present, 1)); - HANDLE_CODE(bref.unpack(delta_f_pucch_f2_present, 1)); - HANDLE_CODE(bref.unpack(delta_f_pucch_f3_present, 1)); - HANDLE_CODE(bref.unpack(delta_f_pucch_f4_present, 1)); - HANDLE_CODE(bref.unpack(p0_set_present, 1)); - HANDLE_CODE(bref.unpack(pathloss_ref_rss_present, 1)); - HANDLE_CODE(bref.unpack(two_pucch_pc_adjustment_states_present, 1)); + HANDLE_CODE(bref.unpack(report_quant_rs_idxes_present, 1)); + HANDLE_CODE(bref.unpack(max_nrof_rs_idxes_to_report_present, 1)); + HANDLE_CODE(bref.unpack(report_add_neigh_meas_present, 1)); - if (delta_f_pucch_f0_present) { - HANDLE_CODE(unpack_integer(delta_f_pucch_f0, bref, (int8_t)-16, (int8_t)15)); - } - if (delta_f_pucch_f1_present) { - HANDLE_CODE(unpack_integer(delta_f_pucch_f1, bref, (int8_t)-16, (int8_t)15)); - } - if (delta_f_pucch_f2_present) { - HANDLE_CODE(unpack_integer(delta_f_pucch_f2, bref, (int8_t)-16, (int8_t)15)); - } - if (delta_f_pucch_f3_present) { - HANDLE_CODE(unpack_integer(delta_f_pucch_f3, bref, (int8_t)-16, (int8_t)15)); - } - if (delta_f_pucch_f4_present) { - HANDLE_CODE(unpack_integer(delta_f_pucch_f4, bref, (int8_t)-16, (int8_t)15)); - } - if (p0_set_present) { - HANDLE_CODE(unpack_dyn_seq_of(p0_set, bref, 1, 8)); + HANDLE_CODE(event_id.unpack(bref)); + HANDLE_CODE(rs_type.unpack(bref)); + HANDLE_CODE(report_interv.unpack(bref)); + HANDLE_CODE(report_amount.unpack(bref)); + HANDLE_CODE(report_quant_cell.unpack(bref)); + HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); + if (report_quant_rs_idxes_present) { + HANDLE_CODE(report_quant_rs_idxes.unpack(bref)); } - if (pathloss_ref_rss_present) { - HANDLE_CODE(unpack_dyn_seq_of(pathloss_ref_rss, bref, 1, 4)); + if (max_nrof_rs_idxes_to_report_present) { + HANDLE_CODE(unpack_integer(max_nrof_rs_idxes_to_report, bref, (uint8_t)1u, (uint8_t)32u)); } + HANDLE_CODE(bref.unpack(include_beam_meass, 1)); return SRSASN_SUCCESS; } -void pucch_pwr_ctrl_s::to_json(json_writer& j) const +void event_trigger_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (delta_f_pucch_f0_present) { - j.write_int("deltaF-PUCCH-f0", delta_f_pucch_f0); - } - if (delta_f_pucch_f1_present) { - j.write_int("deltaF-PUCCH-f1", delta_f_pucch_f1); - } - if (delta_f_pucch_f2_present) { - j.write_int("deltaF-PUCCH-f2", delta_f_pucch_f2); - } - if (delta_f_pucch_f3_present) { - j.write_int("deltaF-PUCCH-f3", delta_f_pucch_f3); - } - if (delta_f_pucch_f4_present) { - j.write_int("deltaF-PUCCH-f4", delta_f_pucch_f4); - } - if (p0_set_present) { - j.start_array("p0-Set"); - for (const auto& e1 : p0_set) { - e1.to_json(j); - } - j.end_array(); - } - if (pathloss_ref_rss_present) { - j.start_array("pathlossReferenceRSs"); - for (const auto& e1 : pathloss_ref_rss) { - e1.to_json(j); - } - j.end_array(); - } - if (two_pucch_pc_adjustment_states_present) { - j.write_str("twoPUCCH-PC-AdjustmentStates", "twoStates"); - } - j.end_obj(); -} - -// PUCCH-Resource ::= SEQUENCE -SRSASN_CODE pucch_res_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(intra_slot_freq_hop_present, 1)); - HANDLE_CODE(bref.pack(second_hop_prb_present, 1)); - - HANDLE_CODE(pack_integer(bref, pucch_res_id, (uint8_t)0u, (uint8_t)127u)); - HANDLE_CODE(pack_integer(bref, start_prb, (uint16_t)0u, (uint16_t)274u)); - if (second_hop_prb_present) { - HANDLE_CODE(pack_integer(bref, second_hop_prb, (uint16_t)0u, (uint16_t)274u)); - } - HANDLE_CODE(format.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE pucch_res_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(intra_slot_freq_hop_present, 1)); - HANDLE_CODE(bref.unpack(second_hop_prb_present, 1)); - - HANDLE_CODE(unpack_integer(pucch_res_id, bref, (uint8_t)0u, (uint8_t)127u)); - HANDLE_CODE(unpack_integer(start_prb, bref, (uint16_t)0u, (uint16_t)274u)); - if (second_hop_prb_present) { - HANDLE_CODE(unpack_integer(second_hop_prb, bref, (uint16_t)0u, (uint16_t)274u)); + j.write_fieldname("eventId"); + event_id.to_json(j); + j.write_str("rsType", rs_type.to_string()); + j.write_str("reportInterval", report_interv.to_string()); + j.write_str("reportAmount", report_amount.to_string()); + j.write_fieldname("reportQuantityCell"); + report_quant_cell.to_json(j); + j.write_int("maxReportCells", max_report_cells); + if (report_quant_rs_idxes_present) { + j.write_fieldname("reportQuantityRS-Indexes"); + report_quant_rs_idxes.to_json(j); } - HANDLE_CODE(format.unpack(bref)); - - return SRSASN_SUCCESS; -} -void pucch_res_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("pucch-ResourceId", pucch_res_id); - j.write_int("startingPRB", start_prb); - if (intra_slot_freq_hop_present) { - j.write_str("intraSlotFrequencyHopping", "enabled"); + if (max_nrof_rs_idxes_to_report_present) { + j.write_int("maxNrofRS-IndexesToReport", max_nrof_rs_idxes_to_report); } - if (second_hop_prb_present) { - j.write_int("secondHopPRB", second_hop_prb); + j.write_bool("includeBeamMeasurements", include_beam_meass); + if (report_add_neigh_meas_present) { + j.write_str("reportAddNeighMeas", "setup"); } - j.write_fieldname("format"); - format.to_json(j); j.end_obj(); } -void pucch_res_s::format_c_::destroy_() +void event_trigger_cfg_s::event_id_c_::destroy_() { switch (type_) { - case types::format0: - c.destroy(); + case types::event_a1: + c.destroy(); break; - case types::format1: - c.destroy(); + case types::event_a2: + c.destroy(); break; - case types::format2: - c.destroy(); + case types::event_a3: + c.destroy(); break; - case types::format3: - c.destroy(); + case types::event_a4: + c.destroy(); break; - case types::format4: - c.destroy(); + case types::event_a5: + c.destroy(); + break; + case types::event_a6: + c.destroy(); break; default: break; } } -void pucch_res_s::format_c_::set(types::options e) +void event_trigger_cfg_s::event_id_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::format0: - c.init(); + case types::event_a1: + c.init(); break; - case types::format1: - c.init(); + case types::event_a2: + c.init(); break; - case types::format2: - c.init(); + case types::event_a3: + c.init(); break; - case types::format3: - c.init(); + case types::event_a4: + c.init(); break; - case types::format4: - c.init(); + case types::event_a5: + c.init(); + break; + case types::event_a6: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); } } -pucch_res_s::format_c_::format_c_(const pucch_res_s::format_c_& other) +event_trigger_cfg_s::event_id_c_::event_id_c_(const event_trigger_cfg_s::event_id_c_& other) { type_ = other.type(); switch (type_) { - case types::format0: - c.init(other.c.get()); + case types::event_a1: + c.init(other.c.get()); break; - case types::format1: - c.init(other.c.get()); + case types::event_a2: + c.init(other.c.get()); break; - case types::format2: - c.init(other.c.get()); + case types::event_a3: + c.init(other.c.get()); break; - case types::format3: - c.init(other.c.get()); + case types::event_a4: + c.init(other.c.get()); break; - case types::format4: - c.init(other.c.get()); + case types::event_a5: + c.init(other.c.get()); + break; + case types::event_a6: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); } } -pucch_res_s::format_c_& pucch_res_s::format_c_::operator=(const pucch_res_s::format_c_& other) +event_trigger_cfg_s::event_id_c_& +event_trigger_cfg_s::event_id_c_::operator=(const event_trigger_cfg_s::event_id_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::format0: - c.set(other.c.get()); + case types::event_a1: + c.set(other.c.get()); break; - case types::format1: - c.set(other.c.get()); + case types::event_a2: + c.set(other.c.get()); break; - case types::format2: - c.set(other.c.get()); + case types::event_a3: + c.set(other.c.get()); break; - case types::format3: - c.set(other.c.get()); + case types::event_a4: + c.set(other.c.get()); break; - case types::format4: - c.set(other.c.get()); + case types::event_a5: + c.set(other.c.get()); + break; + case types::event_a6: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); } return *this; } -void pucch_res_s::format_c_::to_json(json_writer& j) const +void event_trigger_cfg_s::event_id_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::format0: - j.write_fieldname("format0"); - c.get().to_json(j); + case types::event_a1: + j.write_fieldname("eventA1"); + j.start_obj(); + j.write_fieldname("a1-Threshold"); + c.get().a1_thres.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); + j.end_obj(); break; - case types::format1: - j.write_fieldname("format1"); - c.get().to_json(j); + case types::event_a2: + j.write_fieldname("eventA2"); + j.start_obj(); + j.write_fieldname("a2-Threshold"); + c.get().a2_thres.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); + j.end_obj(); break; - case types::format2: - j.write_fieldname("format2"); - c.get().to_json(j); + case types::event_a3: + j.write_fieldname("eventA3"); + j.start_obj(); + j.write_fieldname("a3-Offset"); + c.get().a3_offset.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); + j.write_bool("useWhiteCellList", c.get().use_white_cell_list); + j.end_obj(); break; - case types::format3: - j.write_fieldname("format3"); - c.get().to_json(j); + case types::event_a4: + j.write_fieldname("eventA4"); + j.start_obj(); + j.write_fieldname("a4-Threshold"); + c.get().a4_thres.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); + j.write_bool("useWhiteCellList", c.get().use_white_cell_list); + j.end_obj(); break; - case types::format4: - j.write_fieldname("format4"); - c.get().to_json(j); + case types::event_a5: + j.write_fieldname("eventA5"); + j.start_obj(); + j.write_fieldname("a5-Threshold1"); + c.get().a5_thres1.to_json(j); + j.write_fieldname("a5-Threshold2"); + c.get().a5_thres2.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); + j.write_bool("useWhiteCellList", c.get().use_white_cell_list); + j.end_obj(); + break; + case types::event_a6: + j.write_fieldname("eventA6"); + j.start_obj(); + j.write_fieldname("a6-Offset"); + c.get().a6_offset.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); + j.write_bool("useWhiteCellList", c.get().use_white_cell_list); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); } j.end_obj(); } -SRSASN_CODE pucch_res_s::format_c_::pack(bit_ref& bref) const +SRSASN_CODE event_trigger_cfg_s::event_id_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::format0: - HANDLE_CODE(c.get().pack(bref)); + case types::event_a1: + HANDLE_CODE(c.get().a1_thres.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); break; - case types::format1: - HANDLE_CODE(c.get().pack(bref)); + case types::event_a2: + HANDLE_CODE(c.get().a2_thres.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); break; - case types::format2: - HANDLE_CODE(c.get().pack(bref)); + case types::event_a3: + HANDLE_CODE(c.get().a3_offset.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); + HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); break; - case types::format3: - HANDLE_CODE(c.get().pack(bref)); + case types::event_a4: + HANDLE_CODE(c.get().a4_thres.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); + HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); break; - case types::format4: - HANDLE_CODE(c.get().pack(bref)); + case types::event_a5: + HANDLE_CODE(c.get().a5_thres1.pack(bref)); + HANDLE_CODE(c.get().a5_thres2.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); + HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); + break; + case types::event_a6: + HANDLE_CODE(c.get().a6_offset.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); + HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); break; default: - log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_res_s::format_c_::unpack(cbit_ref& bref) +SRSASN_CODE event_trigger_cfg_s::event_id_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::format0: - HANDLE_CODE(c.get().unpack(bref)); + case types::event_a1: + HANDLE_CODE(c.get().a1_thres.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); break; - case types::format1: - HANDLE_CODE(c.get().unpack(bref)); + case types::event_a2: + HANDLE_CODE(c.get().a2_thres.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); break; - case types::format2: - HANDLE_CODE(c.get().unpack(bref)); + case types::event_a3: + HANDLE_CODE(c.get().a3_offset.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); break; - case types::format3: - HANDLE_CODE(c.get().unpack(bref)); + case types::event_a4: + HANDLE_CODE(c.get().a4_thres.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); break; - case types::format4: - HANDLE_CODE(c.get().unpack(bref)); + case types::event_a5: + HANDLE_CODE(c.get().a5_thres1.unpack(bref)); + HANDLE_CODE(c.get().a5_thres2.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); + break; + case types::event_a6: + HANDLE_CODE(c.get().a6_offset.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); break; default: - log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string pucch_res_s::format_c_::types_opts::to_string() const +std::string event_trigger_cfg_s::event_id_c_::types_opts::to_string() const { - static const char* options[] = {"format0", "format1", "format2", "format3", "format4"}; - return convert_enum_idx(options, 5, value, "pucch_res_s::format_c_::types"); + static const char* options[] = {"eventA1", "eventA2", "eventA3", "eventA4", "eventA5", "eventA6"}; + return convert_enum_idx(options, 6, value, "event_trigger_cfg_s::event_id_c_::types"); } -uint8_t pucch_res_s::format_c_::types_opts::to_number() const +uint8_t event_trigger_cfg_s::event_id_c_::types_opts::to_number() const { - static const uint8_t options[] = {0, 1, 2, 3, 4}; - return map_enum_number(options, 5, value, "pucch_res_s::format_c_::types"); + static const uint8_t options[] = {1, 2, 3, 4, 5, 6}; + return map_enum_number(options, 6, value, "event_trigger_cfg_s::event_id_c_::types"); } -// PUCCH-ResourceSet ::= SEQUENCE -SRSASN_CODE pucch_res_set_s::pack(bit_ref& bref) const +std::string event_trigger_cfg_s::report_amount_opts::to_string() const +{ + static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; + return convert_enum_idx(options, 8, value, "event_trigger_cfg_s::report_amount_e_"); +} +int8_t event_trigger_cfg_s::report_amount_opts::to_number() const { - HANDLE_CODE(bref.pack(max_payload_minus1_present, 1)); + static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; + return map_enum_number(options, 8, value, "event_trigger_cfg_s::report_amount_e_"); +} - HANDLE_CODE(pack_integer(bref, pucch_res_set_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pack_dyn_seq_of(bref, res_list, 1, 32, integer_packer(0, 127))); - if (max_payload_minus1_present) { - HANDLE_CODE(pack_integer(bref, max_payload_minus1, (uint16_t)4u, (uint16_t)256u)); - } +// EventTriggerConfigInterRAT ::= SEQUENCE +SRSASN_CODE event_trigger_cfg_inter_rat_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(event_id.pack(bref)); + HANDLE_CODE(rs_type.pack(bref)); + HANDLE_CODE(report_interv.pack(bref)); + HANDLE_CODE(report_amount.pack(bref)); + HANDLE_CODE(report_quant.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); return SRSASN_SUCCESS; } -SRSASN_CODE pucch_res_set_s::unpack(cbit_ref& bref) +SRSASN_CODE event_trigger_cfg_inter_rat_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(max_payload_minus1_present, 1)); - - HANDLE_CODE(unpack_integer(pucch_res_set_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(unpack_dyn_seq_of(res_list, bref, 1, 32, integer_packer(0, 127))); - if (max_payload_minus1_present) { - HANDLE_CODE(unpack_integer(max_payload_minus1, bref, (uint16_t)4u, (uint16_t)256u)); - } + bref.unpack(ext, 1); + HANDLE_CODE(event_id.unpack(bref)); + HANDLE_CODE(rs_type.unpack(bref)); + HANDLE_CODE(report_interv.unpack(bref)); + HANDLE_CODE(report_amount.unpack(bref)); + HANDLE_CODE(report_quant.unpack(bref)); + HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); return SRSASN_SUCCESS; } -void pucch_res_set_s::to_json(json_writer& j) const +void event_trigger_cfg_inter_rat_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("pucch-ResourceSetId", pucch_res_set_id); - j.start_array("resourceList"); - for (const auto& e1 : res_list) { - j.write_int(e1); - } - j.end_array(); - if (max_payload_minus1_present) { - j.write_int("maxPayloadMinus1", max_payload_minus1); - } + j.write_fieldname("eventId"); + event_id.to_json(j); + j.write_str("rsType", rs_type.to_string()); + j.write_str("reportInterval", report_interv.to_string()); + j.write_str("reportAmount", report_amount.to_string()); + j.write_fieldname("reportQuantity"); + report_quant.to_json(j); + j.write_int("maxReportCells", max_report_cells); j.end_obj(); } -// PUCCH-SpatialRelationInfo ::= SEQUENCE -SRSASN_CODE pucch_spatial_relation_info_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(serving_cell_id_present, 1)); - - HANDLE_CODE(pack_integer(bref, pucch_spatial_relation_info_id, (uint8_t)1u, (uint8_t)8u)); - if (serving_cell_id_present) { - HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(ref_sig.pack(bref)); - HANDLE_CODE(pack_integer(bref, pucch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pack_integer(bref, p0_pucch_id, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(closed_loop_idx.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE pucch_spatial_relation_info_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(serving_cell_id_present, 1)); - - HANDLE_CODE(unpack_integer(pucch_spatial_relation_info_id, bref, (uint8_t)1u, (uint8_t)8u)); - if (serving_cell_id_present) { - HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(ref_sig.unpack(bref)); - HANDLE_CODE(unpack_integer(pucch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(unpack_integer(p0_pucch_id, bref, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(closed_loop_idx.unpack(bref)); - - return SRSASN_SUCCESS; -} -void pucch_spatial_relation_info_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("pucch-SpatialRelationInfoId", pucch_spatial_relation_info_id); - if (serving_cell_id_present) { - j.write_int("servingCellId", serving_cell_id); - } - j.write_fieldname("referenceSignal"); - ref_sig.to_json(j); - j.write_int("pucch-PathlossReferenceRS-Id", pucch_pathloss_ref_rs_id); - j.write_int("p0-PUCCH-Id", p0_pucch_id); - j.write_str("closedLoopIndex", closed_loop_idx.to_string()); - j.end_obj(); -} - -void pucch_spatial_relation_info_s::ref_sig_c_::destroy_() +void event_trigger_cfg_inter_rat_s::event_id_c_::destroy_() { switch (type_) { - case types::srs: - c.destroy(); + case types::event_b1: + c.destroy(); + break; + case types::event_b2: + c.destroy(); break; default: break; } } -void pucch_spatial_relation_info_s::ref_sig_c_::set(types::options e) +void event_trigger_cfg_inter_rat_s::event_id_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ssb_idx: - break; - case types::csi_rs_idx: + case types::event_b1: + c.init(); break; - case types::srs: - c.init(); + case types::event_b2: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); } } -pucch_spatial_relation_info_s::ref_sig_c_::ref_sig_c_(const pucch_spatial_relation_info_s::ref_sig_c_& other) +event_trigger_cfg_inter_rat_s::event_id_c_::event_id_c_(const event_trigger_cfg_inter_rat_s::event_id_c_& other) { type_ = other.type(); switch (type_) { - case types::ssb_idx: - c.init(other.c.get()); - break; - case types::csi_rs_idx: - c.init(other.c.get()); + case types::event_b1: + c.init(other.c.get()); break; - case types::srs: - c.init(other.c.get()); + case types::event_b2: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); } } -pucch_spatial_relation_info_s::ref_sig_c_& pucch_spatial_relation_info_s::ref_sig_c_:: - operator=(const pucch_spatial_relation_info_s::ref_sig_c_& other) +event_trigger_cfg_inter_rat_s::event_id_c_& +event_trigger_cfg_inter_rat_s::event_id_c_::operator=(const event_trigger_cfg_inter_rat_s::event_id_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb_idx: - c.set(other.c.get()); - break; - case types::csi_rs_idx: - c.set(other.c.get()); + case types::event_b1: + c.set(other.c.get()); break; - case types::srs: - c.set(other.c.get()); + case types::event_b2: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); } return *this; } -void pucch_spatial_relation_info_s::ref_sig_c_::to_json(json_writer& j) const +void event_trigger_cfg_inter_rat_s::event_id_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb_idx: - j.write_int("ssb-Index", c.get()); - break; - case types::csi_rs_idx: - j.write_int("csi-RS-Index", c.get()); + case types::event_b1: + j.write_fieldname("eventB1"); + j.start_obj(); + j.write_fieldname("b1-ThresholdEUTRA"); + c.get().b1_thres_eutra.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); + j.end_obj(); break; - case types::srs: - j.write_fieldname("srs"); + case types::event_b2: + j.write_fieldname("eventB2"); j.start_obj(); - j.write_int("resource", c.get().res); - j.write_int("uplinkBWP", c.get().ul_bwp); + j.write_fieldname("b2-Threshold1"); + c.get().b2_thres1.to_json(j); + j.write_fieldname("b2-Threshold2EUTRA"); + c.get().b2_thres2_eutra.to_json(j); + j.write_bool("reportOnLeave", c.get().report_on_leave); + j.write_int("hysteresis", c.get().hysteresis); + j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); j.end_obj(); break; default: - log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); } j.end_obj(); } -SRSASN_CODE pucch_spatial_relation_info_s::ref_sig_c_::pack(bit_ref& bref) const +SRSASN_CODE event_trigger_cfg_inter_rat_s::event_id_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); - break; - case types::csi_rs_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + case types::event_b1: + bref.pack(c.get().ext, 1); + HANDLE_CODE(c.get().b1_thres_eutra.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); break; - case types::srs: - HANDLE_CODE(pack_integer(bref, c.get().res, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_integer(bref, c.get().ul_bwp, (uint8_t)0u, (uint8_t)4u)); + case types::event_b2: + bref.pack(c.get().ext, 1); + HANDLE_CODE(c.get().b2_thres1.pack(bref)); + HANDLE_CODE(c.get().b2_thres2_eutra.pack(bref)); + HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); + HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.pack(bref)); break; default: - log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_spatial_relation_info_s::ref_sig_c_::unpack(cbit_ref& bref) +SRSASN_CODE event_trigger_cfg_inter_rat_s::event_id_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); - break; - case types::csi_rs_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + case types::event_b1: + bref.unpack(c.get().ext, 1); + HANDLE_CODE(c.get().b1_thres_eutra.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); break; - case types::srs: - HANDLE_CODE(unpack_integer(c.get().res, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_integer(c.get().ul_bwp, bref, (uint8_t)0u, (uint8_t)4u)); + case types::event_b2: + bref.unpack(c.get().ext, 1); + HANDLE_CODE(c.get().b2_thres1.unpack(bref)); + HANDLE_CODE(c.get().b2_thres2_eutra.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); + HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); + HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); break; default: - log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); + log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string pucch_spatial_relation_info_s::ref_sig_c_::types_opts::to_string() const +std::string event_trigger_cfg_inter_rat_s::event_id_c_::types_opts::to_string() const { - static const char* options[] = {"ssb-Index", "csi-RS-Index", "srs"}; - return convert_enum_idx(options, 3, value, "pucch_spatial_relation_info_s::ref_sig_c_::types"); + static const char* options[] = {"eventB1", "eventB2"}; + return convert_enum_idx(options, 2, value, "event_trigger_cfg_inter_rat_s::event_id_c_::types"); +} +uint8_t event_trigger_cfg_inter_rat_s::event_id_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "event_trigger_cfg_inter_rat_s::event_id_c_::types"); } -std::string pucch_spatial_relation_info_s::closed_loop_idx_opts::to_string() const +std::string event_trigger_cfg_inter_rat_s::report_amount_opts::to_string() const { - static const char* options[] = {"i0", "i1"}; - return convert_enum_idx(options, 2, value, "pucch_spatial_relation_info_s::closed_loop_idx_e_"); + static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; + return convert_enum_idx(options, 8, value, "event_trigger_cfg_inter_rat_s::report_amount_e_"); } -uint8_t pucch_spatial_relation_info_s::closed_loop_idx_opts::to_number() const +int8_t event_trigger_cfg_inter_rat_s::report_amount_opts::to_number() const { - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "pucch_spatial_relation_info_s::closed_loop_idx_e_"); + static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; + return map_enum_number(options, 8, value, "event_trigger_cfg_inter_rat_s::report_amount_e_"); } -// PUSCH-PowerControl ::= SEQUENCE -SRSASN_CODE pusch_pwr_ctrl_s::pack(bit_ref& bref) const +// FilterConfig ::= SEQUENCE +SRSASN_CODE filt_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(tpc_accumulation_present, 1)); - HANDLE_CODE(bref.pack(msg3_alpha_present, 1)); - HANDLE_CODE(bref.pack(p0_nominal_without_grant_present, 1)); - HANDLE_CODE(bref.pack(p0_alpha_sets_present, 1)); - HANDLE_CODE(bref.pack(pathloss_ref_rs_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(pathloss_ref_rs_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(two_pusch_pc_adjustment_states_present, 1)); - HANDLE_CODE(bref.pack(delta_mcs_present, 1)); - HANDLE_CODE(bref.pack(sri_pusch_map_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(sri_pusch_map_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(filt_coef_rsrp_present, 1)); + HANDLE_CODE(bref.pack(filt_coef_rsrq_present, 1)); + HANDLE_CODE(bref.pack(filt_coef_rs_sinr_present, 1)); - if (msg3_alpha_present) { - HANDLE_CODE(msg3_alpha.pack(bref)); - } - if (p0_nominal_without_grant_present) { - HANDLE_CODE(pack_integer(bref, p0_nominal_without_grant, (int16_t)-202, (int16_t)24)); - } - if (p0_alpha_sets_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, p0_alpha_sets, 1, 30)); - } - if (pathloss_ref_rs_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, pathloss_ref_rs_to_add_mod_list, 1, 4)); - } - if (pathloss_ref_rs_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, pathloss_ref_rs_to_release_list, 1, 4, integer_packer(0, 3))); + if (filt_coef_rsrp_present) { + HANDLE_CODE(filt_coef_rsrp.pack(bref)); } - if (sri_pusch_map_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sri_pusch_map_to_add_mod_list, 1, 16)); + if (filt_coef_rsrq_present) { + HANDLE_CODE(filt_coef_rsrq.pack(bref)); } - if (sri_pusch_map_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sri_pusch_map_to_release_list, 1, 16, integer_packer(0, 15))); + if (filt_coef_rs_sinr_present) { + HANDLE_CODE(filt_coef_rs_sinr.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE pusch_pwr_ctrl_s::unpack(cbit_ref& bref) +SRSASN_CODE filt_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(tpc_accumulation_present, 1)); - HANDLE_CODE(bref.unpack(msg3_alpha_present, 1)); - HANDLE_CODE(bref.unpack(p0_nominal_without_grant_present, 1)); - HANDLE_CODE(bref.unpack(p0_alpha_sets_present, 1)); - HANDLE_CODE(bref.unpack(pathloss_ref_rs_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(pathloss_ref_rs_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(two_pusch_pc_adjustment_states_present, 1)); - HANDLE_CODE(bref.unpack(delta_mcs_present, 1)); - HANDLE_CODE(bref.unpack(sri_pusch_map_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(sri_pusch_map_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(filt_coef_rsrp_present, 1)); + HANDLE_CODE(bref.unpack(filt_coef_rsrq_present, 1)); + HANDLE_CODE(bref.unpack(filt_coef_rs_sinr_present, 1)); - if (msg3_alpha_present) { - HANDLE_CODE(msg3_alpha.unpack(bref)); - } - if (p0_nominal_without_grant_present) { - HANDLE_CODE(unpack_integer(p0_nominal_without_grant, bref, (int16_t)-202, (int16_t)24)); - } - if (p0_alpha_sets_present) { - HANDLE_CODE(unpack_dyn_seq_of(p0_alpha_sets, bref, 1, 30)); - } - if (pathloss_ref_rs_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(pathloss_ref_rs_to_add_mod_list, bref, 1, 4)); - } - if (pathloss_ref_rs_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(pathloss_ref_rs_to_release_list, bref, 1, 4, integer_packer(0, 3))); + if (filt_coef_rsrp_present) { + HANDLE_CODE(filt_coef_rsrp.unpack(bref)); } - if (sri_pusch_map_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sri_pusch_map_to_add_mod_list, bref, 1, 16)); + if (filt_coef_rsrq_present) { + HANDLE_CODE(filt_coef_rsrq.unpack(bref)); } - if (sri_pusch_map_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sri_pusch_map_to_release_list, bref, 1, 16, integer_packer(0, 15))); + if (filt_coef_rs_sinr_present) { + HANDLE_CODE(filt_coef_rs_sinr.unpack(bref)); } return SRSASN_SUCCESS; } -void pusch_pwr_ctrl_s::to_json(json_writer& j) const +void filt_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (tpc_accumulation_present) { - j.write_str("tpc-Accumulation", "disabled"); - } - if (msg3_alpha_present) { - j.write_str("msg3-Alpha", msg3_alpha.to_string()); - } - if (p0_nominal_without_grant_present) { - j.write_int("p0-NominalWithoutGrant", p0_nominal_without_grant); - } - if (p0_alpha_sets_present) { - j.start_array("p0-AlphaSets"); - for (const auto& e1 : p0_alpha_sets) { - e1.to_json(j); - } - j.end_array(); - } - if (pathloss_ref_rs_to_add_mod_list_present) { - j.start_array("pathlossReferenceRSToAddModList"); - for (const auto& e1 : pathloss_ref_rs_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (pathloss_ref_rs_to_release_list_present) { - j.start_array("pathlossReferenceRSToReleaseList"); - for (const auto& e1 : pathloss_ref_rs_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (two_pusch_pc_adjustment_states_present) { - j.write_str("twoPUSCH-PC-AdjustmentStates", "twoStates"); - } - if (delta_mcs_present) { - j.write_str("deltaMCS", "enabled"); + if (filt_coef_rsrp_present) { + j.write_str("filterCoefficientRSRP", filt_coef_rsrp.to_string()); } - if (sri_pusch_map_to_add_mod_list_present) { - j.start_array("sri-PUSCH-MappingToAddModList"); - for (const auto& e1 : sri_pusch_map_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); + if (filt_coef_rsrq_present) { + j.write_str("filterCoefficientRSRQ", filt_coef_rsrq.to_string()); } - if (sri_pusch_map_to_release_list_present) { - j.start_array("sri-PUSCH-MappingToReleaseList"); - for (const auto& e1 : sri_pusch_map_to_release_list) { - j.write_int(e1); - } - j.end_array(); + if (filt_coef_rs_sinr_present) { + j.write_str("filterCoefficientRS-SINR", filt_coef_rs_sinr.to_string()); } j.end_obj(); } -// QCL-Info ::= SEQUENCE -SRSASN_CODE qcl_info_s::pack(bit_ref& bref) const +// PCI-RangeElement ::= SEQUENCE +SRSASN_CODE pci_range_elem_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, pci_range_idx, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(pci_range.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE pci_range_elem_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(pci_range_idx, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(pci_range.unpack(bref)); + + return SRSASN_SUCCESS; +} +void pci_range_elem_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("pci-RangeIndex", pci_range_idx); + j.write_fieldname("pci-Range"); + pci_range.to_json(j); + j.end_obj(); +} + +// PeriodicalReportConfig ::= SEQUENCE +SRSASN_CODE periodical_report_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(cell_present, 1)); - HANDLE_CODE(bref.pack(bwp_id_present, 1)); + HANDLE_CODE(bref.pack(report_quant_rs_idxes_present, 1)); + HANDLE_CODE(bref.pack(max_nrof_rs_idxes_to_report_present, 1)); - if (cell_present) { - HANDLE_CODE(pack_integer(bref, cell, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(rs_type.pack(bref)); + HANDLE_CODE(report_interv.pack(bref)); + HANDLE_CODE(report_amount.pack(bref)); + HANDLE_CODE(report_quant_cell.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); + if (report_quant_rs_idxes_present) { + HANDLE_CODE(report_quant_rs_idxes.pack(bref)); } - if (bwp_id_present) { - HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); + if (max_nrof_rs_idxes_to_report_present) { + HANDLE_CODE(pack_integer(bref, max_nrof_rs_idxes_to_report, (uint8_t)1u, (uint8_t)32u)); } - HANDLE_CODE(ref_sig.pack(bref)); - HANDLE_CODE(qcl_type.pack(bref)); + HANDLE_CODE(bref.pack(include_beam_meass, 1)); + HANDLE_CODE(bref.pack(use_white_cell_list, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE qcl_info_s::unpack(cbit_ref& bref) +SRSASN_CODE periodical_report_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(cell_present, 1)); - HANDLE_CODE(bref.unpack(bwp_id_present, 1)); + HANDLE_CODE(bref.unpack(report_quant_rs_idxes_present, 1)); + HANDLE_CODE(bref.unpack(max_nrof_rs_idxes_to_report_present, 1)); - if (cell_present) { - HANDLE_CODE(unpack_integer(cell, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(rs_type.unpack(bref)); + HANDLE_CODE(report_interv.unpack(bref)); + HANDLE_CODE(report_amount.unpack(bref)); + HANDLE_CODE(report_quant_cell.unpack(bref)); + HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); + if (report_quant_rs_idxes_present) { + HANDLE_CODE(report_quant_rs_idxes.unpack(bref)); } - if (bwp_id_present) { - HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); + if (max_nrof_rs_idxes_to_report_present) { + HANDLE_CODE(unpack_integer(max_nrof_rs_idxes_to_report, bref, (uint8_t)1u, (uint8_t)32u)); } - HANDLE_CODE(ref_sig.unpack(bref)); - HANDLE_CODE(qcl_type.unpack(bref)); + HANDLE_CODE(bref.unpack(include_beam_meass, 1)); + HANDLE_CODE(bref.unpack(use_white_cell_list, 1)); return SRSASN_SUCCESS; } -void qcl_info_s::to_json(json_writer& j) const +void periodical_report_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (cell_present) { - j.write_int("cell", cell); + j.write_str("rsType", rs_type.to_string()); + j.write_str("reportInterval", report_interv.to_string()); + j.write_str("reportAmount", report_amount.to_string()); + j.write_fieldname("reportQuantityCell"); + report_quant_cell.to_json(j); + j.write_int("maxReportCells", max_report_cells); + if (report_quant_rs_idxes_present) { + j.write_fieldname("reportQuantityRS-Indexes"); + report_quant_rs_idxes.to_json(j); } - if (bwp_id_present) { - j.write_int("bwp-Id", bwp_id); + if (max_nrof_rs_idxes_to_report_present) { + j.write_int("maxNrofRS-IndexesToReport", max_nrof_rs_idxes_to_report); } - j.write_fieldname("referenceSignal"); - ref_sig.to_json(j); - j.write_str("qcl-Type", qcl_type.to_string()); + j.write_bool("includeBeamMeasurements", include_beam_meass); + j.write_bool("useWhiteCellList", use_white_cell_list); j.end_obj(); } -void qcl_info_s::ref_sig_c_::destroy_() {} -void qcl_info_s::ref_sig_c_::set(types::options e) +std::string periodical_report_cfg_s::report_amount_opts::to_string() const { - destroy_(); - type_ = e; + static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; + return convert_enum_idx(options, 8, value, "periodical_report_cfg_s::report_amount_e_"); } -qcl_info_s::ref_sig_c_::ref_sig_c_(const qcl_info_s::ref_sig_c_& other) +int8_t periodical_report_cfg_s::report_amount_opts::to_number() const { - type_ = other.type(); - switch (type_) { - case types::csi_rs: - c.init(other.c.get()); - break; - case types::ssb: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); - } + static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; + return map_enum_number(options, 8, value, "periodical_report_cfg_s::report_amount_e_"); } -qcl_info_s::ref_sig_c_& qcl_info_s::ref_sig_c_::operator=(const qcl_info_s::ref_sig_c_& other) + +// PeriodicalReportConfigInterRAT ::= SEQUENCE +SRSASN_CODE periodical_report_cfg_inter_rat_s::pack(bit_ref& bref) const { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::csi_rs: - c.set(other.c.get()); - break; - case types::ssb: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); - } + bref.pack(ext, 1); + HANDLE_CODE(report_interv.pack(bref)); + HANDLE_CODE(report_amount.pack(bref)); + HANDLE_CODE(report_quant.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); - return *this; + return SRSASN_SUCCESS; } -void qcl_info_s::ref_sig_c_::to_json(json_writer& j) const +SRSASN_CODE periodical_report_cfg_inter_rat_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(report_interv.unpack(bref)); + HANDLE_CODE(report_amount.unpack(bref)); + HANDLE_CODE(report_quant.unpack(bref)); + HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); + + return SRSASN_SUCCESS; +} +void periodical_report_cfg_inter_rat_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::csi_rs: - j.write_int("csi-rs", c.get()); - break; - case types::ssb: - j.write_int("ssb", c.get()); - break; - default: - log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); - } + j.write_str("reportInterval", report_interv.to_string()); + j.write_str("reportAmount", report_amount.to_string()); + j.write_fieldname("reportQuantity"); + report_quant.to_json(j); + j.write_int("maxReportCells", max_report_cells); j.end_obj(); } -SRSASN_CODE qcl_info_s::ref_sig_c_::pack(bit_ref& bref) const + +std::string periodical_report_cfg_inter_rat_s::report_amount_opts::to_string() const { - type_.pack(bref); - switch (type_) { - case types::csi_rs: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); - break; - case types::ssb: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); - break; - default: - log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; + return convert_enum_idx(options, 8, value, "periodical_report_cfg_inter_rat_s::report_amount_e_"); +} +int8_t periodical_report_cfg_inter_rat_s::report_amount_opts::to_number() const +{ + static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; + return map_enum_number(options, 8, value, "periodical_report_cfg_inter_rat_s::report_amount_e_"); +} + +// RAN-AreaConfig ::= SEQUENCE +SRSASN_CODE ran_area_cfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(ran_area_code_list_present, 1)); + + HANDLE_CODE(tac.pack(bref)); + if (ran_area_code_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ran_area_code_list, 1, 32, integer_packer(0, 255))); } + return SRSASN_SUCCESS; } -SRSASN_CODE qcl_info_s::ref_sig_c_::unpack(cbit_ref& bref) +SRSASN_CODE ran_area_cfg_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::csi_rs: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); - break; - case types::ssb: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); - break; - default: - log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); - return SRSASN_ERROR_DECODE_FAIL; + HANDLE_CODE(bref.unpack(ran_area_code_list_present, 1)); + + HANDLE_CODE(tac.unpack(bref)); + if (ran_area_code_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ran_area_code_list, bref, 1, 32, integer_packer(0, 255))); } + return SRSASN_SUCCESS; } +void ran_area_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_str("trackingAreaCode", tac.to_string()); + if (ran_area_code_list_present) { + j.start_array("ran-AreaCodeList"); + for (const auto& e1 : ran_area_code_list) { + j.write_int(e1); + } + j.end_array(); + } + j.end_obj(); +} -std::string qcl_info_s::ref_sig_c_::types_opts::to_string() const +// ReferenceSignalConfig ::= SEQUENCE +SRSASN_CODE ref_sig_cfg_s::pack(bit_ref& bref) const { - static const char* options[] = {"csi-rs", "ssb"}; - return convert_enum_idx(options, 2, value, "qcl_info_s::ref_sig_c_::types"); + HANDLE_CODE(bref.pack(ssb_cfg_mob_present, 1)); + HANDLE_CODE(bref.pack(csi_rs_res_cfg_mob_present, 1)); + + if (ssb_cfg_mob_present) { + HANDLE_CODE(ssb_cfg_mob.pack(bref)); + } + if (csi_rs_res_cfg_mob_present) { + HANDLE_CODE(csi_rs_res_cfg_mob.pack(bref)); + } + + return SRSASN_SUCCESS; } +SRSASN_CODE ref_sig_cfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(ssb_cfg_mob_present, 1)); + HANDLE_CODE(bref.unpack(csi_rs_res_cfg_mob_present, 1)); -std::string qcl_info_s::qcl_type_opts::to_string() const + if (ssb_cfg_mob_present) { + HANDLE_CODE(ssb_cfg_mob.unpack(bref)); + } + if (csi_rs_res_cfg_mob_present) { + HANDLE_CODE(csi_rs_res_cfg_mob.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void ref_sig_cfg_s::to_json(json_writer& j) const { - static const char* options[] = {"typeA", "typeB", "typeC", "typeD"}; - return convert_enum_idx(options, 4, value, "qcl_info_s::qcl_type_e_"); + j.start_obj(); + if (ssb_cfg_mob_present) { + j.write_fieldname("ssb-ConfigMobility"); + ssb_cfg_mob.to_json(j); + } + if (csi_rs_res_cfg_mob_present) { + j.write_fieldname("csi-rs-ResourceConfigMobility"); + csi_rs_res_cfg_mob.to_json(j); + } + j.end_obj(); } -// RA-Prioritization ::= SEQUENCE -SRSASN_CODE ra_prioritization_s::pack(bit_ref& bref) const +// ReportCGI ::= SEQUENCE +SRSASN_CODE report_cgi_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(scaling_factor_bi_present, 1)); - - HANDLE_CODE(pwr_ramp_step_high_prio.pack(bref)); - if (scaling_factor_bi_present) { - HANDLE_CODE(scaling_factor_bi.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, cell_for_which_to_report_cgi, (uint16_t)0u, (uint16_t)1007u)); return SRSASN_SUCCESS; } -SRSASN_CODE ra_prioritization_s::unpack(cbit_ref& bref) +SRSASN_CODE report_cgi_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(scaling_factor_bi_present, 1)); - - HANDLE_CODE(pwr_ramp_step_high_prio.unpack(bref)); - if (scaling_factor_bi_present) { - HANDLE_CODE(scaling_factor_bi.unpack(bref)); - } + HANDLE_CODE(unpack_integer(cell_for_which_to_report_cgi, bref, (uint16_t)0u, (uint16_t)1007u)); return SRSASN_SUCCESS; } -void ra_prioritization_s::to_json(json_writer& j) const +void report_cgi_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("powerRampingStepHighPriority", pwr_ramp_step_high_prio.to_string()); - if (scaling_factor_bi_present) { - j.write_str("scalingFactorBI", scaling_factor_bi.to_string()); - } + j.write_int("cellForWhichToReportCGI", cell_for_which_to_report_cgi); j.end_obj(); } -std::string ra_prioritization_s::pwr_ramp_step_high_prio_opts::to_string() const +// ReportCGI-EUTRA ::= SEQUENCE +SRSASN_CODE report_cgi_eutra_s::pack(bit_ref& bref) const { - static const char* options[] = {"dB0", "dB2", "dB4", "dB6"}; - return convert_enum_idx(options, 4, value, "ra_prioritization_s::pwr_ramp_step_high_prio_e_"); + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, cell_for_which_to_report_cgi, (uint16_t)0u, (uint16_t)503u)); + + return SRSASN_SUCCESS; } -uint8_t ra_prioritization_s::pwr_ramp_step_high_prio_opts::to_number() const +SRSASN_CODE report_cgi_eutra_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {0, 2, 4, 6}; - return map_enum_number(options, 4, value, "ra_prioritization_s::pwr_ramp_step_high_prio_e_"); + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(cell_for_which_to_report_cgi, bref, (uint16_t)0u, (uint16_t)503u)); + + return SRSASN_SUCCESS; +} +void report_cgi_eutra_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("cellForWhichToReportCGI", cell_for_which_to_report_cgi); + j.end_obj(); } -std::string ra_prioritization_s::scaling_factor_bi_opts::to_string() const +// ReportSFTD-EUTRA ::= SEQUENCE +SRSASN_CODE report_sftd_eutra_s::pack(bit_ref& bref) const { - static const char* options[] = {"zero", "dot25", "dot5", "dot75"}; - return convert_enum_idx(options, 4, value, "ra_prioritization_s::scaling_factor_bi_e_"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(report_sftd_meas, 1)); + HANDLE_CODE(bref.pack(report_rsrp, 1)); + + return SRSASN_SUCCESS; } -uint8_t ra_prioritization_s::scaling_factor_bi_opts::to_number() const +SRSASN_CODE report_sftd_eutra_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {0, 25, 5, 75}; - return map_enum_number(options, 4, value, "ra_prioritization_s::scaling_factor_bi_e_"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(report_sftd_meas, 1)); + HANDLE_CODE(bref.unpack(report_rsrp, 1)); + + return SRSASN_SUCCESS; +} +void report_sftd_eutra_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_bool("reportSFTD-Meas", report_sftd_meas); + j.write_bool("reportRSRP", report_rsrp); + j.end_obj(); } -// SRS-Resource ::= SEQUENCE -SRSASN_CODE srs_res_s::pack(bit_ref& bref) const +// ReportSFTD-NR ::= SEQUENCE +SRSASN_CODE report_sftd_nr_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ptrs_port_idx_present, 1)); - HANDLE_CODE(bref.pack(spatial_relation_info_present, 1)); + HANDLE_CODE(bref.pack(report_sftd_meas, 1)); + HANDLE_CODE(bref.pack(report_rsrp, 1)); - HANDLE_CODE(pack_integer(bref, srs_res_id, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(nrof_srs_ports.pack(bref)); - if (ptrs_port_idx_present) { - HANDLE_CODE(ptrs_port_idx.pack(bref)); - } - HANDLE_CODE(tx_comb.pack(bref)); - HANDLE_CODE(pack_integer(bref, res_map.start_position, (uint8_t)0u, (uint8_t)5u)); - HANDLE_CODE(res_map.nrof_symbols.pack(bref)); - HANDLE_CODE(res_map.repeat_factor.pack(bref)); - HANDLE_CODE(pack_integer(bref, freq_domain_position, (uint8_t)0u, (uint8_t)67u)); - HANDLE_CODE(pack_integer(bref, freq_domain_shift, (uint16_t)0u, (uint16_t)268u)); - HANDLE_CODE(pack_integer(bref, freq_hop.c_srs, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_integer(bref, freq_hop.b_srs, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pack_integer(bref, freq_hop.b_hop, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(group_or_seq_hop.pack(bref)); - HANDLE_CODE(res_type.pack(bref)); - HANDLE_CODE(pack_integer(bref, seq_id, (uint16_t)0u, (uint16_t)1023u)); - if (spatial_relation_info_present) { - HANDLE_CODE(spatial_relation_info.pack(bref)); - } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= report_sftd_neigh_meas_present; + group_flags[0] |= drx_sftd_neigh_meas_present; + group_flags[0] |= cells_for_which_to_report_sftd.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(bref.pack(report_sftd_neigh_meas_present, 1)); + HANDLE_CODE(bref.pack(drx_sftd_neigh_meas_present, 1)); + HANDLE_CODE(bref.pack(cells_for_which_to_report_sftd.is_present(), 1)); + if (cells_for_which_to_report_sftd.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *cells_for_which_to_report_sftd, 1, 3, integer_packer(0, 1007))); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE srs_res_s::unpack(cbit_ref& bref) +SRSASN_CODE report_sftd_nr_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ptrs_port_idx_present, 1)); - HANDLE_CODE(bref.unpack(spatial_relation_info_present, 1)); + HANDLE_CODE(bref.unpack(report_sftd_meas, 1)); + HANDLE_CODE(bref.unpack(report_rsrp, 1)); - HANDLE_CODE(unpack_integer(srs_res_id, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(nrof_srs_ports.unpack(bref)); - if (ptrs_port_idx_present) { - HANDLE_CODE(ptrs_port_idx.unpack(bref)); - } - HANDLE_CODE(tx_comb.unpack(bref)); - HANDLE_CODE(unpack_integer(res_map.start_position, bref, (uint8_t)0u, (uint8_t)5u)); - HANDLE_CODE(res_map.nrof_symbols.unpack(bref)); - HANDLE_CODE(res_map.repeat_factor.unpack(bref)); - HANDLE_CODE(unpack_integer(freq_domain_position, bref, (uint8_t)0u, (uint8_t)67u)); - HANDLE_CODE(unpack_integer(freq_domain_shift, bref, (uint16_t)0u, (uint16_t)268u)); - HANDLE_CODE(unpack_integer(freq_hop.c_srs, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_integer(freq_hop.b_srs, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(unpack_integer(freq_hop.b_hop, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(group_or_seq_hop.unpack(bref)); - HANDLE_CODE(res_type.unpack(bref)); - HANDLE_CODE(unpack_integer(seq_id, bref, (uint16_t)0u, (uint16_t)1023u)); - if (spatial_relation_info_present) { - HANDLE_CODE(spatial_relation_info.unpack(bref)); - } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(bref.unpack(report_sftd_neigh_meas_present, 1)); + HANDLE_CODE(bref.unpack(drx_sftd_neigh_meas_present, 1)); + bool cells_for_which_to_report_sftd_present; + HANDLE_CODE(bref.unpack(cells_for_which_to_report_sftd_present, 1)); + cells_for_which_to_report_sftd.set_present(cells_for_which_to_report_sftd_present); + if (cells_for_which_to_report_sftd.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*cells_for_which_to_report_sftd, bref, 1, 3, integer_packer(0, 1007))); + } + } + } return SRSASN_SUCCESS; } -void srs_res_s::to_json(json_writer& j) const +void report_sftd_nr_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("srs-ResourceId", srs_res_id); - j.write_str("nrofSRS-Ports", nrof_srs_ports.to_string()); - if (ptrs_port_idx_present) { - j.write_str("ptrs-PortIndex", ptrs_port_idx.to_string()); + j.write_bool("reportSFTD-Meas", report_sftd_meas); + j.write_bool("reportRSRP", report_rsrp); + if (ext) { + if (report_sftd_neigh_meas_present) { + j.write_str("reportSFTD-NeighMeas", "true"); + } + if (drx_sftd_neigh_meas_present) { + j.write_str("drx-SFTD-NeighMeas", "true"); + } + if (cells_for_which_to_report_sftd.is_present()) { + j.start_array("cellsForWhichToReportSFTD"); + for (const auto& e1 : *cells_for_which_to_report_sftd) { + j.write_int(e1); + } + j.end_array(); + } } - j.write_fieldname("transmissionComb"); - tx_comb.to_json(j); - j.write_fieldname("resourceMapping"); - j.start_obj(); - j.write_int("startPosition", res_map.start_position); - j.write_str("nrofSymbols", res_map.nrof_symbols.to_string()); - j.write_str("repetitionFactor", res_map.repeat_factor.to_string()); j.end_obj(); - j.write_int("freqDomainPosition", freq_domain_position); - j.write_int("freqDomainShift", freq_domain_shift); - j.write_fieldname("freqHopping"); +} + +// SSB-MTC2 ::= SEQUENCE +SRSASN_CODE ssb_mtc2_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(pci_list_present, 1)); + + if (pci_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, pci_list, 1, 64, integer_packer(0, 1007))); + } + HANDLE_CODE(periodicity.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE ssb_mtc2_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(pci_list_present, 1)); + + if (pci_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(pci_list, bref, 1, 64, integer_packer(0, 1007))); + } + HANDLE_CODE(periodicity.unpack(bref)); + + return SRSASN_SUCCESS; +} +void ssb_mtc2_s::to_json(json_writer& j) const +{ j.start_obj(); - j.write_int("c-SRS", freq_hop.c_srs); - j.write_int("b-SRS", freq_hop.b_srs); - j.write_int("b-hop", freq_hop.b_hop); - j.end_obj(); - j.write_str("groupOrSequenceHopping", group_or_seq_hop.to_string()); - j.write_fieldname("resourceType"); - res_type.to_json(j); - j.write_int("sequenceId", seq_id); - if (spatial_relation_info_present) { - j.write_fieldname("spatialRelationInfo"); - spatial_relation_info.to_json(j); + if (pci_list_present) { + j.start_array("pci-List"); + for (const auto& e1 : pci_list) { + j.write_int(e1); + } + j.end_array(); } + j.write_str("periodicity", periodicity.to_string()); j.end_obj(); } -std::string srs_res_s::nrof_srs_ports_opts::to_string() const +std::string ssb_mtc2_s::periodicity_opts::to_string() const { - static const char* options[] = {"port1", "ports2", "ports4"}; - return convert_enum_idx(options, 3, value, "srs_res_s::nrof_srs_ports_e_"); + static const char* options[] = {"sf5", "sf10", "sf20", "sf40", "sf80", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 8, value, "ssb_mtc2_s::periodicity_e_"); } -uint8_t srs_res_s::nrof_srs_ports_opts::to_number() const +uint8_t ssb_mtc2_s::periodicity_opts::to_number() const { - static const uint8_t options[] = {1, 2, 4}; - return map_enum_number(options, 3, value, "srs_res_s::nrof_srs_ports_e_"); + static const uint8_t options[] = {5, 10, 20, 40, 80}; + return map_enum_number(options, 5, value, "ssb_mtc2_s::periodicity_e_"); } -std::string srs_res_s::ptrs_port_idx_opts::to_string() const +// MRDC-SecondaryCellGroupConfig ::= SEQUENCE +SRSASN_CODE mrdc_secondary_cell_group_cfg_s::pack(bit_ref& bref) const { - static const char* options[] = {"n0", "n1"}; - return convert_enum_idx(options, 2, value, "srs_res_s::ptrs_port_idx_e_"); + HANDLE_CODE(bref.pack(mrdc_release_and_add_present, 1)); + + HANDLE_CODE(mrdc_secondary_cell_group.pack(bref)); + + return SRSASN_SUCCESS; } -uint8_t srs_res_s::ptrs_port_idx_opts::to_number() const +SRSASN_CODE mrdc_secondary_cell_group_cfg_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "srs_res_s::ptrs_port_idx_e_"); + HANDLE_CODE(bref.unpack(mrdc_release_and_add_present, 1)); + + HANDLE_CODE(mrdc_secondary_cell_group.unpack(bref)); + + return SRSASN_SUCCESS; +} +void mrdc_secondary_cell_group_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (mrdc_release_and_add_present) { + j.write_str("mrdc-ReleaseAndAdd", "true"); + } + j.write_fieldname("mrdc-SecondaryCellGroup"); + mrdc_secondary_cell_group.to_json(j); + j.end_obj(); } -void srs_res_s::tx_comb_c_::destroy_() +void mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::destroy_() { switch (type_) { - case types::n2: - c.destroy(); + case types::nr_scg: + c.destroy(); break; - case types::n4: - c.destroy(); + case types::eutra_scg: + c.destroy(); break; default: break; } } -void srs_res_s::tx_comb_c_::set(types::options e) +void mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::n2: - c.init(); + case types::nr_scg: + c.init(); break; - case types::n4: - c.init(); + case types::eutra_scg: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); + log_invalid_choice_id(type_, "mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_"); } } -srs_res_s::tx_comb_c_::tx_comb_c_(const srs_res_s::tx_comb_c_& other) +mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::mrdc_secondary_cell_group_c_( + const mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_& other) { type_ = other.type(); switch (type_) { - case types::n2: - c.init(other.c.get()); + case types::nr_scg: + c.init(other.c.get()); break; - case types::n4: - c.init(other.c.get()); + case types::eutra_scg: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); + log_invalid_choice_id(type_, "mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_"); } } -srs_res_s::tx_comb_c_& srs_res_s::tx_comb_c_::operator=(const srs_res_s::tx_comb_c_& other) +mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_& +mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::operator=( + const mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::n2: - c.set(other.c.get()); + case types::nr_scg: + c.set(other.c.get()); break; - case types::n4: - c.set(other.c.get()); + case types::eutra_scg: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); + log_invalid_choice_id(type_, "mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_"); } return *this; } -void srs_res_s::tx_comb_c_::to_json(json_writer& j) const +void mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::n2: - j.write_fieldname("n2"); - j.start_obj(); - j.write_int("combOffset-n2", c.get().comb_offset_n2); - j.write_int("cyclicShift-n2", c.get().cyclic_shift_n2); - j.end_obj(); + case types::nr_scg: + j.write_str("nr-SCG", c.get().to_string()); break; - case types::n4: - j.write_fieldname("n4"); - j.start_obj(); - j.write_int("combOffset-n4", c.get().comb_offset_n4); - j.write_int("cyclicShift-n4", c.get().cyclic_shift_n4); - j.end_obj(); + case types::eutra_scg: + j.write_str("eutra-SCG", c.get().to_string()); break; default: - log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); + log_invalid_choice_id(type_, "mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_"); } j.end_obj(); } -SRSASN_CODE srs_res_s::tx_comb_c_::pack(bit_ref& bref) const +SRSASN_CODE mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::n2: - HANDLE_CODE(pack_integer(bref, c.get().comb_offset_n2, (uint8_t)0u, (uint8_t)1u)); - HANDLE_CODE(pack_integer(bref, c.get().cyclic_shift_n2, (uint8_t)0u, (uint8_t)7u)); + case types::nr_scg: + HANDLE_CODE(c.get().pack(bref)); break; - case types::n4: - HANDLE_CODE(pack_integer(bref, c.get().comb_offset_n4, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pack_integer(bref, c.get().cyclic_shift_n4, (uint8_t)0u, (uint8_t)11u)); + case types::eutra_scg: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); + log_invalid_choice_id(type_, "mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE srs_res_s::tx_comb_c_::unpack(cbit_ref& bref) +SRSASN_CODE mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::n2: - HANDLE_CODE(unpack_integer(c.get().comb_offset_n2, bref, (uint8_t)0u, (uint8_t)1u)); - HANDLE_CODE(unpack_integer(c.get().cyclic_shift_n2, bref, (uint8_t)0u, (uint8_t)7u)); + case types::nr_scg: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::n4: - HANDLE_CODE(unpack_integer(c.get().comb_offset_n4, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(unpack_integer(c.get().cyclic_shift_n4, bref, (uint8_t)0u, (uint8_t)11u)); + case types::eutra_scg: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); + log_invalid_choice_id(type_, "mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string srs_res_s::tx_comb_c_::types_opts::to_string() const -{ - static const char* options[] = {"n2", "n4"}; - return convert_enum_idx(options, 2, value, "srs_res_s::tx_comb_c_::types"); -} -uint8_t srs_res_s::tx_comb_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {2, 4}; - return map_enum_number(options, 2, value, "srs_res_s::tx_comb_c_::types"); -} - -std::string srs_res_s::res_map_s_::nrof_symbols_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4"}; - return convert_enum_idx(options, 3, value, "srs_res_s::res_map_s_::nrof_symbols_e_"); -} -uint8_t srs_res_s::res_map_s_::nrof_symbols_opts::to_number() const -{ - static const uint8_t options[] = {1, 2, 4}; - return map_enum_number(options, 3, value, "srs_res_s::res_map_s_::nrof_symbols_e_"); -} - -std::string srs_res_s::res_map_s_::repeat_factor_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4"}; - return convert_enum_idx(options, 3, value, "srs_res_s::res_map_s_::repeat_factor_e_"); -} -uint8_t srs_res_s::res_map_s_::repeat_factor_opts::to_number() const +std::string mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::types_opts::to_string() const { - static const uint8_t options[] = {1, 2, 4}; - return map_enum_number(options, 3, value, "srs_res_s::res_map_s_::repeat_factor_e_"); + static const char* options[] = {"nr-SCG", "eutra-SCG"}; + return convert_enum_idx(options, 2, value, "mrdc_secondary_cell_group_cfg_s::mrdc_secondary_cell_group_c_::types"); } -std::string srs_res_s::group_or_seq_hop_opts::to_string() const +// MeasObjectEUTRA ::= SEQUENCE +SRSASN_CODE meas_obj_eutra_s::pack(bit_ref& bref) const { - static const char* options[] = {"neither", "groupHopping", "sequenceHopping"}; - return convert_enum_idx(options, 3, value, "srs_res_s::group_or_seq_hop_e_"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(cells_to_rem_list_eutran_present, 1)); + HANDLE_CODE(bref.pack(cells_to_add_mod_list_eutran_present, 1)); + HANDLE_CODE(bref.pack(black_cells_to_rem_list_eutran_present, 1)); + HANDLE_CODE(bref.pack(black_cells_to_add_mod_list_eutran_present, 1)); + HANDLE_CODE(bref.pack(eutra_q_offset_range_present, 1)); -void srs_res_s::res_type_c_::destroy_() -{ - switch (type_) { - case types::aperiodic: - c.destroy(); - break; - case types::semi_persistent: - c.destroy(); - break; - case types::periodic: - c.destroy(); - break; - default: - break; + HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(allowed_meas_bw.pack(bref)); + if (cells_to_rem_list_eutran_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_rem_list_eutran, 1, 32, integer_packer(1, 32))); } -} -void srs_res_s::res_type_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::aperiodic: - c.init(); - break; - case types::semi_persistent: - c.init(); - break; - case types::periodic: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); + if (cells_to_add_mod_list_eutran_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_add_mod_list_eutran, 1, 32)); } -} -srs_res_s::res_type_c_::res_type_c_(const srs_res_s::res_type_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::aperiodic: - c.init(other.c.get()); - break; - case types::semi_persistent: - c.init(other.c.get()); - break; - case types::periodic: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); + if (black_cells_to_rem_list_eutran_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_rem_list_eutran, 1, 32, integer_packer(1, 32))); } -} -srs_res_s::res_type_c_& srs_res_s::res_type_c_::operator=(const srs_res_s::res_type_c_& other) -{ - if (this == &other) { - return *this; + if (black_cells_to_add_mod_list_eutran_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_add_mod_list_eutran, 1, 32)); } - set(other.type()); - switch (type_) { - case types::aperiodic: - c.set(other.c.get()); - break; - case types::semi_persistent: - c.set(other.c.get()); - break; - case types::periodic: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); + HANDLE_CODE(bref.pack(eutra_presence_ant_port1, 1)); + if (eutra_q_offset_range_present) { + HANDLE_CODE(eutra_q_offset_range.pack(bref)); } + HANDLE_CODE(bref.pack(wideband_rsrq_meas, 1)); - return *this; + return SRSASN_SUCCESS; } -void srs_res_s::res_type_c_::to_json(json_writer& j) const -{ - j.start_obj(); - switch (type_) { - case types::aperiodic: - j.write_fieldname("aperiodic"); - j.start_obj(); - j.end_obj(); - break; - case types::semi_persistent: - j.write_fieldname("semi-persistent"); - j.start_obj(); - j.write_fieldname("periodicityAndOffset-sp"); - c.get().periodicity_and_offset_sp.to_json(j); - j.end_obj(); - break; - case types::periodic: - j.write_fieldname("periodic"); - j.start_obj(); - j.write_fieldname("periodicityAndOffset-p"); - c.get().periodicity_and_offset_p.to_json(j); - j.end_obj(); - break; - default: - log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); - } - j.end_obj(); -} -SRSASN_CODE srs_res_s::res_type_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::aperiodic: - bref.pack(c.get().ext, 1); - break; - case types::semi_persistent: - bref.pack(c.get().ext, 1); - HANDLE_CODE(c.get().periodicity_and_offset_sp.pack(bref)); - break; - case types::periodic: - bref.pack(c.get().ext, 1); - HANDLE_CODE(c.get().periodicity_and_offset_p.pack(bref)); - break; - default: - log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE srs_res_s::res_type_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::aperiodic: - bref.unpack(c.get().ext, 1); - break; - case types::semi_persistent: - bref.unpack(c.get().ext, 1); - HANDLE_CODE(c.get().periodicity_and_offset_sp.unpack(bref)); - break; - case types::periodic: - bref.unpack(c.get().ext, 1); - HANDLE_CODE(c.get().periodicity_and_offset_p.unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; -} - -std::string srs_res_s::res_type_c_::types_opts::to_string() const -{ - static const char* options[] = {"aperiodic", "semi-persistent", "periodic"}; - return convert_enum_idx(options, 3, value, "srs_res_s::res_type_c_::types"); -} - -// SRS-ResourceSet ::= SEQUENCE -SRSASN_CODE srs_res_set_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(srs_res_id_list_present, 1)); - HANDLE_CODE(bref.pack(alpha_present, 1)); - HANDLE_CODE(bref.pack(p0_present, 1)); - HANDLE_CODE(bref.pack(pathloss_ref_rs_present, 1)); - HANDLE_CODE(bref.pack(srs_pwr_ctrl_adjustment_states_present, 1)); - - HANDLE_CODE(pack_integer(bref, srs_res_set_id, (uint8_t)0u, (uint8_t)15u)); - if (srs_res_id_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_id_list, 1, 16, integer_packer(0, 63))); - } - HANDLE_CODE(res_type.pack(bref)); - HANDLE_CODE(usage.pack(bref)); - if (alpha_present) { - HANDLE_CODE(alpha.pack(bref)); - } - if (p0_present) { - HANDLE_CODE(pack_integer(bref, p0, (int16_t)-202, (int16_t)24)); - } - if (pathloss_ref_rs_present) { - HANDLE_CODE(pathloss_ref_rs.pack(bref)); - } - if (srs_pwr_ctrl_adjustment_states_present) { - HANDLE_CODE(srs_pwr_ctrl_adjustment_states.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE srs_res_set_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_obj_eutra_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(srs_res_id_list_present, 1)); - HANDLE_CODE(bref.unpack(alpha_present, 1)); - HANDLE_CODE(bref.unpack(p0_present, 1)); - HANDLE_CODE(bref.unpack(pathloss_ref_rs_present, 1)); - HANDLE_CODE(bref.unpack(srs_pwr_ctrl_adjustment_states_present, 1)); + HANDLE_CODE(bref.unpack(cells_to_rem_list_eutran_present, 1)); + HANDLE_CODE(bref.unpack(cells_to_add_mod_list_eutran_present, 1)); + HANDLE_CODE(bref.unpack(black_cells_to_rem_list_eutran_present, 1)); + HANDLE_CODE(bref.unpack(black_cells_to_add_mod_list_eutran_present, 1)); + HANDLE_CODE(bref.unpack(eutra_q_offset_range_present, 1)); - HANDLE_CODE(unpack_integer(srs_res_set_id, bref, (uint8_t)0u, (uint8_t)15u)); - if (srs_res_id_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(srs_res_id_list, bref, 1, 16, integer_packer(0, 63))); + HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(allowed_meas_bw.unpack(bref)); + if (cells_to_rem_list_eutran_present) { + HANDLE_CODE(unpack_dyn_seq_of(cells_to_rem_list_eutran, bref, 1, 32, integer_packer(1, 32))); } - HANDLE_CODE(res_type.unpack(bref)); - HANDLE_CODE(usage.unpack(bref)); - if (alpha_present) { - HANDLE_CODE(alpha.unpack(bref)); + if (cells_to_add_mod_list_eutran_present) { + HANDLE_CODE(unpack_dyn_seq_of(cells_to_add_mod_list_eutran, bref, 1, 32)); } - if (p0_present) { - HANDLE_CODE(unpack_integer(p0, bref, (int16_t)-202, (int16_t)24)); + if (black_cells_to_rem_list_eutran_present) { + HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_rem_list_eutran, bref, 1, 32, integer_packer(1, 32))); } - if (pathloss_ref_rs_present) { - HANDLE_CODE(pathloss_ref_rs.unpack(bref)); + if (black_cells_to_add_mod_list_eutran_present) { + HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_add_mod_list_eutran, bref, 1, 32)); } - if (srs_pwr_ctrl_adjustment_states_present) { - HANDLE_CODE(srs_pwr_ctrl_adjustment_states.unpack(bref)); + HANDLE_CODE(bref.unpack(eutra_presence_ant_port1, 1)); + if (eutra_q_offset_range_present) { + HANDLE_CODE(eutra_q_offset_range.unpack(bref)); } + HANDLE_CODE(bref.unpack(wideband_rsrq_meas, 1)); return SRSASN_SUCCESS; } -void srs_res_set_s::to_json(json_writer& j) const +void meas_obj_eutra_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("srs-ResourceSetId", srs_res_set_id); - if (srs_res_id_list_present) { - j.start_array("srs-ResourceIdList"); - for (const auto& e1 : srs_res_id_list) { + j.write_int("carrierFreq", carrier_freq); + j.write_str("allowedMeasBandwidth", allowed_meas_bw.to_string()); + if (cells_to_rem_list_eutran_present) { + j.start_array("cellsToRemoveListEUTRAN"); + for (const auto& e1 : cells_to_rem_list_eutran) { j.write_int(e1); } j.end_array(); } - j.write_fieldname("resourceType"); - res_type.to_json(j); - j.write_str("usage", usage.to_string()); - if (alpha_present) { - j.write_str("alpha", alpha.to_string()); + if (cells_to_add_mod_list_eutran_present) { + j.start_array("cellsToAddModListEUTRAN"); + for (const auto& e1 : cells_to_add_mod_list_eutran) { + e1.to_json(j); + } + j.end_array(); } - if (p0_present) { - j.write_int("p0", p0); + if (black_cells_to_rem_list_eutran_present) { + j.start_array("blackCellsToRemoveListEUTRAN"); + for (const auto& e1 : black_cells_to_rem_list_eutran) { + j.write_int(e1); + } + j.end_array(); } - if (pathloss_ref_rs_present) { - j.write_fieldname("pathlossReferenceRS"); - pathloss_ref_rs.to_json(j); + if (black_cells_to_add_mod_list_eutran_present) { + j.start_array("blackCellsToAddModListEUTRAN"); + for (const auto& e1 : black_cells_to_add_mod_list_eutran) { + e1.to_json(j); + } + j.end_array(); } - if (srs_pwr_ctrl_adjustment_states_present) { - j.write_str("srs-PowerControlAdjustmentStates", srs_pwr_ctrl_adjustment_states.to_string()); + j.write_bool("eutra-PresenceAntennaPort1", eutra_presence_ant_port1); + if (eutra_q_offset_range_present) { + j.write_str("eutra-Q-OffsetRange", eutra_q_offset_range.to_string()); } + j.write_bool("widebandRSRQ-Meas", wideband_rsrq_meas); j.end_obj(); } -void srs_res_set_s::res_type_c_::destroy_() +// MeasObjectNR ::= SEQUENCE +SRSASN_CODE meas_obj_nr_s::pack(bit_ref& bref) const { - switch (type_) { - case types::aperiodic: - c.destroy(); - break; - case types::semi_persistent: - c.destroy(); - break; - case types::periodic: - c.destroy(); - break; - default: - break; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(ssb_freq_present, 1)); + HANDLE_CODE(bref.pack(ssb_subcarrier_spacing_present, 1)); + HANDLE_CODE(bref.pack(smtc1_present, 1)); + HANDLE_CODE(bref.pack(smtc2_present, 1)); + HANDLE_CODE(bref.pack(ref_freq_csi_rs_present, 1)); + HANDLE_CODE(bref.pack(abs_thresh_ss_blocks_consolidation_present, 1)); + HANDLE_CODE(bref.pack(abs_thresh_csi_rs_consolidation_present, 1)); + HANDLE_CODE(bref.pack(nrof_ss_blocks_to_average_present, 1)); + HANDLE_CODE(bref.pack(nrof_csi_rs_res_to_average_present, 1)); + HANDLE_CODE(bref.pack(cells_to_rem_list_present, 1)); + HANDLE_CODE(bref.pack(cells_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(black_cells_to_rem_list_present, 1)); + HANDLE_CODE(bref.pack(black_cells_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(white_cells_to_rem_list_present, 1)); + HANDLE_CODE(bref.pack(white_cells_to_add_mod_list_present, 1)); + + if (ssb_freq_present) { + HANDLE_CODE(pack_integer(bref, ssb_freq, (uint32_t)0u, (uint32_t)3279165u)); } -} -void srs_res_set_s::res_type_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::aperiodic: - c.init(); - break; - case types::semi_persistent: - c.init(); - break; - case types::periodic: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); + if (ssb_subcarrier_spacing_present) { + HANDLE_CODE(ssb_subcarrier_spacing.pack(bref)); } -} -srs_res_set_s::res_type_c_::res_type_c_(const srs_res_set_s::res_type_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::aperiodic: - c.init(other.c.get()); - break; - case types::semi_persistent: - c.init(other.c.get()); - break; - case types::periodic: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); + if (smtc1_present) { + HANDLE_CODE(smtc1.pack(bref)); } -} -srs_res_set_s::res_type_c_& srs_res_set_s::res_type_c_::operator=(const srs_res_set_s::res_type_c_& other) -{ - if (this == &other) { - return *this; + if (smtc2_present) { + HANDLE_CODE(smtc2.pack(bref)); } - set(other.type()); - switch (type_) { - case types::aperiodic: - c.set(other.c.get()); - break; - case types::semi_persistent: - c.set(other.c.get()); - break; - case types::periodic: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); + if (ref_freq_csi_rs_present) { + HANDLE_CODE(pack_integer(bref, ref_freq_csi_rs, (uint32_t)0u, (uint32_t)3279165u)); } - - return *this; -} -void srs_res_set_s::res_type_c_::to_json(json_writer& j) const -{ - j.start_obj(); - switch (type_) { - case types::aperiodic: - j.write_fieldname("aperiodic"); - c.get().to_json(j); - break; - case types::semi_persistent: - j.write_fieldname("semi-persistent"); - j.start_obj(); - if (c.get().associated_csi_rs_present) { - j.write_int("associatedCSI-RS", c.get().associated_csi_rs); - } - j.end_obj(); - break; - case types::periodic: - j.write_fieldname("periodic"); - j.start_obj(); - if (c.get().associated_csi_rs_present) { - j.write_int("associatedCSI-RS", c.get().associated_csi_rs); - } - j.end_obj(); - break; - default: - log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); + HANDLE_CODE(ref_sig_cfg.pack(bref)); + if (abs_thresh_ss_blocks_consolidation_present) { + HANDLE_CODE(abs_thresh_ss_blocks_consolidation.pack(bref)); } - j.end_obj(); -} -SRSASN_CODE srs_res_set_s::res_type_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::aperiodic: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::semi_persistent: - bref.pack(c.get().ext, 1); - HANDLE_CODE(bref.pack(c.get().associated_csi_rs_present, 1)); - if (c.get().associated_csi_rs_present) { - HANDLE_CODE(pack_integer(bref, c.get().associated_csi_rs, (uint8_t)0u, (uint8_t)191u)); - } - break; - case types::periodic: - bref.pack(c.get().ext, 1); - HANDLE_CODE(bref.pack(c.get().associated_csi_rs_present, 1)); - if (c.get().associated_csi_rs_present) { - HANDLE_CODE(pack_integer(bref, c.get().associated_csi_rs, (uint8_t)0u, (uint8_t)191u)); - } - break; - default: - log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + if (abs_thresh_csi_rs_consolidation_present) { + HANDLE_CODE(abs_thresh_csi_rs_consolidation.pack(bref)); } - return SRSASN_SUCCESS; -} -SRSASN_CODE srs_res_set_s::res_type_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::aperiodic: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::semi_persistent: - bref.unpack(c.get().ext, 1); - HANDLE_CODE(bref.unpack(c.get().associated_csi_rs_present, 1)); - if (c.get().associated_csi_rs_present) { - HANDLE_CODE(unpack_integer(c.get().associated_csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); - } - break; - case types::periodic: - bref.unpack(c.get().ext, 1); - HANDLE_CODE(bref.unpack(c.get().associated_csi_rs_present, 1)); - if (c.get().associated_csi_rs_present) { - HANDLE_CODE(unpack_integer(c.get().associated_csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); - } - break; - default: - log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); - return SRSASN_ERROR_DECODE_FAIL; + if (nrof_ss_blocks_to_average_present) { + HANDLE_CODE(pack_integer(bref, nrof_ss_blocks_to_average, (uint8_t)2u, (uint8_t)16u)); } - return SRSASN_SUCCESS; -} - -SRSASN_CODE srs_res_set_s::res_type_c_::aperiodic_s_::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(csi_rs_present, 1)); - HANDLE_CODE(bref.pack(slot_offset_present, 1)); - - HANDLE_CODE(pack_integer(bref, aperiodic_srs_res_trigger, (uint8_t)1u, (uint8_t)3u)); - if (csi_rs_present) { - HANDLE_CODE(pack_integer(bref, csi_rs, (uint8_t)0u, (uint8_t)191u)); + if (nrof_csi_rs_res_to_average_present) { + HANDLE_CODE(pack_integer(bref, nrof_csi_rs_res_to_average, (uint8_t)2u, (uint8_t)16u)); } - if (slot_offset_present) { - HANDLE_CODE(pack_integer(bref, slot_offset, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(pack_integer(bref, quant_cfg_idx, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(offset_mo.pack(bref)); + if (cells_to_rem_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_rem_list, 1, 32, integer_packer(0, 1007))); + } + if (cells_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_add_mod_list, 1, 32)); + } + if (black_cells_to_rem_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_rem_list, 1, 8, integer_packer(1, 8))); + } + if (black_cells_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_add_mod_list, 1, 8)); + } + if (white_cells_to_rem_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, white_cells_to_rem_list, 1, 8, integer_packer(1, 8))); + } + if (white_cells_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, white_cells_to_add_mod_list, 1, 8)); } if (ext) { ext_groups_packer_guard group_flags; - group_flags[0] |= aperiodic_srs_res_trigger_list_v1530.is_present(); + group_flags[0] |= freq_band_ind_nr_present; + group_flags[0] |= meas_cycle_scell_present; group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(aperiodic_srs_res_trigger_list_v1530.is_present(), 1)); - if (aperiodic_srs_res_trigger_list_v1530.is_present()) { - HANDLE_CODE(pack_dyn_seq_of(bref, *aperiodic_srs_res_trigger_list_v1530, 1, 2, integer_packer(1, 3))); + HANDLE_CODE(bref.pack(freq_band_ind_nr_present, 1)); + HANDLE_CODE(bref.pack(meas_cycle_scell_present, 1)); + if (freq_band_ind_nr_present) { + HANDLE_CODE(pack_integer(bref, freq_band_ind_nr, (uint16_t)1u, (uint16_t)1024u)); + } + if (meas_cycle_scell_present) { + HANDLE_CODE(meas_cycle_scell.pack(bref)); } } } return SRSASN_SUCCESS; } -SRSASN_CODE srs_res_set_s::res_type_c_::aperiodic_s_::unpack(cbit_ref& bref) +SRSASN_CODE meas_obj_nr_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(csi_rs_present, 1)); - HANDLE_CODE(bref.unpack(slot_offset_present, 1)); + HANDLE_CODE(bref.unpack(ssb_freq_present, 1)); + HANDLE_CODE(bref.unpack(ssb_subcarrier_spacing_present, 1)); + HANDLE_CODE(bref.unpack(smtc1_present, 1)); + HANDLE_CODE(bref.unpack(smtc2_present, 1)); + HANDLE_CODE(bref.unpack(ref_freq_csi_rs_present, 1)); + HANDLE_CODE(bref.unpack(abs_thresh_ss_blocks_consolidation_present, 1)); + HANDLE_CODE(bref.unpack(abs_thresh_csi_rs_consolidation_present, 1)); + HANDLE_CODE(bref.unpack(nrof_ss_blocks_to_average_present, 1)); + HANDLE_CODE(bref.unpack(nrof_csi_rs_res_to_average_present, 1)); + HANDLE_CODE(bref.unpack(cells_to_rem_list_present, 1)); + HANDLE_CODE(bref.unpack(cells_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(black_cells_to_rem_list_present, 1)); + HANDLE_CODE(bref.unpack(black_cells_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(white_cells_to_rem_list_present, 1)); + HANDLE_CODE(bref.unpack(white_cells_to_add_mod_list_present, 1)); - HANDLE_CODE(unpack_integer(aperiodic_srs_res_trigger, bref, (uint8_t)1u, (uint8_t)3u)); - if (csi_rs_present) { - HANDLE_CODE(unpack_integer(csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); + if (ssb_freq_present) { + HANDLE_CODE(unpack_integer(ssb_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); } - if (slot_offset_present) { - HANDLE_CODE(unpack_integer(slot_offset, bref, (uint8_t)1u, (uint8_t)32u)); + if (ssb_subcarrier_spacing_present) { + HANDLE_CODE(ssb_subcarrier_spacing.unpack(bref)); + } + if (smtc1_present) { + HANDLE_CODE(smtc1.unpack(bref)); + } + if (smtc2_present) { + HANDLE_CODE(smtc2.unpack(bref)); + } + if (ref_freq_csi_rs_present) { + HANDLE_CODE(unpack_integer(ref_freq_csi_rs, bref, (uint32_t)0u, (uint32_t)3279165u)); + } + HANDLE_CODE(ref_sig_cfg.unpack(bref)); + if (abs_thresh_ss_blocks_consolidation_present) { + HANDLE_CODE(abs_thresh_ss_blocks_consolidation.unpack(bref)); + } + if (abs_thresh_csi_rs_consolidation_present) { + HANDLE_CODE(abs_thresh_csi_rs_consolidation.unpack(bref)); + } + if (nrof_ss_blocks_to_average_present) { + HANDLE_CODE(unpack_integer(nrof_ss_blocks_to_average, bref, (uint8_t)2u, (uint8_t)16u)); + } + if (nrof_csi_rs_res_to_average_present) { + HANDLE_CODE(unpack_integer(nrof_csi_rs_res_to_average, bref, (uint8_t)2u, (uint8_t)16u)); + } + HANDLE_CODE(unpack_integer(quant_cfg_idx, bref, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(offset_mo.unpack(bref)); + if (cells_to_rem_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(cells_to_rem_list, bref, 1, 32, integer_packer(0, 1007))); + } + if (cells_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(cells_to_add_mod_list, bref, 1, 32)); + } + if (black_cells_to_rem_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_rem_list, bref, 1, 8, integer_packer(1, 8))); + } + if (black_cells_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_add_mod_list, bref, 1, 8)); + } + if (white_cells_to_rem_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(white_cells_to_rem_list, bref, 1, 8, integer_packer(1, 8))); + } + if (white_cells_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(white_cells_to_add_mod_list, bref, 1, 8)); } if (ext) { @@ -12448,9536 +12398,7364 @@ SRSASN_CODE srs_res_set_s::res_type_c_::aperiodic_s_::unpack(cbit_ref& bref) if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); - bool aperiodic_srs_res_trigger_list_v1530_present; - HANDLE_CODE(bref.unpack(aperiodic_srs_res_trigger_list_v1530_present, 1)); - aperiodic_srs_res_trigger_list_v1530.set_present(aperiodic_srs_res_trigger_list_v1530_present); - if (aperiodic_srs_res_trigger_list_v1530.is_present()) { - HANDLE_CODE( - unpack_dyn_seq_of(*aperiodic_srs_res_trigger_list_v1530, bref, 1, 2, integer_packer(1, 3))); + HANDLE_CODE(bref.unpack(freq_band_ind_nr_present, 1)); + HANDLE_CODE(bref.unpack(meas_cycle_scell_present, 1)); + if (freq_band_ind_nr_present) { + HANDLE_CODE(unpack_integer(freq_band_ind_nr, bref, (uint16_t)1u, (uint16_t)1024u)); + } + if (meas_cycle_scell_present) { + HANDLE_CODE(meas_cycle_scell.unpack(bref)); } } } return SRSASN_SUCCESS; } -void srs_res_set_s::res_type_c_::aperiodic_s_::to_json(json_writer& j) const +void meas_obj_nr_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("aperiodicSRS-ResourceTrigger", aperiodic_srs_res_trigger); - if (csi_rs_present) { - j.write_int("csi-RS", csi_rs); + if (ssb_freq_present) { + j.write_int("ssbFrequency", ssb_freq); } - if (slot_offset_present) { - j.write_int("slotOffset", slot_offset); + if (ssb_subcarrier_spacing_present) { + j.write_str("ssbSubcarrierSpacing", ssb_subcarrier_spacing.to_string()); } - if (ext) { - if (aperiodic_srs_res_trigger_list_v1530.is_present()) { - j.start_array("aperiodicSRS-ResourceTriggerList-v1530"); - for (const auto& e1 : *aperiodic_srs_res_trigger_list_v1530) { - j.write_int(e1); - } - j.end_array(); - } + if (smtc1_present) { + j.write_fieldname("smtc1"); + smtc1.to_json(j); } - j.end_obj(); -} - -std::string srs_res_set_s::res_type_c_::types_opts::to_string() const -{ - static const char* options[] = {"aperiodic", "semi-persistent", "periodic"}; - return convert_enum_idx(options, 3, value, "srs_res_set_s::res_type_c_::types"); + if (smtc2_present) { + j.write_fieldname("smtc2"); + smtc2.to_json(j); + } + if (ref_freq_csi_rs_present) { + j.write_int("refFreqCSI-RS", ref_freq_csi_rs); + } + j.write_fieldname("referenceSignalConfig"); + ref_sig_cfg.to_json(j); + if (abs_thresh_ss_blocks_consolidation_present) { + j.write_fieldname("absThreshSS-BlocksConsolidation"); + abs_thresh_ss_blocks_consolidation.to_json(j); + } + if (abs_thresh_csi_rs_consolidation_present) { + j.write_fieldname("absThreshCSI-RS-Consolidation"); + abs_thresh_csi_rs_consolidation.to_json(j); + } + if (nrof_ss_blocks_to_average_present) { + j.write_int("nrofSS-BlocksToAverage", nrof_ss_blocks_to_average); + } + if (nrof_csi_rs_res_to_average_present) { + j.write_int("nrofCSI-RS-ResourcesToAverage", nrof_csi_rs_res_to_average); + } + j.write_int("quantityConfigIndex", quant_cfg_idx); + j.write_fieldname("offsetMO"); + offset_mo.to_json(j); + if (cells_to_rem_list_present) { + j.start_array("cellsToRemoveList"); + for (const auto& e1 : cells_to_rem_list) { + j.write_int(e1); + } + j.end_array(); + } + if (cells_to_add_mod_list_present) { + j.start_array("cellsToAddModList"); + for (const auto& e1 : cells_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (black_cells_to_rem_list_present) { + j.start_array("blackCellsToRemoveList"); + for (const auto& e1 : black_cells_to_rem_list) { + j.write_int(e1); + } + j.end_array(); + } + if (black_cells_to_add_mod_list_present) { + j.start_array("blackCellsToAddModList"); + for (const auto& e1 : black_cells_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (white_cells_to_rem_list_present) { + j.start_array("whiteCellsToRemoveList"); + for (const auto& e1 : white_cells_to_rem_list) { + j.write_int(e1); + } + j.end_array(); + } + if (white_cells_to_add_mod_list_present) { + j.start_array("whiteCellsToAddModList"); + for (const auto& e1 : white_cells_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (ext) { + if (freq_band_ind_nr_present) { + j.write_int("freqBandIndicatorNR", freq_band_ind_nr); + } + if (meas_cycle_scell_present) { + j.write_str("measCycleSCell", meas_cycle_scell.to_string()); + } + } + j.end_obj(); } -std::string srs_res_set_s::usage_opts::to_string() const +std::string meas_obj_nr_s::meas_cycle_scell_opts::to_string() const { - static const char* options[] = {"beamManagement", "codebook", "nonCodebook", "antennaSwitching"}; - return convert_enum_idx(options, 4, value, "srs_res_set_s::usage_e_"); + static const char* options[] = {"sf160", "sf256", "sf320", "sf512", "sf640", "sf1024", "sf1280"}; + return convert_enum_idx(options, 7, value, "meas_obj_nr_s::meas_cycle_scell_e_"); +} +uint16_t meas_obj_nr_s::meas_cycle_scell_opts::to_number() const +{ + static const uint16_t options[] = {160, 256, 320, 512, 640, 1024, 1280}; + return map_enum_number(options, 7, value, "meas_obj_nr_s::meas_cycle_scell_e_"); } -void srs_res_set_s::pathloss_ref_rs_c_::destroy_() {} -void srs_res_set_s::pathloss_ref_rs_c_::set(types::options e) +// OverheatingAssistanceConfig ::= SEQUENCE +SRSASN_CODE overheat_assist_cfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(overheat_ind_prohibit_timer.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE overheat_assist_cfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(overheat_ind_prohibit_timer.unpack(bref)); + + return SRSASN_SUCCESS; +} +void overheat_assist_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_str("overheatingIndicationProhibitTimer", overheat_ind_prohibit_timer.to_string()); + j.end_obj(); +} + +std::string overheat_assist_cfg_s::overheat_ind_prohibit_timer_opts::to_string() const +{ + static const char* options[] = {"s0", + "s0dot5", + "s1", + "s2", + "s5", + "s10", + "s20", + "s30", + "s60", + "s90", + "s120", + "s300", + "s600", + "spare3", + "spare2", + "spare1"}; + return convert_enum_idx(options, 16, value, "overheat_assist_cfg_s::overheat_ind_prohibit_timer_e_"); +} +float overheat_assist_cfg_s::overheat_ind_prohibit_timer_opts::to_number() const +{ + static const float options[] = {0.0, 0.5, 1.0, 2.0, 5.0, 10.0, 20.0, 30.0, 60.0, 90.0, 120.0, 300.0, 600.0}; + return map_enum_number(options, 13, value, "overheat_assist_cfg_s::overheat_ind_prohibit_timer_e_"); +} +std::string overheat_assist_cfg_s::overheat_ind_prohibit_timer_opts::to_number_string() const +{ + static const char* options[] = {"0", "0.5", "1", "2", "5", "10", "20", "30", "60", "90", "120", "300", "600"}; + return convert_enum_idx(options, 16, value, "overheat_assist_cfg_s::overheat_ind_prohibit_timer_e_"); +} + +// PLMN-RAN-AreaCell ::= SEQUENCE +SRSASN_CODE plmn_ran_area_cell_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(plmn_id_present, 1)); + + if (plmn_id_present) { + HANDLE_CODE(plmn_id.pack(bref)); + } + HANDLE_CODE(pack_dyn_seq_of(bref, ran_area_cells, 1, 32)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE plmn_ran_area_cell_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(plmn_id_present, 1)); + + if (plmn_id_present) { + HANDLE_CODE(plmn_id.unpack(bref)); + } + HANDLE_CODE(unpack_dyn_seq_of(ran_area_cells, bref, 1, 32)); + + return SRSASN_SUCCESS; +} +void plmn_ran_area_cell_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (plmn_id_present) { + j.write_fieldname("plmn-Identity"); + plmn_id.to_json(j); + } + j.start_array("ran-AreaCells"); + for (const auto& e1 : ran_area_cells) { + j.write_str(e1.to_string()); + } + j.end_array(); + j.end_obj(); +} + +// PLMN-RAN-AreaConfig ::= SEQUENCE +SRSASN_CODE plmn_ran_area_cfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(plmn_id_present, 1)); + + if (plmn_id_present) { + HANDLE_CODE(plmn_id.pack(bref)); + } + HANDLE_CODE(pack_dyn_seq_of(bref, ran_area, 1, 16)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE plmn_ran_area_cfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(plmn_id_present, 1)); + + if (plmn_id_present) { + HANDLE_CODE(plmn_id.unpack(bref)); + } + HANDLE_CODE(unpack_dyn_seq_of(ran_area, bref, 1, 16)); + + return SRSASN_SUCCESS; +} +void plmn_ran_area_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (plmn_id_present) { + j.write_fieldname("plmn-Identity"); + plmn_id.to_json(j); + } + j.start_array("ran-Area"); + for (const auto& e1 : ran_area) { + e1.to_json(j); + } + j.end_array(); + j.end_obj(); +} + +// QuantityConfigRS ::= SEQUENCE +SRSASN_CODE quant_cfg_rs_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(ssb_filt_cfg.pack(bref)); + HANDLE_CODE(csi_rs_filt_cfg.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE quant_cfg_rs_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(ssb_filt_cfg.unpack(bref)); + HANDLE_CODE(csi_rs_filt_cfg.unpack(bref)); + + return SRSASN_SUCCESS; +} +void quant_cfg_rs_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_fieldname("ssb-FilterConfig"); + ssb_filt_cfg.to_json(j); + j.write_fieldname("csi-RS-FilterConfig"); + csi_rs_filt_cfg.to_json(j); + j.end_obj(); +} + +// ReportConfigInterRAT ::= SEQUENCE +SRSASN_CODE report_cfg_inter_rat_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(report_type.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE report_cfg_inter_rat_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(report_type.unpack(bref)); + + return SRSASN_SUCCESS; +} +void report_cfg_inter_rat_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_fieldname("reportType"); + report_type.to_json(j); + j.end_obj(); +} + +void report_cfg_inter_rat_s::report_type_c_::destroy_() +{ + switch (type_) { + case types::periodical: + c.destroy(); + break; + case types::event_triggered: + c.destroy(); + break; + case types::report_cgi: + c.destroy(); + break; + case types::report_sftd: + c.destroy(); + break; + default: + break; + } +} +void report_cfg_inter_rat_s::report_type_c_::set(types::options e) { destroy_(); type_ = e; + switch (type_) { + case types::periodical: + c.init(); + break; + case types::event_triggered: + c.init(); + break; + case types::report_cgi: + c.init(); + break; + case types::report_sftd: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); + } } -srs_res_set_s::pathloss_ref_rs_c_::pathloss_ref_rs_c_(const srs_res_set_s::pathloss_ref_rs_c_& other) +report_cfg_inter_rat_s::report_type_c_::report_type_c_(const report_cfg_inter_rat_s::report_type_c_& other) { type_ = other.type(); switch (type_) { - case types::ssb_idx: - c.init(other.c.get()); + case types::periodical: + c.init(other.c.get()); break; - case types::csi_rs_idx: - c.init(other.c.get()); + case types::event_triggered: + c.init(other.c.get()); + break; + case types::report_cgi: + c.init(other.c.get()); + break; + case types::report_sftd: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); + log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); } } -srs_res_set_s::pathloss_ref_rs_c_& srs_res_set_s::pathloss_ref_rs_c_:: - operator=(const srs_res_set_s::pathloss_ref_rs_c_& other) +report_cfg_inter_rat_s::report_type_c_& +report_cfg_inter_rat_s::report_type_c_::operator=(const report_cfg_inter_rat_s::report_type_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb_idx: - c.set(other.c.get()); + case types::periodical: + c.set(other.c.get()); break; - case types::csi_rs_idx: - c.set(other.c.get()); + case types::event_triggered: + c.set(other.c.get()); + break; + case types::report_cgi: + c.set(other.c.get()); + break; + case types::report_sftd: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); + log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); } return *this; } -void srs_res_set_s::pathloss_ref_rs_c_::to_json(json_writer& j) const +void report_cfg_inter_rat_s::report_type_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb_idx: - j.write_int("ssb-Index", c.get()); + case types::periodical: + j.write_fieldname("periodical"); + c.get().to_json(j); break; - case types::csi_rs_idx: - j.write_int("csi-RS-Index", c.get()); + case types::event_triggered: + j.write_fieldname("eventTriggered"); + c.get().to_json(j); + break; + case types::report_cgi: + j.write_fieldname("reportCGI"); + c.get().to_json(j); + break; + case types::report_sftd: + j.write_fieldname("reportSFTD"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); + log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); } j.end_obj(); } -SRSASN_CODE srs_res_set_s::pathloss_ref_rs_c_::pack(bit_ref& bref) const +SRSASN_CODE report_cfg_inter_rat_s::report_type_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + case types::periodical: + HANDLE_CODE(c.get().pack(bref)); break; - case types::csi_rs_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + case types::event_triggered: + HANDLE_CODE(c.get().pack(bref)); break; + case types::report_cgi: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::report_sftd: { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().pack(bref)); + } break; default: - log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); + log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE srs_res_set_s::pathloss_ref_rs_c_::unpack(cbit_ref& bref) +SRSASN_CODE report_cfg_inter_rat_s::report_type_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); + case types::periodical: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::csi_rs_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + case types::event_triggered: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::report_cgi: + HANDLE_CODE(c.get().unpack(bref)); break; + case types::report_sftd: { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().unpack(bref)); + } break; default: - log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); + log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string srs_res_set_s::pathloss_ref_rs_c_::types_opts::to_string() const -{ - static const char* options[] = {"ssb-Index", "csi-RS-Index"}; - return convert_enum_idx(options, 2, value, "srs_res_set_s::pathloss_ref_rs_c_::types"); -} - -std::string srs_res_set_s::srs_pwr_ctrl_adjustment_states_opts::to_string() const -{ - static const char* options[] = {"sameAsFci2", "separateClosedLoop"}; - return convert_enum_idx(options, 2, value, "srs_res_set_s::srs_pwr_ctrl_adjustment_states_e_"); -} -uint8_t srs_res_set_s::srs_pwr_ctrl_adjustment_states_opts::to_number() const +std::string report_cfg_inter_rat_s::report_type_c_::types_opts::to_string() const { - static const uint8_t options[] = {2}; - return map_enum_number(options, 1, value, "srs_res_set_s::srs_pwr_ctrl_adjustment_states_e_"); + static const char* options[] = {"periodical", "eventTriggered", "reportCGI", "reportSFTD"}; + return convert_enum_idx(options, 4, value, "report_cfg_inter_rat_s::report_type_c_::types"); } -// SchedulingRequestResourceConfig ::= SEQUENCE -SRSASN_CODE sched_request_res_cfg_s::pack(bit_ref& bref) const +// ReportConfigNR ::= SEQUENCE +SRSASN_CODE report_cfg_nr_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); - HANDLE_CODE(bref.pack(res_present, 1)); - - HANDLE_CODE(pack_integer(bref, sched_request_res_id, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(pack_integer(bref, sched_request_id, (uint8_t)0u, (uint8_t)7u)); - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.pack(bref)); - } - if (res_present) { - HANDLE_CODE(pack_integer(bref, res, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(report_type.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE sched_request_res_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE report_cfg_nr_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); - HANDLE_CODE(bref.unpack(res_present, 1)); - - HANDLE_CODE(unpack_integer(sched_request_res_id, bref, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(unpack_integer(sched_request_id, bref, (uint8_t)0u, (uint8_t)7u)); - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.unpack(bref)); - } - if (res_present) { - HANDLE_CODE(unpack_integer(res, bref, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(report_type.unpack(bref)); return SRSASN_SUCCESS; } -void sched_request_res_cfg_s::to_json(json_writer& j) const +void report_cfg_nr_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("schedulingRequestResourceId", sched_request_res_id); - j.write_int("schedulingRequestID", sched_request_id); - if (periodicity_and_offset_present) { - j.write_fieldname("periodicityAndOffset"); - periodicity_and_offset.to_json(j); - } - if (res_present) { - j.write_int("resource", res); - } + j.write_fieldname("reportType"); + report_type.to_json(j); j.end_obj(); } -void sched_request_res_cfg_s::periodicity_and_offset_c_::destroy_() {} -void sched_request_res_cfg_s::periodicity_and_offset_c_::set(types::options e) -{ - destroy_(); - type_ = e; -} -sched_request_res_cfg_s::periodicity_and_offset_c_::periodicity_and_offset_c_( - const sched_request_res_cfg_s::periodicity_and_offset_c_& other) +void report_cfg_nr_s::report_type_c_::destroy_() { - type_ = other.type(); switch (type_) { - case types::sym2: - break; - case types::sym6or7: + case types::periodical: + c.destroy(); break; - case types::sl1: + case types::event_triggered: + c.destroy(); break; - case types::sl2: - c.init(other.c.get()); + case types::report_cgi: + c.destroy(); break; - case types::sl4: - c.init(other.c.get()); + case types::report_sftd: + c.destroy(); break; - case types::sl5: - c.init(other.c.get()); + default: break; - case types::sl8: - c.init(other.c.get()); + } +} +void report_cfg_nr_s::report_type_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::periodical: + c.init(); break; - case types::sl10: - c.init(other.c.get()); + case types::event_triggered: + c.init(); break; - case types::sl16: - c.init(other.c.get()); + case types::report_cgi: + c.init(); break; - case types::sl20: - c.init(other.c.get()); + case types::report_sftd: + c.init(); break; - case types::sl40: - c.init(other.c.get()); + case types::nulltype: break; - case types::sl80: - c.init(other.c.get()); + default: + log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); + } +} +report_cfg_nr_s::report_type_c_::report_type_c_(const report_cfg_nr_s::report_type_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::periodical: + c.init(other.c.get()); break; - case types::sl160: - c.init(other.c.get()); + case types::event_triggered: + c.init(other.c.get()); break; - case types::sl320: - c.init(other.c.get()); + case types::report_cgi: + c.init(other.c.get()); break; - case types::sl640: - c.init(other.c.get()); + case types::report_sftd: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); + log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); } } -sched_request_res_cfg_s::periodicity_and_offset_c_& sched_request_res_cfg_s::periodicity_and_offset_c_:: - operator=(const sched_request_res_cfg_s::periodicity_and_offset_c_& other) +report_cfg_nr_s::report_type_c_& +report_cfg_nr_s::report_type_c_::operator=(const report_cfg_nr_s::report_type_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::sym2: + case types::periodical: + c.set(other.c.get()); break; - case types::sym6or7: + case types::event_triggered: + c.set(other.c.get()); break; - case types::sl1: - break; - case types::sl2: - c.set(other.c.get()); - break; - case types::sl4: - c.set(other.c.get()); - break; - case types::sl5: - c.set(other.c.get()); - break; - case types::sl8: - c.set(other.c.get()); - break; - case types::sl10: - c.set(other.c.get()); - break; - case types::sl16: - c.set(other.c.get()); - break; - case types::sl20: - c.set(other.c.get()); - break; - case types::sl40: - c.set(other.c.get()); - break; - case types::sl80: - c.set(other.c.get()); - break; - case types::sl160: - c.set(other.c.get()); - break; - case types::sl320: - c.set(other.c.get()); + case types::report_cgi: + c.set(other.c.get()); break; - case types::sl640: - c.set(other.c.get()); + case types::report_sftd: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); + log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); } return *this; } -void sched_request_res_cfg_s::periodicity_and_offset_c_::to_json(json_writer& j) const +void report_cfg_nr_s::report_type_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::sym2: - break; - case types::sym6or7: - break; - case types::sl1: - break; - case types::sl2: - j.write_int("sl2", c.get()); - break; - case types::sl4: - j.write_int("sl4", c.get()); - break; - case types::sl5: - j.write_int("sl5", c.get()); - break; - case types::sl8: - j.write_int("sl8", c.get()); - break; - case types::sl10: - j.write_int("sl10", c.get()); - break; - case types::sl16: - j.write_int("sl16", c.get()); - break; - case types::sl20: - j.write_int("sl20", c.get()); - break; - case types::sl40: - j.write_int("sl40", c.get()); - break; - case types::sl80: - j.write_int("sl80", c.get()); + case types::periodical: + j.write_fieldname("periodical"); + c.get().to_json(j); break; - case types::sl160: - j.write_int("sl160", c.get()); + case types::event_triggered: + j.write_fieldname("eventTriggered"); + c.get().to_json(j); break; - case types::sl320: - j.write_int("sl320", c.get()); + case types::report_cgi: + j.write_fieldname("reportCGI"); + c.get().to_json(j); break; - case types::sl640: - j.write_int("sl640", c.get()); + case types::report_sftd: + j.write_fieldname("reportSFTD"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); + log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); } j.end_obj(); } -SRSASN_CODE sched_request_res_cfg_s::periodicity_and_offset_c_::pack(bit_ref& bref) const +SRSASN_CODE report_cfg_nr_s::report_type_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::sym2: - break; - case types::sym6or7: - break; - case types::sl1: - break; - case types::sl2: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)1u)); - break; - case types::sl4: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); - break; - case types::sl5: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); - break; - case types::sl8: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); - break; - case types::sl10: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); - break; - case types::sl16: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); - break; - case types::sl20: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); - break; - case types::sl40: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); - break; - case types::sl80: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); - break; - case types::sl160: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); - break; - case types::sl320: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + case types::periodical: + HANDLE_CODE(c.get().pack(bref)); break; - case types::sl640: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); + case types::event_triggered: + HANDLE_CODE(c.get().pack(bref)); break; + case types::report_cgi: { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().pack(bref)); + } break; + case types::report_sftd: { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().pack(bref)); + } break; default: - log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); + log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE sched_request_res_cfg_s::periodicity_and_offset_c_::unpack(cbit_ref& bref) +SRSASN_CODE report_cfg_nr_s::report_type_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::sym2: - break; - case types::sym6or7: - break; - case types::sl1: - break; - case types::sl2: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)1u)); - break; - case types::sl4: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); - break; - case types::sl5: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); - break; - case types::sl8: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); - break; - case types::sl10: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); - break; - case types::sl16: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); - break; - case types::sl20: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); - break; - case types::sl40: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); - break; - case types::sl80: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); - break; - case types::sl160: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); - break; - case types::sl320: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + case types::periodical: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::sl640: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); + case types::event_triggered: + HANDLE_CODE(c.get().unpack(bref)); break; + case types::report_cgi: { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().unpack(bref)); + } break; + case types::report_sftd: { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().unpack(bref)); + } break; default: - log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); + log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string sched_request_res_cfg_s::periodicity_and_offset_c_::types_opts::to_string() const +std::string report_cfg_nr_s::report_type_c_::types_opts::to_string() const { - static const char* options[] = {"sym2", - "sym6or7", - "sl1", - "sl2", - "sl4", - "sl5", - "sl8", - "sl10", - "sl16", - "sl20", - "sl40", - "sl80", - "sl160", - "sl320", - "sl640"}; - return convert_enum_idx(options, 15, value, "sched_request_res_cfg_s::periodicity_and_offset_c_::types"); + static const char* options[] = {"periodical", "eventTriggered", "reportCGI", "reportSFTD"}; + return convert_enum_idx(options, 4, value, "report_cfg_nr_s::report_type_c_::types"); } -// UCI-OnPUSCH ::= SEQUENCE -SRSASN_CODE uci_on_pusch_s::pack(bit_ref& bref) const +// FreqPriorityEUTRA ::= SEQUENCE +SRSASN_CODE freq_prio_eutra_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(beta_offsets_present, 1)); + HANDLE_CODE(bref.pack(cell_resel_sub_prio_present, 1)); - if (beta_offsets_present) { - HANDLE_CODE(beta_offsets.pack(bref)); + HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(pack_integer(bref, cell_resel_prio, (uint8_t)0u, (uint8_t)7u)); + if (cell_resel_sub_prio_present) { + HANDLE_CODE(cell_resel_sub_prio.pack(bref)); } - HANDLE_CODE(scaling.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE uci_on_pusch_s::unpack(cbit_ref& bref) +SRSASN_CODE freq_prio_eutra_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(beta_offsets_present, 1)); + HANDLE_CODE(bref.unpack(cell_resel_sub_prio_present, 1)); - if (beta_offsets_present) { - HANDLE_CODE(beta_offsets.unpack(bref)); + HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(unpack_integer(cell_resel_prio, bref, (uint8_t)0u, (uint8_t)7u)); + if (cell_resel_sub_prio_present) { + HANDLE_CODE(cell_resel_sub_prio.unpack(bref)); } - HANDLE_CODE(scaling.unpack(bref)); return SRSASN_SUCCESS; } -void uci_on_pusch_s::to_json(json_writer& j) const +void freq_prio_eutra_s::to_json(json_writer& j) const { j.start_obj(); - if (beta_offsets_present) { - j.write_fieldname("betaOffsets"); - beta_offsets.to_json(j); + j.write_int("carrierFreq", carrier_freq); + j.write_int("cellReselectionPriority", cell_resel_prio); + if (cell_resel_sub_prio_present) { + j.write_str("cellReselectionSubPriority", cell_resel_sub_prio.to_string()); } - j.write_str("scaling", scaling.to_string()); j.end_obj(); } -void uci_on_pusch_s::beta_offsets_c_::destroy_() +// FreqPriorityNR ::= SEQUENCE +SRSASN_CODE freq_prio_nr_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(cell_resel_sub_prio_present, 1)); + + HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)3279165u)); + HANDLE_CODE(pack_integer(bref, cell_resel_prio, (uint8_t)0u, (uint8_t)7u)); + if (cell_resel_sub_prio_present) { + HANDLE_CODE(cell_resel_sub_prio.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE freq_prio_nr_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(cell_resel_sub_prio_present, 1)); + + HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); + HANDLE_CODE(unpack_integer(cell_resel_prio, bref, (uint8_t)0u, (uint8_t)7u)); + if (cell_resel_sub_prio_present) { + HANDLE_CODE(cell_resel_sub_prio.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void freq_prio_nr_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("carrierFreq", carrier_freq); + j.write_int("cellReselectionPriority", cell_resel_prio); + if (cell_resel_sub_prio_present) { + j.write_str("cellReselectionSubPriority", cell_resel_sub_prio.to_string()); + } + j.end_obj(); +} + +// GapConfig ::= SEQUENCE +SRSASN_CODE gap_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, gap_offset, (uint8_t)0u, (uint8_t)159u)); + HANDLE_CODE(mgl.pack(bref)); + HANDLE_CODE(mgrp.pack(bref)); + HANDLE_CODE(mgta.pack(bref)); + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= ref_serv_cell_ind_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(ref_serv_cell_ind_present, 1)); + if (ref_serv_cell_ind_present) { + HANDLE_CODE(ref_serv_cell_ind.pack(bref)); + } + } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE gap_cfg_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(gap_offset, bref, (uint8_t)0u, (uint8_t)159u)); + HANDLE_CODE(mgl.unpack(bref)); + HANDLE_CODE(mgrp.unpack(bref)); + HANDLE_CODE(mgta.unpack(bref)); + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(ref_serv_cell_ind_present, 1)); + if (ref_serv_cell_ind_present) { + HANDLE_CODE(ref_serv_cell_ind.unpack(bref)); + } + } + } + return SRSASN_SUCCESS; +} +void gap_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("gapOffset", gap_offset); + j.write_str("mgl", mgl.to_string()); + j.write_str("mgrp", mgrp.to_string()); + j.write_str("mgta", mgta.to_string()); + if (ext) { + if (ref_serv_cell_ind_present) { + j.write_str("refServCellIndicator", ref_serv_cell_ind.to_string()); + } + } + j.end_obj(); +} + +std::string gap_cfg_s::mgl_opts::to_string() const +{ + static const char* options[] = {"ms1dot5", "ms3", "ms3dot5", "ms4", "ms5dot5", "ms6"}; + return convert_enum_idx(options, 6, value, "gap_cfg_s::mgl_e_"); +} +float gap_cfg_s::mgl_opts::to_number() const +{ + static const float options[] = {1.5, 3.0, 3.5, 4.0, 5.5, 6.0}; + return map_enum_number(options, 6, value, "gap_cfg_s::mgl_e_"); +} +std::string gap_cfg_s::mgl_opts::to_number_string() const +{ + static const char* options[] = {"1.5", "3", "3.5", "4", "5.5", "6"}; + return convert_enum_idx(options, 6, value, "gap_cfg_s::mgl_e_"); +} + +std::string gap_cfg_s::mgrp_opts::to_string() const +{ + static const char* options[] = {"ms20", "ms40", "ms80", "ms160"}; + return convert_enum_idx(options, 4, value, "gap_cfg_s::mgrp_e_"); +} +uint8_t gap_cfg_s::mgrp_opts::to_number() const +{ + static const uint8_t options[] = {20, 40, 80, 160}; + return map_enum_number(options, 4, value, "gap_cfg_s::mgrp_e_"); +} + +std::string gap_cfg_s::mgta_opts::to_string() const +{ + static const char* options[] = {"ms0", "ms0dot25", "ms0dot5"}; + return convert_enum_idx(options, 3, value, "gap_cfg_s::mgta_e_"); +} +float gap_cfg_s::mgta_opts::to_number() const +{ + static const float options[] = {0.0, 0.25, 0.5}; + return map_enum_number(options, 3, value, "gap_cfg_s::mgta_e_"); +} +std::string gap_cfg_s::mgta_opts::to_number_string() const +{ + static const char* options[] = {"0", "0.25", "0.5"}; + return convert_enum_idx(options, 3, value, "gap_cfg_s::mgta_e_"); +} + +std::string gap_cfg_s::ref_serv_cell_ind_opts::to_string() const +{ + static const char* options[] = {"pCell", "pSCell", "mcg-FR2"}; + return convert_enum_idx(options, 3, value, "gap_cfg_s::ref_serv_cell_ind_e_"); +} +uint8_t gap_cfg_s::ref_serv_cell_ind_opts::to_number() const +{ + if (value == mcg_fr2) { + return 2; + } + invalid_enum_number(value, "gap_cfg_s::ref_serv_cell_ind_e_"); + return 0; +} + +// MeasGapSharingScheme ::= ENUMERATED +std::string meas_gap_sharing_scheme_opts::to_string() const +{ + static const char* options[] = {"scheme00", "scheme01", "scheme10", "scheme11"}; + return convert_enum_idx(options, 4, value, "meas_gap_sharing_scheme_e"); +} +float meas_gap_sharing_scheme_opts::to_number() const +{ + static const float options[] = {0.0, 0.1, 1.0, 1.1}; + return map_enum_number(options, 4, value, "meas_gap_sharing_scheme_e"); +} +std::string meas_gap_sharing_scheme_opts::to_number_string() const +{ + static const char* options[] = {"0.0", "0.1", "1.0", "1.1"}; + return convert_enum_idx(options, 4, value, "meas_gap_sharing_scheme_e"); +} + +// MeasIdToAddMod ::= SEQUENCE +SRSASN_CODE meas_id_to_add_mod_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, meas_id, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_integer(bref, meas_obj_id, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)1u, (uint8_t)64u)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE meas_id_to_add_mod_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(meas_id, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_integer(meas_obj_id, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)1u, (uint8_t)64u)); + + return SRSASN_SUCCESS; +} +void meas_id_to_add_mod_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("measId", meas_id); + j.write_int("measObjectId", meas_obj_id); + j.write_int("reportConfigId", report_cfg_id); + j.end_obj(); +} + +// MeasObjectToAddMod ::= SEQUENCE +SRSASN_CODE meas_obj_to_add_mod_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, meas_obj_id, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(meas_obj.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE meas_obj_to_add_mod_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(meas_obj_id, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(meas_obj.unpack(bref)); + + return SRSASN_SUCCESS; +} +void meas_obj_to_add_mod_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("measObjectId", meas_obj_id); + j.write_fieldname("measObject"); + meas_obj.to_json(j); + j.end_obj(); +} + +void meas_obj_to_add_mod_s::meas_obj_c_::destroy_() { switch (type_) { - case types::dynamic_type: - c.destroy(); + case types::meas_obj_nr: + c.destroy(); break; - case types::semi_static: - c.destroy(); + case types::meas_obj_eutra: + c.destroy(); break; default: break; } } -void uci_on_pusch_s::beta_offsets_c_::set(types::options e) +void meas_obj_to_add_mod_s::meas_obj_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::dynamic_type: - c.init(); + case types::meas_obj_nr: + c.init(); break; - case types::semi_static: - c.init(); + case types::meas_obj_eutra: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); + log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); } } -uci_on_pusch_s::beta_offsets_c_::beta_offsets_c_(const uci_on_pusch_s::beta_offsets_c_& other) +meas_obj_to_add_mod_s::meas_obj_c_::meas_obj_c_(const meas_obj_to_add_mod_s::meas_obj_c_& other) { type_ = other.type(); switch (type_) { - case types::dynamic_type: - c.init(other.c.get()); + case types::meas_obj_nr: + c.init(other.c.get()); break; - case types::semi_static: - c.init(other.c.get()); + case types::meas_obj_eutra: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); + log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); } } -uci_on_pusch_s::beta_offsets_c_& uci_on_pusch_s::beta_offsets_c_:: - operator=(const uci_on_pusch_s::beta_offsets_c_& other) +meas_obj_to_add_mod_s::meas_obj_c_& +meas_obj_to_add_mod_s::meas_obj_c_::operator=(const meas_obj_to_add_mod_s::meas_obj_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::dynamic_type: - c.set(other.c.get()); + case types::meas_obj_nr: + c.set(other.c.get()); break; - case types::semi_static: - c.set(other.c.get()); + case types::meas_obj_eutra: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); + log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); } return *this; } -void uci_on_pusch_s::beta_offsets_c_::to_json(json_writer& j) const +void meas_obj_to_add_mod_s::meas_obj_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::dynamic_type: - j.start_array("dynamic"); - for (const auto& e1 : c.get()) { - e1.to_json(j); - } - j.end_array(); + case types::meas_obj_nr: + j.write_fieldname("measObjectNR"); + c.get().to_json(j); break; - case types::semi_static: - j.write_fieldname("semiStatic"); - c.get().to_json(j); + case types::meas_obj_eutra: + j.write_fieldname("measObjectEUTRA"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); + log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); } j.end_obj(); } -SRSASN_CODE uci_on_pusch_s::beta_offsets_c_::pack(bit_ref& bref) const +SRSASN_CODE meas_obj_to_add_mod_s::meas_obj_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::dynamic_type: - HANDLE_CODE(pack_fixed_seq_of(bref, &(c.get())[0], c.get().size())); - break; - case types::semi_static: - HANDLE_CODE(c.get().pack(bref)); + case types::meas_obj_nr: + HANDLE_CODE(c.get().pack(bref)); break; + case types::meas_obj_eutra: { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().pack(bref)); + } break; default: - log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); + log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE uci_on_pusch_s::beta_offsets_c_::unpack(cbit_ref& bref) +SRSASN_CODE meas_obj_to_add_mod_s::meas_obj_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::dynamic_type: - HANDLE_CODE(unpack_fixed_seq_of(&(c.get())[0], bref, c.get().size())); - break; - case types::semi_static: - HANDLE_CODE(c.get().unpack(bref)); + case types::meas_obj_nr: + HANDLE_CODE(c.get().unpack(bref)); break; + case types::meas_obj_eutra: { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().unpack(bref)); + } break; default: - log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); + log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string uci_on_pusch_s::beta_offsets_c_::types_opts::to_string() const -{ - static const char* options[] = {"dynamic", "semiStatic"}; - return convert_enum_idx(options, 2, value, "uci_on_pusch_s::beta_offsets_c_::types"); -} - -std::string uci_on_pusch_s::scaling_opts::to_string() const +std::string meas_obj_to_add_mod_s::meas_obj_c_::types_opts::to_string() const { - static const char* options[] = {"f0p5", "f0p65", "f0p8", "f1"}; - return convert_enum_idx(options, 4, value, "uci_on_pusch_s::scaling_e_"); + static const char* options[] = {"measObjectNR", "measObjectEUTRA"}; + return convert_enum_idx(options, 2, value, "meas_obj_to_add_mod_s::meas_obj_c_::types"); } -// BeamFailureRecoveryConfig ::= SEQUENCE -SRSASN_CODE beam_fail_recovery_cfg_s::pack(bit_ref& bref) const +// OtherConfig-v1540 ::= SEQUENCE +SRSASN_CODE other_cfg_v1540_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(root_seq_idx_bfr_present, 1)); - HANDLE_CODE(bref.pack(rach_cfg_bfr_present, 1)); - HANDLE_CODE(bref.pack(rsrp_thres_ssb_present, 1)); - HANDLE_CODE(bref.pack(candidate_beam_rs_list_present, 1)); - HANDLE_CODE(bref.pack(ssb_per_rach_occasion_present, 1)); - HANDLE_CODE(bref.pack(ra_ssb_occasion_mask_idx_present, 1)); - HANDLE_CODE(bref.pack(recovery_search_space_id_present, 1)); - HANDLE_CODE(bref.pack(ra_prioritization_present, 1)); - HANDLE_CODE(bref.pack(beam_fail_recovery_timer_present, 1)); + HANDLE_CODE(bref.pack(overheat_assist_cfg_present, 1)); - if (root_seq_idx_bfr_present) { - HANDLE_CODE(pack_integer(bref, root_seq_idx_bfr, (uint8_t)0u, (uint8_t)137u)); - } - if (rach_cfg_bfr_present) { - HANDLE_CODE(rach_cfg_bfr.pack(bref)); - } - if (rsrp_thres_ssb_present) { - HANDLE_CODE(pack_integer(bref, rsrp_thres_ssb, (uint8_t)0u, (uint8_t)127u)); - } - if (candidate_beam_rs_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, candidate_beam_rs_list, 1, 16)); - } - if (ssb_per_rach_occasion_present) { - HANDLE_CODE(ssb_per_rach_occasion.pack(bref)); - } - if (ra_ssb_occasion_mask_idx_present) { - HANDLE_CODE(pack_integer(bref, ra_ssb_occasion_mask_idx, (uint8_t)0u, (uint8_t)15u)); - } - if (recovery_search_space_id_present) { - HANDLE_CODE(pack_integer(bref, recovery_search_space_id, (uint8_t)0u, (uint8_t)39u)); - } - if (ra_prioritization_present) { - HANDLE_CODE(ra_prioritization.pack(bref)); - } - if (beam_fail_recovery_timer_present) { - HANDLE_CODE(beam_fail_recovery_timer.pack(bref)); + if (overheat_assist_cfg_present) { + HANDLE_CODE(overheat_assist_cfg.pack(bref)); } - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= msg1_subcarrier_spacing_v1530_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(msg1_subcarrier_spacing_v1530_present, 1)); - if (msg1_subcarrier_spacing_v1530_present) { - HANDLE_CODE(msg1_subcarrier_spacing_v1530.pack(bref)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE beam_fail_recovery_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE other_cfg_v1540_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(root_seq_idx_bfr_present, 1)); - HANDLE_CODE(bref.unpack(rach_cfg_bfr_present, 1)); - HANDLE_CODE(bref.unpack(rsrp_thres_ssb_present, 1)); - HANDLE_CODE(bref.unpack(candidate_beam_rs_list_present, 1)); - HANDLE_CODE(bref.unpack(ssb_per_rach_occasion_present, 1)); - HANDLE_CODE(bref.unpack(ra_ssb_occasion_mask_idx_present, 1)); - HANDLE_CODE(bref.unpack(recovery_search_space_id_present, 1)); - HANDLE_CODE(bref.unpack(ra_prioritization_present, 1)); - HANDLE_CODE(bref.unpack(beam_fail_recovery_timer_present, 1)); + HANDLE_CODE(bref.unpack(overheat_assist_cfg_present, 1)); - if (root_seq_idx_bfr_present) { - HANDLE_CODE(unpack_integer(root_seq_idx_bfr, bref, (uint8_t)0u, (uint8_t)137u)); - } - if (rach_cfg_bfr_present) { - HANDLE_CODE(rach_cfg_bfr.unpack(bref)); - } - if (rsrp_thres_ssb_present) { - HANDLE_CODE(unpack_integer(rsrp_thres_ssb, bref, (uint8_t)0u, (uint8_t)127u)); - } - if (candidate_beam_rs_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(candidate_beam_rs_list, bref, 1, 16)); - } - if (ssb_per_rach_occasion_present) { - HANDLE_CODE(ssb_per_rach_occasion.unpack(bref)); - } - if (ra_ssb_occasion_mask_idx_present) { - HANDLE_CODE(unpack_integer(ra_ssb_occasion_mask_idx, bref, (uint8_t)0u, (uint8_t)15u)); - } - if (recovery_search_space_id_present) { - HANDLE_CODE(unpack_integer(recovery_search_space_id, bref, (uint8_t)0u, (uint8_t)39u)); - } - if (ra_prioritization_present) { - HANDLE_CODE(ra_prioritization.unpack(bref)); - } - if (beam_fail_recovery_timer_present) { - HANDLE_CODE(beam_fail_recovery_timer.unpack(bref)); + if (overheat_assist_cfg_present) { + HANDLE_CODE(overheat_assist_cfg.unpack(bref)); } - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(msg1_subcarrier_spacing_v1530_present, 1)); - if (msg1_subcarrier_spacing_v1530_present) { - HANDLE_CODE(msg1_subcarrier_spacing_v1530.unpack(bref)); - } - } - } return SRSASN_SUCCESS; } -void beam_fail_recovery_cfg_s::to_json(json_writer& j) const +void other_cfg_v1540_s::to_json(json_writer& j) const { j.start_obj(); - if (root_seq_idx_bfr_present) { - j.write_int("rootSequenceIndex-BFR", root_seq_idx_bfr); - } - if (rach_cfg_bfr_present) { - j.write_fieldname("rach-ConfigBFR"); - rach_cfg_bfr.to_json(j); - } - if (rsrp_thres_ssb_present) { - j.write_int("rsrp-ThresholdSSB", rsrp_thres_ssb); - } - if (candidate_beam_rs_list_present) { - j.start_array("candidateBeamRSList"); - for (const auto& e1 : candidate_beam_rs_list) { - e1.to_json(j); - } - j.end_array(); - } - if (ssb_per_rach_occasion_present) { - j.write_str("ssb-perRACH-Occasion", ssb_per_rach_occasion.to_string()); - } - if (ra_ssb_occasion_mask_idx_present) { - j.write_int("ra-ssb-OccasionMaskIndex", ra_ssb_occasion_mask_idx); - } - if (recovery_search_space_id_present) { - j.write_int("recoverySearchSpaceId", recovery_search_space_id); - } - if (ra_prioritization_present) { - j.write_fieldname("ra-Prioritization"); - ra_prioritization.to_json(j); - } - if (beam_fail_recovery_timer_present) { - j.write_str("beamFailureRecoveryTimer", beam_fail_recovery_timer.to_string()); - } - if (ext) { - if (msg1_subcarrier_spacing_v1530_present) { - j.write_str("msg1-SubcarrierSpacing-v1530", msg1_subcarrier_spacing_v1530.to_string()); - } + if (overheat_assist_cfg_present) { + j.write_fieldname("overheatingAssistanceConfig"); + overheat_assist_cfg.to_json(j); } j.end_obj(); } -std::string beam_fail_recovery_cfg_s::ssb_per_rach_occasion_opts::to_string() const +// QuantityConfigNR ::= SEQUENCE +SRSASN_CODE quant_cfg_nr_s::pack(bit_ref& bref) const { - static const char* options[] = {"oneEighth", "oneFourth", "oneHalf", "one", "two", "four", "eight", "sixteen"}; - return convert_enum_idx(options, 8, value, "beam_fail_recovery_cfg_s::ssb_per_rach_occasion_e_"); + HANDLE_CODE(bref.pack(quant_cfg_rs_idx_present, 1)); + + HANDLE_CODE(quant_cfg_cell.pack(bref)); + if (quant_cfg_rs_idx_present) { + HANDLE_CODE(quant_cfg_rs_idx.pack(bref)); + } + + return SRSASN_SUCCESS; } -float beam_fail_recovery_cfg_s::ssb_per_rach_occasion_opts::to_number() const +SRSASN_CODE quant_cfg_nr_s::unpack(cbit_ref& bref) { - static const float options[] = {0.125, 0.25, 0.5, 1.0, 2.0, 4.0, 8.0, 6.0}; - return map_enum_number(options, 8, value, "beam_fail_recovery_cfg_s::ssb_per_rach_occasion_e_"); + HANDLE_CODE(bref.unpack(quant_cfg_rs_idx_present, 1)); + + HANDLE_CODE(quant_cfg_cell.unpack(bref)); + if (quant_cfg_rs_idx_present) { + HANDLE_CODE(quant_cfg_rs_idx.unpack(bref)); + } + + return SRSASN_SUCCESS; } -std::string beam_fail_recovery_cfg_s::ssb_per_rach_occasion_opts::to_number_string() const +void quant_cfg_nr_s::to_json(json_writer& j) const { - static const char* options[] = {"1/8", "1/4", "1/2", "1", "2", "4", "8", "6"}; - return convert_enum_idx(options, 8, value, "beam_fail_recovery_cfg_s::ssb_per_rach_occasion_e_"); + j.start_obj(); + j.write_fieldname("quantityConfigCell"); + quant_cfg_cell.to_json(j); + if (quant_cfg_rs_idx_present) { + j.write_fieldname("quantityConfigRS-Index"); + quant_cfg_rs_idx.to_json(j); + } + j.end_obj(); } -std::string beam_fail_recovery_cfg_s::beam_fail_recovery_timer_opts::to_string() const -{ - static const char* options[] = {"ms10", "ms20", "ms40", "ms60", "ms80", "ms100", "ms150", "ms200"}; - return convert_enum_idx(options, 8, value, "beam_fail_recovery_cfg_s::beam_fail_recovery_timer_e_"); -} -uint8_t beam_fail_recovery_cfg_s::beam_fail_recovery_timer_opts::to_number() const +// RAT-Type ::= ENUMERATED +std::string rat_type_opts::to_string() const { - static const uint8_t options[] = {10, 20, 40, 60, 80, 100, 150, 200}; - return map_enum_number(options, 8, value, "beam_fail_recovery_cfg_s::beam_fail_recovery_timer_e_"); + static const char* options[] = {"nr", "eutra-nr", "eutra", "spare1"}; + return convert_enum_idx(options, 4, value, "rat_type_e"); } -// CSI-AssociatedReportConfigInfo ::= SEQUENCE -SRSASN_CODE csi_associated_report_cfg_info_s::pack(bit_ref& bref) const +// RRCReconfiguration-v1560-IEs ::= SEQUENCE +SRSASN_CODE rrc_recfg_v1560_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(csi_im_res_for_interference_present, 1)); - HANDLE_CODE(bref.pack(nzp_csi_rs_res_for_interference_present, 1)); + HANDLE_CODE(bref.pack(mrdc_secondary_cell_group_cfg_present, 1)); + HANDLE_CODE(bref.pack(radio_bearer_cfg2_present, 1)); + HANDLE_CODE(bref.pack(sk_counter_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)0u, (uint8_t)47u)); - HANDLE_CODE(res_for_ch.pack(bref)); - if (csi_im_res_for_interference_present) { - HANDLE_CODE(pack_integer(bref, csi_im_res_for_interference, (uint8_t)1u, (uint8_t)16u)); + if (mrdc_secondary_cell_group_cfg_present) { + HANDLE_CODE(mrdc_secondary_cell_group_cfg.pack(bref)); } - if (nzp_csi_rs_res_for_interference_present) { - HANDLE_CODE(pack_integer(bref, nzp_csi_rs_res_for_interference, (uint8_t)1u, (uint8_t)16u)); + if (radio_bearer_cfg2_present) { + HANDLE_CODE(radio_bearer_cfg2.pack(bref)); + } + if (sk_counter_present) { + HANDLE_CODE(pack_integer(bref, sk_counter, (uint32_t)0u, (uint32_t)65535u)); } return SRSASN_SUCCESS; } -SRSASN_CODE csi_associated_report_cfg_info_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_recfg_v1560_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(csi_im_res_for_interference_present, 1)); - HANDLE_CODE(bref.unpack(nzp_csi_rs_res_for_interference_present, 1)); + HANDLE_CODE(bref.unpack(mrdc_secondary_cell_group_cfg_present, 1)); + HANDLE_CODE(bref.unpack(radio_bearer_cfg2_present, 1)); + HANDLE_CODE(bref.unpack(sk_counter_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)0u, (uint8_t)47u)); - HANDLE_CODE(res_for_ch.unpack(bref)); - if (csi_im_res_for_interference_present) { - HANDLE_CODE(unpack_integer(csi_im_res_for_interference, bref, (uint8_t)1u, (uint8_t)16u)); + if (mrdc_secondary_cell_group_cfg_present) { + HANDLE_CODE(mrdc_secondary_cell_group_cfg.unpack(bref)); } - if (nzp_csi_rs_res_for_interference_present) { - HANDLE_CODE(unpack_integer(nzp_csi_rs_res_for_interference, bref, (uint8_t)1u, (uint8_t)16u)); + if (radio_bearer_cfg2_present) { + HANDLE_CODE(radio_bearer_cfg2.unpack(bref)); + } + if (sk_counter_present) { + HANDLE_CODE(unpack_integer(sk_counter, bref, (uint32_t)0u, (uint32_t)65535u)); } return SRSASN_SUCCESS; } -void csi_associated_report_cfg_info_s::to_json(json_writer& j) const +void rrc_recfg_v1560_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("reportConfigId", report_cfg_id); - j.write_fieldname("resourcesForChannel"); - res_for_ch.to_json(j); - if (csi_im_res_for_interference_present) { - j.write_int("csi-IM-ResourcesForInterference", csi_im_res_for_interference); + if (mrdc_secondary_cell_group_cfg_present) { + j.write_fieldname("mrdc-SecondaryCellGroupConfig"); + mrdc_secondary_cell_group_cfg.to_json(j); } - if (nzp_csi_rs_res_for_interference_present) { - j.write_int("nzp-CSI-RS-ResourcesForInterference", nzp_csi_rs_res_for_interference); + if (radio_bearer_cfg2_present) { + j.write_str("radioBearerConfig2", radio_bearer_cfg2.to_string()); + } + if (sk_counter_present) { + j.write_int("sk-Counter", sk_counter); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -void csi_associated_report_cfg_info_s::res_for_ch_c_::destroy_() +// ReportConfigToAddMod ::= SEQUENCE +SRSASN_CODE report_cfg_to_add_mod_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(report_cfg.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE report_cfg_to_add_mod_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(report_cfg.unpack(bref)); + + return SRSASN_SUCCESS; +} +void report_cfg_to_add_mod_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("reportConfigId", report_cfg_id); + j.write_fieldname("reportConfig"); + report_cfg.to_json(j); + j.end_obj(); +} + +void report_cfg_to_add_mod_s::report_cfg_c_::destroy_() { switch (type_) { - case types::nzp_csi_rs: - c.destroy(); + case types::report_cfg_nr: + c.destroy(); + break; + case types::report_cfg_inter_rat: + c.destroy(); break; default: break; } } -void csi_associated_report_cfg_info_s::res_for_ch_c_::set(types::options e) +void report_cfg_to_add_mod_s::report_cfg_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::nzp_csi_rs: - c.init(); + case types::report_cfg_nr: + c.init(); break; - case types::csi_ssb_res_set: + case types::report_cfg_inter_rat: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); } } -csi_associated_report_cfg_info_s::res_for_ch_c_::res_for_ch_c_( - const csi_associated_report_cfg_info_s::res_for_ch_c_& other) +report_cfg_to_add_mod_s::report_cfg_c_::report_cfg_c_(const report_cfg_to_add_mod_s::report_cfg_c_& other) { type_ = other.type(); switch (type_) { - case types::nzp_csi_rs: - c.init(other.c.get()); + case types::report_cfg_nr: + c.init(other.c.get()); break; - case types::csi_ssb_res_set: - c.init(other.c.get()); + case types::report_cfg_inter_rat: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); } } -csi_associated_report_cfg_info_s::res_for_ch_c_& csi_associated_report_cfg_info_s::res_for_ch_c_:: - operator=(const csi_associated_report_cfg_info_s::res_for_ch_c_& other) +report_cfg_to_add_mod_s::report_cfg_c_& +report_cfg_to_add_mod_s::report_cfg_c_::operator=(const report_cfg_to_add_mod_s::report_cfg_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::nzp_csi_rs: - c.set(other.c.get()); + case types::report_cfg_nr: + c.set(other.c.get()); break; - case types::csi_ssb_res_set: - c.set(other.c.get()); + case types::report_cfg_inter_rat: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); } return *this; } -void csi_associated_report_cfg_info_s::res_for_ch_c_::to_json(json_writer& j) const +void report_cfg_to_add_mod_s::report_cfg_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::nzp_csi_rs: - j.write_fieldname("nzp-CSI-RS"); - j.start_obj(); - j.write_int("resourceSet", c.get().res_set); - if (c.get().qcl_info_present) { - j.start_array("qcl-info"); - for (const auto& e1 : c.get().qcl_info) { - j.write_int(e1); - } - j.end_array(); - } - j.end_obj(); + case types::report_cfg_nr: + j.write_fieldname("reportConfigNR"); + c.get().to_json(j); break; - case types::csi_ssb_res_set: - j.write_int("csi-SSB-ResourceSet", c.get()); + case types::report_cfg_inter_rat: + j.write_fieldname("reportConfigInterRAT"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); } j.end_obj(); } -SRSASN_CODE csi_associated_report_cfg_info_s::res_for_ch_c_::pack(bit_ref& bref) const +SRSASN_CODE report_cfg_to_add_mod_s::report_cfg_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::nzp_csi_rs: - HANDLE_CODE(bref.pack(c.get().qcl_info_present, 1)); - HANDLE_CODE(pack_integer(bref, c.get().res_set, (uint8_t)1u, (uint8_t)16u)); - if (c.get().qcl_info_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, c.get().qcl_info, 1, 16, integer_packer(0, 127))); - } - break; - case types::csi_ssb_res_set: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)1u)); + case types::report_cfg_nr: + HANDLE_CODE(c.get().pack(bref)); break; + case types::report_cfg_inter_rat: { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().pack(bref)); + } break; default: - log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_associated_report_cfg_info_s::res_for_ch_c_::unpack(cbit_ref& bref) +SRSASN_CODE report_cfg_to_add_mod_s::report_cfg_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::nzp_csi_rs: - HANDLE_CODE(bref.unpack(c.get().qcl_info_present, 1)); - HANDLE_CODE(unpack_integer(c.get().res_set, bref, (uint8_t)1u, (uint8_t)16u)); - if (c.get().qcl_info_present) { - HANDLE_CODE(unpack_dyn_seq_of(c.get().qcl_info, bref, 1, 16, integer_packer(0, 127))); - } - break; - case types::csi_ssb_res_set: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)1u)); + case types::report_cfg_nr: + HANDLE_CODE(c.get().unpack(bref)); break; + case types::report_cfg_inter_rat: { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get().unpack(bref)); + } break; default: - log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_associated_report_cfg_info_s::res_for_ch_c_::types_opts::to_string() const +std::string report_cfg_to_add_mod_s::report_cfg_c_::types_opts::to_string() const { - static const char* options[] = {"nzp-CSI-RS", "csi-SSB-ResourceSet"}; - return convert_enum_idx(options, 2, value, "csi_associated_report_cfg_info_s::res_for_ch_c_::types"); + static const char* options[] = {"reportConfigNR", "reportConfigInterRAT"}; + return convert_enum_idx(options, 2, value, "report_cfg_to_add_mod_s::report_cfg_c_::types"); } -// ConfiguredGrantConfig ::= SEQUENCE -SRSASN_CODE cfgured_grant_cfg_s::pack(bit_ref& bref) const +// CarrierInfoNR ::= SEQUENCE +SRSASN_CODE carrier_info_nr_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(freq_hop_present, 1)); - HANDLE_CODE(bref.pack(mcs_table_present, 1)); - HANDLE_CODE(bref.pack(mcs_table_transform_precoder_present, 1)); - HANDLE_CODE(bref.pack(uci_on_pusch_present, 1)); - HANDLE_CODE(bref.pack(rbg_size_present, 1)); - HANDLE_CODE(bref.pack(transform_precoder_present, 1)); - HANDLE_CODE(bref.pack(rep_k_rv_present, 1)); - HANDLE_CODE(bref.pack(cfgured_grant_timer_present, 1)); - HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant_present, 1)); + HANDLE_CODE(bref.pack(smtc_present, 1)); - if (freq_hop_present) { - HANDLE_CODE(freq_hop.pack(bref)); - } - HANDLE_CODE(cg_dmrs_cfg.pack(bref)); - if (mcs_table_present) { - HANDLE_CODE(mcs_table.pack(bref)); - } - if (mcs_table_transform_precoder_present) { - HANDLE_CODE(mcs_table_transform_precoder.pack(bref)); - } - if (uci_on_pusch_present) { - HANDLE_CODE(uci_on_pusch.pack(bref)); - } - HANDLE_CODE(res_alloc.pack(bref)); - HANDLE_CODE(pwr_ctrl_loop_to_use.pack(bref)); - HANDLE_CODE(pack_integer(bref, p0_pusch_alpha, (uint8_t)0u, (uint8_t)29u)); - if (transform_precoder_present) { - HANDLE_CODE(transform_precoder.pack(bref)); - } - HANDLE_CODE(pack_integer(bref, nrof_harq_processes, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(rep_k.pack(bref)); - if (rep_k_rv_present) { - HANDLE_CODE(rep_k_rv.pack(bref)); - } - HANDLE_CODE(periodicity.pack(bref)); - if (cfgured_grant_timer_present) { - HANDLE_CODE(pack_integer(bref, cfgured_grant_timer, (uint8_t)1u, (uint8_t)64u)); - } - if (rrc_cfgured_ul_grant_present) { - bref.pack(rrc_cfgured_ul_grant.ext, 1); - HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant.dmrs_seq_initization_present, 1)); - HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant.srs_res_ind_present, 1)); - HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant.freq_hop_offset_present, 1)); - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.time_domain_offset, (uint16_t)0u, (uint16_t)5119u)); - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.time_domain_alloc, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(rrc_cfgured_ul_grant.freq_domain_alloc.pack(bref)); - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.ant_port, (uint8_t)0u, (uint8_t)31u)); - if (rrc_cfgured_ul_grant.dmrs_seq_initization_present) { - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.dmrs_seq_initization, (uint8_t)0u, (uint8_t)1u)); - } - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.precoding_and_nof_layers, (uint8_t)0u, (uint8_t)63u)); - if (rrc_cfgured_ul_grant.srs_res_ind_present) { - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.srs_res_ind, (uint8_t)0u, (uint8_t)15u)); - } - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.mcs_and_tbs, (uint8_t)0u, (uint8_t)31u)); - if (rrc_cfgured_ul_grant.freq_hop_offset_present) { - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.freq_hop_offset, (uint16_t)1u, (uint16_t)274u)); - } - HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.pathloss_ref_idx, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)3279165u)); + HANDLE_CODE(ssb_subcarrier_spacing.pack(bref)); + if (smtc_present) { + HANDLE_CODE(smtc.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE cfgured_grant_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE carrier_info_nr_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(freq_hop_present, 1)); - HANDLE_CODE(bref.unpack(mcs_table_present, 1)); - HANDLE_CODE(bref.unpack(mcs_table_transform_precoder_present, 1)); - HANDLE_CODE(bref.unpack(uci_on_pusch_present, 1)); - HANDLE_CODE(bref.unpack(rbg_size_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoder_present, 1)); - HANDLE_CODE(bref.unpack(rep_k_rv_present, 1)); - HANDLE_CODE(bref.unpack(cfgured_grant_timer_present, 1)); - HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant_present, 1)); + HANDLE_CODE(bref.unpack(smtc_present, 1)); - if (freq_hop_present) { - HANDLE_CODE(freq_hop.unpack(bref)); - } - HANDLE_CODE(cg_dmrs_cfg.unpack(bref)); - if (mcs_table_present) { - HANDLE_CODE(mcs_table.unpack(bref)); - } - if (mcs_table_transform_precoder_present) { - HANDLE_CODE(mcs_table_transform_precoder.unpack(bref)); - } - if (uci_on_pusch_present) { - HANDLE_CODE(uci_on_pusch.unpack(bref)); - } - HANDLE_CODE(res_alloc.unpack(bref)); - HANDLE_CODE(pwr_ctrl_loop_to_use.unpack(bref)); - HANDLE_CODE(unpack_integer(p0_pusch_alpha, bref, (uint8_t)0u, (uint8_t)29u)); - if (transform_precoder_present) { - HANDLE_CODE(transform_precoder.unpack(bref)); - } - HANDLE_CODE(unpack_integer(nrof_harq_processes, bref, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(rep_k.unpack(bref)); - if (rep_k_rv_present) { - HANDLE_CODE(rep_k_rv.unpack(bref)); - } - HANDLE_CODE(periodicity.unpack(bref)); - if (cfgured_grant_timer_present) { - HANDLE_CODE(unpack_integer(cfgured_grant_timer, bref, (uint8_t)1u, (uint8_t)64u)); - } - if (rrc_cfgured_ul_grant_present) { - bref.unpack(rrc_cfgured_ul_grant.ext, 1); - HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant.dmrs_seq_initization_present, 1)); - HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant.srs_res_ind_present, 1)); - HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant.freq_hop_offset_present, 1)); - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.time_domain_offset, bref, (uint16_t)0u, (uint16_t)5119u)); - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.time_domain_alloc, bref, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(rrc_cfgured_ul_grant.freq_domain_alloc.unpack(bref)); - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.ant_port, bref, (uint8_t)0u, (uint8_t)31u)); - if (rrc_cfgured_ul_grant.dmrs_seq_initization_present) { - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.dmrs_seq_initization, bref, (uint8_t)0u, (uint8_t)1u)); - } - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.precoding_and_nof_layers, bref, (uint8_t)0u, (uint8_t)63u)); - if (rrc_cfgured_ul_grant.srs_res_ind_present) { - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.srs_res_ind, bref, (uint8_t)0u, (uint8_t)15u)); - } - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.mcs_and_tbs, bref, (uint8_t)0u, (uint8_t)31u)); - if (rrc_cfgured_ul_grant.freq_hop_offset_present) { - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.freq_hop_offset, bref, (uint16_t)1u, (uint16_t)274u)); - } - HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.pathloss_ref_idx, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); + HANDLE_CODE(ssb_subcarrier_spacing.unpack(bref)); + if (smtc_present) { + HANDLE_CODE(smtc.unpack(bref)); } return SRSASN_SUCCESS; } -void cfgured_grant_cfg_s::to_json(json_writer& j) const +void carrier_info_nr_s::to_json(json_writer& j) const { j.start_obj(); - if (freq_hop_present) { - j.write_str("frequencyHopping", freq_hop.to_string()); - } - j.write_fieldname("cg-DMRS-Configuration"); - cg_dmrs_cfg.to_json(j); - if (mcs_table_present) { - j.write_str("mcs-Table", mcs_table.to_string()); - } - if (mcs_table_transform_precoder_present) { - j.write_str("mcs-TableTransformPrecoder", mcs_table_transform_precoder.to_string()); - } - if (uci_on_pusch_present) { - j.write_fieldname("uci-OnPUSCH"); - uci_on_pusch.to_json(j); - } - j.write_str("resourceAllocation", res_alloc.to_string()); - if (rbg_size_present) { - j.write_str("rbg-Size", "config2"); - } - j.write_str("powerControlLoopToUse", pwr_ctrl_loop_to_use.to_string()); - j.write_int("p0-PUSCH-Alpha", p0_pusch_alpha); - if (transform_precoder_present) { - j.write_str("transformPrecoder", transform_precoder.to_string()); - } - j.write_int("nrofHARQ-Processes", nrof_harq_processes); - j.write_str("repK", rep_k.to_string()); - if (rep_k_rv_present) { - j.write_str("repK-RV", rep_k_rv.to_string()); - } - j.write_str("periodicity", periodicity.to_string()); - if (cfgured_grant_timer_present) { - j.write_int("configuredGrantTimer", cfgured_grant_timer); - } - if (rrc_cfgured_ul_grant_present) { - j.write_fieldname("rrc-ConfiguredUplinkGrant"); - j.start_obj(); - j.write_int("timeDomainOffset", rrc_cfgured_ul_grant.time_domain_offset); - j.write_int("timeDomainAllocation", rrc_cfgured_ul_grant.time_domain_alloc); - j.write_str("frequencyDomainAllocation", rrc_cfgured_ul_grant.freq_domain_alloc.to_string()); - j.write_int("antennaPort", rrc_cfgured_ul_grant.ant_port); - if (rrc_cfgured_ul_grant.dmrs_seq_initization_present) { - j.write_int("dmrs-SeqInitialization", rrc_cfgured_ul_grant.dmrs_seq_initization); - } - j.write_int("precodingAndNumberOfLayers", rrc_cfgured_ul_grant.precoding_and_nof_layers); - if (rrc_cfgured_ul_grant.srs_res_ind_present) { - j.write_int("srs-ResourceIndicator", rrc_cfgured_ul_grant.srs_res_ind); - } - j.write_int("mcsAndTBS", rrc_cfgured_ul_grant.mcs_and_tbs); - if (rrc_cfgured_ul_grant.freq_hop_offset_present) { - j.write_int("frequencyHoppingOffset", rrc_cfgured_ul_grant.freq_hop_offset); - } - j.write_int("pathlossReferenceIndex", rrc_cfgured_ul_grant.pathloss_ref_idx); - j.end_obj(); + j.write_int("carrierFreq", carrier_freq); + j.write_str("ssbSubcarrierSpacing", ssb_subcarrier_spacing.to_string()); + if (smtc_present) { + j.write_fieldname("smtc"); + smtc.to_json(j); } j.end_obj(); } -std::string cfgured_grant_cfg_s::freq_hop_opts::to_string() const -{ - static const char* options[] = {"intraSlot", "interSlot"}; - return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::freq_hop_e_"); -} - -std::string cfgured_grant_cfg_s::mcs_table_opts::to_string() const -{ - static const char* options[] = {"qam256", "qam64LowSE"}; - return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::mcs_table_e_"); -} -uint16_t cfgured_grant_cfg_s::mcs_table_opts::to_number() const +// DRB-CountMSB-Info ::= SEQUENCE +SRSASN_CODE drb_count_msb_info_s::pack(bit_ref& bref) const { - static const uint16_t options[] = {256, 64}; - return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::mcs_table_e_"); -} + HANDLE_CODE(pack_integer(bref, drb_id, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(pack_integer(bref, count_msb_ul, (uint32_t)0u, (uint32_t)33554431u)); + HANDLE_CODE(pack_integer(bref, count_msb_dl, (uint32_t)0u, (uint32_t)33554431u)); -std::string cfgured_grant_cfg_s::mcs_table_transform_precoder_opts::to_string() const -{ - static const char* options[] = {"qam256", "qam64LowSE"}; - return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::mcs_table_transform_precoder_e_"); + return SRSASN_SUCCESS; } -uint16_t cfgured_grant_cfg_s::mcs_table_transform_precoder_opts::to_number() const +SRSASN_CODE drb_count_msb_info_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {256, 64}; - return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::mcs_table_transform_precoder_e_"); -} + HANDLE_CODE(unpack_integer(drb_id, bref, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(unpack_integer(count_msb_ul, bref, (uint32_t)0u, (uint32_t)33554431u)); + HANDLE_CODE(unpack_integer(count_msb_dl, bref, (uint32_t)0u, (uint32_t)33554431u)); -std::string cfgured_grant_cfg_s::res_alloc_opts::to_string() const -{ - static const char* options[] = {"resourceAllocationType0", "resourceAllocationType1", "dynamicSwitch"}; - return convert_enum_idx(options, 3, value, "cfgured_grant_cfg_s::res_alloc_e_"); + return SRSASN_SUCCESS; } -uint8_t cfgured_grant_cfg_s::res_alloc_opts::to_number() const +void drb_count_msb_info_s::to_json(json_writer& j) const { - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::res_alloc_e_"); + j.start_obj(); + j.write_int("drb-Identity", drb_id); + j.write_int("countMSB-Uplink", count_msb_ul); + j.write_int("countMSB-Downlink", count_msb_dl); + j.end_obj(); } -std::string cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_opts::to_string() const -{ - static const char* options[] = {"n0", "n1"}; - return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_e_"); -} -uint8_t cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_opts::to_number() const +// MasterKeyUpdate ::= SEQUENCE +SRSASN_CODE master_key_upd_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_e_"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(nas_container_present, 1)); -std::string cfgured_grant_cfg_s::transform_precoder_opts::to_string() const -{ - static const char* options[] = {"enabled", "disabled"}; - return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::transform_precoder_e_"); -} + HANDLE_CODE(bref.pack(key_set_change_ind, 1)); + HANDLE_CODE(pack_integer(bref, next_hop_chaining_count, (uint8_t)0u, (uint8_t)7u)); + if (nas_container_present) { + HANDLE_CODE(nas_container.pack(bref)); + } -std::string cfgured_grant_cfg_s::rep_k_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4", "n8"}; - return convert_enum_idx(options, 4, value, "cfgured_grant_cfg_s::rep_k_e_"); + return SRSASN_SUCCESS; } -uint8_t cfgured_grant_cfg_s::rep_k_opts::to_number() const +SRSASN_CODE master_key_upd_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {1, 2, 4, 8}; - return map_enum_number(options, 4, value, "cfgured_grant_cfg_s::rep_k_e_"); -} + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(nas_container_present, 1)); -std::string cfgured_grant_cfg_s::rep_k_rv_opts::to_string() const -{ - static const char* options[] = {"s1-0231", "s2-0303", "s3-0000"}; - return convert_enum_idx(options, 3, value, "cfgured_grant_cfg_s::rep_k_rv_e_"); -} -uint8_t cfgured_grant_cfg_s::rep_k_rv_opts::to_number() const -{ - static const uint8_t options[] = {1, 2, 3}; - return map_enum_number(options, 3, value, "cfgured_grant_cfg_s::rep_k_rv_e_"); -} + HANDLE_CODE(bref.unpack(key_set_change_ind, 1)); + HANDLE_CODE(unpack_integer(next_hop_chaining_count, bref, (uint8_t)0u, (uint8_t)7u)); + if (nas_container_present) { + HANDLE_CODE(nas_container.unpack(bref)); + } -std::string cfgured_grant_cfg_s::periodicity_opts::to_string() const + return SRSASN_SUCCESS; +} +void master_key_upd_s::to_json(json_writer& j) const { - static const char* options[] = { - "sym2", "sym7", "sym1x14", "sym2x14", "sym4x14", "sym5x14", "sym8x14", "sym10x14", - "sym16x14", "sym20x14", "sym32x14", "sym40x14", "sym64x14", "sym80x14", "sym128x14", "sym160x14", - "sym256x14", "sym320x14", "sym512x14", "sym640x14", "sym1024x14", "sym1280x14", "sym2560x14", "sym5120x14", - "sym6", "sym1x12", "sym2x12", "sym4x12", "sym5x12", "sym8x12", "sym10x12", "sym16x12", - "sym20x12", "sym32x12", "sym40x12", "sym64x12", "sym80x12", "sym128x12", "sym160x12", "sym256x12", - "sym320x12", "sym512x12", "sym640x12", "sym1280x12", "sym2560x12"}; - return convert_enum_idx(options, 45, value, "cfgured_grant_cfg_s::periodicity_e_"); + j.start_obj(); + j.write_bool("keySetChangeIndicator", key_set_change_ind); + j.write_int("nextHopChainingCount", next_hop_chaining_count); + if (nas_container_present) { + j.write_str("nas-Container", nas_container.to_string()); + } + j.end_obj(); } -// DMRS-DownlinkConfig ::= SEQUENCE -SRSASN_CODE dmrs_dl_cfg_s::pack(bit_ref& bref) const +// MeasGapConfig ::= SEQUENCE +SRSASN_CODE meas_gap_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(dmrs_type_present, 1)); - HANDLE_CODE(bref.pack(dmrs_add_position_present, 1)); - HANDLE_CODE(bref.pack(max_len_present, 1)); - HANDLE_CODE(bref.pack(scrambling_id0_present, 1)); - HANDLE_CODE(bref.pack(scrambling_id1_present, 1)); - HANDLE_CODE(bref.pack(phase_tracking_rs_present, 1)); + HANDLE_CODE(bref.pack(gap_fr2_present, 1)); - if (dmrs_add_position_present) { - HANDLE_CODE(dmrs_add_position.pack(bref)); - } - if (scrambling_id0_present) { - HANDLE_CODE(pack_integer(bref, scrambling_id0, (uint32_t)0u, (uint32_t)65535u)); - } - if (scrambling_id1_present) { - HANDLE_CODE(pack_integer(bref, scrambling_id1, (uint32_t)0u, (uint32_t)65535u)); - } - if (phase_tracking_rs_present) { - HANDLE_CODE(phase_tracking_rs.pack(bref)); + if (gap_fr2_present) { + HANDLE_CODE(gap_fr2.pack(bref)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= gap_fr1.is_present(); + group_flags[0] |= gap_ue.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(gap_fr1.is_present(), 1)); + HANDLE_CODE(bref.pack(gap_ue.is_present(), 1)); + if (gap_fr1.is_present()) { + HANDLE_CODE(gap_fr1->pack(bref)); + } + if (gap_ue.is_present()) { + HANDLE_CODE(gap_ue->pack(bref)); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE dmrs_dl_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_gap_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(dmrs_type_present, 1)); - HANDLE_CODE(bref.unpack(dmrs_add_position_present, 1)); - HANDLE_CODE(bref.unpack(max_len_present, 1)); - HANDLE_CODE(bref.unpack(scrambling_id0_present, 1)); - HANDLE_CODE(bref.unpack(scrambling_id1_present, 1)); - HANDLE_CODE(bref.unpack(phase_tracking_rs_present, 1)); + HANDLE_CODE(bref.unpack(gap_fr2_present, 1)); - if (dmrs_add_position_present) { - HANDLE_CODE(dmrs_add_position.unpack(bref)); - } - if (scrambling_id0_present) { - HANDLE_CODE(unpack_integer(scrambling_id0, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (scrambling_id1_present) { - HANDLE_CODE(unpack_integer(scrambling_id1, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (phase_tracking_rs_present) { - HANDLE_CODE(phase_tracking_rs.unpack(bref)); + if (gap_fr2_present) { + HANDLE_CODE(gap_fr2.unpack(bref)); } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool gap_fr1_present; + HANDLE_CODE(bref.unpack(gap_fr1_present, 1)); + gap_fr1.set_present(gap_fr1_present); + bool gap_ue_present; + HANDLE_CODE(bref.unpack(gap_ue_present, 1)); + gap_ue.set_present(gap_ue_present); + if (gap_fr1.is_present()) { + HANDLE_CODE(gap_fr1->unpack(bref)); + } + if (gap_ue.is_present()) { + HANDLE_CODE(gap_ue->unpack(bref)); + } + } + } return SRSASN_SUCCESS; } -void dmrs_dl_cfg_s::to_json(json_writer& j) const +void meas_gap_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (dmrs_type_present) { - j.write_str("dmrs-Type", "type2"); - } - if (dmrs_add_position_present) { - j.write_str("dmrs-AdditionalPosition", dmrs_add_position.to_string()); - } - if (max_len_present) { - j.write_str("maxLength", "len2"); - } - if (scrambling_id0_present) { - j.write_int("scramblingID0", scrambling_id0); - } - if (scrambling_id1_present) { - j.write_int("scramblingID1", scrambling_id1); + if (gap_fr2_present) { + j.write_fieldname("gapFR2"); + gap_fr2.to_json(j); } - if (phase_tracking_rs_present) { - j.write_fieldname("phaseTrackingRS"); - phase_tracking_rs.to_json(j); + if (ext) { + if (gap_fr1.is_present()) { + j.write_fieldname("gapFR1"); + gap_fr1->to_json(j); + } + if (gap_ue.is_present()) { + j.write_fieldname("gapUE"); + gap_ue->to_json(j); + } } j.end_obj(); } -std::string dmrs_dl_cfg_s::dmrs_add_position_opts::to_string() const -{ - static const char* options[] = {"pos0", "pos1", "pos3"}; - return convert_enum_idx(options, 3, value, "dmrs_dl_cfg_s::dmrs_add_position_e_"); -} -uint8_t dmrs_dl_cfg_s::dmrs_add_position_opts::to_number() const -{ - static const uint8_t options[] = {0, 1, 3}; - return map_enum_number(options, 3, value, "dmrs_dl_cfg_s::dmrs_add_position_e_"); -} - -// DownlinkPreemption ::= SEQUENCE -SRSASN_CODE dl_preemption_s::pack(bit_ref& bref) const +// MeasGapSharingConfig ::= SEQUENCE +SRSASN_CODE meas_gap_sharing_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, int_rnti, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(time_freq_set.pack(bref)); - HANDLE_CODE(pack_integer(bref, dci_payload_size, (uint8_t)0u, (uint8_t)126u)); - HANDLE_CODE(pack_dyn_seq_of(bref, int_cfg_per_serving_cell, 1, 32)); + HANDLE_CODE(bref.pack(gap_sharing_fr2_present, 1)); + + if (gap_sharing_fr2_present) { + HANDLE_CODE(gap_sharing_fr2.pack(bref)); + } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= gap_sharing_fr1.is_present(); + group_flags[0] |= gap_sharing_ue.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(gap_sharing_fr1.is_present(), 1)); + HANDLE_CODE(bref.pack(gap_sharing_ue.is_present(), 1)); + if (gap_sharing_fr1.is_present()) { + HANDLE_CODE(gap_sharing_fr1->pack(bref)); + } + if (gap_sharing_ue.is_present()) { + HANDLE_CODE(gap_sharing_ue->pack(bref)); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE dl_preemption_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_gap_sharing_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(int_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(time_freq_set.unpack(bref)); - HANDLE_CODE(unpack_integer(dci_payload_size, bref, (uint8_t)0u, (uint8_t)126u)); - HANDLE_CODE(unpack_dyn_seq_of(int_cfg_per_serving_cell, bref, 1, 32)); + HANDLE_CODE(bref.unpack(gap_sharing_fr2_present, 1)); + + if (gap_sharing_fr2_present) { + HANDLE_CODE(gap_sharing_fr2.unpack(bref)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + bool gap_sharing_fr1_present; + HANDLE_CODE(bref.unpack(gap_sharing_fr1_present, 1)); + gap_sharing_fr1.set_present(gap_sharing_fr1_present); + bool gap_sharing_ue_present; + HANDLE_CODE(bref.unpack(gap_sharing_ue_present, 1)); + gap_sharing_ue.set_present(gap_sharing_ue_present); + if (gap_sharing_fr1.is_present()) { + HANDLE_CODE(gap_sharing_fr1->unpack(bref)); + } + if (gap_sharing_ue.is_present()) { + HANDLE_CODE(gap_sharing_ue->unpack(bref)); + } + } + } return SRSASN_SUCCESS; } -void dl_preemption_s::to_json(json_writer& j) const +void meas_gap_sharing_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("int-RNTI", int_rnti); - j.write_str("timeFrequencySet", time_freq_set.to_string()); - j.write_int("dci-PayloadSize", dci_payload_size); - j.start_array("int-ConfigurationPerServingCell"); - for (const auto& e1 : int_cfg_per_serving_cell) { - e1.to_json(j); + if (gap_sharing_fr2_present) { + j.write_fieldname("gapSharingFR2"); + gap_sharing_fr2.to_json(j); + } + if (ext) { + if (gap_sharing_fr1.is_present()) { + j.write_fieldname("gapSharingFR1"); + gap_sharing_fr1->to_json(j); + } + if (gap_sharing_ue.is_present()) { + j.write_fieldname("gapSharingUE"); + gap_sharing_ue->to_json(j); + } } - j.end_array(); j.end_obj(); } -std::string dl_preemption_s::time_freq_set_opts::to_string() const -{ - static const char* options[] = {"set0", "set1"}; - return convert_enum_idx(options, 2, value, "dl_preemption_s::time_freq_set_e_"); -} -uint8_t dl_preemption_s::time_freq_set_opts::to_number() const -{ - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "dl_preemption_s::time_freq_set_e_"); -} - -// EUTRA-MBSFN-SubframeConfig ::= SEQUENCE -SRSASN_CODE eutra_mbsfn_sf_cfg_s::pack(bit_ref& bref) const +// OtherConfig ::= SEQUENCE +SRSASN_CODE other_cfg_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(sf_alloc2_present, 1)); + HANDLE_CODE(bref.pack(delay_budget_report_cfg_present, 1)); - HANDLE_CODE(radioframe_alloc_period.pack(bref)); - HANDLE_CODE(pack_integer(bref, radioframe_alloc_offset, (uint8_t)0u, (uint8_t)7u)); - HANDLE_CODE(sf_alloc1.pack(bref)); - if (sf_alloc2_present) { - HANDLE_CODE(sf_alloc2.pack(bref)); + if (delay_budget_report_cfg_present) { + HANDLE_CODE(delay_budget_report_cfg.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE eutra_mbsfn_sf_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE other_cfg_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(sf_alloc2_present, 1)); + HANDLE_CODE(bref.unpack(delay_budget_report_cfg_present, 1)); - HANDLE_CODE(radioframe_alloc_period.unpack(bref)); - HANDLE_CODE(unpack_integer(radioframe_alloc_offset, bref, (uint8_t)0u, (uint8_t)7u)); - HANDLE_CODE(sf_alloc1.unpack(bref)); - if (sf_alloc2_present) { - HANDLE_CODE(sf_alloc2.unpack(bref)); + if (delay_budget_report_cfg_present) { + HANDLE_CODE(delay_budget_report_cfg.unpack(bref)); } return SRSASN_SUCCESS; } -void eutra_mbsfn_sf_cfg_s::to_json(json_writer& j) const +void other_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("radioframeAllocationPeriod", radioframe_alloc_period.to_string()); - j.write_int("radioframeAllocationOffset", radioframe_alloc_offset); - j.write_fieldname("subframeAllocation1"); - sf_alloc1.to_json(j); - if (sf_alloc2_present) { - j.write_fieldname("subframeAllocation2"); - sf_alloc2.to_json(j); + if (delay_budget_report_cfg_present) { + j.write_fieldname("delayBudgetReportingConfig"); + delay_budget_report_cfg.to_json(j); } j.end_obj(); } -std::string eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4", "n8", "n16", "n32"}; - return convert_enum_idx(options, 6, value, "eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_e_"); -} -uint8_t eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_opts::to_number() const +void other_cfg_s::delay_budget_report_cfg_c_::set(types::options e) { - static const uint8_t options[] = {1, 2, 4, 8, 16, 32}; - return map_enum_number(options, 6, value, "eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_e_"); + type_ = e; } - -void eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::destroy_() +void other_cfg_s::delay_budget_report_cfg_c_::to_json(json_writer& j) const { + j.start_obj(); switch (type_) { - case types::one_frame: - c.destroy >(); + case types::release: break; - case types::four_frames: - c.destroy >(); + case types::setup: + j.write_fieldname("setup"); + j.start_obj(); + j.write_str("delayBudgetReportingProhibitTimer", c.delay_budget_report_prohibit_timer.to_string()); + j.end_obj(); break; default: - break; + log_invalid_choice_id(type_, "other_cfg_s::delay_budget_report_cfg_c_"); } + j.end_obj(); } -void eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::set(types::options e) +SRSASN_CODE other_cfg_s::delay_budget_report_cfg_c_::pack(bit_ref& bref) const { - destroy_(); - type_ = e; + type_.pack(bref); switch (type_) { - case types::one_frame: - c.init >(); - break; - case types::four_frames: - c.init >(); + case types::release: break; - case types::nulltype: + case types::setup: + HANDLE_CODE(c.delay_budget_report_prohibit_timer.pack(bref)); break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); + log_invalid_choice_id(type_, "other_cfg_s::delay_budget_report_cfg_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } + return SRSASN_SUCCESS; } -eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::sf_alloc1_c_(const eutra_mbsfn_sf_cfg_s::sf_alloc1_c_& other) +SRSASN_CODE other_cfg_s::delay_budget_report_cfg_c_::unpack(cbit_ref& bref) { - type_ = other.type(); + types e; + e.unpack(bref); + set(e); switch (type_) { - case types::one_frame: - c.init(other.c.get >()); - break; - case types::four_frames: - c.init(other.c.get >()); + case types::release: break; - case types::nulltype: + case types::setup: + HANDLE_CODE(c.delay_budget_report_prohibit_timer.unpack(bref)); break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); + log_invalid_choice_id(type_, "other_cfg_s::delay_budget_report_cfg_c_"); + return SRSASN_ERROR_DECODE_FAIL; } + return SRSASN_SUCCESS; } -eutra_mbsfn_sf_cfg_s::sf_alloc1_c_& eutra_mbsfn_sf_cfg_s::sf_alloc1_c_:: - operator=(const eutra_mbsfn_sf_cfg_s::sf_alloc1_c_& other) + +std::string +other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_opts::to_string() const { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::one_frame: - c.set(other.c.get >()); - break; - case types::four_frames: - c.set(other.c.get >()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); - } + static const char* options[] = {"s0", "s0dot4", "s0dot8", "s1dot6", "s3", "s6", "s12", "s30"}; + return convert_enum_idx( + options, 8, value, "other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_e_"); +} +float other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_opts::to_number() const +{ + static const float options[] = {0.0, 0.4, 0.8, 1.6, 3.0, 6.0, 12.0, 30.0}; + return map_enum_number( + options, 8, value, "other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_e_"); +} +std::string +other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_opts::to_number_string() const +{ + static const char* options[] = {"0", "0.4", "0.8", "1.6", "3", "6", "12", "30"}; + return convert_enum_idx( + options, 8, value, "other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_e_"); +} - return *this; +std::string other_cfg_s::delay_budget_report_cfg_c_::types_opts::to_string() const +{ + static const char* options[] = {"release", "setup"}; + return convert_enum_idx(options, 2, value, "other_cfg_s::delay_budget_report_cfg_c_::types"); } -void eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::to_json(json_writer& j) const + +// PeriodicRNAU-TimerValue ::= ENUMERATED +std::string periodic_rnau_timer_value_opts::to_string() const { - j.start_obj(); - switch (type_) { - case types::one_frame: - j.write_str("oneFrame", c.get >().to_string()); - break; - case types::four_frames: - j.write_str("fourFrames", c.get >().to_string()); - break; - default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); - } - j.end_obj(); + static const char* options[] = {"min5", "min10", "min20", "min30", "min60", "min120", "min360", "min720"}; + return convert_enum_idx(options, 8, value, "periodic_rnau_timer_value_e"); } -SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::pack(bit_ref& bref) const +uint16_t periodic_rnau_timer_value_opts::to_number() const { - type_.pack(bref); - switch (type_) { - case types::one_frame: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::four_frames: - HANDLE_CODE(c.get >().pack(bref)); - break; - default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const uint16_t options[] = {5, 10, 20, 30, 60, 120, 360, 720}; + return map_enum_number(options, 8, value, "periodic_rnau_timer_value_e"); } -SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::unpack(cbit_ref& bref) + +// QuantityConfig ::= SEQUENCE +SRSASN_CODE quant_cfg_s::pack(bit_ref& bref) const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::one_frame: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_frames: - HANDLE_CODE(c.get >().unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); - return SRSASN_ERROR_DECODE_FAIL; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(quant_cfg_nr_list_present, 1)); + + if (quant_cfg_nr_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, quant_cfg_nr_list, 1, 2)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= quant_cfg_eutra.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(quant_cfg_eutra.is_present(), 1)); + if (quant_cfg_eutra.is_present()) { + HANDLE_CODE(quant_cfg_eutra->pack(bref)); + } + } } return SRSASN_SUCCESS; } - -std::string eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types_opts::to_string() const +SRSASN_CODE quant_cfg_s::unpack(cbit_ref& bref) { - static const char* options[] = {"oneFrame", "fourFrames"}; - return convert_enum_idx(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(quant_cfg_nr_list_present, 1)); + + if (quant_cfg_nr_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(quant_cfg_nr_list, bref, 1, 2)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool quant_cfg_eutra_present; + HANDLE_CODE(bref.unpack(quant_cfg_eutra_present, 1)); + quant_cfg_eutra.set_present(quant_cfg_eutra_present); + if (quant_cfg_eutra.is_present()) { + HANDLE_CODE(quant_cfg_eutra->unpack(bref)); + } + } + } + return SRSASN_SUCCESS; } -uint8_t eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types_opts::to_number() const +void quant_cfg_s::to_json(json_writer& j) const { - static const uint8_t options[] = {1, 4}; - return map_enum_number(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types"); + j.start_obj(); + if (quant_cfg_nr_list_present) { + j.start_array("quantityConfigNR-List"); + for (const auto& e1 : quant_cfg_nr_list) { + e1.to_json(j); + } + j.end_array(); + } + if (ext) { + if (quant_cfg_eutra.is_present()) { + j.write_fieldname("quantityConfigEUTRA"); + quant_cfg_eutra->to_json(j); + } + } + j.end_obj(); } -void eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::destroy_() +// RAN-NotificationAreaInfo ::= CHOICE +void ran_notif_area_info_c::destroy_() { switch (type_) { - case types::one_frame: - c.destroy >(); + case types::cell_list: + c.destroy(); break; - case types::four_frames: - c.destroy >(); + case types::ran_area_cfg_list: + c.destroy(); break; default: break; } } -void eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::set(types::options e) +void ran_notif_area_info_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::one_frame: - c.init >(); + case types::cell_list: + c.init(); break; - case types::four_frames: - c.init >(); + case types::ran_area_cfg_list: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); + log_invalid_choice_id(type_, "ran_notif_area_info_c"); } } -eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::sf_alloc2_c_(const eutra_mbsfn_sf_cfg_s::sf_alloc2_c_& other) +ran_notif_area_info_c::ran_notif_area_info_c(const ran_notif_area_info_c& other) { type_ = other.type(); switch (type_) { - case types::one_frame: - c.init(other.c.get >()); + case types::cell_list: + c.init(other.c.get()); break; - case types::four_frames: - c.init(other.c.get >()); + case types::ran_area_cfg_list: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); + log_invalid_choice_id(type_, "ran_notif_area_info_c"); } } -eutra_mbsfn_sf_cfg_s::sf_alloc2_c_& eutra_mbsfn_sf_cfg_s::sf_alloc2_c_:: - operator=(const eutra_mbsfn_sf_cfg_s::sf_alloc2_c_& other) +ran_notif_area_info_c& ran_notif_area_info_c::operator=(const ran_notif_area_info_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::one_frame: - c.set(other.c.get >()); + case types::cell_list: + c.set(other.c.get()); break; - case types::four_frames: - c.set(other.c.get >()); + case types::ran_area_cfg_list: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); + log_invalid_choice_id(type_, "ran_notif_area_info_c"); } return *this; } -void eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::to_json(json_writer& j) const +void ran_notif_area_info_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::one_frame: - j.write_str("oneFrame", c.get >().to_string()); + case types::cell_list: + j.start_array("cellList"); + for (const auto& e1 : c.get()) { + e1.to_json(j); + } + j.end_array(); break; - case types::four_frames: - j.write_str("fourFrames", c.get >().to_string()); + case types::ran_area_cfg_list: + j.start_array("ran-AreaConfigList"); + for (const auto& e1 : c.get()) { + e1.to_json(j); + } + j.end_array(); break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); + log_invalid_choice_id(type_, "ran_notif_area_info_c"); } j.end_obj(); } -SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::pack(bit_ref& bref) const +SRSASN_CODE ran_notif_area_info_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::one_frame: - HANDLE_CODE(c.get >().pack(bref)); + case types::cell_list: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); break; - case types::four_frames: - HANDLE_CODE(c.get >().pack(bref)); + case types::ran_area_cfg_list: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); + log_invalid_choice_id(type_, "ran_notif_area_info_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::unpack(cbit_ref& bref) +SRSASN_CODE ran_notif_area_info_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::one_frame: - HANDLE_CODE(c.get >().unpack(bref)); + case types::cell_list: + HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); break; - case types::four_frames: - HANDLE_CODE(c.get >().unpack(bref)); + case types::ran_area_cfg_list: + HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); break; default: - log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); + log_invalid_choice_id(type_, "ran_notif_area_info_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types_opts::to_string() const -{ - static const char* options[] = {"oneFrame", "fourFrames"}; - return convert_enum_idx(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types"); -} -uint8_t eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types_opts::to_number() const +std::string ran_notif_area_info_c::types_opts::to_string() const { - static const uint8_t options[] = {1, 4}; - return map_enum_number(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types"); + static const char* options[] = {"cellList", "ran-AreaConfigList"}; + return convert_enum_idx(options, 2, value, "ran_notif_area_info_c::types"); } -// PUCCH-Config ::= SEQUENCE -SRSASN_CODE pucch_cfg_s::pack(bit_ref& bref) const +// RRCReconfiguration-v1540-IEs ::= SEQUENCE +SRSASN_CODE rrc_recfg_v1540_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(res_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(format1_present, 1)); - HANDLE_CODE(bref.pack(format2_present, 1)); - HANDLE_CODE(bref.pack(format3_present, 1)); - HANDLE_CODE(bref.pack(format4_present, 1)); - HANDLE_CODE(bref.pack(sched_request_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(sched_request_res_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(multi_csi_pucch_res_list_present, 1)); - HANDLE_CODE(bref.pack(dl_data_to_ul_ack_present, 1)); - HANDLE_CODE(bref.pack(spatial_relation_info_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(spatial_relation_info_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(pucch_pwr_ctrl_present, 1)); + HANDLE_CODE(bref.pack(other_cfg_v1540_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (res_set_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, res_set_to_add_mod_list, 1, 4)); - } - if (res_set_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, res_set_to_release_list, 1, 4, integer_packer(0, 3))); - } - if (res_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, res_to_add_mod_list, 1, 128)); - } - if (res_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, res_to_release_list, 1, 128, integer_packer(0, 127))); - } - if (format1_present) { - HANDLE_CODE(format1.pack(bref)); + if (other_cfg_v1540_present) { + HANDLE_CODE(other_cfg_v1540.pack(bref)); } - if (format2_present) { - HANDLE_CODE(format2.pack(bref)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } - if (format3_present) { - HANDLE_CODE(format3.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_recfg_v1540_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(other_cfg_v1540_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (other_cfg_v1540_present) { + HANDLE_CODE(other_cfg_v1540.unpack(bref)); } - if (format4_present) { - HANDLE_CODE(format4.pack(bref)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } - if (sched_request_res_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_res_to_add_mod_list, 1, 8)); + + return SRSASN_SUCCESS; +} +void rrc_recfg_v1540_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (other_cfg_v1540_present) { + j.write_fieldname("otherConfig-v1540"); + other_cfg_v1540.to_json(j); } - if (sched_request_res_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_res_to_release_list, 1, 8, integer_packer(1, 8))); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } - if (multi_csi_pucch_res_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, multi_csi_pucch_res_list, 1, 2, integer_packer(0, 127))); + j.end_obj(); +} + +// RedirectedCarrierInfo-EUTRA ::= SEQUENCE +SRSASN_CODE redirected_carrier_info_eutra_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(cn_type_present, 1)); + + HANDLE_CODE(pack_integer(bref, eutra_freq, (uint32_t)0u, (uint32_t)262143u)); + if (cn_type_present) { + HANDLE_CODE(cn_type.pack(bref)); } - if (dl_data_to_ul_ack_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, dl_data_to_ul_ack, 1, 8, integer_packer(0, 15))); + + return SRSASN_SUCCESS; +} +SRSASN_CODE redirected_carrier_info_eutra_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(cn_type_present, 1)); + + HANDLE_CODE(unpack_integer(eutra_freq, bref, (uint32_t)0u, (uint32_t)262143u)); + if (cn_type_present) { + HANDLE_CODE(cn_type.unpack(bref)); } - if (spatial_relation_info_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, spatial_relation_info_to_add_mod_list, 1, 8)); + + return SRSASN_SUCCESS; +} +void redirected_carrier_info_eutra_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("eutraFrequency", eutra_freq); + if (cn_type_present) { + j.write_str("cnType", cn_type.to_string()); } - if (spatial_relation_info_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, spatial_relation_info_to_release_list, 1, 8, integer_packer(1, 8))); + j.end_obj(); +} + +std::string redirected_carrier_info_eutra_s::cn_type_opts::to_string() const +{ + static const char* options[] = {"epc", "fiveGC"}; + return convert_enum_idx(options, 2, value, "redirected_carrier_info_eutra_s::cn_type_e_"); +} +uint8_t redirected_carrier_info_eutra_s::cn_type_opts::to_number() const +{ + if (value == five_gc) { + return 5; } - if (pucch_pwr_ctrl_present) { - HANDLE_CODE(pucch_pwr_ctrl.pack(bref)); + invalid_enum_number(value, "redirected_carrier_info_eutra_s::cn_type_e_"); + return 0; +} + +// UE-CapabilityRAT-Request ::= SEQUENCE +SRSASN_CODE ue_cap_rat_request_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(cap_request_filt_present, 1)); + + HANDLE_CODE(rat_type.pack(bref)); + if (cap_request_filt_present) { + HANDLE_CODE(cap_request_filt.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE pucch_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE ue_cap_rat_request_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(res_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(format1_present, 1)); - HANDLE_CODE(bref.unpack(format2_present, 1)); - HANDLE_CODE(bref.unpack(format3_present, 1)); - HANDLE_CODE(bref.unpack(format4_present, 1)); - HANDLE_CODE(bref.unpack(sched_request_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(sched_request_res_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(multi_csi_pucch_res_list_present, 1)); - HANDLE_CODE(bref.unpack(dl_data_to_ul_ack_present, 1)); - HANDLE_CODE(bref.unpack(spatial_relation_info_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(spatial_relation_info_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(pucch_pwr_ctrl_present, 1)); + HANDLE_CODE(bref.unpack(cap_request_filt_present, 1)); - if (res_set_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(res_set_to_add_mod_list, bref, 1, 4)); - } - if (res_set_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(res_set_to_release_list, bref, 1, 4, integer_packer(0, 3))); - } - if (res_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(res_to_add_mod_list, bref, 1, 128)); + HANDLE_CODE(rat_type.unpack(bref)); + if (cap_request_filt_present) { + HANDLE_CODE(cap_request_filt.unpack(bref)); } - if (res_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(res_to_release_list, bref, 1, 128, integer_packer(0, 127))); + + return SRSASN_SUCCESS; +} +void ue_cap_rat_request_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_str("rat-Type", rat_type.to_string()); + if (cap_request_filt_present) { + j.write_str("capabilityRequestFilter", cap_request_filt.to_string()); } - if (format1_present) { - HANDLE_CODE(format1.unpack(bref)); + j.end_obj(); +} + +// CellReselectionPriorities ::= SEQUENCE +SRSASN_CODE cell_resel_priorities_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(freq_prio_list_eutra_present, 1)); + HANDLE_CODE(bref.pack(freq_prio_list_nr_present, 1)); + HANDLE_CODE(bref.pack(t320_present, 1)); + + if (freq_prio_list_eutra_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, freq_prio_list_eutra, 1, 8)); } - if (format2_present) { - HANDLE_CODE(format2.unpack(bref)); + if (freq_prio_list_nr_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, freq_prio_list_nr, 1, 8)); } - if (format3_present) { - HANDLE_CODE(format3.unpack(bref)); + if (t320_present) { + HANDLE_CODE(t320.pack(bref)); } - if (format4_present) { - HANDLE_CODE(format4.unpack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE cell_resel_priorities_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(freq_prio_list_eutra_present, 1)); + HANDLE_CODE(bref.unpack(freq_prio_list_nr_present, 1)); + HANDLE_CODE(bref.unpack(t320_present, 1)); + + if (freq_prio_list_eutra_present) { + HANDLE_CODE(unpack_dyn_seq_of(freq_prio_list_eutra, bref, 1, 8)); } - if (sched_request_res_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sched_request_res_to_add_mod_list, bref, 1, 8)); + if (freq_prio_list_nr_present) { + HANDLE_CODE(unpack_dyn_seq_of(freq_prio_list_nr, bref, 1, 8)); } - if (sched_request_res_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sched_request_res_to_release_list, bref, 1, 8, integer_packer(1, 8))); - } - if (multi_csi_pucch_res_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(multi_csi_pucch_res_list, bref, 1, 2, integer_packer(0, 127))); - } - if (dl_data_to_ul_ack_present) { - HANDLE_CODE(unpack_dyn_seq_of(dl_data_to_ul_ack, bref, 1, 8, integer_packer(0, 15))); - } - if (spatial_relation_info_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(spatial_relation_info_to_add_mod_list, bref, 1, 8)); - } - if (spatial_relation_info_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(spatial_relation_info_to_release_list, bref, 1, 8, integer_packer(1, 8))); - } - if (pucch_pwr_ctrl_present) { - HANDLE_CODE(pucch_pwr_ctrl.unpack(bref)); + if (t320_present) { + HANDLE_CODE(t320.unpack(bref)); } return SRSASN_SUCCESS; } -void pucch_cfg_s::to_json(json_writer& j) const +void cell_resel_priorities_s::to_json(json_writer& j) const { j.start_obj(); - if (res_set_to_add_mod_list_present) { - j.start_array("resourceSetToAddModList"); - for (const auto& e1 : res_set_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (res_set_to_release_list_present) { - j.start_array("resourceSetToReleaseList"); - for (const auto& e1 : res_set_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (res_to_add_mod_list_present) { - j.start_array("resourceToAddModList"); - for (const auto& e1 : res_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (res_to_release_list_present) { - j.start_array("resourceToReleaseList"); - for (const auto& e1 : res_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (format1_present) { - j.write_fieldname("format1"); - format1.to_json(j); - } - if (format2_present) { - j.write_fieldname("format2"); - format2.to_json(j); - } - if (format3_present) { - j.write_fieldname("format3"); - format3.to_json(j); - } - if (format4_present) { - j.write_fieldname("format4"); - format4.to_json(j); - } - if (sched_request_res_to_add_mod_list_present) { - j.start_array("schedulingRequestResourceToAddModList"); - for (const auto& e1 : sched_request_res_to_add_mod_list) { + if (freq_prio_list_eutra_present) { + j.start_array("freqPriorityListEUTRA"); + for (const auto& e1 : freq_prio_list_eutra) { e1.to_json(j); } j.end_array(); } - if (sched_request_res_to_release_list_present) { - j.start_array("schedulingRequestResourceToReleaseList"); - for (const auto& e1 : sched_request_res_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (multi_csi_pucch_res_list_present) { - j.start_array("multi-CSI-PUCCH-ResourceList"); - for (const auto& e1 : multi_csi_pucch_res_list) { - j.write_int(e1); - } - j.end_array(); - } - if (dl_data_to_ul_ack_present) { - j.start_array("dl-DataToUL-ACK"); - for (const auto& e1 : dl_data_to_ul_ack) { - j.write_int(e1); - } - j.end_array(); - } - if (spatial_relation_info_to_add_mod_list_present) { - j.start_array("spatialRelationInfoToAddModList"); - for (const auto& e1 : spatial_relation_info_to_add_mod_list) { + if (freq_prio_list_nr_present) { + j.start_array("freqPriorityListNR"); + for (const auto& e1 : freq_prio_list_nr) { e1.to_json(j); } j.end_array(); } - if (spatial_relation_info_to_release_list_present) { - j.start_array("spatialRelationInfoToReleaseList"); - for (const auto& e1 : spatial_relation_info_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (pucch_pwr_ctrl_present) { - j.write_fieldname("pucch-PowerControl"); - pucch_pwr_ctrl.to_json(j); + if (t320_present) { + j.write_str("t320", t320.to_string()); } j.end_obj(); } -// PUCCH-TPC-CommandConfig ::= SEQUENCE -SRSASN_CODE pucch_tpc_cmd_cfg_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(tpc_idx_pcell_present, 1)); - HANDLE_CODE(bref.pack(tpc_idx_pucch_scell_present, 1)); - - if (tpc_idx_pcell_present) { - HANDLE_CODE(pack_integer(bref, tpc_idx_pcell, (uint8_t)1u, (uint8_t)15u)); - } - if (tpc_idx_pucch_scell_present) { - HANDLE_CODE(pack_integer(bref, tpc_idx_pucch_scell, (uint8_t)1u, (uint8_t)15u)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE pucch_tpc_cmd_cfg_s::unpack(cbit_ref& bref) +std::string cell_resel_priorities_s::t320_opts::to_string() const { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(tpc_idx_pcell_present, 1)); - HANDLE_CODE(bref.unpack(tpc_idx_pucch_scell_present, 1)); - - if (tpc_idx_pcell_present) { - HANDLE_CODE(unpack_integer(tpc_idx_pcell, bref, (uint8_t)1u, (uint8_t)15u)); - } - if (tpc_idx_pucch_scell_present) { - HANDLE_CODE(unpack_integer(tpc_idx_pucch_scell, bref, (uint8_t)1u, (uint8_t)15u)); - } - - return SRSASN_SUCCESS; + static const char* options[] = {"min5", "min10", "min20", "min30", "min60", "min120", "min180", "spare1"}; + return convert_enum_idx(options, 8, value, "cell_resel_priorities_s::t320_e_"); } -void pucch_tpc_cmd_cfg_s::to_json(json_writer& j) const +uint8_t cell_resel_priorities_s::t320_opts::to_number() const { - j.start_obj(); - if (tpc_idx_pcell_present) { - j.write_int("tpc-IndexPCell", tpc_idx_pcell); - } - if (tpc_idx_pucch_scell_present) { - j.write_int("tpc-IndexPUCCH-SCell", tpc_idx_pucch_scell); - } - j.end_obj(); + static const uint8_t options[] = {5, 10, 20, 30, 60, 120, 180}; + return map_enum_number(options, 7, value, "cell_resel_priorities_s::t320_e_"); } -// PUSCH-Config ::= SEQUENCE -SRSASN_CODE pusch_cfg_s::pack(bit_ref& bref) const +// MeasConfig ::= SEQUENCE +SRSASN_CODE meas_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(data_scrambling_id_pusch_present, 1)); - HANDLE_CODE(bref.pack(tx_cfg_present, 1)); - HANDLE_CODE(bref.pack(dmrs_ul_for_pusch_map_type_a_present, 1)); - HANDLE_CODE(bref.pack(dmrs_ul_for_pusch_map_type_b_present, 1)); - HANDLE_CODE(bref.pack(pusch_pwr_ctrl_present, 1)); - HANDLE_CODE(bref.pack(freq_hop_present, 1)); - HANDLE_CODE(bref.pack(freq_hop_offset_lists_present, 1)); - HANDLE_CODE(bref.pack(pusch_time_domain_alloc_list_present, 1)); - HANDLE_CODE(bref.pack(pusch_aggregation_factor_present, 1)); - HANDLE_CODE(bref.pack(mcs_table_present, 1)); - HANDLE_CODE(bref.pack(mcs_table_transform_precoder_present, 1)); - HANDLE_CODE(bref.pack(transform_precoder_present, 1)); - HANDLE_CODE(bref.pack(codebook_subset_present, 1)); - HANDLE_CODE(bref.pack(max_rank_present, 1)); - HANDLE_CODE(bref.pack(rbg_size_present, 1)); - HANDLE_CODE(bref.pack(uci_on_pusch_present, 1)); - HANDLE_CODE(bref.pack(tp_pi2_bpsk_present, 1)); + HANDLE_CODE(bref.pack(meas_obj_to_rem_list_present, 1)); + HANDLE_CODE(bref.pack(meas_obj_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(report_cfg_to_rem_list_present, 1)); + HANDLE_CODE(bref.pack(report_cfg_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(meas_id_to_rem_list_present, 1)); + HANDLE_CODE(bref.pack(meas_id_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(s_measure_cfg_present, 1)); + HANDLE_CODE(bref.pack(quant_cfg_present, 1)); + HANDLE_CODE(bref.pack(meas_gap_cfg_present, 1)); + HANDLE_CODE(bref.pack(meas_gap_sharing_cfg_present, 1)); - if (data_scrambling_id_pusch_present) { - HANDLE_CODE(pack_integer(bref, data_scrambling_id_pusch, (uint16_t)0u, (uint16_t)1023u)); - } - if (tx_cfg_present) { - HANDLE_CODE(tx_cfg.pack(bref)); - } - if (dmrs_ul_for_pusch_map_type_a_present) { - HANDLE_CODE(dmrs_ul_for_pusch_map_type_a.pack(bref)); - } - if (dmrs_ul_for_pusch_map_type_b_present) { - HANDLE_CODE(dmrs_ul_for_pusch_map_type_b.pack(bref)); - } - if (pusch_pwr_ctrl_present) { - HANDLE_CODE(pusch_pwr_ctrl.pack(bref)); - } - if (freq_hop_present) { - HANDLE_CODE(freq_hop.pack(bref)); + if (meas_obj_to_rem_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_obj_to_rem_list, 1, 64, integer_packer(1, 64))); } - if (freq_hop_offset_lists_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, freq_hop_offset_lists, 1, 4, integer_packer(1, 274))); + if (meas_obj_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_obj_to_add_mod_list, 1, 64)); } - HANDLE_CODE(res_alloc.pack(bref)); - if (pusch_time_domain_alloc_list_present) { - HANDLE_CODE(pusch_time_domain_alloc_list.pack(bref)); + if (report_cfg_to_rem_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, report_cfg_to_rem_list, 1, 64, integer_packer(1, 64))); } - if (pusch_aggregation_factor_present) { - HANDLE_CODE(pusch_aggregation_factor.pack(bref)); + if (report_cfg_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, report_cfg_to_add_mod_list, 1, 64)); } - if (mcs_table_present) { - HANDLE_CODE(mcs_table.pack(bref)); + if (meas_id_to_rem_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_id_to_rem_list, 1, 64, integer_packer(1, 64))); } - if (mcs_table_transform_precoder_present) { - HANDLE_CODE(mcs_table_transform_precoder.pack(bref)); + if (meas_id_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_id_to_add_mod_list, 1, 64)); } - if (transform_precoder_present) { - HANDLE_CODE(transform_precoder.pack(bref)); + if (s_measure_cfg_present) { + HANDLE_CODE(s_measure_cfg.pack(bref)); } - if (codebook_subset_present) { - HANDLE_CODE(codebook_subset.pack(bref)); + if (quant_cfg_present) { + HANDLE_CODE(quant_cfg.pack(bref)); } - if (max_rank_present) { - HANDLE_CODE(pack_integer(bref, max_rank, (uint8_t)1u, (uint8_t)4u)); + if (meas_gap_cfg_present) { + HANDLE_CODE(meas_gap_cfg.pack(bref)); } - if (uci_on_pusch_present) { - HANDLE_CODE(uci_on_pusch.pack(bref)); + if (meas_gap_sharing_cfg_present) { + HANDLE_CODE(meas_gap_sharing_cfg.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE pusch_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(data_scrambling_id_pusch_present, 1)); - HANDLE_CODE(bref.unpack(tx_cfg_present, 1)); - HANDLE_CODE(bref.unpack(dmrs_ul_for_pusch_map_type_a_present, 1)); - HANDLE_CODE(bref.unpack(dmrs_ul_for_pusch_map_type_b_present, 1)); - HANDLE_CODE(bref.unpack(pusch_pwr_ctrl_present, 1)); - HANDLE_CODE(bref.unpack(freq_hop_present, 1)); - HANDLE_CODE(bref.unpack(freq_hop_offset_lists_present, 1)); - HANDLE_CODE(bref.unpack(pusch_time_domain_alloc_list_present, 1)); - HANDLE_CODE(bref.unpack(pusch_aggregation_factor_present, 1)); - HANDLE_CODE(bref.unpack(mcs_table_present, 1)); - HANDLE_CODE(bref.unpack(mcs_table_transform_precoder_present, 1)); - HANDLE_CODE(bref.unpack(transform_precoder_present, 1)); - HANDLE_CODE(bref.unpack(codebook_subset_present, 1)); - HANDLE_CODE(bref.unpack(max_rank_present, 1)); - HANDLE_CODE(bref.unpack(rbg_size_present, 1)); - HANDLE_CODE(bref.unpack(uci_on_pusch_present, 1)); - HANDLE_CODE(bref.unpack(tp_pi2_bpsk_present, 1)); + HANDLE_CODE(bref.unpack(meas_obj_to_rem_list_present, 1)); + HANDLE_CODE(bref.unpack(meas_obj_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(report_cfg_to_rem_list_present, 1)); + HANDLE_CODE(bref.unpack(report_cfg_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(meas_id_to_rem_list_present, 1)); + HANDLE_CODE(bref.unpack(meas_id_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(s_measure_cfg_present, 1)); + HANDLE_CODE(bref.unpack(quant_cfg_present, 1)); + HANDLE_CODE(bref.unpack(meas_gap_cfg_present, 1)); + HANDLE_CODE(bref.unpack(meas_gap_sharing_cfg_present, 1)); - if (data_scrambling_id_pusch_present) { - HANDLE_CODE(unpack_integer(data_scrambling_id_pusch, bref, (uint16_t)0u, (uint16_t)1023u)); - } - if (tx_cfg_present) { - HANDLE_CODE(tx_cfg.unpack(bref)); - } - if (dmrs_ul_for_pusch_map_type_a_present) { - HANDLE_CODE(dmrs_ul_for_pusch_map_type_a.unpack(bref)); - } - if (dmrs_ul_for_pusch_map_type_b_present) { - HANDLE_CODE(dmrs_ul_for_pusch_map_type_b.unpack(bref)); - } - if (pusch_pwr_ctrl_present) { - HANDLE_CODE(pusch_pwr_ctrl.unpack(bref)); - } - if (freq_hop_present) { - HANDLE_CODE(freq_hop.unpack(bref)); + if (meas_obj_to_rem_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_obj_to_rem_list, bref, 1, 64, integer_packer(1, 64))); } - if (freq_hop_offset_lists_present) { - HANDLE_CODE(unpack_dyn_seq_of(freq_hop_offset_lists, bref, 1, 4, integer_packer(1, 274))); + if (meas_obj_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_obj_to_add_mod_list, bref, 1, 64)); } - HANDLE_CODE(res_alloc.unpack(bref)); - if (pusch_time_domain_alloc_list_present) { - HANDLE_CODE(pusch_time_domain_alloc_list.unpack(bref)); + if (report_cfg_to_rem_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(report_cfg_to_rem_list, bref, 1, 64, integer_packer(1, 64))); } - if (pusch_aggregation_factor_present) { - HANDLE_CODE(pusch_aggregation_factor.unpack(bref)); + if (report_cfg_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(report_cfg_to_add_mod_list, bref, 1, 64)); } - if (mcs_table_present) { - HANDLE_CODE(mcs_table.unpack(bref)); + if (meas_id_to_rem_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_id_to_rem_list, bref, 1, 64, integer_packer(1, 64))); } - if (mcs_table_transform_precoder_present) { - HANDLE_CODE(mcs_table_transform_precoder.unpack(bref)); + if (meas_id_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_id_to_add_mod_list, bref, 1, 64)); } - if (transform_precoder_present) { - HANDLE_CODE(transform_precoder.unpack(bref)); + if (s_measure_cfg_present) { + HANDLE_CODE(s_measure_cfg.unpack(bref)); } - if (codebook_subset_present) { - HANDLE_CODE(codebook_subset.unpack(bref)); + if (quant_cfg_present) { + HANDLE_CODE(quant_cfg.unpack(bref)); } - if (max_rank_present) { - HANDLE_CODE(unpack_integer(max_rank, bref, (uint8_t)1u, (uint8_t)4u)); + if (meas_gap_cfg_present) { + HANDLE_CODE(meas_gap_cfg.unpack(bref)); } - if (uci_on_pusch_present) { - HANDLE_CODE(uci_on_pusch.unpack(bref)); + if (meas_gap_sharing_cfg_present) { + HANDLE_CODE(meas_gap_sharing_cfg.unpack(bref)); } return SRSASN_SUCCESS; } -void pusch_cfg_s::to_json(json_writer& j) const +void meas_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (data_scrambling_id_pusch_present) { - j.write_int("dataScramblingIdentityPUSCH", data_scrambling_id_pusch); - } - if (tx_cfg_present) { - j.write_str("txConfig", tx_cfg.to_string()); - } - if (dmrs_ul_for_pusch_map_type_a_present) { - j.write_fieldname("dmrs-UplinkForPUSCH-MappingTypeA"); - dmrs_ul_for_pusch_map_type_a.to_json(j); - } - if (dmrs_ul_for_pusch_map_type_b_present) { - j.write_fieldname("dmrs-UplinkForPUSCH-MappingTypeB"); - dmrs_ul_for_pusch_map_type_b.to_json(j); - } - if (pusch_pwr_ctrl_present) { - j.write_fieldname("pusch-PowerControl"); - pusch_pwr_ctrl.to_json(j); - } - if (freq_hop_present) { - j.write_str("frequencyHopping", freq_hop.to_string()); - } - if (freq_hop_offset_lists_present) { - j.start_array("frequencyHoppingOffsetLists"); - for (const auto& e1 : freq_hop_offset_lists) { + if (meas_obj_to_rem_list_present) { + j.start_array("measObjectToRemoveList"); + for (const auto& e1 : meas_obj_to_rem_list) { j.write_int(e1); } j.end_array(); } - j.write_str("resourceAllocation", res_alloc.to_string()); - if (pusch_time_domain_alloc_list_present) { - j.write_fieldname("pusch-TimeDomainAllocationList"); - pusch_time_domain_alloc_list.to_json(j); - } - if (pusch_aggregation_factor_present) { - j.write_str("pusch-AggregationFactor", pusch_aggregation_factor.to_string()); + if (meas_obj_to_add_mod_list_present) { + j.start_array("measObjectToAddModList"); + for (const auto& e1 : meas_obj_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - if (mcs_table_present) { - j.write_str("mcs-Table", mcs_table.to_string()); + if (report_cfg_to_rem_list_present) { + j.start_array("reportConfigToRemoveList"); + for (const auto& e1 : report_cfg_to_rem_list) { + j.write_int(e1); + } + j.end_array(); } - if (mcs_table_transform_precoder_present) { - j.write_str("mcs-TableTransformPrecoder", mcs_table_transform_precoder.to_string()); + if (report_cfg_to_add_mod_list_present) { + j.start_array("reportConfigToAddModList"); + for (const auto& e1 : report_cfg_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - if (transform_precoder_present) { - j.write_str("transformPrecoder", transform_precoder.to_string()); + if (meas_id_to_rem_list_present) { + j.start_array("measIdToRemoveList"); + for (const auto& e1 : meas_id_to_rem_list) { + j.write_int(e1); + } + j.end_array(); } - if (codebook_subset_present) { - j.write_str("codebookSubset", codebook_subset.to_string()); + if (meas_id_to_add_mod_list_present) { + j.start_array("measIdToAddModList"); + for (const auto& e1 : meas_id_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - if (max_rank_present) { - j.write_int("maxRank", max_rank); + if (s_measure_cfg_present) { + j.write_fieldname("s-MeasureConfig"); + s_measure_cfg.to_json(j); } - if (rbg_size_present) { - j.write_str("rbg-Size", "config2"); + if (quant_cfg_present) { + j.write_fieldname("quantityConfig"); + quant_cfg.to_json(j); } - if (uci_on_pusch_present) { - j.write_fieldname("uci-OnPUSCH"); - uci_on_pusch.to_json(j); + if (meas_gap_cfg_present) { + j.write_fieldname("measGapConfig"); + meas_gap_cfg.to_json(j); } - if (tp_pi2_bpsk_present) { - j.write_str("tp-pi2BPSK", "enabled"); + if (meas_gap_sharing_cfg_present) { + j.write_fieldname("measGapSharingConfig"); + meas_gap_sharing_cfg.to_json(j); } j.end_obj(); } -std::string pusch_cfg_s::tx_cfg_opts::to_string() const -{ - static const char* options[] = {"codebook", "nonCodebook"}; - return convert_enum_idx(options, 2, value, "pusch_cfg_s::tx_cfg_e_"); -} - -std::string pusch_cfg_s::freq_hop_opts::to_string() const +void meas_cfg_s::s_measure_cfg_c_::destroy_() {} +void meas_cfg_s::s_measure_cfg_c_::set(types::options e) { - static const char* options[] = {"intraSlot", "interSlot"}; - return convert_enum_idx(options, 2, value, "pusch_cfg_s::freq_hop_e_"); + destroy_(); + type_ = e; } - -std::string pusch_cfg_s::res_alloc_opts::to_string() const +meas_cfg_s::s_measure_cfg_c_::s_measure_cfg_c_(const meas_cfg_s::s_measure_cfg_c_& other) { - static const char* options[] = {"resourceAllocationType0", "resourceAllocationType1", "dynamicSwitch"}; - return convert_enum_idx(options, 3, value, "pusch_cfg_s::res_alloc_e_"); + type_ = other.type(); + switch (type_) { + case types::ssb_rsrp: + c.init(other.c.get()); + break; + case types::csi_rsrp: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + } } -uint8_t pusch_cfg_s::res_alloc_opts::to_number() const +meas_cfg_s::s_measure_cfg_c_& meas_cfg_s::s_measure_cfg_c_::operator=(const meas_cfg_s::s_measure_cfg_c_& other) { - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "pusch_cfg_s::res_alloc_e_"); -} + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::ssb_rsrp: + c.set(other.c.get()); + break; + case types::csi_rsrp: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + } -std::string pusch_cfg_s::pusch_aggregation_factor_opts::to_string() const -{ - static const char* options[] = {"n2", "n4", "n8"}; - return convert_enum_idx(options, 3, value, "pusch_cfg_s::pusch_aggregation_factor_e_"); + return *this; } -uint8_t pusch_cfg_s::pusch_aggregation_factor_opts::to_number() const +void meas_cfg_s::s_measure_cfg_c_::to_json(json_writer& j) const { - static const uint8_t options[] = {2, 4, 8}; - return map_enum_number(options, 3, value, "pusch_cfg_s::pusch_aggregation_factor_e_"); + j.start_obj(); + switch (type_) { + case types::ssb_rsrp: + j.write_int("ssb-RSRP", c.get()); + break; + case types::csi_rsrp: + j.write_int("csi-RSRP", c.get()); + break; + default: + log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + } + j.end_obj(); } - -std::string pusch_cfg_s::mcs_table_opts::to_string() const +SRSASN_CODE meas_cfg_s::s_measure_cfg_c_::pack(bit_ref& bref) const { - static const char* options[] = {"qam256", "qam64LowSE"}; - return convert_enum_idx(options, 2, value, "pusch_cfg_s::mcs_table_e_"); + type_.pack(bref); + switch (type_) { + case types::ssb_rsrp: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + break; + case types::csi_rsrp: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + break; + default: + log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } -uint16_t pusch_cfg_s::mcs_table_opts::to_number() const +SRSASN_CODE meas_cfg_s::s_measure_cfg_c_::unpack(cbit_ref& bref) { - static const uint16_t options[] = {256, 64}; - return map_enum_number(options, 2, value, "pusch_cfg_s::mcs_table_e_"); -} - -std::string pusch_cfg_s::mcs_table_transform_precoder_opts::to_string() const -{ - static const char* options[] = {"qam256", "qam64LowSE"}; - return convert_enum_idx(options, 2, value, "pusch_cfg_s::mcs_table_transform_precoder_e_"); -} -uint16_t pusch_cfg_s::mcs_table_transform_precoder_opts::to_number() const -{ - static const uint16_t options[] = {256, 64}; - return map_enum_number(options, 2, value, "pusch_cfg_s::mcs_table_transform_precoder_e_"); -} - -std::string pusch_cfg_s::transform_precoder_opts::to_string() const -{ - static const char* options[] = {"enabled", "disabled"}; - return convert_enum_idx(options, 2, value, "pusch_cfg_s::transform_precoder_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ssb_rsrp: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + break; + case types::csi_rsrp: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + break; + default: + log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -std::string pusch_cfg_s::codebook_subset_opts::to_string() const +std::string meas_cfg_s::s_measure_cfg_c_::types_opts::to_string() const { - static const char* options[] = {"fullyAndPartialAndNonCoherent", "partialAndNonCoherent", "nonCoherent"}; - return convert_enum_idx(options, 3, value, "pusch_cfg_s::codebook_subset_e_"); + static const char* options[] = {"ssb-RSRP", "csi-RSRP"}; + return convert_enum_idx(options, 2, value, "meas_cfg_s::s_measure_cfg_c_::types"); } -// PUSCH-TPC-CommandConfig ::= SEQUENCE -SRSASN_CODE pusch_tpc_cmd_cfg_s::pack(bit_ref& bref) const +// RRCReconfiguration-v1530-IEs ::= SEQUENCE +SRSASN_CODE rrc_recfg_v1530_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(tpc_idx_present, 1)); - HANDLE_CODE(bref.pack(tpc_idx_sul_present, 1)); - HANDLE_CODE(bref.pack(target_cell_present, 1)); + HANDLE_CODE(bref.pack(master_cell_group_present, 1)); + HANDLE_CODE(bref.pack(full_cfg_present, 1)); + HANDLE_CODE(bref.pack(ded_nas_msg_list_present, 1)); + HANDLE_CODE(bref.pack(master_key_upd_present, 1)); + HANDLE_CODE(bref.pack(ded_sib1_delivery_present, 1)); + HANDLE_CODE(bref.pack(ded_sys_info_delivery_present, 1)); + HANDLE_CODE(bref.pack(other_cfg_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (tpc_idx_present) { - HANDLE_CODE(pack_integer(bref, tpc_idx, (uint8_t)1u, (uint8_t)15u)); + if (master_cell_group_present) { + HANDLE_CODE(master_cell_group.pack(bref)); } - if (tpc_idx_sul_present) { - HANDLE_CODE(pack_integer(bref, tpc_idx_sul, (uint8_t)1u, (uint8_t)15u)); + if (ded_nas_msg_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ded_nas_msg_list, 1, 29)); } - if (target_cell_present) { - HANDLE_CODE(pack_integer(bref, target_cell, (uint8_t)0u, (uint8_t)31u)); + if (master_key_upd_present) { + HANDLE_CODE(master_key_upd.pack(bref)); + } + if (ded_sib1_delivery_present) { + HANDLE_CODE(ded_sib1_delivery.pack(bref)); + } + if (ded_sys_info_delivery_present) { + HANDLE_CODE(ded_sys_info_delivery.pack(bref)); + } + if (other_cfg_present) { + HANDLE_CODE(other_cfg.pack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE pusch_tpc_cmd_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_recfg_v1530_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(tpc_idx_present, 1)); - HANDLE_CODE(bref.unpack(tpc_idx_sul_present, 1)); - HANDLE_CODE(bref.unpack(target_cell_present, 1)); + HANDLE_CODE(bref.unpack(master_cell_group_present, 1)); + HANDLE_CODE(bref.unpack(full_cfg_present, 1)); + HANDLE_CODE(bref.unpack(ded_nas_msg_list_present, 1)); + HANDLE_CODE(bref.unpack(master_key_upd_present, 1)); + HANDLE_CODE(bref.unpack(ded_sib1_delivery_present, 1)); + HANDLE_CODE(bref.unpack(ded_sys_info_delivery_present, 1)); + HANDLE_CODE(bref.unpack(other_cfg_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (tpc_idx_present) { - HANDLE_CODE(unpack_integer(tpc_idx, bref, (uint8_t)1u, (uint8_t)15u)); + if (master_cell_group_present) { + HANDLE_CODE(master_cell_group.unpack(bref)); } - if (tpc_idx_sul_present) { - HANDLE_CODE(unpack_integer(tpc_idx_sul, bref, (uint8_t)1u, (uint8_t)15u)); + if (ded_nas_msg_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ded_nas_msg_list, bref, 1, 29)); } - if (target_cell_present) { - HANDLE_CODE(unpack_integer(target_cell, bref, (uint8_t)0u, (uint8_t)31u)); + if (master_key_upd_present) { + HANDLE_CODE(master_key_upd.unpack(bref)); + } + if (ded_sib1_delivery_present) { + HANDLE_CODE(ded_sib1_delivery.unpack(bref)); + } + if (ded_sys_info_delivery_present) { + HANDLE_CODE(ded_sys_info_delivery.unpack(bref)); + } + if (other_cfg_present) { + HANDLE_CODE(other_cfg.unpack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void pusch_tpc_cmd_cfg_s::to_json(json_writer& j) const +void rrc_recfg_v1530_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (tpc_idx_present) { - j.write_int("tpc-Index", tpc_idx); + if (master_cell_group_present) { + j.write_str("masterCellGroup", master_cell_group.to_string()); } - if (tpc_idx_sul_present) { - j.write_int("tpc-IndexSUL", tpc_idx_sul); + if (full_cfg_present) { + j.write_str("fullConfig", "true"); } - if (target_cell_present) { - j.write_int("targetCell", target_cell); + if (ded_nas_msg_list_present) { + j.start_array("dedicatedNAS-MessageList"); + for (const auto& e1 : ded_nas_msg_list) { + j.write_str(e1.to_string()); + } + j.end_array(); + } + if (master_key_upd_present) { + j.write_fieldname("masterKeyUpdate"); + master_key_upd.to_json(j); + } + if (ded_sib1_delivery_present) { + j.write_str("dedicatedSIB1-Delivery", ded_sib1_delivery.to_string()); + } + if (ded_sys_info_delivery_present) { + j.write_str("dedicatedSystemInformationDelivery", ded_sys_info_delivery.to_string()); + } + if (other_cfg_present) { + j.write_fieldname("otherConfig"); + other_cfg.to_json(j); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } j.end_obj(); } -// RadioLinkMonitoringRS ::= SEQUENCE -SRSASN_CODE radio_link_monitoring_rs_s::pack(bit_ref& bref) const +// RRCRelease-v1540-IEs ::= SEQUENCE +SRSASN_CODE rrc_release_v1540_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, radio_link_monitoring_rs_id, (uint8_t)0u, (uint8_t)9u)); - HANDLE_CODE(purpose.pack(bref)); - HANDLE_CODE(detection_res.pack(bref)); + HANDLE_CODE(bref.pack(wait_time_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - return SRSASN_SUCCESS; -} -SRSASN_CODE radio_link_monitoring_rs_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(radio_link_monitoring_rs_id, bref, (uint8_t)0u, (uint8_t)9u)); - HANDLE_CODE(purpose.unpack(bref)); - HANDLE_CODE(detection_res.unpack(bref)); + if (wait_time_present) { + HANDLE_CODE(pack_integer(bref, wait_time, (uint8_t)1u, (uint8_t)16u)); + } return SRSASN_SUCCESS; } -void radio_link_monitoring_rs_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("radioLinkMonitoringRS-Id", radio_link_monitoring_rs_id); - j.write_str("purpose", purpose.to_string()); - j.write_fieldname("detectionResource"); - detection_res.to_json(j); - j.end_obj(); -} - -std::string radio_link_monitoring_rs_s::purpose_opts::to_string() const +SRSASN_CODE rrc_release_v1540_ies_s::unpack(cbit_ref& bref) { - static const char* options[] = {"beamFailure", "rlf", "both"}; - return convert_enum_idx(options, 3, value, "radio_link_monitoring_rs_s::purpose_e_"); -} + HANDLE_CODE(bref.unpack(wait_time_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); -void radio_link_monitoring_rs_s::detection_res_c_::destroy_() {} -void radio_link_monitoring_rs_s::detection_res_c_::set(types::options e) -{ - destroy_(); - type_ = e; -} -radio_link_monitoring_rs_s::detection_res_c_::detection_res_c_( - const radio_link_monitoring_rs_s::detection_res_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::ssb_idx: - c.init(other.c.get()); - break; - case types::csi_rs_idx: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); - } -} -radio_link_monitoring_rs_s::detection_res_c_& radio_link_monitoring_rs_s::detection_res_c_:: - operator=(const radio_link_monitoring_rs_s::detection_res_c_& other) -{ - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::ssb_idx: - c.set(other.c.get()); - break; - case types::csi_rs_idx: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); + if (wait_time_present) { + HANDLE_CODE(unpack_integer(wait_time, bref, (uint8_t)1u, (uint8_t)16u)); } - return *this; + return SRSASN_SUCCESS; } -void radio_link_monitoring_rs_s::detection_res_c_::to_json(json_writer& j) const +void rrc_release_v1540_ies_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::ssb_idx: - j.write_int("ssb-Index", c.get()); - break; - case types::csi_rs_idx: - j.write_int("csi-RS-Index", c.get()); - break; - default: - log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); - } - j.end_obj(); -} -SRSASN_CODE radio_link_monitoring_rs_s::detection_res_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::ssb_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); - break; - case types::csi_rs_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); - break; - default: - log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + if (wait_time_present) { + j.write_int("waitTime", wait_time); } - return SRSASN_SUCCESS; -} -SRSASN_CODE radio_link_monitoring_rs_s::detection_res_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::ssb_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); - break; - case types::csi_rs_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); - break; - default: - log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); - return SRSASN_ERROR_DECODE_FAIL; + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } - return SRSASN_SUCCESS; -} - -std::string radio_link_monitoring_rs_s::detection_res_c_::types_opts::to_string() const -{ - static const char* options[] = {"ssb-Index", "csi-RS-Index"}; - return convert_enum_idx(options, 2, value, "radio_link_monitoring_rs_s::detection_res_c_::types"); + j.end_obj(); } -// RateMatchPattern ::= SEQUENCE -SRSASN_CODE rate_match_pattern_s::pack(bit_ref& bref) const +// RRCResume-v1560-IEs ::= SEQUENCE +SRSASN_CODE rrc_resume_v1560_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(subcarrier_spacing_present, 1)); + HANDLE_CODE(bref.pack(radio_bearer_cfg2_present, 1)); + HANDLE_CODE(bref.pack(sk_counter_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - HANDLE_CODE(pack_integer(bref, rate_match_pattern_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pattern_type.pack(bref)); - if (subcarrier_spacing_present) { - HANDLE_CODE(subcarrier_spacing.pack(bref)); + if (radio_bearer_cfg2_present) { + HANDLE_CODE(radio_bearer_cfg2.pack(bref)); + } + if (sk_counter_present) { + HANDLE_CODE(pack_integer(bref, sk_counter, (uint32_t)0u, (uint32_t)65535u)); } - HANDLE_CODE(dummy.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE rate_match_pattern_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_resume_v1560_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(subcarrier_spacing_present, 1)); + HANDLE_CODE(bref.unpack(radio_bearer_cfg2_present, 1)); + HANDLE_CODE(bref.unpack(sk_counter_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - HANDLE_CODE(unpack_integer(rate_match_pattern_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pattern_type.unpack(bref)); - if (subcarrier_spacing_present) { - HANDLE_CODE(subcarrier_spacing.unpack(bref)); + if (radio_bearer_cfg2_present) { + HANDLE_CODE(radio_bearer_cfg2.unpack(bref)); + } + if (sk_counter_present) { + HANDLE_CODE(unpack_integer(sk_counter, bref, (uint32_t)0u, (uint32_t)65535u)); } - HANDLE_CODE(dummy.unpack(bref)); return SRSASN_SUCCESS; } -void rate_match_pattern_s::to_json(json_writer& j) const +void rrc_resume_v1560_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rateMatchPatternId", rate_match_pattern_id); - j.write_fieldname("patternType"); - pattern_type.to_json(j); - if (subcarrier_spacing_present) { - j.write_str("subcarrierSpacing", subcarrier_spacing.to_string()); + if (radio_bearer_cfg2_present) { + j.write_str("radioBearerConfig2", radio_bearer_cfg2.to_string()); + } + if (sk_counter_present) { + j.write_int("sk-Counter", sk_counter); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } - j.write_str("dummy", dummy.to_string()); j.end_obj(); } -void rate_match_pattern_s::pattern_type_c_::destroy_() +// RedirectedCarrierInfo ::= CHOICE +void redirected_carrier_info_c::destroy_() { switch (type_) { - case types::bitmaps: - c.destroy(); + case types::nr: + c.destroy(); + break; + case types::eutra: + c.destroy(); break; default: break; } } -void rate_match_pattern_s::pattern_type_c_::set(types::options e) +void redirected_carrier_info_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::bitmaps: - c.init(); + case types::nr: + c.init(); break; - case types::ctrl_res_set: + case types::eutra: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + log_invalid_choice_id(type_, "redirected_carrier_info_c"); } } -rate_match_pattern_s::pattern_type_c_::pattern_type_c_(const rate_match_pattern_s::pattern_type_c_& other) +redirected_carrier_info_c::redirected_carrier_info_c(const redirected_carrier_info_c& other) { type_ = other.type(); switch (type_) { - case types::bitmaps: - c.init(other.c.get()); + case types::nr: + c.init(other.c.get()); break; - case types::ctrl_res_set: - c.init(other.c.get()); + case types::eutra: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + log_invalid_choice_id(type_, "redirected_carrier_info_c"); } } -rate_match_pattern_s::pattern_type_c_& rate_match_pattern_s::pattern_type_c_:: - operator=(const rate_match_pattern_s::pattern_type_c_& other) +redirected_carrier_info_c& redirected_carrier_info_c::operator=(const redirected_carrier_info_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::bitmaps: - c.set(other.c.get()); + case types::nr: + c.set(other.c.get()); break; - case types::ctrl_res_set: - c.set(other.c.get()); + case types::eutra: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + log_invalid_choice_id(type_, "redirected_carrier_info_c"); } return *this; } -void rate_match_pattern_s::pattern_type_c_::to_json(json_writer& j) const +void redirected_carrier_info_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::bitmaps: - j.write_fieldname("bitmaps"); - j.start_obj(); - j.write_str("resourceBlocks", c.get().res_blocks.to_string()); - j.write_fieldname("symbolsInResourceBlock"); - c.get().symbols_in_res_block.to_json(j); - if (c.get().periodicity_and_pattern_present) { - j.write_fieldname("periodicityAndPattern"); - c.get().periodicity_and_pattern.to_json(j); - } - j.end_obj(); + case types::nr: + j.write_fieldname("nr"); + c.get().to_json(j); break; - case types::ctrl_res_set: - j.write_int("controlResourceSet", c.get()); + case types::eutra: + j.write_fieldname("eutra"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + log_invalid_choice_id(type_, "redirected_carrier_info_c"); } j.end_obj(); } -SRSASN_CODE rate_match_pattern_s::pattern_type_c_::pack(bit_ref& bref) const +SRSASN_CODE redirected_carrier_info_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::bitmaps: - bref.pack(c.get().ext, 1); - HANDLE_CODE(bref.pack(c.get().periodicity_and_pattern_present, 1)); - HANDLE_CODE(c.get().res_blocks.pack(bref)); - HANDLE_CODE(c.get().symbols_in_res_block.pack(bref)); - if (c.get().periodicity_and_pattern_present) { - HANDLE_CODE(c.get().periodicity_and_pattern.pack(bref)); - } + case types::nr: + HANDLE_CODE(c.get().pack(bref)); break; - case types::ctrl_res_set: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)11u)); + case types::eutra: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + log_invalid_choice_id(type_, "redirected_carrier_info_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rate_match_pattern_s::pattern_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE redirected_carrier_info_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::bitmaps: - bref.unpack(c.get().ext, 1); - HANDLE_CODE(bref.unpack(c.get().periodicity_and_pattern_present, 1)); - HANDLE_CODE(c.get().res_blocks.unpack(bref)); - HANDLE_CODE(c.get().symbols_in_res_block.unpack(bref)); - if (c.get().periodicity_and_pattern_present) { - HANDLE_CODE(c.get().periodicity_and_pattern.unpack(bref)); - } + case types::nr: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::ctrl_res_set: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)11u)); + case types::eutra: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + log_invalid_choice_id(type_, "redirected_carrier_info_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::destroy_() -{ - switch (type_) { - case types::one_slot: - c.destroy >(); - break; - case types::two_slots: - c.destroy >(); - break; - default: - break; - } -} -void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::set(types::options e) +std::string redirected_carrier_info_c::types_opts::to_string() const { - destroy_(); - type_ = e; - switch (type_) { - case types::one_slot: - c.init >(); - break; - case types::two_slots: - c.init >(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); - } + static const char* options[] = {"nr", "eutra"}; + return convert_enum_idx(options, 2, value, "redirected_carrier_info_c::types"); } -rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::symbols_in_res_block_c_( - const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_& other) + +// SecurityConfigSMC ::= SEQUENCE +SRSASN_CODE security_cfg_smc_s::pack(bit_ref& bref) const { - type_ = other.type(); - switch (type_) { - case types::one_slot: - c.init(other.c.get >()); - break; - case types::two_slots: - c.init(other.c.get >()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); - } + bref.pack(ext, 1); + HANDLE_CODE(security_algorithm_cfg.pack(bref)); + + return SRSASN_SUCCESS; } -rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_& -rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_:: -operator=(const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_& other) +SRSASN_CODE security_cfg_smc_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::one_slot: - c.set(other.c.get >()); - break; - case types::two_slots: - c.set(other.c.get >()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); - } + bref.unpack(ext, 1); + HANDLE_CODE(security_algorithm_cfg.unpack(bref)); - return *this; + return SRSASN_SUCCESS; } -void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::to_json(json_writer& j) const +void security_cfg_smc_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::one_slot: - j.write_str("oneSlot", c.get >().to_string()); - break; - case types::two_slots: - j.write_str("twoSlots", c.get >().to_string()); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); - } + j.write_fieldname("securityAlgorithmConfig"); + security_algorithm_cfg.to_json(j); j.end_obj(); } -SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::one_slot: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::two_slots: - HANDLE_CODE(c.get >().pack(bref)); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::one_slot: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::two_slots: - HANDLE_CODE(c.get >().unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; -} -std::string rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types_opts::to_string() const -{ - static const char* options[] = {"oneSlot", "twoSlots"}; - return convert_enum_idx( - options, 2, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types"); -} -uint8_t rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types_opts::to_number() const +// SuspendConfig ::= SEQUENCE +SRSASN_CODE suspend_cfg_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {1, 2}; - return map_enum_number( - options, 2, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(ran_notif_area_info_present, 1)); + HANDLE_CODE(bref.pack(t380_present, 1)); -void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::destroy_() -{ - switch (type_) { - case types::n2: - c.destroy >(); - break; - case types::n4: - c.destroy >(); - break; - case types::n5: - c.destroy >(); - break; - case types::n8: - c.destroy >(); - break; - case types::n10: - c.destroy >(); - break; - case types::n20: - c.destroy >(); - break; - case types::n40: - c.destroy >(); - break; - default: - break; - } -} -void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::n2: - c.init >(); - break; - case types::n4: - c.init >(); - break; - case types::n5: - c.init >(); - break; - case types::n8: - c.init >(); - break; - case types::n10: - c.init >(); - break; - case types::n20: - c.init >(); - break; - case types::n40: - c.init >(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); + HANDLE_CODE(full_i_rnti.pack(bref)); + HANDLE_CODE(short_i_rnti.pack(bref)); + HANDLE_CODE(ran_paging_cycle.pack(bref)); + if (ran_notif_area_info_present) { + HANDLE_CODE(ran_notif_area_info.pack(bref)); } -} -rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::periodicity_and_pattern_c_( - const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::n2: - c.init(other.c.get >()); - break; - case types::n4: - c.init(other.c.get >()); - break; - case types::n5: - c.init(other.c.get >()); - break; - case types::n8: - c.init(other.c.get >()); - break; - case types::n10: - c.init(other.c.get >()); - break; - case types::n20: - c.init(other.c.get >()); - break; - case types::n40: - c.init(other.c.get >()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); + if (t380_present) { + HANDLE_CODE(t380.pack(bref)); } + HANDLE_CODE(pack_integer(bref, next_hop_chaining_count, (uint8_t)0u, (uint8_t)7u)); + + return SRSASN_SUCCESS; } -rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_& -rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_:: -operator=(const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_& other) +SRSASN_CODE suspend_cfg_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(ran_notif_area_info_present, 1)); + HANDLE_CODE(bref.unpack(t380_present, 1)); + + HANDLE_CODE(full_i_rnti.unpack(bref)); + HANDLE_CODE(short_i_rnti.unpack(bref)); + HANDLE_CODE(ran_paging_cycle.unpack(bref)); + if (ran_notif_area_info_present) { + HANDLE_CODE(ran_notif_area_info.unpack(bref)); } - set(other.type()); - switch (type_) { - case types::n2: - c.set(other.c.get >()); - break; - case types::n4: - c.set(other.c.get >()); - break; - case types::n5: - c.set(other.c.get >()); - break; - case types::n8: - c.set(other.c.get >()); - break; - case types::n10: - c.set(other.c.get >()); - break; - case types::n20: - c.set(other.c.get >()); - break; - case types::n40: - c.set(other.c.get >()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); + if (t380_present) { + HANDLE_CODE(t380.unpack(bref)); } + HANDLE_CODE(unpack_integer(next_hop_chaining_count, bref, (uint8_t)0u, (uint8_t)7u)); - return *this; + return SRSASN_SUCCESS; } -void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::to_json(json_writer& j) const +void suspend_cfg_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::n2: - j.write_str("n2", c.get >().to_string()); - break; - case types::n4: - j.write_str("n4", c.get >().to_string()); - break; - case types::n5: - j.write_str("n5", c.get >().to_string()); - break; - case types::n8: - j.write_str("n8", c.get >().to_string()); - break; - case types::n10: - j.write_str("n10", c.get >().to_string()); - break; - case types::n20: - j.write_str("n20", c.get >().to_string()); - break; - case types::n40: - j.write_str("n40", c.get >().to_string()); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); + j.write_str("fullI-RNTI", full_i_rnti.to_string()); + j.write_str("shortI-RNTI", short_i_rnti.to_string()); + j.write_str("ran-PagingCycle", ran_paging_cycle.to_string()); + if (ran_notif_area_info_present) { + j.write_fieldname("ran-NotificationAreaInfo"); + ran_notif_area_info.to_json(j); + } + if (t380_present) { + j.write_str("t380", t380.to_string()); } + j.write_int("nextHopChainingCount", next_hop_chaining_count); j.end_obj(); } -SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::pack(bit_ref& bref) const + +// CounterCheck-IEs ::= SEQUENCE +SRSASN_CODE counter_check_ies_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::n2: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::n4: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::n5: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::n8: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::n10: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::n20: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::n40: - HANDLE_CODE(c.get >().pack(bref)); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + HANDLE_CODE(pack_dyn_seq_of(bref, drb_count_msb_info_list, 1, 29)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } + return SRSASN_SUCCESS; } -SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::unpack(cbit_ref& bref) +SRSASN_CODE counter_check_ies_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::n2: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::n4: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::n5: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::n8: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::n10: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::n20: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::n40: - HANDLE_CODE(c.get >().unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); - return SRSASN_ERROR_DECODE_FAIL; + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + HANDLE_CODE(unpack_dyn_seq_of(drb_count_msb_info_list, bref, 1, 29)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - return SRSASN_SUCCESS; -} -std::string rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types_opts::to_string() const -{ - static const char* options[] = {"n2", "n4", "n5", "n8", "n10", "n20", "n40"}; - return convert_enum_idx( - options, 7, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types"); -} -uint8_t rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {2, 4, 5, 8, 10, 20, 40}; - return map_enum_number( - options, 7, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types"); + return SRSASN_SUCCESS; } - -std::string rate_match_pattern_s::pattern_type_c_::types_opts::to_string() const +void counter_check_ies_s::to_json(json_writer& j) const { - static const char* options[] = {"bitmaps", "controlResourceSet"}; - return convert_enum_idx(options, 2, value, "rate_match_pattern_s::pattern_type_c_::types"); + j.start_obj(); + j.start_array("drb-CountMSB-InfoList"); + for (const auto& e1 : drb_count_msb_info_list) { + e1.to_json(j); + } + j.end_array(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); } -std::string rate_match_pattern_s::dummy_opts::to_string() const +// DLInformationTransfer-IEs ::= SEQUENCE +SRSASN_CODE dl_info_transfer_ies_s::pack(bit_ref& bref) const { - static const char* options[] = {"dynamic", "semiStatic"}; - return convert_enum_idx(options, 2, value, "rate_match_pattern_s::dummy_e_"); -} + HANDLE_CODE(bref.pack(ded_nas_msg_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); -void rate_match_pattern_group_item_c_::destroy_() {} -void rate_match_pattern_group_item_c_::set(types::options e) -{ - destroy_(); - type_ = e; -} -rate_match_pattern_group_item_c_::rate_match_pattern_group_item_c_(const rate_match_pattern_group_item_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::cell_level: - c.init(other.c.get()); - break; - case types::bwp_level: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); + if (ded_nas_msg_present) { + HANDLE_CODE(ded_nas_msg.pack(bref)); } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; } -rate_match_pattern_group_item_c_& rate_match_pattern_group_item_c_:: - operator=(const rate_match_pattern_group_item_c_& other) +SRSASN_CODE dl_info_transfer_ies_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + HANDLE_CODE(bref.unpack(ded_nas_msg_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (ded_nas_msg_present) { + HANDLE_CODE(ded_nas_msg.unpack(bref)); } - set(other.type()); - switch (type_) { - case types::cell_level: - c.set(other.c.get()); - break; - case types::bwp_level: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - return *this; + return SRSASN_SUCCESS; } -void rate_match_pattern_group_item_c_::to_json(json_writer& j) const +void dl_info_transfer_ies_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::cell_level: - j.write_int("cellLevel", c.get()); - break; - case types::bwp_level: - j.write_int("bwpLevel", c.get()); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); + if (ded_nas_msg_present) { + j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); } - j.end_obj(); -} -SRSASN_CODE rate_match_pattern_group_item_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::cell_level: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); - break; - case types::bwp_level: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - return SRSASN_SUCCESS; -} -SRSASN_CODE rate_match_pattern_group_item_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::cell_level: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); - break; - case types::bwp_level: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); - break; - default: - log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); - return SRSASN_ERROR_DECODE_FAIL; + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } - return SRSASN_SUCCESS; -} - -std::string rate_match_pattern_group_item_c_::types_opts::to_string() const -{ - static const char* options[] = {"cellLevel", "bwpLevel"}; - return convert_enum_idx(options, 2, value, "rate_match_pattern_group_item_c_::types"); + j.end_obj(); } -// SRS-CC-SetIndex ::= SEQUENCE -SRSASN_CODE srs_cc_set_idx_s::pack(bit_ref& bref) const +// MobilityFromNRCommand-IEs ::= SEQUENCE +SRSASN_CODE mob_from_nr_cmd_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(cc_set_idx_present, 1)); - HANDLE_CODE(bref.pack(cc_idx_in_one_cc_set_present, 1)); + HANDLE_CODE(bref.pack(nas_security_param_from_nr_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (cc_set_idx_present) { - HANDLE_CODE(pack_integer(bref, cc_set_idx, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(target_rat_type.pack(bref)); + HANDLE_CODE(target_rat_msg_container.pack(bref)); + if (nas_security_param_from_nr_present) { + HANDLE_CODE(nas_security_param_from_nr.pack(bref)); } - if (cc_idx_in_one_cc_set_present) { - HANDLE_CODE(pack_integer(bref, cc_idx_in_one_cc_set, (uint8_t)0u, (uint8_t)7u)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE srs_cc_set_idx_s::unpack(cbit_ref& bref) +SRSASN_CODE mob_from_nr_cmd_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(cc_set_idx_present, 1)); - HANDLE_CODE(bref.unpack(cc_idx_in_one_cc_set_present, 1)); + HANDLE_CODE(bref.unpack(nas_security_param_from_nr_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (cc_set_idx_present) { - HANDLE_CODE(unpack_integer(cc_set_idx, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(target_rat_type.unpack(bref)); + HANDLE_CODE(target_rat_msg_container.unpack(bref)); + if (nas_security_param_from_nr_present) { + HANDLE_CODE(nas_security_param_from_nr.unpack(bref)); } - if (cc_idx_in_one_cc_set_present) { - HANDLE_CODE(unpack_integer(cc_idx_in_one_cc_set, bref, (uint8_t)0u, (uint8_t)7u)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void srs_cc_set_idx_s::to_json(json_writer& j) const +void mob_from_nr_cmd_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (cc_set_idx_present) { - j.write_int("cc-SetIndex", cc_set_idx); + j.write_str("targetRAT-Type", target_rat_type.to_string()); + j.write_str("targetRAT-MessageContainer", target_rat_msg_container.to_string()); + if (nas_security_param_from_nr_present) { + j.write_str("nas-SecurityParamFromNR", nas_security_param_from_nr.to_string()); } - if (cc_idx_in_one_cc_set_present) { - j.write_int("cc-IndexInOneCC-Set", cc_idx_in_one_cc_set); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - j.end_obj(); -} - -// SRS-Config ::= SEQUENCE -SRSASN_CODE srs_cfg_s::pack(bit_ref& bref) const + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); +} + +std::string mob_from_nr_cmd_ies_s::target_rat_type_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(srs_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(srs_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(srs_res_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(srs_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(tpc_accumulation_present, 1)); + static const char* options[] = {"eutra", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 4, value, "mob_from_nr_cmd_ies_s::target_rat_type_e_"); +} - if (srs_res_set_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_set_to_release_list, 1, 16, integer_packer(0, 15))); +// RRCReconfiguration-IEs ::= SEQUENCE +SRSASN_CODE rrc_recfg_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(radio_bearer_cfg_present, 1)); + HANDLE_CODE(bref.pack(secondary_cell_group_present, 1)); + HANDLE_CODE(bref.pack(meas_cfg_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (radio_bearer_cfg_present) { + HANDLE_CODE(radio_bearer_cfg.pack(bref)); } - if (srs_res_set_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_set_to_add_mod_list, 1, 16)); + if (secondary_cell_group_present) { + HANDLE_CODE(secondary_cell_group.pack(bref)); } - if (srs_res_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_to_release_list, 1, 64, integer_packer(0, 63))); + if (meas_cfg_present) { + HANDLE_CODE(meas_cfg.pack(bref)); } - if (srs_res_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_to_add_mod_list, 1, 64)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE srs_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_recfg_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(srs_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(srs_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(srs_res_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(srs_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(tpc_accumulation_present, 1)); + HANDLE_CODE(bref.unpack(radio_bearer_cfg_present, 1)); + HANDLE_CODE(bref.unpack(secondary_cell_group_present, 1)); + HANDLE_CODE(bref.unpack(meas_cfg_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (srs_res_set_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(srs_res_set_to_release_list, bref, 1, 16, integer_packer(0, 15))); + if (radio_bearer_cfg_present) { + HANDLE_CODE(radio_bearer_cfg.unpack(bref)); } - if (srs_res_set_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(srs_res_set_to_add_mod_list, bref, 1, 16)); + if (secondary_cell_group_present) { + HANDLE_CODE(secondary_cell_group.unpack(bref)); } - if (srs_res_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(srs_res_to_release_list, bref, 1, 64, integer_packer(0, 63))); + if (meas_cfg_present) { + HANDLE_CODE(meas_cfg.unpack(bref)); } - if (srs_res_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(srs_res_to_add_mod_list, bref, 1, 64)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void srs_cfg_s::to_json(json_writer& j) const +void rrc_recfg_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (srs_res_set_to_release_list_present) { - j.start_array("srs-ResourceSetToReleaseList"); - for (const auto& e1 : srs_res_set_to_release_list) { - j.write_int(e1); - } - j.end_array(); + if (radio_bearer_cfg_present) { + j.write_fieldname("radioBearerConfig"); + radio_bearer_cfg.to_json(j); } - if (srs_res_set_to_add_mod_list_present) { - j.start_array("srs-ResourceSetToAddModList"); - for (const auto& e1 : srs_res_set_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); + if (secondary_cell_group_present) { + j.write_str("secondaryCellGroup", secondary_cell_group.to_string()); } - if (srs_res_to_release_list_present) { - j.start_array("srs-ResourceToReleaseList"); - for (const auto& e1 : srs_res_to_release_list) { - j.write_int(e1); - } - j.end_array(); + if (meas_cfg_present) { + j.write_fieldname("measConfig"); + meas_cfg.to_json(j); } - if (srs_res_to_add_mod_list_present) { - j.start_array("srs-ResourceToAddModList"); - for (const auto& e1 : srs_res_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (tpc_accumulation_present) { - j.write_str("tpc-Accumulation", "disabled"); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } j.end_obj(); } -// SRS-TPC-CommandConfig ::= SEQUENCE -SRSASN_CODE srs_tpc_cmd_cfg_s::pack(bit_ref& bref) const +// RRCReestablishment-IEs ::= SEQUENCE +SRSASN_CODE rrc_reest_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(start_bit_of_format2_minus3_present, 1)); - HANDLE_CODE(bref.pack(field_type_format2_minus3_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (start_bit_of_format2_minus3_present) { - HANDLE_CODE(pack_integer(bref, start_bit_of_format2_minus3, (uint8_t)1u, (uint8_t)31u)); - } - if (field_type_format2_minus3_present) { - HANDLE_CODE(pack_integer(bref, field_type_format2_minus3, (uint8_t)0u, (uint8_t)1u)); + HANDLE_CODE(pack_integer(bref, next_hop_chaining_count, (uint8_t)0u, (uint8_t)7u)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= start_bit_of_format2_minus3_sul_v1530_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(start_bit_of_format2_minus3_sul_v1530_present, 1)); - if (start_bit_of_format2_minus3_sul_v1530_present) { - HANDLE_CODE(pack_integer(bref, start_bit_of_format2_minus3_sul_v1530, (uint8_t)1u, (uint8_t)31u)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE srs_tpc_cmd_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_reest_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(start_bit_of_format2_minus3_present, 1)); - HANDLE_CODE(bref.unpack(field_type_format2_minus3_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (start_bit_of_format2_minus3_present) { - HANDLE_CODE(unpack_integer(start_bit_of_format2_minus3, bref, (uint8_t)1u, (uint8_t)31u)); - } - if (field_type_format2_minus3_present) { - HANDLE_CODE(unpack_integer(field_type_format2_minus3, bref, (uint8_t)0u, (uint8_t)1u)); + HANDLE_CODE(unpack_integer(next_hop_chaining_count, bref, (uint8_t)0u, (uint8_t)7u)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(start_bit_of_format2_minus3_sul_v1530_present, 1)); - if (start_bit_of_format2_minus3_sul_v1530_present) { - HANDLE_CODE(unpack_integer(start_bit_of_format2_minus3_sul_v1530, bref, (uint8_t)1u, (uint8_t)31u)); - } - } - } return SRSASN_SUCCESS; } -void srs_tpc_cmd_cfg_s::to_json(json_writer& j) const +void rrc_reest_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (start_bit_of_format2_minus3_present) { - j.write_int("startingBitOfFormat2-3", start_bit_of_format2_minus3); - } - if (field_type_format2_minus3_present) { - j.write_int("fieldTypeFormat2-3", field_type_format2_minus3); + j.write_int("nextHopChainingCount", next_hop_chaining_count); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (ext) { - if (start_bit_of_format2_minus3_sul_v1530_present) { - j.write_int("startingBitOfFormat2-3SUL-v1530", start_bit_of_format2_minus3_sul_v1530); - } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -// SlotFormatCombination ::= SEQUENCE -SRSASN_CODE slot_format_combination_s::pack(bit_ref& bref) const +// RRCRelease-IEs ::= SEQUENCE +SRSASN_CODE rrc_release_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, slot_format_combination_id, (uint16_t)0u, (uint16_t)511u)); - HANDLE_CODE(pack_dyn_seq_of(bref, slot_formats, 1, 256, integer_packer(0, 255))); + HANDLE_CODE(bref.pack(redirected_carrier_info_present, 1)); + HANDLE_CODE(bref.pack(cell_resel_priorities_present, 1)); + HANDLE_CODE(bref.pack(suspend_cfg_present, 1)); + HANDLE_CODE(bref.pack(depriorit_req_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (redirected_carrier_info_present) { + HANDLE_CODE(redirected_carrier_info.pack(bref)); + } + if (cell_resel_priorities_present) { + HANDLE_CODE(cell_resel_priorities.pack(bref)); + } + if (suspend_cfg_present) { + HANDLE_CODE(suspend_cfg.pack(bref)); + } + if (depriorit_req_present) { + HANDLE_CODE(depriorit_req.depriorit_type.pack(bref)); + HANDLE_CODE(depriorit_req.depriorit_timer.pack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE slot_format_combination_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_release_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(slot_format_combination_id, bref, (uint16_t)0u, (uint16_t)511u)); - HANDLE_CODE(unpack_dyn_seq_of(slot_formats, bref, 1, 256, integer_packer(0, 255))); + HANDLE_CODE(bref.unpack(redirected_carrier_info_present, 1)); + HANDLE_CODE(bref.unpack(cell_resel_priorities_present, 1)); + HANDLE_CODE(bref.unpack(suspend_cfg_present, 1)); + HANDLE_CODE(bref.unpack(depriorit_req_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (redirected_carrier_info_present) { + HANDLE_CODE(redirected_carrier_info.unpack(bref)); + } + if (cell_resel_priorities_present) { + HANDLE_CODE(cell_resel_priorities.unpack(bref)); + } + if (suspend_cfg_present) { + HANDLE_CODE(suspend_cfg.unpack(bref)); + } + if (depriorit_req_present) { + HANDLE_CODE(depriorit_req.depriorit_type.unpack(bref)); + HANDLE_CODE(depriorit_req.depriorit_timer.unpack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } return SRSASN_SUCCESS; } -void slot_format_combination_s::to_json(json_writer& j) const +void rrc_release_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("slotFormatCombinationId", slot_format_combination_id); - j.start_array("slotFormats"); - for (const auto& e1 : slot_formats) { - j.write_int(e1); + if (redirected_carrier_info_present) { + j.write_fieldname("redirectedCarrierInfo"); + redirected_carrier_info.to_json(j); + } + if (cell_resel_priorities_present) { + j.write_fieldname("cellReselectionPriorities"); + cell_resel_priorities.to_json(j); + } + if (suspend_cfg_present) { + j.write_fieldname("suspendConfig"); + suspend_cfg.to_json(j); + } + if (depriorit_req_present) { + j.write_fieldname("deprioritisationReq"); + j.start_obj(); + j.write_str("deprioritisationType", depriorit_req.depriorit_type.to_string()); + j.write_str("deprioritisationTimer", depriorit_req.depriorit_timer.to_string()); + j.end_obj(); + } + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } - j.end_array(); j.end_obj(); } -// TCI-State ::= SEQUENCE -SRSASN_CODE tci_state_s::pack(bit_ref& bref) const +std::string rrc_release_ies_s::depriorit_req_s_::depriorit_type_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(qcl_type2_present, 1)); + static const char* options[] = {"frequency", "nr"}; + return convert_enum_idx(options, 2, value, "rrc_release_ies_s::depriorit_req_s_::depriorit_type_e_"); +} - HANDLE_CODE(pack_integer(bref, tci_state_id, (uint8_t)0u, (uint8_t)127u)); - HANDLE_CODE(qcl_type1.pack(bref)); - if (qcl_type2_present) { - HANDLE_CODE(qcl_type2.pack(bref)); +std::string rrc_release_ies_s::depriorit_req_s_::depriorit_timer_opts::to_string() const +{ + static const char* options[] = {"min5", "min10", "min15", "min30"}; + return convert_enum_idx(options, 4, value, "rrc_release_ies_s::depriorit_req_s_::depriorit_timer_e_"); +} +uint8_t rrc_release_ies_s::depriorit_req_s_::depriorit_timer_opts::to_number() const +{ + static const uint8_t options[] = {5, 10, 15, 30}; + return map_enum_number(options, 4, value, "rrc_release_ies_s::depriorit_req_s_::depriorit_timer_e_"); +} + +// RRCResume-IEs ::= SEQUENCE +SRSASN_CODE rrc_resume_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(radio_bearer_cfg_present, 1)); + HANDLE_CODE(bref.pack(master_cell_group_present, 1)); + HANDLE_CODE(bref.pack(meas_cfg_present, 1)); + HANDLE_CODE(bref.pack(full_cfg_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (radio_bearer_cfg_present) { + HANDLE_CODE(radio_bearer_cfg.pack(bref)); + } + if (master_cell_group_present) { + HANDLE_CODE(master_cell_group.pack(bref)); + } + if (meas_cfg_present) { + HANDLE_CODE(meas_cfg.pack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE tci_state_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_resume_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(qcl_type2_present, 1)); + HANDLE_CODE(bref.unpack(radio_bearer_cfg_present, 1)); + HANDLE_CODE(bref.unpack(master_cell_group_present, 1)); + HANDLE_CODE(bref.unpack(meas_cfg_present, 1)); + HANDLE_CODE(bref.unpack(full_cfg_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - HANDLE_CODE(unpack_integer(tci_state_id, bref, (uint8_t)0u, (uint8_t)127u)); - HANDLE_CODE(qcl_type1.unpack(bref)); - if (qcl_type2_present) { - HANDLE_CODE(qcl_type2.unpack(bref)); + if (radio_bearer_cfg_present) { + HANDLE_CODE(radio_bearer_cfg.unpack(bref)); + } + if (master_cell_group_present) { + HANDLE_CODE(master_cell_group.unpack(bref)); + } + if (meas_cfg_present) { + HANDLE_CODE(meas_cfg.unpack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void tci_state_s::to_json(json_writer& j) const +void rrc_resume_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("tci-StateId", tci_state_id); - j.write_fieldname("qcl-Type1"); - qcl_type1.to_json(j); - if (qcl_type2_present) { - j.write_fieldname("qcl-Type2"); - qcl_type2.to_json(j); + if (radio_bearer_cfg_present) { + j.write_fieldname("radioBearerConfig"); + radio_bearer_cfg.to_json(j); + } + if (master_cell_group_present) { + j.write_str("masterCellGroup", master_cell_group.to_string()); + } + if (meas_cfg_present) { + j.write_fieldname("measConfig"); + meas_cfg.to_json(j); + } + if (full_cfg_present) { + j.write_str("fullConfig", "true"); + } + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } j.end_obj(); } -// ZP-CSI-RS-Resource ::= SEQUENCE -SRSASN_CODE zp_csi_rs_res_s::pack(bit_ref& bref) const +// SecurityModeCommand-IEs ::= SEQUENCE +SRSASN_CODE security_mode_cmd_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - HANDLE_CODE(pack_integer(bref, zp_csi_rs_res_id, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(res_map.pack(bref)); - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.pack(bref)); + HANDLE_CODE(security_cfg_smc.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE zp_csi_rs_res_s::unpack(cbit_ref& bref) +SRSASN_CODE security_mode_cmd_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - HANDLE_CODE(unpack_integer(zp_csi_rs_res_id, bref, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(res_map.unpack(bref)); - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.unpack(bref)); + HANDLE_CODE(security_cfg_smc.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void zp_csi_rs_res_s::to_json(json_writer& j) const +void security_mode_cmd_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("zp-CSI-RS-ResourceId", zp_csi_rs_res_id); - j.write_fieldname("resourceMapping"); - res_map.to_json(j); - if (periodicity_and_offset_present) { - j.write_fieldname("periodicityAndOffset"); - periodicity_and_offset.to_json(j); + j.write_fieldname("securityConfigSMC"); + security_cfg_smc.to_json(j); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -// ZP-CSI-RS-ResourceSet ::= SEQUENCE -SRSASN_CODE zp_csi_rs_res_set_s::pack(bit_ref& bref) const +// UECapabilityEnquiry-IEs ::= SEQUENCE +SRSASN_CODE ue_cap_enquiry_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, zp_csi_rs_res_set_id, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(pack_dyn_seq_of(bref, zp_csi_rs_res_id_list, 1, 16, integer_packer(0, 31))); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(ue_cap_enquiry_ext_present, 1)); + + HANDLE_CODE(pack_dyn_seq_of(bref, ue_cap_rat_request_list, 1, 8)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + if (ue_cap_enquiry_ext_present) { + HANDLE_CODE(ue_cap_enquiry_ext.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE zp_csi_rs_res_set_s::unpack(cbit_ref& bref) +SRSASN_CODE ue_cap_enquiry_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(zp_csi_rs_res_set_id, bref, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(unpack_dyn_seq_of(zp_csi_rs_res_id_list, bref, 1, 16, integer_packer(0, 31))); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(ue_cap_enquiry_ext_present, 1)); + + HANDLE_CODE(unpack_dyn_seq_of(ue_cap_rat_request_list, bref, 1, 8)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + if (ue_cap_enquiry_ext_present) { + HANDLE_CODE(ue_cap_enquiry_ext.unpack(bref)); + } return SRSASN_SUCCESS; } -void zp_csi_rs_res_set_s::to_json(json_writer& j) const +void ue_cap_enquiry_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("zp-CSI-RS-ResourceSetId", zp_csi_rs_res_set_id); - j.start_array("zp-CSI-RS-ResourceIdList"); - for (const auto& e1 : zp_csi_rs_res_id_list) { - j.write_int(e1); + j.start_array("ue-CapabilityRAT-RequestList"); + for (const auto& e1 : ue_cap_rat_request_list) { + e1.to_json(j); } j.end_array(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (ue_cap_enquiry_ext_present) { + j.write_str("ue-CapabilityEnquiryExt", ue_cap_enquiry_ext.to_string()); + } j.end_obj(); } -// BWP-UplinkDedicated ::= SEQUENCE -SRSASN_CODE bwp_ul_ded_s::pack(bit_ref& bref) const +// CounterCheck ::= SEQUENCE +SRSASN_CODE counter_check_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(pucch_cfg_present, 1)); - HANDLE_CODE(bref.pack(pusch_cfg_present, 1)); - HANDLE_CODE(bref.pack(cfgured_grant_cfg_present, 1)); - HANDLE_CODE(bref.pack(srs_cfg_present, 1)); - HANDLE_CODE(bref.pack(beam_fail_recovery_cfg_present, 1)); - - if (pucch_cfg_present) { - HANDLE_CODE(pucch_cfg.pack(bref)); - } - if (pusch_cfg_present) { - HANDLE_CODE(pusch_cfg.pack(bref)); - } - if (cfgured_grant_cfg_present) { - HANDLE_CODE(cfgured_grant_cfg.pack(bref)); - } - if (srs_cfg_present) { - HANDLE_CODE(srs_cfg.pack(bref)); - } - if (beam_fail_recovery_cfg_present) { - HANDLE_CODE(beam_fail_recovery_cfg.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE bwp_ul_ded_s::unpack(cbit_ref& bref) +SRSASN_CODE counter_check_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(pucch_cfg_present, 1)); - HANDLE_CODE(bref.unpack(pusch_cfg_present, 1)); - HANDLE_CODE(bref.unpack(cfgured_grant_cfg_present, 1)); - HANDLE_CODE(bref.unpack(srs_cfg_present, 1)); - HANDLE_CODE(bref.unpack(beam_fail_recovery_cfg_present, 1)); - - if (pucch_cfg_present) { - HANDLE_CODE(pucch_cfg.unpack(bref)); - } - if (pusch_cfg_present) { - HANDLE_CODE(pusch_cfg.unpack(bref)); - } - if (cfgured_grant_cfg_present) { - HANDLE_CODE(cfgured_grant_cfg.unpack(bref)); - } - if (srs_cfg_present) { - HANDLE_CODE(srs_cfg.unpack(bref)); - } - if (beam_fail_recovery_cfg_present) { - HANDLE_CODE(beam_fail_recovery_cfg.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void bwp_ul_ded_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (pucch_cfg_present) { - j.write_fieldname("pucch-Config"); - pucch_cfg.to_json(j); - } - if (pusch_cfg_present) { - j.write_fieldname("pusch-Config"); - pusch_cfg.to_json(j); - } - if (cfgured_grant_cfg_present) { - j.write_fieldname("configuredGrantConfig"); - cfgured_grant_cfg.to_json(j); - } - if (srs_cfg_present) { - j.write_fieldname("srs-Config"); - srs_cfg.to_json(j); - } - if (beam_fail_recovery_cfg_present) { - j.write_fieldname("beamFailureRecoveryConfig"); - beam_fail_recovery_cfg.to_json(j); - } - j.end_obj(); -} - -// CFRA-CSIRS-Resource ::= SEQUENCE -SRSASN_CODE cfra_csirs_res_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, csi_rs, (uint8_t)0u, (uint8_t)95u)); - HANDLE_CODE(pack_dyn_seq_of(bref, ra_occasion_list, 1, 64, integer_packer(0, 511))); - HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE cfra_csirs_res_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(csi_rs, bref, (uint8_t)0u, (uint8_t)95u)); - HANDLE_CODE(unpack_dyn_seq_of(ra_occasion_list, bref, 1, 64, integer_packer(0, 511))); - HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); - - return SRSASN_SUCCESS; -} -void cfra_csirs_res_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("csi-RS", csi_rs); - j.start_array("ra-OccasionList"); - for (const auto& e1 : ra_occasion_list) { - j.write_int(e1); - } - j.end_array(); - j.write_int("ra-PreambleIndex", ra_preamb_idx); - j.end_obj(); -} - -// CFRA-SSB-Resource ::= SEQUENCE -SRSASN_CODE cfra_ssb_res_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, ssb, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE cfra_ssb_res_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(ssb, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void cfra_ssb_res_s::to_json(json_writer& j) const +void counter_check_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("ssb", ssb); - j.write_int("ra-PreambleIndex", ra_preamb_idx); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -// CSI-AperiodicTriggerState ::= SEQUENCE -SRSASN_CODE csi_aperiodic_trigger_state_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_dyn_seq_of(bref, associated_report_cfg_info_list, 1, 16)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_aperiodic_trigger_state_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(unpack_dyn_seq_of(associated_report_cfg_info_list, bref, 1, 16)); - - return SRSASN_SUCCESS; -} -void csi_aperiodic_trigger_state_s::to_json(json_writer& j) const +void counter_check_s::crit_exts_c_::destroy_() { - j.start_obj(); - j.start_array("associatedReportConfigInfoList"); - for (const auto& e1 : associated_report_cfg_info_list) { - e1.to_json(j); + switch (type_) { + case types::counter_check: + c.destroy(); + break; + default: + break; } - j.end_array(); - j.end_obj(); } - -// CSI-ReportPeriodicityAndOffset ::= CHOICE -void csi_report_periodicity_and_offset_c::destroy_() {} -void csi_report_periodicity_and_offset_c::set(types::options e) +void counter_check_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; -} -csi_report_periodicity_and_offset_c::csi_report_periodicity_and_offset_c( - const csi_report_periodicity_and_offset_c& other) -{ - type_ = other.type(); switch (type_) { - case types::slots4: - c.init(other.c.get()); - break; - case types::slots5: - c.init(other.c.get()); - break; - case types::slots8: - c.init(other.c.get()); - break; - case types::slots10: - c.init(other.c.get()); - break; - case types::slots16: - c.init(other.c.get()); - break; - case types::slots20: - c.init(other.c.get()); + case types::counter_check: + c.init(); break; - case types::slots40: - c.init(other.c.get()); + case types::crit_exts_future: break; - case types::slots80: - c.init(other.c.get()); + case types::nulltype: break; - case types::slots160: - c.init(other.c.get()); + default: + log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); + } +} +counter_check_s::crit_exts_c_::crit_exts_c_(const counter_check_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::counter_check: + c.init(other.c.get()); break; - case types::slots320: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); } } -csi_report_periodicity_and_offset_c& csi_report_periodicity_and_offset_c:: - operator=(const csi_report_periodicity_and_offset_c& other) +counter_check_s::crit_exts_c_& counter_check_s::crit_exts_c_::operator=(const counter_check_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::slots4: - c.set(other.c.get()); - break; - case types::slots5: - c.set(other.c.get()); - break; - case types::slots8: - c.set(other.c.get()); - break; - case types::slots10: - c.set(other.c.get()); - break; - case types::slots16: - c.set(other.c.get()); - break; - case types::slots20: - c.set(other.c.get()); - break; - case types::slots40: - c.set(other.c.get()); - break; - case types::slots80: - c.set(other.c.get()); - break; - case types::slots160: - c.set(other.c.get()); + case types::counter_check: + c.set(other.c.get()); break; - case types::slots320: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); } return *this; } -void csi_report_periodicity_and_offset_c::to_json(json_writer& j) const +void counter_check_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::slots4: - j.write_int("slots4", c.get()); - break; - case types::slots5: - j.write_int("slots5", c.get()); - break; - case types::slots8: - j.write_int("slots8", c.get()); - break; - case types::slots10: - j.write_int("slots10", c.get()); - break; - case types::slots16: - j.write_int("slots16", c.get()); - break; - case types::slots20: - j.write_int("slots20", c.get()); - break; - case types::slots40: - j.write_int("slots40", c.get()); - break; - case types::slots80: - j.write_int("slots80", c.get()); - break; - case types::slots160: - j.write_int("slots160", c.get()); + case types::counter_check: + j.write_fieldname("counterCheck"); + c.get().to_json(j); break; - case types::slots320: - j.write_int("slots320", c.get()); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE csi_report_periodicity_and_offset_c::pack(bit_ref& bref) const +SRSASN_CODE counter_check_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::slots4: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); - break; - case types::slots5: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); - break; - case types::slots8: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); - break; - case types::slots10: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); - break; - case types::slots16: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); - break; - case types::slots20: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); - break; - case types::slots40: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); - break; - case types::slots80: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); - break; - case types::slots160: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + case types::counter_check: + HANDLE_CODE(c.get().pack(bref)); break; - case types::slots320: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_report_periodicity_and_offset_c::unpack(cbit_ref& bref) +SRSASN_CODE counter_check_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::slots4: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); - break; - case types::slots5: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); - break; - case types::slots8: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); - break; - case types::slots10: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); - break; - case types::slots16: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); - break; - case types::slots20: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); - break; - case types::slots40: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); - break; - case types::slots80: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); - break; - case types::slots160: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + case types::counter_check: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::slots320: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_report_periodicity_and_offset_c::types_opts::to_string() const -{ - static const char* options[] = { - "slots4", "slots5", "slots8", "slots10", "slots16", "slots20", "slots40", "slots80", "slots160", "slots320"}; - return convert_enum_idx(options, 10, value, "csi_report_periodicity_and_offset_c::types"); -} -uint16_t csi_report_periodicity_and_offset_c::types_opts::to_number() const -{ - static const uint16_t options[] = {4, 5, 8, 10, 16, 20, 40, 80, 160, 320}; - return map_enum_number(options, 10, value, "csi_report_periodicity_and_offset_c::types"); -} - -// CSI-SemiPersistentOnPUSCH-TriggerState ::= SEQUENCE -SRSASN_CODE csi_semi_persistent_on_pusch_trigger_state_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, associated_report_cfg_info, (uint8_t)0u, (uint8_t)47u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_semi_persistent_on_pusch_trigger_state_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(associated_report_cfg_info, bref, (uint8_t)0u, (uint8_t)47u)); - - return SRSASN_SUCCESS; -} -void csi_semi_persistent_on_pusch_trigger_state_s::to_json(json_writer& j) const +std::string counter_check_s::crit_exts_c_::types_opts::to_string() const { - j.start_obj(); - j.write_int("associatedReportConfigInfo", associated_report_cfg_info); - j.end_obj(); + static const char* options[] = {"counterCheck", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "counter_check_s::crit_exts_c_::types"); } -// CodebookConfig ::= SEQUENCE -SRSASN_CODE codebook_cfg_s::pack(bit_ref& bref) const +// DLInformationTransfer ::= SEQUENCE +SRSASN_CODE dl_info_transfer_s::pack(bit_ref& bref) const { - HANDLE_CODE(codebook_type.pack(bref)); + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE codebook_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE dl_info_transfer_s::unpack(cbit_ref& bref) { - HANDLE_CODE(codebook_type.unpack(bref)); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void codebook_cfg_s::to_json(json_writer& j) const +void dl_info_transfer_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("codebookType"); - codebook_type.to_json(j); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -void codebook_cfg_s::codebook_type_c_::destroy_() +void dl_info_transfer_s::crit_exts_c_::destroy_() { switch (type_) { - case types::type1: - c.destroy(); - break; - case types::type2: - c.destroy(); + case types::dl_info_transfer: + c.destroy(); break; default: break; } } -void codebook_cfg_s::codebook_type_c_::set(types::options e) +void dl_info_transfer_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::type1: - c.init(); + case types::dl_info_transfer: + c.init(); break; - case types::type2: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::codebook_type_c_(const codebook_cfg_s::codebook_type_c_& other) +dl_info_transfer_s::crit_exts_c_::crit_exts_c_(const dl_info_transfer_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::type1: - c.init(other.c.get()); + case types::dl_info_transfer: + c.init(other.c.get()); break; - case types::type2: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_& codebook_cfg_s::codebook_type_c_:: - operator=(const codebook_cfg_s::codebook_type_c_& other) +dl_info_transfer_s::crit_exts_c_& +dl_info_transfer_s::crit_exts_c_::operator=(const dl_info_transfer_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::type1: - c.set(other.c.get()); + case types::dl_info_transfer: + c.set(other.c.get()); break; - case types::type2: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); } return *this; } -void codebook_cfg_s::codebook_type_c_::to_json(json_writer& j) const +void dl_info_transfer_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::type1: - j.write_fieldname("type1"); - j.start_obj(); - j.write_fieldname("subType"); - c.get().sub_type.to_json(j); - j.write_int("codebookMode", c.get().codebook_mode); - j.end_obj(); + case types::dl_info_transfer: + j.write_fieldname("dlInformationTransfer"); + c.get().to_json(j); break; - case types::type2: - j.write_fieldname("type2"); - j.start_obj(); - j.write_fieldname("subType"); - c.get().sub_type.to_json(j); - j.write_str("phaseAlphabetSize", c.get().phase_alphabet_size.to_string()); - j.write_bool("subbandAmplitude", c.get().subband_amplitude); - j.write_str("numberOfBeams", c.get().nof_beams.to_string()); - j.end_obj(); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::pack(bit_ref& bref) const +SRSASN_CODE dl_info_transfer_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::type1: - HANDLE_CODE(c.get().sub_type.pack(bref)); - HANDLE_CODE(pack_integer(bref, c.get().codebook_mode, (uint8_t)1u, (uint8_t)2u)); + case types::dl_info_transfer: + HANDLE_CODE(c.get().pack(bref)); break; - case types::type2: - HANDLE_CODE(c.get().sub_type.pack(bref)); - HANDLE_CODE(c.get().phase_alphabet_size.pack(bref)); - HANDLE_CODE(bref.pack(c.get().subband_amplitude, 1)); - HANDLE_CODE(c.get().nof_beams.pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE dl_info_transfer_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::type1: - HANDLE_CODE(c.get().sub_type.unpack(bref)); - HANDLE_CODE(unpack_integer(c.get().codebook_mode, bref, (uint8_t)1u, (uint8_t)2u)); + case types::dl_info_transfer: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::type2: - HANDLE_CODE(c.get().sub_type.unpack(bref)); - HANDLE_CODE(c.get().phase_alphabet_size.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().subband_amplitude, 1)); - HANDLE_CODE(c.get().nof_beams.unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::destroy_() +std::string dl_info_transfer_s::crit_exts_c_::types_opts::to_string() const +{ + static const char* options[] = {"dlInformationTransfer", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "dl_info_transfer_s::crit_exts_c_::types"); +} + +// MobilityFromNRCommand ::= SEQUENCE +SRSASN_CODE mob_from_nr_cmd_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE mob_from_nr_cmd_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void mob_from_nr_cmd_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void mob_from_nr_cmd_s::crit_exts_c_::destroy_() { switch (type_) { - case types::type_i_single_panel: - c.destroy(); - break; - case types::type_i_multi_panel: - c.destroy(); + case types::mob_from_nr_cmd: + c.destroy(); break; default: break; } } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::set(types::options e) +void mob_from_nr_cmd_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::type_i_single_panel: - c.init(); + case types::mob_from_nr_cmd: + c.init(); break; - case types::type_i_multi_panel: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::sub_type_c_( - const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_& other) +mob_from_nr_cmd_s::crit_exts_c_::crit_exts_c_(const mob_from_nr_cmd_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::type_i_single_panel: - c.init(other.c.get()); + case types::mob_from_nr_cmd: + c.init(other.c.get()); break; - case types::type_i_multi_panel: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_& codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_:: - operator=(const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_& other) +mob_from_nr_cmd_s::crit_exts_c_& +mob_from_nr_cmd_s::crit_exts_c_::operator=(const mob_from_nr_cmd_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::type_i_single_panel: - c.set(other.c.get()); + case types::mob_from_nr_cmd: + c.set(other.c.get()); break; - case types::type_i_multi_panel: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); } return *this; } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::to_json(json_writer& j) const +void mob_from_nr_cmd_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::type_i_single_panel: - j.write_fieldname("typeI-SinglePanel"); - j.start_obj(); - j.write_fieldname("nrOfAntennaPorts"); - c.get().nr_of_ant_ports.to_json(j); - j.write_str("typeI-SinglePanel-ri-Restriction", - c.get().type_i_single_panel_ri_restrict.to_string()); - j.end_obj(); + case types::mob_from_nr_cmd: + j.write_fieldname("mobilityFromNRCommand"); + c.get().to_json(j); break; - case types::type_i_multi_panel: - j.write_fieldname("typeI-MultiPanel"); - j.start_obj(); - j.write_fieldname("ng-n1-n2"); - c.get().ng_n1_n2.to_json(j); - j.write_str("ri-Restriction", c.get().ri_restrict.to_string()); - j.end_obj(); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::pack(bit_ref& bref) const +SRSASN_CODE mob_from_nr_cmd_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::type_i_single_panel: - HANDLE_CODE(c.get().nr_of_ant_ports.pack(bref)); - HANDLE_CODE(c.get().type_i_single_panel_ri_restrict.pack(bref)); + case types::mob_from_nr_cmd: + HANDLE_CODE(c.get().pack(bref)); break; - case types::type_i_multi_panel: - HANDLE_CODE(c.get().ng_n1_n2.pack(bref)); - HANDLE_CODE(c.get().ri_restrict.pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE mob_from_nr_cmd_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::type_i_single_panel: - HANDLE_CODE(c.get().nr_of_ant_ports.unpack(bref)); - HANDLE_CODE(c.get().type_i_single_panel_ri_restrict.unpack(bref)); + case types::mob_from_nr_cmd: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::type_i_multi_panel: - HANDLE_CODE(c.get().ng_n1_n2.unpack(bref)); - HANDLE_CODE(c.get().ri_restrict.unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::destroy_() +std::string mob_from_nr_cmd_s::crit_exts_c_::types_opts::to_string() const +{ + static const char* options[] = {"mobilityFromNRCommand", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "mob_from_nr_cmd_s::crit_exts_c_::types"); +} + +// RRCReconfiguration ::= SEQUENCE +SRSASN_CODE rrc_recfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_recfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void rrc_recfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void rrc_recfg_s::crit_exts_c_::destroy_() { switch (type_) { - case types::two: - c.destroy(); - break; - case types::more_than_two: - c.destroy(); + case types::rrc_recfg: + c.destroy(); break; default: break; } } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::set( - types::options e) +void rrc_recfg_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::two: - c.init(); + case types::rrc_recfg: + c.init(); break; - case types::more_than_two: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::nr_of_ant_ports_c_( - const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_& other) +rrc_recfg_s::crit_exts_c_::crit_exts_c_(const rrc_recfg_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::two: - c.init(other.c.get()); + case types::rrc_recfg: + c.init(other.c.get()); break; - case types::more_than_two: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_& -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::operator=( - const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_& other) +rrc_recfg_s::crit_exts_c_& rrc_recfg_s::crit_exts_c_::operator=(const rrc_recfg_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::two: - c.set(other.c.get()); + case types::rrc_recfg: + c.set(other.c.get()); break; - case types::more_than_two: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); } return *this; } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::to_json( - json_writer& j) const +void rrc_recfg_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::two: - j.write_fieldname("two"); - j.start_obj(); - j.write_str("twoTX-CodebookSubsetRestriction", c.get().two_tx_codebook_subset_restrict.to_string()); - j.end_obj(); + case types::rrc_recfg: + j.write_fieldname("rrcReconfiguration"); + c.get().to_json(j); break; - case types::more_than_two: - j.write_fieldname("moreThanTwo"); - j.start_obj(); - j.write_fieldname("n1-n2"); - c.get().n1_n2.to_json(j); - if (c.get().type_i_single_panel_codebook_subset_restrict_i2_present) { - j.write_str("typeI-SinglePanel-codebookSubsetRestriction-i2", - c.get().type_i_single_panel_codebook_subset_restrict_i2.to_string()); - } - j.end_obj(); + case types::crit_exts_future: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::pack( - bit_ref& bref) const +SRSASN_CODE rrc_recfg_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::two: - HANDLE_CODE(c.get().two_tx_codebook_subset_restrict.pack(bref)); + case types::rrc_recfg: + HANDLE_CODE(c.get().pack(bref)); break; - case types::more_than_two: - HANDLE_CODE(bref.pack(c.get().type_i_single_panel_codebook_subset_restrict_i2_present, 1)); - HANDLE_CODE(c.get().n1_n2.pack(bref)); - if (c.get().type_i_single_panel_codebook_subset_restrict_i2_present) { - HANDLE_CODE(c.get().type_i_single_panel_codebook_subset_restrict_i2.pack(bref)); - } + case types::crit_exts_future: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::unpack( - cbit_ref& bref) +SRSASN_CODE rrc_recfg_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::two: - HANDLE_CODE(c.get().two_tx_codebook_subset_restrict.unpack(bref)); + case types::rrc_recfg: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::more_than_two: - HANDLE_CODE(bref.unpack(c.get().type_i_single_panel_codebook_subset_restrict_i2_present, 1)); - HANDLE_CODE(c.get().n1_n2.unpack(bref)); - if (c.get().type_i_single_panel_codebook_subset_restrict_i2_present) { - HANDLE_CODE(c.get().type_i_single_panel_codebook_subset_restrict_i2.unpack(bref)); - } + case types::crit_exts_future: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - more_than_two_s_::n1_n2_c_::destroy_() +std::string rrc_recfg_s::crit_exts_c_::types_opts::to_string() const +{ + static const char* options[] = {"rrcReconfiguration", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_recfg_s::crit_exts_c_::types"); +} + +// RRCReestablishment ::= SEQUENCE +SRSASN_CODE rrc_reest_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_reest_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void rrc_reest_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void rrc_reest_s::crit_exts_c_::destroy_() { switch (type_) { - case types::two_one_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::two_two_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::four_one_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::three_two_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::six_one_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::four_two_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::eight_one_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::four_three_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::six_two_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::twelve_one_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::four_four_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::eight_two_type_i_single_panel_restrict: - c.destroy >(); - break; - case types::sixteen_one_type_i_single_panel_restrict: - c.destroy >(); + case types::rrc_reest: + c.destroy(); break; default: break; } } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - more_than_two_s_::n1_n2_c_::set(types::options e) +void rrc_reest_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::two_one_type_i_single_panel_restrict: - c.init >(); - break; - case types::two_two_type_i_single_panel_restrict: - c.init >(); - break; - case types::four_one_type_i_single_panel_restrict: - c.init >(); - break; - case types::three_two_type_i_single_panel_restrict: - c.init >(); - break; - case types::six_one_type_i_single_panel_restrict: - c.init >(); - break; - case types::four_two_type_i_single_panel_restrict: - c.init >(); - break; - case types::eight_one_type_i_single_panel_restrict: - c.init >(); - break; - case types::four_three_type_i_single_panel_restrict: - c.init >(); - break; - case types::six_two_type_i_single_panel_restrict: - c.init >(); - break; - case types::twelve_one_type_i_single_panel_restrict: - c.init >(); - break; - case types::four_four_type_i_single_panel_restrict: - c.init >(); - break; - case types::eight_two_type_i_single_panel_restrict: - c.init >(); + case types::rrc_reest: + c.init(); break; - case types::sixteen_one_type_i_single_panel_restrict: - c.init >(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" - "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::more_than_two_s_:: - n1_n2_c_::n1_n2_c_(const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_:: - nr_of_ant_ports_c_::more_than_two_s_::n1_n2_c_& other) +rrc_reest_s::crit_exts_c_::crit_exts_c_(const rrc_reest_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::two_one_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::two_two_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::four_one_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::three_two_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::six_one_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::four_two_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::eight_one_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::four_three_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::six_two_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::twelve_one_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::four_four_type_i_single_panel_restrict: - c.init(other.c.get >()); - break; - case types::eight_two_type_i_single_panel_restrict: - c.init(other.c.get >()); + case types::rrc_reest: + c.init(other.c.get()); break; - case types::sixteen_one_type_i_single_panel_restrict: - c.init(other.c.get >()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" - "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::more_than_two_s_:: - n1_n2_c_& - codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - more_than_two_s_::n1_n2_c_:: - operator=(const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_:: - nr_of_ant_ports_c_::more_than_two_s_::n1_n2_c_& other) +rrc_reest_s::crit_exts_c_& rrc_reest_s::crit_exts_c_::operator=(const rrc_reest_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::two_one_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::two_two_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::four_one_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::three_two_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::six_one_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::four_two_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::eight_one_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::four_three_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::six_two_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::twelve_one_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::four_four_type_i_single_panel_restrict: - c.set(other.c.get >()); - break; - case types::eight_two_type_i_single_panel_restrict: - c.set(other.c.get >()); + case types::rrc_reest: + c.set(other.c.get()); break; - case types::sixteen_one_type_i_single_panel_restrict: - c.set(other.c.get >()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" - "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); } return *this; } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - more_than_two_s_::n1_n2_c_::to_json(json_writer& j) const +void rrc_reest_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::two_one_type_i_single_panel_restrict: - j.write_str("two-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::two_two_type_i_single_panel_restrict: - j.write_str("two-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::four_one_type_i_single_panel_restrict: - j.write_str("four-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::three_two_type_i_single_panel_restrict: - j.write_str("three-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::six_one_type_i_single_panel_restrict: - j.write_str("six-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::four_two_type_i_single_panel_restrict: - j.write_str("four-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::eight_one_type_i_single_panel_restrict: - j.write_str("eight-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::four_three_type_i_single_panel_restrict: - j.write_str("four-three-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::six_two_type_i_single_panel_restrict: - j.write_str("six-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::twelve_one_type_i_single_panel_restrict: - j.write_str("twelve-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::four_four_type_i_single_panel_restrict: - j.write_str("four-four-TypeI-SinglePanel-Restriction", c.get >().to_string()); - break; - case types::eight_two_type_i_single_panel_restrict: - j.write_str("eight-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); + case types::rrc_reest: + j.write_fieldname("rrcReestablishment"); + c.get().to_json(j); break; - case types::sixteen_one_type_i_single_panel_restrict: - j.write_str("sixteen-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" - "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - more_than_two_s_::n1_n2_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_reest_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::two_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::two_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::four_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::three_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::six_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); + case types::rrc_reest: + HANDLE_CODE(c.get().pack(bref)); break; - case types::four_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); + case types::crit_exts_future: break; - case types::eight_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); + default: + log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_reest_s::crit_exts_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::rrc_reest: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::four_three_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::six_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::twelve_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::four_four_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::eight_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::sixteen_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - default: - log_invalid_choice_id(type_, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" - "ant_ports_c_::more_than_two_s_::n1_n2_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - more_than_two_s_::n1_n2_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::two_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::two_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::three_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::six_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::eight_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_three_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::six_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::twelve_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_four_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::eight_two_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::sixteen_one_type_i_single_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" - "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - more_than_two_s_::n1_n2_c_::types_opts::to_string() const +std::string rrc_reest_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"two-one-TypeI-SinglePanel-Restriction", - "two-two-TypeI-SinglePanel-Restriction", - "four-one-TypeI-SinglePanel-Restriction", - "three-two-TypeI-SinglePanel-Restriction", - "six-one-TypeI-SinglePanel-Restriction", - "four-two-TypeI-SinglePanel-Restriction", - "eight-one-TypeI-SinglePanel-Restriction", - "four-three-TypeI-SinglePanel-Restriction", - "six-two-TypeI-SinglePanel-Restriction", - "twelve-one-TypeI-SinglePanel-Restriction", - "four-four-TypeI-SinglePanel-Restriction", - "eight-two-TypeI-SinglePanel-Restriction", - "sixteen-one-TypeI-SinglePanel-Restriction"}; - return convert_enum_idx(options, - 13, - value, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_" - "ports_c_::more_than_two_s_::n1_n2_c_::types"); + static const char* options[] = {"rrcReestablishment", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_reest_s::crit_exts_c_::types"); } -std::string codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - types_opts::to_string() const +// RRCRelease ::= SEQUENCE +SRSASN_CODE rrc_release_s::pack(bit_ref& bref) const { - static const char* options[] = {"two", "moreThanTwo"}; - return convert_enum_idx( - options, - 2, - value, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::types"); + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; } -uint8_t codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: - types_opts::to_number() const +SRSASN_CODE rrc_release_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {2}; - return map_enum_number( - options, - 1, - value, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::types"); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void rrc_release_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::destroy_() +void rrc_release_s::crit_exts_c_::destroy_() { switch (type_) { - case types::two_two_one_type_i_multi_panel_restrict: - c.destroy >(); - break; - case types::two_four_one_type_i_multi_panel_restrict: - c.destroy >(); - break; - case types::four_two_one_type_i_multi_panel_restrict: - c.destroy >(); - break; - case types::two_two_two_type_i_multi_panel_restrict: - c.destroy >(); - break; - case types::two_eight_one_type_i_multi_panel_restrict: - c.destroy >(); - break; - case types::four_four_one_type_i_multi_panel_restrict: - c.destroy >(); - break; - case types::two_four_two_type_i_multi_panel_restrict: - c.destroy >(); - break; - case types::four_two_two_type_i_multi_panel_restrict: - c.destroy >(); + case types::rrc_release: + c.destroy(); break; default: break; } } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::set(types::options e) +void rrc_release_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::two_two_one_type_i_multi_panel_restrict: - c.init >(); - break; - case types::two_four_one_type_i_multi_panel_restrict: - c.init >(); - break; - case types::four_two_one_type_i_multi_panel_restrict: - c.init >(); - break; - case types::two_two_two_type_i_multi_panel_restrict: - c.init >(); - break; - case types::two_eight_one_type_i_multi_panel_restrict: - c.init >(); - break; - case types::four_four_one_type_i_multi_panel_restrict: - c.init >(); - break; - case types::two_four_two_type_i_multi_panel_restrict: - c.init >(); + case types::rrc_release: + c.init(); break; - case types::four_two_two_type_i_multi_panel_restrict: - c.init >(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::ng_n1_n2_c_( - const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_& other) +rrc_release_s::crit_exts_c_::crit_exts_c_(const rrc_release_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::two_two_one_type_i_multi_panel_restrict: - c.init(other.c.get >()); - break; - case types::two_four_one_type_i_multi_panel_restrict: - c.init(other.c.get >()); - break; - case types::four_two_one_type_i_multi_panel_restrict: - c.init(other.c.get >()); - break; - case types::two_two_two_type_i_multi_panel_restrict: - c.init(other.c.get >()); - break; - case types::two_eight_one_type_i_multi_panel_restrict: - c.init(other.c.get >()); - break; - case types::four_four_one_type_i_multi_panel_restrict: - c.init(other.c.get >()); - break; - case types::two_four_two_type_i_multi_panel_restrict: - c.init(other.c.get >()); + case types::rrc_release: + c.init(other.c.get()); break; - case types::four_two_two_type_i_multi_panel_restrict: - c.init(other.c.get >()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_& -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_:: -operator=(const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_& other) +rrc_release_s::crit_exts_c_& rrc_release_s::crit_exts_c_::operator=(const rrc_release_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::two_two_one_type_i_multi_panel_restrict: - c.set(other.c.get >()); - break; - case types::two_four_one_type_i_multi_panel_restrict: - c.set(other.c.get >()); - break; - case types::four_two_one_type_i_multi_panel_restrict: - c.set(other.c.get >()); - break; - case types::two_two_two_type_i_multi_panel_restrict: - c.set(other.c.get >()); - break; - case types::two_eight_one_type_i_multi_panel_restrict: - c.set(other.c.get >()); - break; - case types::four_four_one_type_i_multi_panel_restrict: - c.set(other.c.get >()); - break; - case types::two_four_two_type_i_multi_panel_restrict: - c.set(other.c.get >()); + case types::rrc_release: + c.set(other.c.get()); break; - case types::four_two_two_type_i_multi_panel_restrict: - c.set(other.c.get >()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); } return *this; } -void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::to_json( - json_writer& j) const +void rrc_release_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::two_two_one_type_i_multi_panel_restrict: - j.write_str("two-two-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); - break; - case types::two_four_one_type_i_multi_panel_restrict: - j.write_str("two-four-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); - break; - case types::four_two_one_type_i_multi_panel_restrict: - j.write_str("four-two-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); - break; - case types::two_two_two_type_i_multi_panel_restrict: - j.write_str("two-two-two-TypeI-MultiPanel-Restriction", c.get >().to_string()); - break; - case types::two_eight_one_type_i_multi_panel_restrict: - j.write_str("two-eight-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); - break; - case types::four_four_one_type_i_multi_panel_restrict: - j.write_str("four-four-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); - break; - case types::two_four_two_type_i_multi_panel_restrict: - j.write_str("two-four-two-TypeI-MultiPanel-Restriction", c.get >().to_string()); + case types::rrc_release: + j.write_fieldname("rrcRelease"); + c.get().to_json(j); break; - case types::four_two_two_type_i_multi_panel_restrict: - j.write_str("four-two-two-TypeI-MultiPanel-Restriction", c.get >().to_string()); + case types::crit_exts_future: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_release_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::two_two_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::two_four_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::four_two_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::two_two_two_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::two_eight_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::four_four_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::two_four_two_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); + case types::rrc_release: + HANDLE_CODE(c.get().pack(bref)); break; - case types::four_two_two_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::unpack(cbit_ref& bref) +SRSASN_CODE rrc_release_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::two_two_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::two_four_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_two_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::two_two_two_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::two_eight_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_four_one_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::two_four_two_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); + case types::rrc_release: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::four_two_two_type_i_multi_panel_restrict: - HANDLE_CODE(c.get >().unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id( - type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string -codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::types_opts::to_string() - const +std::string rrc_release_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"two-two-one-TypeI-MultiPanel-Restriction", - "two-four-one-TypeI-MultiPanel-Restriction", - "four-two-one-TypeI-MultiPanel-Restriction", - "two-two-two-TypeI-MultiPanel-Restriction", - "two-eight-one-TypeI-MultiPanel-Restriction", - "four-four-one-TypeI-MultiPanel-Restriction", - "two-four-two-TypeI-MultiPanel-Restriction", - "four-two-two-TypeI-MultiPanel-Restriction"}; - return convert_enum_idx( - options, - 8, - value, - "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::types"); + static const char* options[] = {"rrcRelease", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_release_s::crit_exts_c_::types"); } -std::string codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::types_opts::to_string() const +// RRCResume ::= SEQUENCE +SRSASN_CODE rrc_resume_s::pack(bit_ref& bref) const { - static const char* options[] = {"typeI-SinglePanel", "typeI-MultiPanel"}; - return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::types"); + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; } +SRSASN_CODE rrc_resume_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); -void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::destroy_() + return SRSASN_SUCCESS; +} +void rrc_resume_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void rrc_resume_s::crit_exts_c_::destroy_() { switch (type_) { - case types::type_ii: - c.destroy(); - break; - case types::type_ii_port_sel: - c.destroy(); + case types::rrc_resume: + c.destroy(); break; default: break; } } -void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::set(types::options e) +void rrc_resume_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::type_ii: - c.init(); + case types::rrc_resume: + c.init(); break; - case types::type_ii_port_sel: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::sub_type_c_( - const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_& other) +rrc_resume_s::crit_exts_c_::crit_exts_c_(const rrc_resume_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::type_ii: - c.init(other.c.get()); + case types::rrc_resume: + c.init(other.c.get()); break; - case types::type_ii_port_sel: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_& codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_:: - operator=(const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_& other) +rrc_resume_s::crit_exts_c_& rrc_resume_s::crit_exts_c_::operator=(const rrc_resume_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::type_ii: - c.set(other.c.get()); + case types::rrc_resume: + c.set(other.c.get()); break; - case types::type_ii_port_sel: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); } return *this; } -void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::to_json(json_writer& j) const +void rrc_resume_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::type_ii: - j.write_fieldname("typeII"); - j.start_obj(); - j.write_fieldname("n1-n2-codebookSubsetRestriction"); - c.get().n1_n2_codebook_subset_restrict.to_json(j); - j.write_str("typeII-RI-Restriction", c.get().type_ii_ri_restrict.to_string()); - j.end_obj(); + case types::rrc_resume: + j.write_fieldname("rrcResume"); + c.get().to_json(j); break; - case types::type_ii_port_sel: - j.write_fieldname("typeII-PortSelection"); - j.start_obj(); - if (c.get().port_sel_sampling_size_present) { - j.write_str("portSelectionSamplingSize", c.get().port_sel_sampling_size.to_string()); - } - j.write_str("typeII-PortSelectionRI-Restriction", - c.get().type_ii_port_sel_ri_restrict.to_string()); - j.end_obj(); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_resume_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::type_ii: - HANDLE_CODE(c.get().n1_n2_codebook_subset_restrict.pack(bref)); - HANDLE_CODE(c.get().type_ii_ri_restrict.pack(bref)); + case types::rrc_resume: + HANDLE_CODE(c.get().pack(bref)); break; - case types::type_ii_port_sel: - HANDLE_CODE(bref.pack(c.get().port_sel_sampling_size_present, 1)); - if (c.get().port_sel_sampling_size_present) { - HANDLE_CODE(c.get().port_sel_sampling_size.pack(bref)); - } - HANDLE_CODE(c.get().type_ii_port_sel_ri_restrict.pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE rrc_resume_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::type_ii: - HANDLE_CODE(c.get().n1_n2_codebook_subset_restrict.unpack(bref)); - HANDLE_CODE(c.get().type_ii_ri_restrict.unpack(bref)); + case types::rrc_resume: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::type_ii_port_sel: - HANDLE_CODE(bref.unpack(c.get().port_sel_sampling_size_present, 1)); - if (c.get().port_sel_sampling_size_present) { - HANDLE_CODE(c.get().port_sel_sampling_size.unpack(bref)); - } - HANDLE_CODE(c.get().type_ii_port_sel_ri_restrict.unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::destroy_() +std::string rrc_resume_s::crit_exts_c_::types_opts::to_string() const { - switch (type_) { - case types::two_one: - c.destroy >(); - break; - case types::two_two: - c.destroy >(); - break; - case types::four_one: - c.destroy >(); - break; - case types::three_two: - c.destroy >(); - break; - case types::six_one: - c.destroy >(); - break; - case types::four_two: - c.destroy >(); - break; - case types::eight_one: - c.destroy >(); - break; - case types::four_three: - c.destroy >(); - break; - case types::six_two: - c.destroy >(); - break; - case types::twelve_one: - c.destroy >(); - break; - case types::four_four: - c.destroy >(); - break; - case types::eight_two: - c.destroy >(); - break; - case types::sixteen_one: - c.destroy >(); + static const char* options[] = {"rrcResume", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_resume_s::crit_exts_c_::types"); +} + +// SecurityModeCommand ::= SEQUENCE +SRSASN_CODE security_mode_cmd_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE security_mode_cmd_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void security_mode_cmd_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void security_mode_cmd_s::crit_exts_c_::destroy_() +{ + switch (type_) { + case types::security_mode_cmd: + c.destroy(); break; default: break; } } -void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::set( - types::options e) +void security_mode_cmd_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::two_one: - c.init >(); - break; - case types::two_two: - c.init >(); - break; - case types::four_one: - c.init >(); - break; - case types::three_two: - c.init >(); - break; - case types::six_one: - c.init >(); - break; - case types::four_two: - c.init >(); + case types::security_mode_cmd: + c.init(); break; - case types::eight_one: - c.init >(); + case types::crit_exts_future: break; - case types::four_three: - c.init >(); + case types::nulltype: break; - case types::six_two: - c.init >(); + default: + log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); + } +} +security_mode_cmd_s::crit_exts_c_::crit_exts_c_(const security_mode_cmd_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::security_mode_cmd: + c.init(other.c.get()); break; - case types::twelve_one: - c.init >(); + case types::crit_exts_future: break; - case types::four_four: - c.init >(); + case types::nulltype: break; - case types::eight_two: - c.init >(); + default: + log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); + } +} +security_mode_cmd_s::crit_exts_c_& +security_mode_cmd_s::crit_exts_c_::operator=(const security_mode_cmd_s::crit_exts_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::security_mode_cmd: + c.set(other.c.get()); break; - case types::sixteen_one: - c.init >(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); + log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); } + + return *this; } -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_:: - n1_n2_codebook_subset_restrict_c_( - const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_& - other) +void security_mode_cmd_s::crit_exts_c_::to_json(json_writer& j) const { - type_ = other.type(); + j.start_obj(); switch (type_) { - case types::two_one: - c.init(other.c.get >()); + case types::security_mode_cmd: + j.write_fieldname("securityModeCommand"); + c.get().to_json(j); break; - case types::two_two: - c.init(other.c.get >()); + case types::crit_exts_future: break; - case types::four_one: - c.init(other.c.get >()); + default: + log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); + } + j.end_obj(); +} +SRSASN_CODE security_mode_cmd_s::crit_exts_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::security_mode_cmd: + HANDLE_CODE(c.get().pack(bref)); break; - case types::three_two: - c.init(other.c.get >()); + case types::crit_exts_future: break; - case types::six_one: - c.init(other.c.get >()); + default: + log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE security_mode_cmd_s::crit_exts_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::security_mode_cmd: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::four_two: - c.init(other.c.get >()); + case types::crit_exts_future: break; - case types::eight_one: - c.init(other.c.get >()); + default: + log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string security_mode_cmd_s::crit_exts_c_::types_opts::to_string() const +{ + static const char* options[] = {"securityModeCommand", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "security_mode_cmd_s::crit_exts_c_::types"); +} + +// UECapabilityEnquiry ::= SEQUENCE +SRSASN_CODE ue_cap_enquiry_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE ue_cap_enquiry_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void ue_cap_enquiry_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void ue_cap_enquiry_s::crit_exts_c_::destroy_() +{ + switch (type_) { + case types::ue_cap_enquiry: + c.destroy(); break; - case types::four_three: - c.init(other.c.get >()); + default: break; - case types::six_two: - c.init(other.c.get >()); + } +} +void ue_cap_enquiry_s::crit_exts_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::ue_cap_enquiry: + c.init(); break; - case types::twelve_one: - c.init(other.c.get >()); + case types::crit_exts_future: break; - case types::four_four: - c.init(other.c.get >()); + case types::nulltype: break; - case types::eight_two: - c.init(other.c.get >()); + default: + log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + } +} +ue_cap_enquiry_s::crit_exts_c_::crit_exts_c_(const ue_cap_enquiry_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::ue_cap_enquiry: + c.init(other.c.get()); break; - case types::sixteen_one: - c.init(other.c.get >()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); + log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); } } -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_& -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::operator=( - const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_& other) +ue_cap_enquiry_s::crit_exts_c_& ue_cap_enquiry_s::crit_exts_c_::operator=(const ue_cap_enquiry_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::two_one: - c.set(other.c.get >()); - break; - case types::two_two: - c.set(other.c.get >()); - break; - case types::four_one: - c.set(other.c.get >()); - break; - case types::three_two: - c.set(other.c.get >()); - break; - case types::six_one: - c.set(other.c.get >()); - break; - case types::four_two: - c.set(other.c.get >()); - break; - case types::eight_one: - c.set(other.c.get >()); - break; - case types::four_three: - c.set(other.c.get >()); - break; - case types::six_two: - c.set(other.c.get >()); - break; - case types::twelve_one: - c.set(other.c.get >()); - break; - case types::four_four: - c.set(other.c.get >()); - break; - case types::eight_two: - c.set(other.c.get >()); + case types::ue_cap_enquiry: + c.set(other.c.get()); break; - case types::sixteen_one: - c.set(other.c.get >()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id( - type_, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); + log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); } return *this; } -void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::to_json( - json_writer& j) const +void ue_cap_enquiry_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::two_one: - j.write_str("two-one", c.get >().to_string()); - break; - case types::two_two: - j.write_str("two-two", c.get >().to_string()); - break; - case types::four_one: - j.write_str("four-one", c.get >().to_string()); + case types::ue_cap_enquiry: + j.write_fieldname("ueCapabilityEnquiry"); + c.get().to_json(j); break; - case types::three_two: - j.write_str("three-two", c.get >().to_string()); + case types::crit_exts_future: break; - case types::six_one: - j.write_str("six-one", c.get >().to_string()); + default: + log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + } + j.end_obj(); +} +SRSASN_CODE ue_cap_enquiry_s::crit_exts_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::ue_cap_enquiry: + HANDLE_CODE(c.get().pack(bref)); break; - case types::four_two: - j.write_str("four-two", c.get >().to_string()); + case types::crit_exts_future: break; - case types::eight_one: - j.write_str("eight-one", c.get >().to_string()); + default: + log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE ue_cap_enquiry_s::crit_exts_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ue_cap_enquiry: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::four_three: - j.write_str("four-three", c.get >().to_string()); + case types::crit_exts_future: break; - case types::six_two: - j.write_str("six-two", c.get >().to_string()); + default: + log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string ue_cap_enquiry_s::crit_exts_c_::types_opts::to_string() const +{ + static const char* options[] = {"ueCapabilityEnquiry", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "ue_cap_enquiry_s::crit_exts_c_::types"); +} + +// DL-DCCH-MessageType ::= CHOICE +void dl_dcch_msg_type_c::destroy_() +{ + switch (type_) { + case types::c1: + c.destroy(); break; - case types::twelve_one: - j.write_str("twelve-one", c.get >().to_string()); + default: break; - case types::four_four: - j.write_str("four-four", c.get >().to_string()); + } +} +void dl_dcch_msg_type_c::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::c1: + c.init(); break; - case types::eight_two: - j.write_str("eight-two", c.get >().to_string()); + case types::msg_class_ext: break; - case types::sixteen_one: - j.write_str("sixteen-one", c.get >().to_string()); + case types::nulltype: break; default: - log_invalid_choice_id( - type_, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); + log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); } - j.end_obj(); } -SRSASN_CODE -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::pack( - bit_ref& bref) const +dl_dcch_msg_type_c::dl_dcch_msg_type_c(const dl_dcch_msg_type_c& other) { - type_.pack(bref); + type_ = other.type(); switch (type_) { - case types::two_one: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::two_two: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::four_one: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::three_two: - HANDLE_CODE(c.get >().pack(bref)); + case types::c1: + c.init(other.c.get()); break; - case types::six_one: - HANDLE_CODE(c.get >().pack(bref)); + case types::msg_class_ext: break; - case types::four_two: - HANDLE_CODE(c.get >().pack(bref)); + case types::nulltype: break; - case types::eight_one: - HANDLE_CODE(c.get >().pack(bref)); + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + } +} +dl_dcch_msg_type_c& dl_dcch_msg_type_c::operator=(const dl_dcch_msg_type_c& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::c1: + c.set(other.c.get()); break; - case types::four_three: - HANDLE_CODE(c.get >().pack(bref)); + case types::msg_class_ext: break; - case types::six_two: - HANDLE_CODE(c.get >().pack(bref)); + case types::nulltype: break; - case types::twelve_one: - HANDLE_CODE(c.get >().pack(bref)); + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + } + + return *this; +} +void dl_dcch_msg_type_c::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::c1: + j.write_fieldname("c1"); + c.get().to_json(j); break; - case types::four_four: - HANDLE_CODE(c.get >().pack(bref)); + case types::msg_class_ext: break; - case types::eight_two: - HANDLE_CODE(c.get >().pack(bref)); + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + } + j.end_obj(); +} +SRSASN_CODE dl_dcch_msg_type_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::c1: + HANDLE_CODE(c.get().pack(bref)); break; - case types::sixteen_one: - HANDLE_CODE(c.get >().pack(bref)); + case types::msg_class_ext: break; default: - log_invalid_choice_id( - type_, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); + log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::unpack( - cbit_ref& bref) +SRSASN_CODE dl_dcch_msg_type_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::two_one: - HANDLE_CODE(c.get >().unpack(bref)); + case types::c1: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::two_two: - HANDLE_CODE(c.get >().unpack(bref)); + case types::msg_class_ext: break; - case types::four_one: - HANDLE_CODE(c.get >().unpack(bref)); + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +void dl_dcch_msg_type_c::c1_c_::destroy_() +{ + switch (type_) { + case types::rrc_recfg: + c.destroy(); break; - case types::three_two: - HANDLE_CODE(c.get >().unpack(bref)); + case types::rrc_resume: + c.destroy(); break; - case types::six_one: - HANDLE_CODE(c.get >().unpack(bref)); + case types::rrc_release: + c.destroy(); break; - case types::four_two: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::eight_one: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::four_three: - HANDLE_CODE(c.get >().unpack(bref)); + case types::rrc_reest: + c.destroy(); break; - case types::six_two: - HANDLE_CODE(c.get >().unpack(bref)); + case types::security_mode_cmd: + c.destroy(); break; - case types::twelve_one: - HANDLE_CODE(c.get >().unpack(bref)); + case types::dl_info_transfer: + c.destroy(); break; - case types::four_four: - HANDLE_CODE(c.get >().unpack(bref)); + case types::ue_cap_enquiry: + c.destroy(); break; - case types::eight_two: - HANDLE_CODE(c.get >().unpack(bref)); + case types::counter_check: + c.destroy(); break; - case types::sixteen_one: - HANDLE_CODE(c.get >().unpack(bref)); + case types::mob_from_nr_cmd: + c.destroy(); break; default: - log_invalid_choice_id( - type_, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); - return SRSASN_ERROR_DECODE_FAIL; + break; } - return SRSASN_SUCCESS; } - -std::string codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_:: - types_opts::to_string() const +void dl_dcch_msg_type_c::c1_c_::set(types::options e) { - static const char* options[] = {"two-one", - "two-two", - "four-one", - "three-two", - "six-one", - "four-two", - "eight-one", - "four-three", - "six-two", - "twelve-one", - "four-four", - "eight-two", - "sixteen-one"}; - return convert_enum_idx( - options, - 13, - value, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::types"); + destroy_(); + type_ = e; + switch (type_) { + case types::rrc_recfg: + c.init(); + break; + case types::rrc_resume: + c.init(); + break; + case types::rrc_release: + c.init(); + break; + case types::rrc_reest: + c.init(); + break; + case types::security_mode_cmd: + c.init(); + break; + case types::dl_info_transfer: + c.init(); + break; + case types::ue_cap_enquiry: + c.init(); + break; + case types::counter_check: + c.init(); + break; + case types::mob_from_nr_cmd: + c.init(); + break; + case types::spare7: + break; + case types::spare6: + break; + case types::spare5: + break; + case types::spare4: + break; + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + } } - -std::string -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_opts::to_string() - const +dl_dcch_msg_type_c::c1_c_::c1_c_(const dl_dcch_msg_type_c::c1_c_& other) { - static const char* options[] = {"n1", "n2", "n3", "n4"}; - return convert_enum_idx( - options, - 4, - value, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_e_"); + type_ = other.type(); + switch (type_) { + case types::rrc_recfg: + c.init(other.c.get()); + break; + case types::rrc_resume: + c.init(other.c.get()); + break; + case types::rrc_release: + c.init(other.c.get()); + break; + case types::rrc_reest: + c.init(other.c.get()); + break; + case types::security_mode_cmd: + c.init(other.c.get()); + break; + case types::dl_info_transfer: + c.init(other.c.get()); + break; + case types::ue_cap_enquiry: + c.init(other.c.get()); + break; + case types::counter_check: + c.init(other.c.get()); + break; + case types::mob_from_nr_cmd: + c.init(other.c.get()); + break; + case types::spare7: + break; + case types::spare6: + break; + case types::spare5: + break; + case types::spare4: + break; + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + } } -uint8_t -codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_opts::to_number() - const +dl_dcch_msg_type_c::c1_c_& dl_dcch_msg_type_c::c1_c_::operator=(const dl_dcch_msg_type_c::c1_c_& other) { - static const uint8_t options[] = {1, 2, 3, 4}; - return map_enum_number( - options, - 4, - value, - "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_e_"); -} + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::rrc_recfg: + c.set(other.c.get()); + break; + case types::rrc_resume: + c.set(other.c.get()); + break; + case types::rrc_release: + c.set(other.c.get()); + break; + case types::rrc_reest: + c.set(other.c.get()); + break; + case types::security_mode_cmd: + c.set(other.c.get()); + break; + case types::dl_info_transfer: + c.set(other.c.get()); + break; + case types::ue_cap_enquiry: + c.set(other.c.get()); + break; + case types::counter_check: + c.set(other.c.get()); + break; + case types::mob_from_nr_cmd: + c.set(other.c.get()); + break; + case types::spare7: + break; + case types::spare6: + break; + case types::spare5: + break; + case types::spare4: + break; + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + } -std::string codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::types_opts::to_string() const -{ - static const char* options[] = {"typeII", "typeII-PortSelection"}; - return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::types"); + return *this; } - -std::string codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_opts::to_string() const +void dl_dcch_msg_type_c::c1_c_::to_json(json_writer& j) const { - static const char* options[] = {"n4", "n8"}; - return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_e_"); + j.start_obj(); + switch (type_) { + case types::rrc_recfg: + j.write_fieldname("rrcReconfiguration"); + c.get().to_json(j); + break; + case types::rrc_resume: + j.write_fieldname("rrcResume"); + c.get().to_json(j); + break; + case types::rrc_release: + j.write_fieldname("rrcRelease"); + c.get().to_json(j); + break; + case types::rrc_reest: + j.write_fieldname("rrcReestablishment"); + c.get().to_json(j); + break; + case types::security_mode_cmd: + j.write_fieldname("securityModeCommand"); + c.get().to_json(j); + break; + case types::dl_info_transfer: + j.write_fieldname("dlInformationTransfer"); + c.get().to_json(j); + break; + case types::ue_cap_enquiry: + j.write_fieldname("ueCapabilityEnquiry"); + c.get().to_json(j); + break; + case types::counter_check: + j.write_fieldname("counterCheck"); + c.get().to_json(j); + break; + case types::mob_from_nr_cmd: + j.write_fieldname("mobilityFromNRCommand"); + c.get().to_json(j); + break; + case types::spare7: + break; + case types::spare6: + break; + case types::spare5: + break; + case types::spare4: + break; + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: + break; + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + } + j.end_obj(); } -uint8_t codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_opts::to_number() const +SRSASN_CODE dl_dcch_msg_type_c::c1_c_::pack(bit_ref& bref) const { - static const uint8_t options[] = {4, 8}; - return map_enum_number(options, 2, value, "codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_e_"); + type_.pack(bref); + switch (type_) { + case types::rrc_recfg: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::rrc_resume: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::rrc_release: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::rrc_reest: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::security_mode_cmd: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::dl_info_transfer: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::ue_cap_enquiry: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::counter_check: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::mob_from_nr_cmd: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::spare7: + break; + case types::spare6: + break; + case types::spare5: + break; + case types::spare4: + break; + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: + break; + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } - -std::string codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_opts::to_string() const +SRSASN_CODE dl_dcch_msg_type_c::c1_c_::unpack(cbit_ref& bref) { - static const char* options[] = {"two", "three", "four"}; - return convert_enum_idx(options, 3, value, "codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::rrc_recfg: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::rrc_resume: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::rrc_release: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::rrc_reest: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::security_mode_cmd: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::dl_info_transfer: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::ue_cap_enquiry: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::counter_check: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::mob_from_nr_cmd: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::spare7: + break; + case types::spare6: + break; + case types::spare5: + break; + case types::spare4: + break; + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: + break; + default: + log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -uint8_t codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_opts::to_number() const + +std::string dl_dcch_msg_type_c::c1_c_::types_opts::to_string() const { - static const uint8_t options[] = {2, 3, 4}; - return map_enum_number(options, 3, value, "codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_e_"); + static const char* options[] = {"rrcReconfiguration", + "rrcResume", + "rrcRelease", + "rrcReestablishment", + "securityModeCommand", + "dlInformationTransfer", + "ueCapabilityEnquiry", + "counterCheck", + "mobilityFromNRCommand", + "spare7", + "spare6", + "spare5", + "spare4", + "spare3", + "spare2", + "spare1"}; + return convert_enum_idx(options, 16, value, "dl_dcch_msg_type_c::c1_c_::types"); } -std::string codebook_cfg_s::codebook_type_c_::types_opts::to_string() const +std::string dl_dcch_msg_type_c::types_opts::to_string() const { - static const char* options[] = {"type1", "type2"}; - return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::types"); + static const char* options[] = {"c1", "messageClassExtension"}; + return convert_enum_idx(options, 2, value, "dl_dcch_msg_type_c::types"); } -uint8_t codebook_cfg_s::codebook_type_c_::types_opts::to_number() const +uint8_t dl_dcch_msg_type_c::types_opts::to_number() const { - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "codebook_cfg_s::codebook_type_c_::types"); + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "dl_dcch_msg_type_c::types"); } -// FrequencyInfoDL ::= SEQUENCE -SRSASN_CODE freq_info_dl_s::pack(bit_ref& bref) const +// DL-DCCH-Message ::= SEQUENCE +SRSASN_CODE dl_dcch_msg_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(absolute_freq_ssb_present, 1)); + HANDLE_CODE(msg.pack(bref)); - if (absolute_freq_ssb_present) { - HANDLE_CODE(pack_integer(bref, absolute_freq_ssb, (uint32_t)0u, (uint32_t)3279165u)); - } - HANDLE_CODE(pack_dyn_seq_of(bref, freq_band_list, 1, 8, integer_packer(1, 1024))); - HANDLE_CODE(pack_integer(bref, absolute_freq_point_a, (uint32_t)0u, (uint32_t)3279165u)); - HANDLE_CODE(pack_dyn_seq_of(bref, scs_specific_carrier_list, 1, 5)); + bref.align_bytes_zero(); return SRSASN_SUCCESS; } -SRSASN_CODE freq_info_dl_s::unpack(cbit_ref& bref) +SRSASN_CODE dl_dcch_msg_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(absolute_freq_ssb_present, 1)); + HANDLE_CODE(msg.unpack(bref)); - if (absolute_freq_ssb_present) { - HANDLE_CODE(unpack_integer(absolute_freq_ssb, bref, (uint32_t)0u, (uint32_t)3279165u)); - } - HANDLE_CODE(unpack_dyn_seq_of(freq_band_list, bref, 1, 8, integer_packer(1, 1024))); - HANDLE_CODE(unpack_integer(absolute_freq_point_a, bref, (uint32_t)0u, (uint32_t)3279165u)); - HANDLE_CODE(unpack_dyn_seq_of(scs_specific_carrier_list, bref, 1, 5)); + bref.align_bytes(); return SRSASN_SUCCESS; } -void freq_info_dl_s::to_json(json_writer& j) const +void dl_dcch_msg_s::to_json(json_writer& j) const { + j.start_array(); j.start_obj(); - if (absolute_freq_ssb_present) { - j.write_int("absoluteFrequencySSB", absolute_freq_ssb); - } - j.start_array("frequencyBandList"); - for (const auto& e1 : freq_band_list) { - j.write_int(e1); - } - j.end_array(); - j.write_int("absoluteFrequencyPointA", absolute_freq_point_a); - j.start_array("scs-SpecificCarrierList"); - for (const auto& e1 : scs_specific_carrier_list) { - e1.to_json(j); - } - j.end_array(); + j.start_obj("DL-DCCH-Message"); + j.write_fieldname("message"); + msg.to_json(j); j.end_obj(); + j.end_obj(); + j.end_array(); } -// FrequencyInfoUL ::= SEQUENCE -SRSASN_CODE freq_info_ul_s::pack(bit_ref& bref) const +// PagingUE-Identity ::= CHOICE +void paging_ue_id_c::destroy_() { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(freq_band_list_present, 1)); - HANDLE_CODE(bref.pack(absolute_freq_point_a_present, 1)); - HANDLE_CODE(bref.pack(add_spec_emission_present, 1)); - HANDLE_CODE(bref.pack(p_max_present, 1)); - HANDLE_CODE(bref.pack(freq_shift7p5khz_present, 1)); - - if (freq_band_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, freq_band_list, 1, 8, integer_packer(1, 1024))); - } - if (absolute_freq_point_a_present) { - HANDLE_CODE(pack_integer(bref, absolute_freq_point_a, (uint32_t)0u, (uint32_t)3279165u)); - } - HANDLE_CODE(pack_dyn_seq_of(bref, scs_specific_carrier_list, 1, 5)); - if (add_spec_emission_present) { - HANDLE_CODE(pack_integer(bref, add_spec_emission, (uint8_t)0u, (uint8_t)7u)); + switch (type_) { + case types::ng_minus5_g_s_tmsi: + c.destroy >(); + break; + case types::full_i_rnti: + c.destroy >(); + break; + default: + break; } - if (p_max_present) { - HANDLE_CODE(pack_integer(bref, p_max, (int8_t)-30, (int8_t)33)); - } - - return SRSASN_SUCCESS; } -SRSASN_CODE freq_info_ul_s::unpack(cbit_ref& bref) +void paging_ue_id_c::set(types::options e) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(freq_band_list_present, 1)); - HANDLE_CODE(bref.unpack(absolute_freq_point_a_present, 1)); - HANDLE_CODE(bref.unpack(add_spec_emission_present, 1)); - HANDLE_CODE(bref.unpack(p_max_present, 1)); - HANDLE_CODE(bref.unpack(freq_shift7p5khz_present, 1)); - - if (freq_band_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(freq_band_list, bref, 1, 8, integer_packer(1, 1024))); + destroy_(); + type_ = e; + switch (type_) { + case types::ng_minus5_g_s_tmsi: + c.init >(); + break; + case types::full_i_rnti: + c.init >(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "paging_ue_id_c"); } - if (absolute_freq_point_a_present) { - HANDLE_CODE(unpack_integer(absolute_freq_point_a, bref, (uint32_t)0u, (uint32_t)3279165u)); +} +paging_ue_id_c::paging_ue_id_c(const paging_ue_id_c& other) +{ + type_ = other.type(); + switch (type_) { + case types::ng_minus5_g_s_tmsi: + c.init(other.c.get >()); + break; + case types::full_i_rnti: + c.init(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "paging_ue_id_c"); } - HANDLE_CODE(unpack_dyn_seq_of(scs_specific_carrier_list, bref, 1, 5)); - if (add_spec_emission_present) { - HANDLE_CODE(unpack_integer(add_spec_emission, bref, (uint8_t)0u, (uint8_t)7u)); +} +paging_ue_id_c& paging_ue_id_c::operator=(const paging_ue_id_c& other) +{ + if (this == &other) { + return *this; } - if (p_max_present) { - HANDLE_CODE(unpack_integer(p_max, bref, (int8_t)-30, (int8_t)33)); + set(other.type()); + switch (type_) { + case types::ng_minus5_g_s_tmsi: + c.set(other.c.get >()); + break; + case types::full_i_rnti: + c.set(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "paging_ue_id_c"); } - return SRSASN_SUCCESS; + return *this; } -void freq_info_ul_s::to_json(json_writer& j) const +void paging_ue_id_c::to_json(json_writer& j) const { j.start_obj(); - if (freq_band_list_present) { - j.start_array("frequencyBandList"); - for (const auto& e1 : freq_band_list) { - j.write_int(e1); - } - j.end_array(); - } - if (absolute_freq_point_a_present) { - j.write_int("absoluteFrequencyPointA", absolute_freq_point_a); - } - j.start_array("scs-SpecificCarrierList"); - for (const auto& e1 : scs_specific_carrier_list) { - e1.to_json(j); - } - j.end_array(); - if (add_spec_emission_present) { - j.write_int("additionalSpectrumEmission", add_spec_emission); + switch (type_) { + case types::ng_minus5_g_s_tmsi: + j.write_str("ng-5G-S-TMSI", c.get >().to_string()); + break; + case types::full_i_rnti: + j.write_str("fullI-RNTI", c.get >().to_string()); + break; + default: + log_invalid_choice_id(type_, "paging_ue_id_c"); } - if (p_max_present) { - j.write_int("p-Max", p_max); + j.end_obj(); +} +SRSASN_CODE paging_ue_id_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::ng_minus5_g_s_tmsi: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::full_i_rnti: + HANDLE_CODE(c.get >().pack(bref)); + break; + default: + log_invalid_choice_id(type_, "paging_ue_id_c"); + return SRSASN_ERROR_ENCODE_FAIL; } - if (freq_shift7p5khz_present) { - j.write_str("frequencyShift7p5khz", "true"); + return SRSASN_SUCCESS; +} +SRSASN_CODE paging_ue_id_c::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ng_minus5_g_s_tmsi: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::full_i_rnti: + HANDLE_CODE(c.get >().unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "paging_ue_id_c"); + return SRSASN_ERROR_DECODE_FAIL; } - j.end_obj(); + return SRSASN_SUCCESS; } -// PDCCH-Config ::= SEQUENCE -SRSASN_CODE pdcch_cfg_s::pack(bit_ref& bref) const +std::string paging_ue_id_c::types_opts::to_string() const +{ + static const char* options[] = {"ng-5G-S-TMSI", "fullI-RNTI"}; + return convert_enum_idx(options, 2, value, "paging_ue_id_c::types"); +} +int8_t paging_ue_id_c::types_opts::to_number() const +{ + static const int8_t options[] = {-5}; + return map_enum_number(options, 1, value, "paging_ue_id_c::types"); +} + +// PagingRecord ::= SEQUENCE +SRSASN_CODE paging_record_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ctrl_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(ctrl_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(search_spaces_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(search_spaces_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(dl_preemption_present, 1)); - HANDLE_CODE(bref.pack(tpc_pusch_present, 1)); - HANDLE_CODE(bref.pack(tpc_pucch_present, 1)); - HANDLE_CODE(bref.pack(tpc_srs_present, 1)); + HANDLE_CODE(bref.pack(access_type_present, 1)); - if (ctrl_res_set_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ctrl_res_set_to_add_mod_list, 1, 3)); - } - if (ctrl_res_set_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ctrl_res_set_to_release_list, 1, 3, integer_packer(0, 11))); - } - if (search_spaces_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, search_spaces_to_add_mod_list, 1, 10)); - } - if (search_spaces_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, search_spaces_to_release_list, 1, 10, integer_packer(0, 39))); - } - if (dl_preemption_present) { - HANDLE_CODE(dl_preemption.pack(bref)); - } - if (tpc_pusch_present) { - HANDLE_CODE(tpc_pusch.pack(bref)); - } - if (tpc_pucch_present) { - HANDLE_CODE(tpc_pucch.pack(bref)); - } - if (tpc_srs_present) { - HANDLE_CODE(tpc_srs.pack(bref)); - } + HANDLE_CODE(ue_id.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE pdcch_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE paging_record_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ctrl_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(ctrl_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(search_spaces_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(search_spaces_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(dl_preemption_present, 1)); - HANDLE_CODE(bref.unpack(tpc_pusch_present, 1)); - HANDLE_CODE(bref.unpack(tpc_pucch_present, 1)); - HANDLE_CODE(bref.unpack(tpc_srs_present, 1)); + HANDLE_CODE(bref.unpack(access_type_present, 1)); - if (ctrl_res_set_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ctrl_res_set_to_add_mod_list, bref, 1, 3)); - } - if (ctrl_res_set_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ctrl_res_set_to_release_list, bref, 1, 3, integer_packer(0, 11))); - } - if (search_spaces_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(search_spaces_to_add_mod_list, bref, 1, 10)); - } - if (search_spaces_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(search_spaces_to_release_list, bref, 1, 10, integer_packer(0, 39))); - } - if (dl_preemption_present) { - HANDLE_CODE(dl_preemption.unpack(bref)); - } - if (tpc_pusch_present) { - HANDLE_CODE(tpc_pusch.unpack(bref)); - } - if (tpc_pucch_present) { - HANDLE_CODE(tpc_pucch.unpack(bref)); - } - if (tpc_srs_present) { - HANDLE_CODE(tpc_srs.unpack(bref)); - } + HANDLE_CODE(ue_id.unpack(bref)); return SRSASN_SUCCESS; } -void pdcch_cfg_s::to_json(json_writer& j) const +void paging_record_s::to_json(json_writer& j) const { j.start_obj(); - if (ctrl_res_set_to_add_mod_list_present) { - j.start_array("controlResourceSetToAddModList"); - for (const auto& e1 : ctrl_res_set_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (ctrl_res_set_to_release_list_present) { - j.start_array("controlResourceSetToReleaseList"); - for (const auto& e1 : ctrl_res_set_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (search_spaces_to_add_mod_list_present) { - j.start_array("searchSpacesToAddModList"); - for (const auto& e1 : search_spaces_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (search_spaces_to_release_list_present) { - j.start_array("searchSpacesToReleaseList"); - for (const auto& e1 : search_spaces_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (dl_preemption_present) { - j.write_fieldname("downlinkPreemption"); - dl_preemption.to_json(j); - } - if (tpc_pusch_present) { - j.write_fieldname("tpc-PUSCH"); - tpc_pusch.to_json(j); - } - if (tpc_pucch_present) { - j.write_fieldname("tpc-PUCCH"); - tpc_pucch.to_json(j); - } - if (tpc_srs_present) { - j.write_fieldname("tpc-SRS"); - tpc_srs.to_json(j); + j.write_fieldname("ue-Identity"); + ue_id.to_json(j); + if (access_type_present) { + j.write_str("accessType", "non3GPP"); } j.end_obj(); } -// PDSCH-Config ::= SEQUENCE -SRSASN_CODE pdsch_cfg_s::pack(bit_ref& bref) const +// Paging ::= SEQUENCE +SRSASN_CODE paging_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(data_scrambling_id_pdsch_present, 1)); - HANDLE_CODE(bref.pack(dmrs_dl_for_pdsch_map_type_a_present, 1)); - HANDLE_CODE(bref.pack(dmrs_dl_for_pdsch_map_type_b_present, 1)); - HANDLE_CODE(bref.pack(tci_states_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(tci_states_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(vrb_to_prb_interleaver_present, 1)); - HANDLE_CODE(bref.pack(pdsch_time_domain_alloc_list_present, 1)); - HANDLE_CODE(bref.pack(pdsch_aggregation_factor_present, 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_group1_present, 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_group2_present, 1)); - HANDLE_CODE(bref.pack(mcs_table_present, 1)); - HANDLE_CODE(bref.pack(max_nrof_code_words_sched_by_dci_present, 1)); - HANDLE_CODE(bref.pack(zp_csi_rs_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(zp_csi_rs_res_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(aperiodic_zp_csi_rs_res_sets_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(sp_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(sp_zp_csi_rs_res_sets_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(p_zp_csi_rs_res_set_present, 1)); + HANDLE_CODE(bref.pack(paging_record_list_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (data_scrambling_id_pdsch_present) { - HANDLE_CODE(pack_integer(bref, data_scrambling_id_pdsch, (uint16_t)0u, (uint16_t)1023u)); - } - if (dmrs_dl_for_pdsch_map_type_a_present) { - HANDLE_CODE(dmrs_dl_for_pdsch_map_type_a.pack(bref)); - } - if (dmrs_dl_for_pdsch_map_type_b_present) { - HANDLE_CODE(dmrs_dl_for_pdsch_map_type_b.pack(bref)); - } - if (tci_states_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, tci_states_to_add_mod_list, 1, 128)); - } - if (tci_states_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, tci_states_to_release_list, 1, 128, integer_packer(0, 127))); - } - if (vrb_to_prb_interleaver_present) { - HANDLE_CODE(vrb_to_prb_interleaver.pack(bref)); - } - HANDLE_CODE(res_alloc.pack(bref)); - if (pdsch_time_domain_alloc_list_present) { - HANDLE_CODE(pdsch_time_domain_alloc_list.pack(bref)); - } - if (pdsch_aggregation_factor_present) { - HANDLE_CODE(pdsch_aggregation_factor.pack(bref)); - } - if (rate_match_pattern_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_add_mod_list, 1, 4)); - } - if (rate_match_pattern_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_release_list, 1, 4, integer_packer(0, 3))); - } - if (rate_match_pattern_group1_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_group1, 1, 8)); - } - if (rate_match_pattern_group2_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_group2, 1, 8)); - } - HANDLE_CODE(rbg_size.pack(bref)); - if (mcs_table_present) { - HANDLE_CODE(mcs_table.pack(bref)); - } - if (max_nrof_code_words_sched_by_dci_present) { - HANDLE_CODE(max_nrof_code_words_sched_by_dci.pack(bref)); - } - HANDLE_CODE(prb_bundling_type.pack(bref)); - if (zp_csi_rs_res_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, zp_csi_rs_res_to_add_mod_list, 1, 32)); - } - if (zp_csi_rs_res_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, zp_csi_rs_res_to_release_list, 1, 32, integer_packer(0, 31))); - } - if (aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, aperiodic_zp_csi_rs_res_sets_to_add_mod_list, 1, 16)); - } - if (aperiodic_zp_csi_rs_res_sets_to_release_list_present) { - HANDLE_CODE( - pack_dyn_seq_of(bref, aperiodic_zp_csi_rs_res_sets_to_release_list, 1, 16, integer_packer(0, 15))); - } - if (sp_zp_csi_rs_res_sets_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sp_zp_csi_rs_res_sets_to_add_mod_list, 1, 16)); - } - if (sp_zp_csi_rs_res_sets_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sp_zp_csi_rs_res_sets_to_release_list, 1, 16, integer_packer(0, 15))); + if (paging_record_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, paging_record_list, 1, 32)); } - if (p_zp_csi_rs_res_set_present) { - HANDLE_CODE(p_zp_csi_rs_res_set.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE pdsch_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE paging_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(data_scrambling_id_pdsch_present, 1)); - HANDLE_CODE(bref.unpack(dmrs_dl_for_pdsch_map_type_a_present, 1)); - HANDLE_CODE(bref.unpack(dmrs_dl_for_pdsch_map_type_b_present, 1)); - HANDLE_CODE(bref.unpack(tci_states_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(tci_states_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(vrb_to_prb_interleaver_present, 1)); - HANDLE_CODE(bref.unpack(pdsch_time_domain_alloc_list_present, 1)); - HANDLE_CODE(bref.unpack(pdsch_aggregation_factor_present, 1)); - HANDLE_CODE(bref.unpack(rate_match_pattern_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(rate_match_pattern_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(rate_match_pattern_group1_present, 1)); - HANDLE_CODE(bref.unpack(rate_match_pattern_group2_present, 1)); - HANDLE_CODE(bref.unpack(mcs_table_present, 1)); - HANDLE_CODE(bref.unpack(max_nrof_code_words_sched_by_dci_present, 1)); - HANDLE_CODE(bref.unpack(zp_csi_rs_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(zp_csi_rs_res_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(aperiodic_zp_csi_rs_res_sets_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(sp_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(sp_zp_csi_rs_res_sets_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(p_zp_csi_rs_res_set_present, 1)); + HANDLE_CODE(bref.unpack(paging_record_list_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (data_scrambling_id_pdsch_present) { - HANDLE_CODE(unpack_integer(data_scrambling_id_pdsch, bref, (uint16_t)0u, (uint16_t)1023u)); - } - if (dmrs_dl_for_pdsch_map_type_a_present) { - HANDLE_CODE(dmrs_dl_for_pdsch_map_type_a.unpack(bref)); - } - if (dmrs_dl_for_pdsch_map_type_b_present) { - HANDLE_CODE(dmrs_dl_for_pdsch_map_type_b.unpack(bref)); - } - if (tci_states_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(tci_states_to_add_mod_list, bref, 1, 128)); - } - if (tci_states_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(tci_states_to_release_list, bref, 1, 128, integer_packer(0, 127))); - } - if (vrb_to_prb_interleaver_present) { - HANDLE_CODE(vrb_to_prb_interleaver.unpack(bref)); - } - HANDLE_CODE(res_alloc.unpack(bref)); - if (pdsch_time_domain_alloc_list_present) { - HANDLE_CODE(pdsch_time_domain_alloc_list.unpack(bref)); - } - if (pdsch_aggregation_factor_present) { - HANDLE_CODE(pdsch_aggregation_factor.unpack(bref)); - } - if (rate_match_pattern_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_add_mod_list, bref, 1, 4)); - } - if (rate_match_pattern_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_release_list, bref, 1, 4, integer_packer(0, 3))); - } - if (rate_match_pattern_group1_present) { - HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_group1, bref, 1, 8)); - } - if (rate_match_pattern_group2_present) { - HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_group2, bref, 1, 8)); - } - HANDLE_CODE(rbg_size.unpack(bref)); - if (mcs_table_present) { - HANDLE_CODE(mcs_table.unpack(bref)); - } - if (max_nrof_code_words_sched_by_dci_present) { - HANDLE_CODE(max_nrof_code_words_sched_by_dci.unpack(bref)); - } - HANDLE_CODE(prb_bundling_type.unpack(bref)); - if (zp_csi_rs_res_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(zp_csi_rs_res_to_add_mod_list, bref, 1, 32)); - } - if (zp_csi_rs_res_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(zp_csi_rs_res_to_release_list, bref, 1, 32, integer_packer(0, 31))); - } - if (aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(aperiodic_zp_csi_rs_res_sets_to_add_mod_list, bref, 1, 16)); - } - if (aperiodic_zp_csi_rs_res_sets_to_release_list_present) { - HANDLE_CODE( - unpack_dyn_seq_of(aperiodic_zp_csi_rs_res_sets_to_release_list, bref, 1, 16, integer_packer(0, 15))); - } - if (sp_zp_csi_rs_res_sets_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sp_zp_csi_rs_res_sets_to_add_mod_list, bref, 1, 16)); - } - if (sp_zp_csi_rs_res_sets_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sp_zp_csi_rs_res_sets_to_release_list, bref, 1, 16, integer_packer(0, 15))); + if (paging_record_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(paging_record_list, bref, 1, 32)); } - if (p_zp_csi_rs_res_set_present) { - HANDLE_CODE(p_zp_csi_rs_res_set.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void pdsch_cfg_s::to_json(json_writer& j) const +void paging_s::to_json(json_writer& j) const { j.start_obj(); - if (data_scrambling_id_pdsch_present) { - j.write_int("dataScramblingIdentityPDSCH", data_scrambling_id_pdsch); - } - if (dmrs_dl_for_pdsch_map_type_a_present) { - j.write_fieldname("dmrs-DownlinkForPDSCH-MappingTypeA"); - dmrs_dl_for_pdsch_map_type_a.to_json(j); - } - if (dmrs_dl_for_pdsch_map_type_b_present) { - j.write_fieldname("dmrs-DownlinkForPDSCH-MappingTypeB"); - dmrs_dl_for_pdsch_map_type_b.to_json(j); - } - if (tci_states_to_add_mod_list_present) { - j.start_array("tci-StatesToAddModList"); - for (const auto& e1 : tci_states_to_add_mod_list) { + if (paging_record_list_present) { + j.start_array("pagingRecordList"); + for (const auto& e1 : paging_record_list) { e1.to_json(j); } j.end_array(); } - if (tci_states_to_release_list_present) { - j.start_array("tci-StatesToReleaseList"); - for (const auto& e1 : tci_states_to_release_list) { - j.write_int(e1); - } - j.end_array(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (vrb_to_prb_interleaver_present) { - j.write_str("vrb-ToPRB-Interleaver", vrb_to_prb_interleaver.to_string()); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } - j.write_str("resourceAllocation", res_alloc.to_string()); - if (pdsch_time_domain_alloc_list_present) { - j.write_fieldname("pdsch-TimeDomainAllocationList"); - pdsch_time_domain_alloc_list.to_json(j); - } - if (pdsch_aggregation_factor_present) { - j.write_str("pdsch-AggregationFactor", pdsch_aggregation_factor.to_string()); - } - if (rate_match_pattern_to_add_mod_list_present) { - j.start_array("rateMatchPatternToAddModList"); - for (const auto& e1 : rate_match_pattern_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (rate_match_pattern_to_release_list_present) { - j.start_array("rateMatchPatternToReleaseList"); - for (const auto& e1 : rate_match_pattern_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (rate_match_pattern_group1_present) { - j.start_array("rateMatchPatternGroup1"); - for (const auto& e1 : rate_match_pattern_group1) { - e1.to_json(j); - } - j.end_array(); - } - if (rate_match_pattern_group2_present) { - j.start_array("rateMatchPatternGroup2"); - for (const auto& e1 : rate_match_pattern_group2) { - e1.to_json(j); - } - j.end_array(); - } - j.write_str("rbg-Size", rbg_size.to_string()); - if (mcs_table_present) { - j.write_str("mcs-Table", mcs_table.to_string()); - } - if (max_nrof_code_words_sched_by_dci_present) { - j.write_str("maxNrofCodeWordsScheduledByDCI", max_nrof_code_words_sched_by_dci.to_string()); - } - j.write_fieldname("prb-BundlingType"); - prb_bundling_type.to_json(j); - if (zp_csi_rs_res_to_add_mod_list_present) { - j.start_array("zp-CSI-RS-ResourceToAddModList"); - for (const auto& e1 : zp_csi_rs_res_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (zp_csi_rs_res_to_release_list_present) { - j.start_array("zp-CSI-RS-ResourceToReleaseList"); - for (const auto& e1 : zp_csi_rs_res_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present) { - j.start_array("aperiodic-ZP-CSI-RS-ResourceSetsToAddModList"); - for (const auto& e1 : aperiodic_zp_csi_rs_res_sets_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (aperiodic_zp_csi_rs_res_sets_to_release_list_present) { - j.start_array("aperiodic-ZP-CSI-RS-ResourceSetsToReleaseList"); - for (const auto& e1 : aperiodic_zp_csi_rs_res_sets_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (sp_zp_csi_rs_res_sets_to_add_mod_list_present) { - j.start_array("sp-ZP-CSI-RS-ResourceSetsToAddModList"); - for (const auto& e1 : sp_zp_csi_rs_res_sets_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (sp_zp_csi_rs_res_sets_to_release_list_present) { - j.start_array("sp-ZP-CSI-RS-ResourceSetsToReleaseList"); - for (const auto& e1 : sp_zp_csi_rs_res_sets_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (p_zp_csi_rs_res_set_present) { - j.write_fieldname("p-ZP-CSI-RS-ResourceSet"); - p_zp_csi_rs_res_set.to_json(j); - } - j.end_obj(); -} - -std::string pdsch_cfg_s::vrb_to_prb_interleaver_opts::to_string() const -{ - static const char* options[] = {"n2", "n4"}; - return convert_enum_idx(options, 2, value, "pdsch_cfg_s::vrb_to_prb_interleaver_e_"); -} -uint8_t pdsch_cfg_s::vrb_to_prb_interleaver_opts::to_number() const -{ - static const uint8_t options[] = {2, 4}; - return map_enum_number(options, 2, value, "pdsch_cfg_s::vrb_to_prb_interleaver_e_"); -} - -std::string pdsch_cfg_s::res_alloc_opts::to_string() const -{ - static const char* options[] = {"resourceAllocationType0", "resourceAllocationType1", "dynamicSwitch"}; - return convert_enum_idx(options, 3, value, "pdsch_cfg_s::res_alloc_e_"); -} -uint8_t pdsch_cfg_s::res_alloc_opts::to_number() const -{ - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "pdsch_cfg_s::res_alloc_e_"); -} - -std::string pdsch_cfg_s::pdsch_aggregation_factor_opts::to_string() const -{ - static const char* options[] = {"n2", "n4", "n8"}; - return convert_enum_idx(options, 3, value, "pdsch_cfg_s::pdsch_aggregation_factor_e_"); -} -uint8_t pdsch_cfg_s::pdsch_aggregation_factor_opts::to_number() const -{ - static const uint8_t options[] = {2, 4, 8}; - return map_enum_number(options, 3, value, "pdsch_cfg_s::pdsch_aggregation_factor_e_"); -} - -std::string pdsch_cfg_s::rbg_size_opts::to_string() const -{ - static const char* options[] = {"config1", "config2"}; - return convert_enum_idx(options, 2, value, "pdsch_cfg_s::rbg_size_e_"); -} -uint8_t pdsch_cfg_s::rbg_size_opts::to_number() const -{ - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "pdsch_cfg_s::rbg_size_e_"); -} - -std::string pdsch_cfg_s::mcs_table_opts::to_string() const -{ - static const char* options[] = {"qam256", "qam64LowSE"}; - return convert_enum_idx(options, 2, value, "pdsch_cfg_s::mcs_table_e_"); -} -uint16_t pdsch_cfg_s::mcs_table_opts::to_number() const -{ - static const uint16_t options[] = {256, 64}; - return map_enum_number(options, 2, value, "pdsch_cfg_s::mcs_table_e_"); -} - -std::string pdsch_cfg_s::max_nrof_code_words_sched_by_dci_opts::to_string() const -{ - static const char* options[] = {"n1", "n2"}; - return convert_enum_idx(options, 2, value, "pdsch_cfg_s::max_nrof_code_words_sched_by_dci_e_"); -} -uint8_t pdsch_cfg_s::max_nrof_code_words_sched_by_dci_opts::to_number() const -{ - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "pdsch_cfg_s::max_nrof_code_words_sched_by_dci_e_"); -} - -void pdsch_cfg_s::prb_bundling_type_c_::destroy_() -{ - switch (type_) { - case types::static_bundling: - c.destroy(); - break; - case types::dynamic_bundling: - c.destroy(); - break; - default: - break; + j.end_obj(); +} + +// PCCH-MessageType ::= CHOICE +void pcch_msg_type_c::destroy_() +{ + switch (type_) { + case types::c1: + c.destroy(); + break; + default: + break; } } -void pdsch_cfg_s::prb_bundling_type_c_::set(types::options e) +void pcch_msg_type_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::static_bundling: - c.init(); + case types::c1: + c.init(); break; - case types::dynamic_bundling: - c.init(); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); + log_invalid_choice_id(type_, "pcch_msg_type_c"); } } -pdsch_cfg_s::prb_bundling_type_c_::prb_bundling_type_c_(const pdsch_cfg_s::prb_bundling_type_c_& other) +pcch_msg_type_c::pcch_msg_type_c(const pcch_msg_type_c& other) { type_ = other.type(); switch (type_) { - case types::static_bundling: - c.init(other.c.get()); + case types::c1: + c.init(other.c.get()); break; - case types::dynamic_bundling: - c.init(other.c.get()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); + log_invalid_choice_id(type_, "pcch_msg_type_c"); } } -pdsch_cfg_s::prb_bundling_type_c_& pdsch_cfg_s::prb_bundling_type_c_:: - operator=(const pdsch_cfg_s::prb_bundling_type_c_& other) +pcch_msg_type_c& pcch_msg_type_c::operator=(const pcch_msg_type_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::static_bundling: - c.set(other.c.get()); + case types::c1: + c.set(other.c.get()); break; - case types::dynamic_bundling: - c.set(other.c.get()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); + log_invalid_choice_id(type_, "pcch_msg_type_c"); } return *this; } -void pdsch_cfg_s::prb_bundling_type_c_::to_json(json_writer& j) const +void pcch_msg_type_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::static_bundling: - j.write_fieldname("staticBundling"); - j.start_obj(); - if (c.get().bundle_size_present) { - j.write_str("bundleSize", c.get().bundle_size.to_string()); - } - j.end_obj(); + case types::c1: + j.write_fieldname("c1"); + c.get().to_json(j); break; - case types::dynamic_bundling: - j.write_fieldname("dynamicBundling"); - j.start_obj(); - if (c.get().bundle_size_set1_present) { - j.write_str("bundleSizeSet1", c.get().bundle_size_set1.to_string()); - } - if (c.get().bundle_size_set2_present) { - j.write_str("bundleSizeSet2", c.get().bundle_size_set2.to_string()); - } - j.end_obj(); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); + log_invalid_choice_id(type_, "pcch_msg_type_c"); } j.end_obj(); } -SRSASN_CODE pdsch_cfg_s::prb_bundling_type_c_::pack(bit_ref& bref) const +SRSASN_CODE pcch_msg_type_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::static_bundling: - HANDLE_CODE(bref.pack(c.get().bundle_size_present, 1)); - if (c.get().bundle_size_present) { - HANDLE_CODE(c.get().bundle_size.pack(bref)); - } + case types::c1: + HANDLE_CODE(c.get().pack(bref)); break; - case types::dynamic_bundling: - HANDLE_CODE(bref.pack(c.get().bundle_size_set1_present, 1)); - HANDLE_CODE(bref.pack(c.get().bundle_size_set2_present, 1)); - if (c.get().bundle_size_set1_present) { - HANDLE_CODE(c.get().bundle_size_set1.pack(bref)); - } - if (c.get().bundle_size_set2_present) { - HANDLE_CODE(c.get().bundle_size_set2.pack(bref)); - } + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); + log_invalid_choice_id(type_, "pcch_msg_type_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE pdsch_cfg_s::prb_bundling_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE pcch_msg_type_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::static_bundling: - HANDLE_CODE(bref.unpack(c.get().bundle_size_present, 1)); - if (c.get().bundle_size_present) { - HANDLE_CODE(c.get().bundle_size.unpack(bref)); - } + case types::c1: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::dynamic_bundling: - HANDLE_CODE(bref.unpack(c.get().bundle_size_set1_present, 1)); - HANDLE_CODE(bref.unpack(c.get().bundle_size_set2_present, 1)); - if (c.get().bundle_size_set1_present) { - HANDLE_CODE(c.get().bundle_size_set1.unpack(bref)); - } - if (c.get().bundle_size_set2_present) { - HANDLE_CODE(c.get().bundle_size_set2.unpack(bref)); - } + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); + log_invalid_choice_id(type_, "pcch_msg_type_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_opts::to_string() const -{ - static const char* options[] = {"n4", "wideband"}; - return convert_enum_idx(options, 2, value, "pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_e_"); -} -uint8_t pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_opts::to_number() const +void pcch_msg_type_c::c1_c_::set(types::options e) { - static const uint8_t options[] = {4}; - return map_enum_number(options, 1, value, "pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_e_"); + type_ = e; } - -std::string pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set1_opts::to_string() const +void pcch_msg_type_c::c1_c_::to_json(json_writer& j) const { - static const char* options[] = {"n4", "wideband", "n2-wideband", "n4-wideband"}; - return convert_enum_idx( - options, 4, value, "pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set1_e_"); + j.start_obj(); + switch (type_) { + case types::paging: + j.write_fieldname("paging"); + c.to_json(j); + break; + case types::spare1: + break; + default: + log_invalid_choice_id(type_, "pcch_msg_type_c::c1_c_"); + } + j.end_obj(); } - -std::string pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_opts::to_string() const +SRSASN_CODE pcch_msg_type_c::c1_c_::pack(bit_ref& bref) const { - static const char* options[] = {"n4", "wideband"}; - return convert_enum_idx( - options, 2, value, "pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_e_"); + type_.pack(bref); + switch (type_) { + case types::paging: + HANDLE_CODE(c.pack(bref)); + break; + case types::spare1: + break; + default: + log_invalid_choice_id(type_, "pcch_msg_type_c::c1_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } -uint8_t pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_opts::to_number() const +SRSASN_CODE pcch_msg_type_c::c1_c_::unpack(cbit_ref& bref) { - static const uint8_t options[] = {4}; - return map_enum_number( - options, 1, value, "pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::paging: + HANDLE_CODE(c.unpack(bref)); + break; + case types::spare1: + break; + default: + log_invalid_choice_id(type_, "pcch_msg_type_c::c1_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -std::string pdsch_cfg_s::prb_bundling_type_c_::types_opts::to_string() const +std::string pcch_msg_type_c::c1_c_::types_opts::to_string() const { - static const char* options[] = {"staticBundling", "dynamicBundling"}; - return convert_enum_idx(options, 2, value, "pdsch_cfg_s::prb_bundling_type_c_::types"); + static const char* options[] = {"paging", "spare1"}; + return convert_enum_idx(options, 2, value, "pcch_msg_type_c::c1_c_::types"); } -// PUCCH-CSI-Resource ::= SEQUENCE -SRSASN_CODE pucch_csi_res_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, ul_bw_part_id, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, pucch_res, (uint8_t)0u, (uint8_t)127u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE pucch_csi_res_s::unpack(cbit_ref& bref) +std::string pcch_msg_type_c::types_opts::to_string() const { - HANDLE_CODE(unpack_integer(ul_bw_part_id, bref, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(pucch_res, bref, (uint8_t)0u, (uint8_t)127u)); - - return SRSASN_SUCCESS; + static const char* options[] = {"c1", "messageClassExtension"}; + return convert_enum_idx(options, 2, value, "pcch_msg_type_c::types"); } -void pucch_csi_res_s::to_json(json_writer& j) const +uint8_t pcch_msg_type_c::types_opts::to_number() const { - j.start_obj(); - j.write_int("uplinkBandwidthPartId", ul_bw_part_id); - j.write_int("pucch-Resource", pucch_res); - j.end_obj(); + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "pcch_msg_type_c::types"); } -// PUSCH-CodeBlockGroupTransmission ::= SEQUENCE -SRSASN_CODE pusch_code_block_group_tx_s::pack(bit_ref& bref) const +// PCCH-Message ::= SEQUENCE +SRSASN_CODE pcch_msg_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(max_code_block_groups_per_transport_block.pack(bref)); + HANDLE_CODE(msg.pack(bref)); + + bref.align_bytes_zero(); return SRSASN_SUCCESS; } -SRSASN_CODE pusch_code_block_group_tx_s::unpack(cbit_ref& bref) +SRSASN_CODE pcch_msg_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(max_code_block_groups_per_transport_block.unpack(bref)); + HANDLE_CODE(msg.unpack(bref)); + + bref.align_bytes(); return SRSASN_SUCCESS; } -void pusch_code_block_group_tx_s::to_json(json_writer& j) const +void pcch_msg_s::to_json(json_writer& j) const { + j.start_array(); j.start_obj(); - j.write_str("maxCodeBlockGroupsPerTransportBlock", max_code_block_groups_per_transport_block.to_string()); + j.start_obj("PCCH-Message"); + j.write_fieldname("message"); + msg.to_json(j); j.end_obj(); + j.end_obj(); + j.end_array(); } -std::string pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_string() const -{ - static const char* options[] = {"n2", "n4", "n6", "n8"}; - return convert_enum_idx( - options, 4, value, "pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); -} -uint8_t pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_number() const +// EstablishmentCause ::= ENUMERATED +std::string establishment_cause_opts::to_string() const { - static const uint8_t options[] = {2, 4, 6, 8}; - return map_enum_number( - options, 4, value, "pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); + static const char* options[] = {"emergency", + "highPriorityAccess", + "mt-Access", + "mo-Signalling", + "mo-Data", + "mo-VoiceCall", + "mo-VideoCall", + "mo-SMS", + "mps-PriorityAccess", + "mcs-PriorityAccess", + "spare6", + "spare5", + "spare4", + "spare3", + "spare2", + "spare1"}; + return convert_enum_idx(options, 16, value, "establishment_cause_e"); } -// PortIndexFor8Ranks ::= CHOICE -void port_idx_for8_ranks_c::destroy_() +// InitialUE-Identity ::= CHOICE +void init_ue_id_c::destroy_() { switch (type_) { - case types::port_idx8: - c.destroy(); - break; - case types::port_idx4: - c.destroy(); + case types::ng_minus5_g_s_tmsi_part1: + c.destroy >(); break; - case types::port_idx2: - c.destroy(); + case types::random_value: + c.destroy >(); break; default: break; } } -void port_idx_for8_ranks_c::set(types::options e) +void init_ue_id_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::port_idx8: - c.init(); - break; - case types::port_idx4: - c.init(); - break; - case types::port_idx2: - c.init(); + case types::ng_minus5_g_s_tmsi_part1: + c.init >(); break; - case types::port_idx1: + case types::random_value: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); + log_invalid_choice_id(type_, "init_ue_id_c"); } } -port_idx_for8_ranks_c::port_idx_for8_ranks_c(const port_idx_for8_ranks_c& other) +init_ue_id_c::init_ue_id_c(const init_ue_id_c& other) { type_ = other.type(); switch (type_) { - case types::port_idx8: - c.init(other.c.get()); - break; - case types::port_idx4: - c.init(other.c.get()); - break; - case types::port_idx2: - c.init(other.c.get()); + case types::ng_minus5_g_s_tmsi_part1: + c.init(other.c.get >()); break; - case types::port_idx1: + case types::random_value: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); + log_invalid_choice_id(type_, "init_ue_id_c"); } } -port_idx_for8_ranks_c& port_idx_for8_ranks_c::operator=(const port_idx_for8_ranks_c& other) +init_ue_id_c& init_ue_id_c::operator=(const init_ue_id_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::port_idx8: - c.set(other.c.get()); - break; - case types::port_idx4: - c.set(other.c.get()); - break; - case types::port_idx2: - c.set(other.c.get()); + case types::ng_minus5_g_s_tmsi_part1: + c.set(other.c.get >()); break; - case types::port_idx1: + case types::random_value: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); + log_invalid_choice_id(type_, "init_ue_id_c"); } return *this; } -void port_idx_for8_ranks_c::to_json(json_writer& j) const +void init_ue_id_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::port_idx8: - j.write_fieldname("portIndex8"); - j.start_obj(); - if (c.get().rank1_minus8_present) { - j.write_int("rank1-8", c.get().rank1_minus8); - } - if (c.get().rank2_minus8_present) { - j.start_array("rank2-8"); - for (const auto& e1 : c.get().rank2_minus8) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank3_minus8_present) { - j.start_array("rank3-8"); - for (const auto& e1 : c.get().rank3_minus8) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank4_minus8_present) { - j.start_array("rank4-8"); - for (const auto& e1 : c.get().rank4_minus8) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank5_minus8_present) { - j.start_array("rank5-8"); - for (const auto& e1 : c.get().rank5_minus8) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank6_minus8_present) { - j.start_array("rank6-8"); - for (const auto& e1 : c.get().rank6_minus8) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank7_minus8_present) { - j.start_array("rank7-8"); - for (const auto& e1 : c.get().rank7_minus8) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank8_minus8_present) { - j.start_array("rank8-8"); - for (const auto& e1 : c.get().rank8_minus8) { - j.write_int(e1); - } - j.end_array(); - } - j.end_obj(); - break; - case types::port_idx4: - j.write_fieldname("portIndex4"); - j.start_obj(); - if (c.get().rank1_minus4_present) { - j.write_int("rank1-4", c.get().rank1_minus4); - } - if (c.get().rank2_minus4_present) { - j.start_array("rank2-4"); - for (const auto& e1 : c.get().rank2_minus4) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank3_minus4_present) { - j.start_array("rank3-4"); - for (const auto& e1 : c.get().rank3_minus4) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().rank4_minus4_present) { - j.start_array("rank4-4"); - for (const auto& e1 : c.get().rank4_minus4) { - j.write_int(e1); - } - j.end_array(); - } - j.end_obj(); - break; - case types::port_idx2: - j.write_fieldname("portIndex2"); - j.start_obj(); - if (c.get().rank1_minus2_present) { - j.write_int("rank1-2", c.get().rank1_minus2); - } - if (c.get().rank2_minus2_present) { - j.start_array("rank2-2"); - for (const auto& e1 : c.get().rank2_minus2) { - j.write_int(e1); - } - j.end_array(); - } - j.end_obj(); + case types::ng_minus5_g_s_tmsi_part1: + j.write_str("ng-5G-S-TMSI-Part1", c.get >().to_string()); break; - case types::port_idx1: + case types::random_value: + j.write_str("randomValue", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); + log_invalid_choice_id(type_, "init_ue_id_c"); } j.end_obj(); } -SRSASN_CODE port_idx_for8_ranks_c::pack(bit_ref& bref) const +SRSASN_CODE init_ue_id_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::port_idx8: - HANDLE_CODE(bref.pack(c.get().rank1_minus8_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank2_minus8_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank3_minus8_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank4_minus8_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank5_minus8_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank6_minus8_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank7_minus8_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank8_minus8_present, 1)); - if (c.get().rank1_minus8_present) { - HANDLE_CODE(pack_integer(bref, c.get().rank1_minus8, (uint8_t)0u, (uint8_t)7u)); - } - if (c.get().rank2_minus8_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank2_minus8)[0], - c.get().rank2_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank3_minus8_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank3_minus8)[0], - c.get().rank3_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank4_minus8_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank4_minus8)[0], - c.get().rank4_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank5_minus8_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank5_minus8)[0], - c.get().rank5_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank6_minus8_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank6_minus8)[0], - c.get().rank6_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank7_minus8_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank7_minus8)[0], - c.get().rank7_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank8_minus8_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank8_minus8)[0], - c.get().rank8_minus8.size(), - integer_packer(0, 7))); - } - break; - case types::port_idx4: - HANDLE_CODE(bref.pack(c.get().rank1_minus4_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank2_minus4_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank3_minus4_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank4_minus4_present, 1)); - if (c.get().rank1_minus4_present) { - HANDLE_CODE(pack_integer(bref, c.get().rank1_minus4, (uint8_t)0u, (uint8_t)3u)); - } - if (c.get().rank2_minus4_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank2_minus4)[0], - c.get().rank2_minus4.size(), - integer_packer(0, 3))); - } - if (c.get().rank3_minus4_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank3_minus4)[0], - c.get().rank3_minus4.size(), - integer_packer(0, 3))); - } - if (c.get().rank4_minus4_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank4_minus4)[0], - c.get().rank4_minus4.size(), - integer_packer(0, 3))); - } - break; - case types::port_idx2: - HANDLE_CODE(bref.pack(c.get().rank1_minus2_present, 1)); - HANDLE_CODE(bref.pack(c.get().rank2_minus2_present, 1)); - if (c.get().rank1_minus2_present) { - HANDLE_CODE(pack_integer(bref, c.get().rank1_minus2, (uint8_t)0u, (uint8_t)1u)); - } - if (c.get().rank2_minus2_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().rank2_minus2)[0], - c.get().rank2_minus2.size(), - integer_packer(0, 1))); - } + case types::ng_minus5_g_s_tmsi_part1: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::port_idx1: + case types::random_value: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); + log_invalid_choice_id(type_, "init_ue_id_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE port_idx_for8_ranks_c::unpack(cbit_ref& bref) +SRSASN_CODE init_ue_id_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::port_idx8: - HANDLE_CODE(bref.unpack(c.get().rank1_minus8_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank2_minus8_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank3_minus8_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank4_minus8_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank5_minus8_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank6_minus8_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank7_minus8_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank8_minus8_present, 1)); - if (c.get().rank1_minus8_present) { - HANDLE_CODE(unpack_integer(c.get().rank1_minus8, bref, (uint8_t)0u, (uint8_t)7u)); - } - if (c.get().rank2_minus8_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank2_minus8)[0], - bref, - c.get().rank2_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank3_minus8_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank3_minus8)[0], - bref, - c.get().rank3_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank4_minus8_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank4_minus8)[0], - bref, - c.get().rank4_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank5_minus8_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank5_minus8)[0], - bref, - c.get().rank5_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank6_minus8_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank6_minus8)[0], - bref, - c.get().rank6_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank7_minus8_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank7_minus8)[0], - bref, - c.get().rank7_minus8.size(), - integer_packer(0, 7))); - } - if (c.get().rank8_minus8_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank8_minus8)[0], - bref, - c.get().rank8_minus8.size(), - integer_packer(0, 7))); - } - break; - case types::port_idx4: - HANDLE_CODE(bref.unpack(c.get().rank1_minus4_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank2_minus4_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank3_minus4_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank4_minus4_present, 1)); - if (c.get().rank1_minus4_present) { - HANDLE_CODE(unpack_integer(c.get().rank1_minus4, bref, (uint8_t)0u, (uint8_t)3u)); - } - if (c.get().rank2_minus4_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank2_minus4)[0], - bref, - c.get().rank2_minus4.size(), - integer_packer(0, 3))); - } - if (c.get().rank3_minus4_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank3_minus4)[0], - bref, - c.get().rank3_minus4.size(), - integer_packer(0, 3))); - } - if (c.get().rank4_minus4_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank4_minus4)[0], - bref, - c.get().rank4_minus4.size(), - integer_packer(0, 3))); - } - break; - case types::port_idx2: - HANDLE_CODE(bref.unpack(c.get().rank1_minus2_present, 1)); - HANDLE_CODE(bref.unpack(c.get().rank2_minus2_present, 1)); - if (c.get().rank1_minus2_present) { - HANDLE_CODE(unpack_integer(c.get().rank1_minus2, bref, (uint8_t)0u, (uint8_t)1u)); - } - if (c.get().rank2_minus2_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank2_minus2)[0], - bref, - c.get().rank2_minus2.size(), - integer_packer(0, 1))); - } + case types::ng_minus5_g_s_tmsi_part1: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::port_idx1: + case types::random_value: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); + log_invalid_choice_id(type_, "init_ue_id_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string port_idx_for8_ranks_c::types_opts::to_string() const +std::string init_ue_id_c::types_opts::to_string() const { - static const char* options[] = {"portIndex8", "portIndex4", "portIndex2", "portIndex1"}; - return convert_enum_idx(options, 4, value, "port_idx_for8_ranks_c::types"); + static const char* options[] = {"ng-5G-S-TMSI-Part1", "randomValue"}; + return convert_enum_idx(options, 2, value, "init_ue_id_c::types"); } -uint8_t port_idx_for8_ranks_c::types_opts::to_number() const +int8_t init_ue_id_c::types_opts::to_number() const { - static const uint8_t options[] = {8, 4, 2, 1}; - return map_enum_number(options, 4, value, "port_idx_for8_ranks_c::types"); + static const int8_t options[] = {-5}; + return map_enum_number(options, 1, value, "init_ue_id_c::types"); } -// RadioLinkMonitoringConfig ::= SEQUENCE -SRSASN_CODE radio_link_monitoring_cfg_s::pack(bit_ref& bref) const +// ReestabUE-Identity ::= SEQUENCE +SRSASN_CODE reestab_ue_id_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(fail_detection_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(fail_detection_res_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(beam_fail_instance_max_count_present, 1)); - HANDLE_CODE(bref.pack(beam_fail_detection_timer_present, 1)); - - if (fail_detection_res_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, fail_detection_res_to_add_mod_list, 1, 10)); - } - if (fail_detection_res_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, fail_detection_res_to_release_list, 1, 10, integer_packer(0, 9))); - } - if (beam_fail_instance_max_count_present) { - HANDLE_CODE(beam_fail_instance_max_count.pack(bref)); - } - if (beam_fail_detection_timer_present) { - HANDLE_CODE(beam_fail_detection_timer.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, c_rnti, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(short_mac_i.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE radio_link_monitoring_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE reestab_ue_id_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(fail_detection_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(fail_detection_res_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(beam_fail_instance_max_count_present, 1)); - HANDLE_CODE(bref.unpack(beam_fail_detection_timer_present, 1)); - - if (fail_detection_res_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(fail_detection_res_to_add_mod_list, bref, 1, 10)); - } - if (fail_detection_res_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(fail_detection_res_to_release_list, bref, 1, 10, integer_packer(0, 9))); - } - if (beam_fail_instance_max_count_present) { - HANDLE_CODE(beam_fail_instance_max_count.unpack(bref)); - } - if (beam_fail_detection_timer_present) { - HANDLE_CODE(beam_fail_detection_timer.unpack(bref)); - } + HANDLE_CODE(unpack_integer(c_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(short_mac_i.unpack(bref)); return SRSASN_SUCCESS; } -void radio_link_monitoring_cfg_s::to_json(json_writer& j) const +void reestab_ue_id_s::to_json(json_writer& j) const { j.start_obj(); - if (fail_detection_res_to_add_mod_list_present) { - j.start_array("failureDetectionResourcesToAddModList"); - for (const auto& e1 : fail_detection_res_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (fail_detection_res_to_release_list_present) { - j.start_array("failureDetectionResourcesToReleaseList"); - for (const auto& e1 : fail_detection_res_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (beam_fail_instance_max_count_present) { - j.write_str("beamFailureInstanceMaxCount", beam_fail_instance_max_count.to_string()); - } - if (beam_fail_detection_timer_present) { - j.write_str("beamFailureDetectionTimer", beam_fail_detection_timer.to_string()); - } + j.write_int("c-RNTI", c_rnti); + j.write_int("physCellId", pci); + j.write_str("shortMAC-I", short_mac_i.to_string()); j.end_obj(); } -std::string radio_link_monitoring_cfg_s::beam_fail_instance_max_count_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n3", "n4", "n5", "n6", "n8", "n10"}; - return convert_enum_idx(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_instance_max_count_e_"); -} -uint8_t radio_link_monitoring_cfg_s::beam_fail_instance_max_count_opts::to_number() const +// ReestablishmentCause ::= ENUMERATED +std::string reest_cause_opts::to_string() const { - static const uint8_t options[] = {1, 2, 3, 4, 5, 6, 8, 10}; - return map_enum_number(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_instance_max_count_e_"); + static const char* options[] = {"reconfigurationFailure", "handoverFailure", "otherFailure", "spare1"}; + return convert_enum_idx(options, 4, value, "reest_cause_e"); } -std::string radio_link_monitoring_cfg_s::beam_fail_detection_timer_opts::to_string() const -{ - static const char* options[] = {"pbfd1", "pbfd2", "pbfd3", "pbfd4", "pbfd5", "pbfd6", "pbfd8", "pbfd10"}; - return convert_enum_idx(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_detection_timer_e_"); -} -uint8_t radio_link_monitoring_cfg_s::beam_fail_detection_timer_opts::to_number() const +// ResumeCause ::= ENUMERATED +std::string resume_cause_opts::to_string() const { - static const uint8_t options[] = {1, 2, 3, 4, 5, 6, 8, 10}; - return map_enum_number(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_detection_timer_e_"); + static const char* options[] = {"emergency", + "highPriorityAccess", + "mt-Access", + "mo-Signalling", + "mo-Data", + "mo-VoiceCall", + "mo-VideoCall", + "mo-SMS", + "rna-Update", + "mps-PriorityAccess", + "mcs-PriorityAccess", + "spare1", + "spare2", + "spare3", + "spare4", + "spare5"}; + return convert_enum_idx(options, 16, value, "resume_cause_e"); } -// SPS-Config ::= SEQUENCE -SRSASN_CODE sps_cfg_s::pack(bit_ref& bref) const +// RRCReestablishmentRequest-IEs ::= SEQUENCE +SRSASN_CODE rrc_reest_request_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(n1_pucch_an_present, 1)); - HANDLE_CODE(bref.pack(mcs_table_present, 1)); - - HANDLE_CODE(periodicity.pack(bref)); - HANDLE_CODE(pack_integer(bref, nrof_harq_processes, (uint8_t)1u, (uint8_t)8u)); - if (n1_pucch_an_present) { - HANDLE_CODE(pack_integer(bref, n1_pucch_an, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(ue_id.pack(bref)); + HANDLE_CODE(reest_cause.pack(bref)); + HANDLE_CODE(spare.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE sps_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_reest_request_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(n1_pucch_an_present, 1)); - HANDLE_CODE(bref.unpack(mcs_table_present, 1)); - - HANDLE_CODE(periodicity.unpack(bref)); - HANDLE_CODE(unpack_integer(nrof_harq_processes, bref, (uint8_t)1u, (uint8_t)8u)); - if (n1_pucch_an_present) { - HANDLE_CODE(unpack_integer(n1_pucch_an, bref, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(ue_id.unpack(bref)); + HANDLE_CODE(reest_cause.unpack(bref)); + HANDLE_CODE(spare.unpack(bref)); return SRSASN_SUCCESS; } -void sps_cfg_s::to_json(json_writer& j) const +void rrc_reest_request_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("periodicity", periodicity.to_string()); - j.write_int("nrofHARQ-Processes", nrof_harq_processes); - if (n1_pucch_an_present) { - j.write_int("n1PUCCH-AN", n1_pucch_an); - } - if (mcs_table_present) { - j.write_str("mcs-Table", "qam64LowSE"); - } + j.write_fieldname("ue-Identity"); + ue_id.to_json(j); + j.write_str("reestablishmentCause", reest_cause.to_string()); + j.write_str("spare", spare.to_string()); j.end_obj(); } -std::string sps_cfg_s::periodicity_opts::to_string() const -{ - static const char* options[] = {"ms10", - "ms20", - "ms32", - "ms40", - "ms64", - "ms80", - "ms128", - "ms160", - "ms320", - "ms640", - "spare6", - "spare5", - "spare4", - "spare3", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "sps_cfg_s::periodicity_e_"); -} -uint16_t sps_cfg_s::periodicity_opts::to_number() const -{ - static const uint16_t options[] = {10, 20, 32, 40, 64, 80, 128, 160, 320, 640}; - return map_enum_number(options, 10, value, "sps_cfg_s::periodicity_e_"); -} - -// SRS-TPC-PDCCH-Config ::= SEQUENCE -SRSASN_CODE srs_tpc_pdcch_cfg_s::pack(bit_ref& bref) const +// RRCResumeRequest-IEs ::= SEQUENCE +SRSASN_CODE rrc_resume_request_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(srs_cc_set_idxlist_present, 1)); - - if (srs_cc_set_idxlist_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, srs_cc_set_idxlist, 1, 4)); - } + HANDLE_CODE(resume_id.pack(bref)); + HANDLE_CODE(resume_mac_i.pack(bref)); + HANDLE_CODE(resume_cause.pack(bref)); + HANDLE_CODE(spare.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE srs_tpc_pdcch_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_resume_request_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(srs_cc_set_idxlist_present, 1)); - - if (srs_cc_set_idxlist_present) { - HANDLE_CODE(unpack_dyn_seq_of(srs_cc_set_idxlist, bref, 1, 4)); - } + HANDLE_CODE(resume_id.unpack(bref)); + HANDLE_CODE(resume_mac_i.unpack(bref)); + HANDLE_CODE(resume_cause.unpack(bref)); + HANDLE_CODE(spare.unpack(bref)); return SRSASN_SUCCESS; } -void srs_tpc_pdcch_cfg_s::to_json(json_writer& j) const +void rrc_resume_request_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (srs_cc_set_idxlist_present) { - j.start_array("srs-CC-SetIndexlist"); - for (const auto& e1 : srs_cc_set_idxlist) { - e1.to_json(j); - } - j.end_array(); - } - j.end_obj(); + j.write_str("resumeIdentity", resume_id.to_string()); + j.write_str("resumeMAC-I", resume_mac_i.to_string()); + j.write_str("resumeCause", resume_cause.to_string()); + j.write_str("spare", spare.to_string()); + j.end_obj(); } -// SlotFormatCombinationsPerCell ::= SEQUENCE -SRSASN_CODE slot_format_combinations_per_cell_s::pack(bit_ref& bref) const +// RRCSetupRequest-IEs ::= SEQUENCE +SRSASN_CODE rrc_setup_request_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(subcarrier_spacing2_present, 1)); - HANDLE_CODE(bref.pack(slot_format_combinations_present, 1)); - HANDLE_CODE(bref.pack(position_in_dci_present, 1)); - - HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(subcarrier_spacing.pack(bref)); - if (subcarrier_spacing2_present) { - HANDLE_CODE(subcarrier_spacing2.pack(bref)); - } - if (slot_format_combinations_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, slot_format_combinations, 1, 512)); - } - if (position_in_dci_present) { - HANDLE_CODE(pack_integer(bref, position_in_dci, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(ue_id.pack(bref)); + HANDLE_CODE(establishment_cause.pack(bref)); + HANDLE_CODE(spare.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE slot_format_combinations_per_cell_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_setup_request_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(subcarrier_spacing2_present, 1)); - HANDLE_CODE(bref.unpack(slot_format_combinations_present, 1)); - HANDLE_CODE(bref.unpack(position_in_dci_present, 1)); - - HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(subcarrier_spacing.unpack(bref)); - if (subcarrier_spacing2_present) { - HANDLE_CODE(subcarrier_spacing2.unpack(bref)); - } - if (slot_format_combinations_present) { - HANDLE_CODE(unpack_dyn_seq_of(slot_format_combinations, bref, 1, 512)); - } - if (position_in_dci_present) { - HANDLE_CODE(unpack_integer(position_in_dci, bref, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(ue_id.unpack(bref)); + HANDLE_CODE(establishment_cause.unpack(bref)); + HANDLE_CODE(spare.unpack(bref)); return SRSASN_SUCCESS; } -void slot_format_combinations_per_cell_s::to_json(json_writer& j) const +void rrc_setup_request_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("servingCellId", serving_cell_id); - j.write_str("subcarrierSpacing", subcarrier_spacing.to_string()); - if (subcarrier_spacing2_present) { - j.write_str("subcarrierSpacing2", subcarrier_spacing2.to_string()); - } - if (slot_format_combinations_present) { - j.start_array("slotFormatCombinations"); - for (const auto& e1 : slot_format_combinations) { - e1.to_json(j); - } - j.end_array(); - } - if (position_in_dci_present) { - j.write_int("positionInDCI", position_in_dci); - } + j.write_fieldname("ue-Identity"); + ue_id.to_json(j); + j.write_str("establishmentCause", establishment_cause.to_string()); + j.write_str("spare", spare.to_string()); j.end_obj(); } -// BWP-DownlinkDedicated ::= SEQUENCE -SRSASN_CODE bwp_dl_ded_s::pack(bit_ref& bref) const +// RRCSystemInfoRequest-IEs ::= SEQUENCE +SRSASN_CODE rrc_sys_info_request_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(pdcch_cfg_present, 1)); - HANDLE_CODE(bref.pack(pdsch_cfg_present, 1)); - HANDLE_CODE(bref.pack(sps_cfg_present, 1)); - HANDLE_CODE(bref.pack(radio_link_monitoring_cfg_present, 1)); - - if (pdcch_cfg_present) { - HANDLE_CODE(pdcch_cfg.pack(bref)); - } - if (pdsch_cfg_present) { - HANDLE_CODE(pdsch_cfg.pack(bref)); - } - if (sps_cfg_present) { - HANDLE_CODE(sps_cfg.pack(bref)); - } - if (radio_link_monitoring_cfg_present) { - HANDLE_CODE(radio_link_monitoring_cfg.pack(bref)); - } + HANDLE_CODE(requested_si_list.pack(bref)); + HANDLE_CODE(spare.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE bwp_dl_ded_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_sys_info_request_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(pdcch_cfg_present, 1)); - HANDLE_CODE(bref.unpack(pdsch_cfg_present, 1)); - HANDLE_CODE(bref.unpack(sps_cfg_present, 1)); - HANDLE_CODE(bref.unpack(radio_link_monitoring_cfg_present, 1)); - - if (pdcch_cfg_present) { - HANDLE_CODE(pdcch_cfg.unpack(bref)); - } - if (pdsch_cfg_present) { - HANDLE_CODE(pdsch_cfg.unpack(bref)); - } - if (sps_cfg_present) { - HANDLE_CODE(sps_cfg.unpack(bref)); - } - if (radio_link_monitoring_cfg_present) { - HANDLE_CODE(radio_link_monitoring_cfg.unpack(bref)); - } + HANDLE_CODE(requested_si_list.unpack(bref)); + HANDLE_CODE(spare.unpack(bref)); return SRSASN_SUCCESS; } -void bwp_dl_ded_s::to_json(json_writer& j) const +void rrc_sys_info_request_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (pdcch_cfg_present) { - j.write_fieldname("pdcch-Config"); - pdcch_cfg.to_json(j); - } - if (pdsch_cfg_present) { - j.write_fieldname("pdsch-Config"); - pdsch_cfg.to_json(j); - } - if (sps_cfg_present) { - j.write_fieldname("sps-Config"); - sps_cfg.to_json(j); - } - if (radio_link_monitoring_cfg_present) { - j.write_fieldname("radioLinkMonitoringConfig"); - radio_link_monitoring_cfg.to_json(j); - } + j.write_str("requested-SI-List", requested_si_list.to_string()); + j.write_str("spare", spare.to_string()); j.end_obj(); } -// BWP-Uplink ::= SEQUENCE -SRSASN_CODE bwp_ul_s::pack(bit_ref& bref) const +// RRCReestablishmentRequest ::= SEQUENCE +SRSASN_CODE rrc_reest_request_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(bwp_common_present, 1)); - HANDLE_CODE(bref.pack(bwp_ded_present, 1)); - - HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); - if (bwp_common_present) { - HANDLE_CODE(bwp_common.pack(bref)); - } - if (bwp_ded_present) { - HANDLE_CODE(bwp_ded.pack(bref)); - } + HANDLE_CODE(rrc_reest_request.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE bwp_ul_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_reest_request_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(bwp_common_present, 1)); - HANDLE_CODE(bref.unpack(bwp_ded_present, 1)); - - HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); - if (bwp_common_present) { - HANDLE_CODE(bwp_common.unpack(bref)); - } - if (bwp_ded_present) { - HANDLE_CODE(bwp_ded.unpack(bref)); - } + HANDLE_CODE(rrc_reest_request.unpack(bref)); return SRSASN_SUCCESS; } -void bwp_ul_s::to_json(json_writer& j) const +void rrc_reest_request_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("bwp-Id", bwp_id); - if (bwp_common_present) { - j.write_fieldname("bwp-Common"); - bwp_common.to_json(j); - } - if (bwp_ded_present) { - j.write_fieldname("bwp-Dedicated"); - bwp_ded.to_json(j); - } + j.write_fieldname("rrcReestablishmentRequest"); + rrc_reest_request.to_json(j); j.end_obj(); } -// CFRA ::= SEQUENCE -SRSASN_CODE cfra_s::pack(bit_ref& bref) const +// RRCResumeRequest ::= SEQUENCE +SRSASN_CODE rrc_resume_request_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(occasions_present, 1)); - - if (occasions_present) { - HANDLE_CODE(bref.pack(occasions.ssb_per_rach_occasion_present, 1)); - HANDLE_CODE(occasions.rach_cfg_generic.pack(bref)); - if (occasions.ssb_per_rach_occasion_present) { - HANDLE_CODE(occasions.ssb_per_rach_occasion.pack(bref)); - } - } - HANDLE_CODE(res.pack(bref)); - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= total_nof_ra_preambs_v1530_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(rrc_resume_request.pack(bref)); - HANDLE_CODE(bref.pack(total_nof_ra_preambs_v1530_present, 1)); - if (total_nof_ra_preambs_v1530_present) { - HANDLE_CODE(pack_integer(bref, total_nof_ra_preambs_v1530, (uint8_t)1u, (uint8_t)63u)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE cfra_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_resume_request_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(occasions_present, 1)); + HANDLE_CODE(rrc_resume_request.unpack(bref)); - if (occasions_present) { - HANDLE_CODE(bref.unpack(occasions.ssb_per_rach_occasion_present, 1)); - HANDLE_CODE(occasions.rach_cfg_generic.unpack(bref)); - if (occasions.ssb_per_rach_occasion_present) { - HANDLE_CODE(occasions.ssb_per_rach_occasion.unpack(bref)); - } - } - HANDLE_CODE(res.unpack(bref)); + return SRSASN_SUCCESS; +} +void rrc_resume_request_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_fieldname("rrcResumeRequest"); + rrc_resume_request.to_json(j); + j.end_obj(); +} - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); +// RRCSetupRequest ::= SEQUENCE +SRSASN_CODE rrc_setup_request_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(rrc_setup_request.pack(bref)); - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_setup_request_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(rrc_setup_request.unpack(bref)); - HANDLE_CODE(bref.unpack(total_nof_ra_preambs_v1530_present, 1)); - if (total_nof_ra_preambs_v1530_present) { - HANDLE_CODE(unpack_integer(total_nof_ra_preambs_v1530, bref, (uint8_t)1u, (uint8_t)63u)); - } - } - } return SRSASN_SUCCESS; } -void cfra_s::to_json(json_writer& j) const +void rrc_setup_request_s::to_json(json_writer& j) const { j.start_obj(); - if (occasions_present) { - j.write_fieldname("occasions"); - j.start_obj(); - j.write_fieldname("rach-ConfigGeneric"); - occasions.rach_cfg_generic.to_json(j); - if (occasions.ssb_per_rach_occasion_present) { - j.write_str("ssb-perRACH-Occasion", occasions.ssb_per_rach_occasion.to_string()); - } - j.end_obj(); - } - j.write_fieldname("resources"); - res.to_json(j); - if (ext) { - if (total_nof_ra_preambs_v1530_present) { - j.write_int("totalNumberOfRA-Preambles-v1530", total_nof_ra_preambs_v1530); - } - } + j.write_fieldname("rrcSetupRequest"); + rrc_setup_request.to_json(j); j.end_obj(); } -std::string cfra_s::occasions_s_::ssb_per_rach_occasion_opts::to_string() const +// RRCSystemInfoRequest ::= SEQUENCE +SRSASN_CODE rrc_sys_info_request_s::pack(bit_ref& bref) const { - static const char* options[] = {"oneEighth", "oneFourth", "oneHalf", "one", "two", "four", "eight", "sixteen"}; - return convert_enum_idx(options, 8, value, "cfra_s::occasions_s_::ssb_per_rach_occasion_e_"); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; } -float cfra_s::occasions_s_::ssb_per_rach_occasion_opts::to_number() const +SRSASN_CODE rrc_sys_info_request_s::unpack(cbit_ref& bref) { - static const float options[] = {0.125, 0.25, 0.5, 1.0, 2.0, 4.0, 8.0, 6.0}; - return map_enum_number(options, 8, value, "cfra_s::occasions_s_::ssb_per_rach_occasion_e_"); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; } -std::string cfra_s::occasions_s_::ssb_per_rach_occasion_opts::to_number_string() const +void rrc_sys_info_request_s::to_json(json_writer& j) const { - static const char* options[] = {"1/8", "1/4", "1/2", "1", "2", "4", "8", "6"}; - return convert_enum_idx(options, 8, value, "cfra_s::occasions_s_::ssb_per_rach_occasion_e_"); + j.start_obj(); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); } -void cfra_s::res_c_::destroy_() +void rrc_sys_info_request_s::crit_exts_c_::destroy_() { switch (type_) { - case types::ssb: - c.destroy(); - break; - case types::csirs: - c.destroy(); + case types::rrc_sys_info_request: + c.destroy(); break; default: break; } } -void cfra_s::res_c_::set(types::options e) +void rrc_sys_info_request_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ssb: - c.init(); + case types::rrc_sys_info_request: + c.init(); break; - case types::csirs: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cfra_s::res_c_"); + log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); } } -cfra_s::res_c_::res_c_(const cfra_s::res_c_& other) +rrc_sys_info_request_s::crit_exts_c_::crit_exts_c_(const rrc_sys_info_request_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::ssb: - c.init(other.c.get()); + case types::rrc_sys_info_request: + c.init(other.c.get()); break; - case types::csirs: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cfra_s::res_c_"); + log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); } } -cfra_s::res_c_& cfra_s::res_c_::operator=(const cfra_s::res_c_& other) +rrc_sys_info_request_s::crit_exts_c_& +rrc_sys_info_request_s::crit_exts_c_::operator=(const rrc_sys_info_request_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb: - c.set(other.c.get()); + case types::rrc_sys_info_request: + c.set(other.c.get()); break; - case types::csirs: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cfra_s::res_c_"); + log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); } return *this; } -void cfra_s::res_c_::to_json(json_writer& j) const +void rrc_sys_info_request_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb: - j.write_fieldname("ssb"); - j.start_obj(); - j.start_array("ssb-ResourceList"); - for (const auto& e1 : c.get().ssb_res_list) { - e1.to_json(j); - } - j.end_array(); - j.write_int("ra-ssb-OccasionMaskIndex", c.get().ra_ssb_occasion_mask_idx); - j.end_obj(); + case types::rrc_sys_info_request: + j.write_fieldname("rrcSystemInfoRequest"); + c.get().to_json(j); break; - case types::csirs: - j.write_fieldname("csirs"); - j.start_obj(); - j.start_array("csirs-ResourceList"); - for (const auto& e1 : c.get().csirs_res_list) { - e1.to_json(j); - } - j.end_array(); - j.write_int("rsrp-ThresholdCSI-RS", c.get().rsrp_thres_csi_rs); - j.end_obj(); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "cfra_s::res_c_"); + log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE cfra_s::res_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_sys_info_request_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get().ssb_res_list, 1, 64)); - HANDLE_CODE(pack_integer(bref, c.get().ra_ssb_occasion_mask_idx, (uint8_t)0u, (uint8_t)15u)); + case types::rrc_sys_info_request: + HANDLE_CODE(c.get().pack(bref)); break; - case types::csirs: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get().csirs_res_list, 1, 96)); - HANDLE_CODE(pack_integer(bref, c.get().rsrp_thres_csi_rs, (uint8_t)0u, (uint8_t)127u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "cfra_s::res_c_"); + log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE cfra_s::res_c_::unpack(cbit_ref& bref) +SRSASN_CODE rrc_sys_info_request_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb: - HANDLE_CODE(unpack_dyn_seq_of(c.get().ssb_res_list, bref, 1, 64)); - HANDLE_CODE(unpack_integer(c.get().ra_ssb_occasion_mask_idx, bref, (uint8_t)0u, (uint8_t)15u)); + case types::rrc_sys_info_request: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::csirs: - HANDLE_CODE(unpack_dyn_seq_of(c.get().csirs_res_list, bref, 1, 96)); - HANDLE_CODE(unpack_integer(c.get().rsrp_thres_csi_rs, bref, (uint8_t)0u, (uint8_t)127u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "cfra_s::res_c_"); + log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string cfra_s::res_c_::types_opts::to_string() const -{ - static const char* options[] = {"ssb", "csirs"}; - return convert_enum_idx(options, 2, value, "cfra_s::res_c_::types"); -} - -// CSI-IM-Resource ::= SEQUENCE -SRSASN_CODE csi_im_res_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(csi_im_res_elem_pattern_present, 1)); - HANDLE_CODE(bref.pack(freq_band_present, 1)); - HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); - - HANDLE_CODE(pack_integer(bref, csi_im_res_id, (uint8_t)0u, (uint8_t)31u)); - if (csi_im_res_elem_pattern_present) { - HANDLE_CODE(csi_im_res_elem_pattern.pack(bref)); - } - if (freq_band_present) { - HANDLE_CODE(freq_band.pack(bref)); - } - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_im_res_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(csi_im_res_elem_pattern_present, 1)); - HANDLE_CODE(bref.unpack(freq_band_present, 1)); - HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); - - HANDLE_CODE(unpack_integer(csi_im_res_id, bref, (uint8_t)0u, (uint8_t)31u)); - if (csi_im_res_elem_pattern_present) { - HANDLE_CODE(csi_im_res_elem_pattern.unpack(bref)); - } - if (freq_band_present) { - HANDLE_CODE(freq_band.unpack(bref)); - } - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void csi_im_res_s::to_json(json_writer& j) const +std::string rrc_sys_info_request_s::crit_exts_c_::types_opts::to_string() const { - j.start_obj(); - j.write_int("csi-IM-ResourceId", csi_im_res_id); - if (csi_im_res_elem_pattern_present) { - j.write_fieldname("csi-IM-ResourceElementPattern"); - csi_im_res_elem_pattern.to_json(j); - } - if (freq_band_present) { - j.write_fieldname("freqBand"); - freq_band.to_json(j); - } - if (periodicity_and_offset_present) { - j.write_fieldname("periodicityAndOffset"); - periodicity_and_offset.to_json(j); - } - j.end_obj(); + static const char* options[] = {"rrcSystemInfoRequest", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_sys_info_request_s::crit_exts_c_::types"); } -void csi_im_res_s::csi_im_res_elem_pattern_c_::destroy_() +// UL-CCCH-MessageType ::= CHOICE +void ul_ccch_msg_type_c::destroy_() { switch (type_) { - case types::pattern0: - c.destroy(); - break; - case types::pattern1: - c.destroy(); + case types::c1: + c.destroy(); break; default: break; } } -void csi_im_res_s::csi_im_res_elem_pattern_c_::set(types::options e) +void ul_ccch_msg_type_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::pattern0: - c.init(); + case types::c1: + c.init(); break; - case types::pattern1: - c.init(); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); } } -csi_im_res_s::csi_im_res_elem_pattern_c_::csi_im_res_elem_pattern_c_( - const csi_im_res_s::csi_im_res_elem_pattern_c_& other) +ul_ccch_msg_type_c::ul_ccch_msg_type_c(const ul_ccch_msg_type_c& other) { type_ = other.type(); switch (type_) { - case types::pattern0: - c.init(other.c.get()); + case types::c1: + c.init(other.c.get()); break; - case types::pattern1: - c.init(other.c.get()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); } } -csi_im_res_s::csi_im_res_elem_pattern_c_& csi_im_res_s::csi_im_res_elem_pattern_c_:: - operator=(const csi_im_res_s::csi_im_res_elem_pattern_c_& other) +ul_ccch_msg_type_c& ul_ccch_msg_type_c::operator=(const ul_ccch_msg_type_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::pattern0: - c.set(other.c.get()); + case types::c1: + c.set(other.c.get()); break; - case types::pattern1: - c.set(other.c.get()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); } return *this; } -void csi_im_res_s::csi_im_res_elem_pattern_c_::to_json(json_writer& j) const +void ul_ccch_msg_type_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::pattern0: - j.write_fieldname("pattern0"); - j.start_obj(); - j.write_str("subcarrierLocation-p0", c.get().subcarrier_location_p0.to_string()); - j.write_int("symbolLocation-p0", c.get().symbol_location_p0); - j.end_obj(); + case types::c1: + j.write_fieldname("c1"); + c.get().to_json(j); break; - case types::pattern1: - j.write_fieldname("pattern1"); - j.start_obj(); - j.write_str("subcarrierLocation-p1", c.get().subcarrier_location_p1.to_string()); - j.write_int("symbolLocation-p1", c.get().symbol_location_p1); - j.end_obj(); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); } j.end_obj(); } -SRSASN_CODE csi_im_res_s::csi_im_res_elem_pattern_c_::pack(bit_ref& bref) const +SRSASN_CODE ul_ccch_msg_type_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::pattern0: - HANDLE_CODE(c.get().subcarrier_location_p0.pack(bref)); - HANDLE_CODE(pack_integer(bref, c.get().symbol_location_p0, (uint8_t)0u, (uint8_t)12u)); + case types::c1: + HANDLE_CODE(c.get().pack(bref)); break; - case types::pattern1: - HANDLE_CODE(c.get().subcarrier_location_p1.pack(bref)); - HANDLE_CODE(pack_integer(bref, c.get().symbol_location_p1, (uint8_t)0u, (uint8_t)13u)); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_im_res_s::csi_im_res_elem_pattern_c_::unpack(cbit_ref& bref) +SRSASN_CODE ul_ccch_msg_type_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::pattern0: - HANDLE_CODE(c.get().subcarrier_location_p0.unpack(bref)); - HANDLE_CODE(unpack_integer(c.get().symbol_location_p0, bref, (uint8_t)0u, (uint8_t)12u)); + case types::c1: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::pattern1: - HANDLE_CODE(c.get().subcarrier_location_p1.unpack(bref)); - HANDLE_CODE(unpack_integer(c.get().symbol_location_p1, bref, (uint8_t)0u, (uint8_t)13u)); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_opts::to_string() const -{ - static const char* options[] = {"s0", "s2", "s4", "s6", "s8", "s10"}; - return convert_enum_idx( - options, 6, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_e_"); -} -uint8_t csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_opts::to_number() const -{ - static const uint8_t options[] = {0, 2, 4, 6, 8, 10}; - return map_enum_number( - options, 6, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_e_"); -} - -std::string csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_opts::to_string() const -{ - static const char* options[] = {"s0", "s4", "s8"}; - return convert_enum_idx( - options, 3, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_e_"); -} -uint8_t csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_opts::to_number() const -{ - static const uint8_t options[] = {0, 4, 8}; - return map_enum_number( - options, 3, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_e_"); -} - -std::string csi_im_res_s::csi_im_res_elem_pattern_c_::types_opts::to_string() const -{ - static const char* options[] = {"pattern0", "pattern1"}; - return convert_enum_idx(options, 2, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::types"); -} -uint8_t csi_im_res_s::csi_im_res_elem_pattern_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {0, 1}; - return map_enum_number(options, 2, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::types"); -} - -// CSI-IM-ResourceSet ::= SEQUENCE -SRSASN_CODE csi_im_res_set_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, csi_im_res_set_id, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res, 1, 8, integer_packer(0, 31))); - - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_im_res_set_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(csi_im_res_set_id, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_dyn_seq_of(csi_im_res, bref, 1, 8, integer_packer(0, 31))); - - return SRSASN_SUCCESS; -} -void csi_im_res_set_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("csi-IM-ResourceSetId", csi_im_res_set_id); - j.start_array("csi-IM-Resources"); - for (const auto& e1 : csi_im_res) { - j.write_int(e1); - } - j.end_array(); - j.end_obj(); -} - -// CSI-ReportConfig ::= SEQUENCE -SRSASN_CODE csi_report_cfg_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(carrier_present, 1)); - HANDLE_CODE(bref.pack(csi_im_res_for_interference_present, 1)); - HANDLE_CODE(bref.pack(nzp_csi_rs_res_for_interference_present, 1)); - HANDLE_CODE(bref.pack(report_freq_cfg_present, 1)); - HANDLE_CODE(bref.pack(codebook_cfg_present, 1)); - HANDLE_CODE(bref.pack(dummy_present, 1)); - HANDLE_CODE(bref.pack(cqi_table_present, 1)); - HANDLE_CODE(bref.pack(non_pmi_port_ind_present, 1)); - - HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)0u, (uint8_t)47u)); - if (carrier_present) { - HANDLE_CODE(pack_integer(bref, carrier, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(pack_integer(bref, res_for_ch_meas, (uint8_t)0u, (uint8_t)111u)); - if (csi_im_res_for_interference_present) { - HANDLE_CODE(pack_integer(bref, csi_im_res_for_interference, (uint8_t)0u, (uint8_t)111u)); - } - if (nzp_csi_rs_res_for_interference_present) { - HANDLE_CODE(pack_integer(bref, nzp_csi_rs_res_for_interference, (uint8_t)0u, (uint8_t)111u)); - } - HANDLE_CODE(report_cfg_type.pack(bref)); - HANDLE_CODE(report_quant.pack(bref)); - if (report_freq_cfg_present) { - HANDLE_CODE(bref.pack(report_freq_cfg.cqi_format_ind_present, 1)); - HANDLE_CODE(bref.pack(report_freq_cfg.pmi_format_ind_present, 1)); - HANDLE_CODE(bref.pack(report_freq_cfg.csi_report_band_present, 1)); - if (report_freq_cfg.cqi_format_ind_present) { - HANDLE_CODE(report_freq_cfg.cqi_format_ind.pack(bref)); - } - if (report_freq_cfg.pmi_format_ind_present) { - HANDLE_CODE(report_freq_cfg.pmi_format_ind.pack(bref)); - } - if (report_freq_cfg.csi_report_band_present) { - HANDLE_CODE(report_freq_cfg.csi_report_band.pack(bref)); - } - } - HANDLE_CODE(time_restrict_for_ch_meass.pack(bref)); - HANDLE_CODE(time_restrict_for_interference_meass.pack(bref)); - if (codebook_cfg_present) { - HANDLE_CODE(codebook_cfg.pack(bref)); - } - if (dummy_present) { - HANDLE_CODE(dummy.pack(bref)); - } - HANDLE_CODE(group_based_beam_report.pack(bref)); - if (cqi_table_present) { - HANDLE_CODE(cqi_table.pack(bref)); - } - HANDLE_CODE(subband_size.pack(bref)); - if (non_pmi_port_ind_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, non_pmi_port_ind, 1, 128)); - } - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= semi_persistent_on_pusch_v1530.is_present(); - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(semi_persistent_on_pusch_v1530.is_present(), 1)); - if (semi_persistent_on_pusch_v1530.is_present()) { - HANDLE_CODE(semi_persistent_on_pusch_v1530->report_slot_cfg_v1530.pack(bref)); - } - } - } - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_report_cfg_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(carrier_present, 1)); - HANDLE_CODE(bref.unpack(csi_im_res_for_interference_present, 1)); - HANDLE_CODE(bref.unpack(nzp_csi_rs_res_for_interference_present, 1)); - HANDLE_CODE(bref.unpack(report_freq_cfg_present, 1)); - HANDLE_CODE(bref.unpack(codebook_cfg_present, 1)); - HANDLE_CODE(bref.unpack(dummy_present, 1)); - HANDLE_CODE(bref.unpack(cqi_table_present, 1)); - HANDLE_CODE(bref.unpack(non_pmi_port_ind_present, 1)); - - HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)0u, (uint8_t)47u)); - if (carrier_present) { - HANDLE_CODE(unpack_integer(carrier, bref, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(unpack_integer(res_for_ch_meas, bref, (uint8_t)0u, (uint8_t)111u)); - if (csi_im_res_for_interference_present) { - HANDLE_CODE(unpack_integer(csi_im_res_for_interference, bref, (uint8_t)0u, (uint8_t)111u)); - } - if (nzp_csi_rs_res_for_interference_present) { - HANDLE_CODE(unpack_integer(nzp_csi_rs_res_for_interference, bref, (uint8_t)0u, (uint8_t)111u)); - } - HANDLE_CODE(report_cfg_type.unpack(bref)); - HANDLE_CODE(report_quant.unpack(bref)); - if (report_freq_cfg_present) { - HANDLE_CODE(bref.unpack(report_freq_cfg.cqi_format_ind_present, 1)); - HANDLE_CODE(bref.unpack(report_freq_cfg.pmi_format_ind_present, 1)); - HANDLE_CODE(bref.unpack(report_freq_cfg.csi_report_band_present, 1)); - if (report_freq_cfg.cqi_format_ind_present) { - HANDLE_CODE(report_freq_cfg.cqi_format_ind.unpack(bref)); - } - if (report_freq_cfg.pmi_format_ind_present) { - HANDLE_CODE(report_freq_cfg.pmi_format_ind.unpack(bref)); - } - if (report_freq_cfg.csi_report_band_present) { - HANDLE_CODE(report_freq_cfg.csi_report_band.unpack(bref)); - } - } - HANDLE_CODE(time_restrict_for_ch_meass.unpack(bref)); - HANDLE_CODE(time_restrict_for_interference_meass.unpack(bref)); - if (codebook_cfg_present) { - HANDLE_CODE(codebook_cfg.unpack(bref)); - } - if (dummy_present) { - HANDLE_CODE(dummy.unpack(bref)); - } - HANDLE_CODE(group_based_beam_report.unpack(bref)); - if (cqi_table_present) { - HANDLE_CODE(cqi_table.unpack(bref)); - } - HANDLE_CODE(subband_size.unpack(bref)); - if (non_pmi_port_ind_present) { - HANDLE_CODE(unpack_dyn_seq_of(non_pmi_port_ind, bref, 1, 128)); - } - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - bool semi_persistent_on_pusch_v1530_present; - HANDLE_CODE(bref.unpack(semi_persistent_on_pusch_v1530_present, 1)); - semi_persistent_on_pusch_v1530.set_present(semi_persistent_on_pusch_v1530_present); - if (semi_persistent_on_pusch_v1530.is_present()) { - HANDLE_CODE(semi_persistent_on_pusch_v1530->report_slot_cfg_v1530.unpack(bref)); - } - } - } - return SRSASN_SUCCESS; -} -void csi_report_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("reportConfigId", report_cfg_id); - if (carrier_present) { - j.write_int("carrier", carrier); - } - j.write_int("resourcesForChannelMeasurement", res_for_ch_meas); - if (csi_im_res_for_interference_present) { - j.write_int("csi-IM-ResourcesForInterference", csi_im_res_for_interference); - } - if (nzp_csi_rs_res_for_interference_present) { - j.write_int("nzp-CSI-RS-ResourcesForInterference", nzp_csi_rs_res_for_interference); - } - j.write_fieldname("reportConfigType"); - report_cfg_type.to_json(j); - j.write_fieldname("reportQuantity"); - report_quant.to_json(j); - if (report_freq_cfg_present) { - j.write_fieldname("reportFreqConfiguration"); - j.start_obj(); - if (report_freq_cfg.cqi_format_ind_present) { - j.write_str("cqi-FormatIndicator", report_freq_cfg.cqi_format_ind.to_string()); - } - if (report_freq_cfg.pmi_format_ind_present) { - j.write_str("pmi-FormatIndicator", report_freq_cfg.pmi_format_ind.to_string()); - } - if (report_freq_cfg.csi_report_band_present) { - j.write_fieldname("csi-ReportingBand"); - report_freq_cfg.csi_report_band.to_json(j); - } - j.end_obj(); - } - j.write_str("timeRestrictionForChannelMeasurements", time_restrict_for_ch_meass.to_string()); - j.write_str("timeRestrictionForInterferenceMeasurements", time_restrict_for_interference_meass.to_string()); - if (codebook_cfg_present) { - j.write_fieldname("codebookConfig"); - codebook_cfg.to_json(j); - } - if (dummy_present) { - j.write_str("dummy", dummy.to_string()); - } - j.write_fieldname("groupBasedBeamReporting"); - group_based_beam_report.to_json(j); - if (cqi_table_present) { - j.write_str("cqi-Table", cqi_table.to_string()); - } - j.write_str("subbandSize", subband_size.to_string()); - if (non_pmi_port_ind_present) { - j.start_array("non-PMI-PortIndication"); - for (const auto& e1 : non_pmi_port_ind) { - e1.to_json(j); - } - j.end_array(); - } - if (ext) { - if (semi_persistent_on_pusch_v1530.is_present()) { - j.write_fieldname("semiPersistentOnPUSCH-v1530"); - j.start_obj(); - j.write_str("reportSlotConfig-v1530", semi_persistent_on_pusch_v1530->report_slot_cfg_v1530.to_string()); - j.end_obj(); - } - } - j.end_obj(); -} - -void csi_report_cfg_s::report_cfg_type_c_::destroy_() +void ul_ccch_msg_type_c::c1_c_::destroy_() { switch (type_) { - case types::periodic: - c.destroy(); + case types::rrc_setup_request: + c.destroy(); break; - case types::semi_persistent_on_pucch: - c.destroy(); + case types::rrc_resume_request: + c.destroy(); break; - case types::semi_persistent_on_pusch: - c.destroy(); + case types::rrc_reest_request: + c.destroy(); break; - case types::aperiodic: - c.destroy(); + case types::rrc_sys_info_request: + c.destroy(); break; default: break; } } -void csi_report_cfg_s::report_cfg_type_c_::set(types::options e) +void ul_ccch_msg_type_c::c1_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::periodic: - c.init(); + case types::rrc_setup_request: + c.init(); break; - case types::semi_persistent_on_pucch: - c.init(); + case types::rrc_resume_request: + c.init(); break; - case types::semi_persistent_on_pusch: - c.init(); + case types::rrc_reest_request: + c.init(); break; - case types::aperiodic: - c.init(); + case types::rrc_sys_info_request: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); } } -csi_report_cfg_s::report_cfg_type_c_::report_cfg_type_c_(const csi_report_cfg_s::report_cfg_type_c_& other) +ul_ccch_msg_type_c::c1_c_::c1_c_(const ul_ccch_msg_type_c::c1_c_& other) { type_ = other.type(); switch (type_) { - case types::periodic: - c.init(other.c.get()); + case types::rrc_setup_request: + c.init(other.c.get()); break; - case types::semi_persistent_on_pucch: - c.init(other.c.get()); + case types::rrc_resume_request: + c.init(other.c.get()); break; - case types::semi_persistent_on_pusch: - c.init(other.c.get()); + case types::rrc_reest_request: + c.init(other.c.get()); break; - case types::aperiodic: - c.init(other.c.get()); + case types::rrc_sys_info_request: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); } } -csi_report_cfg_s::report_cfg_type_c_& csi_report_cfg_s::report_cfg_type_c_:: - operator=(const csi_report_cfg_s::report_cfg_type_c_& other) +ul_ccch_msg_type_c::c1_c_& ul_ccch_msg_type_c::c1_c_::operator=(const ul_ccch_msg_type_c::c1_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::periodic: - c.set(other.c.get()); + case types::rrc_setup_request: + c.set(other.c.get()); break; - case types::semi_persistent_on_pucch: - c.set(other.c.get()); + case types::rrc_resume_request: + c.set(other.c.get()); break; - case types::semi_persistent_on_pusch: - c.set(other.c.get()); + case types::rrc_reest_request: + c.set(other.c.get()); break; - case types::aperiodic: - c.set(other.c.get()); + case types::rrc_sys_info_request: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); } return *this; } -void csi_report_cfg_s::report_cfg_type_c_::to_json(json_writer& j) const +void ul_ccch_msg_type_c::c1_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::periodic: - j.write_fieldname("periodic"); - j.start_obj(); - j.write_fieldname("reportSlotConfig"); - c.get().report_slot_cfg.to_json(j); - j.start_array("pucch-CSI-ResourceList"); - for (const auto& e1 : c.get().pucch_csi_res_list) { - e1.to_json(j); - } - j.end_array(); - j.end_obj(); + case types::rrc_setup_request: + j.write_fieldname("rrcSetupRequest"); + c.get().to_json(j); break; - case types::semi_persistent_on_pucch: - j.write_fieldname("semiPersistentOnPUCCH"); - j.start_obj(); - j.write_fieldname("reportSlotConfig"); - c.get().report_slot_cfg.to_json(j); - j.start_array("pucch-CSI-ResourceList"); - for (const auto& e1 : c.get().pucch_csi_res_list) { - e1.to_json(j); - } - j.end_array(); - j.end_obj(); + case types::rrc_resume_request: + j.write_fieldname("rrcResumeRequest"); + c.get().to_json(j); break; - case types::semi_persistent_on_pusch: - j.write_fieldname("semiPersistentOnPUSCH"); - j.start_obj(); - j.write_str("reportSlotConfig", c.get().report_slot_cfg.to_string()); - j.start_array("reportSlotOffsetList"); - for (const auto& e1 : c.get().report_slot_offset_list) { - j.write_int(e1); - } - j.end_array(); - j.write_int("p0alpha", c.get().p0alpha); - j.end_obj(); + case types::rrc_reest_request: + j.write_fieldname("rrcReestablishmentRequest"); + c.get().to_json(j); break; - case types::aperiodic: - j.write_fieldname("aperiodic"); - j.start_obj(); - j.start_array("reportSlotOffsetList"); - for (const auto& e1 : c.get().report_slot_offset_list) { - j.write_int(e1); - } - j.end_array(); - j.end_obj(); + case types::rrc_sys_info_request: + j.write_fieldname("rrcSystemInfoRequest"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); } j.end_obj(); } -SRSASN_CODE csi_report_cfg_s::report_cfg_type_c_::pack(bit_ref& bref) const +SRSASN_CODE ul_ccch_msg_type_c::c1_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::periodic: - HANDLE_CODE(c.get().report_slot_cfg.pack(bref)); - HANDLE_CODE(pack_dyn_seq_of(bref, c.get().pucch_csi_res_list, 1, 4)); + case types::rrc_setup_request: + HANDLE_CODE(c.get().pack(bref)); break; - case types::semi_persistent_on_pucch: - HANDLE_CODE(c.get().report_slot_cfg.pack(bref)); - HANDLE_CODE(pack_dyn_seq_of(bref, c.get().pucch_csi_res_list, 1, 4)); + case types::rrc_resume_request: + HANDLE_CODE(c.get().pack(bref)); break; - case types::semi_persistent_on_pusch: - HANDLE_CODE(c.get().report_slot_cfg.pack(bref)); - HANDLE_CODE(pack_dyn_seq_of( - bref, c.get().report_slot_offset_list, 1, 16, integer_packer(0, 32))); - HANDLE_CODE(pack_integer(bref, c.get().p0alpha, (uint8_t)0u, (uint8_t)29u)); + case types::rrc_reest_request: + HANDLE_CODE(c.get().pack(bref)); break; - case types::aperiodic: - HANDLE_CODE( - pack_dyn_seq_of(bref, c.get().report_slot_offset_list, 1, 16, integer_packer(0, 32))); + case types::rrc_sys_info_request: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_report_cfg_s::report_cfg_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE ul_ccch_msg_type_c::c1_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::periodic: - HANDLE_CODE(c.get().report_slot_cfg.unpack(bref)); - HANDLE_CODE(unpack_dyn_seq_of(c.get().pucch_csi_res_list, bref, 1, 4)); + case types::rrc_setup_request: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::semi_persistent_on_pucch: - HANDLE_CODE(c.get().report_slot_cfg.unpack(bref)); - HANDLE_CODE(unpack_dyn_seq_of(c.get().pucch_csi_res_list, bref, 1, 4)); + case types::rrc_resume_request: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::semi_persistent_on_pusch: - HANDLE_CODE(c.get().report_slot_cfg.unpack(bref)); - HANDLE_CODE(unpack_dyn_seq_of( - c.get().report_slot_offset_list, bref, 1, 16, integer_packer(0, 32))); - HANDLE_CODE(unpack_integer(c.get().p0alpha, bref, (uint8_t)0u, (uint8_t)29u)); + case types::rrc_reest_request: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::aperiodic: - HANDLE_CODE(unpack_dyn_seq_of( - c.get().report_slot_offset_list, bref, 1, 16, integer_packer(0, 32))); + case types::rrc_sys_info_request: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); + log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_opts::to_string() const +std::string ul_ccch_msg_type_c::c1_c_::types_opts::to_string() const { - static const char* options[] = {"sl5", "sl10", "sl20", "sl40", "sl80", "sl160", "sl320"}; - return convert_enum_idx( - options, 7, value, "csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_e_"); + static const char* options[] = { + "rrcSetupRequest", "rrcResumeRequest", "rrcReestablishmentRequest", "rrcSystemInfoRequest"}; + return convert_enum_idx(options, 4, value, "ul_ccch_msg_type_c::c1_c_::types"); } -uint16_t csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_opts::to_number() const + +std::string ul_ccch_msg_type_c::types_opts::to_string() const { - static const uint16_t options[] = {5, 10, 20, 40, 80, 160, 320}; - return map_enum_number( - options, 7, value, "csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_e_"); + static const char* options[] = {"c1", "messageClassExtension"}; + return convert_enum_idx(options, 2, value, "ul_ccch_msg_type_c::types"); } - -std::string csi_report_cfg_s::report_cfg_type_c_::types_opts::to_string() const +uint8_t ul_ccch_msg_type_c::types_opts::to_number() const { - static const char* options[] = {"periodic", "semiPersistentOnPUCCH", "semiPersistentOnPUSCH", "aperiodic"}; - return convert_enum_idx(options, 4, value, "csi_report_cfg_s::report_cfg_type_c_::types"); + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "ul_ccch_msg_type_c::types"); } -void csi_report_cfg_s::report_quant_c_::set(types::options e) +// UL-CCCH-Message ::= SEQUENCE +SRSASN_CODE ul_ccch_msg_s::pack(bit_ref& bref) const { - type_ = e; + HANDLE_CODE(msg.pack(bref)); + + bref.align_bytes_zero(); + + return SRSASN_SUCCESS; } -void csi_report_cfg_s::report_quant_c_::to_json(json_writer& j) const +SRSASN_CODE ul_ccch_msg_s::unpack(cbit_ref& bref) { - j.start_obj(); - switch (type_) { - case types::none: - break; - case types::cri_ri_pmi_cqi: - break; - case types::cri_ri_i1: - break; - case types::cri_ri_i1_cqi: - j.write_fieldname("cri-RI-i1-CQI"); - j.start_obj(); - if (c.pdsch_bundle_size_for_csi_present) { - j.write_str("pdsch-BundleSizeForCSI", c.pdsch_bundle_size_for_csi.to_string()); - } - j.end_obj(); - break; - case types::cri_ri_cqi: - break; - case types::cri_rsrp: - break; - case types::ssb_idx_rsrp: - break; - case types::cri_ri_li_pmi_cqi: - break; - default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_quant_c_"); - } - j.end_obj(); -} -SRSASN_CODE csi_report_cfg_s::report_quant_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::none: - break; - case types::cri_ri_pmi_cqi: - break; - case types::cri_ri_i1: - break; - case types::cri_ri_i1_cqi: - HANDLE_CODE(bref.pack(c.pdsch_bundle_size_for_csi_present, 1)); - if (c.pdsch_bundle_size_for_csi_present) { - HANDLE_CODE(c.pdsch_bundle_size_for_csi.pack(bref)); - } - break; - case types::cri_ri_cqi: - break; - case types::cri_rsrp: - break; - case types::ssb_idx_rsrp: - break; - case types::cri_ri_li_pmi_cqi: - break; - default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_quant_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } + HANDLE_CODE(msg.unpack(bref)); + + bref.align_bytes(); + return SRSASN_SUCCESS; } -SRSASN_CODE csi_report_cfg_s::report_quant_c_::unpack(cbit_ref& bref) +void ul_ccch_msg_s::to_json(json_writer& j) const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::none: - break; - case types::cri_ri_pmi_cqi: - break; - case types::cri_ri_i1: - break; - case types::cri_ri_i1_cqi: - HANDLE_CODE(bref.unpack(c.pdsch_bundle_size_for_csi_present, 1)); - if (c.pdsch_bundle_size_for_csi_present) { - HANDLE_CODE(c.pdsch_bundle_size_for_csi.unpack(bref)); - } - break; - case types::cri_ri_cqi: - break; - case types::cri_rsrp: - break; - case types::ssb_idx_rsrp: - break; - case types::cri_ri_li_pmi_cqi: - break; - default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_quant_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + j.start_array(); + j.start_obj(); + j.start_obj("UL-CCCH-Message"); + j.write_fieldname("message"); + msg.to_json(j); + j.end_obj(); + j.end_obj(); + j.end_array(); } -std::string csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_opts::to_string() const +// RRCResumeRequest1-IEs ::= SEQUENCE +SRSASN_CODE rrc_resume_request1_ies_s::pack(bit_ref& bref) const { - static const char* options[] = {"n2", "n4"}; - return convert_enum_idx( - options, 2, value, "csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_e_"); + HANDLE_CODE(resume_id.pack(bref)); + HANDLE_CODE(resume_mac_i.pack(bref)); + HANDLE_CODE(resume_cause.pack(bref)); + HANDLE_CODE(spare.pack(bref)); + + return SRSASN_SUCCESS; } -uint8_t csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_opts::to_number() const +SRSASN_CODE rrc_resume_request1_ies_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {2, 4}; - return map_enum_number( - options, 2, value, "csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_e_"); -} + HANDLE_CODE(resume_id.unpack(bref)); + HANDLE_CODE(resume_mac_i.unpack(bref)); + HANDLE_CODE(resume_cause.unpack(bref)); + HANDLE_CODE(spare.unpack(bref)); -std::string csi_report_cfg_s::report_quant_c_::types_opts::to_string() const + return SRSASN_SUCCESS; +} +void rrc_resume_request1_ies_s::to_json(json_writer& j) const { - static const char* options[] = {"none", - "cri-RI-PMI-CQI", - "cri-RI-i1", - "cri-RI-i1-CQI", - "cri-RI-CQI", - "cri-RSRP", - "ssb-Index-RSRP", - "cri-RI-LI-PMI-CQI"}; - return convert_enum_idx(options, 8, value, "csi_report_cfg_s::report_quant_c_::types"); + j.start_obj(); + j.write_str("resumeIdentity", resume_id.to_string()); + j.write_str("resumeMAC-I", resume_mac_i.to_string()); + j.write_str("resumeCause", resume_cause.to_string()); + j.write_str("spare", spare.to_string()); + j.end_obj(); } -std::string csi_report_cfg_s::report_freq_cfg_s_::cqi_format_ind_opts::to_string() const +// RRCResumeRequest1 ::= SEQUENCE +SRSASN_CODE rrc_resume_request1_s::pack(bit_ref& bref) const { - static const char* options[] = {"widebandCQI", "subbandCQI"}; - return convert_enum_idx(options, 2, value, "csi_report_cfg_s::report_freq_cfg_s_::cqi_format_ind_e_"); + HANDLE_CODE(rrc_resume_request1.pack(bref)); + + return SRSASN_SUCCESS; } +SRSASN_CODE rrc_resume_request1_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(rrc_resume_request1.unpack(bref)); -std::string csi_report_cfg_s::report_freq_cfg_s_::pmi_format_ind_opts::to_string() const + return SRSASN_SUCCESS; +} +void rrc_resume_request1_s::to_json(json_writer& j) const { - static const char* options[] = {"widebandPMI", "subbandPMI"}; - return convert_enum_idx(options, 2, value, "csi_report_cfg_s::report_freq_cfg_s_::pmi_format_ind_e_"); + j.start_obj(); + j.write_fieldname("rrcResumeRequest1"); + rrc_resume_request1.to_json(j); + j.end_obj(); } -void csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::destroy_() +// UL-CCCH1-MessageType ::= CHOICE +void ul_ccch1_msg_type_c::destroy_() { switch (type_) { - case types::subbands3: - c.destroy >(); - break; - case types::subbands4: - c.destroy >(); - break; - case types::subbands5: - c.destroy >(); - break; - case types::subbands6: - c.destroy >(); - break; - case types::subbands7: - c.destroy >(); - break; - case types::subbands8: - c.destroy >(); - break; - case types::subbands9: - c.destroy >(); - break; - case types::subbands10: - c.destroy >(); - break; - case types::subbands11: - c.destroy >(); - break; - case types::subbands12: - c.destroy >(); - break; - case types::subbands13: - c.destroy >(); - break; - case types::subbands14: - c.destroy >(); - break; - case types::subbands15: - c.destroy >(); - break; - case types::subbands16: - c.destroy >(); - break; - case types::subbands17: - c.destroy >(); - break; - case types::subbands18: - c.destroy >(); - break; - case types::subbands19_v1530: - c.destroy >(); + case types::c1: + c.destroy(); break; default: break; } } -void csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::set(types::options e) +void ul_ccch1_msg_type_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::subbands3: - c.init >(); - break; - case types::subbands4: - c.init >(); - break; - case types::subbands5: - c.init >(); - break; - case types::subbands6: - c.init >(); - break; - case types::subbands7: - c.init >(); - break; - case types::subbands8: - c.init >(); - break; - case types::subbands9: - c.init >(); - break; - case types::subbands10: - c.init >(); - break; - case types::subbands11: - c.init >(); - break; - case types::subbands12: - c.init >(); - break; - case types::subbands13: - c.init >(); - break; - case types::subbands14: - c.init >(); - break; - case types::subbands15: - c.init >(); - break; - case types::subbands16: - c.init >(); - break; - case types::subbands17: - c.init >(); - break; - case types::subbands18: - c.init >(); + case types::c1: + c.init(); break; - case types::subbands19_v1530: - c.init >(); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); } } -csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::csi_report_band_c_( - const csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_& other) +ul_ccch1_msg_type_c::ul_ccch1_msg_type_c(const ul_ccch1_msg_type_c& other) { type_ = other.type(); switch (type_) { - case types::subbands3: - c.init(other.c.get >()); - break; - case types::subbands4: - c.init(other.c.get >()); - break; - case types::subbands5: - c.init(other.c.get >()); - break; - case types::subbands6: - c.init(other.c.get >()); - break; - case types::subbands7: - c.init(other.c.get >()); - break; - case types::subbands8: - c.init(other.c.get >()); - break; - case types::subbands9: - c.init(other.c.get >()); - break; - case types::subbands10: - c.init(other.c.get >()); - break; - case types::subbands11: - c.init(other.c.get >()); - break; - case types::subbands12: - c.init(other.c.get >()); - break; - case types::subbands13: - c.init(other.c.get >()); - break; - case types::subbands14: - c.init(other.c.get >()); - break; - case types::subbands15: - c.init(other.c.get >()); - break; - case types::subbands16: - c.init(other.c.get >()); - break; - case types::subbands17: - c.init(other.c.get >()); - break; - case types::subbands18: - c.init(other.c.get >()); + case types::c1: + c.init(other.c.get()); break; - case types::subbands19_v1530: - c.init(other.c.get >()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); } } -csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_& csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_:: - operator=(const csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_& other) +ul_ccch1_msg_type_c& ul_ccch1_msg_type_c::operator=(const ul_ccch1_msg_type_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::subbands3: - c.set(other.c.get >()); - break; - case types::subbands4: - c.set(other.c.get >()); - break; - case types::subbands5: - c.set(other.c.get >()); - break; - case types::subbands6: - c.set(other.c.get >()); - break; - case types::subbands7: - c.set(other.c.get >()); - break; - case types::subbands8: - c.set(other.c.get >()); - break; - case types::subbands9: - c.set(other.c.get >()); - break; - case types::subbands10: - c.set(other.c.get >()); - break; - case types::subbands11: - c.set(other.c.get >()); - break; - case types::subbands12: - c.set(other.c.get >()); - break; - case types::subbands13: - c.set(other.c.get >()); - break; - case types::subbands14: - c.set(other.c.get >()); - break; - case types::subbands15: - c.set(other.c.get >()); - break; - case types::subbands16: - c.set(other.c.get >()); - break; - case types::subbands17: - c.set(other.c.get >()); - break; - case types::subbands18: - c.set(other.c.get >()); + case types::c1: + c.set(other.c.get()); break; - case types::subbands19_v1530: - c.set(other.c.get >()); + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); } return *this; } -void csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::to_json(json_writer& j) const +void ul_ccch1_msg_type_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::subbands3: - j.write_str("subbands3", c.get >().to_string()); - break; - case types::subbands4: - j.write_str("subbands4", c.get >().to_string()); - break; - case types::subbands5: - j.write_str("subbands5", c.get >().to_string()); - break; - case types::subbands6: - j.write_str("subbands6", c.get >().to_string()); - break; - case types::subbands7: - j.write_str("subbands7", c.get >().to_string()); - break; - case types::subbands8: - j.write_str("subbands8", c.get >().to_string()); - break; - case types::subbands9: - j.write_str("subbands9", c.get >().to_string()); - break; - case types::subbands10: - j.write_str("subbands10", c.get >().to_string()); - break; - case types::subbands11: - j.write_str("subbands11", c.get >().to_string()); - break; - case types::subbands12: - j.write_str("subbands12", c.get >().to_string()); - break; - case types::subbands13: - j.write_str("subbands13", c.get >().to_string()); - break; - case types::subbands14: - j.write_str("subbands14", c.get >().to_string()); - break; - case types::subbands15: - j.write_str("subbands15", c.get >().to_string()); - break; - case types::subbands16: - j.write_str("subbands16", c.get >().to_string()); - break; - case types::subbands17: - j.write_str("subbands17", c.get >().to_string()); - break; - case types::subbands18: - j.write_str("subbands18", c.get >().to_string()); + case types::c1: + j.write_fieldname("c1"); + c.get().to_json(j); break; - case types::subbands19_v1530: - j.write_str("subbands19-v1530", c.get >().to_string()); + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); } j.end_obj(); } -SRSASN_CODE csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::pack(bit_ref& bref) const +SRSASN_CODE ul_ccch1_msg_type_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::subbands3: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands4: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands5: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands6: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands7: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands8: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands9: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands10: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands11: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands12: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands13: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands14: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands15: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands16: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::subbands17: - HANDLE_CODE(c.get >().pack(bref)); + case types::c1: + HANDLE_CODE(c.get().pack(bref)); break; - case types::subbands18: - HANDLE_CODE(c.get >().pack(bref)); + case types::msg_class_ext: break; - case types::subbands19_v1530: { - varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get >().pack(bref)); - } break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::unpack(cbit_ref& bref) +SRSASN_CODE ul_ccch1_msg_type_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::subbands3: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands4: - HANDLE_CODE(c.get >().unpack(bref)); + case types::c1: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::subbands5: - HANDLE_CODE(c.get >().unpack(bref)); + case types::msg_class_ext: break; - case types::subbands6: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands7: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands8: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands9: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands10: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands11: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands12: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands13: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands14: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands15: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands16: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands17: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands18: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::subbands19_v1530: { - varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get >().unpack(bref)); - } break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types_opts::to_string() const -{ - static const char* options[] = {"subbands3", - "subbands4", - "subbands5", - "subbands6", - "subbands7", - "subbands8", - "subbands9", - "subbands10", - "subbands11", - "subbands12", - "subbands13", - "subbands14", - "subbands15", - "subbands16", - "subbands17", - "subbands18", - "subbands19-v1530"}; - return convert_enum_idx(options, 17, value, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types"); -} -uint8_t csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19}; - return map_enum_number(options, 17, value, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types"); -} - -std::string csi_report_cfg_s::time_restrict_for_ch_meass_opts::to_string() const -{ - static const char* options[] = {"configured", "notConfigured"}; - return convert_enum_idx(options, 2, value, "csi_report_cfg_s::time_restrict_for_ch_meass_e_"); -} - -std::string csi_report_cfg_s::time_restrict_for_interference_meass_opts::to_string() const -{ - static const char* options[] = {"configured", "notConfigured"}; - return convert_enum_idx(options, 2, value, "csi_report_cfg_s::time_restrict_for_interference_meass_e_"); -} - -std::string csi_report_cfg_s::dummy_opts::to_string() const -{ - static const char* options[] = {"n1", "n2"}; - return convert_enum_idx(options, 2, value, "csi_report_cfg_s::dummy_e_"); -} -uint8_t csi_report_cfg_s::dummy_opts::to_number() const -{ - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "csi_report_cfg_s::dummy_e_"); -} - -void csi_report_cfg_s::group_based_beam_report_c_::set(types::options e) +void ul_ccch1_msg_type_c::c1_c_::set(types::options e) { type_ = e; } -void csi_report_cfg_s::group_based_beam_report_c_::to_json(json_writer& j) const +void ul_ccch1_msg_type_c::c1_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::enabled: + case types::rrc_resume_request1: + j.write_fieldname("rrcResumeRequest1"); + c.to_json(j); break; - case types::disabled: - j.write_fieldname("disabled"); - j.start_obj(); - if (c.nrof_reported_rs_present) { - j.write_str("nrofReportedRS", c.nrof_reported_rs.to_string()); - } - j.end_obj(); + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::group_based_beam_report_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c::c1_c_"); } j.end_obj(); } -SRSASN_CODE csi_report_cfg_s::group_based_beam_report_c_::pack(bit_ref& bref) const +SRSASN_CODE ul_ccch1_msg_type_c::c1_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::enabled: + case types::rrc_resume_request1: + HANDLE_CODE(c.pack(bref)); break; - case types::disabled: - HANDLE_CODE(bref.pack(c.nrof_reported_rs_present, 1)); - if (c.nrof_reported_rs_present) { - HANDLE_CODE(c.nrof_reported_rs.pack(bref)); - } + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::group_based_beam_report_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c::c1_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_report_cfg_s::group_based_beam_report_c_::unpack(cbit_ref& bref) +SRSASN_CODE ul_ccch1_msg_type_c::c1_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::enabled: + case types::rrc_resume_request1: + HANDLE_CODE(c.unpack(bref)); break; - case types::disabled: - HANDLE_CODE(bref.unpack(c.nrof_reported_rs_present, 1)); - if (c.nrof_reported_rs_present) { - HANDLE_CODE(c.nrof_reported_rs.unpack(bref)); - } + case types::spare3: + break; + case types::spare2: + break; + case types::spare1: break; default: - log_invalid_choice_id(type_, "csi_report_cfg_s::group_based_beam_report_c_"); + log_invalid_choice_id(type_, "ul_ccch1_msg_type_c::c1_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n3", "n4"}; - return convert_enum_idx( - options, 4, value, "csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_e_"); -} -uint8_t csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_opts::to_number() const +std::string ul_ccch1_msg_type_c::c1_c_::types_opts::to_string() const { - static const uint8_t options[] = {1, 2, 3, 4}; - return map_enum_number( - options, 4, value, "csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_e_"); + static const char* options[] = {"rrcResumeRequest1", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 4, value, "ul_ccch1_msg_type_c::c1_c_::types"); } - -std::string csi_report_cfg_s::group_based_beam_report_c_::types_opts::to_string() const +uint8_t ul_ccch1_msg_type_c::c1_c_::types_opts::to_number() const { - static const char* options[] = {"enabled", "disabled"}; - return convert_enum_idx(options, 2, value, "csi_report_cfg_s::group_based_beam_report_c_::types"); + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "ul_ccch1_msg_type_c::c1_c_::types"); } -std::string csi_report_cfg_s::cqi_table_opts::to_string() const +std::string ul_ccch1_msg_type_c::types_opts::to_string() const { - static const char* options[] = {"table1", "table2", "table3", "spare1"}; - return convert_enum_idx(options, 4, value, "csi_report_cfg_s::cqi_table_e_"); + static const char* options[] = {"c1", "messageClassExtension"}; + return convert_enum_idx(options, 2, value, "ul_ccch1_msg_type_c::types"); } -uint8_t csi_report_cfg_s::cqi_table_opts::to_number() const +uint8_t ul_ccch1_msg_type_c::types_opts::to_number() const { - static const uint8_t options[] = {1, 2, 3}; - return map_enum_number(options, 3, value, "csi_report_cfg_s::cqi_table_e_"); + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "ul_ccch1_msg_type_c::types"); } -std::string csi_report_cfg_s::subband_size_opts::to_string() const +// UL-CCCH1-Message ::= SEQUENCE +SRSASN_CODE ul_ccch1_msg_s::pack(bit_ref& bref) const { - static const char* options[] = {"value1", "value2"}; - return convert_enum_idx(options, 2, value, "csi_report_cfg_s::subband_size_e_"); + HANDLE_CODE(msg.pack(bref)); + + bref.align_bytes_zero(); + + return SRSASN_SUCCESS; } -uint8_t csi_report_cfg_s::subband_size_opts::to_number() const +SRSASN_CODE ul_ccch1_msg_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "csi_report_cfg_s::subband_size_e_"); -} + HANDLE_CODE(msg.unpack(bref)); -std::string csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_opts::to_string() const -{ - static const char* options[] = {"sl4", "sl8", "sl16"}; - return convert_enum_idx( - options, 3, value, "csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_e_"); + bref.align_bytes(); + + return SRSASN_SUCCESS; } -uint8_t csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_opts::to_number() const +void ul_ccch1_msg_s::to_json(json_writer& j) const { - static const uint8_t options[] = {4, 8, 16}; - return map_enum_number( - options, 3, value, "csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_e_"); + j.start_array(); + j.start_obj(); + j.start_obj("UL-CCCH1-Message"); + j.write_fieldname("message"); + msg.to_json(j); + j.end_obj(); + j.end_obj(); + j.end_array(); } -// CSI-ResourceConfig ::= SEQUENCE -SRSASN_CODE csi_res_cfg_s::pack(bit_ref& bref) const +// MeasQuantityResults ::= SEQUENCE +SRSASN_CODE meas_quant_results_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, csi_res_cfg_id, (uint8_t)0u, (uint8_t)111u)); - HANDLE_CODE(csi_rs_res_set_list.pack(bref)); - HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(res_type.pack(bref)); + HANDLE_CODE(bref.pack(rsrp_present, 1)); + HANDLE_CODE(bref.pack(rsrq_present, 1)); + HANDLE_CODE(bref.pack(sinr_present, 1)); + + if (rsrp_present) { + HANDLE_CODE(pack_integer(bref, rsrp, (uint8_t)0u, (uint8_t)127u)); + } + if (rsrq_present) { + HANDLE_CODE(pack_integer(bref, rsrq, (uint8_t)0u, (uint8_t)127u)); + } + if (sinr_present) { + HANDLE_CODE(pack_integer(bref, sinr, (uint8_t)0u, (uint8_t)127u)); + } return SRSASN_SUCCESS; } -SRSASN_CODE csi_res_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_quant_results_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(csi_res_cfg_id, bref, (uint8_t)0u, (uint8_t)111u)); - HANDLE_CODE(csi_rs_res_set_list.unpack(bref)); - HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(res_type.unpack(bref)); + HANDLE_CODE(bref.unpack(rsrp_present, 1)); + HANDLE_CODE(bref.unpack(rsrq_present, 1)); + HANDLE_CODE(bref.unpack(sinr_present, 1)); + + if (rsrp_present) { + HANDLE_CODE(unpack_integer(rsrp, bref, (uint8_t)0u, (uint8_t)127u)); + } + if (rsrq_present) { + HANDLE_CODE(unpack_integer(rsrq, bref, (uint8_t)0u, (uint8_t)127u)); + } + if (sinr_present) { + HANDLE_CODE(unpack_integer(sinr, bref, (uint8_t)0u, (uint8_t)127u)); + } return SRSASN_SUCCESS; } -void csi_res_cfg_s::to_json(json_writer& j) const +void meas_quant_results_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("csi-ResourceConfigId", csi_res_cfg_id); - j.write_fieldname("csi-RS-ResourceSetList"); - csi_rs_res_set_list.to_json(j); - j.write_int("bwp-Id", bwp_id); - j.write_str("resourceType", res_type.to_string()); + if (rsrp_present) { + j.write_int("rsrp", rsrp); + } + if (rsrq_present) { + j.write_int("rsrq", rsrq); + } + if (sinr_present) { + j.write_int("sinr", sinr); + } j.end_obj(); } -void csi_res_cfg_s::csi_rs_res_set_list_c_::destroy_() +// PLMN-Identity-EUTRA-5GC ::= CHOICE +void plmn_id_eutra_minus5_gc_c::destroy_() { switch (type_) { - case types::nzp_csi_rs_ssb: - c.destroy(); - break; - case types::csi_im_res_set_list: - c.destroy(); + case types::plmn_id_eutra_minus5_gc: + c.destroy(); break; default: break; } } -void csi_res_cfg_s::csi_rs_res_set_list_c_::set(types::options e) +void plmn_id_eutra_minus5_gc_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::nzp_csi_rs_ssb: - c.init(); + case types::plmn_id_eutra_minus5_gc: + c.init(); break; - case types::csi_im_res_set_list: - c.init(); + case types::plmn_idx: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); + log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); } } -csi_res_cfg_s::csi_rs_res_set_list_c_::csi_rs_res_set_list_c_(const csi_res_cfg_s::csi_rs_res_set_list_c_& other) +plmn_id_eutra_minus5_gc_c::plmn_id_eutra_minus5_gc_c(const plmn_id_eutra_minus5_gc_c& other) { type_ = other.type(); switch (type_) { - case types::nzp_csi_rs_ssb: - c.init(other.c.get()); + case types::plmn_id_eutra_minus5_gc: + c.init(other.c.get()); break; - case types::csi_im_res_set_list: - c.init(other.c.get()); + case types::plmn_idx: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); + log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); } } -csi_res_cfg_s::csi_rs_res_set_list_c_& csi_res_cfg_s::csi_rs_res_set_list_c_:: - operator=(const csi_res_cfg_s::csi_rs_res_set_list_c_& other) +plmn_id_eutra_minus5_gc_c& plmn_id_eutra_minus5_gc_c::operator=(const plmn_id_eutra_minus5_gc_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::nzp_csi_rs_ssb: - c.set(other.c.get()); + case types::plmn_id_eutra_minus5_gc: + c.set(other.c.get()); break; - case types::csi_im_res_set_list: - c.set(other.c.get()); + case types::plmn_idx: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); + log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); } return *this; } -void csi_res_cfg_s::csi_rs_res_set_list_c_::to_json(json_writer& j) const +void plmn_id_eutra_minus5_gc_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::nzp_csi_rs_ssb: - j.write_fieldname("nzp-CSI-RS-SSB"); - j.start_obj(); - if (c.get().nzp_csi_rs_res_set_list_present) { - j.start_array("nzp-CSI-RS-ResourceSetList"); - for (const auto& e1 : c.get().nzp_csi_rs_res_set_list) { - j.write_int(e1); - } - j.end_array(); - } - if (c.get().csi_ssb_res_set_list_present) { - j.start_array("csi-SSB-ResourceSetList"); - for (const auto& e1 : c.get().csi_ssb_res_set_list) { - j.write_int(e1); - } - j.end_array(); - } - j.end_obj(); + case types::plmn_id_eutra_minus5_gc: + j.write_fieldname("plmn-Identity-EUTRA-5GC"); + c.get().to_json(j); break; - case types::csi_im_res_set_list: - j.start_array("csi-IM-ResourceSetList"); - for (const auto& e1 : c.get()) { - j.write_int(e1); - } - j.end_array(); + case types::plmn_idx: + j.write_int("plmn-index", c.get()); break; default: - log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); + log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); } j.end_obj(); } -SRSASN_CODE csi_res_cfg_s::csi_rs_res_set_list_c_::pack(bit_ref& bref) const +SRSASN_CODE plmn_id_eutra_minus5_gc_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::nzp_csi_rs_ssb: - HANDLE_CODE(bref.pack(c.get().nzp_csi_rs_res_set_list_present, 1)); - HANDLE_CODE(bref.pack(c.get().csi_ssb_res_set_list_present, 1)); - if (c.get().nzp_csi_rs_res_set_list_present) { - HANDLE_CODE(pack_dyn_seq_of( - bref, c.get().nzp_csi_rs_res_set_list, 1, 16, integer_packer(0, 63))); - } - if (c.get().csi_ssb_res_set_list_present) { - HANDLE_CODE(pack_fixed_seq_of(bref, - &(c.get().csi_ssb_res_set_list)[0], - c.get().csi_ssb_res_set_list.size(), - integer_packer(0, 63))); - } + case types::plmn_id_eutra_minus5_gc: + HANDLE_CODE(c.get().pack(bref)); break; - case types::csi_im_res_set_list: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 16, integer_packer(0, 63))); + case types::plmn_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)12u)); break; default: - log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); + log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_res_cfg_s::csi_rs_res_set_list_c_::unpack(cbit_ref& bref) +SRSASN_CODE plmn_id_eutra_minus5_gc_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::nzp_csi_rs_ssb: - HANDLE_CODE(bref.unpack(c.get().nzp_csi_rs_res_set_list_present, 1)); - HANDLE_CODE(bref.unpack(c.get().csi_ssb_res_set_list_present, 1)); - if (c.get().nzp_csi_rs_res_set_list_present) { - HANDLE_CODE(unpack_dyn_seq_of( - c.get().nzp_csi_rs_res_set_list, bref, 1, 16, integer_packer(0, 63))); - } - if (c.get().csi_ssb_res_set_list_present) { - HANDLE_CODE(unpack_fixed_seq_of(&(c.get().csi_ssb_res_set_list)[0], - bref, - c.get().csi_ssb_res_set_list.size(), - integer_packer(0, 63))); - } + case types::plmn_id_eutra_minus5_gc: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::csi_im_res_set_list: - HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 16, integer_packer(0, 63))); + case types::plmn_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)12u)); break; default: - log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); + log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_res_cfg_s::csi_rs_res_set_list_c_::types_opts::to_string() const +std::string plmn_id_eutra_minus5_gc_c::types_opts::to_string() const { - static const char* options[] = {"nzp-CSI-RS-SSB", "csi-IM-ResourceSetList"}; - return convert_enum_idx(options, 2, value, "csi_res_cfg_s::csi_rs_res_set_list_c_::types"); + static const char* options[] = {"plmn-Identity-EUTRA-5GC", "plmn-index"}; + return convert_enum_idx(options, 2, value, "plmn_id_eutra_minus5_gc_c::types"); } - -std::string csi_res_cfg_s::res_type_opts::to_string() const +int8_t plmn_id_eutra_minus5_gc_c::types_opts::to_number() const { - static const char* options[] = {"aperiodic", "semiPersistent", "periodic"}; - return convert_enum_idx(options, 3, value, "csi_res_cfg_s::res_type_e_"); + static const int8_t options[] = {-5}; + return map_enum_number(options, 1, value, "plmn_id_eutra_minus5_gc_c::types"); } -// CSI-SSB-ResourceSet ::= SEQUENCE -SRSASN_CODE csi_ssb_res_set_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, csi_ssb_res_set_id, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_dyn_seq_of(bref, csi_ssb_res_list, 1, 64, integer_packer(0, 63))); - - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_ssb_res_set_s::unpack(cbit_ref& bref) +// CellIdentity-EUTRA-5GC ::= CHOICE +void cell_id_eutra_minus5_gc_c::destroy_() { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(csi_ssb_res_set_id, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_dyn_seq_of(csi_ssb_res_list, bref, 1, 64, integer_packer(0, 63))); - - return SRSASN_SUCCESS; + switch (type_) { + case types::cell_id_eutra: + c.destroy >(); + break; + default: + break; + } } -void csi_ssb_res_set_s::to_json(json_writer& j) const +void cell_id_eutra_minus5_gc_c::set(types::options e) { - j.start_obj(); - j.write_int("csi-SSB-ResourceSetId", csi_ssb_res_set_id); - j.start_array("csi-SSB-ResourceList"); - for (const auto& e1 : csi_ssb_res_list) { - j.write_int(e1); + destroy_(); + type_ = e; + switch (type_) { + case types::cell_id_eutra: + c.init >(); + break; + case types::cell_id_idx: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); } - j.end_array(); - j.end_obj(); } - -// DownlinkConfigCommon ::= SEQUENCE -SRSASN_CODE dl_cfg_common_s::pack(bit_ref& bref) const +cell_id_eutra_minus5_gc_c::cell_id_eutra_minus5_gc_c(const cell_id_eutra_minus5_gc_c& other) { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(freq_info_dl_present, 1)); - HANDLE_CODE(bref.pack(init_dl_bwp_present, 1)); - - if (freq_info_dl_present) { - HANDLE_CODE(freq_info_dl.pack(bref)); - } - if (init_dl_bwp_present) { - HANDLE_CODE(init_dl_bwp.pack(bref)); + type_ = other.type(); + switch (type_) { + case types::cell_id_eutra: + c.init(other.c.get >()); + break; + case types::cell_id_idx: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); } - - return SRSASN_SUCCESS; } -SRSASN_CODE dl_cfg_common_s::unpack(cbit_ref& bref) +cell_id_eutra_minus5_gc_c& cell_id_eutra_minus5_gc_c::operator=(const cell_id_eutra_minus5_gc_c& other) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(freq_info_dl_present, 1)); - HANDLE_CODE(bref.unpack(init_dl_bwp_present, 1)); - - if (freq_info_dl_present) { - HANDLE_CODE(freq_info_dl.unpack(bref)); + if (this == &other) { + return *this; } - if (init_dl_bwp_present) { - HANDLE_CODE(init_dl_bwp.unpack(bref)); + set(other.type()); + switch (type_) { + case types::cell_id_eutra: + c.set(other.c.get >()); + break; + case types::cell_id_idx: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); } - return SRSASN_SUCCESS; + return *this; } -void dl_cfg_common_s::to_json(json_writer& j) const +void cell_id_eutra_minus5_gc_c::to_json(json_writer& j) const { j.start_obj(); - if (freq_info_dl_present) { - j.write_fieldname("frequencyInfoDL"); - freq_info_dl.to_json(j); - } - if (init_dl_bwp_present) { - j.write_fieldname("initialDownlinkBWP"); - init_dl_bwp.to_json(j); + switch (type_) { + case types::cell_id_eutra: + j.write_str("cellIdentity-EUTRA", c.get >().to_string()); + break; + case types::cell_id_idx: + j.write_int("cellId-index", c.get()); + break; + default: + log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); } j.end_obj(); } - -// NZP-CSI-RS-Resource ::= SEQUENCE -SRSASN_CODE nzp_csi_rs_res_s::pack(bit_ref& bref) const +SRSASN_CODE cell_id_eutra_minus5_gc_c::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(pwr_ctrl_offset_ss_present, 1)); - HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); - HANDLE_CODE(bref.pack(qcl_info_periodic_csi_rs_present, 1)); - - HANDLE_CODE(pack_integer(bref, nzp_csi_rs_res_id, (uint8_t)0u, (uint8_t)191u)); - HANDLE_CODE(res_map.pack(bref)); - HANDLE_CODE(pack_integer(bref, pwr_ctrl_offset, (int8_t)-8, (int8_t)15)); - if (pwr_ctrl_offset_ss_present) { - HANDLE_CODE(pwr_ctrl_offset_ss.pack(bref)); + type_.pack(bref); + switch (type_) { + case types::cell_id_eutra: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::cell_id_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)12u)); + break; + default: + log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); + return SRSASN_ERROR_ENCODE_FAIL; } - HANDLE_CODE(pack_integer(bref, scrambling_id, (uint16_t)0u, (uint16_t)1023u)); - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.pack(bref)); + return SRSASN_SUCCESS; +} +SRSASN_CODE cell_id_eutra_minus5_gc_c::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::cell_id_eutra: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::cell_id_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)12u)); + break; + default: + log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); + return SRSASN_ERROR_DECODE_FAIL; } - if (qcl_info_periodic_csi_rs_present) { - HANDLE_CODE(pack_integer(bref, qcl_info_periodic_csi_rs, (uint8_t)0u, (uint8_t)127u)); + return SRSASN_SUCCESS; +} + +std::string cell_id_eutra_minus5_gc_c::types_opts::to_string() const +{ + static const char* options[] = {"cellIdentity-EUTRA", "cellId-index"}; + return convert_enum_idx(options, 2, value, "cell_id_eutra_minus5_gc_c::types"); +} + +// ResultsPerCSI-RS-Index ::= SEQUENCE +SRSASN_CODE results_per_csi_rs_idx_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(csi_rs_results_present, 1)); + + HANDLE_CODE(pack_integer(bref, csi_rs_idx, (uint8_t)0u, (uint8_t)95u)); + if (csi_rs_results_present) { + HANDLE_CODE(csi_rs_results.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE nzp_csi_rs_res_s::unpack(cbit_ref& bref) +SRSASN_CODE results_per_csi_rs_idx_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(pwr_ctrl_offset_ss_present, 1)); - HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); - HANDLE_CODE(bref.unpack(qcl_info_periodic_csi_rs_present, 1)); + HANDLE_CODE(bref.unpack(csi_rs_results_present, 1)); - HANDLE_CODE(unpack_integer(nzp_csi_rs_res_id, bref, (uint8_t)0u, (uint8_t)191u)); - HANDLE_CODE(res_map.unpack(bref)); - HANDLE_CODE(unpack_integer(pwr_ctrl_offset, bref, (int8_t)-8, (int8_t)15)); - if (pwr_ctrl_offset_ss_present) { - HANDLE_CODE(pwr_ctrl_offset_ss.unpack(bref)); - } - HANDLE_CODE(unpack_integer(scrambling_id, bref, (uint16_t)0u, (uint16_t)1023u)); - if (periodicity_and_offset_present) { - HANDLE_CODE(periodicity_and_offset.unpack(bref)); - } - if (qcl_info_periodic_csi_rs_present) { - HANDLE_CODE(unpack_integer(qcl_info_periodic_csi_rs, bref, (uint8_t)0u, (uint8_t)127u)); + HANDLE_CODE(unpack_integer(csi_rs_idx, bref, (uint8_t)0u, (uint8_t)95u)); + if (csi_rs_results_present) { + HANDLE_CODE(csi_rs_results.unpack(bref)); } return SRSASN_SUCCESS; } -void nzp_csi_rs_res_s::to_json(json_writer& j) const +void results_per_csi_rs_idx_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("nzp-CSI-RS-ResourceId", nzp_csi_rs_res_id); - j.write_fieldname("resourceMapping"); - res_map.to_json(j); - j.write_int("powerControlOffset", pwr_ctrl_offset); - if (pwr_ctrl_offset_ss_present) { - j.write_str("powerControlOffsetSS", pwr_ctrl_offset_ss.to_string()); - } - j.write_int("scramblingID", scrambling_id); - if (periodicity_and_offset_present) { - j.write_fieldname("periodicityAndOffset"); - periodicity_and_offset.to_json(j); - } - if (qcl_info_periodic_csi_rs_present) { - j.write_int("qcl-InfoPeriodicCSI-RS", qcl_info_periodic_csi_rs); + j.write_int("csi-RS-Index", csi_rs_idx); + if (csi_rs_results_present) { + j.write_fieldname("csi-RS-Results"); + csi_rs_results.to_json(j); } j.end_obj(); } -std::string nzp_csi_rs_res_s::pwr_ctrl_offset_ss_opts::to_string() const +// ResultsPerSSB-Index ::= SEQUENCE +SRSASN_CODE results_per_ssb_idx_s::pack(bit_ref& bref) const { - static const char* options[] = {"db-3", "db0", "db3", "db6"}; - return convert_enum_idx(options, 4, value, "nzp_csi_rs_res_s::pwr_ctrl_offset_ss_e_"); + HANDLE_CODE(bref.pack(ssb_results_present, 1)); + + HANDLE_CODE(pack_integer(bref, ssb_idx, (uint8_t)0u, (uint8_t)63u)); + if (ssb_results_present) { + HANDLE_CODE(ssb_results.pack(bref)); + } + + return SRSASN_SUCCESS; } -int8_t nzp_csi_rs_res_s::pwr_ctrl_offset_ss_opts::to_number() const +SRSASN_CODE results_per_ssb_idx_s::unpack(cbit_ref& bref) { - static const int8_t options[] = {-3, 0, 3, 6}; - return map_enum_number(options, 4, value, "nzp_csi_rs_res_s::pwr_ctrl_offset_ss_e_"); + HANDLE_CODE(bref.unpack(ssb_results_present, 1)); + + HANDLE_CODE(unpack_integer(ssb_idx, bref, (uint8_t)0u, (uint8_t)63u)); + if (ssb_results_present) { + HANDLE_CODE(ssb_results.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void results_per_ssb_idx_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("ssb-Index", ssb_idx); + if (ssb_results_present) { + j.write_fieldname("ssb-Results"); + ssb_results.to_json(j); + } + j.end_obj(); } -// NZP-CSI-RS-ResourceSet ::= SEQUENCE -SRSASN_CODE nzp_csi_rs_res_set_s::pack(bit_ref& bref) const +// CGI-InfoNR ::= SEQUENCE +SRSASN_CODE cgi_info_nr_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(repeat_present, 1)); - HANDLE_CODE(bref.pack(aperiodic_trigger_offset_present, 1)); - HANDLE_CODE(bref.pack(trs_info_present, 1)); + HANDLE_CODE(bref.pack(plmn_id_info_list_present, 1)); + HANDLE_CODE(bref.pack(freq_band_list_present, 1)); + HANDLE_CODE(bref.pack(no_sib1_present, 1)); - HANDLE_CODE(pack_integer(bref, nzp_csi_res_set_id, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res, 1, 64, integer_packer(0, 191))); - if (repeat_present) { - HANDLE_CODE(repeat.pack(bref)); + if (plmn_id_info_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, plmn_id_info_list, 1, 12)); } - if (aperiodic_trigger_offset_present) { - HANDLE_CODE(pack_integer(bref, aperiodic_trigger_offset, (uint8_t)0u, (uint8_t)6u)); + if (freq_band_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, freq_band_list, 1, 8, integer_packer(1, 1024))); + } + if (no_sib1_present) { + HANDLE_CODE(pack_integer(bref, no_sib1.ssb_subcarrier_offset, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(no_sib1.pdcch_cfg_sib1.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE nzp_csi_rs_res_set_s::unpack(cbit_ref& bref) +SRSASN_CODE cgi_info_nr_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(repeat_present, 1)); - HANDLE_CODE(bref.unpack(aperiodic_trigger_offset_present, 1)); - HANDLE_CODE(bref.unpack(trs_info_present, 1)); + HANDLE_CODE(bref.unpack(plmn_id_info_list_present, 1)); + HANDLE_CODE(bref.unpack(freq_band_list_present, 1)); + HANDLE_CODE(bref.unpack(no_sib1_present, 1)); - HANDLE_CODE(unpack_integer(nzp_csi_res_set_id, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res, bref, 1, 64, integer_packer(0, 191))); - if (repeat_present) { - HANDLE_CODE(repeat.unpack(bref)); + if (plmn_id_info_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(plmn_id_info_list, bref, 1, 12)); } - if (aperiodic_trigger_offset_present) { - HANDLE_CODE(unpack_integer(aperiodic_trigger_offset, bref, (uint8_t)0u, (uint8_t)6u)); + if (freq_band_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(freq_band_list, bref, 1, 8, integer_packer(1, 1024))); + } + if (no_sib1_present) { + HANDLE_CODE(unpack_integer(no_sib1.ssb_subcarrier_offset, bref, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(no_sib1.pdcch_cfg_sib1.unpack(bref)); } return SRSASN_SUCCESS; } -void nzp_csi_rs_res_set_s::to_json(json_writer& j) const +void cgi_info_nr_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("nzp-CSI-ResourceSetId", nzp_csi_res_set_id); - j.start_array("nzp-CSI-RS-Resources"); - for (const auto& e1 : nzp_csi_rs_res) { - j.write_int(e1); + if (plmn_id_info_list_present) { + j.start_array("plmn-IdentityInfoList"); + for (const auto& e1 : plmn_id_info_list) { + e1.to_json(j); + } + j.end_array(); } - j.end_array(); - if (repeat_present) { - j.write_str("repetition", repeat.to_string()); + if (freq_band_list_present) { + j.start_array("frequencyBandList"); + for (const auto& e1 : freq_band_list) { + j.write_int(e1); + } + j.end_array(); } - if (aperiodic_trigger_offset_present) { - j.write_int("aperiodicTriggeringOffset", aperiodic_trigger_offset); + if (no_sib1_present) { + j.write_fieldname("noSIB1"); + j.start_obj(); + j.write_int("ssb-SubcarrierOffset", no_sib1.ssb_subcarrier_offset); + j.write_fieldname("pdcch-ConfigSIB1"); + no_sib1.pdcch_cfg_sib1.to_json(j); + j.end_obj(); } - if (trs_info_present) { - j.write_str("trs-Info", "true"); + j.end_obj(); +} + +// CellAccessRelatedInfo-EUTRA-5GC ::= SEQUENCE +SRSASN_CODE cell_access_related_info_eutra_minus5_gc_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(ranac_minus5gc_present, 1)); + + HANDLE_CODE(pack_dyn_seq_of(bref, plmn_id_list_eutra_minus5gc, 1, 12)); + HANDLE_CODE(tac_eutra_minus5gc.pack(bref)); + if (ranac_minus5gc_present) { + HANDLE_CODE(pack_integer(bref, ranac_minus5gc, (uint16_t)0u, (uint16_t)255u)); + } + HANDLE_CODE(cell_id_eutra_minus5gc.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE cell_access_related_info_eutra_minus5_gc_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(ranac_minus5gc_present, 1)); + + HANDLE_CODE(unpack_dyn_seq_of(plmn_id_list_eutra_minus5gc, bref, 1, 12)); + HANDLE_CODE(tac_eutra_minus5gc.unpack(bref)); + if (ranac_minus5gc_present) { + HANDLE_CODE(unpack_integer(ranac_minus5gc, bref, (uint16_t)0u, (uint16_t)255u)); } + HANDLE_CODE(cell_id_eutra_minus5gc.unpack(bref)); + + return SRSASN_SUCCESS; +} +void cell_access_related_info_eutra_minus5_gc_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.start_array("plmn-IdentityList-eutra-5gc"); + for (const auto& e1 : plmn_id_list_eutra_minus5gc) { + e1.to_json(j); + } + j.end_array(); + j.write_str("trackingAreaCode-eutra-5gc", tac_eutra_minus5gc.to_string()); + if (ranac_minus5gc_present) { + j.write_int("ranac-5gc", ranac_minus5gc); + } + j.write_fieldname("cellIdentity-eutra-5gc"); + cell_id_eutra_minus5gc.to_json(j); j.end_obj(); } -std::string nzp_csi_rs_res_set_s::repeat_opts::to_string() const +// CellAccessRelatedInfo-EUTRA-EPC ::= SEQUENCE +SRSASN_CODE cell_access_related_info_eutra_epc_s::pack(bit_ref& bref) const { - static const char* options[] = {"on", "off"}; - return convert_enum_idx(options, 2, value, "nzp_csi_rs_res_set_s::repeat_e_"); + HANDLE_CODE(pack_dyn_seq_of(bref, plmn_id_list_eutra_epc, 1, 12)); + HANDLE_CODE(tac_eutra_epc.pack(bref)); + HANDLE_CODE(cell_id_eutra_epc.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE cell_access_related_info_eutra_epc_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_dyn_seq_of(plmn_id_list_eutra_epc, bref, 1, 12)); + HANDLE_CODE(tac_eutra_epc.unpack(bref)); + HANDLE_CODE(cell_id_eutra_epc.unpack(bref)); + + return SRSASN_SUCCESS; +} +void cell_access_related_info_eutra_epc_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.start_array("plmn-IdentityList-eutra-epc"); + for (const auto& e1 : plmn_id_list_eutra_epc) { + e1.to_json(j); + } + j.end_array(); + j.write_str("trackingAreaCode-eutra-epc", tac_eutra_epc.to_string()); + j.write_str("cellIdentity-eutra-epc", cell_id_eutra_epc.to_string()); + j.end_obj(); } -// PDSCH-CodeBlockGroupTransmission ::= SEQUENCE -SRSASN_CODE pdsch_code_block_group_tx_s::pack(bit_ref& bref) const +// CGI-InfoEUTRA ::= SEQUENCE +SRSASN_CODE cgi_info_eutra_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(max_code_block_groups_per_transport_block.pack(bref)); - HANDLE_CODE(bref.pack(code_block_group_flush_ind, 1)); + HANDLE_CODE(bref.pack(cgi_info_epc_present, 1)); + HANDLE_CODE(bref.pack(cgi_info_minus5_gc_present, 1)); + HANDLE_CODE(bref.pack(multi_band_info_list_present, 1)); + HANDLE_CODE(bref.pack(freq_band_ind_prio_present, 1)); + + if (cgi_info_epc_present) { + HANDLE_CODE(bref.pack(cgi_info_epc.cgi_info_epc_list_present, 1)); + HANDLE_CODE(cgi_info_epc.cgi_info_epc_legacy.pack(bref)); + if (cgi_info_epc.cgi_info_epc_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, cgi_info_epc.cgi_info_epc_list, 1, 12)); + } + } + if (cgi_info_minus5_gc_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, cgi_info_minus5_gc, 1, 12)); + } + HANDLE_CODE(pack_integer(bref, freq_band_ind, (uint16_t)1u, (uint16_t)256u)); + if (multi_band_info_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, multi_band_info_list, 1, 8, integer_packer(1, 256))); + } return SRSASN_SUCCESS; } -SRSASN_CODE pdsch_code_block_group_tx_s::unpack(cbit_ref& bref) +SRSASN_CODE cgi_info_eutra_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(max_code_block_groups_per_transport_block.unpack(bref)); - HANDLE_CODE(bref.unpack(code_block_group_flush_ind, 1)); + HANDLE_CODE(bref.unpack(cgi_info_epc_present, 1)); + HANDLE_CODE(bref.unpack(cgi_info_minus5_gc_present, 1)); + HANDLE_CODE(bref.unpack(multi_band_info_list_present, 1)); + HANDLE_CODE(bref.unpack(freq_band_ind_prio_present, 1)); + + if (cgi_info_epc_present) { + HANDLE_CODE(bref.unpack(cgi_info_epc.cgi_info_epc_list_present, 1)); + HANDLE_CODE(cgi_info_epc.cgi_info_epc_legacy.unpack(bref)); + if (cgi_info_epc.cgi_info_epc_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(cgi_info_epc.cgi_info_epc_list, bref, 1, 12)); + } + } + if (cgi_info_minus5_gc_present) { + HANDLE_CODE(unpack_dyn_seq_of(cgi_info_minus5_gc, bref, 1, 12)); + } + HANDLE_CODE(unpack_integer(freq_band_ind, bref, (uint16_t)1u, (uint16_t)256u)); + if (multi_band_info_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(multi_band_info_list, bref, 1, 8, integer_packer(1, 256))); + } return SRSASN_SUCCESS; } -void pdsch_code_block_group_tx_s::to_json(json_writer& j) const +void cgi_info_eutra_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("maxCodeBlockGroupsPerTransportBlock", max_code_block_groups_per_transport_block.to_string()); - j.write_bool("codeBlockGroupFlushIndicator", code_block_group_flush_ind); + if (cgi_info_epc_present) { + j.write_fieldname("cgi-info-EPC"); + j.start_obj(); + j.write_fieldname("cgi-info-EPC-legacy"); + cgi_info_epc.cgi_info_epc_legacy.to_json(j); + if (cgi_info_epc.cgi_info_epc_list_present) { + j.start_array("cgi-info-EPC-list"); + for (const auto& e1 : cgi_info_epc.cgi_info_epc_list) { + e1.to_json(j); + } + j.end_array(); + } + j.end_obj(); + } + if (cgi_info_minus5_gc_present) { + j.start_array("cgi-info-5GC"); + for (const auto& e1 : cgi_info_minus5_gc) { + e1.to_json(j); + } + j.end_array(); + } + j.write_int("freqBandIndicator", freq_band_ind); + if (multi_band_info_list_present) { + j.start_array("multiBandInfoList"); + for (const auto& e1 : multi_band_info_list) { + j.write_int(e1); + } + j.end_array(); + } + if (freq_band_ind_prio_present) { + j.write_str("freqBandIndicatorPriority", "true"); + } j.end_obj(); } -std::string pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_string() const +// MeasQuantityResultsEUTRA ::= SEQUENCE +SRSASN_CODE meas_quant_results_eutra_s::pack(bit_ref& bref) const { - static const char* options[] = {"n2", "n4", "n6", "n8"}; - return convert_enum_idx( - options, 4, value, "pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); + HANDLE_CODE(bref.pack(rsrp_present, 1)); + HANDLE_CODE(bref.pack(rsrq_present, 1)); + HANDLE_CODE(bref.pack(sinr_present, 1)); + + if (rsrp_present) { + HANDLE_CODE(pack_integer(bref, rsrp, (uint8_t)0u, (uint8_t)97u)); + } + if (rsrq_present) { + HANDLE_CODE(pack_integer(bref, rsrq, (uint8_t)0u, (uint8_t)34u)); + } + if (sinr_present) { + HANDLE_CODE(pack_integer(bref, sinr, (uint8_t)0u, (uint8_t)127u)); + } + + return SRSASN_SUCCESS; } -uint8_t pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_number() const +SRSASN_CODE meas_quant_results_eutra_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {2, 4, 6, 8}; - return map_enum_number( - options, 4, value, "pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); + HANDLE_CODE(bref.unpack(rsrp_present, 1)); + HANDLE_CODE(bref.unpack(rsrq_present, 1)); + HANDLE_CODE(bref.unpack(sinr_present, 1)); + + if (rsrp_present) { + HANDLE_CODE(unpack_integer(rsrp, bref, (uint8_t)0u, (uint8_t)97u)); + } + if (rsrq_present) { + HANDLE_CODE(unpack_integer(rsrq, bref, (uint8_t)0u, (uint8_t)34u)); + } + if (sinr_present) { + HANDLE_CODE(unpack_integer(sinr, bref, (uint8_t)0u, (uint8_t)127u)); + } + + return SRSASN_SUCCESS; +} +void meas_quant_results_eutra_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (rsrp_present) { + j.write_int("rsrp", rsrp); + } + if (rsrq_present) { + j.write_int("rsrq", rsrq); + } + if (sinr_present) { + j.write_int("sinr", sinr); + } + j.end_obj(); } -// PUSCH-ServingCellConfig ::= SEQUENCE -SRSASN_CODE pusch_serving_cell_cfg_s::pack(bit_ref& bref) const +// MeasResultNR ::= SEQUENCE +SRSASN_CODE meas_result_nr_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(code_block_group_tx_present, 1)); - HANDLE_CODE(bref.pack(rate_matching_present, 1)); - HANDLE_CODE(bref.pack(xoverhead_present, 1)); + HANDLE_CODE(bref.pack(pci_present, 1)); - if (code_block_group_tx_present) { - HANDLE_CODE(code_block_group_tx.pack(bref)); + if (pci_present) { + HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); } - if (xoverhead_present) { - HANDLE_CODE(xoverhead.pack(bref)); + HANDLE_CODE(bref.pack(meas_result.rs_idx_results_present, 1)); + HANDLE_CODE(bref.pack(meas_result.cell_results.results_ssb_cell_present, 1)); + HANDLE_CODE(bref.pack(meas_result.cell_results.results_csi_rs_cell_present, 1)); + if (meas_result.cell_results.results_ssb_cell_present) { + HANDLE_CODE(meas_result.cell_results.results_ssb_cell.pack(bref)); + } + if (meas_result.cell_results.results_csi_rs_cell_present) { + HANDLE_CODE(meas_result.cell_results.results_csi_rs_cell.pack(bref)); + } + if (meas_result.rs_idx_results_present) { + HANDLE_CODE(bref.pack(meas_result.rs_idx_results.results_ssb_idxes_present, 1)); + HANDLE_CODE(bref.pack(meas_result.rs_idx_results.results_csi_rs_idxes_present, 1)); + if (meas_result.rs_idx_results.results_ssb_idxes_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result.rs_idx_results.results_ssb_idxes, 1, 64)); + } + if (meas_result.rs_idx_results.results_csi_rs_idxes_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result.rs_idx_results.results_csi_rs_idxes, 1, 64)); + } } if (ext) { ext_groups_packer_guard group_flags; - group_flags[0] |= max_mimo_layers_present; - group_flags[0] |= processing_type2_enabled_present; + group_flags[0] |= cgi_info.is_present(); group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(max_mimo_layers_present, 1)); - HANDLE_CODE(bref.pack(processing_type2_enabled_present, 1)); - if (max_mimo_layers_present) { - HANDLE_CODE(pack_integer(bref, max_mimo_layers, (uint8_t)1u, (uint8_t)4u)); - } - if (processing_type2_enabled_present) { - HANDLE_CODE(bref.pack(processing_type2_enabled, 1)); + HANDLE_CODE(bref.pack(cgi_info.is_present(), 1)); + if (cgi_info.is_present()) { + HANDLE_CODE(cgi_info->pack(bref)); } } } return SRSASN_SUCCESS; } -SRSASN_CODE pusch_serving_cell_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_result_nr_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(code_block_group_tx_present, 1)); - HANDLE_CODE(bref.unpack(rate_matching_present, 1)); - HANDLE_CODE(bref.unpack(xoverhead_present, 1)); + HANDLE_CODE(bref.unpack(pci_present, 1)); - if (code_block_group_tx_present) { - HANDLE_CODE(code_block_group_tx.unpack(bref)); + if (pci_present) { + HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); } - if (xoverhead_present) { - HANDLE_CODE(xoverhead.unpack(bref)); + HANDLE_CODE(bref.unpack(meas_result.rs_idx_results_present, 1)); + HANDLE_CODE(bref.unpack(meas_result.cell_results.results_ssb_cell_present, 1)); + HANDLE_CODE(bref.unpack(meas_result.cell_results.results_csi_rs_cell_present, 1)); + if (meas_result.cell_results.results_ssb_cell_present) { + HANDLE_CODE(meas_result.cell_results.results_ssb_cell.unpack(bref)); + } + if (meas_result.cell_results.results_csi_rs_cell_present) { + HANDLE_CODE(meas_result.cell_results.results_csi_rs_cell.unpack(bref)); + } + if (meas_result.rs_idx_results_present) { + HANDLE_CODE(bref.unpack(meas_result.rs_idx_results.results_ssb_idxes_present, 1)); + HANDLE_CODE(bref.unpack(meas_result.rs_idx_results.results_csi_rs_idxes_present, 1)); + if (meas_result.rs_idx_results.results_ssb_idxes_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_result.rs_idx_results.results_ssb_idxes, bref, 1, 64)); + } + if (meas_result.rs_idx_results.results_csi_rs_idxes_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_result.rs_idx_results.results_csi_rs_idxes, bref, 1, 64)); + } } if (ext) { @@ -21987,6229 +19765,4738 @@ SRSASN_CODE pusch_serving_cell_cfg_s::unpack(cbit_ref& bref) if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.unpack(max_mimo_layers_present, 1)); - HANDLE_CODE(bref.unpack(processing_type2_enabled_present, 1)); - if (max_mimo_layers_present) { - HANDLE_CODE(unpack_integer(max_mimo_layers, bref, (uint8_t)1u, (uint8_t)4u)); - } - if (processing_type2_enabled_present) { - HANDLE_CODE(bref.unpack(processing_type2_enabled, 1)); + bool cgi_info_present; + HANDLE_CODE(bref.unpack(cgi_info_present, 1)); + cgi_info.set_present(cgi_info_present); + if (cgi_info.is_present()) { + HANDLE_CODE(cgi_info->unpack(bref)); } } } return SRSASN_SUCCESS; } -void pusch_serving_cell_cfg_s::to_json(json_writer& j) const +void meas_result_nr_s::to_json(json_writer& j) const { j.start_obj(); - if (code_block_group_tx_present) { - j.write_fieldname("codeBlockGroupTransmission"); - code_block_group_tx.to_json(j); + if (pci_present) { + j.write_int("physCellId", pci); } - if (rate_matching_present) { - j.write_str("rateMatching", "limitedBufferRM"); + j.write_fieldname("measResult"); + j.start_obj(); + j.write_fieldname("cellResults"); + j.start_obj(); + if (meas_result.cell_results.results_ssb_cell_present) { + j.write_fieldname("resultsSSB-Cell"); + meas_result.cell_results.results_ssb_cell.to_json(j); } - if (xoverhead_present) { - j.write_str("xOverhead", xoverhead.to_string()); + if (meas_result.cell_results.results_csi_rs_cell_present) { + j.write_fieldname("resultsCSI-RS-Cell"); + meas_result.cell_results.results_csi_rs_cell.to_json(j); } - if (ext) { - if (max_mimo_layers_present) { - j.write_int("maxMIMO-Layers", max_mimo_layers); - } - if (processing_type2_enabled_present) { - j.write_bool("processingType2Enabled", processing_type2_enabled); - } + j.end_obj(); + if (meas_result.rs_idx_results_present) { + j.write_fieldname("rsIndexResults"); + j.start_obj(); + if (meas_result.rs_idx_results.results_ssb_idxes_present) { + j.start_array("resultsSSB-Indexes"); + for (const auto& e1 : meas_result.rs_idx_results.results_ssb_idxes) { + e1.to_json(j); + } + j.end_array(); + } + if (meas_result.rs_idx_results.results_csi_rs_idxes_present) { + j.start_array("resultsCSI-RS-Indexes"); + for (const auto& e1 : meas_result.rs_idx_results.results_csi_rs_idxes) { + e1.to_json(j); + } + j.end_array(); + } + j.end_obj(); + } + j.end_obj(); + if (ext) { + if (cgi_info.is_present()) { + j.write_fieldname("cgi-Info"); + cgi_info->to_json(j); + } } j.end_obj(); } -std::string pusch_serving_cell_cfg_s::xoverhead_opts::to_string() const -{ - static const char* options[] = {"xoh6", "xoh12", "xoh18"}; - return convert_enum_idx(options, 3, value, "pusch_serving_cell_cfg_s::xoverhead_e_"); -} -uint8_t pusch_serving_cell_cfg_s::xoverhead_opts::to_number() const -{ - static const uint8_t options[] = {6, 12, 18}; - return map_enum_number(options, 3, value, "pusch_serving_cell_cfg_s::xoverhead_e_"); -} - -// PollByte ::= ENUMERATED -std::string poll_byte_opts::to_string() const -{ - static const char* options[] = { - "kB1", "kB2", "kB5", "kB8", "kB10", "kB15", "kB25", "kB50", "kB75", "kB100", - "kB125", "kB250", "kB375", "kB500", "kB750", "kB1000", "kB1250", "kB1500", "kB2000", "kB3000", - "kB4000", "kB4500", "kB5000", "kB5500", "kB6000", "kB6500", "kB7000", "kB7500", "mB8", "mB9", - "mB10", "mB11", "mB12", "mB13", "mB14", "mB15", "mB16", "mB17", "mB18", "mB20", - "mB25", "mB30", "mB40", "infinity", "spare20", "spare19", "spare18", "spare17", "spare16", "spare15", - "spare14", "spare13", "spare12", "spare11", "spare10", "spare9", "spare8", "spare7", "spare6", "spare5", - "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 64, value, "poll_byte_e"); -} - -// PollPDU ::= ENUMERATED -std::string poll_pdu_opts::to_string() const -{ - static const char* options[] = {"p4", "p8", "p16", "p32", "p64", "p128", "p256", "p512", - "p1024", "p2048", "p4096", "p6144", "p8192", "p12288", "p16384", "p20480", - "p24576", "p28672", "p32768", "p40960", "p49152", "p57344", "p65536", "infinity", - "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 32, value, "poll_pdu_e"); -} -int32_t poll_pdu_opts::to_number() const -{ - static const int32_t options[] = {4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 6144, - 8192, 12288, 16384, 20480, 24576, 28672, 32768, 40960, 49152, 57344, 65536, -1}; - return map_enum_number(options, 24, value, "poll_pdu_e"); -} - -// RateMatchPatternLTE-CRS ::= SEQUENCE -SRSASN_CODE rate_match_pattern_lte_crs_s::pack(bit_ref& bref) const +// MeasResultEUTRA ::= SEQUENCE +SRSASN_CODE meas_result_eutra_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(mbsfn_sf_cfg_list_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(cgi_info_present, 1)); - HANDLE_CODE(pack_integer(bref, carrier_freq_dl, (uint16_t)0u, (uint16_t)16383u)); - HANDLE_CODE(carrier_bw_dl.pack(bref)); - if (mbsfn_sf_cfg_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, mbsfn_sf_cfg_list, 1, 8)); + HANDLE_CODE(pack_integer(bref, eutra_pci, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(meas_result.pack(bref)); + if (cgi_info_present) { + HANDLE_CODE(cgi_info.pack(bref)); } - HANDLE_CODE(nrof_crs_ports.pack(bref)); - HANDLE_CODE(v_shift.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE rate_match_pattern_lte_crs_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_result_eutra_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(mbsfn_sf_cfg_list_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(cgi_info_present, 1)); - HANDLE_CODE(unpack_integer(carrier_freq_dl, bref, (uint16_t)0u, (uint16_t)16383u)); - HANDLE_CODE(carrier_bw_dl.unpack(bref)); - if (mbsfn_sf_cfg_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(mbsfn_sf_cfg_list, bref, 1, 8)); + HANDLE_CODE(unpack_integer(eutra_pci, bref, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(meas_result.unpack(bref)); + if (cgi_info_present) { + HANDLE_CODE(cgi_info.unpack(bref)); } - HANDLE_CODE(nrof_crs_ports.unpack(bref)); - HANDLE_CODE(v_shift.unpack(bref)); return SRSASN_SUCCESS; } -void rate_match_pattern_lte_crs_s::to_json(json_writer& j) const +void meas_result_eutra_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("carrierFreqDL", carrier_freq_dl); - j.write_str("carrierBandwidthDL", carrier_bw_dl.to_string()); - if (mbsfn_sf_cfg_list_present) { - j.start_array("mbsfn-SubframeConfigList"); - for (const auto& e1 : mbsfn_sf_cfg_list) { - e1.to_json(j); - } - j.end_array(); + j.write_int("eutra-PhysCellId", eutra_pci); + j.write_fieldname("measResult"); + meas_result.to_json(j); + if (cgi_info_present) { + j.write_fieldname("cgi-Info"); + cgi_info.to_json(j); } - j.write_str("nrofCRS-Ports", nrof_crs_ports.to_string()); - j.write_str("v-Shift", v_shift.to_string()); j.end_obj(); } -std::string rate_match_pattern_lte_crs_s::carrier_bw_dl_opts::to_string() const +// UplinkTxDirectCurrentBWP ::= SEQUENCE +SRSASN_CODE ul_tx_direct_current_bwp_s::pack(bit_ref& bref) const { - static const char* options[] = {"n6", "n15", "n25", "n50", "n75", "n100", "spare2", "spare1"}; - return convert_enum_idx(options, 8, value, "rate_match_pattern_lte_crs_s::carrier_bw_dl_e_"); + HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(bref.pack(shift7dot5k_hz, 1)); + HANDLE_CODE(pack_integer(bref, tx_direct_current_location, (uint16_t)0u, (uint16_t)3301u)); + + return SRSASN_SUCCESS; } -uint8_t rate_match_pattern_lte_crs_s::carrier_bw_dl_opts::to_number() const +SRSASN_CODE ul_tx_direct_current_bwp_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {6, 15, 25, 50, 75, 100}; - return map_enum_number(options, 6, value, "rate_match_pattern_lte_crs_s::carrier_bw_dl_e_"); -} + HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(bref.unpack(shift7dot5k_hz, 1)); + HANDLE_CODE(unpack_integer(tx_direct_current_location, bref, (uint16_t)0u, (uint16_t)3301u)); -std::string rate_match_pattern_lte_crs_s::nrof_crs_ports_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4"}; - return convert_enum_idx(options, 3, value, "rate_match_pattern_lte_crs_s::nrof_crs_ports_e_"); + return SRSASN_SUCCESS; } -uint8_t rate_match_pattern_lte_crs_s::nrof_crs_ports_opts::to_number() const +void ul_tx_direct_current_bwp_s::to_json(json_writer& j) const { - static const uint8_t options[] = {1, 2, 4}; - return map_enum_number(options, 3, value, "rate_match_pattern_lte_crs_s::nrof_crs_ports_e_"); + j.start_obj(); + j.write_int("bwp-Id", bwp_id); + j.write_bool("shift7dot5kHz", shift7dot5k_hz); + j.write_int("txDirectCurrentLocation", tx_direct_current_location); + j.end_obj(); } -std::string rate_match_pattern_lte_crs_s::v_shift_opts::to_string() const +// EUTRA-RSTD-Info ::= SEQUENCE +SRSASN_CODE eutra_rstd_info_s::pack(bit_ref& bref) const { - static const char* options[] = {"n0", "n1", "n2", "n3", "n4", "n5"}; - return convert_enum_idx(options, 6, value, "rate_match_pattern_lte_crs_s::v_shift_e_"); + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(pack_integer(bref, meas_prs_offset, (uint8_t)0u, (uint8_t)39u)); + + return SRSASN_SUCCESS; } -uint8_t rate_match_pattern_lte_crs_s::v_shift_opts::to_number() const +SRSASN_CODE eutra_rstd_info_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {0, 1, 2, 3, 4, 5}; - return map_enum_number(options, 6, value, "rate_match_pattern_lte_crs_s::v_shift_e_"); + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(unpack_integer(meas_prs_offset, bref, (uint8_t)0u, (uint8_t)39u)); + + return SRSASN_SUCCESS; +} +void eutra_rstd_info_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("carrierFreq", carrier_freq); + j.write_int("measPRS-Offset", meas_prs_offset); + j.end_obj(); } -// SN-FieldLengthAM ::= ENUMERATED -std::string sn_field_len_am_opts::to_string() const +// MIMO-LayersDL ::= ENUMERATED +std::string mimo_layers_dl_opts::to_string() const { - static const char* options[] = {"size12", "size18"}; - return convert_enum_idx(options, 2, value, "sn_field_len_am_e"); + static const char* options[] = {"twoLayers", "fourLayers", "eightLayers"}; + return convert_enum_idx(options, 3, value, "mimo_layers_dl_e"); } -uint8_t sn_field_len_am_opts::to_number() const +uint8_t mimo_layers_dl_opts::to_number() const { - static const uint8_t options[] = {12, 18}; - return map_enum_number(options, 2, value, "sn_field_len_am_e"); + static const uint8_t options[] = {2, 4, 8}; + return map_enum_number(options, 3, value, "mimo_layers_dl_e"); } -// SN-FieldLengthUM ::= ENUMERATED -std::string sn_field_len_um_opts::to_string() const +// MIMO-LayersUL ::= ENUMERATED +std::string mimo_layers_ul_opts::to_string() const { - static const char* options[] = {"size6", "size12"}; - return convert_enum_idx(options, 2, value, "sn_field_len_um_e"); + static const char* options[] = {"oneLayer", "twoLayers", "fourLayers"}; + return convert_enum_idx(options, 3, value, "mimo_layers_ul_e"); } -uint8_t sn_field_len_um_opts::to_number() const +uint8_t mimo_layers_ul_opts::to_number() const { - static const uint8_t options[] = {6, 12}; - return map_enum_number(options, 2, value, "sn_field_len_um_e"); + static const uint8_t options[] = {1, 2, 4}; + return map_enum_number(options, 3, value, "mimo_layers_ul_e"); } -// SRS-CarrierSwitching ::= SEQUENCE -SRSASN_CODE srs_carrier_switching_s::pack(bit_ref& bref) const +// MeasResult2EUTRA ::= SEQUENCE +SRSASN_CODE meas_result2_eutra_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(srs_switch_from_serv_cell_idx_present, 1)); - HANDLE_CODE(bref.pack(srs_tpc_pdcch_group_present, 1)); - HANDLE_CODE(bref.pack(monitoring_cells_present, 1)); + HANDLE_CODE(bref.pack(meas_result_serving_cell_present, 1)); + HANDLE_CODE(bref.pack(meas_result_best_neigh_cell_present, 1)); - if (srs_switch_from_serv_cell_idx_present) { - HANDLE_CODE(pack_integer(bref, srs_switch_from_serv_cell_idx, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(srs_switch_from_carrier.pack(bref)); - if (srs_tpc_pdcch_group_present) { - HANDLE_CODE(srs_tpc_pdcch_group.pack(bref)); + HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)262143u)); + if (meas_result_serving_cell_present) { + HANDLE_CODE(meas_result_serving_cell.pack(bref)); } - if (monitoring_cells_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, monitoring_cells, 1, 32, integer_packer(0, 31))); + if (meas_result_best_neigh_cell_present) { + HANDLE_CODE(meas_result_best_neigh_cell.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE srs_carrier_switching_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_result2_eutra_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(srs_switch_from_serv_cell_idx_present, 1)); - HANDLE_CODE(bref.unpack(srs_tpc_pdcch_group_present, 1)); - HANDLE_CODE(bref.unpack(monitoring_cells_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_serving_cell_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_best_neigh_cell_present, 1)); - if (srs_switch_from_serv_cell_idx_present) { - HANDLE_CODE(unpack_integer(srs_switch_from_serv_cell_idx, bref, (uint8_t)0u, (uint8_t)31u)); - } - HANDLE_CODE(srs_switch_from_carrier.unpack(bref)); - if (srs_tpc_pdcch_group_present) { - HANDLE_CODE(srs_tpc_pdcch_group.unpack(bref)); + HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)262143u)); + if (meas_result_serving_cell_present) { + HANDLE_CODE(meas_result_serving_cell.unpack(bref)); } - if (monitoring_cells_present) { - HANDLE_CODE(unpack_dyn_seq_of(monitoring_cells, bref, 1, 32, integer_packer(0, 31))); + if (meas_result_best_neigh_cell_present) { + HANDLE_CODE(meas_result_best_neigh_cell.unpack(bref)); } return SRSASN_SUCCESS; } -void srs_carrier_switching_s::to_json(json_writer& j) const +void meas_result2_eutra_s::to_json(json_writer& j) const { j.start_obj(); - if (srs_switch_from_serv_cell_idx_present) { - j.write_int("srs-SwitchFromServCellIndex", srs_switch_from_serv_cell_idx); - } - j.write_str("srs-SwitchFromCarrier", srs_switch_from_carrier.to_string()); - if (srs_tpc_pdcch_group_present) { - j.write_fieldname("srs-TPC-PDCCH-Group"); - srs_tpc_pdcch_group.to_json(j); + j.write_int("carrierFreq", carrier_freq); + if (meas_result_serving_cell_present) { + j.write_fieldname("measResultServingCell"); + meas_result_serving_cell.to_json(j); } - if (monitoring_cells_present) { - j.start_array("monitoringCells"); - for (const auto& e1 : monitoring_cells) { - j.write_int(e1); - } - j.end_array(); + if (meas_result_best_neigh_cell_present) { + j.write_fieldname("measResultBestNeighCell"); + meas_result_best_neigh_cell.to_json(j); } j.end_obj(); } -std::string srs_carrier_switching_s::srs_switch_from_carrier_opts::to_string() const +// MeasResult2NR ::= SEQUENCE +SRSASN_CODE meas_result2_nr_s::pack(bit_ref& bref) const { - static const char* options[] = {"sUL", "nUL"}; - return convert_enum_idx(options, 2, value, "srs_carrier_switching_s::srs_switch_from_carrier_e_"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(ssb_freq_present, 1)); + HANDLE_CODE(bref.pack(ref_freq_csi_rs_present, 1)); + HANDLE_CODE(bref.pack(meas_result_serving_cell_present, 1)); + HANDLE_CODE(bref.pack(meas_result_neigh_cell_list_nr_present, 1)); -void srs_carrier_switching_s::srs_tpc_pdcch_group_c_::destroy_() -{ - switch (type_) { - case types::type_a: - c.destroy(); - break; - case types::type_b: - c.destroy(); - break; - default: - break; + if (ssb_freq_present) { + HANDLE_CODE(pack_integer(bref, ssb_freq, (uint32_t)0u, (uint32_t)3279165u)); } -} -void srs_carrier_switching_s::srs_tpc_pdcch_group_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::type_a: - c.init(); - break; - case types::type_b: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); + if (ref_freq_csi_rs_present) { + HANDLE_CODE(pack_integer(bref, ref_freq_csi_rs, (uint32_t)0u, (uint32_t)3279165u)); } -} -srs_carrier_switching_s::srs_tpc_pdcch_group_c_::srs_tpc_pdcch_group_c_( - const srs_carrier_switching_s::srs_tpc_pdcch_group_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::type_a: - c.init(other.c.get()); - break; - case types::type_b: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); + if (meas_result_serving_cell_present) { + HANDLE_CODE(meas_result_serving_cell.pack(bref)); } + if (meas_result_neigh_cell_list_nr_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_neigh_cell_list_nr, 1, 8)); + } + + return SRSASN_SUCCESS; } -srs_carrier_switching_s::srs_tpc_pdcch_group_c_& srs_carrier_switching_s::srs_tpc_pdcch_group_c_:: - operator=(const srs_carrier_switching_s::srs_tpc_pdcch_group_c_& other) +SRSASN_CODE meas_result2_nr_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(ssb_freq_present, 1)); + HANDLE_CODE(bref.unpack(ref_freq_csi_rs_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_serving_cell_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_neigh_cell_list_nr_present, 1)); + + if (ssb_freq_present) { + HANDLE_CODE(unpack_integer(ssb_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); } - set(other.type()); - switch (type_) { - case types::type_a: - c.set(other.c.get()); - break; - case types::type_b: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); + if (ref_freq_csi_rs_present) { + HANDLE_CODE(unpack_integer(ref_freq_csi_rs, bref, (uint32_t)0u, (uint32_t)3279165u)); + } + if (meas_result_serving_cell_present) { + HANDLE_CODE(meas_result_serving_cell.unpack(bref)); + } + if (meas_result_neigh_cell_list_nr_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_result_neigh_cell_list_nr, bref, 1, 8)); } - return *this; + return SRSASN_SUCCESS; } -void srs_carrier_switching_s::srs_tpc_pdcch_group_c_::to_json(json_writer& j) const +void meas_result2_nr_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::type_a: - j.start_array("typeA"); - for (const auto& e1 : c.get()) { - e1.to_json(j); - } - j.end_array(); - break; - case types::type_b: - j.write_fieldname("typeB"); - c.get().to_json(j); - break; - default: - log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); + if (ssb_freq_present) { + j.write_int("ssbFrequency", ssb_freq); + } + if (ref_freq_csi_rs_present) { + j.write_int("refFreqCSI-RS", ref_freq_csi_rs); + } + if (meas_result_serving_cell_present) { + j.write_fieldname("measResultServingCell"); + meas_result_serving_cell.to_json(j); + } + if (meas_result_neigh_cell_list_nr_present) { + j.start_array("measResultNeighCellListNR"); + for (const auto& e1 : meas_result_neigh_cell_list_nr) { + e1.to_json(j); + } + j.end_array(); } j.end_obj(); } -SRSASN_CODE srs_carrier_switching_s::srs_tpc_pdcch_group_c_::pack(bit_ref& bref) const + +// MeasResultCellSFTD-NR ::= SEQUENCE +SRSASN_CODE meas_result_cell_sftd_nr_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::type_a: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 32)); - break; - case types::type_b: - HANDLE_CODE(c.get().pack(bref)); - break; - default: - log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + HANDLE_CODE(bref.pack(rsrp_result_present, 1)); + + HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(pack_integer(bref, sfn_offset_result, (uint16_t)0u, (uint16_t)1023u)); + HANDLE_CODE(pack_integer(bref, frame_boundary_offset_result, (int16_t)-30720, (int16_t)30719)); + if (rsrp_result_present) { + HANDLE_CODE(pack_integer(bref, rsrp_result, (uint8_t)0u, (uint8_t)127u)); } + return SRSASN_SUCCESS; } -SRSASN_CODE srs_carrier_switching_s::srs_tpc_pdcch_group_c_::unpack(cbit_ref& bref) +SRSASN_CODE meas_result_cell_sftd_nr_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::type_a: - HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 32)); - break; - case types::type_b: - HANDLE_CODE(c.get().unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); - return SRSASN_ERROR_DECODE_FAIL; + HANDLE_CODE(bref.unpack(rsrp_result_present, 1)); + + HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(unpack_integer(sfn_offset_result, bref, (uint16_t)0u, (uint16_t)1023u)); + HANDLE_CODE(unpack_integer(frame_boundary_offset_result, bref, (int16_t)-30720, (int16_t)30719)); + if (rsrp_result_present) { + HANDLE_CODE(unpack_integer(rsrp_result, bref, (uint8_t)0u, (uint8_t)127u)); } + return SRSASN_SUCCESS; } - -std::string srs_carrier_switching_s::srs_tpc_pdcch_group_c_::types_opts::to_string() const +void meas_result_cell_sftd_nr_s::to_json(json_writer& j) const { - static const char* options[] = {"typeA", "typeB"}; - return convert_enum_idx(options, 2, value, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_::types"); + j.start_obj(); + j.write_int("physCellId", pci); + j.write_int("sfn-OffsetResult", sfn_offset_result); + j.write_int("frameBoundaryOffsetResult", frame_boundary_offset_result); + if (rsrp_result_present) { + j.write_int("rsrp-Result", rsrp_result); + } + j.end_obj(); } -// SlotFormatIndicator ::= SEQUENCE -SRSASN_CODE slot_format_ind_s::pack(bit_ref& bref) const +// MeasResultServMO ::= SEQUENCE +SRSASN_CODE meas_result_serv_mo_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(slot_format_comb_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(slot_format_comb_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(meas_result_best_neigh_cell_present, 1)); - HANDLE_CODE(pack_integer(bref, sfi_rnti, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(pack_integer(bref, dci_payload_size, (uint8_t)1u, (uint8_t)128u)); - if (slot_format_comb_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, slot_format_comb_to_add_mod_list, 1, 16)); - } - if (slot_format_comb_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, slot_format_comb_to_release_list, 1, 16, integer_packer(0, 31))); + HANDLE_CODE(pack_integer(bref, serv_cell_id, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(meas_result_serving_cell.pack(bref)); + if (meas_result_best_neigh_cell_present) { + HANDLE_CODE(meas_result_best_neigh_cell.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE slot_format_ind_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_result_serv_mo_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(slot_format_comb_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(slot_format_comb_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_best_neigh_cell_present, 1)); - HANDLE_CODE(unpack_integer(sfi_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(unpack_integer(dci_payload_size, bref, (uint8_t)1u, (uint8_t)128u)); - if (slot_format_comb_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(slot_format_comb_to_add_mod_list, bref, 1, 16)); - } - if (slot_format_comb_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(slot_format_comb_to_release_list, bref, 1, 16, integer_packer(0, 31))); + HANDLE_CODE(unpack_integer(serv_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(meas_result_serving_cell.unpack(bref)); + if (meas_result_best_neigh_cell_present) { + HANDLE_CODE(meas_result_best_neigh_cell.unpack(bref)); } return SRSASN_SUCCESS; } -void slot_format_ind_s::to_json(json_writer& j) const +void meas_result_serv_mo_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("sfi-RNTI", sfi_rnti); - j.write_int("dci-PayloadSize", dci_payload_size); - if (slot_format_comb_to_add_mod_list_present) { - j.start_array("slotFormatCombToAddModList"); - for (const auto& e1 : slot_format_comb_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (slot_format_comb_to_release_list_present) { - j.start_array("slotFormatCombToReleaseList"); - for (const auto& e1 : slot_format_comb_to_release_list) { - j.write_int(e1); - } - j.end_array(); + j.write_int("servCellId", serv_cell_id); + j.write_fieldname("measResultServingCell"); + meas_result_serving_cell.to_json(j); + if (meas_result_best_neigh_cell_present) { + j.write_fieldname("measResultBestNeighCell"); + meas_result_best_neigh_cell.to_json(j); } j.end_obj(); } -// T-PollRetransmit ::= ENUMERATED -std::string t_poll_retx_opts::to_string() const +// ReducedAggregatedBandwidth ::= ENUMERATED +std::string reduced_aggregated_bw_opts::to_string() const { static const char* options[] = { - "ms5", "ms10", "ms15", "ms20", "ms25", "ms30", "ms35", "ms40", "ms45", "ms50", "ms55", - "ms60", "ms65", "ms70", "ms75", "ms80", "ms85", "ms90", "ms95", "ms100", "ms105", "ms110", - "ms115", "ms120", "ms125", "ms130", "ms135", "ms140", "ms145", "ms150", "ms155", "ms160", "ms165", - "ms170", "ms175", "ms180", "ms185", "ms190", "ms195", "ms200", "ms205", "ms210", "ms215", "ms220", - "ms225", "ms230", "ms235", "ms240", "ms245", "ms250", "ms300", "ms350", "ms400", "ms450", "ms500", - "ms800", "ms1000", "ms2000", "ms4000", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 64, value, "t_poll_retx_e"); + "mhz0", "mhz10", "mhz20", "mhz30", "mhz40", "mhz50", "mhz60", "mhz80", "mhz100", "mhz200", "mhz300", "mhz400"}; + return convert_enum_idx(options, 12, value, "reduced_aggregated_bw_e"); } -uint16_t t_poll_retx_opts::to_number() const +uint16_t reduced_aggregated_bw_opts::to_number() const { - static const uint16_t options[] = {5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75, - 80, 85, 90, 95, 100, 105, 110, 115, 120, 125, 130, 135, 140, 145, 150, - 155, 160, 165, 170, 175, 180, 185, 190, 195, 200, 205, 210, 215, 220, 225, - 230, 235, 240, 245, 250, 300, 350, 400, 450, 500, 800, 1000, 2000, 4000}; - return map_enum_number(options, 59, value, "t_poll_retx_e"); + static const uint16_t options[] = {0, 10, 20, 30, 40, 50, 60, 80, 100, 200, 300, 400}; + return map_enum_number(options, 12, value, "reduced_aggregated_bw_e"); } -// T-Reassembly ::= ENUMERATED -std::string t_reassembly_opts::to_string() const +// UplinkTxDirectCurrentCell ::= SEQUENCE +SRSASN_CODE ul_tx_direct_current_cell_s::pack(bit_ref& bref) const { - static const char* options[] = {"ms0", "ms5", "ms10", "ms15", "ms20", "ms25", "ms30", "ms35", - "ms40", "ms45", "ms50", "ms55", "ms60", "ms65", "ms70", "ms75", - "ms80", "ms85", "ms90", "ms95", "ms100", "ms110", "ms120", "ms130", - "ms140", "ms150", "ms160", "ms170", "ms180", "ms190", "ms200", "spare1"}; - return convert_enum_idx(options, 32, value, "t_reassembly_e"); + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, serv_cell_idx, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(pack_dyn_seq_of(bref, ul_direct_current_bwp, 1, 4)); + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= ul_direct_current_bwp_sul.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(ul_direct_current_bwp_sul.is_present(), 1)); + if (ul_direct_current_bwp_sul.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *ul_direct_current_bwp_sul, 1, 4)); + } + } + } + return SRSASN_SUCCESS; } -uint8_t t_reassembly_opts::to_number() const +SRSASN_CODE ul_tx_direct_current_cell_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75, - 80, 85, 90, 95, 100, 110, 120, 130, 140, 150, 160, 170, 180, 190, 200}; - return map_enum_number(options, 31, value, "t_reassembly_e"); + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(serv_cell_idx, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(unpack_dyn_seq_of(ul_direct_current_bwp, bref, 1, 4)); + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool ul_direct_current_bwp_sul_present; + HANDLE_CODE(bref.unpack(ul_direct_current_bwp_sul_present, 1)); + ul_direct_current_bwp_sul.set_present(ul_direct_current_bwp_sul_present); + if (ul_direct_current_bwp_sul.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*ul_direct_current_bwp_sul, bref, 1, 4)); + } + } + } + return SRSASN_SUCCESS; +} +void ul_tx_direct_current_cell_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("servCellIndex", serv_cell_idx); + j.start_array("uplinkDirectCurrentBWP"); + for (const auto& e1 : ul_direct_current_bwp) { + e1.to_json(j); + } + j.end_array(); + if (ext) { + if (ul_direct_current_bwp_sul.is_present()) { + j.start_array("uplinkDirectCurrentBWP-SUL"); + for (const auto& e1 : *ul_direct_current_bwp_sul) { + e1.to_json(j); + } + j.end_array(); + } + } + j.end_obj(); } -// T-StatusProhibit ::= ENUMERATED -std::string t_status_prohibit_opts::to_string() const +// DRB-CountInfo ::= SEQUENCE +SRSASN_CODE drb_count_info_s::pack(bit_ref& bref) const { - static const char* options[] = { - "ms0", "ms5", "ms10", "ms15", "ms20", "ms25", "ms30", "ms35", "ms40", "ms45", "ms50", - "ms55", "ms60", "ms65", "ms70", "ms75", "ms80", "ms85", "ms90", "ms95", "ms100", "ms105", - "ms110", "ms115", "ms120", "ms125", "ms130", "ms135", "ms140", "ms145", "ms150", "ms155", "ms160", - "ms165", "ms170", "ms175", "ms180", "ms185", "ms190", "ms195", "ms200", "ms205", "ms210", "ms215", - "ms220", "ms225", "ms230", "ms235", "ms240", "ms245", "ms250", "ms300", "ms350", "ms400", "ms450", - "ms500", "ms800", "ms1000", "ms1200", "ms1600", "ms2000", "ms2400", "spare2", "spare1"}; - return convert_enum_idx(options, 64, value, "t_status_prohibit_e"); + HANDLE_CODE(pack_integer(bref, drb_id, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(pack_integer(bref, count_ul, (uint64_t)0u, (uint64_t)4294967295u)); + HANDLE_CODE(pack_integer(bref, count_dl, (uint64_t)0u, (uint64_t)4294967295u)); + + return SRSASN_SUCCESS; } -uint16_t t_status_prohibit_opts::to_number() const +SRSASN_CODE drb_count_info_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75, - 80, 85, 90, 95, 100, 105, 110, 115, 120, 125, 130, 135, 140, 145, 150, 155, - 160, 165, 170, 175, 180, 185, 190, 195, 200, 205, 210, 215, 220, 225, 230, 235, - 240, 245, 250, 300, 350, 400, 450, 500, 800, 1000, 1200, 1600, 2000, 2400}; - return map_enum_number(options, 62, value, "t_status_prohibit_e"); + HANDLE_CODE(unpack_integer(drb_id, bref, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(unpack_integer(count_ul, bref, (uint64_t)0u, (uint64_t)4294967295u)); + HANDLE_CODE(unpack_integer(count_dl, bref, (uint64_t)0u, (uint64_t)4294967295u)); + + return SRSASN_SUCCESS; +} +void drb_count_info_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("drb-Identity", drb_id); + j.write_int("count-Uplink", count_ul); + j.write_int("count-Downlink", count_dl); + j.end_obj(); } -// TDD-UL-DL-SlotConfig ::= SEQUENCE -SRSASN_CODE tdd_ul_dl_slot_cfg_s::pack(bit_ref& bref) const +// MeasResultSFTD-EUTRA ::= SEQUENCE +SRSASN_CODE meas_result_sftd_eutra_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, slot_idx, (uint16_t)0u, (uint16_t)319u)); - HANDLE_CODE(symbols.pack(bref)); + HANDLE_CODE(bref.pack(rsrp_result_present, 1)); + + HANDLE_CODE(pack_integer(bref, eutra_pci, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(pack_integer(bref, sfn_offset_result, (uint16_t)0u, (uint16_t)1023u)); + HANDLE_CODE(pack_integer(bref, frame_boundary_offset_result, (int16_t)-30720, (int16_t)30719)); + if (rsrp_result_present) { + HANDLE_CODE(pack_integer(bref, rsrp_result, (uint8_t)0u, (uint8_t)127u)); + } return SRSASN_SUCCESS; } -SRSASN_CODE tdd_ul_dl_slot_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_result_sftd_eutra_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(slot_idx, bref, (uint16_t)0u, (uint16_t)319u)); - HANDLE_CODE(symbols.unpack(bref)); + HANDLE_CODE(bref.unpack(rsrp_result_present, 1)); + + HANDLE_CODE(unpack_integer(eutra_pci, bref, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(unpack_integer(sfn_offset_result, bref, (uint16_t)0u, (uint16_t)1023u)); + HANDLE_CODE(unpack_integer(frame_boundary_offset_result, bref, (int16_t)-30720, (int16_t)30719)); + if (rsrp_result_present) { + HANDLE_CODE(unpack_integer(rsrp_result, bref, (uint8_t)0u, (uint8_t)127u)); + } return SRSASN_SUCCESS; } -void tdd_ul_dl_slot_cfg_s::to_json(json_writer& j) const +void meas_result_sftd_eutra_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("slotIndex", slot_idx); - j.write_fieldname("symbols"); - symbols.to_json(j); + j.write_int("eutra-PhysCellId", eutra_pci); + j.write_int("sfn-OffsetResult", sfn_offset_result); + j.write_int("frameBoundaryOffsetResult", frame_boundary_offset_result); + if (rsrp_result_present) { + j.write_int("rsrp-Result", rsrp_result); + } j.end_obj(); } -void tdd_ul_dl_slot_cfg_s::symbols_c_::set(types::options e) +// OverheatingAssistance ::= SEQUENCE +SRSASN_CODE overheat_assist_s::pack(bit_ref& bref) const { - type_ = e; + HANDLE_CODE(bref.pack(reduced_max_ccs_present, 1)); + HANDLE_CODE(bref.pack(reduced_max_bw_fr1_present, 1)); + HANDLE_CODE(bref.pack(reduced_max_bw_fr2_present, 1)); + HANDLE_CODE(bref.pack(reduced_max_mimo_layers_fr1_present, 1)); + HANDLE_CODE(bref.pack(reduced_max_mimo_layers_fr2_present, 1)); + + if (reduced_max_ccs_present) { + HANDLE_CODE(pack_integer(bref, reduced_max_ccs.reduced_ccs_dl, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(pack_integer(bref, reduced_max_ccs.reduced_ccs_ul, (uint8_t)0u, (uint8_t)31u)); + } + if (reduced_max_bw_fr1_present) { + HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_dl.pack(bref)); + HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_ul.pack(bref)); + } + if (reduced_max_bw_fr2_present) { + HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_dl.pack(bref)); + HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_ul.pack(bref)); + } + if (reduced_max_mimo_layers_fr1_present) { + HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_dl.pack(bref)); + HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_ul.pack(bref)); + } + if (reduced_max_mimo_layers_fr2_present) { + HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_dl.pack(bref)); + HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_ul.pack(bref)); + } + + return SRSASN_SUCCESS; } -void tdd_ul_dl_slot_cfg_s::symbols_c_::to_json(json_writer& j) const +SRSASN_CODE overheat_assist_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(reduced_max_ccs_present, 1)); + HANDLE_CODE(bref.unpack(reduced_max_bw_fr1_present, 1)); + HANDLE_CODE(bref.unpack(reduced_max_bw_fr2_present, 1)); + HANDLE_CODE(bref.unpack(reduced_max_mimo_layers_fr1_present, 1)); + HANDLE_CODE(bref.unpack(reduced_max_mimo_layers_fr2_present, 1)); + + if (reduced_max_ccs_present) { + HANDLE_CODE(unpack_integer(reduced_max_ccs.reduced_ccs_dl, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(unpack_integer(reduced_max_ccs.reduced_ccs_ul, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (reduced_max_bw_fr1_present) { + HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_dl.unpack(bref)); + HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_ul.unpack(bref)); + } + if (reduced_max_bw_fr2_present) { + HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_dl.unpack(bref)); + HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_ul.unpack(bref)); + } + if (reduced_max_mimo_layers_fr1_present) { + HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_dl.unpack(bref)); + HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_ul.unpack(bref)); + } + if (reduced_max_mimo_layers_fr2_present) { + HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_dl.unpack(bref)); + HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_ul.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void overheat_assist_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (reduced_max_ccs_present) { + j.write_fieldname("reducedMaxCCs"); + j.start_obj(); + j.write_int("reducedCCsDL", reduced_max_ccs.reduced_ccs_dl); + j.write_int("reducedCCsUL", reduced_max_ccs.reduced_ccs_ul); + j.end_obj(); + } + if (reduced_max_bw_fr1_present) { + j.write_fieldname("reducedMaxBW-FR1"); + j.start_obj(); + j.write_str("reducedBW-FR1-DL", reduced_max_bw_fr1.reduced_bw_fr1_dl.to_string()); + j.write_str("reducedBW-FR1-UL", reduced_max_bw_fr1.reduced_bw_fr1_ul.to_string()); + j.end_obj(); + } + if (reduced_max_bw_fr2_present) { + j.write_fieldname("reducedMaxBW-FR2"); + j.start_obj(); + j.write_str("reducedBW-FR2-DL", reduced_max_bw_fr2.reduced_bw_fr2_dl.to_string()); + j.write_str("reducedBW-FR2-UL", reduced_max_bw_fr2.reduced_bw_fr2_ul.to_string()); + j.end_obj(); + } + if (reduced_max_mimo_layers_fr1_present) { + j.write_fieldname("reducedMaxMIMO-LayersFR1"); + j.start_obj(); + j.write_str("reducedMIMO-LayersFR1-DL", reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_dl.to_string()); + j.write_str("reducedMIMO-LayersFR1-UL", reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_ul.to_string()); + j.end_obj(); + } + if (reduced_max_mimo_layers_fr2_present) { + j.write_fieldname("reducedMaxMIMO-LayersFR2"); + j.start_obj(); + j.write_str("reducedMIMO-LayersFR2-DL", reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_dl.to_string()); + j.write_str("reducedMIMO-LayersFR2-UL", reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_ul.to_string()); + j.end_obj(); + } + j.end_obj(); +} + +// RRCReconfigurationComplete-v1560-IEs ::= SEQUENCE +SRSASN_CODE rrc_recfg_complete_v1560_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(scg_resp_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (scg_resp_present) { + HANDLE_CODE(scg_resp.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_recfg_complete_v1560_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(scg_resp_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (scg_resp_present) { + HANDLE_CODE(scg_resp.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void rrc_recfg_complete_v1560_ies_s::to_json(json_writer& j) const { j.start_obj(); + if (scg_resp_present) { + j.write_fieldname("scg-Response"); + scg_resp.to_json(j); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); +} + +void rrc_recfg_complete_v1560_ies_s::scg_resp_c_::destroy_() +{ switch (type_) { - case types::all_dl: + case types::nr_scg_resp: + c.destroy(); break; - case types::all_ul: + case types::eutra_scg_resp: + c.destroy(); break; - case types::explicit_type: - j.write_fieldname("explicit"); - j.start_obj(); - if (c.nrof_dl_symbols_present) { - j.write_int("nrofDownlinkSymbols", c.nrof_dl_symbols); - } - if (c.nrof_ul_symbols_present) { - j.write_int("nrofUplinkSymbols", c.nrof_ul_symbols); - } - j.end_obj(); + default: + break; + } +} +void rrc_recfg_complete_v1560_ies_s::scg_resp_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::nr_scg_resp: + c.init(); + break; + case types::eutra_scg_resp: + c.init(); + break; + case types::nulltype: break; default: - log_invalid_choice_id(type_, "tdd_ul_dl_slot_cfg_s::symbols_c_"); + log_invalid_choice_id(type_, "rrc_recfg_complete_v1560_ies_s::scg_resp_c_"); + } +} +rrc_recfg_complete_v1560_ies_s::scg_resp_c_::scg_resp_c_(const rrc_recfg_complete_v1560_ies_s::scg_resp_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::nr_scg_resp: + c.init(other.c.get()); + break; + case types::eutra_scg_resp: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_recfg_complete_v1560_ies_s::scg_resp_c_"); + } +} +rrc_recfg_complete_v1560_ies_s::scg_resp_c_& +rrc_recfg_complete_v1560_ies_s::scg_resp_c_::operator=(const rrc_recfg_complete_v1560_ies_s::scg_resp_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::nr_scg_resp: + c.set(other.c.get()); + break; + case types::eutra_scg_resp: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_recfg_complete_v1560_ies_s::scg_resp_c_"); + } + + return *this; +} +void rrc_recfg_complete_v1560_ies_s::scg_resp_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::nr_scg_resp: + j.write_str("nr-SCG-Response", c.get().to_string()); + break; + case types::eutra_scg_resp: + j.write_str("eutra-SCG-Response", c.get().to_string()); + break; + default: + log_invalid_choice_id(type_, "rrc_recfg_complete_v1560_ies_s::scg_resp_c_"); } j.end_obj(); } -SRSASN_CODE tdd_ul_dl_slot_cfg_s::symbols_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_recfg_complete_v1560_ies_s::scg_resp_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::all_dl: - break; - case types::all_ul: + case types::nr_scg_resp: + HANDLE_CODE(c.get().pack(bref)); break; - case types::explicit_type: - HANDLE_CODE(bref.pack(c.nrof_dl_symbols_present, 1)); - HANDLE_CODE(bref.pack(c.nrof_ul_symbols_present, 1)); - if (c.nrof_dl_symbols_present) { - HANDLE_CODE(pack_integer(bref, c.nrof_dl_symbols, (uint8_t)1u, (uint8_t)13u)); - } - if (c.nrof_ul_symbols_present) { - HANDLE_CODE(pack_integer(bref, c.nrof_ul_symbols, (uint8_t)1u, (uint8_t)13u)); - } + case types::eutra_scg_resp: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "tdd_ul_dl_slot_cfg_s::symbols_c_"); + log_invalid_choice_id(type_, "rrc_recfg_complete_v1560_ies_s::scg_resp_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE tdd_ul_dl_slot_cfg_s::symbols_c_::unpack(cbit_ref& bref) +SRSASN_CODE rrc_recfg_complete_v1560_ies_s::scg_resp_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::all_dl: - break; - case types::all_ul: + case types::nr_scg_resp: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::explicit_type: - HANDLE_CODE(bref.unpack(c.nrof_dl_symbols_present, 1)); - HANDLE_CODE(bref.unpack(c.nrof_ul_symbols_present, 1)); - if (c.nrof_dl_symbols_present) { - HANDLE_CODE(unpack_integer(c.nrof_dl_symbols, bref, (uint8_t)1u, (uint8_t)13u)); - } - if (c.nrof_ul_symbols_present) { - HANDLE_CODE(unpack_integer(c.nrof_ul_symbols, bref, (uint8_t)1u, (uint8_t)13u)); - } + case types::eutra_scg_resp: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "tdd_ul_dl_slot_cfg_s::symbols_c_"); + log_invalid_choice_id(type_, "rrc_recfg_complete_v1560_ies_s::scg_resp_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string tdd_ul_dl_slot_cfg_s::symbols_c_::types_opts::to_string() const +std::string rrc_recfg_complete_v1560_ies_s::scg_resp_c_::types_opts::to_string() const { - static const char* options[] = {"allDownlink", "allUplink", "explicit"}; - return convert_enum_idx(options, 3, value, "tdd_ul_dl_slot_cfg_s::symbols_c_::types"); + static const char* options[] = {"nr-SCG-Response", "eutra-SCG-Response"}; + return convert_enum_idx(options, 2, value, "rrc_recfg_complete_v1560_ies_s::scg_resp_c_::types"); } -// UL-DataSplitThreshold ::= ENUMERATED -std::string ul_data_split_thres_opts::to_string() const +// UE-CapabilityRAT-Container ::= SEQUENCE +SRSASN_CODE ue_cap_rat_container_s::pack(bit_ref& bref) const { - static const char* options[] = {"b0", "b100", "b200", "b400", "b800", "b1600", "b3200", - "b6400", "b12800", "b25600", "b51200", "b102400", "b204800", "b409600", - "b819200", "b1228800", "b1638400", "b2457600", "b3276800", "b4096000", "b4915200", - "b5734400", "b6553600", "infinity", "spare8", "spare7", "spare6", "spare5", - "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 32, value, "ul_data_split_thres_e"); + HANDLE_CODE(rat_type.pack(bref)); + HANDLE_CODE(ue_cap_rat_container.pack(bref)); + + return SRSASN_SUCCESS; } -int32_t ul_data_split_thres_opts::to_number() const +SRSASN_CODE ue_cap_rat_container_s::unpack(cbit_ref& bref) { - static const int32_t options[] = {0, 100, 200, 400, 800, 1600, 3200, 6400, - 12800, 25600, 51200, 102400, 204800, 409600, 819200, 1228800, - 1638400, 2457600, 3276800, 4096000, 4915200, 5734400, 6553600, -1}; - return map_enum_number(options, 24, value, "ul_data_split_thres_e"); -} + HANDLE_CODE(rat_type.unpack(bref)); + HANDLE_CODE(ue_cap_rat_container.unpack(bref)); -// UplinkConfigCommon ::= SEQUENCE -SRSASN_CODE ul_cfg_common_s::pack(bit_ref& bref) const + return SRSASN_SUCCESS; +} +void ue_cap_rat_container_s::to_json(json_writer& j) const { - HANDLE_CODE(bref.pack(freq_info_ul_present, 1)); - HANDLE_CODE(bref.pack(init_ul_bwp_present, 1)); + j.start_obj(); + j.write_str("rat-Type", rat_type.to_string()); + j.write_str("ue-CapabilityRAT-Container", ue_cap_rat_container.to_string()); + j.end_obj(); +} - if (freq_info_ul_present) { - HANDLE_CODE(freq_info_ul.pack(bref)); - } - if (init_ul_bwp_present) { - HANDLE_CODE(init_ul_bwp.pack(bref)); +// DelayBudgetReport ::= CHOICE +void delay_budget_report_c::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_str("type1", c.to_string()); + j.end_obj(); +} +SRSASN_CODE delay_budget_report_c::pack(bit_ref& bref) const +{ + pack_enum(bref, type()); + HANDLE_CODE(c.pack(bref)); + return SRSASN_SUCCESS; +} +SRSASN_CODE delay_budget_report_c::unpack(cbit_ref& bref) +{ + types e; + unpack_enum(e, bref); + if (e != type()) { + log_invalid_choice_id(e, "delay_budget_report_c"); + return SRSASN_ERROR_DECODE_FAIL; } - HANDLE_CODE(dummy.pack(bref)); - + HANDLE_CODE(c.unpack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ul_cfg_common_s::unpack(cbit_ref& bref) + +std::string delay_budget_report_c::type1_opts::to_string() const { - HANDLE_CODE(bref.unpack(freq_info_ul_present, 1)); - HANDLE_CODE(bref.unpack(init_ul_bwp_present, 1)); + static const char* options[] = {"msMinus1280", + "msMinus640", + "msMinus320", + "msMinus160", + "msMinus80", + "msMinus60", + "msMinus40", + "msMinus20", + "ms0", + "ms20", + "ms40", + "ms60", + "ms80", + "ms160", + "ms320", + "ms640", + "ms1280"}; + return convert_enum_idx(options, 17, value, "delay_budget_report_c::type1_e_"); +} +int16_t delay_budget_report_c::type1_opts::to_number() const +{ + static const int16_t options[] = { + -1280, -640, -320, -160, -80, -60, -40, -20, 0, 20, 40, 60, 80, 160, 320, 640, 1280}; + return map_enum_number(options, 17, value, "delay_budget_report_c::type1_e_"); +} - if (freq_info_ul_present) { - HANDLE_CODE(freq_info_ul.unpack(bref)); - } - if (init_ul_bwp_present) { - HANDLE_CODE(init_ul_bwp.unpack(bref)); - } - HANDLE_CODE(dummy.unpack(bref)); +std::string delay_budget_report_c::types_opts::to_string() const +{ + static const char* options[] = {"type1"}; + return convert_enum_idx(options, 1, value, "delay_budget_report_c::types"); +} +uint8_t delay_budget_report_c::types_opts::to_number() const +{ + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "delay_budget_report_c::types"); +} + +// FailureInfoRLC-Bearer ::= SEQUENCE +SRSASN_CODE fail_info_rlc_bearer_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, cell_group_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pack_integer(bref, lc_ch_id, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(fail_type.pack(bref)); return SRSASN_SUCCESS; } -void ul_cfg_common_s::to_json(json_writer& j) const +SRSASN_CODE fail_info_rlc_bearer_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(cell_group_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(unpack_integer(lc_ch_id, bref, (uint8_t)1u, (uint8_t)32u)); + HANDLE_CODE(fail_type.unpack(bref)); + + return SRSASN_SUCCESS; +} +void fail_info_rlc_bearer_s::to_json(json_writer& j) const { j.start_obj(); - if (freq_info_ul_present) { - j.write_fieldname("frequencyInfoUL"); - freq_info_ul.to_json(j); - } - if (init_ul_bwp_present) { - j.write_fieldname("initialUplinkBWP"); - init_ul_bwp.to_json(j); - } - j.write_str("dummy", dummy.to_string()); + j.write_int("cellGroupId", cell_group_id); + j.write_int("logicalChannelIdentity", lc_ch_id); + j.write_str("failureType", fail_type.to_string()); j.end_obj(); } -// BWP-Downlink ::= SEQUENCE -SRSASN_CODE bwp_dl_s::pack(bit_ref& bref) const +std::string fail_info_rlc_bearer_s::fail_type_opts::to_string() const +{ + static const char* options[] = {"rlc-failure", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 4, value, "fail_info_rlc_bearer_s::fail_type_e_"); +} + +// FailureReportSCG ::= SEQUENCE +SRSASN_CODE fail_report_scg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(bwp_common_present, 1)); - HANDLE_CODE(bref.pack(bwp_ded_present, 1)); + HANDLE_CODE(bref.pack(meas_result_freq_list_present, 1)); + HANDLE_CODE(bref.pack(meas_result_scg_fail_present, 1)); - HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); - if (bwp_common_present) { - HANDLE_CODE(bwp_common.pack(bref)); + HANDLE_CODE(fail_type.pack(bref)); + if (meas_result_freq_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_freq_list, 1, 8)); } - if (bwp_ded_present) { - HANDLE_CODE(bwp_ded.pack(bref)); + if (meas_result_scg_fail_present) { + HANDLE_CODE(meas_result_scg_fail.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE bwp_dl_s::unpack(cbit_ref& bref) +SRSASN_CODE fail_report_scg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(bwp_common_present, 1)); - HANDLE_CODE(bref.unpack(bwp_ded_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_freq_list_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_scg_fail_present, 1)); - HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); - if (bwp_common_present) { - HANDLE_CODE(bwp_common.unpack(bref)); + HANDLE_CODE(fail_type.unpack(bref)); + if (meas_result_freq_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_result_freq_list, bref, 1, 8)); } - if (bwp_ded_present) { - HANDLE_CODE(bwp_ded.unpack(bref)); + if (meas_result_scg_fail_present) { + HANDLE_CODE(meas_result_scg_fail.unpack(bref)); } return SRSASN_SUCCESS; } -void bwp_dl_s::to_json(json_writer& j) const +void fail_report_scg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("bwp-Id", bwp_id); - if (bwp_common_present) { - j.write_fieldname("bwp-Common"); - bwp_common.to_json(j); + j.write_str("failureType", fail_type.to_string()); + if (meas_result_freq_list_present) { + j.start_array("measResultFreqList"); + for (const auto& e1 : meas_result_freq_list) { + e1.to_json(j); + } + j.end_array(); } - if (bwp_ded_present) { - j.write_fieldname("bwp-Dedicated"); - bwp_ded.to_json(j); + if (meas_result_scg_fail_present) { + j.write_str("measResultSCG-Failure", meas_result_scg_fail.to_string()); } j.end_obj(); } -// CSI-MeasConfig ::= SEQUENCE -SRSASN_CODE csi_meas_cfg_s::pack(bit_ref& bref) const +std::string fail_report_scg_s::fail_type_opts::to_string() const +{ + static const char* options[] = {"t310-Expiry", + "randomAccessProblem", + "rlc-MaxNumRetx", + "synchReconfigFailureSCG", + "scg-ReconfigFailure", + "srb3-IntegrityFailure", + "spare2", + "spare1"}; + return convert_enum_idx(options, 8, value, "fail_report_scg_s::fail_type_e_"); +} +uint16_t fail_report_scg_s::fail_type_opts::to_number() const +{ + switch (value) { + case t310_expiry: + return 310; + case srb3_integrity_fail: + return 3; + default: + invalid_enum_number(value, "fail_report_scg_s::fail_type_e_"); + } + return 0; +} + +// FailureReportSCG-EUTRA ::= SEQUENCE +SRSASN_CODE fail_report_scg_eutra_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(nzp_csi_rs_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(nzp_csi_rs_res_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(nzp_csi_rs_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(nzp_csi_rs_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(csi_im_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(csi_im_res_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(csi_im_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(csi_im_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(csi_ssb_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(csi_ssb_res_set_to_add_release_list_present, 1)); - HANDLE_CODE(bref.pack(csi_res_cfg_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(csi_res_cfg_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(csi_report_cfg_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(csi_report_cfg_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(report_trigger_size_present, 1)); - HANDLE_CODE(bref.pack(aperiodic_trigger_state_list_present, 1)); - HANDLE_CODE(bref.pack(semi_persistent_on_pusch_trigger_state_list_present, 1)); + HANDLE_CODE(bref.pack(meas_result_freq_list_mrdc_present, 1)); + HANDLE_CODE(bref.pack(meas_result_scg_fail_mrdc_present, 1)); - if (nzp_csi_rs_res_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_to_add_mod_list, 1, 192)); - } - if (nzp_csi_rs_res_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_to_release_list, 1, 192, integer_packer(0, 191))); - } - if (nzp_csi_rs_res_set_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_set_to_add_mod_list, 1, 64)); - } - if (nzp_csi_rs_res_set_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_set_to_release_list, 1, 64, integer_packer(0, 63))); - } - if (csi_im_res_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_to_add_mod_list, 1, 32)); - } - if (csi_im_res_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_to_release_list, 1, 32, integer_packer(0, 31))); - } - if (csi_im_res_set_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_set_to_add_mod_list, 1, 64)); - } - if (csi_im_res_set_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_set_to_release_list, 1, 64, integer_packer(0, 63))); - } - if (csi_ssb_res_set_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_ssb_res_set_to_add_mod_list, 1, 64)); - } - if (csi_ssb_res_set_to_add_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_ssb_res_set_to_add_release_list, 1, 64, integer_packer(0, 63))); - } - if (csi_res_cfg_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_res_cfg_to_add_mod_list, 1, 112)); - } - if (csi_res_cfg_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_res_cfg_to_release_list, 1, 112, integer_packer(0, 111))); - } - if (csi_report_cfg_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_report_cfg_to_add_mod_list, 1, 48)); - } - if (csi_report_cfg_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, csi_report_cfg_to_release_list, 1, 48, integer_packer(0, 47))); - } - if (report_trigger_size_present) { - HANDLE_CODE(pack_integer(bref, report_trigger_size, (uint8_t)0u, (uint8_t)6u)); - } - if (aperiodic_trigger_state_list_present) { - HANDLE_CODE(aperiodic_trigger_state_list.pack(bref)); + HANDLE_CODE(fail_type.pack(bref)); + if (meas_result_freq_list_mrdc_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_freq_list_mrdc, 1, 8)); } - if (semi_persistent_on_pusch_trigger_state_list_present) { - HANDLE_CODE(semi_persistent_on_pusch_trigger_state_list.pack(bref)); + if (meas_result_scg_fail_mrdc_present) { + HANDLE_CODE(meas_result_scg_fail_mrdc.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE csi_meas_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE fail_report_scg_eutra_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(nzp_csi_rs_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(nzp_csi_rs_res_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(nzp_csi_rs_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(nzp_csi_rs_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_im_res_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_im_res_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_im_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_im_res_set_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_ssb_res_set_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_ssb_res_set_to_add_release_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_res_cfg_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_res_cfg_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_report_cfg_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(csi_report_cfg_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(report_trigger_size_present, 1)); - HANDLE_CODE(bref.unpack(aperiodic_trigger_state_list_present, 1)); - HANDLE_CODE(bref.unpack(semi_persistent_on_pusch_trigger_state_list_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_freq_list_mrdc_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_scg_fail_mrdc_present, 1)); - if (nzp_csi_rs_res_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_to_add_mod_list, bref, 1, 192)); - } - if (nzp_csi_rs_res_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_to_release_list, bref, 1, 192, integer_packer(0, 191))); - } - if (nzp_csi_rs_res_set_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_set_to_add_mod_list, bref, 1, 64)); - } - if (nzp_csi_rs_res_set_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_set_to_release_list, bref, 1, 64, integer_packer(0, 63))); - } - if (csi_im_res_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_to_add_mod_list, bref, 1, 32)); - } - if (csi_im_res_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_to_release_list, bref, 1, 32, integer_packer(0, 31))); - } - if (csi_im_res_set_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_set_to_add_mod_list, bref, 1, 64)); - } - if (csi_im_res_set_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_set_to_release_list, bref, 1, 64, integer_packer(0, 63))); - } - if (csi_ssb_res_set_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_ssb_res_set_to_add_mod_list, bref, 1, 64)); - } - if (csi_ssb_res_set_to_add_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_ssb_res_set_to_add_release_list, bref, 1, 64, integer_packer(0, 63))); - } - if (csi_res_cfg_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_res_cfg_to_add_mod_list, bref, 1, 112)); - } - if (csi_res_cfg_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_res_cfg_to_release_list, bref, 1, 112, integer_packer(0, 111))); - } - if (csi_report_cfg_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_report_cfg_to_add_mod_list, bref, 1, 48)); - } - if (csi_report_cfg_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(csi_report_cfg_to_release_list, bref, 1, 48, integer_packer(0, 47))); - } - if (report_trigger_size_present) { - HANDLE_CODE(unpack_integer(report_trigger_size, bref, (uint8_t)0u, (uint8_t)6u)); - } - if (aperiodic_trigger_state_list_present) { - HANDLE_CODE(aperiodic_trigger_state_list.unpack(bref)); + HANDLE_CODE(fail_type.unpack(bref)); + if (meas_result_freq_list_mrdc_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_result_freq_list_mrdc, bref, 1, 8)); } - if (semi_persistent_on_pusch_trigger_state_list_present) { - HANDLE_CODE(semi_persistent_on_pusch_trigger_state_list.unpack(bref)); + if (meas_result_scg_fail_mrdc_present) { + HANDLE_CODE(meas_result_scg_fail_mrdc.unpack(bref)); } return SRSASN_SUCCESS; } -void csi_meas_cfg_s::to_json(json_writer& j) const +void fail_report_scg_eutra_s::to_json(json_writer& j) const { j.start_obj(); - if (nzp_csi_rs_res_to_add_mod_list_present) { - j.start_array("nzp-CSI-RS-ResourceToAddModList"); - for (const auto& e1 : nzp_csi_rs_res_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (nzp_csi_rs_res_to_release_list_present) { - j.start_array("nzp-CSI-RS-ResourceToReleaseList"); - for (const auto& e1 : nzp_csi_rs_res_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (nzp_csi_rs_res_set_to_add_mod_list_present) { - j.start_array("nzp-CSI-RS-ResourceSetToAddModList"); - for (const auto& e1 : nzp_csi_rs_res_set_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (nzp_csi_rs_res_set_to_release_list_present) { - j.start_array("nzp-CSI-RS-ResourceSetToReleaseList"); - for (const auto& e1 : nzp_csi_rs_res_set_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (csi_im_res_to_add_mod_list_present) { - j.start_array("csi-IM-ResourceToAddModList"); - for (const auto& e1 : csi_im_res_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (csi_im_res_to_release_list_present) { - j.start_array("csi-IM-ResourceToReleaseList"); - for (const auto& e1 : csi_im_res_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (csi_im_res_set_to_add_mod_list_present) { - j.start_array("csi-IM-ResourceSetToAddModList"); - for (const auto& e1 : csi_im_res_set_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (csi_im_res_set_to_release_list_present) { - j.start_array("csi-IM-ResourceSetToReleaseList"); - for (const auto& e1 : csi_im_res_set_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (csi_ssb_res_set_to_add_mod_list_present) { - j.start_array("csi-SSB-ResourceSetToAddModList"); - for (const auto& e1 : csi_ssb_res_set_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (csi_ssb_res_set_to_add_release_list_present) { - j.start_array("csi-SSB-ResourceSetToAddReleaseList"); - for (const auto& e1 : csi_ssb_res_set_to_add_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (csi_res_cfg_to_add_mod_list_present) { - j.start_array("csi-ResourceConfigToAddModList"); - for (const auto& e1 : csi_res_cfg_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (csi_res_cfg_to_release_list_present) { - j.start_array("csi-ResourceConfigToReleaseList"); - for (const auto& e1 : csi_res_cfg_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (csi_report_cfg_to_add_mod_list_present) { - j.start_array("csi-ReportConfigToAddModList"); - for (const auto& e1 : csi_report_cfg_to_add_mod_list) { + j.write_str("failureType", fail_type.to_string()); + if (meas_result_freq_list_mrdc_present) { + j.start_array("measResultFreqListMRDC"); + for (const auto& e1 : meas_result_freq_list_mrdc) { e1.to_json(j); } j.end_array(); } - if (csi_report_cfg_to_release_list_present) { - j.start_array("csi-ReportConfigToReleaseList"); - for (const auto& e1 : csi_report_cfg_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (report_trigger_size_present) { - j.write_int("reportTriggerSize", report_trigger_size); - } - if (aperiodic_trigger_state_list_present) { - j.write_fieldname("aperiodicTriggerStateList"); - aperiodic_trigger_state_list.to_json(j); - } - if (semi_persistent_on_pusch_trigger_state_list_present) { - j.write_fieldname("semiPersistentOnPUSCH-TriggerStateList"); - semi_persistent_on_pusch_trigger_state_list.to_json(j); + if (meas_result_scg_fail_mrdc_present) { + j.write_str("measResultSCG-FailureMRDC", meas_result_scg_fail_mrdc.to_string()); } j.end_obj(); } -// CipheringAlgorithm ::= ENUMERATED -std::string ciphering_algorithm_opts::to_string() const +std::string fail_report_scg_eutra_s::fail_type_opts::to_string() const { - static const char* options[] = {"nea0", "nea1", "nea2", "nea3", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 8, value, "ciphering_algorithm_e"); + static const char* options[] = {"t313-Expiry", + "randomAccessProblem", + "rlc-MaxNumRetx", + "scg-ChangeFailure", + "spare4", + "spare3", + "spare2", + "spare1"}; + return convert_enum_idx(options, 8, value, "fail_report_scg_eutra_s::fail_type_e_"); } -uint8_t ciphering_algorithm_opts::to_number() const +uint16_t fail_report_scg_eutra_s::fail_type_opts::to_number() const { - static const uint8_t options[] = {0, 1, 2, 3}; - return map_enum_number(options, 4, value, "ciphering_algorithm_e"); + static const uint16_t options[] = {313}; + return map_enum_number(options, 1, value, "fail_report_scg_eutra_s::fail_type_e_"); } -// CrossCarrierSchedulingConfig ::= SEQUENCE -SRSASN_CODE cross_carrier_sched_cfg_s::pack(bit_ref& bref) const +// LocationMeasurementInfo ::= CHOICE +void location_meas_info_c::set(types::options e) +{ + type_ = e; +} +void location_meas_info_c::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::eutra_rstd: + j.start_array("eutra-RSTD"); + for (const auto& e1 : c) { + e1.to_json(j); + } + j.end_array(); + break; + case types::eutra_fine_timing_detection: + break; + default: + log_invalid_choice_id(type_, "location_meas_info_c"); + } + j.end_obj(); +} +SRSASN_CODE location_meas_info_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::eutra_rstd: + HANDLE_CODE(pack_dyn_seq_of(bref, c, 1, 3)); + break; + case types::eutra_fine_timing_detection: + break; + default: + log_invalid_choice_id(type_, "location_meas_info_c"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE location_meas_info_c::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::eutra_rstd: + HANDLE_CODE(unpack_dyn_seq_of(c, bref, 1, 3)); + break; + case types::eutra_fine_timing_detection: + break; + default: + log_invalid_choice_id(type_, "location_meas_info_c"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string location_meas_info_c::types_opts::to_string() const +{ + static const char* options[] = {"eutra-RSTD", "eutra-FineTimingDetection"}; + return convert_enum_idx(options, 2, value, "location_meas_info_c::types"); +} + +// MeasResults ::= SEQUENCE +SRSASN_CODE meas_results_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(sched_cell_info.pack(bref)); + HANDLE_CODE(bref.pack(meas_result_neigh_cells_present, 1)); + + HANDLE_CODE(pack_integer(bref, meas_id, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_serving_mo_list, 1, 32)); + if (meas_result_neigh_cells_present) { + HANDLE_CODE(meas_result_neigh_cells.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= meas_result_serv_freq_list_eutra_scg.is_present(); + group_flags[0] |= meas_result_serv_freq_list_nr_scg.is_present(); + group_flags[0] |= meas_result_sftd_eutra.is_present(); + group_flags[0] |= meas_result_sftd_nr.is_present(); + group_flags[1] |= meas_result_cell_list_sftd_nr.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(meas_result_serv_freq_list_eutra_scg.is_present(), 1)); + HANDLE_CODE(bref.pack(meas_result_serv_freq_list_nr_scg.is_present(), 1)); + HANDLE_CODE(bref.pack(meas_result_sftd_eutra.is_present(), 1)); + HANDLE_CODE(bref.pack(meas_result_sftd_nr.is_present(), 1)); + if (meas_result_serv_freq_list_eutra_scg.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *meas_result_serv_freq_list_eutra_scg, 1, 32)); + } + if (meas_result_serv_freq_list_nr_scg.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *meas_result_serv_freq_list_nr_scg, 1, 32)); + } + if (meas_result_sftd_eutra.is_present()) { + HANDLE_CODE(meas_result_sftd_eutra->pack(bref)); + } + if (meas_result_sftd_nr.is_present()) { + HANDLE_CODE(meas_result_sftd_nr->pack(bref)); + } + } + if (group_flags[1]) { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(bref.pack(meas_result_cell_list_sftd_nr.is_present(), 1)); + if (meas_result_cell_list_sftd_nr.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *meas_result_cell_list_sftd_nr, 1, 3)); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE cross_carrier_sched_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_results_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(sched_cell_info.unpack(bref)); + HANDLE_CODE(bref.unpack(meas_result_neigh_cells_present, 1)); + + HANDLE_CODE(unpack_integer(meas_id, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_dyn_seq_of(meas_result_serving_mo_list, bref, 1, 32)); + if (meas_result_neigh_cells_present) { + HANDLE_CODE(meas_result_neigh_cells.unpack(bref)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(2); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool meas_result_serv_freq_list_eutra_scg_present; + HANDLE_CODE(bref.unpack(meas_result_serv_freq_list_eutra_scg_present, 1)); + meas_result_serv_freq_list_eutra_scg.set_present(meas_result_serv_freq_list_eutra_scg_present); + bool meas_result_serv_freq_list_nr_scg_present; + HANDLE_CODE(bref.unpack(meas_result_serv_freq_list_nr_scg_present, 1)); + meas_result_serv_freq_list_nr_scg.set_present(meas_result_serv_freq_list_nr_scg_present); + bool meas_result_sftd_eutra_present; + HANDLE_CODE(bref.unpack(meas_result_sftd_eutra_present, 1)); + meas_result_sftd_eutra.set_present(meas_result_sftd_eutra_present); + bool meas_result_sftd_nr_present; + HANDLE_CODE(bref.unpack(meas_result_sftd_nr_present, 1)); + meas_result_sftd_nr.set_present(meas_result_sftd_nr_present); + if (meas_result_serv_freq_list_eutra_scg.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*meas_result_serv_freq_list_eutra_scg, bref, 1, 32)); + } + if (meas_result_serv_freq_list_nr_scg.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*meas_result_serv_freq_list_nr_scg, bref, 1, 32)); + } + if (meas_result_sftd_eutra.is_present()) { + HANDLE_CODE(meas_result_sftd_eutra->unpack(bref)); + } + if (meas_result_sftd_nr.is_present()) { + HANDLE_CODE(meas_result_sftd_nr->unpack(bref)); + } + } + if (group_flags[1]) { + varlength_field_unpack_guard varlen_scope(bref, false); + bool meas_result_cell_list_sftd_nr_present; + HANDLE_CODE(bref.unpack(meas_result_cell_list_sftd_nr_present, 1)); + meas_result_cell_list_sftd_nr.set_present(meas_result_cell_list_sftd_nr_present); + if (meas_result_cell_list_sftd_nr.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*meas_result_cell_list_sftd_nr, bref, 1, 3)); + } + } + } return SRSASN_SUCCESS; } -void cross_carrier_sched_cfg_s::to_json(json_writer& j) const +void meas_results_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("schedulingCellInfo"); - sched_cell_info.to_json(j); + j.write_int("measId", meas_id); + j.start_array("measResultServingMOList"); + for (const auto& e1 : meas_result_serving_mo_list) { + e1.to_json(j); + } + j.end_array(); + if (meas_result_neigh_cells_present) { + j.write_fieldname("measResultNeighCells"); + meas_result_neigh_cells.to_json(j); + } + if (ext) { + if (meas_result_serv_freq_list_eutra_scg.is_present()) { + j.start_array("measResultServFreqListEUTRA-SCG"); + for (const auto& e1 : *meas_result_serv_freq_list_eutra_scg) { + e1.to_json(j); + } + j.end_array(); + } + if (meas_result_serv_freq_list_nr_scg.is_present()) { + j.start_array("measResultServFreqListNR-SCG"); + for (const auto& e1 : *meas_result_serv_freq_list_nr_scg) { + e1.to_json(j); + } + j.end_array(); + } + if (meas_result_sftd_eutra.is_present()) { + j.write_fieldname("measResultSFTD-EUTRA"); + meas_result_sftd_eutra->to_json(j); + } + if (meas_result_sftd_nr.is_present()) { + j.write_fieldname("measResultSFTD-NR"); + meas_result_sftd_nr->to_json(j); + } + if (meas_result_cell_list_sftd_nr.is_present()) { + j.start_array("measResultCellListSFTD-NR"); + for (const auto& e1 : *meas_result_cell_list_sftd_nr) { + e1.to_json(j); + } + j.end_array(); + } + } j.end_obj(); } -void cross_carrier_sched_cfg_s::sched_cell_info_c_::destroy_() +void meas_results_s::meas_result_neigh_cells_c_::destroy_() { switch (type_) { - case types::own: - c.destroy(); + case types::meas_result_list_nr: + c.destroy(); break; - case types::other: - c.destroy(); + case types::meas_result_list_eutra: + c.destroy(); break; default: break; } } -void cross_carrier_sched_cfg_s::sched_cell_info_c_::set(types::options e) +void meas_results_s::meas_result_neigh_cells_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::own: - c.init(); + case types::meas_result_list_nr: + c.init(); break; - case types::other: - c.init(); + case types::meas_result_list_eutra: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); } } -cross_carrier_sched_cfg_s::sched_cell_info_c_::sched_cell_info_c_( - const cross_carrier_sched_cfg_s::sched_cell_info_c_& other) +meas_results_s::meas_result_neigh_cells_c_::meas_result_neigh_cells_c_( + const meas_results_s::meas_result_neigh_cells_c_& other) { type_ = other.type(); switch (type_) { - case types::own: - c.init(other.c.get()); + case types::meas_result_list_nr: + c.init(other.c.get()); break; - case types::other: - c.init(other.c.get()); + case types::meas_result_list_eutra: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); } } -cross_carrier_sched_cfg_s::sched_cell_info_c_& cross_carrier_sched_cfg_s::sched_cell_info_c_:: - operator=(const cross_carrier_sched_cfg_s::sched_cell_info_c_& other) +meas_results_s::meas_result_neigh_cells_c_& +meas_results_s::meas_result_neigh_cells_c_::operator=(const meas_results_s::meas_result_neigh_cells_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::own: - c.set(other.c.get()); + case types::meas_result_list_nr: + c.set(other.c.get()); break; - case types::other: - c.set(other.c.get()); + case types::meas_result_list_eutra: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); } return *this; } -void cross_carrier_sched_cfg_s::sched_cell_info_c_::to_json(json_writer& j) const +void meas_results_s::meas_result_neigh_cells_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::own: - j.write_fieldname("own"); - j.start_obj(); - j.write_bool("cif-Presence", c.get().cif_presence); - j.end_obj(); + case types::meas_result_list_nr: + j.start_array("measResultListNR"); + for (const auto& e1 : c.get()) { + e1.to_json(j); + } + j.end_array(); break; - case types::other: - j.write_fieldname("other"); - j.start_obj(); - j.write_int("schedulingCellId", c.get().sched_cell_id); - j.write_int("cif-InSchedulingCell", c.get().cif_in_sched_cell); - j.end_obj(); + case types::meas_result_list_eutra: + j.start_array("measResultListEUTRA"); + for (const auto& e1 : c.get()) { + e1.to_json(j); + } + j.end_array(); break; default: - log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); } j.end_obj(); } -SRSASN_CODE cross_carrier_sched_cfg_s::sched_cell_info_c_::pack(bit_ref& bref) const +SRSASN_CODE meas_results_s::meas_result_neigh_cells_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::own: - HANDLE_CODE(bref.pack(c.get().cif_presence, 1)); - break; - case types::other: - HANDLE_CODE(pack_integer(bref, c.get().sched_cell_id, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(pack_integer(bref, c.get().cif_in_sched_cell, (uint8_t)1u, (uint8_t)7u)); + case types::meas_result_list_nr: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); break; + case types::meas_result_list_eutra: { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); + } break; default: - log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE cross_carrier_sched_cfg_s::sched_cell_info_c_::unpack(cbit_ref& bref) +SRSASN_CODE meas_results_s::meas_result_neigh_cells_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::own: - HANDLE_CODE(bref.unpack(c.get().cif_presence, 1)); - break; - case types::other: - HANDLE_CODE(unpack_integer(c.get().sched_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(unpack_integer(c.get().cif_in_sched_cell, bref, (uint8_t)1u, (uint8_t)7u)); + case types::meas_result_list_nr: + HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); break; + case types::meas_result_list_eutra: { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); + } break; default: - log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string cross_carrier_sched_cfg_s::sched_cell_info_c_::types_opts::to_string() const +std::string meas_results_s::meas_result_neigh_cells_c_::types_opts::to_string() const { - static const char* options[] = {"own", "other"}; - return convert_enum_idx(options, 2, value, "cross_carrier_sched_cfg_s::sched_cell_info_c_::types"); + static const char* options[] = {"measResultListNR", "measResultListEUTRA"}; + return convert_enum_idx(options, 2, value, "meas_results_s::meas_result_neigh_cells_c_::types"); } -// DL-AM-RLC ::= SEQUENCE -SRSASN_CODE dl_am_rlc_s::pack(bit_ref& bref) const +// RRCReconfigurationComplete-v1530-IEs ::= SEQUENCE +SRSASN_CODE rrc_recfg_complete_v1530_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(sn_field_len_present, 1)); + HANDLE_CODE(bref.pack(ul_tx_direct_current_list_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.pack(bref)); + if (ul_tx_direct_current_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ul_tx_direct_current_list, 1, 32)); } - HANDLE_CODE(t_reassembly.pack(bref)); - HANDLE_CODE(t_status_prohibit.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE dl_am_rlc_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); - - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.unpack(bref)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } - HANDLE_CODE(t_reassembly.unpack(bref)); - HANDLE_CODE(t_status_prohibit.unpack(bref)); return SRSASN_SUCCESS; } -void dl_am_rlc_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (sn_field_len_present) { - j.write_str("sn-FieldLength", sn_field_len.to_string()); - } - j.write_str("t-Reassembly", t_reassembly.to_string()); - j.write_str("t-StatusProhibit", t_status_prohibit.to_string()); - j.end_obj(); -} - -// DL-UM-RLC ::= SEQUENCE -SRSASN_CODE dl_um_rlc_s::pack(bit_ref& bref) const +SRSASN_CODE rrc_recfg_complete_v1530_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.pack(sn_field_len_present, 1)); + HANDLE_CODE(bref.unpack(ul_tx_direct_current_list_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.pack(bref)); + if (ul_tx_direct_current_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ul_tx_direct_current_list, bref, 1, 32)); } - HANDLE_CODE(t_reassembly.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE dl_um_rlc_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); - - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.unpack(bref)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } - HANDLE_CODE(t_reassembly.unpack(bref)); return SRSASN_SUCCESS; } -void dl_um_rlc_s::to_json(json_writer& j) const +void rrc_recfg_complete_v1530_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (sn_field_len_present) { - j.write_str("sn-FieldLength", sn_field_len.to_string()); - } - j.write_str("t-Reassembly", t_reassembly.to_string()); - j.end_obj(); -} - -// IntegrityProtAlgorithm ::= ENUMERATED -std::string integrity_prot_algorithm_opts::to_string() const -{ - static const char* options[] = {"nia0", "nia1", "nia2", "nia3", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 8, value, "integrity_prot_algorithm_e"); -} -uint8_t integrity_prot_algorithm_opts::to_number() const -{ - static const uint8_t options[] = {0, 1, 2, 3}; - return map_enum_number(options, 4, value, "integrity_prot_algorithm_e"); -} - -// PDCCH-ServingCellConfig ::= SEQUENCE -SRSASN_CODE pdcch_serving_cell_cfg_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(slot_format_ind_present, 1)); - - if (slot_format_ind_present) { - HANDLE_CODE(slot_format_ind.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE pdcch_serving_cell_cfg_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(slot_format_ind_present, 1)); - - if (slot_format_ind_present) { - HANDLE_CODE(slot_format_ind.unpack(bref)); + if (ul_tx_direct_current_list_present) { + j.start_array("uplinkTxDirectCurrentList"); + for (const auto& e1 : ul_tx_direct_current_list) { + e1.to_json(j); + } + j.end_array(); } - - return SRSASN_SUCCESS; -} -void pdcch_serving_cell_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (slot_format_ind_present) { - j.write_fieldname("slotFormatIndicator"); - slot_format_ind.to_json(j); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } j.end_obj(); } -// PDCP-Config ::= SEQUENCE -SRSASN_CODE pdcp_cfg_s::pack(bit_ref& bref) const +// RegisteredAMF ::= SEQUENCE +SRSASN_CODE registered_amf_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(drb_present, 1)); - HANDLE_CODE(bref.pack(more_than_one_rlc_present, 1)); - HANDLE_CODE(bref.pack(t_reordering_present, 1)); + HANDLE_CODE(bref.pack(plmn_id_present, 1)); - if (drb_present) { - HANDLE_CODE(bref.pack(drb.discard_timer_present, 1)); - HANDLE_CODE(bref.pack(drb.pdcp_sn_size_ul_present, 1)); - HANDLE_CODE(bref.pack(drb.pdcp_sn_size_dl_present, 1)); - HANDLE_CODE(bref.pack(drb.integrity_protection_present, 1)); - HANDLE_CODE(bref.pack(drb.status_report_required_present, 1)); - HANDLE_CODE(bref.pack(drb.out_of_order_delivery_present, 1)); - if (drb.discard_timer_present) { - HANDLE_CODE(drb.discard_timer.pack(bref)); - } - if (drb.pdcp_sn_size_ul_present) { - HANDLE_CODE(drb.pdcp_sn_size_ul.pack(bref)); - } - if (drb.pdcp_sn_size_dl_present) { - HANDLE_CODE(drb.pdcp_sn_size_dl.pack(bref)); - } - HANDLE_CODE(drb.hdr_compress.pack(bref)); - } - if (more_than_one_rlc_present) { - HANDLE_CODE(bref.pack(more_than_one_rlc.ul_data_split_thres_present, 1)); - HANDLE_CODE(bref.pack(more_than_one_rlc.pdcp_dupl_present, 1)); - HANDLE_CODE(bref.pack(more_than_one_rlc.primary_path.cell_group_present, 1)); - HANDLE_CODE(bref.pack(more_than_one_rlc.primary_path.lc_ch_present, 1)); - if (more_than_one_rlc.primary_path.cell_group_present) { - HANDLE_CODE(pack_integer(bref, more_than_one_rlc.primary_path.cell_group, (uint8_t)0u, (uint8_t)3u)); - } - if (more_than_one_rlc.primary_path.lc_ch_present) { - HANDLE_CODE(pack_integer(bref, more_than_one_rlc.primary_path.lc_ch, (uint8_t)1u, (uint8_t)32u)); - } - if (more_than_one_rlc.ul_data_split_thres_present) { - HANDLE_CODE(more_than_one_rlc.ul_data_split_thres.pack(bref)); - } - if (more_than_one_rlc.pdcp_dupl_present) { - HANDLE_CODE(bref.pack(more_than_one_rlc.pdcp_dupl, 1)); - } - } - if (t_reordering_present) { - HANDLE_CODE(t_reordering.pack(bref)); + if (plmn_id_present) { + HANDLE_CODE(plmn_id.pack(bref)); } + HANDLE_CODE(amf_id.pack(bref)); - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= ciphering_disabled_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(ciphering_disabled_present, 1)); - } - } return SRSASN_SUCCESS; } -SRSASN_CODE pdcp_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE registered_amf_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(drb_present, 1)); - HANDLE_CODE(bref.unpack(more_than_one_rlc_present, 1)); - HANDLE_CODE(bref.unpack(t_reordering_present, 1)); + HANDLE_CODE(bref.unpack(plmn_id_present, 1)); - if (drb_present) { - HANDLE_CODE(bref.unpack(drb.discard_timer_present, 1)); - HANDLE_CODE(bref.unpack(drb.pdcp_sn_size_ul_present, 1)); - HANDLE_CODE(bref.unpack(drb.pdcp_sn_size_dl_present, 1)); - HANDLE_CODE(bref.unpack(drb.integrity_protection_present, 1)); - HANDLE_CODE(bref.unpack(drb.status_report_required_present, 1)); - HANDLE_CODE(bref.unpack(drb.out_of_order_delivery_present, 1)); - if (drb.discard_timer_present) { - HANDLE_CODE(drb.discard_timer.unpack(bref)); - } - if (drb.pdcp_sn_size_ul_present) { - HANDLE_CODE(drb.pdcp_sn_size_ul.unpack(bref)); - } - if (drb.pdcp_sn_size_dl_present) { - HANDLE_CODE(drb.pdcp_sn_size_dl.unpack(bref)); - } - HANDLE_CODE(drb.hdr_compress.unpack(bref)); - } - if (more_than_one_rlc_present) { - HANDLE_CODE(bref.unpack(more_than_one_rlc.ul_data_split_thres_present, 1)); - HANDLE_CODE(bref.unpack(more_than_one_rlc.pdcp_dupl_present, 1)); - HANDLE_CODE(bref.unpack(more_than_one_rlc.primary_path.cell_group_present, 1)); - HANDLE_CODE(bref.unpack(more_than_one_rlc.primary_path.lc_ch_present, 1)); - if (more_than_one_rlc.primary_path.cell_group_present) { - HANDLE_CODE(unpack_integer(more_than_one_rlc.primary_path.cell_group, bref, (uint8_t)0u, (uint8_t)3u)); - } - if (more_than_one_rlc.primary_path.lc_ch_present) { - HANDLE_CODE(unpack_integer(more_than_one_rlc.primary_path.lc_ch, bref, (uint8_t)1u, (uint8_t)32u)); - } - if (more_than_one_rlc.ul_data_split_thres_present) { - HANDLE_CODE(more_than_one_rlc.ul_data_split_thres.unpack(bref)); - } - if (more_than_one_rlc.pdcp_dupl_present) { - HANDLE_CODE(bref.unpack(more_than_one_rlc.pdcp_dupl, 1)); - } - } - if (t_reordering_present) { - HANDLE_CODE(t_reordering.unpack(bref)); + if (plmn_id_present) { + HANDLE_CODE(plmn_id.unpack(bref)); } + HANDLE_CODE(amf_id.unpack(bref)); - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(ciphering_disabled_present, 1)); - } - } return SRSASN_SUCCESS; } -void pdcp_cfg_s::to_json(json_writer& j) const +void registered_amf_s::to_json(json_writer& j) const { j.start_obj(); - if (drb_present) { - j.write_fieldname("drb"); - j.start_obj(); - if (drb.discard_timer_present) { - j.write_str("discardTimer", drb.discard_timer.to_string()); - } - if (drb.pdcp_sn_size_ul_present) { - j.write_str("pdcp-SN-SizeUL", drb.pdcp_sn_size_ul.to_string()); - } - if (drb.pdcp_sn_size_dl_present) { - j.write_str("pdcp-SN-SizeDL", drb.pdcp_sn_size_dl.to_string()); - } - j.write_fieldname("headerCompression"); - drb.hdr_compress.to_json(j); - if (drb.integrity_protection_present) { - j.write_str("integrityProtection", "enabled"); - } - if (drb.status_report_required_present) { - j.write_str("statusReportRequired", "true"); - } - if (drb.out_of_order_delivery_present) { - j.write_str("outOfOrderDelivery", "true"); - } - j.end_obj(); - } - if (more_than_one_rlc_present) { - j.write_fieldname("moreThanOneRLC"); - j.start_obj(); - j.write_fieldname("primaryPath"); - j.start_obj(); - if (more_than_one_rlc.primary_path.cell_group_present) { - j.write_int("cellGroup", more_than_one_rlc.primary_path.cell_group); - } - if (more_than_one_rlc.primary_path.lc_ch_present) { - j.write_int("logicalChannel", more_than_one_rlc.primary_path.lc_ch); - } - j.end_obj(); - if (more_than_one_rlc.ul_data_split_thres_present) { - j.write_str("ul-DataSplitThreshold", more_than_one_rlc.ul_data_split_thres.to_string()); - } - if (more_than_one_rlc.pdcp_dupl_present) { - j.write_bool("pdcp-Duplication", more_than_one_rlc.pdcp_dupl); - } - j.end_obj(); - } - if (t_reordering_present) { - j.write_str("t-Reordering", t_reordering.to_string()); - } - if (ext) { - if (ciphering_disabled_present) { - j.write_str("cipheringDisabled", "true"); - } + if (plmn_id_present) { + j.write_fieldname("plmn-Identity"); + plmn_id.to_json(j); } + j.write_str("amf-Identifier", amf_id.to_string()); j.end_obj(); } -std::string pdcp_cfg_s::drb_s_::discard_timer_opts::to_string() const -{ - static const char* options[] = {"ms10", - "ms20", - "ms30", - "ms40", - "ms50", - "ms60", - "ms75", - "ms100", - "ms150", - "ms200", - "ms250", - "ms300", - "ms500", - "ms750", - "ms1500", - "infinity"}; - return convert_enum_idx(options, 16, value, "pdcp_cfg_s::drb_s_::discard_timer_e_"); -} -int16_t pdcp_cfg_s::drb_s_::discard_timer_opts::to_number() const -{ - static const int16_t options[] = {10, 20, 30, 40, 50, 60, 75, 100, 150, 200, 250, 300, 500, 750, 1500, -1}; - return map_enum_number(options, 16, value, "pdcp_cfg_s::drb_s_::discard_timer_e_"); -} - -std::string pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_opts::to_string() const -{ - static const char* options[] = {"len12bits", "len18bits"}; - return convert_enum_idx(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_e_"); -} -uint8_t pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_opts::to_number() const -{ - static const uint8_t options[] = {12, 18}; - return map_enum_number(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_ul_e_"); -} - -std::string pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_opts::to_string() const -{ - static const char* options[] = {"len12bits", "len18bits"}; - return convert_enum_idx(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_e_"); -} -uint8_t pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_opts::to_number() const -{ - static const uint8_t options[] = {12, 18}; - return map_enum_number(options, 2, value, "pdcp_cfg_s::drb_s_::pdcp_sn_size_dl_e_"); -} - -void pdcp_cfg_s::drb_s_::hdr_compress_c_::destroy_() +// S-NSSAI ::= CHOICE +void s_nssai_c::destroy_() { switch (type_) { - case types::rohc: - c.destroy(); + case types::sst: + c.destroy >(); break; - case types::ul_only_rohc: - c.destroy(); + case types::sst_sd: + c.destroy >(); break; default: break; } } -void pdcp_cfg_s::drb_s_::hdr_compress_c_::set(types::options e) +void s_nssai_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::not_used: - break; - case types::rohc: - c.init(); + case types::sst: + c.init >(); break; - case types::ul_only_rohc: - c.init(); + case types::sst_sd: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + log_invalid_choice_id(type_, "s_nssai_c"); } } -pdcp_cfg_s::drb_s_::hdr_compress_c_::hdr_compress_c_(const pdcp_cfg_s::drb_s_::hdr_compress_c_& other) +s_nssai_c::s_nssai_c(const s_nssai_c& other) { type_ = other.type(); switch (type_) { - case types::not_used: - break; - case types::rohc: - c.init(other.c.get()); + case types::sst: + c.init(other.c.get >()); break; - case types::ul_only_rohc: - c.init(other.c.get()); + case types::sst_sd: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + log_invalid_choice_id(type_, "s_nssai_c"); } } -pdcp_cfg_s::drb_s_::hdr_compress_c_& pdcp_cfg_s::drb_s_::hdr_compress_c_:: - operator=(const pdcp_cfg_s::drb_s_::hdr_compress_c_& other) +s_nssai_c& s_nssai_c::operator=(const s_nssai_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::not_used: - break; - case types::rohc: - c.set(other.c.get()); + case types::sst: + c.set(other.c.get >()); break; - case types::ul_only_rohc: - c.set(other.c.get()); + case types::sst_sd: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + log_invalid_choice_id(type_, "s_nssai_c"); } return *this; } -void pdcp_cfg_s::drb_s_::hdr_compress_c_::to_json(json_writer& j) const +void s_nssai_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::not_used: - break; - case types::rohc: - j.write_fieldname("rohc"); - j.start_obj(); - if (c.get().max_cid_present) { - j.write_int("maxCID", c.get().max_cid); - } - j.write_fieldname("profiles"); - j.start_obj(); - j.write_bool("profile0x0001", c.get().profiles.profile0x0001); - j.write_bool("profile0x0002", c.get().profiles.profile0x0002); - j.write_bool("profile0x0003", c.get().profiles.profile0x0003); - j.write_bool("profile0x0004", c.get().profiles.profile0x0004); - j.write_bool("profile0x0006", c.get().profiles.profile0x0006); - j.write_bool("profile0x0101", c.get().profiles.profile0x0101); - j.write_bool("profile0x0102", c.get().profiles.profile0x0102); - j.write_bool("profile0x0103", c.get().profiles.profile0x0103); - j.write_bool("profile0x0104", c.get().profiles.profile0x0104); - j.end_obj(); - if (c.get().drb_continue_rohc_present) { - j.write_str("drb-ContinueROHC", "true"); - } - j.end_obj(); + case types::sst: + j.write_str("sst", c.get >().to_string()); break; - case types::ul_only_rohc: - j.write_fieldname("uplinkOnlyROHC"); - j.start_obj(); - if (c.get().max_cid_present) { - j.write_int("maxCID", c.get().max_cid); - } - j.write_fieldname("profiles"); - j.start_obj(); - j.write_bool("profile0x0006", c.get().profiles.profile0x0006); - j.end_obj(); - if (c.get().drb_continue_rohc_present) { - j.write_str("drb-ContinueROHC", "true"); - } - j.end_obj(); + case types::sst_sd: + j.write_str("sst-SD", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + log_invalid_choice_id(type_, "s_nssai_c"); } j.end_obj(); } -SRSASN_CODE pdcp_cfg_s::drb_s_::hdr_compress_c_::pack(bit_ref& bref) const +SRSASN_CODE s_nssai_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::not_used: - break; - case types::rohc: - HANDLE_CODE(bref.pack(c.get().max_cid_present, 1)); - HANDLE_CODE(bref.pack(c.get().drb_continue_rohc_present, 1)); - if (c.get().max_cid_present) { - HANDLE_CODE(pack_integer(bref, c.get().max_cid, (uint16_t)1u, (uint16_t)16383u)); - } - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0001, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0002, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0003, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0004, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0006, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0101, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0102, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0103, 1)); - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0104, 1)); + case types::sst: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::ul_only_rohc: - HANDLE_CODE(bref.pack(c.get().max_cid_present, 1)); - HANDLE_CODE(bref.pack(c.get().drb_continue_rohc_present, 1)); - if (c.get().max_cid_present) { - HANDLE_CODE(pack_integer(bref, c.get().max_cid, (uint16_t)1u, (uint16_t)16383u)); - } - HANDLE_CODE(bref.pack(c.get().profiles.profile0x0006, 1)); + case types::sst_sd: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + log_invalid_choice_id(type_, "s_nssai_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE pdcp_cfg_s::drb_s_::hdr_compress_c_::unpack(cbit_ref& bref) +SRSASN_CODE s_nssai_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::not_used: - break; - case types::rohc: - HANDLE_CODE(bref.unpack(c.get().max_cid_present, 1)); - HANDLE_CODE(bref.unpack(c.get().drb_continue_rohc_present, 1)); - if (c.get().max_cid_present) { - HANDLE_CODE(unpack_integer(c.get().max_cid, bref, (uint16_t)1u, (uint16_t)16383u)); - } - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0001, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0002, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0003, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0004, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0006, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0101, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0102, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0103, 1)); - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0104, 1)); + case types::sst: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::ul_only_rohc: - HANDLE_CODE(bref.unpack(c.get().max_cid_present, 1)); - HANDLE_CODE(bref.unpack(c.get().drb_continue_rohc_present, 1)); - if (c.get().max_cid_present) { - HANDLE_CODE(unpack_integer(c.get().max_cid, bref, (uint16_t)1u, (uint16_t)16383u)); - } - HANDLE_CODE(bref.unpack(c.get().profiles.profile0x0006, 1)); + case types::sst_sd: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "pdcp_cfg_s::drb_s_::hdr_compress_c_"); + log_invalid_choice_id(type_, "s_nssai_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string pdcp_cfg_s::drb_s_::hdr_compress_c_::types_opts::to_string() const +std::string s_nssai_c::types_opts::to_string() const { - static const char* options[] = {"notUsed", "rohc", "uplinkOnlyROHC"}; - return convert_enum_idx(options, 3, value, "pdcp_cfg_s::drb_s_::hdr_compress_c_::types"); + static const char* options[] = {"sst", "sst-SD"}; + return convert_enum_idx(options, 2, value, "s_nssai_c::types"); } -std::string pdcp_cfg_s::t_reordering_opts::to_string() const -{ - static const char* options[] = { - "ms0", "ms1", "ms2", "ms4", "ms5", "ms8", "ms10", "ms15", "ms20", "ms30", - "ms40", "ms50", "ms60", "ms80", "ms100", "ms120", "ms140", "ms160", "ms180", "ms200", - "ms220", "ms240", "ms260", "ms280", "ms300", "ms500", "ms750", "ms1000", "ms1250", "ms1500", - "ms1750", "ms2000", "ms2250", "ms2500", "ms2750", "ms3000", "spare28", "spare27", "spare26", "spare25", - "spare24", "spare23", "spare22", "spare21", "spare20", "spare19", "spare18", "spare17", "spare16", "spare15", - "spare14", "spare13", "spare12", "spare11", "spare10", "spare09", "spare08", "spare07", "spare06", "spare05", - "spare04", "spare03", "spare02", "spare01"}; - return convert_enum_idx(options, 64, value, "pdcp_cfg_s::t_reordering_e_"); -} -uint16_t pdcp_cfg_s::t_reordering_opts::to_number() const +// SCGFailureInformation-v1590-IEs ::= SEQUENCE +SRSASN_CODE scg_fail_info_v1590_ies_s::pack(bit_ref& bref) const { - static const uint16_t options[] = {0, 1, 2, 4, 5, 8, 10, 15, 20, 30, 40, 50, - 60, 80, 100, 120, 140, 160, 180, 200, 220, 240, 260, 280, - 300, 500, 750, 1000, 1250, 1500, 1750, 2000, 2250, 2500, 2750, 3000}; - return map_enum_number(options, 36, value, "pdcp_cfg_s::t_reordering_e_"); -} + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); -// PDSCH-ServingCellConfig ::= SEQUENCE -SRSASN_CODE pdsch_serving_cell_cfg_s::pack(bit_ref& bref) const + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE scg_fail_info_v1590_ies_s::unpack(cbit_ref& bref) { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(code_block_group_tx_present, 1)); - HANDLE_CODE(bref.pack(xoverhead_present, 1)); - HANDLE_CODE(bref.pack(nrof_harq_processes_for_pdsch_present, 1)); - HANDLE_CODE(bref.pack(pucch_cell_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (code_block_group_tx_present) { - HANDLE_CODE(code_block_group_tx.pack(bref)); - } - if (xoverhead_present) { - HANDLE_CODE(xoverhead.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - if (nrof_harq_processes_for_pdsch_present) { - HANDLE_CODE(nrof_harq_processes_for_pdsch.pack(bref)); + + return SRSASN_SUCCESS; +} +void scg_fail_info_v1590_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (pucch_cell_present) { - HANDLE_CODE(pack_integer(bref, pucch_cell, (uint8_t)0u, (uint8_t)31u)); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } + j.end_obj(); +} - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= max_mimo_layers_present; - group_flags[0] |= processing_type2_enabled_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); +// SCGFailureInformationEUTRA-v1590-IEs ::= SEQUENCE +SRSASN_CODE scg_fail_info_eutra_v1590_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(max_mimo_layers_present, 1)); - HANDLE_CODE(bref.pack(processing_type2_enabled_present, 1)); - if (max_mimo_layers_present) { - HANDLE_CODE(pack_integer(bref, max_mimo_layers, (uint8_t)1u, (uint8_t)8u)); - } - if (processing_type2_enabled_present) { - HANDLE_CODE(bref.pack(processing_type2_enabled, 1)); - } - } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } + return SRSASN_SUCCESS; } -SRSASN_CODE pdsch_serving_cell_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE scg_fail_info_eutra_v1590_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(code_block_group_tx_present, 1)); - HANDLE_CODE(bref.unpack(xoverhead_present, 1)); - HANDLE_CODE(bref.unpack(nrof_harq_processes_for_pdsch_present, 1)); - HANDLE_CODE(bref.unpack(pucch_cell_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (code_block_group_tx_present) { - HANDLE_CODE(code_block_group_tx.unpack(bref)); - } - if (xoverhead_present) { - HANDLE_CODE(xoverhead.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - if (nrof_harq_processes_for_pdsch_present) { - HANDLE_CODE(nrof_harq_processes_for_pdsch.unpack(bref)); + + return SRSASN_SUCCESS; +} +void scg_fail_info_eutra_v1590_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (pucch_cell_present) { - HANDLE_CODE(unpack_integer(pucch_cell, bref, (uint8_t)0u, (uint8_t)31u)); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } + j.end_obj(); +} - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); +// UEAssistanceInformation-v1540-IEs ::= SEQUENCE +SRSASN_CODE ueassist_info_v1540_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(overheat_assist_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + if (overheat_assist_present) { + HANDLE_CODE(overheat_assist.pack(bref)); + } - HANDLE_CODE(bref.unpack(max_mimo_layers_present, 1)); - HANDLE_CODE(bref.unpack(processing_type2_enabled_present, 1)); - if (max_mimo_layers_present) { - HANDLE_CODE(unpack_integer(max_mimo_layers, bref, (uint8_t)1u, (uint8_t)8u)); - } - if (processing_type2_enabled_present) { - HANDLE_CODE(bref.unpack(processing_type2_enabled, 1)); - } - } + return SRSASN_SUCCESS; +} +SRSASN_CODE ueassist_info_v1540_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(overheat_assist_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (overheat_assist_present) { + HANDLE_CODE(overheat_assist.unpack(bref)); } + return SRSASN_SUCCESS; } -void pdsch_serving_cell_cfg_s::to_json(json_writer& j) const +void ueassist_info_v1540_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (code_block_group_tx_present) { - j.write_fieldname("codeBlockGroupTransmission"); - code_block_group_tx.to_json(j); - } - if (xoverhead_present) { - j.write_str("xOverhead", xoverhead.to_string()); - } - if (nrof_harq_processes_for_pdsch_present) { - j.write_str("nrofHARQ-ProcessesForPDSCH", nrof_harq_processes_for_pdsch.to_string()); - } - if (pucch_cell_present) { - j.write_int("pucch-Cell", pucch_cell); + if (overheat_assist_present) { + j.write_fieldname("overheatingAssistance"); + overheat_assist.to_json(j); } - if (ext) { - if (max_mimo_layers_present) { - j.write_int("maxMIMO-Layers", max_mimo_layers); - } - if (processing_type2_enabled_present) { - j.write_bool("processingType2Enabled", processing_type2_enabled); - } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -std::string pdsch_serving_cell_cfg_s::xoverhead_opts::to_string() const +// CounterCheckResponse-IEs ::= SEQUENCE +SRSASN_CODE counter_check_resp_ies_s::pack(bit_ref& bref) const { - static const char* options[] = {"xOh6", "xOh12", "xOh18"}; - return convert_enum_idx(options, 3, value, "pdsch_serving_cell_cfg_s::xoverhead_e_"); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + HANDLE_CODE(pack_dyn_seq_of(bref, drb_count_info_list, 0, 29)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t pdsch_serving_cell_cfg_s::xoverhead_opts::to_number() const +SRSASN_CODE counter_check_resp_ies_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {6, 12, 18}; - return map_enum_number(options, 3, value, "pdsch_serving_cell_cfg_s::xoverhead_e_"); -} + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); -std::string pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_opts::to_string() const -{ - static const char* options[] = {"n2", "n4", "n6", "n10", "n12", "n16"}; - return convert_enum_idx(options, 6, value, "pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_e_"); + HANDLE_CODE(unpack_dyn_seq_of(drb_count_info_list, bref, 0, 29)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_opts::to_number() const +void counter_check_resp_ies_s::to_json(json_writer& j) const { - static const uint8_t options[] = {2, 4, 6, 10, 12, 16}; - return map_enum_number(options, 6, value, "pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_e_"); + j.start_obj(); + j.start_array("drb-CountInfoList"); + for (const auto& e1 : drb_count_info_list) { + e1.to_json(j); + } + j.end_array(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); } -// RACH-ConfigDedicated ::= SEQUENCE -SRSASN_CODE rach_cfg_ded_s::pack(bit_ref& bref) const +// FailureInformation-IEs ::= SEQUENCE +SRSASN_CODE fail_info_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(cfra_present, 1)); - HANDLE_CODE(bref.pack(ra_prioritization_present, 1)); + HANDLE_CODE(bref.pack(fail_info_rlc_bearer_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (cfra_present) { - HANDLE_CODE(cfra.pack(bref)); + if (fail_info_rlc_bearer_present) { + HANDLE_CODE(fail_info_rlc_bearer.pack(bref)); } - if (ra_prioritization_present) { - HANDLE_CODE(ra_prioritization.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE rach_cfg_ded_s::unpack(cbit_ref& bref) +SRSASN_CODE fail_info_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(cfra_present, 1)); - HANDLE_CODE(bref.unpack(ra_prioritization_present, 1)); + HANDLE_CODE(bref.unpack(fail_info_rlc_bearer_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (cfra_present) { - HANDLE_CODE(cfra.unpack(bref)); + if (fail_info_rlc_bearer_present) { + HANDLE_CODE(fail_info_rlc_bearer.unpack(bref)); } - if (ra_prioritization_present) { - HANDLE_CODE(ra_prioritization.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void rach_cfg_ded_s::to_json(json_writer& j) const +void fail_info_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (cfra_present) { - j.write_fieldname("cfra"); - cfra.to_json(j); + if (fail_info_rlc_bearer_present) { + j.write_fieldname("failureInfoRLC-Bearer"); + fail_info_rlc_bearer.to_json(j); } - if (ra_prioritization_present) { - j.write_fieldname("ra-Prioritization"); - ra_prioritization.to_json(j); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -// SDAP-Config ::= SEQUENCE -SRSASN_CODE sdap_cfg_s::pack(bit_ref& bref) const +// LocationMeasurementIndication-IEs ::= SEQUENCE +SRSASN_CODE location_meas_ind_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(mapped_qos_flows_to_add_present, 1)); - HANDLE_CODE(bref.pack(mapped_qos_flows_to_release_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - HANDLE_CODE(pack_integer(bref, pdu_session, (uint16_t)0u, (uint16_t)255u)); - HANDLE_CODE(sdap_hdr_dl.pack(bref)); - HANDLE_CODE(sdap_hdr_ul.pack(bref)); - HANDLE_CODE(bref.pack(default_drb, 1)); - if (mapped_qos_flows_to_add_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, mapped_qos_flows_to_add, 1, 64, integer_packer(0, 63))); - } - if (mapped_qos_flows_to_release_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, mapped_qos_flows_to_release, 1, 64, integer_packer(0, 63))); + HANDLE_CODE(meas_ind.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE sdap_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE location_meas_ind_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(mapped_qos_flows_to_add_present, 1)); - HANDLE_CODE(bref.unpack(mapped_qos_flows_to_release_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - HANDLE_CODE(unpack_integer(pdu_session, bref, (uint16_t)0u, (uint16_t)255u)); - HANDLE_CODE(sdap_hdr_dl.unpack(bref)); - HANDLE_CODE(sdap_hdr_ul.unpack(bref)); - HANDLE_CODE(bref.unpack(default_drb, 1)); - if (mapped_qos_flows_to_add_present) { - HANDLE_CODE(unpack_dyn_seq_of(mapped_qos_flows_to_add, bref, 1, 64, integer_packer(0, 63))); - } - if (mapped_qos_flows_to_release_present) { - HANDLE_CODE(unpack_dyn_seq_of(mapped_qos_flows_to_release, bref, 1, 64, integer_packer(0, 63))); + HANDLE_CODE(meas_ind.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void sdap_cfg_s::to_json(json_writer& j) const +void location_meas_ind_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("pdu-Session", pdu_session); - j.write_str("sdap-HeaderDL", sdap_hdr_dl.to_string()); - j.write_str("sdap-HeaderUL", sdap_hdr_ul.to_string()); - j.write_bool("defaultDRB", default_drb); - if (mapped_qos_flows_to_add_present) { - j.start_array("mappedQoS-FlowsToAdd"); - for (const auto& e1 : mapped_qos_flows_to_add) { - j.write_int(e1); - } - j.end_array(); + j.write_fieldname("measurementIndication"); + meas_ind.to_json(j); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (mapped_qos_flows_to_release_present) { - j.start_array("mappedQoS-FlowsToRelease"); - for (const auto& e1 : mapped_qos_flows_to_release) { - j.write_int(e1); - } - j.end_array(); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -std::string sdap_cfg_s::sdap_hdr_dl_opts::to_string() const +// MeasurementReport-IEs ::= SEQUENCE +SRSASN_CODE meas_report_ies_s::pack(bit_ref& bref) const { - static const char* options[] = {"present", "absent"}; - return convert_enum_idx(options, 2, value, "sdap_cfg_s::sdap_hdr_dl_e_"); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + HANDLE_CODE(meas_results.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; } +SRSASN_CODE meas_report_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); -std::string sdap_cfg_s::sdap_hdr_ul_opts::to_string() const + HANDLE_CODE(meas_results.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void meas_report_ies_s::to_json(json_writer& j) const { - static const char* options[] = {"present", "absent"}; - return convert_enum_idx(options, 2, value, "sdap_cfg_s::sdap_hdr_ul_e_"); + j.start_obj(); + j.write_fieldname("measResults"); + meas_results.to_json(j); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); } -// SchedulingRequestToAddMod ::= SEQUENCE -SRSASN_CODE sched_request_to_add_mod_s::pack(bit_ref& bref) const +// RRCReconfigurationComplete-IEs ::= SEQUENCE +SRSASN_CODE rrc_recfg_complete_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(sr_prohibit_timer_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - HANDLE_CODE(pack_integer(bref, sched_request_id, (uint8_t)0u, (uint8_t)7u)); - if (sr_prohibit_timer_present) { - HANDLE_CODE(sr_prohibit_timer.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } - HANDLE_CODE(sr_trans_max.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE sched_request_to_add_mod_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_recfg_complete_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(sr_prohibit_timer_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - HANDLE_CODE(unpack_integer(sched_request_id, bref, (uint8_t)0u, (uint8_t)7u)); - if (sr_prohibit_timer_present) { - HANDLE_CODE(sr_prohibit_timer.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } - HANDLE_CODE(sr_trans_max.unpack(bref)); return SRSASN_SUCCESS; } -void sched_request_to_add_mod_s::to_json(json_writer& j) const +void rrc_recfg_complete_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("schedulingRequestId", sched_request_id); - if (sr_prohibit_timer_present) { - j.write_str("sr-ProhibitTimer", sr_prohibit_timer.to_string()); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } - j.write_str("sr-TransMax", sr_trans_max.to_string()); j.end_obj(); } -std::string sched_request_to_add_mod_s::sr_prohibit_timer_opts::to_string() const +// RRCReestablishmentComplete-IEs ::= SEQUENCE +SRSASN_CODE rrc_reest_complete_ies_s::pack(bit_ref& bref) const { - static const char* options[] = {"ms1", "ms2", "ms4", "ms8", "ms16", "ms32", "ms64", "ms128"}; - return convert_enum_idx(options, 8, value, "sched_request_to_add_mod_s::sr_prohibit_timer_e_"); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t sched_request_to_add_mod_s::sr_prohibit_timer_opts::to_number() const +SRSASN_CODE rrc_reest_complete_ies_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {1, 2, 4, 8, 16, 32, 64, 128}; - return map_enum_number(options, 8, value, "sched_request_to_add_mod_s::sr_prohibit_timer_e_"); -} + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); -std::string sched_request_to_add_mod_s::sr_trans_max_opts::to_string() const -{ - static const char* options[] = {"n4", "n8", "n16", "n32", "n64", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 8, value, "sched_request_to_add_mod_s::sr_trans_max_e_"); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t sched_request_to_add_mod_s::sr_trans_max_opts::to_number() const +void rrc_reest_complete_ies_s::to_json(json_writer& j) const { - static const uint8_t options[] = {4, 8, 16, 32, 64}; - return map_enum_number(options, 5, value, "sched_request_to_add_mod_s::sr_trans_max_e_"); + j.start_obj(); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); } -// ServingCellConfigCommon ::= SEQUENCE -SRSASN_CODE serving_cell_cfg_common_s::pack(bit_ref& bref) const +// RRCResumeComplete-IEs ::= SEQUENCE +SRSASN_CODE rrc_resume_complete_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(pci_present, 1)); - HANDLE_CODE(bref.pack(dl_cfg_common_present, 1)); - HANDLE_CODE(bref.pack(ul_cfg_common_present, 1)); - HANDLE_CODE(bref.pack(supplementary_ul_cfg_present, 1)); - HANDLE_CODE(bref.pack(n_timing_advance_offset_present, 1)); - HANDLE_CODE(bref.pack(ssb_positions_in_burst_present, 1)); - HANDLE_CODE(bref.pack(ssb_periodicity_serving_cell_present, 1)); - HANDLE_CODE(bref.pack(lte_crs_to_match_around_present, 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(ssb_subcarrier_spacing_present, 1)); - HANDLE_CODE(bref.pack(tdd_ul_dl_cfg_common_present, 1)); + HANDLE_CODE(bref.pack(ded_nas_msg_present, 1)); + HANDLE_CODE(bref.pack(sel_plmn_id_present, 1)); + HANDLE_CODE(bref.pack(ul_tx_direct_current_list_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (pci_present) { - HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); - } - if (dl_cfg_common_present) { - HANDLE_CODE(dl_cfg_common.pack(bref)); - } - if (ul_cfg_common_present) { - HANDLE_CODE(ul_cfg_common.pack(bref)); - } - if (supplementary_ul_cfg_present) { - HANDLE_CODE(supplementary_ul_cfg.pack(bref)); - } - if (n_timing_advance_offset_present) { - HANDLE_CODE(n_timing_advance_offset.pack(bref)); + if (ded_nas_msg_present) { + HANDLE_CODE(ded_nas_msg.pack(bref)); } - if (ssb_positions_in_burst_present) { - HANDLE_CODE(ssb_positions_in_burst.pack(bref)); + if (sel_plmn_id_present) { + HANDLE_CODE(pack_integer(bref, sel_plmn_id, (uint8_t)1u, (uint8_t)12u)); } - if (ssb_periodicity_serving_cell_present) { - HANDLE_CODE(ssb_periodicity_serving_cell.pack(bref)); + if (ul_tx_direct_current_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ul_tx_direct_current_list, 1, 32)); } - HANDLE_CODE(dmrs_type_a_position.pack(bref)); - if (lte_crs_to_match_around_present) { - HANDLE_CODE(lte_crs_to_match_around.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } - if (rate_match_pattern_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_add_mod_list, 1, 4)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_resume_complete_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(ded_nas_msg_present, 1)); + HANDLE_CODE(bref.unpack(sel_plmn_id_present, 1)); + HANDLE_CODE(bref.unpack(ul_tx_direct_current_list_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (ded_nas_msg_present) { + HANDLE_CODE(ded_nas_msg.unpack(bref)); } - if (rate_match_pattern_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_release_list, 1, 4, integer_packer(0, 3))); + if (sel_plmn_id_present) { + HANDLE_CODE(unpack_integer(sel_plmn_id, bref, (uint8_t)1u, (uint8_t)12u)); } - if (ssb_subcarrier_spacing_present) { - HANDLE_CODE(ssb_subcarrier_spacing.pack(bref)); + if (ul_tx_direct_current_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ul_tx_direct_current_list, bref, 1, 32)); } - if (tdd_ul_dl_cfg_common_present) { - HANDLE_CODE(tdd_ul_dl_cfg_common.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - HANDLE_CODE(pack_integer(bref, ss_pbch_block_pwr, (int8_t)-60, (int8_t)50)); return SRSASN_SUCCESS; } -SRSASN_CODE serving_cell_cfg_common_s::unpack(cbit_ref& bref) +void rrc_resume_complete_ies_s::to_json(json_writer& j) const { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(pci_present, 1)); - HANDLE_CODE(bref.unpack(dl_cfg_common_present, 1)); - HANDLE_CODE(bref.unpack(ul_cfg_common_present, 1)); - HANDLE_CODE(bref.unpack(supplementary_ul_cfg_present, 1)); - HANDLE_CODE(bref.unpack(n_timing_advance_offset_present, 1)); - HANDLE_CODE(bref.unpack(ssb_positions_in_burst_present, 1)); - HANDLE_CODE(bref.unpack(ssb_periodicity_serving_cell_present, 1)); - HANDLE_CODE(bref.unpack(lte_crs_to_match_around_present, 1)); - HANDLE_CODE(bref.unpack(rate_match_pattern_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(rate_match_pattern_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(ssb_subcarrier_spacing_present, 1)); - HANDLE_CODE(bref.unpack(tdd_ul_dl_cfg_common_present, 1)); - - if (pci_present) { - HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); - } - if (dl_cfg_common_present) { - HANDLE_CODE(dl_cfg_common.unpack(bref)); - } - if (ul_cfg_common_present) { - HANDLE_CODE(ul_cfg_common.unpack(bref)); + j.start_obj(); + if (ded_nas_msg_present) { + j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); } - if (supplementary_ul_cfg_present) { - HANDLE_CODE(supplementary_ul_cfg.unpack(bref)); + if (sel_plmn_id_present) { + j.write_int("selectedPLMN-Identity", sel_plmn_id); } - if (n_timing_advance_offset_present) { - HANDLE_CODE(n_timing_advance_offset.unpack(bref)); + if (ul_tx_direct_current_list_present) { + j.start_array("uplinkTxDirectCurrentList"); + for (const auto& e1 : ul_tx_direct_current_list) { + e1.to_json(j); + } + j.end_array(); } - if (ssb_positions_in_burst_present) { - HANDLE_CODE(ssb_positions_in_burst.unpack(bref)); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (ssb_periodicity_serving_cell_present) { - HANDLE_CODE(ssb_periodicity_serving_cell.unpack(bref)); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } - HANDLE_CODE(dmrs_type_a_position.unpack(bref)); - if (lte_crs_to_match_around_present) { - HANDLE_CODE(lte_crs_to_match_around.unpack(bref)); + j.end_obj(); +} + +// RRCSetupComplete-IEs ::= SEQUENCE +SRSASN_CODE rrc_setup_complete_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(registered_amf_present, 1)); + HANDLE_CODE(bref.pack(guami_type_present, 1)); + HANDLE_CODE(bref.pack(s_nssai_list_present, 1)); + HANDLE_CODE(bref.pack(ng_minus5_g_s_tmsi_value_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + HANDLE_CODE(pack_integer(bref, sel_plmn_id, (uint8_t)1u, (uint8_t)12u)); + if (registered_amf_present) { + HANDLE_CODE(registered_amf.pack(bref)); } - if (rate_match_pattern_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_add_mod_list, bref, 1, 4)); + if (guami_type_present) { + HANDLE_CODE(guami_type.pack(bref)); } - if (rate_match_pattern_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_release_list, bref, 1, 4, integer_packer(0, 3))); + if (s_nssai_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, s_nssai_list, 1, 8)); } - if (ssb_subcarrier_spacing_present) { - HANDLE_CODE(ssb_subcarrier_spacing.unpack(bref)); + HANDLE_CODE(ded_nas_msg.pack(bref)); + if (ng_minus5_g_s_tmsi_value_present) { + HANDLE_CODE(ng_minus5_g_s_tmsi_value.pack(bref)); } - if (tdd_ul_dl_cfg_common_present) { - HANDLE_CODE(tdd_ul_dl_cfg_common.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } - HANDLE_CODE(unpack_integer(ss_pbch_block_pwr, bref, (int8_t)-60, (int8_t)50)); return SRSASN_SUCCESS; } -void serving_cell_cfg_common_s::to_json(json_writer& j) const +SRSASN_CODE rrc_setup_complete_ies_s::unpack(cbit_ref& bref) { - j.start_obj(); - if (pci_present) { - j.write_int("physCellId", pci); - } - if (dl_cfg_common_present) { - j.write_fieldname("downlinkConfigCommon"); - dl_cfg_common.to_json(j); + HANDLE_CODE(bref.unpack(registered_amf_present, 1)); + HANDLE_CODE(bref.unpack(guami_type_present, 1)); + HANDLE_CODE(bref.unpack(s_nssai_list_present, 1)); + HANDLE_CODE(bref.unpack(ng_minus5_g_s_tmsi_value_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + HANDLE_CODE(unpack_integer(sel_plmn_id, bref, (uint8_t)1u, (uint8_t)12u)); + if (registered_amf_present) { + HANDLE_CODE(registered_amf.unpack(bref)); } - if (ul_cfg_common_present) { - j.write_fieldname("uplinkConfigCommon"); - ul_cfg_common.to_json(j); + if (guami_type_present) { + HANDLE_CODE(guami_type.unpack(bref)); } - if (supplementary_ul_cfg_present) { - j.write_fieldname("supplementaryUplinkConfig"); - supplementary_ul_cfg.to_json(j); + if (s_nssai_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(s_nssai_list, bref, 1, 8)); } - if (n_timing_advance_offset_present) { - j.write_str("n-TimingAdvanceOffset", n_timing_advance_offset.to_string()); + HANDLE_CODE(ded_nas_msg.unpack(bref)); + if (ng_minus5_g_s_tmsi_value_present) { + HANDLE_CODE(ng_minus5_g_s_tmsi_value.unpack(bref)); } - if (ssb_positions_in_burst_present) { - j.write_fieldname("ssb-PositionsInBurst"); - ssb_positions_in_burst.to_json(j); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - if (ssb_periodicity_serving_cell_present) { - j.write_str("ssb-periodicityServingCell", ssb_periodicity_serving_cell.to_string()); + + return SRSASN_SUCCESS; +} +void rrc_setup_complete_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("selectedPLMN-Identity", sel_plmn_id); + if (registered_amf_present) { + j.write_fieldname("registeredAMF"); + registered_amf.to_json(j); } - j.write_str("dmrs-TypeA-Position", dmrs_type_a_position.to_string()); - if (lte_crs_to_match_around_present) { - j.write_fieldname("lte-CRS-ToMatchAround"); - lte_crs_to_match_around.to_json(j); + if (guami_type_present) { + j.write_str("guami-Type", guami_type.to_string()); } - if (rate_match_pattern_to_add_mod_list_present) { - j.start_array("rateMatchPatternToAddModList"); - for (const auto& e1 : rate_match_pattern_to_add_mod_list) { + if (s_nssai_list_present) { + j.start_array("s-NSSAI-List"); + for (const auto& e1 : s_nssai_list) { e1.to_json(j); } j.end_array(); } - if (rate_match_pattern_to_release_list_present) { - j.start_array("rateMatchPatternToReleaseList"); - for (const auto& e1 : rate_match_pattern_to_release_list) { - j.write_int(e1); - } - j.end_array(); + j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); + if (ng_minus5_g_s_tmsi_value_present) { + j.write_fieldname("ng-5G-S-TMSI-Value"); + ng_minus5_g_s_tmsi_value.to_json(j); } - if (ssb_subcarrier_spacing_present) { - j.write_str("ssbSubcarrierSpacing", ssb_subcarrier_spacing.to_string()); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (tdd_ul_dl_cfg_common_present) { - j.write_fieldname("tdd-UL-DL-ConfigurationCommon"); - tdd_ul_dl_cfg_common.to_json(j); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } - j.write_int("ss-PBCH-BlockPower", ss_pbch_block_pwr); j.end_obj(); } -std::string serving_cell_cfg_common_s::n_timing_advance_offset_opts::to_string() const -{ - static const char* options[] = {"n0", "n25600", "n39936"}; - return convert_enum_idx(options, 3, value, "serving_cell_cfg_common_s::n_timing_advance_offset_e_"); -} -uint16_t serving_cell_cfg_common_s::n_timing_advance_offset_opts::to_number() const +std::string rrc_setup_complete_ies_s::guami_type_opts::to_string() const { - static const uint16_t options[] = {0, 25600, 39936}; - return map_enum_number(options, 3, value, "serving_cell_cfg_common_s::n_timing_advance_offset_e_"); + static const char* options[] = {"native", "mapped"}; + return convert_enum_idx(options, 2, value, "rrc_setup_complete_ies_s::guami_type_e_"); } -void serving_cell_cfg_common_s::ssb_positions_in_burst_c_::destroy_() +void rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::destroy_() { switch (type_) { - case types::short_bitmap: - c.destroy >(); - break; - case types::medium_bitmap: - c.destroy >(); + case types::ng_minus5_g_s_tmsi: + c.destroy >(); break; - case types::long_bitmap: - c.destroy >(); + case types::ng_minus5_g_s_tmsi_part2: + c.destroy >(); break; default: break; } } -void serving_cell_cfg_common_s::ssb_positions_in_burst_c_::set(types::options e) +void rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::short_bitmap: - c.init >(); - break; - case types::medium_bitmap: - c.init >(); + case types::ng_minus5_g_s_tmsi: + c.init >(); break; - case types::long_bitmap: - c.init >(); + case types::ng_minus5_g_s_tmsi_part2: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); + log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); } } -serving_cell_cfg_common_s::ssb_positions_in_burst_c_::ssb_positions_in_burst_c_( - const serving_cell_cfg_common_s::ssb_positions_in_burst_c_& other) +rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::ng_minus5_g_s_tmsi_value_c_( + const rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_& other) { type_ = other.type(); switch (type_) { - case types::short_bitmap: - c.init(other.c.get >()); - break; - case types::medium_bitmap: - c.init(other.c.get >()); + case types::ng_minus5_g_s_tmsi: + c.init(other.c.get >()); break; - case types::long_bitmap: - c.init(other.c.get >()); + case types::ng_minus5_g_s_tmsi_part2: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); + log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); } } -serving_cell_cfg_common_s::ssb_positions_in_burst_c_& serving_cell_cfg_common_s::ssb_positions_in_burst_c_:: - operator=(const serving_cell_cfg_common_s::ssb_positions_in_burst_c_& other) +rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_& rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::operator=( + const rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::short_bitmap: - c.set(other.c.get >()); - break; - case types::medium_bitmap: - c.set(other.c.get >()); + case types::ng_minus5_g_s_tmsi: + c.set(other.c.get >()); break; - case types::long_bitmap: - c.set(other.c.get >()); + case types::ng_minus5_g_s_tmsi_part2: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); + log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); } return *this; } -void serving_cell_cfg_common_s::ssb_positions_in_burst_c_::to_json(json_writer& j) const +void rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::short_bitmap: - j.write_str("shortBitmap", c.get >().to_string()); - break; - case types::medium_bitmap: - j.write_str("mediumBitmap", c.get >().to_string()); + case types::ng_minus5_g_s_tmsi: + j.write_str("ng-5G-S-TMSI", c.get >().to_string()); break; - case types::long_bitmap: - j.write_str("longBitmap", c.get >().to_string()); + case types::ng_minus5_g_s_tmsi_part2: + j.write_str("ng-5G-S-TMSI-Part2", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); + log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); } j.end_obj(); } -SRSASN_CODE serving_cell_cfg_common_s::ssb_positions_in_burst_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::short_bitmap: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::medium_bitmap: - HANDLE_CODE(c.get >().pack(bref)); + case types::ng_minus5_g_s_tmsi: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::long_bitmap: - HANDLE_CODE(c.get >().pack(bref)); + case types::ng_minus5_g_s_tmsi_part2: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); + log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE serving_cell_cfg_common_s::ssb_positions_in_burst_c_::unpack(cbit_ref& bref) +SRSASN_CODE rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::short_bitmap: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::medium_bitmap: - HANDLE_CODE(c.get >().unpack(bref)); + case types::ng_minus5_g_s_tmsi: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::long_bitmap: - HANDLE_CODE(c.get >().unpack(bref)); + case types::ng_minus5_g_s_tmsi_part2: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); + log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string serving_cell_cfg_common_s::ssb_positions_in_burst_c_::types_opts::to_string() const -{ - static const char* options[] = {"shortBitmap", "mediumBitmap", "longBitmap"}; - return convert_enum_idx(options, 3, value, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_::types"); -} - -std::string serving_cell_cfg_common_s::ssb_periodicity_serving_cell_opts::to_string() const -{ - static const char* options[] = {"ms5", "ms10", "ms20", "ms40", "ms80", "ms160", "spare2", "spare1"}; - return convert_enum_idx(options, 8, value, "serving_cell_cfg_common_s::ssb_periodicity_serving_cell_e_"); -} -uint8_t serving_cell_cfg_common_s::ssb_periodicity_serving_cell_opts::to_number() const +std::string rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::types_opts::to_string() const { - static const uint8_t options[] = {5, 10, 20, 40, 80, 160}; - return map_enum_number(options, 6, value, "serving_cell_cfg_common_s::ssb_periodicity_serving_cell_e_"); + static const char* options[] = {"ng-5G-S-TMSI", "ng-5G-S-TMSI-Part2"}; + return convert_enum_idx(options, 2, value, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::types"); } -std::string serving_cell_cfg_common_s::dmrs_type_a_position_opts::to_string() const -{ - static const char* options[] = {"pos2", "pos3"}; - return convert_enum_idx(options, 2, value, "serving_cell_cfg_common_s::dmrs_type_a_position_e_"); -} -uint8_t serving_cell_cfg_common_s::dmrs_type_a_position_opts::to_number() const +// SCGFailureInformation-IEs ::= SEQUENCE +SRSASN_CODE scg_fail_info_ies_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {2, 3}; - return map_enum_number(options, 2, value, "serving_cell_cfg_common_s::dmrs_type_a_position_e_"); -} + HANDLE_CODE(bref.pack(fail_report_scg_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); -// TAG ::= SEQUENCE -SRSASN_CODE tag_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, tag_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(time_align_timer.pack(bref)); + if (fail_report_scg_present) { + HANDLE_CODE(fail_report_scg.pack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE tag_s::unpack(cbit_ref& bref) +SRSASN_CODE scg_fail_info_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(tag_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(time_align_timer.unpack(bref)); + HANDLE_CODE(bref.unpack(fail_report_scg_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (fail_report_scg_present) { + HANDLE_CODE(fail_report_scg.unpack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } return SRSASN_SUCCESS; } -void tag_s::to_json(json_writer& j) const +void scg_fail_info_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("tag-Id", tag_id); - j.write_str("timeAlignmentTimer", time_align_timer.to_string()); + if (fail_report_scg_present) { + j.write_fieldname("failureReportSCG"); + fail_report_scg.to_json(j); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); + } j.end_obj(); } -// TDD-UL-DL-ConfigDedicated ::= SEQUENCE -SRSASN_CODE tdd_ul_dl_cfg_ded_s::pack(bit_ref& bref) const +// SCGFailureInformationEUTRA-IEs ::= SEQUENCE +SRSASN_CODE scg_fail_info_eutra_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(slot_specific_cfgs_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(slot_specific_cfgs_torelease_list_present, 1)); + HANDLE_CODE(bref.pack(fail_report_scg_eutra_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (slot_specific_cfgs_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, slot_specific_cfgs_to_add_mod_list, 1, 320)); + if (fail_report_scg_eutra_present) { + HANDLE_CODE(fail_report_scg_eutra.pack(bref)); } - if (slot_specific_cfgs_torelease_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, slot_specific_cfgs_torelease_list, 1, 320, integer_packer(0, 319))); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE tdd_ul_dl_cfg_ded_s::unpack(cbit_ref& bref) +SRSASN_CODE scg_fail_info_eutra_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(slot_specific_cfgs_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(slot_specific_cfgs_torelease_list_present, 1)); + HANDLE_CODE(bref.unpack(fail_report_scg_eutra_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (slot_specific_cfgs_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(slot_specific_cfgs_to_add_mod_list, bref, 1, 320)); + if (fail_report_scg_eutra_present) { + HANDLE_CODE(fail_report_scg_eutra.unpack(bref)); } - if (slot_specific_cfgs_torelease_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(slot_specific_cfgs_torelease_list, bref, 1, 320, integer_packer(0, 319))); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void tdd_ul_dl_cfg_ded_s::to_json(json_writer& j) const +void scg_fail_info_eutra_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (slot_specific_cfgs_to_add_mod_list_present) { - j.start_array("slotSpecificConfigurationsToAddModList"); - for (const auto& e1 : slot_specific_cfgs_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); + if (fail_report_scg_eutra_present) { + j.write_fieldname("failureReportSCG-EUTRA"); + fail_report_scg_eutra.to_json(j); } - if (slot_specific_cfgs_torelease_list_present) { - j.start_array("slotSpecificConfigurationsToreleaseList"); - for (const auto& e1 : slot_specific_cfgs_torelease_list) { - j.write_int(e1); - } - j.end_array(); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } j.end_obj(); } -// UL-AM-RLC ::= SEQUENCE -SRSASN_CODE ul_am_rlc_s::pack(bit_ref& bref) const +// SecurityModeComplete-IEs ::= SEQUENCE +SRSASN_CODE security_mode_complete_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(sn_field_len_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } - HANDLE_CODE(t_poll_retx.pack(bref)); - HANDLE_CODE(poll_pdu.pack(bref)); - HANDLE_CODE(poll_byte.pack(bref)); - HANDLE_CODE(max_retx_thres.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ul_am_rlc_s::unpack(cbit_ref& bref) +SRSASN_CODE security_mode_complete_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - HANDLE_CODE(t_poll_retx.unpack(bref)); - HANDLE_CODE(poll_pdu.unpack(bref)); - HANDLE_CODE(poll_byte.unpack(bref)); - HANDLE_CODE(max_retx_thres.unpack(bref)); return SRSASN_SUCCESS; } -void ul_am_rlc_s::to_json(json_writer& j) const +void security_mode_complete_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (sn_field_len_present) { - j.write_str("sn-FieldLength", sn_field_len.to_string()); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } - j.write_str("t-PollRetransmit", t_poll_retx.to_string()); - j.write_str("pollPDU", poll_pdu.to_string()); - j.write_str("pollByte", poll_byte.to_string()); - j.write_str("maxRetxThreshold", max_retx_thres.to_string()); j.end_obj(); } -std::string ul_am_rlc_s::max_retx_thres_opts::to_string() const -{ - static const char* options[] = {"t1", "t2", "t3", "t4", "t6", "t8", "t16", "t32"}; - return convert_enum_idx(options, 8, value, "ul_am_rlc_s::max_retx_thres_e_"); -} -uint8_t ul_am_rlc_s::max_retx_thres_opts::to_number() const -{ - static const uint8_t options[] = {1, 2, 3, 4, 6, 8, 16, 32}; - return map_enum_number(options, 8, value, "ul_am_rlc_s::max_retx_thres_e_"); -} - -// UL-UM-RLC ::= SEQUENCE -SRSASN_CODE ul_um_rlc_s::pack(bit_ref& bref) const +// SecurityModeFailure-IEs ::= SEQUENCE +SRSASN_CODE security_mode_fail_ies_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(sn_field_len_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE ul_um_rlc_s::unpack(cbit_ref& bref) +SRSASN_CODE security_mode_fail_ies_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (sn_field_len_present) { - HANDLE_CODE(sn_field_len.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void ul_um_rlc_s::to_json(json_writer& j) const +void security_mode_fail_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (sn_field_len_present) { - j.write_str("sn-FieldLength", sn_field_len.to_string()); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -// UplinkConfig ::= SEQUENCE -SRSASN_CODE ul_cfg_s::pack(bit_ref& bref) const +// UEAssistanceInformation-IEs ::= SEQUENCE +SRSASN_CODE ueassist_info_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(init_ul_bwp_present, 1)); - HANDLE_CODE(bref.pack(ul_bwp_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(ul_bwp_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(first_active_ul_bwp_id_present, 1)); - HANDLE_CODE(bref.pack(pusch_serving_cell_cfg_present, 1)); - HANDLE_CODE(bref.pack(carrier_switching_present, 1)); + HANDLE_CODE(bref.pack(delay_budget_report_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (init_ul_bwp_present) { - HANDLE_CODE(init_ul_bwp.pack(bref)); - } - if (ul_bwp_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ul_bwp_to_release_list, 1, 4, integer_packer(0, 4))); - } - if (ul_bwp_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ul_bwp_to_add_mod_list, 1, 4)); - } - if (first_active_ul_bwp_id_present) { - HANDLE_CODE(pack_integer(bref, first_active_ul_bwp_id, (uint8_t)0u, (uint8_t)4u)); + if (delay_budget_report_present) { + HANDLE_CODE(delay_budget_report.pack(bref)); } - if (pusch_serving_cell_cfg_present) { - HANDLE_CODE(pusch_serving_cell_cfg.pack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } - if (carrier_switching_present) { - HANDLE_CODE(carrier_switching.pack(bref)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); } - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= pwr_boost_pi2_bpsk_present; - group_flags[0] |= ul_ch_bw_per_scs_list.is_present(); - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(pwr_boost_pi2_bpsk_present, 1)); - HANDLE_CODE(bref.pack(ul_ch_bw_per_scs_list.is_present(), 1)); - if (pwr_boost_pi2_bpsk_present) { - HANDLE_CODE(bref.pack(pwr_boost_pi2_bpsk, 1)); - } - if (ul_ch_bw_per_scs_list.is_present()) { - HANDLE_CODE(pack_dyn_seq_of(bref, *ul_ch_bw_per_scs_list, 1, 5)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE ul_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE ueassist_info_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(init_ul_bwp_present, 1)); - HANDLE_CODE(bref.unpack(ul_bwp_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(ul_bwp_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(first_active_ul_bwp_id_present, 1)); - HANDLE_CODE(bref.unpack(pusch_serving_cell_cfg_present, 1)); - HANDLE_CODE(bref.unpack(carrier_switching_present, 1)); + HANDLE_CODE(bref.unpack(delay_budget_report_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (init_ul_bwp_present) { - HANDLE_CODE(init_ul_bwp.unpack(bref)); - } - if (ul_bwp_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ul_bwp_to_release_list, bref, 1, 4, integer_packer(0, 4))); - } - if (ul_bwp_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ul_bwp_to_add_mod_list, bref, 1, 4)); - } - if (first_active_ul_bwp_id_present) { - HANDLE_CODE(unpack_integer(first_active_ul_bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); + if (delay_budget_report_present) { + HANDLE_CODE(delay_budget_report.unpack(bref)); } - if (pusch_serving_cell_cfg_present) { - HANDLE_CODE(pusch_serving_cell_cfg.unpack(bref)); + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } - if (carrier_switching_present) { - HANDLE_CODE(carrier_switching.unpack(bref)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); } - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(pwr_boost_pi2_bpsk_present, 1)); - bool ul_ch_bw_per_scs_list_present; - HANDLE_CODE(bref.unpack(ul_ch_bw_per_scs_list_present, 1)); - ul_ch_bw_per_scs_list.set_present(ul_ch_bw_per_scs_list_present); - if (pwr_boost_pi2_bpsk_present) { - HANDLE_CODE(bref.unpack(pwr_boost_pi2_bpsk, 1)); - } - if (ul_ch_bw_per_scs_list.is_present()) { - HANDLE_CODE(unpack_dyn_seq_of(*ul_ch_bw_per_scs_list, bref, 1, 5)); - } - } - } return SRSASN_SUCCESS; } -void ul_cfg_s::to_json(json_writer& j) const +void ueassist_info_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (init_ul_bwp_present) { - j.write_fieldname("initialUplinkBWP"); - init_ul_bwp.to_json(j); - } - if (ul_bwp_to_release_list_present) { - j.start_array("uplinkBWP-ToReleaseList"); - for (const auto& e1 : ul_bwp_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (ul_bwp_to_add_mod_list_present) { - j.start_array("uplinkBWP-ToAddModList"); - for (const auto& e1 : ul_bwp_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (first_active_ul_bwp_id_present) { - j.write_int("firstActiveUplinkBWP-Id", first_active_ul_bwp_id); - } - if (pusch_serving_cell_cfg_present) { - j.write_fieldname("pusch-ServingCellConfig"); - pusch_serving_cell_cfg.to_json(j); + if (delay_budget_report_present) { + j.write_fieldname("delayBudgetReport"); + delay_budget_report.to_json(j); } - if (carrier_switching_present) { - j.write_fieldname("carrierSwitching"); - carrier_switching.to_json(j); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (ext) { - if (pwr_boost_pi2_bpsk_present) { - j.write_bool("powerBoostPi2BPSK", pwr_boost_pi2_bpsk); - } - if (ul_ch_bw_per_scs_list.is_present()) { - j.start_array("uplinkChannelBW-PerSCS-List"); - for (const auto& e1 : *ul_ch_bw_per_scs_list) { - e1.to_json(j); - } - j.end_array(); - } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); } j.end_obj(); } -// BSR-Config ::= SEQUENCE -SRSASN_CODE bsr_cfg_s::pack(bit_ref& bref) const +// UECapabilityInformation-IEs ::= SEQUENCE +SRSASN_CODE ue_cap_info_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(lc_ch_sr_delay_timer_present, 1)); + HANDLE_CODE(bref.pack(ue_cap_rat_container_list_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - HANDLE_CODE(periodic_bsr_timer.pack(bref)); - HANDLE_CODE(retx_bsr_timer.pack(bref)); - if (lc_ch_sr_delay_timer_present) { - HANDLE_CODE(lc_ch_sr_delay_timer.pack(bref)); + if (ue_cap_rat_container_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ue_cap_rat_container_list, 0, 8)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE bsr_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE ue_cap_info_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(lc_ch_sr_delay_timer_present, 1)); + HANDLE_CODE(bref.unpack(ue_cap_rat_container_list_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - HANDLE_CODE(periodic_bsr_timer.unpack(bref)); - HANDLE_CODE(retx_bsr_timer.unpack(bref)); - if (lc_ch_sr_delay_timer_present) { - HANDLE_CODE(lc_ch_sr_delay_timer.unpack(bref)); + if (ue_cap_rat_container_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ue_cap_rat_container_list, bref, 0, 8)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void bsr_cfg_s::to_json(json_writer& j) const +void ue_cap_info_ies_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("periodicBSR-Timer", periodic_bsr_timer.to_string()); - j.write_str("retxBSR-Timer", retx_bsr_timer.to_string()); - if (lc_ch_sr_delay_timer_present) { - j.write_str("logicalChannelSR-DelayTimer", lc_ch_sr_delay_timer.to_string()); + if (ue_cap_rat_container_list_present) { + j.start_array("ue-CapabilityRAT-ContainerList"); + for (const auto& e1 : ue_cap_rat_container_list) { + e1.to_json(j); + } + j.end_array(); + } + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -std::string bsr_cfg_s::periodic_bsr_timer_opts::to_string() const -{ - static const char* options[] = {"sf1", - "sf5", - "sf10", - "sf16", - "sf20", - "sf32", - "sf40", - "sf64", - "sf80", - "sf128", - "sf160", - "sf320", - "sf640", - "sf1280", - "sf2560", - "infinity"}; - return convert_enum_idx(options, 16, value, "bsr_cfg_s::periodic_bsr_timer_e_"); -} -int16_t bsr_cfg_s::periodic_bsr_timer_opts::to_number() const +// ULInformationTransfer-IEs ::= SEQUENCE +SRSASN_CODE ul_info_transfer_ies_s::pack(bit_ref& bref) const { - static const int16_t options[] = {1, 5, 10, 16, 20, 32, 40, 64, 80, 128, 160, 320, 640, 1280, 2560, -1}; - return map_enum_number(options, 16, value, "bsr_cfg_s::periodic_bsr_timer_e_"); -} + HANDLE_CODE(bref.pack(ded_nas_msg_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); -std::string bsr_cfg_s::retx_bsr_timer_opts::to_string() const -{ - static const char* options[] = {"sf10", - "sf20", - "sf40", - "sf80", - "sf160", - "sf320", - "sf640", - "sf1280", - "sf2560", - "sf5120", - "sf10240", - "spare5", - "spare4", - "spare3", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "bsr_cfg_s::retx_bsr_timer_e_"); + if (ded_nas_msg_present) { + HANDLE_CODE(ded_nas_msg.pack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; } -uint16_t bsr_cfg_s::retx_bsr_timer_opts::to_number() const +SRSASN_CODE ul_info_transfer_ies_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {10, 20, 40, 80, 160, 320, 640, 1280, 2560, 5120, 10240}; - return map_enum_number(options, 11, value, "bsr_cfg_s::retx_bsr_timer_e_"); -} + HANDLE_CODE(bref.unpack(ded_nas_msg_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); -std::string bsr_cfg_s::lc_ch_sr_delay_timer_opts::to_string() const -{ - static const char* options[] = {"sf20", "sf40", "sf64", "sf128", "sf512", "sf1024", "sf2560", "spare1"}; - return convert_enum_idx(options, 8, value, "bsr_cfg_s::lc_ch_sr_delay_timer_e_"); + if (ded_nas_msg_present) { + HANDLE_CODE(ded_nas_msg.unpack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; } -uint16_t bsr_cfg_s::lc_ch_sr_delay_timer_opts::to_number() const +void ul_info_transfer_ies_s::to_json(json_writer& j) const { - static const uint16_t options[] = {20, 40, 64, 128, 512, 1024, 2560}; - return map_enum_number(options, 7, value, "bsr_cfg_s::lc_ch_sr_delay_timer_e_"); + j.start_obj(); + if (ded_nas_msg_present) { + j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); + } + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); } -// DRB-ToAddMod ::= SEQUENCE -SRSASN_CODE drb_to_add_mod_s::pack(bit_ref& bref) const +// ULInformationTransferMRDC-IEs ::= SEQUENCE +SRSASN_CODE ul_info_transfer_mrdc_ies_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(cn_assoc_present, 1)); - HANDLE_CODE(bref.pack(reestablish_pdcp_present, 1)); - HANDLE_CODE(bref.pack(recover_pdcp_present, 1)); - HANDLE_CODE(bref.pack(pdcp_cfg_present, 1)); + HANDLE_CODE(bref.pack(ul_dcch_msg_nr_present, 1)); + HANDLE_CODE(bref.pack(ul_dcch_msg_eutra_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (cn_assoc_present) { - HANDLE_CODE(cn_assoc.pack(bref)); + if (ul_dcch_msg_nr_present) { + HANDLE_CODE(ul_dcch_msg_nr.pack(bref)); } - HANDLE_CODE(pack_integer(bref, drb_id, (uint8_t)1u, (uint8_t)32u)); - if (pdcp_cfg_present) { - HANDLE_CODE(pdcp_cfg.pack(bref)); + if (ul_dcch_msg_eutra_present) { + HANDLE_CODE(ul_dcch_msg_eutra.pack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE drb_to_add_mod_s::unpack(cbit_ref& bref) +SRSASN_CODE ul_info_transfer_mrdc_ies_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(cn_assoc_present, 1)); - HANDLE_CODE(bref.unpack(reestablish_pdcp_present, 1)); - HANDLE_CODE(bref.unpack(recover_pdcp_present, 1)); - HANDLE_CODE(bref.unpack(pdcp_cfg_present, 1)); + HANDLE_CODE(bref.unpack(ul_dcch_msg_nr_present, 1)); + HANDLE_CODE(bref.unpack(ul_dcch_msg_eutra_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (cn_assoc_present) { - HANDLE_CODE(cn_assoc.unpack(bref)); + if (ul_dcch_msg_nr_present) { + HANDLE_CODE(ul_dcch_msg_nr.unpack(bref)); } - HANDLE_CODE(unpack_integer(drb_id, bref, (uint8_t)1u, (uint8_t)32u)); - if (pdcp_cfg_present) { - HANDLE_CODE(pdcp_cfg.unpack(bref)); + if (ul_dcch_msg_eutra_present) { + HANDLE_CODE(ul_dcch_msg_eutra.unpack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void drb_to_add_mod_s::to_json(json_writer& j) const +void ul_info_transfer_mrdc_ies_s::to_json(json_writer& j) const { j.start_obj(); - if (cn_assoc_present) { - j.write_fieldname("cnAssociation"); - cn_assoc.to_json(j); + if (ul_dcch_msg_nr_present) { + j.write_str("ul-DCCH-MessageNR", ul_dcch_msg_nr.to_string()); } - j.write_int("drb-Identity", drb_id); - if (reestablish_pdcp_present) { - j.write_str("reestablishPDCP", "true"); + if (ul_dcch_msg_eutra_present) { + j.write_str("ul-DCCH-MessageEUTRA", ul_dcch_msg_eutra.to_string()); } - if (recover_pdcp_present) { - j.write_str("recoverPDCP", "true"); + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } - if (pdcp_cfg_present) { - j.write_fieldname("pdcp-Config"); - pdcp_cfg.to_json(j); + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -void drb_to_add_mod_s::cn_assoc_c_::destroy_() +// CounterCheckResponse ::= SEQUENCE +SRSASN_CODE counter_check_resp_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE counter_check_resp_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void counter_check_resp_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void counter_check_resp_s::crit_exts_c_::destroy_() { switch (type_) { - case types::sdap_cfg: - c.destroy(); + case types::counter_check_resp: + c.destroy(); break; default: break; } } -void drb_to_add_mod_s::cn_assoc_c_::set(types::options e) +void counter_check_resp_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::eps_bearer_id: + case types::counter_check_resp: + c.init(); break; - case types::sdap_cfg: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); + log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); } } -drb_to_add_mod_s::cn_assoc_c_::cn_assoc_c_(const drb_to_add_mod_s::cn_assoc_c_& other) +counter_check_resp_s::crit_exts_c_::crit_exts_c_(const counter_check_resp_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::eps_bearer_id: - c.init(other.c.get()); + case types::counter_check_resp: + c.init(other.c.get()); break; - case types::sdap_cfg: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); + log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); } } -drb_to_add_mod_s::cn_assoc_c_& drb_to_add_mod_s::cn_assoc_c_::operator=(const drb_to_add_mod_s::cn_assoc_c_& other) +counter_check_resp_s::crit_exts_c_& +counter_check_resp_s::crit_exts_c_::operator=(const counter_check_resp_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::eps_bearer_id: - c.set(other.c.get()); + case types::counter_check_resp: + c.set(other.c.get()); break; - case types::sdap_cfg: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); + log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); } return *this; } -void drb_to_add_mod_s::cn_assoc_c_::to_json(json_writer& j) const +void counter_check_resp_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::eps_bearer_id: - j.write_int("eps-BearerIdentity", c.get()); + case types::counter_check_resp: + j.write_fieldname("counterCheckResponse"); + c.get().to_json(j); break; - case types::sdap_cfg: - j.write_fieldname("sdap-Config"); - c.get().to_json(j); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); + log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE drb_to_add_mod_s::cn_assoc_c_::pack(bit_ref& bref) const +SRSASN_CODE counter_check_resp_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::eps_bearer_id: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); + case types::counter_check_resp: + HANDLE_CODE(c.get().pack(bref)); break; - case types::sdap_cfg: - HANDLE_CODE(c.get().pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); + log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE drb_to_add_mod_s::cn_assoc_c_::unpack(cbit_ref& bref) +SRSASN_CODE counter_check_resp_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::eps_bearer_id: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); + case types::counter_check_resp: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::sdap_cfg: - HANDLE_CODE(c.get().unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drb_to_add_mod_s::cn_assoc_c_"); + log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string drb_to_add_mod_s::cn_assoc_c_::types_opts::to_string() const +std::string counter_check_resp_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"eps-BearerIdentity", "sdap-Config"}; - return convert_enum_idx(options, 2, value, "drb_to_add_mod_s::cn_assoc_c_::types"); + static const char* options[] = {"counterCheckResponse", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "counter_check_resp_s::crit_exts_c_::types"); } -// DRX-Config ::= SEQUENCE -SRSASN_CODE drx_cfg_s::pack(bit_ref& bref) const +// FailureInformation ::= SEQUENCE +SRSASN_CODE fail_info_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(short_drx_present, 1)); - - HANDLE_CODE(drx_on_dur_timer.pack(bref)); - HANDLE_CODE(drx_inactivity_timer.pack(bref)); - HANDLE_CODE(pack_integer(bref, drx_harq_rtt_timer_dl, (uint8_t)0u, (uint8_t)56u)); - HANDLE_CODE(pack_integer(bref, drx_harq_rtt_timer_ul, (uint8_t)0u, (uint8_t)56u)); - HANDLE_CODE(drx_retx_timer_dl.pack(bref)); - HANDLE_CODE(drx_retx_timer_ul.pack(bref)); - HANDLE_CODE(drx_long_cycle_start_offset.pack(bref)); - if (short_drx_present) { - HANDLE_CODE(short_drx.drx_short_cycle.pack(bref)); - HANDLE_CODE(pack_integer(bref, short_drx.drx_short_cycle_timer, (uint8_t)1u, (uint8_t)16u)); - } - HANDLE_CODE(pack_integer(bref, drx_slot_offset, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE drx_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE fail_info_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(short_drx_present, 1)); - - HANDLE_CODE(drx_on_dur_timer.unpack(bref)); - HANDLE_CODE(drx_inactivity_timer.unpack(bref)); - HANDLE_CODE(unpack_integer(drx_harq_rtt_timer_dl, bref, (uint8_t)0u, (uint8_t)56u)); - HANDLE_CODE(unpack_integer(drx_harq_rtt_timer_ul, bref, (uint8_t)0u, (uint8_t)56u)); - HANDLE_CODE(drx_retx_timer_dl.unpack(bref)); - HANDLE_CODE(drx_retx_timer_ul.unpack(bref)); - HANDLE_CODE(drx_long_cycle_start_offset.unpack(bref)); - if (short_drx_present) { - HANDLE_CODE(short_drx.drx_short_cycle.unpack(bref)); - HANDLE_CODE(unpack_integer(short_drx.drx_short_cycle_timer, bref, (uint8_t)1u, (uint8_t)16u)); - } - HANDLE_CODE(unpack_integer(drx_slot_offset, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void drx_cfg_s::to_json(json_writer& j) const +void fail_info_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("drx-onDurationTimer"); - drx_on_dur_timer.to_json(j); - j.write_str("drx-InactivityTimer", drx_inactivity_timer.to_string()); - j.write_int("drx-HARQ-RTT-TimerDL", drx_harq_rtt_timer_dl); - j.write_int("drx-HARQ-RTT-TimerUL", drx_harq_rtt_timer_ul); - j.write_str("drx-RetransmissionTimerDL", drx_retx_timer_dl.to_string()); - j.write_str("drx-RetransmissionTimerUL", drx_retx_timer_ul.to_string()); - j.write_fieldname("drx-LongCycleStartOffset"); - drx_long_cycle_start_offset.to_json(j); - if (short_drx_present) { - j.write_fieldname("shortDRX"); - j.start_obj(); - j.write_str("drx-ShortCycle", short_drx.drx_short_cycle.to_string()); - j.write_int("drx-ShortCycleTimer", short_drx.drx_short_cycle_timer); - j.end_obj(); - } - j.write_int("drx-SlotOffset", drx_slot_offset); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -void drx_cfg_s::drx_on_dur_timer_c_::destroy_() {} -void drx_cfg_s::drx_on_dur_timer_c_::set(types::options e) +void fail_info_s::crit_exts_c_::destroy_() +{ + switch (type_) { + case types::fail_info: + c.destroy(); + break; + default: + break; + } +} +void fail_info_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; + switch (type_) { + case types::fail_info: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); + } } -drx_cfg_s::drx_on_dur_timer_c_::drx_on_dur_timer_c_(const drx_cfg_s::drx_on_dur_timer_c_& other) +fail_info_s::crit_exts_c_::crit_exts_c_(const fail_info_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::sub_milli_seconds: - c.init(other.c.get()); + case types::fail_info: + c.init(other.c.get()); break; - case types::milli_seconds: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); + log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); } } -drx_cfg_s::drx_on_dur_timer_c_& drx_cfg_s::drx_on_dur_timer_c_::operator=(const drx_cfg_s::drx_on_dur_timer_c_& other) +fail_info_s::crit_exts_c_& fail_info_s::crit_exts_c_::operator=(const fail_info_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::sub_milli_seconds: - c.set(other.c.get()); + case types::fail_info: + c.set(other.c.get()); break; - case types::milli_seconds: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); + log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); } return *this; } -void drx_cfg_s::drx_on_dur_timer_c_::to_json(json_writer& j) const +void fail_info_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::sub_milli_seconds: - j.write_int("subMilliSeconds", c.get()); + case types::fail_info: + j.write_fieldname("failureInformation"); + c.get().to_json(j); break; - case types::milli_seconds: - j.write_str("milliSeconds", c.get().to_string()); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); + log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE drx_cfg_s::drx_on_dur_timer_c_::pack(bit_ref& bref) const +SRSASN_CODE fail_info_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::sub_milli_seconds: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)31u)); + case types::fail_info: + HANDLE_CODE(c.get().pack(bref)); break; - case types::milli_seconds: - HANDLE_CODE(c.get().pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); + log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE drx_cfg_s::drx_on_dur_timer_c_::unpack(cbit_ref& bref) +SRSASN_CODE fail_info_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::sub_milli_seconds: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)31u)); + case types::fail_info: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::milli_seconds: - HANDLE_CODE(c.get().unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); + log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_opts::to_string() const -{ - static const char* options[] = {"ms1", "ms2", "ms3", "ms4", "ms5", "ms6", "ms8", "ms10", - "ms20", "ms30", "ms40", "ms50", "ms60", "ms80", "ms100", "ms200", - "ms300", "ms400", "ms500", "ms600", "ms800", "ms1000", "ms1200", "ms1600", - "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_e_"); -} -uint16_t drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_opts::to_number() const +std::string fail_info_s::crit_exts_c_::types_opts::to_string() const { - static const uint16_t options[] = {1, 2, 3, 4, 5, 6, 8, 10, 20, 30, 40, 50, - 60, 80, 100, 200, 300, 400, 500, 600, 800, 1000, 1200, 1600}; - return map_enum_number(options, 24, value, "drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_e_"); + static const char* options[] = {"failureInformation", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "fail_info_s::crit_exts_c_::types"); } -std::string drx_cfg_s::drx_on_dur_timer_c_::types_opts::to_string() const +// LocationMeasurementIndication ::= SEQUENCE +SRSASN_CODE location_meas_ind_s::pack(bit_ref& bref) const { - static const char* options[] = {"subMilliSeconds", "milliSeconds"}; - return convert_enum_idx(options, 2, value, "drx_cfg_s::drx_on_dur_timer_c_::types"); -} + HANDLE_CODE(crit_exts.pack(bref)); -std::string drx_cfg_s::drx_inactivity_timer_opts::to_string() const -{ - static const char* options[] = {"ms0", "ms1", "ms2", "ms3", "ms4", "ms5", "ms6", "ms8", - "ms10", "ms20", "ms30", "ms40", "ms50", "ms60", "ms80", "ms100", - "ms200", "ms300", "ms500", "ms750", "ms1280", "ms1920", "ms2560", "spare9", - "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_inactivity_timer_e_"); + return SRSASN_SUCCESS; } -uint16_t drx_cfg_s::drx_inactivity_timer_opts::to_number() const +SRSASN_CODE location_meas_ind_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {0, 1, 2, 3, 4, 5, 6, 8, 10, 20, 30, 40, - 50, 60, 80, 100, 200, 300, 500, 750, 1280, 1920, 2560}; - return map_enum_number(options, 23, value, "drx_cfg_s::drx_inactivity_timer_e_"); -} + HANDLE_CODE(crit_exts.unpack(bref)); -std::string drx_cfg_s::drx_retx_timer_dl_opts::to_string() const -{ - static const char* options[] = {"sl0", "sl1", "sl2", "sl4", "sl6", "sl8", "sl16", "sl24", - "sl33", "sl40", "sl64", "sl80", "sl96", "sl112", "sl128", "sl160", - "sl320", "spare15", "spare14", "spare13", "spare12", "spare11", "spare10", "spare9", - "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_retx_timer_dl_e_"); + return SRSASN_SUCCESS; } -uint16_t drx_cfg_s::drx_retx_timer_dl_opts::to_number() const +void location_meas_ind_s::to_json(json_writer& j) const { - static const uint16_t options[] = {0, 1, 2, 4, 6, 8, 16, 24, 33, 40, 64, 80, 96, 112, 128, 160, 320}; - return map_enum_number(options, 17, value, "drx_cfg_s::drx_retx_timer_dl_e_"); + j.start_obj(); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); } -std::string drx_cfg_s::drx_retx_timer_ul_opts::to_string() const -{ - static const char* options[] = {"sl0", "sl1", "sl2", "sl4", "sl6", "sl8", "sl16", "sl24", - "sl33", "sl40", "sl64", "sl80", "sl96", "sl112", "sl128", "sl160", - "sl320", "spare15", "spare14", "spare13", "spare12", "spare11", "spare10", "spare9", - "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_retx_timer_ul_e_"); -} -uint16_t drx_cfg_s::drx_retx_timer_ul_opts::to_number() const +void location_meas_ind_s::crit_exts_c_::destroy_() { - static const uint16_t options[] = {0, 1, 2, 4, 6, 8, 16, 24, 33, 40, 64, 80, 96, 112, 128, 160, 320}; - return map_enum_number(options, 17, value, "drx_cfg_s::drx_retx_timer_ul_e_"); + switch (type_) { + case types::location_meas_ind: + c.destroy(); + break; + default: + break; + } } - -void drx_cfg_s::drx_long_cycle_start_offset_c_::destroy_() {} -void drx_cfg_s::drx_long_cycle_start_offset_c_::set(types::options e) +void location_meas_ind_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; -} -drx_cfg_s::drx_long_cycle_start_offset_c_::drx_long_cycle_start_offset_c_( - const drx_cfg_s::drx_long_cycle_start_offset_c_& other) -{ - type_ = other.type(); switch (type_) { - case types::ms10: - c.init(other.c.get()); - break; - case types::ms20: - c.init(other.c.get()); - break; - case types::ms32: - c.init(other.c.get()); - break; - case types::ms40: - c.init(other.c.get()); - break; - case types::ms60: - c.init(other.c.get()); - break; - case types::ms64: - c.init(other.c.get()); - break; - case types::ms70: - c.init(other.c.get()); - break; - case types::ms80: - c.init(other.c.get()); - break; - case types::ms128: - c.init(other.c.get()); - break; - case types::ms160: - c.init(other.c.get()); - break; - case types::ms256: - c.init(other.c.get()); - break; - case types::ms320: - c.init(other.c.get()); - break; - case types::ms512: - c.init(other.c.get()); - break; - case types::ms640: - c.init(other.c.get()); - break; - case types::ms1024: - c.init(other.c.get()); - break; - case types::ms1280: - c.init(other.c.get()); + case types::location_meas_ind: + c.init(); break; - case types::ms2048: - c.init(other.c.get()); + case types::crit_exts_future: break; - case types::ms2560: - c.init(other.c.get()); + case types::nulltype: break; - case types::ms5120: - c.init(other.c.get()); + default: + log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); + } +} +location_meas_ind_s::crit_exts_c_::crit_exts_c_(const location_meas_ind_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::location_meas_ind: + c.init(other.c.get()); break; - case types::ms10240: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); + log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); } } -drx_cfg_s::drx_long_cycle_start_offset_c_& drx_cfg_s::drx_long_cycle_start_offset_c_:: - operator=(const drx_cfg_s::drx_long_cycle_start_offset_c_& other) +location_meas_ind_s::crit_exts_c_& +location_meas_ind_s::crit_exts_c_::operator=(const location_meas_ind_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ms10: - c.set(other.c.get()); - break; - case types::ms20: - c.set(other.c.get()); - break; - case types::ms32: - c.set(other.c.get()); - break; - case types::ms40: - c.set(other.c.get()); - break; - case types::ms60: - c.set(other.c.get()); - break; - case types::ms64: - c.set(other.c.get()); - break; - case types::ms70: - c.set(other.c.get()); - break; - case types::ms80: - c.set(other.c.get()); - break; - case types::ms128: - c.set(other.c.get()); - break; - case types::ms160: - c.set(other.c.get()); - break; - case types::ms256: - c.set(other.c.get()); - break; - case types::ms320: - c.set(other.c.get()); - break; - case types::ms512: - c.set(other.c.get()); - break; - case types::ms640: - c.set(other.c.get()); - break; - case types::ms1024: - c.set(other.c.get()); - break; - case types::ms1280: - c.set(other.c.get()); - break; - case types::ms2048: - c.set(other.c.get()); - break; - case types::ms2560: - c.set(other.c.get()); - break; - case types::ms5120: - c.set(other.c.get()); + case types::location_meas_ind: + c.set(other.c.get()); break; - case types::ms10240: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); + log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); } return *this; } -void drx_cfg_s::drx_long_cycle_start_offset_c_::to_json(json_writer& j) const +void location_meas_ind_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ms10: - j.write_int("ms10", c.get()); - break; - case types::ms20: - j.write_int("ms20", c.get()); - break; - case types::ms32: - j.write_int("ms32", c.get()); - break; - case types::ms40: - j.write_int("ms40", c.get()); - break; - case types::ms60: - j.write_int("ms60", c.get()); - break; - case types::ms64: - j.write_int("ms64", c.get()); - break; - case types::ms70: - j.write_int("ms70", c.get()); - break; - case types::ms80: - j.write_int("ms80", c.get()); - break; - case types::ms128: - j.write_int("ms128", c.get()); - break; - case types::ms160: - j.write_int("ms160", c.get()); - break; - case types::ms256: - j.write_int("ms256", c.get()); - break; - case types::ms320: - j.write_int("ms320", c.get()); - break; - case types::ms512: - j.write_int("ms512", c.get()); - break; - case types::ms640: - j.write_int("ms640", c.get()); - break; - case types::ms1024: - j.write_int("ms1024", c.get()); - break; - case types::ms1280: - j.write_int("ms1280", c.get()); - break; - case types::ms2048: - j.write_int("ms2048", c.get()); - break; - case types::ms2560: - j.write_int("ms2560", c.get()); - break; - case types::ms5120: - j.write_int("ms5120", c.get()); + case types::location_meas_ind: + j.write_fieldname("locationMeasurementIndication"); + c.get().to_json(j); break; - case types::ms10240: - j.write_int("ms10240", c.get()); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); + log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE drx_cfg_s::drx_long_cycle_start_offset_c_::pack(bit_ref& bref) const +SRSASN_CODE location_meas_ind_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ms10: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); - break; - case types::ms20: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); - break; - case types::ms32: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); - break; - case types::ms40: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); - break; - case types::ms60: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)59u)); - break; - case types::ms64: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); - break; - case types::ms70: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)69u)); - break; - case types::ms80: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); - break; - case types::ms128: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); - break; - case types::ms160: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); - break; - case types::ms256: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)255u)); - break; - case types::ms320: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); - break; - case types::ms512: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)511u)); - break; - case types::ms640: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); - break; - case types::ms1024: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)1023u)); - break; - case types::ms1280: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)1279u)); - break; - case types::ms2048: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)2047u)); - break; - case types::ms2560: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)2559u)); - break; - case types::ms5120: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)5119u)); + case types::location_meas_ind: + HANDLE_CODE(c.get().pack(bref)); break; - case types::ms10240: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)10239u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); + log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE drx_cfg_s::drx_long_cycle_start_offset_c_::unpack(cbit_ref& bref) +SRSASN_CODE location_meas_ind_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ms10: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); - break; - case types::ms20: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); - break; - case types::ms32: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); - break; - case types::ms40: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); - break; - case types::ms60: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)59u)); - break; - case types::ms64: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); - break; - case types::ms70: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)69u)); - break; - case types::ms80: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); - break; - case types::ms128: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); - break; - case types::ms160: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); - break; - case types::ms256: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)255u)); - break; - case types::ms320: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); - break; - case types::ms512: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)511u)); - break; - case types::ms640: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); - break; - case types::ms1024: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)1023u)); - break; - case types::ms1280: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)1279u)); - break; - case types::ms2048: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)2047u)); - break; - case types::ms2560: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)2559u)); - break; - case types::ms5120: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)5119u)); + case types::location_meas_ind: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::ms10240: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)10239u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); + log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string drx_cfg_s::drx_long_cycle_start_offset_c_::types_opts::to_string() const +std::string location_meas_ind_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"ms10", "ms20", "ms32", "ms40", "ms60", "ms64", "ms70", - "ms80", "ms128", "ms160", "ms256", "ms320", "ms512", "ms640", - "ms1024", "ms1280", "ms2048", "ms2560", "ms5120", "ms10240"}; - return convert_enum_idx(options, 20, value, "drx_cfg_s::drx_long_cycle_start_offset_c_::types"); -} -uint16_t drx_cfg_s::drx_long_cycle_start_offset_c_::types_opts::to_number() const -{ - static const uint16_t options[] = {10, 20, 32, 40, 60, 64, 70, 80, 128, 160, - 256, 320, 512, 640, 1024, 1280, 2048, 2560, 5120, 10240}; - return map_enum_number(options, 20, value, "drx_cfg_s::drx_long_cycle_start_offset_c_::types"); -} - -std::string drx_cfg_s::short_drx_s_::drx_short_cycle_opts::to_string() const -{ - static const char* options[] = {"ms2", "ms3", "ms4", "ms5", "ms6", "ms7", "ms8", "ms10", - "ms14", "ms16", "ms20", "ms30", "ms32", "ms35", "ms40", "ms64", - "ms80", "ms128", "ms160", "ms256", "ms320", "ms512", "ms640", "spare9", - "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 32, value, "drx_cfg_s::short_drx_s_::drx_short_cycle_e_"); -} -uint16_t drx_cfg_s::short_drx_s_::drx_short_cycle_opts::to_number() const -{ - static const uint16_t options[] = {2, 3, 4, 5, 6, 7, 8, 10, 14, 16, 20, 30, - 32, 35, 40, 64, 80, 128, 160, 256, 320, 512, 640}; - return map_enum_number(options, 23, value, "drx_cfg_s::short_drx_s_::drx_short_cycle_e_"); -} - -// DataInactivityTimer ::= ENUMERATED -std::string data_inactivity_timer_opts::to_string() const -{ - static const char* options[] = { - "s1", "s2", "s3", "s5", "s7", "s10", "s15", "s20", "s40", "s50", "s60", "s80", "s100", "s120", "s150", "s180"}; - return convert_enum_idx(options, 16, value, "data_inactivity_timer_e"); -} -uint8_t data_inactivity_timer_opts::to_number() const -{ - static const uint8_t options[] = {1, 2, 3, 5, 7, 10, 15, 20, 40, 50, 60, 80, 100, 120, 150, 180}; - return map_enum_number(options, 16, value, "data_inactivity_timer_e"); + static const char* options[] = {"locationMeasurementIndication", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "location_meas_ind_s::crit_exts_c_::types"); } -// LogicalChannelConfig ::= SEQUENCE -SRSASN_CODE lc_ch_cfg_s::pack(bit_ref& bref) const +// MeasurementReport ::= SEQUENCE +SRSASN_CODE meas_report_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ul_specific_params_present, 1)); - - if (ul_specific_params_present) { - HANDLE_CODE(ul_specific_params.pack(bref)); - } + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE lc_ch_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE meas_report_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ul_specific_params_present, 1)); - - if (ul_specific_params_present) { - HANDLE_CODE(ul_specific_params.unpack(bref)); - } + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void lc_ch_cfg_s::to_json(json_writer& j) const +void meas_report_s::to_json(json_writer& j) const { j.start_obj(); - if (ul_specific_params_present) { - j.write_fieldname("ul-SpecificParameters"); - ul_specific_params.to_json(j); - } + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -SRSASN_CODE lc_ch_cfg_s::ul_specific_params_s_::pack(bit_ref& bref) const +void meas_report_s::crit_exts_c_::destroy_() { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(allowed_serving_cells_present, 1)); - HANDLE_CODE(bref.pack(allowed_scs_list_present, 1)); - HANDLE_CODE(bref.pack(max_pusch_dur_present, 1)); - HANDLE_CODE(bref.pack(cfgured_grant_type1_allowed_present, 1)); - HANDLE_CODE(bref.pack(lc_ch_group_present, 1)); - HANDLE_CODE(bref.pack(sched_request_id_present, 1)); - - HANDLE_CODE(pack_integer(bref, prio, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(prioritised_bit_rate.pack(bref)); - HANDLE_CODE(bucket_size_dur.pack(bref)); - if (allowed_serving_cells_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, allowed_serving_cells, 1, 31, integer_packer(0, 31))); - } - if (allowed_scs_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, allowed_scs_list, 1, 5)); - } - if (max_pusch_dur_present) { - HANDLE_CODE(max_pusch_dur.pack(bref)); - } - if (lc_ch_group_present) { - HANDLE_CODE(pack_integer(bref, lc_ch_group, (uint8_t)0u, (uint8_t)7u)); - } - if (sched_request_id_present) { - HANDLE_CODE(pack_integer(bref, sched_request_id, (uint8_t)0u, (uint8_t)7u)); - } - HANDLE_CODE(bref.pack(lc_ch_sr_mask, 1)); - HANDLE_CODE(bref.pack(lc_ch_sr_delay_timer_applied, 1)); - - if (ext) { - HANDLE_CODE(bref.pack(bit_rate_query_prohibit_timer_present, 1)); - - if (bit_rate_query_prohibit_timer_present) { - HANDLE_CODE(bit_rate_query_prohibit_timer.pack(bref)); - } + switch (type_) { + case types::meas_report: + c.destroy(); + break; + default: + break; } - return SRSASN_SUCCESS; } -SRSASN_CODE lc_ch_cfg_s::ul_specific_params_s_::unpack(cbit_ref& bref) +void meas_report_s::crit_exts_c_::set(types::options e) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(allowed_serving_cells_present, 1)); - HANDLE_CODE(bref.unpack(allowed_scs_list_present, 1)); - HANDLE_CODE(bref.unpack(max_pusch_dur_present, 1)); - HANDLE_CODE(bref.unpack(cfgured_grant_type1_allowed_present, 1)); - HANDLE_CODE(bref.unpack(lc_ch_group_present, 1)); - HANDLE_CODE(bref.unpack(sched_request_id_present, 1)); - - HANDLE_CODE(unpack_integer(prio, bref, (uint8_t)1u, (uint8_t)16u)); - HANDLE_CODE(prioritised_bit_rate.unpack(bref)); - HANDLE_CODE(bucket_size_dur.unpack(bref)); - if (allowed_serving_cells_present) { - HANDLE_CODE(unpack_dyn_seq_of(allowed_serving_cells, bref, 1, 31, integer_packer(0, 31))); - } - if (allowed_scs_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(allowed_scs_list, bref, 1, 5)); + destroy_(); + type_ = e; + switch (type_) { + case types::meas_report: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); } - if (max_pusch_dur_present) { - HANDLE_CODE(max_pusch_dur.unpack(bref)); +} +meas_report_s::crit_exts_c_::crit_exts_c_(const meas_report_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::meas_report: + c.init(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); } - if (lc_ch_group_present) { - HANDLE_CODE(unpack_integer(lc_ch_group, bref, (uint8_t)0u, (uint8_t)7u)); +} +meas_report_s::crit_exts_c_& meas_report_s::crit_exts_c_::operator=(const meas_report_s::crit_exts_c_& other) +{ + if (this == &other) { + return *this; } - if (sched_request_id_present) { - HANDLE_CODE(unpack_integer(sched_request_id, bref, (uint8_t)0u, (uint8_t)7u)); + set(other.type()); + switch (type_) { + case types::meas_report: + c.set(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); } - HANDLE_CODE(bref.unpack(lc_ch_sr_mask, 1)); - HANDLE_CODE(bref.unpack(lc_ch_sr_delay_timer_applied, 1)); - - if (ext) { - HANDLE_CODE(bref.unpack(bit_rate_query_prohibit_timer_present, 1)); - if (bit_rate_query_prohibit_timer_present) { - HANDLE_CODE(bit_rate_query_prohibit_timer.unpack(bref)); - } - } - return SRSASN_SUCCESS; + return *this; } -void lc_ch_cfg_s::ul_specific_params_s_::to_json(json_writer& j) const +void meas_report_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_int("priority", prio); - j.write_str("prioritisedBitRate", prioritised_bit_rate.to_string()); - j.write_str("bucketSizeDuration", bucket_size_dur.to_string()); - if (allowed_serving_cells_present) { - j.start_array("allowedServingCells"); - for (const auto& e1 : allowed_serving_cells) { - j.write_int(e1); - } - j.end_array(); - } - if (allowed_scs_list_present) { - j.start_array("allowedSCS-List"); - for (const auto& e1 : allowed_scs_list) { - j.write_str(e1.to_string()); - } - j.end_array(); - } - if (max_pusch_dur_present) { - j.write_str("maxPUSCH-Duration", max_pusch_dur.to_string()); - } - if (cfgured_grant_type1_allowed_present) { - j.write_str("configuredGrantType1Allowed", "true"); - } - if (lc_ch_group_present) { - j.write_int("logicalChannelGroup", lc_ch_group); - } - if (sched_request_id_present) { - j.write_int("schedulingRequestID", sched_request_id); - } - j.write_bool("logicalChannelSR-Mask", lc_ch_sr_mask); - j.write_bool("logicalChannelSR-DelayTimerApplied", lc_ch_sr_delay_timer_applied); - if (ext) { - if (bit_rate_query_prohibit_timer_present) { - j.write_str("bitRateQueryProhibitTimer", bit_rate_query_prohibit_timer.to_string()); - } + switch (type_) { + case types::meas_report: + j.write_fieldname("measurementReport"); + c.get().to_json(j); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); } j.end_obj(); } - -std::string lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_opts::to_string() const -{ - static const char* options[] = {"kBps0", - "kBps8", - "kBps16", - "kBps32", - "kBps64", - "kBps128", - "kBps256", - "kBps512", - "kBps1024", - "kBps2048", - "kBps4096", - "kBps8192", - "kBps16384", - "kBps32768", - "kBps65536", - "infinity"}; - return convert_enum_idx(options, 16, value, "lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_e_"); -} -int32_t lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_opts::to_number() const -{ - static const int32_t options[] = {0, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 8192, 16384, 32768, 65536, -1}; - return map_enum_number(options, 16, value, "lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_e_"); -} - -std::string lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_opts::to_string() const -{ - static const char* options[] = {"ms5", - "ms10", - "ms20", - "ms50", - "ms100", - "ms150", - "ms300", - "ms500", - "ms1000", - "spare7", - "spare6", - "spare5", - "spare4", - "spare3", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_e_"); -} -uint16_t lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_opts::to_number() const +SRSASN_CODE meas_report_s::crit_exts_c_::pack(bit_ref& bref) const { - static const uint16_t options[] = {5, 10, 20, 50, 100, 150, 300, 500, 1000}; - return map_enum_number(options, 9, value, "lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_e_"); + type_.pack(bref); + switch (type_) { + case types::meas_report: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } - -std::string lc_ch_cfg_s::ul_specific_params_s_::max_pusch_dur_opts::to_string() const +SRSASN_CODE meas_report_s::crit_exts_c_::unpack(cbit_ref& bref) { - static const char* options[] = {"ms0p02", "ms0p04", "ms0p0625", "ms0p125", "ms0p25", "ms0p5", "spare2", "spare1"}; - return convert_enum_idx(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::max_pusch_dur_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::meas_report: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -std::string lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_opts::to_string() const -{ - static const char* options[] = {"s0", "s0dot4", "s0dot8", "s1dot6", "s3", "s6", "s12", "s30"}; - return convert_enum_idx(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_e_"); -} -float lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_opts::to_number() const -{ - static const float options[] = {0.0, 0.4, 0.8, 1.6, 3.0, 6.0, 12.0, 30.0}; - return map_enum_number(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_e_"); -} -std::string lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_opts::to_number_string() const +std::string meas_report_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"0", "0.4", "0.8", "1.6", "3", "6", "12", "30"}; - return convert_enum_idx(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_e_"); + static const char* options[] = {"measurementReport", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "meas_report_s::crit_exts_c_::types"); } -// PHR-Config ::= SEQUENCE -SRSASN_CODE phr_cfg_s::pack(bit_ref& bref) const +// RRCReconfigurationComplete ::= SEQUENCE +SRSASN_CODE rrc_recfg_complete_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(phr_periodic_timer.pack(bref)); - HANDLE_CODE(phr_prohibit_timer.pack(bref)); - HANDLE_CODE(phr_tx_pwr_factor_change.pack(bref)); - HANDLE_CODE(bref.pack(multiple_phr, 1)); - HANDLE_CODE(bref.pack(dummy, 1)); - HANDLE_CODE(bref.pack(phr_type2_other_cell, 1)); - HANDLE_CODE(phr_mode_other_cg.pack(bref)); + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE phr_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_recfg_complete_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(phr_periodic_timer.unpack(bref)); - HANDLE_CODE(phr_prohibit_timer.unpack(bref)); - HANDLE_CODE(phr_tx_pwr_factor_change.unpack(bref)); - HANDLE_CODE(bref.unpack(multiple_phr, 1)); - HANDLE_CODE(bref.unpack(dummy, 1)); - HANDLE_CODE(bref.unpack(phr_type2_other_cell, 1)); - HANDLE_CODE(phr_mode_other_cg.unpack(bref)); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void phr_cfg_s::to_json(json_writer& j) const +void rrc_recfg_complete_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("phr-PeriodicTimer", phr_periodic_timer.to_string()); - j.write_str("phr-ProhibitTimer", phr_prohibit_timer.to_string()); - j.write_str("phr-Tx-PowerFactorChange", phr_tx_pwr_factor_change.to_string()); - j.write_bool("multiplePHR", multiple_phr); - j.write_bool("dummy", dummy); - j.write_bool("phr-Type2OtherCell", phr_type2_other_cell); - j.write_str("phr-ModeOtherCG", phr_mode_other_cg.to_string()); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -std::string phr_cfg_s::phr_periodic_timer_opts::to_string() const -{ - static const char* options[] = {"sf10", "sf20", "sf50", "sf100", "sf200", "sf500", "sf1000", "infinity"}; - return convert_enum_idx(options, 8, value, "phr_cfg_s::phr_periodic_timer_e_"); -} -int16_t phr_cfg_s::phr_periodic_timer_opts::to_number() const -{ - static const int16_t options[] = {10, 20, 50, 100, 200, 500, 1000, -1}; - return map_enum_number(options, 8, value, "phr_cfg_s::phr_periodic_timer_e_"); -} - -std::string phr_cfg_s::phr_prohibit_timer_opts::to_string() const -{ - static const char* options[] = {"sf0", "sf10", "sf20", "sf50", "sf100", "sf200", "sf500", "sf1000"}; - return convert_enum_idx(options, 8, value, "phr_cfg_s::phr_prohibit_timer_e_"); -} -uint16_t phr_cfg_s::phr_prohibit_timer_opts::to_number() const -{ - static const uint16_t options[] = {0, 10, 20, 50, 100, 200, 500, 1000}; - return map_enum_number(options, 8, value, "phr_cfg_s::phr_prohibit_timer_e_"); -} - -std::string phr_cfg_s::phr_tx_pwr_factor_change_opts::to_string() const -{ - static const char* options[] = {"dB1", "dB3", "dB6", "infinity"}; - return convert_enum_idx(options, 4, value, "phr_cfg_s::phr_tx_pwr_factor_change_e_"); -} -int8_t phr_cfg_s::phr_tx_pwr_factor_change_opts::to_number() const -{ - static const int8_t options[] = {1, 3, 6, -1}; - return map_enum_number(options, 4, value, "phr_cfg_s::phr_tx_pwr_factor_change_e_"); -} - -std::string phr_cfg_s::phr_mode_other_cg_opts::to_string() const -{ - static const char* options[] = {"real", "virtual"}; - return convert_enum_idx(options, 2, value, "phr_cfg_s::phr_mode_other_cg_e_"); -} - -// RLC-Config ::= CHOICE -void rlc_cfg_c::destroy_() +void rrc_recfg_complete_s::crit_exts_c_::destroy_() { switch (type_) { - case types::am: - c.destroy(); - break; - case types::um_bi_dir: - c.destroy(); - break; - case types::um_uni_dir_ul: - c.destroy(); - break; - case types::um_uni_dir_dl: - c.destroy(); + case types::rrc_recfg_complete: + c.destroy(); break; default: break; } } -void rlc_cfg_c::set(types::options e) +void rrc_recfg_complete_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::am: - c.init(); - break; - case types::um_bi_dir: - c.init(); - break; - case types::um_uni_dir_ul: - c.init(); + case types::rrc_recfg_complete: + c.init(); break; - case types::um_uni_dir_dl: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rlc_cfg_c"); + log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); } } -rlc_cfg_c::rlc_cfg_c(const rlc_cfg_c& other) +rrc_recfg_complete_s::crit_exts_c_::crit_exts_c_(const rrc_recfg_complete_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::am: - c.init(other.c.get()); - break; - case types::um_bi_dir: - c.init(other.c.get()); - break; - case types::um_uni_dir_ul: - c.init(other.c.get()); + case types::rrc_recfg_complete: + c.init(other.c.get()); break; - case types::um_uni_dir_dl: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rlc_cfg_c"); + log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); } } -rlc_cfg_c& rlc_cfg_c::operator=(const rlc_cfg_c& other) +rrc_recfg_complete_s::crit_exts_c_& +rrc_recfg_complete_s::crit_exts_c_::operator=(const rrc_recfg_complete_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::am: - c.set(other.c.get()); - break; - case types::um_bi_dir: - c.set(other.c.get()); - break; - case types::um_uni_dir_ul: - c.set(other.c.get()); + case types::rrc_recfg_complete: + c.set(other.c.get()); break; - case types::um_uni_dir_dl: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rlc_cfg_c"); + log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); } return *this; } -void rlc_cfg_c::to_json(json_writer& j) const +void rrc_recfg_complete_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::am: - j.write_fieldname("am"); - j.start_obj(); - j.write_fieldname("ul-AM-RLC"); - c.get().ul_am_rlc.to_json(j); - j.write_fieldname("dl-AM-RLC"); - c.get().dl_am_rlc.to_json(j); - j.end_obj(); - break; - case types::um_bi_dir: - j.write_fieldname("um-Bi-Directional"); - j.start_obj(); - j.write_fieldname("ul-UM-RLC"); - c.get().ul_um_rlc.to_json(j); - j.write_fieldname("dl-UM-RLC"); - c.get().dl_um_rlc.to_json(j); - j.end_obj(); - break; - case types::um_uni_dir_ul: - j.write_fieldname("um-Uni-Directional-UL"); - j.start_obj(); - j.write_fieldname("ul-UM-RLC"); - c.get().ul_um_rlc.to_json(j); - j.end_obj(); + case types::rrc_recfg_complete: + j.write_fieldname("rrcReconfigurationComplete"); + c.get().to_json(j); break; - case types::um_uni_dir_dl: - j.write_fieldname("um-Uni-Directional-DL"); - j.start_obj(); - j.write_fieldname("dl-UM-RLC"); - c.get().dl_um_rlc.to_json(j); - j.end_obj(); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rlc_cfg_c"); + log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE rlc_cfg_c::pack(bit_ref& bref) const +SRSASN_CODE rrc_recfg_complete_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::am: - HANDLE_CODE(c.get().ul_am_rlc.pack(bref)); - HANDLE_CODE(c.get().dl_am_rlc.pack(bref)); - break; - case types::um_bi_dir: - HANDLE_CODE(c.get().ul_um_rlc.pack(bref)); - HANDLE_CODE(c.get().dl_um_rlc.pack(bref)); - break; - case types::um_uni_dir_ul: - HANDLE_CODE(c.get().ul_um_rlc.pack(bref)); + case types::rrc_recfg_complete: + HANDLE_CODE(c.get().pack(bref)); break; - case types::um_uni_dir_dl: - HANDLE_CODE(c.get().dl_um_rlc.pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rlc_cfg_c"); + log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rlc_cfg_c::unpack(cbit_ref& bref) +SRSASN_CODE rrc_recfg_complete_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::am: - HANDLE_CODE(c.get().ul_am_rlc.unpack(bref)); - HANDLE_CODE(c.get().dl_am_rlc.unpack(bref)); - break; - case types::um_bi_dir: - HANDLE_CODE(c.get().ul_um_rlc.unpack(bref)); - HANDLE_CODE(c.get().dl_um_rlc.unpack(bref)); - break; - case types::um_uni_dir_ul: - HANDLE_CODE(c.get().ul_um_rlc.unpack(bref)); + case types::rrc_recfg_complete: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::um_uni_dir_dl: - HANDLE_CODE(c.get().dl_um_rlc.unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rlc_cfg_c"); + log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rlc_cfg_c::types_opts::to_string() const +std::string rrc_recfg_complete_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"am", "um-Bi-Directional", "um-Uni-Directional-UL", "um-Uni-Directional-DL"}; - return convert_enum_idx(options, 4, value, "rlc_cfg_c::types"); + static const char* options[] = {"rrcReconfigurationComplete", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_recfg_complete_s::crit_exts_c_::types"); } -// RLF-TimersAndConstants ::= SEQUENCE -SRSASN_CODE rlf_timers_and_consts_s::pack(bit_ref& bref) const +// RRCReestablishmentComplete ::= SEQUENCE +SRSASN_CODE rrc_reest_complete_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(t310.pack(bref)); - HANDLE_CODE(n310.pack(bref)); - HANDLE_CODE(n311.pack(bref)); - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= t311_v1530; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); - HANDLE_CODE(t311_v1530.pack(bref)); - } - } return SRSASN_SUCCESS; } -SRSASN_CODE rlf_timers_and_consts_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_reest_complete_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(t310.unpack(bref)); - HANDLE_CODE(n310.unpack(bref)); - HANDLE_CODE(n311.unpack(bref)); - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); - HANDLE_CODE(t311_v1530.unpack(bref)); - } - } return SRSASN_SUCCESS; } -void rlf_timers_and_consts_s::to_json(json_writer& j) const +void rrc_reest_complete_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("t310", t310.to_string()); - j.write_str("n310", n310.to_string()); - j.write_str("n311", n311.to_string()); - if (ext) { - j.write_str("t311-v1530", t311_v1530.to_string()); - } + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -std::string rlf_timers_and_consts_s::t310_opts::to_string() const +void rrc_reest_complete_s::crit_exts_c_::destroy_() { - static const char* options[] = {"ms0", "ms50", "ms100", "ms200", "ms500", "ms1000", "ms2000", "ms4000", "ms6000"}; - return convert_enum_idx(options, 9, value, "rlf_timers_and_consts_s::t310_e_"); + switch (type_) { + case types::rrc_reest_complete: + c.destroy(); + break; + default: + break; + } } -uint16_t rlf_timers_and_consts_s::t310_opts::to_number() const +void rrc_reest_complete_s::crit_exts_c_::set(types::options e) { - static const uint16_t options[] = {0, 50, 100, 200, 500, 1000, 2000, 4000, 6000}; - return map_enum_number(options, 9, value, "rlf_timers_and_consts_s::t310_e_"); + destroy_(); + type_ = e; + switch (type_) { + case types::rrc_reest_complete: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + } } - -std::string rlf_timers_and_consts_s::n310_opts::to_string() const +rrc_reest_complete_s::crit_exts_c_::crit_exts_c_(const rrc_reest_complete_s::crit_exts_c_& other) { - static const char* options[] = {"n1", "n2", "n3", "n4", "n6", "n8", "n10", "n20"}; - return convert_enum_idx(options, 8, value, "rlf_timers_and_consts_s::n310_e_"); + type_ = other.type(); + switch (type_) { + case types::rrc_reest_complete: + c.init(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + } } -uint8_t rlf_timers_and_consts_s::n310_opts::to_number() const +rrc_reest_complete_s::crit_exts_c_& +rrc_reest_complete_s::crit_exts_c_::operator=(const rrc_reest_complete_s::crit_exts_c_& other) { - static const uint8_t options[] = {1, 2, 3, 4, 6, 8, 10, 20}; - return map_enum_number(options, 8, value, "rlf_timers_and_consts_s::n310_e_"); -} + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::rrc_reest_complete: + c.set(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + } -std::string rlf_timers_and_consts_s::n311_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n3", "n4", "n5", "n6", "n8", "n10"}; - return convert_enum_idx(options, 8, value, "rlf_timers_and_consts_s::n311_e_"); + return *this; } -uint8_t rlf_timers_and_consts_s::n311_opts::to_number() const +void rrc_reest_complete_s::crit_exts_c_::to_json(json_writer& j) const { - static const uint8_t options[] = {1, 2, 3, 4, 5, 6, 8, 10}; - return map_enum_number(options, 8, value, "rlf_timers_and_consts_s::n311_e_"); + j.start_obj(); + switch (type_) { + case types::rrc_reest_complete: + j.write_fieldname("rrcReestablishmentComplete"); + c.get().to_json(j); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + } + j.end_obj(); } - -std::string rlf_timers_and_consts_s::t311_v1530_opts::to_string() const +SRSASN_CODE rrc_reest_complete_s::crit_exts_c_::pack(bit_ref& bref) const { - static const char* options[] = {"ms1000", "ms3000", "ms5000", "ms10000", "ms15000", "ms20000", "ms30000"}; - return convert_enum_idx(options, 7, value, "rlf_timers_and_consts_s::t311_v1530_e_"); + type_.pack(bref); + switch (type_) { + case types::rrc_reest_complete: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } -uint16_t rlf_timers_and_consts_s::t311_v1530_opts::to_number() const +SRSASN_CODE rrc_reest_complete_s::crit_exts_c_::unpack(cbit_ref& bref) { - static const uint16_t options[] = {1000, 3000, 5000, 10000, 15000, 20000, 30000}; - return map_enum_number(options, 7, value, "rlf_timers_and_consts_s::t311_v1530_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::rrc_reest_complete: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -// ReconfigurationWithSync ::= SEQUENCE -SRSASN_CODE recfg_with_sync_s::pack(bit_ref& bref) const +std::string rrc_reest_complete_s::crit_exts_c_::types_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(sp_cell_cfg_common_present, 1)); - HANDLE_CODE(bref.pack(rach_cfg_ded_present, 1)); - - if (sp_cell_cfg_common_present) { - HANDLE_CODE(sp_cell_cfg_common.pack(bref)); - } - HANDLE_CODE(pack_integer(bref, new_ue_id, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(t304.pack(bref)); - if (rach_cfg_ded_present) { - HANDLE_CODE(rach_cfg_ded.pack(bref)); - } - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= smtc.is_present(); - group_flags.pack(bref); + static const char* options[] = {"rrcReestablishmentComplete", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_reest_complete_s::crit_exts_c_::types"); +} - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); +// RRCResumeComplete ::= SEQUENCE +SRSASN_CODE rrc_resume_complete_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); - HANDLE_CODE(bref.pack(smtc.is_present(), 1)); - if (smtc.is_present()) { - HANDLE_CODE(smtc->pack(bref)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE recfg_with_sync_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_resume_complete_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(sp_cell_cfg_common_present, 1)); - HANDLE_CODE(bref.unpack(rach_cfg_ded_present, 1)); - - if (sp_cell_cfg_common_present) { - HANDLE_CODE(sp_cell_cfg_common.unpack(bref)); - } - HANDLE_CODE(unpack_integer(new_ue_id, bref, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(t304.unpack(bref)); - if (rach_cfg_ded_present) { - HANDLE_CODE(rach_cfg_ded.unpack(bref)); - } - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); - bool smtc_present; - HANDLE_CODE(bref.unpack(smtc_present, 1)); - smtc.set_present(smtc_present); - if (smtc.is_present()) { - HANDLE_CODE(smtc->unpack(bref)); - } - } - } return SRSASN_SUCCESS; } -void recfg_with_sync_s::to_json(json_writer& j) const +void rrc_resume_complete_s::to_json(json_writer& j) const { j.start_obj(); - if (sp_cell_cfg_common_present) { - j.write_fieldname("spCellConfigCommon"); - sp_cell_cfg_common.to_json(j); - } - j.write_int("newUE-Identity", new_ue_id); - j.write_str("t304", t304.to_string()); - if (rach_cfg_ded_present) { - j.write_fieldname("rach-ConfigDedicated"); - rach_cfg_ded.to_json(j); - } - if (ext) { - if (smtc.is_present()) { - j.write_fieldname("smtc"); - smtc->to_json(j); - } - } + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -std::string recfg_with_sync_s::t304_opts::to_string() const -{ - static const char* options[] = {"ms50", "ms100", "ms150", "ms200", "ms500", "ms1000", "ms2000", "ms10000"}; - return convert_enum_idx(options, 8, value, "recfg_with_sync_s::t304_e_"); -} -uint16_t recfg_with_sync_s::t304_opts::to_number() const -{ - static const uint16_t options[] = {50, 100, 150, 200, 500, 1000, 2000, 10000}; - return map_enum_number(options, 8, value, "recfg_with_sync_s::t304_e_"); -} - -void recfg_with_sync_s::rach_cfg_ded_c_::destroy_() +void rrc_resume_complete_s::crit_exts_c_::destroy_() { switch (type_) { - case types::ul: - c.destroy(); - break; - case types::supplementary_ul: - c.destroy(); + case types::rrc_resume_complete: + c.destroy(); break; default: break; } } -void recfg_with_sync_s::rach_cfg_ded_c_::set(types::options e) +void rrc_resume_complete_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ul: - c.init(); + case types::rrc_resume_complete: + c.init(); break; - case types::supplementary_ul: - c.init(); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); } } -recfg_with_sync_s::rach_cfg_ded_c_::rach_cfg_ded_c_(const recfg_with_sync_s::rach_cfg_ded_c_& other) +rrc_resume_complete_s::crit_exts_c_::crit_exts_c_(const rrc_resume_complete_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::ul: - c.init(other.c.get()); + case types::rrc_resume_complete: + c.init(other.c.get()); break; - case types::supplementary_ul: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); } } -recfg_with_sync_s::rach_cfg_ded_c_& recfg_with_sync_s::rach_cfg_ded_c_:: - operator=(const recfg_with_sync_s::rach_cfg_ded_c_& other) +rrc_resume_complete_s::crit_exts_c_& +rrc_resume_complete_s::crit_exts_c_::operator=(const rrc_resume_complete_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ul: - c.set(other.c.get()); + case types::rrc_resume_complete: + c.set(other.c.get()); break; - case types::supplementary_ul: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); } return *this; } -void recfg_with_sync_s::rach_cfg_ded_c_::to_json(json_writer& j) const +void rrc_resume_complete_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ul: - j.write_fieldname("uplink"); - c.get().to_json(j); + case types::rrc_resume_complete: + j.write_fieldname("rrcResumeComplete"); + c.get().to_json(j); break; - case types::supplementary_ul: - j.write_fieldname("supplementaryUplink"); - c.get().to_json(j); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE recfg_with_sync_s::rach_cfg_ded_c_::pack(bit_ref& bref) const +SRSASN_CODE rrc_resume_complete_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ul: - HANDLE_CODE(c.get().pack(bref)); + case types::rrc_resume_complete: + HANDLE_CODE(c.get().pack(bref)); break; - case types::supplementary_ul: - HANDLE_CODE(c.get().pack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE recfg_with_sync_s::rach_cfg_ded_c_::unpack(cbit_ref& bref) +SRSASN_CODE rrc_resume_complete_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ul: - HANDLE_CODE(c.get().unpack(bref)); + case types::rrc_resume_complete: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::supplementary_ul: - HANDLE_CODE(c.get().unpack(bref)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string recfg_with_sync_s::rach_cfg_ded_c_::types_opts::to_string() const +std::string rrc_resume_complete_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"uplink", "supplementaryUplink"}; - return convert_enum_idx(options, 2, value, "recfg_with_sync_s::rach_cfg_ded_c_::types"); + static const char* options[] = {"rrcResumeComplete", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_resume_complete_s::crit_exts_c_::types"); } -// SRB-ToAddMod ::= SEQUENCE -SRSASN_CODE srb_to_add_mod_s::pack(bit_ref& bref) const +// RRCSetupComplete ::= SEQUENCE +SRSASN_CODE rrc_setup_complete_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(reestablish_pdcp_present, 1)); - HANDLE_CODE(bref.pack(discard_on_pdcp_present, 1)); - HANDLE_CODE(bref.pack(pdcp_cfg_present, 1)); - - HANDLE_CODE(pack_integer(bref, srb_id, (uint8_t)1u, (uint8_t)3u)); - if (pdcp_cfg_present) { - HANDLE_CODE(pdcp_cfg.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE srb_to_add_mod_s::unpack(cbit_ref& bref) +SRSASN_CODE rrc_setup_complete_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(reestablish_pdcp_present, 1)); - HANDLE_CODE(bref.unpack(discard_on_pdcp_present, 1)); - HANDLE_CODE(bref.unpack(pdcp_cfg_present, 1)); - - HANDLE_CODE(unpack_integer(srb_id, bref, (uint8_t)1u, (uint8_t)3u)); - if (pdcp_cfg_present) { - HANDLE_CODE(pdcp_cfg.unpack(bref)); - } + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void srb_to_add_mod_s::to_json(json_writer& j) const +void rrc_setup_complete_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("srb-Identity", srb_id); - if (reestablish_pdcp_present) { - j.write_str("reestablishPDCP", "true"); - } - if (discard_on_pdcp_present) { - j.write_str("discardOnPDCP", "true"); - } - if (pdcp_cfg_present) { - j.write_fieldname("pdcp-Config"); - pdcp_cfg.to_json(j); - } + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -// SchedulingRequestConfig ::= SEQUENCE -SRSASN_CODE sched_request_cfg_s::pack(bit_ref& bref) const +void rrc_setup_complete_s::crit_exts_c_::destroy_() { - HANDLE_CODE(bref.pack(sched_request_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(sched_request_to_release_list_present, 1)); - - if (sched_request_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_to_add_mod_list, 1, 8)); - } - if (sched_request_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_to_release_list, 1, 8, integer_packer(0, 7))); + switch (type_) { + case types::rrc_setup_complete: + c.destroy(); + break; + default: + break; } - - return SRSASN_SUCCESS; } -SRSASN_CODE sched_request_cfg_s::unpack(cbit_ref& bref) +void rrc_setup_complete_s::crit_exts_c_::set(types::options e) { - HANDLE_CODE(bref.unpack(sched_request_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(sched_request_to_release_list_present, 1)); - - if (sched_request_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sched_request_to_add_mod_list, bref, 1, 8)); - } - if (sched_request_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(sched_request_to_release_list, bref, 1, 8, integer_packer(0, 7))); + destroy_(); + type_ = e; + switch (type_) { + case types::rrc_setup_complete: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); } - - return SRSASN_SUCCESS; } -void sched_request_cfg_s::to_json(json_writer& j) const +rrc_setup_complete_s::crit_exts_c_::crit_exts_c_(const rrc_setup_complete_s::crit_exts_c_& other) { - j.start_obj(); - if (sched_request_to_add_mod_list_present) { - j.start_array("schedulingRequestToAddModList"); - for (const auto& e1 : sched_request_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (sched_request_to_release_list_present) { - j.start_array("schedulingRequestToReleaseList"); - for (const auto& e1 : sched_request_to_release_list) { - j.write_int(e1); - } - j.end_array(); + type_ = other.type(); + switch (type_) { + case types::rrc_setup_complete: + c.init(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); } - j.end_obj(); } - -// SecurityAlgorithmConfig ::= SEQUENCE -SRSASN_CODE security_algorithm_cfg_s::pack(bit_ref& bref) const +rrc_setup_complete_s::crit_exts_c_& +rrc_setup_complete_s::crit_exts_c_::operator=(const rrc_setup_complete_s::crit_exts_c_& other) { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(integrity_prot_algorithm_present, 1)); - - HANDLE_CODE(ciphering_algorithm.pack(bref)); - if (integrity_prot_algorithm_present) { - HANDLE_CODE(integrity_prot_algorithm.pack(bref)); + if (this == &other) { + return *this; } - - return SRSASN_SUCCESS; -} -SRSASN_CODE security_algorithm_cfg_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(integrity_prot_algorithm_present, 1)); - - HANDLE_CODE(ciphering_algorithm.unpack(bref)); - if (integrity_prot_algorithm_present) { - HANDLE_CODE(integrity_prot_algorithm.unpack(bref)); + set(other.type()); + switch (type_) { + case types::rrc_setup_complete: + c.set(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); } - return SRSASN_SUCCESS; + return *this; } -void security_algorithm_cfg_s::to_json(json_writer& j) const +void rrc_setup_complete_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_str("cipheringAlgorithm", ciphering_algorithm.to_string()); - if (integrity_prot_algorithm_present) { - j.write_str("integrityProtAlgorithm", integrity_prot_algorithm.to_string()); + switch (type_) { + case types::rrc_setup_complete: + j.write_fieldname("rrcSetupComplete"); + c.get().to_json(j); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); } j.end_obj(); } - -// ServingCellConfig ::= SEQUENCE -SRSASN_CODE serving_cell_cfg_s::pack(bit_ref& bref) const +SRSASN_CODE rrc_setup_complete_s::crit_exts_c_::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(tdd_ul_dl_cfg_ded_present, 1)); - HANDLE_CODE(bref.pack(init_dl_bwp_present, 1)); - HANDLE_CODE(bref.pack(dl_bwp_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(dl_bwp_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(first_active_dl_bwp_id_present, 1)); - HANDLE_CODE(bref.pack(bwp_inactivity_timer_present, 1)); - HANDLE_CODE(bref.pack(default_dl_bwp_id_present, 1)); - HANDLE_CODE(bref.pack(ul_cfg_present, 1)); - HANDLE_CODE(bref.pack(supplementary_ul_present, 1)); - HANDLE_CODE(bref.pack(pdcch_serving_cell_cfg_present, 1)); - HANDLE_CODE(bref.pack(pdsch_serving_cell_cfg_present, 1)); - HANDLE_CODE(bref.pack(csi_meas_cfg_present, 1)); - HANDLE_CODE(bref.pack(scell_deactivation_timer_present, 1)); - HANDLE_CODE(bref.pack(cross_carrier_sched_cfg_present, 1)); - HANDLE_CODE(bref.pack(dummy_present, 1)); - HANDLE_CODE(bref.pack(pathloss_ref_linking_present, 1)); - HANDLE_CODE(bref.pack(serving_cell_mo_present, 1)); - - if (tdd_ul_dl_cfg_ded_present) { - HANDLE_CODE(tdd_ul_dl_cfg_ded.pack(bref)); - } - if (init_dl_bwp_present) { - HANDLE_CODE(init_dl_bwp.pack(bref)); - } - if (dl_bwp_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, dl_bwp_to_release_list, 1, 4, integer_packer(0, 4))); - } - if (dl_bwp_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, dl_bwp_to_add_mod_list, 1, 4)); - } - if (first_active_dl_bwp_id_present) { - HANDLE_CODE(pack_integer(bref, first_active_dl_bwp_id, (uint8_t)0u, (uint8_t)4u)); - } - if (bwp_inactivity_timer_present) { - HANDLE_CODE(bwp_inactivity_timer.pack(bref)); - } - if (default_dl_bwp_id_present) { - HANDLE_CODE(pack_integer(bref, default_dl_bwp_id, (uint8_t)0u, (uint8_t)4u)); - } - if (ul_cfg_present) { - HANDLE_CODE(ul_cfg.pack(bref)); - } - if (supplementary_ul_present) { - HANDLE_CODE(supplementary_ul.pack(bref)); - } - if (pdcch_serving_cell_cfg_present) { - HANDLE_CODE(pdcch_serving_cell_cfg.pack(bref)); - } - if (pdsch_serving_cell_cfg_present) { - HANDLE_CODE(pdsch_serving_cell_cfg.pack(bref)); - } - if (csi_meas_cfg_present) { - HANDLE_CODE(csi_meas_cfg.pack(bref)); - } - if (scell_deactivation_timer_present) { - HANDLE_CODE(scell_deactivation_timer.pack(bref)); - } - if (cross_carrier_sched_cfg_present) { - HANDLE_CODE(cross_carrier_sched_cfg.pack(bref)); - } - HANDLE_CODE(pack_integer(bref, tag_id, (uint8_t)0u, (uint8_t)3u)); - if (pathloss_ref_linking_present) { - HANDLE_CODE(pathloss_ref_linking.pack(bref)); + type_.pack(bref); + switch (type_) { + case types::rrc_setup_complete: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } - if (serving_cell_mo_present) { - HANDLE_CODE(pack_integer(bref, serving_cell_mo, (uint8_t)1u, (uint8_t)64u)); + return SRSASN_SUCCESS; +} +SRSASN_CODE rrc_setup_complete_s::crit_exts_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::rrc_setup_complete: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; } + return SRSASN_SUCCESS; +} - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= lte_crs_to_match_around.is_present(); - group_flags[0] |= rate_match_pattern_to_add_mod_list.is_present(); - group_flags[0] |= rate_match_pattern_to_release_list.is_present(); - group_flags[0] |= dl_ch_bw_per_scs_list.is_present(); - group_flags.pack(bref); +std::string rrc_setup_complete_s::crit_exts_c_::types_opts::to_string() const +{ + static const char* options[] = {"rrcSetupComplete", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "rrc_setup_complete_s::crit_exts_c_::types"); +} - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); +// SCGFailureInformation ::= SEQUENCE +SRSASN_CODE scg_fail_info_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(crit_exts.pack(bref)); - HANDLE_CODE(bref.pack(lte_crs_to_match_around.is_present(), 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_to_add_mod_list.is_present(), 1)); - HANDLE_CODE(bref.pack(rate_match_pattern_to_release_list.is_present(), 1)); - HANDLE_CODE(bref.pack(dl_ch_bw_per_scs_list.is_present(), 1)); - if (lte_crs_to_match_around.is_present()) { - HANDLE_CODE(lte_crs_to_match_around->pack(bref)); - } - if (rate_match_pattern_to_add_mod_list.is_present()) { - HANDLE_CODE(pack_dyn_seq_of(bref, *rate_match_pattern_to_add_mod_list, 1, 4)); - } - if (rate_match_pattern_to_release_list.is_present()) { - HANDLE_CODE(pack_dyn_seq_of(bref, *rate_match_pattern_to_release_list, 1, 4, integer_packer(0, 3))); - } - if (dl_ch_bw_per_scs_list.is_present()) { - HANDLE_CODE(pack_dyn_seq_of(bref, *dl_ch_bw_per_scs_list, 1, 5)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE serving_cell_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE scg_fail_info_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(tdd_ul_dl_cfg_ded_present, 1)); - HANDLE_CODE(bref.unpack(init_dl_bwp_present, 1)); - HANDLE_CODE(bref.unpack(dl_bwp_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(dl_bwp_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(first_active_dl_bwp_id_present, 1)); - HANDLE_CODE(bref.unpack(bwp_inactivity_timer_present, 1)); - HANDLE_CODE(bref.unpack(default_dl_bwp_id_present, 1)); - HANDLE_CODE(bref.unpack(ul_cfg_present, 1)); - HANDLE_CODE(bref.unpack(supplementary_ul_present, 1)); - HANDLE_CODE(bref.unpack(pdcch_serving_cell_cfg_present, 1)); - HANDLE_CODE(bref.unpack(pdsch_serving_cell_cfg_present, 1)); - HANDLE_CODE(bref.unpack(csi_meas_cfg_present, 1)); - HANDLE_CODE(bref.unpack(scell_deactivation_timer_present, 1)); - HANDLE_CODE(bref.unpack(cross_carrier_sched_cfg_present, 1)); - HANDLE_CODE(bref.unpack(dummy_present, 1)); - HANDLE_CODE(bref.unpack(pathloss_ref_linking_present, 1)); - HANDLE_CODE(bref.unpack(serving_cell_mo_present, 1)); - - if (tdd_ul_dl_cfg_ded_present) { - HANDLE_CODE(tdd_ul_dl_cfg_ded.unpack(bref)); - } - if (init_dl_bwp_present) { - HANDLE_CODE(init_dl_bwp.unpack(bref)); - } - if (dl_bwp_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(dl_bwp_to_release_list, bref, 1, 4, integer_packer(0, 4))); - } - if (dl_bwp_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(dl_bwp_to_add_mod_list, bref, 1, 4)); - } - if (first_active_dl_bwp_id_present) { - HANDLE_CODE(unpack_integer(first_active_dl_bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); - } - if (bwp_inactivity_timer_present) { - HANDLE_CODE(bwp_inactivity_timer.unpack(bref)); - } - if (default_dl_bwp_id_present) { - HANDLE_CODE(unpack_integer(default_dl_bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); - } - if (ul_cfg_present) { - HANDLE_CODE(ul_cfg.unpack(bref)); - } - if (supplementary_ul_present) { - HANDLE_CODE(supplementary_ul.unpack(bref)); - } - if (pdcch_serving_cell_cfg_present) { - HANDLE_CODE(pdcch_serving_cell_cfg.unpack(bref)); - } - if (pdsch_serving_cell_cfg_present) { - HANDLE_CODE(pdsch_serving_cell_cfg.unpack(bref)); - } - if (csi_meas_cfg_present) { - HANDLE_CODE(csi_meas_cfg.unpack(bref)); - } - if (scell_deactivation_timer_present) { - HANDLE_CODE(scell_deactivation_timer.unpack(bref)); - } - if (cross_carrier_sched_cfg_present) { - HANDLE_CODE(cross_carrier_sched_cfg.unpack(bref)); - } - HANDLE_CODE(unpack_integer(tag_id, bref, (uint8_t)0u, (uint8_t)3u)); - if (pathloss_ref_linking_present) { - HANDLE_CODE(pathloss_ref_linking.unpack(bref)); - } - if (serving_cell_mo_present) { - HANDLE_CODE(unpack_integer(serving_cell_mo, bref, (uint8_t)1u, (uint8_t)64u)); - } - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(crit_exts.unpack(bref)); - bool lte_crs_to_match_around_present; - HANDLE_CODE(bref.unpack(lte_crs_to_match_around_present, 1)); - lte_crs_to_match_around.set_present(lte_crs_to_match_around_present); - bool rate_match_pattern_to_add_mod_list_present; - HANDLE_CODE(bref.unpack(rate_match_pattern_to_add_mod_list_present, 1)); - rate_match_pattern_to_add_mod_list.set_present(rate_match_pattern_to_add_mod_list_present); - bool rate_match_pattern_to_release_list_present; - HANDLE_CODE(bref.unpack(rate_match_pattern_to_release_list_present, 1)); - rate_match_pattern_to_release_list.set_present(rate_match_pattern_to_release_list_present); - bool dl_ch_bw_per_scs_list_present; - HANDLE_CODE(bref.unpack(dl_ch_bw_per_scs_list_present, 1)); - dl_ch_bw_per_scs_list.set_present(dl_ch_bw_per_scs_list_present); - if (lte_crs_to_match_around.is_present()) { - HANDLE_CODE(lte_crs_to_match_around->unpack(bref)); - } - if (rate_match_pattern_to_add_mod_list.is_present()) { - HANDLE_CODE(unpack_dyn_seq_of(*rate_match_pattern_to_add_mod_list, bref, 1, 4)); - } - if (rate_match_pattern_to_release_list.is_present()) { - HANDLE_CODE(unpack_dyn_seq_of(*rate_match_pattern_to_release_list, bref, 1, 4, integer_packer(0, 3))); - } - if (dl_ch_bw_per_scs_list.is_present()) { - HANDLE_CODE(unpack_dyn_seq_of(*dl_ch_bw_per_scs_list, bref, 1, 5)); - } - } - } return SRSASN_SUCCESS; } -void serving_cell_cfg_s::to_json(json_writer& j) const +void scg_fail_info_s::to_json(json_writer& j) const { j.start_obj(); - if (tdd_ul_dl_cfg_ded_present) { - j.write_fieldname("tdd-UL-DL-ConfigurationDedicated"); - tdd_ul_dl_cfg_ded.to_json(j); - } - if (init_dl_bwp_present) { - j.write_fieldname("initialDownlinkBWP"); - init_dl_bwp.to_json(j); - } - if (dl_bwp_to_release_list_present) { - j.start_array("downlinkBWP-ToReleaseList"); - for (const auto& e1 : dl_bwp_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (dl_bwp_to_add_mod_list_present) { - j.start_array("downlinkBWP-ToAddModList"); - for (const auto& e1 : dl_bwp_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (first_active_dl_bwp_id_present) { - j.write_int("firstActiveDownlinkBWP-Id", first_active_dl_bwp_id); - } - if (bwp_inactivity_timer_present) { - j.write_str("bwp-InactivityTimer", bwp_inactivity_timer.to_string()); - } - if (default_dl_bwp_id_present) { - j.write_int("defaultDownlinkBWP-Id", default_dl_bwp_id); - } - if (ul_cfg_present) { - j.write_fieldname("uplinkConfig"); - ul_cfg.to_json(j); - } - if (supplementary_ul_present) { - j.write_fieldname("supplementaryUplink"); - supplementary_ul.to_json(j); - } - if (pdcch_serving_cell_cfg_present) { - j.write_fieldname("pdcch-ServingCellConfig"); - pdcch_serving_cell_cfg.to_json(j); - } - if (pdsch_serving_cell_cfg_present) { - j.write_fieldname("pdsch-ServingCellConfig"); - pdsch_serving_cell_cfg.to_json(j); - } - if (csi_meas_cfg_present) { - j.write_fieldname("csi-MeasConfig"); - csi_meas_cfg.to_json(j); - } - if (scell_deactivation_timer_present) { - j.write_str("sCellDeactivationTimer", scell_deactivation_timer.to_string()); - } - if (cross_carrier_sched_cfg_present) { - j.write_fieldname("crossCarrierSchedulingConfig"); - cross_carrier_sched_cfg.to_json(j); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void scg_fail_info_s::crit_exts_c_::destroy_() +{ + switch (type_) { + case types::scg_fail_info: + c.destroy(); + break; + default: + break; } - j.write_int("tag-Id", tag_id); - if (dummy_present) { - j.write_str("dummy", "enabled"); +} +void scg_fail_info_s::crit_exts_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::scg_fail_info: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_s::crit_exts_c_"); } - if (pathloss_ref_linking_present) { - j.write_str("pathlossReferenceLinking", pathloss_ref_linking.to_string()); +} +scg_fail_info_s::crit_exts_c_::crit_exts_c_(const scg_fail_info_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::scg_fail_info: + c.init(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_s::crit_exts_c_"); } - if (serving_cell_mo_present) { - j.write_int("servingCellMO", serving_cell_mo); +} +scg_fail_info_s::crit_exts_c_& scg_fail_info_s::crit_exts_c_::operator=(const scg_fail_info_s::crit_exts_c_& other) +{ + if (this == &other) { + return *this; } - if (ext) { - if (lte_crs_to_match_around.is_present()) { - j.write_fieldname("lte-CRS-ToMatchAround"); - lte_crs_to_match_around->to_json(j); - } - if (rate_match_pattern_to_add_mod_list.is_present()) { - j.start_array("rateMatchPatternToAddModList"); - for (const auto& e1 : *rate_match_pattern_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (rate_match_pattern_to_release_list.is_present()) { - j.start_array("rateMatchPatternToReleaseList"); - for (const auto& e1 : *rate_match_pattern_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (dl_ch_bw_per_scs_list.is_present()) { - j.start_array("downlinkChannelBW-PerSCS-List"); - for (const auto& e1 : *dl_ch_bw_per_scs_list) { - e1.to_json(j); - } - j.end_array(); - } + set(other.type()); + switch (type_) { + case types::scg_fail_info: + c.set(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_s::crit_exts_c_"); } - j.end_obj(); -} -std::string serving_cell_cfg_s::bwp_inactivity_timer_opts::to_string() const -{ - static const char* options[] = {"ms2", "ms3", "ms4", "ms5", "ms6", "ms8", "ms10", "ms20", - "ms30", "ms40", "ms50", "ms60", "ms80", "ms100", "ms200", "ms300", - "ms500", "ms750", "ms1280", "ms1920", "ms2560", "spare10", "spare9", "spare8", - "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 31, value, "serving_cell_cfg_s::bwp_inactivity_timer_e_"); + return *this; } -uint16_t serving_cell_cfg_s::bwp_inactivity_timer_opts::to_number() const +void scg_fail_info_s::crit_exts_c_::to_json(json_writer& j) const { - static const uint16_t options[] = {2, 3, 4, 5, 6, 8, 10, 20, 30, 40, 50, - 60, 80, 100, 200, 300, 500, 750, 1280, 1920, 2560}; - return map_enum_number(options, 21, value, "serving_cell_cfg_s::bwp_inactivity_timer_e_"); + j.start_obj(); + switch (type_) { + case types::scg_fail_info: + j.write_fieldname("scgFailureInformation"); + c.get().to_json(j); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_s::crit_exts_c_"); + } + j.end_obj(); } - -std::string serving_cell_cfg_s::scell_deactivation_timer_opts::to_string() const +SRSASN_CODE scg_fail_info_s::crit_exts_c_::pack(bit_ref& bref) const { - static const char* options[] = {"ms20", - "ms40", - "ms80", - "ms160", - "ms200", - "ms240", - "ms320", - "ms400", - "ms480", - "ms520", - "ms640", - "ms720", - "ms840", - "ms1280", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "serving_cell_cfg_s::scell_deactivation_timer_e_"); + type_.pack(bref); + switch (type_) { + case types::scg_fail_info: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } -uint16_t serving_cell_cfg_s::scell_deactivation_timer_opts::to_number() const +SRSASN_CODE scg_fail_info_s::crit_exts_c_::unpack(cbit_ref& bref) { - static const uint16_t options[] = {20, 40, 80, 160, 200, 240, 320, 400, 480, 520, 640, 720, 840, 1280}; - return map_enum_number(options, 14, value, "serving_cell_cfg_s::scell_deactivation_timer_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::scg_fail_info: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -std::string serving_cell_cfg_s::pathloss_ref_linking_opts::to_string() const +std::string scg_fail_info_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"pCell", "sCell"}; - return convert_enum_idx(options, 2, value, "serving_cell_cfg_s::pathloss_ref_linking_e_"); + static const char* options[] = {"scgFailureInformation", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "scg_fail_info_s::crit_exts_c_::types"); } -// TAG-Config ::= SEQUENCE -SRSASN_CODE tag_cfg_s::pack(bit_ref& bref) const +// SCGFailureInformationEUTRA ::= SEQUENCE +SRSASN_CODE scg_fail_info_eutra_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(tag_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(tag_to_add_mod_list_present, 1)); - - if (tag_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, tag_to_release_list, 1, 4, integer_packer(0, 3))); - } - if (tag_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, tag_to_add_mod_list, 1, 4)); - } + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE tag_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE scg_fail_info_eutra_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(tag_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(tag_to_add_mod_list_present, 1)); - - if (tag_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(tag_to_release_list, bref, 1, 4, integer_packer(0, 3))); - } - if (tag_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(tag_to_add_mod_list, bref, 1, 4)); - } + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void tag_cfg_s::to_json(json_writer& j) const +void scg_fail_info_eutra_s::to_json(json_writer& j) const { j.start_obj(); - if (tag_to_release_list_present) { - j.start_array("tag-ToReleaseList"); - for (const auto& e1 : tag_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (tag_to_add_mod_list_present) { - j.start_array("tag-ToAddModList"); - for (const auto& e1 : tag_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -// MAC-CellGroupConfig ::= SEQUENCE -SRSASN_CODE mac_cell_group_cfg_s::pack(bit_ref& bref) const +void scg_fail_info_eutra_s::crit_exts_c_::destroy_() { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(drx_cfg_present, 1)); - HANDLE_CODE(bref.pack(sched_request_cfg_present, 1)); - HANDLE_CODE(bref.pack(bsr_cfg_present, 1)); - HANDLE_CODE(bref.pack(tag_cfg_present, 1)); - HANDLE_CODE(bref.pack(phr_cfg_present, 1)); - - if (drx_cfg_present) { - HANDLE_CODE(drx_cfg.pack(bref)); - } - if (sched_request_cfg_present) { - HANDLE_CODE(sched_request_cfg.pack(bref)); - } - if (bsr_cfg_present) { - HANDLE_CODE(bsr_cfg.pack(bref)); - } - if (tag_cfg_present) { - HANDLE_CODE(tag_cfg.pack(bref)); - } - if (phr_cfg_present) { - HANDLE_CODE(phr_cfg.pack(bref)); - } - HANDLE_CODE(bref.pack(skip_ul_tx_dynamic, 1)); - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= csi_mask_v1530_present; - group_flags[0] |= data_inactivity_timer_v1530.is_present(); - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(csi_mask_v1530_present, 1)); - HANDLE_CODE(bref.pack(data_inactivity_timer_v1530.is_present(), 1)); - if (csi_mask_v1530_present) { - HANDLE_CODE(bref.pack(csi_mask_v1530, 1)); - } - if (data_inactivity_timer_v1530.is_present()) { - HANDLE_CODE(data_inactivity_timer_v1530->pack(bref)); - } - } + switch (type_) { + case types::scg_fail_info_eutra: + c.destroy(); + break; + default: + break; } - return SRSASN_SUCCESS; } -SRSASN_CODE mac_cell_group_cfg_s::unpack(cbit_ref& bref) +void scg_fail_info_eutra_s::crit_exts_c_::set(types::options e) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(drx_cfg_present, 1)); - HANDLE_CODE(bref.unpack(sched_request_cfg_present, 1)); - HANDLE_CODE(bref.unpack(bsr_cfg_present, 1)); - HANDLE_CODE(bref.unpack(tag_cfg_present, 1)); - HANDLE_CODE(bref.unpack(phr_cfg_present, 1)); - - if (drx_cfg_present) { - HANDLE_CODE(drx_cfg.unpack(bref)); - } - if (sched_request_cfg_present) { - HANDLE_CODE(sched_request_cfg.unpack(bref)); + destroy_(); + type_ = e; + switch (type_) { + case types::scg_fail_info_eutra: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_eutra_s::crit_exts_c_"); } - if (bsr_cfg_present) { - HANDLE_CODE(bsr_cfg.unpack(bref)); +} +scg_fail_info_eutra_s::crit_exts_c_::crit_exts_c_(const scg_fail_info_eutra_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::scg_fail_info_eutra: + c.init(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_eutra_s::crit_exts_c_"); } - if (tag_cfg_present) { - HANDLE_CODE(tag_cfg.unpack(bref)); +} +scg_fail_info_eutra_s::crit_exts_c_& +scg_fail_info_eutra_s::crit_exts_c_::operator=(const scg_fail_info_eutra_s::crit_exts_c_& other) +{ + if (this == &other) { + return *this; } - if (phr_cfg_present) { - HANDLE_CODE(phr_cfg.unpack(bref)); + set(other.type()); + switch (type_) { + case types::scg_fail_info_eutra: + c.set(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_eutra_s::crit_exts_c_"); } - HANDLE_CODE(bref.unpack(skip_ul_tx_dynamic, 1)); - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.unpack(csi_mask_v1530_present, 1)); - bool data_inactivity_timer_v1530_present; - HANDLE_CODE(bref.unpack(data_inactivity_timer_v1530_present, 1)); - data_inactivity_timer_v1530.set_present(data_inactivity_timer_v1530_present); - if (csi_mask_v1530_present) { - HANDLE_CODE(bref.unpack(csi_mask_v1530, 1)); - } - if (data_inactivity_timer_v1530.is_present()) { - HANDLE_CODE(data_inactivity_timer_v1530->unpack(bref)); - } - } - } - return SRSASN_SUCCESS; + return *this; } -void mac_cell_group_cfg_s::to_json(json_writer& j) const +void scg_fail_info_eutra_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); - if (drx_cfg_present) { - j.write_fieldname("drx-Config"); - drx_cfg.to_json(j); - } - if (sched_request_cfg_present) { - j.write_fieldname("schedulingRequestConfig"); - sched_request_cfg.to_json(j); - } - if (bsr_cfg_present) { - j.write_fieldname("bsr-Config"); - bsr_cfg.to_json(j); - } - if (tag_cfg_present) { - j.write_fieldname("tag-Config"); - tag_cfg.to_json(j); - } - if (phr_cfg_present) { - j.write_fieldname("phr-Config"); - phr_cfg.to_json(j); - } - j.write_bool("skipUplinkTxDynamic", skip_ul_tx_dynamic); - if (ext) { - if (csi_mask_v1530_present) { - j.write_bool("csi-Mask-v1530", csi_mask_v1530); - } - if (data_inactivity_timer_v1530.is_present()) { - j.write_fieldname("dataInactivityTimer-v1530"); - data_inactivity_timer_v1530->to_json(j); - } + switch (type_) { + case types::scg_fail_info_eutra: + j.write_fieldname("scgFailureInformationEUTRA"); + c.get().to_json(j); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_eutra_s::crit_exts_c_"); } j.end_obj(); } - -// PhysicalCellGroupConfig ::= SEQUENCE -SRSASN_CODE phys_cell_group_cfg_s::pack(bit_ref& bref) const +SRSASN_CODE scg_fail_info_eutra_s::crit_exts_c_::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(harq_ack_spatial_bundling_pucch_present, 1)); - HANDLE_CODE(bref.pack(harq_ack_spatial_bundling_pusch_present, 1)); - HANDLE_CODE(bref.pack(p_nr_fr1_present, 1)); - HANDLE_CODE(bref.pack(tpc_srs_rnti_present, 1)); - HANDLE_CODE(bref.pack(tpc_pucch_rnti_present, 1)); - HANDLE_CODE(bref.pack(tpc_pusch_rnti_present, 1)); - HANDLE_CODE(bref.pack(sp_csi_rnti_present, 1)); - HANDLE_CODE(bref.pack(cs_rnti_present, 1)); - - if (p_nr_fr1_present) { - HANDLE_CODE(pack_integer(bref, p_nr_fr1, (int8_t)-30, (int8_t)33)); - } - HANDLE_CODE(pdsch_harq_ack_codebook.pack(bref)); - if (tpc_srs_rnti_present) { - HANDLE_CODE(pack_integer(bref, tpc_srs_rnti, (uint32_t)0u, (uint32_t)65535u)); - } - if (tpc_pucch_rnti_present) { - HANDLE_CODE(pack_integer(bref, tpc_pucch_rnti, (uint32_t)0u, (uint32_t)65535u)); - } - if (tpc_pusch_rnti_present) { - HANDLE_CODE(pack_integer(bref, tpc_pusch_rnti, (uint32_t)0u, (uint32_t)65535u)); - } - if (sp_csi_rnti_present) { - HANDLE_CODE(pack_integer(bref, sp_csi_rnti, (uint32_t)0u, (uint32_t)65535u)); - } - if (cs_rnti_present) { - HANDLE_CODE(cs_rnti.pack(bref)); - } - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= mcs_c_rnti_present; - group_flags[0] |= p_ue_fr1_present; - group_flags[1] |= xscale_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(mcs_c_rnti_present, 1)); - HANDLE_CODE(bref.pack(p_ue_fr1_present, 1)); - if (mcs_c_rnti_present) { - HANDLE_CODE(pack_integer(bref, mcs_c_rnti, (uint32_t)0u, (uint32_t)65535u)); - } - if (p_ue_fr1_present) { - HANDLE_CODE(pack_integer(bref, p_ue_fr1, (int8_t)-30, (int8_t)33)); - } - } - if (group_flags[1]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(xscale_present, 1)); - if (xscale_present) { - HANDLE_CODE(xscale.pack(bref)); - } - } + type_.pack(bref); + switch (type_) { + case types::scg_fail_info_eutra: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_eutra_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE phys_cell_group_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE scg_fail_info_eutra_s::crit_exts_c_::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(harq_ack_spatial_bundling_pucch_present, 1)); - HANDLE_CODE(bref.unpack(harq_ack_spatial_bundling_pusch_present, 1)); - HANDLE_CODE(bref.unpack(p_nr_fr1_present, 1)); - HANDLE_CODE(bref.unpack(tpc_srs_rnti_present, 1)); - HANDLE_CODE(bref.unpack(tpc_pucch_rnti_present, 1)); - HANDLE_CODE(bref.unpack(tpc_pusch_rnti_present, 1)); - HANDLE_CODE(bref.unpack(sp_csi_rnti_present, 1)); - HANDLE_CODE(bref.unpack(cs_rnti_present, 1)); - - if (p_nr_fr1_present) { - HANDLE_CODE(unpack_integer(p_nr_fr1, bref, (int8_t)-30, (int8_t)33)); - } - HANDLE_CODE(pdsch_harq_ack_codebook.unpack(bref)); - if (tpc_srs_rnti_present) { - HANDLE_CODE(unpack_integer(tpc_srs_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (tpc_pucch_rnti_present) { - HANDLE_CODE(unpack_integer(tpc_pucch_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (tpc_pusch_rnti_present) { - HANDLE_CODE(unpack_integer(tpc_pusch_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (sp_csi_rnti_present) { - HANDLE_CODE(unpack_integer(sp_csi_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (cs_rnti_present) { - HANDLE_CODE(cs_rnti.unpack(bref)); - } - - if (ext) { - ext_groups_unpacker_guard group_flags(2); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(mcs_c_rnti_present, 1)); - HANDLE_CODE(bref.unpack(p_ue_fr1_present, 1)); - if (mcs_c_rnti_present) { - HANDLE_CODE(unpack_integer(mcs_c_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - } - if (p_ue_fr1_present) { - HANDLE_CODE(unpack_integer(p_ue_fr1, bref, (int8_t)-30, (int8_t)33)); - } - } - if (group_flags[1]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(xscale_present, 1)); - if (xscale_present) { - HANDLE_CODE(xscale.unpack(bref)); - } - } + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::scg_fail_info_eutra: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "scg_fail_info_eutra_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void phys_cell_group_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (harq_ack_spatial_bundling_pucch_present) { - j.write_str("harq-ACK-SpatialBundlingPUCCH", "true"); - } - if (harq_ack_spatial_bundling_pusch_present) { - j.write_str("harq-ACK-SpatialBundlingPUSCH", "true"); - } - if (p_nr_fr1_present) { - j.write_int("p-NR-FR1", p_nr_fr1); - } - j.write_str("pdsch-HARQ-ACK-Codebook", pdsch_harq_ack_codebook.to_string()); - if (tpc_srs_rnti_present) { - j.write_int("tpc-SRS-RNTI", tpc_srs_rnti); - } - if (tpc_pucch_rnti_present) { - j.write_int("tpc-PUCCH-RNTI", tpc_pucch_rnti); - } - if (tpc_pusch_rnti_present) { - j.write_int("tpc-PUSCH-RNTI", tpc_pusch_rnti); - } - if (sp_csi_rnti_present) { - j.write_int("sp-CSI-RNTI", sp_csi_rnti); - } - if (cs_rnti_present) { - j.write_fieldname("cs-RNTI"); - cs_rnti.to_json(j); - } - if (ext) { - if (mcs_c_rnti_present) { - j.write_int("mcs-C-RNTI", mcs_c_rnti); - } - if (p_ue_fr1_present) { - j.write_int("p-UE-FR1", p_ue_fr1); - } - if (xscale_present) { - j.write_str("xScale", xscale.to_string()); - } - } - j.end_obj(); -} - -std::string phys_cell_group_cfg_s::pdsch_harq_ack_codebook_opts::to_string() const -{ - static const char* options[] = {"semiStatic", "dynamic"}; - return convert_enum_idx(options, 2, value, "phys_cell_group_cfg_s::pdsch_harq_ack_codebook_e_"); -} -std::string phys_cell_group_cfg_s::xscale_opts::to_string() const -{ - static const char* options[] = {"dB0", "dB6", "spare2", "spare1"}; - return convert_enum_idx(options, 4, value, "phys_cell_group_cfg_s::xscale_e_"); -} -uint8_t phys_cell_group_cfg_s::xscale_opts::to_number() const +std::string scg_fail_info_eutra_s::crit_exts_c_::types_opts::to_string() const { - static const uint8_t options[] = {0, 6}; - return map_enum_number(options, 2, value, "phys_cell_group_cfg_s::xscale_e_"); + static const char* options[] = {"scgFailureInformationEUTRA", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "scg_fail_info_eutra_s::crit_exts_c_::types"); } -// RLC-BearerConfig ::= SEQUENCE -SRSASN_CODE rlc_bearer_cfg_s::pack(bit_ref& bref) const +// SecurityModeComplete ::= SEQUENCE +SRSASN_CODE security_mode_complete_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(served_radio_bearer_present, 1)); - HANDLE_CODE(bref.pack(reestablish_rlc_present, 1)); - HANDLE_CODE(bref.pack(rlc_cfg_present, 1)); - HANDLE_CODE(bref.pack(mac_lc_ch_cfg_present, 1)); - - HANDLE_CODE(pack_integer(bref, lc_ch_id, (uint8_t)1u, (uint8_t)32u)); - if (served_radio_bearer_present) { - HANDLE_CODE(served_radio_bearer.pack(bref)); - } - if (rlc_cfg_present) { - HANDLE_CODE(rlc_cfg.pack(bref)); - } - if (mac_lc_ch_cfg_present) { - HANDLE_CODE(mac_lc_ch_cfg.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE rlc_bearer_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE security_mode_complete_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(served_radio_bearer_present, 1)); - HANDLE_CODE(bref.unpack(reestablish_rlc_present, 1)); - HANDLE_CODE(bref.unpack(rlc_cfg_present, 1)); - HANDLE_CODE(bref.unpack(mac_lc_ch_cfg_present, 1)); - - HANDLE_CODE(unpack_integer(lc_ch_id, bref, (uint8_t)1u, (uint8_t)32u)); - if (served_radio_bearer_present) { - HANDLE_CODE(served_radio_bearer.unpack(bref)); - } - if (rlc_cfg_present) { - HANDLE_CODE(rlc_cfg.unpack(bref)); - } - if (mac_lc_ch_cfg_present) { - HANDLE_CODE(mac_lc_ch_cfg.unpack(bref)); - } + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void rlc_bearer_cfg_s::to_json(json_writer& j) const +void security_mode_complete_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("logicalChannelIdentity", lc_ch_id); - if (served_radio_bearer_present) { - j.write_fieldname("servedRadioBearer"); - served_radio_bearer.to_json(j); - } - if (reestablish_rlc_present) { - j.write_str("reestablishRLC", "true"); - } - if (rlc_cfg_present) { - j.write_fieldname("rlc-Config"); - rlc_cfg.to_json(j); - } - if (mac_lc_ch_cfg_present) { - j.write_fieldname("mac-LogicalChannelConfig"); - mac_lc_ch_cfg.to_json(j); - } + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -void rlc_bearer_cfg_s::served_radio_bearer_c_::destroy_() {} -void rlc_bearer_cfg_s::served_radio_bearer_c_::set(types::options e) +void security_mode_complete_s::crit_exts_c_::destroy_() +{ + switch (type_) { + case types::security_mode_complete: + c.destroy(); + break; + default: + break; + } +} +void security_mode_complete_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; + switch (type_) { + case types::security_mode_complete: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); + } } -rlc_bearer_cfg_s::served_radio_bearer_c_::served_radio_bearer_c_(const rlc_bearer_cfg_s::served_radio_bearer_c_& other) +security_mode_complete_s::crit_exts_c_::crit_exts_c_(const security_mode_complete_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::srb_id: - c.init(other.c.get()); + case types::security_mode_complete: + c.init(other.c.get()); break; - case types::drb_id: - c.init(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); + log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); } } -rlc_bearer_cfg_s::served_radio_bearer_c_& rlc_bearer_cfg_s::served_radio_bearer_c_:: - operator=(const rlc_bearer_cfg_s::served_radio_bearer_c_& other) +security_mode_complete_s::crit_exts_c_& +security_mode_complete_s::crit_exts_c_::operator=(const security_mode_complete_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::srb_id: - c.set(other.c.get()); + case types::security_mode_complete: + c.set(other.c.get()); break; - case types::drb_id: - c.set(other.c.get()); + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); + log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); } return *this; } -void rlc_bearer_cfg_s::served_radio_bearer_c_::to_json(json_writer& j) const +void security_mode_complete_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::srb_id: - j.write_int("srb-Identity", c.get()); + case types::security_mode_complete: + j.write_fieldname("securityModeComplete"); + c.get().to_json(j); break; - case types::drb_id: - j.write_int("drb-Identity", c.get()); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); + log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE rlc_bearer_cfg_s::served_radio_bearer_c_::pack(bit_ref& bref) const +SRSASN_CODE security_mode_complete_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::srb_id: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)3u)); + case types::security_mode_complete: + HANDLE_CODE(c.get().pack(bref)); break; - case types::drb_id: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)32u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); + log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rlc_bearer_cfg_s::served_radio_bearer_c_::unpack(cbit_ref& bref) +SRSASN_CODE security_mode_complete_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::srb_id: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)3u)); + case types::security_mode_complete: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::drb_id: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)32u)); + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); + log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rlc_bearer_cfg_s::served_radio_bearer_c_::types_opts::to_string() const +std::string security_mode_complete_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"srb-Identity", "drb-Identity"}; - return convert_enum_idx(options, 2, value, "rlc_bearer_cfg_s::served_radio_bearer_c_::types"); + static const char* options[] = {"securityModeComplete", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "security_mode_complete_s::crit_exts_c_::types"); } -// SCellConfig ::= SEQUENCE -SRSASN_CODE scell_cfg_s::pack(bit_ref& bref) const +// SecurityModeFailure ::= SEQUENCE +SRSASN_CODE security_mode_fail_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(scell_cfg_common_present, 1)); - HANDLE_CODE(bref.pack(scell_cfg_ded_present, 1)); - - HANDLE_CODE(pack_integer(bref, scell_idx, (uint8_t)1u, (uint8_t)31u)); - if (scell_cfg_common_present) { - HANDLE_CODE(scell_cfg_common.pack(bref)); - } - if (scell_cfg_ded_present) { - HANDLE_CODE(scell_cfg_ded.pack(bref)); - } - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= smtc.is_present(); - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); - HANDLE_CODE(bref.pack(smtc.is_present(), 1)); - if (smtc.is_present()) { - HANDLE_CODE(smtc->pack(bref)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE scell_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE security_mode_fail_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(scell_cfg_common_present, 1)); - HANDLE_CODE(bref.unpack(scell_cfg_ded_present, 1)); + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); - HANDLE_CODE(unpack_integer(scell_idx, bref, (uint8_t)1u, (uint8_t)31u)); - if (scell_cfg_common_present) { - HANDLE_CODE(scell_cfg_common.unpack(bref)); - } - if (scell_cfg_ded_present) { - HANDLE_CODE(scell_cfg_ded.unpack(bref)); - } - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - bool smtc_present; - HANDLE_CODE(bref.unpack(smtc_present, 1)); - smtc.set_present(smtc_present); - if (smtc.is_present()) { - HANDLE_CODE(smtc->unpack(bref)); - } - } - } return SRSASN_SUCCESS; } -void scell_cfg_s::to_json(json_writer& j) const +void security_mode_fail_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("sCellIndex", scell_idx); - if (scell_cfg_common_present) { - j.write_fieldname("sCellConfigCommon"); - scell_cfg_common.to_json(j); - } - if (scell_cfg_ded_present) { - j.write_fieldname("sCellConfigDedicated"); - scell_cfg_ded.to_json(j); - } - if (ext) { - if (smtc.is_present()) { - j.write_fieldname("smtc"); - smtc->to_json(j); - } - } + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -// SecurityConfig ::= SEQUENCE -SRSASN_CODE security_cfg_s::pack(bit_ref& bref) const +void security_mode_fail_s::crit_exts_c_::destroy_() { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(security_algorithm_cfg_present, 1)); - HANDLE_CODE(bref.pack(key_to_use_present, 1)); - - if (security_algorithm_cfg_present) { - HANDLE_CODE(security_algorithm_cfg.pack(bref)); + switch (type_) { + case types::security_mode_fail: + c.destroy(); + break; + default: + break; } - if (key_to_use_present) { - HANDLE_CODE(key_to_use.pack(bref)); +} +void security_mode_fail_s::crit_exts_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::security_mode_fail: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); } - - return SRSASN_SUCCESS; } -SRSASN_CODE security_cfg_s::unpack(cbit_ref& bref) +security_mode_fail_s::crit_exts_c_::crit_exts_c_(const security_mode_fail_s::crit_exts_c_& other) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(security_algorithm_cfg_present, 1)); - HANDLE_CODE(bref.unpack(key_to_use_present, 1)); - - if (security_algorithm_cfg_present) { - HANDLE_CODE(security_algorithm_cfg.unpack(bref)); + type_ = other.type(); + switch (type_) { + case types::security_mode_fail: + c.init(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); } - if (key_to_use_present) { - HANDLE_CODE(key_to_use.unpack(bref)); +} +security_mode_fail_s::crit_exts_c_& +security_mode_fail_s::crit_exts_c_::operator=(const security_mode_fail_s::crit_exts_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::security_mode_fail: + c.set(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); } - return SRSASN_SUCCESS; + return *this; } -void security_cfg_s::to_json(json_writer& j) const +void security_mode_fail_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); - if (security_algorithm_cfg_present) { - j.write_fieldname("securityAlgorithmConfig"); - security_algorithm_cfg.to_json(j); - } - if (key_to_use_present) { - j.write_str("keyToUse", key_to_use.to_string()); + switch (type_) { + case types::security_mode_fail: + j.write_fieldname("securityModeFailure"); + c.get().to_json(j); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); } j.end_obj(); } - -std::string security_cfg_s::key_to_use_opts::to_string() const +SRSASN_CODE security_mode_fail_s::crit_exts_c_::pack(bit_ref& bref) const { - static const char* options[] = {"master", "secondary"}; - return convert_enum_idx(options, 2, value, "security_cfg_s::key_to_use_e_"); + type_.pack(bref); + switch (type_) { + case types::security_mode_fail: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE security_mode_fail_s::crit_exts_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::security_mode_fail: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -// SpCellConfig ::= SEQUENCE -SRSASN_CODE sp_cell_cfg_s::pack(bit_ref& bref) const +std::string security_mode_fail_s::crit_exts_c_::types_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(serv_cell_idx_present, 1)); - HANDLE_CODE(bref.pack(recfg_with_sync_present, 1)); - HANDLE_CODE(bref.pack(rlf_timers_and_consts_present, 1)); - HANDLE_CODE(bref.pack(rlm_in_sync_out_of_sync_thres_present, 1)); - HANDLE_CODE(bref.pack(sp_cell_cfg_ded_present, 1)); + static const char* options[] = {"securityModeFailure", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "security_mode_fail_s::crit_exts_c_::types"); +} - if (serv_cell_idx_present) { - HANDLE_CODE(pack_integer(bref, serv_cell_idx, (uint8_t)0u, (uint8_t)31u)); - } - if (recfg_with_sync_present) { - HANDLE_CODE(recfg_with_sync.pack(bref)); - } - if (rlf_timers_and_consts_present) { - HANDLE_CODE(rlf_timers_and_consts.pack(bref)); - } - if (sp_cell_cfg_ded_present) { - HANDLE_CODE(sp_cell_cfg_ded.pack(bref)); - } +// UEAssistanceInformation ::= SEQUENCE +SRSASN_CODE ueassist_info_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE sp_cell_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE ueassist_info_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(serv_cell_idx_present, 1)); - HANDLE_CODE(bref.unpack(recfg_with_sync_present, 1)); - HANDLE_CODE(bref.unpack(rlf_timers_and_consts_present, 1)); - HANDLE_CODE(bref.unpack(rlm_in_sync_out_of_sync_thres_present, 1)); - HANDLE_CODE(bref.unpack(sp_cell_cfg_ded_present, 1)); - - if (serv_cell_idx_present) { - HANDLE_CODE(unpack_integer(serv_cell_idx, bref, (uint8_t)0u, (uint8_t)31u)); - } - if (recfg_with_sync_present) { - HANDLE_CODE(recfg_with_sync.unpack(bref)); - } - if (rlf_timers_and_consts_present) { - HANDLE_CODE(rlf_timers_and_consts.unpack(bref)); - } - if (sp_cell_cfg_ded_present) { - HANDLE_CODE(sp_cell_cfg_ded.unpack(bref)); - } + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void sp_cell_cfg_s::to_json(json_writer& j) const +void ueassist_info_s::to_json(json_writer& j) const { j.start_obj(); - if (serv_cell_idx_present) { - j.write_int("servCellIndex", serv_cell_idx); - } - if (recfg_with_sync_present) { - j.write_fieldname("reconfigurationWithSync"); - recfg_with_sync.to_json(j); - } - if (rlf_timers_and_consts_present) { - j.write_fieldname("rlf-TimersAndConstants"); - rlf_timers_and_consts.to_json(j); - } - if (rlm_in_sync_out_of_sync_thres_present) { - j.write_str("rlmInSyncOutOfSyncThreshold", "n1"); - } - if (sp_cell_cfg_ded_present) { - j.write_fieldname("spCellConfigDedicated"); - sp_cell_cfg_ded.to_json(j); - } + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); j.end_obj(); } -// CellGroupConfig ::= SEQUENCE -SRSASN_CODE cell_group_cfg_s::pack(bit_ref& bref) const +void ueassist_info_s::crit_exts_c_::destroy_() { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(rlc_bearer_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(rlc_bearer_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(mac_cell_group_cfg_present, 1)); - HANDLE_CODE(bref.pack(phys_cell_group_cfg_present, 1)); - HANDLE_CODE(bref.pack(sp_cell_cfg_present, 1)); - HANDLE_CODE(bref.pack(scell_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(scell_to_release_list_present, 1)); - - HANDLE_CODE(pack_integer(bref, cell_group_id, (uint8_t)0u, (uint8_t)3u)); - if (rlc_bearer_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rlc_bearer_to_add_mod_list, 1, 32)); - } - if (rlc_bearer_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, rlc_bearer_to_release_list, 1, 32, integer_packer(1, 32))); - } - if (mac_cell_group_cfg_present) { - HANDLE_CODE(mac_cell_group_cfg.pack(bref)); - } - if (phys_cell_group_cfg_present) { - HANDLE_CODE(phys_cell_group_cfg.pack(bref)); - } - if (sp_cell_cfg_present) { - HANDLE_CODE(sp_cell_cfg.pack(bref)); - } - if (scell_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, scell_to_add_mod_list, 1, 31)); - } - if (scell_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, scell_to_release_list, 1, 31, integer_packer(1, 31))); - } - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= report_ul_tx_direct_current_v1530_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(report_ul_tx_direct_current_v1530_present, 1)); - } + switch (type_) { + case types::ue_assist_info: + c.destroy(); + break; + default: + break; } - return SRSASN_SUCCESS; } -SRSASN_CODE cell_group_cfg_s::unpack(cbit_ref& bref) +void ueassist_info_s::crit_exts_c_::set(types::options e) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(rlc_bearer_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(rlc_bearer_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(mac_cell_group_cfg_present, 1)); - HANDLE_CODE(bref.unpack(phys_cell_group_cfg_present, 1)); - HANDLE_CODE(bref.unpack(sp_cell_cfg_present, 1)); - HANDLE_CODE(bref.unpack(scell_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(scell_to_release_list_present, 1)); - - HANDLE_CODE(unpack_integer(cell_group_id, bref, (uint8_t)0u, (uint8_t)3u)); - if (rlc_bearer_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(rlc_bearer_to_add_mod_list, bref, 1, 32)); - } - if (rlc_bearer_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(rlc_bearer_to_release_list, bref, 1, 32, integer_packer(1, 32))); - } - if (mac_cell_group_cfg_present) { - HANDLE_CODE(mac_cell_group_cfg.unpack(bref)); - } - if (phys_cell_group_cfg_present) { - HANDLE_CODE(phys_cell_group_cfg.unpack(bref)); + destroy_(); + type_ = e; + switch (type_) { + case types::ue_assist_info: + c.init(); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); } - if (sp_cell_cfg_present) { - HANDLE_CODE(sp_cell_cfg.unpack(bref)); +} +ueassist_info_s::crit_exts_c_::crit_exts_c_(const ueassist_info_s::crit_exts_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::ue_assist_info: + c.init(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); } - if (scell_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(scell_to_add_mod_list, bref, 1, 31)); +} +ueassist_info_s::crit_exts_c_& ueassist_info_s::crit_exts_c_::operator=(const ueassist_info_s::crit_exts_c_& other) +{ + if (this == &other) { + return *this; } - if (scell_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(scell_to_release_list, bref, 1, 31, integer_packer(1, 31))); + set(other.type()); + switch (type_) { + case types::ue_assist_info: + c.set(other.c.get()); + break; + case types::crit_exts_future: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); } - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(report_ul_tx_direct_current_v1530_present, 1)); - } - } - return SRSASN_SUCCESS; + return *this; } -void cell_group_cfg_s::to_json(json_writer& j) const +void ueassist_info_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_int("cellGroupId", cell_group_id); - if (rlc_bearer_to_add_mod_list_present) { - j.start_array("rlc-BearerToAddModList"); - for (const auto& e1 : rlc_bearer_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (rlc_bearer_to_release_list_present) { - j.start_array("rlc-BearerToReleaseList"); - for (const auto& e1 : rlc_bearer_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (mac_cell_group_cfg_present) { - j.write_fieldname("mac-CellGroupConfig"); - mac_cell_group_cfg.to_json(j); - } - if (phys_cell_group_cfg_present) { - j.write_fieldname("physicalCellGroupConfig"); - phys_cell_group_cfg.to_json(j); - } - if (sp_cell_cfg_present) { - j.write_fieldname("spCellConfig"); - sp_cell_cfg.to_json(j); - } - if (scell_to_add_mod_list_present) { - j.start_array("sCellToAddModList"); - for (const auto& e1 : scell_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); + switch (type_) { + case types::ue_assist_info: + j.write_fieldname("ueAssistanceInformation"); + c.get().to_json(j); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); } - if (scell_to_release_list_present) { - j.start_array("sCellToReleaseList"); - for (const auto& e1 : scell_to_release_list) { - j.write_int(e1); - } - j.end_array(); + j.end_obj(); +} +SRSASN_CODE ueassist_info_s::crit_exts_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::ue_assist_info: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } - if (ext) { - if (report_ul_tx_direct_current_v1530_present) { - j.write_str("reportUplinkTxDirectCurrent-v1530", "true"); - } + return SRSASN_SUCCESS; +} +SRSASN_CODE ueassist_info_s::crit_exts_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ue_assist_info: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::crit_exts_future: + break; + default: + log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); + return SRSASN_ERROR_DECODE_FAIL; } - j.end_obj(); + return SRSASN_SUCCESS; } -// RadioBearerConfig ::= SEQUENCE -SRSASN_CODE radio_bearer_cfg_s::pack(bit_ref& bref) const +std::string ueassist_info_s::crit_exts_c_::types_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(srb_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(srb3_to_release_present, 1)); - HANDLE_CODE(bref.pack(drb_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(drb_to_release_list_present, 1)); - HANDLE_CODE(bref.pack(security_cfg_present, 1)); + static const char* options[] = {"ueAssistanceInformation", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "ueassist_info_s::crit_exts_c_::types"); +} - if (srb_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, srb_to_add_mod_list, 1, 2)); - } - if (drb_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, drb_to_add_mod_list, 1, 29)); - } - if (drb_to_release_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, drb_to_release_list, 1, 29, integer_packer(1, 32))); - } - if (security_cfg_present) { - HANDLE_CODE(security_cfg.pack(bref)); - } +// UECapabilityInformation ::= SEQUENCE +SRSASN_CODE ue_cap_info_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE radio_bearer_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE ue_cap_info_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(srb_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(srb3_to_release_present, 1)); - HANDLE_CODE(bref.unpack(drb_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(drb_to_release_list_present, 1)); - HANDLE_CODE(bref.unpack(security_cfg_present, 1)); - - if (srb_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(srb_to_add_mod_list, bref, 1, 2)); - } - if (drb_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(drb_to_add_mod_list, bref, 1, 29)); - } - if (drb_to_release_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(drb_to_release_list, bref, 1, 29, integer_packer(1, 32))); - } - if (security_cfg_present) { - HANDLE_CODE(security_cfg.unpack(bref)); - } + HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void radio_bearer_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (srb_to_add_mod_list_present) { - j.start_array("srb-ToAddModList"); - for (const auto& e1 : srb_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (srb3_to_release_present) { - j.write_str("srb3-ToRelease", "true"); - } - if (drb_to_add_mod_list_present) { - j.start_array("drb-ToAddModList"); - for (const auto& e1 : drb_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (drb_to_release_list_present) { - j.start_array("drb-ToReleaseList"); - for (const auto& e1 : drb_to_release_list) { - j.write_int(e1); - } - j.end_array(); - } - if (security_cfg_present) { - j.write_fieldname("securityConfig"); - security_cfg.to_json(j); - } - j.end_obj(); -} - -// RRCReject-IEs ::= SEQUENCE -SRSASN_CODE rrc_reject_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(wait_time_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (wait_time_present) { - HANDLE_CODE(pack_integer(bref, wait_time, (uint8_t)1u, (uint8_t)16u)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_reject_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(wait_time_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (wait_time_present) { - HANDLE_CODE(unpack_integer(wait_time, bref, (uint8_t)1u, (uint8_t)16u)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void rrc_reject_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (wait_time_present) { - j.write_int("waitTime", wait_time); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// RRCSetup-IEs ::= SEQUENCE -SRSASN_CODE rrc_setup_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - HANDLE_CODE(radio_bearer_cfg.pack(bref)); - HANDLE_CODE(master_cell_group.pack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_setup_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(radio_bearer_cfg.unpack(bref)); - HANDLE_CODE(master_cell_group.unpack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void rrc_setup_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("radioBearerConfig"); - radio_bearer_cfg.to_json(j); - j.write_str("masterCellGroup", master_cell_group.to_string()); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// RRCReject ::= SEQUENCE -SRSASN_CODE rrc_reject_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_reject_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(crit_exts.unpack(bref)); - - return SRSASN_SUCCESS; -} -void rrc_reject_s::to_json(json_writer& j) const +void ue_cap_info_s::to_json(json_writer& j) const { j.start_obj(); + j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); j.write_fieldname("criticalExtensions"); crit_exts.to_json(j); j.end_obj(); } -void rrc_reject_s::crit_exts_c_::destroy_() +void ue_cap_info_s::crit_exts_c_::destroy_() { switch (type_) { - case types::rrc_reject: - c.destroy(); + case types::ue_cap_info: + c.destroy(); break; default: break; } } -void rrc_reject_s::crit_exts_c_::set(types::options e) +void ue_cap_info_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::rrc_reject: - c.init(); + case types::ue_cap_info: + c.init(); break; case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); } } -rrc_reject_s::crit_exts_c_::crit_exts_c_(const rrc_reject_s::crit_exts_c_& other) +ue_cap_info_s::crit_exts_c_::crit_exts_c_(const ue_cap_info_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_reject: - c.init(other.c.get()); + case types::ue_cap_info: + c.init(other.c.get()); break; case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); } } -rrc_reject_s::crit_exts_c_& rrc_reject_s::crit_exts_c_::operator=(const rrc_reject_s::crit_exts_c_& other) +ue_cap_info_s::crit_exts_c_& ue_cap_info_s::crit_exts_c_::operator=(const ue_cap_info_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_reject: - c.set(other.c.get()); + case types::ue_cap_info: + c.set(other.c.get()); break; case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); } return *this; } -void rrc_reject_s::crit_exts_c_::to_json(json_writer& j) const +void ue_cap_info_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_reject: - j.write_fieldname("rrcReject"); - c.get().to_json(j); + case types::ue_cap_info: + j.write_fieldname("ueCapabilityInformation"); + c.get().to_json(j); break; case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE rrc_reject_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE ue_cap_info_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_reject: - HANDLE_CODE(c.get().pack(bref)); + case types::ue_cap_info: + HANDLE_CODE(c.get().pack(bref)); break; case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_reject_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE ue_cap_info_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_reject: - HANDLE_CODE(c.get().unpack(bref)); + case types::ue_cap_info: + HANDLE_CODE(c.get().unpack(bref)); break; case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rrc_reject_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_reject_s::crit_exts_c_::types_opts::to_string() const +std::string ue_cap_info_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"rrcReject", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_reject_s::crit_exts_c_::types"); + static const char* options[] = {"ueCapabilityInformation", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "ue_cap_info_s::crit_exts_c_::types"); } -// RRCSetup ::= SEQUENCE -SRSASN_CODE rrc_setup_s::pack(bit_ref& bref) const +// ULInformationTransfer ::= SEQUENCE +SRSASN_CODE ul_info_transfer_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); HANDLE_CODE(crit_exts.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE rrc_setup_s::unpack(cbit_ref& bref) +SRSASN_CODE ul_info_transfer_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); HANDLE_CODE(crit_exts.unpack(bref)); return SRSASN_SUCCESS; } -void rrc_setup_s::to_json(json_writer& j) const +void ul_info_transfer_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); j.write_fieldname("criticalExtensions"); crit_exts.to_json(j); j.end_obj(); } -void rrc_setup_s::crit_exts_c_::destroy_() +void ul_info_transfer_s::crit_exts_c_::destroy_() { switch (type_) { - case types::rrc_setup: - c.destroy(); + case types::ul_info_transfer: + c.destroy(); break; default: break; } } -void rrc_setup_s::crit_exts_c_::set(types::options e) +void ul_info_transfer_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::rrc_setup: - c.init(); + case types::ul_info_transfer: + c.init(); break; case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); } } -rrc_setup_s::crit_exts_c_::crit_exts_c_(const rrc_setup_s::crit_exts_c_& other) +ul_info_transfer_s::crit_exts_c_::crit_exts_c_(const ul_info_transfer_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_setup: - c.init(other.c.get()); + case types::ul_info_transfer: + c.init(other.c.get()); break; case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); } } -rrc_setup_s::crit_exts_c_& rrc_setup_s::crit_exts_c_::operator=(const rrc_setup_s::crit_exts_c_& other) +ul_info_transfer_s::crit_exts_c_& +ul_info_transfer_s::crit_exts_c_::operator=(const ul_info_transfer_s::crit_exts_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_setup: - c.set(other.c.get()); + case types::ul_info_transfer: + c.set(other.c.get()); break; case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); } return *this; } -void rrc_setup_s::crit_exts_c_::to_json(json_writer& j) const +void ul_info_transfer_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_setup: - j.write_fieldname("rrcSetup"); - c.get().to_json(j); + case types::ul_info_transfer: + j.write_fieldname("ulInformationTransfer"); + c.get().to_json(j); break; case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE rrc_setup_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE ul_info_transfer_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_setup: - HANDLE_CODE(c.get().pack(bref)); + case types::ul_info_transfer: + HANDLE_CODE(c.get().pack(bref)); break; case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_setup_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE ul_info_transfer_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_setup: - HANDLE_CODE(c.get().unpack(bref)); + case types::ul_info_transfer: + HANDLE_CODE(c.get().unpack(bref)); break; case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "rrc_setup_s::crit_exts_c_"); + log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_setup_s::crit_exts_c_::types_opts::to_string() const +std::string ul_info_transfer_s::crit_exts_c_::types_opts::to_string() const { - static const char* options[] = {"rrcSetup", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_setup_s::crit_exts_c_::types"); + static const char* options[] = {"ulInformationTransfer", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "ul_info_transfer_s::crit_exts_c_::types"); } -// DL-CCCH-MessageType ::= CHOICE -void dl_ccch_msg_type_c::destroy_() +// ULInformationTransferMRDC ::= SEQUENCE +SRSASN_CODE ul_info_transfer_mrdc_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(crit_exts.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE ul_info_transfer_mrdc_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(crit_exts.unpack(bref)); + + return SRSASN_SUCCESS; +} +void ul_info_transfer_mrdc_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_fieldname("criticalExtensions"); + crit_exts.to_json(j); + j.end_obj(); +} + +void ul_info_transfer_mrdc_s::crit_exts_c_::destroy_() { switch (type_) { case types::c1: @@ -28219,7 +24506,7 @@ void dl_ccch_msg_type_c::destroy_() break; } } -void dl_ccch_msg_type_c::set(types::options e) +void ul_info_transfer_mrdc_s::crit_exts_c_::set(types::options e) { destroy_(); type_ = e; @@ -28227,30 +24514,31 @@ void dl_ccch_msg_type_c::set(types::options e) case types::c1: c.init(); break; - case types::msg_class_ext: + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_"); } } -dl_ccch_msg_type_c::dl_ccch_msg_type_c(const dl_ccch_msg_type_c& other) +ul_info_transfer_mrdc_s::crit_exts_c_::crit_exts_c_(const ul_info_transfer_mrdc_s::crit_exts_c_& other) { type_ = other.type(); switch (type_) { case types::c1: c.init(other.c.get()); break; - case types::msg_class_ext: + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_"); } } -dl_ccch_msg_type_c& dl_ccch_msg_type_c::operator=(const dl_ccch_msg_type_c& other) +ul_info_transfer_mrdc_s::crit_exts_c_& +ul_info_transfer_mrdc_s::crit_exts_c_::operator=(const ul_info_transfer_mrdc_s::crit_exts_c_& other) { if (this == &other) { return *this; @@ -28260,17 +24548,17 @@ dl_ccch_msg_type_c& dl_ccch_msg_type_c::operator=(const dl_ccch_msg_type_c& othe case types::c1: c.set(other.c.get()); break; - case types::msg_class_ext: + case types::crit_exts_future: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_"); } return *this; } -void dl_ccch_msg_type_c::to_json(json_writer& j) const +void ul_info_transfer_mrdc_s::crit_exts_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { @@ -28278,29 +24566,29 @@ void dl_ccch_msg_type_c::to_json(json_writer& j) const j.write_fieldname("c1"); c.get().to_json(j); break; - case types::msg_class_ext: + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_"); } j.end_obj(); } -SRSASN_CODE dl_ccch_msg_type_c::pack(bit_ref& bref) const +SRSASN_CODE ul_info_transfer_mrdc_s::crit_exts_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { case types::c1: HANDLE_CODE(c.get().pack(bref)); break; - case types::msg_class_ext: + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE dl_ccch_msg_type_c::unpack(cbit_ref& bref) +SRSASN_CODE ul_info_transfer_mrdc_s::crit_exts_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); @@ -28309,14218 +24597,20575 @@ SRSASN_CODE dl_ccch_msg_type_c::unpack(cbit_ref& bref) case types::c1: HANDLE_CODE(c.get().unpack(bref)); break; - case types::msg_class_ext: + case types::crit_exts_future: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c"); + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void dl_ccch_msg_type_c::c1_c_::destroy_() +void ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_::set(types::options e) { + type_ = e; +} +void ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_::to_json(json_writer& j) const +{ + j.start_obj(); switch (type_) { - case types::rrc_reject: - c.destroy(); + case types::ul_info_transfer_mrdc: + j.write_fieldname("ulInformationTransferMRDC"); + c.to_json(j); break; - case types::rrc_setup: - c.destroy(); + case types::spare3: break; - default: + case types::spare2: break; + case types::spare1: + break; + default: + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_"); } + j.end_obj(); } -void dl_ccch_msg_type_c::c1_c_::set(types::options e) +SRSASN_CODE ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_::pack(bit_ref& bref) const { - destroy_(); - type_ = e; + type_.pack(bref); switch (type_) { - case types::rrc_reject: - c.init(); + case types::ul_info_transfer_mrdc: + HANDLE_CODE(c.pack(bref)); break; - case types::rrc_setup: - c.init(); + case types::spare3: break; case types::spare2: break; case types::spare1: break; - case types::nulltype: - break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } + return SRSASN_SUCCESS; } -dl_ccch_msg_type_c::c1_c_::c1_c_(const dl_ccch_msg_type_c::c1_c_& other) +SRSASN_CODE ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_::unpack(cbit_ref& bref) { - type_ = other.type(); + types e; + e.unpack(bref); + set(e); switch (type_) { - case types::rrc_reject: - c.init(other.c.get()); + case types::ul_info_transfer_mrdc: + HANDLE_CODE(c.unpack(bref)); break; - case types::rrc_setup: - c.init(other.c.get()); + case types::spare3: break; case types::spare2: break; case types::spare1: break; + default: + log_invalid_choice_id(type_, "ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_::types_opts::to_string() const +{ + static const char* options[] = {"ulInformationTransferMRDC", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 4, value, "ul_info_transfer_mrdc_s::crit_exts_c_::c1_c_::types"); +} + +std::string ul_info_transfer_mrdc_s::crit_exts_c_::types_opts::to_string() const +{ + static const char* options[] = {"c1", "criticalExtensionsFuture"}; + return convert_enum_idx(options, 2, value, "ul_info_transfer_mrdc_s::crit_exts_c_::types"); +} +uint8_t ul_info_transfer_mrdc_s::crit_exts_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "ul_info_transfer_mrdc_s::crit_exts_c_::types"); +} + +// UL-DCCH-MessageType ::= CHOICE +void ul_dcch_msg_type_c::destroy_() +{ + switch (type_) { + case types::c1: + c.destroy(); + break; + default: + break; + } +} +void ul_dcch_msg_type_c::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::c1: + c.init(); + break; + case types::msg_class_ext: + break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); } } -dl_ccch_msg_type_c::c1_c_& dl_ccch_msg_type_c::c1_c_::operator=(const dl_ccch_msg_type_c::c1_c_& other) +ul_dcch_msg_type_c::ul_dcch_msg_type_c(const ul_dcch_msg_type_c& other) +{ + type_ = other.type(); + switch (type_) { + case types::c1: + c.init(other.c.get()); + break; + case types::msg_class_ext: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); + } +} +ul_dcch_msg_type_c& ul_dcch_msg_type_c::operator=(const ul_dcch_msg_type_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_reject: - c.set(other.c.get()); - break; - case types::rrc_setup: - c.set(other.c.get()); - break; - case types::spare2: + case types::c1: + c.set(other.c.get()); break; - case types::spare1: + case types::msg_class_ext: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); } return *this; } -void dl_ccch_msg_type_c::c1_c_::to_json(json_writer& j) const +void ul_dcch_msg_type_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_reject: - j.write_fieldname("rrcReject"); - c.get().to_json(j); - break; - case types::rrc_setup: - j.write_fieldname("rrcSetup"); - c.get().to_json(j); - break; - case types::spare2: + case types::c1: + j.write_fieldname("c1"); + c.get().to_json(j); break; - case types::spare1: + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); } j.end_obj(); } -SRSASN_CODE dl_ccch_msg_type_c::c1_c_::pack(bit_ref& bref) const +SRSASN_CODE ul_dcch_msg_type_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_reject: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_setup: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::spare2: + case types::c1: + HANDLE_CODE(c.get().pack(bref)); break; - case types::spare1: + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE dl_ccch_msg_type_c::c1_c_::unpack(cbit_ref& bref) +SRSASN_CODE ul_dcch_msg_type_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_reject: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_setup: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::spare2: + case types::c1: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::spare1: + case types::msg_class_ext: break; default: - log_invalid_choice_id(type_, "dl_ccch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string dl_ccch_msg_type_c::c1_c_::types_opts::to_string() const -{ - static const char* options[] = {"rrcReject", "rrcSetup", "spare2", "spare1"}; - return convert_enum_idx(options, 4, value, "dl_ccch_msg_type_c::c1_c_::types"); -} - -std::string dl_ccch_msg_type_c::types_opts::to_string() const -{ - static const char* options[] = {"c1", "messageClassExtension"}; - return convert_enum_idx(options, 2, value, "dl_ccch_msg_type_c::types"); -} -uint8_t dl_ccch_msg_type_c::types_opts::to_number() const -{ - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "dl_ccch_msg_type_c::types"); -} - -// DL-CCCH-Message ::= SEQUENCE -SRSASN_CODE dl_ccch_msg_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(msg.pack(bref)); - - bref.align_bytes_zero(); - - return SRSASN_SUCCESS; -} -SRSASN_CODE dl_ccch_msg_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(msg.unpack(bref)); - - bref.align_bytes(); - - return SRSASN_SUCCESS; -} -void dl_ccch_msg_s::to_json(json_writer& j) const +void ul_dcch_msg_type_c::c1_c_::destroy_() { - j.start_array(); - j.start_obj(); - j.start_obj("DL-CCCH-Message"); - j.write_fieldname("message"); - msg.to_json(j); - j.end_obj(); - j.end_obj(); - j.end_array(); -} - -// CSI-RS-Resource-Mobility ::= SEQUENCE -SRSASN_CODE csi_rs_res_mob_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(associated_ssb_present, 1)); - - HANDLE_CODE(pack_integer(bref, csi_rs_idx, (uint8_t)0u, (uint8_t)95u)); - HANDLE_CODE(slot_cfg.pack(bref)); - if (associated_ssb_present) { - HANDLE_CODE(pack_integer(bref, associated_ssb.ssb_idx, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(bref.pack(associated_ssb.is_quasi_colocated, 1)); - } - HANDLE_CODE(freq_domain_alloc.pack(bref)); - HANDLE_CODE(pack_integer(bref, first_ofdm_symbol_in_time_domain, (uint8_t)0u, (uint8_t)13u)); - HANDLE_CODE(pack_integer(bref, seq_generation_cfg, (uint16_t)0u, (uint16_t)1023u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_rs_res_mob_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(associated_ssb_present, 1)); - - HANDLE_CODE(unpack_integer(csi_rs_idx, bref, (uint8_t)0u, (uint8_t)95u)); - HANDLE_CODE(slot_cfg.unpack(bref)); - if (associated_ssb_present) { - HANDLE_CODE(unpack_integer(associated_ssb.ssb_idx, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(bref.unpack(associated_ssb.is_quasi_colocated, 1)); - } - HANDLE_CODE(freq_domain_alloc.unpack(bref)); - HANDLE_CODE(unpack_integer(first_ofdm_symbol_in_time_domain, bref, (uint8_t)0u, (uint8_t)13u)); - HANDLE_CODE(unpack_integer(seq_generation_cfg, bref, (uint16_t)0u, (uint16_t)1023u)); - - return SRSASN_SUCCESS; -} -void csi_rs_res_mob_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("csi-RS-Index", csi_rs_idx); - j.write_fieldname("slotConfig"); - slot_cfg.to_json(j); - if (associated_ssb_present) { - j.write_fieldname("associatedSSB"); - j.start_obj(); - j.write_int("ssb-Index", associated_ssb.ssb_idx); - j.write_bool("isQuasiColocated", associated_ssb.is_quasi_colocated); - j.end_obj(); - } - j.write_fieldname("frequencyDomainAllocation"); - freq_domain_alloc.to_json(j); - j.write_int("firstOFDMSymbolInTimeDomain", first_ofdm_symbol_in_time_domain); - j.write_int("sequenceGenerationConfig", seq_generation_cfg); - j.end_obj(); -} - -void csi_rs_res_mob_s::slot_cfg_c_::destroy_() {} -void csi_rs_res_mob_s::slot_cfg_c_::set(types::options e) -{ - destroy_(); - type_ = e; -} -csi_rs_res_mob_s::slot_cfg_c_::slot_cfg_c_(const csi_rs_res_mob_s::slot_cfg_c_& other) -{ - type_ = other.type(); switch (type_) { - case types::ms4: - c.init(other.c.get()); - break; - case types::ms5: - c.init(other.c.get()); + case types::meas_report: + c.destroy(); break; - case types::ms10: - c.init(other.c.get()); + case types::rrc_recfg_complete: + c.destroy(); break; - case types::ms20: - c.init(other.c.get()); + case types::rrc_setup_complete: + c.destroy(); break; - case types::ms40: - c.init(other.c.get()); + case types::rrc_reest_complete: + c.destroy(); break; - case types::nulltype: + case types::rrc_resume_complete: + c.destroy(); break; - default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); - } -} -csi_rs_res_mob_s::slot_cfg_c_& csi_rs_res_mob_s::slot_cfg_c_::operator=(const csi_rs_res_mob_s::slot_cfg_c_& other) -{ - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::ms4: - c.set(other.c.get()); + case types::security_mode_complete: + c.destroy(); break; - case types::ms5: - c.set(other.c.get()); + case types::security_mode_fail: + c.destroy(); break; - case types::ms10: - c.set(other.c.get()); + case types::ul_info_transfer: + c.destroy(); break; - case types::ms20: - c.set(other.c.get()); + case types::location_meas_ind: + c.destroy(); break; - case types::ms40: - c.set(other.c.get()); + case types::ue_cap_info: + c.destroy(); break; - case types::nulltype: + case types::counter_check_resp: + c.destroy(); break; - default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); - } - - return *this; -} -void csi_rs_res_mob_s::slot_cfg_c_::to_json(json_writer& j) const -{ - j.start_obj(); - switch (type_) { - case types::ms4: - j.write_int("ms4", c.get()); + case types::ue_assist_info: + c.destroy(); break; - case types::ms5: - j.write_int("ms5", c.get()); + case types::fail_info: + c.destroy(); break; - case types::ms10: - j.write_int("ms10", c.get()); + case types::ul_info_transfer_mrdc: + c.destroy(); break; - case types::ms20: - j.write_int("ms20", c.get()); + case types::scg_fail_info: + c.destroy(); break; - case types::ms40: - j.write_int("ms40", c.get()); + case types::scg_fail_info_eutra: + c.destroy(); break; default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); + break; } - j.end_obj(); } -SRSASN_CODE csi_rs_res_mob_s::slot_cfg_c_::pack(bit_ref& bref) const +void ul_dcch_msg_type_c::c1_c_::set(types::options e) { - type_.pack(bref); + destroy_(); + type_ = e; switch (type_) { - case types::ms4: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); + case types::meas_report: + c.init(); break; - case types::ms5: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); + case types::rrc_recfg_complete: + c.init(); break; - case types::ms10: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); + case types::rrc_setup_complete: + c.init(); break; - case types::ms20: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + case types::rrc_reest_complete: + c.init(); break; - case types::ms40: - HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + case types::rrc_resume_complete: + c.init(); break; - default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_rs_res_mob_s::slot_cfg_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::ms4: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); + case types::security_mode_complete: + c.init(); break; - case types::ms5: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); + case types::security_mode_fail: + c.init(); break; - case types::ms10: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); + case types::ul_info_transfer: + c.init(); break; - case types::ms20: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + case types::location_meas_ind: + c.init(); break; - case types::ms40: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + case types::ue_cap_info: + c.init(); break; - default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::slot_cfg_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; -} - -std::string csi_rs_res_mob_s::slot_cfg_c_::types_opts::to_string() const -{ - static const char* options[] = {"ms4", "ms5", "ms10", "ms20", "ms40"}; - return convert_enum_idx(options, 5, value, "csi_rs_res_mob_s::slot_cfg_c_::types"); -} -uint8_t csi_rs_res_mob_s::slot_cfg_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {4, 5, 10, 20, 40}; - return map_enum_number(options, 5, value, "csi_rs_res_mob_s::slot_cfg_c_::types"); -} - -void csi_rs_res_mob_s::freq_domain_alloc_c_::destroy_() -{ - switch (type_) { - case types::row1: - c.destroy >(); + case types::counter_check_resp: + c.init(); break; - case types::row2: - c.destroy >(); + case types::ue_assist_info: + c.init(); break; - default: + case types::fail_info: + c.init(); break; - } -} -void csi_rs_res_mob_s::freq_domain_alloc_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::row1: - c.init >(); + case types::ul_info_transfer_mrdc: + c.init(); break; - case types::row2: - c.init >(); + case types::scg_fail_info: + c.init(); + break; + case types::scg_fail_info_eutra: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); } } -csi_rs_res_mob_s::freq_domain_alloc_c_::freq_domain_alloc_c_(const csi_rs_res_mob_s::freq_domain_alloc_c_& other) +ul_dcch_msg_type_c::c1_c_::c1_c_(const ul_dcch_msg_type_c::c1_c_& other) { type_ = other.type(); switch (type_) { - case types::row1: - c.init(other.c.get >()); + case types::meas_report: + c.init(other.c.get()); break; - case types::row2: - c.init(other.c.get >()); + case types::rrc_recfg_complete: + c.init(other.c.get()); + break; + case types::rrc_setup_complete: + c.init(other.c.get()); + break; + case types::rrc_reest_complete: + c.init(other.c.get()); + break; + case types::rrc_resume_complete: + c.init(other.c.get()); + break; + case types::security_mode_complete: + c.init(other.c.get()); + break; + case types::security_mode_fail: + c.init(other.c.get()); + break; + case types::ul_info_transfer: + c.init(other.c.get()); + break; + case types::location_meas_ind: + c.init(other.c.get()); + break; + case types::ue_cap_info: + c.init(other.c.get()); + break; + case types::counter_check_resp: + c.init(other.c.get()); + break; + case types::ue_assist_info: + c.init(other.c.get()); + break; + case types::fail_info: + c.init(other.c.get()); + break; + case types::ul_info_transfer_mrdc: + c.init(other.c.get()); + break; + case types::scg_fail_info: + c.init(other.c.get()); + break; + case types::scg_fail_info_eutra: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); } } -csi_rs_res_mob_s::freq_domain_alloc_c_& csi_rs_res_mob_s::freq_domain_alloc_c_:: - operator=(const csi_rs_res_mob_s::freq_domain_alloc_c_& other) +ul_dcch_msg_type_c::c1_c_& ul_dcch_msg_type_c::c1_c_::operator=(const ul_dcch_msg_type_c::c1_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::row1: - c.set(other.c.get >()); + case types::meas_report: + c.set(other.c.get()); break; - case types::row2: - c.set(other.c.get >()); + case types::rrc_recfg_complete: + c.set(other.c.get()); + break; + case types::rrc_setup_complete: + c.set(other.c.get()); + break; + case types::rrc_reest_complete: + c.set(other.c.get()); + break; + case types::rrc_resume_complete: + c.set(other.c.get()); + break; + case types::security_mode_complete: + c.set(other.c.get()); + break; + case types::security_mode_fail: + c.set(other.c.get()); + break; + case types::ul_info_transfer: + c.set(other.c.get()); + break; + case types::location_meas_ind: + c.set(other.c.get()); + break; + case types::ue_cap_info: + c.set(other.c.get()); + break; + case types::counter_check_resp: + c.set(other.c.get()); + break; + case types::ue_assist_info: + c.set(other.c.get()); + break; + case types::fail_info: + c.set(other.c.get()); + break; + case types::ul_info_transfer_mrdc: + c.set(other.c.get()); + break; + case types::scg_fail_info: + c.set(other.c.get()); + break; + case types::scg_fail_info_eutra: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); } return *this; } -void csi_rs_res_mob_s::freq_domain_alloc_c_::to_json(json_writer& j) const +void ul_dcch_msg_type_c::c1_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::row1: - j.write_str("row1", c.get >().to_string()); + case types::meas_report: + j.write_fieldname("measurementReport"); + c.get().to_json(j); break; - case types::row2: - j.write_str("row2", c.get >().to_string()); + case types::rrc_recfg_complete: + j.write_fieldname("rrcReconfigurationComplete"); + c.get().to_json(j); + break; + case types::rrc_setup_complete: + j.write_fieldname("rrcSetupComplete"); + c.get().to_json(j); + break; + case types::rrc_reest_complete: + j.write_fieldname("rrcReestablishmentComplete"); + c.get().to_json(j); + break; + case types::rrc_resume_complete: + j.write_fieldname("rrcResumeComplete"); + c.get().to_json(j); + break; + case types::security_mode_complete: + j.write_fieldname("securityModeComplete"); + c.get().to_json(j); + break; + case types::security_mode_fail: + j.write_fieldname("securityModeFailure"); + c.get().to_json(j); + break; + case types::ul_info_transfer: + j.write_fieldname("ulInformationTransfer"); + c.get().to_json(j); + break; + case types::location_meas_ind: + j.write_fieldname("locationMeasurementIndication"); + c.get().to_json(j); + break; + case types::ue_cap_info: + j.write_fieldname("ueCapabilityInformation"); + c.get().to_json(j); + break; + case types::counter_check_resp: + j.write_fieldname("counterCheckResponse"); + c.get().to_json(j); + break; + case types::ue_assist_info: + j.write_fieldname("ueAssistanceInformation"); + c.get().to_json(j); + break; + case types::fail_info: + j.write_fieldname("failureInformation"); + c.get().to_json(j); + break; + case types::ul_info_transfer_mrdc: + j.write_fieldname("ulInformationTransferMRDC"); + c.get().to_json(j); + break; + case types::scg_fail_info: + j.write_fieldname("scgFailureInformation"); + c.get().to_json(j); + break; + case types::scg_fail_info_eutra: + j.write_fieldname("scgFailureInformationEUTRA"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); } j.end_obj(); } -SRSASN_CODE csi_rs_res_mob_s::freq_domain_alloc_c_::pack(bit_ref& bref) const +SRSASN_CODE ul_dcch_msg_type_c::c1_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::row1: - HANDLE_CODE(c.get >().pack(bref)); + case types::meas_report: + HANDLE_CODE(c.get().pack(bref)); break; - case types::row2: - HANDLE_CODE(c.get >().pack(bref)); + case types::rrc_recfg_complete: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::rrc_setup_complete: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::rrc_reest_complete: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::rrc_resume_complete: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::security_mode_complete: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::security_mode_fail: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::ul_info_transfer: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::location_meas_ind: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::ue_cap_info: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::counter_check_resp: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::ue_assist_info: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::fail_info: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::ul_info_transfer_mrdc: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::scg_fail_info: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::scg_fail_info_eutra: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE csi_rs_res_mob_s::freq_domain_alloc_c_::unpack(cbit_ref& bref) +SRSASN_CODE ul_dcch_msg_type_c::c1_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::row1: - HANDLE_CODE(c.get >().unpack(bref)); + case types::meas_report: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::row2: - HANDLE_CODE(c.get >().unpack(bref)); + case types::rrc_recfg_complete: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::rrc_setup_complete: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::rrc_reest_complete: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::rrc_resume_complete: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::security_mode_complete: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::security_mode_fail: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::ul_info_transfer: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::location_meas_ind: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::ue_cap_info: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::counter_check_resp: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::ue_assist_info: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::fail_info: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::ul_info_transfer_mrdc: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::scg_fail_info: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::scg_fail_info_eutra: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "csi_rs_res_mob_s::freq_domain_alloc_c_"); + log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string csi_rs_res_mob_s::freq_domain_alloc_c_::types_opts::to_string() const -{ - static const char* options[] = {"row1", "row2"}; - return convert_enum_idx(options, 2, value, "csi_rs_res_mob_s::freq_domain_alloc_c_::types"); -} -uint8_t csi_rs_res_mob_s::freq_domain_alloc_c_::types_opts::to_number() const +std::string ul_dcch_msg_type_c::c1_c_::types_opts::to_string() const { - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "csi_rs_res_mob_s::freq_domain_alloc_c_::types"); + static const char* options[] = {"measurementReport", + "rrcReconfigurationComplete", + "rrcSetupComplete", + "rrcReestablishmentComplete", + "rrcResumeComplete", + "securityModeComplete", + "securityModeFailure", + "ulInformationTransfer", + "locationMeasurementIndication", + "ueCapabilityInformation", + "counterCheckResponse", + "ueAssistanceInformation", + "failureInformation", + "ulInformationTransferMRDC", + "scgFailureInformation", + "scgFailureInformationEUTRA"}; + return convert_enum_idx(options, 16, value, "ul_dcch_msg_type_c::c1_c_::types"); } -// CSI-RS-CellMobility ::= SEQUENCE -SRSASN_CODE csi_rs_cell_mob_s::pack(bit_ref& bref) const +std::string ul_dcch_msg_type_c::types_opts::to_string() const { - HANDLE_CODE(bref.pack(density_present, 1)); + static const char* options[] = {"c1", "messageClassExtension"}; + return convert_enum_idx(options, 2, value, "ul_dcch_msg_type_c::types"); +} +uint8_t ul_dcch_msg_type_c::types_opts::to_number() const +{ + static const uint8_t options[] = {1}; + return map_enum_number(options, 1, value, "ul_dcch_msg_type_c::types"); +} - HANDLE_CODE(pack_integer(bref, cell_id, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(csi_rs_meas_bw.nrof_prbs.pack(bref)); - HANDLE_CODE(pack_integer(bref, csi_rs_meas_bw.start_prb, (uint16_t)0u, (uint16_t)2169u)); - if (density_present) { - HANDLE_CODE(density.pack(bref)); - } - HANDLE_CODE(pack_dyn_seq_of(bref, csi_rs_res_list_mob, 1, 96)); +// UL-DCCH-Message ::= SEQUENCE +SRSASN_CODE ul_dcch_msg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(msg.pack(bref)); + + bref.align_bytes_zero(); return SRSASN_SUCCESS; } -SRSASN_CODE csi_rs_cell_mob_s::unpack(cbit_ref& bref) +SRSASN_CODE ul_dcch_msg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(density_present, 1)); + HANDLE_CODE(msg.unpack(bref)); - HANDLE_CODE(unpack_integer(cell_id, bref, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(csi_rs_meas_bw.nrof_prbs.unpack(bref)); - HANDLE_CODE(unpack_integer(csi_rs_meas_bw.start_prb, bref, (uint16_t)0u, (uint16_t)2169u)); - if (density_present) { - HANDLE_CODE(density.unpack(bref)); - } - HANDLE_CODE(unpack_dyn_seq_of(csi_rs_res_list_mob, bref, 1, 96)); + bref.align_bytes(); return SRSASN_SUCCESS; } -void csi_rs_cell_mob_s::to_json(json_writer& j) const +void ul_dcch_msg_s::to_json(json_writer& j) const { + j.start_array(); j.start_obj(); - j.write_int("cellId", cell_id); - j.write_fieldname("csi-rs-MeasurementBW"); - j.start_obj(); - j.write_str("nrofPRBs", csi_rs_meas_bw.nrof_prbs.to_string()); - j.write_int("startPRB", csi_rs_meas_bw.start_prb); + j.start_obj("UL-DCCH-Message"); + j.write_fieldname("message"); + msg.to_json(j); j.end_obj(); - if (density_present) { - j.write_str("density", density.to_string()); - } - j.start_array("csi-rs-ResourceList-Mobility"); - for (const auto& e1 : csi_rs_res_list_mob) { - e1.to_json(j); - } - j.end_array(); j.end_obj(); + j.end_array(); } -std::string csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_opts::to_string() const -{ - static const char* options[] = {"size24", "size48", "size96", "size192", "size264"}; - return convert_enum_idx(options, 5, value, "csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_e_"); -} -uint16_t csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_opts::to_number() const -{ - static const uint16_t options[] = {24, 48, 96, 192, 264}; - return map_enum_number(options, 5, value, "csi_rs_cell_mob_s::csi_rs_meas_bw_s_::nrof_prbs_e_"); -} - -std::string csi_rs_cell_mob_s::density_opts::to_string() const -{ - static const char* options[] = {"d1", "d3"}; - return convert_enum_idx(options, 2, value, "csi_rs_cell_mob_s::density_e_"); -} -uint8_t csi_rs_cell_mob_s::density_opts::to_number() const -{ - static const uint8_t options[] = {1, 3}; - return map_enum_number(options, 2, value, "csi_rs_cell_mob_s::density_e_"); -} - -// Q-OffsetRangeList ::= SEQUENCE -SRSASN_CODE q_offset_range_list_s::pack(bit_ref& bref) const +// BFR-CSIRS-Resource ::= SEQUENCE +SRSASN_CODE bfr_csirs_res_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(rsrp_offset_ssb_present, 1)); - HANDLE_CODE(bref.pack(rsrq_offset_ssb_present, 1)); - HANDLE_CODE(bref.pack(sinr_offset_ssb_present, 1)); - HANDLE_CODE(bref.pack(rsrp_offset_csi_rs_present, 1)); - HANDLE_CODE(bref.pack(rsrq_offset_csi_rs_present, 1)); - HANDLE_CODE(bref.pack(sinr_offset_csi_rs_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(ra_occasion_list_present, 1)); + HANDLE_CODE(bref.pack(ra_preamb_idx_present, 1)); - if (rsrp_offset_ssb_present) { - HANDLE_CODE(rsrp_offset_ssb.pack(bref)); - } - if (rsrq_offset_ssb_present) { - HANDLE_CODE(rsrq_offset_ssb.pack(bref)); - } - if (sinr_offset_ssb_present) { - HANDLE_CODE(sinr_offset_ssb.pack(bref)); - } - if (rsrp_offset_csi_rs_present) { - HANDLE_CODE(rsrp_offset_csi_rs.pack(bref)); - } - if (rsrq_offset_csi_rs_present) { - HANDLE_CODE(rsrq_offset_csi_rs.pack(bref)); + HANDLE_CODE(pack_integer(bref, csi_rs, (uint8_t)0u, (uint8_t)191u)); + if (ra_occasion_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ra_occasion_list, 1, 64, integer_packer(0, 511))); } - if (sinr_offset_csi_rs_present) { - HANDLE_CODE(sinr_offset_csi_rs.pack(bref)); + if (ra_preamb_idx_present) { + HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); } return SRSASN_SUCCESS; } -SRSASN_CODE q_offset_range_list_s::unpack(cbit_ref& bref) +SRSASN_CODE bfr_csirs_res_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(rsrp_offset_ssb_present, 1)); - HANDLE_CODE(bref.unpack(rsrq_offset_ssb_present, 1)); - HANDLE_CODE(bref.unpack(sinr_offset_ssb_present, 1)); - HANDLE_CODE(bref.unpack(rsrp_offset_csi_rs_present, 1)); - HANDLE_CODE(bref.unpack(rsrq_offset_csi_rs_present, 1)); - HANDLE_CODE(bref.unpack(sinr_offset_csi_rs_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(ra_occasion_list_present, 1)); + HANDLE_CODE(bref.unpack(ra_preamb_idx_present, 1)); - if (rsrp_offset_ssb_present) { - HANDLE_CODE(rsrp_offset_ssb.unpack(bref)); - } - if (rsrq_offset_ssb_present) { - HANDLE_CODE(rsrq_offset_ssb.unpack(bref)); - } - if (sinr_offset_ssb_present) { - HANDLE_CODE(sinr_offset_ssb.unpack(bref)); - } - if (rsrp_offset_csi_rs_present) { - HANDLE_CODE(rsrp_offset_csi_rs.unpack(bref)); - } - if (rsrq_offset_csi_rs_present) { - HANDLE_CODE(rsrq_offset_csi_rs.unpack(bref)); + HANDLE_CODE(unpack_integer(csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); + if (ra_occasion_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ra_occasion_list, bref, 1, 64, integer_packer(0, 511))); } - if (sinr_offset_csi_rs_present) { - HANDLE_CODE(sinr_offset_csi_rs.unpack(bref)); + if (ra_preamb_idx_present) { + HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); } return SRSASN_SUCCESS; } -void q_offset_range_list_s::to_json(json_writer& j) const +void bfr_csirs_res_s::to_json(json_writer& j) const { j.start_obj(); - if (rsrp_offset_ssb_present) { - j.write_str("rsrpOffsetSSB", rsrp_offset_ssb.to_string()); - } - if (rsrq_offset_ssb_present) { - j.write_str("rsrqOffsetSSB", rsrq_offset_ssb.to_string()); - } - if (sinr_offset_ssb_present) { - j.write_str("sinrOffsetSSB", sinr_offset_ssb.to_string()); - } - if (rsrp_offset_csi_rs_present) { - j.write_str("rsrpOffsetCSI-RS", rsrp_offset_csi_rs.to_string()); - } - if (rsrq_offset_csi_rs_present) { - j.write_str("rsrqOffsetCSI-RS", rsrq_offset_csi_rs.to_string()); + j.write_int("csi-RS", csi_rs); + if (ra_occasion_list_present) { + j.start_array("ra-OccasionList"); + for (const auto& e1 : ra_occasion_list) { + j.write_int(e1); + } + j.end_array(); } - if (sinr_offset_csi_rs_present) { - j.write_str("sinrOffsetCSI-RS", sinr_offset_csi_rs.to_string()); + if (ra_preamb_idx_present) { + j.write_int("ra-PreambleIndex", ra_preamb_idx); } j.end_obj(); } -// CSI-RS-ResourceConfigMobility ::= SEQUENCE -SRSASN_CODE csi_rs_res_cfg_mob_s::pack(bit_ref& bref) const +// BFR-SSB-Resource ::= SEQUENCE +SRSASN_CODE bfr_ssb_res_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(subcarrier_spacing.pack(bref)); - HANDLE_CODE(pack_dyn_seq_of(bref, csi_rs_cell_list_mob, 1, 96)); - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= ref_serv_cell_idx_v1530_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(pack_integer(bref, ssb, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(bref.pack(ref_serv_cell_idx_v1530_present, 1)); - if (ref_serv_cell_idx_v1530_present) { - HANDLE_CODE(pack_integer(bref, ref_serv_cell_idx_v1530, (uint8_t)0u, (uint8_t)31u)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE csi_rs_res_cfg_mob_s::unpack(cbit_ref& bref) +SRSASN_CODE bfr_ssb_res_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(subcarrier_spacing.unpack(bref)); - HANDLE_CODE(unpack_dyn_seq_of(csi_rs_cell_list_mob, bref, 1, 96)); - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(unpack_integer(ssb, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); - HANDLE_CODE(bref.unpack(ref_serv_cell_idx_v1530_present, 1)); - if (ref_serv_cell_idx_v1530_present) { - HANDLE_CODE(unpack_integer(ref_serv_cell_idx_v1530, bref, (uint8_t)0u, (uint8_t)31u)); - } - } - } return SRSASN_SUCCESS; } -void csi_rs_res_cfg_mob_s::to_json(json_writer& j) const +void bfr_ssb_res_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("subcarrierSpacing", subcarrier_spacing.to_string()); - j.start_array("csi-RS-CellList-Mobility"); - for (const auto& e1 : csi_rs_cell_list_mob) { - e1.to_json(j); - } - j.end_array(); - if (ext) { - if (ref_serv_cell_idx_v1530_present) { - j.write_int("refServCellIndex-v1530", ref_serv_cell_idx_v1530); - } - } + j.write_int("ssb", ssb); + j.write_int("ra-PreambleIndex", ra_preamb_idx); j.end_obj(); } -// CellsToAddMod ::= SEQUENCE -SRSASN_CODE cells_to_add_mod_s::pack(bit_ref& bref) const +// CSI-FrequencyOccupation ::= SEQUENCE +SRSASN_CODE csi_freq_occupation_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(cell_individual_offset.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, start_rb, (uint16_t)0u, (uint16_t)274u)); + HANDLE_CODE(pack_integer(bref, nrof_rbs, (uint16_t)24u, (uint16_t)276u)); return SRSASN_SUCCESS; } -SRSASN_CODE cells_to_add_mod_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_freq_occupation_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(cell_individual_offset.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(start_rb, bref, (uint16_t)0u, (uint16_t)274u)); + HANDLE_CODE(unpack_integer(nrof_rbs, bref, (uint16_t)24u, (uint16_t)276u)); return SRSASN_SUCCESS; } -void cells_to_add_mod_s::to_json(json_writer& j) const +void csi_freq_occupation_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("physCellId", pci); - j.write_fieldname("cellIndividualOffset"); - cell_individual_offset.to_json(j); + j.write_int("startingRB", start_rb); + j.write_int("nrofRBs", nrof_rbs); j.end_obj(); } -// FilterCoefficient ::= ENUMERATED -std::string filt_coef_opts::to_string() const -{ - static const char* options[] = {"fc0", - "fc1", - "fc2", - "fc3", - "fc4", - "fc5", - "fc6", - "fc7", - "fc8", - "fc9", - "fc11", - "fc13", - "fc15", - "fc17", - "fc19", - "spare1"}; - return convert_enum_idx(options, 16, value, "filt_coef_e"); -} -uint8_t filt_coef_opts::to_number() const +// CSI-RS-ResourceMapping ::= SEQUENCE +SRSASN_CODE csi_rs_res_map_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 13, 15, 17, 19}; - return map_enum_number(options, 15, value, "filt_coef_e"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(first_ofdm_symbol_in_time_domain2_present, 1)); -// MeasReportQuantity ::= SEQUENCE -SRSASN_CODE meas_report_quant_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(rsrp, 1)); - HANDLE_CODE(bref.pack(rsrq, 1)); - HANDLE_CODE(bref.pack(sinr, 1)); + HANDLE_CODE(freq_domain_alloc.pack(bref)); + HANDLE_CODE(nrof_ports.pack(bref)); + HANDLE_CODE(pack_integer(bref, first_ofdm_symbol_in_time_domain, (uint8_t)0u, (uint8_t)13u)); + if (first_ofdm_symbol_in_time_domain2_present) { + HANDLE_CODE(pack_integer(bref, first_ofdm_symbol_in_time_domain2, (uint8_t)2u, (uint8_t)12u)); + } + HANDLE_CODE(cdm_type.pack(bref)); + HANDLE_CODE(density.pack(bref)); + HANDLE_CODE(freq_band.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_report_quant_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_rs_res_map_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(rsrp, 1)); - HANDLE_CODE(bref.unpack(rsrq, 1)); - HANDLE_CODE(bref.unpack(sinr, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(first_ofdm_symbol_in_time_domain2_present, 1)); + + HANDLE_CODE(freq_domain_alloc.unpack(bref)); + HANDLE_CODE(nrof_ports.unpack(bref)); + HANDLE_CODE(unpack_integer(first_ofdm_symbol_in_time_domain, bref, (uint8_t)0u, (uint8_t)13u)); + if (first_ofdm_symbol_in_time_domain2_present) { + HANDLE_CODE(unpack_integer(first_ofdm_symbol_in_time_domain2, bref, (uint8_t)2u, (uint8_t)12u)); + } + HANDLE_CODE(cdm_type.unpack(bref)); + HANDLE_CODE(density.unpack(bref)); + HANDLE_CODE(freq_band.unpack(bref)); return SRSASN_SUCCESS; } -void meas_report_quant_s::to_json(json_writer& j) const +void csi_rs_res_map_s::to_json(json_writer& j) const { j.start_obj(); - j.write_bool("rsrp", rsrp); - j.write_bool("rsrq", rsrq); - j.write_bool("sinr", sinr); + j.write_fieldname("frequencyDomainAllocation"); + freq_domain_alloc.to_json(j); + j.write_str("nrofPorts", nrof_ports.to_string()); + j.write_int("firstOFDMSymbolInTimeDomain", first_ofdm_symbol_in_time_domain); + if (first_ofdm_symbol_in_time_domain2_present) { + j.write_int("firstOFDMSymbolInTimeDomain2", first_ofdm_symbol_in_time_domain2); + } + j.write_str("cdm-Type", cdm_type.to_string()); + j.write_fieldname("density"); + density.to_json(j); + j.write_fieldname("freqBand"); + freq_band.to_json(j); j.end_obj(); } -// MeasTriggerQuantity ::= CHOICE -void meas_trigger_quant_c::destroy_() {} -void meas_trigger_quant_c::set(types::options e) +void csi_rs_res_map_s::freq_domain_alloc_c_::destroy_() +{ + switch (type_) { + case types::row1: + c.destroy >(); + break; + case types::row2: + c.destroy >(); + break; + case types::row4: + c.destroy >(); + break; + case types::other: + c.destroy >(); + break; + default: + break; + } +} +void csi_rs_res_map_s::freq_domain_alloc_c_::set(types::options e) { destroy_(); type_ = e; + switch (type_) { + case types::row1: + c.init >(); + break; + case types::row2: + c.init >(); + break; + case types::row4: + c.init >(); + break; + case types::other: + c.init >(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); + } } -meas_trigger_quant_c::meas_trigger_quant_c(const meas_trigger_quant_c& other) +csi_rs_res_map_s::freq_domain_alloc_c_::freq_domain_alloc_c_(const csi_rs_res_map_s::freq_domain_alloc_c_& other) { type_ = other.type(); switch (type_) { - case types::rsrp: - c.init(other.c.get()); + case types::row1: + c.init(other.c.get >()); break; - case types::rsrq: - c.init(other.c.get()); + case types::row2: + c.init(other.c.get >()); break; - case types::sinr: - c.init(other.c.get()); + case types::row4: + c.init(other.c.get >()); + break; + case types::other: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); } } -meas_trigger_quant_c& meas_trigger_quant_c::operator=(const meas_trigger_quant_c& other) +csi_rs_res_map_s::freq_domain_alloc_c_& +csi_rs_res_map_s::freq_domain_alloc_c_::operator=(const csi_rs_res_map_s::freq_domain_alloc_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rsrp: - c.set(other.c.get()); + case types::row1: + c.set(other.c.get >()); break; - case types::rsrq: - c.set(other.c.get()); + case types::row2: + c.set(other.c.get >()); break; - case types::sinr: - c.set(other.c.get()); + case types::row4: + c.set(other.c.get >()); + break; + case types::other: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); } return *this; } -void meas_trigger_quant_c::to_json(json_writer& j) const +void csi_rs_res_map_s::freq_domain_alloc_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rsrp: - j.write_int("rsrp", c.get()); + case types::row1: + j.write_str("row1", c.get >().to_string()); break; - case types::rsrq: - j.write_int("rsrq", c.get()); + case types::row2: + j.write_str("row2", c.get >().to_string()); break; - case types::sinr: - j.write_int("sinr", c.get()); + case types::row4: + j.write_str("row4", c.get >().to_string()); + break; + case types::other: + j.write_str("other", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); } j.end_obj(); } -SRSASN_CODE meas_trigger_quant_c::pack(bit_ref& bref) const +SRSASN_CODE csi_rs_res_map_s::freq_domain_alloc_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rsrp: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + case types::row1: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::rsrq: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + case types::row2: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::sinr: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + case types::row4: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::other: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE meas_trigger_quant_c::unpack(cbit_ref& bref) +SRSASN_CODE csi_rs_res_map_s::freq_domain_alloc_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rsrp: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + case types::row1: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::rsrq: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + case types::row2: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::sinr: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + case types::row4: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::other: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::freq_domain_alloc_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string meas_trigger_quant_c::types_opts::to_string() const +std::string csi_rs_res_map_s::freq_domain_alloc_c_::types_opts::to_string() const { - static const char* options[] = {"rsrp", "rsrq", "sinr"}; - return convert_enum_idx(options, 3, value, "meas_trigger_quant_c::types"); + static const char* options[] = {"row1", "row2", "row4", "other"}; + return convert_enum_idx(options, 4, value, "csi_rs_res_map_s::freq_domain_alloc_c_::types"); +} +uint8_t csi_rs_res_map_s::freq_domain_alloc_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 4}; + return map_enum_number(options, 3, value, "csi_rs_res_map_s::freq_domain_alloc_c_::types"); } -// MeasTriggerQuantityEUTRA ::= CHOICE -void meas_trigger_quant_eutra_c::destroy_() {} -void meas_trigger_quant_eutra_c::set(types::options e) +std::string csi_rs_res_map_s::nrof_ports_opts::to_string() const { - destroy_(); - type_ = e; + static const char* options[] = {"p1", "p2", "p4", "p8", "p12", "p16", "p24", "p32"}; + return convert_enum_idx(options, 8, value, "csi_rs_res_map_s::nrof_ports_e_"); } -meas_trigger_quant_eutra_c::meas_trigger_quant_eutra_c(const meas_trigger_quant_eutra_c& other) +uint8_t csi_rs_res_map_s::nrof_ports_opts::to_number() const { - type_ = other.type(); - switch (type_) { - case types::rsrp: - c.init(other.c.get()); - break; - case types::rsrq: - c.init(other.c.get()); - break; - case types::sinr: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); - } + static const uint8_t options[] = {1, 2, 4, 8, 12, 16, 24, 32}; + return map_enum_number(options, 8, value, "csi_rs_res_map_s::nrof_ports_e_"); } -meas_trigger_quant_eutra_c& meas_trigger_quant_eutra_c::operator=(const meas_trigger_quant_eutra_c& other) + +std::string csi_rs_res_map_s::cdm_type_opts::to_string() const { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::rsrp: - c.set(other.c.get()); - break; - case types::rsrq: - c.set(other.c.get()); - break; - case types::sinr: - c.set(other.c.get()); - break; - case types::nulltype: - break; + static const char* options[] = {"noCDM", "fd-CDM2", "cdm4-FD2-TD2", "cdm8-FD2-TD4"}; + return convert_enum_idx(options, 4, value, "csi_rs_res_map_s::cdm_type_e_"); +} +uint8_t csi_rs_res_map_s::cdm_type_opts::to_number() const +{ + switch (value) { + case fd_cdm2: + return 2; + case cdm4_fd2_td2: + return 4; + case cdm8_fd2_td4: + return 8; default: - log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); + invalid_enum_number(value, "csi_rs_res_map_s::cdm_type_e_"); } + return 0; +} - return *this; +void csi_rs_res_map_s::density_c_::set(types::options e) +{ + type_ = e; } -void meas_trigger_quant_eutra_c::to_json(json_writer& j) const +void csi_rs_res_map_s::density_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rsrp: - j.write_int("rsrp", c.get()); + case types::dot5: + j.write_str("dot5", c.to_string()); break; - case types::rsrq: - j.write_int("rsrq", c.get()); + case types::one: break; - case types::sinr: - j.write_int("sinr", c.get()); + case types::three: + break; + case types::spare: break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::density_c_"); } j.end_obj(); } -SRSASN_CODE meas_trigger_quant_eutra_c::pack(bit_ref& bref) const +SRSASN_CODE csi_rs_res_map_s::density_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rsrp: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)97u)); + case types::dot5: + HANDLE_CODE(c.pack(bref)); break; - case types::rsrq: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)34u)); + case types::one: break; - case types::sinr: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + case types::three: + break; + case types::spare: break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::density_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE meas_trigger_quant_eutra_c::unpack(cbit_ref& bref) +SRSASN_CODE csi_rs_res_map_s::density_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rsrp: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)97u)); + case types::dot5: + HANDLE_CODE(c.unpack(bref)); break; - case types::rsrq: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)34u)); + case types::one: break; - case types::sinr: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + case types::three: + break; + case types::spare: break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_eutra_c"); + log_invalid_choice_id(type_, "csi_rs_res_map_s::density_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string meas_trigger_quant_eutra_c::types_opts::to_string() const +std::string csi_rs_res_map_s::density_c_::dot5_opts::to_string() const { - static const char* options[] = {"rsrp", "rsrq", "sinr"}; - return convert_enum_idx(options, 3, value, "meas_trigger_quant_eutra_c::types"); + static const char* options[] = {"evenPRBs", "oddPRBs"}; + return convert_enum_idx(options, 2, value, "csi_rs_res_map_s::density_c_::dot5_e_"); } -// MeasTriggerQuantityOffset ::= CHOICE -void meas_trigger_quant_offset_c::destroy_() {} -void meas_trigger_quant_offset_c::set(types::options e) +std::string csi_rs_res_map_s::density_c_::types_opts::to_string() const +{ + static const char* options[] = {"dot5", "one", "three", "spare"}; + return convert_enum_idx(options, 4, value, "csi_rs_res_map_s::density_c_::types"); +} +uint8_t csi_rs_res_map_s::density_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {5, 1, 3}; + return map_enum_number(options, 3, value, "csi_rs_res_map_s::density_c_::types"); +} + +// CSI-ResourcePeriodicityAndOffset ::= CHOICE +void csi_res_periodicity_and_offset_c::destroy_() {} +void csi_res_periodicity_and_offset_c::set(types::options e) { destroy_(); type_ = e; } -meas_trigger_quant_offset_c::meas_trigger_quant_offset_c(const meas_trigger_quant_offset_c& other) +csi_res_periodicity_and_offset_c::csi_res_periodicity_and_offset_c(const csi_res_periodicity_and_offset_c& other) { type_ = other.type(); switch (type_) { - case types::rsrp: - c.init(other.c.get()); + case types::slots4: + c.init(other.c.get()); break; - case types::rsrq: - c.init(other.c.get()); + case types::slots5: + c.init(other.c.get()); break; - case types::sinr: - c.init(other.c.get()); + case types::slots8: + c.init(other.c.get()); + break; + case types::slots10: + c.init(other.c.get()); + break; + case types::slots16: + c.init(other.c.get()); + break; + case types::slots20: + c.init(other.c.get()); + break; + case types::slots32: + c.init(other.c.get()); + break; + case types::slots40: + c.init(other.c.get()); + break; + case types::slots64: + c.init(other.c.get()); + break; + case types::slots80: + c.init(other.c.get()); + break; + case types::slots160: + c.init(other.c.get()); + break; + case types::slots320: + c.init(other.c.get()); + break; + case types::slots640: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); + log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); } } -meas_trigger_quant_offset_c& meas_trigger_quant_offset_c::operator=(const meas_trigger_quant_offset_c& other) +csi_res_periodicity_and_offset_c& +csi_res_periodicity_and_offset_c::operator=(const csi_res_periodicity_and_offset_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rsrp: - c.set(other.c.get()); + case types::slots4: + c.set(other.c.get()); break; - case types::rsrq: - c.set(other.c.get()); + case types::slots5: + c.set(other.c.get()); break; - case types::sinr: - c.set(other.c.get()); + case types::slots8: + c.set(other.c.get()); + break; + case types::slots10: + c.set(other.c.get()); + break; + case types::slots16: + c.set(other.c.get()); + break; + case types::slots20: + c.set(other.c.get()); + break; + case types::slots32: + c.set(other.c.get()); + break; + case types::slots40: + c.set(other.c.get()); + break; + case types::slots64: + c.set(other.c.get()); + break; + case types::slots80: + c.set(other.c.get()); + break; + case types::slots160: + c.set(other.c.get()); + break; + case types::slots320: + c.set(other.c.get()); + break; + case types::slots640: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); + log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); } return *this; } -void meas_trigger_quant_offset_c::to_json(json_writer& j) const +void csi_res_periodicity_and_offset_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rsrp: - j.write_int("rsrp", c.get()); + case types::slots4: + j.write_int("slots4", c.get()); break; - case types::rsrq: - j.write_int("rsrq", c.get()); + case types::slots5: + j.write_int("slots5", c.get()); break; - case types::sinr: - j.write_int("sinr", c.get()); + case types::slots8: + j.write_int("slots8", c.get()); + break; + case types::slots10: + j.write_int("slots10", c.get()); + break; + case types::slots16: + j.write_int("slots16", c.get()); + break; + case types::slots20: + j.write_int("slots20", c.get()); + break; + case types::slots32: + j.write_int("slots32", c.get()); + break; + case types::slots40: + j.write_int("slots40", c.get()); + break; + case types::slots64: + j.write_int("slots64", c.get()); + break; + case types::slots80: + j.write_int("slots80", c.get()); + break; + case types::slots160: + j.write_int("slots160", c.get()); + break; + case types::slots320: + j.write_int("slots320", c.get()); + break; + case types::slots640: + j.write_int("slots640", c.get()); break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); + log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); } j.end_obj(); } -SRSASN_CODE meas_trigger_quant_offset_c::pack(bit_ref& bref) const +SRSASN_CODE csi_res_periodicity_and_offset_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rsrp: - HANDLE_CODE(pack_integer(bref, c.get(), (int8_t)-30, (int8_t)30)); + case types::slots4: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); break; - case types::rsrq: - HANDLE_CODE(pack_integer(bref, c.get(), (int8_t)-30, (int8_t)30)); + case types::slots5: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); break; - case types::sinr: - HANDLE_CODE(pack_integer(bref, c.get(), (int8_t)-30, (int8_t)30)); + case types::slots8: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); + break; + case types::slots10: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); + break; + case types::slots16: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); + break; + case types::slots20: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); + break; + case types::slots32: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); + break; + case types::slots40: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); + break; + case types::slots64: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + break; + case types::slots80: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); + break; + case types::slots160: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + break; + case types::slots320: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + break; + case types::slots640: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); + log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE meas_trigger_quant_offset_c::unpack(cbit_ref& bref) +SRSASN_CODE csi_res_periodicity_and_offset_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rsrp: - HANDLE_CODE(unpack_integer(c.get(), bref, (int8_t)-30, (int8_t)30)); + case types::slots4: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); break; - case types::rsrq: - HANDLE_CODE(unpack_integer(c.get(), bref, (int8_t)-30, (int8_t)30)); + case types::slots5: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); break; - case types::sinr: - HANDLE_CODE(unpack_integer(c.get(), bref, (int8_t)-30, (int8_t)30)); + case types::slots8: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); + break; + case types::slots10: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); + break; + case types::slots16: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); + break; + case types::slots20: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); + break; + case types::slots32: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); + break; + case types::slots40: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); + break; + case types::slots64: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); + break; + case types::slots80: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); + break; + case types::slots160: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + break; + case types::slots320: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + break; + case types::slots640: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); break; default: - log_invalid_choice_id(type_, "meas_trigger_quant_offset_c"); + log_invalid_choice_id(type_, "csi_res_periodicity_and_offset_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string meas_trigger_quant_offset_c::types_opts::to_string() const +std::string csi_res_periodicity_and_offset_c::types_opts::to_string() const { - static const char* options[] = {"rsrp", "rsrq", "sinr"}; - return convert_enum_idx(options, 3, value, "meas_trigger_quant_offset_c::types"); + static const char* options[] = {"slots4", + "slots5", + "slots8", + "slots10", + "slots16", + "slots20", + "slots32", + "slots40", + "slots64", + "slots80", + "slots160", + "slots320", + "slots640"}; + return convert_enum_idx(options, 13, value, "csi_res_periodicity_and_offset_c::types"); } - -// NR-RS-Type ::= ENUMERATED -std::string nr_rs_type_opts::to_string() const +uint16_t csi_res_periodicity_and_offset_c::types_opts::to_number() const { - static const char* options[] = {"ssb", "csi-rs"}; - return convert_enum_idx(options, 2, value, "nr_rs_type_e"); + static const uint16_t options[] = {4, 5, 8, 10, 16, 20, 32, 40, 64, 80, 160, 320, 640}; + return map_enum_number(options, 13, value, "csi_res_periodicity_and_offset_c::types"); } -// ReportInterval ::= ENUMERATED -std::string report_interv_opts::to_string() const +// INT-ConfigurationPerServingCell ::= SEQUENCE +SRSASN_CODE int_cfg_per_serving_cell_s::pack(bit_ref& bref) const { - static const char* options[] = {"ms120", - "ms240", - "ms480", - "ms640", - "ms1024", - "ms2048", - "ms5120", - "ms10240", - "ms20480", - "ms40960", - "min1", - "min6", - "min12", - "min30"}; - return convert_enum_idx(options, 14, value, "report_interv_e"); + HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(pack_integer(bref, position_in_dci, (uint8_t)0u, (uint8_t)125u)); + + return SRSASN_SUCCESS; } -uint16_t report_interv_opts::to_number() const +SRSASN_CODE int_cfg_per_serving_cell_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {120, 240, 480, 640, 1024, 2048, 5120, 10240, 20480, 40960, 1, 6, 12, 30}; - return map_enum_number(options, 14, value, "report_interv_e"); + HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(unpack_integer(position_in_dci, bref, (uint8_t)0u, (uint8_t)125u)); + + return SRSASN_SUCCESS; +} +void int_cfg_per_serving_cell_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("servingCellId", serving_cell_id); + j.write_int("positionInDCI", position_in_dci); + j.end_obj(); } -// SSB-ConfigMobility ::= SEQUENCE -SRSASN_CODE ssb_cfg_mob_s::pack(bit_ref& bref) const +// PTRS-DownlinkConfig ::= SEQUENCE +SRSASN_CODE ptrs_dl_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ssb_to_measure_present, 1)); - HANDLE_CODE(bref.pack(ss_rssi_meas_present, 1)); + HANDLE_CODE(bref.pack(freq_density_present, 1)); + HANDLE_CODE(bref.pack(time_density_present, 1)); + HANDLE_CODE(bref.pack(epre_ratio_present, 1)); + HANDLE_CODE(bref.pack(res_elem_offset_present, 1)); - if (ssb_to_measure_present) { - HANDLE_CODE(ssb_to_measure.pack(bref)); + if (freq_density_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, &(freq_density)[0], freq_density.size(), integer_packer(1, 276))); } - HANDLE_CODE(bref.pack(derive_ssb_idx_from_cell, 1)); - if (ss_rssi_meas_present) { - HANDLE_CODE(ss_rssi_meas.pack(bref)); + if (time_density_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, &(time_density)[0], time_density.size(), integer_packer(0, 29))); + } + if (epre_ratio_present) { + HANDLE_CODE(pack_integer(bref, epre_ratio, (uint8_t)0u, (uint8_t)3u)); + } + if (res_elem_offset_present) { + HANDLE_CODE(res_elem_offset.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE ssb_cfg_mob_s::unpack(cbit_ref& bref) +SRSASN_CODE ptrs_dl_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ssb_to_measure_present, 1)); - HANDLE_CODE(bref.unpack(ss_rssi_meas_present, 1)); + HANDLE_CODE(bref.unpack(freq_density_present, 1)); + HANDLE_CODE(bref.unpack(time_density_present, 1)); + HANDLE_CODE(bref.unpack(epre_ratio_present, 1)); + HANDLE_CODE(bref.unpack(res_elem_offset_present, 1)); - if (ssb_to_measure_present) { - HANDLE_CODE(ssb_to_measure.unpack(bref)); + if (freq_density_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(freq_density)[0], bref, freq_density.size(), integer_packer(1, 276))); } - HANDLE_CODE(bref.unpack(derive_ssb_idx_from_cell, 1)); - if (ss_rssi_meas_present) { - HANDLE_CODE(ss_rssi_meas.unpack(bref)); + if (time_density_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(time_density)[0], bref, time_density.size(), integer_packer(0, 29))); + } + if (epre_ratio_present) { + HANDLE_CODE(unpack_integer(epre_ratio, bref, (uint8_t)0u, (uint8_t)3u)); + } + if (res_elem_offset_present) { + HANDLE_CODE(res_elem_offset.unpack(bref)); } return SRSASN_SUCCESS; } -void ssb_cfg_mob_s::to_json(json_writer& j) const +void ptrs_dl_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (ssb_to_measure_present) { - j.write_fieldname("ssb-ToMeasure"); - ssb_to_measure.to_json(j); + if (freq_density_present) { + j.start_array("frequencyDensity"); + for (const auto& e1 : freq_density) { + j.write_int(e1); + } + j.end_array(); } - j.write_bool("deriveSSB-IndexFromCell", derive_ssb_idx_from_cell); - if (ss_rssi_meas_present) { - j.write_fieldname("ss-RSSI-Measurement"); - ss_rssi_meas.to_json(j); + if (time_density_present) { + j.start_array("timeDensity"); + for (const auto& e1 : time_density) { + j.write_int(e1); + } + j.end_array(); + } + if (epre_ratio_present) { + j.write_int("epre-Ratio", epre_ratio); + } + if (res_elem_offset_present) { + j.write_str("resourceElementOffset", res_elem_offset.to_string()); } j.end_obj(); } -// TimeToTrigger ::= ENUMERATED -std::string time_to_trigger_opts::to_string() const +std::string ptrs_dl_cfg_s::res_elem_offset_opts::to_string() const { - static const char* options[] = {"ms0", - "ms40", - "ms64", - "ms80", - "ms100", - "ms128", - "ms160", - "ms256", - "ms320", - "ms480", - "ms512", - "ms640", - "ms1024", - "ms1280", - "ms2560", - "ms5120"}; - return convert_enum_idx(options, 16, value, "time_to_trigger_e"); + static const char* options[] = {"offset01", "offset10", "offset11"}; + return convert_enum_idx(options, 3, value, "ptrs_dl_cfg_s::res_elem_offset_e_"); } -uint16_t time_to_trigger_opts::to_number() const +float ptrs_dl_cfg_s::res_elem_offset_opts::to_number() const { - static const uint16_t options[] = {0, 40, 64, 80, 100, 128, 160, 256, 320, 480, 512, 640, 1024, 1280, 2560, 5120}; - return map_enum_number(options, 16, value, "time_to_trigger_e"); + static const float options[] = {0.1, 1.0, 1.1}; + return map_enum_number(options, 3, value, "ptrs_dl_cfg_s::res_elem_offset_e_"); } - -// EUTRA-BlackCell ::= SEQUENCE -SRSASN_CODE eutra_black_cell_s::pack(bit_ref& bref) const +std::string ptrs_dl_cfg_s::res_elem_offset_opts::to_number_string() const { - HANDLE_CODE(pack_integer(bref, cell_idx_eutra, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(pci_range.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE eutra_black_cell_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(cell_idx_eutra, bref, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(pci_range.unpack(bref)); - - return SRSASN_SUCCESS; -} -void eutra_black_cell_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("cellIndexEUTRA", cell_idx_eutra); - j.write_fieldname("physCellIdRange"); - pci_range.to_json(j); - j.end_obj(); -} - -// EUTRA-Cell ::= SEQUENCE -SRSASN_CODE eutra_cell_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, cell_idx_eutra, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)503u)); - HANDLE_CODE(cell_individual_offset.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE eutra_cell_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(cell_idx_eutra, bref, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)503u)); - HANDLE_CODE(cell_individual_offset.unpack(bref)); - - return SRSASN_SUCCESS; -} -void eutra_cell_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("cellIndexEUTRA", cell_idx_eutra); - j.write_int("physCellId", pci); - j.write_str("cellIndividualOffset", cell_individual_offset.to_string()); - j.end_obj(); + static const char* options[] = {"0.1", "1.0", "1.1"}; + return convert_enum_idx(options, 3, value, "ptrs_dl_cfg_s::res_elem_offset_e_"); } -// EventTriggerConfig ::= SEQUENCE -SRSASN_CODE event_trigger_cfg_s::pack(bit_ref& bref) const +// QCL-Info ::= SEQUENCE +SRSASN_CODE qcl_info_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(report_quant_rs_idxes_present, 1)); - HANDLE_CODE(bref.pack(max_nrof_rs_idxes_to_report_present, 1)); - HANDLE_CODE(bref.pack(report_add_neigh_meas_present, 1)); + HANDLE_CODE(bref.pack(cell_present, 1)); + HANDLE_CODE(bref.pack(bwp_id_present, 1)); - HANDLE_CODE(event_id.pack(bref)); - HANDLE_CODE(rs_type.pack(bref)); - HANDLE_CODE(report_interv.pack(bref)); - HANDLE_CODE(report_amount.pack(bref)); - HANDLE_CODE(report_quant_cell.pack(bref)); - HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); - if (report_quant_rs_idxes_present) { - HANDLE_CODE(report_quant_rs_idxes.pack(bref)); + if (cell_present) { + HANDLE_CODE(pack_integer(bref, cell, (uint8_t)0u, (uint8_t)31u)); } - if (max_nrof_rs_idxes_to_report_present) { - HANDLE_CODE(pack_integer(bref, max_nrof_rs_idxes_to_report, (uint8_t)1u, (uint8_t)32u)); + if (bwp_id_present) { + HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); } - HANDLE_CODE(bref.pack(include_beam_meass, 1)); + HANDLE_CODE(ref_sig.pack(bref)); + HANDLE_CODE(qcl_type.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE event_trigger_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE qcl_info_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(report_quant_rs_idxes_present, 1)); - HANDLE_CODE(bref.unpack(max_nrof_rs_idxes_to_report_present, 1)); - HANDLE_CODE(bref.unpack(report_add_neigh_meas_present, 1)); + HANDLE_CODE(bref.unpack(cell_present, 1)); + HANDLE_CODE(bref.unpack(bwp_id_present, 1)); - HANDLE_CODE(event_id.unpack(bref)); - HANDLE_CODE(rs_type.unpack(bref)); - HANDLE_CODE(report_interv.unpack(bref)); - HANDLE_CODE(report_amount.unpack(bref)); - HANDLE_CODE(report_quant_cell.unpack(bref)); - HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); - if (report_quant_rs_idxes_present) { - HANDLE_CODE(report_quant_rs_idxes.unpack(bref)); + if (cell_present) { + HANDLE_CODE(unpack_integer(cell, bref, (uint8_t)0u, (uint8_t)31u)); } - if (max_nrof_rs_idxes_to_report_present) { - HANDLE_CODE(unpack_integer(max_nrof_rs_idxes_to_report, bref, (uint8_t)1u, (uint8_t)32u)); + if (bwp_id_present) { + HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); } - HANDLE_CODE(bref.unpack(include_beam_meass, 1)); + HANDLE_CODE(ref_sig.unpack(bref)); + HANDLE_CODE(qcl_type.unpack(bref)); return SRSASN_SUCCESS; } -void event_trigger_cfg_s::to_json(json_writer& j) const +void qcl_info_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("eventId"); - event_id.to_json(j); - j.write_str("rsType", rs_type.to_string()); - j.write_str("reportInterval", report_interv.to_string()); - j.write_str("reportAmount", report_amount.to_string()); - j.write_fieldname("reportQuantityCell"); - report_quant_cell.to_json(j); - j.write_int("maxReportCells", max_report_cells); - if (report_quant_rs_idxes_present) { - j.write_fieldname("reportQuantityRS-Indexes"); - report_quant_rs_idxes.to_json(j); - } - if (max_nrof_rs_idxes_to_report_present) { - j.write_int("maxNrofRS-IndexesToReport", max_nrof_rs_idxes_to_report); + if (cell_present) { + j.write_int("cell", cell); } - j.write_bool("includeBeamMeasurements", include_beam_meass); - if (report_add_neigh_meas_present) { - j.write_str("reportAddNeighMeas", "setup"); + if (bwp_id_present) { + j.write_int("bwp-Id", bwp_id); } + j.write_fieldname("referenceSignal"); + ref_sig.to_json(j); + j.write_str("qcl-Type", qcl_type.to_string()); j.end_obj(); } -void event_trigger_cfg_s::event_id_c_::destroy_() -{ - switch (type_) { - case types::event_a1: - c.destroy(); - break; - case types::event_a2: - c.destroy(); - break; - case types::event_a3: - c.destroy(); - break; - case types::event_a4: - c.destroy(); - break; - case types::event_a5: - c.destroy(); - break; - case types::event_a6: - c.destroy(); - break; - default: - break; - } -} -void event_trigger_cfg_s::event_id_c_::set(types::options e) +void qcl_info_s::ref_sig_c_::destroy_() {} +void qcl_info_s::ref_sig_c_::set(types::options e) { destroy_(); type_ = e; - switch (type_) { - case types::event_a1: - c.init(); - break; - case types::event_a2: - c.init(); - break; - case types::event_a3: - c.init(); - break; - case types::event_a4: - c.init(); - break; - case types::event_a5: - c.init(); - break; - case types::event_a6: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); - } } -event_trigger_cfg_s::event_id_c_::event_id_c_(const event_trigger_cfg_s::event_id_c_& other) +qcl_info_s::ref_sig_c_::ref_sig_c_(const qcl_info_s::ref_sig_c_& other) { type_ = other.type(); switch (type_) { - case types::event_a1: - c.init(other.c.get()); - break; - case types::event_a2: - c.init(other.c.get()); - break; - case types::event_a3: - c.init(other.c.get()); - break; - case types::event_a4: - c.init(other.c.get()); - break; - case types::event_a5: - c.init(other.c.get()); + case types::csi_rs: + c.init(other.c.get()); break; - case types::event_a6: - c.init(other.c.get()); + case types::ssb: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); + log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); } } -event_trigger_cfg_s::event_id_c_& event_trigger_cfg_s::event_id_c_:: - operator=(const event_trigger_cfg_s::event_id_c_& other) +qcl_info_s::ref_sig_c_& qcl_info_s::ref_sig_c_::operator=(const qcl_info_s::ref_sig_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::event_a1: - c.set(other.c.get()); - break; - case types::event_a2: - c.set(other.c.get()); - break; - case types::event_a3: - c.set(other.c.get()); - break; - case types::event_a4: - c.set(other.c.get()); - break; - case types::event_a5: - c.set(other.c.get()); + case types::csi_rs: + c.set(other.c.get()); break; - case types::event_a6: - c.set(other.c.get()); + case types::ssb: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); + log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); } return *this; } -void event_trigger_cfg_s::event_id_c_::to_json(json_writer& j) const +void qcl_info_s::ref_sig_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::event_a1: - j.write_fieldname("eventA1"); - j.start_obj(); - j.write_fieldname("a1-Threshold"); - c.get().a1_thres.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.end_obj(); - break; - case types::event_a2: - j.write_fieldname("eventA2"); - j.start_obj(); - j.write_fieldname("a2-Threshold"); - c.get().a2_thres.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.end_obj(); - break; - case types::event_a3: - j.write_fieldname("eventA3"); - j.start_obj(); - j.write_fieldname("a3-Offset"); - c.get().a3_offset.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.write_bool("useWhiteCellList", c.get().use_white_cell_list); - j.end_obj(); - break; - case types::event_a4: - j.write_fieldname("eventA4"); - j.start_obj(); - j.write_fieldname("a4-Threshold"); - c.get().a4_thres.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.write_bool("useWhiteCellList", c.get().use_white_cell_list); - j.end_obj(); - break; - case types::event_a5: - j.write_fieldname("eventA5"); - j.start_obj(); - j.write_fieldname("a5-Threshold1"); - c.get().a5_thres1.to_json(j); - j.write_fieldname("a5-Threshold2"); - c.get().a5_thres2.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.write_bool("useWhiteCellList", c.get().use_white_cell_list); - j.end_obj(); + case types::csi_rs: + j.write_int("csi-rs", c.get()); break; - case types::event_a6: - j.write_fieldname("eventA6"); - j.start_obj(); - j.write_fieldname("a6-Offset"); - c.get().a6_offset.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.write_bool("useWhiteCellList", c.get().use_white_cell_list); - j.end_obj(); + case types::ssb: + j.write_int("ssb", c.get()); break; default: - log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); + log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); } j.end_obj(); } -SRSASN_CODE event_trigger_cfg_s::event_id_c_::pack(bit_ref& bref) const +SRSASN_CODE qcl_info_s::ref_sig_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::event_a1: - HANDLE_CODE(c.get().a1_thres.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - break; - case types::event_a2: - HANDLE_CODE(c.get().a2_thres.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - break; - case types::event_a3: - HANDLE_CODE(c.get().a3_offset.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); - break; - case types::event_a4: - HANDLE_CODE(c.get().a4_thres.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); - break; - case types::event_a5: - HANDLE_CODE(c.get().a5_thres1.pack(bref)); - HANDLE_CODE(c.get().a5_thres2.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); + case types::csi_rs: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); break; - case types::event_a6: - HANDLE_CODE(c.get().a6_offset.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - HANDLE_CODE(bref.pack(c.get().use_white_cell_list, 1)); + case types::ssb: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); break; default: - log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); + log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE event_trigger_cfg_s::event_id_c_::unpack(cbit_ref& bref) +SRSASN_CODE qcl_info_s::ref_sig_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::event_a1: - HANDLE_CODE(c.get().a1_thres.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - break; - case types::event_a2: - HANDLE_CODE(c.get().a2_thres.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - break; - case types::event_a3: - HANDLE_CODE(c.get().a3_offset.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); - break; - case types::event_a4: - HANDLE_CODE(c.get().a4_thres.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); - break; - case types::event_a5: - HANDLE_CODE(c.get().a5_thres1.unpack(bref)); - HANDLE_CODE(c.get().a5_thres2.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); + case types::csi_rs: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); break; - case types::event_a6: - HANDLE_CODE(c.get().a6_offset.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().use_white_cell_list, 1)); + case types::ssb: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); break; default: - log_invalid_choice_id(type_, "event_trigger_cfg_s::event_id_c_"); + log_invalid_choice_id(type_, "qcl_info_s::ref_sig_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string event_trigger_cfg_s::event_id_c_::types_opts::to_string() const -{ - static const char* options[] = {"eventA1", "eventA2", "eventA3", "eventA4", "eventA5", "eventA6"}; - return convert_enum_idx(options, 6, value, "event_trigger_cfg_s::event_id_c_::types"); -} -uint8_t event_trigger_cfg_s::event_id_c_::types_opts::to_number() const +std::string qcl_info_s::ref_sig_c_::types_opts::to_string() const { - static const uint8_t options[] = {1, 2, 3, 4, 5, 6}; - return map_enum_number(options, 6, value, "event_trigger_cfg_s::event_id_c_::types"); + static const char* options[] = {"csi-rs", "ssb"}; + return convert_enum_idx(options, 2, value, "qcl_info_s::ref_sig_c_::types"); } -std::string event_trigger_cfg_s::report_amount_opts::to_string() const -{ - static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; - return convert_enum_idx(options, 8, value, "event_trigger_cfg_s::report_amount_e_"); -} -int8_t event_trigger_cfg_s::report_amount_opts::to_number() const +std::string qcl_info_s::qcl_type_opts::to_string() const { - static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; - return map_enum_number(options, 8, value, "event_trigger_cfg_s::report_amount_e_"); + static const char* options[] = {"typeA", "typeB", "typeC", "typeD"}; + return convert_enum_idx(options, 4, value, "qcl_info_s::qcl_type_e_"); } -// EventTriggerConfigInterRAT ::= SEQUENCE -SRSASN_CODE event_trigger_cfg_inter_rat_s::pack(bit_ref& bref) const +// DMRS-DownlinkConfig ::= SEQUENCE +SRSASN_CODE dmrs_dl_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(event_id.pack(bref)); - HANDLE_CODE(rs_type.pack(bref)); - HANDLE_CODE(report_interv.pack(bref)); - HANDLE_CODE(report_amount.pack(bref)); - HANDLE_CODE(report_quant.pack(bref)); - HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(bref.pack(dmrs_type_present, 1)); + HANDLE_CODE(bref.pack(dmrs_add_position_present, 1)); + HANDLE_CODE(bref.pack(max_len_present, 1)); + HANDLE_CODE(bref.pack(scrambling_id0_present, 1)); + HANDLE_CODE(bref.pack(scrambling_id1_present, 1)); + HANDLE_CODE(bref.pack(phase_tracking_rs_present, 1)); + + if (dmrs_add_position_present) { + HANDLE_CODE(dmrs_add_position.pack(bref)); + } + if (scrambling_id0_present) { + HANDLE_CODE(pack_integer(bref, scrambling_id0, (uint32_t)0u, (uint32_t)65535u)); + } + if (scrambling_id1_present) { + HANDLE_CODE(pack_integer(bref, scrambling_id1, (uint32_t)0u, (uint32_t)65535u)); + } + if (phase_tracking_rs_present) { + HANDLE_CODE(phase_tracking_rs.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE event_trigger_cfg_inter_rat_s::unpack(cbit_ref& bref) +SRSASN_CODE dmrs_dl_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(event_id.unpack(bref)); - HANDLE_CODE(rs_type.unpack(bref)); - HANDLE_CODE(report_interv.unpack(bref)); - HANDLE_CODE(report_amount.unpack(bref)); - HANDLE_CODE(report_quant.unpack(bref)); - HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(bref.unpack(dmrs_type_present, 1)); + HANDLE_CODE(bref.unpack(dmrs_add_position_present, 1)); + HANDLE_CODE(bref.unpack(max_len_present, 1)); + HANDLE_CODE(bref.unpack(scrambling_id0_present, 1)); + HANDLE_CODE(bref.unpack(scrambling_id1_present, 1)); + HANDLE_CODE(bref.unpack(phase_tracking_rs_present, 1)); + + if (dmrs_add_position_present) { + HANDLE_CODE(dmrs_add_position.unpack(bref)); + } + if (scrambling_id0_present) { + HANDLE_CODE(unpack_integer(scrambling_id0, bref, (uint32_t)0u, (uint32_t)65535u)); + } + if (scrambling_id1_present) { + HANDLE_CODE(unpack_integer(scrambling_id1, bref, (uint32_t)0u, (uint32_t)65535u)); + } + if (phase_tracking_rs_present) { + HANDLE_CODE(phase_tracking_rs.unpack(bref)); + } return SRSASN_SUCCESS; } -void event_trigger_cfg_inter_rat_s::to_json(json_writer& j) const +void dmrs_dl_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("eventId"); - event_id.to_json(j); - j.write_str("rsType", rs_type.to_string()); - j.write_str("reportInterval", report_interv.to_string()); - j.write_str("reportAmount", report_amount.to_string()); - j.write_fieldname("reportQuantity"); - report_quant.to_json(j); - j.write_int("maxReportCells", max_report_cells); + if (dmrs_type_present) { + j.write_str("dmrs-Type", "type2"); + } + if (dmrs_add_position_present) { + j.write_str("dmrs-AdditionalPosition", dmrs_add_position.to_string()); + } + if (max_len_present) { + j.write_str("maxLength", "len2"); + } + if (scrambling_id0_present) { + j.write_int("scramblingID0", scrambling_id0); + } + if (scrambling_id1_present) { + j.write_int("scramblingID1", scrambling_id1); + } + if (phase_tracking_rs_present) { + j.write_fieldname("phaseTrackingRS"); + phase_tracking_rs.to_json(j); + } j.end_obj(); } -void event_trigger_cfg_inter_rat_s::event_id_c_::destroy_() +std::string dmrs_dl_cfg_s::dmrs_add_position_opts::to_string() const { - switch (type_) { - case types::event_b1: - c.destroy(); - break; - case types::event_b2: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"pos0", "pos1", "pos3"}; + return convert_enum_idx(options, 3, value, "dmrs_dl_cfg_s::dmrs_add_position_e_"); } -void event_trigger_cfg_inter_rat_s::event_id_c_::set(types::options e) +uint8_t dmrs_dl_cfg_s::dmrs_add_position_opts::to_number() const { - destroy_(); - type_ = e; - switch (type_) { - case types::event_b1: - c.init(); - break; - case types::event_b2: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); - } + static const uint8_t options[] = {0, 1, 3}; + return map_enum_number(options, 3, value, "dmrs_dl_cfg_s::dmrs_add_position_e_"); } -event_trigger_cfg_inter_rat_s::event_id_c_::event_id_c_(const event_trigger_cfg_inter_rat_s::event_id_c_& other) + +// DownlinkPreemption ::= SEQUENCE +SRSASN_CODE dl_preemption_s::pack(bit_ref& bref) const { - type_ = other.type(); - switch (type_) { - case types::event_b1: - c.init(other.c.get()); - break; - case types::event_b2: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); - } + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, int_rnti, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(time_freq_set.pack(bref)); + HANDLE_CODE(pack_integer(bref, dci_payload_size, (uint8_t)0u, (uint8_t)126u)); + HANDLE_CODE(pack_dyn_seq_of(bref, int_cfg_per_serving_cell, 1, 32)); + + return SRSASN_SUCCESS; } -event_trigger_cfg_inter_rat_s::event_id_c_& event_trigger_cfg_inter_rat_s::event_id_c_:: - operator=(const event_trigger_cfg_inter_rat_s::event_id_c_& other) +SRSASN_CODE dl_preemption_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::event_b1: - c.set(other.c.get()); - break; - case types::event_b2: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); - } + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(int_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(time_freq_set.unpack(bref)); + HANDLE_CODE(unpack_integer(dci_payload_size, bref, (uint8_t)0u, (uint8_t)126u)); + HANDLE_CODE(unpack_dyn_seq_of(int_cfg_per_serving_cell, bref, 1, 32)); - return *this; + return SRSASN_SUCCESS; } -void event_trigger_cfg_inter_rat_s::event_id_c_::to_json(json_writer& j) const +void dl_preemption_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::event_b1: - j.write_fieldname("eventB1"); - j.start_obj(); - j.write_fieldname("b1-ThresholdEUTRA"); - c.get().b1_thres_eutra.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.end_obj(); - break; - case types::event_b2: - j.write_fieldname("eventB2"); - j.start_obj(); - j.write_fieldname("b2-Threshold1"); - c.get().b2_thres1.to_json(j); - j.write_fieldname("b2-Threshold2EUTRA"); - c.get().b2_thres2_eutra.to_json(j); - j.write_bool("reportOnLeave", c.get().report_on_leave); - j.write_int("hysteresis", c.get().hysteresis); - j.write_str("timeToTrigger", c.get().time_to_trigger.to_string()); - j.end_obj(); - break; - default: - log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); + j.write_int("int-RNTI", int_rnti); + j.write_str("timeFrequencySet", time_freq_set.to_string()); + j.write_int("dci-PayloadSize", dci_payload_size); + j.start_array("int-ConfigurationPerServingCell"); + for (const auto& e1 : int_cfg_per_serving_cell) { + e1.to_json(j); } + j.end_array(); j.end_obj(); } -SRSASN_CODE event_trigger_cfg_inter_rat_s::event_id_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::event_b1: - bref.pack(c.get().ext, 1); - HANDLE_CODE(c.get().b1_thres_eutra.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - break; - case types::event_b2: - bref.pack(c.get().ext, 1); - HANDLE_CODE(c.get().b2_thres1.pack(bref)); - HANDLE_CODE(c.get().b2_thres2_eutra.pack(bref)); - HANDLE_CODE(bref.pack(c.get().report_on_leave, 1)); - HANDLE_CODE(pack_integer(bref, c.get().hysteresis, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.pack(bref)); - break; - default: - log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE event_trigger_cfg_inter_rat_s::event_id_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::event_b1: - bref.unpack(c.get().ext, 1); - HANDLE_CODE(c.get().b1_thres_eutra.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - break; - case types::event_b2: - bref.unpack(c.get().ext, 1); - HANDLE_CODE(c.get().b2_thres1.unpack(bref)); - HANDLE_CODE(c.get().b2_thres2_eutra.unpack(bref)); - HANDLE_CODE(bref.unpack(c.get().report_on_leave, 1)); - HANDLE_CODE(unpack_integer(c.get().hysteresis, bref, (uint8_t)0u, (uint8_t)30u)); - HANDLE_CODE(c.get().time_to_trigger.unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "event_trigger_cfg_inter_rat_s::event_id_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; -} - -std::string event_trigger_cfg_inter_rat_s::event_id_c_::types_opts::to_string() const -{ - static const char* options[] = {"eventB1", "eventB2"}; - return convert_enum_idx(options, 2, value, "event_trigger_cfg_inter_rat_s::event_id_c_::types"); -} -uint8_t event_trigger_cfg_inter_rat_s::event_id_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "event_trigger_cfg_inter_rat_s::event_id_c_::types"); -} -std::string event_trigger_cfg_inter_rat_s::report_amount_opts::to_string() const +std::string dl_preemption_s::time_freq_set_opts::to_string() const { - static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; - return convert_enum_idx(options, 8, value, "event_trigger_cfg_inter_rat_s::report_amount_e_"); + static const char* options[] = {"set0", "set1"}; + return convert_enum_idx(options, 2, value, "dl_preemption_s::time_freq_set_e_"); } -int8_t event_trigger_cfg_inter_rat_s::report_amount_opts::to_number() const +uint8_t dl_preemption_s::time_freq_set_opts::to_number() const { - static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; - return map_enum_number(options, 8, value, "event_trigger_cfg_inter_rat_s::report_amount_e_"); + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "dl_preemption_s::time_freq_set_e_"); } -// FilterConfig ::= SEQUENCE -SRSASN_CODE filt_cfg_s::pack(bit_ref& bref) const +// PUCCH-TPC-CommandConfig ::= SEQUENCE +SRSASN_CODE pucch_tpc_cmd_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(filt_coef_rsrp_present, 1)); - HANDLE_CODE(bref.pack(filt_coef_rsrq_present, 1)); - HANDLE_CODE(bref.pack(filt_coef_rs_sinr_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(tpc_idx_pcell_present, 1)); + HANDLE_CODE(bref.pack(tpc_idx_pucch_scell_present, 1)); - if (filt_coef_rsrp_present) { - HANDLE_CODE(filt_coef_rsrp.pack(bref)); - } - if (filt_coef_rsrq_present) { - HANDLE_CODE(filt_coef_rsrq.pack(bref)); + if (tpc_idx_pcell_present) { + HANDLE_CODE(pack_integer(bref, tpc_idx_pcell, (uint8_t)1u, (uint8_t)15u)); } - if (filt_coef_rs_sinr_present) { - HANDLE_CODE(filt_coef_rs_sinr.pack(bref)); + if (tpc_idx_pucch_scell_present) { + HANDLE_CODE(pack_integer(bref, tpc_idx_pucch_scell, (uint8_t)1u, (uint8_t)15u)); } return SRSASN_SUCCESS; } -SRSASN_CODE filt_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_tpc_cmd_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(filt_coef_rsrp_present, 1)); - HANDLE_CODE(bref.unpack(filt_coef_rsrq_present, 1)); - HANDLE_CODE(bref.unpack(filt_coef_rs_sinr_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(tpc_idx_pcell_present, 1)); + HANDLE_CODE(bref.unpack(tpc_idx_pucch_scell_present, 1)); - if (filt_coef_rsrp_present) { - HANDLE_CODE(filt_coef_rsrp.unpack(bref)); - } - if (filt_coef_rsrq_present) { - HANDLE_CODE(filt_coef_rsrq.unpack(bref)); + if (tpc_idx_pcell_present) { + HANDLE_CODE(unpack_integer(tpc_idx_pcell, bref, (uint8_t)1u, (uint8_t)15u)); } - if (filt_coef_rs_sinr_present) { - HANDLE_CODE(filt_coef_rs_sinr.unpack(bref)); + if (tpc_idx_pucch_scell_present) { + HANDLE_CODE(unpack_integer(tpc_idx_pucch_scell, bref, (uint8_t)1u, (uint8_t)15u)); } return SRSASN_SUCCESS; } -void filt_cfg_s::to_json(json_writer& j) const +void pucch_tpc_cmd_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (filt_coef_rsrp_present) { - j.write_str("filterCoefficientRSRP", filt_coef_rsrp.to_string()); - } - if (filt_coef_rsrq_present) { - j.write_str("filterCoefficientRSRQ", filt_coef_rsrq.to_string()); + if (tpc_idx_pcell_present) { + j.write_int("tpc-IndexPCell", tpc_idx_pcell); } - if (filt_coef_rs_sinr_present) { - j.write_str("filterCoefficientRS-SINR", filt_coef_rs_sinr.to_string()); + if (tpc_idx_pucch_scell_present) { + j.write_int("tpc-IndexPUCCH-SCell", tpc_idx_pucch_scell); } j.end_obj(); } -// PCI-RangeElement ::= SEQUENCE -SRSASN_CODE pci_range_elem_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, pci_range_idx, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(pci_range.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE pci_range_elem_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(pci_range_idx, bref, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(pci_range.unpack(bref)); - - return SRSASN_SUCCESS; -} -void pci_range_elem_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("pci-RangeIndex", pci_range_idx); - j.write_fieldname("pci-Range"); - pci_range.to_json(j); - j.end_obj(); -} - -// PeriodicalReportConfig ::= SEQUENCE -SRSASN_CODE periodical_report_cfg_s::pack(bit_ref& bref) const +// PUSCH-TPC-CommandConfig ::= SEQUENCE +SRSASN_CODE pusch_tpc_cmd_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(report_quant_rs_idxes_present, 1)); - HANDLE_CODE(bref.pack(max_nrof_rs_idxes_to_report_present, 1)); + HANDLE_CODE(bref.pack(tpc_idx_present, 1)); + HANDLE_CODE(bref.pack(tpc_idx_sul_present, 1)); + HANDLE_CODE(bref.pack(target_cell_present, 1)); - HANDLE_CODE(rs_type.pack(bref)); - HANDLE_CODE(report_interv.pack(bref)); - HANDLE_CODE(report_amount.pack(bref)); - HANDLE_CODE(report_quant_cell.pack(bref)); - HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); - if (report_quant_rs_idxes_present) { - HANDLE_CODE(report_quant_rs_idxes.pack(bref)); + if (tpc_idx_present) { + HANDLE_CODE(pack_integer(bref, tpc_idx, (uint8_t)1u, (uint8_t)15u)); } - if (max_nrof_rs_idxes_to_report_present) { - HANDLE_CODE(pack_integer(bref, max_nrof_rs_idxes_to_report, (uint8_t)1u, (uint8_t)32u)); + if (tpc_idx_sul_present) { + HANDLE_CODE(pack_integer(bref, tpc_idx_sul, (uint8_t)1u, (uint8_t)15u)); + } + if (target_cell_present) { + HANDLE_CODE(pack_integer(bref, target_cell, (uint8_t)0u, (uint8_t)31u)); } - HANDLE_CODE(bref.pack(include_beam_meass, 1)); - HANDLE_CODE(bref.pack(use_white_cell_list, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE periodical_report_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE pusch_tpc_cmd_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(report_quant_rs_idxes_present, 1)); - HANDLE_CODE(bref.unpack(max_nrof_rs_idxes_to_report_present, 1)); + HANDLE_CODE(bref.unpack(tpc_idx_present, 1)); + HANDLE_CODE(bref.unpack(tpc_idx_sul_present, 1)); + HANDLE_CODE(bref.unpack(target_cell_present, 1)); - HANDLE_CODE(rs_type.unpack(bref)); - HANDLE_CODE(report_interv.unpack(bref)); - HANDLE_CODE(report_amount.unpack(bref)); - HANDLE_CODE(report_quant_cell.unpack(bref)); - HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); - if (report_quant_rs_idxes_present) { - HANDLE_CODE(report_quant_rs_idxes.unpack(bref)); + if (tpc_idx_present) { + HANDLE_CODE(unpack_integer(tpc_idx, bref, (uint8_t)1u, (uint8_t)15u)); } - if (max_nrof_rs_idxes_to_report_present) { - HANDLE_CODE(unpack_integer(max_nrof_rs_idxes_to_report, bref, (uint8_t)1u, (uint8_t)32u)); + if (tpc_idx_sul_present) { + HANDLE_CODE(unpack_integer(tpc_idx_sul, bref, (uint8_t)1u, (uint8_t)15u)); + } + if (target_cell_present) { + HANDLE_CODE(unpack_integer(target_cell, bref, (uint8_t)0u, (uint8_t)31u)); } - HANDLE_CODE(bref.unpack(include_beam_meass, 1)); - HANDLE_CODE(bref.unpack(use_white_cell_list, 1)); return SRSASN_SUCCESS; } -void periodical_report_cfg_s::to_json(json_writer& j) const +void pusch_tpc_cmd_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("rsType", rs_type.to_string()); - j.write_str("reportInterval", report_interv.to_string()); - j.write_str("reportAmount", report_amount.to_string()); - j.write_fieldname("reportQuantityCell"); - report_quant_cell.to_json(j); - j.write_int("maxReportCells", max_report_cells); - if (report_quant_rs_idxes_present) { - j.write_fieldname("reportQuantityRS-Indexes"); - report_quant_rs_idxes.to_json(j); + if (tpc_idx_present) { + j.write_int("tpc-Index", tpc_idx); } - if (max_nrof_rs_idxes_to_report_present) { - j.write_int("maxNrofRS-IndexesToReport", max_nrof_rs_idxes_to_report); + if (tpc_idx_sul_present) { + j.write_int("tpc-IndexSUL", tpc_idx_sul); + } + if (target_cell_present) { + j.write_int("targetCell", target_cell); } - j.write_bool("includeBeamMeasurements", include_beam_meass); - j.write_bool("useWhiteCellList", use_white_cell_list); j.end_obj(); } -std::string periodical_report_cfg_s::report_amount_opts::to_string() const -{ - static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; - return convert_enum_idx(options, 8, value, "periodical_report_cfg_s::report_amount_e_"); -} -int8_t periodical_report_cfg_s::report_amount_opts::to_number() const -{ - static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; - return map_enum_number(options, 8, value, "periodical_report_cfg_s::report_amount_e_"); -} - -// PeriodicalReportConfigInterRAT ::= SEQUENCE -SRSASN_CODE periodical_report_cfg_inter_rat_s::pack(bit_ref& bref) const +// RadioLinkMonitoringRS ::= SEQUENCE +SRSASN_CODE radio_link_monitoring_rs_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(report_interv.pack(bref)); - HANDLE_CODE(report_amount.pack(bref)); - HANDLE_CODE(report_quant.pack(bref)); - HANDLE_CODE(pack_integer(bref, max_report_cells, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(pack_integer(bref, radio_link_monitoring_rs_id, (uint8_t)0u, (uint8_t)9u)); + HANDLE_CODE(purpose.pack(bref)); + HANDLE_CODE(detection_res.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE periodical_report_cfg_inter_rat_s::unpack(cbit_ref& bref) +SRSASN_CODE radio_link_monitoring_rs_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(report_interv.unpack(bref)); - HANDLE_CODE(report_amount.unpack(bref)); - HANDLE_CODE(report_quant.unpack(bref)); - HANDLE_CODE(unpack_integer(max_report_cells, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(unpack_integer(radio_link_monitoring_rs_id, bref, (uint8_t)0u, (uint8_t)9u)); + HANDLE_CODE(purpose.unpack(bref)); + HANDLE_CODE(detection_res.unpack(bref)); return SRSASN_SUCCESS; } -void periodical_report_cfg_inter_rat_s::to_json(json_writer& j) const +void radio_link_monitoring_rs_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("reportInterval", report_interv.to_string()); - j.write_str("reportAmount", report_amount.to_string()); - j.write_fieldname("reportQuantity"); - report_quant.to_json(j); - j.write_int("maxReportCells", max_report_cells); + j.write_int("radioLinkMonitoringRS-Id", radio_link_monitoring_rs_id); + j.write_str("purpose", purpose.to_string()); + j.write_fieldname("detectionResource"); + detection_res.to_json(j); j.end_obj(); } -std::string periodical_report_cfg_inter_rat_s::report_amount_opts::to_string() const +std::string radio_link_monitoring_rs_s::purpose_opts::to_string() const { - static const char* options[] = {"r1", "r2", "r4", "r8", "r16", "r32", "r64", "infinity"}; - return convert_enum_idx(options, 8, value, "periodical_report_cfg_inter_rat_s::report_amount_e_"); + static const char* options[] = {"beamFailure", "rlf", "both"}; + return convert_enum_idx(options, 3, value, "radio_link_monitoring_rs_s::purpose_e_"); } -int8_t periodical_report_cfg_inter_rat_s::report_amount_opts::to_number() const + +void radio_link_monitoring_rs_s::detection_res_c_::destroy_() {} +void radio_link_monitoring_rs_s::detection_res_c_::set(types::options e) { - static const int8_t options[] = {1, 2, 4, 8, 16, 32, 64, -1}; - return map_enum_number(options, 8, value, "periodical_report_cfg_inter_rat_s::report_amount_e_"); + destroy_(); + type_ = e; } - -// RAN-AreaConfig ::= SEQUENCE -SRSASN_CODE ran_area_cfg_s::pack(bit_ref& bref) const +radio_link_monitoring_rs_s::detection_res_c_::detection_res_c_( + const radio_link_monitoring_rs_s::detection_res_c_& other) { - HANDLE_CODE(bref.pack(ran_area_code_list_present, 1)); - - HANDLE_CODE(tac.pack(bref)); - if (ran_area_code_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ran_area_code_list, 1, 32, integer_packer(0, 255))); + type_ = other.type(); + switch (type_) { + case types::ssb_idx: + c.init(other.c.get()); + break; + case types::csi_rs_idx: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); } - - return SRSASN_SUCCESS; } -SRSASN_CODE ran_area_cfg_s::unpack(cbit_ref& bref) +radio_link_monitoring_rs_s::detection_res_c_& +radio_link_monitoring_rs_s::detection_res_c_::operator=(const radio_link_monitoring_rs_s::detection_res_c_& other) { - HANDLE_CODE(bref.unpack(ran_area_code_list_present, 1)); - - HANDLE_CODE(tac.unpack(bref)); - if (ran_area_code_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ran_area_code_list, bref, 1, 32, integer_packer(0, 255))); + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::ssb_idx: + c.set(other.c.get()); + break; + case types::csi_rs_idx: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); } - return SRSASN_SUCCESS; + return *this; } -void ran_area_cfg_s::to_json(json_writer& j) const +void radio_link_monitoring_rs_s::detection_res_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_str("trackingAreaCode", tac.to_string()); - if (ran_area_code_list_present) { - j.start_array("ran-AreaCodeList"); - for (const auto& e1 : ran_area_code_list) { - j.write_int(e1); - } - j.end_array(); + switch (type_) { + case types::ssb_idx: + j.write_int("ssb-Index", c.get()); + break; + case types::csi_rs_idx: + j.write_int("csi-RS-Index", c.get()); + break; + default: + log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); } j.end_obj(); } - -// ReferenceSignalConfig ::= SEQUENCE -SRSASN_CODE ref_sig_cfg_s::pack(bit_ref& bref) const +SRSASN_CODE radio_link_monitoring_rs_s::detection_res_c_::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(ssb_cfg_mob_present, 1)); - HANDLE_CODE(bref.pack(csi_rs_res_cfg_mob_present, 1)); - - if (ssb_cfg_mob_present) { - HANDLE_CODE(ssb_cfg_mob.pack(bref)); - } - if (csi_rs_res_cfg_mob_present) { - HANDLE_CODE(csi_rs_res_cfg_mob.pack(bref)); + type_.pack(bref); + switch (type_) { + case types::ssb_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + break; + case types::csi_rs_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + break; + default: + log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } - return SRSASN_SUCCESS; } -SRSASN_CODE ref_sig_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE radio_link_monitoring_rs_s::detection_res_c_::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(ssb_cfg_mob_present, 1)); - HANDLE_CODE(bref.unpack(csi_rs_res_cfg_mob_present, 1)); - - if (ssb_cfg_mob_present) { - HANDLE_CODE(ssb_cfg_mob.unpack(bref)); - } - if (csi_rs_res_cfg_mob_present) { - HANDLE_CODE(csi_rs_res_cfg_mob.unpack(bref)); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ssb_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); + break; + case types::csi_rs_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + break; + default: + log_invalid_choice_id(type_, "radio_link_monitoring_rs_s::detection_res_c_"); + return SRSASN_ERROR_DECODE_FAIL; } - return SRSASN_SUCCESS; } -void ref_sig_cfg_s::to_json(json_writer& j) const + +std::string radio_link_monitoring_rs_s::detection_res_c_::types_opts::to_string() const { - j.start_obj(); - if (ssb_cfg_mob_present) { - j.write_fieldname("ssb-ConfigMobility"); - ssb_cfg_mob.to_json(j); - } - if (csi_rs_res_cfg_mob_present) { - j.write_fieldname("csi-rs-ResourceConfigMobility"); - csi_rs_res_cfg_mob.to_json(j); - } - j.end_obj(); + static const char* options[] = {"ssb-Index", "csi-RS-Index"}; + return convert_enum_idx(options, 2, value, "radio_link_monitoring_rs_s::detection_res_c_::types"); } -// ReportCGI ::= SEQUENCE -SRSASN_CODE report_cgi_s::pack(bit_ref& bref) const +// RateMatchPattern ::= SEQUENCE +SRSASN_CODE rate_match_pattern_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, cell_for_which_to_report_cgi, (uint16_t)0u, (uint16_t)1007u)); + HANDLE_CODE(bref.pack(subcarrier_spacing_present, 1)); - return SRSASN_SUCCESS; -} -SRSASN_CODE report_cgi_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(cell_for_which_to_report_cgi, bref, (uint16_t)0u, (uint16_t)1007u)); - - return SRSASN_SUCCESS; -} -void report_cgi_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("cellForWhichToReportCGI", cell_for_which_to_report_cgi); - j.end_obj(); -} - -// ReportCGI-EUTRA ::= SEQUENCE -SRSASN_CODE report_cgi_eutra_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, cell_for_which_to_report_cgi, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(pack_integer(bref, rate_match_pattern_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pattern_type.pack(bref)); + if (subcarrier_spacing_present) { + HANDLE_CODE(subcarrier_spacing.pack(bref)); + } + HANDLE_CODE(dummy.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE report_cgi_eutra_s::unpack(cbit_ref& bref) +SRSASN_CODE rate_match_pattern_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(cell_for_which_to_report_cgi, bref, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(bref.unpack(subcarrier_spacing_present, 1)); + + HANDLE_CODE(unpack_integer(rate_match_pattern_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pattern_type.unpack(bref)); + if (subcarrier_spacing_present) { + HANDLE_CODE(subcarrier_spacing.unpack(bref)); + } + HANDLE_CODE(dummy.unpack(bref)); return SRSASN_SUCCESS; } -void report_cgi_eutra_s::to_json(json_writer& j) const +void rate_match_pattern_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("cellForWhichToReportCGI", cell_for_which_to_report_cgi); + j.write_int("rateMatchPatternId", rate_match_pattern_id); + j.write_fieldname("patternType"); + pattern_type.to_json(j); + if (subcarrier_spacing_present) { + j.write_str("subcarrierSpacing", subcarrier_spacing.to_string()); + } + j.write_str("dummy", dummy.to_string()); j.end_obj(); } -// SSB-MTC2 ::= SEQUENCE -SRSASN_CODE ssb_mtc2_s::pack(bit_ref& bref) const +void rate_match_pattern_s::pattern_type_c_::destroy_() { - HANDLE_CODE(bref.pack(pci_list_present, 1)); - - if (pci_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, pci_list, 1, 64, integer_packer(0, 1007))); + switch (type_) { + case types::bitmaps: + c.destroy(); + break; + default: + break; } - HANDLE_CODE(periodicity.pack(bref)); - - return SRSASN_SUCCESS; } -SRSASN_CODE ssb_mtc2_s::unpack(cbit_ref& bref) +void rate_match_pattern_s::pattern_type_c_::set(types::options e) { - HANDLE_CODE(bref.unpack(pci_list_present, 1)); - - if (pci_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(pci_list, bref, 1, 64, integer_packer(0, 1007))); + destroy_(); + type_ = e; + switch (type_) { + case types::bitmaps: + c.init(); + break; + case types::ctrl_res_set: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + } +} +rate_match_pattern_s::pattern_type_c_::pattern_type_c_(const rate_match_pattern_s::pattern_type_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::bitmaps: + c.init(other.c.get()); + break; + case types::ctrl_res_set: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + } +} +rate_match_pattern_s::pattern_type_c_& +rate_match_pattern_s::pattern_type_c_::operator=(const rate_match_pattern_s::pattern_type_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::bitmaps: + c.set(other.c.get()); + break; + case types::ctrl_res_set: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); } - HANDLE_CODE(periodicity.unpack(bref)); - return SRSASN_SUCCESS; + return *this; } -void ssb_mtc2_s::to_json(json_writer& j) const +void rate_match_pattern_s::pattern_type_c_::to_json(json_writer& j) const { j.start_obj(); - if (pci_list_present) { - j.start_array("pci-List"); - for (const auto& e1 : pci_list) { - j.write_int(e1); - } - j.end_array(); + switch (type_) { + case types::bitmaps: + j.write_fieldname("bitmaps"); + j.start_obj(); + j.write_str("resourceBlocks", c.get().res_blocks.to_string()); + j.write_fieldname("symbolsInResourceBlock"); + c.get().symbols_in_res_block.to_json(j); + if (c.get().periodicity_and_pattern_present) { + j.write_fieldname("periodicityAndPattern"); + c.get().periodicity_and_pattern.to_json(j); + } + j.end_obj(); + break; + case types::ctrl_res_set: + j.write_int("controlResourceSet", c.get()); + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); } - j.write_str("periodicity", periodicity.to_string()); j.end_obj(); } - -std::string ssb_mtc2_s::periodicity_opts::to_string() const +SRSASN_CODE rate_match_pattern_s::pattern_type_c_::pack(bit_ref& bref) const { - static const char* options[] = {"sf5", "sf10", "sf20", "sf40", "sf80", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 8, value, "ssb_mtc2_s::periodicity_e_"); + type_.pack(bref); + switch (type_) { + case types::bitmaps: + bref.pack(c.get().ext, 1); + HANDLE_CODE(bref.pack(c.get().periodicity_and_pattern_present, 1)); + HANDLE_CODE(c.get().res_blocks.pack(bref)); + HANDLE_CODE(c.get().symbols_in_res_block.pack(bref)); + if (c.get().periodicity_and_pattern_present) { + HANDLE_CODE(c.get().periodicity_and_pattern.pack(bref)); + } + break; + case types::ctrl_res_set: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)11u)); + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } -uint8_t ssb_mtc2_s::periodicity_opts::to_number() const +SRSASN_CODE rate_match_pattern_s::pattern_type_c_::unpack(cbit_ref& bref) { - static const uint8_t options[] = {5, 10, 20, 40, 80}; - return map_enum_number(options, 5, value, "ssb_mtc2_s::periodicity_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::bitmaps: + bref.unpack(c.get().ext, 1); + HANDLE_CODE(bref.unpack(c.get().periodicity_and_pattern_present, 1)); + HANDLE_CODE(c.get().res_blocks.unpack(bref)); + HANDLE_CODE(c.get().symbols_in_res_block.unpack(bref)); + if (c.get().periodicity_and_pattern_present) { + HANDLE_CODE(c.get().periodicity_and_pattern.unpack(bref)); + } + break; + case types::ctrl_res_set: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)11u)); + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -// MeasObjectEUTRA ::= SEQUENCE -SRSASN_CODE meas_obj_eutra_s::pack(bit_ref& bref) const +void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::destroy_() { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(cells_to_rem_list_eutran_present, 1)); - HANDLE_CODE(bref.pack(cells_to_add_mod_list_eutran_present, 1)); - HANDLE_CODE(bref.pack(black_cells_to_rem_list_eutran_present, 1)); - HANDLE_CODE(bref.pack(black_cells_to_add_mod_list_eutran_present, 1)); - HANDLE_CODE(bref.pack(eutra_q_offset_range_present, 1)); - - HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)262143u)); - HANDLE_CODE(allowed_meas_bw.pack(bref)); - if (cells_to_rem_list_eutran_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_rem_list_eutran, 1, 32, integer_packer(1, 32))); - } - if (cells_to_add_mod_list_eutran_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_add_mod_list_eutran, 1, 32)); - } - if (black_cells_to_rem_list_eutran_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_rem_list_eutran, 1, 32, integer_packer(1, 32))); - } - if (black_cells_to_add_mod_list_eutran_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_add_mod_list_eutran, 1, 32)); - } - HANDLE_CODE(bref.pack(eutra_presence_ant_port1, 1)); - if (eutra_q_offset_range_present) { - HANDLE_CODE(eutra_q_offset_range.pack(bref)); + switch (type_) { + case types::one_slot: + c.destroy >(); + break; + case types::two_slots: + c.destroy >(); + break; + default: + break; } - HANDLE_CODE(bref.pack(wideband_rsrq_meas, 1)); - - return SRSASN_SUCCESS; } -SRSASN_CODE meas_obj_eutra_s::unpack(cbit_ref& bref) +void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::set(types::options e) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(cells_to_rem_list_eutran_present, 1)); - HANDLE_CODE(bref.unpack(cells_to_add_mod_list_eutran_present, 1)); - HANDLE_CODE(bref.unpack(black_cells_to_rem_list_eutran_present, 1)); - HANDLE_CODE(bref.unpack(black_cells_to_add_mod_list_eutran_present, 1)); - HANDLE_CODE(bref.unpack(eutra_q_offset_range_present, 1)); - - HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)262143u)); - HANDLE_CODE(allowed_meas_bw.unpack(bref)); - if (cells_to_rem_list_eutran_present) { - HANDLE_CODE(unpack_dyn_seq_of(cells_to_rem_list_eutran, bref, 1, 32, integer_packer(1, 32))); - } - if (cells_to_add_mod_list_eutran_present) { - HANDLE_CODE(unpack_dyn_seq_of(cells_to_add_mod_list_eutran, bref, 1, 32)); + destroy_(); + type_ = e; + switch (type_) { + case types::one_slot: + c.init >(); + break; + case types::two_slots: + c.init >(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); } - if (black_cells_to_rem_list_eutran_present) { - HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_rem_list_eutran, bref, 1, 32, integer_packer(1, 32))); +} +rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::symbols_in_res_block_c_( + const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::one_slot: + c.init(other.c.get >()); + break; + case types::two_slots: + c.init(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); } - if (black_cells_to_add_mod_list_eutran_present) { - HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_add_mod_list_eutran, bref, 1, 32)); +} +rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_& +rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::operator=( + const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_& other) +{ + if (this == &other) { + return *this; } - HANDLE_CODE(bref.unpack(eutra_presence_ant_port1, 1)); - if (eutra_q_offset_range_present) { - HANDLE_CODE(eutra_q_offset_range.unpack(bref)); + set(other.type()); + switch (type_) { + case types::one_slot: + c.set(other.c.get >()); + break; + case types::two_slots: + c.set(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); } - HANDLE_CODE(bref.unpack(wideband_rsrq_meas, 1)); - return SRSASN_SUCCESS; + return *this; } -void meas_obj_eutra_s::to_json(json_writer& j) const +void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_int("carrierFreq", carrier_freq); - j.write_str("allowedMeasBandwidth", allowed_meas_bw.to_string()); - if (cells_to_rem_list_eutran_present) { - j.start_array("cellsToRemoveListEUTRAN"); - for (const auto& e1 : cells_to_rem_list_eutran) { - j.write_int(e1); - } - j.end_array(); - } - if (cells_to_add_mod_list_eutran_present) { - j.start_array("cellsToAddModListEUTRAN"); - for (const auto& e1 : cells_to_add_mod_list_eutran) { - e1.to_json(j); - } - j.end_array(); - } - if (black_cells_to_rem_list_eutran_present) { - j.start_array("blackCellsToRemoveListEUTRAN"); - for (const auto& e1 : black_cells_to_rem_list_eutran) { - j.write_int(e1); - } - j.end_array(); - } - if (black_cells_to_add_mod_list_eutran_present) { - j.start_array("blackCellsToAddModListEUTRAN"); - for (const auto& e1 : black_cells_to_add_mod_list_eutran) { - e1.to_json(j); - } - j.end_array(); - } - j.write_bool("eutra-PresenceAntennaPort1", eutra_presence_ant_port1); - if (eutra_q_offset_range_present) { - j.write_str("eutra-Q-OffsetRange", eutra_q_offset_range.to_string()); + switch (type_) { + case types::one_slot: + j.write_str("oneSlot", c.get >().to_string()); + break; + case types::two_slots: + j.write_str("twoSlots", c.get >().to_string()); + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); } - j.write_bool("widebandRSRQ-Meas", wideband_rsrq_meas); j.end_obj(); } - -// MeasObjectNR ::= SEQUENCE -SRSASN_CODE meas_obj_nr_s::pack(bit_ref& bref) const +SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ssb_freq_present, 1)); - HANDLE_CODE(bref.pack(ssb_subcarrier_spacing_present, 1)); - HANDLE_CODE(bref.pack(smtc1_present, 1)); - HANDLE_CODE(bref.pack(smtc2_present, 1)); - HANDLE_CODE(bref.pack(ref_freq_csi_rs_present, 1)); - HANDLE_CODE(bref.pack(abs_thresh_ss_blocks_consolidation_present, 1)); - HANDLE_CODE(bref.pack(abs_thresh_csi_rs_consolidation_present, 1)); - HANDLE_CODE(bref.pack(nrof_ss_blocks_to_average_present, 1)); - HANDLE_CODE(bref.pack(nrof_csi_rs_res_to_average_present, 1)); - HANDLE_CODE(bref.pack(cells_to_rem_list_present, 1)); - HANDLE_CODE(bref.pack(cells_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(black_cells_to_rem_list_present, 1)); - HANDLE_CODE(bref.pack(black_cells_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(white_cells_to_rem_list_present, 1)); - HANDLE_CODE(bref.pack(white_cells_to_add_mod_list_present, 1)); - - if (ssb_freq_present) { - HANDLE_CODE(pack_integer(bref, ssb_freq, (uint32_t)0u, (uint32_t)3279165u)); - } - if (ssb_subcarrier_spacing_present) { - HANDLE_CODE(ssb_subcarrier_spacing.pack(bref)); - } - if (smtc1_present) { - HANDLE_CODE(smtc1.pack(bref)); - } - if (smtc2_present) { - HANDLE_CODE(smtc2.pack(bref)); - } - if (ref_freq_csi_rs_present) { - HANDLE_CODE(pack_integer(bref, ref_freq_csi_rs, (uint32_t)0u, (uint32_t)3279165u)); - } - HANDLE_CODE(ref_sig_cfg.pack(bref)); - if (abs_thresh_ss_blocks_consolidation_present) { - HANDLE_CODE(abs_thresh_ss_blocks_consolidation.pack(bref)); - } - if (abs_thresh_csi_rs_consolidation_present) { - HANDLE_CODE(abs_thresh_csi_rs_consolidation.pack(bref)); - } - if (nrof_ss_blocks_to_average_present) { - HANDLE_CODE(pack_integer(bref, nrof_ss_blocks_to_average, (uint8_t)2u, (uint8_t)16u)); - } - if (nrof_csi_rs_res_to_average_present) { - HANDLE_CODE(pack_integer(bref, nrof_csi_rs_res_to_average, (uint8_t)2u, (uint8_t)16u)); - } - HANDLE_CODE(pack_integer(bref, quant_cfg_idx, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(offset_mo.pack(bref)); - if (cells_to_rem_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_rem_list, 1, 32, integer_packer(0, 1007))); - } - if (cells_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, cells_to_add_mod_list, 1, 32)); - } - if (black_cells_to_rem_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_rem_list, 1, 8, integer_packer(1, 8))); - } - if (black_cells_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, black_cells_to_add_mod_list, 1, 8)); - } - if (white_cells_to_rem_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, white_cells_to_rem_list, 1, 8, integer_packer(1, 8))); - } - if (white_cells_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, white_cells_to_add_mod_list, 1, 8)); + type_.pack(bref); + switch (type_) { + case types::one_slot: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::two_slots: + HANDLE_CODE(c.get >().pack(bref)); + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= freq_band_ind_nr_v1530_present; - group_flags[0] |= meas_cycle_scell_v1530_present; - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(freq_band_ind_nr_v1530_present, 1)); - HANDLE_CODE(bref.pack(meas_cycle_scell_v1530_present, 1)); - if (freq_band_ind_nr_v1530_present) { - HANDLE_CODE(pack_integer(bref, freq_band_ind_nr_v1530, (uint16_t)1u, (uint16_t)1024u)); - } - if (meas_cycle_scell_v1530_present) { - HANDLE_CODE(meas_cycle_scell_v1530.pack(bref)); - } - } + return SRSASN_SUCCESS; +} +SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::one_slot: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::two_slots: + HANDLE_CODE(c.get >().unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_"); + return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE meas_obj_nr_s::unpack(cbit_ref& bref) + +std::string rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types_opts::to_string() const { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ssb_freq_present, 1)); - HANDLE_CODE(bref.unpack(ssb_subcarrier_spacing_present, 1)); - HANDLE_CODE(bref.unpack(smtc1_present, 1)); - HANDLE_CODE(bref.unpack(smtc2_present, 1)); - HANDLE_CODE(bref.unpack(ref_freq_csi_rs_present, 1)); - HANDLE_CODE(bref.unpack(abs_thresh_ss_blocks_consolidation_present, 1)); - HANDLE_CODE(bref.unpack(abs_thresh_csi_rs_consolidation_present, 1)); - HANDLE_CODE(bref.unpack(nrof_ss_blocks_to_average_present, 1)); - HANDLE_CODE(bref.unpack(nrof_csi_rs_res_to_average_present, 1)); - HANDLE_CODE(bref.unpack(cells_to_rem_list_present, 1)); - HANDLE_CODE(bref.unpack(cells_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(black_cells_to_rem_list_present, 1)); - HANDLE_CODE(bref.unpack(black_cells_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(white_cells_to_rem_list_present, 1)); - HANDLE_CODE(bref.unpack(white_cells_to_add_mod_list_present, 1)); + static const char* options[] = {"oneSlot", "twoSlots"}; + return convert_enum_idx( + options, 2, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types"); +} +uint8_t rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number( + options, 2, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::symbols_in_res_block_c_::types"); +} - if (ssb_freq_present) { - HANDLE_CODE(unpack_integer(ssb_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); +void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::destroy_() +{ + switch (type_) { + case types::n2: + c.destroy >(); + break; + case types::n4: + c.destroy >(); + break; + case types::n5: + c.destroy >(); + break; + case types::n8: + c.destroy >(); + break; + case types::n10: + c.destroy >(); + break; + case types::n20: + c.destroy >(); + break; + case types::n40: + c.destroy >(); + break; + default: + break; } - if (ssb_subcarrier_spacing_present) { - HANDLE_CODE(ssb_subcarrier_spacing.unpack(bref)); - } - if (smtc1_present) { - HANDLE_CODE(smtc1.unpack(bref)); - } - if (smtc2_present) { - HANDLE_CODE(smtc2.unpack(bref)); - } - if (ref_freq_csi_rs_present) { - HANDLE_CODE(unpack_integer(ref_freq_csi_rs, bref, (uint32_t)0u, (uint32_t)3279165u)); - } - HANDLE_CODE(ref_sig_cfg.unpack(bref)); - if (abs_thresh_ss_blocks_consolidation_present) { - HANDLE_CODE(abs_thresh_ss_blocks_consolidation.unpack(bref)); - } - if (abs_thresh_csi_rs_consolidation_present) { - HANDLE_CODE(abs_thresh_csi_rs_consolidation.unpack(bref)); - } - if (nrof_ss_blocks_to_average_present) { - HANDLE_CODE(unpack_integer(nrof_ss_blocks_to_average, bref, (uint8_t)2u, (uint8_t)16u)); - } - if (nrof_csi_rs_res_to_average_present) { - HANDLE_CODE(unpack_integer(nrof_csi_rs_res_to_average, bref, (uint8_t)2u, (uint8_t)16u)); - } - HANDLE_CODE(unpack_integer(quant_cfg_idx, bref, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(offset_mo.unpack(bref)); - if (cells_to_rem_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(cells_to_rem_list, bref, 1, 32, integer_packer(0, 1007))); - } - if (cells_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(cells_to_add_mod_list, bref, 1, 32)); - } - if (black_cells_to_rem_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_rem_list, bref, 1, 8, integer_packer(1, 8))); - } - if (black_cells_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(black_cells_to_add_mod_list, bref, 1, 8)); - } - if (white_cells_to_rem_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(white_cells_to_rem_list, bref, 1, 8, integer_packer(1, 8))); - } - if (white_cells_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(white_cells_to_add_mod_list, bref, 1, 8)); - } - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.unpack(freq_band_ind_nr_v1530_present, 1)); - HANDLE_CODE(bref.unpack(meas_cycle_scell_v1530_present, 1)); - if (freq_band_ind_nr_v1530_present) { - HANDLE_CODE(unpack_integer(freq_band_ind_nr_v1530, bref, (uint16_t)1u, (uint16_t)1024u)); - } - if (meas_cycle_scell_v1530_present) { - HANDLE_CODE(meas_cycle_scell_v1530.unpack(bref)); - } - } - } - return SRSASN_SUCCESS; -} -void meas_obj_nr_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (ssb_freq_present) { - j.write_int("ssbFrequency", ssb_freq); - } - if (ssb_subcarrier_spacing_present) { - j.write_str("ssbSubcarrierSpacing", ssb_subcarrier_spacing.to_string()); - } - if (smtc1_present) { - j.write_fieldname("smtc1"); - smtc1.to_json(j); - } - if (smtc2_present) { - j.write_fieldname("smtc2"); - smtc2.to_json(j); - } - if (ref_freq_csi_rs_present) { - j.write_int("refFreqCSI-RS", ref_freq_csi_rs); - } - j.write_fieldname("referenceSignalConfig"); - ref_sig_cfg.to_json(j); - if (abs_thresh_ss_blocks_consolidation_present) { - j.write_fieldname("absThreshSS-BlocksConsolidation"); - abs_thresh_ss_blocks_consolidation.to_json(j); - } - if (abs_thresh_csi_rs_consolidation_present) { - j.write_fieldname("absThreshCSI-RS-Consolidation"); - abs_thresh_csi_rs_consolidation.to_json(j); - } - if (nrof_ss_blocks_to_average_present) { - j.write_int("nrofSS-BlocksToAverage", nrof_ss_blocks_to_average); - } - if (nrof_csi_rs_res_to_average_present) { - j.write_int("nrofCSI-RS-ResourcesToAverage", nrof_csi_rs_res_to_average); - } - j.write_int("quantityConfigIndex", quant_cfg_idx); - j.write_fieldname("offsetMO"); - offset_mo.to_json(j); - if (cells_to_rem_list_present) { - j.start_array("cellsToRemoveList"); - for (const auto& e1 : cells_to_rem_list) { - j.write_int(e1); - } - j.end_array(); - } - if (cells_to_add_mod_list_present) { - j.start_array("cellsToAddModList"); - for (const auto& e1 : cells_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (black_cells_to_rem_list_present) { - j.start_array("blackCellsToRemoveList"); - for (const auto& e1 : black_cells_to_rem_list) { - j.write_int(e1); - } - j.end_array(); - } - if (black_cells_to_add_mod_list_present) { - j.start_array("blackCellsToAddModList"); - for (const auto& e1 : black_cells_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (white_cells_to_rem_list_present) { - j.start_array("whiteCellsToRemoveList"); - for (const auto& e1 : white_cells_to_rem_list) { - j.write_int(e1); - } - j.end_array(); - } - if (white_cells_to_add_mod_list_present) { - j.start_array("whiteCellsToAddModList"); - for (const auto& e1 : white_cells_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (ext) { - if (freq_band_ind_nr_v1530_present) { - j.write_int("freqBandIndicatorNR-v1530", freq_band_ind_nr_v1530); - } - if (meas_cycle_scell_v1530_present) { - j.write_str("measCycleSCell-v1530", meas_cycle_scell_v1530.to_string()); - } - } - j.end_obj(); -} - -std::string meas_obj_nr_s::meas_cycle_scell_v1530_opts::to_string() const -{ - static const char* options[] = {"sf160", "sf256", "sf320", "sf512", "sf640", "sf1024", "sf1280"}; - return convert_enum_idx(options, 7, value, "meas_obj_nr_s::meas_cycle_scell_v1530_e_"); -} -uint16_t meas_obj_nr_s::meas_cycle_scell_v1530_opts::to_number() const -{ - static const uint16_t options[] = {160, 256, 320, 512, 640, 1024, 1280}; - return map_enum_number(options, 7, value, "meas_obj_nr_s::meas_cycle_scell_v1530_e_"); -} - -// OverheatingAssistanceConfig ::= SEQUENCE -SRSASN_CODE overheat_assist_cfg_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(overheat_ind_prohibit_timer.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE overheat_assist_cfg_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(overheat_ind_prohibit_timer.unpack(bref)); - - return SRSASN_SUCCESS; -} -void overheat_assist_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_str("overheatingIndicationProhibitTimer", overheat_ind_prohibit_timer.to_string()); - j.end_obj(); -} - -std::string overheat_assist_cfg_s::overheat_ind_prohibit_timer_opts::to_string() const -{ - static const char* options[] = {"s0", - "s0dot5", - "s1", - "s2", - "s5", - "s10", - "s20", - "s30", - "s60", - "s90", - "s120", - "s300", - "s600", - "spare3", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "overheat_assist_cfg_s::overheat_ind_prohibit_timer_e_"); -} -float overheat_assist_cfg_s::overheat_ind_prohibit_timer_opts::to_number() const -{ - static const float options[] = {0.0, 0.5, 1.0, 2.0, 5.0, 10.0, 20.0, 30.0, 60.0, 90.0, 120.0, 300.0, 600.0}; - return map_enum_number(options, 13, value, "overheat_assist_cfg_s::overheat_ind_prohibit_timer_e_"); -} -std::string overheat_assist_cfg_s::overheat_ind_prohibit_timer_opts::to_number_string() const -{ - static const char* options[] = {"0", "0.5", "1", "2", "5", "10", "20", "30", "60", "90", "120", "300", "600"}; - return convert_enum_idx(options, 16, value, "overheat_assist_cfg_s::overheat_ind_prohibit_timer_e_"); -} - -// PLMN-RAN-AreaCell ::= SEQUENCE -SRSASN_CODE plmn_ran_area_cell_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(plmn_id_present, 1)); - - if (plmn_id_present) { - HANDLE_CODE(plmn_id.pack(bref)); - } - HANDLE_CODE(pack_dyn_seq_of(bref, ran_area_cells, 1, 32)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE plmn_ran_area_cell_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(plmn_id_present, 1)); - - if (plmn_id_present) { - HANDLE_CODE(plmn_id.unpack(bref)); - } - HANDLE_CODE(unpack_dyn_seq_of(ran_area_cells, bref, 1, 32)); - - return SRSASN_SUCCESS; -} -void plmn_ran_area_cell_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (plmn_id_present) { - j.write_fieldname("plmn-Identity"); - plmn_id.to_json(j); - } - j.start_array("ran-AreaCells"); - for (const auto& e1 : ran_area_cells) { - j.write_str(e1.to_string()); - } - j.end_array(); - j.end_obj(); -} - -// PLMN-RAN-AreaConfig ::= SEQUENCE -SRSASN_CODE plmn_ran_area_cfg_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(plmn_id_present, 1)); - - if (plmn_id_present) { - HANDLE_CODE(plmn_id.pack(bref)); - } - HANDLE_CODE(pack_dyn_seq_of(bref, ran_area, 1, 16)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE plmn_ran_area_cfg_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(plmn_id_present, 1)); - - if (plmn_id_present) { - HANDLE_CODE(plmn_id.unpack(bref)); - } - HANDLE_CODE(unpack_dyn_seq_of(ran_area, bref, 1, 16)); - - return SRSASN_SUCCESS; -} -void plmn_ran_area_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (plmn_id_present) { - j.write_fieldname("plmn-Identity"); - plmn_id.to_json(j); - } - j.start_array("ran-Area"); - for (const auto& e1 : ran_area) { - e1.to_json(j); - } - j.end_array(); - j.end_obj(); -} - -// QuantityConfigRS ::= SEQUENCE -SRSASN_CODE quant_cfg_rs_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(ssb_filt_cfg.pack(bref)); - HANDLE_CODE(csi_rs_filt_cfg.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE quant_cfg_rs_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(ssb_filt_cfg.unpack(bref)); - HANDLE_CODE(csi_rs_filt_cfg.unpack(bref)); - - return SRSASN_SUCCESS; -} -void quant_cfg_rs_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("ssb-FilterConfig"); - ssb_filt_cfg.to_json(j); - j.write_fieldname("csi-RS-FilterConfig"); - csi_rs_filt_cfg.to_json(j); - j.end_obj(); -} - -// ReportConfigInterRAT ::= SEQUENCE -SRSASN_CODE report_cfg_inter_rat_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(report_type.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE report_cfg_inter_rat_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(report_type.unpack(bref)); - - return SRSASN_SUCCESS; -} -void report_cfg_inter_rat_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("reportType"); - report_type.to_json(j); - j.end_obj(); } - -void report_cfg_inter_rat_s::report_type_c_::destroy_() +void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::set(types::options e) { + destroy_(); + type_ = e; switch (type_) { - case types::periodical: - c.destroy(); + case types::n2: + c.init >(); break; - case types::event_triggered: - c.destroy(); + case types::n4: + c.init >(); break; - case types::report_cgi: - c.destroy(); + case types::n5: + c.init >(); break; - default: + case types::n8: + c.init >(); break; - } -} -void report_cfg_inter_rat_s::report_type_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::periodical: - c.init(); + case types::n10: + c.init >(); break; - case types::event_triggered: - c.init(); + case types::n20: + c.init >(); break; - case types::report_cgi: - c.init(); + case types::n40: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); } } -report_cfg_inter_rat_s::report_type_c_::report_type_c_(const report_cfg_inter_rat_s::report_type_c_& other) +rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::periodicity_and_pattern_c_( + const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_& other) { type_ = other.type(); switch (type_) { - case types::periodical: - c.init(other.c.get()); + case types::n2: + c.init(other.c.get >()); break; - case types::event_triggered: - c.init(other.c.get()); + case types::n4: + c.init(other.c.get >()); break; - case types::report_cgi: - c.init(other.c.get()); + case types::n5: + c.init(other.c.get >()); + break; + case types::n8: + c.init(other.c.get >()); + break; + case types::n10: + c.init(other.c.get >()); + break; + case types::n20: + c.init(other.c.get >()); + break; + case types::n40: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); } } -report_cfg_inter_rat_s::report_type_c_& report_cfg_inter_rat_s::report_type_c_:: - operator=(const report_cfg_inter_rat_s::report_type_c_& other) +rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_& +rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::operator=( + const rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::periodical: - c.set(other.c.get()); + case types::n2: + c.set(other.c.get >()); break; - case types::event_triggered: - c.set(other.c.get()); + case types::n4: + c.set(other.c.get >()); break; - case types::report_cgi: - c.set(other.c.get()); + case types::n5: + c.set(other.c.get >()); + break; + case types::n8: + c.set(other.c.get >()); + break; + case types::n10: + c.set(other.c.get >()); + break; + case types::n20: + c.set(other.c.get >()); + break; + case types::n40: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); } return *this; } -void report_cfg_inter_rat_s::report_type_c_::to_json(json_writer& j) const +void rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::periodical: - j.write_fieldname("periodical"); - c.get().to_json(j); + case types::n2: + j.write_str("n2", c.get >().to_string()); break; - case types::event_triggered: - j.write_fieldname("eventTriggered"); - c.get().to_json(j); + case types::n4: + j.write_str("n4", c.get >().to_string()); break; - case types::report_cgi: - j.write_fieldname("reportCGI"); - c.get().to_json(j); + case types::n5: + j.write_str("n5", c.get >().to_string()); + break; + case types::n8: + j.write_str("n8", c.get >().to_string()); + break; + case types::n10: + j.write_str("n10", c.get >().to_string()); + break; + case types::n20: + j.write_str("n20", c.get >().to_string()); + break; + case types::n40: + j.write_str("n40", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); } j.end_obj(); } -SRSASN_CODE report_cfg_inter_rat_s::report_type_c_::pack(bit_ref& bref) const +SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::periodical: - HANDLE_CODE(c.get().pack(bref)); + case types::n2: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::event_triggered: - HANDLE_CODE(c.get().pack(bref)); + case types::n4: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::report_cgi: - HANDLE_CODE(c.get().pack(bref)); + case types::n5: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::n8: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::n10: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::n20: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::n40: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE report_cfg_inter_rat_s::report_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::periodical: - HANDLE_CODE(c.get().unpack(bref)); + case types::n2: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::event_triggered: - HANDLE_CODE(c.get().unpack(bref)); + case types::n4: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::report_cgi: - HANDLE_CODE(c.get().unpack(bref)); + case types::n5: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::n8: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::n10: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::n20: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::n40: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "report_cfg_inter_rat_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string report_cfg_inter_rat_s::report_type_c_::types_opts::to_string() const +std::string rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types_opts::to_string() const { - static const char* options[] = {"periodical", "eventTriggered", "reportCGI"}; - return convert_enum_idx(options, 3, value, "report_cfg_inter_rat_s::report_type_c_::types"); -} - -// ReportConfigNR ::= SEQUENCE -SRSASN_CODE report_cfg_nr_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(report_type.pack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"n2", "n4", "n5", "n8", "n10", "n20", "n40"}; + return convert_enum_idx( + options, 7, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types"); } -SRSASN_CODE report_cfg_nr_s::unpack(cbit_ref& bref) +uint8_t rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types_opts::to_number() const { - HANDLE_CODE(report_type.unpack(bref)); - - return SRSASN_SUCCESS; + static const uint8_t options[] = {2, 4, 5, 8, 10, 20, 40}; + return map_enum_number( + options, 7, value, "rate_match_pattern_s::pattern_type_c_::bitmaps_s_::periodicity_and_pattern_c_::types"); } -void report_cfg_nr_s::to_json(json_writer& j) const + +std::string rate_match_pattern_s::pattern_type_c_::types_opts::to_string() const { - j.start_obj(); - j.write_fieldname("reportType"); - report_type.to_json(j); - j.end_obj(); + static const char* options[] = {"bitmaps", "controlResourceSet"}; + return convert_enum_idx(options, 2, value, "rate_match_pattern_s::pattern_type_c_::types"); } -void report_cfg_nr_s::report_type_c_::destroy_() +std::string rate_match_pattern_s::dummy_opts::to_string() const { - switch (type_) { - case types::periodical: - c.destroy(); - break; - case types::event_triggered: - c.destroy(); - break; - case types::report_cgi: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"dynamic", "semiStatic"}; + return convert_enum_idx(options, 2, value, "rate_match_pattern_s::dummy_e_"); } -void report_cfg_nr_s::report_type_c_::set(types::options e) + +void rate_match_pattern_group_item_c_::destroy_() {} +void rate_match_pattern_group_item_c_::set(types::options e) { destroy_(); type_ = e; - switch (type_) { - case types::periodical: - c.init(); - break; - case types::event_triggered: - c.init(); - break; - case types::report_cgi: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); - } } -report_cfg_nr_s::report_type_c_::report_type_c_(const report_cfg_nr_s::report_type_c_& other) +rate_match_pattern_group_item_c_::rate_match_pattern_group_item_c_(const rate_match_pattern_group_item_c_& other) { type_ = other.type(); switch (type_) { - case types::periodical: - c.init(other.c.get()); - break; - case types::event_triggered: - c.init(other.c.get()); + case types::cell_level: + c.init(other.c.get()); break; - case types::report_cgi: - c.init(other.c.get()); + case types::bwp_level: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); } } -report_cfg_nr_s::report_type_c_& report_cfg_nr_s::report_type_c_:: - operator=(const report_cfg_nr_s::report_type_c_& other) +rate_match_pattern_group_item_c_& +rate_match_pattern_group_item_c_::operator=(const rate_match_pattern_group_item_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::periodical: - c.set(other.c.get()); - break; - case types::event_triggered: - c.set(other.c.get()); + case types::cell_level: + c.set(other.c.get()); break; - case types::report_cgi: - c.set(other.c.get()); + case types::bwp_level: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); } return *this; } -void report_cfg_nr_s::report_type_c_::to_json(json_writer& j) const +void rate_match_pattern_group_item_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::periodical: - j.write_fieldname("periodical"); - c.get().to_json(j); - break; - case types::event_triggered: - j.write_fieldname("eventTriggered"); - c.get().to_json(j); + case types::cell_level: + j.write_int("cellLevel", c.get()); break; - case types::report_cgi: - j.write_fieldname("reportCGI"); - c.get().to_json(j); + case types::bwp_level: + j.write_int("bwpLevel", c.get()); break; default: - log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); } j.end_obj(); } -SRSASN_CODE report_cfg_nr_s::report_type_c_::pack(bit_ref& bref) const +SRSASN_CODE rate_match_pattern_group_item_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::periodical: - HANDLE_CODE(c.get().pack(bref)); + case types::cell_level: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); break; - case types::event_triggered: - HANDLE_CODE(c.get().pack(bref)); + case types::bwp_level: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); break; - case types::report_cgi: { - varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get().pack(bref)); - } break; default: - log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE report_cfg_nr_s::report_type_c_::unpack(cbit_ref& bref) +SRSASN_CODE rate_match_pattern_group_item_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::periodical: - HANDLE_CODE(c.get().unpack(bref)); + case types::cell_level: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); break; - case types::event_triggered: - HANDLE_CODE(c.get().unpack(bref)); + case types::bwp_level: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); break; - case types::report_cgi: { - varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get().unpack(bref)); - } break; default: - log_invalid_choice_id(type_, "report_cfg_nr_s::report_type_c_"); + log_invalid_choice_id(type_, "rate_match_pattern_group_item_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string report_cfg_nr_s::report_type_c_::types_opts::to_string() const +std::string rate_match_pattern_group_item_c_::types_opts::to_string() const { - static const char* options[] = {"periodical", "eventTriggered", "reportCGI"}; - return convert_enum_idx(options, 3, value, "report_cfg_nr_s::report_type_c_::types"); + static const char* options[] = {"cellLevel", "bwpLevel"}; + return convert_enum_idx(options, 2, value, "rate_match_pattern_group_item_c_::types"); } -// FreqPriorityEUTRA ::= SEQUENCE -SRSASN_CODE freq_prio_eutra_s::pack(bit_ref& bref) const +// SRS-TPC-CommandConfig ::= SEQUENCE +SRSASN_CODE srs_tpc_cmd_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(cell_resel_sub_prio_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(start_bit_of_format2_minus3_present, 1)); + HANDLE_CODE(bref.pack(field_type_format2_minus3_present, 1)); - HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)262143u)); - HANDLE_CODE(pack_integer(bref, cell_resel_prio, (uint8_t)0u, (uint8_t)7u)); - if (cell_resel_sub_prio_present) { - HANDLE_CODE(cell_resel_sub_prio.pack(bref)); + if (start_bit_of_format2_minus3_present) { + HANDLE_CODE(pack_integer(bref, start_bit_of_format2_minus3, (uint8_t)1u, (uint8_t)31u)); + } + if (field_type_format2_minus3_present) { + HANDLE_CODE(pack_integer(bref, field_type_format2_minus3, (uint8_t)0u, (uint8_t)1u)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= start_bit_of_format2_minus3_sul_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(start_bit_of_format2_minus3_sul_present, 1)); + if (start_bit_of_format2_minus3_sul_present) { + HANDLE_CODE(pack_integer(bref, start_bit_of_format2_minus3_sul, (uint8_t)1u, (uint8_t)31u)); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE freq_prio_eutra_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_tpc_cmd_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(cell_resel_sub_prio_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(start_bit_of_format2_minus3_present, 1)); + HANDLE_CODE(bref.unpack(field_type_format2_minus3_present, 1)); - HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)262143u)); - HANDLE_CODE(unpack_integer(cell_resel_prio, bref, (uint8_t)0u, (uint8_t)7u)); - if (cell_resel_sub_prio_present) { - HANDLE_CODE(cell_resel_sub_prio.unpack(bref)); + if (start_bit_of_format2_minus3_present) { + HANDLE_CODE(unpack_integer(start_bit_of_format2_minus3, bref, (uint8_t)1u, (uint8_t)31u)); } + if (field_type_format2_minus3_present) { + HANDLE_CODE(unpack_integer(field_type_format2_minus3, bref, (uint8_t)0u, (uint8_t)1u)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(bref.unpack(start_bit_of_format2_minus3_sul_present, 1)); + if (start_bit_of_format2_minus3_sul_present) { + HANDLE_CODE(unpack_integer(start_bit_of_format2_minus3_sul, bref, (uint8_t)1u, (uint8_t)31u)); + } + } + } return SRSASN_SUCCESS; } -void freq_prio_eutra_s::to_json(json_writer& j) const +void srs_tpc_cmd_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("carrierFreq", carrier_freq); - j.write_int("cellReselectionPriority", cell_resel_prio); - if (cell_resel_sub_prio_present) { - j.write_str("cellReselectionSubPriority", cell_resel_sub_prio.to_string()); + if (start_bit_of_format2_minus3_present) { + j.write_int("startingBitOfFormat2-3", start_bit_of_format2_minus3); + } + if (field_type_format2_minus3_present) { + j.write_int("fieldTypeFormat2-3", field_type_format2_minus3); + } + if (ext) { + if (start_bit_of_format2_minus3_sul_present) { + j.write_int("startingBitOfFormat2-3SUL", start_bit_of_format2_minus3_sul); + } } j.end_obj(); } -// FreqPriorityNR ::= SEQUENCE -SRSASN_CODE freq_prio_nr_s::pack(bit_ref& bref) const +// TCI-State ::= SEQUENCE +SRSASN_CODE tci_state_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(cell_resel_sub_prio_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(qcl_type2_present, 1)); - HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)3279165u)); - HANDLE_CODE(pack_integer(bref, cell_resel_prio, (uint8_t)0u, (uint8_t)7u)); - if (cell_resel_sub_prio_present) { - HANDLE_CODE(cell_resel_sub_prio.pack(bref)); + HANDLE_CODE(pack_integer(bref, tci_state_id, (uint8_t)0u, (uint8_t)127u)); + HANDLE_CODE(qcl_type1.pack(bref)); + if (qcl_type2_present) { + HANDLE_CODE(qcl_type2.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE freq_prio_nr_s::unpack(cbit_ref& bref) +SRSASN_CODE tci_state_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(cell_resel_sub_prio_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(qcl_type2_present, 1)); - HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); - HANDLE_CODE(unpack_integer(cell_resel_prio, bref, (uint8_t)0u, (uint8_t)7u)); - if (cell_resel_sub_prio_present) { - HANDLE_CODE(cell_resel_sub_prio.unpack(bref)); + HANDLE_CODE(unpack_integer(tci_state_id, bref, (uint8_t)0u, (uint8_t)127u)); + HANDLE_CODE(qcl_type1.unpack(bref)); + if (qcl_type2_present) { + HANDLE_CODE(qcl_type2.unpack(bref)); } return SRSASN_SUCCESS; } -void freq_prio_nr_s::to_json(json_writer& j) const +void tci_state_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("carrierFreq", carrier_freq); - j.write_int("cellReselectionPriority", cell_resel_prio); - if (cell_resel_sub_prio_present) { - j.write_str("cellReselectionSubPriority", cell_resel_sub_prio.to_string()); + j.write_int("tci-StateId", tci_state_id); + j.write_fieldname("qcl-Type1"); + qcl_type1.to_json(j); + if (qcl_type2_present) { + j.write_fieldname("qcl-Type2"); + qcl_type2.to_json(j); } j.end_obj(); } -// GapConfig ::= SEQUENCE -SRSASN_CODE gap_cfg_s::pack(bit_ref& bref) const +// ZP-CSI-RS-Resource ::= SEQUENCE +SRSASN_CODE zp_csi_rs_res_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, gap_offset, (uint8_t)0u, (uint8_t)159u)); - HANDLE_CODE(mgl.pack(bref)); - HANDLE_CODE(mgrp.pack(bref)); - HANDLE_CODE(mgta.pack(bref)); + HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); + + HANDLE_CODE(pack_integer(bref, zp_csi_rs_res_id, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(res_map.pack(bref)); + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE gap_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE zp_csi_rs_res_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(gap_offset, bref, (uint8_t)0u, (uint8_t)159u)); - HANDLE_CODE(mgl.unpack(bref)); - HANDLE_CODE(mgrp.unpack(bref)); - HANDLE_CODE(mgta.unpack(bref)); + HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); + + HANDLE_CODE(unpack_integer(zp_csi_rs_res_id, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(res_map.unpack(bref)); + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.unpack(bref)); + } return SRSASN_SUCCESS; } -void gap_cfg_s::to_json(json_writer& j) const +void zp_csi_rs_res_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("gapOffset", gap_offset); - j.write_str("mgl", mgl.to_string()); - j.write_str("mgrp", mgrp.to_string()); - j.write_str("mgta", mgta.to_string()); + j.write_int("zp-CSI-RS-ResourceId", zp_csi_rs_res_id); + j.write_fieldname("resourceMapping"); + res_map.to_json(j); + if (periodicity_and_offset_present) { + j.write_fieldname("periodicityAndOffset"); + periodicity_and_offset.to_json(j); + } j.end_obj(); } -std::string gap_cfg_s::mgl_opts::to_string() const -{ - static const char* options[] = {"ms1dot5", "ms3", "ms3dot5", "ms4", "ms5dot5", "ms6"}; - return convert_enum_idx(options, 6, value, "gap_cfg_s::mgl_e_"); -} -float gap_cfg_s::mgl_opts::to_number() const -{ - static const float options[] = {1.5, 3.0, 3.5, 4.0, 5.5, 6.0}; - return map_enum_number(options, 6, value, "gap_cfg_s::mgl_e_"); -} -std::string gap_cfg_s::mgl_opts::to_number_string() const -{ - static const char* options[] = {"1.5", "3", "3.5", "4", "5.5", "6"}; - return convert_enum_idx(options, 6, value, "gap_cfg_s::mgl_e_"); -} - -std::string gap_cfg_s::mgrp_opts::to_string() const -{ - static const char* options[] = {"ms20", "ms40", "ms80", "ms160"}; - return convert_enum_idx(options, 4, value, "gap_cfg_s::mgrp_e_"); -} -uint8_t gap_cfg_s::mgrp_opts::to_number() const -{ - static const uint8_t options[] = {20, 40, 80, 160}; - return map_enum_number(options, 4, value, "gap_cfg_s::mgrp_e_"); -} - -std::string gap_cfg_s::mgta_opts::to_string() const -{ - static const char* options[] = {"ms0", "ms0dot25", "ms0dot5"}; - return convert_enum_idx(options, 3, value, "gap_cfg_s::mgta_e_"); -} -float gap_cfg_s::mgta_opts::to_number() const -{ - static const float options[] = {0.0, 0.25, 0.5}; - return map_enum_number(options, 3, value, "gap_cfg_s::mgta_e_"); -} -std::string gap_cfg_s::mgta_opts::to_number_string() const -{ - static const char* options[] = {"0", "0.25", "0.5"}; - return convert_enum_idx(options, 3, value, "gap_cfg_s::mgta_e_"); -} - -// MeasGapSharingScheme ::= ENUMERATED -std::string meas_gap_sharing_scheme_opts::to_string() const -{ - static const char* options[] = {"scheme00", "scheme01", "scheme10", "scheme11"}; - return convert_enum_idx(options, 4, value, "meas_gap_sharing_scheme_e"); -} -float meas_gap_sharing_scheme_opts::to_number() const -{ - static const float options[] = {0.0, 0.1, 1.0, 1.1}; - return map_enum_number(options, 4, value, "meas_gap_sharing_scheme_e"); -} -std::string meas_gap_sharing_scheme_opts::to_number_string() const -{ - static const char* options[] = {"0.0", "0.1", "1.0", "1.1"}; - return convert_enum_idx(options, 4, value, "meas_gap_sharing_scheme_e"); -} - -// MeasIdToAddMod ::= SEQUENCE -SRSASN_CODE meas_id_to_add_mod_s::pack(bit_ref& bref) const +// ZP-CSI-RS-ResourceSet ::= SEQUENCE +SRSASN_CODE zp_csi_rs_res_set_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, meas_id, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_integer(bref, meas_obj_id, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)1u, (uint8_t)64u)); + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, zp_csi_rs_res_set_id, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(pack_dyn_seq_of(bref, zp_csi_rs_res_id_list, 1, 16, integer_packer(0, 31))); return SRSASN_SUCCESS; } -SRSASN_CODE meas_id_to_add_mod_s::unpack(cbit_ref& bref) +SRSASN_CODE zp_csi_rs_res_set_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(meas_id, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_integer(meas_obj_id, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)1u, (uint8_t)64u)); + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(zp_csi_rs_res_set_id, bref, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(unpack_dyn_seq_of(zp_csi_rs_res_id_list, bref, 1, 16, integer_packer(0, 31))); return SRSASN_SUCCESS; } -void meas_id_to_add_mod_s::to_json(json_writer& j) const +void zp_csi_rs_res_set_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("measId", meas_id); - j.write_int("measObjectId", meas_obj_id); - j.write_int("reportConfigId", report_cfg_id); + j.write_int("zp-CSI-RS-ResourceSetId", zp_csi_rs_res_set_id); + j.start_array("zp-CSI-RS-ResourceIdList"); + for (const auto& e1 : zp_csi_rs_res_id_list) { + j.write_int(e1); + } + j.end_array(); j.end_obj(); } -// MeasObjectToAddMod ::= SEQUENCE -SRSASN_CODE meas_obj_to_add_mod_s::pack(bit_ref& bref) const +// PDCCH-Config ::= SEQUENCE +SRSASN_CODE pdcch_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, meas_obj_id, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(meas_obj.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(ctrl_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(ctrl_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(search_spaces_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(search_spaces_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(dl_preemption_present, 1)); + HANDLE_CODE(bref.pack(tpc_pusch_present, 1)); + HANDLE_CODE(bref.pack(tpc_pucch_present, 1)); + HANDLE_CODE(bref.pack(tpc_srs_present, 1)); + + if (ctrl_res_set_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ctrl_res_set_to_add_mod_list, 1, 3)); + } + if (ctrl_res_set_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ctrl_res_set_to_release_list, 1, 3, integer_packer(0, 11))); + } + if (search_spaces_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, search_spaces_to_add_mod_list, 1, 10)); + } + if (search_spaces_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, search_spaces_to_release_list, 1, 10, integer_packer(0, 39))); + } + if (dl_preemption_present) { + HANDLE_CODE(dl_preemption.pack(bref)); + } + if (tpc_pusch_present) { + HANDLE_CODE(tpc_pusch.pack(bref)); + } + if (tpc_pucch_present) { + HANDLE_CODE(tpc_pucch.pack(bref)); + } + if (tpc_srs_present) { + HANDLE_CODE(tpc_srs.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE meas_obj_to_add_mod_s::unpack(cbit_ref& bref) +SRSASN_CODE pdcch_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(meas_obj_id, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(meas_obj.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(ctrl_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(ctrl_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(search_spaces_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(search_spaces_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(dl_preemption_present, 1)); + HANDLE_CODE(bref.unpack(tpc_pusch_present, 1)); + HANDLE_CODE(bref.unpack(tpc_pucch_present, 1)); + HANDLE_CODE(bref.unpack(tpc_srs_present, 1)); + + if (ctrl_res_set_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ctrl_res_set_to_add_mod_list, bref, 1, 3)); + } + if (ctrl_res_set_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ctrl_res_set_to_release_list, bref, 1, 3, integer_packer(0, 11))); + } + if (search_spaces_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(search_spaces_to_add_mod_list, bref, 1, 10)); + } + if (search_spaces_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(search_spaces_to_release_list, bref, 1, 10, integer_packer(0, 39))); + } + if (dl_preemption_present) { + HANDLE_CODE(dl_preemption.unpack(bref)); + } + if (tpc_pusch_present) { + HANDLE_CODE(tpc_pusch.unpack(bref)); + } + if (tpc_pucch_present) { + HANDLE_CODE(tpc_pucch.unpack(bref)); + } + if (tpc_srs_present) { + HANDLE_CODE(tpc_srs.unpack(bref)); + } return SRSASN_SUCCESS; } -void meas_obj_to_add_mod_s::to_json(json_writer& j) const +void pdcch_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("measObjectId", meas_obj_id); - j.write_fieldname("measObject"); - meas_obj.to_json(j); + if (ctrl_res_set_to_add_mod_list_present) { + j.start_array("controlResourceSetToAddModList"); + for (const auto& e1 : ctrl_res_set_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (ctrl_res_set_to_release_list_present) { + j.start_array("controlResourceSetToReleaseList"); + for (const auto& e1 : ctrl_res_set_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (search_spaces_to_add_mod_list_present) { + j.start_array("searchSpacesToAddModList"); + for (const auto& e1 : search_spaces_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (search_spaces_to_release_list_present) { + j.start_array("searchSpacesToReleaseList"); + for (const auto& e1 : search_spaces_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (dl_preemption_present) { + j.write_fieldname("downlinkPreemption"); + dl_preemption.to_json(j); + } + if (tpc_pusch_present) { + j.write_fieldname("tpc-PUSCH"); + tpc_pusch.to_json(j); + } + if (tpc_pucch_present) { + j.write_fieldname("tpc-PUCCH"); + tpc_pucch.to_json(j); + } + if (tpc_srs_present) { + j.write_fieldname("tpc-SRS"); + tpc_srs.to_json(j); + } j.end_obj(); } -void meas_obj_to_add_mod_s::meas_obj_c_::destroy_() +// PDSCH-Config ::= SEQUENCE +SRSASN_CODE pdsch_cfg_s::pack(bit_ref& bref) const { - switch (type_) { - case types::meas_obj_nr: - c.destroy(); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(data_scrambling_id_pdsch_present, 1)); + HANDLE_CODE(bref.pack(dmrs_dl_for_pdsch_map_type_a_present, 1)); + HANDLE_CODE(bref.pack(dmrs_dl_for_pdsch_map_type_b_present, 1)); + HANDLE_CODE(bref.pack(tci_states_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(tci_states_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(vrb_to_prb_interleaver_present, 1)); + HANDLE_CODE(bref.pack(pdsch_time_domain_alloc_list_present, 1)); + HANDLE_CODE(bref.pack(pdsch_aggregation_factor_present, 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_group1_present, 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_group2_present, 1)); + HANDLE_CODE(bref.pack(mcs_table_present, 1)); + HANDLE_CODE(bref.pack(max_nrof_code_words_sched_by_dci_present, 1)); + HANDLE_CODE(bref.pack(zp_csi_rs_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(zp_csi_rs_res_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(aperiodic_zp_csi_rs_res_sets_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(sp_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(sp_zp_csi_rs_res_sets_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(p_zp_csi_rs_res_set_present, 1)); + + if (data_scrambling_id_pdsch_present) { + HANDLE_CODE(pack_integer(bref, data_scrambling_id_pdsch, (uint16_t)0u, (uint16_t)1023u)); + } + if (dmrs_dl_for_pdsch_map_type_a_present) { + HANDLE_CODE(dmrs_dl_for_pdsch_map_type_a.pack(bref)); + } + if (dmrs_dl_for_pdsch_map_type_b_present) { + HANDLE_CODE(dmrs_dl_for_pdsch_map_type_b.pack(bref)); + } + if (tci_states_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, tci_states_to_add_mod_list, 1, 128)); + } + if (tci_states_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, tci_states_to_release_list, 1, 128, integer_packer(0, 127))); + } + if (vrb_to_prb_interleaver_present) { + HANDLE_CODE(vrb_to_prb_interleaver.pack(bref)); + } + HANDLE_CODE(res_alloc.pack(bref)); + if (pdsch_time_domain_alloc_list_present) { + HANDLE_CODE(pdsch_time_domain_alloc_list.pack(bref)); + } + if (pdsch_aggregation_factor_present) { + HANDLE_CODE(pdsch_aggregation_factor.pack(bref)); + } + if (rate_match_pattern_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_add_mod_list, 1, 4)); + } + if (rate_match_pattern_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_release_list, 1, 4, integer_packer(0, 3))); + } + if (rate_match_pattern_group1_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_group1, 1, 8)); + } + if (rate_match_pattern_group2_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_group2, 1, 8)); + } + HANDLE_CODE(rbg_size.pack(bref)); + if (mcs_table_present) { + HANDLE_CODE(mcs_table.pack(bref)); + } + if (max_nrof_code_words_sched_by_dci_present) { + HANDLE_CODE(max_nrof_code_words_sched_by_dci.pack(bref)); + } + HANDLE_CODE(prb_bundling_type.pack(bref)); + if (zp_csi_rs_res_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, zp_csi_rs_res_to_add_mod_list, 1, 32)); + } + if (zp_csi_rs_res_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, zp_csi_rs_res_to_release_list, 1, 32, integer_packer(0, 31))); + } + if (aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, aperiodic_zp_csi_rs_res_sets_to_add_mod_list, 1, 16)); + } + if (aperiodic_zp_csi_rs_res_sets_to_release_list_present) { + HANDLE_CODE( + pack_dyn_seq_of(bref, aperiodic_zp_csi_rs_res_sets_to_release_list, 1, 16, integer_packer(0, 15))); + } + if (sp_zp_csi_rs_res_sets_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sp_zp_csi_rs_res_sets_to_add_mod_list, 1, 16)); + } + if (sp_zp_csi_rs_res_sets_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sp_zp_csi_rs_res_sets_to_release_list, 1, 16, integer_packer(0, 15))); + } + if (p_zp_csi_rs_res_set_present) { + HANDLE_CODE(p_zp_csi_rs_res_set.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE pdsch_cfg_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(data_scrambling_id_pdsch_present, 1)); + HANDLE_CODE(bref.unpack(dmrs_dl_for_pdsch_map_type_a_present, 1)); + HANDLE_CODE(bref.unpack(dmrs_dl_for_pdsch_map_type_b_present, 1)); + HANDLE_CODE(bref.unpack(tci_states_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(tci_states_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(vrb_to_prb_interleaver_present, 1)); + HANDLE_CODE(bref.unpack(pdsch_time_domain_alloc_list_present, 1)); + HANDLE_CODE(bref.unpack(pdsch_aggregation_factor_present, 1)); + HANDLE_CODE(bref.unpack(rate_match_pattern_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(rate_match_pattern_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(rate_match_pattern_group1_present, 1)); + HANDLE_CODE(bref.unpack(rate_match_pattern_group2_present, 1)); + HANDLE_CODE(bref.unpack(mcs_table_present, 1)); + HANDLE_CODE(bref.unpack(max_nrof_code_words_sched_by_dci_present, 1)); + HANDLE_CODE(bref.unpack(zp_csi_rs_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(zp_csi_rs_res_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(aperiodic_zp_csi_rs_res_sets_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(sp_zp_csi_rs_res_sets_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(sp_zp_csi_rs_res_sets_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(p_zp_csi_rs_res_set_present, 1)); + + if (data_scrambling_id_pdsch_present) { + HANDLE_CODE(unpack_integer(data_scrambling_id_pdsch, bref, (uint16_t)0u, (uint16_t)1023u)); + } + if (dmrs_dl_for_pdsch_map_type_a_present) { + HANDLE_CODE(dmrs_dl_for_pdsch_map_type_a.unpack(bref)); + } + if (dmrs_dl_for_pdsch_map_type_b_present) { + HANDLE_CODE(dmrs_dl_for_pdsch_map_type_b.unpack(bref)); + } + if (tci_states_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(tci_states_to_add_mod_list, bref, 1, 128)); + } + if (tci_states_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(tci_states_to_release_list, bref, 1, 128, integer_packer(0, 127))); + } + if (vrb_to_prb_interleaver_present) { + HANDLE_CODE(vrb_to_prb_interleaver.unpack(bref)); + } + HANDLE_CODE(res_alloc.unpack(bref)); + if (pdsch_time_domain_alloc_list_present) { + HANDLE_CODE(pdsch_time_domain_alloc_list.unpack(bref)); + } + if (pdsch_aggregation_factor_present) { + HANDLE_CODE(pdsch_aggregation_factor.unpack(bref)); + } + if (rate_match_pattern_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_add_mod_list, bref, 1, 4)); + } + if (rate_match_pattern_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_release_list, bref, 1, 4, integer_packer(0, 3))); + } + if (rate_match_pattern_group1_present) { + HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_group1, bref, 1, 8)); + } + if (rate_match_pattern_group2_present) { + HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_group2, bref, 1, 8)); + } + HANDLE_CODE(rbg_size.unpack(bref)); + if (mcs_table_present) { + HANDLE_CODE(mcs_table.unpack(bref)); + } + if (max_nrof_code_words_sched_by_dci_present) { + HANDLE_CODE(max_nrof_code_words_sched_by_dci.unpack(bref)); + } + HANDLE_CODE(prb_bundling_type.unpack(bref)); + if (zp_csi_rs_res_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(zp_csi_rs_res_to_add_mod_list, bref, 1, 32)); + } + if (zp_csi_rs_res_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(zp_csi_rs_res_to_release_list, bref, 1, 32, integer_packer(0, 31))); + } + if (aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(aperiodic_zp_csi_rs_res_sets_to_add_mod_list, bref, 1, 16)); + } + if (aperiodic_zp_csi_rs_res_sets_to_release_list_present) { + HANDLE_CODE( + unpack_dyn_seq_of(aperiodic_zp_csi_rs_res_sets_to_release_list, bref, 1, 16, integer_packer(0, 15))); + } + if (sp_zp_csi_rs_res_sets_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sp_zp_csi_rs_res_sets_to_add_mod_list, bref, 1, 16)); + } + if (sp_zp_csi_rs_res_sets_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sp_zp_csi_rs_res_sets_to_release_list, bref, 1, 16, integer_packer(0, 15))); + } + if (p_zp_csi_rs_res_set_present) { + HANDLE_CODE(p_zp_csi_rs_res_set.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void pdsch_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (data_scrambling_id_pdsch_present) { + j.write_int("dataScramblingIdentityPDSCH", data_scrambling_id_pdsch); + } + if (dmrs_dl_for_pdsch_map_type_a_present) { + j.write_fieldname("dmrs-DownlinkForPDSCH-MappingTypeA"); + dmrs_dl_for_pdsch_map_type_a.to_json(j); + } + if (dmrs_dl_for_pdsch_map_type_b_present) { + j.write_fieldname("dmrs-DownlinkForPDSCH-MappingTypeB"); + dmrs_dl_for_pdsch_map_type_b.to_json(j); + } + if (tci_states_to_add_mod_list_present) { + j.start_array("tci-StatesToAddModList"); + for (const auto& e1 : tci_states_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (tci_states_to_release_list_present) { + j.start_array("tci-StatesToReleaseList"); + for (const auto& e1 : tci_states_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (vrb_to_prb_interleaver_present) { + j.write_str("vrb-ToPRB-Interleaver", vrb_to_prb_interleaver.to_string()); + } + j.write_str("resourceAllocation", res_alloc.to_string()); + if (pdsch_time_domain_alloc_list_present) { + j.write_fieldname("pdsch-TimeDomainAllocationList"); + pdsch_time_domain_alloc_list.to_json(j); + } + if (pdsch_aggregation_factor_present) { + j.write_str("pdsch-AggregationFactor", pdsch_aggregation_factor.to_string()); + } + if (rate_match_pattern_to_add_mod_list_present) { + j.start_array("rateMatchPatternToAddModList"); + for (const auto& e1 : rate_match_pattern_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (rate_match_pattern_to_release_list_present) { + j.start_array("rateMatchPatternToReleaseList"); + for (const auto& e1 : rate_match_pattern_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (rate_match_pattern_group1_present) { + j.start_array("rateMatchPatternGroup1"); + for (const auto& e1 : rate_match_pattern_group1) { + e1.to_json(j); + } + j.end_array(); + } + if (rate_match_pattern_group2_present) { + j.start_array("rateMatchPatternGroup2"); + for (const auto& e1 : rate_match_pattern_group2) { + e1.to_json(j); + } + j.end_array(); + } + j.write_str("rbg-Size", rbg_size.to_string()); + if (mcs_table_present) { + j.write_str("mcs-Table", mcs_table.to_string()); + } + if (max_nrof_code_words_sched_by_dci_present) { + j.write_str("maxNrofCodeWordsScheduledByDCI", max_nrof_code_words_sched_by_dci.to_string()); + } + j.write_fieldname("prb-BundlingType"); + prb_bundling_type.to_json(j); + if (zp_csi_rs_res_to_add_mod_list_present) { + j.start_array("zp-CSI-RS-ResourceToAddModList"); + for (const auto& e1 : zp_csi_rs_res_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (zp_csi_rs_res_to_release_list_present) { + j.start_array("zp-CSI-RS-ResourceToReleaseList"); + for (const auto& e1 : zp_csi_rs_res_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (aperiodic_zp_csi_rs_res_sets_to_add_mod_list_present) { + j.start_array("aperiodic-ZP-CSI-RS-ResourceSetsToAddModList"); + for (const auto& e1 : aperiodic_zp_csi_rs_res_sets_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (aperiodic_zp_csi_rs_res_sets_to_release_list_present) { + j.start_array("aperiodic-ZP-CSI-RS-ResourceSetsToReleaseList"); + for (const auto& e1 : aperiodic_zp_csi_rs_res_sets_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (sp_zp_csi_rs_res_sets_to_add_mod_list_present) { + j.start_array("sp-ZP-CSI-RS-ResourceSetsToAddModList"); + for (const auto& e1 : sp_zp_csi_rs_res_sets_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (sp_zp_csi_rs_res_sets_to_release_list_present) { + j.start_array("sp-ZP-CSI-RS-ResourceSetsToReleaseList"); + for (const auto& e1 : sp_zp_csi_rs_res_sets_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (p_zp_csi_rs_res_set_present) { + j.write_fieldname("p-ZP-CSI-RS-ResourceSet"); + p_zp_csi_rs_res_set.to_json(j); + } + j.end_obj(); +} + +std::string pdsch_cfg_s::vrb_to_prb_interleaver_opts::to_string() const +{ + static const char* options[] = {"n2", "n4"}; + return convert_enum_idx(options, 2, value, "pdsch_cfg_s::vrb_to_prb_interleaver_e_"); +} +uint8_t pdsch_cfg_s::vrb_to_prb_interleaver_opts::to_number() const +{ + static const uint8_t options[] = {2, 4}; + return map_enum_number(options, 2, value, "pdsch_cfg_s::vrb_to_prb_interleaver_e_"); +} + +std::string pdsch_cfg_s::res_alloc_opts::to_string() const +{ + static const char* options[] = {"resourceAllocationType0", "resourceAllocationType1", "dynamicSwitch"}; + return convert_enum_idx(options, 3, value, "pdsch_cfg_s::res_alloc_e_"); +} +uint8_t pdsch_cfg_s::res_alloc_opts::to_number() const +{ + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "pdsch_cfg_s::res_alloc_e_"); +} + +std::string pdsch_cfg_s::pdsch_aggregation_factor_opts::to_string() const +{ + static const char* options[] = {"n2", "n4", "n8"}; + return convert_enum_idx(options, 3, value, "pdsch_cfg_s::pdsch_aggregation_factor_e_"); +} +uint8_t pdsch_cfg_s::pdsch_aggregation_factor_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 8}; + return map_enum_number(options, 3, value, "pdsch_cfg_s::pdsch_aggregation_factor_e_"); +} + +std::string pdsch_cfg_s::rbg_size_opts::to_string() const +{ + static const char* options[] = {"config1", "config2"}; + return convert_enum_idx(options, 2, value, "pdsch_cfg_s::rbg_size_e_"); +} +uint8_t pdsch_cfg_s::rbg_size_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "pdsch_cfg_s::rbg_size_e_"); +} + +std::string pdsch_cfg_s::mcs_table_opts::to_string() const +{ + static const char* options[] = {"qam256", "qam64LowSE"}; + return convert_enum_idx(options, 2, value, "pdsch_cfg_s::mcs_table_e_"); +} +uint16_t pdsch_cfg_s::mcs_table_opts::to_number() const +{ + static const uint16_t options[] = {256, 64}; + return map_enum_number(options, 2, value, "pdsch_cfg_s::mcs_table_e_"); +} + +std::string pdsch_cfg_s::max_nrof_code_words_sched_by_dci_opts::to_string() const +{ + static const char* options[] = {"n1", "n2"}; + return convert_enum_idx(options, 2, value, "pdsch_cfg_s::max_nrof_code_words_sched_by_dci_e_"); +} +uint8_t pdsch_cfg_s::max_nrof_code_words_sched_by_dci_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "pdsch_cfg_s::max_nrof_code_words_sched_by_dci_e_"); +} + +void pdsch_cfg_s::prb_bundling_type_c_::destroy_() +{ + switch (type_) { + case types::static_bundling: + c.destroy(); break; - case types::meas_obj_eutra: - c.destroy(); + case types::dynamic_bundling: + c.destroy(); break; default: break; } } -void meas_obj_to_add_mod_s::meas_obj_c_::set(types::options e) +void pdsch_cfg_s::prb_bundling_type_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::meas_obj_nr: - c.init(); + case types::static_bundling: + c.init(); break; - case types::meas_obj_eutra: - c.init(); + case types::dynamic_bundling: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); + log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); } } -meas_obj_to_add_mod_s::meas_obj_c_::meas_obj_c_(const meas_obj_to_add_mod_s::meas_obj_c_& other) +pdsch_cfg_s::prb_bundling_type_c_::prb_bundling_type_c_(const pdsch_cfg_s::prb_bundling_type_c_& other) { type_ = other.type(); switch (type_) { - case types::meas_obj_nr: - c.init(other.c.get()); + case types::static_bundling: + c.init(other.c.get()); break; - case types::meas_obj_eutra: - c.init(other.c.get()); + case types::dynamic_bundling: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); + log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); } } -meas_obj_to_add_mod_s::meas_obj_c_& meas_obj_to_add_mod_s::meas_obj_c_:: - operator=(const meas_obj_to_add_mod_s::meas_obj_c_& other) +pdsch_cfg_s::prb_bundling_type_c_& +pdsch_cfg_s::prb_bundling_type_c_::operator=(const pdsch_cfg_s::prb_bundling_type_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::meas_obj_nr: - c.set(other.c.get()); + case types::static_bundling: + c.set(other.c.get()); break; - case types::meas_obj_eutra: - c.set(other.c.get()); + case types::dynamic_bundling: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); + log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); } return *this; } -void meas_obj_to_add_mod_s::meas_obj_c_::to_json(json_writer& j) const +void pdsch_cfg_s::prb_bundling_type_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::meas_obj_nr: - j.write_fieldname("measObjectNR"); - c.get().to_json(j); + case types::static_bundling: + j.write_fieldname("staticBundling"); + j.start_obj(); + if (c.get().bundle_size_present) { + j.write_str("bundleSize", c.get().bundle_size.to_string()); + } + j.end_obj(); break; - case types::meas_obj_eutra: - j.write_fieldname("measObjectEUTRA"); - c.get().to_json(j); + case types::dynamic_bundling: + j.write_fieldname("dynamicBundling"); + j.start_obj(); + if (c.get().bundle_size_set1_present) { + j.write_str("bundleSizeSet1", c.get().bundle_size_set1.to_string()); + } + if (c.get().bundle_size_set2_present) { + j.write_str("bundleSizeSet2", c.get().bundle_size_set2.to_string()); + } + j.end_obj(); break; default: - log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); + log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); } j.end_obj(); } -SRSASN_CODE meas_obj_to_add_mod_s::meas_obj_c_::pack(bit_ref& bref) const +SRSASN_CODE pdsch_cfg_s::prb_bundling_type_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::meas_obj_nr: - HANDLE_CODE(c.get().pack(bref)); + case types::static_bundling: + HANDLE_CODE(bref.pack(c.get().bundle_size_present, 1)); + if (c.get().bundle_size_present) { + HANDLE_CODE(c.get().bundle_size.pack(bref)); + } + break; + case types::dynamic_bundling: + HANDLE_CODE(bref.pack(c.get().bundle_size_set1_present, 1)); + HANDLE_CODE(bref.pack(c.get().bundle_size_set2_present, 1)); + if (c.get().bundle_size_set1_present) { + HANDLE_CODE(c.get().bundle_size_set1.pack(bref)); + } + if (c.get().bundle_size_set2_present) { + HANDLE_CODE(c.get().bundle_size_set2.pack(bref)); + } break; - case types::meas_obj_eutra: { - varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get().pack(bref)); - } break; default: - log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); + log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE meas_obj_to_add_mod_s::meas_obj_c_::unpack(cbit_ref& bref) +SRSASN_CODE pdsch_cfg_s::prb_bundling_type_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::meas_obj_nr: - HANDLE_CODE(c.get().unpack(bref)); + case types::static_bundling: + HANDLE_CODE(bref.unpack(c.get().bundle_size_present, 1)); + if (c.get().bundle_size_present) { + HANDLE_CODE(c.get().bundle_size.unpack(bref)); + } + break; + case types::dynamic_bundling: + HANDLE_CODE(bref.unpack(c.get().bundle_size_set1_present, 1)); + HANDLE_CODE(bref.unpack(c.get().bundle_size_set2_present, 1)); + if (c.get().bundle_size_set1_present) { + HANDLE_CODE(c.get().bundle_size_set1.unpack(bref)); + } + if (c.get().bundle_size_set2_present) { + HANDLE_CODE(c.get().bundle_size_set2.unpack(bref)); + } break; - case types::meas_obj_eutra: { - varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get().unpack(bref)); - } break; default: - log_invalid_choice_id(type_, "meas_obj_to_add_mod_s::meas_obj_c_"); + log_invalid_choice_id(type_, "pdsch_cfg_s::prb_bundling_type_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string meas_obj_to_add_mod_s::meas_obj_c_::types_opts::to_string() const +std::string pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_opts::to_string() const { - static const char* options[] = {"measObjectNR", "measObjectEUTRA"}; - return convert_enum_idx(options, 2, value, "meas_obj_to_add_mod_s::meas_obj_c_::types"); + static const char* options[] = {"n4", "wideband"}; + return convert_enum_idx(options, 2, value, "pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_e_"); } - -// OtherConfig-v1540 ::= SEQUENCE -SRSASN_CODE other_cfg_v1540_s::pack(bit_ref& bref) const +uint8_t pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_opts::to_number() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(overheat_assist_cfg_present, 1)); - - if (overheat_assist_cfg_present) { - HANDLE_CODE(overheat_assist_cfg.pack(bref)); - } - - return SRSASN_SUCCESS; + static const uint8_t options[] = {4}; + return map_enum_number(options, 1, value, "pdsch_cfg_s::prb_bundling_type_c_::static_bundling_s_::bundle_size_e_"); } -SRSASN_CODE other_cfg_v1540_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(overheat_assist_cfg_present, 1)); - - if (overheat_assist_cfg_present) { - HANDLE_CODE(overheat_assist_cfg.unpack(bref)); - } - return SRSASN_SUCCESS; -} -void other_cfg_v1540_s::to_json(json_writer& j) const +std::string pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set1_opts::to_string() const { - j.start_obj(); - if (overheat_assist_cfg_present) { - j.write_fieldname("overheatingAssistanceConfig"); - overheat_assist_cfg.to_json(j); - } - j.end_obj(); + static const char* options[] = {"n4", "wideband", "n2-wideband", "n4-wideband"}; + return convert_enum_idx( + options, 4, value, "pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set1_e_"); } -// QuantityConfigNR ::= SEQUENCE -SRSASN_CODE quant_cfg_nr_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(quant_cfg_rs_idx_present, 1)); - - HANDLE_CODE(quant_cfg_cell.pack(bref)); - if (quant_cfg_rs_idx_present) { - HANDLE_CODE(quant_cfg_rs_idx.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE quant_cfg_nr_s::unpack(cbit_ref& bref) +std::string pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_opts::to_string() const { - HANDLE_CODE(bref.unpack(quant_cfg_rs_idx_present, 1)); - - HANDLE_CODE(quant_cfg_cell.unpack(bref)); - if (quant_cfg_rs_idx_present) { - HANDLE_CODE(quant_cfg_rs_idx.unpack(bref)); - } - - return SRSASN_SUCCESS; + static const char* options[] = {"n4", "wideband"}; + return convert_enum_idx( + options, 2, value, "pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_e_"); } -void quant_cfg_nr_s::to_json(json_writer& j) const +uint8_t pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_opts::to_number() const { - j.start_obj(); - j.write_fieldname("quantityConfigCell"); - quant_cfg_cell.to_json(j); - if (quant_cfg_rs_idx_present) { - j.write_fieldname("quantityConfigRS-Index"); - quant_cfg_rs_idx.to_json(j); - } - j.end_obj(); + static const uint8_t options[] = {4}; + return map_enum_number( + options, 1, value, "pdsch_cfg_s::prb_bundling_type_c_::dynamic_bundling_s_::bundle_size_set2_e_"); } -// RAT-Type ::= ENUMERATED -std::string rat_type_opts::to_string() const +std::string pdsch_cfg_s::prb_bundling_type_c_::types_opts::to_string() const { - static const char* options[] = {"nr", "eutra-nr", "eutra", "spare1"}; - return convert_enum_idx(options, 4, value, "rat_type_e"); + static const char* options[] = {"staticBundling", "dynamicBundling"}; + return convert_enum_idx(options, 2, value, "pdsch_cfg_s::prb_bundling_type_c_::types"); } -// ReportConfigToAddMod ::= SEQUENCE -SRSASN_CODE report_cfg_to_add_mod_s::pack(bit_ref& bref) const +// RadioLinkMonitoringConfig ::= SEQUENCE +SRSASN_CODE radio_link_monitoring_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(report_cfg.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(fail_detection_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(fail_detection_res_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(beam_fail_instance_max_count_present, 1)); + HANDLE_CODE(bref.pack(beam_fail_detection_timer_present, 1)); - return SRSASN_SUCCESS; -} -SRSASN_CODE report_cfg_to_add_mod_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(report_cfg.unpack(bref)); + if (fail_detection_res_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, fail_detection_res_to_add_mod_list, 1, 10)); + } + if (fail_detection_res_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, fail_detection_res_to_release_list, 1, 10, integer_packer(0, 9))); + } + if (beam_fail_instance_max_count_present) { + HANDLE_CODE(beam_fail_instance_max_count.pack(bref)); + } + if (beam_fail_detection_timer_present) { + HANDLE_CODE(beam_fail_detection_timer.pack(bref)); + } return SRSASN_SUCCESS; } -void report_cfg_to_add_mod_s::to_json(json_writer& j) const +SRSASN_CODE radio_link_monitoring_cfg_s::unpack(cbit_ref& bref) { - j.start_obj(); - j.write_int("reportConfigId", report_cfg_id); - j.write_fieldname("reportConfig"); - report_cfg.to_json(j); - j.end_obj(); -} + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(fail_detection_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(fail_detection_res_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(beam_fail_instance_max_count_present, 1)); + HANDLE_CODE(bref.unpack(beam_fail_detection_timer_present, 1)); -void report_cfg_to_add_mod_s::report_cfg_c_::destroy_() -{ - switch (type_) { - case types::report_cfg_nr: - c.destroy(); - break; - case types::report_cfg_inter_rat: - c.destroy(); - break; - default: - break; - } -} -void report_cfg_to_add_mod_s::report_cfg_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::report_cfg_nr: - c.init(); - break; - case types::report_cfg_inter_rat: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); + if (fail_detection_res_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(fail_detection_res_to_add_mod_list, bref, 1, 10)); } -} -report_cfg_to_add_mod_s::report_cfg_c_::report_cfg_c_(const report_cfg_to_add_mod_s::report_cfg_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::report_cfg_nr: - c.init(other.c.get()); - break; - case types::report_cfg_inter_rat: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); + if (fail_detection_res_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(fail_detection_res_to_release_list, bref, 1, 10, integer_packer(0, 9))); } -} -report_cfg_to_add_mod_s::report_cfg_c_& report_cfg_to_add_mod_s::report_cfg_c_:: - operator=(const report_cfg_to_add_mod_s::report_cfg_c_& other) -{ - if (this == &other) { - return *this; + if (beam_fail_instance_max_count_present) { + HANDLE_CODE(beam_fail_instance_max_count.unpack(bref)); } - set(other.type()); - switch (type_) { - case types::report_cfg_nr: - c.set(other.c.get()); - break; - case types::report_cfg_inter_rat: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); + if (beam_fail_detection_timer_present) { + HANDLE_CODE(beam_fail_detection_timer.unpack(bref)); } - return *this; + return SRSASN_SUCCESS; } -void report_cfg_to_add_mod_s::report_cfg_c_::to_json(json_writer& j) const +void radio_link_monitoring_cfg_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::report_cfg_nr: - j.write_fieldname("reportConfigNR"); - c.get().to_json(j); - break; - case types::report_cfg_inter_rat: - j.write_fieldname("reportConfigInterRAT"); - c.get().to_json(j); - break; - default: - log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); + if (fail_detection_res_to_add_mod_list_present) { + j.start_array("failureDetectionResourcesToAddModList"); + for (const auto& e1 : fail_detection_res_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (fail_detection_res_to_release_list_present) { + j.start_array("failureDetectionResourcesToReleaseList"); + for (const auto& e1 : fail_detection_res_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (beam_fail_instance_max_count_present) { + j.write_str("beamFailureInstanceMaxCount", beam_fail_instance_max_count.to_string()); + } + if (beam_fail_detection_timer_present) { + j.write_str("beamFailureDetectionTimer", beam_fail_detection_timer.to_string()); } j.end_obj(); } -SRSASN_CODE report_cfg_to_add_mod_s::report_cfg_c_::pack(bit_ref& bref) const + +std::string radio_link_monitoring_cfg_s::beam_fail_instance_max_count_opts::to_string() const { - type_.pack(bref); - switch (type_) { - case types::report_cfg_nr: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::report_cfg_inter_rat: { - varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get().pack(bref)); - } break; - default: - log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"n1", "n2", "n3", "n4", "n5", "n6", "n8", "n10"}; + return convert_enum_idx(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_instance_max_count_e_"); } -SRSASN_CODE report_cfg_to_add_mod_s::report_cfg_c_::unpack(cbit_ref& bref) +uint8_t radio_link_monitoring_cfg_s::beam_fail_instance_max_count_opts::to_number() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::report_cfg_nr: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::report_cfg_inter_rat: { - varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(c.get().unpack(bref)); - } break; - default: - log_invalid_choice_id(type_, "report_cfg_to_add_mod_s::report_cfg_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const uint8_t options[] = {1, 2, 3, 4, 5, 6, 8, 10}; + return map_enum_number(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_instance_max_count_e_"); } -std::string report_cfg_to_add_mod_s::report_cfg_c_::types_opts::to_string() const +std::string radio_link_monitoring_cfg_s::beam_fail_detection_timer_opts::to_string() const { - static const char* options[] = {"reportConfigNR", "reportConfigInterRAT"}; - return convert_enum_idx(options, 2, value, "report_cfg_to_add_mod_s::report_cfg_c_::types"); + static const char* options[] = {"pbfd1", "pbfd2", "pbfd3", "pbfd4", "pbfd5", "pbfd6", "pbfd8", "pbfd10"}; + return convert_enum_idx(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_detection_timer_e_"); +} +uint8_t radio_link_monitoring_cfg_s::beam_fail_detection_timer_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 3, 4, 5, 6, 8, 10}; + return map_enum_number(options, 8, value, "radio_link_monitoring_cfg_s::beam_fail_detection_timer_e_"); } -// CarrierInfoNR ::= SEQUENCE -SRSASN_CODE carrier_info_nr_s::pack(bit_ref& bref) const +// SPS-Config ::= SEQUENCE +SRSASN_CODE sps_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(smtc_present, 1)); + HANDLE_CODE(bref.pack(n1_pucch_an_present, 1)); + HANDLE_CODE(bref.pack(mcs_table_present, 1)); - HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)3279165u)); - HANDLE_CODE(ssb_subcarrier_spacing.pack(bref)); - if (smtc_present) { - HANDLE_CODE(smtc.pack(bref)); + HANDLE_CODE(periodicity.pack(bref)); + HANDLE_CODE(pack_integer(bref, nrof_harq_processes, (uint8_t)1u, (uint8_t)8u)); + if (n1_pucch_an_present) { + HANDLE_CODE(pack_integer(bref, n1_pucch_an, (uint8_t)0u, (uint8_t)127u)); } return SRSASN_SUCCESS; } -SRSASN_CODE carrier_info_nr_s::unpack(cbit_ref& bref) +SRSASN_CODE sps_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(smtc_present, 1)); + HANDLE_CODE(bref.unpack(n1_pucch_an_present, 1)); + HANDLE_CODE(bref.unpack(mcs_table_present, 1)); - HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); - HANDLE_CODE(ssb_subcarrier_spacing.unpack(bref)); - if (smtc_present) { - HANDLE_CODE(smtc.unpack(bref)); + HANDLE_CODE(periodicity.unpack(bref)); + HANDLE_CODE(unpack_integer(nrof_harq_processes, bref, (uint8_t)1u, (uint8_t)8u)); + if (n1_pucch_an_present) { + HANDLE_CODE(unpack_integer(n1_pucch_an, bref, (uint8_t)0u, (uint8_t)127u)); } return SRSASN_SUCCESS; } -void carrier_info_nr_s::to_json(json_writer& j) const +void sps_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("carrierFreq", carrier_freq); - j.write_str("ssbSubcarrierSpacing", ssb_subcarrier_spacing.to_string()); - if (smtc_present) { - j.write_fieldname("smtc"); - smtc.to_json(j); + j.write_str("periodicity", periodicity.to_string()); + j.write_int("nrofHARQ-Processes", nrof_harq_processes); + if (n1_pucch_an_present) { + j.write_int("n1PUCCH-AN", n1_pucch_an); + } + if (mcs_table_present) { + j.write_str("mcs-Table", "qam64LowSE"); } j.end_obj(); } -// DRB-CountMSB-Info ::= SEQUENCE -SRSASN_CODE drb_count_msb_info_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, drb_id, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(pack_integer(bref, count_msb_ul, (uint32_t)0u, (uint32_t)33554431u)); - HANDLE_CODE(pack_integer(bref, count_msb_dl, (uint32_t)0u, (uint32_t)33554431u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE drb_count_msb_info_s::unpack(cbit_ref& bref) +std::string sps_cfg_s::periodicity_opts::to_string() const { - HANDLE_CODE(unpack_integer(drb_id, bref, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(unpack_integer(count_msb_ul, bref, (uint32_t)0u, (uint32_t)33554431u)); - HANDLE_CODE(unpack_integer(count_msb_dl, bref, (uint32_t)0u, (uint32_t)33554431u)); - - return SRSASN_SUCCESS; + static const char* options[] = {"ms10", + "ms20", + "ms32", + "ms40", + "ms64", + "ms80", + "ms128", + "ms160", + "ms320", + "ms640", + "spare6", + "spare5", + "spare4", + "spare3", + "spare2", + "spare1"}; + return convert_enum_idx(options, 16, value, "sps_cfg_s::periodicity_e_"); } -void drb_count_msb_info_s::to_json(json_writer& j) const +uint16_t sps_cfg_s::periodicity_opts::to_number() const { - j.start_obj(); - j.write_int("drb-Identity", drb_id); - j.write_int("countMSB-Uplink", count_msb_ul); - j.write_int("countMSB-Downlink", count_msb_dl); - j.end_obj(); + static const uint16_t options[] = {10, 20, 32, 40, 64, 80, 128, 160, 320, 640}; + return map_enum_number(options, 10, value, "sps_cfg_s::periodicity_e_"); } -// MasterKeyUpdate ::= SEQUENCE -SRSASN_CODE master_key_upd_s::pack(bit_ref& bref) const +// BWP-DownlinkDedicated ::= SEQUENCE +SRSASN_CODE bwp_dl_ded_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(nas_container_present, 1)); + HANDLE_CODE(bref.pack(pdcch_cfg_present, 1)); + HANDLE_CODE(bref.pack(pdsch_cfg_present, 1)); + HANDLE_CODE(bref.pack(sps_cfg_present, 1)); + HANDLE_CODE(bref.pack(radio_link_monitoring_cfg_present, 1)); - HANDLE_CODE(bref.pack(key_set_change_ind, 1)); - HANDLE_CODE(pack_integer(bref, next_hop_chaining_count, (uint8_t)0u, (uint8_t)7u)); - if (nas_container_present) { - HANDLE_CODE(nas_container.pack(bref)); + if (pdcch_cfg_present) { + HANDLE_CODE(pdcch_cfg.pack(bref)); + } + if (pdsch_cfg_present) { + HANDLE_CODE(pdsch_cfg.pack(bref)); + } + if (sps_cfg_present) { + HANDLE_CODE(sps_cfg.pack(bref)); + } + if (radio_link_monitoring_cfg_present) { + HANDLE_CODE(radio_link_monitoring_cfg.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE master_key_upd_s::unpack(cbit_ref& bref) +SRSASN_CODE bwp_dl_ded_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(nas_container_present, 1)); + HANDLE_CODE(bref.unpack(pdcch_cfg_present, 1)); + HANDLE_CODE(bref.unpack(pdsch_cfg_present, 1)); + HANDLE_CODE(bref.unpack(sps_cfg_present, 1)); + HANDLE_CODE(bref.unpack(radio_link_monitoring_cfg_present, 1)); - HANDLE_CODE(bref.unpack(key_set_change_ind, 1)); - HANDLE_CODE(unpack_integer(next_hop_chaining_count, bref, (uint8_t)0u, (uint8_t)7u)); - if (nas_container_present) { - HANDLE_CODE(nas_container.unpack(bref)); + if (pdcch_cfg_present) { + HANDLE_CODE(pdcch_cfg.unpack(bref)); + } + if (pdsch_cfg_present) { + HANDLE_CODE(pdsch_cfg.unpack(bref)); + } + if (sps_cfg_present) { + HANDLE_CODE(sps_cfg.unpack(bref)); + } + if (radio_link_monitoring_cfg_present) { + HANDLE_CODE(radio_link_monitoring_cfg.unpack(bref)); } return SRSASN_SUCCESS; } -void master_key_upd_s::to_json(json_writer& j) const +void bwp_dl_ded_s::to_json(json_writer& j) const { j.start_obj(); - j.write_bool("keySetChangeIndicator", key_set_change_ind); - j.write_int("nextHopChainingCount", next_hop_chaining_count); - if (nas_container_present) { - j.write_str("nas-Container", nas_container.to_string()); + if (pdcch_cfg_present) { + j.write_fieldname("pdcch-Config"); + pdcch_cfg.to_json(j); + } + if (pdsch_cfg_present) { + j.write_fieldname("pdsch-Config"); + pdsch_cfg.to_json(j); + } + if (sps_cfg_present) { + j.write_fieldname("sps-Config"); + sps_cfg.to_json(j); + } + if (radio_link_monitoring_cfg_present) { + j.write_fieldname("radioLinkMonitoringConfig"); + radio_link_monitoring_cfg.to_json(j); } j.end_obj(); } -// MeasGapConfig ::= SEQUENCE -SRSASN_CODE meas_gap_cfg_s::pack(bit_ref& bref) const +// BWP-Downlink ::= SEQUENCE +SRSASN_CODE bwp_dl_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(gap_fr2_present, 1)); + HANDLE_CODE(bref.pack(bwp_common_present, 1)); + HANDLE_CODE(bref.pack(bwp_ded_present, 1)); - if (gap_fr2_present) { - HANDLE_CODE(gap_fr2.pack(bref)); + HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); + if (bwp_common_present) { + HANDLE_CODE(bwp_common.pack(bref)); } - - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= gap_fr1.is_present(); - group_flags[0] |= gap_ue.is_present(); - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(gap_fr1.is_present(), 1)); - HANDLE_CODE(bref.pack(gap_ue.is_present(), 1)); - if (gap_fr1.is_present()) { - HANDLE_CODE(gap_fr1->pack(bref)); - } - if (gap_ue.is_present()) { - HANDLE_CODE(gap_ue->pack(bref)); - } - } + if (bwp_ded_present) { + HANDLE_CODE(bwp_ded.pack(bref)); } + return SRSASN_SUCCESS; } -SRSASN_CODE meas_gap_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE bwp_dl_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(gap_fr2_present, 1)); + HANDLE_CODE(bref.unpack(bwp_common_present, 1)); + HANDLE_CODE(bref.unpack(bwp_ded_present, 1)); - if (gap_fr2_present) { - HANDLE_CODE(gap_fr2.unpack(bref)); + HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); + if (bwp_common_present) { + HANDLE_CODE(bwp_common.unpack(bref)); } - - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - bool gap_fr1_present; - HANDLE_CODE(bref.unpack(gap_fr1_present, 1)); - gap_fr1.set_present(gap_fr1_present); - bool gap_ue_present; - HANDLE_CODE(bref.unpack(gap_ue_present, 1)); - gap_ue.set_present(gap_ue_present); - if (gap_fr1.is_present()) { - HANDLE_CODE(gap_fr1->unpack(bref)); - } - if (gap_ue.is_present()) { - HANDLE_CODE(gap_ue->unpack(bref)); - } - } + if (bwp_ded_present) { + HANDLE_CODE(bwp_ded.unpack(bref)); } + return SRSASN_SUCCESS; } -void meas_gap_cfg_s::to_json(json_writer& j) const +void bwp_dl_s::to_json(json_writer& j) const { j.start_obj(); - if (gap_fr2_present) { - j.write_fieldname("gapFR2"); - gap_fr2.to_json(j); + j.write_int("bwp-Id", bwp_id); + if (bwp_common_present) { + j.write_fieldname("bwp-Common"); + bwp_common.to_json(j); } - if (ext) { - if (gap_fr1.is_present()) { - j.write_fieldname("gapFR1"); - gap_fr1->to_json(j); - } - if (gap_ue.is_present()) { - j.write_fieldname("gapUE"); - gap_ue->to_json(j); - } + if (bwp_ded_present) { + j.write_fieldname("bwp-Dedicated"); + bwp_ded.to_json(j); } j.end_obj(); } -// MeasGapSharingConfig ::= SEQUENCE -SRSASN_CODE meas_gap_sharing_cfg_s::pack(bit_ref& bref) const +// Alpha ::= ENUMERATED +std::string alpha_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(gap_sharing_fr2_present, 1)); + static const char* options[] = {"alpha0", "alpha04", "alpha05", "alpha06", "alpha07", "alpha08", "alpha09", "alpha1"}; + return convert_enum_idx(options, 8, value, "alpha_e"); +} +float alpha_opts::to_number() const +{ + static const float options[] = {0.0, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1.0}; + return map_enum_number(options, 8, value, "alpha_e"); +} +std::string alpha_opts::to_number_string() const +{ + static const char* options[] = {"0", "0.4", "0.5", "0.6", "0.7", "0.8", "0.9", "1"}; + return convert_enum_idx(options, 8, value, "alpha_e"); +} - if (gap_sharing_fr2_present) { - HANDLE_CODE(gap_sharing_fr2.pack(bref)); +// BetaOffsets ::= SEQUENCE +SRSASN_CODE beta_offsets_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(beta_offset_ack_idx1_present, 1)); + HANDLE_CODE(bref.pack(beta_offset_ack_idx2_present, 1)); + HANDLE_CODE(bref.pack(beta_offset_ack_idx3_present, 1)); + HANDLE_CODE(bref.pack(beta_offset_csi_part1_idx1_present, 1)); + HANDLE_CODE(bref.pack(beta_offset_csi_part1_idx2_present, 1)); + HANDLE_CODE(bref.pack(beta_offset_csi_part2_idx1_present, 1)); + HANDLE_CODE(bref.pack(beta_offset_csi_part2_idx2_present, 1)); + + if (beta_offset_ack_idx1_present) { + HANDLE_CODE(pack_integer(bref, beta_offset_ack_idx1, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_ack_idx2_present) { + HANDLE_CODE(pack_integer(bref, beta_offset_ack_idx2, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_ack_idx3_present) { + HANDLE_CODE(pack_integer(bref, beta_offset_ack_idx3, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part1_idx1_present) { + HANDLE_CODE(pack_integer(bref, beta_offset_csi_part1_idx1, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part1_idx2_present) { + HANDLE_CODE(pack_integer(bref, beta_offset_csi_part1_idx2, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part2_idx1_present) { + HANDLE_CODE(pack_integer(bref, beta_offset_csi_part2_idx1, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part2_idx2_present) { + HANDLE_CODE(pack_integer(bref, beta_offset_csi_part2_idx2, (uint8_t)0u, (uint8_t)31u)); } - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= gap_sharing_fr1.is_present(); - group_flags[0] |= gap_sharing_ue.is_present(); - group_flags.pack(bref); + return SRSASN_SUCCESS; +} +SRSASN_CODE beta_offsets_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(beta_offset_ack_idx1_present, 1)); + HANDLE_CODE(bref.unpack(beta_offset_ack_idx2_present, 1)); + HANDLE_CODE(bref.unpack(beta_offset_ack_idx3_present, 1)); + HANDLE_CODE(bref.unpack(beta_offset_csi_part1_idx1_present, 1)); + HANDLE_CODE(bref.unpack(beta_offset_csi_part1_idx2_present, 1)); + HANDLE_CODE(bref.unpack(beta_offset_csi_part2_idx1_present, 1)); + HANDLE_CODE(bref.unpack(beta_offset_csi_part2_idx2_present, 1)); - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); + if (beta_offset_ack_idx1_present) { + HANDLE_CODE(unpack_integer(beta_offset_ack_idx1, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_ack_idx2_present) { + HANDLE_CODE(unpack_integer(beta_offset_ack_idx2, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_ack_idx3_present) { + HANDLE_CODE(unpack_integer(beta_offset_ack_idx3, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part1_idx1_present) { + HANDLE_CODE(unpack_integer(beta_offset_csi_part1_idx1, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part1_idx2_present) { + HANDLE_CODE(unpack_integer(beta_offset_csi_part1_idx2, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part2_idx1_present) { + HANDLE_CODE(unpack_integer(beta_offset_csi_part2_idx1, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (beta_offset_csi_part2_idx2_present) { + HANDLE_CODE(unpack_integer(beta_offset_csi_part2_idx2, bref, (uint8_t)0u, (uint8_t)31u)); + } - HANDLE_CODE(bref.pack(gap_sharing_fr1.is_present(), 1)); - HANDLE_CODE(bref.pack(gap_sharing_ue.is_present(), 1)); - if (gap_sharing_fr1.is_present()) { - HANDLE_CODE(gap_sharing_fr1->pack(bref)); - } - if (gap_sharing_ue.is_present()) { - HANDLE_CODE(gap_sharing_ue->pack(bref)); - } - } + return SRSASN_SUCCESS; +} +void beta_offsets_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (beta_offset_ack_idx1_present) { + j.write_int("betaOffsetACK-Index1", beta_offset_ack_idx1); + } + if (beta_offset_ack_idx2_present) { + j.write_int("betaOffsetACK-Index2", beta_offset_ack_idx2); + } + if (beta_offset_ack_idx3_present) { + j.write_int("betaOffsetACK-Index3", beta_offset_ack_idx3); + } + if (beta_offset_csi_part1_idx1_present) { + j.write_int("betaOffsetCSI-Part1-Index1", beta_offset_csi_part1_idx1); } + if (beta_offset_csi_part1_idx2_present) { + j.write_int("betaOffsetCSI-Part1-Index2", beta_offset_csi_part1_idx2); + } + if (beta_offset_csi_part2_idx1_present) { + j.write_int("betaOffsetCSI-Part2-Index1", beta_offset_csi_part2_idx1); + } + if (beta_offset_csi_part2_idx2_present) { + j.write_int("betaOffsetCSI-Part2-Index2", beta_offset_csi_part2_idx2); + } + j.end_obj(); +} + +// P0-PUCCH ::= SEQUENCE +SRSASN_CODE p0_pucch_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, p0_pucch_id, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(pack_integer(bref, p0_pucch_value, (int8_t)-16, (int8_t)15)); + return SRSASN_SUCCESS; } -SRSASN_CODE meas_gap_sharing_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE p0_pucch_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(gap_sharing_fr2_present, 1)); + HANDLE_CODE(unpack_integer(p0_pucch_id, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(unpack_integer(p0_pucch_value, bref, (int8_t)-16, (int8_t)15)); - if (gap_sharing_fr2_present) { - HANDLE_CODE(gap_sharing_fr2.unpack(bref)); - } + return SRSASN_SUCCESS; +} +void p0_pucch_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("p0-PUCCH-Id", p0_pucch_id); + j.write_int("p0-PUCCH-Value", p0_pucch_value); + j.end_obj(); +} - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); +// P0-PUSCH-AlphaSet ::= SEQUENCE +SRSASN_CODE p0_pusch_alpha_set_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(p0_present, 1)); + HANDLE_CODE(bref.pack(alpha_present, 1)); - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(pack_integer(bref, p0_pusch_alpha_set_id, (uint8_t)0u, (uint8_t)29u)); + if (p0_present) { + HANDLE_CODE(pack_integer(bref, p0, (int8_t)-16, (int8_t)15)); + } + if (alpha_present) { + HANDLE_CODE(alpha.pack(bref)); + } - bool gap_sharing_fr1_present; - HANDLE_CODE(bref.unpack(gap_sharing_fr1_present, 1)); - gap_sharing_fr1.set_present(gap_sharing_fr1_present); - bool gap_sharing_ue_present; - HANDLE_CODE(bref.unpack(gap_sharing_ue_present, 1)); - gap_sharing_ue.set_present(gap_sharing_ue_present); - if (gap_sharing_fr1.is_present()) { - HANDLE_CODE(gap_sharing_fr1->unpack(bref)); - } - if (gap_sharing_ue.is_present()) { - HANDLE_CODE(gap_sharing_ue->unpack(bref)); - } - } + return SRSASN_SUCCESS; +} +SRSASN_CODE p0_pusch_alpha_set_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(p0_present, 1)); + HANDLE_CODE(bref.unpack(alpha_present, 1)); + + HANDLE_CODE(unpack_integer(p0_pusch_alpha_set_id, bref, (uint8_t)0u, (uint8_t)29u)); + if (p0_present) { + HANDLE_CODE(unpack_integer(p0, bref, (int8_t)-16, (int8_t)15)); } + if (alpha_present) { + HANDLE_CODE(alpha.unpack(bref)); + } + return SRSASN_SUCCESS; } -void meas_gap_sharing_cfg_s::to_json(json_writer& j) const +void p0_pusch_alpha_set_s::to_json(json_writer& j) const { j.start_obj(); - if (gap_sharing_fr2_present) { - j.write_fieldname("gapSharingFR2"); - gap_sharing_fr2.to_json(j); + j.write_int("p0-PUSCH-AlphaSetId", p0_pusch_alpha_set_id); + if (p0_present) { + j.write_int("p0", p0); } - if (ext) { - if (gap_sharing_fr1.is_present()) { - j.write_fieldname("gapSharingFR1"); - gap_sharing_fr1->to_json(j); - } - if (gap_sharing_ue.is_present()) { - j.write_fieldname("gapSharingUE"); - gap_sharing_ue->to_json(j); - } + if (alpha_present) { + j.write_str("alpha", alpha.to_string()); } j.end_obj(); } -// OtherConfig ::= SEQUENCE -SRSASN_CODE other_cfg_s::pack(bit_ref& bref) const +// PTRS-UplinkConfig ::= SEQUENCE +SRSASN_CODE ptrs_ul_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(delay_budget_report_cfg_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(transform_precoder_disabled_present, 1)); + HANDLE_CODE(bref.pack(transform_precoder_enabled_present, 1)); - if (delay_budget_report_cfg_present) { - HANDLE_CODE(delay_budget_report_cfg.pack(bref)); + if (transform_precoder_disabled_present) { + HANDLE_CODE(bref.pack(transform_precoder_disabled.freq_density_present, 1)); + HANDLE_CODE(bref.pack(transform_precoder_disabled.time_density_present, 1)); + HANDLE_CODE(bref.pack(transform_precoder_disabled.res_elem_offset_present, 1)); + if (transform_precoder_disabled.freq_density_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(transform_precoder_disabled.freq_density)[0], + transform_precoder_disabled.freq_density.size(), + integer_packer(1, 276))); + } + if (transform_precoder_disabled.time_density_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(transform_precoder_disabled.time_density)[0], + transform_precoder_disabled.time_density.size(), + integer_packer(0, 29))); + } + HANDLE_CODE(transform_precoder_disabled.max_nrof_ports.pack(bref)); + if (transform_precoder_disabled.res_elem_offset_present) { + HANDLE_CODE(transform_precoder_disabled.res_elem_offset.pack(bref)); + } + HANDLE_CODE(transform_precoder_disabled.ptrs_pwr.pack(bref)); + } + if (transform_precoder_enabled_present) { + HANDLE_CODE(bref.pack(transform_precoder_enabled.time_density_transform_precoding_present, 1)); + HANDLE_CODE(pack_fixed_seq_of(bref, + &(transform_precoder_enabled.sample_density)[0], + transform_precoder_enabled.sample_density.size(), + integer_packer(1, 276))); } return SRSASN_SUCCESS; } -SRSASN_CODE other_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE ptrs_ul_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(delay_budget_report_cfg_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(transform_precoder_disabled_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoder_enabled_present, 1)); - if (delay_budget_report_cfg_present) { - HANDLE_CODE(delay_budget_report_cfg.unpack(bref)); + if (transform_precoder_disabled_present) { + HANDLE_CODE(bref.unpack(transform_precoder_disabled.freq_density_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoder_disabled.time_density_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoder_disabled.res_elem_offset_present, 1)); + if (transform_precoder_disabled.freq_density_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(transform_precoder_disabled.freq_density)[0], + bref, + transform_precoder_disabled.freq_density.size(), + integer_packer(1, 276))); + } + if (transform_precoder_disabled.time_density_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(transform_precoder_disabled.time_density)[0], + bref, + transform_precoder_disabled.time_density.size(), + integer_packer(0, 29))); + } + HANDLE_CODE(transform_precoder_disabled.max_nrof_ports.unpack(bref)); + if (transform_precoder_disabled.res_elem_offset_present) { + HANDLE_CODE(transform_precoder_disabled.res_elem_offset.unpack(bref)); + } + HANDLE_CODE(transform_precoder_disabled.ptrs_pwr.unpack(bref)); + } + if (transform_precoder_enabled_present) { + HANDLE_CODE(bref.unpack(transform_precoder_enabled.time_density_transform_precoding_present, 1)); + HANDLE_CODE(unpack_fixed_seq_of(&(transform_precoder_enabled.sample_density)[0], + bref, + transform_precoder_enabled.sample_density.size(), + integer_packer(1, 276))); } return SRSASN_SUCCESS; } -void other_cfg_s::to_json(json_writer& j) const +void ptrs_ul_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (delay_budget_report_cfg_present) { - j.write_fieldname("delayBudgetReportingConfig"); - delay_budget_report_cfg.to_json(j); + if (transform_precoder_disabled_present) { + j.write_fieldname("transformPrecoderDisabled"); + j.start_obj(); + if (transform_precoder_disabled.freq_density_present) { + j.start_array("frequencyDensity"); + for (const auto& e1 : transform_precoder_disabled.freq_density) { + j.write_int(e1); + } + j.end_array(); + } + if (transform_precoder_disabled.time_density_present) { + j.start_array("timeDensity"); + for (const auto& e1 : transform_precoder_disabled.time_density) { + j.write_int(e1); + } + j.end_array(); + } + j.write_str("maxNrofPorts", transform_precoder_disabled.max_nrof_ports.to_string()); + if (transform_precoder_disabled.res_elem_offset_present) { + j.write_str("resourceElementOffset", transform_precoder_disabled.res_elem_offset.to_string()); + } + j.write_str("ptrs-Power", transform_precoder_disabled.ptrs_pwr.to_string()); + j.end_obj(); + } + if (transform_precoder_enabled_present) { + j.write_fieldname("transformPrecoderEnabled"); + j.start_obj(); + j.start_array("sampleDensity"); + for (const auto& e1 : transform_precoder_enabled.sample_density) { + j.write_int(e1); + } + j.end_array(); + if (transform_precoder_enabled.time_density_transform_precoding_present) { + j.write_str("timeDensityTransformPrecoding", "d2"); + } + j.end_obj(); } j.end_obj(); } -void other_cfg_s::delay_budget_report_cfg_c_::set(types::options e) +std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_opts::to_string() const +{ + static const char* options[] = {"n1", "n2"}; + return convert_enum_idx(options, 2, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_e_"); +} +uint8_t ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::max_nrof_ports_e_"); +} + +std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_opts::to_string() const +{ + static const char* options[] = {"offset01", "offset10", "offset11"}; + return convert_enum_idx(options, 3, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_e_"); +} +float ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_opts::to_number() const +{ + static const float options[] = {0.1, 1.0, 1.1}; + return map_enum_number(options, 3, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_e_"); +} +std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_opts::to_number_string() const +{ + static const char* options[] = {"0.1", "1.0", "1.1"}; + return convert_enum_idx(options, 3, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::res_elem_offset_e_"); +} + +std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_opts::to_string() const +{ + static const char* options[] = {"p00", "p01", "p10", "p11"}; + return convert_enum_idx(options, 4, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_e_"); +} +float ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_opts::to_number() const +{ + static const float options[] = {0.0, 0.1, 1.0, 1.1}; + return map_enum_number(options, 4, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_e_"); +} +std::string ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_opts::to_number_string() const +{ + static const char* options[] = {"0.0", "0.1", "1.0", "1.1"}; + return convert_enum_idx(options, 4, value, "ptrs_ul_cfg_s::transform_precoder_disabled_s_::ptrs_pwr_e_"); +} + +// PUCCH-MaxCodeRate ::= ENUMERATED +std::string pucch_max_code_rate_opts::to_string() const +{ + static const char* options[] = { + "zeroDot08", "zeroDot15", "zeroDot25", "zeroDot35", "zeroDot45", "zeroDot60", "zeroDot80"}; + return convert_enum_idx(options, 7, value, "pucch_max_code_rate_e"); +} +float pucch_max_code_rate_opts::to_number() const +{ + static const float options[] = {0.08, 0.15, 0.25, 0.35, 0.45, 0.6, 0.8}; + return map_enum_number(options, 7, value, "pucch_max_code_rate_e"); +} +std::string pucch_max_code_rate_opts::to_number_string() const +{ + static const char* options[] = {"0.08", "0.15", "0.25", "0.35", "0.45", "0.60", "0.80"}; + return convert_enum_idx(options, 7, value, "pucch_max_code_rate_e"); +} + +// PUCCH-PathlossReferenceRS ::= SEQUENCE +SRSASN_CODE pucch_pathloss_ref_rs_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, pucch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(ref_sig.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE pucch_pathloss_ref_rs_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(pucch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(ref_sig.unpack(bref)); + + return SRSASN_SUCCESS; +} +void pucch_pathloss_ref_rs_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("pucch-PathlossReferenceRS-Id", pucch_pathloss_ref_rs_id); + j.write_fieldname("referenceSignal"); + ref_sig.to_json(j); + j.end_obj(); +} + +void pucch_pathloss_ref_rs_s::ref_sig_c_::destroy_() {} +void pucch_pathloss_ref_rs_s::ref_sig_c_::set(types::options e) { + destroy_(); type_ = e; } -void other_cfg_s::delay_budget_report_cfg_c_::to_json(json_writer& j) const +pucch_pathloss_ref_rs_s::ref_sig_c_::ref_sig_c_(const pucch_pathloss_ref_rs_s::ref_sig_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::ssb_idx: + c.init(other.c.get()); + break; + case types::csi_rs_idx: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); + } +} +pucch_pathloss_ref_rs_s::ref_sig_c_& +pucch_pathloss_ref_rs_s::ref_sig_c_::operator=(const pucch_pathloss_ref_rs_s::ref_sig_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::ssb_idx: + c.set(other.c.get()); + break; + case types::csi_rs_idx: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); + } + + return *this; +} +void pucch_pathloss_ref_rs_s::ref_sig_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::release: + case types::ssb_idx: + j.write_int("ssb-Index", c.get()); break; - case types::setup: - j.write_fieldname("setup"); - j.start_obj(); - j.write_str("delayBudgetReportingProhibitTimer", c.delay_budget_report_prohibit_timer.to_string()); - j.end_obj(); + case types::csi_rs_idx: + j.write_int("csi-RS-Index", c.get()); break; default: - log_invalid_choice_id(type_, "other_cfg_s::delay_budget_report_cfg_c_"); + log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); } j.end_obj(); } -SRSASN_CODE other_cfg_s::delay_budget_report_cfg_c_::pack(bit_ref& bref) const +SRSASN_CODE pucch_pathloss_ref_rs_s::ref_sig_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::release: + case types::ssb_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); break; - case types::setup: - HANDLE_CODE(c.delay_budget_report_prohibit_timer.pack(bref)); + case types::csi_rs_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); break; default: - log_invalid_choice_id(type_, "other_cfg_s::delay_budget_report_cfg_c_"); + log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE other_cfg_s::delay_budget_report_cfg_c_::unpack(cbit_ref& bref) +SRSASN_CODE pucch_pathloss_ref_rs_s::ref_sig_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::release: + case types::ssb_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); break; - case types::setup: - HANDLE_CODE(c.delay_budget_report_prohibit_timer.unpack(bref)); + case types::csi_rs_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); break; default: - log_invalid_choice_id(type_, "other_cfg_s::delay_budget_report_cfg_c_"); + log_invalid_choice_id(type_, "pucch_pathloss_ref_rs_s::ref_sig_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string -other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_opts::to_string() const +std::string pucch_pathloss_ref_rs_s::ref_sig_c_::types_opts::to_string() const { - static const char* options[] = {"s0", "s0dot4", "s0dot8", "s1dot6", "s3", "s6", "s12", "s30"}; - return convert_enum_idx( - options, 8, value, "other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_e_"); + static const char* options[] = {"ssb-Index", "csi-RS-Index"}; + return convert_enum_idx(options, 2, value, "pucch_pathloss_ref_rs_s::ref_sig_c_::types"); } -float other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_opts::to_number() const + +// PUCCH-format0 ::= SEQUENCE +SRSASN_CODE pucch_format0_s::pack(bit_ref& bref) const { - static const float options[] = {0.0, 0.4, 0.8, 1.6, 3.0, 6.0, 12.0, 30.0}; - return map_enum_number( - options, 8, value, "other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_e_"); + HANDLE_CODE(pack_integer(bref, init_cyclic_shift, (uint8_t)0u, (uint8_t)11u)); + HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)13u)); + + return SRSASN_SUCCESS; } -std::string -other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_opts::to_number_string() const +SRSASN_CODE pucch_format0_s::unpack(cbit_ref& bref) { - static const char* options[] = {"0", "0.4", "0.8", "1.6", "3", "6", "12", "30"}; - return convert_enum_idx( - options, 8, value, "other_cfg_s::delay_budget_report_cfg_c_::setup_s_::delay_budget_report_prohibit_timer_e_"); -} + HANDLE_CODE(unpack_integer(init_cyclic_shift, bref, (uint8_t)0u, (uint8_t)11u)); + HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)13u)); -std::string other_cfg_s::delay_budget_report_cfg_c_::types_opts::to_string() const + return SRSASN_SUCCESS; +} +void pucch_format0_s::to_json(json_writer& j) const { - static const char* options[] = {"release", "setup"}; - return convert_enum_idx(options, 2, value, "other_cfg_s::delay_budget_report_cfg_c_::types"); + j.start_obj(); + j.write_int("initialCyclicShift", init_cyclic_shift); + j.write_int("nrofSymbols", nrof_symbols); + j.write_int("startingSymbolIndex", start_symbol_idx); + j.end_obj(); } -// PeriodicRNAU-TimerValue ::= ENUMERATED -std::string periodic_rnau_timer_value_opts::to_string() const +// PUCCH-format1 ::= SEQUENCE +SRSASN_CODE pucch_format1_s::pack(bit_ref& bref) const { - static const char* options[] = {"min5", "min10", "min20", "min30", "min60", "min120", "min360", "min720"}; - return convert_enum_idx(options, 8, value, "periodic_rnau_timer_value_e"); + HANDLE_CODE(pack_integer(bref, init_cyclic_shift, (uint8_t)0u, (uint8_t)11u)); + HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)4u, (uint8_t)14u)); + HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)10u)); + HANDLE_CODE(pack_integer(bref, time_domain_occ, (uint8_t)0u, (uint8_t)6u)); + + return SRSASN_SUCCESS; } -uint16_t periodic_rnau_timer_value_opts::to_number() const +SRSASN_CODE pucch_format1_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {5, 10, 20, 30, 60, 120, 360, 720}; - return map_enum_number(options, 8, value, "periodic_rnau_timer_value_e"); + HANDLE_CODE(unpack_integer(init_cyclic_shift, bref, (uint8_t)0u, (uint8_t)11u)); + HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)4u, (uint8_t)14u)); + HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)10u)); + HANDLE_CODE(unpack_integer(time_domain_occ, bref, (uint8_t)0u, (uint8_t)6u)); + + return SRSASN_SUCCESS; +} +void pucch_format1_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("initialCyclicShift", init_cyclic_shift); + j.write_int("nrofSymbols", nrof_symbols); + j.write_int("startingSymbolIndex", start_symbol_idx); + j.write_int("timeDomainOCC", time_domain_occ); + j.end_obj(); } -// QuantityConfig ::= SEQUENCE -SRSASN_CODE quant_cfg_s::pack(bit_ref& bref) const +// PUCCH-format2 ::= SEQUENCE +SRSASN_CODE pucch_format2_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(quant_cfg_nr_list_present, 1)); + HANDLE_CODE(pack_integer(bref, nrof_prbs, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)13u)); - if (quant_cfg_nr_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, quant_cfg_nr_list, 1, 2)); - } + return SRSASN_SUCCESS; +} +SRSASN_CODE pucch_format2_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(nrof_prbs, bref, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)13u)); - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= quant_cfg_eutra.is_present(); - group_flags.pack(bref); + return SRSASN_SUCCESS; +} +void pucch_format2_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("nrofPRBs", nrof_prbs); + j.write_int("nrofSymbols", nrof_symbols); + j.write_int("startingSymbolIndex", start_symbol_idx); + j.end_obj(); +} - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); +// PUCCH-format3 ::= SEQUENCE +SRSASN_CODE pucch_format3_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, nrof_prbs, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)4u, (uint8_t)14u)); + HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)10u)); - HANDLE_CODE(bref.pack(quant_cfg_eutra.is_present(), 1)); - if (quant_cfg_eutra.is_present()) { - HANDLE_CODE(quant_cfg_eutra->pack(bref)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE quant_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_format3_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(quant_cfg_nr_list_present, 1)); + HANDLE_CODE(unpack_integer(nrof_prbs, bref, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)4u, (uint8_t)14u)); + HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)10u)); - if (quant_cfg_nr_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(quant_cfg_nr_list, bref, 1, 2)); - } + return SRSASN_SUCCESS; +} +void pucch_format3_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("nrofPRBs", nrof_prbs); + j.write_int("nrofSymbols", nrof_symbols); + j.write_int("startingSymbolIndex", start_symbol_idx); + j.end_obj(); +} - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); +// PUCCH-format4 ::= SEQUENCE +SRSASN_CODE pucch_format4_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, nrof_symbols, (uint8_t)4u, (uint8_t)14u)); + HANDLE_CODE(occ_len.pack(bref)); + HANDLE_CODE(occ_idx.pack(bref)); + HANDLE_CODE(pack_integer(bref, start_symbol_idx, (uint8_t)0u, (uint8_t)10u)); - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); + return SRSASN_SUCCESS; +} +SRSASN_CODE pucch_format4_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(nrof_symbols, bref, (uint8_t)4u, (uint8_t)14u)); + HANDLE_CODE(occ_len.unpack(bref)); + HANDLE_CODE(occ_idx.unpack(bref)); + HANDLE_CODE(unpack_integer(start_symbol_idx, bref, (uint8_t)0u, (uint8_t)10u)); - bool quant_cfg_eutra_present; - HANDLE_CODE(bref.unpack(quant_cfg_eutra_present, 1)); - quant_cfg_eutra.set_present(quant_cfg_eutra_present); - if (quant_cfg_eutra.is_present()) { - HANDLE_CODE(quant_cfg_eutra->unpack(bref)); - } - } - } return SRSASN_SUCCESS; } -void quant_cfg_s::to_json(json_writer& j) const +void pucch_format4_s::to_json(json_writer& j) const { j.start_obj(); - if (quant_cfg_nr_list_present) { - j.start_array("quantityConfigNR-List"); - for (const auto& e1 : quant_cfg_nr_list) { - e1.to_json(j); - } - j.end_array(); - } - if (ext) { - if (quant_cfg_eutra.is_present()) { - j.write_fieldname("quantityConfigEUTRA"); - quant_cfg_eutra->to_json(j); - } - } + j.write_int("nrofSymbols", nrof_symbols); + j.write_str("occ-Length", occ_len.to_string()); + j.write_str("occ-Index", occ_idx.to_string()); + j.write_int("startingSymbolIndex", start_symbol_idx); j.end_obj(); } -// RAN-NotificationAreaInfo ::= CHOICE -void ran_notif_area_info_c::destroy_() +std::string pucch_format4_s::occ_len_opts::to_string() const { - switch (type_) { - case types::cell_list: - c.destroy(); - break; - case types::ran_area_cfg_list: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"n2", "n4"}; + return convert_enum_idx(options, 2, value, "pucch_format4_s::occ_len_e_"); } -void ran_notif_area_info_c::set(types::options e) +uint8_t pucch_format4_s::occ_len_opts::to_number() const +{ + static const uint8_t options[] = {2, 4}; + return map_enum_number(options, 2, value, "pucch_format4_s::occ_len_e_"); +} + +std::string pucch_format4_s::occ_idx_opts::to_string() const +{ + static const char* options[] = {"n0", "n1", "n2", "n3"}; + return convert_enum_idx(options, 4, value, "pucch_format4_s::occ_idx_e_"); +} +uint8_t pucch_format4_s::occ_idx_opts::to_number() const +{ + static const uint8_t options[] = {0, 1, 2, 3}; + return map_enum_number(options, 4, value, "pucch_format4_s::occ_idx_e_"); +} + +// PUSCH-PathlossReferenceRS ::= SEQUENCE +SRSASN_CODE pusch_pathloss_ref_rs_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, pusch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(ref_sig.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE pusch_pathloss_ref_rs_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(pusch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(ref_sig.unpack(bref)); + + return SRSASN_SUCCESS; +} +void pusch_pathloss_ref_rs_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("pusch-PathlossReferenceRS-Id", pusch_pathloss_ref_rs_id); + j.write_fieldname("referenceSignal"); + ref_sig.to_json(j); + j.end_obj(); +} + +void pusch_pathloss_ref_rs_s::ref_sig_c_::destroy_() {} +void pusch_pathloss_ref_rs_s::ref_sig_c_::set(types::options e) { destroy_(); type_ = e; - switch (type_) { - case types::cell_list: - c.init(); - break; - case types::ran_area_cfg_list: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ran_notif_area_info_c"); - } } -ran_notif_area_info_c::ran_notif_area_info_c(const ran_notif_area_info_c& other) +pusch_pathloss_ref_rs_s::ref_sig_c_::ref_sig_c_(const pusch_pathloss_ref_rs_s::ref_sig_c_& other) { type_ = other.type(); switch (type_) { - case types::cell_list: - c.init(other.c.get()); + case types::ssb_idx: + c.init(other.c.get()); break; - case types::ran_area_cfg_list: - c.init(other.c.get()); + case types::csi_rs_idx: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ran_notif_area_info_c"); + log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); } } -ran_notif_area_info_c& ran_notif_area_info_c::operator=(const ran_notif_area_info_c& other) +pusch_pathloss_ref_rs_s::ref_sig_c_& +pusch_pathloss_ref_rs_s::ref_sig_c_::operator=(const pusch_pathloss_ref_rs_s::ref_sig_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::cell_list: - c.set(other.c.get()); + case types::ssb_idx: + c.set(other.c.get()); break; - case types::ran_area_cfg_list: - c.set(other.c.get()); + case types::csi_rs_idx: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ran_notif_area_info_c"); + log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); } return *this; } -void ran_notif_area_info_c::to_json(json_writer& j) const +void pusch_pathloss_ref_rs_s::ref_sig_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::cell_list: - j.start_array("cellList"); - for (const auto& e1 : c.get()) { - e1.to_json(j); - } - j.end_array(); + case types::ssb_idx: + j.write_int("ssb-Index", c.get()); break; - case types::ran_area_cfg_list: - j.start_array("ran-AreaConfigList"); - for (const auto& e1 : c.get()) { - e1.to_json(j); - } - j.end_array(); + case types::csi_rs_idx: + j.write_int("csi-RS-Index", c.get()); break; default: - log_invalid_choice_id(type_, "ran_notif_area_info_c"); + log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); } j.end_obj(); } -SRSASN_CODE ran_notif_area_info_c::pack(bit_ref& bref) const +SRSASN_CODE pusch_pathloss_ref_rs_s::ref_sig_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::cell_list: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); + case types::ssb_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); break; - case types::ran_area_cfg_list: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); + case types::csi_rs_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); break; default: - log_invalid_choice_id(type_, "ran_notif_area_info_c"); + log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE ran_notif_area_info_c::unpack(cbit_ref& bref) +SRSASN_CODE pusch_pathloss_ref_rs_s::ref_sig_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::cell_list: - HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); + case types::ssb_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); break; - case types::ran_area_cfg_list: - HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); + case types::csi_rs_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); break; default: - log_invalid_choice_id(type_, "ran_notif_area_info_c"); + log_invalid_choice_id(type_, "pusch_pathloss_ref_rs_s::ref_sig_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string ran_notif_area_info_c::types_opts::to_string() const -{ - static const char* options[] = {"cellList", "ran-AreaConfigList"}; - return convert_enum_idx(options, 2, value, "ran_notif_area_info_c::types"); -} - -// RRCReconfiguration-v1540-IEs ::= SEQUENCE -SRSASN_CODE rrc_recfg_v1540_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(other_cfg_v1540_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (other_cfg_v1540_present) { - HANDLE_CODE(other_cfg_v1540.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_recfg_v1540_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(other_cfg_v1540_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (other_cfg_v1540_present) { - HANDLE_CODE(other_cfg_v1540.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void rrc_recfg_v1540_ies_s::to_json(json_writer& j) const +std::string pusch_pathloss_ref_rs_s::ref_sig_c_::types_opts::to_string() const { - j.start_obj(); - if (other_cfg_v1540_present) { - j.write_fieldname("otherConfig-v1540"); - other_cfg_v1540.to_json(j); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); + static const char* options[] = {"ssb-Index", "csi-RS-Index"}; + return convert_enum_idx(options, 2, value, "pusch_pathloss_ref_rs_s::ref_sig_c_::types"); } -// RedirectedCarrierInfo-EUTRA ::= SEQUENCE -SRSASN_CODE redirected_carrier_info_eutra_s::pack(bit_ref& bref) const +// SRI-PUSCH-PowerControl ::= SEQUENCE +SRSASN_CODE sri_pusch_pwr_ctrl_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(cn_type_present, 1)); - - HANDLE_CODE(pack_integer(bref, eutra_freq, (uint32_t)0u, (uint32_t)262143u)); - if (cn_type_present) { - HANDLE_CODE(cn_type.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, sri_pusch_pwr_ctrl_id, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(pack_integer(bref, sri_pusch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pack_integer(bref, sri_p0_pusch_alpha_set_id, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(sri_pusch_closed_loop_idx.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE redirected_carrier_info_eutra_s::unpack(cbit_ref& bref) +SRSASN_CODE sri_pusch_pwr_ctrl_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(cn_type_present, 1)); - - HANDLE_CODE(unpack_integer(eutra_freq, bref, (uint32_t)0u, (uint32_t)262143u)); - if (cn_type_present) { - HANDLE_CODE(cn_type.unpack(bref)); - } + HANDLE_CODE(unpack_integer(sri_pusch_pwr_ctrl_id, bref, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(unpack_integer(sri_pusch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(unpack_integer(sri_p0_pusch_alpha_set_id, bref, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(sri_pusch_closed_loop_idx.unpack(bref)); return SRSASN_SUCCESS; } -void redirected_carrier_info_eutra_s::to_json(json_writer& j) const +void sri_pusch_pwr_ctrl_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("eutraFrequency", eutra_freq); - if (cn_type_present) { - j.write_str("cnType", cn_type.to_string()); - } + j.write_int("sri-PUSCH-PowerControlId", sri_pusch_pwr_ctrl_id); + j.write_int("sri-PUSCH-PathlossReferenceRS-Id", sri_pusch_pathloss_ref_rs_id); + j.write_int("sri-P0-PUSCH-AlphaSetId", sri_p0_pusch_alpha_set_id); + j.write_str("sri-PUSCH-ClosedLoopIndex", sri_pusch_closed_loop_idx.to_string()); j.end_obj(); } -std::string redirected_carrier_info_eutra_s::cn_type_opts::to_string() const +std::string sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_opts::to_string() const { - static const char* options[] = {"epc", "fiveGC"}; - return convert_enum_idx(options, 2, value, "redirected_carrier_info_eutra_s::cn_type_e_"); + static const char* options[] = {"i0", "i1"}; + return convert_enum_idx(options, 2, value, "sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_e_"); } -uint8_t redirected_carrier_info_eutra_s::cn_type_opts::to_number() const +uint8_t sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_opts::to_number() const { - if (value == five_gc) { - return 5; - } - invalid_enum_number(value, "redirected_carrier_info_eutra_s::cn_type_e_"); - return 0; + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "sri_pusch_pwr_ctrl_s::sri_pusch_closed_loop_idx_e_"); } -// UE-CapabilityRAT-Request ::= SEQUENCE -SRSASN_CODE ue_cap_rat_request_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(cap_request_filt_present, 1)); - - HANDLE_CODE(rat_type.pack(bref)); - if (cap_request_filt_present) { - HANDLE_CODE(cap_request_filt.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE ue_cap_rat_request_s::unpack(cbit_ref& bref) +// SRS-PeriodicityAndOffset ::= CHOICE +void srs_periodicity_and_offset_c::destroy_() {} +void srs_periodicity_and_offset_c::set(types::options e) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(cap_request_filt_present, 1)); - - HANDLE_CODE(rat_type.unpack(bref)); - if (cap_request_filt_present) { - HANDLE_CODE(cap_request_filt.unpack(bref)); - } - - return SRSASN_SUCCESS; + destroy_(); + type_ = e; } -void ue_cap_rat_request_s::to_json(json_writer& j) const +srs_periodicity_and_offset_c::srs_periodicity_and_offset_c(const srs_periodicity_and_offset_c& other) { - j.start_obj(); - j.write_str("rat-Type", rat_type.to_string()); - if (cap_request_filt_present) { - j.write_str("capabilityRequestFilter", cap_request_filt.to_string()); + type_ = other.type(); + switch (type_) { + case types::sl1: + break; + case types::sl2: + c.init(other.c.get()); + break; + case types::sl4: + c.init(other.c.get()); + break; + case types::sl5: + c.init(other.c.get()); + break; + case types::sl8: + c.init(other.c.get()); + break; + case types::sl10: + c.init(other.c.get()); + break; + case types::sl16: + c.init(other.c.get()); + break; + case types::sl20: + c.init(other.c.get()); + break; + case types::sl32: + c.init(other.c.get()); + break; + case types::sl40: + c.init(other.c.get()); + break; + case types::sl64: + c.init(other.c.get()); + break; + case types::sl80: + c.init(other.c.get()); + break; + case types::sl160: + c.init(other.c.get()); + break; + case types::sl320: + c.init(other.c.get()); + break; + case types::sl640: + c.init(other.c.get()); + break; + case types::sl1280: + c.init(other.c.get()); + break; + case types::sl2560: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); } - j.end_obj(); } - -// CellReselectionPriorities ::= SEQUENCE -SRSASN_CODE cell_resel_priorities_s::pack(bit_ref& bref) const +srs_periodicity_and_offset_c& srs_periodicity_and_offset_c::operator=(const srs_periodicity_and_offset_c& other) { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(freq_prio_list_eutra_present, 1)); - HANDLE_CODE(bref.pack(freq_prio_list_nr_present, 1)); - HANDLE_CODE(bref.pack(t320_present, 1)); - - if (freq_prio_list_eutra_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, freq_prio_list_eutra, 1, 8)); - } - if (freq_prio_list_nr_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, freq_prio_list_nr, 1, 8)); - } - if (t320_present) { - HANDLE_CODE(t320.pack(bref)); + if (this == &other) { + return *this; } - - return SRSASN_SUCCESS; -} -SRSASN_CODE cell_resel_priorities_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(freq_prio_list_eutra_present, 1)); - HANDLE_CODE(bref.unpack(freq_prio_list_nr_present, 1)); - HANDLE_CODE(bref.unpack(t320_present, 1)); - - if (freq_prio_list_eutra_present) { - HANDLE_CODE(unpack_dyn_seq_of(freq_prio_list_eutra, bref, 1, 8)); - } - if (freq_prio_list_nr_present) { - HANDLE_CODE(unpack_dyn_seq_of(freq_prio_list_nr, bref, 1, 8)); - } - if (t320_present) { - HANDLE_CODE(t320.unpack(bref)); + set(other.type()); + switch (type_) { + case types::sl1: + break; + case types::sl2: + c.set(other.c.get()); + break; + case types::sl4: + c.set(other.c.get()); + break; + case types::sl5: + c.set(other.c.get()); + break; + case types::sl8: + c.set(other.c.get()); + break; + case types::sl10: + c.set(other.c.get()); + break; + case types::sl16: + c.set(other.c.get()); + break; + case types::sl20: + c.set(other.c.get()); + break; + case types::sl32: + c.set(other.c.get()); + break; + case types::sl40: + c.set(other.c.get()); + break; + case types::sl64: + c.set(other.c.get()); + break; + case types::sl80: + c.set(other.c.get()); + break; + case types::sl160: + c.set(other.c.get()); + break; + case types::sl320: + c.set(other.c.get()); + break; + case types::sl640: + c.set(other.c.get()); + break; + case types::sl1280: + c.set(other.c.get()); + break; + case types::sl2560: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); } - return SRSASN_SUCCESS; + return *this; } -void cell_resel_priorities_s::to_json(json_writer& j) const +void srs_periodicity_and_offset_c::to_json(json_writer& j) const { j.start_obj(); - if (freq_prio_list_eutra_present) { - j.start_array("freqPriorityListEUTRA"); - for (const auto& e1 : freq_prio_list_eutra) { - e1.to_json(j); - } - j.end_array(); + switch (type_) { + case types::sl1: + break; + case types::sl2: + j.write_int("sl2", c.get()); + break; + case types::sl4: + j.write_int("sl4", c.get()); + break; + case types::sl5: + j.write_int("sl5", c.get()); + break; + case types::sl8: + j.write_int("sl8", c.get()); + break; + case types::sl10: + j.write_int("sl10", c.get()); + break; + case types::sl16: + j.write_int("sl16", c.get()); + break; + case types::sl20: + j.write_int("sl20", c.get()); + break; + case types::sl32: + j.write_int("sl32", c.get()); + break; + case types::sl40: + j.write_int("sl40", c.get()); + break; + case types::sl64: + j.write_int("sl64", c.get()); + break; + case types::sl80: + j.write_int("sl80", c.get()); + break; + case types::sl160: + j.write_int("sl160", c.get()); + break; + case types::sl320: + j.write_int("sl320", c.get()); + break; + case types::sl640: + j.write_int("sl640", c.get()); + break; + case types::sl1280: + j.write_int("sl1280", c.get()); + break; + case types::sl2560: + j.write_int("sl2560", c.get()); + break; + default: + log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); } - if (freq_prio_list_nr_present) { - j.start_array("freqPriorityListNR"); - for (const auto& e1 : freq_prio_list_nr) { - e1.to_json(j); - } - j.end_array(); + j.end_obj(); +} +SRSASN_CODE srs_periodicity_and_offset_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::sl1: + break; + case types::sl2: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)1u)); + break; + case types::sl4: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); + break; + case types::sl5: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); + break; + case types::sl8: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); + break; + case types::sl10: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); + break; + case types::sl16: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); + break; + case types::sl20: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); + break; + case types::sl32: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); + break; + case types::sl40: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); + break; + case types::sl64: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + break; + case types::sl80: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); + break; + case types::sl160: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + break; + case types::sl320: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + break; + case types::sl640: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); + break; + case types::sl1280: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)1279u)); + break; + case types::sl2560: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)2559u)); + break; + default: + log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); + return SRSASN_ERROR_ENCODE_FAIL; } - if (t320_present) { - j.write_str("t320", t320.to_string()); + return SRSASN_SUCCESS; +} +SRSASN_CODE srs_periodicity_and_offset_c::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::sl1: + break; + case types::sl2: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)1u)); + break; + case types::sl4: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); + break; + case types::sl5: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); + break; + case types::sl8: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); + break; + case types::sl10: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); + break; + case types::sl16: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); + break; + case types::sl20: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); + break; + case types::sl32: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); + break; + case types::sl40: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); + break; + case types::sl64: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); + break; + case types::sl80: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); + break; + case types::sl160: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + break; + case types::sl320: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + break; + case types::sl640: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); + break; + case types::sl1280: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)1279u)); + break; + case types::sl2560: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)2559u)); + break; + default: + log_invalid_choice_id(type_, "srs_periodicity_and_offset_c"); + return SRSASN_ERROR_DECODE_FAIL; } - j.end_obj(); + return SRSASN_SUCCESS; } -std::string cell_resel_priorities_s::t320_opts::to_string() const +std::string srs_periodicity_and_offset_c::types_opts::to_string() const { - static const char* options[] = {"min5", "min10", "min20", "min30", "min60", "min120", "min180", "spare1"}; - return convert_enum_idx(options, 8, value, "cell_resel_priorities_s::t320_e_"); + static const char* options[] = {"sl1", + "sl2", + "sl4", + "sl5", + "sl8", + "sl10", + "sl16", + "sl20", + "sl32", + "sl40", + "sl64", + "sl80", + "sl160", + "sl320", + "sl640", + "sl1280", + "sl2560"}; + return convert_enum_idx(options, 17, value, "srs_periodicity_and_offset_c::types"); } -uint8_t cell_resel_priorities_s::t320_opts::to_number() const +uint16_t srs_periodicity_and_offset_c::types_opts::to_number() const { - static const uint8_t options[] = {5, 10, 20, 30, 60, 120, 180}; - return map_enum_number(options, 7, value, "cell_resel_priorities_s::t320_e_"); + static const uint16_t options[] = {1, 2, 4, 5, 8, 10, 16, 20, 32, 40, 64, 80, 160, 320, 640, 1280, 2560}; + return map_enum_number(options, 17, value, "srs_periodicity_and_offset_c::types"); } -// MeasConfig ::= SEQUENCE -SRSASN_CODE meas_cfg_s::pack(bit_ref& bref) const +// SRS-SpatialRelationInfo ::= SEQUENCE +SRSASN_CODE srs_spatial_relation_info_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(meas_obj_to_rem_list_present, 1)); - HANDLE_CODE(bref.pack(meas_obj_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(report_cfg_to_rem_list_present, 1)); - HANDLE_CODE(bref.pack(report_cfg_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(meas_id_to_rem_list_present, 1)); - HANDLE_CODE(bref.pack(meas_id_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.pack(s_measure_cfg_present, 1)); - HANDLE_CODE(bref.pack(quant_cfg_present, 1)); - HANDLE_CODE(bref.pack(meas_gap_cfg_present, 1)); - HANDLE_CODE(bref.pack(meas_gap_sharing_cfg_present, 1)); + HANDLE_CODE(bref.pack(serving_cell_id_present, 1)); - if (meas_obj_to_rem_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_obj_to_rem_list, 1, 64, integer_packer(1, 64))); - } - if (meas_obj_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_obj_to_add_mod_list, 1, 64)); - } - if (report_cfg_to_rem_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, report_cfg_to_rem_list, 1, 64, integer_packer(1, 64))); - } - if (report_cfg_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, report_cfg_to_add_mod_list, 1, 64)); - } - if (meas_id_to_rem_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_id_to_rem_list, 1, 64, integer_packer(1, 64))); - } - if (meas_id_to_add_mod_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_id_to_add_mod_list, 1, 64)); - } - if (s_measure_cfg_present) { - HANDLE_CODE(s_measure_cfg.pack(bref)); - } - if (quant_cfg_present) { - HANDLE_CODE(quant_cfg.pack(bref)); - } - if (meas_gap_cfg_present) { - HANDLE_CODE(meas_gap_cfg.pack(bref)); - } - if (meas_gap_sharing_cfg_present) { - HANDLE_CODE(meas_gap_sharing_cfg.pack(bref)); + if (serving_cell_id_present) { + HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); } + HANDLE_CODE(ref_sig.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_cfg_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_spatial_relation_info_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(meas_obj_to_rem_list_present, 1)); - HANDLE_CODE(bref.unpack(meas_obj_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(report_cfg_to_rem_list_present, 1)); - HANDLE_CODE(bref.unpack(report_cfg_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(meas_id_to_rem_list_present, 1)); - HANDLE_CODE(bref.unpack(meas_id_to_add_mod_list_present, 1)); - HANDLE_CODE(bref.unpack(s_measure_cfg_present, 1)); - HANDLE_CODE(bref.unpack(quant_cfg_present, 1)); - HANDLE_CODE(bref.unpack(meas_gap_cfg_present, 1)); - HANDLE_CODE(bref.unpack(meas_gap_sharing_cfg_present, 1)); + HANDLE_CODE(bref.unpack(serving_cell_id_present, 1)); - if (meas_obj_to_rem_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_obj_to_rem_list, bref, 1, 64, integer_packer(1, 64))); - } - if (meas_obj_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_obj_to_add_mod_list, bref, 1, 64)); - } - if (report_cfg_to_rem_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(report_cfg_to_rem_list, bref, 1, 64, integer_packer(1, 64))); - } - if (report_cfg_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(report_cfg_to_add_mod_list, bref, 1, 64)); - } - if (meas_id_to_rem_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_id_to_rem_list, bref, 1, 64, integer_packer(1, 64))); - } - if (meas_id_to_add_mod_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_id_to_add_mod_list, bref, 1, 64)); - } - if (s_measure_cfg_present) { - HANDLE_CODE(s_measure_cfg.unpack(bref)); - } - if (quant_cfg_present) { - HANDLE_CODE(quant_cfg.unpack(bref)); - } - if (meas_gap_cfg_present) { - HANDLE_CODE(meas_gap_cfg.unpack(bref)); - } - if (meas_gap_sharing_cfg_present) { - HANDLE_CODE(meas_gap_sharing_cfg.unpack(bref)); + if (serving_cell_id_present) { + HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); } + HANDLE_CODE(ref_sig.unpack(bref)); return SRSASN_SUCCESS; } -void meas_cfg_s::to_json(json_writer& j) const +void srs_spatial_relation_info_s::to_json(json_writer& j) const { j.start_obj(); - if (meas_obj_to_rem_list_present) { - j.start_array("measObjectToRemoveList"); - for (const auto& e1 : meas_obj_to_rem_list) { - j.write_int(e1); - } - j.end_array(); - } - if (meas_obj_to_add_mod_list_present) { - j.start_array("measObjectToAddModList"); - for (const auto& e1 : meas_obj_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (report_cfg_to_rem_list_present) { - j.start_array("reportConfigToRemoveList"); - for (const auto& e1 : report_cfg_to_rem_list) { - j.write_int(e1); - } - j.end_array(); - } - if (report_cfg_to_add_mod_list_present) { - j.start_array("reportConfigToAddModList"); - for (const auto& e1 : report_cfg_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (meas_id_to_rem_list_present) { - j.start_array("measIdToRemoveList"); - for (const auto& e1 : meas_id_to_rem_list) { - j.write_int(e1); - } - j.end_array(); - } - if (meas_id_to_add_mod_list_present) { - j.start_array("measIdToAddModList"); - for (const auto& e1 : meas_id_to_add_mod_list) { - e1.to_json(j); - } - j.end_array(); - } - if (s_measure_cfg_present) { - j.write_fieldname("s-MeasureConfig"); - s_measure_cfg.to_json(j); - } - if (quant_cfg_present) { - j.write_fieldname("quantityConfig"); - quant_cfg.to_json(j); - } - if (meas_gap_cfg_present) { - j.write_fieldname("measGapConfig"); - meas_gap_cfg.to_json(j); - } - if (meas_gap_sharing_cfg_present) { - j.write_fieldname("measGapSharingConfig"); - meas_gap_sharing_cfg.to_json(j); + if (serving_cell_id_present) { + j.write_int("servingCellId", serving_cell_id); } + j.write_fieldname("referenceSignal"); + ref_sig.to_json(j); j.end_obj(); } -void meas_cfg_s::s_measure_cfg_c_::destroy_() {} -void meas_cfg_s::s_measure_cfg_c_::set(types::options e) +void srs_spatial_relation_info_s::ref_sig_c_::destroy_() +{ + switch (type_) { + case types::srs: + c.destroy(); + break; + default: + break; + } +} +void srs_spatial_relation_info_s::ref_sig_c_::set(types::options e) { destroy_(); type_ = e; + switch (type_) { + case types::ssb_idx: + break; + case types::csi_rs_idx: + break; + case types::srs: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); + } } -meas_cfg_s::s_measure_cfg_c_::s_measure_cfg_c_(const meas_cfg_s::s_measure_cfg_c_& other) +srs_spatial_relation_info_s::ref_sig_c_::ref_sig_c_(const srs_spatial_relation_info_s::ref_sig_c_& other) { type_ = other.type(); switch (type_) { - case types::ssb_rsrp: + case types::ssb_idx: c.init(other.c.get()); break; - case types::csi_rsrp: + case types::csi_rs_idx: c.init(other.c.get()); break; + case types::srs: + c.init(other.c.get()); + break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); } } -meas_cfg_s::s_measure_cfg_c_& meas_cfg_s::s_measure_cfg_c_::operator=(const meas_cfg_s::s_measure_cfg_c_& other) +srs_spatial_relation_info_s::ref_sig_c_& +srs_spatial_relation_info_s::ref_sig_c_::operator=(const srs_spatial_relation_info_s::ref_sig_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ssb_rsrp: + case types::ssb_idx: c.set(other.c.get()); break; - case types::csi_rsrp: + case types::csi_rs_idx: c.set(other.c.get()); break; + case types::srs: + c.set(other.c.get()); + break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); } return *this; } -void meas_cfg_s::s_measure_cfg_c_::to_json(json_writer& j) const +void srs_spatial_relation_info_s::ref_sig_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ssb_rsrp: - j.write_int("ssb-RSRP", c.get()); + case types::ssb_idx: + j.write_int("ssb-Index", c.get()); break; - case types::csi_rsrp: - j.write_int("csi-RSRP", c.get()); + case types::csi_rs_idx: + j.write_int("csi-RS-Index", c.get()); + break; + case types::srs: + j.write_fieldname("srs"); + j.start_obj(); + j.write_int("resourceId", c.get().res_id); + j.write_int("uplinkBWP", c.get().ul_bwp); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); } j.end_obj(); } -SRSASN_CODE meas_cfg_s::s_measure_cfg_c_::pack(bit_ref& bref) const +SRSASN_CODE srs_spatial_relation_info_s::ref_sig_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ssb_rsrp: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + case types::ssb_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); break; - case types::csi_rsrp: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + case types::csi_rs_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + break; + case types::srs: + HANDLE_CODE(pack_integer(bref, c.get().res_id, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_integer(bref, c.get().ul_bwp, (uint8_t)0u, (uint8_t)4u)); break; default: - log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE meas_cfg_s::s_measure_cfg_c_::unpack(cbit_ref& bref) +SRSASN_CODE srs_spatial_relation_info_s::ref_sig_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ssb_rsrp: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + case types::ssb_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); break; - case types::csi_rsrp: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + case types::csi_rs_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + break; + case types::srs: + HANDLE_CODE(unpack_integer(c.get().res_id, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_integer(c.get().ul_bwp, bref, (uint8_t)0u, (uint8_t)4u)); break; default: - log_invalid_choice_id(type_, "meas_cfg_s::s_measure_cfg_c_"); + log_invalid_choice_id(type_, "srs_spatial_relation_info_s::ref_sig_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string meas_cfg_s::s_measure_cfg_c_::types_opts::to_string() const +std::string srs_spatial_relation_info_s::ref_sig_c_::types_opts::to_string() const { - static const char* options[] = {"ssb-RSRP", "csi-RSRP"}; - return convert_enum_idx(options, 2, value, "meas_cfg_s::s_measure_cfg_c_::types"); + static const char* options[] = {"ssb-Index", "csi-RS-Index", "srs"}; + return convert_enum_idx(options, 3, value, "srs_spatial_relation_info_s::ref_sig_c_::types"); } -// RRCReconfiguration-v1530-IEs ::= SEQUENCE -SRSASN_CODE rrc_recfg_v1530_ies_s::pack(bit_ref& bref) const +// CG-UCI-OnPUSCH ::= CHOICE +void cg_uci_on_pusch_c::destroy_() { - HANDLE_CODE(bref.pack(master_cell_group_present, 1)); - HANDLE_CODE(bref.pack(full_cfg_present, 1)); - HANDLE_CODE(bref.pack(ded_nas_msg_list_present, 1)); - HANDLE_CODE(bref.pack(master_key_upd_present, 1)); - HANDLE_CODE(bref.pack(ded_sib1_delivery_present, 1)); - HANDLE_CODE(bref.pack(ded_sys_info_delivery_present, 1)); - HANDLE_CODE(bref.pack(other_cfg_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (master_cell_group_present) { - HANDLE_CODE(master_cell_group.pack(bref)); - } - if (ded_nas_msg_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ded_nas_msg_list, 1, 29)); - } - if (master_key_upd_present) { - HANDLE_CODE(master_key_upd.pack(bref)); - } - if (ded_sib1_delivery_present) { - HANDLE_CODE(ded_sib1_delivery.pack(bref)); - } - if (ded_sys_info_delivery_present) { - HANDLE_CODE(ded_sys_info_delivery.pack(bref)); - } - if (other_cfg_present) { - HANDLE_CODE(other_cfg.pack(bref)); - } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.pack(bref)); + switch (type_) { + case types::dynamic_type: + c.destroy(); + break; + case types::semi_static: + c.destroy(); + break; + default: + break; } - - return SRSASN_SUCCESS; } -SRSASN_CODE rrc_recfg_v1530_ies_s::unpack(cbit_ref& bref) +void cg_uci_on_pusch_c::set(types::options e) { - HANDLE_CODE(bref.unpack(master_cell_group_present, 1)); - HANDLE_CODE(bref.unpack(full_cfg_present, 1)); - HANDLE_CODE(bref.unpack(ded_nas_msg_list_present, 1)); - HANDLE_CODE(bref.unpack(master_key_upd_present, 1)); - HANDLE_CODE(bref.unpack(ded_sib1_delivery_present, 1)); - HANDLE_CODE(bref.unpack(ded_sys_info_delivery_present, 1)); - HANDLE_CODE(bref.unpack(other_cfg_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (master_cell_group_present) { - HANDLE_CODE(master_cell_group.unpack(bref)); - } - if (ded_nas_msg_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ded_nas_msg_list, bref, 1, 29)); - } - if (master_key_upd_present) { - HANDLE_CODE(master_key_upd.unpack(bref)); - } - if (ded_sib1_delivery_present) { - HANDLE_CODE(ded_sib1_delivery.unpack(bref)); + destroy_(); + type_ = e; + switch (type_) { + case types::dynamic_type: + c.init(); + break; + case types::semi_static: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); } - if (ded_sys_info_delivery_present) { - HANDLE_CODE(ded_sys_info_delivery.unpack(bref)); +} +cg_uci_on_pusch_c::cg_uci_on_pusch_c(const cg_uci_on_pusch_c& other) +{ + type_ = other.type(); + switch (type_) { + case types::dynamic_type: + c.init(other.c.get()); + break; + case types::semi_static: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); } - if (other_cfg_present) { - HANDLE_CODE(other_cfg.unpack(bref)); +} +cg_uci_on_pusch_c& cg_uci_on_pusch_c::operator=(const cg_uci_on_pusch_c& other) +{ + if (this == &other) { + return *this; } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.unpack(bref)); + set(other.type()); + switch (type_) { + case types::dynamic_type: + c.set(other.c.get()); + break; + case types::semi_static: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); } - return SRSASN_SUCCESS; + return *this; } -void rrc_recfg_v1530_ies_s::to_json(json_writer& j) const +void cg_uci_on_pusch_c::to_json(json_writer& j) const { j.start_obj(); - if (master_cell_group_present) { - j.write_str("masterCellGroup", master_cell_group.to_string()); - } - if (full_cfg_present) { - j.write_str("fullConfig", "true"); - } - if (ded_nas_msg_list_present) { - j.start_array("dedicatedNAS-MessageList"); - for (const auto& e1 : ded_nas_msg_list) { - j.write_str(e1.to_string()); - } - j.end_array(); - } - if (master_key_upd_present) { - j.write_fieldname("masterKeyUpdate"); - master_key_upd.to_json(j); - } - if (ded_sib1_delivery_present) { - j.write_str("dedicatedSIB1-Delivery", ded_sib1_delivery.to_string()); - } - if (ded_sys_info_delivery_present) { - j.write_str("dedicatedSystemInformationDelivery", ded_sys_info_delivery.to_string()); + switch (type_) { + case types::dynamic_type: + j.start_array("dynamic"); + for (const auto& e1 : c.get()) { + e1.to_json(j); + } + j.end_array(); + break; + case types::semi_static: + j.write_fieldname("semiStatic"); + c.get().to_json(j); + break; + default: + log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); } - if (other_cfg_present) { - j.write_fieldname("otherConfig"); - other_cfg.to_json(j); + j.end_obj(); +} +SRSASN_CODE cg_uci_on_pusch_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::dynamic_type: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 4)); + break; + case types::semi_static: + HANDLE_CODE(c.get().pack(bref)); + break; + default: + log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + return SRSASN_ERROR_ENCODE_FAIL; } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - non_crit_ext.to_json(j); + return SRSASN_SUCCESS; +} +SRSASN_CODE cg_uci_on_pusch_c::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::dynamic_type: + HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 4)); + break; + case types::semi_static: + HANDLE_CODE(c.get().unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "cg_uci_on_pusch_c"); + return SRSASN_ERROR_DECODE_FAIL; } - j.end_obj(); + return SRSASN_SUCCESS; } -// RRCRelease-v1540-IEs ::= SEQUENCE -SRSASN_CODE rrc_release_v1540_ies_s::pack(bit_ref& bref) const +std::string cg_uci_on_pusch_c::types_opts::to_string() const { - HANDLE_CODE(bref.pack(wait_time_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + static const char* options[] = {"dynamic", "semiStatic"}; + return convert_enum_idx(options, 2, value, "cg_uci_on_pusch_c::types"); +} - if (wait_time_present) { - HANDLE_CODE(pack_integer(bref, wait_time, (uint8_t)1u, (uint8_t)16u)); +// DMRS-UplinkConfig ::= SEQUENCE +SRSASN_CODE dmrs_ul_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(dmrs_type_present, 1)); + HANDLE_CODE(bref.pack(dmrs_add_position_present, 1)); + HANDLE_CODE(bref.pack(phase_tracking_rs_present, 1)); + HANDLE_CODE(bref.pack(max_len_present, 1)); + HANDLE_CODE(bref.pack(transform_precoding_disabled_present, 1)); + HANDLE_CODE(bref.pack(transform_precoding_enabled_present, 1)); + + if (dmrs_add_position_present) { + HANDLE_CODE(dmrs_add_position.pack(bref)); + } + if (phase_tracking_rs_present) { + HANDLE_CODE(phase_tracking_rs.pack(bref)); + } + if (transform_precoding_disabled_present) { + bref.pack(transform_precoding_disabled.ext, 1); + HANDLE_CODE(bref.pack(transform_precoding_disabled.scrambling_id0_present, 1)); + HANDLE_CODE(bref.pack(transform_precoding_disabled.scrambling_id1_present, 1)); + if (transform_precoding_disabled.scrambling_id0_present) { + HANDLE_CODE(pack_integer(bref, transform_precoding_disabled.scrambling_id0, (uint32_t)0u, (uint32_t)65535u)); + } + if (transform_precoding_disabled.scrambling_id1_present) { + HANDLE_CODE(pack_integer(bref, transform_precoding_disabled.scrambling_id1, (uint32_t)0u, (uint32_t)65535u)); + } + } + if (transform_precoding_enabled_present) { + bref.pack(transform_precoding_enabled.ext, 1); + HANDLE_CODE(bref.pack(transform_precoding_enabled.npusch_id_present, 1)); + HANDLE_CODE(bref.pack(transform_precoding_enabled.seq_group_hop_present, 1)); + HANDLE_CODE(bref.pack(transform_precoding_enabled.seq_hop_present, 1)); + if (transform_precoding_enabled.npusch_id_present) { + HANDLE_CODE(pack_integer(bref, transform_precoding_enabled.npusch_id, (uint16_t)0u, (uint16_t)1007u)); + } } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_release_v1540_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE dmrs_ul_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(wait_time_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(dmrs_type_present, 1)); + HANDLE_CODE(bref.unpack(dmrs_add_position_present, 1)); + HANDLE_CODE(bref.unpack(phase_tracking_rs_present, 1)); + HANDLE_CODE(bref.unpack(max_len_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoding_disabled_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoding_enabled_present, 1)); - if (wait_time_present) { - HANDLE_CODE(unpack_integer(wait_time, bref, (uint8_t)1u, (uint8_t)16u)); + if (dmrs_add_position_present) { + HANDLE_CODE(dmrs_add_position.unpack(bref)); + } + if (phase_tracking_rs_present) { + HANDLE_CODE(phase_tracking_rs.unpack(bref)); + } + if (transform_precoding_disabled_present) { + bref.unpack(transform_precoding_disabled.ext, 1); + HANDLE_CODE(bref.unpack(transform_precoding_disabled.scrambling_id0_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoding_disabled.scrambling_id1_present, 1)); + if (transform_precoding_disabled.scrambling_id0_present) { + HANDLE_CODE(unpack_integer(transform_precoding_disabled.scrambling_id0, bref, (uint32_t)0u, (uint32_t)65535u)); + } + if (transform_precoding_disabled.scrambling_id1_present) { + HANDLE_CODE(unpack_integer(transform_precoding_disabled.scrambling_id1, bref, (uint32_t)0u, (uint32_t)65535u)); + } + } + if (transform_precoding_enabled_present) { + bref.unpack(transform_precoding_enabled.ext, 1); + HANDLE_CODE(bref.unpack(transform_precoding_enabled.npusch_id_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoding_enabled.seq_group_hop_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoding_enabled.seq_hop_present, 1)); + if (transform_precoding_enabled.npusch_id_present) { + HANDLE_CODE(unpack_integer(transform_precoding_enabled.npusch_id, bref, (uint16_t)0u, (uint16_t)1007u)); + } } return SRSASN_SUCCESS; } -void rrc_release_v1540_ies_s::to_json(json_writer& j) const +void dmrs_ul_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (wait_time_present) { - j.write_int("waitTime", wait_time); + if (dmrs_type_present) { + j.write_str("dmrs-Type", "type2"); } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); + if (dmrs_add_position_present) { + j.write_str("dmrs-AdditionalPosition", dmrs_add_position.to_string()); + } + if (phase_tracking_rs_present) { + j.write_fieldname("phaseTrackingRS"); + phase_tracking_rs.to_json(j); + } + if (max_len_present) { + j.write_str("maxLength", "len2"); + } + if (transform_precoding_disabled_present) { + j.write_fieldname("transformPrecodingDisabled"); + j.start_obj(); + if (transform_precoding_disabled.scrambling_id0_present) { + j.write_int("scramblingID0", transform_precoding_disabled.scrambling_id0); + } + if (transform_precoding_disabled.scrambling_id1_present) { + j.write_int("scramblingID1", transform_precoding_disabled.scrambling_id1); + } + j.end_obj(); + } + if (transform_precoding_enabled_present) { + j.write_fieldname("transformPrecodingEnabled"); j.start_obj(); + if (transform_precoding_enabled.npusch_id_present) { + j.write_int("nPUSCH-Identity", transform_precoding_enabled.npusch_id); + } + if (transform_precoding_enabled.seq_group_hop_present) { + j.write_str("sequenceGroupHopping", "disabled"); + } + if (transform_precoding_enabled.seq_hop_present) { + j.write_str("sequenceHopping", "enabled"); + } j.end_obj(); } j.end_obj(); } -// RedirectedCarrierInfo ::= CHOICE -void redirected_carrier_info_c::destroy_() +std::string dmrs_ul_cfg_s::dmrs_add_position_opts::to_string() const +{ + static const char* options[] = {"pos0", "pos1", "pos3"}; + return convert_enum_idx(options, 3, value, "dmrs_ul_cfg_s::dmrs_add_position_e_"); +} +uint8_t dmrs_ul_cfg_s::dmrs_add_position_opts::to_number() const +{ + static const uint8_t options[] = {0, 1, 3}; + return map_enum_number(options, 3, value, "dmrs_ul_cfg_s::dmrs_add_position_e_"); +} + +// PRACH-ResourceDedicatedBFR ::= CHOICE +void prach_res_ded_bfr_c::destroy_() { switch (type_) { - case types::nr: - c.destroy(); + case types::ssb: + c.destroy(); break; - case types::eutra: - c.destroy(); + case types::csi_rs: + c.destroy(); break; default: break; } } -void redirected_carrier_info_c::set(types::options e) +void prach_res_ded_bfr_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::nr: - c.init(); + case types::ssb: + c.init(); break; - case types::eutra: - c.init(); + case types::csi_rs: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "redirected_carrier_info_c"); + log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); } } -redirected_carrier_info_c::redirected_carrier_info_c(const redirected_carrier_info_c& other) +prach_res_ded_bfr_c::prach_res_ded_bfr_c(const prach_res_ded_bfr_c& other) { type_ = other.type(); switch (type_) { - case types::nr: - c.init(other.c.get()); + case types::ssb: + c.init(other.c.get()); break; - case types::eutra: - c.init(other.c.get()); + case types::csi_rs: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "redirected_carrier_info_c"); + log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); } } -redirected_carrier_info_c& redirected_carrier_info_c::operator=(const redirected_carrier_info_c& other) +prach_res_ded_bfr_c& prach_res_ded_bfr_c::operator=(const prach_res_ded_bfr_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::nr: - c.set(other.c.get()); + case types::ssb: + c.set(other.c.get()); break; - case types::eutra: - c.set(other.c.get()); + case types::csi_rs: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "redirected_carrier_info_c"); + log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); } return *this; } -void redirected_carrier_info_c::to_json(json_writer& j) const +void prach_res_ded_bfr_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::nr: - j.write_fieldname("nr"); - c.get().to_json(j); + case types::ssb: + j.write_fieldname("ssb"); + c.get().to_json(j); break; - case types::eutra: - j.write_fieldname("eutra"); - c.get().to_json(j); + case types::csi_rs: + j.write_fieldname("csi-RS"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "redirected_carrier_info_c"); + log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); } j.end_obj(); } -SRSASN_CODE redirected_carrier_info_c::pack(bit_ref& bref) const +SRSASN_CODE prach_res_ded_bfr_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::nr: - HANDLE_CODE(c.get().pack(bref)); + case types::ssb: + HANDLE_CODE(c.get().pack(bref)); break; - case types::eutra: - HANDLE_CODE(c.get().pack(bref)); + case types::csi_rs: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "redirected_carrier_info_c"); + log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE redirected_carrier_info_c::unpack(cbit_ref& bref) +SRSASN_CODE prach_res_ded_bfr_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::nr: - HANDLE_CODE(c.get().unpack(bref)); + case types::ssb: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::eutra: - HANDLE_CODE(c.get().unpack(bref)); + case types::csi_rs: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "redirected_carrier_info_c"); + log_invalid_choice_id(type_, "prach_res_ded_bfr_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string redirected_carrier_info_c::types_opts::to_string() const +std::string prach_res_ded_bfr_c::types_opts::to_string() const { - static const char* options[] = {"nr", "eutra"}; - return convert_enum_idx(options, 2, value, "redirected_carrier_info_c::types"); + static const char* options[] = {"ssb", "csi-RS"}; + return convert_enum_idx(options, 2, value, "prach_res_ded_bfr_c::types"); } -// SecurityConfigSMC ::= SEQUENCE -SRSASN_CODE security_cfg_smc_s::pack(bit_ref& bref) const +// PUCCH-FormatConfig ::= SEQUENCE +SRSASN_CODE pucch_format_cfg_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(security_algorithm_cfg.pack(bref)); + HANDLE_CODE(bref.pack(interslot_freq_hop_present, 1)); + HANDLE_CODE(bref.pack(add_dmrs_present, 1)); + HANDLE_CODE(bref.pack(max_code_rate_present, 1)); + HANDLE_CODE(bref.pack(nrof_slots_present, 1)); + HANDLE_CODE(bref.pack(pi2_bpsk_present, 1)); + HANDLE_CODE(bref.pack(simul_harq_ack_csi_present, 1)); + + if (max_code_rate_present) { + HANDLE_CODE(max_code_rate.pack(bref)); + } + if (nrof_slots_present) { + HANDLE_CODE(nrof_slots.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE security_cfg_smc_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_format_cfg_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(security_algorithm_cfg.unpack(bref)); + HANDLE_CODE(bref.unpack(interslot_freq_hop_present, 1)); + HANDLE_CODE(bref.unpack(add_dmrs_present, 1)); + HANDLE_CODE(bref.unpack(max_code_rate_present, 1)); + HANDLE_CODE(bref.unpack(nrof_slots_present, 1)); + HANDLE_CODE(bref.unpack(pi2_bpsk_present, 1)); + HANDLE_CODE(bref.unpack(simul_harq_ack_csi_present, 1)); + + if (max_code_rate_present) { + HANDLE_CODE(max_code_rate.unpack(bref)); + } + if (nrof_slots_present) { + HANDLE_CODE(nrof_slots.unpack(bref)); + } return SRSASN_SUCCESS; } -void security_cfg_smc_s::to_json(json_writer& j) const +void pucch_format_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("securityAlgorithmConfig"); - security_algorithm_cfg.to_json(j); - j.end_obj(); -} - -// SuspendConfig ::= SEQUENCE -SRSASN_CODE suspend_cfg_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ran_notif_area_info_present, 1)); - HANDLE_CODE(bref.pack(t380_present, 1)); - - HANDLE_CODE(full_i_rnti.pack(bref)); - HANDLE_CODE(short_i_rnti.pack(bref)); - HANDLE_CODE(ran_paging_cycle.pack(bref)); - if (ran_notif_area_info_present) { - HANDLE_CODE(ran_notif_area_info.pack(bref)); + if (interslot_freq_hop_present) { + j.write_str("interslotFrequencyHopping", "enabled"); } - if (t380_present) { - HANDLE_CODE(t380.pack(bref)); + if (add_dmrs_present) { + j.write_str("additionalDMRS", "true"); } - HANDLE_CODE(pack_integer(bref, next_hop_chaining_count, (uint8_t)0u, (uint8_t)7u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE suspend_cfg_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ran_notif_area_info_present, 1)); - HANDLE_CODE(bref.unpack(t380_present, 1)); - - HANDLE_CODE(full_i_rnti.unpack(bref)); - HANDLE_CODE(short_i_rnti.unpack(bref)); - HANDLE_CODE(ran_paging_cycle.unpack(bref)); - if (ran_notif_area_info_present) { - HANDLE_CODE(ran_notif_area_info.unpack(bref)); + if (max_code_rate_present) { + j.write_str("maxCodeRate", max_code_rate.to_string()); } - if (t380_present) { - HANDLE_CODE(t380.unpack(bref)); + if (nrof_slots_present) { + j.write_str("nrofSlots", nrof_slots.to_string()); } - HANDLE_CODE(unpack_integer(next_hop_chaining_count, bref, (uint8_t)0u, (uint8_t)7u)); - - return SRSASN_SUCCESS; -} -void suspend_cfg_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_str("fullI-RNTI", full_i_rnti.to_string()); - j.write_str("shortI-RNTI", short_i_rnti.to_string()); - j.write_str("ran-PagingCycle", ran_paging_cycle.to_string()); - if (ran_notif_area_info_present) { - j.write_fieldname("ran-NotificationAreaInfo"); - ran_notif_area_info.to_json(j); + if (pi2_bpsk_present) { + j.write_str("pi2BPSK", "enabled"); } - if (t380_present) { - j.write_str("t380", t380.to_string()); + if (simul_harq_ack_csi_present) { + j.write_str("simultaneousHARQ-ACK-CSI", "true"); } - j.write_int("nextHopChainingCount", next_hop_chaining_count); j.end_obj(); } -// CounterCheck-IEs ::= SEQUENCE -SRSASN_CODE counter_check_ies_s::pack(bit_ref& bref) const +std::string pucch_format_cfg_s::nrof_slots_opts::to_string() const { - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + static const char* options[] = {"n2", "n4", "n8"}; + return convert_enum_idx(options, 3, value, "pucch_format_cfg_s::nrof_slots_e_"); +} +uint8_t pucch_format_cfg_s::nrof_slots_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 8}; + return map_enum_number(options, 3, value, "pucch_format_cfg_s::nrof_slots_e_"); +} - HANDLE_CODE(pack_dyn_seq_of(bref, drb_count_msb_info_list, 1, 29)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); +// PUCCH-PowerControl ::= SEQUENCE +SRSASN_CODE pucch_pwr_ctrl_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(delta_f_pucch_f0_present, 1)); + HANDLE_CODE(bref.pack(delta_f_pucch_f1_present, 1)); + HANDLE_CODE(bref.pack(delta_f_pucch_f2_present, 1)); + HANDLE_CODE(bref.pack(delta_f_pucch_f3_present, 1)); + HANDLE_CODE(bref.pack(delta_f_pucch_f4_present, 1)); + HANDLE_CODE(bref.pack(p0_set_present, 1)); + HANDLE_CODE(bref.pack(pathloss_ref_rss_present, 1)); + HANDLE_CODE(bref.pack(two_pucch_pc_adjustment_states_present, 1)); + + if (delta_f_pucch_f0_present) { + HANDLE_CODE(pack_integer(bref, delta_f_pucch_f0, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f1_present) { + HANDLE_CODE(pack_integer(bref, delta_f_pucch_f1, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f2_present) { + HANDLE_CODE(pack_integer(bref, delta_f_pucch_f2, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f3_present) { + HANDLE_CODE(pack_integer(bref, delta_f_pucch_f3, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f4_present) { + HANDLE_CODE(pack_integer(bref, delta_f_pucch_f4, (int8_t)-16, (int8_t)15)); + } + if (p0_set_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, p0_set, 1, 8)); + } + if (pathloss_ref_rss_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, pathloss_ref_rss, 1, 4)); } return SRSASN_SUCCESS; } -SRSASN_CODE counter_check_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_pwr_ctrl_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(delta_f_pucch_f0_present, 1)); + HANDLE_CODE(bref.unpack(delta_f_pucch_f1_present, 1)); + HANDLE_CODE(bref.unpack(delta_f_pucch_f2_present, 1)); + HANDLE_CODE(bref.unpack(delta_f_pucch_f3_present, 1)); + HANDLE_CODE(bref.unpack(delta_f_pucch_f4_present, 1)); + HANDLE_CODE(bref.unpack(p0_set_present, 1)); + HANDLE_CODE(bref.unpack(pathloss_ref_rss_present, 1)); + HANDLE_CODE(bref.unpack(two_pucch_pc_adjustment_states_present, 1)); - HANDLE_CODE(unpack_dyn_seq_of(drb_count_msb_info_list, bref, 1, 29)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + if (delta_f_pucch_f0_present) { + HANDLE_CODE(unpack_integer(delta_f_pucch_f0, bref, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f1_present) { + HANDLE_CODE(unpack_integer(delta_f_pucch_f1, bref, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f2_present) { + HANDLE_CODE(unpack_integer(delta_f_pucch_f2, bref, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f3_present) { + HANDLE_CODE(unpack_integer(delta_f_pucch_f3, bref, (int8_t)-16, (int8_t)15)); + } + if (delta_f_pucch_f4_present) { + HANDLE_CODE(unpack_integer(delta_f_pucch_f4, bref, (int8_t)-16, (int8_t)15)); + } + if (p0_set_present) { + HANDLE_CODE(unpack_dyn_seq_of(p0_set, bref, 1, 8)); + } + if (pathloss_ref_rss_present) { + HANDLE_CODE(unpack_dyn_seq_of(pathloss_ref_rss, bref, 1, 4)); } return SRSASN_SUCCESS; } -void counter_check_ies_s::to_json(json_writer& j) const +void pucch_pwr_ctrl_s::to_json(json_writer& j) const { j.start_obj(); - j.start_array("drb-CountMSB-InfoList"); - for (const auto& e1 : drb_count_msb_info_list) { - e1.to_json(j); + if (delta_f_pucch_f0_present) { + j.write_int("deltaF-PUCCH-f0", delta_f_pucch_f0); } - j.end_array(); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + if (delta_f_pucch_f1_present) { + j.write_int("deltaF-PUCCH-f1", delta_f_pucch_f1); } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + if (delta_f_pucch_f2_present) { + j.write_int("deltaF-PUCCH-f2", delta_f_pucch_f2); + } + if (delta_f_pucch_f3_present) { + j.write_int("deltaF-PUCCH-f3", delta_f_pucch_f3); + } + if (delta_f_pucch_f4_present) { + j.write_int("deltaF-PUCCH-f4", delta_f_pucch_f4); + } + if (p0_set_present) { + j.start_array("p0-Set"); + for (const auto& e1 : p0_set) { + e1.to_json(j); + } + j.end_array(); + } + if (pathloss_ref_rss_present) { + j.start_array("pathlossReferenceRSs"); + for (const auto& e1 : pathloss_ref_rss) { + e1.to_json(j); + } + j.end_array(); + } + if (two_pucch_pc_adjustment_states_present) { + j.write_str("twoPUCCH-PC-AdjustmentStates", "twoStates"); } j.end_obj(); } -// DLInformationTransfer-IEs ::= SEQUENCE -SRSASN_CODE dl_info_transfer_ies_s::pack(bit_ref& bref) const +// PUCCH-Resource ::= SEQUENCE +SRSASN_CODE pucch_res_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(ded_nas_msg_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(intra_slot_freq_hop_present, 1)); + HANDLE_CODE(bref.pack(second_hop_prb_present, 1)); - if (ded_nas_msg_present) { - HANDLE_CODE(ded_nas_msg.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); + HANDLE_CODE(pack_integer(bref, pucch_res_id, (uint8_t)0u, (uint8_t)127u)); + HANDLE_CODE(pack_integer(bref, start_prb, (uint16_t)0u, (uint16_t)274u)); + if (second_hop_prb_present) { + HANDLE_CODE(pack_integer(bref, second_hop_prb, (uint16_t)0u, (uint16_t)274u)); } + HANDLE_CODE(format.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE dl_info_transfer_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_res_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(ded_nas_msg_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(intra_slot_freq_hop_present, 1)); + HANDLE_CODE(bref.unpack(second_hop_prb_present, 1)); - if (ded_nas_msg_present) { - HANDLE_CODE(ded_nas_msg.unpack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + HANDLE_CODE(unpack_integer(pucch_res_id, bref, (uint8_t)0u, (uint8_t)127u)); + HANDLE_CODE(unpack_integer(start_prb, bref, (uint16_t)0u, (uint16_t)274u)); + if (second_hop_prb_present) { + HANDLE_CODE(unpack_integer(second_hop_prb, bref, (uint16_t)0u, (uint16_t)274u)); } + HANDLE_CODE(format.unpack(bref)); return SRSASN_SUCCESS; } -void dl_info_transfer_ies_s::to_json(json_writer& j) const +void pucch_res_s::to_json(json_writer& j) const { j.start_obj(); - if (ded_nas_msg_present) { - j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + j.write_int("pucch-ResourceId", pucch_res_id); + j.write_int("startingPRB", start_prb); + if (intra_slot_freq_hop_present) { + j.write_str("intraSlotFrequencyHopping", "enabled"); } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + if (second_hop_prb_present) { + j.write_int("secondHopPRB", second_hop_prb); } + j.write_fieldname("format"); + format.to_json(j); j.end_obj(); } -// MobilityFromNRCommand-IEs ::= SEQUENCE -SRSASN_CODE mob_from_nr_cmd_ies_s::pack(bit_ref& bref) const +void pucch_res_s::format_c_::destroy_() { - HANDLE_CODE(bref.pack(nas_security_param_from_nr_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - HANDLE_CODE(target_rat_type.pack(bref)); - HANDLE_CODE(target_rat_msg_container.pack(bref)); - if (nas_security_param_from_nr_present) { - HANDLE_CODE(nas_security_param_from_nr.pack(bref)); + switch (type_) { + case types::format0: + c.destroy(); + break; + case types::format1: + c.destroy(); + break; + case types::format2: + c.destroy(); + break; + case types::format3: + c.destroy(); + break; + case types::format4: + c.destroy(); + break; + default: + break; } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); +} +void pucch_res_s::format_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::format0: + c.init(); + break; + case types::format1: + c.init(); + break; + case types::format2: + c.init(); + break; + case types::format3: + c.init(); + break; + case types::format4: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pucch_res_s::format_c_"); } - - return SRSASN_SUCCESS; } -SRSASN_CODE mob_from_nr_cmd_ies_s::unpack(cbit_ref& bref) +pucch_res_s::format_c_::format_c_(const pucch_res_s::format_c_& other) { - HANDLE_CODE(bref.unpack(nas_security_param_from_nr_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(target_rat_type.unpack(bref)); - HANDLE_CODE(target_rat_msg_container.unpack(bref)); - if (nas_security_param_from_nr_present) { - HANDLE_CODE(nas_security_param_from_nr.unpack(bref)); + type_ = other.type(); + switch (type_) { + case types::format0: + c.init(other.c.get()); + break; + case types::format1: + c.init(other.c.get()); + break; + case types::format2: + c.init(other.c.get()); + break; + case types::format3: + c.init(other.c.get()); + break; + case types::format4: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pucch_res_s::format_c_"); } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); +} +pucch_res_s::format_c_& pucch_res_s::format_c_::operator=(const pucch_res_s::format_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::format0: + c.set(other.c.get()); + break; + case types::format1: + c.set(other.c.get()); + break; + case types::format2: + c.set(other.c.get()); + break; + case types::format3: + c.set(other.c.get()); + break; + case types::format4: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "pucch_res_s::format_c_"); } - return SRSASN_SUCCESS; + return *this; } -void mob_from_nr_cmd_ies_s::to_json(json_writer& j) const +void pucch_res_s::format_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_str("targetRAT-Type", target_rat_type.to_string()); - j.write_str("targetRAT-MessageContainer", target_rat_msg_container.to_string()); - if (nas_security_param_from_nr_present) { - j.write_str("nas-SecurityParamFromNR", nas_security_param_from_nr.to_string()); + switch (type_) { + case types::format0: + j.write_fieldname("format0"); + c.get().to_json(j); + break; + case types::format1: + j.write_fieldname("format1"); + c.get().to_json(j); + break; + case types::format2: + j.write_fieldname("format2"); + c.get().to_json(j); + break; + case types::format3: + j.write_fieldname("format3"); + c.get().to_json(j); + break; + case types::format4: + j.write_fieldname("format4"); + c.get().to_json(j); + break; + default: + log_invalid_choice_id(type_, "pucch_res_s::format_c_"); } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + j.end_obj(); +} +SRSASN_CODE pucch_res_s::format_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::format0: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::format1: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::format2: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::format3: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::format4: + HANDLE_CODE(c.get().pack(bref)); + break; + default: + log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + return SRSASN_SUCCESS; +} +SRSASN_CODE pucch_res_s::format_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::format0: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::format1: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::format2: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::format3: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::format4: + HANDLE_CODE(c.get().unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "pucch_res_s::format_c_"); + return SRSASN_ERROR_DECODE_FAIL; } - j.end_obj(); + return SRSASN_SUCCESS; } -std::string mob_from_nr_cmd_ies_s::target_rat_type_opts::to_string() const +std::string pucch_res_s::format_c_::types_opts::to_string() const { - static const char* options[] = {"eutra", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 4, value, "mob_from_nr_cmd_ies_s::target_rat_type_e_"); + static const char* options[] = {"format0", "format1", "format2", "format3", "format4"}; + return convert_enum_idx(options, 5, value, "pucch_res_s::format_c_::types"); +} +uint8_t pucch_res_s::format_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {0, 1, 2, 3, 4}; + return map_enum_number(options, 5, value, "pucch_res_s::format_c_::types"); } -// RRCReconfiguration-IEs ::= SEQUENCE -SRSASN_CODE rrc_recfg_ies_s::pack(bit_ref& bref) const +// PUCCH-ResourceSet ::= SEQUENCE +SRSASN_CODE pucch_res_set_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(radio_bearer_cfg_present, 1)); - HANDLE_CODE(bref.pack(secondary_cell_group_present, 1)); - HANDLE_CODE(bref.pack(meas_cfg_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(max_payload_size_present, 1)); - if (radio_bearer_cfg_present) { - HANDLE_CODE(radio_bearer_cfg.pack(bref)); - } - if (secondary_cell_group_present) { - HANDLE_CODE(secondary_cell_group.pack(bref)); - } - if (meas_cfg_present) { - HANDLE_CODE(meas_cfg.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.pack(bref)); + HANDLE_CODE(pack_integer(bref, pucch_res_set_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pack_dyn_seq_of(bref, res_list, 1, 32, integer_packer(0, 127))); + if (max_payload_size_present) { + HANDLE_CODE(pack_integer(bref, max_payload_size, (uint16_t)4u, (uint16_t)256u)); } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_recfg_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_res_set_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(radio_bearer_cfg_present, 1)); - HANDLE_CODE(bref.unpack(secondary_cell_group_present, 1)); - HANDLE_CODE(bref.unpack(meas_cfg_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(max_payload_size_present, 1)); - if (radio_bearer_cfg_present) { - HANDLE_CODE(radio_bearer_cfg.unpack(bref)); - } - if (secondary_cell_group_present) { - HANDLE_CODE(secondary_cell_group.unpack(bref)); - } - if (meas_cfg_present) { - HANDLE_CODE(meas_cfg.unpack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.unpack(bref)); + HANDLE_CODE(unpack_integer(pucch_res_set_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(unpack_dyn_seq_of(res_list, bref, 1, 32, integer_packer(0, 127))); + if (max_payload_size_present) { + HANDLE_CODE(unpack_integer(max_payload_size, bref, (uint16_t)4u, (uint16_t)256u)); } return SRSASN_SUCCESS; } -void rrc_recfg_ies_s::to_json(json_writer& j) const +void pucch_res_set_s::to_json(json_writer& j) const { j.start_obj(); - if (radio_bearer_cfg_present) { - j.write_fieldname("radioBearerConfig"); - radio_bearer_cfg.to_json(j); + j.write_int("pucch-ResourceSetId", pucch_res_set_id); + j.start_array("resourceList"); + for (const auto& e1 : res_list) { + j.write_int(e1); } - if (secondary_cell_group_present) { - j.write_str("secondaryCellGroup", secondary_cell_group.to_string()); - } - if (meas_cfg_present) { - j.write_fieldname("measConfig"); - meas_cfg.to_json(j); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - non_crit_ext.to_json(j); - } - j.end_obj(); -} - -// RRCReestablishment-IEs ::= SEQUENCE -SRSASN_CODE rrc_reest_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - HANDLE_CODE(pack_integer(bref, next_hop_chaining_count, (uint8_t)0u, (uint8_t)7u)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_reest_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(unpack_integer(next_hop_chaining_count, bref, (uint8_t)0u, (uint8_t)7u)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void rrc_reest_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("nextHopChainingCount", next_hop_chaining_count); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// RRCRelease-IEs ::= SEQUENCE -SRSASN_CODE rrc_release_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(redirected_carrier_info_present, 1)); - HANDLE_CODE(bref.pack(cell_resel_priorities_present, 1)); - HANDLE_CODE(bref.pack(suspend_cfg_present, 1)); - HANDLE_CODE(bref.pack(depriorit_req_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (redirected_carrier_info_present) { - HANDLE_CODE(redirected_carrier_info.pack(bref)); - } - if (cell_resel_priorities_present) { - HANDLE_CODE(cell_resel_priorities.pack(bref)); - } - if (suspend_cfg_present) { - HANDLE_CODE(suspend_cfg.pack(bref)); - } - if (depriorit_req_present) { - HANDLE_CODE(depriorit_req.depriorit_type.pack(bref)); - HANDLE_CODE(depriorit_req.depriorit_timer.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_release_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(redirected_carrier_info_present, 1)); - HANDLE_CODE(bref.unpack(cell_resel_priorities_present, 1)); - HANDLE_CODE(bref.unpack(suspend_cfg_present, 1)); - HANDLE_CODE(bref.unpack(depriorit_req_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (redirected_carrier_info_present) { - HANDLE_CODE(redirected_carrier_info.unpack(bref)); - } - if (cell_resel_priorities_present) { - HANDLE_CODE(cell_resel_priorities.unpack(bref)); - } - if (suspend_cfg_present) { - HANDLE_CODE(suspend_cfg.unpack(bref)); - } - if (depriorit_req_present) { - HANDLE_CODE(depriorit_req.depriorit_type.unpack(bref)); - HANDLE_CODE(depriorit_req.depriorit_timer.unpack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void rrc_release_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (redirected_carrier_info_present) { - j.write_fieldname("redirectedCarrierInfo"); - redirected_carrier_info.to_json(j); - } - if (cell_resel_priorities_present) { - j.write_fieldname("cellReselectionPriorities"); - cell_resel_priorities.to_json(j); - } - if (suspend_cfg_present) { - j.write_fieldname("suspendConfig"); - suspend_cfg.to_json(j); - } - if (depriorit_req_present) { - j.write_fieldname("deprioritisationReq"); - j.start_obj(); - j.write_str("deprioritisationType", depriorit_req.depriorit_type.to_string()); - j.write_str("deprioritisationTimer", depriorit_req.depriorit_timer.to_string()); - j.end_obj(); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - non_crit_ext.to_json(j); - } - j.end_obj(); -} - -std::string rrc_release_ies_s::depriorit_req_s_::depriorit_type_opts::to_string() const -{ - static const char* options[] = {"frequency", "nr"}; - return convert_enum_idx(options, 2, value, "rrc_release_ies_s::depriorit_req_s_::depriorit_type_e_"); -} - -std::string rrc_release_ies_s::depriorit_req_s_::depriorit_timer_opts::to_string() const -{ - static const char* options[] = {"min5", "min10", "min15", "min30"}; - return convert_enum_idx(options, 4, value, "rrc_release_ies_s::depriorit_req_s_::depriorit_timer_e_"); -} -uint8_t rrc_release_ies_s::depriorit_req_s_::depriorit_timer_opts::to_number() const -{ - static const uint8_t options[] = {5, 10, 15, 30}; - return map_enum_number(options, 4, value, "rrc_release_ies_s::depriorit_req_s_::depriorit_timer_e_"); -} - -// RRCResume-IEs ::= SEQUENCE -SRSASN_CODE rrc_resume_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(radio_bearer_cfg_present, 1)); - HANDLE_CODE(bref.pack(master_cell_group_present, 1)); - HANDLE_CODE(bref.pack(meas_cfg_present, 1)); - HANDLE_CODE(bref.pack(full_cfg_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (radio_bearer_cfg_present) { - HANDLE_CODE(radio_bearer_cfg.pack(bref)); - } - if (master_cell_group_present) { - HANDLE_CODE(master_cell_group.pack(bref)); - } - if (meas_cfg_present) { - HANDLE_CODE(meas_cfg.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_resume_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(radio_bearer_cfg_present, 1)); - HANDLE_CODE(bref.unpack(master_cell_group_present, 1)); - HANDLE_CODE(bref.unpack(meas_cfg_present, 1)); - HANDLE_CODE(bref.unpack(full_cfg_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (radio_bearer_cfg_present) { - HANDLE_CODE(radio_bearer_cfg.unpack(bref)); - } - if (master_cell_group_present) { - HANDLE_CODE(master_cell_group.unpack(bref)); - } - if (meas_cfg_present) { - HANDLE_CODE(meas_cfg.unpack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void rrc_resume_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (radio_bearer_cfg_present) { - j.write_fieldname("radioBearerConfig"); - radio_bearer_cfg.to_json(j); - } - if (master_cell_group_present) { - j.write_str("masterCellGroup", master_cell_group.to_string()); - } - if (meas_cfg_present) { - j.write_fieldname("measConfig"); - meas_cfg.to_json(j); - } - if (full_cfg_present) { - j.write_str("fullConfig", "true"); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// SecurityModeCommand-IEs ::= SEQUENCE -SRSASN_CODE security_mode_cmd_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - HANDLE_CODE(security_cfg_smc.pack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE security_mode_cmd_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(security_cfg_smc.unpack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void security_mode_cmd_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("securityConfigSMC"); - security_cfg_smc.to_json(j); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + j.end_array(); + if (max_payload_size_present) { + j.write_int("maxPayloadSize", max_payload_size); } j.end_obj(); } -// UECapabilityEnquiry-IEs ::= SEQUENCE -SRSASN_CODE ue_cap_enquiry_ies_s::pack(bit_ref& bref) const +// PUCCH-SpatialRelationInfo ::= SEQUENCE +SRSASN_CODE pucch_spatial_relation_info_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(serving_cell_id_present, 1)); - HANDLE_CODE(pack_dyn_seq_of(bref, ue_cap_rat_request_list, 1, 8)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); + HANDLE_CODE(pack_integer(bref, pucch_spatial_relation_info_id, (uint8_t)1u, (uint8_t)8u)); + if (serving_cell_id_present) { + HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); } + HANDLE_CODE(ref_sig.pack(bref)); + HANDLE_CODE(pack_integer(bref, pucch_pathloss_ref_rs_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pack_integer(bref, p0_pucch_id, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(closed_loop_idx.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ue_cap_enquiry_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_spatial_relation_info_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(serving_cell_id_present, 1)); - HANDLE_CODE(unpack_dyn_seq_of(ue_cap_rat_request_list, bref, 1, 8)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + HANDLE_CODE(unpack_integer(pucch_spatial_relation_info_id, bref, (uint8_t)1u, (uint8_t)8u)); + if (serving_cell_id_present) { + HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); } + HANDLE_CODE(ref_sig.unpack(bref)); + HANDLE_CODE(unpack_integer(pucch_pathloss_ref_rs_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(unpack_integer(p0_pucch_id, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(closed_loop_idx.unpack(bref)); return SRSASN_SUCCESS; } -void ue_cap_enquiry_ies_s::to_json(json_writer& j) const +void pucch_spatial_relation_info_s::to_json(json_writer& j) const { j.start_obj(); - j.start_array("ue-CapabilityRAT-RequestList"); - for (const auto& e1 : ue_cap_rat_request_list) { - e1.to_json(j); - } - j.end_array(); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + j.write_int("pucch-SpatialRelationInfoId", pucch_spatial_relation_info_id); + if (serving_cell_id_present) { + j.write_int("servingCellId", serving_cell_id); } + j.write_fieldname("referenceSignal"); + ref_sig.to_json(j); + j.write_int("pucch-PathlossReferenceRS-Id", pucch_pathloss_ref_rs_id); + j.write_int("p0-PUCCH-Id", p0_pucch_id); + j.write_str("closedLoopIndex", closed_loop_idx.to_string()); j.end_obj(); } -// CounterCheck ::= SEQUENCE -SRSASN_CODE counter_check_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE counter_check_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); - - return SRSASN_SUCCESS; -} -void counter_check_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); - j.end_obj(); -} - -void counter_check_s::crit_exts_c_::destroy_() +void pucch_spatial_relation_info_s::ref_sig_c_::destroy_() { switch (type_) { - case types::counter_check: - c.destroy(); + case types::srs: + c.destroy(); break; default: break; } } -void counter_check_s::crit_exts_c_::set(types::options e) +void pucch_spatial_relation_info_s::ref_sig_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::counter_check: - c.init(); + case types::ssb_idx: break; - case types::crit_exts_future: + case types::csi_rs_idx: + break; + case types::srs: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); + log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); } } -counter_check_s::crit_exts_c_::crit_exts_c_(const counter_check_s::crit_exts_c_& other) +pucch_spatial_relation_info_s::ref_sig_c_::ref_sig_c_(const pucch_spatial_relation_info_s::ref_sig_c_& other) { type_ = other.type(); switch (type_) { - case types::counter_check: - c.init(other.c.get()); + case types::ssb_idx: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::csi_rs_idx: + c.init(other.c.get()); + break; + case types::srs: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); + log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); } } -counter_check_s::crit_exts_c_& counter_check_s::crit_exts_c_::operator=(const counter_check_s::crit_exts_c_& other) +pucch_spatial_relation_info_s::ref_sig_c_& +pucch_spatial_relation_info_s::ref_sig_c_::operator=(const pucch_spatial_relation_info_s::ref_sig_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::counter_check: - c.set(other.c.get()); + case types::ssb_idx: + c.set(other.c.get()); break; - case types::crit_exts_future: + case types::csi_rs_idx: + c.set(other.c.get()); + break; + case types::srs: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); + log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); } return *this; } -void counter_check_s::crit_exts_c_::to_json(json_writer& j) const +void pucch_spatial_relation_info_s::ref_sig_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::counter_check: - j.write_fieldname("counterCheck"); - c.get().to_json(j); + case types::ssb_idx: + j.write_int("ssb-Index", c.get()); break; - case types::crit_exts_future: + case types::csi_rs_idx: + j.write_int("csi-RS-Index", c.get()); + break; + case types::srs: + j.write_fieldname("srs"); + j.start_obj(); + j.write_int("resource", c.get().res); + j.write_int("uplinkBWP", c.get().ul_bwp); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); + log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); } j.end_obj(); } -SRSASN_CODE counter_check_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE pucch_spatial_relation_info_s::ref_sig_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::counter_check: - HANDLE_CODE(c.get().pack(bref)); + case types::ssb_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); break; - case types::crit_exts_future: + case types::csi_rs_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); + break; + case types::srs: + HANDLE_CODE(pack_integer(bref, c.get().res, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_integer(bref, c.get().ul_bwp, (uint8_t)0u, (uint8_t)4u)); break; default: - log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); + log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE counter_check_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE pucch_spatial_relation_info_s::ref_sig_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::counter_check: - HANDLE_CODE(c.get().unpack(bref)); + case types::ssb_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); break; - case types::crit_exts_future: + case types::csi_rs_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); + break; + case types::srs: + HANDLE_CODE(unpack_integer(c.get().res, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_integer(c.get().ul_bwp, bref, (uint8_t)0u, (uint8_t)4u)); break; default: - log_invalid_choice_id(type_, "counter_check_s::crit_exts_c_"); + log_invalid_choice_id(type_, "pucch_spatial_relation_info_s::ref_sig_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string counter_check_s::crit_exts_c_::types_opts::to_string() const +std::string pucch_spatial_relation_info_s::ref_sig_c_::types_opts::to_string() const { - static const char* options[] = {"counterCheck", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "counter_check_s::crit_exts_c_::types"); + static const char* options[] = {"ssb-Index", "csi-RS-Index", "srs"}; + return convert_enum_idx(options, 3, value, "pucch_spatial_relation_info_s::ref_sig_c_::types"); } -// DLInformationTransfer ::= SEQUENCE -SRSASN_CODE dl_info_transfer_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE dl_info_transfer_s::unpack(cbit_ref& bref) +std::string pucch_spatial_relation_info_s::closed_loop_idx_opts::to_string() const { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"i0", "i1"}; + return convert_enum_idx(options, 2, value, "pucch_spatial_relation_info_s::closed_loop_idx_e_"); } -void dl_info_transfer_s::to_json(json_writer& j) const +uint8_t pucch_spatial_relation_info_s::closed_loop_idx_opts::to_number() const { - j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); - j.end_obj(); + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "pucch_spatial_relation_info_s::closed_loop_idx_e_"); } -void dl_info_transfer_s::crit_exts_c_::destroy_() +// PUSCH-PowerControl ::= SEQUENCE +SRSASN_CODE pusch_pwr_ctrl_s::pack(bit_ref& bref) const { - switch (type_) { - case types::dl_info_transfer: - c.destroy(); - break; - default: - break; + HANDLE_CODE(bref.pack(tpc_accumulation_present, 1)); + HANDLE_CODE(bref.pack(msg3_alpha_present, 1)); + HANDLE_CODE(bref.pack(p0_nominal_without_grant_present, 1)); + HANDLE_CODE(bref.pack(p0_alpha_sets_present, 1)); + HANDLE_CODE(bref.pack(pathloss_ref_rs_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(pathloss_ref_rs_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(two_pusch_pc_adjustment_states_present, 1)); + HANDLE_CODE(bref.pack(delta_mcs_present, 1)); + HANDLE_CODE(bref.pack(sri_pusch_map_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(sri_pusch_map_to_release_list_present, 1)); + + if (msg3_alpha_present) { + HANDLE_CODE(msg3_alpha.pack(bref)); } -} -void dl_info_transfer_s::crit_exts_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::dl_info_transfer: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); + if (p0_nominal_without_grant_present) { + HANDLE_CODE(pack_integer(bref, p0_nominal_without_grant, (int16_t)-202, (int16_t)24)); } -} -dl_info_transfer_s::crit_exts_c_::crit_exts_c_(const dl_info_transfer_s::crit_exts_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::dl_info_transfer: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); + if (p0_alpha_sets_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, p0_alpha_sets, 1, 30)); + } + if (pathloss_ref_rs_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, pathloss_ref_rs_to_add_mod_list, 1, 4)); + } + if (pathloss_ref_rs_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, pathloss_ref_rs_to_release_list, 1, 4, integer_packer(0, 3))); } + if (sri_pusch_map_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sri_pusch_map_to_add_mod_list, 1, 16)); + } + if (sri_pusch_map_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sri_pusch_map_to_release_list, 1, 16, integer_packer(0, 15))); + } + + return SRSASN_SUCCESS; } -dl_info_transfer_s::crit_exts_c_& dl_info_transfer_s::crit_exts_c_:: - operator=(const dl_info_transfer_s::crit_exts_c_& other) +SRSASN_CODE pusch_pwr_ctrl_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + HANDLE_CODE(bref.unpack(tpc_accumulation_present, 1)); + HANDLE_CODE(bref.unpack(msg3_alpha_present, 1)); + HANDLE_CODE(bref.unpack(p0_nominal_without_grant_present, 1)); + HANDLE_CODE(bref.unpack(p0_alpha_sets_present, 1)); + HANDLE_CODE(bref.unpack(pathloss_ref_rs_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(pathloss_ref_rs_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(two_pusch_pc_adjustment_states_present, 1)); + HANDLE_CODE(bref.unpack(delta_mcs_present, 1)); + HANDLE_CODE(bref.unpack(sri_pusch_map_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(sri_pusch_map_to_release_list_present, 1)); + + if (msg3_alpha_present) { + HANDLE_CODE(msg3_alpha.unpack(bref)); } - set(other.type()); - switch (type_) { - case types::dl_info_transfer: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); + if (p0_nominal_without_grant_present) { + HANDLE_CODE(unpack_integer(p0_nominal_without_grant, bref, (int16_t)-202, (int16_t)24)); + } + if (p0_alpha_sets_present) { + HANDLE_CODE(unpack_dyn_seq_of(p0_alpha_sets, bref, 1, 30)); + } + if (pathloss_ref_rs_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(pathloss_ref_rs_to_add_mod_list, bref, 1, 4)); + } + if (pathloss_ref_rs_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(pathloss_ref_rs_to_release_list, bref, 1, 4, integer_packer(0, 3))); + } + if (sri_pusch_map_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sri_pusch_map_to_add_mod_list, bref, 1, 16)); + } + if (sri_pusch_map_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sri_pusch_map_to_release_list, bref, 1, 16, integer_packer(0, 15))); } - return *this; + return SRSASN_SUCCESS; } -void dl_info_transfer_s::crit_exts_c_::to_json(json_writer& j) const +void pusch_pwr_ctrl_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::dl_info_transfer: - j.write_fieldname("dlInformationTransfer"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); + if (tpc_accumulation_present) { + j.write_str("tpc-Accumulation", "disabled"); + } + if (msg3_alpha_present) { + j.write_str("msg3-Alpha", msg3_alpha.to_string()); + } + if (p0_nominal_without_grant_present) { + j.write_int("p0-NominalWithoutGrant", p0_nominal_without_grant); + } + if (p0_alpha_sets_present) { + j.start_array("p0-AlphaSets"); + for (const auto& e1 : p0_alpha_sets) { + e1.to_json(j); + } + j.end_array(); + } + if (pathloss_ref_rs_to_add_mod_list_present) { + j.start_array("pathlossReferenceRSToAddModList"); + for (const auto& e1 : pathloss_ref_rs_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (pathloss_ref_rs_to_release_list_present) { + j.start_array("pathlossReferenceRSToReleaseList"); + for (const auto& e1 : pathloss_ref_rs_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (two_pusch_pc_adjustment_states_present) { + j.write_str("twoPUSCH-PC-AdjustmentStates", "twoStates"); + } + if (delta_mcs_present) { + j.write_str("deltaMCS", "enabled"); + } + if (sri_pusch_map_to_add_mod_list_present) { + j.start_array("sri-PUSCH-MappingToAddModList"); + for (const auto& e1 : sri_pusch_map_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (sri_pusch_map_to_release_list_present) { + j.start_array("sri-PUSCH-MappingToReleaseList"); + for (const auto& e1 : sri_pusch_map_to_release_list) { + j.write_int(e1); + } + j.end_array(); } j.end_obj(); } -SRSASN_CODE dl_info_transfer_s::crit_exts_c_::pack(bit_ref& bref) const + +// RA-Prioritization ::= SEQUENCE +SRSASN_CODE ra_prioritization_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::dl_info_transfer: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(scaling_factor_bi_present, 1)); + + HANDLE_CODE(pwr_ramp_step_high_prio.pack(bref)); + if (scaling_factor_bi_present) { + HANDLE_CODE(scaling_factor_bi.pack(bref)); } + return SRSASN_SUCCESS; } -SRSASN_CODE dl_info_transfer_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE ra_prioritization_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::dl_info_transfer: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "dl_info_transfer_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(scaling_factor_bi_present, 1)); + + HANDLE_CODE(pwr_ramp_step_high_prio.unpack(bref)); + if (scaling_factor_bi_present) { + HANDLE_CODE(scaling_factor_bi.unpack(bref)); } + return SRSASN_SUCCESS; } +void ra_prioritization_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_str("powerRampingStepHighPriority", pwr_ramp_step_high_prio.to_string()); + if (scaling_factor_bi_present) { + j.write_str("scalingFactorBI", scaling_factor_bi.to_string()); + } + j.end_obj(); +} -std::string dl_info_transfer_s::crit_exts_c_::types_opts::to_string() const +std::string ra_prioritization_s::pwr_ramp_step_high_prio_opts::to_string() const { - static const char* options[] = {"dlInformationTransfer", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "dl_info_transfer_s::crit_exts_c_::types"); + static const char* options[] = {"dB0", "dB2", "dB4", "dB6"}; + return convert_enum_idx(options, 4, value, "ra_prioritization_s::pwr_ramp_step_high_prio_e_"); +} +uint8_t ra_prioritization_s::pwr_ramp_step_high_prio_opts::to_number() const +{ + static const uint8_t options[] = {0, 2, 4, 6}; + return map_enum_number(options, 4, value, "ra_prioritization_s::pwr_ramp_step_high_prio_e_"); } -// MobilityFromNRCommand ::= SEQUENCE -SRSASN_CODE mob_from_nr_cmd_s::pack(bit_ref& bref) const +std::string ra_prioritization_s::scaling_factor_bi_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + static const char* options[] = {"zero", "dot25", "dot5", "dot75"}; + return convert_enum_idx(options, 4, value, "ra_prioritization_s::scaling_factor_bi_e_"); +} +uint8_t ra_prioritization_s::scaling_factor_bi_opts::to_number() const +{ + static const uint8_t options[] = {0, 25, 5, 75}; + return map_enum_number(options, 4, value, "ra_prioritization_s::scaling_factor_bi_e_"); +} + +// SRS-Resource ::= SEQUENCE +SRSASN_CODE srs_res_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(ptrs_port_idx_present, 1)); + HANDLE_CODE(bref.pack(spatial_relation_info_present, 1)); + + HANDLE_CODE(pack_integer(bref, srs_res_id, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(nrof_srs_ports.pack(bref)); + if (ptrs_port_idx_present) { + HANDLE_CODE(ptrs_port_idx.pack(bref)); + } + HANDLE_CODE(tx_comb.pack(bref)); + HANDLE_CODE(pack_integer(bref, res_map.start_position, (uint8_t)0u, (uint8_t)5u)); + HANDLE_CODE(res_map.nrof_symbols.pack(bref)); + HANDLE_CODE(res_map.repeat_factor.pack(bref)); + HANDLE_CODE(pack_integer(bref, freq_domain_position, (uint8_t)0u, (uint8_t)67u)); + HANDLE_CODE(pack_integer(bref, freq_domain_shift, (uint16_t)0u, (uint16_t)268u)); + HANDLE_CODE(pack_integer(bref, freq_hop.c_srs, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_integer(bref, freq_hop.b_srs, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pack_integer(bref, freq_hop.b_hop, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(group_or_seq_hop.pack(bref)); + HANDLE_CODE(res_type.pack(bref)); + HANDLE_CODE(pack_integer(bref, seq_id, (uint16_t)0u, (uint16_t)1023u)); + if (spatial_relation_info_present) { + HANDLE_CODE(spatial_relation_info.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE mob_from_nr_cmd_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_res_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(ptrs_port_idx_present, 1)); + HANDLE_CODE(bref.unpack(spatial_relation_info_present, 1)); + + HANDLE_CODE(unpack_integer(srs_res_id, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(nrof_srs_ports.unpack(bref)); + if (ptrs_port_idx_present) { + HANDLE_CODE(ptrs_port_idx.unpack(bref)); + } + HANDLE_CODE(tx_comb.unpack(bref)); + HANDLE_CODE(unpack_integer(res_map.start_position, bref, (uint8_t)0u, (uint8_t)5u)); + HANDLE_CODE(res_map.nrof_symbols.unpack(bref)); + HANDLE_CODE(res_map.repeat_factor.unpack(bref)); + HANDLE_CODE(unpack_integer(freq_domain_position, bref, (uint8_t)0u, (uint8_t)67u)); + HANDLE_CODE(unpack_integer(freq_domain_shift, bref, (uint16_t)0u, (uint16_t)268u)); + HANDLE_CODE(unpack_integer(freq_hop.c_srs, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_integer(freq_hop.b_srs, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(unpack_integer(freq_hop.b_hop, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(group_or_seq_hop.unpack(bref)); + HANDLE_CODE(res_type.unpack(bref)); + HANDLE_CODE(unpack_integer(seq_id, bref, (uint16_t)0u, (uint16_t)1023u)); + if (spatial_relation_info_present) { + HANDLE_CODE(spatial_relation_info.unpack(bref)); + } return SRSASN_SUCCESS; } -void mob_from_nr_cmd_s::to_json(json_writer& j) const +void srs_res_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("srs-ResourceId", srs_res_id); + j.write_str("nrofSRS-Ports", nrof_srs_ports.to_string()); + if (ptrs_port_idx_present) { + j.write_str("ptrs-PortIndex", ptrs_port_idx.to_string()); + } + j.write_fieldname("transmissionComb"); + tx_comb.to_json(j); + j.write_fieldname("resourceMapping"); + j.start_obj(); + j.write_int("startPosition", res_map.start_position); + j.write_str("nrofSymbols", res_map.nrof_symbols.to_string()); + j.write_str("repetitionFactor", res_map.repeat_factor.to_string()); + j.end_obj(); + j.write_int("freqDomainPosition", freq_domain_position); + j.write_int("freqDomainShift", freq_domain_shift); + j.write_fieldname("freqHopping"); + j.start_obj(); + j.write_int("c-SRS", freq_hop.c_srs); + j.write_int("b-SRS", freq_hop.b_srs); + j.write_int("b-hop", freq_hop.b_hop); + j.end_obj(); + j.write_str("groupOrSequenceHopping", group_or_seq_hop.to_string()); + j.write_fieldname("resourceType"); + res_type.to_json(j); + j.write_int("sequenceId", seq_id); + if (spatial_relation_info_present) { + j.write_fieldname("spatialRelationInfo"); + spatial_relation_info.to_json(j); + } j.end_obj(); } -void mob_from_nr_cmd_s::crit_exts_c_::destroy_() +std::string srs_res_s::nrof_srs_ports_opts::to_string() const +{ + static const char* options[] = {"port1", "ports2", "ports4"}; + return convert_enum_idx(options, 3, value, "srs_res_s::nrof_srs_ports_e_"); +} +uint8_t srs_res_s::nrof_srs_ports_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 4}; + return map_enum_number(options, 3, value, "srs_res_s::nrof_srs_ports_e_"); +} + +std::string srs_res_s::ptrs_port_idx_opts::to_string() const +{ + static const char* options[] = {"n0", "n1"}; + return convert_enum_idx(options, 2, value, "srs_res_s::ptrs_port_idx_e_"); +} +uint8_t srs_res_s::ptrs_port_idx_opts::to_number() const +{ + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "srs_res_s::ptrs_port_idx_e_"); +} + +void srs_res_s::tx_comb_c_::destroy_() { switch (type_) { - case types::mob_from_nr_cmd: - c.destroy(); + case types::n2: + c.destroy(); + break; + case types::n4: + c.destroy(); break; default: break; } } -void mob_from_nr_cmd_s::crit_exts_c_::set(types::options e) +void srs_res_s::tx_comb_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::mob_from_nr_cmd: - c.init(); + case types::n2: + c.init(); break; - case types::crit_exts_future: + case types::n4: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); } } -mob_from_nr_cmd_s::crit_exts_c_::crit_exts_c_(const mob_from_nr_cmd_s::crit_exts_c_& other) +srs_res_s::tx_comb_c_::tx_comb_c_(const srs_res_s::tx_comb_c_& other) { type_ = other.type(); switch (type_) { - case types::mob_from_nr_cmd: - c.init(other.c.get()); + case types::n2: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::n4: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); } } -mob_from_nr_cmd_s::crit_exts_c_& mob_from_nr_cmd_s::crit_exts_c_:: - operator=(const mob_from_nr_cmd_s::crit_exts_c_& other) +srs_res_s::tx_comb_c_& srs_res_s::tx_comb_c_::operator=(const srs_res_s::tx_comb_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::mob_from_nr_cmd: - c.set(other.c.get()); + case types::n2: + c.set(other.c.get()); break; - case types::crit_exts_future: + case types::n4: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); } return *this; } -void mob_from_nr_cmd_s::crit_exts_c_::to_json(json_writer& j) const +void srs_res_s::tx_comb_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::mob_from_nr_cmd: - j.write_fieldname("mobilityFromNRCommand"); - c.get().to_json(j); + case types::n2: + j.write_fieldname("n2"); + j.start_obj(); + j.write_int("combOffset-n2", c.get().comb_offset_n2); + j.write_int("cyclicShift-n2", c.get().cyclic_shift_n2); + j.end_obj(); break; - case types::crit_exts_future: + case types::n4: + j.write_fieldname("n4"); + j.start_obj(); + j.write_int("combOffset-n4", c.get().comb_offset_n4); + j.write_int("cyclicShift-n4", c.get().cyclic_shift_n4); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); } j.end_obj(); } -SRSASN_CODE mob_from_nr_cmd_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE srs_res_s::tx_comb_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::mob_from_nr_cmd: - HANDLE_CODE(c.get().pack(bref)); + case types::n2: + HANDLE_CODE(pack_integer(bref, c.get().comb_offset_n2, (uint8_t)0u, (uint8_t)1u)); + HANDLE_CODE(pack_integer(bref, c.get().cyclic_shift_n2, (uint8_t)0u, (uint8_t)7u)); break; - case types::crit_exts_future: + case types::n4: + HANDLE_CODE(pack_integer(bref, c.get().comb_offset_n4, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(pack_integer(bref, c.get().cyclic_shift_n4, (uint8_t)0u, (uint8_t)11u)); break; default: - log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE mob_from_nr_cmd_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE srs_res_s::tx_comb_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::mob_from_nr_cmd: - HANDLE_CODE(c.get().unpack(bref)); + case types::n2: + HANDLE_CODE(unpack_integer(c.get().comb_offset_n2, bref, (uint8_t)0u, (uint8_t)1u)); + HANDLE_CODE(unpack_integer(c.get().cyclic_shift_n2, bref, (uint8_t)0u, (uint8_t)7u)); break; - case types::crit_exts_future: + case types::n4: + HANDLE_CODE(unpack_integer(c.get().comb_offset_n4, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(unpack_integer(c.get().cyclic_shift_n4, bref, (uint8_t)0u, (uint8_t)11u)); break; default: - log_invalid_choice_id(type_, "mob_from_nr_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::tx_comb_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string mob_from_nr_cmd_s::crit_exts_c_::types_opts::to_string() const +std::string srs_res_s::tx_comb_c_::types_opts::to_string() const { - static const char* options[] = {"mobilityFromNRCommand", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "mob_from_nr_cmd_s::crit_exts_c_::types"); + static const char* options[] = {"n2", "n4"}; + return convert_enum_idx(options, 2, value, "srs_res_s::tx_comb_c_::types"); } - -// RRCReconfiguration ::= SEQUENCE -SRSASN_CODE rrc_recfg_s::pack(bit_ref& bref) const +uint8_t srs_res_s::tx_comb_c_::types_opts::to_number() const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + static const uint8_t options[] = {2, 4}; + return map_enum_number(options, 2, value, "srs_res_s::tx_comb_c_::types"); +} - return SRSASN_SUCCESS; +std::string srs_res_s::res_map_s_::nrof_symbols_opts::to_string() const +{ + static const char* options[] = {"n1", "n2", "n4"}; + return convert_enum_idx(options, 3, value, "srs_res_s::res_map_s_::nrof_symbols_e_"); } -SRSASN_CODE rrc_recfg_s::unpack(cbit_ref& bref) +uint8_t srs_res_s::res_map_s_::nrof_symbols_opts::to_number() const { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + static const uint8_t options[] = {1, 2, 4}; + return map_enum_number(options, 3, value, "srs_res_s::res_map_s_::nrof_symbols_e_"); +} - return SRSASN_SUCCESS; +std::string srs_res_s::res_map_s_::repeat_factor_opts::to_string() const +{ + static const char* options[] = {"n1", "n2", "n4"}; + return convert_enum_idx(options, 3, value, "srs_res_s::res_map_s_::repeat_factor_e_"); } -void rrc_recfg_s::to_json(json_writer& j) const +uint8_t srs_res_s::res_map_s_::repeat_factor_opts::to_number() const { - j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); - j.end_obj(); + static const uint8_t options[] = {1, 2, 4}; + return map_enum_number(options, 3, value, "srs_res_s::res_map_s_::repeat_factor_e_"); } -void rrc_recfg_s::crit_exts_c_::destroy_() +std::string srs_res_s::group_or_seq_hop_opts::to_string() const +{ + static const char* options[] = {"neither", "groupHopping", "sequenceHopping"}; + return convert_enum_idx(options, 3, value, "srs_res_s::group_or_seq_hop_e_"); +} + +void srs_res_s::res_type_c_::destroy_() { switch (type_) { - case types::rrc_recfg: - c.destroy(); + case types::aperiodic: + c.destroy(); + break; + case types::semi_persistent: + c.destroy(); + break; + case types::periodic: + c.destroy(); break; default: break; } } -void rrc_recfg_s::crit_exts_c_::set(types::options e) +void srs_res_s::res_type_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::rrc_recfg: - c.init(); + case types::aperiodic: + c.init(); break; - case types::crit_exts_future: + case types::semi_persistent: + c.init(); + break; + case types::periodic: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); } } -rrc_recfg_s::crit_exts_c_::crit_exts_c_(const rrc_recfg_s::crit_exts_c_& other) +srs_res_s::res_type_c_::res_type_c_(const srs_res_s::res_type_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_recfg: - c.init(other.c.get()); + case types::aperiodic: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::semi_persistent: + c.init(other.c.get()); + break; + case types::periodic: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); } } -rrc_recfg_s::crit_exts_c_& rrc_recfg_s::crit_exts_c_::operator=(const rrc_recfg_s::crit_exts_c_& other) +srs_res_s::res_type_c_& srs_res_s::res_type_c_::operator=(const srs_res_s::res_type_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_recfg: - c.set(other.c.get()); - break; - case types::crit_exts_future: + case types::aperiodic: + c.set(other.c.get()); + break; + case types::semi_persistent: + c.set(other.c.get()); + break; + case types::periodic: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); } return *this; } -void rrc_recfg_s::crit_exts_c_::to_json(json_writer& j) const +void srs_res_s::res_type_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_recfg: - j.write_fieldname("rrcReconfiguration"); - c.get().to_json(j); + case types::aperiodic: + j.write_fieldname("aperiodic"); + j.start_obj(); + j.end_obj(); break; - case types::crit_exts_future: + case types::semi_persistent: + j.write_fieldname("semi-persistent"); + j.start_obj(); + j.write_fieldname("periodicityAndOffset-sp"); + c.get().periodicity_and_offset_sp.to_json(j); + j.end_obj(); + break; + case types::periodic: + j.write_fieldname("periodic"); + j.start_obj(); + j.write_fieldname("periodicityAndOffset-p"); + c.get().periodicity_and_offset_p.to_json(j); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); } j.end_obj(); } -SRSASN_CODE rrc_recfg_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE srs_res_s::res_type_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_recfg: - HANDLE_CODE(c.get().pack(bref)); + case types::aperiodic: + bref.pack(c.get().ext, 1); break; - case types::crit_exts_future: + case types::semi_persistent: + bref.pack(c.get().ext, 1); + HANDLE_CODE(c.get().periodicity_and_offset_sp.pack(bref)); + break; + case types::periodic: + bref.pack(c.get().ext, 1); + HANDLE_CODE(c.get().periodicity_and_offset_p.pack(bref)); break; default: - log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_recfg_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE srs_res_s::res_type_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_recfg: - HANDLE_CODE(c.get().unpack(bref)); + case types::aperiodic: + bref.unpack(c.get().ext, 1); break; - case types::crit_exts_future: + case types::semi_persistent: + bref.unpack(c.get().ext, 1); + HANDLE_CODE(c.get().periodicity_and_offset_sp.unpack(bref)); + break; + case types::periodic: + bref.unpack(c.get().ext, 1); + HANDLE_CODE(c.get().periodicity_and_offset_p.unpack(bref)); break; default: - log_invalid_choice_id(type_, "rrc_recfg_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_s::res_type_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_recfg_s::crit_exts_c_::types_opts::to_string() const +std::string srs_res_s::res_type_c_::types_opts::to_string() const { - static const char* options[] = {"rrcReconfiguration", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_recfg_s::crit_exts_c_::types"); + static const char* options[] = {"aperiodic", "semi-persistent", "periodic"}; + return convert_enum_idx(options, 3, value, "srs_res_s::res_type_c_::types"); } -// RRCReestablishment ::= SEQUENCE -SRSASN_CODE rrc_reest_s::pack(bit_ref& bref) const +// SRS-ResourceSet ::= SEQUENCE +SRSASN_CODE srs_res_set_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(srs_res_id_list_present, 1)); + HANDLE_CODE(bref.pack(alpha_present, 1)); + HANDLE_CODE(bref.pack(p0_present, 1)); + HANDLE_CODE(bref.pack(pathloss_ref_rs_present, 1)); + HANDLE_CODE(bref.pack(srs_pwr_ctrl_adjustment_states_present, 1)); + + HANDLE_CODE(pack_integer(bref, srs_res_set_id, (uint8_t)0u, (uint8_t)15u)); + if (srs_res_id_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_id_list, 1, 16, integer_packer(0, 63))); + } + HANDLE_CODE(res_type.pack(bref)); + HANDLE_CODE(usage.pack(bref)); + if (alpha_present) { + HANDLE_CODE(alpha.pack(bref)); + } + if (p0_present) { + HANDLE_CODE(pack_integer(bref, p0, (int16_t)-202, (int16_t)24)); + } + if (pathloss_ref_rs_present) { + HANDLE_CODE(pathloss_ref_rs.pack(bref)); + } + if (srs_pwr_ctrl_adjustment_states_present) { + HANDLE_CODE(srs_pwr_ctrl_adjustment_states.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_reest_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_res_set_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(srs_res_id_list_present, 1)); + HANDLE_CODE(bref.unpack(alpha_present, 1)); + HANDLE_CODE(bref.unpack(p0_present, 1)); + HANDLE_CODE(bref.unpack(pathloss_ref_rs_present, 1)); + HANDLE_CODE(bref.unpack(srs_pwr_ctrl_adjustment_states_present, 1)); + + HANDLE_CODE(unpack_integer(srs_res_set_id, bref, (uint8_t)0u, (uint8_t)15u)); + if (srs_res_id_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(srs_res_id_list, bref, 1, 16, integer_packer(0, 63))); + } + HANDLE_CODE(res_type.unpack(bref)); + HANDLE_CODE(usage.unpack(bref)); + if (alpha_present) { + HANDLE_CODE(alpha.unpack(bref)); + } + if (p0_present) { + HANDLE_CODE(unpack_integer(p0, bref, (int16_t)-202, (int16_t)24)); + } + if (pathloss_ref_rs_present) { + HANDLE_CODE(pathloss_ref_rs.unpack(bref)); + } + if (srs_pwr_ctrl_adjustment_states_present) { + HANDLE_CODE(srs_pwr_ctrl_adjustment_states.unpack(bref)); + } return SRSASN_SUCCESS; } -void rrc_reest_s::to_json(json_writer& j) const +void srs_res_set_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("srs-ResourceSetId", srs_res_set_id); + if (srs_res_id_list_present) { + j.start_array("srs-ResourceIdList"); + for (const auto& e1 : srs_res_id_list) { + j.write_int(e1); + } + j.end_array(); + } + j.write_fieldname("resourceType"); + res_type.to_json(j); + j.write_str("usage", usage.to_string()); + if (alpha_present) { + j.write_str("alpha", alpha.to_string()); + } + if (p0_present) { + j.write_int("p0", p0); + } + if (pathloss_ref_rs_present) { + j.write_fieldname("pathlossReferenceRS"); + pathloss_ref_rs.to_json(j); + } + if (srs_pwr_ctrl_adjustment_states_present) { + j.write_str("srs-PowerControlAdjustmentStates", srs_pwr_ctrl_adjustment_states.to_string()); + } j.end_obj(); } -void rrc_reest_s::crit_exts_c_::destroy_() +void srs_res_set_s::res_type_c_::destroy_() { switch (type_) { - case types::rrc_reest: - c.destroy(); + case types::aperiodic: + c.destroy(); + break; + case types::semi_persistent: + c.destroy(); + break; + case types::periodic: + c.destroy(); break; default: break; } } -void rrc_reest_s::crit_exts_c_::set(types::options e) +void srs_res_set_s::res_type_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::rrc_reest: - c.init(); + case types::aperiodic: + c.init(); break; - case types::crit_exts_future: + case types::semi_persistent: + c.init(); + break; + case types::periodic: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); } } -rrc_reest_s::crit_exts_c_::crit_exts_c_(const rrc_reest_s::crit_exts_c_& other) +srs_res_set_s::res_type_c_::res_type_c_(const srs_res_set_s::res_type_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_reest: - c.init(other.c.get()); + case types::aperiodic: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::semi_persistent: + c.init(other.c.get()); + break; + case types::periodic: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); } } -rrc_reest_s::crit_exts_c_& rrc_reest_s::crit_exts_c_::operator=(const rrc_reest_s::crit_exts_c_& other) +srs_res_set_s::res_type_c_& srs_res_set_s::res_type_c_::operator=(const srs_res_set_s::res_type_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_reest: - c.set(other.c.get()); + case types::aperiodic: + c.set(other.c.get()); break; - case types::crit_exts_future: + case types::semi_persistent: + c.set(other.c.get()); + break; + case types::periodic: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); } return *this; } -void rrc_reest_s::crit_exts_c_::to_json(json_writer& j) const +void srs_res_set_s::res_type_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_reest: - j.write_fieldname("rrcReestablishment"); - c.get().to_json(j); + case types::aperiodic: + j.write_fieldname("aperiodic"); + c.get().to_json(j); break; - case types::crit_exts_future: + case types::semi_persistent: + j.write_fieldname("semi-persistent"); + j.start_obj(); + if (c.get().associated_csi_rs_present) { + j.write_int("associatedCSI-RS", c.get().associated_csi_rs); + } + j.end_obj(); + break; + case types::periodic: + j.write_fieldname("periodic"); + j.start_obj(); + if (c.get().associated_csi_rs_present) { + j.write_int("associatedCSI-RS", c.get().associated_csi_rs); + } + j.end_obj(); break; default: - log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); } j.end_obj(); } -SRSASN_CODE rrc_reest_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE srs_res_set_s::res_type_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_reest: - HANDLE_CODE(c.get().pack(bref)); + case types::aperiodic: + HANDLE_CODE(c.get().pack(bref)); break; - case types::crit_exts_future: + case types::semi_persistent: + bref.pack(c.get().ext, 1); + HANDLE_CODE(bref.pack(c.get().associated_csi_rs_present, 1)); + if (c.get().associated_csi_rs_present) { + HANDLE_CODE(pack_integer(bref, c.get().associated_csi_rs, (uint8_t)0u, (uint8_t)191u)); + } + break; + case types::periodic: + bref.pack(c.get().ext, 1); + HANDLE_CODE(bref.pack(c.get().associated_csi_rs_present, 1)); + if (c.get().associated_csi_rs_present) { + HANDLE_CODE(pack_integer(bref, c.get().associated_csi_rs, (uint8_t)0u, (uint8_t)191u)); + } break; default: - log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_reest_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE srs_res_set_s::res_type_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_reest: - HANDLE_CODE(c.get().unpack(bref)); + case types::aperiodic: + HANDLE_CODE(c.get().unpack(bref)); break; - case types::crit_exts_future: + case types::semi_persistent: + bref.unpack(c.get().ext, 1); + HANDLE_CODE(bref.unpack(c.get().associated_csi_rs_present, 1)); + if (c.get().associated_csi_rs_present) { + HANDLE_CODE(unpack_integer(c.get().associated_csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); + } + break; + case types::periodic: + bref.unpack(c.get().ext, 1); + HANDLE_CODE(bref.unpack(c.get().associated_csi_rs_present, 1)); + if (c.get().associated_csi_rs_present) { + HANDLE_CODE(unpack_integer(c.get().associated_csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); + } break; default: - log_invalid_choice_id(type_, "rrc_reest_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::res_type_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_reest_s::crit_exts_c_::types_opts::to_string() const +SRSASN_CODE srs_res_set_s::res_type_c_::aperiodic_s_::pack(bit_ref& bref) const { - static const char* options[] = {"rrcReestablishment", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_reest_s::crit_exts_c_::types"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(csi_rs_present, 1)); + HANDLE_CODE(bref.pack(slot_offset_present, 1)); -// RRCRelease ::= SEQUENCE -SRSASN_CODE rrc_release_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + HANDLE_CODE(pack_integer(bref, aperiodic_srs_res_trigger, (uint8_t)1u, (uint8_t)3u)); + if (csi_rs_present) { + HANDLE_CODE(pack_integer(bref, csi_rs, (uint8_t)0u, (uint8_t)191u)); + } + if (slot_offset_present) { + HANDLE_CODE(pack_integer(bref, slot_offset, (uint8_t)1u, (uint8_t)32u)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= aperiodic_srs_res_trigger_list.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(bref.pack(aperiodic_srs_res_trigger_list.is_present(), 1)); + if (aperiodic_srs_res_trigger_list.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *aperiodic_srs_res_trigger_list, 1, 2, integer_packer(1, 3))); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_release_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_res_set_s::res_type_c_::aperiodic_s_::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(csi_rs_present, 1)); + HANDLE_CODE(bref.unpack(slot_offset_present, 1)); + + HANDLE_CODE(unpack_integer(aperiodic_srs_res_trigger, bref, (uint8_t)1u, (uint8_t)3u)); + if (csi_rs_present) { + HANDLE_CODE(unpack_integer(csi_rs, bref, (uint8_t)0u, (uint8_t)191u)); + } + if (slot_offset_present) { + HANDLE_CODE(unpack_integer(slot_offset, bref, (uint8_t)1u, (uint8_t)32u)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool aperiodic_srs_res_trigger_list_present; + HANDLE_CODE(bref.unpack(aperiodic_srs_res_trigger_list_present, 1)); + aperiodic_srs_res_trigger_list.set_present(aperiodic_srs_res_trigger_list_present); + if (aperiodic_srs_res_trigger_list.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*aperiodic_srs_res_trigger_list, bref, 1, 2, integer_packer(1, 3))); + } + } + } return SRSASN_SUCCESS; } -void rrc_release_s::to_json(json_writer& j) const +void srs_res_set_s::res_type_c_::aperiodic_s_::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("aperiodicSRS-ResourceTrigger", aperiodic_srs_res_trigger); + if (csi_rs_present) { + j.write_int("csi-RS", csi_rs); + } + if (slot_offset_present) { + j.write_int("slotOffset", slot_offset); + } + if (ext) { + if (aperiodic_srs_res_trigger_list.is_present()) { + j.start_array("aperiodicSRS-ResourceTriggerList"); + for (const auto& e1 : *aperiodic_srs_res_trigger_list) { + j.write_int(e1); + } + j.end_array(); + } + } j.end_obj(); } -void rrc_release_s::crit_exts_c_::destroy_() +std::string srs_res_set_s::res_type_c_::types_opts::to_string() const { - switch (type_) { - case types::rrc_release: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"aperiodic", "semi-persistent", "periodic"}; + return convert_enum_idx(options, 3, value, "srs_res_set_s::res_type_c_::types"); } -void rrc_release_s::crit_exts_c_::set(types::options e) + +std::string srs_res_set_s::usage_opts::to_string() const +{ + static const char* options[] = {"beamManagement", "codebook", "nonCodebook", "antennaSwitching"}; + return convert_enum_idx(options, 4, value, "srs_res_set_s::usage_e_"); +} + +void srs_res_set_s::pathloss_ref_rs_c_::destroy_() {} +void srs_res_set_s::pathloss_ref_rs_c_::set(types::options e) { destroy_(); type_ = e; - switch (type_) { - case types::rrc_release: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); - } } -rrc_release_s::crit_exts_c_::crit_exts_c_(const rrc_release_s::crit_exts_c_& other) +srs_res_set_s::pathloss_ref_rs_c_::pathloss_ref_rs_c_(const srs_res_set_s::pathloss_ref_rs_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_release: - c.init(other.c.get()); + case types::ssb_idx: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::csi_rs_idx: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); } } -rrc_release_s::crit_exts_c_& rrc_release_s::crit_exts_c_::operator=(const rrc_release_s::crit_exts_c_& other) +srs_res_set_s::pathloss_ref_rs_c_& +srs_res_set_s::pathloss_ref_rs_c_::operator=(const srs_res_set_s::pathloss_ref_rs_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_release: - c.set(other.c.get()); + case types::ssb_idx: + c.set(other.c.get()); break; - case types::crit_exts_future: + case types::csi_rs_idx: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); } return *this; } -void rrc_release_s::crit_exts_c_::to_json(json_writer& j) const +void srs_res_set_s::pathloss_ref_rs_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_release: - j.write_fieldname("rrcRelease"); - c.get().to_json(j); + case types::ssb_idx: + j.write_int("ssb-Index", c.get()); break; - case types::crit_exts_future: + case types::csi_rs_idx: + j.write_int("csi-RS-Index", c.get()); break; default: - log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); } j.end_obj(); } -SRSASN_CODE rrc_release_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE srs_res_set_s::pathloss_ref_rs_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_release: - HANDLE_CODE(c.get().pack(bref)); + case types::ssb_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); break; - case types::crit_exts_future: + case types::csi_rs_idx: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)191u)); break; default: - log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_release_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE srs_res_set_s::pathloss_ref_rs_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_release: - HANDLE_CODE(c.get().unpack(bref)); + case types::ssb_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); break; - case types::crit_exts_future: + case types::csi_rs_idx: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)191u)); break; default: - log_invalid_choice_id(type_, "rrc_release_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_res_set_s::pathloss_ref_rs_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_release_s::crit_exts_c_::types_opts::to_string() const +std::string srs_res_set_s::pathloss_ref_rs_c_::types_opts::to_string() const { - static const char* options[] = {"rrcRelease", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_release_s::crit_exts_c_::types"); + static const char* options[] = {"ssb-Index", "csi-RS-Index"}; + return convert_enum_idx(options, 2, value, "srs_res_set_s::pathloss_ref_rs_c_::types"); } -// RRCResume ::= SEQUENCE -SRSASN_CODE rrc_resume_s::pack(bit_ref& bref) const +std::string srs_res_set_s::srs_pwr_ctrl_adjustment_states_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + static const char* options[] = {"sameAsFci2", "separateClosedLoop"}; + return convert_enum_idx(options, 2, value, "srs_res_set_s::srs_pwr_ctrl_adjustment_states_e_"); +} +uint8_t srs_res_set_s::srs_pwr_ctrl_adjustment_states_opts::to_number() const +{ + static const uint8_t options[] = {2}; + return map_enum_number(options, 1, value, "srs_res_set_s::srs_pwr_ctrl_adjustment_states_e_"); +} + +// SchedulingRequestResourceConfig ::= SEQUENCE +SRSASN_CODE sched_request_res_cfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); + HANDLE_CODE(bref.pack(res_present, 1)); + + HANDLE_CODE(pack_integer(bref, sched_request_res_id, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(pack_integer(bref, sched_request_id, (uint8_t)0u, (uint8_t)7u)); + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.pack(bref)); + } + if (res_present) { + HANDLE_CODE(pack_integer(bref, res, (uint8_t)0u, (uint8_t)127u)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_resume_s::unpack(cbit_ref& bref) +SRSASN_CODE sched_request_res_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); + HANDLE_CODE(bref.unpack(res_present, 1)); + + HANDLE_CODE(unpack_integer(sched_request_res_id, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(unpack_integer(sched_request_id, bref, (uint8_t)0u, (uint8_t)7u)); + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.unpack(bref)); + } + if (res_present) { + HANDLE_CODE(unpack_integer(res, bref, (uint8_t)0u, (uint8_t)127u)); + } return SRSASN_SUCCESS; } -void rrc_resume_s::to_json(json_writer& j) const +void sched_request_res_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("schedulingRequestResourceId", sched_request_res_id); + j.write_int("schedulingRequestID", sched_request_id); + if (periodicity_and_offset_present) { + j.write_fieldname("periodicityAndOffset"); + periodicity_and_offset.to_json(j); + } + if (res_present) { + j.write_int("resource", res); + } j.end_obj(); } -void rrc_resume_s::crit_exts_c_::destroy_() -{ - switch (type_) { - case types::rrc_resume: - c.destroy(); - break; - default: - break; - } -} -void rrc_resume_s::crit_exts_c_::set(types::options e) +void sched_request_res_cfg_s::periodicity_and_offset_c_::destroy_() {} +void sched_request_res_cfg_s::periodicity_and_offset_c_::set(types::options e) { destroy_(); type_ = e; - switch (type_) { - case types::rrc_resume: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); - } } -rrc_resume_s::crit_exts_c_::crit_exts_c_(const rrc_resume_s::crit_exts_c_& other) +sched_request_res_cfg_s::periodicity_and_offset_c_::periodicity_and_offset_c_( + const sched_request_res_cfg_s::periodicity_and_offset_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_resume: - c.init(other.c.get()); + case types::sym2: break; - case types::crit_exts_future: + case types::sym6or7: + break; + case types::sl1: + break; + case types::sl2: + c.init(other.c.get()); + break; + case types::sl4: + c.init(other.c.get()); + break; + case types::sl5: + c.init(other.c.get()); + break; + case types::sl8: + c.init(other.c.get()); + break; + case types::sl10: + c.init(other.c.get()); + break; + case types::sl16: + c.init(other.c.get()); + break; + case types::sl20: + c.init(other.c.get()); + break; + case types::sl40: + c.init(other.c.get()); + break; + case types::sl80: + c.init(other.c.get()); + break; + case types::sl160: + c.init(other.c.get()); + break; + case types::sl320: + c.init(other.c.get()); + break; + case types::sl640: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); + log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); } } -rrc_resume_s::crit_exts_c_& rrc_resume_s::crit_exts_c_::operator=(const rrc_resume_s::crit_exts_c_& other) +sched_request_res_cfg_s::periodicity_and_offset_c_& sched_request_res_cfg_s::periodicity_and_offset_c_::operator=( + const sched_request_res_cfg_s::periodicity_and_offset_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_resume: - c.set(other.c.get()); + case types::sym2: break; - case types::crit_exts_future: + case types::sym6or7: + break; + case types::sl1: + break; + case types::sl2: + c.set(other.c.get()); + break; + case types::sl4: + c.set(other.c.get()); + break; + case types::sl5: + c.set(other.c.get()); + break; + case types::sl8: + c.set(other.c.get()); + break; + case types::sl10: + c.set(other.c.get()); + break; + case types::sl16: + c.set(other.c.get()); + break; + case types::sl20: + c.set(other.c.get()); + break; + case types::sl40: + c.set(other.c.get()); + break; + case types::sl80: + c.set(other.c.get()); + break; + case types::sl160: + c.set(other.c.get()); + break; + case types::sl320: + c.set(other.c.get()); + break; + case types::sl640: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); + log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); } return *this; } -void rrc_resume_s::crit_exts_c_::to_json(json_writer& j) const +void sched_request_res_cfg_s::periodicity_and_offset_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_resume: - j.write_fieldname("rrcResume"); - c.get().to_json(j); + case types::sym2: break; - case types::crit_exts_future: + case types::sym6or7: break; - default: - log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); - } - j.end_obj(); -} -SRSASN_CODE rrc_resume_s::crit_exts_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::rrc_resume: - HANDLE_CODE(c.get().pack(bref)); + case types::sl1: break; - case types::crit_exts_future: + case types::sl2: + j.write_int("sl2", c.get()); break; - default: - log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_resume_s::crit_exts_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::rrc_resume: - HANDLE_CODE(c.get().unpack(bref)); + case types::sl4: + j.write_int("sl4", c.get()); break; - case types::crit_exts_future: + case types::sl5: + j.write_int("sl5", c.get()); + break; + case types::sl8: + j.write_int("sl8", c.get()); + break; + case types::sl10: + j.write_int("sl10", c.get()); + break; + case types::sl16: + j.write_int("sl16", c.get()); + break; + case types::sl20: + j.write_int("sl20", c.get()); + break; + case types::sl40: + j.write_int("sl40", c.get()); + break; + case types::sl80: + j.write_int("sl80", c.get()); + break; + case types::sl160: + j.write_int("sl160", c.get()); + break; + case types::sl320: + j.write_int("sl320", c.get()); + break; + case types::sl640: + j.write_int("sl640", c.get()); break; default: - log_invalid_choice_id(type_, "rrc_resume_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; + log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); } - return SRSASN_SUCCESS; -} - -std::string rrc_resume_s::crit_exts_c_::types_opts::to_string() const -{ - static const char* options[] = {"rrcResume", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_resume_s::crit_exts_c_::types"); -} - -// SecurityModeCommand ::= SEQUENCE -SRSASN_CODE security_mode_cmd_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE security_mode_cmd_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); - - return SRSASN_SUCCESS; -} -void security_mode_cmd_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); j.end_obj(); } - -void security_mode_cmd_s::crit_exts_c_::destroy_() +SRSASN_CODE sched_request_res_cfg_s::periodicity_and_offset_c_::pack(bit_ref& bref) const { + type_.pack(bref); switch (type_) { - case types::security_mode_cmd: - c.destroy(); + case types::sym2: break; - default: + case types::sym6or7: break; - } -} -void security_mode_cmd_s::crit_exts_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::security_mode_cmd: - c.init(); + case types::sl1: break; - case types::crit_exts_future: + case types::sl2: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)1u)); break; - case types::nulltype: + case types::sl4: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); break; - default: - log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); - } -} -security_mode_cmd_s::crit_exts_c_::crit_exts_c_(const security_mode_cmd_s::crit_exts_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::security_mode_cmd: - c.init(other.c.get()); + case types::sl5: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); break; - case types::crit_exts_future: + case types::sl8: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); break; - case types::nulltype: + case types::sl10: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); break; - default: - log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); - } -} -security_mode_cmd_s::crit_exts_c_& security_mode_cmd_s::crit_exts_c_:: - operator=(const security_mode_cmd_s::crit_exts_c_& other) -{ - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::security_mode_cmd: - c.set(other.c.get()); + case types::sl16: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); break; - case types::crit_exts_future: + case types::sl20: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); break; - case types::nulltype: + case types::sl40: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); break; - default: - log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); - } - - return *this; -} -void security_mode_cmd_s::crit_exts_c_::to_json(json_writer& j) const -{ - j.start_obj(); - switch (type_) { - case types::security_mode_cmd: - j.write_fieldname("securityModeCommand"); - c.get().to_json(j); + case types::sl80: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); break; - case types::crit_exts_future: + case types::sl160: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); break; - default: - log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); - } - j.end_obj(); -} -SRSASN_CODE security_mode_cmd_s::crit_exts_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::security_mode_cmd: - HANDLE_CODE(c.get().pack(bref)); + case types::sl320: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); break; - case types::crit_exts_future: + case types::sl640: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); break; default: - log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE security_mode_cmd_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE sched_request_res_cfg_s::periodicity_and_offset_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::security_mode_cmd: - HANDLE_CODE(c.get().unpack(bref)); + case types::sym2: break; - case types::crit_exts_future: + case types::sym6or7: + break; + case types::sl1: + break; + case types::sl2: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)1u)); + break; + case types::sl4: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); + break; + case types::sl5: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); + break; + case types::sl8: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); + break; + case types::sl10: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); + break; + case types::sl16: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); + break; + case types::sl20: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); + break; + case types::sl40: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); + break; + case types::sl80: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); + break; + case types::sl160: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + break; + case types::sl320: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + break; + case types::sl640: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); break; default: - log_invalid_choice_id(type_, "security_mode_cmd_s::crit_exts_c_"); + log_invalid_choice_id(type_, "sched_request_res_cfg_s::periodicity_and_offset_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string security_mode_cmd_s::crit_exts_c_::types_opts::to_string() const +std::string sched_request_res_cfg_s::periodicity_and_offset_c_::types_opts::to_string() const { - static const char* options[] = {"securityModeCommand", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "security_mode_cmd_s::crit_exts_c_::types"); + static const char* options[] = {"sym2", + "sym6or7", + "sl1", + "sl2", + "sl4", + "sl5", + "sl8", + "sl10", + "sl16", + "sl20", + "sl40", + "sl80", + "sl160", + "sl320", + "sl640"}; + return convert_enum_idx(options, 15, value, "sched_request_res_cfg_s::periodicity_and_offset_c_::types"); } -// UECapabilityEnquiry ::= SEQUENCE -SRSASN_CODE ue_cap_enquiry_s::pack(bit_ref& bref) const +// UCI-OnPUSCH ::= SEQUENCE +SRSASN_CODE uci_on_pusch_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + HANDLE_CODE(bref.pack(beta_offsets_present, 1)); + + if (beta_offsets_present) { + HANDLE_CODE(beta_offsets.pack(bref)); + } + HANDLE_CODE(scaling.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ue_cap_enquiry_s::unpack(cbit_ref& bref) +SRSASN_CODE uci_on_pusch_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + HANDLE_CODE(bref.unpack(beta_offsets_present, 1)); + + if (beta_offsets_present) { + HANDLE_CODE(beta_offsets.unpack(bref)); + } + HANDLE_CODE(scaling.unpack(bref)); return SRSASN_SUCCESS; } -void ue_cap_enquiry_s::to_json(json_writer& j) const +void uci_on_pusch_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + if (beta_offsets_present) { + j.write_fieldname("betaOffsets"); + beta_offsets.to_json(j); + } + j.write_str("scaling", scaling.to_string()); j.end_obj(); } -void ue_cap_enquiry_s::crit_exts_c_::destroy_() +void uci_on_pusch_s::beta_offsets_c_::destroy_() { switch (type_) { - case types::ue_cap_enquiry: - c.destroy(); + case types::dynamic_type: + c.destroy(); + break; + case types::semi_static: + c.destroy(); break; default: break; } } -void ue_cap_enquiry_s::crit_exts_c_::set(types::options e) +void uci_on_pusch_s::beta_offsets_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ue_cap_enquiry: - c.init(); + case types::dynamic_type: + c.init(); break; - case types::crit_exts_future: + case types::semi_static: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); } } -ue_cap_enquiry_s::crit_exts_c_::crit_exts_c_(const ue_cap_enquiry_s::crit_exts_c_& other) +uci_on_pusch_s::beta_offsets_c_::beta_offsets_c_(const uci_on_pusch_s::beta_offsets_c_& other) { type_ = other.type(); switch (type_) { - case types::ue_cap_enquiry: - c.init(other.c.get()); + case types::dynamic_type: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::semi_static: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); } } -ue_cap_enquiry_s::crit_exts_c_& ue_cap_enquiry_s::crit_exts_c_::operator=(const ue_cap_enquiry_s::crit_exts_c_& other) +uci_on_pusch_s::beta_offsets_c_& +uci_on_pusch_s::beta_offsets_c_::operator=(const uci_on_pusch_s::beta_offsets_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ue_cap_enquiry: - c.set(other.c.get()); + case types::dynamic_type: + c.set(other.c.get()); break; - case types::crit_exts_future: + case types::semi_static: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); } return *this; } -void ue_cap_enquiry_s::crit_exts_c_::to_json(json_writer& j) const +void uci_on_pusch_s::beta_offsets_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ue_cap_enquiry: - j.write_fieldname("ueCapabilityEnquiry"); - c.get().to_json(j); + case types::dynamic_type: + j.start_array("dynamic"); + for (const auto& e1 : c.get()) { + e1.to_json(j); + } + j.end_array(); break; - case types::crit_exts_future: + case types::semi_static: + j.write_fieldname("semiStatic"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); } j.end_obj(); } -SRSASN_CODE ue_cap_enquiry_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE uci_on_pusch_s::beta_offsets_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ue_cap_enquiry: - HANDLE_CODE(c.get().pack(bref)); + case types::dynamic_type: + HANDLE_CODE(pack_fixed_seq_of(bref, &(c.get())[0], c.get().size())); break; - case types::crit_exts_future: + case types::semi_static: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE ue_cap_enquiry_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE uci_on_pusch_s::beta_offsets_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ue_cap_enquiry: - HANDLE_CODE(c.get().unpack(bref)); + case types::dynamic_type: + HANDLE_CODE(unpack_fixed_seq_of(&(c.get())[0], bref, c.get().size())); break; - case types::crit_exts_future: + case types::semi_static: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "ue_cap_enquiry_s::crit_exts_c_"); + log_invalid_choice_id(type_, "uci_on_pusch_s::beta_offsets_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string ue_cap_enquiry_s::crit_exts_c_::types_opts::to_string() const +std::string uci_on_pusch_s::beta_offsets_c_::types_opts::to_string() const { - static const char* options[] = {"ueCapabilityEnquiry", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "ue_cap_enquiry_s::crit_exts_c_::types"); + static const char* options[] = {"dynamic", "semiStatic"}; + return convert_enum_idx(options, 2, value, "uci_on_pusch_s::beta_offsets_c_::types"); } -// DL-DCCH-MessageType ::= CHOICE -void dl_dcch_msg_type_c::destroy_() +std::string uci_on_pusch_s::scaling_opts::to_string() const { - switch (type_) { - case types::c1: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"f0p5", "f0p65", "f0p8", "f1"}; + return convert_enum_idx(options, 4, value, "uci_on_pusch_s::scaling_e_"); } -void dl_dcch_msg_type_c::set(types::options e) + +// BeamFailureRecoveryConfig ::= SEQUENCE +SRSASN_CODE beam_fail_recovery_cfg_s::pack(bit_ref& bref) const { - destroy_(); - type_ = e; - switch (type_) { - case types::c1: - c.init(); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(root_seq_idx_bfr_present, 1)); + HANDLE_CODE(bref.pack(rach_cfg_bfr_present, 1)); + HANDLE_CODE(bref.pack(rsrp_thres_ssb_present, 1)); + HANDLE_CODE(bref.pack(candidate_beam_rs_list_present, 1)); + HANDLE_CODE(bref.pack(ssb_per_rach_occasion_present, 1)); + HANDLE_CODE(bref.pack(ra_ssb_occasion_mask_idx_present, 1)); + HANDLE_CODE(bref.pack(recovery_search_space_id_present, 1)); + HANDLE_CODE(bref.pack(ra_prioritization_present, 1)); + HANDLE_CODE(bref.pack(beam_fail_recovery_timer_present, 1)); + + if (root_seq_idx_bfr_present) { + HANDLE_CODE(pack_integer(bref, root_seq_idx_bfr, (uint8_t)0u, (uint8_t)137u)); } -} -dl_dcch_msg_type_c::dl_dcch_msg_type_c(const dl_dcch_msg_type_c& other) -{ - type_ = other.type(); - switch (type_) { - case types::c1: - c.init(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + if (rach_cfg_bfr_present) { + HANDLE_CODE(rach_cfg_bfr.pack(bref)); + } + if (rsrp_thres_ssb_present) { + HANDLE_CODE(pack_integer(bref, rsrp_thres_ssb, (uint8_t)0u, (uint8_t)127u)); + } + if (candidate_beam_rs_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, candidate_beam_rs_list, 1, 16)); + } + if (ssb_per_rach_occasion_present) { + HANDLE_CODE(ssb_per_rach_occasion.pack(bref)); + } + if (ra_ssb_occasion_mask_idx_present) { + HANDLE_CODE(pack_integer(bref, ra_ssb_occasion_mask_idx, (uint8_t)0u, (uint8_t)15u)); + } + if (recovery_search_space_id_present) { + HANDLE_CODE(pack_integer(bref, recovery_search_space_id, (uint8_t)0u, (uint8_t)39u)); + } + if (ra_prioritization_present) { + HANDLE_CODE(ra_prioritization.pack(bref)); + } + if (beam_fail_recovery_timer_present) { + HANDLE_CODE(beam_fail_recovery_timer.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= msg1_subcarrier_spacing_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(msg1_subcarrier_spacing_present, 1)); + if (msg1_subcarrier_spacing_present) { + HANDLE_CODE(msg1_subcarrier_spacing.pack(bref)); + } + } } + return SRSASN_SUCCESS; } -dl_dcch_msg_type_c& dl_dcch_msg_type_c::operator=(const dl_dcch_msg_type_c& other) +SRSASN_CODE beam_fail_recovery_cfg_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(root_seq_idx_bfr_present, 1)); + HANDLE_CODE(bref.unpack(rach_cfg_bfr_present, 1)); + HANDLE_CODE(bref.unpack(rsrp_thres_ssb_present, 1)); + HANDLE_CODE(bref.unpack(candidate_beam_rs_list_present, 1)); + HANDLE_CODE(bref.unpack(ssb_per_rach_occasion_present, 1)); + HANDLE_CODE(bref.unpack(ra_ssb_occasion_mask_idx_present, 1)); + HANDLE_CODE(bref.unpack(recovery_search_space_id_present, 1)); + HANDLE_CODE(bref.unpack(ra_prioritization_present, 1)); + HANDLE_CODE(bref.unpack(beam_fail_recovery_timer_present, 1)); + + if (root_seq_idx_bfr_present) { + HANDLE_CODE(unpack_integer(root_seq_idx_bfr, bref, (uint8_t)0u, (uint8_t)137u)); } - set(other.type()); - switch (type_) { - case types::c1: - c.set(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + if (rach_cfg_bfr_present) { + HANDLE_CODE(rach_cfg_bfr.unpack(bref)); + } + if (rsrp_thres_ssb_present) { + HANDLE_CODE(unpack_integer(rsrp_thres_ssb, bref, (uint8_t)0u, (uint8_t)127u)); + } + if (candidate_beam_rs_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(candidate_beam_rs_list, bref, 1, 16)); + } + if (ssb_per_rach_occasion_present) { + HANDLE_CODE(ssb_per_rach_occasion.unpack(bref)); + } + if (ra_ssb_occasion_mask_idx_present) { + HANDLE_CODE(unpack_integer(ra_ssb_occasion_mask_idx, bref, (uint8_t)0u, (uint8_t)15u)); + } + if (recovery_search_space_id_present) { + HANDLE_CODE(unpack_integer(recovery_search_space_id, bref, (uint8_t)0u, (uint8_t)39u)); + } + if (ra_prioritization_present) { + HANDLE_CODE(ra_prioritization.unpack(bref)); + } + if (beam_fail_recovery_timer_present) { + HANDLE_CODE(beam_fail_recovery_timer.unpack(bref)); } - return *this; + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(msg1_subcarrier_spacing_present, 1)); + if (msg1_subcarrier_spacing_present) { + HANDLE_CODE(msg1_subcarrier_spacing.unpack(bref)); + } + } + } + return SRSASN_SUCCESS; } -void dl_dcch_msg_type_c::to_json(json_writer& j) const +void beam_fail_recovery_cfg_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::c1: - j.write_fieldname("c1"); - c.get().to_json(j); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); + if (root_seq_idx_bfr_present) { + j.write_int("rootSequenceIndex-BFR", root_seq_idx_bfr); + } + if (rach_cfg_bfr_present) { + j.write_fieldname("rach-ConfigBFR"); + rach_cfg_bfr.to_json(j); + } + if (rsrp_thres_ssb_present) { + j.write_int("rsrp-ThresholdSSB", rsrp_thres_ssb); + } + if (candidate_beam_rs_list_present) { + j.start_array("candidateBeamRSList"); + for (const auto& e1 : candidate_beam_rs_list) { + e1.to_json(j); + } + j.end_array(); + } + if (ssb_per_rach_occasion_present) { + j.write_str("ssb-perRACH-Occasion", ssb_per_rach_occasion.to_string()); + } + if (ra_ssb_occasion_mask_idx_present) { + j.write_int("ra-ssb-OccasionMaskIndex", ra_ssb_occasion_mask_idx); + } + if (recovery_search_space_id_present) { + j.write_int("recoverySearchSpaceId", recovery_search_space_id); + } + if (ra_prioritization_present) { + j.write_fieldname("ra-Prioritization"); + ra_prioritization.to_json(j); + } + if (beam_fail_recovery_timer_present) { + j.write_str("beamFailureRecoveryTimer", beam_fail_recovery_timer.to_string()); + } + if (ext) { + if (msg1_subcarrier_spacing_present) { + j.write_str("msg1-SubcarrierSpacing", msg1_subcarrier_spacing.to_string()); + } } j.end_obj(); } -SRSASN_CODE dl_dcch_msg_type_c::pack(bit_ref& bref) const + +std::string beam_fail_recovery_cfg_s::ssb_per_rach_occasion_opts::to_string() const { - type_.pack(bref); - switch (type_) { - case types::c1: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"oneEighth", "oneFourth", "oneHalf", "one", "two", "four", "eight", "sixteen"}; + return convert_enum_idx(options, 8, value, "beam_fail_recovery_cfg_s::ssb_per_rach_occasion_e_"); } -SRSASN_CODE dl_dcch_msg_type_c::unpack(cbit_ref& bref) +float beam_fail_recovery_cfg_s::ssb_per_rach_occasion_opts::to_number() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::c1: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const float options[] = {0.125, 0.25, 0.5, 1.0, 2.0, 4.0, 8.0, 6.0}; + return map_enum_number(options, 8, value, "beam_fail_recovery_cfg_s::ssb_per_rach_occasion_e_"); } - -void dl_dcch_msg_type_c::c1_c_::destroy_() +std::string beam_fail_recovery_cfg_s::ssb_per_rach_occasion_opts::to_number_string() const { - switch (type_) { - case types::rrc_recfg: - c.destroy(); - break; - case types::rrc_resume: - c.destroy(); - break; - case types::rrc_release: - c.destroy(); - break; - case types::rrc_reest: - c.destroy(); - break; - case types::security_mode_cmd: - c.destroy(); - break; - case types::dl_info_transfer: - c.destroy(); - break; - case types::ue_cap_enquiry: - c.destroy(); - break; - case types::counter_check: - c.destroy(); - break; - case types::mob_from_nr_cmd: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"1/8", "1/4", "1/2", "1", "2", "4", "8", "6"}; + return convert_enum_idx(options, 8, value, "beam_fail_recovery_cfg_s::ssb_per_rach_occasion_e_"); } -void dl_dcch_msg_type_c::c1_c_::set(types::options e) + +std::string beam_fail_recovery_cfg_s::beam_fail_recovery_timer_opts::to_string() const { - destroy_(); - type_ = e; - switch (type_) { - case types::rrc_recfg: - c.init(); - break; - case types::rrc_resume: - c.init(); - break; - case types::rrc_release: - c.init(); - break; - case types::rrc_reest: - c.init(); - break; - case types::security_mode_cmd: - c.init(); - break; - case types::dl_info_transfer: - c.init(); - break; - case types::ue_cap_enquiry: - c.init(); - break; - case types::counter_check: - c.init(); - break; - case types::mob_from_nr_cmd: - c.init(); - break; - case types::spare7: - break; - case types::spare6: - break; - case types::spare5: - break; - case types::spare4: - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); - } + static const char* options[] = {"ms10", "ms20", "ms40", "ms60", "ms80", "ms100", "ms150", "ms200"}; + return convert_enum_idx(options, 8, value, "beam_fail_recovery_cfg_s::beam_fail_recovery_timer_e_"); } -dl_dcch_msg_type_c::c1_c_::c1_c_(const dl_dcch_msg_type_c::c1_c_& other) +uint8_t beam_fail_recovery_cfg_s::beam_fail_recovery_timer_opts::to_number() const { - type_ = other.type(); - switch (type_) { - case types::rrc_recfg: - c.init(other.c.get()); - break; - case types::rrc_resume: - c.init(other.c.get()); - break; - case types::rrc_release: - c.init(other.c.get()); - break; - case types::rrc_reest: - c.init(other.c.get()); - break; - case types::security_mode_cmd: - c.init(other.c.get()); - break; - case types::dl_info_transfer: - c.init(other.c.get()); - break; - case types::ue_cap_enquiry: - c.init(other.c.get()); - break; - case types::counter_check: - c.init(other.c.get()); - break; - case types::mob_from_nr_cmd: - c.init(other.c.get()); - break; - case types::spare7: - break; - case types::spare6: - break; - case types::spare5: - break; - case types::spare4: - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); - } + static const uint8_t options[] = {10, 20, 40, 60, 80, 100, 150, 200}; + return map_enum_number(options, 8, value, "beam_fail_recovery_cfg_s::beam_fail_recovery_timer_e_"); } -dl_dcch_msg_type_c::c1_c_& dl_dcch_msg_type_c::c1_c_::operator=(const dl_dcch_msg_type_c::c1_c_& other) + +// ConfiguredGrantConfig ::= SEQUENCE +SRSASN_CODE cfgured_grant_cfg_s::pack(bit_ref& bref) const { - if (this == &other) { - return *this; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(freq_hop_present, 1)); + HANDLE_CODE(bref.pack(mcs_table_present, 1)); + HANDLE_CODE(bref.pack(mcs_table_transform_precoder_present, 1)); + HANDLE_CODE(bref.pack(uci_on_pusch_present, 1)); + HANDLE_CODE(bref.pack(rbg_size_present, 1)); + HANDLE_CODE(bref.pack(transform_precoder_present, 1)); + HANDLE_CODE(bref.pack(rep_k_rv_present, 1)); + HANDLE_CODE(bref.pack(cfgured_grant_timer_present, 1)); + HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant_present, 1)); + + if (freq_hop_present) { + HANDLE_CODE(freq_hop.pack(bref)); } - set(other.type()); - switch (type_) { - case types::rrc_recfg: - c.set(other.c.get()); - break; - case types::rrc_resume: - c.set(other.c.get()); - break; - case types::rrc_release: - c.set(other.c.get()); - break; - case types::rrc_reest: - c.set(other.c.get()); - break; - case types::security_mode_cmd: - c.set(other.c.get()); - break; - case types::dl_info_transfer: - c.set(other.c.get()); - break; - case types::ue_cap_enquiry: - c.set(other.c.get()); - break; - case types::counter_check: - c.set(other.c.get()); - break; - case types::mob_from_nr_cmd: - c.set(other.c.get()); - break; - case types::spare7: - break; - case types::spare6: - break; - case types::spare5: - break; - case types::spare4: - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + HANDLE_CODE(cg_dmrs_cfg.pack(bref)); + if (mcs_table_present) { + HANDLE_CODE(mcs_table.pack(bref)); + } + if (mcs_table_transform_precoder_present) { + HANDLE_CODE(mcs_table_transform_precoder.pack(bref)); + } + if (uci_on_pusch_present) { + HANDLE_CODE(uci_on_pusch.pack(bref)); + } + HANDLE_CODE(res_alloc.pack(bref)); + HANDLE_CODE(pwr_ctrl_loop_to_use.pack(bref)); + HANDLE_CODE(pack_integer(bref, p0_pusch_alpha, (uint8_t)0u, (uint8_t)29u)); + if (transform_precoder_present) { + HANDLE_CODE(transform_precoder.pack(bref)); + } + HANDLE_CODE(pack_integer(bref, nrof_harq_processes, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(rep_k.pack(bref)); + if (rep_k_rv_present) { + HANDLE_CODE(rep_k_rv.pack(bref)); + } + HANDLE_CODE(periodicity.pack(bref)); + if (cfgured_grant_timer_present) { + HANDLE_CODE(pack_integer(bref, cfgured_grant_timer, (uint8_t)1u, (uint8_t)64u)); + } + if (rrc_cfgured_ul_grant_present) { + bref.pack(rrc_cfgured_ul_grant.ext, 1); + HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant.dmrs_seq_initization_present, 1)); + HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant.srs_res_ind_present, 1)); + HANDLE_CODE(bref.pack(rrc_cfgured_ul_grant.freq_hop_offset_present, 1)); + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.time_domain_offset, (uint16_t)0u, (uint16_t)5119u)); + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.time_domain_alloc, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(rrc_cfgured_ul_grant.freq_domain_alloc.pack(bref)); + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.ant_port, (uint8_t)0u, (uint8_t)31u)); + if (rrc_cfgured_ul_grant.dmrs_seq_initization_present) { + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.dmrs_seq_initization, (uint8_t)0u, (uint8_t)1u)); + } + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.precoding_and_nof_layers, (uint8_t)0u, (uint8_t)63u)); + if (rrc_cfgured_ul_grant.srs_res_ind_present) { + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.srs_res_ind, (uint8_t)0u, (uint8_t)15u)); + } + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.mcs_and_tbs, (uint8_t)0u, (uint8_t)31u)); + if (rrc_cfgured_ul_grant.freq_hop_offset_present) { + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.freq_hop_offset, (uint16_t)1u, (uint16_t)274u)); + } + HANDLE_CODE(pack_integer(bref, rrc_cfgured_ul_grant.pathloss_ref_idx, (uint8_t)0u, (uint8_t)3u)); } - return *this; + return SRSASN_SUCCESS; } -void dl_dcch_msg_type_c::c1_c_::to_json(json_writer& j) const +SRSASN_CODE cfgured_grant_cfg_s::unpack(cbit_ref& bref) { - j.start_obj(); - switch (type_) { - case types::rrc_recfg: - j.write_fieldname("rrcReconfiguration"); - c.get().to_json(j); - break; - case types::rrc_resume: - j.write_fieldname("rrcResume"); - c.get().to_json(j); - break; - case types::rrc_release: - j.write_fieldname("rrcRelease"); - c.get().to_json(j); - break; - case types::rrc_reest: - j.write_fieldname("rrcReestablishment"); - c.get().to_json(j); - break; - case types::security_mode_cmd: - j.write_fieldname("securityModeCommand"); - c.get().to_json(j); - break; - case types::dl_info_transfer: - j.write_fieldname("dlInformationTransfer"); - c.get().to_json(j); - break; - case types::ue_cap_enquiry: - j.write_fieldname("ueCapabilityEnquiry"); - c.get().to_json(j); - break; - case types::counter_check: - j.write_fieldname("counterCheck"); - c.get().to_json(j); - break; - case types::mob_from_nr_cmd: - j.write_fieldname("mobilityFromNRCommand"); - c.get().to_json(j); - break; - case types::spare7: - break; - case types::spare6: - break; - case types::spare5: - break; - case types::spare4: - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(freq_hop_present, 1)); + HANDLE_CODE(bref.unpack(mcs_table_present, 1)); + HANDLE_CODE(bref.unpack(mcs_table_transform_precoder_present, 1)); + HANDLE_CODE(bref.unpack(uci_on_pusch_present, 1)); + HANDLE_CODE(bref.unpack(rbg_size_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoder_present, 1)); + HANDLE_CODE(bref.unpack(rep_k_rv_present, 1)); + HANDLE_CODE(bref.unpack(cfgured_grant_timer_present, 1)); + HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant_present, 1)); + + if (freq_hop_present) { + HANDLE_CODE(freq_hop.unpack(bref)); } - j.end_obj(); -} -SRSASN_CODE dl_dcch_msg_type_c::c1_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::rrc_recfg: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_resume: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_release: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_reest: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::security_mode_cmd: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::dl_info_transfer: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::ue_cap_enquiry: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::counter_check: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::mob_from_nr_cmd: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::spare7: - break; - case types::spare6: - break; - case types::spare5: - break; - case types::spare4: - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + HANDLE_CODE(cg_dmrs_cfg.unpack(bref)); + if (mcs_table_present) { + HANDLE_CODE(mcs_table.unpack(bref)); + } + if (mcs_table_transform_precoder_present) { + HANDLE_CODE(mcs_table_transform_precoder.unpack(bref)); + } + if (uci_on_pusch_present) { + HANDLE_CODE(uci_on_pusch.unpack(bref)); + } + HANDLE_CODE(res_alloc.unpack(bref)); + HANDLE_CODE(pwr_ctrl_loop_to_use.unpack(bref)); + HANDLE_CODE(unpack_integer(p0_pusch_alpha, bref, (uint8_t)0u, (uint8_t)29u)); + if (transform_precoder_present) { + HANDLE_CODE(transform_precoder.unpack(bref)); + } + HANDLE_CODE(unpack_integer(nrof_harq_processes, bref, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(rep_k.unpack(bref)); + if (rep_k_rv_present) { + HANDLE_CODE(rep_k_rv.unpack(bref)); + } + HANDLE_CODE(periodicity.unpack(bref)); + if (cfgured_grant_timer_present) { + HANDLE_CODE(unpack_integer(cfgured_grant_timer, bref, (uint8_t)1u, (uint8_t)64u)); + } + if (rrc_cfgured_ul_grant_present) { + bref.unpack(rrc_cfgured_ul_grant.ext, 1); + HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant.dmrs_seq_initization_present, 1)); + HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant.srs_res_ind_present, 1)); + HANDLE_CODE(bref.unpack(rrc_cfgured_ul_grant.freq_hop_offset_present, 1)); + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.time_domain_offset, bref, (uint16_t)0u, (uint16_t)5119u)); + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.time_domain_alloc, bref, (uint8_t)0u, (uint8_t)15u)); + HANDLE_CODE(rrc_cfgured_ul_grant.freq_domain_alloc.unpack(bref)); + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.ant_port, bref, (uint8_t)0u, (uint8_t)31u)); + if (rrc_cfgured_ul_grant.dmrs_seq_initization_present) { + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.dmrs_seq_initization, bref, (uint8_t)0u, (uint8_t)1u)); + } + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.precoding_and_nof_layers, bref, (uint8_t)0u, (uint8_t)63u)); + if (rrc_cfgured_ul_grant.srs_res_ind_present) { + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.srs_res_ind, bref, (uint8_t)0u, (uint8_t)15u)); + } + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.mcs_and_tbs, bref, (uint8_t)0u, (uint8_t)31u)); + if (rrc_cfgured_ul_grant.freq_hop_offset_present) { + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.freq_hop_offset, bref, (uint16_t)1u, (uint16_t)274u)); + } + HANDLE_CODE(unpack_integer(rrc_cfgured_ul_grant.pathloss_ref_idx, bref, (uint8_t)0u, (uint8_t)3u)); } + return SRSASN_SUCCESS; } -SRSASN_CODE dl_dcch_msg_type_c::c1_c_::unpack(cbit_ref& bref) +void cfgured_grant_cfg_s::to_json(json_writer& j) const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::rrc_recfg: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_resume: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_release: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_reest: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::security_mode_cmd: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::dl_info_transfer: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::ue_cap_enquiry: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::counter_check: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::mob_from_nr_cmd: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::spare7: - break; - case types::spare6: - break; - case types::spare5: - break; - case types::spare4: - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "dl_dcch_msg_type_c::c1_c_"); - return SRSASN_ERROR_DECODE_FAIL; + j.start_obj(); + if (freq_hop_present) { + j.write_str("frequencyHopping", freq_hop.to_string()); } - return SRSASN_SUCCESS; + j.write_fieldname("cg-DMRS-Configuration"); + cg_dmrs_cfg.to_json(j); + if (mcs_table_present) { + j.write_str("mcs-Table", mcs_table.to_string()); + } + if (mcs_table_transform_precoder_present) { + j.write_str("mcs-TableTransformPrecoder", mcs_table_transform_precoder.to_string()); + } + if (uci_on_pusch_present) { + j.write_fieldname("uci-OnPUSCH"); + uci_on_pusch.to_json(j); + } + j.write_str("resourceAllocation", res_alloc.to_string()); + if (rbg_size_present) { + j.write_str("rbg-Size", "config2"); + } + j.write_str("powerControlLoopToUse", pwr_ctrl_loop_to_use.to_string()); + j.write_int("p0-PUSCH-Alpha", p0_pusch_alpha); + if (transform_precoder_present) { + j.write_str("transformPrecoder", transform_precoder.to_string()); + } + j.write_int("nrofHARQ-Processes", nrof_harq_processes); + j.write_str("repK", rep_k.to_string()); + if (rep_k_rv_present) { + j.write_str("repK-RV", rep_k_rv.to_string()); + } + j.write_str("periodicity", periodicity.to_string()); + if (cfgured_grant_timer_present) { + j.write_int("configuredGrantTimer", cfgured_grant_timer); + } + if (rrc_cfgured_ul_grant_present) { + j.write_fieldname("rrc-ConfiguredUplinkGrant"); + j.start_obj(); + j.write_int("timeDomainOffset", rrc_cfgured_ul_grant.time_domain_offset); + j.write_int("timeDomainAllocation", rrc_cfgured_ul_grant.time_domain_alloc); + j.write_str("frequencyDomainAllocation", rrc_cfgured_ul_grant.freq_domain_alloc.to_string()); + j.write_int("antennaPort", rrc_cfgured_ul_grant.ant_port); + if (rrc_cfgured_ul_grant.dmrs_seq_initization_present) { + j.write_int("dmrs-SeqInitialization", rrc_cfgured_ul_grant.dmrs_seq_initization); + } + j.write_int("precodingAndNumberOfLayers", rrc_cfgured_ul_grant.precoding_and_nof_layers); + if (rrc_cfgured_ul_grant.srs_res_ind_present) { + j.write_int("srs-ResourceIndicator", rrc_cfgured_ul_grant.srs_res_ind); + } + j.write_int("mcsAndTBS", rrc_cfgured_ul_grant.mcs_and_tbs); + if (rrc_cfgured_ul_grant.freq_hop_offset_present) { + j.write_int("frequencyHoppingOffset", rrc_cfgured_ul_grant.freq_hop_offset); + } + j.write_int("pathlossReferenceIndex", rrc_cfgured_ul_grant.pathloss_ref_idx); + j.end_obj(); + } + j.end_obj(); } -std::string dl_dcch_msg_type_c::c1_c_::types_opts::to_string() const +std::string cfgured_grant_cfg_s::freq_hop_opts::to_string() const { - static const char* options[] = {"rrcReconfiguration", - "rrcResume", - "rrcRelease", - "rrcReestablishment", - "securityModeCommand", - "dlInformationTransfer", - "ueCapabilityEnquiry", - "counterCheck", - "mobilityFromNRCommand", - "spare7", - "spare6", - "spare5", - "spare4", - "spare3", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "dl_dcch_msg_type_c::c1_c_::types"); + static const char* options[] = {"intraSlot", "interSlot"}; + return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::freq_hop_e_"); } -std::string dl_dcch_msg_type_c::types_opts::to_string() const +std::string cfgured_grant_cfg_s::mcs_table_opts::to_string() const { - static const char* options[] = {"c1", "messageClassExtension"}; - return convert_enum_idx(options, 2, value, "dl_dcch_msg_type_c::types"); + static const char* options[] = {"qam256", "qam64LowSE"}; + return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::mcs_table_e_"); } -uint8_t dl_dcch_msg_type_c::types_opts::to_number() const +uint16_t cfgured_grant_cfg_s::mcs_table_opts::to_number() const { - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "dl_dcch_msg_type_c::types"); + static const uint16_t options[] = {256, 64}; + return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::mcs_table_e_"); } -// DL-DCCH-Message ::= SEQUENCE -SRSASN_CODE dl_dcch_msg_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(msg.pack(bref)); - - bref.align_bytes_zero(); - - return SRSASN_SUCCESS; -} -SRSASN_CODE dl_dcch_msg_s::unpack(cbit_ref& bref) +std::string cfgured_grant_cfg_s::mcs_table_transform_precoder_opts::to_string() const { - HANDLE_CODE(msg.unpack(bref)); - - bref.align_bytes(); - - return SRSASN_SUCCESS; + static const char* options[] = {"qam256", "qam64LowSE"}; + return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::mcs_table_transform_precoder_e_"); } -void dl_dcch_msg_s::to_json(json_writer& j) const +uint16_t cfgured_grant_cfg_s::mcs_table_transform_precoder_opts::to_number() const { - j.start_array(); - j.start_obj(); - j.start_obj("DL-DCCH-Message"); - j.write_fieldname("message"); - msg.to_json(j); - j.end_obj(); - j.end_obj(); - j.end_array(); + static const uint16_t options[] = {256, 64}; + return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::mcs_table_transform_precoder_e_"); } -// PagingUE-Identity ::= CHOICE -void paging_ue_id_c::destroy_() -{ - switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.destroy >(); - break; - case types::full_i_rnti: - c.destroy >(); - break; - default: - break; - } -} -void paging_ue_id_c::set(types::options e) +std::string cfgured_grant_cfg_s::res_alloc_opts::to_string() const { - destroy_(); - type_ = e; - switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.init >(); - break; - case types::full_i_rnti: - c.init >(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "paging_ue_id_c"); - } + static const char* options[] = {"resourceAllocationType0", "resourceAllocationType1", "dynamicSwitch"}; + return convert_enum_idx(options, 3, value, "cfgured_grant_cfg_s::res_alloc_e_"); } -paging_ue_id_c::paging_ue_id_c(const paging_ue_id_c& other) +uint8_t cfgured_grant_cfg_s::res_alloc_opts::to_number() const { - type_ = other.type(); - switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.init(other.c.get >()); - break; - case types::full_i_rnti: - c.init(other.c.get >()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "paging_ue_id_c"); - } + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::res_alloc_e_"); } -paging_ue_id_c& paging_ue_id_c::operator=(const paging_ue_id_c& other) -{ - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.set(other.c.get >()); - break; - case types::full_i_rnti: - c.set(other.c.get >()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "paging_ue_id_c"); - } - return *this; -} -void paging_ue_id_c::to_json(json_writer& j) const +std::string cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_opts::to_string() const { - j.start_obj(); - switch (type_) { - case types::ng_minus5_g_s_tmsi: - j.write_str("ng-5G-S-TMSI", c.get >().to_string()); - break; - case types::full_i_rnti: - j.write_str("fullI-RNTI", c.get >().to_string()); - break; - default: - log_invalid_choice_id(type_, "paging_ue_id_c"); - } - j.end_obj(); + static const char* options[] = {"n0", "n1"}; + return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_e_"); } -SRSASN_CODE paging_ue_id_c::pack(bit_ref& bref) const +uint8_t cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_opts::to_number() const { - type_.pack(bref); - switch (type_) { - case types::ng_minus5_g_s_tmsi: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::full_i_rnti: - HANDLE_CODE(c.get >().pack(bref)); - break; - default: - log_invalid_choice_id(type_, "paging_ue_id_c"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "cfgured_grant_cfg_s::pwr_ctrl_loop_to_use_e_"); } -SRSASN_CODE paging_ue_id_c::unpack(cbit_ref& bref) + +std::string cfgured_grant_cfg_s::transform_precoder_opts::to_string() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::ng_minus5_g_s_tmsi: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::full_i_rnti: - HANDLE_CODE(c.get >().unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "paging_ue_id_c"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"enabled", "disabled"}; + return convert_enum_idx(options, 2, value, "cfgured_grant_cfg_s::transform_precoder_e_"); } -std::string paging_ue_id_c::types_opts::to_string() const +std::string cfgured_grant_cfg_s::rep_k_opts::to_string() const { - static const char* options[] = {"ng-5G-S-TMSI", "fullI-RNTI"}; - return convert_enum_idx(options, 2, value, "paging_ue_id_c::types"); + static const char* options[] = {"n1", "n2", "n4", "n8"}; + return convert_enum_idx(options, 4, value, "cfgured_grant_cfg_s::rep_k_e_"); } -int8_t paging_ue_id_c::types_opts::to_number() const +uint8_t cfgured_grant_cfg_s::rep_k_opts::to_number() const { - static const int8_t options[] = {-5}; - return map_enum_number(options, 1, value, "paging_ue_id_c::types"); + static const uint8_t options[] = {1, 2, 4, 8}; + return map_enum_number(options, 4, value, "cfgured_grant_cfg_s::rep_k_e_"); } -// PagingRecord ::= SEQUENCE -SRSASN_CODE paging_record_s::pack(bit_ref& bref) const +std::string cfgured_grant_cfg_s::rep_k_rv_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(access_type_present, 1)); - - HANDLE_CODE(ue_id.pack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"s1-0231", "s2-0303", "s3-0000"}; + return convert_enum_idx(options, 3, value, "cfgured_grant_cfg_s::rep_k_rv_e_"); } -SRSASN_CODE paging_record_s::unpack(cbit_ref& bref) +uint8_t cfgured_grant_cfg_s::rep_k_rv_opts::to_number() const { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(access_type_present, 1)); - - HANDLE_CODE(ue_id.unpack(bref)); - - return SRSASN_SUCCESS; + static const uint8_t options[] = {1, 2, 3}; + return map_enum_number(options, 3, value, "cfgured_grant_cfg_s::rep_k_rv_e_"); } -void paging_record_s::to_json(json_writer& j) const + +std::string cfgured_grant_cfg_s::periodicity_opts::to_string() const { - j.start_obj(); - j.write_fieldname("ue-Identity"); - ue_id.to_json(j); - if (access_type_present) { - j.write_str("accessType", "non3GPP"); - } - j.end_obj(); + static const char* options[] = { + "sym2", "sym7", "sym1x14", "sym2x14", "sym4x14", "sym5x14", "sym8x14", "sym10x14", + "sym16x14", "sym20x14", "sym32x14", "sym40x14", "sym64x14", "sym80x14", "sym128x14", "sym160x14", + "sym256x14", "sym320x14", "sym512x14", "sym640x14", "sym1024x14", "sym1280x14", "sym2560x14", "sym5120x14", + "sym6", "sym1x12", "sym2x12", "sym4x12", "sym5x12", "sym8x12", "sym10x12", "sym16x12", + "sym20x12", "sym32x12", "sym40x12", "sym64x12", "sym80x12", "sym128x12", "sym160x12", "sym256x12", + "sym320x12", "sym512x12", "sym640x12", "sym1280x12", "sym2560x12"}; + return convert_enum_idx(options, 45, value, "cfgured_grant_cfg_s::periodicity_e_"); } -// Paging ::= SEQUENCE -SRSASN_CODE paging_s::pack(bit_ref& bref) const +// PUCCH-Config ::= SEQUENCE +SRSASN_CODE pucch_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(paging_record_list_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(res_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(format1_present, 1)); + HANDLE_CODE(bref.pack(format2_present, 1)); + HANDLE_CODE(bref.pack(format3_present, 1)); + HANDLE_CODE(bref.pack(format4_present, 1)); + HANDLE_CODE(bref.pack(sched_request_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(sched_request_res_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(multi_csi_pucch_res_list_present, 1)); + HANDLE_CODE(bref.pack(dl_data_to_ul_ack_present, 1)); + HANDLE_CODE(bref.pack(spatial_relation_info_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(spatial_relation_info_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(pucch_pwr_ctrl_present, 1)); - if (paging_record_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, paging_record_list, 1, 32)); + if (res_set_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, res_set_to_add_mod_list, 1, 4)); } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); + if (res_set_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, res_set_to_release_list, 1, 4, integer_packer(0, 3))); } - - return SRSASN_SUCCESS; -} -SRSASN_CODE paging_s::unpack(cbit_ref& bref) + if (res_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, res_to_add_mod_list, 1, 128)); + } + if (res_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, res_to_release_list, 1, 128, integer_packer(0, 127))); + } + if (format1_present) { + HANDLE_CODE(format1.pack(bref)); + } + if (format2_present) { + HANDLE_CODE(format2.pack(bref)); + } + if (format3_present) { + HANDLE_CODE(format3.pack(bref)); + } + if (format4_present) { + HANDLE_CODE(format4.pack(bref)); + } + if (sched_request_res_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_res_to_add_mod_list, 1, 8)); + } + if (sched_request_res_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_res_to_release_list, 1, 8, integer_packer(1, 8))); + } + if (multi_csi_pucch_res_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, multi_csi_pucch_res_list, 1, 2, integer_packer(0, 127))); + } + if (dl_data_to_ul_ack_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, dl_data_to_ul_ack, 1, 8, integer_packer(0, 15))); + } + if (spatial_relation_info_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, spatial_relation_info_to_add_mod_list, 1, 8)); + } + if (spatial_relation_info_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, spatial_relation_info_to_release_list, 1, 8, integer_packer(1, 8))); + } + if (pucch_pwr_ctrl_present) { + HANDLE_CODE(pucch_pwr_ctrl.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE pucch_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(paging_record_list_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(res_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(format1_present, 1)); + HANDLE_CODE(bref.unpack(format2_present, 1)); + HANDLE_CODE(bref.unpack(format3_present, 1)); + HANDLE_CODE(bref.unpack(format4_present, 1)); + HANDLE_CODE(bref.unpack(sched_request_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(sched_request_res_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(multi_csi_pucch_res_list_present, 1)); + HANDLE_CODE(bref.unpack(dl_data_to_ul_ack_present, 1)); + HANDLE_CODE(bref.unpack(spatial_relation_info_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(spatial_relation_info_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(pucch_pwr_ctrl_present, 1)); - if (paging_record_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(paging_record_list, bref, 1, 32)); + if (res_set_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(res_set_to_add_mod_list, bref, 1, 4)); } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + if (res_set_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(res_set_to_release_list, bref, 1, 4, integer_packer(0, 3))); + } + if (res_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(res_to_add_mod_list, bref, 1, 128)); + } + if (res_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(res_to_release_list, bref, 1, 128, integer_packer(0, 127))); + } + if (format1_present) { + HANDLE_CODE(format1.unpack(bref)); + } + if (format2_present) { + HANDLE_CODE(format2.unpack(bref)); + } + if (format3_present) { + HANDLE_CODE(format3.unpack(bref)); + } + if (format4_present) { + HANDLE_CODE(format4.unpack(bref)); + } + if (sched_request_res_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sched_request_res_to_add_mod_list, bref, 1, 8)); + } + if (sched_request_res_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sched_request_res_to_release_list, bref, 1, 8, integer_packer(1, 8))); + } + if (multi_csi_pucch_res_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(multi_csi_pucch_res_list, bref, 1, 2, integer_packer(0, 127))); + } + if (dl_data_to_ul_ack_present) { + HANDLE_CODE(unpack_dyn_seq_of(dl_data_to_ul_ack, bref, 1, 8, integer_packer(0, 15))); + } + if (spatial_relation_info_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(spatial_relation_info_to_add_mod_list, bref, 1, 8)); + } + if (spatial_relation_info_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(spatial_relation_info_to_release_list, bref, 1, 8, integer_packer(1, 8))); + } + if (pucch_pwr_ctrl_present) { + HANDLE_CODE(pucch_pwr_ctrl.unpack(bref)); } return SRSASN_SUCCESS; } -void paging_s::to_json(json_writer& j) const +void pucch_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (paging_record_list_present) { - j.start_array("pagingRecordList"); - for (const auto& e1 : paging_record_list) { + if (res_set_to_add_mod_list_present) { + j.start_array("resourceSetToAddModList"); + for (const auto& e1 : res_set_to_add_mod_list) { e1.to_json(j); } j.end_array(); } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + if (res_set_to_release_list_present) { + j.start_array("resourceSetToReleaseList"); + for (const auto& e1 : res_set_to_release_list) { + j.write_int(e1); + } + j.end_array(); } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + if (res_to_add_mod_list_present) { + j.start_array("resourceToAddModList"); + for (const auto& e1 : res_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (res_to_release_list_present) { + j.start_array("resourceToReleaseList"); + for (const auto& e1 : res_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (format1_present) { + j.write_fieldname("format1"); + format1.to_json(j); + } + if (format2_present) { + j.write_fieldname("format2"); + format2.to_json(j); + } + if (format3_present) { + j.write_fieldname("format3"); + format3.to_json(j); + } + if (format4_present) { + j.write_fieldname("format4"); + format4.to_json(j); + } + if (sched_request_res_to_add_mod_list_present) { + j.start_array("schedulingRequestResourceToAddModList"); + for (const auto& e1 : sched_request_res_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (sched_request_res_to_release_list_present) { + j.start_array("schedulingRequestResourceToReleaseList"); + for (const auto& e1 : sched_request_res_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (multi_csi_pucch_res_list_present) { + j.start_array("multi-CSI-PUCCH-ResourceList"); + for (const auto& e1 : multi_csi_pucch_res_list) { + j.write_int(e1); + } + j.end_array(); + } + if (dl_data_to_ul_ack_present) { + j.start_array("dl-DataToUL-ACK"); + for (const auto& e1 : dl_data_to_ul_ack) { + j.write_int(e1); + } + j.end_array(); + } + if (spatial_relation_info_to_add_mod_list_present) { + j.start_array("spatialRelationInfoToAddModList"); + for (const auto& e1 : spatial_relation_info_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (spatial_relation_info_to_release_list_present) { + j.start_array("spatialRelationInfoToReleaseList"); + for (const auto& e1 : spatial_relation_info_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (pucch_pwr_ctrl_present) { + j.write_fieldname("pucch-PowerControl"); + pucch_pwr_ctrl.to_json(j); } j.end_obj(); } -// PCCH-MessageType ::= CHOICE -void pcch_msg_type_c::destroy_() +// PUSCH-Config ::= SEQUENCE +SRSASN_CODE pusch_cfg_s::pack(bit_ref& bref) const { - switch (type_) { - case types::c1: - c.destroy(); - break; - default: - break; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(data_scrambling_id_pusch_present, 1)); + HANDLE_CODE(bref.pack(tx_cfg_present, 1)); + HANDLE_CODE(bref.pack(dmrs_ul_for_pusch_map_type_a_present, 1)); + HANDLE_CODE(bref.pack(dmrs_ul_for_pusch_map_type_b_present, 1)); + HANDLE_CODE(bref.pack(pusch_pwr_ctrl_present, 1)); + HANDLE_CODE(bref.pack(freq_hop_present, 1)); + HANDLE_CODE(bref.pack(freq_hop_offset_lists_present, 1)); + HANDLE_CODE(bref.pack(pusch_time_domain_alloc_list_present, 1)); + HANDLE_CODE(bref.pack(pusch_aggregation_factor_present, 1)); + HANDLE_CODE(bref.pack(mcs_table_present, 1)); + HANDLE_CODE(bref.pack(mcs_table_transform_precoder_present, 1)); + HANDLE_CODE(bref.pack(transform_precoder_present, 1)); + HANDLE_CODE(bref.pack(codebook_subset_present, 1)); + HANDLE_CODE(bref.pack(max_rank_present, 1)); + HANDLE_CODE(bref.pack(rbg_size_present, 1)); + HANDLE_CODE(bref.pack(uci_on_pusch_present, 1)); + HANDLE_CODE(bref.pack(tp_pi2_bpsk_present, 1)); + + if (data_scrambling_id_pusch_present) { + HANDLE_CODE(pack_integer(bref, data_scrambling_id_pusch, (uint16_t)0u, (uint16_t)1023u)); } -} -void pcch_msg_type_c::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::c1: - c.init(); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c"); + if (tx_cfg_present) { + HANDLE_CODE(tx_cfg.pack(bref)); } -} -pcch_msg_type_c::pcch_msg_type_c(const pcch_msg_type_c& other) -{ - type_ = other.type(); - switch (type_) { - case types::c1: - c.init(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c"); + if (dmrs_ul_for_pusch_map_type_a_present) { + HANDLE_CODE(dmrs_ul_for_pusch_map_type_a.pack(bref)); + } + if (dmrs_ul_for_pusch_map_type_b_present) { + HANDLE_CODE(dmrs_ul_for_pusch_map_type_b.pack(bref)); + } + if (pusch_pwr_ctrl_present) { + HANDLE_CODE(pusch_pwr_ctrl.pack(bref)); + } + if (freq_hop_present) { + HANDLE_CODE(freq_hop.pack(bref)); + } + if (freq_hop_offset_lists_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, freq_hop_offset_lists, 1, 4, integer_packer(1, 274))); + } + HANDLE_CODE(res_alloc.pack(bref)); + if (pusch_time_domain_alloc_list_present) { + HANDLE_CODE(pusch_time_domain_alloc_list.pack(bref)); + } + if (pusch_aggregation_factor_present) { + HANDLE_CODE(pusch_aggregation_factor.pack(bref)); + } + if (mcs_table_present) { + HANDLE_CODE(mcs_table.pack(bref)); + } + if (mcs_table_transform_precoder_present) { + HANDLE_CODE(mcs_table_transform_precoder.pack(bref)); + } + if (transform_precoder_present) { + HANDLE_CODE(transform_precoder.pack(bref)); + } + if (codebook_subset_present) { + HANDLE_CODE(codebook_subset.pack(bref)); + } + if (max_rank_present) { + HANDLE_CODE(pack_integer(bref, max_rank, (uint8_t)1u, (uint8_t)4u)); + } + if (uci_on_pusch_present) { + HANDLE_CODE(uci_on_pusch.pack(bref)); } + + return SRSASN_SUCCESS; } -pcch_msg_type_c& pcch_msg_type_c::operator=(const pcch_msg_type_c& other) +SRSASN_CODE pusch_cfg_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(data_scrambling_id_pusch_present, 1)); + HANDLE_CODE(bref.unpack(tx_cfg_present, 1)); + HANDLE_CODE(bref.unpack(dmrs_ul_for_pusch_map_type_a_present, 1)); + HANDLE_CODE(bref.unpack(dmrs_ul_for_pusch_map_type_b_present, 1)); + HANDLE_CODE(bref.unpack(pusch_pwr_ctrl_present, 1)); + HANDLE_CODE(bref.unpack(freq_hop_present, 1)); + HANDLE_CODE(bref.unpack(freq_hop_offset_lists_present, 1)); + HANDLE_CODE(bref.unpack(pusch_time_domain_alloc_list_present, 1)); + HANDLE_CODE(bref.unpack(pusch_aggregation_factor_present, 1)); + HANDLE_CODE(bref.unpack(mcs_table_present, 1)); + HANDLE_CODE(bref.unpack(mcs_table_transform_precoder_present, 1)); + HANDLE_CODE(bref.unpack(transform_precoder_present, 1)); + HANDLE_CODE(bref.unpack(codebook_subset_present, 1)); + HANDLE_CODE(bref.unpack(max_rank_present, 1)); + HANDLE_CODE(bref.unpack(rbg_size_present, 1)); + HANDLE_CODE(bref.unpack(uci_on_pusch_present, 1)); + HANDLE_CODE(bref.unpack(tp_pi2_bpsk_present, 1)); + + if (data_scrambling_id_pusch_present) { + HANDLE_CODE(unpack_integer(data_scrambling_id_pusch, bref, (uint16_t)0u, (uint16_t)1023u)); } - set(other.type()); - switch (type_) { - case types::c1: - c.set(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c"); + if (tx_cfg_present) { + HANDLE_CODE(tx_cfg.unpack(bref)); + } + if (dmrs_ul_for_pusch_map_type_a_present) { + HANDLE_CODE(dmrs_ul_for_pusch_map_type_a.unpack(bref)); + } + if (dmrs_ul_for_pusch_map_type_b_present) { + HANDLE_CODE(dmrs_ul_for_pusch_map_type_b.unpack(bref)); + } + if (pusch_pwr_ctrl_present) { + HANDLE_CODE(pusch_pwr_ctrl.unpack(bref)); + } + if (freq_hop_present) { + HANDLE_CODE(freq_hop.unpack(bref)); + } + if (freq_hop_offset_lists_present) { + HANDLE_CODE(unpack_dyn_seq_of(freq_hop_offset_lists, bref, 1, 4, integer_packer(1, 274))); + } + HANDLE_CODE(res_alloc.unpack(bref)); + if (pusch_time_domain_alloc_list_present) { + HANDLE_CODE(pusch_time_domain_alloc_list.unpack(bref)); + } + if (pusch_aggregation_factor_present) { + HANDLE_CODE(pusch_aggregation_factor.unpack(bref)); + } + if (mcs_table_present) { + HANDLE_CODE(mcs_table.unpack(bref)); + } + if (mcs_table_transform_precoder_present) { + HANDLE_CODE(mcs_table_transform_precoder.unpack(bref)); + } + if (transform_precoder_present) { + HANDLE_CODE(transform_precoder.unpack(bref)); + } + if (codebook_subset_present) { + HANDLE_CODE(codebook_subset.unpack(bref)); + } + if (max_rank_present) { + HANDLE_CODE(unpack_integer(max_rank, bref, (uint8_t)1u, (uint8_t)4u)); + } + if (uci_on_pusch_present) { + HANDLE_CODE(uci_on_pusch.unpack(bref)); } - return *this; + return SRSASN_SUCCESS; } -void pcch_msg_type_c::to_json(json_writer& j) const +void pusch_cfg_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::c1: - j.write_fieldname("c1"); - c.get().to_json(j); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c"); + if (data_scrambling_id_pusch_present) { + j.write_int("dataScramblingIdentityPUSCH", data_scrambling_id_pusch); + } + if (tx_cfg_present) { + j.write_str("txConfig", tx_cfg.to_string()); + } + if (dmrs_ul_for_pusch_map_type_a_present) { + j.write_fieldname("dmrs-UplinkForPUSCH-MappingTypeA"); + dmrs_ul_for_pusch_map_type_a.to_json(j); + } + if (dmrs_ul_for_pusch_map_type_b_present) { + j.write_fieldname("dmrs-UplinkForPUSCH-MappingTypeB"); + dmrs_ul_for_pusch_map_type_b.to_json(j); + } + if (pusch_pwr_ctrl_present) { + j.write_fieldname("pusch-PowerControl"); + pusch_pwr_ctrl.to_json(j); + } + if (freq_hop_present) { + j.write_str("frequencyHopping", freq_hop.to_string()); + } + if (freq_hop_offset_lists_present) { + j.start_array("frequencyHoppingOffsetLists"); + for (const auto& e1 : freq_hop_offset_lists) { + j.write_int(e1); + } + j.end_array(); + } + j.write_str("resourceAllocation", res_alloc.to_string()); + if (pusch_time_domain_alloc_list_present) { + j.write_fieldname("pusch-TimeDomainAllocationList"); + pusch_time_domain_alloc_list.to_json(j); + } + if (pusch_aggregation_factor_present) { + j.write_str("pusch-AggregationFactor", pusch_aggregation_factor.to_string()); + } + if (mcs_table_present) { + j.write_str("mcs-Table", mcs_table.to_string()); + } + if (mcs_table_transform_precoder_present) { + j.write_str("mcs-TableTransformPrecoder", mcs_table_transform_precoder.to_string()); + } + if (transform_precoder_present) { + j.write_str("transformPrecoder", transform_precoder.to_string()); + } + if (codebook_subset_present) { + j.write_str("codebookSubset", codebook_subset.to_string()); + } + if (max_rank_present) { + j.write_int("maxRank", max_rank); + } + if (rbg_size_present) { + j.write_str("rbg-Size", "config2"); + } + if (uci_on_pusch_present) { + j.write_fieldname("uci-OnPUSCH"); + uci_on_pusch.to_json(j); + } + if (tp_pi2_bpsk_present) { + j.write_str("tp-pi2BPSK", "enabled"); } j.end_obj(); } -SRSASN_CODE pcch_msg_type_c::pack(bit_ref& bref) const + +std::string pusch_cfg_s::tx_cfg_opts::to_string() const { - type_.pack(bref); - switch (type_) { - case types::c1: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"codebook", "nonCodebook"}; + return convert_enum_idx(options, 2, value, "pusch_cfg_s::tx_cfg_e_"); } -SRSASN_CODE pcch_msg_type_c::unpack(cbit_ref& bref) + +std::string pusch_cfg_s::freq_hop_opts::to_string() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::c1: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"intraSlot", "interSlot"}; + return convert_enum_idx(options, 2, value, "pusch_cfg_s::freq_hop_e_"); } -void pcch_msg_type_c::c1_c_::set(types::options e) +std::string pusch_cfg_s::res_alloc_opts::to_string() const { - type_ = e; + static const char* options[] = {"resourceAllocationType0", "resourceAllocationType1", "dynamicSwitch"}; + return convert_enum_idx(options, 3, value, "pusch_cfg_s::res_alloc_e_"); } -void pcch_msg_type_c::c1_c_::to_json(json_writer& j) const +uint8_t pusch_cfg_s::res_alloc_opts::to_number() const { - j.start_obj(); - switch (type_) { - case types::paging: - j.write_fieldname("paging"); - c.to_json(j); - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c::c1_c_"); - } - j.end_obj(); + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "pusch_cfg_s::res_alloc_e_"); } -SRSASN_CODE pcch_msg_type_c::c1_c_::pack(bit_ref& bref) const + +std::string pusch_cfg_s::pusch_aggregation_factor_opts::to_string() const { - type_.pack(bref); - switch (type_) { - case types::paging: - HANDLE_CODE(c.pack(bref)); - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c::c1_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + static const char* options[] = {"n2", "n4", "n8"}; + return convert_enum_idx(options, 3, value, "pusch_cfg_s::pusch_aggregation_factor_e_"); +} +uint8_t pusch_cfg_s::pusch_aggregation_factor_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 8}; + return map_enum_number(options, 3, value, "pusch_cfg_s::pusch_aggregation_factor_e_"); +} + +std::string pusch_cfg_s::mcs_table_opts::to_string() const +{ + static const char* options[] = {"qam256", "qam64LowSE"}; + return convert_enum_idx(options, 2, value, "pusch_cfg_s::mcs_table_e_"); +} +uint16_t pusch_cfg_s::mcs_table_opts::to_number() const +{ + static const uint16_t options[] = {256, 64}; + return map_enum_number(options, 2, value, "pusch_cfg_s::mcs_table_e_"); +} + +std::string pusch_cfg_s::mcs_table_transform_precoder_opts::to_string() const +{ + static const char* options[] = {"qam256", "qam64LowSE"}; + return convert_enum_idx(options, 2, value, "pusch_cfg_s::mcs_table_transform_precoder_e_"); +} +uint16_t pusch_cfg_s::mcs_table_transform_precoder_opts::to_number() const +{ + static const uint16_t options[] = {256, 64}; + return map_enum_number(options, 2, value, "pusch_cfg_s::mcs_table_transform_precoder_e_"); +} + +std::string pusch_cfg_s::transform_precoder_opts::to_string() const +{ + static const char* options[] = {"enabled", "disabled"}; + return convert_enum_idx(options, 2, value, "pusch_cfg_s::transform_precoder_e_"); +} + +std::string pusch_cfg_s::codebook_subset_opts::to_string() const +{ + static const char* options[] = {"fullyAndPartialAndNonCoherent", "partialAndNonCoherent", "nonCoherent"}; + return convert_enum_idx(options, 3, value, "pusch_cfg_s::codebook_subset_e_"); +} + +// SRS-Config ::= SEQUENCE +SRSASN_CODE srs_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(srs_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(srs_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(srs_res_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(srs_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(tpc_accumulation_present, 1)); + + if (srs_res_set_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_set_to_release_list, 1, 16, integer_packer(0, 15))); + } + if (srs_res_set_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_set_to_add_mod_list, 1, 16)); + } + if (srs_res_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_to_release_list, 1, 64, integer_packer(0, 63))); + } + if (srs_res_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, srs_res_to_add_mod_list, 1, 64)); } + return SRSASN_SUCCESS; } -SRSASN_CODE pcch_msg_type_c::c1_c_::unpack(cbit_ref& bref) +SRSASN_CODE srs_cfg_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::paging: - HANDLE_CODE(c.unpack(bref)); - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "pcch_msg_type_c::c1_c_"); - return SRSASN_ERROR_DECODE_FAIL; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(srs_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(srs_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(srs_res_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(srs_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(tpc_accumulation_present, 1)); + + if (srs_res_set_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(srs_res_set_to_release_list, bref, 1, 16, integer_packer(0, 15))); + } + if (srs_res_set_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(srs_res_set_to_add_mod_list, bref, 1, 16)); + } + if (srs_res_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(srs_res_to_release_list, bref, 1, 64, integer_packer(0, 63))); + } + if (srs_res_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(srs_res_to_add_mod_list, bref, 1, 64)); } + return SRSASN_SUCCESS; } - -std::string pcch_msg_type_c::c1_c_::types_opts::to_string() const +void srs_cfg_s::to_json(json_writer& j) const { - static const char* options[] = {"paging", "spare1"}; - return convert_enum_idx(options, 2, value, "pcch_msg_type_c::c1_c_::types"); + j.start_obj(); + if (srs_res_set_to_release_list_present) { + j.start_array("srs-ResourceSetToReleaseList"); + for (const auto& e1 : srs_res_set_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (srs_res_set_to_add_mod_list_present) { + j.start_array("srs-ResourceSetToAddModList"); + for (const auto& e1 : srs_res_set_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (srs_res_to_release_list_present) { + j.start_array("srs-ResourceToReleaseList"); + for (const auto& e1 : srs_res_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (srs_res_to_add_mod_list_present) { + j.start_array("srs-ResourceToAddModList"); + for (const auto& e1 : srs_res_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (tpc_accumulation_present) { + j.write_str("tpc-Accumulation", "disabled"); + } + j.end_obj(); } -std::string pcch_msg_type_c::types_opts::to_string() const +// BWP-UplinkDedicated ::= SEQUENCE +SRSASN_CODE bwp_ul_ded_s::pack(bit_ref& bref) const { - static const char* options[] = {"c1", "messageClassExtension"}; - return convert_enum_idx(options, 2, value, "pcch_msg_type_c::types"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(pucch_cfg_present, 1)); + HANDLE_CODE(bref.pack(pusch_cfg_present, 1)); + HANDLE_CODE(bref.pack(cfgured_grant_cfg_present, 1)); + HANDLE_CODE(bref.pack(srs_cfg_present, 1)); + HANDLE_CODE(bref.pack(beam_fail_recovery_cfg_present, 1)); + + if (pucch_cfg_present) { + HANDLE_CODE(pucch_cfg.pack(bref)); + } + if (pusch_cfg_present) { + HANDLE_CODE(pusch_cfg.pack(bref)); + } + if (cfgured_grant_cfg_present) { + HANDLE_CODE(cfgured_grant_cfg.pack(bref)); + } + if (srs_cfg_present) { + HANDLE_CODE(srs_cfg.pack(bref)); + } + if (beam_fail_recovery_cfg_present) { + HANDLE_CODE(beam_fail_recovery_cfg.pack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t pcch_msg_type_c::types_opts::to_number() const +SRSASN_CODE bwp_ul_ded_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "pcch_msg_type_c::types"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(pucch_cfg_present, 1)); + HANDLE_CODE(bref.unpack(pusch_cfg_present, 1)); + HANDLE_CODE(bref.unpack(cfgured_grant_cfg_present, 1)); + HANDLE_CODE(bref.unpack(srs_cfg_present, 1)); + HANDLE_CODE(bref.unpack(beam_fail_recovery_cfg_present, 1)); + + if (pucch_cfg_present) { + HANDLE_CODE(pucch_cfg.unpack(bref)); + } + if (pusch_cfg_present) { + HANDLE_CODE(pusch_cfg.unpack(bref)); + } + if (cfgured_grant_cfg_present) { + HANDLE_CODE(cfgured_grant_cfg.unpack(bref)); + } + if (srs_cfg_present) { + HANDLE_CODE(srs_cfg.unpack(bref)); + } + if (beam_fail_recovery_cfg_present) { + HANDLE_CODE(beam_fail_recovery_cfg.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void bwp_ul_ded_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (pucch_cfg_present) { + j.write_fieldname("pucch-Config"); + pucch_cfg.to_json(j); + } + if (pusch_cfg_present) { + j.write_fieldname("pusch-Config"); + pusch_cfg.to_json(j); + } + if (cfgured_grant_cfg_present) { + j.write_fieldname("configuredGrantConfig"); + cfgured_grant_cfg.to_json(j); + } + if (srs_cfg_present) { + j.write_fieldname("srs-Config"); + srs_cfg.to_json(j); + } + if (beam_fail_recovery_cfg_present) { + j.write_fieldname("beamFailureRecoveryConfig"); + beam_fail_recovery_cfg.to_json(j); + } + j.end_obj(); } -// PCCH-Message ::= SEQUENCE -SRSASN_CODE pcch_msg_s::pack(bit_ref& bref) const +// BWP-Uplink ::= SEQUENCE +SRSASN_CODE bwp_ul_s::pack(bit_ref& bref) const { - HANDLE_CODE(msg.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(bwp_common_present, 1)); + HANDLE_CODE(bref.pack(bwp_ded_present, 1)); - bref.align_bytes_zero(); + HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); + if (bwp_common_present) { + HANDLE_CODE(bwp_common.pack(bref)); + } + if (bwp_ded_present) { + HANDLE_CODE(bwp_ded.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE pcch_msg_s::unpack(cbit_ref& bref) +SRSASN_CODE bwp_ul_s::unpack(cbit_ref& bref) { - HANDLE_CODE(msg.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(bwp_common_present, 1)); + HANDLE_CODE(bref.unpack(bwp_ded_present, 1)); - bref.align_bytes(); + HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); + if (bwp_common_present) { + HANDLE_CODE(bwp_common.unpack(bref)); + } + if (bwp_ded_present) { + HANDLE_CODE(bwp_ded.unpack(bref)); + } return SRSASN_SUCCESS; } -void pcch_msg_s::to_json(json_writer& j) const +void bwp_ul_s::to_json(json_writer& j) const { - j.start_array(); j.start_obj(); - j.start_obj("PCCH-Message"); - j.write_fieldname("message"); - msg.to_json(j); - j.end_obj(); + j.write_int("bwp-Id", bwp_id); + if (bwp_common_present) { + j.write_fieldname("bwp-Common"); + bwp_common.to_json(j); + } + if (bwp_ded_present) { + j.write_fieldname("bwp-Dedicated"); + bwp_ded.to_json(j); + } j.end_obj(); - j.end_array(); } -// EstablishmentCause ::= ENUMERATED -std::string establishment_cause_opts::to_string() const +// CA-BandwidthClassEUTRA ::= ENUMERATED +std::string ca_bw_class_eutra_opts::to_string() const { - static const char* options[] = {"emergency", - "highPriorityAccess", - "mt-Access", - "mo-Signalling", - "mo-Data", - "mo-VoiceCall", - "mo-VideoCall", - "mo-SMS", - "mps-PriorityAccess", - "mcs-PriorityAccess", - "spare6", - "spare5", - "spare4", - "spare3", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "establishment_cause_e"); + static const char* options[] = {"a", "b", "c", "d", "e", "f"}; + return convert_enum_idx(options, 6, value, "ca_bw_class_eutra_e"); } -// InitialUE-Identity ::= CHOICE -void init_ue_id_c::destroy_() +// CA-BandwidthClassNR ::= ENUMERATED +std::string ca_bw_class_nr_opts::to_string() const +{ + static const char* options[] = {"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q"}; + return convert_enum_idx(options, 17, value, "ca_bw_class_nr_e"); +} + +// BandParameters ::= CHOICE +void band_params_c::destroy_() { switch (type_) { - case types::ng_minus5_g_s_tmsi_part1: - c.destroy >(); + case types::eutra: + c.destroy(); break; - case types::random_value: - c.destroy >(); + case types::nr: + c.destroy(); break; default: break; } } -void init_ue_id_c::set(types::options e) +void band_params_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ng_minus5_g_s_tmsi_part1: - c.init >(); + case types::eutra: + c.init(); break; - case types::random_value: - c.init >(); + case types::nr: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "init_ue_id_c"); + log_invalid_choice_id(type_, "band_params_c"); } } -init_ue_id_c::init_ue_id_c(const init_ue_id_c& other) +band_params_c::band_params_c(const band_params_c& other) { type_ = other.type(); switch (type_) { - case types::ng_minus5_g_s_tmsi_part1: - c.init(other.c.get >()); + case types::eutra: + c.init(other.c.get()); break; - case types::random_value: - c.init(other.c.get >()); + case types::nr: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "init_ue_id_c"); + log_invalid_choice_id(type_, "band_params_c"); } } -init_ue_id_c& init_ue_id_c::operator=(const init_ue_id_c& other) +band_params_c& band_params_c::operator=(const band_params_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ng_minus5_g_s_tmsi_part1: - c.set(other.c.get >()); + case types::eutra: + c.set(other.c.get()); break; - case types::random_value: - c.set(other.c.get >()); + case types::nr: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "init_ue_id_c"); + log_invalid_choice_id(type_, "band_params_c"); } return *this; } -void init_ue_id_c::to_json(json_writer& j) const +void band_params_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ng_minus5_g_s_tmsi_part1: - j.write_str("ng-5G-S-TMSI-Part1", c.get >().to_string()); + case types::eutra: + j.write_fieldname("eutra"); + j.start_obj(); + j.write_int("bandEUTRA", c.get().band_eutra); + if (c.get().ca_bw_class_dl_eutra_present) { + j.write_str("ca-BandwidthClassDL-EUTRA", c.get().ca_bw_class_dl_eutra.to_string()); + } + if (c.get().ca_bw_class_ul_eutra_present) { + j.write_str("ca-BandwidthClassUL-EUTRA", c.get().ca_bw_class_ul_eutra.to_string()); + } + j.end_obj(); break; - case types::random_value: - j.write_str("randomValue", c.get >().to_string()); + case types::nr: + j.write_fieldname("nr"); + j.start_obj(); + j.write_int("bandNR", c.get().band_nr); + if (c.get().ca_bw_class_dl_nr_present) { + j.write_str("ca-BandwidthClassDL-NR", c.get().ca_bw_class_dl_nr.to_string()); + } + if (c.get().ca_bw_class_ul_nr_present) { + j.write_str("ca-BandwidthClassUL-NR", c.get().ca_bw_class_ul_nr.to_string()); + } + j.end_obj(); break; default: - log_invalid_choice_id(type_, "init_ue_id_c"); + log_invalid_choice_id(type_, "band_params_c"); } j.end_obj(); } -SRSASN_CODE init_ue_id_c::pack(bit_ref& bref) const +SRSASN_CODE band_params_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ng_minus5_g_s_tmsi_part1: - HANDLE_CODE(c.get >().pack(bref)); + case types::eutra: + HANDLE_CODE(bref.pack(c.get().ca_bw_class_dl_eutra_present, 1)); + HANDLE_CODE(bref.pack(c.get().ca_bw_class_ul_eutra_present, 1)); + HANDLE_CODE(pack_integer(bref, c.get().band_eutra, (uint16_t)1u, (uint16_t)256u)); + if (c.get().ca_bw_class_dl_eutra_present) { + HANDLE_CODE(c.get().ca_bw_class_dl_eutra.pack(bref)); + } + if (c.get().ca_bw_class_ul_eutra_present) { + HANDLE_CODE(c.get().ca_bw_class_ul_eutra.pack(bref)); + } break; - case types::random_value: - HANDLE_CODE(c.get >().pack(bref)); + case types::nr: + HANDLE_CODE(bref.pack(c.get().ca_bw_class_dl_nr_present, 1)); + HANDLE_CODE(bref.pack(c.get().ca_bw_class_ul_nr_present, 1)); + HANDLE_CODE(pack_integer(bref, c.get().band_nr, (uint16_t)1u, (uint16_t)1024u)); + if (c.get().ca_bw_class_dl_nr_present) { + HANDLE_CODE(c.get().ca_bw_class_dl_nr.pack(bref)); + } + if (c.get().ca_bw_class_ul_nr_present) { + HANDLE_CODE(c.get().ca_bw_class_ul_nr.pack(bref)); + } break; default: - log_invalid_choice_id(type_, "init_ue_id_c"); + log_invalid_choice_id(type_, "band_params_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE init_ue_id_c::unpack(cbit_ref& bref) +SRSASN_CODE band_params_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ng_minus5_g_s_tmsi_part1: - HANDLE_CODE(c.get >().unpack(bref)); + case types::eutra: + HANDLE_CODE(bref.unpack(c.get().ca_bw_class_dl_eutra_present, 1)); + HANDLE_CODE(bref.unpack(c.get().ca_bw_class_ul_eutra_present, 1)); + HANDLE_CODE(unpack_integer(c.get().band_eutra, bref, (uint16_t)1u, (uint16_t)256u)); + if (c.get().ca_bw_class_dl_eutra_present) { + HANDLE_CODE(c.get().ca_bw_class_dl_eutra.unpack(bref)); + } + if (c.get().ca_bw_class_ul_eutra_present) { + HANDLE_CODE(c.get().ca_bw_class_ul_eutra.unpack(bref)); + } break; - case types::random_value: - HANDLE_CODE(c.get >().unpack(bref)); + case types::nr: + HANDLE_CODE(bref.unpack(c.get().ca_bw_class_dl_nr_present, 1)); + HANDLE_CODE(bref.unpack(c.get().ca_bw_class_ul_nr_present, 1)); + HANDLE_CODE(unpack_integer(c.get().band_nr, bref, (uint16_t)1u, (uint16_t)1024u)); + if (c.get().ca_bw_class_dl_nr_present) { + HANDLE_CODE(c.get().ca_bw_class_dl_nr.unpack(bref)); + } + if (c.get().ca_bw_class_ul_nr_present) { + HANDLE_CODE(c.get().ca_bw_class_ul_nr.unpack(bref)); + } break; default: - log_invalid_choice_id(type_, "init_ue_id_c"); + log_invalid_choice_id(type_, "band_params_c"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string init_ue_id_c::types_opts::to_string() const -{ - static const char* options[] = {"ng-5G-S-TMSI-Part1", "randomValue"}; - return convert_enum_idx(options, 2, value, "init_ue_id_c::types"); -} -int8_t init_ue_id_c::types_opts::to_number() const +std::string band_params_c::types_opts::to_string() const { - static const int8_t options[] = {-5}; - return map_enum_number(options, 1, value, "init_ue_id_c::types"); + static const char* options[] = {"eutra", "nr"}; + return convert_enum_idx(options, 2, value, "band_params_c::types"); } -// ReestabUE-Identity ::= SEQUENCE -SRSASN_CODE reestab_ue_id_s::pack(bit_ref& bref) const +// CA-ParametersEUTRA ::= SEQUENCE +SRSASN_CODE ca_params_eutra_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, c_rnti, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(short_mac_i.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(multiple_timing_advance_present, 1)); + HANDLE_CODE(bref.pack(simul_rx_tx_present, 1)); + HANDLE_CODE(bref.pack(supported_naics_minus2_crs_ap_present, 1)); + HANDLE_CODE(bref.pack(add_rx_tx_performance_req_present, 1)); + HANDLE_CODE(bref.pack(ue_ca_pwr_class_n_present, 1)); + HANDLE_CODE(bref.pack(supported_bw_combination_set_eutra_v1530_present, 1)); + + if (supported_naics_minus2_crs_ap_present) { + HANDLE_CODE(supported_naics_minus2_crs_ap.pack(bref)); + } + if (supported_bw_combination_set_eutra_v1530_present) { + HANDLE_CODE(supported_bw_combination_set_eutra_v1530.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE reestab_ue_id_s::unpack(cbit_ref& bref) +SRSASN_CODE ca_params_eutra_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(c_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); - HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(short_mac_i.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(multiple_timing_advance_present, 1)); + HANDLE_CODE(bref.unpack(simul_rx_tx_present, 1)); + HANDLE_CODE(bref.unpack(supported_naics_minus2_crs_ap_present, 1)); + HANDLE_CODE(bref.unpack(add_rx_tx_performance_req_present, 1)); + HANDLE_CODE(bref.unpack(ue_ca_pwr_class_n_present, 1)); + HANDLE_CODE(bref.unpack(supported_bw_combination_set_eutra_v1530_present, 1)); + + if (supported_naics_minus2_crs_ap_present) { + HANDLE_CODE(supported_naics_minus2_crs_ap.unpack(bref)); + } + if (supported_bw_combination_set_eutra_v1530_present) { + HANDLE_CODE(supported_bw_combination_set_eutra_v1530.unpack(bref)); + } return SRSASN_SUCCESS; } -void reestab_ue_id_s::to_json(json_writer& j) const +void ca_params_eutra_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("c-RNTI", c_rnti); - j.write_int("physCellId", pci); - j.write_str("shortMAC-I", short_mac_i.to_string()); - j.end_obj(); -} - -// ReestablishmentCause ::= ENUMERATED -std::string reest_cause_opts::to_string() const -{ - static const char* options[] = {"reconfigurationFailure", "handoverFailure", "otherFailure", "spare1"}; - return convert_enum_idx(options, 4, value, "reest_cause_e"); -} - -// ResumeCause ::= ENUMERATED -std::string resume_cause_opts::to_string() const -{ - static const char* options[] = {"emergency", - "highPriorityAccess", - "mt-Access", - "mo-Signalling", - "mo-Data", - "mo-VoiceCall", - "mo-VideoCall", - "mo-SMS", - "rna-Update", - "mps-PriorityAccess", - "mcs-PriorityAccess", - "spare1", - "spare2", - "spare3", - "spare4", - "spare5"}; - return convert_enum_idx(options, 16, value, "resume_cause_e"); + if (multiple_timing_advance_present) { + j.write_str("multipleTimingAdvance", "supported"); + } + if (simul_rx_tx_present) { + j.write_str("simultaneousRx-Tx", "supported"); + } + if (supported_naics_minus2_crs_ap_present) { + j.write_str("supportedNAICS-2CRS-AP", supported_naics_minus2_crs_ap.to_string()); + } + if (add_rx_tx_performance_req_present) { + j.write_str("additionalRx-Tx-PerformanceReq", "supported"); + } + if (ue_ca_pwr_class_n_present) { + j.write_str("ue-CA-PowerClass-N", "class2"); + } + if (supported_bw_combination_set_eutra_v1530_present) { + j.write_str("supportedBandwidthCombinationSetEUTRA-v1530", supported_bw_combination_set_eutra_v1530.to_string()); + } + j.end_obj(); } -// RRCReestablishmentRequest-IEs ::= SEQUENCE -SRSASN_CODE rrc_reest_request_ies_s::pack(bit_ref& bref) const +// CA-ParametersNR ::= SEQUENCE +SRSASN_CODE ca_params_nr_s::pack(bit_ref& bref) const { - HANDLE_CODE(ue_id.pack(bref)); - HANDLE_CODE(reest_cause.pack(bref)); - HANDLE_CODE(spare.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(dummy_present, 1)); + HANDLE_CODE(bref.pack(parallel_tx_srs_pucch_pusch_present, 1)); + HANDLE_CODE(bref.pack(parallel_tx_prach_srs_pucch_pusch_present, 1)); + HANDLE_CODE(bref.pack(simul_rx_tx_inter_band_ca_present, 1)); + HANDLE_CODE(bref.pack(simul_rx_tx_sul_present, 1)); + HANDLE_CODE(bref.pack(diff_numerology_across_pucch_group_present, 1)); + HANDLE_CODE(bref.pack(diff_numerology_within_pucch_group_smaller_scs_present, 1)); + HANDLE_CODE(bref.pack(supported_num_tag_present, 1)); + + if (supported_num_tag_present) { + HANDLE_CODE(supported_num_tag.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_reest_request_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE ca_params_nr_s::unpack(cbit_ref& bref) { - HANDLE_CODE(ue_id.unpack(bref)); - HANDLE_CODE(reest_cause.unpack(bref)); - HANDLE_CODE(spare.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(dummy_present, 1)); + HANDLE_CODE(bref.unpack(parallel_tx_srs_pucch_pusch_present, 1)); + HANDLE_CODE(bref.unpack(parallel_tx_prach_srs_pucch_pusch_present, 1)); + HANDLE_CODE(bref.unpack(simul_rx_tx_inter_band_ca_present, 1)); + HANDLE_CODE(bref.unpack(simul_rx_tx_sul_present, 1)); + HANDLE_CODE(bref.unpack(diff_numerology_across_pucch_group_present, 1)); + HANDLE_CODE(bref.unpack(diff_numerology_within_pucch_group_smaller_scs_present, 1)); + HANDLE_CODE(bref.unpack(supported_num_tag_present, 1)); + + if (supported_num_tag_present) { + HANDLE_CODE(supported_num_tag.unpack(bref)); + } return SRSASN_SUCCESS; } -void rrc_reest_request_ies_s::to_json(json_writer& j) const +void ca_params_nr_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("ue-Identity"); - ue_id.to_json(j); - j.write_str("reestablishmentCause", reest_cause.to_string()); - j.write_str("spare", spare.to_string()); + if (dummy_present) { + j.write_str("dummy", "supported"); + } + if (parallel_tx_srs_pucch_pusch_present) { + j.write_str("parallelTxSRS-PUCCH-PUSCH", "supported"); + } + if (parallel_tx_prach_srs_pucch_pusch_present) { + j.write_str("parallelTxPRACH-SRS-PUCCH-PUSCH", "supported"); + } + if (simul_rx_tx_inter_band_ca_present) { + j.write_str("simultaneousRxTxInterBandCA", "supported"); + } + if (simul_rx_tx_sul_present) { + j.write_str("simultaneousRxTxSUL", "supported"); + } + if (diff_numerology_across_pucch_group_present) { + j.write_str("diffNumerologyAcrossPUCCH-Group", "supported"); + } + if (diff_numerology_within_pucch_group_smaller_scs_present) { + j.write_str("diffNumerologyWithinPUCCH-GroupSmallerSCS", "supported"); + } + if (supported_num_tag_present) { + j.write_str("supportedNumberTAG", supported_num_tag.to_string()); + } j.end_obj(); } -// RRCResumeRequest-IEs ::= SEQUENCE -SRSASN_CODE rrc_resume_request_ies_s::pack(bit_ref& bref) const +std::string ca_params_nr_s::supported_num_tag_opts::to_string() const { - HANDLE_CODE(resume_id.pack(bref)); - HANDLE_CODE(resume_mac_i.pack(bref)); - HANDLE_CODE(resume_cause.pack(bref)); - HANDLE_CODE(spare.pack(bref)); + static const char* options[] = {"n2", "n3", "n4"}; + return convert_enum_idx(options, 3, value, "ca_params_nr_s::supported_num_tag_e_"); +} +uint8_t ca_params_nr_s::supported_num_tag_opts::to_number() const +{ + static const uint8_t options[] = {2, 3, 4}; + return map_enum_number(options, 3, value, "ca_params_nr_s::supported_num_tag_e_"); +} + +// MRDC-Parameters ::= SEQUENCE +SRSASN_CODE mrdc_params_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(single_ul_tx_present, 1)); + HANDLE_CODE(bref.pack(dynamic_pwr_sharing_endc_present, 1)); + HANDLE_CODE(bref.pack(tdm_pattern_present, 1)); + HANDLE_CODE(bref.pack(ul_sharing_eutra_nr_present, 1)); + HANDLE_CODE(bref.pack(ul_switching_time_eutra_nr_present, 1)); + HANDLE_CODE(bref.pack(simul_rx_tx_inter_band_endc_present, 1)); + HANDLE_CODE(bref.pack(async_intra_band_endc_present, 1)); + if (ul_sharing_eutra_nr_present) { + HANDLE_CODE(ul_sharing_eutra_nr.pack(bref)); + } + if (ul_switching_time_eutra_nr_present) { + HANDLE_CODE(ul_switching_time_eutra_nr.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= dual_pa_architecture_present; + group_flags[0] |= intra_band_endc_support_present; + group_flags[0] |= ul_timing_align_eutra_nr_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(dual_pa_architecture_present, 1)); + HANDLE_CODE(bref.pack(intra_band_endc_support_present, 1)); + HANDLE_CODE(bref.pack(ul_timing_align_eutra_nr_present, 1)); + if (intra_band_endc_support_present) { + HANDLE_CODE(intra_band_endc_support.pack(bref)); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_resume_request_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE mrdc_params_s::unpack(cbit_ref& bref) { - HANDLE_CODE(resume_id.unpack(bref)); - HANDLE_CODE(resume_mac_i.unpack(bref)); - HANDLE_CODE(resume_cause.unpack(bref)); - HANDLE_CODE(spare.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(single_ul_tx_present, 1)); + HANDLE_CODE(bref.unpack(dynamic_pwr_sharing_endc_present, 1)); + HANDLE_CODE(bref.unpack(tdm_pattern_present, 1)); + HANDLE_CODE(bref.unpack(ul_sharing_eutra_nr_present, 1)); + HANDLE_CODE(bref.unpack(ul_switching_time_eutra_nr_present, 1)); + HANDLE_CODE(bref.unpack(simul_rx_tx_inter_band_endc_present, 1)); + HANDLE_CODE(bref.unpack(async_intra_band_endc_present, 1)); + + if (ul_sharing_eutra_nr_present) { + HANDLE_CODE(ul_sharing_eutra_nr.unpack(bref)); + } + if (ul_switching_time_eutra_nr_present) { + HANDLE_CODE(ul_switching_time_eutra_nr.unpack(bref)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(bref.unpack(dual_pa_architecture_present, 1)); + HANDLE_CODE(bref.unpack(intra_band_endc_support_present, 1)); + HANDLE_CODE(bref.unpack(ul_timing_align_eutra_nr_present, 1)); + if (intra_band_endc_support_present) { + HANDLE_CODE(intra_band_endc_support.unpack(bref)); + } + } + } return SRSASN_SUCCESS; } -void rrc_resume_request_ies_s::to_json(json_writer& j) const +void mrdc_params_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("resumeIdentity", resume_id.to_string()); - j.write_str("resumeMAC-I", resume_mac_i.to_string()); - j.write_str("resumeCause", resume_cause.to_string()); - j.write_str("spare", spare.to_string()); + if (single_ul_tx_present) { + j.write_str("singleUL-Transmission", "supported"); + } + if (dynamic_pwr_sharing_endc_present) { + j.write_str("dynamicPowerSharingENDC", "supported"); + } + if (tdm_pattern_present) { + j.write_str("tdm-Pattern", "supported"); + } + if (ul_sharing_eutra_nr_present) { + j.write_str("ul-SharingEUTRA-NR", ul_sharing_eutra_nr.to_string()); + } + if (ul_switching_time_eutra_nr_present) { + j.write_str("ul-SwitchingTimeEUTRA-NR", ul_switching_time_eutra_nr.to_string()); + } + if (simul_rx_tx_inter_band_endc_present) { + j.write_str("simultaneousRxTxInterBandENDC", "supported"); + } + if (async_intra_band_endc_present) { + j.write_str("asyncIntraBandENDC", "supported"); + } + if (ext) { + if (dual_pa_architecture_present) { + j.write_str("dualPA-Architecture", "supported"); + } + if (intra_band_endc_support_present) { + j.write_str("intraBandENDC-Support", intra_band_endc_support.to_string()); + } + if (ul_timing_align_eutra_nr_present) { + j.write_str("ul-TimingAlignmentEUTRA-NR", "required"); + } + } j.end_obj(); } -// RRCSetupRequest-IEs ::= SEQUENCE -SRSASN_CODE rrc_setup_request_ies_s::pack(bit_ref& bref) const +std::string mrdc_params_s::ul_sharing_eutra_nr_opts::to_string() const { - HANDLE_CODE(ue_id.pack(bref)); - HANDLE_CODE(establishment_cause.pack(bref)); - HANDLE_CODE(spare.pack(bref)); + static const char* options[] = {"tdm", "fdm", "both"}; + return convert_enum_idx(options, 3, value, "mrdc_params_s::ul_sharing_eutra_nr_e_"); +} - return SRSASN_SUCCESS; +std::string mrdc_params_s::ul_switching_time_eutra_nr_opts::to_string() const +{ + static const char* options[] = {"type1", "type2"}; + return convert_enum_idx(options, 2, value, "mrdc_params_s::ul_switching_time_eutra_nr_e_"); } -SRSASN_CODE rrc_setup_request_ies_s::unpack(cbit_ref& bref) +uint8_t mrdc_params_s::ul_switching_time_eutra_nr_opts::to_number() const { - HANDLE_CODE(ue_id.unpack(bref)); - HANDLE_CODE(establishment_cause.unpack(bref)); - HANDLE_CODE(spare.unpack(bref)); - - return SRSASN_SUCCESS; + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "mrdc_params_s::ul_switching_time_eutra_nr_e_"); } -void rrc_setup_request_ies_s::to_json(json_writer& j) const + +std::string mrdc_params_s::intra_band_endc_support_opts::to_string() const { - j.start_obj(); - j.write_fieldname("ue-Identity"); - ue_id.to_json(j); - j.write_str("establishmentCause", establishment_cause.to_string()); - j.write_str("spare", spare.to_string()); - j.end_obj(); + static const char* options[] = {"non-contiguous", "both"}; + return convert_enum_idx(options, 2, value, "mrdc_params_s::intra_band_endc_support_e_"); } -// RRCSystemInfoRequest-r15-IEs ::= SEQUENCE -SRSASN_CODE rrc_sys_info_request_r15_ies_s::pack(bit_ref& bref) const +// BandCombination ::= SEQUENCE +SRSASN_CODE band_combination_s::pack(bit_ref& bref) const { - HANDLE_CODE(requested_si_list.pack(bref)); - HANDLE_CODE(spare.pack(bref)); + HANDLE_CODE(bref.pack(ca_params_eutra_present, 1)); + HANDLE_CODE(bref.pack(ca_params_nr_present, 1)); + HANDLE_CODE(bref.pack(mrdc_params_present, 1)); + HANDLE_CODE(bref.pack(supported_bw_combination_set_present, 1)); + HANDLE_CODE(bref.pack(pwr_class_v1530_present, 1)); + + HANDLE_CODE(pack_dyn_seq_of(bref, band_list, 1, 32)); + HANDLE_CODE(pack_integer(bref, feature_set_combination, (uint16_t)0u, (uint16_t)1024u)); + if (ca_params_eutra_present) { + HANDLE_CODE(ca_params_eutra.pack(bref)); + } + if (ca_params_nr_present) { + HANDLE_CODE(ca_params_nr.pack(bref)); + } + if (mrdc_params_present) { + HANDLE_CODE(mrdc_params.pack(bref)); + } + if (supported_bw_combination_set_present) { + HANDLE_CODE(supported_bw_combination_set.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_sys_info_request_r15_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE band_combination_s::unpack(cbit_ref& bref) { - HANDLE_CODE(requested_si_list.unpack(bref)); - HANDLE_CODE(spare.unpack(bref)); + HANDLE_CODE(bref.unpack(ca_params_eutra_present, 1)); + HANDLE_CODE(bref.unpack(ca_params_nr_present, 1)); + HANDLE_CODE(bref.unpack(mrdc_params_present, 1)); + HANDLE_CODE(bref.unpack(supported_bw_combination_set_present, 1)); + HANDLE_CODE(bref.unpack(pwr_class_v1530_present, 1)); + + HANDLE_CODE(unpack_dyn_seq_of(band_list, bref, 1, 32)); + HANDLE_CODE(unpack_integer(feature_set_combination, bref, (uint16_t)0u, (uint16_t)1024u)); + if (ca_params_eutra_present) { + HANDLE_CODE(ca_params_eutra.unpack(bref)); + } + if (ca_params_nr_present) { + HANDLE_CODE(ca_params_nr.unpack(bref)); + } + if (mrdc_params_present) { + HANDLE_CODE(mrdc_params.unpack(bref)); + } + if (supported_bw_combination_set_present) { + HANDLE_CODE(supported_bw_combination_set.unpack(bref)); + } return SRSASN_SUCCESS; } -void rrc_sys_info_request_r15_ies_s::to_json(json_writer& j) const +void band_combination_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("requested-SI-List", requested_si_list.to_string()); - j.write_str("spare", spare.to_string()); + j.start_array("bandList"); + for (const auto& e1 : band_list) { + e1.to_json(j); + } + j.end_array(); + j.write_int("featureSetCombination", feature_set_combination); + if (ca_params_eutra_present) { + j.write_fieldname("ca-ParametersEUTRA"); + ca_params_eutra.to_json(j); + } + if (ca_params_nr_present) { + j.write_fieldname("ca-ParametersNR"); + ca_params_nr.to_json(j); + } + if (mrdc_params_present) { + j.write_fieldname("mrdc-Parameters"); + mrdc_params.to_json(j); + } + if (supported_bw_combination_set_present) { + j.write_str("supportedBandwidthCombinationSet", supported_bw_combination_set.to_string()); + } + if (pwr_class_v1530_present) { + j.write_str("powerClass-v1530", "pc2"); + } j.end_obj(); } -// RRCReestablishmentRequest ::= SEQUENCE -SRSASN_CODE rrc_reest_request_s::pack(bit_ref& bref) const +// SRS-SwitchingTimeEUTRA ::= SEQUENCE +SRSASN_CODE srs_switching_time_eutra_s::pack(bit_ref& bref) const { - HANDLE_CODE(rrc_reest_request.pack(bref)); + HANDLE_CODE(bref.pack(switching_time_dl_present, 1)); + HANDLE_CODE(bref.pack(switching_time_ul_present, 1)); + + if (switching_time_dl_present) { + HANDLE_CODE(switching_time_dl.pack(bref)); + } + if (switching_time_ul_present) { + HANDLE_CODE(switching_time_ul.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_reest_request_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_switching_time_eutra_s::unpack(cbit_ref& bref) { - HANDLE_CODE(rrc_reest_request.unpack(bref)); + HANDLE_CODE(bref.unpack(switching_time_dl_present, 1)); + HANDLE_CODE(bref.unpack(switching_time_ul_present, 1)); + + if (switching_time_dl_present) { + HANDLE_CODE(switching_time_dl.unpack(bref)); + } + if (switching_time_ul_present) { + HANDLE_CODE(switching_time_ul.unpack(bref)); + } return SRSASN_SUCCESS; } -void rrc_reest_request_s::to_json(json_writer& j) const +void srs_switching_time_eutra_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("rrcReestablishmentRequest"); - rrc_reest_request.to_json(j); + if (switching_time_dl_present) { + j.write_str("switchingTimeDL", switching_time_dl.to_string()); + } + if (switching_time_ul_present) { + j.write_str("switchingTimeUL", switching_time_ul.to_string()); + } j.end_obj(); } -// RRCResumeRequest ::= SEQUENCE -SRSASN_CODE rrc_resume_request_s::pack(bit_ref& bref) const +std::string srs_switching_time_eutra_s::switching_time_dl_opts::to_string() const { - HANDLE_CODE(rrc_resume_request.pack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"n0", + "n0dot5", + "n1", + "n1dot5", + "n2", + "n2dot5", + "n3", + "n3dot5", + "n4", + "n4dot5", + "n5", + "n5dot5", + "n6", + "n6dot5", + "n7"}; + return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_dl_e_"); } -SRSASN_CODE rrc_resume_request_s::unpack(cbit_ref& bref) +float srs_switching_time_eutra_s::switching_time_dl_opts::to_number() const { - HANDLE_CODE(rrc_resume_request.unpack(bref)); - - return SRSASN_SUCCESS; + static const float options[] = {0.0, 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5, 5.0, 5.5, 6.0, 6.5, 7.0}; + return map_enum_number(options, 15, value, "srs_switching_time_eutra_s::switching_time_dl_e_"); } -void rrc_resume_request_s::to_json(json_writer& j) const +std::string srs_switching_time_eutra_s::switching_time_dl_opts::to_number_string() const { - j.start_obj(); - j.write_fieldname("rrcResumeRequest"); - rrc_resume_request.to_json(j); - j.end_obj(); + static const char* options[] = { + "0", "0.5", "1", "1.5", "2", "2.5", "3", "3.5", "4", "4.5", "5", "5.5", "6", "6.5", "7"}; + return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_dl_e_"); } -// RRCSetupRequest ::= SEQUENCE -SRSASN_CODE rrc_setup_request_s::pack(bit_ref& bref) const +std::string srs_switching_time_eutra_s::switching_time_ul_opts::to_string() const { - HANDLE_CODE(rrc_setup_request.pack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"n0", + "n0dot5", + "n1", + "n1dot5", + "n2", + "n2dot5", + "n3", + "n3dot5", + "n4", + "n4dot5", + "n5", + "n5dot5", + "n6", + "n6dot5", + "n7"}; + return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_ul_e_"); } -SRSASN_CODE rrc_setup_request_s::unpack(cbit_ref& bref) +float srs_switching_time_eutra_s::switching_time_ul_opts::to_number() const { - HANDLE_CODE(rrc_setup_request.unpack(bref)); - - return SRSASN_SUCCESS; + static const float options[] = {0.0, 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5, 5.0, 5.5, 6.0, 6.5, 7.0}; + return map_enum_number(options, 15, value, "srs_switching_time_eutra_s::switching_time_ul_e_"); } -void rrc_setup_request_s::to_json(json_writer& j) const +std::string srs_switching_time_eutra_s::switching_time_ul_opts::to_number_string() const { - j.start_obj(); - j.write_fieldname("rrcSetupRequest"); - rrc_setup_request.to_json(j); - j.end_obj(); + static const char* options[] = { + "0", "0.5", "1", "1.5", "2", "2.5", "3", "3.5", "4", "4.5", "5", "5.5", "6", "6.5", "7"}; + return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_ul_e_"); } -// RRCSystemInfoRequest ::= SEQUENCE -SRSASN_CODE rrc_sys_info_request_s::pack(bit_ref& bref) const +// SRS-SwitchingTimeNR ::= SEQUENCE +SRSASN_CODE srs_switching_time_nr_s::pack(bit_ref& bref) const { - HANDLE_CODE(crit_exts.pack(bref)); + HANDLE_CODE(bref.pack(switching_time_dl_present, 1)); + HANDLE_CODE(bref.pack(switching_time_ul_present, 1)); + + if (switching_time_dl_present) { + HANDLE_CODE(switching_time_dl.pack(bref)); + } + if (switching_time_ul_present) { + HANDLE_CODE(switching_time_ul.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_sys_info_request_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_switching_time_nr_s::unpack(cbit_ref& bref) { - HANDLE_CODE(crit_exts.unpack(bref)); + HANDLE_CODE(bref.unpack(switching_time_dl_present, 1)); + HANDLE_CODE(bref.unpack(switching_time_ul_present, 1)); + + if (switching_time_dl_present) { + HANDLE_CODE(switching_time_dl.unpack(bref)); + } + if (switching_time_ul_present) { + HANDLE_CODE(switching_time_ul.unpack(bref)); + } return SRSASN_SUCCESS; } -void rrc_sys_info_request_s::to_json(json_writer& j) const +void srs_switching_time_nr_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + if (switching_time_dl_present) { + j.write_str("switchingTimeDL", switching_time_dl.to_string()); + } + if (switching_time_ul_present) { + j.write_str("switchingTimeUL", switching_time_ul.to_string()); + } j.end_obj(); } -void rrc_sys_info_request_s::crit_exts_c_::destroy_() +std::string srs_switching_time_nr_s::switching_time_dl_opts::to_string() const { - switch (type_) { - case types::rrc_sys_info_request_r15: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"n0us", "n30us", "n100us", "n140us", "n200us", "n300us", "n500us", "n900us"}; + return convert_enum_idx(options, 8, value, "srs_switching_time_nr_s::switching_time_dl_e_"); } -void rrc_sys_info_request_s::crit_exts_c_::set(types::options e) +uint16_t srs_switching_time_nr_s::switching_time_dl_opts::to_number() const { - destroy_(); - type_ = e; - switch (type_) { - case types::rrc_sys_info_request_r15: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); - } + static const uint16_t options[] = {0, 30, 100, 140, 200, 300, 500, 900}; + return map_enum_number(options, 8, value, "srs_switching_time_nr_s::switching_time_dl_e_"); } -rrc_sys_info_request_s::crit_exts_c_::crit_exts_c_(const rrc_sys_info_request_s::crit_exts_c_& other) + +std::string srs_switching_time_nr_s::switching_time_ul_opts::to_string() const { - type_ = other.type(); - switch (type_) { - case types::rrc_sys_info_request_r15: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); - } + static const char* options[] = {"n0us", "n30us", "n100us", "n140us", "n200us", "n300us", "n500us", "n900us"}; + return convert_enum_idx(options, 8, value, "srs_switching_time_nr_s::switching_time_ul_e_"); } -rrc_sys_info_request_s::crit_exts_c_& rrc_sys_info_request_s::crit_exts_c_:: - operator=(const rrc_sys_info_request_s::crit_exts_c_& other) +uint16_t srs_switching_time_nr_s::switching_time_ul_opts::to_number() const { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::rrc_sys_info_request_r15: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); - } - - return *this; + static const uint16_t options[] = {0, 30, 100, 140, 200, 300, 500, 900}; + return map_enum_number(options, 8, value, "srs_switching_time_nr_s::switching_time_ul_e_"); } -void rrc_sys_info_request_s::crit_exts_c_::to_json(json_writer& j) const + +// BandParameters-v1540 ::= SEQUENCE +SRSASN_CODE band_params_v1540_s::pack(bit_ref& bref) const { - j.start_obj(); - switch (type_) { - case types::rrc_sys_info_request_r15: - j.write_fieldname("rrcSystemInfoRequest-r15"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); + HANDLE_CODE(bref.pack(srs_carrier_switch_present, 1)); + HANDLE_CODE(bref.pack(srs_tx_switch_present, 1)); + + if (srs_carrier_switch_present) { + HANDLE_CODE(srs_carrier_switch.pack(bref)); } - j.end_obj(); -} -SRSASN_CODE rrc_sys_info_request_s::crit_exts_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::rrc_sys_info_request_r15: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + if (srs_tx_switch_present) { + HANDLE_CODE(bref.pack(srs_tx_switch.tx_switch_impact_to_rx_present, 1)); + HANDLE_CODE(bref.pack(srs_tx_switch.tx_switch_with_another_band_present, 1)); + HANDLE_CODE(srs_tx_switch.supported_srs_tx_port_switch.pack(bref)); + if (srs_tx_switch.tx_switch_impact_to_rx_present) { + HANDLE_CODE(pack_integer(bref, srs_tx_switch.tx_switch_impact_to_rx, (uint8_t)1u, (uint8_t)32u)); + } + if (srs_tx_switch.tx_switch_with_another_band_present) { + HANDLE_CODE(pack_integer(bref, srs_tx_switch.tx_switch_with_another_band, (uint8_t)1u, (uint8_t)32u)); + } } + return SRSASN_SUCCESS; } -SRSASN_CODE rrc_sys_info_request_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE band_params_v1540_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::rrc_sys_info_request_r15: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_sys_info_request_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; + HANDLE_CODE(bref.unpack(srs_carrier_switch_present, 1)); + HANDLE_CODE(bref.unpack(srs_tx_switch_present, 1)); + + if (srs_carrier_switch_present) { + HANDLE_CODE(srs_carrier_switch.unpack(bref)); } + if (srs_tx_switch_present) { + HANDLE_CODE(bref.unpack(srs_tx_switch.tx_switch_impact_to_rx_present, 1)); + HANDLE_CODE(bref.unpack(srs_tx_switch.tx_switch_with_another_band_present, 1)); + HANDLE_CODE(srs_tx_switch.supported_srs_tx_port_switch.unpack(bref)); + if (srs_tx_switch.tx_switch_impact_to_rx_present) { + HANDLE_CODE(unpack_integer(srs_tx_switch.tx_switch_impact_to_rx, bref, (uint8_t)1u, (uint8_t)32u)); + } + if (srs_tx_switch.tx_switch_with_another_band_present) { + HANDLE_CODE(unpack_integer(srs_tx_switch.tx_switch_with_another_band, bref, (uint8_t)1u, (uint8_t)32u)); + } + } + return SRSASN_SUCCESS; } - -std::string rrc_sys_info_request_s::crit_exts_c_::types_opts::to_string() const +void band_params_v1540_s::to_json(json_writer& j) const { - static const char* options[] = {"rrcSystemInfoRequest-r15", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_sys_info_request_s::crit_exts_c_::types"); + j.start_obj(); + if (srs_carrier_switch_present) { + j.write_fieldname("srs-CarrierSwitch"); + srs_carrier_switch.to_json(j); + } + if (srs_tx_switch_present) { + j.write_fieldname("srs-TxSwitch"); + j.start_obj(); + j.write_str("supportedSRS-TxPortSwitch", srs_tx_switch.supported_srs_tx_port_switch.to_string()); + if (srs_tx_switch.tx_switch_impact_to_rx_present) { + j.write_int("txSwitchImpactToRx", srs_tx_switch.tx_switch_impact_to_rx); + } + if (srs_tx_switch.tx_switch_with_another_band_present) { + j.write_int("txSwitchWithAnotherBand", srs_tx_switch.tx_switch_with_another_band); + } + j.end_obj(); + } + j.end_obj(); } -// UL-CCCH-MessageType ::= CHOICE -void ul_ccch_msg_type_c::destroy_() +void band_params_v1540_s::srs_carrier_switch_c_::destroy_() { switch (type_) { - case types::c1: - c.destroy(); + case types::nr: + c.destroy(); + break; + case types::eutra: + c.destroy(); break; default: break; } } -void ul_ccch_msg_type_c::set(types::options e) +void band_params_v1540_s::srs_carrier_switch_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::c1: - c.init(); + case types::nr: + c.init(); break; - case types::msg_class_ext: + case types::eutra: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); + log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); } } -ul_ccch_msg_type_c::ul_ccch_msg_type_c(const ul_ccch_msg_type_c& other) +band_params_v1540_s::srs_carrier_switch_c_::srs_carrier_switch_c_( + const band_params_v1540_s::srs_carrier_switch_c_& other) { type_ = other.type(); switch (type_) { - case types::c1: - c.init(other.c.get()); + case types::nr: + c.init(other.c.get()); break; - case types::msg_class_ext: + case types::eutra: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); + log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); } } -ul_ccch_msg_type_c& ul_ccch_msg_type_c::operator=(const ul_ccch_msg_type_c& other) +band_params_v1540_s::srs_carrier_switch_c_& +band_params_v1540_s::srs_carrier_switch_c_::operator=(const band_params_v1540_s::srs_carrier_switch_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::c1: - c.set(other.c.get()); + case types::nr: + c.set(other.c.get()); break; - case types::msg_class_ext: + case types::eutra: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); + log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); } return *this; } -void ul_ccch_msg_type_c::to_json(json_writer& j) const +void band_params_v1540_s::srs_carrier_switch_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::c1: - j.write_fieldname("c1"); - c.get().to_json(j); + case types::nr: + j.write_fieldname("nr"); + j.start_obj(); + j.start_array("srs-SwitchingTimesListNR"); + for (const auto& e1 : c.get().srs_switching_times_list_nr) { + e1.to_json(j); + } + j.end_array(); + j.end_obj(); break; - case types::msg_class_ext: + case types::eutra: + j.write_fieldname("eutra"); + j.start_obj(); + j.start_array("srs-SwitchingTimesListEUTRA"); + for (const auto& e1 : c.get().srs_switching_times_list_eutra) { + e1.to_json(j); + } + j.end_array(); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); + log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); } j.end_obj(); } -SRSASN_CODE ul_ccch_msg_type_c::pack(bit_ref& bref) const +SRSASN_CODE band_params_v1540_s::srs_carrier_switch_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::c1: - HANDLE_CODE(c.get().pack(bref)); + case types::nr: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get().srs_switching_times_list_nr, 1, 32)); break; - case types::msg_class_ext: + case types::eutra: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get().srs_switching_times_list_eutra, 1, 32)); break; default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); + log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE ul_ccch_msg_type_c::unpack(cbit_ref& bref) +SRSASN_CODE band_params_v1540_s::srs_carrier_switch_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::c1: - HANDLE_CODE(c.get().unpack(bref)); + case types::nr: + HANDLE_CODE(unpack_dyn_seq_of(c.get().srs_switching_times_list_nr, bref, 1, 32)); break; - case types::msg_class_ext: + case types::eutra: + HANDLE_CODE(unpack_dyn_seq_of(c.get().srs_switching_times_list_eutra, bref, 1, 32)); break; default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c"); + log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void ul_ccch_msg_type_c::c1_c_::destroy_() +std::string band_params_v1540_s::srs_carrier_switch_c_::types_opts::to_string() const { - switch (type_) { - case types::rrc_setup_request: - c.destroy(); - break; - case types::rrc_resume_request: - c.destroy(); - break; - case types::rrc_reest_request: - c.destroy(); - break; - case types::rrc_sys_info_request: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"nr", "eutra"}; + return convert_enum_idx(options, 2, value, "band_params_v1540_s::srs_carrier_switch_c_::types"); } -void ul_ccch_msg_type_c::c1_c_::set(types::options e) + +std::string band_params_v1540_s::srs_tx_switch_s_::supported_srs_tx_port_switch_opts::to_string() const { - destroy_(); - type_ = e; - switch (type_) { - case types::rrc_setup_request: - c.init(); - break; - case types::rrc_resume_request: - c.init(); - break; - case types::rrc_reest_request: - c.init(); - break; - case types::rrc_sys_info_request: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); - } + static const char* options[] = {"t1r2", "t1r4", "t2r4", "t1r4-t2r4", "t1r1", "t2r2", "t4r4", "notSupported"}; + return convert_enum_idx(options, 8, value, "band_params_v1540_s::srs_tx_switch_s_::supported_srs_tx_port_switch_e_"); } -ul_ccch_msg_type_c::c1_c_::c1_c_(const ul_ccch_msg_type_c::c1_c_& other) + +// CA-ParametersNR-v1540 ::= SEQUENCE +SRSASN_CODE ca_params_nr_v1540_s::pack(bit_ref& bref) const { - type_ = other.type(); - switch (type_) { - case types::rrc_setup_request: - c.init(other.c.get()); - break; - case types::rrc_resume_request: - c.init(other.c.get()); - break; - case types::rrc_reest_request: - c.init(other.c.get()); - break; - case types::rrc_sys_info_request: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); + HANDLE_CODE(bref.pack(simul_srs_assoc_csi_rs_all_cc_present, 1)); + HANDLE_CODE(bref.pack(csi_rs_im_reception_for_feedback_per_band_comb_present, 1)); + HANDLE_CODE(bref.pack(simul_csi_reports_all_cc_present, 1)); + HANDLE_CODE(bref.pack(dual_pa_architecture_present, 1)); + + if (simul_srs_assoc_csi_rs_all_cc_present) { + HANDLE_CODE(pack_integer(bref, simul_srs_assoc_csi_rs_all_cc, (uint8_t)5u, (uint8_t)32u)); + } + if (csi_rs_im_reception_for_feedback_per_band_comb_present) { + HANDLE_CODE( + bref.pack(csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); + HANDLE_CODE(bref.pack( + csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); + if (csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present) { + HANDLE_CODE(pack_integer(bref, + csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc, + (uint8_t)1u, + (uint8_t)64u)); + } + if (csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present) { + HANDLE_CODE( + pack_integer(bref, + csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc, + (uint16_t)2u, + (uint16_t)256u)); + } + } + if (simul_csi_reports_all_cc_present) { + HANDLE_CODE(pack_integer(bref, simul_csi_reports_all_cc, (uint8_t)5u, (uint8_t)32u)); } + + return SRSASN_SUCCESS; } -ul_ccch_msg_type_c::c1_c_& ul_ccch_msg_type_c::c1_c_::operator=(const ul_ccch_msg_type_c::c1_c_& other) +SRSASN_CODE ca_params_nr_v1540_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + HANDLE_CODE(bref.unpack(simul_srs_assoc_csi_rs_all_cc_present, 1)); + HANDLE_CODE(bref.unpack(csi_rs_im_reception_for_feedback_per_band_comb_present, 1)); + HANDLE_CODE(bref.unpack(simul_csi_reports_all_cc_present, 1)); + HANDLE_CODE(bref.unpack(dual_pa_architecture_present, 1)); + + if (simul_srs_assoc_csi_rs_all_cc_present) { + HANDLE_CODE(unpack_integer(simul_srs_assoc_csi_rs_all_cc, bref, (uint8_t)5u, (uint8_t)32u)); } - set(other.type()); - switch (type_) { - case types::rrc_setup_request: - c.set(other.c.get()); - break; - case types::rrc_resume_request: - c.set(other.c.get()); - break; - case types::rrc_reest_request: - c.set(other.c.get()); - break; - case types::rrc_sys_info_request: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); + if (csi_rs_im_reception_for_feedback_per_band_comb_present) { + HANDLE_CODE( + bref.unpack(csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); + HANDLE_CODE(bref.unpack( + csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); + if (csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present) { + HANDLE_CODE(unpack_integer(csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc, + bref, + (uint8_t)1u, + (uint8_t)64u)); + } + if (csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present) { + HANDLE_CODE( + unpack_integer(csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc, + bref, + (uint16_t)2u, + (uint16_t)256u)); + } + } + if (simul_csi_reports_all_cc_present) { + HANDLE_CODE(unpack_integer(simul_csi_reports_all_cc, bref, (uint8_t)5u, (uint8_t)32u)); } - return *this; + return SRSASN_SUCCESS; } -void ul_ccch_msg_type_c::c1_c_::to_json(json_writer& j) const +void ca_params_nr_v1540_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::rrc_setup_request: - j.write_fieldname("rrcSetupRequest"); - c.get().to_json(j); - break; - case types::rrc_resume_request: - j.write_fieldname("rrcResumeRequest"); - c.get().to_json(j); - break; - case types::rrc_reest_request: - j.write_fieldname("rrcReestablishmentRequest"); - c.get().to_json(j); - break; - case types::rrc_sys_info_request: - j.write_fieldname("rrcSystemInfoRequest"); - c.get().to_json(j); - break; - default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); + if (simul_srs_assoc_csi_rs_all_cc_present) { + j.write_int("simultaneousSRS-AssocCSI-RS-AllCC", simul_srs_assoc_csi_rs_all_cc); + } + if (csi_rs_im_reception_for_feedback_per_band_comb_present) { + j.write_fieldname("csi-RS-IM-ReceptionForFeedbackPerBandComb"); + j.start_obj(); + if (csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present) { + j.write_int("maxNumberSimultaneousNZP-CSI-RS-ActBWP-AllCC", + csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc); + } + if (csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present) { + j.write_int("totalNumberPortsSimultaneousNZP-CSI-RS-ActBWP-AllCC", + csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc); + } + j.end_obj(); + } + if (simul_csi_reports_all_cc_present) { + j.write_int("simultaneousCSI-ReportsAllCC", simul_csi_reports_all_cc); + } + if (dual_pa_architecture_present) { + j.write_str("dualPA-Architecture", "supported"); } j.end_obj(); } -SRSASN_CODE ul_ccch_msg_type_c::c1_c_::pack(bit_ref& bref) const + +// BandCombination-v1540 ::= SEQUENCE +SRSASN_CODE band_combination_v1540_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::rrc_setup_request: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_resume_request: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_reest_request: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_sys_info_request: - HANDLE_CODE(c.get().pack(bref)); - break; - default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + HANDLE_CODE(bref.pack(ca_params_nr_v1540_present, 1)); + + HANDLE_CODE(pack_dyn_seq_of(bref, band_list_v1540, 1, 32)); + if (ca_params_nr_v1540_present) { + HANDLE_CODE(ca_params_nr_v1540.pack(bref)); } + return SRSASN_SUCCESS; } -SRSASN_CODE ul_ccch_msg_type_c::c1_c_::unpack(cbit_ref& bref) +SRSASN_CODE band_combination_v1540_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::rrc_setup_request: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_resume_request: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_reest_request: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_sys_info_request: - HANDLE_CODE(c.get().unpack(bref)); - break; - default: - log_invalid_choice_id(type_, "ul_ccch_msg_type_c::c1_c_"); - return SRSASN_ERROR_DECODE_FAIL; + HANDLE_CODE(bref.unpack(ca_params_nr_v1540_present, 1)); + + HANDLE_CODE(unpack_dyn_seq_of(band_list_v1540, bref, 1, 32)); + if (ca_params_nr_v1540_present) { + HANDLE_CODE(ca_params_nr_v1540.unpack(bref)); } + return SRSASN_SUCCESS; } - -std::string ul_ccch_msg_type_c::c1_c_::types_opts::to_string() const +void band_combination_v1540_s::to_json(json_writer& j) const { - static const char* options[] = { - "rrcSetupRequest", "rrcResumeRequest", "rrcReestablishmentRequest", "rrcSystemInfoRequest"}; - return convert_enum_idx(options, 4, value, "ul_ccch_msg_type_c::c1_c_::types"); + j.start_obj(); + j.start_array("bandList-v1540"); + for (const auto& e1 : band_list_v1540) { + e1.to_json(j); + } + j.end_array(); + if (ca_params_nr_v1540_present) { + j.write_fieldname("ca-ParametersNR-v1540"); + ca_params_nr_v1540.to_json(j); + } + j.end_obj(); } -std::string ul_ccch_msg_type_c::types_opts::to_string() const +// CA-ParametersNR-v1550 ::= SEQUENCE +SRSASN_CODE ca_params_nr_v1550_s::pack(bit_ref& bref) const { - static const char* options[] = {"c1", "messageClassExtension"}; - return convert_enum_idx(options, 2, value, "ul_ccch_msg_type_c::types"); + HANDLE_CODE(bref.pack(dummy_present, 1)); + + return SRSASN_SUCCESS; } -uint8_t ul_ccch_msg_type_c::types_opts::to_number() const +SRSASN_CODE ca_params_nr_v1550_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "ul_ccch_msg_type_c::types"); -} + HANDLE_CODE(bref.unpack(dummy_present, 1)); -// UL-CCCH-Message ::= SEQUENCE -SRSASN_CODE ul_ccch_msg_s::pack(bit_ref& bref) const + return SRSASN_SUCCESS; +} +void ca_params_nr_v1550_s::to_json(json_writer& j) const { - HANDLE_CODE(msg.pack(bref)); + j.start_obj(); + if (dummy_present) { + j.write_str("dummy", "supported"); + } + j.end_obj(); +} - bref.align_bytes_zero(); +// BandCombination-v1550 ::= SEQUENCE +SRSASN_CODE band_combination_v1550_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(ca_params_nr_v1550.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ul_ccch_msg_s::unpack(cbit_ref& bref) +SRSASN_CODE band_combination_v1550_s::unpack(cbit_ref& bref) { - HANDLE_CODE(msg.unpack(bref)); - - bref.align_bytes(); + HANDLE_CODE(ca_params_nr_v1550.unpack(bref)); return SRSASN_SUCCESS; } -void ul_ccch_msg_s::to_json(json_writer& j) const +void band_combination_v1550_s::to_json(json_writer& j) const { - j.start_array(); j.start_obj(); - j.start_obj("UL-CCCH-Message"); - j.write_fieldname("message"); - msg.to_json(j); - j.end_obj(); + j.write_fieldname("ca-ParametersNR-v1550"); + ca_params_nr_v1550.to_json(j); j.end_obj(); - j.end_array(); } -// RRCResumeRequest1-IEs ::= SEQUENCE -SRSASN_CODE rrc_resume_request1_ies_s::pack(bit_ref& bref) const +// CA-ParametersNR-v1560 ::= SEQUENCE +SRSASN_CODE ca_params_nr_v1560_s::pack(bit_ref& bref) const { - HANDLE_CODE(resume_id.pack(bref)); - HANDLE_CODE(resume_mac_i.pack(bref)); - HANDLE_CODE(resume_cause.pack(bref)); - HANDLE_CODE(spare.pack(bref)); + HANDLE_CODE(bref.pack(diff_numerology_within_pucch_group_larger_scs_present, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE rrc_resume_request1_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE ca_params_nr_v1560_s::unpack(cbit_ref& bref) { - HANDLE_CODE(resume_id.unpack(bref)); - HANDLE_CODE(resume_mac_i.unpack(bref)); - HANDLE_CODE(resume_cause.unpack(bref)); - HANDLE_CODE(spare.unpack(bref)); + HANDLE_CODE(bref.unpack(diff_numerology_within_pucch_group_larger_scs_present, 1)); return SRSASN_SUCCESS; } -void rrc_resume_request1_ies_s::to_json(json_writer& j) const +void ca_params_nr_v1560_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("resumeIdentity", resume_id.to_string()); - j.write_str("resumeMAC-I", resume_mac_i.to_string()); - j.write_str("resumeCause", resume_cause.to_string()); - j.write_str("spare", spare.to_string()); + if (diff_numerology_within_pucch_group_larger_scs_present) { + j.write_str("diffNumerologyWithinPUCCH-GroupLargerSCS", "supported"); + } j.end_obj(); } -// RRCResumeRequest1 ::= SEQUENCE -SRSASN_CODE rrc_resume_request1_s::pack(bit_ref& bref) const +// CA-ParametersEUTRA-v1560 ::= SEQUENCE +SRSASN_CODE ca_params_eutra_v1560_s::pack(bit_ref& bref) const { - HANDLE_CODE(rrc_resume_request1.pack(bref)); + HANDLE_CODE(bref.pack(fd_mimo_total_weighted_layers_present, 1)); + + if (fd_mimo_total_weighted_layers_present) { + HANDLE_CODE(pack_integer(bref, fd_mimo_total_weighted_layers, (uint8_t)2u, (uint8_t)128u)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_resume_request1_s::unpack(cbit_ref& bref) +SRSASN_CODE ca_params_eutra_v1560_s::unpack(cbit_ref& bref) { - HANDLE_CODE(rrc_resume_request1.unpack(bref)); + HANDLE_CODE(bref.unpack(fd_mimo_total_weighted_layers_present, 1)); + + if (fd_mimo_total_weighted_layers_present) { + HANDLE_CODE(unpack_integer(fd_mimo_total_weighted_layers, bref, (uint8_t)2u, (uint8_t)128u)); + } return SRSASN_SUCCESS; } -void rrc_resume_request1_s::to_json(json_writer& j) const +void ca_params_eutra_v1560_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("rrcResumeRequest1"); - rrc_resume_request1.to_json(j); + if (fd_mimo_total_weighted_layers_present) { + j.write_int("fd-MIMO-TotalWeightedLayers", fd_mimo_total_weighted_layers); + } j.end_obj(); } -// UL-CCCH1-MessageType ::= CHOICE -void ul_ccch1_msg_type_c::destroy_() +// CA-ParametersNRDC ::= SEQUENCE +SRSASN_CODE ca_params_nrdc_s::pack(bit_ref& bref) const { - switch (type_) { - case types::c1: - c.destroy(); - break; - default: - break; + HANDLE_CODE(bref.pack(ca_params_nr_for_dc_present, 1)); + HANDLE_CODE(bref.pack(ca_params_nr_for_dc_v1540_present, 1)); + HANDLE_CODE(bref.pack(ca_params_nr_for_dc_v1550_present, 1)); + HANDLE_CODE(bref.pack(ca_params_nr_for_dc_v1560_present, 1)); + HANDLE_CODE(bref.pack(feature_set_combination_dc_present, 1)); + + if (ca_params_nr_for_dc_present) { + HANDLE_CODE(ca_params_nr_for_dc.pack(bref)); } -} -void ul_ccch1_msg_type_c::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::c1: - c.init(); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); + if (ca_params_nr_for_dc_v1540_present) { + HANDLE_CODE(ca_params_nr_for_dc_v1540.pack(bref)); } -} -ul_ccch1_msg_type_c::ul_ccch1_msg_type_c(const ul_ccch1_msg_type_c& other) -{ - type_ = other.type(); - switch (type_) { - case types::c1: - c.init(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); + if (ca_params_nr_for_dc_v1550_present) { + HANDLE_CODE(ca_params_nr_for_dc_v1550.pack(bref)); + } + if (ca_params_nr_for_dc_v1560_present) { + HANDLE_CODE(ca_params_nr_for_dc_v1560.pack(bref)); + } + if (feature_set_combination_dc_present) { + HANDLE_CODE(pack_integer(bref, feature_set_combination_dc, (uint16_t)0u, (uint16_t)1024u)); } + + return SRSASN_SUCCESS; } -ul_ccch1_msg_type_c& ul_ccch1_msg_type_c::operator=(const ul_ccch1_msg_type_c& other) +SRSASN_CODE ca_params_nrdc_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + HANDLE_CODE(bref.unpack(ca_params_nr_for_dc_present, 1)); + HANDLE_CODE(bref.unpack(ca_params_nr_for_dc_v1540_present, 1)); + HANDLE_CODE(bref.unpack(ca_params_nr_for_dc_v1550_present, 1)); + HANDLE_CODE(bref.unpack(ca_params_nr_for_dc_v1560_present, 1)); + HANDLE_CODE(bref.unpack(feature_set_combination_dc_present, 1)); + + if (ca_params_nr_for_dc_present) { + HANDLE_CODE(ca_params_nr_for_dc.unpack(bref)); } - set(other.type()); - switch (type_) { - case types::c1: - c.set(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); + if (ca_params_nr_for_dc_v1540_present) { + HANDLE_CODE(ca_params_nr_for_dc_v1540.unpack(bref)); + } + if (ca_params_nr_for_dc_v1550_present) { + HANDLE_CODE(ca_params_nr_for_dc_v1550.unpack(bref)); + } + if (ca_params_nr_for_dc_v1560_present) { + HANDLE_CODE(ca_params_nr_for_dc_v1560.unpack(bref)); + } + if (feature_set_combination_dc_present) { + HANDLE_CODE(unpack_integer(feature_set_combination_dc, bref, (uint16_t)0u, (uint16_t)1024u)); } - return *this; + return SRSASN_SUCCESS; } -void ul_ccch1_msg_type_c::to_json(json_writer& j) const +void ca_params_nrdc_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::c1: - j.write_fieldname("c1"); - c.get().to_json(j); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); + if (ca_params_nr_for_dc_present) { + j.write_fieldname("ca-ParametersNR-ForDC"); + ca_params_nr_for_dc.to_json(j); + } + if (ca_params_nr_for_dc_v1540_present) { + j.write_fieldname("ca-ParametersNR-ForDC-v1540"); + ca_params_nr_for_dc_v1540.to_json(j); + } + if (ca_params_nr_for_dc_v1550_present) { + j.write_fieldname("ca-ParametersNR-ForDC-v1550"); + ca_params_nr_for_dc_v1550.to_json(j); + } + if (ca_params_nr_for_dc_v1560_present) { + j.write_fieldname("ca-ParametersNR-ForDC-v1560"); + ca_params_nr_for_dc_v1560.to_json(j); + } + if (feature_set_combination_dc_present) { + j.write_int("featureSetCombinationDC", feature_set_combination_dc); } j.end_obj(); } -SRSASN_CODE ul_ccch1_msg_type_c::pack(bit_ref& bref) const + +// BandCombination-v1560 ::= SEQUENCE +SRSASN_CODE band_combination_v1560_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::c1: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); - return SRSASN_ERROR_ENCODE_FAIL; + HANDLE_CODE(bref.pack(ne_dc_bc_present, 1)); + HANDLE_CODE(bref.pack(ca_params_nrdc_present, 1)); + HANDLE_CODE(bref.pack(ca_params_eutra_v1560_present, 1)); + HANDLE_CODE(bref.pack(ca_params_nr_v1560_present, 1)); + + if (ca_params_nrdc_present) { + HANDLE_CODE(ca_params_nrdc.pack(bref)); + } + if (ca_params_eutra_v1560_present) { + HANDLE_CODE(ca_params_eutra_v1560.pack(bref)); } + if (ca_params_nr_v1560_present) { + HANDLE_CODE(ca_params_nr_v1560.pack(bref)); + } + return SRSASN_SUCCESS; } -SRSASN_CODE ul_ccch1_msg_type_c::unpack(cbit_ref& bref) +SRSASN_CODE band_combination_v1560_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::c1: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::msg_class_ext: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c"); - return SRSASN_ERROR_DECODE_FAIL; + HANDLE_CODE(bref.unpack(ne_dc_bc_present, 1)); + HANDLE_CODE(bref.unpack(ca_params_nrdc_present, 1)); + HANDLE_CODE(bref.unpack(ca_params_eutra_v1560_present, 1)); + HANDLE_CODE(bref.unpack(ca_params_nr_v1560_present, 1)); + + if (ca_params_nrdc_present) { + HANDLE_CODE(ca_params_nrdc.unpack(bref)); + } + if (ca_params_eutra_v1560_present) { + HANDLE_CODE(ca_params_eutra_v1560.unpack(bref)); + } + if (ca_params_nr_v1560_present) { + HANDLE_CODE(ca_params_nr_v1560.unpack(bref)); } - return SRSASN_SUCCESS; -} -void ul_ccch1_msg_type_c::c1_c_::set(types::options e) -{ - type_ = e; + return SRSASN_SUCCESS; } -void ul_ccch1_msg_type_c::c1_c_::to_json(json_writer& j) const +void band_combination_v1560_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::rrc_resume_request1: - j.write_fieldname("rrcResumeRequest1"); - c.to_json(j); - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c::c1_c_"); + if (ne_dc_bc_present) { + j.write_str("ne-DC-BC", "supported"); + } + if (ca_params_nrdc_present) { + j.write_fieldname("ca-ParametersNRDC"); + ca_params_nrdc.to_json(j); + } + if (ca_params_eutra_v1560_present) { + j.write_fieldname("ca-ParametersEUTRA-v1560"); + ca_params_eutra_v1560.to_json(j); + } + if (ca_params_nr_v1560_present) { + j.write_fieldname("ca-ParametersNR-v1560"); + ca_params_nr_v1560.to_json(j); } j.end_obj(); } -SRSASN_CODE ul_ccch1_msg_type_c::c1_c_::pack(bit_ref& bref) const + +// CA-ParametersEUTRA-v1570 ::= SEQUENCE +SRSASN_CODE ca_params_eutra_v1570_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::rrc_resume_request1: - HANDLE_CODE(c.pack(bref)); - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c::c1_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + HANDLE_CODE(bref.pack(dl_minus1024_qam_total_weighted_layers_present, 1)); + + if (dl_minus1024_qam_total_weighted_layers_present) { + HANDLE_CODE(pack_integer(bref, dl_minus1024_qam_total_weighted_layers, (uint8_t)0u, (uint8_t)10u)); } + return SRSASN_SUCCESS; } -SRSASN_CODE ul_ccch1_msg_type_c::c1_c_::unpack(cbit_ref& bref) +SRSASN_CODE ca_params_eutra_v1570_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::rrc_resume_request1: - HANDLE_CODE(c.unpack(bref)); - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "ul_ccch1_msg_type_c::c1_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; -} + HANDLE_CODE(bref.unpack(dl_minus1024_qam_total_weighted_layers_present, 1)); -std::string ul_ccch1_msg_type_c::c1_c_::types_opts::to_string() const -{ - static const char* options[] = {"rrcResumeRequest1", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 4, value, "ul_ccch1_msg_type_c::c1_c_::types"); -} -uint8_t ul_ccch1_msg_type_c::c1_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "ul_ccch1_msg_type_c::c1_c_::types"); -} + if (dl_minus1024_qam_total_weighted_layers_present) { + HANDLE_CODE(unpack_integer(dl_minus1024_qam_total_weighted_layers, bref, (uint8_t)0u, (uint8_t)10u)); + } -std::string ul_ccch1_msg_type_c::types_opts::to_string() const -{ - static const char* options[] = {"c1", "messageClassExtension"}; - return convert_enum_idx(options, 2, value, "ul_ccch1_msg_type_c::types"); + return SRSASN_SUCCESS; } -uint8_t ul_ccch1_msg_type_c::types_opts::to_number() const +void ca_params_eutra_v1570_s::to_json(json_writer& j) const { - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "ul_ccch1_msg_type_c::types"); + j.start_obj(); + if (dl_minus1024_qam_total_weighted_layers_present) { + j.write_int("dl-1024QAM-TotalWeightedLayers", dl_minus1024_qam_total_weighted_layers); + } + j.end_obj(); } -// UL-CCCH1-Message ::= SEQUENCE -SRSASN_CODE ul_ccch1_msg_s::pack(bit_ref& bref) const +// BandCombination-v1570 ::= SEQUENCE +SRSASN_CODE band_combination_v1570_s::pack(bit_ref& bref) const { - HANDLE_CODE(msg.pack(bref)); - - bref.align_bytes_zero(); + HANDLE_CODE(ca_params_eutra_v1570.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ul_ccch1_msg_s::unpack(cbit_ref& bref) +SRSASN_CODE band_combination_v1570_s::unpack(cbit_ref& bref) { - HANDLE_CODE(msg.unpack(bref)); - - bref.align_bytes(); + HANDLE_CODE(ca_params_eutra_v1570.unpack(bref)); return SRSASN_SUCCESS; } -void ul_ccch1_msg_s::to_json(json_writer& j) const +void band_combination_v1570_s::to_json(json_writer& j) const { - j.start_array(); j.start_obj(); - j.start_obj("UL-CCCH1-Message"); - j.write_fieldname("message"); - msg.to_json(j); - j.end_obj(); + j.write_fieldname("ca-ParametersEUTRA-v1570"); + ca_params_eutra_v1570.to_json(j); j.end_obj(); - j.end_array(); } -// MeasQuantityResults ::= SEQUENCE -SRSASN_CODE meas_quant_results_s::pack(bit_ref& bref) const +// MRDC-Parameters-v1580 ::= SEQUENCE +SRSASN_CODE mrdc_params_v1580_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(rsrp_present, 1)); - HANDLE_CODE(bref.pack(rsrq_present, 1)); - HANDLE_CODE(bref.pack(sinr_present, 1)); - - if (rsrp_present) { - HANDLE_CODE(pack_integer(bref, rsrp, (uint8_t)0u, (uint8_t)127u)); - } - if (rsrq_present) { - HANDLE_CODE(pack_integer(bref, rsrq, (uint8_t)0u, (uint8_t)127u)); - } - if (sinr_present) { - HANDLE_CODE(pack_integer(bref, sinr, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(bref.pack(dynamic_pwr_sharing_nedc_present, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_quant_results_s::unpack(cbit_ref& bref) +SRSASN_CODE mrdc_params_v1580_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(rsrp_present, 1)); - HANDLE_CODE(bref.unpack(rsrq_present, 1)); - HANDLE_CODE(bref.unpack(sinr_present, 1)); - - if (rsrp_present) { - HANDLE_CODE(unpack_integer(rsrp, bref, (uint8_t)0u, (uint8_t)127u)); - } - if (rsrq_present) { - HANDLE_CODE(unpack_integer(rsrq, bref, (uint8_t)0u, (uint8_t)127u)); - } - if (sinr_present) { - HANDLE_CODE(unpack_integer(sinr, bref, (uint8_t)0u, (uint8_t)127u)); - } + HANDLE_CODE(bref.unpack(dynamic_pwr_sharing_nedc_present, 1)); return SRSASN_SUCCESS; } -void meas_quant_results_s::to_json(json_writer& j) const +void mrdc_params_v1580_s::to_json(json_writer& j) const { j.start_obj(); - if (rsrp_present) { - j.write_int("rsrp", rsrp); - } - if (rsrq_present) { - j.write_int("rsrq", rsrq); - } - if (sinr_present) { - j.write_int("sinr", sinr); + if (dynamic_pwr_sharing_nedc_present) { + j.write_str("dynamicPowerSharingNEDC", "supported"); } j.end_obj(); } -// PLMN-Identity-EUTRA-5GC ::= CHOICE -void plmn_id_eutra_minus5_gc_c::destroy_() -{ - switch (type_) { - case types::plmn_id_eutra_minus5_gc: - c.destroy(); - break; - default: - break; - } -} -void plmn_id_eutra_minus5_gc_c::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::plmn_id_eutra_minus5_gc: - c.init(); - break; - case types::plmn_idx: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); - } -} -plmn_id_eutra_minus5_gc_c::plmn_id_eutra_minus5_gc_c(const plmn_id_eutra_minus5_gc_c& other) +// BandCombination-v1580 ::= SEQUENCE +SRSASN_CODE band_combination_v1580_s::pack(bit_ref& bref) const { - type_ = other.type(); - switch (type_) { - case types::plmn_id_eutra_minus5_gc: - c.init(other.c.get()); - break; - case types::plmn_idx: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); - } + HANDLE_CODE(mrdc_params_v1580.pack(bref)); + + return SRSASN_SUCCESS; } -plmn_id_eutra_minus5_gc_c& plmn_id_eutra_minus5_gc_c::operator=(const plmn_id_eutra_minus5_gc_c& other) +SRSASN_CODE band_combination_v1580_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::plmn_id_eutra_minus5_gc: - c.set(other.c.get()); - break; - case types::plmn_idx: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); - } + HANDLE_CODE(mrdc_params_v1580.unpack(bref)); - return *this; + return SRSASN_SUCCESS; } -void plmn_id_eutra_minus5_gc_c::to_json(json_writer& j) const +void band_combination_v1580_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::plmn_id_eutra_minus5_gc: - j.write_fieldname("plmn-Identity-EUTRA-5GC"); - c.get().to_json(j); - break; - case types::plmn_idx: - j.write_int("plmn-index", c.get()); - break; - default: - log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); - } + j.write_fieldname("mrdc-Parameters-v1580"); + mrdc_params_v1580.to_json(j); j.end_obj(); } -SRSASN_CODE plmn_id_eutra_minus5_gc_c::pack(bit_ref& bref) const + +// MRDC-Parameters-v1590 ::= SEQUENCE +SRSASN_CODE mrdc_params_v1590_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::plmn_id_eutra_minus5_gc: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::plmn_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)12u)); - break; - default: - log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); - return SRSASN_ERROR_ENCODE_FAIL; - } + HANDLE_CODE(bref.pack(inter_band_contiguous_mrdc_present, 1)); + return SRSASN_SUCCESS; } -SRSASN_CODE plmn_id_eutra_minus5_gc_c::unpack(cbit_ref& bref) +SRSASN_CODE mrdc_params_v1590_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::plmn_id_eutra_minus5_gc: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::plmn_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)12u)); - break; - default: - log_invalid_choice_id(type_, "plmn_id_eutra_minus5_gc_c"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; -} + HANDLE_CODE(bref.unpack(inter_band_contiguous_mrdc_present, 1)); -std::string plmn_id_eutra_minus5_gc_c::types_opts::to_string() const -{ - static const char* options[] = {"plmn-Identity-EUTRA-5GC", "plmn-index"}; - return convert_enum_idx(options, 2, value, "plmn_id_eutra_minus5_gc_c::types"); + return SRSASN_SUCCESS; } -int8_t plmn_id_eutra_minus5_gc_c::types_opts::to_number() const +void mrdc_params_v1590_s::to_json(json_writer& j) const { - static const int8_t options[] = {-5}; - return map_enum_number(options, 1, value, "plmn_id_eutra_minus5_gc_c::types"); + j.start_obj(); + if (inter_band_contiguous_mrdc_present) { + j.write_str("interBandContiguousMRDC", "supported"); + } + j.end_obj(); } -// ResultsPerCSI-RS-Index ::= SEQUENCE -SRSASN_CODE results_per_csi_rs_idx_s::pack(bit_ref& bref) const +// BandCombination-v1590 ::= SEQUENCE +SRSASN_CODE band_combination_v1590_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(csi_rs_results_present, 1)); + HANDLE_CODE(bref.pack(supported_bw_combination_set_intra_endc_present, 1)); - HANDLE_CODE(pack_integer(bref, csi_rs_idx, (uint8_t)0u, (uint8_t)95u)); - if (csi_rs_results_present) { - HANDLE_CODE(csi_rs_results.pack(bref)); + if (supported_bw_combination_set_intra_endc_present) { + HANDLE_CODE(supported_bw_combination_set_intra_endc.pack(bref)); } + HANDLE_CODE(mrdc_params_v1590.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE results_per_csi_rs_idx_s::unpack(cbit_ref& bref) +SRSASN_CODE band_combination_v1590_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(csi_rs_results_present, 1)); + HANDLE_CODE(bref.unpack(supported_bw_combination_set_intra_endc_present, 1)); - HANDLE_CODE(unpack_integer(csi_rs_idx, bref, (uint8_t)0u, (uint8_t)95u)); - if (csi_rs_results_present) { - HANDLE_CODE(csi_rs_results.unpack(bref)); + if (supported_bw_combination_set_intra_endc_present) { + HANDLE_CODE(supported_bw_combination_set_intra_endc.unpack(bref)); } + HANDLE_CODE(mrdc_params_v1590.unpack(bref)); return SRSASN_SUCCESS; } -void results_per_csi_rs_idx_s::to_json(json_writer& j) const +void band_combination_v1590_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("csi-RS-Index", csi_rs_idx); - if (csi_rs_results_present) { - j.write_fieldname("csi-RS-Results"); - csi_rs_results.to_json(j); + if (supported_bw_combination_set_intra_endc_present) { + j.write_str("supportedBandwidthCombinationSetIntraENDC", supported_bw_combination_set_intra_endc.to_string()); } + j.write_fieldname("mrdc-Parameters-v1590"); + mrdc_params_v1590.to_json(j); j.end_obj(); } -// ResultsPerSSB-Index ::= SEQUENCE -SRSASN_CODE results_per_ssb_idx_s::pack(bit_ref& bref) const +// SupportedCSI-RS-Resource ::= SEQUENCE +SRSASN_CODE supported_csi_rs_res_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(ssb_results_present, 1)); - - HANDLE_CODE(pack_integer(bref, ssb_idx, (uint8_t)0u, (uint8_t)63u)); - if (ssb_results_present) { - HANDLE_CODE(ssb_results.pack(bref)); - } + HANDLE_CODE(max_num_tx_ports_per_res.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_num_res_per_band, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_integer(bref, total_num_tx_ports_per_band, (uint16_t)2u, (uint16_t)256u)); return SRSASN_SUCCESS; } -SRSASN_CODE results_per_ssb_idx_s::unpack(cbit_ref& bref) +SRSASN_CODE supported_csi_rs_res_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(ssb_results_present, 1)); - - HANDLE_CODE(unpack_integer(ssb_idx, bref, (uint8_t)0u, (uint8_t)63u)); - if (ssb_results_present) { - HANDLE_CODE(ssb_results.unpack(bref)); - } + HANDLE_CODE(max_num_tx_ports_per_res.unpack(bref)); + HANDLE_CODE(unpack_integer(max_num_res_per_band, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_integer(total_num_tx_ports_per_band, bref, (uint16_t)2u, (uint16_t)256u)); return SRSASN_SUCCESS; } -void results_per_ssb_idx_s::to_json(json_writer& j) const +void supported_csi_rs_res_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("ssb-Index", ssb_idx); - if (ssb_results_present) { - j.write_fieldname("ssb-Results"); - ssb_results.to_json(j); - } + j.write_str("maxNumberTxPortsPerResource", max_num_tx_ports_per_res.to_string()); + j.write_int("maxNumberResourcesPerBand", max_num_res_per_band); + j.write_int("totalNumberTxPortsPerBand", total_num_tx_ports_per_band); j.end_obj(); } -// CGI-Info ::= SEQUENCE -SRSASN_CODE cgi_info_s::pack(bit_ref& bref) const +std::string supported_csi_rs_res_s::max_num_tx_ports_per_res_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(plmn_id_info_list_present, 1)); - HANDLE_CODE(bref.pack(freq_band_list_present, 1)); - HANDLE_CODE(bref.pack(no_sib1_present, 1)); + static const char* options[] = {"p2", "p4", "p8", "p12", "p16", "p24", "p32"}; + return convert_enum_idx(options, 7, value, "supported_csi_rs_res_s::max_num_tx_ports_per_res_e_"); +} +uint8_t supported_csi_rs_res_s::max_num_tx_ports_per_res_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 8, 12, 16, 24, 32}; + return map_enum_number(options, 7, value, "supported_csi_rs_res_s::max_num_tx_ports_per_res_e_"); +} - if (plmn_id_info_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, plmn_id_info_list, 1, 12)); - } - if (freq_band_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, freq_band_list, 1, 8, integer_packer(1, 1024))); - } - if (no_sib1_present) { - HANDLE_CODE(pack_integer(bref, no_sib1.ssb_subcarrier_offset, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(no_sib1.pdcch_cfg_sib1.pack(bref)); +// BeamManagementSSB-CSI-RS ::= SEQUENCE +SRSASN_CODE beam_management_ssb_csi_rs_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(supported_csi_rs_density_present, 1)); + + HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.pack(bref)); + HANDLE_CODE(max_num_csi_rs_res.pack(bref)); + HANDLE_CODE(max_num_csi_rs_res_two_tx.pack(bref)); + if (supported_csi_rs_density_present) { + HANDLE_CODE(supported_csi_rs_density.pack(bref)); } + HANDLE_CODE(max_num_aperiodic_csi_rs_res.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE cgi_info_s::unpack(cbit_ref& bref) +SRSASN_CODE beam_management_ssb_csi_rs_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(plmn_id_info_list_present, 1)); - HANDLE_CODE(bref.unpack(freq_band_list_present, 1)); - HANDLE_CODE(bref.unpack(no_sib1_present, 1)); + HANDLE_CODE(bref.unpack(supported_csi_rs_density_present, 1)); - if (plmn_id_info_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(plmn_id_info_list, bref, 1, 12)); - } - if (freq_band_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(freq_band_list, bref, 1, 8, integer_packer(1, 1024))); - } - if (no_sib1_present) { - HANDLE_CODE(unpack_integer(no_sib1.ssb_subcarrier_offset, bref, (uint8_t)0u, (uint8_t)15u)); - HANDLE_CODE(no_sib1.pdcch_cfg_sib1.unpack(bref)); + HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.unpack(bref)); + HANDLE_CODE(max_num_csi_rs_res.unpack(bref)); + HANDLE_CODE(max_num_csi_rs_res_two_tx.unpack(bref)); + if (supported_csi_rs_density_present) { + HANDLE_CODE(supported_csi_rs_density.unpack(bref)); } + HANDLE_CODE(max_num_aperiodic_csi_rs_res.unpack(bref)); return SRSASN_SUCCESS; } -void cgi_info_s::to_json(json_writer& j) const +void beam_management_ssb_csi_rs_s::to_json(json_writer& j) const { j.start_obj(); - if (plmn_id_info_list_present) { - j.start_array("plmn-IdentityInfoList"); - for (const auto& e1 : plmn_id_info_list) { - e1.to_json(j); - } - j.end_array(); - } - if (freq_band_list_present) { - j.start_array("frequencyBandList"); - for (const auto& e1 : freq_band_list) { - j.write_int(e1); - } - j.end_array(); - } - if (no_sib1_present) { - j.write_fieldname("noSIB1"); - j.start_obj(); - j.write_int("ssb-SubcarrierOffset", no_sib1.ssb_subcarrier_offset); - j.write_fieldname("pdcch-ConfigSIB1"); - no_sib1.pdcch_cfg_sib1.to_json(j); - j.end_obj(); + j.write_str("maxNumberSSB-CSI-RS-ResourceOneTx", max_num_ssb_csi_rs_res_one_tx.to_string()); + j.write_str("maxNumberCSI-RS-Resource", max_num_csi_rs_res.to_string()); + j.write_str("maxNumberCSI-RS-ResourceTwoTx", max_num_csi_rs_res_two_tx.to_string()); + if (supported_csi_rs_density_present) { + j.write_str("supportedCSI-RS-Density", supported_csi_rs_density.to_string()); } + j.write_str("maxNumberAperiodicCSI-RS-Resource", max_num_aperiodic_csi_rs_res.to_string()); j.end_obj(); } -// CellIdentity-EUTRA-5GC ::= CHOICE -void cell_id_eutra_minus5_gc_c::destroy_() +std::string beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_opts::to_string() const { - switch (type_) { - case types::cell_id_eutra: - c.destroy >(); - break; - default: - break; - } + static const char* options[] = {"n0", "n8", "n16", "n32", "n64"}; + return convert_enum_idx(options, 5, value, "beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_e_"); } -void cell_id_eutra_minus5_gc_c::set(types::options e) +uint8_t beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_opts::to_number() const { - destroy_(); - type_ = e; - switch (type_) { - case types::cell_id_eutra: - c.init >(); - break; - case types::cell_id_idx: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); - } + static const uint8_t options[] = {0, 8, 16, 32, 64}; + return map_enum_number(options, 5, value, "beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_e_"); } -cell_id_eutra_minus5_gc_c::cell_id_eutra_minus5_gc_c(const cell_id_eutra_minus5_gc_c& other) + +std::string beam_management_ssb_csi_rs_s::max_num_csi_rs_res_opts::to_string() const { - type_ = other.type(); - switch (type_) { - case types::cell_id_eutra: - c.init(other.c.get >()); - break; - case types::cell_id_idx: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); - } + static const char* options[] = {"n0", "n4", "n8", "n16", "n32", "n64"}; + return convert_enum_idx(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_e_"); } -cell_id_eutra_minus5_gc_c& cell_id_eutra_minus5_gc_c::operator=(const cell_id_eutra_minus5_gc_c& other) +uint8_t beam_management_ssb_csi_rs_s::max_num_csi_rs_res_opts::to_number() const { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::cell_id_eutra: - c.set(other.c.get >()); - break; - case types::cell_id_idx: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); - } - - return *this; + static const uint8_t options[] = {0, 4, 8, 16, 32, 64}; + return map_enum_number(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_e_"); } -void cell_id_eutra_minus5_gc_c::to_json(json_writer& j) const + +std::string beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_opts::to_string() const { - j.start_obj(); - switch (type_) { - case types::cell_id_eutra: - j.write_str("cellIdentity-EUTRA", c.get >().to_string()); - break; - case types::cell_id_idx: - j.write_int("cellId-index", c.get()); - break; - default: - log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); - } - j.end_obj(); + static const char* options[] = {"n0", "n4", "n8", "n16", "n32", "n64"}; + return convert_enum_idx(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_e_"); } -SRSASN_CODE cell_id_eutra_minus5_gc_c::pack(bit_ref& bref) const +uint8_t beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_opts::to_number() const { - type_.pack(bref); - switch (type_) { - case types::cell_id_eutra: - HANDLE_CODE(c.get >().pack(bref)); - break; - case types::cell_id_idx: - HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)12u)); - break; - default: - log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const uint8_t options[] = {0, 4, 8, 16, 32, 64}; + return map_enum_number(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_e_"); } -SRSASN_CODE cell_id_eutra_minus5_gc_c::unpack(cbit_ref& bref) + +std::string beam_management_ssb_csi_rs_s::supported_csi_rs_density_opts::to_string() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::cell_id_eutra: - HANDLE_CODE(c.get >().unpack(bref)); - break; - case types::cell_id_idx: - HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)12u)); - break; - default: - log_invalid_choice_id(type_, "cell_id_eutra_minus5_gc_c"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"one", "three", "oneAndThree"}; + return convert_enum_idx(options, 3, value, "beam_management_ssb_csi_rs_s::supported_csi_rs_density_e_"); } -std::string cell_id_eutra_minus5_gc_c::types_opts::to_string() const +std::string beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_opts::to_string() const { - static const char* options[] = {"cellIdentity-EUTRA", "cellId-index"}; - return convert_enum_idx(options, 2, value, "cell_id_eutra_minus5_gc_c::types"); + static const char* options[] = {"n0", "n1", "n4", "n8", "n16", "n32", "n64"}; + return convert_enum_idx(options, 7, value, "beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_e_"); } - -// CellAccessRelatedInfo-EUTRA-5GC ::= SEQUENCE -SRSASN_CODE cell_access_related_info_eutra_minus5_gc_s::pack(bit_ref& bref) const +uint8_t beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_opts::to_number() const { - HANDLE_CODE(bref.pack(ranac_minus5gc_present, 1)); + static const uint8_t options[] = {0, 1, 4, 8, 16, 32, 64}; + return map_enum_number(options, 7, value, "beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_e_"); +} - HANDLE_CODE(pack_dyn_seq_of(bref, plmn_id_list_eutra_minus5gc, 1, 12)); - HANDLE_CODE(tac_eutra_minus5gc.pack(bref)); - if (ranac_minus5gc_present) { - HANDLE_CODE(pack_integer(bref, ranac_minus5gc, (uint16_t)0u, (uint16_t)255u)); - } - HANDLE_CODE(cell_id_eutra_minus5gc.pack(bref)); +// CSI-RS-ForTracking ::= SEQUENCE +SRSASN_CODE csi_rs_for_tracking_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, max_burst_len, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(pack_integer(bref, max_simul_res_sets_per_cc, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_per_cc, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_all_cc, (uint16_t)1u, (uint16_t)256u)); return SRSASN_SUCCESS; } -SRSASN_CODE cell_access_related_info_eutra_minus5_gc_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_rs_for_tracking_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(ranac_minus5gc_present, 1)); - - HANDLE_CODE(unpack_dyn_seq_of(plmn_id_list_eutra_minus5gc, bref, 1, 12)); - HANDLE_CODE(tac_eutra_minus5gc.unpack(bref)); - if (ranac_minus5gc_present) { - HANDLE_CODE(unpack_integer(ranac_minus5gc, bref, (uint16_t)0u, (uint16_t)255u)); - } - HANDLE_CODE(cell_id_eutra_minus5gc.unpack(bref)); + HANDLE_CODE(unpack_integer(max_burst_len, bref, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(unpack_integer(max_simul_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(unpack_integer(max_cfgured_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_integer(max_cfgured_res_sets_all_cc, bref, (uint16_t)1u, (uint16_t)256u)); return SRSASN_SUCCESS; } -void cell_access_related_info_eutra_minus5_gc_s::to_json(json_writer& j) const +void csi_rs_for_tracking_s::to_json(json_writer& j) const { j.start_obj(); - j.start_array("plmn-IdentityList-eutra-5gc"); - for (const auto& e1 : plmn_id_list_eutra_minus5gc) { - e1.to_json(j); - } - j.end_array(); - j.write_str("trackingAreaCode-eutra-5gc", tac_eutra_minus5gc.to_string()); - if (ranac_minus5gc_present) { - j.write_int("ranac-5gc", ranac_minus5gc); - } - j.write_fieldname("cellIdentity-eutra-5gc"); - cell_id_eutra_minus5gc.to_json(j); + j.write_int("maxBurstLength", max_burst_len); + j.write_int("maxSimultaneousResourceSetsPerCC", max_simul_res_sets_per_cc); + j.write_int("maxConfiguredResourceSetsPerCC", max_cfgured_res_sets_per_cc); + j.write_int("maxConfiguredResourceSetsAllCC", max_cfgured_res_sets_all_cc); j.end_obj(); } -// CellAccessRelatedInfo-EUTRA-EPC ::= SEQUENCE -SRSASN_CODE cell_access_related_info_eutra_epc_s::pack(bit_ref& bref) const +// CSI-RS-IM-ReceptionForFeedback ::= SEQUENCE +SRSASN_CODE csi_rs_im_reception_for_feedback_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_dyn_seq_of(bref, plmn_id_list_eutra_epc, 1, 12)); - HANDLE_CODE(tac_eutra_epc.pack(bref)); - HANDLE_CODE(cell_id_eutra_epc.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_cfg_num_nzp_csi_rs_per_cc, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_integer(bref, max_cfg_num_ports_across_nzp_csi_rs_per_cc, (uint16_t)2u, (uint16_t)256u)); + HANDLE_CODE(max_cfg_num_csi_im_per_cc.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_num_simul_nzp_csi_rs_per_cc, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_integer(bref, total_num_ports_simul_nzp_csi_rs_per_cc, (uint16_t)2u, (uint16_t)256u)); return SRSASN_SUCCESS; } -SRSASN_CODE cell_access_related_info_eutra_epc_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_rs_im_reception_for_feedback_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_dyn_seq_of(plmn_id_list_eutra_epc, bref, 1, 12)); - HANDLE_CODE(tac_eutra_epc.unpack(bref)); - HANDLE_CODE(cell_id_eutra_epc.unpack(bref)); + HANDLE_CODE(unpack_integer(max_cfg_num_nzp_csi_rs_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_integer(max_cfg_num_ports_across_nzp_csi_rs_per_cc, bref, (uint16_t)2u, (uint16_t)256u)); + HANDLE_CODE(max_cfg_num_csi_im_per_cc.unpack(bref)); + HANDLE_CODE(unpack_integer(max_num_simul_nzp_csi_rs_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_integer(total_num_ports_simul_nzp_csi_rs_per_cc, bref, (uint16_t)2u, (uint16_t)256u)); return SRSASN_SUCCESS; } -void cell_access_related_info_eutra_epc_s::to_json(json_writer& j) const +void csi_rs_im_reception_for_feedback_s::to_json(json_writer& j) const { j.start_obj(); - j.start_array("plmn-IdentityList-eutra-epc"); - for (const auto& e1 : plmn_id_list_eutra_epc) { - e1.to_json(j); - } - j.end_array(); - j.write_str("trackingAreaCode-eutra-epc", tac_eutra_epc.to_string()); - j.write_str("cellIdentity-eutra-epc", cell_id_eutra_epc.to_string()); + j.write_int("maxConfigNumberNZP-CSI-RS-PerCC", max_cfg_num_nzp_csi_rs_per_cc); + j.write_int("maxConfigNumberPortsAcrossNZP-CSI-RS-PerCC", max_cfg_num_ports_across_nzp_csi_rs_per_cc); + j.write_str("maxConfigNumberCSI-IM-PerCC", max_cfg_num_csi_im_per_cc.to_string()); + j.write_int("maxNumberSimultaneousNZP-CSI-RS-PerCC", max_num_simul_nzp_csi_rs_per_cc); + j.write_int("totalNumberPortsSimultaneousNZP-CSI-RS-PerCC", total_num_ports_simul_nzp_csi_rs_per_cc); j.end_obj(); } -// MeasQuantityResultsEUTRA ::= SEQUENCE -SRSASN_CODE meas_quant_results_eutra_s::pack(bit_ref& bref) const +std::string csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_opts::to_string() const { - HANDLE_CODE(bref.pack(rsrp_present, 1)); - HANDLE_CODE(bref.pack(rsrq_present, 1)); - HANDLE_CODE(bref.pack(sinr_present, 1)); + static const char* options[] = {"n1", "n2", "n4", "n8", "n16", "n32"}; + return convert_enum_idx(options, 6, value, "csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_e_"); +} +uint8_t csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 4, 8, 16, 32}; + return map_enum_number(options, 6, value, "csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_e_"); +} - if (rsrp_present) { - HANDLE_CODE(pack_integer(bref, rsrp, (uint8_t)0u, (uint8_t)97u)); - } - if (rsrq_present) { - HANDLE_CODE(pack_integer(bref, rsrq, (uint8_t)0u, (uint8_t)34u)); - } - if (sinr_present) { - HANDLE_CODE(pack_integer(bref, sinr, (uint8_t)0u, (uint8_t)127u)); - } +// CSI-RS-ProcFrameworkForSRS ::= SEQUENCE +SRSASN_CODE csi_rs_proc_framework_for_srs_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, max_num_periodic_srs_assoc_csi_rs_per_bwp, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, max_num_aperiodic_srs_assoc_csi_rs_per_bwp, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, max_num_sp_srs_assoc_csi_rs_per_bwp, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, simul_srs_assoc_csi_rs_per_cc, (uint8_t)1u, (uint8_t)8u)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_quant_results_eutra_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_rs_proc_framework_for_srs_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(rsrp_present, 1)); - HANDLE_CODE(bref.unpack(rsrq_present, 1)); - HANDLE_CODE(bref.unpack(sinr_present, 1)); + HANDLE_CODE(unpack_integer(max_num_periodic_srs_assoc_csi_rs_per_bwp, bref, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(max_num_aperiodic_srs_assoc_csi_rs_per_bwp, bref, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(max_num_sp_srs_assoc_csi_rs_per_bwp, bref, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(simul_srs_assoc_csi_rs_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); - if (rsrp_present) { - HANDLE_CODE(unpack_integer(rsrp, bref, (uint8_t)0u, (uint8_t)97u)); - } - if (rsrq_present) { - HANDLE_CODE(unpack_integer(rsrq, bref, (uint8_t)0u, (uint8_t)34u)); - } - if (sinr_present) { - HANDLE_CODE(unpack_integer(sinr, bref, (uint8_t)0u, (uint8_t)127u)); - } + return SRSASN_SUCCESS; +} +void csi_rs_proc_framework_for_srs_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("maxNumberPeriodicSRS-AssocCSI-RS-PerBWP", max_num_periodic_srs_assoc_csi_rs_per_bwp); + j.write_int("maxNumberAperiodicSRS-AssocCSI-RS-PerBWP", max_num_aperiodic_srs_assoc_csi_rs_per_bwp); + j.write_int("maxNumberSP-SRS-AssocCSI-RS-PerBWP", max_num_sp_srs_assoc_csi_rs_per_bwp); + j.write_int("simultaneousSRS-AssocCSI-RS-PerCC", simul_srs_assoc_csi_rs_per_cc); + j.end_obj(); +} + +// CSI-ReportFramework ::= SEQUENCE +SRSASN_CODE csi_report_framework_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, max_num_periodic_csi_per_bwp_for_csi_report, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, max_num_aperiodic_csi_per_bwp_for_csi_report, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, max_num_semi_persistent_csi_per_bwp_for_csi_report, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, max_num_periodic_csi_per_bwp_for_beam_report, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, max_num_aperiodic_csi_per_bwp_for_beam_report, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(max_num_aperiodic_csi_trigger_state_per_cc.pack(bref)); + HANDLE_CODE(pack_integer(bref, max_num_semi_persistent_csi_per_bwp_for_beam_report, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, simul_csi_reports_per_cc, (uint8_t)1u, (uint8_t)8u)); return SRSASN_SUCCESS; } -void meas_quant_results_eutra_s::to_json(json_writer& j) const +SRSASN_CODE csi_report_framework_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(max_num_periodic_csi_per_bwp_for_csi_report, bref, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(max_num_aperiodic_csi_per_bwp_for_csi_report, bref, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(max_num_semi_persistent_csi_per_bwp_for_csi_report, bref, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(max_num_periodic_csi_per_bwp_for_beam_report, bref, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(max_num_aperiodic_csi_per_bwp_for_beam_report, bref, (uint8_t)1u, (uint8_t)4u)); + HANDLE_CODE(max_num_aperiodic_csi_trigger_state_per_cc.unpack(bref)); + HANDLE_CODE(unpack_integer(max_num_semi_persistent_csi_per_bwp_for_beam_report, bref, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(simul_csi_reports_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); + + return SRSASN_SUCCESS; +} +void csi_report_framework_s::to_json(json_writer& j) const { j.start_obj(); - if (rsrp_present) { - j.write_int("rsrp", rsrp); - } - if (rsrq_present) { - j.write_int("rsrq", rsrq); - } - if (sinr_present) { - j.write_int("sinr", sinr); - } + j.write_int("maxNumberPeriodicCSI-PerBWP-ForCSI-Report", max_num_periodic_csi_per_bwp_for_csi_report); + j.write_int("maxNumberAperiodicCSI-PerBWP-ForCSI-Report", max_num_aperiodic_csi_per_bwp_for_csi_report); + j.write_int("maxNumberSemiPersistentCSI-PerBWP-ForCSI-Report", max_num_semi_persistent_csi_per_bwp_for_csi_report); + j.write_int("maxNumberPeriodicCSI-PerBWP-ForBeamReport", max_num_periodic_csi_per_bwp_for_beam_report); + j.write_int("maxNumberAperiodicCSI-PerBWP-ForBeamReport", max_num_aperiodic_csi_per_bwp_for_beam_report); + j.write_str("maxNumberAperiodicCSI-triggeringStatePerCC", max_num_aperiodic_csi_trigger_state_per_cc.to_string()); + j.write_int("maxNumberSemiPersistentCSI-PerBWP-ForBeamReport", max_num_semi_persistent_csi_per_bwp_for_beam_report); + j.write_int("simultaneousCSI-ReportsPerCC", simul_csi_reports_per_cc); j.end_obj(); } -// MeasResultNR ::= SEQUENCE -SRSASN_CODE meas_result_nr_s::pack(bit_ref& bref) const +std::string csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(pci_present, 1)); + static const char* options[] = {"n3", "n7", "n15", "n31", "n63", "n128"}; + return convert_enum_idx(options, 6, value, "csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_e_"); +} +uint8_t csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_opts::to_number() const +{ + static const uint8_t options[] = {3, 7, 15, 31, 63, 128}; + return map_enum_number(options, 6, value, "csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_e_"); +} - if (pci_present) { - HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); - } - HANDLE_CODE(bref.pack(meas_result.rs_idx_results_present, 1)); - HANDLE_CODE(bref.pack(meas_result.cell_results.results_ssb_cell_present, 1)); - HANDLE_CODE(bref.pack(meas_result.cell_results.results_csi_rs_cell_present, 1)); - if (meas_result.cell_results.results_ssb_cell_present) { - HANDLE_CODE(meas_result.cell_results.results_ssb_cell.pack(bref)); +// CodebookParameters ::= SEQUENCE +SRSASN_CODE codebook_params_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(type2_present, 1)); + HANDLE_CODE(bref.pack(type2_port_sel_present, 1)); + + HANDLE_CODE(bref.pack(type1.multi_panel_present, 1)); + HANDLE_CODE(pack_dyn_seq_of(bref, type1.single_panel.supported_csi_rs_res_list, 1, 7)); + HANDLE_CODE(type1.single_panel.modes.pack(bref)); + HANDLE_CODE(pack_integer(bref, type1.single_panel.max_num_csi_rs_per_res_set, (uint8_t)1u, (uint8_t)8u)); + if (type1.multi_panel_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, type1.multi_panel.supported_csi_rs_res_list, 1, 7)); + HANDLE_CODE(type1.multi_panel.modes.pack(bref)); + HANDLE_CODE(type1.multi_panel.nrof_panels.pack(bref)); + HANDLE_CODE(pack_integer(bref, type1.multi_panel.max_num_csi_rs_per_res_set, (uint8_t)1u, (uint8_t)8u)); } - if (meas_result.cell_results.results_csi_rs_cell_present) { - HANDLE_CODE(meas_result.cell_results.results_csi_rs_cell.pack(bref)); + if (type2_present) { + HANDLE_CODE(bref.pack(type2.amplitude_subset_restrict_present, 1)); + HANDLE_CODE(pack_dyn_seq_of(bref, type2.supported_csi_rs_res_list, 1, 7)); + HANDLE_CODE(pack_integer(bref, type2.param_lx, (uint8_t)2u, (uint8_t)4u)); + HANDLE_CODE(type2.amplitude_scaling_type.pack(bref)); } - if (meas_result.rs_idx_results_present) { - HANDLE_CODE(bref.pack(meas_result.rs_idx_results.results_ssb_idxes_present, 1)); - HANDLE_CODE(bref.pack(meas_result.rs_idx_results.results_csi_rs_idxes_present, 1)); - if (meas_result.rs_idx_results.results_ssb_idxes_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_result.rs_idx_results.results_ssb_idxes, 1, 64)); - } - if (meas_result.rs_idx_results.results_csi_rs_idxes_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_result.rs_idx_results.results_csi_rs_idxes, 1, 64)); - } + if (type2_port_sel_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, type2_port_sel.supported_csi_rs_res_list, 1, 7)); + HANDLE_CODE(pack_integer(bref, type2_port_sel.param_lx, (uint8_t)2u, (uint8_t)4u)); + HANDLE_CODE(type2_port_sel.amplitude_scaling_type.pack(bref)); } - if (ext) { - ext_groups_packer_guard group_flags; - group_flags[0] |= cgi_info.is_present(); - group_flags.pack(bref); - - if (group_flags[0]) { - varlength_field_pack_guard varlen_scope(bref, false); - - HANDLE_CODE(bref.pack(cgi_info.is_present(), 1)); - if (cgi_info.is_present()) { - HANDLE_CODE(cgi_info->pack(bref)); - } - } - } return SRSASN_SUCCESS; } -SRSASN_CODE meas_result_nr_s::unpack(cbit_ref& bref) +SRSASN_CODE codebook_params_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(pci_present, 1)); + HANDLE_CODE(bref.unpack(type2_present, 1)); + HANDLE_CODE(bref.unpack(type2_port_sel_present, 1)); - if (pci_present) { - HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); - } - HANDLE_CODE(bref.unpack(meas_result.rs_idx_results_present, 1)); - HANDLE_CODE(bref.unpack(meas_result.cell_results.results_ssb_cell_present, 1)); - HANDLE_CODE(bref.unpack(meas_result.cell_results.results_csi_rs_cell_present, 1)); - if (meas_result.cell_results.results_ssb_cell_present) { - HANDLE_CODE(meas_result.cell_results.results_ssb_cell.unpack(bref)); + HANDLE_CODE(bref.unpack(type1.multi_panel_present, 1)); + HANDLE_CODE(unpack_dyn_seq_of(type1.single_panel.supported_csi_rs_res_list, bref, 1, 7)); + HANDLE_CODE(type1.single_panel.modes.unpack(bref)); + HANDLE_CODE(unpack_integer(type1.single_panel.max_num_csi_rs_per_res_set, bref, (uint8_t)1u, (uint8_t)8u)); + if (type1.multi_panel_present) { + HANDLE_CODE(unpack_dyn_seq_of(type1.multi_panel.supported_csi_rs_res_list, bref, 1, 7)); + HANDLE_CODE(type1.multi_panel.modes.unpack(bref)); + HANDLE_CODE(type1.multi_panel.nrof_panels.unpack(bref)); + HANDLE_CODE(unpack_integer(type1.multi_panel.max_num_csi_rs_per_res_set, bref, (uint8_t)1u, (uint8_t)8u)); } - if (meas_result.cell_results.results_csi_rs_cell_present) { - HANDLE_CODE(meas_result.cell_results.results_csi_rs_cell.unpack(bref)); + if (type2_present) { + HANDLE_CODE(bref.unpack(type2.amplitude_subset_restrict_present, 1)); + HANDLE_CODE(unpack_dyn_seq_of(type2.supported_csi_rs_res_list, bref, 1, 7)); + HANDLE_CODE(unpack_integer(type2.param_lx, bref, (uint8_t)2u, (uint8_t)4u)); + HANDLE_CODE(type2.amplitude_scaling_type.unpack(bref)); } - if (meas_result.rs_idx_results_present) { - HANDLE_CODE(bref.unpack(meas_result.rs_idx_results.results_ssb_idxes_present, 1)); - HANDLE_CODE(bref.unpack(meas_result.rs_idx_results.results_csi_rs_idxes_present, 1)); - if (meas_result.rs_idx_results.results_ssb_idxes_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_result.rs_idx_results.results_ssb_idxes, bref, 1, 64)); - } - if (meas_result.rs_idx_results.results_csi_rs_idxes_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_result.rs_idx_results.results_csi_rs_idxes, bref, 1, 64)); - } + if (type2_port_sel_present) { + HANDLE_CODE(unpack_dyn_seq_of(type2_port_sel.supported_csi_rs_res_list, bref, 1, 7)); + HANDLE_CODE(unpack_integer(type2_port_sel.param_lx, bref, (uint8_t)2u, (uint8_t)4u)); + HANDLE_CODE(type2_port_sel.amplitude_scaling_type.unpack(bref)); } - if (ext) { - ext_groups_unpacker_guard group_flags(1); - group_flags.unpack(bref); - - if (group_flags[0]) { - varlength_field_unpack_guard varlen_scope(bref, false); - - bool cgi_info_present; - HANDLE_CODE(bref.unpack(cgi_info_present, 1)); - cgi_info.set_present(cgi_info_present); - if (cgi_info.is_present()) { - HANDLE_CODE(cgi_info->unpack(bref)); - } - } - } return SRSASN_SUCCESS; } -void meas_result_nr_s::to_json(json_writer& j) const +void codebook_params_s::to_json(json_writer& j) const { j.start_obj(); - if (pci_present) { - j.write_int("physCellId", pci); - } - j.write_fieldname("measResult"); + j.write_fieldname("type1"); j.start_obj(); - j.write_fieldname("cellResults"); + j.write_fieldname("singlePanel"); j.start_obj(); - if (meas_result.cell_results.results_ssb_cell_present) { - j.write_fieldname("resultsSSB-Cell"); - meas_result.cell_results.results_ssb_cell.to_json(j); + j.start_array("supportedCSI-RS-ResourceList"); + for (const auto& e1 : type1.single_panel.supported_csi_rs_res_list) { + e1.to_json(j); } - if (meas_result.cell_results.results_csi_rs_cell_present) { - j.write_fieldname("resultsCSI-RS-Cell"); - meas_result.cell_results.results_csi_rs_cell.to_json(j); + j.end_array(); + j.write_str("modes", type1.single_panel.modes.to_string()); + j.write_int("maxNumberCSI-RS-PerResourceSet", type1.single_panel.max_num_csi_rs_per_res_set); + j.end_obj(); + if (type1.multi_panel_present) { + j.write_fieldname("multiPanel"); + j.start_obj(); + j.start_array("supportedCSI-RS-ResourceList"); + for (const auto& e1 : type1.multi_panel.supported_csi_rs_res_list) { + e1.to_json(j); + } + j.end_array(); + j.write_str("modes", type1.multi_panel.modes.to_string()); + j.write_str("nrofPanels", type1.multi_panel.nrof_panels.to_string()); + j.write_int("maxNumberCSI-RS-PerResourceSet", type1.multi_panel.max_num_csi_rs_per_res_set); + j.end_obj(); } j.end_obj(); - if (meas_result.rs_idx_results_present) { - j.write_fieldname("rsIndexResults"); + if (type2_present) { + j.write_fieldname("type2"); j.start_obj(); - if (meas_result.rs_idx_results.results_ssb_idxes_present) { - j.start_array("resultsSSB-Indexes"); - for (const auto& e1 : meas_result.rs_idx_results.results_ssb_idxes) { - e1.to_json(j); - } - j.end_array(); + j.start_array("supportedCSI-RS-ResourceList"); + for (const auto& e1 : type2.supported_csi_rs_res_list) { + e1.to_json(j); } - if (meas_result.rs_idx_results.results_csi_rs_idxes_present) { - j.start_array("resultsCSI-RS-Indexes"); - for (const auto& e1 : meas_result.rs_idx_results.results_csi_rs_idxes) { - e1.to_json(j); - } - j.end_array(); + j.end_array(); + j.write_int("parameterLx", type2.param_lx); + j.write_str("amplitudeScalingType", type2.amplitude_scaling_type.to_string()); + if (type2.amplitude_subset_restrict_present) { + j.write_str("amplitudeSubsetRestriction", "supported"); } j.end_obj(); } - j.end_obj(); - if (ext) { - if (cgi_info.is_present()) { - j.write_fieldname("cgi-Info"); - cgi_info->to_json(j); + if (type2_port_sel_present) { + j.write_fieldname("type2-PortSelection"); + j.start_obj(); + j.start_array("supportedCSI-RS-ResourceList"); + for (const auto& e1 : type2_port_sel.supported_csi_rs_res_list) { + e1.to_json(j); } + j.end_array(); + j.write_int("parameterLx", type2_port_sel.param_lx); + j.write_str("amplitudeScalingType", type2_port_sel.amplitude_scaling_type.to_string()); + j.end_obj(); } j.end_obj(); } -// UplinkTxDirectCurrentBWP ::= SEQUENCE -SRSASN_CODE ul_tx_direct_current_bwp_s::pack(bit_ref& bref) const +std::string codebook_params_s::type1_s_::single_panel_s_::modes_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(bref.pack(shift7dot5k_hz, 1)); - HANDLE_CODE(pack_integer(bref, tx_direct_current_location, (uint16_t)0u, (uint16_t)3301u)); - - return SRSASN_SUCCESS; + static const char* options[] = {"mode1", "mode1andMode2"}; + return convert_enum_idx(options, 2, value, "codebook_params_s::type1_s_::single_panel_s_::modes_e_"); } -SRSASN_CODE ul_tx_direct_current_bwp_s::unpack(cbit_ref& bref) + +std::string codebook_params_s::type1_s_::multi_panel_s_::modes_opts::to_string() const { - HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(bref.unpack(shift7dot5k_hz, 1)); - HANDLE_CODE(unpack_integer(tx_direct_current_location, bref, (uint16_t)0u, (uint16_t)3301u)); + static const char* options[] = {"mode1", "mode2", "both"}; + return convert_enum_idx(options, 3, value, "codebook_params_s::type1_s_::multi_panel_s_::modes_e_"); +} +uint8_t codebook_params_s::type1_s_::multi_panel_s_::modes_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "codebook_params_s::type1_s_::multi_panel_s_::modes_e_"); +} - return SRSASN_SUCCESS; +std::string codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_opts::to_string() const +{ + static const char* options[] = {"n2", "n4"}; + return convert_enum_idx(options, 2, value, "codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_e_"); } -void ul_tx_direct_current_bwp_s::to_json(json_writer& j) const +uint8_t codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_opts::to_number() const { - j.start_obj(); - j.write_int("bwp-Id", bwp_id); - j.write_bool("shift7dot5kHz", shift7dot5k_hz); - j.write_int("txDirectCurrentLocation", tx_direct_current_location); - j.end_obj(); + static const uint8_t options[] = {2, 4}; + return map_enum_number(options, 2, value, "codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_e_"); } -// EUTRA-RSTD-Info ::= SEQUENCE -SRSASN_CODE eutra_rstd_info_s::pack(bit_ref& bref) const +std::string codebook_params_s::type2_s_::amplitude_scaling_type_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, carrier_freq, (uint32_t)0u, (uint32_t)262143u)); - HANDLE_CODE(pack_integer(bref, meas_prs_offset, (uint8_t)0u, (uint8_t)39u)); + static const char* options[] = {"wideband", "widebandAndSubband"}; + return convert_enum_idx(options, 2, value, "codebook_params_s::type2_s_::amplitude_scaling_type_e_"); +} + +std::string codebook_params_s::type2_port_sel_s_::amplitude_scaling_type_opts::to_string() const +{ + static const char* options[] = {"wideband", "widebandAndSubband"}; + return convert_enum_idx(options, 2, value, "codebook_params_s::type2_port_sel_s_::amplitude_scaling_type_e_"); +} + +// DummyG ::= SEQUENCE +SRSASN_CODE dummy_g_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.pack(bref)); + HANDLE_CODE(max_num_ssb_csi_rs_res_two_tx.pack(bref)); + HANDLE_CODE(supported_csi_rs_density.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE eutra_rstd_info_s::unpack(cbit_ref& bref) +SRSASN_CODE dummy_g_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(carrier_freq, bref, (uint32_t)0u, (uint32_t)262143u)); - HANDLE_CODE(unpack_integer(meas_prs_offset, bref, (uint8_t)0u, (uint8_t)39u)); + HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.unpack(bref)); + HANDLE_CODE(max_num_ssb_csi_rs_res_two_tx.unpack(bref)); + HANDLE_CODE(supported_csi_rs_density.unpack(bref)); return SRSASN_SUCCESS; } -void eutra_rstd_info_s::to_json(json_writer& j) const +void dummy_g_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("carrierFreq", carrier_freq); - j.write_int("measPRS-Offset", meas_prs_offset); + j.write_str("maxNumberSSB-CSI-RS-ResourceOneTx", max_num_ssb_csi_rs_res_one_tx.to_string()); + j.write_str("maxNumberSSB-CSI-RS-ResourceTwoTx", max_num_ssb_csi_rs_res_two_tx.to_string()); + j.write_str("supportedCSI-RS-Density", supported_csi_rs_density.to_string()); j.end_obj(); } -// MIMO-LayersDL ::= ENUMERATED -std::string mimo_layers_dl_opts::to_string() const +std::string dummy_g_s::max_num_ssb_csi_rs_res_one_tx_opts::to_string() const { - static const char* options[] = {"twoLayers", "fourLayers", "eightLayers"}; - return convert_enum_idx(options, 3, value, "mimo_layers_dl_e"); + static const char* options[] = {"n8", "n16", "n32", "n64"}; + return convert_enum_idx(options, 4, value, "dummy_g_s::max_num_ssb_csi_rs_res_one_tx_e_"); } -uint8_t mimo_layers_dl_opts::to_number() const +uint8_t dummy_g_s::max_num_ssb_csi_rs_res_one_tx_opts::to_number() const { - static const uint8_t options[] = {2, 4, 8}; - return map_enum_number(options, 3, value, "mimo_layers_dl_e"); + static const uint8_t options[] = {8, 16, 32, 64}; + return map_enum_number(options, 4, value, "dummy_g_s::max_num_ssb_csi_rs_res_one_tx_e_"); } -// MIMO-LayersUL ::= ENUMERATED -std::string mimo_layers_ul_opts::to_string() const +std::string dummy_g_s::max_num_ssb_csi_rs_res_two_tx_opts::to_string() const { - static const char* options[] = {"oneLayer", "twoLayers", "fourLayers"}; - return convert_enum_idx(options, 3, value, "mimo_layers_ul_e"); + static const char* options[] = {"n0", "n4", "n8", "n16", "n32", "n64"}; + return convert_enum_idx(options, 6, value, "dummy_g_s::max_num_ssb_csi_rs_res_two_tx_e_"); } -uint8_t mimo_layers_ul_opts::to_number() const +uint8_t dummy_g_s::max_num_ssb_csi_rs_res_two_tx_opts::to_number() const { - static const uint8_t options[] = {1, 2, 4}; - return map_enum_number(options, 3, value, "mimo_layers_ul_e"); + static const uint8_t options[] = {0, 4, 8, 16, 32, 64}; + return map_enum_number(options, 6, value, "dummy_g_s::max_num_ssb_csi_rs_res_two_tx_e_"); } -// MeasResultEUTRA ::= SEQUENCE -SRSASN_CODE meas_result_eutra_s::pack(bit_ref& bref) const +std::string dummy_g_s::supported_csi_rs_density_opts::to_string() const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(cgi_info_present, 1)); + static const char* options[] = {"one", "three", "oneAndThree"}; + return convert_enum_idx(options, 3, value, "dummy_g_s::supported_csi_rs_density_e_"); +} - HANDLE_CODE(pack_integer(bref, eutra_pci, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(meas_result.pack(bref)); - if (cgi_info_present) { - HANDLE_CODE(bref.pack(cgi_info.cgi_info_epc_present, 1)); - HANDLE_CODE(bref.pack(cgi_info.cgi_info_minus5_gc_present, 1)); - HANDLE_CODE(bref.pack(cgi_info.multi_band_info_list_present, 1)); - HANDLE_CODE(bref.pack(cgi_info.freq_band_ind_prio_present, 1)); - if (cgi_info.cgi_info_epc_present) { - HANDLE_CODE(bref.pack(cgi_info.cgi_info_epc.cgi_info_epc_list_present, 1)); - HANDLE_CODE(cgi_info.cgi_info_epc.cgi_info_epc_legacy.pack(bref)); - if (cgi_info.cgi_info_epc.cgi_info_epc_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, cgi_info.cgi_info_epc.cgi_info_epc_list, 1, 12)); - } - } - if (cgi_info.cgi_info_minus5_gc_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, cgi_info.cgi_info_minus5_gc, 1, 12)); - } - HANDLE_CODE(pack_integer(bref, cgi_info.freq_band_ind, (uint16_t)1u, (uint16_t)256u)); - if (cgi_info.multi_band_info_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, cgi_info.multi_band_info_list, 1, 8, integer_packer(1, 256))); - } - } +// DummyH ::= SEQUENCE +SRSASN_CODE dummy_h_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, burst_len, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(pack_integer(bref, max_simul_res_sets_per_cc, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_per_cc, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_all_cc, (uint8_t)1u, (uint8_t)128u)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_result_eutra_s::unpack(cbit_ref& bref) +SRSASN_CODE dummy_h_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(cgi_info_present, 1)); - - HANDLE_CODE(unpack_integer(eutra_pci, bref, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(meas_result.unpack(bref)); - if (cgi_info_present) { - HANDLE_CODE(bref.unpack(cgi_info.cgi_info_epc_present, 1)); - HANDLE_CODE(bref.unpack(cgi_info.cgi_info_minus5_gc_present, 1)); - HANDLE_CODE(bref.unpack(cgi_info.multi_band_info_list_present, 1)); - HANDLE_CODE(bref.unpack(cgi_info.freq_band_ind_prio_present, 1)); - if (cgi_info.cgi_info_epc_present) { - HANDLE_CODE(bref.unpack(cgi_info.cgi_info_epc.cgi_info_epc_list_present, 1)); - HANDLE_CODE(cgi_info.cgi_info_epc.cgi_info_epc_legacy.unpack(bref)); - if (cgi_info.cgi_info_epc.cgi_info_epc_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(cgi_info.cgi_info_epc.cgi_info_epc_list, bref, 1, 12)); - } - } - if (cgi_info.cgi_info_minus5_gc_present) { - HANDLE_CODE(unpack_dyn_seq_of(cgi_info.cgi_info_minus5_gc, bref, 1, 12)); - } - HANDLE_CODE(unpack_integer(cgi_info.freq_band_ind, bref, (uint16_t)1u, (uint16_t)256u)); - if (cgi_info.multi_band_info_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(cgi_info.multi_band_info_list, bref, 1, 8, integer_packer(1, 256))); - } - } + HANDLE_CODE(unpack_integer(burst_len, bref, (uint8_t)1u, (uint8_t)2u)); + HANDLE_CODE(unpack_integer(max_simul_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); + HANDLE_CODE(unpack_integer(max_cfgured_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); + HANDLE_CODE(unpack_integer(max_cfgured_res_sets_all_cc, bref, (uint8_t)1u, (uint8_t)128u)); return SRSASN_SUCCESS; } -void meas_result_eutra_s::to_json(json_writer& j) const +void dummy_h_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("eutra-PhysCellId", eutra_pci); - j.write_fieldname("measResult"); - meas_result.to_json(j); - if (cgi_info_present) { - j.write_fieldname("cgi-Info"); - j.start_obj(); - if (cgi_info.cgi_info_epc_present) { - j.write_fieldname("cgi-info-EPC"); - j.start_obj(); - j.write_fieldname("cgi-info-EPC-legacy"); - cgi_info.cgi_info_epc.cgi_info_epc_legacy.to_json(j); - if (cgi_info.cgi_info_epc.cgi_info_epc_list_present) { - j.start_array("cgi-info-EPC-list"); - for (const auto& e1 : cgi_info.cgi_info_epc.cgi_info_epc_list) { - e1.to_json(j); - } - j.end_array(); - } - j.end_obj(); - } - if (cgi_info.cgi_info_minus5_gc_present) { - j.start_array("cgi-info-5GC"); - for (const auto& e1 : cgi_info.cgi_info_minus5_gc) { - e1.to_json(j); - } - j.end_array(); - } - j.write_int("freqBandIndicator", cgi_info.freq_band_ind); - if (cgi_info.multi_band_info_list_present) { - j.start_array("multiBandInfoList"); - for (const auto& e1 : cgi_info.multi_band_info_list) { - j.write_int(e1); - } - j.end_array(); - } - if (cgi_info.freq_band_ind_prio_present) { - j.write_str("freqBandIndicatorPriority", "true"); - } - j.end_obj(); - } + j.write_int("burstLength", burst_len); + j.write_int("maxSimultaneousResourceSetsPerCC", max_simul_res_sets_per_cc); + j.write_int("maxConfiguredResourceSetsPerCC", max_cfgured_res_sets_per_cc); + j.write_int("maxConfiguredResourceSetsAllCC", max_cfgured_res_sets_all_cc); j.end_obj(); } -// MeasResultServMO ::= SEQUENCE -SRSASN_CODE meas_result_serv_mo_s::pack(bit_ref& bref) const +// PTRS-DensityRecommendationDL ::= SEQUENCE +SRSASN_CODE ptrs_density_recommendation_dl_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(meas_result_best_neigh_cell_present, 1)); - - HANDLE_CODE(pack_integer(bref, serv_cell_id, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(meas_result_serving_cell.pack(bref)); - if (meas_result_best_neigh_cell_present) { - HANDLE_CODE(meas_result_best_neigh_cell.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, freq_density1, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, freq_density2, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, time_density1, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(pack_integer(bref, time_density2, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(pack_integer(bref, time_density3, (uint8_t)0u, (uint8_t)29u)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_result_serv_mo_s::unpack(cbit_ref& bref) +SRSASN_CODE ptrs_density_recommendation_dl_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(meas_result_best_neigh_cell_present, 1)); - - HANDLE_CODE(unpack_integer(serv_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(meas_result_serving_cell.unpack(bref)); - if (meas_result_best_neigh_cell_present) { - HANDLE_CODE(meas_result_best_neigh_cell.unpack(bref)); - } + HANDLE_CODE(unpack_integer(freq_density1, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(freq_density2, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(time_density1, bref, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(unpack_integer(time_density2, bref, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(unpack_integer(time_density3, bref, (uint8_t)0u, (uint8_t)29u)); return SRSASN_SUCCESS; } -void meas_result_serv_mo_s::to_json(json_writer& j) const +void ptrs_density_recommendation_dl_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("servCellId", serv_cell_id); - j.write_fieldname("measResultServingCell"); - meas_result_serving_cell.to_json(j); - if (meas_result_best_neigh_cell_present) { - j.write_fieldname("measResultBestNeighCell"); - meas_result_best_neigh_cell.to_json(j); - } + j.write_int("frequencyDensity1", freq_density1); + j.write_int("frequencyDensity2", freq_density2); + j.write_int("timeDensity1", time_density1); + j.write_int("timeDensity2", time_density2); + j.write_int("timeDensity3", time_density3); j.end_obj(); } -// ReducedAggregatedBandwidth ::= ENUMERATED -std::string reduced_aggregated_bw_opts::to_string() const +// PTRS-DensityRecommendationUL ::= SEQUENCE +SRSASN_CODE ptrs_density_recommendation_ul_s::pack(bit_ref& bref) const { - static const char* options[] = { - "mhz0", "mhz10", "mhz20", "mhz30", "mhz40", "mhz50", "mhz60", "mhz80", "mhz100", "mhz200", "mhz300", "mhz400"}; - return convert_enum_idx(options, 12, value, "reduced_aggregated_bw_e"); + HANDLE_CODE(pack_integer(bref, freq_density1, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, freq_density2, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, time_density1, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(pack_integer(bref, time_density2, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(pack_integer(bref, time_density3, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(pack_integer(bref, sample_density1, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, sample_density2, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, sample_density3, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, sample_density4, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(pack_integer(bref, sample_density5, (uint16_t)1u, (uint16_t)276u)); + + return SRSASN_SUCCESS; } -uint16_t reduced_aggregated_bw_opts::to_number() const +SRSASN_CODE ptrs_density_recommendation_ul_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {0, 10, 20, 30, 40, 50, 60, 80, 100, 200, 300, 400}; - return map_enum_number(options, 12, value, "reduced_aggregated_bw_e"); + HANDLE_CODE(unpack_integer(freq_density1, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(freq_density2, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(time_density1, bref, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(unpack_integer(time_density2, bref, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(unpack_integer(time_density3, bref, (uint8_t)0u, (uint8_t)29u)); + HANDLE_CODE(unpack_integer(sample_density1, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(sample_density2, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(sample_density3, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(sample_density4, bref, (uint16_t)1u, (uint16_t)276u)); + HANDLE_CODE(unpack_integer(sample_density5, bref, (uint16_t)1u, (uint16_t)276u)); + + return SRSASN_SUCCESS; +} +void ptrs_density_recommendation_ul_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("frequencyDensity1", freq_density1); + j.write_int("frequencyDensity2", freq_density2); + j.write_int("timeDensity1", time_density1); + j.write_int("timeDensity2", time_density2); + j.write_int("timeDensity3", time_density3); + j.write_int("sampleDensity1", sample_density1); + j.write_int("sampleDensity2", sample_density2); + j.write_int("sampleDensity3", sample_density3); + j.write_int("sampleDensity4", sample_density4); + j.write_int("sampleDensity5", sample_density5); + j.end_obj(); } -// UplinkTxDirectCurrentCell ::= SEQUENCE -SRSASN_CODE ul_tx_direct_current_cell_s::pack(bit_ref& bref) const +// SpatialRelations ::= SEQUENCE +SRSASN_CODE spatial_relations_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(pack_integer(bref, serv_cell_idx, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(pack_dyn_seq_of(bref, ul_direct_current_bwp, 1, 4)); + HANDLE_CODE(bref.pack(add_active_spatial_relation_pucch_present, 1)); + + HANDLE_CODE(max_num_cfgured_spatial_relations.pack(bref)); + HANDLE_CODE(max_num_active_spatial_relations.pack(bref)); + HANDLE_CODE(max_num_dl_rs_qcl_type_d.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ul_tx_direct_current_cell_s::unpack(cbit_ref& bref) +SRSASN_CODE spatial_relations_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_integer(serv_cell_idx, bref, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(unpack_dyn_seq_of(ul_direct_current_bwp, bref, 1, 4)); + HANDLE_CODE(bref.unpack(add_active_spatial_relation_pucch_present, 1)); + + HANDLE_CODE(max_num_cfgured_spatial_relations.unpack(bref)); + HANDLE_CODE(max_num_active_spatial_relations.unpack(bref)); + HANDLE_CODE(max_num_dl_rs_qcl_type_d.unpack(bref)); return SRSASN_SUCCESS; } -void ul_tx_direct_current_cell_s::to_json(json_writer& j) const +void spatial_relations_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("servCellIndex", serv_cell_idx); - j.start_array("uplinkDirectCurrentBWP"); - for (const auto& e1 : ul_direct_current_bwp) { - e1.to_json(j); + j.write_str("maxNumberConfiguredSpatialRelations", max_num_cfgured_spatial_relations.to_string()); + j.write_str("maxNumberActiveSpatialRelations", max_num_active_spatial_relations.to_string()); + if (add_active_spatial_relation_pucch_present) { + j.write_str("additionalActiveSpatialRelationPUCCH", "supported"); } - j.end_array(); + j.write_str("maxNumberDL-RS-QCL-TypeD", max_num_dl_rs_qcl_type_d.to_string()); j.end_obj(); } -// DRB-CountInfo ::= SEQUENCE -SRSASN_CODE drb_count_info_s::pack(bit_ref& bref) const +std::string spatial_relations_s::max_num_cfgured_spatial_relations_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, drb_id, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(pack_integer(bref, count_ul, (uint64_t)0u, (uint64_t)4294967295u)); - HANDLE_CODE(pack_integer(bref, count_dl, (uint64_t)0u, (uint64_t)4294967295u)); + static const char* options[] = {"n4", "n8", "n16", "n32", "n64", "n96"}; + return convert_enum_idx(options, 6, value, "spatial_relations_s::max_num_cfgured_spatial_relations_e_"); +} +uint8_t spatial_relations_s::max_num_cfgured_spatial_relations_opts::to_number() const +{ + static const uint8_t options[] = {4, 8, 16, 32, 64, 96}; + return map_enum_number(options, 6, value, "spatial_relations_s::max_num_cfgured_spatial_relations_e_"); +} - return SRSASN_SUCCESS; +std::string spatial_relations_s::max_num_active_spatial_relations_opts::to_string() const +{ + static const char* options[] = {"n1", "n2", "n4", "n8", "n14"}; + return convert_enum_idx(options, 5, value, "spatial_relations_s::max_num_active_spatial_relations_e_"); } -SRSASN_CODE drb_count_info_s::unpack(cbit_ref& bref) +uint8_t spatial_relations_s::max_num_active_spatial_relations_opts::to_number() const { - HANDLE_CODE(unpack_integer(drb_id, bref, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(unpack_integer(count_ul, bref, (uint64_t)0u, (uint64_t)4294967295u)); - HANDLE_CODE(unpack_integer(count_dl, bref, (uint64_t)0u, (uint64_t)4294967295u)); + static const uint8_t options[] = {1, 2, 4, 8, 14}; + return map_enum_number(options, 5, value, "spatial_relations_s::max_num_active_spatial_relations_e_"); +} - return SRSASN_SUCCESS; +std::string spatial_relations_s::max_num_dl_rs_qcl_type_d_opts::to_string() const +{ + static const char* options[] = {"n1", "n2", "n4", "n8", "n14"}; + return convert_enum_idx(options, 5, value, "spatial_relations_s::max_num_dl_rs_qcl_type_d_e_"); } -void drb_count_info_s::to_json(json_writer& j) const +uint8_t spatial_relations_s::max_num_dl_rs_qcl_type_d_opts::to_number() const { - j.start_obj(); - j.write_int("drb-Identity", drb_id); - j.write_int("count-Uplink", count_ul); - j.write_int("count-Downlink", count_dl); - j.end_obj(); + static const uint8_t options[] = {1, 2, 4, 8, 14}; + return map_enum_number(options, 5, value, "spatial_relations_s::max_num_dl_rs_qcl_type_d_e_"); } -// OverheatingAssistance ::= SEQUENCE -SRSASN_CODE overheat_assist_s::pack(bit_ref& bref) const +// MIMO-ParametersPerBand ::= SEQUENCE +SRSASN_CODE mimo_params_per_band_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(reduced_max_ccs_present, 1)); - HANDLE_CODE(bref.pack(reduced_max_bw_fr1_present, 1)); - HANDLE_CODE(bref.pack(reduced_max_bw_fr2_present, 1)); - HANDLE_CODE(bref.pack(reduced_max_mimo_layers_fr1_present, 1)); - HANDLE_CODE(bref.pack(reduced_max_mimo_layers_fr2_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(tci_state_pdsch_present, 1)); + HANDLE_CODE(bref.pack(add_active_tci_state_pdcch_present, 1)); + HANDLE_CODE(bref.pack(pusch_trans_coherence_present, 1)); + HANDLE_CODE(bref.pack(beam_correspondence_without_ul_beam_sweeping_present, 1)); + HANDLE_CODE(bref.pack(periodic_beam_report_present, 1)); + HANDLE_CODE(bref.pack(aperiodic_beam_report_present, 1)); + HANDLE_CODE(bref.pack(sp_beam_report_pucch_present, 1)); + HANDLE_CODE(bref.pack(sp_beam_report_pusch_present, 1)); + HANDLE_CODE(bref.pack(dummy1_present, 1)); + HANDLE_CODE(bref.pack(max_num_rx_beam_present, 1)); + HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl_present, 1)); + HANDLE_CODE(bref.pack(max_num_non_group_beam_report_present, 1)); + HANDLE_CODE(bref.pack(group_beam_report_present, 1)); + HANDLE_CODE(bref.pack(ul_beam_management_present, 1)); + HANDLE_CODE(bref.pack(max_num_csi_rs_bfd_present, 1)); + HANDLE_CODE(bref.pack(max_num_ssb_bfd_present, 1)); + HANDLE_CODE(bref.pack(max_num_csi_rs_ssb_cbd_present, 1)); + HANDLE_CODE(bref.pack(dummy2_present, 1)); + HANDLE_CODE(bref.pack(two_ports_ptrs_ul_present, 1)); + HANDLE_CODE(bref.pack(dummy5_present, 1)); + HANDLE_CODE(bref.pack(dummy3_present, 1)); + HANDLE_CODE(bref.pack(beam_report_timing_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul_present, 1)); + HANDLE_CODE(bref.pack(dummy4_present, 1)); + HANDLE_CODE(bref.pack(aperiodic_trs_present, 1)); - if (reduced_max_ccs_present) { - HANDLE_CODE(pack_integer(bref, reduced_max_ccs.reduced_ccs_dl, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(pack_integer(bref, reduced_max_ccs.reduced_ccs_ul, (uint8_t)0u, (uint8_t)31u)); - } - if (reduced_max_bw_fr1_present) { - HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_dl.pack(bref)); - HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_ul.pack(bref)); + if (tci_state_pdsch_present) { + HANDLE_CODE(bref.pack(tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present, 1)); + HANDLE_CODE(bref.pack(tci_state_pdsch.max_num_active_tci_per_bwp_present, 1)); + if (tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present) { + HANDLE_CODE(tci_state_pdsch.max_num_cfgured_tcistates_per_cc.pack(bref)); + } + if (tci_state_pdsch.max_num_active_tci_per_bwp_present) { + HANDLE_CODE(tci_state_pdsch.max_num_active_tci_per_bwp.pack(bref)); + } } - if (reduced_max_bw_fr2_present) { - HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_dl.pack(bref)); - HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_ul.pack(bref)); + if (pusch_trans_coherence_present) { + HANDLE_CODE(pusch_trans_coherence.pack(bref)); } - if (reduced_max_mimo_layers_fr1_present) { - HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_dl.pack(bref)); - HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_ul.pack(bref)); + if (dummy1_present) { + HANDLE_CODE(dummy1.pack(bref)); } - if (reduced_max_mimo_layers_fr2_present) { - HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_dl.pack(bref)); - HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_ul.pack(bref)); + if (max_num_rx_beam_present) { + HANDLE_CODE(pack_integer(bref, max_num_rx_beam, (uint8_t)2u, (uint8_t)8u)); } - - return SRSASN_SUCCESS; -} -SRSASN_CODE overheat_assist_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(reduced_max_ccs_present, 1)); - HANDLE_CODE(bref.unpack(reduced_max_bw_fr1_present, 1)); - HANDLE_CODE(bref.unpack(reduced_max_bw_fr2_present, 1)); - HANDLE_CODE(bref.unpack(reduced_max_mimo_layers_fr1_present, 1)); - HANDLE_CODE(bref.unpack(reduced_max_mimo_layers_fr2_present, 1)); - - if (reduced_max_ccs_present) { - HANDLE_CODE(unpack_integer(reduced_max_ccs.reduced_ccs_dl, bref, (uint8_t)0u, (uint8_t)31u)); - HANDLE_CODE(unpack_integer(reduced_max_ccs.reduced_ccs_ul, bref, (uint8_t)0u, (uint8_t)31u)); + if (max_num_rx_tx_beam_switch_dl_present) { + HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present, 1)); + HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present, 1)); + if (max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz.pack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz.pack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz.pack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz.pack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz.pack(bref)); + } } - if (reduced_max_bw_fr1_present) { - HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_dl.unpack(bref)); - HANDLE_CODE(reduced_max_bw_fr1.reduced_bw_fr1_ul.unpack(bref)); + if (max_num_non_group_beam_report_present) { + HANDLE_CODE(max_num_non_group_beam_report.pack(bref)); } - if (reduced_max_bw_fr2_present) { - HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_dl.unpack(bref)); - HANDLE_CODE(reduced_max_bw_fr2.reduced_bw_fr2_ul.unpack(bref)); + if (ul_beam_management_present) { + HANDLE_CODE(ul_beam_management.max_num_srs_res_per_set_bm.pack(bref)); + HANDLE_CODE(pack_integer(bref, ul_beam_management.max_num_srs_res_set, (uint8_t)1u, (uint8_t)8u)); } - if (reduced_max_mimo_layers_fr1_present) { - HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_dl.unpack(bref)); - HANDLE_CODE(reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_ul.unpack(bref)); + if (max_num_csi_rs_bfd_present) { + HANDLE_CODE(pack_integer(bref, max_num_csi_rs_bfd, (uint8_t)1u, (uint8_t)64u)); } - if (reduced_max_mimo_layers_fr2_present) { - HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_dl.unpack(bref)); - HANDLE_CODE(reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_ul.unpack(bref)); + if (max_num_ssb_bfd_present) { + HANDLE_CODE(pack_integer(bref, max_num_ssb_bfd, (uint8_t)1u, (uint8_t)64u)); } - - return SRSASN_SUCCESS; -} -void overheat_assist_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (reduced_max_ccs_present) { - j.write_fieldname("reducedMaxCCs"); - j.start_obj(); - j.write_int("reducedCCsDL", reduced_max_ccs.reduced_ccs_dl); - j.write_int("reducedCCsUL", reduced_max_ccs.reduced_ccs_ul); - j.end_obj(); + if (max_num_csi_rs_ssb_cbd_present) { + HANDLE_CODE(pack_integer(bref, max_num_csi_rs_ssb_cbd, (uint16_t)1u, (uint16_t)256u)); } - if (reduced_max_bw_fr1_present) { - j.write_fieldname("reducedMaxBW-FR1"); - j.start_obj(); - j.write_str("reducedBW-FR1-DL", reduced_max_bw_fr1.reduced_bw_fr1_dl.to_string()); - j.write_str("reducedBW-FR1-UL", reduced_max_bw_fr1.reduced_bw_fr1_ul.to_string()); - j.end_obj(); + if (dummy5_present) { + HANDLE_CODE(dummy5.pack(bref)); } - if (reduced_max_bw_fr2_present) { - j.write_fieldname("reducedMaxBW-FR2"); - j.start_obj(); - j.write_str("reducedBW-FR2-DL", reduced_max_bw_fr2.reduced_bw_fr2_dl.to_string()); - j.write_str("reducedBW-FR2-UL", reduced_max_bw_fr2.reduced_bw_fr2_ul.to_string()); - j.end_obj(); + if (dummy3_present) { + HANDLE_CODE(pack_integer(bref, dummy3, (uint8_t)1u, (uint8_t)4u)); } - if (reduced_max_mimo_layers_fr1_present) { - j.write_fieldname("reducedMaxMIMO-LayersFR1"); - j.start_obj(); - j.write_str("reducedMIMO-LayersFR1-DL", reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_dl.to_string()); - j.write_str("reducedMIMO-LayersFR1-UL", reduced_max_mimo_layers_fr1.reduced_mimo_layers_fr1_ul.to_string()); - j.end_obj(); + if (beam_report_timing_present) { + HANDLE_CODE(bref.pack(beam_report_timing.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(beam_report_timing.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(beam_report_timing.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(beam_report_timing.scs_minus120k_hz_present, 1)); + if (beam_report_timing.scs_minus15k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus15k_hz.pack(bref)); + } + if (beam_report_timing.scs_minus30k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus30k_hz.pack(bref)); + } + if (beam_report_timing.scs_minus60k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus60k_hz.pack(bref)); + } + if (beam_report_timing.scs_minus120k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus120k_hz.pack(bref)); + } } - if (reduced_max_mimo_layers_fr2_present) { - j.write_fieldname("reducedMaxMIMO-LayersFR2"); - j.start_obj(); - j.write_str("reducedMIMO-LayersFR2-DL", reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_dl.to_string()); - j.write_str("reducedMIMO-LayersFR2-UL", reduced_max_mimo_layers_fr2.reduced_mimo_layers_fr2_ul.to_string()); - j.end_obj(); + if (ptrs_density_recommendation_set_dl_present) { + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus120k_hz_present, 1)); + if (ptrs_density_recommendation_set_dl.scs_minus15k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus15k_hz.pack(bref)); + } + if (ptrs_density_recommendation_set_dl.scs_minus30k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus30k_hz.pack(bref)); + } + if (ptrs_density_recommendation_set_dl.scs_minus60k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus60k_hz.pack(bref)); + } + if (ptrs_density_recommendation_set_dl.scs_minus120k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus120k_hz.pack(bref)); + } + } + if (ptrs_density_recommendation_set_ul_present) { + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus120k_hz_present, 1)); + if (ptrs_density_recommendation_set_ul.scs_minus15k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus15k_hz.pack(bref)); + } + if (ptrs_density_recommendation_set_ul.scs_minus30k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus30k_hz.pack(bref)); + } + if (ptrs_density_recommendation_set_ul.scs_minus60k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus60k_hz.pack(bref)); + } + if (ptrs_density_recommendation_set_ul.scs_minus120k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus120k_hz.pack(bref)); + } + } + if (dummy4_present) { + HANDLE_CODE(dummy4.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= dummy6_present; + group_flags[0] |= beam_management_ssb_csi_rs.is_present(); + group_flags[0] |= beam_switch_timing.is_present(); + group_flags[0] |= codebook_params.is_present(); + group_flags[0] |= csi_rs_im_reception_for_feedback.is_present(); + group_flags[0] |= csi_rs_proc_framework_for_srs.is_present(); + group_flags[0] |= csi_report_framework.is_present(); + group_flags[0] |= csi_rs_for_tracking.is_present(); + group_flags[0] |= srs_assoc_csi_rs.is_present(); + group_flags[0] |= spatial_relations.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(dummy6_present, 1)); + HANDLE_CODE(bref.pack(beam_management_ssb_csi_rs.is_present(), 1)); + HANDLE_CODE(bref.pack(beam_switch_timing.is_present(), 1)); + HANDLE_CODE(bref.pack(codebook_params.is_present(), 1)); + HANDLE_CODE(bref.pack(csi_rs_im_reception_for_feedback.is_present(), 1)); + HANDLE_CODE(bref.pack(csi_rs_proc_framework_for_srs.is_present(), 1)); + HANDLE_CODE(bref.pack(csi_report_framework.is_present(), 1)); + HANDLE_CODE(bref.pack(csi_rs_for_tracking.is_present(), 1)); + HANDLE_CODE(bref.pack(srs_assoc_csi_rs.is_present(), 1)); + HANDLE_CODE(bref.pack(spatial_relations.is_present(), 1)); + if (beam_management_ssb_csi_rs.is_present()) { + HANDLE_CODE(beam_management_ssb_csi_rs->pack(bref)); + } + if (beam_switch_timing.is_present()) { + HANDLE_CODE(bref.pack(beam_switch_timing->scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(beam_switch_timing->scs_minus120k_hz_present, 1)); + if (beam_switch_timing->scs_minus60k_hz_present) { + HANDLE_CODE(beam_switch_timing->scs_minus60k_hz.pack(bref)); + } + if (beam_switch_timing->scs_minus120k_hz_present) { + HANDLE_CODE(beam_switch_timing->scs_minus120k_hz.pack(bref)); + } + } + if (codebook_params.is_present()) { + HANDLE_CODE(codebook_params->pack(bref)); + } + if (csi_rs_im_reception_for_feedback.is_present()) { + HANDLE_CODE(csi_rs_im_reception_for_feedback->pack(bref)); + } + if (csi_rs_proc_framework_for_srs.is_present()) { + HANDLE_CODE(csi_rs_proc_framework_for_srs->pack(bref)); + } + if (csi_report_framework.is_present()) { + HANDLE_CODE(csi_report_framework->pack(bref)); + } + if (csi_rs_for_tracking.is_present()) { + HANDLE_CODE(csi_rs_for_tracking->pack(bref)); + } + if (srs_assoc_csi_rs.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *srs_assoc_csi_rs, 1, 7)); + } + if (spatial_relations.is_present()) { + HANDLE_CODE(spatial_relations->pack(bref)); + } + } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE mimo_params_per_band_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(tci_state_pdsch_present, 1)); + HANDLE_CODE(bref.unpack(add_active_tci_state_pdcch_present, 1)); + HANDLE_CODE(bref.unpack(pusch_trans_coherence_present, 1)); + HANDLE_CODE(bref.unpack(beam_correspondence_without_ul_beam_sweeping_present, 1)); + HANDLE_CODE(bref.unpack(periodic_beam_report_present, 1)); + HANDLE_CODE(bref.unpack(aperiodic_beam_report_present, 1)); + HANDLE_CODE(bref.unpack(sp_beam_report_pucch_present, 1)); + HANDLE_CODE(bref.unpack(sp_beam_report_pusch_present, 1)); + HANDLE_CODE(bref.unpack(dummy1_present, 1)); + HANDLE_CODE(bref.unpack(max_num_rx_beam_present, 1)); + HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl_present, 1)); + HANDLE_CODE(bref.unpack(max_num_non_group_beam_report_present, 1)); + HANDLE_CODE(bref.unpack(group_beam_report_present, 1)); + HANDLE_CODE(bref.unpack(ul_beam_management_present, 1)); + HANDLE_CODE(bref.unpack(max_num_csi_rs_bfd_present, 1)); + HANDLE_CODE(bref.unpack(max_num_ssb_bfd_present, 1)); + HANDLE_CODE(bref.unpack(max_num_csi_rs_ssb_cbd_present, 1)); + HANDLE_CODE(bref.unpack(dummy2_present, 1)); + HANDLE_CODE(bref.unpack(two_ports_ptrs_ul_present, 1)); + HANDLE_CODE(bref.unpack(dummy5_present, 1)); + HANDLE_CODE(bref.unpack(dummy3_present, 1)); + HANDLE_CODE(bref.unpack(beam_report_timing_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul_present, 1)); + HANDLE_CODE(bref.unpack(dummy4_present, 1)); + HANDLE_CODE(bref.unpack(aperiodic_trs_present, 1)); + + if (tci_state_pdsch_present) { + HANDLE_CODE(bref.unpack(tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present, 1)); + HANDLE_CODE(bref.unpack(tci_state_pdsch.max_num_active_tci_per_bwp_present, 1)); + if (tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present) { + HANDLE_CODE(tci_state_pdsch.max_num_cfgured_tcistates_per_cc.unpack(bref)); + } + if (tci_state_pdsch.max_num_active_tci_per_bwp_present) { + HANDLE_CODE(tci_state_pdsch.max_num_active_tci_per_bwp.unpack(bref)); + } + } + if (pusch_trans_coherence_present) { + HANDLE_CODE(pusch_trans_coherence.unpack(bref)); + } + if (dummy1_present) { + HANDLE_CODE(dummy1.unpack(bref)); + } + if (max_num_rx_beam_present) { + HANDLE_CODE(unpack_integer(max_num_rx_beam, bref, (uint8_t)2u, (uint8_t)8u)); + } + if (max_num_rx_tx_beam_switch_dl_present) { + HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present, 1)); + HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present, 1)); + if (max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz.unpack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz.unpack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz.unpack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz.unpack(bref)); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present) { + HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz.unpack(bref)); + } + } + if (max_num_non_group_beam_report_present) { + HANDLE_CODE(max_num_non_group_beam_report.unpack(bref)); + } + if (ul_beam_management_present) { + HANDLE_CODE(ul_beam_management.max_num_srs_res_per_set_bm.unpack(bref)); + HANDLE_CODE(unpack_integer(ul_beam_management.max_num_srs_res_set, bref, (uint8_t)1u, (uint8_t)8u)); + } + if (max_num_csi_rs_bfd_present) { + HANDLE_CODE(unpack_integer(max_num_csi_rs_bfd, bref, (uint8_t)1u, (uint8_t)64u)); + } + if (max_num_ssb_bfd_present) { + HANDLE_CODE(unpack_integer(max_num_ssb_bfd, bref, (uint8_t)1u, (uint8_t)64u)); + } + if (max_num_csi_rs_ssb_cbd_present) { + HANDLE_CODE(unpack_integer(max_num_csi_rs_ssb_cbd, bref, (uint16_t)1u, (uint16_t)256u)); + } + if (dummy5_present) { + HANDLE_CODE(dummy5.unpack(bref)); + } + if (dummy3_present) { + HANDLE_CODE(unpack_integer(dummy3, bref, (uint8_t)1u, (uint8_t)4u)); + } + if (beam_report_timing_present) { + HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus120k_hz_present, 1)); + if (beam_report_timing.scs_minus15k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus15k_hz.unpack(bref)); + } + if (beam_report_timing.scs_minus30k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus30k_hz.unpack(bref)); + } + if (beam_report_timing.scs_minus60k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus60k_hz.unpack(bref)); + } + if (beam_report_timing.scs_minus120k_hz_present) { + HANDLE_CODE(beam_report_timing.scs_minus120k_hz.unpack(bref)); + } + } + if (ptrs_density_recommendation_set_dl_present) { + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus120k_hz_present, 1)); + if (ptrs_density_recommendation_set_dl.scs_minus15k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus15k_hz.unpack(bref)); + } + if (ptrs_density_recommendation_set_dl.scs_minus30k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus30k_hz.unpack(bref)); + } + if (ptrs_density_recommendation_set_dl.scs_minus60k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus60k_hz.unpack(bref)); + } + if (ptrs_density_recommendation_set_dl.scs_minus120k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus120k_hz.unpack(bref)); + } + } + if (ptrs_density_recommendation_set_ul_present) { + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus120k_hz_present, 1)); + if (ptrs_density_recommendation_set_ul.scs_minus15k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus15k_hz.unpack(bref)); + } + if (ptrs_density_recommendation_set_ul.scs_minus30k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus30k_hz.unpack(bref)); + } + if (ptrs_density_recommendation_set_ul.scs_minus60k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus60k_hz.unpack(bref)); + } + if (ptrs_density_recommendation_set_ul.scs_minus120k_hz_present) { + HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus120k_hz.unpack(bref)); + } + } + if (dummy4_present) { + HANDLE_CODE(dummy4.unpack(bref)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(dummy6_present, 1)); + bool beam_management_ssb_csi_rs_present; + HANDLE_CODE(bref.unpack(beam_management_ssb_csi_rs_present, 1)); + beam_management_ssb_csi_rs.set_present(beam_management_ssb_csi_rs_present); + bool beam_switch_timing_present; + HANDLE_CODE(bref.unpack(beam_switch_timing_present, 1)); + beam_switch_timing.set_present(beam_switch_timing_present); + bool codebook_params_present; + HANDLE_CODE(bref.unpack(codebook_params_present, 1)); + codebook_params.set_present(codebook_params_present); + bool csi_rs_im_reception_for_feedback_present; + HANDLE_CODE(bref.unpack(csi_rs_im_reception_for_feedback_present, 1)); + csi_rs_im_reception_for_feedback.set_present(csi_rs_im_reception_for_feedback_present); + bool csi_rs_proc_framework_for_srs_present; + HANDLE_CODE(bref.unpack(csi_rs_proc_framework_for_srs_present, 1)); + csi_rs_proc_framework_for_srs.set_present(csi_rs_proc_framework_for_srs_present); + bool csi_report_framework_present; + HANDLE_CODE(bref.unpack(csi_report_framework_present, 1)); + csi_report_framework.set_present(csi_report_framework_present); + bool csi_rs_for_tracking_present; + HANDLE_CODE(bref.unpack(csi_rs_for_tracking_present, 1)); + csi_rs_for_tracking.set_present(csi_rs_for_tracking_present); + bool srs_assoc_csi_rs_present; + HANDLE_CODE(bref.unpack(srs_assoc_csi_rs_present, 1)); + srs_assoc_csi_rs.set_present(srs_assoc_csi_rs_present); + bool spatial_relations_present; + HANDLE_CODE(bref.unpack(spatial_relations_present, 1)); + spatial_relations.set_present(spatial_relations_present); + if (beam_management_ssb_csi_rs.is_present()) { + HANDLE_CODE(beam_management_ssb_csi_rs->unpack(bref)); + } + if (beam_switch_timing.is_present()) { + HANDLE_CODE(bref.unpack(beam_switch_timing->scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(beam_switch_timing->scs_minus120k_hz_present, 1)); + if (beam_switch_timing->scs_minus60k_hz_present) { + HANDLE_CODE(beam_switch_timing->scs_minus60k_hz.unpack(bref)); + } + if (beam_switch_timing->scs_minus120k_hz_present) { + HANDLE_CODE(beam_switch_timing->scs_minus120k_hz.unpack(bref)); + } + } + if (codebook_params.is_present()) { + HANDLE_CODE(codebook_params->unpack(bref)); + } + if (csi_rs_im_reception_for_feedback.is_present()) { + HANDLE_CODE(csi_rs_im_reception_for_feedback->unpack(bref)); + } + if (csi_rs_proc_framework_for_srs.is_present()) { + HANDLE_CODE(csi_rs_proc_framework_for_srs->unpack(bref)); + } + if (csi_report_framework.is_present()) { + HANDLE_CODE(csi_report_framework->unpack(bref)); + } + if (csi_rs_for_tracking.is_present()) { + HANDLE_CODE(csi_rs_for_tracking->unpack(bref)); + } + if (srs_assoc_csi_rs.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*srs_assoc_csi_rs, bref, 1, 7)); + } + if (spatial_relations.is_present()) { + HANDLE_CODE(spatial_relations->unpack(bref)); + } + } + } + return SRSASN_SUCCESS; +} +void mimo_params_per_band_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (tci_state_pdsch_present) { + j.write_fieldname("tci-StatePDSCH"); + j.start_obj(); + if (tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present) { + j.write_str("maxNumberConfiguredTCIstatesPerCC", tci_state_pdsch.max_num_cfgured_tcistates_per_cc.to_string()); + } + if (tci_state_pdsch.max_num_active_tci_per_bwp_present) { + j.write_str("maxNumberActiveTCI-PerBWP", tci_state_pdsch.max_num_active_tci_per_bwp.to_string()); + } + j.end_obj(); + } + if (add_active_tci_state_pdcch_present) { + j.write_str("additionalActiveTCI-StatePDCCH", "supported"); + } + if (pusch_trans_coherence_present) { + j.write_str("pusch-TransCoherence", pusch_trans_coherence.to_string()); + } + if (beam_correspondence_without_ul_beam_sweeping_present) { + j.write_str("beamCorrespondenceWithoutUL-BeamSweeping", "supported"); + } + if (periodic_beam_report_present) { + j.write_str("periodicBeamReport", "supported"); + } + if (aperiodic_beam_report_present) { + j.write_str("aperiodicBeamReport", "supported"); + } + if (sp_beam_report_pucch_present) { + j.write_str("sp-BeamReportPUCCH", "supported"); + } + if (sp_beam_report_pusch_present) { + j.write_str("sp-BeamReportPUSCH", "supported"); + } + if (dummy1_present) { + j.write_fieldname("dummy1"); + dummy1.to_json(j); + } + if (max_num_rx_beam_present) { + j.write_int("maxNumberRxBeam", max_num_rx_beam); + } + if (max_num_rx_tx_beam_switch_dl_present) { + j.write_fieldname("maxNumberRxTxBeamSwitchDL"); + j.start_obj(); + if (max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present) { + j.write_str("scs-15kHz", max_num_rx_tx_beam_switch_dl.scs_minus15k_hz.to_string()); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present) { + j.write_str("scs-30kHz", max_num_rx_tx_beam_switch_dl.scs_minus30k_hz.to_string()); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present) { + j.write_str("scs-60kHz", max_num_rx_tx_beam_switch_dl.scs_minus60k_hz.to_string()); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present) { + j.write_str("scs-120kHz", max_num_rx_tx_beam_switch_dl.scs_minus120k_hz.to_string()); + } + if (max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present) { + j.write_str("scs-240kHz", max_num_rx_tx_beam_switch_dl.scs_minus240k_hz.to_string()); + } + j.end_obj(); + } + if (max_num_non_group_beam_report_present) { + j.write_str("maxNumberNonGroupBeamReporting", max_num_non_group_beam_report.to_string()); + } + if (group_beam_report_present) { + j.write_str("groupBeamReporting", "supported"); + } + if (ul_beam_management_present) { + j.write_fieldname("uplinkBeamManagement"); + j.start_obj(); + j.write_str("maxNumberSRS-ResourcePerSet-BM", ul_beam_management.max_num_srs_res_per_set_bm.to_string()); + j.write_int("maxNumberSRS-ResourceSet", ul_beam_management.max_num_srs_res_set); + j.end_obj(); + } + if (max_num_csi_rs_bfd_present) { + j.write_int("maxNumberCSI-RS-BFD", max_num_csi_rs_bfd); + } + if (max_num_ssb_bfd_present) { + j.write_int("maxNumberSSB-BFD", max_num_ssb_bfd); + } + if (max_num_csi_rs_ssb_cbd_present) { + j.write_int("maxNumberCSI-RS-SSB-CBD", max_num_csi_rs_ssb_cbd); + } + if (dummy2_present) { + j.write_str("dummy2", "supported"); + } + if (two_ports_ptrs_ul_present) { + j.write_str("twoPortsPTRS-UL", "supported"); + } + if (dummy5_present) { + j.write_fieldname("dummy5"); + dummy5.to_json(j); + } + if (dummy3_present) { + j.write_int("dummy3", dummy3); + } + if (beam_report_timing_present) { + j.write_fieldname("beamReportTiming"); + j.start_obj(); + if (beam_report_timing.scs_minus15k_hz_present) { + j.write_str("scs-15kHz", beam_report_timing.scs_minus15k_hz.to_string()); + } + if (beam_report_timing.scs_minus30k_hz_present) { + j.write_str("scs-30kHz", beam_report_timing.scs_minus30k_hz.to_string()); + } + if (beam_report_timing.scs_minus60k_hz_present) { + j.write_str("scs-60kHz", beam_report_timing.scs_minus60k_hz.to_string()); + } + if (beam_report_timing.scs_minus120k_hz_present) { + j.write_str("scs-120kHz", beam_report_timing.scs_minus120k_hz.to_string()); + } + j.end_obj(); + } + if (ptrs_density_recommendation_set_dl_present) { + j.write_fieldname("ptrs-DensityRecommendationSetDL"); + j.start_obj(); + if (ptrs_density_recommendation_set_dl.scs_minus15k_hz_present) { + j.write_fieldname("scs-15kHz"); + ptrs_density_recommendation_set_dl.scs_minus15k_hz.to_json(j); + } + if (ptrs_density_recommendation_set_dl.scs_minus30k_hz_present) { + j.write_fieldname("scs-30kHz"); + ptrs_density_recommendation_set_dl.scs_minus30k_hz.to_json(j); + } + if (ptrs_density_recommendation_set_dl.scs_minus60k_hz_present) { + j.write_fieldname("scs-60kHz"); + ptrs_density_recommendation_set_dl.scs_minus60k_hz.to_json(j); + } + if (ptrs_density_recommendation_set_dl.scs_minus120k_hz_present) { + j.write_fieldname("scs-120kHz"); + ptrs_density_recommendation_set_dl.scs_minus120k_hz.to_json(j); + } + j.end_obj(); + } + if (ptrs_density_recommendation_set_ul_present) { + j.write_fieldname("ptrs-DensityRecommendationSetUL"); + j.start_obj(); + if (ptrs_density_recommendation_set_ul.scs_minus15k_hz_present) { + j.write_fieldname("scs-15kHz"); + ptrs_density_recommendation_set_ul.scs_minus15k_hz.to_json(j); + } + if (ptrs_density_recommendation_set_ul.scs_minus30k_hz_present) { + j.write_fieldname("scs-30kHz"); + ptrs_density_recommendation_set_ul.scs_minus30k_hz.to_json(j); + } + if (ptrs_density_recommendation_set_ul.scs_minus60k_hz_present) { + j.write_fieldname("scs-60kHz"); + ptrs_density_recommendation_set_ul.scs_minus60k_hz.to_json(j); + } + if (ptrs_density_recommendation_set_ul.scs_minus120k_hz_present) { + j.write_fieldname("scs-120kHz"); + ptrs_density_recommendation_set_ul.scs_minus120k_hz.to_json(j); + } + j.end_obj(); + } + if (dummy4_present) { + j.write_fieldname("dummy4"); + dummy4.to_json(j); + } + if (aperiodic_trs_present) { + j.write_str("aperiodicTRS", "supported"); + } + if (ext) { + if (dummy6_present) { + j.write_str("dummy6", "true"); + } + if (beam_management_ssb_csi_rs.is_present()) { + j.write_fieldname("beamManagementSSB-CSI-RS"); + beam_management_ssb_csi_rs->to_json(j); + } + if (beam_switch_timing.is_present()) { + j.write_fieldname("beamSwitchTiming"); + j.start_obj(); + if (beam_switch_timing->scs_minus60k_hz_present) { + j.write_str("scs-60kHz", beam_switch_timing->scs_minus60k_hz.to_string()); + } + if (beam_switch_timing->scs_minus120k_hz_present) { + j.write_str("scs-120kHz", beam_switch_timing->scs_minus120k_hz.to_string()); + } + j.end_obj(); + } + if (codebook_params.is_present()) { + j.write_fieldname("codebookParameters"); + codebook_params->to_json(j); + } + if (csi_rs_im_reception_for_feedback.is_present()) { + j.write_fieldname("csi-RS-IM-ReceptionForFeedback"); + csi_rs_im_reception_for_feedback->to_json(j); + } + if (csi_rs_proc_framework_for_srs.is_present()) { + j.write_fieldname("csi-RS-ProcFrameworkForSRS"); + csi_rs_proc_framework_for_srs->to_json(j); + } + if (csi_report_framework.is_present()) { + j.write_fieldname("csi-ReportFramework"); + csi_report_framework->to_json(j); + } + if (csi_rs_for_tracking.is_present()) { + j.write_fieldname("csi-RS-ForTracking"); + csi_rs_for_tracking->to_json(j); + } + if (srs_assoc_csi_rs.is_present()) { + j.start_array("srs-AssocCSI-RS"); + for (const auto& e1 : *srs_assoc_csi_rs) { + e1.to_json(j); + } + j.end_array(); + } + if (spatial_relations.is_present()) { + j.write_fieldname("spatialRelations"); + spatial_relations->to_json(j); + } + } + j.end_obj(); +} + +std::string mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_opts::to_string() const +{ + static const char* options[] = {"n4", "n8", "n16", "n32", "n64", "n128"}; + return convert_enum_idx( + options, 6, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_e_"); +} +uint8_t mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_opts::to_number() const +{ + static const uint8_t options[] = {4, 8, 16, 32, 64, 128}; + return map_enum_number( + options, 6, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_e_"); +} + +std::string mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_opts::to_string() const +{ + static const char* options[] = {"n1", "n2", "n4", "n8"}; + return convert_enum_idx( + options, 4, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_e_"); +} +uint8_t mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 4, 8}; + return map_enum_number( + options, 4, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_e_"); +} + +std::string mimo_params_per_band_s::pusch_trans_coherence_opts::to_string() const +{ + static const char* options[] = {"nonCoherent", "partialCoherent", "fullCoherent"}; + return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::pusch_trans_coherence_e_"); +} + +std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_opts::to_string() const +{ + static const char* options[] = {"n4", "n7", "n14"}; + return convert_enum_idx( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_e_"); +} +uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_opts::to_number() const +{ + static const uint8_t options[] = {4, 7, 14}; + return map_enum_number( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_e_"); +} + +std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_opts::to_string() const +{ + static const char* options[] = {"n4", "n7", "n14"}; + return convert_enum_idx( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_e_"); +} +uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_opts::to_number() const +{ + static const uint8_t options[] = {4, 7, 14}; + return map_enum_number( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_e_"); +} + +std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_opts::to_string() const +{ + static const char* options[] = {"n4", "n7", "n14"}; + return convert_enum_idx( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_e_"); +} +uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_opts::to_number() const +{ + static const uint8_t options[] = {4, 7, 14}; + return map_enum_number( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_e_"); +} + +std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_opts::to_string() const +{ + static const char* options[] = {"n4", "n7", "n14"}; + return convert_enum_idx( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_e_"); +} +uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_opts::to_number() const +{ + static const uint8_t options[] = {4, 7, 14}; + return map_enum_number( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_e_"); +} + +std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_opts::to_string() const +{ + static const char* options[] = {"n4", "n7", "n14"}; + return convert_enum_idx( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_e_"); +} +uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_opts::to_number() const +{ + static const uint8_t options[] = {4, 7, 14}; + return map_enum_number( + options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_e_"); +} + +std::string mimo_params_per_band_s::max_num_non_group_beam_report_opts::to_string() const +{ + static const char* options[] = {"n1", "n2", "n4"}; + return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::max_num_non_group_beam_report_e_"); +} +uint8_t mimo_params_per_band_s::max_num_non_group_beam_report_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 4}; + return map_enum_number(options, 3, value, "mimo_params_per_band_s::max_num_non_group_beam_report_e_"); +} + +std::string mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_opts::to_string() const +{ + static const char* options[] = {"n2", "n4", "n8", "n16"}; + return convert_enum_idx( + options, 4, value, "mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_e_"); +} +uint8_t mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 8, 16}; + return map_enum_number( + options, 4, value, "mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_e_"); +} + +std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_opts::to_string() const +{ + static const char* options[] = {"sym2", "sym4", "sym8"}; + return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_e_"); +} +uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 8}; + return map_enum_number(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_e_"); +} + +std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_opts::to_string() const +{ + static const char* options[] = {"sym4", "sym8", "sym14", "sym28"}; + return convert_enum_idx(options, 4, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_e_"); +} +uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_opts::to_number() const +{ + static const uint8_t options[] = {4, 8, 14, 28}; + return map_enum_number(options, 4, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_e_"); +} + +std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_opts::to_string() const +{ + static const char* options[] = {"sym8", "sym14", "sym28"}; + return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_e_"); +} +uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_opts::to_number() const +{ + static const uint8_t options[] = {8, 14, 28}; + return map_enum_number(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_e_"); +} + +std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_opts::to_string() const +{ + static const char* options[] = {"sym14", "sym28", "sym56"}; + return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_e_"); +} +uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_opts::to_number() const +{ + static const uint8_t options[] = {14, 28, 56}; + return map_enum_number(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_e_"); +} + +std::string mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_opts::to_string() const +{ + static const char* options[] = {"sym14", "sym28", "sym48", "sym224", "sym336"}; + return convert_enum_idx(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_e_"); +} +uint16_t mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_opts::to_number() const +{ + static const uint16_t options[] = {14, 28, 48, 224, 336}; + return map_enum_number(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_e_"); +} + +std::string mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_opts::to_string() const +{ + static const char* options[] = {"sym14", "sym28", "sym48", "sym224", "sym336"}; + return convert_enum_idx(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_e_"); +} +uint16_t mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_opts::to_number() const +{ + static const uint16_t options[] = {14, 28, 48, 224, 336}; + return map_enum_number(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_e_"); +} + +// BandNR ::= SEQUENCE +SRSASN_CODE band_nr_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(modified_mpr_behaviour_present, 1)); + HANDLE_CODE(bref.pack(mimo_params_per_band_present, 1)); + HANDLE_CODE(bref.pack(extended_cp_present, 1)); + HANDLE_CODE(bref.pack(multiple_tci_present, 1)); + HANDLE_CODE(bref.pack(bwp_without_restrict_present, 1)); + HANDLE_CODE(bref.pack(bwp_same_numerology_present, 1)); + HANDLE_CODE(bref.pack(bwp_diff_numerology_present, 1)); + HANDLE_CODE(bref.pack(cross_carrier_sched_same_scs_present, 1)); + HANDLE_CODE(bref.pack(pdsch_minus256_qam_fr2_present, 1)); + HANDLE_CODE(bref.pack(pusch_minus256_qam_present, 1)); + HANDLE_CODE(bref.pack(ue_pwr_class_present, 1)); + HANDLE_CODE(bref.pack(rate_matching_lte_crs_present, 1)); + HANDLE_CODE(bref.pack(ch_bws_dl_present, 1)); + HANDLE_CODE(bref.pack(ch_bws_ul_present, 1)); + + HANDLE_CODE(pack_integer(bref, band_nr, (uint16_t)1u, (uint16_t)1024u)); + if (modified_mpr_behaviour_present) { + HANDLE_CODE(modified_mpr_behaviour.pack(bref)); + } + if (mimo_params_per_band_present) { + HANDLE_CODE(mimo_params_per_band.pack(bref)); + } + if (bwp_same_numerology_present) { + HANDLE_CODE(bwp_same_numerology.pack(bref)); + } + if (ue_pwr_class_present) { + HANDLE_CODE(ue_pwr_class.pack(bref)); + } + if (ch_bws_dl_present) { + HANDLE_CODE(ch_bws_dl.pack(bref)); + } + if (ch_bws_ul_present) { + HANDLE_CODE(ch_bws_ul.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= max_ul_duty_cycle_pc2_fr1_present; + group_flags[1] |= pucch_spatial_rel_info_mac_ce_present; + group_flags[1] |= pwr_boosting_pi2_bpsk_present; + group_flags[2] |= max_ul_duty_cycle_fr2_present; + group_flags[3] |= ch_bws_dl_v1590.is_present(); + group_flags[3] |= ch_bws_ul_v1590.is_present(); + group_flags[4] |= asymmetric_bw_combination_set_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(max_ul_duty_cycle_pc2_fr1_present, 1)); + if (max_ul_duty_cycle_pc2_fr1_present) { + HANDLE_CODE(max_ul_duty_cycle_pc2_fr1.pack(bref)); + } + } + if (group_flags[1]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(pucch_spatial_rel_info_mac_ce_present, 1)); + HANDLE_CODE(bref.pack(pwr_boosting_pi2_bpsk_present, 1)); + } + if (group_flags[2]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(max_ul_duty_cycle_fr2_present, 1)); + if (max_ul_duty_cycle_fr2_present) { + HANDLE_CODE(max_ul_duty_cycle_fr2.pack(bref)); + } + } + if (group_flags[3]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(ch_bws_dl_v1590.is_present(), 1)); + HANDLE_CODE(bref.pack(ch_bws_ul_v1590.is_present(), 1)); + if (ch_bws_dl_v1590.is_present()) { + HANDLE_CODE(ch_bws_dl_v1590->pack(bref)); + } + if (ch_bws_ul_v1590.is_present()) { + HANDLE_CODE(ch_bws_ul_v1590->pack(bref)); + } + } + if (group_flags[4]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(asymmetric_bw_combination_set_present, 1)); + if (asymmetric_bw_combination_set_present) { + HANDLE_CODE(asymmetric_bw_combination_set.pack(bref)); + } + } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE band_nr_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(modified_mpr_behaviour_present, 1)); + HANDLE_CODE(bref.unpack(mimo_params_per_band_present, 1)); + HANDLE_CODE(bref.unpack(extended_cp_present, 1)); + HANDLE_CODE(bref.unpack(multiple_tci_present, 1)); + HANDLE_CODE(bref.unpack(bwp_without_restrict_present, 1)); + HANDLE_CODE(bref.unpack(bwp_same_numerology_present, 1)); + HANDLE_CODE(bref.unpack(bwp_diff_numerology_present, 1)); + HANDLE_CODE(bref.unpack(cross_carrier_sched_same_scs_present, 1)); + HANDLE_CODE(bref.unpack(pdsch_minus256_qam_fr2_present, 1)); + HANDLE_CODE(bref.unpack(pusch_minus256_qam_present, 1)); + HANDLE_CODE(bref.unpack(ue_pwr_class_present, 1)); + HANDLE_CODE(bref.unpack(rate_matching_lte_crs_present, 1)); + HANDLE_CODE(bref.unpack(ch_bws_dl_present, 1)); + HANDLE_CODE(bref.unpack(ch_bws_ul_present, 1)); + + HANDLE_CODE(unpack_integer(band_nr, bref, (uint16_t)1u, (uint16_t)1024u)); + if (modified_mpr_behaviour_present) { + HANDLE_CODE(modified_mpr_behaviour.unpack(bref)); + } + if (mimo_params_per_band_present) { + HANDLE_CODE(mimo_params_per_band.unpack(bref)); + } + if (bwp_same_numerology_present) { + HANDLE_CODE(bwp_same_numerology.unpack(bref)); + } + if (ue_pwr_class_present) { + HANDLE_CODE(ue_pwr_class.unpack(bref)); + } + if (ch_bws_dl_present) { + HANDLE_CODE(ch_bws_dl.unpack(bref)); + } + if (ch_bws_ul_present) { + HANDLE_CODE(ch_bws_ul.unpack(bref)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(5); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(max_ul_duty_cycle_pc2_fr1_present, 1)); + if (max_ul_duty_cycle_pc2_fr1_present) { + HANDLE_CODE(max_ul_duty_cycle_pc2_fr1.unpack(bref)); + } + } + if (group_flags[1]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(pucch_spatial_rel_info_mac_ce_present, 1)); + HANDLE_CODE(bref.unpack(pwr_boosting_pi2_bpsk_present, 1)); + } + if (group_flags[2]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(max_ul_duty_cycle_fr2_present, 1)); + if (max_ul_duty_cycle_fr2_present) { + HANDLE_CODE(max_ul_duty_cycle_fr2.unpack(bref)); + } + } + if (group_flags[3]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool ch_bws_dl_v1590_present; + HANDLE_CODE(bref.unpack(ch_bws_dl_v1590_present, 1)); + ch_bws_dl_v1590.set_present(ch_bws_dl_v1590_present); + bool ch_bws_ul_v1590_present; + HANDLE_CODE(bref.unpack(ch_bws_ul_v1590_present, 1)); + ch_bws_ul_v1590.set_present(ch_bws_ul_v1590_present); + if (ch_bws_dl_v1590.is_present()) { + HANDLE_CODE(ch_bws_dl_v1590->unpack(bref)); + } + if (ch_bws_ul_v1590.is_present()) { + HANDLE_CODE(ch_bws_ul_v1590->unpack(bref)); + } + } + if (group_flags[4]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(asymmetric_bw_combination_set_present, 1)); + if (asymmetric_bw_combination_set_present) { + HANDLE_CODE(asymmetric_bw_combination_set.unpack(bref)); + } + } + } + return SRSASN_SUCCESS; +} +void band_nr_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("bandNR", band_nr); + if (modified_mpr_behaviour_present) { + j.write_str("modifiedMPR-Behaviour", modified_mpr_behaviour.to_string()); + } + if (mimo_params_per_band_present) { + j.write_fieldname("mimo-ParametersPerBand"); + mimo_params_per_band.to_json(j); + } + if (extended_cp_present) { + j.write_str("extendedCP", "supported"); + } + if (multiple_tci_present) { + j.write_str("multipleTCI", "supported"); + } + if (bwp_without_restrict_present) { + j.write_str("bwp-WithoutRestriction", "supported"); + } + if (bwp_same_numerology_present) { + j.write_str("bwp-SameNumerology", bwp_same_numerology.to_string()); + } + if (bwp_diff_numerology_present) { + j.write_str("bwp-DiffNumerology", "upto4"); + } + if (cross_carrier_sched_same_scs_present) { + j.write_str("crossCarrierScheduling-SameSCS", "supported"); + } + if (pdsch_minus256_qam_fr2_present) { + j.write_str("pdsch-256QAM-FR2", "supported"); + } + if (pusch_minus256_qam_present) { + j.write_str("pusch-256QAM", "supported"); + } + if (ue_pwr_class_present) { + j.write_str("ue-PowerClass", ue_pwr_class.to_string()); + } + if (rate_matching_lte_crs_present) { + j.write_str("rateMatchingLTE-CRS", "supported"); + } + if (ch_bws_dl_present) { + j.write_fieldname("channelBWs-DL"); + ch_bws_dl.to_json(j); + } + if (ch_bws_ul_present) { + j.write_fieldname("channelBWs-UL"); + ch_bws_ul.to_json(j); + } + if (ext) { + if (max_ul_duty_cycle_pc2_fr1_present) { + j.write_str("maxUplinkDutyCycle-PC2-FR1", max_ul_duty_cycle_pc2_fr1.to_string()); + } + if (pucch_spatial_rel_info_mac_ce_present) { + j.write_str("pucch-SpatialRelInfoMAC-CE", "supported"); + } + if (pwr_boosting_pi2_bpsk_present) { + j.write_str("powerBoosting-pi2BPSK", "supported"); + } + if (max_ul_duty_cycle_fr2_present) { + j.write_str("maxUplinkDutyCycle-FR2", max_ul_duty_cycle_fr2.to_string()); + } + if (ch_bws_dl_v1590.is_present()) { + j.write_fieldname("channelBWs-DL-v1590"); + ch_bws_dl_v1590->to_json(j); + } + if (ch_bws_ul_v1590.is_present()) { + j.write_fieldname("channelBWs-UL-v1590"); + ch_bws_ul_v1590->to_json(j); + } + if (asymmetric_bw_combination_set_present) { + j.write_str("asymmetricBandwidthCombinationSet", asymmetric_bw_combination_set.to_string()); + } + } + j.end_obj(); +} + +std::string band_nr_s::bwp_same_numerology_opts::to_string() const +{ + static const char* options[] = {"upto2", "upto4"}; + return convert_enum_idx(options, 2, value, "band_nr_s::bwp_same_numerology_e_"); +} +uint8_t band_nr_s::bwp_same_numerology_opts::to_number() const +{ + static const uint8_t options[] = {2, 4}; + return map_enum_number(options, 2, value, "band_nr_s::bwp_same_numerology_e_"); +} + +std::string band_nr_s::ue_pwr_class_opts::to_string() const +{ + static const char* options[] = {"pc1", "pc2", "pc3", "pc4"}; + return convert_enum_idx(options, 4, value, "band_nr_s::ue_pwr_class_e_"); +} +uint8_t band_nr_s::ue_pwr_class_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 3, 4}; + return map_enum_number(options, 4, value, "band_nr_s::ue_pwr_class_e_"); +} + +void band_nr_s::ch_bws_dl_c_::destroy_() +{ + switch (type_) { + case types::fr1: + c.destroy(); + break; + case types::fr2: + c.destroy(); + break; + default: + break; + } +} +void band_nr_s::ch_bws_dl_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::fr1: + c.init(); + break; + case types::fr2: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_c_"); + } +} +band_nr_s::ch_bws_dl_c_::ch_bws_dl_c_(const band_nr_s::ch_bws_dl_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::fr1: + c.init(other.c.get()); + break; + case types::fr2: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_c_"); + } +} +band_nr_s::ch_bws_dl_c_& band_nr_s::ch_bws_dl_c_::operator=(const band_nr_s::ch_bws_dl_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::fr1: + c.set(other.c.get()); + break; + case types::fr2: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_c_"); + } + + return *this; +} +void band_nr_s::ch_bws_dl_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::fr1: + j.write_fieldname("fr1"); + j.start_obj(); + if (c.get().scs_minus15k_hz_present) { + j.write_str("scs-15kHz", c.get().scs_minus15k_hz.to_string()); + } + if (c.get().scs_minus30k_hz_present) { + j.write_str("scs-30kHz", c.get().scs_minus30k_hz.to_string()); + } + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + j.end_obj(); + break; + case types::fr2: + j.write_fieldname("fr2"); + j.start_obj(); + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + if (c.get().scs_minus120k_hz_present) { + j.write_str("scs-120kHz", c.get().scs_minus120k_hz.to_string()); + } + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_c_"); + } + j.end_obj(); +} +SRSASN_CODE band_nr_s::ch_bws_dl_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.pack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.pack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.pack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.pack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE band_nr_s::ch_bws_dl_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.unpack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.unpack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.unpack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.unpack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string band_nr_s::ch_bws_dl_c_::types_opts::to_string() const +{ + static const char* options[] = {"fr1", "fr2"}; + return convert_enum_idx(options, 2, value, "band_nr_s::ch_bws_dl_c_::types"); +} +uint8_t band_nr_s::ch_bws_dl_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "band_nr_s::ch_bws_dl_c_::types"); +} + +void band_nr_s::ch_bws_ul_c_::destroy_() +{ + switch (type_) { + case types::fr1: + c.destroy(); + break; + case types::fr2: + c.destroy(); + break; + default: + break; + } +} +void band_nr_s::ch_bws_ul_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::fr1: + c.init(); + break; + case types::fr2: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_c_"); + } +} +band_nr_s::ch_bws_ul_c_::ch_bws_ul_c_(const band_nr_s::ch_bws_ul_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::fr1: + c.init(other.c.get()); + break; + case types::fr2: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_c_"); + } +} +band_nr_s::ch_bws_ul_c_& band_nr_s::ch_bws_ul_c_::operator=(const band_nr_s::ch_bws_ul_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::fr1: + c.set(other.c.get()); + break; + case types::fr2: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_c_"); + } + + return *this; +} +void band_nr_s::ch_bws_ul_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::fr1: + j.write_fieldname("fr1"); + j.start_obj(); + if (c.get().scs_minus15k_hz_present) { + j.write_str("scs-15kHz", c.get().scs_minus15k_hz.to_string()); + } + if (c.get().scs_minus30k_hz_present) { + j.write_str("scs-30kHz", c.get().scs_minus30k_hz.to_string()); + } + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + j.end_obj(); + break; + case types::fr2: + j.write_fieldname("fr2"); + j.start_obj(); + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + if (c.get().scs_minus120k_hz_present) { + j.write_str("scs-120kHz", c.get().scs_minus120k_hz.to_string()); + } + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_c_"); + } + j.end_obj(); +} +SRSASN_CODE band_nr_s::ch_bws_ul_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.pack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.pack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.pack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.pack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE band_nr_s::ch_bws_ul_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.unpack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.unpack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.unpack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.unpack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string band_nr_s::ch_bws_ul_c_::types_opts::to_string() const +{ + static const char* options[] = {"fr1", "fr2"}; + return convert_enum_idx(options, 2, value, "band_nr_s::ch_bws_ul_c_::types"); +} +uint8_t band_nr_s::ch_bws_ul_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "band_nr_s::ch_bws_ul_c_::types"); +} + +std::string band_nr_s::max_ul_duty_cycle_pc2_fr1_opts::to_string() const +{ + static const char* options[] = {"n60", "n70", "n80", "n90", "n100"}; + return convert_enum_idx(options, 5, value, "band_nr_s::max_ul_duty_cycle_pc2_fr1_e_"); +} +uint8_t band_nr_s::max_ul_duty_cycle_pc2_fr1_opts::to_number() const +{ + static const uint8_t options[] = {60, 70, 80, 90, 100}; + return map_enum_number(options, 5, value, "band_nr_s::max_ul_duty_cycle_pc2_fr1_e_"); +} + +std::string band_nr_s::max_ul_duty_cycle_fr2_opts::to_string() const +{ + static const char* options[] = {"n15", "n20", "n25", "n30", "n40", "n50", "n60", "n70", "n80", "n90", "n100"}; + return convert_enum_idx(options, 11, value, "band_nr_s::max_ul_duty_cycle_fr2_e_"); +} +uint8_t band_nr_s::max_ul_duty_cycle_fr2_opts::to_number() const +{ + static const uint8_t options[] = {15, 20, 25, 30, 40, 50, 60, 70, 80, 90, 100}; + return map_enum_number(options, 11, value, "band_nr_s::max_ul_duty_cycle_fr2_e_"); +} + +void band_nr_s::ch_bws_dl_v1590_c_::destroy_() +{ + switch (type_) { + case types::fr1: + c.destroy(); + break; + case types::fr2: + c.destroy(); + break; + default: + break; + } +} +void band_nr_s::ch_bws_dl_v1590_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::fr1: + c.init(); + break; + case types::fr2: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1590_c_"); + } +} +band_nr_s::ch_bws_dl_v1590_c_::ch_bws_dl_v1590_c_(const band_nr_s::ch_bws_dl_v1590_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::fr1: + c.init(other.c.get()); + break; + case types::fr2: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1590_c_"); + } +} +band_nr_s::ch_bws_dl_v1590_c_& band_nr_s::ch_bws_dl_v1590_c_::operator=(const band_nr_s::ch_bws_dl_v1590_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::fr1: + c.set(other.c.get()); + break; + case types::fr2: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1590_c_"); + } + + return *this; +} +void band_nr_s::ch_bws_dl_v1590_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::fr1: + j.write_fieldname("fr1"); + j.start_obj(); + if (c.get().scs_minus15k_hz_present) { + j.write_str("scs-15kHz", c.get().scs_minus15k_hz.to_string()); + } + if (c.get().scs_minus30k_hz_present) { + j.write_str("scs-30kHz", c.get().scs_minus30k_hz.to_string()); + } + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + j.end_obj(); + break; + case types::fr2: + j.write_fieldname("fr2"); + j.start_obj(); + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + if (c.get().scs_minus120k_hz_present) { + j.write_str("scs-120kHz", c.get().scs_minus120k_hz.to_string()); + } + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1590_c_"); + } + j.end_obj(); +} +SRSASN_CODE band_nr_s::ch_bws_dl_v1590_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.pack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.pack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.pack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.pack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1590_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE band_nr_s::ch_bws_dl_v1590_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.unpack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.unpack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.unpack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.unpack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1590_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string band_nr_s::ch_bws_dl_v1590_c_::types_opts::to_string() const +{ + static const char* options[] = {"fr1", "fr2"}; + return convert_enum_idx(options, 2, value, "band_nr_s::ch_bws_dl_v1590_c_::types"); +} +uint8_t band_nr_s::ch_bws_dl_v1590_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "band_nr_s::ch_bws_dl_v1590_c_::types"); +} + +void band_nr_s::ch_bws_ul_v1590_c_::destroy_() +{ + switch (type_) { + case types::fr1: + c.destroy(); + break; + case types::fr2: + c.destroy(); + break; + default: + break; + } +} +void band_nr_s::ch_bws_ul_v1590_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::fr1: + c.init(); + break; + case types::fr2: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1590_c_"); + } +} +band_nr_s::ch_bws_ul_v1590_c_::ch_bws_ul_v1590_c_(const band_nr_s::ch_bws_ul_v1590_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::fr1: + c.init(other.c.get()); + break; + case types::fr2: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1590_c_"); + } +} +band_nr_s::ch_bws_ul_v1590_c_& band_nr_s::ch_bws_ul_v1590_c_::operator=(const band_nr_s::ch_bws_ul_v1590_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::fr1: + c.set(other.c.get()); + break; + case types::fr2: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1590_c_"); + } + + return *this; +} +void band_nr_s::ch_bws_ul_v1590_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::fr1: + j.write_fieldname("fr1"); + j.start_obj(); + if (c.get().scs_minus15k_hz_present) { + j.write_str("scs-15kHz", c.get().scs_minus15k_hz.to_string()); + } + if (c.get().scs_minus30k_hz_present) { + j.write_str("scs-30kHz", c.get().scs_minus30k_hz.to_string()); + } + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + j.end_obj(); + break; + case types::fr2: + j.write_fieldname("fr2"); + j.start_obj(); + if (c.get().scs_minus60k_hz_present) { + j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); + } + if (c.get().scs_minus120k_hz_present) { + j.write_str("scs-120kHz", c.get().scs_minus120k_hz.to_string()); + } + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1590_c_"); + } + j.end_obj(); +} +SRSASN_CODE band_nr_s::ch_bws_ul_v1590_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.pack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.pack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.pack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.pack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.pack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1590_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE band_nr_s::ch_bws_ul_v1590_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::fr1: + HANDLE_CODE(bref.unpack(c.get().scs_minus15k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus30k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + if (c.get().scs_minus15k_hz_present) { + HANDLE_CODE(c.get().scs_minus15k_hz.unpack(bref)); + } + if (c.get().scs_minus30k_hz_present) { + HANDLE_CODE(c.get().scs_minus30k_hz.unpack(bref)); + } + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + break; + case types::fr2: + HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); + HANDLE_CODE(bref.unpack(c.get().scs_minus120k_hz_present, 1)); + if (c.get().scs_minus60k_hz_present) { + HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); + } + if (c.get().scs_minus120k_hz_present) { + HANDLE_CODE(c.get().scs_minus120k_hz.unpack(bref)); + } + break; + default: + log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1590_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string band_nr_s::ch_bws_ul_v1590_c_::types_opts::to_string() const +{ + static const char* options[] = {"fr1", "fr2"}; + return convert_enum_idx(options, 2, value, "band_nr_s::ch_bws_ul_v1590_c_::types"); +} +uint8_t band_nr_s::ch_bws_ul_v1590_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "band_nr_s::ch_bws_ul_v1590_c_::types"); +} + +// CFRA-CSIRS-Resource ::= SEQUENCE +SRSASN_CODE cfra_csirs_res_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, csi_rs, (uint8_t)0u, (uint8_t)95u)); + HANDLE_CODE(pack_dyn_seq_of(bref, ra_occasion_list, 1, 64, integer_packer(0, 511))); + HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE cfra_csirs_res_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(csi_rs, bref, (uint8_t)0u, (uint8_t)95u)); + HANDLE_CODE(unpack_dyn_seq_of(ra_occasion_list, bref, 1, 64, integer_packer(0, 511))); + HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); + + return SRSASN_SUCCESS; +} +void cfra_csirs_res_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("csi-RS", csi_rs); + j.start_array("ra-OccasionList"); + for (const auto& e1 : ra_occasion_list) { + j.write_int(e1); + } + j.end_array(); + j.write_int("ra-PreambleIndex", ra_preamb_idx); + j.end_obj(); +} + +// CFRA-SSB-Resource ::= SEQUENCE +SRSASN_CODE cfra_ssb_res_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, ssb, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_integer(bref, ra_preamb_idx, (uint8_t)0u, (uint8_t)63u)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE cfra_ssb_res_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(ssb, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_integer(ra_preamb_idx, bref, (uint8_t)0u, (uint8_t)63u)); + + return SRSASN_SUCCESS; +} +void cfra_ssb_res_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("ssb", ssb); + j.write_int("ra-PreambleIndex", ra_preamb_idx); + j.end_obj(); +} + +// CFRA ::= SEQUENCE +SRSASN_CODE cfra_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(occasions_present, 1)); + + if (occasions_present) { + HANDLE_CODE(bref.pack(occasions.ssb_per_rach_occasion_present, 1)); + HANDLE_CODE(occasions.rach_cfg_generic.pack(bref)); + if (occasions.ssb_per_rach_occasion_present) { + HANDLE_CODE(occasions.ssb_per_rach_occasion.pack(bref)); + } + } + HANDLE_CODE(res.pack(bref)); + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= total_nof_ra_preambs_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(total_nof_ra_preambs_present, 1)); + if (total_nof_ra_preambs_present) { + HANDLE_CODE(pack_integer(bref, total_nof_ra_preambs, (uint8_t)1u, (uint8_t)63u)); + } + } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE cfra_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(occasions_present, 1)); + + if (occasions_present) { + HANDLE_CODE(bref.unpack(occasions.ssb_per_rach_occasion_present, 1)); + HANDLE_CODE(occasions.rach_cfg_generic.unpack(bref)); + if (occasions.ssb_per_rach_occasion_present) { + HANDLE_CODE(occasions.ssb_per_rach_occasion.unpack(bref)); + } + } + HANDLE_CODE(res.unpack(bref)); + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(total_nof_ra_preambs_present, 1)); + if (total_nof_ra_preambs_present) { + HANDLE_CODE(unpack_integer(total_nof_ra_preambs, bref, (uint8_t)1u, (uint8_t)63u)); + } + } + } + return SRSASN_SUCCESS; +} +void cfra_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (occasions_present) { + j.write_fieldname("occasions"); + j.start_obj(); + j.write_fieldname("rach-ConfigGeneric"); + occasions.rach_cfg_generic.to_json(j); + if (occasions.ssb_per_rach_occasion_present) { + j.write_str("ssb-perRACH-Occasion", occasions.ssb_per_rach_occasion.to_string()); + } + j.end_obj(); + } + j.write_fieldname("resources"); + res.to_json(j); + if (ext) { + if (total_nof_ra_preambs_present) { + j.write_int("totalNumberOfRA-Preambles", total_nof_ra_preambs); + } + } + j.end_obj(); +} + +std::string cfra_s::occasions_s_::ssb_per_rach_occasion_opts::to_string() const +{ + static const char* options[] = {"oneEighth", "oneFourth", "oneHalf", "one", "two", "four", "eight", "sixteen"}; + return convert_enum_idx(options, 8, value, "cfra_s::occasions_s_::ssb_per_rach_occasion_e_"); +} +float cfra_s::occasions_s_::ssb_per_rach_occasion_opts::to_number() const +{ + static const float options[] = {0.125, 0.25, 0.5, 1.0, 2.0, 4.0, 8.0, 6.0}; + return map_enum_number(options, 8, value, "cfra_s::occasions_s_::ssb_per_rach_occasion_e_"); +} +std::string cfra_s::occasions_s_::ssb_per_rach_occasion_opts::to_number_string() const +{ + static const char* options[] = {"1/8", "1/4", "1/2", "1", "2", "4", "8", "6"}; + return convert_enum_idx(options, 8, value, "cfra_s::occasions_s_::ssb_per_rach_occasion_e_"); +} + +void cfra_s::res_c_::destroy_() +{ + switch (type_) { + case types::ssb: + c.destroy(); + break; + case types::csirs: + c.destroy(); + break; + default: + break; + } +} +void cfra_s::res_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::ssb: + c.init(); + break; + case types::csirs: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cfra_s::res_c_"); + } +} +cfra_s::res_c_::res_c_(const cfra_s::res_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::ssb: + c.init(other.c.get()); + break; + case types::csirs: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cfra_s::res_c_"); + } +} +cfra_s::res_c_& cfra_s::res_c_::operator=(const cfra_s::res_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::ssb: + c.set(other.c.get()); + break; + case types::csirs: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "cfra_s::res_c_"); + } + + return *this; +} +void cfra_s::res_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::ssb: + j.write_fieldname("ssb"); + j.start_obj(); + j.start_array("ssb-ResourceList"); + for (const auto& e1 : c.get().ssb_res_list) { + e1.to_json(j); + } + j.end_array(); + j.write_int("ra-ssb-OccasionMaskIndex", c.get().ra_ssb_occasion_mask_idx); + j.end_obj(); + break; + case types::csirs: + j.write_fieldname("csirs"); + j.start_obj(); + j.start_array("csirs-ResourceList"); + for (const auto& e1 : c.get().csirs_res_list) { + e1.to_json(j); + } + j.end_array(); + j.write_int("rsrp-ThresholdCSI-RS", c.get().rsrp_thres_csi_rs); + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "cfra_s::res_c_"); + } + j.end_obj(); +} +SRSASN_CODE cfra_s::res_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::ssb: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get().ssb_res_list, 1, 64)); + HANDLE_CODE(pack_integer(bref, c.get().ra_ssb_occasion_mask_idx, (uint8_t)0u, (uint8_t)15u)); + break; + case types::csirs: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get().csirs_res_list, 1, 96)); + HANDLE_CODE(pack_integer(bref, c.get().rsrp_thres_csi_rs, (uint8_t)0u, (uint8_t)127u)); + break; + default: + log_invalid_choice_id(type_, "cfra_s::res_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE cfra_s::res_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ssb: + HANDLE_CODE(unpack_dyn_seq_of(c.get().ssb_res_list, bref, 1, 64)); + HANDLE_CODE(unpack_integer(c.get().ra_ssb_occasion_mask_idx, bref, (uint8_t)0u, (uint8_t)15u)); + break; + case types::csirs: + HANDLE_CODE(unpack_dyn_seq_of(c.get().csirs_res_list, bref, 1, 96)); + HANDLE_CODE(unpack_integer(c.get().rsrp_thres_csi_rs, bref, (uint8_t)0u, (uint8_t)127u)); + break; + default: + log_invalid_choice_id(type_, "cfra_s::res_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string cfra_s::res_c_::types_opts::to_string() const +{ + static const char* options[] = {"ssb", "csirs"}; + return convert_enum_idx(options, 2, value, "cfra_s::res_c_::types"); +} + +// CSI-AssociatedReportConfigInfo ::= SEQUENCE +SRSASN_CODE csi_associated_report_cfg_info_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(csi_im_res_for_interference_present, 1)); + HANDLE_CODE(bref.pack(nzp_csi_rs_res_for_interference_present, 1)); + + HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)0u, (uint8_t)47u)); + HANDLE_CODE(res_for_ch.pack(bref)); + if (csi_im_res_for_interference_present) { + HANDLE_CODE(pack_integer(bref, csi_im_res_for_interference, (uint8_t)1u, (uint8_t)16u)); + } + if (nzp_csi_rs_res_for_interference_present) { + HANDLE_CODE(pack_integer(bref, nzp_csi_rs_res_for_interference, (uint8_t)1u, (uint8_t)16u)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_associated_report_cfg_info_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(csi_im_res_for_interference_present, 1)); + HANDLE_CODE(bref.unpack(nzp_csi_rs_res_for_interference_present, 1)); + + HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)0u, (uint8_t)47u)); + HANDLE_CODE(res_for_ch.unpack(bref)); + if (csi_im_res_for_interference_present) { + HANDLE_CODE(unpack_integer(csi_im_res_for_interference, bref, (uint8_t)1u, (uint8_t)16u)); + } + if (nzp_csi_rs_res_for_interference_present) { + HANDLE_CODE(unpack_integer(nzp_csi_rs_res_for_interference, bref, (uint8_t)1u, (uint8_t)16u)); + } + + return SRSASN_SUCCESS; +} +void csi_associated_report_cfg_info_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("reportConfigId", report_cfg_id); + j.write_fieldname("resourcesForChannel"); + res_for_ch.to_json(j); + if (csi_im_res_for_interference_present) { + j.write_int("csi-IM-ResourcesForInterference", csi_im_res_for_interference); + } + if (nzp_csi_rs_res_for_interference_present) { + j.write_int("nzp-CSI-RS-ResourcesForInterference", nzp_csi_rs_res_for_interference); + } + j.end_obj(); +} + +void csi_associated_report_cfg_info_s::res_for_ch_c_::destroy_() +{ + switch (type_) { + case types::nzp_csi_rs: + c.destroy(); + break; + default: + break; + } +} +void csi_associated_report_cfg_info_s::res_for_ch_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::nzp_csi_rs: + c.init(); + break; + case types::csi_ssb_res_set: + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + } +} +csi_associated_report_cfg_info_s::res_for_ch_c_::res_for_ch_c_( + const csi_associated_report_cfg_info_s::res_for_ch_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::nzp_csi_rs: + c.init(other.c.get()); + break; + case types::csi_ssb_res_set: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + } +} +csi_associated_report_cfg_info_s::res_for_ch_c_& +csi_associated_report_cfg_info_s::res_for_ch_c_::operator=(const csi_associated_report_cfg_info_s::res_for_ch_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::nzp_csi_rs: + c.set(other.c.get()); + break; + case types::csi_ssb_res_set: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + } + + return *this; +} +void csi_associated_report_cfg_info_s::res_for_ch_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::nzp_csi_rs: + j.write_fieldname("nzp-CSI-RS"); + j.start_obj(); + j.write_int("resourceSet", c.get().res_set); + if (c.get().qcl_info_present) { + j.start_array("qcl-info"); + for (const auto& e1 : c.get().qcl_info) { + j.write_int(e1); + } + j.end_array(); + } + j.end_obj(); + break; + case types::csi_ssb_res_set: + j.write_int("csi-SSB-ResourceSet", c.get()); + break; + default: + log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + } + j.end_obj(); +} +SRSASN_CODE csi_associated_report_cfg_info_s::res_for_ch_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::nzp_csi_rs: + HANDLE_CODE(bref.pack(c.get().qcl_info_present, 1)); + HANDLE_CODE(pack_integer(bref, c.get().res_set, (uint8_t)1u, (uint8_t)16u)); + if (c.get().qcl_info_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, c.get().qcl_info, 1, 16, integer_packer(0, 127))); + } + break; + case types::csi_ssb_res_set: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)1u)); + break; + default: + log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_associated_report_cfg_info_s::res_for_ch_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::nzp_csi_rs: + HANDLE_CODE(bref.unpack(c.get().qcl_info_present, 1)); + HANDLE_CODE(unpack_integer(c.get().res_set, bref, (uint8_t)1u, (uint8_t)16u)); + if (c.get().qcl_info_present) { + HANDLE_CODE(unpack_dyn_seq_of(c.get().qcl_info, bref, 1, 16, integer_packer(0, 127))); + } + break; + case types::csi_ssb_res_set: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)1u)); + break; + default: + log_invalid_choice_id(type_, "csi_associated_report_cfg_info_s::res_for_ch_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string csi_associated_report_cfg_info_s::res_for_ch_c_::types_opts::to_string() const +{ + static const char* options[] = {"nzp-CSI-RS", "csi-SSB-ResourceSet"}; + return convert_enum_idx(options, 2, value, "csi_associated_report_cfg_info_s::res_for_ch_c_::types"); +} + +// CSI-AperiodicTriggerState ::= SEQUENCE +SRSASN_CODE csi_aperiodic_trigger_state_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_dyn_seq_of(bref, associated_report_cfg_info_list, 1, 16)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_aperiodic_trigger_state_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_dyn_seq_of(associated_report_cfg_info_list, bref, 1, 16)); + + return SRSASN_SUCCESS; +} +void csi_aperiodic_trigger_state_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.start_array("associatedReportConfigInfoList"); + for (const auto& e1 : associated_report_cfg_info_list) { + e1.to_json(j); + } + j.end_array(); + j.end_obj(); +} + +// CSI-IM-Resource ::= SEQUENCE +SRSASN_CODE csi_im_res_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(csi_im_res_elem_pattern_present, 1)); + HANDLE_CODE(bref.pack(freq_band_present, 1)); + HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); + + HANDLE_CODE(pack_integer(bref, csi_im_res_id, (uint8_t)0u, (uint8_t)31u)); + if (csi_im_res_elem_pattern_present) { + HANDLE_CODE(csi_im_res_elem_pattern.pack(bref)); + } + if (freq_band_present) { + HANDLE_CODE(freq_band.pack(bref)); + } + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_im_res_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(csi_im_res_elem_pattern_present, 1)); + HANDLE_CODE(bref.unpack(freq_band_present, 1)); + HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); + + HANDLE_CODE(unpack_integer(csi_im_res_id, bref, (uint8_t)0u, (uint8_t)31u)); + if (csi_im_res_elem_pattern_present) { + HANDLE_CODE(csi_im_res_elem_pattern.unpack(bref)); + } + if (freq_band_present) { + HANDLE_CODE(freq_band.unpack(bref)); + } + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void csi_im_res_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("csi-IM-ResourceId", csi_im_res_id); + if (csi_im_res_elem_pattern_present) { + j.write_fieldname("csi-IM-ResourceElementPattern"); + csi_im_res_elem_pattern.to_json(j); + } + if (freq_band_present) { + j.write_fieldname("freqBand"); + freq_band.to_json(j); + } + if (periodicity_and_offset_present) { + j.write_fieldname("periodicityAndOffset"); + periodicity_and_offset.to_json(j); + } + j.end_obj(); +} + +void csi_im_res_s::csi_im_res_elem_pattern_c_::destroy_() +{ + switch (type_) { + case types::pattern0: + c.destroy(); + break; + case types::pattern1: + c.destroy(); + break; + default: + break; + } +} +void csi_im_res_s::csi_im_res_elem_pattern_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::pattern0: + c.init(); + break; + case types::pattern1: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + } +} +csi_im_res_s::csi_im_res_elem_pattern_c_::csi_im_res_elem_pattern_c_( + const csi_im_res_s::csi_im_res_elem_pattern_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::pattern0: + c.init(other.c.get()); + break; + case types::pattern1: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + } +} +csi_im_res_s::csi_im_res_elem_pattern_c_& +csi_im_res_s::csi_im_res_elem_pattern_c_::operator=(const csi_im_res_s::csi_im_res_elem_pattern_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::pattern0: + c.set(other.c.get()); + break; + case types::pattern1: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + } + + return *this; +} +void csi_im_res_s::csi_im_res_elem_pattern_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::pattern0: + j.write_fieldname("pattern0"); + j.start_obj(); + j.write_str("subcarrierLocation-p0", c.get().subcarrier_location_p0.to_string()); + j.write_int("symbolLocation-p0", c.get().symbol_location_p0); + j.end_obj(); + break; + case types::pattern1: + j.write_fieldname("pattern1"); + j.start_obj(); + j.write_str("subcarrierLocation-p1", c.get().subcarrier_location_p1.to_string()); + j.write_int("symbolLocation-p1", c.get().symbol_location_p1); + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + } + j.end_obj(); +} +SRSASN_CODE csi_im_res_s::csi_im_res_elem_pattern_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::pattern0: + HANDLE_CODE(c.get().subcarrier_location_p0.pack(bref)); + HANDLE_CODE(pack_integer(bref, c.get().symbol_location_p0, (uint8_t)0u, (uint8_t)12u)); + break; + case types::pattern1: + HANDLE_CODE(c.get().subcarrier_location_p1.pack(bref)); + HANDLE_CODE(pack_integer(bref, c.get().symbol_location_p1, (uint8_t)0u, (uint8_t)13u)); + break; + default: + log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_im_res_s::csi_im_res_elem_pattern_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::pattern0: + HANDLE_CODE(c.get().subcarrier_location_p0.unpack(bref)); + HANDLE_CODE(unpack_integer(c.get().symbol_location_p0, bref, (uint8_t)0u, (uint8_t)12u)); + break; + case types::pattern1: + HANDLE_CODE(c.get().subcarrier_location_p1.unpack(bref)); + HANDLE_CODE(unpack_integer(c.get().symbol_location_p1, bref, (uint8_t)0u, (uint8_t)13u)); + break; + default: + log_invalid_choice_id(type_, "csi_im_res_s::csi_im_res_elem_pattern_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_opts::to_string() const +{ + static const char* options[] = {"s0", "s2", "s4", "s6", "s8", "s10"}; + return convert_enum_idx( + options, 6, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_e_"); +} +uint8_t csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_opts::to_number() const +{ + static const uint8_t options[] = {0, 2, 4, 6, 8, 10}; + return map_enum_number( + options, 6, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern0_s_::subcarrier_location_p0_e_"); +} + +std::string csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_opts::to_string() const +{ + static const char* options[] = {"s0", "s4", "s8"}; + return convert_enum_idx( + options, 3, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_e_"); +} +uint8_t csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_opts::to_number() const +{ + static const uint8_t options[] = {0, 4, 8}; + return map_enum_number( + options, 3, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::pattern1_s_::subcarrier_location_p1_e_"); +} + +std::string csi_im_res_s::csi_im_res_elem_pattern_c_::types_opts::to_string() const +{ + static const char* options[] = {"pattern0", "pattern1"}; + return convert_enum_idx(options, 2, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::types"); +} +uint8_t csi_im_res_s::csi_im_res_elem_pattern_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {0, 1}; + return map_enum_number(options, 2, value, "csi_im_res_s::csi_im_res_elem_pattern_c_::types"); +} + +// CSI-IM-ResourceSet ::= SEQUENCE +SRSASN_CODE csi_im_res_set_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, csi_im_res_set_id, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res, 1, 8, integer_packer(0, 31))); + + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_im_res_set_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(csi_im_res_set_id, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_dyn_seq_of(csi_im_res, bref, 1, 8, integer_packer(0, 31))); + + return SRSASN_SUCCESS; +} +void csi_im_res_set_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("csi-IM-ResourceSetId", csi_im_res_set_id); + j.start_array("csi-IM-Resources"); + for (const auto& e1 : csi_im_res) { + j.write_int(e1); + } + j.end_array(); + j.end_obj(); +} + +// CSI-ReportPeriodicityAndOffset ::= CHOICE +void csi_report_periodicity_and_offset_c::destroy_() {} +void csi_report_periodicity_and_offset_c::set(types::options e) +{ + destroy_(); + type_ = e; +} +csi_report_periodicity_and_offset_c::csi_report_periodicity_and_offset_c( + const csi_report_periodicity_and_offset_c& other) +{ + type_ = other.type(); + switch (type_) { + case types::slots4: + c.init(other.c.get()); + break; + case types::slots5: + c.init(other.c.get()); + break; + case types::slots8: + c.init(other.c.get()); + break; + case types::slots10: + c.init(other.c.get()); + break; + case types::slots16: + c.init(other.c.get()); + break; + case types::slots20: + c.init(other.c.get()); + break; + case types::slots40: + c.init(other.c.get()); + break; + case types::slots80: + c.init(other.c.get()); + break; + case types::slots160: + c.init(other.c.get()); + break; + case types::slots320: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + } +} +csi_report_periodicity_and_offset_c& +csi_report_periodicity_and_offset_c::operator=(const csi_report_periodicity_and_offset_c& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::slots4: + c.set(other.c.get()); + break; + case types::slots5: + c.set(other.c.get()); + break; + case types::slots8: + c.set(other.c.get()); + break; + case types::slots10: + c.set(other.c.get()); + break; + case types::slots16: + c.set(other.c.get()); + break; + case types::slots20: + c.set(other.c.get()); + break; + case types::slots40: + c.set(other.c.get()); + break; + case types::slots80: + c.set(other.c.get()); + break; + case types::slots160: + c.set(other.c.get()); + break; + case types::slots320: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + } + + return *this; +} +void csi_report_periodicity_and_offset_c::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::slots4: + j.write_int("slots4", c.get()); + break; + case types::slots5: + j.write_int("slots5", c.get()); + break; + case types::slots8: + j.write_int("slots8", c.get()); + break; + case types::slots10: + j.write_int("slots10", c.get()); + break; + case types::slots16: + j.write_int("slots16", c.get()); + break; + case types::slots20: + j.write_int("slots20", c.get()); + break; + case types::slots40: + j.write_int("slots40", c.get()); + break; + case types::slots80: + j.write_int("slots80", c.get()); + break; + case types::slots160: + j.write_int("slots160", c.get()); + break; + case types::slots320: + j.write_int("slots320", c.get()); + break; + default: + log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + } + j.end_obj(); +} +SRSASN_CODE csi_report_periodicity_and_offset_c::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::slots4: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)3u)); + break; + case types::slots5: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)4u)); + break; + case types::slots8: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)7u)); + break; + case types::slots10: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); + break; + case types::slots16: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)15u)); + break; + case types::slots20: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); + break; + case types::slots40: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); + break; + case types::slots80: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); + break; + case types::slots160: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + break; + case types::slots320: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + break; + default: + log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_report_periodicity_and_offset_c::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::slots4: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)3u)); + break; + case types::slots5: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)4u)); + break; + case types::slots8: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)7u)); + break; + case types::slots10: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); + break; + case types::slots16: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)15u)); + break; + case types::slots20: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); + break; + case types::slots40: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); + break; + case types::slots80: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); + break; + case types::slots160: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + break; + case types::slots320: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + break; + default: + log_invalid_choice_id(type_, "csi_report_periodicity_and_offset_c"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string csi_report_periodicity_and_offset_c::types_opts::to_string() const +{ + static const char* options[] = { + "slots4", "slots5", "slots8", "slots10", "slots16", "slots20", "slots40", "slots80", "slots160", "slots320"}; + return convert_enum_idx(options, 10, value, "csi_report_periodicity_and_offset_c::types"); +} +uint16_t csi_report_periodicity_and_offset_c::types_opts::to_number() const +{ + static const uint16_t options[] = {4, 5, 8, 10, 16, 20, 40, 80, 160, 320}; + return map_enum_number(options, 10, value, "csi_report_periodicity_and_offset_c::types"); +} + +// CSI-SemiPersistentOnPUSCH-TriggerState ::= SEQUENCE +SRSASN_CODE csi_semi_persistent_on_pusch_trigger_state_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, associated_report_cfg_info, (uint8_t)0u, (uint8_t)47u)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE csi_semi_persistent_on_pusch_trigger_state_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(associated_report_cfg_info, bref, (uint8_t)0u, (uint8_t)47u)); + + return SRSASN_SUCCESS; +} +void csi_semi_persistent_on_pusch_trigger_state_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("associatedReportConfigInfo", associated_report_cfg_info); + j.end_obj(); +} + +// CodebookConfig ::= SEQUENCE +SRSASN_CODE codebook_cfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(codebook_type.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE codebook_cfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(codebook_type.unpack(bref)); + + return SRSASN_SUCCESS; +} +void codebook_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_fieldname("codebookType"); + codebook_type.to_json(j); + j.end_obj(); +} + +void codebook_cfg_s::codebook_type_c_::destroy_() +{ + switch (type_) { + case types::type1: + c.destroy(); + break; + case types::type2: + c.destroy(); + break; + default: + break; + } +} +void codebook_cfg_s::codebook_type_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::type1: + c.init(); + break; + case types::type2: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + } +} +codebook_cfg_s::codebook_type_c_::codebook_type_c_(const codebook_cfg_s::codebook_type_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::type1: + c.init(other.c.get()); + break; + case types::type2: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + } +} +codebook_cfg_s::codebook_type_c_& +codebook_cfg_s::codebook_type_c_::operator=(const codebook_cfg_s::codebook_type_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::type1: + c.set(other.c.get()); + break; + case types::type2: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + } + + return *this; +} +void codebook_cfg_s::codebook_type_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::type1: + j.write_fieldname("type1"); + j.start_obj(); + j.write_fieldname("subType"); + c.get().sub_type.to_json(j); + j.write_int("codebookMode", c.get().codebook_mode); + j.end_obj(); + break; + case types::type2: + j.write_fieldname("type2"); + j.start_obj(); + j.write_fieldname("subType"); + c.get().sub_type.to_json(j); + j.write_str("phaseAlphabetSize", c.get().phase_alphabet_size.to_string()); + j.write_bool("subbandAmplitude", c.get().subband_amplitude); + j.write_str("numberOfBeams", c.get().nof_beams.to_string()); + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + } + j.end_obj(); +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::type1: + HANDLE_CODE(c.get().sub_type.pack(bref)); + HANDLE_CODE(pack_integer(bref, c.get().codebook_mode, (uint8_t)1u, (uint8_t)2u)); + break; + case types::type2: + HANDLE_CODE(c.get().sub_type.pack(bref)); + HANDLE_CODE(c.get().phase_alphabet_size.pack(bref)); + HANDLE_CODE(bref.pack(c.get().subband_amplitude, 1)); + HANDLE_CODE(c.get().nof_beams.pack(bref)); + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::type1: + HANDLE_CODE(c.get().sub_type.unpack(bref)); + HANDLE_CODE(unpack_integer(c.get().codebook_mode, bref, (uint8_t)1u, (uint8_t)2u)); + break; + case types::type2: + HANDLE_CODE(c.get().sub_type.unpack(bref)); + HANDLE_CODE(c.get().phase_alphabet_size.unpack(bref)); + HANDLE_CODE(bref.unpack(c.get().subband_amplitude, 1)); + HANDLE_CODE(c.get().nof_beams.unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::destroy_() +{ + switch (type_) { + case types::type_i_single_panel: + c.destroy(); + break; + case types::type_i_multi_panel: + c.destroy(); + break; + default: + break; + } +} +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::type_i_single_panel: + c.init(); + break; + case types::type_i_multi_panel: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + } +} +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::sub_type_c_( + const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::type_i_single_panel: + c.init(other.c.get()); + break; + case types::type_i_multi_panel: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + } +} +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_& +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::operator=( + const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::type_i_single_panel: + c.set(other.c.get()); + break; + case types::type_i_multi_panel: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + } + + return *this; +} +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::type_i_single_panel: + j.write_fieldname("typeI-SinglePanel"); + j.start_obj(); + j.write_fieldname("nrOfAntennaPorts"); + c.get().nr_of_ant_ports.to_json(j); + j.write_str("typeI-SinglePanel-ri-Restriction", + c.get().type_i_single_panel_ri_restrict.to_string()); + j.end_obj(); + break; + case types::type_i_multi_panel: + j.write_fieldname("typeI-MultiPanel"); + j.start_obj(); + j.write_fieldname("ng-n1-n2"); + c.get().ng_n1_n2.to_json(j); + j.write_str("ri-Restriction", c.get().ri_restrict.to_string()); + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + } + j.end_obj(); +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::type_i_single_panel: + HANDLE_CODE(c.get().nr_of_ant_ports.pack(bref)); + HANDLE_CODE(c.get().type_i_single_panel_ri_restrict.pack(bref)); + break; + case types::type_i_multi_panel: + HANDLE_CODE(c.get().ng_n1_n2.pack(bref)); + HANDLE_CODE(c.get().ri_restrict.pack(bref)); + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::type_i_single_panel: + HANDLE_CODE(c.get().nr_of_ant_ports.unpack(bref)); + HANDLE_CODE(c.get().type_i_single_panel_ri_restrict.unpack(bref)); + break; + case types::type_i_multi_panel: + HANDLE_CODE(c.get().ng_n1_n2.unpack(bref)); + HANDLE_CODE(c.get().ri_restrict.unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::destroy_() +{ + switch (type_) { + case types::two: + c.destroy(); + break; + case types::more_than_two: + c.destroy(); + break; + default: + break; + } +} +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::set( + types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::two: + c.init(); + break; + case types::more_than_two: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + } +} +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::nr_of_ant_ports_c_( + const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::two: + c.init(other.c.get()); + break; + case types::more_than_two: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + } +} +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_& +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::operator=( + const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::two: + c.set(other.c.get()); + break; + case types::more_than_two: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + } + + return *this; +} +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::to_json( + json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::two: + j.write_fieldname("two"); + j.start_obj(); + j.write_str("twoTX-CodebookSubsetRestriction", c.get().two_tx_codebook_subset_restrict.to_string()); + j.end_obj(); + break; + case types::more_than_two: + j.write_fieldname("moreThanTwo"); + j.start_obj(); + j.write_fieldname("n1-n2"); + c.get().n1_n2.to_json(j); + if (c.get().type_i_single_panel_codebook_subset_restrict_i2_present) { + j.write_str("typeI-SinglePanel-codebookSubsetRestriction-i2", + c.get().type_i_single_panel_codebook_subset_restrict_i2.to_string()); + } + j.end_obj(); + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + } + j.end_obj(); +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::pack( + bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::two: + HANDLE_CODE(c.get().two_tx_codebook_subset_restrict.pack(bref)); + break; + case types::more_than_two: + HANDLE_CODE(bref.pack(c.get().type_i_single_panel_codebook_subset_restrict_i2_present, 1)); + HANDLE_CODE(c.get().n1_n2.pack(bref)); + if (c.get().type_i_single_panel_codebook_subset_restrict_i2_present) { + HANDLE_CODE(c.get().type_i_single_panel_codebook_subset_restrict_i2.pack(bref)); + } + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::unpack( + cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::two: + HANDLE_CODE(c.get().two_tx_codebook_subset_restrict.unpack(bref)); + break; + case types::more_than_two: + HANDLE_CODE(bref.unpack(c.get().type_i_single_panel_codebook_subset_restrict_i2_present, 1)); + HANDLE_CODE(c.get().n1_n2.unpack(bref)); + if (c.get().type_i_single_panel_codebook_subset_restrict_i2_present) { + HANDLE_CODE(c.get().type_i_single_panel_codebook_subset_restrict_i2.unpack(bref)); + } + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_::destroy_() +{ + switch (type_) { + case types::two_one_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::two_two_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::four_one_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::three_two_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::six_one_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::four_two_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::eight_one_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::four_three_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::six_two_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::twelve_one_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::four_four_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::eight_two_type_i_single_panel_restrict: + c.destroy >(); + break; + case types::sixteen_one_type_i_single_panel_restrict: + c.destroy >(); + break; + default: + break; + } +} +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::two_one_type_i_single_panel_restrict: + c.init >(); + break; + case types::two_two_type_i_single_panel_restrict: + c.init >(); + break; + case types::four_one_type_i_single_panel_restrict: + c.init >(); + break; + case types::three_two_type_i_single_panel_restrict: + c.init >(); + break; + case types::six_one_type_i_single_panel_restrict: + c.init >(); + break; + case types::four_two_type_i_single_panel_restrict: + c.init >(); + break; + case types::eight_one_type_i_single_panel_restrict: + c.init >(); + break; + case types::four_three_type_i_single_panel_restrict: + c.init >(); + break; + case types::six_two_type_i_single_panel_restrict: + c.init >(); + break; + case types::twelve_one_type_i_single_panel_restrict: + c.init >(); + break; + case types::four_four_type_i_single_panel_restrict: + c.init >(); + break; + case types::eight_two_type_i_single_panel_restrict: + c.init >(); + break; + case types::sixteen_one_type_i_single_panel_restrict: + c.init >(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" + "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + } +} +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::more_than_two_s_:: + n1_n2_c_::n1_n2_c_(const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_:: + nr_of_ant_ports_c_::more_than_two_s_::n1_n2_c_& other) +{ + type_ = other.type(); + switch (type_) { + case types::two_one_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::two_two_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::four_one_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::three_two_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::six_one_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::four_two_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::eight_one_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::four_three_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::six_two_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::twelve_one_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::four_four_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::eight_two_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::sixteen_one_type_i_single_panel_restrict: + c.init(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" + "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + } +} +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::more_than_two_s_:: + n1_n2_c_& + codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_::operator=( + const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_& other) +{ + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::two_one_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::two_two_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::four_one_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::three_two_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::six_one_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::four_two_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::eight_one_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::four_three_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::six_two_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::twelve_one_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::four_four_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::eight_two_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::sixteen_one_type_i_single_panel_restrict: + c.set(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" + "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + } + + return *this; +} +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_::to_json(json_writer& j) const +{ + j.start_obj(); + switch (type_) { + case types::two_one_type_i_single_panel_restrict: + j.write_str("two-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::two_two_type_i_single_panel_restrict: + j.write_str("two-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::four_one_type_i_single_panel_restrict: + j.write_str("four-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::three_two_type_i_single_panel_restrict: + j.write_str("three-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::six_one_type_i_single_panel_restrict: + j.write_str("six-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::four_two_type_i_single_panel_restrict: + j.write_str("four-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::eight_one_type_i_single_panel_restrict: + j.write_str("eight-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::four_three_type_i_single_panel_restrict: + j.write_str("four-three-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::six_two_type_i_single_panel_restrict: + j.write_str("six-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::twelve_one_type_i_single_panel_restrict: + j.write_str("twelve-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::four_four_type_i_single_panel_restrict: + j.write_str("four-four-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::eight_two_type_i_single_panel_restrict: + j.write_str("eight-two-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + case types::sixteen_one_type_i_single_panel_restrict: + j.write_str("sixteen-one-TypeI-SinglePanel-Restriction", c.get >().to_string()); + break; + default: + log_invalid_choice_id(type_, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" + "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + } + j.end_obj(); +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::two_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::two_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::three_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::six_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::eight_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_three_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::six_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::twelve_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_four_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::eight_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::sixteen_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + default: + log_invalid_choice_id(type_, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" + "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::two_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::two_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::three_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::six_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::eight_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_three_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::six_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::twelve_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_four_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::eight_two_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::sixteen_one_type_i_single_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + default: + log_invalid_choice_id(type_, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_" + "ant_ports_c_::more_than_two_s_::n1_n2_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + more_than_two_s_::n1_n2_c_::types_opts::to_string() const +{ + static const char* options[] = {"two-one-TypeI-SinglePanel-Restriction", + "two-two-TypeI-SinglePanel-Restriction", + "four-one-TypeI-SinglePanel-Restriction", + "three-two-TypeI-SinglePanel-Restriction", + "six-one-TypeI-SinglePanel-Restriction", + "four-two-TypeI-SinglePanel-Restriction", + "eight-one-TypeI-SinglePanel-Restriction", + "four-three-TypeI-SinglePanel-Restriction", + "six-two-TypeI-SinglePanel-Restriction", + "twelve-one-TypeI-SinglePanel-Restriction", + "four-four-TypeI-SinglePanel-Restriction", + "eight-two-TypeI-SinglePanel-Restriction", + "sixteen-one-TypeI-SinglePanel-Restriction"}; + return convert_enum_idx(options, + 13, + value, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_" + "ports_c_::more_than_two_s_::n1_n2_c_::types"); +} + +std::string codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + types_opts::to_string() const +{ + static const char* options[] = {"two", "moreThanTwo"}; + return convert_enum_idx( + options, + 2, + value, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::types"); +} +uint8_t codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_:: + types_opts::to_number() const +{ + static const uint8_t options[] = {2}; + return map_enum_number( + options, + 1, + value, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_single_panel_s_::nr_of_ant_ports_c_::types"); +} + +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::destroy_() +{ + switch (type_) { + case types::two_two_one_type_i_multi_panel_restrict: + c.destroy >(); + break; + case types::two_four_one_type_i_multi_panel_restrict: + c.destroy >(); + break; + case types::four_two_one_type_i_multi_panel_restrict: + c.destroy >(); + break; + case types::two_two_two_type_i_multi_panel_restrict: + c.destroy >(); + break; + case types::two_eight_one_type_i_multi_panel_restrict: + c.destroy >(); + break; + case types::four_four_one_type_i_multi_panel_restrict: + c.destroy >(); + break; + case types::two_four_two_type_i_multi_panel_restrict: + c.destroy >(); + break; + case types::four_two_two_type_i_multi_panel_restrict: + c.destroy >(); + break; + default: + break; } - j.end_obj(); } - -// UE-CapabilityRAT-Container ::= SEQUENCE -SRSASN_CODE ue_cap_rat_container_s::pack(bit_ref& bref) const +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::set(types::options e) { - HANDLE_CODE(rat_type.pack(bref)); - HANDLE_CODE(ue_cap_rat_container.pack(bref)); - - return SRSASN_SUCCESS; + destroy_(); + type_ = e; + switch (type_) { + case types::two_two_one_type_i_multi_panel_restrict: + c.init >(); + break; + case types::two_four_one_type_i_multi_panel_restrict: + c.init >(); + break; + case types::four_two_one_type_i_multi_panel_restrict: + c.init >(); + break; + case types::two_two_two_type_i_multi_panel_restrict: + c.init >(); + break; + case types::two_eight_one_type_i_multi_panel_restrict: + c.init >(); + break; + case types::four_four_one_type_i_multi_panel_restrict: + c.init >(); + break; + case types::two_four_two_type_i_multi_panel_restrict: + c.init >(); + break; + case types::four_two_two_type_i_multi_panel_restrict: + c.init >(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + } } -SRSASN_CODE ue_cap_rat_container_s::unpack(cbit_ref& bref) +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::ng_n1_n2_c_( + const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_& other) { - HANDLE_CODE(rat_type.unpack(bref)); - HANDLE_CODE(ue_cap_rat_container.unpack(bref)); - - return SRSASN_SUCCESS; + type_ = other.type(); + switch (type_) { + case types::two_two_one_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::two_four_one_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::four_two_one_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::two_two_two_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::two_eight_one_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::four_four_one_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::two_four_two_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::four_two_two_type_i_multi_panel_restrict: + c.init(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + } } -void ue_cap_rat_container_s::to_json(json_writer& j) const +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_& +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::operator=( + const codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_& other) { - j.start_obj(); - j.write_str("rat-Type", rat_type.to_string()); - j.write_str("ue-CapabilityRAT-Container", ue_cap_rat_container.to_string()); - j.end_obj(); -} + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::two_two_one_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::two_four_one_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::four_two_one_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::two_two_two_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::two_eight_one_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::four_four_one_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::two_four_two_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::four_two_two_type_i_multi_panel_restrict: + c.set(other.c.get >()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + } -// DelayBudgetReport ::= CHOICE -void delay_budget_report_c::to_json(json_writer& j) const + return *this; +} +void codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::to_json( + json_writer& j) const { j.start_obj(); - j.write_str("type1", c.to_string()); + switch (type_) { + case types::two_two_one_type_i_multi_panel_restrict: + j.write_str("two-two-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + case types::two_four_one_type_i_multi_panel_restrict: + j.write_str("two-four-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + case types::four_two_one_type_i_multi_panel_restrict: + j.write_str("four-two-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + case types::two_two_two_type_i_multi_panel_restrict: + j.write_str("two-two-two-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + case types::two_eight_one_type_i_multi_panel_restrict: + j.write_str("two-eight-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + case types::four_four_one_type_i_multi_panel_restrict: + j.write_str("four-four-one-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + case types::two_four_two_type_i_multi_panel_restrict: + j.write_str("two-four-two-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + case types::four_two_two_type_i_multi_panel_restrict: + j.write_str("four-two-two-TypeI-MultiPanel-Restriction", c.get >().to_string()); + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + } j.end_obj(); } -SRSASN_CODE delay_budget_report_c::pack(bit_ref& bref) const +SRSASN_CODE +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::pack(bit_ref& bref) const { - pack_enum(bref, type()); - HANDLE_CODE(c.pack(bref)); + type_.pack(bref); + switch (type_) { + case types::two_two_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::two_four_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_two_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::two_two_two_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::two_eight_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_four_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::two_four_two_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_two_two_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().pack(bref)); + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } return SRSASN_SUCCESS; } -SRSASN_CODE delay_budget_report_c::unpack(cbit_ref& bref) +SRSASN_CODE +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::unpack(cbit_ref& bref) { types e; - unpack_enum(e, bref); - if (e != type()) { - log_invalid_choice_id(e, "delay_budget_report_c"); - return SRSASN_ERROR_DECODE_FAIL; + e.unpack(bref); + set(e); + switch (type_) { + case types::two_two_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::two_four_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_two_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::two_two_two_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::two_eight_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_four_one_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::two_four_two_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_two_two_type_i_multi_panel_restrict: + HANDLE_CODE(c.get >().unpack(bref)); + break; + default: + log_invalid_choice_id( + type_, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_"); + return SRSASN_ERROR_DECODE_FAIL; } - HANDLE_CODE(c.unpack(bref)); return SRSASN_SUCCESS; } -std::string delay_budget_report_c::type1_opts::to_string() const -{ - static const char* options[] = {"msMinus1280", - "msMinus640", - "msMinus320", - "msMinus160", - "msMinus80", - "msMinus60", - "msMinus40", - "msMinus20", - "ms0", - "ms20", - "ms40", - "ms60", - "ms80", - "ms160", - "ms320", - "ms640", - "ms1280"}; - return convert_enum_idx(options, 17, value, "delay_budget_report_c::type1_e_"); -} -int16_t delay_budget_report_c::type1_opts::to_number() const +std::string +codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::types_opts::to_string() + const { - static const int16_t options[] = { - -1280, -640, -320, -160, -80, -60, -40, -20, 0, 20, 40, 60, 80, 160, 320, 640, 1280}; - return map_enum_number(options, 17, value, "delay_budget_report_c::type1_e_"); + static const char* options[] = {"two-two-one-TypeI-MultiPanel-Restriction", + "two-four-one-TypeI-MultiPanel-Restriction", + "four-two-one-TypeI-MultiPanel-Restriction", + "two-two-two-TypeI-MultiPanel-Restriction", + "two-eight-one-TypeI-MultiPanel-Restriction", + "four-four-one-TypeI-MultiPanel-Restriction", + "two-four-two-TypeI-MultiPanel-Restriction", + "four-two-two-TypeI-MultiPanel-Restriction"}; + return convert_enum_idx( + options, + 8, + value, + "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::type_i_multi_panel_s_::ng_n1_n2_c_::types"); } -std::string delay_budget_report_c::types_opts::to_string() const -{ - static const char* options[] = {"type1"}; - return convert_enum_idx(options, 1, value, "delay_budget_report_c::types"); -} -uint8_t delay_budget_report_c::types_opts::to_number() const +std::string codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::types_opts::to_string() const { - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "delay_budget_report_c::types"); + static const char* options[] = {"typeI-SinglePanel", "typeI-MultiPanel"}; + return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::type1_s_::sub_type_c_::types"); } -// FailureInfoRLC-Bearer ::= SEQUENCE -SRSASN_CODE fail_info_rlc_bearer_s::pack(bit_ref& bref) const +void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::destroy_() { - HANDLE_CODE(pack_integer(bref, cell_group_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(pack_integer(bref, lc_ch_id, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(fail_type.pack(bref)); - - return SRSASN_SUCCESS; + switch (type_) { + case types::type_ii: + c.destroy(); + break; + case types::type_ii_port_sel: + c.destroy(); + break; + default: + break; + } } -SRSASN_CODE fail_info_rlc_bearer_s::unpack(cbit_ref& bref) +void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::set(types::options e) { - HANDLE_CODE(unpack_integer(cell_group_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(unpack_integer(lc_ch_id, bref, (uint8_t)1u, (uint8_t)32u)); - HANDLE_CODE(fail_type.unpack(bref)); - - return SRSASN_SUCCESS; + destroy_(); + type_ = e; + switch (type_) { + case types::type_ii: + c.init(); + break; + case types::type_ii_port_sel: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + } } -void fail_info_rlc_bearer_s::to_json(json_writer& j) const +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::sub_type_c_( + const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_& other) { - j.start_obj(); - j.write_int("cellGroupId", cell_group_id); - j.write_int("logicalChannelIdentity", lc_ch_id); - j.write_str("failureType", fail_type.to_string()); - j.end_obj(); + type_ = other.type(); + switch (type_) { + case types::type_ii: + c.init(other.c.get()); + break; + case types::type_ii_port_sel: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + } } - -std::string fail_info_rlc_bearer_s::fail_type_opts::to_string() const +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_& +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::operator=( + const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_& other) { - static const char* options[] = {"duplication", "spare3", "spare2", "spare1"}; - return convert_enum_idx(options, 4, value, "fail_info_rlc_bearer_s::fail_type_e_"); -} + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::type_ii: + c.set(other.c.get()); + break; + case types::type_ii_port_sel: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); + } -// LocationMeasurementInfo ::= CHOICE -void location_meas_info_c::set(types::options e) -{ - type_ = e; + return *this; } -void location_meas_info_c::to_json(json_writer& j) const +void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::eutra_rstd: - j.start_array("eutra-RSTD"); - for (const auto& e1 : c) { - e1.to_json(j); - } - j.end_array(); + case types::type_ii: + j.write_fieldname("typeII"); + j.start_obj(); + j.write_fieldname("n1-n2-codebookSubsetRestriction"); + c.get().n1_n2_codebook_subset_restrict.to_json(j); + j.write_str("typeII-RI-Restriction", c.get().type_ii_ri_restrict.to_string()); + j.end_obj(); break; - case types::eutra_fine_timing_detection: + case types::type_ii_port_sel: + j.write_fieldname("typeII-PortSelection"); + j.start_obj(); + if (c.get().port_sel_sampling_size_present) { + j.write_str("portSelectionSamplingSize", c.get().port_sel_sampling_size.to_string()); + } + j.write_str("typeII-PortSelectionRI-Restriction", + c.get().type_ii_port_sel_ri_restrict.to_string()); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "location_meas_info_c"); + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); } j.end_obj(); } -SRSASN_CODE location_meas_info_c::pack(bit_ref& bref) const +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::eutra_rstd: - HANDLE_CODE(pack_dyn_seq_of(bref, c, 1, 3)); + case types::type_ii: + HANDLE_CODE(c.get().n1_n2_codebook_subset_restrict.pack(bref)); + HANDLE_CODE(c.get().type_ii_ri_restrict.pack(bref)); break; - case types::eutra_fine_timing_detection: + case types::type_ii_port_sel: + HANDLE_CODE(bref.pack(c.get().port_sel_sampling_size_present, 1)); + if (c.get().port_sel_sampling_size_present) { + HANDLE_CODE(c.get().port_sel_sampling_size.pack(bref)); + } + HANDLE_CODE(c.get().type_ii_port_sel_ri_restrict.pack(bref)); break; default: - log_invalid_choice_id(type_, "location_meas_info_c"); + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE location_meas_info_c::unpack(cbit_ref& bref) +SRSASN_CODE codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::eutra_rstd: - HANDLE_CODE(unpack_dyn_seq_of(c, bref, 1, 3)); + case types::type_ii: + HANDLE_CODE(c.get().n1_n2_codebook_subset_restrict.unpack(bref)); + HANDLE_CODE(c.get().type_ii_ri_restrict.unpack(bref)); break; - case types::eutra_fine_timing_detection: + case types::type_ii_port_sel: + HANDLE_CODE(bref.unpack(c.get().port_sel_sampling_size_present, 1)); + if (c.get().port_sel_sampling_size_present) { + HANDLE_CODE(c.get().port_sel_sampling_size.unpack(bref)); + } + HANDLE_CODE(c.get().type_ii_port_sel_ri_restrict.unpack(bref)); break; default: - log_invalid_choice_id(type_, "location_meas_info_c"); + log_invalid_choice_id(type_, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string location_meas_info_c::types_opts::to_string() const -{ - static const char* options[] = {"eutra-RSTD", "eutra-FineTimingDetection"}; - return convert_enum_idx(options, 2, value, "location_meas_info_c::types"); -} - -// MeasResults ::= SEQUENCE -SRSASN_CODE meas_results_s::pack(bit_ref& bref) const -{ - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(meas_result_neigh_cells_present, 1)); - - HANDLE_CODE(pack_integer(bref, meas_id, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_serving_mo_list, 1, 32)); - if (meas_result_neigh_cells_present) { - HANDLE_CODE(meas_result_neigh_cells.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE meas_results_s::unpack(cbit_ref& bref) -{ - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(meas_result_neigh_cells_present, 1)); - - HANDLE_CODE(unpack_integer(meas_id, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_dyn_seq_of(meas_result_serving_mo_list, bref, 1, 32)); - if (meas_result_neigh_cells_present) { - HANDLE_CODE(meas_result_neigh_cells.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void meas_results_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("measId", meas_id); - j.start_array("measResultServingMOList"); - for (const auto& e1 : meas_result_serving_mo_list) { - e1.to_json(j); - } - j.end_array(); - if (meas_result_neigh_cells_present) { - j.write_fieldname("measResultNeighCells"); - meas_result_neigh_cells.to_json(j); - } - j.end_obj(); -} - -void meas_results_s::meas_result_neigh_cells_c_::destroy_() +void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::destroy_() { switch (type_) { - case types::meas_result_list_nr: - c.destroy(); + case types::two_one: + c.destroy >(); + break; + case types::two_two: + c.destroy >(); + break; + case types::four_one: + c.destroy >(); + break; + case types::three_two: + c.destroy >(); + break; + case types::six_one: + c.destroy >(); + break; + case types::four_two: + c.destroy >(); break; - case types::meas_result_list_eutra: - c.destroy(); + case types::eight_one: + c.destroy >(); + break; + case types::four_three: + c.destroy >(); + break; + case types::six_two: + c.destroy >(); + break; + case types::twelve_one: + c.destroy >(); + break; + case types::four_four: + c.destroy >(); + break; + case types::eight_two: + c.destroy >(); + break; + case types::sixteen_one: + c.destroy >(); break; default: break; } } -void meas_results_s::meas_result_neigh_cells_c_::set(types::options e) +void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::set( + types::options e) { destroy_(); type_ = e; switch (type_) { - case types::meas_result_list_nr: - c.init(); + case types::two_one: + c.init >(); break; - case types::meas_result_list_eutra: - c.init(); + case types::two_two: + c.init >(); + break; + case types::four_one: + c.init >(); + break; + case types::three_two: + c.init >(); + break; + case types::six_one: + c.init >(); + break; + case types::four_two: + c.init >(); + break; + case types::eight_one: + c.init >(); + break; + case types::four_three: + c.init >(); + break; + case types::six_two: + c.init >(); + break; + case types::twelve_one: + c.init >(); + break; + case types::four_four: + c.init >(); + break; + case types::eight_two: + c.init >(); + break; + case types::sixteen_one: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); + log_invalid_choice_id( + type_, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); } } -meas_results_s::meas_result_neigh_cells_c_::meas_result_neigh_cells_c_( - const meas_results_s::meas_result_neigh_cells_c_& other) +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_:: + n1_n2_codebook_subset_restrict_c_( + const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_& + other) { type_ = other.type(); switch (type_) { - case types::meas_result_list_nr: - c.init(other.c.get()); + case types::two_one: + c.init(other.c.get >()); break; - case types::meas_result_list_eutra: - c.init(other.c.get()); + case types::two_two: + c.init(other.c.get >()); + break; + case types::four_one: + c.init(other.c.get >()); + break; + case types::three_two: + c.init(other.c.get >()); + break; + case types::six_one: + c.init(other.c.get >()); + break; + case types::four_two: + c.init(other.c.get >()); + break; + case types::eight_one: + c.init(other.c.get >()); + break; + case types::four_three: + c.init(other.c.get >()); + break; + case types::six_two: + c.init(other.c.get >()); + break; + case types::twelve_one: + c.init(other.c.get >()); + break; + case types::four_four: + c.init(other.c.get >()); + break; + case types::eight_two: + c.init(other.c.get >()); + break; + case types::sixteen_one: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); + log_invalid_choice_id( + type_, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); } } -meas_results_s::meas_result_neigh_cells_c_& meas_results_s::meas_result_neigh_cells_c_:: - operator=(const meas_results_s::meas_result_neigh_cells_c_& other) +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_& +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::operator=( + const codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::meas_result_list_nr: - c.set(other.c.get()); + case types::two_one: + c.set(other.c.get >()); break; - case types::meas_result_list_eutra: - c.set(other.c.get()); + case types::two_two: + c.set(other.c.get >()); + break; + case types::four_one: + c.set(other.c.get >()); + break; + case types::three_two: + c.set(other.c.get >()); + break; + case types::six_one: + c.set(other.c.get >()); + break; + case types::four_two: + c.set(other.c.get >()); + break; + case types::eight_one: + c.set(other.c.get >()); + break; + case types::four_three: + c.set(other.c.get >()); + break; + case types::six_two: + c.set(other.c.get >()); + break; + case types::twelve_one: + c.set(other.c.get >()); + break; + case types::four_four: + c.set(other.c.get >()); + break; + case types::eight_two: + c.set(other.c.get >()); + break; + case types::sixteen_one: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); + log_invalid_choice_id( + type_, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); } return *this; } -void meas_results_s::meas_result_neigh_cells_c_::to_json(json_writer& j) const +void codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::to_json( + json_writer& j) const { j.start_obj(); switch (type_) { - case types::meas_result_list_nr: - j.start_array("measResultListNR"); - for (const auto& e1 : c.get()) { - e1.to_json(j); - } - j.end_array(); + case types::two_one: + j.write_str("two-one", c.get >().to_string()); break; - case types::meas_result_list_eutra: - j.start_array("measResultListEUTRA"); - for (const auto& e1 : c.get()) { - e1.to_json(j); - } - j.end_array(); + case types::two_two: + j.write_str("two-two", c.get >().to_string()); + break; + case types::four_one: + j.write_str("four-one", c.get >().to_string()); + break; + case types::three_two: + j.write_str("three-two", c.get >().to_string()); + break; + case types::six_one: + j.write_str("six-one", c.get >().to_string()); + break; + case types::four_two: + j.write_str("four-two", c.get >().to_string()); + break; + case types::eight_one: + j.write_str("eight-one", c.get >().to_string()); + break; + case types::four_three: + j.write_str("four-three", c.get >().to_string()); + break; + case types::six_two: + j.write_str("six-two", c.get >().to_string()); + break; + case types::twelve_one: + j.write_str("twelve-one", c.get >().to_string()); + break; + case types::four_four: + j.write_str("four-four", c.get >().to_string()); + break; + case types::eight_two: + j.write_str("eight-two", c.get >().to_string()); + break; + case types::sixteen_one: + j.write_str("sixteen-one", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); + log_invalid_choice_id( + type_, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); } j.end_obj(); } -SRSASN_CODE meas_results_s::meas_result_neigh_cells_c_::pack(bit_ref& bref) const +SRSASN_CODE +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::pack( + bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::meas_result_list_nr: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); + case types::two_one: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::two_two: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_one: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::three_two: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::six_one: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_two: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::eight_one: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_three: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::six_two: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::twelve_one: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::four_four: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::eight_two: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::sixteen_one: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::meas_result_list_eutra: { - varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 8)); - } break; default: - log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); + log_invalid_choice_id( + type_, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE meas_results_s::meas_result_neigh_cells_c_::unpack(cbit_ref& bref) +SRSASN_CODE +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::unpack( + cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::meas_result_list_nr: - HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); + case types::two_one: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::two_two: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_one: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::three_two: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::six_one: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_two: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::eight_one: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_three: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::six_two: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::twelve_one: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::four_four: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::eight_two: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::sixteen_one: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::meas_result_list_eutra: { - varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 8)); - } break; default: - log_invalid_choice_id(type_, "meas_results_s::meas_result_neigh_cells_c_"); + log_invalid_choice_id( + type_, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string meas_results_s::meas_result_neigh_cells_c_::types_opts::to_string() const +std::string codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_:: + types_opts::to_string() const { - static const char* options[] = {"measResultListNR", "measResultListEUTRA"}; - return convert_enum_idx(options, 2, value, "meas_results_s::meas_result_neigh_cells_c_::types"); + static const char* options[] = {"two-one", + "two-two", + "four-one", + "three-two", + "six-one", + "four-two", + "eight-one", + "four-three", + "six-two", + "twelve-one", + "four-four", + "eight-two", + "sixteen-one"}; + return convert_enum_idx( + options, + 13, + value, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_s_::n1_n2_codebook_subset_restrict_c_::types"); } -// RRCReconfigurationComplete-v1530-IEs ::= SEQUENCE -SRSASN_CODE rrc_recfg_complete_v1530_ies_s::pack(bit_ref& bref) const +std::string +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_opts::to_string() + const { - HANDLE_CODE(bref.pack(ul_tx_direct_current_list_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + static const char* options[] = {"n1", "n2", "n3", "n4"}; + return convert_enum_idx( + options, + 4, + value, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_e_"); +} +uint8_t +codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_opts::to_number() + const +{ + static const uint8_t options[] = {1, 2, 3, 4}; + return map_enum_number( + options, + 4, + value, + "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::type_ii_port_sel_s_::port_sel_sampling_size_e_"); +} - if (ul_tx_direct_current_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ul_tx_direct_current_list, 1, 32)); - } +std::string codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::types_opts::to_string() const +{ + static const char* options[] = {"typeII", "typeII-PortSelection"}; + return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::type2_s_::sub_type_c_::types"); +} - return SRSASN_SUCCESS; +std::string codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_opts::to_string() const +{ + static const char* options[] = {"n4", "n8"}; + return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_e_"); } -SRSASN_CODE rrc_recfg_complete_v1530_ies_s::unpack(cbit_ref& bref) +uint8_t codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_opts::to_number() const { - HANDLE_CODE(bref.unpack(ul_tx_direct_current_list_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (ul_tx_direct_current_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ul_tx_direct_current_list, bref, 1, 32)); - } + static const uint8_t options[] = {4, 8}; + return map_enum_number(options, 2, value, "codebook_cfg_s::codebook_type_c_::type2_s_::phase_alphabet_size_e_"); +} - return SRSASN_SUCCESS; +std::string codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_opts::to_string() const +{ + static const char* options[] = {"two", "three", "four"}; + return convert_enum_idx(options, 3, value, "codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_e_"); } -void rrc_recfg_complete_v1530_ies_s::to_json(json_writer& j) const +uint8_t codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_opts::to_number() const { - j.start_obj(); - if (ul_tx_direct_current_list_present) { - j.start_array("uplinkTxDirectCurrentList"); - for (const auto& e1 : ul_tx_direct_current_list) { - e1.to_json(j); - } - j.end_array(); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); + static const uint8_t options[] = {2, 3, 4}; + return map_enum_number(options, 3, value, "codebook_cfg_s::codebook_type_c_::type2_s_::nof_beams_e_"); } -// RegisteredAMF ::= SEQUENCE -SRSASN_CODE registered_amf_s::pack(bit_ref& bref) const +std::string codebook_cfg_s::codebook_type_c_::types_opts::to_string() const { - HANDLE_CODE(bref.pack(plmn_id_present, 1)); + static const char* options[] = {"type1", "type2"}; + return convert_enum_idx(options, 2, value, "codebook_cfg_s::codebook_type_c_::types"); +} +uint8_t codebook_cfg_s::codebook_type_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "codebook_cfg_s::codebook_type_c_::types"); +} - if (plmn_id_present) { - HANDLE_CODE(plmn_id.pack(bref)); - } - HANDLE_CODE(amf_id.pack(bref)); +// PUCCH-CSI-Resource ::= SEQUENCE +SRSASN_CODE pucch_csi_res_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, ul_bw_part_id, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(pack_integer(bref, pucch_res, (uint8_t)0u, (uint8_t)127u)); return SRSASN_SUCCESS; } -SRSASN_CODE registered_amf_s::unpack(cbit_ref& bref) +SRSASN_CODE pucch_csi_res_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(plmn_id_present, 1)); - - if (plmn_id_present) { - HANDLE_CODE(plmn_id.unpack(bref)); - } - HANDLE_CODE(amf_id.unpack(bref)); + HANDLE_CODE(unpack_integer(ul_bw_part_id, bref, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(unpack_integer(pucch_res, bref, (uint8_t)0u, (uint8_t)127u)); return SRSASN_SUCCESS; } -void registered_amf_s::to_json(json_writer& j) const +void pucch_csi_res_s::to_json(json_writer& j) const { j.start_obj(); - if (plmn_id_present) { - j.write_fieldname("plmn-Identity"); - plmn_id.to_json(j); - } - j.write_str("amf-Identifier", amf_id.to_string()); + j.write_int("uplinkBandwidthPartId", ul_bw_part_id); + j.write_int("pucch-Resource", pucch_res); j.end_obj(); } -// S-NSSAI ::= CHOICE -void s_nssai_c::destroy_() +// PortIndexFor8Ranks ::= CHOICE +void port_idx_for8_ranks_c::destroy_() { switch (type_) { - case types::sst: - c.destroy >(); + case types::port_idx8: + c.destroy(); break; - case types::sst_sd: - c.destroy >(); + case types::port_idx4: + c.destroy(); + break; + case types::port_idx2: + c.destroy(); break; default: break; } } -void s_nssai_c::set(types::options e) +void port_idx_for8_ranks_c::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::sst: - c.init >(); + case types::port_idx8: + c.init(); break; - case types::sst_sd: - c.init >(); + case types::port_idx4: + c.init(); + break; + case types::port_idx2: + c.init(); + break; + case types::port_idx1: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "s_nssai_c"); + log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); } } -s_nssai_c::s_nssai_c(const s_nssai_c& other) +port_idx_for8_ranks_c::port_idx_for8_ranks_c(const port_idx_for8_ranks_c& other) { type_ = other.type(); switch (type_) { - case types::sst: - c.init(other.c.get >()); + case types::port_idx8: + c.init(other.c.get()); break; - case types::sst_sd: - c.init(other.c.get >()); + case types::port_idx4: + c.init(other.c.get()); + break; + case types::port_idx2: + c.init(other.c.get()); + break; + case types::port_idx1: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "s_nssai_c"); + log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); } } -s_nssai_c& s_nssai_c::operator=(const s_nssai_c& other) +port_idx_for8_ranks_c& port_idx_for8_ranks_c::operator=(const port_idx_for8_ranks_c& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::sst: - c.set(other.c.get >()); + case types::port_idx8: + c.set(other.c.get()); break; - case types::sst_sd: - c.set(other.c.get >()); + case types::port_idx4: + c.set(other.c.get()); + break; + case types::port_idx2: + c.set(other.c.get()); + break; + case types::port_idx1: break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "s_nssai_c"); + log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); } return *this; } -void s_nssai_c::to_json(json_writer& j) const +void port_idx_for8_ranks_c::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::sst: - j.write_str("sst", c.get >().to_string()); + case types::port_idx8: + j.write_fieldname("portIndex8"); + j.start_obj(); + if (c.get().rank1_minus8_present) { + j.write_int("rank1-8", c.get().rank1_minus8); + } + if (c.get().rank2_minus8_present) { + j.start_array("rank2-8"); + for (const auto& e1 : c.get().rank2_minus8) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank3_minus8_present) { + j.start_array("rank3-8"); + for (const auto& e1 : c.get().rank3_minus8) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank4_minus8_present) { + j.start_array("rank4-8"); + for (const auto& e1 : c.get().rank4_minus8) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank5_minus8_present) { + j.start_array("rank5-8"); + for (const auto& e1 : c.get().rank5_minus8) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank6_minus8_present) { + j.start_array("rank6-8"); + for (const auto& e1 : c.get().rank6_minus8) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank7_minus8_present) { + j.start_array("rank7-8"); + for (const auto& e1 : c.get().rank7_minus8) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank8_minus8_present) { + j.start_array("rank8-8"); + for (const auto& e1 : c.get().rank8_minus8) { + j.write_int(e1); + } + j.end_array(); + } + j.end_obj(); break; - case types::sst_sd: - j.write_str("sst-SD", c.get >().to_string()); + case types::port_idx4: + j.write_fieldname("portIndex4"); + j.start_obj(); + if (c.get().rank1_minus4_present) { + j.write_int("rank1-4", c.get().rank1_minus4); + } + if (c.get().rank2_minus4_present) { + j.start_array("rank2-4"); + for (const auto& e1 : c.get().rank2_minus4) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank3_minus4_present) { + j.start_array("rank3-4"); + for (const auto& e1 : c.get().rank3_minus4) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().rank4_minus4_present) { + j.start_array("rank4-4"); + for (const auto& e1 : c.get().rank4_minus4) { + j.write_int(e1); + } + j.end_array(); + } + j.end_obj(); + break; + case types::port_idx2: + j.write_fieldname("portIndex2"); + j.start_obj(); + if (c.get().rank1_minus2_present) { + j.write_int("rank1-2", c.get().rank1_minus2); + } + if (c.get().rank2_minus2_present) { + j.start_array("rank2-2"); + for (const auto& e1 : c.get().rank2_minus2) { + j.write_int(e1); + } + j.end_array(); + } + j.end_obj(); + break; + case types::port_idx1: break; default: - log_invalid_choice_id(type_, "s_nssai_c"); + log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); } j.end_obj(); } -SRSASN_CODE s_nssai_c::pack(bit_ref& bref) const +SRSASN_CODE port_idx_for8_ranks_c::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::sst: - HANDLE_CODE(c.get >().pack(bref)); + case types::port_idx8: + HANDLE_CODE(bref.pack(c.get().rank1_minus8_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank2_minus8_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank3_minus8_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank4_minus8_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank5_minus8_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank6_minus8_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank7_minus8_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank8_minus8_present, 1)); + if (c.get().rank1_minus8_present) { + HANDLE_CODE(pack_integer(bref, c.get().rank1_minus8, (uint8_t)0u, (uint8_t)7u)); + } + if (c.get().rank2_minus8_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank2_minus8)[0], + c.get().rank2_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank3_minus8_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank3_minus8)[0], + c.get().rank3_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank4_minus8_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank4_minus8)[0], + c.get().rank4_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank5_minus8_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank5_minus8)[0], + c.get().rank5_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank6_minus8_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank6_minus8)[0], + c.get().rank6_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank7_minus8_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank7_minus8)[0], + c.get().rank7_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank8_minus8_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank8_minus8)[0], + c.get().rank8_minus8.size(), + integer_packer(0, 7))); + } break; - case types::sst_sd: - HANDLE_CODE(c.get >().pack(bref)); + case types::port_idx4: + HANDLE_CODE(bref.pack(c.get().rank1_minus4_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank2_minus4_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank3_minus4_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank4_minus4_present, 1)); + if (c.get().rank1_minus4_present) { + HANDLE_CODE(pack_integer(bref, c.get().rank1_minus4, (uint8_t)0u, (uint8_t)3u)); + } + if (c.get().rank2_minus4_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank2_minus4)[0], + c.get().rank2_minus4.size(), + integer_packer(0, 3))); + } + if (c.get().rank3_minus4_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank3_minus4)[0], + c.get().rank3_minus4.size(), + integer_packer(0, 3))); + } + if (c.get().rank4_minus4_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank4_minus4)[0], + c.get().rank4_minus4.size(), + integer_packer(0, 3))); + } + break; + case types::port_idx2: + HANDLE_CODE(bref.pack(c.get().rank1_minus2_present, 1)); + HANDLE_CODE(bref.pack(c.get().rank2_minus2_present, 1)); + if (c.get().rank1_minus2_present) { + HANDLE_CODE(pack_integer(bref, c.get().rank1_minus2, (uint8_t)0u, (uint8_t)1u)); + } + if (c.get().rank2_minus2_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().rank2_minus2)[0], + c.get().rank2_minus2.size(), + integer_packer(0, 1))); + } + break; + case types::port_idx1: break; default: - log_invalid_choice_id(type_, "s_nssai_c"); + log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE s_nssai_c::unpack(cbit_ref& bref) +SRSASN_CODE port_idx_for8_ranks_c::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::sst: - HANDLE_CODE(c.get >().unpack(bref)); + case types::port_idx8: + HANDLE_CODE(bref.unpack(c.get().rank1_minus8_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank2_minus8_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank3_minus8_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank4_minus8_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank5_minus8_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank6_minus8_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank7_minus8_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank8_minus8_present, 1)); + if (c.get().rank1_minus8_present) { + HANDLE_CODE(unpack_integer(c.get().rank1_minus8, bref, (uint8_t)0u, (uint8_t)7u)); + } + if (c.get().rank2_minus8_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank2_minus8)[0], + bref, + c.get().rank2_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank3_minus8_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank3_minus8)[0], + bref, + c.get().rank3_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank4_minus8_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank4_minus8)[0], + bref, + c.get().rank4_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank5_minus8_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank5_minus8)[0], + bref, + c.get().rank5_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank6_minus8_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank6_minus8)[0], + bref, + c.get().rank6_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank7_minus8_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank7_minus8)[0], + bref, + c.get().rank7_minus8.size(), + integer_packer(0, 7))); + } + if (c.get().rank8_minus8_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank8_minus8)[0], + bref, + c.get().rank8_minus8.size(), + integer_packer(0, 7))); + } break; - case types::sst_sd: - HANDLE_CODE(c.get >().unpack(bref)); + case types::port_idx4: + HANDLE_CODE(bref.unpack(c.get().rank1_minus4_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank2_minus4_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank3_minus4_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank4_minus4_present, 1)); + if (c.get().rank1_minus4_present) { + HANDLE_CODE(unpack_integer(c.get().rank1_minus4, bref, (uint8_t)0u, (uint8_t)3u)); + } + if (c.get().rank2_minus4_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank2_minus4)[0], + bref, + c.get().rank2_minus4.size(), + integer_packer(0, 3))); + } + if (c.get().rank3_minus4_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank3_minus4)[0], + bref, + c.get().rank3_minus4.size(), + integer_packer(0, 3))); + } + if (c.get().rank4_minus4_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank4_minus4)[0], + bref, + c.get().rank4_minus4.size(), + integer_packer(0, 3))); + } break; - default: - log_invalid_choice_id(type_, "s_nssai_c"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; -} - -std::string s_nssai_c::types_opts::to_string() const -{ - static const char* options[] = {"sst", "sst-SD"}; - return convert_enum_idx(options, 2, value, "s_nssai_c::types"); -} - -// UEAssistanceInformation-v1540-IEs ::= SEQUENCE -SRSASN_CODE ueassist_info_v1540_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(overheat_assist_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (overheat_assist_present) { - HANDLE_CODE(overheat_assist.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE ueassist_info_v1540_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(overheat_assist_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (overheat_assist_present) { - HANDLE_CODE(overheat_assist.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void ueassist_info_v1540_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (overheat_assist_present) { - j.write_fieldname("overheatingAssistance"); - overheat_assist.to_json(j); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// CounterCheckResponse-IEs ::= SEQUENCE -SRSASN_CODE counter_check_resp_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - HANDLE_CODE(pack_dyn_seq_of(bref, drb_count_info_list, 0, 29)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE counter_check_resp_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(unpack_dyn_seq_of(drb_count_info_list, bref, 0, 29)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void counter_check_resp_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.start_array("drb-CountInfoList"); - for (const auto& e1 : drb_count_info_list) { - e1.to_json(j); - } - j.end_array(); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// FailureInformation-IEs ::= SEQUENCE -SRSASN_CODE fail_info_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(fail_info_rlc_bearer_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (fail_info_rlc_bearer_present) { - HANDLE_CODE(fail_info_rlc_bearer.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE fail_info_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(fail_info_rlc_bearer_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (fail_info_rlc_bearer_present) { - HANDLE_CODE(fail_info_rlc_bearer.unpack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void fail_info_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (fail_info_rlc_bearer_present) { - j.write_fieldname("failureInfoRLC-Bearer"); - fail_info_rlc_bearer.to_json(j); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// LocationMeasurementIndication-IEs ::= SEQUENCE -SRSASN_CODE location_meas_ind_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - HANDLE_CODE(meas_ind.pack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE location_meas_ind_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(meas_ind.unpack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void location_meas_ind_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("measurementIndication"); - meas_ind.to_json(j); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} - -// MeasurementReport-IEs ::= SEQUENCE -SRSASN_CODE meas_report_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - HANDLE_CODE(meas_results.pack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); + case types::port_idx2: + HANDLE_CODE(bref.unpack(c.get().rank1_minus2_present, 1)); + HANDLE_CODE(bref.unpack(c.get().rank2_minus2_present, 1)); + if (c.get().rank1_minus2_present) { + HANDLE_CODE(unpack_integer(c.get().rank1_minus2, bref, (uint8_t)0u, (uint8_t)1u)); + } + if (c.get().rank2_minus2_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().rank2_minus2)[0], + bref, + c.get().rank2_minus2.size(), + integer_packer(0, 1))); + } + break; + case types::port_idx1: + break; + default: + log_invalid_choice_id(type_, "port_idx_for8_ranks_c"); + return SRSASN_ERROR_DECODE_FAIL; } - return SRSASN_SUCCESS; } -SRSASN_CODE meas_report_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(meas_results.unpack(bref)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - return SRSASN_SUCCESS; +std::string port_idx_for8_ranks_c::types_opts::to_string() const +{ + static const char* options[] = {"portIndex8", "portIndex4", "portIndex2", "portIndex1"}; + return convert_enum_idx(options, 4, value, "port_idx_for8_ranks_c::types"); } -void meas_report_ies_s::to_json(json_writer& j) const +uint8_t port_idx_for8_ranks_c::types_opts::to_number() const { - j.start_obj(); - j.write_fieldname("measResults"); - meas_results.to_json(j); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); + static const uint8_t options[] = {8, 4, 2, 1}; + return map_enum_number(options, 4, value, "port_idx_for8_ranks_c::types"); } -// RRCReconfigurationComplete-IEs ::= SEQUENCE -SRSASN_CODE rrc_recfg_complete_ies_s::pack(bit_ref& bref) const +// CSI-ReportConfig ::= SEQUENCE +SRSASN_CODE csi_report_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(carrier_present, 1)); + HANDLE_CODE(bref.pack(csi_im_res_for_interference_present, 1)); + HANDLE_CODE(bref.pack(nzp_csi_rs_res_for_interference_present, 1)); + HANDLE_CODE(bref.pack(report_freq_cfg_present, 1)); + HANDLE_CODE(bref.pack(codebook_cfg_present, 1)); + HANDLE_CODE(bref.pack(dummy_present, 1)); + HANDLE_CODE(bref.pack(cqi_table_present, 1)); + HANDLE_CODE(bref.pack(non_pmi_port_ind_present, 1)); - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); + HANDLE_CODE(pack_integer(bref, report_cfg_id, (uint8_t)0u, (uint8_t)47u)); + if (carrier_present) { + HANDLE_CODE(pack_integer(bref, carrier, (uint8_t)0u, (uint8_t)31u)); } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.pack(bref)); + HANDLE_CODE(pack_integer(bref, res_for_ch_meas, (uint8_t)0u, (uint8_t)111u)); + if (csi_im_res_for_interference_present) { + HANDLE_CODE(pack_integer(bref, csi_im_res_for_interference, (uint8_t)0u, (uint8_t)111u)); } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_recfg_complete_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + if (nzp_csi_rs_res_for_interference_present) { + HANDLE_CODE(pack_integer(bref, nzp_csi_rs_res_for_interference, (uint8_t)0u, (uint8_t)111u)); } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.unpack(bref)); + HANDLE_CODE(report_cfg_type.pack(bref)); + HANDLE_CODE(report_quant.pack(bref)); + if (report_freq_cfg_present) { + HANDLE_CODE(bref.pack(report_freq_cfg.cqi_format_ind_present, 1)); + HANDLE_CODE(bref.pack(report_freq_cfg.pmi_format_ind_present, 1)); + HANDLE_CODE(bref.pack(report_freq_cfg.csi_report_band_present, 1)); + if (report_freq_cfg.cqi_format_ind_present) { + HANDLE_CODE(report_freq_cfg.cqi_format_ind.pack(bref)); + } + if (report_freq_cfg.pmi_format_ind_present) { + HANDLE_CODE(report_freq_cfg.pmi_format_ind.pack(bref)); + } + if (report_freq_cfg.csi_report_band_present) { + HANDLE_CODE(report_freq_cfg.csi_report_band.pack(bref)); + } } - - return SRSASN_SUCCESS; -} -void rrc_recfg_complete_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + HANDLE_CODE(time_restrict_for_ch_meass.pack(bref)); + HANDLE_CODE(time_restrict_for_interference_meass.pack(bref)); + if (codebook_cfg_present) { + HANDLE_CODE(codebook_cfg.pack(bref)); } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - non_crit_ext.to_json(j); + if (dummy_present) { + HANDLE_CODE(dummy.pack(bref)); } - j.end_obj(); -} - -// RRCReestablishmentComplete-IEs ::= SEQUENCE -SRSASN_CODE rrc_reest_complete_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); + HANDLE_CODE(group_based_beam_report.pack(bref)); + if (cqi_table_present) { + HANDLE_CODE(cqi_table.pack(bref)); } - - return SRSASN_SUCCESS; -} -SRSASN_CODE rrc_reest_complete_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + HANDLE_CODE(subband_size.pack(bref)); + if (non_pmi_port_ind_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, non_pmi_port_ind, 1, 128)); } - return SRSASN_SUCCESS; -} -void rrc_reest_complete_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); -} + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= semi_persistent_on_pusch_v1530.is_present(); + group_flags.pack(bref); -// RRCResumeComplete-IEs ::= SEQUENCE -SRSASN_CODE rrc_resume_complete_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(ded_nas_msg_present, 1)); - HANDLE_CODE(bref.pack(sel_plmn_id_present, 1)); - HANDLE_CODE(bref.pack(ul_tx_direct_current_list_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); - if (ded_nas_msg_present) { - HANDLE_CODE(ded_nas_msg.pack(bref)); - } - if (sel_plmn_id_present) { - HANDLE_CODE(pack_integer(bref, sel_plmn_id, (uint8_t)1u, (uint8_t)12u)); - } - if (ul_tx_direct_current_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ul_tx_direct_current_list, 1, 32)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); + HANDLE_CODE(bref.pack(semi_persistent_on_pusch_v1530.is_present(), 1)); + if (semi_persistent_on_pusch_v1530.is_present()) { + HANDLE_CODE(semi_persistent_on_pusch_v1530->report_slot_cfg_v1530.pack(bref)); + } + } } - return SRSASN_SUCCESS; } -SRSASN_CODE rrc_resume_complete_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_report_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(ded_nas_msg_present, 1)); - HANDLE_CODE(bref.unpack(sel_plmn_id_present, 1)); - HANDLE_CODE(bref.unpack(ul_tx_direct_current_list_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(carrier_present, 1)); + HANDLE_CODE(bref.unpack(csi_im_res_for_interference_present, 1)); + HANDLE_CODE(bref.unpack(nzp_csi_rs_res_for_interference_present, 1)); + HANDLE_CODE(bref.unpack(report_freq_cfg_present, 1)); + HANDLE_CODE(bref.unpack(codebook_cfg_present, 1)); + HANDLE_CODE(bref.unpack(dummy_present, 1)); + HANDLE_CODE(bref.unpack(cqi_table_present, 1)); + HANDLE_CODE(bref.unpack(non_pmi_port_ind_present, 1)); - if (ded_nas_msg_present) { - HANDLE_CODE(ded_nas_msg.unpack(bref)); - } - if (sel_plmn_id_present) { - HANDLE_CODE(unpack_integer(sel_plmn_id, bref, (uint8_t)1u, (uint8_t)12u)); + HANDLE_CODE(unpack_integer(report_cfg_id, bref, (uint8_t)0u, (uint8_t)47u)); + if (carrier_present) { + HANDLE_CODE(unpack_integer(carrier, bref, (uint8_t)0u, (uint8_t)31u)); } - if (ul_tx_direct_current_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ul_tx_direct_current_list, bref, 1, 32)); + HANDLE_CODE(unpack_integer(res_for_ch_meas, bref, (uint8_t)0u, (uint8_t)111u)); + if (csi_im_res_for_interference_present) { + HANDLE_CODE(unpack_integer(csi_im_res_for_interference, bref, (uint8_t)0u, (uint8_t)111u)); } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + if (nzp_csi_rs_res_for_interference_present) { + HANDLE_CODE(unpack_integer(nzp_csi_rs_res_for_interference, bref, (uint8_t)0u, (uint8_t)111u)); } - - return SRSASN_SUCCESS; -} -void rrc_resume_complete_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (ded_nas_msg_present) { - j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); + HANDLE_CODE(report_cfg_type.unpack(bref)); + HANDLE_CODE(report_quant.unpack(bref)); + if (report_freq_cfg_present) { + HANDLE_CODE(bref.unpack(report_freq_cfg.cqi_format_ind_present, 1)); + HANDLE_CODE(bref.unpack(report_freq_cfg.pmi_format_ind_present, 1)); + HANDLE_CODE(bref.unpack(report_freq_cfg.csi_report_band_present, 1)); + if (report_freq_cfg.cqi_format_ind_present) { + HANDLE_CODE(report_freq_cfg.cqi_format_ind.unpack(bref)); + } + if (report_freq_cfg.pmi_format_ind_present) { + HANDLE_CODE(report_freq_cfg.pmi_format_ind.unpack(bref)); + } + if (report_freq_cfg.csi_report_band_present) { + HANDLE_CODE(report_freq_cfg.csi_report_band.unpack(bref)); + } } - if (sel_plmn_id_present) { - j.write_int("selectedPLMN-Identity", sel_plmn_id); + HANDLE_CODE(time_restrict_for_ch_meass.unpack(bref)); + HANDLE_CODE(time_restrict_for_interference_meass.unpack(bref)); + if (codebook_cfg_present) { + HANDLE_CODE(codebook_cfg.unpack(bref)); } - if (ul_tx_direct_current_list_present) { - j.start_array("uplinkTxDirectCurrentList"); - for (const auto& e1 : ul_tx_direct_current_list) { - e1.to_json(j); - } - j.end_array(); + if (dummy_present) { + HANDLE_CODE(dummy.unpack(bref)); } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + HANDLE_CODE(group_based_beam_report.unpack(bref)); + if (cqi_table_present) { + HANDLE_CODE(cqi_table.unpack(bref)); } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + HANDLE_CODE(subband_size.unpack(bref)); + if (non_pmi_port_ind_present) { + HANDLE_CODE(unpack_dyn_seq_of(non_pmi_port_ind, bref, 1, 128)); } - j.end_obj(); -} -// RRCSetupComplete-IEs ::= SEQUENCE -SRSASN_CODE rrc_setup_complete_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(registered_amf_present, 1)); - HANDLE_CODE(bref.pack(guami_type_present, 1)); - HANDLE_CODE(bref.pack(s_nssai_list_present, 1)); - HANDLE_CODE(bref.pack(ng_minus5_g_s_tmsi_value_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); - HANDLE_CODE(pack_integer(bref, sel_plmn_id, (uint8_t)1u, (uint8_t)12u)); - if (registered_amf_present) { - HANDLE_CODE(registered_amf.pack(bref)); - } - if (guami_type_present) { - HANDLE_CODE(guami_type.pack(bref)); - } - if (s_nssai_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, s_nssai_list, 1, 8)); - } - HANDLE_CODE(ded_nas_msg.pack(bref)); - if (ng_minus5_g_s_tmsi_value_present) { - HANDLE_CODE(ng_minus5_g_s_tmsi_value.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + bool semi_persistent_on_pusch_v1530_present; + HANDLE_CODE(bref.unpack(semi_persistent_on_pusch_v1530_present, 1)); + semi_persistent_on_pusch_v1530.set_present(semi_persistent_on_pusch_v1530_present); + if (semi_persistent_on_pusch_v1530.is_present()) { + HANDLE_CODE(semi_persistent_on_pusch_v1530->report_slot_cfg_v1530.unpack(bref)); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_setup_complete_ies_s::unpack(cbit_ref& bref) +void csi_report_cfg_s::to_json(json_writer& j) const { - HANDLE_CODE(bref.unpack(registered_amf_present, 1)); - HANDLE_CODE(bref.unpack(guami_type_present, 1)); - HANDLE_CODE(bref.unpack(s_nssai_list_present, 1)); - HANDLE_CODE(bref.unpack(ng_minus5_g_s_tmsi_value_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - HANDLE_CODE(unpack_integer(sel_plmn_id, bref, (uint8_t)1u, (uint8_t)12u)); - if (registered_amf_present) { - HANDLE_CODE(registered_amf.unpack(bref)); + j.start_obj(); + j.write_int("reportConfigId", report_cfg_id); + if (carrier_present) { + j.write_int("carrier", carrier); } - if (guami_type_present) { - HANDLE_CODE(guami_type.unpack(bref)); + j.write_int("resourcesForChannelMeasurement", res_for_ch_meas); + if (csi_im_res_for_interference_present) { + j.write_int("csi-IM-ResourcesForInterference", csi_im_res_for_interference); } - if (s_nssai_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(s_nssai_list, bref, 1, 8)); + if (nzp_csi_rs_res_for_interference_present) { + j.write_int("nzp-CSI-RS-ResourcesForInterference", nzp_csi_rs_res_for_interference); } - HANDLE_CODE(ded_nas_msg.unpack(bref)); - if (ng_minus5_g_s_tmsi_value_present) { - HANDLE_CODE(ng_minus5_g_s_tmsi_value.unpack(bref)); + j.write_fieldname("reportConfigType"); + report_cfg_type.to_json(j); + j.write_fieldname("reportQuantity"); + report_quant.to_json(j); + if (report_freq_cfg_present) { + j.write_fieldname("reportFreqConfiguration"); + j.start_obj(); + if (report_freq_cfg.cqi_format_ind_present) { + j.write_str("cqi-FormatIndicator", report_freq_cfg.cqi_format_ind.to_string()); + } + if (report_freq_cfg.pmi_format_ind_present) { + j.write_str("pmi-FormatIndicator", report_freq_cfg.pmi_format_ind.to_string()); + } + if (report_freq_cfg.csi_report_band_present) { + j.write_fieldname("csi-ReportingBand"); + report_freq_cfg.csi_report_band.to_json(j); + } + j.end_obj(); } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); + j.write_str("timeRestrictionForChannelMeasurements", time_restrict_for_ch_meass.to_string()); + j.write_str("timeRestrictionForInterferenceMeasurements", time_restrict_for_interference_meass.to_string()); + if (codebook_cfg_present) { + j.write_fieldname("codebookConfig"); + codebook_cfg.to_json(j); } - - return SRSASN_SUCCESS; -} -void rrc_setup_complete_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("selectedPLMN-Identity", sel_plmn_id); - if (registered_amf_present) { - j.write_fieldname("registeredAMF"); - registered_amf.to_json(j); + if (dummy_present) { + j.write_str("dummy", dummy.to_string()); } - if (guami_type_present) { - j.write_str("guami-Type", guami_type.to_string()); + j.write_fieldname("groupBasedBeamReporting"); + group_based_beam_report.to_json(j); + if (cqi_table_present) { + j.write_str("cqi-Table", cqi_table.to_string()); } - if (s_nssai_list_present) { - j.start_array("s-NSSAI-List"); - for (const auto& e1 : s_nssai_list) { + j.write_str("subbandSize", subband_size.to_string()); + if (non_pmi_port_ind_present) { + j.start_array("non-PMI-PortIndication"); + for (const auto& e1 : non_pmi_port_ind) { e1.to_json(j); } j.end_array(); } - j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); - if (ng_minus5_g_s_tmsi_value_present) { - j.write_fieldname("ng-5G-S-TMSI-Value"); - ng_minus5_g_s_tmsi_value.to_json(j); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + if (ext) { + if (semi_persistent_on_pusch_v1530.is_present()) { + j.write_fieldname("semiPersistentOnPUSCH-v1530"); + j.start_obj(); + j.write_str("reportSlotConfig-v1530", semi_persistent_on_pusch_v1530->report_slot_cfg_v1530.to_string()); + j.end_obj(); + } } j.end_obj(); } -std::string rrc_setup_complete_ies_s::guami_type_opts::to_string() const -{ - static const char* options[] = {"native", "mapped"}; - return convert_enum_idx(options, 2, value, "rrc_setup_complete_ies_s::guami_type_e_"); -} - -void rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::destroy_() +void csi_report_cfg_s::report_cfg_type_c_::destroy_() { switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.destroy >(); + case types::periodic: + c.destroy(); break; - case types::ng_minus5_g_s_tmsi_part2: - c.destroy >(); + case types::semi_persistent_on_pucch: + c.destroy(); + break; + case types::semi_persistent_on_pusch: + c.destroy(); + break; + case types::aperiodic: + c.destroy(); break; default: break; } } -void rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::set(types::options e) +void csi_report_cfg_s::report_cfg_type_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.init >(); + case types::periodic: + c.init(); break; - case types::ng_minus5_g_s_tmsi_part2: - c.init >(); + case types::semi_persistent_on_pucch: + c.init(); + break; + case types::semi_persistent_on_pusch: + c.init(); + break; + case types::aperiodic: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); } } -rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::ng_minus5_g_s_tmsi_value_c_( - const rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_& other) +csi_report_cfg_s::report_cfg_type_c_::report_cfg_type_c_(const csi_report_cfg_s::report_cfg_type_c_& other) { type_ = other.type(); switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.init(other.c.get >()); + case types::periodic: + c.init(other.c.get()); break; - case types::ng_minus5_g_s_tmsi_part2: - c.init(other.c.get >()); + case types::semi_persistent_on_pucch: + c.init(other.c.get()); + break; + case types::semi_persistent_on_pusch: + c.init(other.c.get()); + break; + case types::aperiodic: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); } } -rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_& rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_:: - operator=(const rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_& other) +csi_report_cfg_s::report_cfg_type_c_& +csi_report_cfg_s::report_cfg_type_c_::operator=(const csi_report_cfg_s::report_cfg_type_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ng_minus5_g_s_tmsi: - c.set(other.c.get >()); + case types::periodic: + c.set(other.c.get()); break; - case types::ng_minus5_g_s_tmsi_part2: - c.set(other.c.get >()); + case types::semi_persistent_on_pucch: + c.set(other.c.get()); + break; + case types::semi_persistent_on_pusch: + c.set(other.c.get()); + break; + case types::aperiodic: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); } return *this; } -void rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::to_json(json_writer& j) const +void csi_report_cfg_s::report_cfg_type_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ng_minus5_g_s_tmsi: - j.write_str("ng-5G-S-TMSI", c.get >().to_string()); + case types::periodic: + j.write_fieldname("periodic"); + j.start_obj(); + j.write_fieldname("reportSlotConfig"); + c.get().report_slot_cfg.to_json(j); + j.start_array("pucch-CSI-ResourceList"); + for (const auto& e1 : c.get().pucch_csi_res_list) { + e1.to_json(j); + } + j.end_array(); + j.end_obj(); + break; + case types::semi_persistent_on_pucch: + j.write_fieldname("semiPersistentOnPUCCH"); + j.start_obj(); + j.write_fieldname("reportSlotConfig"); + c.get().report_slot_cfg.to_json(j); + j.start_array("pucch-CSI-ResourceList"); + for (const auto& e1 : c.get().pucch_csi_res_list) { + e1.to_json(j); + } + j.end_array(); + j.end_obj(); break; - case types::ng_minus5_g_s_tmsi_part2: - j.write_str("ng-5G-S-TMSI-Part2", c.get >().to_string()); + case types::semi_persistent_on_pusch: + j.write_fieldname("semiPersistentOnPUSCH"); + j.start_obj(); + j.write_str("reportSlotConfig", c.get().report_slot_cfg.to_string()); + j.start_array("reportSlotOffsetList"); + for (const auto& e1 : c.get().report_slot_offset_list) { + j.write_int(e1); + } + j.end_array(); + j.write_int("p0alpha", c.get().p0alpha); + j.end_obj(); + break; + case types::aperiodic: + j.write_fieldname("aperiodic"); + j.start_obj(); + j.start_array("reportSlotOffsetList"); + for (const auto& e1 : c.get().report_slot_offset_list) { + j.write_int(e1); + } + j.end_array(); + j.end_obj(); break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); } j.end_obj(); } -SRSASN_CODE rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::pack(bit_ref& bref) const +SRSASN_CODE csi_report_cfg_s::report_cfg_type_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ng_minus5_g_s_tmsi: - HANDLE_CODE(c.get >().pack(bref)); + case types::periodic: + HANDLE_CODE(c.get().report_slot_cfg.pack(bref)); + HANDLE_CODE(pack_dyn_seq_of(bref, c.get().pucch_csi_res_list, 1, 4)); break; - case types::ng_minus5_g_s_tmsi_part2: - HANDLE_CODE(c.get >().pack(bref)); + case types::semi_persistent_on_pucch: + HANDLE_CODE(c.get().report_slot_cfg.pack(bref)); + HANDLE_CODE(pack_dyn_seq_of(bref, c.get().pucch_csi_res_list, 1, 4)); + break; + case types::semi_persistent_on_pusch: + HANDLE_CODE(c.get().report_slot_cfg.pack(bref)); + HANDLE_CODE(pack_dyn_seq_of( + bref, c.get().report_slot_offset_list, 1, 16, integer_packer(0, 32))); + HANDLE_CODE(pack_integer(bref, c.get().p0alpha, (uint8_t)0u, (uint8_t)29u)); + break; + case types::aperiodic: + HANDLE_CODE( + pack_dyn_seq_of(bref, c.get().report_slot_offset_list, 1, 16, integer_packer(0, 32))); break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::unpack(cbit_ref& bref) +SRSASN_CODE csi_report_cfg_s::report_cfg_type_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ng_minus5_g_s_tmsi: - HANDLE_CODE(c.get >().unpack(bref)); + case types::periodic: + HANDLE_CODE(c.get().report_slot_cfg.unpack(bref)); + HANDLE_CODE(unpack_dyn_seq_of(c.get().pucch_csi_res_list, bref, 1, 4)); break; - case types::ng_minus5_g_s_tmsi_part2: - HANDLE_CODE(c.get >().unpack(bref)); + case types::semi_persistent_on_pucch: + HANDLE_CODE(c.get().report_slot_cfg.unpack(bref)); + HANDLE_CODE(unpack_dyn_seq_of(c.get().pucch_csi_res_list, bref, 1, 4)); + break; + case types::semi_persistent_on_pusch: + HANDLE_CODE(c.get().report_slot_cfg.unpack(bref)); + HANDLE_CODE(unpack_dyn_seq_of( + c.get().report_slot_offset_list, bref, 1, 16, integer_packer(0, 32))); + HANDLE_CODE(unpack_integer(c.get().p0alpha, bref, (uint8_t)0u, (uint8_t)29u)); + break; + case types::aperiodic: + HANDLE_CODE(unpack_dyn_seq_of( + c.get().report_slot_offset_list, bref, 1, 16, integer_packer(0, 32))); break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_cfg_type_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::types_opts::to_string() const +std::string csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_opts::to_string() const { - static const char* options[] = {"ng-5G-S-TMSI", "ng-5G-S-TMSI-Part2"}; - return convert_enum_idx(options, 2, value, "rrc_setup_complete_ies_s::ng_minus5_g_s_tmsi_value_c_::types"); + static const char* options[] = {"sl5", "sl10", "sl20", "sl40", "sl80", "sl160", "sl320"}; + return convert_enum_idx( + options, 7, value, "csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_e_"); } - -// SecurityModeComplete-IEs ::= SEQUENCE -SRSASN_CODE security_mode_complete_ies_s::pack(bit_ref& bref) const +uint16_t csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_opts::to_number() const { - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; + static const uint16_t options[] = {5, 10, 20, 40, 80, 160, 320}; + return map_enum_number( + options, 7, value, "csi_report_cfg_s::report_cfg_type_c_::semi_persistent_on_pusch_s_::report_slot_cfg_e_"); } -SRSASN_CODE security_mode_complete_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - return SRSASN_SUCCESS; -} -void security_mode_complete_ies_s::to_json(json_writer& j) const +std::string csi_report_cfg_s::report_cfg_type_c_::types_opts::to_string() const { - j.start_obj(); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); + static const char* options[] = {"periodic", "semiPersistentOnPUCCH", "semiPersistentOnPUSCH", "aperiodic"}; + return convert_enum_idx(options, 4, value, "csi_report_cfg_s::report_cfg_type_c_::types"); } -// SecurityModeFailure-IEs ::= SEQUENCE -SRSASN_CODE security_mode_fail_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE security_mode_fail_ies_s::unpack(cbit_ref& bref) +void csi_report_cfg_s::report_quant_c_::set(types::options e) { - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; + type_ = e; } -void security_mode_fail_ies_s::to_json(json_writer& j) const +void csi_report_cfg_s::report_quant_c_::to_json(json_writer& j) const { j.start_obj(); - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + switch (type_) { + case types::none: + break; + case types::cri_ri_pmi_cqi: + break; + case types::cri_ri_i1: + break; + case types::cri_ri_i1_cqi: + j.write_fieldname("cri-RI-i1-CQI"); + j.start_obj(); + if (c.pdsch_bundle_size_for_csi_present) { + j.write_str("pdsch-BundleSizeForCSI", c.pdsch_bundle_size_for_csi.to_string()); + } + j.end_obj(); + break; + case types::cri_ri_cqi: + break; + case types::cri_rsrp: + break; + case types::ssb_idx_rsrp: + break; + case types::cri_ri_li_pmi_cqi: + break; + default: + log_invalid_choice_id(type_, "csi_report_cfg_s::report_quant_c_"); } j.end_obj(); } - -// UEAssistanceInformation-IEs ::= SEQUENCE -SRSASN_CODE ueassist_info_ies_s::pack(bit_ref& bref) const +SRSASN_CODE csi_report_cfg_s::report_quant_c_::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(delay_budget_report_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (delay_budget_report_present) { - HANDLE_CODE(delay_budget_report.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.pack(bref)); + type_.pack(bref); + switch (type_) { + case types::none: + break; + case types::cri_ri_pmi_cqi: + break; + case types::cri_ri_i1: + break; + case types::cri_ri_i1_cqi: + HANDLE_CODE(bref.pack(c.pdsch_bundle_size_for_csi_present, 1)); + if (c.pdsch_bundle_size_for_csi_present) { + HANDLE_CODE(c.pdsch_bundle_size_for_csi.pack(bref)); + } + break; + case types::cri_ri_cqi: + break; + case types::cri_rsrp: + break; + case types::ssb_idx_rsrp: + break; + case types::cri_ri_li_pmi_cqi: + break; + default: + log_invalid_choice_id(type_, "csi_report_cfg_s::report_quant_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } - return SRSASN_SUCCESS; } -SRSASN_CODE ueassist_info_ies_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_report_cfg_s::report_quant_c_::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(delay_budget_report_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (delay_budget_report_present) { - HANDLE_CODE(delay_budget_report.unpack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - if (non_crit_ext_present) { - HANDLE_CODE(non_crit_ext.unpack(bref)); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::none: + break; + case types::cri_ri_pmi_cqi: + break; + case types::cri_ri_i1: + break; + case types::cri_ri_i1_cqi: + HANDLE_CODE(bref.unpack(c.pdsch_bundle_size_for_csi_present, 1)); + if (c.pdsch_bundle_size_for_csi_present) { + HANDLE_CODE(c.pdsch_bundle_size_for_csi.unpack(bref)); + } + break; + case types::cri_ri_cqi: + break; + case types::cri_rsrp: + break; + case types::ssb_idx_rsrp: + break; + case types::cri_ri_li_pmi_cqi: + break; + default: + log_invalid_choice_id(type_, "csi_report_cfg_s::report_quant_c_"); + return SRSASN_ERROR_DECODE_FAIL; } - return SRSASN_SUCCESS; } -void ueassist_info_ies_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (delay_budget_report_present) { - j.write_fieldname("delayBudgetReport"); - delay_budget_report.to_json(j); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - non_crit_ext.to_json(j); - } - j.end_obj(); -} - -// UECapabilityInformation-IEs ::= SEQUENCE -SRSASN_CODE ue_cap_info_ies_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(ue_cap_rat_container_list_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (ue_cap_rat_container_list_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, ue_cap_rat_container_list, 0, 8)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - return SRSASN_SUCCESS; -} -SRSASN_CODE ue_cap_info_ies_s::unpack(cbit_ref& bref) +std::string csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_opts::to_string() const { - HANDLE_CODE(bref.unpack(ue_cap_rat_container_list_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (ue_cap_rat_container_list_present) { - HANDLE_CODE(unpack_dyn_seq_of(ue_cap_rat_container_list, bref, 0, 8)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - - return SRSASN_SUCCESS; + static const char* options[] = {"n2", "n4"}; + return convert_enum_idx( + options, 2, value, "csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_e_"); } -void ue_cap_info_ies_s::to_json(json_writer& j) const +uint8_t csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_opts::to_number() const { - j.start_obj(); - if (ue_cap_rat_container_list_present) { - j.start_array("ue-CapabilityRAT-ContainerList"); - for (const auto& e1 : ue_cap_rat_container_list) { - e1.to_json(j); - } - j.end_array(); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); + static const uint8_t options[] = {2, 4}; + return map_enum_number( + options, 2, value, "csi_report_cfg_s::report_quant_c_::cri_ri_i1_cqi_s_::pdsch_bundle_size_for_csi_e_"); } -// ULInformationTransfer-IEs ::= SEQUENCE -SRSASN_CODE ul_info_transfer_ies_s::pack(bit_ref& bref) const +std::string csi_report_cfg_s::report_quant_c_::types_opts::to_string() const { - HANDLE_CODE(bref.pack(ded_nas_msg_present, 1)); - HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - - if (ded_nas_msg_present) { - HANDLE_CODE(ded_nas_msg.pack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.pack(bref)); - } - - return SRSASN_SUCCESS; + static const char* options[] = {"none", + "cri-RI-PMI-CQI", + "cri-RI-i1", + "cri-RI-i1-CQI", + "cri-RI-CQI", + "cri-RSRP", + "ssb-Index-RSRP", + "cri-RI-LI-PMI-CQI"}; + return convert_enum_idx(options, 8, value, "csi_report_cfg_s::report_quant_c_::types"); } -SRSASN_CODE ul_info_transfer_ies_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(ded_nas_msg_present, 1)); - HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); - HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - - if (ded_nas_msg_present) { - HANDLE_CODE(ded_nas_msg.unpack(bref)); - } - if (late_non_crit_ext_present) { - HANDLE_CODE(late_non_crit_ext.unpack(bref)); - } - return SRSASN_SUCCESS; -} -void ul_info_transfer_ies_s::to_json(json_writer& j) const +std::string csi_report_cfg_s::report_freq_cfg_s_::cqi_format_ind_opts::to_string() const { - j.start_obj(); - if (ded_nas_msg_present) { - j.write_str("dedicatedNAS-Message", ded_nas_msg.to_string()); - } - if (late_non_crit_ext_present) { - j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); - } - if (non_crit_ext_present) { - j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); - } - j.end_obj(); + static const char* options[] = {"widebandCQI", "subbandCQI"}; + return convert_enum_idx(options, 2, value, "csi_report_cfg_s::report_freq_cfg_s_::cqi_format_ind_e_"); } -// CounterCheckResponse ::= SEQUENCE -SRSASN_CODE counter_check_resp_s::pack(bit_ref& bref) const +std::string csi_report_cfg_s::report_freq_cfg_s_::pmi_format_ind_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"widebandPMI", "subbandPMI"}; + return convert_enum_idx(options, 2, value, "csi_report_cfg_s::report_freq_cfg_s_::pmi_format_ind_e_"); } -SRSASN_CODE counter_check_resp_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); - return SRSASN_SUCCESS; -} -void counter_check_resp_s::to_json(json_writer& j) const +void csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::destroy_() { - j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); - j.end_obj(); + switch (type_) { + case types::subbands3: + c.destroy >(); + break; + case types::subbands4: + c.destroy >(); + break; + case types::subbands5: + c.destroy >(); + break; + case types::subbands6: + c.destroy >(); + break; + case types::subbands7: + c.destroy >(); + break; + case types::subbands8: + c.destroy >(); + break; + case types::subbands9: + c.destroy >(); + break; + case types::subbands10: + c.destroy >(); + break; + case types::subbands11: + c.destroy >(); + break; + case types::subbands12: + c.destroy >(); + break; + case types::subbands13: + c.destroy >(); + break; + case types::subbands14: + c.destroy >(); + break; + case types::subbands15: + c.destroy >(); + break; + case types::subbands16: + c.destroy >(); + break; + case types::subbands17: + c.destroy >(); + break; + case types::subbands18: + c.destroy >(); + break; + case types::subbands19_v1530: + c.destroy >(); + break; + default: + break; + } } - -void counter_check_resp_s::crit_exts_c_::destroy_() +void csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::set(types::options e) { + destroy_(); + type_ = e; switch (type_) { - case types::counter_check_resp: - c.destroy(); + case types::subbands3: + c.init >(); + break; + case types::subbands4: + c.init >(); + break; + case types::subbands5: + c.init >(); + break; + case types::subbands6: + c.init >(); + break; + case types::subbands7: + c.init >(); + break; + case types::subbands8: + c.init >(); + break; + case types::subbands9: + c.init >(); + break; + case types::subbands10: + c.init >(); + break; + case types::subbands11: + c.init >(); + break; + case types::subbands12: + c.init >(); + break; + case types::subbands13: + c.init >(); + break; + case types::subbands14: + c.init >(); + break; + case types::subbands15: + c.init >(); + break; + case types::subbands16: + c.init >(); break; - default: + case types::subbands17: + c.init >(); break; - } -} -void counter_check_resp_s::crit_exts_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::counter_check_resp: - c.init(); + case types::subbands18: + c.init >(); break; - case types::crit_exts_future: + case types::subbands19_v1530: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); } } -counter_check_resp_s::crit_exts_c_::crit_exts_c_(const counter_check_resp_s::crit_exts_c_& other) +csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::csi_report_band_c_( + const csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_& other) { type_ = other.type(); switch (type_) { - case types::counter_check_resp: - c.init(other.c.get()); + case types::subbands3: + c.init(other.c.get >()); break; - case types::crit_exts_future: + case types::subbands4: + c.init(other.c.get >()); + break; + case types::subbands5: + c.init(other.c.get >()); + break; + case types::subbands6: + c.init(other.c.get >()); + break; + case types::subbands7: + c.init(other.c.get >()); + break; + case types::subbands8: + c.init(other.c.get >()); + break; + case types::subbands9: + c.init(other.c.get >()); + break; + case types::subbands10: + c.init(other.c.get >()); + break; + case types::subbands11: + c.init(other.c.get >()); + break; + case types::subbands12: + c.init(other.c.get >()); + break; + case types::subbands13: + c.init(other.c.get >()); + break; + case types::subbands14: + c.init(other.c.get >()); + break; + case types::subbands15: + c.init(other.c.get >()); + break; + case types::subbands16: + c.init(other.c.get >()); + break; + case types::subbands17: + c.init(other.c.get >()); + break; + case types::subbands18: + c.init(other.c.get >()); + break; + case types::subbands19_v1530: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); } } -counter_check_resp_s::crit_exts_c_& counter_check_resp_s::crit_exts_c_:: - operator=(const counter_check_resp_s::crit_exts_c_& other) +csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_& +csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::operator=( + const csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::counter_check_resp: - c.set(other.c.get()); + case types::subbands3: + c.set(other.c.get >()); break; - case types::crit_exts_future: + case types::subbands4: + c.set(other.c.get >()); + break; + case types::subbands5: + c.set(other.c.get >()); + break; + case types::subbands6: + c.set(other.c.get >()); + break; + case types::subbands7: + c.set(other.c.get >()); + break; + case types::subbands8: + c.set(other.c.get >()); + break; + case types::subbands9: + c.set(other.c.get >()); + break; + case types::subbands10: + c.set(other.c.get >()); + break; + case types::subbands11: + c.set(other.c.get >()); + break; + case types::subbands12: + c.set(other.c.get >()); + break; + case types::subbands13: + c.set(other.c.get >()); + break; + case types::subbands14: + c.set(other.c.get >()); + break; + case types::subbands15: + c.set(other.c.get >()); + break; + case types::subbands16: + c.set(other.c.get >()); + break; + case types::subbands17: + c.set(other.c.get >()); + break; + case types::subbands18: + c.set(other.c.get >()); + break; + case types::subbands19_v1530: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); } return *this; } -void counter_check_resp_s::crit_exts_c_::to_json(json_writer& j) const +void csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::counter_check_resp: - j.write_fieldname("counterCheckResponse"); - c.get().to_json(j); + case types::subbands3: + j.write_str("subbands3", c.get >().to_string()); break; - case types::crit_exts_future: + case types::subbands4: + j.write_str("subbands4", c.get >().to_string()); break; - default: - log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); - } - j.end_obj(); -} -SRSASN_CODE counter_check_resp_s::crit_exts_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::counter_check_resp: - HANDLE_CODE(c.get().pack(bref)); + case types::subbands5: + j.write_str("subbands5", c.get >().to_string()); break; - case types::crit_exts_future: + case types::subbands6: + j.write_str("subbands6", c.get >().to_string()); break; - default: - log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE counter_check_resp_s::crit_exts_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::counter_check_resp: - HANDLE_CODE(c.get().unpack(bref)); + case types::subbands7: + j.write_str("subbands7", c.get >().to_string()); break; - case types::crit_exts_future: + case types::subbands8: + j.write_str("subbands8", c.get >().to_string()); + break; + case types::subbands9: + j.write_str("subbands9", c.get >().to_string()); + break; + case types::subbands10: + j.write_str("subbands10", c.get >().to_string()); + break; + case types::subbands11: + j.write_str("subbands11", c.get >().to_string()); + break; + case types::subbands12: + j.write_str("subbands12", c.get >().to_string()); + break; + case types::subbands13: + j.write_str("subbands13", c.get >().to_string()); + break; + case types::subbands14: + j.write_str("subbands14", c.get >().to_string()); + break; + case types::subbands15: + j.write_str("subbands15", c.get >().to_string()); + break; + case types::subbands16: + j.write_str("subbands16", c.get >().to_string()); + break; + case types::subbands17: + j.write_str("subbands17", c.get >().to_string()); + break; + case types::subbands18: + j.write_str("subbands18", c.get >().to_string()); + break; + case types::subbands19_v1530: + j.write_str("subbands19-v1530", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "counter_check_resp_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; + log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); } - return SRSASN_SUCCESS; -} - -std::string counter_check_resp_s::crit_exts_c_::types_opts::to_string() const -{ - static const char* options[] = {"counterCheckResponse", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "counter_check_resp_s::crit_exts_c_::types"); -} - -// FailureInformation ::= SEQUENCE -SRSASN_CODE fail_info_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE fail_info_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(crit_exts.unpack(bref)); - - return SRSASN_SUCCESS; -} -void fail_info_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); j.end_obj(); } - -void fail_info_s::crit_exts_c_::destroy_() +SRSASN_CODE csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::pack(bit_ref& bref) const { + type_.pack(bref); switch (type_) { - case types::fail_info: - c.destroy(); + case types::subbands3: + HANDLE_CODE(c.get >().pack(bref)); break; - default: + case types::subbands4: + HANDLE_CODE(c.get >().pack(bref)); break; - } -} -void fail_info_s::crit_exts_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::fail_info: - c.init(); + case types::subbands5: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::crit_exts_future: + case types::subbands6: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::nulltype: + case types::subbands7: + HANDLE_CODE(c.get >().pack(bref)); break; - default: - log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); - } -} -fail_info_s::crit_exts_c_::crit_exts_c_(const fail_info_s::crit_exts_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::fail_info: - c.init(other.c.get()); + case types::subbands8: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::crit_exts_future: + case types::subbands9: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::nulltype: + case types::subbands10: + HANDLE_CODE(c.get >().pack(bref)); break; - default: - log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); - } -} -fail_info_s::crit_exts_c_& fail_info_s::crit_exts_c_::operator=(const fail_info_s::crit_exts_c_& other) -{ - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::fail_info: - c.set(other.c.get()); + case types::subbands11: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::crit_exts_future: + case types::subbands12: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::nulltype: + case types::subbands13: + HANDLE_CODE(c.get >().pack(bref)); break; - default: - log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); - } - - return *this; -} -void fail_info_s::crit_exts_c_::to_json(json_writer& j) const -{ - j.start_obj(); - switch (type_) { - case types::fail_info: - j.write_fieldname("failureInformation"); - c.get().to_json(j); + case types::subbands14: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::crit_exts_future: + case types::subbands15: + HANDLE_CODE(c.get >().pack(bref)); break; - default: - log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); - } - j.end_obj(); -} -SRSASN_CODE fail_info_s::crit_exts_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::fail_info: - HANDLE_CODE(c.get().pack(bref)); + case types::subbands16: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::crit_exts_future: + case types::subbands17: + HANDLE_CODE(c.get >().pack(bref)); break; + case types::subbands18: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::subbands19_v1530: { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get >().pack(bref)); + } break; default: - log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE fail_info_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::fail_info: - HANDLE_CODE(c.get().unpack(bref)); + case types::subbands3: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::crit_exts_future: + case types::subbands4: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands5: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands6: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands7: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands8: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands9: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands10: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands11: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands12: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands13: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands14: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands15: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands16: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands17: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::subbands18: + HANDLE_CODE(c.get >().unpack(bref)); break; + case types::subbands19_v1530: { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(c.get >().unpack(bref)); + } break; default: - log_invalid_choice_id(type_, "fail_info_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string fail_info_s::crit_exts_c_::types_opts::to_string() const +std::string csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types_opts::to_string() const { - static const char* options[] = {"failureInformation", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "fail_info_s::crit_exts_c_::types"); + static const char* options[] = {"subbands3", + "subbands4", + "subbands5", + "subbands6", + "subbands7", + "subbands8", + "subbands9", + "subbands10", + "subbands11", + "subbands12", + "subbands13", + "subbands14", + "subbands15", + "subbands16", + "subbands17", + "subbands18", + "subbands19-v1530"}; + return convert_enum_idx(options, 17, value, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types"); } - -// LocationMeasurementIndication ::= SEQUENCE -SRSASN_CODE location_meas_ind_s::pack(bit_ref& bref) const +uint8_t csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types_opts::to_number() const { - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; + static const uint8_t options[] = {3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19}; + return map_enum_number(options, 17, value, "csi_report_cfg_s::report_freq_cfg_s_::csi_report_band_c_::types"); } -SRSASN_CODE location_meas_ind_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(crit_exts.unpack(bref)); - return SRSASN_SUCCESS; -} -void location_meas_ind_s::to_json(json_writer& j) const +std::string csi_report_cfg_s::time_restrict_for_ch_meass_opts::to_string() const { - j.start_obj(); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); - j.end_obj(); + static const char* options[] = {"configured", "notConfigured"}; + return convert_enum_idx(options, 2, value, "csi_report_cfg_s::time_restrict_for_ch_meass_e_"); } -void location_meas_ind_s::crit_exts_c_::destroy_() -{ - switch (type_) { - case types::location_meas_ind: - c.destroy(); - break; - default: - break; - } -} -void location_meas_ind_s::crit_exts_c_::set(types::options e) +std::string csi_report_cfg_s::time_restrict_for_interference_meass_opts::to_string() const { - destroy_(); - type_ = e; - switch (type_) { - case types::location_meas_ind: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); - } + static const char* options[] = {"configured", "notConfigured"}; + return convert_enum_idx(options, 2, value, "csi_report_cfg_s::time_restrict_for_interference_meass_e_"); } -location_meas_ind_s::crit_exts_c_::crit_exts_c_(const location_meas_ind_s::crit_exts_c_& other) + +std::string csi_report_cfg_s::dummy_opts::to_string() const { - type_ = other.type(); - switch (type_) { - case types::location_meas_ind: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); - } + static const char* options[] = {"n1", "n2"}; + return convert_enum_idx(options, 2, value, "csi_report_cfg_s::dummy_e_"); } -location_meas_ind_s::crit_exts_c_& location_meas_ind_s::crit_exts_c_:: - operator=(const location_meas_ind_s::crit_exts_c_& other) +uint8_t csi_report_cfg_s::dummy_opts::to_number() const { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::location_meas_ind: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); - } + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "csi_report_cfg_s::dummy_e_"); +} - return *this; +void csi_report_cfg_s::group_based_beam_report_c_::set(types::options e) +{ + type_ = e; } -void location_meas_ind_s::crit_exts_c_::to_json(json_writer& j) const +void csi_report_cfg_s::group_based_beam_report_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::location_meas_ind: - j.write_fieldname("locationMeasurementIndication"); - c.get().to_json(j); + case types::enabled: break; - case types::crit_exts_future: + case types::disabled: + j.write_fieldname("disabled"); + j.start_obj(); + if (c.nrof_reported_rs_present) { + j.write_str("nrofReportedRS", c.nrof_reported_rs.to_string()); + } + j.end_obj(); break; default: - log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::group_based_beam_report_c_"); } j.end_obj(); } -SRSASN_CODE location_meas_ind_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE csi_report_cfg_s::group_based_beam_report_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::location_meas_ind: - HANDLE_CODE(c.get().pack(bref)); + case types::enabled: break; - case types::crit_exts_future: + case types::disabled: + HANDLE_CODE(bref.pack(c.nrof_reported_rs_present, 1)); + if (c.nrof_reported_rs_present) { + HANDLE_CODE(c.nrof_reported_rs.pack(bref)); + } break; default: - log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::group_based_beam_report_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE location_meas_ind_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE csi_report_cfg_s::group_based_beam_report_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::location_meas_ind: - HANDLE_CODE(c.get().unpack(bref)); + case types::enabled: break; - case types::crit_exts_future: + case types::disabled: + HANDLE_CODE(bref.unpack(c.nrof_reported_rs_present, 1)); + if (c.nrof_reported_rs_present) { + HANDLE_CODE(c.nrof_reported_rs.unpack(bref)); + } break; default: - log_invalid_choice_id(type_, "location_meas_ind_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_report_cfg_s::group_based_beam_report_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string location_meas_ind_s::crit_exts_c_::types_opts::to_string() const +std::string csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_opts::to_string() const { - static const char* options[] = {"locationMeasurementIndication", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "location_meas_ind_s::crit_exts_c_::types"); + static const char* options[] = {"n1", "n2", "n3", "n4"}; + return convert_enum_idx( + options, 4, value, "csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_e_"); } - -// MeasurementReport ::= SEQUENCE -SRSASN_CODE meas_report_s::pack(bit_ref& bref) const +uint8_t csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_opts::to_number() const { - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; + static const uint8_t options[] = {1, 2, 3, 4}; + return map_enum_number( + options, 4, value, "csi_report_cfg_s::group_based_beam_report_c_::disabled_s_::nrof_reported_rs_e_"); } -SRSASN_CODE meas_report_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(crit_exts.unpack(bref)); - return SRSASN_SUCCESS; -} -void meas_report_s::to_json(json_writer& j) const +std::string csi_report_cfg_s::group_based_beam_report_c_::types_opts::to_string() const { - j.start_obj(); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); - j.end_obj(); + static const char* options[] = {"enabled", "disabled"}; + return convert_enum_idx(options, 2, value, "csi_report_cfg_s::group_based_beam_report_c_::types"); } -void meas_report_s::crit_exts_c_::destroy_() -{ - switch (type_) { - case types::meas_report: - c.destroy(); - break; - default: - break; - } -} -void meas_report_s::crit_exts_c_::set(types::options e) +std::string csi_report_cfg_s::cqi_table_opts::to_string() const { - destroy_(); - type_ = e; - switch (type_) { - case types::meas_report: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); - } + static const char* options[] = {"table1", "table2", "table3", "spare1"}; + return convert_enum_idx(options, 4, value, "csi_report_cfg_s::cqi_table_e_"); } -meas_report_s::crit_exts_c_::crit_exts_c_(const meas_report_s::crit_exts_c_& other) +uint8_t csi_report_cfg_s::cqi_table_opts::to_number() const { - type_ = other.type(); - switch (type_) { - case types::meas_report: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); - } + static const uint8_t options[] = {1, 2, 3}; + return map_enum_number(options, 3, value, "csi_report_cfg_s::cqi_table_e_"); } -meas_report_s::crit_exts_c_& meas_report_s::crit_exts_c_::operator=(const meas_report_s::crit_exts_c_& other) -{ - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::meas_report: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); - } - return *this; -} -void meas_report_s::crit_exts_c_::to_json(json_writer& j) const +std::string csi_report_cfg_s::subband_size_opts::to_string() const { - j.start_obj(); - switch (type_) { - case types::meas_report: - j.write_fieldname("measurementReport"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); - } - j.end_obj(); + static const char* options[] = {"value1", "value2"}; + return convert_enum_idx(options, 2, value, "csi_report_cfg_s::subband_size_e_"); } -SRSASN_CODE meas_report_s::crit_exts_c_::pack(bit_ref& bref) const +uint8_t csi_report_cfg_s::subband_size_opts::to_number() const { - type_.pack(bref); - switch (type_) { - case types::meas_report: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const uint8_t options[] = {1, 2}; + return map_enum_number(options, 2, value, "csi_report_cfg_s::subband_size_e_"); } -SRSASN_CODE meas_report_s::crit_exts_c_::unpack(cbit_ref& bref) + +std::string csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_opts::to_string() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::meas_report: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "meas_report_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"sl4", "sl8", "sl16"}; + return convert_enum_idx( + options, 3, value, "csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_e_"); } - -std::string meas_report_s::crit_exts_c_::types_opts::to_string() const +uint8_t csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_opts::to_number() const { - static const char* options[] = {"measurementReport", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "meas_report_s::crit_exts_c_::types"); + static const uint8_t options[] = {4, 8, 16}; + return map_enum_number( + options, 3, value, "csi_report_cfg_s::semi_persistent_on_pusch_v1530_s_::report_slot_cfg_v1530_e_"); } -// RRCReconfigurationComplete ::= SEQUENCE -SRSASN_CODE rrc_recfg_complete_s::pack(bit_ref& bref) const +// CSI-ResourceConfig ::= SEQUENCE +SRSASN_CODE csi_res_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, csi_res_cfg_id, (uint8_t)0u, (uint8_t)111u)); + HANDLE_CODE(csi_rs_res_set_list.pack(bref)); + HANDLE_CODE(pack_integer(bref, bwp_id, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(res_type.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE rrc_recfg_complete_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_res_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(csi_res_cfg_id, bref, (uint8_t)0u, (uint8_t)111u)); + HANDLE_CODE(csi_rs_res_set_list.unpack(bref)); + HANDLE_CODE(unpack_integer(bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); + HANDLE_CODE(res_type.unpack(bref)); return SRSASN_SUCCESS; } -void rrc_recfg_complete_s::to_json(json_writer& j) const +void csi_res_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("csi-ResourceConfigId", csi_res_cfg_id); + j.write_fieldname("csi-RS-ResourceSetList"); + csi_rs_res_set_list.to_json(j); + j.write_int("bwp-Id", bwp_id); + j.write_str("resourceType", res_type.to_string()); j.end_obj(); } -void rrc_recfg_complete_s::crit_exts_c_::destroy_() +void csi_res_cfg_s::csi_rs_res_set_list_c_::destroy_() { switch (type_) { - case types::rrc_recfg_complete: - c.destroy(); + case types::nzp_csi_rs_ssb: + c.destroy(); + break; + case types::csi_im_res_set_list: + c.destroy(); break; default: break; } } -void rrc_recfg_complete_s::crit_exts_c_::set(types::options e) +void csi_res_cfg_s::csi_rs_res_set_list_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::rrc_recfg_complete: - c.init(); + case types::nzp_csi_rs_ssb: + c.init(); break; - case types::crit_exts_future: + case types::csi_im_res_set_list: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); } } -rrc_recfg_complete_s::crit_exts_c_::crit_exts_c_(const rrc_recfg_complete_s::crit_exts_c_& other) +csi_res_cfg_s::csi_rs_res_set_list_c_::csi_rs_res_set_list_c_(const csi_res_cfg_s::csi_rs_res_set_list_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_recfg_complete: - c.init(other.c.get()); + case types::nzp_csi_rs_ssb: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::csi_im_res_set_list: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); } } -rrc_recfg_complete_s::crit_exts_c_& rrc_recfg_complete_s::crit_exts_c_:: - operator=(const rrc_recfg_complete_s::crit_exts_c_& other) +csi_res_cfg_s::csi_rs_res_set_list_c_& +csi_res_cfg_s::csi_rs_res_set_list_c_::operator=(const csi_res_cfg_s::csi_rs_res_set_list_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_recfg_complete: - c.set(other.c.get()); + case types::nzp_csi_rs_ssb: + c.set(other.c.get()); break; - case types::crit_exts_future: + case types::csi_im_res_set_list: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); } return *this; } -void rrc_recfg_complete_s::crit_exts_c_::to_json(json_writer& j) const +void csi_res_cfg_s::csi_rs_res_set_list_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_recfg_complete: - j.write_fieldname("rrcReconfigurationComplete"); - c.get().to_json(j); + case types::nzp_csi_rs_ssb: + j.write_fieldname("nzp-CSI-RS-SSB"); + j.start_obj(); + if (c.get().nzp_csi_rs_res_set_list_present) { + j.start_array("nzp-CSI-RS-ResourceSetList"); + for (const auto& e1 : c.get().nzp_csi_rs_res_set_list) { + j.write_int(e1); + } + j.end_array(); + } + if (c.get().csi_ssb_res_set_list_present) { + j.start_array("csi-SSB-ResourceSetList"); + for (const auto& e1 : c.get().csi_ssb_res_set_list) { + j.write_int(e1); + } + j.end_array(); + } + j.end_obj(); break; - case types::crit_exts_future: + case types::csi_im_res_set_list: + j.start_array("csi-IM-ResourceSetList"); + for (const auto& e1 : c.get()) { + j.write_int(e1); + } + j.end_array(); break; default: - log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); } j.end_obj(); } -SRSASN_CODE rrc_recfg_complete_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE csi_res_cfg_s::csi_rs_res_set_list_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_recfg_complete: - HANDLE_CODE(c.get().pack(bref)); + case types::nzp_csi_rs_ssb: + HANDLE_CODE(bref.pack(c.get().nzp_csi_rs_res_set_list_present, 1)); + HANDLE_CODE(bref.pack(c.get().csi_ssb_res_set_list_present, 1)); + if (c.get().nzp_csi_rs_res_set_list_present) { + HANDLE_CODE(pack_dyn_seq_of( + bref, c.get().nzp_csi_rs_res_set_list, 1, 16, integer_packer(0, 63))); + } + if (c.get().csi_ssb_res_set_list_present) { + HANDLE_CODE(pack_fixed_seq_of(bref, + &(c.get().csi_ssb_res_set_list)[0], + c.get().csi_ssb_res_set_list.size(), + integer_packer(0, 63))); + } break; - case types::crit_exts_future: + case types::csi_im_res_set_list: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 16, integer_packer(0, 63))); break; default: - log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_recfg_complete_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE csi_res_cfg_s::csi_rs_res_set_list_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_recfg_complete: - HANDLE_CODE(c.get().unpack(bref)); + case types::nzp_csi_rs_ssb: + HANDLE_CODE(bref.unpack(c.get().nzp_csi_rs_res_set_list_present, 1)); + HANDLE_CODE(bref.unpack(c.get().csi_ssb_res_set_list_present, 1)); + if (c.get().nzp_csi_rs_res_set_list_present) { + HANDLE_CODE(unpack_dyn_seq_of( + c.get().nzp_csi_rs_res_set_list, bref, 1, 16, integer_packer(0, 63))); + } + if (c.get().csi_ssb_res_set_list_present) { + HANDLE_CODE(unpack_fixed_seq_of(&(c.get().csi_ssb_res_set_list)[0], + bref, + c.get().csi_ssb_res_set_list.size(), + integer_packer(0, 63))); + } break; - case types::crit_exts_future: + case types::csi_im_res_set_list: + HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 16, integer_packer(0, 63))); break; default: - log_invalid_choice_id(type_, "rrc_recfg_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "csi_res_cfg_s::csi_rs_res_set_list_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_recfg_complete_s::crit_exts_c_::types_opts::to_string() const +std::string csi_res_cfg_s::csi_rs_res_set_list_c_::types_opts::to_string() const { - static const char* options[] = {"rrcReconfigurationComplete", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_recfg_complete_s::crit_exts_c_::types"); + static const char* options[] = {"nzp-CSI-RS-SSB", "csi-IM-ResourceSetList"}; + return convert_enum_idx(options, 2, value, "csi_res_cfg_s::csi_rs_res_set_list_c_::types"); } -// RRCReestablishmentComplete ::= SEQUENCE -SRSASN_CODE rrc_reest_complete_s::pack(bit_ref& bref) const +std::string csi_res_cfg_s::res_type_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + static const char* options[] = {"aperiodic", "semiPersistent", "periodic"}; + return convert_enum_idx(options, 3, value, "csi_res_cfg_s::res_type_e_"); +} + +// CSI-SSB-ResourceSet ::= SEQUENCE +SRSASN_CODE csi_ssb_res_set_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_integer(bref, csi_ssb_res_set_id, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_dyn_seq_of(bref, csi_ssb_res_list, 1, 64, integer_packer(0, 63))); return SRSASN_SUCCESS; } -SRSASN_CODE rrc_reest_complete_s::unpack(cbit_ref& bref) +SRSASN_CODE csi_ssb_res_set_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(csi_ssb_res_set_id, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_dyn_seq_of(csi_ssb_res_list, bref, 1, 64, integer_packer(0, 63))); return SRSASN_SUCCESS; } -void rrc_reest_complete_s::to_json(json_writer& j) const +void csi_ssb_res_set_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("csi-SSB-ResourceSetId", csi_ssb_res_set_id); + j.start_array("csi-SSB-ResourceList"); + for (const auto& e1 : csi_ssb_res_list) { + j.write_int(e1); + } + j.end_array(); j.end_obj(); } -void rrc_reest_complete_s::crit_exts_c_::destroy_() -{ - switch (type_) { - case types::rrc_reest_complete: - c.destroy(); - break; - default: - break; - } -} -void rrc_reest_complete_s::crit_exts_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::rrc_reest_complete: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); - } -} -rrc_reest_complete_s::crit_exts_c_::crit_exts_c_(const rrc_reest_complete_s::crit_exts_c_& other) +// NZP-CSI-RS-Resource ::= SEQUENCE +SRSASN_CODE nzp_csi_rs_res_s::pack(bit_ref& bref) const { - type_ = other.type(); - switch (type_) { - case types::rrc_reest_complete: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(pwr_ctrl_offset_ss_present, 1)); + HANDLE_CODE(bref.pack(periodicity_and_offset_present, 1)); + HANDLE_CODE(bref.pack(qcl_info_periodic_csi_rs_present, 1)); + + HANDLE_CODE(pack_integer(bref, nzp_csi_rs_res_id, (uint8_t)0u, (uint8_t)191u)); + HANDLE_CODE(res_map.pack(bref)); + HANDLE_CODE(pack_integer(bref, pwr_ctrl_offset, (int8_t)-8, (int8_t)15)); + if (pwr_ctrl_offset_ss_present) { + HANDLE_CODE(pwr_ctrl_offset_ss.pack(bref)); } -} -rrc_reest_complete_s::crit_exts_c_& rrc_reest_complete_s::crit_exts_c_:: - operator=(const rrc_reest_complete_s::crit_exts_c_& other) -{ - if (this == &other) { - return *this; + HANDLE_CODE(pack_integer(bref, scrambling_id, (uint16_t)0u, (uint16_t)1023u)); + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.pack(bref)); } - set(other.type()); - switch (type_) { - case types::rrc_reest_complete: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); + if (qcl_info_periodic_csi_rs_present) { + HANDLE_CODE(pack_integer(bref, qcl_info_periodic_csi_rs, (uint8_t)0u, (uint8_t)127u)); } - return *this; -} -void rrc_reest_complete_s::crit_exts_c_::to_json(json_writer& j) const -{ - j.start_obj(); - switch (type_) { - case types::rrc_reest_complete: - j.write_fieldname("rrcReestablishmentComplete"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); - } - j.end_obj(); -} -SRSASN_CODE rrc_reest_complete_s::crit_exts_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::rrc_reest_complete: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_reest_complete_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE nzp_csi_rs_res_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::rrc_reest_complete: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_reest_complete_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(pwr_ctrl_offset_ss_present, 1)); + HANDLE_CODE(bref.unpack(periodicity_and_offset_present, 1)); + HANDLE_CODE(bref.unpack(qcl_info_periodic_csi_rs_present, 1)); + + HANDLE_CODE(unpack_integer(nzp_csi_rs_res_id, bref, (uint8_t)0u, (uint8_t)191u)); + HANDLE_CODE(res_map.unpack(bref)); + HANDLE_CODE(unpack_integer(pwr_ctrl_offset, bref, (int8_t)-8, (int8_t)15)); + if (pwr_ctrl_offset_ss_present) { + HANDLE_CODE(pwr_ctrl_offset_ss.unpack(bref)); + } + HANDLE_CODE(unpack_integer(scrambling_id, bref, (uint16_t)0u, (uint16_t)1023u)); + if (periodicity_and_offset_present) { + HANDLE_CODE(periodicity_and_offset.unpack(bref)); } + if (qcl_info_periodic_csi_rs_present) { + HANDLE_CODE(unpack_integer(qcl_info_periodic_csi_rs, bref, (uint8_t)0u, (uint8_t)127u)); + } + return SRSASN_SUCCESS; } +void nzp_csi_rs_res_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("nzp-CSI-RS-ResourceId", nzp_csi_rs_res_id); + j.write_fieldname("resourceMapping"); + res_map.to_json(j); + j.write_int("powerControlOffset", pwr_ctrl_offset); + if (pwr_ctrl_offset_ss_present) { + j.write_str("powerControlOffsetSS", pwr_ctrl_offset_ss.to_string()); + } + j.write_int("scramblingID", scrambling_id); + if (periodicity_and_offset_present) { + j.write_fieldname("periodicityAndOffset"); + periodicity_and_offset.to_json(j); + } + if (qcl_info_periodic_csi_rs_present) { + j.write_int("qcl-InfoPeriodicCSI-RS", qcl_info_periodic_csi_rs); + } + j.end_obj(); +} -std::string rrc_reest_complete_s::crit_exts_c_::types_opts::to_string() const +std::string nzp_csi_rs_res_s::pwr_ctrl_offset_ss_opts::to_string() const { - static const char* options[] = {"rrcReestablishmentComplete", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_reest_complete_s::crit_exts_c_::types"); + static const char* options[] = {"db-3", "db0", "db3", "db6"}; + return convert_enum_idx(options, 4, value, "nzp_csi_rs_res_s::pwr_ctrl_offset_ss_e_"); +} +int8_t nzp_csi_rs_res_s::pwr_ctrl_offset_ss_opts::to_number() const +{ + static const int8_t options[] = {-3, 0, 3, 6}; + return map_enum_number(options, 4, value, "nzp_csi_rs_res_s::pwr_ctrl_offset_ss_e_"); } -// RRCResumeComplete ::= SEQUENCE -SRSASN_CODE rrc_resume_complete_s::pack(bit_ref& bref) const +// NZP-CSI-RS-ResourceSet ::= SEQUENCE +SRSASN_CODE nzp_csi_rs_res_set_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(repeat_present, 1)); + HANDLE_CODE(bref.pack(aperiodic_trigger_offset_present, 1)); + HANDLE_CODE(bref.pack(trs_info_present, 1)); + + HANDLE_CODE(pack_integer(bref, nzp_csi_res_set_id, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res, 1, 64, integer_packer(0, 191))); + if (repeat_present) { + HANDLE_CODE(repeat.pack(bref)); + } + if (aperiodic_trigger_offset_present) { + HANDLE_CODE(pack_integer(bref, aperiodic_trigger_offset, (uint8_t)0u, (uint8_t)6u)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_resume_complete_s::unpack(cbit_ref& bref) +SRSASN_CODE nzp_csi_rs_res_set_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(repeat_present, 1)); + HANDLE_CODE(bref.unpack(aperiodic_trigger_offset_present, 1)); + HANDLE_CODE(bref.unpack(trs_info_present, 1)); + + HANDLE_CODE(unpack_integer(nzp_csi_res_set_id, bref, (uint8_t)0u, (uint8_t)63u)); + HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res, bref, 1, 64, integer_packer(0, 191))); + if (repeat_present) { + HANDLE_CODE(repeat.unpack(bref)); + } + if (aperiodic_trigger_offset_present) { + HANDLE_CODE(unpack_integer(aperiodic_trigger_offset, bref, (uint8_t)0u, (uint8_t)6u)); + } return SRSASN_SUCCESS; } -void rrc_resume_complete_s::to_json(json_writer& j) const +void nzp_csi_rs_res_set_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("nzp-CSI-ResourceSetId", nzp_csi_res_set_id); + j.start_array("nzp-CSI-RS-Resources"); + for (const auto& e1 : nzp_csi_rs_res) { + j.write_int(e1); + } + j.end_array(); + if (repeat_present) { + j.write_str("repetition", repeat.to_string()); + } + if (aperiodic_trigger_offset_present) { + j.write_int("aperiodicTriggeringOffset", aperiodic_trigger_offset); + } + if (trs_info_present) { + j.write_str("trs-Info", "true"); + } j.end_obj(); } -void rrc_resume_complete_s::crit_exts_c_::destroy_() +std::string nzp_csi_rs_res_set_s::repeat_opts::to_string() const { - switch (type_) { - case types::rrc_resume_complete: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"on", "off"}; + return convert_enum_idx(options, 2, value, "nzp_csi_rs_res_set_s::repeat_e_"); } -void rrc_resume_complete_s::crit_exts_c_::set(types::options e) + +// CSI-MeasConfig ::= SEQUENCE +SRSASN_CODE csi_meas_cfg_s::pack(bit_ref& bref) const { - destroy_(); - type_ = e; - switch (type_) { - case types::rrc_resume_complete: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(nzp_csi_rs_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(nzp_csi_rs_res_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(nzp_csi_rs_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(nzp_csi_rs_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(csi_im_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(csi_im_res_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(csi_im_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(csi_im_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(csi_ssb_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(csi_ssb_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(csi_res_cfg_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(csi_res_cfg_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(csi_report_cfg_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(csi_report_cfg_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(report_trigger_size_present, 1)); + HANDLE_CODE(bref.pack(aperiodic_trigger_state_list_present, 1)); + HANDLE_CODE(bref.pack(semi_persistent_on_pusch_trigger_state_list_present, 1)); + + if (nzp_csi_rs_res_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_to_add_mod_list, 1, 192)); } -} -rrc_resume_complete_s::crit_exts_c_::crit_exts_c_(const rrc_resume_complete_s::crit_exts_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::rrc_resume_complete: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); + if (nzp_csi_rs_res_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_to_release_list, 1, 192, integer_packer(0, 191))); } -} -rrc_resume_complete_s::crit_exts_c_& rrc_resume_complete_s::crit_exts_c_:: - operator=(const rrc_resume_complete_s::crit_exts_c_& other) -{ - if (this == &other) { - return *this; + if (nzp_csi_rs_res_set_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_set_to_add_mod_list, 1, 64)); } - set(other.type()); - switch (type_) { - case types::rrc_resume_complete: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); + if (nzp_csi_rs_res_set_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, nzp_csi_rs_res_set_to_release_list, 1, 64, integer_packer(0, 63))); + } + if (csi_im_res_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_to_add_mod_list, 1, 32)); + } + if (csi_im_res_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_to_release_list, 1, 32, integer_packer(0, 31))); + } + if (csi_im_res_set_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_set_to_add_mod_list, 1, 64)); + } + if (csi_im_res_set_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_im_res_set_to_release_list, 1, 64, integer_packer(0, 63))); + } + if (csi_ssb_res_set_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_ssb_res_set_to_add_mod_list, 1, 64)); + } + if (csi_ssb_res_set_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_ssb_res_set_to_release_list, 1, 64, integer_packer(0, 63))); + } + if (csi_res_cfg_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_res_cfg_to_add_mod_list, 1, 112)); + } + if (csi_res_cfg_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_res_cfg_to_release_list, 1, 112, integer_packer(0, 111))); + } + if (csi_report_cfg_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_report_cfg_to_add_mod_list, 1, 48)); + } + if (csi_report_cfg_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, csi_report_cfg_to_release_list, 1, 48, integer_packer(0, 47))); + } + if (report_trigger_size_present) { + HANDLE_CODE(pack_integer(bref, report_trigger_size, (uint8_t)0u, (uint8_t)6u)); + } + if (aperiodic_trigger_state_list_present) { + HANDLE_CODE(aperiodic_trigger_state_list.pack(bref)); + } + if (semi_persistent_on_pusch_trigger_state_list_present) { + HANDLE_CODE(semi_persistent_on_pusch_trigger_state_list.pack(bref)); } - return *this; + return SRSASN_SUCCESS; } -void rrc_resume_complete_s::crit_exts_c_::to_json(json_writer& j) const +SRSASN_CODE csi_meas_cfg_s::unpack(cbit_ref& bref) { - j.start_obj(); - switch (type_) { - case types::rrc_resume_complete: - j.write_fieldname("rrcResumeComplete"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(nzp_csi_rs_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(nzp_csi_rs_res_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(nzp_csi_rs_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(nzp_csi_rs_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_im_res_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_im_res_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_im_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_im_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_ssb_res_set_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_ssb_res_set_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_res_cfg_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_res_cfg_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_report_cfg_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(csi_report_cfg_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(report_trigger_size_present, 1)); + HANDLE_CODE(bref.unpack(aperiodic_trigger_state_list_present, 1)); + HANDLE_CODE(bref.unpack(semi_persistent_on_pusch_trigger_state_list_present, 1)); + + if (nzp_csi_rs_res_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_to_add_mod_list, bref, 1, 192)); } - j.end_obj(); -} -SRSASN_CODE rrc_resume_complete_s::crit_exts_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::rrc_resume_complete: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + if (nzp_csi_rs_res_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_to_release_list, bref, 1, 192, integer_packer(0, 191))); + } + if (nzp_csi_rs_res_set_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_set_to_add_mod_list, bref, 1, 64)); + } + if (nzp_csi_rs_res_set_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(nzp_csi_rs_res_set_to_release_list, bref, 1, 64, integer_packer(0, 63))); + } + if (csi_im_res_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_to_add_mod_list, bref, 1, 32)); + } + if (csi_im_res_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_to_release_list, bref, 1, 32, integer_packer(0, 31))); + } + if (csi_im_res_set_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_set_to_add_mod_list, bref, 1, 64)); + } + if (csi_im_res_set_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_im_res_set_to_release_list, bref, 1, 64, integer_packer(0, 63))); + } + if (csi_ssb_res_set_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_ssb_res_set_to_add_mod_list, bref, 1, 64)); + } + if (csi_ssb_res_set_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_ssb_res_set_to_release_list, bref, 1, 64, integer_packer(0, 63))); + } + if (csi_res_cfg_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_res_cfg_to_add_mod_list, bref, 1, 112)); + } + if (csi_res_cfg_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_res_cfg_to_release_list, bref, 1, 112, integer_packer(0, 111))); } + if (csi_report_cfg_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_report_cfg_to_add_mod_list, bref, 1, 48)); + } + if (csi_report_cfg_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(csi_report_cfg_to_release_list, bref, 1, 48, integer_packer(0, 47))); + } + if (report_trigger_size_present) { + HANDLE_CODE(unpack_integer(report_trigger_size, bref, (uint8_t)0u, (uint8_t)6u)); + } + if (aperiodic_trigger_state_list_present) { + HANDLE_CODE(aperiodic_trigger_state_list.unpack(bref)); + } + if (semi_persistent_on_pusch_trigger_state_list_present) { + HANDLE_CODE(semi_persistent_on_pusch_trigger_state_list.unpack(bref)); + } + return SRSASN_SUCCESS; } -SRSASN_CODE rrc_resume_complete_s::crit_exts_c_::unpack(cbit_ref& bref) +void csi_meas_cfg_s::to_json(json_writer& j) const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::rrc_resume_complete: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "rrc_resume_complete_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; + j.start_obj(); + if (nzp_csi_rs_res_to_add_mod_list_present) { + j.start_array("nzp-CSI-RS-ResourceToAddModList"); + for (const auto& e1 : nzp_csi_rs_res_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - return SRSASN_SUCCESS; + if (nzp_csi_rs_res_to_release_list_present) { + j.start_array("nzp-CSI-RS-ResourceToReleaseList"); + for (const auto& e1 : nzp_csi_rs_res_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (nzp_csi_rs_res_set_to_add_mod_list_present) { + j.start_array("nzp-CSI-RS-ResourceSetToAddModList"); + for (const auto& e1 : nzp_csi_rs_res_set_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (nzp_csi_rs_res_set_to_release_list_present) { + j.start_array("nzp-CSI-RS-ResourceSetToReleaseList"); + for (const auto& e1 : nzp_csi_rs_res_set_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (csi_im_res_to_add_mod_list_present) { + j.start_array("csi-IM-ResourceToAddModList"); + for (const auto& e1 : csi_im_res_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (csi_im_res_to_release_list_present) { + j.start_array("csi-IM-ResourceToReleaseList"); + for (const auto& e1 : csi_im_res_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (csi_im_res_set_to_add_mod_list_present) { + j.start_array("csi-IM-ResourceSetToAddModList"); + for (const auto& e1 : csi_im_res_set_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (csi_im_res_set_to_release_list_present) { + j.start_array("csi-IM-ResourceSetToReleaseList"); + for (const auto& e1 : csi_im_res_set_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (csi_ssb_res_set_to_add_mod_list_present) { + j.start_array("csi-SSB-ResourceSetToAddModList"); + for (const auto& e1 : csi_ssb_res_set_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (csi_ssb_res_set_to_release_list_present) { + j.start_array("csi-SSB-ResourceSetToReleaseList"); + for (const auto& e1 : csi_ssb_res_set_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (csi_res_cfg_to_add_mod_list_present) { + j.start_array("csi-ResourceConfigToAddModList"); + for (const auto& e1 : csi_res_cfg_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (csi_res_cfg_to_release_list_present) { + j.start_array("csi-ResourceConfigToReleaseList"); + for (const auto& e1 : csi_res_cfg_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (csi_report_cfg_to_add_mod_list_present) { + j.start_array("csi-ReportConfigToAddModList"); + for (const auto& e1 : csi_report_cfg_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (csi_report_cfg_to_release_list_present) { + j.start_array("csi-ReportConfigToReleaseList"); + for (const auto& e1 : csi_report_cfg_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (report_trigger_size_present) { + j.write_int("reportTriggerSize", report_trigger_size); + } + if (aperiodic_trigger_state_list_present) { + j.write_fieldname("aperiodicTriggerStateList"); + aperiodic_trigger_state_list.to_json(j); + } + if (semi_persistent_on_pusch_trigger_state_list_present) { + j.write_fieldname("semiPersistentOnPUSCH-TriggerStateList"); + semi_persistent_on_pusch_trigger_state_list.to_json(j); + } + j.end_obj(); } -std::string rrc_resume_complete_s::crit_exts_c_::types_opts::to_string() const +// EUTRA-MBSFN-SubframeConfig ::= SEQUENCE +SRSASN_CODE eutra_mbsfn_sf_cfg_s::pack(bit_ref& bref) const { - static const char* options[] = {"rrcResumeComplete", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_resume_complete_s::crit_exts_c_::types"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(sf_alloc2_present, 1)); -// RRCSetupComplete ::= SEQUENCE -SRSASN_CODE rrc_setup_complete_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + HANDLE_CODE(radioframe_alloc_period.pack(bref)); + HANDLE_CODE(pack_integer(bref, radioframe_alloc_offset, (uint8_t)0u, (uint8_t)7u)); + HANDLE_CODE(sf_alloc1.pack(bref)); + if (sf_alloc2_present) { + HANDLE_CODE(sf_alloc2.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_setup_complete_s::unpack(cbit_ref& bref) +SRSASN_CODE eutra_mbsfn_sf_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(sf_alloc2_present, 1)); + + HANDLE_CODE(radioframe_alloc_period.unpack(bref)); + HANDLE_CODE(unpack_integer(radioframe_alloc_offset, bref, (uint8_t)0u, (uint8_t)7u)); + HANDLE_CODE(sf_alloc1.unpack(bref)); + if (sf_alloc2_present) { + HANDLE_CODE(sf_alloc2.unpack(bref)); + } return SRSASN_SUCCESS; } -void rrc_setup_complete_s::to_json(json_writer& j) const +void eutra_mbsfn_sf_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_str("radioframeAllocationPeriod", radioframe_alloc_period.to_string()); + j.write_int("radioframeAllocationOffset", radioframe_alloc_offset); + j.write_fieldname("subframeAllocation1"); + sf_alloc1.to_json(j); + if (sf_alloc2_present) { + j.write_fieldname("subframeAllocation2"); + sf_alloc2.to_json(j); + } j.end_obj(); } -void rrc_setup_complete_s::crit_exts_c_::destroy_() +std::string eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_opts::to_string() const +{ + static const char* options[] = {"n1", "n2", "n4", "n8", "n16", "n32"}; + return convert_enum_idx(options, 6, value, "eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_e_"); +} +uint8_t eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 4, 8, 16, 32}; + return map_enum_number(options, 6, value, "eutra_mbsfn_sf_cfg_s::radioframe_alloc_period_e_"); +} + +void eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::destroy_() { switch (type_) { - case types::rrc_setup_complete: - c.destroy(); + case types::one_frame: + c.destroy >(); + break; + case types::four_frames: + c.destroy >(); break; default: break; } } -void rrc_setup_complete_s::crit_exts_c_::set(types::options e) +void eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::rrc_setup_complete: - c.init(); + case types::one_frame: + c.init >(); break; - case types::crit_exts_future: + case types::four_frames: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); } } -rrc_setup_complete_s::crit_exts_c_::crit_exts_c_(const rrc_setup_complete_s::crit_exts_c_& other) +eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::sf_alloc1_c_(const eutra_mbsfn_sf_cfg_s::sf_alloc1_c_& other) { type_ = other.type(); switch (type_) { - case types::rrc_setup_complete: - c.init(other.c.get()); + case types::one_frame: + c.init(other.c.get >()); break; - case types::crit_exts_future: + case types::four_frames: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); } } -rrc_setup_complete_s::crit_exts_c_& rrc_setup_complete_s::crit_exts_c_:: - operator=(const rrc_setup_complete_s::crit_exts_c_& other) +eutra_mbsfn_sf_cfg_s::sf_alloc1_c_& +eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::operator=(const eutra_mbsfn_sf_cfg_s::sf_alloc1_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::rrc_setup_complete: - c.set(other.c.get()); + case types::one_frame: + c.set(other.c.get >()); break; - case types::crit_exts_future: + case types::four_frames: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); } return *this; } -void rrc_setup_complete_s::crit_exts_c_::to_json(json_writer& j) const +void eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::rrc_setup_complete: - j.write_fieldname("rrcSetupComplete"); - c.get().to_json(j); + case types::one_frame: + j.write_str("oneFrame", c.get >().to_string()); break; - case types::crit_exts_future: + case types::four_frames: + j.write_str("fourFrames", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); } j.end_obj(); } -SRSASN_CODE rrc_setup_complete_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::rrc_setup_complete: - HANDLE_CODE(c.get().pack(bref)); + case types::one_frame: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::crit_exts_future: + case types::four_frames: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE rrc_setup_complete_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::rrc_setup_complete: - HANDLE_CODE(c.get().unpack(bref)); + case types::one_frame: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::crit_exts_future: + case types::four_frames: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "rrc_setup_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string rrc_setup_complete_s::crit_exts_c_::types_opts::to_string() const -{ - static const char* options[] = {"rrcSetupComplete", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "rrc_setup_complete_s::crit_exts_c_::types"); -} - -// SecurityModeComplete ::= SEQUENCE -SRSASN_CODE security_mode_complete_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE security_mode_complete_s::unpack(cbit_ref& bref) +std::string eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types_opts::to_string() const { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); - - return SRSASN_SUCCESS; + static const char* options[] = {"oneFrame", "fourFrames"}; + return convert_enum_idx(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types"); } -void security_mode_complete_s::to_json(json_writer& j) const +uint8_t eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types_opts::to_number() const { - j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); - j.end_obj(); + static const uint8_t options[] = {1, 4}; + return map_enum_number(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc1_c_::types"); } -void security_mode_complete_s::crit_exts_c_::destroy_() +void eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::destroy_() { switch (type_) { - case types::security_mode_complete: - c.destroy(); + case types::one_frame: + c.destroy >(); + break; + case types::four_frames: + c.destroy >(); break; default: break; } } -void security_mode_complete_s::crit_exts_c_::set(types::options e) +void eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::security_mode_complete: - c.init(); + case types::one_frame: + c.init >(); break; - case types::crit_exts_future: + case types::four_frames: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); } } -security_mode_complete_s::crit_exts_c_::crit_exts_c_(const security_mode_complete_s::crit_exts_c_& other) +eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::sf_alloc2_c_(const eutra_mbsfn_sf_cfg_s::sf_alloc2_c_& other) { type_ = other.type(); switch (type_) { - case types::security_mode_complete: - c.init(other.c.get()); + case types::one_frame: + c.init(other.c.get >()); break; - case types::crit_exts_future: + case types::four_frames: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); } } -security_mode_complete_s::crit_exts_c_& security_mode_complete_s::crit_exts_c_:: - operator=(const security_mode_complete_s::crit_exts_c_& other) +eutra_mbsfn_sf_cfg_s::sf_alloc2_c_& +eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::operator=(const eutra_mbsfn_sf_cfg_s::sf_alloc2_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::security_mode_complete: - c.set(other.c.get()); + case types::one_frame: + c.set(other.c.get >()); break; - case types::crit_exts_future: + case types::four_frames: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); } return *this; } -void security_mode_complete_s::crit_exts_c_::to_json(json_writer& j) const +void eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::security_mode_complete: - j.write_fieldname("securityModeComplete"); - c.get().to_json(j); + case types::one_frame: + j.write_str("oneFrame", c.get >().to_string()); break; - case types::crit_exts_future: + case types::four_frames: + j.write_str("fourFrames", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); } j.end_obj(); } -SRSASN_CODE security_mode_complete_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::security_mode_complete: - HANDLE_CODE(c.get().pack(bref)); + case types::one_frame: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::crit_exts_future: + case types::four_frames: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE security_mode_complete_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::security_mode_complete: - HANDLE_CODE(c.get().unpack(bref)); + case types::one_frame: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::crit_exts_future: + case types::four_frames: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "security_mode_complete_s::crit_exts_c_"); + log_invalid_choice_id(type_, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string security_mode_complete_s::crit_exts_c_::types_opts::to_string() const +std::string eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types_opts::to_string() const { - static const char* options[] = {"securityModeComplete", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "security_mode_complete_s::crit_exts_c_::types"); + static const char* options[] = {"oneFrame", "fourFrames"}; + return convert_enum_idx(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types"); +} +uint8_t eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types_opts::to_number() const +{ + static const uint8_t options[] = {1, 4}; + return map_enum_number(options, 2, value, "eutra_mbsfn_sf_cfg_s::sf_alloc2_c_::types"); } -// SecurityModeFailure ::= SEQUENCE -SRSASN_CODE security_mode_fail_s::pack(bit_ref& bref) const +// SRS-CC-SetIndex ::= SEQUENCE +SRSASN_CODE srs_cc_set_idx_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + HANDLE_CODE(bref.pack(cc_set_idx_present, 1)); + HANDLE_CODE(bref.pack(cc_idx_in_one_cc_set_present, 1)); + + if (cc_set_idx_present) { + HANDLE_CODE(pack_integer(bref, cc_set_idx, (uint8_t)0u, (uint8_t)3u)); + } + if (cc_idx_in_one_cc_set_present) { + HANDLE_CODE(pack_integer(bref, cc_idx_in_one_cc_set, (uint8_t)0u, (uint8_t)7u)); + } return SRSASN_SUCCESS; } -SRSASN_CODE security_mode_fail_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_cc_set_idx_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + HANDLE_CODE(bref.unpack(cc_set_idx_present, 1)); + HANDLE_CODE(bref.unpack(cc_idx_in_one_cc_set_present, 1)); + + if (cc_set_idx_present) { + HANDLE_CODE(unpack_integer(cc_set_idx, bref, (uint8_t)0u, (uint8_t)3u)); + } + if (cc_idx_in_one_cc_set_present) { + HANDLE_CODE(unpack_integer(cc_idx_in_one_cc_set, bref, (uint8_t)0u, (uint8_t)7u)); + } return SRSASN_SUCCESS; } -void security_mode_fail_s::to_json(json_writer& j) const +void srs_cc_set_idx_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + if (cc_set_idx_present) { + j.write_int("cc-SetIndex", cc_set_idx); + } + if (cc_idx_in_one_cc_set_present) { + j.write_int("cc-IndexInOneCC-Set", cc_idx_in_one_cc_set); + } j.end_obj(); } -void security_mode_fail_s::crit_exts_c_::destroy_() +// SlotFormatCombination ::= SEQUENCE +SRSASN_CODE slot_format_combination_s::pack(bit_ref& bref) const { - switch (type_) { - case types::security_mode_fail: - c.destroy(); - break; - default: - break; + HANDLE_CODE(pack_integer(bref, slot_format_combination_id, (uint16_t)0u, (uint16_t)511u)); + HANDLE_CODE(pack_dyn_seq_of(bref, slot_formats, 1, 256, integer_packer(0, 255))); + + return SRSASN_SUCCESS; +} +SRSASN_CODE slot_format_combination_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(slot_format_combination_id, bref, (uint16_t)0u, (uint16_t)511u)); + HANDLE_CODE(unpack_dyn_seq_of(slot_formats, bref, 1, 256, integer_packer(0, 255))); + + return SRSASN_SUCCESS; +} +void slot_format_combination_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("slotFormatCombinationId", slot_format_combination_id); + j.start_array("slotFormats"); + for (const auto& e1 : slot_formats) { + j.write_int(e1); } + j.end_array(); + j.end_obj(); } -void security_mode_fail_s::crit_exts_c_::set(types::options e) + +// FrequencyInfoDL ::= SEQUENCE +SRSASN_CODE freq_info_dl_s::pack(bit_ref& bref) const { - destroy_(); - type_ = e; - switch (type_) { - case types::security_mode_fail: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(absolute_freq_ssb_present, 1)); + + if (absolute_freq_ssb_present) { + HANDLE_CODE(pack_integer(bref, absolute_freq_ssb, (uint32_t)0u, (uint32_t)3279165u)); } + HANDLE_CODE(pack_dyn_seq_of(bref, freq_band_list, 1, 8, integer_packer(1, 1024))); + HANDLE_CODE(pack_integer(bref, absolute_freq_point_a, (uint32_t)0u, (uint32_t)3279165u)); + HANDLE_CODE(pack_dyn_seq_of(bref, scs_specific_carrier_list, 1, 5)); + + return SRSASN_SUCCESS; } -security_mode_fail_s::crit_exts_c_::crit_exts_c_(const security_mode_fail_s::crit_exts_c_& other) +SRSASN_CODE freq_info_dl_s::unpack(cbit_ref& bref) { - type_ = other.type(); - switch (type_) { - case types::security_mode_fail: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(absolute_freq_ssb_present, 1)); + + if (absolute_freq_ssb_present) { + HANDLE_CODE(unpack_integer(absolute_freq_ssb, bref, (uint32_t)0u, (uint32_t)3279165u)); } + HANDLE_CODE(unpack_dyn_seq_of(freq_band_list, bref, 1, 8, integer_packer(1, 1024))); + HANDLE_CODE(unpack_integer(absolute_freq_point_a, bref, (uint32_t)0u, (uint32_t)3279165u)); + HANDLE_CODE(unpack_dyn_seq_of(scs_specific_carrier_list, bref, 1, 5)); + + return SRSASN_SUCCESS; } -security_mode_fail_s::crit_exts_c_& security_mode_fail_s::crit_exts_c_:: - operator=(const security_mode_fail_s::crit_exts_c_& other) +void freq_info_dl_s::to_json(json_writer& j) const { - if (this == &other) { - return *this; + j.start_obj(); + if (absolute_freq_ssb_present) { + j.write_int("absoluteFrequencySSB", absolute_freq_ssb); } - set(other.type()); - switch (type_) { - case types::security_mode_fail: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); + j.start_array("frequencyBandList"); + for (const auto& e1 : freq_band_list) { + j.write_int(e1); + } + j.end_array(); + j.write_int("absoluteFrequencyPointA", absolute_freq_point_a); + j.start_array("scs-SpecificCarrierList"); + for (const auto& e1 : scs_specific_carrier_list) { + e1.to_json(j); + } + j.end_array(); + j.end_obj(); +} + +// FrequencyInfoUL ::= SEQUENCE +SRSASN_CODE freq_info_ul_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(freq_band_list_present, 1)); + HANDLE_CODE(bref.pack(absolute_freq_point_a_present, 1)); + HANDLE_CODE(bref.pack(add_spec_emission_present, 1)); + HANDLE_CODE(bref.pack(p_max_present, 1)); + HANDLE_CODE(bref.pack(freq_shift7p5khz_present, 1)); + + if (freq_band_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, freq_band_list, 1, 8, integer_packer(1, 1024))); + } + if (absolute_freq_point_a_present) { + HANDLE_CODE(pack_integer(bref, absolute_freq_point_a, (uint32_t)0u, (uint32_t)3279165u)); + } + HANDLE_CODE(pack_dyn_seq_of(bref, scs_specific_carrier_list, 1, 5)); + if (add_spec_emission_present) { + HANDLE_CODE(pack_integer(bref, add_spec_emission, (uint8_t)0u, (uint8_t)7u)); + } + if (p_max_present) { + HANDLE_CODE(pack_integer(bref, p_max, (int8_t)-30, (int8_t)33)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE freq_info_ul_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(freq_band_list_present, 1)); + HANDLE_CODE(bref.unpack(absolute_freq_point_a_present, 1)); + HANDLE_CODE(bref.unpack(add_spec_emission_present, 1)); + HANDLE_CODE(bref.unpack(p_max_present, 1)); + HANDLE_CODE(bref.unpack(freq_shift7p5khz_present, 1)); + + if (freq_band_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(freq_band_list, bref, 1, 8, integer_packer(1, 1024))); + } + if (absolute_freq_point_a_present) { + HANDLE_CODE(unpack_integer(absolute_freq_point_a, bref, (uint32_t)0u, (uint32_t)3279165u)); + } + HANDLE_CODE(unpack_dyn_seq_of(scs_specific_carrier_list, bref, 1, 5)); + if (add_spec_emission_present) { + HANDLE_CODE(unpack_integer(add_spec_emission, bref, (uint8_t)0u, (uint8_t)7u)); + } + if (p_max_present) { + HANDLE_CODE(unpack_integer(p_max, bref, (int8_t)-30, (int8_t)33)); + } + + return SRSASN_SUCCESS; +} +void freq_info_ul_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (freq_band_list_present) { + j.start_array("frequencyBandList"); + for (const auto& e1 : freq_band_list) { + j.write_int(e1); + } + j.end_array(); + } + if (absolute_freq_point_a_present) { + j.write_int("absoluteFrequencyPointA", absolute_freq_point_a); + } + j.start_array("scs-SpecificCarrierList"); + for (const auto& e1 : scs_specific_carrier_list) { + e1.to_json(j); + } + j.end_array(); + if (add_spec_emission_present) { + j.write_int("additionalSpectrumEmission", add_spec_emission); + } + if (p_max_present) { + j.write_int("p-Max", p_max); + } + if (freq_shift7p5khz_present) { + j.write_str("frequencyShift7p5khz", "true"); + } + j.end_obj(); +} + +// PUSCH-CodeBlockGroupTransmission ::= SEQUENCE +SRSASN_CODE pusch_code_block_group_tx_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(max_code_block_groups_per_transport_block.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE pusch_code_block_group_tx_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(max_code_block_groups_per_transport_block.unpack(bref)); + + return SRSASN_SUCCESS; +} +void pusch_code_block_group_tx_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_str("maxCodeBlockGroupsPerTransportBlock", max_code_block_groups_per_transport_block.to_string()); + j.end_obj(); +} + +std::string pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_string() const +{ + static const char* options[] = {"n2", "n4", "n6", "n8"}; + return convert_enum_idx( + options, 4, value, "pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); +} +uint8_t pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 6, 8}; + return map_enum_number( + options, 4, value, "pusch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); +} + +// SRS-TPC-PDCCH-Config ::= SEQUENCE +SRSASN_CODE srs_tpc_pdcch_cfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(srs_cc_set_idxlist_present, 1)); + + if (srs_cc_set_idxlist_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, srs_cc_set_idxlist, 1, 4)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE srs_tpc_pdcch_cfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(srs_cc_set_idxlist_present, 1)); + + if (srs_cc_set_idxlist_present) { + HANDLE_CODE(unpack_dyn_seq_of(srs_cc_set_idxlist, bref, 1, 4)); + } + + return SRSASN_SUCCESS; +} +void srs_tpc_pdcch_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (srs_cc_set_idxlist_present) { + j.start_array("srs-CC-SetIndexlist"); + for (const auto& e1 : srs_cc_set_idxlist) { + e1.to_json(j); + } + j.end_array(); + } + j.end_obj(); +} + +// SlotFormatCombinationsPerCell ::= SEQUENCE +SRSASN_CODE slot_format_combinations_per_cell_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(subcarrier_spacing2_present, 1)); + HANDLE_CODE(bref.pack(slot_format_combinations_present, 1)); + HANDLE_CODE(bref.pack(position_in_dci_present, 1)); + + HANDLE_CODE(pack_integer(bref, serving_cell_id, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(subcarrier_spacing.pack(bref)); + if (subcarrier_spacing2_present) { + HANDLE_CODE(subcarrier_spacing2.pack(bref)); + } + if (slot_format_combinations_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, slot_format_combinations, 1, 512)); + } + if (position_in_dci_present) { + HANDLE_CODE(pack_integer(bref, position_in_dci, (uint8_t)0u, (uint8_t)127u)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE slot_format_combinations_per_cell_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(subcarrier_spacing2_present, 1)); + HANDLE_CODE(bref.unpack(slot_format_combinations_present, 1)); + HANDLE_CODE(bref.unpack(position_in_dci_present, 1)); + + HANDLE_CODE(unpack_integer(serving_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(subcarrier_spacing.unpack(bref)); + if (subcarrier_spacing2_present) { + HANDLE_CODE(subcarrier_spacing2.unpack(bref)); + } + if (slot_format_combinations_present) { + HANDLE_CODE(unpack_dyn_seq_of(slot_format_combinations, bref, 1, 512)); + } + if (position_in_dci_present) { + HANDLE_CODE(unpack_integer(position_in_dci, bref, (uint8_t)0u, (uint8_t)127u)); + } + + return SRSASN_SUCCESS; +} +void slot_format_combinations_per_cell_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("servingCellId", serving_cell_id); + j.write_str("subcarrierSpacing", subcarrier_spacing.to_string()); + if (subcarrier_spacing2_present) { + j.write_str("subcarrierSpacing2", subcarrier_spacing2.to_string()); + } + if (slot_format_combinations_present) { + j.start_array("slotFormatCombinations"); + for (const auto& e1 : slot_format_combinations) { + e1.to_json(j); + } + j.end_array(); } - - return *this; -} -void security_mode_fail_s::crit_exts_c_::to_json(json_writer& j) const -{ - j.start_obj(); - switch (type_) { - case types::security_mode_fail: - j.write_fieldname("securityModeFailure"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); + if (position_in_dci_present) { + j.write_int("positionInDCI", position_in_dci); } j.end_obj(); } -SRSASN_CODE security_mode_fail_s::crit_exts_c_::pack(bit_ref& bref) const + +// DownlinkConfigCommon ::= SEQUENCE +SRSASN_CODE dl_cfg_common_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::security_mode_fail: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(freq_info_dl_present, 1)); + HANDLE_CODE(bref.pack(init_dl_bwp_present, 1)); + + if (freq_info_dl_present) { + HANDLE_CODE(freq_info_dl.pack(bref)); + } + if (init_dl_bwp_present) { + HANDLE_CODE(init_dl_bwp.pack(bref)); } + return SRSASN_SUCCESS; } -SRSASN_CODE security_mode_fail_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE dl_cfg_common_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::security_mode_fail: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "security_mode_fail_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(freq_info_dl_present, 1)); + HANDLE_CODE(bref.unpack(init_dl_bwp_present, 1)); + + if (freq_info_dl_present) { + HANDLE_CODE(freq_info_dl.unpack(bref)); + } + if (init_dl_bwp_present) { + HANDLE_CODE(init_dl_bwp.unpack(bref)); } + return SRSASN_SUCCESS; } - -std::string security_mode_fail_s::crit_exts_c_::types_opts::to_string() const +void dl_cfg_common_s::to_json(json_writer& j) const { - static const char* options[] = {"securityModeFailure", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "security_mode_fail_s::crit_exts_c_::types"); + j.start_obj(); + if (freq_info_dl_present) { + j.write_fieldname("frequencyInfoDL"); + freq_info_dl.to_json(j); + } + if (init_dl_bwp_present) { + j.write_fieldname("initialDownlinkBWP"); + init_dl_bwp.to_json(j); + } + j.end_obj(); } -// UEAssistanceInformation ::= SEQUENCE -SRSASN_CODE ueassist_info_s::pack(bit_ref& bref) const +// PDSCH-CodeBlockGroupTransmission ::= SEQUENCE +SRSASN_CODE pdsch_code_block_group_tx_s::pack(bit_ref& bref) const { - HANDLE_CODE(crit_exts.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(max_code_block_groups_per_transport_block.pack(bref)); + HANDLE_CODE(bref.pack(code_block_group_flush_ind, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE ueassist_info_s::unpack(cbit_ref& bref) +SRSASN_CODE pdsch_code_block_group_tx_s::unpack(cbit_ref& bref) { - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(max_code_block_groups_per_transport_block.unpack(bref)); + HANDLE_CODE(bref.unpack(code_block_group_flush_ind, 1)); return SRSASN_SUCCESS; } -void ueassist_info_s::to_json(json_writer& j) const +void pdsch_code_block_group_tx_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_str("maxCodeBlockGroupsPerTransportBlock", max_code_block_groups_per_transport_block.to_string()); + j.write_bool("codeBlockGroupFlushIndicator", code_block_group_flush_ind); j.end_obj(); } -void ueassist_info_s::crit_exts_c_::destroy_() +std::string pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_string() const { - switch (type_) { - case types::ue_assist_info: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"n2", "n4", "n6", "n8"}; + return convert_enum_idx( + options, 4, value, "pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); } -void ueassist_info_s::crit_exts_c_::set(types::options e) +uint8_t pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_opts::to_number() const { - destroy_(); - type_ = e; - switch (type_) { - case types::ue_assist_info: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); - } + static const uint8_t options[] = {2, 4, 6, 8}; + return map_enum_number( + options, 4, value, "pdsch_code_block_group_tx_s::max_code_block_groups_per_transport_block_e_"); } -ueassist_info_s::crit_exts_c_::crit_exts_c_(const ueassist_info_s::crit_exts_c_& other) + +// PUSCH-ServingCellConfig ::= SEQUENCE +SRSASN_CODE pusch_serving_cell_cfg_s::pack(bit_ref& bref) const { - type_ = other.type(); - switch (type_) { - case types::ue_assist_info: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(code_block_group_tx_present, 1)); + HANDLE_CODE(bref.pack(rate_matching_present, 1)); + HANDLE_CODE(bref.pack(xoverhead_present, 1)); + + if (code_block_group_tx_present) { + HANDLE_CODE(code_block_group_tx.pack(bref)); + } + if (xoverhead_present) { + HANDLE_CODE(xoverhead.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= max_mimo_layers_present; + group_flags[0] |= processing_type2_enabled_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(max_mimo_layers_present, 1)); + HANDLE_CODE(bref.pack(processing_type2_enabled_present, 1)); + if (max_mimo_layers_present) { + HANDLE_CODE(pack_integer(bref, max_mimo_layers, (uint8_t)1u, (uint8_t)4u)); + } + if (processing_type2_enabled_present) { + HANDLE_CODE(bref.pack(processing_type2_enabled, 1)); + } + } } + return SRSASN_SUCCESS; } -ueassist_info_s::crit_exts_c_& ueassist_info_s::crit_exts_c_::operator=(const ueassist_info_s::crit_exts_c_& other) +SRSASN_CODE pusch_serving_cell_cfg_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(code_block_group_tx_present, 1)); + HANDLE_CODE(bref.unpack(rate_matching_present, 1)); + HANDLE_CODE(bref.unpack(xoverhead_present, 1)); + + if (code_block_group_tx_present) { + HANDLE_CODE(code_block_group_tx.unpack(bref)); } - set(other.type()); - switch (type_) { - case types::ue_assist_info: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); + if (xoverhead_present) { + HANDLE_CODE(xoverhead.unpack(bref)); } - return *this; + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(max_mimo_layers_present, 1)); + HANDLE_CODE(bref.unpack(processing_type2_enabled_present, 1)); + if (max_mimo_layers_present) { + HANDLE_CODE(unpack_integer(max_mimo_layers, bref, (uint8_t)1u, (uint8_t)4u)); + } + if (processing_type2_enabled_present) { + HANDLE_CODE(bref.unpack(processing_type2_enabled, 1)); + } + } + } + return SRSASN_SUCCESS; } -void ueassist_info_s::crit_exts_c_::to_json(json_writer& j) const +void pusch_serving_cell_cfg_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::ue_assist_info: - j.write_fieldname("ueAssistanceInformation"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); + if (code_block_group_tx_present) { + j.write_fieldname("codeBlockGroupTransmission"); + code_block_group_tx.to_json(j); + } + if (rate_matching_present) { + j.write_str("rateMatching", "limitedBufferRM"); + } + if (xoverhead_present) { + j.write_str("xOverhead", xoverhead.to_string()); + } + if (ext) { + if (max_mimo_layers_present) { + j.write_int("maxMIMO-Layers", max_mimo_layers); + } + if (processing_type2_enabled_present) { + j.write_bool("processingType2Enabled", processing_type2_enabled); + } } j.end_obj(); } -SRSASN_CODE ueassist_info_s::crit_exts_c_::pack(bit_ref& bref) const + +std::string pusch_serving_cell_cfg_s::xoverhead_opts::to_string() const { - type_.pack(bref); - switch (type_) { - case types::ue_assist_info: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"xoh6", "xoh12", "xoh18"}; + return convert_enum_idx(options, 3, value, "pusch_serving_cell_cfg_s::xoverhead_e_"); } -SRSASN_CODE ueassist_info_s::crit_exts_c_::unpack(cbit_ref& bref) +uint8_t pusch_serving_cell_cfg_s::xoverhead_opts::to_number() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::ue_assist_info: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "ueassist_info_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const uint8_t options[] = {6, 12, 18}; + return map_enum_number(options, 3, value, "pusch_serving_cell_cfg_s::xoverhead_e_"); } -std::string ueassist_info_s::crit_exts_c_::types_opts::to_string() const +// PollByte ::= ENUMERATED +std::string poll_byte_opts::to_string() const { - static const char* options[] = {"ueAssistanceInformation", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "ueassist_info_s::crit_exts_c_::types"); + static const char* options[] = { + "kB1", "kB2", "kB5", "kB8", "kB10", "kB15", "kB25", "kB50", "kB75", "kB100", + "kB125", "kB250", "kB375", "kB500", "kB750", "kB1000", "kB1250", "kB1500", "kB2000", "kB3000", + "kB4000", "kB4500", "kB5000", "kB5500", "kB6000", "kB6500", "kB7000", "kB7500", "mB8", "mB9", + "mB10", "mB11", "mB12", "mB13", "mB14", "mB15", "mB16", "mB17", "mB18", "mB20", + "mB25", "mB30", "mB40", "infinity", "spare20", "spare19", "spare18", "spare17", "spare16", "spare15", + "spare14", "spare13", "spare12", "spare11", "spare10", "spare9", "spare8", "spare7", "spare6", "spare5", + "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 64, value, "poll_byte_e"); } -// UECapabilityInformation ::= SEQUENCE -SRSASN_CODE ue_cap_info_s::pack(bit_ref& bref) const +// PollPDU ::= ENUMERATED +std::string poll_pdu_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, rrc_transaction_id, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.pack(bref)); + static const char* options[] = {"p4", "p8", "p16", "p32", "p64", "p128", "p256", "p512", + "p1024", "p2048", "p4096", "p6144", "p8192", "p12288", "p16384", "p20480", + "p24576", "p28672", "p32768", "p40960", "p49152", "p57344", "p65536", "infinity", + "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 32, value, "poll_pdu_e"); +} +int32_t poll_pdu_opts::to_number() const +{ + static const int32_t options[] = {4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 6144, + 8192, 12288, 16384, 20480, 24576, 28672, 32768, 40960, 49152, 57344, 65536, -1}; + return map_enum_number(options, 24, value, "poll_pdu_e"); +} + +// RateMatchPatternLTE-CRS ::= SEQUENCE +SRSASN_CODE rate_match_pattern_lte_crs_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(mbsfn_sf_cfg_list_present, 1)); + + HANDLE_CODE(pack_integer(bref, carrier_freq_dl, (uint16_t)0u, (uint16_t)16383u)); + HANDLE_CODE(carrier_bw_dl.pack(bref)); + if (mbsfn_sf_cfg_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, mbsfn_sf_cfg_list, 1, 8)); + } + HANDLE_CODE(nrof_crs_ports.pack(bref)); + HANDLE_CODE(v_shift.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ue_cap_info_s::unpack(cbit_ref& bref) +SRSASN_CODE rate_match_pattern_lte_crs_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(rrc_transaction_id, bref, (uint8_t)0u, (uint8_t)3u)); - HANDLE_CODE(crit_exts.unpack(bref)); + HANDLE_CODE(bref.unpack(mbsfn_sf_cfg_list_present, 1)); + + HANDLE_CODE(unpack_integer(carrier_freq_dl, bref, (uint16_t)0u, (uint16_t)16383u)); + HANDLE_CODE(carrier_bw_dl.unpack(bref)); + if (mbsfn_sf_cfg_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(mbsfn_sf_cfg_list, bref, 1, 8)); + } + HANDLE_CODE(nrof_crs_ports.unpack(bref)); + HANDLE_CODE(v_shift.unpack(bref)); return SRSASN_SUCCESS; } -void ue_cap_info_s::to_json(json_writer& j) const +void rate_match_pattern_lte_crs_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("rrc-TransactionIdentifier", rrc_transaction_id); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + j.write_int("carrierFreqDL", carrier_freq_dl); + j.write_str("carrierBandwidthDL", carrier_bw_dl.to_string()); + if (mbsfn_sf_cfg_list_present) { + j.start_array("mbsfn-SubframeConfigList"); + for (const auto& e1 : mbsfn_sf_cfg_list) { + e1.to_json(j); + } + j.end_array(); + } + j.write_str("nrofCRS-Ports", nrof_crs_ports.to_string()); + j.write_str("v-Shift", v_shift.to_string()); j.end_obj(); } -void ue_cap_info_s::crit_exts_c_::destroy_() +std::string rate_match_pattern_lte_crs_s::carrier_bw_dl_opts::to_string() const { - switch (type_) { - case types::ue_cap_info: - c.destroy(); - break; - default: - break; - } + static const char* options[] = {"n6", "n15", "n25", "n50", "n75", "n100", "spare2", "spare1"}; + return convert_enum_idx(options, 8, value, "rate_match_pattern_lte_crs_s::carrier_bw_dl_e_"); } -void ue_cap_info_s::crit_exts_c_::set(types::options e) +uint8_t rate_match_pattern_lte_crs_s::carrier_bw_dl_opts::to_number() const { - destroy_(); - type_ = e; - switch (type_) { - case types::ue_cap_info: - c.init(); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); - } + static const uint8_t options[] = {6, 15, 25, 50, 75, 100}; + return map_enum_number(options, 6, value, "rate_match_pattern_lte_crs_s::carrier_bw_dl_e_"); } -ue_cap_info_s::crit_exts_c_::crit_exts_c_(const ue_cap_info_s::crit_exts_c_& other) + +std::string rate_match_pattern_lte_crs_s::nrof_crs_ports_opts::to_string() const { - type_ = other.type(); - switch (type_) { - case types::ue_cap_info: - c.init(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); - } + static const char* options[] = {"n1", "n2", "n4"}; + return convert_enum_idx(options, 3, value, "rate_match_pattern_lte_crs_s::nrof_crs_ports_e_"); } -ue_cap_info_s::crit_exts_c_& ue_cap_info_s::crit_exts_c_::operator=(const ue_cap_info_s::crit_exts_c_& other) +uint8_t rate_match_pattern_lte_crs_s::nrof_crs_ports_opts::to_number() const { - if (this == &other) { - return *this; - } - set(other.type()); - switch (type_) { - case types::ue_cap_info: - c.set(other.c.get()); - break; - case types::crit_exts_future: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); - } + static const uint8_t options[] = {1, 2, 4}; + return map_enum_number(options, 3, value, "rate_match_pattern_lte_crs_s::nrof_crs_ports_e_"); +} - return *this; +std::string rate_match_pattern_lte_crs_s::v_shift_opts::to_string() const +{ + static const char* options[] = {"n0", "n1", "n2", "n3", "n4", "n5"}; + return convert_enum_idx(options, 6, value, "rate_match_pattern_lte_crs_s::v_shift_e_"); } -void ue_cap_info_s::crit_exts_c_::to_json(json_writer& j) const +uint8_t rate_match_pattern_lte_crs_s::v_shift_opts::to_number() const { - j.start_obj(); - switch (type_) { - case types::ue_cap_info: - j.write_fieldname("ueCapabilityInformation"); - c.get().to_json(j); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); - } - j.end_obj(); + static const uint8_t options[] = {0, 1, 2, 3, 4, 5}; + return map_enum_number(options, 6, value, "rate_match_pattern_lte_crs_s::v_shift_e_"); } -SRSASN_CODE ue_cap_info_s::crit_exts_c_::pack(bit_ref& bref) const + +// SN-FieldLengthAM ::= ENUMERATED +std::string sn_field_len_am_opts::to_string() const { - type_.pack(bref); - switch (type_) { - case types::ue_cap_info: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); - return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; + static const char* options[] = {"size12", "size18"}; + return convert_enum_idx(options, 2, value, "sn_field_len_am_e"); } -SRSASN_CODE ue_cap_info_s::crit_exts_c_::unpack(cbit_ref& bref) +uint8_t sn_field_len_am_opts::to_number() const { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::ue_cap_info: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::crit_exts_future: - break; - default: - log_invalid_choice_id(type_, "ue_cap_info_s::crit_exts_c_"); - return SRSASN_ERROR_DECODE_FAIL; - } - return SRSASN_SUCCESS; + static const uint8_t options[] = {12, 18}; + return map_enum_number(options, 2, value, "sn_field_len_am_e"); } -std::string ue_cap_info_s::crit_exts_c_::types_opts::to_string() const +// SN-FieldLengthUM ::= ENUMERATED +std::string sn_field_len_um_opts::to_string() const { - static const char* options[] = {"ueCapabilityInformation", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "ue_cap_info_s::crit_exts_c_::types"); + static const char* options[] = {"size6", "size12"}; + return convert_enum_idx(options, 2, value, "sn_field_len_um_e"); +} +uint8_t sn_field_len_um_opts::to_number() const +{ + static const uint8_t options[] = {6, 12}; + return map_enum_number(options, 2, value, "sn_field_len_um_e"); } -// ULInformationTransfer ::= SEQUENCE -SRSASN_CODE ul_info_transfer_s::pack(bit_ref& bref) const +// SRS-CarrierSwitching ::= SEQUENCE +SRSASN_CODE srs_carrier_switching_s::pack(bit_ref& bref) const { - HANDLE_CODE(crit_exts.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(srs_switch_from_serv_cell_idx_present, 1)); + HANDLE_CODE(bref.pack(srs_tpc_pdcch_group_present, 1)); + HANDLE_CODE(bref.pack(monitoring_cells_present, 1)); + + if (srs_switch_from_serv_cell_idx_present) { + HANDLE_CODE(pack_integer(bref, srs_switch_from_serv_cell_idx, (uint8_t)0u, (uint8_t)31u)); + } + HANDLE_CODE(srs_switch_from_carrier.pack(bref)); + if (srs_tpc_pdcch_group_present) { + HANDLE_CODE(srs_tpc_pdcch_group.pack(bref)); + } + if (monitoring_cells_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, monitoring_cells, 1, 32, integer_packer(0, 31))); + } return SRSASN_SUCCESS; } -SRSASN_CODE ul_info_transfer_s::unpack(cbit_ref& bref) +SRSASN_CODE srs_carrier_switching_s::unpack(cbit_ref& bref) { - HANDLE_CODE(crit_exts.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(srs_switch_from_serv_cell_idx_present, 1)); + HANDLE_CODE(bref.unpack(srs_tpc_pdcch_group_present, 1)); + HANDLE_CODE(bref.unpack(monitoring_cells_present, 1)); + + if (srs_switch_from_serv_cell_idx_present) { + HANDLE_CODE(unpack_integer(srs_switch_from_serv_cell_idx, bref, (uint8_t)0u, (uint8_t)31u)); + } + HANDLE_CODE(srs_switch_from_carrier.unpack(bref)); + if (srs_tpc_pdcch_group_present) { + HANDLE_CODE(srs_tpc_pdcch_group.unpack(bref)); + } + if (monitoring_cells_present) { + HANDLE_CODE(unpack_dyn_seq_of(monitoring_cells, bref, 1, 32, integer_packer(0, 31))); + } return SRSASN_SUCCESS; } -void ul_info_transfer_s::to_json(json_writer& j) const +void srs_carrier_switching_s::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("criticalExtensions"); - crit_exts.to_json(j); + if (srs_switch_from_serv_cell_idx_present) { + j.write_int("srs-SwitchFromServCellIndex", srs_switch_from_serv_cell_idx); + } + j.write_str("srs-SwitchFromCarrier", srs_switch_from_carrier.to_string()); + if (srs_tpc_pdcch_group_present) { + j.write_fieldname("srs-TPC-PDCCH-Group"); + srs_tpc_pdcch_group.to_json(j); + } + if (monitoring_cells_present) { + j.start_array("monitoringCells"); + for (const auto& e1 : monitoring_cells) { + j.write_int(e1); + } + j.end_array(); + } j.end_obj(); } -void ul_info_transfer_s::crit_exts_c_::destroy_() +std::string srs_carrier_switching_s::srs_switch_from_carrier_opts::to_string() const +{ + static const char* options[] = {"sUL", "nUL"}; + return convert_enum_idx(options, 2, value, "srs_carrier_switching_s::srs_switch_from_carrier_e_"); +} + +void srs_carrier_switching_s::srs_tpc_pdcch_group_c_::destroy_() { switch (type_) { - case types::ul_info_transfer: - c.destroy(); + case types::type_a: + c.destroy(); + break; + case types::type_b: + c.destroy(); break; default: break; } } -void ul_info_transfer_s::crit_exts_c_::set(types::options e) +void srs_carrier_switching_s::srs_tpc_pdcch_group_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::ul_info_transfer: - c.init(); + case types::type_a: + c.init(); break; - case types::crit_exts_future: + case types::type_b: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); } } -ul_info_transfer_s::crit_exts_c_::crit_exts_c_(const ul_info_transfer_s::crit_exts_c_& other) +srs_carrier_switching_s::srs_tpc_pdcch_group_c_::srs_tpc_pdcch_group_c_( + const srs_carrier_switching_s::srs_tpc_pdcch_group_c_& other) { type_ = other.type(); switch (type_) { - case types::ul_info_transfer: - c.init(other.c.get()); + case types::type_a: + c.init(other.c.get()); break; - case types::crit_exts_future: + case types::type_b: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); } } -ul_info_transfer_s::crit_exts_c_& ul_info_transfer_s::crit_exts_c_:: - operator=(const ul_info_transfer_s::crit_exts_c_& other) +srs_carrier_switching_s::srs_tpc_pdcch_group_c_& +srs_carrier_switching_s::srs_tpc_pdcch_group_c_::operator=(const srs_carrier_switching_s::srs_tpc_pdcch_group_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::ul_info_transfer: - c.set(other.c.get()); + case types::type_a: + c.set(other.c.get()); break; - case types::crit_exts_future: + case types::type_b: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); } return *this; } -void ul_info_transfer_s::crit_exts_c_::to_json(json_writer& j) const +void srs_carrier_switching_s::srs_tpc_pdcch_group_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::ul_info_transfer: - j.write_fieldname("ulInformationTransfer"); - c.get().to_json(j); + case types::type_a: + j.start_array("typeA"); + for (const auto& e1 : c.get()) { + e1.to_json(j); + } + j.end_array(); break; - case types::crit_exts_future: + case types::type_b: + j.write_fieldname("typeB"); + c.get().to_json(j); break; default: - log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); } j.end_obj(); } -SRSASN_CODE ul_info_transfer_s::crit_exts_c_::pack(bit_ref& bref) const +SRSASN_CODE srs_carrier_switching_s::srs_tpc_pdcch_group_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::ul_info_transfer: - HANDLE_CODE(c.get().pack(bref)); + case types::type_a: + HANDLE_CODE(pack_dyn_seq_of(bref, c.get(), 1, 32)); break; - case types::crit_exts_future: + case types::type_b: + HANDLE_CODE(c.get().pack(bref)); break; default: - log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE ul_info_transfer_s::crit_exts_c_::unpack(cbit_ref& bref) +SRSASN_CODE srs_carrier_switching_s::srs_tpc_pdcch_group_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::ul_info_transfer: - HANDLE_CODE(c.get().unpack(bref)); + case types::type_a: + HANDLE_CODE(unpack_dyn_seq_of(c.get(), bref, 1, 32)); break; - case types::crit_exts_future: + case types::type_b: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "ul_info_transfer_s::crit_exts_c_"); + log_invalid_choice_id(type_, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string ul_info_transfer_s::crit_exts_c_::types_opts::to_string() const +std::string srs_carrier_switching_s::srs_tpc_pdcch_group_c_::types_opts::to_string() const { - static const char* options[] = {"ulInformationTransfer", "criticalExtensionsFuture"}; - return convert_enum_idx(options, 2, value, "ul_info_transfer_s::crit_exts_c_::types"); + static const char* options[] = {"typeA", "typeB"}; + return convert_enum_idx(options, 2, value, "srs_carrier_switching_s::srs_tpc_pdcch_group_c_::types"); } -// UL-DCCH-MessageType ::= CHOICE -void ul_dcch_msg_type_c::destroy_() +// SlotFormatIndicator ::= SEQUENCE +SRSASN_CODE slot_format_ind_s::pack(bit_ref& bref) const { - switch (type_) { - case types::c1: - c.destroy(); - break; - default: - break; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(slot_format_comb_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(slot_format_comb_to_release_list_present, 1)); + + HANDLE_CODE(pack_integer(bref, sfi_rnti, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(pack_integer(bref, dci_payload_size, (uint8_t)1u, (uint8_t)128u)); + if (slot_format_comb_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, slot_format_comb_to_add_mod_list, 1, 16)); } -} -void ul_dcch_msg_type_c::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::c1: - c.init(); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); + if (slot_format_comb_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, slot_format_comb_to_release_list, 1, 16, integer_packer(0, 31))); } + + return SRSASN_SUCCESS; } -ul_dcch_msg_type_c::ul_dcch_msg_type_c(const ul_dcch_msg_type_c& other) +SRSASN_CODE slot_format_ind_s::unpack(cbit_ref& bref) { - type_ = other.type(); - switch (type_) { - case types::c1: - c.init(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(slot_format_comb_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(slot_format_comb_to_release_list_present, 1)); + + HANDLE_CODE(unpack_integer(sfi_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(unpack_integer(dci_payload_size, bref, (uint8_t)1u, (uint8_t)128u)); + if (slot_format_comb_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(slot_format_comb_to_add_mod_list, bref, 1, 16)); + } + if (slot_format_comb_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(slot_format_comb_to_release_list, bref, 1, 16, integer_packer(0, 31))); } + + return SRSASN_SUCCESS; } -ul_dcch_msg_type_c& ul_dcch_msg_type_c::operator=(const ul_dcch_msg_type_c& other) +void slot_format_ind_s::to_json(json_writer& j) const { - if (this == &other) { - return *this; + j.start_obj(); + j.write_int("sfi-RNTI", sfi_rnti); + j.write_int("dci-PayloadSize", dci_payload_size); + if (slot_format_comb_to_add_mod_list_present) { + j.start_array("slotFormatCombToAddModList"); + for (const auto& e1 : slot_format_comb_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - set(other.type()); - switch (type_) { - case types::c1: - c.set(other.c.get()); - break; - case types::msg_class_ext: - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); + if (slot_format_comb_to_release_list_present) { + j.start_array("slotFormatCombToReleaseList"); + for (const auto& e1 : slot_format_comb_to_release_list) { + j.write_int(e1); + } + j.end_array(); } + j.end_obj(); +} - return *this; +// T-PollRetransmit ::= ENUMERATED +std::string t_poll_retx_opts::to_string() const +{ + static const char* options[] = { + "ms5", "ms10", "ms15", "ms20", "ms25", "ms30", "ms35", "ms40", "ms45", "ms50", "ms55", + "ms60", "ms65", "ms70", "ms75", "ms80", "ms85", "ms90", "ms95", "ms100", "ms105", "ms110", + "ms115", "ms120", "ms125", "ms130", "ms135", "ms140", "ms145", "ms150", "ms155", "ms160", "ms165", + "ms170", "ms175", "ms180", "ms185", "ms190", "ms195", "ms200", "ms205", "ms210", "ms215", "ms220", + "ms225", "ms230", "ms235", "ms240", "ms245", "ms250", "ms300", "ms350", "ms400", "ms450", "ms500", + "ms800", "ms1000", "ms2000", "ms4000", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 64, value, "t_poll_retx_e"); } -void ul_dcch_msg_type_c::to_json(json_writer& j) const +uint16_t t_poll_retx_opts::to_number() const +{ + static const uint16_t options[] = {5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75, + 80, 85, 90, 95, 100, 105, 110, 115, 120, 125, 130, 135, 140, 145, 150, + 155, 160, 165, 170, 175, 180, 185, 190, 195, 200, 205, 210, 215, 220, 225, + 230, 235, 240, 245, 250, 300, 350, 400, 450, 500, 800, 1000, 2000, 4000}; + return map_enum_number(options, 59, value, "t_poll_retx_e"); +} + +// T-Reassembly ::= ENUMERATED +std::string t_reassembly_opts::to_string() const +{ + static const char* options[] = {"ms0", "ms5", "ms10", "ms15", "ms20", "ms25", "ms30", "ms35", + "ms40", "ms45", "ms50", "ms55", "ms60", "ms65", "ms70", "ms75", + "ms80", "ms85", "ms90", "ms95", "ms100", "ms110", "ms120", "ms130", + "ms140", "ms150", "ms160", "ms170", "ms180", "ms190", "ms200", "spare1"}; + return convert_enum_idx(options, 32, value, "t_reassembly_e"); +} +uint8_t t_reassembly_opts::to_number() const +{ + static const uint8_t options[] = {0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75, + 80, 85, 90, 95, 100, 110, 120, 130, 140, 150, 160, 170, 180, 190, 200}; + return map_enum_number(options, 31, value, "t_reassembly_e"); +} + +// T-StatusProhibit ::= ENUMERATED +std::string t_status_prohibit_opts::to_string() const +{ + static const char* options[] = { + "ms0", "ms5", "ms10", "ms15", "ms20", "ms25", "ms30", "ms35", "ms40", "ms45", "ms50", + "ms55", "ms60", "ms65", "ms70", "ms75", "ms80", "ms85", "ms90", "ms95", "ms100", "ms105", + "ms110", "ms115", "ms120", "ms125", "ms130", "ms135", "ms140", "ms145", "ms150", "ms155", "ms160", + "ms165", "ms170", "ms175", "ms180", "ms185", "ms190", "ms195", "ms200", "ms205", "ms210", "ms215", + "ms220", "ms225", "ms230", "ms235", "ms240", "ms245", "ms250", "ms300", "ms350", "ms400", "ms450", + "ms500", "ms800", "ms1000", "ms1200", "ms1600", "ms2000", "ms2400", "spare2", "spare1"}; + return convert_enum_idx(options, 64, value, "t_status_prohibit_e"); +} +uint16_t t_status_prohibit_opts::to_number() const +{ + static const uint16_t options[] = {0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 60, 65, 70, 75, + 80, 85, 90, 95, 100, 105, 110, 115, 120, 125, 130, 135, 140, 145, 150, 155, + 160, 165, 170, 175, 180, 185, 190, 195, 200, 205, 210, 215, 220, 225, 230, 235, + 240, 245, 250, 300, 350, 400, 450, 500, 800, 1000, 1200, 1600, 2000, 2400}; + return map_enum_number(options, 62, value, "t_status_prohibit_e"); +} + +// TDD-UL-DL-SlotConfig ::= SEQUENCE +SRSASN_CODE tdd_ul_dl_slot_cfg_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, slot_idx, (uint16_t)0u, (uint16_t)319u)); + HANDLE_CODE(symbols.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE tdd_ul_dl_slot_cfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(slot_idx, bref, (uint16_t)0u, (uint16_t)319u)); + HANDLE_CODE(symbols.unpack(bref)); + + return SRSASN_SUCCESS; +} +void tdd_ul_dl_slot_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("slotIndex", slot_idx); + j.write_fieldname("symbols"); + symbols.to_json(j); + j.end_obj(); +} + +void tdd_ul_dl_slot_cfg_s::symbols_c_::set(types::options e) +{ + type_ = e; +} +void tdd_ul_dl_slot_cfg_s::symbols_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::c1: - j.write_fieldname("c1"); - c.get().to_json(j); + case types::all_dl: break; - case types::msg_class_ext: + case types::all_ul: + break; + case types::explicit_type: + j.write_fieldname("explicit"); + j.start_obj(); + if (c.nrof_dl_symbols_present) { + j.write_int("nrofDownlinkSymbols", c.nrof_dl_symbols); + } + if (c.nrof_ul_symbols_present) { + j.write_int("nrofUplinkSymbols", c.nrof_ul_symbols); + } + j.end_obj(); break; default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); + log_invalid_choice_id(type_, "tdd_ul_dl_slot_cfg_s::symbols_c_"); } j.end_obj(); } -SRSASN_CODE ul_dcch_msg_type_c::pack(bit_ref& bref) const +SRSASN_CODE tdd_ul_dl_slot_cfg_s::symbols_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::c1: - HANDLE_CODE(c.get().pack(bref)); + case types::all_dl: break; - case types::msg_class_ext: + case types::all_ul: + break; + case types::explicit_type: + HANDLE_CODE(bref.pack(c.nrof_dl_symbols_present, 1)); + HANDLE_CODE(bref.pack(c.nrof_ul_symbols_present, 1)); + if (c.nrof_dl_symbols_present) { + HANDLE_CODE(pack_integer(bref, c.nrof_dl_symbols, (uint8_t)1u, (uint8_t)13u)); + } + if (c.nrof_ul_symbols_present) { + HANDLE_CODE(pack_integer(bref, c.nrof_ul_symbols, (uint8_t)1u, (uint8_t)13u)); + } break; default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); + log_invalid_choice_id(type_, "tdd_ul_dl_slot_cfg_s::symbols_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE ul_dcch_msg_type_c::unpack(cbit_ref& bref) +SRSASN_CODE tdd_ul_dl_slot_cfg_s::symbols_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::c1: - HANDLE_CODE(c.get().unpack(bref)); + case types::all_dl: break; - case types::msg_class_ext: + case types::all_ul: + break; + case types::explicit_type: + HANDLE_CODE(bref.unpack(c.nrof_dl_symbols_present, 1)); + HANDLE_CODE(bref.unpack(c.nrof_ul_symbols_present, 1)); + if (c.nrof_dl_symbols_present) { + HANDLE_CODE(unpack_integer(c.nrof_dl_symbols, bref, (uint8_t)1u, (uint8_t)13u)); + } + if (c.nrof_ul_symbols_present) { + HANDLE_CODE(unpack_integer(c.nrof_ul_symbols, bref, (uint8_t)1u, (uint8_t)13u)); + } break; default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c"); + log_invalid_choice_id(type_, "tdd_ul_dl_slot_cfg_s::symbols_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -void ul_dcch_msg_type_c::c1_c_::destroy_() +std::string tdd_ul_dl_slot_cfg_s::symbols_c_::types_opts::to_string() const { - switch (type_) { - case types::meas_report: - c.destroy(); - break; - case types::rrc_recfg_complete: - c.destroy(); - break; - case types::rrc_setup_complete: - c.destroy(); - break; - case types::rrc_reest_complete: - c.destroy(); - break; - case types::rrc_resume_complete: - c.destroy(); - break; - case types::security_mode_complete: - c.destroy(); - break; - case types::security_mode_fail: - c.destroy(); - break; - case types::ul_info_transfer: - c.destroy(); - break; - case types::location_meas_ind: - c.destroy(); - break; - case types::ue_cap_info: - c.destroy(); - break; - case types::counter_check_resp: - c.destroy(); - break; - case types::ue_assist_info: - c.destroy(); - break; - case types::fail_info: - c.destroy(); - break; - default: - break; + static const char* options[] = {"allDownlink", "allUplink", "explicit"}; + return convert_enum_idx(options, 3, value, "tdd_ul_dl_slot_cfg_s::symbols_c_::types"); +} + +// UplinkConfigCommon ::= SEQUENCE +SRSASN_CODE ul_cfg_common_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(freq_info_ul_present, 1)); + HANDLE_CODE(bref.pack(init_ul_bwp_present, 1)); + + if (freq_info_ul_present) { + HANDLE_CODE(freq_info_ul.pack(bref)); + } + if (init_ul_bwp_present) { + HANDLE_CODE(init_ul_bwp.pack(bref)); } + HANDLE_CODE(dummy.pack(bref)); + + return SRSASN_SUCCESS; } -void ul_dcch_msg_type_c::c1_c_::set(types::options e) +SRSASN_CODE ul_cfg_common_s::unpack(cbit_ref& bref) { - destroy_(); - type_ = e; - switch (type_) { - case types::meas_report: - c.init(); - break; - case types::rrc_recfg_complete: - c.init(); - break; - case types::rrc_setup_complete: - c.init(); - break; - case types::rrc_reest_complete: - c.init(); - break; - case types::rrc_resume_complete: - c.init(); - break; - case types::security_mode_complete: - c.init(); - break; - case types::security_mode_fail: - c.init(); - break; - case types::ul_info_transfer: - c.init(); - break; - case types::location_meas_ind: - c.init(); - break; - case types::ue_cap_info: - c.init(); - break; - case types::counter_check_resp: - c.init(); - break; - case types::ue_assist_info: - c.init(); + HANDLE_CODE(bref.unpack(freq_info_ul_present, 1)); + HANDLE_CODE(bref.unpack(init_ul_bwp_present, 1)); + + if (freq_info_ul_present) { + HANDLE_CODE(freq_info_ul.unpack(bref)); + } + if (init_ul_bwp_present) { + HANDLE_CODE(init_ul_bwp.unpack(bref)); + } + HANDLE_CODE(dummy.unpack(bref)); + + return SRSASN_SUCCESS; +} +void ul_cfg_common_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (freq_info_ul_present) { + j.write_fieldname("frequencyInfoUL"); + freq_info_ul.to_json(j); + } + if (init_ul_bwp_present) { + j.write_fieldname("initialUplinkBWP"); + init_ul_bwp.to_json(j); + } + j.write_str("dummy", dummy.to_string()); + j.end_obj(); +} + +// CrossCarrierSchedulingConfig ::= SEQUENCE +SRSASN_CODE cross_carrier_sched_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(sched_cell_info.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE cross_carrier_sched_cfg_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(sched_cell_info.unpack(bref)); + + return SRSASN_SUCCESS; +} +void cross_carrier_sched_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_fieldname("schedulingCellInfo"); + sched_cell_info.to_json(j); + j.end_obj(); +} + +void cross_carrier_sched_cfg_s::sched_cell_info_c_::destroy_() +{ + switch (type_) { + case types::own: + c.destroy(); break; - case types::fail_info: - c.init(); + case types::other: + c.destroy(); break; - case types::spare3: + default: break; - case types::spare2: + } +} +void cross_carrier_sched_cfg_s::sched_cell_info_c_::set(types::options e) +{ + destroy_(); + type_ = e; + switch (type_) { + case types::own: + c.init(); break; - case types::spare1: + case types::other: + c.init(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); } } -ul_dcch_msg_type_c::c1_c_::c1_c_(const ul_dcch_msg_type_c::c1_c_& other) +cross_carrier_sched_cfg_s::sched_cell_info_c_::sched_cell_info_c_( + const cross_carrier_sched_cfg_s::sched_cell_info_c_& other) { type_ = other.type(); switch (type_) { - case types::meas_report: - c.init(other.c.get()); - break; - case types::rrc_recfg_complete: - c.init(other.c.get()); - break; - case types::rrc_setup_complete: - c.init(other.c.get()); - break; - case types::rrc_reest_complete: - c.init(other.c.get()); - break; - case types::rrc_resume_complete: - c.init(other.c.get()); - break; - case types::security_mode_complete: - c.init(other.c.get()); - break; - case types::security_mode_fail: - c.init(other.c.get()); - break; - case types::ul_info_transfer: - c.init(other.c.get()); - break; - case types::location_meas_ind: - c.init(other.c.get()); - break; - case types::ue_cap_info: - c.init(other.c.get()); - break; - case types::counter_check_resp: - c.init(other.c.get()); - break; - case types::ue_assist_info: - c.init(other.c.get()); - break; - case types::fail_info: - c.init(other.c.get()); - break; - case types::spare3: - break; - case types::spare2: + case types::own: + c.init(other.c.get()); break; - case types::spare1: + case types::other: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); } } -ul_dcch_msg_type_c::c1_c_& ul_dcch_msg_type_c::c1_c_::operator=(const ul_dcch_msg_type_c::c1_c_& other) +cross_carrier_sched_cfg_s::sched_cell_info_c_& +cross_carrier_sched_cfg_s::sched_cell_info_c_::operator=(const cross_carrier_sched_cfg_s::sched_cell_info_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::meas_report: - c.set(other.c.get()); - break; - case types::rrc_recfg_complete: - c.set(other.c.get()); - break; - case types::rrc_setup_complete: - c.set(other.c.get()); - break; - case types::rrc_reest_complete: - c.set(other.c.get()); - break; - case types::rrc_resume_complete: - c.set(other.c.get()); - break; - case types::security_mode_complete: - c.set(other.c.get()); - break; - case types::security_mode_fail: - c.set(other.c.get()); - break; - case types::ul_info_transfer: - c.set(other.c.get()); - break; - case types::location_meas_ind: - c.set(other.c.get()); - break; - case types::ue_cap_info: - c.set(other.c.get()); - break; - case types::counter_check_resp: - c.set(other.c.get()); - break; - case types::ue_assist_info: - c.set(other.c.get()); - break; - case types::fail_info: - c.set(other.c.get()); - break; - case types::spare3: - break; - case types::spare2: + case types::own: + c.set(other.c.get()); break; - case types::spare1: + case types::other: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); } return *this; } -void ul_dcch_msg_type_c::c1_c_::to_json(json_writer& j) const +void cross_carrier_sched_cfg_s::sched_cell_info_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::meas_report: - j.write_fieldname("measurementReport"); - c.get().to_json(j); - break; - case types::rrc_recfg_complete: - j.write_fieldname("rrcReconfigurationComplete"); - c.get().to_json(j); - break; - case types::rrc_setup_complete: - j.write_fieldname("rrcSetupComplete"); - c.get().to_json(j); - break; - case types::rrc_reest_complete: - j.write_fieldname("rrcReestablishmentComplete"); - c.get().to_json(j); - break; - case types::rrc_resume_complete: - j.write_fieldname("rrcResumeComplete"); - c.get().to_json(j); - break; - case types::security_mode_complete: - j.write_fieldname("securityModeComplete"); - c.get().to_json(j); - break; - case types::security_mode_fail: - j.write_fieldname("securityModeFailure"); - c.get().to_json(j); - break; - case types::ul_info_transfer: - j.write_fieldname("ulInformationTransfer"); - c.get().to_json(j); - break; - case types::location_meas_ind: - j.write_fieldname("locationMeasurementIndication"); - c.get().to_json(j); - break; - case types::ue_cap_info: - j.write_fieldname("ueCapabilityInformation"); - c.get().to_json(j); - break; - case types::counter_check_resp: - j.write_fieldname("counterCheckResponse"); - c.get().to_json(j); + case types::own: + j.write_fieldname("own"); + j.start_obj(); + j.write_bool("cif-Presence", c.get().cif_presence); + j.end_obj(); break; - case types::ue_assist_info: - j.write_fieldname("ueAssistanceInformation"); - c.get().to_json(j); + case types::other: + j.write_fieldname("other"); + j.start_obj(); + j.write_int("schedulingCellId", c.get().sched_cell_id); + j.write_int("cif-InSchedulingCell", c.get().cif_in_sched_cell); + j.end_obj(); break; - case types::fail_info: - j.write_fieldname("failureInformation"); - c.get().to_json(j); + default: + log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + } + j.end_obj(); +} +SRSASN_CODE cross_carrier_sched_cfg_s::sched_cell_info_c_::pack(bit_ref& bref) const +{ + type_.pack(bref); + switch (type_) { + case types::own: + HANDLE_CODE(bref.pack(c.get().cif_presence, 1)); break; - case types::spare3: + case types::other: + HANDLE_CODE(pack_integer(bref, c.get().sched_cell_id, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(pack_integer(bref, c.get().cif_in_sched_cell, (uint8_t)1u, (uint8_t)7u)); break; - case types::spare2: + default: + log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; +} +SRSASN_CODE cross_carrier_sched_cfg_s::sched_cell_info_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::own: + HANDLE_CODE(bref.unpack(c.get().cif_presence, 1)); break; - case types::spare1: + case types::other: + HANDLE_CODE(unpack_integer(c.get().sched_cell_id, bref, (uint8_t)0u, (uint8_t)31u)); + HANDLE_CODE(unpack_integer(c.get().cif_in_sched_cell, bref, (uint8_t)1u, (uint8_t)7u)); break; default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); + log_invalid_choice_id(type_, "cross_carrier_sched_cfg_s::sched_cell_info_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; +} + +std::string cross_carrier_sched_cfg_s::sched_cell_info_c_::types_opts::to_string() const +{ + static const char* options[] = {"own", "other"}; + return convert_enum_idx(options, 2, value, "cross_carrier_sched_cfg_s::sched_cell_info_c_::types"); +} + +// DL-AM-RLC ::= SEQUENCE +SRSASN_CODE dl_am_rlc_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(sn_field_len_present, 1)); + + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.pack(bref)); + } + HANDLE_CODE(t_reassembly.pack(bref)); + HANDLE_CODE(t_status_prohibit.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE dl_am_rlc_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); + + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.unpack(bref)); + } + HANDLE_CODE(t_reassembly.unpack(bref)); + HANDLE_CODE(t_status_prohibit.unpack(bref)); + + return SRSASN_SUCCESS; +} +void dl_am_rlc_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (sn_field_len_present) { + j.write_str("sn-FieldLength", sn_field_len.to_string()); + } + j.write_str("t-Reassembly", t_reassembly.to_string()); + j.write_str("t-StatusProhibit", t_status_prohibit.to_string()); + j.end_obj(); +} + +// DL-UM-RLC ::= SEQUENCE +SRSASN_CODE dl_um_rlc_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(sn_field_len_present, 1)); + + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.pack(bref)); + } + HANDLE_CODE(t_reassembly.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE dl_um_rlc_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); + + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.unpack(bref)); + } + HANDLE_CODE(t_reassembly.unpack(bref)); + + return SRSASN_SUCCESS; +} +void dl_um_rlc_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (sn_field_len_present) { + j.write_str("sn-FieldLength", sn_field_len.to_string()); + } + j.write_str("t-Reassembly", t_reassembly.to_string()); + j.end_obj(); +} + +// PDCCH-ServingCellConfig ::= SEQUENCE +SRSASN_CODE pdcch_serving_cell_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(slot_format_ind_present, 1)); + + if (slot_format_ind_present) { + HANDLE_CODE(slot_format_ind.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE pdcch_serving_cell_cfg_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(slot_format_ind_present, 1)); + + if (slot_format_ind_present) { + HANDLE_CODE(slot_format_ind.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void pdcch_serving_cell_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (slot_format_ind_present) { + j.write_fieldname("slotFormatIndicator"); + slot_format_ind.to_json(j); + } + j.end_obj(); +} + +// PDSCH-ServingCellConfig ::= SEQUENCE +SRSASN_CODE pdsch_serving_cell_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(code_block_group_tx_present, 1)); + HANDLE_CODE(bref.pack(xoverhead_present, 1)); + HANDLE_CODE(bref.pack(nrof_harq_processes_for_pdsch_present, 1)); + HANDLE_CODE(bref.pack(pucch_cell_present, 1)); + + if (code_block_group_tx_present) { + HANDLE_CODE(code_block_group_tx.pack(bref)); + } + if (xoverhead_present) { + HANDLE_CODE(xoverhead.pack(bref)); + } + if (nrof_harq_processes_for_pdsch_present) { + HANDLE_CODE(nrof_harq_processes_for_pdsch.pack(bref)); + } + if (pucch_cell_present) { + HANDLE_CODE(pack_integer(bref, pucch_cell, (uint8_t)0u, (uint8_t)31u)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= max_mimo_layers_present; + group_flags[0] |= processing_type2_enabled_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(max_mimo_layers_present, 1)); + HANDLE_CODE(bref.pack(processing_type2_enabled_present, 1)); + if (max_mimo_layers_present) { + HANDLE_CODE(pack_integer(bref, max_mimo_layers, (uint8_t)1u, (uint8_t)8u)); + } + if (processing_type2_enabled_present) { + HANDLE_CODE(bref.pack(processing_type2_enabled, 1)); + } + } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE pdsch_serving_cell_cfg_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(code_block_group_tx_present, 1)); + HANDLE_CODE(bref.unpack(xoverhead_present, 1)); + HANDLE_CODE(bref.unpack(nrof_harq_processes_for_pdsch_present, 1)); + HANDLE_CODE(bref.unpack(pucch_cell_present, 1)); + + if (code_block_group_tx_present) { + HANDLE_CODE(code_block_group_tx.unpack(bref)); + } + if (xoverhead_present) { + HANDLE_CODE(xoverhead.unpack(bref)); + } + if (nrof_harq_processes_for_pdsch_present) { + HANDLE_CODE(nrof_harq_processes_for_pdsch.unpack(bref)); + } + if (pucch_cell_present) { + HANDLE_CODE(unpack_integer(pucch_cell, bref, (uint8_t)0u, (uint8_t)31u)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(max_mimo_layers_present, 1)); + HANDLE_CODE(bref.unpack(processing_type2_enabled_present, 1)); + if (max_mimo_layers_present) { + HANDLE_CODE(unpack_integer(max_mimo_layers, bref, (uint8_t)1u, (uint8_t)8u)); + } + if (processing_type2_enabled_present) { + HANDLE_CODE(bref.unpack(processing_type2_enabled, 1)); + } + } + } + return SRSASN_SUCCESS; +} +void pdsch_serving_cell_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (code_block_group_tx_present) { + j.write_fieldname("codeBlockGroupTransmission"); + code_block_group_tx.to_json(j); + } + if (xoverhead_present) { + j.write_str("xOverhead", xoverhead.to_string()); + } + if (nrof_harq_processes_for_pdsch_present) { + j.write_str("nrofHARQ-ProcessesForPDSCH", nrof_harq_processes_for_pdsch.to_string()); + } + if (pucch_cell_present) { + j.write_int("pucch-Cell", pucch_cell); + } + if (ext) { + if (max_mimo_layers_present) { + j.write_int("maxMIMO-Layers", max_mimo_layers); + } + if (processing_type2_enabled_present) { + j.write_bool("processingType2Enabled", processing_type2_enabled); + } + } + j.end_obj(); +} + +std::string pdsch_serving_cell_cfg_s::xoverhead_opts::to_string() const +{ + static const char* options[] = {"xOh6", "xOh12", "xOh18"}; + return convert_enum_idx(options, 3, value, "pdsch_serving_cell_cfg_s::xoverhead_e_"); +} +uint8_t pdsch_serving_cell_cfg_s::xoverhead_opts::to_number() const +{ + static const uint8_t options[] = {6, 12, 18}; + return map_enum_number(options, 3, value, "pdsch_serving_cell_cfg_s::xoverhead_e_"); +} + +std::string pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_opts::to_string() const +{ + static const char* options[] = {"n2", "n4", "n6", "n10", "n12", "n16"}; + return convert_enum_idx(options, 6, value, "pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_e_"); +} +uint8_t pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_opts::to_number() const +{ + static const uint8_t options[] = {2, 4, 6, 10, 12, 16}; + return map_enum_number(options, 6, value, "pdsch_serving_cell_cfg_s::nrof_harq_processes_for_pdsch_e_"); +} + +// RACH-ConfigDedicated ::= SEQUENCE +SRSASN_CODE rach_cfg_ded_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(cfra_present, 1)); + HANDLE_CODE(bref.pack(ra_prioritization_present, 1)); + + if (cfra_present) { + HANDLE_CODE(cfra.pack(bref)); + } + if (ra_prioritization_present) { + HANDLE_CODE(ra_prioritization.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE rach_cfg_ded_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(cfra_present, 1)); + HANDLE_CODE(bref.unpack(ra_prioritization_present, 1)); + + if (cfra_present) { + HANDLE_CODE(cfra.unpack(bref)); + } + if (ra_prioritization_present) { + HANDLE_CODE(ra_prioritization.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void rach_cfg_ded_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (cfra_present) { + j.write_fieldname("cfra"); + cfra.to_json(j); + } + if (ra_prioritization_present) { + j.write_fieldname("ra-Prioritization"); + ra_prioritization.to_json(j); } j.end_obj(); } -SRSASN_CODE ul_dcch_msg_type_c::c1_c_::pack(bit_ref& bref) const + +// SchedulingRequestToAddMod ::= SEQUENCE +SRSASN_CODE sched_request_to_add_mod_s::pack(bit_ref& bref) const { - type_.pack(bref); - switch (type_) { - case types::meas_report: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_recfg_complete: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_setup_complete: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_reest_complete: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::rrc_resume_complete: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::security_mode_complete: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::security_mode_fail: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::ul_info_transfer: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::location_meas_ind: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::ue_cap_info: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::counter_check_resp: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::ue_assist_info: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::fail_info: - HANDLE_CODE(c.get().pack(bref)); - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + HANDLE_CODE(bref.pack(sr_prohibit_timer_present, 1)); + + HANDLE_CODE(pack_integer(bref, sched_request_id, (uint8_t)0u, (uint8_t)7u)); + if (sr_prohibit_timer_present) { + HANDLE_CODE(sr_prohibit_timer.pack(bref)); } + HANDLE_CODE(sr_trans_max.pack(bref)); + return SRSASN_SUCCESS; } -SRSASN_CODE ul_dcch_msg_type_c::c1_c_::unpack(cbit_ref& bref) +SRSASN_CODE sched_request_to_add_mod_s::unpack(cbit_ref& bref) { - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::meas_report: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_recfg_complete: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_setup_complete: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_reest_complete: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::rrc_resume_complete: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::security_mode_complete: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::security_mode_fail: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::ul_info_transfer: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::location_meas_ind: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::ue_cap_info: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::counter_check_resp: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::ue_assist_info: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::fail_info: - HANDLE_CODE(c.get().unpack(bref)); - break; - case types::spare3: - break; - case types::spare2: - break; - case types::spare1: - break; - default: - log_invalid_choice_id(type_, "ul_dcch_msg_type_c::c1_c_"); - return SRSASN_ERROR_DECODE_FAIL; + HANDLE_CODE(bref.unpack(sr_prohibit_timer_present, 1)); + + HANDLE_CODE(unpack_integer(sched_request_id, bref, (uint8_t)0u, (uint8_t)7u)); + if (sr_prohibit_timer_present) { + HANDLE_CODE(sr_prohibit_timer.unpack(bref)); } + HANDLE_CODE(sr_trans_max.unpack(bref)); + return SRSASN_SUCCESS; } +void sched_request_to_add_mod_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("schedulingRequestId", sched_request_id); + if (sr_prohibit_timer_present) { + j.write_str("sr-ProhibitTimer", sr_prohibit_timer.to_string()); + } + j.write_str("sr-TransMax", sr_trans_max.to_string()); + j.end_obj(); +} -std::string ul_dcch_msg_type_c::c1_c_::types_opts::to_string() const +std::string sched_request_to_add_mod_s::sr_prohibit_timer_opts::to_string() const { - static const char* options[] = {"measurementReport", - "rrcReconfigurationComplete", - "rrcSetupComplete", - "rrcReestablishmentComplete", - "rrcResumeComplete", - "securityModeComplete", - "securityModeFailure", - "ulInformationTransfer", - "locationMeasurementIndication", - "ueCapabilityInformation", - "counterCheckResponse", - "ueAssistanceInformation", - "failureInformation", - "spare3", - "spare2", - "spare1"}; - return convert_enum_idx(options, 16, value, "ul_dcch_msg_type_c::c1_c_::types"); + static const char* options[] = {"ms1", "ms2", "ms4", "ms8", "ms16", "ms32", "ms64", "ms128"}; + return convert_enum_idx(options, 8, value, "sched_request_to_add_mod_s::sr_prohibit_timer_e_"); +} +uint8_t sched_request_to_add_mod_s::sr_prohibit_timer_opts::to_number() const +{ + static const uint8_t options[] = {1, 2, 4, 8, 16, 32, 64, 128}; + return map_enum_number(options, 8, value, "sched_request_to_add_mod_s::sr_prohibit_timer_e_"); } -std::string ul_dcch_msg_type_c::types_opts::to_string() const +std::string sched_request_to_add_mod_s::sr_trans_max_opts::to_string() const { - static const char* options[] = {"c1", "messageClassExtension"}; - return convert_enum_idx(options, 2, value, "ul_dcch_msg_type_c::types"); + static const char* options[] = {"n4", "n8", "n16", "n32", "n64", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 8, value, "sched_request_to_add_mod_s::sr_trans_max_e_"); } -uint8_t ul_dcch_msg_type_c::types_opts::to_number() const +uint8_t sched_request_to_add_mod_s::sr_trans_max_opts::to_number() const { - static const uint8_t options[] = {1}; - return map_enum_number(options, 1, value, "ul_dcch_msg_type_c::types"); + static const uint8_t options[] = {4, 8, 16, 32, 64}; + return map_enum_number(options, 5, value, "sched_request_to_add_mod_s::sr_trans_max_e_"); } -// UL-DCCH-Message ::= SEQUENCE -SRSASN_CODE ul_dcch_msg_s::pack(bit_ref& bref) const +// ServingCellConfigCommon ::= SEQUENCE +SRSASN_CODE serving_cell_cfg_common_s::pack(bit_ref& bref) const { - HANDLE_CODE(msg.pack(bref)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(pci_present, 1)); + HANDLE_CODE(bref.pack(dl_cfg_common_present, 1)); + HANDLE_CODE(bref.pack(ul_cfg_common_present, 1)); + HANDLE_CODE(bref.pack(supplementary_ul_cfg_present, 1)); + HANDLE_CODE(bref.pack(n_timing_advance_offset_present, 1)); + HANDLE_CODE(bref.pack(ssb_positions_in_burst_present, 1)); + HANDLE_CODE(bref.pack(ssb_periodicity_serving_cell_present, 1)); + HANDLE_CODE(bref.pack(lte_crs_to_match_around_present, 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(ssb_subcarrier_spacing_present, 1)); + HANDLE_CODE(bref.pack(tdd_ul_dl_cfg_common_present, 1)); - bref.align_bytes_zero(); + if (pci_present) { + HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); + } + if (dl_cfg_common_present) { + HANDLE_CODE(dl_cfg_common.pack(bref)); + } + if (ul_cfg_common_present) { + HANDLE_CODE(ul_cfg_common.pack(bref)); + } + if (supplementary_ul_cfg_present) { + HANDLE_CODE(supplementary_ul_cfg.pack(bref)); + } + if (n_timing_advance_offset_present) { + HANDLE_CODE(n_timing_advance_offset.pack(bref)); + } + if (ssb_positions_in_burst_present) { + HANDLE_CODE(ssb_positions_in_burst.pack(bref)); + } + if (ssb_periodicity_serving_cell_present) { + HANDLE_CODE(ssb_periodicity_serving_cell.pack(bref)); + } + HANDLE_CODE(dmrs_type_a_position.pack(bref)); + if (lte_crs_to_match_around_present) { + HANDLE_CODE(lte_crs_to_match_around.pack(bref)); + } + if (rate_match_pattern_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_add_mod_list, 1, 4)); + } + if (rate_match_pattern_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rate_match_pattern_to_release_list, 1, 4, integer_packer(0, 3))); + } + if (ssb_subcarrier_spacing_present) { + HANDLE_CODE(ssb_subcarrier_spacing.pack(bref)); + } + if (tdd_ul_dl_cfg_common_present) { + HANDLE_CODE(tdd_ul_dl_cfg_common.pack(bref)); + } + HANDLE_CODE(pack_integer(bref, ss_pbch_block_pwr, (int8_t)-60, (int8_t)50)); return SRSASN_SUCCESS; } -SRSASN_CODE ul_dcch_msg_s::unpack(cbit_ref& bref) +SRSASN_CODE serving_cell_cfg_common_s::unpack(cbit_ref& bref) { - HANDLE_CODE(msg.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(pci_present, 1)); + HANDLE_CODE(bref.unpack(dl_cfg_common_present, 1)); + HANDLE_CODE(bref.unpack(ul_cfg_common_present, 1)); + HANDLE_CODE(bref.unpack(supplementary_ul_cfg_present, 1)); + HANDLE_CODE(bref.unpack(n_timing_advance_offset_present, 1)); + HANDLE_CODE(bref.unpack(ssb_positions_in_burst_present, 1)); + HANDLE_CODE(bref.unpack(ssb_periodicity_serving_cell_present, 1)); + HANDLE_CODE(bref.unpack(lte_crs_to_match_around_present, 1)); + HANDLE_CODE(bref.unpack(rate_match_pattern_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(rate_match_pattern_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(ssb_subcarrier_spacing_present, 1)); + HANDLE_CODE(bref.unpack(tdd_ul_dl_cfg_common_present, 1)); - bref.align_bytes(); + if (pci_present) { + HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); + } + if (dl_cfg_common_present) { + HANDLE_CODE(dl_cfg_common.unpack(bref)); + } + if (ul_cfg_common_present) { + HANDLE_CODE(ul_cfg_common.unpack(bref)); + } + if (supplementary_ul_cfg_present) { + HANDLE_CODE(supplementary_ul_cfg.unpack(bref)); + } + if (n_timing_advance_offset_present) { + HANDLE_CODE(n_timing_advance_offset.unpack(bref)); + } + if (ssb_positions_in_burst_present) { + HANDLE_CODE(ssb_positions_in_burst.unpack(bref)); + } + if (ssb_periodicity_serving_cell_present) { + HANDLE_CODE(ssb_periodicity_serving_cell.unpack(bref)); + } + HANDLE_CODE(dmrs_type_a_position.unpack(bref)); + if (lte_crs_to_match_around_present) { + HANDLE_CODE(lte_crs_to_match_around.unpack(bref)); + } + if (rate_match_pattern_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_add_mod_list, bref, 1, 4)); + } + if (rate_match_pattern_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(rate_match_pattern_to_release_list, bref, 1, 4, integer_packer(0, 3))); + } + if (ssb_subcarrier_spacing_present) { + HANDLE_CODE(ssb_subcarrier_spacing.unpack(bref)); + } + if (tdd_ul_dl_cfg_common_present) { + HANDLE_CODE(tdd_ul_dl_cfg_common.unpack(bref)); + } + HANDLE_CODE(unpack_integer(ss_pbch_block_pwr, bref, (int8_t)-60, (int8_t)50)); return SRSASN_SUCCESS; } -void ul_dcch_msg_s::to_json(json_writer& j) const +void serving_cell_cfg_common_s::to_json(json_writer& j) const { - j.start_array(); j.start_obj(); - j.start_obj("UL-DCCH-Message"); - j.write_fieldname("message"); - msg.to_json(j); - j.end_obj(); + if (pci_present) { + j.write_int("physCellId", pci); + } + if (dl_cfg_common_present) { + j.write_fieldname("downlinkConfigCommon"); + dl_cfg_common.to_json(j); + } + if (ul_cfg_common_present) { + j.write_fieldname("uplinkConfigCommon"); + ul_cfg_common.to_json(j); + } + if (supplementary_ul_cfg_present) { + j.write_fieldname("supplementaryUplinkConfig"); + supplementary_ul_cfg.to_json(j); + } + if (n_timing_advance_offset_present) { + j.write_str("n-TimingAdvanceOffset", n_timing_advance_offset.to_string()); + } + if (ssb_positions_in_burst_present) { + j.write_fieldname("ssb-PositionsInBurst"); + ssb_positions_in_burst.to_json(j); + } + if (ssb_periodicity_serving_cell_present) { + j.write_str("ssb-periodicityServingCell", ssb_periodicity_serving_cell.to_string()); + } + j.write_str("dmrs-TypeA-Position", dmrs_type_a_position.to_string()); + if (lte_crs_to_match_around_present) { + j.write_fieldname("lte-CRS-ToMatchAround"); + lte_crs_to_match_around.to_json(j); + } + if (rate_match_pattern_to_add_mod_list_present) { + j.start_array("rateMatchPatternToAddModList"); + for (const auto& e1 : rate_match_pattern_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (rate_match_pattern_to_release_list_present) { + j.start_array("rateMatchPatternToReleaseList"); + for (const auto& e1 : rate_match_pattern_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (ssb_subcarrier_spacing_present) { + j.write_str("ssbSubcarrierSpacing", ssb_subcarrier_spacing.to_string()); + } + if (tdd_ul_dl_cfg_common_present) { + j.write_fieldname("tdd-UL-DL-ConfigurationCommon"); + tdd_ul_dl_cfg_common.to_json(j); + } + j.write_int("ss-PBCH-BlockPower", ss_pbch_block_pwr); j.end_obj(); - j.end_array(); } -// CA-BandwidthClassEUTRA ::= ENUMERATED -std::string ca_bw_class_eutra_opts::to_string() const +std::string serving_cell_cfg_common_s::n_timing_advance_offset_opts::to_string() const { - static const char* options[] = {"a", "b", "c", "d", "e", "f"}; - return convert_enum_idx(options, 6, value, "ca_bw_class_eutra_e"); + static const char* options[] = {"n0", "n25600", "n39936"}; + return convert_enum_idx(options, 3, value, "serving_cell_cfg_common_s::n_timing_advance_offset_e_"); } - -// CA-BandwidthClassNR ::= ENUMERATED -std::string ca_bw_class_nr_opts::to_string() const +uint16_t serving_cell_cfg_common_s::n_timing_advance_offset_opts::to_number() const { - static const char* options[] = {"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q"}; - return convert_enum_idx(options, 17, value, "ca_bw_class_nr_e"); + static const uint16_t options[] = {0, 25600, 39936}; + return map_enum_number(options, 3, value, "serving_cell_cfg_common_s::n_timing_advance_offset_e_"); } -// BandParameters ::= CHOICE -void band_params_c::destroy_() +void serving_cell_cfg_common_s::ssb_positions_in_burst_c_::destroy_() { switch (type_) { - case types::eutra: - c.destroy(); + case types::short_bitmap: + c.destroy >(); break; - case types::nr: - c.destroy(); + case types::medium_bitmap: + c.destroy >(); + break; + case types::long_bitmap: + c.destroy >(); break; default: break; } } -void band_params_c::set(types::options e) +void serving_cell_cfg_common_s::ssb_positions_in_burst_c_::set(types::options e) { destroy_(); type_ = e; switch (type_) { - case types::eutra: - c.init(); + case types::short_bitmap: + c.init >(); break; - case types::nr: - c.init(); + case types::medium_bitmap: + c.init >(); + break; + case types::long_bitmap: + c.init >(); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "band_params_c"); + log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); } } -band_params_c::band_params_c(const band_params_c& other) +serving_cell_cfg_common_s::ssb_positions_in_burst_c_::ssb_positions_in_burst_c_( + const serving_cell_cfg_common_s::ssb_positions_in_burst_c_& other) { type_ = other.type(); switch (type_) { - case types::eutra: - c.init(other.c.get()); + case types::short_bitmap: + c.init(other.c.get >()); break; - case types::nr: - c.init(other.c.get()); + case types::medium_bitmap: + c.init(other.c.get >()); + break; + case types::long_bitmap: + c.init(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "band_params_c"); + log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); } } -band_params_c& band_params_c::operator=(const band_params_c& other) +serving_cell_cfg_common_s::ssb_positions_in_burst_c_& serving_cell_cfg_common_s::ssb_positions_in_burst_c_::operator=( + const serving_cell_cfg_common_s::ssb_positions_in_burst_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::eutra: - c.set(other.c.get()); + case types::short_bitmap: + c.set(other.c.get >()); break; - case types::nr: - c.set(other.c.get()); + case types::medium_bitmap: + c.set(other.c.get >()); + break; + case types::long_bitmap: + c.set(other.c.get >()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "band_params_c"); + log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); } return *this; } -void band_params_c::to_json(json_writer& j) const +void serving_cell_cfg_common_s::ssb_positions_in_burst_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::eutra: - j.write_fieldname("eutra"); - j.start_obj(); - j.write_int("bandEUTRA", c.get().band_eutra); - if (c.get().ca_bw_class_dl_eutra_present) { - j.write_str("ca-BandwidthClassDL-EUTRA", c.get().ca_bw_class_dl_eutra.to_string()); - } - if (c.get().ca_bw_class_ul_eutra_present) { - j.write_str("ca-BandwidthClassUL-EUTRA", c.get().ca_bw_class_ul_eutra.to_string()); - } - j.end_obj(); + case types::short_bitmap: + j.write_str("shortBitmap", c.get >().to_string()); break; - case types::nr: - j.write_fieldname("nr"); - j.start_obj(); - j.write_int("bandNR", c.get().band_nr); - if (c.get().ca_bw_class_dl_nr_present) { - j.write_str("ca-BandwidthClassDL-NR", c.get().ca_bw_class_dl_nr.to_string()); - } - if (c.get().ca_bw_class_ul_nr_present) { - j.write_str("ca-BandwidthClassUL-NR", c.get().ca_bw_class_ul_nr.to_string()); - } - j.end_obj(); + case types::medium_bitmap: + j.write_str("mediumBitmap", c.get >().to_string()); + break; + case types::long_bitmap: + j.write_str("longBitmap", c.get >().to_string()); break; default: - log_invalid_choice_id(type_, "band_params_c"); + log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); } j.end_obj(); } -SRSASN_CODE band_params_c::pack(bit_ref& bref) const +SRSASN_CODE serving_cell_cfg_common_s::ssb_positions_in_burst_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::eutra: - HANDLE_CODE(bref.pack(c.get().ca_bw_class_dl_eutra_present, 1)); - HANDLE_CODE(bref.pack(c.get().ca_bw_class_ul_eutra_present, 1)); - HANDLE_CODE(pack_integer(bref, c.get().band_eutra, (uint16_t)1u, (uint16_t)256u)); - if (c.get().ca_bw_class_dl_eutra_present) { - HANDLE_CODE(c.get().ca_bw_class_dl_eutra.pack(bref)); - } - if (c.get().ca_bw_class_ul_eutra_present) { - HANDLE_CODE(c.get().ca_bw_class_ul_eutra.pack(bref)); - } + case types::short_bitmap: + HANDLE_CODE(c.get >().pack(bref)); break; - case types::nr: - HANDLE_CODE(bref.pack(c.get().ca_bw_class_dl_nr_present, 1)); - HANDLE_CODE(bref.pack(c.get().ca_bw_class_ul_nr_present, 1)); - HANDLE_CODE(pack_integer(bref, c.get().band_nr, (uint16_t)1u, (uint16_t)1024u)); - if (c.get().ca_bw_class_dl_nr_present) { - HANDLE_CODE(c.get().ca_bw_class_dl_nr.pack(bref)); - } - if (c.get().ca_bw_class_ul_nr_present) { - HANDLE_CODE(c.get().ca_bw_class_ul_nr.pack(bref)); - } + case types::medium_bitmap: + HANDLE_CODE(c.get >().pack(bref)); + break; + case types::long_bitmap: + HANDLE_CODE(c.get >().pack(bref)); break; default: - log_invalid_choice_id(type_, "band_params_c"); + log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); return SRSASN_ERROR_ENCODE_FAIL; - } - return SRSASN_SUCCESS; -} -SRSASN_CODE band_params_c::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::eutra: - HANDLE_CODE(bref.unpack(c.get().ca_bw_class_dl_eutra_present, 1)); - HANDLE_CODE(bref.unpack(c.get().ca_bw_class_ul_eutra_present, 1)); - HANDLE_CODE(unpack_integer(c.get().band_eutra, bref, (uint16_t)1u, (uint16_t)256u)); - if (c.get().ca_bw_class_dl_eutra_present) { - HANDLE_CODE(c.get().ca_bw_class_dl_eutra.unpack(bref)); - } - if (c.get().ca_bw_class_ul_eutra_present) { - HANDLE_CODE(c.get().ca_bw_class_ul_eutra.unpack(bref)); - } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE serving_cell_cfg_common_s::ssb_positions_in_burst_c_::unpack(cbit_ref& bref) +{ + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::short_bitmap: + HANDLE_CODE(c.get >().unpack(bref)); break; - case types::nr: - HANDLE_CODE(bref.unpack(c.get().ca_bw_class_dl_nr_present, 1)); - HANDLE_CODE(bref.unpack(c.get().ca_bw_class_ul_nr_present, 1)); - HANDLE_CODE(unpack_integer(c.get().band_nr, bref, (uint16_t)1u, (uint16_t)1024u)); - if (c.get().ca_bw_class_dl_nr_present) { - HANDLE_CODE(c.get().ca_bw_class_dl_nr.unpack(bref)); - } - if (c.get().ca_bw_class_ul_nr_present) { - HANDLE_CODE(c.get().ca_bw_class_ul_nr.unpack(bref)); - } + case types::medium_bitmap: + HANDLE_CODE(c.get >().unpack(bref)); + break; + case types::long_bitmap: + HANDLE_CODE(c.get >().unpack(bref)); break; default: - log_invalid_choice_id(type_, "band_params_c"); + log_invalid_choice_id(type_, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string band_params_c::types_opts::to_string() const +std::string serving_cell_cfg_common_s::ssb_positions_in_burst_c_::types_opts::to_string() const { - static const char* options[] = {"eutra", "nr"}; - return convert_enum_idx(options, 2, value, "band_params_c::types"); + static const char* options[] = {"shortBitmap", "mediumBitmap", "longBitmap"}; + return convert_enum_idx(options, 3, value, "serving_cell_cfg_common_s::ssb_positions_in_burst_c_::types"); } -// CA-ParametersEUTRA ::= SEQUENCE -SRSASN_CODE ca_params_eutra_s::pack(bit_ref& bref) const +std::string serving_cell_cfg_common_s::ssb_periodicity_serving_cell_opts::to_string() const +{ + static const char* options[] = {"ms5", "ms10", "ms20", "ms40", "ms80", "ms160", "spare2", "spare1"}; + return convert_enum_idx(options, 8, value, "serving_cell_cfg_common_s::ssb_periodicity_serving_cell_e_"); +} +uint8_t serving_cell_cfg_common_s::ssb_periodicity_serving_cell_opts::to_number() const +{ + static const uint8_t options[] = {5, 10, 20, 40, 80, 160}; + return map_enum_number(options, 6, value, "serving_cell_cfg_common_s::ssb_periodicity_serving_cell_e_"); +} + +std::string serving_cell_cfg_common_s::dmrs_type_a_position_opts::to_string() const +{ + static const char* options[] = {"pos2", "pos3"}; + return convert_enum_idx(options, 2, value, "serving_cell_cfg_common_s::dmrs_type_a_position_e_"); +} +uint8_t serving_cell_cfg_common_s::dmrs_type_a_position_opts::to_number() const +{ + static const uint8_t options[] = {2, 3}; + return map_enum_number(options, 2, value, "serving_cell_cfg_common_s::dmrs_type_a_position_e_"); +} + +// TAG ::= SEQUENCE +SRSASN_CODE tag_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(multiple_timing_advance_present, 1)); - HANDLE_CODE(bref.pack(simul_rx_tx_present, 1)); - HANDLE_CODE(bref.pack(supported_naics_minus2_crs_ap_present, 1)); - HANDLE_CODE(bref.pack(add_rx_tx_performance_req_present, 1)); - HANDLE_CODE(bref.pack(ue_ca_pwr_class_n_present, 1)); - HANDLE_CODE(bref.pack(supported_bw_combination_set_eutra_v1530_present, 1)); + HANDLE_CODE(pack_integer(bref, tag_id, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(time_align_timer.pack(bref)); - if (supported_naics_minus2_crs_ap_present) { - HANDLE_CODE(supported_naics_minus2_crs_ap.pack(bref)); + return SRSASN_SUCCESS; +} +SRSASN_CODE tag_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_integer(tag_id, bref, (uint8_t)0u, (uint8_t)3u)); + HANDLE_CODE(time_align_timer.unpack(bref)); + + return SRSASN_SUCCESS; +} +void tag_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("tag-Id", tag_id); + j.write_str("timeAlignmentTimer", time_align_timer.to_string()); + j.end_obj(); +} + +// TDD-UL-DL-ConfigDedicated ::= SEQUENCE +SRSASN_CODE tdd_ul_dl_cfg_ded_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(slot_specific_cfgs_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(slot_specific_cfgs_to_release_list_present, 1)); + + if (slot_specific_cfgs_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, slot_specific_cfgs_to_add_mod_list, 1, 320)); } - if (supported_bw_combination_set_eutra_v1530_present) { - HANDLE_CODE(supported_bw_combination_set_eutra_v1530.pack(bref)); + if (slot_specific_cfgs_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, slot_specific_cfgs_to_release_list, 1, 320, integer_packer(0, 319))); } return SRSASN_SUCCESS; } -SRSASN_CODE ca_params_eutra_s::unpack(cbit_ref& bref) +SRSASN_CODE tdd_ul_dl_cfg_ded_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(multiple_timing_advance_present, 1)); - HANDLE_CODE(bref.unpack(simul_rx_tx_present, 1)); - HANDLE_CODE(bref.unpack(supported_naics_minus2_crs_ap_present, 1)); - HANDLE_CODE(bref.unpack(add_rx_tx_performance_req_present, 1)); - HANDLE_CODE(bref.unpack(ue_ca_pwr_class_n_present, 1)); - HANDLE_CODE(bref.unpack(supported_bw_combination_set_eutra_v1530_present, 1)); + HANDLE_CODE(bref.unpack(slot_specific_cfgs_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(slot_specific_cfgs_to_release_list_present, 1)); - if (supported_naics_minus2_crs_ap_present) { - HANDLE_CODE(supported_naics_minus2_crs_ap.unpack(bref)); + if (slot_specific_cfgs_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(slot_specific_cfgs_to_add_mod_list, bref, 1, 320)); } - if (supported_bw_combination_set_eutra_v1530_present) { - HANDLE_CODE(supported_bw_combination_set_eutra_v1530.unpack(bref)); + if (slot_specific_cfgs_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(slot_specific_cfgs_to_release_list, bref, 1, 320, integer_packer(0, 319))); } return SRSASN_SUCCESS; } -void ca_params_eutra_s::to_json(json_writer& j) const +void tdd_ul_dl_cfg_ded_s::to_json(json_writer& j) const { j.start_obj(); - if (multiple_timing_advance_present) { - j.write_str("multipleTimingAdvance", "supported"); - } - if (simul_rx_tx_present) { - j.write_str("simultaneousRx-Tx", "supported"); - } - if (supported_naics_minus2_crs_ap_present) { - j.write_str("supportedNAICS-2CRS-AP", supported_naics_minus2_crs_ap.to_string()); - } - if (add_rx_tx_performance_req_present) { - j.write_str("additionalRx-Tx-PerformanceReq", "supported"); - } - if (ue_ca_pwr_class_n_present) { - j.write_str("ue-CA-PowerClass-N", "class2"); + if (slot_specific_cfgs_to_add_mod_list_present) { + j.start_array("slotSpecificConfigurationsToAddModList"); + for (const auto& e1 : slot_specific_cfgs_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - if (supported_bw_combination_set_eutra_v1530_present) { - j.write_str("supportedBandwidthCombinationSetEUTRA-v1530", supported_bw_combination_set_eutra_v1530.to_string()); + if (slot_specific_cfgs_to_release_list_present) { + j.start_array("slotSpecificConfigurationsToReleaseList"); + for (const auto& e1 : slot_specific_cfgs_to_release_list) { + j.write_int(e1); + } + j.end_array(); } j.end_obj(); } -// CA-ParametersNR ::= SEQUENCE -SRSASN_CODE ca_params_nr_s::pack(bit_ref& bref) const +// UL-AM-RLC ::= SEQUENCE +SRSASN_CODE ul_am_rlc_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(multiple_timing_advances_present, 1)); - HANDLE_CODE(bref.pack(parallel_tx_srs_pucch_pusch_present, 1)); - HANDLE_CODE(bref.pack(parallel_tx_prach_srs_pucch_pusch_present, 1)); - HANDLE_CODE(bref.pack(simul_rx_tx_inter_band_ca_present, 1)); - HANDLE_CODE(bref.pack(simul_rx_tx_sul_present, 1)); - HANDLE_CODE(bref.pack(diff_numerology_across_pucch_group_present, 1)); - HANDLE_CODE(bref.pack(diff_numerology_within_pucch_group_present, 1)); - HANDLE_CODE(bref.pack(supported_num_tag_present, 1)); + HANDLE_CODE(bref.pack(sn_field_len_present, 1)); - if (supported_num_tag_present) { - HANDLE_CODE(supported_num_tag.pack(bref)); + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.pack(bref)); } + HANDLE_CODE(t_poll_retx.pack(bref)); + HANDLE_CODE(poll_pdu.pack(bref)); + HANDLE_CODE(poll_byte.pack(bref)); + HANDLE_CODE(max_retx_thres.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE ca_params_nr_s::unpack(cbit_ref& bref) +SRSASN_CODE ul_am_rlc_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(multiple_timing_advances_present, 1)); - HANDLE_CODE(bref.unpack(parallel_tx_srs_pucch_pusch_present, 1)); - HANDLE_CODE(bref.unpack(parallel_tx_prach_srs_pucch_pusch_present, 1)); - HANDLE_CODE(bref.unpack(simul_rx_tx_inter_band_ca_present, 1)); - HANDLE_CODE(bref.unpack(simul_rx_tx_sul_present, 1)); - HANDLE_CODE(bref.unpack(diff_numerology_across_pucch_group_present, 1)); - HANDLE_CODE(bref.unpack(diff_numerology_within_pucch_group_present, 1)); - HANDLE_CODE(bref.unpack(supported_num_tag_present, 1)); + HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); - if (supported_num_tag_present) { - HANDLE_CODE(supported_num_tag.unpack(bref)); + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.unpack(bref)); } + HANDLE_CODE(t_poll_retx.unpack(bref)); + HANDLE_CODE(poll_pdu.unpack(bref)); + HANDLE_CODE(poll_byte.unpack(bref)); + HANDLE_CODE(max_retx_thres.unpack(bref)); return SRSASN_SUCCESS; } -void ca_params_nr_s::to_json(json_writer& j) const +void ul_am_rlc_s::to_json(json_writer& j) const { j.start_obj(); - if (multiple_timing_advances_present) { - j.write_str("multipleTimingAdvances", "supported"); - } - if (parallel_tx_srs_pucch_pusch_present) { - j.write_str("parallelTxSRS-PUCCH-PUSCH", "supported"); - } - if (parallel_tx_prach_srs_pucch_pusch_present) { - j.write_str("parallelTxPRACH-SRS-PUCCH-PUSCH", "supported"); - } - if (simul_rx_tx_inter_band_ca_present) { - j.write_str("simultaneousRxTxInterBandCA", "supported"); - } - if (simul_rx_tx_sul_present) { - j.write_str("simultaneousRxTxSUL", "supported"); - } - if (diff_numerology_across_pucch_group_present) { - j.write_str("diffNumerologyAcrossPUCCH-Group", "supported"); - } - if (diff_numerology_within_pucch_group_present) { - j.write_str("diffNumerologyWithinPUCCH-Group", "supported"); - } - if (supported_num_tag_present) { - j.write_str("supportedNumberTAG", supported_num_tag.to_string()); + if (sn_field_len_present) { + j.write_str("sn-FieldLength", sn_field_len.to_string()); } + j.write_str("t-PollRetransmit", t_poll_retx.to_string()); + j.write_str("pollPDU", poll_pdu.to_string()); + j.write_str("pollByte", poll_byte.to_string()); + j.write_str("maxRetxThreshold", max_retx_thres.to_string()); j.end_obj(); } -std::string ca_params_nr_s::supported_num_tag_opts::to_string() const +std::string ul_am_rlc_s::max_retx_thres_opts::to_string() const { - static const char* options[] = {"n2", "n3", "n4"}; - return convert_enum_idx(options, 3, value, "ca_params_nr_s::supported_num_tag_e_"); + static const char* options[] = {"t1", "t2", "t3", "t4", "t6", "t8", "t16", "t32"}; + return convert_enum_idx(options, 8, value, "ul_am_rlc_s::max_retx_thres_e_"); } -uint8_t ca_params_nr_s::supported_num_tag_opts::to_number() const +uint8_t ul_am_rlc_s::max_retx_thres_opts::to_number() const { - static const uint8_t options[] = {2, 3, 4}; - return map_enum_number(options, 3, value, "ca_params_nr_s::supported_num_tag_e_"); + static const uint8_t options[] = {1, 2, 3, 4, 6, 8, 16, 32}; + return map_enum_number(options, 8, value, "ul_am_rlc_s::max_retx_thres_e_"); } -// MRDC-Parameters ::= SEQUENCE -SRSASN_CODE mrdc_params_s::pack(bit_ref& bref) const +// UL-UM-RLC ::= SEQUENCE +SRSASN_CODE ul_um_rlc_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(sn_field_len_present, 1)); + + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE ul_um_rlc_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(sn_field_len_present, 1)); + + if (sn_field_len_present) { + HANDLE_CODE(sn_field_len.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void ul_um_rlc_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (sn_field_len_present) { + j.write_str("sn-FieldLength", sn_field_len.to_string()); + } + j.end_obj(); +} + +// UplinkConfig ::= SEQUENCE +SRSASN_CODE ul_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(single_ul_tx_present, 1)); - HANDLE_CODE(bref.pack(dynamic_pwr_sharing_present, 1)); - HANDLE_CODE(bref.pack(tdm_pattern_present, 1)); - HANDLE_CODE(bref.pack(ul_sharing_eutra_nr_present, 1)); - HANDLE_CODE(bref.pack(ul_switching_time_eutra_nr_present, 1)); - HANDLE_CODE(bref.pack(simul_rx_tx_inter_band_endc_present, 1)); - HANDLE_CODE(bref.pack(async_intra_band_endc_present, 1)); + HANDLE_CODE(bref.pack(init_ul_bwp_present, 1)); + HANDLE_CODE(bref.pack(ul_bwp_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(ul_bwp_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(first_active_ul_bwp_id_present, 1)); + HANDLE_CODE(bref.pack(pusch_serving_cell_cfg_present, 1)); + HANDLE_CODE(bref.pack(carrier_switching_present, 1)); - if (ul_sharing_eutra_nr_present) { - HANDLE_CODE(ul_sharing_eutra_nr.pack(bref)); + if (init_ul_bwp_present) { + HANDLE_CODE(init_ul_bwp.pack(bref)); } - if (ul_switching_time_eutra_nr_present) { - HANDLE_CODE(ul_switching_time_eutra_nr.pack(bref)); + if (ul_bwp_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ul_bwp_to_release_list, 1, 4, integer_packer(0, 4))); + } + if (ul_bwp_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, ul_bwp_to_add_mod_list, 1, 4)); + } + if (first_active_ul_bwp_id_present) { + HANDLE_CODE(pack_integer(bref, first_active_ul_bwp_id, (uint8_t)0u, (uint8_t)4u)); + } + if (pusch_serving_cell_cfg_present) { + HANDLE_CODE(pusch_serving_cell_cfg.pack(bref)); + } + if (carrier_switching_present) { + HANDLE_CODE(carrier_switching.pack(bref)); } if (ext) { ext_groups_packer_guard group_flags; - group_flags[0] |= dual_pa_architecture_present; - group_flags[0] |= intra_band_endc_support_v1540_present; - group_flags[0] |= ul_timing_align_eutra_nr_present; + group_flags[0] |= pwr_boost_pi2_bpsk_present; + group_flags[0] |= ul_ch_bw_per_scs_list.is_present(); group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(dual_pa_architecture_present, 1)); - HANDLE_CODE(bref.pack(intra_band_endc_support_v1540_present, 1)); - HANDLE_CODE(bref.pack(ul_timing_align_eutra_nr_present, 1)); - if (intra_band_endc_support_v1540_present) { - HANDLE_CODE(intra_band_endc_support_v1540.pack(bref)); + HANDLE_CODE(bref.pack(pwr_boost_pi2_bpsk_present, 1)); + HANDLE_CODE(bref.pack(ul_ch_bw_per_scs_list.is_present(), 1)); + if (pwr_boost_pi2_bpsk_present) { + HANDLE_CODE(bref.pack(pwr_boost_pi2_bpsk, 1)); + } + if (ul_ch_bw_per_scs_list.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *ul_ch_bw_per_scs_list, 1, 5)); } } } return SRSASN_SUCCESS; } -SRSASN_CODE mrdc_params_s::unpack(cbit_ref& bref) +SRSASN_CODE ul_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(single_ul_tx_present, 1)); - HANDLE_CODE(bref.unpack(dynamic_pwr_sharing_present, 1)); - HANDLE_CODE(bref.unpack(tdm_pattern_present, 1)); - HANDLE_CODE(bref.unpack(ul_sharing_eutra_nr_present, 1)); - HANDLE_CODE(bref.unpack(ul_switching_time_eutra_nr_present, 1)); - HANDLE_CODE(bref.unpack(simul_rx_tx_inter_band_endc_present, 1)); - HANDLE_CODE(bref.unpack(async_intra_band_endc_present, 1)); + HANDLE_CODE(bref.unpack(init_ul_bwp_present, 1)); + HANDLE_CODE(bref.unpack(ul_bwp_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(ul_bwp_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(first_active_ul_bwp_id_present, 1)); + HANDLE_CODE(bref.unpack(pusch_serving_cell_cfg_present, 1)); + HANDLE_CODE(bref.unpack(carrier_switching_present, 1)); - if (ul_sharing_eutra_nr_present) { - HANDLE_CODE(ul_sharing_eutra_nr.unpack(bref)); + if (init_ul_bwp_present) { + HANDLE_CODE(init_ul_bwp.unpack(bref)); } - if (ul_switching_time_eutra_nr_present) { - HANDLE_CODE(ul_switching_time_eutra_nr.unpack(bref)); + if (ul_bwp_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ul_bwp_to_release_list, bref, 1, 4, integer_packer(0, 4))); + } + if (ul_bwp_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(ul_bwp_to_add_mod_list, bref, 1, 4)); + } + if (first_active_ul_bwp_id_present) { + HANDLE_CODE(unpack_integer(first_active_ul_bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); + } + if (pusch_serving_cell_cfg_present) { + HANDLE_CODE(pusch_serving_cell_cfg.unpack(bref)); + } + if (carrier_switching_present) { + HANDLE_CODE(carrier_switching.unpack(bref)); } if (ext) { @@ -42530,1751 +45175,1832 @@ SRSASN_CODE mrdc_params_s::unpack(cbit_ref& bref) if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.unpack(dual_pa_architecture_present, 1)); - HANDLE_CODE(bref.unpack(intra_band_endc_support_v1540_present, 1)); - HANDLE_CODE(bref.unpack(ul_timing_align_eutra_nr_present, 1)); - if (intra_band_endc_support_v1540_present) { - HANDLE_CODE(intra_band_endc_support_v1540.unpack(bref)); + HANDLE_CODE(bref.unpack(pwr_boost_pi2_bpsk_present, 1)); + bool ul_ch_bw_per_scs_list_present; + HANDLE_CODE(bref.unpack(ul_ch_bw_per_scs_list_present, 1)); + ul_ch_bw_per_scs_list.set_present(ul_ch_bw_per_scs_list_present); + if (pwr_boost_pi2_bpsk_present) { + HANDLE_CODE(bref.unpack(pwr_boost_pi2_bpsk, 1)); + } + if (ul_ch_bw_per_scs_list.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*ul_ch_bw_per_scs_list, bref, 1, 5)); } } } return SRSASN_SUCCESS; } -void mrdc_params_s::to_json(json_writer& j) const +void ul_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (single_ul_tx_present) { - j.write_str("singleUL-Transmission", "supported"); - } - if (dynamic_pwr_sharing_present) { - j.write_str("dynamicPowerSharing", "supported"); + if (init_ul_bwp_present) { + j.write_fieldname("initialUplinkBWP"); + init_ul_bwp.to_json(j); } - if (tdm_pattern_present) { - j.write_str("tdm-Pattern", "supported"); + if (ul_bwp_to_release_list_present) { + j.start_array("uplinkBWP-ToReleaseList"); + for (const auto& e1 : ul_bwp_to_release_list) { + j.write_int(e1); + } + j.end_array(); } - if (ul_sharing_eutra_nr_present) { - j.write_str("ul-SharingEUTRA-NR", ul_sharing_eutra_nr.to_string()); + if (ul_bwp_to_add_mod_list_present) { + j.start_array("uplinkBWP-ToAddModList"); + for (const auto& e1 : ul_bwp_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - if (ul_switching_time_eutra_nr_present) { - j.write_str("ul-SwitchingTimeEUTRA-NR", ul_switching_time_eutra_nr.to_string()); + if (first_active_ul_bwp_id_present) { + j.write_int("firstActiveUplinkBWP-Id", first_active_ul_bwp_id); } - if (simul_rx_tx_inter_band_endc_present) { - j.write_str("simultaneousRxTxInterBandENDC", "supported"); + if (pusch_serving_cell_cfg_present) { + j.write_fieldname("pusch-ServingCellConfig"); + pusch_serving_cell_cfg.to_json(j); } - if (async_intra_band_endc_present) { - j.write_str("asyncIntraBandENDC", "supported"); + if (carrier_switching_present) { + j.write_fieldname("carrierSwitching"); + carrier_switching.to_json(j); } if (ext) { - if (dual_pa_architecture_present) { - j.write_str("dualPA-Architecture", "supported"); - } - if (intra_band_endc_support_v1540_present) { - j.write_str("intraBandENDC-Support-v1540", intra_band_endc_support_v1540.to_string()); + if (pwr_boost_pi2_bpsk_present) { + j.write_bool("powerBoostPi2BPSK", pwr_boost_pi2_bpsk); } - if (ul_timing_align_eutra_nr_present) { - j.write_str("ul-TimingAlignmentEUTRA-NR", "required"); + if (ul_ch_bw_per_scs_list.is_present()) { + j.start_array("uplinkChannelBW-PerSCS-List"); + for (const auto& e1 : *ul_ch_bw_per_scs_list) { + e1.to_json(j); + } + j.end_array(); } } j.end_obj(); } -std::string mrdc_params_s::ul_sharing_eutra_nr_opts::to_string() const -{ - static const char* options[] = {"tdm", "fdm", "both"}; - return convert_enum_idx(options, 3, value, "mrdc_params_s::ul_sharing_eutra_nr_e_"); -} - -std::string mrdc_params_s::ul_switching_time_eutra_nr_opts::to_string() const -{ - static const char* options[] = {"type1", "type2"}; - return convert_enum_idx(options, 2, value, "mrdc_params_s::ul_switching_time_eutra_nr_e_"); -} -uint8_t mrdc_params_s::ul_switching_time_eutra_nr_opts::to_number() const -{ - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "mrdc_params_s::ul_switching_time_eutra_nr_e_"); -} - -std::string mrdc_params_s::intra_band_endc_support_v1540_opts::to_string() const -{ - static const char* options[] = {"non-contiguous", "both"}; - return convert_enum_idx(options, 2, value, "mrdc_params_s::intra_band_endc_support_v1540_e_"); -} - -// BandCombination ::= SEQUENCE -SRSASN_CODE band_combination_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(ca_params_eutra_present, 1)); - HANDLE_CODE(bref.pack(ca_params_nr_present, 1)); - HANDLE_CODE(bref.pack(mrdc_params_present, 1)); - HANDLE_CODE(bref.pack(supported_bw_combination_set_present, 1)); - HANDLE_CODE(bref.pack(pwr_class_v1530_present, 1)); - - HANDLE_CODE(pack_dyn_seq_of(bref, band_list, 1, 32)); - HANDLE_CODE(pack_integer(bref, feature_set_combination, (uint16_t)0u, (uint16_t)1024u)); - if (ca_params_eutra_present) { - HANDLE_CODE(ca_params_eutra.pack(bref)); - } - if (ca_params_nr_present) { - HANDLE_CODE(ca_params_nr.pack(bref)); - } - if (mrdc_params_present) { - HANDLE_CODE(mrdc_params.pack(bref)); - } - if (supported_bw_combination_set_present) { - HANDLE_CODE(supported_bw_combination_set.pack(bref)); - } - - return SRSASN_SUCCESS; -} -SRSASN_CODE band_combination_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(ca_params_eutra_present, 1)); - HANDLE_CODE(bref.unpack(ca_params_nr_present, 1)); - HANDLE_CODE(bref.unpack(mrdc_params_present, 1)); - HANDLE_CODE(bref.unpack(supported_bw_combination_set_present, 1)); - HANDLE_CODE(bref.unpack(pwr_class_v1530_present, 1)); - - HANDLE_CODE(unpack_dyn_seq_of(band_list, bref, 1, 32)); - HANDLE_CODE(unpack_integer(feature_set_combination, bref, (uint16_t)0u, (uint16_t)1024u)); - if (ca_params_eutra_present) { - HANDLE_CODE(ca_params_eutra.unpack(bref)); - } - if (ca_params_nr_present) { - HANDLE_CODE(ca_params_nr.unpack(bref)); - } - if (mrdc_params_present) { - HANDLE_CODE(mrdc_params.unpack(bref)); - } - if (supported_bw_combination_set_present) { - HANDLE_CODE(supported_bw_combination_set.unpack(bref)); - } - - return SRSASN_SUCCESS; -} -void band_combination_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.start_array("bandList"); - for (const auto& e1 : band_list) { - e1.to_json(j); - } - j.end_array(); - j.write_int("featureSetCombination", feature_set_combination); - if (ca_params_eutra_present) { - j.write_fieldname("ca-ParametersEUTRA"); - ca_params_eutra.to_json(j); - } - if (ca_params_nr_present) { - j.write_fieldname("ca-ParametersNR"); - ca_params_nr.to_json(j); - } - if (mrdc_params_present) { - j.write_fieldname("mrdc-Parameters"); - mrdc_params.to_json(j); - } - if (supported_bw_combination_set_present) { - j.write_str("supportedBandwidthCombinationSet", supported_bw_combination_set.to_string()); - } - if (pwr_class_v1530_present) { - j.write_str("powerClass-v1530", "pc2"); - } - j.end_obj(); -} - -// SRS-SwitchingTimeEUTRA ::= SEQUENCE -SRSASN_CODE srs_switching_time_eutra_s::pack(bit_ref& bref) const +// BSR-Config ::= SEQUENCE +SRSASN_CODE bsr_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(switching_time_dl_present, 1)); - HANDLE_CODE(bref.pack(switching_time_ul_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(lc_ch_sr_delay_timer_present, 1)); - if (switching_time_dl_present) { - HANDLE_CODE(switching_time_dl.pack(bref)); - } - if (switching_time_ul_present) { - HANDLE_CODE(switching_time_ul.pack(bref)); + HANDLE_CODE(periodic_bsr_timer.pack(bref)); + HANDLE_CODE(retx_bsr_timer.pack(bref)); + if (lc_ch_sr_delay_timer_present) { + HANDLE_CODE(lc_ch_sr_delay_timer.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE srs_switching_time_eutra_s::unpack(cbit_ref& bref) +SRSASN_CODE bsr_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(switching_time_dl_present, 1)); - HANDLE_CODE(bref.unpack(switching_time_ul_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(lc_ch_sr_delay_timer_present, 1)); - if (switching_time_dl_present) { - HANDLE_CODE(switching_time_dl.unpack(bref)); - } - if (switching_time_ul_present) { - HANDLE_CODE(switching_time_ul.unpack(bref)); + HANDLE_CODE(periodic_bsr_timer.unpack(bref)); + HANDLE_CODE(retx_bsr_timer.unpack(bref)); + if (lc_ch_sr_delay_timer_present) { + HANDLE_CODE(lc_ch_sr_delay_timer.unpack(bref)); } return SRSASN_SUCCESS; } -void srs_switching_time_eutra_s::to_json(json_writer& j) const +void bsr_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (switching_time_dl_present) { - j.write_str("switchingTimeDL", switching_time_dl.to_string()); - } - if (switching_time_ul_present) { - j.write_str("switchingTimeUL", switching_time_ul.to_string()); + j.write_str("periodicBSR-Timer", periodic_bsr_timer.to_string()); + j.write_str("retxBSR-Timer", retx_bsr_timer.to_string()); + if (lc_ch_sr_delay_timer_present) { + j.write_str("logicalChannelSR-DelayTimer", lc_ch_sr_delay_timer.to_string()); } j.end_obj(); } -std::string srs_switching_time_eutra_s::switching_time_dl_opts::to_string() const +std::string bsr_cfg_s::periodic_bsr_timer_opts::to_string() const { - static const char* options[] = {"n0", - "n0dot5", - "n1", - "n1dot5", - "n2", - "n2dot5", - "n3", - "n3dot5", - "n4", - "n4dot5", - "n5", - "n5dot5", - "n6", - "n6dot5", - "n7"}; - return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_dl_e_"); + static const char* options[] = {"sf1", + "sf5", + "sf10", + "sf16", + "sf20", + "sf32", + "sf40", + "sf64", + "sf80", + "sf128", + "sf160", + "sf320", + "sf640", + "sf1280", + "sf2560", + "infinity"}; + return convert_enum_idx(options, 16, value, "bsr_cfg_s::periodic_bsr_timer_e_"); } -float srs_switching_time_eutra_s::switching_time_dl_opts::to_number() const +int16_t bsr_cfg_s::periodic_bsr_timer_opts::to_number() const { - static const float options[] = {0.0, 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5, 5.0, 5.5, 6.0, 6.5, 7.0}; - return map_enum_number(options, 15, value, "srs_switching_time_eutra_s::switching_time_dl_e_"); + static const int16_t options[] = {1, 5, 10, 16, 20, 32, 40, 64, 80, 128, 160, 320, 640, 1280, 2560, -1}; + return map_enum_number(options, 16, value, "bsr_cfg_s::periodic_bsr_timer_e_"); } -std::string srs_switching_time_eutra_s::switching_time_dl_opts::to_number_string() const + +std::string bsr_cfg_s::retx_bsr_timer_opts::to_string() const { - static const char* options[] = { - "0", "0.5", "1", "1.5", "2", "2.5", "3", "3.5", "4", "4.5", "5", "5.5", "6", "6.5", "7"}; - return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_dl_e_"); + static const char* options[] = {"sf10", + "sf20", + "sf40", + "sf80", + "sf160", + "sf320", + "sf640", + "sf1280", + "sf2560", + "sf5120", + "sf10240", + "spare5", + "spare4", + "spare3", + "spare2", + "spare1"}; + return convert_enum_idx(options, 16, value, "bsr_cfg_s::retx_bsr_timer_e_"); } - -std::string srs_switching_time_eutra_s::switching_time_ul_opts::to_string() const +uint16_t bsr_cfg_s::retx_bsr_timer_opts::to_number() const { - static const char* options[] = {"n0", - "n0dot5", - "n1", - "n1dot5", - "n2", - "n2dot5", - "n3", - "n3dot5", - "n4", - "n4dot5", - "n5", - "n5dot5", - "n6", - "n6dot5", - "n7"}; - return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_ul_e_"); + static const uint16_t options[] = {10, 20, 40, 80, 160, 320, 640, 1280, 2560, 5120, 10240}; + return map_enum_number(options, 11, value, "bsr_cfg_s::retx_bsr_timer_e_"); } -float srs_switching_time_eutra_s::switching_time_ul_opts::to_number() const + +std::string bsr_cfg_s::lc_ch_sr_delay_timer_opts::to_string() const { - static const float options[] = {0.0, 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5, 5.0, 5.5, 6.0, 6.5, 7.0}; - return map_enum_number(options, 15, value, "srs_switching_time_eutra_s::switching_time_ul_e_"); + static const char* options[] = {"sf20", "sf40", "sf64", "sf128", "sf512", "sf1024", "sf2560", "spare1"}; + return convert_enum_idx(options, 8, value, "bsr_cfg_s::lc_ch_sr_delay_timer_e_"); } -std::string srs_switching_time_eutra_s::switching_time_ul_opts::to_number_string() const +uint16_t bsr_cfg_s::lc_ch_sr_delay_timer_opts::to_number() const { - static const char* options[] = { - "0", "0.5", "1", "1.5", "2", "2.5", "3", "3.5", "4", "4.5", "5", "5.5", "6", "6.5", "7"}; - return convert_enum_idx(options, 15, value, "srs_switching_time_eutra_s::switching_time_ul_e_"); + static const uint16_t options[] = {20, 40, 64, 128, 512, 1024, 2560}; + return map_enum_number(options, 7, value, "bsr_cfg_s::lc_ch_sr_delay_timer_e_"); } -// SRS-SwitchingTimeNR ::= SEQUENCE -SRSASN_CODE srs_switching_time_nr_s::pack(bit_ref& bref) const +// DRX-Config ::= SEQUENCE +SRSASN_CODE drx_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(switching_time_dl_present, 1)); - HANDLE_CODE(bref.pack(switching_time_ul_present, 1)); + HANDLE_CODE(bref.pack(short_drx_present, 1)); - if (switching_time_dl_present) { - HANDLE_CODE(switching_time_dl.pack(bref)); - } - if (switching_time_ul_present) { - HANDLE_CODE(switching_time_ul.pack(bref)); + HANDLE_CODE(drx_on_dur_timer.pack(bref)); + HANDLE_CODE(drx_inactivity_timer.pack(bref)); + HANDLE_CODE(pack_integer(bref, drx_harq_rtt_timer_dl, (uint8_t)0u, (uint8_t)56u)); + HANDLE_CODE(pack_integer(bref, drx_harq_rtt_timer_ul, (uint8_t)0u, (uint8_t)56u)); + HANDLE_CODE(drx_retx_timer_dl.pack(bref)); + HANDLE_CODE(drx_retx_timer_ul.pack(bref)); + HANDLE_CODE(drx_long_cycle_start_offset.pack(bref)); + if (short_drx_present) { + HANDLE_CODE(short_drx.drx_short_cycle.pack(bref)); + HANDLE_CODE(pack_integer(bref, short_drx.drx_short_cycle_timer, (uint8_t)1u, (uint8_t)16u)); } + HANDLE_CODE(pack_integer(bref, drx_slot_offset, (uint8_t)0u, (uint8_t)31u)); return SRSASN_SUCCESS; } -SRSASN_CODE srs_switching_time_nr_s::unpack(cbit_ref& bref) +SRSASN_CODE drx_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(switching_time_dl_present, 1)); - HANDLE_CODE(bref.unpack(switching_time_ul_present, 1)); + HANDLE_CODE(bref.unpack(short_drx_present, 1)); - if (switching_time_dl_present) { - HANDLE_CODE(switching_time_dl.unpack(bref)); - } - if (switching_time_ul_present) { - HANDLE_CODE(switching_time_ul.unpack(bref)); + HANDLE_CODE(drx_on_dur_timer.unpack(bref)); + HANDLE_CODE(drx_inactivity_timer.unpack(bref)); + HANDLE_CODE(unpack_integer(drx_harq_rtt_timer_dl, bref, (uint8_t)0u, (uint8_t)56u)); + HANDLE_CODE(unpack_integer(drx_harq_rtt_timer_ul, bref, (uint8_t)0u, (uint8_t)56u)); + HANDLE_CODE(drx_retx_timer_dl.unpack(bref)); + HANDLE_CODE(drx_retx_timer_ul.unpack(bref)); + HANDLE_CODE(drx_long_cycle_start_offset.unpack(bref)); + if (short_drx_present) { + HANDLE_CODE(short_drx.drx_short_cycle.unpack(bref)); + HANDLE_CODE(unpack_integer(short_drx.drx_short_cycle_timer, bref, (uint8_t)1u, (uint8_t)16u)); } + HANDLE_CODE(unpack_integer(drx_slot_offset, bref, (uint8_t)0u, (uint8_t)31u)); return SRSASN_SUCCESS; } -void srs_switching_time_nr_s::to_json(json_writer& j) const +void drx_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (switching_time_dl_present) { - j.write_str("switchingTimeDL", switching_time_dl.to_string()); - } - if (switching_time_ul_present) { - j.write_str("switchingTimeUL", switching_time_ul.to_string()); + j.write_fieldname("drx-onDurationTimer"); + drx_on_dur_timer.to_json(j); + j.write_str("drx-InactivityTimer", drx_inactivity_timer.to_string()); + j.write_int("drx-HARQ-RTT-TimerDL", drx_harq_rtt_timer_dl); + j.write_int("drx-HARQ-RTT-TimerUL", drx_harq_rtt_timer_ul); + j.write_str("drx-RetransmissionTimerDL", drx_retx_timer_dl.to_string()); + j.write_str("drx-RetransmissionTimerUL", drx_retx_timer_ul.to_string()); + j.write_fieldname("drx-LongCycleStartOffset"); + drx_long_cycle_start_offset.to_json(j); + if (short_drx_present) { + j.write_fieldname("shortDRX"); + j.start_obj(); + j.write_str("drx-ShortCycle", short_drx.drx_short_cycle.to_string()); + j.write_int("drx-ShortCycleTimer", short_drx.drx_short_cycle_timer); + j.end_obj(); } + j.write_int("drx-SlotOffset", drx_slot_offset); j.end_obj(); } -std::string srs_switching_time_nr_s::switching_time_dl_opts::to_string() const -{ - static const char* options[] = {"n0us", "n30us", "n100us", "n140us", "n200us", "n300us", "n500us", "n900us"}; - return convert_enum_idx(options, 8, value, "srs_switching_time_nr_s::switching_time_dl_e_"); -} -uint16_t srs_switching_time_nr_s::switching_time_dl_opts::to_number() const -{ - static const uint16_t options[] = {0, 30, 100, 140, 200, 300, 500, 900}; - return map_enum_number(options, 8, value, "srs_switching_time_nr_s::switching_time_dl_e_"); -} - -std::string srs_switching_time_nr_s::switching_time_ul_opts::to_string() const -{ - static const char* options[] = {"n0us", "n30us", "n100us", "n140us", "n200us", "n300us", "n500us", "n900us"}; - return convert_enum_idx(options, 8, value, "srs_switching_time_nr_s::switching_time_ul_e_"); -} -uint16_t srs_switching_time_nr_s::switching_time_ul_opts::to_number() const +void drx_cfg_s::drx_on_dur_timer_c_::destroy_() {} +void drx_cfg_s::drx_on_dur_timer_c_::set(types::options e) { - static const uint16_t options[] = {0, 30, 100, 140, 200, 300, 500, 900}; - return map_enum_number(options, 8, value, "srs_switching_time_nr_s::switching_time_ul_e_"); + destroy_(); + type_ = e; } - -// BandParameters-v1540 ::= SEQUENCE -SRSASN_CODE band_params_v1540_s::pack(bit_ref& bref) const +drx_cfg_s::drx_on_dur_timer_c_::drx_on_dur_timer_c_(const drx_cfg_s::drx_on_dur_timer_c_& other) { - HANDLE_CODE(bref.pack(srs_carrier_switch_present, 1)); - HANDLE_CODE(bref.pack(srs_tx_switch_v1540_present, 1)); - - if (srs_carrier_switch_present) { - HANDLE_CODE(srs_carrier_switch.pack(bref)); - } - if (srs_tx_switch_v1540_present) { - HANDLE_CODE(bref.pack(srs_tx_switch_v1540.tx_switch_impact_to_rx_present, 1)); - HANDLE_CODE(bref.pack(srs_tx_switch_v1540.tx_switch_with_another_band_present, 1)); - HANDLE_CODE(srs_tx_switch_v1540.supported_srs_tx_port_switch.pack(bref)); - if (srs_tx_switch_v1540.tx_switch_impact_to_rx_present) { - HANDLE_CODE(pack_integer(bref, srs_tx_switch_v1540.tx_switch_impact_to_rx, (uint8_t)1u, (uint8_t)32u)); - } - if (srs_tx_switch_v1540.tx_switch_with_another_band_present) { - HANDLE_CODE(pack_integer(bref, srs_tx_switch_v1540.tx_switch_with_another_band, (uint8_t)1u, (uint8_t)32u)); - } + type_ = other.type(); + switch (type_) { + case types::sub_milli_seconds: + c.init(other.c.get()); + break; + case types::milli_seconds: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); } - - return SRSASN_SUCCESS; } -SRSASN_CODE band_params_v1540_s::unpack(cbit_ref& bref) +drx_cfg_s::drx_on_dur_timer_c_& drx_cfg_s::drx_on_dur_timer_c_::operator=(const drx_cfg_s::drx_on_dur_timer_c_& other) { - HANDLE_CODE(bref.unpack(srs_carrier_switch_present, 1)); - HANDLE_CODE(bref.unpack(srs_tx_switch_v1540_present, 1)); - - if (srs_carrier_switch_present) { - HANDLE_CODE(srs_carrier_switch.unpack(bref)); + if (this == &other) { + return *this; } - if (srs_tx_switch_v1540_present) { - HANDLE_CODE(bref.unpack(srs_tx_switch_v1540.tx_switch_impact_to_rx_present, 1)); - HANDLE_CODE(bref.unpack(srs_tx_switch_v1540.tx_switch_with_another_band_present, 1)); - HANDLE_CODE(srs_tx_switch_v1540.supported_srs_tx_port_switch.unpack(bref)); - if (srs_tx_switch_v1540.tx_switch_impact_to_rx_present) { - HANDLE_CODE(unpack_integer(srs_tx_switch_v1540.tx_switch_impact_to_rx, bref, (uint8_t)1u, (uint8_t)32u)); - } - if (srs_tx_switch_v1540.tx_switch_with_another_band_present) { - HANDLE_CODE(unpack_integer(srs_tx_switch_v1540.tx_switch_with_another_band, bref, (uint8_t)1u, (uint8_t)32u)); - } + set(other.type()); + switch (type_) { + case types::sub_milli_seconds: + c.set(other.c.get()); + break; + case types::milli_seconds: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); } - return SRSASN_SUCCESS; + return *this; } -void band_params_v1540_s::to_json(json_writer& j) const +void drx_cfg_s::drx_on_dur_timer_c_::to_json(json_writer& j) const { j.start_obj(); - if (srs_carrier_switch_present) { - j.write_fieldname("srs-CarrierSwitch"); - srs_carrier_switch.to_json(j); - } - if (srs_tx_switch_v1540_present) { - j.write_fieldname("srs-TxSwitch-v1540"); - j.start_obj(); - j.write_str("supportedSRS-TxPortSwitch", srs_tx_switch_v1540.supported_srs_tx_port_switch.to_string()); - if (srs_tx_switch_v1540.tx_switch_impact_to_rx_present) { - j.write_int("txSwitchImpactToRx", srs_tx_switch_v1540.tx_switch_impact_to_rx); - } - if (srs_tx_switch_v1540.tx_switch_with_another_band_present) { - j.write_int("txSwitchWithAnotherBand", srs_tx_switch_v1540.tx_switch_with_another_band); - } - j.end_obj(); + switch (type_) { + case types::sub_milli_seconds: + j.write_int("subMilliSeconds", c.get()); + break; + case types::milli_seconds: + j.write_str("milliSeconds", c.get().to_string()); + break; + default: + log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); } j.end_obj(); } - -void band_params_v1540_s::srs_carrier_switch_c_::destroy_() +SRSASN_CODE drx_cfg_s::drx_on_dur_timer_c_::pack(bit_ref& bref) const { + type_.pack(bref); switch (type_) { - case types::nr: - c.destroy(); + case types::sub_milli_seconds: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)31u)); break; - case types::eutra: - c.destroy(); + case types::milli_seconds: + HANDLE_CODE(c.get().pack(bref)); break; default: - break; + log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); + return SRSASN_ERROR_ENCODE_FAIL; } + return SRSASN_SUCCESS; } -void band_params_v1540_s::srs_carrier_switch_c_::set(types::options e) +SRSASN_CODE drx_cfg_s::drx_on_dur_timer_c_::unpack(cbit_ref& bref) { - destroy_(); - type_ = e; + types e; + e.unpack(bref); + set(e); switch (type_) { - case types::nr: - c.init(); - break; - case types::eutra: - c.init(); + case types::sub_milli_seconds: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)31u)); break; - case types::nulltype: + case types::milli_seconds: + HANDLE_CODE(c.get().unpack(bref)); break; default: - log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); + log_invalid_choice_id(type_, "drx_cfg_s::drx_on_dur_timer_c_"); + return SRSASN_ERROR_DECODE_FAIL; } + return SRSASN_SUCCESS; } -band_params_v1540_s::srs_carrier_switch_c_::srs_carrier_switch_c_( - const band_params_v1540_s::srs_carrier_switch_c_& other) + +std::string drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_opts::to_string() const +{ + static const char* options[] = {"ms1", "ms2", "ms3", "ms4", "ms5", "ms6", "ms8", "ms10", + "ms20", "ms30", "ms40", "ms50", "ms60", "ms80", "ms100", "ms200", + "ms300", "ms400", "ms500", "ms600", "ms800", "ms1000", "ms1200", "ms1600", + "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_e_"); +} +uint16_t drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_opts::to_number() const +{ + static const uint16_t options[] = {1, 2, 3, 4, 5, 6, 8, 10, 20, 30, 40, 50, + 60, 80, 100, 200, 300, 400, 500, 600, 800, 1000, 1200, 1600}; + return map_enum_number(options, 24, value, "drx_cfg_s::drx_on_dur_timer_c_::milli_seconds_e_"); +} + +std::string drx_cfg_s::drx_on_dur_timer_c_::types_opts::to_string() const +{ + static const char* options[] = {"subMilliSeconds", "milliSeconds"}; + return convert_enum_idx(options, 2, value, "drx_cfg_s::drx_on_dur_timer_c_::types"); +} + +std::string drx_cfg_s::drx_inactivity_timer_opts::to_string() const +{ + static const char* options[] = {"ms0", "ms1", "ms2", "ms3", "ms4", "ms5", "ms6", "ms8", + "ms10", "ms20", "ms30", "ms40", "ms50", "ms60", "ms80", "ms100", + "ms200", "ms300", "ms500", "ms750", "ms1280", "ms1920", "ms2560", "spare9", + "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_inactivity_timer_e_"); +} +uint16_t drx_cfg_s::drx_inactivity_timer_opts::to_number() const +{ + static const uint16_t options[] = {0, 1, 2, 3, 4, 5, 6, 8, 10, 20, 30, 40, + 50, 60, 80, 100, 200, 300, 500, 750, 1280, 1920, 2560}; + return map_enum_number(options, 23, value, "drx_cfg_s::drx_inactivity_timer_e_"); +} + +std::string drx_cfg_s::drx_retx_timer_dl_opts::to_string() const +{ + static const char* options[] = {"sl0", "sl1", "sl2", "sl4", "sl6", "sl8", "sl16", "sl24", + "sl33", "sl40", "sl64", "sl80", "sl96", "sl112", "sl128", "sl160", + "sl320", "spare15", "spare14", "spare13", "spare12", "spare11", "spare10", "spare9", + "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_retx_timer_dl_e_"); +} +uint16_t drx_cfg_s::drx_retx_timer_dl_opts::to_number() const +{ + static const uint16_t options[] = {0, 1, 2, 4, 6, 8, 16, 24, 33, 40, 64, 80, 96, 112, 128, 160, 320}; + return map_enum_number(options, 17, value, "drx_cfg_s::drx_retx_timer_dl_e_"); +} + +std::string drx_cfg_s::drx_retx_timer_ul_opts::to_string() const +{ + static const char* options[] = {"sl0", "sl1", "sl2", "sl4", "sl6", "sl8", "sl16", "sl24", + "sl33", "sl40", "sl64", "sl80", "sl96", "sl112", "sl128", "sl160", + "sl320", "spare15", "spare14", "spare13", "spare12", "spare11", "spare10", "spare9", + "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 32, value, "drx_cfg_s::drx_retx_timer_ul_e_"); +} +uint16_t drx_cfg_s::drx_retx_timer_ul_opts::to_number() const +{ + static const uint16_t options[] = {0, 1, 2, 4, 6, 8, 16, 24, 33, 40, 64, 80, 96, 112, 128, 160, 320}; + return map_enum_number(options, 17, value, "drx_cfg_s::drx_retx_timer_ul_e_"); +} + +void drx_cfg_s::drx_long_cycle_start_offset_c_::destroy_() {} +void drx_cfg_s::drx_long_cycle_start_offset_c_::set(types::options e) +{ + destroy_(); + type_ = e; +} +drx_cfg_s::drx_long_cycle_start_offset_c_::drx_long_cycle_start_offset_c_( + const drx_cfg_s::drx_long_cycle_start_offset_c_& other) { type_ = other.type(); switch (type_) { - case types::nr: - c.init(other.c.get()); + case types::ms10: + c.init(other.c.get()); break; - case types::eutra: - c.init(other.c.get()); + case types::ms20: + c.init(other.c.get()); + break; + case types::ms32: + c.init(other.c.get()); + break; + case types::ms40: + c.init(other.c.get()); + break; + case types::ms60: + c.init(other.c.get()); + break; + case types::ms64: + c.init(other.c.get()); + break; + case types::ms70: + c.init(other.c.get()); + break; + case types::ms80: + c.init(other.c.get()); + break; + case types::ms128: + c.init(other.c.get()); + break; + case types::ms160: + c.init(other.c.get()); + break; + case types::ms256: + c.init(other.c.get()); + break; + case types::ms320: + c.init(other.c.get()); + break; + case types::ms512: + c.init(other.c.get()); + break; + case types::ms640: + c.init(other.c.get()); + break; + case types::ms1024: + c.init(other.c.get()); + break; + case types::ms1280: + c.init(other.c.get()); + break; + case types::ms2048: + c.init(other.c.get()); + break; + case types::ms2560: + c.init(other.c.get()); + break; + case types::ms5120: + c.init(other.c.get()); + break; + case types::ms10240: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); + log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); } } -band_params_v1540_s::srs_carrier_switch_c_& band_params_v1540_s::srs_carrier_switch_c_:: - operator=(const band_params_v1540_s::srs_carrier_switch_c_& other) +drx_cfg_s::drx_long_cycle_start_offset_c_& +drx_cfg_s::drx_long_cycle_start_offset_c_::operator=(const drx_cfg_s::drx_long_cycle_start_offset_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::nr: - c.set(other.c.get()); + case types::ms10: + c.set(other.c.get()); + break; + case types::ms20: + c.set(other.c.get()); + break; + case types::ms32: + c.set(other.c.get()); + break; + case types::ms40: + c.set(other.c.get()); + break; + case types::ms60: + c.set(other.c.get()); + break; + case types::ms64: + c.set(other.c.get()); + break; + case types::ms70: + c.set(other.c.get()); + break; + case types::ms80: + c.set(other.c.get()); + break; + case types::ms128: + c.set(other.c.get()); + break; + case types::ms160: + c.set(other.c.get()); + break; + case types::ms256: + c.set(other.c.get()); + break; + case types::ms320: + c.set(other.c.get()); + break; + case types::ms512: + c.set(other.c.get()); + break; + case types::ms640: + c.set(other.c.get()); + break; + case types::ms1024: + c.set(other.c.get()); + break; + case types::ms1280: + c.set(other.c.get()); + break; + case types::ms2048: + c.set(other.c.get()); + break; + case types::ms2560: + c.set(other.c.get()); break; - case types::eutra: - c.set(other.c.get()); + case types::ms5120: + c.set(other.c.get()); + break; + case types::ms10240: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); + log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); } return *this; } -void band_params_v1540_s::srs_carrier_switch_c_::to_json(json_writer& j) const +void drx_cfg_s::drx_long_cycle_start_offset_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::nr: - j.write_fieldname("nr"); - j.start_obj(); - j.start_array("srs-SwitchingTimesListNR"); - for (const auto& e1 : c.get().srs_switching_times_list_nr) { - e1.to_json(j); - } - j.end_array(); - j.end_obj(); + case types::ms10: + j.write_int("ms10", c.get()); break; - case types::eutra: - j.write_fieldname("eutra"); - j.start_obj(); - j.start_array("srs-SwitchingTimesListEUTRA"); - for (const auto& e1 : c.get().srs_switching_times_list_eutra) { - e1.to_json(j); - } - j.end_array(); - j.end_obj(); + case types::ms20: + j.write_int("ms20", c.get()); + break; + case types::ms32: + j.write_int("ms32", c.get()); + break; + case types::ms40: + j.write_int("ms40", c.get()); + break; + case types::ms60: + j.write_int("ms60", c.get()); + break; + case types::ms64: + j.write_int("ms64", c.get()); + break; + case types::ms70: + j.write_int("ms70", c.get()); + break; + case types::ms80: + j.write_int("ms80", c.get()); + break; + case types::ms128: + j.write_int("ms128", c.get()); + break; + case types::ms160: + j.write_int("ms160", c.get()); + break; + case types::ms256: + j.write_int("ms256", c.get()); + break; + case types::ms320: + j.write_int("ms320", c.get()); + break; + case types::ms512: + j.write_int("ms512", c.get()); + break; + case types::ms640: + j.write_int("ms640", c.get()); + break; + case types::ms1024: + j.write_int("ms1024", c.get()); + break; + case types::ms1280: + j.write_int("ms1280", c.get()); + break; + case types::ms2048: + j.write_int("ms2048", c.get()); + break; + case types::ms2560: + j.write_int("ms2560", c.get()); + break; + case types::ms5120: + j.write_int("ms5120", c.get()); + break; + case types::ms10240: + j.write_int("ms10240", c.get()); break; default: - log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); + log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); } j.end_obj(); } -SRSASN_CODE band_params_v1540_s::srs_carrier_switch_c_::pack(bit_ref& bref) const +SRSASN_CODE drx_cfg_s::drx_long_cycle_start_offset_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::nr: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get().srs_switching_times_list_nr, 1, 32)); + case types::ms10: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)9u)); break; - case types::eutra: - HANDLE_CODE(pack_dyn_seq_of(bref, c.get().srs_switching_times_list_eutra, 1, 32)); + case types::ms20: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)19u)); + break; + case types::ms32: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)31u)); + break; + case types::ms40: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)39u)); + break; + case types::ms60: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)59u)); + break; + case types::ms64: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)63u)); + break; + case types::ms70: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)69u)); + break; + case types::ms80: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)79u)); + break; + case types::ms128: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)127u)); + break; + case types::ms160: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)0u, (uint8_t)159u)); + break; + case types::ms256: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)255u)); + break; + case types::ms320: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)319u)); + break; + case types::ms512: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)511u)); + break; + case types::ms640: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)639u)); + break; + case types::ms1024: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)1023u)); + break; + case types::ms1280: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)1279u)); + break; + case types::ms2048: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)2047u)); + break; + case types::ms2560: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)2559u)); + break; + case types::ms5120: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)5119u)); + break; + case types::ms10240: + HANDLE_CODE(pack_integer(bref, c.get(), (uint16_t)0u, (uint16_t)10239u)); break; default: - log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); + log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE band_params_v1540_s::srs_carrier_switch_c_::unpack(cbit_ref& bref) +SRSASN_CODE drx_cfg_s::drx_long_cycle_start_offset_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::nr: - HANDLE_CODE(unpack_dyn_seq_of(c.get().srs_switching_times_list_nr, bref, 1, 32)); + case types::ms10: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)9u)); break; - case types::eutra: - HANDLE_CODE(unpack_dyn_seq_of(c.get().srs_switching_times_list_eutra, bref, 1, 32)); + case types::ms20: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)19u)); + break; + case types::ms32: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)31u)); + break; + case types::ms40: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)39u)); + break; + case types::ms60: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)59u)); + break; + case types::ms64: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)63u)); + break; + case types::ms70: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)69u)); + break; + case types::ms80: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)79u)); + break; + case types::ms128: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)127u)); + break; + case types::ms160: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)0u, (uint8_t)159u)); + break; + case types::ms256: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)255u)); + break; + case types::ms320: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)319u)); + break; + case types::ms512: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)511u)); + break; + case types::ms640: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)639u)); + break; + case types::ms1024: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)1023u)); + break; + case types::ms1280: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)1279u)); + break; + case types::ms2048: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)2047u)); + break; + case types::ms2560: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)2559u)); + break; + case types::ms5120: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)5119u)); + break; + case types::ms10240: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint16_t)0u, (uint16_t)10239u)); break; default: - log_invalid_choice_id(type_, "band_params_v1540_s::srs_carrier_switch_c_"); + log_invalid_choice_id(type_, "drx_cfg_s::drx_long_cycle_start_offset_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string band_params_v1540_s::srs_carrier_switch_c_::types_opts::to_string() const +std::string drx_cfg_s::drx_long_cycle_start_offset_c_::types_opts::to_string() const { - static const char* options[] = {"nr", "eutra"}; - return convert_enum_idx(options, 2, value, "band_params_v1540_s::srs_carrier_switch_c_::types"); + static const char* options[] = {"ms10", "ms20", "ms32", "ms40", "ms60", "ms64", "ms70", + "ms80", "ms128", "ms160", "ms256", "ms320", "ms512", "ms640", + "ms1024", "ms1280", "ms2048", "ms2560", "ms5120", "ms10240"}; + return convert_enum_idx(options, 20, value, "drx_cfg_s::drx_long_cycle_start_offset_c_::types"); } - -std::string band_params_v1540_s::srs_tx_switch_v1540_s_::supported_srs_tx_port_switch_opts::to_string() const +uint16_t drx_cfg_s::drx_long_cycle_start_offset_c_::types_opts::to_number() const { - static const char* options[] = {"t1r2", "t1r4", "t2r4", "t1r4-t2r4", "t1r1", "t2r2", "t4r4", "notSupported"}; - return convert_enum_idx( - options, 8, value, "band_params_v1540_s::srs_tx_switch_v1540_s_::supported_srs_tx_port_switch_e_"); + static const uint16_t options[] = {10, 20, 32, 40, 60, 64, 70, 80, 128, 160, + 256, 320, 512, 640, 1024, 1280, 2048, 2560, 5120, 10240}; + return map_enum_number(options, 20, value, "drx_cfg_s::drx_long_cycle_start_offset_c_::types"); } -// CA-ParametersNR-v1540 ::= SEQUENCE -SRSASN_CODE ca_params_nr_v1540_s::pack(bit_ref& bref) const +std::string drx_cfg_s::short_drx_s_::drx_short_cycle_opts::to_string() const { - HANDLE_CODE(bref.pack(simul_srs_assoc_csi_rs_all_cc_present, 1)); - HANDLE_CODE(bref.pack(csi_rs_im_reception_for_feedback_per_band_comb_present, 1)); - HANDLE_CODE(bref.pack(simul_csi_reports_all_cc_present, 1)); - HANDLE_CODE(bref.pack(dual_pa_architecture_present, 1)); - - if (simul_srs_assoc_csi_rs_all_cc_present) { - HANDLE_CODE(pack_integer(bref, simul_srs_assoc_csi_rs_all_cc, (uint8_t)5u, (uint8_t)32u)); - } - if (csi_rs_im_reception_for_feedback_per_band_comb_present) { - HANDLE_CODE( - bref.pack(csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); - HANDLE_CODE(bref.pack( - csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); - if (csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present) { - HANDLE_CODE(pack_integer(bref, - csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc, - (uint8_t)1u, - (uint8_t)64u)); - } - if (csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present) { - HANDLE_CODE( - pack_integer(bref, - csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc, - (uint16_t)2u, - (uint16_t)256u)); - } - } - if (simul_csi_reports_all_cc_present) { - HANDLE_CODE(pack_integer(bref, simul_csi_reports_all_cc, (uint8_t)5u, (uint8_t)32u)); - } - - return SRSASN_SUCCESS; + static const char* options[] = {"ms2", "ms3", "ms4", "ms5", "ms6", "ms7", "ms8", "ms10", + "ms14", "ms16", "ms20", "ms30", "ms32", "ms35", "ms40", "ms64", + "ms80", "ms128", "ms160", "ms256", "ms320", "ms512", "ms640", "spare9", + "spare8", "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 32, value, "drx_cfg_s::short_drx_s_::drx_short_cycle_e_"); } -SRSASN_CODE ca_params_nr_v1540_s::unpack(cbit_ref& bref) +uint16_t drx_cfg_s::short_drx_s_::drx_short_cycle_opts::to_number() const { - HANDLE_CODE(bref.unpack(simul_srs_assoc_csi_rs_all_cc_present, 1)); - HANDLE_CODE(bref.unpack(csi_rs_im_reception_for_feedback_per_band_comb_present, 1)); - HANDLE_CODE(bref.unpack(simul_csi_reports_all_cc_present, 1)); - HANDLE_CODE(bref.unpack(dual_pa_architecture_present, 1)); - - if (simul_srs_assoc_csi_rs_all_cc_present) { - HANDLE_CODE(unpack_integer(simul_srs_assoc_csi_rs_all_cc, bref, (uint8_t)5u, (uint8_t)32u)); - } - if (csi_rs_im_reception_for_feedback_per_band_comb_present) { - HANDLE_CODE( - bref.unpack(csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); - HANDLE_CODE(bref.unpack( - csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present, 1)); - if (csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present) { - HANDLE_CODE(unpack_integer(csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc, - bref, - (uint8_t)1u, - (uint8_t)64u)); - } - if (csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present) { - HANDLE_CODE( - unpack_integer(csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc, - bref, - (uint16_t)2u, - (uint16_t)256u)); - } - } - if (simul_csi_reports_all_cc_present) { - HANDLE_CODE(unpack_integer(simul_csi_reports_all_cc, bref, (uint8_t)5u, (uint8_t)32u)); - } + static const uint16_t options[] = {2, 3, 4, 5, 6, 7, 8, 10, 14, 16, 20, 30, + 32, 35, 40, 64, 80, 128, 160, 256, 320, 512, 640}; + return map_enum_number(options, 23, value, "drx_cfg_s::short_drx_s_::drx_short_cycle_e_"); +} - return SRSASN_SUCCESS; +// DataInactivityTimer ::= ENUMERATED +std::string data_inactivity_timer_opts::to_string() const +{ + static const char* options[] = { + "s1", "s2", "s3", "s5", "s7", "s10", "s15", "s20", "s40", "s50", "s60", "s80", "s100", "s120", "s150", "s180"}; + return convert_enum_idx(options, 16, value, "data_inactivity_timer_e"); } -void ca_params_nr_v1540_s::to_json(json_writer& j) const +uint8_t data_inactivity_timer_opts::to_number() const { - j.start_obj(); - if (simul_srs_assoc_csi_rs_all_cc_present) { - j.write_int("simultaneousSRS-AssocCSI-RS-AllCC", simul_srs_assoc_csi_rs_all_cc); - } - if (csi_rs_im_reception_for_feedback_per_band_comb_present) { - j.write_fieldname("csi-RS-IM-ReceptionForFeedbackPerBandComb"); - j.start_obj(); - if (csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present) { - j.write_int("maxNumberSimultaneousNZP-CSI-RS-ActBWP-AllCC", - csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc); - } - if (csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present) { - j.write_int("totalNumberPortsSimultaneousNZP-CSI-RS-ActBWP-AllCC", - csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc); - } - j.end_obj(); - } - if (simul_csi_reports_all_cc_present) { - j.write_int("simultaneousCSI-ReportsAllCC", simul_csi_reports_all_cc); - } - if (dual_pa_architecture_present) { - j.write_str("dualPA-Architecture", "supported"); - } - j.end_obj(); + static const uint8_t options[] = {1, 2, 3, 5, 7, 10, 15, 20, 40, 50, 60, 80, 100, 120, 150, 180}; + return map_enum_number(options, 16, value, "data_inactivity_timer_e"); } -// BandCombination-v1540 ::= SEQUENCE -SRSASN_CODE band_combination_v1540_s::pack(bit_ref& bref) const +// LogicalChannelConfig ::= SEQUENCE +SRSASN_CODE lc_ch_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(ca_params_nr_v1540_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(ul_specific_params_present, 1)); - HANDLE_CODE(pack_dyn_seq_of(bref, band_list_v1540, 1, 32)); - if (ca_params_nr_v1540_present) { - HANDLE_CODE(ca_params_nr_v1540.pack(bref)); + if (ul_specific_params_present) { + HANDLE_CODE(ul_specific_params.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE band_combination_v1540_s::unpack(cbit_ref& bref) +SRSASN_CODE lc_ch_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(ca_params_nr_v1540_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(ul_specific_params_present, 1)); - HANDLE_CODE(unpack_dyn_seq_of(band_list_v1540, bref, 1, 32)); - if (ca_params_nr_v1540_present) { - HANDLE_CODE(ca_params_nr_v1540.unpack(bref)); + if (ul_specific_params_present) { + HANDLE_CODE(ul_specific_params.unpack(bref)); } return SRSASN_SUCCESS; } -void band_combination_v1540_s::to_json(json_writer& j) const +void lc_ch_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.start_array("bandList-v1540"); - for (const auto& e1 : band_list_v1540) { - e1.to_json(j); - } - j.end_array(); - if (ca_params_nr_v1540_present) { - j.write_fieldname("ca-ParametersNR-v1540"); - ca_params_nr_v1540.to_json(j); + if (ul_specific_params_present) { + j.write_fieldname("ul-SpecificParameters"); + ul_specific_params.to_json(j); } j.end_obj(); } -// CA-ParametersNR-v1550 ::= SEQUENCE -SRSASN_CODE ca_params_nr_v1550_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(bref.pack(aperiodic_csi_diff_scs_present, 1)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE ca_params_nr_v1550_s::unpack(cbit_ref& bref) +SRSASN_CODE lc_ch_cfg_s::ul_specific_params_s_::pack(bit_ref& bref) const { - HANDLE_CODE(bref.unpack(aperiodic_csi_diff_scs_present, 1)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(allowed_serving_cells_present, 1)); + HANDLE_CODE(bref.pack(allowed_scs_list_present, 1)); + HANDLE_CODE(bref.pack(max_pusch_dur_present, 1)); + HANDLE_CODE(bref.pack(cfgured_grant_type1_allowed_present, 1)); + HANDLE_CODE(bref.pack(lc_ch_group_present, 1)); + HANDLE_CODE(bref.pack(sched_request_id_present, 1)); - return SRSASN_SUCCESS; -} -void ca_params_nr_v1550_s::to_json(json_writer& j) const -{ - j.start_obj(); - if (aperiodic_csi_diff_scs_present) { - j.write_str("aperiodic-CSI-diffSCS", "supported"); + HANDLE_CODE(pack_integer(bref, prio, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(prioritised_bit_rate.pack(bref)); + HANDLE_CODE(bucket_size_dur.pack(bref)); + if (allowed_serving_cells_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, allowed_serving_cells, 1, 31, integer_packer(0, 31))); } - j.end_obj(); -} - -// BandCombination-v1550 ::= SEQUENCE -SRSASN_CODE band_combination_v1550_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(ca_params_nr_v1550.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE band_combination_v1550_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(ca_params_nr_v1550.unpack(bref)); - - return SRSASN_SUCCESS; -} -void band_combination_v1550_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("ca-ParametersNR-v1550"); - ca_params_nr_v1550.to_json(j); - j.end_obj(); -} - -// SupportedCSI-RS-Resource ::= SEQUENCE -SRSASN_CODE supported_csi_rs_res_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(max_num_tx_ports_per_res.pack(bref)); - HANDLE_CODE(pack_integer(bref, max_num_res_per_band, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_integer(bref, total_num_tx_ports_per_band, (uint16_t)2u, (uint16_t)256u)); + if (allowed_scs_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, allowed_scs_list, 1, 5)); + } + if (max_pusch_dur_present) { + HANDLE_CODE(max_pusch_dur.pack(bref)); + } + if (lc_ch_group_present) { + HANDLE_CODE(pack_integer(bref, lc_ch_group, (uint8_t)0u, (uint8_t)7u)); + } + if (sched_request_id_present) { + HANDLE_CODE(pack_integer(bref, sched_request_id, (uint8_t)0u, (uint8_t)7u)); + } + HANDLE_CODE(bref.pack(lc_ch_sr_mask, 1)); + HANDLE_CODE(bref.pack(lc_ch_sr_delay_timer_applied, 1)); - return SRSASN_SUCCESS; -} -SRSASN_CODE supported_csi_rs_res_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(max_num_tx_ports_per_res.unpack(bref)); - HANDLE_CODE(unpack_integer(max_num_res_per_band, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_integer(total_num_tx_ports_per_band, bref, (uint16_t)2u, (uint16_t)256u)); + if (ext) { + HANDLE_CODE(bref.pack(bit_rate_query_prohibit_timer_present, 1)); + if (bit_rate_query_prohibit_timer_present) { + HANDLE_CODE(bit_rate_query_prohibit_timer.pack(bref)); + } + } return SRSASN_SUCCESS; } -void supported_csi_rs_res_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_str("maxNumberTxPortsPerResource", max_num_tx_ports_per_res.to_string()); - j.write_int("maxNumberResourcesPerBand", max_num_res_per_band); - j.write_int("totalNumberTxPortsPerBand", total_num_tx_ports_per_band); - j.end_obj(); -} - -std::string supported_csi_rs_res_s::max_num_tx_ports_per_res_opts::to_string() const -{ - static const char* options[] = {"p2", "p4", "p8", "p12", "p16", "p24", "p32"}; - return convert_enum_idx(options, 7, value, "supported_csi_rs_res_s::max_num_tx_ports_per_res_e_"); -} -uint8_t supported_csi_rs_res_s::max_num_tx_ports_per_res_opts::to_number() const -{ - static const uint8_t options[] = {2, 4, 8, 12, 16, 24, 32}; - return map_enum_number(options, 7, value, "supported_csi_rs_res_s::max_num_tx_ports_per_res_e_"); -} - -// BeamManagementSSB-CSI-RS ::= SEQUENCE -SRSASN_CODE beam_management_ssb_csi_rs_s::pack(bit_ref& bref) const +SRSASN_CODE lc_ch_cfg_s::ul_specific_params_s_::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.pack(supported_csi_rs_density_present, 1)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(allowed_serving_cells_present, 1)); + HANDLE_CODE(bref.unpack(allowed_scs_list_present, 1)); + HANDLE_CODE(bref.unpack(max_pusch_dur_present, 1)); + HANDLE_CODE(bref.unpack(cfgured_grant_type1_allowed_present, 1)); + HANDLE_CODE(bref.unpack(lc_ch_group_present, 1)); + HANDLE_CODE(bref.unpack(sched_request_id_present, 1)); - HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.pack(bref)); - HANDLE_CODE(max_num_csi_rs_res.pack(bref)); - HANDLE_CODE(max_num_csi_rs_res_two_tx.pack(bref)); - if (supported_csi_rs_density_present) { - HANDLE_CODE(supported_csi_rs_density.pack(bref)); + HANDLE_CODE(unpack_integer(prio, bref, (uint8_t)1u, (uint8_t)16u)); + HANDLE_CODE(prioritised_bit_rate.unpack(bref)); + HANDLE_CODE(bucket_size_dur.unpack(bref)); + if (allowed_serving_cells_present) { + HANDLE_CODE(unpack_dyn_seq_of(allowed_serving_cells, bref, 1, 31, integer_packer(0, 31))); + } + if (allowed_scs_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(allowed_scs_list, bref, 1, 5)); + } + if (max_pusch_dur_present) { + HANDLE_CODE(max_pusch_dur.unpack(bref)); } - HANDLE_CODE(max_num_aperiodic_csi_rs_res.pack(bref)); + if (lc_ch_group_present) { + HANDLE_CODE(unpack_integer(lc_ch_group, bref, (uint8_t)0u, (uint8_t)7u)); + } + if (sched_request_id_present) { + HANDLE_CODE(unpack_integer(sched_request_id, bref, (uint8_t)0u, (uint8_t)7u)); + } + HANDLE_CODE(bref.unpack(lc_ch_sr_mask, 1)); + HANDLE_CODE(bref.unpack(lc_ch_sr_delay_timer_applied, 1)); - return SRSASN_SUCCESS; -} -SRSASN_CODE beam_management_ssb_csi_rs_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(bref.unpack(supported_csi_rs_density_present, 1)); + if (ext) { + HANDLE_CODE(bref.unpack(bit_rate_query_prohibit_timer_present, 1)); - HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.unpack(bref)); - HANDLE_CODE(max_num_csi_rs_res.unpack(bref)); - HANDLE_CODE(max_num_csi_rs_res_two_tx.unpack(bref)); - if (supported_csi_rs_density_present) { - HANDLE_CODE(supported_csi_rs_density.unpack(bref)); + if (bit_rate_query_prohibit_timer_present) { + HANDLE_CODE(bit_rate_query_prohibit_timer.unpack(bref)); + } } - HANDLE_CODE(max_num_aperiodic_csi_rs_res.unpack(bref)); - return SRSASN_SUCCESS; } -void beam_management_ssb_csi_rs_s::to_json(json_writer& j) const +void lc_ch_cfg_s::ul_specific_params_s_::to_json(json_writer& j) const { j.start_obj(); - j.write_str("maxNumberSSB-CSI-RS-ResourceOneTx", max_num_ssb_csi_rs_res_one_tx.to_string()); - j.write_str("maxNumberCSI-RS-Resource", max_num_csi_rs_res.to_string()); - j.write_str("maxNumberCSI-RS-ResourceTwoTx", max_num_csi_rs_res_two_tx.to_string()); - if (supported_csi_rs_density_present) { - j.write_str("supportedCSI-RS-Density", supported_csi_rs_density.to_string()); + j.write_int("priority", prio); + j.write_str("prioritisedBitRate", prioritised_bit_rate.to_string()); + j.write_str("bucketSizeDuration", bucket_size_dur.to_string()); + if (allowed_serving_cells_present) { + j.start_array("allowedServingCells"); + for (const auto& e1 : allowed_serving_cells) { + j.write_int(e1); + } + j.end_array(); + } + if (allowed_scs_list_present) { + j.start_array("allowedSCS-List"); + for (const auto& e1 : allowed_scs_list) { + j.write_str(e1.to_string()); + } + j.end_array(); + } + if (max_pusch_dur_present) { + j.write_str("maxPUSCH-Duration", max_pusch_dur.to_string()); + } + if (cfgured_grant_type1_allowed_present) { + j.write_str("configuredGrantType1Allowed", "true"); + } + if (lc_ch_group_present) { + j.write_int("logicalChannelGroup", lc_ch_group); + } + if (sched_request_id_present) { + j.write_int("schedulingRequestID", sched_request_id); + } + j.write_bool("logicalChannelSR-Mask", lc_ch_sr_mask); + j.write_bool("logicalChannelSR-DelayTimerApplied", lc_ch_sr_delay_timer_applied); + if (ext) { + if (bit_rate_query_prohibit_timer_present) { + j.write_str("bitRateQueryProhibitTimer", bit_rate_query_prohibit_timer.to_string()); + } } - j.write_str("maxNumberAperiodicCSI-RS-Resource", max_num_aperiodic_csi_rs_res.to_string()); j.end_obj(); } -std::string beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_opts::to_string() const +std::string lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_opts::to_string() const { - static const char* options[] = {"n0", "n8", "n16", "n32", "n64"}; - return convert_enum_idx(options, 5, value, "beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_e_"); + static const char* options[] = {"kBps0", + "kBps8", + "kBps16", + "kBps32", + "kBps64", + "kBps128", + "kBps256", + "kBps512", + "kBps1024", + "kBps2048", + "kBps4096", + "kBps8192", + "kBps16384", + "kBps32768", + "kBps65536", + "infinity"}; + return convert_enum_idx(options, 16, value, "lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_e_"); } -uint8_t beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_opts::to_number() const +int32_t lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_opts::to_number() const { - static const uint8_t options[] = {0, 8, 16, 32, 64}; - return map_enum_number(options, 5, value, "beam_management_ssb_csi_rs_s::max_num_ssb_csi_rs_res_one_tx_e_"); + static const int32_t options[] = {0, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 8192, 16384, 32768, 65536, -1}; + return map_enum_number(options, 16, value, "lc_ch_cfg_s::ul_specific_params_s_::prioritised_bit_rate_e_"); } -std::string beam_management_ssb_csi_rs_s::max_num_csi_rs_res_opts::to_string() const +std::string lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_opts::to_string() const { - static const char* options[] = {"n0", "n4", "n8", "n16", "n32", "n64"}; - return convert_enum_idx(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_e_"); + static const char* options[] = {"ms5", + "ms10", + "ms20", + "ms50", + "ms100", + "ms150", + "ms300", + "ms500", + "ms1000", + "spare7", + "spare6", + "spare5", + "spare4", + "spare3", + "spare2", + "spare1"}; + return convert_enum_idx(options, 16, value, "lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_e_"); } -uint8_t beam_management_ssb_csi_rs_s::max_num_csi_rs_res_opts::to_number() const +uint16_t lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_opts::to_number() const { - static const uint8_t options[] = {0, 4, 8, 16, 32, 64}; - return map_enum_number(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_e_"); + static const uint16_t options[] = {5, 10, 20, 50, 100, 150, 300, 500, 1000}; + return map_enum_number(options, 9, value, "lc_ch_cfg_s::ul_specific_params_s_::bucket_size_dur_e_"); } -std::string beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_opts::to_string() const -{ - static const char* options[] = {"n0", "n4", "n8", "n16", "n32", "n64"}; - return convert_enum_idx(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_e_"); -} -uint8_t beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_opts::to_number() const +std::string lc_ch_cfg_s::ul_specific_params_s_::max_pusch_dur_opts::to_string() const { - static const uint8_t options[] = {0, 4, 8, 16, 32, 64}; - return map_enum_number(options, 6, value, "beam_management_ssb_csi_rs_s::max_num_csi_rs_res_two_tx_e_"); + static const char* options[] = {"ms0p02", "ms0p04", "ms0p0625", "ms0p125", "ms0p25", "ms0p5", "spare2", "spare1"}; + return convert_enum_idx(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::max_pusch_dur_e_"); } -std::string beam_management_ssb_csi_rs_s::supported_csi_rs_density_opts::to_string() const +std::string lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_opts::to_string() const { - static const char* options[] = {"one", "three", "oneAndThree"}; - return convert_enum_idx(options, 3, value, "beam_management_ssb_csi_rs_s::supported_csi_rs_density_e_"); + static const char* options[] = {"s0", "s0dot4", "s0dot8", "s1dot6", "s3", "s6", "s12", "s30"}; + return convert_enum_idx(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_e_"); } - -std::string beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_opts::to_string() const +float lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_opts::to_number() const { - static const char* options[] = {"n0", "n1", "n4", "n8", "n16", "n32", "n64"}; - return convert_enum_idx(options, 7, value, "beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_e_"); + static const float options[] = {0.0, 0.4, 0.8, 1.6, 3.0, 6.0, 12.0, 30.0}; + return map_enum_number(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_e_"); } -uint8_t beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_opts::to_number() const +std::string lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_opts::to_number_string() const { - static const uint8_t options[] = {0, 1, 4, 8, 16, 32, 64}; - return map_enum_number(options, 7, value, "beam_management_ssb_csi_rs_s::max_num_aperiodic_csi_rs_res_e_"); + static const char* options[] = {"0", "0.4", "0.8", "1.6", "3", "6", "12", "30"}; + return convert_enum_idx(options, 8, value, "lc_ch_cfg_s::ul_specific_params_s_::bit_rate_query_prohibit_timer_e_"); } -// CSI-RS-ForTracking ::= SEQUENCE -SRSASN_CODE csi_rs_for_tracking_s::pack(bit_ref& bref) const +// PHR-Config ::= SEQUENCE +SRSASN_CODE phr_cfg_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, max_burst_len, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(pack_integer(bref, max_simul_res_sets_per_cc, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_per_cc, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_all_cc, (uint16_t)1u, (uint16_t)256u)); + bref.pack(ext, 1); + HANDLE_CODE(phr_periodic_timer.pack(bref)); + HANDLE_CODE(phr_prohibit_timer.pack(bref)); + HANDLE_CODE(phr_tx_pwr_factor_change.pack(bref)); + HANDLE_CODE(bref.pack(multiple_phr, 1)); + HANDLE_CODE(bref.pack(dummy, 1)); + HANDLE_CODE(bref.pack(phr_type2_other_cell, 1)); + HANDLE_CODE(phr_mode_other_cg.pack(bref)); return SRSASN_SUCCESS; } -SRSASN_CODE csi_rs_for_tracking_s::unpack(cbit_ref& bref) +SRSASN_CODE phr_cfg_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(max_burst_len, bref, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(unpack_integer(max_simul_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(unpack_integer(max_cfgured_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_integer(max_cfgured_res_sets_all_cc, bref, (uint16_t)1u, (uint16_t)256u)); + bref.unpack(ext, 1); + HANDLE_CODE(phr_periodic_timer.unpack(bref)); + HANDLE_CODE(phr_prohibit_timer.unpack(bref)); + HANDLE_CODE(phr_tx_pwr_factor_change.unpack(bref)); + HANDLE_CODE(bref.unpack(multiple_phr, 1)); + HANDLE_CODE(bref.unpack(dummy, 1)); + HANDLE_CODE(bref.unpack(phr_type2_other_cell, 1)); + HANDLE_CODE(phr_mode_other_cg.unpack(bref)); return SRSASN_SUCCESS; } -void csi_rs_for_tracking_s::to_json(json_writer& j) const +void phr_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("maxBurstLength", max_burst_len); - j.write_int("maxSimultaneousResourceSetsPerCC", max_simul_res_sets_per_cc); - j.write_int("maxConfiguredResourceSetsPerCC", max_cfgured_res_sets_per_cc); - j.write_int("maxConfiguredResourceSetsAllCC", max_cfgured_res_sets_all_cc); + j.write_str("phr-PeriodicTimer", phr_periodic_timer.to_string()); + j.write_str("phr-ProhibitTimer", phr_prohibit_timer.to_string()); + j.write_str("phr-Tx-PowerFactorChange", phr_tx_pwr_factor_change.to_string()); + j.write_bool("multiplePHR", multiple_phr); + j.write_bool("dummy", dummy); + j.write_bool("phr-Type2OtherCell", phr_type2_other_cell); + j.write_str("phr-ModeOtherCG", phr_mode_other_cg.to_string()); j.end_obj(); } -// CSI-RS-IM-ReceptionForFeedback ::= SEQUENCE -SRSASN_CODE csi_rs_im_reception_for_feedback_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, max_cfg_num_nzp_csi_rs_per_cc, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_integer(bref, max_cfg_num_ports_across_nzp_csi_rs_per_cc, (uint16_t)2u, (uint16_t)256u)); - HANDLE_CODE(max_cfg_num_csi_im_per_cc.pack(bref)); - HANDLE_CODE(pack_integer(bref, max_num_simul_nzp_csi_rs_per_cc, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_integer(bref, total_num_ports_simul_nzp_csi_rs_per_cc, (uint16_t)2u, (uint16_t)256u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE csi_rs_im_reception_for_feedback_s::unpack(cbit_ref& bref) +std::string phr_cfg_s::phr_periodic_timer_opts::to_string() const { - HANDLE_CODE(unpack_integer(max_cfg_num_nzp_csi_rs_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_integer(max_cfg_num_ports_across_nzp_csi_rs_per_cc, bref, (uint16_t)2u, (uint16_t)256u)); - HANDLE_CODE(max_cfg_num_csi_im_per_cc.unpack(bref)); - HANDLE_CODE(unpack_integer(max_num_simul_nzp_csi_rs_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_integer(total_num_ports_simul_nzp_csi_rs_per_cc, bref, (uint16_t)2u, (uint16_t)256u)); - - return SRSASN_SUCCESS; + static const char* options[] = {"sf10", "sf20", "sf50", "sf100", "sf200", "sf500", "sf1000", "infinity"}; + return convert_enum_idx(options, 8, value, "phr_cfg_s::phr_periodic_timer_e_"); } -void csi_rs_im_reception_for_feedback_s::to_json(json_writer& j) const +int16_t phr_cfg_s::phr_periodic_timer_opts::to_number() const { - j.start_obj(); - j.write_int("maxConfigNumberNZP-CSI-RS-PerCC", max_cfg_num_nzp_csi_rs_per_cc); - j.write_int("maxConfigNumberPortsAcrossNZP-CSI-RS-PerCC", max_cfg_num_ports_across_nzp_csi_rs_per_cc); - j.write_str("maxConfigNumberCSI-IM-PerCC", max_cfg_num_csi_im_per_cc.to_string()); - j.write_int("maxNumberSimultaneousNZP-CSI-RS-PerCC", max_num_simul_nzp_csi_rs_per_cc); - j.write_int("totalNumberPortsSimultaneousNZP-CSI-RS-PerCC", total_num_ports_simul_nzp_csi_rs_per_cc); - j.end_obj(); + static const int16_t options[] = {10, 20, 50, 100, 200, 500, 1000, -1}; + return map_enum_number(options, 8, value, "phr_cfg_s::phr_periodic_timer_e_"); } -std::string csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4", "n8", "n16", "n32"}; - return convert_enum_idx(options, 6, value, "csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_e_"); -} -uint8_t csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_opts::to_number() const +std::string phr_cfg_s::phr_prohibit_timer_opts::to_string() const { - static const uint8_t options[] = {1, 2, 4, 8, 16, 32}; - return map_enum_number(options, 6, value, "csi_rs_im_reception_for_feedback_s::max_cfg_num_csi_im_per_cc_e_"); + static const char* options[] = {"sf0", "sf10", "sf20", "sf50", "sf100", "sf200", "sf500", "sf1000"}; + return convert_enum_idx(options, 8, value, "phr_cfg_s::phr_prohibit_timer_e_"); } - -// CSI-RS-ProcFrameworkForSRS ::= SEQUENCE -SRSASN_CODE csi_rs_proc_framework_for_srs_s::pack(bit_ref& bref) const +uint16_t phr_cfg_s::phr_prohibit_timer_opts::to_number() const { - HANDLE_CODE(pack_integer(bref, max_num_periodic_srs_assoc_csi_rs_per_bwp, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, max_num_aperiodic_srs_assoc_csi_rs_per_bwp, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, max_num_sp_srs_assoc_csi_rs_per_bwp, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, simul_srs_assoc_csi_rs_per_cc, (uint8_t)1u, (uint8_t)8u)); - - return SRSASN_SUCCESS; + static const uint16_t options[] = {0, 10, 20, 50, 100, 200, 500, 1000}; + return map_enum_number(options, 8, value, "phr_cfg_s::phr_prohibit_timer_e_"); } -SRSASN_CODE csi_rs_proc_framework_for_srs_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(max_num_periodic_srs_assoc_csi_rs_per_bwp, bref, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(max_num_aperiodic_srs_assoc_csi_rs_per_bwp, bref, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(max_num_sp_srs_assoc_csi_rs_per_bwp, bref, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(simul_srs_assoc_csi_rs_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); - return SRSASN_SUCCESS; -} -void csi_rs_proc_framework_for_srs_s::to_json(json_writer& j) const +std::string phr_cfg_s::phr_tx_pwr_factor_change_opts::to_string() const { - j.start_obj(); - j.write_int("maxNumberPeriodicSRS-AssocCSI-RS-PerBWP", max_num_periodic_srs_assoc_csi_rs_per_bwp); - j.write_int("maxNumberAperiodicSRS-AssocCSI-RS-PerBWP", max_num_aperiodic_srs_assoc_csi_rs_per_bwp); - j.write_int("maxNumberSP-SRS-AssocCSI-RS-PerBWP", max_num_sp_srs_assoc_csi_rs_per_bwp); - j.write_int("simultaneousSRS-AssocCSI-RS-PerCC", simul_srs_assoc_csi_rs_per_cc); - j.end_obj(); + static const char* options[] = {"dB1", "dB3", "dB6", "infinity"}; + return convert_enum_idx(options, 4, value, "phr_cfg_s::phr_tx_pwr_factor_change_e_"); } - -// CSI-ReportFramework ::= SEQUENCE -SRSASN_CODE csi_report_framework_s::pack(bit_ref& bref) const +int8_t phr_cfg_s::phr_tx_pwr_factor_change_opts::to_number() const { - HANDLE_CODE(pack_integer(bref, max_num_periodic_csi_per_bwp_for_csi_report, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, max_num_aperiodic_csi_per_bwp_for_csi_report, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, max_num_semi_persistent_csi_per_bwp_for_csi_report, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, max_num_periodic_csi_per_bwp_for_beam_report, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, max_num_aperiodic_csi_per_bwp_for_beam_report, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(max_num_aperiodic_csi_trigger_state_per_cc.pack(bref)); - HANDLE_CODE(pack_integer(bref, max_num_semi_persistent_csi_per_bwp_for_beam_report, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(pack_integer(bref, simul_csi_reports_per_cc, (uint8_t)1u, (uint8_t)8u)); - - return SRSASN_SUCCESS; + static const int8_t options[] = {1, 3, 6, -1}; + return map_enum_number(options, 4, value, "phr_cfg_s::phr_tx_pwr_factor_change_e_"); } -SRSASN_CODE csi_report_framework_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(max_num_periodic_csi_per_bwp_for_csi_report, bref, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(max_num_aperiodic_csi_per_bwp_for_csi_report, bref, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(max_num_semi_persistent_csi_per_bwp_for_csi_report, bref, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(max_num_periodic_csi_per_bwp_for_beam_report, bref, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(max_num_aperiodic_csi_per_bwp_for_beam_report, bref, (uint8_t)1u, (uint8_t)4u)); - HANDLE_CODE(max_num_aperiodic_csi_trigger_state_per_cc.unpack(bref)); - HANDLE_CODE(unpack_integer(max_num_semi_persistent_csi_per_bwp_for_beam_report, bref, (uint8_t)0u, (uint8_t)4u)); - HANDLE_CODE(unpack_integer(simul_csi_reports_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); - return SRSASN_SUCCESS; -} -void csi_report_framework_s::to_json(json_writer& j) const +std::string phr_cfg_s::phr_mode_other_cg_opts::to_string() const { - j.start_obj(); - j.write_int("maxNumberPeriodicCSI-PerBWP-ForCSI-Report", max_num_periodic_csi_per_bwp_for_csi_report); - j.write_int("maxNumberAperiodicCSI-PerBWP-ForCSI-Report", max_num_aperiodic_csi_per_bwp_for_csi_report); - j.write_int("maxNumberSemiPersistentCSI-PerBWP-ForCSI-Report", max_num_semi_persistent_csi_per_bwp_for_csi_report); - j.write_int("maxNumberPeriodicCSI-PerBWP-ForBeamReport", max_num_periodic_csi_per_bwp_for_beam_report); - j.write_int("maxNumberAperiodicCSI-PerBWP-ForBeamReport", max_num_aperiodic_csi_per_bwp_for_beam_report); - j.write_str("maxNumberAperiodicCSI-triggeringStatePerCC", max_num_aperiodic_csi_trigger_state_per_cc.to_string()); - j.write_int("maxNumberSemiPersistentCSI-PerBWP-ForBeamReport", max_num_semi_persistent_csi_per_bwp_for_beam_report); - j.write_int("simultaneousCSI-ReportsPerCC", simul_csi_reports_per_cc); - j.end_obj(); + static const char* options[] = {"real", "virtual"}; + return convert_enum_idx(options, 2, value, "phr_cfg_s::phr_mode_other_cg_e_"); } -std::string csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_opts::to_string() const +// RLC-Config ::= CHOICE +void rlc_cfg_c::destroy_() { - static const char* options[] = {"n3", "n7", "n15", "n31", "n63", "n128"}; - return convert_enum_idx(options, 6, value, "csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_e_"); + switch (type_) { + case types::am: + c.destroy(); + break; + case types::um_bi_dir: + c.destroy(); + break; + case types::um_uni_dir_ul: + c.destroy(); + break; + case types::um_uni_dir_dl: + c.destroy(); + break; + default: + break; + } } -uint8_t csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_opts::to_number() const +void rlc_cfg_c::set(types::options e) { - static const uint8_t options[] = {3, 7, 15, 31, 63, 128}; - return map_enum_number(options, 6, value, "csi_report_framework_s::max_num_aperiodic_csi_trigger_state_per_cc_e_"); + destroy_(); + type_ = e; + switch (type_) { + case types::am: + c.init(); + break; + case types::um_bi_dir: + c.init(); + break; + case types::um_uni_dir_ul: + c.init(); + break; + case types::um_uni_dir_dl: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rlc_cfg_c"); + } } - -// CodebookParameters ::= SEQUENCE -SRSASN_CODE codebook_params_s::pack(bit_ref& bref) const +rlc_cfg_c::rlc_cfg_c(const rlc_cfg_c& other) { - HANDLE_CODE(bref.pack(type2_present, 1)); - HANDLE_CODE(bref.pack(type2_port_sel_present, 1)); - - HANDLE_CODE(bref.pack(type1.multi_panel_present, 1)); - HANDLE_CODE(pack_dyn_seq_of(bref, type1.single_panel.supported_csi_rs_res_list, 1, 7)); - HANDLE_CODE(type1.single_panel.modes.pack(bref)); - HANDLE_CODE(pack_integer(bref, type1.single_panel.max_num_csi_rs_per_res_set, (uint8_t)1u, (uint8_t)8u)); - if (type1.multi_panel_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, type1.multi_panel.supported_csi_rs_res_list, 1, 7)); - HANDLE_CODE(type1.multi_panel.modes.pack(bref)); - HANDLE_CODE(type1.multi_panel.nrof_panels.pack(bref)); - HANDLE_CODE(pack_integer(bref, type1.multi_panel.max_num_csi_rs_per_res_set, (uint8_t)1u, (uint8_t)8u)); - } - if (type2_present) { - HANDLE_CODE(bref.pack(type2.amplitude_subset_restrict_present, 1)); - HANDLE_CODE(pack_dyn_seq_of(bref, type2.supported_csi_rs_res_list, 1, 7)); - HANDLE_CODE(pack_integer(bref, type2.param_lx, (uint8_t)2u, (uint8_t)4u)); - HANDLE_CODE(type2.amplitude_scaling_type.pack(bref)); - } - if (type2_port_sel_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, type2_port_sel.supported_csi_rs_res_list, 1, 7)); - HANDLE_CODE(pack_integer(bref, type2_port_sel.param_lx, (uint8_t)2u, (uint8_t)4u)); - HANDLE_CODE(type2_port_sel.amplitude_scaling_type.pack(bref)); + type_ = other.type(); + switch (type_) { + case types::am: + c.init(other.c.get()); + break; + case types::um_bi_dir: + c.init(other.c.get()); + break; + case types::um_uni_dir_ul: + c.init(other.c.get()); + break; + case types::um_uni_dir_dl: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rlc_cfg_c"); } - - return SRSASN_SUCCESS; } -SRSASN_CODE codebook_params_s::unpack(cbit_ref& bref) +rlc_cfg_c& rlc_cfg_c::operator=(const rlc_cfg_c& other) { - HANDLE_CODE(bref.unpack(type2_present, 1)); - HANDLE_CODE(bref.unpack(type2_port_sel_present, 1)); - - HANDLE_CODE(bref.unpack(type1.multi_panel_present, 1)); - HANDLE_CODE(unpack_dyn_seq_of(type1.single_panel.supported_csi_rs_res_list, bref, 1, 7)); - HANDLE_CODE(type1.single_panel.modes.unpack(bref)); - HANDLE_CODE(unpack_integer(type1.single_panel.max_num_csi_rs_per_res_set, bref, (uint8_t)1u, (uint8_t)8u)); - if (type1.multi_panel_present) { - HANDLE_CODE(unpack_dyn_seq_of(type1.multi_panel.supported_csi_rs_res_list, bref, 1, 7)); - HANDLE_CODE(type1.multi_panel.modes.unpack(bref)); - HANDLE_CODE(type1.multi_panel.nrof_panels.unpack(bref)); - HANDLE_CODE(unpack_integer(type1.multi_panel.max_num_csi_rs_per_res_set, bref, (uint8_t)1u, (uint8_t)8u)); - } - if (type2_present) { - HANDLE_CODE(bref.unpack(type2.amplitude_subset_restrict_present, 1)); - HANDLE_CODE(unpack_dyn_seq_of(type2.supported_csi_rs_res_list, bref, 1, 7)); - HANDLE_CODE(unpack_integer(type2.param_lx, bref, (uint8_t)2u, (uint8_t)4u)); - HANDLE_CODE(type2.amplitude_scaling_type.unpack(bref)); + if (this == &other) { + return *this; } - if (type2_port_sel_present) { - HANDLE_CODE(unpack_dyn_seq_of(type2_port_sel.supported_csi_rs_res_list, bref, 1, 7)); - HANDLE_CODE(unpack_integer(type2_port_sel.param_lx, bref, (uint8_t)2u, (uint8_t)4u)); - HANDLE_CODE(type2_port_sel.amplitude_scaling_type.unpack(bref)); + set(other.type()); + switch (type_) { + case types::am: + c.set(other.c.get()); + break; + case types::um_bi_dir: + c.set(other.c.get()); + break; + case types::um_uni_dir_ul: + c.set(other.c.get()); + break; + case types::um_uni_dir_dl: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "rlc_cfg_c"); } - return SRSASN_SUCCESS; + return *this; } -void codebook_params_s::to_json(json_writer& j) const +void rlc_cfg_c::to_json(json_writer& j) const { j.start_obj(); - j.write_fieldname("type1"); - j.start_obj(); - j.write_fieldname("singlePanel"); - j.start_obj(); - j.start_array("supportedCSI-RS-ResourceList"); - for (const auto& e1 : type1.single_panel.supported_csi_rs_res_list) { - e1.to_json(j); - } - j.end_array(); - j.write_str("modes", type1.single_panel.modes.to_string()); - j.write_int("maxNumberCSI-RS-PerResourceSet", type1.single_panel.max_num_csi_rs_per_res_set); - j.end_obj(); - if (type1.multi_panel_present) { - j.write_fieldname("multiPanel"); - j.start_obj(); - j.start_array("supportedCSI-RS-ResourceList"); - for (const auto& e1 : type1.multi_panel.supported_csi_rs_res_list) { - e1.to_json(j); - } - j.end_array(); - j.write_str("modes", type1.multi_panel.modes.to_string()); - j.write_str("nrofPanels", type1.multi_panel.nrof_panels.to_string()); - j.write_int("maxNumberCSI-RS-PerResourceSet", type1.multi_panel.max_num_csi_rs_per_res_set); - j.end_obj(); - } - j.end_obj(); - if (type2_present) { - j.write_fieldname("type2"); - j.start_obj(); - j.start_array("supportedCSI-RS-ResourceList"); - for (const auto& e1 : type2.supported_csi_rs_res_list) { - e1.to_json(j); - } - j.end_array(); - j.write_int("parameterLx", type2.param_lx); - j.write_str("amplitudeScalingType", type2.amplitude_scaling_type.to_string()); - if (type2.amplitude_subset_restrict_present) { - j.write_str("amplitudeSubsetRestriction", "supported"); - } - j.end_obj(); - } - if (type2_port_sel_present) { - j.write_fieldname("type2-PortSelection"); - j.start_obj(); - j.start_array("supportedCSI-RS-ResourceList"); - for (const auto& e1 : type2_port_sel.supported_csi_rs_res_list) { - e1.to_json(j); - } - j.end_array(); - j.write_int("parameterLx", type2_port_sel.param_lx); - j.write_str("amplitudeScalingType", type2_port_sel.amplitude_scaling_type.to_string()); - j.end_obj(); + switch (type_) { + case types::am: + j.write_fieldname("am"); + j.start_obj(); + j.write_fieldname("ul-AM-RLC"); + c.get().ul_am_rlc.to_json(j); + j.write_fieldname("dl-AM-RLC"); + c.get().dl_am_rlc.to_json(j); + j.end_obj(); + break; + case types::um_bi_dir: + j.write_fieldname("um-Bi-Directional"); + j.start_obj(); + j.write_fieldname("ul-UM-RLC"); + c.get().ul_um_rlc.to_json(j); + j.write_fieldname("dl-UM-RLC"); + c.get().dl_um_rlc.to_json(j); + j.end_obj(); + break; + case types::um_uni_dir_ul: + j.write_fieldname("um-Uni-Directional-UL"); + j.start_obj(); + j.write_fieldname("ul-UM-RLC"); + c.get().ul_um_rlc.to_json(j); + j.end_obj(); + break; + case types::um_uni_dir_dl: + j.write_fieldname("um-Uni-Directional-DL"); + j.start_obj(); + j.write_fieldname("dl-UM-RLC"); + c.get().dl_um_rlc.to_json(j); + j.end_obj(); + break; + default: + log_invalid_choice_id(type_, "rlc_cfg_c"); } j.end_obj(); } - -std::string codebook_params_s::type1_s_::single_panel_s_::modes_opts::to_string() const -{ - static const char* options[] = {"mode1", "mode1andMode2"}; - return convert_enum_idx(options, 2, value, "codebook_params_s::type1_s_::single_panel_s_::modes_e_"); -} - -std::string codebook_params_s::type1_s_::multi_panel_s_::modes_opts::to_string() const +SRSASN_CODE rlc_cfg_c::pack(bit_ref& bref) const { - static const char* options[] = {"mode1", "mode2", "both"}; - return convert_enum_idx(options, 3, value, "codebook_params_s::type1_s_::multi_panel_s_::modes_e_"); + type_.pack(bref); + switch (type_) { + case types::am: + HANDLE_CODE(c.get().ul_am_rlc.pack(bref)); + HANDLE_CODE(c.get().dl_am_rlc.pack(bref)); + break; + case types::um_bi_dir: + HANDLE_CODE(c.get().ul_um_rlc.pack(bref)); + HANDLE_CODE(c.get().dl_um_rlc.pack(bref)); + break; + case types::um_uni_dir_ul: + HANDLE_CODE(c.get().ul_um_rlc.pack(bref)); + break; + case types::um_uni_dir_dl: + HANDLE_CODE(c.get().dl_um_rlc.pack(bref)); + break; + default: + log_invalid_choice_id(type_, "rlc_cfg_c"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } -uint8_t codebook_params_s::type1_s_::multi_panel_s_::modes_opts::to_number() const +SRSASN_CODE rlc_cfg_c::unpack(cbit_ref& bref) { - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "codebook_params_s::type1_s_::multi_panel_s_::modes_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::am: + HANDLE_CODE(c.get().ul_am_rlc.unpack(bref)); + HANDLE_CODE(c.get().dl_am_rlc.unpack(bref)); + break; + case types::um_bi_dir: + HANDLE_CODE(c.get().ul_um_rlc.unpack(bref)); + HANDLE_CODE(c.get().dl_um_rlc.unpack(bref)); + break; + case types::um_uni_dir_ul: + HANDLE_CODE(c.get().ul_um_rlc.unpack(bref)); + break; + case types::um_uni_dir_dl: + HANDLE_CODE(c.get().dl_um_rlc.unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "rlc_cfg_c"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -std::string codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_opts::to_string() const -{ - static const char* options[] = {"n2", "n4"}; - return convert_enum_idx(options, 2, value, "codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_e_"); -} -uint8_t codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_opts::to_number() const +std::string rlc_cfg_c::types_opts::to_string() const { - static const uint8_t options[] = {2, 4}; - return map_enum_number(options, 2, value, "codebook_params_s::type1_s_::multi_panel_s_::nrof_panels_e_"); + static const char* options[] = {"am", "um-Bi-Directional", "um-Uni-Directional-UL", "um-Uni-Directional-DL"}; + return convert_enum_idx(options, 4, value, "rlc_cfg_c::types"); } -std::string codebook_params_s::type2_s_::amplitude_scaling_type_opts::to_string() const +// RLF-TimersAndConstants ::= SEQUENCE +SRSASN_CODE rlf_timers_and_consts_s::pack(bit_ref& bref) const { - static const char* options[] = {"wideband", "widebandAndSubband"}; - return convert_enum_idx(options, 2, value, "codebook_params_s::type2_s_::amplitude_scaling_type_e_"); -} + bref.pack(ext, 1); + HANDLE_CODE(t310.pack(bref)); + HANDLE_CODE(n310.pack(bref)); + HANDLE_CODE(n311.pack(bref)); -std::string codebook_params_s::type2_port_sel_s_::amplitude_scaling_type_opts::to_string() const -{ - static const char* options[] = {"wideband", "widebandAndSubband"}; - return convert_enum_idx(options, 2, value, "codebook_params_s::type2_port_sel_s_::amplitude_scaling_type_e_"); -} + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= t311; + group_flags.pack(bref); -// DummyG ::= SEQUENCE -SRSASN_CODE dummy_g_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.pack(bref)); - HANDLE_CODE(max_num_ssb_csi_rs_res_two_tx.pack(bref)); - HANDLE_CODE(supported_csi_rs_density.pack(bref)); + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + HANDLE_CODE(t311.pack(bref)); + } + } return SRSASN_SUCCESS; } -SRSASN_CODE dummy_g_s::unpack(cbit_ref& bref) +SRSASN_CODE rlf_timers_and_consts_s::unpack(cbit_ref& bref) { - HANDLE_CODE(max_num_ssb_csi_rs_res_one_tx.unpack(bref)); - HANDLE_CODE(max_num_ssb_csi_rs_res_two_tx.unpack(bref)); - HANDLE_CODE(supported_csi_rs_density.unpack(bref)); + bref.unpack(ext, 1); + HANDLE_CODE(t310.unpack(bref)); + HANDLE_CODE(n310.unpack(bref)); + HANDLE_CODE(n311.unpack(bref)); + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + HANDLE_CODE(t311.unpack(bref)); + } + } return SRSASN_SUCCESS; } -void dummy_g_s::to_json(json_writer& j) const +void rlf_timers_and_consts_s::to_json(json_writer& j) const { j.start_obj(); - j.write_str("maxNumberSSB-CSI-RS-ResourceOneTx", max_num_ssb_csi_rs_res_one_tx.to_string()); - j.write_str("maxNumberSSB-CSI-RS-ResourceTwoTx", max_num_ssb_csi_rs_res_two_tx.to_string()); - j.write_str("supportedCSI-RS-Density", supported_csi_rs_density.to_string()); + j.write_str("t310", t310.to_string()); + j.write_str("n310", n310.to_string()); + j.write_str("n311", n311.to_string()); + if (ext) { + j.write_str("t311", t311.to_string()); + } j.end_obj(); } -std::string dummy_g_s::max_num_ssb_csi_rs_res_one_tx_opts::to_string() const +std::string rlf_timers_and_consts_s::t310_opts::to_string() const { - static const char* options[] = {"n8", "n16", "n32", "n64"}; - return convert_enum_idx(options, 4, value, "dummy_g_s::max_num_ssb_csi_rs_res_one_tx_e_"); + static const char* options[] = {"ms0", "ms50", "ms100", "ms200", "ms500", "ms1000", "ms2000", "ms4000", "ms6000"}; + return convert_enum_idx(options, 9, value, "rlf_timers_and_consts_s::t310_e_"); } -uint8_t dummy_g_s::max_num_ssb_csi_rs_res_one_tx_opts::to_number() const +uint16_t rlf_timers_and_consts_s::t310_opts::to_number() const { - static const uint8_t options[] = {8, 16, 32, 64}; - return map_enum_number(options, 4, value, "dummy_g_s::max_num_ssb_csi_rs_res_one_tx_e_"); + static const uint16_t options[] = {0, 50, 100, 200, 500, 1000, 2000, 4000, 6000}; + return map_enum_number(options, 9, value, "rlf_timers_and_consts_s::t310_e_"); } -std::string dummy_g_s::max_num_ssb_csi_rs_res_two_tx_opts::to_string() const +std::string rlf_timers_and_consts_s::n310_opts::to_string() const { - static const char* options[] = {"n0", "n4", "n8", "n16", "n32", "n64"}; - return convert_enum_idx(options, 6, value, "dummy_g_s::max_num_ssb_csi_rs_res_two_tx_e_"); + static const char* options[] = {"n1", "n2", "n3", "n4", "n6", "n8", "n10", "n20"}; + return convert_enum_idx(options, 8, value, "rlf_timers_and_consts_s::n310_e_"); } -uint8_t dummy_g_s::max_num_ssb_csi_rs_res_two_tx_opts::to_number() const +uint8_t rlf_timers_and_consts_s::n310_opts::to_number() const { - static const uint8_t options[] = {0, 4, 8, 16, 32, 64}; - return map_enum_number(options, 6, value, "dummy_g_s::max_num_ssb_csi_rs_res_two_tx_e_"); + static const uint8_t options[] = {1, 2, 3, 4, 6, 8, 10, 20}; + return map_enum_number(options, 8, value, "rlf_timers_and_consts_s::n310_e_"); } -std::string dummy_g_s::supported_csi_rs_density_opts::to_string() const +std::string rlf_timers_and_consts_s::n311_opts::to_string() const { - static const char* options[] = {"one", "three", "oneAndThree"}; - return convert_enum_idx(options, 3, value, "dummy_g_s::supported_csi_rs_density_e_"); + static const char* options[] = {"n1", "n2", "n3", "n4", "n5", "n6", "n8", "n10"}; + return convert_enum_idx(options, 8, value, "rlf_timers_and_consts_s::n311_e_"); } - -// DummyH ::= SEQUENCE -SRSASN_CODE dummy_h_s::pack(bit_ref& bref) const +uint8_t rlf_timers_and_consts_s::n311_opts::to_number() const { - HANDLE_CODE(pack_integer(bref, burst_len, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(pack_integer(bref, max_simul_res_sets_per_cc, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_per_cc, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(pack_integer(bref, max_cfgured_res_sets_all_cc, (uint8_t)1u, (uint8_t)128u)); - - return SRSASN_SUCCESS; + static const uint8_t options[] = {1, 2, 3, 4, 5, 6, 8, 10}; + return map_enum_number(options, 8, value, "rlf_timers_and_consts_s::n311_e_"); } -SRSASN_CODE dummy_h_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(burst_len, bref, (uint8_t)1u, (uint8_t)2u)); - HANDLE_CODE(unpack_integer(max_simul_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)8u)); - HANDLE_CODE(unpack_integer(max_cfgured_res_sets_per_cc, bref, (uint8_t)1u, (uint8_t)64u)); - HANDLE_CODE(unpack_integer(max_cfgured_res_sets_all_cc, bref, (uint8_t)1u, (uint8_t)128u)); - return SRSASN_SUCCESS; +std::string rlf_timers_and_consts_s::t311_opts::to_string() const +{ + static const char* options[] = {"ms1000", "ms3000", "ms5000", "ms10000", "ms15000", "ms20000", "ms30000"}; + return convert_enum_idx(options, 7, value, "rlf_timers_and_consts_s::t311_e_"); } -void dummy_h_s::to_json(json_writer& j) const +uint16_t rlf_timers_and_consts_s::t311_opts::to_number() const { - j.start_obj(); - j.write_int("burstLength", burst_len); - j.write_int("maxSimultaneousResourceSetsPerCC", max_simul_res_sets_per_cc); - j.write_int("maxConfiguredResourceSetsPerCC", max_cfgured_res_sets_per_cc); - j.write_int("maxConfiguredResourceSetsAllCC", max_cfgured_res_sets_all_cc); - j.end_obj(); + static const uint16_t options[] = {1000, 3000, 5000, 10000, 15000, 20000, 30000}; + return map_enum_number(options, 7, value, "rlf_timers_and_consts_s::t311_e_"); } -// PTRS-DensityRecommendationDL ::= SEQUENCE -SRSASN_CODE ptrs_density_recommendation_dl_s::pack(bit_ref& bref) const +// ReconfigurationWithSync ::= SEQUENCE +SRSASN_CODE recfg_with_sync_s::pack(bit_ref& bref) const { - HANDLE_CODE(pack_integer(bref, freq_density1, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, freq_density2, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, time_density1, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(pack_integer(bref, time_density2, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(pack_integer(bref, time_density3, (uint8_t)0u, (uint8_t)29u)); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(sp_cell_cfg_common_present, 1)); + HANDLE_CODE(bref.pack(rach_cfg_ded_present, 1)); + if (sp_cell_cfg_common_present) { + HANDLE_CODE(sp_cell_cfg_common.pack(bref)); + } + HANDLE_CODE(pack_integer(bref, new_ue_id, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(t304.pack(bref)); + if (rach_cfg_ded_present) { + HANDLE_CODE(rach_cfg_ded.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= smtc.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(smtc.is_present(), 1)); + if (smtc.is_present()) { + HANDLE_CODE(smtc->pack(bref)); + } + } + } return SRSASN_SUCCESS; } -SRSASN_CODE ptrs_density_recommendation_dl_s::unpack(cbit_ref& bref) +SRSASN_CODE recfg_with_sync_s::unpack(cbit_ref& bref) { - HANDLE_CODE(unpack_integer(freq_density1, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(freq_density2, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(time_density1, bref, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(unpack_integer(time_density2, bref, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(unpack_integer(time_density3, bref, (uint8_t)0u, (uint8_t)29u)); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(sp_cell_cfg_common_present, 1)); + HANDLE_CODE(bref.unpack(rach_cfg_ded_present, 1)); + + if (sp_cell_cfg_common_present) { + HANDLE_CODE(sp_cell_cfg_common.unpack(bref)); + } + HANDLE_CODE(unpack_integer(new_ue_id, bref, (uint32_t)0u, (uint32_t)65535u)); + HANDLE_CODE(t304.unpack(bref)); + if (rach_cfg_ded_present) { + HANDLE_CODE(rach_cfg_ded.unpack(bref)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + bool smtc_present; + HANDLE_CODE(bref.unpack(smtc_present, 1)); + smtc.set_present(smtc_present); + if (smtc.is_present()) { + HANDLE_CODE(smtc->unpack(bref)); + } + } + } return SRSASN_SUCCESS; } -void ptrs_density_recommendation_dl_s::to_json(json_writer& j) const +void recfg_with_sync_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("frequencyDensity1", freq_density1); - j.write_int("frequencyDensity2", freq_density2); - j.write_int("timeDensity1", time_density1); - j.write_int("timeDensity2", time_density2); - j.write_int("timeDensity3", time_density3); + if (sp_cell_cfg_common_present) { + j.write_fieldname("spCellConfigCommon"); + sp_cell_cfg_common.to_json(j); + } + j.write_int("newUE-Identity", new_ue_id); + j.write_str("t304", t304.to_string()); + if (rach_cfg_ded_present) { + j.write_fieldname("rach-ConfigDedicated"); + rach_cfg_ded.to_json(j); + } + if (ext) { + if (smtc.is_present()) { + j.write_fieldname("smtc"); + smtc->to_json(j); + } + } j.end_obj(); } -// PTRS-DensityRecommendationUL ::= SEQUENCE -SRSASN_CODE ptrs_density_recommendation_ul_s::pack(bit_ref& bref) const +std::string recfg_with_sync_s::t304_opts::to_string() const { - HANDLE_CODE(pack_integer(bref, freq_density1, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, freq_density2, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, time_density1, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(pack_integer(bref, time_density2, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(pack_integer(bref, time_density3, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(pack_integer(bref, sample_density1, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, sample_density2, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, sample_density3, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, sample_density4, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(pack_integer(bref, sample_density5, (uint16_t)1u, (uint16_t)276u)); - - return SRSASN_SUCCESS; + static const char* options[] = {"ms50", "ms100", "ms150", "ms200", "ms500", "ms1000", "ms2000", "ms10000"}; + return convert_enum_idx(options, 8, value, "recfg_with_sync_s::t304_e_"); } -SRSASN_CODE ptrs_density_recommendation_ul_s::unpack(cbit_ref& bref) +uint16_t recfg_with_sync_s::t304_opts::to_number() const { - HANDLE_CODE(unpack_integer(freq_density1, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(freq_density2, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(time_density1, bref, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(unpack_integer(time_density2, bref, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(unpack_integer(time_density3, bref, (uint8_t)0u, (uint8_t)29u)); - HANDLE_CODE(unpack_integer(sample_density1, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(sample_density2, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(sample_density3, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(sample_density4, bref, (uint16_t)1u, (uint16_t)276u)); - HANDLE_CODE(unpack_integer(sample_density5, bref, (uint16_t)1u, (uint16_t)276u)); + static const uint16_t options[] = {50, 100, 150, 200, 500, 1000, 2000, 10000}; + return map_enum_number(options, 8, value, "recfg_with_sync_s::t304_e_"); +} - return SRSASN_SUCCESS; +void recfg_with_sync_s::rach_cfg_ded_c_::destroy_() +{ + switch (type_) { + case types::ul: + c.destroy(); + break; + case types::supplementary_ul: + c.destroy(); + break; + default: + break; + } } -void ptrs_density_recommendation_ul_s::to_json(json_writer& j) const +void recfg_with_sync_s::rach_cfg_ded_c_::set(types::options e) { - j.start_obj(); - j.write_int("frequencyDensity1", freq_density1); - j.write_int("frequencyDensity2", freq_density2); - j.write_int("timeDensity1", time_density1); - j.write_int("timeDensity2", time_density2); - j.write_int("timeDensity3", time_density3); - j.write_int("sampleDensity1", sample_density1); - j.write_int("sampleDensity2", sample_density2); - j.write_int("sampleDensity3", sample_density3); - j.write_int("sampleDensity4", sample_density4); - j.write_int("sampleDensity5", sample_density5); - j.end_obj(); + destroy_(); + type_ = e; + switch (type_) { + case types::ul: + c.init(); + break; + case types::supplementary_ul: + c.init(); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + } } - -// SpatialRelations ::= SEQUENCE -SRSASN_CODE spatial_relations_s::pack(bit_ref& bref) const +recfg_with_sync_s::rach_cfg_ded_c_::rach_cfg_ded_c_(const recfg_with_sync_s::rach_cfg_ded_c_& other) { - HANDLE_CODE(bref.pack(add_active_spatial_relation_pucch_present, 1)); - - HANDLE_CODE(max_num_cfgured_spatial_relations.pack(bref)); - HANDLE_CODE(max_num_active_spatial_relations.pack(bref)); - HANDLE_CODE(max_num_dl_rs_qcl_type_d.pack(bref)); - - return SRSASN_SUCCESS; + type_ = other.type(); + switch (type_) { + case types::ul: + c.init(other.c.get()); + break; + case types::supplementary_ul: + c.init(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + } } -SRSASN_CODE spatial_relations_s::unpack(cbit_ref& bref) +recfg_with_sync_s::rach_cfg_ded_c_& +recfg_with_sync_s::rach_cfg_ded_c_::operator=(const recfg_with_sync_s::rach_cfg_ded_c_& other) { - HANDLE_CODE(bref.unpack(add_active_spatial_relation_pucch_present, 1)); - - HANDLE_CODE(max_num_cfgured_spatial_relations.unpack(bref)); - HANDLE_CODE(max_num_active_spatial_relations.unpack(bref)); - HANDLE_CODE(max_num_dl_rs_qcl_type_d.unpack(bref)); + if (this == &other) { + return *this; + } + set(other.type()); + switch (type_) { + case types::ul: + c.set(other.c.get()); + break; + case types::supplementary_ul: + c.set(other.c.get()); + break; + case types::nulltype: + break; + default: + log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + } - return SRSASN_SUCCESS; + return *this; } -void spatial_relations_s::to_json(json_writer& j) const +void recfg_with_sync_s::rach_cfg_ded_c_::to_json(json_writer& j) const { j.start_obj(); - j.write_str("maxNumberConfiguredSpatialRelations", max_num_cfgured_spatial_relations.to_string()); - j.write_str("maxNumberActiveSpatialRelations", max_num_active_spatial_relations.to_string()); - if (add_active_spatial_relation_pucch_present) { - j.write_str("additionalActiveSpatialRelationPUCCH", "supported"); + switch (type_) { + case types::ul: + j.write_fieldname("uplink"); + c.get().to_json(j); + break; + case types::supplementary_ul: + j.write_fieldname("supplementaryUplink"); + c.get().to_json(j); + break; + default: + log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); } - j.write_str("maxNumberDL-RS-QCL-TypeD", max_num_dl_rs_qcl_type_d.to_string()); j.end_obj(); } - -std::string spatial_relations_s::max_num_cfgured_spatial_relations_opts::to_string() const +SRSASN_CODE recfg_with_sync_s::rach_cfg_ded_c_::pack(bit_ref& bref) const { - static const char* options[] = {"n4", "n8", "n16", "n32", "n64", "n96"}; - return convert_enum_idx(options, 6, value, "spatial_relations_s::max_num_cfgured_spatial_relations_e_"); + type_.pack(bref); + switch (type_) { + case types::ul: + HANDLE_CODE(c.get().pack(bref)); + break; + case types::supplementary_ul: + HANDLE_CODE(c.get().pack(bref)); + break; + default: + log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + return SRSASN_ERROR_ENCODE_FAIL; + } + return SRSASN_SUCCESS; } -uint8_t spatial_relations_s::max_num_cfgured_spatial_relations_opts::to_number() const +SRSASN_CODE recfg_with_sync_s::rach_cfg_ded_c_::unpack(cbit_ref& bref) { - static const uint8_t options[] = {4, 8, 16, 32, 64, 96}; - return map_enum_number(options, 6, value, "spatial_relations_s::max_num_cfgured_spatial_relations_e_"); + types e; + e.unpack(bref); + set(e); + switch (type_) { + case types::ul: + HANDLE_CODE(c.get().unpack(bref)); + break; + case types::supplementary_ul: + HANDLE_CODE(c.get().unpack(bref)); + break; + default: + log_invalid_choice_id(type_, "recfg_with_sync_s::rach_cfg_ded_c_"); + return SRSASN_ERROR_DECODE_FAIL; + } + return SRSASN_SUCCESS; } -std::string spatial_relations_s::max_num_active_spatial_relations_opts::to_string() const +std::string recfg_with_sync_s::rach_cfg_ded_c_::types_opts::to_string() const { - static const char* options[] = {"n1", "n2", "n4", "n8", "n14"}; - return convert_enum_idx(options, 5, value, "spatial_relations_s::max_num_active_spatial_relations_e_"); + static const char* options[] = {"uplink", "supplementaryUplink"}; + return convert_enum_idx(options, 2, value, "recfg_with_sync_s::rach_cfg_ded_c_::types"); } -uint8_t spatial_relations_s::max_num_active_spatial_relations_opts::to_number() const + +// SchedulingRequestConfig ::= SEQUENCE +SRSASN_CODE sched_request_cfg_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {1, 2, 4, 8, 14}; - return map_enum_number(options, 5, value, "spatial_relations_s::max_num_active_spatial_relations_e_"); + HANDLE_CODE(bref.pack(sched_request_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(sched_request_to_release_list_present, 1)); + + if (sched_request_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_to_add_mod_list, 1, 8)); + } + if (sched_request_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sched_request_to_release_list, 1, 8, integer_packer(0, 7))); + } + + return SRSASN_SUCCESS; } +SRSASN_CODE sched_request_cfg_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(sched_request_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(sched_request_to_release_list_present, 1)); + + if (sched_request_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sched_request_to_add_mod_list, bref, 1, 8)); + } + if (sched_request_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(sched_request_to_release_list, bref, 1, 8, integer_packer(0, 7))); + } -std::string spatial_relations_s::max_num_dl_rs_qcl_type_d_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4", "n8", "n14"}; - return convert_enum_idx(options, 5, value, "spatial_relations_s::max_num_dl_rs_qcl_type_d_e_"); + return SRSASN_SUCCESS; } -uint8_t spatial_relations_s::max_num_dl_rs_qcl_type_d_opts::to_number() const +void sched_request_cfg_s::to_json(json_writer& j) const { - static const uint8_t options[] = {1, 2, 4, 8, 14}; - return map_enum_number(options, 5, value, "spatial_relations_s::max_num_dl_rs_qcl_type_d_e_"); + j.start_obj(); + if (sched_request_to_add_mod_list_present) { + j.start_array("schedulingRequestToAddModList"); + for (const auto& e1 : sched_request_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (sched_request_to_release_list_present) { + j.start_array("schedulingRequestToReleaseList"); + for (const auto& e1 : sched_request_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + j.end_obj(); } -// MIMO-ParametersPerBand ::= SEQUENCE -SRSASN_CODE mimo_params_per_band_s::pack(bit_ref& bref) const +// ServingCellConfig ::= SEQUENCE +SRSASN_CODE serving_cell_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(tci_state_pdsch_present, 1)); - HANDLE_CODE(bref.pack(add_active_tci_state_pdcch_present, 1)); - HANDLE_CODE(bref.pack(pusch_trans_coherence_present, 1)); - HANDLE_CODE(bref.pack(beam_correspondence_without_ul_beam_sweeping_present, 1)); - HANDLE_CODE(bref.pack(periodic_beam_report_present, 1)); - HANDLE_CODE(bref.pack(aperiodic_beam_report_present, 1)); - HANDLE_CODE(bref.pack(sp_beam_report_pucch_present, 1)); - HANDLE_CODE(bref.pack(sp_beam_report_pusch_present, 1)); - HANDLE_CODE(bref.pack(dummy1_present, 1)); - HANDLE_CODE(bref.pack(max_num_rx_beam_present, 1)); - HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl_present, 1)); - HANDLE_CODE(bref.pack(max_num_non_group_beam_report_present, 1)); - HANDLE_CODE(bref.pack(group_beam_report_present, 1)); - HANDLE_CODE(bref.pack(ul_beam_management_present, 1)); - HANDLE_CODE(bref.pack(max_num_csi_rs_bfd_present, 1)); - HANDLE_CODE(bref.pack(max_num_ssb_bfd_present, 1)); - HANDLE_CODE(bref.pack(max_num_csi_rs_ssb_cbd_present, 1)); - HANDLE_CODE(bref.pack(dummy2_present, 1)); - HANDLE_CODE(bref.pack(two_ports_ptrs_ul_present, 1)); - HANDLE_CODE(bref.pack(dummy5_present, 1)); - HANDLE_CODE(bref.pack(dummy3_present, 1)); - HANDLE_CODE(bref.pack(beam_report_timing_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul_present, 1)); - HANDLE_CODE(bref.pack(dummy4_present, 1)); - HANDLE_CODE(bref.pack(aperiodic_trs_present, 1)); + HANDLE_CODE(bref.pack(tdd_ul_dl_cfg_ded_present, 1)); + HANDLE_CODE(bref.pack(init_dl_bwp_present, 1)); + HANDLE_CODE(bref.pack(dl_bwp_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(dl_bwp_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(first_active_dl_bwp_id_present, 1)); + HANDLE_CODE(bref.pack(bwp_inactivity_timer_present, 1)); + HANDLE_CODE(bref.pack(default_dl_bwp_id_present, 1)); + HANDLE_CODE(bref.pack(ul_cfg_present, 1)); + HANDLE_CODE(bref.pack(supplementary_ul_present, 1)); + HANDLE_CODE(bref.pack(pdcch_serving_cell_cfg_present, 1)); + HANDLE_CODE(bref.pack(pdsch_serving_cell_cfg_present, 1)); + HANDLE_CODE(bref.pack(csi_meas_cfg_present, 1)); + HANDLE_CODE(bref.pack(scell_deactivation_timer_present, 1)); + HANDLE_CODE(bref.pack(cross_carrier_sched_cfg_present, 1)); + HANDLE_CODE(bref.pack(dummy_present, 1)); + HANDLE_CODE(bref.pack(pathloss_ref_linking_present, 1)); + HANDLE_CODE(bref.pack(serving_cell_mo_present, 1)); - if (tci_state_pdsch_present) { - HANDLE_CODE(bref.pack(tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present, 1)); - HANDLE_CODE(bref.pack(tci_state_pdsch.max_num_active_tci_per_bwp_present, 1)); - if (tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present) { - HANDLE_CODE(tci_state_pdsch.max_num_cfgured_tcistates_per_cc.pack(bref)); - } - if (tci_state_pdsch.max_num_active_tci_per_bwp_present) { - HANDLE_CODE(tci_state_pdsch.max_num_active_tci_per_bwp.pack(bref)); - } + if (tdd_ul_dl_cfg_ded_present) { + HANDLE_CODE(tdd_ul_dl_cfg_ded.pack(bref)); } - if (pusch_trans_coherence_present) { - HANDLE_CODE(pusch_trans_coherence.pack(bref)); + if (init_dl_bwp_present) { + HANDLE_CODE(init_dl_bwp.pack(bref)); } - if (dummy1_present) { - HANDLE_CODE(dummy1.pack(bref)); + if (dl_bwp_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, dl_bwp_to_release_list, 1, 4, integer_packer(0, 4))); } - if (max_num_rx_beam_present) { - HANDLE_CODE(pack_integer(bref, max_num_rx_beam, (uint8_t)2u, (uint8_t)8u)); + if (dl_bwp_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, dl_bwp_to_add_mod_list, 1, 4)); } - if (max_num_rx_tx_beam_switch_dl_present) { - HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present, 1)); - HANDLE_CODE(bref.pack(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present, 1)); - if (max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz.pack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz.pack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz.pack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz.pack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz.pack(bref)); - } + if (first_active_dl_bwp_id_present) { + HANDLE_CODE(pack_integer(bref, first_active_dl_bwp_id, (uint8_t)0u, (uint8_t)4u)); } - if (max_num_non_group_beam_report_present) { - HANDLE_CODE(max_num_non_group_beam_report.pack(bref)); + if (bwp_inactivity_timer_present) { + HANDLE_CODE(bwp_inactivity_timer.pack(bref)); } - if (ul_beam_management_present) { - HANDLE_CODE(ul_beam_management.max_num_srs_res_per_set_bm.pack(bref)); - HANDLE_CODE(pack_integer(bref, ul_beam_management.max_num_srs_res_set, (uint8_t)1u, (uint8_t)8u)); + if (default_dl_bwp_id_present) { + HANDLE_CODE(pack_integer(bref, default_dl_bwp_id, (uint8_t)0u, (uint8_t)4u)); } - if (max_num_csi_rs_bfd_present) { - HANDLE_CODE(pack_integer(bref, max_num_csi_rs_bfd, (uint8_t)1u, (uint8_t)64u)); + if (ul_cfg_present) { + HANDLE_CODE(ul_cfg.pack(bref)); } - if (max_num_ssb_bfd_present) { - HANDLE_CODE(pack_integer(bref, max_num_ssb_bfd, (uint8_t)1u, (uint8_t)64u)); + if (supplementary_ul_present) { + HANDLE_CODE(supplementary_ul.pack(bref)); } - if (max_num_csi_rs_ssb_cbd_present) { - HANDLE_CODE(pack_integer(bref, max_num_csi_rs_ssb_cbd, (uint16_t)1u, (uint16_t)256u)); + if (pdcch_serving_cell_cfg_present) { + HANDLE_CODE(pdcch_serving_cell_cfg.pack(bref)); } - if (dummy5_present) { - HANDLE_CODE(dummy5.pack(bref)); + if (pdsch_serving_cell_cfg_present) { + HANDLE_CODE(pdsch_serving_cell_cfg.pack(bref)); } - if (dummy3_present) { - HANDLE_CODE(pack_integer(bref, dummy3, (uint8_t)1u, (uint8_t)4u)); + if (csi_meas_cfg_present) { + HANDLE_CODE(csi_meas_cfg.pack(bref)); } - if (beam_report_timing_present) { - HANDLE_CODE(bref.pack(beam_report_timing.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.pack(beam_report_timing.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.pack(beam_report_timing.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.pack(beam_report_timing.scs_minus120k_hz_present, 1)); - if (beam_report_timing.scs_minus15k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus15k_hz.pack(bref)); - } - if (beam_report_timing.scs_minus30k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus30k_hz.pack(bref)); - } - if (beam_report_timing.scs_minus60k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus60k_hz.pack(bref)); - } - if (beam_report_timing.scs_minus120k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus120k_hz.pack(bref)); - } + if (scell_deactivation_timer_present) { + HANDLE_CODE(scell_deactivation_timer.pack(bref)); } - if (ptrs_density_recommendation_set_dl_present) { - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_dl.scs_minus120k_hz_present, 1)); - if (ptrs_density_recommendation_set_dl.scs_minus15k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus15k_hz.pack(bref)); - } - if (ptrs_density_recommendation_set_dl.scs_minus30k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus30k_hz.pack(bref)); - } - if (ptrs_density_recommendation_set_dl.scs_minus60k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus60k_hz.pack(bref)); - } - if (ptrs_density_recommendation_set_dl.scs_minus120k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus120k_hz.pack(bref)); - } + if (cross_carrier_sched_cfg_present) { + HANDLE_CODE(cross_carrier_sched_cfg.pack(bref)); } - if (ptrs_density_recommendation_set_ul_present) { - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.pack(ptrs_density_recommendation_set_ul.scs_minus120k_hz_present, 1)); - if (ptrs_density_recommendation_set_ul.scs_minus15k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus15k_hz.pack(bref)); - } - if (ptrs_density_recommendation_set_ul.scs_minus30k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus30k_hz.pack(bref)); - } - if (ptrs_density_recommendation_set_ul.scs_minus60k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus60k_hz.pack(bref)); - } - if (ptrs_density_recommendation_set_ul.scs_minus120k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus120k_hz.pack(bref)); - } + HANDLE_CODE(pack_integer(bref, tag_id, (uint8_t)0u, (uint8_t)3u)); + if (pathloss_ref_linking_present) { + HANDLE_CODE(pathloss_ref_linking.pack(bref)); } - if (dummy4_present) { - HANDLE_CODE(dummy4.pack(bref)); + if (serving_cell_mo_present) { + HANDLE_CODE(pack_integer(bref, serving_cell_mo, (uint8_t)1u, (uint8_t)64u)); } if (ext) { ext_groups_packer_guard group_flags; - group_flags[0] |= beam_correspondence_ca_present; - group_flags[0] |= beam_management_ssb_csi_rs.is_present(); - group_flags[0] |= beam_switch_timing.is_present(); - group_flags[0] |= codebook_params.is_present(); - group_flags[0] |= csi_rs_im_reception_for_feedback.is_present(); - group_flags[0] |= csi_rs_proc_framework_for_srs.is_present(); - group_flags[0] |= csi_report_framework.is_present(); - group_flags[0] |= csi_rs_for_tracking.is_present(); - group_flags[0] |= srs_assoc_csi_rs.is_present(); - group_flags[0] |= spatial_relations.is_present(); + group_flags[0] |= lte_crs_to_match_around.is_present(); + group_flags[0] |= rate_match_pattern_to_add_mod_list.is_present(); + group_flags[0] |= rate_match_pattern_to_release_list.is_present(); + group_flags[0] |= dl_ch_bw_per_scs_list.is_present(); group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(beam_correspondence_ca_present, 1)); - HANDLE_CODE(bref.pack(beam_management_ssb_csi_rs.is_present(), 1)); - HANDLE_CODE(bref.pack(beam_switch_timing.is_present(), 1)); - HANDLE_CODE(bref.pack(codebook_params.is_present(), 1)); - HANDLE_CODE(bref.pack(csi_rs_im_reception_for_feedback.is_present(), 1)); - HANDLE_CODE(bref.pack(csi_rs_proc_framework_for_srs.is_present(), 1)); - HANDLE_CODE(bref.pack(csi_report_framework.is_present(), 1)); - HANDLE_CODE(bref.pack(csi_rs_for_tracking.is_present(), 1)); - HANDLE_CODE(bref.pack(srs_assoc_csi_rs.is_present(), 1)); - HANDLE_CODE(bref.pack(spatial_relations.is_present(), 1)); - if (beam_management_ssb_csi_rs.is_present()) { - HANDLE_CODE(beam_management_ssb_csi_rs->pack(bref)); - } - if (beam_switch_timing.is_present()) { - HANDLE_CODE(bref.pack(beam_switch_timing->scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.pack(beam_switch_timing->scs_minus120k_hz_present, 1)); - if (beam_switch_timing->scs_minus60k_hz_present) { - HANDLE_CODE(beam_switch_timing->scs_minus60k_hz.pack(bref)); - } - if (beam_switch_timing->scs_minus120k_hz_present) { - HANDLE_CODE(beam_switch_timing->scs_minus120k_hz.pack(bref)); - } - } - if (codebook_params.is_present()) { - HANDLE_CODE(codebook_params->pack(bref)); - } - if (csi_rs_im_reception_for_feedback.is_present()) { - HANDLE_CODE(csi_rs_im_reception_for_feedback->pack(bref)); - } - if (csi_rs_proc_framework_for_srs.is_present()) { - HANDLE_CODE(csi_rs_proc_framework_for_srs->pack(bref)); - } - if (csi_report_framework.is_present()) { - HANDLE_CODE(csi_report_framework->pack(bref)); + HANDLE_CODE(bref.pack(lte_crs_to_match_around.is_present(), 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_to_add_mod_list.is_present(), 1)); + HANDLE_CODE(bref.pack(rate_match_pattern_to_release_list.is_present(), 1)); + HANDLE_CODE(bref.pack(dl_ch_bw_per_scs_list.is_present(), 1)); + if (lte_crs_to_match_around.is_present()) { + HANDLE_CODE(lte_crs_to_match_around->pack(bref)); } - if (csi_rs_for_tracking.is_present()) { - HANDLE_CODE(csi_rs_for_tracking->pack(bref)); + if (rate_match_pattern_to_add_mod_list.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *rate_match_pattern_to_add_mod_list, 1, 4)); } - if (srs_assoc_csi_rs.is_present()) { - HANDLE_CODE(pack_dyn_seq_of(bref, *srs_assoc_csi_rs, 1, 7)); + if (rate_match_pattern_to_release_list.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *rate_match_pattern_to_release_list, 1, 4, integer_packer(0, 3))); } - if (spatial_relations.is_present()) { - HANDLE_CODE(spatial_relations->pack(bref)); + if (dl_ch_bw_per_scs_list.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *dl_ch_bw_per_scs_list, 1, 5)); } } } return SRSASN_SUCCESS; } -SRSASN_CODE mimo_params_per_band_s::unpack(cbit_ref& bref) +SRSASN_CODE serving_cell_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(tci_state_pdsch_present, 1)); - HANDLE_CODE(bref.unpack(add_active_tci_state_pdcch_present, 1)); - HANDLE_CODE(bref.unpack(pusch_trans_coherence_present, 1)); - HANDLE_CODE(bref.unpack(beam_correspondence_without_ul_beam_sweeping_present, 1)); - HANDLE_CODE(bref.unpack(periodic_beam_report_present, 1)); - HANDLE_CODE(bref.unpack(aperiodic_beam_report_present, 1)); - HANDLE_CODE(bref.unpack(sp_beam_report_pucch_present, 1)); - HANDLE_CODE(bref.unpack(sp_beam_report_pusch_present, 1)); - HANDLE_CODE(bref.unpack(dummy1_present, 1)); - HANDLE_CODE(bref.unpack(max_num_rx_beam_present, 1)); - HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl_present, 1)); - HANDLE_CODE(bref.unpack(max_num_non_group_beam_report_present, 1)); - HANDLE_CODE(bref.unpack(group_beam_report_present, 1)); - HANDLE_CODE(bref.unpack(ul_beam_management_present, 1)); - HANDLE_CODE(bref.unpack(max_num_csi_rs_bfd_present, 1)); - HANDLE_CODE(bref.unpack(max_num_ssb_bfd_present, 1)); - HANDLE_CODE(bref.unpack(max_num_csi_rs_ssb_cbd_present, 1)); - HANDLE_CODE(bref.unpack(dummy2_present, 1)); - HANDLE_CODE(bref.unpack(two_ports_ptrs_ul_present, 1)); - HANDLE_CODE(bref.unpack(dummy5_present, 1)); - HANDLE_CODE(bref.unpack(dummy3_present, 1)); - HANDLE_CODE(bref.unpack(beam_report_timing_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul_present, 1)); - HANDLE_CODE(bref.unpack(dummy4_present, 1)); - HANDLE_CODE(bref.unpack(aperiodic_trs_present, 1)); + HANDLE_CODE(bref.unpack(tdd_ul_dl_cfg_ded_present, 1)); + HANDLE_CODE(bref.unpack(init_dl_bwp_present, 1)); + HANDLE_CODE(bref.unpack(dl_bwp_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(dl_bwp_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(first_active_dl_bwp_id_present, 1)); + HANDLE_CODE(bref.unpack(bwp_inactivity_timer_present, 1)); + HANDLE_CODE(bref.unpack(default_dl_bwp_id_present, 1)); + HANDLE_CODE(bref.unpack(ul_cfg_present, 1)); + HANDLE_CODE(bref.unpack(supplementary_ul_present, 1)); + HANDLE_CODE(bref.unpack(pdcch_serving_cell_cfg_present, 1)); + HANDLE_CODE(bref.unpack(pdsch_serving_cell_cfg_present, 1)); + HANDLE_CODE(bref.unpack(csi_meas_cfg_present, 1)); + HANDLE_CODE(bref.unpack(scell_deactivation_timer_present, 1)); + HANDLE_CODE(bref.unpack(cross_carrier_sched_cfg_present, 1)); + HANDLE_CODE(bref.unpack(dummy_present, 1)); + HANDLE_CODE(bref.unpack(pathloss_ref_linking_present, 1)); + HANDLE_CODE(bref.unpack(serving_cell_mo_present, 1)); - if (tci_state_pdsch_present) { - HANDLE_CODE(bref.unpack(tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present, 1)); - HANDLE_CODE(bref.unpack(tci_state_pdsch.max_num_active_tci_per_bwp_present, 1)); - if (tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present) { - HANDLE_CODE(tci_state_pdsch.max_num_cfgured_tcistates_per_cc.unpack(bref)); - } - if (tci_state_pdsch.max_num_active_tci_per_bwp_present) { - HANDLE_CODE(tci_state_pdsch.max_num_active_tci_per_bwp.unpack(bref)); - } + if (tdd_ul_dl_cfg_ded_present) { + HANDLE_CODE(tdd_ul_dl_cfg_ded.unpack(bref)); } - if (pusch_trans_coherence_present) { - HANDLE_CODE(pusch_trans_coherence.unpack(bref)); + if (init_dl_bwp_present) { + HANDLE_CODE(init_dl_bwp.unpack(bref)); } - if (dummy1_present) { - HANDLE_CODE(dummy1.unpack(bref)); + if (dl_bwp_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(dl_bwp_to_release_list, bref, 1, 4, integer_packer(0, 4))); } - if (max_num_rx_beam_present) { - HANDLE_CODE(unpack_integer(max_num_rx_beam, bref, (uint8_t)2u, (uint8_t)8u)); + if (dl_bwp_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(dl_bwp_to_add_mod_list, bref, 1, 4)); } - if (max_num_rx_tx_beam_switch_dl_present) { - HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present, 1)); - HANDLE_CODE(bref.unpack(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present, 1)); - if (max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus15k_hz.unpack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus30k_hz.unpack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus60k_hz.unpack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus120k_hz.unpack(bref)); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present) { - HANDLE_CODE(max_num_rx_tx_beam_switch_dl.scs_minus240k_hz.unpack(bref)); - } + if (first_active_dl_bwp_id_present) { + HANDLE_CODE(unpack_integer(first_active_dl_bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); } - if (max_num_non_group_beam_report_present) { - HANDLE_CODE(max_num_non_group_beam_report.unpack(bref)); + if (bwp_inactivity_timer_present) { + HANDLE_CODE(bwp_inactivity_timer.unpack(bref)); } - if (ul_beam_management_present) { - HANDLE_CODE(ul_beam_management.max_num_srs_res_per_set_bm.unpack(bref)); - HANDLE_CODE(unpack_integer(ul_beam_management.max_num_srs_res_set, bref, (uint8_t)1u, (uint8_t)8u)); + if (default_dl_bwp_id_present) { + HANDLE_CODE(unpack_integer(default_dl_bwp_id, bref, (uint8_t)0u, (uint8_t)4u)); } - if (max_num_csi_rs_bfd_present) { - HANDLE_CODE(unpack_integer(max_num_csi_rs_bfd, bref, (uint8_t)1u, (uint8_t)64u)); + if (ul_cfg_present) { + HANDLE_CODE(ul_cfg.unpack(bref)); } - if (max_num_ssb_bfd_present) { - HANDLE_CODE(unpack_integer(max_num_ssb_bfd, bref, (uint8_t)1u, (uint8_t)64u)); + if (supplementary_ul_present) { + HANDLE_CODE(supplementary_ul.unpack(bref)); } - if (max_num_csi_rs_ssb_cbd_present) { - HANDLE_CODE(unpack_integer(max_num_csi_rs_ssb_cbd, bref, (uint16_t)1u, (uint16_t)256u)); + if (pdcch_serving_cell_cfg_present) { + HANDLE_CODE(pdcch_serving_cell_cfg.unpack(bref)); } - if (dummy5_present) { - HANDLE_CODE(dummy5.unpack(bref)); + if (pdsch_serving_cell_cfg_present) { + HANDLE_CODE(pdsch_serving_cell_cfg.unpack(bref)); } - if (dummy3_present) { - HANDLE_CODE(unpack_integer(dummy3, bref, (uint8_t)1u, (uint8_t)4u)); + if (csi_meas_cfg_present) { + HANDLE_CODE(csi_meas_cfg.unpack(bref)); } - if (beam_report_timing_present) { - HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.unpack(beam_report_timing.scs_minus120k_hz_present, 1)); - if (beam_report_timing.scs_minus15k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus15k_hz.unpack(bref)); - } - if (beam_report_timing.scs_minus30k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus30k_hz.unpack(bref)); - } - if (beam_report_timing.scs_minus60k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus60k_hz.unpack(bref)); - } - if (beam_report_timing.scs_minus120k_hz_present) { - HANDLE_CODE(beam_report_timing.scs_minus120k_hz.unpack(bref)); - } + if (scell_deactivation_timer_present) { + HANDLE_CODE(scell_deactivation_timer.unpack(bref)); } - if (ptrs_density_recommendation_set_dl_present) { - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_dl.scs_minus120k_hz_present, 1)); - if (ptrs_density_recommendation_set_dl.scs_minus15k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus15k_hz.unpack(bref)); - } - if (ptrs_density_recommendation_set_dl.scs_minus30k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus30k_hz.unpack(bref)); - } - if (ptrs_density_recommendation_set_dl.scs_minus60k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus60k_hz.unpack(bref)); - } - if (ptrs_density_recommendation_set_dl.scs_minus120k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_dl.scs_minus120k_hz.unpack(bref)); - } + if (cross_carrier_sched_cfg_present) { + HANDLE_CODE(cross_carrier_sched_cfg.unpack(bref)); } - if (ptrs_density_recommendation_set_ul_present) { - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.unpack(ptrs_density_recommendation_set_ul.scs_minus120k_hz_present, 1)); - if (ptrs_density_recommendation_set_ul.scs_minus15k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus15k_hz.unpack(bref)); - } - if (ptrs_density_recommendation_set_ul.scs_minus30k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus30k_hz.unpack(bref)); - } - if (ptrs_density_recommendation_set_ul.scs_minus60k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus60k_hz.unpack(bref)); - } - if (ptrs_density_recommendation_set_ul.scs_minus120k_hz_present) { - HANDLE_CODE(ptrs_density_recommendation_set_ul.scs_minus120k_hz.unpack(bref)); - } + HANDLE_CODE(unpack_integer(tag_id, bref, (uint8_t)0u, (uint8_t)3u)); + if (pathloss_ref_linking_present) { + HANDLE_CODE(pathloss_ref_linking.unpack(bref)); } - if (dummy4_present) { - HANDLE_CODE(dummy4.unpack(bref)); + if (serving_cell_mo_present) { + HANDLE_CODE(unpack_integer(serving_cell_mo, bref, (uint8_t)1u, (uint8_t)64u)); } if (ext) { @@ -44284,1058 +47010,1032 @@ SRSASN_CODE mimo_params_per_band_s::unpack(cbit_ref& bref) if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.unpack(beam_correspondence_ca_present, 1)); - bool beam_management_ssb_csi_rs_present; - HANDLE_CODE(bref.unpack(beam_management_ssb_csi_rs_present, 1)); - beam_management_ssb_csi_rs.set_present(beam_management_ssb_csi_rs_present); - bool beam_switch_timing_present; - HANDLE_CODE(bref.unpack(beam_switch_timing_present, 1)); - beam_switch_timing.set_present(beam_switch_timing_present); - bool codebook_params_present; - HANDLE_CODE(bref.unpack(codebook_params_present, 1)); - codebook_params.set_present(codebook_params_present); - bool csi_rs_im_reception_for_feedback_present; - HANDLE_CODE(bref.unpack(csi_rs_im_reception_for_feedback_present, 1)); - csi_rs_im_reception_for_feedback.set_present(csi_rs_im_reception_for_feedback_present); - bool csi_rs_proc_framework_for_srs_present; - HANDLE_CODE(bref.unpack(csi_rs_proc_framework_for_srs_present, 1)); - csi_rs_proc_framework_for_srs.set_present(csi_rs_proc_framework_for_srs_present); - bool csi_report_framework_present; - HANDLE_CODE(bref.unpack(csi_report_framework_present, 1)); - csi_report_framework.set_present(csi_report_framework_present); - bool csi_rs_for_tracking_present; - HANDLE_CODE(bref.unpack(csi_rs_for_tracking_present, 1)); - csi_rs_for_tracking.set_present(csi_rs_for_tracking_present); - bool srs_assoc_csi_rs_present; - HANDLE_CODE(bref.unpack(srs_assoc_csi_rs_present, 1)); - srs_assoc_csi_rs.set_present(srs_assoc_csi_rs_present); - bool spatial_relations_present; - HANDLE_CODE(bref.unpack(spatial_relations_present, 1)); - spatial_relations.set_present(spatial_relations_present); - if (beam_management_ssb_csi_rs.is_present()) { - HANDLE_CODE(beam_management_ssb_csi_rs->unpack(bref)); - } - if (beam_switch_timing.is_present()) { - HANDLE_CODE(bref.unpack(beam_switch_timing->scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.unpack(beam_switch_timing->scs_minus120k_hz_present, 1)); - if (beam_switch_timing->scs_minus60k_hz_present) { - HANDLE_CODE(beam_switch_timing->scs_minus60k_hz.unpack(bref)); - } - if (beam_switch_timing->scs_minus120k_hz_present) { - HANDLE_CODE(beam_switch_timing->scs_minus120k_hz.unpack(bref)); - } - } - if (codebook_params.is_present()) { - HANDLE_CODE(codebook_params->unpack(bref)); - } - if (csi_rs_im_reception_for_feedback.is_present()) { - HANDLE_CODE(csi_rs_im_reception_for_feedback->unpack(bref)); - } - if (csi_rs_proc_framework_for_srs.is_present()) { - HANDLE_CODE(csi_rs_proc_framework_for_srs->unpack(bref)); - } - if (csi_report_framework.is_present()) { - HANDLE_CODE(csi_report_framework->unpack(bref)); + bool lte_crs_to_match_around_present; + HANDLE_CODE(bref.unpack(lte_crs_to_match_around_present, 1)); + lte_crs_to_match_around.set_present(lte_crs_to_match_around_present); + bool rate_match_pattern_to_add_mod_list_present; + HANDLE_CODE(bref.unpack(rate_match_pattern_to_add_mod_list_present, 1)); + rate_match_pattern_to_add_mod_list.set_present(rate_match_pattern_to_add_mod_list_present); + bool rate_match_pattern_to_release_list_present; + HANDLE_CODE(bref.unpack(rate_match_pattern_to_release_list_present, 1)); + rate_match_pattern_to_release_list.set_present(rate_match_pattern_to_release_list_present); + bool dl_ch_bw_per_scs_list_present; + HANDLE_CODE(bref.unpack(dl_ch_bw_per_scs_list_present, 1)); + dl_ch_bw_per_scs_list.set_present(dl_ch_bw_per_scs_list_present); + if (lte_crs_to_match_around.is_present()) { + HANDLE_CODE(lte_crs_to_match_around->unpack(bref)); } - if (csi_rs_for_tracking.is_present()) { - HANDLE_CODE(csi_rs_for_tracking->unpack(bref)); + if (rate_match_pattern_to_add_mod_list.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*rate_match_pattern_to_add_mod_list, bref, 1, 4)); } - if (srs_assoc_csi_rs.is_present()) { - HANDLE_CODE(unpack_dyn_seq_of(*srs_assoc_csi_rs, bref, 1, 7)); + if (rate_match_pattern_to_release_list.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*rate_match_pattern_to_release_list, bref, 1, 4, integer_packer(0, 3))); } - if (spatial_relations.is_present()) { - HANDLE_CODE(spatial_relations->unpack(bref)); + if (dl_ch_bw_per_scs_list.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*dl_ch_bw_per_scs_list, bref, 1, 5)); } } } return SRSASN_SUCCESS; } -void mimo_params_per_band_s::to_json(json_writer& j) const +void serving_cell_cfg_s::to_json(json_writer& j) const { j.start_obj(); - if (tci_state_pdsch_present) { - j.write_fieldname("tci-StatePDSCH"); - j.start_obj(); - if (tci_state_pdsch.max_num_cfgured_tcistates_per_cc_present) { - j.write_str("maxNumberConfiguredTCIstatesPerCC", tci_state_pdsch.max_num_cfgured_tcistates_per_cc.to_string()); - } - if (tci_state_pdsch.max_num_active_tci_per_bwp_present) { - j.write_str("maxNumberActiveTCI-PerBWP", tci_state_pdsch.max_num_active_tci_per_bwp.to_string()); - } - j.end_obj(); - } - if (add_active_tci_state_pdcch_present) { - j.write_str("additionalActiveTCI-StatePDCCH", "supported"); - } - if (pusch_trans_coherence_present) { - j.write_str("pusch-TransCoherence", pusch_trans_coherence.to_string()); - } - if (beam_correspondence_without_ul_beam_sweeping_present) { - j.write_str("beamCorrespondenceWithoutUL-BeamSweeping", "supported"); - } - if (periodic_beam_report_present) { - j.write_str("periodicBeamReport", "supported"); - } - if (aperiodic_beam_report_present) { - j.write_str("aperiodicBeamReport", "supported"); - } - if (sp_beam_report_pucch_present) { - j.write_str("sp-BeamReportPUCCH", "supported"); - } - if (sp_beam_report_pusch_present) { - j.write_str("sp-BeamReportPUSCH", "supported"); - } - if (dummy1_present) { - j.write_fieldname("dummy1"); - dummy1.to_json(j); + if (tdd_ul_dl_cfg_ded_present) { + j.write_fieldname("tdd-UL-DL-ConfigurationDedicated"); + tdd_ul_dl_cfg_ded.to_json(j); } - if (max_num_rx_beam_present) { - j.write_int("maxNumberRxBeam", max_num_rx_beam); + if (init_dl_bwp_present) { + j.write_fieldname("initialDownlinkBWP"); + init_dl_bwp.to_json(j); } - if (max_num_rx_tx_beam_switch_dl_present) { - j.write_fieldname("maxNumberRxTxBeamSwitchDL"); - j.start_obj(); - if (max_num_rx_tx_beam_switch_dl.scs_minus15k_hz_present) { - j.write_str("scs-15kHz", max_num_rx_tx_beam_switch_dl.scs_minus15k_hz.to_string()); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus30k_hz_present) { - j.write_str("scs-30kHz", max_num_rx_tx_beam_switch_dl.scs_minus30k_hz.to_string()); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus60k_hz_present) { - j.write_str("scs-60kHz", max_num_rx_tx_beam_switch_dl.scs_minus60k_hz.to_string()); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus120k_hz_present) { - j.write_str("scs-120kHz", max_num_rx_tx_beam_switch_dl.scs_minus120k_hz.to_string()); - } - if (max_num_rx_tx_beam_switch_dl.scs_minus240k_hz_present) { - j.write_str("scs-240kHz", max_num_rx_tx_beam_switch_dl.scs_minus240k_hz.to_string()); + if (dl_bwp_to_release_list_present) { + j.start_array("downlinkBWP-ToReleaseList"); + for (const auto& e1 : dl_bwp_to_release_list) { + j.write_int(e1); } - j.end_obj(); - } - if (max_num_non_group_beam_report_present) { - j.write_str("maxNumberNonGroupBeamReporting", max_num_non_group_beam_report.to_string()); + j.end_array(); } - if (group_beam_report_present) { - j.write_str("groupBeamReporting", "supported"); + if (dl_bwp_to_add_mod_list_present) { + j.start_array("downlinkBWP-ToAddModList"); + for (const auto& e1 : dl_bwp_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); } - if (ul_beam_management_present) { - j.write_fieldname("uplinkBeamManagement"); - j.start_obj(); - j.write_str("maxNumberSRS-ResourcePerSet-BM", ul_beam_management.max_num_srs_res_per_set_bm.to_string()); - j.write_int("maxNumberSRS-ResourceSet", ul_beam_management.max_num_srs_res_set); - j.end_obj(); + if (first_active_dl_bwp_id_present) { + j.write_int("firstActiveDownlinkBWP-Id", first_active_dl_bwp_id); } - if (max_num_csi_rs_bfd_present) { - j.write_int("maxNumberCSI-RS-BFD", max_num_csi_rs_bfd); + if (bwp_inactivity_timer_present) { + j.write_str("bwp-InactivityTimer", bwp_inactivity_timer.to_string()); } - if (max_num_ssb_bfd_present) { - j.write_int("maxNumberSSB-BFD", max_num_ssb_bfd); + if (default_dl_bwp_id_present) { + j.write_int("defaultDownlinkBWP-Id", default_dl_bwp_id); } - if (max_num_csi_rs_ssb_cbd_present) { - j.write_int("maxNumberCSI-RS-SSB-CBD", max_num_csi_rs_ssb_cbd); + if (ul_cfg_present) { + j.write_fieldname("uplinkConfig"); + ul_cfg.to_json(j); } - if (dummy2_present) { - j.write_str("dummy2", "supported"); + if (supplementary_ul_present) { + j.write_fieldname("supplementaryUplink"); + supplementary_ul.to_json(j); } - if (two_ports_ptrs_ul_present) { - j.write_str("twoPortsPTRS-UL", "supported"); + if (pdcch_serving_cell_cfg_present) { + j.write_fieldname("pdcch-ServingCellConfig"); + pdcch_serving_cell_cfg.to_json(j); } - if (dummy5_present) { - j.write_fieldname("dummy5"); - dummy5.to_json(j); + if (pdsch_serving_cell_cfg_present) { + j.write_fieldname("pdsch-ServingCellConfig"); + pdsch_serving_cell_cfg.to_json(j); } - if (dummy3_present) { - j.write_int("dummy3", dummy3); + if (csi_meas_cfg_present) { + j.write_fieldname("csi-MeasConfig"); + csi_meas_cfg.to_json(j); } - if (beam_report_timing_present) { - j.write_fieldname("beamReportTiming"); - j.start_obj(); - if (beam_report_timing.scs_minus15k_hz_present) { - j.write_str("scs-15kHz", beam_report_timing.scs_minus15k_hz.to_string()); - } - if (beam_report_timing.scs_minus30k_hz_present) { - j.write_str("scs-30kHz", beam_report_timing.scs_minus30k_hz.to_string()); - } - if (beam_report_timing.scs_minus60k_hz_present) { - j.write_str("scs-60kHz", beam_report_timing.scs_minus60k_hz.to_string()); - } - if (beam_report_timing.scs_minus120k_hz_present) { - j.write_str("scs-120kHz", beam_report_timing.scs_minus120k_hz.to_string()); - } - j.end_obj(); + if (scell_deactivation_timer_present) { + j.write_str("sCellDeactivationTimer", scell_deactivation_timer.to_string()); } - if (ptrs_density_recommendation_set_dl_present) { - j.write_fieldname("ptrs-DensityRecommendationSetDL"); - j.start_obj(); - if (ptrs_density_recommendation_set_dl.scs_minus15k_hz_present) { - j.write_fieldname("scs-15kHz"); - ptrs_density_recommendation_set_dl.scs_minus15k_hz.to_json(j); - } - if (ptrs_density_recommendation_set_dl.scs_minus30k_hz_present) { - j.write_fieldname("scs-30kHz"); - ptrs_density_recommendation_set_dl.scs_minus30k_hz.to_json(j); - } - if (ptrs_density_recommendation_set_dl.scs_minus60k_hz_present) { - j.write_fieldname("scs-60kHz"); - ptrs_density_recommendation_set_dl.scs_minus60k_hz.to_json(j); - } - if (ptrs_density_recommendation_set_dl.scs_minus120k_hz_present) { - j.write_fieldname("scs-120kHz"); - ptrs_density_recommendation_set_dl.scs_minus120k_hz.to_json(j); - } - j.end_obj(); + if (cross_carrier_sched_cfg_present) { + j.write_fieldname("crossCarrierSchedulingConfig"); + cross_carrier_sched_cfg.to_json(j); } - if (ptrs_density_recommendation_set_ul_present) { - j.write_fieldname("ptrs-DensityRecommendationSetUL"); - j.start_obj(); - if (ptrs_density_recommendation_set_ul.scs_minus15k_hz_present) { - j.write_fieldname("scs-15kHz"); - ptrs_density_recommendation_set_ul.scs_minus15k_hz.to_json(j); - } - if (ptrs_density_recommendation_set_ul.scs_minus30k_hz_present) { - j.write_fieldname("scs-30kHz"); - ptrs_density_recommendation_set_ul.scs_minus30k_hz.to_json(j); - } - if (ptrs_density_recommendation_set_ul.scs_minus60k_hz_present) { - j.write_fieldname("scs-60kHz"); - ptrs_density_recommendation_set_ul.scs_minus60k_hz.to_json(j); - } - if (ptrs_density_recommendation_set_ul.scs_minus120k_hz_present) { - j.write_fieldname("scs-120kHz"); - ptrs_density_recommendation_set_ul.scs_minus120k_hz.to_json(j); - } - j.end_obj(); + j.write_int("tag-Id", tag_id); + if (dummy_present) { + j.write_str("dummy", "enabled"); } - if (dummy4_present) { - j.write_fieldname("dummy4"); - dummy4.to_json(j); + if (pathloss_ref_linking_present) { + j.write_str("pathlossReferenceLinking", pathloss_ref_linking.to_string()); } - if (aperiodic_trs_present) { - j.write_str("aperiodicTRS", "supported"); + if (serving_cell_mo_present) { + j.write_int("servingCellMO", serving_cell_mo); } if (ext) { - if (beam_correspondence_ca_present) { - j.write_str("beamCorrespondenceCA", "true"); - } - if (beam_management_ssb_csi_rs.is_present()) { - j.write_fieldname("beamManagementSSB-CSI-RS"); - beam_management_ssb_csi_rs->to_json(j); + if (lte_crs_to_match_around.is_present()) { + j.write_fieldname("lte-CRS-ToMatchAround"); + lte_crs_to_match_around->to_json(j); } - if (beam_switch_timing.is_present()) { - j.write_fieldname("beamSwitchTiming"); - j.start_obj(); - if (beam_switch_timing->scs_minus60k_hz_present) { - j.write_str("scs-60kHz", beam_switch_timing->scs_minus60k_hz.to_string()); - } - if (beam_switch_timing->scs_minus120k_hz_present) { - j.write_str("scs-120kHz", beam_switch_timing->scs_minus120k_hz.to_string()); + if (rate_match_pattern_to_add_mod_list.is_present()) { + j.start_array("rateMatchPatternToAddModList"); + for (const auto& e1 : *rate_match_pattern_to_add_mod_list) { + e1.to_json(j); } - j.end_obj(); - } - if (codebook_params.is_present()) { - j.write_fieldname("codebookParameters"); - codebook_params->to_json(j); - } - if (csi_rs_im_reception_for_feedback.is_present()) { - j.write_fieldname("csi-RS-IM-ReceptionForFeedback"); - csi_rs_im_reception_for_feedback->to_json(j); - } - if (csi_rs_proc_framework_for_srs.is_present()) { - j.write_fieldname("csi-RS-ProcFrameworkForSRS"); - csi_rs_proc_framework_for_srs->to_json(j); - } - if (csi_report_framework.is_present()) { - j.write_fieldname("csi-ReportFramework"); - csi_report_framework->to_json(j); + j.end_array(); } - if (csi_rs_for_tracking.is_present()) { - j.write_fieldname("csi-RS-ForTracking"); - csi_rs_for_tracking->to_json(j); + if (rate_match_pattern_to_release_list.is_present()) { + j.start_array("rateMatchPatternToReleaseList"); + for (const auto& e1 : *rate_match_pattern_to_release_list) { + j.write_int(e1); + } + j.end_array(); } - if (srs_assoc_csi_rs.is_present()) { - j.start_array("srs-AssocCSI-RS"); - for (const auto& e1 : *srs_assoc_csi_rs) { + if (dl_ch_bw_per_scs_list.is_present()) { + j.start_array("downlinkChannelBW-PerSCS-List"); + for (const auto& e1 : *dl_ch_bw_per_scs_list) { e1.to_json(j); } j.end_array(); } - if (spatial_relations.is_present()) { - j.write_fieldname("spatialRelations"); - spatial_relations->to_json(j); - } } j.end_obj(); } -std::string mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_opts::to_string() const -{ - static const char* options[] = {"n4", "n8", "n16", "n32", "n64", "n128"}; - return convert_enum_idx( - options, 6, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_e_"); -} -uint8_t mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_opts::to_number() const -{ - static const uint8_t options[] = {4, 8, 16, 32, 64, 128}; - return map_enum_number( - options, 6, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_cfgured_tcistates_per_cc_e_"); -} - -std::string mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4", "n8"}; - return convert_enum_idx( - options, 4, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_e_"); -} -uint8_t mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_opts::to_number() const +std::string serving_cell_cfg_s::bwp_inactivity_timer_opts::to_string() const { - static const uint8_t options[] = {1, 2, 4, 8}; - return map_enum_number( - options, 4, value, "mimo_params_per_band_s::tci_state_pdsch_s_::max_num_active_tci_per_bwp_e_"); + static const char* options[] = {"ms2", "ms3", "ms4", "ms5", "ms6", "ms8", "ms10", "ms20", + "ms30", "ms40", "ms50", "ms60", "ms80", "ms100", "ms200", "ms300", + "ms500", "ms750", "ms1280", "ms1920", "ms2560", "spare10", "spare9", "spare8", + "spare7", "spare6", "spare5", "spare4", "spare3", "spare2", "spare1"}; + return convert_enum_idx(options, 31, value, "serving_cell_cfg_s::bwp_inactivity_timer_e_"); } - -std::string mimo_params_per_band_s::pusch_trans_coherence_opts::to_string() const +uint16_t serving_cell_cfg_s::bwp_inactivity_timer_opts::to_number() const { - static const char* options[] = {"nonCoherent", "partialCoherent", "fullCoherent"}; - return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::pusch_trans_coherence_e_"); + static const uint16_t options[] = {2, 3, 4, 5, 6, 8, 10, 20, 30, 40, 50, + 60, 80, 100, 200, 300, 500, 750, 1280, 1920, 2560}; + return map_enum_number(options, 21, value, "serving_cell_cfg_s::bwp_inactivity_timer_e_"); } -std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_opts::to_string() const +std::string serving_cell_cfg_s::scell_deactivation_timer_opts::to_string() const { - static const char* options[] = {"n4", "n7", "n14"}; - return convert_enum_idx( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_e_"); + static const char* options[] = {"ms20", + "ms40", + "ms80", + "ms160", + "ms200", + "ms240", + "ms320", + "ms400", + "ms480", + "ms520", + "ms640", + "ms720", + "ms840", + "ms1280", + "spare2", + "spare1"}; + return convert_enum_idx(options, 16, value, "serving_cell_cfg_s::scell_deactivation_timer_e_"); } -uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_opts::to_number() const +uint16_t serving_cell_cfg_s::scell_deactivation_timer_opts::to_number() const { - static const uint8_t options[] = {4, 7, 14}; - return map_enum_number( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus15k_hz_e_"); + static const uint16_t options[] = {20, 40, 80, 160, 200, 240, 320, 400, 480, 520, 640, 720, 840, 1280}; + return map_enum_number(options, 14, value, "serving_cell_cfg_s::scell_deactivation_timer_e_"); } -std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_opts::to_string() const -{ - static const char* options[] = {"n4", "n7", "n14"}; - return convert_enum_idx( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_e_"); -} -uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_opts::to_number() const +std::string serving_cell_cfg_s::pathloss_ref_linking_opts::to_string() const { - static const uint8_t options[] = {4, 7, 14}; - return map_enum_number( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus30k_hz_e_"); + static const char* options[] = {"spCell", "sCell"}; + return convert_enum_idx(options, 2, value, "serving_cell_cfg_s::pathloss_ref_linking_e_"); } -std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_opts::to_string() const -{ - static const char* options[] = {"n4", "n7", "n14"}; - return convert_enum_idx( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_e_"); -} -uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_opts::to_number() const +// TAG-Config ::= SEQUENCE +SRSASN_CODE tag_cfg_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {4, 7, 14}; - return map_enum_number( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus60k_hz_e_"); -} + HANDLE_CODE(bref.pack(tag_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(tag_to_add_mod_list_present, 1)); -std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_opts::to_string() const -{ - static const char* options[] = {"n4", "n7", "n14"}; - return convert_enum_idx( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_e_"); -} -uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_opts::to_number() const -{ - static const uint8_t options[] = {4, 7, 14}; - return map_enum_number( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus120k_hz_e_"); -} + if (tag_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, tag_to_release_list, 1, 4, integer_packer(0, 3))); + } + if (tag_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, tag_to_add_mod_list, 1, 4)); + } -std::string mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_opts::to_string() const -{ - static const char* options[] = {"n4", "n7", "n14"}; - return convert_enum_idx( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_e_"); + return SRSASN_SUCCESS; } -uint8_t mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_opts::to_number() const +SRSASN_CODE tag_cfg_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {4, 7, 14}; - return map_enum_number( - options, 3, value, "mimo_params_per_band_s::max_num_rx_tx_beam_switch_dl_s_::scs_minus240k_hz_e_"); -} + HANDLE_CODE(bref.unpack(tag_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(tag_to_add_mod_list_present, 1)); -std::string mimo_params_per_band_s::max_num_non_group_beam_report_opts::to_string() const -{ - static const char* options[] = {"n1", "n2", "n4"}; - return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::max_num_non_group_beam_report_e_"); -} -uint8_t mimo_params_per_band_s::max_num_non_group_beam_report_opts::to_number() const -{ - static const uint8_t options[] = {1, 2, 4}; - return map_enum_number(options, 3, value, "mimo_params_per_band_s::max_num_non_group_beam_report_e_"); -} + if (tag_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(tag_to_release_list, bref, 1, 4, integer_packer(0, 3))); + } + if (tag_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(tag_to_add_mod_list, bref, 1, 4)); + } -std::string mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_opts::to_string() const -{ - static const char* options[] = {"n2", "n4", "n8", "n16"}; - return convert_enum_idx( - options, 4, value, "mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_e_"); + return SRSASN_SUCCESS; } -uint8_t mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_opts::to_number() const +void tag_cfg_s::to_json(json_writer& j) const { - static const uint8_t options[] = {2, 4, 8, 16}; - return map_enum_number( - options, 4, value, "mimo_params_per_band_s::ul_beam_management_s_::max_num_srs_res_per_set_bm_e_"); + j.start_obj(); + if (tag_to_release_list_present) { + j.start_array("tag-ToReleaseList"); + for (const auto& e1 : tag_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (tag_to_add_mod_list_present) { + j.start_array("tag-ToAddModList"); + for (const auto& e1 : tag_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + j.end_obj(); } -std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_opts::to_string() const -{ - static const char* options[] = {"sym2", "sym4", "sym8"}; - return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_e_"); -} -uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_opts::to_number() const +// MAC-CellGroupConfig ::= SEQUENCE +SRSASN_CODE mac_cell_group_cfg_s::pack(bit_ref& bref) const { - static const uint8_t options[] = {2, 4, 8}; - return map_enum_number(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus15k_hz_e_"); -} + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(drx_cfg_present, 1)); + HANDLE_CODE(bref.pack(sched_request_cfg_present, 1)); + HANDLE_CODE(bref.pack(bsr_cfg_present, 1)); + HANDLE_CODE(bref.pack(tag_cfg_present, 1)); + HANDLE_CODE(bref.pack(phr_cfg_present, 1)); -std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_opts::to_string() const -{ - static const char* options[] = {"sym4", "sym8", "sym14", "sym28"}; - return convert_enum_idx(options, 4, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_e_"); -} -uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_opts::to_number() const -{ - static const uint8_t options[] = {4, 8, 14, 28}; - return map_enum_number(options, 4, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus30k_hz_e_"); -} + if (drx_cfg_present) { + HANDLE_CODE(drx_cfg.pack(bref)); + } + if (sched_request_cfg_present) { + HANDLE_CODE(sched_request_cfg.pack(bref)); + } + if (bsr_cfg_present) { + HANDLE_CODE(bsr_cfg.pack(bref)); + } + if (tag_cfg_present) { + HANDLE_CODE(tag_cfg.pack(bref)); + } + if (phr_cfg_present) { + HANDLE_CODE(phr_cfg.pack(bref)); + } + HANDLE_CODE(bref.pack(skip_ul_tx_dynamic, 1)); -std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_opts::to_string() const -{ - static const char* options[] = {"sym8", "sym14", "sym28"}; - return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_e_"); -} -uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_opts::to_number() const -{ - static const uint8_t options[] = {8, 14, 28}; - return map_enum_number(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus60k_hz_e_"); -} + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= csi_mask_present; + group_flags[0] |= data_inactivity_timer.is_present(); + group_flags.pack(bref); -std::string mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_opts::to_string() const -{ - static const char* options[] = {"sym14", "sym28", "sym56"}; - return convert_enum_idx(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_e_"); -} -uint8_t mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_opts::to_number() const -{ - static const uint8_t options[] = {14, 28, 56}; - return map_enum_number(options, 3, value, "mimo_params_per_band_s::beam_report_timing_s_::scs_minus120k_hz_e_"); -} + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); -std::string mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_opts::to_string() const -{ - static const char* options[] = {"sym14", "sym28", "sym48", "sym224", "sym336"}; - return convert_enum_idx(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_e_"); + HANDLE_CODE(bref.pack(csi_mask_present, 1)); + HANDLE_CODE(bref.pack(data_inactivity_timer.is_present(), 1)); + if (csi_mask_present) { + HANDLE_CODE(bref.pack(csi_mask, 1)); + } + if (data_inactivity_timer.is_present()) { + HANDLE_CODE(data_inactivity_timer->pack(bref)); + } + } + } + return SRSASN_SUCCESS; } -uint16_t mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_opts::to_number() const +SRSASN_CODE mac_cell_group_cfg_s::unpack(cbit_ref& bref) { - static const uint16_t options[] = {14, 28, 48, 224, 336}; - return map_enum_number(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus60k_hz_e_"); -} + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(drx_cfg_present, 1)); + HANDLE_CODE(bref.unpack(sched_request_cfg_present, 1)); + HANDLE_CODE(bref.unpack(bsr_cfg_present, 1)); + HANDLE_CODE(bref.unpack(tag_cfg_present, 1)); + HANDLE_CODE(bref.unpack(phr_cfg_present, 1)); -std::string mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_opts::to_string() const -{ - static const char* options[] = {"sym14", "sym28", "sym48", "sym224", "sym336"}; - return convert_enum_idx(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_e_"); + if (drx_cfg_present) { + HANDLE_CODE(drx_cfg.unpack(bref)); + } + if (sched_request_cfg_present) { + HANDLE_CODE(sched_request_cfg.unpack(bref)); + } + if (bsr_cfg_present) { + HANDLE_CODE(bsr_cfg.unpack(bref)); + } + if (tag_cfg_present) { + HANDLE_CODE(tag_cfg.unpack(bref)); + } + if (phr_cfg_present) { + HANDLE_CODE(phr_cfg.unpack(bref)); + } + HANDLE_CODE(bref.unpack(skip_ul_tx_dynamic, 1)); + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(csi_mask_present, 1)); + bool data_inactivity_timer_present; + HANDLE_CODE(bref.unpack(data_inactivity_timer_present, 1)); + data_inactivity_timer.set_present(data_inactivity_timer_present); + if (csi_mask_present) { + HANDLE_CODE(bref.unpack(csi_mask, 1)); + } + if (data_inactivity_timer.is_present()) { + HANDLE_CODE(data_inactivity_timer->unpack(bref)); + } + } + } + return SRSASN_SUCCESS; } -uint16_t mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_opts::to_number() const +void mac_cell_group_cfg_s::to_json(json_writer& j) const { - static const uint16_t options[] = {14, 28, 48, 224, 336}; - return map_enum_number(options, 5, value, "mimo_params_per_band_s::beam_switch_timing_s_::scs_minus120k_hz_e_"); + j.start_obj(); + if (drx_cfg_present) { + j.write_fieldname("drx-Config"); + drx_cfg.to_json(j); + } + if (sched_request_cfg_present) { + j.write_fieldname("schedulingRequestConfig"); + sched_request_cfg.to_json(j); + } + if (bsr_cfg_present) { + j.write_fieldname("bsr-Config"); + bsr_cfg.to_json(j); + } + if (tag_cfg_present) { + j.write_fieldname("tag-Config"); + tag_cfg.to_json(j); + } + if (phr_cfg_present) { + j.write_fieldname("phr-Config"); + phr_cfg.to_json(j); + } + j.write_bool("skipUplinkTxDynamic", skip_ul_tx_dynamic); + if (ext) { + if (csi_mask_present) { + j.write_bool("csi-Mask", csi_mask); + } + if (data_inactivity_timer.is_present()) { + j.write_fieldname("dataInactivityTimer"); + data_inactivity_timer->to_json(j); + } + } + j.end_obj(); } -// BandNR ::= SEQUENCE -SRSASN_CODE band_nr_s::pack(bit_ref& bref) const +// PhysicalCellGroupConfig ::= SEQUENCE +SRSASN_CODE phys_cell_group_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); - HANDLE_CODE(bref.pack(modified_mpr_behaviour_present, 1)); - HANDLE_CODE(bref.pack(mimo_params_per_band_present, 1)); - HANDLE_CODE(bref.pack(extended_cp_present, 1)); - HANDLE_CODE(bref.pack(multiple_tci_present, 1)); - HANDLE_CODE(bref.pack(bwp_without_restrict_present, 1)); - HANDLE_CODE(bref.pack(bwp_same_numerology_present, 1)); - HANDLE_CODE(bref.pack(bwp_diff_numerology_present, 1)); - HANDLE_CODE(bref.pack(cross_carrier_sched_same_scs_present, 1)); - HANDLE_CODE(bref.pack(pdsch_minus256_qam_fr2_present, 1)); - HANDLE_CODE(bref.pack(pusch_minus256_qam_present, 1)); - HANDLE_CODE(bref.pack(ue_pwr_class_present, 1)); - HANDLE_CODE(bref.pack(rate_matching_lte_crs_present, 1)); - HANDLE_CODE(bref.pack(ch_bws_dl_v1530_present, 1)); - HANDLE_CODE(bref.pack(ch_bws_ul_v1530_present, 1)); + HANDLE_CODE(bref.pack(harq_ack_spatial_bundling_pucch_present, 1)); + HANDLE_CODE(bref.pack(harq_ack_spatial_bundling_pusch_present, 1)); + HANDLE_CODE(bref.pack(p_nr_fr1_present, 1)); + HANDLE_CODE(bref.pack(tpc_srs_rnti_present, 1)); + HANDLE_CODE(bref.pack(tpc_pucch_rnti_present, 1)); + HANDLE_CODE(bref.pack(tpc_pusch_rnti_present, 1)); + HANDLE_CODE(bref.pack(sp_csi_rnti_present, 1)); + HANDLE_CODE(bref.pack(cs_rnti_present, 1)); - HANDLE_CODE(pack_integer(bref, band_nr, (uint16_t)1u, (uint16_t)1024u)); - if (modified_mpr_behaviour_present) { - HANDLE_CODE(modified_mpr_behaviour.pack(bref)); + if (p_nr_fr1_present) { + HANDLE_CODE(pack_integer(bref, p_nr_fr1, (int8_t)-30, (int8_t)33)); } - if (mimo_params_per_band_present) { - HANDLE_CODE(mimo_params_per_band.pack(bref)); + HANDLE_CODE(pdsch_harq_ack_codebook.pack(bref)); + if (tpc_srs_rnti_present) { + HANDLE_CODE(pack_integer(bref, tpc_srs_rnti, (uint32_t)0u, (uint32_t)65535u)); } - if (bwp_same_numerology_present) { - HANDLE_CODE(bwp_same_numerology.pack(bref)); + if (tpc_pucch_rnti_present) { + HANDLE_CODE(pack_integer(bref, tpc_pucch_rnti, (uint32_t)0u, (uint32_t)65535u)); } - if (ue_pwr_class_present) { - HANDLE_CODE(ue_pwr_class.pack(bref)); + if (tpc_pusch_rnti_present) { + HANDLE_CODE(pack_integer(bref, tpc_pusch_rnti, (uint32_t)0u, (uint32_t)65535u)); } - if (ch_bws_dl_v1530_present) { - HANDLE_CODE(ch_bws_dl_v1530.pack(bref)); + if (sp_csi_rnti_present) { + HANDLE_CODE(pack_integer(bref, sp_csi_rnti, (uint32_t)0u, (uint32_t)65535u)); } - if (ch_bws_ul_v1530_present) { - HANDLE_CODE(ch_bws_ul_v1530.pack(bref)); + if (cs_rnti_present) { + HANDLE_CODE(cs_rnti.pack(bref)); } if (ext) { ext_groups_packer_guard group_flags; - group_flags[0] |= max_ul_duty_cycle_pc2_fr1_present; - group_flags[1] |= pucch_spatial_rel_info_mac_ce_present; - group_flags[1] |= pwr_boosting_pi2_bpsk_present; + group_flags[0] |= mcs_c_rnti_present; + group_flags[0] |= p_ue_fr1_present; + group_flags[1] |= xscale_present; + group_flags[2] |= pdcch_blind_detection.is_present(); group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(max_ul_duty_cycle_pc2_fr1_present, 1)); - if (max_ul_duty_cycle_pc2_fr1_present) { - HANDLE_CODE(max_ul_duty_cycle_pc2_fr1.pack(bref)); + HANDLE_CODE(bref.pack(mcs_c_rnti_present, 1)); + HANDLE_CODE(bref.pack(p_ue_fr1_present, 1)); + if (mcs_c_rnti_present) { + HANDLE_CODE(pack_integer(bref, mcs_c_rnti, (uint32_t)0u, (uint32_t)65535u)); + } + if (p_ue_fr1_present) { + HANDLE_CODE(pack_integer(bref, p_ue_fr1, (int8_t)-30, (int8_t)33)); } } if (group_flags[1]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(pucch_spatial_rel_info_mac_ce_present, 1)); - HANDLE_CODE(bref.pack(pwr_boosting_pi2_bpsk_present, 1)); + HANDLE_CODE(bref.pack(xscale_present, 1)); + if (xscale_present) { + HANDLE_CODE(xscale.pack(bref)); + } + } + if (group_flags[2]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(pdcch_blind_detection.is_present(), 1)); + if (pdcch_blind_detection.is_present()) { + HANDLE_CODE(pdcch_blind_detection->pack(bref)); + } } } return SRSASN_SUCCESS; } -SRSASN_CODE band_nr_s::unpack(cbit_ref& bref) +SRSASN_CODE phys_cell_group_cfg_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(modified_mpr_behaviour_present, 1)); - HANDLE_CODE(bref.unpack(mimo_params_per_band_present, 1)); - HANDLE_CODE(bref.unpack(extended_cp_present, 1)); - HANDLE_CODE(bref.unpack(multiple_tci_present, 1)); - HANDLE_CODE(bref.unpack(bwp_without_restrict_present, 1)); - HANDLE_CODE(bref.unpack(bwp_same_numerology_present, 1)); - HANDLE_CODE(bref.unpack(bwp_diff_numerology_present, 1)); - HANDLE_CODE(bref.unpack(cross_carrier_sched_same_scs_present, 1)); - HANDLE_CODE(bref.unpack(pdsch_minus256_qam_fr2_present, 1)); - HANDLE_CODE(bref.unpack(pusch_minus256_qam_present, 1)); - HANDLE_CODE(bref.unpack(ue_pwr_class_present, 1)); - HANDLE_CODE(bref.unpack(rate_matching_lte_crs_present, 1)); - HANDLE_CODE(bref.unpack(ch_bws_dl_v1530_present, 1)); - HANDLE_CODE(bref.unpack(ch_bws_ul_v1530_present, 1)); + HANDLE_CODE(bref.unpack(harq_ack_spatial_bundling_pucch_present, 1)); + HANDLE_CODE(bref.unpack(harq_ack_spatial_bundling_pusch_present, 1)); + HANDLE_CODE(bref.unpack(p_nr_fr1_present, 1)); + HANDLE_CODE(bref.unpack(tpc_srs_rnti_present, 1)); + HANDLE_CODE(bref.unpack(tpc_pucch_rnti_present, 1)); + HANDLE_CODE(bref.unpack(tpc_pusch_rnti_present, 1)); + HANDLE_CODE(bref.unpack(sp_csi_rnti_present, 1)); + HANDLE_CODE(bref.unpack(cs_rnti_present, 1)); - HANDLE_CODE(unpack_integer(band_nr, bref, (uint16_t)1u, (uint16_t)1024u)); - if (modified_mpr_behaviour_present) { - HANDLE_CODE(modified_mpr_behaviour.unpack(bref)); + if (p_nr_fr1_present) { + HANDLE_CODE(unpack_integer(p_nr_fr1, bref, (int8_t)-30, (int8_t)33)); } - if (mimo_params_per_band_present) { - HANDLE_CODE(mimo_params_per_band.unpack(bref)); + HANDLE_CODE(pdsch_harq_ack_codebook.unpack(bref)); + if (tpc_srs_rnti_present) { + HANDLE_CODE(unpack_integer(tpc_srs_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); } - if (bwp_same_numerology_present) { - HANDLE_CODE(bwp_same_numerology.unpack(bref)); + if (tpc_pucch_rnti_present) { + HANDLE_CODE(unpack_integer(tpc_pucch_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); } - if (ue_pwr_class_present) { - HANDLE_CODE(ue_pwr_class.unpack(bref)); + if (tpc_pusch_rnti_present) { + HANDLE_CODE(unpack_integer(tpc_pusch_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); } - if (ch_bws_dl_v1530_present) { - HANDLE_CODE(ch_bws_dl_v1530.unpack(bref)); + if (sp_csi_rnti_present) { + HANDLE_CODE(unpack_integer(sp_csi_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); } - if (ch_bws_ul_v1530_present) { - HANDLE_CODE(ch_bws_ul_v1530.unpack(bref)); + if (cs_rnti_present) { + HANDLE_CODE(cs_rnti.unpack(bref)); } if (ext) { - ext_groups_unpacker_guard group_flags(2); + ext_groups_unpacker_guard group_flags(3); group_flags.unpack(bref); if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.unpack(max_ul_duty_cycle_pc2_fr1_present, 1)); - if (max_ul_duty_cycle_pc2_fr1_present) { - HANDLE_CODE(max_ul_duty_cycle_pc2_fr1.unpack(bref)); + HANDLE_CODE(bref.unpack(mcs_c_rnti_present, 1)); + HANDLE_CODE(bref.unpack(p_ue_fr1_present, 1)); + if (mcs_c_rnti_present) { + HANDLE_CODE(unpack_integer(mcs_c_rnti, bref, (uint32_t)0u, (uint32_t)65535u)); + } + if (p_ue_fr1_present) { + HANDLE_CODE(unpack_integer(p_ue_fr1, bref, (int8_t)-30, (int8_t)33)); } } if (group_flags[1]) { varlength_field_unpack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.unpack(pucch_spatial_rel_info_mac_ce_present, 1)); - HANDLE_CODE(bref.unpack(pwr_boosting_pi2_bpsk_present, 1)); + HANDLE_CODE(bref.unpack(xscale_present, 1)); + if (xscale_present) { + HANDLE_CODE(xscale.unpack(bref)); + } + } + if (group_flags[2]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool pdcch_blind_detection_present; + HANDLE_CODE(bref.unpack(pdcch_blind_detection_present, 1)); + pdcch_blind_detection.set_present(pdcch_blind_detection_present); + if (pdcch_blind_detection.is_present()) { + HANDLE_CODE(pdcch_blind_detection->unpack(bref)); + } } } return SRSASN_SUCCESS; } -void band_nr_s::to_json(json_writer& j) const +void phys_cell_group_cfg_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("bandNR", band_nr); - if (modified_mpr_behaviour_present) { - j.write_str("modifiedMPR-Behaviour", modified_mpr_behaviour.to_string()); - } - if (mimo_params_per_band_present) { - j.write_fieldname("mimo-ParametersPerBand"); - mimo_params_per_band.to_json(j); - } - if (extended_cp_present) { - j.write_str("extendedCP", "supported"); - } - if (multiple_tci_present) { - j.write_str("multipleTCI", "supported"); - } - if (bwp_without_restrict_present) { - j.write_str("bwp-WithoutRestriction", "supported"); - } - if (bwp_same_numerology_present) { - j.write_str("bwp-SameNumerology", bwp_same_numerology.to_string()); - } - if (bwp_diff_numerology_present) { - j.write_str("bwp-DiffNumerology", "upto4"); + if (harq_ack_spatial_bundling_pucch_present) { + j.write_str("harq-ACK-SpatialBundlingPUCCH", "true"); } - if (cross_carrier_sched_same_scs_present) { - j.write_str("crossCarrierScheduling-SameSCS", "supported"); + if (harq_ack_spatial_bundling_pusch_present) { + j.write_str("harq-ACK-SpatialBundlingPUSCH", "true"); } - if (pdsch_minus256_qam_fr2_present) { - j.write_str("pdsch-256QAM-FR2", "supported"); + if (p_nr_fr1_present) { + j.write_int("p-NR-FR1", p_nr_fr1); } - if (pusch_minus256_qam_present) { - j.write_str("pusch-256QAM", "supported"); + j.write_str("pdsch-HARQ-ACK-Codebook", pdsch_harq_ack_codebook.to_string()); + if (tpc_srs_rnti_present) { + j.write_int("tpc-SRS-RNTI", tpc_srs_rnti); } - if (ue_pwr_class_present) { - j.write_str("ue-PowerClass", ue_pwr_class.to_string()); + if (tpc_pucch_rnti_present) { + j.write_int("tpc-PUCCH-RNTI", tpc_pucch_rnti); } - if (rate_matching_lte_crs_present) { - j.write_str("rateMatchingLTE-CRS", "supported"); + if (tpc_pusch_rnti_present) { + j.write_int("tpc-PUSCH-RNTI", tpc_pusch_rnti); } - if (ch_bws_dl_v1530_present) { - j.write_fieldname("channelBWs-DL-v1530"); - ch_bws_dl_v1530.to_json(j); + if (sp_csi_rnti_present) { + j.write_int("sp-CSI-RNTI", sp_csi_rnti); } - if (ch_bws_ul_v1530_present) { - j.write_fieldname("channelBWs-UL-v1530"); - ch_bws_ul_v1530.to_json(j); + if (cs_rnti_present) { + j.write_fieldname("cs-RNTI"); + cs_rnti.to_json(j); } if (ext) { - if (max_ul_duty_cycle_pc2_fr1_present) { - j.write_str("maxUplinkDutyCycle-PC2-FR1", max_ul_duty_cycle_pc2_fr1.to_string()); + if (mcs_c_rnti_present) { + j.write_int("mcs-C-RNTI", mcs_c_rnti); } - if (pucch_spatial_rel_info_mac_ce_present) { - j.write_str("pucch-SpatialRelInfoMAC-CE", "supported"); + if (p_ue_fr1_present) { + j.write_int("p-UE-FR1", p_ue_fr1); } - if (pwr_boosting_pi2_bpsk_present) { - j.write_str("powerBoosting-pi2BPSK", "supported"); + if (xscale_present) { + j.write_str("xScale", xscale.to_string()); + } + if (pdcch_blind_detection.is_present()) { + j.write_fieldname("pdcch-BlindDetection"); + pdcch_blind_detection->to_json(j); } } j.end_obj(); } -std::string band_nr_s::bwp_same_numerology_opts::to_string() const -{ - static const char* options[] = {"upto2", "upto4"}; - return convert_enum_idx(options, 2, value, "band_nr_s::bwp_same_numerology_e_"); -} -uint8_t band_nr_s::bwp_same_numerology_opts::to_number() const +std::string phys_cell_group_cfg_s::pdsch_harq_ack_codebook_opts::to_string() const { - static const uint8_t options[] = {2, 4}; - return map_enum_number(options, 2, value, "band_nr_s::bwp_same_numerology_e_"); + static const char* options[] = {"semiStatic", "dynamic"}; + return convert_enum_idx(options, 2, value, "phys_cell_group_cfg_s::pdsch_harq_ack_codebook_e_"); } -std::string band_nr_s::ue_pwr_class_opts::to_string() const +std::string phys_cell_group_cfg_s::xscale_opts::to_string() const { - static const char* options[] = {"pc1", "pc2", "pc3", "pc4"}; - return convert_enum_idx(options, 4, value, "band_nr_s::ue_pwr_class_e_"); + static const char* options[] = {"dB0", "dB6", "spare2", "spare1"}; + return convert_enum_idx(options, 4, value, "phys_cell_group_cfg_s::xscale_e_"); } -uint8_t band_nr_s::ue_pwr_class_opts::to_number() const +uint8_t phys_cell_group_cfg_s::xscale_opts::to_number() const { - static const uint8_t options[] = {1, 2, 3, 4}; - return map_enum_number(options, 4, value, "band_nr_s::ue_pwr_class_e_"); + static const uint8_t options[] = {0, 6}; + return map_enum_number(options, 2, value, "phys_cell_group_cfg_s::xscale_e_"); } -void band_nr_s::ch_bws_dl_v1530_c_::destroy_() +// RLC-BearerConfig ::= SEQUENCE +SRSASN_CODE rlc_bearer_cfg_s::pack(bit_ref& bref) const { - switch (type_) { - case types::fr1: - c.destroy(); - break; - case types::fr2: - c.destroy(); - break; - default: - break; + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(served_radio_bearer_present, 1)); + HANDLE_CODE(bref.pack(reestablish_rlc_present, 1)); + HANDLE_CODE(bref.pack(rlc_cfg_present, 1)); + HANDLE_CODE(bref.pack(mac_lc_ch_cfg_present, 1)); + + HANDLE_CODE(pack_integer(bref, lc_ch_id, (uint8_t)1u, (uint8_t)32u)); + if (served_radio_bearer_present) { + HANDLE_CODE(served_radio_bearer.pack(bref)); } -} -void band_nr_s::ch_bws_dl_v1530_c_::set(types::options e) -{ - destroy_(); - type_ = e; - switch (type_) { - case types::fr1: - c.init(); - break; - case types::fr2: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1530_c_"); + if (rlc_cfg_present) { + HANDLE_CODE(rlc_cfg.pack(bref)); } -} -band_nr_s::ch_bws_dl_v1530_c_::ch_bws_dl_v1530_c_(const band_nr_s::ch_bws_dl_v1530_c_& other) -{ - type_ = other.type(); - switch (type_) { - case types::fr1: - c.init(other.c.get()); - break; - case types::fr2: - c.init(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1530_c_"); + if (mac_lc_ch_cfg_present) { + HANDLE_CODE(mac_lc_ch_cfg.pack(bref)); } + + return SRSASN_SUCCESS; } -band_nr_s::ch_bws_dl_v1530_c_& band_nr_s::ch_bws_dl_v1530_c_::operator=(const band_nr_s::ch_bws_dl_v1530_c_& other) +SRSASN_CODE rlc_bearer_cfg_s::unpack(cbit_ref& bref) { - if (this == &other) { - return *this; + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(served_radio_bearer_present, 1)); + HANDLE_CODE(bref.unpack(reestablish_rlc_present, 1)); + HANDLE_CODE(bref.unpack(rlc_cfg_present, 1)); + HANDLE_CODE(bref.unpack(mac_lc_ch_cfg_present, 1)); + + HANDLE_CODE(unpack_integer(lc_ch_id, bref, (uint8_t)1u, (uint8_t)32u)); + if (served_radio_bearer_present) { + HANDLE_CODE(served_radio_bearer.unpack(bref)); } - set(other.type()); - switch (type_) { - case types::fr1: - c.set(other.c.get()); - break; - case types::fr2: - c.set(other.c.get()); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1530_c_"); + if (rlc_cfg_present) { + HANDLE_CODE(rlc_cfg.unpack(bref)); + } + if (mac_lc_ch_cfg_present) { + HANDLE_CODE(mac_lc_ch_cfg.unpack(bref)); } - return *this; + return SRSASN_SUCCESS; } -void band_nr_s::ch_bws_dl_v1530_c_::to_json(json_writer& j) const +void rlc_bearer_cfg_s::to_json(json_writer& j) const { j.start_obj(); - switch (type_) { - case types::fr1: - j.write_fieldname("fr1"); - j.start_obj(); - if (c.get().scs_minus15k_hz_present) { - j.write_str("scs-15kHz", c.get().scs_minus15k_hz.to_string()); - } - if (c.get().scs_minus30k_hz_present) { - j.write_str("scs-30kHz", c.get().scs_minus30k_hz.to_string()); - } - if (c.get().scs_minus60k_hz_present) { - j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); - } - j.end_obj(); - break; - case types::fr2: - j.write_fieldname("fr2"); - j.start_obj(); - if (c.get().scs_minus60k_hz_present) { - j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); - } - if (c.get().scs_minus120k_hz_present) { - j.write_str("scs-120kHz", c.get().scs_minus120k_hz.to_string()); - } - j.end_obj(); - break; - default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1530_c_"); + j.write_int("logicalChannelIdentity", lc_ch_id); + if (served_radio_bearer_present) { + j.write_fieldname("servedRadioBearer"); + served_radio_bearer.to_json(j); } - j.end_obj(); -} -SRSASN_CODE band_nr_s::ch_bws_dl_v1530_c_::pack(bit_ref& bref) const -{ - type_.pack(bref); - switch (type_) { - case types::fr1: - HANDLE_CODE(bref.pack(c.get().scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.pack(c.get().scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); - if (c.get().scs_minus15k_hz_present) { - HANDLE_CODE(c.get().scs_minus15k_hz.pack(bref)); - } - if (c.get().scs_minus30k_hz_present) { - HANDLE_CODE(c.get().scs_minus30k_hz.pack(bref)); - } - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); - } - break; - case types::fr2: - HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.pack(c.get().scs_minus120k_hz_present, 1)); - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); - } - if (c.get().scs_minus120k_hz_present) { - HANDLE_CODE(c.get().scs_minus120k_hz.pack(bref)); - } - break; - default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1530_c_"); - return SRSASN_ERROR_ENCODE_FAIL; + if (reestablish_rlc_present) { + j.write_str("reestablishRLC", "true"); } - return SRSASN_SUCCESS; -} -SRSASN_CODE band_nr_s::ch_bws_dl_v1530_c_::unpack(cbit_ref& bref) -{ - types e; - e.unpack(bref); - set(e); - switch (type_) { - case types::fr1: - HANDLE_CODE(bref.unpack(c.get().scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.unpack(c.get().scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); - if (c.get().scs_minus15k_hz_present) { - HANDLE_CODE(c.get().scs_minus15k_hz.unpack(bref)); - } - if (c.get().scs_minus30k_hz_present) { - HANDLE_CODE(c.get().scs_minus30k_hz.unpack(bref)); - } - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); - } - break; - case types::fr2: - HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.unpack(c.get().scs_minus120k_hz_present, 1)); - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); - } - if (c.get().scs_minus120k_hz_present) { - HANDLE_CODE(c.get().scs_minus120k_hz.unpack(bref)); - } - break; - default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_dl_v1530_c_"); - return SRSASN_ERROR_DECODE_FAIL; + if (rlc_cfg_present) { + j.write_fieldname("rlc-Config"); + rlc_cfg.to_json(j); } - return SRSASN_SUCCESS; -} - -std::string band_nr_s::ch_bws_dl_v1530_c_::types_opts::to_string() const -{ - static const char* options[] = {"fr1", "fr2"}; - return convert_enum_idx(options, 2, value, "band_nr_s::ch_bws_dl_v1530_c_::types"); -} -uint8_t band_nr_s::ch_bws_dl_v1530_c_::types_opts::to_number() const -{ - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "band_nr_s::ch_bws_dl_v1530_c_::types"); -} - -void band_nr_s::ch_bws_ul_v1530_c_::destroy_() -{ - switch (type_) { - case types::fr1: - c.destroy(); - break; - case types::fr2: - c.destroy(); - break; - default: - break; + if (mac_lc_ch_cfg_present) { + j.write_fieldname("mac-LogicalChannelConfig"); + mac_lc_ch_cfg.to_json(j); } + j.end_obj(); } -void band_nr_s::ch_bws_ul_v1530_c_::set(types::options e) + +void rlc_bearer_cfg_s::served_radio_bearer_c_::destroy_() {} +void rlc_bearer_cfg_s::served_radio_bearer_c_::set(types::options e) { destroy_(); type_ = e; - switch (type_) { - case types::fr1: - c.init(); - break; - case types::fr2: - c.init(); - break; - case types::nulltype: - break; - default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1530_c_"); - } } -band_nr_s::ch_bws_ul_v1530_c_::ch_bws_ul_v1530_c_(const band_nr_s::ch_bws_ul_v1530_c_& other) +rlc_bearer_cfg_s::served_radio_bearer_c_::served_radio_bearer_c_(const rlc_bearer_cfg_s::served_radio_bearer_c_& other) { type_ = other.type(); switch (type_) { - case types::fr1: - c.init(other.c.get()); + case types::srb_id: + c.init(other.c.get()); break; - case types::fr2: - c.init(other.c.get()); + case types::drb_id: + c.init(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1530_c_"); + log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); } } -band_nr_s::ch_bws_ul_v1530_c_& band_nr_s::ch_bws_ul_v1530_c_::operator=(const band_nr_s::ch_bws_ul_v1530_c_& other) +rlc_bearer_cfg_s::served_radio_bearer_c_& +rlc_bearer_cfg_s::served_radio_bearer_c_::operator=(const rlc_bearer_cfg_s::served_radio_bearer_c_& other) { if (this == &other) { return *this; } set(other.type()); switch (type_) { - case types::fr1: - c.set(other.c.get()); + case types::srb_id: + c.set(other.c.get()); break; - case types::fr2: - c.set(other.c.get()); + case types::drb_id: + c.set(other.c.get()); break; case types::nulltype: break; default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1530_c_"); + log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); } return *this; } -void band_nr_s::ch_bws_ul_v1530_c_::to_json(json_writer& j) const +void rlc_bearer_cfg_s::served_radio_bearer_c_::to_json(json_writer& j) const { j.start_obj(); switch (type_) { - case types::fr1: - j.write_fieldname("fr1"); - j.start_obj(); - if (c.get().scs_minus15k_hz_present) { - j.write_str("scs-15kHz", c.get().scs_minus15k_hz.to_string()); - } - if (c.get().scs_minus30k_hz_present) { - j.write_str("scs-30kHz", c.get().scs_minus30k_hz.to_string()); - } - if (c.get().scs_minus60k_hz_present) { - j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); - } - j.end_obj(); + case types::srb_id: + j.write_int("srb-Identity", c.get()); break; - case types::fr2: - j.write_fieldname("fr2"); - j.start_obj(); - if (c.get().scs_minus60k_hz_present) { - j.write_str("scs-60kHz", c.get().scs_minus60k_hz.to_string()); - } - if (c.get().scs_minus120k_hz_present) { - j.write_str("scs-120kHz", c.get().scs_minus120k_hz.to_string()); - } - j.end_obj(); + case types::drb_id: + j.write_int("drb-Identity", c.get()); break; default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1530_c_"); + log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); } j.end_obj(); } -SRSASN_CODE band_nr_s::ch_bws_ul_v1530_c_::pack(bit_ref& bref) const +SRSASN_CODE rlc_bearer_cfg_s::served_radio_bearer_c_::pack(bit_ref& bref) const { type_.pack(bref); switch (type_) { - case types::fr1: - HANDLE_CODE(bref.pack(c.get().scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.pack(c.get().scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); - if (c.get().scs_minus15k_hz_present) { - HANDLE_CODE(c.get().scs_minus15k_hz.pack(bref)); - } - if (c.get().scs_minus30k_hz_present) { - HANDLE_CODE(c.get().scs_minus30k_hz.pack(bref)); - } - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); - } + case types::srb_id: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)3u)); break; - case types::fr2: - HANDLE_CODE(bref.pack(c.get().scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.pack(c.get().scs_minus120k_hz_present, 1)); - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.pack(bref)); - } - if (c.get().scs_minus120k_hz_present) { - HANDLE_CODE(c.get().scs_minus120k_hz.pack(bref)); - } + case types::drb_id: + HANDLE_CODE(pack_integer(bref, c.get(), (uint8_t)1u, (uint8_t)32u)); break; default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1530_c_"); + log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); return SRSASN_ERROR_ENCODE_FAIL; } return SRSASN_SUCCESS; } -SRSASN_CODE band_nr_s::ch_bws_ul_v1530_c_::unpack(cbit_ref& bref) +SRSASN_CODE rlc_bearer_cfg_s::served_radio_bearer_c_::unpack(cbit_ref& bref) { types e; e.unpack(bref); set(e); switch (type_) { - case types::fr1: - HANDLE_CODE(bref.unpack(c.get().scs_minus15k_hz_present, 1)); - HANDLE_CODE(bref.unpack(c.get().scs_minus30k_hz_present, 1)); - HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); - if (c.get().scs_minus15k_hz_present) { - HANDLE_CODE(c.get().scs_minus15k_hz.unpack(bref)); - } - if (c.get().scs_minus30k_hz_present) { - HANDLE_CODE(c.get().scs_minus30k_hz.unpack(bref)); - } - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); - } + case types::srb_id: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)3u)); break; - case types::fr2: - HANDLE_CODE(bref.unpack(c.get().scs_minus60k_hz_present, 1)); - HANDLE_CODE(bref.unpack(c.get().scs_minus120k_hz_present, 1)); - if (c.get().scs_minus60k_hz_present) { - HANDLE_CODE(c.get().scs_minus60k_hz.unpack(bref)); - } - if (c.get().scs_minus120k_hz_present) { - HANDLE_CODE(c.get().scs_minus120k_hz.unpack(bref)); - } + case types::drb_id: + HANDLE_CODE(unpack_integer(c.get(), bref, (uint8_t)1u, (uint8_t)32u)); break; default: - log_invalid_choice_id(type_, "band_nr_s::ch_bws_ul_v1530_c_"); + log_invalid_choice_id(type_, "rlc_bearer_cfg_s::served_radio_bearer_c_"); return SRSASN_ERROR_DECODE_FAIL; } return SRSASN_SUCCESS; } -std::string band_nr_s::ch_bws_ul_v1530_c_::types_opts::to_string() const +std::string rlc_bearer_cfg_s::served_radio_bearer_c_::types_opts::to_string() const { - static const char* options[] = {"fr1", "fr2"}; - return convert_enum_idx(options, 2, value, "band_nr_s::ch_bws_ul_v1530_c_::types"); + static const char* options[] = {"srb-Identity", "drb-Identity"}; + return convert_enum_idx(options, 2, value, "rlc_bearer_cfg_s::served_radio_bearer_c_::types"); +} + +// SCellConfig ::= SEQUENCE +SRSASN_CODE scell_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(scell_cfg_common_present, 1)); + HANDLE_CODE(bref.pack(scell_cfg_ded_present, 1)); + + HANDLE_CODE(pack_integer(bref, scell_idx, (uint8_t)1u, (uint8_t)31u)); + if (scell_cfg_common_present) { + HANDLE_CODE(scell_cfg_common.pack(bref)); + } + if (scell_cfg_ded_present) { + HANDLE_CODE(scell_cfg_ded.pack(bref)); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= smtc.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(smtc.is_present(), 1)); + if (smtc.is_present()) { + HANDLE_CODE(smtc->pack(bref)); + } + } + } + return SRSASN_SUCCESS; } -uint8_t band_nr_s::ch_bws_ul_v1530_c_::types_opts::to_number() const +SRSASN_CODE scell_cfg_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {1, 2}; - return map_enum_number(options, 2, value, "band_nr_s::ch_bws_ul_v1530_c_::types"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(scell_cfg_common_present, 1)); + HANDLE_CODE(bref.unpack(scell_cfg_ded_present, 1)); + + HANDLE_CODE(unpack_integer(scell_idx, bref, (uint8_t)1u, (uint8_t)31u)); + if (scell_cfg_common_present) { + HANDLE_CODE(scell_cfg_common.unpack(bref)); + } + if (scell_cfg_ded_present) { + HANDLE_CODE(scell_cfg_ded.unpack(bref)); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool smtc_present; + HANDLE_CODE(bref.unpack(smtc_present, 1)); + smtc.set_present(smtc_present); + if (smtc.is_present()) { + HANDLE_CODE(smtc->unpack(bref)); + } + } + } + return SRSASN_SUCCESS; +} +void scell_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("sCellIndex", scell_idx); + if (scell_cfg_common_present) { + j.write_fieldname("sCellConfigCommon"); + scell_cfg_common.to_json(j); + } + if (scell_cfg_ded_present) { + j.write_fieldname("sCellConfigDedicated"); + scell_cfg_ded.to_json(j); + } + if (ext) { + if (smtc.is_present()) { + j.write_fieldname("smtc"); + smtc->to_json(j); + } + } + j.end_obj(); } -std::string band_nr_s::max_ul_duty_cycle_pc2_fr1_opts::to_string() const +// SpCellConfig ::= SEQUENCE +SRSASN_CODE sp_cell_cfg_s::pack(bit_ref& bref) const { - static const char* options[] = {"n60", "n70", "n80", "n90", "n100"}; - return convert_enum_idx(options, 5, value, "band_nr_s::max_ul_duty_cycle_pc2_fr1_e_"); + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(serv_cell_idx_present, 1)); + HANDLE_CODE(bref.pack(recfg_with_sync_present, 1)); + HANDLE_CODE(bref.pack(rlf_timers_and_consts_present, 1)); + HANDLE_CODE(bref.pack(rlm_in_sync_out_of_sync_thres_present, 1)); + HANDLE_CODE(bref.pack(sp_cell_cfg_ded_present, 1)); + + if (serv_cell_idx_present) { + HANDLE_CODE(pack_integer(bref, serv_cell_idx, (uint8_t)0u, (uint8_t)31u)); + } + if (recfg_with_sync_present) { + HANDLE_CODE(recfg_with_sync.pack(bref)); + } + if (rlf_timers_and_consts_present) { + HANDLE_CODE(rlf_timers_and_consts.pack(bref)); + } + if (sp_cell_cfg_ded_present) { + HANDLE_CODE(sp_cell_cfg_ded.pack(bref)); + } + + return SRSASN_SUCCESS; } -uint8_t band_nr_s::max_ul_duty_cycle_pc2_fr1_opts::to_number() const +SRSASN_CODE sp_cell_cfg_s::unpack(cbit_ref& bref) { - static const uint8_t options[] = {60, 70, 80, 90, 100}; - return map_enum_number(options, 5, value, "band_nr_s::max_ul_duty_cycle_pc2_fr1_e_"); + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(serv_cell_idx_present, 1)); + HANDLE_CODE(bref.unpack(recfg_with_sync_present, 1)); + HANDLE_CODE(bref.unpack(rlf_timers_and_consts_present, 1)); + HANDLE_CODE(bref.unpack(rlm_in_sync_out_of_sync_thres_present, 1)); + HANDLE_CODE(bref.unpack(sp_cell_cfg_ded_present, 1)); + + if (serv_cell_idx_present) { + HANDLE_CODE(unpack_integer(serv_cell_idx, bref, (uint8_t)0u, (uint8_t)31u)); + } + if (recfg_with_sync_present) { + HANDLE_CODE(recfg_with_sync.unpack(bref)); + } + if (rlf_timers_and_consts_present) { + HANDLE_CODE(rlf_timers_and_consts.unpack(bref)); + } + if (sp_cell_cfg_ded_present) { + HANDLE_CODE(sp_cell_cfg_ded.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void sp_cell_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (serv_cell_idx_present) { + j.write_int("servCellIndex", serv_cell_idx); + } + if (recfg_with_sync_present) { + j.write_fieldname("reconfigurationWithSync"); + recfg_with_sync.to_json(j); + } + if (rlf_timers_and_consts_present) { + j.write_fieldname("rlf-TimersAndConstants"); + rlf_timers_and_consts.to_json(j); + } + if (rlm_in_sync_out_of_sync_thres_present) { + j.write_str("rlmInSyncOutOfSyncThreshold", "n1"); + } + if (sp_cell_cfg_ded_present) { + j.write_fieldname("spCellConfigDedicated"); + sp_cell_cfg_ded.to_json(j); + } + j.end_obj(); +} + +// CellGroupConfig ::= SEQUENCE +SRSASN_CODE cell_group_cfg_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(rlc_bearer_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(rlc_bearer_to_release_list_present, 1)); + HANDLE_CODE(bref.pack(mac_cell_group_cfg_present, 1)); + HANDLE_CODE(bref.pack(phys_cell_group_cfg_present, 1)); + HANDLE_CODE(bref.pack(sp_cell_cfg_present, 1)); + HANDLE_CODE(bref.pack(scell_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.pack(scell_to_release_list_present, 1)); + + HANDLE_CODE(pack_integer(bref, cell_group_id, (uint8_t)0u, (uint8_t)3u)); + if (rlc_bearer_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rlc_bearer_to_add_mod_list, 1, 32)); + } + if (rlc_bearer_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, rlc_bearer_to_release_list, 1, 32, integer_packer(1, 32))); + } + if (mac_cell_group_cfg_present) { + HANDLE_CODE(mac_cell_group_cfg.pack(bref)); + } + if (phys_cell_group_cfg_present) { + HANDLE_CODE(phys_cell_group_cfg.pack(bref)); + } + if (sp_cell_cfg_present) { + HANDLE_CODE(sp_cell_cfg.pack(bref)); + } + if (scell_to_add_mod_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, scell_to_add_mod_list, 1, 31)); + } + if (scell_to_release_list_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, scell_to_release_list, 1, 31, integer_packer(1, 31))); + } + + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= report_ul_tx_direct_current_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(report_ul_tx_direct_current_present, 1)); + } + } + return SRSASN_SUCCESS; +} +SRSASN_CODE cell_group_cfg_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(rlc_bearer_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(rlc_bearer_to_release_list_present, 1)); + HANDLE_CODE(bref.unpack(mac_cell_group_cfg_present, 1)); + HANDLE_CODE(bref.unpack(phys_cell_group_cfg_present, 1)); + HANDLE_CODE(bref.unpack(sp_cell_cfg_present, 1)); + HANDLE_CODE(bref.unpack(scell_to_add_mod_list_present, 1)); + HANDLE_CODE(bref.unpack(scell_to_release_list_present, 1)); + + HANDLE_CODE(unpack_integer(cell_group_id, bref, (uint8_t)0u, (uint8_t)3u)); + if (rlc_bearer_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(rlc_bearer_to_add_mod_list, bref, 1, 32)); + } + if (rlc_bearer_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(rlc_bearer_to_release_list, bref, 1, 32, integer_packer(1, 32))); + } + if (mac_cell_group_cfg_present) { + HANDLE_CODE(mac_cell_group_cfg.unpack(bref)); + } + if (phys_cell_group_cfg_present) { + HANDLE_CODE(phys_cell_group_cfg.unpack(bref)); + } + if (sp_cell_cfg_present) { + HANDLE_CODE(sp_cell_cfg.unpack(bref)); + } + if (scell_to_add_mod_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(scell_to_add_mod_list, bref, 1, 31)); + } + if (scell_to_release_list_present) { + HANDLE_CODE(unpack_dyn_seq_of(scell_to_release_list, bref, 1, 31, integer_packer(1, 31))); + } + + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(report_ul_tx_direct_current_present, 1)); + } + } + return SRSASN_SUCCESS; +} +void cell_group_cfg_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("cellGroupId", cell_group_id); + if (rlc_bearer_to_add_mod_list_present) { + j.start_array("rlc-BearerToAddModList"); + for (const auto& e1 : rlc_bearer_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (rlc_bearer_to_release_list_present) { + j.start_array("rlc-BearerToReleaseList"); + for (const auto& e1 : rlc_bearer_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (mac_cell_group_cfg_present) { + j.write_fieldname("mac-CellGroupConfig"); + mac_cell_group_cfg.to_json(j); + } + if (phys_cell_group_cfg_present) { + j.write_fieldname("physicalCellGroupConfig"); + phys_cell_group_cfg.to_json(j); + } + if (sp_cell_cfg_present) { + j.write_fieldname("spCellConfig"); + sp_cell_cfg.to_json(j); + } + if (scell_to_add_mod_list_present) { + j.start_array("sCellToAddModList"); + for (const auto& e1 : scell_to_add_mod_list) { + e1.to_json(j); + } + j.end_array(); + } + if (scell_to_release_list_present) { + j.start_array("sCellToReleaseList"); + for (const auto& e1 : scell_to_release_list) { + j.write_int(e1); + } + j.end_array(); + } + if (ext) { + if (report_ul_tx_direct_current_present) { + j.write_str("reportUplinkTxDirectCurrent", "true"); + } + } + j.end_obj(); } // EUTRA-ParametersCommon ::= SEQUENCE @@ -45351,6 +48051,17 @@ SRSASN_CODE eutra_params_common_s::pack(bit_ref& bref) const HANDLE_CODE(modified_mpr_behavior_eutra.pack(bref)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= ne_dc_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(ne_dc_present, 1)); + } + } return SRSASN_SUCCESS; } SRSASN_CODE eutra_params_common_s::unpack(cbit_ref& bref) @@ -45365,6 +48076,16 @@ SRSASN_CODE eutra_params_common_s::unpack(cbit_ref& bref) HANDLE_CODE(modified_mpr_behavior_eutra.unpack(bref)); } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(ne_dc_present, 1)); + } + } return SRSASN_SUCCESS; } void eutra_params_common_s::to_json(json_writer& j) const @@ -45382,6 +48103,11 @@ void eutra_params_common_s::to_json(json_writer& j) const if (rs_sinr_meas_eutra_present) { j.write_str("rs-SINR-MeasEUTRA", "supported"); } + if (ext) { + if (ne_dc_present) { + j.write_str("ne-DC", "supported"); + } + } j.end_obj(); } @@ -46613,6 +49339,37 @@ feature_set_dl_v1540_s::pdsch_processing_type2_limited_s_::different_tb_per_slot "feature_set_dl_v1540_s::pdsch_processing_type2_limited_s_::different_tb_per_slot_scs_minus30k_hz_e_"); } +// FeatureSetDownlink-v15a0 ::= SEQUENCE +SRSASN_CODE feature_set_dl_v15a0_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(supported_srs_res_present, 1)); + + if (supported_srs_res_present) { + HANDLE_CODE(supported_srs_res.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE feature_set_dl_v15a0_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(supported_srs_res_present, 1)); + + if (supported_srs_res_present) { + HANDLE_CODE(supported_srs_res.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void feature_set_dl_v15a0_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (supported_srs_res_present) { + j.write_fieldname("supportedSRS-Resources"); + supported_srs_res.to_json(j); + } + j.end_obj(); +} + // ModulationOrder ::= ENUMERATED std::string mod_order_opts::to_string() const { @@ -47333,6 +50090,7 @@ SRSASN_CODE feature_sets_s::pack(bit_ref& bref) const group_flags[0] |= feature_sets_dl_v1540.is_present(); group_flags[0] |= feature_sets_ul_v1540.is_present(); group_flags[0] |= feature_sets_ul_per_cc_v1540.is_present(); + group_flags[1] |= feature_sets_dl_v15a0.is_present(); group_flags.pack(bref); if (group_flags[0]) { @@ -47351,6 +50109,14 @@ SRSASN_CODE feature_sets_s::pack(bit_ref& bref) const HANDLE_CODE(pack_dyn_seq_of(bref, *feature_sets_ul_per_cc_v1540, 1, 1024)); } } + if (group_flags[1]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(feature_sets_dl_v15a0.is_present(), 1)); + if (feature_sets_dl_v15a0.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *feature_sets_dl_v15a0, 1, 1024)); + } + } } return SRSASN_SUCCESS; } @@ -47376,7 +50142,7 @@ SRSASN_CODE feature_sets_s::unpack(cbit_ref& bref) } if (ext) { - ext_groups_unpacker_guard group_flags(1); + ext_groups_unpacker_guard group_flags(2); group_flags.unpack(bref); if (group_flags[0]) { @@ -47401,6 +50167,16 @@ SRSASN_CODE feature_sets_s::unpack(cbit_ref& bref) HANDLE_CODE(unpack_dyn_seq_of(*feature_sets_ul_per_cc_v1540, bref, 1, 1024)); } } + if (group_flags[1]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool feature_sets_dl_v15a0_present; + HANDLE_CODE(bref.unpack(feature_sets_dl_v15a0_present, 1)); + feature_sets_dl_v15a0.set_present(feature_sets_dl_v15a0_present); + if (feature_sets_dl_v15a0.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*feature_sets_dl_v15a0, bref, 1, 1024)); + } + } } return SRSASN_SUCCESS; } @@ -47457,6 +50233,13 @@ void feature_sets_s::to_json(json_writer& j) const } j.end_array(); } + if (feature_sets_dl_v15a0.is_present()) { + j.start_array("featureSetsDownlink-v15a0"); + for (const auto& e1 : *feature_sets_dl_v15a0) { + e1.to_json(j); + } + j.end_array(); + } } j.end_obj(); } @@ -47730,6 +50513,17 @@ SRSASN_CODE ims_params_common_s::pack(bit_ref& bref) const bref.pack(ext, 1); HANDLE_CODE(bref.pack(voice_over_eutra_minus5_gc_present, 1)); + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= voice_over_scg_bearer_eutra_minus5_gc_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(voice_over_scg_bearer_eutra_minus5_gc_present, 1)); + } + } return SRSASN_SUCCESS; } SRSASN_CODE ims_params_common_s::unpack(cbit_ref& bref) @@ -47737,6 +50531,16 @@ SRSASN_CODE ims_params_common_s::unpack(cbit_ref& bref) bref.unpack(ext, 1); HANDLE_CODE(bref.unpack(voice_over_eutra_minus5_gc_present, 1)); + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(voice_over_scg_bearer_eutra_minus5_gc_present, 1)); + } + } return SRSASN_SUCCESS; } void ims_params_common_s::to_json(json_writer& j) const @@ -47745,6 +50549,11 @@ void ims_params_common_s::to_json(json_writer& j) const if (voice_over_eutra_minus5_gc_present) { j.write_str("voiceOverEUTRA-5GC", "supported"); } + if (ext) { + if (voice_over_scg_bearer_eutra_minus5_gc_present) { + j.write_str("voiceOverSCG-BearerEUTRA-5GC", "supported"); + } + } j.end_obj(); } @@ -48031,6 +50840,10 @@ SRSASN_CODE meas_and_mob_params_common_s::pack(bit_ref& bref) const group_flags[1] |= ho_fr1_fr2_present; group_flags[1] |= max_num_csi_rs_rrm_rs_sinr_present; group_flags[2] |= nr_cgi_report_endc_present; + group_flags[3] |= eutra_cgi_report_nedc_present; + group_flags[3] |= eutra_cgi_report_nrdc_present; + group_flags[3] |= nr_cgi_report_nedc_present; + group_flags[3] |= nr_cgi_report_nrdc_present; group_flags.pack(bref); if (group_flags[0]) { @@ -48057,6 +50870,14 @@ SRSASN_CODE meas_and_mob_params_common_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(nr_cgi_report_endc_present, 1)); } + if (group_flags[3]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(eutra_cgi_report_nedc_present, 1)); + HANDLE_CODE(bref.pack(eutra_cgi_report_nrdc_present, 1)); + HANDLE_CODE(bref.pack(nr_cgi_report_nedc_present, 1)); + HANDLE_CODE(bref.pack(nr_cgi_report_nrdc_present, 1)); + } } return SRSASN_SUCCESS; } @@ -48072,7 +50893,7 @@ SRSASN_CODE meas_and_mob_params_common_s::unpack(cbit_ref& bref) } if (ext) { - ext_groups_unpacker_guard group_flags(3); + ext_groups_unpacker_guard group_flags(4); group_flags.unpack(bref); if (group_flags[0]) { @@ -48099,6 +50920,14 @@ SRSASN_CODE meas_and_mob_params_common_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(nr_cgi_report_endc_present, 1)); } + if (group_flags[3]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(eutra_cgi_report_nedc_present, 1)); + HANDLE_CODE(bref.unpack(eutra_cgi_report_nrdc_present, 1)); + HANDLE_CODE(bref.unpack(nr_cgi_report_nedc_present, 1)); + HANDLE_CODE(bref.unpack(nr_cgi_report_nrdc_present, 1)); + } } return SRSASN_SUCCESS; } @@ -48142,6 +50971,18 @@ void meas_and_mob_params_common_s::to_json(json_writer& j) const if (nr_cgi_report_endc_present) { j.write_str("nr-CGI-Reporting-ENDC", "supported"); } + if (eutra_cgi_report_nedc_present) { + j.write_str("eutra-CGI-Reporting-NEDC", "supported"); + } + if (eutra_cgi_report_nrdc_present) { + j.write_str("eutra-CGI-Reporting-NRDC", "supported"); + } + if (nr_cgi_report_nedc_present) { + j.write_str("nr-CGI-Reporting-NEDC", "supported"); + } + if (nr_cgi_report_nrdc_present) { + j.write_str("nr-CGI-Reporting-NRDC", "supported"); + } } j.end_obj(); } @@ -48170,8 +51011,8 @@ SRSASN_CODE meas_and_mob_params_frx_diff_s::pack(bit_ref& bref) const if (ext) { ext_groups_packer_guard group_flags; group_flags[0] |= ho_inter_f_present; - group_flags[0] |= ho_lte_present; - group_flags[0] |= ho_e_lte_present; + group_flags[0] |= ho_lte_epc_present; + group_flags[0] |= ho_lte_minus5_gc_present; group_flags[1] |= max_num_res_csi_rs_rlm_present; group_flags[2] |= simul_rx_data_ssb_diff_numerology_present; group_flags.pack(bref); @@ -48180,8 +51021,8 @@ SRSASN_CODE meas_and_mob_params_frx_diff_s::pack(bit_ref& bref) const varlength_field_pack_guard varlen_scope(bref, false); HANDLE_CODE(bref.pack(ho_inter_f_present, 1)); - HANDLE_CODE(bref.pack(ho_lte_present, 1)); - HANDLE_CODE(bref.pack(ho_e_lte_present, 1)); + HANDLE_CODE(bref.pack(ho_lte_epc_present, 1)); + HANDLE_CODE(bref.pack(ho_lte_minus5_gc_present, 1)); } if (group_flags[1]) { varlength_field_pack_guard varlen_scope(bref, false); @@ -48216,8 +51057,8 @@ SRSASN_CODE meas_and_mob_params_frx_diff_s::unpack(cbit_ref& bref) varlength_field_unpack_guard varlen_scope(bref, false); HANDLE_CODE(bref.unpack(ho_inter_f_present, 1)); - HANDLE_CODE(bref.unpack(ho_lte_present, 1)); - HANDLE_CODE(bref.unpack(ho_e_lte_present, 1)); + HANDLE_CODE(bref.unpack(ho_lte_epc_present, 1)); + HANDLE_CODE(bref.unpack(ho_lte_minus5_gc_present, 1)); } if (group_flags[1]) { varlength_field_unpack_guard varlen_scope(bref, false); @@ -48257,11 +51098,11 @@ void meas_and_mob_params_frx_diff_s::to_json(json_writer& j) const if (ho_inter_f_present) { j.write_str("handoverInterF", "supported"); } - if (ho_lte_present) { - j.write_str("handoverLTE", "supported"); + if (ho_lte_epc_present) { + j.write_str("handoverLTE-EPC", "supported"); } - if (ho_e_lte_present) { - j.write_str("handover-eLTE", "supported"); + if (ho_lte_minus5_gc_present) { + j.write_str("handoverLTE-5GC", "supported"); } if (max_num_res_csi_rs_rlm_present) { j.write_str("maxNumberResource-CSI-RS-RLM", max_num_res_csi_rs_rlm.to_string()); @@ -48294,16 +51135,24 @@ SRSASN_CODE meas_and_mob_params_xdd_diff_s::pack(bit_ref& bref) const if (ext) { ext_groups_packer_guard group_flags; group_flags[0] |= ho_inter_f_present; - group_flags[0] |= ho_lte_present; - group_flags[0] |= ho_e_lte_present; + group_flags[0] |= ho_lte_epc_present; + group_flags[0] |= ho_lte_minus5_gc_present; + group_flags[1] |= sftd_meas_nr_neigh_present; + group_flags[1] |= sftd_meas_nr_neigh_drx_present; group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); HANDLE_CODE(bref.pack(ho_inter_f_present, 1)); - HANDLE_CODE(bref.pack(ho_lte_present, 1)); - HANDLE_CODE(bref.pack(ho_e_lte_present, 1)); + HANDLE_CODE(bref.pack(ho_lte_epc_present, 1)); + HANDLE_CODE(bref.pack(ho_lte_minus5_gc_present, 1)); + } + if (group_flags[1]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(sftd_meas_nr_neigh_present, 1)); + HANDLE_CODE(bref.pack(sftd_meas_nr_neigh_drx_present, 1)); } } return SRSASN_SUCCESS; @@ -48315,15 +51164,21 @@ SRSASN_CODE meas_and_mob_params_xdd_diff_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(event_a_meas_and_report_present, 1)); if (ext) { - ext_groups_unpacker_guard group_flags(1); + ext_groups_unpacker_guard group_flags(2); group_flags.unpack(bref); if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); HANDLE_CODE(bref.unpack(ho_inter_f_present, 1)); - HANDLE_CODE(bref.unpack(ho_lte_present, 1)); - HANDLE_CODE(bref.unpack(ho_e_lte_present, 1)); + HANDLE_CODE(bref.unpack(ho_lte_epc_present, 1)); + HANDLE_CODE(bref.unpack(ho_lte_minus5_gc_present, 1)); + } + if (group_flags[1]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(sftd_meas_nr_neigh_present, 1)); + HANDLE_CODE(bref.unpack(sftd_meas_nr_neigh_drx_present, 1)); } } return SRSASN_SUCCESS; @@ -48341,11 +51196,17 @@ void meas_and_mob_params_xdd_diff_s::to_json(json_writer& j) const if (ho_inter_f_present) { j.write_str("handoverInterF", "supported"); } - if (ho_lte_present) { - j.write_str("handoverLTE", "supported"); + if (ho_lte_epc_present) { + j.write_str("handoverLTE-EPC", "supported"); } - if (ho_e_lte_present) { - j.write_str("handover-eLTE", "supported"); + if (ho_lte_minus5_gc_present) { + j.write_str("handoverLTE-5GC", "supported"); + } + if (sftd_meas_nr_neigh_present) { + j.write_str("sftd-MeasNR-Neigh", "supported"); + } + if (sftd_meas_nr_neigh_drx_present) { + j.write_str("sftd-MeasNR-Neigh-DRX", "supported"); } } j.end_obj(); @@ -48532,138 +51393,356 @@ void meas_and_mob_params_mrdc_s::to_json(json_writer& j) const j.end_obj(); } -// MeasResult2NR ::= SEQUENCE -SRSASN_CODE meas_result2_nr_s::pack(bit_ref& bref) const +// MeasAndMobParametersMRDC-XDD-Diff-v1560 ::= SEQUENCE +SRSASN_CODE meas_and_mob_params_mrdc_xdd_diff_v1560_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(ssb_freq_present, 1)); - HANDLE_CODE(bref.pack(ref_freq_csi_rs_present, 1)); - HANDLE_CODE(bref.pack(meas_result_serving_cell_present, 1)); - HANDLE_CODE(bref.pack(meas_result_neigh_cell_list_nr_present, 1)); + HANDLE_CODE(bref.pack(sftd_meas_ps_cell_nedc_present, 1)); - if (ssb_freq_present) { - HANDLE_CODE(pack_integer(bref, ssb_freq, (uint32_t)0u, (uint32_t)3279165u)); + return SRSASN_SUCCESS; +} +SRSASN_CODE meas_and_mob_params_mrdc_xdd_diff_v1560_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(sftd_meas_ps_cell_nedc_present, 1)); + + return SRSASN_SUCCESS; +} +void meas_and_mob_params_mrdc_xdd_diff_v1560_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (sftd_meas_ps_cell_nedc_present) { + j.write_str("sftd-MeasPSCell-NEDC", "supported"); } - if (ref_freq_csi_rs_present) { - HANDLE_CODE(pack_integer(bref, ref_freq_csi_rs, (uint32_t)0u, (uint32_t)3279165u)); + j.end_obj(); +} + +// MeasAndMobParametersMRDC-v1560 ::= SEQUENCE +SRSASN_CODE meas_and_mob_params_mrdc_v1560_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(meas_and_mob_params_mrdc_xdd_diff_v1560_present, 1)); + + if (meas_and_mob_params_mrdc_xdd_diff_v1560_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff_v1560.pack(bref)); } - if (meas_result_serving_cell_present) { - HANDLE_CODE(meas_result_serving_cell.pack(bref)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE meas_and_mob_params_mrdc_v1560_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(meas_and_mob_params_mrdc_xdd_diff_v1560_present, 1)); + + if (meas_and_mob_params_mrdc_xdd_diff_v1560_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff_v1560.unpack(bref)); } - if (meas_result_neigh_cell_list_nr_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_neigh_cell_list_nr, 1, 8)); + + return SRSASN_SUCCESS; +} +void meas_and_mob_params_mrdc_v1560_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (meas_and_mob_params_mrdc_xdd_diff_v1560_present) { + j.write_fieldname("measAndMobParametersMRDC-XDD-Diff-v1560"); + meas_and_mob_params_mrdc_xdd_diff_v1560.to_json(j); + } + j.end_obj(); +} + +// MeasResultSCG-Failure ::= SEQUENCE +SRSASN_CODE meas_result_scg_fail_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_per_mo_list, 1, 8)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE meas_result_scg_fail_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(unpack_dyn_seq_of(meas_result_per_mo_list, bref, 1, 8)); + + return SRSASN_SUCCESS; +} +void meas_result_scg_fail_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.start_array("measResultPerMOList"); + for (const auto& e1 : meas_result_per_mo_list) { + e1.to_json(j); } + j.end_array(); + j.end_obj(); +} + +// GeneralParametersMRDC-XDD-Diff ::= SEQUENCE +SRSASN_CODE general_params_mrdc_xdd_diff_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(split_srb_with_one_ul_path_present, 1)); + HANDLE_CODE(bref.pack(split_drb_with_ul_both_mcg_scg_present, 1)); + HANDLE_CODE(bref.pack(srb3_present, 1)); + HANDLE_CODE(bref.pack(v2x_eutra_present, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_result2_nr_s::unpack(cbit_ref& bref) +SRSASN_CODE general_params_mrdc_xdd_diff_s::unpack(cbit_ref& bref) { bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(ssb_freq_present, 1)); - HANDLE_CODE(bref.unpack(ref_freq_csi_rs_present, 1)); - HANDLE_CODE(bref.unpack(meas_result_serving_cell_present, 1)); - HANDLE_CODE(bref.unpack(meas_result_neigh_cell_list_nr_present, 1)); + HANDLE_CODE(bref.unpack(split_srb_with_one_ul_path_present, 1)); + HANDLE_CODE(bref.unpack(split_drb_with_ul_both_mcg_scg_present, 1)); + HANDLE_CODE(bref.unpack(srb3_present, 1)); + HANDLE_CODE(bref.unpack(v2x_eutra_present, 1)); - if (ssb_freq_present) { - HANDLE_CODE(unpack_integer(ssb_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); + return SRSASN_SUCCESS; +} +void general_params_mrdc_xdd_diff_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (split_srb_with_one_ul_path_present) { + j.write_str("splitSRB-WithOneUL-Path", "supported"); } - if (ref_freq_csi_rs_present) { - HANDLE_CODE(unpack_integer(ref_freq_csi_rs, bref, (uint32_t)0u, (uint32_t)3279165u)); + if (split_drb_with_ul_both_mcg_scg_present) { + j.write_str("splitDRB-withUL-Both-MCG-SCG", "supported"); } - if (meas_result_serving_cell_present) { - HANDLE_CODE(meas_result_serving_cell.unpack(bref)); + if (srb3_present) { + j.write_str("srb3", "supported"); } - if (meas_result_neigh_cell_list_nr_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_result_neigh_cell_list_nr, bref, 1, 8)); + if (v2x_eutra_present) { + j.write_str("v2x-EUTRA", "supported"); } + j.end_obj(); +} + +// UE-MRDC-CapabilityAddFRX-Mode ::= SEQUENCE +SRSASN_CODE ue_mrdc_cap_add_frx_mode_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(meas_and_mob_params_mrdc_frx_diff.pack(bref)); return SRSASN_SUCCESS; } -void meas_result2_nr_s::to_json(json_writer& j) const +SRSASN_CODE ue_mrdc_cap_add_frx_mode_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(meas_and_mob_params_mrdc_frx_diff.unpack(bref)); + + return SRSASN_SUCCESS; +} +void ue_mrdc_cap_add_frx_mode_s::to_json(json_writer& j) const { j.start_obj(); - if (ssb_freq_present) { - j.write_int("ssbFrequency", ssb_freq); + j.write_fieldname("measAndMobParametersMRDC-FRX-Diff"); + meas_and_mob_params_mrdc_frx_diff.to_json(j); + j.end_obj(); +} + +// UE-MRDC-CapabilityAddXDD-Mode ::= SEQUENCE +SRSASN_CODE ue_mrdc_cap_add_xdd_mode_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(meas_and_mob_params_mrdc_xdd_diff_present, 1)); + HANDLE_CODE(bref.pack(general_params_mrdc_xdd_diff_present, 1)); + + if (meas_and_mob_params_mrdc_xdd_diff_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff.pack(bref)); } - if (ref_freq_csi_rs_present) { - j.write_int("refFreqCSI-RS", ref_freq_csi_rs); + if (general_params_mrdc_xdd_diff_present) { + HANDLE_CODE(general_params_mrdc_xdd_diff.pack(bref)); } - if (meas_result_serving_cell_present) { - j.write_fieldname("measResultServingCell"); - meas_result_serving_cell.to_json(j); + + return SRSASN_SUCCESS; +} +SRSASN_CODE ue_mrdc_cap_add_xdd_mode_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(meas_and_mob_params_mrdc_xdd_diff_present, 1)); + HANDLE_CODE(bref.unpack(general_params_mrdc_xdd_diff_present, 1)); + + if (meas_and_mob_params_mrdc_xdd_diff_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff.unpack(bref)); } - if (meas_result_neigh_cell_list_nr_present) { - j.start_array("measResultNeighCellListNR"); - for (const auto& e1 : meas_result_neigh_cell_list_nr) { - e1.to_json(j); - } - j.end_array(); + if (general_params_mrdc_xdd_diff_present) { + HANDLE_CODE(general_params_mrdc_xdd_diff.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void ue_mrdc_cap_add_xdd_mode_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (meas_and_mob_params_mrdc_xdd_diff_present) { + j.write_fieldname("measAndMobParametersMRDC-XDD-Diff"); + meas_and_mob_params_mrdc_xdd_diff.to_json(j); + } + if (general_params_mrdc_xdd_diff_present) { + j.write_fieldname("generalParametersMRDC-XDD-Diff"); + general_params_mrdc_xdd_diff.to_json(j); } j.end_obj(); } -// MeasResultCellSFTD ::= SEQUENCE -SRSASN_CODE meas_result_cell_sftd_s::pack(bit_ref& bref) const +// NRDC-Parameters ::= SEQUENCE +SRSASN_CODE nrdc_params_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(rsrp_result_present, 1)); + HANDLE_CODE(bref.pack(meas_and_mob_params_nrdc_present, 1)); + HANDLE_CODE(bref.pack(general_params_nrdc_present, 1)); + HANDLE_CODE(bref.pack(fdd_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.pack(tdd_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.pack(fr1_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.pack(fr2_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.pack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.pack(dummy_present, 1)); - HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(pack_integer(bref, sfn_offset_result, (uint16_t)0u, (uint16_t)1023u)); - HANDLE_CODE(pack_integer(bref, frame_boundary_offset_result, (int16_t)-30720, (int16_t)30719)); - if (rsrp_result_present) { - HANDLE_CODE(pack_integer(bref, rsrp_result, (uint8_t)0u, (uint8_t)127u)); + if (meas_and_mob_params_nrdc_present) { + HANDLE_CODE(meas_and_mob_params_nrdc.pack(bref)); + } + if (general_params_nrdc_present) { + HANDLE_CODE(general_params_nrdc.pack(bref)); + } + if (fdd_add_ue_nrdc_cap_present) { + HANDLE_CODE(fdd_add_ue_nrdc_cap.pack(bref)); + } + if (tdd_add_ue_nrdc_cap_present) { + HANDLE_CODE(tdd_add_ue_nrdc_cap.pack(bref)); + } + if (fr1_add_ue_nrdc_cap_present) { + HANDLE_CODE(fr1_add_ue_nrdc_cap.pack(bref)); + } + if (fr2_add_ue_nrdc_cap_present) { + HANDLE_CODE(fr2_add_ue_nrdc_cap.pack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE meas_result_cell_sftd_s::unpack(cbit_ref& bref) +SRSASN_CODE nrdc_params_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(rsrp_result_present, 1)); + HANDLE_CODE(bref.unpack(meas_and_mob_params_nrdc_present, 1)); + HANDLE_CODE(bref.unpack(general_params_nrdc_present, 1)); + HANDLE_CODE(bref.unpack(fdd_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.unpack(tdd_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.unpack(fr1_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.unpack(fr2_add_ue_nrdc_cap_present, 1)); + HANDLE_CODE(bref.unpack(late_non_crit_ext_present, 1)); + HANDLE_CODE(bref.unpack(dummy_present, 1)); - HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); - HANDLE_CODE(unpack_integer(sfn_offset_result, bref, (uint16_t)0u, (uint16_t)1023u)); - HANDLE_CODE(unpack_integer(frame_boundary_offset_result, bref, (int16_t)-30720, (int16_t)30719)); - if (rsrp_result_present) { - HANDLE_CODE(unpack_integer(rsrp_result, bref, (uint8_t)0u, (uint8_t)127u)); + if (meas_and_mob_params_nrdc_present) { + HANDLE_CODE(meas_and_mob_params_nrdc.unpack(bref)); + } + if (general_params_nrdc_present) { + HANDLE_CODE(general_params_nrdc.unpack(bref)); + } + if (fdd_add_ue_nrdc_cap_present) { + HANDLE_CODE(fdd_add_ue_nrdc_cap.unpack(bref)); + } + if (tdd_add_ue_nrdc_cap_present) { + HANDLE_CODE(tdd_add_ue_nrdc_cap.unpack(bref)); + } + if (fr1_add_ue_nrdc_cap_present) { + HANDLE_CODE(fr1_add_ue_nrdc_cap.unpack(bref)); + } + if (fr2_add_ue_nrdc_cap_present) { + HANDLE_CODE(fr2_add_ue_nrdc_cap.unpack(bref)); + } + if (late_non_crit_ext_present) { + HANDLE_CODE(late_non_crit_ext.unpack(bref)); } return SRSASN_SUCCESS; } -void meas_result_cell_sftd_s::to_json(json_writer& j) const +void nrdc_params_s::to_json(json_writer& j) const { j.start_obj(); - j.write_int("physCellId", pci); - j.write_int("sfn-OffsetResult", sfn_offset_result); - j.write_int("frameBoundaryOffsetResult", frame_boundary_offset_result); - if (rsrp_result_present) { - j.write_int("rsrp-Result", rsrp_result); + if (meas_and_mob_params_nrdc_present) { + j.write_fieldname("measAndMobParametersNRDC"); + meas_and_mob_params_nrdc.to_json(j); + } + if (general_params_nrdc_present) { + j.write_fieldname("generalParametersNRDC"); + general_params_nrdc.to_json(j); + } + if (fdd_add_ue_nrdc_cap_present) { + j.write_fieldname("fdd-Add-UE-NRDC-Capabilities"); + fdd_add_ue_nrdc_cap.to_json(j); + } + if (tdd_add_ue_nrdc_cap_present) { + j.write_fieldname("tdd-Add-UE-NRDC-Capabilities"); + tdd_add_ue_nrdc_cap.to_json(j); + } + if (fr1_add_ue_nrdc_cap_present) { + j.write_fieldname("fr1-Add-UE-NRDC-Capabilities"); + fr1_add_ue_nrdc_cap.to_json(j); + } + if (fr2_add_ue_nrdc_cap_present) { + j.write_fieldname("fr2-Add-UE-NRDC-Capabilities"); + fr2_add_ue_nrdc_cap.to_json(j); + } + if (late_non_crit_ext_present) { + j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); + } + if (dummy_present) { + j.write_fieldname("dummy"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } -// MeasResultSCG-Failure ::= SEQUENCE -SRSASN_CODE meas_result_scg_fail_s::pack(bit_ref& bref) const +// CarrierAggregationVariant ::= SEQUENCE +SRSASN_CODE carrier_aggregation_variant_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_per_mo_list, 1, 8)); + HANDLE_CODE(bref.pack(fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_fdd_present, 1)); + HANDLE_CODE(bref.pack(fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_tdd_present, 1)); + HANDLE_CODE(bref.pack(fr1fdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present, 1)); + HANDLE_CODE(bref.pack(fr1fdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present, 1)); + HANDLE_CODE(bref.pack(fr1tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present, 1)); + HANDLE_CODE(bref.pack(fr1tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present, 1)); + HANDLE_CODE(bref.pack(fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present, 1)); + HANDLE_CODE(bref.pack(fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present, 1)); + HANDLE_CODE(bref.pack(fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present, 1)); return SRSASN_SUCCESS; } -SRSASN_CODE meas_result_scg_fail_s::unpack(cbit_ref& bref) +SRSASN_CODE carrier_aggregation_variant_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(unpack_dyn_seq_of(meas_result_per_mo_list, bref, 1, 8)); + HANDLE_CODE(bref.unpack(fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_fdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_tdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1fdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1fdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present, 1)); + HANDLE_CODE(bref.unpack(fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present, 1)); return SRSASN_SUCCESS; } -void meas_result_scg_fail_s::to_json(json_writer& j) const +void carrier_aggregation_variant_s::to_json(json_writer& j) const { j.start_obj(); - j.start_array("measResultPerMOList"); - for (const auto& e1 : meas_result_per_mo_list) { - e1.to_json(j); + if (fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_fdd_present) { + j.write_str("fr1fdd-FR1TDD-CA-SpCellOnFR1FDD", "supported"); + } + if (fr1fdd_fr1_tdd_ca_sp_cell_on_fr1_tdd_present) { + j.write_str("fr1fdd-FR1TDD-CA-SpCellOnFR1TDD", "supported"); + } + if (fr1fdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present) { + j.write_str("fr1fdd-FR2TDD-CA-SpCellOnFR1FDD", "supported"); + } + if (fr1fdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present) { + j.write_str("fr1fdd-FR2TDD-CA-SpCellOnFR2TDD", "supported"); + } + if (fr1tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present) { + j.write_str("fr1tdd-FR2TDD-CA-SpCellOnFR1TDD", "supported"); + } + if (fr1tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present) { + j.write_str("fr1tdd-FR2TDD-CA-SpCellOnFR2TDD", "supported"); + } + if (fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_fdd_present) { + j.write_str("fr1fdd-FR1TDD-FR2TDD-CA-SpCellOnFR1FDD", "supported"); + } + if (fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr1_tdd_present) { + j.write_str("fr1fdd-FR1TDD-FR2TDD-CA-SpCellOnFR1TDD", "supported"); + } + if (fr1fdd_fr1_tdd_fr2_tdd_ca_sp_cell_on_fr2_tdd_present) { + j.write_str("fr1fdd-FR1TDD-FR2TDD-CA-SpCellOnFR2TDD", "supported"); } - j.end_array(); j.end_obj(); } @@ -48716,6 +51795,7 @@ SRSASN_CODE phy_params_common_s::pack(bit_ref& bref) const group_flags[1] |= max_num_search_spaces_present; group_flags[1] |= rate_matching_ctrl_resrc_set_dynamic_present; group_flags[1] |= max_layers_mimo_ind_present; + group_flags[2] |= sp_cell_placement.is_present(); group_flags.pack(bref); if (group_flags[0]) { @@ -48730,6 +51810,14 @@ SRSASN_CODE phy_params_common_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(rate_matching_ctrl_resrc_set_dynamic_present, 1)); HANDLE_CODE(bref.pack(max_layers_mimo_ind_present, 1)); } + if (group_flags[2]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(sp_cell_placement.is_present(), 1)); + if (sp_cell_placement.is_present()) { + HANDLE_CODE(sp_cell_placement->pack(bref)); + } + } } return SRSASN_SUCCESS; } @@ -48776,7 +51864,7 @@ SRSASN_CODE phy_params_common_s::unpack(cbit_ref& bref) } if (ext) { - ext_groups_unpacker_guard group_flags(2); + ext_groups_unpacker_guard group_flags(3); group_flags.unpack(bref); if (group_flags[0]) { @@ -48791,6 +51879,16 @@ SRSASN_CODE phy_params_common_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(rate_matching_ctrl_resrc_set_dynamic_present, 1)); HANDLE_CODE(bref.unpack(max_layers_mimo_ind_present, 1)); } + if (group_flags[2]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool sp_cell_placement_present; + HANDLE_CODE(bref.unpack(sp_cell_placement_present, 1)); + sp_cell_placement.set_present(sp_cell_placement_present); + if (sp_cell_placement.is_present()) { + HANDLE_CODE(sp_cell_placement->unpack(bref)); + } + } } return SRSASN_SUCCESS; } @@ -48912,6 +52010,10 @@ void phy_params_common_s::to_json(json_writer& j) const if (max_layers_mimo_ind_present) { j.write_str("maxLayersMIMO-Indication", "supported"); } + if (sp_cell_placement.is_present()) { + j.write_fieldname("spCellPlacement"); + sp_cell_placement->to_json(j); + } } j.end_obj(); } @@ -48987,7 +52089,7 @@ void phy_params_fr1_s::to_json(json_writer& j) const { j.start_obj(); if (pdcch_monitoring_single_occasion_present) { - j.write_str("pdcchMonitoringSingleOccasion", "supported"); + j.write_str("pdcch-MonitoringSingleOccasion", "supported"); } if (scs_minus60k_hz_present) { j.write_str("scs-60kHz", "supported"); @@ -49174,8 +52276,8 @@ SRSASN_CODE phy_params_frx_diff_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(pucch_f2_with_fh_present, 1)); HANDLE_CODE(bref.pack(pucch_f3_with_fh_present, 1)); HANDLE_CODE(bref.pack(pucch_f4_with_fh_present, 1)); - HANDLE_CODE(bref.pack(freq_hop_pucch_f0_minus2_present, 1)); - HANDLE_CODE(bref.pack(freq_hop_pucch_f1_minus3_minus4_present, 1)); + HANDLE_CODE(bref.pack(pucch_f0_minus2_without_fh_present, 1)); + HANDLE_CODE(bref.pack(pucch_f1_minus3_minus4_without_fh_present, 1)); HANDLE_CODE(bref.pack(mux_sr_harq_ack_csi_pucch_multi_per_slot_present, 1)); HANDLE_CODE(bref.pack(uci_code_block_segmentation_present, 1)); HANDLE_CODE(bref.pack(one_pucch_long_and_short_format_present, 1)); @@ -49239,6 +52341,8 @@ SRSASN_CODE phy_params_frx_diff_s::pack(bit_ref& bref) const group_flags[0] |= one_fl_dmrs_two_add_dmrs_ul_present; group_flags[0] |= two_fl_dmrs_two_add_dmrs_ul_present; group_flags[0] |= one_fl_dmrs_three_add_dmrs_ul_present; + group_flags[1] |= pdcch_blind_detection_nrdc.is_present(); + group_flags[1] |= mux_harq_ack_pusch_diff_symbol_present; group_flags.pack(bref); if (group_flags[0]) { @@ -49273,6 +52377,18 @@ SRSASN_CODE phy_params_frx_diff_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(mux_sr_harq_ack_csi_pucch_once_per_slot->diff_symbol_present, 1)); } } + if (group_flags[1]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(pdcch_blind_detection_nrdc.is_present(), 1)); + HANDLE_CODE(bref.pack(mux_harq_ack_pusch_diff_symbol_present, 1)); + if (pdcch_blind_detection_nrdc.is_present()) { + HANDLE_CODE( + pack_integer(bref, pdcch_blind_detection_nrdc->pdcch_blind_detection_mcg_ue, (uint8_t)1u, (uint8_t)15u)); + HANDLE_CODE( + pack_integer(bref, pdcch_blind_detection_nrdc->pdcch_blind_detection_scg_ue, (uint8_t)1u, (uint8_t)15u)); + } + } } return SRSASN_SUCCESS; } @@ -49294,8 +52410,8 @@ SRSASN_CODE phy_params_frx_diff_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(pucch_f2_with_fh_present, 1)); HANDLE_CODE(bref.unpack(pucch_f3_with_fh_present, 1)); HANDLE_CODE(bref.unpack(pucch_f4_with_fh_present, 1)); - HANDLE_CODE(bref.unpack(freq_hop_pucch_f0_minus2_present, 1)); - HANDLE_CODE(bref.unpack(freq_hop_pucch_f1_minus3_minus4_present, 1)); + HANDLE_CODE(bref.unpack(pucch_f0_minus2_without_fh_present, 1)); + HANDLE_CODE(bref.unpack(pucch_f1_minus3_minus4_without_fh_present, 1)); HANDLE_CODE(bref.unpack(mux_sr_harq_ack_csi_pucch_multi_per_slot_present, 1)); HANDLE_CODE(bref.unpack(uci_code_block_segmentation_present, 1)); HANDLE_CODE(bref.unpack(one_pucch_long_and_short_format_present, 1)); @@ -49343,7 +52459,7 @@ SRSASN_CODE phy_params_frx_diff_s::unpack(cbit_ref& bref) } if (ext) { - ext_groups_unpacker_guard group_flags(1); + ext_groups_unpacker_guard group_flags(2); group_flags.unpack(bref); if (group_flags[0]) { @@ -49386,6 +52502,20 @@ SRSASN_CODE phy_params_frx_diff_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(mux_sr_harq_ack_csi_pucch_once_per_slot->diff_symbol_present, 1)); } } + if (group_flags[1]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool pdcch_blind_detection_nrdc_present; + HANDLE_CODE(bref.unpack(pdcch_blind_detection_nrdc_present, 1)); + pdcch_blind_detection_nrdc.set_present(pdcch_blind_detection_nrdc_present); + HANDLE_CODE(bref.unpack(mux_harq_ack_pusch_diff_symbol_present, 1)); + if (pdcch_blind_detection_nrdc.is_present()) { + HANDLE_CODE( + unpack_integer(pdcch_blind_detection_nrdc->pdcch_blind_detection_mcg_ue, bref, (uint8_t)1u, (uint8_t)15u)); + HANDLE_CODE( + unpack_integer(pdcch_blind_detection_nrdc->pdcch_blind_detection_scg_ue, bref, (uint8_t)1u, (uint8_t)15u)); + } + } } return SRSASN_SUCCESS; } @@ -49437,11 +52567,11 @@ void phy_params_frx_diff_s::to_json(json_writer& j) const if (pucch_f4_with_fh_present) { j.write_str("pucch-F4-WithFH", "supported"); } - if (freq_hop_pucch_f0_minus2_present) { - j.write_str("freqHoppingPUCCH-F0-2", "notSupported"); + if (pucch_f0_minus2_without_fh_present) { + j.write_str("pucch-F0-2WithoutFH", "notSupported"); } - if (freq_hop_pucch_f1_minus3_minus4_present) { - j.write_str("freqHoppingPUCCH-F1-3-4", "notSupported"); + if (pucch_f1_minus3_minus4_without_fh_present) { + j.write_str("pucch-F1-3-4WithoutFH", "notSupported"); } if (mux_sr_harq_ack_csi_pucch_multi_per_slot_present) { j.write_str("mux-SR-HARQ-ACK-CSI-PUCCH-MultiPerSlot", "supported"); @@ -49560,6 +52690,16 @@ void phy_params_frx_diff_s::to_json(json_writer& j) const if (one_fl_dmrs_three_add_dmrs_ul_present) { j.write_str("oneFL-DMRS-ThreeAdditionalDMRS-UL", "supported"); } + if (pdcch_blind_detection_nrdc.is_present()) { + j.write_fieldname("pdcch-BlindDetectionNRDC"); + j.start_obj(); + j.write_int("pdcch-BlindDetectionMCG-UE", pdcch_blind_detection_nrdc->pdcch_blind_detection_mcg_ue); + j.write_int("pdcch-BlindDetectionSCG-UE", pdcch_blind_detection_nrdc->pdcch_blind_detection_scg_ue); + j.end_obj(); + } + if (mux_harq_ack_pusch_diff_symbol_present) { + j.write_str("mux-HARQ-ACK-PUSCH-DiffSymbol", "supported"); + } } j.end_obj(); } @@ -49793,6 +52933,20 @@ SRSASN_CODE phy_params_mrdc_s::pack(bit_ref& bref) const HANDLE_CODE(pack_dyn_seq_of(bref, naics_cap_list, 1, 8)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= sp_cell_placement.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(sp_cell_placement.is_present(), 1)); + if (sp_cell_placement.is_present()) { + HANDLE_CODE(sp_cell_placement->pack(bref)); + } + } + } return SRSASN_SUCCESS; } SRSASN_CODE phy_params_mrdc_s::unpack(cbit_ref& bref) @@ -49804,6 +52958,21 @@ SRSASN_CODE phy_params_mrdc_s::unpack(cbit_ref& bref) HANDLE_CODE(unpack_dyn_seq_of(naics_cap_list, bref, 1, 8)); } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool sp_cell_placement_present; + HANDLE_CODE(bref.unpack(sp_cell_placement_present, 1)); + sp_cell_placement.set_present(sp_cell_placement_present); + if (sp_cell_placement.is_present()) { + HANDLE_CODE(sp_cell_placement->unpack(bref)); + } + } + } return SRSASN_SUCCESS; } void phy_params_mrdc_s::to_json(json_writer& j) const @@ -49816,6 +52985,12 @@ void phy_params_mrdc_s::to_json(json_writer& j) const } j.end_array(); } + if (ext) { + if (sp_cell_placement.is_present()) { + j.write_fieldname("spCellPlacement"); + sp_cell_placement->to_json(j); + } + } j.end_obj(); } @@ -49839,6 +53014,7 @@ SRSASN_CODE rf_params_s::pack(bit_ref& bref) const group_flags[0] |= supported_band_combination_list_v1540.is_present(); group_flags[0] |= srs_switching_time_requested_present; group_flags[1] |= supported_band_combination_list_v1550.is_present(); + group_flags[2] |= supported_band_combination_list_v1560.is_present(); group_flags.pack(bref); if (group_flags[0]) { @@ -49858,6 +53034,14 @@ SRSASN_CODE rf_params_s::pack(bit_ref& bref) const HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_v1550, 1, 65536)); } } + if (group_flags[2]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(supported_band_combination_list_v1560.is_present(), 1)); + if (supported_band_combination_list_v1560.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_v1560, 1, 65536)); + } + } } return SRSASN_SUCCESS; } @@ -49876,7 +53060,7 @@ SRSASN_CODE rf_params_s::unpack(cbit_ref& bref) } if (ext) { - ext_groups_unpacker_guard group_flags(2); + ext_groups_unpacker_guard group_flags(3); group_flags.unpack(bref); if (group_flags[0]) { @@ -49900,6 +53084,16 @@ SRSASN_CODE rf_params_s::unpack(cbit_ref& bref) HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_v1550, bref, 1, 65536)); } } + if (group_flags[2]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool supported_band_combination_list_v1560_present; + HANDLE_CODE(bref.unpack(supported_band_combination_list_v1560_present, 1)); + supported_band_combination_list_v1560.set_present(supported_band_combination_list_v1560_present); + if (supported_band_combination_list_v1560.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_v1560, bref, 1, 65536)); + } + } } return SRSASN_SUCCESS; } @@ -49943,6 +53137,13 @@ void rf_params_s::to_json(json_writer& j) const } j.end_array(); } + if (supported_band_combination_list_v1560.is_present()) { + j.start_array("supportedBandCombinationList-v1560"); + for (const auto& e1 : *supported_band_combination_list_v1560) { + e1.to_json(j); + } + j.end_array(); + } } j.end_obj(); } @@ -49966,6 +53167,12 @@ SRSASN_CODE rf_params_mrdc_s::pack(bit_ref& bref) const group_flags[0] |= srs_switching_time_requested_present; group_flags[0] |= supported_band_combination_list_v1540.is_present(); group_flags[1] |= supported_band_combination_list_v1550.is_present(); + group_flags[2] |= supported_band_combination_list_v1560.is_present(); + group_flags[2] |= supported_band_combination_list_nedc_only.is_present(); + group_flags[3] |= supported_band_combination_list_v1570.is_present(); + group_flags[4] |= supported_band_combination_list_v1580.is_present(); + group_flags[5] |= supported_band_combination_list_v1590.is_present(); + group_flags[6] |= supported_band_combination_list_nedc_only_v15a0.is_present(); group_flags.pack(bref); if (group_flags[0]) { @@ -49985,6 +53192,79 @@ SRSASN_CODE rf_params_mrdc_s::pack(bit_ref& bref) const HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_v1550, 1, 65536)); } } + if (group_flags[2]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(supported_band_combination_list_v1560.is_present(), 1)); + HANDLE_CODE(bref.pack(supported_band_combination_list_nedc_only.is_present(), 1)); + if (supported_band_combination_list_v1560.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_v1560, 1, 65536)); + } + if (supported_band_combination_list_nedc_only.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_nedc_only, 1, 65536)); + } + } + if (group_flags[3]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(supported_band_combination_list_v1570.is_present(), 1)); + if (supported_band_combination_list_v1570.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_v1570, 1, 65536)); + } + } + if (group_flags[4]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(supported_band_combination_list_v1580.is_present(), 1)); + if (supported_band_combination_list_v1580.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_v1580, 1, 65536)); + } + } + if (group_flags[5]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(supported_band_combination_list_v1590.is_present(), 1)); + if (supported_band_combination_list_v1590.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *supported_band_combination_list_v1590, 1, 65536)); + } + } + if (group_flags[6]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(supported_band_combination_list_nedc_only_v15a0.is_present(), 1)); + if (supported_band_combination_list_nedc_only_v15a0.is_present()) { + HANDLE_CODE(bref.pack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540_present, 1)); + HANDLE_CODE(bref.pack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560_present, 1)); + HANDLE_CODE(bref.pack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570_present, 1)); + HANDLE_CODE(bref.pack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580_present, 1)); + HANDLE_CODE(bref.pack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590_present, 1)); + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540_present) { + HANDLE_CODE(pack_dyn_seq_of( + bref, supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560_present) { + HANDLE_CODE(pack_dyn_seq_of( + bref, supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570_present) { + HANDLE_CODE(pack_dyn_seq_of( + bref, supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580_present) { + HANDLE_CODE(pack_dyn_seq_of( + bref, supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590_present) { + HANDLE_CODE(pack_dyn_seq_of( + bref, supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590, 1, 65536)); + } + } + } } return SRSASN_SUCCESS; } @@ -50002,7 +53282,7 @@ SRSASN_CODE rf_params_mrdc_s::unpack(cbit_ref& bref) } if (ext) { - ext_groups_unpacker_guard group_flags(2); + ext_groups_unpacker_guard group_flags(7); group_flags.unpack(bref); if (group_flags[0]) { @@ -50026,6 +53306,92 @@ SRSASN_CODE rf_params_mrdc_s::unpack(cbit_ref& bref) HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_v1550, bref, 1, 65536)); } } + if (group_flags[2]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool supported_band_combination_list_v1560_present; + HANDLE_CODE(bref.unpack(supported_band_combination_list_v1560_present, 1)); + supported_band_combination_list_v1560.set_present(supported_band_combination_list_v1560_present); + bool supported_band_combination_list_nedc_only_present; + HANDLE_CODE(bref.unpack(supported_band_combination_list_nedc_only_present, 1)); + supported_band_combination_list_nedc_only.set_present(supported_band_combination_list_nedc_only_present); + if (supported_band_combination_list_v1560.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_v1560, bref, 1, 65536)); + } + if (supported_band_combination_list_nedc_only.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_nedc_only, bref, 1, 65536)); + } + } + if (group_flags[3]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool supported_band_combination_list_v1570_present; + HANDLE_CODE(bref.unpack(supported_band_combination_list_v1570_present, 1)); + supported_band_combination_list_v1570.set_present(supported_band_combination_list_v1570_present); + if (supported_band_combination_list_v1570.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_v1570, bref, 1, 65536)); + } + } + if (group_flags[4]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool supported_band_combination_list_v1580_present; + HANDLE_CODE(bref.unpack(supported_band_combination_list_v1580_present, 1)); + supported_band_combination_list_v1580.set_present(supported_band_combination_list_v1580_present); + if (supported_band_combination_list_v1580.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_v1580, bref, 1, 65536)); + } + } + if (group_flags[5]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool supported_band_combination_list_v1590_present; + HANDLE_CODE(bref.unpack(supported_band_combination_list_v1590_present, 1)); + supported_band_combination_list_v1590.set_present(supported_band_combination_list_v1590_present); + if (supported_band_combination_list_v1590.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*supported_band_combination_list_v1590, bref, 1, 65536)); + } + } + if (group_flags[6]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool supported_band_combination_list_nedc_only_v15a0_present; + HANDLE_CODE(bref.unpack(supported_band_combination_list_nedc_only_v15a0_present, 1)); + supported_band_combination_list_nedc_only_v15a0.set_present( + supported_band_combination_list_nedc_only_v15a0_present); + if (supported_band_combination_list_nedc_only_v15a0.is_present()) { + HANDLE_CODE(bref.unpack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540_present, 1)); + HANDLE_CODE(bref.unpack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560_present, 1)); + HANDLE_CODE(bref.unpack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570_present, 1)); + HANDLE_CODE(bref.unpack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580_present, 1)); + HANDLE_CODE(bref.unpack( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590_present, 1)); + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540_present) { + HANDLE_CODE(unpack_dyn_seq_of( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540, bref, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560_present) { + HANDLE_CODE(unpack_dyn_seq_of( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560, bref, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570_present) { + HANDLE_CODE(unpack_dyn_seq_of( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570, bref, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580_present) { + HANDLE_CODE(unpack_dyn_seq_of( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580, bref, 1, 65536)); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590_present) { + HANDLE_CODE(unpack_dyn_seq_of( + supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590, bref, 1, 65536)); + } + } + } } return SRSASN_SUCCESS; } @@ -50064,6 +53430,81 @@ void rf_params_mrdc_s::to_json(json_writer& j) const } j.end_array(); } + if (supported_band_combination_list_v1560.is_present()) { + j.start_array("supportedBandCombinationList-v1560"); + for (const auto& e1 : *supported_band_combination_list_v1560) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_nedc_only.is_present()) { + j.start_array("supportedBandCombinationListNEDC-Only"); + for (const auto& e1 : *supported_band_combination_list_nedc_only) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_v1570.is_present()) { + j.start_array("supportedBandCombinationList-v1570"); + for (const auto& e1 : *supported_band_combination_list_v1570) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_v1580.is_present()) { + j.start_array("supportedBandCombinationList-v1580"); + for (const auto& e1 : *supported_band_combination_list_v1580) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_v1590.is_present()) { + j.start_array("supportedBandCombinationList-v1590"); + for (const auto& e1 : *supported_band_combination_list_v1590) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_nedc_only_v15a0.is_present()) { + j.write_fieldname("supportedBandCombinationListNEDC-Only-v15a0"); + j.start_obj(); + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540_present) { + j.start_array("supportedBandCombinationList-v1540"); + for (const auto& e1 : supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1540) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560_present) { + j.start_array("supportedBandCombinationList-v1560"); + for (const auto& e1 : supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1560) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570_present) { + j.start_array("supportedBandCombinationList-v1570"); + for (const auto& e1 : supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1570) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580_present) { + j.start_array("supportedBandCombinationList-v1580"); + for (const auto& e1 : supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1580) { + e1.to_json(j); + } + j.end_array(); + } + if (supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590_present) { + j.start_array("supportedBandCombinationList-v1590"); + for (const auto& e1 : supported_band_combination_list_nedc_only_v15a0->supported_band_combination_list_v1590) { + e1.to_json(j); + } + j.end_array(); + } + j.end_obj(); + } } j.end_obj(); } @@ -50143,41 +53584,33 @@ void ue_cap_request_filt_nr_s::to_json(json_writer& j) const j.end_obj(); } -// GeneralParametersMRDC-XDD-Diff ::= SEQUENCE -SRSASN_CODE general_params_mrdc_xdd_diff_s::pack(bit_ref& bref) const +// UE-MRDC-CapabilityAddXDD-Mode-v1560 ::= SEQUENCE +SRSASN_CODE ue_mrdc_cap_add_xdd_mode_v1560_s::pack(bit_ref& bref) const { - bref.pack(ext, 1); - HANDLE_CODE(bref.pack(split_srb_with_one_ul_path_present, 1)); - HANDLE_CODE(bref.pack(split_drb_with_ul_both_mcg_scg_present, 1)); - HANDLE_CODE(bref.pack(srb3_present, 1)); - HANDLE_CODE(bref.pack(v2x_eutra_v1530_present, 1)); + HANDLE_CODE(bref.pack(meas_and_mob_params_mrdc_xdd_diff_v1560_present, 1)); + + if (meas_and_mob_params_mrdc_xdd_diff_v1560_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff_v1560.pack(bref)); + } return SRSASN_SUCCESS; } -SRSASN_CODE general_params_mrdc_xdd_diff_s::unpack(cbit_ref& bref) +SRSASN_CODE ue_mrdc_cap_add_xdd_mode_v1560_s::unpack(cbit_ref& bref) { - bref.unpack(ext, 1); - HANDLE_CODE(bref.unpack(split_srb_with_one_ul_path_present, 1)); - HANDLE_CODE(bref.unpack(split_drb_with_ul_both_mcg_scg_present, 1)); - HANDLE_CODE(bref.unpack(srb3_present, 1)); - HANDLE_CODE(bref.unpack(v2x_eutra_v1530_present, 1)); + HANDLE_CODE(bref.unpack(meas_and_mob_params_mrdc_xdd_diff_v1560_present, 1)); + + if (meas_and_mob_params_mrdc_xdd_diff_v1560_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff_v1560.unpack(bref)); + } return SRSASN_SUCCESS; } -void general_params_mrdc_xdd_diff_s::to_json(json_writer& j) const +void ue_mrdc_cap_add_xdd_mode_v1560_s::to_json(json_writer& j) const { j.start_obj(); - if (split_srb_with_one_ul_path_present) { - j.write_str("splitSRB-WithOneUL-Path", "supported"); - } - if (split_drb_with_ul_both_mcg_scg_present) { - j.write_str("splitDRB-withUL-Both-MCG-SCG", "supported"); - } - if (srb3_present) { - j.write_str("srb3", "supported"); - } - if (v2x_eutra_v1530_present) { - j.write_str("v2x-EUTRA-v1530", "supported"); + if (meas_and_mob_params_mrdc_xdd_diff_v1560_present) { + j.write_fieldname("measAndMobParametersMRDC-XDD-Diff-v1560"); + meas_and_mob_params_mrdc_xdd_diff_v1560.to_json(j); } j.end_obj(); } @@ -50209,66 +53642,75 @@ void pdcp_params_mrdc_s::to_json(json_writer& j) const j.end_obj(); } -// UE-MRDC-CapabilityAddFRX-Mode ::= SEQUENCE -SRSASN_CODE ue_mrdc_cap_add_frx_mode_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(meas_and_mob_params_mrdc_frx_diff.pack(bref)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE ue_mrdc_cap_add_frx_mode_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(meas_and_mob_params_mrdc_frx_diff.unpack(bref)); - - return SRSASN_SUCCESS; -} -void ue_mrdc_cap_add_frx_mode_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_fieldname("measAndMobParametersMRDC-FRX-Diff"); - meas_and_mob_params_mrdc_frx_diff.to_json(j); - j.end_obj(); -} - -// UE-MRDC-CapabilityAddXDD-Mode ::= SEQUENCE -SRSASN_CODE ue_mrdc_cap_add_xdd_mode_s::pack(bit_ref& bref) const +// UE-MRDC-Capability-v1560 ::= SEQUENCE +SRSASN_CODE ue_mrdc_cap_v1560_s::pack(bit_ref& bref) const { - HANDLE_CODE(bref.pack(meas_and_mob_params_mrdc_xdd_diff_present, 1)); - HANDLE_CODE(bref.pack(general_params_mrdc_xdd_diff_present, 1)); + HANDLE_CODE(bref.pack(rx_filts_present, 1)); + HANDLE_CODE(bref.pack(meas_and_mob_params_mrdc_v1560_present, 1)); + HANDLE_CODE(bref.pack(fdd_add_ue_mrdc_cap_v1560_present, 1)); + HANDLE_CODE(bref.pack(tdd_add_ue_mrdc_cap_v1560_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); - if (meas_and_mob_params_mrdc_xdd_diff_present) { - HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff.pack(bref)); + if (rx_filts_present) { + HANDLE_CODE(rx_filts.pack(bref)); } - if (general_params_mrdc_xdd_diff_present) { - HANDLE_CODE(general_params_mrdc_xdd_diff.pack(bref)); + if (meas_and_mob_params_mrdc_v1560_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_v1560.pack(bref)); + } + if (fdd_add_ue_mrdc_cap_v1560_present) { + HANDLE_CODE(fdd_add_ue_mrdc_cap_v1560.pack(bref)); + } + if (tdd_add_ue_mrdc_cap_v1560_present) { + HANDLE_CODE(tdd_add_ue_mrdc_cap_v1560.pack(bref)); } return SRSASN_SUCCESS; } -SRSASN_CODE ue_mrdc_cap_add_xdd_mode_s::unpack(cbit_ref& bref) +SRSASN_CODE ue_mrdc_cap_v1560_s::unpack(cbit_ref& bref) { - HANDLE_CODE(bref.unpack(meas_and_mob_params_mrdc_xdd_diff_present, 1)); - HANDLE_CODE(bref.unpack(general_params_mrdc_xdd_diff_present, 1)); + HANDLE_CODE(bref.unpack(rx_filts_present, 1)); + HANDLE_CODE(bref.unpack(meas_and_mob_params_mrdc_v1560_present, 1)); + HANDLE_CODE(bref.unpack(fdd_add_ue_mrdc_cap_v1560_present, 1)); + HANDLE_CODE(bref.unpack(tdd_add_ue_mrdc_cap_v1560_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); - if (meas_and_mob_params_mrdc_xdd_diff_present) { - HANDLE_CODE(meas_and_mob_params_mrdc_xdd_diff.unpack(bref)); + if (rx_filts_present) { + HANDLE_CODE(rx_filts.unpack(bref)); } - if (general_params_mrdc_xdd_diff_present) { - HANDLE_CODE(general_params_mrdc_xdd_diff.unpack(bref)); + if (meas_and_mob_params_mrdc_v1560_present) { + HANDLE_CODE(meas_and_mob_params_mrdc_v1560.unpack(bref)); + } + if (fdd_add_ue_mrdc_cap_v1560_present) { + HANDLE_CODE(fdd_add_ue_mrdc_cap_v1560.unpack(bref)); + } + if (tdd_add_ue_mrdc_cap_v1560_present) { + HANDLE_CODE(tdd_add_ue_mrdc_cap_v1560.unpack(bref)); } return SRSASN_SUCCESS; } -void ue_mrdc_cap_add_xdd_mode_s::to_json(json_writer& j) const +void ue_mrdc_cap_v1560_s::to_json(json_writer& j) const { j.start_obj(); - if (meas_and_mob_params_mrdc_xdd_diff_present) { - j.write_fieldname("measAndMobParametersMRDC-XDD-Diff"); - meas_and_mob_params_mrdc_xdd_diff.to_json(j); + if (rx_filts_present) { + j.write_str("receivedFilters", rx_filts.to_string()); } - if (general_params_mrdc_xdd_diff_present) { - j.write_fieldname("generalParametersMRDC-XDD-Diff"); - general_params_mrdc_xdd_diff.to_json(j); + if (meas_and_mob_params_mrdc_v1560_present) { + j.write_fieldname("measAndMobParametersMRDC-v1560"); + meas_and_mob_params_mrdc_v1560.to_json(j); + } + if (fdd_add_ue_mrdc_cap_v1560_present) { + j.write_fieldname("fdd-Add-UE-MRDC-Capabilities-v1560"); + fdd_add_ue_mrdc_cap_v1560.to_json(j); + } + if (tdd_add_ue_mrdc_cap_v1560_present) { + j.write_fieldname("tdd-Add-UE-MRDC-Capabilities-v1560"); + tdd_add_ue_mrdc_cap_v1560.to_json(j); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); } j.end_obj(); } @@ -50323,6 +53765,9 @@ SRSASN_CODE ue_mrdc_cap_s::pack(bit_ref& bref) const if (late_non_crit_ext_present) { HANDLE_CODE(late_non_crit_ext.pack(bref)); } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } return SRSASN_SUCCESS; } @@ -50375,6 +53820,9 @@ SRSASN_CODE ue_mrdc_cap_s::unpack(cbit_ref& bref) if (late_non_crit_ext_present) { HANDLE_CODE(late_non_crit_ext.unpack(bref)); } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } return SRSASN_SUCCESS; } @@ -50433,6 +53881,65 @@ void ue_mrdc_cap_s::to_json(json_writer& j) const if (late_non_crit_ext_present) { j.write_str("lateNonCriticalExtension", late_non_crit_ext.to_string()); } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); + } + j.end_obj(); +} + +// NRDC-Parameters-v1570 ::= SEQUENCE +SRSASN_CODE nrdc_params_v1570_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(sfn_sync_nrdc_present, 1)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE nrdc_params_v1570_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(sfn_sync_nrdc_present, 1)); + + return SRSASN_SUCCESS; +} +void nrdc_params_v1570_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (sfn_sync_nrdc_present) { + j.write_str("sfn-SyncNRDC", "supported"); + } + j.end_obj(); +} + +// UE-NR-Capability-v1570 ::= SEQUENCE +SRSASN_CODE ue_nr_cap_v1570_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(nrdc_params_v1570_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (nrdc_params_v1570_present) { + HANDLE_CODE(nrdc_params_v1570.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE ue_nr_cap_v1570_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(nrdc_params_v1570_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (nrdc_params_v1570_present) { + HANDLE_CODE(nrdc_params_v1570.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void ue_nr_cap_v1570_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (nrdc_params_v1570_present) { + j.write_fieldname("nrdc-Parameters-v1570"); + nrdc_params_v1570.to_json(j); + } if (non_crit_ext_present) { j.write_fieldname("nonCriticalExtension"); j.start_obj(); @@ -50441,6 +53948,60 @@ void ue_mrdc_cap_s::to_json(json_writer& j) const j.end_obj(); } +// UE-NR-Capability-v1560 ::= SEQUENCE +SRSASN_CODE ue_nr_cap_v1560_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(nrdc_params_present, 1)); + HANDLE_CODE(bref.pack(rx_filts_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (nrdc_params_present) { + HANDLE_CODE(nrdc_params.pack(bref)); + } + if (rx_filts_present) { + HANDLE_CODE(rx_filts.pack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE ue_nr_cap_v1560_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(nrdc_params_present, 1)); + HANDLE_CODE(bref.unpack(rx_filts_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (nrdc_params_present) { + HANDLE_CODE(nrdc_params.unpack(bref)); + } + if (rx_filts_present) { + HANDLE_CODE(rx_filts.unpack(bref)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void ue_nr_cap_v1560_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (nrdc_params_present) { + j.write_fieldname("nrdc-Parameters"); + nrdc_params.to_json(j); + } + if (rx_filts_present) { + j.write_str("receivedFilters", rx_filts.to_string()); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); + } + j.end_obj(); +} + // SDAP-Parameters ::= SEQUENCE SRSASN_CODE sdap_params_s::pack(bit_ref& bref) const { @@ -50471,6 +54032,10 @@ SRSASN_CODE ue_nr_cap_v1550_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(reduced_cp_latency_present, 1)); HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } + return SRSASN_SUCCESS; } SRSASN_CODE ue_nr_cap_v1550_s::unpack(cbit_ref& bref) @@ -50478,6 +54043,10 @@ SRSASN_CODE ue_nr_cap_v1550_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(reduced_cp_latency_present, 1)); HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } + return SRSASN_SUCCESS; } void ue_nr_cap_v1550_s::to_json(json_writer& j) const @@ -50488,8 +54057,7 @@ void ue_nr_cap_v1550_s::to_json(json_writer& j) const } if (non_crit_ext_present) { j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + non_crit_ext.to_json(j); } j.end_obj(); } @@ -51165,12 +54733,127 @@ void ue_nr_cap_s::to_json(json_writer& j) const j.end_obj(); } +// UE-CapabilityRequestFilterCommon ::= SEQUENCE +SRSASN_CODE ue_cap_request_filt_common_s::pack(bit_ref& bref) const +{ + bref.pack(ext, 1); + HANDLE_CODE(bref.pack(mrdc_request_present, 1)); + + if (mrdc_request_present) { + HANDLE_CODE(bref.pack(mrdc_request.omit_en_dc_present, 1)); + HANDLE_CODE(bref.pack(mrdc_request.include_nr_dc_present, 1)); + HANDLE_CODE(bref.pack(mrdc_request.include_ne_dc_present, 1)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE ue_cap_request_filt_common_s::unpack(cbit_ref& bref) +{ + bref.unpack(ext, 1); + HANDLE_CODE(bref.unpack(mrdc_request_present, 1)); + + if (mrdc_request_present) { + HANDLE_CODE(bref.unpack(mrdc_request.omit_en_dc_present, 1)); + HANDLE_CODE(bref.unpack(mrdc_request.include_nr_dc_present, 1)); + HANDLE_CODE(bref.unpack(mrdc_request.include_ne_dc_present, 1)); + } + + return SRSASN_SUCCESS; +} +void ue_cap_request_filt_common_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (mrdc_request_present) { + j.write_fieldname("mrdc-Request"); + j.start_obj(); + if (mrdc_request.omit_en_dc_present) { + j.write_str("omitEN-DC", "true"); + } + if (mrdc_request.include_nr_dc_present) { + j.write_str("includeNR-DC", "true"); + } + if (mrdc_request.include_ne_dc_present) { + j.write_str("includeNE-DC", "true"); + } + j.end_obj(); + } + j.end_obj(); +} + +// UECapabilityEnquiry-v1560-IEs ::= SEQUENCE +SRSASN_CODE ue_cap_enquiry_v1560_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(cap_request_filt_common_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (cap_request_filt_common_present) { + HANDLE_CODE(cap_request_filt_common.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE ue_cap_enquiry_v1560_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(cap_request_filt_common_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (cap_request_filt_common_present) { + HANDLE_CODE(cap_request_filt_common.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void ue_cap_enquiry_v1560_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (cap_request_filt_common_present) { + j.write_fieldname("capabilityRequestFilterCommon"); + cap_request_filt_common.to_json(j); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); +} + // AS-Config ::= SEQUENCE SRSASN_CODE as_cfg_s::pack(bit_ref& bref) const { bref.pack(ext, 1); HANDLE_CODE(rrc_recfg.pack(bref)); + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= source_rb_sn_cfg_present; + group_flags[0] |= source_scg_nr_cfg_present; + group_flags[0] |= source_scg_eutra_cfg_present; + group_flags[1] |= source_scg_cfgured_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(source_rb_sn_cfg_present, 1)); + HANDLE_CODE(bref.pack(source_scg_nr_cfg_present, 1)); + HANDLE_CODE(bref.pack(source_scg_eutra_cfg_present, 1)); + if (source_rb_sn_cfg_present) { + HANDLE_CODE(source_rb_sn_cfg.pack(bref)); + } + if (source_scg_nr_cfg_present) { + HANDLE_CODE(source_scg_nr_cfg.pack(bref)); + } + if (source_scg_eutra_cfg_present) { + HANDLE_CODE(source_scg_eutra_cfg.pack(bref)); + } + } + if (group_flags[1]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(source_scg_cfgured_present, 1)); + } + } return SRSASN_SUCCESS; } SRSASN_CODE as_cfg_s::unpack(cbit_ref& bref) @@ -51178,12 +54861,52 @@ SRSASN_CODE as_cfg_s::unpack(cbit_ref& bref) bref.unpack(ext, 1); HANDLE_CODE(rrc_recfg.unpack(bref)); + if (ext) { + ext_groups_unpacker_guard group_flags(2); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(source_rb_sn_cfg_present, 1)); + HANDLE_CODE(bref.unpack(source_scg_nr_cfg_present, 1)); + HANDLE_CODE(bref.unpack(source_scg_eutra_cfg_present, 1)); + if (source_rb_sn_cfg_present) { + HANDLE_CODE(source_rb_sn_cfg.unpack(bref)); + } + if (source_scg_nr_cfg_present) { + HANDLE_CODE(source_scg_nr_cfg.unpack(bref)); + } + if (source_scg_eutra_cfg_present) { + HANDLE_CODE(source_scg_eutra_cfg.unpack(bref)); + } + } + if (group_flags[1]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(source_scg_cfgured_present, 1)); + } + } return SRSASN_SUCCESS; } void as_cfg_s::to_json(json_writer& j) const { j.start_obj(); j.write_str("rrcReconfiguration", rrc_recfg.to_string()); + if (ext) { + if (source_rb_sn_cfg_present) { + j.write_str("sourceRB-SN-Config", source_rb_sn_cfg.to_string()); + } + if (source_scg_nr_cfg_present) { + j.write_str("sourceSCG-NR-Config", source_scg_nr_cfg.to_string()); + } + if (source_scg_eutra_cfg_present) { + j.write_str("sourceSCG-EUTRA-Config", source_scg_eutra_cfg.to_string()); + } + if (source_scg_cfgured_present) { + j.write_str("sourceSCG-Configured", "true"); + } + } j.end_obj(); } @@ -51240,6 +54963,29 @@ void reestab_ncell_info_s::to_json(json_writer& j) const j.end_obj(); } +// BandCombinationInfoSN ::= SEQUENCE +SRSASN_CODE band_combination_info_sn_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(pack_integer(bref, band_combination_idx, (uint32_t)1u, (uint32_t)65536u)); + HANDLE_CODE(pack_integer(bref, requested_feature_sets, (uint8_t)1u, (uint8_t)128u)); + + return SRSASN_SUCCESS; +} +SRSASN_CODE band_combination_info_sn_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(unpack_integer(band_combination_idx, bref, (uint32_t)1u, (uint32_t)65536u)); + HANDLE_CODE(unpack_integer(requested_feature_sets, bref, (uint8_t)1u, (uint8_t)128u)); + + return SRSASN_SUCCESS; +} +void band_combination_info_sn_s::to_json(json_writer& j) const +{ + j.start_obj(); + j.write_int("bandCombinationIndex", band_combination_idx); + j.write_int("requestedFeatureSets", requested_feature_sets); + j.end_obj(); +} + // ConfigRestrictInfoSCG ::= SEQUENCE SRSASN_CODE cfg_restrict_info_scg_s::pack(bit_ref& bref) const { @@ -51247,8 +54993,8 @@ SRSASN_CODE cfg_restrict_info_scg_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(allowed_bc_list_mrdc_present, 1)); HANDLE_CODE(bref.pack(pwr_coordination_fr1_present, 1)); HANDLE_CODE(bref.pack(serv_cell_idx_range_scg_present, 1)); - HANDLE_CODE(bref.pack(max_meas_freqs_scg_nr_present, 1)); - HANDLE_CODE(bref.pack(max_meas_identities_scg_nr_present, 1)); + HANDLE_CODE(bref.pack(max_meas_freqs_scg_present, 1)); + HANDLE_CODE(bref.pack(dummy_present, 1)); if (allowed_bc_list_mrdc_present) { HANDLE_CODE(pack_dyn_seq_of(bref, allowed_bc_list_mrdc, 1, 65536)); @@ -51271,13 +55017,55 @@ SRSASN_CODE cfg_restrict_info_scg_s::pack(bit_ref& bref) const HANDLE_CODE(pack_integer(bref, serv_cell_idx_range_scg.low_bound, (uint8_t)0u, (uint8_t)31u)); HANDLE_CODE(pack_integer(bref, serv_cell_idx_range_scg.up_bound, (uint8_t)0u, (uint8_t)31u)); } - if (max_meas_freqs_scg_nr_present) { - HANDLE_CODE(pack_integer(bref, max_meas_freqs_scg_nr, (uint8_t)1u, (uint8_t)32u)); + if (max_meas_freqs_scg_present) { + HANDLE_CODE(pack_integer(bref, max_meas_freqs_scg, (uint8_t)1u, (uint8_t)32u)); } - if (max_meas_identities_scg_nr_present) { - HANDLE_CODE(pack_integer(bref, max_meas_identities_scg_nr, (uint8_t)1u, (uint8_t)62u)); + if (dummy_present) { + HANDLE_CODE(pack_integer(bref, dummy, (uint8_t)1u, (uint8_t)62u)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= sel_band_entries_mn_list.is_present(); + group_flags[0] |= pdcch_blind_detection_scg_present; + group_flags[0] |= max_num_rohc_context_sessions_sn_present; + group_flags[1] |= max_intra_freq_meas_identities_scg_present; + group_flags[1] |= max_inter_freq_meas_identities_scg_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(sel_band_entries_mn_list.is_present(), 1)); + HANDLE_CODE(bref.pack(pdcch_blind_detection_scg_present, 1)); + HANDLE_CODE(bref.pack(max_num_rohc_context_sessions_sn_present, 1)); + if (sel_band_entries_mn_list.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, + *sel_band_entries_mn_list, + 1, + 65536, + SeqOfPacker >(1, 32, integer_packer(0, 32)))); + } + if (pdcch_blind_detection_scg_present) { + HANDLE_CODE(pack_integer(bref, pdcch_blind_detection_scg, (uint8_t)1u, (uint8_t)15u)); + } + if (max_num_rohc_context_sessions_sn_present) { + HANDLE_CODE(pack_integer(bref, max_num_rohc_context_sessions_sn, (uint16_t)0u, (uint16_t)16384u)); + } + } + if (group_flags[1]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(max_intra_freq_meas_identities_scg_present, 1)); + HANDLE_CODE(bref.pack(max_inter_freq_meas_identities_scg_present, 1)); + if (max_intra_freq_meas_identities_scg_present) { + HANDLE_CODE(pack_integer(bref, max_intra_freq_meas_identities_scg, (uint8_t)1u, (uint8_t)62u)); + } + if (max_inter_freq_meas_identities_scg_present) { + HANDLE_CODE(pack_integer(bref, max_inter_freq_meas_identities_scg, (uint8_t)1u, (uint8_t)62u)); + } + } + } return SRSASN_SUCCESS; } SRSASN_CODE cfg_restrict_info_scg_s::unpack(cbit_ref& bref) @@ -51286,8 +55074,8 @@ SRSASN_CODE cfg_restrict_info_scg_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(allowed_bc_list_mrdc_present, 1)); HANDLE_CODE(bref.unpack(pwr_coordination_fr1_present, 1)); HANDLE_CODE(bref.unpack(serv_cell_idx_range_scg_present, 1)); - HANDLE_CODE(bref.unpack(max_meas_freqs_scg_nr_present, 1)); - HANDLE_CODE(bref.unpack(max_meas_identities_scg_nr_present, 1)); + HANDLE_CODE(bref.unpack(max_meas_freqs_scg_present, 1)); + HANDLE_CODE(bref.unpack(dummy_present, 1)); if (allowed_bc_list_mrdc_present) { HANDLE_CODE(unpack_dyn_seq_of(allowed_bc_list_mrdc, bref, 1, 65536)); @@ -51310,13 +55098,52 @@ SRSASN_CODE cfg_restrict_info_scg_s::unpack(cbit_ref& bref) HANDLE_CODE(unpack_integer(serv_cell_idx_range_scg.low_bound, bref, (uint8_t)0u, (uint8_t)31u)); HANDLE_CODE(unpack_integer(serv_cell_idx_range_scg.up_bound, bref, (uint8_t)0u, (uint8_t)31u)); } - if (max_meas_freqs_scg_nr_present) { - HANDLE_CODE(unpack_integer(max_meas_freqs_scg_nr, bref, (uint8_t)1u, (uint8_t)32u)); + if (max_meas_freqs_scg_present) { + HANDLE_CODE(unpack_integer(max_meas_freqs_scg, bref, (uint8_t)1u, (uint8_t)32u)); } - if (max_meas_identities_scg_nr_present) { - HANDLE_CODE(unpack_integer(max_meas_identities_scg_nr, bref, (uint8_t)1u, (uint8_t)62u)); + if (dummy_present) { + HANDLE_CODE(unpack_integer(dummy, bref, (uint8_t)1u, (uint8_t)62u)); } + if (ext) { + ext_groups_unpacker_guard group_flags(2); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool sel_band_entries_mn_list_present; + HANDLE_CODE(bref.unpack(sel_band_entries_mn_list_present, 1)); + sel_band_entries_mn_list.set_present(sel_band_entries_mn_list_present); + HANDLE_CODE(bref.unpack(pdcch_blind_detection_scg_present, 1)); + HANDLE_CODE(bref.unpack(max_num_rohc_context_sessions_sn_present, 1)); + if (sel_band_entries_mn_list.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*sel_band_entries_mn_list, + bref, + 1, + 65536, + SeqOfPacker >(1, 32, integer_packer(0, 32)))); + } + if (pdcch_blind_detection_scg_present) { + HANDLE_CODE(unpack_integer(pdcch_blind_detection_scg, bref, (uint8_t)1u, (uint8_t)15u)); + } + if (max_num_rohc_context_sessions_sn_present) { + HANDLE_CODE(unpack_integer(max_num_rohc_context_sessions_sn, bref, (uint16_t)0u, (uint16_t)16384u)); + } + } + if (group_flags[1]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(max_intra_freq_meas_identities_scg_present, 1)); + HANDLE_CODE(bref.unpack(max_inter_freq_meas_identities_scg_present, 1)); + if (max_intra_freq_meas_identities_scg_present) { + HANDLE_CODE(unpack_integer(max_intra_freq_meas_identities_scg, bref, (uint8_t)1u, (uint8_t)62u)); + } + if (max_inter_freq_meas_identities_scg_present) { + HANDLE_CODE(unpack_integer(max_inter_freq_meas_identities_scg, bref, (uint8_t)1u, (uint8_t)62u)); + } + } + } return SRSASN_SUCCESS; } void cfg_restrict_info_scg_s::to_json(json_writer& j) const @@ -51350,11 +55177,36 @@ void cfg_restrict_info_scg_s::to_json(json_writer& j) const j.write_int("upBound", serv_cell_idx_range_scg.up_bound); j.end_obj(); } - if (max_meas_freqs_scg_nr_present) { - j.write_int("maxMeasFreqsSCG-NR", max_meas_freqs_scg_nr); + if (max_meas_freqs_scg_present) { + j.write_int("maxMeasFreqsSCG", max_meas_freqs_scg); } - if (max_meas_identities_scg_nr_present) { - j.write_int("maxMeasIdentitiesSCG-NR", max_meas_identities_scg_nr); + if (dummy_present) { + j.write_int("dummy", dummy); + } + if (ext) { + if (sel_band_entries_mn_list.is_present()) { + j.start_array("selectedBandEntriesMNList"); + for (const auto& e1 : *sel_band_entries_mn_list) { + j.start_array(); + for (const auto& e2 : e1) { + j.write_int(e2); + } + j.end_array(); + } + j.end_array(); + } + if (pdcch_blind_detection_scg_present) { + j.write_int("pdcch-BlindDetectionSCG", pdcch_blind_detection_scg); + } + if (max_num_rohc_context_sessions_sn_present) { + j.write_int("maxNumberROHC-ContextSessionsSN", max_num_rohc_context_sessions_sn); + } + if (max_intra_freq_meas_identities_scg_present) { + j.write_int("maxIntraFreqMeasIdentitiesSCG", max_intra_freq_meas_identities_scg); + } + if (max_inter_freq_meas_identities_scg_present) { + j.write_int("maxInterFreqMeasIdentitiesSCG", max_inter_freq_meas_identities_scg); + } } j.end_obj(); } @@ -51417,6 +55269,7 @@ SRSASN_CODE as_context_s::pack(bit_ref& bref) const ext_groups_packer_guard group_flags; group_flags[0] |= ran_notif_area_info.is_present(); group_flags[1] |= ue_assist_info_present; + group_flags[2] |= sel_band_combination_sn.is_present(); group_flags.pack(bref); if (group_flags[0]) { @@ -51435,6 +55288,14 @@ SRSASN_CODE as_context_s::pack(bit_ref& bref) const HANDLE_CODE(ue_assist_info.pack(bref)); } } + if (group_flags[2]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(sel_band_combination_sn.is_present(), 1)); + if (sel_band_combination_sn.is_present()) { + HANDLE_CODE(sel_band_combination_sn->pack(bref)); + } + } } return SRSASN_SUCCESS; } @@ -51452,7 +55313,7 @@ SRSASN_CODE as_context_s::unpack(cbit_ref& bref) } if (ext) { - ext_groups_unpacker_guard group_flags(2); + ext_groups_unpacker_guard group_flags(3); group_flags.unpack(bref); if (group_flags[0]) { @@ -51473,6 +55334,16 @@ SRSASN_CODE as_context_s::unpack(cbit_ref& bref) HANDLE_CODE(ue_assist_info.unpack(bref)); } } + if (group_flags[2]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool sel_band_combination_sn_present; + HANDLE_CODE(bref.unpack(sel_band_combination_sn_present, 1)); + sel_band_combination_sn.set_present(sel_band_combination_sn_present); + if (sel_band_combination_sn.is_present()) { + HANDLE_CODE(sel_band_combination_sn->unpack(bref)); + } + } } return SRSASN_SUCCESS; } @@ -51495,6 +55366,10 @@ void as_context_s::to_json(json_writer& j) const if (ue_assist_info_present) { j.write_str("ueAssistanceInformation", ue_assist_info.to_string()); } + if (sel_band_combination_sn.is_present()) { + j.write_fieldname("selectedBandCombinationSN"); + sel_band_combination_sn->to_json(j); + } } j.end_obj(); } @@ -51627,29 +55502,6 @@ std::string affected_carrier_freq_comb_info_mrdc_s::interference_direction_mrdc_ return convert_enum_idx(options, 8, value, "affected_carrier_freq_comb_info_mrdc_s::interference_direction_mrdc_e_"); } -// BandCombinationInfoSN ::= SEQUENCE -SRSASN_CODE band_combination_info_sn_s::pack(bit_ref& bref) const -{ - HANDLE_CODE(pack_integer(bref, band_combination_idx, (uint32_t)1u, (uint32_t)65536u)); - HANDLE_CODE(pack_integer(bref, requested_feature_sets, (uint8_t)1u, (uint8_t)128u)); - - return SRSASN_SUCCESS; -} -SRSASN_CODE band_combination_info_sn_s::unpack(cbit_ref& bref) -{ - HANDLE_CODE(unpack_integer(band_combination_idx, bref, (uint32_t)1u, (uint32_t)65536u)); - HANDLE_CODE(unpack_integer(requested_feature_sets, bref, (uint8_t)1u, (uint8_t)128u)); - - return SRSASN_SUCCESS; -} -void band_combination_info_sn_s::to_json(json_writer& j) const -{ - j.start_obj(); - j.write_int("bandCombinationIndex", band_combination_idx); - j.write_int("requestedFeatureSets", requested_feature_sets); - j.end_obj(); -} - // PH-UplinkCarrierSCG ::= SEQUENCE SRSASN_CODE ph_ul_carrier_scg_s::pack(bit_ref& bref) const { @@ -51683,6 +55535,62 @@ uint8_t ph_ul_carrier_scg_s::ph_type1or3_opts::to_number() const return map_enum_number(options, 2, value, "ph_ul_carrier_scg_s::ph_type1or3_e_"); } +// CG-Config-v1590-IEs ::= SEQUENCE +SRSASN_CODE cg_cfg_v1590_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(scell_frequencies_sn_nr_present, 1)); + HANDLE_CODE(bref.pack(scell_frequencies_sn_eutra_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (scell_frequencies_sn_nr_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, scell_frequencies_sn_nr, 1, 31, integer_packer(0, 3279165))); + } + if (scell_frequencies_sn_eutra_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, scell_frequencies_sn_eutra, 1, 31, integer_packer(0, 262143))); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE cg_cfg_v1590_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(scell_frequencies_sn_nr_present, 1)); + HANDLE_CODE(bref.unpack(scell_frequencies_sn_eutra_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (scell_frequencies_sn_nr_present) { + HANDLE_CODE(unpack_dyn_seq_of(scell_frequencies_sn_nr, bref, 1, 31, integer_packer(0, 3279165))); + } + if (scell_frequencies_sn_eutra_present) { + HANDLE_CODE(unpack_dyn_seq_of(scell_frequencies_sn_eutra, bref, 1, 31, integer_packer(0, 262143))); + } + + return SRSASN_SUCCESS; +} +void cg_cfg_v1590_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (scell_frequencies_sn_nr_present) { + j.start_array("scellFrequenciesSN-NR"); + for (const auto& e1 : scell_frequencies_sn_nr) { + j.write_int(e1); + } + j.end_array(); + } + if (scell_frequencies_sn_eutra_present) { + j.start_array("scellFrequenciesSN-EUTRA"); + for (const auto& e1 : scell_frequencies_sn_eutra) { + j.write_int(e1); + } + j.end_array(); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); +} + // PH-InfoSCG ::= SEQUENCE SRSASN_CODE ph_info_scg_s::pack(bit_ref& bref) const { @@ -51723,6 +55631,139 @@ void ph_info_scg_s::to_json(json_writer& j) const j.end_obj(); } +// CG-Config-v1560-IEs ::= SEQUENCE +SRSASN_CODE cg_cfg_v1560_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(pscell_freq_eutra_present, 1)); + HANDLE_CODE(bref.pack(scg_cell_group_cfg_eutra_present, 1)); + HANDLE_CODE(bref.pack(candidate_cell_info_list_sn_eutra_present, 1)); + HANDLE_CODE(bref.pack(candidate_serving_freq_list_eutra_present, 1)); + HANDLE_CODE(bref.pack(need_for_gaps_present, 1)); + HANDLE_CODE(bref.pack(drx_cfg_scg_present, 1)); + HANDLE_CODE(bref.pack(report_cgi_request_eutra_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (pscell_freq_eutra_present) { + HANDLE_CODE(pack_integer(bref, pscell_freq_eutra, (uint32_t)0u, (uint32_t)262143u)); + } + if (scg_cell_group_cfg_eutra_present) { + HANDLE_CODE(scg_cell_group_cfg_eutra.pack(bref)); + } + if (candidate_cell_info_list_sn_eutra_present) { + HANDLE_CODE(candidate_cell_info_list_sn_eutra.pack(bref)); + } + if (candidate_serving_freq_list_eutra_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, candidate_serving_freq_list_eutra, 1, 32, integer_packer(0, 262143))); + } + if (drx_cfg_scg_present) { + HANDLE_CODE(drx_cfg_scg.pack(bref)); + } + if (report_cgi_request_eutra_present) { + HANDLE_CODE(bref.pack(report_cgi_request_eutra.requested_cell_info_eutra_present, 1)); + if (report_cgi_request_eutra.requested_cell_info_eutra_present) { + HANDLE_CODE(pack_integer( + bref, report_cgi_request_eutra.requested_cell_info_eutra.eutra_freq, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(pack_integer(bref, + report_cgi_request_eutra.requested_cell_info_eutra.cell_for_which_to_report_cgi_eutra, + (uint16_t)0u, + (uint16_t)503u)); + } + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE cg_cfg_v1560_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(pscell_freq_eutra_present, 1)); + HANDLE_CODE(bref.unpack(scg_cell_group_cfg_eutra_present, 1)); + HANDLE_CODE(bref.unpack(candidate_cell_info_list_sn_eutra_present, 1)); + HANDLE_CODE(bref.unpack(candidate_serving_freq_list_eutra_present, 1)); + HANDLE_CODE(bref.unpack(need_for_gaps_present, 1)); + HANDLE_CODE(bref.unpack(drx_cfg_scg_present, 1)); + HANDLE_CODE(bref.unpack(report_cgi_request_eutra_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (pscell_freq_eutra_present) { + HANDLE_CODE(unpack_integer(pscell_freq_eutra, bref, (uint32_t)0u, (uint32_t)262143u)); + } + if (scg_cell_group_cfg_eutra_present) { + HANDLE_CODE(scg_cell_group_cfg_eutra.unpack(bref)); + } + if (candidate_cell_info_list_sn_eutra_present) { + HANDLE_CODE(candidate_cell_info_list_sn_eutra.unpack(bref)); + } + if (candidate_serving_freq_list_eutra_present) { + HANDLE_CODE(unpack_dyn_seq_of(candidate_serving_freq_list_eutra, bref, 1, 32, integer_packer(0, 262143))); + } + if (drx_cfg_scg_present) { + HANDLE_CODE(drx_cfg_scg.unpack(bref)); + } + if (report_cgi_request_eutra_present) { + HANDLE_CODE(bref.unpack(report_cgi_request_eutra.requested_cell_info_eutra_present, 1)); + if (report_cgi_request_eutra.requested_cell_info_eutra_present) { + HANDLE_CODE(unpack_integer( + report_cgi_request_eutra.requested_cell_info_eutra.eutra_freq, bref, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(unpack_integer(report_cgi_request_eutra.requested_cell_info_eutra.cell_for_which_to_report_cgi_eutra, + bref, + (uint16_t)0u, + (uint16_t)503u)); + } + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void cg_cfg_v1560_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (pscell_freq_eutra_present) { + j.write_int("pSCellFrequencyEUTRA", pscell_freq_eutra); + } + if (scg_cell_group_cfg_eutra_present) { + j.write_str("scg-CellGroupConfigEUTRA", scg_cell_group_cfg_eutra.to_string()); + } + if (candidate_cell_info_list_sn_eutra_present) { + j.write_str("candidateCellInfoListSN-EUTRA", candidate_cell_info_list_sn_eutra.to_string()); + } + if (candidate_serving_freq_list_eutra_present) { + j.start_array("candidateServingFreqListEUTRA"); + for (const auto& e1 : candidate_serving_freq_list_eutra) { + j.write_int(e1); + } + j.end_array(); + } + if (need_for_gaps_present) { + j.write_str("needForGaps", "true"); + } + if (drx_cfg_scg_present) { + j.write_fieldname("drx-ConfigSCG"); + drx_cfg_scg.to_json(j); + } + if (report_cgi_request_eutra_present) { + j.write_fieldname("reportCGI-RequestEUTRA"); + j.start_obj(); + if (report_cgi_request_eutra.requested_cell_info_eutra_present) { + j.write_fieldname("requestedCellInfoEUTRA"); + j.start_obj(); + j.write_int("eutraFrequency", report_cgi_request_eutra.requested_cell_info_eutra.eutra_freq); + j.write_int("cellForWhichToReportCGI-EUTRA", + report_cgi_request_eutra.requested_cell_info_eutra.cell_for_which_to_report_cgi_eutra); + j.end_obj(); + } + j.end_obj(); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); + } + j.end_obj(); +} + // FR-Info ::= SEQUENCE SRSASN_CODE fr_info_s::pack(bit_ref& bref) const { @@ -51793,50 +55834,56 @@ void nr_freq_info_s::to_json(json_writer& j) const SRSASN_CODE cg_cfg_v1540_ies_s::pack(bit_ref& bref) const { HANDLE_CODE(bref.pack(pscell_freq_present, 1)); - HANDLE_CODE(bref.pack(report_cgi_request_present, 1)); + HANDLE_CODE(bref.pack(report_cgi_request_nr_present, 1)); HANDLE_CODE(bref.pack(ph_info_scg_present, 1)); HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); if (pscell_freq_present) { HANDLE_CODE(pack_integer(bref, pscell_freq, (uint32_t)0u, (uint32_t)3279165u)); } - if (report_cgi_request_present) { - HANDLE_CODE(bref.pack(report_cgi_request.requested_cell_info_present, 1)); - if (report_cgi_request.requested_cell_info_present) { + if (report_cgi_request_nr_present) { + HANDLE_CODE(bref.pack(report_cgi_request_nr.requested_cell_info_present, 1)); + if (report_cgi_request_nr.requested_cell_info_present) { HANDLE_CODE( - pack_integer(bref, report_cgi_request.requested_cell_info.ssb_freq, (uint32_t)0u, (uint32_t)3279165u)); + pack_integer(bref, report_cgi_request_nr.requested_cell_info.ssb_freq, (uint32_t)0u, (uint32_t)3279165u)); HANDLE_CODE(pack_integer( - bref, report_cgi_request.requested_cell_info.cell_for_which_to_report_cgi, (uint16_t)0u, (uint16_t)1007u)); + bref, report_cgi_request_nr.requested_cell_info.cell_for_which_to_report_cgi, (uint16_t)0u, (uint16_t)1007u)); } } if (ph_info_scg_present) { HANDLE_CODE(pack_dyn_seq_of(bref, ph_info_scg, 1, 32)); } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } return SRSASN_SUCCESS; } SRSASN_CODE cg_cfg_v1540_ies_s::unpack(cbit_ref& bref) { HANDLE_CODE(bref.unpack(pscell_freq_present, 1)); - HANDLE_CODE(bref.unpack(report_cgi_request_present, 1)); + HANDLE_CODE(bref.unpack(report_cgi_request_nr_present, 1)); HANDLE_CODE(bref.unpack(ph_info_scg_present, 1)); HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); if (pscell_freq_present) { HANDLE_CODE(unpack_integer(pscell_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); } - if (report_cgi_request_present) { - HANDLE_CODE(bref.unpack(report_cgi_request.requested_cell_info_present, 1)); - if (report_cgi_request.requested_cell_info_present) { + if (report_cgi_request_nr_present) { + HANDLE_CODE(bref.unpack(report_cgi_request_nr.requested_cell_info_present, 1)); + if (report_cgi_request_nr.requested_cell_info_present) { HANDLE_CODE( - unpack_integer(report_cgi_request.requested_cell_info.ssb_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); + unpack_integer(report_cgi_request_nr.requested_cell_info.ssb_freq, bref, (uint32_t)0u, (uint32_t)3279165u)); HANDLE_CODE(unpack_integer( - report_cgi_request.requested_cell_info.cell_for_which_to_report_cgi, bref, (uint16_t)0u, (uint16_t)1007u)); + report_cgi_request_nr.requested_cell_info.cell_for_which_to_report_cgi, bref, (uint16_t)0u, (uint16_t)1007u)); } } if (ph_info_scg_present) { HANDLE_CODE(unpack_dyn_seq_of(ph_info_scg, bref, 1, 32)); } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } return SRSASN_SUCCESS; } @@ -51846,14 +55893,14 @@ void cg_cfg_v1540_ies_s::to_json(json_writer& j) const if (pscell_freq_present) { j.write_int("pSCellFrequency", pscell_freq); } - if (report_cgi_request_present) { - j.write_fieldname("reportCGI-Request"); + if (report_cgi_request_nr_present) { + j.write_fieldname("reportCGI-RequestNR"); j.start_obj(); - if (report_cgi_request.requested_cell_info_present) { + if (report_cgi_request_nr.requested_cell_info_present) { j.write_fieldname("requestedCellInfo"); j.start_obj(); - j.write_int("ssbFrequency", report_cgi_request.requested_cell_info.ssb_freq); - j.write_int("cellForWhichToReportCGI", report_cgi_request.requested_cell_info.cell_for_which_to_report_cgi); + j.write_int("ssbFrequency", report_cgi_request_nr.requested_cell_info.ssb_freq); + j.write_int("cellForWhichToReportCGI", report_cgi_request_nr.requested_cell_info.cell_for_which_to_report_cgi); j.end_obj(); } j.end_obj(); @@ -51867,8 +55914,7 @@ void cg_cfg_v1540_ies_s::to_json(json_writer& j) const } if (non_crit_ext_present) { j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + non_crit_ext.to_json(j); } j.end_obj(); } @@ -51887,6 +55933,25 @@ SRSASN_CODE cfg_restrict_mod_req_scg_s::pack(bit_ref& bref) const HANDLE_CODE(pack_integer(bref, requested_p_max_fr1, (int8_t)-30, (int8_t)33)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= requested_pdcch_blind_detection_scg_present; + group_flags[0] |= requested_p_max_eutra_present; + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(requested_pdcch_blind_detection_scg_present, 1)); + HANDLE_CODE(bref.pack(requested_p_max_eutra_present, 1)); + if (requested_pdcch_blind_detection_scg_present) { + HANDLE_CODE(pack_integer(bref, requested_pdcch_blind_detection_scg, (uint8_t)1u, (uint8_t)15u)); + } + if (requested_p_max_eutra_present) { + HANDLE_CODE(pack_integer(bref, requested_p_max_eutra, (int8_t)-30, (int8_t)33)); + } + } + } return SRSASN_SUCCESS; } SRSASN_CODE cfg_restrict_mod_req_scg_s::unpack(cbit_ref& bref) @@ -51902,6 +55967,23 @@ SRSASN_CODE cfg_restrict_mod_req_scg_s::unpack(cbit_ref& bref) HANDLE_CODE(unpack_integer(requested_p_max_fr1, bref, (int8_t)-30, (int8_t)33)); } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.unpack(requested_pdcch_blind_detection_scg_present, 1)); + HANDLE_CODE(bref.unpack(requested_p_max_eutra_present, 1)); + if (requested_pdcch_blind_detection_scg_present) { + HANDLE_CODE(unpack_integer(requested_pdcch_blind_detection_scg, bref, (uint8_t)1u, (uint8_t)15u)); + } + if (requested_p_max_eutra_present) { + HANDLE_CODE(unpack_integer(requested_p_max_eutra, bref, (int8_t)-30, (int8_t)33)); + } + } + } return SRSASN_SUCCESS; } void cfg_restrict_mod_req_scg_s::to_json(json_writer& j) const @@ -51914,6 +55996,14 @@ void cfg_restrict_mod_req_scg_s::to_json(json_writer& j) const if (requested_p_max_fr1_present) { j.write_int("requestedP-MaxFR1", requested_p_max_fr1); } + if (ext) { + if (requested_pdcch_blind_detection_scg_present) { + j.write_int("requestedPDCCH-BlindDetectionSCG", requested_pdcch_blind_detection_scg); + } + if (requested_p_max_eutra_present) { + j.write_int("requestedP-MaxEUTRA", requested_p_max_eutra); + } + } j.end_obj(); } @@ -52034,8 +56124,8 @@ drx_info_s::drx_long_cycle_start_offset_c_::drx_long_cycle_start_offset_c_( log_invalid_choice_id(type_, "drx_info_s::drx_long_cycle_start_offset_c_"); } } -drx_info_s::drx_long_cycle_start_offset_c_& drx_info_s::drx_long_cycle_start_offset_c_:: - operator=(const drx_info_s::drx_long_cycle_start_offset_c_& other) +drx_info_s::drx_long_cycle_start_offset_c_& +drx_info_s::drx_long_cycle_start_offset_c_::operator=(const drx_info_s::drx_long_cycle_start_offset_c_& other) { if (this == &other) { return *this; @@ -52396,7 +56486,7 @@ SRSASN_CODE cg_cfg_ies_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(drx_info_scg_present, 1)); HANDLE_CODE(bref.pack(candidate_cell_info_list_sn_present, 1)); HANDLE_CODE(bref.pack(meas_cfg_sn_present, 1)); - HANDLE_CODE(bref.pack(sel_band_combination_nr_present, 1)); + HANDLE_CODE(bref.pack(sel_band_combination_present, 1)); HANDLE_CODE(bref.pack(fr_info_list_scg_present, 1)); HANDLE_CODE(bref.pack(candidate_serving_freq_list_nr_present, 1)); HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); @@ -52419,8 +56509,8 @@ SRSASN_CODE cg_cfg_ies_s::pack(bit_ref& bref) const if (meas_cfg_sn_present) { HANDLE_CODE(meas_cfg_sn.pack(bref)); } - if (sel_band_combination_nr_present) { - HANDLE_CODE(sel_band_combination_nr.pack(bref)); + if (sel_band_combination_present) { + HANDLE_CODE(sel_band_combination.pack(bref)); } if (fr_info_list_scg_present) { HANDLE_CODE(pack_dyn_seq_of(bref, fr_info_list_scg, 1, 31)); @@ -52442,7 +56532,7 @@ SRSASN_CODE cg_cfg_ies_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(drx_info_scg_present, 1)); HANDLE_CODE(bref.unpack(candidate_cell_info_list_sn_present, 1)); HANDLE_CODE(bref.unpack(meas_cfg_sn_present, 1)); - HANDLE_CODE(bref.unpack(sel_band_combination_nr_present, 1)); + HANDLE_CODE(bref.unpack(sel_band_combination_present, 1)); HANDLE_CODE(bref.unpack(fr_info_list_scg_present, 1)); HANDLE_CODE(bref.unpack(candidate_serving_freq_list_nr_present, 1)); HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); @@ -52465,8 +56555,8 @@ SRSASN_CODE cg_cfg_ies_s::unpack(cbit_ref& bref) if (meas_cfg_sn_present) { HANDLE_CODE(meas_cfg_sn.unpack(bref)); } - if (sel_band_combination_nr_present) { - HANDLE_CODE(sel_band_combination_nr.unpack(bref)); + if (sel_band_combination_present) { + HANDLE_CODE(sel_band_combination.unpack(bref)); } if (fr_info_list_scg_present) { HANDLE_CODE(unpack_dyn_seq_of(fr_info_list_scg, bref, 1, 31)); @@ -52504,9 +56594,9 @@ void cg_cfg_ies_s::to_json(json_writer& j) const j.write_fieldname("measConfigSN"); meas_cfg_sn.to_json(j); } - if (sel_band_combination_nr_present) { - j.write_fieldname("selectedBandCombinationNR"); - sel_band_combination_nr.to_json(j); + if (sel_band_combination_present) { + j.write_fieldname("selectedBandCombination"); + sel_band_combination.to_json(j); } if (fr_info_list_scg_present) { j.start_array("fr-InfoListSCG"); @@ -52740,6 +56830,47 @@ uint8_t cg_cfg_s::crit_exts_c_::types_opts::to_number() const return map_enum_number(options, 1, value, "cg_cfg_s::crit_exts_c_::types"); } +// CG-ConfigInfo-v1590-IEs ::= SEQUENCE +SRSASN_CODE cg_cfg_info_v1590_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(serv_frequencies_mn_nr_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (serv_frequencies_mn_nr_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, serv_frequencies_mn_nr, 1, 31, integer_packer(0, 3279165))); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE cg_cfg_info_v1590_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(serv_frequencies_mn_nr_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (serv_frequencies_mn_nr_present) { + HANDLE_CODE(unpack_dyn_seq_of(serv_frequencies_mn_nr, bref, 1, 31, integer_packer(0, 3279165))); + } + + return SRSASN_SUCCESS; +} +void cg_cfg_info_v1590_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (serv_frequencies_mn_nr_present) { + j.start_array("servFrequenciesMN-NR"); + for (const auto& e1 : serv_frequencies_mn_nr) { + j.write_int(e1); + } + j.end_array(); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + j.start_obj(); + j.end_obj(); + } + j.end_obj(); +} + // PH-UplinkCarrierMCG ::= SEQUENCE SRSASN_CODE ph_ul_carrier_mcg_s::pack(bit_ref& bref) const { @@ -52773,6 +56904,67 @@ uint8_t ph_ul_carrier_mcg_s::ph_type1or3_opts::to_number() const return map_enum_number(options, 2, value, "ph_ul_carrier_mcg_s::ph_type1or3_e_"); } +// CG-ConfigInfo-v1570-IEs ::= SEQUENCE +SRSASN_CODE cg_cfg_info_v1570_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(sftd_freq_list_nr_present, 1)); + HANDLE_CODE(bref.pack(sftd_freq_list_eutra_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (sftd_freq_list_nr_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sftd_freq_list_nr, 1, 3, integer_packer(0, 3279165))); + } + if (sftd_freq_list_eutra_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, sftd_freq_list_eutra, 1, 3, integer_packer(0, 262143))); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE cg_cfg_info_v1570_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(sftd_freq_list_nr_present, 1)); + HANDLE_CODE(bref.unpack(sftd_freq_list_eutra_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (sftd_freq_list_nr_present) { + HANDLE_CODE(unpack_dyn_seq_of(sftd_freq_list_nr, bref, 1, 3, integer_packer(0, 3279165))); + } + if (sftd_freq_list_eutra_present) { + HANDLE_CODE(unpack_dyn_seq_of(sftd_freq_list_eutra, bref, 1, 3, integer_packer(0, 262143))); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void cg_cfg_info_v1570_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (sftd_freq_list_nr_present) { + j.start_array("sftdFrequencyList-NR"); + for (const auto& e1 : sftd_freq_list_nr) { + j.write_int(e1); + } + j.end_array(); + } + if (sftd_freq_list_eutra_present) { + j.start_array("sftdFrequencyList-EUTRA"); + for (const auto& e1 : sftd_freq_list_eutra) { + j.write_int(e1); + } + j.end_array(); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); + } + j.end_obj(); +} + // PH-InfoMCG ::= SEQUENCE SRSASN_CODE ph_info_mcg_s::pack(bit_ref& bref) const { @@ -52813,6 +57005,163 @@ void ph_info_mcg_s::to_json(json_writer& j) const j.end_obj(); } +// CG-ConfigInfo-v1560-IEs ::= SEQUENCE +SRSASN_CODE cg_cfg_info_v1560_ies_s::pack(bit_ref& bref) const +{ + HANDLE_CODE(bref.pack(candidate_cell_info_list_mn_eutra_present, 1)); + HANDLE_CODE(bref.pack(candidate_cell_info_list_sn_eutra_present, 1)); + HANDLE_CODE(bref.pack(source_cfg_scg_eutra_present, 1)); + HANDLE_CODE(bref.pack(scg_fail_info_eutra_present, 1)); + HANDLE_CODE(bref.pack(drx_cfg_mcg_present, 1)); + HANDLE_CODE(bref.pack(meas_result_report_cgi_eutra_present, 1)); + HANDLE_CODE(bref.pack(meas_result_cell_list_sftd_eutra_present, 1)); + HANDLE_CODE(bref.pack(fr_info_list_mcg_present, 1)); + HANDLE_CODE(bref.pack(non_crit_ext_present, 1)); + + if (candidate_cell_info_list_mn_eutra_present) { + HANDLE_CODE(candidate_cell_info_list_mn_eutra.pack(bref)); + } + if (candidate_cell_info_list_sn_eutra_present) { + HANDLE_CODE(candidate_cell_info_list_sn_eutra.pack(bref)); + } + if (source_cfg_scg_eutra_present) { + HANDLE_CODE(source_cfg_scg_eutra.pack(bref)); + } + if (scg_fail_info_eutra_present) { + HANDLE_CODE(scg_fail_info_eutra.fail_type_eutra.pack(bref)); + HANDLE_CODE(scg_fail_info_eutra.meas_result_scg_eutra.pack(bref)); + } + if (drx_cfg_mcg_present) { + HANDLE_CODE(drx_cfg_mcg.pack(bref)); + } + if (meas_result_report_cgi_eutra_present) { + HANDLE_CODE(pack_integer(bref, meas_result_report_cgi_eutra.eutra_freq, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(pack_integer( + bref, meas_result_report_cgi_eutra.cell_for_which_to_report_cgi_eutra, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(meas_result_report_cgi_eutra.cgi_info_eutra.pack(bref)); + } + if (meas_result_cell_list_sftd_eutra_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_cell_list_sftd_eutra, 1, 3)); + } + if (fr_info_list_mcg_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, fr_info_list_mcg, 1, 31)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } + + return SRSASN_SUCCESS; +} +SRSASN_CODE cg_cfg_info_v1560_ies_s::unpack(cbit_ref& bref) +{ + HANDLE_CODE(bref.unpack(candidate_cell_info_list_mn_eutra_present, 1)); + HANDLE_CODE(bref.unpack(candidate_cell_info_list_sn_eutra_present, 1)); + HANDLE_CODE(bref.unpack(source_cfg_scg_eutra_present, 1)); + HANDLE_CODE(bref.unpack(scg_fail_info_eutra_present, 1)); + HANDLE_CODE(bref.unpack(drx_cfg_mcg_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_report_cgi_eutra_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_cell_list_sftd_eutra_present, 1)); + HANDLE_CODE(bref.unpack(fr_info_list_mcg_present, 1)); + HANDLE_CODE(bref.unpack(non_crit_ext_present, 1)); + + if (candidate_cell_info_list_mn_eutra_present) { + HANDLE_CODE(candidate_cell_info_list_mn_eutra.unpack(bref)); + } + if (candidate_cell_info_list_sn_eutra_present) { + HANDLE_CODE(candidate_cell_info_list_sn_eutra.unpack(bref)); + } + if (source_cfg_scg_eutra_present) { + HANDLE_CODE(source_cfg_scg_eutra.unpack(bref)); + } + if (scg_fail_info_eutra_present) { + HANDLE_CODE(scg_fail_info_eutra.fail_type_eutra.unpack(bref)); + HANDLE_CODE(scg_fail_info_eutra.meas_result_scg_eutra.unpack(bref)); + } + if (drx_cfg_mcg_present) { + HANDLE_CODE(drx_cfg_mcg.unpack(bref)); + } + if (meas_result_report_cgi_eutra_present) { + HANDLE_CODE(unpack_integer(meas_result_report_cgi_eutra.eutra_freq, bref, (uint32_t)0u, (uint32_t)262143u)); + HANDLE_CODE(unpack_integer( + meas_result_report_cgi_eutra.cell_for_which_to_report_cgi_eutra, bref, (uint16_t)0u, (uint16_t)503u)); + HANDLE_CODE(meas_result_report_cgi_eutra.cgi_info_eutra.unpack(bref)); + } + if (meas_result_cell_list_sftd_eutra_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_result_cell_list_sftd_eutra, bref, 1, 3)); + } + if (fr_info_list_mcg_present) { + HANDLE_CODE(unpack_dyn_seq_of(fr_info_list_mcg, bref, 1, 31)); + } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } + + return SRSASN_SUCCESS; +} +void cg_cfg_info_v1560_ies_s::to_json(json_writer& j) const +{ + j.start_obj(); + if (candidate_cell_info_list_mn_eutra_present) { + j.write_str("candidateCellInfoListMN-EUTRA", candidate_cell_info_list_mn_eutra.to_string()); + } + if (candidate_cell_info_list_sn_eutra_present) { + j.write_str("candidateCellInfoListSN-EUTRA", candidate_cell_info_list_sn_eutra.to_string()); + } + if (source_cfg_scg_eutra_present) { + j.write_str("sourceConfigSCG-EUTRA", source_cfg_scg_eutra.to_string()); + } + if (scg_fail_info_eutra_present) { + j.write_fieldname("scgFailureInfoEUTRA"); + j.start_obj(); + j.write_str("failureTypeEUTRA", scg_fail_info_eutra.fail_type_eutra.to_string()); + j.write_str("measResultSCG-EUTRA", scg_fail_info_eutra.meas_result_scg_eutra.to_string()); + j.end_obj(); + } + if (drx_cfg_mcg_present) { + j.write_fieldname("drx-ConfigMCG"); + drx_cfg_mcg.to_json(j); + } + if (meas_result_report_cgi_eutra_present) { + j.write_fieldname("measResultReportCGI-EUTRA"); + j.start_obj(); + j.write_int("eutraFrequency", meas_result_report_cgi_eutra.eutra_freq); + j.write_int("cellForWhichToReportCGI-EUTRA", meas_result_report_cgi_eutra.cell_for_which_to_report_cgi_eutra); + j.write_fieldname("cgi-InfoEUTRA"); + meas_result_report_cgi_eutra.cgi_info_eutra.to_json(j); + j.end_obj(); + } + if (meas_result_cell_list_sftd_eutra_present) { + j.start_array("measResultCellListSFTD-EUTRA"); + for (const auto& e1 : meas_result_cell_list_sftd_eutra) { + e1.to_json(j); + } + j.end_array(); + } + if (fr_info_list_mcg_present) { + j.start_array("fr-InfoListMCG"); + for (const auto& e1 : fr_info_list_mcg) { + e1.to_json(j); + } + j.end_array(); + } + if (non_crit_ext_present) { + j.write_fieldname("nonCriticalExtension"); + non_crit_ext.to_json(j); + } + j.end_obj(); +} + +std::string cg_cfg_info_v1560_ies_s::scg_fail_info_eutra_s_::fail_type_eutra_opts::to_string() const +{ + static const char* options[] = {"t313-Expiry", "randomAccessProblem", "rlc-MaxNumRetx", "scg-ChangeFailure"}; + return convert_enum_idx(options, 4, value, "cg_cfg_info_v1560_ies_s::scg_fail_info_eutra_s_::fail_type_eutra_e_"); +} +uint16_t cg_cfg_info_v1560_ies_s::scg_fail_info_eutra_s_::fail_type_eutra_opts::to_number() const +{ + static const uint16_t options[] = {313}; + return map_enum_number(options, 1, value, "cg_cfg_info_v1560_ies_s::scg_fail_info_eutra_s_::fail_type_eutra_e_"); +} + // CG-ConfigInfo-v1540-IEs ::= SEQUENCE SRSASN_CODE cg_cfg_info_v1540_ies_s::pack(bit_ref& bref) const { @@ -52828,6 +57177,9 @@ SRSASN_CODE cg_cfg_info_v1540_ies_s::pack(bit_ref& bref) const HANDLE_CODE(pack_integer(bref, meas_result_report_cgi.cell_for_which_to_report_cgi, (uint16_t)0u, (uint16_t)1007u)); HANDLE_CODE(meas_result_report_cgi.cgi_info.pack(bref)); } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.pack(bref)); + } return SRSASN_SUCCESS; } @@ -52846,6 +57198,9 @@ SRSASN_CODE cg_cfg_info_v1540_ies_s::unpack(cbit_ref& bref) unpack_integer(meas_result_report_cgi.cell_for_which_to_report_cgi, bref, (uint16_t)0u, (uint16_t)1007u)); HANDLE_CODE(meas_result_report_cgi.cgi_info.unpack(bref)); } + if (non_crit_ext_present) { + HANDLE_CODE(non_crit_ext.unpack(bref)); + } return SRSASN_SUCCESS; } @@ -52870,8 +57225,7 @@ void cg_cfg_info_v1540_ies_s::to_json(json_writer& j) const } if (non_crit_ext_present) { j.write_fieldname("nonCriticalExtension"); - j.start_obj(); - j.end_obj(); + non_crit_ext.to_json(j); } j.end_obj(); } @@ -52920,6 +57274,20 @@ SRSASN_CODE meas_cfg_mn_s::pack(bit_ref& bref) const HANDLE_CODE(gap_purpose.pack(bref)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= meas_gap_cfg_fr2.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(meas_gap_cfg_fr2.is_present(), 1)); + if (meas_gap_cfg_fr2.is_present()) { + HANDLE_CODE(meas_gap_cfg_fr2->pack(bref)); + } + } + } return SRSASN_SUCCESS; } SRSASN_CODE meas_cfg_mn_s::unpack(cbit_ref& bref) @@ -52939,6 +57307,21 @@ SRSASN_CODE meas_cfg_mn_s::unpack(cbit_ref& bref) HANDLE_CODE(gap_purpose.unpack(bref)); } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool meas_gap_cfg_fr2_present; + HANDLE_CODE(bref.unpack(meas_gap_cfg_fr2_present, 1)); + meas_gap_cfg_fr2.set_present(meas_gap_cfg_fr2_present); + if (meas_gap_cfg_fr2.is_present()) { + HANDLE_CODE(meas_gap_cfg_fr2->unpack(bref)); + } + } + } return SRSASN_SUCCESS; } void meas_cfg_mn_s::to_json(json_writer& j) const @@ -52958,6 +57341,12 @@ void meas_cfg_mn_s::to_json(json_writer& j) const if (gap_purpose_present) { j.write_str("gapPurpose", gap_purpose.to_string()); } + if (ext) { + if (meas_gap_cfg_fr2.is_present()) { + j.write_fieldname("measGapConfigFR2"); + meas_gap_cfg_fr2->to_json(j); + } + } j.end_obj(); } @@ -52981,7 +57370,7 @@ SRSASN_CODE cg_cfg_info_ies_s::pack(bit_ref& bref) const HANDLE_CODE(bref.pack(ue_cap_info_present, 1)); HANDLE_CODE(bref.pack(candidate_cell_info_list_mn_present, 1)); HANDLE_CODE(bref.pack(candidate_cell_info_list_sn_present, 1)); - HANDLE_CODE(bref.pack(meas_result_cell_list_sftd_present, 1)); + HANDLE_CODE(bref.pack(meas_result_cell_list_sftd_nr_present, 1)); HANDLE_CODE(bref.pack(scg_fail_info_present, 1)); HANDLE_CODE(bref.pack(cfg_restrict_info_present, 1)); HANDLE_CODE(bref.pack(drx_info_mcg_present, 1)); @@ -53001,8 +57390,8 @@ SRSASN_CODE cg_cfg_info_ies_s::pack(bit_ref& bref) const if (candidate_cell_info_list_sn_present) { HANDLE_CODE(candidate_cell_info_list_sn.pack(bref)); } - if (meas_result_cell_list_sftd_present) { - HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_cell_list_sftd, 1, 3)); + if (meas_result_cell_list_sftd_nr_present) { + HANDLE_CODE(pack_dyn_seq_of(bref, meas_result_cell_list_sftd_nr, 1, 3)); } if (scg_fail_info_present) { HANDLE_CODE(scg_fail_info.fail_type.pack(bref)); @@ -53040,7 +57429,7 @@ SRSASN_CODE cg_cfg_info_ies_s::unpack(cbit_ref& bref) HANDLE_CODE(bref.unpack(ue_cap_info_present, 1)); HANDLE_CODE(bref.unpack(candidate_cell_info_list_mn_present, 1)); HANDLE_CODE(bref.unpack(candidate_cell_info_list_sn_present, 1)); - HANDLE_CODE(bref.unpack(meas_result_cell_list_sftd_present, 1)); + HANDLE_CODE(bref.unpack(meas_result_cell_list_sftd_nr_present, 1)); HANDLE_CODE(bref.unpack(scg_fail_info_present, 1)); HANDLE_CODE(bref.unpack(cfg_restrict_info_present, 1)); HANDLE_CODE(bref.unpack(drx_info_mcg_present, 1)); @@ -53060,8 +57449,8 @@ SRSASN_CODE cg_cfg_info_ies_s::unpack(cbit_ref& bref) if (candidate_cell_info_list_sn_present) { HANDLE_CODE(candidate_cell_info_list_sn.unpack(bref)); } - if (meas_result_cell_list_sftd_present) { - HANDLE_CODE(unpack_dyn_seq_of(meas_result_cell_list_sftd, bref, 1, 3)); + if (meas_result_cell_list_sftd_nr_present) { + HANDLE_CODE(unpack_dyn_seq_of(meas_result_cell_list_sftd_nr, bref, 1, 3)); } if (scg_fail_info_present) { HANDLE_CODE(scg_fail_info.fail_type.unpack(bref)); @@ -53110,9 +57499,9 @@ void cg_cfg_info_ies_s::to_json(json_writer& j) const if (candidate_cell_info_list_sn_present) { j.write_str("candidateCellInfoListSN", candidate_cell_info_list_sn.to_string()); } - if (meas_result_cell_list_sftd_present) { - j.start_array("measResultCellListSFTD"); - for (const auto& e1 : meas_result_cell_list_sftd) { + if (meas_result_cell_list_sftd_nr_present) { + j.start_array("measResultCellListSFTD-NR"); + for (const auto& e1 : meas_result_cell_list_sftd_nr) { e1.to_json(j); } j.end_array(); @@ -53743,6 +58132,20 @@ SRSASN_CODE rrm_cfg_s::pack(bit_ref& bref) const HANDLE_CODE(pack_dyn_seq_of(bref, candidate_cell_info_list, 1, 8)); } + if (ext) { + ext_groups_packer_guard group_flags; + group_flags[0] |= candidate_cell_info_list_sn_eutra.is_present(); + group_flags.pack(bref); + + if (group_flags[0]) { + varlength_field_pack_guard varlen_scope(bref, false); + + HANDLE_CODE(bref.pack(candidate_cell_info_list_sn_eutra.is_present(), 1)); + if (candidate_cell_info_list_sn_eutra.is_present()) { + HANDLE_CODE(pack_dyn_seq_of(bref, *candidate_cell_info_list_sn_eutra, 1, 32)); + } + } + } return SRSASN_SUCCESS; } SRSASN_CODE rrm_cfg_s::unpack(cbit_ref& bref) @@ -53758,6 +58161,21 @@ SRSASN_CODE rrm_cfg_s::unpack(cbit_ref& bref) HANDLE_CODE(unpack_dyn_seq_of(candidate_cell_info_list, bref, 1, 8)); } + if (ext) { + ext_groups_unpacker_guard group_flags(1); + group_flags.unpack(bref); + + if (group_flags[0]) { + varlength_field_unpack_guard varlen_scope(bref, false); + + bool candidate_cell_info_list_sn_eutra_present; + HANDLE_CODE(bref.unpack(candidate_cell_info_list_sn_eutra_present, 1)); + candidate_cell_info_list_sn_eutra.set_present(candidate_cell_info_list_sn_eutra_present); + if (candidate_cell_info_list_sn_eutra.is_present()) { + HANDLE_CODE(unpack_dyn_seq_of(*candidate_cell_info_list_sn_eutra, bref, 1, 32)); + } + } + } return SRSASN_SUCCESS; } void rrm_cfg_s::to_json(json_writer& j) const @@ -53773,6 +58191,15 @@ void rrm_cfg_s::to_json(json_writer& j) const } j.end_array(); } + if (ext) { + if (candidate_cell_info_list_sn_eutra.is_present()) { + j.start_array("candidateCellInfoListSN-EUTRA"); + for (const auto& e1 : *candidate_cell_info_list_sn_eutra) { + e1.to_json(j); + } + j.end_array(); + } + } j.end_obj(); } @@ -54087,17 +58514,17 @@ SRSASN_CODE meas_timing_s::pack(bit_ref& bref) const if (ext) { ext_groups_packer_guard group_flags; - group_flags[0] |= ssb_to_measure_v1540.is_present(); + group_flags[0] |= ssb_to_measure.is_present(); group_flags[0] |= pci_present; group_flags.pack(bref); if (group_flags[0]) { varlength_field_pack_guard varlen_scope(bref, false); - HANDLE_CODE(bref.pack(ssb_to_measure_v1540.is_present(), 1)); + HANDLE_CODE(bref.pack(ssb_to_measure.is_present(), 1)); HANDLE_CODE(bref.pack(pci_present, 1)); - if (ssb_to_measure_v1540.is_present()) { - HANDLE_CODE(ssb_to_measure_v1540->pack(bref)); + if (ssb_to_measure.is_present()) { + HANDLE_CODE(ssb_to_measure->pack(bref)); } if (pci_present) { HANDLE_CODE(pack_integer(bref, pci, (uint16_t)0u, (uint16_t)1007u)); @@ -54128,12 +58555,12 @@ SRSASN_CODE meas_timing_s::unpack(cbit_ref& bref) if (group_flags[0]) { varlength_field_unpack_guard varlen_scope(bref, false); - bool ssb_to_measure_v1540_present; - HANDLE_CODE(bref.unpack(ssb_to_measure_v1540_present, 1)); - ssb_to_measure_v1540.set_present(ssb_to_measure_v1540_present); + bool ssb_to_measure_present; + HANDLE_CODE(bref.unpack(ssb_to_measure_present, 1)); + ssb_to_measure.set_present(ssb_to_measure_present); HANDLE_CODE(bref.unpack(pci_present, 1)); - if (ssb_to_measure_v1540.is_present()) { - HANDLE_CODE(ssb_to_measure_v1540->unpack(bref)); + if (ssb_to_measure.is_present()) { + HANDLE_CODE(ssb_to_measure->unpack(bref)); } if (pci_present) { HANDLE_CODE(unpack_integer(pci, bref, (uint16_t)0u, (uint16_t)1007u)); @@ -54159,9 +58586,9 @@ void meas_timing_s::to_json(json_writer& j) const j.end_obj(); } if (ext) { - if (ssb_to_measure_v1540.is_present()) { - j.write_fieldname("ssb-ToMeasure-v1540"); - ssb_to_measure_v1540->to_json(j); + if (ssb_to_measure.is_present()) { + j.write_fieldname("ssb-ToMeasure"); + ssb_to_measure->to_json(j); } if (pci_present) { j.write_int("physCellId", pci); @@ -54310,8 +58737,8 @@ meas_timing_cfg_s::crit_exts_c_::crit_exts_c_(const meas_timing_cfg_s::crit_exts log_invalid_choice_id(type_, "meas_timing_cfg_s::crit_exts_c_"); } } -meas_timing_cfg_s::crit_exts_c_& meas_timing_cfg_s::crit_exts_c_:: - operator=(const meas_timing_cfg_s::crit_exts_c_& other) +meas_timing_cfg_s::crit_exts_c_& +meas_timing_cfg_s::crit_exts_c_::operator=(const meas_timing_cfg_s::crit_exts_c_& other) { if (this == &other) { return *this; @@ -54551,8 +58978,8 @@ ue_radio_access_cap_info_s::crit_exts_c_::crit_exts_c_(const ue_radio_access_cap log_invalid_choice_id(type_, "ue_radio_access_cap_info_s::crit_exts_c_"); } } -ue_radio_access_cap_info_s::crit_exts_c_& ue_radio_access_cap_info_s::crit_exts_c_:: - operator=(const ue_radio_access_cap_info_s::crit_exts_c_& other) +ue_radio_access_cap_info_s::crit_exts_c_& +ue_radio_access_cap_info_s::crit_exts_c_::operator=(const ue_radio_access_cap_info_s::crit_exts_c_& other) { if (this == &other) { return *this; @@ -54829,8 +59256,8 @@ ue_radio_paging_info_s::crit_exts_c_::crit_exts_c_(const ue_radio_paging_info_s: log_invalid_choice_id(type_, "ue_radio_paging_info_s::crit_exts_c_"); } } -ue_radio_paging_info_s::crit_exts_c_& ue_radio_paging_info_s::crit_exts_c_:: - operator=(const ue_radio_paging_info_s::crit_exts_c_& other) +ue_radio_paging_info_s::crit_exts_c_& +ue_radio_paging_info_s::crit_exts_c_::operator=(const ue_radio_paging_info_s::crit_exts_c_& other) { if (this == &other) { return *this; @@ -55114,8 +59541,8 @@ var_meas_cfg_s::s_measure_cfg_c_::s_measure_cfg_c_(const var_meas_cfg_s::s_measu log_invalid_choice_id(type_, "var_meas_cfg_s::s_measure_cfg_c_"); } } -var_meas_cfg_s::s_measure_cfg_c_& var_meas_cfg_s::s_measure_cfg_c_:: - operator=(const var_meas_cfg_s::s_measure_cfg_c_& other) +var_meas_cfg_s::s_measure_cfg_c_& +var_meas_cfg_s::s_measure_cfg_c_::operator=(const var_meas_cfg_s::s_measure_cfg_c_& other) { if (this == &other) { return *this; diff --git a/lib/test/asn1/CMakeLists.txt b/lib/test/asn1/CMakeLists.txt index a0d30ca64..ca33b7377 100644 --- a/lib/test/asn1/CMakeLists.txt +++ b/lib/test/asn1/CMakeLists.txt @@ -47,6 +47,10 @@ target_link_libraries(rrc_asn1_test rrc_asn1 asn1_utils srslte_common) add_test(rrc_asn1_test rrc_asn1_test) if (ENABLE_5GNR) + add_executable(rrc_nr_asn1_test rrc_nr_test.cc) + target_link_libraries(rrc_nr_asn1_test rrc_nr_asn1 asn1_utils srslte_common) + add_test(rrc_nr_asn1_test rrc_nr_asn1_test) + add_executable(ngap_asn1_test ngap_test.cc) target_link_libraries(ngap_asn1_test ngap_nr_asn1 srslte_common) add_test(ngap_asn1_test ngap_asn1_test) diff --git a/lib/test/asn1/rrc_nr_test.cc b/lib/test/asn1/rrc_nr_test.cc new file mode 100644 index 000000000..c29559905 --- /dev/null +++ b/lib/test/asn1/rrc_nr_test.cc @@ -0,0 +1,154 @@ +/** + * + * \section COPYRIGHT + * + * Copyright 2013-2020 Software Radio Systems Limited + * + * By using this file, you agree to the terms and conditions set + * forth in the LICENSE file which can be found at the top level of + * the distribution. + * + */ + +#include "srslte/asn1/rrc_nr.h" +#include "srslte/common/test_common.h" +#include + +using namespace asn1; +using namespace asn1::rrc_nr; + +int test_eutra_nr_capabilities() +{ + struct ue_mrdc_cap_s mrdc_cap; + band_combination_s band_combination; + struct band_params_c band_param_eutra; + band_param_eutra.set_eutra(); + band_param_eutra.eutra().ca_bw_class_dl_eutra_present = true; + band_param_eutra.eutra().ca_bw_class_ul_eutra_present = true; + band_param_eutra.eutra().band_eutra = 1; + band_param_eutra.eutra().ca_bw_class_dl_eutra = asn1::rrc_nr::ca_bw_class_eutra_opts::options::a; + band_param_eutra.eutra().ca_bw_class_ul_eutra = asn1::rrc_nr::ca_bw_class_eutra_opts::options::a; + band_combination.band_list.push_back(band_param_eutra); + struct band_params_c band_param_nr; + band_param_nr.set_nr(); + band_param_nr.nr().ca_bw_class_dl_nr_present = true; + band_param_nr.nr().ca_bw_class_ul_nr_present = true; + band_param_nr.nr().band_nr = 78; + band_param_nr.nr().ca_bw_class_dl_nr = asn1::rrc_nr::ca_bw_class_nr_opts::options::a; + band_param_nr.nr().ca_bw_class_ul_nr = asn1::rrc_nr::ca_bw_class_nr_opts::options::a; + band_combination.band_list.push_back(band_param_nr); + + mrdc_cap.rf_params_mrdc.supported_band_combination_list.push_back(band_combination); + mrdc_cap.rf_params_mrdc.supported_band_combination_list_present = true; + + mrdc_cap.rf_params_mrdc.ext = true; + + // RF Params MRDC applied_freq_band_list_filt + freq_band_info_c band_info_eutra; + band_info_eutra.set_band_info_eutra(); + band_info_eutra.band_info_eutra().ca_bw_class_dl_eutra_present = false; + band_info_eutra.band_info_eutra().ca_bw_class_ul_eutra_present = false; + band_info_eutra.band_info_eutra().band_eutra = 1; + mrdc_cap.rf_params_mrdc.applied_freq_band_list_filt.push_back(band_info_eutra); + + freq_band_info_c band_info_nr; + band_info_nr.set_band_info_nr(); + band_info_nr.band_info_nr().band_nr = 78; + mrdc_cap.rf_params_mrdc.applied_freq_band_list_filt.push_back(band_info_nr); + + mrdc_cap.rf_params_mrdc.applied_freq_band_list_filt_present = true; + + // rf_params_mrdc supported band combination list v1540 + + band_combination_list_v1540_l* band_combination_list_v1450 = new band_combination_list_v1540_l(); + band_combination_v1540_s band_combination_v1540; + + band_params_v1540_s band_params_a; + band_params_a.srs_tx_switch_present = true; + band_params_a.srs_carrier_switch_present = false; + band_params_a.srs_tx_switch.supported_srs_tx_port_switch = + band_params_v1540_s::srs_tx_switch_s_::supported_srs_tx_port_switch_opts::not_supported; + band_combination_v1540.band_list_v1540.push_back(band_params_a); + + band_params_v1540_s band_params_b; + band_params_b.srs_tx_switch_present = true; + band_params_b.srs_tx_switch.supported_srs_tx_port_switch = + band_params_v1540_s::srs_tx_switch_s_::supported_srs_tx_port_switch_opts::t1r2; + band_params_b.srs_carrier_switch_present = false; + band_combination_v1540.band_list_v1540.push_back(band_params_b); + + // clang-format off + band_combination_v1540.ca_params_nr_v1540_present = false; + band_combination_v1540.ca_params_nr_v1540.simul_csi_reports_all_cc_present = true; + band_combination_v1540.ca_params_nr_v1540.csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc_present = true; + band_combination_v1540.ca_params_nr_v1540.csi_rs_im_reception_for_feedback_per_band_comb.max_num_simul_nzp_csi_rs_act_bwp_all_cc = 5; + band_combination_v1540.ca_params_nr_v1540.csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc_present = true; + band_combination_v1540.ca_params_nr_v1540.csi_rs_im_reception_for_feedback_per_band_comb.total_num_ports_simul_nzp_csi_rs_act_bwp_all_cc = 32; + // clang-format on + band_combination_list_v1450->push_back(band_combination_v1540); + mrdc_cap.rf_params_mrdc.supported_band_combination_list_v1540.reset(band_combination_list_v1450); + + feature_set_combination_l feature_set_combination; + + feature_sets_per_band_l feature_sets_per_band; + + feature_set_c feature_set_eutra; + feature_set_eutra.set_eutra(); + feature_set_eutra.eutra().dl_set_eutra = 1; + feature_set_eutra.eutra().ul_set_eutra = 1; + feature_sets_per_band.push_back(feature_set_eutra); + + feature_set_combination.push_back(feature_sets_per_band); + + feature_set_c feature_set_nr; + feature_set_nr.set_nr(); + feature_set_nr.nr().dl_set_nr = 1; + feature_set_nr.nr().ul_set_nr = 1; + feature_sets_per_band.push_back(feature_set_nr); + + feature_set_combination.push_back(feature_sets_per_band); + + mrdc_cap.feature_set_combinations.push_back(feature_set_combination); + + mrdc_cap.feature_set_combinations_present = true; + + // Pack mrdc_cap + uint8_t buffer[1024]; + asn1::bit_ref bref(buffer, sizeof(buffer)); + mrdc_cap.pack(bref); + + TESTASSERT(test_pack_unpack_consistency(mrdc_cap) == SRSASN_SUCCESS); + + srslte::logmap::get("RRC")->info_hex( + buffer, bref.distance_bytes(), "Packed cap struct (%d bytes):\n", bref.distance_bytes()); + + return SRSLTE_SUCCESS; +} + +int test_ue_mrdc_capabilities() +{ + uint8_t msg[] = {0x01, 0x1c, 0x04, 0x81, 0x60, 0x00, 0x1c, 0x4d, 0x00, 0x00, 0x00, 0x04, + 0x00, 0x40, 0x04, 0x04, 0xd0, 0x10, 0x74, 0x06, 0x14, 0xe8, 0x1b, 0x10, + 0x78, 0x00, 0x00, 0x20, 0x00, 0x10, 0x08, 0x08, 0x01, 0x00, 0x20}; + // 011c048160001c4d0000000400400404d010740614e81b107800002000100808010020 + + asn1::cbit_ref bref{msg, sizeof(msg)}; + ue_mrdc_cap_s mrdc_cap; + + TESTASSERT(mrdc_cap.unpack(bref) == SRSASN_SUCCESS); + + TESTASSERT(test_pack_unpack_consistency(mrdc_cap) == SRSASN_SUCCESS); + + return SRSLTE_SUCCESS; +} + +int main() +{ + srslte::logmap::set_default_log_level(srslte::LOG_LEVEL_DEBUG); + + TESTASSERT(test_eutra_nr_capabilities() == 0); + TESTASSERT(test_ue_mrdc_capabilities() == 0); + + printf("Success\n"); + return 0; +} diff --git a/srsenb/src/stack/rrc/rrc_nr.cc b/srsenb/src/stack/rrc/rrc_nr.cc index 7e05edfce..916060561 100644 --- a/srsenb/src/stack/rrc/rrc_nr.cc +++ b/srsenb/src/stack/rrc/rrc_nr.cc @@ -231,8 +231,8 @@ uint32_t rrc_nr::generate_sibs() for (uint32_t sched_info_elem = 0; sched_info_elem < nof_messages; sched_info_elem++) { uint32_t msg_index = sched_info_elem + 1; // first msg is SIB1, therefore start with second - msg[msg_index].msg.set_c1().set_sys_info().crit_exts.set_sys_info_r15(); - auto& sib_list = msg[msg_index].msg.c1().sys_info().crit_exts.sys_info_r15().sib_type_and_info; + msg[msg_index].msg.set_c1().set_sys_info().crit_exts.set_sys_info(); + auto& sib_list = msg[msg_index].msg.c1().sys_info().crit_exts.sys_info().sib_type_and_info; for (uint32_t mapping = 0; mapping < sched_info[sched_info_elem].sib_map_info.size(); ++mapping) { uint32_t sibidx = sched_info[sched_info_elem].sib_map_info[mapping].type; // SIB2 == 0