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
wangwenhui
OpenXG-RAN
Commits
9fca3313
Commit
9fca3313
authored
Mar 21, 2016
by
Xiwen JIANG
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
move symbol level ifft including beamforming into ofdm_mod.c
parent
e196f5fc
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
55 additions
and
54 deletions
+55
-54
openair1/PHY/MODULATION/ofdm_mod.c
openair1/PHY/MODULATION/ofdm_mod.c
+55
-0
openair1/SIMULATION/LTE_PHY/dlsim.c
openair1/SIMULATION/LTE_PHY/dlsim.c
+0
-54
No files found.
openair1/PHY/MODULATION/ofdm_mod.c
View file @
9fca3313
...
@@ -276,4 +276,59 @@ void do_OFDM_mod(mod_sym_t **txdataF, int32_t **txdata, uint32_t frame,uint16_t
...
@@ -276,4 +276,59 @@ void do_OFDM_mod(mod_sym_t **txdataF, int32_t **txdata, uint32_t frame,uint16_t
}
}
// OFDM modulation for each symbol
void
do_OFDM_mod_l
(
LTE_eNB_COMMON
*
eNB_common_vars
,
int
eNB_id
,
uint16_t
next_slot
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
uint8_t
num_pdcch_symbols
,
unsigned
char
transmission_mode
)
{
int
aa
,
l
,
slot_offset
,
slot_offset_F
;
mod_sym_t
**
txdataF
=
eNB_common_vars
->
txdataF
[
eNB_id
];
mod_sym_t
**
txdataF_BF
=
eNB_common_vars
->
txdataF_BF
[
eNB_id
];
int32_t
**
txdata
=
eNB_common_vars
->
txdata
[
eNB_id
];
//slot_offset_F = (next_slot)*(frame_parms->ofdm_symbol_size)*((frame_parms->Ncp==1) ? 6 : 7);
slot_offset
=
(
next_slot
)
*
(
frame_parms
->
samples_per_tti
>>
1
);
// printf("Thread %d starting ... aa %d (%llu)\n",omp_get_thread_num(),aa,rdtsc());
for
(
l
=
0
;
l
<
frame_parms
->
symbols_per_tti
>>
1
;
l
++
)
{
//printf("do_OFDM_mod_l, slot=%d, l=%d, NUMBER_OF_OFDM_CARRIERS=%d,OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES=%d\n",next_slot, l,NUMBER_OF_OFDM_CARRIERS,OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES);
if
(
l
<
num_pdcch_symbols
&&
next_slot
&
1
==
0
)
cell_spec_beamforming
(
txdataF
,
txdataF_BF
,
frame_parms
,
eNB_common_vars
->
cell_spec_bf_weights
[
eNB_id
],
next_slot
,
l
);
else
if
(
transmission_mode
<
7
)
cell_spec_beamforming
(
txdataF
,
txdataF_BF
,
frame_parms
,
eNB_common_vars
->
cell_spec_bf_weights
[
eNB_id
],
next_slot
,
l
);
else
ue_spec_beamforming
(
txdataF
,
txdataF_BF
,
frame_parms
,
eNB_common_vars
->
ue_spec_bf_weights
[
eNB_id
],
next_slot
,
l
);
for
(
aa
=
0
;
aa
<
frame_parms
->
nb_antennas_tx
;
aa
++
)
{
if
(
frame_parms
->
Ncp
==
1
)
PHY_ofdm_mod
(
txdataF_BF
[
aa
],
// input
&
txdata
[
aa
][
slot_offset
+
l
*
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES
],
// output
frame_parms
->
ofdm_symbol_size
,
1
,
// number of symbols
frame_parms
->
nb_prefix_samples
,
// number of prefix samples
CYCLIC_PREFIX
);
else
{
if
(
l
==
0
)
{
PHY_ofdm_mod
(
txdataF_BF
[
aa
],
// input
&
txdata
[
aa
][
slot_offset
],
// output
frame_parms
->
ofdm_symbol_size
,
1
,
// number of symbols
frame_parms
->
nb_prefix_samples0
,
// number of prefix samples
CYCLIC_PREFIX
);
}
else
{
PHY_ofdm_mod
(
txdataF_BF
[
aa
],
// input
&
txdata
[
aa
][
slot_offset
+
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES0
+
(
l
-
1
)
*
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES
],
// output
frame_parms
->
ofdm_symbol_size
,
1
,
// number of symbols
frame_parms
->
nb_prefix_samples
,
// number of prefix samples
CYCLIC_PREFIX
);
}
}
}
}
}
/** @} */
/** @} */
openair1/SIMULATION/LTE_PHY/dlsim.c
View file @
9fca3313
...
@@ -118,60 +118,6 @@ uint64_t DLSCH_alloc_pdu_1[2];
...
@@ -118,60 +118,6 @@ uint64_t DLSCH_alloc_pdu_1[2];
#define CCCH_RB_ALLOC computeRIV(PHY_vars_eNB->lte_frame_parms.N_RB_UL,0,2)
#define CCCH_RB_ALLOC computeRIV(PHY_vars_eNB->lte_frame_parms.N_RB_UL,0,2)
//#define DLSCH_RB_ALLOC 0x1fbf // igore DC component,RB13
//#define DLSCH_RB_ALLOC 0x1fbf // igore DC component,RB13
//#define DLSCH_RB_ALLOC 0x0001
//#define DLSCH_RB_ALLOC 0x0001
void
do_OFDM_mod_l
(
LTE_eNB_COMMON
*
eNB_common_vars
,
int
eNB_id
,
uint16_t
next_slot
,
LTE_DL_FRAME_PARMS
*
frame_parms
,
uint8_t
num_pdcch_symbols
,
unsigned
char
transmission_mode
)
{
int
aa
,
l
,
slot_offset
,
slot_offset_F
;
mod_sym_t
**
txdataF
=
eNB_common_vars
->
txdataF
[
eNB_id
];
mod_sym_t
**
txdataF_BF
=
eNB_common_vars
->
txdataF_BF
[
eNB_id
];
int32_t
**
txdata
=
eNB_common_vars
->
txdata
[
eNB_id
];
//slot_offset_F = (next_slot)*(frame_parms->ofdm_symbol_size)*((frame_parms->Ncp==1) ? 6 : 7);
slot_offset
=
(
next_slot
)
*
(
frame_parms
->
samples_per_tti
>>
1
);
// printf("Thread %d starting ... aa %d (%llu)\n",omp_get_thread_num(),aa,rdtsc());
for
(
l
=
0
;
l
<
frame_parms
->
symbols_per_tti
>>
1
;
l
++
)
{
//printf("do_OFDM_mod_l, slot=%d, l=%d, NUMBER_OF_OFDM_CARRIERS=%d,OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES=%d\n",next_slot, l,NUMBER_OF_OFDM_CARRIERS,OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES);
if
(
l
<
num_pdcch_symbols
&&
next_slot
&
1
==
0
)
cell_spec_beamforming
(
txdataF
,
txdataF_BF
,
frame_parms
,
eNB_common_vars
->
cell_spec_bf_weights
[
eNB_id
],
next_slot
,
l
);
else
if
(
transmission_mode
<
7
)
cell_spec_beamforming
(
txdataF
,
txdataF_BF
,
frame_parms
,
eNB_common_vars
->
cell_spec_bf_weights
[
eNB_id
],
next_slot
,
l
);
else
ue_spec_beamforming
(
txdataF
,
txdataF_BF
,
frame_parms
,
eNB_common_vars
->
ue_spec_bf_weights
[
eNB_id
],
next_slot
,
l
);
for
(
aa
=
0
;
aa
<
frame_parms
->
nb_antennas_tx
;
aa
++
)
{
if
(
frame_parms
->
Ncp
==
1
)
PHY_ofdm_mod
(
txdataF_BF
[
aa
],
// input
&
txdata
[
aa
][
slot_offset
+
l
*
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES
],
// output
frame_parms
->
ofdm_symbol_size
,
1
,
// number of symbols
frame_parms
->
nb_prefix_samples
,
// number of prefix samples
CYCLIC_PREFIX
);
else
{
if
(
l
==
0
)
{
PHY_ofdm_mod
(
txdataF_BF
[
aa
],
// input
&
txdata
[
aa
][
slot_offset
],
// output
frame_parms
->
ofdm_symbol_size
,
1
,
// number of symbols
frame_parms
->
nb_prefix_samples0
,
// number of prefix samples
CYCLIC_PREFIX
);
}
else
{
PHY_ofdm_mod
(
txdataF_BF
[
aa
],
// input
&
txdata
[
aa
][
slot_offset
+
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES0
+
(
l
-
1
)
*
OFDM_SYMBOL_SIZE_COMPLEX_SAMPLES
],
// output
frame_parms
->
ofdm_symbol_size
,
1
,
// number of symbols
frame_parms
->
nb_prefix_samples
,
// number of prefix samples
CYCLIC_PREFIX
);
}
}
}
}
}
int
main
(
int
argc
,
char
**
argv
)
int
main
(
int
argc
,
char
**
argv
)
{
{
...
...
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