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 mbed nRF51822
Diff: main.cpp
- Revision:
- 3:183823979708
- Parent:
- 2:9b977e86e2d5
- Child:
- 4:851d3f52c344
--- a/main.cpp Mon Oct 19 19:29:31 2015 +0000
+++ b/main.cpp Thu Oct 22 10:22:59 2015 +0000
@@ -21,7 +21,7 @@
BLE ble;
DigitalOut connectionLed(LED1);
InterruptIn button(BUTTON1);
-BusIn ecg(p20, p23, p24, p25, p28, p29, p0, p30);
+AnalogIn ecg(p1);
const static char DEVICE_NAME[] = "UberVest";
static const uint16_t uuid16_list[] = {UberVestService::UBER_VEST_SERVICE_UUID};
@@ -87,7 +87,7 @@
buttonState = IDLE;
}
- ecgValue = ecg.read();
+ ecgValue = (ecg.read() * 1024);
uberVestServicePtr->updateEcg(ecgValue);
ble.waitForEvent();