Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ZhouShuya
OpenXG-RAN
Commits
cc698b52
Commit
cc698b52
authored
Aug 10, 2018
by
AlanLi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MIB/SIBs
parent
cf44f391
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
242 additions
and
270 deletions
+242
-270
openair1/SCHED/IF_Module_L1_primitives_NB_IoT.c
openair1/SCHED/IF_Module_L1_primitives_NB_IoT.c
+65
-31
openair1/SCHED/phy_procedures_lte_eNb_NB_IoT.c
openair1/SCHED/phy_procedures_lte_eNb_NB_IoT.c
+7
-4
openair2/LAYER2/MAC/eNB_scheduler_bch_NB_IoT.c
openair2/LAYER2/MAC/eNB_scheduler_bch_NB_IoT.c
+10
-25
openair2/LAYER2/MAC/output_handler_NB_IoT.c
openair2/LAYER2/MAC/output_handler_NB_IoT.c
+134
-111
openair2/PHY_INTERFACE/IF_Module_L2_primitives_NB_IoT.c
openair2/PHY_INTERFACE/IF_Module_L2_primitives_NB_IoT.c
+26
-99
No files found.
openair1/SCHED/IF_Module_L1_primitives_NB_IoT.c
View file @
cc698b52
This diff is collapsed.
Click to expand it.
openair1/SCHED/phy_procedures_lte_eNb_NB_IoT.c
View file @
cc698b52
...
...
@@ -289,10 +289,13 @@ void common_signal_procedures_NB_IoT(PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
RB_IoT_ID
);
}
uint8_t
*
npbch_pdu
=
get_NB_IoT_MIB
();
uint8_t
*
sib1_pdu
=
get_NB_IoT_SIB1
();
uint8_t
*
sib23_pdu
=
get_NB_IoT_SIB23
();
//uint8_t *npbch_pdu = get_NB_IoT_MIB();
uint8_t
*
npbch_pdu
=
broadcast_str
->
pdu
;
//uint8_t *sib1_pdu = get_NB_IoT_SIB1();
uint8_t
*
sib1_pdu
=
sib1
->
pdu
;
//uint8_t *sib23_pdu = get_NB_IoT_SIB23();
uint8_t
*
sib23_pdu
=
sib23
->
pdu
;
if
(
subframe
==
0
)
{
...
...
openair2/LAYER2/MAC/eNB_scheduler_bch_NB_IoT.c
View file @
cc698b52
/*
* 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
* the OAI Public License, Version 1.0 (the "License"); you may not use this file
* 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
*/
/*! \file eNB_scheduler_bch_NB_IoT.c
* \brief schedule functions for SIBs transmission in NB-IoT
* \author NTUST BMW Lab./
Calvin HSU
* \date 2017
- 2018
* \email:
kai-hsiang.hsu@eurecom.fr
* \author NTUST BMW Lab./
* \date 2017
* \email:
* \version 1.0
*
*/
...
...
@@ -30,7 +11,7 @@
#include "defs_NB_IoT.h"
#include "proto_NB_IoT.h"
#include "extern_NB_IoT.h"
#include "openair2/RRC/LITE/proto_NB_IoT.h"
char
str
[
6
][
7
]
=
{
"SIBs_1"
,
"SIBs_2"
,
"SIBs_3"
,
"SIBs_4"
,
"SIBs_5"
,
"SIBs_6"
};
...
...
@@ -46,6 +27,8 @@ void schedule_sibs(eNB_MAC_INST_NB_IoT *mac_inst, uint32_t sibs_order, int start
schedule_result_t
*
new_node
;
DCIFormatN1_t
*
sibs_dci
;
uint32_t
j
,
i
,
k
;
uint8_t
SIB23_size
=
0
;
uint8_t
*
SIB23_pdu
=
get_NB_IoT_SIB23
();
int
residual_subframe
,
num_subframe
,
last_subframe
;
num_subframe
=
mac_inst
->
rrc_config
.
sibs_NB_IoT_sched
[
sibs_order
].
si_tb
;
...
...
@@ -96,9 +79,11 @@ LOG_D(MAC,"for1 k=%d j=%d i=%d rep=%d\n", k, j, i, si_repetition_pattern[mac_ins
if
((
available_resource_DL_t
*
)
0
!=
pt
[
k
]){
new_node
=
(
schedule_result_t
*
)
malloc
(
sizeof
(
schedule_result_t
));
// fill new node
SIB23_size
=
get_NB_IoT_SIB23_size
();
new_node
->
output_subframe
=
first_subframe
[
k
];
new_node
->
end_subframe
=
(
j
==
i
)
?
last_subframe
:
j
+
9
;
new_node
->
sdu_length
=
0
;
new_node
->
sdu_length
=
SIB23_size
;
new_node
->
DLSCH_pdu
=
SIB23_pdu
;
new_node
->
direction
=
DL
;
new_node
->
DCI_release
=
(
j
==
i
);
new_node
->
channel
=
NPDSCH
;
...
...
openair2/LAYER2/MAC/output_handler_NB_IoT.c
View file @
cc698b52
This diff is collapsed.
Click to expand it.
openair2/PHY_INTERFACE/IF_Module_L2_primitives_NB_IoT.c
View file @
cc698b52
...
...
@@ -6,26 +6,27 @@
// Sched_INFO as a input for the scheduler
void
UL_indication_NB_IoT
(
UL_IND_NB_IoT_t
*
UL_INFO
)
{
//
int i=0;
int
i
=
0
;
uint32_t
abs_subframe
;
Sched_Rsp_NB_IoT_t
*
SCHED_info
=
&
mac_inst
->
Sched_INFO
;;
//UE_TEMPLATE_NB_IoT *UE_info;
/* Disable uplink RX function for now
//If there is a preamble, do the initiate RA procedure
if(UL_INFO->
nrach_ind
.number_of_initial_scs_detected>0)
if(UL_INFO->
NRACH
.number_of_initial_scs_detected>0)
{
for(i=0;i<UL_INFO->
nrach_ind
.number_of_initial_scs_detected;i++)
for(i=0;i<UL_INFO->
NRACH
.number_of_initial_scs_detected;i++)
{
// initiate_ra here, some useful inforamtion :
//(UL_INFO->
nrach_ind
.nrach_pdu_list+i)->nrach_indication_rel13.initial_sc
//(UL_INFO->
nrach_ind
.nrach_pdu_list+i)->nrach_indication_rel13.timing_advance
//(UL_INFO->
NRACH
.nrach_pdu_list+i)->nrach_indication_rel13.initial_sc
//(UL_INFO->
NRACH
.nrach_pdu_list+i)->nrach_indication_rel13.timing_advance
init_RA_NB_IoT(mac_inst,
(UL_INFO->
nrach_ind
.nrach_pdu_list+i)->nrach_indication_rel13.initial_sc,
(UL_INFO->
nrach_ind
.nrach_pdu_list+i)->nrach_indication_rel13.nrach_ce_level,
(UL_INFO->
NRACH
.nrach_pdu_list+i)->nrach_indication_rel13.initial_sc,
(UL_INFO->
NRACH
.nrach_pdu_list+i)->nrach_indication_rel13.nrach_ce_level,
UL_INFO->frame,
//timing_offset = Timing_advance * 16
(UL_INFO->
nrach_ind
.nrach_pdu_list+i)->nrach_indication_rel13.timing_advance*16
(UL_INFO->
NRACH
.nrach_pdu_list+i)->nrach_indication_rel13.timing_advance*16
);
...
...
@@ -68,99 +69,25 @@ void UL_indication_NB_IoT(UL_IND_NB_IoT_t *UL_INFO)
}
*/
abs_subframe
=
UL_INFO
->
frame
*
10
+
UL_INFO
->
subframe
;
//LOG_I(MAC,"IF L2 frame: %d ,subframe: %d \n",UL_INFO->frame,UL_INFO->subframe);
abs_subframe
=
UL_INFO
->
frame
*
10
+
UL_INFO
->
subframe
+
4
;
//LOG_I(MAC,"Enter scheduler in subframe %d\n",abs_subframe);
//scheduler here
//Schedule subframe should be next four subframe, means that UL_INFO->frame*10+UL_INFO->subframe + 4
eNB_dlsch_ulsch_scheduler_NB_IoT
(
mac_inst
,
abs_subframe
);
}
///////////////////////////////////////////////////////////////////////////////
////////////////////////////// backup ////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
// Sched_INFO as a input for the scheduler
/// void UL_indication_NB_IoT(UL_IND_NB_IoT_t *UL_INFO)
/// {
// int i=0;
/// uint32_t abs_subframe;
//UE_TEMPLATE_NB_IoT *UE_info;
/* Disable uplink RX function for now
//If there is a preamble, do the initiate RA procedure
if(UL_INFO->nrach_ind.number_of_initial_scs_detected>0)
{
for(i=0;i<UL_INFO->nrach_ind.number_of_initial_scs_detected;i++)
{
// initiate_ra here, some useful inforamtion :
//(UL_INFO->nrach_ind.nrach_pdu_list+i)->nrach_indication_rel13.initial_sc
//(UL_INFO->nrach_ind.nrach_pdu_list+i)->nrach_indication_rel13.timing_advance
init_RA_NB_IoT(mac_inst,
(UL_INFO->nrach_ind.nrach_pdu_list+i)->nrach_indication_rel13.initial_sc,
(UL_INFO->nrach_ind.nrach_pdu_list+i)->nrach_indication_rel13.nrach_ce_level,
UL_INFO->frame,
//timing_offset = Timing_advance * 16
(UL_INFO->nrach_ind.nrach_pdu_list+i)->nrach_indication_rel13.timing_advance*16
);
}
}
// crc indication if there is error for this round UL transmission
if(UL_INFO->crc_ind.number_of_crcs>0)
{
for(i=0;i<UL_INFO->crc_ind.number_of_crcs;i++)
{
if((UL_INFO->crc_ind.crc_pdu_list+i)->crc_indication_rel8.crc_flag == 0)
{
//unsuccessfully received this UE PDU
//UE_info = get_ue_from_rnti(mac_inst,((UL_INFO->crc_ind.crc_pdu_list)+i)->rx_ue_information.rnti);
//UE_info->HARQ_round++;
}
}
}
//If there is a Uplink SDU which needs to send to MAC
if(UL_INFO->RX_NPUSCH.number_of_pdus>0)
{
for(i=0;i<UL_INFO->RX_NPUSCH.number_of_pdus;i++)
{
//For MSG3, Normal Uplink Data, NAK
rx_sdu_NB_IoT(UL_INFO->module_id,
UL_INFO->CC_id,
UL_INFO->frame,
UL_INFO->subframe,
(UL_INFO->RX_NPUSCH.rx_pdu_list+i)->rx_ue_information.rnti,
(UL_INFO->RX_NPUSCH.rx_pdu_list+i)->data,
(UL_INFO->RX_NPUSCH.rx_pdu_list+i)->rx_indication_rel8.length
);
}
}
*/
/// abs_subframe = UL_INFO->frame*10+UL_INFO->subframe;
//LOG_I(MAC,"Enter scheduler in subframe %d\n",abs_subframe);
//scheduler here
//Schedule subframe should be next four subframe, means that UL_INFO->frame*10+UL_INFO->subframe + 4
/// eNB_dlsch_ulsch_scheduler_NB_IoT(mac_inst,abs_subframe);
/// }
///////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////
\ No newline at end of file
mac_inst
->
if_inst_NB_IoT
->
schedule_response
(
&
mac_inst
->
Sched_INFO
);
/*
free(SCHED_info->TX_req->tx_request_body.tx_pdu_list);
free(SCHED_info->HI_DCI0_req->hi_dci0_request_body.hi_dci0_pdu_list);
free(SCHED_info->DL_req->dl_config_request_body.dl_config_pdu_list);
free(SCHED_info->UL_req->ul_config_request_body.ul_config_pdu_list);
free(SCHED_info->TX_req);
free(SCHED_info->HI_DCI0_req);
free(SCHED_info->DL_req);
free(SCHED_info->UL_req);
*/
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment