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
eee0a155
Commit
eee0a155
authored
Oct 20, 2015
by
Raymond Knopp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
TM2 fixes for TDD
parent
551ae353
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
149 additions
and
75 deletions
+149
-75
openair1/PHY/LTE_TRANSPORT/dlsch_demodulation.c
openair1/PHY/LTE_TRANSPORT/dlsch_demodulation.c
+148
-75
openair1/PHY/LTE_TRANSPORT/dlsch_llr_computation.c
openair1/PHY/LTE_TRANSPORT/dlsch_llr_computation.c
+1
-0
No files found.
openair1/PHY/LTE_TRANSPORT/dlsch_demodulation.c
View file @
eee0a155
...
@@ -45,7 +45,6 @@
...
@@ -45,7 +45,6 @@
#include "PHY/sse_intrin.h"
#include "PHY/sse_intrin.h"
#ifndef USER_MODE
#ifndef USER_MODE
#define NOCYGWIN_STATIC static
#define NOCYGWIN_STATIC static
#else
#else
...
@@ -55,7 +54,7 @@
...
@@ -55,7 +54,7 @@
//#define DEBUG_PHY 1
//#define DEBUG_PHY 1
//#define DEBUG_DLSCH_DEMOD 1
//#define DEBUG_DLSCH_DEMOD 1
int
avg
[
4
];
int
avg
[
4
];
// [MCS][i_mod (0,1,2) = (2,4,6)]
// [MCS][i_mod (0,1,2) = (2,4,6)]
unsigned
char
offset_mumimo_llr_drange_fix
=
0
;
unsigned
char
offset_mumimo_llr_drange_fix
=
0
;
...
@@ -3362,7 +3361,10 @@ unsigned short dlsch_extract_rbs_single(int **rxdataF,
...
@@ -3362,7 +3361,10 @@ unsigned short dlsch_extract_rbs_single(int **rxdataF,
//PSS in subframe 0/5 if FDD
//PSS in subframe 0/5 if FDD
if
(
frame_parms
->
frame_type
==
FDD
)
{
//FDD
if
(
frame_parms
->
frame_type
==
FDD
)
{
//FDD
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
rb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
rb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
rb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
rb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
rb_alloc_ind
=
0
;
rb_alloc_ind
=
0
;
}
}
...
@@ -3439,7 +3441,7 @@ unsigned short dlsch_extract_rbs_single(int **rxdataF,
...
@@ -3439,7 +3441,7 @@ unsigned short dlsch_extract_rbs_single(int **rxdataF,
dl_ch0_ext
[
j
++
]
=
dl_ch0
[
i
];
dl_ch0_ext
[
j
++
]
=
dl_ch0
[
i
];
}
}
}
}
rxF_ext
+=
5
;
dl_ch0_ext
+=
5
;
dl_ch0_ext
+=
5
;
}
else
if
(
skip_half
==
2
)
{
}
else
if
(
skip_half
==
2
)
{
for
(
i
=
0
;
i
<
6
;
i
++
)
{
for
(
i
=
0
;
i
<
6
;
i
++
)
{
...
@@ -3495,29 +3497,31 @@ unsigned short dlsch_extract_rbs_single(int **rxdataF,
...
@@ -3495,29 +3497,31 @@ unsigned short dlsch_extract_rbs_single(int **rxdataF,
nb_rb
++
;
nb_rb
++
;
// PBCH
// PBCH
if
((
subframe
==
0
)
&&
(
rb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
rb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
>=
(
nsymb
>>
1
))
&&
(
l
<
((
nsymb
>>
1
)
+
4
)))
{
if
((
subframe
==
0
)
&&
(
l
>=
(
nsymb
>>
1
))
&&
(
l
<
((
nsymb
>>
1
)
+
4
)))
{
rb_alloc_ind
=
0
;
rb_alloc_ind
=
0
;
}
}
//SSS
//SSS
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
rb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
rb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
sss_symb
)
)
{
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
l
==
sss_symb
)
)
{
rb_alloc_ind
=
0
;
rb_alloc_ind
=
0
;
}
}
if
(
frame_parms
->
frame_type
==
FDD
)
{
if
(
frame_parms
->
frame_type
==
FDD
)
{
//PSS
//PSS
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
rb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
rb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
l
==
pss_symb
)
)
{
rb_alloc_ind
=
0
;
rb_alloc_ind
=
0
;
}
}
}
}
//PSS
if
((
frame_parms
->
frame_type
==
TDD
)
&&
if
((
frame_parms
->
frame_type
==
TDD
)
&&
(
subframe
==
6
))
{
(
subframe
==
6
)
&&
//PSS
(
l
==
pss_symb
)
)
{
if
((
rb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
rb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
rb_alloc_ind
=
0
;
rb_alloc_ind
=
0
;
}
}
}
// printf("dlch_ext %d\n",dl_ch0_ext-&dl_ch_estimates_ext[aarx][0]);
// printf("dlch_ext %d\n",dl_ch0_ext-&dl_ch_estimates_ext[aarx][0]);
// printf("DC rb %d (%p)\n",rb,rxF);
// printf("DC rb %d (%p)\n",rb,rxF);
...
@@ -3823,51 +3827,54 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -3823,51 +3827,54 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
if
(
rb_alloc_ind
==
1
)
if
(
rb_alloc_ind
==
1
)
nb_rb
++
;
nb_rb
++
;
// PBCH
if
((
subframe
==
0
)
&&
if
((
frame_parms
->
N_RB_DL
&
1
)
==
0
)
{
// even number of RBs
(
prb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
// PBCH
(
l
>=
(
nsymb
>>
1
))
&&
if
((
subframe
==
0
)
&&
(
l
<
((
nsymb
>>
1
)
+
4
)))
{
(
prb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
rb_alloc_ind
=
0
;
// printf("symbol %d / rb %d: skipping PBCH REs\n",symbol,prb);
}
//SSS
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
prb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
sss_symb
)
)
{
rb_alloc_ind
=
0
;
// printf("symbol %d / rb %d: skipping SSS REs\n",symbol,prb);
}
//PSS in subframe 0/5 if FDD
if
(
frame_parms
->
frame_type
==
FDD
)
{
//FDD
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
prb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
(
l
>=
(
nsymb
>>
1
))
&&
(
l
<
((
nsymb
>>
1
)
+
4
)))
{
rb_alloc_ind
=
0
;
rb_alloc_ind
=
0
;
//
printf("symbol %d / rb %d: skipping PSS
REs\n",symbol,prb);
//
printf("symbol %d / rb %d: skipping PBCH
REs\n",symbol,prb);
}
}
}
//SSS
if
((
frame_parms
->
frame_type
==
TDD
)
&&
(
subframe
==
6
))
{
//TDD Subframe 6
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
if
((
prb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
=
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
p
ss_symb
)
)
{
(
l
==
s
ss_symb
)
)
{
rb_alloc_ind
=
0
;
rb_alloc_ind
=
0
;
// printf("symbol %d / rb %d: skipping SSS REs\n",symbol,prb);
}
}
}
if
(
rb_alloc_ind
==
1
)
{
// PRB is allocated
//PSS in subframe 0/5 if FDD
if
(
frame_parms
->
frame_type
==
FDD
)
{
//FDD
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
prb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
rb_alloc_ind
=
0
;
// printf("symbol %d / rb %d: skipping PSS REs\n",symbol,prb);
}
}
if
((
frame_parms
->
frame_type
==
TDD
)
&&
(
subframe
==
6
))
{
//TDD Subframe 6
if
((
prb
>=
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
rb_alloc_ind
=
0
;
}
}
if
(
rb_alloc_ind
==
1
)
{
// PRB is allocated
if
((
frame_parms
->
N_RB_DL
&
1
)
==
0
)
{
// even number of RBs
prb_off
=
12
*
prb
;
prb_off
=
12
*
prb
;
prb_off2
=
1
+
(
12
*
(
prb
-
(
frame_parms
->
N_RB_DL
>>
1
)));
prb_off2
=
1
+
(
12
*
(
prb
-
(
frame_parms
->
N_RB_DL
>>
1
)));
...
@@ -3912,11 +3919,55 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -3912,11 +3919,55 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
rxF_ext
+=
8
;
rxF_ext
+=
8
;
}
// pilots==1
}
// pilots==1
}
}
else
{
// Odd number of RBs
}
else
{
// Odd number of RBs
skip_half
=
0
;
// PBCH
if
((
subframe
==
0
)
&&
(
prb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
>=
(
nsymb
>>
1
))
&&
(
l
<
((
nsymb
>>
1
)
+
4
)))
{
rb_alloc_ind
=
0
;
// printf("symbol %d / rb %d: skipping PBCH REs\n",symbol,prb);
}
//SSS
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
prb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
sss_symb
)
)
{
rb_alloc_ind
=
0
;
// printf("symbol %d / rb %d: skipping SSS REs\n",symbol,prb);
}
//PSS in subframe 0/5 if FDD
if
(
frame_parms
->
frame_type
==
FDD
)
{
//FDD
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
(
prb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
rb_alloc_ind
=
0
;
// printf("symbol %d / rb %d: skipping PSS REs\n",symbol,prb);
}
}
if
((
frame_parms
->
frame_type
==
TDD
)
&&
((
subframe
==
1
)
||
(
subframe
==
6
)))
{
//TDD Subframe 1-6
if
((
prb
>
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
prb
<
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
)
)
{
rb_alloc_ind
=
0
;
}
}
if
(
rb_alloc_ind
==
1
)
{
skip_half
=
0
;
//Check if we have to drop half a PRB due to PSS/SSS/PBCH
//Check if we have to drop half a PRB due to PSS/SSS/PBCH
// skip_half == 0 means full PRB
// skip_half == 0 means full PRB
// skip_half == 1 means first half is used (leftmost half-PRB from PSS/SSS/PBCH)
// skip_half == 1 means first half is used (leftmost half-PRB from PSS/SSS/PBCH)
...
@@ -3947,13 +3998,12 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -3947,13 +3998,12 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
if
(((
frame_parms
->
frame_type
==
FDD
)
&&
if
(((
frame_parms
->
frame_type
==
FDD
)
&&
(((
subframe
==
0
)
||
(
subframe
==
5
))))
||
//FDD Subframes 0,5
(((
subframe
==
0
)
||
(
subframe
==
5
))))
||
//FDD Subframes 0,5
((
frame_parms
->
frame_type
==
TDD
)
&&
((
frame_parms
->
frame_type
==
TDD
)
&&
(((
subframe
==
2
)
||
(
subframe
==
6
)))))
{
//TDD Subframes 2
,6
(((
subframe
==
1
)
||
(
subframe
==
6
)))))
{
//TDD Subframes 1
,6
if
((
prb
==
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
if
((
prb
==
((
frame_parms
->
N_RB_DL
>>
1
)
-
3
))
&&
(
l
==
pss_symb
))
(
l
==
pss_symb
))
skip_half
=
1
;
skip_half
=
1
;
else
if
(((
subframe
==
0
)
||
(
subframe
==
5
))
&&
else
if
((
prb
==
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
prb
==
((
frame_parms
->
N_RB_DL
>>
1
)
+
3
))
&&
(
l
==
pss_symb
))
(
l
==
pss_symb
))
skip_half
=
2
;
skip_half
=
2
;
}
}
...
@@ -3973,9 +4023,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -3973,9 +4023,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
rxF
=
&
rxdataF
[
aarx
][
prb_off2
+
rxF
=
&
rxdataF
[
aarx
][
prb_off2
+
(
symbol
*
(
frame_parms
->
ofdm_symbol_size
))];
(
symbol
*
(
frame_parms
->
ofdm_symbol_size
))];
}
}
#ifdef DEBUG_DLSCH_DEMOD
//
printf("symbol %d / rb %d: alloc %d skip_half %d (rxF %p, rxF_ext %p) prb_off (%d,%d)\n",symbol,prb,rb_alloc_ind,skip_half,rxF,rxF_ext,prb_off,prb_off2);
printf
(
"symbol %d / rb %d: alloc %d skip_half %d (rxF %p, rxF_ext %p) prb_off (%d,%d)
\n
"
,
symbol
,
prb
,
rb_alloc_ind
,
skip_half
,
rxF
,
rxF_ext
,
prb_off
,
prb_off2
);
#endif
*
pmi_loc
=
(
pmi
>>
((
prb
>>
2
)
<<
1
))
&
3
;
*
pmi_loc
=
(
pmi
>>
((
prb
>>
2
)
<<
1
))
&
3
;
// printf("symbol_mod %d (pilots %d) rb %d, sb %d, pmi %d (pmi_loc %p,rxF %p, ch00 %p, ch01 %p, rxF_ext %p dl_ch0_ext %p dl_ch1_ext %p)\n",symbol_mod,pilots,rb,rb>>2,*pmi_loc,pmi_loc,rxF,dl_ch0, dl_ch1, rxF_ext,dl_ch0_ext,dl_ch1_ext);
// printf("symbol_mod %d (pilots %d) rb %d, sb %d, pmi %d (pmi_loc %p,rxF %p, ch00 %p, ch01 %p, rxF_ext %p dl_ch0_ext %p dl_ch1_ext %p)\n",symbol_mod,pilots,rb,rb>>2,*pmi_loc,pmi_loc,rxF,dl_ch0, dl_ch1, rxF_ext,dl_ch0_ext,dl_ch1_ext);
...
@@ -3987,6 +4037,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -3987,6 +4037,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
6
*
sizeof
(
int32_t
));
#ifdef DEBUG_DLSCH_DEMOD
for
(
i
=
0
;
i
<
6
;
i
++
)
printf
(
"extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
i
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
i
]));
#endif
dl_ch0_ext
+=
6
;
dl_ch0_ext
+=
6
;
dl_ch1_ext
+=
6
;
dl_ch1_ext
+=
6
;
rxF_ext
+=
6
;
rxF_ext
+=
6
;
...
@@ -3994,6 +4048,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -3994,6 +4048,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
memcpy
(
dl_ch0_ext
,
dl_ch0p
+
6
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch0_ext
,
dl_ch0p
+
6
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
+
6
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
+
6
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
+
6
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
+
6
,
6
*
sizeof
(
int32_t
));
#ifdef DEBUG_DLSCH_DEMOD
for
(
i
=
0
;
i
<
6
;
i
++
)
printf
(
"extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
i
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
i
]));
#endif
dl_ch0_ext
+=
6
;
dl_ch0_ext
+=
6
;
dl_ch1_ext
+=
6
;
dl_ch1_ext
+=
6
;
rxF_ext
+=
6
;
rxF_ext
+=
6
;
...
@@ -4001,8 +4059,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4001,8 +4059,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
12
*
sizeof
(
int32_t
));
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
12
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
12
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
12
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
12
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
12
*
sizeof
(
int32_t
));
// for (i=0;i<12;i++)
#ifdef DEBUG_DLSCH_DEMOD
// printf("extract rb %d, re %d => (%d,%d)\n",prb,i,*(short *)&rxF_ext[i],*(1+(short*)&rxF_ext[i]));
for
(
i
=
0
;
i
<
12
;
i
++
)
printf
(
"extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
i
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
i
]));
#endif
dl_ch0_ext
+=
12
;
dl_ch0_ext
+=
12
;
dl_ch1_ext
+=
12
;
dl_ch1_ext
+=
12
;
rxF_ext
+=
12
;
rxF_ext
+=
12
;
...
@@ -4015,7 +4075,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4015,7 +4075,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
if
((
i
!=
frame_parms
->
nushift
)
&&
if
((
i
!=
frame_parms
->
nushift
)
&&
(
i
!=
((
frame_parms
->
nushift
+
3
)
%
6
)))
{
(
i
!=
((
frame_parms
->
nushift
+
3
)
%
6
)))
{
rxF_ext
[
j
]
=
rxF
[
i
];
rxF_ext
[
j
]
=
rxF
[
i
];
// printf("(pilots,skip1)extract rb %d, re %d => (%d,%d)\n",prb,i,*(short *)&rxF_ext[j],*(1+(short*)&rxF_ext[j]));
#ifdef DEBUG_DLSCH_DEMOD
printf
(
"(pilots,skip1)extract rb %d, re %d (%d)=> (%d,%d)
\n
"
,
prb
,
i
,
j
,
*
(
short
*
)
&
rxF_ext
[
j
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
j
]));
#endif
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch1_ext
[
j
++
]
=
dl_ch1p
[
i
];
dl_ch1_ext
[
j
++
]
=
dl_ch1p
[
i
];
}
}
...
@@ -4028,15 +4090,17 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4028,15 +4090,17 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
if
((
i
!=
frame_parms
->
nushift
)
&&
if
((
i
!=
frame_parms
->
nushift
)
&&
(
i
!=
((
frame_parms
->
nushift
+
3
)
%
6
)))
{
(
i
!=
((
frame_parms
->
nushift
+
3
)
%
6
)))
{
rxF_ext
[
j
]
=
rxF
[(
i
+
6
)];
rxF_ext
[
j
]
=
rxF
[(
i
+
6
)];
// printf("(pilots,skip2)extract rb %d, re %d => (%d,%d)\n",prb,i,*(short *)&rxF_ext[j],*(1+(short*)&rxF_ext[j]));
#ifdef DEBUG_DLSCH_DEMOD
printf
(
"(pilots,skip2)extract rb %d, re %d (%d) => (%d,%d)
\n
"
,
prb
,
i
,
j
,
*
(
short
*
)
&
rxF_ext
[
j
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
j
]));
#endif
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
+
6
];
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
+
6
];
dl_ch1_ext
[
j
++
]
=
dl_ch1p
[
i
+
6
];
dl_ch1_ext
[
j
++
]
=
dl_ch1p
[
i
+
6
];
}
}
dl_ch0_ext
+=
4
;
dl_ch1_ext
+=
4
;
rxF_ext
+=
4
;
}
}
dl_ch0_ext
+=
4
;
dl_ch1_ext
+=
4
;
rxF_ext
+=
4
;
}
else
{
//skip_half==0
}
else
{
//skip_half==0
for
(
i
=
0
;
i
<
12
;
i
++
)
{
for
(
i
=
0
;
i
<
12
;
i
++
)
{
if
((
i
!=
frame_parms
->
nushift
)
&&
if
((
i
!=
frame_parms
->
nushift
)
&&
...
@@ -4044,7 +4108,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4044,7 +4108,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
(
i
!=
frame_parms
->
nushift
+
6
)
&&
(
i
!=
frame_parms
->
nushift
+
6
)
&&
(
i
!=
((
frame_parms
->
nushift
+
9
)
%
12
)))
{
(
i
!=
((
frame_parms
->
nushift
+
9
)
%
12
)))
{
rxF_ext
[
j
]
=
rxF
[
i
];
rxF_ext
[
j
]
=
rxF
[
i
];
// printf("(pilots)extract rb %d, re %d => (%d,%d)\n",prb,i,*(short *)&rxF_ext[j],*(1+(short*)&rxF_ext[j]));
#ifdef DEBUG_DLSCH_DEMOD
printf
(
"(pilots)extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
j
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
j
]));
#endif
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch1_ext
[
j
++
]
=
dl_ch1p
[
i
];
dl_ch1_ext
[
j
++
]
=
dl_ch1p
[
i
];
}
}
...
@@ -4060,10 +4126,11 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4060,10 +4126,11 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
6
*
sizeof
(
int32_t
));
/*
#ifdef DEBUG_DLSCH_DEMOD
for
(
i
=
0
;
i
<
6
;
i
++
)
{
for
(
i
=
0
;
i
<
6
;
i
++
)
{
printf
(
"extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
i
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
i
]));
printf
(
"extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
i
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
i
]));
}*/
}
#endif
rxF_ext
+=
6
;
rxF_ext
+=
6
;
dl_ch0_ext
+=
6
;
dl_ch0_ext
+=
6
;
dl_ch1_ext
+=
6
;
dl_ch1_ext
+=
6
;
...
@@ -4075,9 +4142,11 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4075,9 +4142,11 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch0_ext
,
dl_ch0p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
6
*
sizeof
(
int32_t
));
memcpy
(
dl_ch1_ext
,
dl_ch1p
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
6
*
sizeof
(
int32_t
));
memcpy
(
rxF_ext
,
rxF
,
6
*
sizeof
(
int32_t
));
/*for (i=0; i<6; i++) {
#ifdef DEBUG_DLSCH_DEMOD
for
(
i
=
0
;
i
<
6
;
i
++
)
{
printf
(
"extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
i
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
i
]));
printf
(
"extract rb %d, re %d => (%d,%d)
\n
"
,
prb
,
i
,
*
(
short
*
)
&
rxF_ext
[
i
],
*
(
1
+
(
short
*
)
&
rxF_ext
[
i
]));
}*/
}
#endif
rxF_ext
+=
6
;
rxF_ext
+=
6
;
dl_ch0_ext
+=
6
;
dl_ch0_ext
+=
6
;
dl_ch1_ext
+=
6
;
dl_ch1_ext
+=
6
;
...
@@ -4090,7 +4159,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4090,7 +4159,9 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch1_ext
[
j
]
=
dl_ch1p
[
i
];
dl_ch1_ext
[
j
]
=
dl_ch1p
[
i
];
rxF_ext
[
j
++
]
=
rxF
[
i
];
rxF_ext
[
j
++
]
=
rxF
[
i
];
//printf("(pilots)extract rb %d, re %d => (%d,%d)\n",prb,i,*(short *)&rxF[i],*(1+(short*)&rxF[i]));
#ifdef DEBUG_DLSCH_DEMOD
printf
(
"(pilots)extract rb %d, re %d (%d) => (%d,%d)
\n
"
,
prb
,
i
,
j
,
*
(
short
*
)
&
rxF
[
i
],
*
(
1
+
(
short
*
)
&
rxF
[
i
]));
#endif
}
}
}
}
rxF
=
&
rxdataF
[
aarx
][
1
+
symbol
*
(
frame_parms
->
ofdm_symbol_size
)];
rxF
=
&
rxdataF
[
aarx
][
1
+
symbol
*
(
frame_parms
->
ofdm_symbol_size
)];
...
@@ -4100,8 +4171,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
...
@@ -4100,8 +4171,10 @@ unsigned short dlsch_extract_rbs_dual(int **rxdataF,
(
i
!=
((
frame_parms
->
nushift
+
9
)
%
12
)))
{
(
i
!=
((
frame_parms
->
nushift
+
9
)
%
12
)))
{
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch0_ext
[
j
]
=
dl_ch0p
[
i
];
dl_ch1_ext
[
j
]
=
dl_ch1p
[
i
];
dl_ch1_ext
[
j
]
=
dl_ch1p
[
i
];
rxF_ext
[
j
++
]
=
rxF
[(
i
-
6
)];
rxF_ext
[
j
++
]
=
rxF
[
i
-
6
];
//printf("(pilots)extract rb %d, re %d => (%d,%d)\n",prb,i,*(short *)&rxF[1+i-6],*(1+(short*)&rxF[1+i-6]));
#ifdef DEBUG_DLSCH_DEMOD
printf
(
"(pilots)extract rb %d, re %d (%d) => (%d,%d)
\n
"
,
prb
,
i
,
j
,
*
(
short
*
)
&
rxF
[
1
+
i
-
6
],
*
(
1
+
(
short
*
)
&
rxF
[
1
+
i
-
6
]));
#endif
}
}
}
}
...
...
openair1/PHY/LTE_TRANSPORT/dlsch_llr_computation.c
View file @
eee0a155
...
@@ -672,6 +672,7 @@ int dlsch_qpsk_llr(LTE_DL_FRAME_PARMS *frame_parms,
...
@@ -672,6 +672,7 @@ int dlsch_qpsk_llr(LTE_DL_FRAME_PARMS *frame_parms,
// printf("dlsch_qpsk_llr: symbol %d,nb_rb %d, len %d,pbch_pss_sss_adjust %d\n",symbol,nb_rb,len,pbch_pss_sss_adjust);
// printf("dlsch_qpsk_llr: symbol %d,nb_rb %d, len %d,pbch_pss_sss_adjust %d\n",symbol,nb_rb,len,pbch_pss_sss_adjust);
for
(
i
=
0
;
i
<
len
;
i
++
)
{
for
(
i
=
0
;
i
<
len
;
i
++
)
{
*
llr32
=
*
rxF
;
*
llr32
=
*
rxF
;
// printf("llr %d : (%d,%d)\n",i,((int16_t*)llr32)[0],((int16_t*)llr32)[1]);
rxF
++
;
rxF
++
;
llr32
++
;
llr32
++
;
}
}
...
...
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