Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
oai
openairinterface5G
Commits
fc85f44f
Commit
fc85f44f
authored
Aug 30, 2016
by
Florian Kaltenberger
Browse files
fixed a bug in Alamouti coding (introduced in
7bc37c56
)
parent
2129a58e
Changes
1
Hide whitespace changes
Inline
Side-by-side
openair1/PHY/LTE_TRANSPORT/dlsch_modulation.c
View file @
fc85f44f
...
...
@@ -361,8 +361,6 @@ int allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
else
if
(
mimo_mode
==
ALAMOUTI
)
{
*
re_allocated
=
*
re_allocated
+
1
;
// normalization for 2 tx antennas
amp
=
(
int16_t
)(((
int32_t
)
tmp_amp
*
ONE_OVER_SQRT2_Q15
)
>>
15
);
switch
(
mod_order0
)
{
case
2
:
//QPSK
...
...
@@ -419,8 +417,8 @@ int allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
//((int16_t *)&txdataF[0][tti_offset])[0]+=(int16_t)(((int32_t)amp*qam16_table[qam16_table_offset_re])>>15);
//((int16_t *)&txdataF[0][tti_offset])[1]+=(int16_t)(((int32_t)amp*qam16_table[qam16_table_offset_im])>>15);
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
0
]
+=
qam_table_s0
[
qam16_table_offset_re
];
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
1
]
+=
qam_table_s0
[
qam16_table_offset_im
];
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
0
]
+=
(
qam_table_s0
[
qam16_table_offset_re
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
1
]
+=
(
qam_table_s0
[
qam16_table_offset_im
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
// Antenna 1 position n Real part -> -x1*
...
...
@@ -450,8 +448,8 @@ int allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
//((int16_t *)&txdataF[1][tti_offset])[0]+=-(int16_t)(((int32_t)amp*qam16_table[qam16_table_offset_re])>>15);
//((int16_t *)&txdataF[1][tti_offset])[1]+=(int16_t)(((int32_t)amp*qam16_table[qam16_table_offset_im])>>15);
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
0
]
+=-
qam_table_s0
[
qam16_table_offset_re
];
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
1
]
+=
qam_table_s0
[
qam16_table_offset_im
];
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
0
]
+=-
(
qam_table_s0
[
qam16_table_offset_re
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
1
]
+=
(
qam_table_s0
[
qam16_table_offset_im
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
break
;
...
...
@@ -494,8 +492,8 @@ int allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
//((int16_t *)&txdataF[0][tti_offset])[0]+=(int16_t)(((int32_t)amp*qam64_table[qam64_table_offset_re])>>15);
//((int16_t *)&txdataF[0][tti_offset])[1]+=(int16_t)(((int32_t)amp*qam64_table[qam64_table_offset_im])>>15);
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
0
]
+=
qam_table_s0
[
qam64_table_offset_re
];
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
1
]
+=
qam_table_s0
[
qam64_table_offset_im
];
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
0
]
+=
(
qam_table_s0
[
qam64_table_offset_re
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
((
int16_t
*
)
&
txdataF
[
0
][
tti_offset
])[
1
]
+=
(
qam_table_s0
[
qam64_table_offset_im
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
// Antenna 1 => -x1*
...
...
@@ -534,8 +532,8 @@ int allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
//((int16_t *)&txdataF[1][tti_offset])[0]+=-(int16_t)(((int32_t)amp*qam64_table[qam64_table_offset_re])>>15);
//((int16_t *)&txdataF[1][tti_offset])[1]+=(int16_t)(((int32_t)amp*qam64_table[qam64_table_offset_im])>>15);
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
0
]
+=-
qam_table_s0
[
qam64_table_offset_re
];
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
1
]
+=
qam_table_s0
[
qam64_table_offset_im
];
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
0
]
+=-
(
qam_table_s0
[
qam64_table_offset_re
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
((
int16_t
*
)
&
txdataF
[
1
][
tti_offset
])[
1
]
+=
(
qam_table_s0
[
qam64_table_offset_im
]
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
break
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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