Official reference client implementation for Cumulocity SmartREST on u-blox C027.
Dependencies: C027_Support C12832 LM75B MMA7660 MbedSmartRest mbed-rtos mbed
Fork of MbedSmartRestMain by
Diff: operation/OperationSupport.cpp
- Revision:
- 68:0dc778a16d0d
- Parent:
- 67:c360a2b2c948
- Child:
- 70:f489ca11f254
--- a/operation/OperationSupport.cpp Sun Nov 30 19:34:49 2014 +0000 +++ b/operation/OperationSupport.cpp Sat Dec 06 19:47:23 2014 +0000 @@ -10,11 +10,11 @@ CharValue aOperationStateSuccessful("SUCCESSFUL"); CharValue aOperationStateFailed("FAILED"); -OperationSupport::OperationSupport(AbstractSmartRest& client, SmartRestTemplate& tpl, long& deviceId, DeviceIO& io) : +OperationSupport::OperationSupport(AbstractSmartRest& client, SmartRestTemplate& tpl, long& deviceId, ConfigurationSynchronization& configurationSynchronization, DeviceIO& io) : _client(client), _tpl(tpl), _deviceId(deviceId), - _executor(client, tpl, deviceId, io), + _executor(client, tpl, deviceId, configurationSynchronization, io), _thread1(OperationSupport::thread1_func, this), _thread2(OperationSupport::thread2_func, this), _thread3(OperationSupport::thread3_func, this) @@ -59,10 +59,11 @@ { if (_firstRun) { _firstRun = false; - return true; - if (!requestPendingOperations()) - return false; + //TODO: only request pending until push operation works } + + if (!requestPendingOperations()) + return false; return true; } @@ -228,7 +229,7 @@ void OperationSupport::thread3() { - char bayeuxId[33]; +/* char bayeuxId[33]; ComposedRecord record; ParsedRecord received; @@ -257,7 +258,7 @@ } while (true) { - } + }*/ } void OperationSupport::thread1_func(void const *arg)