Search code examples
swiftxcodebluetoothbluetooth-lowenergyheartrate

How to get raw ECG data with BLE


I'm currently working on a holter monitor. I can successfully show the heart rate (bpm) using the Heart Rate Measurement (0x2A37) characteristic of Bluetooth. But I want to show an ECG line graph so I need the raw heart data, with the voltage amounts specified. I can reach some other information such as RR-interval and sensor contact status (with this characteristic) but I don't know how to get the raw data itself. Is it possible that I'm missing a feature of this characteristic, or is there any other way I can get this data? I'm using an AD8232 heart monitor.


Solution

  • The GATT Heart Rate Service doesn't provide access to the raw signal (see Gatt specifications).

    If you have access to the hardware platform you will have to write a custom service and characteristic that supports notification, and forward the data from the sensor onto this. You'll then have to write the matching app-side code to get this data and convert it into a usable format.