Commit 43fb9741 authored by nikaeinn's avatar nikaeinn

*chaning the AssertFatal to AssertError for RLC-MAC interface


git-svn-id: http://svn.eurecom.fr/openair4G/trunk@5155 818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent dc7170cb
......@@ -49,7 +49,7 @@
#include "SCHED/phy_procedures_emos.h"
#endif
#define DEBUG_PHY_PROC
//#define DEBUG_PHY_PROC
//#define DEBUG_ULSCH
#include "ARCH/CBMIMO1/DEVICE_DRIVER/extern.h"
......@@ -78,7 +78,7 @@
#define PUCCH 1
#define PUCCH1_THRES 25
#define PUCCH1_THRES 15
#define PUCCH1a_THRES 15
extern inline unsigned int taus(void);
......@@ -1702,7 +1702,7 @@ void phy_procedures_eNB_TX(unsigned char next_slot,PHY_VARS_eNB *phy_vars_eNB,ui
if (abstraction_flag == 0) {
#ifdef DEBUG_PHY_PROC
if (DCI_pdu->Num_ue_spec_dci+DCI_pdu->Num_common_dci > 0)
LOG_I(PHY,"[eNB %d] Frame %d, subframe %d: Calling generate_dci_top (pdcch) (common %d,ue_spec %d)\n",phy_vars_eNB->Mod_id,phy_vars_eNB->frame, next_slot>>1,DCI_pdu->Num_common_dci,DCI_pdu->Num_ue_spec_dci);
LOG_D(PHY,"[eNB %d] Frame %d, subframe %d: Calling generate_dci_top (pdcch) (common %d,ue_spec %d)\n",phy_vars_eNB->Mod_id,phy_vars_eNB->frame, next_slot>>1,DCI_pdu->Num_common_dci,DCI_pdu->Num_ue_spec_dci);
#endif
for (sect_id=0;sect_id<number_of_cards;sect_id++)
......@@ -2576,7 +2576,7 @@ void prach_procedures(PHY_VARS_eNB *phy_vars_eNB,uint8_t subframe,uint8_t abstra
}
#ifdef DEBUG_PHY_PROC
LOG_I(PHY,"[RAPROC] Most likely preamble %d, energy %d dB delay %d\n",
LOG_D(PHY,"[RAPROC] Most likely preamble %d, energy %d dB delay %d\n",
preamble_max,
preamble_energy_list[preamble_max],
preamble_delay_list[preamble_max]);
......
......@@ -2468,6 +2468,22 @@ int main(int argc, char **argv) {
} //ABStraction
if ( (test_perf != 0) && (100 * effective_rate > test_perf )) {
fprintf(bler_fd,"SNR; MCS; TBS; rate; err0; trials0; err1; trials1; err2; trials2; err3; trials3; dci_err\n");
fprintf(bler_fd,"%f;%d;%d;%f;%d;%d;%d;%d;%d;%d;%d;%d;%d\n",
SNR,
mcs,
PHY_vars_eNB->dlsch_eNB[0][0]->harq_processes[0]->TBS,
rate,
errs[0],
round_trials[0],
errs[1],
round_trials[1],
errs[2],
round_trials[2],
errs[3],
round_trials[3],
dci_errors);
fprintf(time_meas_fd,"SNR; MCS; TBS; rate; DL_DECOD_ITER; err0; trials0; err1; trials1; err2; trials2; err3; trials3; PE; dci_err;PE;ND;\n");
fprintf(time_meas_fd,"%f;%d;%d;%f(%2.1f%%,%f);%f;%d;%d;%d;%d;%d;%d;%d;%d;(%e,%e,%e,%e);%d/%d;%e;%f(%f);\n",
SNR,
......@@ -2495,7 +2511,7 @@ int main(int argc, char **argv) {
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0])/(double)PHY_vars_eNB->dlsch_eNB[0][0]->harq_processes[0]->TBS,
(1.0*(round_trials[0]-errs[0])+2.0*(round_trials[1]-errs[1])+3.0*(round_trials[2]-errs[2])+4.0*(round_trials[3]-errs[3]))/((double)round_trials[0]));
fprintf(time_meas_fd,"eNB_PROC_TX(%d); OFDM_MOD(%d); DL_MOD(%d); DL_SCR(%d); DL_ENC(%d); UE_PROC_RX(%d); OFDM_DEMOD_CH_EST(%d); RX_PDCCH(%d); CH_COMP_LLR(%d); DL_DECOD(%d);\n",
fprintf(time_meas_fd,"eNB_PROC_TX(%d); OFDM_MOD(%d); DL_MOD(%d); DL_SCR(%d); DL_ENC(%d); UE_PROC_RX(%d); OFDM_DEMOD_CH_EST(%d); RX_PDCCH(%d); CH_COMP_LLR(%d); DL_USCR; DL_DECOD(%d);\n",
PHY_vars_eNB->phy_proc_tx.trials,
PHY_vars_eNB->ofdm_mod_stats.trials,
PHY_vars_eNB->dlsch_modulation_stats.trials,
......@@ -2508,7 +2524,7 @@ int main(int argc, char **argv) {
PHY_vars_UE->dlsch_unscrambling_stats.trials,
PHY_vars_UE->dlsch_decoding_stats.trials
);
fprintf(time_meas_fd,"%f;%f;%f;%f;%f;%f;%f;%f;%f;%f;%f;%f;",
fprintf(time_meas_fd,"%f;%f;%f;%f;%f;%f;%f;%f;%f;%f;%f;",
get_time_meas_us(&PHY_vars_eNB->phy_proc_tx),
get_time_meas_us(&PHY_vars_eNB->ofdm_mod_stats),
get_time_meas_us(&PHY_vars_eNB->dlsch_modulation_stats),
......
......@@ -299,8 +299,9 @@ module_id_t find_UE_id(module_id_t module_idP, rnti_t rnti) {
module_id_t ue_mod_id;
for (ue_mod_id=0;ue_mod_id<NUMBER_OF_UE_MAX;ue_mod_id++) {
// if (mac_get_rrc_status(module_idP,1,ue_mod_id) >= RRC_CONNECTED) {
if (eNB_mac_inst[module_idP].UE_template[ue_mod_id].rnti==rnti) {
return(ue_mod_id);
return(ue_mod_id);
}
}
return(module_id_t)(-1);
......@@ -512,13 +513,14 @@ unsigned char *parse_ulsch_header(unsigned char *mac_header,
void SR_indication(module_id_t enb_mod_idP, frame_t frameP, rnti_t rntiP, sub_frame_t subframeP) {
smodule_id_t ue_mod_id = find_UE_id(enb_mod_idP, rntiP);
if (ue_mod_id >= 0) {
LOG_D(MAC,"[eNB %d][SR %x] Frame %d subframeP %d Signaling SR for UE %d \n",enb_mod_idP,rntiP,frameP,subframeP, ue_mod_id);
eNB_mac_inst[enb_mod_idP].UE_template[ue_mod_id].ul_SR = 1;
eNB_mac_inst[enb_mod_idP].UE_template[ue_mod_id].ul_active = TRUE;
} else {
AssertFatal(0, "find_UE_id(%u,rnti %d) not found", enb_mod_idP, rntiP);
// AssertFatal(0, "find_UE_id(%u,rnti %d) not found", enb_mod_idP, rntiP);
AssertError(0, 0, "find_UE_id(%u,rnti %d) not found", enb_mod_idP, rntiP);
}
}
......
......@@ -108,7 +108,7 @@ tbs_size_t mac_rlc_data_req(
AssertFatal (channel_idP < RLC_MAX_MBMS_LC, "channel id is too high (%u/%d)!\n", channel_idP, RLC_MAX_MBMS_LC);
else
AssertFatal (channel_idP < NB_RB_MAX, "channel id is too high (%u/%d)!\n", channel_idP, NB_RB_MAX);
#if defined(USER_MODE) && defined(OAI_EMU)
if (enb_flagP) {
AssertFatal ((enb_mod_idP >= oai_emulation.info.first_enb_local) && (oai_emulation.info.nb_enb_local > 0),
"eNB module id is too low (%u/%d)!\n",
......@@ -134,7 +134,7 @@ tbs_size_t mac_rlc_data_req(
ue_mod_idP,
oai_emulation.info.first_ue_local);
}
#endif
if (enb_flagP) {
if (MBMS_flagP) {
......@@ -149,7 +149,8 @@ tbs_size_t mac_rlc_data_req(
rlc_mode = rlc_array_eNB[enb_mod_idP][ue_mod_idP][rb_id].mode;
switch (rlc_mode) {
case RLC_MODE_NONE:
AssertFatal (0 , "enB RLC not configured rb id %u lcid %u module %u!\n", rb_id, channel_idP, enb_mod_idP);
//AssertFatal (0 , "enB RLC not configured rb id %u lcid %u module %u!\n", rb_id, channel_idP, enb_mod_idP);
AssertError (0 , 0, "enB RLC not configured rb id %u lcid %u module %u!\n", rb_id, channel_idP, enb_mod_idP);
return (tbs_size_t)0;
break;
case RLC_MODE_AM:
......@@ -279,7 +280,8 @@ void mac_rlc_data_ind (
rlc_mode = rlc_array_eNB[enb_mod_idP][ue_mod_idP][rb_id].mode;
switch (rlc_mode) {
case RLC_MODE_NONE:
AssertFatal (0 , "enB RLC not configured rb id %u lcid %u module %u!\n", rb_id, channel_idP, enb_mod_idP);
//AssertFatal (0 , "enB RLC not configured rb id %u lcid %u module %u!\n", rb_id, channel_idP, enb_mod_idP);
AssertError (0 , 0, "enB RLC not configured rb id %u lcid %u module %u!\n", rb_id, channel_idP, enb_mod_idP);
break;
case RLC_MODE_AM:
rlc_p = (void*)&rlc_array_eNB[enb_mod_idP][ue_mod_idP][rb_id].rlc.am;
......
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