Cellular: Fix queue scheduling for bare metal

For non-rtos build (bare metal) cellular event queue is now scheduled by shared event queue.
pull/11859/head
Kimmo Vaisanen 2019-11-13 14:51:14 +02:00
parent f1848f9e6d
commit deadcee06c
1 changed files with 5 additions and 0 deletions

View File

@ -19,6 +19,7 @@
#include "CellularDevice.h"
#include "CellularLog.h"
#include "Thread.h"
#include "mbed_shared_queues.h"
#ifndef MBED_TRACE_MAX_LEVEL
#define MBED_TRACE_MAX_LEVEL TRACE_LEVEL_INFO
@ -111,6 +112,8 @@ void CellularStateMachine::stop()
delete _queue_thread;
_queue_thread = NULL;
}
#else
_queue.chain(NULL);
#endif
reset();
@ -655,6 +658,8 @@ nsapi_error_t CellularStateMachine::start_dispatch()
}
_event_id = -1;
#else
_queue.chain(mbed_event_queue());
#endif
return NSAPI_ERROR_OK;
}