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: mbed X_NUCLEO_IDB0XA1 BLE_API
Diff: main.cpp
- Revision:
- 1:11cd427bbc8b
- Parent:
- 0:eb7f02ad28a7
- Child:
- 2:bc0c0d442a24
diff -r eb7f02ad28a7 -r 11cd427bbc8b main.cpp
--- a/main.cpp Tue Sep 22 18:11:51 2015 +0000
+++ b/main.cpp Tue Sep 29 09:11:55 2015 +0000
@@ -21,7 +21,10 @@
#include "ble/services/DeviceInformationService.h"
BLE ble;
+
+#if !defined(IDB0XA1_D13_PATCH)
DigitalOut led1(LED1);
+#endif
const static char DEVICE_NAME[] = "HRM1";
static const uint16_t uuid16_list[] = {GattService::UUID_HEART_RATE_SERVICE,
@@ -35,8 +38,10 @@
void periodicCallback(void)
{
+
+#if !defined(IDB0XA1_D13_PATCH)
led1 = !led1; /* Do blinky on LED1 while we're waiting for BLE events */
-
+#endif
/* Note that the periodicCallback() executes in interrupt context, so it is safer to do
* heavy-weight sensor polling from the main thread. */
triggerSensorPolling = true;
@@ -44,7 +49,10 @@
int main(void)
{
+
+#if !defined(IDB0XA1_D13_PATCH)
led1 = 1;
+#endif
Ticker ticker;
ticker.attach(periodicCallback, 1); // blink LED every second