// lnormal is the OFDM symbol number in the PUCCH transmission where l=0 corresponds to the first OFDM symbol of the PUCCH transmission
//uint8_t lnormal = 0 ;
// 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]
uint8_tlprime=startingSymbolIndex;
// mcs = 0 except for PUCCH format 0
uint8_tmcs=0;
// r_u_v_alpha_delta_re and r_u_v_alpha_delta_im tables containing the sequence y(n) for the PUCCH, when they are multiplied by d(0)
// r_u_v_alpha_delta_dmrs_re and r_u_v_alpha_delta_dmrs_im tables containing the sequence for the DM-RS.
// the orthogonal sequence index for wi(m) defined in TS 38.213 Subclause 9.2.1
// the index of the orthogonal cover code is from a set determined as described in [4, TS 38.211]
// and is indicated by higher layer parameter PUCCH-F1-time-domain-OCC
// In the PUCCH_Config IE, the PUCCH-format1, timeDomainOCC field
uint8_tw_index=timeDomainOCC;
// N_SF_mprime_PUCCH_1 contains N_SF_mprime from table 6.3.2.4.1-1 (depending on number of PUCCH symbols nrofSymbols, mprime and intra-slot hopping enabled/disabled)
uint8_tN_SF_mprime_PUCCH_1;
// N_SF_mprime_PUCCH_1 contains N_SF_mprime from table 6.4.1.3.1.1-1 (depending on number of PUCCH symbols nrofSymbols, mprime and intra-slot hopping enabled/disabled)
uint8_tN_SF_mprime_PUCCH_DMRS_1;
// N_SF_mprime_PUCCH_1 contains N_SF_mprime from table 6.3.2.4.1-1 (depending on number of PUCCH symbols nrofSymbols, mprime=0 and intra-slot hopping enabled/disabled)
uint8_tN_SF_mprime0_PUCCH_1;
// N_SF_mprime_PUCCH_1 contains N_SF_mprime from table 6.4.1.3.1.1-1 (depending on number of PUCCH symbols nrofSymbols, mprime=0 and intra-slot hopping enabled/disabled)
uint8_tN_SF_mprime0_PUCCH_DMRS_1;
// mprime is 0 if no intra-slot hopping / mprime is {0,1} if intra-slot hopping
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_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
uint8_ttimeDomainOCC=0;
SCM_tchannel_model=AWGN;//Rayleigh1_anticorr;
intN_RB_DL=273,mu=1;
unsignedcharframe_type=0;
unsignedcharpbch_phase=0;
intframe=0,subframe=0;
floattarget_error_rate=0.01;
intframe_length_complex_samples;
intframe_length_complex_samples_no_prefix;
NR_DL_FRAME_PARMS*frame_parms;
nfapi_nr_config_request_t*gNB_config;
unsignedcharframe_type=0;
intloglvl=OAILOG_WARNING;
cpuf=get_cpu_freq_GHz();
...
...
@@ -142,7 +134,7 @@ int main(int argc, char **argv)
@@ -456,63 +443,89 @@ int main(int argc, char **argv)
printf("Error at UE NR initialisation\n");
exit(-1);
}
int16_tamp=0x1FFF;
intnr_tti_tx=0;//According to standards it is Slot number within a frame for subcarrier spacing configuration μ but not sure why he made the variable name so 4.3.2,38.211
nr_gold_pbch(UE);
// generate signal
// pucch_config_common_nr should assign values for this if not done before structure in ue being used by functions
uint8_tactual_payload=0,payload_received;//payload bits b7b6...b2b1b0 where b7..b3=0 b2b1=HARQ b0 is SR. payload maximum value is 7