Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG UE
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
OpenXG
OpenXG UE
Commits
5a17c34c
Commit
5a17c34c
authored
Nov 18, 2020
by
Raymond Knopp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
testing with AW2S RRU.
parent
149fac52
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
39 additions
and
32 deletions
+39
-32
openair1/PHY/LTE_TRANSPORT/if5_tools.c
openair1/PHY/LTE_TRANSPORT/if5_tools.c
+4
-3
openair1/PHY/LTE_TRANSPORT/prach.c
openair1/PHY/LTE_TRANSPORT/prach.c
+26
-24
openair1/SCHED/prach_procedures.c
openair1/SCHED/prach_procedures.c
+1
-1
targets/ARCH/ETHERNET/USERSPACE/LIB/eth_udp.c
targets/ARCH/ETHERNET/USERSPACE/LIB/eth_udp.c
+6
-2
targets/RT/USER/lte-ru.c
targets/RT/USER/lte-ru.c
+2
-2
No files found.
openair1/PHY/LTE_TRANSPORT/if5_tools.c
View file @
5a17c34c
...
...
@@ -1106,7 +1106,7 @@ void send_IF5(RU_t *ru, openair0_timestamp proc_timestamp, int subframe, uint8_t
}
else
if
(
eth
->
compression
==
NO_COMPRESS
)
{
for
(
i
=
0
;
i
<
ru
->
nb_tx
;
i
++
)
txp
[
i
]
=
(
void
*
)
&
ru
->
common
.
txdata
[
i
][
subframe
*
fp
->
samples_per_tti
];
txp
[
i
]
=
(
int32_t
*
)
&
ru
->
common
.
txdata
[
i
][
subframe
*
fp
->
samples_per_tti
];
for
(
packet_id
=
0
;
packet_id
<
spsf
/
spp_eth
;
packet_id
++
)
{
for
(
int
aid
=
0
;
aid
<
ru
->
nb_tx
;
aid
++
)
{
...
...
@@ -1114,11 +1114,12 @@ void send_IF5(RU_t *ru, openair0_timestamp proc_timestamp, int subframe, uint8_t
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 1 );
clock_gettime
(
CLOCK_MONOTONIC
,
&
start_comp
);
ru
->
ifdevice
.
trx_write_func2
(
&
ru
->
ifdevice
,
(
proc_timestamp
+
packet_id
*
spp_eth
),
(
proc_timestamp
+
packet_id
*
spp_eth
-
500
)
*
(
30720
/
spsf
),
(
void
*
)
txp
[
aid
],
spp_eth
,
aid
,
0
);
LOG_D
(
HW
,
"SF %d : packet %d, TS %llu
\n
"
,
subframe
,
packet_id
,(
unsigned
long
long
)(
proc_timestamp
+
packet_id
*
spp_eth
));
clock_gettime
(
CLOCK_MONOTONIC
,
&
end_comp
);
LOG_D
(
HW
,
"[SF %d] IF_Write_Time: %"
PRId64
"
\n
"
,
subframe
,
clock_difftime_ns
(
start_comp
,
end_comp
));
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 0 );
...
...
@@ -1454,7 +1455,7 @@ void recv_IF5(RU_t *ru, openair0_timestamp *proc_timestamp, int subframe, uint16
&
aid
);
clock_gettime
(
CLOCK_MONOTONIC
,
&
if_time
);
timeout
[
packet_id
]
=
if_time
.
tv_nsec
;
timestamp
[
packet_id
]
/=
(
30720
/
spsf
);
LOG_D
(
PHY
,
"subframe %d: Received packet %d: aid %d, TS %llu, oldTS %llu, diff %lld,
\n
"
,
subframe
,
packet_id
,
aid
,(
unsigned
long
long
)
timestamp
[
packet_id
],(
unsigned
long
long
)
oldTS
,(
unsigned
long
long
)(
timestamp
[
packet_id
]
-
timestamp
[
0
]));
if
(
aid
==
0
)
{
if
(
firstTS
==
1
)
firstTS
=
0
;
...
...
openair1/PHY/LTE_TRANSPORT/prach.c
View file @
5a17c34c
...
...
@@ -89,7 +89,7 @@ void rx_prach0(PHY_VARS_eNB *eNB,
int32_t
*
prach_ifft
=
(
int32_t
*
)
NULL
;
int32_t
**
prach_ifftp
=
(
int32_t
**
)
NULL
;
int
prach_ifft_cnt
=
0
;
int
exit_flag
=
0
;
LTE_DL_FRAME_PARMS
*
fp
;
int
nb_rx
;
if
(
eNB
)
{
...
...
@@ -177,7 +177,7 @@ void rx_prach0(PHY_VARS_eNB *eNB,
}
AssertFatal
(
ru
!=
NULL
,
"ru is null
\n
"
);
int8_t
dBEn0
;
for
(
aa
=
0
;
aa
<
nb_rx
;
aa
++
)
{
if
(
ru
->
if_south
==
LOCAL_RF
||
ru
->
function
==
NGFI_RAU_IF5
)
{
// set the time-domain signal if we have to use it in this node
// DJP - indexing below in subframe zero takes us off the beginning of the array???
...
...
@@ -185,24 +185,25 @@ void rx_prach0(PHY_VARS_eNB *eNB,
if
(
LOG_DUMPFLAG
(
PRACH
))
{
int32_t
en0
=
signal_energy
((
int32_t
*
)
prach
[
aa
],
fp
->
samples_per_tti
);
int8_t
db
En0
=
dB_fixed
(
en0
);
int8_t
rach_dBm
=
d
b
En0
-
ru
->
rx_total_gain_dB
;
dB
En0
=
dB_fixed
(
en0
);
int8_t
rach_dBm
=
d
B
En0
-
ru
->
rx_total_gain_dB
;
char
buffer
[
80
];
if
(
d
bEn0
>
32
&&
prach
[
0
]
!=
NULL
)
{
if
(
d
BEn0
>
30
&&
prach
[
0
]
!=
NULL
)
{
static
int
counter
=
0
;
sprintf
(
buffer
,
"%s%d"
,
"/tmp/prach_rx"
,
counter
);
LOG_M
(
buffer
,
"prach_rx"
,
prach
[
0
],
fp
->
samples_per_tti
,
1
,
13
);
sprintf
(
buffer
,
"%s%d"
,
"/tmp/prach_rx.m"
,
counter
);
LOG_M
(
buffer
,
"prach_rx"
,
prach
[
0
],
fp
->
samples_per_tti
,
1
,
1
);
exit_flag
=
1
;
}
if
(
dB
_fixed
(
en0
)
>
32
)
{
if
(
dB
En0
>
30
)
{
sprintf
(
buffer
,
"rach_dBm:%d"
,
rach_dBm
);
if
(
prach
[
0
]
!=
NULL
)
LOG_M
(
"prach_rx"
,
"prach_rx"
,
prach
[
0
],
fp
->
samples_per_tti
,
1
,
1
);
if
(
prach
[
0
]
!=
NULL
)
LOG_M
(
"prach_rx
.m
"
,
"prach_rx"
,
prach
[
0
],
fp
->
samples_per_tti
,
1
,
1
);
LOG_I
(
PHY
,
"RU %d, br_flag %d ce_level %d frame %d subframe %d per_tti:%d prach:%p (energy %d) TA:%d %s rxdata:%p index:%d
\n
"
,
ru
->
idx
,
br_flag
,
ce_level
,
frame_prach
,
subframe
,
fp
->
samples_per_tti
,
prach
[
aa
],
d
b
En0
,
ru
->
N_TA_offset
,
buffer
,
ru
->
common
.
rxdata
[
aa
],
prach
[
aa
],
d
B
En0
,
ru
->
N_TA_offset
,
buffer
,
ru
->
common
.
rxdata
[
aa
],
(
subframe
*
fp
->
samples_per_tti
)
-
ru
->
N_TA_offset
);
}
}
...
...
@@ -415,7 +416,7 @@ void rx_prach0(PHY_VARS_eNB *eNB,
if
(
LOG_DEBUGFLAG
(
PRACH
))
{
int
en
=
dB_fixed
(
signal_energy
((
int32_t
*
)
&
rxsigF
[
0
][
0
],
840
));
if
((
en
>
6
0
)
&&
(
br_flag
==
1
))
LOG_I
(
PHY
,
"PRACH (br_flag %d,ce_level %d, n_ra_prb %d, k %d): Frame %d, Subframe %d => %d dB
\n
"
,
br_flag
,
ce_level
,
n_ra_prb
,
k
,
frame_prach
,
subframe
,
en
);
if
((
en
>
1
0
)
&&
(
br_flag
==
1
))
LOG_I
(
PHY
,
"PRACH (br_flag %d,ce_level %d, n_ra_prb %d, k %d): Frame %d, Subframe %d => %d dB
\n
"
,
br_flag
,
ce_level
,
n_ra_prb
,
k
,
frame_prach
,
subframe
,
en
);
}
}
...
...
@@ -454,9 +455,9 @@ void rx_prach0(PHY_VARS_eNB *eNB,
for
(
preamble_index
=
0
;
preamble_index
<
64
;
preamble_index
++
)
{
if
(
LOG_DEBUGFLAG
(
PRACH
))
{
int
en
=
dB_fixed
(
signal_energy
((
int32_t
*
)
&
rxsigF
[
0
][
0
],
840
));
//
int en = dB_fixed(signal_energy((int32_t *)&rxsigF[0][0],840));
if
(
en
>
6
0
)
LOG_I
(
PHY
,
"frame %d, subframe %d : Trying preamble %d (br_flag %d)
\n
"
,
frame_prach
,
subframe
,
preamble_index
,
br_flag
);
if
(
dBEn0
>
3
0
)
LOG_I
(
PHY
,
"frame %d, subframe %d : Trying preamble %d (br_flag %d)
\n
"
,
frame_prach
,
subframe
,
preamble_index
,
br_flag
);
}
if
(
restricted_set
==
0
)
{
...
...
@@ -539,10 +540,10 @@ void rx_prach0(PHY_VARS_eNB *eNB,
// Compute DFT of RX signal (conjugate input, results in conjugate output) for each new rootSequenceIndex
if
(
LOG_DEBUGFLAG
(
PRACH
))
{
int
en
=
dB_fixed
(
signal_energy
((
int32_t
*
)
&
rxsigF
[
0
][
0
],
840
));
//
en = dB_fixed(signal_energy((int32_t *)&rxsigF[0][0],840));
if
(
en
>
6
0
)
LOG_I
(
PHY
,
"frame %d, subframe %d : preamble index %d: offset %d, preamble shift %d (br_flag %d, en %d)
\n
"
,
frame_prach
,
subframe
,
preamble_index
,
preamble_offset
,
preamble_shift
,
br_flag
,
en
);
if
(
dBEn0
>
3
0
)
LOG_I
(
PHY
,
"frame %d, subframe %d : preamble index %d: offset %d, preamble shift %d (br_flag %d, en %d)
\n
"
,
frame_prach
,
subframe
,
preamble_index
,
preamble_offset
,
preamble_shift
,
br_flag
,
dBEn0
);
}
log2_ifft_size
=
10
;
...
...
@@ -564,13 +565,13 @@ void rx_prach0(PHY_VARS_eNB *eNB,
memset
(
prachF
,
0
,
sizeof
(
int16_t
)
*
2
*
1024
);
if
(
LOG_DUMPFLAG
(
PRACH
))
{
if
(
LOG_DUMPFLAG
(
PRACH
))
{
if
(
prach
[
0
]
!=
NULL
)
LOG_M
(
"prach_rx0.m"
,
"prach_rx0"
,
prach
[
0
],
6144
+
792
,
1
,
1
);
LOG_M
(
"prach_rx1.m"
,
"prach_rx1"
,
prach
[
1
],
6144
+
792
,
1
,
1
);
LOG_M
(
"prach_rxF0.m"
,
"prach_rxF0"
,
rxsigF
[
0
],
12288
,
1
,
1
);
LOG_M
(
"prach_rxF1.m"
,
"prach_rxF1"
,
rxsigF
[
1
],
12288
,
1
,
1
);
}
}
for
(
aa
=
0
;
aa
<
nb_rx
;
aa
++
)
{
// Do componentwise product with Xu* on each antenna
...
...
@@ -633,9 +634,9 @@ void rx_prach0(PHY_VARS_eNB *eNB,
*
max_preamble
=
preamble_index
;
if
(
LOG_DEBUGFLAG
(
PRACH
))
{
int
en
=
dB_fixed
(
signal_energy
((
int32_t
*
)
&
rxsigF
[
0
][
0
],
840
));
//
int en = dB_fixed(signal_energy((int32_t *)&rxsigF[0][0],840));
if
(
(
en
>
60
)
&&
(
br_flag
==
1
)
)
if
(
dBEn0
>
30
)
LOG_D
(
PHY
,
"frame %d, subframe %d : max_preamble_energy %d, max_preamble_delay %d, max_preamble %d (br_flag %d,ce_level %d, levdB %d, lev %d)
\n
"
,
frame_prach
,
subframe
,
*
max_preamble_energy
,
*
max_preamble_delay
,
...
...
@@ -648,10 +649,10 @@ void rx_prach0(PHY_VARS_eNB *eNB,
*
avg_preamble_energy
=
dB_fixed
(
avg_en
/
64
);
if
(
LOG_DUMPFLAG
(
PRACH
)
)
{
if
(
exit_flag
==
1
)
{
int
en
=
dB_fixed
(
signal_energy
((
int32_t
*
)
&
rxsigF
[
0
][
0
],
840
));
if
(
en
>
6
0
)
{
if
(
en
>
3
0
)
{
k
=
(
12
*
n_ra_prb
)
-
6
*
fp
->
N_RB_UL
;
if
(
k
<
0
)
k
+=
fp
->
ofdm_symbol_size
;
...
...
@@ -665,19 +666,20 @@ void rx_prach0(PHY_VARS_eNB *eNB,
LOG_M
(
"prach_rxF_comp0.m"
,
"prach_rxF_comp0"
,
prachF
,
1024
,
1
,
1
);
LOG_M
(
"Xu.m"
,
"xu"
,
Xu
,
N_ZC
,
1
,
1
);
LOG_M
(
"prach_ifft0.m"
,
"prach_t0"
,
prach_ifft
,
1024
,
1
,
1
);
exit
(
-
1
);
LOG_M
(
"SF2_3.m"
,
"sf2_3"
,
&
ru
->
common
.
rxdata
[
0
][
2
*
fp
->
samples_per_tti
],
2
*
fp
->
samples_per_tti
,
1
,
1
);
}
else
{
LOG_E
(
PHY
,
"Dumping prach (br_flag %d), k = %d (n_ra_prb %d)
\n
"
,
br_flag
,
k
,
n_ra_prb
);
LOG_M
(
"rxsigF_br.m"
,
"prach_rxF_br"
,
&
rxsigF
[
0
][
0
],
12288
,
1
,
1
);
LOG_M
(
"prach_rxF_comp0_br.m"
,
"prach_rxF_comp0_br"
,
prachF
,
1024
,
1
,
1
);
LOG_M
(
"Xu_br.m"
,
"xu_br"
,
Xu
,
N_ZC
,
1
,
1
);
LOG_M
(
"prach_ifft0_br.m"
,
"prach_t0_br"
,
prach_ifft
,
1024
,
1
,
1
);
exit
(
-
1
);
}
}
}
/* LOG_DUMPFLAG(PRACH) */
if
(
eNB
)
stop_meas
(
&
eNB
->
rx_prach
);
AssertFatal
(
exit_flag
==
0
,
"exiting
\n
"
);
}
...
...
openair1/SCHED/prach_procedures.c
View file @
5a17c34c
...
...
@@ -148,7 +148,7 @@ void prach_procedures(PHY_VARS_eNB *eNB,
}
else
{
if
((
eNB
->
prach_energy_counter
==
100
)
&&
(
max_preamble_energy
[
0
]
>
eNB
->
measurements
.
prach_I0
+
eNB
->
prach_DTX_threshold
))
{
LOG_
D
(
PHY
,
"[eNB %d/%d][RAPROC] Frame %d, subframe %d Initiating RA procedure with preamble %d, energy %d.%d dB, delay %d
\n
"
,
LOG_
I
(
PHY
,
"[eNB %d/%d][RAPROC] Frame %d, subframe %d Initiating RA procedure with preamble %d, energy %d.%d dB, delay %d
\n
"
,
eNB
->
Mod_id
,
eNB
->
CC_id
,
frame
,
...
...
targets/ARCH/ETHERNET/USERSPACE/LIB/eth_udp.c
View file @
5a17c34c
...
...
@@ -394,6 +394,7 @@ int trx_eth_write_udp(openair0_device *device, openair0_timestamp timestamp, voi
}
#define NOSHIFT 1
int
trx_eth_read_udp
(
openair0_device
*
device
,
openair0_timestamp
*
timestamp
,
void
*
buff
,
int
nsamps
,
int
*
cc
)
{
...
...
@@ -473,7 +474,10 @@ int trx_eth_read_udp(openair0_device *device, openair0_timestamp *timestamp, voi
eth
->
rx_actual_nsamps
=
payload_size
>>
2
;
eth
->
rx_count
++
;
}
#ifdef NOSHIFT
memcpy
(
buff
,(
void
*
)(
temp_rx
+
1
),
payload_size
);
#else
// populate receive buffer in lower 12-bits from 16-bit representation
for
(
int
j
=
1
;
j
<
nsamps2
;
j
++
)
{
#if defined(__x86_64__) || defined(__i386__)
...
...
@@ -486,7 +490,7 @@ int trx_eth_read_udp(openair0_device *device, openair0_timestamp *timestamp, voi
((
int16x8_t
*
)
buff
)[
j
]
=
vshrq_n_s16
(
temp_rx
[
i
][
j
],
2
);
#endif
}
#endif
return
(
payload_size
>>
2
);
}
...
...
targets/RT/USER/lte-ru.c
View file @
5a17c34c
...
...
@@ -185,7 +185,7 @@ void fh_if5_south_in(RU_t *ru,
recv_IF5
(
ru
,
&
proc
->
timestamp_rx
,
*
subframe
,
IF5_RRH_GW_UL
);
proc
->
frame_rx
=
(
proc
->
timestamp_rx
/
(
fp
->
samples_per_tti
*
10
))
&
1023
;
proc
->
tti_rx
=
(
proc
->
timestamp_rx
/
fp
->
samples_per_tti
)
%
10
;
//LOG_I(PHY,"%d.%d (TS %llu) => %d.%d\n",*frame,*subframe,(unsigned long long)proc->timestamp_rx,proc->frame_rx,proc->tti_rx);
if
(
proc
->
first_rx
==
0
)
{
if
(
proc
->
tti_rx
!=
*
subframe
)
{
LOG_E
(
PHY
,
"Received Timestamp doesn't correspond to the time we think it is (proc->tti_rx %d, subframe %d), resynching
\n
"
,
proc
->
tti_rx
,
*
subframe
);
...
...
@@ -680,7 +680,7 @@ void rx_rf(RU_t *ru,
(
int
)
ru
->
ts_offset
,
proc
->
frame_rx
,
proc
->
tti_rx
);
LOG_
D
(
PHY
,
"south_in/rx_rf: RU %d/%d TS %llu (off %d), frame %d, subframe %d
\n
"
,
LOG_
I
(
PHY
,
"south_in/rx_rf: RU %d/%d TS %llu (off %d), frame %d, subframe %d
\n
"
,
ru
->
idx
,
0
,
(
unsigned
long
long
int
)
proc
->
timestamp_rx
,
...
...
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