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
ZhouShuya
OpenXG-RAN
Commits
4c5d5ea4
Commit
4c5d5ea4
authored
6 years ago
by
Hongzhi Wang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ue switch to slot based processing
parent
682ca5eb
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
72 additions
and
64 deletions
+72
-64
openair1/PHY/MODULATION/slot_fep_nr.c
openair1/PHY/MODULATION/slot_fep_nr.c
+10
-10
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
+10
-10
openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
+3
-3
openair1/PHY/NR_UE_TRANSPORT/dci_tools_nr.c
openair1/PHY/NR_UE_TRANSPORT/dci_tools_nr.c
+1
-1
openair1/PHY/defs_nr_UE.h
openair1/PHY/defs_nr_UE.h
+1
-1
openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
+4
-2
targets/RT/USER/nr-ue.c
targets/RT/USER/nr-ue.c
+43
-37
No files found.
openair1/PHY/MODULATION/slot_fep_nr.c
View file @
4c5d5ea4
...
...
@@ -54,7 +54,7 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue,
//int i;
unsigned
int
frame_length_samples
=
frame_parms
->
samples_per_subframe
*
10
;
unsigned
int
rx_offset
;
NR_UE_PDCCH
*
pdcch_vars
=
ue
->
pdcch_vars
[
ue
->
current_thread_id
[
Ns
>>
1
]][
0
];
NR_UE_PDCCH
*
pdcch_vars
=
ue
->
pdcch_vars
[
ue
->
current_thread_id
[
Ns
]][
0
];
uint16_t
coreset_start_subcarrier
=
frame_parms
->
first_carrier_offset
;
//+((int)floor(frame_parms->ssb_start_subcarrier/NR_NB_SC_PER_RB)+pdcch_vars->coreset[0].rb_offset)*NR_NB_SC_PER_RB;
uint16_t
nb_rb_coreset
=
24
;
uint16_t
bwp_start_subcarrier
=
frame_parms
->
first_carrier_offset
;
//+516;
...
...
@@ -104,9 +104,9 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue,
}
if
(
no_prefix
)
{
slot_offset
=
frame_parms
->
ofdm_symbol_size
*
(
frame_parms
->
symbols_per_slot
*
frame_parms
->
slots_per_subframe
)
*
(
Ns
>>
1
);
slot_offset
=
frame_parms
->
ofdm_symbol_size
*
(
frame_parms
->
symbols_per_slot
)
*
(
Ns
);
}
else
{
slot_offset
=
(
frame_parms
->
samples_per_s
ubframe
)
*
(
Ns
>>
1
);
slot_offset
=
(
frame_parms
->
samples_per_s
lot
)
*
(
Ns
);
}
/*if (l<0 || l>=7-frame_parms->Ncp) {
...
...
@@ -122,7 +122,7 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue,
for
(
aa
=
0
;
aa
<
frame_parms
->
nb_antennas_rx
;
aa
++
)
{
memset
(
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
0
,
frame_parms
->
ofdm_symbol_size
*
sizeof
(
int
));
memset
(
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
0
,
frame_parms
->
ofdm_symbol_size
*
sizeof
(
int
));
rx_offset
=
sample_offset
+
slot_offset
+
nb_prefix_samples0
-
SOFFSET
;
// Align with 256 bit
...
...
@@ -130,8 +130,8 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue,
#ifdef DEBUG_FEP
// if (ue->frame <100)
/*LOG_I(PHY,*/
printf
(
"slot_fep: frame %d: slot %d, symbol %d, nb_prefix_samples %d, nb_prefix_samples0 %d, slot_offset %d,
subframe_offset %d, sample_offset %d,rx_offset %d, frame_length_samples %d
\n
"
,
ue
->
proc
.
proc_rxtx
[(
Ns
>>
1
)
&
1
].
frame_rx
,
Ns
,
symbol
,
nb_prefix_samples
,
nb_prefix_samples0
,
slot_offset
,
s
ubframe_offset
,
s
ample_offset
,
rx_offset
,
frame_length_samples
);
/*LOG_I(PHY,*/
printf
(
"slot_fep: frame %d: slot %d, symbol %d, nb_prefix_samples %d, nb_prefix_samples0 %d, slot_offset %d,
sample_offset %d,rx_offset %d, frame_length_samples %d
\n
"
,
ue
->
proc
.
proc_rxtx
[(
Ns
)
&
1
].
frame_rx
,
Ns
,
symbol
,
nb_prefix_samples
,
nb_prefix_samples0
,
slot_offset
,
sample_offset
,
rx_offset
,
frame_length_samples
);
#endif
if
(
l
==
0
)
{
...
...
@@ -146,14 +146,14 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue,
(
void
*
)
&
common_vars
->
rxdata
[
aa
][
rx_offset
%
frame_length_samples
],
frame_parms
->
ofdm_symbol_size
*
sizeof
(
int
));
dft
((
int16_t
*
)
tmp_dft_in
,
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
}
else
{
// use dft input from RX buffer directly
#if UE_TIMING_TRACE
start_meas
(
&
ue
->
rx_dft_stats
);
#endif
dft
((
int16_t
*
)
&
common_vars
->
rxdata
[
aa
][(
rx_offset
)
%
frame_length_samples
],
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
#if UE_TIMING_TRACE
stop_meas
(
&
ue
->
rx_dft_stats
);
#endif
...
...
@@ -175,11 +175,11 @@ int nr_slot_fep(PHY_VARS_NR_UE *ue,
(
void
*
)
&
common_vars
->
rxdata
[
aa
][(
rx_offset
)
%
frame_length_samples
],
frame_parms
->
ofdm_symbol_size
*
sizeof
(
int
));
dft
((
int16_t
*
)
tmp_dft_in
,
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
}
else
{
// use dft input from RX buffer directly
dft
((
int16_t
*
)
&
common_vars
->
rxdata
[
aa
][(
rx_offset
)
%
frame_length_samples
],
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
(
int16_t
*
)
&
common_vars
->
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
rxdataF
[
aa
][
frame_parms
->
ofdm_symbol_size
*
symbol
],
1
);
}
#if UE_TIMING_TRACE
stop_meas
(
&
ue
->
rx_dft_stats
);
...
...
This diff is collapsed.
Click to expand it.
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
View file @
4c5d5ea4
...
...
@@ -272,8 +272,8 @@ int nr_pdcch_channel_estimation(PHY_VARS_NR_UE *ue,
//uint16_t Nid_cell = (eNB_offset == 0) ? ue->frame_parms.Nid_cell : ue->measurements.adj_cell_id[eNB_offset-1];
uint8_t
nushift
;
int
**
dl_ch_estimates
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
dl_ch_estimates
[
eNB_offset
];
int
**
rxdataF
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
rxdataF
;
int
**
dl_ch_estimates
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
dl_ch_estimates
[
eNB_offset
];
int
**
rxdataF
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
rxdataF
;
nushift
=
1
;
ue
->
frame_parms
.
nushift
=
nushift
;
...
...
@@ -288,7 +288,7 @@ int nr_pdcch_channel_estimation(PHY_VARS_NR_UE *ue,
k
=
coreset_start_subcarrier
;
#ifdef DEBUG_PDCCH
printf
(
"PDCCH Channel Estimation : ThreadId %d, eNB_offset %d ch_offset %d, OFDM size %d, Ncp=%d, l=%d, Ns=%d, k=%d symbol %d
\n
"
,
ue
->
current_thread_id
[
Ns
>>
1
],
eNB_offset
,
ch_offset
,
ue
->
frame_parms
.
ofdm_symbol_size
,
printf
(
"PDCCH Channel Estimation : ThreadId %d, eNB_offset %d ch_offset %d, OFDM size %d, Ncp=%d, l=%d, Ns=%d, k=%d symbol %d
\n
"
,
ue
->
current_thread_id
[
Ns
],
eNB_offset
,
ch_offset
,
ue
->
frame_parms
.
ofdm_symbol_size
,
ue
->
frame_parms
.
Ncp
,
l
,
Ns
,
k
,
symbol
);
#endif
...
...
@@ -460,16 +460,16 @@ int nr_pdcch_channel_estimation(PHY_VARS_NR_UE *ue,
break
;
}
if
(
(
Ns
==
2
)
&&
(
l
==
0
))
if
(
(
Ns
==
1
)
&&
(
l
==
0
))
{
// do ifft of channel estimate
for
(
aarx
=
0
;
aarx
<
ue
->
frame_parms
.
nb_antennas_rx
;
aarx
++
)
for
(
p
=
0
;
p
<
ue
->
frame_parms
.
nb_antenna_ports_eNB
;
p
++
)
{
if
(
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
dl_ch_estimates
[
eNB_offset
][(
p
<<
1
)
+
aarx
])
if
(
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
dl_ch_estimates
[
eNB_offset
][(
p
<<
1
)
+
aarx
])
{
LOG_D
(
PHY
,
"Channel Impulse Computation Slot %d ThreadId %d Symbol %d
\n
"
,
Ns
,
ue
->
current_thread_id
[
Ns
>>
1
],
l
);
idft
((
int16_t
*
)
&
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
dl_ch_estimates
[
eNB_offset
][(
p
<<
1
)
+
aarx
][
0
],
(
int16_t
*
)
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
dl_ch_estimates_time
[
eNB_offset
][(
p
<<
1
)
+
aarx
],
1
);
LOG_D
(
PHY
,
"Channel Impulse Computation Slot %d ThreadId %d Symbol %d
\n
"
,
Ns
,
ue
->
current_thread_id
[
Ns
],
l
);
idft
((
int16_t
*
)
&
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
dl_ch_estimates
[
eNB_offset
][(
p
<<
1
)
+
aarx
][
0
],
(
int16_t
*
)
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
dl_ch_estimates_time
[
eNB_offset
][(
p
<<
1
)
+
aarx
],
1
);
}
}
}
...
...
@@ -497,8 +497,8 @@ int nr_pdsch_channel_estimation(PHY_VARS_NR_UE *ue,
//uint16_t Nid_cell = (eNB_offset == 0) ? ue->frame_parms.Nid_cell : ue->measurements.adj_cell_id[eNB_offset-1];
uint8_t
nushift
;
int
**
dl_ch_estimates
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
dl_ch_estimates
[
eNB_offset
];
int
**
rxdataF
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
>>
1
]].
rxdataF
;
int
**
dl_ch_estimates
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
dl_ch_estimates
[
eNB_offset
];
int
**
rxdataF
=
ue
->
common_vars
.
common_vars_rx_data_per_thread
[
ue
->
current_thread_id
[
Ns
]].
rxdataF
;
nushift
=
(
p
>>
1
)
&
1
;
ue
->
frame_parms
.
nushift
=
nushift
;
...
...
This diff is collapsed.
Click to expand it.
openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
View file @
4c5d5ea4
...
...
@@ -49,7 +49,7 @@
//#define NR_LTE_PDCCH_DCI_SWITCH
#define NR_PDCCH_DCI_RUN // activates new nr functions
#define NR_PDCCH_DCI_DEBUG // activates NR_PDCCH_DCI_DEBUG logs
//
#define NR_PDCCH_DCI_DEBUG // activates NR_PDCCH_DCI_DEBUG logs
#define NR_NBR_CORESET_ACT_BWP 3 // The number of CoreSets per BWP is limited to 3 (including initial CORESET: ControlResourceId 0)
#define NR_NBR_SEARCHSPACE_ACT_BWP 10 // The number of SearSpaces per BWP is limited to 10 (including initial SEARCHSPACE: SearchSpaceId 0)
#define PDCCH_TEST_POLAR_TEMP_FIX
...
...
@@ -1451,12 +1451,12 @@ void nr_dci_decoding_procedure0(int s,
dci_alloc
[
*
dci_cnt
].
dci_pdu
[
1
]
=
dci_estimation
[
1
];
dci_alloc
[
*
dci_cnt
].
dci_pdu
[
2
]
=
dci_estimation
[
2
];
dci_alloc
[
*
dci_cnt
].
dci_pdu
[
3
]
=
dci_estimation
[
3
];
#ifdef NR_PDCCH_DCI_DEBUG
//
#ifdef NR_PDCCH_DCI_DEBUG
printf
(
"
\t\t
<-NR_PDCCH_DCI_DEBUG (nr_dci_decoding_procedure0)-> rnti matches -> DCI FOUND !!! crc =>%x, sizeof_bits %d, sizeof_bytes %d
\n
"
,
dci_alloc
[
*
dci_cnt
].
rnti
,
dci_alloc
[
*
dci_cnt
].
dci_length
,
sizeof_bytes
);
printf
(
"
\t\t
<-NR_PDCCH_DCI_DEBUG (nr_dci_decoding_procedure0)-> dci_cnt %d (format_css %d crc_scrambled %d) L %d, firstCCE %d pdu[0] %x pdu[1] %x pdu[2] %x pdu[3] %x
\n
"
,
*
dci_cnt
,
format_css
,
*
crc_scrambled
,
dci_alloc
[
*
dci_cnt
].
L
,
dci_alloc
[
*
dci_cnt
].
firstCCE
,
dci_alloc
[
*
dci_cnt
].
dci_pdu
[
0
],
dci_alloc
[
*
dci_cnt
].
dci_pdu
[
1
],
dci_alloc
[
*
dci_cnt
].
dci_pdu
[
2
],
dci_alloc
[
*
dci_cnt
].
dci_pdu
[
3
]);
#endif
//
#endif
if
((
format_css
==
cformat0_0_and_1_0
)
||
(
format_uss
==
uformat0_0_and_1_0
)){
if
((
*
crc_scrambled
==
_p_rnti
)
||
(
*
crc_scrambled
==
_si_rnti
)
||
(
*
crc_scrambled
==
_ra_rnti
)){
dci_alloc
[
*
dci_cnt
].
format
=
format1_0
;
...
...
This diff is collapsed.
Click to expand it.
openair1/PHY/NR_UE_TRANSPORT/dci_tools_nr.c
View file @
4c5d5ea4
...
...
@@ -52,7 +52,7 @@
//#define DEBUG_DCI
#define NR_PDCCH_DCI_TOOLS
#define NR_PDCCH_DCI_TOOLS_DEBUG
//
#define NR_PDCCH_DCI_TOOLS_DEBUG
typedef
unsigned
__int128
uint128_t
;
...
...
This diff is collapsed.
Click to expand it.
openair1/PHY/defs_nr_UE.h
View file @
4c5d5ea4
...
...
@@ -1030,7 +1030,7 @@ typedef struct {
fapi_nr_dci_indication_t
dci_ind
;
// point to the current rxTx thread index
uint8_t
current_thread_id
[
1
0
];
uint8_t
current_thread_id
[
4
0
];
NR_UE_PDSCH
*
pdsch_vars
[
RX_NB_TH_MAX
][
NUMBER_OF_CONNECTED_eNB_MAX
+
1
];
// two RxTx Threads
NR_UE_PDSCH_FLP
*
pdsch_vars_flp
[
NUMBER_OF_CONNECTED_eNB_MAX
+
1
];
...
...
This diff is collapsed.
Click to expand it.
openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
View file @
4c5d5ea4
...
...
@@ -56,7 +56,7 @@
//#define DEBUG_PHY_PROC
#define NR_PDCCH_SCHED
#define NR_PDCCH_SCHED_DEBUG
//
#define NR_PDCCH_SCHED_DEBUG
//#define NR_PUCCH_SCHED
//#define NR_PUCCH_SCHED_DEBUG
...
...
@@ -3081,6 +3081,8 @@ int nr_ue_pdcch_procedures(uint8_t eNB_id,PHY_VARS_NR_UE *ue,UE_nr_rxtx_proc_t *
// Higher layers have updated the number of searchSpaces with are active in the current slot and this value is stored in variable nb_searchspace_total
int
nb_searchspace_total
=
pdcch_vars2
->
nb_search_space
;
pdcch_vars
[
eNB_id
]
->
crnti
=
0x1234
;
//to be check how to set when using loop memory
uint16_t
c_rnti
=
pdcch_vars
[
eNB_id
]
->
crnti
;
uint16_t
cs_rnti
,
new_rnti
,
tc_rnti
;
uint16_t
p_rnti
=
P_RNTI
;
...
...
@@ -5075,7 +5077,7 @@ int phy_procedures_nrUE_RX(PHY_VARS_NR_UE *ue,UE_nr_rxtx_proc_t *proc,uint8_t eN
#endif
//printf("phy procedure pdcch start measurement l =%d\n",l);
nr_ue_measurement_procedures
(
l
,
ue
,
proc
,
eNB_id
,(
nr_tti_rx
<<
1
),
mode
);
nr_ue_measurement_procedures
(
l
,
ue
,
proc
,
eNB_id
,(
nr_tti_rx
),
mode
);
}
...
...
This diff is collapsed.
Click to expand it.
targets/RT/USER/nr-ue.c
View file @
4c5d5ea4
This diff is collapsed.
Click to expand it.
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