rrc_messages_types.h 20.9 KB
Newer Older
1
2
3
4
5
/*
 * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The OpenAirInterface Software Alliance licenses this file to You under
Cédric Roux's avatar
Cédric Roux committed
6
 * the OAI Public License, Version 1.1  (the "License"); you may not use this file
7
8
9
10
11
12
13
14
15
16
17
18
19
20
 * except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.openairinterface.org/?page_id=698
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *-------------------------------------------------------------------------------
 * For more information about the OpenAirInterface (OAI) Software Alliance:
 *      contact@openairinterface.org
 */
nikaeinn's avatar
nikaeinn committed
21

22
23
24
25
/*
 * rrc_messages_types.h
 *
 *  Created on: Oct 24, 2013
nikaeinn's avatar
nikaeinn committed
26
 *      Author: winckel and Navid Nikaein
27
28
29
30
31
 */

#ifndef RRC_MESSAGES_TYPES_H_
#define RRC_MESSAGES_TYPES_H_

winckel's avatar
RRC:    
winckel committed
32
#include "as_message.h"
winckel's avatar
winckel committed
33
#include "rrc_types.h"
34
#include "s1ap_messages_types.h"
35
#include "f1ap_messages_types.h"
36
#include "LTE_SystemInformationBlockType2.h"
37
38
#include "LTE_SL-OffsetIndicator-r12.h"
#include "LTE_SubframeBitmapSL-r12.h"
39
#include "LTE_DRX-Config.h"
40
41
42
#include "LTE_SL-CP-Len-r12.h"
#include "LTE_SL-PeriodComm-r12.h"
#include "LTE_SL-DiscResourcePool-r12.h"
43

winckel's avatar
RRC:    
winckel committed
44
45
46

//-------------------------------------------------------------------------------------------//
// Messages for RRC logging
47
#if defined(DISABLE_ITTI_XER_PRINT)
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
48
49
50
51
52
53
  #include "LTE_BCCH-DL-SCH-Message.h"
  #include "LTE_DL-CCCH-Message.h"
  #include "LTE_DL-DCCH-Message.h"
  #include "LTE_UE-EUTRA-Capability.h"
  #include "LTE_UL-CCCH-Message.h"
  #include "LTE_UL-DCCH-Message.h"
54

Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
55
56
57
58
59
60
  typedef BCCH_DL_SCH_Message_t   RrcDlBcchMessage;
  typedef DL_CCCH_Message_t       RrcDlCcchMessage;
  typedef DL_DCCH_Message_t       RrcDlDcchMessage;
  typedef UE_EUTRA_Capability_t   RrcUeEutraCapability;
  typedef UL_CCCH_Message_t       RrcUlCcchMessage;
  typedef UL_DCCH_Message_t       RrcUlDcchMessage;
61
#endif
62
63

//-------------------------------------------------------------------------------------------//
winckel's avatar
RRC:    
winckel committed
64
// Defines to access message fields.
winckel's avatar
winckel committed
65
66
#define RRC_STATE_IND(mSGpTR)           (mSGpTR)->ittiMsg.rrc_state_ind

winckel's avatar
winckel committed
67
#define RRC_CONFIGURATION_REQ(mSGpTR)   (mSGpTR)->ittiMsg.rrc_configuration_req
winckel's avatar
winckel committed
68

oai's avatar
oai committed
69
70
#define NBIOTRRC_CONFIGURATION_REQ(mSGpTR)   (mSGpTR)->ittiMsg.nbiotrrc_configuration_req

71
#define NAS_KENB_REFRESH_REQ(mSGpTR)    (mSGpTR)->ittiMsg.nas_kenb_refresh_req
winckel's avatar
winckel committed
72
73
74
#define NAS_CELL_SELECTION_REQ(mSGpTR)  (mSGpTR)->ittiMsg.nas_cell_selection_req
#define NAS_CONN_ESTABLI_REQ(mSGpTR)    (mSGpTR)->ittiMsg.nas_conn_establi_req
#define NAS_UPLINK_DATA_REQ(mSGpTR)     (mSGpTR)->ittiMsg.nas_ul_data_req
75

winckel's avatar
winckel committed
76
77
78
79
80
81
82
83
84
#define NAS_RAB_ESTABLI_RSP(mSGpTR)     (mSGpTR)->ittiMsg.nas_rab_est_rsp

#define NAS_CELL_SELECTION_CNF(mSGpTR)  (mSGpTR)->ittiMsg.nas_cell_selection_cnf
#define NAS_CELL_SELECTION_IND(mSGpTR)  (mSGpTR)->ittiMsg.nas_cell_selection_ind
#define NAS_PAGING_IND(mSGpTR)          (mSGpTR)->ittiMsg.nas_paging_ind
#define NAS_CONN_ESTABLI_CNF(mSGpTR)    (mSGpTR)->ittiMsg.nas_conn_establi_cnf
#define NAS_CONN_RELEASE_IND(mSGpTR)    (mSGpTR)->ittiMsg.nas_conn_release_ind
#define NAS_UPLINK_DATA_CNF(mSGpTR)     (mSGpTR)->ittiMsg.nas_ul_data_cnf
#define NAS_DOWNLINK_DATA_IND(mSGpTR)   (mSGpTR)->ittiMsg.nas_dl_data_ind
85

86
87
#define RRC_SUBFRAME_PROCESS(mSGpTR)    (mSGpTR)->ittiMsg.rrc_subframe_process

88
//-------------------------------------------------------------------------------------------//
89
90
91
typedef struct RrcStateInd_s {
  Rrc_State_t     state;
  Rrc_Sub_State_t sub_state;
winckel's avatar
winckel committed
92
93
} RrcStateInd;

94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
typedef struct RadioResourceConfig_s {
  long                    prach_root;
  long                    prach_config_index;
  BOOLEAN_t               prach_high_speed;
  long                    prach_zero_correlation;
  long                    prach_freq_offset;
  long                    pucch_delta_shift;
  long                    pucch_nRB_CQI;
  long                    pucch_nCS_AN;
  long                    pucch_n1_AN;
  long                    pdsch_referenceSignalPower;
  long                    pdsch_p_b;
  long                    pusch_n_SB;
  long                    pusch_hoppingMode;
  long                    pusch_hoppingOffset;
  BOOLEAN_t               pusch_enable64QAM;
  BOOLEAN_t               pusch_groupHoppingEnabled;
  long                    pusch_groupAssignment;
  BOOLEAN_t               pusch_sequenceHoppingEnabled;
  long                    pusch_nDMRS1;
  long                    phich_duration;
  long                    phich_resource;
  BOOLEAN_t               srs_enable;
  long                    srs_BandwidthConfig;
  long                    srs_SubframeConfig;
  BOOLEAN_t               srs_ackNackST;
  BOOLEAN_t               srs_MaxUpPts;
  long                    pusch_p0_Nominal;
  long                    pusch_alpha;
  long                    pucch_p0_Nominal;
  long                    msg3_delta_Preamble;
  long                    ul_CyclicPrefixLength;
126
127
128
129
130
  e_LTE_DeltaFList_PUCCH__deltaF_PUCCH_Format1                    pucch_deltaF_Format1;
  e_LTE_DeltaFList_PUCCH__deltaF_PUCCH_Format1b                   pucch_deltaF_Format1b;
  e_LTE_DeltaFList_PUCCH__deltaF_PUCCH_Format2                    pucch_deltaF_Format2;
  e_LTE_DeltaFList_PUCCH__deltaF_PUCCH_Format2a                   pucch_deltaF_Format2a;
  e_LTE_DeltaFList_PUCCH__deltaF_PUCCH_Format2b                   pucch_deltaF_Format2b;
131
132
133
134
  long                    rach_numberOfRA_Preambles;
  BOOLEAN_t               rach_preamblesGroupAConfig;
  long                    rach_sizeOfRA_PreamblesGroupA;
  long                    rach_messageSizeGroupA;
135
  e_LTE_RACH_ConfigCommon__preambleInfo__preamblesGroupAConfig__messagePowerOffsetGroupB                    rach_messagePowerOffsetGroupB;
136
137
138
139
140
141
142
143
144
  long                    rach_powerRampingStep;
  long                    rach_preambleInitialReceivedTargetPower;
  long                    rach_preambleTransMax;
  long                    rach_raResponseWindowSize;
  long                    rach_macContentionResolutionTimer;
  long                    rach_maxHARQ_Msg3Tx;
  long                    bcch_modificationPeriodCoeff;
  long                    pcch_defaultPagingCycle;
  long                    pcch_nB;
145
146
147
148
149
150
151
152
  LTE_DRX_Config_PR                                   drx_Config_present;
  long                                                drx_onDurationTimer;
  long                                                drx_InactivityTimer;
  long                                                drx_RetransmissionTimer;
  LTE_DRX_Config__setup__longDRX_CycleStartOffset_PR  drx_longDrx_CycleStartOffset_present;
  long                                                drx_longDrx_CycleStartOffset;
  long                                                drx_shortDrx_Cycle;
  long                                                drx_shortDrx_ShortCycleTimer;
153
154
155
156
157
158
159
  long                    ue_TimersAndConstants_t300;
  long                    ue_TimersAndConstants_t301;
  long                    ue_TimersAndConstants_t310;
  long                    ue_TimersAndConstants_t311;
  long                    ue_TimersAndConstants_n310;
  long                    ue_TimersAndConstants_n311;
  long                    ue_TransmissionMode;
160
  long                    ue_multiple_max;
nepes's avatar
nepes committed
161
#if (LTE_RRC_VERSION >= MAKE_VERSION(14, 0, 0))
162
163
164
165
166
167
168
  //SIB2 BR Options
  long*			  preambleTransMax_CE_r13;
  BOOLEAN_t		  prach_ConfigCommon_v1310;
  BOOLEAN_t*	          mpdcch_startSF_CSS_RA_r13;
  long			  mpdcch_startSF_CSS_RA_r13_val;
  long*			  prach_HoppingOffset_r13;
#endif
169
  BOOLEAN_t		  mbms_dedicated_serving_cell;
170
171
} RadioResourceConfig;

winckel's avatar
winckel committed
172
173
// eNB: ENB_APP -> RRC messages
typedef struct RrcConfigurationReq_s {
174
  uint32_t                cell_identity;
winckel's avatar
winckel committed
175

176
  uint16_t                tac;
winckel's avatar
winckel committed
177
178


179
180
181
182
  uint16_t            mcc[PLMN_LIST_MAX_SIZE];
  uint16_t            mnc[PLMN_LIST_MAX_SIZE];
  uint8_t             mnc_digit_length[PLMN_LIST_MAX_SIZE];
  uint8_t             num_plmn;
183

184
185
186
  int                 enable_measurement_reports;
  int                 enable_x2;

187
  uint32_t            rrc_inactivity_timer_thres; // for testing, maybe change later
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
188

189
  paging_drx_t            default_drx;
knopp's avatar
   
knopp committed
190
191
192
193
194
  int16_t                 nb_cc;
  lte_frame_type_t        frame_type[MAX_NUM_CCs];
  uint8_t                 tdd_config[MAX_NUM_CCs];
  uint8_t                 tdd_config_s[MAX_NUM_CCs];
  lte_prefix_type_t       prefix_type[MAX_NUM_CCs];
195
  uint8_t                 pbch_repetition[MAX_NUM_CCs];
knopp's avatar
   
knopp committed
196
197
198
199
200
  int16_t                 eutra_band[MAX_NUM_CCs];
  uint32_t                downlink_frequency[MAX_NUM_CCs];
  int32_t                 uplink_frequency_offset[MAX_NUM_CCs];
  int16_t                 Nid_cell[MAX_NUM_CCs];// for testing, change later
  int16_t                 N_RB_DL[MAX_NUM_CCs];// for testing, change later
201
  int                     nb_antenna_ports[MAX_NUM_CCs];
202
  int                     eMBMS_configured;
203
204
  int                     eMTC_configured;
  int                     SL_configured;
205

206
  RadioResourceConfig     radioresourceconfig[MAX_NUM_CCs];
kogo's avatar
kogo committed
207
  RadioResourceConfig     radioresourceconfig_BR[MAX_NUM_CCs];
208

209
#if (LTE_RRC_VERSION >= MAKE_VERSION(13, 0, 0))
210
  //MIB
211
  long	 		  schedulingInfoSIB1_BR_r13[MAX_NUM_CCs];
212
  //SIB1 BR options
213
214
215
216
217
218
219
220
221
  uint16_t*		  hyperSFN_r13                           [MAX_NUM_CCs];
  long*			  eDRX_Allowed_r13                       [MAX_NUM_CCs];
  BOOLEAN_t		  cellSelectionInfoCE_r13                [MAX_NUM_CCs];
  long			  q_RxLevMinCE_r13                       [MAX_NUM_CCs];
  long*			  q_QualMinRSRQ_CE_r13                   [MAX_NUM_CCs];
  BOOLEAN_t		  bandwidthReducedAccessRelatedInfo_r13  [MAX_NUM_CCs];
  long            si_Narrowband_r13         [MAX_NUM_CCs][32];
  long            si_TBS_r13                [MAX_NUM_CCs][32];
  int             scheduling_info_br_size   [MAX_NUM_CCs];
Mohamed Said's avatar
Mohamed Said committed
222
223
  long			  si_WindowLength_BR_r13                       [MAX_NUM_CCs];
  long			  si_RepetitionPattern_r13                     [MAX_NUM_CCs];
224
225
226
  BOOLEAN_t		 * fdd_DownlinkOrTddSubframeBitmapBR_r13       [MAX_NUM_CCs];
  uint64_t		  fdd_DownlinkOrTddSubframeBitmapBR_val_r13    [MAX_NUM_CCs];
  uint16_t		  *fdd_UplinkSubframeBitmapBR_r13              [MAX_NUM_CCs];
Mohamed Said's avatar
Mohamed Said committed
227
228
229
  long			  startSymbolBR_r13                            [MAX_NUM_CCs];
  long			  si_HoppingConfigCommon_r13                   [MAX_NUM_CCs];
  long*			  si_ValidityTime_r13                          [MAX_NUM_CCs];
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
  long            systemInfoValueTagSi_r13      [MAX_NUM_CCs][10];
  int             system_info_value_tag_SI_size [MAX_NUM_CCs];
  BOOLEAN_t		  freqHoppingParametersDL_r13                   [MAX_NUM_CCs];
  long*			  mpdcch_pdsch_HoppingNB_r13                    [MAX_NUM_CCs];
  BOOLEAN_t		  interval_DLHoppingConfigCommonModeA_r13       [MAX_NUM_CCs];
  long			  interval_DLHoppingConfigCommonModeA_r13_val   [MAX_NUM_CCs];
  BOOLEAN_t		  interval_DLHoppingConfigCommonModeB_r13       [MAX_NUM_CCs];
  long			  interval_DLHoppingConfigCommonModeB_r13_val   [MAX_NUM_CCs];
  long*			  mpdcch_pdsch_HoppingOffset_r13                [MAX_NUM_CCs];
  long firstPreamble_r13                 [MAX_NUM_CCs][4];
  long lastPreamble_r13                  [MAX_NUM_CCs][4];
  long ra_ResponseWindowSize_r13         [MAX_NUM_CCs][4];
  long mac_ContentionResolutionTimer_r13 [MAX_NUM_CCs][4];
  long rar_HoppingConfig_r13             [MAX_NUM_CCs][4];
  int  rach_CE_LevelInfoList_r13_size    [MAX_NUM_CCs];
245
//  long pcch_defaultPagingCycle_br;
246
247
248
249
250
251
252
253
254
255
256
  long rsrp_range           [MAX_NUM_CCs][3];
  int rsrp_range_list_size  [MAX_NUM_CCs];
  long prach_config_index                        [MAX_NUM_CCs][4];
  long prach_freq_offset                         [MAX_NUM_CCs][4];
  long *prach_StartingSubframe_r13               [MAX_NUM_CCs][4];
  long *maxNumPreambleAttemptCE_r13              [MAX_NUM_CCs][4];
  long numRepetitionPerPreambleAttempt_r13       [MAX_NUM_CCs][4];
  long mpdcch_NumRepetition_RA_r13               [MAX_NUM_CCs][4];
  long prach_HoppingConfig_r13                   [MAX_NUM_CCs][4];
  int  prach_parameters_list_size                [MAX_NUM_CCs];
  long max_available_narrow_band                 [MAX_NUM_CCs][4][2];
257
  int  max_available_narrow_band_size            [MAX_NUM_CCs][4];
258
259
260
261
262
263
264
265
266
267
268
269
270
  long pucch_info_value       [MAX_NUM_CCs][4];
  int  pucch_info_value_size  [MAX_NUM_CCs];
  bool  pcch_config_v1310               [MAX_NUM_CCs];
  long  paging_narrowbands_r13          [MAX_NUM_CCs];
  long  mpdcch_numrepetition_paging_r13 [MAX_NUM_CCs];
  long  *nb_v1310                        [MAX_NUM_CCs];
  long  *pucch_NumRepetitionCE_Msg4_Level0_r13  [MAX_NUM_CCs];
  long  *pucch_NumRepetitionCE_Msg4_Level1_r13  [MAX_NUM_CCs];
  long  *pucch_NumRepetitionCE_Msg4_Level2_r13  [MAX_NUM_CCs];
  long  *pucch_NumRepetitionCE_Msg4_Level3_r13  [MAX_NUM_CCs];
  bool  sib2_freq_hoppingParameters_r13_exists             [MAX_NUM_CCs];
  long  *sib2_mpdcch_pdsch_hoppingNB_r13                   [MAX_NUM_CCs];
  long  *sib2_interval_DLHoppingConfigCommonModeA_r13      [MAX_NUM_CCs];
271
272
273
  long  sib2_interval_DLHoppingConfigCommonModeA_r13_val  [MAX_NUM_CCs];
  long  *sib2_interval_DLHoppingConfigCommonModeB_r13      [MAX_NUM_CCs];
  long  sib2_interval_DLHoppingConfigCommonModeB_r13_val  [MAX_NUM_CCs];
274
  long  *sib2_interval_ULHoppingConfigCommonModeA_r13      [MAX_NUM_CCs];
275
  long  sib2_interval_ULHoppingConfigCommonModeA_r13_val  [MAX_NUM_CCs];
276
277
278
279
280
281
282
  long  *sib2_interval_ULHoppingConfigCommonModeB_r13      [MAX_NUM_CCs];
  long  sib2_interval_ULHoppingConfigCommonModeB_r13_val  [MAX_NUM_CCs];
  long  *sib2_mpdcch_pdsch_hoppingOffset_r13               [MAX_NUM_CCs];
  long  *pdsch_maxNumRepetitionCEmodeA_r13                 [MAX_NUM_CCs];
  long  *pdsch_maxNumRepetitionCEmodeB_r13                 [MAX_NUM_CCs];
  long  *pusch_maxNumRepetitionCEmodeA_r13                 [MAX_NUM_CCs];
  long  *pusch_maxNumRepetitionCEmodeB_r13                 [MAX_NUM_CCs];
283
  long  *pusch_repetitionLevelCEmodeA_r13				   [MAX_NUM_CCs];
284
  long  *pusch_HoppingOffset_v1310                         [MAX_NUM_CCs];
285
#endif
286
  //SIB18
287
288
289
  e_LTE_SL_CP_Len_r12            rxPool_sc_CP_Len[MAX_NUM_CCs];
  e_LTE_SL_PeriodComm_r12        rxPool_sc_Period[MAX_NUM_CCs];
  e_LTE_SL_CP_Len_r12            rxPool_data_CP_Len[MAX_NUM_CCs];
290
291
292
  long                           rxPool_ResourceConfig_prb_Num[MAX_NUM_CCs];
  long                           rxPool_ResourceConfig_prb_Start[MAX_NUM_CCs];
  long                           rxPool_ResourceConfig_prb_End[MAX_NUM_CCs];
293
  LTE_SL_OffsetIndicator_r12_PR  rxPool_ResourceConfig_offsetIndicator_present[MAX_NUM_CCs];
294
  long                           rxPool_ResourceConfig_offsetIndicator_choice[MAX_NUM_CCs];
295
  LTE_SubframeBitmapSL_r12_PR    rxPool_ResourceConfig_subframeBitmap_present[MAX_NUM_CCs];
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
296
  char                          *rxPool_ResourceConfig_subframeBitmap_choice_bs_buf[MAX_NUM_CCs];
297
298
299
300
301
  long                           rxPool_ResourceConfig_subframeBitmap_choice_bs_size[MAX_NUM_CCs];
  long                           rxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused[MAX_NUM_CCs];

  //SIB19
  //for discRxPool
302
303
  LTE_SL_CP_Len_r12_t            discRxPool_cp_Len[MAX_NUM_CCs];
  e_LTE_SL_DiscResourcePool_r12__discPeriod_r12               discRxPool_discPeriod[MAX_NUM_CCs];
304
305
306
307
308
  long                           discRxPool_numRetx[MAX_NUM_CCs];
  long                           discRxPool_numRepetition[MAX_NUM_CCs];
  long                           discRxPool_ResourceConfig_prb_Num[MAX_NUM_CCs];
  long                           discRxPool_ResourceConfig_prb_Start[MAX_NUM_CCs];
  long                           discRxPool_ResourceConfig_prb_End[MAX_NUM_CCs];
309
  LTE_SL_OffsetIndicator_r12_PR  discRxPool_ResourceConfig_offsetIndicator_present[MAX_NUM_CCs];
310
  long                           discRxPool_ResourceConfig_offsetIndicator_choice[MAX_NUM_CCs];
311
  LTE_SubframeBitmapSL_r12_PR    discRxPool_ResourceConfig_subframeBitmap_present[MAX_NUM_CCs];
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
312
  char                          *discRxPool_ResourceConfig_subframeBitmap_choice_bs_buf[MAX_NUM_CCs];
313
314
315
  long                           discRxPool_ResourceConfig_subframeBitmap_choice_bs_size[MAX_NUM_CCs];
  long                           discRxPool_ResourceConfig_subframeBitmap_choice_bs_bits_unused[MAX_NUM_CCs];
  //for discRxPoolPS
316
317
  LTE_SL_CP_Len_r12_t            discRxPoolPS_cp_Len[MAX_NUM_CCs];
  e_LTE_SL_DiscResourcePool_r12__discPeriod_r12                   discRxPoolPS_discPeriod[MAX_NUM_CCs];
318
319
320
321
322
  long                           discRxPoolPS_numRetx[MAX_NUM_CCs];
  long                           discRxPoolPS_numRepetition[MAX_NUM_CCs];
  long                           discRxPoolPS_ResourceConfig_prb_Num[MAX_NUM_CCs];
  long                           discRxPoolPS_ResourceConfig_prb_Start[MAX_NUM_CCs];
  long                           discRxPoolPS_ResourceConfig_prb_End[MAX_NUM_CCs];
323
  LTE_SL_OffsetIndicator_r12_PR  discRxPoolPS_ResourceConfig_offsetIndicator_present[MAX_NUM_CCs];
324
  long                           discRxPoolPS_ResourceConfig_offsetIndicator_choice[MAX_NUM_CCs];
325
  LTE_SubframeBitmapSL_r12_PR    discRxPoolPS_ResourceConfig_subframeBitmap_present[MAX_NUM_CCs];
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
326
  char                          *discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_buf[MAX_NUM_CCs];
327
328
  long                           discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_size[MAX_NUM_CCs];
  long                           discRxPoolPS_ResourceConfig_subframeBitmap_choice_bs_bits_unused[MAX_NUM_CCs];
winckel's avatar
winckel committed
329
330
} RrcConfigurationReq;

oai's avatar
oai committed
331
#define MAX_NUM_NBIOT_CELEVELS    3
332

oai's avatar
oai committed
333
334
335
typedef struct NbIoTRrcConfigurationReq_s {
  uint32_t            cell_identity;
  uint16_t            tac;
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
336
337
338
339
  uint16_t        mcc;
  uint16_t        mnc;
  uint8_t       mnc_digit_length;
  lte_frame_type_t    frame_type;
oai's avatar
oai committed
340
341
342
  uint8_t                 tdd_config;
  uint8_t                 tdd_config_s;
  lte_prefix_type_t       prefix_type;
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
343
  lte_prefix_type_t   prefix_type_UL;
oai's avatar
oai committed
344
345
346
347
348
349
  int16_t                 eutra_band;
  uint32_t                downlink_frequency;
  int32_t                 uplink_frequency_offset;
  int16_t                 Nid_cell;// for testing, change later
  int16_t                 N_RB_DL;// for testing, change later
  //RACH
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
350
351
352
353
354
  long            rach_raResponseWindowSize_NB;
  long            rach_macContentionResolutionTimer_NB;
  long            rach_powerRampingStep_NB;
  long            rach_preambleInitialReceivedTargetPower_NB;
  long            rach_preambleTransMax_CE_NB;
oai's avatar
oai committed
355
  //BCCH
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
356
  long            bcch_modificationPeriodCoeff_NB;
oai's avatar
oai committed
357
  //PCCH
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
358
359
360
  long            pcch_defaultPagingCycle_NB;
  long            pcch_nB_NB;
  long            pcch_npdcch_NumRepetitionPaging_NB;
oai's avatar
oai committed
361
  //NPRACH
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
362
363
364
365
366
367
368
369
370
371
372
373
  long            nprach_CP_Length;
  long            nprach_rsrp_range;
  long            nprach_Periodicity[MAX_NUM_NBIOT_CELEVELS];
  long            nprach_StartTime[MAX_NUM_NBIOT_CELEVELS];
  long            nprach_SubcarrierOffset[MAX_NUM_NBIOT_CELEVELS];
  long            nprach_NumSubcarriers[MAX_NUM_NBIOT_CELEVELS];
  long            numRepetitionsPerPreambleAttempt_NB[MAX_NUM_NBIOT_CELEVELS];
  long            nprach_SubcarrierMSG3_RangeStart;
  long            maxNumPreambleAttemptCE_NB;
  long            npdcch_NumRepetitions_RA[MAX_NUM_NBIOT_CELEVELS];
  long            npdcch_StartSF_CSS_RA[MAX_NUM_NBIOT_CELEVELS];
  long            npdcch_Offset_RA[MAX_NUM_NBIOT_CELEVELS];
oai's avatar
oai committed
374
  //NPDSCH
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
375
  long            npdsch_nrs_Power;
oai's avatar
oai committed
376
  //NPUSCH
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
377
378
379
380
381
382
  long            npusch_ack_nack_numRepetitions_NB;
  long            npusch_srs_SubframeConfig_NB;
  long            npusch_threeTone_CyclicShift_r13;
  long            npusch_sixTone_CyclicShift_r13;
  BOOLEAN_t         npusch_groupHoppingEnabled;
  long            npusch_groupAssignmentNPUSCH_r13;
oai's avatar
oai committed
383
384

  //DL_GapConfig
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
385
386
387
  long            dl_GapThreshold_NB;
  long            dl_GapPeriodicity_NB;
  long            dl_GapDurationCoeff_NB;
oai's avatar
oai committed
388
  //Uplink power control Common
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
389
390
391
  long            npusch_p0_NominalNPUSCH;
  long            npusch_alpha;
  long            deltaPreambleMsg3;
oai's avatar
oai committed
392
  //UE timers and constants
Louis Adrien Dufrene's avatar
Louis Adrien Dufrene committed
393
394
395
396
397
398
  long            ue_TimersAndConstants_t300_NB;
  long            ue_TimersAndConstants_t301_NB;
  long            ue_TimersAndConstants_t310_NB;
  long            ue_TimersAndConstants_t311_NB;
  long            ue_TimersAndConstants_n310_NB;
  long            ue_TimersAndConstants_n311_NB;
oai's avatar
oai committed
399
400
} NbIoTRrcConfigurationReq;

winckel's avatar
winckel committed
401

winckel's avatar
winckel committed
402
// UE: NAS -> RRC messages
403
typedef kenb_refresh_req_t      NasKenbRefreshReq;
winckel's avatar
winckel committed
404
405
406
407
typedef cell_info_req_t         NasCellSelectionReq;
typedef nas_establish_req_t     NasConnEstabliReq;
typedef ul_info_transfer_req_t  NasUlDataReq;

408
409
typedef rab_establish_rsp_t     NasRabEstRsp;

winckel's avatar
winckel committed
410
411
412
413
414
415
416
417
// UE: RRC -> NAS messages
typedef cell_info_cnf_t         NasCellSelectionCnf;
typedef cell_info_ind_t         NasCellSelectionInd;
typedef paging_ind_t            NasPagingInd;
typedef nas_establish_cnf_t     NasConnEstabCnf;
typedef nas_release_ind_t       NasConnReleaseInd;
typedef ul_info_transfer_cnf_t  NasUlDataCnf;
typedef dl_info_transfer_ind_t  NasDlDataInd;
418

419
420
421
422
423
424
// eNB: realtime -> RRC messages
typedef struct rrc_subframe_process_s {
  protocol_ctxt_t ctxt;
  int             CC_id;
} RrcSubframeProcess;

425
#endif /* RRC_MESSAGES_TYPES_H_ */