* update ulsim/dlsim stats
git-svn-id: http://svn.eurecom.fr/openair4G/trunk@6268 818b1a75-f10b-46b9-bf7c-635c3b92a50f
This commit is contained in:
@@ -6,7 +6,7 @@ OPENAIR1_TOP = $(OPENAIR1_DIR)
|
|||||||
OPENAIR2_TOP = $(OPENAIR2_DIR)
|
OPENAIR2_TOP = $(OPENAIR2_DIR)
|
||||||
OPENAIR3 = $(OPENAIR3_DIR)
|
OPENAIR3 = $(OPENAIR3_DIR)
|
||||||
|
|
||||||
CFLAGS += -DMAX_NUM_CCs=1 -Wall -DPHYSIM -DNODE_RG -DUSER_MODE -DNB_ANTENNAS_RX=2 -DNB_ANTENNAS_TXRX=2 -DNB_ANTENNAS_TX=2 -DPHY_CONTEXT=1 -DMALLOC_CHECK_=1 -DENABLE_VCD_FIFO # -Wno-packed-bitfield-compat
|
CFLAGS += -DMAX_NUM_CCs=1 -Wall -DPHYSIM -DNODE_RG -DUSER_MODE -DNB_ANTENNAS_RX=2 -DNB_ANTENNAS_TXRX=2 -DNB_ANTENNAS_TX=2 -DPHY_CONTEXT=1 -DMALLOC_CHECK_=1 -DENABLE_VCD_FIFO -DLOG_NO_THREAD # -Wno-packed-bitfield-compat
|
||||||
|
|
||||||
|
|
||||||
# DCI Debug
|
# DCI Debug
|
||||||
|
|||||||
@@ -337,7 +337,7 @@ int main(int argc, char **argv) {
|
|||||||
int rballocset=0;
|
int rballocset=0;
|
||||||
int print_perf=0;
|
int print_perf=0;
|
||||||
int test_perf=0;
|
int test_perf=0;
|
||||||
|
int dump_table=0;
|
||||||
int llr8_flag=0;
|
int llr8_flag=0;
|
||||||
|
|
||||||
double effective_rate=0.0;
|
double effective_rate=0.0;
|
||||||
@@ -366,7 +366,7 @@ int main(int argc, char **argv) {
|
|||||||
snr0 = 0;
|
snr0 = 0;
|
||||||
num_layers = 1;
|
num_layers = 1;
|
||||||
|
|
||||||
while ((c = getopt (argc, argv, "ahdpDe:m:n:o:s:f:t:c:g:r:F:x:y:z:AM:N:I:i:O:R:S:C:T:b:u:v:w:B:PLl:")) != -1) {
|
while ((c = getopt (argc, argv, "ahdpXDe:m:n:o:s:f:t:c:g:r:F:x:y:z:AM:N:I:i:O:R:S:C:T:b:u:v:w:B:PLl:")) != -1) {
|
||||||
switch (c)
|
switch (c)
|
||||||
{
|
{
|
||||||
case 'a':
|
case 'a':
|
||||||
@@ -561,6 +561,9 @@ int main(int argc, char **argv) {
|
|||||||
test_perf=atoi(optarg);
|
test_perf=atoi(optarg);
|
||||||
//print_perf =1;
|
//print_perf =1;
|
||||||
break;
|
break;
|
||||||
|
case 'X':
|
||||||
|
dump_table=1;
|
||||||
|
break;
|
||||||
case 'h':
|
case 'h':
|
||||||
default:
|
default:
|
||||||
printf("%s -h(elp) -a(wgn on) -d(ci decoding on) -p(extended prefix on) -m mcs1 -M mcs2 -n n_frames -s snr0 -x transmission mode (1,2,5,6) -y TXant -z RXant -I trch_file\n",argv[0]);
|
printf("%s -h(elp) -a(wgn on) -d(ci decoding on) -p(extended prefix on) -m mcs1 -M mcs2 -n n_frames -s snr0 -x transmission mode (1,2,5,6) -y TXant -z RXant -I trch_file\n",argv[0]);
|
||||||
@@ -3298,17 +3301,22 @@ PHY_vars_UE->lte_ue_pdcch_vars[0]->num_pdcch_symbols,
|
|||||||
// sort table
|
// sort table
|
||||||
qsort (table_tx, time_vector_tx.size, sizeof(double), &compare);
|
qsort (table_tx, time_vector_tx.size, sizeof(double), &compare);
|
||||||
qsort (table_rx, time_vector_rx.size, sizeof(double), &compare);
|
qsort (table_rx, time_vector_rx.size, sizeof(double), &compare);
|
||||||
#ifdef DEBUG
|
if (dump_table == 1 ) {
|
||||||
int n;
|
set_component_filelog(USIM); // file located in /tmp/usim.txt
|
||||||
printf("The transmitter raw data: \n");
|
int n;
|
||||||
for (n=0; n< time_vector_tx.size; n++)
|
LOG_F(USIM,"The transmitter raw data: \n");
|
||||||
printf("%f ", table_tx[n]);
|
for (n=0; n< time_vector_tx.size; n++){
|
||||||
printf("\n");
|
printf("%f ", table_tx[n]);
|
||||||
printf("The receiver raw data: \n");
|
LOG_F(USIM,"%f ", table_tx[n]);
|
||||||
for (n=0; n< time_vector_rx.size; n++)
|
}
|
||||||
printf("%f ", table_rx[n]);
|
LOG_F(USIM,"\n");
|
||||||
printf("\n");
|
LOG_F(USIM,"The receiver raw data: \n");
|
||||||
#endif
|
for (n=0; n< time_vector_rx.size; n++){
|
||||||
|
// printf("%f ", table_rx[n]);
|
||||||
|
LOG_F(USIM,"%f ", table_rx[n]);
|
||||||
|
}
|
||||||
|
LOG_F(USIM,"\n");
|
||||||
|
}
|
||||||
double tx_median = table_tx[time_vector_tx.size/2];
|
double tx_median = table_tx[time_vector_tx.size/2];
|
||||||
double tx_q1 = table_tx[time_vector_tx.size/4];
|
double tx_q1 = table_tx[time_vector_tx.size/4];
|
||||||
double tx_q3 = table_tx[3*time_vector_tx.size/4];
|
double tx_q3 = table_tx[3*time_vector_tx.size/4];
|
||||||
|
|||||||
@@ -258,6 +258,7 @@ int main(int argc, char **argv) {
|
|||||||
int s,Kr,Kr_bytes;
|
int s,Kr,Kr_bytes;
|
||||||
int dump_perf=0;
|
int dump_perf=0;
|
||||||
int test_perf=0;
|
int test_perf=0;
|
||||||
|
int dump_table=0;
|
||||||
|
|
||||||
double effective_rate=0.0;
|
double effective_rate=0.0;
|
||||||
char channel_model_input[10];
|
char channel_model_input[10];
|
||||||
@@ -276,7 +277,7 @@ int main(int argc, char **argv) {
|
|||||||
|
|
||||||
logInit();
|
logInit();
|
||||||
|
|
||||||
while ((c = getopt (argc, argv, "hapbm:n:Y:X:x:s:w:e:q:d:D:O:c:r:i:f:y:c:oA:C:R:g:N:l:S:T:QB:PI:L")) != -1) {
|
while ((c = getopt (argc, argv, "hapbXm:n:Y:X:x:s:w:e:q:d:D:O:c:r:i:f:y:c:oA:C:R:g:N:l:S:T:QB:PI:L")) != -1) {
|
||||||
switch (c) {
|
switch (c) {
|
||||||
case 'a':
|
case 'a':
|
||||||
channel_model = AWGN;
|
channel_model = AWGN;
|
||||||
@@ -1313,17 +1314,22 @@ int main(int argc, char **argv) {
|
|||||||
// sort table
|
// sort table
|
||||||
qsort (table_tx, time_vector_tx.size, sizeof(double), &compare);
|
qsort (table_tx, time_vector_tx.size, sizeof(double), &compare);
|
||||||
qsort (table_rx, time_vector_rx.size, sizeof(double), &compare);
|
qsort (table_rx, time_vector_rx.size, sizeof(double), &compare);
|
||||||
#ifdef DEBUG
|
if (dump_table == 1 ) {
|
||||||
int n;
|
int n;
|
||||||
printf("The transmitter raw data: \n");
|
set_component_filelog(USIM); // file located in /tmp/usim.txt
|
||||||
for (n=0; n< time_vector_tx.size; n++)
|
LOG_F(USIM,"The transmitter raw data: \n");
|
||||||
printf("%f ", table_tx[n]);
|
for (n=0; n< time_vector_tx.size; n++){
|
||||||
printf("\n");
|
// printf("%f ", table_tx[n]);
|
||||||
printf("The receiver raw data: \n");
|
LOG_F(USIM,"%f ", table_tx[n]);
|
||||||
for (n=0; n< time_vector_rx.size; n++)
|
}
|
||||||
printf("%f ", table_rx[n]);
|
LOG_F(USIM,"\n");
|
||||||
printf("\n");
|
LOG_F(USIM,"The receiver raw data: \n");
|
||||||
#endif
|
for (n=0; n< time_vector_rx.size; n++){
|
||||||
|
// printf("%f ", table_rx[n]);
|
||||||
|
LOG_F(USIM,"%f ", table_rx[n]);
|
||||||
|
}
|
||||||
|
LOG_F(USIM,"\n");
|
||||||
|
}
|
||||||
double tx_median = table_tx[time_vector_tx.size/2];
|
double tx_median = table_tx[time_vector_tx.size/2];
|
||||||
double tx_q1 = table_tx[time_vector_tx.size/4];
|
double tx_q1 = table_tx[time_vector_tx.size/4];
|
||||||
double tx_q3 = table_tx[3*time_vector_tx.size/4];
|
double tx_q3 = table_tx[3*time_vector_tx.size/4];
|
||||||
|
|||||||
+11
-3
@@ -381,13 +381,21 @@ int logInit (void)
|
|||||||
g_log->log_component[TMR].filelog = 0;
|
g_log->log_component[TMR].filelog = 0;
|
||||||
g_log->log_component[TMR].filelog_name = "";
|
g_log->log_component[TMR].filelog_name = "";
|
||||||
|
|
||||||
|
g_log->log_component[USIM].name = "USIM";
|
||||||
|
g_log->log_component[USIM].level = LOG_DEBUG;
|
||||||
|
g_log->log_component[USIM].flag = LOG_NONE;
|
||||||
|
g_log->log_component[USIM].interval = 1;
|
||||||
|
g_log->log_component[USIM].fd = 0;
|
||||||
|
g_log->log_component[USIM].filelog = 0;
|
||||||
|
g_log->log_component[USIM].filelog_name = "/tmp/usim.txt";
|
||||||
|
|
||||||
/* following log component are used for the localization*/
|
/* following log component are used for the localization*/
|
||||||
g_log->log_component[LOCALIZE].name = "LOCALIZE";
|
g_log->log_component[LOCALIZE].name = "LOCALIZE";
|
||||||
g_log->log_component[LOCALIZE].level = LOG_EMERG;
|
g_log->log_component[LOCALIZE].level = LOG_EMERG;
|
||||||
g_log->log_component[LOCALIZE].flag = LOG_MED;
|
g_log->log_component[LOCALIZE].flag = LOG_MED;
|
||||||
g_log->log_component[LOCALIZE].interval = 1;
|
g_log->log_component[LOCALIZE].interval = 1;
|
||||||
g_log->log_component[LOCALIZE].fd = 0;
|
g_log->log_component[LOCALIZE].fd = 0;
|
||||||
g_log->log_component[LOCALIZE].filelog = 1;
|
g_log->log_component[LOCALIZE].filelog = 0;
|
||||||
g_log->log_component[LOCALIZE].filelog_name = "/tmp/localize.log";
|
g_log->log_component[LOCALIZE].filelog_name = "/tmp/localize.log";
|
||||||
|
|
||||||
g_log->level2string[LOG_EMERG] = "G"; //EMERG
|
g_log->level2string[LOG_EMERG] = "G"; //EMERG
|
||||||
@@ -587,7 +595,7 @@ void logRecord_thread_safe(const char *file, const char *func,
|
|||||||
}
|
}
|
||||||
if ((g_log->log_component[comp].filelog) && (level == LOG_FILE)) {
|
if ((g_log->log_component[comp].filelog) && (level == LOG_FILE)) {
|
||||||
if (write(g_log->log_component[comp].fd, log_buffer, total_len) < total_len) {
|
if (write(g_log->log_component[comp].fd, log_buffer, total_len) < total_len) {
|
||||||
// TODO assert ?
|
// TODO assert ?
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -750,7 +758,7 @@ void logRecord_mt(const char *file, const char *func, int line, int comp,
|
|||||||
}
|
}
|
||||||
if ((g_log->log_component[comp].filelog) && (level == LOG_FILE)) {
|
if ((g_log->log_component[comp].filelog) && (level == LOG_FILE)) {
|
||||||
if (write(g_log->log_component[comp].fd, c->log_buffer, len) < len) {
|
if (write(g_log->log_component[comp].fd, c->log_buffer, len) < len) {
|
||||||
// TODO assert ?
|
// TODO assert ?
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
|
|||||||
@@ -265,6 +265,7 @@ typedef enum {
|
|||||||
RAL_UE,
|
RAL_UE,
|
||||||
ENB_APP,
|
ENB_APP,
|
||||||
TMR,
|
TMR,
|
||||||
|
USIM,
|
||||||
LOCALIZE,
|
LOCALIZE,
|
||||||
MAX_LOG_COMPONENTS,
|
MAX_LOG_COMPONENTS,
|
||||||
} comp_name_t;
|
} comp_name_t;
|
||||||
|
|||||||
Reference in New Issue
Block a user