Commit 05d61a08 authored by Thomas Schlichter's avatar Thomas Schlichter

fix scrambling initialization in nr_dlsim and nr_ulsim

parent 96919468
......@@ -924,7 +924,16 @@ int main(int argc, char **argv)
init_nr_ue_transport(UE,0);
nr_gold_pbch(UE);
nr_gold_pdcch(UE,0);
// compute the scramblingID_pdcch and the gold pdcch
UE->scramblingID_pdcch = frame_parms->Nid_cell;
nr_gold_pdcch(UE, frame_parms->Nid_cell);
// compute the scrambling IDs for PDSCH DMRS
for (int i = 0; i < 2; i++)
UE->scramblingID[i] = frame_parms->Nid_cell;
nr_gold_pdsch(UE, UE->scramblingID);
nr_l2_init_ue(NULL);
UE_mac = get_mac_inst(0);
......
......@@ -755,28 +755,17 @@ int main(int argc, char **argv)
PHY_vars_UE_g[0][0] = UE;
memcpy(&UE->frame_parms, frame_parms, sizeof(NR_DL_FRAME_PARMS));
//phy_init_nr_top(frame_parms);
if (init_nr_ue_signal(UE, 1, 0) != 0) {
printf("Error at UE NR initialisation\n");
exit(-1);
}
//nr_init_frame_parms_ue(&UE->frame_parms);
init_nr_ue_transport(UE, 0);
/*
for (int sf = 0; sf < 2; sf++) {
for (i = 0; i < 2; i++) {
UE->ulsch[sf][0][i] = new_nr_ue_ulsch(N_RB_UL, 8, 0);
if (!UE->ulsch[sf][0][i]) {
printf("Can't get ue ulsch structures\n");
exit(-1);
}
}
}
*/
// initialize the pusch dmrs
uint16_t N_n_scid[2] = {frame_parms->Nid_cell,frame_parms->Nid_cell};
int n_scid = 0; // This quantity is indicated by higher layer parameter dmrs-SeqInitialization
nr_init_pusch_dmrs(UE, N_n_scid, n_scid);
//Configure UE
NR_UE_RRC_INST_t rrcue;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment