Esempio n. 1
0
void srslte_sync_set_cfo_i_enable(srslte_sync_t *q, bool enable) {
  q->cfo_i_enable = enable;
  if (q->cfo_i_enable  && !q->cfo_i_initiated) {
    for (int i=0;i<2;i++) {
      int offset=(i==0)?-1:1;
      if (srslte_pss_init_fft_offset(&q->pss_i[i], q->max_offset, q->fft_size, offset)) {
        fprintf(stderr, "Error initializing PSS object\n");
      }
      for (int t=0;t<q->frame_size;t++) {
        q->cfo_i_corr[i][t] = cexpf(-2*_Complex_I*M_PI*offset*(float) t/q->fft_size);
      }
    }
    q->cfo_i_initiated = true;
  }
}
Esempio n. 2
0
File: pss.c Progetto: srsLTE/srsLTE
int srslte_pss_init_fft(srslte_pss_t *q, uint32_t frame_size, uint32_t fft_size) {
  return srslte_pss_init_fft_offset(q, frame_size, fft_size, 0);
}