Hussein Aladeen
Apr 24, 2017 · 6 min read

Google Fit API Integration

Image for post
Image for post

Background


The Architecture

Image for post
Image for post

The Implementation

FitManager

Connecting to the Google Fit API

Retrieving total steps recorded between two timestamps

Retrieving total steps recorded for the day

Inserting new steps

BleManager

Sending commands

Receiving data from BLE notifications


StepsSyncManager

Retrieving steps data from BLE

Pushing steps data to Google Fit API


Conclusion

Fueled Engineering

Publishing insights and discoveries on iOS and Android app…

Thanks to Garima Jain

Hussein Aladeen

Written by

Computer Science graduate. Loves mobile and web apps. Android developer. Creator of http://husseinala.com/flimo

Fueled Engineering

Publishing insights and discoveries on iOS and Android app development since 1982.

Hussein Aladeen

Written by

Computer Science graduate. Loves mobile and web apps. Android developer. Creator of http://husseinala.com/flimo

Fueled Engineering

Publishing insights and discoveries on iOS and Android app development since 1982.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch

Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore

Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store