Commit fe861bf4 authored by Raymond Knopp's avatar Raymond Knopp

compilation passes and 1 UE simulation ok.

parent 0b89046a
......@@ -685,13 +685,6 @@ function main() {
oaisim_build_dir=oaisim_build_oai
oaisim_exec=oaisim
fi
# mandatory shared lib
compilations \
$oaisim_build_dir $config_libconfig_shlib \
lib$config_libconfig_shlib.so $dbin/lib$config_libconfig_shlib.so
compilations \
$oaisim_build_dir coding \
libcoding.so $dbin/libcoding.so
echo_info "Compiling $oaisim_exec ($oaisim_build_dir)"
cmake_file=$DIR/$oaisim_build_dir/CMakeLists.txt
......@@ -711,6 +704,13 @@ function main() {
compilations \
$oaisim_build_dir $oaisim_exec \
$oaisim_exec $dbin/$oaisim_exec.$REL
compilations \
$oaisim_build_dir $config_libconfig_shlib \
lib$config_libconfig_shlib.so $dbin/lib$config_libconfig_shlib.so
compilations \
$oaisim_build_dir coding \
libcoding.so $dbin/libcoding.so
if [ "$NOS1" != "1" ] ; then
......
......@@ -407,7 +407,7 @@ void recv_IF4p5(RU_t *ru, int *frame, int *subframe, uint16_t *packet_type, uint
PRACH_BLOCK_SIZE_BYTES);
}
}
LOG_I(PHY,"PRACH_IF4p5: CC_id %d : frame %d, subframe %d => %d dB\n",ru->idx,*frame,*subframe,
LOG_D(PHY,"PRACH_IF4p5: CC_id %d : frame %d, subframe %d => %d dB\n",ru->idx,*frame,*subframe,
dB_fixed(signal_energy((int*)&prach_rxsigF[0][0],839)));
for (idx=0;idx<ru->num_eNB;idx++) ru->wakeup_prach_eNB(ru->eNB_list[idx],ru,*frame,*subframe);
......
......@@ -1514,7 +1514,7 @@ void rx_prach0(PHY_VARS_eNB *eNB,
else
#endif
send_IF4p5(ru, ru->proc.frame_prach, ru->proc.subframe_prach, IF4p5_PRACH);
LOG_D(PHY,"SFN/SF %d.%d: Sending PRACH over IF4p5\n",ru->proc.frame_prach,ru->proc.subframe_prach);
return;
} else if (eNB!=NULL) {
......
......@@ -834,7 +834,7 @@ void schedule_response(Sched_Rsp_t *Sched_INFO)
else {
for (i=0;i<number_ul_pdu;i++) {
ul_config_pdu = &UL_req->ul_config_request_body.ul_config_pdu_list[i];
LOG_I(PHY,"NFAPI: ul_pdu %d : type %d\n",i,ul_config_pdu->pdu_type);
LOG_D(PHY,"NFAPI: ul_pdu %d : type %d\n",i,ul_config_pdu->pdu_type);
AssertFatal(ul_config_pdu->pdu_type == NFAPI_UL_CONFIG_ULSCH_PDU_TYPE ||
ul_config_pdu->pdu_type == NFAPI_UL_CONFIG_ULSCH_HARQ_PDU_TYPE ||
ul_config_pdu->pdu_type == NFAPI_UL_CONFIG_ULSCH_CQI_RI_PDU_TYPE ||
......
......@@ -1898,7 +1898,7 @@ void phy_procedures_eNB_uespec_RX(PHY_VARS_eNB *eNB,eNB_rxtx_proc_t *proc,const
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_PHY_PROCEDURES_ENB_RX_UESPEC, 1 );
LOG_I(PHY,"[eNB %d] Frame %d: Doing phy_procedures_eNB_uespec_RX(%d)\n",eNB->Mod_id,frame, subframe);
LOG_D(PHY,"[eNB %d] Frame %d: Doing phy_procedures_eNB_uespec_RX(%d)\n",eNB->Mod_id,frame, subframe);
eNB->rb_mask_ul[0]=0;
eNB->rb_mask_ul[1]=0;
......
......@@ -116,7 +116,7 @@ void prach_procedures(PHY_VARS_eNB *eNB
#endif
);
LOG_I(PHY,"[RAPROC] Frame %d, subframe %d : Most likely preamble %d, energy %d dB delay %d (prach_energy counter %d)\n",
LOG_D(PHY,"[RAPROC] Frame %d, subframe %d : Most likely preamble %d, energy %d dB delay %d (prach_energy counter %d)\n",
frame,subframe,
max_preamble[0],
max_preamble_energy[0]/10,
......
......@@ -391,7 +391,7 @@ void eNB_top(PHY_VARS_eNB *eNB, int frame_rx, int subframe_rx, char *string)
proc->frame_tx = proc_rxtx->frame_tx;
proc_rxtx->timestamp_tx = proc->timestamp_tx;
LOG_I(PHY,"RXTX for TX: %d.%d, RX: %d.%d\n",proc_rxtx->frame_tx,proc_rxtx->subframe_tx,proc_rxtx->frame_rx,proc_rxtx->subframe_rx);
LOG_D(PHY,"RXTX for TX: %d.%d, RX: %d.%d\n",proc_rxtx->frame_tx,proc_rxtx->subframe_tx,proc_rxtx->frame_rx,proc_rxtx->subframe_rx);
if (rxtx(eNB,proc_rxtx,string) < 0) LOG_E(PHY,"eNB %d CC_id %d failed during execution\n",eNB->Mod_id,eNB->CC_id);
}
......@@ -630,7 +630,7 @@ static void* eNB_thread_prach( void* param ) {
if (wait_on_condition(&proc->mutex_prach,&proc->cond_prach,&proc->instance_cnt_prach,"eNB_prach_thread") < 0) break;
LOG_I(PHY,"Running eNB prach procedures\n");
LOG_D(PHY,"Running eNB prach procedures\n");
prach_procedures(eNB
#ifdef Rel14
,0
......
......@@ -1097,7 +1097,7 @@ static void* ru_thread_prach( void* param ) {
);
}
else {
LOG_I(PHY,"Running rx_prach in %d.%d\n",proc->frame_prach,proc->subframe_prach);
LOG_D(PHY,"Running rx_prach in %d.%d\n",proc->frame_prach,proc->subframe_prach);
rx_prach(NULL,
ru,
NULL,
......@@ -1289,7 +1289,7 @@ void wakeup_eNBs(RU_t *ru) {
sprintf(string,"Incoming RU %d",ru->idx);
pthread_mutex_lock(&proc->mutex_RU);
LOG_I(PHY,"Frame %d, Subframe %d: RU %d done (wait_cnt %d),RU_mask[%d] %x\n",
LOG_D(PHY,"Frame %d, Subframe %d: RU %d done (wait_cnt %d),RU_mask[%d] %x\n",
ru->proc.frame_rx,ru->proc.subframe_rx,ru->idx,ru->wait_cnt,ru->proc.subframe_rx,proc->RU_mask[ru->proc.subframe_rx]);
clock_gettime(CLOCK_MONOTONIC,&ru->proc.t[ru->proc.subframe_rx]);
......@@ -1612,7 +1612,7 @@ static void* ru_thread_control( void* param ) {
&rru_config_msg,
msg_len))<0) {
LOG_D(PHY,"Waiting msg for RU %d\n", ru->idx);
}
else
{
switch(rru_config_msg.type)
......@@ -1845,7 +1845,7 @@ static void* ru_thread( void* param ) {
PHY_VARS_eNB **eNB_list = ru->eNB_list;
PHY_VARS_eNB *eNB=eNB_list[0];
eNB_proc_t *eNBproc = &eNB->proc;
int ret;
// set default return value
thread_top_init("ru_thread",0,870000,1000000,1000000);
......@@ -1863,7 +1863,7 @@ static void* ru_thread( void* param ) {
ret = openair0_device_load(&ru->rfdevice,&ru->openair0_cfg);
}
if (setup_RU_buffers(ru)!=0) {
printf("Exiting, cannot initialize RU Buffers\n");
exit(-1);
......@@ -1891,7 +1891,7 @@ static void* ru_thread( void* param ) {
// wait to be woken up
if (ru->function!=eNodeB_3GPP && ru->has_ctrl_prt == 1) {
if (wait_on_condition(&ru->proc.mutex_ru,&ru->proc.cond_ru_thread,&ru->proc.instance_cnt_ru,"ru_thread")<0) break;
}
else wait_sync("ru_thread");
if (ru->is_slave == 0) AssertFatal(ru->state == RU_RUN,"ru-%d state = %s != RU_RUN\n",ru->idx,ru_states[ru->state]);
......@@ -1982,7 +1982,7 @@ static void* ru_thread( void* param ) {
ru->idx,frame,subframe);
if ((ru->do_prach>0) && (is_prach_subframe(fp, proc->frame_rx, proc->subframe_rx)==1)) {
LOG_I(PHY,"Waking up prach for %d.%d\n",proc->frame_rx,proc->subframe_rx);
LOG_D(PHY,"Waking up prach for %d.%d\n",proc->frame_rx,proc->subframe_rx);
wakeup_prach_ru(ru);
}
#ifdef Rel14
......@@ -2886,12 +2886,16 @@ void RCconfig_RU(void) {
// Check if control port set
if (!(config_isparamset(RUParamList.paramarray[j],RU_REMOTE_PORTC_IDX)) ){
RC.ru[j]->eth_params.my_portc = *(RUParamList.paramarray[j][RU_LOCAL_PORTC_IDX].uptr);
RC.ru[j]->eth_params.remote_portc = *(RUParamList.paramarray[j][RU_REMOTE_PORTC_IDX].uptr);
printf("Removing control port for RU %d\n",j);
RC.ru[j]->has_ctrl_prt = 0;
}
else {
RC.ru[j]->eth_params.my_portc = *(RUParamList.paramarray[j][RU_LOCAL_PORTC_IDX].uptr);
RC.ru[j]->eth_params.remote_portc = *(RUParamList.paramarray[j][RU_REMOTE_PORTC_IDX].uptr);
printf(" Control port %u \n",RC.ru[j]->eth_params.my_portc);
}
if (strcmp(*(RUParamList.paramarray[j][RU_TRANSPORT_PREFERENCE_IDX].strptr), "udp") == 0) {
RC.ru[j]->if_south = LOCAL_RF;
......
......@@ -497,7 +497,7 @@ void do_UL_sig(channel_desc_t *UE2RU[NUMBER_OF_UE_MAX][NUMBER_OF_RU_MAX][MAX_NUM
if (((double)PHY_vars_UE_g[UE_id][CC_id]->tx_power_dBm[subframe] +
UE2RU[UE_id][ru_id][CC_id]->path_loss_dB) <= -125.0) {
// don't simulate a UE that is too weak
LOG_D(OCM,"[SIM][UL] ULPOWERS UE %d tx_pwr %d dBm (num_RE %d) for subframe %d (sf_offset %d)\n",
LOG_D(PHY,"[SIM][UL] ULPOWERS UE %d tx_pwr %d dBm (num_RE %d) for subframe %d (sf_offset %d)\n",
UE_id,
PHY_vars_UE_g[UE_id][CC_id]->tx_power_dBm[subframe],
PHY_vars_UE_g[UE_id][CC_id]->tx_total_RE[subframe],
......@@ -516,7 +516,7 @@ void do_UL_sig(channel_desc_t *UE2RU[NUMBER_OF_UE_MAX][NUMBER_OF_RU_MAX][MAX_NUM
1,
NULL,
PHY_vars_UE_g[UE_id][CC_id]->tx_total_RE[subframe]); // This make the previous argument the total power
LOG_D(OCM,"[SIM][UL] ULPOWERS UE %d tx_pwr %f dBm (target %d dBm, num_RE %d) for subframe %d (sf_offset %d)\n",
LOG_D(PHY,"[SIM][UL] ULPOWERS UE %d tx_pwr %f dBm (target %d dBm, num_RE %d) for subframe %d (sf_offset %d)\n",
UE_id,
10*log10(tx_pwr*PHY_vars_UE_g[UE_id][CC_id]->tx_total_RE[subframe]),
PHY_vars_UE_g[UE_id][CC_id]->tx_power_dBm[subframe],
......
......@@ -443,13 +443,13 @@ int olg_config(void)
//set_log(OCM, LOG_INFO, 20);
//set_log(OTG, LOG_INFO, 1);
set_comp_log(OCG, LOG_ERR, 0x15,1);
set_comp_log(EMU, LOG_DEBUG, 0x15,20);
set_comp_log(EMU, LOG_INFO, 0x15,20);
set_comp_log(MAC, LOG_TRACE, 0x15,1);
set_comp_log(RLC, LOG_TRACE, 0x15,1);
set_comp_log(PHY, LOG_TRACE, 0x15, 1);
set_comp_log(PDCP, LOG_DEBUG, 0x15,1);
set_comp_log(RRC, LOG_DEBUG, 0x15,1);
set_comp_log(OCM, LOG_DEBUG, 0x15,20);
set_comp_log(OCM, LOG_INFO, 0x15,20);
set_comp_log(OTG, LOG_DEBUG, 0x15,1);
set_comp_log(OMG, LOG_NOTICE, 0x15,1);
set_comp_log(OPT, LOG_ERR, 0x15,1);
......
......@@ -1072,7 +1072,7 @@ int ru_trx_read(openair0_device *device, openair0_timestamp *ptimestamp, void **
*ptimestamp = last_ru_rx_timestamp[ru_id][CC_id];
LOG_D(EMU,"RU_trx_read nsamps %d TS(%llu,%llu) => subframe %d\n",nsamps,
LOG_D(PHY,"RU_trx_read nsamps %d TS(%llu,%llu) => subframe %d\n",nsamps,
(unsigned long long)current_ru_rx_timestamp[ru_id][CC_id],
(unsigned long long)last_ru_rx_timestamp[ru_id][CC_id],
(int)((*ptimestamp/RC.ru[ru_id]->frame_parms.samples_per_tti)%10));
......@@ -1087,8 +1087,9 @@ int ru_trx_read(openair0_device *device, openair0_timestamp *ptimestamp, void **
subframe = (last_ru_rx_timestamp[ru_id][CC_id]/RC.ru[ru_id]->frame_parms.samples_per_tti)%10;
if (subframe_select(&RC.ru[ru_id]->frame_parms,subframe) != SF_DL) {
LOG_D(EMU,"RU_trx_read generating UL subframe %d (Ts %llu, current TS %llu)\n",
if (RC.ru[ru_id]->frame_parms.frame_type == FDD ||
subframe_select(&RC.ru[ru_id]->frame_parms,subframe) != SF_DL) {
LOG_D(PHY,"RU_trx_read generating UL subframe %d (Ts %llu, current TS %llu)\n",
subframe,(unsigned long long)*ptimestamp,
(unsigned long long)current_ru_rx_timestamp[ru_id][CC_id]);
......
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