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
ba253723
Commit
ba253723
authored
Sep 30, 2022
by
Marwan Hammouda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
extended KPIs completed for both gNB and UE
parent
2bd68a9a
Changes
8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
1138 additions
and
514 deletions
+1138
-514
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
+6
-2
openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
+11
-3
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
+1
-5
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
+11
-2
openair1/PHY/TOOLS/nr_phy_qt_scope.cpp
openair1/PHY/TOOLS/nr_phy_qt_scope.cpp
+1056
-453
openair1/PHY/TOOLS/nr_phy_qt_scope.h
openair1/PHY/TOOLS/nr_phy_qt_scope.h
+48
-14
openair1/PHY/TOOLS/nr_phy_scope.c
openair1/PHY/TOOLS/nr_phy_scope.c
+2
-0
openair1/PHY/TOOLS/phy_scope_interface.h
openair1/PHY/TOOLS/phy_scope_interface.h
+3
-35
No files found.
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
View file @
ba253723
...
@@ -458,8 +458,12 @@ int nr_pbch_channel_estimation(PHY_VARS_NR_UE *ue,
...
@@ -458,8 +458,12 @@ int nr_pbch_channel_estimation(PHY_VARS_NR_UE *ue,
}
}
}
}
if
(
dmrss
==
2
)
scopeData_t
*
scope
=
(
scopeData_t
*
)
ue
->
scopeData
;
UEscopeCopy
(
ue
,
pbchDlChEstimateTime
,
(
void
*
)
dl_ch_estimates_time
,
sizeof
(
struct
complex16
),
ue
->
frame_parms
.
nb_antennas_rx
,
ue
->
frame_parms
.
ofdm_symbol_size
>>
3
);
if
((
scope
)
&&
(
dmrss
==
2
)){
int
istreamingFlag
=
scope
->
flag_streaming
[
pbchDlChEstimateTime
];
if
(
istreamingFlag
==
1
)
UEscopeCopy
(
ue
,
pbchDlChEstimateTime
,
(
void
*
)
dl_ch_estimates_time
,
sizeof
(
struct
complex16
),
ue
->
frame_parms
.
nb_antennas_rx
,
idftsizeidx
);
// ue->frame_parms.ofdm_symbol_size>>3
}
return
(
0
);
return
(
0
);
...
...
openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
View file @
ba253723
...
@@ -745,8 +745,12 @@ int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
...
@@ -745,8 +745,12 @@ int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
log2_maxh
,
log2_maxh
,
n_rb
);
// log2_maxh+I0_shift
n_rb
);
// log2_maxh+I0_shift
UEscopeCopy
(
ue
,
pdcchRxdataF_comp
,
rxdataF_comp
,
sizeof
(
struct
complex16
),
frame_parms
->
nb_antennas_rx
,
rx_size
);
scopeData_t
*
scope
=
(
scopeData_t
*
)
ue
->
scopeData
;
if
(
scope
){
int
istreamingFlag
=
scope
->
flag_streaming
[
pdcchRxdataF_comp
];
if
(
istreamingFlag
==
1
)
UEscopeCopy
(
ue
,
pdcchRxdataF_comp
,
rxdataF_comp
,
sizeof
(
struct
complex16
),
frame_parms
->
nb_antennas_rx
,
rx_size
);
}
if
(
frame_parms
->
nb_antennas_rx
>
1
)
{
if
(
frame_parms
->
nb_antennas_rx
>
1
)
{
LOG_D
(
PHY
,
"we enter nr_pdcch_detection_mrc(frame_parms->nb_antennas_rx=%d)
\n
"
,
frame_parms
->
nb_antennas_rx
);
LOG_D
(
PHY
,
"we enter nr_pdcch_detection_mrc(frame_parms->nb_antennas_rx=%d)
\n
"
,
frame_parms
->
nb_antennas_rx
);
nr_pdcch_detection_mrc
(
frame_parms
,
rx_size
,
rxdataF_comp
,
s
);
nr_pdcch_detection_mrc
(
frame_parms
,
rx_size
,
rxdataF_comp
,
s
);
...
@@ -761,7 +765,11 @@ int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
...
@@ -761,7 +765,11 @@ int32_t nr_rx_pdcch(PHY_VARS_NR_UE *ue,
s
,
s
,
n_rb
);
n_rb
);
UEscopeCopy
(
ue
,
pdcchLlr
,
llr
,
sizeof
(
int16_t
),
1
,
llr_size
);
if
(
scope
){
int
istreamingFlag
=
scope
->
flag_streaming
[
pdcchLlr
];
if
(
istreamingFlag
==
1
)
UEscopeCopy
(
ue
,
pdcchLlr
,
llr
,
sizeof
(
int16_t
),
1
,
llr_size
);
}
#if T_TRACER
#if T_TRACER
...
...
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
View file @
ba253723
...
@@ -76,11 +76,7 @@ void getKPIUE(extended_kpi_ue* kpiStructure)
...
@@ -76,11 +76,7 @@ void getKPIUE(extended_kpi_ue* kpiStructure)
}
}
kpiStructure
->
DL_BLER
=
dl_bler
;
kpiStructure
->
DL_BLER
=
dl_bler
;
double
blerTerm
=
1
.
0
-
(
double
)
dl_bler
;
kpiStructure
->
blockSize
=
blockSize
;
double
blockSieBits
=
(
double
)(
blockSize
<<
3
);
kpiStructure
->
throu
=
blerTerm
*
blockSieBits
/
0
.
1
;
kpiStructure
->
dl_mcs
=
dl_mcs
;
kpiStructure
->
dl_mcs
=
dl_mcs
;
kpiStructure
->
nofRBs
=
nofRBs
;
kpiStructure
->
nofRBs
=
nofRBs
;
}
}
...
...
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
View file @
ba253723
...
@@ -487,8 +487,17 @@ int nr_rx_pbch( PHY_VARS_NR_UE *ue,
...
@@ -487,8 +487,17 @@ int nr_rx_pbch( PHY_VARS_NR_UE *ue,
}
}
// legacy code use int16, but it is complex16
// legacy code use int16, but it is complex16
UEscopeCopy
(
ue
,
pbchRxdataF_comp
,
pbch_unClipped
,
sizeof
(
struct
complex16
),
frame_parms
->
nb_antennas_rx
,
pbch_e_rx_idx
/
2
);
scopeData_t
*
scope
=
(
scopeData_t
*
)
ue
->
scopeData
;
UEscopeCopy
(
ue
,
pbchLlr
,
pbch_e_rx
,
sizeof
(
int16_t
),
frame_parms
->
nb_antennas_rx
,
pbch_e_rx_idx
);
if
(
scope
)
{
int
istreamingFlag
=
scope
->
flag_streaming
[
pbchRxdataF_comp
];
if
(
istreamingFlag
==
1
)
UEscopeCopy
(
ue
,
pbchRxdataF_comp
,
pbch_unClipped
,
sizeof
(
struct
complex16
),
frame_parms
->
nb_antennas_rx
,
pbch_e_rx_idx
/
2
);
istreamingFlag
=
scope
->
flag_streaming
[
pbchLlr
];
if
(
istreamingFlag
==
1
)
UEscopeCopy
(
ue
,
pbchLlr
,
pbch_e_rx
,
sizeof
(
int16_t
),
frame_parms
->
nb_antennas_rx
,
pbch_e_rx_idx
);
}
#ifdef DEBUG_PBCH
#ifdef DEBUG_PBCH
write_output
(
"rxdataF_comp.m"
,
"rxFcomp"
,
rxdataF_comp
[
0
],
240
*
3
,
1
,
1
);
write_output
(
"rxdataF_comp.m"
,
"rxFcomp"
,
rxdataF_comp
[
0
],
240
*
3
,
1
,
1
);
short
*
p
=
(
short
*
)
rxdataF_comp
[
0
]);
short
*
p
=
(
short
*
)
rxdataF_comp
[
0
]);
...
...
openair1/PHY/TOOLS/nr_phy_qt_scope.cpp
View file @
ba253723
This diff is collapsed.
Click to expand it.
openair1/PHY/TOOLS/nr_phy_qt_scope.h
View file @
ba253723
...
@@ -47,6 +47,21 @@ extern "C" {
...
@@ -47,6 +47,21 @@ extern "C" {
extern
RAN_CONTEXT_t
RC
;
extern
RAN_CONTEXT_t
RC
;
}
}
typedef
struct
{
float
max_value
;
float
min_value
;
float
avg_value
;
int
plot_idx
;
uint64_t
avg_idx
;
uint64_t
nof_retrans
;
// especially for the KPI: nof retransmissions
QLineSeries
*
series
;
QLineSeries
*
seriesMin
;
QLineSeries
*
seriesMax
;
QLineSeries
*
seriesAvg
;
}
KPI_elements
;
// drop-down list UE
// drop-down list UE
class
KPIListSelect
:
public
QComboBox
class
KPIListSelect
:
public
QComboBox
{
{
...
@@ -82,6 +97,8 @@ class PainterWidget : public QWidget
...
@@ -82,6 +97,8 @@ class PainterWidget : public QWidget
public:
public:
PainterWidget
(
QComboBox
*
parent
,
PHY_VARS_NR_UE
*
ue
);
PainterWidget
(
QComboBox
*
parent
,
PHY_VARS_NR_UE
*
ue
);
void
makeConnections
();
void
makeConnections
();
void
resetKPIPlot
(
KPI_elements
*
inputStruct
);
void
resetKPIValues
(
KPI_elements
*
inputStruct
);
QPixmap
*
pix
;
QPixmap
*
pix
;
QTimer
*
timer
;
QTimer
*
timer
;
int
chartHight
,
chartWidth
;
int
chartHight
,
chartWidth
;
...
@@ -98,6 +115,11 @@ public:
...
@@ -98,6 +115,11 @@ public:
extended_kpi_ue
extendKPIUE
;
extended_kpi_ue
extendKPIUE
;
KPI_elements
DLBLER
;
KPI_elements
DLMCS
;
KPI_elements
Throu
;
KPI_elements
nofRBs
;
protected:
protected:
void
paintEvent
(
QPaintEvent
*
event
);
void
paintEvent
(
QPaintEvent
*
event
);
void
resizeEvent
(
QResizeEvent
*
event
)
override
;
void
resizeEvent
(
QResizeEvent
*
event
)
override
;
...
@@ -120,13 +142,16 @@ public slots:
...
@@ -120,13 +142,16 @@ public slots:
void
paintPixmap_ueChannelResponse
();
void
paintPixmap_ueChannelResponse
();
// Extended KPIs
void
KPI_DL_BLER
();
void
KPI_DL_MCS
();
void
KPI_DL_Throu
();
void
KPI_Nof_RBs
();
private:
private:
PHY_VARS_NR_UE
*
ue
;
PHY_VARS_NR_UE
*
ue
;
int
indexToPlot
;
int
indexToPlot
;
int
previousIndex
;
int
previousIndex
;
int
chartBaseHeight
;
int
chartBaseWidth
;
};
};
...
@@ -139,29 +164,33 @@ public:
...
@@ -139,29 +164,33 @@ public:
PainterWidgetgNB
(
QComboBox
*
parent
,
scopeData_t
*
p
);
PainterWidgetgNB
(
QComboBox
*
parent
,
scopeData_t
*
p
);
void
makeConnections
();
void
makeConnections
();
void
createPixMap
(
float
*
xData
,
float
*
yData
,
int
len
,
QColor
MarkerColor
,
const
QString
xLabel
,
const
QString
yLabel
,
bool
scaleX
);
void
createPixMap
(
float
*
xData
,
float
*
yData
,
int
len
,
QColor
MarkerColor
,
const
QString
xLabel
,
const
QString
yLabel
,
bool
scaleX
);
void
resetKPIPlot
(
KPI_elements
*
inputStruct
);
void
resetKPIValues
(
KPI_elements
*
inputStruct
);
QPixmap
*
pix
;
QPixmap
*
pix
;
QTimer
*
timer
;
QTimer
*
timer
;
QTimer
*
timerRetrans
;
int
chartHight
,
chartWidth
;
int
chartHight
,
chartWidth
;
int
nb_UEs
;
int
nb_UEs
;
QComboBox
*
parentWindow
;
QComboBox
*
parentWindow
;
extended_kpi_gNB
extendKPIgNB
;
KPI_elements
ULBLER
;
KPI_elements
ULMCS
;
KPI_elements
DLBLER
;
KPI_elements
DLMCS
;
KPI_elements
ULThrou
;
KPI_elements
DLThrou
;
KPI_elements
nofRBs
;
KPI_elements
ULSNR
;
KPI_elements
DLSNR
;
NR_UE_info_t
*
targetUE
;
KPI_elements
ULRetrans
[
4
];
KPI_elements
DLRetrans
[
4
];
QLineSeries
*
seriesULBLER
;
QLineSeries
*
seriesULMCS
;
QLineSeries
*
seriesDLBLER
;
QLineSeries
*
seriesDLMCS
;
QLineSeries
*
seriesULThrou
;
QLineSeries
*
seriesDLThrou
;
float
ul_thr_ue
,
dl_thr_ue
;
protected:
protected:
void
paintEvent
(
QPaintEvent
*
event
);
void
paintEvent
(
QPaintEvent
*
event
);
void
resizeEvent
(
QResizeEvent
*
event
)
override
;
public
slots
:
public
slots
:
void
KPI_PuschIQ
();
void
KPI_PuschIQ
();
...
@@ -173,6 +202,11 @@ public slots:
...
@@ -173,6 +202,11 @@ public slots:
void
KPI_DL_MCS
();
void
KPI_DL_MCS
();
void
KPI_UL_Throu
();
void
KPI_UL_Throu
();
void
KPI_DL_Throu
();
void
KPI_DL_Throu
();
void
KPI_Nof_RBs
();
void
KPI_UL_SNR
();
void
KPI_DL_SNR
();
void
KPI_UL_Retrans
();
void
KPI_DL_Retrans
();
private:
private:
scopeData_t
*
p
;
scopeData_t
*
p
;
...
...
openair1/PHY/TOOLS/nr_phy_scope.c
View file @
ba253723
...
@@ -972,6 +972,8 @@ void nrUEinitScope(PHY_VARS_NR_UE *ue) {
...
@@ -972,6 +972,8 @@ void nrUEinitScope(PHY_VARS_NR_UE *ue) {
scopeData_t
*
scope
=
(
scopeData_t
*
)
ue
->
scopeData
;
scopeData_t
*
scope
=
(
scopeData_t
*
)
ue
->
scopeData
;
scope
->
copyData
=
UEcopyData
;
scope
->
copyData
=
UEcopyData
;
AssertFatal
(
scope
->
liveData
=
calloc
(
sizeof
(
scopeGraphData_t
*
),
UEdataTypeNumberOfItems
),
""
);
AssertFatal
(
scope
->
liveData
=
calloc
(
sizeof
(
scopeGraphData_t
*
),
UEdataTypeNumberOfItems
),
""
);
for
(
int
i
=
0
;
i
<
UEdataTypeNumberOfItems
;
i
++
)
scope
->
flag_streaming
[
i
]
=
1
;
pthread_t
forms_thread
;
pthread_t
forms_thread
;
threadCreate
(
&
forms_thread
,
nrUEscopeThread
,
ue
,
"scope"
,
-
1
,
OAI_PRIORITY_RT_LOW
);
threadCreate
(
&
forms_thread
,
nrUEscopeThread
,
ue
,
"scope"
,
-
1
,
OAI_PRIORITY_RT_LOW
);
}
}
...
...
openair1/PHY/TOOLS/phy_scope_interface.h
View file @
ba253723
...
@@ -35,43 +35,10 @@
...
@@ -35,43 +35,10 @@
#include <openair1/PHY/defs_nr_UE.h>
#include <openair1/PHY/defs_nr_UE.h>
typedef
struct
{
typedef
struct
{
// Uplink BLock Error Rate
int
idx_ULBLER
;
// Uplink MCS
float
UL_MCS_max
;
int
idx_ULMCS
;
// Downlink BLock Error Rate
int
idx_DLBLER
;
// Downlink MCS
float
DL_MCS_max
;
int
idx_DLMCS
;
// UL Throughput
float
UL_Throu_max
;
int
idx_ULThrou
;
// DL Throughput
float
DL_Throu_max
;
int
idx_DLThrou
;
}
extended_kpi_gNB
;
typedef
struct
{
int
idx_BLER
;
float
DL_BLER
;
float
DL_BLER
;
uint32_t
blockSize
;
// block size, to be used for throughput calculation
int
idx_throu
;
double
throu
;
int
idx_mcs
;
uint8_t
dl_mcs
;
uint8_t
dl_mcs
;
int
idx_nofRBs
;
uint16_t
nofRBs
;
uint16_t
nofRBs
;
}
extended_kpi_ue
;
}
extended_kpi_ue
;
...
@@ -92,12 +59,13 @@ enum UEdataType {
...
@@ -92,12 +59,13 @@ enum UEdataType {
};
};
typedef
struct
scopeData_s
{
typedef
struct
scopeData_s
{
int
flag_streaming
[
UEdataTypeNumberOfItems
];
int
*
argc
;
int
*
argc
;
char
**
argv
;
char
**
argv
;
RU_t
*
ru
;
RU_t
*
ru
;
PHY_VARS_gNB
*
gNB
;
PHY_VARS_gNB
*
gNB
;
void
*
liveData
;
void
*
liveDataUE
;
void
*
liveDataUE
;
void
*
liveData
;
void
(
*
slotFunc
)(
int32_t
*
data
,
int
slot
,
void
*
scopeData
);
void
(
*
slotFunc
)(
int32_t
*
data
,
int
slot
,
void
*
scopeData
);
void
(
*
copyData
)(
PHY_VARS_NR_UE
*
,
enum
UEdataType
,
void
*
data
,
int
elementSz
,
int
colSz
,
int
lineSz
);
void
(
*
copyData
)(
PHY_VARS_NR_UE
*
,
enum
UEdataType
,
void
*
data
,
int
elementSz
,
int
colSz
,
int
lineSz
);
}
scopeData_t
;
}
scopeData_t
;
...
...
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