// to be check the fields needed to L1 with NR_DL_UE_HARQ_t and NR_UE_DLSCH_t
// PTRS [TS38.214, sec 5.1.6.3]
/// PT-RS antenna ports [TS38.214, sec 5.1.6.3] [TS38.211, table 7.4.1.2.2-1] Bitmap occupying the 6 LSBs with: bit 0: antenna port 1000 bit 5: antenna port 1005 and for each bit 0: PTRS port not used 1: PTRS port used
uint8_tPTRSPortIndex;
/// PT-RS time density [TS38.214, table 5.1.6.3-1] 0: 1 1: 2 2: 4
uint8_tPTRSTimeDensity;
/// PT-RS frequency density [TS38.214, table 5.1.6.3-2] 0: 2 1: 4
uint8_tPTRSFreqDensity;
/// PT-RS resource element offset [TS38.211, table 7.4.1.2.2-1] Value: 0->3
uint8_tPTRSReOffset;
/// PT-RS-to-PDSCH EPRE ratio [TS38.214, table 4.1-2] Value :0->3
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[
int32_t**dl_ch_estimates_ext;
/// \brief Downlink channel estimates extracted in PRBS.
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[
int32_t**dl_ch_ptrs_estimates_ext;
/// \brief Downlink cross-correlation of MIMO channel estimates (unquantized PMI) extracted in PRBS. For the SIC receiver we need to store the history of this for each harq process and round
/// - first index: ? [0..7] (hard coded) accessed via \c harq_pid
/// - second index: ? [0..7] (hard coded) accessed via \c round
...
...
@@ -414,6 +418,16 @@ typedef struct {
uint32_tllr_offset[14];
// llr length per ofdm symbol
uint32_tllr_length[14];
// llr offset per ofdm symbol
uint32_tdl_valid_re[14];
/// \brief Estimated phase error based upon PTRS on each symbol .
/// - first index: ? [0..7] Number of Antenna
/// - second index: ? [0...14] smybol per slot
int32_t**ptrs_phase_per_slot;
/// \brief Estimated phase error based upon PTRS on each symbol .
@@ -1006,8 +1004,8 @@ int main(int argc, char **argv)
}
for(i=0;i<slot_length;i++){
for(ap=0;ap<frame_parms->nb_antennas_rx;ap++){
((int16_t*)&gNB->common_vars.rxdata[ap][slot_offset])[(2*i)+(delay*2)]=(int16_t)((tx_gain*r_re[ap][i])+(sqrt(sigma/2)*gaussdouble(0.0,1.0)));// convert to fixed point
((int16_t*)&gNB->common_vars.rxdata[ap][slot_offset])[(2*i)+(delay*2)]=(int16_t)((r_re[ap][i])+(sqrt(sigma/2)*gaussdouble(0.0,1.0)));// convert to fixed point