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
Michael Black
OpenXG-RAN
Commits
d5893eea
Commit
d5893eea
authored
Nov 07, 2018
by
Guy De Souza
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Interleaving init fix
parent
b6de2aea
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
openair1/PHY/NR_TRANSPORT/nr_pbch.c
openair1/PHY/NR_TRANSPORT/nr_pbch.c
+5
-5
openair1/PHY/NR_TRANSPORT/nr_transport.h
openair1/PHY/NR_TRANSPORT/nr_transport.h
+1
-1
No files found.
openair1/PHY/NR_TRANSPORT/nr_pbch.c
View file @
d5893eea
...
@@ -190,7 +190,7 @@ void nr_pbch_scrambling(NR_gNB_PBCH *pbch,
...
@@ -190,7 +190,7 @@ void nr_pbch_scrambling(NR_gNB_PBCH *pbch,
}
}
}
}
uint8_t
nr_
pbch_init
_interleaver
(
uint8_t
*
interleaver
)
{
uint8_t
nr_
init_pbch
_interleaver
(
uint8_t
*
interleaver
)
{
uint8_t
j_sfn
=
0
,
j_hrf
=
10
,
j_ssb
=
11
,
j_other
=
14
;
uint8_t
j_sfn
=
0
,
j_hrf
=
10
,
j_ssb
=
11
,
j_other
=
14
;
memset
((
void
*
)
interleaver
,
0
,
NR_POLAR_PBCH_PAYLOAD_BITS
);
memset
((
void
*
)
interleaver
,
0
,
NR_POLAR_PBCH_PAYLOAD_BITS
);
...
@@ -272,15 +272,15 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
...
@@ -272,15 +272,15 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
for
(
int
i
=
0
;
i
<
NR_POLAR_PBCH_PAYLOAD_BITS
;
i
++
)
{
for
(
int
i
=
0
;
i
<
NR_POLAR_PBCH_PAYLOAD_BITS
;
i
++
)
{
pbch
->
pbch_a_interleaved
|=
((
in
>>
i
)
&
1
)
<<
(
*
(
interleaver
+
i
));
pbch
->
pbch_a_interleaved
|=
((
in
>>
i
)
&
1
)
<<
(
*
(
interleaver
+
i
));
#ifdef DEBUG_PBCH_ENCODING
//
#ifdef DEBUG_PBCH_ENCODING
printf
(
"i %d in 0x%08x out 0x%08x ilv %d (in>>i)&1) %d
\n
"
,
i
,
in
,
pbch
->
pbch_a_interleaved
,
*
(
interleaver
+
i
),
(
in
>>
i
)
&
1
);
printf
(
"i %d in 0x%08x out 0x%08x ilv %d (in>>i)&1) %d
\n
"
,
i
,
in
,
pbch
->
pbch_a_interleaved
,
*
(
interleaver
+
i
),
(
in
>>
i
)
&
1
);
#endif
//
#endif
}
}
#ifdef DEBUG_PBCH_ENCODING
//
#ifdef DEBUG_PBCH_ENCODING
printf
(
"Interleaving:
\n
"
);
printf
(
"Interleaving:
\n
"
);
printf
(
"pbch_a_interleaved: 0x%08x
\n
"
,
pbch
->
pbch_a_interleaved
);
printf
(
"pbch_a_interleaved: 0x%08x
\n
"
,
pbch
->
pbch_a_interleaved
);
#endif
//
#endif
// Scrambling
// Scrambling
M
=
(
Lmax
==
64
)
?
(
NR_POLAR_PBCH_PAYLOAD_BITS
-
6
)
:
(
NR_POLAR_PBCH_PAYLOAD_BITS
-
3
);
M
=
(
Lmax
==
64
)
?
(
NR_POLAR_PBCH_PAYLOAD_BITS
-
6
)
:
(
NR_POLAR_PBCH_PAYLOAD_BITS
-
3
);
...
...
openair1/PHY/NR_TRANSPORT/nr_transport.h
View file @
d5893eea
...
@@ -103,6 +103,6 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
...
@@ -103,6 +103,6 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
@param bit index i of the input payload
@param bit index i of the input payload
@returns the bit index of the output
@returns the bit index of the output
*/
*/
uint8_t
nr_
pbch_payload_interleaver
(
uint8_t
i
);
uint8_t
nr_
init_pbch_interleaver
(
uint8_t
*
interleaver
);
#endif
/*__NR_TRANSPORT__H__*/
#endif
/*__NR_TRANSPORT__H__*/
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