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
1638bbba
Commit
1638bbba
authored
Aug 18, 2022
by
Roberto Louro Magueta
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add intermediate variable
parent
0cb014f4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
openair1/PHY/NR_ESTIMATION/nr_ul_channel_estimation.c
openair1/PHY/NR_ESTIMATION/nr_ul_channel_estimation.c
+6
-5
No files found.
openair1/PHY/NR_ESTIMATION/nr_ul_channel_estimation.c
View file @
1638bbba
...
@@ -1017,6 +1017,8 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
...
@@ -1017,6 +1017,8 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
ls_estimated
[
1
]
=
(
int16_t
)(((
int32_t
)
generated_real
*
received_imag
-
(
int32_t
)
generated_imag
*
received_real
)
>>
nr_srs_info
->
srs_generated_signal_bits
);
ls_estimated
[
1
]
=
(
int16_t
)(((
int32_t
)
generated_real
*
received_imag
-
(
int32_t
)
generated_imag
*
received_real
)
>>
nr_srs_info
->
srs_generated_signal_bits
);
srs_ls_estimated_channel
[
ant
][
nr_srs_info
->
sc_list
[
sc_idx
]]
=
ls_estimated
[
0
]
+
(((
int32_t
)
ls_estimated
[
1
]
<<
16
)
&
0xFFFF0000
);
srs_ls_estimated_channel
[
ant
][
nr_srs_info
->
sc_list
[
sc_idx
]]
=
ls_estimated
[
0
]
+
(((
int32_t
)
ls_estimated
[
1
]
<<
16
)
&
0xFFFF0000
);
const
uint16_t
sc_idx_offset
=
nr_srs_info
->
sc_list
[
sc_idx
]
+
mem_offset
;
// Channel interpolation
// Channel interpolation
if
(
srs_pdu
->
comb_size
==
0
)
{
if
(
srs_pdu
->
comb_size
==
0
)
{
if
(
sc_idx
==
0
)
{
// First subcarrier case
if
(
sc_idx
==
0
)
{
// First subcarrier case
...
@@ -1038,14 +1040,14 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
...
@@ -1038,14 +1040,14 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
}
else
if
(
sc_idx
%
2
==
0
)
{
// 2nd middle case
}
else
if
(
sc_idx
%
2
==
0
)
{
// 2nd middle case
// filt8_middle4 is {0,0,4096,8192,8192,8192,4096,0}
// filt8_middle4 is {0,0,4096,8192,8192,8192,4096,0}
multadd_real_vector_complex_scalar
(
filt8_middle4
,
ls_estimated
,
srs_estimated_channel16
,
8
);
multadd_real_vector_complex_scalar
(
filt8_middle4
,
ls_estimated
,
srs_estimated_channel16
,
8
);
srs_estimated_channel16
=
(
int16_t
*
)
&
srs_est
[
nr_srs_info
->
sc_list
[
sc_idx
]
+
mem
_offset
];
srs_estimated_channel16
=
(
int16_t
*
)
&
srs_est
[
sc_idx
_offset
];
}
}
}
else
{
}
else
{
if
(
sc_idx
==
0
)
{
// First subcarrier case
if
(
sc_idx
==
0
)
{
// First subcarrier case
// filt16_start is {12288,8192,8192,8192,4096,0,0,0,0,0,0,0,0,0,0,0}
// filt16_start is {12288,8192,8192,8192,4096,0,0,0,0,0,0,0,0,0,0,0}
multadd_real_vector_complex_scalar
(
filt16_start
,
ls_estimated
,
srs_estimated_channel16
,
16
);
multadd_real_vector_complex_scalar
(
filt16_start
,
ls_estimated
,
srs_estimated_channel16
,
16
);
}
else
if
(
nr_srs_info
->
sc_list
[
sc_idx
]
<
nr_srs_info
->
sc_list
[
sc_idx
-
1
])
{
// Start of OFDM symbol case
}
else
if
(
nr_srs_info
->
sc_list
[
sc_idx
]
<
nr_srs_info
->
sc_list
[
sc_idx
-
1
])
{
// Start of OFDM symbol case
srs_estimated_channel16
=
(
int16_t
*
)
&
srs_est
[
nr_srs_info
->
sc_list
[
sc_idx
]
+
mem
_offset
];
srs_estimated_channel16
=
(
int16_t
*
)
&
srs_est
[
sc_idx
_offset
];
// filt16_start is {12288,8192,8192,8192,4096,0,0,0,0,0,0,0,0,0,0,0}
// filt16_start is {12288,8192,8192,8192,4096,0,0,0,0,0,0,0,0,0,0,0}
multadd_real_vector_complex_scalar
(
filt16_start
,
ls_estimated
,
srs_estimated_channel16
,
16
);
multadd_real_vector_complex_scalar
(
filt16_start
,
ls_estimated
,
srs_estimated_channel16
,
16
);
}
else
if
((
sc_idx
<
(
nr_srs_info
->
sc_list_length
-
1
)
&&
nr_srs_info
->
sc_list
[
sc_idx
+
1
]
<
nr_srs_info
->
sc_list
[
sc_idx
])
}
else
if
((
sc_idx
<
(
nr_srs_info
->
sc_list_length
-
1
)
&&
nr_srs_info
->
sc_list
[
sc_idx
+
1
]
<
nr_srs_info
->
sc_list
[
sc_idx
])
...
@@ -1055,7 +1057,7 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
...
@@ -1055,7 +1057,7 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
}
else
{
// Middle case
}
else
{
// Middle case
// filt16_middle4 is {4096,8192,8192,8192,8192,8192,8192,8192,4096,0,0,0,0,0,0,0}
// filt16_middle4 is {4096,8192,8192,8192,8192,8192,8192,8192,4096,0,0,0,0,0,0,0}
multadd_real_vector_complex_scalar
(
filt16_middle4
,
ls_estimated
,
srs_estimated_channel16
,
16
);
multadd_real_vector_complex_scalar
(
filt16_middle4
,
ls_estimated
,
srs_estimated_channel16
,
16
);
srs_estimated_channel16
=
(
int16_t
*
)
&
srs_est
[
nr_srs_info
->
sc_list
[
sc_idx
]
+
mem
_offset
];
srs_estimated_channel16
=
(
int16_t
*
)
&
srs_est
[
sc_idx
_offset
];
}
}
}
}
...
@@ -1189,9 +1191,8 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
...
@@ -1189,9 +1191,8 @@ int nr_srs_channel_estimation(const PHY_VARS_gNB *gNB,
LOG_I
(
NR_PHY
,
"
\t
__lsRe__________lsIm__|____intRe_______intIm__|____noiRe_______noiIm_
\n
"
);
LOG_I
(
NR_PHY
,
"
\t
__lsRe__________lsIm__|____intRe_______intIm__|____noiRe_______noiIm_
\n
"
);
}
}
for
(
int
r
=
0
;
r
<
R
;
r
++
)
{
for
(
int
r
=
0
;
r
<
R
;
r
++
)
{
if
(
nr_srs_info
->
sc_list
[
sc_idx
]
+
r
>=
frame_parms
->
ofdm_symbol_size
)
{
if
(
nr_srs_info
->
sc_list
[
sc_idx
]
+
r
>=
frame_parms
->
ofdm_symbol_size
)
continue
;
continue
;
}
LOG_I
(
NR_PHY
,
"(%4i) %6i
\t
%6i | %6i
\t
%6i | %6i
\t
%6i
\n
"
,
LOG_I
(
NR_PHY
,
"(%4i) %6i
\t
%6i | %6i
\t
%6i | %6i
\t
%6i
\n
"
,
subcarrier_log
+
r
,
subcarrier_log
+
r
,
(
int16_t
)(
srs_ls_estimated_channel
[
ant
][
nr_srs_info
->
sc_list
[
sc_idx
]
+
r
]
&
0xFFFF
),
(
int16_t
)(
srs_ls_estimated_channel
[
ant
][
nr_srs_info
->
sc_list
[
sc_idx
]
+
r
]
&
0xFFFF
),
...
...
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