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
ffc5faf3
Commit
ffc5faf3
authored
Oct 10, 2018
by
Raymond Knopp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
removal of warnings
parent
9d9aadd4
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
23 additions
and
12 deletions
+23
-12
openair1/PHY/CODING/nrPolar_init.c
openair1/PHY/CODING/nrPolar_init.c
+3
-3
openair1/PHY/CODING/nrPolar_tools/nr_polar_decoding_tools.c
openair1/PHY/CODING/nrPolar_tools/nr_polar_decoding_tools.c
+1
-5
openair1/PHY/CODING/nrPolar_tools/nr_polar_defs.h
openair1/PHY/CODING/nrPolar_tools/nr_polar_defs.h
+15
-0
openair1/PHY/NR_TRANSPORT/nr_pbch.c
openair1/PHY/NR_TRANSPORT/nr_pbch.c
+4
-4
No files found.
openair1/PHY/CODING/nrPolar_init.c
View file @
ffc5faf3
...
@@ -27,9 +27,9 @@ void nr_polar_init(t_nrPolar_params* polarParams, int messageType) {
...
@@ -27,9 +27,9 @@ void nr_polar_init(t_nrPolar_params* polarParams, int messageType) {
uint32_t
poly6
=
0x84000000
;
// 1000100000... -> D^6+D^5+1
uint32_t
poly6
=
0x84000000
;
// 1000100000... -> D^6+D^5+1
uint32_t
poly11
=
0x63200000
;
//11000100001000... -> D^11+D^10+D^9+D^5+1
uint32_t
poly11
=
0x63200000
;
//11000100001000... -> D^11+D^10+D^9+D^5+1
uint32_t
poly16
=
0x81080000
;
//100000010000100... - > D^16+D^12+D^5+1
//
uint32_t poly16 = 0x81080000; //100000010000100... - > D^16+D^12+D^5+1
uint32_t
poly24a
=
0x864cfb00
;
//100001100100110011111011 -> D^24+D^23+D^18+D^17+D^14+D^11+D^10+D^7+D^6+D^5+D^4+D^3+D+1
//
uint32_t poly24a = 0x864cfb00; //100001100100110011111011 -> D^24+D^23+D^18+D^17+D^14+D^11+D^10+D^7+D^6+D^5+D^4+D^3+D+1
uint32_t
poly24b
=
0x80006300
;
//100000000000000001100011 -> D^24+D^23+D^6+D^5+D+1
//
uint32_t poly24b = 0x80006300; //100000000000000001100011 -> D^24+D^23+D^6+D^5+D+1
uint32_t
poly24c
=
0xB2B11700
;
//101100101011000100010111 -> D^24...
uint32_t
poly24c
=
0xB2B11700
;
//101100101011000100010111 -> D^24...
if
(
messageType
==
0
)
{
//DCI
if
(
messageType
==
0
)
{
//DCI
...
...
openair1/PHY/CODING/nrPolar_tools/nr_polar_decoding_tools.c
View file @
ffc5faf3
...
@@ -50,7 +50,6 @@ int16_t llrtab[256][256];
...
@@ -50,7 +50,6 @@ int16_t llrtab[256][256];
void
nr_polar_llrtableinit
()
{
void
nr_polar_llrtableinit
()
{
int16_t
absA
,
absB
;
int16_t
absA
,
absB
;
int16_t
maska
,
maskb
;
int16_t
minabs
;
int16_t
minabs
;
for
(
int
a
=-
128
;
a
<
128
;
a
++
)
{
for
(
int
a
=-
128
;
a
<
128
;
a
++
)
{
...
@@ -229,7 +228,6 @@ void updatePathMetric2(decoder_list_t **dlist, uint8_t listSize, uint16_t row, u
...
@@ -229,7 +228,6 @@ void updatePathMetric2(decoder_list_t **dlist, uint8_t listSize, uint16_t row, u
void
updatePathMetric2_int8
(
decoder_list_int8_t
**
dlist
,
uint8_t
listSize
,
uint16_t
row
,
int
generate_optim_code
,
FILE
*
fd
)
{
void
updatePathMetric2_int8
(
decoder_list_int8_t
**
dlist
,
uint8_t
listSize
,
uint16_t
row
,
int
generate_optim_code
,
FILE
*
fd
)
{
int
i
;
...
@@ -303,7 +301,7 @@ decoder_node_t *new_decoder_node(int first_leaf_index,int level) {
...
@@ -303,7 +301,7 @@ decoder_node_t *new_decoder_node(int first_leaf_index,int level) {
node
->
right
=
(
decoder_node_t
*
)
NULL
;
node
->
right
=
(
decoder_node_t
*
)
NULL
;
node
->
all_frozen
=
0
;
node
->
all_frozen
=
0
;
node
->
alpha
=
(
int16_t
*
)
malloc16
(
node
->
Nv
*
sizeof
(
int16_t
));
node
->
alpha
=
(
int16_t
*
)
malloc16
(
node
->
Nv
*
sizeof
(
int16_t
));
node
->
beta
=
(
int
8
_t
*
)
malloc16
(
node
->
Nv
*
sizeof
(
int16_t
));
node
->
beta
=
(
int
16
_t
*
)
malloc16
(
node
->
Nv
*
sizeof
(
int16_t
));
memset
((
void
*
)
node
->
beta
,
-
1
,
node
->
Nv
*
sizeof
(
int16_t
));
memset
((
void
*
)
node
->
beta
,
-
1
,
node
->
Nv
*
sizeof
(
int16_t
));
...
@@ -434,9 +432,7 @@ void applyGtoright(t_nrPolar_params *pp,decoder_node_t *node) {
...
@@ -434,9 +432,7 @@ void applyGtoright(t_nrPolar_params *pp,decoder_node_t *node) {
int16_t
*
alpha_r
=
node
->
right
->
alpha
;
int16_t
*
alpha_r
=
node
->
right
->
alpha
;
int16_t
*
betal
=
node
->
left
->
beta
;
int16_t
*
betal
=
node
->
left
->
beta
;
int16_t
*
betar
=
node
->
right
->
beta
;
int16_t
*
betar
=
node
->
right
->
beta
;
int8_t
frozen_mask
=-
1
;
if
(
node
->
Nv
==
2
)
frozen_mask
=-
pp
->
information_bit_pattern
[
node
->
first_leaf_index
+
1
];
#ifdef DEBUG_NEW_IMPL
#ifdef DEBUG_NEW_IMPL
printf
(
"applyGtoright %d, Nv %d (level %d), (leaf %d, AF %d)
\n
"
,
node
->
first_leaf_index
,
node
->
Nv
,
node
->
level
,
node
->
right
->
leaf
,
node
->
right
->
all_frozen
);
printf
(
"applyGtoright %d, Nv %d (level %d), (leaf %d, AF %d)
\n
"
,
node
->
first_leaf_index
,
node
->
Nv
,
node
->
level
,
node
->
right
->
leaf
,
node
->
right
->
all_frozen
);
#endif
#endif
...
...
openair1/PHY/CODING/nrPolar_tools/nr_polar_defs.h
View file @
ffc5faf3
...
@@ -125,6 +125,8 @@ void polar_encoder(uint8_t *input, uint8_t *output, t_nrPolar_params* polarParam
...
@@ -125,6 +125,8 @@ void polar_encoder(uint8_t *input, uint8_t *output, t_nrPolar_params* polarParam
void
nr_polar_kernal_operation
(
uint8_t
*
u
,
uint8_t
*
d
,
uint16_t
N
);
void
nr_polar_kernal_operation
(
uint8_t
*
u
,
uint8_t
*
d
,
uint16_t
N
);
void
generic_polar_decoder
(
t_nrPolar_params
*
,
decoder_node_t
*
);
int8_t
polar_decoder
(
double
*
input
,
uint8_t
*
output
,
t_nrPolar_params
*
polarParams
,
int8_t
polar_decoder
(
double
*
input
,
uint8_t
*
output
,
t_nrPolar_params
*
polarParams
,
uint8_t
listSize
,
double
*
aPrioriPayload
,
uint8_t
pathMetricAppr
,
uint8_t
listSize
,
double
*
aPrioriPayload
,
uint8_t
pathMetricAppr
,
time_stats_t
*
init
,
time_stats_t
*
init
,
...
@@ -150,6 +152,19 @@ int8_t polar_decoder_int8(int16_t *input,
...
@@ -150,6 +152,19 @@ int8_t polar_decoder_int8(int16_t *input,
time_stats_t
*
update_LLR
,
time_stats_t
*
update_LLR
,
int
generate_optim_code
);
int
generate_optim_code
);
int8_t
polar_decoder_int8_new
(
int16_t
*
input
,
uint8_t
*
output
,
t_nrPolar_params
*
polarParams
,
uint8_t
listSize
,
time_stats_t
*
init
,
time_stats_t
*
polar_rate_matching
,
time_stats_t
*
decoding
,
time_stats_t
*
bit_extraction
,
time_stats_t
*
deinterleaving
,
time_stats_t
*
sorting
,
time_stats_t
*
path_metric
,
time_stats_t
*
update_LLR
,
int
generate_optim_code
);
void
nr_polar_llrtableinit
(
void
);
void
nr_polar_llrtableinit
(
void
);
...
...
openair1/PHY/NR_TRANSPORT/nr_pbch.c
View file @
ffc5faf3
...
@@ -219,7 +219,7 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
...
@@ -219,7 +219,7 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
uint8_t
nushift
;
uint8_t
nushift
;
uint8_t
*
xbyte
=
pbch
->
pbch_a
;
uint8_t
*
xbyte
=
pbch
->
pbch_a
;
memset
((
void
*
)
xbyte
,
0
,
1
);
memset
((
void
*
)
xbyte
,
0
,
1
);
uint8_t
pbch_a_b
[
32
];
//
uint8_t pbch_a_b[32];
LOG_I
(
PHY
,
"PBCH generation started
\n
"
);
LOG_I
(
PHY
,
"PBCH generation started
\n
"
);
...
@@ -282,10 +282,10 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
...
@@ -282,10 +282,10 @@ int nr_generate_pbch(NR_gNB_PBCH *pbch,
printf
(
"pbch_a_prime[%d]: 0x%02x
\n
"
,
i
,
pbch
->
pbch_a_prime
[
i
]);
printf
(
"pbch_a_prime[%d]: 0x%02x
\n
"
,
i
,
pbch
->
pbch_a_prime
[
i
]);
#endif
#endif
for
(
int
m
=
0
;
m
<
32
;
m
++
){
//
for (int m=0;m<32;m++){
pbch_a_b
[
m
]
=
((
pbch
->
pbch_a_prime
[
m
/
8
]
>>
(
m
&
7
))
&
01
);
//
pbch_a_b[m] = ((pbch->pbch_a_prime[m/8]>>(m&7))&01);
//printf("pbch_a_b[%d] %d\n", m, pbch_a_b[m] );
//printf("pbch_a_b[%d] %d\n", m, pbch_a_b[m] );
}
//
}
/// CRC, coding and rate matching
/// CRC, coding and rate matching
polar_encoder
(
pbch
->
pbch_a_prime
,
pbch
->
pbch_e
,
&
frame_parms
->
pbch_polar_params
);
polar_encoder
(
pbch
->
pbch_a_prime
,
pbch
->
pbch_e
,
&
frame_parms
->
pbch_polar_params
);
...
...
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