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
zzha zzha
OpenXG-RAN
Commits
c5745c16
Commit
c5745c16
authored
Jun 16, 2016
by
Sandeep Kumar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
highlight send/recv if4 - midsave to swich pc
parent
c76951a3
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
78 additions
and
86 deletions
+78
-86
openair1/PHY/LTE_TRANSPORT/if4_tools.c
openair1/PHY/LTE_TRANSPORT/if4_tools.c
+16
-17
openair1/PHY/LTE_TRANSPORT/prach.c
openair1/PHY/LTE_TRANSPORT/prach.c
+3
-3
openair1/SCHED/phy_procedures_lte_eNb.c
openair1/SCHED/phy_procedures_lte_eNb.c
+6
-26
targets/RT/USER/lte-enb.c
targets/RT/USER/lte-enb.c
+51
-38
targets/RT/USER/lte-softmodem.c
targets/RT/USER/lte-softmodem.c
+2
-2
No files found.
openair1/PHY/LTE_TRANSPORT/if4_tools.c
View file @
c5745c16
...
...
@@ -38,16 +38,11 @@
* \warning
*/
#ifndef USER_MODE
#include "if4_tools.h"
#include <stdint.h>
#else
#include <stdint.h>
#include "PHY/defs.h"
#include "PHY/defs.h"
#include "PHY/LTE_TRANSPORT/if4_tools.h"
#include "PHY/TOOLS/ALAW/alaw_lut.h"
#endif
// Get device information
void
send_IF4
(
PHY_VARS_eNB
*
eNB
,
eNB_rxtx_proc_t
*
proc
)
{
...
...
@@ -71,6 +66,8 @@ void send_IF4(PHY_VARS_eNB *eNB, eNB_rxtx_proc_t *proc) {
for
(
symbol_id
=
0
;
symbol_id
<
fp
->
symbols_per_tti
;
symbol_id
++
)
{
printf
(
"
\n
Send IF4 for frame %d, subframe %d and symbol %d
\n
"
,
proc
->
frame_tx
,
proc
->
subframe_tx
,
symbol_id
);
// Do compression of the two parts and generate data blocks
for
(
element_id
=
0
;
element_id
<
db_halflength
;
element_id
++
)
{
data_block
[
element_id
]
=
lin2alaw
[
(
txdataF
[
0
][
blockoffsetF
+
element_id
]
&
0xffff
)
+
32768
];
...
...
@@ -84,11 +81,11 @@ void send_IF4(PHY_VARS_eNB *eNB, eNB_rxtx_proc_t *proc) {
dl_packet
->
frame_status
.
sym_num
=
symbol_id
;
// Write the packet(s) to the fronthaul
//if ((bytes_sent = dev->eth_dev.trx_write_func (&dev->eth_dev
,
// timestamp_rx
,
// rx_eNB
,
// spp_eth
,
// dev->eth_dev.openair0_cfg->rx_num_channels
,
// if ((bytes_sent = eNB->ifdevice.trx_write_func(&eNB->ifdevice
,
// (proc->timestamp_tx-eNB->ifdevice.openair0_cfg.tx_sample_advance)
,
// dl_packet
,
// eNB->frame_parms.samples_per_tti
,
// eNB->frame_parms.nb_antennas_tx
,
// 0)) < 0) {
// perror("RCC : ETHERNET write");
//}
...
...
@@ -104,10 +101,10 @@ void send_IF4(PHY_VARS_eNB *eNB, eNB_rxtx_proc_t *proc) {
for
(
symbol_id
=
0
;
symbol_id
<
fp
->
symbols_per_tti
;
symbol_id
++
)
{
// Do compression of the two parts and generate data blocks
// Do compression of the two parts and generate data blocks
- rxdataF
for
(
element_id
=
0
;
element_id
<
db_halflength
;
element_id
++
)
{
data_block
[
element_id
]
=
lin2alaw
[
(
t
xdataF
[
0
][
blockoffsetF
+
element_id
]
&
0xffff
)
+
32768
];
data_block
[
element_id
]
|=
lin2alaw
[
(
t
xdataF
[
0
][
blockoffsetF
+
element_id
]
>>
16
)
+
32768
]
<<
8
;
data_block
[
element_id
]
=
lin2alaw
[
(
r
xdataF
[
0
][
blockoffsetF
+
element_id
]
&
0xffff
)
+
32768
];
data_block
[
element_id
]
|=
lin2alaw
[
(
r
xdataF
[
0
][
blockoffsetF
+
element_id
]
>>
16
)
+
32768
]
<<
8
;
data_block
[
element_id
+
db_halflength
]
=
lin2alaw
[
(
txdataF
[
0
][
slotoffsetF
+
element_id
]
&
0xffff
)
+
32768
];
data_block
[
element_id
+
db_halflength
]
|=
lin2alaw
[
(
txdataF
[
0
][
slotoffsetF
+
element_id
]
>>
16
)
+
32768
]
<<
8
;
...
...
@@ -130,6 +127,8 @@ void recv_IF4(PHY_VARS_eNB *eNB, eNB_rxtx_proc_t *proc, uint16_t *packet_type, u
// Caller: RRU - DL *** handle RCC case - UL and PRACH ***
if
(
eNB
->
node_function
==
NGFI_RRU_IF4
)
{
printf
(
"
\n
Recv IF4 for frame %d, subframe %d and symbol %d
\n
"
,
proc
->
frame_tx
,
proc
->
subframe_tx
,
symbol_id
);
// for(i=0; i<fp->symbols_per_tti; i++) {
// Read packet(s) from the fronthaul
// if (dev->eth_dev.trx_read_func (&dev->eth_dev,
...
...
openair1/PHY/LTE_TRANSPORT/prach.c
View file @
c5745c16
...
...
@@ -1269,16 +1269,16 @@ void rx_prach(PHY_VARS_eNB *eNB,
}
if
(
eNB
->
node_function
==
NGFI_RRU_IF4
)
{
//
send prachF to RCC
//
/ **** send_IF4 of prachF to RCC **** ///
return
;
}
// in case of RCC and prach received rx_thread wakes up prach
//else if (eNB->node_function == NGFI_RCC_IF4) {
//
wait for prachF from RRU and continue with PRACH processing
//
wait for prachF from RRU and continue with PRACH processing
//}
// here onwards is for eNodeB_3GPP or NGFI_RCC_IF4
preamble_offset_old
=
99
;
...
...
openair1/SCHED/phy_procedures_lte_eNb.c
View file @
c5745c16
...
...
@@ -1430,24 +1430,6 @@ void phy_procedures_eNB_TX(PHY_VARS_eNB *eNB,
#endif
// Clean up split point *** RRU only function to recv and do_OFDM_mod ***
if
(
eNB
->
node_function
==
eNodeB_3GPP
)
{
// Add above to IF4 split
// do_OFDM_mod
}
else
if
(
eNB
->
node_function
==
NGFI_RCC_IF4
)
{
//send_IF4(eNB,subframe<<1);
//send_IF4(eNB,(subframe<<1)+1);
}
else
if
(
eNB
->
node_function
==
NGFI_RRU_IF4
)
{
// => acquisition from RCC (IF4)
// get frame/subframe information from IF4 interface
//recv_IF4(eNB,subframe<<1);
//recv_IF4(eNB,1+(subframe<<1));
//do_OFDM_mod
}
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_PHY_PROCEDURES_ENB_TX
,
0
);
stop_meas
(
&
eNB
->
phy_proc_tx
);
...
...
@@ -2572,12 +2554,14 @@ void phy_procedures_eNB_common_RX(PHY_VARS_eNB *eNB,const uint8_t abstraction_fl
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_ENB_SLOT_FEP
,
0
);
if
(
eNB
->
node_function
==
NGFI_RRU_IF4
)
{
//send_IF4(eNB,subframe<<1);
//send_IF4(eNB,(subframe<<1)+1);
/// **** send_IF4 of rxdataF to RCC **** ///
/// Handle routing to prach thread for sending prach
}
}
else
if
(
eNB
->
node_function
==
NGFI_RCC_IF4
)
{
// => acquisition from RRU (IF4)
else
if
(
eNB
->
node_function
==
NGFI_RCC_IF4
)
{
/// **** recv_IF4 of rxdataF from RRU **** ///
/// **** recv_IF4 of prachF from RRU **** ///
// get frame/subframe information from IF4 interface
// timed loop (200 us)
...
...
@@ -2599,10 +2583,6 @@ void phy_procedures_eNB_common_RX(PHY_VARS_eNB *eNB,const uint8_t abstraction_fl
//} while( (symbol_mask != symbol_mask_full) || (prach_rx == 0));
//recv_IF4(eNB,subframe<<1);
//recv_IF4(eNB,1+(subframe<<1));
// Tobi aka mr monaco: ETH
...
...
targets/RT/USER/lte-enb.c
View file @
c5745c16
...
...
@@ -68,6 +68,8 @@
//#undef FRAME_LENGTH_COMPLEX_SAMPLES //there are two conflicting definitions, so we better make sure we don't use it at all
#include "PHY/LTE_TRANSPORT/if4_tools.h"
#include "PHY/extern.h"
#include "SCHED/extern.h"
#include "LAYER2/MAC/extern.h"
...
...
@@ -494,9 +496,15 @@ static void* eNB_thread_rxtx( void* param )
exit_fun
(
"nothing to add"
);
break
;
}
}
else
{
/// **** recv_IF4 of txdataF from RCC **** ///
//recv_IF4( eNB, proc, packet_type, symbol_number);
}
}
// eNodeB_3GPP and RRU create txdata and write to RF device
if
(
PHY_vars_eNB_g
[
0
][
proc
->
CC_id
]
->
node_function
!=
NGFI_RCC_IF4
)
{
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME
(
VCD_SIGNAL_DUMPER_FUNCTIONS_PHY_ENB_SFGEN
,
1
);
do_OFDM_mod_rt
(
proc
->
subframe_tx
,
PHY_vars_eNB_g
[
0
][
proc
->
CC_id
]
);
...
...
@@ -537,6 +545,11 @@ static void* eNB_thread_rxtx( void* param )
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME
(
VCD_SIGNAL_DUMPER_VARIABLES_TRX_TST
,
(
proc
->
timestamp_tx
-
openair0_cfg
[
0
].
tx_sample_advance
)
&
0xffffffff
);
}
else
{
// RCC sends the txdataF using send_IF4 function
/// **** send_IF4 of txdataF to RRU **** ///
//send_IF4(PHY_vars_eNB_g[0][proc->CC_id], proc);
}
if
(
pthread_mutex_lock
(
&
proc
->
mutex_rxtx
)
!=
0
)
{
...
...
@@ -743,13 +756,13 @@ static void* eNB_thread_rx_common( void* param )
#endif
// Start RF device for this CC
if
(
eNB
->
node_function
==
eNodeB_3GPP
||
eNB
->
node_function
==
NGFI_RRU
_IF4
)
{
if
(
eNB
->
node_function
!=
NGFI_RCC
_IF4
)
{
if
(
eNB
->
rfdevice
.
trx_start_func
(
&
eNB
->
rfdevice
)
!=
0
)
LOG_E
(
HW
,
"Could not start the RF device
\n
"
);
}
// Start IF device for this CC
if
(
eNB
->
node_function
==
NGFI_RCC_IF4
||
eNB
->
node_function
==
NGFI_RRU_IF4
)
{
if
(
eNB
->
node_function
!=
eNodeB_3GPP
)
{
if
(
eNB
->
ifdevice
.
trx_start_func
(
&
eNB
->
ifdevice
)
!=
0
)
LOG_E
(
HW
,
"Could not start the IF device
\n
"
);
}
...
...
targets/RT/USER/lte-softmodem.c
View file @
c5745c16
...
...
@@ -1635,7 +1635,7 @@ int main( int argc, char **argv )
// Handle spatially distributed MIMO antenna ports
// Load RF device and initialize
if
(
node_function
==
eNodeB_3GPP
||
node_function
==
NGFI_RRU
_IF4
)
{
if
(
node_function
!=
NGFI_RCC
_IF4
)
{
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
if
(
mode
!=
loop_through_memory
)
{
returns
=
openair0_device_load
(
&
(
PHY_vars_eNB_g
[
0
][
CC_id
]
->
rfdevice
),
&
openair0_cfg
[
0
]);
...
...
@@ -1651,7 +1651,7 @@ int main( int argc, char **argv )
}
// Load transport protocol and initialize
if
(
node_function
==
NGFI_RCC_IF4
||
node_function
==
NGFI_RRU_IF4
){
if
(
node_function
!=
eNodeB_3GPP
){
for
(
CC_id
=
0
;
CC_id
<
MAX_NUM_CCs
;
CC_id
++
)
{
if
(
mode
!=
loop_through_memory
)
{
returns
=
openair0_transport_load
(
&
(
PHY_vars_eNB_g
[
0
][
CC_id
]
->
ifdevice
),
&
openair0_cfg
[
0
],
(
eth_params
+
CC_id
));
...
...
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