![](/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@93:61d44636f020, 2015-04-20 (annotated)
- Committer:
- xinlei
- Date:
- Mon Apr 20 15:04:23 2015 +0000
- Revision:
- 93:61d44636f020
- Parent:
- 92:0acd11870c6a
- Child:
- 95:5dfdc8568e9f
Integration of new device push code base.
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> |
Cumulocity | 41:804f6a0bda26 | 5 | #include "MDM.h" |
xinlei | 93:61d44636f020 | 6 | #include "SmartRest.h" |
Cumulocity | 41:804f6a0bda26 | 7 | #include "SmartRestTemplate.h" |
Cumulocity | 41:804f6a0bda26 | 8 | #include "DeviceInfo.h" |
vwochnik | 67:c360a2b2c948 | 9 | #include "DeviceMemory.h" |
Cumulocity | 41:804f6a0bda26 | 10 | #include "DeviceBootstrap.h" |
Cumulocity | 41:804f6a0bda26 | 11 | #include "DeviceIntegration.h" |
vwochnik | 68:0dc778a16d0d | 12 | #include "DeviceConfiguration.h" |
vwochnik | 68:0dc778a16d0d | 13 | #include "ConfigurationProperties.h" |
vwochnik | 68:0dc778a16d0d | 14 | #include "ConfigurationSynchronization.h" |
Cumulocity | 41:804f6a0bda26 | 15 | #include "SignalQualityMeasurement.h" |
Cumulocity | 41:804f6a0bda26 | 16 | #include "TemperatureMeasurement.h" |
Cumulocity | 41:804f6a0bda26 | 17 | #include "AccelerationMeasurement.h" |
Cumulocity | 47:89ae46d5c466 | 18 | #include "AnalogMeasurement.h" |
Cumulocity | 47:89ae46d5c466 | 19 | #include "LocationUpdate.h" |
vwochnik | 57:4af5f1bec3a6 | 20 | #include "OperationSupport.h" |
xinlei | 92:0acd11870c6a | 21 | #include "LCDDisplay.h" |
xinlei | 92:0acd11870c6a | 22 | #include "SmartRestConf.h" |
xinlei | 93:61d44636f020 | 23 | #include "PollingThread.h" |
xinlei | 93:61d44636f020 | 24 | #include "ReportThread.h" |
Cumulocity | 41:804f6a0bda26 | 25 | |
Cumulocity | 41:804f6a0bda26 | 26 | class MbedAgent |
Cumulocity | 41:804f6a0bda26 | 27 | { |
Cumulocity | 41:804f6a0bda26 | 28 | public: |
xinlei | 92:0acd11870c6a | 29 | MbedAgent(GPSI2C&, MDMSerial&, LCDDisplay&, DeviceInfo&, DeviceMemory&); |
xinlei | 92:0acd11870c6a | 30 | |
Cumulocity | 41:804f6a0bda26 | 31 | bool init(); |
xinlei | 92:0acd11870c6a | 32 | int run(); |
xinlei | 92:0acd11870c6a | 33 | void loop(); |
Cumulocity | 41:804f6a0bda26 | 34 | |
Cumulocity | 41:804f6a0bda26 | 35 | protected: |
Cumulocity | 41:804f6a0bda26 | 36 | |
Cumulocity | 41:804f6a0bda26 | 37 | private: |
xinlei | 93:61d44636f020 | 38 | long _deviceId; |
Cumulocity | 41:804f6a0bda26 | 39 | MDMSerial& _mdm; |
Cumulocity | 41:804f6a0bda26 | 40 | DeviceInfo& _deviceInfo; |
vwochnik | 67:c360a2b2c948 | 41 | DeviceMemory& _deviceMemory; |
xinlei | 93:61d44636f020 | 42 | LCDDisplay& _lcdDisplay; |
vwochnik | 68:0dc778a16d0d | 43 | DeviceConfiguration _deviceConfiguration; |
vwochnik | 68:0dc778a16d0d | 44 | ConfigurationProperties _configurationProperties; |
xinlei | 93:61d44636f020 | 45 | SmartRest _client; |
Cumulocity | 41:804f6a0bda26 | 46 | SmartRestTemplate _tpl; |
Cumulocity | 41:804f6a0bda26 | 47 | DeviceBootstrap _bootstrap; |
Cumulocity | 41:804f6a0bda26 | 48 | DeviceIntegration _integration; |
vwochnik | 68:0dc778a16d0d | 49 | ConfigurationSynchronization _configurationSynchronization; |
Cumulocity | 41:804f6a0bda26 | 50 | SignalQualityMeasurement _signalQualityMeasurement; |
Cumulocity | 41:804f6a0bda26 | 51 | TemperatureMeasurement _temperatureMeasurement; |
Cumulocity | 41:804f6a0bda26 | 52 | AccelerationMeasurement _accelerationMeasurement; |
Cumulocity | 47:89ae46d5c466 | 53 | AnalogMeasurement _analogMeasurement; |
Cumulocity | 47:89ae46d5c466 | 54 | LocationUpdate _locationUpdate; |
xinlei | 93:61d44636f020 | 55 | OperationPool pool; |
vwochnik | 57:4af5f1bec3a6 | 56 | OperationSupport _operationSupport; |
Cumulocity | 41:804f6a0bda26 | 57 | }; |
Cumulocity | 41:804f6a0bda26 | 58 | |
Cumulocity | 41:804f6a0bda26 | 59 | #endif |