Commit d580bcea authored by Nick Ho's avatar Nick Ho

Finish timing issue for sib23

parent 8d862a56
...@@ -96,6 +96,7 @@ int generate_SIB1(NB_IoT_eNB_NDLSCH_t *sib1_struct, ...@@ -96,6 +96,7 @@ int generate_SIB1(NB_IoT_eNB_NDLSCH_t *sib1_struct,
if((subframe == 4) && (frame%2 == var) && (born_inf<= frame % rep_val) && (frame % rep_val < born_sup )) if((subframe == 4) && (frame%2 == var) && (born_inf<= frame % rep_val) && (frame % rep_val < born_sup ))
{ {
LOG_D(PHY,"[%3d][%2d] Generating SIB1\n",frame,subframe);
int G = get_G_SIB1_NB_IoT(frame_parms,operation_mode); int G = get_G_SIB1_NB_IoT(frame_parms,operation_mode);
if( frame % rep_val == var ) if( frame % rep_val == var )
...@@ -158,6 +159,8 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23, ...@@ -158,6 +159,8 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23,
int G = get_G_NB_IoT(frame_parms); int G = get_G_NB_IoT(frame_parms);
uint8_t Nsf = SIB23->resource_assignment; //value 2 or 8 uint8_t Nsf = SIB23->resource_assignment; //value 2 or 8
LOG_D(PHY,"[%3d][%2d] Generating SIB23\n",frame,subframe);
if(counter_rep == rep) if(counter_rep == rep)
{ {
dlsch_encoding_NB_IoT(SIB23_pdu, dlsch_encoding_NB_IoT(SIB23_pdu,
...@@ -190,6 +193,7 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23, ...@@ -190,6 +193,7 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23,
if(SIB23->counter_repetition_number == 0) if(SIB23->counter_repetition_number == 0)
{ {
//printf("[%3d][%2d] Generate SIB23 done\n",frame,subframe);
SIB23->active = 0; SIB23->active = 0;
done =1; done =1;
} }
......
...@@ -187,7 +187,7 @@ void handle_nfapi_dlsch_pdu_NB_IoT(PHY_VARS_eNB *eNB, ...@@ -187,7 +187,7 @@ void handle_nfapi_dlsch_pdu_NB_IoT(PHY_VARS_eNB *eNB,
//Independently if we have the PDU or not (first transmission or repetition) the process is activated for triggering the ndlsch_procedure //Independently if we have the PDU or not (first transmission or repetition) the process is activated for triggering the ndlsch_procedure
//LOG_I(PHY,"ACTIVE_NB_IoT\n"); //LOG_I(PHY,"ACTIVE_NB_IoT\n");
ndlsch_harq23->status = ACTIVE_NB_IoT; ndlsch_harq23->status = ACTIVE_NB_IoT;
//LOG_I(PHY,"A NB-handle_nfapi_dlsch_pdu_NB_IoT SIB23\n"); LOG_I(PHY,"A NB-handle_nfapi_dlsch_pdu_NB_IoT SIB23\n");
} }
//ue specific data or RAR (we already have received the DCI for this) //ue specific data or RAR (we already have received the DCI for this)
......
...@@ -422,14 +422,11 @@ void rrc_mac_config_req_NB_IoT( ...@@ -422,14 +422,11 @@ void rrc_mac_config_req_NB_IoT(
if(sib1_NB_IoT != NULL) if(sib1_NB_IoT != NULL)
{ {
mac_config->sib1_NB_IoT_sched_config.repetitions = 4; mac_config->sib1_NB_IoT_sched_config.repetitions = 8;
//printf("[ASN Debug] SI P: %ld\n",sib1_NB_IoT->schedulingInfoList_r13.list.array[0]->si_Periodicity_r13); //printf("[ASN Debug] SI P: %ld\n",sib1_NB_IoT->schedulingInfoList_r13.list.array[0]->si_Periodicity_r13);
mac_config->sib1_NB_IoT_sched_config.starting_rf = 0;
//mac_config->sib1_NB_IoT_sched_config.starting_rf = *(sib1_NB_IoT->si_RadioFrameOffset_r13);
mac_config->sib1_NB_IoT_sched_config.starting_rf = 1;
mac_config->si_window_length = ms160; mac_config->si_window_length = ms160;
......
...@@ -30,7 +30,7 @@ void schedule_sibs(eNB_MAC_INST_NB_IoT *mac_inst, uint32_t sibs_order, int start ...@@ -30,7 +30,7 @@ void schedule_sibs(eNB_MAC_INST_NB_IoT *mac_inst, uint32_t sibs_order, int start
uint8_t SIB23_size = 0; uint8_t SIB23_size = 0;
uint8_t *SIB23_pdu = get_NB_IoT_SIB23(); uint8_t *SIB23_pdu = get_NB_IoT_SIB23();
int residual_subframe, num_subframe, last_subframe; int residual_subframe, num_subframe, last_subframe;
num_subframe = mac_inst->rrc_config.sibs_NB_IoT_sched[sibs_order].si_tb; num_subframe = (mac_inst->rrc_config.sibs_NB_IoT_sched[sibs_order].si_tb)*8;
int rmax = mac_inst->rrc_config.mac_NPRACH_ConfigSIB[0].mac_npdcch_NumRepetitions_RA_NB_IoT; int rmax = mac_inst->rrc_config.mac_NPRACH_ConfigSIB[0].mac_npdcch_NumRepetitions_RA_NB_IoT;
rmax = (rmax * 10) >> 3; // x1.25 rmax = (rmax * 10) >> 3; // x1.25
...@@ -87,14 +87,14 @@ void schedule_sibs(eNB_MAC_INST_NB_IoT *mac_inst, uint32_t sibs_order, int start ...@@ -87,14 +87,14 @@ void schedule_sibs(eNB_MAC_INST_NB_IoT *mac_inst, uint32_t sibs_order, int start
new_node->direction = DL; new_node->direction = DL;
new_node->DCI_release = (j==i); new_node->DCI_release = (j==i);
new_node->channel = NPDSCH; new_node->channel = NPDSCH;
new_node->rnti = SI_RNTI; new_node->rnti = 65535;
new_node->rnti_type = 3; new_node->rnti_type = 1;
new_node->npusch_format = 0; // useless new_node->npusch_format = 0; // useless
new_node->R_harq = 0; // useless new_node->R_harq = 0; // useless
new_node->next = (schedule_result_t *)0; new_node->next = (schedule_result_t *)0;
new_node->DCI_pdu = (void *)sibs_dci; new_node->DCI_pdu = (void *)sibs_dci;
//new_node->debug_str = str[sibs_order]; //new_node->debug_str = str[sibs_order];
LOG_D(MAC,"for*1 %d %d %d %p\n", pt[k]->start_subframe, first_subframe[k], (j==i)?last_subframe:j+9, new_node); LOG_D(MAC,"debug: pt[k]->start_subframe:%d output_subframe:%d end_subframe:%d rep:%d\n", pt[k]->start_subframe, first_subframe[k], (j==i)?last_subframe:j+9,si_repetition_pattern[mac_inst->rrc_config.sibs_NB_IoT_sched[sibs_order].si_repetition_pattern]);
fill_resource_DL(mac_inst, pt[k], first_subframe[k], (j==i)?last_subframe:j+9, new_node); fill_resource_DL(mac_inst, pt[k], first_subframe[k], (j==i)?last_subframe:j+9, new_node);
LOG_D(MAC,"for*2\n"); LOG_D(MAC,"for*2\n");
} }
......
...@@ -161,10 +161,10 @@ uint8_t *get_NB_IoT_SIB1(uint8_t Mod_id, int CC_id, ...@@ -161,10 +161,10 @@ uint8_t *get_NB_IoT_SIB1(uint8_t Mod_id, int CC_id,
{ {
if(frame%64==1 && subframe ==0) //if(frame%64==1 && subframe ==0)
{ //{
do_SIB1_NB_IoT_x(Mod_id,CC_id,carrier,mcc,mnc,tac,cell_identity,band,mnc_digit_length,hyper_frame); do_SIB1_NB_IoT_x(Mod_id,CC_id,carrier,mcc,mnc,tac,cell_identity,band,mnc_digit_length,hyper_frame);
} //}
......
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