Commit f5be2be5 authored by gabrielC's avatar gabrielC

Correct DCIFormat and AgregationLevel to put them in pdcch structure

parent 10c9d899
......@@ -3056,12 +3056,14 @@ void dci_decoding_procedure0(LTE_UE_PDCCH **pdcch_vars,
return;
} // rnti match
} // CCEmap_cand == 0
if ( agregationLevel != 0xFF &&
/*
if ( agregationLevel != 0xFF &&
(format_c == format0 && m==0 && si_rnti != SI_RNTI))
{
//Only valid for OAI : Save some processing time when looking for DCI format0. From the log we see the DCI only on candidate 0.
return;
}
*/
} // candidate loop
}
......@@ -3651,9 +3653,6 @@ uint16_t dci_decoding_procedure(PHY_VARS_UE *ue,
((format0_found==1)&&(format_c_found==1)))
return(dci_cnt);
if ((CCEmap0==0xffff)||
((format0_found==1)&&(format_c_found==1)))
return(dci_cnt);
//printf("[DCI search] Format 0 aggregation 2 dci_cnt %d\n",dci_cnt);
}
......
......@@ -75,8 +75,6 @@
#define RX_NB_TH_MAX 2
#define RX_NB_TH 2
extern uint8_t dciFormat;
extern uint8_t agregationLevel;
//#ifdef SHRLIBDEV
......
......@@ -1034,6 +1034,9 @@ typedef struct {
uint32_t dci_missed;
/// nCCE for PUCCH per subframe
uint8_t nCCE[10];
//Check for specific DCIFormat and AgregationLevel
uint8_t dciFormat;
uint8_t agregationLevel;
} LTE_UE_PDCCH;
#define PBCH_A 24
......
......@@ -78,8 +78,6 @@ unsigned char NB_INST=0;
unsigned int ULSCH_max_consecutive_errors = 20;
int number_of_cards;
uint8_t dciFormat;
uint8_t agregationLevel;
int flag_LA=0;
......
......@@ -3097,7 +3097,7 @@ int ue_pdcch_procedures(uint8_t eNB_id,PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint
//printf("Decode SIB frame param agregation + DCI %d %d \n",agregationLevel,dciFormat);
//agregation level == FF means no configuration on
if(agregationLevel == 0xFF || ue->decode_SIB)
if(ue->pdcch_vars[ue->current_thread_id[subframe_rx]][eNB_id]->agregationLevel == 0xFF || ue->decode_SIB)
{
// search all possible dcis
dci_cnt = dci_decoding_procedure(ue,
......@@ -3112,8 +3112,8 @@ int ue_pdcch_procedures(uint8_t eNB_id,PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint
// search C RNTI dci
dci_cnt = dci_CRNTI_decoding_procedure(ue,
dci_alloc_rx,
dciFormat,
agregationLevel,
ue->pdcch_vars[ue->current_thread_id[subframe_rx]][eNB_id]->dciFormat,
ue->pdcch_vars[ue->current_thread_id[subframe_rx]][eNB_id]->agregationLevel,
eNB_id,
subframe_rx);
}
......
......@@ -1590,10 +1590,6 @@ int main( int argc, char **argv ) {
NB_UE_INST=1;
NB_INST=1;
dciFormat = dci_Format;
agregationLevel = agregation_Level;
LOG_I(PHY,"Set dciFormat %d , agregationLevel %d \n",dciFormat, agregationLevel);
PHY_vars_UE_g = malloc(sizeof(PHY_VARS_UE**));
PHY_vars_UE_g[0] = malloc(sizeof(PHY_VARS_UE*)*MAX_NUM_CCs);
......@@ -1626,6 +1622,11 @@ int main( int argc, char **argv ) {
UE[CC_id]->mode = mode;
printf("UE[%d]->mode = %d\n",CC_id,mode);
for (uint8_t i=0; i<RX_NB_TH_MAX; i++) {
UE[CC_id]->pdcch_vars[i][0]->agregationLevel = agregation_Level;
UE[CC_id]->pdcch_vars[i][0]->dciFormat = dci_Format;
}
compute_prach_seq(&UE[CC_id]->frame_parms.prach_config_common,
UE[CC_id]->frame_parms.frame_type,
UE[CC_id]->X_u);
......
......@@ -1431,6 +1431,11 @@ void init_openair1(void)
PHY_vars_UE_g[UE_id][CC_id]->mac_enabled=1;
PHY_vars_UE_g[UE_id][CC_id]->pdcch_vars[0][0]->crnti = 0x1235 + UE_id;
for (uint8_t i=0; i<RX_NB_TH_MAX; i++) {
PHY_vars_UE_g[UE_id][CC_id]->pdcch_vars[i][0]->dciFormat = 0;
PHY_vars_UE_g[UE_id][CC_id]->pdcch_vars[i][0]->agregationLevel = 0xFF;
}
PHY_vars_UE_g[UE_id][CC_id]->current_dlsch_cqi[0] = 10;
LOG_I(EMU, "UE %d mode is initialized to %d\n", UE_id, PHY_vars_UE_g[UE_id][CC_id]->UE_mode[0] );
......
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