* - m0: provided by higher layer parameter PUCCH-F0-F1-initial-cyclic-shift of PUCCH-F0-resource-config
* - mcs: mcs=0 except for PUCCH format 0 when it depends on information to be transmitted according to TS 38.213 subclause 9.2
* - lnormal: lnormal is the OFDM symbol number in the PUCCH transmission where l=0 corresponds to the first OFDM symbol of the PUCCH transmission
* - lprime: lprime is the index of the OFDM symbol in the slot that corresponds to the first OFDM symbol of the PUCCH transmission in the slot given by [5, TS 38.213]
*/
// alpha_init initialized to 2*PI/12=0.5235987756
doublealpha=0.5235987756;
uint32_tc_init=n_id;// we initialize c_init again to calculate n_cs
@@ -87,12 +87,13 @@ int main(int argc, char **argv)
...
@@ -87,12 +87,13 @@ int main(int argc, char **argv)
uint8_tnacktoack_flag=0;
uint8_tnacktoack_flag=0;
int16_tamp=0x7FFF;
int16_tamp=0x7FFF;
intnr_tti_tx=0;
intnr_tti_tx=0;
uint64_tactual_payload=0,payload_received;//payload bits b7b6...b2b1b0 where b7..b3=0 b2b1=HARQ b0 is SR. payload maximum value is 7 for pucch format 0
uint8_tnrofSymbols=1;//number of OFDM symbols can be 1-2 for format 1
uint8_tnrofSymbols=1;//number of OFDM symbols can be 1-2 for format 1
uint8_tstartingSymbolIndex=0;// resource allocated see 9.2.1, 38.213 for more info.should be actually present in the resource set provided
uint8_tstartingSymbolIndex=0;// resource allocated see 9.2.1, 38.213 for more info.should be actually present in the resource set provided
uint16_tstartingPRB=0,startingPRB_intraSlotHopping=0;//PRB number not sure see 9.2.1, 38.213 for more info. Should be actually present in the resource set provided
uint16_tstartingPRB=0,startingPRB_intraSlotHopping=0;//PRB number not sure see 9.2.1, 38.213 for more info. Should be actually present in the resource set provided
uint32_thoppingId=40;
uint8_ttimeDomainOCC=0;
uint8_ttimeDomainOCC=0;
SCM_tchannel_model=AWGN;//Rayleigh1_anticorr;
SCM_tchannel_model=AWGN;//Rayleigh1_anticorr;
...
@@ -114,7 +115,7 @@ int main(int argc, char **argv)
...
@@ -114,7 +115,7 @@ int main(int argc, char **argv)
dlsch_in_slot_bitmap=&RC.nrmac[module_idP]->UE_list.UE_sched_ctrl[UE_id].dlsch_in_slot_bitmap;// static bitmap signaling which slot in a tdd period contains dlsch
ulsch_in_slot_bitmap=&RC.nrmac[module_idP]->UE_list.UE_sched_ctrl[UE_id].ulsch_in_slot_bitmap;// static bitmap signaling which slot in a tdd period contains ulsch
// hardcoding dlsch to be in slot 1
if(!(slot_txP%num_slots_per_tdd)){
if(slot_txP==0)
*dlsch_in_slot_bitmap=0x02;
else
*dlsch_in_slot_bitmap=0x00;
}
// hardcoding ulsch to be in slot 8
if(!(slot_rxP%num_slots_per_tdd)){
if(slot_rxP==0)
*ulsch_in_slot_bitmap=0x100;
else
*ulsch_in_slot_bitmap=0x00;
}
}
// Check if there are downlink symbols in the slot,
// Check if there are downlink symbols in the slot,