1 /*******************************************************************************
2 ################################################################################
3 # Copyright (c) [2017-2019] [Radisys] #
5 # Licensed under the Apache License, Version 2.0 (the "License"); #
6 # you may not use this file except in compliance with the License. #
7 # You may obtain a copy of the License at #
9 # http://www.apache.org/licenses/LICENSE-2.0 #
11 # Unless required by applicable law or agreed to in writing, software #
12 # distributed under the License is distributed on an "AS IS" BASIS, #
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
14 # See the License for the specific language governing permissions and #
15 # limitations under the License. #
16 ################################################################################
17 *******************************************************************************/
19 /* This file contains functions that maps values received in F1AP message with
20 * its corresponding values used in DU and vice-versa */
22 #include "common_def.h"
23 #include "BSR-Config.h"
24 #include "du_f1ap_conversions.h"
26 /************************************************************************
28 * @brief Coverts Internal Enum value to RRC code enum for RB type
32 * Function : covertRbTypeFromIntEnumToRrcEnum
34 * Functionality: Coverts Internal Enum value to RRC code enum for RB type
36 * @params[in] Internal Enum value for RB type
37 * @return RRC codec enum value for RB type
39 * **********************************************************************/
40 RLC_BearerConfig__servedRadioBearer_PR covertRbTypeFromIntEnumToRrcEnum(RlcRbType rbType)
45 return RLC_BearerConfig__servedRadioBearer_PR_srb_Identity;
47 return RLC_BearerConfig__servedRadioBearer_PR_drb_Identity;
49 return RLC_BearerConfig__servedRadioBearer_PR_NOTHING;
53 /************************************************************************
55 * @brief Coverts internal enum value to RRC code enum for RLC mode
59 * Function : covertRlcModeFromIntEnumToRrcEnum
61 * Functionality: Coverts internal enum value to RRC code enum for RLC mode
63 * @params[in] Internal enum value for RLC mode
64 * @return RRC codec enum value for RLC mode
66 * **********************************************************************/
67 RLC_Config_PR covertRlcModeFromIntEnumToRrcEnum(RlcMode mode)
72 return RLC_Config_PR_am;
73 case RLC_UM_BI_DIRECTIONAL:
74 return RLC_Config_PR_um_Bi_Directional;
75 case RLC_UM_UNI_DIRECTIONAL_UL:
76 return RLC_Config_PR_um_Uni_Directional_UL;
77 case RLC_UM_UNI_DIRECTIONAL_DL:
78 return RLC_Config_PR_um_Uni_Directional_DL;
80 return RLC_Config_PR_NOTHING;
84 /************************************************************************
86 * @brief Converts Internal enum value to RRC code enum value for AM mode
91 * Function : covertAmSnLenFromIntEnumToRrcEnum
93 * Functionality: Converts Internal enum value to RRC code enum value for AM
96 * @params[in] Internal Enum value
97 * @return RRC Enum value
99 * **********************************************************************/
100 SN_FieldLengthAM_t covertAmSnLenFromIntEnumToRrcEnum(SnLenAm snLen)
105 return SN_FieldLengthAM_size12;
107 return SN_FieldLengthAM_size18;
109 return SN_FieldLengthAM_size12;
113 /************************************************************************
115 * @brief Coverts RRC ASN enum value to Internal Enum value
119 * Function : covertAmSnLenFromRrcEnumToIntEnum
121 * Functionality: Coverts RRC ASN enum value to Internal Enum value for
124 * @params[in] RRC ASN Enum value
125 * @return Internal Enum value
127 * **********************************************************************/
128 SnLenAm covertAmSnLenFromRrcEnumToIntEnum(SN_FieldLengthAM_t snLen)
132 case SN_FieldLengthAM_size12:
134 case SN_FieldLengthAM_size18:
141 /************************************************************************
143 * @brief Coverts Internal Enum value to RRC ASN enum value
147 * Function : covertUmSnLenFromIntEnumToRrcEnum
149 * Functionality: Coverts Internal ennum value to RRC ASN enum value
150 * for UM mode SN length
152 * @params[in] Internal enum value
153 * @return RRC ASN value
155 * **********************************************************************/
156 SN_FieldLengthUM_t covertUmSnLenFromIntEnumToRrcEnum(SnLenUm snLen)
161 return SN_FieldLengthUM_size6;
163 return SN_FieldLengthUM_size12;
165 return SN_FieldLengthUM_size12;
169 /************************************************************************
171 * @brief Converts RRC ASN enum value to Internal enum value
175 * Function : covertUmSnLenFromRrcEnumToIntEnum
177 * Functionality: Converts RRC ASN enum value to Internal enum value
178 * for UM mode SN length
180 * @params[in] RRC ASN enum value
181 * @return Internal enum value
183 * **********************************************************************/
184 SnLenUm covertUmSnLenFromRrcEnumToIntEnum(SN_FieldLengthUM_t snLen)
188 case SN_FieldLengthUM_size6:
190 case SN_FieldLengthUM_size12:
197 /************************************************************************
199 * @brief Converts poll retransmission timer value to its corresponding enum
203 * Function : covertPollRetxTmrValueToEnum
205 * Functionality: Converts poll retransmission timer value to its
208 * @params[in] Poll retransmission timer value
209 * @return Poll retransmission timer enum
211 * **********************************************************************/
212 T_PollRetransmit_t covertPollRetxTmrValueToEnum(uint16_t pollRetxTmr)
214 /* All values of poll retx timer are at interval of 5ms starting from 5ms(Enum value 0) upto 250ms
215 * Hence converting the value to enum by dividing it to 5 and subtracting 1.
217 if((pollRetxTmr <= 250) && ((pollRetxTmr%5) == 0))
218 return ((pollRetxTmr/5) -1);
224 return T_PollRetransmit_ms300;
226 return T_PollRetransmit_ms350;
228 return T_PollRetransmit_ms400;
230 return T_PollRetransmit_ms450;
232 return T_PollRetransmit_ms500;
234 return T_PollRetransmit_ms800;
236 return T_PollRetransmit_spare5;
241 /************************************************************************
243 * @brief Converts enum values into actual value of Poll retransmit timer
247 * Function : covertPollRetxTmrEnumToValue
249 * Functionality: Converts enum values into actual value of poll
252 * @params[in] Enum value of pollPdu
253 * @return Actual value of pollPdu
255 * **********************************************************************/
257 uint16_t covertPollRetxTmrEnumToValue(uint8_t pollRetxTmrCfg)
259 uint16_t pollRetxTmr;
261 /* All values of poll retx timer are at interval of 5ms.
262 * This is valid upto 250ms
263 * Hence converting the enum value to actual value by multiplying it to 5
265 if(pollRetxTmrCfg <= T_PollRetransmit_ms250)
266 pollRetxTmr = (pollRetxTmrCfg + 1) * 5;
269 switch(pollRetxTmrCfg)
271 case T_PollRetransmit_ms300:
274 case T_PollRetransmit_ms350:
277 case T_PollRetransmit_ms400:
280 case T_PollRetransmit_ms450:
283 case T_PollRetransmit_ms500:
286 case T_PollRetransmit_ms800:
290 DU_LOG("\nERROR --> F1AP: Invalid value of Poll Retransmit timer");
297 /************************************************************************
299 * @brief Coverts the value of Poll pdu to its corresponding enum
303 * Function : covertPollPduValueToEnum
305 * Functionality: Coverts the value of Poll pdu to its corresponding enum
307 * @params[in] Poll PDU value
308 * @return Poll PDU enum
310 * **********************************************************************/
311 PollPDU_t covertPollPduValueToEnum(int32_t pollPdu)
332 return PollPDU_p1024;
334 return PollPDU_p2048;
336 return PollPDU_p4096;
338 return PollPDU_p6144;
340 return PollPDU_p8192;
342 return PollPDU_p12288;
344 return PollPDU_p16384;
346 return PollPDU_p20480;
348 return PollPDU_p24576;
350 return PollPDU_p28672;
352 return PollPDU_p32768;
354 return PollPDU_p40960;
356 return PollPDU_p49152;
358 return PollPDU_p57344;
360 return PollPDU_p65536;
362 return PollPDU_infinity;
364 return PollPDU_spare8;
366 return PollPDU_spare8;
369 /*******************************************************************
371 * @brief Converts enum values into actual value of PollPdu
375 * Function : covertPollPduEnumToValue
377 * Functionality: Converts enum values into actual value of PollPdu
379 * @params[in] Enum value of pollPdu
380 * @return Actual value of pollPdu
382 * ****************************************************************/
383 int32_t covertPollPduEnumToValue(uint8_t pollPduCfg)
457 case PollPDU_infinity:
461 DU_LOG("\nERROR --> F1AP: Invalid value of poll pdu");
468 /************************************************************************
470 * @brief Converts Poll byte value to its corresponding enum
474 * Function : covertPollByteValueToEnum
476 * Functionality: Converts Poll byte value to its corresponding enum
478 * @params[in] Poll Byte value
479 * @return Poll Byte enum
481 * **********************************************************************/
482 PollByte_t covertPollByteValueToEnum(int32_t pollByte)
495 return PollByte_kB10;
497 return PollByte_kB15;
499 return PollByte_kB25;
501 return PollByte_kB50;
503 return PollByte_kB75;
505 return PollByte_kB100;
507 return PollByte_kB125;
509 return PollByte_kB250;
511 return PollByte_kB375;
513 return PollByte_kB500;
515 return PollByte_kB750;
517 return PollByte_kB1000;
519 return PollByte_kB1250;
521 return PollByte_kB1500;
523 return PollByte_kB2000;
525 return PollByte_kB3000;
527 return PollByte_kB4000;
529 return PollByte_kB4500;
531 return PollByte_kB5000;
533 return PollByte_kB5500;
535 return PollByte_kB6000;
537 return PollByte_kB6500;
539 return PollByte_kB7000;
541 return PollByte_kB7500;
547 return PollByte_mB10;
549 return PollByte_mB11;
551 return PollByte_mB12;
553 return PollByte_mB13;
555 return PollByte_mB14;
557 return PollByte_mB15;
559 return PollByte_mB16;
561 return PollByte_mB17;
563 return PollByte_mB18;
565 return PollByte_mB20;
567 return PollByte_mB25;
569 return PollByte_mB30;
571 return PollByte_mB40;
573 return PollByte_infinity;
575 return PollByte_spare20;
579 /*******************************************************************
581 * @brief Converts enum values into actual value of poll bytes
585 * Function : covertPollByteEnumToValue
587 * Functionality: Converts enum values into actual value of pollBytes
589 * @params[in] Enum value
590 * @return Actual value
592 * ****************************************************************/
593 int32_t covertPollByteEnumToValue(uint16_t pollBytesCfg)
643 case PollByte_kB1000:
646 case PollByte_kB1250:
649 case PollByte_kB1500:
652 case PollByte_kB2000:
655 case PollByte_kB3000:
658 case PollByte_kB4000:
661 case PollByte_kB4500:
664 case PollByte_kB5000:
667 case PollByte_kB5500:
670 case PollByte_kB6000:
673 case PollByte_kB6500:
676 case PollByte_kB7000:
679 case PollByte_kB7500:
689 pollBytes = 10000000;
692 pollBytes = 11000000;
695 pollBytes = 12000000;
698 pollBytes = 13000000;
701 pollBytes = 14000000;
704 pollBytes = 15000000;
707 pollBytes = 16000000;
710 pollBytes = 17000000;
713 pollBytes = 18000000;
716 pollBytes = 20000000;
719 pollBytes = 25000000;
722 pollBytes = 30000000;
725 pollBytes = 40000000;
727 case PollByte_infinity:
731 DU_LOG("\nERROR --> F1AP: Invalid value of poll bytes");
737 /************************************************************************
739 * @brief Converts Max retranmission value to enum
743 * Function : covertMaxRetxValueToEnum
745 * Functionality: Converts Max retranmission value to enum
747 * @params[in] Max retransmission value
748 * @return Max retransmission enum
750 * **********************************************************************/
751 uint8_t covertMaxRetxValueToEnum(uint8_t maxRetx)
756 return UL_AM_RLC__maxRetxThreshold_t1;
758 return UL_AM_RLC__maxRetxThreshold_t2;
760 return UL_AM_RLC__maxRetxThreshold_t3;
762 return UL_AM_RLC__maxRetxThreshold_t4;
764 return UL_AM_RLC__maxRetxThreshold_t6;
766 return UL_AM_RLC__maxRetxThreshold_t8;
768 return UL_AM_RLC__maxRetxThreshold_t16;
770 return UL_AM_RLC__maxRetxThreshold_t32;
772 return UL_AM_RLC__maxRetxThreshold_t8;
775 /*******************************************************************
777 * @brief Converts enum values into actual value of maxRetx
781 * Function : covertMaxRetxEnumToValue
783 * Functionality: Converts enum values into actual value of maxRetx
785 * @params[in] Enum value
786 * @return Actual value
788 * ****************************************************************/
789 uint8_t covertMaxRetxEnumToValue(uint8_t maxRetxCfg)
794 case UL_AM_RLC__maxRetxThreshold_t1:
797 case UL_AM_RLC__maxRetxThreshold_t2:
800 case UL_AM_RLC__maxRetxThreshold_t3:
803 case UL_AM_RLC__maxRetxThreshold_t4:
806 case UL_AM_RLC__maxRetxThreshold_t6:
809 case UL_AM_RLC__maxRetxThreshold_t8:
812 case UL_AM_RLC__maxRetxThreshold_t16:
815 case UL_AM_RLC__maxRetxThreshold_t32:
819 DU_LOG("\nERROR --> F1AP: Invalid configuration for Max retransmission threshold");
825 /************************************************************************
827 * @brief Converts reassembly timer value to its ASN enum
831 * Function : convertReasmblTmrValueToEnum
833 * Functionality: Converts reassembly timer value to its ASN enum
835 * @params[in] Reassembly timer value
836 * @return Reassembly timer enum
838 * **********************************************************************/
839 T_Reassembly_t convertReasmblTmrValueToEnum(int8_t reasmblTmr)
842 return T_Reassembly_ms0;
843 else if((reasmblTmr >=5 && reasmblTmr <= 100) && ((reasmblTmr % 5) == 0))
844 return (reasmblTmr/5);
845 else if((reasmblTmr <= 200) && ((reasmblTmr % 10) == 0))
846 return ((reasmblTmr/10) +10);
848 return T_Reassembly_spare1;
851 /*******************************************************************
852 * @brief Converts enum values into actual value of reassembly timer
856 * Function : convertReasmblTmrEnumToValue
858 * Functionality: Converts enum values into actual value of reassembly
861 * @params[in] Enum value of reassembly timer
862 * @return Actual value of reassembly timer
864 * **********************************************************************/
866 int8_t convertReasmblTmrEnumToValue(uint8_t reAsmblTmrCfg)
868 int8_t reAsmblTmr = 0;
870 if(reAsmblTmrCfg == T_Reassembly_ms0)
874 else if(reAsmblTmrCfg >= T_Reassembly_ms5 || reAsmblTmrCfg <= T_Reassembly_ms100)
876 /* All values of re assembly timer are at interval of 5ms.
877 * This is valid upto 100ms
878 * Hence converting the enum value to actual value by multiplying it to 5
880 reAsmblTmr = reAsmblTmrCfg * 5;
882 else if(reAsmblTmrCfg >= T_Reassembly_ms110 || reAsmblTmrCfg <= T_Reassembly_ms200)
884 /* All values of re assembly timer are at interval of 10ms.
885 * This is valid upto 200ms
886 * since enum value starts from 20 for 100ms, subtracting 10 and
887 * converting the enum value to actual value by multiplying it to 10
889 reAsmblTmr = ((reAsmblTmrCfg-10) * 10);
893 DU_LOG("\nERROR --> F1AP : Invalid value of Re Assembly timer %d", reAsmblTmrCfg);
899 /************************************************************************
901 * @brief Converts Prohibit timer value to its ASN enum
905 * Function : convertProhibitTmrValueToEnum
907 * Functionality: Converts Prohibit timer value to its ASN enum
909 * @params[in] Prohibit timer value
910 * @return Prohibit timer enum
912 * **********************************************************************/
913 T_StatusProhibit_t convertProhibitTmrValueToEnum(int16_t prohibitTmr)
916 return T_StatusProhibit_ms0;
917 else if((prohibitTmr >= 5) && (prohibitTmr <= 250) && ((prohibitTmr % 5) == 0))
918 return prohibitTmr/5;
924 return T_StatusProhibit_ms300;
926 return T_StatusProhibit_ms350;
928 return T_StatusProhibit_ms400;
930 return T_StatusProhibit_ms450;
932 return T_StatusProhibit_ms500;
934 return T_StatusProhibit_ms800;
936 return T_StatusProhibit_ms1000;
938 return T_StatusProhibit_ms1200;
940 return T_StatusProhibit_ms1600;
942 return T_StatusProhibit_ms2000;
944 return T_StatusProhibit_ms2400;
946 return T_StatusProhibit_spare2;
951 /************************************************************************
953 * @brief Converts Prohibit timer enum to its actual value
957 * Function : convertProhibitTmrEnumToValue
959 * Functionality: Converts Prohibit timer enum to its actual value
961 * @params[in] Prohibit timer enum
962 * @return Prohibit timer value
964 * **********************************************************************/
965 int16_t convertProhibitTmrEnumToValue(T_StatusProhibit_t prohibitTmr)
967 if(prohibitTmr == T_StatusProhibit_ms0)
969 else if((prohibitTmr >= T_StatusProhibit_ms5) && (prohibitTmr <= T_StatusProhibit_ms250))
970 return prohibitTmr*5;
975 case T_StatusProhibit_ms300:
977 case T_StatusProhibit_ms350:
979 case T_StatusProhibit_ms400:
981 case T_StatusProhibit_ms450:
983 case T_StatusProhibit_ms500:
985 case T_StatusProhibit_ms800:
987 case T_StatusProhibit_ms1000:
989 case T_StatusProhibit_ms1200:
991 case T_StatusProhibit_ms1600:
993 case T_StatusProhibit_ms2000:
995 case T_StatusProhibit_ms2400:
1003 /************************************************************************
1005 * @brief Converts internal enum value to RRC ASN enum value
1009 * Function : covertPucchFormatIntEnumToRrcEnum
1011 * Functionality: Converts internal enum value to RRC ASN enum value
1014 * @params[in] PUCCH format value in internal enum
1015 * @return PUCCH format value RRC ASN enum
1017 * **********************************************************************/
1018 PUCCH_Resource__format_PR covertPucchFormatIntEnumToRrcEnum(uint8_t pucchFormat)
1022 case PUCCH_FORMAT_0:
1023 return PUCCH_Resource__format_PR_format0;
1024 case PUCCH_FORMAT_1:
1025 return PUCCH_Resource__format_PR_format1;
1026 case PUCCH_FORMAT_2:
1027 return PUCCH_Resource__format_PR_format2;
1028 case PUCCH_FORMAT_3:
1029 return PUCCH_Resource__format_PR_format3;
1030 case PUCCH_FORMAT_4:
1031 return PUCCH_Resource__format_PR_format4;
1033 return PUCCH_Resource__format_PR_NOTHING;
1035 return PUCCH_Resource__format_PR_NOTHING;
1038 /************************************************************************
1040 * @brief Converts BSR Periodic timer value to its ASN enum value
1044 * Function : convertBsrPeriodicTmrValueToEnum
1046 * Functionality: Converts BSR Periodic timer timer value to its ASN enum value
1048 * @params[in] BSR Periodic timer value
1049 * @return BSR Periodic timer ASN enum
1051 * **********************************************************************/
1052 long convertBsrPeriodicTmrValueToEnum(int16_t periodicTmr)
1057 return BSR_Config__periodicBSR_Timer_sf1;
1059 return BSR_Config__periodicBSR_Timer_sf5;
1061 return BSR_Config__periodicBSR_Timer_sf10;
1063 return BSR_Config__periodicBSR_Timer_sf16;
1065 return BSR_Config__periodicBSR_Timer_sf20;
1067 return BSR_Config__periodicBSR_Timer_sf32;
1069 return BSR_Config__periodicBSR_Timer_sf40;
1071 return BSR_Config__periodicBSR_Timer_sf64;
1073 return BSR_Config__periodicBSR_Timer_sf80;
1075 return BSR_Config__periodicBSR_Timer_sf128;
1077 return BSR_Config__periodicBSR_Timer_sf320;
1079 return BSR_Config__periodicBSR_Timer_sf640;
1081 return BSR_Config__periodicBSR_Timer_sf1280;
1083 return BSR_Config__periodicBSR_Timer_sf2560;
1085 return BSR_Config__periodicBSR_Timer_infinity;
1087 return BSR_Config__periodicBSR_Timer_sf10;
1091 /************************************************************************
1093 * @brief Converts BSR Retransmission timer value to its ASN enum value
1097 * Function : convertBsrRetxTmrValueToEnum
1099 * Functionality: Converts BSR Retransmission timer timer value to its ASN enum value
1101 * @params[in] BSR Retransmission timer value
1102 * @return BSR Restransmission timer ASN enum
1104 * **********************************************************************/
1105 long convertBsrRetxTmrValueToEnum(uint16_t retxTmr)
1110 return BSR_Config__retxBSR_Timer_sf10;
1112 return BSR_Config__retxBSR_Timer_sf20;
1114 return BSR_Config__retxBSR_Timer_sf40;
1116 return BSR_Config__retxBSR_Timer_sf80;
1118 return BSR_Config__retxBSR_Timer_sf160;
1120 return BSR_Config__retxBSR_Timer_sf320;
1122 return BSR_Config__retxBSR_Timer_sf640;
1124 return BSR_Config__retxBSR_Timer_sf1280;
1126 return BSR_Config__retxBSR_Timer_sf2560;
1128 return BSR_Config__retxBSR_Timer_sf5120;
1130 return BSR_Config__retxBSR_Timer_sf10240;
1132 return BSR_Config__retxBSR_Timer_sf320;
1136 /************************************************************************
1138 * @brief Converts LC SR Delay timer value to its ASN enum value
1142 * Function : convertLcSrDelayTmrValueToEnum
1144 * Functionality: Converts LC SR Delay timer value to its ASN enum value
1146 * @params[in] LC SR Delay timer value
1147 * @return LC SR Delay timer ASN enum
1149 * **********************************************************************/
1150 long convertLcSrDelayTmrValueToEnum(uint16_t delayTimer)
1155 return BSR_Config__logicalChannelSR_DelayTimer_sf20;
1157 return BSR_Config__logicalChannelSR_DelayTimer_sf40;
1159 return BSR_Config__logicalChannelSR_DelayTimer_sf64;
1161 return BSR_Config__logicalChannelSR_DelayTimer_sf128;
1163 return BSR_Config__logicalChannelSR_DelayTimer_sf512;
1165 return BSR_Config__logicalChannelSR_DelayTimer_sf1024;
1167 return BSR_Config__logicalChannelSR_DelayTimer_sf2560;
1169 return BSR_Config__logicalChannelSR_DelayTimer_sf2560;
1173 /************************************************************************
1175 * @brief Converts actual values into enum value of Paging DRX cycle
1179 * Function : convertPagingCycleValueToEnum
1181 * Functionality: As per Spec 38.331,
1182 * Converts Actual values into enum value of Paging DRX cycle
1185 * @params[in] Actual value of PagingDRX
1186 * @return Enum value of DRX cycle
1188 * **********************************************************************/
1189 e_PagingDRX convertPagingCycleValueToEnum(uint16_t pagingDrxCycle)
1191 switch(pagingDrxCycle)
1194 return PagingDRX_v32;
1196 return PagingDRX_v64;
1198 return PagingDRX_v128;
1200 return PagingDRX_v256;
1202 return PagingDRX_v32;
1206 /************************************************************************
1208 * @brief Converts enum values into actual value of Paging DRX cycle
1212 * Function : convertPagingCycleEnumToValue
1214 * Functionality: As per Spec 38.331,
1215 * Converts enum values into actual value of Paging DRX cycle
1218 * @params[in] Enum value of PagingDRX
1219 * @return Actual value of DRX cycle
1220 * Note: Returning the MAX value in case of Incorrect Enum Value as DRX
1221 * cycle is MIN of Various DRX cycles(Mentioned in Spec38.304)
1223 * **********************************************************************/
1224 uint16_t convertPagingCycleEnumToValue(e_PagingDRX pagingDrx)
1232 case PagingDRX_v128:
1234 case PagingDRX_v256:
1240 /************************************************************************
1242 * @brief Converts enum values into actual value of Num of Paging Ocassions
1246 * Function : convertPagingOccEnumToValue
1248 * Functionality: As per Spec 38.331,
1249 * Converts enum values into actual value of Num of Paging Ocassion
1252 * @params[in] Enum value of Ns
1253 * @return Actual value of Num of Paging Ocassions
1255 * **********************************************************************/
1256 uint8_t convertNsEnumToValue(e_PCCH_Config__ns Ns)
1260 case PCCH_Config__ns_four:
1262 case PCCH_Config__ns_two:
1264 case PCCH_Config__ns_one:
1271 /************************************************************************
1273 * @brief Converts actual values into enum value of Num of Paging Ocassions
1277 * Function : convertNsValueToEnum
1279 * Functionality: As per Spec 38.331,
1280 * Converts actual values into enum value of Num of Paging Ocassions
1283 * @params[in] Actual value of Num of Paging Ocassions
1284 * @return Enum value of Ns
1286 * **********************************************************************/
1287 e_PCCH_Config__ns convertNsValueToEnum(uint8_t numPO)
1292 return PCCH_Config__ns_one;
1294 return PCCH_Config__ns_two;
1296 return PCCH_Config__ns_four;
1298 return PCCH_Config__ns_one;
1302 /************************************************************************
1304 * @brief Converts actual values into enum value of SSB Periodicity in SIB
1308 * Function : convertSsbPeriodicityValueToEnumForSib
1311 * Converts actual values into enum value of SSB Periodicity in SIB
1314 * @params[in] Actual value of SSB Periodicity
1315 * @return Enum value of SSB Periodicity
1317 * **********************************************************************/
1318 e_ServingCellConfigCommonSIB__ssb_PeriodicityServingCell convertSsbPeriodicityValueToEnumForSib(uint16_t ssbPeriodicity)
1320 switch(ssbPeriodicity)
1323 return ServingCellConfigCommonSIB__ssb_PeriodicityServingCell_ms5;
1325 return ServingCellConfigCommonSIB__ssb_PeriodicityServingCell_ms10;
1327 return ServingCellConfigCommonSIB__ssb_PeriodicityServingCell_ms20;
1329 return ServingCellConfigCommonSIB__ssb_PeriodicityServingCell_ms40;
1331 return ServingCellConfigCommonSIB__ssb_PeriodicityServingCell_ms80;
1333 return ServingCellConfigCommonSIB__ssb_PeriodicityServingCell_ms160;
1335 return ServingCellConfigCommonSIB__ssb_PeriodicityServingCell_ms20;
1339 /************************************************************************
1341 * @brief Converts actual values into enum value of SSB Periodicity
1345 * Function : convertSsbPeriodicityValueToEnum
1348 * Converts actual values into enum value of SSB Periodicity
1351 * @params[in] Actual value of SSB Periodicity
1352 * @return Enum value of SSB Periodicity
1354 * **********************************************************************/
1355 e_ServingCellConfigCommon__ssb_periodicityServingCell convertSsbPeriodicityValueToEnum(uint16_t ssbPeriodicity)
1357 switch(ssbPeriodicity)
1360 return ServingCellConfigCommon__ssb_periodicityServingCell_ms5;
1362 return ServingCellConfigCommon__ssb_periodicityServingCell_ms10;
1364 return ServingCellConfigCommon__ssb_periodicityServingCell_ms20;
1366 return ServingCellConfigCommon__ssb_periodicityServingCell_ms40;
1368 return ServingCellConfigCommon__ssb_periodicityServingCell_ms80;
1370 return ServingCellConfigCommon__ssb_periodicityServingCell_ms160;
1372 return ServingCellConfigCommon__ssb_periodicityServingCell_ms20;
1376 /************************************************************************
1378 * @brief Converts actual values into enum value of SSB per RACH occassion
1383 * Function : convertCFRASsbPerRachOccasionValueToEnum
1386 * Converts actual values into enum value of SSB occasion per RACH
1387 * occassion for CFRA
1389 * @params[in] Actual value of SSB Occasion per RACH
1390 * @return Enum value
1392 * **********************************************************************/
1393 e_CFRA__occasions__ssb_perRACH_Occasion convertCFRASsbPerRachOccasionValueToEnum(uint8_t ssbOccPerRach)
1395 switch(ssbOccPerRach)
1398 return CFRA__occasions__ssb_perRACH_Occasion_one;
1400 return CFRA__occasions__ssb_perRACH_Occasion_two;
1402 return CFRA__occasions__ssb_perRACH_Occasion_four;
1404 return CFRA__occasions__ssb_perRACH_Occasion_eight;
1406 return CFRA__occasions__ssb_perRACH_Occasion_sixteen;
1408 return CFRA__occasions__ssb_perRACH_Occasion_one;
1412 /************************************************************************
1414 * @brief Converts actual values into enum value of CB Preamble per SSB
1415 * for one SSB per RACH occassion
1419 * Function : convertCbPreamblePerSsbValueToEnum
1422 * Converts actual values into enum value of CB Preamble per
1423 * SSB for one SSB per RACH occasion
1425 * @params[in] Actual value of CB preambles per SSB
1426 * @return Enum value
1428 * **********************************************************************/
1429 e_RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one convertCbPreamblePerSsbValueToEnum(uint8_t numCbPreamblePerSsb)
1431 switch(numCbPreamblePerSsb)
1434 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n4;
1436 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n8;
1438 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n12;
1440 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n16;
1442 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n20;
1444 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n24;
1446 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n28;
1448 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n32;
1450 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n36;
1452 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n40;
1454 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n44;
1456 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n48;
1458 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n52;
1460 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n56;
1462 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n60;
1464 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n64;
1466 return RACH_ConfigCommon__ssb_perRACH_OccasionAndCB_PreamblesPerSSB__one_n8;
1470 /************************************************************************
1472 * @brief Converts actual values into enum value of DMRS Type A Position
1477 * Function : convertDmrsTypeAPosValueToEnum
1480 * Converts actual values into enum value of DMRS Type A Position
1482 * @params[in] Actual value of DMRS Type A Position
1483 * @return Enum value
1485 * **********************************************************************/
1486 e_ServingCellConfigCommon__dmrs_TypeA_Position convertDmrsTypeAPosValueToEnum(uint8_t dmrsTypeAPos)
1488 switch(dmrsTypeAPos)
1491 return ServingCellConfigCommon__dmrs_TypeA_Position_pos2;
1493 return ServingCellConfigCommon__dmrs_TypeA_Position_pos3;
1495 return ServingCellConfigCommon__dmrs_TypeA_Position_pos2;
1499 /************************************************************************
1501 * @brief Converts enum values into actual value of Long drx Cycle length
1505 * Function : convertLongDrxCycleLengthEnumToValue
1507 * Functionality: As per Spec 38.331,
1508 * Converts enum values into actual value of Long drx Cycle length
1511 * @params[in] Enum value of e_LongDRXCycleLength
1512 * @return Actual value of long Drx cycle length
1514 * **********************************************************************/
1515 uint16_t convertLongDrxCycleLengthEnumToValue(e_LongDRXCycleLength longDrxCycleLength)
1517 switch(longDrxCycleLength)
1519 case LongDRXCycleLength_ms10:
1521 case LongDRXCycleLength_ms20:
1523 case LongDRXCycleLength_ms32:
1525 case LongDRXCycleLength_ms40:
1527 case LongDRXCycleLength_ms60:
1529 case LongDRXCycleLength_ms64:
1531 case LongDRXCycleLength_ms70:
1533 case LongDRXCycleLength_ms80:
1535 case LongDRXCycleLength_ms128:
1537 case LongDRXCycleLength_ms160:
1539 case LongDRXCycleLength_ms256:
1541 case LongDRXCycleLength_ms320:
1543 case LongDRXCycleLength_ms512:
1545 case LongDRXCycleLength_ms640:
1547 case LongDRXCycleLength_ms1024:
1549 case LongDRXCycleLength_ms1280:
1551 case LongDRXCycleLength_ms2048:
1553 case LongDRXCycleLength_ms2560:
1555 case LongDRXCycleLength_ms5120:
1557 case LongDRXCycleLength_ms10240:
1563 /************************************************************************
1565 * @brief Converts enum values into actual value of Short drx Cycle length
1569 * Function : convertShortDrxCycleLengthEnumToValue
1571 * Functionality: As per Spec 38.331,
1572 * Converts enum values into actual value of Short drx Cycle length
1575 * @params[in] Enum value of e_ShortDRXCycleLength
1576 * @return Actual value of short Drx cycle length
1578 * **********************************************************************/
1579 uint16_t convertShortDrxCycleLengthEnumToValue(e_ShortDRXCycleLength shortDrxCycleLength)
1581 switch(shortDrxCycleLength)
1583 case ShortDRXCycleLength_ms2:
1585 case ShortDRXCycleLength_ms3:
1587 case ShortDRXCycleLength_ms4:
1589 case ShortDRXCycleLength_ms5:
1591 case ShortDRXCycleLength_ms6:
1593 case ShortDRXCycleLength_ms7:
1595 case ShortDRXCycleLength_ms8:
1597 case ShortDRXCycleLength_ms10:
1599 case ShortDRXCycleLength_ms14:
1601 case ShortDRXCycleLength_ms16:
1603 case ShortDRXCycleLength_ms20:
1605 case ShortDRXCycleLength_ms30:
1607 case ShortDRXCycleLength_ms32:
1609 case ShortDRXCycleLength_ms35:
1611 case ShortDRXCycleLength_ms40:
1613 case ShortDRXCycleLength_ms64:
1615 case ShortDRXCycleLength_ms80:
1617 case ShortDRXCycleLength_ms128:
1619 case ShortDRXCycleLength_ms160:
1621 case ShortDRXCycleLength_ms256:
1623 case ShortDRXCycleLength_ms320:
1625 case ShortDRXCycleLength_ms512:
1627 case ShortDRXCycleLength_ms640:
1633 /************************************************************************
1635 * @brief Converts actual value of long drx Cycle length to enum value
1639 * Function : convertLongDrxCycleLengthValueToEnum
1641 * Functionality: As per Spec 38.331,
1642 * Converts actual value of long drx Cycle length to enum value
1644 * @params[in] uint16_t longDRXCycleLength
1645 * @return enum value of long drx cycle
1647 * **********************************************************************/
1648 enum DRX_ConfigRrc__drx_LongCycleStartOffset_PR convertLongDrxCycleLengthValueToEnum(uint16_t longDrxCycleLength)
1650 switch(longDrxCycleLength)
1653 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms10;
1655 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms20;
1657 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms32;
1659 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms40;
1661 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms60;
1663 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms64;
1665 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms70;
1667 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms80;
1669 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms128;
1671 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms160;
1673 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms256;
1675 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms320;
1677 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms512;
1679 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms640;
1681 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms1024;
1683 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms1280;
1685 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms2048;
1687 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms2560;
1689 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms5120;
1691 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms10240;
1693 return DRX_ConfigRrc__drx_LongCycleStartOffset_PR_ms20;
1696 /************************************************************************
1698 * @brief Converts actual value of Short drx Cycle length to enum value
1702 * Function : convertShortDrxCycleLengthValueToEnum
1704 * Functionality: As per Spec 38.331,
1705 * Converts actual value of Short drx Cycle length to enum value
1707 * @params[in] uint16_t shortDRXCycleLength
1708 * @return enum value of short drx cycle
1710 * **********************************************************************/
1711 e_DRX_ConfigRrc__shortDRX__drx_ShortCycle convertShortDrxCycleLengthValueToEnum(uint16_t shortDrxCycleLength)
1713 switch(shortDrxCycleLength)
1716 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms2;
1718 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms3;
1720 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms4;
1722 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms5;
1724 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms6;
1726 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms7;
1728 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms8;
1730 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms10;
1732 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms14;
1734 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms16;
1736 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms20;
1738 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms30;
1740 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms32;
1742 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms35;
1744 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms40;
1746 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms64;
1748 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms80;
1750 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms128;
1752 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms160;
1754 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms256;
1756 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms320;
1758 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms512;
1760 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms640;
1762 return DRX_ConfigRrc__shortDRX__drx_ShortCycle_ms2;
1765 /************************************************************************
1767 * @brief Converts actual value of ondurationTime length to enum value
1771 * Function : convertOnDurationTimerMilliSecondsValueToEnum
1773 * Functionality: As per Spec 38.331,
1774 * Converts actual value of ondurationTime to enum value
1776 * @params[in] uint16_t ondurationTime
1777 * @return enum value of onDurationTimer in milliSeconds
1779 * **********************************************************************/
1780 e_DRX_ConfigRrc__drx_onDurationTimer__milliSeconds convertOnDurationTimerMilliSecondsValueToEnum(uint16_t ondurationTime)
1782 switch(ondurationTime)
1785 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1;
1787 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms2;
1789 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms3;
1791 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms4;
1793 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms5;
1795 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms6;
1797 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms8;
1799 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms10;
1801 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms20;
1803 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms30;
1805 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms40;
1807 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms50;
1809 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms60;
1811 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms80;
1813 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms100;
1815 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms200;
1817 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms300;
1819 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms400;
1821 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms500;
1823 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms600;
1825 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms800;
1827 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1000;
1829 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1200;
1831 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1600;
1833 return DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1;
1837 /************************************************************************
1839 * @brief Converts enum value of ondurationTime length to actual value
1843 * Function : convertOnDurationTimerMilliSecondsEnumToValue
1845 * Functionality: As per Spec 38.331,
1846 * Converts enum value of ondurationTime to actual value
1848 * @params[in] e_DRX_ConfigRrc__drx_onDurationTimer__milliSeconds ondurationTime
1849 * @return actual value of onDurationTimer in milliSeconds
1851 * **********************************************************************/
1852 uint16_t convertOnDurationTimerMilliSecondsEnumToValue(e_DRX_ConfigRrc__drx_onDurationTimer__milliSeconds ondurationTime)
1854 switch(ondurationTime)
1856 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1:
1858 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms2:
1860 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms3:
1862 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms4:
1864 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms5:
1866 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms6:
1868 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms8:
1870 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms10:
1872 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms20:
1874 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms30:
1876 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms40:
1878 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms50:
1880 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms60:
1882 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms80:
1884 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms100:
1886 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms200:
1888 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms300:
1890 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms400:
1892 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms500:
1894 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms600:
1896 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms800:
1898 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1000:
1900 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1200:
1902 case DRX_ConfigRrc__drx_onDurationTimer__milliSeconds_ms1600:
1909 /************************************************************************
1911 * @brief Converts actual value of drx RetransmissionTimerUL to enum value
1915 * Function : convertDrxRetransmissionTimerUlValueToEnum
1917 * Functionality: As per Spec 38.331,
1918 * Converts actual value drx RetransmissionTimerUL to enum value
1920 * @params[in] uint16_t retransmissionTimerUL
1921 * @return enum value of drx RetransmissionTimerUL
1923 * **********************************************************************/
1924 e_DRX_ConfigRrc__drx_RetransmissionTimerUL convertDrxRetransmissionTimerUlValueToEnum(uint16_t retransmissionTimerUL)
1926 switch(retransmissionTimerUL)
1929 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl0;
1931 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl1;
1933 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl2;
1935 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl4;
1937 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl6;
1939 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl8;
1941 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl16;
1943 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl24;
1945 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl33;
1947 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl40;
1949 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl64;
1951 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl80;
1953 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl96;
1955 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl112;
1957 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl128;
1959 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl160;
1961 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl320;
1963 return DRX_ConfigRrc__drx_RetransmissionTimerUL_sl4;
1967 /************************************************************************
1969 * @brief Converts enum value of drx RetransmissionTimerUL to actual value
1973 * Function : convertDrxRetransmissionTimerUlEnumToValue
1975 * Functionality: As per Spec 38.331,
1976 * Converts enum value drx RetransmissionTimerUL to actual value
1978 * @params[in] e_DRX_ConfigRrc__drx_RetransmissionTimerUL retransmissionTimerUL
1979 * @return actual value of drx RetransmissionTimerUL
1981 * **********************************************************************/
1982 uint16_t convertDrxRetransmissionTimerUlEnumToValue(e_DRX_ConfigRrc__drx_RetransmissionTimerUL retransmissionTimerUL)
1984 switch(retransmissionTimerUL)
1987 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl0:
1989 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl1:
1991 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl2:
1993 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl4:
1995 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl6:
1997 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl8:
1999 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl16:
2001 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl24:
2003 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl33:
2005 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl40:
2007 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl64:
2009 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl80:
2011 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl96:
2013 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl112:
2015 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl128:
2017 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl160:
2019 case DRX_ConfigRrc__drx_RetransmissionTimerUL_sl320:
2026 /************************************************************************
2028 * @brief Converts actual value of drx RetransmissionTimerDL to enum value
2032 * Function : convertDrxRetransmissionTimerDlValueToEnum
2034 * Functionality: As per Spec 38.331,
2035 * Converts actual value drx RetransmissionTimerDL to enum value
2037 * @params[in] uint16_t retransmissionTimerDL
2038 * @return enum value of drx RetransmissionTimerDL
2040 * **********************************************************************/
2041 e_DRX_ConfigRrc__drx_RetransmissionTimerDL convertDrxRetransmissionTimerDlValueToEnum(uint16_t retransmissionTimerDL)
2043 switch(retransmissionTimerDL)
2046 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl0;
2048 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl1;
2050 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl2;
2052 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl4;
2054 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl6;
2056 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl8;
2058 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl16;
2060 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl24;
2062 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl33;
2064 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl40;
2066 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl64;
2068 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl80;
2070 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl96;
2072 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl112;
2074 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl128;
2076 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl160;
2078 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl320;
2080 return DRX_ConfigRrc__drx_RetransmissionTimerDL_sl4;
2083 /************************************************************************
2085 * @brief Converts enum value of drx RetransmissionTimerDL to actual value
2089 * Function : convertDrxRetransmissionTimerDlEnumToValue
2091 * Functionality: As per Spec 38.331,
2092 * Converts enum value drx RetransmissionTimerDL to actual value
2094 * @params[in] e_DRX_ConfigRrc__drx_RetransmissionTimerDL retransmissionTimerDL
2095 * @return actual value of drx RetransmissionTimerDL
2097 * **********************************************************************/
2098 uint16_t convertDrxRetransmissionTimerDlEnumToValue(e_DRX_ConfigRrc__drx_RetransmissionTimerDL retransmissionTimerDL)
2100 switch(retransmissionTimerDL)
2103 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl0:
2105 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl1:
2107 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl2:
2109 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl4:
2111 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl6:
2113 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl8:
2115 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl16:
2117 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl24:
2119 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl33:
2121 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl40:
2123 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl64:
2125 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl80:
2127 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl96:
2129 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl112:
2131 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl128:
2133 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl160:
2135 case DRX_ConfigRrc__drx_RetransmissionTimerDL_sl320:
2142 /************************************************************************
2144 * @brief Converts actual value of drx inactivityTimer to enum value
2148 * Function : convertDrxInactivityTimerValueToEnum
2150 * Functionality: As per Spec 38.331,
2151 * Converts actual value drx inactivityTimer to enum value
2153 * @params[in] uint16_tinactivityTimer
2154 * @return enum value of drxinactivityTimer
2156 * **********************************************************************/
2157 e_DRX_ConfigRrc__drx_InactivityTimer convertDrxInactivityTimerValueToEnum(uint16_t inactivityTimer)
2159 switch(inactivityTimer)
2162 return DRX_ConfigRrc__drx_InactivityTimer_ms0;
2164 return DRX_ConfigRrc__drx_InactivityTimer_ms1;
2166 return DRX_ConfigRrc__drx_InactivityTimer_ms2;
2168 return DRX_ConfigRrc__drx_InactivityTimer_ms3;
2170 return DRX_ConfigRrc__drx_InactivityTimer_ms4;
2172 return DRX_ConfigRrc__drx_InactivityTimer_ms5;
2174 return DRX_ConfigRrc__drx_InactivityTimer_ms6;
2176 return DRX_ConfigRrc__drx_InactivityTimer_ms8;
2178 return DRX_ConfigRrc__drx_InactivityTimer_ms10;
2180 return DRX_ConfigRrc__drx_InactivityTimer_ms20;
2182 return DRX_ConfigRrc__drx_InactivityTimer_ms30;
2184 return DRX_ConfigRrc__drx_InactivityTimer_ms40;
2186 return DRX_ConfigRrc__drx_InactivityTimer_ms50;
2188 return DRX_ConfigRrc__drx_InactivityTimer_ms60;
2190 return DRX_ConfigRrc__drx_InactivityTimer_ms80;
2192 return DRX_ConfigRrc__drx_InactivityTimer_ms100;
2194 return DRX_ConfigRrc__drx_InactivityTimer_ms200;
2196 return DRX_ConfigRrc__drx_InactivityTimer_ms300;
2198 return DRX_ConfigRrc__drx_InactivityTimer_ms500;
2200 return DRX_ConfigRrc__drx_InactivityTimer_ms750;
2202 return DRX_ConfigRrc__drx_InactivityTimer_ms1280;
2204 return DRX_ConfigRrc__drx_InactivityTimer_ms1920;
2206 return DRX_ConfigRrc__drx_InactivityTimer_ms2560;
2208 return DRX_ConfigRrc__drx_InactivityTimer_ms1;
2211 /************************************************************************
2213 * @brief Converts enum value of drx inactivityTimer to actual value
2217 * Function : convertDrxInactivityTimerEnumToValue
2219 * Functionality: As per Spec 38.331,
2220 * Converts enum value drx inactivityTimer to actual value
2222 * @params[in] e_DRX_ConfigRrc__drx_InactivityTimer inactivityTimer
2223 * @return value of drxinactivityTimer
2225 * **********************************************************************/
2226 uint16_t convertDrxInactivityTimerEnumToValue(e_DRX_ConfigRrc__drx_InactivityTimer inactivityTimer)
2228 switch(inactivityTimer)
2230 case DRX_ConfigRrc__drx_InactivityTimer_ms0:
2232 case DRX_ConfigRrc__drx_InactivityTimer_ms1:
2234 case DRX_ConfigRrc__drx_InactivityTimer_ms2:
2236 case DRX_ConfigRrc__drx_InactivityTimer_ms3:
2238 case DRX_ConfigRrc__drx_InactivityTimer_ms4:
2240 case DRX_ConfigRrc__drx_InactivityTimer_ms5:
2242 case DRX_ConfigRrc__drx_InactivityTimer_ms6:
2244 case DRX_ConfigRrc__drx_InactivityTimer_ms8:
2246 case DRX_ConfigRrc__drx_InactivityTimer_ms10:
2248 case DRX_ConfigRrc__drx_InactivityTimer_ms20:
2250 case DRX_ConfigRrc__drx_InactivityTimer_ms30:
2252 case DRX_ConfigRrc__drx_InactivityTimer_ms40:
2254 case DRX_ConfigRrc__drx_InactivityTimer_ms50:
2256 case DRX_ConfigRrc__drx_InactivityTimer_ms60:
2258 case DRX_ConfigRrc__drx_InactivityTimer_ms80:
2260 case DRX_ConfigRrc__drx_InactivityTimer_ms100:
2262 case DRX_ConfigRrc__drx_InactivityTimer_ms200:
2264 case DRX_ConfigRrc__drx_InactivityTimer_ms300:
2266 case DRX_ConfigRrc__drx_InactivityTimer_ms500:
2268 case DRX_ConfigRrc__drx_InactivityTimer_ms750:
2270 case DRX_ConfigRrc__drx_InactivityTimer_ms1280:
2272 case DRX_ConfigRrc__drx_InactivityTimer_ms1920:
2274 case DRX_ConfigRrc__drx_InactivityTimer_ms2560:
2281 /**********************************************************************
2283 **********************************************************************/