Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG UE
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
Michael Black
OpenXG UE
Commits
4ff293c5
Commit
4ff293c5
authored
Jul 22, 2019
by
yilmazt
Browse files
Options
Browse Files
Download
Plain Diff
develop&-nr current as of 22.7.19 & OAI fully ready for testing
parents
95250533
6dc81d8d
Changes
44
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
44 changed files
with
549 additions
and
384 deletions
+549
-384
ci-scripts/conf_files/rcc.band38.tm1.50PRB.multi.rru.conf
ci-scripts/conf_files/rcc.band38.tm1.50PRB.multi.rru.conf
+2
-0
ci-scripts/conf_files/rru.band38.tm1.master.conf
ci-scripts/conf_files/rru.band38.tm1.master.conf
+1
-0
ci-scripts/conf_files/rru.band38.tm1.slave.conf
ci-scripts/conf_files/rru.band38.tm1.slave.conf
+1
-0
ci-scripts/main.py
ci-scripts/main.py
+179
-134
ci-scripts/oai-ci-vm-tool
ci-scripts/oai-ci-vm-tool
+3
-1
ci-scripts/xml_files/enb_usrp210_band7_test_10mhz_tm1.xml
ci-scripts/xml_files/enb_usrp210_band7_test_10mhz_tm1.xml
+1
-1
ci-scripts/xml_files/enb_usrp210_band7_test_10mhz_tm1_cdrx.xml
...ripts/xml_files/enb_usrp210_band7_test_10mhz_tm1_cdrx.xml
+90
-0
ci-scripts/xml_files/f1_usrp210_band7_test_05mhz.xml
ci-scripts/xml_files/f1_usrp210_band7_test_05mhz.xml
+2
-1
ci-scripts/xml_files/f1_usrp210_band7_test_10mhz.xml
ci-scripts/xml_files/f1_usrp210_band7_test_10mhz.xml
+2
-1
ci-scripts/xml_files/f1_usrp210_band7_test_20mhz.xml
ci-scripts/xml_files/f1_usrp210_band7_test_20mhz.xml
+2
-1
ci-scripts/xml_files/multi_rru_band38_test_10mhz_tm1.xml
ci-scripts/xml_files/multi_rru_band38_test_10mhz_tm1.xml
+1
-0
ci-scripts/xml_files/ue_band20_test_10mhz_orange.xml
ci-scripts/xml_files/ue_band20_test_10mhz_orange.xml
+1
-0
ci-scripts/xml_files/ue_band20_test_10mhz_sfr.xml
ci-scripts/xml_files/ue_band20_test_10mhz_sfr.xml
+1
-0
cmake_targets/CMakeLists.txt
cmake_targets/CMakeLists.txt
+4
-4
common/config/config_paramdesc.h
common/config/config_paramdesc.h
+2
-2
common/config/config_userapi.c
common/config/config_userapi.c
+5
-5
executables/nr-ru.c
executables/nr-ru.c
+45
-34
executables/nr-softmodem-common.h
executables/nr-softmodem-common.h
+1
-1
executables/nr-softmodem.c
executables/nr-softmodem.c
+3
-3
executables/nr-softmodem.h
executables/nr-softmodem.h
+1
-1
executables/nr-uesoftmodem.c
executables/nr-uesoftmodem.c
+4
-3
executables/nr-uesoftmodem.h
executables/nr-uesoftmodem.h
+1
-1
openair1/PHY/INIT/nr_init.c
openair1/PHY/INIT/nr_init.c
+40
-34
openair1/PHY/defs_RU.h
openair1/PHY/defs_RU.h
+4
-0
openair1/SCHED_NR_UE/defs.h
openair1/SCHED_NR_UE/defs.h
+1
-1
openair1/SIMULATION/NR_PHY/dlschsim.c
openair1/SIMULATION/NR_PHY/dlschsim.c
+2
-3
openair1/SIMULATION/NR_PHY/pbchsim.c
openair1/SIMULATION/NR_PHY/pbchsim.c
+1
-1
openair1/SIMULATION/NR_PHY/pucchsim.c
openair1/SIMULATION/NR_PHY/pucchsim.c
+1
-5
openair1/SIMULATION/NR_PHY/ulschsim.c
openair1/SIMULATION/NR_PHY/ulschsim.c
+1
-1
openair1/SIMULATION/NR_PHY/ulsim.c
openair1/SIMULATION/NR_PHY/ulsim.c
+12
-32
openair2/ENB_APP/enb_paramdef.h
openair2/ENB_APP/enb_paramdef.h
+10
-7
openair2/LAYER2/MAC/config.c
openair2/LAYER2/MAC/config.c
+26
-25
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
+35
-39
openair2/LAYER2/NR_MAC_gNB/nr_mac_common.c
openair2/LAYER2/NR_MAC_gNB/nr_mac_common.c
+24
-8
openair2/LAYER2/PDCP_v10.1.0/pdcp.h
openair2/LAYER2/PDCP_v10.1.0/pdcp.h
+3
-2
openair2/NETWORK_DRIVER/UE_IP/local.h
openair2/NETWORK_DRIVER/UE_IP/local.h
+3
-3
openair2/RRC/NR/nr_rrc_defs.h
openair2/RRC/NR/nr_rrc_defs.h
+2
-2
targets/ARCH/USRP/USERSPACE/LIB/usrp_lib.cpp
targets/ARCH/USRP/USERSPACE/LIB/usrp_lib.cpp
+7
-7
targets/RT/USER/lte-enb.c
targets/RT/USER/lte-enb.c
+5
-5
targets/RT/USER/lte-ru.c
targets/RT/USER/lte-ru.c
+13
-7
targets/RT/USER/lte-softmodem-common.c
targets/RT/USER/lte-softmodem-common.c
+0
-1
targets/RT/USER/lte-softmodem.h
targets/RT/USER/lte-softmodem.h
+4
-5
targets/RT/USER/lte-ue.c
targets/RT/USER/lte-ue.c
+1
-1
targets/RT/USER/ru_control.c
targets/RT/USER/ru_control.c
+2
-2
No files found.
ci-scripts/conf_files/rcc.band38.tm1.50PRB.multi.rru.conf
View file @
4ff293c5
...
...
@@ -193,6 +193,7 @@ RUs = (
att_rx
=
20
;
eNB_instances
= [
0
];
is_slave
=
"no"
;
ota_sync_enabled
=
"yes"
;
},
{
local_if_name
=
"enp129s0f0"
;
...
...
@@ -210,6 +211,7 @@ RUs = (
att_rx
=
20
;
eNB_instances
= [
0
];
is_slave
=
"yes"
;
ota_sync_enabled
=
"yes"
;
}
);
...
...
ci-scripts/conf_files/rru.band38.tm1.master.conf
View file @
4ff293c5
...
...
@@ -15,6 +15,7 @@ RUs = (
max_rxgain
=
100
;
bands
= [
38
];
is_slave
=
"no"
;
ota_sync_enabled
=
"yes"
;
}
);
...
...
ci-scripts/conf_files/rru.band38.tm1.slave.conf
View file @
4ff293c5
...
...
@@ -15,6 +15,7 @@ RUs = (
max_rxgain
=
100
;
bands
= [
38
];
is_slave
=
"yes"
;
ota_sync_enabled
=
"yes"
;
}
);
...
...
ci-scripts/main.py
View file @
4ff293c5
This diff is collapsed.
Click to expand it.
ci-scripts/oai-ci-vm-tool
View file @
4ff293c5
...
...
@@ -167,7 +167,7 @@ function variant__v2__basic_sim {
}
function
variant__v3__phy_sim
{
NB_PATTERN_FILES
=
3
NB_PATTERN_FILES
=
12
BUILD_OPTIONS
=
"--phy_simulators"
RUN_OPTIONS
=
"./run_exec_autotests.bash -g
\"
01510*
\"
-q -np -b"
}
...
...
@@ -195,6 +195,7 @@ function variant__v7__enb_ethernet {
NB_PATTERN_FILES
=
8
BUILD_OPTIONS
=
"--eNB"
}
function
variant__v8__ue_ethernet
{
VM_MEMORY
=
4096
ARCHIVES_LOC
=
ue_eth
...
...
@@ -208,6 +209,7 @@ function variant__v10__flexran_rtc {
BUILD_OPTIONS
=
"cmake . && make -j2"
VARIANT_INFO
=
"non-OSA"
}
function
variant__v20__l1_sim
{
ARCHIVES_LOC
=
l1_sim
RUN_OPTIONS
=
"complex"
...
...
ci-scripts/xml_files/enb_usrp210_band7_test_10mhz_tm1.xml
View file @
4ff293c5
...
...
@@ -34,7 +34,7 @@
<testCase
id=
"030111"
>
<class>
Initialize_eNB
</class>
<desc>
Initialize eNB (FDD/Band7/10MHz)
</desc>
<Initialize_eNB_args>
-O ci-scripts/conf_files/enb.band7.tm1.50PRB.usrpb210.conf
</Initialize_eNB_args>
<Initialize_eNB_args>
-O ci-scripts/conf_files/enb.band7.tm1.50PRB.usrpb210.conf
--eNBs.[0].component_carriers.[0].drx_Config_present prRelease
</Initialize_eNB_args>
</testCase>
<testCase
id=
"030201"
>
...
...
ci-scripts/xml_files/enb_usrp210_band7_test_10mhz_tm1_cdrx.xml
0 → 100644
View file @
4ff293c5
<!--
Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The OpenAirInterface Software Alliance licenses this file to You under
the OAI Public License, Version 1.1 (the "License"); you may not use this file
except in compliance with the License.
You may obtain a copy of the License at
http://www.openairinterface.org/?page_id=698
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
For more information about the OpenAirInterface (OAI) Software Alliance:
contact@openairinterface.org
-->
<testCaseList>
<htmlTabRef>
test-10-cdrx-tm1
</htmlTabRef>
<htmlTabName>
Test-10MHz-CDRX-TM1
</htmlTabName>
<htmlTabIcon>
tasks
</htmlTabIcon>
<repeatCount>
4
</repeatCount>
<TestCaseRequestedList>
030201
040101
030112 040302 040512 040612 040650 040401 040201 030201
</TestCaseRequestedList>
<TestCaseExclusionList></TestCaseExclusionList>
<testCase
id=
"030112"
>
<class>
Initialize_eNB
</class>
<desc>
Initialize eNB (FDD/Band7/10MHz) with CDRX
</desc>
<Initialize_eNB_args>
-O ci-scripts/conf_files/enb.band7.tm1.50PRB.usrpb210.conf --eNBs.[0].component_carriers.[0].drx_Config_present prSetup
</Initialize_eNB_args>
</testCase>
<testCase
id=
"030201"
>
<class>
Terminate_eNB
</class>
<desc>
Terminate eNB
</desc>
</testCase>
<testCase
id=
"040101"
>
<class>
Initialize_UE
</class>
<desc>
Initialize UE
</desc>
</testCase>
<testCase
id=
"040201"
>
<class>
Terminate_UE
</class>
<desc>
Terminate UE
</desc>
</testCase>
<testCase
id=
"040302"
>
<class>
Attach_UE
</class>
<desc>
Attach UE
</desc>
<nbMaxUEtoAttach>
1
</nbMaxUEtoAttach>
</testCase>
<testCase
id=
"040401"
>
<class>
Detach_UE
</class>
<desc>
Detach UE
</desc>
</testCase>
<testCase
id=
"040512"
>
<class>
Ping
</class>
<desc>
ping (10MHz - 20 sec)
</desc>
<ping_args>
-c 20
</ping_args>
<ping_packetloss_threshold>
5
</ping_packetloss_threshold>
</testCase>
<testCase
id=
"040612"
>
<class>
Iperf
</class>
<desc>
iperf (10MHz - DL/30Mbps/UDP)(30 sec)(balanced profile)
</desc>
<iperf_args>
-u -b 30M -t 30 -i 1
</iperf_args>
<iperf_packetloss_threshold>
50
</iperf_packetloss_threshold>
<iperf_profile>
balanced
</iperf_profile>
</testCase>
<testCase
id=
"040650"
>
<class>
Iperf
</class>
<desc>
iperf (10MHz - UL/20Mbps/UDP)(30 sec)(balanced profile)
</desc>
<iperf_args>
-u -b 20M -t 30 -i 1 -R
</iperf_args>
<iperf_packetloss_threshold>
50
</iperf_packetloss_threshold>
<iperf_profile>
balanced
</iperf_profile>
</testCase>
</testCaseList>
ci-scripts/xml_files/f1_usrp210_band7_test_05mhz.xml
View file @
4ff293c5
...
...
@@ -22,8 +22,9 @@
-->
<testCaseList>
<htmlTabRef>
test-f1-05
</htmlTabRef>
<htmlTabName>
Test-F1-CU
/
DU-05MHz
</htmlTabName>
<htmlTabName>
Test-F1-CU
-
DU-05MHz
</htmlTabName>
<htmlTabIcon>
tasks
</htmlTabIcon>
<repeatCount>
4
</repeatCount>
<TestCaseRequestedList>
030201
040101
...
...
ci-scripts/xml_files/f1_usrp210_band7_test_10mhz.xml
View file @
4ff293c5
...
...
@@ -22,8 +22,9 @@
-->
<testCaseList>
<htmlTabRef>
test-f1-10
</htmlTabRef>
<htmlTabName>
Test-F1-CU
/
DU-10MHz
</htmlTabName>
<htmlTabName>
Test-F1-CU
-
DU-10MHz
</htmlTabName>
<htmlTabIcon>
tasks
</htmlTabIcon>
<repeatCount>
4
</repeatCount>
<TestCaseRequestedList>
030201
040101
...
...
ci-scripts/xml_files/f1_usrp210_band7_test_20mhz.xml
View file @
4ff293c5
...
...
@@ -22,8 +22,9 @@
-->
<testCaseList>
<htmlTabRef>
test-f1-20
</htmlTabRef>
<htmlTabName>
Test-F1-CU
/
DU-20MHz
</htmlTabName>
<htmlTabName>
Test-F1-CU
-
DU-20MHz
</htmlTabName>
<htmlTabIcon>
tasks
</htmlTabIcon>
<repeatCount>
4
</repeatCount>
<TestCaseRequestedList>
030201
040101
...
...
ci-scripts/xml_files/multi_rru_band38_test_10mhz_tm1.xml
View file @
4ff293c5
...
...
@@ -24,6 +24,7 @@
<htmlTabRef>
test-multi-rru-10
</htmlTabRef>
<htmlTabName>
Test-Multi-RRU-10MHz
</htmlTabName>
<htmlTabIcon>
tasks
</htmlTabIcon>
<repeatCount>
4
</repeatCount>
<TestCaseRequestedList>
030211 030212 030213
030111 030112 030113
...
...
ci-scripts/xml_files/ue_band20_test_10mhz_orange.xml
View file @
4ff293c5
...
...
@@ -24,6 +24,7 @@
<htmlTabRef>
test-10mhz-orange
</htmlTabRef>
<htmlTabName>
Test-10Mhz-Orange
</htmlTabName>
<htmlTabIcon>
tasks
</htmlTabIcon>
<repeatCount>
4
</repeatCount>
<TestCaseRequestedList>
090109
090110 000001 090109
...
...
ci-scripts/xml_files/ue_band20_test_10mhz_sfr.xml
View file @
4ff293c5
...
...
@@ -24,6 +24,7 @@
<htmlTabRef>
test-10mHz-sfr
</htmlTabRef>
<htmlTabName>
Test-10MHz-SFR
</htmlTabName>
<htmlTabIcon>
tasks
</htmlTabIcon>
<repeatCount>
4
</repeatCount>
<TestCaseRequestedList>
090109
090111 000001 090109
...
...
cmake_targets/CMakeLists.txt
View file @
4ff293c5
...
...
@@ -2645,21 +2645,21 @@ add_executable(nr_dlschsim
${
OPENAIR_DIR
}
/common/utils/backtrace.c
${
OPENAIR_DIR
}
/common/utils/system.c
${
T_SOURCE
}
)
target_link_libraries
(
nr_dlschsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB -Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
target_link_libraries
(
nr_dlschsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB
MAC_NR_COMMON
-Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
add_executable
(
nr_pbchsim
${
OPENAIR1_DIR
}
/SIMULATION/NR_PHY/pbchsim.c
${
OPENAIR_DIR
}
/common/utils/backtrace.c
${
OPENAIR_DIR
}
/common/utils/system.c
${
T_SOURCE
}
)
target_link_libraries
(
nr_pbchsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB -Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
target_link_libraries
(
nr_pbchsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB
MAC_NR_COMMON
-Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
#PUCCH ---> Prashanth
add_executable
(
nr_pucchsim
${
OPENAIR1_DIR
}
/SIMULATION/NR_PHY/pucchsim.c
${
OPENAIR_DIR
}
/common/utils/backtrace.c
${
T_SOURCE
}
)
target_link_libraries
(
nr_pucchsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB -Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
target_link_libraries
(
nr_pucchsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB
MAC_NR_COMMON
-Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
#PUCCH ---> Prashanth
add_executable
(
nr_dlsim
...
...
@@ -2673,7 +2673,7 @@ add_executable(nr_ulschsim
${
OPENAIR1_DIR
}
/SIMULATION/NR_PHY/ulschsim.c
${
OPENAIR_DIR
}
/common/utils/backtrace.c
${
T_SOURCE
}
)
target_link_libraries
(
nr_ulschsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB -Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
target_link_libraries
(
nr_ulschsim -Wl,--start-group UTIL SIMU PHY_COMMON PHY_NR PHY_NR_UE SCHED_NR_LIB CONFIG_LIB
MAC_NR_COMMON
-Wl,--end-group m pthread
${
ATLAS_LIBRARIES
}
${
T_LIB
}
dl
)
add_executable
(
nr_ulsim
${
OPENAIR1_DIR
}
/SIMULATION/NR_PHY/ulsim.c
...
...
common/config/config_paramdesc.h
View file @
4ff293c5
...
...
@@ -101,8 +101,8 @@ typedef struct paramdef {
char
*
helpstr
;
/* help string */
unsigned
int
paramflags
;
/* value is a "ored" combination of above PARAMFLAG_XXXX values */
union
{
/* pointer to the parameter value, completed by the config module */
char
**
strptr
;
char
**
strlistptr
;
char
**
strptr
;
char
**
strlistptr
;
uint8_t
*
u8ptr
;
int8_t
*
i8ptr
;
uint16_t
*
u16ptr
;
...
...
common/config/config_userapi.c
View file @
4ff293c5
...
...
@@ -184,7 +184,7 @@ void config_printhelp(paramdef_t *params,int numparams, char *prefix) {
printf
(
"--------------------------------------------------------------------
\n\n
"
);
}
int
config_execcheck
(
paramdef_t
*
params
,
int
numparams
,
char
*
prefix
)
{
int
config_execcheck
(
paramdef_t
*
params
,
int
numparams
,
char
*
prefix
)
{
int
st
=
0
;
for
(
int
i
=
0
;
i
<
numparams
;
i
++
)
{
...
...
@@ -204,7 +204,7 @@ int config_execcheck(paramdef_t *params,int numparams, char *prefix) {
return
st
;
}
int
config_get
(
paramdef_t
*
params
,
int
numparams
,
char
*
prefix
)
{
int
config_get
(
paramdef_t
*
params
,
int
numparams
,
char
*
prefix
)
{
int
ret
=
-
1
;
if
(
CONFIG_ISFLAGSET
(
CONFIG_ABORT
))
{
...
...
@@ -215,11 +215,11 @@ int config_get(paramdef_t *params,int numparams, char *prefix) {
configmodule_interface_t
*
cfgif
=
config_get_if
();
if
(
cfgif
!=
NULL
)
{
ret
=
config_get_if
()
->
get
(
params
,
numparams
,
prefix
);
ret
=
config_get_if
()
->
get
(
params
,
numparams
,
prefix
);
if
(
ret
>=
0
)
{
config_process_cmdline
(
params
,
numparams
,
prefix
);
config_execcheck
(
params
,
numparams
,
prefix
);
config_process_cmdline
(
params
,
numparams
,
prefix
);
config_execcheck
(
params
,
numparams
,
prefix
);
}
return
ret
;
...
...
executables/nr-ru.c
View file @
4ff293c5
This diff is collapsed.
Click to expand it.
executables/nr-softmodem-common.h
View file @
4ff293c5
...
...
@@ -103,7 +103,7 @@
/* optname helpstr paramflags XXXptr defXXXval type numelt */
/*--------------------------------------------------------------------------------------------------------------------------------*/
#define START_MSC softmodem_params.start_msc
#define CMDLINE_LOGPARAMS_DESC { \
#define CMDLINE_LOGPARAMS_DESC
_NR
{ \
{"R" , CONFIG_HLP_FLOG, 0, uptr:&online_log_messages, defintval:1, TYPE_INT, 0}, \
{"g" , CONFIG_HLP_LOGL, 0, uptr:&glog_level, defintval:0, TYPE_UINT, 0}, \
{"G" , CONFIG_HLP_LOGV, 0, uptr:&glog_verbosity, defintval:0, TYPE_UINT16, 0}, \
...
...
executables/nr-softmodem.c
View file @
4ff293c5
...
...
@@ -126,7 +126,7 @@ unsigned char NB_gNB_INST = 1;
int
UE_scan
=
1
;
int
UE_scan_carrier
=
0
;
runmode_t
mode
=
normal_txrx
;
double
snr_dB
=
20
;
static
double
snr_dB
=
20
;
FILE
*
input_fd
=
NULL
;
...
...
@@ -510,7 +510,7 @@ static void get_options(void) {
uint32_t
glog_level
,
glog_verbosity
;
uint32_t
start_telnetsrv
;
paramdef_t
cmdline_params
[]
=
CMDLINE_PARAMS_DESC_GNB
;
paramdef_t
cmdline_logparams
[]
=
CMDLINE_LOGPARAMS_DESC
;
paramdef_t
cmdline_logparams
[]
=
CMDLINE_LOGPARAMS_DESC
_NR
;
config_process_cmdline
(
cmdline_params
,
sizeof
(
cmdline_params
)
/
sizeof
(
paramdef_t
),
NULL
);
if
(
strlen
(
in_path
)
>
0
)
{
...
...
@@ -1047,7 +1047,7 @@ int main( int argc, char **argv )
if
(
RC
.
nb_RU
>
0
)
{
printf
(
"Initializing RU threads
\n
"
);
init_RU
(
rf_config_file
);
init_
NR_
RU
(
rf_config_file
);
for
(
ru_id
=
0
;
ru_id
<
RC
.
nb_RU
;
ru_id
++
)
{
RC
.
ru
[
ru_id
]
->
rf_map
.
card
=
0
;
...
...
executables/nr-softmodem.h
View file @
4ff293c5
...
...
@@ -67,7 +67,7 @@ extern void stop_gNB(int);
extern
void
kill_gNB_proc
(
int
inst
);
// In nr-ru.c
extern
void
init_RU
(
char
*
);
extern
void
init_
NR_
RU
(
char
*
);
extern
void
init_RU_proc
(
RU_t
*
ru
);
extern
void
stop_RU
(
int
nb_ru
);
extern
void
kill_NR_RU_proc
(
int
inst
);
...
...
executables/nr-uesoftmodem.c
View file @
4ff293c5
...
...
@@ -48,6 +48,7 @@
#include "LAYER2/MAC/mac_proto.h"
#include "RRC/LTE/rrc_vars.h"
#include "PHY_INTERFACE/phy_interface_vars.h"
#include "openair1/SIMULATION/TOOLS/sim.h"
#ifdef SMBV
#include "PHY/TOOLS/smbv.h"
...
...
@@ -112,9 +113,9 @@ volatile int start_eNB = 0;
volatile
int
start_UE
=
0
;
volatile
int
oai_exit
=
0
;
static
clock_source_t
clock_source
=
internal
;
static
clock_source_t
clock_source
=
internal
;
int
single_thread_flag
=
1
;
double
snr_dB
=
20
;
static
double
snr_dB
=
20
;
int
threequarter_fs
=
0
;
...
...
@@ -409,7 +410,7 @@ static void get_options(void) {
uint32_t
glog_level
,
glog_verbosity
;
uint32_t
start_telnetsrv
=
0
;
paramdef_t
cmdline_params
[]
=
CMDLINE_PARAMS_DESC_UE
;
paramdef_t
cmdline_logparams
[]
=
CMDLINE_LOGPARAMS_DESC
;
paramdef_t
cmdline_logparams
[]
=
CMDLINE_LOGPARAMS_DESC
_NR
;
config_process_cmdline
(
cmdline_params
,
sizeof
(
cmdline_params
)
/
sizeof
(
paramdef_t
),
NULL
);
if
(
strlen
(
in_path
)
>
0
)
{
...
...
executables/nr-uesoftmodem.h
View file @
4ff293c5
...
...
@@ -71,7 +71,7 @@
{"A" , CONFIG_HLP_TADV, 0, uptr:&timing_advance, defintval:0, TYPE_UINT, 0}, \
{"C" , CONFIG_HLP_DLF, 0, uptr:&(downlink_frequency[0][0]), defuintval:2680000000, TYPE_UINT, 0}, \
{"a" , CONFIG_HLP_CHOFF, 0, iptr:&chain_offset, defintval:0, TYPE_INT, 0}, \
{"d" , CONFIG_HLP_SOFTS, PARAMFLAG_BOOL,
i
ptr:&do_forms, defintval:0, TYPE_INT, 0}, \
{"d" , CONFIG_HLP_SOFTS, PARAMFLAG_BOOL,
u
ptr:&do_forms, defintval:0, TYPE_INT, 0}, \
{"E" , CONFIG_HLP_TQFS, PARAMFLAG_BOOL, iptr:&threequarter_fs, defintval:0, TYPE_INT, 0}, \
{"m" , CONFIG_HLP_DLMCS, 0, uptr:&target_dl_mcs, defintval:0, TYPE_UINT, 0}, \
{"t" , CONFIG_HLP_ULMCS, 0, uptr:&target_ul_mcs, defintval:0, TYPE_UINT, 0}, \
...
...
openair1/PHY/INIT/nr_init.c
View file @
4ff293c5
...
...
@@ -37,32 +37,33 @@
#include "PHY/NR_TRANSPORT/nr_ulsch.h"
#include "PHY/NR_REFSIG/nr_refsig.h"
#include "SCHED_NR/fapi_nr_l1.h"
#include "openair2/LAYER2/NR_MAC_gNB/mac_proto.h"
/*
extern uint32_t from_nrarfcn(int nr_bandP,uint32_t dl_nrarfcn);
extern
int32_t
get_
uldl_offset
(
int
nr_bandP
);
extern int32_t get_
nr_uldl_offset(int nr_bandP);*/
extern
openair0_config_t
openair0_cfg
[
MAX_CARDS
];
int
l1_north_init_gNB
()
{
int
i
,
j
;
int
l1_north_init_gNB
()
{
if
(
RC
.
nb_nr_L1_inst
>
0
&&
RC
.
nb_nr_L1_CC
!=
NULL
&&
RC
.
gNB
!=
NULL
)
{
AssertFatal
(
RC
.
nb_nr_L1_inst
>
0
,
"nb_nr_L1_inst=%d
\n
"
,
RC
.
nb_nr_L1_inst
);
AssertFatal
(
RC
.
nb_nr_L1_CC
!=
NULL
,
"nb_nr_L1_CC is null
\n
"
);
AssertFatal
(
RC
.
gNB
!=
NULL
,
"RC.gNB is null
\n
"
);
LOG_I
(
PHY
,
"%s() RC.nb_nr_L1_inst:%d
\n
"
,
__FUNCTION__
,
RC
.
nb_nr_L1_inst
);
for
(
i
=
0
;
i
<
RC
.
nb_nr_L1_inst
;
i
++
)
{
for
(
i
nt
i
=
0
;
i
<
RC
.
nb_nr_L1_inst
;
i
++
)
{
AssertFatal
(
RC
.
gNB
[
i
]
!=
NULL
,
"RC.gNB[%d] is null
\n
"
,
i
);
AssertFatal
(
RC
.
nb_nr_L1_CC
[
i
]
>
0
,
"RC.nb_nr_L1_CC[%d]=%d
\n
"
,
i
,
RC
.
nb_nr_L1_CC
[
i
]);
LOG_I
(
PHY
,
"%s() RC.nb_nr_L1_CC[%d]:%d
\n
"
,
__FUNCTION__
,
i
,
RC
.
nb_nr_L1_CC
[
i
]);
for
(
j
=
0
;
j
<
RC
.
nb_nr_L1_CC
[
i
];
j
++
)
{
for
(
int
j
=
0
;
j
<
RC
.
nb_nr_L1_CC
[
i
];
j
++
)
{
AssertFatal
(
RC
.
gNB
[
i
][
j
]
!=
NULL
,
"RC.gNB[%d][%d] is null
\n
"
,
i
,
j
);
if
((
RC
.
gNB
[
i
][
j
]
->
if_inst
=
NR_IF_Module_init
(
i
))
<
0
)
return
(
-
1
);
LOG_I
(
PHY
,
"%s() RC.gNB[%d][%d] installing callbacks
\n
"
,
__FUNCTION__
,
i
,
j
);
RC
.
gNB
[
i
][
j
]
->
if_inst
->
NR_PHY_config_req
=
nr_phy_config_request
;
RC
.
gNB
[
i
][
j
]
->
if_inst
->
NR_PHY_config_req
=
nr_phy_config_request
;
RC
.
gNB
[
i
][
j
]
->
if_inst
->
NR_Schedule_response
=
nr_schedule_response
;
}
}
...
...
@@ -356,41 +357,46 @@ void install_schedule_handlers(IF_Module_t *if_inst)
/// this function is a temporary addition for NR configuration
void
nr_phy_config_request_sim
(
PHY_VARS_gNB
*
gNB
,
int
N_RB_DL
,
int
N_RB_UL
,
int
mu
,
int
Nid_cell
,
uint64_t
position_in_burst
)
{
NR_DL_FRAME_PARMS
*
fp
=
&
gNB
->
frame_parms
;
nfapi_nr_config_request_t
*
gNB_config
=
&
gNB
->
gNB_config
;
void
nr_phy_config_request_sim
(
PHY_VARS_gNB
*
gNB
,
int
N_RB_DL
,
int
N_RB_UL
,
int
mu
,
int
Nid_cell
,
uint64_t
position_in_burst
)
{
NR_DL_FRAME_PARMS
*
fp
=
&
gNB
->
frame_parms
;
nfapi_nr_config_request_t
*
gNB_config
=
&
gNB
->
gNB_config
;
//overwrite for new NR parameters
gNB_config
->
nfapi_config
.
rf_bands
.
rf_band
[
0
]
=
78
;
gNB_config
->
nfapi_config
.
nrarfcn
.
value
=
620000
;
gNB_config
->
subframe_config
.
numerology_index_mu
.
value
=
mu
;
gNB_config
->
subframe_config
.
duplex_mode
.
value
=
TDD
;
gNB_config
->
rf_config
.
dl_carrier_bandwidth
.
value
=
N_RB_DL
;
gNB_config
->
rf_config
.
ul_carrier_bandwidth
.
value
=
N_RB_UL
;
gNB_config
->
sch_config
.
half_frame_index
.
value
=
0
;
gNB_config
->
sch_config
.
ssb_subcarrier_offset
.
value
=
0
;
gNB_config
->
sch_config
.
n_ssb_crb
.
value
=
(
N_RB_DL
-
20
);
gNB_config
->
sch_config
.
ssb_subcarrier_offset
.
value
=
0
;
gNB_config
->
sch_config
.
physical_cell_id
.
value
=
Nid_cell
;
gNB_config
->
sch_config
.
ssb_scg_position_in_burst
.
value
=
position_in_burst
;
gNB_config
->
nfapi_config
.
rf_bands
.
rf_band
[
0
]
=
78
;
gNB_config
->
nfapi_config
.
nrarfcn
.
value
=
620000
;
gNB_config
->
subframe_config
.
numerology_index_mu
.
value
=
mu
;
gNB_config
->
subframe_config
.
duplex_mode
.
value
=
TDD
;
gNB_config
->
rf_config
.
dl_carrier_bandwidth
.
value
=
N_RB_DL
;
gNB_config
->
rf_config
.
ul_carrier_bandwidth
.
value
=
N_RB_UL
;
gNB_config
->
sch_config
.
half_frame_index
.
value
=
0
;
gNB_config
->
sch_config
.
ssb_subcarrier_offset
.
value
=
0
;
gNB_config
->
sch_config
.
n_ssb_crb
.
value
=
(
N_RB_DL
-
20
);
gNB_config
->
sch_config
.
ssb_subcarrier_offset
.
value
=
0
;
gNB_config
->
sch_config
.
physical_cell_id
.
value
=
Nid_cell
;
gNB_config
->
sch_config
.
ssb_scg_position_in_burst
.
value
=
position_in_burst
;
gNB_config
->
subframe_config
.
dl_cyclic_prefix_type
.
value
=
(
fp
->
Ncp
==
NORMAL
)
?
NFAPI_CP_NORMAL
:
NFAPI_CP_EXTENDED
;
gNB
->
mac_enabled
=
1
;
gNB
->
mac_enabled
=
1
;
fp
->
dl_CarrierFreq
=
3500000000
;
//from_nrarfcn(gNB_config->nfapi_config.rf_bands.rf_band[0],gNB_config->nfapi_config.nrarfcn.value);
fp
->
ul_CarrierFreq
=
3500000000
;
//fp->dl_CarrierFreq - (get_uldl_offset(gNB_config->nfapi_config.rf_bands.rf_band[0])*100000);
fp
->
threequarter_fs
=
0
;
fp
->
threequarter_fs
=
0
;
nr_init_frame_parms
(
gNB_config
,
fp
);
gNB
->
configured
=
1
;
gNB
->
configured
=
1
;
LOG_I
(
PHY
,
"gNB configured
\n
"
);
}
void
nr_phy_config_request
(
NR_PHY_Config_t
*
phy_config
)
{
uint8_t
Mod_id
=
phy_config
->
Mod_id
;
int
CC_id
=
phy_config
->
CC_id
;
NR_DL_FRAME_PARMS
*
fp
=
&
RC
.
gNB
[
Mod_id
][
CC_id
]
->
frame_parms
;
nfapi_nr_config_request_t
*
gNB_config
=
&
RC
.
gNB
[
Mod_id
][
CC_id
]
->
gNB_config
;
void
nr_phy_config_request
(
NR_PHY_Config_t
*
phy_config
)
{
uint8_t
Mod_id
=
phy_config
->
Mod_id
;
int
CC_id
=
phy_config
->
CC_id
;
NR_DL_FRAME_PARMS
*
fp
=
&
RC
.
gNB
[
Mod_id
][
CC_id
]
->
frame_parms
;
nfapi_nr_config_request_t
*
gNB_config
=
&
RC
.
gNB
[
Mod_id
][
CC_id
]
->
gNB_config
;
gNB_config
->
nfapi_config
.
rf_bands
.
rf_band
[
0
]
=
phy_config
->
cfg
->
nfapi_config
.
rf_bands
.
rf_band
[
0
];
//22
gNB_config
->
nfapi_config
.
nrarfcn
.
value
=
phy_config
->
cfg
->
nfapi_config
.
nrarfcn
.
value
;
//6600
gNB_config
->
subframe_config
.
numerology_index_mu
.
value
=
phy_config
->
cfg
->
subframe_config
.
numerology_index_mu
.
value
;
//1
...
...
@@ -401,7 +407,7 @@ void nr_phy_config_request(NR_PHY_Config_t *phy_config) {
gNB_config
->
sch_config
.
n_ssb_crb
.
value
=
(
phy_config
->
cfg
->
rf_config
.
dl_carrier_bandwidth
.
value
-
20
);
gNB_config
->
sch_config
.
physical_cell_id
.
value
=
phy_config
->
cfg
->
sch_config
.
physical_cell_id
.
value
;
gNB_config
->
sch_config
.
ssb_scg_position_in_burst
.
value
=
phy_config
->
cfg
->
sch_config
.
ssb_scg_position_in_burst
.
value
;
gNB_config
->
sch_config
.
ssb_periodicity
.
value
=
phy_config
->
cfg
->
sch_config
.
ssb_periodicity
.
value
;
gNB_config
->
sch_config
.
ssb_periodicity
.
value
=
phy_config
->
cfg
->
sch_config
.
ssb_periodicity
.
value
;
if
(
phy_config
->
cfg
->
subframe_config
.
duplex_mode
.
value
==
0
)
{
gNB_config
->
subframe_config
.
duplex_mode
.
value
=
TDD
;
...
...
@@ -411,7 +417,7 @@ void nr_phy_config_request(NR_PHY_Config_t *phy_config) {
RC
.
gNB
[
Mod_id
][
CC_id
]
->
mac_enabled
=
1
;
fp
->
dl_CarrierFreq
=
from_nrarfcn
(
gNB_config
->
nfapi_config
.
rf_bands
.
rf_band
[
0
],
gNB_config
->
nfapi_config
.
nrarfcn
.
value
);
fp
->
ul_CarrierFreq
=
fp
->
dl_CarrierFreq
-
(
get_uldl_offset
(
gNB_config
->
nfapi_config
.
rf_bands
.
rf_band
[
0
])
*
100000
);
fp
->
ul_CarrierFreq
=
fp
->
dl_CarrierFreq
-
(
get_
nr_
uldl_offset
(
gNB_config
->
nfapi_config
.
rf_bands
.
rf_band
[
0
])
*
100000
);
fp
->
threequarter_fs
=
openair0_cfg
[
0
].
threequarter_fs
;
LOG_I
(
PHY
,
"Configuring MIB for instance %d, CCid %d : (band %d,N_RB_DL %d, N_RB_UL %d, Nid_cell %d,DL freq %u)
\n
"
,
Mod_id
,
...
...
openair1/PHY/defs_RU.h
View file @
4ff293c5
...
...
@@ -293,6 +293,8 @@ typedef struct RU_proc_t_s {
pthread_cond_t
cond_eNBs
;
/// condition variable for gNB signal
pthread_cond_t
cond_gNBs
;
/// condition variable for ru_thread
pthread_cond_t
cond_ru_thread
;
/// mutex for RU FH
pthread_mutex_t
mutex_FH
;
pthread_mutex_t
mutex_FH1
;
...
...
@@ -419,6 +421,8 @@ typedef struct RU_t_s{
int
north_out_cnt
;
/// flag to indicate the RU is a slave to another source
int
is_slave
;
/// flag to indicate if the RU has to perform OTA sync
int
ota_sync_enable
;
/// flag to indicate that the RU should generate the DMRS sequence in slot 2 (subframe 1) for OTA synchronization and calibration
int
generate_dmrs_sync
;
/// flag to indicate if the RU has a control channel
...
...
openair1/SCHED_NR_UE/defs.h
View file @
4ff293c5
...
...
@@ -95,7 +95,7 @@
@param *phy_vars_rn pointer to RN variables
*/
void
phy_procedures_UE_lte
(
PHY_VARS_NR_UE
*
ue
,
UE_nr_rxtx_proc_t
*
proc
,
uint8_t
eNB_id
,
uint8_t
abstraction_flag
,
uint8_t
do_pdcch_flag
,
runmode_t
mode
,
relaying_type_t
r_type
);
#if
defined(Rel10) || defined(Rel14
)
#if
(NR_RRC_VERSION >= MAKE_VERSION(10, 0, 0)
)
/*! \brief Top-level entry routine for relay node procedures actinf as UE. This proc will make us of the existing UE procs.
@param last_slot Index of last slot (0-19)
@param next_slot Index of next_slot (0-19)
...
...
openair1/SIMULATION/NR_PHY/dlschsim.c
View file @
4ff293c5
...
...
@@ -81,9 +81,8 @@ int oai_nfapi_nr_dl_config_req(nfapi_nr_dl_config_request_t *dl_config_req) {
return
(
0
);
}
uint32_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_earfcn
)
{
return
(
0
);
}
//uint32_t from_nrarfcn(int nr_bandP, uint32_t dl_earfcn) { return (0); }
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
return
(
0
);
}
...
...
openair1/SIMULATION/NR_PHY/pbchsim.c
View file @
4ff293c5
...
...
@@ -68,7 +68,7 @@ int oai_nfapi_ul_config_req(nfapi_ul_config_request_t *ul_config_req) { return(0
int
oai_nfapi_nr_dl_config_req
(
nfapi_nr_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);}
uint32_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_nrarfcn
)
{
return
(
0
);}
//
uint32_t from_nrarfcn(int nr_bandP,uint32_t dl_nrarfcn) {return(0);}
int32_t
get_uldl_offset
(
int
nr_bandP
)
{
return
(
0
);}
NR_IF_Module_t
*
NR_IF_Module_init
(
int
Mod_id
){
return
(
NULL
);}
...
...
openair1/SIMULATION/NR_PHY/pucchsim.c
View file @
4ff293c5
...
...
@@ -60,14 +60,10 @@ double cpuf;
int
nfapi_mode
=
0
;
int
oai_nfapi_hi_dci0_req
(
nfapi_hi_dci0_request_t
*
hi_dci0_req
)
{
return
(
0
);}
int
oai_nfapi_tx_req
(
nfapi_tx_request_t
*
tx_req
)
{
return
(
0
);
}
int
oai_nfapi_dl_config_req
(
nfapi_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);
}
int
oai_nfapi_ul_config_req
(
nfapi_ul_config_request_t
*
ul_config_req
)
{
return
(
0
);
}
int
oai_nfapi_nr_dl_config_req
(
nfapi_nr_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);}
uint32_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_nrarfcn
)
{
return
(
0
);}
//uint32_t from_nrarfcn(int nr_bandP,uint32_t dl_nrarfcn) {return(0);}
int32_t
get_uldl_offset
(
int
nr_bandP
)
{
return
(
0
);}
NR_IF_Module_t
*
NR_IF_Module_init
(
int
Mod_id
){
return
(
NULL
);}
...
...
openair1/SIMULATION/NR_PHY/ulschsim.c
View file @
4ff293c5
...
...
@@ -69,7 +69,7 @@ int oai_nfapi_tx_req(nfapi_tx_request_t *tx_req) { return (0); }
int
oai_nfapi_dl_config_req
(
nfapi_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);
}
int
oai_nfapi_ul_config_req
(
nfapi_ul_config_request_t
*
ul_config_req
)
{
return
(
0
);
}
int
oai_nfapi_nr_dl_config_req
(
nfapi_nr_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);
}
uint32_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_earfcn
)
{
return
(
0
);
}
//
uint32_t from_nrarfcn(int nr_bandP, uint32_t dl_earfcn) { return (0); }
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
return
(
0
);
}
NR_IF_Module_t
*
NR_IF_Module_init
(
int
Mod_id
)
{
return
(
NULL
);
}
...
...
openair1/SIMULATION/NR_PHY/ulsim.c
View file @
4ff293c5
...
...
@@ -73,36 +73,16 @@ double cpuf;
// dummy functions
int
nfapi_mode
=
0
;
int
oai_nfapi_hi_dci0_req
(
nfapi_hi_dci0_request_t
*
hi_dci0_req
)
{
return
(
0
);
}
int
oai_nfapi_tx_req
(
nfapi_tx_request_t
*
tx_req
)
{
return
(
0
);
}
int
oai_nfapi_dl_config_req
(
nfapi_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);
}
int
oai_nfapi_ul_config_req
(
nfapi_ul_config_request_t
*
ul_config_req
)
{
return
(
0
);
}
int
oai_nfapi_nr_dl_config_req
(
nfapi_nr_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);
}
uint32_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_earfcn
)
{
return
(
0
);
}
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
return
(
0
);
}
int
oai_nfapi_hi_dci0_req
(
nfapi_hi_dci0_request_t
*
hi_dci0_req
)
{
return
(
0
);
}
int
oai_nfapi_tx_req
(
nfapi_tx_request_t
*
tx_req
)
{
return
(
0
);
}
int
oai_nfapi_dl_config_req
(
nfapi_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);
}
int
oai_nfapi_ul_config_req
(
nfapi_ul_config_request_t
*
ul_config_req
)
{
return
(
0
);
}
int
oai_nfapi_nr_dl_config_req
(
nfapi_nr_dl_config_request_t
*
dl_config_req
)
{
return
(
0
);
}
//uint32_t from_nrarfcn(int nr_bandP, uint32_t dl_earfcn) { return (0); }
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
return
(
0
);
}
NR_IF_Module_t
*
NR_IF_Module_init
(
int
Mod_id
)
{
return
(
NULL
);
}
NR_IF_Module_init
(
int
Mod_id
)
{
return
(
NULL
);
}
void
exit_function
(
const
char
*
file
,
const
char
*
function
,
const
int
line
,
const
char
*
s
)
{
const
char
*
msg
=
s
==
NULL
?
"no comment"
:
s
;
...
...
@@ -477,17 +457,17 @@ int main(int argc, char **argv) {
rel15_ul
->
ulsch_pdu_rel15
.
n_layers
=
precod_nbr_layers
;
///////////////////////////////////////////////////
fapi_nr_ul_config_request_t
ul_config
;
/*
fapi_nr_ul_config_request_t ul_config;
//fapi_nr_tx_request_t tx_request;
/*
nr_scheduled_response_t scheduled_response;
nr_scheduled_response_t scheduled_response;
scheduled_response.module_id = 0;
scheduled_response.CC_id = 0;
scheduled_response.frame = frame;
scheduled_response.slot = slot;
scheduled_response.dl_config = NULL;
scheduled_response.ul_config = &ul_config;
scheduled_response.dl_config = NULL;
*/
scheduled_response.dl_config = NULL;
ul_config.sfn_slot = slot;
...
...
@@ -501,7 +481,7 @@ int main(int argc, char **argv) {
ul_config.ul_config_list[0].ulsch_config_pdu.ulsch_pdu_rel15.mcs = Imcs;
ul_config.ul_config_list[0].ulsch_config_pdu.ulsch_pdu_rel15.ndi = 0;
ul_config.ul_config_list[0].ulsch_config_pdu.ulsch_pdu_rel15.rv = 0;
ul_config
.
ul_config_list
[
0
].
ulsch_config_pdu
.
ulsch_pdu_rel15
.
n_layers
=
precod_nbr_layers
;
ul_config.ul_config_list[0].ulsch_config_pdu.ulsch_pdu_rel15.n_layers = precod_nbr_layers;
*/
//there are plenty of other parameters that we don't seem to be using for now. e.g.
//ul_config.ul_config_list[0].ulsch_config_pdu.ulsch_pdu_rel15.absolute_delta_PUSCH = 0;
...
...
openair2/ENB_APP/enb_paramdef.h
View file @
4ff293c5
...
...
@@ -35,15 +35,15 @@
#include "common/config/config_paramdesc.h"
#include "RRC_paramsvalues.h"
#define ENB_CONFIG_STRING_CC_NODE_FUNCTION
"node_function"
#define ENB_CONFIG_STRING_CC_NODE_TIMING
"node_timing"
#define ENB_CONFIG_STRING_CC_NODE_SYNCH_REF
"node_synch_ref"
#define ENB_CONFIG_STRING_CC_NODE_FUNCTION "node_function"
#define ENB_CONFIG_STRING_CC_NODE_TIMING
"node_timing"
#define ENB_CONFIG_STRING_CC_NODE_SYNCH_REF
"node_synch_ref"
// OTG config per ENB-UE DL
#define ENB_CONF_STRING_OTG_CONFIG
"otg_config"
#define ENB_CONF_STRING_OTG_UE_ID
"ue_id"
#define ENB_CONF_STRING_OTG_APP_TYPE
"app_type"
#define ENB_CONF_STRING_OTG_BG_TRAFFIC
"bg_traffic"
#define ENB_CONF_STRING_OTG_CONFIG "otg_config"
#define ENB_CONF_STRING_OTG_UE_ID "ue_id"
#define ENB_CONF_STRING_OTG_APP_TYPE "app_type"
#define ENB_CONF_STRING_OTG_BG_TRAFFIC "bg_traffic"
#ifdef LIBCONFIG_LONG
#define libconfig_int long
...
...
@@ -92,6 +92,7 @@ typedef enum {
#define CONFIG_STRING_RU_SDR_CLK_SRC "clock_src"
#define CONFIG_STRING_RU_SF_EXTENSION "sf_extension"
#define CONFIG_STRING_RU_END_OF_BURST_DELAY "end_of_burst_delay"
#define CONFIG_STRING_RU_OTA_SYNC_ENABLE "ota_sync_enabled"
#define RU_LOCAL_IF_NAME_IDX 0
#define RU_LOCAL_ADDRESS_IDX 1
...
...
@@ -116,6 +117,7 @@ typedef enum {
#define RU_SDR_CLK_SRC 20
#define RU_SF_EXTENSION_IDX 21
#define RU_END_OF_BURST_DELAY_IDX 22
#define RU_OTA_SYNC_ENABLE_IDX 23
...
...
@@ -147,6 +149,7 @@ typedef enum {
{CONFIG_STRING_RU_SDR_CLK_SRC, NULL, 0, strptr:NULL, defstrval:"internal", TYPE_STRING, 0}, \
{CONFIG_STRING_RU_SF_EXTENSION, NULL, 0, uptr:NULL, defuintval:312, TYPE_UINT, 0}, \
{CONFIG_STRING_RU_END_OF_BURST_DELAY, NULL, 0, uptr:NULL, defuintval:400, TYPE_UINT, 0}, \
{CONFIG_STRING_RU_OTA_SYNC_ENABLE, NULL, 0, strptr:NULL, defstrval:"no", TYPE_STRING, 0}, \
}
/*---------------------------------------------------------------------------------------------------------------------------------------*/
...
...
openair2/LAYER2/MAC/config.c
View file @
4ff293c5
...
...
@@ -83,36 +83,36 @@ typedef struct band_info_s {
static
const
eutra_bandentry_t
eutra_bandtable
[]
=
{
{
1
,
19200
,
19800
,
21100
,
21700
,
0
},
{
2
,
18500
,
19100
,
19300
,
19900
,
6000
},
{
3
,
17100
,
17850
,
18050
,
18800
,
12000
},
{
4
,
17100
,
17550
,
21100
,
21550
,
19500
},
{
5
,
8240
,
8490
,
8690
,
8940
,
24000
},
{
6
,
8300
,
8400
,
8750
,
8850
,
26500
},
{
7
,
25000
,
25700
,
26200
,
26900
,
27500
},
{
8
,
8800
,
9150
,
9250
,
9600
,
34500
},
{
9
,
17499
,
17849
,
18449
,
18799
,
38000
},
{
1
,
19200
,
19800
,
21100
,
21700
,
0
},
{
2
,
18500
,
19100
,
19300
,
19900
,
6000
},
{
3
,
17100
,
17850
,
18050
,
18800
,
12000
},
{
4
,
17100
,
17550
,
21100
,
21550
,
19500
},
{
5
,
8240
,
8490
,
8690
,
8940
,
24000
},
{
6
,
8300
,
8400
,
8750
,
8850
,
26500
},
{
7
,
25000
,
25700
,
26200
,
26900
,
27500
},
{
8
,
8800
,
9150
,
9250
,
9600
,
34500
},
{
9
,
17499
,
17849
,
18449
,
18799
,
38000
},
{
10
,
17100
,
17700
,
21100
,
21700
,
41500
},
{
11
,
14279
,
14529
,
14759
,
15009
,
47500
},
{
12
,
6980
,
7160
,
7280
,
7460
,
50100
},
{
13
,
7770
,
7870
,
7460
,
7560
,
51800
},
{
14
,
7880
,
7980
,
7580
,
7680
,
52800
},
{
17
,
7040
,
7160
,
7340
,
7460
,
57300
},
{
18
,
8150
,
9650
,
8600
,
10100
,
58500
},
{
19
,
8300
,
8450
,
8750
,
8900
,
60000
},
{
20
,
8320
,
8620
,
7910
,
8210
,
61500
},
{
12
,
6980
,
7160
,
7280
,
7460
,
50100
},
{
13
,
7770
,
7870
,
7460
,
7560
,
51800
},
{
14
,
7880
,
7980
,
7580
,
7680
,
52800
},
{
17
,
7040
,
7160
,
7340
,
7460
,
57300
},
{
18
,
8150
,
9650
,
8600
,
10100
,
58500
},
{
19
,
8300
,
8450
,
8750
,
8900
,
60000
},
{
20
,
8320
,
8620
,
7910
,
8210
,
61500
},
{
21
,
14479
,
14629
,
14959
,
15109
,
64500
},
{
22
,
34100
,
34900
,
35100
,
35900
,
66000
},
{
23
,
20000
,
20200
,
21800
,
22000
,
75000
},
{
24
,
16126
,
16605
,
15250
,
15590
,
77000
},
{
25
,
18500
,
19150
,
19300
,
19950
,
80400
},
{
26
,
8140
,
8490
,
8590
,
8940
,
86900
},
{
27
,
8070
,
8240
,
8520
,
8690
,
90400
},
{
28
,
7030
,
7580
,
7580
,
8130
,
92100
},
{
29
,
0
,
0
,
7170
,
7280
,
96600
},
{
26
,
8140
,
8490
,
8590
,
8940
,
86900
},
{
27
,
8070
,
8240
,
8520
,
8690
,
90400
},
{
28
,
7030
,
7580
,
7580
,
8130
,
92100
},
{
29
,
0
,
0
,
7170
,
7280
,
96600
},
{
30
,
23050
,
23250
,
23500
,
23600
,
97700
},
{
31
,
45250
,
34900
,
46250
,
35900
,
98700
},
{
32
,
0
,
0
,
14520
,
14960
,
99200
},
{
32
,
0
,
0
,
14520
,
14960
,
99200
},
{
33
,
19000
,
19200
,
19000
,
19200
,
36000
},
{
34
,
20100
,
20250
,
20100
,
20250
,
36200
},
{
35
,
18500
,
19100
,
18500
,
19100
,
36350
},
...
...
@@ -124,13 +124,13 @@ static const eutra_bandentry_t eutra_bandtable[] = {
{
41
,
24960
,
26900
,
24960
,
26900
,
39650
},
{
42
,
34000
,
36000
,
34000
,
36000
,
41590
},
{
43
,
36000
,
38000
,
36000
,
38000
,
43590
},
{
44
,
7030
,
8030
,
7030
,
8030
,
45590
},
{
44
,
7030
,
8030
,
7030
,
8030
,
45590
},
{
45
,
14470
,
14670
,
14470
,
14670
,
46590
},
{
46
,
51500
,
59250
,
51500
,
59250
,
46790
},
{
65
,
19200
,
20100
,
21100
,
22000
,
65536
},
{
66
,
17100
,
18000
,
21100
,
22000
,
66436
},
{
67
,
0
,
0
,
7380
,
7580
,
67336
},
{
68
,
6980
,
7280
,
7530
,
7830
,
67536
}
{
67
,
0
,
0
,
7380
,
7580
,
67336
},
{
68
,
6980
,
7280
,
7530
,
7830
,
67536
}
};
...
...
@@ -216,7 +216,8 @@ uint32_t from_earfcn(int eutra_bandP, uint32_t dl_earfcn) {
}
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
int
i
;
for
(
i
=
0
;
i
<
BANDTABLE_SIZE
&&
eutra_bandtable
[
i
].
band
!=
eutra_bandP
;
i
++
);
...
...
openair2/LAYER2/NR_MAC_gNB/mac_proto.h
View file @
4ff293c5
...
...
@@ -38,16 +38,16 @@ void mac_top_init_gNB(void);
void
config_common
(
int
Mod_idP
,
int
CC_idP
,
int
Nid_cell
,
int
Nid_cell
,
int
nr_bandP
,
uint64_t
ssb_pattern
,
uint16_t
ssb_periodicity
,
uint64_t
ssb_pattern
,
uint16_t
ssb_periodicity
,
uint64_t
dl_CarrierFreqP
,
uint32_t
dl_BandwidthP
);
int
rrc_mac_config_req_gNB
(
module_id_t
Mod_idP
,
int
CC_id
,
int
cellid
,
int
cellid
,
int
p_gNB
,
int
nr_bandP
,
uint64_t
ssb_pattern
,
...
...
@@ -55,8 +55,7 @@ int rrc_mac_config_req_gNB(module_id_t Mod_idP,
uint64_t
dl_CarrierFreqP
,
int
dl_BandwidthP
,
NR_BCCH_BCH_Message_t
*
mib
,
NR_ServingCellConfigCommon_t
*
servingcellconfigcommon
);
NR_ServingCellConfigCommon_t
*
servingcellconfigcommon
);
int
is_nr_UL_slot
(
NR_COMMON_channels_t
*
ccP
,
int
slotP
);
...
...
@@ -65,14 +64,10 @@ void clear_nr_nfapi_information(gNB_MAC_INST * gNB,
frame_t
frameP
,
sub_frame_t
subframeP
);
void
gNB_dlsch_ulsch_scheduler
(
module_id_t
module_idP
,
frame_t
frameP
,
sub_frame_t
subframeP
);
void
gNB_dlsch_ulsch_scheduler
(
module_id_t
module_idP
,
frame_t
frameP
,
sub_frame_t
subframeP
);
void
schedule_nr_mib
(
module_id_t
module_idP
,
frame_t
frameP
,
sub_frame_t
subframeP
);
void
nr_schedule_css_dlsch_phytest
(
module_id_t
module_idP
,
frame_t
frameP
,
sub_frame_t
subframeP
);
...
...
@@ -81,30 +76,29 @@ void nr_schedule_uss_dlsch_phytest(module_id_t module_idP,
frame_t
frameP
,
sub_frame_t
slotP
);
void
nr_configure_css_dci_initial
(
nfapi_nr_dl_config_pdcch_parameters_rel15_t
*
pdcch_params
,
nr_scs_e
scs_common
,
nr_scs_e
pdcch_scs
,
nr_frequency_range_e
freq_range
,
uint8_t
rmsi_pdcch_config
,
uint8_t
ssb_idx
,
uint8_t
k_ssb
,
uint16_t
sfn_ssb
,
uint8_t
n_ssb
,
uint16_t
nb_slots_per_frame
,
uint16_t
N_RB
);
nr_scs_e
scs_common
,
nr_scs_e
pdcch_scs
,
nr_frequency_range_e
freq_range
,
uint8_t
rmsi_pdcch_config
,
uint8_t
ssb_idx
,
uint8_t
k_ssb
,
uint16_t
sfn_ssb
,
uint8_t
n_ssb
,
uint16_t
nb_slots_per_frame
,
uint16_t
N_RB
);
int
nr_is_dci_opportunity
(
nfapi_nr_search_space_t
search_space
,
nfapi_nr_coreset_t
coreset
,
uint16_t
frame
,
uint16_t
slot
,
nfapi_nr_config_request_t
cfg
);
nfapi_nr_coreset_t
coreset
,
uint16_t
frame
,
uint16_t
slot
,
nfapi_nr_config_request_t
cfg
);
void
nr_configure_dci_from_pdcch_config
(
nfapi_nr_dl_config_pdcch_parameters_rel15_t
*
pdcch_params
,
nfapi_nr_coreset_t
*
coreset
,
nfapi_nr_search_space_t
*
search_space
,
nfapi_nr_config_request_t
cfg
,
uint16_t
N_RB
);
nfapi_nr_coreset_t
*
coreset
,
nfapi_nr_search_space_t
*
search_space
,
nfapi_nr_config_request_t
cfg
,
uint16_t
N_RB
);
int
get_dlscs
(
nfapi_nr_config_request_t
*
cfg
);
...
...
@@ -116,20 +110,22 @@ int to_absslot(nfapi_nr_config_request_t *cfg,int frame,int slot);
int
get_symbolsperslot
(
nfapi_nr_config_request_t
*
cfg
);
void
get_band
(
uint32_t
downlink_frequency
,
uint8_t
*
current_band
,
int32_t
*
current_offset
,
lte_frame_type_t
*
current_type
);
void
get_band
(
uint32_t
downlink_frequency
,
uint8_t
*
current_band
,
int32_t
*
current_offset
,
lte_frame_type_t
*
current_type
);
uint64_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_nrarfcn
);
uint32_t
to_nrarfcn
(
int
nr_bandP
,
uint64_t
dl_CarrierFreq
,
uint32_t
bw
);
int32_t
get_nr_uldl_offset
(
int
nr_bandP
);
void
config_nr_mib
(
int
Mod_idP
,
int
CC_idP
,
int
p_gNBP
,
int
subCarrierSpacingCommon
,
uint32_t
ssb_SubcarrierOffset
,
int
dmrs_TypeA_Position
,
uint32_t
pdcch_ConfigSIB1
,
int
cellBarred
,
int
intraFreqReselection
);
int
CC_idP
,
int
p_gNBP
,
int
subCarrierSpacingCommon
,
uint32_t
ssb_SubcarrierOffset
,
int
dmrs_TypeA_Position
,
uint32_t
pdcch_ConfigSIB1
,
int
cellBarred
,
int
intraFreqReselection
);
#endif
/*__LAYER2_NR_MAC_PROTO_H__*/
openair2/LAYER2/NR_MAC_gNB/nr_mac_common.c
View file @
4ff293c5
...
...
@@ -67,8 +67,13 @@ nr_bandentry_t nr_bandtable[] = {
{
86
,
1710000
,
1785000
,
000
,
000
,
20
,
342000
}
};
void
get_band
(
uint32_t
downlink_frequency
,
uint8_t
*
current_band
,
int32_t
*
current_offset
,
lte_frame_type_t
*
current_type
)
{
#define NR_BANDTABLE_SIZE (sizeof(nr_bandtable)/sizeof(nr_bandentry_t))
void
get_band
(
uint32_t
downlink_frequency
,
uint8_t
*
current_band
,
int32_t
*
current_offset
,
lte_frame_type_t
*
current_type
)
{
int
ind
;
int64_t
dl_freq_khz
=
downlink_frequency
/
1000
;
for
(
ind
=
0
;
...
...
@@ -96,9 +101,10 @@ void get_band(uint32_t downlink_frequency, uint8_t *current_band, int32_t *c
}
uint32_t
to_nrarfcn
(
int
nr_bandP
,
uint64_t
dl_CarrierFreq
,
uint32_t
bw
)
uint32_t
to_nrarfcn
(
int
nr_bandP
,
uint64_t
dl_CarrierFreq
,
uint32_t
bw
)
{
uint64_t
dl_CarrierFreq_by_1k
=
dl_CarrierFreq
/
1000
;
int
bw_kHz
=
bw
/
1000
;
...
...
@@ -112,8 +118,7 @@ uint32_t to_nrarfcn(int nr_bandP, uint64_t dl_CarrierFreq, uint32_t bw)
"Band %d, bw %u : DL carrier frequency %llu kHz < %llu
\n
"
,
nr_bandP
,
bw
,
(
long
long
unsigned
int
)
dl_CarrierFreq_by_1k
,
(
long
long
unsigned
int
)
nr_bandtable
[
i
].
dl_min
);
AssertFatal
(
dl_CarrierFreq_by_1k
<=
(
nr_bandtable
[
i
].
dl_max
-
bw_kHz
),
AssertFatal
(
dl_CarrierFreq_by_1k
<=
(
nr_bandtable
[
i
].
dl_max
-
bw_kHz
),
"Band %d, dl_CarrierFreq %llu bw %u: DL carrier frequency %llu kHz > %llu
\n
"
,
nr_bandP
,
(
long
long
unsigned
int
)
dl_CarrierFreq
,
bw
,
(
long
long
unsigned
int
)
dl_CarrierFreq_by_1k
,
(
long
long
unsigned
int
)(
nr_bandtable
[
i
].
dl_max
-
bw_kHz
));
...
...
@@ -130,9 +135,9 @@ uint32_t to_nrarfcn(int nr_bandP, uint64_t dl_CarrierFreq, uint32_t bw)
}
uint64_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_nrarfcn
)
uint64_t
from_nrarfcn
(
int
nr_bandP
,
uint32_t
dl_nrarfcn
)
{
int
i
;
int
deltaFglobal
;
...
...
@@ -144,5 +149,16 @@ uint64_t from_nrarfcn(int nr_bandP, uint32_t dl_nrarfcn)
AssertFatal
(
dl_nrarfcn
>=
nr_bandtable
[
i
].
N_OFFs_DL
,
"dl_nrarfcn %u < N_OFFs_DL %llu
\n
"
,
dl_nrarfcn
,
(
long
long
unsigned
int
)
nr_bandtable
[
i
].
N_OFFs_DL
);
return
1000
*
(
nr_bandtable
[
i
].
dl_min
+
(
dl_nrarfcn
-
nr_bandtable
[
i
].
N_OFFs_DL
)
*
deltaFglobal
);
}
int32_t
get_nr_uldl_offset
(
int
nr_bandP
)
{
int
i
;
for
(
i
=
0
;
i
<
NR_BANDTABLE_SIZE
&&
nr_bandtable
[
i
].
band
!=
nr_bandP
;
i
++
);
AssertFatal
(
i
<
NR_BANDTABLE_SIZE
,
"i %d >= BANDTABLE_SIZE %ld
\n
"
,
i
,
NR_BANDTABLE_SIZE
);
return
(
nr_bandtable
[
i
].
dl_min
-
nr_bandtable
[
i
].
ul_min
);
}
openair2/LAYER2/PDCP_v10.1.0/pdcp.h
View file @
4ff293c5
...
...
@@ -74,8 +74,9 @@ typedef struct {
}
pdcp_params_t
;
#define PDCP_USE_NETLINK ( get_pdcp_optmask() & PDCP_USE_NETLINK_BIT)
#ifndef PDCP_USE_NETLINK
#define PDCP_USE_NETLINK ( get_pdcp_optmask() & PDCP_USE_NETLINK_BIT)
#endif
#define LINK_ENB_PDCP_TO_IP_DRIVER ( get_pdcp_optmask() & LINK_ENB_PDCP_TO_IP_DRIVER_BIT)
#define LINK_ENB_PDCP_TO_GTPV1U ( get_pdcp_optmask() & LINK_ENB_PDCP_TO_GTPV1U_BIT)
#define UE_NAS_USE_TUN ( get_pdcp_optmask() & UE_NAS_USE_TUN_BIT)
...
...
openair2/NETWORK_DRIVER/UE_IP/local.h
View file @
4ff293c5
...
...
@@ -51,13 +51,13 @@
#include <linux/in.h>
#include <net/ndisc.h>
#include "constant.h"
#include "platform_types.h"
#include "sap.h"
#define MAKE_VERSION(a,b,c) ((a)*256+(b)*16+(c))
#ifndef MAKE_VERSION
#define MAKE_VERSION(a,b,c) ((a)*256+(b)*16+(c))
#endif
typedef
struct
ue_ip_priv_s
{
int
irq
;
...
...
openair2/RRC/NR/nr_rrc_defs.h
View file @
4ff293c5
...
...
@@ -158,7 +158,7 @@ typedef struct UE_RRC_INFO_NR_s {
uint8_t
SIB1systemInfoValueTag
;
uint32_t
SIStatus
;
uint32_t
SIcnt
;
#if
defined(Rel10) || defined(Rel14
)
#if
(NR_RRC_VERSION >= MAKE_VERSION(10, 0, 0)
)
uint8_t
MCCHStatus
[
8
];
// MAX_MBSFN_AREA
#endif
uint8_t
SIwindowsize
;
//!< Corresponds to the SIB1 si-WindowLength parameter. The unit is ms. Possible values are (final): 1,2,5,10,15,20,40
...
...
@@ -260,7 +260,7 @@ typedef struct SRB_INFO_TABLE_ENTRY_NR_s {
typedef
struct
gNB_RRC_UE_s
{
uint8_t
primaryCC_id
;
#if
defined(Rel10) || defined(Rel14
)
#if
(NR_RRC_VERSION >= MAKE_VERSION(10, 0, 0)
)
SCellToAddMod_r10_t
sCell_config
[
2
];
#endif
NR_SRB_ToAddModList_t
*
SRB_configList
;
...
...
targets/ARCH/USRP/USERSPACE/LIB/usrp_lib.cpp
View file @
4ff293c5
...
...
@@ -481,34 +481,34 @@ static int trx_usrp_write(openair0_device *device, openair0_timestamp timestamp,
// s->tx_md.start_of_burst = true;
// s->tx_md.end_of_burst = false;
first_packet_state
=
true
;
last_packet_state
=
false
;
last_packet_state
=
false
;
}
else
if
(
flags
==
3
)
{
// end of burst
//s->tx_md.start_of_burst = false;
//s->tx_md.end_of_burst = true;
first_packet_state
=
false
;
last_packet_state
-
true
;
last_packet_state
=
true
;
}
else
if
(
flags
==
4
)
{
// start and end
// s->tx_md.start_of_burst = true;
// s->tx_md.end_of_burst = true;
first_packet_state
=
true
;
last_packet_state
=
true
;
last_packet_state
=
true
;
}
else
if
(
flags
==
1
)
{
// middle of burst
// s->tx_md.start_of_burst = false;
// s->tx_md.end_of_burst = false;
first_packet_state
=
false
;
last_packet_state
=
false
;
last_packet_state
=
false
;
}
else
if
(
flags
==
10
)
{
// fail safe mode
// s->tx_md.has_time_spec = false;
// s->tx_md.start_of_burst = false;
// s->tx_md.end_of_burst = true;
first_packet_state
=
false
;
last_packet_state
=
true
;
first_packet_state
=
false
;
last_packet_state
=
true
;
}
s
->
tx_md
.
has_time_spec
=
true
;
s
->
tx_md
.
start_of_burst
=
(
s
->
tx_count
==
0
)
?
true
:
first_packet_state
;
s
->
tx_md
.
end_of_burst
=
last_packet_state
;
s
->
tx_md
.
time_spec
=
uhd
::
time_spec_t
::
from_ticks
(
timestamp
,
s
->
sample_rate
);
s
->
tx_md
.
time_spec
=
uhd
::
time_spec_t
::
from_ticks
(
timestamp
,
s
->
sample_rate
);
s
->
tx_count
++
;
...
...
targets/RT/USER/lte-enb.c
View file @
4ff293c5
...
...
@@ -471,7 +471,7 @@ void eNB_top(PHY_VARS_eNB *eNB,
proc
->
subframe_rx
=
subframe_rx
;
if
(
!
oai_exit
)
{
T
(
T_ENB_MASTER_TICK
,
T_INT
(
0
),
T_INT
(
ru_proc
->
frame_rx
),
T_INT
(
ru_proc
->
subframe
_rx
));
T
(
T_ENB_MASTER_TICK
,
T_INT
(
0
),
T_INT
(
ru_proc
->
frame_rx
),
T_INT
(
ru_proc
->
tti
_rx
));
L1_proc
->
timestamp_tx
=
ru_proc
->
timestamp_rx
+
(
sf_ahead
*
fp
->
samples_per_tti
);
L1_proc
->
frame_rx
=
ru_proc
->
frame_rx
;
L1_proc
->
subframe_rx
=
ru_proc
->
tti_rx
;
...
...
@@ -523,7 +523,7 @@ int wakeup_txfh(PHY_VARS_eNB *eNB,
for
(
int
ru_id
=
0
;
ru_id
<
eNB
->
num_RU
;
ru_id
++
){
ru
=
eNB
->
RU_list
[
ru_id
];
ru_proc
=
&
ru
->
proc
;
fp
=
&
ru
->
frame_parms
;
fp
=
ru
->
frame_parms
;
if
(((
fp
->
frame_type
==
TDD
)
&&
(
subframe_select
(
fp
,
proc
->
subframe_tx
)
==
SF_UL
))
||
(
eNB
->
RU_list
[
ru_id
]
->
state
==
RU_SYNC
)
||
(
eNB
->
RU_list
[
ru_id
]
->
wait_cnt
>
0
)){
...
...
@@ -536,7 +536,7 @@ int wakeup_txfh(PHY_VARS_eNB *eNB,
AssertFatal
((
ret
=
pthread_mutex_lock
(
&
ru_proc
->
mutex_eNBs
))
==
0
,
"ERROR pthread_mutex_lock failed on mutex_eNBs L1_thread_tx with ret=%d
\n
"
,
ret
);
if
(
ru_proc
->
instance_cnt_eNBs
==
0
)
{
LOG_E
(
PHY
,
"Frame %d, subframe %d: TX FH thread busy, dropping Frame %d, subframe %d
\n
"
,
ru_proc
->
frame_tx
,
ru_proc
->
subframe
_tx
,
proc
->
frame_rx
,
proc
->
subframe_rx
);
LOG_E
(
PHY
,
"Frame %d, subframe %d: TX FH thread busy, dropping Frame %d, subframe %d
\n
"
,
ru_proc
->
frame_tx
,
ru_proc
->
tti
_tx
,
proc
->
frame_rx
,
proc
->
subframe_rx
);
AssertFatal
((
ret
=
pthread_mutex_lock
(
&
eNB
->
proc
.
mutex_RU_tx
))
==
0
,
"mutex_lock returns %d
\n
"
,
ret
);
eNB
->
proc
.
RU_mask_tx
=
0
;
AssertFatal
((
ret
=
pthread_mutex_unlock
(
&
eNB
->
proc
.
mutex_RU_tx
))
==
0
,
"mutex_unlock returns %d
\n
"
,
ret
);
...
...
@@ -609,7 +609,7 @@ int wakeup_rxtx(PHY_VARS_eNB *eNB,
LTE_DL_FRAME_PARMS
*
fp
=
&
eNB
->
frame_parms
;
int
ret
;
LOG_D
(
PHY
,
"ENTERED wakeup_rxtx, %d.%d
\n
"
,
ru_proc
->
frame_rx
,
ru_proc
->
subframe
_rx
);
LOG_D
(
PHY
,
"ENTERED wakeup_rxtx, %d.%d
\n
"
,
ru_proc
->
frame_rx
,
ru_proc
->
tti
_rx
);
// wake up TX for subframe n+sl_ahead
// lock the TX mutex and make sure the thread is ready
...
...
@@ -617,7 +617,7 @@ int wakeup_rxtx(PHY_VARS_eNB *eNB,
if
(
L1_proc
->
instance_cnt
==
0
)
{
// L1_thread is busy so abort the subframe
AssertFatal
((
ret
=
pthread_mutex_unlock
(
&
L1_proc
->
mutex
))
==
0
,
"mutex_unlock return %d
\n
"
,
ret
);
LOG_W
(
PHY
,
"L1_thread isn't ready in %d.%d, aborting RX processing
\n
"
,
ru_proc
->
frame_rx
,
ru_proc
->
subframe_rx
);
LOG_W
(
PHY
,
"L1_thread isn't ready in %d.%d, aborting RX processing
\n
"
,
ru_proc
->
frame_rx
,
ru_proc
->
tti_rx
);
return
(
0
);
}
...
...
targets/RT/USER/lte-ru.c
View file @
4ff293c5
...
...
@@ -467,7 +467,7 @@ void fh_if5_north_asynch_in(RU_t *ru,
frame_tx
=
(
timestamp_tx
/
(
fp
->
samples_per_tti
*
10
))
&
1023
;
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME
(
VCD_SIGNAL_DUMPER_VARIABLES_FRAME_NUMBER_TX0_RU
,
proc
->
frame_tx
);
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME
(
VCD_SIGNAL_DUMPER_VARIABLES_
SUBFRAME
_NUMBER_TX0_RU
,
proc
->
tti_tx
);
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME
(
VCD_SIGNAL_DUMPER_VARIABLES_
TTI
_NUMBER_TX0_RU
,
proc
->
tti_tx
);
if
(
proc
->
first_tx
!=
0
)
{
*
subframe
=
tti_tx
;
...
...
@@ -1622,7 +1622,7 @@ static void* ru_thread_tx( void* param )
// wait until eNBs are finished subframe RX n and TX n+4
wait_on_condition
(
&
proc
->
mutex_eNBs
,
&
proc
->
cond_eNBs
,
&
proc
->
instance_cnt_eNBs
,
"ru_thread_tx"
);
LOG_D
(
PHY
,
"ru_thread_tx: TX in %d.%d
\n
"
,
ru
->
proc
.
frame_tx
,
ru
->
proc
.
subframe
_tx
);
LOG_D
(
PHY
,
"ru_thread_tx: TX in %d.%d
\n
"
,
ru
->
proc
.
frame_tx
,
ru
->
proc
.
tti
_tx
);
if
(
oai_exit
)
break
;
...
...
@@ -2007,7 +2007,6 @@ void *ru_thread_synch(void *arg)
RU_t
*
ru
=
(
RU_t
*
)
arg
;
LTE_DL_FRAME_PARMS
*
fp
=
ru
->
frame_parms
;
int64_t
peak_val
,
avg
;
uint32_t
sync_corr
[
307200
]
__attribute__
((
aligned
(
32
)));
static
int
ru_thread_synch_status
=
0
;
int
cnt
=
0
;
thread_top_init
(
"ru_thread_synch"
,
0
,
5000000
,
10000000
,
10000000
);
...
...
@@ -2040,7 +2039,7 @@ void *ru_thread_synch(void *arg)
//exit(-1);
}
// sync_pos > 0
else
//AssertFatal(cnt<1000,"Cannot find synch reference\n");
{
{
if
(
cnt
>
200
)
{
LOG_M
(
"ru_sync_rx.m"
,
"rurx"
,
&
ru
->
common
.
rxdata
[
0
][
0
],
LTE_NUMBER_OF_SUBFRAMES_PER_FRAME
*
fp
->
samples_per_tti
,
1
,
1
);
LOG_M
(
"ru_sync_corr.m"
,
"sync_corr"
,
ru
->
dmrs_corr
,
LTE_NUMBER_OF_SUBFRAMES_PER_FRAME
*
fp
->
samples_per_tti
,
1
,
6
);
...
...
@@ -2408,7 +2407,7 @@ void init_RU_proc(RU_t *ru)
pthread_create
(
&
proc
->
pthread_prach
,
attr_prach
,
ru_thread_prach
,
(
void
*
)
ru
);
ru
->
state
=
RU_RUN
;
fill_rf_config
(
ru
,
ru
->
rf_config_file
);
init_frame_parms
(
&
ru
->
frame_parms
,
1
);
init_frame_parms
(
ru
->
frame_parms
,
1
);
ru
->
frame_parms
->
nb_antennas_rx
=
ru
->
nb_rx
;
phy_init_RU
(
ru
);
...
...
@@ -2799,10 +2798,14 @@ void init_RU(char *rf_config_file,
// NOTE: multiple CC_id are not handled here yet!
ru
->
openair0_cfg
.
clock_source
=
clock_source
;
ru
->
openair0_cfg
.
time_source
=
time_source
;
ru
->
generate_dmrs_sync
=
(
ru
->
is_slave
==
0
)
?
1
:
0
;
//ru->generate_dmrs_sync = (ru->is_slave == 0) ? 1 : 0;
if
((
ru
->
is_slave
==
0
)
&&
(
ru
->
ota_sync_enable
==
1
))
ru
->
generate_dmrs_sync
=
1
;
else
ru
->
generate_dmrs_sync
=
0
;
if
(
ru
->
generate_dmrs_sync
==
1
)
{
generate_ul_ref_sigs
();
ru
->
dmrssync
=
(
int16_t
*
)
malloc16_clear
(
ofdm_symbol_size
*
2
*
sizeof
(
int16_t
));
ru
->
dmrssync
=
(
int16_t
*
)
malloc16_clear
(
ru
->
frame_parms
->
ofdm_symbol_size
*
2
*
sizeof
(
int16_t
));
}
ru
->
wakeup_L1_sleeptime
=
2000
;
ru
->
wakeup_L1_sleep_cnt_max
=
3
;
...
...
@@ -3087,6 +3090,9 @@ void RCconfig_RU(void)
printf
(
"RU %d is_slave=%s
\n
"
,
j
,
*
(
RUParamList
.
paramarray
[
j
][
RU_IS_SLAVE_IDX
].
strptr
));
if
(
strcmp
(
*
(
RUParamList
.
paramarray
[
j
][
RU_IS_SLAVE_IDX
].
strptr
),
"yes"
)
==
0
)
RC
.
ru
[
j
]
->
is_slave
=
1
;
else
RC
.
ru
[
j
]
->
is_slave
=
0
;
printf
(
"RU %d ota_sync_enabled=%s
\n
"
,
j
,
*
(
RUParamList
.
paramarray
[
j
][
RU_OTA_SYNC_ENABLE_IDX
].
strptr
));
if
(
strcmp
(
*
(
RUParamList
.
paramarray
[
j
][
RU_OTA_SYNC_ENABLE_IDX
].
strptr
),
"yes"
)
==
0
)
RC
.
ru
[
j
]
->
ota_sync_enable
=
1
;
else
RC
.
ru
[
j
]
->
ota_sync_enable
=
0
;
}
RC
.
ru
[
j
]
->
max_pdschReferenceSignalPower
=
*
(
RUParamList
.
paramarray
[
j
][
RU_MAX_RS_EPRE_IDX
].
uptr
);;
RC
.
ru
[
j
]
->
max_rxgain
=
*
(
RUParamList
.
paramarray
[
j
][
RU_MAX_RXGAIN_IDX
].
uptr
);
...
...
targets/RT/USER/lte-softmodem-common.c
View file @
4ff293c5
...
...
@@ -56,7 +56,6 @@ softmodem_params_t *get_softmodem_params(void) {
void
get_common_options
(
void
)
{
uint32_t
online_log_messages
;
uint32_t
glog_level
;
uint32_t
glog_verbosity
;
uint32_t
start_telnetsrv
;
uint32_t
noS1
;
uint32_t
nokrnmod
;
...
...
targets/RT/USER/lte-softmodem.h
View file @
4ff293c5
...
...
@@ -126,7 +126,7 @@
#define CMDLINE_DUMPMEMORY_IDX 7
/*------------------------------------------------------------------------------------------------------------------------------------------*/
#define START_MSC softmodem_params.start_msc
/*-------------------------------------------------------------------------------------------------------------------------------------------------------*/
/* command line parameters specific to UE */
/* optname helpstr paramflags XXXptr defXXXval type numelt */
...
...
@@ -218,15 +218,14 @@
#define CONFIG_HLP_MSC "Enable the MSC tracing utility \n"
/*---------------------------------------------------------------------------------------------------------------------------------------------------------------------------*/
/* command line parameters for LOG utility */
/* optname
helpstr paramflags XXXptr defXXXval type numelt
*/
/* optname
helpstr paramflags XXXptr defXXXval type numelt
*/
/*---------------------------------------------------------------------------------------------------------------------------------------------------------------------------*/
#define START_MSC softmodem_params.start_msc
#define CMDLINE_LOGPARAMS_DESC { \
{"R" , CONFIG_HLP_FLOG, 0, uptr:&online_log_messages, defintval:1, TYPE_INT, 0}, \
{"g" , CONFIG_HLP_LOGL, 0, uptr:&glog_level, defintval:0, TYPE_UINT, 0}, \
{"G" , CONFIG_HLP_LOGV, 0, uptr:&glog_verbosity, defintval:0, TYPE_UINT16, 0}, \
{"telnetsrv", CONFIG_HLP_TELN, PARAMFLAG_BOOL, uptr:&start_telnetsrv, defintval:0, TYPE_UINT, 0}, \
{"msc", CONFIG_HLP_MSC, PARAMFLAG_BOOL, uptr:&START_MSC, defintval:0, TYPE_UINT, 0}, \
{"telnetsrv", CONFIG_HLP_TELN, PARAMFLAG_BOOL, uptr:&start_telnetsrv, defintval:0, TYPE_UINT, 0}, \
{"msc", CONFIG_HLP_MSC, PARAMFLAG_BOOL, uptr:&START_MSC, defintval:0, TYPE_UINT, 0}, \
}
#define CMDLINE_ONLINELOG_IDX 0
...
...
targets/RT/USER/lte-ue.c
View file @
4ff293c5
...
...
@@ -287,7 +287,7 @@ void init_UE(int nb_inst,
// needed for memcopy below. these are not used in the RU, but needed for UE
RC
.
ru
[
0
]
->
frame_parms
->
nb_antennas_rx
=
fp0
->
nb_antennas_rx
;
RC
.
ru
[
0
]
->
frame_parms
->
nb_antennas_tx
=
fp0
->
nb_antennas_tx
;
PHY_vars_UE_g
[
inst
][
0
]
=
init_ue_vars
(
&
RC
.
ru
[
0
]
->
frame_parms
,
inst
,
0
);
PHY_vars_UE_g
[
inst
][
0
]
=
init_ue_vars
(
RC
.
ru
[
0
]
->
frame_parms
,
inst
,
0
);
}
// turn off timing control loop in UE
...
...
targets/RT/USER/ru_control.c
View file @
4ff293c5
...
...
@@ -578,8 +578,8 @@ void* ru_thread_control( void* param )
fill_rf_config
(
ru
,
ru
->
rf_config_file
);
init_frame_parms
(
&
ru
->
frame_parms
,
1
);
ru
->
frame_parms
.
nb_antennas_rx
=
ru
->
nb_rx
;
init_frame_parms
(
ru
->
frame_parms
,
1
);
ru
->
frame_parms
->
nb_antennas_rx
=
ru
->
nb_rx
;
phy_init_RU
(
ru
);
//if (ru->is_slave == 1) lte_sync_time_init(&ru->frame_parms);
...
...
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