Commit 5667fc4e authored by gabriel's avatar gabriel

change to nr_tti in SCHED folder

parent 05d882e8
...@@ -197,6 +197,12 @@ typedef struct { ...@@ -197,6 +197,12 @@ typedef struct {
uint8_t CC_id; uint8_t CC_id;
/// timestamp transmitted to HW /// timestamp transmitted to HW
openair0_timestamp timestamp_tx; openair0_timestamp timestamp_tx;
#ifdef UE_NR_PHY_DEMO
/// NR TTI index within subframe_tx [0 .. ttis_per_subframe - 1] to act upon for transmission
int nr_tti_tx;
/// NR TTI index within subframe_rx [0 .. ttis_per_subframe - 1] to act upon for reception
int nr_tti_rx;
#endif
/// subframe to act upon for transmission /// subframe to act upon for transmission
int subframe_tx; int subframe_tx;
/// subframe to act upon for reception /// subframe to act upon for reception
......
...@@ -57,12 +57,12 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -57,12 +57,12 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
uint32_t rballoc = 0x1FFFF; uint32_t rballoc = 0x1FFFF;
//uint32_t rballoc2 = 0x000F; //uint32_t rballoc2 = 0x000F;
int subframe = proc->subframe_tx; int nr_tti_tx = proc->nr_tti_tx;
/* /*
uint32_t rand = taus(); uint32_t rand = taus();
if ((subframe==8) || (subframe==9) || (subframe==0)) if ((nr_tti_tx==8) || (nr_tti_tx==9) || (nr_tti_tx==0))
rand = (rand%5)+5; rand = (rand%5)+5;
else else
rand = (rand%4)+5; rand = (rand%4)+5;
...@@ -70,11 +70,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -70,11 +70,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
uint32_t bcch_pdu; uint32_t bcch_pdu;
uint64_t dlsch_pdu; uint64_t dlsch_pdu;
LOG_D(PHY,"frame %d, subframe %d, transmission_mode %d\n",proc->frame_tx,proc->subframe_tx,transmission_mode); LOG_D(PHY,"frame %d, nr_tti_tx %d, transmission_mode %d\n",proc->frame_tx,proc->nr_tti_tx,transmission_mode);
DCI_pdu->Num_dci = 0; DCI_pdu->Num_dci = 0;
switch (subframe) { switch (nr_tti_tx) {
case 5: case 5:
if ( !(proc->frame_tx&1) ) // SI message on even frame only (SFN mod 2 == 0) if ( !(proc->frame_tx&1) ) // SI message on even frame only (SFN mod 2 == 0)
{ {
...@@ -159,10 +159,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -159,10 +159,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->type = 1; ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->type = 1;
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->vrb_type = 0; ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->vrb_type = 0;
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->rballoc = computeRIV(50,10,3); ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->rballoc = computeRIV(50,10,3);
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->ndi = subframe / 5; ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->ndi = nr_tti_tx / 5;
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->rv = 1; ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->rv = 1;
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->mcs = 1; ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->mcs = 1;
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->harq_pid = subframe % 5; ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->harq_pid = nr_tti_tx % 5;
((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->TPC = 1; // set to 3 PRB ((DCI1A_10MHz_TDD_1_6_t*)&bcch_pdu)->TPC = 1; // set to 3 PRB
memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],&bcch_pdu,sizeof(DCI1A_10MHz_TDD_1_6_t)); memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],&bcch_pdu,sizeof(DCI1A_10MHz_TDD_1_6_t));
} }
...@@ -196,13 +196,13 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -196,13 +196,13 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
break; break;
} }
break; //subframe switch break; //nr_tti_tx switch
} // if ( !(proc->frame_tx&1) ) } // if ( !(proc->frame_tx&1) )
else // No SI message on odd frame (SFN mod 2 == 1) else // No SI message on odd frame (SFN mod 2 == 1)
{ {
/* warning: work around to send dlsch on subframe 5 odd frame !!! */ /* warning: work around to send dlsch on nr_tti_tx 5 odd frame !!! */
/* todo: clean up, espacially if subframe cases are added next !!! */ /* todo: clean up, espacially if nr_tti_tx cases are added next !!! */
} }
/* /*
case 6: case 6:
...@@ -244,11 +244,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -244,11 +244,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
if (eNB->frame_parms.frame_type == FDD) { if (eNB->frame_parms.frame_type == FDD) {
DCI_pdu->dci_alloc[0].dci_length = sizeof_DCI1_5MHz_FDD_t; DCI_pdu->dci_alloc[0].dci_length = sizeof_DCI1_5MHz_FDD_t;
harq_pid_value = ( ((proc->frame_tx * 10) + subframe) % 8 ); harq_pid_value = ( ((proc->frame_tx * 10) + nr_tti_tx) % 8 );
if (!(subframe&1)) // even subframe if (!(nr_tti_tx&1)) // even nr_tti_tx
dci_ndi_toggle_tmp = &(dci_ndi_toggle_even[harq_pid_value]); dci_ndi_toggle_tmp = &(dci_ndi_toggle_even[harq_pid_value]);
else // odd subframe else // odd nr_tti_tx
dci_ndi_toggle_tmp = &(dci_ndi_toggle_odd[harq_pid_value]); dci_ndi_toggle_tmp = &(dci_ndi_toggle_odd[harq_pid_value]);
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(25,10,3); ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(25,10,3);
...@@ -275,7 +275,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -275,7 +275,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1;
//((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[subframe].frame%1024)%28); //((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[nr_tti_tx].frame%1024)%28);
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->ndi = 1; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->ndi = 1;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rv = 0;
...@@ -287,10 +287,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -287,10 +287,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(25,10,3); ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(25,10,3);
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->harq_pid = subframe % 5; ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->harq_pid = nr_tti_tx % 5;
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
//((DCI1_5MHz_TDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->frame%1024)%28); //((DCI1_5MHz_TDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->frame%1024)%28);
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->ndi = subframe / 5; ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->ndi = nr_tti_tx / 5;
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->rv = 0;
((DCI1_5MHz_TDD_t *)&dlsch_pdu)->rah = 0; ((DCI1_5MHz_TDD_t *)&dlsch_pdu)->rah = 0;
memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],(void *)&dlsch_pdu,sizeof(DCI1_5MHz_TDD_t)); memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],(void *)&dlsch_pdu,sizeof(DCI1_5MHz_TDD_t));
...@@ -307,7 +307,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -307,7 +307,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1;
//((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[subframe].frame%1024)%28); //((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[nr_tti_tx].frame%1024)%28);
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->ndi = 1; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->ndi = 1;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rv = 0;
...@@ -323,11 +323,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -323,11 +323,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
if (eNB->frame_parms.frame_type == FDD) { if (eNB->frame_parms.frame_type == FDD) {
DCI_pdu->dci_alloc[0].dci_length = sizeof_DCI1_10MHz_FDD_t; DCI_pdu->dci_alloc[0].dci_length = sizeof_DCI1_10MHz_FDD_t;
harq_pid_value = ( ((proc->frame_tx * 10) + subframe) % 8 ); harq_pid_value = ( ((proc->frame_tx * 10) + nr_tti_tx) % 8 );
if (!(subframe&1)) // even subframe if (!(nr_tti_tx&1)) // even nr_tti_tx
dci_ndi_toggle_tmp = &(dci_ndi_toggle_even[harq_pid_value]); dci_ndi_toggle_tmp = &(dci_ndi_toggle_even[harq_pid_value]);
else // odd subframe else // odd nr_tti_tx
dci_ndi_toggle_tmp = &(dci_ndi_toggle_odd[harq_pid_value]); dci_ndi_toggle_tmp = &(dci_ndi_toggle_odd[harq_pid_value]);
((DCI1_10MHz_FDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(50,10,3); ((DCI1_10MHz_FDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(50,10,3);
...@@ -347,10 +347,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -347,10 +347,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(50,10,3); ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(50,10,3);
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->harq_pid = subframe % 5; ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->harq_pid = nr_tti_tx % 5;
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
//((DCI1_10MHz_TDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->frame%1024)%28); //((DCI1_10MHz_TDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->frame%1024)%28);
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->ndi = subframe / 5; ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->ndi = nr_tti_tx / 5;
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->rv = 0;
((DCI1_10MHz_TDD_t *)&dlsch_pdu)->rah = 0; ((DCI1_10MHz_TDD_t *)&dlsch_pdu)->rah = 0;
memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],(void *)&dlsch_pdu,sizeof(DCI1_10MHz_TDD_t)); memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],(void *)&dlsch_pdu,sizeof(DCI1_10MHz_TDD_t));
...@@ -367,7 +367,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -367,7 +367,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_10MHz_FDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_10MHz_FDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_10MHz_FDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_10MHz_FDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_10MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1; ((DCI1_10MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1;
//((DCI1_10MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[subframe].frame%1024)%28); //((DCI1_10MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[nr_tti_tx].frame%1024)%28);
((DCI1_10MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_10MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
((DCI1_10MHz_FDD_t *)&dlsch_pdu)->ndi = 1; ((DCI1_10MHz_FDD_t *)&dlsch_pdu)->ndi = 1;
((DCI1_10MHz_FDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_10MHz_FDD_t *)&dlsch_pdu)->rv = 0;
...@@ -382,11 +382,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -382,11 +382,11 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
if (eNB->frame_parms.frame_type == FDD) { if (eNB->frame_parms.frame_type == FDD) {
DCI_pdu->dci_alloc[0].dci_length = sizeof_DCI1_20MHz_FDD_t; DCI_pdu->dci_alloc[0].dci_length = sizeof_DCI1_20MHz_FDD_t;
harq_pid_value = ( ((proc->frame_tx * 10) + subframe) % 8 ); harq_pid_value = ( ((proc->frame_tx * 10) + nr_tti_tx) % 8 );
if (!(subframe&1)) // even subframe if (!(nr_tti_tx&1)) // even nr_tti_tx
dci_ndi_toggle_tmp = &(dci_ndi_toggle_even[harq_pid_value]); dci_ndi_toggle_tmp = &(dci_ndi_toggle_even[harq_pid_value]);
else // odd subframe else // odd nr_tti_tx
dci_ndi_toggle_tmp = &(dci_ndi_toggle_odd[harq_pid_value]); dci_ndi_toggle_tmp = &(dci_ndi_toggle_odd[harq_pid_value]);
((DCI1_20MHz_FDD_t *)&dlsch_pdu)->rballoc = 0x1ffffff; //rballoc; //computeRIV(100,10,3); ((DCI1_20MHz_FDD_t *)&dlsch_pdu)->rballoc = 0x1ffffff; //rballoc; //computeRIV(100,10,3);
...@@ -413,7 +413,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -413,7 +413,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1;
//((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[subframe].frame%1024)%28); //((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[nr_tti_tx].frame%1024)%28);
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->ndi = 1; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->ndi = 1;
((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_5MHz_FDD_t *)&dlsch_pdu)->rv = 0;
...@@ -426,10 +426,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -426,10 +426,10 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(100,10,3); ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->rballoc = rballoc; //computeRIV(100,10,3);
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->harq_pid = subframe % 5; ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->harq_pid = nr_tti_tx % 5;
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
//((DCI1_20MHz_TDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->frame%1024)%28); //((DCI1_20MHz_TDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->frame%1024)%28);
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->ndi = subframe / 5; ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->ndi = nr_tti_tx / 5;
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->rv = 0;
((DCI1_20MHz_TDD_t *)&dlsch_pdu)->rah = 0; ((DCI1_20MHz_TDD_t *)&dlsch_pdu)->rah = 0;
memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],(void *)&dlsch_pdu,sizeof(DCI1_20MHz_TDD_t)); memcpy((void*)&DCI_pdu->dci_alloc[0].dci_pdu[0],(void *)&dlsch_pdu,sizeof(DCI1_20MHz_TDD_t));
...@@ -446,7 +446,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -446,7 +446,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI1_20MHz_FDD_t *)&dlsch_pdu)->TPC = 0; ((DCI1_20MHz_FDD_t *)&dlsch_pdu)->TPC = 0;
((DCI1_20MHz_FDD_t *)&dlsch_pdu)->dai = 0; ((DCI1_20MHz_FDD_t *)&dlsch_pdu)->dai = 0;
((DCI1_20MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1; ((DCI1_20MHz_FDD_t *)&dlsch_pdu)->harq_pid = 1;
//((DCI1_20MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[subframe].frame%1024)%28); //((DCI1_20MHz_FDD_t *)&dlsch_pdu)->mcs = (unsigned char) ((eNB->proc[nr_tti_tx].frame%1024)%28);
((DCI1_20MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs; ((DCI1_20MHz_FDD_t *)&dlsch_pdu)->mcs = eNB->target_ue_dl_mcs;
((DCI1_20MHz_FDD_t *)&dlsch_pdu)->ndi = 1; ((DCI1_20MHz_FDD_t *)&dlsch_pdu)->ndi = 1;
((DCI1_20MHz_FDD_t *)&dlsch_pdu)->rv = 0; ((DCI1_20MHz_FDD_t *)&dlsch_pdu)->rv = 0;
...@@ -615,13 +615,13 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -615,13 +615,13 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->tpmi = 0; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->tpmi = 0;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rv1 = 0; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rv1 = 0;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->ndi1 = subframe / 5; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->ndi1 = nr_tti_tx / 5;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->mcs1 = eNB->target_ue_dl_mcs; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->mcs1 = eNB->target_ue_dl_mcs;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rv2 = 0; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rv2 = 0;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->ndi2 = subframe / 5; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->ndi2 = nr_tti_tx / 5;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->mcs2 = eNB->target_ue_dl_mcs; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->mcs2 = eNB->target_ue_dl_mcs;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->tb_swap = 0; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->tb_swap = 0;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->harq_pid = subframe % 5; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->harq_pid = nr_tti_tx % 5;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->TPC = 0; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->TPC = 0;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rballoc = eNB->ue_dl_rb_alloc; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rballoc = eNB->ue_dl_rb_alloc;
((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rah = 0; ((DCI2_5MHz_2A_FDD_t*) (&DCI_pdu->dci_alloc[0].dci_pdu))->rah = 0;
...@@ -638,13 +638,13 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -638,13 +638,13 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
DLSCH_alloc_pdu1E.tpmi = 5; //5=use feedback DLSCH_alloc_pdu1E.tpmi = 5; //5=use feedback
DLSCH_alloc_pdu1E.rv = 0; DLSCH_alloc_pdu1E.rv = 0;
DLSCH_alloc_pdu1E.ndi = subframe / 5; DLSCH_alloc_pdu1E.ndi = nr_tti_tx / 5;
//DLSCH_alloc_pdu1E.mcs = cqi_to_mcs[eNB->UE_stats->DL_cqi[0]]; //DLSCH_alloc_pdu1E.mcs = cqi_to_mcs[eNB->UE_stats->DL_cqi[0]];
//DLSCH_alloc_pdu1E.mcs = (unsigned char) (taus()%28); //DLSCH_alloc_pdu1E.mcs = (unsigned char) (taus()%28);
DLSCH_alloc_pdu1E.mcs = eNB->target_ue_dl_mcs; DLSCH_alloc_pdu1E.mcs = eNB->target_ue_dl_mcs;
//DLSCH_alloc_pdu1E.mcs = (unsigned char) ((eNB->proc[subframe].frame%1024)%28); //DLSCH_alloc_pdu1E.mcs = (unsigned char) ((eNB->proc[nr_tti_tx].frame%1024)%28);
eNB->UE_stats[0].dlsch_mcs1 = DLSCH_alloc_pdu1E.mcs; eNB->UE_stats[0].dlsch_mcs1 = DLSCH_alloc_pdu1E.mcs;
DLSCH_alloc_pdu1E.harq_pid = subframe % 5; DLSCH_alloc_pdu1E.harq_pid = nr_tti_tx % 5;
DLSCH_alloc_pdu1E.dai = 0; DLSCH_alloc_pdu1E.dai = 0;
DLSCH_alloc_pdu1E.TPC = 0; DLSCH_alloc_pdu1E.TPC = 0;
DLSCH_alloc_pdu1E.rballoc = eNB->ue_dl_rb_alloc; DLSCH_alloc_pdu1E.rballoc = eNB->ue_dl_rb_alloc;
...@@ -671,7 +671,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -671,7 +671,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
eNB->UE_stats[1].DL_pmi_single = (eNB->UE_stats[0].DL_pmi_single ^ 0x1555); eNB->UE_stats[1].DL_pmi_single = (eNB->UE_stats[0].DL_pmi_single ^ 0x1555);
} }
break; //subframe switch break; //nr_tti_tx switch
/* /*
case 8: case 8:
...@@ -734,7 +734,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc) ...@@ -734,7 +734,7 @@ void fill_dci(DCI_PDU *DCI_pdu,PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc)
*/ */
} }
void fill_dci_emos(DCI_PDU *DCI_pdu, uint8_t subframe, PHY_VARS_eNB *eNB) void fill_dci_emos(DCI_PDU *DCI_pdu, uint8_t nr_tti_rx, PHY_VARS_eNB *eNB)
{ {
//uint8_t cooperation_flag = eNB->cooperation_flag; //uint8_t cooperation_flag = eNB->cooperation_flag;
...@@ -744,7 +744,7 @@ void fill_dci_emos(DCI_PDU *DCI_pdu, uint8_t subframe, PHY_VARS_eNB *eNB) ...@@ -744,7 +744,7 @@ void fill_dci_emos(DCI_PDU *DCI_pdu, uint8_t subframe, PHY_VARS_eNB *eNB)
//uint32_t rballoc2 = 0x000F; //uint32_t rballoc2 = 0x000F;
/* /*
uint32_t rand = taus(); uint32_t rand = taus();
if ((subframe==8) || (subframe==9) || (subframe==0)) if ((nr_tti_rx==8) || (nr_tti_rx==9) || (nr_tti_rx==0))
rand = (rand%5)+5; rand = (rand%5)+5;
else else
rand = (rand%4)+5; rand = (rand%4)+5;
...@@ -752,7 +752,7 @@ void fill_dci_emos(DCI_PDU *DCI_pdu, uint8_t subframe, PHY_VARS_eNB *eNB) ...@@ -752,7 +752,7 @@ void fill_dci_emos(DCI_PDU *DCI_pdu, uint8_t subframe, PHY_VARS_eNB *eNB)
DCI_pdu->Num_dci = 0; DCI_pdu->Num_dci = 0;
switch (subframe) { switch (nr_tti_rx) {
case 5: case 5:
DCI_pdu->Num_dci = 1; DCI_pdu->Num_dci = 1;
......
...@@ -39,109 +39,109 @@ ...@@ -39,109 +39,109 @@
#endif #endif
void get_Msg3_alloc(LTE_DL_FRAME_PARMS *frame_parms, void get_Msg3_alloc(LTE_DL_FRAME_PARMS *frame_parms,
unsigned char current_subframe, unsigned char current_nr_tti_rx,
unsigned int current_frame, unsigned int current_frame,
unsigned int *frame, unsigned int *frame,
unsigned char *subframe) unsigned char *nr_tti_rx)
{ {
// Fill in other TDD Configuration!!!! // Fill in other TDD Configuration!!!!
if (frame_parms->frame_type == FDD) { if (frame_parms->frame_type == FDD) {
*subframe = current_subframe+6; *nr_tti_rx = current_nr_tti_rx+6;
if (*subframe>9) { if (*nr_tti_rx > ((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME)) {
*subframe = *subframe-10; *nr_tti_rx = *nr_tti_rx-((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME);
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
} else { } else {
*frame=current_frame; *frame=current_frame;
} }
} else { // TDD } else { // TDD
if (frame_parms->tdd_config == 1) { if (frame_parms->tdd_config == 1) {
switch (current_subframe) { switch (current_nr_tti_rx) {
case 0: case 0:
*subframe = 7; *nr_tti_rx = 7;
*frame = current_frame; *frame = current_frame;
break; break;
case 4: case 4:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 5: case 5:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 9: case 9:
*subframe = 7; *nr_tti_rx = 7;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
} }
} else if (frame_parms->tdd_config == 3) { } else if (frame_parms->tdd_config == 3) {
switch (current_subframe) { switch (current_nr_tti_rx) {
case 0: case 0:
case 5: case 5:
case 6: case 6:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 7: case 7:
*subframe = 3; *nr_tti_rx = 3;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 8: case 8:
*subframe = 4; *nr_tti_rx = 4;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 9: case 9:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+2) & 1023; *frame = (current_frame+2) & 1023;
break; break;
} }
} else if (frame_parms->tdd_config == 4) { } else if (frame_parms->tdd_config == 4) {
switch (current_subframe) { switch (current_nr_tti_rx) {
case 0: case 0:
case 4: case 4:
case 5: case 5:
case 6: case 6:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 7: case 7:
*subframe = 3; *nr_tti_rx = 3;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 8: case 8:
case 9: case 9:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+2) & 1023; *frame = (current_frame+2) & 1023;
break; break;
} }
} else if (frame_parms->tdd_config == 5) { } else if (frame_parms->tdd_config == 5) {
switch (current_subframe) { switch (current_nr_tti_rx) {
case 0: case 0:
case 4: case 4:
case 5: case 5:
case 6: case 6:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+1) & 1023; *frame = (current_frame+1) & 1023;
break; break;
case 7: case 7:
case 8: case 8:
case 9: case 9:
*subframe = 2; *nr_tti_rx = 2;
*frame = (current_frame+2) & 1023; *frame = (current_frame+2) & 1023;
break; break;
} }
...@@ -150,17 +150,17 @@ void get_Msg3_alloc(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -150,17 +150,17 @@ void get_Msg3_alloc(LTE_DL_FRAME_PARMS *frame_parms,
} }
void get_Msg3_alloc_ret(LTE_DL_FRAME_PARMS *frame_parms, void get_Msg3_alloc_ret(LTE_DL_FRAME_PARMS *frame_parms,
unsigned char current_subframe, unsigned char current_nr_tti_rx,
unsigned int current_frame, unsigned int current_frame,
unsigned int *frame, unsigned int *frame,
unsigned char *subframe) unsigned char *nr_tti_rx)
{ {
if (frame_parms->frame_type == FDD) { if (frame_parms->frame_type == FDD) {
/* always retransmit in n+8 */ /* always retransmit in n+8 */
*subframe = current_subframe + 8; *nr_tti_rx = current_nr_tti_rx + 8;
if (*subframe > 9) { if (*nr_tti_rx > ((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME)) {
*subframe = *subframe - 10; *nr_tti_rx = *nr_tti_rx-((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME);
*frame = (current_frame + 1) & 1023; *frame = (current_frame + 1) & 1023;
} else { } else {
*frame = current_frame; *frame = current_frame;
...@@ -190,28 +190,28 @@ void get_Msg3_alloc_ret(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -190,28 +190,28 @@ void get_Msg3_alloc_ret(LTE_DL_FRAME_PARMS *frame_parms,
uint8_t get_Msg3_harq_pid(LTE_DL_FRAME_PARMS *frame_parms, uint8_t get_Msg3_harq_pid(LTE_DL_FRAME_PARMS *frame_parms,
uint32_t frame, uint32_t frame,
unsigned char current_subframe) unsigned char current_nr_tti_rx)
{ {
uint8_t ul_subframe=0; uint8_t ul_nr_tti_rx=0;
uint32_t ul_frame=0; uint32_t ul_frame=0;
if (frame_parms->frame_type ==FDD) { if (frame_parms->frame_type ==FDD) {
ul_subframe = (current_subframe>3) ? (current_subframe-4) : (current_subframe+6); ul_nr_tti_rx = ((current_nr_tti_rx>((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME)-6)) ? (current_nr_tti_rx-4) : (current_nr_tti_rx+6);
ul_frame = (current_subframe>3) ? ((frame+1)&1023) : frame; ul_frame = ((current_nr_tti_rx>((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME)-6)) ? ((frame+1)&1023) : frame;
} else { } else {
switch (frame_parms->tdd_config) { switch (frame_parms->tdd_config) {
case 1: case 1:
switch (current_subframe) { switch (current_nr_tti_rx) {
case 9: case 9:
case 0: case 0:
ul_subframe = 7; ul_nr_tti_rx = 7;
break; break;
case 5: case 5:
case 7: case 7:
ul_subframe = 2; ul_nr_tti_rx = 2;
break; break;
} }
...@@ -219,49 +219,49 @@ uint8_t get_Msg3_harq_pid(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -219,49 +219,49 @@ uint8_t get_Msg3_harq_pid(LTE_DL_FRAME_PARMS *frame_parms,
break; break;
case 3: case 3:
switch (current_subframe) { switch (current_nr_tti_rx) {
case 0: case 0:
case 5: case 5:
case 6: case 6:
ul_subframe = 2; ul_nr_tti_rx = 2;
break; break;
case 7: case 7:
ul_subframe = 3; ul_nr_tti_rx = 3;
break; break;
case 8: case 8:
ul_subframe = 4; ul_nr_tti_rx = 4;
break; break;
case 9: case 9:
ul_subframe = 2; ul_nr_tti_rx = 2;
break; break;
} }
break; break;
case 4: case 4:
switch (current_subframe) { switch (current_nr_tti_rx) {
case 0: case 0:
case 5: case 5:
case 6: case 6:
case 8: case 8:
case 9: case 9:
ul_subframe = 2; ul_nr_tti_rx = 2;
break; break;
case 7: case 7:
ul_subframe = 3; ul_nr_tti_rx = 3;
break; break;
} }
break; break;
case 5: case 5:
ul_subframe =2; ul_nr_tti_rx =2;
break; break;
default: default:
...@@ -271,65 +271,65 @@ uint8_t get_Msg3_harq_pid(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -271,65 +271,65 @@ uint8_t get_Msg3_harq_pid(LTE_DL_FRAME_PARMS *frame_parms,
} }
} }
return(subframe2harq_pid(frame_parms,ul_frame,ul_subframe)); return(subframe2harq_pid(frame_parms,ul_frame,ul_nr_tti_rx));
} }
unsigned char ul_ACK_subframe2_dl_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsigned char subframe,unsigned char ACK_index) unsigned char ul_ACK_subframe2_dl_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsigned char nr_tti_rx,unsigned char ACK_index)
{ {
if (frame_parms->frame_type == FDD) { if (frame_parms->frame_type == FDD) {
return((subframe<4) ? subframe+6 : subframe-4); return(nr_tti_rx<(((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME)-6) ? nr_tti_rx+6 : nr_tti_rx-4);
} else { } else {
switch (frame_parms->tdd_config) { switch (frame_parms->tdd_config) {
case 3: case 3:
if (subframe == 2) { // ACK subframes 5 and 6 if (nr_tti_rx == 2) { // ACK nr_tti_rx 5 and 6
if (ACK_index==2) if (ACK_index==2)
return(1); return(1);
return(5+ACK_index); return(5+ACK_index);
} else if (subframe == 3) { // ACK subframes 7 and 8 } else if (nr_tti_rx == 3) { // ACK nr_tti_rx 7 and 8
return(7+ACK_index); // To be updated return(7+ACK_index); // To be updated
} else if (subframe == 4) { // ACK subframes 9 and 0 } else if (nr_tti_rx == 4) { // ACK nr_tti_rx 9 and 0
return((9+ACK_index)%10); return((9+ACK_index)%10);
} else { } else {
LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal subframe %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal nr_tti_rx %d for tdd_config %d\n",
subframe,frame_parms->tdd_config); nr_tti_rx,frame_parms->tdd_config);
return(0); return(0);
} }
break; break;
case 4: case 4:
if (subframe == 2) { // ACK subframes 0, 4 and 5 if (nr_tti_rx == 2) { // ACK nr_tti_rx 0, 4 and 5
//if (ACK_index==2) //if (ACK_index==2)
// return(1); TBC // return(1); TBC
if (ACK_index==2) if (ACK_index==2)
return(0); return(0);
return(4+ACK_index); return(4+ACK_index);
} else if (subframe == 3) { // ACK subframes 6, 7 8 and 9 } else if (nr_tti_rx == 3) { // ACK subframes 6, 7 8 and 9
return(6+ACK_index); // To be updated return(6+ACK_index); // To be updated
} else { } else {
LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal subframe %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal nr_tti_rx %d for tdd_config %d\n",
subframe,frame_parms->tdd_config); nr_tti_rx,frame_parms->tdd_config);
return(0); return(0);
} }
break; break;
case 1: case 1:
if (subframe == 2) { // ACK subframes 5 and 6 if (nr_tti_rx == 2) { // ACK nr_tti_rx 5 and 6
return(5+ACK_index); return(5+ACK_index);
} else if (subframe == 3) { // ACK subframe 9 } else if (nr_tti_rx == 3) { // ACK nr_tti_rx 9
return(9); // To be updated return(9); // To be updated
} else if (subframe == 7) { // ACK subframes 0 and 1 } else if (nr_tti_rx == 7) { // ACK nr_tti_rx 0 and 1
return(ACK_index); // To be updated return(ACK_index); // To be updated
} else if (subframe == 8) { // ACK subframe 4 } else if (nr_tti_rx == 8) { // ACK nr_tti_rx 4
return(4); // To be updated return(4); // To be updated
} else { } else {
LOG_E(PHY,"phy_procedures_lte_common.c/ul_ACK_subframe2_dl_subframe: illegal subframe %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte_common.c/ul_ACK_subframe2_dl_subframe: illegal nr_tti_rx %d for tdd_config %d\n",
subframe,frame_parms->tdd_config); nr_tti_rx,frame_parms->tdd_config);
return(0); return(0);
} }
...@@ -340,7 +340,7 @@ unsigned char ul_ACK_subframe2_dl_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsig ...@@ -340,7 +340,7 @@ unsigned char ul_ACK_subframe2_dl_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsig
return(0); return(0);
} }
unsigned char ul_ACK_subframe2_M(LTE_DL_FRAME_PARMS *frame_parms,unsigned char subframe) unsigned char ul_ACK_subframe2_M(LTE_DL_FRAME_PARMS *frame_parms,unsigned char nr_tti_rx)
{ {
if (frame_parms->frame_type == FDD) { if (frame_parms->frame_type == FDD) {
...@@ -348,56 +348,56 @@ unsigned char ul_ACK_subframe2_M(LTE_DL_FRAME_PARMS *frame_parms,unsigned char s ...@@ -348,56 +348,56 @@ unsigned char ul_ACK_subframe2_M(LTE_DL_FRAME_PARMS *frame_parms,unsigned char s
} else { } else {
switch (frame_parms->tdd_config) { switch (frame_parms->tdd_config) {
case 3: case 3:
if (subframe == 2) { // ACK subframes 5 and 6 if (nr_tti_rx == 2) { // ACK subframes 5 and 6
return(2); // should be 3 return(2); // should be 3
} else if (subframe == 3) { // ACK subframes 7 and 8 } else if (nr_tti_rx == 3) { // ACK subframes 7 and 8
return(2); // To be updated return(2); // To be updated
} else if (subframe == 4) { // ACK subframes 9 and 0 } else if (nr_tti_rx == 4) { // ACK subframes 9 and 0
return(2); return(2);
} else { } else {
LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal subframe %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal nr_tti_rx %d for tdd_config %d\n",
subframe,frame_parms->tdd_config); nr_tti_rx,frame_parms->tdd_config);
return(0); return(0);
} }
break; break;
case 4: case 4:
if (subframe == 2) { // ACK subframes 0,4 and 5 if (nr_tti_rx == 2) { // ACK subframes 0,4 and 5
return(3); // should be 4 return(3); // should be 4
} else if (subframe == 3) { // ACK subframes 6,7,8 and 9 } else if (nr_tti_rx == 3) { // ACK subframes 6,7,8 and 9
return(4); return(4);
} else { } else {
LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal subframe %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal nr_tti_rx %d for tdd_config %d\n",
subframe,frame_parms->tdd_config); nr_tti_rx,frame_parms->tdd_config);
return(0); return(0);
} }
break; break;
case 5: case 5:
if (subframe == 2) { // ACK subframes 0,3,4,5,6,7,8 and 9 if (nr_tti_rx == 2) { // ACK subframes 0,3,4,5,6,7,8 and 9
return(8); // should be 3 return(8); // should be 3
} else { } else {
LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal subframe %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal nr_tti_rx %d for tdd_config %d\n",
subframe,frame_parms->tdd_config); nr_tti_rx,frame_parms->tdd_config);
return(0); return(0);
} }
break; break;
case 1: case 1:
if (subframe == 2) { // ACK subframes 5 and 6 if (nr_tti_rx == 2) { // ACK subframes 5 and 6
return(2); return(2);
} else if (subframe == 3) { // ACK subframe 9 } else if (nr_tti_rx == 3) { // ACK nr_tti_rx 9
return(1); // To be updated return(1); // To be updated
} else if (subframe == 7) { // ACK subframes 0 and 1 } else if (nr_tti_rx == 7) { // ACK nr_tti_rx 0 and 1
return(2); // To be updated return(2); // To be updated
} else if (subframe == 8) { // ACK subframe 4 } else if (nr_tti_rx == 8) { // ACK nr_tti_rx 4
return(1); // To be updated return(1); // To be updated
} else { } else {
LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal subframe %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte_common.c/subframe2_dl_harq_pid: illegal nr_tti_rx %d for tdd_config %d\n",
subframe,frame_parms->tdd_config); nr_tti_rx,frame_parms->tdd_config);
return(0); return(0);
} }
...@@ -412,34 +412,35 @@ unsigned char ul_ACK_subframe2_M(LTE_DL_FRAME_PARMS *frame_parms,unsigned char s ...@@ -412,34 +412,35 @@ unsigned char ul_ACK_subframe2_M(LTE_DL_FRAME_PARMS *frame_parms,unsigned char s
// return the number 'Nbundled' // return the number 'Nbundled'
uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms, uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms,
harq_status_t *harq_ack, harq_status_t *harq_ack,
unsigned char subframe_tx, unsigned char nr_tti_tx,
unsigned char subframe_rx, unsigned char nr_tti_rx,
unsigned char *o_ACK, unsigned char *o_ACK,
uint8_t *pN_bundled, uint8_t *pN_bundled,
uint8_t cw_idx, uint8_t cw_idx,
uint8_t do_reset) // 1 to reset ACK/NACK status : 0 otherwise uint8_t do_reset) // 1 to reset ACK/NACK status : 0 otherwise
{ {
uint8_t status=0; uint8_t status=0;
uint8_t subframe_ul=0xff, subframe_dl0=0xff, subframe_dl1=0xff,subframe_dl2=0xff, subframe_dl3=0xff; //uint8_t nr_tti_ul=0xff, nr_tti_dl0=0xff, nr_tti_dl1=0xff,nr_tti_dl2=0xff;// nr_tti_dl3=0xff;
uint8_t nr_tti_dl0=0xff;
// printf("get_ack: SF %d\n",subframe); // printf("get_ack: SF %d\n",nr_tti_rx);
if (frame_parms->frame_type == FDD) { if (frame_parms->frame_type == FDD) {
if (subframe_tx < 4) if (nr_tti_tx < 4)
subframe_dl0 = subframe_tx + 6; nr_tti_dl0 = nr_tti_tx + ((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME) - 4;
else else
subframe_dl0 = subframe_tx - 4; nr_tti_dl0 = nr_tti_tx - 4;
o_ACK[cw_idx] = harq_ack[subframe_dl0].ack; o_ACK[cw_idx] = harq_ack[nr_tti_dl0].ack;
status = harq_ack[subframe_dl0].send_harq_status; status = harq_ack[nr_tti_dl0].send_harq_status;
//LOG_I(PHY,"dl subframe %d send_harq_status %d cw_idx %d, reset %d\n",subframe_dl0, status, cw_idx, do_reset); //LOG_I(PHY,"dl nr_tti_rx %d send_harq_status %d cw_idx %d, reset %d\n",nr_tti_rx_dl0, status, cw_idx, do_reset);
if(do_reset) if(do_reset)
harq_ack[subframe_dl0].send_harq_status = 0; harq_ack[nr_tti_dl0].send_harq_status = 0;
//printf("get_ack: Getting ACK/NAK for PDSCH (subframe %d) => %d\n",subframe_dl,o_ACK[0]); //printf("get_ack: Getting ACK/NAK for PDSCH (nr_tti_rx %d) => %d\n",nr_tti_rx_dl,o_ACK[0]);
} else { } else {
/*
switch (frame_parms->tdd_config) { switch (frame_parms->tdd_config) {
case 1: case 1:
if (subframe_tx == 2) { // ACK subframes 5,6 if (nr_tti_tx == 2) { // ACK nr_tti_rx 5,6
subframe_ul = 6; subframe_ul = 6;
subframe_dl0 = 5; subframe_dl0 = 5;
subframe_dl1 = 6; subframe_dl1 = 6;
...@@ -535,13 +536,13 @@ uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -535,13 +536,13 @@ uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms,
subframe_dl0 = 7; subframe_dl0 = 7;
subframe_dl1 = 8; subframe_dl1 = 8;
subframe_ul = 3; subframe_ul = 3;
//printf("Subframe 3, TDD config 3: harq_ack[7] = %d,harq_ack[8] = %d\n",harq_ack[7].ack,harq_ack[8].ack); //printf("nr_tti_rx 3, TDD config 3: harq_ack[7] = %d,harq_ack[8] = %d\n",harq_ack[7].ack,harq_ack[8].ack);
//printf("status %d : o_ACK (%d,%d)\n", status,o_ACK[0],o_ACK[1]); //printf("status %d : o_ACK (%d,%d)\n", status,o_ACK[0],o_ACK[1]);
} else if (subframe_tx == 4) { // ACK subframes 9 and 0 } else if (subframe_tx == 4) { // ACK nr_tti_rxs 9 and 0
subframe_dl0 = 9; subframe_dl0 = 9;
subframe_dl1 = 0; subframe_dl1 = 0;
subframe_ul = 4; subframe_ul = 4;
//printf("Subframe 4, TDD config 3: harq_ack[9] = %d,harq_ack[0] = %d\n",harq_ack[9].ack,harq_ack[0].ack); //printf("nr_tti_rx 4, TDD config 3: harq_ack[9] = %d,harq_ack[0] = %d\n",harq_ack[9].ack,harq_ack[0].ack);
} else { } else {
LOG_E(PHY,"phy_procedures_lte.c: get_ack, illegal subframe_tx %d for tdd_config %d\n", LOG_E(PHY,"phy_procedures_lte.c: get_ack, illegal subframe_tx %d for tdd_config %d\n",
subframe_tx,frame_parms->tdd_config); subframe_tx,frame_parms->tdd_config);
...@@ -632,6 +633,7 @@ uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -632,6 +633,7 @@ uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms,
break; break;
} }
*/
} }
//printf("status %d\n",status); //printf("status %d\n",status);
...@@ -641,24 +643,24 @@ uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms, ...@@ -641,24 +643,24 @@ uint8_t get_reset_ack(LTE_DL_FRAME_PARMS *frame_parms,
uint8_t get_ack(LTE_DL_FRAME_PARMS *frame_parms, uint8_t get_ack(LTE_DL_FRAME_PARMS *frame_parms,
harq_status_t *harq_ack, harq_status_t *harq_ack,
unsigned char subframe_tx, unsigned char nr_tti_tx,
unsigned char subframe_rx, unsigned char nr_tti_rx,
unsigned char *o_ACK, unsigned char *o_ACK,
uint8_t cw_idx) uint8_t cw_idx)
{ {
uint8_t N_bundled = 0; uint8_t N_bundled = 0;
return get_reset_ack(frame_parms, harq_ack, subframe_tx, subframe_rx, o_ACK, &N_bundled, cw_idx, 0); return get_reset_ack(frame_parms, harq_ack, nr_tti_tx, nr_tti_rx, o_ACK, &N_bundled, cw_idx, 0);
} }
uint8_t reset_ack(LTE_DL_FRAME_PARMS *frame_parms, uint8_t reset_ack(LTE_DL_FRAME_PARMS *frame_parms,
harq_status_t *harq_ack, harq_status_t *harq_ack,
unsigned char subframe_tx, unsigned char nr_tti_tx,
unsigned char subframe_rx, unsigned char nr_tti_rx,
unsigned char *o_ACK, unsigned char *o_ACK,
uint8_t *pN_bundled, uint8_t *pN_bundled,
uint8_t cw_idx) uint8_t cw_idx)
{ {
return get_reset_ack(frame_parms, harq_ack, subframe_tx, subframe_rx, o_ACK, pN_bundled, cw_idx, 1); return get_reset_ack(frame_parms, harq_ack, nr_tti_tx, nr_tti_rx, o_ACK, pN_bundled, cw_idx, 1);
} }
...@@ -713,17 +715,18 @@ uint16_t get_Np(uint8_t N_RB_DL,uint8_t nCCE,uint8_t plus1) ...@@ -713,17 +715,18 @@ uint16_t get_Np(uint8_t N_RB_DL,uint8_t nCCE,uint8_t plus1)
return(Np[0+plus1]); return(Np[0+plus1]);
} }
lte_subframe_t subframe_select(LTE_DL_FRAME_PARMS *frame_parms,unsigned char subframe) lte_subframe_t subframe_select(LTE_DL_FRAME_PARMS *frame_parms,unsigned char nr_tti)
{ {
// if FDD return dummy value // if FDD return dummy value
if (frame_parms->frame_type == FDD) if (frame_parms->frame_type == FDD)
return(SF_DL); return(SF_DL);
/*
switch (frame_parms->tdd_config) { switch (frame_parms->tdd_config) {
case 1: case 1:
switch (subframe) { switch (nr_tti) {
case 0: case 0:
case 4: case 4:
case 5: case 5:
...@@ -786,9 +789,13 @@ lte_subframe_t subframe_select(LTE_DL_FRAME_PARMS *frame_parms,unsigned char sub ...@@ -786,9 +789,13 @@ lte_subframe_t subframe_select(LTE_DL_FRAME_PARMS *frame_parms,unsigned char sub
return(255); return(255);
} }
*/
return(255);
} }
dci_detect_mode_t dci_detect_mode_select(LTE_DL_FRAME_PARMS *frame_parms,uint8_t subframe) dci_detect_mode_t dci_detect_mode_select(LTE_DL_FRAME_PARMS *frame_parms,uint8_t nr_tti)
{ {
dci_detect_mode_t ret = 0; dci_detect_mode_t ret = 0;
...@@ -803,41 +810,42 @@ dci_detect_mode_t dci_detect_mode_select(LTE_DL_FRAME_PARMS *frame_parms,uint8_t ...@@ -803,41 +810,42 @@ dci_detect_mode_t dci_detect_mode_select(LTE_DL_FRAME_PARMS *frame_parms,uint8_t
{UL_DL_DCI, UL_DL_DCI , NO_DCI , NO_DCI , NO_DCI , UL_DL_DCI , UL_DL_DCI , NO_DCI, NO_DCI , UL_DL_DCI }}; // tdd6 {UL_DL_DCI, UL_DL_DCI , NO_DCI , NO_DCI , NO_DCI , UL_DL_DCI , UL_DL_DCI , NO_DCI, NO_DCI , UL_DL_DCI }}; // tdd6
DevAssert(subframe>=0 && subframe<=9); DevAssert(nr_tti>=0 && nr_tti<=(((frame_parms->ttis_per_subframe)*LTE_NUMBER_OF_SUBFRAMES_PER_FRAME)-1));
DevAssert((frame_parms->tdd_config)>=0 && (frame_parms->tdd_config)<=6); DevAssert((frame_parms->tdd_config)>=0 && (frame_parms->tdd_config)<=6);
if (frame_parms->frame_type == FDD) { if (frame_parms->frame_type == FDD) {
ret = UL_DL_DCI; ret = UL_DL_DCI;
} else { } else {
ret = Table_8_2_3gpp_36_213[frame_parms->tdd_config][subframe]; ret = Table_8_2_3gpp_36_213[frame_parms->tdd_config][nr_tti];
} }
LOG_D(PHY, "subframe %d: detect UL_DCI=%d, detect DL_DCI=%d\n", subframe, (ret & UL_DCI)>0, (ret & DL_DCI)>0); LOG_D(PHY, "nr_tti %d: detect UL_DCI=%d, detect DL_DCI=%d\n", nr_tti, (ret & UL_DCI)>0, (ret & DL_DCI)>0);
return ret; return ret;
} }
lte_subframe_t get_subframe_direction(uint8_t Mod_id,uint8_t CC_id,uint8_t subframe) lte_subframe_t get_subframe_direction(uint8_t Mod_id,uint8_t CC_id,uint8_t nr_tti)
{ {
return(subframe_select(&PHY_vars_eNB_g[Mod_id][CC_id]->frame_parms,subframe)); return(subframe_select(&PHY_vars_eNB_g[Mod_id][CC_id]->frame_parms,nr_tti));
} }
uint8_t phich_subframe_to_harq_pid(LTE_DL_FRAME_PARMS *frame_parms,uint32_t frame,uint8_t subframe) uint8_t phich_subframe_to_harq_pid(LTE_DL_FRAME_PARMS *frame_parms,uint32_t frame,uint8_t nr_tti)
{ {
//LOG_D(PHY,"phich_subframe_to_harq_pid.c: frame %d, subframe %d\n",frame,subframe); //LOG_D(PHY,"phich_subframe_to_harq_pid.c: frame %d, nr_tti %d\n",frame,nr_tti);
return(subframe2harq_pid(frame_parms, return(subframe2harq_pid(frame_parms,
phich_frame2_pusch_frame(frame_parms,frame,subframe), phich_frame2_pusch_frame(frame_parms,frame,nr_tti),
phich_subframe2_pusch_subframe(frame_parms,subframe))); phich_subframe2_pusch_subframe(frame_parms,nr_tti)));
} }
unsigned int is_phich_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsigned char subframe) unsigned int is_phich_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsigned char nr_tti)
{ {
if (frame_parms->frame_type == FDD) { if (frame_parms->frame_type == FDD) {
return(1); return(1);
} else { } else {
/*
switch (frame_parms->tdd_config) { switch (frame_parms->tdd_config) {
case 1: case 1:
if ((subframe == 1) || (subframe == 4) || (subframe == 6) || (subframe == 9)) if ((subframe == 1) || (subframe == 4) || (subframe == 6) || (subframe == 9))
...@@ -867,6 +875,7 @@ unsigned int is_phich_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsigned char sub ...@@ -867,6 +875,7 @@ unsigned int is_phich_subframe(LTE_DL_FRAME_PARMS *frame_parms,unsigned char sub
return(0); return(0);
break; break;
} }
*/
} }
return(0); return(0);
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
#include "PHY/LTE_TRANSPORT/proto.h" #include "PHY/LTE_TRANSPORT/proto.h"
#include "PHY/extern.h" #include "PHY/extern.h"
int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t subframe,uint8_t eNB_id,PUCCH_FMT_t pucch_fmt) int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t nr_tti_rx,uint8_t eNB_id,PUCCH_FMT_t pucch_fmt)
{ {
int16_t Po_PUCCH; int16_t Po_PUCCH;
...@@ -45,7 +45,7 @@ int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t subframe,u ...@@ -45,7 +45,7 @@ int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t subframe,u
// //
//if ((pucch_fmt == pucch_format1a) || //if ((pucch_fmt == pucch_format1a) ||
// (pucch_fmt == pucch_format1b)) { // Update g_pucch based on TPC/delta_PUCCH received in PDCCH for this process // (pucch_fmt == pucch_format1b)) { // Update g_pucch based on TPC/delta_PUCCH received in PDCCH for this process
//harq_pid = ue->dlsch[eNB_id][0]->harq_ack[subframe].harq_id; //harq_pid = ue->dlsch[eNB_id][0]->harq_ack[nr_tti_rx].harq_id;
//this is now done in dci_tools //this is now done in dci_tools
//ue->g_pucch[eNB_id] += ue->dlsch[eNB_id][0]->harq_processes[harq_pid]->delta_PUCCH; //ue->g_pucch[eNB_id] += ue->dlsch[eNB_id][0]->harq_processes[harq_pid]->delta_PUCCH;
//} //}
...@@ -95,7 +95,7 @@ int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t subframe,u ...@@ -95,7 +95,7 @@ int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t subframe,u
if (pucch_fmt!=pucch_format1) { if (pucch_fmt!=pucch_format1) {
LOG_D(PHY,"[UE %d][PDSCH %x] AbsSubframe %d.%d: Po_PUCCH %d dBm : Po_NOMINAL_PUCCH %d dBm, PL %d dB, g_pucch %d dB\n", LOG_D(PHY,"[UE %d][PDSCH %x] AbsSubframe %d.%d: Po_PUCCH %d dBm : Po_NOMINAL_PUCCH %d dBm, PL %d dB, g_pucch %d dB\n",
ue->Mod_id, ue->Mod_id,
ue->dlsch[ue->current_thread_id[proc->subframe_rx]][eNB_id][0]->rnti,proc->frame_tx%1024,subframe, ue->dlsch[ue->current_thread_id[proc->subframe_rx]][eNB_id][0]->rnti,proc->frame_tx%1024,nr_tti_rx,
Po_PUCCH, Po_PUCCH,
ue->frame_parms.ul_power_control_config_common.p0_NominalPUCCH, ue->frame_parms.ul_power_control_config_common.p0_NominalPUCCH,
get_PL(ue->Mod_id,ue->CC_id,eNB_id), get_PL(ue->Mod_id,ue->CC_id,eNB_id),
...@@ -103,7 +103,7 @@ int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t subframe,u ...@@ -103,7 +103,7 @@ int16_t pucch_power_cntl(PHY_VARS_UE *ue,UE_rxtx_proc_t *proc,uint8_t subframe,u
} else { } else {
LOG_D(PHY,"[UE %d][SR %x] AbsSubframe %d.%d: Po_PUCCH %d dBm : Po_NOMINAL_PUCCH %d dBm, PL %d dB g_pucch %d dB\n", LOG_D(PHY,"[UE %d][SR %x] AbsSubframe %d.%d: Po_PUCCH %d dBm : Po_NOMINAL_PUCCH %d dBm, PL %d dB g_pucch %d dB\n",
ue->Mod_id, ue->Mod_id,
ue->dlsch[ue->current_thread_id[proc->subframe_rx]][eNB_id][0]->rnti,proc->frame_tx%1024,subframe, ue->dlsch[ue->current_thread_id[proc->subframe_rx]][eNB_id][0]->rnti,proc->frame_tx%1024,nr_tti_rx,
Po_PUCCH, Po_PUCCH,
ue->frame_parms.ul_power_control_config_common.p0_NominalPUCCH, ue->frame_parms.ul_power_control_config_common.p0_NominalPUCCH,
get_PL(ue->Mod_id,ue->CC_id,eNB_id), get_PL(ue->Mod_id,ue->CC_id,eNB_id),
......
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