Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenXG
OpenXG-RAN
Commits
b51a144d
Commit
b51a144d
authored
May 13, 2024
by
Romain Beurdouche
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(phy simulators): fix cmdline configmodule for CODING phy simulators
parent
8b889d90
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
45 additions
and
4 deletions
+45
-4
openair1/PHY/CODING/TESTBENCH/ldpctest.c
openair1/PHY/CODING/TESTBENCH/ldpctest.c
+16
-2
openair1/PHY/CODING/TESTBENCH/polartest.c
openair1/PHY/CODING/TESTBENCH/polartest.c
+14
-1
openair1/PHY/CODING/TESTBENCH/smallblocktest.c
openair1/PHY/CODING/TESTBENCH/smallblocktest.c
+15
-1
No files found.
openair1/PHY/CODING/TESTBENCH/ldpctest.c
View file @
b51a144d
...
...
@@ -26,6 +26,7 @@
#include <stdint.h>
#include "assertions.h"
#include "SIMULATION/TOOLS/sim.h"
#include "common/config/config_userapi.h"
#include "common/utils/load_module_shlib.h"
#include "PHY/CODING/nrLDPC_extern.h"
//#include "openair1/SIMULATION/NR_PHY/nr_unitary_defs.h"
...
...
@@ -402,7 +403,7 @@ int main(int argc, char *argv[])
{
short
block_length
=
8448
;
// decoder supports length: 1201 -> 1280, 2401 -> 2560
// default to check output inside ldpc, the NR version checks the outer CRC defined by 3GPP
char
*
ldpc_version
=
""
;
char
*
ldpc_version
=
NULL
;
/* version of the ldpc decoder library to use (XXX suffix to use when loading libldpc_XXX.so */
short
max_iterations
=
5
;
int
n_segments
=
1
;
...
...
@@ -424,7 +425,19 @@ int main(int argc, char *argv[])
short
BG
=
0
,
Zc
;
while
((
c
=
getopt
(
argc
,
argv
,
"q:r:s:S:l:G:n:d:i:t:u:hv:"
))
!=
-
1
)
if
((
uniqCfg
=
load_configmodule
(
argc
,
argv
,
CONFIG_ENABLECMDLINEONLY
))
==
0
)
{
exit_fun
(
"[LDPCTEST] Error, configuration module init failed
\n
"
);
}
logInit
();
while
((
c
=
getopt
(
argc
,
argv
,
"--:q:r:s:S:l:G:n:d:i:t:u:hv:"
))
!=
-
1
)
{
/* ignore long options starting with '--' and their arguments that are handled by configmodule */
/* with this opstring getopt returns 1 for non-option arguments, refer to 'man 3 getopt' */
if
(
c
==
1
||
c
==
'-'
)
continue
;
printf
(
"handling optarg %c
\n
"
,
c
);
switch
(
c
)
{
case
'q'
:
qbits
=
atoi
(
optarg
);
...
...
@@ -494,6 +507,7 @@ int main(int argc, char *argv[])
exit
(
1
);
break
;
}
}
//printf("the decoder supports BG2, Kb=10, Z=128 & 256\n");
//printf(" range of blocklength: 1201 -> 1280, 2401 -> 2560\n");
printf
(
"block length %d:
\n
"
,
block_length
);
...
...
openair1/PHY/CODING/TESTBENCH/polartest.c
View file @
b51a144d
...
...
@@ -11,6 +11,7 @@
#include "PHY/CODING/nrPolar_tools/nr_polar_uci_defs.h"
#include "PHY/CODING/coding_defs.h"
#include "SIMULATION/TOOLS/sim.h"
#include "common/config/config_userapi.h"
//#include "common/utils/LOG/log.h"
#include "coding_unitary_defs.h"
//#define DEBUG_DCI_POLAR_PARAMS
...
...
@@ -32,7 +33,19 @@ int main(int argc, char *argv[])
uint8_t
aggregation_level
=
8
,
decoderListSize
=
8
,
logFlag
=
0
;
uint16_t
rnti
=
0
;
while
((
arguments
=
getopt
(
argc
,
argv
,
"s:d:f:m:i:l:a:p:hqgFL:k:"
))
!=
-
1
)
{
if
((
uniqCfg
=
load_configmodule
(
argc
,
argv
,
CONFIG_ENABLECMDLINEONLY
))
==
0
)
{
exit_fun
(
"[POLARTEST] Error, configuration module init failed
\n
"
);
}
logInit
();
while
((
arguments
=
getopt
(
argc
,
argv
,
"--:s:d:f:m:i:l:a:p:hqgFL:k:"
))
!=
-
1
)
{
/* ignore long options starting with '--' and their arguments that are handled by configmodule */
/* with this opstring getopt returns 1 for non-option arguments, refer to 'man 3 getopt' */
if
(
arguments
==
1
||
arguments
==
'-'
)
continue
;
printf
(
"handling optarg %c
\n
"
,
arguments
);
switch
(
arguments
)
{
case
's'
:
SNRstart
=
atof
(
optarg
);
...
...
openair1/PHY/CODING/TESTBENCH/smallblocktest.c
View file @
b51a144d
#include <getopt.h>
#include "common/config/config_userapi.h"
#include "SIMULATION/TOOLS/sim.h"
#include "PHY/CODING/nrSmallBlock/nr_small_block_defs.h"
#include "coding_unitary_defs.h"
...
...
@@ -26,7 +27,19 @@ int main(int argc, char *argv[])
int8_t
channelOutput_int8
[
NR_SMALL_BLOCK_CODED_BITS
];
unsigned
char
qbits
=
8
;
while
((
arguments
=
getopt
(
argc
,
argv
,
"s:d:f:l:i:mhg"
))
!=
-
1
)
if
((
uniqCfg
=
load_configmodule
(
argc
,
argv
,
CONFIG_ENABLECMDLINEONLY
))
==
0
)
{
exit_fun
(
"[SMALLBLOCKTEST] Error, configuration module init failed
\n
"
);
}
logInit
();
while
((
arguments
=
getopt
(
argc
,
argv
,
"--:s:d:f:l:i:mhg"
))
!=
-
1
)
{
/* ignore long options starting with '--' and their arguments that are handled by configmodule */
/* with this opstring getopt returns 1 for non-option arguments, refer to 'man 3 getopt' */
if
(
arguments
==
1
||
arguments
==
'-'
)
continue
;
printf
(
"handling optarg %c
\n
"
,
arguments
);
switch
(
arguments
)
{
case
's'
:
SNRstart
=
atof
(
optarg
);
...
...
@@ -69,6 +82,7 @@ int main(int argc, char *argv[])
perror
(
"[smallblocktest.c] Problem at argument parsing with getopt"
);
exit
(
-
1
);
}
}
uint16_t
mask
=
0x07ff
>>
(
11
-
messageLength
);
for
(
SNR
=
SNRstart
;
SNR
<=
SNRstop
;
SNR
+=
SNRinc
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment