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
zzha zzha
OpenXG-RAN
Commits
f68d124d
Commit
f68d124d
authored
Jul 04, 2018
by
hongzhi wang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ue changing pbch dmrs modulation
parent
eba95e3f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
11 deletions
+16
-11
openair1/PHY/NR_REFSIG/nr_dmrs_rx.c
openair1/PHY/NR_REFSIG/nr_dmrs_rx.c
+12
-7
openair1/PHY/NR_REFSIG/nr_mod_table.h
openair1/PHY/NR_REFSIG/nr_mod_table.h
+1
-1
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
+3
-3
No files found.
openair1/PHY/NR_REFSIG/nr_dmrs_rx.c
View file @
f68d124d
...
...
@@ -41,6 +41,7 @@
#include "refsig_defs_ue.h"
#include "PHY/defs_nr_UE.h"
#include "nr_mod_table.h"
#include "log.h"
/*Table 7.4.1.1.2-1/2 from 38.211 */
...
...
@@ -50,7 +51,7 @@ int wf2[12][2] = {{1,1},{1,-1},{1,1},{1,-1},{1,1},{1,-1},{1,1},{1,1},{1,1},{1,-1
int
wt2
[
12
][
2
]
=
{{
1
,
1
},{
1
,
1
},{
1
,
1
},{
1
,
1
},{
1
,
1
},{
1
,
1
},{
1
,
-
1
},{
1
,
-
1
},{
1
,
-
1
},{
1
,
-
1
},{
1
,
-
1
},{
1
,
-
1
}};
//short nr_mod_table[14] = {0,0,-23170,-23170,23170,23170,-23170,-23170,-23170,23170,23170,-23170,23170,23170};
short
nr_
mod_table
[
14
]
=
{
0
,
0
,
23170
,
-
23170
,
-
23170
,
23170
,
23170
,
-
23170
,
23170
,
23170
,
-
23170
,
-
23170
,
-
23170
,
23170
};
short
nr_
rx_mod_table
[
NR_MOD_TABLE_SIZE_SHORT
]
=
{
0
,
0
,
23170
,
-
23170
,
-
23170
,
23170
,
23170
,
-
23170
,
23170
,
23170
,
-
23170
,
-
23170
,
-
23170
,
23170
};
//short nr_mod_table[14] = {0,0,23170,23170,-23170,-23170,23170,23170,23170,-23170,-23170,23170,-23170,-23170};
//extern short nr_mod_table[NR_MOD_TABLE_SIZE_SHORT];
...
...
@@ -143,16 +144,20 @@ int nr_pdsch_dmrs_rx(PHY_VARS_NR_UE *ue,
int
nr_pbch_dmrs_rx
(
unsigned
int
*
nr_gold_pbch
,
int32_t
*
output
)
{
int
m
;
int
m
;
uint8_t
idx
=
0
;
/// QPSK modulation
for
(
m
=
0
;
m
<
NR_PBCH_DMRS_LENGTH
>>
1
;
m
++
)
{
idx
=
((((
nr_gold_pbch
[(
m
<<
1
)
>>
5
])
>>
((
m
<<
1
)
&
0x1f
))
&
1
)
<<
1
)
^
(((
nr_gold_pbch
[((
m
<<
1
)
+
1
)
>>
5
])
>>
(((
m
<<
1
)
+
1
)
&
0x1f
))
&
1
);
((
int16_t
*
)
output
)[
m
<<
1
]
=
nr_rx_mod_table
[(
NR_MOD_TABLE_QPSK_OFFSET
+
idx
)
<<
1
];
((
int16_t
*
)
output
)[(
m
<<
1
)
+
1
]
=
nr_rx_mod_table
[((
NR_MOD_TABLE_QPSK_OFFSET
+
idx
)
<<
1
)
+
1
];
/// BPSK modulation
for
(
m
=
0
;
m
<
NR_PBCH_DMRS_LENGTH
;
m
++
)
{
((
int16_t
*
)
output
)[
m
<<
1
]
=
nr_mod_table
[((
1
+
((
nr_gold_pbch
[
m
>>
5
]
&
(
1
<<
(
m
&
0x1f
)))
>>
(
m
&
0x1f
)))
<<
1
)];
((
int16_t
*
)
output
)[(
m
<<
1
)
+
1
]
=
nr_mod_table
[((
1
+
((
nr_gold_pbch
[
m
>>
5
]
&
(
1
<<
(
m
&
0x1f
)))
>>
(
m
&
0x1f
)))
<<
1
)
+
1
];
#ifdef DEBUG_PBCH
//printf("nr_gold_pbch[m>>5] %x\n",nr_gold_pbch[m>>5]);
if
(
m
<
16
)
{
printf
(
"nr_gold_pbch[(m<<1)>>5] %x
\n
"
,
nr_gold_pbch
[(
m
<<
1
)
>>
5
]);
printf
(
"m %d output %d %d addr %p
\n
"
,
m
,
((
int16_t
*
)
output
)[
m
<<
1
],
((
int16_t
*
)
output
)[(
m
<<
1
)
+
1
],
&
output
[
0
]);
}
#endif
}
...
...
openair1/PHY/NR_REFSIG/nr_mod_table.h
View file @
f68d124d
#define NR_MOD_TABLE_SIZE_SHORT 14
#define NR_MOD_TABLE_BPSK_OFFSET 1
#define NR_MOD_TABLE_QPSK_OFFSET 3
short
nr_mod_table
[
MOD_TABLE_SIZE_SHORT
]
=
{
0
,
0
,
23170
,
23170
,
-
23170
,
-
23170
,
23170
,
23170
,
23170
,
-
23170
,
-
23170
,
23170
,
-
23170
,
-
23170
};
short
nr_mod_table
[
NR_
MOD_TABLE_SIZE_SHORT
]
=
{
0
,
0
,
23170
,
23170
,
-
23170
,
-
23170
,
23170
,
23170
,
23170
,
-
23170
,
-
23170
,
23170
,
-
23170
,
-
23170
};
openair1/PHY/NR_UE_TRANSPORT/nr_pbch.c
View file @
f68d124d
...
...
@@ -496,7 +496,7 @@ uint16_t nr_rx_pbch( PHY_VARS_NR_UE *ue,
uint8_t
*
decoded_output
=
nr_ue_pbch_vars
->
decoded_output
;
//uint16_t crc;
//short nr_demod_table[8] = {0,0,0,1,1,0,1,1};
double
nr_demod_table
[
8
]
=
{
0
.
707
,
0
.
707
,
0
.
707
,
-
0
.
707
,
-
0
.
707
,
0
.
707
,
-
0
.
707
,
-
0
.
707
};
double
nr_demod_table
[
8
]
=
{
0
.
707
,
0
.
707
,
-
0
.
707
,
0
.
707
,
0
.
707
,
-
0
.
707
,
-
0
.
707
,
-
0
.
707
};
double
*
demod_pbch_e
=
malloc
(
sizeof
(
double
)
*
864
);
unsigned
short
idx_demod
=
0
;
int8_t
decoderState
=
0
;
...
...
@@ -607,8 +607,8 @@ uint16_t nr_rx_pbch( PHY_VARS_NR_UE *ue,
//polar decoding de-rate matching
decoderState
=
polar_decoder
(
demod_pbch_e
,
pbch_a
,
&
frame_parms
->
pbch_polar_params
,
decoderListSize
,
aPrioriArray
,
pathMetricAppr
);
//
for (i=0; i<NR_POLAR_PBCH_PAYLOAD_BITS; i++)
//
printf("pbch_a[%d] = %u \n", i,pbch_a[i]);
for
(
i
=
0
;
i
<
NR_POLAR_PBCH_PAYLOAD_BITS
;
i
++
)
printf
(
"pbch_a[%d] = %u
\n
"
,
i
,
pbch_a
[
i
]);
//un-scrambling
nr_pbch_unscrambling
(
frame_parms
,
pbch_a
,
NR_POLAR_PBCH_PAYLOAD_BITS
);
...
...
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