2 * Generated by asn1c-0.9.29 (http://lionet.info/asn1c)
3 * From ASN.1 module "X2AP-IEs"
4 * found in "X2AP-15-4-0.asn1"
5 * `asn1c -D ./asn1_n1 -pdu=auto -fno-include-deps -fcompound-names -findirect-choice -gen-PER -gen-OER -no-gen-example`
8 #include "RelativeNarrowbandTxPower.h"
10 #include "ProtocolExtensionContainer.h"
12 * This type is implemented using NativeEnumerated,
13 * so here we adjust the DEF accordingly.
16 memb_rNTP_PerPRB_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
17 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
18 const BIT_STRING_t *st = (const BIT_STRING_t *)sptr;
22 ASN__CTFAIL(app_key, td, sptr,
23 "%s: value not given (%s:%d)",
24 td->name, __FILE__, __LINE__);
30 size = 8 * st->size - (st->bits_unused & 0x07);
35 if((size >= 6 && size <= 110)) {
36 /* Constraint check succeeded */
39 ASN__CTFAIL(app_key, td, sptr,
40 "%s: constraint failed (%s:%d)",
41 td->name, __FILE__, __LINE__);
47 memb_p_B_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
48 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
52 ASN__CTFAIL(app_key, td, sptr,
53 "%s: value not given (%s:%d)",
54 td->name, __FILE__, __LINE__);
58 value = *(const long *)sptr;
60 if((value >= 0 && value <= 3)) {
61 /* Constraint check succeeded */
64 ASN__CTFAIL(app_key, td, sptr,
65 "%s: constraint failed (%s:%d)",
66 td->name, __FILE__, __LINE__);
72 memb_pDCCH_InterferenceImpact_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
73 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
77 ASN__CTFAIL(app_key, td, sptr,
78 "%s: value not given (%s:%d)",
79 td->name, __FILE__, __LINE__);
83 value = *(const long *)sptr;
85 if((value >= 0 && value <= 4)) {
86 /* Constraint check succeeded */
89 ASN__CTFAIL(app_key, td, sptr,
90 "%s: constraint failed (%s:%d)",
91 td->name, __FILE__, __LINE__);
96 static asn_oer_constraints_t asn_OER_type_numberOfCellSpecificAntennaPorts_constr_4 CC_NOTUSED = {
99 static asn_per_constraints_t asn_PER_type_numberOfCellSpecificAntennaPorts_constr_4 CC_NOTUSED = {
100 { APC_CONSTRAINED | APC_EXTENSIBLE, 2, 2, 0, 2 } /* (0..2,...) */,
101 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
102 0, 0 /* No PER value map */
104 static asn_oer_constraints_t asn_OER_memb_rNTP_PerPRB_constr_2 CC_NOTUSED = {
106 -1 /* (SIZE(0..MAX)) */};
107 static asn_per_constraints_t asn_PER_memb_rNTP_PerPRB_constr_2 CC_NOTUSED = {
108 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
109 { APC_CONSTRAINED | APC_EXTENSIBLE, 7, 7, 6, 110 } /* (SIZE(6..110,...)) */,
110 0, 0 /* No PER value map */
112 static asn_oer_constraints_t asn_OER_memb_p_B_constr_9 CC_NOTUSED = {
115 static asn_per_constraints_t asn_PER_memb_p_B_constr_9 CC_NOTUSED = {
116 { APC_CONSTRAINED | APC_EXTENSIBLE, 2, 2, 0, 3 } /* (0..3,...) */,
117 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
118 0, 0 /* No PER value map */
120 static asn_oer_constraints_t asn_OER_memb_pDCCH_InterferenceImpact_constr_10 CC_NOTUSED = {
123 static asn_per_constraints_t asn_PER_memb_pDCCH_InterferenceImpact_constr_10 CC_NOTUSED = {
124 { APC_CONSTRAINED | APC_EXTENSIBLE, 3, 3, 0, 4 } /* (0..4,...) */,
125 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
126 0, 0 /* No PER value map */
128 static const asn_INTEGER_enum_map_t asn_MAP_numberOfCellSpecificAntennaPorts_value2enum_4[] = {
132 /* This list is extensible */
134 static const unsigned int asn_MAP_numberOfCellSpecificAntennaPorts_enum2value_4[] = {
138 /* This list is extensible */
140 static const asn_INTEGER_specifics_t asn_SPC_numberOfCellSpecificAntennaPorts_specs_4 = {
141 asn_MAP_numberOfCellSpecificAntennaPorts_value2enum_4, /* "tag" => N; sorted by tag */
142 asn_MAP_numberOfCellSpecificAntennaPorts_enum2value_4, /* N => "tag"; sorted by N */
143 3, /* Number of elements in the maps */
144 4, /* Extensions before this member */
145 1, /* Strict enumeration */
146 0, /* Native long size */
149 static const ber_tlv_tag_t asn_DEF_numberOfCellSpecificAntennaPorts_tags_4[] = {
150 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
151 (ASN_TAG_CLASS_UNIVERSAL | (10 << 2))
153 static /* Use -fall-defs-global to expose */
154 asn_TYPE_descriptor_t asn_DEF_numberOfCellSpecificAntennaPorts_4 = {
155 "numberOfCellSpecificAntennaPorts",
156 "numberOfCellSpecificAntennaPorts",
157 &asn_OP_NativeEnumerated,
158 asn_DEF_numberOfCellSpecificAntennaPorts_tags_4,
159 sizeof(asn_DEF_numberOfCellSpecificAntennaPorts_tags_4)
160 /sizeof(asn_DEF_numberOfCellSpecificAntennaPorts_tags_4[0]) - 1, /* 1 */
161 asn_DEF_numberOfCellSpecificAntennaPorts_tags_4, /* Same as above */
162 sizeof(asn_DEF_numberOfCellSpecificAntennaPorts_tags_4)
163 /sizeof(asn_DEF_numberOfCellSpecificAntennaPorts_tags_4[0]), /* 2 */
164 { &asn_OER_type_numberOfCellSpecificAntennaPorts_constr_4, &asn_PER_type_numberOfCellSpecificAntennaPorts_constr_4, NativeEnumerated_constraint },
165 0, 0, /* Defined elsewhere */
166 &asn_SPC_numberOfCellSpecificAntennaPorts_specs_4 /* Additional specs */
169 asn_TYPE_member_t asn_MBR_RelativeNarrowbandTxPower_1[] = {
170 { ATF_NOFLAGS, 0, offsetof(struct RelativeNarrowbandTxPower, rNTP_PerPRB),
171 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
172 -1, /* IMPLICIT tag at current level */
175 { &asn_OER_memb_rNTP_PerPRB_constr_2, &asn_PER_memb_rNTP_PerPRB_constr_2, memb_rNTP_PerPRB_constraint_1 },
176 0, 0, /* No default value */
179 { ATF_NOFLAGS, 0, offsetof(struct RelativeNarrowbandTxPower, rNTP_Threshold),
180 (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
181 -1, /* IMPLICIT tag at current level */
182 &asn_DEF_RNTP_Threshold,
185 0, 0, /* No default value */
188 { ATF_NOFLAGS, 0, offsetof(struct RelativeNarrowbandTxPower, numberOfCellSpecificAntennaPorts),
189 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
190 -1, /* IMPLICIT tag at current level */
191 &asn_DEF_numberOfCellSpecificAntennaPorts_4,
194 0, 0, /* No default value */
195 "numberOfCellSpecificAntennaPorts"
197 { ATF_NOFLAGS, 0, offsetof(struct RelativeNarrowbandTxPower, p_B),
198 (ASN_TAG_CLASS_CONTEXT | (3 << 2)),
199 -1, /* IMPLICIT tag at current level */
200 &asn_DEF_NativeInteger,
202 { &asn_OER_memb_p_B_constr_9, &asn_PER_memb_p_B_constr_9, memb_p_B_constraint_1 },
203 0, 0, /* No default value */
206 { ATF_NOFLAGS, 0, offsetof(struct RelativeNarrowbandTxPower, pDCCH_InterferenceImpact),
207 (ASN_TAG_CLASS_CONTEXT | (4 << 2)),
208 -1, /* IMPLICIT tag at current level */
209 &asn_DEF_NativeInteger,
211 { &asn_OER_memb_pDCCH_InterferenceImpact_constr_10, &asn_PER_memb_pDCCH_InterferenceImpact_constr_10, memb_pDCCH_InterferenceImpact_constraint_1 },
212 0, 0, /* No default value */
213 "pDCCH-InterferenceImpact"
215 { ATF_POINTER, 1, offsetof(struct RelativeNarrowbandTxPower, iE_Extensions),
216 (ASN_TAG_CLASS_CONTEXT | (5 << 2)),
217 -1, /* IMPLICIT tag at current level */
218 &asn_DEF_ProtocolExtensionContainer_7683P184,
221 0, 0, /* No default value */
225 static const int asn_MAP_RelativeNarrowbandTxPower_oms_1[] = { 5 };
226 static const ber_tlv_tag_t asn_DEF_RelativeNarrowbandTxPower_tags_1[] = {
227 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
229 static const asn_TYPE_tag2member_t asn_MAP_RelativeNarrowbandTxPower_tag2el_1[] = {
230 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* rNTP-PerPRB */
231 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* rNTP-Threshold */
232 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 }, /* numberOfCellSpecificAntennaPorts */
233 { (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0 }, /* p-B */
234 { (ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0 }, /* pDCCH-InterferenceImpact */
235 { (ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0 } /* iE-Extensions */
237 asn_SEQUENCE_specifics_t asn_SPC_RelativeNarrowbandTxPower_specs_1 = {
238 sizeof(struct RelativeNarrowbandTxPower),
239 offsetof(struct RelativeNarrowbandTxPower, _asn_ctx),
240 asn_MAP_RelativeNarrowbandTxPower_tag2el_1,
241 6, /* Count of tags in the map */
242 asn_MAP_RelativeNarrowbandTxPower_oms_1, /* Optional members */
243 1, 0, /* Root/Additions */
244 6, /* First extension addition */
246 asn_TYPE_descriptor_t asn_DEF_RelativeNarrowbandTxPower = {
247 "RelativeNarrowbandTxPower",
248 "RelativeNarrowbandTxPower",
250 asn_DEF_RelativeNarrowbandTxPower_tags_1,
251 sizeof(asn_DEF_RelativeNarrowbandTxPower_tags_1)
252 /sizeof(asn_DEF_RelativeNarrowbandTxPower_tags_1[0]), /* 1 */
253 asn_DEF_RelativeNarrowbandTxPower_tags_1, /* Same as above */
254 sizeof(asn_DEF_RelativeNarrowbandTxPower_tags_1)
255 /sizeof(asn_DEF_RelativeNarrowbandTxPower_tags_1[0]), /* 1 */
256 { 0, 0, SEQUENCE_constraint },
257 asn_MBR_RelativeNarrowbandTxPower_1,
258 6, /* Elements count */
259 &asn_SPC_RelativeNarrowbandTxPower_specs_1 /* Additional specs */