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
lizhongxiao
OpenXG-RAN
Commits
f0c6b74d
Commit
f0c6b74d
authored
Jan 11, 2019
by
Raymond Knopp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
initialization of transport channels in nr_dlsim
parent
09a481d9
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
105 additions
and
105 deletions
+105
-105
openair1/PHY/CODING/nr_polar_init.c
openair1/PHY/CODING/nr_polar_init.c
+3
-3
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
+2
-2
openair1/SIMULATION/NR_PHY/dlsim.c
openair1/SIMULATION/NR_PHY/dlsim.c
+2
-0
targets/RT/USER/lte-enb.c
targets/RT/USER/lte-enb.c
+7
-7
targets/RT/USER/lte-ru.c
targets/RT/USER/lte-ru.c
+91
-91
targets/RT/USER/nr-uesoftmodem.c
targets/RT/USER/nr-uesoftmodem.c
+0
-2
No files found.
openair1/PHY/CODING/nr_polar_init.c
View file @
f0c6b74d
...
@@ -51,7 +51,7 @@ void nr_polar_init(t_nrPolar_paramsPtr *polarParams,
...
@@ -51,7 +51,7 @@ void nr_polar_init(t_nrPolar_paramsPtr *polarParams,
//Parse the list. If the node is already created, return without initialization.
//Parse the list. If the node is already created, return without initialization.
while
(
currentPtr
!=
NULL
)
{
while
(
currentPtr
!=
NULL
)
{
printf
(
"currentPtr->idx %d, (%d,%d)
\n
"
,
currentPtr
->
idx
,
currentPtr
->
payloadBits
,
currentPtr
->
encoderLength
);
//
printf("currentPtr->idx %d, (%d,%d)\n",currentPtr->idx,currentPtr->payloadBits,currentPtr->encoderLength);
if
(
currentPtr
->
idx
==
(
messageType
*
messageLength
*
aggregation_prime
))
return
;
if
(
currentPtr
->
idx
==
(
messageType
*
messageLength
*
aggregation_prime
))
return
;
else
currentPtr
=
currentPtr
->
nextPtr
;
else
currentPtr
=
currentPtr
->
nextPtr
;
}
}
...
@@ -64,7 +64,7 @@ void nr_polar_init(t_nrPolar_paramsPtr *polarParams,
...
@@ -64,7 +64,7 @@ void nr_polar_init(t_nrPolar_paramsPtr *polarParams,
newPolarInitNode
->
idx
=
(
messageType
*
messageLength
*
aggregation_prime
);
newPolarInitNode
->
idx
=
(
messageType
*
messageLength
*
aggregation_prime
);
newPolarInitNode
->
nextPtr
=
NULL
;
newPolarInitNode
->
nextPtr
=
NULL
;
printf
(
"newPolarInitNode->idx %d, (%d,%d,%d:%d)
\n
"
,
newPolarInitNode
->
idx
,
messageType
,
messageLength
,
aggregation_prime
,
aggregation_level
);
//
printf("newPolarInitNode->idx %d, (%d,%d,%d:%d)\n",newPolarInitNode->idx,messageType,messageLength,aggregation_prime,aggregation_level);
if
(
messageType
==
0
)
{
//PBCH
if
(
messageType
==
0
)
{
//PBCH
newPolarInitNode
->
n_max
=
NR_POLAR_PBCH_N_MAX
;
newPolarInitNode
->
n_max
=
NR_POLAR_PBCH_N_MAX
;
...
@@ -178,7 +178,7 @@ void nr_polar_init(t_nrPolar_paramsPtr *polarParams,
...
@@ -178,7 +178,7 @@ void nr_polar_init(t_nrPolar_paramsPtr *polarParams,
if
(
currentPtr
==
NULL
)
if
(
currentPtr
==
NULL
)
{
{
*
polarParams
=
newPolarInitNode
;
*
polarParams
=
newPolarInitNode
;
printf
(
"Creating first polarParams entry index %d, %p
\n
"
,
newPolarInitNode
->
idx
,
*
polarParams
);
//
printf("Creating first polarParams entry index %d, %p\n",newPolarInitNode->idx,*polarParams);
return
;
return
;
}
}
//Else, add node to the end of the linked list.
//Else, add node to the end of the linked list.
...
...
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
View file @
f0c6b74d
...
@@ -542,7 +542,7 @@ int nr_rx_pbch( PHY_VARS_NR_UE *ue,
...
@@ -542,7 +542,7 @@ int nr_rx_pbch( PHY_VARS_NR_UE *ue,
uint8_t
ssb_index
=
0
;
uint8_t
ssb_index
=
0
;
//uint16_t crc;
//uint16_t crc;
unsigned
short
idx_demod
=
0
;
unsigned
short
idx_demod
=
0
;
int8
_t
decoderState
=
0
;
uint32
_t
decoderState
=
0
;
uint8_t
decoderListSize
=
8
,
pathMetricAppr
=
0
;
uint8_t
decoderListSize
=
8
,
pathMetricAppr
=
0
;
time_stats_t
polar_decoder_init
,
polar_rate_matching
,
decoding
,
bit_extraction
,
deinterleaving
;
time_stats_t
polar_decoder_init
,
polar_rate_matching
,
decoding
,
bit_extraction
,
deinterleaving
;
...
@@ -672,7 +672,7 @@ int nr_rx_pbch( PHY_VARS_NR_UE *ue,
...
@@ -672,7 +672,7 @@ int nr_rx_pbch( PHY_VARS_NR_UE *ue,
decoderState
=
polar_decoder_int16
(
pbch_e_rx
,(
uint8_t
*
)
&
nr_ue_pbch_vars
->
pbch_a_prime
,
currentPtr
);
decoderState
=
polar_decoder_int16
(
pbch_e_rx
,(
uint8_t
*
)
&
nr_ue_pbch_vars
->
pbch_a_prime
,
currentPtr
);
if
(
decoderState
>
0
)
return
(
decoderState
);
if
(
decoderState
)
return
(
decoderState
);
// printf("polar decoder output 0x%08x\n",nr_ue_pbch_vars->pbch_a_prime);
// printf("polar decoder output 0x%08x\n",nr_ue_pbch_vars->pbch_a_prime);
...
...
openair1/SIMULATION/NR_PHY/dlsim.c
View file @
f0c6b74d
...
@@ -487,6 +487,8 @@ int main(int argc, char **argv)
...
@@ -487,6 +487,8 @@ int main(int argc, char **argv)
exit
(
-
1
);
exit
(
-
1
);
}
}
init_nr_ue_transport
(
UE
,
0
);
nr_gold_pbch
(
UE
);
nr_gold_pbch
(
UE
);
nr_gold_pdcch
(
UE
,
0
,
2
);
nr_gold_pdcch
(
UE
,
0
,
2
);
...
...
targets/RT/USER/lte-enb.c
View file @
f0c6b74d
...
@@ -453,13 +453,13 @@ void eNB_top(PHY_VARS_eNB *eNB, int frame_rx, int subframe_rx, char *string,RU_t
...
@@ -453,13 +453,13 @@ void eNB_top(PHY_VARS_eNB *eNB, int frame_rx, int subframe_rx, char *string,RU_t
proc_rxtx
->
timestamp_tx
=
ru_proc
->
timestamp_rx
+
(
sf_ahead
*
fp
->
samples_per_tti
);
proc_rxtx
->
timestamp_tx
=
ru_proc
->
timestamp_rx
+
(
sf_ahead
*
fp
->
samples_per_tti
);
proc_rxtx
->
frame_rx
=
ru_proc
->
frame_rx
;
proc_rxtx
->
frame_rx
=
ru_proc
->
frame_rx
;
proc_rxtx
->
subframe_rx
=
ru_proc
->
subframe
_rx
;
proc_rxtx
->
subframe_rx
=
ru_proc
->
tti
_rx
;
proc_rxtx
->
frame_tx
=
(
proc_rxtx
->
subframe_rx
>
(
9
-
sf_ahead
))
?
(
proc_rxtx
->
frame_rx
+
1
)
&
1023
:
proc_rxtx
->
frame_rx
;
proc_rxtx
->
frame_tx
=
(
proc_rxtx
->
subframe_rx
>
(
9
-
sf_ahead
))
?
(
proc_rxtx
->
frame_rx
+
1
)
&
1023
:
proc_rxtx
->
frame_rx
;
proc_rxtx
->
subframe_tx
=
(
proc_rxtx
->
subframe_rx
+
sf_ahead
)
%
10
;
proc_rxtx
->
subframe_tx
=
(
proc_rxtx
->
subframe_rx
+
sf_ahead
)
%
10
;
if
(
rxtx
(
eNB
,
proc_rxtx
,
string
)
<
0
)
LOG_E
(
PHY
,
"eNB %d CC_id %d failed during execution
\n
"
,
eNB
->
Mod_id
,
eNB
->
CC_id
);
if
(
rxtx
(
eNB
,
proc_rxtx
,
string
)
<
0
)
LOG_E
(
PHY
,
"eNB %d CC_id %d failed during execution
\n
"
,
eNB
->
Mod_id
,
eNB
->
CC_id
);
ru_proc
->
timestamp_tx
=
proc_rxtx
->
timestamp_tx
;
ru_proc
->
timestamp_tx
=
proc_rxtx
->
timestamp_tx
;
ru_proc
->
subframe
_tx
=
proc_rxtx
->
subframe_tx
;
ru_proc
->
tti
_tx
=
proc_rxtx
->
subframe_tx
;
ru_proc
->
frame_tx
=
proc_rxtx
->
frame_tx
;
ru_proc
->
frame_tx
=
proc_rxtx
->
frame_tx
;
}
}
}
}
...
@@ -474,24 +474,24 @@ int wakeup_txfh(eNB_rxtx_proc_t *proc,RU_proc_t *ru_proc) {
...
@@ -474,24 +474,24 @@ int wakeup_txfh(eNB_rxtx_proc_t *proc,RU_proc_t *ru_proc) {
if
(
wait_on_condition
(
&
ru_proc
->
mutex_eNBs
,
&
ru_proc
->
cond_eNBs
,
&
ru_proc
->
ru_tx_ready
,
"wakeup_txfh"
)
<
0
)
{
if
(
wait_on_condition
(
&
ru_proc
->
mutex_eNBs
,
&
ru_proc
->
cond_eNBs
,
&
ru_proc
->
ru_tx_ready
,
"wakeup_txfh"
)
<
0
)
{
LOG_E
(
PHY
,
"Frame %d, subframe %d: TX FH not ready
\n
"
,
ru_proc
->
frame_tx
,
ru_proc
->
subframe
_tx
);
LOG_E
(
PHY
,
"Frame %d, subframe %d: TX FH not ready
\n
"
,
ru_proc
->
frame_tx
,
ru_proc
->
tti
_tx
);
return
(
-
1
);
return
(
-
1
);
}
}
if
(
release_thread
(
&
ru_proc
->
mutex_eNBs
,
&
ru_proc
->
ru_tx_ready
,
"wakeup_txfh"
)
<
0
)
return
(
-
1
);
if
(
release_thread
(
&
ru_proc
->
mutex_eNBs
,
&
ru_proc
->
ru_tx_ready
,
"wakeup_txfh"
)
<
0
)
return
(
-
1
);
if
(
ru_proc
->
instance_cnt_eNBs
==
0
)
{
if
(
ru_proc
->
instance_cnt_eNBs
==
0
)
{
LOG_E
(
PHY
,
"Frame %d, subframe %d: TX FH thread busy, dropping Frame %d, subframe %d
\n
"
,
ru_proc
->
frame_tx
,
ru_proc
->
subframe
_tx
,
proc
->
frame_rx
,
proc
->
subframe_rx
);
LOG_E
(
PHY
,
"Frame %d, subframe %d: TX FH thread busy, dropping Frame %d, subframe %d
\n
"
,
ru_proc
->
frame_tx
,
ru_proc
->
tti
_tx
,
proc
->
frame_rx
,
proc
->
subframe_rx
);
return
(
-
1
);
return
(
-
1
);
}
}
if
(
pthread_mutex_timedlock
(
&
ru_proc
->
mutex_eNBs
,
&
wait
)
!=
0
)
{
if
(
pthread_mutex_timedlock
(
&
ru_proc
->
mutex_eNBs
,
&
wait
)
!=
0
)
{
LOG_E
(
PHY
,
"[eNB] ERROR pthread_mutex_lock for eNB TX1 thread %d (IC %d)
\n
"
,
ru_proc
->
subframe
_rx
&
1
,
ru_proc
->
instance_cnt_eNBs
);
LOG_E
(
PHY
,
"[eNB] ERROR pthread_mutex_lock for eNB TX1 thread %d (IC %d)
\n
"
,
ru_proc
->
tti
_rx
&
1
,
ru_proc
->
instance_cnt_eNBs
);
exit_fun
(
"error locking mutex_eNB"
);
exit_fun
(
"error locking mutex_eNB"
);
return
(
-
1
);
return
(
-
1
);
}
}
++
ru_proc
->
instance_cnt_eNBs
;
++
ru_proc
->
instance_cnt_eNBs
;
ru_proc
->
timestamp_tx
=
proc
->
timestamp_tx
;
ru_proc
->
timestamp_tx
=
proc
->
timestamp_tx
;
ru_proc
->
subframe
_tx
=
proc
->
subframe_tx
;
ru_proc
->
tti
_tx
=
proc
->
subframe_tx
;
ru_proc
->
frame_tx
=
proc
->
frame_tx
;
ru_proc
->
frame_tx
=
proc
->
frame_tx
;
// the thread can now be woken up
// the thread can now be woken up
...
@@ -622,7 +622,7 @@ int wakeup_rxtx(PHY_VARS_eNB *eNB,RU_t *ru) {
...
@@ -622,7 +622,7 @@ int wakeup_rxtx(PHY_VARS_eNB *eNB,RU_t *ru) {
// and proc->subframe_tx = proc->subframe_rx+sf_ahead
// and proc->subframe_tx = proc->subframe_rx+sf_ahead
proc_rxtx0
->
timestamp_tx
=
ru_proc
->
timestamp_rx
+
(
sf_ahead
*
fp
->
samples_per_tti
);
proc_rxtx0
->
timestamp_tx
=
ru_proc
->
timestamp_rx
+
(
sf_ahead
*
fp
->
samples_per_tti
);
proc_rxtx0
->
frame_rx
=
ru_proc
->
frame_rx
;
proc_rxtx0
->
frame_rx
=
ru_proc
->
frame_rx
;
proc_rxtx0
->
subframe_rx
=
ru_proc
->
subframe
_rx
;
proc_rxtx0
->
subframe_rx
=
ru_proc
->
tti
_rx
;
proc_rxtx0
->
frame_tx
=
(
proc_rxtx0
->
subframe_rx
>
(
9
-
sf_ahead
))
?
(
proc_rxtx0
->
frame_rx
+
1
)
&
1023
:
proc_rxtx0
->
frame_rx
;
proc_rxtx0
->
frame_tx
=
(
proc_rxtx0
->
subframe_rx
>
(
9
-
sf_ahead
))
?
(
proc_rxtx0
->
frame_rx
+
1
)
&
1023
:
proc_rxtx0
->
frame_rx
;
proc_rxtx0
->
subframe_tx
=
(
proc_rxtx0
->
subframe_rx
+
sf_ahead
)
%
10
;
proc_rxtx0
->
subframe_tx
=
(
proc_rxtx0
->
subframe_rx
+
sf_ahead
)
%
10
;
...
...
targets/RT/USER/lte-ru.c
View file @
f0c6b74d
This diff is collapsed.
Click to expand it.
targets/RT/USER/nr-uesoftmodem.c
View file @
f0c6b74d
...
@@ -658,8 +658,6 @@ void set_default_frame_parms(NR_DL_FRAME_PARMS *frame_parms[MAX_NUM_CCs]) {
...
@@ -658,8 +658,6 @@ void set_default_frame_parms(NR_DL_FRAME_PARMS *frame_parms[MAX_NUM_CCs]) {
config
[
CC_id
]
->
subframe_config
.
dl_cyclic_prefix_type
.
value
=
0
;
//NORMAL
config
[
CC_id
]
->
subframe_config
.
dl_cyclic_prefix_type
.
value
=
0
;
//NORMAL
config
[
CC_id
]
->
rf_config
.
dl_carrier_bandwidth
.
value
=
106
;
config
[
CC_id
]
->
rf_config
.
dl_carrier_bandwidth
.
value
=
106
;
config
[
CC_id
]
->
rf_config
.
ul_carrier_bandwidth
.
value
=
106
;
config
[
CC_id
]
->
rf_config
.
ul_carrier_bandwidth
.
value
=
106
;
config
[
CC_id
]
->
rf_config
.
tx_antenna_ports
.
value
=
1
;
config
[
CC_id
]
->
rf_config
.
rx_antenna_ports
.
value
=
1
;
config
[
CC_id
]
->
sch_config
.
physical_cell_id
.
value
=
0
;
config
[
CC_id
]
->
sch_config
.
physical_cell_id
.
value
=
0
;
frame_parms
[
CC_id
]
->
frame_type
=
FDD
;
frame_parms
[
CC_id
]
->
frame_type
=
FDD
;
...
...
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