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
ZhouShuya
OpenXG-RAN
Commits
a9650117
Commit
a9650117
authored
Apr 17, 2021
by
Sakthivel Velumani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Code cleanup as per reiview comments
parent
3c17c29a
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
13 deletions
+7
-13
openair1/PHY/NR_ESTIMATION/nr_ul_channel_estimation.c
openair1/PHY/NR_ESTIMATION/nr_ul_channel_estimation.c
+1
-1
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
+6
-12
No files found.
openair1/PHY/NR_ESTIMATION/nr_ul_channel_estimation.c
View file @
a9650117
...
@@ -605,7 +605,7 @@ int nr_pusch_channel_estimation(PHY_VARS_gNB *gNB,
...
@@ -605,7 +605,7 @@ int nr_pusch_channel_estimation(PHY_VARS_gNB *gNB,
ul_ch
+=
24
;
ul_ch
+=
24
;
}
}
}
}
#ifdef DEBUG_P
D
SCH
#ifdef DEBUG_P
U
SCH
ul_ch
=
(
int16_t
*
)
&
ul_ch_estimates
[
p
*
gNB
->
frame_parms
.
nb_antennas_rx
+
aarx
][
ch_offset
];
ul_ch
=
(
int16_t
*
)
&
ul_ch_estimates
[
p
*
gNB
->
frame_parms
.
nb_antennas_rx
+
aarx
][
ch_offset
];
for
(
uint16_t
idxP
=
0
;
idxP
<
ceil
((
float
)
nb_rb_pusch
*
12
/
8
);
idxP
++
)
{
for
(
uint16_t
idxP
=
0
;
idxP
<
ceil
((
float
)
nb_rb_pusch
*
12
/
8
);
idxP
++
)
{
for
(
uint8_t
idxI
=
0
;
idxI
<
16
;
idxI
+=
2
)
{
for
(
uint8_t
idxI
=
0
;
idxI
<
16
;
idxI
+=
2
)
{
...
...
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
View file @
a9650117
...
@@ -786,14 +786,14 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
...
@@ -786,14 +786,14 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
}
}
for
(
aarx
=
0
;
aarx
<
ue
->
frame_parms
.
nb_antennas_rx
;
aarx
++
)
{
for
(
aarx
=
0
;
aarx
<
ue
->
frame_parms
.
nb_antennas_rx
;
aarx
++
)
{
pil
=
(
int16_t
*
)
&
pilot
[
rb_offset
*
((
config_type
==
pdsch_dmrs_type1
)
?
6
:
4
)];
pil
=
(
int16_t
*
)
&
pilot
[
rb_offset
*
((
config_type
==
pdsch_dmrs_type1
)
?
6
:
4
)];
k
=
k
%
ue
->
frame_parms
.
ofdm_symbol_size
;
k
=
k
%
ue
->
frame_parms
.
ofdm_symbol_size
;
re_offset
=
k
;
re_offset
=
k
;
rxF
=
(
int16_t
*
)
&
rxdataF
[
aarx
][(
symbol_offset
+
re_offset
+
nushift
)];
rxF
=
(
int16_t
*
)
&
rxdataF
[
aarx
][(
symbol_offset
+
re_offset
+
nushift
)];
dl_ch
=
(
int16_t
*
)
&
dl_ch_estimates
[
p
*
ue
->
frame_parms
.
nb_antennas_rx
+
aarx
][
ch_offset
];
dl_ch
=
(
int16_t
*
)
&
dl_ch_estimates
[
p
*
ue
->
frame_parms
.
nb_antennas_rx
+
aarx
][
ch_offset
];
memset
(
dl_ch
,
0
,
4
*
(
ue
->
frame_parms
.
ofdm_symbol_size
));
memset
(
dl_ch
,
0
,
4
*
(
ue
->
frame_parms
.
ofdm_symbol_size
));
if
(
ue
->
high_speed_flag
==
0
)
// multiply previous channel estimate by ch_est_alpha
if
(
ue
->
high_speed_flag
==
0
)
// multiply previous channel estimate by ch_est_alpha
multadd_complex_vector_real_scalar
(
dl_ch
-
(
ue
->
frame_parms
.
ofdm_symbol_size
<<
1
),
multadd_complex_vector_real_scalar
(
dl_ch
-
(
ue
->
frame_parms
.
ofdm_symbol_size
<<
1
),
ue
->
ch_est_alpha
,
dl_ch
-
(
ue
->
frame_parms
.
ofdm_symbol_size
<<
1
),
ue
->
ch_est_alpha
,
dl_ch
-
(
ue
->
frame_parms
.
ofdm_symbol_size
<<
1
),
1
,
ue
->
frame_parms
.
ofdm_symbol_size
);
1
,
ue
->
frame_parms
.
ofdm_symbol_size
);
...
@@ -848,18 +848,12 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
...
@@ -848,18 +848,12 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
dl_ch
,
dl_ch
,
8
);
8
);
//for (int i= 0; i<16; i++)
//printf("dl_ch addr %p %d\n", dl_ch+i, *(dl_ch+i));
pil
+=
2
;
pil
+=
2
;
re_offset
=
(
re_offset
+
2
)
%
ue
->
frame_parms
.
ofdm_symbol_size
;
re_offset
=
(
re_offset
+
2
)
%
ue
->
frame_parms
.
ofdm_symbol_size
;
rxF
=
(
int16_t
*
)
&
rxdataF
[
aarx
][(
symbol_offset
+
nushift
+
re_offset
)];
rxF
=
(
int16_t
*
)
&
rxdataF
[
aarx
][(
symbol_offset
+
nushift
+
re_offset
)];
dl_ch
+=
8
;
dl_ch
+=
8
;
for
(
pilot_cnt
=
3
;
pilot_cnt
<
(
6
*
nb_rb_pdsch
-
3
);
pilot_cnt
+=
2
)
{
for
(
pilot_cnt
=
3
;
pilot_cnt
<
(
6
*
nb_rb_pdsch
-
3
);
pilot_cnt
+=
2
)
{
//if ((pilot_cnt%6)==0)
//dl_ch += 4;
//printf("re_offset %d\n",re_offset);
ch
[
0
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
0
]
-
(
int32_t
)
pil
[
1
]
*
rxF
[
1
])
>>
15
);
ch
[
0
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
0
]
-
(
int32_t
)
pil
[
1
]
*
rxF
[
1
])
>>
15
);
ch
[
1
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
1
]
+
(
int32_t
)
pil
[
1
]
*
rxF
[
0
])
>>
15
);
ch
[
1
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
1
]
+
(
int32_t
)
pil
[
1
]
*
rxF
[
0
])
>>
15
);
...
@@ -941,7 +935,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
...
@@ -941,7 +935,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
uint16_t
idxDC
=
2
*
(
ue
->
frame_parms
.
ofdm_symbol_size
-
bwp_start_subcarrier
);
uint16_t
idxDC
=
2
*
(
ue
->
frame_parms
.
ofdm_symbol_size
-
bwp_start_subcarrier
);
uint16_t
idxPil
=
idxDC
/
2
;
uint16_t
idxPil
=
idxDC
/
2
;
re_offset
=
k
;
re_offset
=
k
;
pil
=
(
int16_t
*
)
&
pilot
[
rb_offset
*
((
config_type
==
pdsch_dmrs_type1
)
?
6
:
4
)];
pil
=
(
int16_t
*
)
&
pilot
[
rb_offset
*
((
config_type
==
pdsch_dmrs_type1
)
?
6
:
4
)];
pil
+=
(
idxPil
-
2
);
pil
+=
(
idxPil
-
2
);
dl_ch
+=
(
idxDC
-
4
);
dl_ch
+=
(
idxDC
-
4
);
dl_ch
=
memset
(
dl_ch
,
0
,
sizeof
(
int16_t
)
*
10
);
dl_ch
=
memset
(
dl_ch
,
0
,
sizeof
(
int16_t
)
*
10
);
...
@@ -951,7 +945,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
...
@@ -951,7 +945,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
ch
[
1
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
1
]
+
(
int32_t
)
pil
[
1
]
*
rxF
[
0
])
>>
15
);
ch
[
1
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
1
]
+
(
int32_t
)
pil
[
1
]
*
rxF
[
0
])
>>
15
);
// for proper allignment of SIMD vectors
// for proper allignment of SIMD vectors
if
((
ue
->
frame_parms
.
N_RB_DL
&
1
)
==
0
)
{
if
((
ue
->
frame_parms
.
N_RB_DL
&
1
)
==
0
)
{
multadd_real_vector_complex_scalar
(
fdcl
,
multadd_real_vector_complex_scalar
(
fdcl
,
ch
,
ch
,
...
@@ -987,7 +981,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
...
@@ -987,7 +981,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
8
);
8
);
}
}
}
}
}
else
if
(
config_type
==
pdsch_dmrs_type2
&&
ue
->
fd_lin_interpolation
==
1
){
//pdsch_dmrs_type2 |dmrs_r,dmrs_l,0,0,0,0,dmrs_r,dmrs_l,0,0,0,0|
}
else
if
(
config_type
==
pdsch_dmrs_type2
&&
ue
->
fd_lin_interpolation
==
1
){
//pdsch_dmrs_type2 |dmrs_r,dmrs_l,0,0,0,0,dmrs_r,dmrs_l,0,0,0,0|
// Treat first 4 pilots specially (left edge)
// Treat first 4 pilots specially (left edge)
ch_l
[
0
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
0
]
-
(
int32_t
)
pil
[
1
]
*
rxF
[
1
])
>>
15
);
ch_l
[
0
]
=
(
int16_t
)(((
int32_t
)
pil
[
0
]
*
rxF
[
0
]
-
(
int32_t
)
pil
[
1
]
*
rxF
[
1
])
>>
15
);
...
@@ -1150,7 +1144,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
...
@@ -1150,7 +1144,7 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
ch_l
[
1
]
=
dl_ch
[
1
]
;
ch_l
[
1
]
=
dl_ch
[
1
]
;
// for proper allignment of SIMD vectors
// for proper allignment of SIMD vectors
if
((
ue
->
frame_parms
.
N_RB_DL
&
1
)
==
0
)
{
if
((
ue
->
frame_parms
.
N_RB_DL
&
1
)
==
0
)
{
dl_ch
-=
20
;
dl_ch
-=
20
;
//Interpolate fdcrl1 with ch_r
//Interpolate fdcrl1 with ch_r
multadd_real_vector_complex_scalar
(
filt8_dcrl1
,
multadd_real_vector_complex_scalar
(
filt8_dcrl1
,
...
...
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