diff --git a/targets/RT/USER/Makefile b/targets/RT/USER/Makefile index d9b350a64c..151370ce52 100644 --- a/targets/RT/USER/Makefile +++ b/targets/RT/USER/Makefile @@ -12,11 +12,13 @@ LOWLATENCY_KERNEL:=$(shell if [ $(KERNEL_TYPE) = "lowlatency" ]; then echo "1" ; include $(OPENAIR2_DIR)/RRC/LITE/MESSAGES/Makefile.inc -#ifdef LOWLATENCY # this ifdef is to be removed after the debugging +ifdef EXMIMO +ifdef LOWLATENCY # this ifdef is to be removed after the debugging ifeq ($(LOWLATENCY_KERNEL),1) CFLAGS+=-DLOWLATENCY endif -#endif +endif +endif ifndef USRP USRP=0 diff --git a/targets/RT/USER/lte-softmodem.c b/targets/RT/USER/lte-softmodem.c index 1bed1df102..f146934b40 100644 --- a/targets/RT/USER/lte-softmodem.c +++ b/targets/RT/USER/lte-softmodem.c @@ -1719,7 +1719,7 @@ static void *eNB_thread(void *arg) } -#endif + static void get_options (int argc, char **argv) { int c; @@ -1839,6 +1839,7 @@ static void get_options (int argc, char **argv) { break; #ifdef OPENAIR2 case 'P': +#ifdef OPENAIR2 /* enable openair packet tracer (OPT)*/ if ((strcmp(optarg, "wireshark") == 0) || (strcmp(optarg, "WIRESHARK") == 0)) { @@ -1853,6 +1854,7 @@ static void get_options (int argc, char **argv) { printf("Unrecognized option for OPT module\n"); printf("Possible values are either wireshark or pcap\n"); } +#endif break; #endif case 'V': @@ -1950,6 +1952,9 @@ static void get_options (int argc, char **argv) { } } + AssertFatal(conf_config_file_name != NULL,"Please provide a configuration file\n"); + + if ((UE_flag == 0) && (conf_config_file_name != NULL)) { int i,j; @@ -2096,7 +2101,7 @@ int main(int argc, char **argv) { for (CC_id=0;CC_idframe_type = FDD; /* TDD */ + frame_parms[CC_id]->frame_type = TDD; /* TDD */ frame_parms[CC_id]->tdd_config = 3; frame_parms[CC_id]->tdd_config_S = 0; frame_parms[CC_id]->N_RB_DL = 25; @@ -2105,6 +2110,9 @@ int main(int argc, char **argv) { frame_parms[CC_id]->Ncp_UL = NORMAL; frame_parms[CC_id]->Nid_cell = Nid_cell; frame_parms[CC_id]->num_MBSFN_config = 0; + frame_parms[CC_id]->nb_antennas_tx_eNB = 1; + frame_parms[CC_id]->nb_antennas_tx = 1; + frame_parms[CC_id]->nb_antennas_rx = 1; } // initialize the log (see log.h for details) @@ -2188,7 +2196,6 @@ int main(int argc, char **argv) { if (opp_enabled ==1) reset_opp_meas(); - #ifdef OPENAIR2 if (opt_type != OPT_NONE) { radio_type_t radio_type; @@ -2278,7 +2285,7 @@ int main(int argc, char **argv) { UE[CC_id] = PHY_vars_UE_g[0][CC_id]; printf("PHY_vars_UE_g[0][%d] = %p\n",CC_id,UE[CC_id]); #ifndef OPENAIR2 - for (i=0;ipusch_config_dedicated[i].betaOffset_ACK_Index = beta_ACK; UE[CC_id]->pusch_config_dedicated[i].betaOffset_RI_Index = beta_RI; UE[CC_id]->pusch_config_dedicated[i].betaOffset_CQI_Index = beta_CQI; diff --git a/targets/RT/USER/lte-ue.c b/targets/RT/USER/lte-ue.c index 60afcf8106..200038c70d 100644 --- a/targets/RT/USER/lte-ue.c +++ b/targets/RT/USER/lte-ue.c @@ -59,8 +59,10 @@ #include "PHY/types.h" #include "PHY/defs.h" +#ifdef OPENAIR2 #include "LAYER2/MAC/defs.h" #include "RRC/LITE/extern.h" +#endif #include "PHY_INTERFACE/extern.h" #undef MALLOC //there are two conflicting definitions, so we better make sure we don't use it at all @@ -76,8 +78,10 @@ #include "MAC_INTERFACE/extern.h" //#include "SCHED/defs.h" #include "SCHED/extern.h" +#ifdef OPENAIR2 #include "LAYER2/MAC/extern.h" #include "LAYER2/MAC/proto.h" +#endif #include "UTIL/LOG/log_extern.h" #include "UTIL/OTG/otg_tx.h" @@ -481,7 +485,7 @@ static void *UE_thread_tx(void *arg) { phy_procedures_UE_S_TX(UE,0,0,no_relay); } - + #ifdef OPENAIR2 if (UE->lte_frame_parms.frame_type == TDD) { ret = mac_xface->ue_scheduler(UE->Mod_id, @@ -509,6 +513,8 @@ static void *UE_thread_tx(void *arg) { UE->UE_mode[0] = PRACH; } } + +#endif if (pthread_mutex_lock(&UE->mutex_tx) != 0) { @@ -620,7 +626,8 @@ static void *UE_thread_rx(void *arg) { ((UE->slot_rx&1)==0)) { phy_procedures_UE_RX(UE,0,0,UE->mode,no_relay,NULL); } - + +#ifdef OPENAIR2 if (i==0) { ret = mac_xface->ue_scheduler(UE->Mod_id, UE->frame_tx, @@ -647,8 +654,8 @@ static void *UE_thread_rx(void *arg) { UE->Mod_id,UE->frame_rx,UE->slot_tx>>1); UE->UE_mode[0] = PRACH; } - } - + } +#endif UE->slot_rx++; if (UE->slot_rx==20) { @@ -714,7 +721,6 @@ void *UE_thread(void *arg) { #ifdef LOWLATENCY struct sched_attr attr; unsigned int flags = 0; - unsigned long mask = 1; // processor 0 #endif @@ -1362,7 +1368,7 @@ void init_UE_threads(void) { } - +#ifdef OPENAIR2 void fill_ue_band_info(void) { UE_EUTRA_Capability_t *UE_EUTRA_Capability = UE_rrc_inst[0].UECap->UE_EUTRA_Capability; @@ -1390,7 +1396,7 @@ void fill_ue_band_info(void) { } } } - +#endif int setup_ue_buffers(PHY_VARS_UE **phy_vars_ue, openair0_config_t *openair0_cfg, openair0_rf_map rf_map[MAX_NUM_CCs]) {