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
spbro
OpenXG-RAN
Commits
00cb43ba
Commit
00cb43ba
authored
Jul 26, 2024
by
Laurent THOMAS
Committed by
Robert Schmidt
Jul 30, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use gold cache for PRS decoding
parent
7563937a
Changes
17
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
34 additions
and
177 deletions
+34
-177
openair1/PHY/INIT/nr_init.c
openair1/PHY/INIT/nr_init.c
+0
-15
openair1/PHY/INIT/nr_init_ue.c
openair1/PHY/INIT/nr_init_ue.c
+0
-44
openair1/PHY/NR_REFSIG/nr_gold.c
openair1/PHY/NR_REFSIG/nr_gold.c
+0
-52
openair1/PHY/NR_REFSIG/nr_gold_ue.c
openair1/PHY/NR_REFSIG/nr_gold_ue.c
+0
-37
openair1/PHY/NR_REFSIG/nr_refsig.h
openair1/PHY/NR_REFSIG/nr_refsig.h
+0
-8
openair1/PHY/NR_REFSIG/nr_refsig_common.h
openair1/PHY/NR_REFSIG/nr_refsig_common.h
+1
-0
openair1/PHY/NR_REFSIG/refsig.c
openair1/PHY/NR_REFSIG/refsig.c
+13
-0
openair1/PHY/NR_REFSIG/refsig_defs_ue.h
openair1/PHY/NR_REFSIG/refsig_defs_ue.h
+0
-1
openair1/PHY/NR_TRANSPORT/nr_prs.c
openair1/PHY/NR_TRANSPORT/nr_prs.c
+9
-8
openair1/PHY/NR_TRANSPORT/nr_scrambling.c
openair1/PHY/NR_TRANSPORT/nr_scrambling.c
+1
-0
openair1/PHY/NR_TRANSPORT/nr_transport_proto.h
openair1/PHY/NR_TRANSPORT/nr_transport_proto.h
+1
-1
openair1/PHY/NR_TRANSPORT/nr_uci_tools_common.c
openair1/PHY/NR_TRANSPORT/nr_uci_tools_common.c
+2
-0
openair1/PHY/NR_TRANSPORT/pucch_rx.c
openair1/PHY/NR_TRANSPORT/pucch_rx.c
+1
-0
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
+5
-4
openair1/PHY/defs_gNB.h
openair1/PHY/defs_gNB.h
+0
-3
openair1/PHY/defs_nr_UE.h
openair1/PHY/defs_nr_UE.h
+0
-3
openair1/SCHED_NR/phy_procedures_nr_gNB.c
openair1/SCHED_NR/phy_procedures_nr_gNB.c
+1
-1
No files found.
openair1/PHY/INIT/nr_init.c
View file @
00cb43ba
...
...
@@ -154,9 +154,6 @@ int phy_init_nr_gNB(PHY_VARS_gNB *gNB)
// ceil((NB_RB*8(max allocation per RB)*2(QPSK))/32)
gNB
->
nr_csi_info
=
(
nr_csi_info_t
*
)
malloc16_clear
(
sizeof
(
nr_csi_info_t
));
//PRS init
nr_init_prs
(
gNB
);
generate_ul_reference_signal_sequences
(
SHRT_MAX
);
/* Generate low PAPR type 1 sequences for PUSCH DMRS, these are used if transform precoding is enabled. */
...
...
@@ -240,7 +237,6 @@ int phy_init_nr_gNB(PHY_VARS_gNB *gNB)
void
phy_free_nr_gNB
(
PHY_VARS_gNB
*
gNB
)
{
NR_DL_FRAME_PARMS
*
const
fp
=
&
gNB
->
frame_parms
;
const
int
Ptx
=
gNB
->
gNB_config
.
carrier_config
.
num_tx_ant
.
value
;
const
int
Prx
=
gNB
->
gNB_config
.
carrier_config
.
num_rx_ant
.
value
;
const
int
max_ul_mimo_layers
=
4
;
// taken from phy_init_nr_gNB()
...
...
@@ -274,17 +270,6 @@ void phy_free_nr_gNB(PHY_VARS_gNB *gNB)
free_and_zero
(
common_vars
->
beam_id
[
i
]);
}
for
(
int
rsc
=
0
;
rsc
<
gNB
->
prs_vars
.
NumPRSResources
;
rsc
++
)
{
for
(
int
slot
=
0
;
slot
<
fp
->
slots_per_frame
;
slot
++
)
{
for
(
int
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
free_and_zero
(
gNB
->
nr_gold_prs
[
rsc
][
slot
][
symb
]);
}
free_and_zero
(
gNB
->
nr_gold_prs
[
rsc
][
slot
]);
}
free_and_zero
(
gNB
->
nr_gold_prs
[
rsc
]);
}
free_and_zero
(
gNB
->
nr_gold_prs
);
/* Do NOT free per-antenna txdataF/rxdataF: the gNB gets a pointer to the
* RU's txdataF/rxdataF, and the RU will free that */
free_and_zero
(
common_vars
->
txdataF
);
...
...
openair1/PHY/INIT/nr_init_ue.c
View file @
00cb43ba
...
...
@@ -162,32 +162,6 @@ void init_nr_prs_ue_vars(PHY_VARS_NR_UE *ue)
// load the config file params
RCconfig_nrUE_prs
(
ue
);
//PRS sequence init
ue
->
nr_gold_prs
=
malloc16
(
ue
->
prs_active_gNBs
*
sizeof
(
uint32_t
****
));
uint32_t
*****
prs
=
ue
->
nr_gold_prs
;
AssertFatal
(
prs
!=
NULL
,
"%s: positioning reference signal malloc failed
\n
"
,
__FUNCTION__
);
for
(
int
gnb
=
0
;
gnb
<
ue
->
prs_active_gNBs
;
gnb
++
)
{
prs
[
gnb
]
=
malloc16
(
ue
->
prs_vars
[
gnb
]
->
NumPRSResources
*
sizeof
(
uint32_t
***
));
AssertFatal
(
prs
[
gnb
]
!=
NULL
,
"%s: positioning reference signal for gnb %d - malloc failed
\n
"
,
__FUNCTION__
,
gnb
);
for
(
int
rsc
=
0
;
rsc
<
ue
->
prs_vars
[
gnb
]
->
NumPRSResources
;
rsc
++
)
{
prs
[
gnb
][
rsc
]
=
malloc16
(
fp
->
slots_per_frame
*
sizeof
(
uint32_t
**
));
AssertFatal
(
prs
[
gnb
][
rsc
]
!=
NULL
,
"%s: positioning reference signal for gnb %d rsc %d- malloc failed
\n
"
,
__FUNCTION__
,
gnb
,
rsc
);
for
(
int
slot
=
0
;
slot
<
fp
->
slots_per_frame
;
slot
++
)
{
prs
[
gnb
][
rsc
][
slot
]
=
malloc16
(
fp
->
symbols_per_slot
*
sizeof
(
uint32_t
*
));
AssertFatal
(
prs
[
gnb
][
rsc
][
slot
]
!=
NULL
,
"%s: positioning reference signal for gnb %d rsc %d slot %d - malloc failed
\n
"
,
__FUNCTION__
,
gnb
,
rsc
,
slot
);
for
(
int
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
prs
[
gnb
][
rsc
][
slot
][
symb
]
=
malloc16
(
NR_MAX_PRS_INIT_LENGTH_DWORD
*
sizeof
(
uint32_t
));
AssertFatal
(
prs
[
gnb
][
rsc
][
slot
][
symb
]
!=
NULL
,
"%s: positioning reference signal for gnb %d rsc %d slot %d symbol %d - malloc failed
\n
"
,
__FUNCTION__
,
gnb
,
rsc
,
slot
,
symb
);
}
// for symb
}
// for slot
}
// for rsc
}
// for gnb
init_nr_gold_prs
(
ue
);
}
int
init_nr_ue_signal
(
PHY_VARS_NR_UE
*
ue
,
int
nb_connected_gNB
)
...
...
@@ -362,24 +336,6 @@ void term_nr_ue_signal(PHY_VARS_NR_UE *ue, int nb_connected_gNB)
free_and_zero
(
ue
->
prach_vars
[
gNB_id
]);
}
for
(
int
gnb
=
0
;
gnb
<
ue
->
prs_active_gNBs
;
gnb
++
)
{
for
(
int
rsc
=
0
;
rsc
<
ue
->
prs_vars
[
gnb
]
->
NumPRSResources
;
rsc
++
)
{
for
(
int
slot
=
0
;
slot
<
fp
->
slots_per_frame
;
slot
++
)
{
for
(
int
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
free_and_zero
(
ue
->
nr_gold_prs
[
gnb
][
rsc
][
slot
][
symb
]);
}
free_and_zero
(
ue
->
nr_gold_prs
[
gnb
][
rsc
][
slot
]);
}
free_and_zero
(
ue
->
nr_gold_prs
[
gnb
][
rsc
]);
}
free_and_zero
(
ue
->
nr_gold_prs
[
gnb
]);
}
free_and_zero
(
ue
->
nr_gold_prs
);
for
(
int
idx
=
0
;
idx
<
NR_MAX_PRS_COMB_SIZE
;
idx
++
)
{
for
(
int
k
=
0
;
k
<
NR_MAX_PRS_RESOURCES_PER_SET
;
k
++
)
...
...
openair1/PHY/NR_REFSIG/nr_gold.c
View file @
00cb43ba
...
...
@@ -20,55 +20,3 @@
*/
#include "nr_refsig.h"
void
nr_init_prs
(
PHY_VARS_gNB
*
gNB
)
{
unsigned
int
x1
=
0
,
x2
=
0
;
uint16_t
Nid
;
NR_DL_FRAME_PARMS
*
fp
=
&
gNB
->
frame_parms
;
gNB
->
nr_gold_prs
=
(
uint32_t
****
)
malloc16
(
gNB
->
prs_vars
.
NumPRSResources
*
sizeof
(
uint32_t
***
));
uint32_t
****
prs
=
gNB
->
nr_gold_prs
;
AssertFatal
(
prs
!=
NULL
,
"NR init: positioning reference signal malloc failed
\n
"
);
for
(
int
rsc
=
0
;
rsc
<
gNB
->
prs_vars
.
NumPRSResources
;
rsc
++
)
{
prs
[
rsc
]
=
(
uint32_t
***
)
malloc16
(
fp
->
slots_per_frame
*
sizeof
(
uint32_t
**
));
AssertFatal
(
prs
[
rsc
]
!=
NULL
,
"NR init: positioning reference signal for rsc %d - malloc failed
\n
"
,
rsc
);
for
(
int
slot
=
0
;
slot
<
fp
->
slots_per_frame
;
slot
++
)
{
prs
[
rsc
][
slot
]
=
(
uint32_t
**
)
malloc16
(
fp
->
symbols_per_slot
*
sizeof
(
uint32_t
*
));
AssertFatal
(
prs
[
rsc
][
slot
]
!=
NULL
,
"NR init: positioning reference signal for slot %d - malloc failed
\n
"
,
slot
);
for
(
int
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
prs
[
rsc
][
slot
][
symb
]
=
(
uint32_t
*
)
malloc16
(
NR_MAX_PRS_INIT_LENGTH_DWORD
*
sizeof
(
uint32_t
));
AssertFatal
(
prs
[
rsc
][
slot
][
symb
]
!=
NULL
,
"NR init: positioning reference signal for rsc %d slot %d symbol %d - malloc failed
\n
"
,
rsc
,
slot
,
symb
);
}
}
}
uint8_t
reset
;
uint8_t
slotNum
,
symNum
,
rsc_id
;
for
(
rsc_id
=
0
;
rsc_id
<
gNB
->
prs_vars
.
NumPRSResources
;
rsc_id
++
)
{
Nid
=
gNB
->
prs_vars
.
prs_cfg
[
rsc_id
].
NPRSID
;
// seed value
LOG_I
(
PHY
,
"Initiaized NR-PRS sequence with PRS_ID %3d for resource %d
\n
"
,
Nid
,
rsc_id
);
for
(
slotNum
=
0
;
slotNum
<
fp
->
slots_per_frame
;
slotNum
++
)
{
for
(
symNum
=
0
;
symNum
<
fp
->
symbols_per_slot
;
symNum
++
)
{
reset
=
1
;
// initial x2 for prs as ts138.211
uint32_t
c_init1
,
c_init2
,
c_init3
;
uint32_t
pow22
=
1
<<
22
;
uint32_t
pow10
=
1
<<
10
;
c_init1
=
pow22
*
ceil
(
Nid
/
1024
);
c_init2
=
pow10
*
(
slotNum
+
symNum
+
1
)
*
(
2
*
(
Nid
%
1024
)
+
1
);
c_init3
=
Nid
%
1024
;
x2
=
c_init1
+
c_init2
+
c_init3
;
for
(
uint8_t
n
=
0
;
n
<
NR_MAX_PRS_INIT_LENGTH_DWORD
;
n
++
)
{
gNB
->
nr_gold_prs
[
rsc_id
][
slotNum
][
symNum
][
n
]
=
lte_gold_generic
(
&
x1
,
&
x2
,
reset
);
reset
=
0
;
//printf("%d \n",gNB->nr_gold_prs[slotNum][symNum][n]);
}
}
}
}
}
openair1/PHY/NR_REFSIG/nr_gold_ue.c
View file @
00cb43ba
...
...
@@ -22,43 +22,6 @@
#include "refsig_defs_ue.h"
#include "openair1/PHY/LTE_TRANSPORT/transport_proto.h" // for lte_gold_generic()
void
init_nr_gold_prs
(
PHY_VARS_NR_UE
*
ue
)
{
unsigned
int
x1
=
0
,
x2
=
0
;
uint16_t
Nid
;
NR_DL_FRAME_PARMS
*
fp
=
&
ue
->
frame_parms
;
uint8_t
reset
;
uint8_t
slotNum
,
symNum
,
gnb
,
rsc
;
for
(
gnb
=
0
;
gnb
<
ue
->
prs_active_gNBs
;
gnb
++
)
{
for
(
rsc
=
0
;
rsc
<
ue
->
prs_vars
[
gnb
]
->
NumPRSResources
;
rsc
++
)
{
Nid
=
ue
->
prs_vars
[
gnb
]
->
prs_resource
[
rsc
].
prs_cfg
.
NPRSID
;
// seed value
LOG_I
(
PHY
,
"Initialised NR-PRS sequence with PRS_ID %3d for resource %d
\n
"
,
Nid
,
rsc
);
for
(
slotNum
=
0
;
slotNum
<
fp
->
slots_per_frame
;
slotNum
++
)
{
for
(
symNum
=
0
;
symNum
<
fp
->
symbols_per_slot
;
symNum
++
)
{
reset
=
1
;
// initial x2 for prs as ts138.211
uint32_t
c_init1
,
c_init2
,
c_init3
;
uint32_t
pow22
=
1
<<
22
;
uint32_t
pow10
=
1
<<
10
;
c_init1
=
pow22
*
ceil
(
Nid
/
1024
);
c_init2
=
pow10
*
(
slotNum
+
symNum
+
1
)
*
(
2
*
(
Nid
%
1024
)
+
1
);
c_init3
=
Nid
%
1024
;
x2
=
c_init1
+
c_init2
+
c_init3
;
for
(
uint8_t
n
=
0
;
n
<
NR_MAX_PRS_INIT_LENGTH_DWORD
;
n
++
)
{
ue
->
nr_gold_prs
[
gnb
][
rsc
][
slotNum
][
symNum
][
n
]
=
lte_gold_generic
(
&
x1
,
&
x2
,
reset
);
reset
=
0
;
//printf("%d \n",gNB->nr_gold_prs[slotNum][symNum][n]);
}
}
}
}
// for rsc
}
// for gnb
}
void
sl_init_psbch_dmrs_gold_sequences
(
PHY_VARS_NR_UE
*
UE
)
{
unsigned
int
x1
,
x2
;
...
...
openair1/PHY/NR_REFSIG/nr_refsig.h
View file @
00cb43ba
...
...
@@ -26,14 +26,6 @@
#include "PHY/defs_gNB.h"
#include "openair1/PHY/NR_REFSIG/nr_refsig_common.h"
#include "PHY/LTE_REFSIG/lte_refsig.h"
#include "PHY/sse_intrin.h"
/*
This function generates NR Gold Sequence(ts 138.211) for the PRS.
@param PHY_VARS_gNB* gNB structure provides configuration, frame parameters and the pointers to the 32 bits sequence storage tables
*/
void
nr_init_prs
(
PHY_VARS_gNB
*
gNB
);
int
nr_pusch_dmrs_delta
(
uint8_t
dmrs_config_type
,
unsigned
short
p
);
...
...
openair1/PHY/NR_REFSIG/nr_refsig_common.h
View file @
00cb43ba
...
...
@@ -30,5 +30,6 @@ uint32_t *nr_gold_pdcch(int N_RB_DL, int symbols_per_slot, unsigned short n_idDM
uint32_t
*
nr_gold_pdsch
(
int
N_RB_DL
,
int
symbols_per_slot
,
int
nid
,
int
nscid
,
int
slot
,
int
symbol
);
uint32_t
*
nr_gold_pusch
(
int
N_RB_UL
,
int
symbols_per_slot
,
int
Nid
,
int
nscid
,
int
slot
,
int
symbol
);
uint32_t
*
nr_gold_csi_rs
(
int
N_RB_DL
,
int
symbols_per_slot
,
int
slot
,
int
symb
,
uint32_t
Nid
);
uint32_t
*
nr_gold_prs
(
int
nid
,
int
slot
,
int
symbol
);
#endif
openair1/PHY/NR_REFSIG/refsig.c
View file @
00cb43ba
...
...
@@ -205,3 +205,16 @@ uint32_t *nr_gold_csi_rs(int N_RB_DL, int symbols_per_slot, int slot, int symb,
uint32_t
x2
=
temp_x2
%
(
1U
<<
31
);
return
gold_cache
(
x2
,
csi_dmrs_init_length
);
}
uint32_t
*
nr_gold_prs
(
int
Nid
,
int
slotNum
,
int
symNum
)
{
LOG_D
(
PHY
,
"Initialised NR-PRS sequence for PCI %d
\n
"
,
Nid
);
// initial x2 for prs as ts138.211
uint32_t
pow22
=
1
<<
22
;
uint32_t
pow10
=
1
<<
10
;
uint32_t
c_init1
=
pow22
*
ceil
(
Nid
/
1024
);
uint32_t
c_init2
=
pow10
*
(
slotNum
+
symNum
+
1
)
*
(
2
*
(
Nid
%
1024
)
+
1
);
uint32_t
c_init3
=
Nid
%
1024
;
uint32_t
x2
=
c_init1
+
c_init2
+
c_init3
;
return
gold_cache
(
x2
,
NR_MAX_PRS_INIT_LENGTH_DWORD
);
}
openair1/PHY/NR_REFSIG/refsig_defs_ue.h
View file @
00cb43ba
...
...
@@ -51,7 +51,6 @@ int nr_pdsch_dmrs_rx(const PHY_VARS_NR_UE *ue,
unsigned
short
nb_pdsch_rb
,
uint8_t
config_type
);
void
init_nr_gold_prs
(
PHY_VARS_NR_UE
*
ue
);
void
sl_generate_pss
(
SL_NR_UE_INIT_PARAMS_t
*
sl_init_params
,
uint8_t
n_sl_id2
,
uint16_t
scaling
);
void
sl_generate_pss_ifft_samples
(
sl_nr_ue_phy_params_t
*
sl_ue_params
,
SL_NR_UE_INIT_PARAMS_t
*
sl_init_params
);
void
sl_generate_sss
(
SL_NR_UE_INIT_PARAMS_t
*
sl_init_params
,
uint16_t
slss_id
,
uint16_t
scaling
);
...
...
openair1/PHY/NR_TRANSPORT/nr_prs.c
View file @
00cb43ba
...
...
@@ -3,18 +3,18 @@
#include "PHY/LTE_REFSIG/lte_refsig.h"
#include "PHY/NR_REFSIG/nr_refsig.h"
#include "PHY/sse_intrin.h"
#include "openair1/PHY/NR_REFSIG/refsig_defs_ue.h"
//#define DEBUG_PRS_MOD
//#define DEBUG_PRS_MAP
extern
short
nr_qpsk_mod_table
[
8
];
int
nr_generate_prs
(
uint32_t
**
nr_gold_prs
,
c16_t
*
txdataF
,
int16_t
amp
,
prs_config_t
*
prs_cfg
,
nfapi_nr_config_request_scf_t
*
config
,
NR_DL_FRAME_PARMS
*
frame_parms
)
int
nr_generate_prs
(
int
slot
,
c16_t
*
txdataF
,
int16_t
amp
,
prs_config_t
*
prs_cfg
,
nfapi_nr_config_request_scf_t
*
config
,
NR_DL_FRAME_PARMS
*
frame_parms
)
{
int
k_prime
=
0
,
k
=
0
,
idx
;
...
...
@@ -42,8 +42,9 @@ int nr_generate_prs(uint32_t **nr_gold_prs,
k
=
(
prs_cfg
->
REOffset
+
k_prime
)
%
prs_cfg
->
CombSize
+
prs_cfg
->
RBOffset
*
12
+
frame_parms
->
first_carrier_offset
;
// QPSK modulation
uint32_t
*
gold
=
nr_gold_prs
(
prs_cfg
->
NPRSID
,
slot
,
l
);
for
(
int
m
=
0
;
m
<
(
12
/
prs_cfg
->
CombSize
)
*
prs_cfg
->
NumRB
;
m
++
)
{
idx
=
(((
nr_gold_prs
[
l
][(
m
<<
1
)
>>
5
])
>>
((
m
<<
1
)
&
0x1f
))
&
3
);
idx
=
(((
gold
[(
m
<<
1
)
>>
5
])
>>
((
m
<<
1
)
&
0x1f
))
&
3
);
mod_prs
[
m
<<
1
]
=
nr_qpsk_mod_table
[
idx
<<
1
];
mod_prs
[(
m
<<
1
)
+
1
]
=
nr_qpsk_mod_table
[(
idx
<<
1
)
+
1
];
...
...
openair1/PHY/NR_TRANSPORT/nr_scrambling.c
View file @
00cb43ba
...
...
@@ -21,6 +21,7 @@
#include "nr_transport_common_proto.h"
#include "PHY/NR_REFSIG/nr_refsig.h"
#include "openair1/PHY/LTE_TRANSPORT/transport_proto.h" // for lte_gold_generic()
#include "common/utils/LOG/vcd_signal_dumper.h"
#define DEBUG_SCRAMBLING(a)
//#define DEBUG_SCRAMBLING(a) a
...
...
openair1/PHY/NR_TRANSPORT/nr_transport_proto.h
View file @
00cb43ba
...
...
@@ -40,7 +40,7 @@
NR_gNB_PHY_STATS_t
*
get_phy_stats
(
PHY_VARS_gNB
*
gNB
,
uint16_t
rnti
);
int
nr_generate_prs
(
uint32_t
**
nr_gold_prs
,
int
nr_generate_prs
(
int
slot
,
c16_t
*
txdataF
,
int16_t
amp
,
prs_config_t
*
prs_cfg
,
...
...
openair1/PHY/NR_TRANSPORT/nr_uci_tools_common.c
View file @
00cb43ba
...
...
@@ -31,6 +31,8 @@
*/
#include "nr_dci.h"
#include "openair1/PHY/LTE_TRANSPORT/transport_proto.h" // for lte_gold_generic()
void
nr_group_sequence_hopping
(
pucch_GroupHopping_t
PUCCH_GroupHopping
,
uint32_t
n_id
,
...
...
openair1/PHY/NR_TRANSPORT/pucch_rx.c
View file @
00cb43ba
...
...
@@ -43,6 +43,7 @@
#include "PHY/sse_intrin.h"
#include "PHY/NR_UE_TRANSPORT/pucch_nr.h"
#include <openair1/PHY/CODING/nrSmallBlock/nr_small_block_defs.h>
#include "openair1/PHY/LTE_TRANSPORT/transport_proto.h" // for lte_gold_generic()
#include "PHY/NR_TRANSPORT/nr_transport_common_proto.h"
#include "PHY/NR_TRANSPORT/nr_transport_proto.h"
#include "PHY/NR_REFSIG/nr_refsig.h"
...
...
openair1/PHY/NR_UE_ESTIMATION/nr_dl_channel_estimation.c
View file @
00cb43ba
...
...
@@ -89,9 +89,9 @@ int nr_prs_channel_estimation(uint8_t gNB_id,
memset
(
ch_tmp_buf
,
0
,
sizeof
(
ch_tmp_buf
));
memset
(
chF_interpol
,
0
,
sizeof
(
chF_interpol
));
memset
(
chT_interpol
,
0
,
sizeof
(
chF_interpol
));
int
slot_prs
=
(
proc
->
nr_slot_rx
-
rep_num
*
prs_cfg
->
PRSResourceTimeGap
+
frame_params
->
slots_per_frame
)
%
frame_params
->
slots_per_frame
;
uint32_t
**
nr_gold_prs
=
ue
->
nr_gold_prs
[
gNB_id
][
rsc_id
][
slot_prs
]
;
int
slot_prs
=
(
proc
->
nr_slot_rx
-
rep_num
*
prs_cfg
->
PRSResourceTimeGap
+
frame_params
->
slots_per_frame
)
%
frame_params
->
slots_per_frame
;
int16_t
*
rxF
,
*
pil
,
mod_prs
[
NR_MAX_PRS_LENGTH
<<
1
];
const
int16_t
*
fl
,
*
fm
,
*
fmm
,
*
fml
,
*
fmr
,
*
fr
;
...
...
@@ -113,6 +113,7 @@ int nr_prs_channel_estimation(uint8_t gNB_id,
int16_t
k_prime_table
[
K_PRIME_TABLE_ROW_SIZE
][
K_PRIME_TABLE_COL_SIZE
]
=
PRS_K_PRIME_TABLE
;
for
(
int
l
=
prs_cfg
->
SymbolStart
;
l
<
prs_cfg
->
SymbolStart
+
prs_cfg
->
NumPRSSymbols
;
l
++
)
{
uint32_t
*
gold_prs
=
nr_gold_prs
(
ue
->
prs_vars
[
gNB_id
]
->
prs_resource
[
rsc_id
].
prs_cfg
.
NPRSID
,
slot_prs
,
l
);
int
symInd
=
l
-
prs_cfg
->
SymbolStart
;
if
(
prs_cfg
->
CombSize
==
2
)
{
k_prime
=
k_prime_table
[
0
][
symInd
];
...
...
@@ -135,7 +136,7 @@ int nr_prs_channel_estimation(uint8_t gNB_id,
AssertFatal
(
num_pilots
>
0
,
"num_pilots needs to be gt 0 or mod_prs[0] UB"
);
for
(
int
m
=
0
;
m
<
num_pilots
;
m
++
)
{
idx
=
(((
nr_gold_prs
[
l
][(
m
<<
1
)
>>
5
])
>>
((
m
<<
1
)
&
0x1f
))
&
3
);
idx
=
(((
gold_prs
[(
m
<<
1
)
>>
5
])
>>
((
m
<<
1
)
&
0x1f
))
&
3
);
mod_prs
[
m
<<
1
]
=
nr_qpsk_mod_table
[
idx
<<
1
];
mod_prs
[(
m
<<
1
)
+
1
]
=
nr_qpsk_mod_table
[(
idx
<<
1
)
+
1
];
}
...
...
openair1/PHY/defs_gNB.h
View file @
00cb43ba
...
...
@@ -609,9 +609,6 @@ typedef struct PHY_VARS_gNB_s {
/// PBCH interleaver
uint8_t
nr_pbch_interleaver
[
NR_POLAR_PBCH_PAYLOAD_BITS
];
/// PRS sequence
uint32_t
****
nr_gold_prs
;
/// PRACH root sequence
c16_t
X_u
[
64
][
839
];
...
...
openair1/PHY/defs_nr_UE.h
View file @
00cb43ba
...
...
@@ -408,9 +408,6 @@ typedef struct PHY_VARS_NR_UE_s {
#endif
// Scrambling IDs used in PUSCH DMRS
// PRS sequence per gNB, per resource
uint32_t
*****
nr_gold_prs
;
c16_t
X_u
[
64
][
839
];
// flag to activate PRB based averaging of channel estimates
...
...
openair1/SCHED_NR/phy_procedures_nr_gNB.c
View file @
00cb43ba
...
...
@@ -179,7 +179,7 @@ void phy_procedures_gNB_TX(processingData_L1tx_t *msgTx,
{
slot_prs
=
(
slot
-
i
*
prs_config
->
PRSResourceTimeGap
+
fp
->
slots_per_frame
)
%
fp
->
slots_per_frame
;
LOG_D
(
PHY
,
"gNB_TX: frame %d, slot %d, slot_prs %d, PRS Resource ID %d
\n
"
,
frame
,
slot
,
slot_prs
,
rsc_id
);
nr_generate_prs
(
gNB
->
nr_gold_prs
[
rsc_id
][
slot_prs
],
&
gNB
->
common_vars
.
txdataF
[
0
][
txdataF_offset
],
AMP
,
prs_config
,
cfg
,
fp
);
nr_generate_prs
(
slot_prs
,
&
gNB
->
common_vars
.
txdataF
[
0
][
txdataF_offset
],
AMP
,
prs_config
,
cfg
,
fp
);
}
}
}
...
...
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