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
zzha zzha
OpenXG-RAN
Commits
a456054d
Commit
a456054d
authored
4 years ago
by
laurent
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
continue scope
parent
e4b2689e
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
40 additions
and
21 deletions
+40
-21
executables/ocp-gnb.c
executables/ocp-gnb.c
+6
-6
openair1/PHY/TOOLS/nr_phy_scope.c
openair1/PHY/TOOLS/nr_phy_scope.c
+19
-10
openair1/PHY/TOOLS/readme.md
openair1/PHY/TOOLS/readme.md
+12
-0
openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
+2
-4
openair2/LAYER2/NR_MAC_UE/main_ue_nr.c
openair2/LAYER2/NR_MAC_UE/main_ue_nr.c
+1
-1
No files found.
executables/ocp-gnb.c
View file @
a456054d
...
@@ -99,10 +99,10 @@ int flexran_agent_start(mid_t mod_id) {
...
@@ -99,10 +99,10 @@ int flexran_agent_start(mid_t mod_id) {
}
}
void
flexran_agent_slice_update
(
mid_t
module_idP
)
{
void
flexran_agent_slice_update
(
mid_t
module_idP
)
{
}
}
int
proto_agent_start
(
mod_id_t
mod_id
,
const
cudu_params_t
*
p
){
int
proto_agent_start
(
mod_id_t
mod_id
,
const
cudu_params_t
*
p
)
{
return
0
;
return
0
;
}
}
void
proto_agent_stop
(
mod_id_t
mod_id
){
void
proto_agent_stop
(
mod_id_t
mod_id
)
{
}
}
int
split73
=
0
;
int
split73
=
0
;
void
sendFs6Ul
(
PHY_VARS_eNB
*
eNB
,
int
UE_id
,
int
harq_pid
,
int
segmentID
,
int16_t
*
data
,
int
dataLen
,
int
r_offset
)
{
void
sendFs6Ul
(
PHY_VARS_eNB
*
eNB
,
int
UE_id
,
int
harq_pid
,
int
segmentID
,
int16_t
*
data
,
int
dataLen
,
int
r_offset
)
{
...
@@ -400,8 +400,8 @@ void OCPconfig_RU(RU_t *ru) {
...
@@ -400,8 +400,8 @@ void OCPconfig_RU(RU_t *ru) {
config_getlist
(
&
RUParamList
,
RUParams
,
sizeof
(
RUParams
)
/
sizeof
(
paramdef_t
),
NULL
);
config_getlist
(
&
RUParamList
,
RUParams
,
sizeof
(
RUParams
)
/
sizeof
(
paramdef_t
),
NULL
);
AssertFatal
(
RUParamList
.
numelt
==
1
&&
RC
.
nb_nr_L1_inst
==
1
,
""
);
AssertFatal
(
RUParamList
.
numelt
==
1
&&
RC
.
nb_nr_L1_inst
==
1
,
""
);
ru
->
idx
=
0
;
ru
->
idx
=
0
;
ru
->
nr_frame_parms
=
(
NR_DL_FRAME_PARMS
*
)
malloc
(
sizeof
(
NR_DL_FRAME_PARMS
)
);
ru
->
nr_frame_parms
=
(
NR_DL_FRAME_PARMS
*
)
calloc
(
sizeof
(
NR_DL_FRAME_PARMS
),
1
);
ru
->
frame_parms
=
(
LTE_DL_FRAME_PARMS
*
)
malloc
(
sizeof
(
LTE_DL_FRAME_PARMS
)
);
ru
->
frame_parms
=
(
LTE_DL_FRAME_PARMS
*
)
calloc
(
sizeof
(
LTE_DL_FRAME_PARMS
),
1
);
ru
->
if_timing
=
synch_to_ext_device
;
ru
->
if_timing
=
synch_to_ext_device
;
ru
->
num_gNB
=
RUParamList
.
paramarray
[
j
][
RU_ENB_LIST_IDX
].
numelt
;
ru
->
num_gNB
=
RUParamList
.
paramarray
[
j
][
RU_ENB_LIST_IDX
].
numelt
;
ru
->
gNB_list
[
i
]
=
&
RC
.
gNB
[
RUParamList
.
paramarray
[
j
][
RU_ENB_LIST_IDX
].
iptr
[
i
]][
0
];
ru
->
gNB_list
[
i
]
=
&
RC
.
gNB
[
RUParamList
.
paramarray
[
j
][
RU_ENB_LIST_IDX
].
iptr
[
i
]][
0
];
...
@@ -858,7 +858,7 @@ int main( int argc, char **argv ) {
...
@@ -858,7 +858,7 @@ int main( int argc, char **argv ) {
// once all RUs are ready initialize the rest of the gNBs ((dependence on final RU parameters after configuration)
// once all RUs are ready initialize the rest of the gNBs ((dependence on final RU parameters after configuration)
printf
(
"ALL RUs ready - init gNBs
\n
"
);
printf
(
"ALL RUs ready - init gNBs
\n
"
);
LOG_E
(
PHY
,
"configuring RU from file, hardcoded one gNB for one RU, one carrier
\n
"
);
LOG_E
(
PHY
,
"configuring RU from file, hardcoded one gNB for one RU, one carrier
\n
"
);
RU_t
ru
=
{
0
};
RU_t
ru
=
{
0
};
OCPconfig_RU
(
&
ru
);
OCPconfig_RU
(
&
ru
);
ru
.
nr_frame_parms
->
threequarter_fs
=
threequarter_fs
;
ru
.
nr_frame_parms
->
threequarter_fs
=
threequarter_fs
;
fill_rf_config
(
&
ru
,
ru
.
rf_config_file
);
fill_rf_config
(
&
ru
,
ru
.
rf_config_file
);
...
...
This diff is collapsed.
Click to expand it.
openair1/PHY/TOOLS/nr_phy_scope.c
View file @
a456054d
...
@@ -162,19 +162,28 @@ static void oai_xygraph(OAIgraph_t *graph, float *x, float *y, int len, int laye
...
@@ -162,19 +162,28 @@ static void oai_xygraph(OAIgraph_t *graph, float *x, float *y, int len, int laye
}
}
static
void
genericLogPowerPerAntena
(
OAIgraph_t
*
graph
,
const
int
nb_ant
,
const
scopeSample_t
**
data
,
const
int
len
)
{
static
void
genericLogPowerPerAntena
(
OAIgraph_t
*
graph
,
const
int
nb_ant
,
const
scopeSample_t
**
data
,
const
int
len
)
{
float
values
[
len
]
;
float
*
values
=
malloc
(
len
*
sizeof
(
*
values
))
;
float
time
[
len
]
;
float
*
time
=
malloc
(
len
*
sizeof
(
*
time
))
;
for
(
int
ant
=
0
;
ant
<
nb_ant
;
ant
++
)
{
for
(
int
ant
=
0
;
ant
<
nb_ant
;
ant
++
)
{
if
(
data
[
ant
]
!=
NULL
)
{
if
(
data
[
ant
]
!=
NULL
)
{
for
(
int
i
=
0
;
i
<
len
;
i
++
)
{
for
(
int
i
=
0
;
i
<
len
;
i
+=
8
)
{
values
[
i
]
=
10
*
log10
(
1
.
0
+
SquaredNorm
(
data
[
ant
][
i
]));
float
*
vals
=
values
+
i
;
time
[
i
]
=
i
;
float
*
tim
=
time
+
i
;
const
scopeSample_t
*
in
=&
(
data
[
ant
][
i
]);
for
(
int
k
=
0
;
k
<
8
;
k
++
)
{
vals
[
k
]
=
10
*
log10
(
1
.
0
+
SquaredNorm
(
in
[
k
]));
tim
[
k
]
=
i
+
k
;
}
}
}
oai_xygraph
(
graph
,
time
,
values
,
len
,
ant
,
10
);
oai_xygraph
(
graph
,
time
,
values
,
len
,
ant
,
10
);
}
}
}
}
free
(
values
);
free
(
time
);
}
}
static
void
genericPowerPerAntena
(
OAIgraph_t
*
graph
,
const
int
nb_ant
,
const
scopeSample_t
**
data
,
const
int
len
)
{
static
void
genericPowerPerAntena
(
OAIgraph_t
*
graph
,
const
int
nb_ant
,
const
scopeSample_t
**
data
,
const
int
len
)
{
...
@@ -322,7 +331,7 @@ static OAI_phy_scope_t *create_phy_scope_gnb(void) {
...
@@ -322,7 +331,7 @@ static OAI_phy_scope_t *create_phy_scope_gnb(void) {
fl_set_object_color
(
obj
,
FL_BLACK
,
FL_WHITE
);
fl_set_object_color
(
obj
,
FL_BLACK
,
FL_WHITE
);
int
curY
=
0
,
x
,
y
,
w
,
h
;
int
curY
=
0
,
x
,
y
,
w
,
h
;
// Received signal
// Received signal
fdui
->
graph
[
0
]
=
gNBcommonGraph
(
timeSignal
,
FL_
FIL
L_XYPLOT
,
0
,
curY
,
400
,
100
,
fdui
->
graph
[
0
]
=
gNBcommonGraph
(
timeSignal
,
FL_
NORMA
L_XYPLOT
,
0
,
curY
,
400
,
100
,
"Received Signal (Time-Domain, dB)"
,
FL_RED
);
"Received Signal (Time-Domain, dB)"
,
FL_RED
);
// Time-domain channel response
// Time-domain channel response
fdui
->
graph
[
1
]
=
gNBcommonGraph
(
timeResponse
,
FL_NORMAL_XYPLOT
,
410
,
curY
,
400
,
100
,
fdui
->
graph
[
1
]
=
gNBcommonGraph
(
timeResponse
,
FL_NORMAL_XYPLOT
,
410
,
curY
,
400
,
100
,
...
@@ -330,7 +339,7 @@ static OAI_phy_scope_t *create_phy_scope_gnb(void) {
...
@@ -330,7 +339,7 @@ static OAI_phy_scope_t *create_phy_scope_gnb(void) {
fl_get_object_bbox
(
fdui
->
graph
[
0
].
graph
,
&
x
,
&
y
,
&
w
,
&
h
);
fl_get_object_bbox
(
fdui
->
graph
[
0
].
graph
,
&
x
,
&
y
,
&
w
,
&
h
);
curY
+=
h
;
curY
+=
h
;
// Frequency-domain channel response
// Frequency-domain channel response
fdui
->
graph
[
2
]
=
gNBcommonGraph
(
frequencyResponse
,
FL_
FIL
L_XYPLOT
,
0
,
curY
,
800
,
100
,
fdui
->
graph
[
2
]
=
gNBcommonGraph
(
frequencyResponse
,
FL_
NORMA
L_XYPLOT
,
0
,
curY
,
800
,
100
,
"Channel Frequency Response (RE, dB)"
,
FL_RED
);
"Channel Frequency Response (RE, dB)"
,
FL_RED
);
fl_get_object_bbox
(
fdui
->
graph
[
2
].
graph
,
&
x
,
&
y
,
&
w
,
&
h
);
fl_get_object_bbox
(
fdui
->
graph
[
2
].
graph
,
&
x
,
&
y
,
&
w
,
&
h
);
curY
+=
h
;
curY
+=
h
;
...
@@ -390,8 +399,8 @@ static void *scope_thread_gNB(void *arg) {
...
@@ -390,8 +399,8 @@ static void *scope_thread_gNB(void *arg) {
//# ifdef ENABLE_XFORMS_WRITE_STATS
//# ifdef ENABLE_XFORMS_WRITE_STATS
// FILE *gNB_stats = fopen("gNB_stats.txt", "w");
// FILE *gNB_stats = fopen("gNB_stats.txt", "w");
//#endif
//#endif
size_t
stksize
;
size_t
stksize
=
0
;
pthread_attr_t
atr
;
pthread_attr_t
atr
=
{
0
}
;
pthread_attr_getstacksize
(
&
atr
,
&
stksize
);
pthread_attr_getstacksize
(
&
atr
,
&
stksize
);
pthread_attr_setstacksize
(
&
atr
,
32
*
1024
*
1024
);
pthread_attr_setstacksize
(
&
atr
,
32
*
1024
*
1024
);
sleep
(
3
);
// no clean interthread barriers
sleep
(
3
);
// no clean interthread barriers
...
@@ -649,7 +658,7 @@ static OAI_phy_scope_t *create_phy_scope_nrue( int ID ) {
...
@@ -649,7 +658,7 @@ static OAI_phy_scope_t *create_phy_scope_nrue( int ID ) {
int
curY
=
0
,
x
,
y
,
w
,
h
;
int
curY
=
0
,
x
,
y
,
w
,
h
;
// Received signal
// Received signal
fdui
->
graph
[
0
]
=
nrUEcommonGraph
(
ueTimeResponse
,
fdui
->
graph
[
0
]
=
nrUEcommonGraph
(
ueTimeResponse
,
FL_
FIL
L_XYPLOT
,
0
,
curY
,
400
,
100
,
"Received Signal (Time-Domain, dB)"
,
FL_RED
);
FL_
NORMA
L_XYPLOT
,
0
,
curY
,
400
,
100
,
"Received Signal (Time-Domain, dB)"
,
FL_RED
);
// Time-domain channel response
// Time-domain channel response
fdui
->
graph
[
1
]
=
nrUEcommonGraph
(
ueChannelResponse
,
fdui
->
graph
[
1
]
=
nrUEcommonGraph
(
ueChannelResponse
,
FL_NORMAL_XYPLOT
,
400
,
curY
,
400
,
100
,
"Channel Impulse Response (samples, abs)"
,
FL_RED
);
FL_NORMAL_XYPLOT
,
400
,
curY
,
400
,
100
,
"Channel Impulse Response (samples, abs)"
,
FL_RED
);
...
...
This diff is collapsed.
Click to expand it.
openair1/PHY/TOOLS/readme.md
0 → 100644
View file @
a456054d
To use the scope, run the xNB or the UE with option "-d"
Usage in gdb
In gdb, when you break, you can refresh immediatly the scope view by calling the display function.
The first paramter is the graph context, nevertheless we keep the last value for a dirty call in gdb (so you can use '0')
Example with no variable known
phy_scope_nrUE(0, PHY_vars_UE_g
[
0
][
0
]
, 0, 0, 0)
or
phy_scope_gNB(0, phy_vars_gnb, phy_vars_ru, UE_id)
This diff is collapsed.
Click to expand it.
openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
View file @
a456054d
...
@@ -2989,10 +2989,8 @@ int nr_ue_pdcch_procedures(uint8_t gNB_id,
...
@@ -2989,10 +2989,8 @@ int nr_ue_pdcch_procedures(uint8_t gNB_id,
pdcch_vars
->
nb_search_space
);
pdcch_vars
->
nb_search_space
);
#endif
#endif
fapi_nr_dci_indication_t
dci_ind
;
fapi_nr_dci_indication_t
dci_ind
=
{
0
};
nr_downlink_indication_t
dl_indication
;
nr_downlink_indication_t
dl_indication
=
{
0
};
memset
((
void
*
)
&
dci_ind
,
0
,
sizeof
(
dci_ind
));
memset
((
void
*
)
&
dl_indication
,
0
,
sizeof
(
dl_indication
));
dci_cnt
=
nr_dci_decoding_procedure
(
ue
,
dci_cnt
=
nr_dci_decoding_procedure
(
ue
,
proc
->
frame_rx
,
proc
->
frame_rx
,
nr_tti_rx
,
nr_tti_rx
,
...
...
This diff is collapsed.
Click to expand it.
openair2/LAYER2/NR_MAC_UE/main_ue_nr.c
View file @
a456054d
...
@@ -50,7 +50,7 @@ NR_UE_MAC_INST_t * nr_l2_init_ue(NR_UE_RRC_INST_t* rrc_inst)
...
@@ -50,7 +50,7 @@ NR_UE_MAC_INST_t * nr_l2_init_ue(NR_UE_RRC_INST_t* rrc_inst)
//LOG_I(MAC, "[MAIN] init UE MAC functions \n");
//LOG_I(MAC, "[MAIN] init UE MAC functions \n");
//init mac here
//init mac here
nr_ue_mac_inst
=
(
NR_UE_MAC_INST_t
*
)
malloc
(
sizeof
(
NR_UE_MAC_INST_t
)
*
NB_NR_UE_MAC_INST
);
nr_ue_mac_inst
=
(
NR_UE_MAC_INST_t
*
)
calloc
(
sizeof
(
NR_UE_MAC_INST_t
),
NB_NR_UE_MAC_INST
);
if
(
rrc_inst
)
{
if
(
rrc_inst
)
{
nr_rrc_mac_config_req_ue
(
0
,
0
,
0
,
NULL
,
rrc_inst
->
cell_group_config
->
spCellConfig
);
nr_rrc_mac_config_req_ue
(
0
,
0
,
0
,
NULL
,
rrc_inst
->
cell_group_config
->
spCellConfig
);
...
...
This diff is collapsed.
Click to expand it.
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