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
canghaiwuhen
OpenXG-RAN
Commits
76f360c1
Commit
76f360c1
authored
Sep 16, 2019
by
Francesco Mani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
generation of csi-rs sequence
parent
b2e54e09
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
51 additions
and
0 deletions
+51
-0
openair1/PHY/INIT/nr_init.c
openair1/PHY/INIT/nr_init.c
+17
-0
openair1/PHY/NR_REFSIG/nr_gold.c
openair1/PHY/NR_REFSIG/nr_gold.c
+27
-0
openair1/PHY/NR_REFSIG/nr_refsig.h
openair1/PHY/NR_REFSIG/nr_refsig.h
+1
-0
openair1/PHY/defs_gNB.h
openair1/PHY/defs_gNB.h
+3
-0
openair1/PHY/defs_nr_common.h
openair1/PHY/defs_nr_common.h
+3
-0
No files found.
openair1/PHY/INIT/nr_init.c
View file @
76f360c1
...
@@ -179,6 +179,23 @@ int phy_init_nr_gNB(PHY_VARS_gNB *gNB,
...
@@ -179,6 +179,23 @@ int phy_init_nr_gNB(PHY_VARS_gNB *gNB,
LOG_D
(
PHY
,
"Initializing PUSCH DMRS Gold sequence with (%x,%x)
\n
"
,
Nid_pusch
[
0
],
Nid_pusch
[
1
]);
LOG_D
(
PHY
,
"Initializing PUSCH DMRS Gold sequence with (%x,%x)
\n
"
,
Nid_pusch
[
0
],
Nid_pusch
[
1
]);
nr_gold_pusch
(
gNB
,
&
Nid_pusch
[
0
]);
nr_gold_pusch
(
gNB
,
&
Nid_pusch
[
0
]);
//CSI RS init
gNB
->
nr_gold_csi_rs
=
(
uint32_t
***
)
malloc16
(
fp
->
slots_per_frame
*
sizeof
(
uint32_t
**
));
uint32_t
***
csi_rs
=
gNB
->
nr_gold_csi_rs
;
AssertFatal
(
csi_rs
!=
NULL
,
"NR init: csi reference signal malloc failed
\n
"
);
for
(
int
slot
=
0
;
slot
<
fp
->
slots_per_frame
;
slot
++
)
{
csi_rs
[
slot
]
=
(
uint32_t
**
)
malloc16
(
fp
->
symbols_per_slot
*
sizeof
(
uint32_t
*
));
AssertFatal
(
csi_rs
[
slot
]
!=
NULL
,
"NR init: csi reference signal for slot %d - malloc failed
\n
"
,
slot
);
for
(
int
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
csi_rs
[
slot
][
symb
]
=
(
uint32_t
*
)
malloc16
(
NR_MAX_CSI_RS_INIT_LENGTH_DWORD
*
sizeof
(
uint32_t
));
AssertFatal
(
csi_rs
[
slot
][
symb
]
!=
NULL
,
"NR init: csi reference signal for slot %d symbol %d - malloc failed
\n
"
,
slot
,
symb
);
}
}
nr_init_csi_rs
(
gNB
,
0
);
// TODO scramblingID currently hardcoded to 0, to be taken from higher layer parameter scramblingID when implemented
/// Transport init necessary for NR synchro
/// Transport init necessary for NR synchro
init_nr_transport
(
gNB
);
init_nr_transport
(
gNB
);
...
...
openair1/PHY/NR_REFSIG/nr_gold.c
View file @
76f360c1
...
@@ -65,7 +65,11 @@ void nr_init_pdcch_dmrs(PHY_VARS_gNB* gNB, uint32_t Nid)
...
@@ -65,7 +65,11 @@ void nr_init_pdcch_dmrs(PHY_VARS_gNB* gNB, uint32_t Nid)
for
(
uint8_t
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
for
(
uint8_t
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
reset
=
1
;
reset
=
1
;
<<<<<<<
HEAD
x2
=
((
1
<<
17
)
*
(
14
*
slot
+
symb
+
1
)
*
((
Nid
<<
1
)
+
1
))
+
(
Nid
<<
1
);
x2
=
((
1
<<
17
)
*
(
14
*
slot
+
symb
+
1
)
*
((
Nid
<<
1
)
+
1
))
+
(
Nid
<<
1
);
=======
x2
=
((
1
<<
17
)
*
(
fp
->
symbols_per_slot
*
slot
+
symb
+
1
)
*
((
Nid
<<
1
)
+
1
)
+
(
Nid
<<
1
));
>>>>>>>
3752
a5f0a
...
generation
of
csi
-
rs
sequence
for
(
uint32_t
n
=
0
;
n
<
NR_MAX_PDCCH_DMRS_INIT_LENGTH_DWORD
;
n
++
)
{
for
(
uint32_t
n
=
0
;
n
<
NR_MAX_PDCCH_DMRS_INIT_LENGTH_DWORD
;
n
++
)
{
pdcch_dmrs
[
slot
][
symb
][
n
]
=
lte_gold_generic
(
&
x1
,
&
x2
,
reset
);
pdcch_dmrs
[
slot
][
symb
][
n
]
=
lte_gold_generic
(
&
x1
,
&
x2
,
reset
);
...
@@ -130,3 +134,26 @@ void nr_gold_pusch(PHY_VARS_gNB* gNB, uint32_t *Nid) {
...
@@ -130,3 +134,26 @@ void nr_gold_pusch(PHY_VARS_gNB* gNB, uint32_t *Nid) {
}
}
}
}
}
}
void
nr_init_csi_rs
(
PHY_VARS_gNB
*
gNB
,
uint32_t
Nid
)
{
NR_DL_FRAME_PARMS
*
fp
=
&
gNB
->
frame_parms
;
uint32_t
***
csi_rs
=
gNB
->
nr_gold_csi_rs
;
uint32_t
x1
,
x2
;
uint8_t
reset
;
for
(
uint8_t
slot
=
0
;
slot
<
fp
->
slots_per_frame
;
slot
++
)
{
for
(
uint8_t
symb
=
0
;
symb
<
fp
->
symbols_per_slot
;
symb
++
)
{
reset
=
1
;
x2
=
((
1
<<
10
)
*
(
fp
->
symbols_per_slot
*
slot
+
symb
+
1
)
*
((
Nid
<<
1
)
+
1
)
+
(
Nid
));
for
(
uint32_t
n
=
0
;
n
<
NR_MAX_PDCCH_DMRS_INIT_LENGTH_DWORD
;
n
++
)
{
csi_rs
[
slot
][
symb
][
n
]
=
lte_gold_generic
(
&
x1
,
&
x2
,
reset
);
reset
=
0
;
}
}
}
}
openair1/PHY/NR_REFSIG/nr_refsig.h
View file @
76f360c1
...
@@ -38,6 +38,7 @@ void nr_init_pbch_dmrs(PHY_VARS_gNB* gNB);
...
@@ -38,6 +38,7 @@ void nr_init_pbch_dmrs(PHY_VARS_gNB* gNB);
*/
*/
void
nr_init_pdcch_dmrs
(
PHY_VARS_gNB
*
gNB
,
uint32_t
Nid
);
void
nr_init_pdcch_dmrs
(
PHY_VARS_gNB
*
gNB
,
uint32_t
Nid
);
void
nr_init_pdsch_dmrs
(
PHY_VARS_gNB
*
gNB
,
uint32_t
Nid
);
void
nr_init_pdsch_dmrs
(
PHY_VARS_gNB
*
gNB
,
uint32_t
Nid
);
void
nr_init_csi_rs
(
PHY_VARS_gNB
*
gNB
,
uint32_t
Nid
);
void
nr_gold_pusch
(
PHY_VARS_gNB
*
gNB
,
uint32_t
*
Nid
);
void
nr_gold_pusch
(
PHY_VARS_gNB
*
gNB
,
uint32_t
*
Nid
);
...
...
openair1/PHY/defs_gNB.h
View file @
76f360c1
...
@@ -719,6 +719,9 @@ typedef struct PHY_VARS_gNB_s {
...
@@ -719,6 +719,9 @@ typedef struct PHY_VARS_gNB_s {
uint32_t
rb_mask_ul
[
9
];
uint32_t
rb_mask_ul
[
9
];
int
ulmask_symb
;
int
ulmask_symb
;
/// CSI RS sequence
uint32_t
***
nr_gold_csi_rs
;
/// Indicator set to 0 after first SR
/// Indicator set to 0 after first SR
uint8_t
first_sr
[
NUMBER_OF_NR_SR_MAX
];
uint8_t
first_sr
[
NUMBER_OF_NR_SR_MAX
];
...
...
openair1/PHY/defs_nr_common.h
View file @
76f360c1
...
@@ -82,6 +82,9 @@
...
@@ -82,6 +82,9 @@
#define NR_MAX_PDSCH_DMRS_LENGTH 3300 //275*6(k)*2(QPSK real+imag)
#define NR_MAX_PDSCH_DMRS_LENGTH 3300 //275*6(k)*2(QPSK real+imag)
#define NR_MAX_PDSCH_DMRS_INIT_LENGTH_DWORD 104 // ceil(NR_MAX_PDSCH_DMRS_LENGTH/32)
#define NR_MAX_PDSCH_DMRS_INIT_LENGTH_DWORD 104 // ceil(NR_MAX_PDSCH_DMRS_LENGTH/32)
#define NR_MAX_CSI_RS_LENGTH 5500 //275*10(max allocation per RB)*2(QPSK)
#define NR_MAX_CSI_RS_INIT_LENGTH_DWORD 172 // ceil(NR_MAX_CSI_RS_LENGTH/32)
#define NR_MAX_PUSCH_DMRS_LENGTH NR_MAX_PDSCH_DMRS_LENGTH
#define NR_MAX_PUSCH_DMRS_LENGTH NR_MAX_PDSCH_DMRS_LENGTH
#define NR_MAX_PUSCH_DMRS_INIT_LENGTH_DWORD NR_MAX_PDSCH_DMRS_INIT_LENGTH_DWORD
#define NR_MAX_PUSCH_DMRS_INIT_LENGTH_DWORD NR_MAX_PDSCH_DMRS_INIT_LENGTH_DWORD
...
...
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