Commit 3681d24f authored by Michele Paffetti's avatar Michele Paffetti

adding NPDCCH structure for UE specific and Common Search space. To be...

adding NPDCCH structure for UE specific and Common Search space. To be implemented NPDCCH repetitions.Code Copile. 145 Warnings
parent 0fffe1a3
...@@ -369,16 +369,17 @@ void NB_phy_config_dedicated_eNB(uint8_t Mod_id, ...@@ -369,16 +369,17 @@ void NB_phy_config_dedicated_eNB(uint8_t Mod_id,
} }
//configure UE specific parameters for NPDCCH Search Space //configure UE specific parameters for NPDCCH Search Space
//
if (eNB->npdcch[UE_id]) { if (eNB->npdcch[UE_id]) {
npdcch = eNB->npdcch[UE_id]; npdcch = eNB->npdcch[UE_id];
npdcch->rnti = rnti; npdcch->rnti = rnti;
npdcch->npdcch_NumRepetitions = extra_parms->npdcch_NumRepetitions; npdcch->npdcch_NumRepetitions = extra_parms->npdcch_NumRepetitions; //Rmax maybe is the only one needed
npdcch->npdcch_Offset_USS = extra_parms->npdcch_Offset_USS; // npdcch->npdcch_Offset_USS = extra_parms->npdcch_Offset_USS;
npdcch->npdcch_StartSF_USS = extra_parms->npdcch_StartSF_USS; // npdcch->npdcch_StartSF_USS = extra_parms->npdcch_StartSF_USS;
LOG_I(PHY,"NB_phy_config_dedicated_eNB: npdcch_NumRepetitions = %d, npdcch_Offset_USS = %d, npdcch_StartSF_USS = %d\n", LOG_I(PHY,"NB_phy_config_dedicated_eNB: npdcch_NumRepetitions = %d\n",
npdcch->npdcch_NumRepetitions, npdcch->npdcch_Offset_USS, npdcch->npdcch_StartSF_USS); npdcch->npdcch_NumRepetitions);
} else { } else {
LOG_E(PHY,"[eNB %d] Received NULL radioResourceConfigDedicated from eNB %d\n",Mod_id, UE_id); LOG_E(PHY,"[eNB %d] Received NULL radioResourceConfigDedicated from eNB %d\n",Mod_id, UE_id);
......
...@@ -820,7 +820,6 @@ typedef enum ...@@ -820,7 +820,6 @@ typedef enum
typedef struct { typedef struct {
rnti_t rnti; rnti_t rnti;
//array containing the pdus of DCI //array containing the pdus of DCI
uint8_t *a[2]; uint8_t *a[2];
...@@ -829,13 +828,31 @@ typedef struct { ...@@ -829,13 +828,31 @@ typedef struct {
//UE specific parameters //UE specific parameters
uint16_t npdcch_NumRepetitions; uint16_t npdcch_NumRepetitions;
uint16_t npdcch_Offset_USS;
uint16_t npdcch_StartSF_USS; uint16_t repetition_number;
//indicate the corresponding subframe within the repetition (set to 0 when a new NPDCCH pdu is received)
uint16_t repetition_idx;
// uint16_t npdcch_Offset_USS;
// uint16_t npdcch_StartSF_USS;
}NB_IoT_eNB_NPDCCH_t; }NB_IoT_eNB_NPDCCH_t;
typedef struct{
//Number of repetitions (R) for common search space (RAR and PAGING)
uint16_t number_repetition_RA;
uint16_t number_repetition_PAg;
//index of the current subframe among the repetition (set to 0 when we receive the new NPDCCH)
uint16_t repetition_idx_RA;
uint16_t repetition_idx_Pag;
}NB_IoT_eNB_COMMON_NPDCCH_t;
typedef struct { typedef struct {
...@@ -1080,7 +1097,7 @@ typedef struct { ...@@ -1080,7 +1097,7 @@ typedef struct {
uint8_t npbch_e[1600]; uint8_t npbch_e[1600];
///pdu of the npbch message ///pdu of the npbch message
uint8_t*pdu; uint8_t*pdu;
} NB_IoT_eNB_NPBCH; } NB_IoT_eNB_NPBCH_t;
//--------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------
......
...@@ -117,7 +117,7 @@ int allocate_npbch_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -117,7 +117,7 @@ int allocate_npbch_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
} }
/********************************************************** /**********************************************************
**********************************************************/ **********************************************************/
int generate_npbch(NB_IoT_eNB_NPBCH *eNB_npbch, int generate_npbch(NB_IoT_eNB_NPBCH_t *eNB_npbch,
int32_t **txdataF, int32_t **txdataF,
int amp, int amp,
LTE_DL_FRAME_PARMS *frame_parms, LTE_DL_FRAME_PARMS *frame_parms,
......
...@@ -75,7 +75,7 @@ int allocate_npbch_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -75,7 +75,7 @@ int allocate_npbch_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
unsigned short id_offset, unsigned short id_offset,
uint32_t *re_allocated); uint32_t *re_allocated);
int generate_npbch(NB_IoT_eNB_NPBCH *eNB_npbch, int generate_npbch(NB_IoT_eNB_NPBCH_t *eNB_npbch,
int32_t **txdataF, int32_t **txdataF,
int amp, int amp,
LTE_DL_FRAME_PARMS *frame_parms, LTE_DL_FRAME_PARMS *frame_parms,
......
...@@ -702,8 +702,9 @@ typedef struct PHY_VARS_eNB_s { ...@@ -702,8 +702,9 @@ typedef struct PHY_VARS_eNB_s {
* *
*/ */
NB_IoT_eNB_NPBCH *npbch; //TODO: check what should be NUMBER_OF_UE_MAX_NB_IoT value
NB_IoT_eNB_NPDCCH_t *npdcch[NUMBER_OF_UE_MAX_NB_IoT]; //check if should be an array and the max size of this array NB_IoT_eNB_NPBCH_t *npbch;
NB_IoT_eNB_NPDCCH_t *npdcch[NUMBER_OF_UE_MAX_NB_IoT];
NB_IoT_eNB_NDLSCH_t *ndlsch[NUMBER_OF_UE_MAX_NB_IoT]; NB_IoT_eNB_NDLSCH_t *ndlsch[NUMBER_OF_UE_MAX_NB_IoT];
NB_IoT_eNB_NULSCH_t *nulsch[NUMBER_OF_UE_MAX_NB_IoT+1]; //nulsch[0] contains the RAR NB_IoT_eNB_NULSCH_t *nulsch[NUMBER_OF_UE_MAX_NB_IoT+1]; //nulsch[0] contains the RAR
NB_IoT_eNB_NDLSCH_t *ndlsch_SI,*ndlsch_ra, *ndlsch_SIB1; NB_IoT_eNB_NDLSCH_t *ndlsch_SI,*ndlsch_ra, *ndlsch_SIB1;
......
...@@ -63,7 +63,7 @@ typedef struct NPRACH_Parameters_NB{ ...@@ -63,7 +63,7 @@ typedef struct NPRACH_Parameters_NB{
uint16_t maxNumPreambleAttemptCE; uint16_t maxNumPreambleAttemptCE;
/// Number of NPRACH repetitions per attempt for each NPRACH resource /// Number of NPRACH repetitions per attempt for each NPRACH resource
uint16_t numRepetitionsPerPreambleAttempt; uint16_t numRepetitionsPerPreambleAttempt;
/// The number of the repetition for DCI use in RAR/MSG3/MSG4 from 1 - 2048 /// The number of the repetition for DCI use in RAR/MSG3/MSG4 from 1 - 2048 (Rmax)
uint16_t npdcch_NumRepetitions_RA; uint16_t npdcch_NumRepetitions_RA;
/// Starting subframe for NPDCCH Common searching space for (RAR/MSG3/MSG4) /// Starting subframe for NPDCCH Common searching space for (RAR/MSG3/MSG4)
uint16_t npdcch_StartSF_CSS_RA; uint16_t npdcch_StartSF_CSS_RA;
...@@ -90,6 +90,7 @@ typedef struct { ...@@ -90,6 +90,7 @@ typedef struct {
struct rsrp_ThresholdsNPrachInfoList *rsrp_ThresholdsPrachInfoList; struct rsrp_ThresholdsNPrachInfoList *rsrp_ThresholdsPrachInfoList;
/// NPRACH Parameters List /// NPRACH Parameters List
NPRACH_List_NB_t nprach_ParametersList; NPRACH_List_NB_t nprach_ParametersList;
} NPRACH_CONFIG_COMMON; } NPRACH_CONFIG_COMMON;
/// NPDSCH-ConfigCommon from 36.331 RRC spec /// NPDSCH-ConfigCommon from 36.331 RRC spec
...@@ -264,7 +265,6 @@ typedef struct { ...@@ -264,7 +265,6 @@ typedef struct {
uint16_t eutra_NumCRS_ports; uint16_t eutra_NumCRS_ports;
} NB_DL_FRAME_PARMS; } NB_DL_FRAME_PARMS;
......
...@@ -169,7 +169,7 @@ void schedule_response(Sched_Rsp_t *Sched_INFO) ...@@ -169,7 +169,7 @@ void schedule_response(Sched_Rsp_t *Sched_INFO)
//XXX check if correct to take eNB like this //XXX check if correct to take eNB like this
PHY_VARS_eNB *eNB = PHY_vars_eNB_g[0][Sched_INFO->CC_id]; PHY_VARS_eNB *eNB = PHY_vars_eNB_g[0][Sched_INFO->CC_id];
eNB_rxtx_proc_t *proc = &eNB->proc.proc_rxtx[0]; eNB_rxtx_proc_t *proc = &eNB->proc.proc_rxtx[0];
NB_IoT_eNB_NPBCH *npbch; NB_IoT_eNB_NPBCH_t *npbch;
int i; int i;
......
...@@ -36,7 +36,7 @@ typedef struct{ ...@@ -36,7 +36,7 @@ typedef struct{
uint16_t nprach_config_0_max_num_preamble_attempt_CE; uint16_t nprach_config_0_max_num_preamble_attempt_CE;
uint16_t nprach_config_1_max_num_preamble_attempt_CE; uint16_t nprach_config_1_max_num_preamble_attempt_CE;
uint16_t nprach_config_2_max_num_preamble_attempt_CE; uint16_t nprach_config_2_max_num_preamble_attempt_CE;
uint16_t nprach_config_0_npdcch_num_repetitions_RA; //Rmax (see TS 36.213 ch 16.6) uint16_t nprach_config_0_npdcch_num_repetitions_RA; //Rmax (see TS 36.213 ch 16.6) -->only this is managed at PHY layer
uint16_t nprach_config_1_npdcch_num_repetitions_RA; uint16_t nprach_config_1_npdcch_num_repetitions_RA;
uint16_t nprach_config_2_npdcch_num_repetitions_RA; uint16_t nprach_config_2_npdcch_num_repetitions_RA;
uint16_t nprach_config_0_npdcch_startSF_CSS_RA; //G (see TS 36.213 ch 16.6) uint16_t nprach_config_0_npdcch_startSF_CSS_RA; //G (see TS 36.213 ch 16.6)
...@@ -48,7 +48,7 @@ typedef struct{ ...@@ -48,7 +48,7 @@ typedef struct{
//configured through the phy_config_dedicated //configured through the phy_config_dedicated
//Higher layer parameter for NPDCCH UE-spec search space //Higher layer parameter for NPDCCH UE-spec search space
uint16_t npdcch_NumRepetitions;//Rmax (see TS 36.213 ch 16.6) uint16_t npdcch_NumRepetitions;//Rmax (see TS 36.213 ch 16.6) -->only this is managed at PHY layer
uint16_t npdcch_StartSF_USS; //G (see TS 36.213 ch 16.6) uint16_t npdcch_StartSF_USS; //G (see TS 36.213 ch 16.6)
uint16_t npdcch_Offset_USS; //Alfa_offset (see TS 36.213 ch 16.6) uint16_t npdcch_Offset_USS; //Alfa_offset (see TS 36.213 ch 16.6)
......
...@@ -376,7 +376,7 @@ void config_sib2_NB_fapi( ...@@ -376,7 +376,7 @@ void config_sib2_NB_fapi(
//MP: missed configuration for FAPI-style structure (I have added on my own byt maybe are not needed) //MP: missed configuration for FAPI-style structure (I have added on my own byt maybe are not needed)
config_INFO->extra_phy_parms.nprach_config_0_subcarrier_MSG3_range_start = nprach_parameter->nprach_SubcarrierMSG3_RangeStart_r13; config_INFO->extra_phy_parms.nprach_config_0_subcarrier_MSG3_range_start = nprach_parameter->nprach_SubcarrierMSG3_RangeStart_r13;
config_INFO->extra_phy_parms.nprach_config_0_max_num_preamble_attempt_CE = nprach_parameter->maxNumPreambleAttemptCE_r13; config_INFO->extra_phy_parms.nprach_config_0_max_num_preamble_attempt_CE = nprach_parameter->maxNumPreambleAttemptCE_r13;
config_INFO->extra_phy_parms.nprach_config_0_npdcch_num_repetitions_RA = nprach_parameter->npdcch_NumRepetitions_RA_r13; config_INFO->extra_phy_parms.nprach_config_0_npdcch_num_repetitions_RA = nprach_parameter->npdcch_NumRepetitions_RA_r13; //Rmax
config_INFO->extra_phy_parms.nprach_config_0_npdcch_startSF_CSS_RA = nprach_parameter->npdcch_StartSF_CSS_RA_r13; config_INFO->extra_phy_parms.nprach_config_0_npdcch_startSF_CSS_RA = nprach_parameter->npdcch_StartSF_CSS_RA_r13;
config_INFO->extra_phy_parms.nprach_config_0_npdcch_offset_RA = nprach_parameter->npdcch_Offset_RA_r13; config_INFO->extra_phy_parms.nprach_config_0_npdcch_offset_RA = nprach_parameter->npdcch_Offset_RA_r13;
//rsrp_ThresholdsPrachInfoList_r13 /*OPTIONAL*/ //rsrp_ThresholdsPrachInfoList_r13 /*OPTIONAL*/
...@@ -706,11 +706,10 @@ int NB_rrc_mac_config_req_eNB( ...@@ -706,11 +706,10 @@ int NB_rrc_mac_config_req_eNB(
config_INFO->get_DEDICATED = 1; config_INFO->get_DEDICATED = 1;
//XXX this parameters seems to be not defined by FAPi specs //XXX this parameters seems to be not defined by FAPi specs
//this are UE specific information that should be transmitted to the PHY layer //this are UE specific information that should be transmitted to the PHY layer
//Possible implementation is to use UE-specific structure at phy layer where to store this information (NPDCCH structure) this structure will be scrambled based on the rnti //use UE-specific structure at phy layer where to store this information (NPDCCH structure) this structure will be scrambled based on the rnti
config_INFO->rnti = UE_RNTI(Mod_idP, UE_id); config_INFO->rnti = UE_RNTI(Mod_idP, UE_id);
config_INFO->extra_phy_parms.npdcch_NumRepetitions = physicalConfigDedicated->npdcch_ConfigDedicated_r13->npdcch_NumRepetitions_r13; config_INFO->extra_phy_parms.npdcch_NumRepetitions = physicalConfigDedicated->npdcch_ConfigDedicated_r13->npdcch_NumRepetitions_r13; //Rmax
config_INFO->extra_phy_parms.npdcch_Offset_USS = physicalConfigDedicated->npdcch_ConfigDedicated_r13->npdcch_Offset_USS_r13; config_INFO->extra_phy_parms.npdcch_Offset_USS = physicalConfigDedicated->npdcch_ConfigDedicated_r13->npdcch_Offset_USS_r13;
config_INFO->extra_phy_parms.npdcch_StartSF_USS = physicalConfigDedicated->npdcch_ConfigDedicated_r13->npdcch_StartSF_USS_r13; config_INFO->extra_phy_parms.npdcch_StartSF_USS = physicalConfigDedicated->npdcch_ConfigDedicated_r13->npdcch_StartSF_USS_r13;
......
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