ue,sync: increase timeout for entering IDLE to 2s (#1941)

in ZMQ runs we've seen that entering idle could take quite
a bit of time depending how quickly workers get their samples
sent or reconfigurations done.

In one example up to ~160ms

this patch increases the maximum wait time to 2s.
This commit is contained in:
Andre Puschmann 2020-10-22 22:13:03 +02:00 committed by GitHub
parent 9b40d1da99
commit 58776bc227
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -751,9 +751,9 @@ void sync::set_ue_sync_opts(srslte_ue_sync_t* q, float cfo)
bool sync::set_cell(float cfo)
{
// Wait the SYNC thread to transition to IDLE
// Wait for SYNC thread to transition to IDLE (max. 2000ms)
uint32_t cnt = 0;
while (!phy_state.is_idle() && cnt <= 20) {
while (!phy_state.is_idle() && cnt <= 4000) {
Info("SYNC: PHY state is_idle=%d, cnt=%d\n", phy_state.is_idle(), cnt);
usleep(500);
cnt++;