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
Michael Black
OpenXG-RAN
Commits
3be476c8
Commit
3be476c8
authored
Sep 06, 2021
by
Sakthivel Velumani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved logging of PUSCH rx
parent
c834f401
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
44 additions
and
38 deletions
+44
-38
openair1/PHY/CODING/nr_segmentation.c
openair1/PHY/CODING/nr_segmentation.c
+3
-7
openair1/PHY/NR_ESTIMATION/nr_measurements_gNB.c
openair1/PHY/NR_ESTIMATION/nr_measurements_gNB.c
+4
-2
openair1/PHY/NR_TRANSPORT/nr_tbs_tools.c
openair1/PHY/NR_TRANSPORT/nr_tbs_tools.c
+1
-1
openair1/PHY/NR_TRANSPORT/nr_ulsch_decoding.c
openair1/PHY/NR_TRANSPORT/nr_ulsch_decoding.c
+1
-1
openair1/PHY/NR_TRANSPORT/nr_ulsch_demodulation.c
openair1/PHY/NR_TRANSPORT/nr_ulsch_demodulation.c
+33
-26
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
+2
-1
No files found.
openair1/PHY/CODING/nr_segmentation.c
View file @
3be476c8
...
@@ -92,9 +92,7 @@ if ((Kprime%Kb) > 0)
...
@@ -92,9 +92,7 @@ if ((Kprime%Kb) > 0)
else
else
Z
=
(
Kprime
/
Kb
);
Z
=
(
Kprime
/
Kb
);
#ifdef DEBUG_SEGMENTATION
LOG_D
(
PHY
,
"nr segmetation B %u Bprime %u Kprime %u z %u
\n
"
,
B
,
Bprime
,
Kprime
,
Z
);
printf
(
"nr segmetation B %u Bprime %u Kprime %u z %u
\n
"
,
B
,
Bprime
,
Kprime
,
Z
);
#endif
if
(
Z
<=
2
)
{
if
(
Z
<=
2
)
{
*
K
=
2
;
*
K
=
2
;
...
@@ -148,10 +146,8 @@ else
...
@@ -148,10 +146,8 @@ else
*
F
=
((
*
K
)
-
Kprime
);
*
F
=
((
*
K
)
-
Kprime
);
#ifdef DEBUG_SEGMENTATION
LOG_D
(
PHY
,
"final nr seg output Z %u K %u F %u
\n
"
,
*
Zout
,
*
K
,
*
F
);
printf
(
"final nr seg output Z %u K %u F %u
\n
"
,
*
Zout
,
*
K
,
*
F
);
LOG_D
(
PHY
,
"C %u, K %u, Bprime_bytes %u, Bprime %u, F %u
\n
"
,
*
C
,
*
K
,
Bprime
>>
3
,
Bprime
,
*
F
);
printf
(
"C %u, K %u, Bprime_bytes %u, Bprime %u, F %u
\n
"
,
*
C
,
*
K
,
Bprime
>>
3
,
Bprime
,
*
F
);
#endif
if
((
input_buffer
)
&&
(
output_buffers
))
{
if
((
input_buffer
)
&&
(
output_buffers
))
{
...
...
openair1/PHY/NR_ESTIMATION/nr_measurements_gNB.c
View file @
3be476c8
...
@@ -203,6 +203,7 @@ void nr_gnb_measurements(PHY_VARS_gNB *gNB, uint8_t ulsch_id, unsigned char harq
...
@@ -203,6 +203,7 @@ void nr_gnb_measurements(PHY_VARS_gNB *gNB, uint8_t ulsch_id, unsigned char harq
rx_power
[
ulsch_id
][
aarx
]
+=
meas
->
rx_spatial_power
[
ulsch_id
][
aatx
][
aarx
];
rx_power
[
ulsch_id
][
aarx
]
+=
meas
->
rx_spatial_power
[
ulsch_id
][
aatx
][
aarx
];
}
}
LOG_D
(
PHY
,
"[ULSCH ID %d] RX power in antenna %d = %d
\n
"
,
ulsch_id
,
aarx
,
rx_power
[
ulsch_id
][
aarx
]);
rx_power_tot
[
ulsch_id
]
+=
rx_power
[
ulsch_id
][
aarx
];
rx_power_tot
[
ulsch_id
]
+=
rx_power
[
ulsch_id
][
aarx
];
...
@@ -214,12 +215,13 @@ void nr_gnb_measurements(PHY_VARS_gNB *gNB, uint8_t ulsch_id, unsigned char harq
...
@@ -214,12 +215,13 @@ void nr_gnb_measurements(PHY_VARS_gNB *gNB, uint8_t ulsch_id, unsigned char harq
meas
->
wideband_cqi_tot
[
ulsch_id
]
=
dB_fixed2
(
rx_power_tot
[
ulsch_id
],
meas
->
n0_power_tot
);
meas
->
wideband_cqi_tot
[
ulsch_id
]
=
dB_fixed2
(
rx_power_tot
[
ulsch_id
],
meas
->
n0_power_tot
);
meas
->
rx_rssi_dBm
[
ulsch_id
]
=
rx_power_avg_dB
[
ulsch_id
]
+
30
-
10
*
log10
(
pow
(
2
,
30
))
-
(
rx_gain
-
rx_gain_offset
)
-
dB_fixed
(
fp
->
ofdm_symbol_size
);
meas
->
rx_rssi_dBm
[
ulsch_id
]
=
rx_power_avg_dB
[
ulsch_id
]
+
30
-
10
*
log10
(
pow
(
2
,
30
))
-
(
rx_gain
-
rx_gain_offset
)
-
dB_fixed
(
fp
->
ofdm_symbol_size
);
LOG_D
(
PHY
,
"[ULSCH %d] RSSI %d dBm/RE, RSSI (digital) %d dB (N_RB_UL %d), WBand CQI tot %d dB, N0 Power tot %d
\n
"
,
LOG_D
(
PHY
,
"[ULSCH %d] RSSI %d dBm/RE, RSSI (digital) %d dB (N_RB_UL %d), WBand CQI tot %d dB, N0 Power tot %d
, RX Power tot %d
\n
"
,
ulsch_id
,
ulsch_id
,
meas
->
rx_rssi_dBm
[
ulsch_id
],
meas
->
rx_rssi_dBm
[
ulsch_id
],
rx_power_avg_dB
[
ulsch_id
],
rx_power_avg_dB
[
ulsch_id
],
N_RB_UL
,
N_RB_UL
,
meas
->
wideband_cqi_tot
[
ulsch_id
],
meas
->
wideband_cqi_tot
[
ulsch_id
],
meas
->
n0_power_tot
);
meas
->
n0_power_tot
,
rx_power_tot
[
ulsch_id
]);
}
}
openair1/PHY/NR_TRANSPORT/nr_tbs_tools.c
View file @
3be476c8
...
@@ -46,11 +46,11 @@ uint32_t nr_get_E(uint32_t G, uint8_t C, uint8_t Qm, uint8_t Nl, uint8_t r) {
...
@@ -46,11 +46,11 @@ uint32_t nr_get_E(uint32_t G, uint8_t C, uint8_t Qm, uint8_t Nl, uint8_t r) {
AssertFatal
(
Nl
>
0
,
"Nl is 0
\n
"
);
AssertFatal
(
Nl
>
0
,
"Nl is 0
\n
"
);
AssertFatal
(
Qm
>
0
,
"Qm is 0
\n
"
);
AssertFatal
(
Qm
>
0
,
"Qm is 0
\n
"
);
LOG_D
(
PHY
,
"nr_get_E : (G %d, C %d, Qm %d, Nl %d, r %d)
\n
"
,
G
,
C
,
Qm
,
Nl
,
r
);
if
(
r
<=
Cprime
-
((
G
/
(
Nl
*
Qm
))
%
Cprime
)
-
1
)
if
(
r
<=
Cprime
-
((
G
/
(
Nl
*
Qm
))
%
Cprime
)
-
1
)
E
=
Nl
*
Qm
*
(
G
/
(
Nl
*
Qm
*
Cprime
));
E
=
Nl
*
Qm
*
(
G
/
(
Nl
*
Qm
*
Cprime
));
else
else
E
=
Nl
*
Qm
*
((
G
/
(
Nl
*
Qm
*
Cprime
))
+
1
);
E
=
Nl
*
Qm
*
((
G
/
(
Nl
*
Qm
*
Cprime
))
+
1
);
LOG_D
(
PHY
,
"nr_get_E : (G %d, C %d, Qm %d, Nl %d, r %d), E %d
\n
"
,
G
,
C
,
Qm
,
Nl
,
r
,
E
);
return
E
;
return
E
;
}
}
openair1/PHY/NR_TRANSPORT/nr_ulsch_decoding.c
View file @
3be476c8
...
@@ -510,7 +510,7 @@ uint32_t nr_ulsch_decoding(PHY_VARS_gNB *phy_vars_gNB,
...
@@ -510,7 +510,7 @@ uint32_t nr_ulsch_decoding(PHY_VARS_gNB *phy_vars_gNB,
A
=
(
harq_process
->
TBS
)
<<
3
;
A
=
(
harq_process
->
TBS
)
<<
3
;
LOG_D
(
PHY
,
"ULSCH Decoding, harq_pid %d TBS %d G %d mcs %d Nl %d nb_rb %d, Qm %d, n_layers %d
\n
"
,
harq_pid
,
A
,
G
,
mcs
,
n_layers
,
nb_rb
,
Qm
,
n_layers
);
LOG_D
(
PHY
,
"ULSCH Decoding, harq_pid %d TBS %d G %d mcs %d Nl %d nb_rb %d, Qm %d, n_layers %d
, Coderate %d
\n
"
,
harq_pid
,
A
,
G
,
mcs
,
n_layers
,
nb_rb
,
Qm
,
n_layers
,
R
);
if
(
R
<
1024
)
if
(
R
<
1024
)
Coderate
=
(
float
)
R
/
(
float
)
1024
;
Coderate
=
(
float
)
R
/
(
float
)
1024
;
...
...
openair1/PHY/NR_TRANSPORT/nr_ulsch_demodulation.c
View file @
3be476c8
...
@@ -582,22 +582,29 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
...
@@ -582,22 +582,29 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
unsigned
short
nb_rb
,
unsigned
short
nb_rb
,
unsigned
char
output_shift
)
{
unsigned
char
output_shift
)
{
#ifdef __AVX2__
int
off
=
((
nb_rb
&
1
)
==
1
)
?
4
:
0
;
#else
int
off
=
0
;
#endif
#ifdef DEBUG_CH_COMP
#ifdef DEBUG_CH_COMP
int16_t
*
rxF
,
*
ul_ch
;
int16_t
*
rxF
,
*
ul_ch
;
int
prnt_idx
;
int
prnt_idx
;
rxF
=
(
int16_t
*
)
&
rxdataF_ext
[
0
][
symbol
*
(
off
+
(
nb_rb
*
12
))];
for
(
int
ant
=
0
;
ant
<
frame_parms
->
nb_antennas_rx
;
ant
++
)
{
ul_ch
=
(
int16_t
*
)
&
ul_ch_estimates_ext
[
0
][
symbol
*
(
off
+
(
nb_rb
*
1
))
2
];
rxF
=
(
int16_t
*
)
&
rxdataF_ext
[
ant
][
symbol
*
(
off
+
(
nb_rb
*
12
))];
ul_ch
=
(
int16_t
*
)
&
ul_ch_estimates_ext
[
ant
][
symbol
*
(
off
+
(
nb_rb
*
12
))];
printf
(
"--------------------symbol = %d, mod_order = %d, output_shift = %d-----------------------
\n
"
,
symbol
,
mod_order
,
output_shift
);
printf
(
"--------------------symbol = %d, mod_order = %d, output_shift = %d-----------------------
\n
"
,
symbol
,
mod_order
,
output_shift
);
printf
(
"----------------Before compensation------------------
\n
"
);
printf
(
"----------------Before compensation------------------
\n
"
);
for
(
prnt_idx
=
0
;
prnt_idx
<
12
*
nb_rb
*
2
;
prnt_idx
+=
2
){
for
(
prnt_idx
=
0
;
prnt_idx
<
12
*
5
*
2
;
prnt_idx
+=
2
){
printf
(
"rxF[%d] = (%d,%d)
\n
"
,
prnt_idx
>>
1
,
rxF
[
prnt_idx
],
rxF
[
prnt_idx
+
1
]);
printf
(
"rxF[%d] = (%d,%d)
\n
"
,
prnt_idx
>>
1
,
rxF
[
prnt_idx
],
rxF
[
prnt_idx
+
1
]);
printf
(
"ul_ch[%d] = (%d,%d)
\n
"
,
prnt_idx
>>
1
,
ul_ch
[
prnt_idx
],
ul_ch
[
prnt_idx
+
1
]);
printf
(
"ul_ch[%d] = (%d,%d)
\n
"
,
prnt_idx
>>
1
,
ul_ch
[
prnt_idx
],
ul_ch
[
prnt_idx
+
1
]);
}
}
}
#endif
#endif
...
@@ -607,25 +614,21 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
...
@@ -607,25 +614,21 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
int
print_idx
;
int
print_idx
;
ch_mag
=
(
int16_t
*
)
&
ul_ch_mag
[
0
][
symbol
*
(
off
+
(
nb_rb
*
12
))];
for
(
int
ant
=
0
;
ant
<
frame_parms
->
nb_antennas_rx
;
ant
++
)
{
ch_mag
=
(
int16_t
*
)
&
ul_ch_mag
[
ant
][
symbol
*
(
off
+
(
nb_rb
*
12
))];
printf
(
"--------------------symbol = %d, mod_order = %d-----------------------
\n
"
,
symbol
,
mod_order
);
printf
(
"--------------------symbol = %d, mod_order = %d-----------------------
\n
"
,
symbol
,
mod_order
);
printf
(
"----------------Before computation------------------
\n
"
);
printf
(
"----------------Before computation------------------
\n
"
);
for
(
print_idx
=
0
;
print_idx
<
50
;
print_idx
++
){
for
(
print_idx
=
0
;
print_idx
<
5
;
print_idx
++
){
printf
(
"ch_mag[%d] = %d
\n
"
,
print_idx
,
ch_mag
[
print_idx
]);
printf
(
"ch_mag[%d] = %d
\n
"
,
print_idx
,
ch_mag
[
print_idx
]);
}
}
}
#endif
#endif
#ifdef __AVX2__
int
off
=
((
nb_rb
&
1
)
==
1
)
?
4
:
0
;
#else
int
off
=
0
;
#endif
#if defined(__i386) || defined(__x86_64__)
#if defined(__i386) || defined(__x86_64__)
unsigned
short
rb
;
unsigned
short
rb
;
...
@@ -1068,14 +1071,16 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
...
@@ -1068,14 +1071,16 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
#ifdef DEBUG_CH_COMP
#ifdef DEBUG_CH_COMP
rxF
=
(
int16_t
*
)
&
rxdataF_comp
[
0
][(
symbol
*
(
off
+
(
nb_rb
*
12
)))];
for
(
int
ant
=
0
;
ant
<
frame_parms
->
nb_antennas_rx
;
ant
++
)
{
rxF
=
(
int16_t
*
)
&
rxdataF_comp
[
ant
][(
symbol
*
(
off
+
(
nb_rb
*
12
)))];
printf
(
"----------------After compansation------------------
\n
"
);
printf
(
"----------------After compansation------------------
\n
"
);
for
(
prnt_idx
=
0
;
prnt_idx
<
12
*
nb_rb
*
2
;
prnt_idx
+=
2
){
for
(
prnt_idx
=
0
;
prnt_idx
<
12
*
5
*
2
;
prnt_idx
+=
2
){
printf
(
"rxF[%d] = (%d,%d)
\n
"
,
prnt_idx
>>
1
,
rxF
[
prnt_idx
],
rxF
[
prnt_idx
+
1
]);
printf
(
"rxF[%d] = (%d,%d)
\n
"
,
prnt_idx
>>
1
,
rxF
[
prnt_idx
],
rxF
[
prnt_idx
+
1
]);
}
}
}
#endif
#endif
...
@@ -1083,14 +1088,16 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
...
@@ -1083,14 +1088,16 @@ void nr_ulsch_channel_compensation(int **rxdataF_ext,
#ifdef DEBUG_CH_MAG
#ifdef DEBUG_CH_MAG
ch_mag
=
(
int16_t
*
)
&
ul_ch_mag
[
0
][(
symbol
*
(
off
+
(
nb_rb
*
12
)))];
for
(
int
ant
=
0
;
ant
<
frame_parms
->
nb_antennas_rx
;
ant
++
)
{
ch_mag
=
(
int16_t
*
)
&
ul_ch_mag
[
ant
][(
symbol
*
(
off
+
(
nb_rb
*
12
)))];
printf
(
"----------------After computation------------------
\n
"
);
printf
(
"----------------After computation------------------
\n
"
);
for
(
print_idx
=
0
;
print_idx
<
12
*
nb_rb
*
2
;
print_idx
+=
2
){
for
(
print_idx
=
0
;
print_idx
<
12
*
5
*
2
;
print_idx
+=
2
){
printf
(
"ch_mag[%d] = (%d,%d)
\n
"
,
print_idx
>>
1
,
ch_mag
[
print_idx
],
ch_mag
[
print_idx
+
1
]);
printf
(
"ch_mag[%d] = (%d,%d)
\n
"
,
print_idx
>>
1
,
ch_mag
[
print_idx
],
ch_mag
[
print_idx
+
1
]);
}
}
}
#endif
#endif
...
...
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c
View file @
3be476c8
...
@@ -1200,7 +1200,8 @@ void nr_dlsch_decoding_process(void *arg) {
...
@@ -1200,7 +1200,8 @@ void nr_dlsch_decoding_process(void *arg) {
ret
=
dlsch
->
max_ldpc_iterations
;
ret
=
dlsch
->
max_ldpc_iterations
;
harq_process
->
G
=
nr_get_G
(
nb_rb
,
nb_symb_sch
,
nb_re_dmrs
,
length_dmrs
,
harq_process
->
Qm
,
harq_process
->
Nl
);
harq_process
->
G
=
nr_get_G
(
nb_rb
,
nb_symb_sch
,
nb_re_dmrs
,
length_dmrs
,
harq_process
->
Qm
,
harq_process
->
Nl
);
G
=
harq_process
->
G
;
G
=
harq_process
->
G
;
LOG_D
(
PHY
,
"DLSCH Decoding process, harq_pid %d TBS %d G %d mcs %d Nl %d nb_symb_sch %d nb_rb %d
\n
"
,
harq_pid
,
A
,
G
,
harq_process
->
mcs
,
harq_process
->
Nl
,
nb_symb_sch
,
nb_rb
);
LOG_D
(
PHY
,
"DLSCH Decoding process, harq_pid %d TBS %d G %d mcs %d Nl %d nb_symb_sch %d nb_rb %d, Coderate %d
\n
"
,
harq_pid
,
A
,
G
,
harq_process
->
mcs
,
harq_process
->
Nl
,
nb_symb_sch
,
nb_rb
,
harq_process
->
R
);
if
((
harq_process
->
R
)
<
1024
)
if
((
harq_process
->
R
)
<
1024
)
Coderate
=
(
float
)
(
harq_process
->
R
)
/
(
float
)
1024
;
Coderate
=
(
float
)
(
harq_process
->
R
)
/
(
float
)
1024
;
...
...
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