Commit d7d4f6a8 authored by Sakthivel Velumani's avatar Sakthivel Velumani

FR2 integration complete

FR2 freq and numerology is configured via config file and cmd line.
For gnb the numerology is hard coded in NR_MAC_gNB/config.c as there is no easy way to pass it for now. This might be fixed in RRC branch.
parent 03d4142c
...@@ -114,7 +114,7 @@ int single_thread_flag=1; ...@@ -114,7 +114,7 @@ int single_thread_flag=1;
static int8_t threequarter_fs=0; static int8_t threequarter_fs=0;
uint32_t downlink_frequency[MAX_NUM_CCs][4]; uint64_t downlink_frequency[MAX_NUM_CCs][4];
int32_t uplink_frequency_offset[MAX_NUM_CCs][4]; int32_t uplink_frequency_offset[MAX_NUM_CCs][4];
//Temp fix for inexisting NR upper layer //Temp fix for inexisting NR upper layer
......
...@@ -609,16 +609,6 @@ void *UE_thread(void *arg) { ...@@ -609,16 +609,6 @@ void *UE_thread(void *arg) {
openair0_timestamp timestamp; openair0_timestamp timestamp;
void *rxp[NB_ANTENNAS_RX], *txp[NB_ANTENNAS_TX]; void *rxp[NB_ANTENNAS_RX], *txp[NB_ANTENNAS_TX];
int start_rx_stream = 0; int start_rx_stream = 0;
const uint16_t table_sf_slot[80] = {0,0,0,0,0,0,0,0,
1,1,1,1,1,1,1,1,
2,2,2,2,2,2,2,2,
3,3,3,3,3,3,3,3,
4,4,4,4,4,4,4,4,
5,5,5,5,5,5,5,5,
6,6,6,6,6,6,6,6,
7,7,7,7,7,7,7,7,
8,8,8,8,8,8,8,8,
9,9,9,9,9,9,9,9};
AssertFatal(0== openair0_device_load(&(UE->rfdevice), &openair0_cfg[0]), ""); AssertFatal(0== openair0_device_load(&(UE->rfdevice), &openair0_cfg[0]), "");
UE->rfdevice.host_type = RAU_HOST; UE->rfdevice.host_type = RAU_HOST;
AssertFatal(UE->rfdevice.trx_start_func(&UE->rfdevice) == 0, "Could not start the device\n"); AssertFatal(UE->rfdevice.trx_start_func(&UE->rfdevice) == 0, "Could not start the device\n");
...@@ -704,7 +694,7 @@ void *UE_thread(void *arg) { ...@@ -704,7 +694,7 @@ void *UE_thread(void *arg) {
curMsg->UE->current_thread_id[slot_nr] = thread_idx; curMsg->UE->current_thread_id[slot_nr] = thread_idx;
curMsg->proc.CC_id = 0; curMsg->proc.CC_id = 0;
curMsg->proc.nr_tti_rx= slot_nr; curMsg->proc.nr_tti_rx= slot_nr;
curMsg->proc.subframe_rx=table_sf_slot[slot_nr]; curMsg->proc.subframe_rx=slot_nr/(nb_slot_frame/10);
curMsg->proc.nr_tti_tx = (absolute_slot + DURATION_RX_TO_TX) % nb_slot_frame; curMsg->proc.nr_tti_tx = (absolute_slot + DURATION_RX_TO_TX) % nb_slot_frame;
curMsg->proc.subframe_tx=curMsg->proc.nr_tti_rx; curMsg->proc.subframe_tx=curMsg->proc.nr_tti_rx;
curMsg->proc.frame_rx = ( absolute_slot/nb_slot_frame ) % MAX_FRAME_NUMBER; curMsg->proc.frame_rx = ( absolute_slot/nb_slot_frame ) % MAX_FRAME_NUMBER;
......
...@@ -79,7 +79,7 @@ ...@@ -79,7 +79,7 @@
{"S" , CONFIG_HLP_MSLOTS, PARAMFLAG_BOOL, u8ptr:&exit_missed_slots, defintval:1, TYPE_UINT8, 0}, \ {"S" , CONFIG_HLP_MSLOTS, PARAMFLAG_BOOL, u8ptr:&exit_missed_slots, defintval:1, TYPE_UINT8, 0}, \
{"T" , CONFIG_HLP_TDD, PARAMFLAG_BOOL, iptr:&tddflag, defintval:0, TYPE_INT, 0}, \ {"T" , CONFIG_HLP_TDD, PARAMFLAG_BOOL, iptr:&tddflag, defintval:0, TYPE_INT, 0}, \
{"V" , CONFIG_HLP_VCD, PARAMFLAG_BOOL, iptr:&vcdflag, defintval:0, TYPE_INT, 0}, \ {"V" , CONFIG_HLP_VCD, PARAMFLAG_BOOL, iptr:&vcdflag, defintval:0, TYPE_INT, 0}, \
{"numerology" , CONFIG_HLP_NUMEROLOGY, PARAMFLAG_BOOL, iptr:&numerology, defintval:0, TYPE_INT, 0}, \ {"numerology" , CONFIG_HLP_NUMEROLOGY, 0, iptr:&numerology, defintval:0, TYPE_INT, 0}, \
{"emulate-rf" , CONFIG_HLP_EMULATE_RF, PARAMFLAG_BOOL, iptr:&emulate_rf, defintval:0, TYPE_INT, 0}, \ {"emulate-rf" , CONFIG_HLP_EMULATE_RF, PARAMFLAG_BOOL, iptr:&emulate_rf, defintval:0, TYPE_INT, 0}, \
{"parallel-config", CONFIG_HLP_PARALLEL_CMD,0, strptr:(char **)&parallel_config, defstrval:NULL, TYPE_STRING, 0}, \ {"parallel-config", CONFIG_HLP_PARALLEL_CMD,0, strptr:(char **)&parallel_config, defstrval:NULL, TYPE_STRING, 0}, \
{"worker-config", CONFIG_HLP_WORKER_CMD, 0, strptr:(char **)&worker_config, defstrval:NULL, TYPE_STRING, 0}, \ {"worker-config", CONFIG_HLP_WORKER_CMD, 0, strptr:(char **)&worker_config, defstrval:NULL, TYPE_STRING, 0}, \
......
...@@ -560,13 +560,14 @@ int main(int argc, char **argv) ...@@ -560,13 +560,14 @@ int main(int argc, char **argv)
mac_top_init_gNB(); mac_top_init_gNB();
gNB_mac = RC.nrmac[0]; gNB_mac = RC.nrmac[0];
if(mu<3) { if(mu==1) {
config_common(0,0,Nid_cell,78,SSB_positions,ssb_periodicity,(uint64_t)3640000000L,N_RB_DL,mu); config_common(0,0,Nid_cell,78,SSB_positions,ssb_periodicity,(uint64_t)3640000000L,N_RB_DL,1);
config_nr_mib(0,0,1,kHz30,0,0,0,0,0); config_nr_mib(0,0,1,kHz30,0,0,0,0,0);
} else { } else if(mu==3) {
config_common(0,0,Nid_cell,257,SSB_positions,ssb_periodicity,(uint64_t)28100000000L,N_RB_DL,mu); config_common(0,0,Nid_cell,257,SSB_positions,ssb_periodicity,(uint64_t)28100000000L,N_RB_DL,3);
config_nr_mib(0,0,1,kHz120,0,0,0,0,0); config_nr_mib(0,0,1,kHz120,0,0,0,0,0);
} } else
exit(-1);
......
...@@ -188,8 +188,8 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP, ...@@ -188,8 +188,8 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
ssb_pattern, ssb_pattern,
ssb_periodicity, ssb_periodicity,
dl_CarrierFreqP, dl_CarrierFreqP,
dl_BandwidthP dl_BandwidthP,
); 3); // for now in develop-nr there is no easy way pass numerology here hence hard coding.
}//END if( servingcellconfigcommon != NULL ) }//END if( servingcellconfigcommon != NULL )
LOG_E(MAC, "%s() %s:%d RC.nrmac[Mod_idP]->if_inst->NR_PHY_config_req:%p\n", __FUNCTION__, __FILE__, __LINE__, RC.nrmac[Mod_idP]->if_inst->NR_PHY_config_req); LOG_E(MAC, "%s() %s:%d RC.nrmac[Mod_idP]->if_inst->NR_PHY_config_req:%p\n", __FUNCTION__, __FILE__, __LINE__, RC.nrmac[Mod_idP]->if_inst->NR_PHY_config_req);
......
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