![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
Own fork of MbedSmartRestMain
Dependencies: C027_Support C12832 LM75B MMA7660 MbedSmartRest mbed-rtos mbed
Fork of MbedSmartRestMain by
MbedAgent.h@96:ea056f6be2e8, 2015-04-27 (annotated)
- Committer:
- xinlei
- Date:
- Mon Apr 27 13:02:50 2015 +0000
- Revision:
- 96:ea056f6be2e8
- Parent:
- 95:5dfdc8568e9f
- Child:
- 97:9f2de96941c4
MDMSerial now singleton
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Cumulocity | 41:804f6a0bda26 | 1 | #ifndef MBEDAGENT_H |
Cumulocity | 41:804f6a0bda26 | 2 | #define MBEDAGENT_H |
Cumulocity | 41:804f6a0bda26 | 3 | |
Cumulocity | 41:804f6a0bda26 | 4 | #include <stddef.h> |
xinlei | 93:61d44636f020 | 5 | #include "SmartRest.h" |
Cumulocity | 41:804f6a0bda26 | 6 | #include "SmartRestTemplate.h" |
Cumulocity | 41:804f6a0bda26 | 7 | #include "DeviceInfo.h" |
vwochnik | 67:c360a2b2c948 | 8 | #include "DeviceMemory.h" |
Cumulocity | 41:804f6a0bda26 | 9 | #include "DeviceBootstrap.h" |
Cumulocity | 41:804f6a0bda26 | 10 | #include "DeviceIntegration.h" |
vwochnik | 68:0dc778a16d0d | 11 | #include "ConfigurationSynchronization.h" |
Cumulocity | 41:804f6a0bda26 | 12 | #include "SignalQualityMeasurement.h" |
Cumulocity | 41:804f6a0bda26 | 13 | #include "TemperatureMeasurement.h" |
Cumulocity | 41:804f6a0bda26 | 14 | #include "AccelerationMeasurement.h" |
Cumulocity | 47:89ae46d5c466 | 15 | #include "AnalogMeasurement.h" |
Cumulocity | 47:89ae46d5c466 | 16 | #include "LocationUpdate.h" |
vwochnik | 57:4af5f1bec3a6 | 17 | #include "OperationSupport.h" |
xinlei | 92:0acd11870c6a | 18 | #include "SmartRestConf.h" |
xinlei | 95:5dfdc8568e9f | 19 | #include "PollThread.h" |
xinlei | 93:61d44636f020 | 20 | #include "ReportThread.h" |
Cumulocity | 41:804f6a0bda26 | 21 | |
Cumulocity | 41:804f6a0bda26 | 22 | class MbedAgent |
Cumulocity | 41:804f6a0bda26 | 23 | { |
Cumulocity | 41:804f6a0bda26 | 24 | public: |
xinlei | 96:ea056f6be2e8 | 25 | MbedAgent(GPSI2C&, DeviceInfo&, DeviceMemory&); |
xinlei | 92:0acd11870c6a | 26 | |
Cumulocity | 41:804f6a0bda26 | 27 | bool init(); |
xinlei | 92:0acd11870c6a | 28 | int run(); |
xinlei | 92:0acd11870c6a | 29 | void loop(); |
Cumulocity | 41:804f6a0bda26 | 30 | |
Cumulocity | 41:804f6a0bda26 | 31 | protected: |
Cumulocity | 41:804f6a0bda26 | 32 | |
Cumulocity | 41:804f6a0bda26 | 33 | private: |
xinlei | 93:61d44636f020 | 34 | long _deviceId; |
xinlei | 93:61d44636f020 | 35 | SmartRest _client; |
Cumulocity | 41:804f6a0bda26 | 36 | SmartRestTemplate _tpl; |
Cumulocity | 41:804f6a0bda26 | 37 | DeviceBootstrap _bootstrap; |
Cumulocity | 41:804f6a0bda26 | 38 | DeviceIntegration _integration; |
vwochnik | 68:0dc778a16d0d | 39 | ConfigurationSynchronization _configurationSynchronization; |
Cumulocity | 41:804f6a0bda26 | 40 | SignalQualityMeasurement _signalQualityMeasurement; |
Cumulocity | 41:804f6a0bda26 | 41 | TemperatureMeasurement _temperatureMeasurement; |
Cumulocity | 41:804f6a0bda26 | 42 | AccelerationMeasurement _accelerationMeasurement; |
Cumulocity | 47:89ae46d5c466 | 43 | AnalogMeasurement _analogMeasurement; |
Cumulocity | 47:89ae46d5c466 | 44 | LocationUpdate _locationUpdate; |
xinlei | 93:61d44636f020 | 45 | OperationPool pool; |
vwochnik | 57:4af5f1bec3a6 | 46 | OperationSupport _operationSupport; |
Cumulocity | 41:804f6a0bda26 | 47 | }; |
Cumulocity | 41:804f6a0bda26 | 48 | |
Cumulocity | 41:804f6a0bda26 | 49 | #endif |