Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG UE
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 UE
Commits
3313f442
Commit
3313f442
authored
Apr 22, 2020
by
cig
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Completed dlsch demodulation for RA PDSCH
parent
5a8605e0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
56 additions
and
52 deletions
+56
-52
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_demodulation.c
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_demodulation.c
+56
-52
No files found.
openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_demodulation.c
View file @
3313f442
...
...
@@ -132,7 +132,7 @@ int nr_rx_pdsch(PHY_VARS_NR_UE *ue,
unsigned
short
nb_rb
=
0
,
round
;
int
avgs
=
0
;
// rb;
NR_DL_UE_HARQ_t
*
dlsch0_harq
,
*
dlsch1_harq
=
0
;
NR_DL_UE_HARQ_t
*
dlsch0_harq
,
*
dlsch1_harq
=
NULL
;
uint8_t
beamforming_mode
;
...
...
@@ -157,7 +157,6 @@ int nr_rx_pdsch(PHY_VARS_NR_UE *ue,
int32_t
median
[
16
];
uint32_t
len
;
switch
(
type
)
{
case
SI_PDSCH
:
pdsch_vars
=
ue
->
pdsch_vars_SI
;
...
...
@@ -171,67 +170,73 @@ int nr_rx_pdsch(PHY_VARS_NR_UE *ue,
dlsch
=
&
ue
->
dlsch_ra
[
eNB_id
];
dlsch0_harq
=
dlsch
[
0
]
->
harq_processes
[
harq_pid
];
beamforming_mode
=
0
;
break
;
case
PDSCH
:
pdsch_vars
=
ue
->
pdsch_vars
[
ue
->
current_thread_id
[
nr_tti_rx
]];
dlsch
=
ue
->
dlsch
[
ue
->
current_thread_id
[
nr_tti_rx
]][
eNB_id
];
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
Qm
=
nr_get_Qm_dl
(
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs
,
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs_table
);
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
R
=
nr_get_code_rate_dl
(
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs
,
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs_table
);
beamforming_mode
=
ue
->
transmission_mode
[
eNB_id
]
<
7
?
0
:
ue
->
transmission_mode
[
eNB_id
];
dlsch0_harq
=
dlsch
[
0
]
->
harq_processes
[
harq_pid
];
dlsch1_harq
=
dlsch
[
1
]
->
harq_processes
[
harq_pid
];
//printf("status TB0 = %d, status TB1 = %d \n", dlsch[0]->harq_processes[harq_pid]->status, dlsch[1]->harq_processes[harq_pid]->status);
LOG_D
(
PHY
,
"AbsSubframe %d.%d / Sym %d harq_pid %d, harq status %d.%d
\n
"
,
frame
,
nr_tti_rx
,
symbol
,
harq_pid
,
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
status
,
dlsch
[
1
]
->
harq_processes
[
harq_pid
]
->
status
);
if
((
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
status
==
ACTIVE
)
&&
(
dlsch
[
1
]
->
harq_processes
[
harq_pid
]
->
status
==
ACTIVE
)){
codeword_TB0
=
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
codeword
;
codeword_TB1
=
dlsch
[
1
]
->
harq_processes
[
harq_pid
]
->
codeword
;
LOG_D
(
PHY
,
"AbsSubframe %d.%d / Sym %d harq_pid %d, harq status %d.%d
\n
"
,
frame
,
nr_tti_rx
,
symbol
,
harq_pid
,
dlsch0_harq
->
status
,
dlsch1_harq
->
status
);
if
((
dlsch0_harq
->
status
==
ACTIVE
)
&&
(
dlsch1_harq
->
status
==
ACTIVE
)){
codeword_TB0
=
dlsch0_harq
->
codeword
;
codeword_TB1
=
dlsch1_harq
->
codeword
;
dlsch0_harq
=
dlsch
[
codeword_TB0
]
->
harq_processes
[
harq_pid
];
dlsch1_harq
=
dlsch
[
codeword_TB1
]
->
harq_processes
[
harq_pid
];
#ifdef DEBUG_HARQ
#ifdef DEBUG_HARQ
printf
(
"[DEMOD] I am assuming both TBs are active
\n
"
);
#endif
}
else
if
((
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
status
==
ACTIVE
)
&&
(
dlsch
[
1
]
->
harq_processes
[
harq_pid
]
->
status
!=
ACTIVE
)
)
{
codeword_TB
0
=
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
codeword
;
#endif
}
else
if
((
dlsch0_harq
->
status
==
ACTIVE
)
&&
(
dlsch1_harq
->
status
!=
ACTIVE
)
)
{
codeword_TB0
=
dlsch0_harq
->
codeword
;
codeword_TB
1
=
-
1
;
dlsch0_harq
=
dlsch
[
0
]
->
harq_processes
[
harq_pid
];
dlsch1_harq
=
NULL
;
codeword_TB1
=
-
1
;
#ifdef DEBUG_HARQ
#ifdef DEBUG_HARQ
printf
(
"[DEMOD] I am assuming only TB0 is active
\n
"
);
#endif
}
else
if
((
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
status
!=
ACTIVE
)
&&
(
dlsch
[
1
]
->
harq_processes
[
harq_pid
]
->
status
==
ACTIVE
)
){
codeword_TB1
=
dlsch
[
1
]
->
harq_processes
[
harq_pid
]
->
codeword
;
dlsch0_harq
=
dlsch
[
1
]
->
harq_processes
[
harq_pid
];
dlsch1_harq
=
NULL
;
#endif
}
else
if
((
dlsch0_harq
->
status
!=
ACTIVE
)
&&
(
dlsch1_harq
->
status
==
ACTIVE
)){
codeword_TB0
=
-
1
;
#ifdef DEBUG_HARQ
codeword_TB1
=
dlsch1_harq
->
codeword
;
dlsch0_harq
=
NULL
;
dlsch1_harq
=
dlsch
[
1
]
->
harq_processes
[
codeword_TB1
];
#ifdef DEBUG_HARQ
printf
(
"[DEMOD] I am assuming only TB1 is active, it is in cw %d
\n
"
,
dlsch0_harq
->
codeword
);
#endif
}
else
{
LOG_E
(
PHY
,
"[UE][FATAL] nr_tti_rx %d: no active DLSCH
\n
"
,
nr_tti_rx
);
#endif
AssertFatal
(
1
==
0
,
"[UE][FATAL] DLSCH: TB0 not active and TB1 active case is not supported %d
\n
"
);
}
else
{
LOG_E
(
PHY
,
"[UE][FATAL] nr_tti_rx %d: no active DLSCH
\n
"
,
nr_tti_rx
);
return
(
-
1
);
}
beamforming_mode
=
ue
->
transmission_mode
[
eNB_id
]
<
7
?
0
:
ue
->
transmission_mode
[
eNB_id
];
break
;
default:
AssertFatal
(
1
==
0
,
"[UE][FATAL] nr_tti_rx %d: Unknown PDSCH format %d
\n
"
,
nr_tti_rx
,
type
);
AssertFatal
(
1
==
0
,
"[UE][FATAL] nr_tti_rx %d: Unknown PDSCH format %d
\n
"
,
nr_tti_rx
,
type
);
return
(
-
1
);
break
;
}
#ifdef DEBUG_HARQ
dlsch0_harq
->
Qm
=
nr_get_Qm_dl
(
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs
,
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs_table
);
dlsch0_harq
->
R
=
nr_get_code_rate_dl
(
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs
,
dlsch
[
0
]
->
harq_processes
[
harq_pid
]
->
mcs_table
);
#ifdef DEBUG_HARQ
printf
(
"[DEMOD] MIMO mode = %d
\n
"
,
dlsch0_harq
->
mimo_mode
);
printf
(
"[DEMOD] cw for TB0 = %d, cw for TB1 = %d
\n
"
,
codeword_TB0
,
codeword_TB1
);
#endif
#endif
start_rb
=
dlsch0_harq
->
start_rb
;
nb_rb_pdsch
=
dlsch0_harq
->
nb_rb
;
...
...
@@ -270,7 +275,6 @@ int nr_rx_pdsch(PHY_VARS_NR_UE *ue,
return
(
-
1
);
}
if
(
dlsch0_harq
->
mimo_mode
==
NR_DUALSTREAM
)
{
DevAssert
(
dlsch1_harq
);
}
...
...
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