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
wangjie
OpenXG-RAN
Commits
71336339
Commit
71336339
authored
Nov 23, 2016
by
Florian Kaltenberger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bugfixes in precoder
parent
441b062e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
12 deletions
+15
-12
openair1/PHY/INIT/lte_init.c
openair1/PHY/INIT/lte_init.c
+7
-6
openair1/PHY/MODULATION/beamforming.c
openair1/PHY/MODULATION/beamforming.c
+8
-6
No files found.
openair1/PHY/INIT/lte_init.c
View file @
71336339
...
...
@@ -1251,12 +1251,13 @@ int phy_init_lte_eNB(PHY_VARS_eNB *eNB,
common_vars
->
beam_weights
[
eNB_id
][
i
]
=
(
int32_t
**
)
malloc16_clear
(
fp
->
nb_antennas_tx
*
sizeof
(
int32_t
*
));
for
(
j
=
0
;
j
<
fp
->
nb_antennas_tx
;
j
++
)
{
common_vars
->
beam_weights
[
eNB_id
][
i
][
j
]
=
(
int32_t
*
)
malloc16_clear
(
fp
->
ofdm_symbol_size
*
sizeof
(
int32_t
));
for
(
re
=
0
;
re
<
fp
->
ofdm_symbol_size
;
re
++
)
common_vars
->
beam_weights
[
eNB_id
][
i
][
j
][
re
]
=
0x00007fff
;
#ifdef DEBUG_PUY
msg
(
"[openair][LTE_PHY][INIT] lte_common_vars->beam_weights[%d][%d][%d] = %p (%d bytes)
\n
"
,
eNB_id
,
i
,
j
,
common_vars
->
beam_weights
[
eNB_id
][
i
][
j
],
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES
*
sizeof
(
int32_t
));
if
(
i
==
j
)
for
(
re
=
0
;
re
<
fp
->
ofdm_symbol_size
;
re
++
)
common_vars
->
beam_weights
[
eNB_id
][
i
][
j
][
re
]
=
0x00007fff
;
#ifdef DEBUG_PHY
msg
(
"[openair][LTE_PHY][INIT] lte_common_vars->beam_weights[%d][%d][%d] = %p (%d bytes)
\n
"
,
eNB_id
,
i
,
j
,
common_vars
->
beam_weights
[
eNB_id
][
i
][
j
],
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES
*
sizeof
(
int32_t
));
#endif
}
}
...
...
openair1/PHY/MODULATION/beamforming.c
View file @
71336339
...
...
@@ -61,18 +61,19 @@ int beam_precoding(int32_t **txdataF,
// clear txdata_BF[aa][re] for each call of ue_spec_beamforming
for
(
aa
=
0
;
aa
<
frame_parms
->
nb_antennas_tx
;
aa
++
)
memset
(
txdataF_BF
[
aa
],
0
,
4
*
(
frame_parms
->
ofdm_symbol_size
));
memset
(
txdataF_BF
[
aa
],
0
,
sizeof
(
int32_t
)
*
(
frame_parms
->
ofdm_symbol_size
));
for
(
re
=
0
;
re
<
frame_parms
->
ofdm_symbol_size
;
re
++
)
{
for
(
p
=
0
;
p
<
2
;
p
++
)
{
if
(
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
]
!=
0
)
{
for
(
aa
=
0
;
aa
<
frame_parms
->
nb_antennas_tx
;
aa
++
)
{
((
int16_t
*
)
&
txdataF_BF
[
aa
][
re
])[
0
]
=
(
int16_t
)((((
int16_t
*
)
&
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
])[
0
]
*
((
int16_t
*
)
&
beam_weights
[
p
][
aa
][
re
])[
0
])
>>
15
);
((
int16_t
*
)
&
txdataF_BF
[
aa
][
re
])[
0
]
+
=
(
int16_t
)((((
int16_t
*
)
&
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
])[
0
]
*
((
int16_t
*
)
&
beam_weights
[
p
][
aa
][
re
])[
0
])
>>
15
);
((
int16_t
*
)
&
txdataF_BF
[
aa
][
re
])[
0
]
-=
(
int16_t
)((((
int16_t
*
)
&
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
])[
1
]
*
((
int16_t
*
)
&
beam_weights
[
p
][
aa
][
re
])[
1
])
>>
15
);
((
int16_t
*
)
&
txdataF_BF
[
aa
][
re
])[
1
]
=
(
int16_t
)((((
int16_t
*
)
&
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
])[
0
]
*
((
int16_t
*
)
&
beam_weights
[
p
][
aa
][
re
])[
1
])
>>
15
);
((
int16_t
*
)
&
txdataF_BF
[
aa
][
re
])[
1
]
+=
(
int16_t
)((((
int16_t
*
)
&
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
])[
1
]
*
((
int16_t
*
)
&
beam_weights
[
0
][
aa
][
re
])[
0
])
>>
15
);
((
int16_t
*
)
&
txdataF_BF
[
aa
][
re
])[
1
]
+
=
(
int16_t
)((((
int16_t
*
)
&
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
])[
0
]
*
((
int16_t
*
)
&
beam_weights
[
p
][
aa
][
re
])[
1
])
>>
15
);
((
int16_t
*
)
&
txdataF_BF
[
aa
][
re
])[
1
]
+=
(
int16_t
)((((
int16_t
*
)
&
txdataF
[
p
][
slot_offset_F
+
symbol
*
frame_parms
->
ofdm_symbol_size
+
re
])[
1
]
*
((
int16_t
*
)
&
beam_weights
[
p
][
aa
][
re
])[
0
])
>>
15
);
/*printf("beamforming.c:txdata[%d][%d]=%d+j%d, beam_weights[%d][%d][%d]=%d+j%d,txdata_BF[%d][%d]=%d+j%d\n",
/*
printf("beamforming.c:txdataF[%d][%d]=%d+j%d, beam_weights[%d][%d][%d]=%d+j%d,txdata_BF[%d][%d]=%d+j%d\n",
p,slot_offset_F+symbol*frame_parms->ofdm_symbol_size+re,
((int16_t*)&txdataF[p][slot_offset_F+symbol*frame_parms->ofdm_symbol_size+re])[0],
((int16_t*)&txdataF[p][slot_offset_F+symbol*frame_parms->ofdm_symbol_size+re])[1],
...
...
@@ -80,7 +81,8 @@ int beam_precoding(int32_t **txdataF,
((int16_t*)&beam_weights[p][aa][re])[0],((int16_t*)&beam_weights[p][aa][re])[1],
aa,re,
((int16_t*)&txdataF_BF[aa][re])[0],
((int16_t*)&txdataF_BF[aa][re])[1]); */
((int16_t*)&txdataF_BF[aa][re])[1]);
*/
}
}
...
...
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