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
lizhongxiao
OpenXG-RAN
Commits
b64e0324
Commit
b64e0324
authored
Dec 07, 2016
by
Florian Kaltenberger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
code cleanup
parent
98717043
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
41 deletions
+15
-41
targets/RT/USER/lte-softmodem.c
targets/RT/USER/lte-softmodem.c
+15
-41
No files found.
targets/RT/USER/lte-softmodem.c
View file @
b64e0324
...
@@ -1814,8 +1814,6 @@ int main( int argc, char **argv )
...
@@ -1814,8 +1814,6 @@ int main( int argc, char **argv )
rt_sleep_ns
(
10
*
100000000ULL
);
rt_sleep_ns
(
10
*
100000000ULL
);
// start the main thread
if
(
UE_flag
==
1
)
{
if
(
UE_flag
==
1
)
{
init_UE
(
1
);
init_UE
(
1
);
number_of_cards
=
1
;
number_of_cards
=
1
;
...
@@ -1823,66 +1821,42 @@ int main( int argc, char **argv )
...
@@ -1823,66 +1821,42 @@ int main( int argc, char **argv )
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
PHY_vars_UE_g
[
0
][
CC_id
]
->
rf_map
.
card
=
0
;
PHY_vars_UE_g
[
0
][
CC_id
]
->
rf_map
.
card
=
0
;
PHY_vars_UE_g
[
0
][
CC_id
]
->
rf_map
.
chain
=
CC_id
+
chain_offset
;
PHY_vars_UE_g
[
0
][
CC_id
]
->
rf_map
.
chain
=
CC_id
+
chain_offset
;
}
}
else
{
init_eNB
(
node_function
,
node_timing
,
1
,
eth_params
,
single_thread_flag
);
// Sleep to allow all threads to setup
number_of_cards
=
1
;
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
PHY_vars_eNB_g
[
0
][
CC_id
]
->
rf_map
.
card
=
0
;
PHY_vars_eNB_g
[
0
][
CC_id
]
->
rf_map
.
chain
=
CC_id
+
chain_offset
;
}
}
// connect the TX/RX buffers
if
(
UE_flag
==
1
)
{
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
#ifdef OAI_USRP
#ifdef OAI_USRP
UE
[
CC_id
]
->
hw_timing_advance
=
timing_advance
;
PHY_vars_UE_g
[
0
]
[
CC_id
]
->
hw_timing_advance
=
timing_advance
;
#else
#else
UE
[
CC_id
]
->
hw_timing_advance
=
160
;
PHY_vars_UE_g
[
0
]
[
CC_id
]
->
hw_timing_advance
=
160
;
#endif
#endif
}
}
if
(
setup_ue_buffers
(
UE
,
&
openair0_cfg
[
0
])
!=
0
)
{
if
(
setup_ue_buffers
(
UE
,
&
openair0_cfg
[
0
])
!=
0
)
{
printf
(
"Error setting up eNB buffer
\n
"
);
printf
(
"Error setting up eNB buffer
\n
"
);
exit
(
-
1
);
exit
(
-
1
);
}
}
if
(
input_fd
)
{
if
(
input_fd
)
{
printf
(
"Reading in from file to antenna buffer %d
\n
"
,
0
);
printf
(
"Reading in from file to antenna buffer %d
\n
"
,
0
);
if
(
fread
(
UE
[
0
]
->
common_vars
.
rxdata
[
0
],
if
(
fread
(
PHY_vars_UE_g
[
0
]
[
0
]
->
common_vars
.
rxdata
[
0
],
sizeof
(
int32_t
),
sizeof
(
int32_t
),
frame_parms
[
0
]
->
samples_per_tti
*
10
,
frame_parms
[
0
]
->
samples_per_tti
*
10
,
input_fd
)
!=
frame_parms
[
0
]
->
samples_per_tti
*
10
)
input_fd
)
!=
frame_parms
[
0
]
->
samples_per_tti
*
10
)
printf
(
"error reading from file
\n
"
);
printf
(
"error reading from file
\n
"
);
}
}
//p_exmimo_config->framing.tdd_config = TXRXSWITCH_TESTRX;
}
else
{
}
printf
(
"Setting eNB buffer to all-RX
\n
"
);
else
{
init_eNB
(
node_function
,
node_timing
,
1
,
eth_params
,
single_thread_flag
);
// Set LSBs for antenna switch (ExpressMIMO)
// Sleep to allow all threads to setup
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
PHY_vars_eNB_g
[
0
][
CC_id
]
->
hw_timing_advance
=
0
;
number_of_cards
=
1
;
for
(
i
=
0
;
i
<
frame_parms
[
CC_id
]
->
samples_per_tti
*
10
;
i
++
)
for
(
aa
=
0
;
aa
<
frame_parms
[
CC_id
]
->
nb_antennas_tx
;
aa
++
)
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
PHY_vars_eNB_g
[
0
][
CC_id
]
->
common_vars
.
txdata
[
0
][
aa
][
i
]
=
0x00010001
;
PHY_vars_eNB_g
[
0
][
CC_id
]
->
rf_map
.
card
=
0
;
PHY_vars_eNB_g
[
0
][
CC_id
]
->
rf_map
.
chain
=
CC_id
+
chain_offset
;
}
}
}
}
sleep
(
3
);
sleep
(
3
);
printf
(
"Sending sync to all threads
\n
"
);
printf
(
"Sending sync to all threads
\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