test
Dependents: BLE_PowerBank_HeyFaradey
Fork of BLE_API by
Revision 1203:d4f1ef46d97b, committed 2016-09-14
- Comitter:
- Vincent Coubard
- Date:
- Wed Sep 14 14:17:55 2016 +0100
- Branch:
- cd1b77dd31654b728a317d0ac7e9bc4e04b17468
- Parent:
- 1201:9b71aac42d14
- Child:
- 1204:87fd06ff4e3c
- Commit message:
- Sync with cd1b77dd31654b728a317d0ac7e9bc4e04b17468
2016-08-31 09:54:29+01:00: Vincent Coubard
Synchronize with ble folder in mbed-os 5.
Changed in this revision
source/BLE.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/source/BLE.cpp Wed Sep 14 14:17:52 2016 +0100 +++ b/source/BLE.cpp Wed Sep 14 14:17:55 2016 +0100 @@ -25,6 +25,11 @@ #include <minar/minar.h> #endif +#if !defined(YOTTA_CFG_MBED_OS) +#include <mbed_error.h> +#include <toolchain.h> +#endif + ble_error_t BLE::initImplementation(FunctionPointerWithContext<InitializationCompleteCallbackContext*> callback) { @@ -82,6 +87,20 @@ * This may be overridden. */ #define INITIALIZER_LIST_FOR_INSTANCE_CONSTRUCTORS createBLEInstance + +// yotta unlike mbed-cli has proper dependency mechanisms +// It is not required to defined a stub for createBLEInstance +#if !defined(YOTTA_CFG_MBED_OS) + +// this stub is required by ARMCC otherwise link will systematically fail +MBED_WEAK BLEInstanceBase* createBLEInstance() { + error("Please provide an implementation for mbed BLE"); + return NULL; +} + +#endif + + #endif /* YOTTA_CFG_BLE_INSTANCES_COUNT */ typedef BLEInstanceBase *(*InstanceConstructor_t)(void);