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: BLE_API nRF51822 mbed-dev-bin
Diff: source/core/MicroBitDevice.cpp
- Revision:
- 57:290a35cb9981
- Parent:
- 47:69f452b1a5c9
- Child:
- 65:f7ebabf23e15
diff -r 1311cac15dda -r 290a35cb9981 source/core/MicroBitDevice.cpp
--- a/source/core/MicroBitDevice.cpp Wed Jul 13 12:18:35 2016 +0100
+++ b/source/core/MicroBitDevice.cpp Wed Jul 13 12:18:37 2016 +0100
@@ -67,8 +67,12 @@
*/
bool ble_running()
{
- uint8_t t;
+ uint8_t t = 0;
+
+#if CONFIG_ENABLED(MICROBIT_BLE_ENABLED) || CONFIG_ENABLED(MICROBIT_BLE_PAIRING_MODE)
sd_softdevice_is_enabled(&t);
+#endif
+
return t==1;
}