fix Scell sync for large cells

the PSS detection needs more temporary buffer than a full subframe.
we therefore need to allocate and initialize the sync object with
larger maximum size to support Scell search of large cells, e.g.
20 MHz

this fixes issue #1538
master
Andre Puschmann 4 years ago committed by Xavier Arteaga
parent f380f46a10
commit 1199a79851

@ -53,7 +53,6 @@ int srslte_sync_init(srslte_sync_t* q, uint32_t frame_size, uint32_t max_offset,
}
int srslte_sync_init_decim(srslte_sync_t* q, uint32_t frame_size, uint32_t max_offset, uint32_t fft_size, int decimate)
{
int ret = SRSLTE_ERROR_INVALID_INPUTS;
if (q != NULL && fft_size_isvalid(fft_size)) {

@ -59,7 +59,7 @@ private:
uint32_t channel = 0;
srslte_sync_t find_pss = {};
int32_t sf_len = 0;
std::array<cf_t, SRSLTE_SF_LEN_MAX> temp;
std::array<cf_t, 2 * SRSLTE_SF_LEN_MAX> temp;
/**
* Executes the PSS search state
@ -110,14 +110,18 @@ private:
public:
/**
* Constructor
*
* Init PSS search object with twice the max subframe length to support max cell bandwidth.
*
* @param _callback provides the class for giving feedback
* @param _channel provides the channel index where the feedback needs to be applied
*/
sync(sync_callback* _callback, uint32_t _channel) : callback(_callback), channel(_channel)
{
// Initialise Find PSS object
if (srslte_sync_init(&find_pss, SRSLTE_SF_LEN_MAX, SRSLTE_SF_LEN_MAX, SRSLTE_SYMBOL_SZ_MAX) != SRSLTE_SUCCESS) {
ERROR("Initiating Synchroniser\n");
if (srslte_sync_init(&find_pss, 2 * SRSLTE_SF_LEN_MAX, 2 * SRSLTE_SF_LEN_MAX, SRSLTE_SYMBOL_SZ_MAX) !=
SRSLTE_SUCCESS) {
ERROR("Initiating Synchronizer\n");
}
}

Loading…
Cancel
Save