Commit bdc38e8e authored by Michele Paffetti's avatar Michele Paffetti

Adding preliminary .config file for nb-iot (to be completed), adding EARFCN...

Adding preliminary .config file for nb-iot (to be completed), adding EARFCN calculation for configuration with corresponding table for UE cat NB1/NB2
parent 8cd9b164
......@@ -45,8 +45,7 @@ void NB_phy_config_mib_eNB(
int Ncp,
int Ncp_UL,
int p_eNB,
uint32_t dl_CarrierFreq,
uint32_t ul_CarrierFreq,
uint16_t EARFCN,
uint16_t prb_index, // NB_IoT_RB_ID,
uint16_t operating_mode,
uint16_t control_region_size,
......
......@@ -52,50 +52,33 @@ void NB_phy_config_mib_eNB(
int Ncp,
int Ncp_UL,
int p_eNB,
uint32_t dl_CarrierFreq,
uint32_t ul_CarrierFreq,
uint16_t EARFCN,
uint16_t prb_index, // NB_IoT_RB_ID,
uint16_t operating_mode,
uint16_t control_region_size,
uint16_t eutra_NumCRS_ports)
{
/*Not sure if phy parameters should be initial here or not (RAYMOND version)*/
/*the phy_config_mib_eNB as the entry point to allocate the context for L1. The RC contains the context for L1,L2. If RC.eNB is NULL, it hasn't been allocated earlier so we allocate it there.*/
/*if (RC.eNB == NULL) {
RC.eNB = (PHY_VARS_eNB ***)malloc((1+NUMBER_OF_eNB_MAX)*sizeof(PHY_VARS_eNB***));
LOG_I(PHY,"RC.eNB = %p\n",RC.eNB);
memset(RC.eNB,0,(1+NUMBER_OF_eNB_MAX)*sizeof(PHY_VARS_eNB***));
}
if (RC.eNB[Mod_id] == NULL) {
RC.eNB[Mod_id] = (PHY_VARS_eNB **)malloc((1+MAX_NUM_CCs)*sizeof(PHY_VARS_eNB**));
LOG_I(PHY,"RC.eNB[%d] = %p\n",Mod_id,RC.eNB[Mod_id]);
memset(RC.eNB[Mod_id],0,(1+MAX_NUM_CCs)*sizeof(PHY_VARS_eNB***));
}
if (RC.eNB[Mod_id][CC_id] == NULL) {
RC.eNB[Mod_id][CC_id] = (PHY_VARS_eNB *)malloc(sizeof(PHY_VARS_eNB));
LOG_I(PHY,"RC.eNB[%d][%d] = %p\n",Mod_id,CC_id,RC.eNB[Mod_id][CC_id]);
RC.eNB[Mod_id][CC_id]->Mod_id = Mod_id;
RC.eNB[Mod_id][CC_id]->CC_id = CC_id;
}
RC.eNB[Mod_id][CC_id]->mac_enabled = 1;
fp = &RC.eNB[Mod_id][CC_id]->frame_parms; */
AssertFatal(PHY_vars_eNB_g != NULL, "PHY_vars_eNB_g instance pointer doesn't exist\n");
AssertFatal(PHY_vars_eNB_g[Mod_id] != NULL, "PHY_vars_eNB_g instance %d doesn't exist\n",Mod_id);
AssertFatal(PHY_vars_eNB_g[Mod_id][CC_id] != NULL, "PHY_vars_eNB_g instance %d, CCid %d doesn't exist\n",Mod_id,CC_id);
NB_DL_FRAME_PARMS *fp = &PHY_vars_eNB_g[Mod_id][CC_id]->frame_parms_nb_iot;
LOG_I(PHY,"Configuring MIB-NB for instance %d, CCid %d : (band %d,Nid_cell %d,p %d,DL freq %u)\n",
Mod_id, CC_id, eutra_band, Nid_cell, p_eNB,dl_CarrierFreq);
LOG_I(PHY,"Configuring MIB-NB for instance %d, CCid %d : (band %d,Nid_cell %d,p %d,EARFCN %u)\n",
Mod_id, CC_id, eutra_band, Nid_cell, p_eNB,EARFCN);
// fp->N_RB_DL
// fp->N_RB_UL also this two values need to be known when we are dealing with in-band and guard-band operating mode
fp->Nid_cell = Nid_cell;
fp->nushift = Nid_cell%6;
fp->eutra_band = eutra_band;
fp->Ncp = Ncp;
fp->Ncp_UL = Ncp_UL;
fp->nb_antenna_ports_eNB = p_eNB; //tx antenna port
fp->dl_CarrierFreq = dl_CarrierFreq;
fp->ul_CarrierFreq = ul_CarrierFreq;
fp->dl_CarrierFreq = from_earfcn(eutra_band,EARFCN);
fp->ul_CarrierFreq = fp->dl_CarrierFreq - get_uldl_offset(eutra_band);
fp->operating_mode = operating_mode; //see how are defined by FAPI structure
fp->NB_IoT_RB_ID = prb_index; //XXX to be better understand how should be managed
//fp->nb_rx_antenna_ports_eNB
......@@ -103,12 +86,13 @@ void NB_phy_config_mib_eNB(
fp->eutra_NumCRS_ports = eutra_NumCRS_ports; //(valid only for in-band operating mode with different PCI)
//TODO
//TODO for nb-iot ??? (new Raymond implementation) in the classic implementation seems to be used only by oaisim
//init_frame_parms(fp,1);
//init_lte_top(fp);
}
//Before FAPI implementation
//void NB_phy_config_sib2_eNB(uint8_t Mod_id,
// int CC_id,
// RadioResourceConfigCommonSIB_NB_r13_t *radioResourceConfigCommon
......
......@@ -870,7 +870,7 @@ typedef struct {
uint8_t repetition_number;
/// Determined the ACK/NACK delay and the subcarrier allocation TS 36.213 Table 16.4.2
uint8_t HARQ_ACK_resource;
/// Determined the repetition number value 0-3
/// Determined the repetition number value 0-3 (2 biut carried by the FAPI NPDCCH)
uint8_t dci_subframe_repetitions;
/// modulation always QPSK Qm = 2
uint8_t modulation;
......
......@@ -227,6 +227,7 @@ void schedule_response(Sched_Rsp_t *Sched_INFO)
{
case NFAPI_DL_CONFIG_NPDCCH_PDU_TYPE:
//Remember: there is no DCI for SI information
//TODO: separate the ndlsch structure configuration from the DCI (here we will encode only the DCI)
NB_generate_eNB_dlsch_params(eNB,proc,dl_config_pdu);
break;
......@@ -319,17 +320,17 @@ void PHY_config_req(PHY_Config_t* config_INFO){
//MIB-NB configuration
NB_phy_config_mib_eNB(config_INFO->mod_id,
config_INFO->CC_id,
config_INFO->frequency_band_indicator,
config_INFO->cfg->nfapi_config.rf_bands.rf_band[0],//eutraband
config_INFO->cfg->sch_config.physical_cell_id.value,
config_INFO->cfg->subframe_config.dl_cyclic_prefix_type.value,
config_INFO->cfg->subframe_config.ul_cyclic_prefix_type.value,
config_INFO->cfg->rf_config.tx_antenna_ports.value,
config_INFO->dl_CarrierFreq,
config_INFO->ul_CarrierFreq,
config_INFO->cfg->nfapi_config.earfcn.value,
config_INFO->cfg->nb_iot_config.prb_index.value,
config_INFO->cfg->nb_iot_config.operating_mode.value,
config_INFO->cfg->nb_iot_config.control_region_size.value,
config_INFO->cfg->nb_iot_config.assumed_crs_aps.value); //defined only in in-band different PCI
}
if(config_INFO->get_COMMON != 0)
......@@ -344,6 +345,7 @@ void PHY_config_req(PHY_Config_t* config_INFO){
);
}
///FOR FAPI is not specified
if(config_INFO->get_DEDICATED!= 0)
{
//Dedicated Configuration
......
......@@ -1123,11 +1123,20 @@ void NB_phy_procedures_eNB_TX(PHY_VARS_eNB *eNB,
/*
* Delays between DCI transmission and NDLSCH transmission are taken in consideration by the MAC scheduler by sending in the proper subframe the scheduler_response
* (TS 36.213 ch 16.4.1: DCI format N1, N2, ending in subframe n intended for the UE, the UE shall decode, starting from subframe n+5 DL subframe,
* the corresponding NPDSCH transmission over the N consecutive NB/IoT DL subframes according to NPDCCH information)
* Transmission over more subframe and Repetitions are managed directly by the PHY layer
* We should have only 1 ue-specific ndlsch structure active at each time (active flag is set = 1 only at the corresponding NDLSCH pdu reception and not at the DCI time
* (NDLSCH transmission should be compliant with the FAPI procedure Figure 3-49)
*
* XXX how are managed the transmission and repetitions???
* XXX how are managed the transmission and repetitions over the NPDSCH:
* -repetitions over the NPDSCH channel are defined inside the DCI
* -need to know the repetition number R (see specs)
* -repetition are made following a pattern rule (e.g. 00, 11 ...) (see specs)
* --whenever R>4 then repetition pattern rule changes
* -possibility to have DL-GAP (OPTIONAL) otherwise no gap in DCI transmission
*
* XXX During repetitions of DCI or NDLSCH we receive no schedule_response form MAC
*
*/
......@@ -1168,7 +1177,26 @@ void NB_phy_procedures_eNB_TX(PHY_VARS_eNB *eNB,
//no dedicated phy config
/*If we have DCI to generate do it now*/
/*If we have DCI to generate do it now
*
* DCI in NB-IoT are transmitted over NPDCCH search spaces as described in TS 36.213 ch 16.6
* 1)distinction of NPDCCH SS is implicit with type of DCI? (assume yes)
* 2)NPDCCH rep. number (R) is obtained by different tables and by the higher layer parms:
* -npdcch-NumRepetitions (UE-specific)
* -npdcch-NumRepetitionPaging (common)
* -npdcch-NumRepetitions-rA (common)
* PROBLEM: in FAPI specs seems there is no way to trasnmit them to the PHY
*
* We need
* - a flag for telling us if it is a new repetition or not (means when the MAC transmit the scedule response for the DCI
* -Add a check for understanding if the current subframe is at the beginning of the search space or not
* -among the R repetition which number is the current one
*
* ***whenever we have aggretation level = 1 for UE-specific the R is always = 1 (see table 16.6-1)
*
*
* */
generate_dci_top_NB(
eNB->npdcch,
dci_pdu->Num_dci,
......
......@@ -541,6 +541,7 @@ typedef struct {
} eNB_STATS_NB;
/*! \brief top level eNB MAC structure */
typedef struct {
///
uint16_t Node_id;
/// frame counter
......
......@@ -59,7 +59,6 @@
#define ENABLE_MAC_PAYLOAD_DEBUG
#define DEBUG_eNB_SCHEDULER 1
//------------------------------------------------------------------------------
void init_ue_sched_info(void)
//------------------------------------------------------------------------------
......
......@@ -65,17 +65,13 @@ typedef struct{
//For Nb-IoT only a restricted values of PRB indexes are allowed (see Rhode&Shwartz pag9)
//unsigned short NB_IoT_RB_ID; (should coincide with PRB index)
//In FAPI specs --> is inside the nb_iot_rssi_request (P4 Network Monitor Mode procedure)
//In OAI is called eutra_band
uint8_t frequency_band_indicator; //parameter carried by the SIB1-NB, is and index of the Table 5.5-1 TS 36.101
//In 3GPP specs (TS 36.101 Table 5.7.3-1 and ch 5.7.3F) see also SIB2-NB freqInfo.ul-carrierFreq
//this parameters should be evaluated based of the EUTRA Absolute Radio Frequency Channel Number (EARFCN)
//in FAPI this value is given inside the BROADCAST DETECT request (P4 Network Monitor Mode procedure)
//in OAI we set the dl_CarrierFrequenci at configuration time (see COMMON/rrc_messages_types.h)
//then adding an offset for the ul_CarrierFreq ( see RU-RAU split approach - init_SI)
uint32_t dl_CarrierFreq;
uint32_t ul_CarrierFreq;
//uint32_t dl_CarrierFreq;
//uint32_t ul_CarrierFreq; --> problem solved since we directly evaluate the EARFCN has requested by FAPI specs
/*FAPI style config. parameters
......@@ -87,13 +83,14 @@ typedef struct{
* -nfapi_sch_config_t sch_config;
* -nfapi_nb_iot_config_t nb_iot_config;
* -nfapi_l23_config_t l23_config;
* -nfapi_config --> EARFCN
*
* */
//XXX where allocate memory??
nfapi_config_request_t* cfg;
/*Dedicated configuration -->not supported by FAPI
/*Dedicated configuration -->not supported by FAPI (may not needed)
* In OAI at least are needed when we manage the phy_procedures_eNB_TX in which we call the phy_config_dedicated_eNB_step2
* that use the physicalConfigDedicated info previously stored in the PHY_VARS_eNB structure through the phy_config_dedicated procedure
*/
......
This diff is collapsed.
Active_eNBs = ( "eNB_Eurecom_LTE_NB_IoT_Box");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
eNBs =
(
{
////////// Identification parameters:
eNB_ID = 0xe00;
cell_type = "CELL_MACRO_ENB";
eNB_name = "eNB_Eurecom_LTE_NB_IoT_Box";
// Tracking area code, 0x0000 and 0xfffe are reserved values
tracking_area_code = "1";
mobile_country_code = "208";
mobile_network_code = "92";
////////// Physical parameters:
component_carriers = (
{
node_function = "eNodeB_3GPP";
node_timing = "synch_to_ext_device";
node_synch_ref = 0;
frame_type = "FDD";
//TDD config should be not used for NB-IoT
/*
tdd_config = 3;
tdd_config_s = 0;
*/
#NORMAL cyclic prefix should be applied for DL frame
prefix_type = "NORMAL";
#set of allowed bands TS 36.104: 1,2,3,5,8,11,12,13,17,18,19,20,25,26,28,31,66,70
eutra_band = 3;
downlink_frequency = ;
uplink_frequency_offset = ; //shuld be the duplexing gap??
Nid_cell = 0;
N_RB_DL = 1;//only 1 RB assigned for NB_IoT
#it is also needed to know the NRB_DL and NRB_UL of LTE when we are in in-band and guard band mode
#it is also needed the PRB index choosen for NB-IoT depending on the LTE bandwidht we are using (only specific indexes are allowed)
nb_antennas_tx = 1;
nb_antennas_rx = 1;
tx_gain = 25;
rx_gain = 20;
nprach_CP_length = ;
#OPTIONAL (rsrp_thresholdsNPRACH)
rsrp_range = ;
nprach_Periodicity = ;
nprach_StartTime = ;
nprach_SubcarrierOffset = ;
nprach_NumSubcarriers_r13 = ;
nprach_SubcarrierMSG3_RangeStart = ;
maxNumPreambleAttemptCE = ;
numRepetitionsPerPreambleAttempt = ;
npdcch_NumRepetitions_RA = ;
npdcch_StartSF_CSS_RA = ;
npdcch_Offset_RA = ;
npdsch_nrs_Power = ;
ACK_NACK_NumRepetitions_NB = ;
threeTone_CyclicShift = ;
sixTone_CyclicShift = ;
pusch_groupAssignment = ;
//OPTIONAL
srs_SubframeConfig = ;
threeTone_BaseSequence = ;
sixTone_BaseSequence = ;
twelveTone_BaseSequence = ;
//OPTIONAL
dl_GapThreshold = ;
dl_GapPeriodicity = ;
dl_GapDurationCoeff = ;
//ULPowerControlCommon
p0_NominalNPUSCH = ;
alpha_r13 = ;
deltaPreambleMsg3 = ;
msg3_delta_Preamble = ;
preambleTransMax_CE = ;
powerRampingStep = ;
preambleInitialReceivedTargetPower = ;
ra_ResponseWindowSize = ;
mac_ContentionResolutionTimer = ;
//OPTIONAL
connEstFailOffset = ;
ue_TimersAndConstants_t300 = 1000;
ue_TimersAndConstants_t301 = 1000;
ue_TimersAndConstants_t310 = 1000;
ue_TimersAndConstants_t311 = 10000;
ue_TimersAndConstants_n310 = 20;
ue_TimersAndConstants_n311 = 1;
///freqInfo
additionalSpectrumEmission = ;
//OPTIONAL
carrierFreq = ;
carrierFreqOffset = ;
///multiBandInfoList(OPTIONAL)
AdditionalSpectrumEmission_t = ;
ue_TransmissionMode = 1;
}
);
#Default SRB1-NB configuration for RLC (same as for SIB1bis)
srb1_NB_parameters :
{
#NOTE: "N/A" means that the UE does not apply a specific value (E-UTRAN can not assume the UE to keeps the previously configured value upon switching to a default configuration
# timer_poll_retransmit = (ms) [250, 500, 1000,..., 4000, 6000, 10000, 15000, 25000,...] TS 36.331 v14.2.0 pag 616
timer_poll_retransmit = 25000;
//OPTIONAL
# timer_reordering = (ms) [0,5, ... 100, 110, 120, ... ,200]
timer_reordering = N/A;
//OPTIONAL
# timer_reordering = (ms) [0,5, ... 250, 300, 350, ... ,500]
timer_status_prohibit = N/A;
//OPTIONAL
# poll_pdu = [4, 8, 16, 32 , 64, 128, 256, infinity(>10000)]
poll_pdu = N/A;
//OPTIONAL
# poll_byte = (kB) [25,50,75,100,125,250,375,500,750,1000,1250,1500,2000,3000,infinity(>10000)]
poll_byte = N/A;
# max_retx_threshold = [1, 2, 3, 4 , 6, 8, 16, 32]
max_retx_threshold = 4;
#enableStatusReportSN_Gap = ENUMERATED {TRUE} (Enable the status reporting due to detection of reception failure)
enableStatusReportSN_Gap = "DISABLE"
}
# ------- SCTP definitions
SCTP :
{
# Number of streams to use in input/output
SCTP_INSTREAMS = 2;
SCTP_OUTSTREAMS = 2;
};
////////// MME parameters:
mme_ip_address = ( { ipv4 = "192.168.13.11";
ipv6 = "192:168:30::17";
active = "yes";
preference = "ipv4";
}
);
NETWORK_INTERFACES :
{
ENB_INTERFACE_NAME_FOR_S1_MME = "eth0";
ENB_IPV4_ADDRESS_FOR_S1_MME = "192.168.13.10/24";
ENB_INTERFACE_NAME_FOR_S1U = "eth0";
ENB_IPV4_ADDRESS_FOR_S1U = "192.168.13.10/24";
ENB_PORT_FOR_S1U = 2152; # Spec 2152
};
/*
otg_config = (
{
ue_id =1;
app_type ="scbr";
bg_traffic ="disable";
},
{
ue_id =2;
app_type ="bcbr";
bg_traffic ="enable";
}
);
*/
log_config :
{
global_log_level ="info";
global_log_verbosity ="medium";
hw_log_level ="debug";
hw_log_verbosity ="medium";
phy_log_level ="info";
phy_log_verbosity ="medium";
mac_log_level ="info";
mac_log_verbosity ="high";
rlc_log_level ="info";
rlc_log_verbosity ="medium";
pdcp_log_level ="info";
pdcp_log_verbosity ="medium";
rrc_log_level ="debug";
rrc_log_verbosity ="medium";
gtpu_log_level ="error";
gtpu_log_verbosity ="medium";
udp_log_level ="error";
udp_log_verbosity ="medium";
osa_log_level ="warn";
osa_log_verbosity ="low";
};
}
);
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment