Commit 016185c1 authored by Florian Kaltenberger's avatar Florian Kaltenberger

polartest will now create output files in current directory (otherwise it will not run on CI bench)

parent 4b1c9d83
...@@ -1037,7 +1037,7 @@ ...@@ -1037,7 +1037,7 @@
<pre_exec_args></pre_exec_args> <pre_exec_args></pre_exec_args>
<main_exec> $OPENAIR_DIR/targets/bin/polartest.Rel15</main_exec> <main_exec> $OPENAIR_DIR/targets/bin/polartest.Rel15</main_exec>
<main_exec_args>-q -s-10 -f0</main_exec_args> <main_exec_args>-q -s-10 -f0</main_exec_args>
<tags>ldpctest.test1</tags> <tags>polartest.test1</tags>
<search_expr_true>BLER= 0.000000</search_expr_true> <search_expr_true>BLER= 0.000000</search_expr_true>
<search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false> <search_expr_false>segmentation fault|assertion|exiting|fatal</search_expr_false>
<nruns>3</nruns> <nruns>3</nruns>
......
...@@ -82,6 +82,7 @@ int main(int argc, char *argv[]) { ...@@ -82,6 +82,7 @@ int main(int argc, char *argv[]) {
SNRstop =-6.0; SNRstop =-6.0;
decoder_int16=1; decoder_int16=1;
break; break;
case 'h': case 'h':
printf("./polartest -s SNRstart -d SNRinc -f SNRstop -m [0=PBCH|1=DCI|2=UCI] -i iterations -l decoderListSize -a pathMetricAppr -q (use fixed point decoder)\n"); printf("./polartest -s SNRstart -d SNRinc -f SNRstop -m [0=PBCH|1=DCI|2=UCI] -i iterations -l decoderListSize -a pathMetricAppr -q (use fixed point decoder)\n");
exit(-1); exit(-1);
...@@ -108,10 +109,13 @@ int main(int argc, char *argv[]) { ...@@ -108,10 +109,13 @@ int main(int argc, char *argv[]) {
//Logging //Logging
time_t currentTime; time_t currentTime;
time (&currentTime); time (&currentTime);
char *folderName, fileName[512], currentTimeInfo[25]; char fileName[512], currentTimeInfo[25];
char folderName[] = ".";
/*
folderName=getenv("HOME"); folderName=getenv("HOME");
strcat(folderName,"/Desktop/polartestResults"); strcat(folderName,"/Desktop/polartestResults");
*/
#ifdef DEBUG_POLAR_TIMING #ifdef DEBUG_POLAR_TIMING
sprintf(fileName,"%s/TIMING_ListSize_%d_pmAppr_%d_Payload_%d_Itr_%d",folderName,decoderListSize,pathMetricAppr,testLength,iterations); sprintf(fileName,"%s/TIMING_ListSize_%d_pmAppr_%d_Payload_%d_Itr_%d",folderName,decoderListSize,pathMetricAppr,testLength,iterations);
...@@ -122,8 +126,10 @@ int main(int argc, char *argv[]) { ...@@ -122,8 +126,10 @@ int main(int argc, char *argv[]) {
strcat(fileName,currentTimeInfo); strcat(fileName,currentTimeInfo);
//Create "~/Desktop/polartestResults" folder if it doesn't already exist. //Create "~/Desktop/polartestResults" folder if it doesn't already exist.
/*
struct stat folder = {0}; struct stat folder = {0};
if (stat(folderName, &folder) == -1) mkdir(folderName, S_IRWXU | S_IRWXG | S_IRWXO); if (stat(folderName, &folder) == -1) mkdir(folderName, S_IRWXU | S_IRWXG | S_IRWXO);
*/
FILE* logFile; FILE* logFile;
logFile = fopen(fileName, "w"); logFile = fopen(fileName, "w");
......
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