From 9d7ec211de2ba80eb0cc6498a19f3f4fd1f5cbb0 Mon Sep 17 00:00:00 2001 From: mich Date: Wed, 21 Nov 2018 17:02:55 +0100 Subject: [PATCH] mobile: some work on GSM RR and CSN.1, regenerated all CSN.1 structures, more work is required on the CSN.1 runtime for setting values and encoding --- pycrate_csn1/csnobj.py | 36 +- pycrate_csn1/trans.py | 48 +- ...iate_assignment_type_3_message_content.csn | 2 +- .../44060/psi3_quater_message_content.csn | 86 --- pycrate_csn1dir/_3g_csg_description_ie.py | 4 +- pycrate_csn1dir/_3g_priority_parameters_ie.py | 4 +- pycrate_csn1dir/__init__.py | 287 -------- pycrate_csn1dir/ack_nack_description_ie.py | 4 +- ...dio_access_capabilities_message_content.py | 8 +- pycrate_csn1dir/ba_list_pref.py | 4 +- pycrate_csn1dir/cell_identification_ie.py | 4 +- ...release_of_all_tch_and_sdcch_value_part.py | 99 ++- ...hannel_request_description_2_value_part.py | 4 +- .../channel_request_description_ie.py | 4 +- pycrate_csn1dir/classmark_3_value_part.py | 36 +- pycrate_csn1dir/compact_reduced_ma_ie.py | 4 +- .../cs_handover_radio_resources_ie.py | 4 +- .../dlmc_channel_quality_report_ie.py | 4 +- .../downlink_rlc_mac_control_message.py | 152 ++--- .../dtm_handover_command_message_content.py | 14 +- .../dtm_handover_ps_radio_resources_2_ie.py | 6 +- .../dtm_handover_ps_radio_resources_3_ie.py | 6 +- .../dtm_handover_ps_radio_resources_ie.py | 50 +- .../dtm_information_details_value_part.py | 4 +- .../dual_carrier_frequency_parameters_ie.py | 16 +- pycrate_csn1dir/dynamic_allocation_2_ie.py | 4 +- pycrate_csn1dir/dynamic_allocation_3_ie.py | 4 +- pycrate_csn1dir/dynamic_arfcn_mapping.py | 4 +- pycrate_csn1dir/e_utran_csg_description_ie.py | 4 +- .../e_utran_csg_measurement_report_ie.py | 4 +- pycrate_csn1dir/e_utran_csg_target_cell_ie.py | 4 +- .../e_utran_ipp_with_extended_earfcns_ie.py | 4 +- .../e_utran_nc_with_extended_earfcns_ie.py | 4 +- pycrate_csn1dir/e_utran_parameters_ie.py | 18 +- pycrate_csn1dir/e_utran_target_cell_ie.py | 4 +- ...ran_target_cell_with_extended_earfcn_ie.py | 4 +- pycrate_csn1dir/ec_ack_nack_description_ie.py | 4 +- .../ec_channel_quality_report_ie.py | 4 +- .../ec_downlink_assignment_message_content.py | 4 +- ...nlink_assignment_message_type_2_content.py | 4 +- pycrate_csn1dir/ec_dummy_message_content.py | 4 +- ...diate_assignment_reject_message_content.py | 4 +- ...diate_assignment_type_2_message_content.py | 4 +- ...diate_assignment_type_3_message_content.py | 4 +- ...diate_assignment_type_4_message_content.py | 6 +- ...ec_packet_access_reject_message_content.py | 4 +- .../ec_packet_channel_description_type_1.py | 4 +- .../ec_packet_channel_description_type_2.py | 4 +- ...ket_channel_request_message_content_cc1.py | 8 +- ...control_acknowledgement_message_content.py | 4 +- ...acket_downlink_ack_nack_message_content.py | 8 +- ...ket_downlink_assignment_message_content.py | 8 +- ...ink_dummy_control_block_message_content.py | 4 +- ..._packet_polling_request_message_content.py | 6 +- ..._control_timing_advance_message_content.py | 8 +- .../ec_packet_tbf_release_message_content.py | 4 +- .../ec_packet_timing_advance_ie.py | 4 +- ...d_contention_resolution_message_content.py | 6 +- ..._packet_uplink_ack_nack_message_content.py | 8 +- ...acket_uplink_assignment_message_content.py | 18 +- pycrate_csn1dir/ec_paging_indication.py | 4 +- .../ec_paging_request_message_content.py | 4 +- .../ec_primary_ack_nack_description_ie.py | 4 +- .../ec_request_reference_description.py | 4 +- .../ec_system_information_type_1.py | 12 +- .../ec_system_information_type_2.py | 82 +-- .../ec_system_information_type_3.py | 30 +- .../ec_system_information_type_4.py | 4 +- .../egprs_ack_nack_description_dlmc_ie.py | 4 +- .../egprs_ack_nack_description_ie.py | 4 +- .../egprs_bep_link_quality_measurements_ie.py | 4 +- ...bep_link_quality_measurements_type_2_ie.py | 4 +- .../egprs_channel_quality_report_ie.py | 6 +- .../egprs_channel_quality_report_type_2_ie.py | 6 +- pycrate_csn1dir/egprs_level_ie.py | 4 +- pycrate_csn1dir/egprs_mode_2_ie.py | 6 +- .../egprs_modulation_and_coding_scheme_ie.py | 4 +- ..._packet_channel_request_message_content.py | 4 +- ..._downlink_ack_nack_dlmc_message_content.py | 8 +- ...acket_downlink_ack_nack_message_content.py | 8 +- ...ownlink_ack_nack_type_2_message_content.py | 8 +- ...ownlink_ack_nack_type_3_message_content.py | 10 +- ...s_timeslot_link_quality_measurements_ie.py | 4 +- ...lot_link_quality_measurements_type_2_ie.py | 72 +- pycrate_csn1dir/egprs_window_size_ie.py | 4 +- ...enhanced_cell_reselection_parameters_ie.py | 4 +- .../enhanced_measurement_report.py | 18 +- pycrate_csn1dir/extension_bits_ie.py | 4 +- .../flo_ack_nack_description_ie.py | 4 +- pycrate_csn1dir/frequency_parameters_ie.py | 4 +- pycrate_csn1dir/g_rnti_ie.py | 4 +- pycrate_csn1dir/generator/to_be_completed.txt | 187 ++--- .../global_packet_timing_advance_ie.py | 4 +- .../global_power_control_parameters_ie.py | 4 +- pycrate_csn1dir/global_tfi_ie.py | 4 +- .../gprs_broadcast_information_value_part.py | 6 +- pycrate_csn1dir/gprs_cell_options_ie.py | 4 +- pycrate_csn1dir/gprs_mobile_allocation_ie.py | 4 +- .../gprs_power_control_parameters_ie.py | 4 +- pycrate_csn1dir/gsm_priority_parameters_ie.py | 4 +- .../handover_access_8_bit_message.py | 4 +- pycrate_csn1dir/ia_rest_octets.py | 344 +++++----- pycrate_csn1dir/iar_rest_octets.py | 4 +- pycrate_csn1dir/iax_rest_octets.py | 4 +- pycrate_csn1dir/individual_priorities.py | 32 +- pycrate_csn1dir/individual_priorities_ie.py | 38 +- pycrate_csn1dir/ipa_rest_octets.py | 28 +- .../iu_mode_channel_request_description_ie.py | 4 +- pycrate_csn1dir/lsa_parameters_ie.py | 4 +- ...assignment_distribution_message_content.py | 10 +- ...gnment_non_distribution_message_content.py | 10 +- pycrate_csn1dir/mbms_channel_parameters_ie.py | 6 +- .../mbms_downlink_ack_nack_message_content.py | 8 +- .../mbms_in_band_signalling_indicator_ie.py | 4 +- .../mbms_ms_id_assignment_message_content.py | 6 +- ...ouring_cell_information_message_content.py | 30 +- .../mbms_p_t_m_channel_description_ie.py | 4 +- ...ms_p_t_m_channel_description_value_part.py | 4 +- .../mbms_service_request_message_content.py | 6 +- .../mbms_session_identity_value_part.py | 4 +- .../mbms_session_parameters_list_ie.py | 4 +- ...mbms_session_parameters_list_value_part.py | 4 +- pycrate_csn1dir/mbms_sessions_list_ie.py | 4 +- ...surement_control_parameters_description.py | 4 +- pycrate_csn1dir/measurement_information.py | 593 ++++++++-------- .../measurement_results_contents.py | 46 +- .../mprach_control_parameters_ie.py | 4 +- pycrate_csn1dir/mprach_description_ie.py | 6 +- .../mprach_description_value_part.py | 4 +- ..._packet_channel_request_message_content.py | 4 +- .../ms_network_capability_value_part.py | 4 +- .../ms_ra_capability_value_part.py | 84 ++- .../ms_radio_access_capability_2_ie.py | 4 +- .../multiple_downlink_assignment_2_ie.py | 26 +- ...tbf_downlink_assignment_message_content.py | 66 +- ...bf_timeslot_reconfigure_message_content.py | 262 +++---- ...e_tbf_uplink_assignment_message_content.py | 172 ++--- .../multiple_uplink_assignment_2_ie.py | 114 ++-- .../nas_container_for_ps_handover_ie.py | 4 +- pycrate_csn1dir/non_gprs_cell_options_ie.py | 4 +- pycrate_csn1dir/notification_facch.py | 26 +- pycrate_csn1dir/notify_application_data.py | 8 +- pycrate_csn1dir/ntn_rest_octets.py | 30 +- pycrate_csn1dir/p1_rest_octets.py | 12 +- pycrate_csn1dir/p2_rest_octets.py | 4 +- pycrate_csn1dir/p3_rest_octets.py | 4 +- .../packet_access_reject_message_content.py | 20 +- ...application_information_message_content.py | 4 +- ...et_cell_change_continue_message_content.py | 6 +- ...ket_cell_change_failure_message_content.py | 12 +- ...ell_change_notification_message_content.py | 78 +-- ...acket_cell_change_order_message_content.py | 427 +++++++----- pycrate_csn1dir/packet_channel_description.py | 4 +- ..._channel_request_11_bit_message_content.py | 4 +- ...control_acknowledgement_message_content.py | 32 +- .../packet_cs_command_message_content.py | 6 +- .../packet_cs_release_message_content.py | 108 +-- .../packet_cs_request_message_content.py | 6 +- ...acket_dbpsch_assignment_message_content.py | 14 +- ...packet_dbpsch_downlink_ack_nack_message.py | 4 +- ...dbpsch_downlink_ack_nack_type_2_message.py | 8 +- ..._dbpsch_uplink_ack_nack_message_content.py | 4 +- ..._uplink_ack_nack_type_2_message_content.py | 6 +- ...acket_downlink_ack_nack_message_content.py | 10 +- ...ket_downlink_assignment_message_content.py | 28 +- ...ink_dummy_control_block_message_content.py | 4 +- ...nced_measurement_report_message_content.py | 16 +- ...acket_mbms_announcement_message_content.py | 10 +- ...acket_measurement_order_message_content.py | 437 +++++++----- ...cket_measurement_report_message_content.py | 8 +- ...acket_mobile_tbf_status_message_content.py | 6 +- ...ket_neighbour_cell_data_message_content.py | 6 +- .../packet_paging_request_message_content.py | 38 +- .../packet_pause_message_content.py | 4 +- .../packet_pdch_release_message_content.py | 4 +- ...et_physical_information_message_content.py | 6 +- .../packet_polling_request_message_content.py | 6 +- ..._control_timing_advance_message_content.py | 10 +- ...packet_prach_parameters_message_content.py | 4 +- .../packet_psi_status_message_content.py | 6 +- ...t_queueing_notification_message_content.py | 6 +- .../packet_request_reference_ie.py | 4 +- ...packet_resource_request_message_content.py | 18 +- ...acket_serving_cell_data_message_content.py | 6 +- .../packet_serving_cell_si_message_content.py | 4 +- .../packet_si_status_message_content.py | 6 +- .../packet_tbf_release_message_content.py | 6 +- ...et_timeslot_reconfigure_message_content.py | 236 +++---- pycrate_csn1dir/packet_timing_advance_ie.py | 4 +- .../packet_uplink_ack_nack_message_content.py | 8 +- ...acket_uplink_assignment_message_content.py | 108 +-- ...ink_dummy_control_block_message_content.py | 4 +- pycrate_csn1dir/padding_bits.py | 8 +- .../pccch_organization_parameters_ie.py | 4 +- pycrate_csn1dir/pcid_group_ie.py | 4 +- pycrate_csn1dir/pdch_pairs_description_ie.py | 4 +- .../physical_information_message_content.py | 4 +- .../power_control_parameters_ie.py | 4 +- .../prach_control_parameters_ie.py | 4 +- ...er_access_message_content_8_bit_message.py | 8 +- .../ps_handover_command_message_content.py | 30 +- .../ps_handover_radio_resources_2_ie.py | 8 +- .../ps_handover_radio_resources_3_ie.py | 20 +- .../ps_handover_radio_resources_ie.py | 120 ++-- pycrate_csn1dir/psc_group_ie.py | 4 +- pycrate_csn1dir/psi13_message_content.py | 8 +- pycrate_csn1dir/psi14_message_content.py | 32 +- pycrate_csn1dir/psi15_message_content.py | 4 +- pycrate_csn1dir/psi16_message_content.py | 8 +- pycrate_csn1dir/psi1_message_content.py | 8 +- pycrate_csn1dir/psi2_message_content.py | 90 +-- pycrate_csn1dir/psi3_bis_message_content.py | 475 ++++++------- pycrate_csn1dir/psi3_message_content.py | 146 ++-- .../psi3_quater_message_content.py | 139 ++-- pycrate_csn1dir/psi3_ter_message_content.py | 12 +- pycrate_csn1dir/psi5_message_content.py | 24 +- pycrate_csn1dir/psi6_message_content.py | 16 +- pycrate_csn1dir/psi8_message_content.py | 6 +- pycrate_csn1dir/pulse_format_ie.py | 16 +- .../receive_npdu_number_list_value.py | 32 +- .../restriction_timer_value_part.py | 4 +- ...t_downlink_assignment_type_2_value_part.py | 52 +- ...r_packet_downlink_assignment_value_part.py | 42 +- .../rr_packet_uplink_assignment_value_part.py | 162 ++--- pycrate_csn1dir/rrc_container_ie.py | 4 +- pycrate_csn1dir/si10_rest_octets.py | 38 +- pycrate_csn1dir/si10bis_rest_octets.py | 4 +- pycrate_csn1dir/si14_rest_octets.py | 4 +- pycrate_csn1dir/si15_rest_octets.py | 4 +- pycrate_csn1dir/si16_rest_octets.py | 4 +- pycrate_csn1dir/si1_rest_octets.py | 4 +- pycrate_csn1dir/si2bis_rest_octets.py | 4 +- pycrate_csn1dir/si2n_rest_octets.py | 4 +- pycrate_csn1dir/si2quater_rest_octets.py | 641 ++++++++++-------- pycrate_csn1dir/si2ter_rest_octets.py | 28 +- pycrate_csn1dir/si3_rest_octet.py | 32 +- pycrate_csn1dir/si4_rest_octets.py | 62 +- pycrate_csn1dir/si6_rest_octets.py | 34 +- pycrate_csn1dir/si9_rest_octets.py | 18 +- pycrate_csn1dir/si_13_rest_octets.py | 6 +- pycrate_csn1dir/si_13alt_rest_octets.py | 4 +- pycrate_csn1dir/si_18_rest_octets.py | 4 +- pycrate_csn1dir/si_19_rest_octets.py | 4 +- pycrate_csn1dir/si_21_rest_octets.py | 4 +- pycrate_csn1dir/si_22_rest_octets.py | 4 +- pycrate_csn1dir/si_23_rest_octets.py | 46 +- .../single_downlink_assignment_2_ie.py | 6 +- .../single_uplink_assignment_2_ie.py | 10 +- .../starting_frame_number_description_ie.py | 4 +- pycrate_csn1dir/system_information_type_10.py | 4 +- .../system_information_type_10bis.py | 4 +- .../system_information_type_10ter.py | 4 +- pycrate_csn1dir/tlli_g_rnti_ie.py | 4 +- pycrate_csn1dir/tmgi_ie.py | 4 +- pycrate_csn1dir/uplink_free.py | 4 +- .../uplink_rlc_mac_control_message.py | 34 +- pycrate_csn1dir/used_dl_coverage_class_ie.py | 4 +- .../utran_csg_measurement_report_ie.py | 4 +- pycrate_csn1dir/utran_csg_target_cell_ie.py | 4 +- pycrate_csn1dir/utran_fdd_target_cell_ie.py | 4 +- pycrate_csn1dir/utran_freq_list.py | 4 +- pycrate_csn1dir/utran_tdd_target_cell_ie.py | 4 +- pycrate_csn1dir/vbs_vgcs_reconfigure.py | 4 +- pycrate_csn1dir/vbs_vgcs_reconfigure2.py | 4 +- pycrate_csn1dir/vgcs_additional_info.py | 4 +- .../vgcs_neighbour_cell_information.py | 4 +- pycrate_csn1dir/vgcs_sms_information.py | 4 +- test/test_gsmrr.py | 105 +++ test/test_mobile.py | 1 + 269 files changed, 4170 insertions(+), 3967 deletions(-) delete mode 100644 pycrate_csn1dir/__init__.py create mode 100644 test/test_gsmrr.py diff --git a/pycrate_csn1/csnobj.py b/pycrate_csn1/csnobj.py index 01d210b..6c7a845 100644 --- a/pycrate_csn1/csnobj.py +++ b/pycrate_csn1/csnobj.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2017. Benoit Michau. ANSSI. +# * Copyright 2017. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -50,18 +50,20 @@ class CSN1Obj(Element): int, static number of repetition for the object default is 1, it can be >= 0 or -1, for an undefined number of repetitions - (x:int, (a:int, b:int) is an alternate possible value in case + (x:int, (a:int, b:int)) is an alternate possible value in case the number of repetitions is dynamic and depends on another - object, handling is similar to lref - In case of undefined number of repetitions, the decoding happens - until there is no more buffer to decode, or a fixed value defined in - the object is not present anymore in the buffer to decode - - lref: (x:int, (a:int, b:int)), enforces the length in bit during - the decoding and potentially the encoding - x: offset into a field in the parent object (which has to be a list) - to get the value from - a, b: transform in the form x: a*(x+b) to be applied to the - value of the referred object to get the length of self + object: + x: backward reference to a field into the parent object which + has to be a list + a, b: transform in the form x: a*(x+b) to be applied to the + value of the backward reference to get the length of self + - lref: enforces a limitation to the length in bits during the decoding + and potentially the encoding, used for lists and alternatives + None, no limitation + int, static limitation of the number of bits + (x:int, (a:int, b:int)) is an alternate possible value in case the + limitation of number of bits is dynamic and depends on another + object, handling is similar to num This class must not be used directly, only CSN1Bit, CSN1List, CSN1Alt, CSN1Val, CSN1Ref, CSN1SelfRef. @@ -114,6 +116,8 @@ class CSN1Obj(Element): self._num = kw['num'] if 'lref' in kw and kw['lref'] is not None: self._lref = kw['lref'] + if 'val' in kw: + self.set_val(kw['val']) # offset for dealing with L / H bits self._off = 0 @@ -255,8 +259,12 @@ class CSN1Obj(Element): _root_obj = self # if self._lref is not None: - # dynamic shortage of the char buffer - lref = self._resolve_ref(self._lref) + if isinstance(self._lref, integer_types): + # static shortage of the char buffer + lref = self._lref + else: + # dynamic shortage of the char buffer + lref = self._resolve_ref(self._lref) char_lb = char._len_bit char._len_bit = char._cur + lref assert( char._len_bit <= char_lb ) diff --git a/pycrate_csn1/trans.py b/pycrate_csn1/trans.py index 0202683..76c71c9 100644 --- a/pycrate_csn1/trans.py +++ b/pycrate_csn1/trans.py @@ -47,15 +47,20 @@ class CSN1Obj(object): int, static number of repetition for the object default is 1, it can be >= 0 or -1, for an undefined number of repetitions - (x:int, (a:int, b:int) is an alternate possible value in case + (x:int, (a:int, b:int)) is an alternate possible value in case the number of repetitions is dynamic and depends on another - object, handling is similar to lref - - lref: (x:int, (a:int, b:int)), enforces the length in bit during - the decoding and potentially the encoding - x: backward reference to a field into the parent object which - has to be a list - a, b: transform in the form x: a*(x+b) to be applied to the - value of the backward reference to get the length of self + object: + x: backward reference to a field into the parent object which + has to be a list + a, b: transform in the form x: a*(x+b) to be applied to the + value of the backward reference to get the length of self + - lref: enforces a limitation to the length in bits during the decoding + and potentially the encoding, used for lists and alternatives + None, no limitation + int, static limitation to the number of bits + (x:int, (a:int, b:int)) is an alternate possible value in case the + limitation of number of bits is dynamic and depends on another + object, handling is similar to num - ref : set of str, list all reference to external CSN.1 objects In case the CSN.1 object is a bit-field: @@ -63,9 +68,9 @@ class CSN1Obj(object): int, static number of bits for the object default is 1, it can be >= 0 or -1, for an undefined number of bits - (x:int, (a:int, b:int) is an alternate possible value in case + (x:int, (a:int, b:int)) is an alternate possible value in case the number of bits is dynamic and depends on another - object, handling is similar to lref + object, handling is similar to num - excl: None or CSN1Val, list of excluded values In case the CSN.1 object is a list of objects: @@ -1170,7 +1175,14 @@ def build_alt_selector(Obj): if val == 'null': has_null.append( True ) else: - selec.append( (val, (pythonize_name(alt._name), [])) ) + # potential alternative + if val[-2:] == '**': + # take care of repeated value (e.g. 0**) + nv = ASN1Val() + nv.parse_val(val) + selec.append( (val[:-2], (pythonize_name(alt._name), [nv])) ) + else: + selec.append( (val, (pythonize_name(alt._name), [])) ) has_null.append( False ) else: if alt._val[0] == 'null': @@ -1178,7 +1190,11 @@ def build_alt_selector(Obj): has_null.append(True) else: # potential alternative - selec.append( (alt._val[0], (pythonize_name(alt._name), [])) ) + if alt._val[0][-2:] == '**': + # take care of repeated value (e.g. 0**) + selec.append( (alt._val[0][:-2], (pythonize_name(alt._name), [alt])) ) + else: + selec.append( (alt._val[0], (pythonize_name(alt._name), [])) ) has_null.append( False ) # elif isinstance(alt, CSN1Ref): @@ -1193,9 +1209,13 @@ def build_alt_selector(Obj): # associate all of them with the rest of the objects' list rest = alt[1:] for val in alt[0]._val: + if val[-2:] == '**': + raise(CSN1Err('unsupported alternative key, %s' % val)) selec.append( (val, (pythonize_name(alt[0]._name), rest)) ) has_null.append( False ) else: + if alt[0]._val[0][-2:] == '**': + raise(CSN1Err('unsupported alternative key, %s' % alt[0]._val[0])) selec.append( (alt[0]._val[0], (pythonize_name(alt[0]._name), alt[1:])) ) has_null.append( False ) elif alt[0]._bit and alt[0]._excl: @@ -1231,9 +1251,13 @@ def build_alt_selector(Obj): # associate all of them with the rest of the objects' list rest = alt._list[1:] for val in alt._list[0]._val: + if val[-2:] == '**': + raise(CSN1Err('unsupported alternative key, %s' % val)) selec.append( (val, (pythonize_name(alt_name), rest)) ) has_null.append( False ) else: + if alt._list[0]._val[0][-2:] == '**': + raise(CSN1Err('unsupported alternative key, %s' % alt._list[0]._val[0])) selec.append( (alt._list[0]._val[0], (pythonize_name(alt_name), alt._list[1:])) ) has_null.append( False ) elif alt._list[0]._bit and alt._list[0]._excl: diff --git a/pycrate_csn1dir/44018/ec_immediate_assignment_type_3_message_content.csn b/pycrate_csn1dir/44018/ec_immediate_assignment_type_3_message_content.csn index 79e3111..fbb4540 100644 --- a/pycrate_csn1dir/44018/ec_immediate_assignment_type_3_message_content.csn +++ b/pycrate_csn1dir/44018/ec_immediate_assignment_type_3_message_content.csn @@ -6,7 +6,7 @@ < Message Type : bit (4) > < Used DL Coverage Class : bit (2) > { 0 | 1 < EC Page Extension : bit (4) > } - < Acknowledged Access Request 1 : Acknowldeged Access Request struct > + < Acknowledged Access Request 1 : Acknowledged Access Request struct > { 0 | 1 < Acknowledged Access Request 2 : Acknowledged Access Request struct > } { 0 | 1 < Acknowledged Access Request 3 : Acknowledged Access Request struct > } { 0 | 1 < Acknowledged Access Request 4 : Acknowledged Access Request struct > } diff --git a/pycrate_csn1dir/44060/psi3_quater_message_content.csn b/pycrate_csn1dir/44060/psi3_quater_message_content.csn index 9d0b554..e69de29 100644 --- a/pycrate_csn1dir/44060/psi3_quater_message_content.csn +++ b/pycrate_csn1dir/44060/psi3_quater_message_content.csn @@ -1,86 +0,0 @@ --- TS 44.060 - d60 --- 11.2.21b Packet System Information Type 3 quater --- PSI3 quater message content - -< PSI3 quater message content > ::= - < PAGE_MODE : bit (2) > - < PSI3_CHANGE_MARK : bit (2) > - < PSI3_QUATER_INDEX : bit (4) > - < PSI3_QUATER_COUNT : bit (4) > - { { 0 | 1 < GPRS REP_PRIORITY Description : < GPRS REP PRIORITY Description struct >> } - { 0 | 1 < 3G Neighbour Cells Description : < 3G Neighbour Cells Description struct >> } - { 0 | 1 < 3G MEASUREMENT Parameters Description : - < 3G MEASUREMENT PARAMETERS Description struct >> } - { 0 | 1 < 3G Initial Dedicated Mode Reporting Description : - < 3G Initial Dedicated Mode Reporting Description struct >> } - { null | 0 bit** = < no string> -- Receiver compatible with earlier release - | 1 -- Additions in Release 5: - { 0 | 1 < GPRS 3G Additional Measurement Parameters Description : - < GPRS 3G Additional Measurement Parameters Description struct >> } - { 0 | 1 < GPRS 3G Additional Measurement Parameters Description 2: - < GPRS 3G Additional Measurement Parameters Description 2 struct >> } - { null | 0 bit** = < no string > --Receiver compatible with earlier release - | 1 --Additions in Release 6: - < 3G_CCN_ACTIVE : bit > - < padding bits > } - } - } // -- truncation at end of message allowed, bits '0' assumed - ! < Distribution part error : bit (*) = < no string > > ; - -< GPRS REP PRIORITY Description struct > ::= - < Number_Cells : bit(7) > - { < REP_PRIORITY : bit > } * (val(Number_Cells)) ; - -< 3G Neighbour Cells Description struct > ::= - { 0 | 1 < Index_Start_3G : bit (7) > } - { 0 | 1 < Absolute_Index_Start_EMR : bit (7) > } - { 0 | 1 < UTRAN FDD Description : < UTRAN FDD Description struct >> } - { 0 | 1 < UTRAN TDD Description : < UTRAN TDD Description struct >> } ; - -< UTRAN FDD Description struct > ::= - { 0 | 1 < Bandwidth_FDD : bit (3) > } - { 1 < Repeated UTRAN FDD Neighbour Cells : < Repeated UTRAN FDD Neighbour Cells struct >> } ** 0 ; - -< Repeated UTRAN FDD Neighbour Cells struct > ::= - 0 < FDD-ARFCN : bit (14) > -- The value ‘1’ was used in an earlier - -- version of the protocol and shall not be used. - < FDD_Indic0 : bit > - < NR_OF_FDD_CELLS : bit (5) > - < FDD _CELL_INFORMATION Field : bit(p(NR_OF_FDD_CELLS)) > ; - -< UTRAN TDD Description struct > ::= - { 0 | 1 < Bandwidth_TDD : bit (3) > } - { 1 < Repeated UTRAN TDD Neighbour Cells : < Repeated UTRAN TDD Neighbour Cells struct >> } ** 0 ; - -< Repeated UTRAN TDD Neighbour Cells struct > ::= - 0 < TDD-ARFCN : bit (14) > -- The value ‘1’ was used in an earlier - -- version of the protocol and shall not be used. - < TDD_Indic0 : bit > - < NR_OF_TDD_CELLS : bit (5) > - < TDD_CELL_INFORMATION Field : bit(q(NR_OF_TDD_CELLS)) > ; - -< 3G MEASUREMENT PARAMETERS Description struct > ::= - < Qsearch_P : bit (4) > - { 1 ! < Ignore : bit = < no string >> } -- this bit shall be ignored by the receiver - -- for backward compatibility with earlier releases - { 0 | 1 < FDD_GPRS_Qoffset : bit (4) > -- FDD information - < FDD_Qmin : bit (3) > } - { 0 | 1 < TDD_GPRS_Qoffset : bit (4) > } ; -- TDD information - -< 3G Initial Dedicated Mode Reporting Description struct > ::= - < 3G_BA_IND : bit > - < Qsearch_I : bit (4) > - < Qsearch_C_Initial : bit (1) > - { 0 | 1 < FDD_Qoffset : bit (4) > -- FDD information - < FDD_REP_QUANT : bit (1) > - < FDD_MULTIRAT_REPORTING : bit (2) > } - { 0 | 1 < TDD_Qoffset : bit (4) > -- TDD information - < TDD_MULTIRAT_REPORTING : bit (2) > } ; - -< GPRS 3G Additional Measurement Parameters Description struct > ::= - < FDD_Qmin_Offset : bit (3) > -- FDD information - < FDD_RSCPmin : bit (4) > ; - -< GPRS 3G Additional Measurement Parameters Description 2 struct > ::= - { 0 | 1 < FDD_REPORTING_THRESHOLD_2 : bit (6) > } ; -- FDD information - diff --git a/pycrate_csn1dir/_3g_csg_description_ie.py b/pycrate_csn1dir/_3g_csg_description_ie.py index ad5dedf..f28a8e9 100644 --- a/pycrate_csn1dir/_3g_csg_description_ie.py +++ b/pycrate_csn1dir/_3g_csg_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/_3g_csg_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/_3g_priority_parameters_ie.py b/pycrate_csn1dir/_3g_priority_parameters_ie.py index 4965ee5..f20f250 100644 --- a/pycrate_csn1dir/_3g_priority_parameters_ie.py +++ b/pycrate_csn1dir/_3g_priority_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/_3g_priority_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/__init__.py b/pycrate_csn1dir/__init__.py deleted file mode 100644 index b6c3827..0000000 --- a/pycrate_csn1dir/__init__.py +++ /dev/null @@ -1,287 +0,0 @@ - -# -*- coding: UTF-8 -*- -#/** -# * Software Name : pycrate -# * Version : 0.3 -# * -# * Copyright 2018. Benoit Michau. ANSSI. -# * -# * This library is free software; you can redistribute it and/or -# * modify it under the terms of the GNU Lesser General Public -# * License as published by the Free Software Foundation; either -# * version 2.1 of the License, or (at your option) any later version. -# * -# * This library is distributed in the hope that it will be useful, -# * but WITHOUT ANY WARRANTY; without even the implied warranty of -# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# * Lesser General Public License for more details. -# * -# * You should have received a copy of the GNU Lesser General Public -# * License along with this library; if not, write to the Free Software -# * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -# * MA 02110-1301 USA -# * -# *-------------------------------------------------------- -# * File Name : pycrate_csn1dir/_init_.py -# * Created : 2018-07-26 -# * Authors : Benoit Michau -# *-------------------------------------------------------- -#*/ - -__version__ = '0.3.0' -__all__ = [ - '_3g_csg_description_ie', - '_3g_priority_parameters_ie', - 'ack_nack_description_ie', - 'additional_ms_radio_access_capabilities_message_content', - 'ba_list_pref', - 'cell_identification_ie', - 'cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part', - 'channel_request_description_2_value_part', - 'channel_request_description_ie', - 'classmark_3_value_part', - 'compact_reduced_ma_ie', - 'cs_handover_radio_resources_ie', - 'dlmc_channel_quality_report_ie', - 'downlink_rlc_mac_control_message', - 'dtm_handover_command_message_content', - 'dtm_handover_ps_radio_resources_2_ie', - 'dtm_handover_ps_radio_resources_3_ie', - 'dtm_handover_ps_radio_resources_ie', - 'dtm_information_details_value_part', - 'dual_carrier_frequency_parameters_ie', - 'dynamic_allocation_2_ie', - 'dynamic_allocation_3_ie', - 'dynamic_arfcn_mapping', - 'ec_ack_nack_description_ie', - 'ec_channel_quality_report_ie', - 'ec_downlink_assignment_message_content', - 'ec_dummy_message_content', - 'ec_immediate_assignment_reject_message_content', - 'ec_immediate_assignment_type_2_message_content', - 'ec_packet_access_reject_message_content', - 'ec_packet_channel_description_type_1', - 'ec_packet_channel_description_type_2', - 'ec_packet_channel_request_message_content_cc1', - 'ec_packet_control_acknowledgement_message_content', - 'ec_packet_downlink_ack_nack_message_content', - 'ec_packet_downlink_assignment_message_content', - 'ec_packet_downlink_dummy_control_block_message_content', - 'ec_packet_polling_request_message_content', - 'ec_packet_power_control_timing_advance_message_content', - 'ec_packet_tbf_release_message_content', - 'ec_packet_timing_advance_ie', - 'ec_packet_uplink_ack_nack_and_contention_resolution_message_content', - 'ec_packet_uplink_ack_nack_message_content', - 'ec_packet_uplink_assignment_message_content', - 'ec_paging_request_message_content', - 'ec_primary_ack_nack_description_ie', - 'ec_request_reference_description', - 'ec_system_information_type_1', - 'ec_system_information_type_2', - 'ec_system_information_type_3', - 'ec_system_information_type_4', - 'egprs_ack_nack_description_dlmc_ie', - 'egprs_ack_nack_description_ie', - 'egprs_bep_link_quality_measurements_ie', - 'egprs_bep_link_quality_measurements_type_2_ie', - 'egprs_channel_quality_report_ie', - 'egprs_channel_quality_report_type_2_ie', - 'egprs_level_ie', - 'egprs_mode_2_ie', - 'egprs_modulation_and_coding_scheme_ie', - 'egprs_packet_channel_request_message_content', - 'egprs_packet_downlink_ack_nack_dlmc_message_content', - 'egprs_packet_downlink_ack_nack_message_content', - 'egprs_packet_downlink_ack_nack_type_2_message_content', - 'egprs_packet_downlink_ack_nack_type_3_message_content', - 'egprs_timeslot_link_quality_measurements_ie', - 'egprs_timeslot_link_quality_measurements_type_2_ie', - 'egprs_window_size_ie', - 'enhanced_cell_reselection_parameters_ie', - 'enhanced_measurement_report', - 'e_utran_csg_description_ie', - 'e_utran_csg_measurement_report_ie', - 'e_utran_csg_target_cell_ie', - 'e_utran_ipp_with_extended_earfcns_ie', - 'e_utran_nc_with_extended_earfcns_ie', - 'e_utran_parameters_ie', - 'e_utran_target_cell_ie', - 'e_utran_target_cell_with_extended_earfcn_ie', - 'extension_bits_ie', - 'flo_ack_nack_description_ie', - 'frequency_parameters_ie', - 'global_packet_timing_advance_ie', - 'global_power_control_parameters_ie', - 'global_tfi_ie', - 'gprs_broadcast_information_value_part', - 'gprs_cell_options_ie', - 'gprs_mobile_allocation_ie', - 'gprs_power_control_parameters_ie', - 'g_rnti_ie', - 'gsm_priority_parameters_ie', - 'handover_access_8_bit_message', - 'ia_rest_octets', - 'iar_rest_octets', - 'iax_rest_octets', - 'individual_priorities_ie', - 'individual_priorities', - 'ipa_rest_octets', - 'iu_mode_channel_request_description_ie', - 'lsa_parameters_ie', - 'mbms_assignment_distribution_message_content', - 'mbms_assignment_non_distribution_message_content', - 'mbms_channel_parameters_ie', - 'mbms_downlink_ack_nack_message_content', - 'mbms_in_band_signalling_indicator_ie', - 'mbms_ms_id_assignment_message_content', - 'mbms_neighbouring_cell_information_message_content', - 'mbms_p_t_m_channel_description_ie', - 'mbms_p_t_m_channel_description_value_part', - 'mbms_service_request_message_content', - 'mbms_session_identity_value_part', - 'mbms_session_parameters_list_ie', - 'mbms_session_parameters_list_value_part', - 'mbms_sessions_list_ie', - 'measurement_control_parameters_description', - 'measurement_information', - 'measurement_results_contents', - 'mprach_control_parameters_ie', - 'mprach_description_ie', - 'mprach_description_value_part', - 'mprach_packet_channel_request_message_content', - 'ms_network_capability_value_part', - 'ms_ra_capability_value_part', - 'ms_radio_access_capability_2_ie', - 'multiple_downlink_assignment_2_ie', - 'multiple_tbf_downlink_assignment_message_content', - 'multiple_tbf_timeslot_reconfigure_message_content', - 'multiple_tbf_uplink_assignment_message_content', - 'multiple_uplink_assignment_2_ie', - 'nas_container_for_ps_handover_ie', - 'non_gprs_cell_options_ie', - 'notification_facch', - 'ntn_rest_octets', - 'p1_rest_octets', - 'p2_rest_octets', - 'p3_rest_octets', - 'packet_access_reject_message_content', - 'packet_application_information_message_content', - 'packet_cell_change_continue_message_content', - 'packet_cell_change_failure_message_content', - 'packet_cell_change_notification_message_content', - 'packet_cell_change_order_message_content', - 'packet_channel_description', - 'packet_channel_request_11_bit_message_content', - 'packet_control_acknowledgement_message_content', - 'packet_cs_command_message_content', - 'packet_cs_release_message_content', - 'packet_cs_request_message_content', - 'packet_dbpsch_assignment_message_content', - 'packet_dbpsch_downlink_ack_nack_message', - 'packet_dbpsch_downlink_ack_nack_type_2_message', - 'packet_dbpsch_uplink_ack_nack_message_content', - 'packet_dbpsch_uplink_ack_nack_type_2_message_content', - 'packet_downlink_ack_nack_message_content', - 'packet_downlink_assignment_message_content', - 'packet_downlink_dummy_control_block_message_content', - 'packet_enhanced_measurement_report_message_content', - 'packet_mbms_announcement_message_content', - 'packet_measurement_order_message_content', - 'packet_measurement_report_message_content', - 'packet_mobile_tbf_status_message_content', - 'packet_neighbour_cell_data_message_content', - 'packet_paging_request_message_content', - 'packet_pause_message_content', - 'packet_pdch_release_message_content', - 'packet_physical_information_message_content', - 'packet_polling_request_message_content', - 'packet_power_control_timing_advance_message_content', - 'packet_prach_parameters_message_content', - 'packet_psi_status_message_content', - 'packet_queueing_notification_message_content', - 'packet_request_reference_ie', - 'packet_resource_request_message_content', - 'packet_serving_cell_data_message_content', - 'packet_serving_cell_si_message_content', - 'packet_si_status_message_content', - 'packet_tbf_release_message_content', - 'packet_timeslot_reconfigure_message_content', - 'packet_timing_advance_ie', - 'packet_uplink_ack_nack_message_content', - 'packet_uplink_assignment_message_content', - 'packet_uplink_dummy_control_block_message_content', - 'padding_bits', - 'pccch_organization_parameters_ie', - 'pcid_group_ie', - 'pdch_pairs_description_ie', - 'physical_information_message_content', - 'power_control_parameters_ie', - 'prach_control_parameters_ie', - 'psc_group_ie', - 'ps_handover_access_message_content_8_bit_message', - 'ps_handover_command_message_content', - 'ps_handover_radio_resources_2_ie', - 'ps_handover_radio_resources_3_ie', - 'ps_handover_radio_resources_ie', - 'psi13_message_content', - 'psi14_message_content', - 'psi15_message_content', - 'psi16_message_content', - 'psi1_message_content', - 'psi2_message_content', - 'psi3_bis_message_content', - 'psi3_message_content', - 'psi3_quater_message_content', - 'psi3_ter_message_content', - 'psi5_message_content', - 'psi6_message_content', - 'psi8_message_content', - 'pulse_format_ie', - 'receive_npdu_number_list_value', - 'restriction_timer_value_part', - 'rrc_container_ie', - 'rr_packet_downlink_assignment_type_2_value_part', - 'rr_packet_downlink_assignment_value_part', - 'rr_packet_uplink_assignment_value_part', - 'si10bis_rest_octets', - 'si10_rest_octets', - 'si_13alt_rest_octets', - 'si_13_rest_octets', - 'si14_rest_octets', - 'si15_rest_octets', - 'si16_rest_octets', - 'si_18_rest_octets', - 'si_19_rest_octets', - 'si1_rest_octets', - 'si_21_rest_octets', - 'si_22_rest_octets', - 'si_23_rest_octets', - 'si2bis_rest_octets', - 'si2n_rest_octets', - 'si2quater_rest_octets', - 'si2ter_rest_octets', - 'si3_rest_octet', - 'si4_rest_octets', - 'si6_rest_octets', - 'si9_rest_octets', - 'single_downlink_assignment_2_ie', - 'single_uplink_assignment_2_ie', - 'starting_frame_number_description_ie', - 'system_information_type_10bis', - 'system_information_type_10ter', - 'tlli_g_rnti_ie', - 'tmgi_ie', - 'uplink_free', - 'uplink_rlc_mac_control_message', - 'used_dl_coverage_class_ie', - 'utran_csg_measurement_report_ie', - 'utran_csg_target_cell_ie', - 'utran_fdd_target_cell_ie', - 'utran_freq_list', - 'utran_tdd_target_cell_ie', - 'vbs_vgcs_reconfigure2', - 'vbs_vgcs_reconfigure', - 'vgcs_additional_info', - 'vgcs_neighbour_cell_information', - 'vgcs_sms_information'] diff --git a/pycrate_csn1dir/ack_nack_description_ie.py b/pycrate_csn1dir/ack_nack_description_ie.py index b68fe6c..e522a38 100644 --- a/pycrate_csn1dir/ack_nack_description_ie.py +++ b/pycrate_csn1dir/ack_nack_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ack_nack_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/additional_ms_radio_access_capabilities_message_content.py b/pycrate_csn1dir/additional_ms_radio_access_capabilities_message_content.py index 9ad91c4..532c759 100644 --- a/pycrate_csn1dir/additional_ms_radio_access_capabilities_message_content.py +++ b/pycrate_csn1dir/additional_ms_radio_access_capabilities_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/additional_ms_radio_access_capabilities_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: Additional MS Radio Access Capabilities message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.ms_radio_access_capability_2_ie import ms_radio_access_capability_2_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.ms_radio_access_capability_2_ie import ms_radio_access_capability_2_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/ba_list_pref.py b/pycrate_csn1dir/ba_list_pref.py index bc1704e..4f22546 100644 --- a/pycrate_csn1dir/ba_list_pref.py +++ b/pycrate_csn1dir/ba_list_pref.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ba_list_pref.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/cell_identification_ie.py b/pycrate_csn1dir/cell_identification_ie.py index 4522209..23b3a7b 100644 --- a/pycrate_csn1dir/cell_identification_ie.py +++ b/pycrate_csn1dir/cell_identification_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/cell_identification_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.py b/pycrate_csn1dir/cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.py index 1127db8..206816a 100644 --- a/pycrate_csn1dir/cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.py +++ b/pycrate_csn1dir/cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,6 +30,65 @@ # section: 10.5.2.1e Cell selection indicator after release of all TCH and SDCCH IE # top-level object: Cell Selection Indicator after release of all TCH and SDCCH value part +# table 9.1.54.1a +_TransP = { + 0 : 0, + 1 : 10, + 2 : 19, + 3 : 28, + 4 : 36, + 5 : 44, + 6 : 52, + 7 : 60, + 8 : 67, + 9 : 74, + 10: 81, + 11: 88, + 12: 95, + 13: 102, + 14: 109, + 15: 116, + 16: 122 + } + +def trans_p(n): + try: + return _TransP[n] + except: + return 0 + +# table 9.1.54.1b +_TransQ = { + 0 : 0, + 1 : 9, + 2 : 17, + 3 : 25, + 4 : 32, + 5 : 39, + 6 : 46, + 7 : 53, + 8 : 59, + 9 : 65, + 10: 71, + 11: 77, + 12: 83, + 13: 89, + 14: 95, + 15: 101, + 16: 106, + 17: 111, + 18: 116, + 19: 121, + 20: 126 + } + +def trans_q(n): + try: + return _TransQ[n] + except: + return 0 + + # external references from pycrate_csn1dir.pcid_group_ie import pcid_group_ie @@ -40,21 +99,6 @@ from pycrate_csn1dir.pcid_group_ie import pcid_group_ie from pycrate_csn1.csnobj import * -e_utran_description_struct = CSN1List(name='e_utran_description_struct', list=[ - CSN1Bit(name='earfcn', bit=16), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='measurement_bandwidth', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='not_allowed_cells', obj=pcid_group_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='target_pcid', bit=9)])})]) - gsm_description_struct = CSN1List(name='gsm_description_struct', list=[ CSN1Bit(name='band_indicator'), CSN1Bit(name='arfcn', bit=10), @@ -71,7 +115,23 @@ utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', lis '1': ('', [ CSN1Bit(name='tdd_indic0'), CSN1Bit(name='nr_of_tdd_cells', bit=5), - CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))])})]) + #CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))])})]) + CSN1Bit(name='tdd_cell_information_field', bit=([2], trans_q))])})]) + +e_utran_description_struct = CSN1List(name='e_utran_description_struct', list=[ + CSN1Bit(name='earfcn', bit=16), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='measurement_bandwidth', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='not_allowed_cells', obj=pcid_group_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='target_pcid', bit=9)])})]) utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ CSN1Alt(alt={ @@ -84,7 +144,8 @@ utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', lis '1': ('', [ CSN1Bit(name='fdd_indic0'), CSN1Bit(name='nr_of_fdd_cells', bit=5), - CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))])})]) + #CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))])})]) + CSN1Bit(name='fdd_cell_information_field', bit=([2], trans_p))])})]) cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part = CSN1Alt(name='cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part', alt={ '000': ('', [ diff --git a/pycrate_csn1dir/channel_request_description_2_value_part.py b/pycrate_csn1dir/channel_request_description_2_value_part.py index c9ef491..4b5fce0 100644 --- a/pycrate_csn1dir/channel_request_description_2_value_part.py +++ b/pycrate_csn1dir/channel_request_description_2_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/channel_request_description_2_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/channel_request_description_ie.py b/pycrate_csn1dir/channel_request_description_ie.py index 8b04842..a438a8b 100644 --- a/pycrate_csn1dir/channel_request_description_ie.py +++ b/pycrate_csn1dir/channel_request_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/channel_request_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/classmark_3_value_part.py b/pycrate_csn1dir/classmark_3_value_part.py index 2f0ba37..1636e4e 100644 --- a/pycrate_csn1dir/classmark_3_value_part.py +++ b/pycrate_csn1dir/classmark_3_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/classmark_3_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -47,7 +47,19 @@ spare_bits = CSN1Bit(name='spare_bits', num=-1) Spare_bits = spare_bits Spare_Bits = spare_bits -r_support = CSN1Bit(name='r_support', bit=3) +ms_measurement_capability = CSN1List(name='ms_measurement_capability', list=[ + CSN1Bit(name='sms_value', bit=4), + CSN1Bit(name='sm_value', bit=4)]) + +ecsd_multi_slot_capability = CSN1Bit(name='ecsd_multi_slot_capability', bit=5) + +hscsd_multi_slot_capability = CSN1Bit(name='hscsd_multi_slot_capability', bit=5) + +a5_bits = CSN1List(name='a5_bits', list=[ + CSN1Bit(name='a5_7'), + CSN1Bit(name='a5_6'), + CSN1Bit(name='a5_5'), + CSN1Bit(name='a5_4')]) _8_psk_struct = CSN1List(name='_8_psk_struct', list=[ CSN1Bit(name='modulation_capability'), @@ -60,24 +72,12 @@ _8_psk_struct = CSN1List(name='_8_psk_struct', list=[ '1': ('', [ CSN1Bit(name='_8_psk_rf_power_capability_2', bit=2)])})]) -ecsd_multi_slot_capability = CSN1Bit(name='ecsd_multi_slot_capability', bit=5) - -a5_bits = CSN1List(name='a5_bits', list=[ - CSN1Bit(name='a5_7'), - CSN1Bit(name='a5_6'), - CSN1Bit(name='a5_5'), - CSN1Bit(name='a5_4')]) - -hscsd_multi_slot_capability = CSN1Bit(name='hscsd_multi_slot_capability', bit=5) - -ms_measurement_capability = CSN1List(name='ms_measurement_capability', list=[ - CSN1Bit(name='sms_value', bit=4), - CSN1Bit(name='sm_value', bit=4)]) - -ms_positioning_method_capability = CSN1Bit(name='ms_positioning_method_capability', bit=5) +r_support = CSN1Bit(name='r_support', bit=3) single_band_support = CSN1Bit(name='single_band_support', bit=4) +ms_positioning_method_capability = CSN1Bit(name='ms_positioning_method_capability', bit=5) + classmark_3_value_part = CSN1List(name='classmark_3_value_part', trunc=True, list=[ CSN1Ref(obj=spare_bit), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/compact_reduced_ma_ie.py b/pycrate_csn1dir/compact_reduced_ma_ie.py index 535dd68..9ab7822 100644 --- a/pycrate_csn1dir/compact_reduced_ma_ie.py +++ b/pycrate_csn1dir/compact_reduced_ma_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/compact_reduced_ma_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/cs_handover_radio_resources_ie.py b/pycrate_csn1dir/cs_handover_radio_resources_ie.py index 050a45b..2c5515b 100644 --- a/pycrate_csn1dir/cs_handover_radio_resources_ie.py +++ b/pycrate_csn1dir/cs_handover_radio_resources_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/cs_handover_radio_resources_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/dlmc_channel_quality_report_ie.py b/pycrate_csn1dir/dlmc_channel_quality_report_ie.py index 529178a..f1f9a8b 100644 --- a/pycrate_csn1dir/dlmc_channel_quality_report_ie.py +++ b/pycrate_csn1dir/dlmc_channel_quality_report_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dlmc_channel_quality_report_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/downlink_rlc_mac_control_message.py b/pycrate_csn1dir/downlink_rlc_mac_control_message.py index 9a42e46..7d2fa6c 100644 --- a/pycrate_csn1dir/downlink_rlc_mac_control_message.py +++ b/pycrate_csn1dir/downlink_rlc_mac_control_message.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/downlink_rlc_mac_control_message.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,62 +31,62 @@ # top-level object: Downlink RLC/MAC control message # external references -from pycrate_csn1dir.multiple_tbf_uplink_assignment_message_content import multiple_tbf_uplink_assignment_message_content -from pycrate_csn1dir.packet_uplink_assignment_message_content import packet_uplink_assignment_message_content -from pycrate_csn1dir.psi5_message_content import psi5_message_content -from pycrate_csn1dir.psi3_ter_message_content import psi3_ter_message_content -from pycrate_csn1dir.psi3_quater_message_content import psi3_quater_message_content -from pycrate_csn1dir.ec_packet_uplink_ack_nack_message_content import ec_packet_uplink_ack_nack_message_content -from pycrate_csn1dir.packet_paging_request_message_content import packet_paging_request_message_content -from pycrate_csn1dir.multiple_tbf_timeslot_reconfigure_message_content import multiple_tbf_timeslot_reconfigure_message_content -from pycrate_csn1dir.mbms_ms_id_assignment_message_content import mbms_ms_id_assignment_message_content -from pycrate_csn1dir.packet_uplink_ack_nack_message_content import packet_uplink_ack_nack_message_content -from pycrate_csn1dir.packet_prach_parameters_message_content import packet_prach_parameters_message_content -from pycrate_csn1dir.psi2_message_content import psi2_message_content -from pycrate_csn1dir.packet_cell_change_order_message_content import packet_cell_change_order_message_content -from pycrate_csn1dir.ec_packet_power_control_timing_advance_message_content import ec_packet_power_control_timing_advance_message_content -from pycrate_csn1dir.packet_application_information_message_content import packet_application_information_message_content -from pycrate_csn1dir.psi1_message_content import psi1_message_content -from pycrate_csn1dir.mbms_assignment_distribution_message_content import mbms_assignment_distribution_message_content -from pycrate_csn1dir.psi14_message_content import psi14_message_content -from pycrate_csn1dir.psi16_message_content import psi16_message_content -from pycrate_csn1dir.packet_physical_information_message_content import packet_physical_information_message_content -from pycrate_csn1dir.psi13_message_content import psi13_message_content -from pycrate_csn1dir.packet_cs_release_message_content import packet_cs_release_message_content from pycrate_csn1dir.packet_neighbour_cell_data_message_content import packet_neighbour_cell_data_message_content -from pycrate_csn1dir.ec_packet_polling_request_message_content import ec_packet_polling_request_message_content -from pycrate_csn1dir.packet_pdch_release_message_content import packet_pdch_release_message_content -from pycrate_csn1dir.ec_packet_access_reject_message_content import ec_packet_access_reject_message_content -from pycrate_csn1dir.packet_timeslot_reconfigure_message_content import packet_timeslot_reconfigure_message_content -from pycrate_csn1dir.packet_serving_cell_data_message_content import packet_serving_cell_data_message_content -from pycrate_csn1dir.packet_downlink_assignment_message_content import packet_downlink_assignment_message_content -from pycrate_csn1dir.ec_packet_downlink_dummy_control_block_message_content import ec_packet_downlink_dummy_control_block_message_content -from pycrate_csn1dir.multiple_tbf_downlink_assignment_message_content import multiple_tbf_downlink_assignment_message_content -from pycrate_csn1dir.packet_power_control_timing_advance_message_content import packet_power_control_timing_advance_message_content -from pycrate_csn1dir.packet_cs_command_message_content import packet_cs_command_message_content -from pycrate_csn1dir.psi15_message_content import psi15_message_content -from pycrate_csn1dir.dtm_handover_command_message_content import dtm_handover_command_message_content -from pycrate_csn1dir.ec_packet_uplink_assignment_message_content import ec_packet_uplink_assignment_message_content -from pycrate_csn1dir.ec_packet_uplink_ack_nack_and_contention_resolution_message_content import ec_packet_uplink_ack_nack_and_contention_resolution_message_content -from pycrate_csn1dir.ps_handover_command_message_content import ps_handover_command_message_content -from pycrate_csn1dir.packet_queueing_notification_message_content import packet_queueing_notification_message_content -from pycrate_csn1dir.packet_serving_cell_si_message_content import packet_serving_cell_si_message_content -from pycrate_csn1dir.packet_downlink_dummy_control_block_message_content import packet_downlink_dummy_control_block_message_content -from pycrate_csn1dir.psi3_message_content import psi3_message_content -from pycrate_csn1dir.packet_polling_request_message_content import packet_polling_request_message_content -from pycrate_csn1dir.packet_tbf_release_message_content import packet_tbf_release_message_content -from pycrate_csn1dir.psi3_bis_message_content import psi3_bis_message_content -from pycrate_csn1dir.packet_mbms_announcement_message_content import packet_mbms_announcement_message_content -from pycrate_csn1dir.mbms_neighbouring_cell_information_message_content import mbms_neighbouring_cell_information_message_content from pycrate_csn1dir.psi6_message_content import psi6_message_content +from pycrate_csn1dir.psi3_ter_message_content import psi3_ter_message_content +from pycrate_csn1dir.ps_handover_command_message_content import ps_handover_command_message_content +from pycrate_csn1dir.ec_packet_power_control_timing_advance_message_content import ec_packet_power_control_timing_advance_message_content +from pycrate_csn1dir.packet_queueing_notification_message_content import packet_queueing_notification_message_content +from pycrate_csn1dir.ec_packet_access_reject_message_content import ec_packet_access_reject_message_content +from pycrate_csn1dir.dtm_handover_command_message_content import dtm_handover_command_message_content +from pycrate_csn1dir.packet_cs_command_message_content import packet_cs_command_message_content +from pycrate_csn1dir.packet_uplink_ack_nack_message_content import packet_uplink_ack_nack_message_content +from pycrate_csn1dir.psi14_message_content import psi14_message_content +from pycrate_csn1dir.packet_downlink_assignment_message_content import packet_downlink_assignment_message_content +from pycrate_csn1dir.packet_pdch_release_message_content import packet_pdch_release_message_content +from pycrate_csn1dir.psi2_message_content import psi2_message_content +from pycrate_csn1dir.packet_cs_release_message_content import packet_cs_release_message_content +from pycrate_csn1dir.multiple_tbf_timeslot_reconfigure_message_content import multiple_tbf_timeslot_reconfigure_message_content +from pycrate_csn1dir.packet_cell_change_order_message_content import packet_cell_change_order_message_content from pycrate_csn1dir.psi8_message_content import psi8_message_content +from pycrate_csn1dir.ec_packet_downlink_dummy_control_block_message_content import ec_packet_downlink_dummy_control_block_message_content +from pycrate_csn1dir.packet_tbf_release_message_content import packet_tbf_release_message_content +from pycrate_csn1dir.ec_packet_uplink_ack_nack_message_content import ec_packet_uplink_ack_nack_message_content +from pycrate_csn1dir.multiple_tbf_downlink_assignment_message_content import multiple_tbf_downlink_assignment_message_content +from pycrate_csn1dir.mbms_ms_id_assignment_message_content import mbms_ms_id_assignment_message_content from pycrate_csn1dir.packet_access_reject_message_content import packet_access_reject_message_content -from pycrate_csn1dir.ec_packet_downlink_assignment_message_content import ec_packet_downlink_assignment_message_content -from pycrate_csn1dir.packet_dbpsch_assignment_message_content import packet_dbpsch_assignment_message_content -from pycrate_csn1dir.mbms_assignment_non_distribution_message_content import mbms_assignment_non_distribution_message_content -from pycrate_csn1dir.ec_packet_tbf_release_message_content import ec_packet_tbf_release_message_content +from pycrate_csn1dir.packet_uplink_assignment_message_content import packet_uplink_assignment_message_content +from pycrate_csn1dir.ec_packet_uplink_ack_nack_and_contention_resolution_message_content import ec_packet_uplink_ack_nack_and_contention_resolution_message_content from pycrate_csn1dir.packet_cell_change_continue_message_content import packet_cell_change_continue_message_content +from pycrate_csn1dir.psi16_message_content import psi16_message_content +from pycrate_csn1dir.ec_packet_downlink_assignment_message_content import ec_packet_downlink_assignment_message_content +from pycrate_csn1dir.packet_timeslot_reconfigure_message_content import packet_timeslot_reconfigure_message_content from pycrate_csn1dir.packet_measurement_order_message_content import packet_measurement_order_message_content +from pycrate_csn1dir.packet_downlink_dummy_control_block_message_content import packet_downlink_dummy_control_block_message_content +from pycrate_csn1dir.psi15_message_content import psi15_message_content +from pycrate_csn1dir.packet_power_control_timing_advance_message_content import packet_power_control_timing_advance_message_content +from pycrate_csn1dir.ec_packet_uplink_assignment_message_content import ec_packet_uplink_assignment_message_content +from pycrate_csn1dir.packet_physical_information_message_content import packet_physical_information_message_content +from pycrate_csn1dir.packet_serving_cell_si_message_content import packet_serving_cell_si_message_content +from pycrate_csn1dir.packet_application_information_message_content import packet_application_information_message_content +from pycrate_csn1dir.multiple_tbf_uplink_assignment_message_content import multiple_tbf_uplink_assignment_message_content +from pycrate_csn1dir.mbms_neighbouring_cell_information_message_content import mbms_neighbouring_cell_information_message_content +from pycrate_csn1dir.packet_serving_cell_data_message_content import packet_serving_cell_data_message_content +from pycrate_csn1dir.psi3_quater_message_content import psi3_quater_message_content +from pycrate_csn1dir.packet_mbms_announcement_message_content import packet_mbms_announcement_message_content +from pycrate_csn1dir.mbms_assignment_non_distribution_message_content import mbms_assignment_non_distribution_message_content +from pycrate_csn1dir.packet_dbpsch_assignment_message_content import packet_dbpsch_assignment_message_content +from pycrate_csn1dir.psi3_message_content import psi3_message_content +from pycrate_csn1dir.psi3_bis_message_content import psi3_bis_message_content +from pycrate_csn1dir.packet_prach_parameters_message_content import packet_prach_parameters_message_content +from pycrate_csn1dir.ec_packet_polling_request_message_content import ec_packet_polling_request_message_content +from pycrate_csn1dir.psi1_message_content import psi1_message_content +from pycrate_csn1dir.packet_polling_request_message_content import packet_polling_request_message_content +from pycrate_csn1dir.ec_packet_tbf_release_message_content import ec_packet_tbf_release_message_content +from pycrate_csn1dir.psi5_message_content import psi5_message_content +from pycrate_csn1dir.psi13_message_content import psi13_message_content +from pycrate_csn1dir.mbms_assignment_distribution_message_content import mbms_assignment_distribution_message_content +from pycrate_csn1dir.packet_paging_request_message_content import packet_paging_request_message_content # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -95,36 +95,12 @@ from pycrate_csn1dir.packet_measurement_order_message_content import packet_meas from pycrate_csn1.csnobj import * -default_downlink_message_content_on_ec_pacch = CSN1List(name='default_downlink_message_content_on_ec_pacch', list=[ - CSN1Bit(name='used_dl_coverage_class', bit=2), - CSN1Bit(bit=-1)]) - psi7_message_content = CSN1Ref(name='psi7_message_content', obj=psi6_message_content) default_downlink_message_content = CSN1List(name='default_downlink_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1Bit(bit=-1)]) -downlink_rlc_mac_control_message_on_ec_pacch = CSN1Alt(name='downlink_rlc_mac_control_message_on_ec_pacch', alt={ - '00001': ('message_type', [ - CSN1Ref(obj=ec_packet_downlink_assignment_message_content)]), - '00010': ('message_type', [ - CSN1Ref(obj=ec_packet_polling_request_message_content)]), - '00011': ('message_type', [ - CSN1Ref(obj=ec_packet_power_control_timing_advance_message_content)]), - '00100': ('message_type', [ - CSN1Ref(obj=ec_packet_tbf_release_message_content)]), - '00101': ('message_type', [ - CSN1Ref(obj=ec_packet_uplink_ack_nack_message_content)]), - '00110': ('message_type', [ - CSN1Ref(obj=ec_packet_uplink_assignment_message_content)]), - '00111': ('message_type', [ - CSN1Ref(obj=ec_packet_uplink_ack_nack_and_contention_resolution_message_content)]), - '10001': ('message_type', [ - CSN1Ref(obj=ec_packet_access_reject_message_content)]), - '10010': ('message_type', [ - CSN1Ref(obj=ec_packet_downlink_dummy_control_block_message_content)])}) - downlink_rlc_mac_control_message = CSN1Alt(name='downlink_rlc_mac_control_message', alt={ '000001': ('message_type', [ CSN1Ref(obj=packet_cell_change_order_message_content)]), @@ -223,3 +199,27 @@ downlink_rlc_mac_control_message = CSN1Alt(name='downlink_rlc_mac_control_messag '111110': ('message_type', [ CSN1Ref(obj=psi15_message_content)])}) +default_downlink_message_content_on_ec_pacch = CSN1List(name='default_downlink_message_content_on_ec_pacch', list=[ + CSN1Bit(name='used_dl_coverage_class', bit=2), + CSN1Bit(bit=-1)]) + +downlink_rlc_mac_control_message_on_ec_pacch = CSN1Alt(name='downlink_rlc_mac_control_message_on_ec_pacch', alt={ + '00001': ('message_type', [ + CSN1Ref(obj=ec_packet_downlink_assignment_message_content)]), + '00010': ('message_type', [ + CSN1Ref(obj=ec_packet_polling_request_message_content)]), + '00011': ('message_type', [ + CSN1Ref(obj=ec_packet_power_control_timing_advance_message_content)]), + '00100': ('message_type', [ + CSN1Ref(obj=ec_packet_tbf_release_message_content)]), + '00101': ('message_type', [ + CSN1Ref(obj=ec_packet_uplink_ack_nack_message_content)]), + '00110': ('message_type', [ + CSN1Ref(obj=ec_packet_uplink_assignment_message_content)]), + '00111': ('message_type', [ + CSN1Ref(obj=ec_packet_uplink_ack_nack_and_contention_resolution_message_content)]), + '10001': ('message_type', [ + CSN1Ref(obj=ec_packet_access_reject_message_content)]), + '10010': ('message_type', [ + CSN1Ref(obj=ec_packet_downlink_dummy_control_block_message_content)])}) + diff --git a/pycrate_csn1dir/dtm_handover_command_message_content.py b/pycrate_csn1dir/dtm_handover_command_message_content.py index c214a75..c507f11 100644 --- a/pycrate_csn1dir/dtm_handover_command_message_content.py +++ b/pycrate_csn1dir/dtm_handover_command_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dtm_handover_command_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,14 +31,14 @@ # top-level object: DTM Handover Command message content # external references -from pycrate_csn1dir.rrc_container_ie import rrc_container_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.cs_handover_radio_resources_ie import cs_handover_radio_resources_ie +from pycrate_csn1dir.rrc_container_ie import rrc_container_ie +from pycrate_csn1dir.nas_container_for_ps_handover_ie import nas_container_for_ps_handover_ie +from pycrate_csn1dir.dtm_handover_ps_radio_resources_3_ie import dtm_handover_ps_radio_resources_3_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.dtm_handover_ps_radio_resources_2_ie import dtm_handover_ps_radio_resources_2_ie from pycrate_csn1dir.dtm_handover_ps_radio_resources_ie import dtm_handover_ps_radio_resources_ie -from pycrate_csn1dir.dtm_handover_ps_radio_resources_3_ie import dtm_handover_ps_radio_resources_3_ie -from pycrate_csn1dir.nas_container_for_ps_handover_ie import nas_container_for_ps_handover_ie -from pycrate_csn1dir.cs_handover_radio_resources_ie import cs_handover_radio_resources_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/dtm_handover_ps_radio_resources_2_ie.py b/pycrate_csn1dir/dtm_handover_ps_radio_resources_2_ie.py index bf6527d..11196d7 100644 --- a/pycrate_csn1dir/dtm_handover_ps_radio_resources_2_ie.py +++ b/pycrate_csn1dir/dtm_handover_ps_radio_resources_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dtm_handover_ps_radio_resources_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -34,8 +34,8 @@ from pycrate_csn1dir.egprs_mode_2_ie import egprs_mode_2_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.cell_identification_ie import cell_identification_ie -from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_parameters_ie +from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/dtm_handover_ps_radio_resources_3_ie.py b/pycrate_csn1dir/dtm_handover_ps_radio_resources_3_ie.py index 8b564f8..9b6a95f 100644 --- a/pycrate_csn1dir/dtm_handover_ps_radio_resources_3_ie.py +++ b/pycrate_csn1dir/dtm_handover_ps_radio_resources_3_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dtm_handover_ps_radio_resources_3_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -34,8 +34,8 @@ from pycrate_csn1dir.egprs_mode_2_ie import egprs_mode_2_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.cell_identification_ie import cell_identification_ie -from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_parameters_ie +from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/dtm_handover_ps_radio_resources_ie.py b/pycrate_csn1dir/dtm_handover_ps_radio_resources_ie.py index ccc69dc..bfa5cb2 100644 --- a/pycrate_csn1dir/dtm_handover_ps_radio_resources_ie.py +++ b/pycrate_csn1dir/dtm_handover_ps_radio_resources_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dtm_handover_ps_radio_resources_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: DTM Handover PS Radio Resources IE # external references -from pycrate_csn1dir.cell_identification_ie import cell_identification_ie -from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.cell_identification_ie import cell_identification_ie from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_parameters_ie @@ -58,6 +58,10 @@ downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', '1': ('', [ CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])})]) +downlink_assignment_struct = CSN1List(name='downlink_assignment_struct', list=[ + CSN1Bit(name='timeslot_allocation', bit=8), + CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]) + timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ '0': ('', [ CSN1Bit(name='ms_timeslot_allocation', bit=8)]), @@ -130,9 +134,23 @@ uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', lis '1': ('', [ CSN1Bit(name='usf_allocation', bit=3)])})])})]) -downlink_assignment_struct = CSN1List(name='downlink_assignment_struct', list=[ - CSN1Bit(name='timeslot_allocation', bit=8), - CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]) +gprs_mode_struct = CSN1List(name='gprs_mode_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='channel_coding_command', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='global_timeslot_description', obj=timeslot_description_struct), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='uplink_assignment', obj=uplink_tbf_assignment_struct)]), + CSN1Val(name='', val='0')])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='downlink_assignment', obj=downlink_assignment_struct)]), + CSN1Val(name='', val='0')]) egprs_mode_struct = CSN1List(name='egprs_mode_struct', list=[ CSN1List(list=[ @@ -176,24 +194,6 @@ egprs_mode_struct = CSN1List(name='egprs_mode_struct', list=[ CSN1Ref(name='downlink_assignment', obj=downlink_assignment_struct)]), CSN1Val(name='', val='0')])})]) -gprs_mode_struct = CSN1List(name='gprs_mode_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='channel_coding_command', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='global_timeslot_description', obj=timeslot_description_struct), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='uplink_assignment', obj=uplink_tbf_assignment_struct)]), - CSN1Val(name='', val='0')])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='downlink_assignment', obj=downlink_assignment_struct)]), - CSN1Val(name='', val='0')]) - dtm_handover_ps_radio_resources_ie = CSN1List(name='dtm_handover_ps_radio_resources_ie', list=[ CSN1Ref(name='cell_identification', obj=cell_identification_ie), CSN1Bit(name='max_lapdm', bit=3), diff --git a/pycrate_csn1dir/dtm_information_details_value_part.py b/pycrate_csn1dir/dtm_information_details_value_part.py index f330bdf..4b0367b 100644 --- a/pycrate_csn1dir/dtm_information_details_value_part.py +++ b/pycrate_csn1dir/dtm_information_details_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dtm_information_details_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/dual_carrier_frequency_parameters_ie.py b/pycrate_csn1dir/dual_carrier_frequency_parameters_ie.py index c3c8eb1..08c31b0 100644 --- a/pycrate_csn1dir/dual_carrier_frequency_parameters_ie.py +++ b/pycrate_csn1dir/dual_carrier_frequency_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dual_carrier_frequency_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -40,7 +40,7 @@ from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie from pycrate_csn1.csnobj import * -dual_carrier_direct_encoding_2_struct = CSN1List(name='dual_carrier_direct_encoding_2_struct', list=[ +dual_carrier_direct_encoding_1_struct = CSN1List(name='dual_carrier_direct_encoding_1_struct', list=[ CSN1Alt(alt={ '0': ('', []), '1': ('', [ @@ -49,9 +49,7 @@ dual_carrier_direct_encoding_2_struct = CSN1List(name='dual_carrier_direct_encod '0': ('', []), '1': ('', [ CSN1Bit(name='maio2', bit=6)])}), - CSN1Bit(name='hsn', bit=6), - CSN1Bit(name='length_of_ma_frequency_list_contents', bit=4), - CSN1Bit(name='ma_frequency_list_contents', bit=8, num=([3], lambda x: x + 3))]) + CSN1Ref(name='gprs_mobile_allocation', obj=gprs_mobile_allocation_ie)]) dual_carrier_indirect_encoding_struct = CSN1List(name='dual_carrier_indirect_encoding_struct', list=[ CSN1Alt(alt={ @@ -72,7 +70,7 @@ dual_carrier_indirect_encoding_struct = CSN1List(name='dual_carrier_indirect_enc '1': ('', [ CSN1Bit(name='change_mark_2', bit=2)])})])})]) -dual_carrier_direct_encoding_1_struct = CSN1List(name='dual_carrier_direct_encoding_1_struct', list=[ +dual_carrier_direct_encoding_2_struct = CSN1List(name='dual_carrier_direct_encoding_2_struct', list=[ CSN1Alt(alt={ '0': ('', []), '1': ('', [ @@ -81,7 +79,9 @@ dual_carrier_direct_encoding_1_struct = CSN1List(name='dual_carrier_direct_encod '0': ('', []), '1': ('', [ CSN1Bit(name='maio2', bit=6)])}), - CSN1Ref(name='gprs_mobile_allocation', obj=gprs_mobile_allocation_ie)]) + CSN1Bit(name='hsn', bit=6), + CSN1Bit(name='length_of_ma_frequency_list_contents', bit=4), + CSN1Bit(name='ma_frequency_list_contents', bit=8, num=([3], lambda x: x + 3))]) dual_carrier_frequency_parameters_ie = CSN1List(name='dual_carrier_frequency_parameters_ie', list=[ CSN1Bit(name='tsc', bit=3), diff --git a/pycrate_csn1dir/dynamic_allocation_2_ie.py b/pycrate_csn1dir/dynamic_allocation_2_ie.py index 0ee203c..d2eb3b0 100644 --- a/pycrate_csn1dir/dynamic_allocation_2_ie.py +++ b/pycrate_csn1dir/dynamic_allocation_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dynamic_allocation_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/dynamic_allocation_3_ie.py b/pycrate_csn1dir/dynamic_allocation_3_ie.py index 2632979..27f8240 100644 --- a/pycrate_csn1dir/dynamic_allocation_3_ie.py +++ b/pycrate_csn1dir/dynamic_allocation_3_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dynamic_allocation_3_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/dynamic_arfcn_mapping.py b/pycrate_csn1dir/dynamic_arfcn_mapping.py index f8da218..160fdb5 100644 --- a/pycrate_csn1dir/dynamic_arfcn_mapping.py +++ b/pycrate_csn1dir/dynamic_arfcn_mapping.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. P1sec. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/dynamic_arfcn_mapping.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/e_utran_csg_description_ie.py b/pycrate_csn1dir/e_utran_csg_description_ie.py index 67a2c0f..354be63 100644 --- a/pycrate_csn1dir/e_utran_csg_description_ie.py +++ b/pycrate_csn1dir/e_utran_csg_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_csg_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/e_utran_csg_measurement_report_ie.py b/pycrate_csn1dir/e_utran_csg_measurement_report_ie.py index a7e2240..c88254d 100644 --- a/pycrate_csn1dir/e_utran_csg_measurement_report_ie.py +++ b/pycrate_csn1dir/e_utran_csg_measurement_report_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_csg_measurement_report_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/e_utran_csg_target_cell_ie.py b/pycrate_csn1dir/e_utran_csg_target_cell_ie.py index 1029bce..80fc83e 100644 --- a/pycrate_csn1dir/e_utran_csg_target_cell_ie.py +++ b/pycrate_csn1dir/e_utran_csg_target_cell_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_csg_target_cell_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/e_utran_ipp_with_extended_earfcns_ie.py b/pycrate_csn1dir/e_utran_ipp_with_extended_earfcns_ie.py index 5f9fc36..0c67fb1 100644 --- a/pycrate_csn1dir/e_utran_ipp_with_extended_earfcns_ie.py +++ b/pycrate_csn1dir/e_utran_ipp_with_extended_earfcns_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_ipp_with_extended_earfcns_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/e_utran_nc_with_extended_earfcns_ie.py b/pycrate_csn1dir/e_utran_nc_with_extended_earfcns_ie.py index f382ace..ee2d8cf 100644 --- a/pycrate_csn1dir/e_utran_nc_with_extended_earfcns_ie.py +++ b/pycrate_csn1dir/e_utran_nc_with_extended_earfcns_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_nc_with_extended_earfcns_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/e_utran_parameters_ie.py b/pycrate_csn1dir/e_utran_parameters_ie.py index 24e5f72..74c07af 100644 --- a/pycrate_csn1dir/e_utran_parameters_ie.py +++ b/pycrate_csn1dir/e_utran_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -79,13 +79,6 @@ repeated_e_utran_pcid_to_ta_mapping_struct = CSN1List(name='repeated_e_utran_pci CSN1Bit(name='e_utran_frequency_index', bit=3)]), CSN1Val(name='', val='0')]) -repeated_e_utran_not_allowed_cells_struct = CSN1List(name='repeated_e_utran_not_allowed_cells_struct', list=[ - CSN1Ref(name='not_allowed_cells', obj=pcid_group_ie), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='e_utran_frequency_index', bit=3)]), - CSN1Val(name='', val='0')]) - repeated_e_utran_neighbour_cells_struct = CSN1List(name='repeated_e_utran_neighbour_cells_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -109,6 +102,13 @@ repeated_e_utran_neighbour_cells_struct = CSN1List(name='repeated_e_utran_neighb '1': ('', [ CSN1Bit(name='e_utran_qrxlevmin', bit=5)])})]) +repeated_e_utran_not_allowed_cells_struct = CSN1List(name='repeated_e_utran_not_allowed_cells_struct', list=[ + CSN1Ref(name='not_allowed_cells', obj=pcid_group_ie), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='e_utran_frequency_index', bit=3)]), + CSN1Val(name='', val='0')]) + e_utran_parameters_ie = CSN1List(name='e_utran_parameters_ie', list=[ CSN1Bit(name='e_utran_ccn_active'), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/e_utran_target_cell_ie.py b/pycrate_csn1dir/e_utran_target_cell_ie.py index b89fa57..ac91073 100644 --- a/pycrate_csn1dir/e_utran_target_cell_ie.py +++ b/pycrate_csn1dir/e_utran_target_cell_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_target_cell_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/e_utran_target_cell_with_extended_earfcn_ie.py b/pycrate_csn1dir/e_utran_target_cell_with_extended_earfcn_ie.py index 842b743..e2597fd 100644 --- a/pycrate_csn1dir/e_utran_target_cell_with_extended_earfcn_ie.py +++ b/pycrate_csn1dir/e_utran_target_cell_with_extended_earfcn_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/e_utran_target_cell_with_extended_earfcn_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_ack_nack_description_ie.py b/pycrate_csn1dir/ec_ack_nack_description_ie.py index da01cee..915455d 100644 --- a/pycrate_csn1dir/ec_ack_nack_description_ie.py +++ b/pycrate_csn1dir/ec_ack_nack_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_ack_nack_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_channel_quality_report_ie.py b/pycrate_csn1dir/ec_channel_quality_report_ie.py index 7dd229e..983eeab 100644 --- a/pycrate_csn1dir/ec_channel_quality_report_ie.py +++ b/pycrate_csn1dir/ec_channel_quality_report_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_channel_quality_report_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_downlink_assignment_message_content.py b/pycrate_csn1dir/ec_downlink_assignment_message_content.py index a71496b..383f1c1 100644 --- a/pycrate_csn1dir/ec_downlink_assignment_message_content.py +++ b/pycrate_csn1dir/ec_downlink_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_downlink_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_downlink_assignment_message_type_2_content.py b/pycrate_csn1dir/ec_downlink_assignment_message_type_2_content.py index 737baa8..f8904ee 100644 --- a/pycrate_csn1dir/ec_downlink_assignment_message_type_2_content.py +++ b/pycrate_csn1dir/ec_downlink_assignment_message_type_2_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. P1sec. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_downlink_assignment_message_type_2_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_dummy_message_content.py b/pycrate_csn1dir/ec_dummy_message_content.py index e05a6e2..17cbaa7 100644 --- a/pycrate_csn1dir/ec_dummy_message_content.py +++ b/pycrate_csn1dir/ec_dummy_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_dummy_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_immediate_assignment_reject_message_content.py b/pycrate_csn1dir/ec_immediate_assignment_reject_message_content.py index 6dca7fc..9742a63 100644 --- a/pycrate_csn1dir/ec_immediate_assignment_reject_message_content.py +++ b/pycrate_csn1dir/ec_immediate_assignment_reject_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_immediate_assignment_reject_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_immediate_assignment_type_2_message_content.py b/pycrate_csn1dir/ec_immediate_assignment_type_2_message_content.py index 799807a..648201f 100644 --- a/pycrate_csn1dir/ec_immediate_assignment_type_2_message_content.py +++ b/pycrate_csn1dir/ec_immediate_assignment_type_2_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_immediate_assignment_type_2_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_immediate_assignment_type_3_message_content.py b/pycrate_csn1dir/ec_immediate_assignment_type_3_message_content.py index 2039ade..fc0fb78 100644 --- a/pycrate_csn1dir/ec_immediate_assignment_type_3_message_content.py +++ b/pycrate_csn1dir/ec_immediate_assignment_type_3_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. P1sec. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_immediate_assignment_type_3_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_immediate_assignment_type_4_message_content.py b/pycrate_csn1dir/ec_immediate_assignment_type_4_message_content.py index 7bbb47b..09dbcfa 100644 --- a/pycrate_csn1dir/ec_immediate_assignment_type_4_message_content.py +++ b/pycrate_csn1dir/ec_immediate_assignment_type_4_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. P1sec. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,13 +22,13 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_immediate_assignment_type_4_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ # specification: TS 44.018 - d80 # section: 9.1.66 EC IMMEDIATE ASSIGNMENT TYPE 4 -# top-level object: EC IMMEDIATE ASSIGNMENT TYPE 4 message content +# top-level object: EC IMMEDIATE ASSIGNMENT TYPE 4 message content diff --git a/pycrate_csn1dir/ec_packet_access_reject_message_content.py b/pycrate_csn1dir/ec_packet_access_reject_message_content.py index 3821105..52345f5 100644 --- a/pycrate_csn1dir/ec_packet_access_reject_message_content.py +++ b/pycrate_csn1dir/ec_packet_access_reject_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_access_reject_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_packet_channel_description_type_1.py b/pycrate_csn1dir/ec_packet_channel_description_type_1.py index 6b34a5d..0773b36 100644 --- a/pycrate_csn1dir/ec_packet_channel_description_type_1.py +++ b/pycrate_csn1dir/ec_packet_channel_description_type_1.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_channel_description_type_1.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_packet_channel_description_type_2.py b/pycrate_csn1dir/ec_packet_channel_description_type_2.py index 25b91ad..af69e94 100644 --- a/pycrate_csn1dir/ec_packet_channel_description_type_2.py +++ b/pycrate_csn1dir/ec_packet_channel_description_type_2.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_channel_description_type_2.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_packet_channel_request_message_content_cc1.py b/pycrate_csn1dir/ec_packet_channel_request_message_content_cc1.py index 2999f00..2305b16 100644 --- a/pycrate_csn1dir/ec_packet_channel_request_message_content_cc1.py +++ b/pycrate_csn1dir/ec_packet_channel_request_message_content_cc1.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_channel_request_message_content_cc1.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -45,13 +45,13 @@ ec_packet_channel_request_message_content_cc3 = CSN1List(name='ec_packet_channel CSN1Bit(name='randombits', bit=3), CSN1Bit(name='selected_dl_coverage_class', bit=3)]) -ec_packet_channel_request_message_content_cc4 = CSN1List(name='ec_packet_channel_request_message_content_cc4', list=[ +ec_packet_channel_request_message_content_cc1 = CSN1List(name='ec_packet_channel_request_message_content_cc1', list=[ CSN1Bit(name='ec_numberofblocks', bit=3), CSN1Bit(name='ec_priority'), CSN1Bit(name='randombits', bit=3), CSN1Bit(name='selected_dl_coverage_class', bit=3)]) -ec_packet_channel_request_message_content_cc1 = CSN1List(name='ec_packet_channel_request_message_content_cc1', list=[ +ec_packet_channel_request_message_content_cc4 = CSN1List(name='ec_packet_channel_request_message_content_cc4', list=[ CSN1Bit(name='ec_numberofblocks', bit=3), CSN1Bit(name='ec_priority'), CSN1Bit(name='randombits', bit=3), diff --git a/pycrate_csn1dir/ec_packet_control_acknowledgement_message_content.py b/pycrate_csn1dir/ec_packet_control_acknowledgement_message_content.py index 075fb66..f410b5f 100644 --- a/pycrate_csn1dir/ec_packet_control_acknowledgement_message_content.py +++ b/pycrate_csn1dir/ec_packet_control_acknowledgement_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_control_acknowledgement_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_packet_downlink_ack_nack_message_content.py b/pycrate_csn1dir/ec_packet_downlink_ack_nack_message_content.py index 65b8d95..e001c84 100644 --- a/pycrate_csn1dir/ec_packet_downlink_ack_nack_message_content.py +++ b/pycrate_csn1dir/ec_packet_downlink_ack_nack_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_downlink_ack_nack_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: EC Packet Downlink Ack/Nack message content # external references -from pycrate_csn1dir.ec_ack_nack_description_ie import ec_ack_nack_description_ie -from pycrate_csn1dir.ec_channel_quality_report_ie import ec_channel_quality_report_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.ec_channel_quality_report_ie import ec_channel_quality_report_ie +from pycrate_csn1dir.ec_ack_nack_description_ie import ec_ack_nack_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/ec_packet_downlink_assignment_message_content.py b/pycrate_csn1dir/ec_packet_downlink_assignment_message_content.py index 665dad7..8fe8d6f 100644 --- a/pycrate_csn1dir/ec_packet_downlink_assignment_message_content.py +++ b/pycrate_csn1dir/ec_packet_downlink_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_downlink_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: EC Packet Downlink Assignment message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.used_dl_coverage_class_ie import used_dl_coverage_class_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/ec_packet_downlink_dummy_control_block_message_content.py b/pycrate_csn1dir/ec_packet_downlink_dummy_control_block_message_content.py index c6d2a3c..32b913b 100644 --- a/pycrate_csn1dir/ec_packet_downlink_dummy_control_block_message_content.py +++ b/pycrate_csn1dir/ec_packet_downlink_dummy_control_block_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_downlink_dummy_control_block_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_packet_polling_request_message_content.py b/pycrate_csn1dir/ec_packet_polling_request_message_content.py index 8a15262..287f60c 100644 --- a/pycrate_csn1dir/ec_packet_polling_request_message_content.py +++ b/pycrate_csn1dir/ec_packet_polling_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_polling_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: EC Packet Polling Request message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.used_dl_coverage_class_ie import used_dl_coverage_class_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/ec_packet_power_control_timing_advance_message_content.py b/pycrate_csn1dir/ec_packet_power_control_timing_advance_message_content.py index 6fd46c5..19210a1 100644 --- a/pycrate_csn1dir/ec_packet_power_control_timing_advance_message_content.py +++ b/pycrate_csn1dir/ec_packet_power_control_timing_advance_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_power_control_timing_advance_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: EC Packet Power Control/Timing Advance message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.used_dl_coverage_class_ie import used_dl_coverage_class_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/ec_packet_tbf_release_message_content.py b/pycrate_csn1dir/ec_packet_tbf_release_message_content.py index 5da353c..f7065d7 100644 --- a/pycrate_csn1dir/ec_packet_tbf_release_message_content.py +++ b/pycrate_csn1dir/ec_packet_tbf_release_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_tbf_release_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_packet_timing_advance_ie.py b/pycrate_csn1dir/ec_packet_timing_advance_ie.py index 6eb833a..f237e1e 100644 --- a/pycrate_csn1dir/ec_packet_timing_advance_ie.py +++ b/pycrate_csn1dir/ec_packet_timing_advance_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_timing_advance_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_packet_uplink_ack_nack_and_contention_resolution_message_content.py b/pycrate_csn1dir/ec_packet_uplink_ack_nack_and_contention_resolution_message_content.py index 15de63a..4aabab5 100644 --- a/pycrate_csn1dir/ec_packet_uplink_ack_nack_and_contention_resolution_message_content.py +++ b/pycrate_csn1dir/ec_packet_uplink_ack_nack_and_contention_resolution_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_uplink_ack_nack_and_contention_resolution_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: EC Packet Uplink Ack/Nack and Contention Resolution message content # external references -from pycrate_csn1dir.ec_primary_ack_nack_description_ie import ec_primary_ack_nack_description_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.ec_primary_ack_nack_description_ie import ec_primary_ack_nack_description_ie from pycrate_csn1dir.used_dl_coverage_class_ie import used_dl_coverage_class_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/ec_packet_uplink_ack_nack_message_content.py b/pycrate_csn1dir/ec_packet_uplink_ack_nack_message_content.py index be091cb..35b0e36 100644 --- a/pycrate_csn1dir/ec_packet_uplink_ack_nack_message_content.py +++ b/pycrate_csn1dir/ec_packet_uplink_ack_nack_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_uplink_ack_nack_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,11 +31,11 @@ # top-level object: EC Packet Uplink Ack/Nack message content # external references +from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.ec_primary_ack_nack_description_ie import ec_primary_ack_nack_description_ie +from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie from pycrate_csn1dir.used_dl_coverage_class_ie import used_dl_coverage_class_ie from pycrate_csn1dir.ec_ack_nack_description_ie import ec_ack_nack_description_ie -from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/ec_packet_uplink_assignment_message_content.py b/pycrate_csn1dir/ec_packet_uplink_assignment_message_content.py index 45194de..ba070d1 100644 --- a/pycrate_csn1dir/ec_packet_uplink_assignment_message_content.py +++ b/pycrate_csn1dir/ec_packet_uplink_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_packet_uplink_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: EC Packet Uplink Assignment message content # external references +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.ec_packet_timing_advance_ie import ec_packet_timing_advance_ie -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.used_dl_coverage_class_ie import used_dl_coverage_class_ie # code automatically generated by pycrate_csn1 @@ -44,6 +44,11 @@ from pycrate_csn1dir.used_dl_coverage_class_ie import used_dl_coverage_class_ie from pycrate_csn1.csnobj import * +frequency_parameters_struct = CSN1List(name='frequency_parameters_struct', list=[ + CSN1Bit(name='ec_ma_number', bit=5), + CSN1Bit(name='tsc', bit=3), + CSN1Bit(name='primary_tsc_set')]) + fixed_uplink_allocation_struct = CSN1List(name='fixed_uplink_allocation_struct', list=[ CSN1Bit(name='start_first_ul_rlc_data_block', bit=4), CSN1List(num=-1, list=[ @@ -54,11 +59,6 @@ fixed_uplink_allocation_struct = CSN1List(name='fixed_uplink_allocation_struct', '1': ('', [])})]), CSN1Val(name='', val='0')]) -frequency_parameters_struct = CSN1List(name='frequency_parameters_struct', list=[ - CSN1Bit(name='ec_ma_number', bit=5), - CSN1Bit(name='tsc', bit=3), - CSN1Bit(name='primary_tsc_set')]) - ec_packet_uplink_assignment_message_content = CSN1List(name='ec_packet_uplink_assignment_message_content', list=[ CSN1Ref(name='used_dl_coverage_class', obj=used_dl_coverage_class_ie), CSN1List(list=[ diff --git a/pycrate_csn1dir/ec_paging_indication.py b/pycrate_csn1dir/ec_paging_indication.py index f05c1e5..5887ac8 100644 --- a/pycrate_csn1dir/ec_paging_indication.py +++ b/pycrate_csn1dir/ec_paging_indication.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. P1sec. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_paging_indication.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_paging_request_message_content.py b/pycrate_csn1dir/ec_paging_request_message_content.py index 48561ef..1de4f76 100644 --- a/pycrate_csn1dir/ec_paging_request_message_content.py +++ b/pycrate_csn1dir/ec_paging_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_paging_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_primary_ack_nack_description_ie.py b/pycrate_csn1dir/ec_primary_ack_nack_description_ie.py index e0d68be..51b26f3 100644 --- a/pycrate_csn1dir/ec_primary_ack_nack_description_ie.py +++ b/pycrate_csn1dir/ec_primary_ack_nack_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_primary_ack_nack_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_request_reference_description.py b/pycrate_csn1dir/ec_request_reference_description.py index 596419d..83db7bf 100644 --- a/pycrate_csn1dir/ec_request_reference_description.py +++ b/pycrate_csn1dir/ec_request_reference_description.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_request_reference_description.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ec_system_information_type_1.py b/pycrate_csn1dir/ec_system_information_type_1.py index 85b6ec7..4f1b6e5 100644 --- a/pycrate_csn1dir/ec_system_information_type_1.py +++ b/pycrate_csn1dir/ec_system_information_type_1.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_system_information_type_1.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,10 +43,6 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -ec_cell_channel_description_struct = CSN1List(name='ec_cell_channel_description_struct', list=[ - CSN1Bit(name='numberofoctets', bit=5), - CSN1Bit(name='frequency_list_information', bit=([0], lambda x: 8 * (x + 1)))]) - ec_mobile_allocation_struct = CSN1List(name='ec_mobile_allocation_struct', list=[ CSN1Bit(name='ec_ma_number', bit=5), CSN1Alt(alt={ @@ -73,6 +69,10 @@ ec_mobile_allocation_list_struct = CSN1List(name='ec_mobile_allocation_list_stru CSN1Ref(obj=ec_mobile_allocation_struct)]), CSN1Val(name='', val='0')]) +ec_cell_channel_description_struct = CSN1List(name='ec_cell_channel_description_struct', list=[ + CSN1Bit(name='numberofoctets', bit=5), + CSN1Bit(name='frequency_list_information', bit=([0], lambda x: 8 * (x + 1)))]) + ec_system_information_type_1 = CSN1List(name='ec_system_information_type_1', list=[ CSN1Bit(name='message_type', bit=3), CSN1Bit(name='ec_si_1_index', bit=2), diff --git a/pycrate_csn1dir/ec_system_information_type_2.py b/pycrate_csn1dir/ec_system_information_type_2.py index 038dab0..ba6da66 100644 --- a/pycrate_csn1dir/ec_system_information_type_2.py +++ b/pycrate_csn1dir/ec_system_information_type_2.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_system_information_type_2.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,24 +43,22 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -ec_cell_options_struct = CSN1List(name='ec_cell_options_struct', list=[ +ec_rach_control_parameters_struct = CSN1List(name='ec_rach_control_parameters_struct', list=[ + CSN1Bit(name='ec_max_retrans', bit=2), + CSN1Bit(name='sm', bit=2), + CSN1Bit(name='tm', bit=2), + CSN1Bit(name='access_timeslots'), + CSN1Bit(name='cc_access_adaptation', bit=2), + CSN1Bit(name='cell_bar_access'), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='alpha', bit=4)])}), + CSN1Bit(name='ec_access_control_class', bit=7), + CSN1Bit(name='exception_report_status')])}), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='t3168', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='t3192', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='t3226', bit=3)])}), - CSN1Bit(name='t3248', bit=2)]) + CSN1Bit(name='bt_threshold_ul_margin', bit=3)])})]) coverage_class_selection_parameters_struct = CSN1List(name='coverage_class_selection_parameters_struct', list=[ CSN1Bit(name='dl_cc_selection'), @@ -89,6 +87,35 @@ coverage_class_selection_parameters_struct = CSN1List(name='coverage_class_selec CSN1Bit(name='dl_signal_strength_step_size', bit=2)])}), CSN1Bit(name='ec_reduced_pdch_allocation')]) +short_rach_control_parameters_struct = CSN1List(name='short_rach_control_parameters_struct', list=[ + CSN1Bit(name='max_retrans', bit=2), + CSN1Bit(name='tx_integer', bit=4), + CSN1Bit(name='cell_bar_access'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='access_control_class', bit=16), + CSN1Bit(name='exception_report_status')])})]) + +ec_cell_options_struct = CSN1List(name='ec_cell_options_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alpha', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='t3168', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='t3192', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='t3226', bit=3)])}), + CSN1Bit(name='t3248', bit=2)]) + ec_cell_selection_parameters_struct = CSN1List(name='ec_cell_selection_parameters_struct', list=[ CSN1Bit(name='location_area_identification', bit=40), CSN1Bit(name='routing_area_code', bit=8), @@ -105,33 +132,6 @@ ec_cell_selection_parameters_struct = CSN1List(name='ec_cell_selection_parameter '1': ('', [ CSN1Bit(name='cell_selection_rla_margin', bit=3)])})]) -short_rach_control_parameters_struct = CSN1List(name='short_rach_control_parameters_struct', list=[ - CSN1Bit(name='max_retrans', bit=2), - CSN1Bit(name='tx_integer', bit=4), - CSN1Bit(name='cell_bar_access'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='access_control_class', bit=16), - CSN1Bit(name='exception_report_status')])})]) - -ec_rach_control_parameters_struct = CSN1List(name='ec_rach_control_parameters_struct', list=[ - CSN1Bit(name='ec_max_retrans', bit=2), - CSN1Bit(name='sm', bit=2), - CSN1Bit(name='tm', bit=2), - CSN1Bit(name='access_timeslots'), - CSN1Bit(name='cc_access_adaptation', bit=2), - CSN1Bit(name='cell_bar_access'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ec_access_control_class', bit=7), - CSN1Bit(name='exception_report_status')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bt_threshold_ul_margin', bit=3)])})]) - ec_system_information_type_2 = CSN1List(name='ec_system_information_type_2', list=[ CSN1Bit(name='message_type', bit=3), CSN1Bit(name='ec_si_2_index', bit=2), diff --git a/pycrate_csn1dir/ec_system_information_type_3.py b/pycrate_csn1dir/ec_system_information_type_3.py index f8962d7..bfd5a72 100644 --- a/pycrate_csn1dir/ec_system_information_type_3.py +++ b/pycrate_csn1dir/ec_system_information_type_3.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_system_information_type_3.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,19 +43,6 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -ec_cell_reselection_parameters_struct = CSN1List(name='ec_cell_reselection_parameters_struct', list=[ - CSN1Bit(name='cell_reselect_hysteresis', bit=3), - CSN1Bit(name='cell_reselect_offset', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='c1_delta_min', bit=2), - CSN1Bit(name='c1_delta_max', bit=3)])})]) - -ec_neighbour_cell_description_struct = CSN1List(name='ec_neighbour_cell_description_struct', list=[ - CSN1Bit(name='numberofoctets', bit=5), - CSN1Bit(name='neighbour_frequency_list_information', bit=([0], lambda x: 8 * (x + 1)))]) - ec_neighbour_cell_reselection_parameters_struct = CSN1List(name='ec_neighbour_cell_reselection_parameters_struct', list=[ CSN1Bit(name='nb_ncell', bit=5), CSN1List(num=([0], lambda x: x + 1), list=[ @@ -86,6 +73,19 @@ ec_neighbour_cell_reselection_parameters_struct = CSN1List(name='ec_neighbour_ce '1': ('', [ CSN1Bit(name='cell_reselect_offset', bit=6)])})])})])]) +ec_cell_reselection_parameters_struct = CSN1List(name='ec_cell_reselection_parameters_struct', list=[ + CSN1Bit(name='cell_reselect_hysteresis', bit=3), + CSN1Bit(name='cell_reselect_offset', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='c1_delta_min', bit=2), + CSN1Bit(name='c1_delta_max', bit=3)])})]) + +ec_neighbour_cell_description_struct = CSN1List(name='ec_neighbour_cell_description_struct', list=[ + CSN1Bit(name='numberofoctets', bit=5), + CSN1Bit(name='neighbour_frequency_list_information', bit=([0], lambda x: 8 * (x + 1)))]) + ec_system_information_type_3 = CSN1List(name='ec_system_information_type_3', list=[ CSN1Bit(name='message_type', bit=3), CSN1Bit(name='ec_si_3_index', bit=2), diff --git a/pycrate_csn1dir/ec_system_information_type_4.py b/pycrate_csn1dir/ec_system_information_type_4.py index 4c899b9..854477d 100644 --- a/pycrate_csn1dir/ec_system_information_type_4.py +++ b/pycrate_csn1dir/ec_system_information_type_4.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ec_system_information_type_4.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_ack_nack_description_dlmc_ie.py b/pycrate_csn1dir/egprs_ack_nack_description_dlmc_ie.py index da3207d..f5d292a 100644 --- a/pycrate_csn1dir/egprs_ack_nack_description_dlmc_ie.py +++ b/pycrate_csn1dir/egprs_ack_nack_description_dlmc_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_ack_nack_description_dlmc_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_ack_nack_description_ie.py b/pycrate_csn1dir/egprs_ack_nack_description_ie.py index dabbe3c..82b8ea7 100644 --- a/pycrate_csn1dir/egprs_ack_nack_description_ie.py +++ b/pycrate_csn1dir/egprs_ack_nack_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_ack_nack_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_bep_link_quality_measurements_ie.py b/pycrate_csn1dir/egprs_bep_link_quality_measurements_ie.py index 7ce488f..2f067e2 100644 --- a/pycrate_csn1dir/egprs_bep_link_quality_measurements_ie.py +++ b/pycrate_csn1dir/egprs_bep_link_quality_measurements_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_bep_link_quality_measurements_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_bep_link_quality_measurements_type_2_ie.py b/pycrate_csn1dir/egprs_bep_link_quality_measurements_type_2_ie.py index d4d5efb..cf71ef2 100644 --- a/pycrate_csn1dir/egprs_bep_link_quality_measurements_type_2_ie.py +++ b/pycrate_csn1dir/egprs_bep_link_quality_measurements_type_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_bep_link_quality_measurements_type_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_channel_quality_report_ie.py b/pycrate_csn1dir/egprs_channel_quality_report_ie.py index 07ae3fd..cd6716a 100644 --- a/pycrate_csn1dir/egprs_channel_quality_report_ie.py +++ b/pycrate_csn1dir/egprs_channel_quality_report_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_channel_quality_report_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: EGPRS Channel Quality Report IE # external references -from pycrate_csn1dir.egprs_bep_link_quality_measurements_ie import egprs_bep_link_quality_measurements_ie from pycrate_csn1dir.egprs_timeslot_link_quality_measurements_ie import egprs_timeslot_link_quality_measurements_ie +from pycrate_csn1dir.egprs_bep_link_quality_measurements_ie import egprs_bep_link_quality_measurements_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/egprs_channel_quality_report_type_2_ie.py b/pycrate_csn1dir/egprs_channel_quality_report_type_2_ie.py index 5749aab..54aaec1 100644 --- a/pycrate_csn1dir/egprs_channel_quality_report_type_2_ie.py +++ b/pycrate_csn1dir/egprs_channel_quality_report_type_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_channel_quality_report_type_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: EGPRS Channel Quality Report Type 2 IE # external references -from pycrate_csn1dir.egprs_timeslot_link_quality_measurements_type_2_ie import egprs_timeslot_link_quality_measurements_type_2_ie from pycrate_csn1dir.egprs_bep_link_quality_measurements_type_2_ie import egprs_bep_link_quality_measurements_type_2_ie +from pycrate_csn1dir.egprs_timeslot_link_quality_measurements_type_2_ie import egprs_timeslot_link_quality_measurements_type_2_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/egprs_level_ie.py b/pycrate_csn1dir/egprs_level_ie.py index 619afd2..88fe355 100644 --- a/pycrate_csn1dir/egprs_level_ie.py +++ b/pycrate_csn1dir/egprs_level_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_level_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_mode_2_ie.py b/pycrate_csn1dir/egprs_mode_2_ie.py index 5aff6a6..404f47a 100644 --- a/pycrate_csn1dir/egprs_mode_2_ie.py +++ b/pycrate_csn1dir/egprs_mode_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_mode_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,9 +32,9 @@ # external references from pycrate_csn1dir.single_downlink_assignment_2_ie import single_downlink_assignment_2_ie +from pycrate_csn1dir.multiple_downlink_assignment_2_ie import multiple_downlink_assignment_2_ie from pycrate_csn1dir.multiple_uplink_assignment_2_ie import multiple_uplink_assignment_2_ie from pycrate_csn1dir.single_uplink_assignment_2_ie import single_uplink_assignment_2_ie -from pycrate_csn1dir.multiple_downlink_assignment_2_ie import multiple_downlink_assignment_2_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/egprs_modulation_and_coding_scheme_ie.py b/pycrate_csn1dir/egprs_modulation_and_coding_scheme_ie.py index 3fb3b51..3d4ddb2 100644 --- a/pycrate_csn1dir/egprs_modulation_and_coding_scheme_ie.py +++ b/pycrate_csn1dir/egprs_modulation_and_coding_scheme_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_modulation_and_coding_scheme_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_packet_channel_request_message_content.py b/pycrate_csn1dir/egprs_packet_channel_request_message_content.py index 57dc04a..29b645b 100644 --- a/pycrate_csn1dir/egprs_packet_channel_request_message_content.py +++ b/pycrate_csn1dir/egprs_packet_channel_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_packet_channel_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_dlmc_message_content.py b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_dlmc_message_content.py index e3e3d4e..2916936 100644 --- a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_dlmc_message_content.py +++ b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_dlmc_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_packet_downlink_ack_nack_dlmc_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: EGPRS Packet Downlink Ack/Nack DLMC message content # external references -from pycrate_csn1dir.channel_request_description_ie import channel_request_description_ie +from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.egprs_ack_nack_description_dlmc_ie import egprs_ack_nack_description_dlmc_ie from pycrate_csn1dir.dlmc_channel_quality_report_ie import dlmc_channel_quality_report_ie -from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.channel_request_description_ie import channel_request_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_message_content.py b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_message_content.py index bbc8e85..47122e8 100644 --- a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_message_content.py +++ b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_packet_downlink_ack_nack_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,11 +31,11 @@ # top-level object: EGPRS Packet Downlink Ack/Nack message content # external references -from pycrate_csn1dir.egprs_ack_nack_description_ie import egprs_ack_nack_description_ie from pycrate_csn1dir.channel_request_description_ie import channel_request_description_ie +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.egprs_ack_nack_description_ie import egprs_ack_nack_description_ie from pycrate_csn1dir.iu_mode_channel_request_description_ie import extended_channel_request_description_ie from pycrate_csn1dir.egprs_channel_quality_report_ie import egprs_channel_quality_report_ie -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.iu_mode_channel_request_description_ie import iu_mode_channel_request_description_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_2_message_content.py b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_2_message_content.py index 5d0d71a..662f819 100644 --- a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_2_message_content.py +++ b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_2_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_2_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: EGPRS Packet Downlink Ack/Nack Type 2 message content # external references +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.iu_mode_channel_request_description_ie import extended_channel_request_description_ie from pycrate_csn1dir.channel_request_description_ie import channel_request_description_ie from pycrate_csn1dir.egprs_ack_nack_description_ie import egprs_ack_nack_description_ie -from pycrate_csn1dir.iu_mode_channel_request_description_ie import extended_channel_request_description_ie -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.egprs_channel_quality_report_type_2_ie import egprs_channel_quality_report_type_2_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_3_message_content.py b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_3_message_content.py index 854757e..6057715 100644 --- a/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_3_message_content.py +++ b/pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_3_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_packet_downlink_ack_nack_type_3_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: EGPRS Packet Downlink Ack/Nack Type 3 message content # external references -from pycrate_csn1dir.egprs_ack_nack_description_ie import egprs_ack_nack_description_ie -from pycrate_csn1dir.extension_bits_ie import extension_bits_ie -from pycrate_csn1dir.egprs_channel_quality_report_type_2_ie import egprs_channel_quality_report_type_2_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.extension_bits_ie import extension_bits_ie +from pycrate_csn1dir.egprs_ack_nack_description_ie import egprs_ack_nack_description_ie +from pycrate_csn1dir.egprs_channel_quality_report_type_2_ie import egprs_channel_quality_report_type_2_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_ie.py b/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_ie.py index 3dc9498..bf728e3 100644 --- a/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_ie.py +++ b/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_timeslot_link_quality_measurements_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_type_2_ie.py b/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_type_2_ie.py index 8ec6a7a..05d66b8 100644 --- a/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_type_2_ie.py +++ b/pycrate_csn1dir/egprs_timeslot_link_quality_measurements_type_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_timeslot_link_quality_measurements_type_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -39,6 +39,40 @@ from pycrate_csn1.csnobj import * +interference_measurement_report_struct = CSN1List(name='interference_measurement_report_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn0', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn1', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn2', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn3', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn4', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn5', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn6', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='i_level_tn7', bit=4)])})]) + bep_measurement_report_struct = CSN1List(name='bep_measurement_report_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -81,40 +115,6 @@ bep_measurement_report_struct = CSN1List(name='bep_measurement_report_struct', l CSN1Bit(name='reported_modulation', bit=2), CSN1Bit(name='mean_bep_tn7', bit=4)])})]) -interference_measurement_report_struct = CSN1List(name='interference_measurement_report_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn0', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn1', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn2', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn3', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn4', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn5', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn6', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='i_level_tn7', bit=4)])})]) - egprs_timeslot_link_quality_measurements_type_2_ie = CSN1List(name='egprs_timeslot_link_quality_measurements_type_2_ie', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/egprs_window_size_ie.py b/pycrate_csn1dir/egprs_window_size_ie.py index 3f43fbc..3493766 100644 --- a/pycrate_csn1dir/egprs_window_size_ie.py +++ b/pycrate_csn1dir/egprs_window_size_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/egprs_window_size_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/enhanced_cell_reselection_parameters_ie.py b/pycrate_csn1dir/enhanced_cell_reselection_parameters_ie.py index 3b8a043..1eef24a 100644 --- a/pycrate_csn1dir/enhanced_cell_reselection_parameters_ie.py +++ b/pycrate_csn1dir/enhanced_cell_reselection_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/enhanced_cell_reselection_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/enhanced_measurement_report.py b/pycrate_csn1dir/enhanced_measurement_report.py index 914c094..14f7c41 100644 --- a/pycrate_csn1dir/enhanced_measurement_report.py +++ b/pycrate_csn1dir/enhanced_measurement_report.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/enhanced_measurement_report.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -44,6 +44,13 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding +eutran_measurement_report_struct = CSN1List(name='eutran_measurement_report_struct', list=[ + CSN1Bit(name='n_eutran', bit=2), + CSN1List(num=([0], lambda x: x + 1), list=[ + CSN1Bit(name='eutran_frequency_index', bit=3), + CSN1Bit(name='cell_identity', bit=9), + CSN1Bit(name='reporting_quantity', bit=6)])]) + repeated_invalid_bsic_information_struct = CSN1List(name='repeated_invalid_bsic_information_struct', list=[ CSN1Bit(name='bcch_freq_ncell', bit=5), CSN1Bit(name='bsic', bit=6), @@ -57,13 +64,6 @@ serving_cell_data_struct = CSN1List(name='serving_cell_data_struct', list=[ CSN1Bit(name='cv_bep', bit=3), CSN1Bit(name='nbr_rcvd_blocks', bit=5)]) -eutran_measurement_report_struct = CSN1List(name='eutran_measurement_report_struct', list=[ - CSN1Bit(name='n_eutran', bit=2), - CSN1List(num=([0], lambda x: x + 1), list=[ - CSN1Bit(name='eutran_frequency_index', bit=3), - CSN1Bit(name='cell_identity', bit=9), - CSN1Bit(name='reporting_quantity', bit=6)])]) - enhanced_measurement_report = CSN1List(name='enhanced_measurement_report', list=[ CSN1Bit(name='rr_short_pd'), CSN1Bit(name='message_type', bit=5), diff --git a/pycrate_csn1dir/extension_bits_ie.py b/pycrate_csn1dir/extension_bits_ie.py index f4ac338..fab053c 100644 --- a/pycrate_csn1dir/extension_bits_ie.py +++ b/pycrate_csn1dir/extension_bits_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/extension_bits_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/flo_ack_nack_description_ie.py b/pycrate_csn1dir/flo_ack_nack_description_ie.py index fa910f7..461219b 100644 --- a/pycrate_csn1dir/flo_ack_nack_description_ie.py +++ b/pycrate_csn1dir/flo_ack_nack_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/flo_ack_nack_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/frequency_parameters_ie.py b/pycrate_csn1dir/frequency_parameters_ie.py index 94a8dc9..360f252 100644 --- a/pycrate_csn1dir/frequency_parameters_ie.py +++ b/pycrate_csn1dir/frequency_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/frequency_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/g_rnti_ie.py b/pycrate_csn1dir/g_rnti_ie.py index 1e3020b..0dc7489 100644 --- a/pycrate_csn1dir/g_rnti_ie.py +++ b/pycrate_csn1dir/g_rnti_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/g_rnti_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/generator/to_be_completed.txt b/pycrate_csn1dir/generator/to_be_completed.txt index f03019a..e2d100f 100644 --- a/pycrate_csn1dir/generator/to_be_completed.txt +++ b/pycrate_csn1dir/generator/to_be_completed.txt @@ -1,18 +1,32 @@ -> 44060/multiple_tbf_timeslot_reconfigure_message_content.csn -WARN: unable to process arithmetic expression, (N) - do it by hand within the Python file generated -WARN: unable to process arithmetic expression, (M-1) - do it by hand within the Python file generated -WARN: unable to process arithmetic expression, (N) - do it by hand within the Python file generated -WARN: unable to process arithmetic expression, (M-1) - do it by hand within the Python file generated +### Warnings -> 44060/packet_cs_release_message_content.csn -WARN: unable to process arithmetic expression, (N) +> 44018/si2quater_rest_octets.csn +WARN: unable to process arithmetic expression, (p(NR_OF_FDD_CELLS)) do it by hand within the Python file generated -WARN: unable to process arithmetic expression, (M-1) +WARN: unable to process arithmetic expression, (q(NR_OF_TDD_CELLS)) do it by hand within the Python file generated +# handled below + +> 44018/cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.csn +WARN: unable to process arithmetic expression, (p(NR_OF_FDD_CELLS)) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (q(NR_OF_TDD_CELLS)) + do it by hand within the Python file generated +# handled below + +> 44018/measurement_information.csn +WARN: unable to process arithmetic expression, (p(NR_OF_FDD_CELLS)) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (q(NR_OF_TDD_CELLS)) + do it by hand within the Python file generated +# handled below + +> 44060/psi3_bis_message_content.csn +WARN: unable to process arithmetic expression, (1+max(val(CELL_PARAMS_POINTER))) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (1+max(val(CELL_PARAMS_POINTER))) + do it by hand within the Python file generated +# handled below > 44060/multiple_uplink_assignment_2_ie.csn WARN: unable to resolve reference, N_PAIRS @@ -21,6 +35,7 @@ WARN: unable to resolve reference, N_PAIRS do it by hand within the Python file generated WARN: unable to resolve reference, N_PAIRS do it by hand within the Python file generated +# unhandled > 44060/multiple_tbf_uplink_assignment_message_content.csn WARN: unable to process arithmetic expression, (N) @@ -31,26 +46,69 @@ WARN: unable to process arithmetic expression, (N) do it by hand within the Python file generated WARN: unable to process arithmetic expression, (M-1) do it by hand within the Python file generated +# unhandled -> 44060/ps_handover_radio_resources_ie.csn +> 44060/packet_measurement_order_message_content.csn +WARN: unable to process arithmetic expression, (p(NR_OF_FDD_CELLS)) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (q(NR_OF_TDD_CELLS)) + do it by hand within the Python file generated +# handled below + +> 44060/packet_cs_release_message_content.csn WARN: unable to process arithmetic expression, (N) do it by hand within the Python file generated WARN: unable to process arithmetic expression, (M-1) do it by hand within the Python file generated +# unhandled + +> 44060/packet_cell_change_order_message_content.csn +WARN: unable to process arithmetic expression, (p(NR_OF_FDD_CELLS)) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (q(NR_OF_TDD_CELLS)) + do it by hand within the Python file generated +# handled below + +> 44060/psi3_quater_message_content.csn +WARN: unable to process arithmetic expression, (p(NR_OF_FDD_CELLS)) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (q(NR_OF_TDD_CELLS)) + do it by hand within the Python file generated +# handled below + +> 44060/multiple_tbf_timeslot_reconfigure_message_content.csn +WARN: unable to process arithmetic expression, (N) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (M-1) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (N) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (M-1) + do it by hand within the Python file generated +# unhandled > 44060/dtm_handover_ps_radio_resources_ie.csn WARN: unable to process arithmetic expression, (N) do it by hand within the Python file generated WARN: unable to process arithmetic expression, (M-1) do it by hand within the Python file generated +# unhandled + +> 44060/ps_handover_radio_resources_ie.csn +WARN: unable to process arithmetic expression, (N) + do it by hand within the Python file generated +WARN: unable to process arithmetic expression, (M-1) + do it by hand within the Python file generated +# unhandled -# manual patching required -# 24.008 -# ms_ra_capability_value_part.py +### Manual patching required -# manual edit +## 24.008 +## ms_ra_capability_value_part.py + +# create a dict: _AccessTechnoType_dict = { 0 : 'GSM P', 1 : 'GSM E --note that GSM E covers GSM P', @@ -67,14 +125,18 @@ _AccessTechnoType_dict = { 12 : 'GSM 710', 13 : 'GSM T 810', } +# ref it with a kdic=_AccessTechnoType_dict +# within the object ms_ra_capability_value_part_struct -# 44.018 -# cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.py -# measurement_information.py -# si2quater_rest_octets.py +## 44.018 +## cell_selection_indicator_after_release_of_all_tch_and_sdcch_value_part.py +## measurement_information.py +## si2quater_rest_octets.py + +# add the following function definitions +# and patch all objects having such crappy references: ('# unprocessed: ...', lambda: 0) -# manual edit # table 9.1.54.1a _TransP = { 0 : 0, @@ -133,11 +195,21 @@ def trans_q(n): except: return 0 -# 44.060 -# psi3_bis_message_content.py + +## 44.060 +## psi3_bis_message_content.py + +# add the following function definitions +# and patch all objects having such crappy references: ('# unprocessed: ...', lambda: 0) def max_cell_params(cpp): - # cpp is a list of list of (1, ref, val) + # cpp is a list of list of fmt [1, ref, 2-bit-val] + # + # CSN1List(num=-1, list=[ + # CSN1Val(name='', val='1'), + # CSN1Ref(obj=ncp2_repeat_struct), + # CSN1Bit(name='cell_params_pointer', bit=2)]) + # if cpp: try: if isinstance(cpp[0][2], integer_types): @@ -148,67 +220,14 @@ def max_cell_params(cpp): pass return 0 -# 44.060 -# packet_cell_change_order_message_content.py -# packet_measurement_order_message_content.py -# psi3_quater_message_content.py -# manual edit -# table 11.2.9b.2.a -_TransP = { - 0 : 0, - 1 : 10, - 2 : 19, - 3 : 28, - 4 : 36, - 5 : 44, - 6 : 52, - 7 : 60, - 8 : 67, - 9 : 74, - 10: 81, - 11: 88, - 12: 95, - 13: 102, - 14: 109, - 15: 116, - 16: 122 - } +## 44.060 +## packet_cell_change_order_message_content.py +## packet_measurement_order_message_content.py +## psi3_quater_message_content.py -def trans_p(n): - try: - return _TransP[n] - except: - return 0 +# add the following function definitions +# and patch all objects having such crappy references: ('# unprocessed: ...', lambda: 0) -# table 11.2.9b.2.b -_TransQ = { - 0 : 0, - 1 : 9, - 2 : 17, - 3 : 25, - 4 : 32, - 5 : 39, - 6 : 46, - 7 : 53, - 8 : 59, - 9 : 65, - 10: 71, - 11: 77, - 12: 83, - 13: 89, - 14: 95, - 15: 101, - 16: 106, - 17: 111, - 18: 116, - 19: 121, - 20: 126 - } -def trans_q(n): - try: - return _TransQ[n] - except: - return 0 diff --git a/pycrate_csn1dir/global_packet_timing_advance_ie.py b/pycrate_csn1dir/global_packet_timing_advance_ie.py index 2942837..b0b1eb7 100644 --- a/pycrate_csn1dir/global_packet_timing_advance_ie.py +++ b/pycrate_csn1dir/global_packet_timing_advance_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/global_packet_timing_advance_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/global_power_control_parameters_ie.py b/pycrate_csn1dir/global_power_control_parameters_ie.py index 4e7fdaf..88e7c59 100644 --- a/pycrate_csn1dir/global_power_control_parameters_ie.py +++ b/pycrate_csn1dir/global_power_control_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/global_power_control_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/global_tfi_ie.py b/pycrate_csn1dir/global_tfi_ie.py index 11faa13..7a4714a 100644 --- a/pycrate_csn1dir/global_tfi_ie.py +++ b/pycrate_csn1dir/global_tfi_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/global_tfi_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/gprs_broadcast_information_value_part.py b/pycrate_csn1dir/gprs_broadcast_information_value_part.py index 6770b06..44ba513 100644 --- a/pycrate_csn1dir/gprs_broadcast_information_value_part.py +++ b/pycrate_csn1dir/gprs_broadcast_information_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/gprs_broadcast_information_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: GPRS broadcast information value part # external references -from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_parameters_ie +from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/gprs_cell_options_ie.py b/pycrate_csn1dir/gprs_cell_options_ie.py index ff85697..bee402d 100644 --- a/pycrate_csn1dir/gprs_cell_options_ie.py +++ b/pycrate_csn1dir/gprs_cell_options_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/gprs_cell_options_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/gprs_mobile_allocation_ie.py b/pycrate_csn1dir/gprs_mobile_allocation_ie.py index 4191fd5..f6986d7 100644 --- a/pycrate_csn1dir/gprs_mobile_allocation_ie.py +++ b/pycrate_csn1dir/gprs_mobile_allocation_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/gprs_mobile_allocation_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/gprs_power_control_parameters_ie.py b/pycrate_csn1dir/gprs_power_control_parameters_ie.py index 8ff23fd..4cb578a 100644 --- a/pycrate_csn1dir/gprs_power_control_parameters_ie.py +++ b/pycrate_csn1dir/gprs_power_control_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/gprs_power_control_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/gsm_priority_parameters_ie.py b/pycrate_csn1dir/gsm_priority_parameters_ie.py index 6e29a4c..5563708 100644 --- a/pycrate_csn1dir/gsm_priority_parameters_ie.py +++ b/pycrate_csn1dir/gsm_priority_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/gsm_priority_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/handover_access_8_bit_message.py b/pycrate_csn1dir/handover_access_8_bit_message.py index 21c3bdf..bc8e5e4 100644 --- a/pycrate_csn1dir/handover_access_8_bit_message.py +++ b/pycrate_csn1dir/handover_access_8_bit_message.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/handover_access_8_bit_message.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ia_rest_octets.py b/pycrate_csn1dir/ia_rest_octets.py index f805df2..13e72be 100644 --- a/pycrate_csn1dir/ia_rest_octets.py +++ b/pycrate_csn1dir/ia_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ia_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,10 +32,10 @@ # external references from pycrate_csn1dir.tmgi_ie import tmgi_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie from pycrate_csn1dir.egprs_level_ie import egprs_level_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -48,15 +48,6 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -second_part_packet_assignment = CSN1Alt(name='second_part_packet_assignment', alt={ - 'H': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='extended_ra', bit=5)])})]), - 'L': ('', []), - None: ('', [])}) - access_technologies_request_struct = CSN1List(name='access_technologies_request_struct', list=[ CSN1Bit(name='access_technology_type', bit=4), CSN1Alt(alt={ @@ -64,166 +55,6 @@ access_technologies_request_struct = CSN1List(name='access_technologies_request_ '1': ('', [ CSN1SelfRef()])})]) -frequency_parameters_before_time = CSN1Alt(name='frequency_parameters_before_time', alt={ - '00': ('', [ - CSN1Bit(name='maio', bit=6), - CSN1Bit(name='mobile_allocation', bit=-1)]), - None: ('', [])}) - -packet_uplink_assignment = CSN1List(name='packet_uplink_assignment', list=[ - CSN1Alt(alt={ - '0': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='alpha', bit=4)])}), - CSN1Bit(name='gamma', bit=5), - CSN1Val(name='', val='01'), - CSN1Bit(name='tbf_starting_time', bit=16), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Bit(name='p0', bit=4), - CSN1Val(name='', val='0'), - CSN1Bit(name='pr_mode')]), - 'L': ('', [])})]), - '1': ('', [ - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Bit(name='polling'), - CSN1Val(name='', val='0'), - CSN1Bit(name='usf', bit=3), - CSN1Bit(name='usf_granularity'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='p0', bit=4), - CSN1Bit(name='pr_mode')])}), - CSN1Bit(name='channel_coding_command', bit=2), - CSN1Bit(name='tlli_block_channel_coding'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='alpha', bit=4)])}), - CSN1Bit(name='gamma', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='timing_advance_index', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tbf_starting_time', bit=16)])})])}), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='extended_ra', bit=5)])})]), - 'L': ('', []), - None: ('', [])}), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='pfi', bit=7)])})]), - 'L': ('', []), - None: ('', [])})]) - -packet_downlink_assignment = CSN1List(name='packet_downlink_assignment', list=[ - CSN1Bit(name='tlli', bit=32), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Bit(name='rlc_mode'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='alpha', bit=4)])}), - CSN1Bit(name='gamma', bit=5), - CSN1Bit(name='polling'), - CSN1Bit(name='ta_valid')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='timing_advance_index', bit=4)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tbf_starting_time', bit=16)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='p0', bit=4), - CSN1Val(name='', val='0'), - CSN1Bit(name='pr_mode')])}), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie), - CSN1Bit(name='link_quality_measurement_mode', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bep_period2', bit=4)])})]), - 'L': ('', []), - None: ('', [])}), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='pfi', bit=7)])})]), - 'L': ('', []), - None: ('', [])}), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='event_based_fanr')])})]), - '1': ('', [ - CSN1Bit(name='event_based_fanr'), - CSN1Bit(name='pdch_pair_indication', bit=3)])}), - CSN1Ref(name='downlink_egprs_level', obj=egprs_level_ie)]), - 'L': ('', []), - None: ('', [])})]) - -multiple_blocks_packet_downlink_assignment = CSN1List(name='multiple_blocks_packet_downlink_assignment', list=[ - CSN1Bit(name='tbf_starting_time', bit=16), - CSN1Bit(name='number_of_allocated_blocks', bit=4), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Alt(alt={ - '0': ('', [ - CSN1Ref(name='tmgi', obj=tmgi_ie), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='mbms_session_identity', bit=8)])})]), - '1': ('', [ - CSN1Bit(name='tlli_g_rnti', bit=32), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='length_indicator_of_ms_id', bit=2), - CSN1Bit(name='ms_id', bit=([1], lambda x: x + 1)), - CSN1Ref(name='packet_timing_advance', obj=packet_timing_advance_ie), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='alpha', bit=4), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma', bit=5)])})])})])})])})])})]) - egprs_packet_uplink_assignment = CSN1List(name='egprs_packet_uplink_assignment', list=[ CSN1Bit(name='extended_ra', bit=5), CSN1Alt(alt={ @@ -314,6 +145,175 @@ egprs_packet_uplink_assignment = CSN1List(name='egprs_packet_uplink_assignment', 'L': ('', []), None: ('', [])})])})]) +packet_uplink_assignment = CSN1List(name='packet_uplink_assignment', list=[ + CSN1Alt(alt={ + '0': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alpha', bit=4)])}), + CSN1Bit(name='gamma', bit=5), + CSN1Val(name='', val='01'), + CSN1Bit(name='tbf_starting_time', bit=16), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Bit(name='p0', bit=4), + CSN1Val(name='', val='0'), + CSN1Bit(name='pr_mode')]), + 'L': ('', [])})]), + '1': ('', [ + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Bit(name='polling'), + CSN1Val(name='', val='0'), + CSN1Bit(name='usf', bit=3), + CSN1Bit(name='usf_granularity'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='p0', bit=4), + CSN1Bit(name='pr_mode')])}), + CSN1Bit(name='channel_coding_command', bit=2), + CSN1Bit(name='tlli_block_channel_coding'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alpha', bit=4)])}), + CSN1Bit(name='gamma', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='timing_advance_index', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tbf_starting_time', bit=16)])})])}), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='extended_ra', bit=5)])})]), + 'L': ('', []), + None: ('', [])}), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='pfi', bit=7)])})]), + 'L': ('', []), + None: ('', [])})]) + +frequency_parameters_before_time = CSN1Alt(name='frequency_parameters_before_time', alt={ + '00': ('', [ + CSN1Bit(name='maio', bit=6), + CSN1Bit(name='mobile_allocation', bit=-1)]), + None: ('', [])}) + +second_part_packet_assignment = CSN1Alt(name='second_part_packet_assignment', alt={ + 'H': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='extended_ra', bit=5)])})]), + 'L': ('', []), + None: ('', [])}) + +multiple_blocks_packet_downlink_assignment = CSN1List(name='multiple_blocks_packet_downlink_assignment', list=[ + CSN1Bit(name='tbf_starting_time', bit=16), + CSN1Bit(name='number_of_allocated_blocks', bit=4), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Alt(alt={ + '0': ('', [ + CSN1Ref(name='tmgi', obj=tmgi_ie), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='mbms_session_identity', bit=8)])})]), + '1': ('', [ + CSN1Bit(name='tlli_g_rnti', bit=32), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='length_indicator_of_ms_id', bit=2), + CSN1Bit(name='ms_id', bit=([1], lambda x: x + 1)), + CSN1Ref(name='packet_timing_advance', obj=packet_timing_advance_ie), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alpha', bit=4), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma', bit=5)])})])})])})])})])})]) + +packet_downlink_assignment = CSN1List(name='packet_downlink_assignment', list=[ + CSN1Bit(name='tlli', bit=32), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Bit(name='rlc_mode'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alpha', bit=4)])}), + CSN1Bit(name='gamma', bit=5), + CSN1Bit(name='polling'), + CSN1Bit(name='ta_valid')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='timing_advance_index', bit=4)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tbf_starting_time', bit=16)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='p0', bit=4), + CSN1Val(name='', val='0'), + CSN1Bit(name='pr_mode')])}), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie), + CSN1Bit(name='link_quality_measurement_mode', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bep_period2', bit=4)])})]), + 'L': ('', []), + None: ('', [])}), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='pfi', bit=7)])})]), + 'L': ('', []), + None: ('', [])}), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='event_based_fanr')])})]), + '1': ('', [ + CSN1Bit(name='event_based_fanr'), + CSN1Bit(name='pdch_pair_indication', bit=3)])}), + CSN1Ref(name='downlink_egprs_level', obj=egprs_level_ie)]), + 'L': ('', []), + None: ('', [])})]) + ia_rest_octets = CSN1List(name='ia_rest_octets', list=[ CSN1Alt(alt={ 'HH': ('', [ diff --git a/pycrate_csn1dir/iar_rest_octets.py b/pycrate_csn1dir/iar_rest_octets.py index 57ba230..299b3a9 100644 --- a/pycrate_csn1dir/iar_rest_octets.py +++ b/pycrate_csn1dir/iar_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/iar_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/iax_rest_octets.py b/pycrate_csn1dir/iax_rest_octets.py index 0a588ea..e3150d1 100644 --- a/pycrate_csn1dir/iax_rest_octets.py +++ b/pycrate_csn1dir/iax_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/iax_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/individual_priorities.py b/pycrate_csn1dir/individual_priorities.py index 9a0db46..332fc6a 100644 --- a/pycrate_csn1dir/individual_priorities.py +++ b/pycrate_csn1dir/individual_priorities.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/individual_priorities.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -46,6 +46,13 @@ repeated_individual_e_utran_priority_parameters_description_struct = CSN1List(na CSN1Val(name='', val='0'), CSN1Bit(name='e_utran_priority', bit=3)]) +repeated_individual_e_utran_pp_with_extended_earfcns_description_struct = CSN1List(name='repeated_individual_e_utran_pp_with_extended_earfcns_description_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='earfcn_extended', bit=18)]), + CSN1Val(name='', val='0'), + CSN1Bit(name='e_utran_priority', bit=3)]) + repeated_individual_utran_priority_parameters_struct = CSN1List(name='repeated_individual_utran_priority_parameters_struct', list=[ CSN1Alt(alt={ '0': ('', [ @@ -60,12 +67,15 @@ repeated_individual_utran_priority_parameters_struct = CSN1List(name='repeated_i CSN1Val(name='', val='0')])}), CSN1Bit(name='utran_priority', bit=3)]) -repeated_individual_e_utran_pp_with_extended_earfcns_description_struct = CSN1List(name='repeated_individual_e_utran_pp_with_extended_earfcns_description_struct', list=[ +e_utran_individual_priority_parameters_description_struct = CSN1List(name='e_utran_individual_priority_parameters_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='default_e_utran_priority', bit=3)])}), CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Bit(name='earfcn_extended', bit=18)]), - CSN1Val(name='', val='0'), - CSN1Bit(name='e_utran_priority', bit=3)]) + CSN1Ref(name='repeated_individual_e_utran_priority_parameters', obj=repeated_individual_e_utran_priority_parameters_description_struct)]), + CSN1Val(name='', val='0')]) e_utran_ipp_with_extended_earfcns_description_struct = CSN1List(name='e_utran_ipp_with_extended_earfcns_description_struct', list=[ CSN1Alt(alt={ @@ -77,16 +87,6 @@ e_utran_ipp_with_extended_earfcns_description_struct = CSN1List(name='e_utran_ip CSN1Ref(name='repeated_individual_e_utran_pp_with_extended_earfcns', obj=repeated_individual_e_utran_pp_with_extended_earfcns_description_struct)]), CSN1Val(name='', val='0')]) -e_utran_individual_priority_parameters_description_struct = CSN1List(name='e_utran_individual_priority_parameters_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='default_e_utran_priority', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_individual_e_utran_priority_parameters', obj=repeated_individual_e_utran_priority_parameters_description_struct)]), - CSN1Val(name='', val='0')]) - _3g_individual_priority_parameters_description_struct = CSN1List(name='_3g_individual_priority_parameters_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/individual_priorities_ie.py b/pycrate_csn1dir/individual_priorities_ie.py index bf2c4a6..d7c4ebe 100644 --- a/pycrate_csn1dir/individual_priorities_ie.py +++ b/pycrate_csn1dir/individual_priorities_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/individual_priorities_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -39,13 +39,6 @@ from pycrate_csn1.csnobj import * -repeated_individual_e_utran_priority_parameters_struct = CSN1List(name='repeated_individual_e_utran_priority_parameters_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='earfcn', bit=16)]), - CSN1Val(name='', val='0'), - CSN1Bit(name='e_utran_priority', bit=3)]) - repeated_individual_utran_priority_parameters_struct = CSN1List(name='repeated_individual_utran_priority_parameters_struct', list=[ CSN1Alt(alt={ '0': ('', [ @@ -60,16 +53,6 @@ repeated_individual_utran_priority_parameters_struct = CSN1List(name='repeated_i CSN1Val(name='', val='0')])}), CSN1Bit(name='utran_priority', bit=3)]) -e_utran_individual_priority_parameters_description_struct = CSN1List(name='e_utran_individual_priority_parameters_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='default_e_utran_priority', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_individual_e_utran_priority_parameters', obj=repeated_individual_e_utran_priority_parameters_struct)]), - CSN1Val(name='', val='0')]) - _3g_individual_priority_parameters_description_struct = CSN1List(name='_3g_individual_priority_parameters_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -80,6 +63,23 @@ _3g_individual_priority_parameters_description_struct = CSN1List(name='_3g_indiv CSN1Ref(name='repeated_individual_utran_priority_parameters', obj=repeated_individual_utran_priority_parameters_struct)]), CSN1Val(name='', val='0')]) +repeated_individual_e_utran_priority_parameters_struct = CSN1List(name='repeated_individual_e_utran_priority_parameters_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='earfcn', bit=16)]), + CSN1Val(name='', val='0'), + CSN1Bit(name='e_utran_priority', bit=3)]) + +e_utran_individual_priority_parameters_description_struct = CSN1List(name='e_utran_individual_priority_parameters_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='default_e_utran_priority', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_individual_e_utran_priority_parameters', obj=repeated_individual_e_utran_priority_parameters_struct)]), + CSN1Val(name='', val='0')]) + individual_priorities_ie = CSN1Alt(name='individual_priorities_ie', alt={ '0': ('', []), '1': ('', [ diff --git a/pycrate_csn1dir/ipa_rest_octets.py b/pycrate_csn1dir/ipa_rest_octets.py index 4b28125..8a1fa35 100644 --- a/pycrate_csn1dir/ipa_rest_octets.py +++ b/pycrate_csn1dir/ipa_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ipa_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,6 +43,18 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding +ipa_downlink_assignment_struct = CSN1List(name='ipa_downlink_assignment_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='tlli', bit=32), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Bit(name='gamma', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='timing_advance_value', bit=6)])})]), + CSN1Val(name='', val='0')]) + ipa_uplink_assignment_struct = CSN1List(name='ipa_uplink_assignment_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -66,18 +78,6 @@ ipa_single_block_uplink_assignment_struct = CSN1List(name='ipa_single_block_upli CSN1Bit(name='starting_time_offset', bit=6)]), CSN1Val(name='', val='0')]) -ipa_downlink_assignment_struct = CSN1List(name='ipa_downlink_assignment_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='tlli', bit=32), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Bit(name='gamma', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='timing_advance_value', bit=6)])})]), - CSN1Val(name='', val='0')]) - ipa_rest_octets = CSN1List(name='ipa_rest_octets', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/iu_mode_channel_request_description_ie.py b/pycrate_csn1dir/iu_mode_channel_request_description_ie.py index 5983b41..babf33b 100644 --- a/pycrate_csn1dir/iu_mode_channel_request_description_ie.py +++ b/pycrate_csn1dir/iu_mode_channel_request_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/iu_mode_channel_request_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/lsa_parameters_ie.py b/pycrate_csn1dir/lsa_parameters_ie.py index 6489b73..4c42122 100644 --- a/pycrate_csn1dir/lsa_parameters_ie.py +++ b/pycrate_csn1dir/lsa_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/lsa_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mbms_assignment_distribution_message_content.py b/pycrate_csn1dir/mbms_assignment_distribution_message_content.py index c8a2746..d6ee830 100644 --- a/pycrate_csn1dir/mbms_assignment_distribution_message_content.py +++ b/pycrate_csn1dir/mbms_assignment_distribution_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_assignment_distribution_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,11 +31,11 @@ # top-level object: MBMS Assignment Distribution message content # external references -from pycrate_csn1dir.tmgi_ie import tmgi_ie -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.mbms_in_band_signalling_indicator_ie import mbms_in_band_signalling_indicator_ie from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.tmgi_ie import tmgi_ie +from pycrate_csn1dir.mbms_in_band_signalling_indicator_ie import mbms_in_band_signalling_indicator_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/mbms_assignment_non_distribution_message_content.py b/pycrate_csn1dir/mbms_assignment_non_distribution_message_content.py index 739abe9..f2566b8 100644 --- a/pycrate_csn1dir/mbms_assignment_non_distribution_message_content.py +++ b/pycrate_csn1dir/mbms_assignment_non_distribution_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_assignment_non_distribution_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,12 +31,12 @@ # top-level object: MBMS Assignment Non-distribution message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie from pycrate_csn1dir.tmgi_ie import tmgi_ie from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.mbms_in_band_signalling_indicator_ie import mbms_in_band_signalling_indicator_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/mbms_channel_parameters_ie.py b/pycrate_csn1dir/mbms_channel_parameters_ie.py index 69b2002..b108c2e 100644 --- a/pycrate_csn1dir/mbms_channel_parameters_ie.py +++ b/pycrate_csn1dir/mbms_channel_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_channel_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: MBMS Channel Parameters IE # external references +from pycrate_csn1dir.mbms_session_parameters_list_ie import mbms_session_parameters_list_ie from pycrate_csn1dir.mprach_description_ie import mprach_description_ie from pycrate_csn1dir.mbms_p_t_m_channel_description_ie import mbms_p_t_m_channel_description_ie -from pycrate_csn1dir.mbms_session_parameters_list_ie import mbms_session_parameters_list_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/mbms_downlink_ack_nack_message_content.py b/pycrate_csn1dir/mbms_downlink_ack_nack_message_content.py index e1f3042..4431a11 100644 --- a/pycrate_csn1dir/mbms_downlink_ack_nack_message_content.py +++ b/pycrate_csn1dir/mbms_downlink_ack_nack_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_downlink_ack_nack_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: MBMS Downlink Ack/Nack message content # external references +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.extension_bits_ie import extension_bits_ie from pycrate_csn1dir.egprs_ack_nack_description_ie import egprs_ack_nack_description_ie from pycrate_csn1dir.ack_nack_description_ie import ack_nack_description_ie -from pycrate_csn1dir.extension_bits_ie import extension_bits_ie -from pycrate_csn1dir.padding_bits import padding_bits # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/mbms_in_band_signalling_indicator_ie.py b/pycrate_csn1dir/mbms_in_band_signalling_indicator_ie.py index 9aa5b27..aaf2f38 100644 --- a/pycrate_csn1dir/mbms_in_band_signalling_indicator_ie.py +++ b/pycrate_csn1dir/mbms_in_band_signalling_indicator_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_in_band_signalling_indicator_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mbms_ms_id_assignment_message_content.py b/pycrate_csn1dir/mbms_ms_id_assignment_message_content.py index 12a6fd9..9d907b2 100644 --- a/pycrate_csn1dir/mbms_ms_id_assignment_message_content.py +++ b/pycrate_csn1dir/mbms_ms_id_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_ms_id_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: MBMS MS_ID Assignment message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/mbms_neighbouring_cell_information_message_content.py b/pycrate_csn1dir/mbms_neighbouring_cell_information_message_content.py index 6f5127d..9a246a4 100644 --- a/pycrate_csn1dir/mbms_neighbouring_cell_information_message_content.py +++ b/pycrate_csn1dir/mbms_neighbouring_cell_information_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_neighbouring_cell_information_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: MBMS Neighbouring Cell Information message content # external references -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.mbms_in_band_signalling_indicator_ie import mbms_in_band_signalling_indicator_ie -from pycrate_csn1dir.mprach_control_parameters_ie import mprach_control_parameters_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.mprach_control_parameters_ie import mprach_control_parameters_ie +from pycrate_csn1dir.mbms_in_band_signalling_indicator_ie import mbms_in_band_signalling_indicator_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -43,16 +43,6 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -mbms_p_t_m_frequency_parameters_struct = CSN1List(name='mbms_p_t_m_frequency_parameters_struct', list=[ - CSN1Bit(name='tsc', bit=3), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='arfcn', bit=10)]), - '1': ('', [ - CSN1Bit(name='maio', bit=6), - CSN1Bit(name='hsn', bit=6), - CSN1Bit(name='freq_list_number', bit=2)])})]) - mbms_frequency_list_struct = CSN1List(name='mbms_frequency_list_struct', list=[ CSN1Bit(name='freq_list_number', bit=2), CSN1Bit(name='length_of_frequency_list_contents', bit=4), @@ -70,6 +60,16 @@ pbcch_information_struct = CSN1List(name='pbcch_information_struct', list=[ CSN1Bit(name='length_of_neighbour_mbms_bearer_identity', bit=3), CSN1Bit(name='neighbour_mbms_bearer_identity', bit=([1], lambda x: x))])})]) +mbms_p_t_m_frequency_parameters_struct = CSN1List(name='mbms_p_t_m_frequency_parameters_struct', list=[ + CSN1Bit(name='tsc', bit=3), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='arfcn', bit=10)]), + '1': ('', [ + CSN1Bit(name='maio', bit=6), + CSN1Bit(name='hsn', bit=6), + CSN1Bit(name='freq_list_number', bit=2)])})]) + mbms_neighbouring_cell_information_message_content = CSN1List(name='mbms_neighbouring_cell_information_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1List(num=-1, list=[ diff --git a/pycrate_csn1dir/mbms_p_t_m_channel_description_ie.py b/pycrate_csn1dir/mbms_p_t_m_channel_description_ie.py index 001caea..c1f270c 100644 --- a/pycrate_csn1dir/mbms_p_t_m_channel_description_ie.py +++ b/pycrate_csn1dir/mbms_p_t_m_channel_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_p_t_m_channel_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mbms_p_t_m_channel_description_value_part.py b/pycrate_csn1dir/mbms_p_t_m_channel_description_value_part.py index 21f9e86..7e63970 100644 --- a/pycrate_csn1dir/mbms_p_t_m_channel_description_value_part.py +++ b/pycrate_csn1dir/mbms_p_t_m_channel_description_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_p_t_m_channel_description_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mbms_service_request_message_content.py b/pycrate_csn1dir/mbms_service_request_message_content.py index 6500fa1..4d1181d 100644 --- a/pycrate_csn1dir/mbms_service_request_message_content.py +++ b/pycrate_csn1dir/mbms_service_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_service_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: MBMS service request message content # external references -from pycrate_csn1dir.tmgi_ie import tmgi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.tmgi_ie import tmgi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/mbms_session_identity_value_part.py b/pycrate_csn1dir/mbms_session_identity_value_part.py index 1f6bd73..69fee4f 100644 --- a/pycrate_csn1dir/mbms_session_identity_value_part.py +++ b/pycrate_csn1dir/mbms_session_identity_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_session_identity_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mbms_session_parameters_list_ie.py b/pycrate_csn1dir/mbms_session_parameters_list_ie.py index 0d8083b..795a68d 100644 --- a/pycrate_csn1dir/mbms_session_parameters_list_ie.py +++ b/pycrate_csn1dir/mbms_session_parameters_list_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_session_parameters_list_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mbms_session_parameters_list_value_part.py b/pycrate_csn1dir/mbms_session_parameters_list_value_part.py index e0f1b2d..b43554a 100644 --- a/pycrate_csn1dir/mbms_session_parameters_list_value_part.py +++ b/pycrate_csn1dir/mbms_session_parameters_list_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_session_parameters_list_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mbms_sessions_list_ie.py b/pycrate_csn1dir/mbms_sessions_list_ie.py index 74a6921..6068747 100644 --- a/pycrate_csn1dir/mbms_sessions_list_ie.py +++ b/pycrate_csn1dir/mbms_sessions_list_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mbms_sessions_list_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/measurement_control_parameters_description.py b/pycrate_csn1dir/measurement_control_parameters_description.py index 0c919fa..a777dbd 100644 --- a/pycrate_csn1dir/measurement_control_parameters_description.py +++ b/pycrate_csn1dir/measurement_control_parameters_description.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/measurement_control_parameters_description.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/measurement_information.py b/pycrate_csn1dir/measurement_information.py index 2635cc3..733ff35 100644 --- a/pycrate_csn1dir/measurement_information.py +++ b/pycrate_csn1dir/measurement_information.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/measurement_information.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,6 +30,65 @@ # section: 9.1.54 MEASUREMENT INFORMATION # top-level object: Measurement information +# table 9.1.54.1a +_TransP = { + 0 : 0, + 1 : 10, + 2 : 19, + 3 : 28, + 4 : 36, + 5 : 44, + 6 : 52, + 7 : 60, + 8 : 67, + 9 : 74, + 10: 81, + 11: 88, + 12: 95, + 13: 102, + 14: 109, + 15: 116, + 16: 122 + } + +def trans_p(n): + try: + return _TransP[n] + except: + return 0 + +# table 9.1.54.1b +_TransQ = { + 0 : 0, + 1 : 9, + 2 : 17, + 3 : 25, + 4 : 32, + 5 : 39, + 6 : 46, + 7 : 53, + 8 : 59, + 9 : 65, + 10: 71, + 11: 77, + 12: 83, + 13: 89, + 14: 95, + 15: 101, + 16: 106, + 17: 111, + 18: 116, + 19: 121, + 20: 126 + } + +def trans_q(n): + try: + return _TransQ[n] + except: + return 0 + + # external references from pycrate_csn1dir.pcid_group_ie import pcid_group_ie from pycrate_csn1dir.psc_group_ie import psc_group_ie @@ -45,179 +104,6 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -repeated_e_utran_measurement_control_parameters_struct = CSN1List(name='repeated_e_utran_measurement_control_parameters_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='e_utran_frequency_index', bit=3)]), - CSN1Val(name='', val='0'), - CSN1Bit(name='measurement_control_e_utran')]) - -repeated_utran_fdd_neighbour_cells_struct = CSN1List(name='repeated_utran_fdd_neighbour_cells_struct', list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='fdd_arfcn', bit=14), - CSN1Bit(name='fdd_indic0'), - CSN1Bit(name='nr_of_fdd_cells', bit=5), - CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) - -utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_fdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - -measurement_parameters_description_struct = CSN1List(name='measurement_parameters_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='multiband_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='serving_band_reporting', bit=2)])}), - CSN1Bit(name='scale_ord', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_900_reporting_offset', bit=3), - CSN1Bit(name='_900_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_1800_reporting_offset', bit=3), - CSN1Bit(name='_1800_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_400_reporting_offset', bit=3), - CSN1Bit(name='_400_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_1900_reporting_offset', bit=3), - CSN1Bit(name='_1900_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_850_reporting_offset', bit=3), - CSN1Bit(name='_850_reporting_threshold', bit=3)])})]) - -bsic_description_struct = CSN1List(name='bsic_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ba_index_start_bsic', bit=5)])}), - CSN1Bit(name='bsic', bit=6), - CSN1Bit(name='number_remaining_bsic', bit=7), - CSN1List(num=([2], lambda x: x), list=[ - CSN1Bit(name='frequency_scrolling'), - CSN1Bit(name='bsic', bit=6)])]) - -repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='tdd_arfcn', bit=14), - CSN1Bit(name='tdd_indic0'), - CSN1Bit(name='nr_of_tdd_cells', bit=5), - CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) - -utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_tdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - -repeated_e_utran_not_allowed_cells_struct = CSN1List(name='repeated_e_utran_not_allowed_cells_struct', list=[ - CSN1Ref(name='not_allowed_cells', obj=pcid_group_ie), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='e_utran_frequency_index', bit=3)]), - CSN1Val(name='', val='0')]) - -_3g_measurement_parameters_description_struct = CSN1List(name='_3g_measurement_parameters_description_struct', list=[ - CSN1Bit(name='qsearch_c', bit=4), - CSN1Val(name='', val='1'), - CSN1Bit(name='fdd_rep_quant'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_reporting_offset', bit=3), - CSN1Bit(name='fdd_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_reporting_offset', bit=3), - CSN1Bit(name='tdd_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='cdma2000_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='cdma2000_reporting_offset', bit=3), - CSN1Bit(name='cdma2000_reporting_threshold', bit=3)])})]) - -rtd6_struct = CSN1List(name='rtd6_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='rtd', bit=6)]), - CSN1Val(name='', val='1')]) - -_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='_3g_additional_measurement_parameters_description_2_struct', alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) - -report_priority_description_struct = CSN1List(name='report_priority_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) - -e_utran_csg_description_struct = CSN1List(name='e_utran_csg_description_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='csg_pci_split', obj=pcid_group_ie), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='e_utran_frequency_index', bit=3)]), - CSN1Val(name='', val='0')]), - CSN1Val(name='', val='0')]) - -e_utran_measurement_control_parameters_description_struct = CSN1List(name='e_utran_measurement_control_parameters_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='default_measurement_control_e_utran')])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_e_utran_measurement_control_parameters', obj=repeated_e_utran_measurement_control_parameters_struct)]), - CSN1Val(name='', val='0')]) - -repeated_e_utran_nc_with_extended_earfcns_struct = CSN1List(name='repeated_e_utran_nc_with_extended_earfcns_struct', list=[ - CSN1Bit(name='earfcn_extended', bit=18), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='earfcn_extended', bit=18)]), - CSN1Val(name='', val='0'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='measurement_bandwidth', bit=3)])})]) - e_utran_measurement_parameters_description_struct = CSN1List(name='e_utran_measurement_parameters_description_struct', list=[ CSN1Bit(name='qsearch_c_e_utran', bit=4), CSN1Bit(name='e_utran_rep_quant'), @@ -275,6 +161,203 @@ e_utran_measurement_parameters_description_struct = CSN1List(name='e_utran_measu CSN1Bit(name='e_utran_tdd_reporting_offset', bit=3)])})])}), CSN1Bit(name='reporting_granularity')])})]) +_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='_3g_additional_measurement_parameters_description_2_struct', alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) + +repeated_utran_fdd_neighbour_cells_struct = CSN1List(name='repeated_utran_fdd_neighbour_cells_struct', list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='fdd_arfcn', bit=14), + CSN1Bit(name='fdd_indic0'), + CSN1Bit(name='nr_of_fdd_cells', bit=5), + #CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) + CSN1Bit(name='fdd_cell_information_field', bit=([3], trans_p))]) + +repeated_e_utran_not_allowed_cells_struct = CSN1List(name='repeated_e_utran_not_allowed_cells_struct', list=[ + CSN1Ref(name='not_allowed_cells', obj=pcid_group_ie), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='e_utran_frequency_index', bit=3)]), + CSN1Val(name='', val='0')]) + +utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_fdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) + +bsic_description_struct = CSN1List(name='bsic_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='ba_index_start_bsic', bit=5)])}), + CSN1Bit(name='bsic', bit=6), + CSN1Bit(name='number_remaining_bsic', bit=7), + CSN1List(num=([2], lambda x: x), list=[ + CSN1Bit(name='frequency_scrolling'), + CSN1Bit(name='bsic', bit=6)])]) + +repeated_e_utran_nc_with_extended_earfcns_struct = CSN1List(name='repeated_e_utran_nc_with_extended_earfcns_struct', list=[ + CSN1Bit(name='earfcn_extended', bit=18), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='earfcn_extended', bit=18)]), + CSN1Val(name='', val='0'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='measurement_bandwidth', bit=3)])})]) + +repeated_e_utran_neighbour_cells_struct = CSN1List(name='repeated_e_utran_neighbour_cells_struct', list=[ + CSN1Bit(name='earfcn', bit=16), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='earfcn', bit=16)]), + CSN1Val(name='', val='0'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='measurement_bandwidth', bit=3)])})]) + +rtd12_struct = CSN1List(name='rtd12_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='rtd', bit=12)]), + CSN1Val(name='', val='1')]) + +measurement_parameters_description_struct = CSN1List(name='measurement_parameters_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='multiband_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='serving_band_reporting', bit=2)])}), + CSN1Bit(name='scale_ord', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_900_reporting_offset', bit=3), + CSN1Bit(name='_900_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_1800_reporting_offset', bit=3), + CSN1Bit(name='_1800_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_400_reporting_offset', bit=3), + CSN1Bit(name='_400_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_1900_reporting_offset', bit=3), + CSN1Bit(name='_1900_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_850_reporting_offset', bit=3), + CSN1Bit(name='_850_reporting_threshold', bit=3)])})]) + +repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='tdd_arfcn', bit=14), + CSN1Bit(name='tdd_indic0'), + CSN1Bit(name='nr_of_tdd_cells', bit=5), + #CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) + CSN1Bit(name='tdd_cell_information_field', bit=([3], trans_q))]) + +_3g_measurement_parameters_description_struct = CSN1List(name='_3g_measurement_parameters_description_struct', list=[ + CSN1Bit(name='qsearch_c', bit=4), + CSN1Val(name='', val='1'), + CSN1Bit(name='fdd_rep_quant'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_reporting_offset', bit=3), + CSN1Bit(name='fdd_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_reporting_offset', bit=3), + CSN1Bit(name='tdd_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='cdma2000_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='cdma2000_reporting_offset', bit=3), + CSN1Bit(name='cdma2000_reporting_threshold', bit=3)])})]) + +utran_csg_cells_reporting_description_struct = CSN1List(name='utran_csg_cells_reporting_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_csg_fdd_reporting_threshold', bit=3), + CSN1Bit(name='utran_csg_fdd_reporting_threshold_2', bit=6)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_csg_tdd_reporting_threshold', bit=3)])})]) + +_3g_csg_description_struct = CSN1List(name='_3g_csg_description_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='csg_psc_split', obj=psc_group_ie), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='utran_frequency_index', bit=5)]), + CSN1Val(name='', val='0')]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='csg_fdd_uarfcn', bit=14)]), + '1': ('', [ + CSN1Bit(name='csg_tdd_uarfcn', bit=14)])})]), + CSN1Val(name='', val='0')]) + +e_utran_csg_description_struct = CSN1List(name='e_utran_csg_description_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='csg_pci_split', obj=pcid_group_ie), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='e_utran_frequency_index', bit=3)]), + CSN1Val(name='', val='0')]), + CSN1Val(name='', val='0')]) + +repeated_e_utran_measurement_control_parameters_struct = CSN1List(name='repeated_e_utran_measurement_control_parameters_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='e_utran_frequency_index', bit=3)]), + CSN1Val(name='', val='0'), + CSN1Bit(name='measurement_control_e_utran')]) + +rtd6_struct = CSN1List(name='rtd6_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='rtd', bit=6)]), + CSN1Val(name='', val='1')]) + repeated_utran_measurement_control_parameters_struct = CSN1List(name='repeated_utran_measurement_control_parameters_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -282,6 +365,20 @@ repeated_utran_measurement_control_parameters_struct = CSN1List(name='repeated_u CSN1Val(name='', val='0'), CSN1Bit(name='measurement_control_utran')]) +report_priority_description_struct = CSN1List(name='report_priority_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) + +utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_tdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) + cdma_2000_description_struct = CSN1List(name='cdma_2000_description_struct', list=[ CSN1Bit(name='cdma2000_frequency_band', bit=5), CSN1Bit(name='cdma2000_frequency', bit=11), @@ -334,61 +431,67 @@ cdma_2000_description_struct = CSN1List(name='cdma_2000_description_struct', lis CSN1Bit(name='walsh_length2', bit=3), CSN1Bit(name='aux_pilot_walsh2', bit=([2], lambda x: x + 6))])})])])})])})])]) -rtd12_struct = CSN1List(name='rtd12_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='rtd', bit=12)]), - CSN1Val(name='', val='1')]) - -utran_csg_cells_reporting_description_struct = CSN1List(name='utran_csg_cells_reporting_description_struct', list=[ +real_time_difference_description_struct = CSN1List(name='real_time_difference_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='utran_csg_fdd_reporting_threshold', bit=3), - CSN1Bit(name='utran_csg_fdd_reporting_threshold_2', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='utran_csg_tdd_reporting_threshold', bit=3)])})]) - -_3g_csg_description_struct = CSN1List(name='_3g_csg_description_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='csg_psc_split', obj=psc_group_ie), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='utran_frequency_index', bit=5)]), - CSN1Val(name='', val='0')]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='csg_fdd_uarfcn', bit=14)]), + '0': ('', []), '1': ('', [ - CSN1Bit(name='csg_tdd_uarfcn', bit=14)])})]), - CSN1Val(name='', val='0')]) + CSN1Bit(name='ba_index_start_rtd', bit=5)])}), + CSN1Ref(name='rtd_struct', obj=rtd6_struct), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='0'), + CSN1Ref(name='rtd_struct', obj=rtd6_struct)]), + CSN1Val(name='', val='1')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='ba_index_start_rtd', bit=5)])}), + CSN1Ref(name='rtd_struct', obj=rtd12_struct), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='0'), + CSN1Ref(name='rtd_struct', obj=rtd12_struct)]), + CSN1Val(name='', val='1')])})]) -repeated_e_utran_neighbour_cells_struct = CSN1List(name='repeated_e_utran_neighbour_cells_struct', list=[ - CSN1Bit(name='earfcn', bit=16), +e_utran_nc_with_extended_earfcns_description_struct = CSN1List(name='e_utran_nc_with_extended_earfcns_description_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Bit(name='earfcn', bit=16)]), + CSN1Ref(obj=repeated_e_utran_nc_with_extended_earfcns_struct)]), + CSN1Val(name='', val='0')]) + +e_utran_measurement_control_parameters_description_struct = CSN1List(name='e_utran_measurement_control_parameters_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='default_measurement_control_e_utran')])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_e_utran_measurement_control_parameters', obj=repeated_e_utran_measurement_control_parameters_struct)]), + CSN1Val(name='', val='0')]) + +e_utran_parameters_description_struct = CSN1List(name='e_utran_parameters_description_struct', list=[ + CSN1Bit(name='e_utran_start'), + CSN1Bit(name='e_utran_stop'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='e_utran_measurement_parameters_description', obj=e_utran_measurement_parameters_description_struct)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_e_utran_neighbour_cells', obj=repeated_e_utran_neighbour_cells_struct)]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_e_utran_not_allowed_cells', obj=repeated_e_utran_not_allowed_cells_struct)]), CSN1Val(name='', val='0'), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='measurement_bandwidth', bit=3)])})]) - -_3g_measurement_control_parameters_description_struct = CSN1List(name='_3g_measurement_control_parameters_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='default_measurement_control_utran')])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_measurement_control_parameters', obj=repeated_utran_measurement_control_parameters_struct)]), - CSN1Val(name='', val='0')]) + CSN1Ref(name='e_utran_measurement_control_parameters_description', obj=e_utran_measurement_control_parameters_description_struct)])})]) _3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_description_struct', list=[ CSN1Alt(alt={ @@ -416,58 +519,16 @@ _3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_descri '1': ('', [ CSN1Ref(name='cdma2000_description', obj=cdma_2000_description_struct)])})]) -e_utran_nc_with_extended_earfcns_description_struct = CSN1List(name='e_utran_nc_with_extended_earfcns_description_struct', list=[ +_3g_measurement_control_parameters_description_struct = CSN1List(name='_3g_measurement_control_parameters_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='default_measurement_control_utran')])}), CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Ref(obj=repeated_e_utran_nc_with_extended_earfcns_struct)]), + CSN1Ref(name='repeated_utran_measurement_control_parameters', obj=repeated_utran_measurement_control_parameters_struct)]), CSN1Val(name='', val='0')]) -e_utran_parameters_description_struct = CSN1List(name='e_utran_parameters_description_struct', list=[ - CSN1Bit(name='e_utran_start'), - CSN1Bit(name='e_utran_stop'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='e_utran_measurement_parameters_description', obj=e_utran_measurement_parameters_description_struct)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_e_utran_neighbour_cells', obj=repeated_e_utran_neighbour_cells_struct)]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_e_utran_not_allowed_cells', obj=repeated_e_utran_not_allowed_cells_struct)]), - CSN1Val(name='', val='0'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='e_utran_measurement_control_parameters_description', obj=e_utran_measurement_control_parameters_description_struct)])})]) - -real_time_difference_description_struct = CSN1List(name='real_time_difference_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ba_index_start_rtd', bit=5)])}), - CSN1Ref(name='rtd_struct', obj=rtd6_struct), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='0'), - CSN1Ref(name='rtd_struct', obj=rtd6_struct)]), - CSN1Val(name='', val='1')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ba_index_start_rtd', bit=5)])}), - CSN1Ref(name='rtd_struct', obj=rtd12_struct), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='0'), - CSN1Ref(name='rtd_struct', obj=rtd12_struct)]), - CSN1Val(name='', val='1')])})]) - _3g_supplementary_parameters_description_struct = CSN1List(name='_3g_supplementary_parameters_description_struct', list=[ CSN1Bit(name='utran_start'), CSN1Bit(name='utran_stop'), diff --git a/pycrate_csn1dir/measurement_results_contents.py b/pycrate_csn1dir/measurement_results_contents.py index 454af31..c8f4d17 100644 --- a/pycrate_csn1dir/measurement_results_contents.py +++ b/pycrate_csn1dir/measurement_results_contents.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/measurement_results_contents.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -59,71 +59,85 @@ measurement_results_contents = CSN1List(name='measurement_results_contents', lre '000': ('no_ncell_m', [ CSN1Ref(name='ncell_report', obj=ncell_report_struct, num=([0], lambda x: x)), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), '1': ('', [ CSN1Ref(name='utran_csg_measurement_report', obj=utran_csg_measurement_report_ie), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), None: ('', [])})]), None: ('', [])})]), '001': ('no_ncell_m', [ CSN1Ref(name='ncell_report', obj=ncell_report_struct, num=([0], lambda x: x)), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), '1': ('', [ CSN1Ref(name='utran_csg_measurement_report', obj=utran_csg_measurement_report_ie), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), None: ('', [])})]), None: ('', [])})]), '010': ('no_ncell_m', [ CSN1Ref(name='ncell_report', obj=ncell_report_struct, num=([0], lambda x: x)), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), '1': ('', [ CSN1Ref(name='utran_csg_measurement_report', obj=utran_csg_measurement_report_ie), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), None: ('', [])})]), None: ('', [])})]), '011': ('no_ncell_m', [ CSN1Ref(name='ncell_report', obj=ncell_report_struct, num=([0], lambda x: x)), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), '1': ('', [ CSN1Ref(name='utran_csg_measurement_report', obj=utran_csg_measurement_report_ie), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), None: ('', [])})]), None: ('', [])})]), '100': ('no_ncell_m', [ CSN1Ref(name='ncell_report', obj=ncell_report_struct, num=([0], lambda x: x)), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), '1': ('', [ CSN1Ref(name='utran_csg_measurement_report', obj=utran_csg_measurement_report_ie), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), None: ('', [])})]), None: ('', [])})]), '101': ('no_ncell_m', [ CSN1Ref(name='ncell_report', obj=ncell_report_struct, num=([0], lambda x: x)), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), '1': ('', [ CSN1Ref(name='utran_csg_measurement_report', obj=utran_csg_measurement_report_ie), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), None: ('', [])})]), None: ('', [])})]), '110': ('no_ncell_m', [ CSN1Ref(name='ncell_report', obj=ncell_report_struct, num=([0], lambda x: x)), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), '1': ('', [ CSN1Ref(name='utran_csg_measurement_report', obj=utran_csg_measurement_report_ie), CSN1Alt(alt={ - '0**': ('', []), + '0': ('', [ + CSN1Val(name='', val='0**')]), None: ('', [])})]), None: ('', [])})]), '111': ('no_ncell_m', [ diff --git a/pycrate_csn1dir/mprach_control_parameters_ie.py b/pycrate_csn1dir/mprach_control_parameters_ie.py index 6ad6c14..9e4a299 100644 --- a/pycrate_csn1dir/mprach_control_parameters_ie.py +++ b/pycrate_csn1dir/mprach_control_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mprach_control_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mprach_description_ie.py b/pycrate_csn1dir/mprach_description_ie.py index 68187b2..1883cdf 100644 --- a/pycrate_csn1dir/mprach_description_ie.py +++ b/pycrate_csn1dir/mprach_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mprach_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: MPRACH description IE # external references -from pycrate_csn1dir.mprach_control_parameters_ie import mprach_control_parameters_ie from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.mprach_control_parameters_ie import mprach_control_parameters_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/mprach_description_value_part.py b/pycrate_csn1dir/mprach_description_value_part.py index a4ebe2a..e0de5fb 100644 --- a/pycrate_csn1dir/mprach_description_value_part.py +++ b/pycrate_csn1dir/mprach_description_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mprach_description_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/mprach_packet_channel_request_message_content.py b/pycrate_csn1dir/mprach_packet_channel_request_message_content.py index 8e24ea2..fa22c14 100644 --- a/pycrate_csn1dir/mprach_packet_channel_request_message_content.py +++ b/pycrate_csn1dir/mprach_packet_channel_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/mprach_packet_channel_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ms_network_capability_value_part.py b/pycrate_csn1dir/ms_network_capability_value_part.py index 1f82826..72403ca 100644 --- a/pycrate_csn1dir/ms_network_capability_value_part.py +++ b/pycrate_csn1dir/ms_network_capability_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ms_network_capability_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ms_ra_capability_value_part.py b/pycrate_csn1dir/ms_ra_capability_value_part.py index dc81480..8eaa193 100644 --- a/pycrate_csn1dir/ms_ra_capability_value_part.py +++ b/pycrate_csn1dir/ms_ra_capability_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ms_ra_capability_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,6 +30,23 @@ # section: 10.5.5.12a MS Radio Access capability # top-level object: MS RA capability value part +_AccessTechnoType_dict = { + 0 : 'GSM P', + 1 : 'GSM E --note that GSM E covers GSM P', + 2 : 'GSM R --note that GSM R covers GSM E and GSM P', + 3 : 'GSM 1800', + 4 : 'GSM 1900', + 5 : 'GSM 450', + 6 : 'GSM 480', + 7 : 'GSM 850', + 8 : 'GSM 750', + 9 : 'GSM T 380', + 10 : 'GSM T 410', + 11 : 'unused', + 12 : 'GSM 710', + 13 : 'GSM T 810', +} + # code automatically generated by pycrate_csn1 @@ -43,36 +60,6 @@ spare_bits = CSN1Bit(name='spare_bits', num=-1) Spare_bits = spare_bits Spare_Bits = spare_bits -dlmc_capability_struct = CSN1List(name='dlmc_capability_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='dlmc_non_contiguous_intra_band_reception', bit=2), - CSN1Bit(name='dlmc_inter_band_reception')])}), - CSN1Bit(name='dlmc_maximum_bandwidth', bit=2), - CSN1Bit(name='dlmc_maximum_number_of_downlink_timeslots', bit=6), - CSN1Bit(name='dlmc_maximum_number_of_downlink_carriers', bit=3)]) - -enhanced_flexible_timeslot_assignment_struct = CSN1Alt(name='enhanced_flexible_timeslot_assignment_struct', alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='alternative_efta_multislot_class', bit=4), - CSN1Bit(name='efta_multislot_capability_reduction_for_downlink_dual_carrier', bit=3)])}) - -a5_bits = CSN1List(name='a5_bits', list=[ - CSN1Bit(name='a5_1'), - CSN1Bit(name='a5_2'), - CSN1Bit(name='a5_3'), - CSN1Bit(name='a5_4'), - CSN1Bit(name='a5_5'), - CSN1Bit(name='a5_6'), - CSN1Bit(name='a5_7')]) - -additional_access_technologies_struct = CSN1List(name='additional_access_technologies_struct', list=[ - CSN1Bit(name='access_technology_type', bit=4), - CSN1Bit(name='gmsk_power_class', bit=3), - CSN1Bit(name='_8psk_power_class', bit=2)]) - multislot_capability_struct = CSN1List(name='multislot_capability_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -107,6 +94,36 @@ multislot_capability_struct = CSN1List(name='multislot_capability_struct', list= '1': ('', [ CSN1Bit(name='dtm_egprs_multi_slot_class', bit=2)])})])})]) +dlmc_capability_struct = CSN1List(name='dlmc_capability_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='dlmc_non_contiguous_intra_band_reception', bit=2), + CSN1Bit(name='dlmc_inter_band_reception')])}), + CSN1Bit(name='dlmc_maximum_bandwidth', bit=2), + CSN1Bit(name='dlmc_maximum_number_of_downlink_timeslots', bit=6), + CSN1Bit(name='dlmc_maximum_number_of_downlink_carriers', bit=3)]) + +a5_bits = CSN1List(name='a5_bits', list=[ + CSN1Bit(name='a5_1'), + CSN1Bit(name='a5_2'), + CSN1Bit(name='a5_3'), + CSN1Bit(name='a5_4'), + CSN1Bit(name='a5_5'), + CSN1Bit(name='a5_6'), + CSN1Bit(name='a5_7')]) + +additional_access_technologies_struct = CSN1List(name='additional_access_technologies_struct', list=[ + CSN1Bit(name='access_technology_type', bit=4), + CSN1Bit(name='gmsk_power_class', bit=3), + CSN1Bit(name='_8psk_power_class', bit=2)]) + +enhanced_flexible_timeslot_assignment_struct = CSN1Alt(name='enhanced_flexible_timeslot_assignment_struct', alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alternative_efta_multislot_class', bit=4), + CSN1Bit(name='efta_multislot_capability_reduction_for_downlink_dual_carrier', bit=3)])}) + content = CSN1List(name='content', trunc=True, list=[ CSN1Bit(name='rf_power_capability', bit=3), CSN1Alt(alt={ @@ -247,7 +264,8 @@ ms_ra_capability_value_part_struct = CSN1List(name='ms_ra_capability_value_part_ CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1SelfRef()])})]) + CSN1SelfRef()])})], + kdic=_AccessTechnoType_dict) ms_ra_capability_value_part = CSN1List(name='ms_ra_capability_value_part', list=[ CSN1Ref(obj=ms_ra_capability_value_part_struct), diff --git a/pycrate_csn1dir/ms_radio_access_capability_2_ie.py b/pycrate_csn1dir/ms_radio_access_capability_2_ie.py index fe0e291..192ef34 100644 --- a/pycrate_csn1dir/ms_radio_access_capability_2_ie.py +++ b/pycrate_csn1dir/ms_radio_access_capability_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ms_radio_access_capability_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/multiple_downlink_assignment_2_ie.py b/pycrate_csn1dir/multiple_downlink_assignment_2_ie.py index 0ff03a7..785729d 100644 --- a/pycrate_csn1dir/multiple_downlink_assignment_2_ie.py +++ b/pycrate_csn1dir/multiple_downlink_assignment_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/multiple_downlink_assignment_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -86,17 +86,6 @@ btti_multiple_downlink_assignment_struct = CSN1List(name='btti_multiple_downlink CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), CSN1Val(name='', val='0')]) -rtti_multiple_downlink_assignment_sc_struct = CSN1List(name='rtti_multiple_downlink_assignment_sc_struct', list=[ - CSN1Bit(name='rtti_downlink_pdch_pair_assignment_sc', bit=4), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='uplink_control_timeslot_c1', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), - CSN1Val(name='', val='0')]) - rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downlink_assignment_dc_struct', list=[ CSN1Bit(name='rtti_downlink_pdch_pair_assignment_dc', bit=8), CSN1Alt(alt={ @@ -112,6 +101,17 @@ rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downl CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), CSN1Val(name='', val='0')]) +rtti_multiple_downlink_assignment_sc_struct = CSN1List(name='rtti_multiple_downlink_assignment_sc_struct', list=[ + CSN1Bit(name='rtti_downlink_pdch_pair_assignment_sc', bit=4), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='uplink_control_timeslot_c1', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), + CSN1Val(name='', val='0')]) + multiple_downlink_assignment_2_ie = CSN1List(name='multiple_downlink_assignment_2_ie', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/multiple_tbf_downlink_assignment_message_content.py b/pycrate_csn1dir/multiple_tbf_downlink_assignment_message_content.py index 1281ba4..a6002d0 100644 --- a/pycrate_csn1dir/multiple_tbf_downlink_assignment_message_content.py +++ b/pycrate_csn1dir/multiple_tbf_downlink_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/multiple_tbf_downlink_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,16 +31,16 @@ # top-level object: Multiple TBF Downlink Assignment message content # external references -from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie +from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.tlli_g_rnti_ie import tlli_g_rnti_ie -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie -from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -49,21 +49,6 @@ from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_ from pycrate_csn1.csnobj import * -downlink_tbf_assignment_2_struct = CSN1List(name='downlink_tbf_assignment_2_struct', list=[ - CSN1Bit(name='pfi', bit=7), - CSN1Bit(name='rlc_mode'), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Bit(name='control_ack'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Bit(name='event_based_fanr'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) - downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', list=[ CSN1Alt(alt={ '0': ('', [ @@ -82,6 +67,32 @@ downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', '1': ('', [ CSN1Bit(name='hfn_lsb')])})]) +assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ + CSN1Bit(name='assignment_type', bit=2), + CSN1Bit(name='carrier_id')]) + +multiple_downlink_tbf_assignment_struct = CSN1List(name='multiple_downlink_tbf_assignment_struct', list=[ + CSN1Bit(name='timeslot_allocation', bit=8), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]), + CSN1Val(name='', val='0')]) + +downlink_tbf_assignment_2_struct = CSN1List(name='downlink_tbf_assignment_2_struct', list=[ + CSN1Bit(name='pfi', bit=7), + CSN1Bit(name='rlc_mode'), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Bit(name='control_ack'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Bit(name='event_based_fanr'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) + rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downlink_assignment_dc_struct', list=[ CSN1Bit(name='rtti_downlink_pdch_pair_assignment_dc', bit=8), CSN1List(num=-1, list=[ @@ -89,10 +100,6 @@ rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downl CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), CSN1Val(name='', val='0')]) -assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ - CSN1Bit(name='assignment_type', bit=2), - CSN1Bit(name='carrier_id')]) - btti_multiple_downlink_assignment_struct = CSN1List(name='btti_multiple_downlink_assignment_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -107,13 +114,6 @@ btti_multiple_downlink_assignment_struct = CSN1List(name='btti_multiple_downlink CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), CSN1Val(name='', val='0')]) -multiple_downlink_tbf_assignment_struct = CSN1List(name='multiple_downlink_tbf_assignment_struct', list=[ - CSN1Bit(name='timeslot_allocation', bit=8), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]), - CSN1Val(name='', val='0')]) - rtti_multiple_downlink_assignment_sc_struct = CSN1List(name='rtti_multiple_downlink_assignment_sc_struct', list=[ CSN1Bit(name='rtti_downlink_pdch_pair_assignment_sc', bit=4), CSN1List(num=-1, list=[ diff --git a/pycrate_csn1dir/multiple_tbf_timeslot_reconfigure_message_content.py b/pycrate_csn1dir/multiple_tbf_timeslot_reconfigure_message_content.py index 9e15125..4ef8291 100644 --- a/pycrate_csn1dir/multiple_tbf_timeslot_reconfigure_message_content.py +++ b/pycrate_csn1dir/multiple_tbf_timeslot_reconfigure_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/multiple_tbf_timeslot_reconfigure_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,16 +31,16 @@ # top-level object: Multiple TBF Timeslot Reconfigure message content # external references -from pycrate_csn1dir.pulse_format_ie import pulse_format_ie from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie +from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.pulse_format_ie import pulse_format_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -49,6 +49,51 @@ from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_fr from pycrate_csn1.csnobj import * +downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', list=[ + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='rb_id', bit=5)]), + '1': ('', [ + CSN1Bit(name='pfi', bit=7), + CSN1Bit(name='rlc_mode')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='uplink_control_timeslot', bit=3)])}), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Bit(name='control_ack'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) + +assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ + CSN1Bit(name='assignment_type', bit=2), + CSN1Bit(name='carrier_id')]) + +downlink_tbf_assignment_2_struct = CSN1List(name='downlink_tbf_assignment_2_struct', list=[ + CSN1Bit(name='pfi', bit=7), + CSN1Bit(name='rlc_mode'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='uplink_control_timeslot_c1', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='uplink_control_timeslot_c2', bit=3)])}), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Bit(name='control_ack'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Bit(name='event_based_fanr'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) + timeslot_description_2_struct = CSN1Alt(name='timeslot_description_2_struct', alt={ '0': ('', [ CSN1Bit(name='ms_timeslot_allocation_c1', bit=8), @@ -127,24 +172,6 @@ timeslot_description_2_struct = CSN1Alt(name='timeslot_description_2_struct', al '1': ('', [ CSN1Bit(name='gamma_tn7_c2', bit=5)])})])}) -downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', list=[ - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='rb_id', bit=5)]), - '1': ('', [ - CSN1Bit(name='pfi', bit=7), - CSN1Bit(name='rlc_mode')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='uplink_control_timeslot', bit=3)])}), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Bit(name='control_ack'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) - uplink_tbf_assignment_2_struct = CSN1List(name='uplink_tbf_assignment_2_struct', list=[ CSN1Bit(name='pfi', bit=7), CSN1Bit(name='rlc_mode'), @@ -187,9 +214,43 @@ uplink_tbf_assignment_2_struct = CSN1List(name='uplink_tbf_assignment_2_struct', '1': ('', [ CSN1Bit(name='usf_allocation', bit=3)])})])]) -assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ - CSN1Bit(name='assignment_type', bit=2), - CSN1Bit(name='carrier_id')]) +timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ + '0': ('', [ + CSN1Bit(name='ms_timeslot_allocation', bit=8)]), + '1': ('', [ + CSN1Bit(name='alpha', bit=4), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn0', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn1', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn2', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn3', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn4', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn5', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn6', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn7', bit=5)])})])}) multiple_downlink_assignment_struct = CSN1List(name='multiple_downlink_assignment_struct', list=[ CSN1Bit(name='timeslot_allocation', bit=8), @@ -202,6 +263,41 @@ multiple_downlink_assignment_struct = CSN1List(name='multiple_downlink_assignmen CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]), CSN1Val(name='', val='0')]) +uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='rb_id', bit=5)]), + '1': ('', [ + CSN1Bit(name='pfi', bit=7), + CSN1Bit(name='rlc_mode')])}), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='channel_coding_command', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='uplink_egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='usf_granularity'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='usf_allocation', bit=3)]), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3), + CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3)])})])})]) + multiple_uplink_assignment_2_struct = CSN1List(name='multiple_uplink_assignment_2_struct', list=[ CSN1Bit(name='extended_dynamic_allocation'), CSN1Alt(alt={ @@ -261,9 +357,8 @@ multiple_uplink_assignment_2_struct = CSN1List(name='multiple_uplink_assignment_ CSN1Bit(name='rtti_usf_mode')]), CSN1Val(name='', val='0')])})])})]) -downlink_tbf_assignment_2_struct = CSN1List(name='downlink_tbf_assignment_2_struct', list=[ - CSN1Bit(name='pfi', bit=7), - CSN1Bit(name='rlc_mode'), +rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downlink_assignment_dc_struct', list=[ + CSN1Bit(name='rtti_downlink_pdch_pair_assignment_dc', bit=8), CSN1Alt(alt={ '0': ('', []), '1': ('', [ @@ -272,52 +367,10 @@ downlink_tbf_assignment_2_struct = CSN1List(name='downlink_tbf_assignment_2_stru '0': ('', []), '1': ('', [ CSN1Bit(name='uplink_control_timeslot_c2', bit=3)])}), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Bit(name='control_ack'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Bit(name='event_based_fanr'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) - -uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='rb_id', bit=5)]), - '1': ('', [ - CSN1Bit(name='pfi', bit=7), - CSN1Bit(name='rlc_mode')])}), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='channel_coding_command', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='uplink_egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='usf_granularity'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='usf_allocation', bit=3)]), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3), - CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3)])})])})]) + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), + CSN1Val(name='', val='0')]) btti_multiple_downlink_assignment_struct = CSN1List(name='btti_multiple_downlink_assignment_struct', list=[ CSN1Alt(alt={ @@ -341,44 +394,6 @@ btti_multiple_downlink_assignment_struct = CSN1List(name='btti_multiple_downlink CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), CSN1Val(name='', val='0')]) -timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ - '0': ('', [ - CSN1Bit(name='ms_timeslot_allocation', bit=8)]), - '1': ('', [ - CSN1Bit(name='alpha', bit=4), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn0', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn1', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn2', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn3', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn4', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn5', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn6', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn7', bit=5)])})])}) - rtti_multiple_downlink_assignment_sc_struct = CSN1List(name='rtti_multiple_downlink_assignment_sc_struct', list=[ CSN1Bit(name='rtti_downlink_pdch_pair_assignment_sc', bit=4), CSN1Alt(alt={ @@ -390,21 +405,6 @@ rtti_multiple_downlink_assignment_sc_struct = CSN1List(name='rtti_multiple_downl CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), CSN1Val(name='', val='0')]) -rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downlink_assignment_dc_struct', list=[ - CSN1Bit(name='rtti_downlink_pdch_pair_assignment_dc', bit=8), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='uplink_control_timeslot_c1', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='uplink_control_timeslot_c2', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), - CSN1Val(name='', val='0')]) - multiple_uplink_assignment_struct = CSN1List(name='multiple_uplink_assignment_struct', list=[ CSN1Bit(name='extended_dynamic_allocation'), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/multiple_tbf_uplink_assignment_message_content.py b/pycrate_csn1dir/multiple_tbf_uplink_assignment_message_content.py index 62a1a51..b0a4273 100644 --- a/pycrate_csn1dir/multiple_tbf_uplink_assignment_message_content.py +++ b/pycrate_csn1dir/multiple_tbf_uplink_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/multiple_tbf_uplink_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,18 +31,18 @@ # top-level object: Multiple TBF Uplink Assignment message content # external references -from pycrate_csn1dir.pulse_format_ie import pulse_format_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie +from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.tlli_g_rnti_ie import tlli_g_rnti_ie -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie -from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie +from pycrate_csn1dir.pulse_format_ie import pulse_format_ie from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie -from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie +from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -51,10 +51,6 @@ from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_ from pycrate_csn1.csnobj import * -assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ - CSN1Bit(name='assignment_type', bit=2), - CSN1Bit(name='carrier_id')]) - timeslot_description_2_struct = CSN1Alt(name='timeslot_description_2_struct', alt={ '0': ('', [ CSN1Bit(name='ms_timeslot_allocation_c1', bit=8), @@ -133,41 +129,6 @@ timeslot_description_2_struct = CSN1Alt(name='timeslot_description_2_struct', al '1': ('', [ CSN1Bit(name='gamma_tn7_c2', bit=5)])})])}) -uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='rb_id', bit=5)]), - '1': ('', [ - CSN1Bit(name='pfi', bit=7), - CSN1Bit(name='rlc_mode')])}), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='channel_coding_command', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='usf_granularity'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='usf_allocation', bit=3)]), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3), - CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3)])})])})]) - uplink_tbf_assignment_2_struct = CSN1List(name='uplink_tbf_assignment_2_struct', list=[ CSN1Bit(name='pfi', bit=7), CSN1Bit(name='rlc_mode'), @@ -210,44 +171,6 @@ uplink_tbf_assignment_2_struct = CSN1List(name='uplink_tbf_assignment_2_struct', '1': ('', [ CSN1Bit(name='usf_allocation', bit=3)])})])]) -timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ - '0': ('', [ - CSN1Bit(name='ms_timeslot_allocation', bit=8)]), - '1': ('', [ - CSN1Bit(name='alpha', bit=4), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn0', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn1', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn2', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn3', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn4', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn5', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn6', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma_tn7', bit=5)])})])}) - uplink_assignment_2_struct = CSN1List(name='uplink_assignment_2_struct', list=[ CSN1Bit(name='extended_dynamic_allocation'), CSN1Alt(alt={ @@ -316,6 +239,79 @@ uplink_assignment_2_struct = CSN1List(name='uplink_assignment_2_struct', list=[ CSN1Bit(name='rtti_usf_mode')]), CSN1Val(name='', val='0')])})])})]) +timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ + '0': ('', [ + CSN1Bit(name='ms_timeslot_allocation', bit=8)]), + '1': ('', [ + CSN1Bit(name='alpha', bit=4), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn0', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn1', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn2', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn3', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn4', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn5', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn6', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma_tn7', bit=5)])})])}) + +uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='rb_id', bit=5)]), + '1': ('', [ + CSN1Bit(name='pfi', bit=7), + CSN1Bit(name='rlc_mode')])}), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='channel_coding_command', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='usf_granularity'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='usf_allocation', bit=3)]), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3), + CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3)])})])})]) + uplink_assignment_struct = CSN1List(name='uplink_assignment_struct', list=[ CSN1Bit(name='extended_dynamic_allocation'), CSN1Alt(alt={ @@ -340,6 +336,10 @@ uplink_assignment_struct = CSN1List(name='uplink_assignment_struct', list=[ CSN1Ref(name='uplink_tbf_assignment', obj=uplink_tbf_assignment_struct)]), CSN1Val(name='', val='0')])})]) +assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ + CSN1Bit(name='assignment_type', bit=2), + CSN1Bit(name='carrier_id')]) + multiple_tbf_uplink_assignment_message_content = CSN1List(name='multiple_tbf_uplink_assignment_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/multiple_uplink_assignment_2_ie.py b/pycrate_csn1dir/multiple_uplink_assignment_2_ie.py index 7dd8027..e53de68 100644 --- a/pycrate_csn1dir/multiple_uplink_assignment_2_ie.py +++ b/pycrate_csn1dir/multiple_uplink_assignment_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/multiple_uplink_assignment_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -34,8 +34,8 @@ from pycrate_csn1dir.pulse_format_ie import pulse_format_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.egprs_level_ie import egprs_level_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -44,60 +44,6 @@ from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie from pycrate_csn1.csnobj import * -rtti_uplink_tbf_assignment_struct = CSN1List(name='rtti_uplink_tbf_assignment_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='pfi', bit=7)])}), - CSN1Bit(name='rlc_mode'), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='uplink_egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='reported_timeslots_c1', bit=8), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='reported_timeslots_c2', bit=8)])})])}), - CSN1Bit(name='usf_granularity'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tbf_uplink_pairs_allocation', bit=('# unresolved: N_PAIRS', lambda: 0))])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='usf_c1', bit=3), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_c2', bit=3)])})]), - '1': ('', [ - CSN1Bit(name='usf', bit=3), - CSN1Alt(num=('# unresolved: N_PAIRS', lambda: 0), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_2', bit=3), - CSN1Alt(num=('# unresolved: N_PAIRS', lambda: 0), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_2', bit=3)])})])})])})]) - timeslot_description_2_struct = CSN1Alt(name='timeslot_description_2_struct', alt={ '0': ('', [ CSN1Bit(name='ms_timeslot_allocation_c1', bit=8), @@ -176,6 +122,60 @@ timeslot_description_2_struct = CSN1Alt(name='timeslot_description_2_struct', al '1': ('', [ CSN1Bit(name='gamma_tn7_c2', bit=5)])})])}) +rtti_uplink_tbf_assignment_struct = CSN1List(name='rtti_uplink_tbf_assignment_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='pfi', bit=7)])}), + CSN1Bit(name='rlc_mode'), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='uplink_egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='reported_timeslots_c1', bit=8), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='reported_timeslots_c2', bit=8)])})])}), + CSN1Bit(name='usf_granularity'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tbf_uplink_pairs_allocation', bit=('# unresolved: N_PAIRS', lambda: 0))])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='usf_c1', bit=3), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_c2', bit=3)])})]), + '1': ('', [ + CSN1Bit(name='usf', bit=3), + CSN1Alt(num=('# unresolved: N_PAIRS', lambda: 0), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_2', bit=3), + CSN1Alt(num=('# unresolved: N_PAIRS', lambda: 0), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_2', bit=3)])})])})])})]) + btti_uplink_tbf_assignment_struct = CSN1List(name='btti_uplink_tbf_assignment_struct', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/nas_container_for_ps_handover_ie.py b/pycrate_csn1dir/nas_container_for_ps_handover_ie.py index 4b96eb5..fed2088 100644 --- a/pycrate_csn1dir/nas_container_for_ps_handover_ie.py +++ b/pycrate_csn1dir/nas_container_for_ps_handover_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/nas_container_for_ps_handover_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/non_gprs_cell_options_ie.py b/pycrate_csn1dir/non_gprs_cell_options_ie.py index e6bab27..8cf2818 100644 --- a/pycrate_csn1dir/non_gprs_cell_options_ie.py +++ b/pycrate_csn1dir/non_gprs_cell_options_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/non_gprs_cell_options_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/notification_facch.py b/pycrate_csn1dir/notification_facch.py index d6703ae..c8cafe2 100644 --- a/pycrate_csn1dir/notification_facch.py +++ b/pycrate_csn1dir/notification_facch.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/notification_facch.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,6 +43,10 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding +priority_uplink_access = CSN1Alt(name='priority_uplink_access', alt={ + 'H': ('', []), + 'L': ('', [])}) + emergency_ind = CSN1Alt(name='emergency_ind', alt={ 'H': ('', []), 'L': ('', [])}) @@ -51,10 +55,6 @@ nas_type4_lv = CSN1List(name='nas_type4_lv', list=[ CSN1Bit(name='length', bit=8), CSN1Bit(name='value', bit=([0], lambda x: 8 * x))]) -priority_uplink_access = CSN1Alt(name='priority_uplink_access', alt={ - 'H': ('', []), - 'L': ('', [])}) - group_channel_description = CSN1List(name='group_channel_description', list=[ CSN1Bit(name='channel_description', bit=24), CSN1Alt(alt={ @@ -66,6 +66,13 @@ group_channel_description = CSN1List(name='group_channel_description', list=[ '1': ('', [ CSN1Bit(name='frequency_short_list', bit=64)])})])})]) +group_call_information = CSN1List(name='group_call_information', list=[ + CSN1Bit(name='group_call_reference', bit=36), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(obj=group_channel_description)])})]) + paging_information = CSN1List(name='paging_information', list=[ CSN1Ref(name='mobile_identity', obj=nas_type4_lv), CSN1Bit(name='channel_first', bit=2), @@ -74,13 +81,6 @@ paging_information = CSN1List(name='paging_information', list=[ '1': ('', [ CSN1Bit(name='emlpp_priority', bit=3)])})]) -group_call_information = CSN1List(name='group_call_information', list=[ - CSN1Bit(name='group_call_reference', bit=36), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(obj=group_channel_description)])})]) - notification_facch = CSN1List(name='notification_facch', list=[ CSN1Bit(name='rr_short_pd'), CSN1Bit(name='message_type', bit=5), diff --git a/pycrate_csn1dir/notify_application_data.py b/pycrate_csn1dir/notify_application_data.py index 7e476f3..4933bcf 100644 --- a/pycrate_csn1dir/notify_application_data.py +++ b/pycrate_csn1dir/notify_application_data.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. P1sec. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -21,14 +21,14 @@ # * MA 02110-1301 USA # * # *-------------------------------------------------------- -# * File Name : pycrate_csn1dir/notification_application_data.py -# * Created : 2018-10-08 +# * File Name : pycrate_csn1dir/vgcs_neighbour_cell_information.py +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ # specification: TS 44.018 - d80 # section: 9.1.58 NOTIFY APPLICATION DATA -# top-level object: NOTIFY APPLICATION DATA +# top-level object: VGCS Neighbour Cell Information diff --git a/pycrate_csn1dir/ntn_rest_octets.py b/pycrate_csn1dir/ntn_rest_octets.py index 69e01a5..cec3c4c 100644 --- a/pycrate_csn1dir/ntn_rest_octets.py +++ b/pycrate_csn1dir/ntn_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ntn_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: NTN Rest Octets # external references -from pycrate_csn1dir.notification_facch import group_call_information from pycrate_csn1dir.notification_facch import emergency_ind +from pycrate_csn1dir.notification_facch import group_call_information # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -45,6 +45,18 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding +list_of_reduced_gcr = CSN1List(name='list_of_reduced_gcr', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='reduced_gcr', bit=28)]), + CSN1Val(name='', val='0')]) + +list_of_group_call_nch_information = CSN1Alt(name='list_of_group_call_nch_information', alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(obj=group_call_information), + CSN1SelfRef()])}) + list_of_vstk_rand_information = CSN1List(name='list_of_vstk_rand_information', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -55,24 +67,12 @@ list_of_vstk_rand_information = CSN1List(name='list_of_vstk_rand_information', l CSN1Bit(name='vstk_rand', bit=36)])})]), CSN1Val(name='', val='0')]) -list_of_reduced_gcr = CSN1List(name='list_of_reduced_gcr', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='reduced_gcr', bit=28)]), - CSN1Val(name='', val='0')]) - list_of_emergency_information = CSN1Alt(name='list_of_emergency_information', alt={ '0': ('', []), '1': ('', [ CSN1Ref(obj=emergency_ind), CSN1SelfRef()])}) -list_of_group_call_nch_information = CSN1Alt(name='list_of_group_call_nch_information', alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(obj=group_call_information), - CSN1SelfRef()])}) - ntn_rest_octets = CSN1List(name='ntn_rest_octets', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/p1_rest_octets.py b/pycrate_csn1dir/p1_rest_octets.py index 670db0e..4a5cafb 100644 --- a/pycrate_csn1dir/p1_rest_octets.py +++ b/pycrate_csn1dir/p1_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/p1_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: P1 Rest Octets # external references -from pycrate_csn1dir.notification_facch import group_call_information -from pycrate_csn1dir.mbms_channel_parameters_ie import mbms_channel_parameters_ie from pycrate_csn1dir.mbms_sessions_list_ie import mbms_sessions_list_ie +from pycrate_csn1dir.mbms_channel_parameters_ie import mbms_channel_parameters_ie +from pycrate_csn1dir.notification_facch import group_call_information # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -46,8 +46,6 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -priority = CSN1Bit(name='priority', bit=3) - etws_primary_notification_struct = CSN1List(name='etws_primary_notification_struct', list=[ CSN1Alt(alt={ '0': ('', [ @@ -73,6 +71,8 @@ mbms_information = CSN1List(name='mbms_information', list=[ CSN1Ref(name='mbms_sessions_list', obj=mbms_sessions_list_ie)]), CSN1Val(name='', val='0')]) +priority = CSN1Bit(name='priority', bit=3) + p1_rest_octets = CSN1List(name='p1_rest_octets', list=[ CSN1Alt(alt={ 'H': ('', [ diff --git a/pycrate_csn1dir/p2_rest_octets.py b/pycrate_csn1dir/p2_rest_octets.py index 6226fc5..31d7bab 100644 --- a/pycrate_csn1dir/p2_rest_octets.py +++ b/pycrate_csn1dir/p2_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/p2_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/p3_rest_octets.py b/pycrate_csn1dir/p3_rest_octets.py index cb0bc44..e2b71c4 100644 --- a/pycrate_csn1dir/p3_rest_octets.py +++ b/pycrate_csn1dir/p3_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/p3_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_access_reject_message_content.py b/pycrate_csn1dir/packet_access_reject_message_content.py index 9611751..df29a2a 100644 --- a/pycrate_csn1dir/packet_access_reject_message_content.py +++ b/pycrate_csn1dir/packet_access_reject_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_access_reject_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,8 +32,8 @@ # external references from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -42,6 +42,13 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * +iu_mode_reject_struct = CSN1List(name='iu_mode_reject_struct', list=[ + CSN1Bit(name='g_rnti_extension', bit=4), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='rb_id', bit=5)]), + CSN1Val(name='', val='0')]) + a_gb_mode_reject_struct = CSN1List(name='a_gb_mode_reject_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -64,13 +71,6 @@ reject_struct = CSN1List(name='reject_struct', list=[ CSN1Bit(name='wait_indication', bit=8), CSN1Bit(name='wait__indication_size')])})]) -iu_mode_reject_struct = CSN1List(name='iu_mode_reject_struct', list=[ - CSN1Bit(name='g_rnti_extension', bit=4), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='rb_id', bit=5)]), - CSN1Val(name='', val='0')]) - packet_access_reject_message_content = CSN1List(name='packet_access_reject_message_content', trunc=True, list=[ CSN1Bit(name='page_mode', bit=2), CSN1Ref(name='reject', obj=reject_struct), diff --git a/pycrate_csn1dir/packet_application_information_message_content.py b/pycrate_csn1dir/packet_application_information_message_content.py index efb41ec..ce13025 100644 --- a/pycrate_csn1dir/packet_application_information_message_content.py +++ b/pycrate_csn1dir/packet_application_information_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_application_information_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_cell_change_continue_message_content.py b/pycrate_csn1dir/packet_cell_change_continue_message_content.py index 22b0133..69e9592 100644 --- a/pycrate_csn1dir/packet_cell_change_continue_message_content.py +++ b/pycrate_csn1dir/packet_cell_change_continue_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_cell_change_continue_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet Cell Change Continue message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_cell_change_failure_message_content.py b/pycrate_csn1dir/packet_cell_change_failure_message_content.py index 3546a61..922b9f3 100644 --- a/pycrate_csn1dir/packet_cell_change_failure_message_content.py +++ b/pycrate_csn1dir/packet_cell_change_failure_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_cell_change_failure_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,13 +31,13 @@ # top-level object: Packet Cell Change Failure message content # external references +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.utran_fdd_target_cell_ie import utran_fdd_target_cell_ie +from pycrate_csn1dir.utran_tdd_target_cell_ie import utran_tdd_target_cell_ie from pycrate_csn1dir.utran_csg_target_cell_ie import utran_csg_target_cell_ie +from pycrate_csn1dir.e_utran_target_cell_ie import e_utran_target_cell_ie from pycrate_csn1dir.e_utran_target_cell_with_extended_earfcn_ie import e_utran_target_cell_with_extended_earfcn_ie from pycrate_csn1dir.e_utran_csg_target_cell_ie import e_utran_csg_target_cell_ie -from pycrate_csn1dir.padding_bits import padding_bits -from pycrate_csn1dir.utran_tdd_target_cell_ie import utran_tdd_target_cell_ie -from pycrate_csn1dir.utran_fdd_target_cell_ie import utran_fdd_target_cell_ie -from pycrate_csn1dir.e_utran_target_cell_ie import e_utran_target_cell_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_cell_change_notification_message_content.py b/pycrate_csn1dir/packet_cell_change_notification_message_content.py index 8bc003a..ba7eef5 100644 --- a/pycrate_csn1dir/packet_cell_change_notification_message_content.py +++ b/pycrate_csn1dir/packet_cell_change_notification_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_cell_change_notification_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: Packet Cell Change Notification message content # external references +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.utran_csg_measurement_report_ie import utran_csg_measurement_report_ie from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.e_utran_csg_measurement_report_ie import e_utran_csg_measurement_report_ie -from pycrate_csn1dir.utran_csg_measurement_report_ie import utran_csg_measurement_report_ie -from pycrate_csn1dir.padding_bits import padding_bits # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -43,26 +43,6 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -ccn_measurement_report_struct = CSN1List(name='ccn_measurement_report_struct', list=[ - CSN1Bit(name='rxlev_serving_cell', bit=6), - CSN1Val(name='', val='0'), - CSN1Bit(name='number_of_nc_measurements', bit=3), - CSN1List(num=([2], lambda x: x), list=[ - CSN1Bit(name='frequency_n', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bsic_n', bit=6)])}), - CSN1Bit(name='rxlev_n', bit=6)])]) - -e_utran_ccn_measurement_report_struct = CSN1List(name='e_utran_ccn_measurement_report_struct', list=[ - CSN1Bit(name='_3g_ba_used'), - CSN1Bit(name='n_e_utran', bit=2), - CSN1List(num=([1], lambda x: x + 1), list=[ - CSN1Bit(name='e_utran_frequency_index', bit=3), - CSN1Bit(name='cell_identity', bit=9), - CSN1Bit(name='reporting_quantity', bit=6)])]) - e_utran_target_cell_with_extended_earfcn_struct = CSN1List(name='e_utran_target_cell_with_extended_earfcn_struct', list=[ CSN1Bit(name='earfcn_extended', bit=18), CSN1Alt(alt={ @@ -72,21 +52,6 @@ e_utran_target_cell_with_extended_earfcn_struct = CSN1List(name='e_utran_target_ CSN1Bit(name='physical_layer_cell_identity', bit=9), CSN1Bit(name='reporting_quantity', bit=6)]) -_3g_ccn_measurement_report_struct = CSN1List(name='_3g_ccn_measurement_report_struct', list=[ - CSN1Bit(name='n_3g', bit=3), - CSN1List(num=([0], lambda x: x + 1), list=[ - CSN1Bit(name='_3g_cell_list_index', bit=7), - CSN1Bit(name='reporting_quantity', bit=6)])]) - -e_utran_target_cell_struct = CSN1List(name='e_utran_target_cell_struct', list=[ - CSN1Bit(name='earfcn', bit=16), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='measurement_bandwidth', bit=3)])}), - CSN1Bit(name='physical_layer_cell_identity', bit=9), - CSN1Bit(name='reporting_quantity', bit=6)]) - _3g_target_cell_struct = CSN1List(name='_3g_target_cell_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -109,6 +74,41 @@ _3g_target_cell_struct = CSN1List(name='_3g_target_cell_struct', list=[ CSN1Bit(name='sync_case')])}), CSN1Bit(name='reporting_quantity', bit=6)]) +ccn_measurement_report_struct = CSN1List(name='ccn_measurement_report_struct', list=[ + CSN1Bit(name='rxlev_serving_cell', bit=6), + CSN1Val(name='', val='0'), + CSN1Bit(name='number_of_nc_measurements', bit=3), + CSN1List(num=([2], lambda x: x), list=[ + CSN1Bit(name='frequency_n', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bsic_n', bit=6)])}), + CSN1Bit(name='rxlev_n', bit=6)])]) + +e_utran_target_cell_struct = CSN1List(name='e_utran_target_cell_struct', list=[ + CSN1Bit(name='earfcn', bit=16), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='measurement_bandwidth', bit=3)])}), + CSN1Bit(name='physical_layer_cell_identity', bit=9), + CSN1Bit(name='reporting_quantity', bit=6)]) + +_3g_ccn_measurement_report_struct = CSN1List(name='_3g_ccn_measurement_report_struct', list=[ + CSN1Bit(name='n_3g', bit=3), + CSN1List(num=([0], lambda x: x + 1), list=[ + CSN1Bit(name='_3g_cell_list_index', bit=7), + CSN1Bit(name='reporting_quantity', bit=6)])]) + +e_utran_ccn_measurement_report_struct = CSN1List(name='e_utran_ccn_measurement_report_struct', list=[ + CSN1Bit(name='_3g_ba_used'), + CSN1Bit(name='n_e_utran', bit=2), + CSN1List(num=([1], lambda x: x + 1), list=[ + CSN1Bit(name='e_utran_frequency_index', bit=3), + CSN1Bit(name='cell_identity', bit=9), + CSN1Bit(name='reporting_quantity', bit=6)])]) + packet_cell_change_notification_message_content = CSN1List(name='packet_cell_change_notification_message_content', list=[ CSN1Ref(name='global_tfi', obj=global_tfi_ie), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/packet_cell_change_order_message_content.py b/pycrate_csn1dir/packet_cell_change_order_message_content.py index 4ceb099..ad2cc6c 100644 --- a/pycrate_csn1dir/packet_cell_change_order_message_content.py +++ b/pycrate_csn1dir/packet_cell_change_order_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_cell_change_order_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,16 +30,75 @@ # section: 11.2.4 Packet Cell Change Order # top-level object: Packet Cell Change Order message content +# table 11.2.9b.2.a +_TransP = { + 0 : 0, + 1 : 10, + 2 : 19, + 3 : 28, + 4 : 36, + 5 : 44, + 6 : 52, + 7 : 60, + 8 : 67, + 9 : 74, + 10: 81, + 11: 88, + 12: 95, + 13: 102, + 14: 109, + 15: 116, + 16: 122 + } + +def trans_p(n): + try: + return _TransP[n] + except: + return 0 + +# table 11.2.9b.2.b +_TransQ = { + 0 : 0, + 1 : 9, + 2 : 17, + 3 : 25, + 4 : 32, + 5 : 39, + 6 : 46, + 7 : 53, + 8 : 59, + 9 : 65, + 10: 71, + 11: 77, + 12: 83, + 13: 89, + 14: 95, + 15: 101, + 16: 106, + 17: 111, + 18: 116, + 19: 121, + 20: 126 + } + +def trans_q(n): + try: + return _TransQ[n] + except: + return 0 + + # external references -from pycrate_csn1dir.e_utran_ipp_with_extended_earfcns_ie import e_utran_ipp_with_extended_earfcns_ie -from pycrate_csn1dir.e_utran_target_cell_with_extended_earfcn_ie import e_utran_target_cell_with_extended_earfcn_ie from pycrate_csn1dir.lsa_parameters_ie import lsa_parameters_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits -from pycrate_csn1dir.utran_tdd_target_cell_ie import utran_tdd_target_cell_ie from pycrate_csn1dir.utran_fdd_target_cell_ie import utran_fdd_target_cell_ie from pycrate_csn1dir.individual_priorities_ie import individual_priorities_ie +from pycrate_csn1dir.utran_tdd_target_cell_ie import utran_tdd_target_cell_ie +from pycrate_csn1dir.e_utran_ipp_with_extended_earfcns_ie import e_utran_ipp_with_extended_earfcns_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.e_utran_target_cell_ie import e_utran_target_cell_ie +from pycrate_csn1dir.e_utran_target_cell_with_extended_earfcn_ie import e_utran_target_cell_with_extended_earfcn_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -48,165 +107,17 @@ from pycrate_csn1dir.e_utran_target_cell_ie import e_utran_target_cell_ie from pycrate_csn1.csnobj import * +hcs_struct = CSN1List(name='hcs_struct', list=[ + CSN1Bit(name='priority_class', bit=3), + CSN1Bit(name='hcs_thr', bit=5)]) + repeated_utran_fdd_neighbour_cells_struct = CSN1List(name='repeated_utran_fdd_neighbour_cells_struct', list=[ CSN1Val(name='', val='0'), CSN1Bit(name='fdd_arfcn', bit=14), CSN1Bit(name='fdd_indic0'), CSN1Bit(name='nr_of_fdd_cells', bit=5), - CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) - -utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_fdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - -repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='tdd_arfcn', bit=14), - CSN1Bit(name='tdd_indic0'), - CSN1Bit(name='nr_of_tdd_cells', bit=5), - CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) - -utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_tdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - -si13_pbcch_location_struct = CSN1Alt(name='si13_pbcch_location_struct', alt={ - '0': ('', [ - CSN1Bit(name='si13_location')]), - '1': ('', [ - CSN1Bit(name='pbcch_location', bit=2), - CSN1Bit(name='psi1_repeat_period', bit=4)])}) - -gprs_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='gprs_3g_additional_measurement_parameters_description_2_struct', alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) - -ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) - -gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) - -gprs_3g_measurement_parameters_description_struct = CSN1List(name='gprs_3g_measurement_parameters_description_struct', list=[ - CSN1Bit(name='qsearch_p', bit=4), - CSN1Val(name='', val='1'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_rep_quant'), - CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_reporting_offset', bit=3), - CSN1Bit(name='fdd_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_reporting_offset', bit=3), - CSN1Bit(name='tdd_reporting_threshold', bit=3)])})]) - -hcs_struct = CSN1List(name='hcs_struct', list=[ - CSN1Bit(name='priority_class', bit=3), - CSN1Bit(name='hcs_thr', bit=5)]) - -cell_selection_struct = CSN1List(name='cell_selection_struct', list=[ - CSN1Bit(name='cell_bar_access_2'), - CSN1Bit(name='exc_acc'), - CSN1Bit(name='same_ra_as_serving_cell'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_rxlev_access_min', bit=6), - CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_temporary_offset', bit=3), - CSN1Bit(name='gprs_penalty_time', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_reselect_offset', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='hcs_params', obj=hcs_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13_pbcch_location', obj=si13_pbcch_location_struct)])})]) - -iu_mode_only_cell_selection_struct = CSN1List(name='iu_mode_only_cell_selection_struct', list=[ - CSN1Bit(name='cell_bar_qualify_3', bit=2), - CSN1Bit(name='same_ra_as_serving_cell'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_rxlev_access_min', bit=6), - CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_temporary_offset', bit=3), - CSN1Bit(name='gprs_penalty_time', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_reselect_offset', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='hcs_params', obj=hcs_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) - -add_frequency_list_struct = CSN1List(name='add_frequency_list_struct', list=[ - CSN1Bit(name='start_frequency', bit=10), - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])}), - CSN1Bit(name='nr_of_frequencies', bit=5), - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([3], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x)), - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])})])]) - -removed_3gcell_description_struct = CSN1List(name='removed_3gcell_description_struct', list=[ - CSN1Bit(name='n1', bit=2), - CSN1List(num=([0], lambda x: x + 1), list=[ - CSN1Bit(name='n2', bit=5), - CSN1List(num=([0], lambda x: x + 1), list=[ - CSN1Bit(name='removed_3gcell_index', bit=7), - CSN1Bit(name='_3g_cell_diff_length', bit=3), - CSN1Bit(name='_3gcell_diff', bit=([1], lambda x: x))])])]) + #CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) + CSN1Bit(name='fdd_cell_information_field', bit=([3], trans_p))]) gprs_measurement_parameters_description_struct = CSN1List(name='gprs_measurement_parameters_description_struct', list=[ CSN1Alt(alt={ @@ -244,6 +155,142 @@ gprs_measurement_parameters_description_struct = CSN1List(name='gprs_measurement CSN1Bit(name='_850_reporting_offset', bit=3), CSN1Bit(name='_850_reporting_threshold', bit=3)])})]) +utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_fdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) + +removed_3gcell_description_struct = CSN1List(name='removed_3gcell_description_struct', list=[ + CSN1Bit(name='n1', bit=2), + CSN1List(num=([0], lambda x: x + 1), list=[ + CSN1Bit(name='n2', bit=5), + CSN1List(num=([0], lambda x: x + 1), list=[ + CSN1Bit(name='removed_3gcell_index', bit=7), + CSN1Bit(name='_3g_cell_diff_length', bit=3), + CSN1Bit(name='_3gcell_diff', bit=([1], lambda x: x))])])]) + +repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='tdd_arfcn', bit=14), + CSN1Bit(name='tdd_indic0'), + CSN1Bit(name='nr_of_tdd_cells', bit=5), + #CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) + CSN1Bit(name='tdd_cell_information_field', bit=([3], trans_q))]) + +ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) + +gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) + +gprs_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='gprs_3g_additional_measurement_parameters_description_2_struct', alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) + +gprs_3g_measurement_parameters_description_struct = CSN1List(name='gprs_3g_measurement_parameters_description_struct', list=[ + CSN1Bit(name='qsearch_p', bit=4), + CSN1Val(name='', val='1'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_rep_quant'), + CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_reporting_offset', bit=3), + CSN1Bit(name='fdd_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_reporting_offset', bit=3), + CSN1Bit(name='tdd_reporting_threshold', bit=3)])})]) + +si13_pbcch_location_struct = CSN1Alt(name='si13_pbcch_location_struct', alt={ + '0': ('', [ + CSN1Bit(name='si13_location')]), + '1': ('', [ + CSN1Bit(name='pbcch_location', bit=2), + CSN1Bit(name='psi1_repeat_period', bit=4)])}) + +utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_tdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) + +iu_mode_only_cell_selection_struct = CSN1List(name='iu_mode_only_cell_selection_struct', list=[ + CSN1Bit(name='cell_bar_qualify_3', bit=2), + CSN1Bit(name='same_ra_as_serving_cell'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_rxlev_access_min', bit=6), + CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_temporary_offset', bit=3), + CSN1Bit(name='gprs_penalty_time', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_reselect_offset', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='hcs_params', obj=hcs_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) + +add_iu_mode_only_cell_list_struct = CSN1List(name='add_iu_mode_only_cell_list_struct', list=[ + CSN1Bit(name='start_frequency', bit=10), + CSN1Bit(name='bsic', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])}), + CSN1Bit(name='nr_of_frequencies', bit=5), + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([3], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x)), + CSN1Bit(name='bsic', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])})])]) + +iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', list=[ + CSN1Bit(name='cell_bar_qualify_3', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) + +nc_iu_mode_only_cell_list_struct = CSN1List(name='nc_iu_mode_only_cell_list_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='list_of_added_cells', obj=add_iu_mode_only_cell_list_struct)]), + CSN1Val(name='', val='0')]) + _3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -266,29 +313,32 @@ _3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_descri '1': ('', [ CSN1Ref(name='removed_3gcell_description', obj=removed_3gcell_description_struct)])})]) -iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', list=[ - CSN1Bit(name='cell_bar_qualify_3', bit=2), +cell_selection_struct = CSN1List(name='cell_selection_struct', list=[ + CSN1Bit(name='cell_bar_access_2'), + CSN1Bit(name='exc_acc'), + CSN1Bit(name='same_ra_as_serving_cell'), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) - -add_iu_mode_only_cell_list_struct = CSN1List(name='add_iu_mode_only_cell_list_struct', list=[ - CSN1Bit(name='start_frequency', bit=10), - CSN1Bit(name='bsic', bit=6), + CSN1Bit(name='gprs_rxlev_access_min', bit=6), + CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])}), - CSN1Bit(name='nr_of_frequencies', bit=5), - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([3], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x)), - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])})])]) + CSN1Bit(name='gprs_temporary_offset', bit=3), + CSN1Bit(name='gprs_penalty_time', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_reselect_offset', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='hcs_params', obj=hcs_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13_pbcch_location', obj=si13_pbcch_location_struct)])})]) enh_measurement_parameters_struct = CSN1List(name='enh_measurement_parameters_struct', list=[ CSN1Alt(alt={ @@ -329,6 +379,23 @@ iu_mode_neighbour_cell_params_struct = CSN1List(name='iu_mode_neighbour_cell_par '1': ('', [ CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])})]) +add_frequency_list_struct = CSN1List(name='add_frequency_list_struct', list=[ + CSN1Bit(name='start_frequency', bit=10), + CSN1Bit(name='bsic', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])}), + CSN1Bit(name='nr_of_frequencies', bit=5), + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([3], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x)), + CSN1Bit(name='bsic', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])})])]) + nc_frequency_list_struct = CSN1List(name='nc_frequency_list_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -353,12 +420,6 @@ nc_measurement_parameters_struct = CSN1List(name='nc_measurement_parameters_stru '1': ('', [ CSN1Ref(name='nc_frequency_list', obj=nc_frequency_list_struct)])})]) -nc_iu_mode_only_cell_list_struct = CSN1List(name='nc_iu_mode_only_cell_list_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='list_of_added_cells', obj=add_iu_mode_only_cell_list_struct)]), - CSN1Val(name='', val='0')]) - gsm_target_cell_struct = CSN1List(name='gsm_target_cell_struct', list=[ CSN1Bit(name='arfcn', bit=10), CSN1Bit(name='bsic', bit=6), diff --git a/pycrate_csn1dir/packet_channel_description.py b/pycrate_csn1dir/packet_channel_description.py index af123d7..6bf71d2 100644 --- a/pycrate_csn1dir/packet_channel_description.py +++ b/pycrate_csn1dir/packet_channel_description.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_channel_description.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_channel_request_11_bit_message_content.py b/pycrate_csn1dir/packet_channel_request_11_bit_message_content.py index f40f81c..cfac3dd 100644 --- a/pycrate_csn1dir/packet_channel_request_11_bit_message_content.py +++ b/pycrate_csn1dir/packet_channel_request_11_bit_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_channel_request_11_bit_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_control_acknowledgement_message_content.py b/pycrate_csn1dir/packet_control_acknowledgement_message_content.py index 5c93bb7..5e43841 100644 --- a/pycrate_csn1dir/packet_control_acknowledgement_message_content.py +++ b/pycrate_csn1dir/packet_control_acknowledgement_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_control_acknowledgement_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -40,20 +40,6 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -packet_control_acknowledgement_8_bit_message = CSN1List(name='packet_control_acknowledgement_8_bit_message', list=[ - CSN1Alt(alt={ - '000': ('message_type', [ - CSN1Bit(name='tn_rrbp', bit=3)]), - '011111': ('message_type', [])}), - CSN1Bit(name='ctrl_ack', bit=2)]) - -packet_control_acknowledgement_11_bit_message = CSN1List(name='packet_control_acknowledgement_11_bit_message', list=[ - CSN1Alt(alt={ - '110111': ('message_type', [ - CSN1Bit(name='tn_rrbp', bit=3)]), - '111111001': ('message_type', [])}), - CSN1Bit(name='ctrl_ack', bit=2)]) - packet_control_acknowledgement_message_content = CSN1List(name='packet_control_acknowledgement_message_content', list=[ CSN1Bit(name='tlli_g_rnti', bit=32), CSN1Bit(name='ctrl_ack', bit=2), @@ -81,3 +67,17 @@ packet_control_acknowledgement_message_content = CSN1List(name='packet_control_a None: ('', [])})]), None: ('', [])})]) +packet_control_acknowledgement_11_bit_message = CSN1List(name='packet_control_acknowledgement_11_bit_message', list=[ + CSN1Alt(alt={ + '110111': ('message_type', [ + CSN1Bit(name='tn_rrbp', bit=3)]), + '111111001': ('message_type', [])}), + CSN1Bit(name='ctrl_ack', bit=2)]) + +packet_control_acknowledgement_8_bit_message = CSN1List(name='packet_control_acknowledgement_8_bit_message', list=[ + CSN1Alt(alt={ + '000': ('message_type', [ + CSN1Bit(name='tn_rrbp', bit=3)]), + '011111': ('message_type', [])}), + CSN1Bit(name='ctrl_ack', bit=2)]) + diff --git a/pycrate_csn1dir/packet_cs_command_message_content.py b/pycrate_csn1dir/packet_cs_command_message_content.py index fae7aed..98c977a 100644 --- a/pycrate_csn1dir/packet_cs_command_message_content.py +++ b/pycrate_csn1dir/packet_cs_command_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_cs_command_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet CS Command message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_cs_release_message_content.py b/pycrate_csn1dir/packet_cs_release_message_content.py index 05c78d3..61aeb19 100644 --- a/pycrate_csn1dir/packet_cs_release_message_content.py +++ b/pycrate_csn1dir/packet_cs_release_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_cs_release_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,14 +31,14 @@ # top-level object: Packet CS Release message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie +from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie from pycrate_csn1dir.egprs_mode_2_ie import egprs_mode_2_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie -from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -47,52 +47,6 @@ from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_fr from pycrate_csn1.csnobj import * -rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Bit(name='rlc_mode'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='pfi', bit=7)]) - -assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ - CSN1Bit(name='assignment_type', bit=2), - CSN1Bit(name='carrier_id')]) - -uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='pfi', bit=7)])}), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='channel_coding_command', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='uplink_egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='usf_granularity'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='usf_allocation', bit=3)]), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3), - CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3)])})])})]) - downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -110,14 +64,19 @@ downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', '1': ('', [ CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) -additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ +rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ CSN1Bit(name='tfi_assignment', bit=5), + CSN1Bit(name='rlc_mode'), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), CSN1Bit(name='pfi', bit=7)]) +assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ + CSN1Bit(name='assignment_type', bit=2), + CSN1Bit(name='carrier_id')]) + timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ '0': ('', [ CSN1Bit(name='ms_timeslot_allocation', bit=8)]), @@ -167,6 +126,47 @@ multiple_downlink_assignment_struct = CSN1List(name='multiple_downlink_assignmen CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]), CSN1Val(name='', val='0')]) +uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='pfi', bit=7)])}), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='channel_coding_command', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='uplink_egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='usf_granularity'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='usf_allocation', bit=3)]), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3), + CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3)])})])})]) + +additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Bit(name='pfi', bit=7)]) + multiple_uplink_assignment_struct = CSN1List(name='multiple_uplink_assignment_struct', list=[ CSN1Bit(name='extended_dynamic_allocation'), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/packet_cs_request_message_content.py b/pycrate_csn1dir/packet_cs_request_message_content.py index 76639b8..e5d7dbc 100644 --- a/pycrate_csn1dir/packet_cs_request_message_content.py +++ b/pycrate_csn1dir/packet_cs_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_cs_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet CS Request message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_dbpsch_assignment_message_content.py b/pycrate_csn1dir/packet_dbpsch_assignment_message_content.py index 9d05f94..adae0c2 100644 --- a/pycrate_csn1dir/packet_dbpsch_assignment_message_content.py +++ b/pycrate_csn1dir/packet_dbpsch_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_dbpsch_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,8 +32,8 @@ # external references from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -46,10 +46,6 @@ response_time_sacch_struct = CSN1List(name='response_time_sacch_struct', list=[ CSN1Bit(name='trmin_sacch'), CSN1Bit(name='tresp_sacch')]) -response_time_sdcch_struct = CSN1List(name='response_time_sdcch_struct', list=[ - CSN1Bit(name='trmin_sdcch'), - CSN1Bit(name='tresp_sdcch')]) - power_command_struct = CSN1List(name='power_command_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -87,6 +83,10 @@ channel_description_struct = CSN1List(name='channel_description_struct', list=[ '1': ('', [ CSN1Bit(name='arfcn', bit=10)])})]) +response_time_sdcch_struct = CSN1List(name='response_time_sdcch_struct', list=[ + CSN1Bit(name='trmin_sdcch'), + CSN1Bit(name='tresp_sdcch')]) + network_response_times_struct = CSN1Alt(name='network_response_times_struct', alt={ '0': ('', [ CSN1Ref(name='response_time_sdcch', obj=response_time_sdcch_struct)]), diff --git a/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_message.py b/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_message.py index 481de26..f8fbce7 100644 --- a/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_message.py +++ b/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_message.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_message.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_type_2_message.py b/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_type_2_message.py index 3944423..f2f77be 100644 --- a/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_type_2_message.py +++ b/pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_type_2_message.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_dbpsch_downlink_ack_nack_type_2_message.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: Packet DBPSCH Downlink Ack/Nack Type 2 message # external references -from pycrate_csn1dir.flo_ack_nack_description_ie import flo_ack_nack_description_ie -from pycrate_csn1dir.egprs_channel_quality_report_ie import egprs_channel_quality_report_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.egprs_channel_quality_report_ie import egprs_channel_quality_report_ie +from pycrate_csn1dir.flo_ack_nack_description_ie import flo_ack_nack_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_message_content.py b/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_message_content.py index 1d02798..3a7b754 100644 --- a/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_message_content.py +++ b/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_type_2_message_content.py b/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_type_2_message_content.py index 3a58e42..16f0883 100644 --- a/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_type_2_message_content.py +++ b/pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_type_2_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_dbpsch_uplink_ack_nack_type_2_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet DBPSCH Uplink Ack/Nack Type 2 message content # external references -from pycrate_csn1dir.flo_ack_nack_description_ie import flo_ack_nack_description_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.flo_ack_nack_description_ie import flo_ack_nack_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_downlink_ack_nack_message_content.py b/pycrate_csn1dir/packet_downlink_ack_nack_message_content.py index 2908f62..c02ae86 100644 --- a/pycrate_csn1dir/packet_downlink_ack_nack_message_content.py +++ b/pycrate_csn1dir/packet_downlink_ack_nack_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_downlink_ack_nack_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,11 +31,11 @@ # top-level object: Packet Downlink Ack/Nack message content # external references +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.iu_mode_channel_request_description_ie import extended_channel_request_description_ie +from pycrate_csn1dir.iu_mode_channel_request_description_ie import iu_mode_channel_request_description_ie from pycrate_csn1dir.channel_request_description_ie import channel_request_description_ie from pycrate_csn1dir.ack_nack_description_ie import ack_nack_description_ie -from pycrate_csn1dir.iu_mode_channel_request_description_ie import iu_mode_channel_request_description_ie -from pycrate_csn1dir.iu_mode_channel_request_description_ie import extended_channel_request_description_ie -from pycrate_csn1dir.padding_bits import padding_bits # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_downlink_assignment_message_content.py b/pycrate_csn1dir/packet_downlink_assignment_message_content.py index 3fef955..974debf 100644 --- a/pycrate_csn1dir/packet_downlink_assignment_message_content.py +++ b/pycrate_csn1dir/packet_downlink_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_downlink_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,16 +32,16 @@ # external references from pycrate_csn1dir.pulse_format_ie import dlmc_frequency_parameters_ie -from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.compact_reduced_ma_ie import compact_reduced_ma_ie -from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie from pycrate_csn1dir.padding_bits import padding_bits -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie -from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie +from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie +from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie +from pycrate_csn1dir.compact_reduced_ma_ie import compact_reduced_ma_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -59,6 +59,10 @@ rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), CSN1Bit(name='pfi', bit=7)]) +assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ + CSN1Bit(name='assignment_type', bit=2), + CSN1Bit(name='carrier_id')]) + additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ CSN1Bit(name='downlink_tfi_assignment', bit=5), CSN1Alt(alt={ @@ -67,10 +71,6 @@ additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ CSN1Bit(name='npm_transfer_time', bit=5)])}), CSN1Bit(name='pfi', bit=7)]) -assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ - CSN1Bit(name='assignment_type', bit=2), - CSN1Bit(name='carrier_id')]) - carrier_specific_info_struct = CSN1Alt(name='carrier_specific_info_struct', alt={ '00': ('', []), '01': ('', []), diff --git a/pycrate_csn1dir/packet_downlink_dummy_control_block_message_content.py b/pycrate_csn1dir/packet_downlink_dummy_control_block_message_content.py index 1a6545d..7fab69a 100644 --- a/pycrate_csn1dir/packet_downlink_dummy_control_block_message_content.py +++ b/pycrate_csn1dir/packet_downlink_dummy_control_block_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_downlink_dummy_control_block_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_enhanced_measurement_report_message_content.py b/pycrate_csn1dir/packet_enhanced_measurement_report_message_content.py index 530df80..8aa4370 100644 --- a/pycrate_csn1dir/packet_enhanced_measurement_report_message_content.py +++ b/pycrate_csn1dir/packet_enhanced_measurement_report_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_enhanced_measurement_report_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: PACKET ENHANCED MEASUREMENT REPORT message content # external references -from pycrate_csn1dir.e_utran_csg_measurement_report_ie import e_utran_csg_measurement_report_ie -from pycrate_csn1dir.utran_csg_measurement_report_ie import utran_csg_measurement_report_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.utran_csg_measurement_report_ie import utran_csg_measurement_report_ie +from pycrate_csn1dir.e_utran_csg_measurement_report_ie import e_utran_csg_measurement_report_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -42,10 +42,6 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -serving_cell_data_struct = CSN1List(name='serving_cell_data_struct', list=[ - CSN1Bit(name='rxlev_serving_cell', bit=6), - CSN1Val(name='', val='0')]) - e_utran_measurement_report_struct = CSN1List(name='e_utran_measurement_report_struct', list=[ CSN1Bit(name='n_e_utran', bit=2), CSN1List(num=([0], lambda x: x + 1), list=[ @@ -58,6 +54,10 @@ repeated_invalid_bsic_information_struct = CSN1List(name='repeated_invalid_bsic_ CSN1Bit(name='bsic', bit=6), CSN1Bit(name='rxlev_ncell', bit=6)]) +serving_cell_data_struct = CSN1List(name='serving_cell_data_struct', list=[ + CSN1Bit(name='rxlev_serving_cell', bit=6), + CSN1Val(name='', val='0')]) + nc_measurement_report_struct = CSN1List(name='nc_measurement_report_struct', list=[ CSN1Bit(name='nc_mode'), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/packet_mbms_announcement_message_content.py b/pycrate_csn1dir/packet_mbms_announcement_message_content.py index 71e6c1b..726d36f 100644 --- a/pycrate_csn1dir/packet_mbms_announcement_message_content.py +++ b/pycrate_csn1dir/packet_mbms_announcement_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_mbms_announcement_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,11 +31,11 @@ # top-level object: PACKET MBMS ANNOUNCEMENT message content # external references -from pycrate_csn1dir.tmgi_ie import tmgi_ie -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.mprach_control_parameters_ie import mprach_control_parameters_ie from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.tmgi_ie import tmgi_ie +from pycrate_csn1dir.mprach_control_parameters_ie import mprach_control_parameters_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_measurement_order_message_content.py b/pycrate_csn1dir/packet_measurement_order_message_content.py index 0649cae..02e1949 100644 --- a/pycrate_csn1dir/packet_measurement_order_message_content.py +++ b/pycrate_csn1dir/packet_measurement_order_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_measurement_order_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,20 +30,79 @@ # section: 11.2.9b Packet Measurement Order # top-level object: Packet Measurement Order message content +# table 11.2.9b.2.a +_TransP = { + 0 : 0, + 1 : 10, + 2 : 19, + 3 : 28, + 4 : 36, + 5 : 44, + 6 : 52, + 7 : 60, + 8 : 67, + 9 : 74, + 10: 81, + 11: 88, + 12: 95, + 13: 102, + 14: 109, + 15: 116, + 16: 122 + } + +def trans_p(n): + try: + return _TransP[n] + except: + return 0 + +# table 11.2.9b.2.b +_TransQ = { + 0 : 0, + 1 : 9, + 2 : 17, + 3 : 25, + 4 : 32, + 5 : 39, + 6 : 46, + 7 : 53, + 8 : 59, + 9 : 65, + 10: 71, + 11: 77, + 12: 83, + 13: 89, + 14: 95, + 15: 101, + 16: 106, + 17: 111, + 18: 116, + 19: 121, + 20: 126 + } + +def trans_q(n): + try: + return _TransQ[n] + except: + return 0 + + # external references -from pycrate_csn1dir.e_utran_nc_with_extended_earfcns_ie import e_utran_nc_with_extended_earfcns_ie -from pycrate_csn1dir.e_utran_ipp_with_extended_earfcns_ie import e_utran_ipp_with_extended_earfcns_ie from pycrate_csn1dir.lsa_parameters_ie import lsa_parameters_ie -from pycrate_csn1dir.gsm_priority_parameters_ie import gsm_priority_parameters_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.e_utran_csg_description_ie import e_utran_csg_description_ie from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir._3g_priority_parameters_ie import _3g_priority_parameters_ie -from pycrate_csn1dir.enhanced_cell_reselection_parameters_ie import enhanced_cell_reselection_parameters_ie -from pycrate_csn1dir.e_utran_parameters_ie import e_utran_parameters_ie -from pycrate_csn1dir.measurement_control_parameters_description import measurement_control_parameters_description -from pycrate_csn1dir._3g_csg_description_ie import _3g_csg_description_ie +from pycrate_csn1dir.e_utran_csg_description_ie import e_utran_csg_description_ie from pycrate_csn1dir.individual_priorities_ie import individual_priorities_ie +from pycrate_csn1dir.measurement_control_parameters_description import measurement_control_parameters_description +from pycrate_csn1dir.e_utran_ipp_with_extended_earfcns_ie import e_utran_ipp_with_extended_earfcns_ie +from pycrate_csn1dir.gsm_priority_parameters_ie import gsm_priority_parameters_ie +from pycrate_csn1dir.enhanced_cell_reselection_parameters_ie import enhanced_cell_reselection_parameters_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie +from pycrate_csn1dir.e_utran_parameters_ie import e_utran_parameters_ie +from pycrate_csn1dir.e_utran_nc_with_extended_earfcns_ie import e_utran_nc_with_extended_earfcns_ie +from pycrate_csn1dir._3g_csg_description_ie import _3g_csg_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -52,49 +111,73 @@ from pycrate_csn1dir.individual_priorities_ie import individual_priorities_ie from pycrate_csn1.csnobj import * -si13_pbcch_location_struct = CSN1Alt(name='si13_pbcch_location_struct', alt={ - '0': ('', [ - CSN1Bit(name='si13_location')]), - '1': ('', [ - CSN1Bit(name='pbcch_location', bit=2), - CSN1Bit(name='psi1_repeat_period', bit=4)])}) - -repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ - CSN1Bit(name='tdd_indic0'), - CSN1Val(name='', val='0'), - CSN1Bit(name='tdd_arfcn', bit=14), - CSN1Bit(name='nr_of_tdd_cells', bit=5), - CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) - -utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ +priority_and_e_utran_parameters_description_struct = CSN1List(name='priority_and_e_utran_parameters_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='bandwidth_tdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - -gprs_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='gprs_3g_additional_measurement_parameters_description_2_struct', alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) - -ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) + CSN1Ref(name='serving_cell_priority_parameters_description', obj=gsm_priority_parameters_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='_3g_priority_parameters_description', obj=_3g_priority_parameters_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='e_utran_parameters_description', obj=e_utran_parameters_ie)])})]) repeated_utran_fdd_neighbour_cells_struct = CSN1List(name='repeated_utran_fdd_neighbour_cells_struct', list=[ CSN1Val(name='', val='0'), CSN1Bit(name='fdd_arfcn', bit=14), CSN1Bit(name='fdd_indic0'), CSN1Bit(name='nr_of_fdd_cells', bit=5), - CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) + #CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) + CSN1Bit(name='fdd_cell_information_field', bit=([3], trans_p))]) -gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) +gprs_measurement_parameters_description_struct = CSN1List(name='gprs_measurement_parameters_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='multiband_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='serving_band_reporting', bit=2)])}), + CSN1Bit(name='scale_ord', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_900_reporting_offset', bit=3), + CSN1Bit(name='_900_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_1800_reporting_offset', bit=3), + CSN1Bit(name='_1800_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_400_reporting_offset', bit=3), + CSN1Bit(name='_400_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_1900_reporting_offset', bit=3), + CSN1Bit(name='_1900_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='_850_reporting_offset', bit=3), + CSN1Bit(name='_850_reporting_threshold', bit=3)])})]) + +utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_fdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) e_utran_csg_cells_reporting_description_struct = CSN1List(name='e_utran_csg_cells_reporting_description_struct', list=[ CSN1Alt(alt={ @@ -108,10 +191,42 @@ e_utran_csg_cells_reporting_description_struct = CSN1List(name='e_utran_csg_cell CSN1Bit(name='e_utran_csg_tdd_reporting_threshold', bit=3), CSN1Bit(name='e_utran_csg_tdd_reporting_threshold_2', bit=6)])})]) +removed_3gcell_description_struct = CSN1List(name='removed_3gcell_description_struct', list=[ + CSN1Bit(name='n1', bit=2), + CSN1List(num=([0], lambda x: x + 1), list=[ + CSN1Bit(name='n2', bit=5), + CSN1List(num=([0], lambda x: x + 1), list=[ + CSN1Bit(name='removed_3gcell_index', bit=7), + CSN1Bit(name='_3g_cell_diff_length', bit=3), + CSN1Bit(name='_3gcell_diff', bit=([1], lambda x: x))])])]) + +si13_pbcch_location_struct = CSN1Alt(name='si13_pbcch_location_struct', alt={ + '0': ('', [ + CSN1Bit(name='si13_location')]), + '1': ('', [ + CSN1Bit(name='pbcch_location', bit=2), + CSN1Bit(name='psi1_repeat_period', bit=4)])}) + +repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ + CSN1Bit(name='tdd_indic0'), + CSN1Val(name='', val='0'), + CSN1Bit(name='tdd_arfcn', bit=14), + CSN1Bit(name='nr_of_tdd_cells', bit=5), + #CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) + CSN1Bit(name='tdd_cell_information_field', bit=([3], trans_q))]) + hcs_struct = CSN1List(name='hcs_struct', list=[ CSN1Bit(name='priority_class', bit=3), CSN1Bit(name='hcs_thr', bit=5)]) +ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) + +gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) + cell_selection_struct = CSN1List(name='cell_selection_struct', list=[ CSN1Bit(name='cell_bar_access_2'), CSN1Bit(name='exc_acc'), @@ -139,6 +254,22 @@ cell_selection_struct = CSN1List(name='cell_selection_struct', list=[ '1': ('', [ CSN1Ref(name='si13_pbcch_location', obj=si13_pbcch_location_struct)])})]) +utran_csg_cells_reporting_description_struct = CSN1List(name='utran_csg_cells_reporting_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_csg_fdd_reporting_threshold', bit=3), + CSN1Bit(name='utran_csg_fdd_reporting_threshold_2', bit=6)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_csg_tdd_reporting_threshold', bit=3)])})]) + +gprs_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='gprs_3g_additional_measurement_parameters_description_2_struct', alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) + gprs_3g_measurement_parameters_bis_description_struct = CSN1List(name='gprs_3g_measurement_parameters_bis_description_struct', list=[ CSN1Bit(name='qsearch_p', bit=4), CSN1Val(name='', val='1'), @@ -171,62 +302,15 @@ gprs_3g_measurement_parameters_bis_description_struct = CSN1List(name='gprs_3g_m CSN1Bit(name='cdma2000_reporting_offset', bit=3), CSN1Bit(name='cdma2000_reporting_threshold', bit=3)])})]) -iu_mode_only_cell_selection_struct = CSN1List(name='iu_mode_only_cell_selection_struct', list=[ - CSN1Bit(name='cell_bar_qualify_3', bit=2), - CSN1Bit(name='same_ra_as_serving_cell'), +utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='gprs_rxlev_access_min', bit=6), - CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_temporary_offset', bit=3), - CSN1Bit(name='gprs_penalty_time', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_reselect_offset', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='hcs_params', obj=hcs_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) - -priority_and_e_utran_parameters_description_struct = CSN1List(name='priority_and_e_utran_parameters_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='serving_cell_priority_parameters_description', obj=gsm_priority_parameters_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='_3g_priority_parameters_description', obj=_3g_priority_parameters_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='e_utran_parameters_description', obj=e_utran_parameters_ie)])})]) - -add_frequency_list_struct = CSN1List(name='add_frequency_list_struct', list=[ - CSN1Bit(name='start_frequency', bit=10), - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])}), - CSN1Bit(name='nr_of_frequencies', bit=5), - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([3], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x + 1)), - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])})])]) + CSN1Bit(name='bandwidth_tdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) cdma_2000_description_struct = CSN1List(name='cdma_2000_description_struct', list=[ CSN1Bit(name='cdma2000_frequency_band', bit=5), @@ -280,61 +364,65 @@ cdma_2000_description_struct = CSN1List(name='cdma_2000_description_struct', lis CSN1Bit(name='walsh_length2', bit=3), CSN1Bit(name='aux_pilot_walsh2', bit=([2], lambda x: x + 6))])})])])})])})])]) -removed_3gcell_description_struct = CSN1List(name='removed_3gcell_description_struct', list=[ - CSN1Bit(name='n1', bit=2), - CSN1List(num=([0], lambda x: x + 1), list=[ - CSN1Bit(name='n2', bit=5), - CSN1List(num=([0], lambda x: x + 1), list=[ - CSN1Bit(name='removed_3gcell_index', bit=7), - CSN1Bit(name='_3g_cell_diff_length', bit=3), - CSN1Bit(name='_3gcell_diff', bit=([1], lambda x: x))])])]) +iu_mode_only_cell_selection_struct = CSN1List(name='iu_mode_only_cell_selection_struct', list=[ + CSN1Bit(name='cell_bar_qualify_3', bit=2), + CSN1Bit(name='same_ra_as_serving_cell'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_rxlev_access_min', bit=6), + CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_temporary_offset', bit=3), + CSN1Bit(name='gprs_penalty_time', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_reselect_offset', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='hcs_params', obj=hcs_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) -gprs_measurement_parameters_description_struct = CSN1List(name='gprs_measurement_parameters_description_struct', list=[ +add_frequency_list_struct = CSN1List(name='add_frequency_list_struct', list=[ + CSN1Bit(name='start_frequency', bit=10), + CSN1Bit(name='bsic', bit=6), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='multiband_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='serving_band_reporting', bit=2)])}), - CSN1Bit(name='scale_ord', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_900_reporting_offset', bit=3), - CSN1Bit(name='_900_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_1800_reporting_offset', bit=3), - CSN1Bit(name='_1800_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_400_reporting_offset', bit=3), - CSN1Bit(name='_400_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_1900_reporting_offset', bit=3), - CSN1Bit(name='_1900_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='_850_reporting_offset', bit=3), - CSN1Bit(name='_850_reporting_threshold', bit=3)])})]) + CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])}), + CSN1Bit(name='nr_of_frequencies', bit=5), + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([3], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x + 1)), + CSN1Bit(name='bsic', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])})])]) -utran_csg_cells_reporting_description_struct = CSN1List(name='utran_csg_cells_reporting_description_struct', list=[ +add_iu_mode_only_cell_list_struct = CSN1List(name='add_iu_mode_only_cell_list_struct', list=[ + CSN1Bit(name='start_frequency', bit=10), + CSN1Bit(name='bsic', bit=6), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='utran_csg_fdd_reporting_threshold', bit=3), - CSN1Bit(name='utran_csg_fdd_reporting_threshold_2', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='utran_csg_tdd_reporting_threshold', bit=3)])})]) + CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])}), + CSN1Bit(name='nr_of_frequencies', bit=5), + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([3], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x)), + CSN1Bit(name='bsic', bit=6), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])})])]) iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', list=[ CSN1Bit(name='cell_bar_qualify_3', bit=2), @@ -343,16 +431,6 @@ iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', l '1': ('', [ CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) -utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_fdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - csg_cells_reporting_description_struct = CSN1List(name='csg_cells_reporting_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -363,6 +441,12 @@ csg_cells_reporting_description_struct = CSN1List(name='csg_cells_reporting_desc '1': ('', [ CSN1Ref(name='e_utran_csg_cells_reporting_description', obj=e_utran_csg_cells_reporting_description_struct)])})]) +nc_iu_mode_only_cell_list_struct = CSN1List(name='nc_iu_mode_only_cell_list_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='list_of_added_cells', obj=add_iu_mode_only_cell_list_struct)]), + CSN1Val(name='', val='0')]) + _3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -389,23 +473,6 @@ _3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_descri '1': ('', [ CSN1Ref(name='removed_3gcell_description', obj=removed_3gcell_description_struct)])})]) -add_iu_mode_only_cell_list_struct = CSN1List(name='add_iu_mode_only_cell_list_struct', list=[ - CSN1Bit(name='start_frequency', bit=10), - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])}), - CSN1Bit(name='nr_of_frequencies', bit=5), - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([3], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 4], lambda x: x)), - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='cell_selection_params', obj=iu_mode_only_cell_selection_struct)])})])]) - enh_measurement_parameters_struct = CSN1List(name='enh_measurement_parameters_struct', list=[ CSN1Alt(alt={ '0': ('', [ @@ -434,17 +501,6 @@ enh_measurement_parameters_struct = CSN1List(name='enh_measurement_parameters_st '1': ('', [ CSN1Ref(name='gprs_3g_measurement_parameters_description', obj=gprs_3g_measurement_parameters_bis_description_struct)])})]) -iu_mode_neighbour_cell_params_struct = CSN1List(name='iu_mode_neighbour_cell_params_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])}), - CSN1Bit(name='nr_of_frequencies', bit=5), - CSN1Alt(num=([1], lambda x: x), alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])})]) - nc_frequency_list_struct = CSN1List(name='nc_frequency_list_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -457,6 +513,17 @@ nc_frequency_list_struct = CSN1List(name='nc_frequency_list_struct', list=[ CSN1Ref(name='list_of_added_frequency_struct', obj=add_frequency_list_struct)]), CSN1Val(name='', val='0')]) +iu_mode_neighbour_cell_params_struct = CSN1List(name='iu_mode_neighbour_cell_params_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])}), + CSN1Bit(name='nr_of_frequencies', bit=5), + CSN1Alt(num=([1], lambda x: x), alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])})]) + nc_measurement_parameters_struct = CSN1List(name='nc_measurement_parameters_struct', list=[ CSN1Bit(name='network_control_order', bit=2), CSN1Alt(alt={ @@ -470,12 +537,6 @@ nc_measurement_parameters_struct = CSN1List(name='nc_measurement_parameters_stru '1': ('', [ CSN1Ref(name='nc_frequency_list', obj=nc_frequency_list_struct)])})]) -nc_iu_mode_only_cell_list_struct = CSN1List(name='nc_iu_mode_only_cell_list_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='list_of_added_cells', obj=add_iu_mode_only_cell_list_struct)]), - CSN1Val(name='', val='0')]) - packet_measurement_order_message_content = CSN1List(name='packet_measurement_order_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1List(list=[ diff --git a/pycrate_csn1dir/packet_measurement_report_message_content.py b/pycrate_csn1dir/packet_measurement_report_message_content.py index fbb1d8b..a126969 100644 --- a/pycrate_csn1dir/packet_measurement_report_message_content.py +++ b/pycrate_csn1dir/packet_measurement_report_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_measurement_report_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: Packet Measurement Report message content # external references -from pycrate_csn1dir.e_utran_csg_measurement_report_ie import e_utran_csg_measurement_report_ie -from pycrate_csn1dir.utran_csg_measurement_report_ie import utran_csg_measurement_report_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.utran_csg_measurement_report_ie import utran_csg_measurement_report_ie +from pycrate_csn1dir.e_utran_csg_measurement_report_ie import e_utran_csg_measurement_report_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_mobile_tbf_status_message_content.py b/pycrate_csn1dir/packet_mobile_tbf_status_message_content.py index 7aa137f..f3357af 100644 --- a/pycrate_csn1dir/packet_mobile_tbf_status_message_content.py +++ b/pycrate_csn1dir/packet_mobile_tbf_status_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_mobile_tbf_status_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet Mobile TBF Status message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_neighbour_cell_data_message_content.py b/pycrate_csn1dir/packet_neighbour_cell_data_message_content.py index 1770747..b21363c 100644 --- a/pycrate_csn1dir/packet_neighbour_cell_data_message_content.py +++ b/pycrate_csn1dir/packet_neighbour_cell_data_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_neighbour_cell_data_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet Neighbour Cell Data message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_paging_request_message_content.py b/pycrate_csn1dir/packet_paging_request_message_content.py index 6a9fcf1..3988e96 100644 --- a/pycrate_csn1dir/packet_paging_request_message_content.py +++ b/pycrate_csn1dir/packet_paging_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_paging_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,8 +32,8 @@ # external references from pycrate_csn1dir.mbms_sessions_list_ie import mbms_sessions_list_ie -from pycrate_csn1dir.mbms_channel_parameters_ie import mbms_channel_parameters_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.mbms_channel_parameters_ie import mbms_channel_parameters_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -52,22 +52,6 @@ etws_primary_notification_struct = CSN1List(name='etws_primary_notification_stru CSN1Bit(name='length_of_segment', bit=7), CSN1Bit(name='etws_primary_notification_data', bit=([2], lambda x: x))]) -mbms_information = CSN1List(name='mbms_information', list=[ - CSN1Ref(name='mbms_sessions_list', obj=mbms_sessions_list_ie), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='mbms_channel_parameters', obj=mbms_channel_parameters_ie), - CSN1Ref(name='mbms_sessions_list', obj=mbms_sessions_list_ie)]), - CSN1Val(name='', val='0')]) - -page_info_struct = CSN1List(name='page_info_struct', list=[ - CSN1Bit(name='paging_cause', bit=3), - CSN1Bit(name='cn_domain_identity', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='paging_record_type_identifier', bit=2)])})]) - repeated_page_info_struct = CSN1Alt(name='repeated_page_info_struct', alt={ '0': ('', [ CSN1Alt(alt={ @@ -89,6 +73,22 @@ repeated_page_info_struct = CSN1Alt(name='repeated_page_info_struct', alt={ '1': ('', [ CSN1Bit(name='emlpp_priority', bit=3)])})])}) +mbms_information = CSN1List(name='mbms_information', list=[ + CSN1Ref(name='mbms_sessions_list', obj=mbms_sessions_list_ie), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='mbms_channel_parameters', obj=mbms_channel_parameters_ie), + CSN1Ref(name='mbms_sessions_list', obj=mbms_sessions_list_ie)]), + CSN1Val(name='', val='0')]) + +page_info_struct = CSN1List(name='page_info_struct', list=[ + CSN1Bit(name='paging_cause', bit=3), + CSN1Bit(name='cn_domain_identity', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='paging_record_type_identifier', bit=2)])})]) + repeated_iu_page_info_struct = CSN1Alt(name='repeated_iu_page_info_struct', alt={ '0': ('', [ CSN1Bit(name='g_rnti', bit=32)]), diff --git a/pycrate_csn1dir/packet_pause_message_content.py b/pycrate_csn1dir/packet_pause_message_content.py index 61706ac..4e5c6e4 100644 --- a/pycrate_csn1dir/packet_pause_message_content.py +++ b/pycrate_csn1dir/packet_pause_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_pause_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_pdch_release_message_content.py b/pycrate_csn1dir/packet_pdch_release_message_content.py index da00495..c5d1cfd 100644 --- a/pycrate_csn1dir/packet_pdch_release_message_content.py +++ b/pycrate_csn1dir/packet_pdch_release_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_pdch_release_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_physical_information_message_content.py b/pycrate_csn1dir/packet_physical_information_message_content.py index 75a3927..536bc32 100644 --- a/pycrate_csn1dir/packet_physical_information_message_content.py +++ b/pycrate_csn1dir/packet_physical_information_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_physical_information_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet Physical information message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_polling_request_message_content.py b/pycrate_csn1dir/packet_polling_request_message_content.py index cdc01a3..084190f 100644 --- a/pycrate_csn1dir/packet_polling_request_message_content.py +++ b/pycrate_csn1dir/packet_polling_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_polling_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet Polling Request message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_power_control_timing_advance_message_content.py b/pycrate_csn1dir/packet_power_control_timing_advance_message_content.py index 60360f0..9155600 100644 --- a/pycrate_csn1dir/packet_power_control_timing_advance_message_content.py +++ b/pycrate_csn1dir/packet_power_control_timing_advance_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_power_control_timing_advance_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: Packet Power Control/Timing Advance message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie -from pycrate_csn1dir.global_power_control_parameters_ie import global_power_control_parameters_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_power_control_parameters_ie import global_power_control_parameters_ie +from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/packet_prach_parameters_message_content.py b/pycrate_csn1dir/packet_prach_parameters_message_content.py index 68d1cac..d053c53 100644 --- a/pycrate_csn1dir/packet_prach_parameters_message_content.py +++ b/pycrate_csn1dir/packet_prach_parameters_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_prach_parameters_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_psi_status_message_content.py b/pycrate_csn1dir/packet_psi_status_message_content.py index 353f769..a4e0d34 100644 --- a/pycrate_csn1dir/packet_psi_status_message_content.py +++ b/pycrate_csn1dir/packet_psi_status_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_psi_status_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet PSI Status message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_queueing_notification_message_content.py b/pycrate_csn1dir/packet_queueing_notification_message_content.py index 54c1028..12799de 100644 --- a/pycrate_csn1dir/packet_queueing_notification_message_content.py +++ b/pycrate_csn1dir/packet_queueing_notification_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_queueing_notification_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet Queueing Notification message content # external references -from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_request_reference_ie.py b/pycrate_csn1dir/packet_request_reference_ie.py index 68c3ded..edda0a7 100644 --- a/pycrate_csn1dir/packet_request_reference_ie.py +++ b/pycrate_csn1dir/packet_request_reference_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_request_reference_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_resource_request_message_content.py b/pycrate_csn1dir/packet_resource_request_message_content.py index d93e51e..12b4af1 100644 --- a/pycrate_csn1dir/packet_resource_request_message_content.py +++ b/pycrate_csn1dir/packet_resource_request_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_resource_request_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,16 +31,16 @@ # top-level object: Packet Resource Request message content # external references -from pycrate_csn1dir.egprs_bep_link_quality_measurements_ie import egprs_bep_link_quality_measurements_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.egprs_timeslot_link_quality_measurements_ie import egprs_timeslot_link_quality_measurements_ie -from pycrate_csn1dir.egprs_bep_link_quality_measurements_type_2_ie import egprs_bep_link_quality_measurements_type_2_ie -from pycrate_csn1dir.ms_radio_access_capability_2_ie import ms_radio_access_capability_2_ie -from pycrate_csn1dir.iu_mode_channel_request_description_ie import extended_channel_request_description_ie -from pycrate_csn1dir.channel_request_description_ie import channel_request_description_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.channel_request_description_ie import channel_request_description_ie +from pycrate_csn1dir.egprs_timeslot_link_quality_measurements_ie import egprs_timeslot_link_quality_measurements_ie from pycrate_csn1dir.tlli_g_rnti_ie import tlli_g_rnti_ie +from pycrate_csn1dir.egprs_bep_link_quality_measurements_type_2_ie import egprs_bep_link_quality_measurements_type_2_ie +from pycrate_csn1dir.iu_mode_channel_request_description_ie import extended_channel_request_description_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.egprs_timeslot_link_quality_measurements_type_2_ie import egprs_timeslot_link_quality_measurements_type_2_ie +from pycrate_csn1dir.ms_radio_access_capability_2_ie import ms_radio_access_capability_2_ie +from pycrate_csn1dir.egprs_bep_link_quality_measurements_ie import egprs_bep_link_quality_measurements_ie from pycrate_csn1dir.iu_mode_channel_request_description_ie import iu_mode_channel_request_description_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/packet_serving_cell_data_message_content.py b/pycrate_csn1dir/packet_serving_cell_data_message_content.py index 7a23139..3a8e13a 100644 --- a/pycrate_csn1dir/packet_serving_cell_data_message_content.py +++ b/pycrate_csn1dir/packet_serving_cell_data_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_serving_cell_data_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet Serving Cell Data message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_serving_cell_si_message_content.py b/pycrate_csn1dir/packet_serving_cell_si_message_content.py index b95a531..08850f2 100644 --- a/pycrate_csn1dir/packet_serving_cell_si_message_content.py +++ b/pycrate_csn1dir/packet_serving_cell_si_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_serving_cell_si_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_si_status_message_content.py b/pycrate_csn1dir/packet_si_status_message_content.py index 5e00adc..5e869e5 100644 --- a/pycrate_csn1dir/packet_si_status_message_content.py +++ b/pycrate_csn1dir/packet_si_status_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_si_status_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet SI Status message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_tbf_release_message_content.py b/pycrate_csn1dir/packet_tbf_release_message_content.py index 5e54788..130e455 100644 --- a/pycrate_csn1dir/packet_tbf_release_message_content.py +++ b/pycrate_csn1dir/packet_tbf_release_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_tbf_release_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Packet TBF Release message content # external references -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_timeslot_reconfigure_message_content.py b/pycrate_csn1dir/packet_timeslot_reconfigure_message_content.py index 8078236..c615f67 100644 --- a/pycrate_csn1dir/packet_timeslot_reconfigure_message_content.py +++ b/pycrate_csn1dir/packet_timeslot_reconfigure_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_timeslot_reconfigure_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,20 +32,20 @@ # external references from pycrate_csn1dir.pulse_format_ie import dlmc_frequency_parameters_ie -from pycrate_csn1dir.pulse_format_ie import pulse_format_ie -from pycrate_csn1dir.dtm_handover_ps_radio_resources_3_ie import additional_pfcs_struct -from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.compact_reduced_ma_ie import compact_reduced_ma_ie from pycrate_csn1dir.padding_bits import padding_bits -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.dynamic_allocation_3_ie import dynamic_allocation_3_ie -from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie -from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie +from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie +from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.dynamic_allocation_3_ie import dynamic_allocation_3_ie +from pycrate_csn1dir.pulse_format_ie import pulse_format_ie from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.dtm_handover_ps_radio_resources_3_ie import additional_pfcs_struct +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie +from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie +from pycrate_csn1dir.compact_reduced_ma_ie import compact_reduced_ma_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -54,15 +54,6 @@ from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters from pycrate_csn1.csnobj import * -rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ - CSN1Bit(name='tfi', bit=5), - CSN1Bit(name='rlc_mode'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='pfi', bit=7)]) - dynamic_allocation_struct = CSN1List(name='dynamic_allocation_struct', list=[ CSN1Bit(name='extended_dynamic__allocation'), CSN1Alt(alt={ @@ -153,110 +144,19 @@ dynamic_allocation_struct = CSN1List(name='dynamic_allocation_struct', list=[ CSN1Bit(name='usf_tn7', bit=3), CSN1Bit(name='gamma_tn7', bit=5)])})])})]) -dynamic_allocation_2_struct = CSN1List(name='dynamic_allocation_2_struct', list=[ - CSN1Bit(name='extended_dynamic_allocation'), +rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ + CSN1Bit(name='tfi', bit=5), + CSN1Bit(name='rlc_mode'), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='p0_c1', bit=4), - CSN1Bit(name='pr_mode_c1'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='p0_c2', bit=4), - CSN1Bit(name='pr_mode_c2')])})])}), - CSN1Bit(name='usf_granularity'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='uplink_tfi_assignment', bit=5)])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='n_usf', bit=4), - CSN1Alt(num=([1], lambda x: x + 1), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf', bit=3)])})]), - '1': ('', [ - CSN1Bit(name='alpha_c1', bit=4), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='alpha_c2', bit=4)])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='n_ts', bit=4), - CSN1Alt(num=([1], lambda x: x + 1), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf', bit=3), - CSN1Bit(name='gamma', bit=5)])})]), - '1': ('', [ - CSN1Bit(name='n_pairs', bit=3), - CSN1Alt(num=([1], lambda x: x + 1), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf', bit=3), - CSN1Bit(name='gamma', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Alt(num=([-1, 1], lambda x: x + 1), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_2', bit=3), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gamma', bit=5)])})])})])})])})])})]) + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='pfi', bit=7)]) assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ CSN1Bit(name='assignment_type', bit=2), CSN1Bit(name='carrier_id')]) -dlmc_ul_carrier_info_struct = CSN1Alt(name='dlmc_ul_carrier_info_struct', alt={ - '00': ('', []), - '01': ('', []), - '10': ('', [ - CSN1Alt(alt={ - '0': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='uplink_timeslot_allocation', bit=8)])})]), - '1': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='uplink_pdch_pairs_dlmc', bit=8)])})])}), - CSN1Ref(name='dynamic_allocation_3', obj=dynamic_allocation_3_ie), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='uplink_rlc_entity_2', obj=rlc_entity_struct), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='uplink_rlc_entity_3', obj=rlc_entity_struct)])})])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='emsr_additional_pfcs_1', obj=additional_pfcs_struct)]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='emsr_additional_pfcs_2', obj=additional_pfcs_struct)]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='emsr_additional_pfcs_3', obj=additional_pfcs_struct)]), - CSN1Val(name='', val='0')])}), - CSN1Bit(name='primary_tsc_set')]), - '11': ('', [ - CSN1Bit(bit=-1)])}) - carrier_specific_info_struct = CSN1Alt(name='carrier_specific_info_struct', alt={ '00': ('', []), '01': ('', []), @@ -346,6 +246,106 @@ carrier_specific_info_struct = CSN1Alt(name='carrier_specific_info_struct', alt= '11': ('', [ CSN1Bit(bit=-1)])}) +dlmc_ul_carrier_info_struct = CSN1Alt(name='dlmc_ul_carrier_info_struct', alt={ + '00': ('', []), + '01': ('', []), + '10': ('', [ + CSN1Alt(alt={ + '0': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='uplink_timeslot_allocation', bit=8)])})]), + '1': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='uplink_pdch_pairs_dlmc', bit=8)])})])}), + CSN1Ref(name='dynamic_allocation_3', obj=dynamic_allocation_3_ie), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='uplink_rlc_entity_2', obj=rlc_entity_struct), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='uplink_rlc_entity_3', obj=rlc_entity_struct)])})])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='emsr_additional_pfcs_1', obj=additional_pfcs_struct)]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='emsr_additional_pfcs_2', obj=additional_pfcs_struct)]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='emsr_additional_pfcs_3', obj=additional_pfcs_struct)]), + CSN1Val(name='', val='0')])}), + CSN1Bit(name='primary_tsc_set')]), + '11': ('', [ + CSN1Bit(bit=-1)])}) + +dynamic_allocation_2_struct = CSN1List(name='dynamic_allocation_2_struct', list=[ + CSN1Bit(name='extended_dynamic_allocation'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='p0_c1', bit=4), + CSN1Bit(name='pr_mode_c1'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='p0_c2', bit=4), + CSN1Bit(name='pr_mode_c2')])})])}), + CSN1Bit(name='usf_granularity'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='uplink_tfi_assignment', bit=5)])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='n_usf', bit=4), + CSN1Alt(num=([1], lambda x: x + 1), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf', bit=3)])})]), + '1': ('', [ + CSN1Bit(name='alpha_c1', bit=4), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alpha_c2', bit=4)])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='n_ts', bit=4), + CSN1Alt(num=([1], lambda x: x + 1), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf', bit=3), + CSN1Bit(name='gamma', bit=5)])})]), + '1': ('', [ + CSN1Bit(name='n_pairs', bit=3), + CSN1Alt(num=([1], lambda x: x + 1), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf', bit=3), + CSN1Bit(name='gamma', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Alt(num=([-1, 1], lambda x: x + 1), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_2', bit=3), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gamma', bit=5)])})])})])})])})])})]) + ufps_struct = CSN1Alt(name='ufps_struct', alt={ '00': ('', []), '01': ('', []), diff --git a/pycrate_csn1dir/packet_timing_advance_ie.py b/pycrate_csn1dir/packet_timing_advance_ie.py index cb90b43..5ce13e5 100644 --- a/pycrate_csn1dir/packet_timing_advance_ie.py +++ b/pycrate_csn1dir/packet_timing_advance_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_timing_advance_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/packet_uplink_ack_nack_message_content.py b/pycrate_csn1dir/packet_uplink_ack_nack_message_content.py index 98db54c..c58c27e 100644 --- a/pycrate_csn1dir/packet_uplink_ack_nack_message_content.py +++ b/pycrate_csn1dir/packet_uplink_ack_nack_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_uplink_ack_nack_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,13 +31,13 @@ # top-level object: Packet Uplink Ack/Nack message content # external references +from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.egprs_ack_nack_description_ie import egprs_ack_nack_description_ie +from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie from pycrate_csn1dir.ack_nack_description_ie import ack_nack_description_ie from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie from pycrate_csn1dir.extension_bits_ie import extension_bits_ie -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/packet_uplink_assignment_message_content.py b/pycrate_csn1dir/packet_uplink_assignment_message_content.py index 8809147..652b447 100644 --- a/pycrate_csn1dir/packet_uplink_assignment_message_content.py +++ b/pycrate_csn1dir/packet_uplink_assignment_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_uplink_assignment_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,20 +31,20 @@ # top-level object: Packet Uplink Assignment message content # external references -from pycrate_csn1dir.pulse_format_ie import pulse_format_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.compact_reduced_ma_ie import compact_reduced_ma_ie -from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie -from pycrate_csn1dir.padding_bits import padding_bits -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.dynamic_allocation_3_ie import dynamic_allocation_3_ie -from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie -from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie -from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie -from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_number_description_ie +from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.dynamic_allocation_3_ie import dynamic_allocation_3_ie +from pycrate_csn1dir.pulse_format_ie import pulse_format_ie +from pycrate_csn1dir.packet_request_reference_ie import packet_request_reference_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie +from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie +from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie +from pycrate_csn1dir.compact_reduced_ma_ie import compact_reduced_ma_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -53,23 +53,6 @@ from pycrate_csn1dir.starting_frame_number_description_ie import starting_frame_ from pycrate_csn1.csnobj import * -additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ - CSN1Bit(name='uplink_tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Bit(name='pfi', bit=7)]) - -rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ - CSN1Bit(name='uplink_tfi_assignment', bit=5), - CSN1Bit(name='rlc_mode'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='pfi', bit=7)]) - access_technologies_request_struct = CSN1List(name='access_technologies_request_struct', list=[ CSN1Bit(name='access_technology_type', bit=4), CSN1Alt(alt={ @@ -171,9 +154,30 @@ dynamic_allocation_struct = CSN1List(name='dynamic_allocation_struct', list=[ CSN1Bit(name='usf_tn7', bit=3), CSN1Bit(name='gamma_tn7', bit=5)])})])})]) +additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ + CSN1Bit(name='uplink_tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Bit(name='pfi', bit=7)]) + +rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ + CSN1Bit(name='uplink_tfi_assignment', bit=5), + CSN1Bit(name='rlc_mode'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='pfi', bit=7)]) + +assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ + CSN1Bit(name='assignment_type', bit=2), + CSN1Bit(name='carrier_id')]) + extension = CSN1Val(name='extension', val='null') -multi_block_allocation_struct = CSN1List(name='multi_block_allocation_struct', list=[ +single_block_allocation_struct = CSN1List(name='single_block_allocation_struct', list=[ CSN1Bit(name='timeslot_number', bit=3), CSN1Alt(alt={ '0': ('', []), @@ -186,8 +190,7 @@ multi_block_allocation_struct = CSN1List(name='multi_block_allocation_struct', l CSN1Bit(name='p0', bit=4), CSN1Val(name='', val='0'), CSN1Bit(name='pr_mode')])}), - CSN1Ref(name='tbf_starting_time', obj=starting_frame_number_description_ie), - CSN1Bit(name='number_of_radio_blocks_allocated', bit=2)]) + CSN1Ref(name='tbf_starting_time', obj=starting_frame_number_description_ie)]) dynamic_allocation_2_struct = CSN1List(name='dynamic_allocation_2_struct', list=[ CSN1Bit(name='extended_dynamic_allocation'), @@ -246,25 +249,6 @@ dynamic_allocation_2_struct = CSN1List(name='dynamic_allocation_2_struct', list= '1': ('', [ CSN1Bit(name='gamma', bit=5)])})])})])})])})])})]) -single_block_allocation_struct = CSN1List(name='single_block_allocation_struct', list=[ - CSN1Bit(name='timeslot_number', bit=3), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='alpha', bit=4), - CSN1Bit(name='gamma_tn', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='p0', bit=4), - CSN1Val(name='', val='0'), - CSN1Bit(name='pr_mode')])}), - CSN1Ref(name='tbf_starting_time', obj=starting_frame_number_description_ie)]) - -assignment_info_struct = CSN1List(name='assignment_info_struct', list=[ - CSN1Bit(name='assignment_type', bit=2), - CSN1Bit(name='carrier_id')]) - dlmc_ul_carrier_info_struct = CSN1Alt(name='dlmc_ul_carrier_info_struct', alt={ '00': ('', []), '01': ('', []), @@ -308,6 +292,22 @@ dlmc_ul_carrier_info_struct = CSN1Alt(name='dlmc_ul_carrier_info_struct', alt={ '11': ('', [ CSN1Bit(bit=-1)])}) +multi_block_allocation_struct = CSN1List(name='multi_block_allocation_struct', list=[ + CSN1Bit(name='timeslot_number', bit=3), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='alpha', bit=4), + CSN1Bit(name='gamma_tn', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='p0', bit=4), + CSN1Val(name='', val='0'), + CSN1Bit(name='pr_mode')])}), + CSN1Ref(name='tbf_starting_time', obj=starting_frame_number_description_ie), + CSN1Bit(name='number_of_radio_blocks_allocated', bit=2)]) + packet_uplink_assignment_message_content = CSN1List(name='packet_uplink_assignment_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/packet_uplink_dummy_control_block_message_content.py b/pycrate_csn1dir/packet_uplink_dummy_control_block_message_content.py index 7f71af9..3064238 100644 --- a/pycrate_csn1dir/packet_uplink_dummy_control_block_message_content.py +++ b/pycrate_csn1dir/packet_uplink_dummy_control_block_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/packet_uplink_dummy_control_block_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/padding_bits.py b/pycrate_csn1dir/padding_bits.py index d46ec84..2e07180 100644 --- a/pycrate_csn1dir/padding_bits.py +++ b/pycrate_csn1dir/padding_bits.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/padding_bits.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,10 +43,10 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -spare_padding = CSN1Val(name='spare_padding', val='L**') - padding_bits = CSN1Alt(name='padding_bits', alt={ '0': ('', [ CSN1Ref(obj=spare_padding)]), None: ('', [])}) +spare_padding = CSN1Val(name='spare_padding', val='L**') + diff --git a/pycrate_csn1dir/pccch_organization_parameters_ie.py b/pycrate_csn1dir/pccch_organization_parameters_ie.py index eca3f68..feac448 100644 --- a/pycrate_csn1dir/pccch_organization_parameters_ie.py +++ b/pycrate_csn1dir/pccch_organization_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/pccch_organization_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/pcid_group_ie.py b/pycrate_csn1dir/pcid_group_ie.py index 0d4d3f7..b79f4ff 100644 --- a/pycrate_csn1dir/pcid_group_ie.py +++ b/pycrate_csn1dir/pcid_group_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/pcid_group_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/pdch_pairs_description_ie.py b/pycrate_csn1dir/pdch_pairs_description_ie.py index 4ad4ad6..16b9683 100644 --- a/pycrate_csn1dir/pdch_pairs_description_ie.py +++ b/pycrate_csn1dir/pdch_pairs_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/pdch_pairs_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/physical_information_message_content.py b/pycrate_csn1dir/physical_information_message_content.py index 5681350..228f5b7 100644 --- a/pycrate_csn1dir/physical_information_message_content.py +++ b/pycrate_csn1dir/physical_information_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/physical_information_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/power_control_parameters_ie.py b/pycrate_csn1dir/power_control_parameters_ie.py index fcf9bb2..b84fb61 100644 --- a/pycrate_csn1dir/power_control_parameters_ie.py +++ b/pycrate_csn1dir/power_control_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/power_control_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/prach_control_parameters_ie.py b/pycrate_csn1dir/prach_control_parameters_ie.py index 5e87c68..2256dfc 100644 --- a/pycrate_csn1dir/prach_control_parameters_ie.py +++ b/pycrate_csn1dir/prach_control_parameters_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/prach_control_parameters_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/ps_handover_access_message_content_8_bit_message.py b/pycrate_csn1dir/ps_handover_access_message_content_8_bit_message.py index 6dfd548..ec64e51 100644 --- a/pycrate_csn1dir/ps_handover_access_message_content_8_bit_message.py +++ b/pycrate_csn1dir/ps_handover_access_message_content_8_bit_message.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ps_handover_access_message_content_8_bit_message.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -39,9 +39,9 @@ from pycrate_csn1.csnobj import * -ps_handover_access_message_content_8_bit_message = CSN1Bit(name='ps_handover_access_message_content_8_bit_message', bit=8) - ps_handover_access_message_content_11_bit_message = CSN1List(name='ps_handover_access_message_content_11_bit_message', list=[ CSN1Bit(name='handover_reference', bit=8), CSN1Bit(name='spare', bit=3)]) +ps_handover_access_message_content_8_bit_message = CSN1Bit(name='ps_handover_access_message_content_8_bit_message', bit=8) + diff --git a/pycrate_csn1dir/ps_handover_command_message_content.py b/pycrate_csn1dir/ps_handover_command_message_content.py index 4994ced..b2b8812 100644 --- a/pycrate_csn1dir/ps_handover_command_message_content.py +++ b/pycrate_csn1dir/ps_handover_command_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ps_handover_command_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,15 +31,15 @@ # top-level object: PS Handover Command message content # external references -from pycrate_csn1dir.ps_handover_radio_resources_3_ie import ps_handover_radio_resources_3_ie -from pycrate_csn1dir.rrc_container_ie import rrc_container_ie -from pycrate_csn1dir.global_tfi_ie import global_tfi_ie -from pycrate_csn1dir.ps_handover_radio_resources_ie import ps_handover_radio_resources_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.rrc_container_ie import rrc_container_ie +from pycrate_csn1dir.nas_container_for_ps_handover_ie import nas_container_for_ps_handover_ie +from pycrate_csn1dir.ps_handover_radio_resources_3_ie import ps_handover_radio_resources_3_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.measurement_control_parameters_description import measurement_control_parameters_description +from pycrate_csn1dir.global_tfi_ie import global_tfi_ie +from pycrate_csn1dir.ps_handover_radio_resources_ie import ps_handover_radio_resources_ie from pycrate_csn1dir.ps_handover_radio_resources_2_ie import ps_handover_radio_resources_2_ie -from pycrate_csn1dir.nas_container_for_ps_handover_ie import nas_container_for_ps_handover_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -48,14 +48,6 @@ from pycrate_csn1dir.nas_container_for_ps_handover_ie import nas_container_for_p from pycrate_csn1.csnobj import * -additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ - CSN1Bit(name='tfi', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Bit(name='pfi', bit=7)]) - rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ CSN1Bit(name='tfi', bit=5), CSN1Bit(name='rlc_mode'), @@ -65,6 +57,14 @@ rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), CSN1Bit(name='pfi', bit=7)]) +additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ + CSN1Bit(name='tfi', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Bit(name='pfi', bit=7)]) + ps_handover_command_message_content = CSN1List(name='ps_handover_command_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1List(list=[ diff --git a/pycrate_csn1dir/ps_handover_radio_resources_2_ie.py b/pycrate_csn1dir/ps_handover_radio_resources_2_ie.py index 93c6f4b..64de46e 100644 --- a/pycrate_csn1dir/ps_handover_radio_resources_2_ie.py +++ b/pycrate_csn1dir/ps_handover_radio_resources_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ps_handover_radio_resources_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: PS Handover Radio Resources 2 IE # external references -from pycrate_csn1dir.egprs_mode_2_ie import egprs_mode_2_ie -from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie from pycrate_csn1dir.dual_carrier_frequency_parameters_ie import dual_carrier_frequency_parameters_ie +from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie +from pycrate_csn1dir.egprs_mode_2_ie import egprs_mode_2_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/ps_handover_radio_resources_3_ie.py b/pycrate_csn1dir/ps_handover_radio_resources_3_ie.py index be68ba0..1429bf8 100644 --- a/pycrate_csn1dir/ps_handover_radio_resources_3_ie.py +++ b/pycrate_csn1dir/ps_handover_radio_resources_3_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ps_handover_radio_resources_3_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,13 +32,13 @@ # external references from pycrate_csn1dir.pulse_format_ie import dlmc_frequency_parameters_ie +from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie +from pycrate_csn1dir.dynamic_allocation_3_ie import dynamic_allocation_3_ie from pycrate_csn1dir.pulse_format_ie import pulse_format_ie +from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.dynamic_allocation_3_ie import dynamic_allocation_3_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie -from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie -from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -47,10 +47,6 @@ from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters from pycrate_csn1.csnobj import * -ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) - rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ CSN1Bit(name='tfi', bit=5), CSN1Bit(name='rlc_mode'), @@ -60,6 +56,10 @@ rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), CSN1Bit(name='pfi', bit=7)]) +ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) + additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ CSN1Bit(name='tfi', bit=5), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/ps_handover_radio_resources_ie.py b/pycrate_csn1dir/ps_handover_radio_resources_ie.py index 57ed5ea..50a8f25 100644 --- a/pycrate_csn1dir/ps_handover_radio_resources_ie.py +++ b/pycrate_csn1dir/ps_handover_radio_resources_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/ps_handover_radio_resources_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: PS Handover Radio Resources IE # external references -from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.global_packet_timing_advance_ie import global_packet_timing_advance_ie from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -43,44 +43,6 @@ from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulati from pycrate_csn1.csnobj import * -ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) - -uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='pfi', bit=7)])}), - CSN1Bit(name='rlc_mode'), - CSN1Bit(name='tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='channel_coding_command', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='usf_granularity'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='usf_allocation', bit=3)]), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3), - CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_allocation', bit=3)])})])})]) - downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -94,6 +56,10 @@ downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', '1': ('', [ CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])})]) +ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) + timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ '0': ('', [ CSN1Bit(name='ms_timeslot_allocation', bit=8)]), @@ -132,10 +98,62 @@ timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ '1': ('', [ CSN1Bit(name='gamma_tn7', bit=5)])})])}) +uplink_tbf_assignment_struct = CSN1List(name='uplink_tbf_assignment_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='pfi', bit=7)])}), + CSN1Bit(name='rlc_mode'), + CSN1Bit(name='tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='channel_coding_command', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_channel_coding_command', obj=egprs_modulation_and_coding_scheme_ie)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='usf_granularity'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tbf_timeslot_allocation', bit=('# unprocessed: (N)', lambda: 0))])}), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='usf_allocation', bit=3)]), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3), + CSN1Alt(num=('# unprocessed: (M-1)', lambda: 0), alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_allocation', bit=3)])})])})]) + downlink_assignment_struct = CSN1List(name='downlink_assignment_struct', list=[ CSN1Bit(name='timeslot_allocation', bit=8), CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]) +gprs_mode_struct = CSN1List(name='gprs_mode_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='channel_coding_command', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='global_timeslot_description', obj=timeslot_description_struct), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='uplink_assignment', obj=uplink_tbf_assignment_struct)]), + CSN1Val(name='', val='0')])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='downlink_assignment', obj=downlink_assignment_struct)]), + CSN1Val(name='', val='0')]) + egprs_mode_struct = CSN1List(name='egprs_mode_struct', list=[ CSN1List(list=[ CSN1Alt(alt={ @@ -178,24 +196,6 @@ egprs_mode_struct = CSN1List(name='egprs_mode_struct', list=[ CSN1Ref(name='downlink_assignment', obj=downlink_assignment_struct)]), CSN1Val(name='', val='0')])})]) -gprs_mode_struct = CSN1List(name='gprs_mode_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='channel_coding_command', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='global_timeslot_description', obj=timeslot_description_struct), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='uplink_assignment', obj=uplink_tbf_assignment_struct)]), - CSN1Val(name='', val='0')])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='downlink_assignment', obj=downlink_assignment_struct)]), - CSN1Val(name='', val='0')]) - ps_handover_radio_resources_ie = CSN1List(name='ps_handover_radio_resources_ie', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/psc_group_ie.py b/pycrate_csn1dir/psc_group_ie.py index cc0c0b3..ae504df 100644 --- a/pycrate_csn1dir/psc_group_ie.py +++ b/pycrate_csn1dir/psc_group_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psc_group_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/psi13_message_content.py b/pycrate_csn1dir/psi13_message_content.py index 6f04016..9f0b46d 100644 --- a/pycrate_csn1dir/psi13_message_content.py +++ b/pycrate_csn1dir/psi13_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi13_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: PSI13 message content # external references -from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie -from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie +from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_parameters_ie # code automatically generated by pycrate_csn1 diff --git a/pycrate_csn1dir/psi14_message_content.py b/pycrate_csn1dir/psi14_message_content.py index d1bc05b..d178b77 100644 --- a/pycrate_csn1dir/psi14_message_content.py +++ b/pycrate_csn1dir/psi14_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi14_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,11 +31,11 @@ # top-level object: PSI14 message content # external references -from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_parameters_ie +from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -44,18 +44,6 @@ from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_ from pycrate_csn1.csnobj import * -pbcch_description_struct_2 = CSN1List(name='pbcch_description_struct_2', list=[ - CSN1Bit(name='psi1_repeat_period', bit=4), - CSN1Bit(name='pb', bit=4), - CSN1Bit(name='tn', bit=3), - CSN1Ref(name='pbcch_frequency_description', obj=frequency_parameters_ie), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(bit=-1)]), - '11': ('', [ - CSN1Bit(name='psi_changed_ind')]), - None: ('', [])})]) - ccch_access_information_struct = CSN1List(name='ccch_access_information_struct', list=[ CSN1Bit(name='bcch_change_mark', bit=3), CSN1Alt(alt={ @@ -87,6 +75,18 @@ ccch_access_information_struct = CSN1List(name='ccch_access_information_struct', None: ('', [])})]), None: ('', [])})]) +pbcch_description_struct_2 = CSN1List(name='pbcch_description_struct_2', list=[ + CSN1Bit(name='psi1_repeat_period', bit=4), + CSN1Bit(name='pb', bit=4), + CSN1Bit(name='tn', bit=3), + CSN1Ref(name='pbcch_frequency_description', obj=frequency_parameters_ie), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(bit=-1)]), + '11': ('', [ + CSN1Bit(name='psi_changed_ind')]), + None: ('', [])})]) + psi14_message_content = CSN1List(name='psi14_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/psi15_message_content.py b/pycrate_csn1dir/psi15_message_content.py index 7220364..16c856e 100644 --- a/pycrate_csn1dir/psi15_message_content.py +++ b/pycrate_csn1dir/psi15_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi15_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/psi16_message_content.py b/pycrate_csn1dir/psi16_message_content.py index 956b793..0d3bd08 100644 --- a/pycrate_csn1dir/psi16_message_content.py +++ b/pycrate_csn1dir/psi16_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi16_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -40,14 +40,14 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * +cn_domain_identity_ie = CSN1Bit(name='cn_domain_identity_ie', bit=2) + gra_id_struct = CSN1List(name='gra_id_struct', list=[ CSN1Bit(name='number_of_gra_ids', bit=3), CSN1Bit(name='gra_id', bit=16, num=([0], lambda x: x + 1))]) cn_domain_specific_drx_cycle_length_coefficient_ie = CSN1Bit(name='cn_domain_specific_drx_cycle_length_coefficient_ie', bit=4) -cn_domain_identity_ie = CSN1Bit(name='cn_domain_identity_ie', bit=2) - psi16_message_content = CSN1List(name='psi16_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1Bit(name='psi16_change_mark', bit=2), diff --git a/pycrate_csn1dir/psi1_message_content.py b/pycrate_csn1dir/psi1_message_content.py index d0ae972..934e2c9 100644 --- a/pycrate_csn1dir/psi1_message_content.py +++ b/pycrate_csn1dir/psi1_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi1_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,11 +31,11 @@ # top-level object: PSI1 message content # external references -from pycrate_csn1dir.pccch_organization_parameters_ie import pccch_organization_parameters_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.prach_control_parameters_ie import prach_control_parameters_ie +from pycrate_csn1dir.pccch_organization_parameters_ie import pccch_organization_parameters_ie from pycrate_csn1dir.global_power_control_parameters_ie import global_power_control_parameters_ie from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie -from pycrate_csn1dir.prach_control_parameters_ie import prach_control_parameters_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/psi2_message_content.py b/pycrate_csn1dir/psi2_message_content.py index d161b1b..49c5e3e 100644 --- a/pycrate_csn1dir/psi2_message_content.py +++ b/pycrate_csn1dir/psi2_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi2_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: PSI2 message content # external references -from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie from pycrate_csn1dir.non_gprs_cell_options_ie import non_gprs_cell_options_ie -from pycrate_csn1dir.cell_identification_ie import cell_identification_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.cell_identification_ie import cell_identification_ie +from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -43,26 +43,14 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -non_hopping_pccch_carriers_struct = CSN1List(name='non_hopping_pccch_carriers_struct', list=[ - CSN1Bit(name='arfcn', bit=10), - CSN1Bit(name='timeslot_allocation', bit=8)]) - reference_frequency_struct = CSN1List(name='reference_frequency_struct', list=[ CSN1Bit(name='rfl_number', bit=4), CSN1Bit(name='length_of_rfl_contents', bit=4), CSN1Bit(name='rfl_contents', bit=8, num=([1], lambda x: x + 3))]) -non_hopping_pccch_carriers_lists_struct = CSN1List(name='non_hopping_pccch_carriers_lists_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(obj=non_hopping_pccch_carriers_struct)]), - CSN1Val(name='', val='0')]) - -reference_frequency_lists_struct = CSN1List(name='reference_frequency_lists_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(obj=reference_frequency_struct)]), - CSN1Val(name='', val='0')]) +gprs_mobile_allocations_struct = CSN1List(name='gprs_mobile_allocations_struct', list=[ + CSN1Bit(name='ma_number', bit=4), + CSN1Ref(name='gprs_mobile_allocation', obj=gprs_mobile_allocation_ie)]) number_of_idle_blocks_struct = CSN1List(name='number_of_idle_blocks_struct', list=[ CSN1Alt(alt={ @@ -82,26 +70,6 @@ number_of_idle_blocks_struct = CSN1List(name='number_of_idle_blocks_struct', lis '1': ('', [ CSN1Bit(name='nib_ccch_3', bit=4)])})]) -hopping_pccch_carriers_struct = CSN1List(name='hopping_pccch_carriers_struct', list=[ - CSN1Bit(name='maio', bit=6), - CSN1Bit(name='timeslot_allocation', bit=8)]) - -gprs_mobile_allocations_struct = CSN1List(name='gprs_mobile_allocations_struct', list=[ - CSN1Bit(name='ma_number', bit=4), - CSN1Ref(name='gprs_mobile_allocation', obj=gprs_mobile_allocation_ie)]) - -gprs_mobile_allocations_lists_struct = CSN1List(name='gprs_mobile_allocations_lists_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(obj=gprs_mobile_allocations_struct)]), - CSN1Val(name='', val='0')]) - -additional_psi_messages_struct = CSN1List(name='additional_psi_messages_struct', list=[ - CSN1Bit(name='non_gsm_information', bit=2), - CSN1Bit(name='psi8_broadcast'), - CSN1Bit(name='psi3ter_broadcast'), - CSN1Bit(name='psi3quater_broadcast')]) - compact_control_info_struct = CSN1List(name='compact_control_info_struct', list=[ CSN1Bit(name='large_cell_operation'), CSN1Alt(alt={ @@ -113,14 +81,52 @@ compact_control_info_struct = CSN1List(name='compact_control_info_struct', list= '1': ('', [ CSN1Bit(name='n_ccch_nh', bit=4)])})]) +hopping_pccch_carriers_struct = CSN1List(name='hopping_pccch_carriers_struct', list=[ + CSN1Bit(name='maio', bit=6), + CSN1Bit(name='timeslot_allocation', bit=8)]) + cell_allocation_struct = CSN1Bit(name='cell_allocation_struct', bit=4) +additional_psi_messages_struct = CSN1List(name='additional_psi_messages_struct', list=[ + CSN1Bit(name='non_gsm_information', bit=2), + CSN1Bit(name='psi8_broadcast'), + CSN1Bit(name='psi3ter_broadcast'), + CSN1Bit(name='psi3quater_broadcast')]) + +reference_frequency_lists_struct = CSN1List(name='reference_frequency_lists_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(obj=reference_frequency_struct)]), + CSN1Val(name='', val='0')]) + hopping_pccch_carriers_lists_struct = CSN1List(name='hopping_pccch_carriers_lists_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), CSN1Ref(obj=hopping_pccch_carriers_struct)]), CSN1Val(name='', val='0')]) +non_hopping_pccch_carriers_struct = CSN1List(name='non_hopping_pccch_carriers_struct', list=[ + CSN1Bit(name='arfcn', bit=10), + CSN1Bit(name='timeslot_allocation', bit=8)]) + +gprs_mobile_allocations_lists_struct = CSN1List(name='gprs_mobile_allocations_lists_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(obj=gprs_mobile_allocations_struct)]), + CSN1Val(name='', val='0')]) + +cell_allocation_lists_struct = CSN1List(name='cell_allocation_lists_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(obj=cell_allocation_struct)]), + CSN1Val(name='', val='0')]) + +non_hopping_pccch_carriers_lists_struct = CSN1List(name='non_hopping_pccch_carriers_lists_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(obj=non_hopping_pccch_carriers_struct)]), + CSN1Val(name='', val='0')]) + pccch_description_struct = CSN1List(name='pccch_description_struct', list=[ CSN1Bit(name='tsc', bit=3), CSN1Alt(alt={ @@ -136,12 +142,6 @@ pccch_description_lists_struct = CSN1List(name='pccch_description_lists_struct', CSN1Ref(obj=pccch_description_struct)]), CSN1Val(name='', val='0')]) -cell_allocation_lists_struct = CSN1List(name='cell_allocation_lists_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(obj=cell_allocation_struct)]), - CSN1Val(name='', val='0')]) - psi2_message_content = CSN1List(name='psi2_message_content', trunc=True, list=[ CSN1Bit(name='page_mode', bit=2), CSN1Bit(name='psi2_change_mark', bit=2), diff --git a/pycrate_csn1dir/psi3_bis_message_content.py b/pycrate_csn1dir/psi3_bis_message_content.py index ef8be46..1d2f488 100644 --- a/pycrate_csn1dir/psi3_bis_message_content.py +++ b/pycrate_csn1dir/psi3_bis_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi3_bis_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,6 +30,25 @@ # section: 11.2.21 Packet System Information Type 3 bis # top-level object: PSI3 bis message content +def max_cell_params(cpp): + # cpp is a list of list of fmt [1, ref, 2-bit-val] + # + # CSN1List(num=-1, list=[ + # CSN1Val(name='', val='1'), + # CSN1Ref(obj=ncp2_repeat_struct), + # CSN1Bit(name='cell_params_pointer', bit=2)]) + # + if cpp: + try: + if isinstance(cpp[0][2], integer_types): + return 1 + max([i[2] for i in cpp]) + elif isinstance(cpp[0][2], str_types): + return 1 + max([int(i[2], 2) for i in cpp]) + except: + pass + return 0 + + # external references from pycrate_csn1dir.lsa_parameters_ie import lsa_parameters_ie from pycrate_csn1dir.padding_bits import padding_bits @@ -41,204 +60,21 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -si13_pbcch_location_struct = CSN1Alt(name='si13_pbcch_location_struct', alt={ - '0': ('', [ - CSN1Bit(name='si13_location')]), - '1': ('', [ - CSN1Bit(name='pbcch_location', bit=2), - CSN1Bit(name='psi1_repeat_period', bit=4)])}) - -compact_ncp2_property_struct = CSN1List(name='compact_ncp2_property_struct', list=[ - CSN1Bit(name='same_ra_as_serving_cell'), - CSN1Bit(name='cell_bar_access_2'), - CSN1Bit(name='bcc', bit=3), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='time_group', bit=2)])})]) - -compact_ncp2_repeat_struct = CSN1Alt(name='compact_ncp2_repeat_struct', alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='start_frequency', bit=10), - CSN1Ref(obj=compact_ncp2_property_struct), - CSN1Alt(alt={ - '0000': ('', []), - '0001': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '0010': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '0011': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '0100': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '0101': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '0110': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '0111': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1000': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1001': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1010': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1011': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1100': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1101': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1110': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()]), - '1111': ('nr_of_remaining_cells', [ - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([0], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), - CSN1Ref(obj=compact_ncp2_property_struct)]), - CSN1SelfRef()])})])}) - ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ CSN1Bit(name='number_cells', bit=7), CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) -iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', list=[ - CSN1Bit(name='cell_bar_qualify_3', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) - -compact_neighbour_parameter_set_struct = CSN1List(name='compact_neighbour_parameter_set_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ncc', bit=3)])}), - CSN1Bit(name='exc_acc'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_rxlev_access_min', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_priority_class', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_hcs_thr', bit=5)])}), - CSN1Bit(name='gprs_temporary_offset', bit=3), - CSN1Bit(name='gprs_penalty_time', bit=5), - CSN1Bit(name='gprs_reselect_offset', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='guar_constant_pwr_blks', bit=2)])})]) - ncp2_property_struct = CSN1List(name='ncp2_property_struct', list=[ CSN1Bit(name='same_ra_as_serving_cell'), CSN1Bit(name='cell_bar_access_2'), CSN1Bit(name='bcc', bit=3)]) -neighbour_parameter_set_struct = CSN1List(name='neighbour_parameter_set_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ncc', bit=3)])}), - CSN1Bit(name='exc_acc'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_rxlev_access_min', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='priority_class', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='hcs_thr', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13_pbcch_location', obj=si13_pbcch_location_struct)])}), - CSN1Bit(name='gprs_temporary_offset', bit=3), - CSN1Bit(name='gprs_penalty_time', bit=5), - CSN1Bit(name='gprs_reselect_offset', bit=5)]) - -compact_neighbour_cell_params_2_struct = CSN1List(name='compact_neighbour_cell_params_2_struct', list=[ - CSN1Val(name='', val='00'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(obj=compact_ncp2_repeat_struct), - CSN1Bit(name='cell_params_pointer', bit=2)]), - CSN1Val(name='', val='0'), - CSN1Ref(name='compact_neighbour_parameter_set', obj=compact_neighbour_parameter_set_struct, num=('# unprocessed: (1+max(val(CELL_PARAMS_POINTER)))', lambda: 0))]) +si13_pbcch_location_struct = CSN1Alt(name='si13_pbcch_location_struct', alt={ + '0': ('', [ + CSN1Bit(name='si13_location')]), + '1': ('', [ + CSN1Bit(name='pbcch_location', bit=2), + CSN1Bit(name='psi1_repeat_period', bit=4)])}) hcs_struct = CSN1List(name='hcs_struct', list=[ CSN1Bit(name='priority_class', bit=3), @@ -271,51 +107,44 @@ iu_mode_only_cell_selection_struct = CSN1List(name='iu_mode_only_cell_selection_ '1': ('', [ CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) -cell_selection_struct = CSN1List(name='cell_selection_struct', list=[ - CSN1Bit(name='bsic', bit=6), - CSN1Bit(name='cell_bar_access_2'), - CSN1Bit(name='exc_acc'), - CSN1Bit(name='same_ra_as_serving_cell'), +neighbour_parameter_set_struct = CSN1List(name='neighbour_parameter_set_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='ncc', bit=3)])}), + CSN1Bit(name='exc_acc'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_rxlev_access_min', bit=6)])}), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='gprs_rxlev_access_min', bit=6), CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='gprs_temporary_offset', bit=3), - CSN1Bit(name='gprs_penalty_time', bit=5)])}), + CSN1Bit(name='priority_class', bit=3)])}), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='gprs_reselect_offset', bit=5)])}), + CSN1Bit(name='hcs_thr', bit=5)])}), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Ref(name='hcs_params', obj=hcs_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13_pbcch_location', obj=si13_pbcch_location_struct)])})]) + CSN1Ref(name='si13_pbcch_location', obj=si13_pbcch_location_struct)])}), + CSN1Bit(name='gprs_temporary_offset', bit=3), + CSN1Bit(name='gprs_penalty_time', bit=5), + CSN1Bit(name='gprs_reselect_offset', bit=5)]) -neighbour_cell_params_struct = CSN1List(name='neighbour_cell_params_struct', list=[ - CSN1Bit(name='start_frequency', bit=10), - CSN1Ref(name='cell_selection_params', obj=cell_selection_struct), - CSN1Bit(name='nr_of_remaining_cells', bit=4), - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([2], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 3], lambda x: x + 1)), - CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])]) - -iu_mode_only_neighbour_cell_params_struct = CSN1List(name='iu_mode_only_neighbour_cell_params_struct', list=[ - CSN1Bit(name='start_frequency', bit=10), - CSN1Ref(name='iu_mode_only_cell_selection_params', obj=iu_mode_only_cell_selection_struct), - CSN1Bit(name='nr_of_remaining_cells', bit=4), - CSN1Bit(name='freq_diff_length', bit=3), - CSN1List(num=([2], lambda x: x), list=[ - CSN1Bit(name='frequency_diff', bit=([-1, 3], lambda x: x + 1)), - CSN1Ref(name='iu_mode_only_cell_selection_params', obj=iu_mode_only_cell_selection_struct)])]) +compact_ncp2_property_struct = CSN1List(name='compact_ncp2_property_struct', list=[ + CSN1Bit(name='same_ra_as_serving_cell'), + CSN1Bit(name='cell_bar_access_2'), + CSN1Bit(name='bcc', bit=3), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='time_group', bit=2)])})]) ncp2_repeat_struct = CSN1Alt(name='ncp2_repeat_struct', alt={ '0': ('', []), @@ -415,12 +244,196 @@ ncp2_repeat_struct = CSN1Alt(name='ncp2_repeat_struct', alt={ CSN1Ref(obj=ncp2_property_struct)]), CSN1SelfRef()])})])}) -iu_mode_neighbour_cell_params_struct = CSN1List(name='iu_mode_neighbour_cell_params_struct', list=[ - CSN1Bit(name='nr_of_remaining_cells', bit=4), - CSN1Alt(num=([0], lambda x: x), alt={ +compact_ncp2_repeat_struct = CSN1Alt(name='compact_ncp2_repeat_struct', alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='start_frequency', bit=10), + CSN1Ref(obj=compact_ncp2_property_struct), + CSN1Alt(alt={ + '0000': ('', []), + '0001': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '0010': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '0011': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '0100': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '0101': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '0110': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '0111': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1000': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1001': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1010': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1011': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1100': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1101': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1110': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()]), + '1111': ('nr_of_remaining_cells', [ + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([0], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 1], lambda x: x + 1)), + CSN1Ref(obj=compact_ncp2_property_struct)]), + CSN1SelfRef()])})])}) + +compact_neighbour_parameter_set_struct = CSN1List(name='compact_neighbour_parameter_set_struct', list=[ + CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])})]) + CSN1Bit(name='ncc', bit=3)])}), + CSN1Bit(name='exc_acc'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_rxlev_access_min', bit=6)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_priority_class', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_hcs_thr', bit=5)])}), + CSN1Bit(name='gprs_temporary_offset', bit=3), + CSN1Bit(name='gprs_penalty_time', bit=5), + CSN1Bit(name='gprs_reselect_offset', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='guar_constant_pwr_blks', bit=2)])})]) + +cell_selection_struct = CSN1List(name='cell_selection_struct', list=[ + CSN1Bit(name='bsic', bit=6), + CSN1Bit(name='cell_bar_access_2'), + CSN1Bit(name='exc_acc'), + CSN1Bit(name='same_ra_as_serving_cell'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_rxlev_access_min', bit=6), + CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_temporary_offset', bit=3), + CSN1Bit(name='gprs_penalty_time', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_reselect_offset', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='hcs_params', obj=hcs_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13_pbcch_location', obj=si13_pbcch_location_struct)])})]) + +iu_mode_only_neighbour_cell_params_struct = CSN1List(name='iu_mode_only_neighbour_cell_params_struct', list=[ + CSN1Bit(name='start_frequency', bit=10), + CSN1Ref(name='iu_mode_only_cell_selection_params', obj=iu_mode_only_cell_selection_struct), + CSN1Bit(name='nr_of_remaining_cells', bit=4), + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([2], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 3], lambda x: x + 1)), + CSN1Ref(name='iu_mode_only_cell_selection_params', obj=iu_mode_only_cell_selection_struct)])]) + +iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', list=[ + CSN1Bit(name='cell_bar_qualify_3', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) + +compact_neighbour_cell_params_2_struct = CSN1List(name='compact_neighbour_cell_params_2_struct', list=[ + CSN1Val(name='', val='00'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(obj=compact_ncp2_repeat_struct), + CSN1Bit(name='cell_params_pointer', bit=2)]), + CSN1Val(name='', val='0'), + #CSN1Ref(name='compact_neighbour_parameter_set', obj=compact_neighbour_parameter_set_struct, num=('# unprocessed: (1+max(val(CELL_PARAMS_POINTER)))', lambda: 0))]) + CSN1Ref(name='compact_neighbour_parameter_set', obj=compact_neighbour_parameter_set_struct, num=([1], max_cell_params))]) + +neighbour_cell_params_struct = CSN1List(name='neighbour_cell_params_struct', list=[ + CSN1Bit(name='start_frequency', bit=10), + CSN1Ref(name='cell_selection_params', obj=cell_selection_struct), + CSN1Bit(name='nr_of_remaining_cells', bit=4), + CSN1Bit(name='freq_diff_length', bit=3), + CSN1List(num=([2], lambda x: x), list=[ + CSN1Bit(name='frequency_diff', bit=([-1, 3], lambda x: x + 1)), + CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])]) neighbour_cell_params_2_struct = CSN1List(name='neighbour_cell_params_2_struct', list=[ CSN1Val(name='', val='00'), @@ -429,7 +442,15 @@ neighbour_cell_params_2_struct = CSN1List(name='neighbour_cell_params_2_struct', CSN1Ref(obj=ncp2_repeat_struct), CSN1Bit(name='cell_params_pointer', bit=2)]), CSN1Val(name='', val='0'), - CSN1Ref(name='neighbour_parameter_set', obj=neighbour_parameter_set_struct, num=('# unprocessed: (1+max(val(CELL_PARAMS_POINTER)))', lambda: 0))]) + #CSN1Ref(name='neighbour_parameter_set', obj=neighbour_parameter_set_struct, num=('# unprocessed: (1+max(val(CELL_PARAMS_POINTER)))', lambda: 0))]) + CSN1Ref(name='neighbour_parameter_set', obj=neighbour_parameter_set_struct, num=([1], max_cell_params))]) + +iu_mode_neighbour_cell_params_struct = CSN1List(name='iu_mode_neighbour_cell_params_struct', list=[ + CSN1Bit(name='nr_of_remaining_cells', bit=4), + CSN1Alt(num=([0], lambda x: x), alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])})]) psi3_bis_message_content = CSN1List(name='psi3_bis_message_content', trunc=True, list=[ CSN1Bit(name='page_mode', bit=2), diff --git a/pycrate_csn1dir/psi3_message_content.py b/pycrate_csn1dir/psi3_message_content.py index 7bb21b0..1d88b1c 100644 --- a/pycrate_csn1dir/psi3_message_content.py +++ b/pycrate_csn1dir/psi3_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi3_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,8 +32,8 @@ # external references from pycrate_csn1dir.lsa_parameters_ie import lsa_parameters_ie -from pycrate_csn1dir.cell_identification_ie import cell_identification_ie from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.cell_identification_ie import cell_identification_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -42,20 +42,6 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -gen_cell_sel_struct = CSN1List(name='gen_cell_sel_struct', list=[ - CSN1Bit(name='gprs_cell_reselect_hysteresis', bit=3), - CSN1Bit(name='c31_hyst'), - CSN1Bit(name='c32_qual'), - CSN1Val(name='', val='1'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='t_resel', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ra_reselect_hysteresis', bit=3)])})]) - lsa_id_information_struct = CSN1List(name='lsa_id_information_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -73,21 +59,21 @@ si13_pbcch_location_struct = CSN1Alt(name='si13_pbcch_location_struct', alt={ CSN1Bit(name='pbcch_location', bit=2), CSN1Bit(name='psi1_repeat_period', bit=4)])}) -ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) - -iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', list=[ - CSN1Bit(name='cell_bar_qualify_3', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) - hcs_struct = CSN1List(name='hcs_struct', list=[ CSN1Bit(name='priority_class', bit=3), CSN1Bit(name='hcs_thr', bit=5)]) +serving_cell_params_struct = CSN1List(name='serving_cell_params_struct', list=[ + CSN1Bit(name='cell_bar_access_2'), + CSN1Bit(name='exc_acc'), + CSN1Bit(name='gprs_rxlev_access_min', bit=6), + CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='hcs_serving_cell_parameters', obj=hcs_struct)])}), + CSN1Bit(name='multiband_reporting', bit=2)]) + cell_selection_struct = CSN1List(name='cell_selection_struct', list=[ CSN1Bit(name='bsic', bit=6), CSN1Bit(name='cell_bar_access_2'), @@ -125,50 +111,19 @@ neighbour_cell_params_struct = CSN1List(name='neighbour_cell_params_struct', lis CSN1Bit(name='frequency_diff', bit=([-1, 3], lambda x: x + 1)), CSN1Ref(name='cell_selection_params', obj=cell_selection_struct)])]) -iu_mode_only_cell_selection_struct = CSN1List(name='iu_mode_only_cell_selection_struct', list=[ - CSN1Bit(name='bsic', bit=6), - CSN1Bit(name='cell_bar_qualify_3', bit=2), - CSN1Bit(name='same_ra_as_serving_cell'), +gen_cell_sel_struct = CSN1List(name='gen_cell_sel_struct', list=[ + CSN1Bit(name='gprs_cell_reselect_hysteresis', bit=3), + CSN1Bit(name='c31_hyst'), + CSN1Bit(name='c32_qual'), + CSN1Val(name='', val='1'), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='gprs_rxlev_access_min', bit=6), - CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), + CSN1Bit(name='t_resel', bit=3)])}), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='gprs_temporary_offset', bit=3), - CSN1Bit(name='gprs_penalty_time', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='gprs_reselect_offset', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='hcs_params', obj=hcs_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) - -serving_cell_params_struct = CSN1List(name='serving_cell_params_struct', list=[ - CSN1Bit(name='cell_bar_access_2'), - CSN1Bit(name='exc_acc'), - CSN1Bit(name='gprs_rxlev_access_min', bit=6), - CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='hcs_serving_cell_parameters', obj=hcs_struct)])}), - CSN1Bit(name='multiband_reporting', bit=2)]) - -iu_mode_neighbour_cell_params_struct = CSN1List(name='iu_mode_neighbour_cell_params_struct', list=[ - CSN1Bit(name='nr_of_remaining_cells', bit=4), - CSN1Alt(num=([0], lambda x: x), alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])})]) + CSN1Bit(name='ra_reselect_hysteresis', bit=3)])})]) compact_cell_selection_struct = CSN1List(name='compact_cell_selection_struct', list=[ CSN1Bit(name='bsic', bit=6), @@ -202,6 +157,51 @@ compact_cell_selection_struct = CSN1List(name='compact_cell_selection_struct', l '1': ('', [ CSN1Bit(name='guar_constant_pwr_blks', bit=2)])})]) +iu_mode_cell_selection_struct = CSN1List(name='iu_mode_cell_selection_struct', list=[ + CSN1Bit(name='cell_bar_qualify_3', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) + +iu_mode_only_cell_selection_struct = CSN1List(name='iu_mode_only_cell_selection_struct', list=[ + CSN1Bit(name='bsic', bit=6), + CSN1Bit(name='cell_bar_qualify_3', bit=2), + CSN1Bit(name='same_ra_as_serving_cell'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_rxlev_access_min', bit=6), + CSN1Bit(name='gprs_ms_txpwr_max_cch', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_temporary_offset', bit=3), + CSN1Bit(name='gprs_penalty_time', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='gprs_reselect_offset', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='hcs_params', obj=hcs_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='si13alt_pbcch_location', obj=si13_pbcch_location_struct)])})]) + +iu_mode_neighbour_cell_params_struct = CSN1List(name='iu_mode_neighbour_cell_params_struct', list=[ + CSN1Bit(name='nr_of_remaining_cells', bit=4), + CSN1Alt(num=([0], lambda x: x), alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='iu_mode_cell_selection_params', obj=iu_mode_cell_selection_struct)])})]) + +ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) + compact_neighbour_cell_params_struct = CSN1List(name='compact_neighbour_cell_params_struct', list=[ CSN1Bit(name='start_frequency', bit=10), CSN1Ref(name='compact_cell_selection_params', obj=compact_cell_selection_struct), @@ -211,13 +211,6 @@ compact_neighbour_cell_params_struct = CSN1List(name='compact_neighbour_cell_par CSN1Bit(name='frequency_diff', bit=([-1, 3], lambda x: x + 1)), CSN1Ref(name='compact_cell_selection_params', obj=compact_cell_selection_struct)])]) -compact_information_struct = CSN1List(name='compact_information_struct', list=[ - CSN1Ref(name='cell_identification', obj=cell_identification_ie), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(obj=compact_neighbour_cell_params_struct)]), - CSN1Val(name='', val='0')]) - iu_mode_only_neighbour_cell_params_struct = CSN1List(name='iu_mode_only_neighbour_cell_params_struct', list=[ CSN1Bit(name='start_frequency', bit=10), CSN1Ref(name='iu_mode_only_cell_selection_params', obj=iu_mode_only_cell_selection_struct), @@ -227,6 +220,13 @@ iu_mode_only_neighbour_cell_params_struct = CSN1List(name='iu_mode_only_neighbou CSN1Bit(name='frequency_diff', bit=([-1, 3], lambda x: x + 1)), CSN1Ref(name='iu_mode_only_cell_selection_params', obj=iu_mode_only_cell_selection_struct)])]) +compact_information_struct = CSN1List(name='compact_information_struct', list=[ + CSN1Ref(name='cell_identification', obj=cell_identification_ie), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(obj=compact_neighbour_cell_params_struct)]), + CSN1Val(name='', val='0')]) + psi3_message_content = CSN1List(name='psi3_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1Bit(name='psi3_change_mark', bit=2), diff --git a/pycrate_csn1dir/psi3_quater_message_content.py b/pycrate_csn1dir/psi3_quater_message_content.py index 3b4f19f..1ff0d22 100644 --- a/pycrate_csn1dir/psi3_quater_message_content.py +++ b/pycrate_csn1dir/psi3_quater_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi3_quater_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,6 +30,65 @@ # section: 11.2.21b Packet System Information Type 3 quater # top-level object: PSI3 quater message content +# table 9.1.54.1a +_TransP = { + 0 : 0, + 1 : 10, + 2 : 19, + 3 : 28, + 4 : 36, + 5 : 44, + 6 : 52, + 7 : 60, + 8 : 67, + 9 : 74, + 10: 81, + 11: 88, + 12: 95, + 13: 102, + 14: 109, + 15: 116, + 16: 122 + } + +def trans_p(n): + try: + return _TransP[n] + except: + return 0 + +# table 9.1.54.1b +_TransQ = { + 0 : 0, + 1 : 9, + 2 : 17, + 3 : 25, + 4 : 32, + 5 : 39, + 6 : 46, + 7 : 53, + 8 : 59, + 9 : 65, + 10: 71, + 11: 77, + 12: 83, + 13: 89, + 14: 95, + 15: 101, + 16: 106, + 17: 111, + 18: 116, + 19: 121, + 20: 126 + } + +def trans_q(n): + try: + return _TransQ[n] + except: + return 0 + + # external references from pycrate_csn1dir.padding_bits import padding_bits @@ -40,28 +99,21 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -_3g_initial_dedicated_mode_reporting_description_struct = CSN1List(name='_3g_initial_dedicated_mode_reporting_description_struct', list=[ - CSN1Bit(name='_3g_ba_ind'), - CSN1Bit(name='qsearch_i', bit=4), - CSN1Bit(name='qsearch_c_initial'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_qoffset', bit=4), - CSN1Bit(name='fdd_rep_quant'), - CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_qoffset', bit=4), - CSN1Bit(name='tdd_multirat_reporting', bit=2)])})]) - repeated_utran_fdd_neighbour_cells_struct = CSN1List(name='repeated_utran_fdd_neighbour_cells_struct', list=[ CSN1Val(name='', val='0'), CSN1Bit(name='fdd_arfcn', bit=14), CSN1Bit(name='fdd_indic0'), CSN1Bit(name='nr_of_fdd_cells', bit=5), - CSN1Bit(name='fdd__cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) + #CSN1Bit(name='fdd__cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) + CSN1Bit(name='fdd__cell_information_field', bit=([3], trans_p))]) + +repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='tdd_arfcn', bit=14), + CSN1Bit(name='tdd_indic0'), + CSN1Bit(name='nr_of_tdd_cells', bit=5), + #CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) + CSN1Bit(name='tdd_cell_information_field', bit=([3], trans_q))]) utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ CSN1Alt(alt={ @@ -73,6 +125,20 @@ utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', lis CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), CSN1Val(name='', val='0')]) +gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) + +utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_tdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) + _3g_measurement_parameters_description_struct = CSN1List(name='_3g_measurement_parameters_description_struct', list=[ CSN1Bit(name='qsearch_p', bit=4), CSN1Val(name='', val='1'), @@ -91,31 +157,26 @@ gprs_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='g '1': ('', [ CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) -gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) +_3g_initial_dedicated_mode_reporting_description_struct = CSN1List(name='_3g_initial_dedicated_mode_reporting_description_struct', list=[ + CSN1Bit(name='_3g_ba_ind'), + CSN1Bit(name='qsearch_i', bit=4), + CSN1Bit(name='qsearch_c_initial'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_qoffset', bit=4), + CSN1Bit(name='fdd_rep_quant'), + CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_qoffset', bit=4), + CSN1Bit(name='tdd_multirat_reporting', bit=2)])})]) gprs_3g_additional_measurement_parameters_description_struct = CSN1List(name='gprs_3g_additional_measurement_parameters_description_struct', list=[ CSN1Bit(name='fdd_qmin_offset', bit=3), CSN1Bit(name='fdd_rscpmin', bit=4)]) -repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='tdd_arfcn', bit=14), - CSN1Bit(name='tdd_indic0'), - CSN1Bit(name='nr_of_tdd_cells', bit=5), - CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) - -utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_tdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - _3g_neighbour_cells_description_struct = CSN1List(name='_3g_neighbour_cells_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/psi3_ter_message_content.py b/pycrate_csn1dir/psi3_ter_message_content.py index 7ea83eb..7f73284 100644 --- a/pycrate_csn1dir/psi3_ter_message_content.py +++ b/pycrate_csn1dir/psi3_ter_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi3_ter_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -40,15 +40,15 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * -gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) - rtd12_struct = CSN1Alt(name='rtd12_struct', alt={ '0': ('', []), '1': ('', [ CSN1Bit(name='rtd', bit=12)])}) +gprs_rep_priority_description_struct = CSN1List(name='gprs_rep_priority_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) + rtd6_struct = CSN1Alt(name='rtd6_struct', alt={ '0': ('', []), '1': ('', [ diff --git a/pycrate_csn1dir/psi5_message_content.py b/pycrate_csn1dir/psi5_message_content.py index 433618f..6757945 100644 --- a/pycrate_csn1dir/psi5_message_content.py +++ b/pycrate_csn1dir/psi5_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi5_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: PSI5 message content # external references -from pycrate_csn1dir.packet_cell_change_order_message_content import gprs_3g_additional_measurement_parameters_description_2_struct from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.packet_cell_change_order_message_content import gprs_3g_additional_measurement_parameters_description_2_struct # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -41,6 +41,15 @@ from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1.csnobj import * +nc_measurement_parameters_struct = CSN1List(name='nc_measurement_parameters_struct', list=[ + CSN1Bit(name='network_control_order', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='nc__non_drx_period', bit=3), + CSN1Bit(name='nc_reporting_period_i', bit=3), + CSN1Bit(name='nc_reporting_period_t', bit=3)])})]) + gprs_3g_additional_measurement_parameters_2_struct = CSN1Alt(name='gprs_3g_additional_measurement_parameters_2_struct', alt={ '0': ('', []), '1': ('', [ @@ -67,15 +76,6 @@ gprs_3g_measurement_parameters_description_struct = CSN1List(name='gprs_3g_measu CSN1Bit(name='tdd_reporting_offset', bit=3), CSN1Bit(name='tdd_reporting_threshold', bit=3)])})]) -nc_measurement_parameters_struct = CSN1List(name='nc_measurement_parameters_struct', list=[ - CSN1Bit(name='network_control_order', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='nc__non_drx_period', bit=3), - CSN1Bit(name='nc_reporting_period_i', bit=3), - CSN1Bit(name='nc_reporting_period_t', bit=3)])})]) - gprs_measurement_parameters_description_struct = CSN1List(name='gprs_measurement_parameters_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/psi6_message_content.py b/pycrate_csn1dir/psi6_message_content.py index eab19b8..40a3275 100644 --- a/pycrate_csn1dir/psi6_message_content.py +++ b/pycrate_csn1dir/psi6_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi6_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: PSI6 message content # external references -from pycrate_csn1dir.si_18_rest_octets import non_gsm_message_struct from pycrate_csn1dir.padding_bits import padding_bits +from pycrate_csn1dir.si_18_rest_octets import non_gsm_message_struct # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -45,6 +45,11 @@ spare_bit = CSN1Bit(name='spare_bit') Spare_bit = spare_bit Spare_Bit = spare_bit +nongsm_message_struct = CSN1List(name='nongsm_message_struct', list=[ + CSN1Bit(name='nongsm_protocol_discriminator', bit=3), + CSN1Bit(name='nr_of_container_octets', bit=5, excl=['00000']), + CSN1Bit(name='container', bit=8, num=([1], lambda x: x))]) + psi6_message_content = CSN1List(name='psi6_message_content', list=[ CSN1Bit(name='page_mode', bit=2), CSN1Bit(name='psi6_change_mark', bit=2), @@ -55,8 +60,3 @@ psi6_message_content = CSN1List(name='psi6_message_content', list=[ CSN1Ref(obj=spare_bit, num=300000), CSN1Ref(obj=padding_bits)])]) -nongsm_message_struct = CSN1List(name='nongsm_message_struct', list=[ - CSN1Bit(name='nongsm_protocol_discriminator', bit=3), - CSN1Bit(name='nr_of_container_octets', bit=5, excl=['00000']), - CSN1Bit(name='container', bit=8, num=([1], lambda x: x))]) - diff --git a/pycrate_csn1dir/psi8_message_content.py b/pycrate_csn1dir/psi8_message_content.py index a6aa566..3144737 100644 --- a/pycrate_csn1dir/psi8_message_content.py +++ b/pycrate_csn1dir/psi8_message_content.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/psi8_message_content.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: PSI8 message content # external references -from pycrate_csn1dir.padding_bits import padding_bits from pycrate_csn1dir.frequency_parameters_ie import frequency_parameters_ie +from pycrate_csn1dir.padding_bits import padding_bits # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/pulse_format_ie.py b/pycrate_csn1dir/pulse_format_ie.py index 0e94d54..29bc50a 100644 --- a/pycrate_csn1dir/pulse_format_ie.py +++ b/pycrate_csn1dir/pulse_format_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/pulse_format_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -47,12 +47,6 @@ pulse_format_coding_2_struct = CSN1Alt(name='pulse_format_coding_2_struct', alt= '1': ('', [ CSN1Val(name='non_hopping_carrier_pulse_format', val='00')])}) -pulse_format_ie = CSN1Alt(name='pulse_format_ie', alt={ - '0': ('', [ - CSN1Bit(name='pulse_format_coding_1', bit=3)]), - '1': ('', [ - CSN1Ref(name='pulse_format_coding_2', obj=pulse_format_coding_2_struct)])}) - dlmc_indirect_encoding_struct = CSN1List(name='dlmc_indirect_encoding_struct', list=[ CSN1Bit(name='ma_number', bit=4), CSN1Alt(alt={ @@ -69,6 +63,12 @@ dlmc_direct_encoding_2_struct = CSN1List(name='dlmc_direct_encoding_2_struct', l CSN1Bit(name='length_of_ma_frequency_list_contents', bit=4), CSN1Bit(name='ma_frequency_list_contents', bit=8, num=([1], lambda x: x + 3))]) +pulse_format_ie = CSN1Alt(name='pulse_format_ie', alt={ + '0': ('', [ + CSN1Bit(name='pulse_format_coding_1', bit=3)]), + '1': ('', [ + CSN1Ref(name='pulse_format_coding_2', obj=pulse_format_coding_2_struct)])}) + dlmc_direct_encoding_1_struct = CSN1Ref(name='dlmc_direct_encoding_1_struct', obj=gprs_mobile_allocation_ie) dlmc_frequency_parameters_ie = CSN1List(name='dlmc_frequency_parameters_ie', list=[ diff --git a/pycrate_csn1dir/receive_npdu_number_list_value.py b/pycrate_csn1dir/receive_npdu_number_list_value.py index 6317be9..70e066f 100644 --- a/pycrate_csn1dir/receive_npdu_number_list_value.py +++ b/pycrate_csn1dir/receive_npdu_number_list_value.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/receive_npdu_number_list_value.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -39,9 +39,17 @@ from pycrate_csn1.csnobj import * -receive_npdu_number_value = CSN1Alt(name='receive_npdu_number_value', num=8, alt={ - '0': ('', []), - '1': ('', [])}) +padding_bits = CSN1Alt(name='padding_bits', alt={ + '0000': ('', []), + None: ('', [])}) + +receive_npdu_number_list = CSN1List(name='receive_npdu_number_list', list=[ + CSN1Bit(name='sapi', bit=4), + CSN1Bit(name='receive_npdu_number_value', bit=8), + CSN1Alt(alt={ + '': ('', [ + CSN1SelfRef()]), + None: ('', [])})]) nsapi = CSN1Alt(name='nsapi', alt={ '0101': ('', []), @@ -56,17 +64,9 @@ nsapi = CSN1Alt(name='nsapi', alt={ '1110': ('', []), '1111': ('', [])}) -padding_bits = CSN1Alt(name='padding_bits', alt={ - '0000': ('', []), - None: ('', [])}) - -receive_npdu_number_list = CSN1List(name='receive_npdu_number_list', list=[ - CSN1Bit(name='sapi', bit=4), - CSN1Bit(name='receive_npdu_number_value', bit=8), - CSN1Alt(alt={ - '': ('', [ - CSN1SelfRef()]), - None: ('', [])})]) +receive_npdu_number_value = CSN1Alt(name='receive_npdu_number_value', num=8, alt={ + '0': ('', []), + '1': ('', [])}) receive_npdu_number_list_value = CSN1List(name='receive_npdu_number_list_value', list=[ CSN1Ref(obj=receive_npdu_number_list), diff --git a/pycrate_csn1dir/restriction_timer_value_part.py b/pycrate_csn1dir/restriction_timer_value_part.py index a72bdca..d4da8bb 100644 --- a/pycrate_csn1dir/restriction_timer_value_part.py +++ b/pycrate_csn1dir/restriction_timer_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/restriction_timer_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/rr_packet_downlink_assignment_type_2_value_part.py b/pycrate_csn1dir/rr_packet_downlink_assignment_type_2_value_part.py index e99929b..c0f56e8 100644 --- a/pycrate_csn1dir/rr_packet_downlink_assignment_type_2_value_part.py +++ b/pycrate_csn1dir/rr_packet_downlink_assignment_type_2_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/rr_packet_downlink_assignment_type_2_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,8 +32,8 @@ # external references from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -46,6 +46,23 @@ spare_bit = CSN1Bit(name='spare_bit') Spare_bit = spare_bit Spare_Bit = spare_bit +additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ + CSN1Bit(name='downlink_tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Bit(name='pfi', bit=7)]) + +rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ + CSN1Bit(name='downlink_tfi_assignment', bit=5), + CSN1Bit(name='rlc_mode'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='pfi', bit=7)]) + downlink_tbf_assignment_2_struct = CSN1List(name='downlink_tbf_assignment_2_struct', list=[ CSN1Bit(name='pfi', bit=7), CSN1Bit(name='rlc_mode'), @@ -61,13 +78,12 @@ downlink_tbf_assignment_2_struct = CSN1List(name='downlink_tbf_assignment_2_stru '1': ('', [ CSN1Ref(name='downlink_egprs_window_size', obj=egprs_window_size_ie)])})]) -additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ - CSN1Bit(name='downlink_tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Bit(name='pfi', bit=7)]) +rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downlink_assignment_dc_struct', list=[ + CSN1Bit(name='rtti_downlink_pdch_pair_assignment_dc', bit=8), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), + CSN1Val(name='', val='0')]) btti_multiple_downlink_assignment_struct = CSN1List(name='btti_multiple_downlink_assignment_struct', list=[ CSN1Alt(alt={ @@ -87,22 +103,6 @@ btti_multiple_downlink_assignment_struct = CSN1List(name='btti_multiple_downlink CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), CSN1Val(name='', val='0')]) -rtti_multiple_downlink_assignment_dc_struct = CSN1List(name='rtti_multiple_downlink_assignment_dc_struct', list=[ - CSN1Bit(name='rtti_downlink_pdch_pair_assignment_dc', bit=8), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_2_struct)]), - CSN1Val(name='', val='0')]) - -rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ - CSN1Bit(name='downlink_tfi_assignment', bit=5), - CSN1Bit(name='rlc_mode'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='pfi', bit=7)]) - rtti_multiple_downlink_assignment_sc_struct = CSN1List(name='rtti_multiple_downlink_assignment_sc_struct', list=[ CSN1Bit(name='rtti_downlink_pdch_pair_assignment_sc', bit=4), CSN1List(num=-1, list=[ diff --git a/pycrate_csn1dir/rr_packet_downlink_assignment_value_part.py b/pycrate_csn1dir/rr_packet_downlink_assignment_value_part.py index 2e1bcc1..62031af 100644 --- a/pycrate_csn1dir/rr_packet_downlink_assignment_value_part.py +++ b/pycrate_csn1dir/rr_packet_downlink_assignment_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/rr_packet_downlink_assignment_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,10 +31,10 @@ # top-level object: RR Packet Downlink Assignment value part # external references -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie from pycrate_csn1dir.power_control_parameters_ie import power_control_parameters_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -47,23 +47,6 @@ spare_bit = CSN1Bit(name='spare_bit') Spare_bit = spare_bit Spare_Bit = spare_bit -additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ - CSN1Bit(name='downlink_tfi_assignment', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='npm_transfer_time', bit=5)])}), - CSN1Bit(name='pfi', bit=7)]) - -rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ - CSN1Bit(name='downlink_tfi_assignment', bit=5), - CSN1Bit(name='rlc_mode'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), - CSN1Bit(name='pfi', bit=7)]) - downlink_tbf_assignment_struct = CSN1List(name='downlink_tbf_assignment_struct', list=[ CSN1Bit(name='pfi', bit=7), CSN1Bit(name='rlc_mode'), @@ -85,6 +68,23 @@ multiple_downlink_tbf_assignment_struct = CSN1List(name='multiple_downlink_tbf_a CSN1Ref(name='downlink_tbf_assignment', obj=downlink_tbf_assignment_struct)]), CSN1Val(name='', val='0')]) +rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ + CSN1Bit(name='downlink_tfi_assignment', bit=5), + CSN1Bit(name='rlc_mode'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='egprs_window_size', obj=egprs_window_size_ie)])}), + CSN1Bit(name='pfi', bit=7)]) + +additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ + CSN1Bit(name='downlink_tfi_assignment', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='npm_transfer_time', bit=5)])}), + CSN1Bit(name='pfi', bit=7)]) + rr_packet_downlink_assignment_value_part = CSN1List(name='rr_packet_downlink_assignment_value_part', list=[ CSN1Bit(name='mac_mode', bit=2), CSN1Bit(name='rlc_mode'), diff --git a/pycrate_csn1dir/rr_packet_uplink_assignment_value_part.py b/pycrate_csn1dir/rr_packet_uplink_assignment_value_part.py index dd06907..3496c0d 100644 --- a/pycrate_csn1dir/rr_packet_uplink_assignment_value_part.py +++ b/pycrate_csn1dir/rr_packet_uplink_assignment_value_part.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/rr_packet_uplink_assignment_value_part.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,11 +32,11 @@ # external references from pycrate_csn1dir.pulse_format_ie import pulse_format_ie -from pycrate_csn1dir.packet_uplink_assignment_message_content import extension +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie from pycrate_csn1dir.packet_timing_advance_ie import packet_timing_advance_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.packet_uplink_assignment_message_content import extension from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -49,6 +49,83 @@ spare_bit = CSN1Bit(name='spare_bit') Spare_bit = spare_bit Spare_Bit = spare_bit +timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ + '0': ('', [ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity')])})]), + '1': ('', [ + CSN1Bit(name='alpha', bit=4), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn0', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn1', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn2', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn3', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn4', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn5', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn6', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='usf_granularity'), + CSN1Bit(name='gamma_tn7', bit=5)])})])}) + rlc_entity_struct = CSN1List(name='rlc_entity_struct', list=[ CSN1Bit(name='uplink_tfi_assignment', bit=5), CSN1Bit(name='rlc_mode'), @@ -186,83 +263,6 @@ additional_pfcs_struct = CSN1List(name='additional_pfcs_struct', list=[ CSN1Bit(name='npm_transfer_time', bit=5)])}), CSN1Bit(name='pfi', bit=7)]) -timeslot_description_struct = CSN1Alt(name='timeslot_description_struct', alt={ - '0': ('', [ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity')])})]), - '1': ('', [ - CSN1Bit(name='alpha', bit=4), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn0', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn1', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn2', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn3', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn4', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn5', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn6', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='usf_granularity'), - CSN1Bit(name='gamma_tn7', bit=5)])})])}) - multiple_tbf_allocation_struct = CSN1List(name='multiple_tbf_allocation_struct', list=[ CSN1Bit(name='extended_dynamic_allocation'), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/rrc_container_ie.py b/pycrate_csn1dir/rrc_container_ie.py index 860a597..62d7ae1 100644 --- a/pycrate_csn1dir/rrc_container_ie.py +++ b/pycrate_csn1dir/rrc_container_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/rrc_container_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si10_rest_octets.py b/pycrate_csn1dir/si10_rest_octets.py index 97a6a40..2a6c9e8 100644 --- a/pycrate_csn1dir/si10_rest_octets.py +++ b/pycrate_csn1dir/si10_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si10_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,13 +43,21 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -next_frequency = CSN1Val(name='next_frequency', val='H') - la_different = CSN1Alt(name='la_different', alt={ 'H': ('', [ CSN1Bit(name='cell_reselect_hysteresis', bit=3)]), 'L': ('', [])}) +next_frequency = CSN1Val(name='next_frequency', val='H') + +further_cell_info = CSN1List(name='further_cell_info', list=[ + CSN1Ref(obj=la_different), + CSN1Bit(name='ms_txpwr_max_cch', bit=5), + CSN1Bit(name='rxlev_access_min', bit=6), + CSN1Bit(name='cell_reselect_offset', bit=6), + CSN1Bit(name='temporary_offset', bit=3), + CSN1Bit(name='penalty_time', bit=5)]) + further_diff_cell_info = CSN1List(name='further_diff_cell_info', list=[ CSN1Ref(obj=la_different), CSN1Alt(alt={ @@ -73,14 +81,6 @@ further_diff_cell_info = CSN1List(name='further_diff_cell_info', list=[ CSN1Bit(name='penalty_time', bit=5)]), 'L': ('', [])})]) -further_cell_info = CSN1List(name='further_cell_info', list=[ - CSN1Ref(obj=la_different), - CSN1Bit(name='ms_txpwr_max_cch', bit=5), - CSN1Bit(name='rxlev_access_min', bit=6), - CSN1Bit(name='cell_reselect_offset', bit=6), - CSN1Bit(name='temporary_offset', bit=3), - CSN1Bit(name='penalty_time', bit=5)]) - diff_cell_pars = CSN1Alt(name='diff_cell_pars', alt={ 'H': ('cell_barred', []), 'L': ('', [ @@ -91,13 +91,6 @@ cell_parameters = CSN1Alt(name='cell_parameters', alt={ 'L': ('', [ CSN1Ref(obj=further_cell_info)])}) -cell_info = CSN1List(name='cell_info', list=[ - CSN1Bit(name='bsic', bit=6), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Ref(obj=cell_parameters)]), - 'L': ('', [])})]) - differential_cell_info = CSN1List(name='differential_cell_info', list=[ CSN1Alt(alt={ 'H': ('', [ @@ -109,6 +102,13 @@ differential_cell_info = CSN1List(name='differential_cell_info', list=[ CSN1Ref(obj=diff_cell_pars)]), 'L': ('', [])})]) +cell_info = CSN1List(name='cell_info', list=[ + CSN1Bit(name='bsic', bit=6), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Ref(obj=cell_parameters)]), + 'L': ('', [])})]) + info_field = CSN1List(name='info_field', list=[ CSN1Ref(obj=next_frequency, num=-1), CSN1Val(name='', val='L'), diff --git a/pycrate_csn1dir/si10bis_rest_octets.py b/pycrate_csn1dir/si10bis_rest_octets.py index 0eefdca..8b8ed8f 100644 --- a/pycrate_csn1dir/si10bis_rest_octets.py +++ b/pycrate_csn1dir/si10bis_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si10bis_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si14_rest_octets.py b/pycrate_csn1dir/si14_rest_octets.py index 67ed9a4..84408d0 100644 --- a/pycrate_csn1dir/si14_rest_octets.py +++ b/pycrate_csn1dir/si14_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si14_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si15_rest_octets.py b/pycrate_csn1dir/si15_rest_octets.py index f6f330c..c1f6d51 100644 --- a/pycrate_csn1dir/si15_rest_octets.py +++ b/pycrate_csn1dir/si15_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si15_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si16_rest_octets.py b/pycrate_csn1dir/si16_rest_octets.py index 8a9b3b7..b72c632 100644 --- a/pycrate_csn1dir/si16_rest_octets.py +++ b/pycrate_csn1dir/si16_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si16_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si1_rest_octets.py b/pycrate_csn1dir/si1_rest_octets.py index 41c846c..1bfd793 100644 --- a/pycrate_csn1dir/si1_rest_octets.py +++ b/pycrate_csn1dir/si1_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si1_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si2bis_rest_octets.py b/pycrate_csn1dir/si2bis_rest_octets.py index 9570223..6565b85 100644 --- a/pycrate_csn1dir/si2bis_rest_octets.py +++ b/pycrate_csn1dir/si2bis_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si2bis_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si2n_rest_octets.py b/pycrate_csn1dir/si2n_rest_octets.py index a0264a9..770ebeb 100644 --- a/pycrate_csn1dir/si2n_rest_octets.py +++ b/pycrate_csn1dir/si2n_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si2n_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si2quater_rest_octets.py b/pycrate_csn1dir/si2quater_rest_octets.py index 504ca8f..146fecb 100644 --- a/pycrate_csn1dir/si2quater_rest_octets.py +++ b/pycrate_csn1dir/si2quater_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si2quater_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -30,6 +30,65 @@ # section: 10.5.2.33b SI 2quater Rest Octets # top-level object: SI2quater Rest Octets +# table 9.1.54.1a +_TransP = { + 0 : 0, + 1 : 10, + 2 : 19, + 3 : 28, + 4 : 36, + 5 : 44, + 6 : 52, + 7 : 60, + 8 : 67, + 9 : 74, + 10: 81, + 11: 88, + 12: 95, + 13: 102, + 14: 109, + 15: 116, + 16: 122 + } + +def trans_p(n): + try: + return _TransP[n] + except: + return 0 + +# table 9.1.54.1b +_TransQ = { + 0 : 0, + 1 : 9, + 2 : 17, + 3 : 25, + 4 : 32, + 5 : 39, + 6 : 46, + 7 : 53, + 8 : 59, + 9 : 65, + 10: 71, + 11: 77, + 12: 83, + 13: 89, + 14: 95, + 15: 101, + 16: 106, + 17: 111, + 18: 116, + 19: 121, + 20: 126 + } + +def trans_q(n): + try: + return _TransQ[n] + except: + return 0 + + # external references from pycrate_csn1dir.pcid_group_ie import pcid_group_ie from pycrate_csn1dir.enhanced_cell_reselection_parameters_ie import enhanced_cell_reselection_parameters_ie @@ -50,166 +109,6 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -extended_earfcns_description_for_csg_cells_struct = CSN1List(name='extended_earfcns_description_for_csg_cells_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='csg_earfcn_extended', bit=18)]), - CSN1Val(name='', val='0')]) - -measurement_parameters_description_struct = CSN1List(name='measurement_parameters_description_struct', list=[ - CSN1Bit(name='report_type'), - CSN1Bit(name='serving_band_reporting', bit=2)]) - -gprs_report_priority_description_struct = CSN1List(name='gprs_report_priority_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) - -extended_earfcns_description_struct = CSN1List(name='extended_earfcns_description_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='earfcn_extended', bit=18)]), - CSN1Val(name='', val='0')]) - -repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='tdd_arfcn', bit=14), - CSN1Bit(name='tdd_indic0'), - CSN1Bit(name='nr_of_tdd_cells', bit=5), - CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) - -utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_tdd', bit=3)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), - CSN1Val(name='', val='0')]) - -repeated_utran_fdd_neighbour_cells_struct = CSN1List(name='repeated_utran_fdd_neighbour_cells_struct', list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='fdd_arfcn', bit=14), - CSN1Bit(name='fdd_indic0'), - CSN1Bit(name='nr_of_fdd_cells', bit=5), - CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) - -e_utran_csg_cells_reporting_description_struct = CSN1List(name='e_utran_csg_cells_reporting_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_csg_fdd_reporting_threshold', bit=3), - CSN1Bit(name='e_utran_csg_fdd_reporting_threshold_2', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_csg_tdd_reporting_threshold', bit=3), - CSN1Bit(name='e_utran_csg_fdd_reporting_threshold_2', bit=6)])})]) - -ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ - CSN1Bit(name='number_cells', bit=7), - CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) - -utran_csg_cells_reporting_description_struct = CSN1List(name='utran_csg_cells_reporting_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='utran_csg_fdd_reporting_threshold', bit=3), - CSN1Bit(name='utran_csg_fdd_reporting_threshold_2', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='utran_csg_tdd_reporting_threshold', bit=3)])})]) - -gprs_3g_measurement_parameters_description_struct = CSN1List(name='gprs_3g_measurement_parameters_description_struct', list=[ - CSN1Bit(name='qsearch_p', bit=4), - CSN1Val(name='', val='1'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_rep_quant'), - CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_reporting_offset', bit=3), - CSN1Bit(name='fdd_reporting_threshold', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_multirat_reporting', bit=2)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_reporting_offset', bit=3), - CSN1Bit(name='tdd_reporting_threshold', bit=3)])})]) - -_3g_measurement_parameters_description_struct = CSN1List(name='_3g_measurement_parameters_description_struct', list=[ - CSN1Bit(name='qsearch_i', bit=4), - CSN1Bit(name='qsearch_c_initial'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_qoffset', bit=4), - CSN1Bit(name='fdd_rep_quant'), - CSN1Bit(name='fdd_multirat_reporting', bit=2), - CSN1Bit(name='fdd_qmin', bit=3)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='tdd_qoffset', bit=4), - CSN1Bit(name='tdd_multirat_reporting', bit=2)])})]) - -rtd6_struct = CSN1List(name='rtd6_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='rtd', bit=6)]), - CSN1Val(name='', val='1')]) - -_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='_3g_additional_measurement_parameters_description_2_struct', alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) - -csg_cells_reporting_description_struct = CSN1List(name='csg_cells_reporting_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='utran_csg_cells_reporting_description', obj=utran_csg_cells_reporting_description_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='e_utran_csg_cells_reporting_description', obj=e_utran_csg_cells_reporting_description_struct)])})]) - -gprs_e_utran_measurement_parameters_description_struct = CSN1List(name='gprs_e_utran_measurement_parameters_description_struct', list=[ - CSN1Bit(name='qsearch_p_e_utran', bit=4), - CSN1Bit(name='e_utran_rep_quant'), - CSN1Bit(name='e_utran_multirat_reporting', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_fdd_reporting_threshold', bit=3), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_fdd_reporting_threshold_2', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_fdd_reporting_offset', bit=3)])})])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_tdd_reporting_threshold', bit=3), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_tdd_reporting_threshold_2', bit=6)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='e_utran_tdd_reporting_offset', bit=3)])})])})]) - repeated_utran_priority_parameters_struct = CSN1List(name='repeated_utran_priority_parameters_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -229,16 +128,14 @@ repeated_utran_priority_parameters_struct = CSN1List(name='repeated_utran_priori '1': ('', [ CSN1Bit(name='utran_qrxlevmin', bit=5)])})]) -_3g_additional_measurement_parameters_description_struct = CSN1List(name='_3g_additional_measurement_parameters_description_struct', list=[ - CSN1Bit(name='fdd_qmin_offset', bit=3), - CSN1Bit(name='fdd_rscpmin', bit=4)]) - -si2q_extension_information = CSN1List(name='si2q_extension_information', list=[ +nc_measurement_parameters_struct = CSN1List(name='nc_measurement_parameters_struct', list=[ + CSN1Bit(name='network_control_order', bit=2), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Ref(name='ccn_support_description', obj=ccn_support_description_struct)])}), - CSN1Ref(obj=spare_bit, num=-1)]) + CSN1Bit(name='nc__non_drx_period', bit=3), + CSN1Bit(name='nc_reporting_period_i', bit=3), + CSN1Bit(name='nc_reporting_period_t', bit=3)])})]) e_utran_measurement_parameters_description_struct = CSN1List(name='e_utran_measurement_parameters_description_struct', list=[ CSN1Bit(name='qsearch_c_e_utran_initial', bit=4), @@ -297,6 +194,39 @@ e_utran_measurement_parameters_description_struct = CSN1List(name='e_utran_measu CSN1Bit(name='e_utran_tdd_reporting_offset', bit=3)])})])}), CSN1Bit(name='reporting_granularity')])})]) +_3g_additional_measurement_parameters_description_2_struct = CSN1Alt(name='_3g_additional_measurement_parameters_description_2_struct', alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_reporting_threshold_2', bit=6)])}) + +extended_earfcns_description_for_csg_cells_struct = CSN1List(name='extended_earfcns_description_for_csg_cells_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='csg_earfcn_extended', bit=18)]), + CSN1Val(name='', val='0')]) + +_3g_priority_parameters_description_struct = CSN1List(name='_3g_priority_parameters_description_struct', list=[ + CSN1Bit(name='utran_start'), + CSN1Bit(name='utran_stop'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='default_utran_priority', bit=3), + CSN1Bit(name='default_thresh_utran', bit=5), + CSN1Bit(name='default_utran_qrxlevmin', bit=5)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_priority_parameters', obj=repeated_utran_priority_parameters_struct)]), + CSN1Val(name='', val='0')]) + +repeated_utran_fdd_neighbour_cells_struct = CSN1List(name='repeated_utran_fdd_neighbour_cells_struct', list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='fdd_arfcn', bit=14), + CSN1Bit(name='fdd_indic0'), + CSN1Bit(name='nr_of_fdd_cells', bit=5), + #CSN1Bit(name='fdd_cell_information_field', bit=('# unprocessed: (p(NR_OF_FDD_CELLS))', lambda: 0))]) + CSN1Bit(name='fdd_cell_information_field', bit=([3], trans_p))]) + repeated_e_utran_not_allowed_cells_struct = CSN1List(name='repeated_e_utran_not_allowed_cells_struct', list=[ CSN1Ref(name='not_allowed_cells', obj=pcid_group_ie), CSN1List(num=-1, list=[ @@ -304,63 +234,24 @@ repeated_e_utran_not_allowed_cells_struct = CSN1List(name='repeated_e_utran_not_ CSN1Bit(name='e_utran_frequency_index', bit=3)]), CSN1Val(name='', val='0')]) -gprs_bsic_description_struct = CSN1List(name='gprs_bsic_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='ba_index_start_bsic', bit=5)])}), - CSN1Bit(name='bsic', bit=6), - CSN1Bit(name='number_remaining_bsic', bit=7), - CSN1List(num=([2], lambda x: x), list=[ - CSN1Bit(name='frequency_scrolling'), - CSN1Bit(name='bsic', bit=6)])]) - -e_utran_csg_description_struct = CSN1List(name='e_utran_csg_description_struct', list=[ +_3g_csg_description_struct = CSN1List(name='_3g_csg_description_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Ref(name='csg_pci_split', obj=pcid_group_ie), + CSN1Ref(name='csg_psc_split', obj=psc_group_ie), CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Bit(name='e_utran_frequency_index', bit=3)]), + CSN1Bit(name='utran_frequency_index', bit=5)]), CSN1Val(name='', val='0')]), CSN1Val(name='', val='0'), CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Bit(name='csg_earfcn', bit=16)]), + CSN1Alt(alt={ + '0': ('', [ + CSN1Bit(name='csg_fdd_uarfcn', bit=14)]), + '1': ('', [ + CSN1Bit(name='csg_tdd_uarfcn', bit=14)])})]), CSN1Val(name='', val='0')]) -repeated_e_utran_pcid_to_ta_mapping_struct = CSN1List(name='repeated_e_utran_pcid_to_ta_mapping_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='pcid_to_ta_mapping', obj=pcid_group_ie)]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='e_utran_frequency_index', bit=3)]), - CSN1Val(name='', val='0')]) - -rtd12_struct = CSN1List(name='rtd12_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='0'), - CSN1Bit(name='rtd', bit=12)]), - CSN1Val(name='', val='1')]) - -serving_cell_priority_parameters_description_struct = CSN1List(name='serving_cell_priority_parameters_description_struct', list=[ - CSN1Bit(name='geran_priority', bit=3), - CSN1Bit(name='thresh_priority_search', bit=4), - CSN1Bit(name='thresh_gsm_low', bit=4), - CSN1Bit(name='h_prio', bit=2), - CSN1Bit(name='t_reselection', bit=2)]) - -nc_measurement_parameters_struct = CSN1List(name='nc_measurement_parameters_struct', list=[ - CSN1Bit(name='network_control_order', bit=2), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='nc__non_drx_period', bit=3), - CSN1Bit(name='nc_reporting_period_i', bit=3), - CSN1Bit(name='nc_reporting_period_t', bit=3)])})]) - gprs_measurement_parameters_description_struct = CSN1List(name='gprs_measurement_parameters_description_struct', list=[ CSN1Bit(name='report_type'), CSN1Bit(name='reporting_rate'), @@ -400,24 +291,57 @@ gprs_measurement_parameters_description_struct = CSN1List(name='gprs_measurement CSN1Bit(name='_850_reporting_offset', bit=3), CSN1Bit(name='_850_reporting_threshold', bit=3)])})]) -_3g_csg_description_struct = CSN1List(name='_3g_csg_description_struct', list=[ +utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_fdd', bit=3)])}), CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Ref(name='csg_psc_split', obj=psc_group_ie), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='utran_frequency_index', bit=5)]), - CSN1Val(name='', val='0')]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Alt(alt={ - '0': ('', [ - CSN1Bit(name='csg_fdd_uarfcn', bit=14)]), - '1': ('', [ - CSN1Bit(name='csg_tdd_uarfcn', bit=14)])})]), + CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), CSN1Val(name='', val='0')]) +e_utran_csg_cells_reporting_description_struct = CSN1List(name='e_utran_csg_cells_reporting_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_csg_fdd_reporting_threshold', bit=3), + CSN1Bit(name='e_utran_csg_fdd_reporting_threshold_2', bit=6)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_csg_tdd_reporting_threshold', bit=3), + CSN1Bit(name='e_utran_csg_fdd_reporting_threshold_2', bit=6)])})]) + +gprs_e_utran_measurement_parameters_description_struct = CSN1List(name='gprs_e_utran_measurement_parameters_description_struct', list=[ + CSN1Bit(name='qsearch_p_e_utran', bit=4), + CSN1Bit(name='e_utran_rep_quant'), + CSN1Bit(name='e_utran_multirat_reporting', bit=2), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_fdd_reporting_threshold', bit=3), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_fdd_reporting_threshold_2', bit=6)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_fdd_reporting_offset', bit=3)])})])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_tdd_reporting_threshold', bit=3), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_tdd_reporting_threshold_2', bit=6)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='e_utran_tdd_reporting_offset', bit=3)])})])})]) + repeated_e_utran_neighbour_cells_struct = CSN1List(name='repeated_e_utran_neighbour_cells_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -441,16 +365,210 @@ repeated_e_utran_neighbour_cells_struct = CSN1List(name='repeated_e_utran_neighb '1': ('', [ CSN1Bit(name='e_utran_qrxlevmin', bit=5)])})]) -utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ +serving_cell_priority_parameters_description_struct = CSN1List(name='serving_cell_priority_parameters_description_struct', list=[ + CSN1Bit(name='geran_priority', bit=3), + CSN1Bit(name='thresh_priority_search', bit=4), + CSN1Bit(name='thresh_gsm_low', bit=4), + CSN1Bit(name='h_prio', bit=2), + CSN1Bit(name='t_reselection', bit=2)]) + +rtd12_struct = CSN1List(name='rtd12_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='rtd', bit=12)]), + CSN1Val(name='', val='1')]) + +repeated_utran_tdd_neighbour_cells_struct = CSN1List(name='repeated_utran_tdd_neighbour_cells_struct', list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='tdd_arfcn', bit=14), + CSN1Bit(name='tdd_indic0'), + CSN1Bit(name='nr_of_tdd_cells', bit=5), + #CSN1Bit(name='tdd_cell_information_field', bit=('# unprocessed: (q(NR_OF_TDD_CELLS))', lambda: 0))]) + CSN1Bit(name='tdd_cell_information_field', bit=([3], trans_q))]) + +repeated_e_utran_pcid_to_ta_mapping_struct = CSN1List(name='repeated_e_utran_pcid_to_ta_mapping_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='pcid_to_ta_mapping', obj=pcid_group_ie)]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='e_utran_frequency_index', bit=3)]), + CSN1Val(name='', val='0')]) + +_3g_additional_measurement_parameters_description_struct = CSN1List(name='_3g_additional_measurement_parameters_description_struct', list=[ + CSN1Bit(name='fdd_qmin_offset', bit=3), + CSN1Bit(name='fdd_rscpmin', bit=4)]) + +ccn_support_description_struct = CSN1List(name='ccn_support_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='ccn_supported', num=([0], lambda x: x))]) + +_3g_measurement_parameters_description_struct = CSN1List(name='_3g_measurement_parameters_description_struct', list=[ + CSN1Bit(name='qsearch_i', bit=4), + CSN1Bit(name='qsearch_c_initial'), CSN1Alt(alt={ '0': ('', []), '1': ('', [ - CSN1Bit(name='bandwidth_fdd', bit=3)])}), + CSN1Bit(name='fdd_qoffset', bit=4), + CSN1Bit(name='fdd_rep_quant'), + CSN1Bit(name='fdd_multirat_reporting', bit=2), + CSN1Bit(name='fdd_qmin', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_qoffset', bit=4), + CSN1Bit(name='tdd_multirat_reporting', bit=2)])})]) + +gprs_bsic_description_struct = CSN1List(name='gprs_bsic_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='ba_index_start_bsic', bit=5)])}), + CSN1Bit(name='bsic', bit=6), + CSN1Bit(name='number_remaining_bsic', bit=7), + CSN1List(num=([2], lambda x: x), list=[ + CSN1Bit(name='frequency_scrolling'), + CSN1Bit(name='bsic', bit=6)])]) + +utran_csg_cells_reporting_description_struct = CSN1List(name='utran_csg_cells_reporting_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_csg_fdd_reporting_threshold', bit=3), + CSN1Bit(name='utran_csg_fdd_reporting_threshold_2', bit=6)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_csg_tdd_reporting_threshold', bit=3)])})]) + +gprs_report_priority_description_struct = CSN1List(name='gprs_report_priority_description_struct', list=[ + CSN1Bit(name='number_cells', bit=7), + CSN1Bit(name='rep_priority', num=([0], lambda x: x))]) + +measurement_parameters_description_struct = CSN1List(name='measurement_parameters_description_struct', list=[ + CSN1Bit(name='report_type'), + CSN1Bit(name='serving_band_reporting', bit=2)]) + +e_utran_csg_description_struct = CSN1List(name='e_utran_csg_description_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_fdd_neighbour_cells', obj=repeated_utran_fdd_neighbour_cells_struct)]), + CSN1Ref(name='csg_pci_split', obj=pcid_group_ie), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='e_utran_frequency_index', bit=3)]), + CSN1Val(name='', val='0')]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='csg_earfcn', bit=16)]), CSN1Val(name='', val='0')]) +gprs_3g_measurement_parameters_description_struct = CSN1List(name='gprs_3g_measurement_parameters_description_struct', list=[ + CSN1Bit(name='qsearch_p', bit=4), + CSN1Val(name='', val='1'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_rep_quant'), + CSN1Bit(name='fdd_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='fdd_reporting_offset', bit=3), + CSN1Bit(name='fdd_reporting_threshold', bit=3)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_multirat_reporting', bit=2)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='tdd_reporting_offset', bit=3), + CSN1Bit(name='tdd_reporting_threshold', bit=3)])})]) + +rtd6_struct = CSN1List(name='rtd6_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='0'), + CSN1Bit(name='rtd', bit=6)]), + CSN1Val(name='', val='1')]) + +extended_earfcns_description_struct = CSN1List(name='extended_earfcns_description_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='earfcn_extended', bit=18)]), + CSN1Val(name='', val='0')]) + +utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_tdd', bit=3)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_utran_tdd_neighbour_cells', obj=repeated_utran_tdd_neighbour_cells_struct)]), + CSN1Val(name='', val='0')]) + +si2q_extension_information = CSN1List(name='si2q_extension_information', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='ccn_support_description', obj=ccn_support_description_struct)])}), + CSN1Ref(obj=spare_bit, num=-1)]) + +csg_cells_reporting_description_struct = CSN1List(name='csg_cells_reporting_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='utran_csg_cells_reporting_description', obj=utran_csg_cells_reporting_description_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='e_utran_csg_cells_reporting_description', obj=e_utran_csg_cells_reporting_description_struct)])})]) + +e_utran_parameters_description_struct = CSN1List(name='e_utran_parameters_description_struct', list=[ + CSN1Bit(name='e_utran_ccn_active'), + CSN1Bit(name='e_utran_start'), + CSN1Bit(name='e_utran_stop'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='e_utran_measurement_parameters_description', obj=e_utran_measurement_parameters_description_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='gprs_e_utran_measurement_parameters_description', obj=gprs_e_utran_measurement_parameters_description_struct)])}), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_e_utran_neighbour_cells', obj=repeated_e_utran_neighbour_cells_struct)]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_e_utran_not_allowed_cells', obj=repeated_e_utran_not_allowed_cells_struct)]), + CSN1Val(name='', val='0'), + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Ref(name='repeated_e_utran_pcid_to_ta_mapping', obj=repeated_e_utran_pcid_to_ta_mapping_struct)]), + CSN1Val(name='', val='0')]) + +_3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_description_struct', list=[ + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='index_start_3g', bit=7)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='absolute_index_start_emr', bit=7)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='utran_fdd_description', obj=utran_fdd_description_struct)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(name='utran_tdd_description', obj=utran_tdd_description_struct)])})]) + gprs_real_time_difference_description_struct = CSN1List(name='gprs_real_time_difference_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -477,45 +595,6 @@ gprs_real_time_difference_description_struct = CSN1List(name='gprs_real_time_dif CSN1Ref(name='rtd', obj=rtd12_struct)]), CSN1Val(name='', val='1')])})]) -e_utran_parameters_description_struct = CSN1List(name='e_utran_parameters_description_struct', list=[ - CSN1Bit(name='e_utran_ccn_active'), - CSN1Bit(name='e_utran_start'), - CSN1Bit(name='e_utran_stop'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='e_utran_measurement_parameters_description', obj=e_utran_measurement_parameters_description_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='gprs_e_utran_measurement_parameters_description', obj=gprs_e_utran_measurement_parameters_description_struct)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_e_utran_neighbour_cells', obj=repeated_e_utran_neighbour_cells_struct)]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_e_utran_not_allowed_cells', obj=repeated_e_utran_not_allowed_cells_struct)]), - CSN1Val(name='', val='0'), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_e_utran_pcid_to_ta_mapping', obj=repeated_e_utran_pcid_to_ta_mapping_struct)]), - CSN1Val(name='', val='0')]) - -_3g_priority_parameters_description_struct = CSN1List(name='_3g_priority_parameters_description_struct', list=[ - CSN1Bit(name='utran_start'), - CSN1Bit(name='utran_stop'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='default_utran_priority', bit=3), - CSN1Bit(name='default_thresh_utran', bit=5), - CSN1Bit(name='default_utran_qrxlevmin', bit=5)])}), - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Ref(name='repeated_utran_priority_parameters', obj=repeated_utran_priority_parameters_struct)]), - CSN1Val(name='', val='0')]) - priority_and_e_utran_parameters_description_struct = CSN1List(name='priority_and_e_utran_parameters_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), @@ -530,24 +609,6 @@ priority_and_e_utran_parameters_description_struct = CSN1List(name='priority_and '1': ('', [ CSN1Ref(name='e_utran_parameters_description', obj=e_utran_parameters_description_struct)])})]) -_3g_neighbour_cell_description_struct = CSN1List(name='_3g_neighbour_cell_description_struct', list=[ - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='index_start_3g', bit=7)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='absolute_index_start_emr', bit=7)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='utran_fdd_description', obj=utran_fdd_description_struct)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(name='utran_tdd_description', obj=utran_tdd_description_struct)])})]) - si2quater_rest_octets = CSN1List(name='si2quater_rest_octets', list=[ CSN1Bit(name='ba_ind'), CSN1Bit(name='_3g_ba_ind'), diff --git a/pycrate_csn1dir/si2ter_rest_octets.py b/pycrate_csn1dir/si2ter_rest_octets.py index d30eb86..7580def 100644 --- a/pycrate_csn1dir/si2ter_rest_octets.py +++ b/pycrate_csn1dir/si2ter_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si2ter_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,6 +43,14 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding +utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ + CSN1Val(name='', val='01'), + CSN1Bit(name='tdd_arfcn', bit=14), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='bandwidth_tdd', bit=3)])})]) + _3g_measurement_parameters_description_struct = CSN1List(name='_3g_measurement_parameters_description_struct', list=[ CSN1Bit(name='qsearch_i', bit=4), CSN1Alt(alt={ @@ -55,6 +63,10 @@ _3g_measurement_parameters_description_struct = CSN1List(name='_3g_measurement_p '1': ('', [ CSN1Bit(name='tdd_qoffset', bit=4)])})]) +_3g_additional_measurement_parameters_description_struct = CSN1List(name='_3g_additional_measurement_parameters_description_struct', list=[ + CSN1Bit(name='fdd_qmin_offset', bit=3), + CSN1Bit(name='fdd_rscpmin', bit=4)]) + utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', list=[ CSN1Val(name='', val='01'), CSN1Bit(name='fdd_arfcn', bit=14), @@ -63,18 +75,6 @@ utran_fdd_description_struct = CSN1List(name='utran_fdd_description_struct', lis '1': ('', [ CSN1Bit(name='bandwidth_fdd', bit=3)])})]) -utran_tdd_description_struct = CSN1List(name='utran_tdd_description_struct', list=[ - CSN1Val(name='', val='01'), - CSN1Bit(name='tdd_arfcn', bit=14), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='bandwidth_tdd', bit=3)])})]) - -_3g_additional_measurement_parameters_description_struct = CSN1List(name='_3g_additional_measurement_parameters_description_struct', list=[ - CSN1Bit(name='fdd_qmin_offset', bit=3), - CSN1Bit(name='fdd_rscpmin', bit=4)]) - si2ter_rest_octets = CSN1List(name='si2ter_rest_octets', list=[ CSN1Alt(alt={ 'H': ('', [ diff --git a/pycrate_csn1dir/si3_rest_octet.py b/pycrate_csn1dir/si3_rest_octet.py index 9f88c52..592f2e1 100644 --- a/pycrate_csn1dir/si3_rest_octet.py +++ b/pycrate_csn1dir/si3_rest_octet.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si3_rest_octet.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,19 +43,19 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -si2quater_indicator_struct = CSN1Bit(name='si2quater_indicator_struct') +gprs_indicator = CSN1List(name='gprs_indicator', list=[ + CSN1Bit(name='ra_colour', bit=3), + CSN1Bit(name='si13_position')]) early_classmark_sending_control = CSN1Alt(name='early_classmark_sending_control', alt={ 'H': ('', []), 'L': ('', [])}) -_3g_early_classmark_sending_restriction = CSN1Alt(name='_3g_early_classmark_sending_restriction', alt={ - 'H': ('', []), - 'L': ('', [])}) - -gprs_indicator = CSN1List(name='gprs_indicator', list=[ - CSN1Bit(name='ra_colour', bit=3), - CSN1Bit(name='si13_position')]) +selection_parameters = CSN1List(name='selection_parameters', list=[ + CSN1Bit(name='cbq'), + CSN1Bit(name='cell_reselect_offset', bit=6), + CSN1Bit(name='temporary_offset', bit=3), + CSN1Bit(name='penalty_time', bit=5)]) scheduling_if_and_where = CSN1Alt(name='scheduling_if_and_where', alt={ 'H': ('', [ @@ -71,18 +71,18 @@ system_information_2ter_indicator = CSN1Alt(name='system_information_2ter_indica 'H': ('', []), 'L': ('', [])}) -selection_parameters = CSN1List(name='selection_parameters', list=[ - CSN1Bit(name='cbq'), - CSN1Bit(name='cell_reselect_offset', bit=6), - CSN1Bit(name='temporary_offset', bit=3), - CSN1Bit(name='penalty_time', bit=5)]) +iu_indicator = CSN1Bit(name='iu_indicator') optional_power_offset = CSN1Alt(name='optional_power_offset', alt={ 'H': ('', [ CSN1Bit(name='power_offset', bit=2)]), 'L': ('', [])}) -iu_indicator = CSN1Bit(name='iu_indicator') +_3g_early_classmark_sending_restriction = CSN1Alt(name='_3g_early_classmark_sending_restriction', alt={ + 'H': ('', []), + 'L': ('', [])}) + +si2quater_indicator_struct = CSN1Bit(name='si2quater_indicator_struct') optional_selection_parameters = CSN1Alt(name='optional_selection_parameters', alt={ 'H': ('', [ diff --git a/pycrate_csn1dir/si4_rest_octets.py b/pycrate_csn1dir/si4_rest_octets.py index 2a6175a..abaec9a 100644 --- a/pycrate_csn1dir/si4_rest_octets.py +++ b/pycrate_csn1dir/si4_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si4_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,24 +43,16 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -selection_parameters = CSN1List(name='selection_parameters', list=[ - CSN1Bit(name='cbq'), - CSN1Bit(name='cell_reselect_offset', bit=6), - CSN1Bit(name='temporary_offset', bit=3), - CSN1Bit(name='penalty_time', bit=5)]) - -break_indicator = CSN1Alt(name='break_indicator', alt={ - 'H': ('', []), - 'L': ('', [])}) - optional_power_offset = CSN1Alt(name='optional_power_offset', alt={ 'H': ('', [ CSN1Bit(name='power_offset', bit=2)]), 'L': ('', [])}) -gprs_indicator = CSN1List(name='gprs_indicator', list=[ - CSN1Bit(name='ra_colour', bit=3), - CSN1Bit(name='si13_position')]) +lsa_identity = CSN1Alt(name='lsa_identity', alt={ + '0': ('', [ + CSN1Bit(name='lsa_id', bit=24)]), + '1': ('', [ + CSN1Bit(name='shortlsa_id', bit=10)])}) lsa_parameters = CSN1List(name='lsa_parameters', list=[ CSN1Bit(name='prio_thr', bit=3), @@ -71,15 +63,18 @@ lsa_parameters = CSN1List(name='lsa_parameters', list=[ CSN1Bit(name='mcc', bit=12), CSN1Bit(name='mnc', bit=12)])})]) -lsa_identity = CSN1Alt(name='lsa_identity', alt={ - '0': ('', [ - CSN1Bit(name='lsa_id', bit=24)]), - '1': ('', [ - CSN1Bit(name='shortlsa_id', bit=10)])}) +gprs_indicator = CSN1List(name='gprs_indicator', list=[ + CSN1Bit(name='ra_colour', bit=3), + CSN1Bit(name='si13_position')]) -optional_selection_parameters = CSN1Alt(name='optional_selection_parameters', alt={ - 'H': ('', [ - CSN1Ref(obj=selection_parameters)]), +selection_parameters = CSN1List(name='selection_parameters', list=[ + CSN1Bit(name='cbq'), + CSN1Bit(name='cell_reselect_offset', bit=6), + CSN1Bit(name='temporary_offset', bit=3), + CSN1Bit(name='penalty_time', bit=5)]) + +break_indicator = CSN1Alt(name='break_indicator', alt={ + 'H': ('', []), 'L': ('', [])}) lsa_id_information = CSN1List(name='lsa_id_information', list=[ @@ -89,14 +84,6 @@ lsa_id_information = CSN1List(name='lsa_id_information', list=[ '1': ('', [ CSN1SelfRef()])})]) -si4_rest_octets_o = CSN1List(name='si4_rest_octets_o', list=[ - CSN1Ref(obj=optional_selection_parameters), - CSN1Ref(obj=optional_power_offset), - CSN1Alt(alt={ - 'H': ('', [ - CSN1Ref(obj=gprs_indicator)]), - 'L': ('', [])})]) - si4_rest_octets_s = CSN1List(name='si4_rest_octets_s', list=[ CSN1Alt(alt={ 'H': ('', [ @@ -119,6 +106,19 @@ si4_rest_octets_s = CSN1List(name='si4_rest_octets_s', list=[ CSN1Bit(name='si13alt_position')])})]), 'L': ('', [])})]) +optional_selection_parameters = CSN1Alt(name='optional_selection_parameters', alt={ + 'H': ('', [ + CSN1Ref(obj=selection_parameters)]), + 'L': ('', [])}) + +si4_rest_octets_o = CSN1List(name='si4_rest_octets_o', list=[ + CSN1Ref(obj=optional_selection_parameters), + CSN1Ref(obj=optional_power_offset), + CSN1Alt(alt={ + 'H': ('', [ + CSN1Ref(obj=gprs_indicator)]), + 'L': ('', [])})]) + si4_rest_octets = CSN1List(name='si4_rest_octets', list=[ CSN1Ref(obj=si4_rest_octets_o), CSN1Alt(alt={ diff --git a/pycrate_csn1dir/si6_rest_octets.py b/pycrate_csn1dir/si6_rest_octets.py index aa2a0d4..326ed73 100644 --- a/pycrate_csn1dir/si6_rest_octets.py +++ b/pycrate_csn1dir/si6_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si6_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -43,22 +43,10 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -band_indicator = CSN1Alt(name='band_indicator', alt={ - 'H': ('', []), - 'L': ('', [])}) - -inband_pagings = CSN1Alt(name='inband_pagings', alt={ - '0': ('', []), - '1': ('', [])}) - paging_channel_restructuring = CSN1Alt(name='paging_channel_restructuring', alt={ '0': ('', []), '1': ('', [])}) -inband_notifications = CSN1Alt(name='inband_notifications', alt={ - '0': ('', []), - '1': ('', [])}) - pch_and_nch_info = CSN1List(name='pch_and_nch_info', list=[ CSN1Ref(obj=paging_channel_restructuring), CSN1Bit(name='nln_sacch', bit=2), @@ -68,9 +56,9 @@ pch_and_nch_info = CSN1List(name='pch_and_nch_info', list=[ CSN1Bit(name='call_priority', bit=3)])}), CSN1Bit(name='nln_status_sacch')]) -vbs_vgcs_options = CSN1List(name='vbs_vgcs_options', list=[ - CSN1Ref(obj=inband_notifications), - CSN1Ref(obj=inband_pagings)]) +band_indicator = CSN1Alt(name='band_indicator', alt={ + 'H': ('', []), + 'L': ('', [])}) si6_rest_octets = CSN1List(name='si6_rest_octets', list=[ CSN1Alt(alt={ @@ -109,3 +97,15 @@ si6_rest_octets = CSN1List(name='si6_rest_octets', list=[ 'L': ('', [])}), CSN1Ref(obj=spare_padding)]) +inband_pagings = CSN1Alt(name='inband_pagings', alt={ + '0': ('', []), + '1': ('', [])}) + +inband_notifications = CSN1Alt(name='inband_notifications', alt={ + '0': ('', []), + '1': ('', [])}) + +vbs_vgcs_options = CSN1List(name='vbs_vgcs_options', list=[ + CSN1Ref(obj=inband_notifications), + CSN1Ref(obj=inband_pagings)]) + diff --git a/pycrate_csn1dir/si9_rest_octets.py b/pycrate_csn1dir/si9_rest_octets.py index 9b4880b..b8aed99 100644 --- a/pycrate_csn1dir/si9_rest_octets.py +++ b/pycrate_csn1dir/si9_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si9_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -92,13 +92,6 @@ position = CSN1Alt(name='position', alt={ CSN1Bit(name='relative_position', bit=([0], lambda x: x + 1)), CSN1Bit(name='bcch_type')])}) -positions = CSN1List(name='positions', list=[ - CSN1Ref(obj=position), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Ref(obj=position)])})]) - info_type = CSN1Alt(name='info_type', alt={ '0': ('', [ CSN1Bit(name='info_type_4', bit=4)]), @@ -107,6 +100,13 @@ info_type = CSN1Alt(name='info_type', alt={ '11': ('', [ CSN1Bit(name='info_type_6', bit=6)])}) +positions = CSN1List(name='positions', list=[ + CSN1Ref(obj=position), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Ref(obj=position)])})]) + scheduling_info = CSN1List(name='scheduling_info', list=[ CSN1Ref(obj=info_type), CSN1Ref(obj=positions), diff --git a/pycrate_csn1dir/si_13_rest_octets.py b/pycrate_csn1dir/si_13_rest_octets.py index ae6a4aa..497a83a 100644 --- a/pycrate_csn1dir/si_13_rest_octets.py +++ b/pycrate_csn1dir/si_13_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si_13_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -32,8 +32,8 @@ # external references from pycrate_csn1dir.gprs_mobile_allocation_ie import gprs_mobile_allocation_ie -from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie from pycrate_csn1dir.gprs_power_control_parameters_ie import gprs_power_control_parameters_ie +from pycrate_csn1dir.gprs_cell_options_ie import gprs_cell_options_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/si_13alt_rest_octets.py b/pycrate_csn1dir/si_13alt_rest_octets.py index a3dbf67..9ed1a60 100644 --- a/pycrate_csn1dir/si_13alt_rest_octets.py +++ b/pycrate_csn1dir/si_13alt_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si_13alt_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si_18_rest_octets.py b/pycrate_csn1dir/si_18_rest_octets.py index e494aba..9a48a87 100644 --- a/pycrate_csn1dir/si_18_rest_octets.py +++ b/pycrate_csn1dir/si_18_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si_18_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si_19_rest_octets.py b/pycrate_csn1dir/si_19_rest_octets.py index 232c1f8..2c1d7f1 100644 --- a/pycrate_csn1dir/si_19_rest_octets.py +++ b/pycrate_csn1dir/si_19_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si_19_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si_21_rest_octets.py b/pycrate_csn1dir/si_21_rest_octets.py index 5cbcc5e..5e15e5d 100644 --- a/pycrate_csn1dir/si_21_rest_octets.py +++ b/pycrate_csn1dir/si_21_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si_21_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si_22_rest_octets.py b/pycrate_csn1dir/si_22_rest_octets.py index 29c735c..1e6a006 100644 --- a/pycrate_csn1dir/si_22_rest_octets.py +++ b/pycrate_csn1dir/si_22_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si_22_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/si_23_rest_octets.py b/pycrate_csn1dir/si_23_rest_octets.py index 9edd751..3f93930 100644 --- a/pycrate_csn1dir/si_23_rest_octets.py +++ b/pycrate_csn1dir/si_23_rest_octets.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/si_23_rest_octets.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,9 +31,9 @@ # top-level object: SI 23 Rest Octets # external references -from pycrate_csn1dir.si2quater_rest_octets import repeated_e_utran_pcid_to_ta_mapping_struct -from pycrate_csn1dir.enhanced_cell_reselection_parameters_ie import enhanced_cell_reselection_parameters_ie from pycrate_csn1dir.measurement_information import repeated_e_utran_not_allowed_cells_struct +from pycrate_csn1dir.enhanced_cell_reselection_parameters_ie import enhanced_cell_reselection_parameters_ie +from pycrate_csn1dir.si2quater_rest_octets import repeated_e_utran_pcid_to_ta_mapping_struct # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init @@ -46,25 +46,6 @@ spare_padding = CSN1Val(name='spare_padding', val='L', num=-1) Spare_padding = spare_padding Spare_Padding = spare_padding -repeated_utran_fdd_tdd_neighbour_frequency_and_priority_struct = CSN1List(name='repeated_utran_fdd_tdd_neighbour_frequency_and_priority_struct', list=[ - CSN1List(num=-1, list=[ - CSN1Val(name='', val='1'), - CSN1Bit(name='utran_arfcn', bit=14)]), - CSN1Val(name='', val='0'), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='utran_priority', bit=3)])}), - CSN1Bit(name='thresh_utran_high', bit=5), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='thresh_utran_low', bit=5)])}), - CSN1Alt(alt={ - '0': ('', []), - '1': ('', [ - CSN1Bit(name='utran_qrxlevmin', bit=5)])})]) - repeated_e_utran_neighbour_frequency_and_priority_struct = CSN1List(name='repeated_e_utran_neighbour_frequency_and_priority_struct', list=[ CSN1List(num=-1, list=[ CSN1Val(name='', val='1'), @@ -88,6 +69,25 @@ repeated_e_utran_neighbour_frequency_and_priority_struct = CSN1List(name='repeat '1': ('', [ CSN1Bit(name='e_utran_qrxlevmin', bit=5)])})]) +repeated_utran_fdd_tdd_neighbour_frequency_and_priority_struct = CSN1List(name='repeated_utran_fdd_tdd_neighbour_frequency_and_priority_struct', list=[ + CSN1List(num=-1, list=[ + CSN1Val(name='', val='1'), + CSN1Bit(name='utran_arfcn', bit=14)]), + CSN1Val(name='', val='0'), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_priority', bit=3)])}), + CSN1Bit(name='thresh_utran_high', bit=5), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='thresh_utran_low', bit=5)])}), + CSN1Alt(alt={ + '0': ('', []), + '1': ('', [ + CSN1Bit(name='utran_qrxlevmin', bit=5)])})]) + utran_fdd_tdd_description_struct = CSN1List(name='utran_fdd_tdd_description_struct', list=[ CSN1Alt(alt={ '0': ('', []), diff --git a/pycrate_csn1dir/single_downlink_assignment_2_ie.py b/pycrate_csn1dir/single_downlink_assignment_2_ie.py index 05dd02e..b8a648b 100644 --- a/pycrate_csn1dir/single_downlink_assignment_2_ie.py +++ b/pycrate_csn1dir/single_downlink_assignment_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/single_downlink_assignment_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,8 +31,8 @@ # top-level object: Single Downlink Assignment 2 IE # external references -from pycrate_csn1dir.egprs_level_ie import egprs_level_ie from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.egprs_level_ie import egprs_level_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/single_uplink_assignment_2_ie.py b/pycrate_csn1dir/single_uplink_assignment_2_ie.py index 1e6d3f5..0e74c3e 100644 --- a/pycrate_csn1dir/single_uplink_assignment_2_ie.py +++ b/pycrate_csn1dir/single_uplink_assignment_2_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/single_uplink_assignment_2_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -33,10 +33,10 @@ # external references from pycrate_csn1dir.pulse_format_ie import pulse_format_ie from pycrate_csn1dir.dynamic_allocation_2_ie import dynamic_allocation_2_ie -from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie -from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie -from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie from pycrate_csn1dir.egprs_level_ie import egprs_level_ie +from pycrate_csn1dir.egprs_modulation_and_coding_scheme_ie import egprs_modulation_and_coding_scheme_ie +from pycrate_csn1dir.egprs_window_size_ie import egprs_window_size_ie +from pycrate_csn1dir.pdch_pairs_description_ie import pdch_pairs_description_ie # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/starting_frame_number_description_ie.py b/pycrate_csn1dir/starting_frame_number_description_ie.py index 0df0485..b05c8ee 100644 --- a/pycrate_csn1dir/starting_frame_number_description_ie.py +++ b/pycrate_csn1dir/starting_frame_number_description_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/starting_frame_number_description_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/system_information_type_10.py b/pycrate_csn1dir/system_information_type_10.py index 697ff30..f2ebed4 100644 --- a/pycrate_csn1dir/system_information_type_10.py +++ b/pycrate_csn1dir/system_information_type_10.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. P1sec. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/system_information_type_10.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/system_information_type_10bis.py b/pycrate_csn1dir/system_information_type_10bis.py index 0fbb8a0..d656576 100644 --- a/pycrate_csn1dir/system_information_type_10bis.py +++ b/pycrate_csn1dir/system_information_type_10bis.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/system_information_type_10bis.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/system_information_type_10ter.py b/pycrate_csn1dir/system_information_type_10ter.py index 0b9abc0..a6b9ad9 100644 --- a/pycrate_csn1dir/system_information_type_10ter.py +++ b/pycrate_csn1dir/system_information_type_10ter.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/system_information_type_10ter.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/tlli_g_rnti_ie.py b/pycrate_csn1dir/tlli_g_rnti_ie.py index 433969b..a517df2 100644 --- a/pycrate_csn1dir/tlli_g_rnti_ie.py +++ b/pycrate_csn1dir/tlli_g_rnti_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/tlli_g_rnti_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/tmgi_ie.py b/pycrate_csn1dir/tmgi_ie.py index 2b3b52a..ae8bfc6 100644 --- a/pycrate_csn1dir/tmgi_ie.py +++ b/pycrate_csn1dir/tmgi_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/tmgi_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/uplink_free.py b/pycrate_csn1dir/uplink_free.py index 70cb04d..2d8e0e5 100644 --- a/pycrate_csn1dir/uplink_free.py +++ b/pycrate_csn1dir/uplink_free.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/uplink_free.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/uplink_rlc_mac_control_message.py b/pycrate_csn1dir/uplink_rlc_mac_control_message.py index 3d08b87..fe10fd2 100644 --- a/pycrate_csn1dir/uplink_rlc_mac_control_message.py +++ b/pycrate_csn1dir/uplink_rlc_mac_control_message.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/uplink_rlc_mac_control_message.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ @@ -31,28 +31,28 @@ # top-level object: Uplink RLC/MAC control message # external references -from pycrate_csn1dir.packet_cell_change_notification_message_content import packet_cell_change_notification_message_content from pycrate_csn1dir.packet_enhanced_measurement_report_message_content import packet_enhanced_measurement_report_message_content -from pycrate_csn1dir.ec_packet_downlink_ack_nack_message_content import ec_packet_downlink_ack_nack_message_content -from pycrate_csn1dir.egprs_packet_downlink_ack_nack_type_2_message_content import egprs_packet_downlink_ack_nack_type_2_message_content -from pycrate_csn1dir.packet_downlink_ack_nack_message_content import packet_downlink_ack_nack_message_content -from pycrate_csn1dir.packet_cell_change_failure_message_content import packet_cell_change_failure_message_content -from pycrate_csn1dir.packet_resource_request_message_content import packet_resource_request_message_content from pycrate_csn1dir.mbms_downlink_ack_nack_message_content import mbms_downlink_ack_nack_message_content -from pycrate_csn1dir.packet_psi_status_message_content import packet_psi_status_message_content -from pycrate_csn1dir.packet_mobile_tbf_status_message_content import packet_mobile_tbf_status_message_content -from pycrate_csn1dir.packet_si_status_message_content import packet_si_status_message_content -from pycrate_csn1dir.packet_control_acknowledgement_message_content import packet_control_acknowledgement_message_content -from pycrate_csn1dir.additional_ms_radio_access_capabilities_message_content import additional_ms_radio_access_capabilities_message_content -from pycrate_csn1dir.ec_packet_control_acknowledgement_message_content import ec_packet_control_acknowledgement_message_content -from pycrate_csn1dir.packet_uplink_dummy_control_block_message_content import packet_uplink_dummy_control_block_message_content -from pycrate_csn1dir.egprs_packet_downlink_ack_nack_type_3_message_content import egprs_packet_downlink_ack_nack_type_3_message_content -from pycrate_csn1dir.mbms_service_request_message_content import mbms_service_request_message_content from pycrate_csn1dir.packet_cs_request_message_content import packet_cs_request_message_content +from pycrate_csn1dir.ec_packet_control_acknowledgement_message_content import ec_packet_control_acknowledgement_message_content +from pycrate_csn1dir.ec_packet_downlink_ack_nack_message_content import ec_packet_downlink_ack_nack_message_content +from pycrate_csn1dir.packet_uplink_dummy_control_block_message_content import packet_uplink_dummy_control_block_message_content +from pycrate_csn1dir.additional_ms_radio_access_capabilities_message_content import additional_ms_radio_access_capabilities_message_content +from pycrate_csn1dir.mbms_service_request_message_content import mbms_service_request_message_content +from pycrate_csn1dir.packet_si_status_message_content import packet_si_status_message_content +from pycrate_csn1dir.packet_resource_request_message_content import packet_resource_request_message_content +from pycrate_csn1dir.packet_cell_change_failure_message_content import packet_cell_change_failure_message_content from pycrate_csn1dir.egprs_packet_downlink_ack_nack_message_content import egprs_packet_downlink_ack_nack_message_content +from pycrate_csn1dir.packet_mobile_tbf_status_message_content import packet_mobile_tbf_status_message_content from pycrate_csn1dir.egprs_packet_downlink_ack_nack_dlmc_message_content import egprs_packet_downlink_ack_nack_dlmc_message_content +from pycrate_csn1dir.packet_psi_status_message_content import packet_psi_status_message_content +from pycrate_csn1dir.packet_cell_change_notification_message_content import packet_cell_change_notification_message_content +from pycrate_csn1dir.egprs_packet_downlink_ack_nack_type_2_message_content import egprs_packet_downlink_ack_nack_type_2_message_content +from pycrate_csn1dir.egprs_packet_downlink_ack_nack_type_3_message_content import egprs_packet_downlink_ack_nack_type_3_message_content +from pycrate_csn1dir.packet_downlink_ack_nack_message_content import packet_downlink_ack_nack_message_content from pycrate_csn1dir.packet_pause_message_content import packet_pause_message_content from pycrate_csn1dir.packet_measurement_report_message_content import packet_measurement_report_message_content +from pycrate_csn1dir.packet_control_acknowledgement_message_content import packet_control_acknowledgement_message_content # code automatically generated by pycrate_csn1 # change object type with type=CSN1T_BSTR (default type is CSN1T_UINT) in init diff --git a/pycrate_csn1dir/used_dl_coverage_class_ie.py b/pycrate_csn1dir/used_dl_coverage_class_ie.py index 0759781..c492bed 100644 --- a/pycrate_csn1dir/used_dl_coverage_class_ie.py +++ b/pycrate_csn1dir/used_dl_coverage_class_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/used_dl_coverage_class_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/utran_csg_measurement_report_ie.py b/pycrate_csn1dir/utran_csg_measurement_report_ie.py index e4ed719..2e99c30 100644 --- a/pycrate_csn1dir/utran_csg_measurement_report_ie.py +++ b/pycrate_csn1dir/utran_csg_measurement_report_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/utran_csg_measurement_report_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/utran_csg_target_cell_ie.py b/pycrate_csn1dir/utran_csg_target_cell_ie.py index 02bb1f1..03255b4 100644 --- a/pycrate_csn1dir/utran_csg_target_cell_ie.py +++ b/pycrate_csn1dir/utran_csg_target_cell_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/utran_csg_target_cell_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/utran_fdd_target_cell_ie.py b/pycrate_csn1dir/utran_fdd_target_cell_ie.py index 1944b3f..59d7798 100644 --- a/pycrate_csn1dir/utran_fdd_target_cell_ie.py +++ b/pycrate_csn1dir/utran_fdd_target_cell_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/utran_fdd_target_cell_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/utran_freq_list.py b/pycrate_csn1dir/utran_freq_list.py index 40945a3..fbcab4d 100644 --- a/pycrate_csn1dir/utran_freq_list.py +++ b/pycrate_csn1dir/utran_freq_list.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/utran_freq_list.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/utran_tdd_target_cell_ie.py b/pycrate_csn1dir/utran_tdd_target_cell_ie.py index 4db2a4a..31d8836 100644 --- a/pycrate_csn1dir/utran_tdd_target_cell_ie.py +++ b/pycrate_csn1dir/utran_tdd_target_cell_ie.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/utran_tdd_target_cell_ie.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/vbs_vgcs_reconfigure.py b/pycrate_csn1dir/vbs_vgcs_reconfigure.py index 817e622..cc3f614 100644 --- a/pycrate_csn1dir/vbs_vgcs_reconfigure.py +++ b/pycrate_csn1dir/vbs_vgcs_reconfigure.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/vbs_vgcs_reconfigure.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/vbs_vgcs_reconfigure2.py b/pycrate_csn1dir/vbs_vgcs_reconfigure2.py index 6e39465..c29bd8d 100644 --- a/pycrate_csn1dir/vbs_vgcs_reconfigure2.py +++ b/pycrate_csn1dir/vbs_vgcs_reconfigure2.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/vbs_vgcs_reconfigure2.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/vgcs_additional_info.py b/pycrate_csn1dir/vgcs_additional_info.py index c554017..2c6fd6f 100644 --- a/pycrate_csn1dir/vgcs_additional_info.py +++ b/pycrate_csn1dir/vgcs_additional_info.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/vgcs_additional_info.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/vgcs_neighbour_cell_information.py b/pycrate_csn1dir/vgcs_neighbour_cell_information.py index d437159..11111ac 100644 --- a/pycrate_csn1dir/vgcs_neighbour_cell_information.py +++ b/pycrate_csn1dir/vgcs_neighbour_cell_information.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/vgcs_neighbour_cell_information.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/pycrate_csn1dir/vgcs_sms_information.py b/pycrate_csn1dir/vgcs_sms_information.py index fae9550..ad014fc 100644 --- a/pycrate_csn1dir/vgcs_sms_information.py +++ b/pycrate_csn1dir/vgcs_sms_information.py @@ -3,7 +3,7 @@ # * Software Name : pycrate # * Version : 0.3 # * -# * Copyright 2018. Benoit Michau. ANSSI. +# * Copyright 2018. Benoit Michau. ANSSI. P1sec. # * # * This library is free software; you can redistribute it and/or # * modify it under the terms of the GNU Lesser General Public @@ -22,7 +22,7 @@ # * # *-------------------------------------------------------- # * File Name : pycrate_csn1dir/vgcs_sms_information.py -# * Created : 2018-10-08 +# * Created : 2018-11-21 # * Authors : Benoit Michau # *-------------------------------------------------------- #*/ diff --git a/test/test_gsmrr.py b/test/test_gsmrr.py new file mode 100644 index 0000000..ef8855b --- /dev/null +++ b/test/test_gsmrr.py @@ -0,0 +1,105 @@ +# -*- coding: UTF-8 -*- +#/** +# * Software Name : pycrate +# * Version : 0.3 +# * +# * Copyright 2018. Benoit Michau. P1sec. +# * +# * This library is free software; you can redistribute it and/or +# * modify it under the terms of the GNU Lesser General Public +# * License as published by the Free Software Foundation; either +# * version 2.1 of the License, or (at your option) any later version. +# * +# * This library is distributed in the hope that it will be useful, +# * but WITHOUT ANY WARRANTY; without even the implied warranty of +# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# * Lesser General Public License for more details. +# * +# * You should have received a copy of the GNU Lesser General Public +# * License along with this library; if not, write to the Free Software +# * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, +# * MA 02110-1301 USA +# * +# *-------------------------------------------------------- +# * File Name : test/test_gsmrr.py +# * Created : 2018-11-21 +# * Authors : Benoit Michau +# *-------------------------------------------------------- +#*/ + +from timeit import timeit + +#from pycrate_core.elt import Element +#Element._SAFE_STAT = False +#Element._SAFE_DYN = False + +from pycrate_mobile.NAS import * + +rr_pdu_mo = tuple(map(unhexlify, ( + # SACCH + '061524a420e5516f30d68dc8000000000000', # measurement report + '061523a30123516f1b97586b81c000000000', + # DCCH + '062702035359a605f4312949c4', # paging response + '0634c430946102f81003100106', # GPRS suspension req + '0616035359a6200b601404ef6503b8878d2100', # classmark change + '0632', # ciphering mode complete + ))) + +rr_pdu_mt = tuple(map(unhexlify, ( + # BCCH + '2d063f110e600c7f1d3800004bc26b0284b510f32b2b2b', # immediate assignment + '35063f0178b18207ec1704021fff2b2b2b2b2b2b2b2b2b', + '2506212005f438e593af2b2b2b2b2b2b2b2b2b2b2b2b2b', # paging req type 1 + '490622a0c9585d282cf7eb861705f4df78a200cc8b2b2b', # paging req type 2 + '4d0624a0356c9f6bf1e09909ff402879d9304369d32b2b', # paging req type 3 + '5506198fe900200000000000000000000000007900002b', # SI type 1 + '55061900000000000000000001c00001ff80007900002b', + '01060080005847eb4a93f51a298a16ab2b2b2b2b2b2b2b', # SI type 13 + '59061a10000000000000000000000000007effff790000', # SI type 2 + '550602afe85f7000000ba000000000000000007900002b', # SI type 2bis + '05060700e046e508007e5170c1879fe259742c5e182d53', # SI type 2quater + '010603cf8a30000000000000000000005000002b2b2b2b', # SI type 2ter + '49061bfae102f8100310c8021e1785407900008000029b', # SI type 3 + '31061c02f810031085407900008000572b2b2b2b2b2b2b', # SI type 4 + # SACCH + '061d00000000000000000000000000007eff', # SI type 5 + '061e87e902f810031097ff2b2b2b2b2b2b2b', # SI type 6 + # DCCH + '063505', # ciphering mode cmd + '060d00', # channel release + ))) + +def test_gsmrr_mo(rr_pdu=rr_pdu_mo): + for pdu in rr_pdu: + m, e = parse_NAS_MO(pdu) + assert( e == 0 ) + m.reautomate() + v = m.get_val() + m.set_val(v) + assert( m.to_bytes() == pdu ) + +def test_gsmrr_mt(rr_pdu=rr_pdu_mt): + for pdu in rr_pdu: + m, e = parse_NAS_MT(pdu) + assert( e == 0 ) + m.reautomate() + v = m.get_val() + m.set_val(v) + assert( m.to_bytes() == pdu ) + +def test_perf(): + + print('[+] GSM RR MO decoding and re-encoding') + Ta = timeit(test_gsmrr_mo, number=10) + print('test_nas_mo: {0:.4f}'.format(Ta)) + + print('[+] GSM RR MT decoding and re-encoding') + Tb = timeit(test_gsmrr_mt, number=10) + print('test_nas_mt: {0:.4f}'.format(Tb)) + + print('[+] GSM RR total time: {0:.4f}'.format(Ta+Tb)) + +if __name__ == '__main__': + test_perf() + diff --git a/test/test_mobile.py b/test/test_mobile.py index 266f8fd..d2d460a 100644 --- a/test/test_mobile.py +++ b/test/test_mobile.py @@ -197,3 +197,4 @@ def test_perf(): if __name__ == '__main__': test_perf() +