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
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
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
alex037yang
OpenXG-RAN
Commits
1942d267
Commit
1942d267
authored
Sep 30, 2018
by
Florian Kaltenberger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
adding command line paramter usrp-args and usrp-clksrc to UE
parent
9f5f0ade
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
1 deletion
+29
-1
targets/RT/USER/lte-softmodem.h
targets/RT/USER/lte-softmodem.h
+6
-1
targets/RT/USER/lte-uesoftmodem.c
targets/RT/USER/lte-uesoftmodem.c
+23
-0
No files found.
targets/RT/USER/lte-softmodem.h
View file @
1942d267
...
@@ -98,6 +98,9 @@
...
@@ -98,6 +98,9 @@
#define CONFIG_HLP_DISABLNBIOT "disable nb-iot, even if defined in config\n"
#define CONFIG_HLP_DISABLNBIOT "disable nb-iot, even if defined in config\n"
#define CONFIG_HLP_USRP_ARGS "set the arguments to identify USRP (same syntax as in UHD)\n"
#define CONFIG_HLP_USRP_CLK_SRC "USRP clock source: 'internal' or 'external'\n"
/***************************************************************************************************************************************/
/***************************************************************************************************************************************/
/* command line options definitions, CMDLINE_XXXX_DESC macros are used to initialize paramdef_t arrays which are then used as argument
/* command line options definitions, CMDLINE_XXXX_DESC macros are used to initialize paramdef_t arrays which are then used as argument
when calling config_get or config_getlist functions */
when calling config_get or config_getlist functions */
...
@@ -147,7 +150,9 @@
...
@@ -147,7 +150,9 @@
{"num-ues", NULL, 0, u8ptr:&(NB_UE_INST), defuintval:1, TYPE_UINT8, 0}, \
{"num-ues", NULL, 0, u8ptr:&(NB_UE_INST), defuintval:1, TYPE_UINT8, 0}, \
{"r" , CONFIG_HLP_PRB, 0, u8ptr:&(frame_parms[0]->N_RB_DL), defintval:25, TYPE_UINT8, 0}, \
{"r" , CONFIG_HLP_PRB, 0, u8ptr:&(frame_parms[0]->N_RB_DL), defintval:25, TYPE_UINT8, 0}, \
{"dlsch-demod-shift", CONFIG_HLP_DLSHIFT, 0, iptr:(int32_t *)&dlsch_demod_shift, defintval:0, TYPE_INT, 0}, \
{"dlsch-demod-shift", CONFIG_HLP_DLSHIFT, 0, iptr:(int32_t *)&dlsch_demod_shift, defintval:0, TYPE_INT, 0}, \
}
{"usrp-args", CONFIG_HLP_USRP_ARGS, 0, strptr:(char **)&usrp_args, defstrval:"type=b200", TYPE_STRING, 0}, \
{"usrp-clksrc", CONFIG_HLP_USRP_CLK_SRC,0, strptr:(char **)&usrp_clksrc, defstrval:"internal", TYPE_STRING, 0} \
}
#define DEFAULT_DLF 2680000000
#define DEFAULT_DLF 2680000000
...
...
targets/RT/USER/lte-uesoftmodem.c
View file @
1942d267
...
@@ -223,6 +223,9 @@ int numerology = 0;
...
@@ -223,6 +223,9 @@ int numerology = 0;
char
*
parallel_config
=
NULL
;
char
*
parallel_config
=
NULL
;
char
*
worker_config
=
NULL
;
char
*
worker_config
=
NULL
;
char
*
usrp_args
=
NULL
;
char
*
usrp_clksrc
=
NULL
;
static
THREAD_STRUCT
thread_struct
;
static
THREAD_STRUCT
thread_struct
;
void
set_parallel_conf
(
char
*
parallel_conf
)
void
set_parallel_conf
(
char
*
parallel_conf
)
{
{
...
@@ -739,6 +742,26 @@ void init_openair0(LTE_DL_FRAME_PARMS *frame_parms,int rxgain) {
...
@@ -739,6 +742,26 @@ void init_openair0(LTE_DL_FRAME_PARMS *frame_parms,int rxgain) {
openair0_cfg
[
card
].
tx_freq
[
i
],
openair0_cfg
[
card
].
tx_freq
[
i
],
openair0_cfg
[
card
].
rx_freq
[
i
]);
openair0_cfg
[
card
].
rx_freq
[
i
]);
}
}
if
(
usrp_args
)
openair0_cfg
[
card
].
sdr_addrs
=
usrp_args
;
if
(
usrp_clksrc
)
{
if
(
strcmp
(
usrp_clksrc
,
"internal"
)
==
0
)
{
openair0_cfg
[
card
].
clock_source
=
internal
;
LOG_D
(
PHY
,
"USRP clock source set as internal
\n
"
);
}
else
if
(
strcmp
(
usrp_clksrc
,
"external"
)
==
0
)
{
openair0_cfg
[
card
].
clock_source
=
external
;
LOG_D
(
PHY
,
"USRP clock source set as external
\n
"
);
}
else
if
(
strcmp
(
usrp_clksrc
,
"gpsdo"
)
==
0
)
{
openair0_cfg
[
card
].
clock_source
=
gpsdo
;
LOG_D
(
PHY
,
"USRP clock source set as gpsdo
\n
"
);
}
else
{
openair0_cfg
[
card
].
clock_source
=
internal
;
LOG_I
(
PHY
,
"USRP clock source unknown ('%s'). defaulting to internal
\n
"
,
usrp_clksrc
);
}
}
else
{
openair0_cfg
[
card
].
clock_source
=
internal
;
LOG_I
(
PHY
,
"USRP clock source not specified. defaulting to internal
\n
"
);
}
}
}
}
}
...
...
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