Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: NaturalTinyShell_ice libmDot-12Sept mbed-rtos mbed
Fork of ICE by
Diff: src/main.cpp
- Revision:
- 34:f345fdec711d
- Parent:
- 32:79ec3a4c0ec5
- Child:
- 35:6235ef67faa1
--- a/src/main.cpp Thu Sep 08 21:17:21 2016 +0000 +++ b/src/main.cpp Thu Sep 08 22:01:00 2016 +0000 @@ -31,6 +31,13 @@ // for file system access outside of main() mDot *GLOBAL_mdot; +Thread *GLOBAL_analyticsLogger_thread = NULL; +Thread *GLOBAL_modbusMaster_thread = NULL; +Thread *GLOBAL_BLE_thread = NULL; +Thread *GLOBAL_CDH_thread = NULL; +Thread *GLOBAL_configHandler_thread = NULL; +Thread *GLOBAL_controlTask_thread = NULL; + // store modbus register information std::map<std::string,ModbusRegister> ModbusRegisterMap; @@ -87,10 +94,18 @@ printf("\r%s: continuing to initialize...\n", __func__); - Thread anaylticsLogger_thread(AnalyticsLogger); + Thread analyticsLoggerThread(AnalyticsLogger); Thread modbusMaster_thread(ModbusMaster); Thread BLE_thread(BLEDataHandler); Thread CDH_thread(CloudDataHandler, 0, osPriorityNormal, 3000, NULL); + + GLOBAL_analyticsLogger_thread = &analyticsLoggerThread; + GLOBAL_modbusMaster_thread = &modbusMaster_thread; + GLOBAL_BLE_thread = & BLE_thread; + GLOBAL_CDH_thread = & CDH_thread; + + GLOBAL_configHandler_thread = &configHandler_thread; + GLOBAL_controlTask_thread = &controlTask_thread; Thread::wait(1000);