Commit 7a2f8749 authored by Matthieu Kanj's avatar Matthieu Kanj

transmission conflict fix

parent 125878cf
...@@ -123,6 +123,7 @@ int generate_SIB1(NB_IoT_eNB_NDLSCH_t *sib1_struct, ...@@ -123,6 +123,7 @@ int generate_SIB1(NB_IoT_eNB_NDLSCH_t *sib1_struct,
4, 4,
RB_IoT_ID); RB_IoT_ID);
done =1; done =1;
frame_parms->flag_free_sf =1;
} }
...@@ -145,15 +146,15 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23, ...@@ -145,15 +146,15 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23,
{ {
int done=0; int done=0;
uint8_t *SIB23_pdu = SIB23->harq_process->pdu;
uint32_t rep = SIB23->resource_assignment;
uint8_t eutro_control_region = 3;
uint32_t counter_rep = SIB23->counter_repetition_number;
uint32_t pointer_to_sf = SIB23->pointer_to_subframe; /// to identify wich encoded subframe to transmit
if( SIB23->active == 1 ) if( SIB23->active == 1 )
{ {
uint8_t *SIB23_pdu = SIB23->harq_process->pdu;
uint32_t rep = SIB23->resource_assignment;
uint8_t eutro_control_region = 3;
uint32_t counter_rep = SIB23->counter_repetition_number;
uint32_t pointer_to_sf = SIB23->pointer_to_subframe; /// to identify wich encoded subframe to transmit
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
...@@ -184,6 +185,8 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23, ...@@ -184,6 +185,8 @@ int generate_SIB23(NB_IoT_eNB_NDLSCH_t *SIB23,
SIB23->counter_repetition_number--; SIB23->counter_repetition_number--;
SIB23->pointer_to_subframe++; SIB23->pointer_to_subframe++;
frame_parms->flag_free_sf =1;
if(SIB23->counter_repetition_number == 0) if(SIB23->counter_repetition_number == 0)
{ {
...@@ -210,16 +213,16 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR, ...@@ -210,16 +213,16 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR,
{ {
int done = 0; int done = 0;
uint8_t *RAR_pdu = RAR->harq_process->pdu; if( (RAR->active == 1) && (frame_parms->flag_free_sf == 0))
uint32_t rep = RAR->repetition_number; {
uint8_t eutro_control_region = 3; uint8_t *RAR_pdu = RAR->harq_process->pdu;
uint32_t rep = RAR->repetition_number;
uint8_t eutro_control_region = 3;
uint32_t counter_rep = RAR->counter_repetition_number; uint32_t counter_rep = RAR->counter_repetition_number;
uint32_t counter_sf_rep = RAR->counter_current_sf_repetition; /// for identifiying when to trigger new scrambling uint32_t counter_sf_rep = RAR->counter_current_sf_repetition; /// for identifiying when to trigger new scrambling
uint32_t pointer_to_sf = RAR->pointer_to_subframe; /// to identify wich encoded subframe to transmit uint32_t pointer_to_sf = RAR->pointer_to_subframe; /// to identify wich encoded subframe to transmit
if( RAR->active == 1 )
{
int G = get_G_NB_IoT(frame_parms); int G = get_G_NB_IoT(frame_parms);
uint8_t Nsf = RAR->number_of_subframes_for_resource_assignment; uint8_t Nsf = RAR->number_of_subframes_for_resource_assignment;
...@@ -316,7 +319,7 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR, ...@@ -316,7 +319,7 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR,
} }
///////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////////////////
/*int generate_NDCCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR, /*int generate_NDCCH_NB_IoT(NB_IoT_eNB_NPDCCH_t *DCI,
int32_t **txdataF, int32_t **txdataF,
int16_t amp, int16_t amp,
LTE_DL_FRAME_PARMS *frame_parms, LTE_DL_FRAME_PARMS *frame_parms,
...@@ -326,9 +329,9 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR, ...@@ -326,9 +329,9 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR,
{ {
int done=0; int done=0;
uint8_t *RAR_pdu = RAR->harq_process->pdu; uint8_t *DCI = RAR->harq_process->pdu;
uint32_t rep = RAR->repetition_number; uint32_t rep = RAR->repetition_number;
uint8_t eutro_control_region = 3; uint8_t eutro_control_region = 3;
uint32_t counter_rep = RAR->counter_repetition_number; uint32_t counter_rep = RAR->counter_repetition_number;
uint32_t counter_sf_rep = RAR->counter_current_sf_repetition; /// for identifiying when to trigger new scrambling uint32_t counter_sf_rep = RAR->counter_current_sf_repetition; /// for identifiying when to trigger new scrambling
...@@ -430,8 +433,8 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR, ...@@ -430,8 +433,8 @@ int generate_NDLSCH_NB_IoT(NB_IoT_eNB_NDLSCH_t *RAR,
return(done); return(done);
} }
*/
*/
////////////////////////////////////////////////// backup /////////////////////////// ////////////////////////////////////////////////// backup ///////////////////////////
......
...@@ -677,32 +677,35 @@ typedef struct { ...@@ -677,32 +677,35 @@ typedef struct {
typedef struct { typedef struct {
//the 2 LSB of the hsfn (the MSB are indicated by the SIB1-NB) //the 2 LSB of the hsfn (the MSB are indicated by the SIB1-NB)
rnti_t rnti[2]; rnti_t rnti[2];
//////////////////////////////////////////////////////// ////////////////////////////////////////////////////////
uint32_t length[2]; /// Active flag for baseband transmitter processing
uint32_t ncce_index[2]; uint8_t active[2];
uint32_t aggregation_level[2];
uint32_t rnti_type[2]; uint32_t length[2];
uint32_t dci_format[2]; uint32_t ncce_index[2];
uint32_t scheduling_delay[2]; uint32_t aggregation_level[2];
uint32_t resource_assignment[2]; uint32_t rnti_type[2];
uint32_t dci_format[2];
uint32_t scheduling_delay[2];
uint32_t resource_assignment[2];
// uint32_t repetition_number[2]; // uint32_t repetition_number[2];
uint32_t mcs[2]; uint32_t mcs[2];
uint32_t new_data_indicator[2]; uint32_t new_data_indicator[2];
uint32_t harq_ack_resource[2]; uint32_t harq_ack_resource[2];
uint32_t npdcch_order_indication[2]; uint32_t npdcch_order_indication[2];
uint32_t dci_subframe_repetition_number[2]; uint32_t dci_subframe_repetition_number[2];
//////////////////////////////////////////////////////// ////////////////////////////////////////////////////////
//UE specific parameters //UE specific parameters
uint16_t npdcch_NumRepetitions[2]; uint16_t npdcch_NumRepetitions[2];
uint16_t repetition_number[2]; uint16_t repetition_number[2];
//indicate the corresponding subframe within the repetition (set to 0 when a new NPDCCH pdu is received) //indicate the corresponding subframe within the repetition (set to 0 when a new NPDCCH pdu is received)
uint16_t repetition_idx[2]; uint16_t repetition_idx[2];
////////////////////////////////////// //////////////////////////////////////
uint32_t counter_repetition_number[2]; uint32_t counter_repetition_number[2];
// uint32_t counter_current_sf_repetition[2]; // uint32_t counter_current_sf_repetition[2];
// uint32_t pointer_to_subframe[2]; // uint32_t pointer_to_subframe[2];
////////////////////////////////////// //////////////////////////////////////
......
...@@ -232,6 +232,7 @@ int generate_npbch(NB_IoT_eNB_NPBCH_t *eNB_npbch, ...@@ -232,6 +232,7 @@ int generate_npbch(NB_IoT_eNB_NPBCH_t *eNB_npbch,
uint32_t symbol_offset; uint32_t symbol_offset;
uint16_t amask=0; uint16_t amask=0;
frame_parms->flag_free_sf =1;
/* /*
uint32_t ii=0; uint32_t ii=0;
uint8_t reset=1; uint8_t reset=1;
......
...@@ -50,6 +50,8 @@ int generate_npss_NB_IoT(int32_t **txdataF, ...@@ -50,6 +50,8 @@ int generate_npss_NB_IoT(int32_t **txdataF,
unsigned short NB_IoT_start; // Index of the first RE in the RB dedicated for NB-IoT unsigned short NB_IoT_start; // Index of the first RE in the RB dedicated for NB-IoT
unsigned short bandwidth_even_odd; unsigned short bandwidth_even_odd;
frame_parms->flag_free_sf =1;
slot_id = slot_offset; // The id(0..19) of the slot including the NPSS signal // For NB-IoT, slod_id should be 10 (SF5) slot_id = slot_offset; // The id(0..19) of the slot including the NPSS signal // For NB-IoT, slod_id should be 10 (SF5)
primary_sync = primary_synch_NB_IoT; // primary_synch_NB_IoT[264] of primary_synch_NB_IoT.h primary_sync = primary_synch_NB_IoT; // primary_synch_NB_IoT[264] of primary_synch_NB_IoT.h
......
...@@ -54,7 +54,9 @@ int generate_sss_NB_IoT(int32_t **txdataF, ...@@ -54,7 +54,9 @@ int generate_sss_NB_IoT(int32_t **txdataF,
uint16_t slot_id; // slot_id = 17 in NB_IoT uint16_t slot_id; // slot_id = 17 in NB_IoT
unsigned short bandwidth_even_odd; unsigned short bandwidth_even_odd;
unsigned short NB_IoT_start; unsigned short NB_IoT_start;
frame_parms->flag_free_sf =1;
n_f = frame_number; n_f = frame_number;
Nid_NB_IoT = frame_parms->Nid_cell; // supposing Cell_Id of LTE = Cell_Id of NB-IoT // if different , NB_IOT_DL_FRAME_PARMS should be includes as attribute Nid_NB_IoT = frame_parms->Nid_cell; // supposing Cell_Id of LTE = Cell_Id of NB-IoT // if different , NB_IOT_DL_FRAME_PARMS should be includes as attribute
......
...@@ -649,6 +649,8 @@ typedef struct { ...@@ -649,6 +649,8 @@ typedef struct {
NPUSCH_CONFIG_COMMONx npusch_config_common; NPUSCH_CONFIG_COMMONx npusch_config_common;
uint8_t RB_ID_NB_IoT; // to be used uint8_t RB_ID_NB_IoT; // to be used
uint8_t flag_free_sf; // flag to indicate for NPDSCH and NPDCCH process if the current SF already used
///////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////
} LTE_DL_FRAME_PARMS; } LTE_DL_FRAME_PARMS;
......
...@@ -232,6 +232,8 @@ void common_signal_procedures_NB_IoT(PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -232,6 +232,8 @@ void common_signal_procedures_NB_IoT(PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
int With_NSSS=0; // With_NSSS = 1; if the frame include a sub-Frame with NSSS signal int With_NSSS=0; // With_NSSS = 1; if the frame include a sub-Frame with NSSS signal
uint32_t hyper_frame=proc->HFN; uint32_t hyper_frame=proc->HFN;
//fp->flag_free_sf =0;
//////////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////////
/* /*
rrc_eNB_carrier_data_NB_IoT_t *carrier = &eNB_rrc_inst_NB_IoT->carrier[0]; rrc_eNB_carrier_data_NB_IoT_t *carrier = &eNB_rrc_inst_NB_IoT->carrier[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