mbed Connector Interface simplification API on top of mbed-client
Fork of mbedConnectorInterfaceV3 by
NOTE:
This repo has been replaced with https://github.com/ARMmbed/mbedConnectorInterface. No further updates will occur with this repo. Please use the github repo instead. Thanks!
Diff: source/EventQueueResourceObserver.cpp
- Revision:
- 123:2167e9286edb
- Parent:
- 122:4072e03884e4
- Child:
- 124:097ec45bd12b
--- a/source/EventQueueResourceObserver.cpp Thu Jul 13 18:48:54 2017 +0000 +++ b/source/EventQueueResourceObserver.cpp Thu Jul 13 19:04:25 2017 +0000 @@ -34,13 +34,13 @@ this->logger()->log("EventQueueResourceObserver being used for %s (sleep_time: %d ms)",resource->getFullName().c_str(),sleep_time); // start the thread by invoking the thread task... - this->m_event_queue.call_every(sleep_time,callback(this,&EventQueueResourceObserver::observation_task)); + this->m_id = this->m_event_queue.call_every(sleep_time,callback(this,&EventQueueResourceObserver::observation_task)); } // destructor EventQueueResourceObserver::~EventQueueResourceObserver() { this->stopObservation(); - this->m_event_queue.cancel(); + this->m_event_queue.cancel(this->m_id); } // observation task method