Commit 4c0427ea authored by rmagueta's avatar rmagueta

Merge remote-tracking branch 'origin/nr_mimo_precoding_codebook_I' into develop-CSI-Measurements

# Conflicts:
#	openair1/PHY/INIT/nr_init_ue.c
#	openair2/GNB_APP/gnb_config.c
#	openair2/GNB_APP/gnb_paramdef.h
#	targets/PROJECTS/GENERIC-NR-5GC/CONF/gnb.sa.band41.fr1.106PRB.usrpb210.conf
#	targets/PROJECTS/GENERIC-NR-5GC/CONF/gnb.sa.band78.fr1.106PRB.usrpb210.conf
#	targets/PROJECTS/GENERIC-NR-5GC/CONF/gnb.sa.band78.fr1.162PRB.2x2.usrpn300.conf
parents 38d0dca0 6e48ec92
...@@ -22,9 +22,7 @@ gNBs = ...@@ -22,9 +22,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
#spCellConfigCommon #spCellConfigCommon
......
...@@ -37,8 +37,6 @@ gNBs = ...@@ -37,8 +37,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
min_rxtxtime = 6; min_rxtxtime = 6;
sib1_tda = 0; sib1_tda = 0;
......
...@@ -38,7 +38,7 @@ gNBs = ...@@ -38,7 +38,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1; pdsch_AntennaPorts_N1 = 2;
pusch_AntennaPorts = 2; pusch_AntennaPorts = 2;
pdcch_ConfigSIB1 = ( pdcch_ConfigSIB1 = (
......
...@@ -39,7 +39,7 @@ gNBs = ...@@ -39,7 +39,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1; pdsch_AntennaPorts_N1 = 2;
pusch_AntennaPorts = 2; pusch_AntennaPorts = 2;
pdcch_ConfigSIB1 = ( pdcch_ConfigSIB1 = (
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
min_rxtxtime = 6; min_rxtxtime = 6;
servingCellConfigCommon = ( servingCellConfigCommon = (
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
min_rxtxtime = 6; min_rxtxtime = 6;
servingCellConfigCommon = ( servingCellConfigCommon = (
......
...@@ -20,7 +20,7 @@ gNBs = ...@@ -20,7 +20,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1; pdsch_AntennaPorts_N1 = 2;
pusch_AntennaPorts = 2; pusch_AntennaPorts = 2;
pusch_TargetSNRx10 = 200; pusch_TargetSNRx10 = 200;
pucch_TargetSNRx10 = 200; pucch_TargetSNRx10 = 200;
......
...@@ -38,7 +38,7 @@ gNBs = ...@@ -38,7 +38,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1; pdsch_AntennaPorts_N1 = 2;
pusch_AntennaPorts = 2; pusch_AntennaPorts = 2;
ul_prbblacklist = "51,52,53,54" ul_prbblacklist = "51,52,53,54"
do_SRS = 1; do_SRS = 1;
......
...@@ -38,8 +38,6 @@ gNBs = ...@@ -38,8 +38,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
#pusch_TargetSNRx10 = 200; #pusch_TargetSNRx10 = 200;
#pucch_TargetSNRx10 = 200; #pucch_TargetSNRx10 = 200;
ul_prbblacklist = "51,52,53,54" ul_prbblacklist = "51,52,53,54"
......
...@@ -38,8 +38,10 @@ gNBs = ...@@ -38,8 +38,10 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1; pdsch_AntennaPorts_N1 = 2;
pusch_AntennaPorts = 2; pusch_AntennaPorts = 2;
#pusch_TargetSNRx10 = 200;
#pucch_TargetSNRx10 = 200;
ul_prbblacklist = "79,80,81,82" ul_prbblacklist = "79,80,81,82"
pdcch_ConfigSIB1 = ( pdcch_ConfigSIB1 = (
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
min_rxtxtime = 6; min_rxtxtime = 6;
servingCellConfigCommon = ( servingCellConfigCommon = (
......
...@@ -20,8 +20,6 @@ gNBs = ...@@ -20,8 +20,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -21,8 +21,6 @@ gNBs = ...@@ -21,8 +21,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
min_rxtxtime = 6; min_rxtxtime = 6;
servingCellConfigCommon = ( servingCellConfigCommon = (
......
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
#include "PHY/phy_extern.h" #include "PHY/phy_extern.h"
#include "LAYER2/NR_MAC_COMMON/nr_mac_extern.h" #include "common/ran_context.h"
#include "RRC/LTE/rrc_extern.h" #include "RRC/LTE/rrc_extern.h"
#include "PHY_INTERFACE/phy_interface.h" #include "PHY_INTERFACE/phy_interface.h"
#include "common/utils/LOG/log_extern.h" #include "common/utils/LOG/log_extern.h"
...@@ -75,7 +75,6 @@ ...@@ -75,7 +75,6 @@
#include "enb_config.h" #include "enb_config.h"
#include "gnb_paramdef.h" #include "gnb_paramdef.h"
#include "s1ap_eNB.h" #include "s1ap_eNB.h"
#include "SIMULATION/ETH_TRANSPORT/proto.h" #include "SIMULATION/ETH_TRANSPORT/proto.h"
#include <executables/softmodem-common.h> #include <executables/softmodem-common.h>
...@@ -517,7 +516,8 @@ void init_eNB_afterRU(void) { ...@@ -517,7 +516,8 @@ void init_eNB_afterRU(void) {
RC.nb_nr_inst = 1; RC.nb_nr_inst = 1;
for (inst=0; inst<RC.nb_nr_inst; inst++) { for (inst=0; inst<RC.nb_nr_inst; inst++) {
LOG_I(PHY,"RC.nb_nr_CC[inst:%d]:%p\n", inst, RC.gNB[inst]); LOG_I(PHY,"RC.nb_nr_CC[inst:%d]:%p\n", inst, RC.gNB[inst]);
gNB = RC.gNB[inst]; gNB = RC.gNB[inst];
phy_init_nr_gNB(gNB,0,0); phy_init_nr_gNB(gNB,0,0);
// map antennas and PRACH signals to gNB RX // map antennas and PRACH signals to gNB RX
......
This diff is collapsed.
This diff is collapsed.
...@@ -402,6 +402,7 @@ void init_nr_ue_transport(PHY_VARS_NR_UE *ue); ...@@ -402,6 +402,7 @@ void init_nr_ue_transport(PHY_VARS_NR_UE *ue);
void init_N_TA_offset(PHY_VARS_NR_UE *ue); void init_N_TA_offset(PHY_VARS_NR_UE *ue);
void nr_dump_frame_parms(NR_DL_FRAME_PARMS *frame_parms); void nr_dump_frame_parms(NR_DL_FRAME_PARMS *frame_parms);
int phy_init_nr_gNB(PHY_VARS_gNB *gNB, unsigned char is_secondary_gNB, unsigned char lowmem_flag); int phy_init_nr_gNB(PHY_VARS_gNB *gNB, unsigned char is_secondary_gNB, unsigned char lowmem_flag);
int init_codebook_gNB(PHY_VARS_gNB *gNB);
void nr_phy_config_request(NR_PHY_Config_t *gNB); void nr_phy_config_request(NR_PHY_Config_t *gNB);
void nr_phy_config_request_sim(PHY_VARS_gNB *gNB,int N_RB_DL,int N_RB_UL,int mu,int Nid_cell,uint64_t position_in_burst); void nr_phy_config_request_sim(PHY_VARS_gNB *gNB,int N_RB_DL,int N_RB_UL,int mu,int Nid_cell,uint64_t position_in_burst);
void phy_free_nr_gNB(PHY_VARS_gNB *gNB); void phy_free_nr_gNB(PHY_VARS_gNB *gNB);
......
...@@ -719,3 +719,18 @@ int nr_layer_precoder(int16_t **datatx_F_precoding, char *prec_matrix, uint8_t n ...@@ -719,3 +719,18 @@ int nr_layer_precoder(int16_t **datatx_F_precoding, char *prec_matrix, uint8_t n
/* ((int16_t *)precodatatx_F)[0] = (int16_t)((((int16_t *)precodatatx_F)[0]*ONE_OVER_SQRT2_Q15)>>15); /* ((int16_t *)precodatatx_F)[0] = (int16_t)((((int16_t *)precodatatx_F)[0]*ONE_OVER_SQRT2_Q15)>>15);
((int16_t *)precodatatx_F)[1] = (int16_t)((((int16_t *)precodatatx_F)[1]*ONE_OVER_SQRT2_Q15)>>15);*/ ((int16_t *)precodatatx_F)[1] = (int16_t)((((int16_t *)precodatatx_F)[1]*ONE_OVER_SQRT2_Q15)>>15);*/
} }
int nr_layer_precoder_cm(int16_t **datatx_F_precoding, int *prec_matrix, uint8_t n_layers, int32_t re_offset)
{
int32_t precodatatx_F = 0;
for (int al = 0; al<n_layers; al++) {
int16_t antenna_re = datatx_F_precoding[al][re_offset<<1];
int16_t antenna_im = datatx_F_precoding[al][(re_offset<<1) +1];
//printf("antenna precoding: %d %d\n",((int16_t *)&prec_matrix[al])[0],((int16_t *)&prec_matrix[al])[1]);
((int16_t *) &precodatatx_F)[0] += (int16_t)(((int32_t)(antenna_re*(((int16_t *)&prec_matrix[al])[0])) - (int32_t)(antenna_im* (((int16_t *)&prec_matrix[al])[1])))>>15);
((int16_t *) &precodatatx_F)[1] += (int16_t)(((int32_t)(antenna_re*(((int16_t *)&prec_matrix[al])[1])) + (int32_t)(antenna_im* (((int16_t *)&prec_matrix[al])[0])))>>15);
}
return precodatatx_F;
}
...@@ -135,4 +135,9 @@ int nr_layer_precoder(int16_t **datatx_F_precoding, ...@@ -135,4 +135,9 @@ int nr_layer_precoder(int16_t **datatx_F_precoding,
char *prec_matrix, char *prec_matrix,
uint8_t n_layers, uint8_t n_layers,
int32_t re_offset); int32_t re_offset);
int nr_layer_precoder_cm(int16_t **datatx_F_precoding,
int *prec_matrix,
uint8_t n_layers,
int32_t re_offset);
#endif #endif
...@@ -446,8 +446,7 @@ void nr_generate_pdsch(processingData_L1tx_t *msgTx, ...@@ -446,8 +446,7 @@ void nr_generate_pdsch(processingData_L1tx_t *msgTx,
// The same precoding matrix is applied on prg_size RBs, Thus // The same precoding matrix is applied on prg_size RBs, Thus
// pmi = prgs_list[rbidx/prg_size].pm_idx, rbidx =0,...,rbSize-1 // pmi = prgs_list[rbidx/prg_size].pm_idx, rbidx =0,...,rbSize-1
// The Precoding matrix: // The Precoding matrix:
// The Codebook Type I and Type II are not supported yet. // The Codebook Type I
// We`adopt the precoding matrices of PUSCH for 4 layers.
start_meas(&gNB->dlsch_precoding_stats); start_meas(&gNB->dlsch_precoding_stats);
for (int ap=0; ap<frame_parms->nb_antennas_tx; ap++) { for (int ap=0; ap<frame_parms->nb_antennas_tx; ap++) {
...@@ -498,47 +497,38 @@ void nr_generate_pdsch(processingData_L1tx_t *msgTx, ...@@ -498,47 +497,38 @@ void nr_generate_pdsch(processingData_L1tx_t *msgTx,
} }
} }
else { else {
//get the precoding matrix weights: if(frame_parms->nb_antennas_tx==1){//no precoding matrix defined
char *W_prec; memcpy((void*)&txdataF[ap][l*frame_parms->ofdm_symbol_size + txdataF_offset + k],
switch (frame_parms->nb_antennas_tx) { (void*)&txdataF_precoding[ap][2*(l*frame_parms->ofdm_symbol_size + k)],
case 1://1 antenna port NR_NB_SC_PER_RB*sizeof(int32_t));
W_prec = nr_W_1l_2p[pmi][ap]; k += NR_NB_SC_PER_RB;
break; if (k >= frame_parms->ofdm_symbol_size) {
case 2://2 antenna ports
if (rel15->nrOfLayers == 1)//1 layer
W_prec = nr_W_1l_2p[pmi][ap];
else//2 layers
W_prec = nr_W_2l_2p[pmi][ap];
break;
case 4://4 antenna ports
if (rel15->nrOfLayers == 1)//1 layer
W_prec = nr_W_1l_4p[pmi][ap];
else if (rel15->nrOfLayers == 2)//2 layers
W_prec = nr_W_2l_4p[pmi][ap];
else if (rel15->nrOfLayers == 3)//3 layers
W_prec = nr_W_3l_4p[pmi][ap];
else//4 layers
W_prec = nr_W_4l_4p[pmi][ap];
break;
default:
LOG_D(PHY,"Precoding 1,2, or 4 antenna ports are currently supported\n");
W_prec = nr_W_1l_2p[pmi][ap];
break;
}
for (int i=0; i<NR_NB_SC_PER_RB; i++) {
int32_t re_offset = l*frame_parms->ofdm_symbol_size + k;
int32_t precodatatx_F = nr_layer_precoder(txdataF_precoding, W_prec, rel15->nrOfLayers, re_offset);
((int16_t*)txdataF[ap])[(re_offset<<1) + (2*txdataF_offset)] = ((int16_t *) &precodatatx_F)[0];
((int16_t*)txdataF[ap])[(re_offset<<1) + 1 + (2*txdataF_offset)] = ((int16_t *) &precodatatx_F)[1];
#ifdef DEBUG_DLSCH_MAPPING
printf("antenna %d\t l %d \t k %d \t txdataF: %d %d\n",
ap, l, k, ((int16_t*)txdataF[ap])[(re_offset<<1) + (2*txdataF_offset)],
((int16_t*)txdataF[ap])[(re_offset<<1) + 1 + (2*txdataF_offset)]);
#endif
if (++k >= frame_parms->ofdm_symbol_size) {
k -= frame_parms->ofdm_symbol_size; k -= frame_parms->ofdm_symbol_size;
} }
} }
else {
//get the precoding matrix weights:
int32_t **mat = gNB->nr_mimo_precoding_matrix[rel15->nrOfLayers-1];
//i_row =0,...,dl_antenna_port
//j_col =0,...,nrOfLayers
//mat[pmi][i_rows*2+j_col]
int *W_prec;
W_prec = (int32_t *)&mat[pmi][ap*rel15->nrOfLayers];
for (int i=0; i<NR_NB_SC_PER_RB; i++) {
int32_t re_offset = l*frame_parms->ofdm_symbol_size + k;
int32_t precodatatx_F = nr_layer_precoder_cm(txdataF_precoding, W_prec, rel15->nrOfLayers, re_offset);
((int16_t*)txdataF[ap])[(re_offset<<1) + (2*txdataF_offset)] = ((int16_t *) &precodatatx_F)[0];
((int16_t*)txdataF[ap])[(re_offset<<1) + 1 + (2*txdataF_offset)] = ((int16_t *) &precodatatx_F)[1];
#ifdef DEBUG_DLSCH_MAPPING
printf("antenna %d\t l %d \t k %d \t txdataF: %d %d\n",
ap, l, k, ((int16_t*)txdataF[ap])[(re_offset<<1) + (2*txdataF_offset)],
((int16_t*)txdataF[ap])[(re_offset<<1) + 1 + (2*txdataF_offset)]);
#endif
if (++k >= frame_parms->ofdm_symbol_size) {
k -= frame_parms->ofdm_symbol_size;
}
}
}
} }
} //RB loop } //RB loop
} // symbol loop } // symbol loop
......
...@@ -402,7 +402,7 @@ void nr_processDLSegment(void* arg) { ...@@ -402,7 +402,7 @@ void nr_processDLSegment(void* arg) {
// Fixme: correct type is unsigned, but nrLDPC_decoder and all called behind use signed int // Fixme: correct type is unsigned, but nrLDPC_decoder and all called behind use signed int
if (check_crc((uint8_t *)llrProcBuf,length_dec,harq_process->F,crc_type)) { if (check_crc((uint8_t *)llrProcBuf,length_dec,harq_process->F,crc_type)) {
LOG_D(PHY,"Segment %u CRC OK\n\033[0m",r); LOG_D(PHY,"Segment %u CRC OK\n",r);
if (r==0) { if (r==0) {
for (int i=0; i<10; i++) LOG_D(PHY,"byte %d : %x\n",i,((uint8_t *)llrProcBuf)[i]); for (int i=0; i<10; i++) LOG_D(PHY,"byte %d : %x\n",i,((uint8_t *)llrProcBuf)[i]);
...@@ -412,7 +412,7 @@ void nr_processDLSegment(void* arg) { ...@@ -412,7 +412,7 @@ void nr_processDLSegment(void* arg) {
no_iteration_ldpc = dlsch->max_ldpc_iterations; no_iteration_ldpc = dlsch->max_ldpc_iterations;
rdata->decodeIterations = no_iteration_ldpc; rdata->decodeIterations = no_iteration_ldpc;
} else { } else {
LOG_D(PHY,"CRC NOT OK\n\033[0m"); LOG_D(PHY,"CRC NOT OK\n");
} }
nb_total_decod++; nb_total_decod++;
......
...@@ -733,7 +733,7 @@ unsigned short nr_dlsch_extract_rbs_single(int **rxdataF, ...@@ -733,7 +733,7 @@ unsigned short nr_dlsch_extract_rbs_single(int **rxdataF,
@param n_dmrs_cdm_groups @param n_dmrs_cdm_groups
@param frame_parms Pointer to frame descriptor @param frame_parms Pointer to frame descriptor
*/ */
unsigned short nr_dlsch_extract_rbs_multiple(int **rxdataF, void nr_dlsch_extract_rbs(int **rxdataF,
int **dl_ch_estimates, int **dl_ch_estimates,
int **rxdataF_ext, int **rxdataF_ext,
int **dl_ch_estimates_ext, int **dl_ch_estimates_ext,
...@@ -824,28 +824,12 @@ void nr_dlsch_channel_compensation_core(int **rxdataF_ext, ...@@ -824,28 +824,12 @@ void nr_dlsch_channel_compensation_core(int **rxdataF_ext,
int start_point); int start_point);
void nr_dlsch_deinterleaving(uint8_t symbol, void nr_dlsch_deinterleaving(uint8_t symbol,
uint8_t start_symbol, uint8_t start_symbol,
uint16_t L, uint16_t L,
uint16_t *llr, uint16_t *llr,
uint16_t *llr_deint, uint16_t *llr_deint,
uint16_t nb_rb_pdsch); uint16_t nb_rb_pdsch);
void dlsch_dual_stream_correlation(NR_DL_FRAME_PARMS *frame_parms,
unsigned char symbol,
unsigned short nb_rb,
int **dl_ch_estimates_ext,
int **dl_ch_estimates_ext_i,
int **dl_ch_rho_ext,
unsigned char output_shift);
void dlsch_dual_stream_correlationTM34(NR_DL_FRAME_PARMS *frame_parms,
unsigned char symbol,
unsigned short nb_rb,
int **dl_ch_estimates_ext,
int **dl_ch_estimates_ext_i,
int **dl_ch_rho_ext,
unsigned char output_shift0,
unsigned char output_shift1);
//This function is used to compute multiplications in Hhermitian * H matrix //This function is used to compute multiplications in Hhermitian * H matrix
void conjch0_mult_ch1(int *ch0, void conjch0_mult_ch1(int *ch0,
int *ch1, int *ch1,
...@@ -897,19 +881,6 @@ void nr_dlsch_detection_mrc(int **rxdataF_comp, ...@@ -897,19 +881,6 @@ void nr_dlsch_detection_mrc(int **rxdataF_comp,
unsigned short nb_rb, unsigned short nb_rb,
int length); int length);
void nr_dlsch_detection_mrc_core(int **rxdataF_comp,
int **rxdataF_comp_i,
int **rho,
int **rho_i,
int **dl_ch_mag,
int **dl_ch_magb,
int **dl_ch_mag_i,
int **dl_ch_magb_i,
unsigned char n_tx,
unsigned char n_rx,
int length,
int start_point);
void det_HhH(int32_t *after_mf_00, void det_HhH(int32_t *after_mf_00,
int32_t *after_mf_01, int32_t *after_mf_01,
int32_t *after_mf_10, int32_t *after_mf_10,
......
...@@ -803,6 +803,13 @@ typedef struct PHY_VARS_gNB_s { ...@@ -803,6 +803,13 @@ typedef struct PHY_VARS_gNB_s {
/// PDSCH DMRS sequence /// PDSCH DMRS sequence
uint32_t ****nr_gold_pdsch_dmrs; uint32_t ****nr_gold_pdsch_dmrs;
/// PDSCH codebook I precoding LUTs
/// first dimension: Rank number [0,...,noOfLayers-1[
/// second dimension: PMI [0,...,CodeSize-1[
/// third dimension: [i_rows*noOfLayers+j_col], i_rows=0,...pdsch_AntennaPorts-1 and j_col=0,...,noOfLayers-1
int32_t ***nr_mimo_precoding_matrix;
int pmiq_size[NR_MAX_NB_LAYERS];
/// PUSCH DMRS /// PUSCH DMRS
uint32_t ****nr_gold_pusch_dmrs; uint32_t ****nr_gold_pusch_dmrs;
...@@ -845,6 +852,9 @@ typedef struct PHY_VARS_gNB_s { ...@@ -845,6 +852,9 @@ typedef struct PHY_VARS_gNB_s {
/// counter to average prach energh over first 100 prach opportunities /// counter to average prach energh over first 100 prach opportunities
int prach_energy_counter; int prach_energy_counter;
int ap_N1;
int ap_N2;
int ap_XP;
int pucch0_thres; int pucch0_thres;
int pusch_thres; int pusch_thres;
int prach_thres; int prach_thres;
......
...@@ -183,7 +183,7 @@ typedef struct { ...@@ -183,7 +183,7 @@ typedef struct {
//! estimated rssi (dBm) //! estimated rssi (dBm)
short rx_rssi_dBm[NUMBER_OF_CONNECTED_gNB_MAX]; short rx_rssi_dBm[NUMBER_OF_CONNECTED_gNB_MAX];
//! estimated correlation (wideband linear) between spatial channels (computed in dlsch_demodulation) //! estimated correlation (wideband linear) between spatial channels (computed in dlsch_demodulation)
int rx_correlation[NUMBER_OF_CONNECTED_gNB_MAX][4][4]; int rx_correlation[NUMBER_OF_CONNECTED_gNB_MAX][NB_ANTENNAS_RX][NR_MAX_NB_LAYERS*NR_MAX_NB_LAYERS];//
//! estimated correlation (wideband dB) between spatial channels (computed in dlsch_demodulation) //! estimated correlation (wideband dB) between spatial channels (computed in dlsch_demodulation)
int rx_correlation_dB[NUMBER_OF_CONNECTED_gNB_MAX][2]; int rx_correlation_dB[NUMBER_OF_CONNECTED_gNB_MAX][2];
...@@ -271,12 +271,6 @@ typedef struct { ...@@ -271,12 +271,6 @@ typedef struct {
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx /// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[ /// - second index: ? [0..168*N_RB_DL[
int32_t **rxdataF_comp0; int32_t **rxdataF_comp0;
/// \brief Received frequency-domain signal after extraction and channel compensation for the second stream. 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
/// - third index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - fourth index: ? [0..168*N_RB_DL[
int32_t **rxdataF_comp1[8][8];
/// \brief Hold the channel estimates in frequency domain. /// \brief Hold the channel estimates in frequency domain.
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx /// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: samples? [0..symbols_per_tti*(ofdm_symbol_size+LTE_CE_FILTER_LENGTH)[ /// - second index: samples? [0..symbols_per_tti*(ofdm_symbol_size+LTE_CE_FILTER_LENGTH)[
...@@ -289,12 +283,6 @@ typedef struct { ...@@ -289,12 +283,6 @@ typedef struct {
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx /// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[ /// - second index: ? [0..168*N_RB_DL[
int32_t **dl_ch_ptrs_estimates_ext; 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
/// - third index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - fourth index: ? [0..168*N_RB_DL[
int32_t **dl_ch_rho_ext[8][8];
/// \brief Downlink beamforming channel estimates in frequency domain. /// \brief Downlink beamforming channel estimates in frequency domain.
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx /// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: samples? [0..symbols_per_tti*(ofdm_symbol_size+LTE_CE_FILTER_LENGTH)[ /// - second index: samples? [0..symbols_per_tti*(ofdm_symbol_size+LTE_CE_FILTER_LENGTH)[
...@@ -303,10 +291,6 @@ typedef struct { ...@@ -303,10 +291,6 @@ typedef struct {
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx /// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[ /// - second index: ? [0..168*N_RB_DL[
int32_t **dl_bf_ch_estimates_ext; int32_t **dl_bf_ch_estimates_ext;
/// \brief Downlink cross-correlation of MIMO channel estimates (unquantized PMI) 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_rho2_ext;
/// \brief Downlink PMIs extracted in PRBS and grouped in subbands. /// \brief Downlink PMIs extracted in PRBS and grouped in subbands.
/// - first index: ressource block [0..N_RB_DL[ /// - first index: ressource block [0..N_RB_DL[
uint8_t *pmi_ext; uint8_t *pmi_ext;
...@@ -314,18 +298,10 @@ typedef struct { ...@@ -314,18 +298,10 @@ typedef struct {
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx /// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[ /// - second index: ? [0..168*N_RB_DL[
int32_t **dl_ch_mag0; int32_t **dl_ch_mag0;
/// \brief Magnitude of Downlink Channel second layer (16QAM level/First 64QAM level).
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[
int32_t **dl_ch_mag1[8][8];
/// \brief Magnitude of Downlink Channel, first layer (2nd 64QAM level). /// \brief Magnitude of Downlink Channel, first layer (2nd 64QAM level).
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx /// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[ /// - second index: ? [0..168*N_RB_DL[
int32_t **dl_ch_magb0; int32_t **dl_ch_magb0;
/// \brief Magnitude of Downlink Channel second layer (2nd 64QAM level).
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[
int32_t **dl_ch_magb1[8][8];
/// \brief Magnitude of Downlink Channel, first layer (256QAM level). /// \brief Magnitude of Downlink Channel, first layer (256QAM level).
int32_t **dl_ch_magr0; int32_t **dl_ch_magr0;
/// \brief Cross-correlation Matrix of the gNB Tx channel signals. /// \brief Cross-correlation Matrix of the gNB Tx channel signals.
...@@ -595,10 +571,6 @@ typedef struct { ...@@ -595,10 +571,6 @@ typedef struct {
/// - second index: ? [0..168*N_RB_DL[ /// - second index: ? [0..168*N_RB_DL[
int32_t **dl_ch_estimates_ext; int32_t **dl_ch_estimates_ext;
/// \brief Pointers to channel cross-correlation vectors for multi-gNB detection. /// \brief Pointers to channel cross-correlation vectors for multi-gNB detection.
/// - first index: ? [0..7] (hard coded) FIXME! accessed via \c nb_antennas_rx
/// - second index: ? [0..168*N_RB_DL[
int32_t **dl_ch_rho_ext;
/// \brief Pointers to channel cross-correlation vectors for multi-gNB detection.
/// - first index: rx antenna [0..nb_antennas_rx[ /// - first index: rx antenna [0..nb_antennas_rx[
/// - second index: ? [0..] /// - second index: ? [0..]
int32_t **rho; int32_t **rho;
......
...@@ -348,7 +348,7 @@ struct NR_DL_FRAME_PARMS { ...@@ -348,7 +348,7 @@ struct NR_DL_FRAME_PARMS {
uint32_t samples_per_frame_wCP; uint32_t samples_per_frame_wCP;
/// NR numerology index [0..5] as specified in 38.211 Section 4 (mu). 0=15khZ SCS, 1=30khZ, 2=60kHz, etc /// NR numerology index [0..5] as specified in 38.211 Section 4 (mu). 0=15khZ SCS, 1=30khZ, 2=60kHz, etc
uint8_t numerology_index; uint8_t numerology_index;
/// Number of Physical transmit antennas in node /// Number of Physical transmit antennas in node (corresponds to nrOfAntennaPorts)
uint8_t nb_antennas_tx; uint8_t nb_antennas_tx;
/// Number of Receive antennas in node /// Number of Receive antennas in node
uint8_t nb_antennas_rx; uint8_t nb_antennas_rx;
......
...@@ -207,7 +207,7 @@ int nr_derive_key(int alg_type, uint8_t alg_id, ...@@ -207,7 +207,7 @@ int nr_derive_key(int alg_type, uint8_t alg_id,
void config_common(int Mod_idP, void config_common(int Mod_idP,
int ssb_SubcarrierOffset, int ssb_SubcarrierOffset,
int pdsch_AntennaPorts, rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts,
int pusch_AntennaPorts, int pusch_AntennaPorts,
NR_ServingCellConfigCommon_t *scc NR_ServingCellConfigCommon_t *scc
); );
...@@ -537,8 +537,8 @@ int main(int argc, char **argv) ...@@ -537,8 +537,8 @@ int main(int argc, char **argv)
case 'x': case 'x':
g_nrOfLayers=atoi(optarg); g_nrOfLayers=atoi(optarg);
if ((g_nrOfLayers!=1) && if ((g_nrOfLayers==0) ||
(g_nrOfLayers!=2)) { (g_nrOfLayers>4)) {
printf("Unsupported nr Of Layers %d\n",g_nrOfLayers); printf("Unsupported nr Of Layers %d\n",g_nrOfLayers);
exit(-1); exit(-1);
} }
...@@ -784,12 +784,20 @@ int main(int argc, char **argv) ...@@ -784,12 +784,20 @@ int main(int argc, char **argv)
fix_scc(scc,ssb_bitmap); fix_scc(scc,ssb_bitmap);
prepare_scd(scd); prepare_scd(scd);
rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts;
pdsch_AntennaPorts.N1 = n_tx>1 ? n_tx>>1 : 1;
pdsch_AntennaPorts.N2 = 1;
pdsch_AntennaPorts.XP = n_tx>1 ? 2 : 1;
gNB->ap_N1 = pdsch_AntennaPorts.N1;
gNB->ap_N2 = pdsch_AntennaPorts.N2;
gNB->ap_XP = pdsch_AntennaPorts.XP;
NR_UE_NR_Capability_t* UE_Capability_nr = CALLOC(1,sizeof(NR_UE_NR_Capability_t)); NR_UE_NR_Capability_t* UE_Capability_nr = CALLOC(1,sizeof(NR_UE_NR_Capability_t));
prepare_sim_uecap(UE_Capability_nr,scc,mu, prepare_sim_uecap(UE_Capability_nr,scc,mu,
N_RB_DL,g_mcsTableIdx); N_RB_DL,g_mcsTableIdx);
// TODO do a UECAP for phy-sim // TODO do a UECAP for phy-sim
fill_default_secondaryCellGroup(scc, scd, secondaryCellGroup, UE_Capability_nr, 0, 1, n_tx, 6, 0, 0, 0); fill_default_secondaryCellGroup(scc, scd, secondaryCellGroup, UE_Capability_nr, 0, 1, pdsch_AntennaPorts, 6, 0, 0, 0);
/* RRC parameter validation for secondaryCellGroup */ /* RRC parameter validation for secondaryCellGroup */
fix_scd(scd); fix_scd(scd);
...@@ -807,10 +815,11 @@ int main(int argc, char **argv) ...@@ -807,10 +815,11 @@ int main(int argc, char **argv)
AssertFatal((gNB->if_inst = NR_IF_Module_init(0))!=NULL,"Cannot register interface"); AssertFatal((gNB->if_inst = NR_IF_Module_init(0))!=NULL,"Cannot register interface");
gNB->if_inst->NR_PHY_config_req = nr_phy_config_request; gNB->if_inst->NR_PHY_config_req = nr_phy_config_request;
// common configuration // common configuration
rrc_mac_config_req_gNB(0,0, n_tx, n_tx, 0, 6, scc, NULL, 0, 0, NULL); rrc_mac_config_req_gNB(0,0, pdsch_AntennaPorts, n_tx, 0, 6, scc, NULL, 0, 0, NULL);
// UE dedicated configuration // UE dedicated configuration
rrc_mac_config_req_gNB(0,0, n_tx, n_tx, 0, 6, scc, NULL, 1, secondaryCellGroup->spCellConfig->reconfigurationWithSync->newUE_Identity,secondaryCellGroup); rrc_mac_config_req_gNB(0,0, pdsch_AntennaPorts, n_tx, 0, 6, scc, NULL, 1, secondaryCellGroup->spCellConfig->reconfigurationWithSync->newUE_Identity,secondaryCellGroup);
// reset preprocessor to the one of DLSIM after it has been set during // reset preprocessor to the one of DLSIM after it has been set during
// rrc_mac_config_req_gNB // rrc_mac_config_req_gNB
gNB_mac->pre_processor_dl = nr_dlsim_preprocessor; gNB_mac->pre_processor_dl = nr_dlsim_preprocessor;
...@@ -1202,10 +1211,10 @@ int main(int argc, char **argv) ...@@ -1202,10 +1211,10 @@ int main(int argc, char **argv)
frame_length_complex_samples, frame_length_complex_samples,
0); 0);
double H_awgn_mimo[4][4] ={{1.0, 0.5, 0.25, 0.125},//rx 0 double H_awgn_mimo[4][4] ={{1.0, 0.2, 0.1, 0.05}, //rx 0
{0.5, 1.0, 0.5, 0.25}, //rx 1 {0.2, 1.0, 0.2, 0.1}, //rx 1
{0.25, 0.5, 1.0, 0.5}, //rx 2 {0.1, 0.2, 1.0, 0.2}, //rx 2
{0.125, 0.25, 0.5, 1.0}};//rx 3 {0.05, 0.1, 0.2, 1.0}};//rx 3
for (i=frame_parms->get_samples_slot_timestamp(slot,frame_parms,0); for (i=frame_parms->get_samples_slot_timestamp(slot,frame_parms,0);
i<frame_parms->get_samples_slot_timestamp(slot+1,frame_parms,0); i<frame_parms->get_samples_slot_timestamp(slot+1,frame_parms,0);
...@@ -1260,7 +1269,7 @@ int main(int argc, char **argv) ...@@ -1260,7 +1269,7 @@ int main(int argc, char **argv)
TBS = UE_harq_process->TBS;//rel15->TBSize[0]; TBS = UE_harq_process->TBS;//rel15->TBSize[0];
uint16_t length_dmrs = get_num_dmrs(rel15->dlDmrsSymbPos); uint16_t length_dmrs = get_num_dmrs(rel15->dlDmrsSymbPos);
uint16_t nb_rb = rel15->rbSize; uint16_t nb_rb = rel15->rbSize;
uint8_t nb_re_dmrs = rel15->dmrsConfigType == NFAPI_NR_DMRS_TYPE1 ? 6 : 4; uint8_t nb_re_dmrs = rel15->dmrsConfigType == NFAPI_NR_DMRS_TYPE1 ? 6*UE_harq_process->n_dmrs_cdm_groups : 4*UE_harq_process->n_dmrs_cdm_groups;
uint8_t mod_order = rel15->qamModOrder[0]; uint8_t mod_order = rel15->qamModOrder[0];
uint8_t nb_symb_sch = rel15->NrOfSymbols; uint8_t nb_symb_sch = rel15->NrOfSymbols;
......
...@@ -730,8 +730,12 @@ int main(int argc, char **argv) ...@@ -730,8 +730,12 @@ int main(int argc, char **argv)
prepare_scd(scd); prepare_scd(scd);
// TODO do a UECAP for phy-sim rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts;
fill_default_secondaryCellGroup(scc, scd, secondaryCellGroup, NULL, 0, 1, n_tx, 0, 0, 0, 0); pdsch_AntennaPorts.N1 = n_tx;
pdsch_AntennaPorts.N2 = 1;
pdsch_AntennaPorts.XP = 1;
fill_default_secondaryCellGroup(scc, scd, secondaryCellGroup, NULL, 0, 1, pdsch_AntennaPorts, 0, 0, 0, 0);
// xer_fprint(stdout, &asn_DEF_NR_CellGroupConfig, (const void*)secondaryCellGroup); // xer_fprint(stdout, &asn_DEF_NR_CellGroupConfig, (const void*)secondaryCellGroup);
...@@ -742,9 +746,9 @@ int main(int argc, char **argv) ...@@ -742,9 +746,9 @@ int main(int argc, char **argv)
gNB->if_inst->NR_PHY_config_req = nr_phy_config_request; gNB->if_inst->NR_PHY_config_req = nr_phy_config_request;
// common configuration // common configuration
rrc_mac_config_req_gNB(0,0, n_tx, n_rx, 0, 6, scc, &rrc.carrier.mib,0, 0, NULL); rrc_mac_config_req_gNB(0,0, pdsch_AntennaPorts, n_rx, 0, 6, scc, &rrc.carrier.mib,0, 0, NULL);
// UE dedicated configuration // UE dedicated configuration
rrc_mac_config_req_gNB(0,0, n_tx, n_rx, 0, 6, scc, &rrc.carrier.mib,1, secondaryCellGroup->spCellConfig->reconfigurationWithSync->newUE_Identity,secondaryCellGroup); rrc_mac_config_req_gNB(0,0, pdsch_AntennaPorts, n_rx, 0, 6, scc, &rrc.carrier.mib,1, secondaryCellGroup->spCellConfig->reconfigurationWithSync->newUE_Identity,secondaryCellGroup);
frame_parms->nb_antennas_tx = n_tx; frame_parms->nb_antennas_tx = n_tx;
frame_parms->nb_antennas_rx = n_rx; frame_parms->nb_antennas_rx = n_rx;
nfapi_nr_config_request_scf_t *cfg = &gNB->gNB_config; nfapi_nr_config_request_scf_t *cfg = &gNB->gNB_config;
......
...@@ -413,7 +413,9 @@ typedef struct NRRrcConfigurationReq_s { ...@@ -413,7 +413,9 @@ typedef struct NRRrcConfigurationReq_s {
NR_ServingCellConfig_t *scd; NR_ServingCellConfig_t *scd;
int ssb_SubcarrierOffset; int ssb_SubcarrierOffset;
int sib1_tda; int sib1_tda;
int pdsch_AntennaPorts; int pdsch_AntennaPorts_N1;
int pdsch_AntennaPorts_N2;
int pdsch_AntennaPorts_XP;
int pusch_AntennaPorts; int pusch_AntennaPorts;
int minRXTXTIME; int minRXTXTIME;
int do_CSIRS; int do_CSIRS;
......
...@@ -620,8 +620,12 @@ void RCconfig_NR_L1(void) { ...@@ -620,8 +620,12 @@ void RCconfig_NR_L1(void) {
config_get( GNBSParams,sizeof(GNBSParams)/sizeof(paramdef_t),NULL); config_get( GNBSParams,sizeof(GNBSParams)/sizeof(paramdef_t),NULL);
int num_gnbs = GNBSParams[GNB_ACTIVE_GNBS_IDX].numelt; int num_gnbs = GNBSParams[GNB_ACTIVE_GNBS_IDX].numelt;
AssertFatal (num_gnbs > 0,"Failed to parse config file no gnbs %s \n",GNB_CONFIG_STRING_ACTIVE_GNBS); AssertFatal (num_gnbs > 0,"Failed to parse config file no gnbs %s \n",GNB_CONFIG_STRING_ACTIVE_GNBS);
config_getlist( &GNBParamList,GNBParams,sizeof(GNBParams)/sizeof(paramdef_t),NULL);
char *ulprbbl = *GNBParamList.paramarray[0][GNB_ULPRBBLACKLIST_IDX].strptr; config_getlist( &GNBParamList,GNBParams,sizeof(GNBParams)/sizeof(paramdef_t),NULL);
int N1 = *GNBParamList.paramarray[0][GNB_PDSCH_ANTENNAPORTS_N1_IDX].iptr;
int N2 = *GNBParamList.paramarray[0][GNB_PDSCH_ANTENNAPORTS_N2_IDX].iptr;
int XP = *GNBParamList.paramarray[0][GNB_PDSCH_ANTENNAPORTS_XP_IDX].iptr;
char *ulprbbl = *GNBParamList.paramarray[0][GNB_ULPRBBLACKLIST_IDX].strptr;
if (ulprbbl) LOG_I(NR_PHY,"PRB blacklist %s\n",ulprbbl); if (ulprbbl) LOG_I(NR_PHY,"PRB blacklist %s\n",ulprbbl);
char *save = NULL; char *save = NULL;
char *pt = strtok_r(ulprbbl, ",", &save); char *pt = strtok_r(ulprbbl, ",", &save);
...@@ -667,6 +671,9 @@ void RCconfig_NR_L1(void) { ...@@ -667,6 +671,9 @@ void RCconfig_NR_L1(void) {
RC.gNB[j]->prach_thres = *(L1_ParamList.paramarray[j][L1_PRACH_DTX_THRESHOLD].uptr); RC.gNB[j]->prach_thres = *(L1_ParamList.paramarray[j][L1_PRACH_DTX_THRESHOLD].uptr);
RC.gNB[j]->pusch_thres = *(L1_ParamList.paramarray[j][L1_PUSCH_DTX_THRESHOLD].uptr); RC.gNB[j]->pusch_thres = *(L1_ParamList.paramarray[j][L1_PUSCH_DTX_THRESHOLD].uptr);
RC.gNB[j]->num_ulprbbl = num_prbbl; RC.gNB[j]->num_ulprbbl = num_prbbl;
RC.gNB[j]->ap_N1 = N1;
RC.gNB[j]->ap_N2 = N2;
RC.gNB[j]->ap_XP = XP;
LOG_I(NR_PHY,"Copying %d blacklisted PRB to L1 context\n",num_prbbl); LOG_I(NR_PHY,"Copying %d blacklisted PRB to L1 context\n",num_prbbl);
memcpy(RC.gNB[j]->ulprbbl,prbbl,275*sizeof(int)); memcpy(RC.gNB[j]->ulprbbl,prbbl,275*sizeof(int));
if(strcmp(*(L1_ParamList.paramarray[j][L1_TRANSPORT_N_PREFERENCE_IDX].strptr), "local_mac") == 0) { if(strcmp(*(L1_ParamList.paramarray[j][L1_TRANSPORT_N_PREFERENCE_IDX].strptr), "local_mac") == 0) {
...@@ -1164,8 +1171,12 @@ void RCconfig_NRRRC(MessageDef *msg_p, uint32_t i, gNB_RRC_INST *rrc) { ...@@ -1164,8 +1171,12 @@ void RCconfig_NRRRC(MessageDef *msg_p, uint32_t i, gNB_RRC_INST *rrc) {
} }
LOG_I(GNB_APP,"SSB SCO %d\n",*GNBParamList.paramarray[i][GNB_SSB_SUBCARRIEROFFSET_IDX].iptr); LOG_I(GNB_APP,"SSB SCO %d\n",*GNBParamList.paramarray[i][GNB_SSB_SUBCARRIEROFFSET_IDX].iptr);
NRRRC_CONFIGURATION_REQ (msg_p).ssb_SubcarrierOffset = *GNBParamList.paramarray[i][GNB_SSB_SUBCARRIEROFFSET_IDX].iptr; NRRRC_CONFIGURATION_REQ (msg_p).ssb_SubcarrierOffset = *GNBParamList.paramarray[i][GNB_SSB_SUBCARRIEROFFSET_IDX].iptr;
LOG_I(GNB_APP,"pdsch_AntennaPorts %d\n",*GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_IDX].iptr); LOG_I(GNB_APP,"pdsch_AntennaPorts N1 %d\n",*GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_N1_IDX].iptr);
NRRRC_CONFIGURATION_REQ (msg_p).pdsch_AntennaPorts = *GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_IDX].iptr; NRRRC_CONFIGURATION_REQ (msg_p).pdsch_AntennaPorts_N1 = *GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_N1_IDX].iptr;
LOG_I(GNB_APP,"pdsch_AntennaPorts N2 %d\n",*GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_N2_IDX].iptr);
NRRRC_CONFIGURATION_REQ (msg_p).pdsch_AntennaPorts_N2 = *GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_N2_IDX].iptr;
LOG_I(GNB_APP,"pdsch_AntennaPorts XP %d\n",*GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_XP_IDX].iptr);
NRRRC_CONFIGURATION_REQ (msg_p).pdsch_AntennaPorts_XP = *GNBParamList.paramarray[i][GNB_PDSCH_ANTENNAPORTS_XP_IDX].iptr;
LOG_I(GNB_APP,"pusch_AntennaPorts %d\n",*GNBParamList.paramarray[i][GNB_PUSCH_ANTENNAPORTS_IDX].iptr); LOG_I(GNB_APP,"pusch_AntennaPorts %d\n",*GNBParamList.paramarray[i][GNB_PUSCH_ANTENNAPORTS_IDX].iptr);
NRRRC_CONFIGURATION_REQ (msg_p).pusch_AntennaPorts = *GNBParamList.paramarray[i][GNB_PUSCH_ANTENNAPORTS_IDX].iptr; NRRRC_CONFIGURATION_REQ (msg_p).pusch_AntennaPorts = *GNBParamList.paramarray[i][GNB_PUSCH_ANTENNAPORTS_IDX].iptr;
LOG_I(GNB_APP,"minTXRXTIME %d\n",*GNBParamList.paramarray[i][GNB_MINRXTXTIME_IDX].iptr); LOG_I(GNB_APP,"minTXRXTIME %d\n",*GNBParamList.paramarray[i][GNB_MINRXTXTIME_IDX].iptr);
...@@ -2039,9 +2050,13 @@ void configure_gnb_du_mac(int inst) { ...@@ -2039,9 +2050,13 @@ void configure_gnb_du_mac(int inst) {
gNB_RRC_INST *rrc = RC.nrrrc[inst]; gNB_RRC_INST *rrc = RC.nrrrc[inst];
// LOG_I(GNB_APP,"Configuring MAC/L1 %d, carrier->sib2 %p\n", inst, &carrier->sib2->radioResourceConfigCommon); // LOG_I(GNB_APP,"Configuring MAC/L1 %d, carrier->sib2 %p\n", inst, &carrier->sib2->radioResourceConfigCommon);
LOG_I(GNB_APP,"Configuring gNB DU MAC/L1 %d \n", inst); LOG_I(GNB_APP,"Configuring gNB DU MAC/L1 %d \n", inst);
rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts;
pdsch_AntennaPorts.N1 = rrc->configuration.pdsch_AntennaPorts_N1;
pdsch_AntennaPorts.N2 = rrc->configuration.pdsch_AntennaPorts_N2;
pdsch_AntennaPorts.XP = rrc->configuration.pdsch_AntennaPorts_XP;
rrc_mac_config_req_gNB(rrc->module_id, rrc_mac_config_req_gNB(rrc->module_id,
rrc->configuration.ssb_SubcarrierOffset, rrc->configuration.ssb_SubcarrierOffset,
rrc->configuration.pdsch_AntennaPorts, pdsch_AntennaPorts,
rrc->configuration.pusch_AntennaPorts, rrc->configuration.pusch_AntennaPorts,
rrc->configuration.sib1_tda, rrc->configuration.sib1_tda,
rrc->configuration.minRXTXTIME, rrc->configuration.minRXTXTIME,
......
...@@ -114,7 +114,9 @@ typedef enum { ...@@ -114,7 +114,9 @@ typedef enum {
#define GNB_CONFIG_STRING_LOCAL_S_PORTD "local_s_portd" #define GNB_CONFIG_STRING_LOCAL_S_PORTD "local_s_portd"
#define GNB_CONFIG_STRING_REMOTE_S_PORTD "remote_s_portd" #define GNB_CONFIG_STRING_REMOTE_S_PORTD "remote_s_portd"
#define GNB_CONFIG_STRING_SSBSUBCARRIEROFFSET "ssb_SubcarrierOffset" #define GNB_CONFIG_STRING_SSBSUBCARRIEROFFSET "ssb_SubcarrierOffset"
#define GNB_CONFIG_STRING_PDSCHANTENNAPORTS "pdsch_AntennaPorts" #define GNB_CONFIG_STRING_PDSCHANTENNAPORTS_N1 "pdsch_AntennaPorts_N1"
#define GNB_CONFIG_STRING_PDSCHANTENNAPORTS_N2 "pdsch_AntennaPorts_N2"
#define GNB_CONFIG_STRING_PDSCHANTENNAPORTS_XP "pdsch_AntennaPorts_XP"
#define GNB_CONFIG_STRING_PUSCHANTENNAPORTS "pusch_AntennaPorts" #define GNB_CONFIG_STRING_PUSCHANTENNAPORTS "pusch_AntennaPorts"
#define GNB_CONFIG_STRING_SIB1TDA "sib1_tda" #define GNB_CONFIG_STRING_SIB1TDA "sib1_tda"
#define GNB_CONFIG_STRING_DOCSIRS "do_CSIRS" #define GNB_CONFIG_STRING_DOCSIRS "do_CSIRS"
...@@ -144,7 +146,9 @@ typedef enum { ...@@ -144,7 +146,9 @@ typedef enum {
{GNB_CONFIG_STRING_LOCAL_S_PORTD, NULL, 0, uptr:NULL, defuintval:50001, TYPE_UINT, 0}, \ {GNB_CONFIG_STRING_LOCAL_S_PORTD, NULL, 0, uptr:NULL, defuintval:50001, TYPE_UINT, 0}, \
{GNB_CONFIG_STRING_REMOTE_S_PORTD, NULL, 0, uptr:NULL, defuintval:50001, TYPE_UINT, 0}, \ {GNB_CONFIG_STRING_REMOTE_S_PORTD, NULL, 0, uptr:NULL, defuintval:50001, TYPE_UINT, 0}, \
{GNB_CONFIG_STRING_SSBSUBCARRIEROFFSET, NULL, 0, iptr:NULL, defintval:31, TYPE_INT, 0}, \ {GNB_CONFIG_STRING_SSBSUBCARRIEROFFSET, NULL, 0, iptr:NULL, defintval:31, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_PDSCHANTENNAPORTS, NULL, 0, iptr:NULL, defintval:1, TYPE_INT, 0}, \ {GNB_CONFIG_STRING_PDSCHANTENNAPORTS_N1, "horiz. log. antenna ports", 0, iptr:NULL, defintval:1, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_PDSCHANTENNAPORTS_N2, "vert. log. antenna ports", 0, iptr:NULL, defintval:1, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_PDSCHANTENNAPORTS_XP, "XP log. antenna ports", 0, iptr:NULL, defintval:1, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_PUSCHANTENNAPORTS, NULL, 0, iptr:NULL, defintval:1, TYPE_INT, 0}, \ {GNB_CONFIG_STRING_PUSCHANTENNAPORTS, NULL, 0, iptr:NULL, defintval:1, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_SIB1TDA, NULL, 0, iptr:NULL, defintval:0, TYPE_INT, 0}, \ {GNB_CONFIG_STRING_SIB1TDA, NULL, 0, iptr:NULL, defintval:0, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_DOCSIRS, NULL, 0, iptr:NULL, defintval:0, TYPE_INT, 0}, \ {GNB_CONFIG_STRING_DOCSIRS, NULL, 0, iptr:NULL, defintval:0, TYPE_INT, 0}, \
...@@ -170,15 +174,17 @@ typedef enum { ...@@ -170,15 +174,17 @@ typedef enum {
#define GNB_LOCAL_S_PORTD_IDX 12 #define GNB_LOCAL_S_PORTD_IDX 12
#define GNB_REMOTE_S_PORTD_IDX 13 #define GNB_REMOTE_S_PORTD_IDX 13
#define GNB_SSB_SUBCARRIEROFFSET_IDX 14 #define GNB_SSB_SUBCARRIEROFFSET_IDX 14
#define GNB_PDSCH_ANTENNAPORTS_IDX 15 #define GNB_PDSCH_ANTENNAPORTS_N1_IDX 15
#define GNB_PUSCH_ANTENNAPORTS_IDX 16 #define GNB_PDSCH_ANTENNAPORTS_N2_IDX 16
#define GNB_SIB1_TDA_IDX 17 #define GNB_PDSCH_ANTENNAPORTS_XP_IDX 17
#define GNB_DO_CSIRS_IDX 18 #define GNB_PUSCH_ANTENNAPORTS_IDX 18
#define GNB_DO_SRS_IDX 19 #define GNB_SIB1_TDA_IDX 19
#define GNB_NRCELLID_IDX 20 #define GNB_DO_CSIRS_IDX 20
#define GNB_MINRXTXTIME_IDX 21 #define GNB_DO_SRS_IDX 21
#define GNB_ULPRBBLACKLIST_IDX 22 #define GNB_NRCELLID_IDX 22
#define GNB_UMONDEFAULTDRB_IDX 23 #define GNB_MINRXTXTIME_IDX 23
#define GNB_ULPRBBLACKLIST_IDX 24
#define GNB_UMONDEFAULTDRB_IDX 25
#define TRACKING_AREA_CODE_OKRANGE {0x0001,0xFFFD} #define TRACKING_AREA_CODE_OKRANGE {0x0001,0xFFFD}
#define GNBPARAMS_CHECK { \ #define GNBPARAMS_CHECK { \
......
...@@ -160,11 +160,11 @@ void process_CellGroup(NR_CellGroupConfig_t *CellGroup, NR_UE_sched_ctrl_t *sche ...@@ -160,11 +160,11 @@ void process_CellGroup(NR_CellGroupConfig_t *CellGroup, NR_UE_sched_ctrl_t *sche
} }
void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts, int pusch_AntennaPorts, NR_ServingCellConfigCommon_t *scc) { void config_common(int Mod_idP, int ssb_SubcarrierOffset, rrc_pdsch_AntennaPorts_t dl_antenna_ports_struct, int pusch_AntennaPorts, NR_ServingCellConfigCommon_t *scc) {
nfapi_nr_config_request_scf_t *cfg = &RC.nrmac[Mod_idP]->config[0]; nfapi_nr_config_request_scf_t *cfg = &RC.nrmac[Mod_idP]->config[0];
RC.nrmac[Mod_idP]->common_channels[0].ServingCellConfigCommon = scc; RC.nrmac[Mod_idP]->common_channels[0].ServingCellConfigCommon = scc;
int i; int pdsch_AntennaPorts = dl_antenna_ports_struct.N1 * dl_antenna_ports_struct.N2 * dl_antenna_ports_struct.XP;
// Carrier configuration // Carrier configuration
...@@ -181,7 +181,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts ...@@ -181,7 +181,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts
cfg->carrier_config.dl_frequency.tl.tag = NFAPI_NR_CONFIG_DL_FREQUENCY_TAG; cfg->carrier_config.dl_frequency.tl.tag = NFAPI_NR_CONFIG_DL_FREQUENCY_TAG;
cfg->num_tlv++; cfg->num_tlv++;
for (i=0; i<5; i++) { for (int i=0; i<5; i++) {
if (i==scc->downlinkConfigCommon->frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->subcarrierSpacing) { if (i==scc->downlinkConfigCommon->frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->subcarrierSpacing) {
cfg->carrier_config.dl_grid_size[i].value = scc->downlinkConfigCommon->frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->carrierBandwidth; cfg->carrier_config.dl_grid_size[i].value = scc->downlinkConfigCommon->frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->carrierBandwidth;
cfg->carrier_config.dl_k0[i].value = scc->downlinkConfigCommon->frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->offsetToCarrier; cfg->carrier_config.dl_k0[i].value = scc->downlinkConfigCommon->frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->offsetToCarrier;
...@@ -215,7 +215,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts ...@@ -215,7 +215,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts
cfg->carrier_config.uplink_frequency.tl.tag = NFAPI_NR_CONFIG_UPLINK_FREQUENCY_TAG; cfg->carrier_config.uplink_frequency.tl.tag = NFAPI_NR_CONFIG_UPLINK_FREQUENCY_TAG;
cfg->num_tlv++; cfg->num_tlv++;
for (i=0; i<5; i++) { for (int i=0; i<5; i++) {
if (i==scc->uplinkConfigCommon->frequencyInfoUL->scs_SpecificCarrierList.list.array[0]->subcarrierSpacing) { if (i==scc->uplinkConfigCommon->frequencyInfoUL->scs_SpecificCarrierList.list.array[0]->subcarrierSpacing) {
cfg->carrier_config.ul_grid_size[i].value = scc->uplinkConfigCommon->frequencyInfoUL->scs_SpecificCarrierList.list.array[0]->carrierBandwidth; cfg->carrier_config.ul_grid_size[i].value = scc->uplinkConfigCommon->frequencyInfoUL->scs_SpecificCarrierList.list.array[0]->carrierBandwidth;
cfg->carrier_config.ul_k0[i].value = scc->uplinkConfigCommon->frequencyInfoUL->scs_SpecificCarrierList.list.array[0]->offsetToCarrier; cfg->carrier_config.ul_k0[i].value = scc->uplinkConfigCommon->frequencyInfoUL->scs_SpecificCarrierList.list.array[0]->offsetToCarrier;
...@@ -306,7 +306,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts ...@@ -306,7 +306,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts
cfg->num_tlv++; cfg->num_tlv++;
cfg->prach_config.num_prach_fd_occasions_list = (nfapi_nr_num_prach_fd_occasions_t *) malloc(cfg->prach_config.num_prach_fd_occasions.value*sizeof(nfapi_nr_num_prach_fd_occasions_t)); cfg->prach_config.num_prach_fd_occasions_list = (nfapi_nr_num_prach_fd_occasions_t *) malloc(cfg->prach_config.num_prach_fd_occasions.value*sizeof(nfapi_nr_num_prach_fd_occasions_t));
for (i=0; i<cfg->prach_config.num_prach_fd_occasions.value; i++) { for (int i=0; i<cfg->prach_config.num_prach_fd_occasions.value; i++) {
// cfg->prach_config.num_prach_fd_occasions_list[i].num_prach_fd_occasions = i; // cfg->prach_config.num_prach_fd_occasions_list[i].num_prach_fd_occasions = i;
if (cfg->prach_config.prach_sequence_length.value) if (cfg->prach_config.prach_sequence_length.value)
cfg->prach_config.num_prach_fd_occasions_list[i].prach_root_sequence_index.value = scc->uplinkConfigCommon->initialUplinkBWP->rach_ConfigCommon->choice.setup->prach_RootSequenceIndex.choice.l139; cfg->prach_config.num_prach_fd_occasions_list[i].prach_root_sequence_index.value = scc->uplinkConfigCommon->initialUplinkBWP->rach_ConfigCommon->choice.setup->prach_RootSequenceIndex.choice.l139;
...@@ -374,7 +374,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts ...@@ -374,7 +374,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts
case 3 : case 3 :
cfg->ssb_table.ssb_mask_list[0].ssb_mask.value = 0; cfg->ssb_table.ssb_mask_list[0].ssb_mask.value = 0;
cfg->ssb_table.ssb_mask_list[1].ssb_mask.value = 0; cfg->ssb_table.ssb_mask_list[1].ssb_mask.value = 0;
for (i=0; i<4; i++) { for (int i=0; i<4; i++) {
cfg->ssb_table.ssb_mask_list[0].ssb_mask.value += (scc->ssb_PositionsInBurst->choice.longBitmap.buf[3-i]<<i*8); cfg->ssb_table.ssb_mask_list[0].ssb_mask.value += (scc->ssb_PositionsInBurst->choice.longBitmap.buf[3-i]<<i*8);
cfg->ssb_table.ssb_mask_list[1].ssb_mask.value += (scc->ssb_PositionsInBurst->choice.longBitmap.buf[7-i]<<i*8); cfg->ssb_table.ssb_mask_list[1].ssb_mask.value += (scc->ssb_PositionsInBurst->choice.longBitmap.buf[7-i]<<i*8);
} }
...@@ -413,7 +413,8 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts ...@@ -413,7 +413,8 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts
cfg->carrier_config.num_rx_ant.value = pusch_AntennaPorts; cfg->carrier_config.num_rx_ant.value = pusch_AntennaPorts;
AssertFatal(pusch_AntennaPorts > 0 && pusch_AntennaPorts < 13, "pusch_AntennaPorts in 1...12\n"); AssertFatal(pusch_AntennaPorts > 0 && pusch_AntennaPorts < 13, "pusch_AntennaPorts in 1...12\n");
cfg->carrier_config.num_rx_ant.tl.tag = NFAPI_NR_CONFIG_NUM_RX_ANT_TAG; cfg->carrier_config.num_rx_ant.tl.tag = NFAPI_NR_CONFIG_NUM_RX_ANT_TAG;
LOG_I(NR_MAC,"Set TX/RX antenna number to %d (num ssb %d: %x,%x)\n",cfg->carrier_config.num_tx_ant.value,num_ssb,cfg->ssb_table.ssb_mask_list[0].ssb_mask.value,cfg->ssb_table.ssb_mask_list[1].ssb_mask.value); LOG_I(NR_MAC,"Set TX/RX antenna number to %d (num ssb %d: %x,%x)\n",
cfg->carrier_config.num_tx_ant.value,num_ssb,cfg->ssb_table.ssb_mask_list[0].ssb_mask.value,cfg->ssb_table.ssb_mask_list[1].ssb_mask.value);
AssertFatal(cfg->carrier_config.num_tx_ant.value > 0,"carrier_config.num_tx_ant.value %d !\n",cfg->carrier_config.num_tx_ant.value ); AssertFatal(cfg->carrier_config.num_tx_ant.value > 0,"carrier_config.num_tx_ant.value %d !\n",cfg->carrier_config.num_tx_ant.value );
cfg->num_tlv++; cfg->num_tlv++;
cfg->num_tlv++; cfg->num_tlv++;
...@@ -450,7 +451,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts ...@@ -450,7 +451,7 @@ void config_common(int Mod_idP, int ssb_SubcarrierOffset, int pdsch_AntennaPorts
int rrc_mac_config_req_gNB(module_id_t Mod_idP, int rrc_mac_config_req_gNB(module_id_t Mod_idP,
int ssb_SubcarrierOffset, int ssb_SubcarrierOffset,
int pdsch_AntennaPorts, rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts,
int pusch_AntennaPorts, int pusch_AntennaPorts,
int sib1_tda, int sib1_tda,
int minRXTXTIMEpdsch, int minRXTXTIMEpdsch,
......
...@@ -42,13 +42,13 @@ void process_CellGroup(NR_CellGroupConfig_t *CellGroup, NR_UE_sched_ctrl_t *sche ...@@ -42,13 +42,13 @@ void process_CellGroup(NR_CellGroupConfig_t *CellGroup, NR_UE_sched_ctrl_t *sche
void config_common(int Mod_idP, void config_common(int Mod_idP,
int ssb_SubcarrierOffset, int ssb_SubcarrierOffset,
int pdsch_AntennaPorts, rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts,
int pusch_AntennaPorts, int pusch_AntennaPorts,
NR_ServingCellConfigCommon_t *scc); NR_ServingCellConfigCommon_t *scc);
int rrc_mac_config_req_gNB(module_id_t Mod_idP, int rrc_mac_config_req_gNB(module_id_t Mod_idP,
int ssb_SubcarrierOffset, int ssb_SubcarrierOffset,
int pdsch_AntennaPorts, rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts,
int pusch_AntennaPorts, int pusch_AntennaPorts,
int sib1_tda, int sib1_tda,
int minRXTXTIMEpdsch, int minRXTXTIMEpdsch,
......
...@@ -424,6 +424,11 @@ typedef struct rrc_gNB_ue_context_s { ...@@ -424,6 +424,11 @@ typedef struct rrc_gNB_ue_context_s {
struct gNB_RRC_UE_s ue_context; struct gNB_RRC_UE_s ue_context;
} rrc_gNB_ue_context_t; } rrc_gNB_ue_context_t;
typedef struct {
int N1;
int N2;
int XP;
} rrc_pdsch_AntennaPorts_t;
typedef struct { typedef struct {
...@@ -451,7 +456,7 @@ typedef struct { ...@@ -451,7 +456,7 @@ typedef struct {
NR_BCCH_DL_SCH_Message_t systemInformation; // SIB23 NR_BCCH_DL_SCH_Message_t systemInformation; // SIB23
int ssb_SubcarrierOffset; int ssb_SubcarrierOffset;
int sib1_tda; int sib1_tda;
int pdsch_AntennaPorts; rrc_pdsch_AntennaPorts_t pdsch_AntennaPorts;
int pusch_AntennaPorts; int pusch_AntennaPorts;
int minRXTXTIME; int minRXTXTIME;
int do_CSIRS; int do_CSIRS;
......
...@@ -79,7 +79,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco ...@@ -79,7 +79,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
NR_UE_NR_Capability_t *uecap, NR_UE_NR_Capability_t *uecap,
int scg_id, int scg_id,
int servCellIndex, int servCellIndex,
int dl_antenna_ports, rrc_pdsch_AntennaPorts_t dl_antenna_ports,
int minRXTXTIMEpdsch, int minRXTXTIMEpdsch,
int do_csirs, int do_csirs,
int do_srs, int do_srs,
...@@ -90,7 +90,7 @@ void fill_default_reconfig(NR_ServingCellConfigCommon_t *servingcellconfigcommon ...@@ -90,7 +90,7 @@ void fill_default_reconfig(NR_ServingCellConfigCommon_t *servingcellconfigcommon
NR_RRCReconfiguration_IEs_t *reconfig, NR_RRCReconfiguration_IEs_t *reconfig,
NR_CellGroupConfig_t *secondaryCellGroup, NR_CellGroupConfig_t *secondaryCellGroup,
NR_UE_NR_Capability_t *uecap, NR_UE_NR_Capability_t *uecap,
int dl_antenna_ports, rrc_pdsch_AntennaPorts_t dl_antenna_ports,
int minRXTXTIMEpdsch, int minRXTXTIMEpdsch,
int do_csirs, int do_csirs,
int do_srs, int do_srs,
......
...@@ -218,7 +218,9 @@ char openair_rrc_gNB_configuration(const module_id_t gnb_mod_idP, gNB_RrcConfigu ...@@ -218,7 +218,9 @@ char openair_rrc_gNB_configuration(const module_id_t gnb_mod_idP, gNB_RrcConfigu
rrc->ngap_id2_ngap_ids = hashtable_create (NUMBER_OF_UE_MAX * 2, NULL, NULL); rrc->ngap_id2_ngap_ids = hashtable_create (NUMBER_OF_UE_MAX * 2, NULL, NULL);
rrc->carrier.servingcellconfigcommon = configuration->scc; rrc->carrier.servingcellconfigcommon = configuration->scc;
rrc->carrier.ssb_SubcarrierOffset = configuration->ssb_SubcarrierOffset; rrc->carrier.ssb_SubcarrierOffset = configuration->ssb_SubcarrierOffset;
rrc->carrier.pdsch_AntennaPorts = configuration->pdsch_AntennaPorts; rrc->carrier.pdsch_AntennaPorts.N1 = configuration->pdsch_AntennaPorts_N1;
rrc->carrier.pdsch_AntennaPorts.N2 = configuration->pdsch_AntennaPorts_N2;
rrc->carrier.pdsch_AntennaPorts.XP = configuration->pdsch_AntennaPorts_XP;
rrc->carrier.pusch_AntennaPorts = configuration->pusch_AntennaPorts; rrc->carrier.pusch_AntennaPorts = configuration->pusch_AntennaPorts;
rrc->carrier.minRXTXTIME = configuration->minRXTXTIME; rrc->carrier.minRXTXTIME = configuration->minRXTXTIME;
rrc->carrier.sib1_tda = configuration->sib1_tda; rrc->carrier.sib1_tda = configuration->sib1_tda;
......
...@@ -360,7 +360,7 @@ void rrc_add_nsa_user(gNB_RRC_INST *rrc,struct rrc_gNB_ue_context_s *ue_context_ ...@@ -360,7 +360,7 @@ void rrc_add_nsa_user(gNB_RRC_INST *rrc,struct rrc_gNB_ue_context_s *ue_context_
if (NODE_IS_DU(rrc->node_type)) { if (NODE_IS_DU(rrc->node_type)) {
rrc_mac_config_req_gNB(rrc->module_id, rrc_mac_config_req_gNB(rrc->module_id,
rrc->carrier.ssb_SubcarrierOffset, rrc->carrier.ssb_SubcarrierOffset,
rrc->carrier.pdsch_AntennaPorts, rrc->carrier.pdsch_AntennaPorts,
rrc->carrier.pusch_AntennaPorts, rrc->carrier.pusch_AntennaPorts,
rrc->carrier.sib1_tda, rrc->carrier.sib1_tda,
rrc->carrier.minRXTXTIME, rrc->carrier.minRXTXTIME,
...@@ -372,7 +372,7 @@ void rrc_add_nsa_user(gNB_RRC_INST *rrc,struct rrc_gNB_ue_context_s *ue_context_ ...@@ -372,7 +372,7 @@ void rrc_add_nsa_user(gNB_RRC_INST *rrc,struct rrc_gNB_ue_context_s *ue_context_
} else { } else {
rrc_mac_config_req_gNB(rrc->module_id, rrc_mac_config_req_gNB(rrc->module_id,
rrc->carrier.ssb_SubcarrierOffset, rrc->carrier.ssb_SubcarrierOffset,
rrc->carrier.pdsch_AntennaPorts, rrc->carrier.pdsch_AntennaPorts,
rrc->carrier.pusch_AntennaPorts, rrc->carrier.pusch_AntennaPorts,
rrc->carrier.sib1_tda, rrc->carrier.sib1_tda,
rrc->carrier.minRXTXTIME, rrc->carrier.minRXTXTIME,
......
...@@ -56,7 +56,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco ...@@ -56,7 +56,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
NR_UE_NR_Capability_t *uecap, NR_UE_NR_Capability_t *uecap,
int scg_id, int scg_id,
int servCellIndex, int servCellIndex,
int dl_antenna_ports, rrc_pdsch_AntennaPorts_t dl_antenna_ports_struct,
int minRXTXTIME, int minRXTXTIME,
int do_csirs, int do_csirs,
int do_srs, int do_srs,
...@@ -73,6 +73,8 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco ...@@ -73,6 +73,8 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
// where the startPosition = 2 or 3 and sl160 = 17, 17, 27 ... 157 only give us 30 different allocations. // where the startPosition = 2 or 3 and sl160 = 17, 17, 27 ... 157 only give us 30 different allocations.
AssertFatal(uid>=0 && uid<30, "gNB cannot allocate the SRS resources\n"); AssertFatal(uid>=0 && uid<30, "gNB cannot allocate the SRS resources\n");
int dl_antenna_ports = dl_antenna_ports_struct.N1 * dl_antenna_ports_struct.N2 * dl_antenna_ports_struct.XP;
uint64_t bitmap=0; uint64_t bitmap=0;
switch (servingcellconfigcommon->ssb_PositionsInBurst->present) { switch (servingcellconfigcommon->ssb_PositionsInBurst->present) {
case 1 : case 1 :
...@@ -1159,19 +1161,50 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco ...@@ -1159,19 +1161,50 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
csirep1->codebookConfig->codebookType.choice.type1 = calloc(1,sizeof(*csirep1->codebookConfig->codebookType.choice.type1)); csirep1->codebookConfig->codebookType.choice.type1 = calloc(1,sizeof(*csirep1->codebookConfig->codebookType.choice.type1));
csirep1->codebookConfig->codebookType.choice.type1->subType.present=NR_CodebookConfig__codebookType__type1__subType_PR_typeI_SinglePanel; csirep1->codebookConfig->codebookType.choice.type1->subType.present=NR_CodebookConfig__codebookType__type1__subType_PR_typeI_SinglePanel;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel=calloc(1,sizeof(*csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel)); csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel=calloc(1,sizeof(*csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel));
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.present= if (dl_antenna_ports == 2) {
NR_CodebookConfig__codebookType__type1__subType__typeI_SinglePanel__nrOfAntennaPorts_PR_two; csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.present=
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two= NR_CodebookConfig__codebookType__type1__subType__typeI_SinglePanel__nrOfAntennaPorts_PR_two;
calloc(1,sizeof(*csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two)); csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two=
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.size=1; calloc(1,sizeof(*csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two));
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.bits_unused=2; csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.size=1;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.buf=malloc(1); csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.bits_unused=2;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.buf[0]=0xfc; csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.buf=malloc(1);
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.size=1; csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.two->twoTX_CodebookSubsetRestriction.buf[0]=0xfc;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.bits_unused=0; csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.size=1;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.buf=malloc(1); csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.bits_unused=0;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.buf[0]=0x03; csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.buf=malloc(1);
csirep1->codebookConfig->codebookType.choice.type1->codebookMode=1; csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->typeI_SinglePanel_ri_Restriction.buf[0]=0x03;
csirep1->codebookConfig->codebookType.choice.type1->codebookMode=1;
} else if (dl_antenna_ports < 16) {
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.present=
NR_CodebookConfig__codebookType__type1__subType__typeI_SinglePanel__nrOfAntennaPorts_PR_moreThanTwo;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo=
calloc(1,sizeof(*csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo));
if(dl_antenna_ports == 4)
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.present=
NR_CodebookConfig__codebookType__type1__subType__typeI_SinglePanel__nrOfAntennaPorts__moreThanTwo__n1_n2_PR_two_one_TypeI_SinglePanel_Restriction;
else if(dl_antenna_ports == 8)
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.present=
NR_CodebookConfig__codebookType__type1__subType__typeI_SinglePanel__nrOfAntennaPorts__moreThanTwo__n1_n2_PR_four_one_TypeI_SinglePanel_Restriction;
else if(dl_antenna_ports == 12)
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.present=
NR_CodebookConfig__codebookType__type1__subType__typeI_SinglePanel__nrOfAntennaPorts__moreThanTwo__n1_n2_PR_six_one_TypeI_SinglePanel_Restriction;
else//default
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.present=
NR_CodebookConfig__codebookType__type1__subType__typeI_SinglePanel__nrOfAntennaPorts__moreThanTwo__n1_n2_PR_two_one_TypeI_SinglePanel_Restriction;
/*csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.choice.two_one_TypeI_SinglePanel_Restriction.size=1;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.choice.two_one_TypeI_SinglePanel_Restriction.bits_unused=1;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.choice.two_one_TypeI_SinglePanel_Restriction.buf=malloc(1);
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->n1_n2.choice.two_one_TypeI_SinglePanel_Restriction.buf[0]=0xc0; //'00000011'B
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->typeI_SinglePanel_codebookSubsetRestriction_i2->size = 1;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->typeI_SinglePanel_codebookSubsetRestriction_i2->bits_unused=1;
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->typeI_SinglePanel_codebookSubsetRestriction_i2->buf=malloc(1);
csirep1->codebookConfig->codebookType.choice.type1->subType.choice.typeI_SinglePanel->nrOfAntennaPorts.choice.moreThanTwo->typeI_SinglePanel_codebookSubsetRestriction_i2->buf[0]=0xc0;*/
csirep1->codebookConfig->codebookType.choice.type1->codebookMode=1;
} else {//32 antennas are Not implemented yet
csirep1->codebookConfig->codebookType.choice.type1->codebookMode=2;
}
csirep1->dummy = NULL; csirep1->dummy = NULL;
csirep1->groupBasedBeamReporting.present = NR_CSI_ReportConfig__groupBasedBeamReporting_PR_disabled; csirep1->groupBasedBeamReporting.present = NR_CSI_ReportConfig__groupBasedBeamReporting_PR_disabled;
csirep1->groupBasedBeamReporting.choice.disabled=calloc(1,sizeof(*csirep1->groupBasedBeamReporting.choice.disabled)); csirep1->groupBasedBeamReporting.choice.disabled=calloc(1,sizeof(*csirep1->groupBasedBeamReporting.choice.disabled));
...@@ -1265,7 +1298,7 @@ void fill_default_reconfig(NR_ServingCellConfigCommon_t *servingcellconfigcommon ...@@ -1265,7 +1298,7 @@ void fill_default_reconfig(NR_ServingCellConfigCommon_t *servingcellconfigcommon
NR_RRCReconfiguration_IEs_t *reconfig, NR_RRCReconfiguration_IEs_t *reconfig,
NR_CellGroupConfig_t *secondaryCellGroup, NR_CellGroupConfig_t *secondaryCellGroup,
NR_UE_NR_Capability_t *uecap, NR_UE_NR_Capability_t *uecap,
int dl_antenna_ports, rrc_pdsch_AntennaPorts_t dl_antenna_ports,
int minRXTXTIME, int minRXTXTIME,
int do_csirs, int do_csirs,
int do_srs, int do_srs,
......
...@@ -736,10 +736,10 @@ static int rfsimulator_read(openair0_device *device, openair0_timestamp *ptimest ...@@ -736,10 +736,10 @@ static int rfsimulator_read(openair0_device *device, openair0_timestamp *ptimest
CirSize CirSize
); );
else { // no channel modeling else { // no channel modeling
double H_awgn_mimo[4][4] ={{1.0, 0.5, 0.25, 0.125},//rx 0 double H_awgn_mimo[4][4] ={{1.0, 0.2, 0.1, 0.05}, //rx 0
{0.5, 1.0, 0.5, 0.25}, //rx 1 {0.2, 1.0, 0.2, 0.1}, //rx 1
{0.25, 0.5, 1.0, 0.5}, //rx 2 {0.1, 0.2, 1.0, 0.2}, //rx 2
{0.125, 0.25, 0.5, 1.0}};//rx 3 {0.05, 0.1, 0.2, 1.0}};//rx 3
sample_t *out=(sample_t *)samplesVoid[a]; sample_t *out=(sample_t *)samplesVoid[a];
int nbAnt_tx = ptr->th.nbAnt;//number of Tx antennas int nbAnt_tx = ptr->th.nbAnt;//number of Tx antennas
......
...@@ -23,8 +23,6 @@ gNBs = ...@@ -23,8 +23,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,9 +22,7 @@ gNBs = ...@@ -22,9 +22,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
#spCellConfigCommon #spCellConfigCommon
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; ssb_SubcarrierOffset = 31;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,9 +22,7 @@ gNBs = ...@@ -22,9 +22,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
#spCellConfigCommon #spCellConfigCommon
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,9 +22,7 @@ gNBs = ...@@ -22,9 +22,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
#spCellConfigCommon #spCellConfigCommon
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
...@@ -203,7 +201,7 @@ L1s = ( ...@@ -203,7 +201,7 @@ L1s = (
RUs = ( RUs = (
{ {
local_rf = "yes" local_rf = "yes"
nb_tx = 1 nb_tx = 4
nb_rx = 1 nb_rx = 1
att_tx = 0 att_tx = 0
att_rx = 0; att_rx = 0;
...@@ -217,8 +215,10 @@ RUs = ( ...@@ -217,8 +215,10 @@ RUs = (
#bf_weights = [0x00007fff, 0x0000,0x0000, 0x0000]; #bf_weights = [0x00007fff, 0x0000,0x0000, 0x0000];
## beamforming 2x2 matrix: ## beamforming 2x2 matrix:
#bf_weights = [0x00007fff, 0x00000000, 0x00000000, 0x00007fff]; #bf_weights = [0x00007fff, 0x00000000, 0x00000000, 0x00007fff];
## beamforming 4x4 matrix: ## beamforming 2x4 matrix:
#bf_weights = [0x00007fff, 0x0000, 0x0000, 0x0000, 0x00000000, 0x00007fff, 0x0000, 0x0000, 0x0000, 0x0000, 0x00007fff, 0x0000, 0x0000, 0x0000, 0x0000, 0x00007fff]; #bf_weights = [0x00007fff, 0x0000, 0x0000, 0x0000, 0x0000, 0x00007fff, 0x0000, 0x0000];
#beamforming 4x4 matrix:
bf_weights = [0x00007fff, 0x0000, 0x0000, 0x0000, 0x0000, 0x00007fff, 0x0000, 0x0000, 0x0000, 0x0000, 0x00007fff, 0x0000, 0x0000, 0x0000, 0x0000, 0x00007fff];
sdr_addrs = "addr=192.168.10.2,mgmt_addr=192.168.10.2,second_addr=192.168.20.2"; sdr_addrs = "addr=192.168.10.2,mgmt_addr=192.168.10.2,second_addr=192.168.20.2";
clock_src = "external"; clock_src = "external";
} }
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,9 +22,7 @@ gNBs = ...@@ -22,9 +22,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
#spCellConfigCommon #spCellConfigCommon
......
...@@ -22,9 +22,7 @@ gNBs = ...@@ -22,9 +22,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
#spCellConfigCommon #spCellConfigCommon
......
...@@ -22,9 +22,7 @@ gNBs = ...@@ -22,9 +22,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
#spCellConfigCommon #spCellConfigCommon
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -22,8 +22,6 @@ gNBs = ...@@ -22,8 +22,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 31; //0; ssb_SubcarrierOffset = 31; //0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
pusch_TargetSNRx10 = 200; pusch_TargetSNRx10 = 200;
pucch_TargetSNRx10 = 200; pucch_TargetSNRx10 = 200;
......
...@@ -37,8 +37,6 @@ gNBs = ...@@ -37,8 +37,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
min_rxtxtime = 6; min_rxtxtime = 6;
sib1_tda = 0; sib1_tda = 0;
......
...@@ -37,8 +37,6 @@ gNBs = ...@@ -37,8 +37,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
sib1_tda = 0; sib1_tda = 0;
servingCellConfigCommon = ( servingCellConfigCommon = (
{ {
......
...@@ -33,7 +33,7 @@ gNBs = ...@@ -33,7 +33,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1; pdsch_AntennaPorts_N1 = 2;
pusch_AntennaPorts = 2; pusch_AntennaPorts = 2;
min_rxtxtime = 2; min_rxtxtime = 2;
sib1_tda = 0; sib1_tda = 0;
......
...@@ -31,8 +31,6 @@ gNBs = ...@@ -31,8 +31,6 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1;
pusch_AntennaPorts = 1;
pdcch_ConfigSIB1 = ( pdcch_ConfigSIB1 = (
{ {
......
...@@ -33,7 +33,7 @@ gNBs = ...@@ -33,7 +33,7 @@ gNBs =
////////// Physical parameters: ////////// Physical parameters:
ssb_SubcarrierOffset = 0; ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts = 1; pdsch_AntennaPorts_N1 = 2;
pusch_AntennaPorts = 2; pusch_AntennaPorts = 2;
min_rxtxtime = 2; min_rxtxtime = 2;
sib1_tda = 0; sib1_tda = 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