diff --git a/openair1/PHY/INIT/nr_init.c b/openair1/PHY/INIT/nr_init.c
index bce14e4f5629d8e430e640909f4ce28fd32c4940..135d6099e007bf8d7494b13d450568de18c82c87 100644
--- a/openair1/PHY/INIT/nr_init.c
+++ b/openair1/PHY/INIT/nr_init.c
@@ -384,7 +384,7 @@ void nr_phy_config_request_sim(PHY_VARS_gNB *gNB,int N_RB_DL,int N_RB_UL,int mu)
   gNB_config->rf_config.ul_carrier_bandwidth.value = N_RB_UL;
   gNB_config->sch_config.half_frame_index.value = 0;
   gNB_config->sch_config.ssb_subcarrier_offset.value = 0;
-  gNB_config->sch_config.n_ssb_crb.value = (N_RB_DL-20)>>1;
+  gNB_config->sch_config.n_ssb_crb.value = (N_RB_DL-20);
   gNB_config->sch_config.ssb_subcarrier_offset.value = 0;
 
 
@@ -419,7 +419,7 @@ void nr_phy_config_request(NR_PHY_Config_t *phy_config)
   gNB_config->rf_config.ul_carrier_bandwidth.value      = phy_config->cfg->rf_config.ul_carrier_bandwidth.value;//106;
   gNB_config->sch_config.half_frame_index.value         = 0;
   gNB_config->sch_config.ssb_subcarrier_offset.value    = phy_config->cfg->sch_config.ssb_subcarrier_offset.value;//0;
-  gNB_config->sch_config.n_ssb_crb.value                = (phy_config->cfg->rf_config.dl_carrier_bandwidth.value-20)>>1;
+  gNB_config->sch_config.n_ssb_crb.value                = (phy_config->cfg->rf_config.dl_carrier_bandwidth.value-20);
   gNB_config->sch_config.physical_cell_id.value         = phy_config->cfg->sch_config.physical_cell_id.value;
 
   if (phy_config->cfg->subframe_config.duplex_mode.value == 0) {
diff --git a/openair1/PHY/INIT/nr_init_ue.c b/openair1/PHY/INIT/nr_init_ue.c
index 77faeaa0c2140baf24bef30f99624ffd6416f3dd..a2385b998c2b81ee25f8d9c39cc8c50f88c489e6 100644
--- a/openair1/PHY/INIT/nr_init_ue.c
+++ b/openair1/PHY/INIT/nr_init_ue.c
@@ -655,7 +655,7 @@ int init_nr_ue_signal(PHY_VARS_NR_UE *ue,
   int i,j,k,l;
   int eNB_id;
   int th_id;
-  int n_ssb_crb=(fp->N_RB_DL-20)>>1;
+  int n_ssb_crb=(fp->N_RB_DL-20);
   abstraction_flag = 0;
   fp->nb_antennas_tx = 1;
   fp->nb_antennas_rx=1;
diff --git a/openair1/PHY/NR_UE_TRANSPORT/dci_nr.c b/openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
index 78f793ec17d7857f46496952d7a7796b6beb0b47..b1a384d4a0b2173928fb7607f3c27b831c516ff9 100755
--- a/openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
+++ b/openair1/PHY/NR_UE_TRANSPORT/dci_nr.c
@@ -49,7 +49,7 @@
 
 //#define NR_LTE_PDCCH_DCI_SWITCH
 #define NR_PDCCH_DCI_RUN              // activates new nr functions
-//#define NR_PDCCH_DCI_DEBUG            // activates NR_PDCCH_DCI_DEBUG logs
+#define NR_PDCCH_DCI_DEBUG            // activates NR_PDCCH_DCI_DEBUG logs
 #define NR_NBR_CORESET_ACT_BWP 3      // The number of CoreSets per BWP is limited to 3 (including initial CORESET: ControlResourceId 0)
 #define NR_NBR_SEARCHSPACE_ACT_BWP 10 // The number of SearSpaces per BWP is limited to 10 (including initial SEARCHSPACE: SearchSpaceId 0)
 #define PDCCH_TEST_POLAR_TEMP_FIX
diff --git a/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c b/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c
index 1b315756157a53a60977b4386a649316730eb37d..80c71bd665a6f785020786617c3662e0259a6902 100644
--- a/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c
+++ b/openair1/PHY/NR_UE_TRANSPORT/nr_initial_sync.c
@@ -149,7 +149,7 @@ int nr_initial_sync(PHY_VARS_NR_UE *ue, runmode_t mode)
   int rx_power=0; //aarx,
   //nfapi_nr_config_request_t* config;
 
-  int n_ssb_crb=(fp->N_RB_DL-20)>>1;
+  int n_ssb_crb=(fp->N_RB_DL-20);
   // First try TDD normal prefix, mu 1
   fp->Ncp=NORMAL;
   fp->frame_type=TDD;
@@ -213,12 +213,12 @@ int nr_initial_sync(PHY_VARS_NR_UE *ue, runmode_t mode)
     
     nr_gold_pdcch(ue,0, 2);
     /*
-    int nb_prefix_samples0 = frame_parms->nb_prefix_samples0;
-    frame_parms->nb_prefix_samples0 = frame_parms->nb_prefix_samples.
+    int nb_prefix_samples0 = fp->nb_prefix_samples0;
+    fp->nb_prefix_samples0 = fp->nb_prefix_samples;
 	  
     nr_slot_fep(ue,0, 0, ue->ssb_offset, 0, 1, NR_PDCCH_EST);
     nr_slot_fep(ue,1, 0, ue->ssb_offset, 0, 1, NR_PDCCH_EST);
-    frame_parms->nb_prefix_samples0 = nb_prefix_samples0;	
+    fp->nb_prefix_samples0 = nb_prefix_samples0;	
 
     LOG_I(PHY,"[UE  %d] AUTOTEST Cell Sync : frame = %d, rx_offset %d, freq_offset %d \n",
               ue->Mod_id,
diff --git a/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c b/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
index 32beb9200991d5933db7ee9a3a995c65d9e62b76..f3fa4ed55b1750e98dd5582d18f93800e5b6c22e 100644
--- a/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
+++ b/openair1/SCHED_NR_UE/phy_procedures_nr_ue.c
@@ -5922,11 +5922,11 @@ int phy_procedures_nrUE_RX(PHY_VARS_NR_UE *ue,UE_nr_rxtx_proc_t *proc,uint8_t eN
 
       VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_UE_SLOT_FEP, VCD_FUNCTION_IN);
       nr_slot_fep(ue,
-         l,
-         nr_tti_rx,
-         0,
-         1,
-         1,
+		  l,
+		  nr_tti_rx,
+		  0,
+		  0,
+		  1,
 		 NR_PDCCH_EST);
       VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_UE_SLOT_FEP, VCD_FUNCTION_OUT);
 #if UE_TIMING_TRACE
@@ -5934,48 +5934,51 @@ int phy_procedures_nrUE_RX(PHY_VARS_NR_UE *ue,UE_nr_rxtx_proc_t *proc,uint8_t eN
 #endif
     }
   }
-    //ue_measurement_procedures(l-1,ue,proc,eNB_id,(nr_tti_rx<<1),abstraction_flag,mode);
 
-    //if (do_pdcch_flag) {
-//      if ((l==pilot1) || ((pmch_flag==1)&(l==l2)))  {
-//	LOG_D(PHY,"[UE  %d] Frame %d: Calling pdcch procedures (eNB %d)\n",ue->Mod_id,frame_rx,eNB_id);
+  write_output("rxdataF.m","rxF",ue->common_vars.common_vars_rx_data_per_thread[ue->current_thread_id[nr_tti_rx>>1]].rxdataF[0],ue->frame_parms.ofdm_symbol_size*2,1,1);
 
-	//start_meas(&ue->rx_pdcch_stats[ue->current_thread_id[nr_tti_rx]]);
-	
-//printf(">>> at phy_procedures_nrUE_RX, nr_ue_pdcch_procedures init, dlsch->active=%d\n",
-//        ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0]->active); 
-	if (nr_ue_pdcch_procedures(eNB_id,ue,proc,abstraction_flag) == -1) {
-	  LOG_E(PHY,"[UE  %d] Frame %d, nr_tti_rx %d: Error in pdcch procedures\n",ue->Mod_id,frame_rx,nr_tti_rx);
-	  return(-1);
-	}
-//for (int m=0;m<1000;m++) printf("%d",m); 
-//printf("\n>>> at phy_procedures_nrUE_RX, nr_ue_pdcch_procedures end, dlsch->active=%d\n",
-//        ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0]->active); 
+  //ue_measurement_procedures(l-1,ue,proc,eNB_id,(nr_tti_rx<<1),abstraction_flag,mode);
 
+  //if (do_pdcch_flag) {
+  //      if ((l==pilot1) || ((pmch_flag==1)&(l==l2)))  {
+  //	LOG_D(PHY,"[UE  %d] Frame %d: Calling pdcch procedures (eNB %d)\n",ue->Mod_id,frame_rx,eNB_id);
+
+  //start_meas(&ue->rx_pdcch_stats[ue->current_thread_id[nr_tti_rx]]);
+	
+  //printf(">>> at phy_procedures_nrUE_RX, nr_ue_pdcch_procedures init, dlsch->active=%d\n",
+  //        ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0]->active); 
+  if (nr_ue_pdcch_procedures(eNB_id,ue,proc,abstraction_flag) == -1) {
+    LOG_E(PHY,"[UE  %d] Frame %d, nr_tti_rx %d: Error in pdcch procedures\n",ue->Mod_id,frame_rx,nr_tti_rx);
+    return(-1);
+  }
+  //for (int m=0;m<1000;m++) printf("%d",m); 
+  //printf("\n>>> at phy_procedures_nrUE_RX, nr_ue_pdcch_procedures end, dlsch->active=%d\n",
+  //        ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0]->active); 
+  
   // preparing for PDSCH procedures
-//  if (ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0]->active == 1) {
-//    ue_pdsch_procedures(ue,
-//			proc,
-//			eNB_id,
-//			PDSCH,
-//			ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0],
-//			NULL,
-//			ue->pdcch_vars[ue->current_thread_id[nr_tti_rx]][eNB_id]->num_pdcch_symbols,
-//			ue->frame_parms.symbols_per_tti>>1,
-//			abstraction_flag);
-//  }
+  //  if (ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0]->active == 1) {
+  //    ue_pdsch_procedures(ue,
+  //			proc,
+  //			eNB_id,
+  //			PDSCH,
+  //			ue->dlsch[ue->current_thread_id[nr_tti_rx]][eNB_id][0],
+  //			NULL,
+  //			ue->pdcch_vars[ue->current_thread_id[nr_tti_rx]][eNB_id]->num_pdcch_symbols,
+  //			ue->frame_parms.symbols_per_tti>>1,
+  //			abstraction_flag);
+  //  }
 #if 0
-	//stop_meas(&ue->rx_pdcch_stats[ue->current_thread_id[nr_tti_rx]]);
-    //printf("nr_tti_rx %d n_pdcch_sym %d pdcch procedures  %5.3f \n",
-    //        nr_tti_rx, ue->pdcch_vars[ue->current_thread_id[nr_tti_rx]][eNB_id]->num_pdcch_symbols,
-    //     (ue->rx_pdcch_stats[ue->current_thread_id[nr_tti_rx]].p_time)/(cpuf*1000.0));
-	LOG_D(PHY,"num_pdcch_symbols %d\n",ue->pdcch_vars[ue->current_thread_id[nr_tti_rx]][eNB_id]->num_pdcch_symbols);
-//      }
-    //}
-
-//  } // for l=1..l2
-
-
+  //stop_meas(&ue->rx_pdcch_stats[ue->current_thread_id[nr_tti_rx]]);
+  //printf("nr_tti_rx %d n_pdcch_sym %d pdcch procedures  %5.3f \n",
+  //        nr_tti_rx, ue->pdcch_vars[ue->current_thread_id[nr_tti_rx]][eNB_id]->num_pdcch_symbols,
+  //     (ue->rx_pdcch_stats[ue->current_thread_id[nr_tti_rx]].p_time)/(cpuf*1000.0));
+  LOG_D(PHY,"num_pdcch_symbols %d\n",ue->pdcch_vars[ue->current_thread_id[nr_tti_rx]][eNB_id]->num_pdcch_symbols);
+  //      }
+  //}
+  
+  //  } // for l=1..l2
+  
+  
   ue_measurement_procedures(l-1,ue,proc,eNB_id,(nr_tti_rx<<1),abstraction_flag,mode);
 
   LOG_D(PHY," ------  end FFT/ChannelEst/PDCCH slot 0: AbsSubframe %d.%d ------  \n", frame_rx%1024, nr_tti_rx);
diff --git a/openair1/SIMULATION/NR_PHY/pbchsim.c b/openair1/SIMULATION/NR_PHY/pbchsim.c
index 8de8a585c6b1632faea0a855e25a18b3c10931cb..f1ec263284418c4e968039e869079fa20e8a38ad 100644
--- a/openair1/SIMULATION/NR_PHY/pbchsim.c
+++ b/openair1/SIMULATION/NR_PHY/pbchsim.c
@@ -442,11 +442,10 @@ int main(int argc, char **argv)
     for (int i=0;i<4;i++) gNB->pbch_pdu[i]=i+1;
     nr_common_signal_procedures (gNB,frame,subframe);
 
-    /*  
 	LOG_M("txsigF0.m","txsF0", gNB->common_vars.txdataF[0],frame_length_complex_samples_no_prefix,1,1);
 	if (gNB->frame_parms.nb_antennas_tx>1)
 	LOG_M("txsigF1.m","txsF1", gNB->common_vars.txdataF[1],frame_length_complex_samples_no_prefix,1,1);
-    */
+
     //TODO: loop over slots
     for (aa=0; aa<gNB->frame_parms.nb_antennas_tx; aa++) {
       if (gNB_config->subframe_config.dl_cyclic_prefix_type.value == 1) {