Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
openairinterface5G
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Merge Requests
20
Merge Requests
20
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
oai
openairinterface5G
Commits
15cd4ab0
Commit
15cd4ab0
authored
Apr 06, 2016
by
Florian Kaltenberger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleanup for Mdlharq usage/meaning
parent
ce454d64
Changes
37
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
37 changed files
with
169 additions
and
1044 deletions
+169
-1044
openair1/PHY/CODING/3gpplte_turbo_decoder_avx2_16bit.c
openair1/PHY/CODING/3gpplte_turbo_decoder_avx2_16bit.c
+8
-5
openair1/PHY/CODING/defs.h
openair1/PHY/CODING/defs.h
+11
-0
openair1/PHY/CODING/lte_rate_matching.c
openair1/PHY/CODING/lte_rate_matching.c
+17
-6
openair1/PHY/INIT/lte_init.c
openair1/PHY/INIT/lte_init.c
+6
-17
openair1/PHY/LTE_REFSIG/defs.h
openair1/PHY/LTE_REFSIG/defs.h
+4
-4
openair1/PHY/LTE_REFSIG/lte_dl_cell_spec.c
openair1/PHY/LTE_REFSIG/lte_dl_cell_spec.c
+4
-4
openair1/PHY/LTE_REFSIG/lte_dl_mbsfn.c
openair1/PHY/LTE_REFSIG/lte_dl_mbsfn.c
+2
-2
openair1/PHY/LTE_REFSIG/lte_dl_uespec.c
openair1/PHY/LTE_REFSIG/lte_dl_uespec.c
+2
-2
openair1/PHY/LTE_TRANSPORT/dci.c
openair1/PHY/LTE_TRANSPORT/dci.c
+7
-7
openair1/PHY/LTE_TRANSPORT/defs.h
openair1/PHY/LTE_TRANSPORT/defs.h
+8
-8
openair1/PHY/LTE_TRANSPORT/dlsch_coding.c
openair1/PHY/LTE_TRANSPORT/dlsch_coding.c
+1
-0
openair1/PHY/LTE_TRANSPORT/dlsch_modulation.c
openair1/PHY/LTE_TRANSPORT/dlsch_modulation.c
+4
-4
openair1/PHY/LTE_TRANSPORT/drs_modulation.c
openair1/PHY/LTE_TRANSPORT/drs_modulation.c
+13
-13
openair1/PHY/LTE_TRANSPORT/pbch.c
openair1/PHY/LTE_TRANSPORT/pbch.c
+2
-2
openair1/PHY/LTE_TRANSPORT/pcfich.c
openair1/PHY/LTE_TRANSPORT/pcfich.c
+2
-2
openair1/PHY/LTE_TRANSPORT/phich.c
openair1/PHY/LTE_TRANSPORT/phich.c
+4
-4
openair1/PHY/LTE_TRANSPORT/pilots.c
openair1/PHY/LTE_TRANSPORT/pilots.c
+2
-2
openair1/PHY/LTE_TRANSPORT/pilots_mbsfn.c
openair1/PHY/LTE_TRANSPORT/pilots_mbsfn.c
+1
-1
openair1/PHY/LTE_TRANSPORT/proto.h
openair1/PHY/LTE_TRANSPORT/proto.h
+18
-18
openair1/PHY/LTE_TRANSPORT/pss.c
openair1/PHY/LTE_TRANSPORT/pss.c
+1
-1
openair1/PHY/LTE_TRANSPORT/pucch.c
openair1/PHY/LTE_TRANSPORT/pucch.c
+2
-2
openair1/PHY/LTE_TRANSPORT/srs_modulation.c
openair1/PHY/LTE_TRANSPORT/srs_modulation.c
+5
-5
openair1/PHY/LTE_TRANSPORT/sss.c
openair1/PHY/LTE_TRANSPORT/sss.c
+1
-1
openair1/PHY/LTE_TRANSPORT/ulsch_coding.c
openair1/PHY/LTE_TRANSPORT/ulsch_coding.c
+5
-6
openair1/PHY/LTE_TRANSPORT/ulsch_decoding.c
openair1/PHY/LTE_TRANSPORT/ulsch_decoding.c
+6
-21
openair1/PHY/LTE_TRANSPORT/ulsch_modulation.c
openair1/PHY/LTE_TRANSPORT/ulsch_modulation.c
+3
-3
openair1/PHY/MODULATION/defs.h
openair1/PHY/MODULATION/defs.h
+1
-1
openair1/PHY/MODULATION/ofdm_mod.c
openair1/PHY/MODULATION/ofdm_mod.c
+1
-1
openair1/PHY/TOOLS/lte_dfts.c
openair1/PHY/TOOLS/lte_dfts.c
+0
-1
openair1/PHY/defs.h
openair1/PHY/defs.h
+0
-1
openair1/PHY/impl_defs_lte.h
openair1/PHY/impl_defs_lte.h
+2
-3
openair1/PHY/impl_defs_top.h
openair1/PHY/impl_defs_top.h
+8
-65
openair1/PHY/spec_defs.h
openair1/PHY/spec_defs.h
+0
-745
openair1/PHY/spec_defs_top.h
openair1/PHY/spec_defs_top.h
+0
-68
openair1/SCHED/phy_procedures_lte_eNb.c
openair1/SCHED/phy_procedures_lte_eNb.c
+9
-10
targets/RT/USER/lte-softmodem.c
targets/RT/USER/lte-softmodem.c
+2
-2
targets/SIMU/USER/init_lte.c
targets/SIMU/USER/init_lte.c
+7
-7
No files found.
openair1/PHY/CODING/3gpplte_turbo_decoder_avx2_16bit.c
View file @
15cd4ab0
...
...
@@ -940,9 +940,8 @@ unsigned char phy_threegpplte_turbo_decoder16avx2(int16_t *y,
uint32_t
db
;
__m128i
*
yp128
,
*
yp128_cw2
;
__m256i
tmp
,
zeros
=
_mm256_setzero_si256
();
__m128i
tmpe
,
tmpe_cw2
;
int
offset8_flag
=
0
;
...
...
@@ -988,9 +987,6 @@ unsigned char phy_threegpplte_turbo_decoder16avx2(int16_t *y,
}
yp128
=
(
__m128i
*
)
y
;
yp128_cw2
=
(
__m128i
*
)
y2
;
s
=
systematic0
;
s1
=
systematic1
;
s2
=
systematic2
;
...
...
@@ -999,6 +995,13 @@ unsigned char phy_threegpplte_turbo_decoder16avx2(int16_t *y,
#if 0
__m128i *yp128,*yp128_cw2;
__m128i tmpe,tmpe_cw2;
yp128 = (__m128i*)y;
yp128_cw2 = (__m128i*)y2;
for (i=0; i<n; i+=8) {
pi2_p = &pi2tab16avx2[iind][i];
...
...
openair1/PHY/CODING/defs.h
View file @
15cd4ab0
...
...
@@ -372,6 +372,17 @@ void init_td8 (void);
\brief This function initializes the tables for 16-bit LLR Turbo decoder.*/
void
init_td16
(
void
);
#ifdef __AVX2__
/*!\fn void init_td8(void)
\brief This function initializes the tables for 8-bit LLR Turbo decoder (AVX2).*/
void
init_td8avx2
(
void
);
/*!\fn void init_td16(void)
\brief This function initializes the tables for 16-bit LLR Turbo decoder (AVX2).*/
void
init_td16avx2
(
void
);
#endif
/*!\fn uint32_t crc24a(uint8_t *inPtr, int32_t bitlen)
\brief This computes a 24-bit crc ('a' variant for overall transport block)
based on 3GPP UMTS/LTE specifications.
...
...
openair1/PHY/CODING/lte_rate_matching.c
View file @
15cd4ab0
...
...
@@ -495,8 +495,14 @@ uint32_t lte_rate_matching_turbo(uint32_t RTC,
char
fname
[
512
];
#endif
Nir
=
Nsoft
/
Kmimo
/
cmin
(
8
,
Mdlharq
);
Ncb
=
cmin
(
Nir
/
C
,
3
*
(
RTC
<<
5
));
if
(
Mdlharq
>
0
)
{
// Downlink
Nir
=
Nsoft
/
Kmimo
/
cmin
(
8
,
Mdlharq
);
Ncb
=
cmin
(
Nir
/
C
,
3
*
(
RTC
<<
5
));
}
else
{
// Uplink
Nir
=
0
;
Ncb
=
3
*
(
RTC
<<
5
);
// Kw
}
#ifdef RM_DEBUG_TX
if
(
rvidx
==
0
&&
r
==
0
)
{
...
...
@@ -709,15 +715,20 @@ int lte_rate_matching_turbo_rx(uint32_t RTC,
int
nulled
=
0
;
#endif
if
(
Kmimo
==
0
||
Mdlharq
==
0
||
C
==
0
||
Qm
==
0
||
Nl
==
0
)
{
if
(
Kmimo
==
0
||
C
==
0
||
Qm
==
0
||
Nl
==
0
)
{
printf
(
"lte_rate_matching.c: invalid parameters (Kmimo %d, Mdlharq %d, C %d, Qm %d, Nl %d
\n
"
,
Kmimo
,
Mdlharq
,
C
,
Qm
,
Nl
);
return
(
-
1
);
}
Nir
=
Nsoft
/
Kmimo
/
cmin
(
8
,
Mdlharq
);
Ncb
=
cmin
(
Nir
/
C
,
3
*
(
RTC
<<
5
));
if
(
Mdlharq
>
0
)
{
// Downlink
Nir
=
Nsoft
/
Kmimo
/
cmin
(
8
,
Mdlharq
);
Ncb
=
cmin
(
Nir
/
C
,
3
*
(
RTC
<<
5
));
}
else
{
// Uplink
Nir
=
0
;
Ncb
=
3
*
(
RTC
<<
5
);
}
Gp
=
G
/
Nl
/
Qm
;
GpmodC
=
Gp
%
C
;
...
...
openair1/PHY/INIT/lte_init.c
View file @
15cd4ab0
...
...
@@ -26,17 +26,6 @@
Address : Eurecom, Campus SophiaTech, 450 Route des Chappes, CS 50193 - 06904 Biot Sophia Antipolis cedex, FRANCE
*******************************************************************************/
/*
#ifdef CBMIMO1
#include "ARCH/COMMON/defs.h"
#include "ARCH/CBMIMO1/DEVICE_DRIVER/from_grlib_softconfig.h"
#include "ARCH/CBMIMO1/DEVICE_DRIVER/cbmimo1_device.h"
#include "ARCH/CBMIMO1/DEVICE_DRIVER/defs.h"
#include "ARCH/CBMIMO1/DEVICE_DRIVER/extern.h"
#include "ARCH/CBMIMO1/DEVICE_DRIVER/cbmimo1_pci.h"
//#include "pci_commands.h"
#endif //CBMIMO1
*/
#ifdef EXMIMO
#include "openair0_lib.h"
#endif
...
...
@@ -1053,7 +1042,7 @@ int phy_init_lte_ue(PHY_VARS_UE *phy_vars_ue,
// init TX buffers
ue_common_vars
->
txdata
=
(
int32_t
**
)
malloc16
(
frame_parms
->
nb_antennas_tx
*
sizeof
(
int32_t
*
)
);
ue_common_vars
->
txdataF
=
(
mod_sym_t
**
)
malloc16
(
frame_parms
->
nb_antennas_tx
*
sizeof
(
mod_sym
_t
*
)
);
ue_common_vars
->
txdataF
=
(
int32_t
**
)
malloc16
(
frame_parms
->
nb_antennas_tx
*
sizeof
(
int32
_t
*
)
);
for
(
i
=
0
;
i
<
frame_parms
->
nb_antennas_tx
;
i
++
)
{
#ifdef USER_MODE
...
...
@@ -1061,7 +1050,7 @@ int phy_init_lte_ue(PHY_VARS_UE *phy_vars_ue,
#else //USER_MODE
ue_common_vars
->
txdata
[
i
]
=
TX_DMA_BUFFER
[
0
][
i
];
#endif //USER_MODE
ue_common_vars
->
txdataF
[
i
]
=
(
mod_sym_t
*
)
malloc16_clear
(
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
mod_sym
_t
)
);
ue_common_vars
->
txdataF
[
i
]
=
(
int32_t
*
)
malloc16_clear
(
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
int32
_t
)
);
}
// init RX buffers
...
...
@@ -1274,21 +1263,21 @@ int phy_init_lte_eNB(PHY_VARS_eNB *phy_vars_eNB,
// TX vars
eNB_common_vars
->
txdata
[
eNB_id
]
=
(
int32_t
**
)
malloc16
(
frame_parms
->
nb_antennas_tx
*
sizeof
(
int32_t
*
)
);
eNB_common_vars
->
txdataF
[
eNB_id
]
=
(
mod_sym_t
**
)
malloc16
(
frame_parms
->
nb_antennas_tx
*
sizeof
(
mod_sym
_t
*
)
);
eNB_common_vars
->
txdataF
[
eNB_id
]
=
(
int32_t
**
)
malloc16
(
frame_parms
->
nb_antennas_tx
*
sizeof
(
int32
_t
*
)
);
for
(
i
=
0
;
i
<
frame_parms
->
nb_antennas_tx
;
i
++
)
{
#ifdef USER_MODE
eNB_common_vars
->
txdata
[
eNB_id
][
i
]
=
(
int32_t
*
)
malloc16_clear
(
FRAME_LENGTH_COMPLEX_SAMPLES
*
sizeof
(
int32_t
)
);
eNB_common_vars
->
txdataF
[
eNB_id
][
i
]
=
(
mod_sym_t
*
)
malloc16_clear
(
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
mod_sym
_t
)
);
eNB_common_vars
->
txdataF
[
eNB_id
][
i
]
=
(
int32_t
*
)
malloc16_clear
(
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
int32
_t
)
);
#else // USER_MODE
eNB_common_vars
->
txdata
[
eNB_id
][
i
]
=
TX_DMA_BUFFER
[
eNB_id
][
i
];
eNB_common_vars
->
txdataF
[
eNB_id
][
i
]
=
(
mod_sym_t
*
)
malloc16_clear
(
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
mod_sym
_t
)
);
eNB_common_vars
->
txdataF
[
eNB_id
][
i
]
=
(
int32_t
*
)
malloc16_clear
(
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
int32
_t
)
);
#endif //USER_MODE
#ifdef DEBUG_PHY
msg
(
"[openair][LTE_PHY][INIT] lte_eNB_common_vars->txdata[%d][%d] = %p
\n
"
,
eNB_id
,
i
,
eNB_common_vars
->
txdata
[
eNB_id
][
i
]);
msg
(
"[openair][LTE_PHY][INIT] lte_eNB_common_vars->txdataF[%d][%d] = %p (%d bytes)
\n
"
,
eNB_id
,
i
,
eNB_common_vars
->
txdataF
[
eNB_id
][
i
],
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
mod_sym
_t
));
FRAME_LENGTH_COMPLEX_SAMPLES_NO_PREFIX
*
sizeof
(
int32
_t
));
#endif
}
...
...
openair1/PHY/LTE_REFSIG/defs.h
View file @
15cd4ab0
...
...
@@ -73,7 +73,7 @@ void lte_gold_mbsfn(LTE_DL_FRAME_PARMS *frame_parms,uint32_t lte_gold_mbsfn_tabl
int
lte_dl_cell_spec
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
*
output
,
int32
_t
*
output
,
short
amp
,
unsigned
char
Ns
,
unsigned
char
l
,
...
...
@@ -89,7 +89,7 @@ int lte_dl_cell_spec(PHY_VARS_eNB *phy_vars_eNB,
*/
int
lte_dl_ue_spec
(
PHY_VARS_eNB
*
phy_vars_eNB
,
uint8_t
UE_id
,
mod_sym
_t
*
output
,
int32
_t
*
output
,
short
amp
,
uint8_t
Ns
,
uint8_t
p
,
...
...
@@ -102,7 +102,7 @@ int lte_dl_ue_spec(PHY_VARS_eNB *phy_vars_eNB,
@param Ns Slot number (0..19)
@param l symbol (0,1,2)
*/
int
lte_dl_mbsfn
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
*
output
,
int
lte_dl_mbsfn
(
PHY_VARS_eNB
*
phy_vars_eNB
,
int32
_t
*
output
,
short
amp
,
int
subframe
,
unsigned
char
l
);
...
...
@@ -148,7 +148,7 @@ void free_ul_ref_sigs(void);
@sub_frame_offset Offset of this subframe in units of subframes
*/
int
lte_generate_srs
(
mod_sym
_t
**
txdataF
,
int
lte_generate_srs
(
int32
_t
**
txdataF
,
short
amp
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
unsigned
int
sub_frame_offset
);
...
...
openair1/PHY/LTE_REFSIG/lte_dl_cell_spec.c
View file @
15cd4ab0
...
...
@@ -41,7 +41,7 @@
//Calibration
int
lte_dl_cell_spec_SS
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
*
output
,
int32
_t
*
output
,
short
amp
,
unsigned
char
Ns
,
unsigned
char
l
,
//nb of sym per slot
...
...
@@ -50,7 +50,7 @@ int lte_dl_cell_spec_SS(PHY_VARS_eNB *phy_vars_eNB,
unsigned
char
nu
,
mprime
,
mprime_dword
,
mprime_qpsk_symb
,
m
;
unsigned
short
k
,
a
;
mod_sym
_t
qpsk
[
4
];
int32
_t
qpsk
[
4
];
a
=
(
amp
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
((
short
*
)
&
qpsk
[
0
])[
0
]
=
a
;
...
...
@@ -121,7 +121,7 @@ int lte_dl_cell_spec_SS(PHY_VARS_eNB *phy_vars_eNB,
int
lte_dl_cell_spec
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
*
output
,
int32
_t
*
output
,
short
amp
,
unsigned
char
Ns
,
unsigned
char
l
,
...
...
@@ -130,7 +130,7 @@ int lte_dl_cell_spec(PHY_VARS_eNB *phy_vars_eNB,
unsigned
char
nu
,
mprime
,
mprime_dword
,
mprime_qpsk_symb
,
m
;
unsigned
short
k
,
a
;
mod_sym
_t
qpsk
[
4
];
int32
_t
qpsk
[
4
];
a
=
(
amp
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
((
short
*
)
&
qpsk
[
0
])[
0
]
=
a
;
...
...
openair1/PHY/LTE_REFSIG/lte_dl_mbsfn.c
View file @
15cd4ab0
...
...
@@ -39,7 +39,7 @@
//extern unsigned int lte_gold_table[10][3][42];
//#define DEBUG_DL_MBSFN
int
lte_dl_mbsfn
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
*
output
,
int
lte_dl_mbsfn
(
PHY_VARS_eNB
*
phy_vars_eNB
,
int32
_t
*
output
,
short
amp
,
int
subframe
,
unsigned
char
l
)
...
...
@@ -47,7 +47,7 @@ int lte_dl_mbsfn(PHY_VARS_eNB *phy_vars_eNB, mod_sym_t *output,
unsigned
int
mprime
,
mprime_dword
,
mprime_qpsk_symb
,
m
;
unsigned
short
k
=
0
,
a
;
mod_sym
_t
qpsk
[
4
];
int32
_t
qpsk
[
4
];
a
=
(
amp
*
ONE_OVER_SQRT2_Q15
)
>>
15
;
((
short
*
)
&
qpsk
[
0
])[
0
]
=
a
;
...
...
openair1/PHY/LTE_REFSIG/lte_dl_uespec.c
View file @
15cd4ab0
...
...
@@ -54,14 +54,14 @@ int Wbar_NCP[8][4] = {{1,1,1,1},{1,-1,1,-1},{1,1,1,1},{1,-1,1,-1},{1,1,-1,-1},{-
int
lte_dl_ue_spec
(
PHY_VARS_eNB
*
phy_vars_eNB
,
uint8_t
UE_id
,
mod_sym
_t
*
output
,
int32
_t
*
output
,
short
amp
,
uint8_t
Ns
,
uint8_t
p
,
int
SS_flag
)
{
mod_sym
_t
qpsk
[
4
],
nqpsk
[
4
],
*
qpsk_p
,
*
output_p
;
int32
_t
qpsk
[
4
],
nqpsk
[
4
],
*
qpsk_p
,
*
output_p
;
int16_t
a
;
int
w
,
lprime
,
ind
,
l
,
ind_dword
,
ind_qpsk_symb
,
nPRB
;
// LTE_eNB_DLSCH_t *dlsch = phy_vars_eNB->dlsch_eNB[UE_id][0];
...
...
openair1/PHY/LTE_TRANSPORT/dci.c
View file @
15cd4ab0
...
...
@@ -272,12 +272,12 @@ uint32_t Y;
//#define Mquad (Msymb/4)
static
uint32_t
bitrev_cc_dci
[
32
]
=
{
1
,
17
,
9
,
25
,
5
,
21
,
13
,
29
,
3
,
19
,
11
,
27
,
7
,
23
,
15
,
31
,
0
,
16
,
8
,
24
,
4
,
20
,
12
,
28
,
2
,
18
,
10
,
26
,
6
,
22
,
14
,
30
};
static
mod_sym
_t
wtemp
[
2
][
Msymb
];
static
int32
_t
wtemp
[
2
][
Msymb
];
void
pdcch_interleaving
(
LTE_DL_FRAME_PARMS
*
frame_parms
,
mod_sym_t
**
z
,
mod_sym
_t
**
wbar
,
uint8_t
n_symbols_pdcch
,
uint8_t
mi
)
void
pdcch_interleaving
(
LTE_DL_FRAME_PARMS
*
frame_parms
,
int32_t
**
z
,
int32
_t
**
wbar
,
uint8_t
n_symbols_pdcch
,
uint8_t
mi
)
{
mod_sym
_t
*
wptr
,
*
wptr2
,
*
zptr
;
int32
_t
*
wptr
,
*
wptr2
,
*
zptr
;
uint32_t
Mquad
=
get_nquad
(
n_symbols_pdcch
,
frame_parms
,
mi
);
uint32_t
RCC
=
(
Mquad
>>
5
),
ND
;
uint32_t
row
,
col
,
Kpi
,
index
;
...
...
@@ -2027,7 +2027,7 @@ uint8_t generate_dci_top(uint8_t num_ue_spec_dci,
uint32_t
n_rnti
,
int16_t
amp
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
uint32_t
subframe
)
{
...
...
@@ -2038,10 +2038,10 @@ uint8_t generate_dci_top(uint8_t num_ue_spec_dci,
int16_t
re_offset
;
uint8_t
mi
=
get_mi
(
frame_parms
,
subframe
);
static
uint8_t
e
[
DCI_BITS_MAX
];
static
mod_sym
_t
yseq0
[
Msymb
],
yseq1
[
Msymb
],
wbar0
[
Msymb
],
wbar1
[
Msymb
];
static
int32
_t
yseq0
[
Msymb
],
yseq1
[
Msymb
],
wbar0
[
Msymb
],
wbar1
[
Msymb
];
mod_sym
_t
*
y
[
2
];
mod_sym
_t
*
wbar
[
2
];
int32
_t
*
y
[
2
];
int32
_t
*
wbar
[
2
];
int
nushiftmod3
=
frame_parms
->
nushift
%
3
;
...
...
openair1/PHY/LTE_TRANSPORT/defs.h
View file @
15cd4ab0
...
...
@@ -269,8 +269,10 @@ typedef struct {
uint32_t
G
;
/// Codebook index for this dlsch (0,1,2,3)
uint8_t
codebook_index
;
/// Maximum number of HARQ
round
s (for definition see 36-212 V8.6 2009-03, p.17)
/// Maximum number of HARQ
processe
s (for definition see 36-212 V8.6 2009-03, p.17)
uint8_t
Mdlharq
;
/// Maximum number of HARQ rounds
uint8_t
Mlimit
;
/// MIMO transmission mode indicator for this sub-frame (for definition see 36-212 V8.6 2009-03, p.17)
uint8_t
Kmimo
;
/// Nsoft parameter related to UE Category
...
...
@@ -315,11 +317,9 @@ typedef struct {
/// Scrambled "b"-sequences (for definition see 36-211 V8.6 2009-03, p.14)
uint8_t
b_tilde
[
MAX_NUM_CHANNEL_BITS
];
/// Modulated "d"-sequences (for definition see 36-211 V8.6 2009-03, p.14)
mod_sym
_t
d
[
MAX_NUM_RE
];
int32
_t
d
[
MAX_NUM_RE
];
/// Transform-coded "z"-sequences (for definition see 36-211 V8.6 2009-03, p.14-15)
mod_sym_t
z
[
MAX_NUM_RE
];
/// Maximum number of HARQ rounds (for definition see 36-212 V8.6 2009-03, p.17)
uint8_t
Mdlharq
;
int32_t
z
[
MAX_NUM_RE
];
/// "q" sequences for CQI/PMI (for definition see 36-212 V8.6 2009-03, p.27)
uint8_t
q
[
MAX_CQI_PAYLOAD
];
/// coded and interleaved CQI bits
...
...
@@ -468,8 +468,8 @@ typedef struct {
typedef
struct
{
/// Pointers to 8 HARQ processes for the ULSCH
LTE_UL_eNB_HARQ_t
*
harq_processes
[
8
];
/// Maximum number of HARQ rounds
(for definition see 36-212 V8.6 2009-03, p.17)
uint8_t
M
dlharq
;
/// Maximum number of HARQ rounds
uint8_t
M
limit
;
/// Maximum number of iterations used in eNB turbo decoder
uint8_t
max_turbo_iterations
;
/// ACK/NAK Bundling flag
...
...
@@ -702,7 +702,7 @@ typedef struct {
harq_status_t
harq_ack
[
10
];
/// Pointers to up to 8 HARQ processes
LTE_DL_UE_HARQ_t
*
harq_processes
[
8
];
/// Maximum number of HARQ
rounds
(for definition see 36-212 V8.6 2009-03, p.17
/// Maximum number of HARQ
processes
(for definition see 36-212 V8.6 2009-03, p.17
uint8_t
Mdlharq
;
/// MIMO transmission mode indicator for this sub-frame (for definition see 36-212 V8.6 2009-03, p.17)
uint8_t
Kmimo
;
...
...
openair1/PHY/LTE_TRANSPORT/dlsch_coding.c
View file @
15cd4ab0
...
...
@@ -150,6 +150,7 @@ LTE_eNB_DLSCH_t *new_eNB_dlsch(unsigned char Kmimo,unsigned char Mdlharq,uint32_
bzero
(
dlsch
,
sizeof
(
LTE_eNB_DLSCH_t
));
dlsch
->
Kmimo
=
Kmimo
;
dlsch
->
Mdlharq
=
Mdlharq
;
dlsch
->
Mlimit
=
4
;
dlsch
->
Nsoft
=
Nsoft
;
for
(
i
=
0
;
i
<
10
;
i
++
)
...
...
openair1/PHY/LTE_TRANSPORT/dlsch_modulation.c
View file @
15cd4ab0
...
...
@@ -137,7 +137,7 @@ void layer1prec2A(int32_t *antenna0_sample, int32_t *antenna1_sample, uint8_t pr
}
int
allocate_REs_in_RB
(
LTE_DL_FRAME_PARMS
*
frame_parms
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
uint32_t
*
jj
,
uint32_t
*
jj2
,
uint16_t
re_offset
,
...
...
@@ -981,7 +981,7 @@ int allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
return
(
0
);
}
int
allocate_REs_in_RB_MCH
(
mod_sym
_t
**
txdataF
,
int
allocate_REs_in_RB_MCH
(
int32
_t
**
txdataF
,
uint32_t
*
jj
,
uint16_t
re_offset
,
uint32_t
symbol_offset
,
...
...
@@ -1178,7 +1178,7 @@ uint8_t get_pmi(uint8_t N_RB_DL,LTE_DL_eNB_HARQ_t *dlsch_harq,uint16_t rb)
}
int
dlsch_modulation
(
mod_sym
_t
**
txdataF
,
int
dlsch_modulation
(
int32
_t
**
txdataF
,
int16_t
amp
,
uint32_t
subframe_offset
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
...
...
@@ -1492,7 +1492,7 @@ int dlsch_modulation(mod_sym_t **txdataF,
return
(
re_allocated
);
}
int
mch_modulation
(
mod_sym
_t
**
txdataF
,
int
mch_modulation
(
int32
_t
**
txdataF
,
int16_t
amp
,
uint32_t
subframe_offset
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
...
...
openair1/PHY/LTE_TRANSPORT/drs_modulation.c
View file @
15cd4ab0
...
...
@@ -63,7 +63,7 @@ int generate_drs_pusch(PHY_VARS_UE *phy_vars_ue,
uint8_t
cyclic_shift
,
cyclic_shift0
,
cyclic_shift1
;
LTE_DL_FRAME_PARMS
*
frame_parms
=
&
phy_vars_ue
->
lte_frame_parms
;
mod_sym
_t
*
txdataF
=
phy_vars_ue
->
lte_ue_common_vars
.
txdataF
[
ant
];
int32
_t
*
txdataF
=
phy_vars_ue
->
lte_ue_common_vars
.
txdataF
[
ant
];
uint32_t
u
,
v
,
alpha_ind
;
uint32_t
u0
=
frame_parms
->
pusch_config_common
.
ul_ReferenceSignalsPUSCH
.
grouphop
[
subframe
<<
1
];
uint32_t
u1
=
frame_parms
->
pusch_config_common
.
ul_ReferenceSignalsPUSCH
.
grouphop
[
1
+
(
subframe
<<
1
)];
...
...
@@ -147,13 +147,13 @@ int generate_drs_pusch(PHY_VARS_UE *phy_vars_ue,
if
(
cyclic_shift
==
0
)
{
for
(
k
=
0
;
k
<
12
;
k
++
)
{
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
>=
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
>=
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
1
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
1
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
>=
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
<
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
2
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
2
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
<
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
>=
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
3
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
3
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
<
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
<
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
4
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
4
;
re_offset
++
;
drs_offset
++
;
...
...
@@ -165,22 +165,22 @@ int generate_drs_pusch(PHY_VARS_UE *phy_vars_ue,
for
(
k
=
0
;
k
<
12
;
k
++
)
{
if
(
k
%
2
==
0
)
{
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
>=
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
>=
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
4
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
4
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
>=
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
<
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
3
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
3
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
<
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
>=
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
2
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
2
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
<
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
<
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
1
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
1
;
}
else
{
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
>=
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
>=
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
1
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
1
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
>=
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
<
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
2
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
2
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
<
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
>=
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
3
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
3
;
else
if
((
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][
drs_offset
<<
1
]
<
0
)
&&
(
ul_ref_sigs
[
u
][
v
][
Msc_RS_idx
][(
drs_offset
<<
1
)
+
1
]
<
0
))
txdataF
[
symbol_offset
+
re_offset
]
=
(
mod_sym
_t
)
4
;
txdataF
[
symbol_offset
+
re_offset
]
=
(
int32
_t
)
4
;
}
re_offset
++
;
...
...
openair1/PHY/LTE_TRANSPORT/pbch.c
View file @
15cd4ab0
...
...
@@ -61,7 +61,7 @@
#define PBCH_A 24
int
allocate_pbch_REs_in_RB
(
LTE_DL_FRAME_PARMS
*
frame_parms
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
uint32_t
*
jj
,
uint16_t
re_offset
,
uint32_t
symbol_offset
,
...
...
@@ -160,7 +160,7 @@ int allocate_pbch_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
//uint8_t pbch_d[96+(3*(16+PBCH_A))], pbch_w[3*3*(16+PBCH_A)],pbch_e[1920]; //one bit per byte
int
generate_pbch
(
LTE_eNB_PBCH
*
eNB_pbch
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
int
amp
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
uint8_t
*
pbch_pdu
,
...
...
openair1/PHY/LTE_TRANSPORT/pcfich.c
View file @
15cd4ab0
...
...
@@ -143,12 +143,12 @@ uint8_t pcfich_b[4][32]= {{0,1,1,0,1,1,0,1,1,0,1,1,0,1,1,0,1,1,0,1,1,0,1,1,0,1,1
void
generate_pcfich
(
uint8_t
num_pdcch_symbols
,
int16_t
amp
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
uint8_t
subframe
)
{
uint8_t
pcfich_bt
[
32
],
nsymb
,
pcfich_quad
;
mod_sym
_t
pcfich_d
[
2
][
16
];
int32
_t
pcfich_d
[
2
][
16
];
uint8_t
i
;
uint32_t
symbol_offset
,
m
,
re_offset
,
reg_offset
;
int16_t
gain_lin_QPSK
;
...
...
openair1/PHY/LTE_TRANSPORT/phich.c
View file @
15cd4ab0
...
...
@@ -393,8 +393,8 @@ void generate_phich_emul(LTE_DL_FRAME_PARMS *frame_parms,
}
mod_sym
_t
alam_bpsk_perm1
[
4
]
=
{
2
,
1
,
4
,
3
};
// -conj(x) 1 (-1-j) -> 2 (1-j), 2->1, 3 (-1+j) -> (4) 1+j, 4->3
mod_sym
_t
alam_bpsk_perm2
[
4
]
=
{
3
,
4
,
2
,
1
};
// conj(x) 1 (-1-j) -> 3 (-1+j), 3->1, 2 (1-j) -> 4 (1+j), 4->2
int32
_t
alam_bpsk_perm1
[
4
]
=
{
2
,
1
,
4
,
3
};
// -conj(x) 1 (-1-j) -> 2 (1-j), 2->1, 3 (-1+j) -> (4) 1+j, 4->3
int32
_t
alam_bpsk_perm2
[
4
]
=
{
3
,
4
,
2
,
1
};
// conj(x) 1 (-1-j) -> 3 (-1+j), 3->1, 2 (1-j) -> 4 (1+j), 4->2
// This routine generates the PHICH
...
...
@@ -404,7 +404,7 @@ void generate_phich(LTE_DL_FRAME_PARMS *frame_parms,
uint8_t
ngroup_PHICH
,
uint8_t
HI
,
uint8_t
subframe
,
mod_sym
_t
**
y
)
int32
_t
**
y
)
{
int16_t
d
[
24
],
*
dp
;
...
...
@@ -1425,7 +1425,7 @@ void generate_phich_top(PHY_VARS_eNB *phy_vars_eNB,
LTE_DL_FRAME_PARMS
*
frame_parms
=&
phy_vars_eNB
->
lte_frame_parms
;
LTE_eNB_ULSCH_t
**
ulsch_eNB
=
phy_vars_eNB
->
ulsch_eNB
;
mod_sym
_t
**
txdataF
=
phy_vars_eNB
->
lte_eNB_common_vars
.
txdataF
[
sect_id
];
int32
_t
**
txdataF
=
phy_vars_eNB
->
lte_eNB_common_vars
.
txdataF
[
sect_id
];
uint8_t
harq_pid
;
uint8_t
Ngroup_PHICH
,
ngroup_PHICH
,
nseq_PHICH
;
uint8_t
NSF_PHICH
=
4
;
...
...
openair1/PHY/LTE_TRANSPORT/pilots.c
View file @
15cd4ab0
...
...
@@ -41,7 +41,7 @@
#include "PHY/defs.h"
void
generate_pilots
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
int16_t
amp
,
uint16_t
Ntti
)
{
...
...
@@ -168,7 +168,7 @@ void generate_pilots(PHY_VARS_eNB *phy_vars_eNB,
}
int
generate_pilots_slot
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
int16_t
amp
,
uint16_t
slot
,
int
first_pilot_only
)
...
...
openair1/PHY/LTE_TRANSPORT/pilots_mbsfn.c
View file @
15cd4ab0
...
...
@@ -42,7 +42,7 @@
int
generate_mbsfn_pilot
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
int16_t
amp
,
uint16_t
subframe
)
{
...
...
openair1/PHY/LTE_TRANSPORT/proto.h
View file @
15cd4ab0
...
...
@@ -89,9 +89,9 @@ void clean_eNb_ulsch(LTE_eNB_ULSCH_t *ulsch);
void
free_ue_ulsch
(
LTE_UE_ULSCH_t
*
ulsch
);
LTE_eNB_ULSCH_t
*
new_eNB_ulsch
(
uint8_t
Mdlharq
,
uint8_t
max_turbo_iterations
,
uint8_t
N_RB_UL
,
uint8_t
abstraction_flag
);
LTE_eNB_ULSCH_t
*
new_eNB_ulsch
(
uint8_t
max_turbo_iterations
,
uint8_t
N_RB_UL
,
uint8_t
abstraction_flag
);
LTE_UE_ULSCH_t
*
new_ue_ulsch
(
u
int8_t
Mdlharq
,
u
nsigned
char
N_RB_UL
,
uint8_t
abstraction_flag
);
LTE_UE_ULSCH_t
*
new_ue_ulsch
(
unsigned
char
N_RB_UL
,
uint8_t
abstraction_flag
);
/** \fn dlsch_encoding(uint8_t *input_buffer,
LTE_DL_FRAME_PARMS *frame_parms,
...
...
@@ -133,7 +133,7 @@ void dlsch_encoding_emul(PHY_VARS_eNB *phy_vars_eNB,
// Functions below implement 36-211
/** \fn allocate_REs_in_RB(
mod_sym
_t **txdataF,
/** \fn allocate_REs_in_RB(
int32
_t **txdataF,
uint32_t *jj,
uint32_t *jj2,
uint16_t re_offset,
...
...
@@ -169,7 +169,7 @@ void dlsch_encoding_emul(PHY_VARS_eNB *phy_vars_eNB,
*/
int32_t
allocate_REs_in_RB
(
LTE_DL_FRAME_PARMS
*
frame_parms
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
uint32_t
*
jj
,
uint32_t
*
jj2
,
uint16_t
re_offset
,
...
...
@@ -186,7 +186,7 @@ int32_t allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
uint8_t
skip_half
);
/** \fn int32_t dlsch_modulation(
mod_sym
_t **txdataF,
/** \fn int32_t dlsch_modulation(
int32
_t **txdataF,
int16_t amp,
uint32_t sub_frame_offset,
LTE_DL_FRAME_PARMS *frame_parms,
...
...
@@ -203,7 +203,7 @@ int32_t allocate_REs_in_RB(LTE_DL_FRAME_PARMS *frame_parms,
@param dlsch1 Pointer to Transport Block 0 DLSCH descriptor for this allocation
*/
int32_t
dlsch_modulation
(
mod_sym
_t
**
txdataF
,
int32_t
dlsch_modulation
(
int32
_t
**
txdataF
,
int16_t
amp
,
uint32_t
sub_frame_offset
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
...
...
@@ -218,7 +218,7 @@ int32_t dlsch_modulation(mod_sym_t **txdataF,
@param frame_parms Pointer to frame descriptor
@param dlsch Pointer to DLSCH descriptor for this allocation
*/
int
mch_modulation
(
mod_sym
_t
**
txdataF
,
int
mch_modulation
(
int32
_t
**
txdataF
,
int16_t
amp
,
uint32_t
subframe_offset
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
...
...
@@ -279,7 +279,7 @@ void dump_mch(PHY_VARS_UE *phy_vars_ue,uint8_t eNB_id,uint16_t coded_bits_per_co
@param N Number of sub-frames to generate
*/
void
generate_pilots
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
int16_t
amp
,
uint16_t
N
);
...
...
@@ -292,17 +292,17 @@ void generate_pilots(PHY_VARS_eNB *phy_vars_eNB,
@param first_pilot_only (0 no)
*/
int32_t
generate_pilots_slot
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
int16_t
amp
,
uint16_t
slot
,
int
first_pilot_only
);
int32_t
generate_mbsfn_pilot
(
PHY_VARS_eNB
*
phy_vars_eNB
,
mod_sym
_t
**
txdataF
,
int32
_t
**
txdataF
,
int16_t
amp
,
uint16_t
subframe
);
int32_t
generate_pss
(
mod_sym
_t
**
txdataF
,