This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Companion SDK / Health API and Live Heart Rate Data

Hi,

I want to use get live heart rate data (a bit of delay is okay). I wanted to know about the delay I would experience when trying to get the Heart Rate data.

I am planning this flow:

Garmin Device -> Garmin Connect -> Cloud Sync -> Health API -> Heart Rate Data (via REST API)

OR

Garmin Device -> Companion SDK -> Heart Rate Data (in Android App)

What is the delay that I can experience in both cases?

Top Replies

All Replies

  • Garmin Device -> Garmin Connect -> Cloud Sync -> Health API -> Heart Rate Data (via REST API)

    Live HR data is being transmitted to the Garmin Connect app live, without any significant delay, but it gets synced to the cloud only occasionally - at some events like the end of an activity, manual sync, or some scheduled sync events. Hence the delay to the Health API may be considerable (up to hours)

    Garmin Device -> Companion SDK -> Heart Rate Data (in Android App)

    A Connect IQ app transmitting the HR to a companion app would have no significant delay

    However, on most Garmin watch models, you can simply turn on the HR streaming (either over ANT+ or over BT), and read the HR directly without having to use any CIQ app + Companion, just using commonly available apps for reading data from HR monitors.

  • Hi, Thanks for the quick reply.

    You mentioned Connect IQ, isn't that used to develop Garmin watch apps? I assumed that Companion SDK is different and that it is used only to develop Android/iOS applications. More precisely, do I need to develop both apps? Like ConnectIQ transmitting and Companion SDK in my mobile app receiving that data? Is there a way to skip the Mobile App and expose data collected with ConnectIQ directly to a REST endpoint? OR vice versa? Skip ConnectIQ and connect my Android app with my Garmin Device to read HR data from it directly?

    I was looking for this solution because in my watch, Vivosmart 4, I wasn't sure if it broadcasted HR over BLE. It would be great if I could simply use some BLE library in Python like Bleak and get live HR.

  • You mentioned Connect IQ, isn't that used to develop Garmin watch apps? I assumed that Companion SDK is different and that it is used only to develop Android/iOS applications.

    Yes, the Companion SDK can read the all-day data in real time even without a Connect IQ app. However, the access to the Companion SDK is commercial, not free, unlike the access to the CIQ SDK. With CIQ, you can write your own app and your own companion, and stream the data of your choice to it, free of charge.

  • Does Garmin provide any way to get on-demand HR data like in WearOS?

  • Only in the mentioned ways: 

    1. HR broadcasting (Vivosmart 4 broadcasts the HR over ANT+, so you need an ANT+ enabled phone, or an ANT+ adapter)
    2. CIQ app (+ companion app or an HTTP receiver)
    3. Health API + Companion SDK
  • ... alternatively you can also capture some data, including the HR, from outdoors activities with the help of LiveTrack - by parsing the LiveTrack HTTP streams.

  • Thanks so much. I just wanted to know if newer models of Vivosmart 4 have some firmware updates. It mentions Bluetooth Smart (BLE) but on the forum, I saw some people mentioning it does not broadcast HR over BLE. I'm a bit confused as to why they would mention BLE.

  • Vivosmart 4 uses BLE (Bluetooth Low Energy) for the communication with Garmin Connect, but it only uses ANT+ for broadcasting the HR, as I already wrote previously.