02-12-2023 04:11
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

02-12-2023 04:11
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hello,
I am having a hard time in finding this information. Currently, we are integrating with an Apple Watch and we are thinking about integrating a Fitbit Charge 5 into our Sleep application which is built in Swift. Our app is dependent on accelerometer data.
- Using Swift, can we access the Raw Accelerometer data on the Charge 5? If so, can we query historical data? This would be done via Bluetooth.
- Or, does the Swift App have to make Http Requests to the FitBit API to retrieve this data? Again, we would need to query historical data. When is this data updated? Is that up to the user?
- If the Fitbit Charge 5 does not support this, what Fitbit devices have this support?
Thank you,
myRW
Answered! Go to the Best Answer.

Accepted Solutions
02-12-2023 11:29
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


02-12-2023 11:29
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Accel data can't be obtained from Charge 5. You'd need to use a Fitbit OS device (Versa* or Sense*).
Accel data isn't available from the Web API, probably because there would be too much of it to transfer.
You can get accel data from the Device API. You'd need to write a clockface or app that runs on the watch to collect this.
Accel data has to be collected in real-time on the watch.
You'd need to write code to transfer the data from the watch to the app/clockface companion code on the connected phone, and to send it from there to a server.
You may need to clarify what you mean by 'raw' data. You don't get access to the hardware; you can only get accel data from the API.
Gondwana Software

02-12-2023 04:42
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


02-12-2023 04:42
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hello @myRW and welcome to the Community. I'm moving your post to one of the developer forums. It's a better fit for your question. This forum's focus is Charge 5 users with device issues.
Laurie | Maryland
Sense 2, Luxe, Aria 2 | iOS | Mac OS
Take a look at the Fitbit help site for further assistance and information.

02-12-2023 05:44
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

02-12-2023 05:44
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Thank you @LZeeW . Can you post the new link?

02-12-2023 06:03
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


02-12-2023 06:03
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
@myRW No new link is needed. The whole thread is moved and it is if it were there all along.
Laurie | Maryland
Sense 2, Luxe, Aria 2 | iOS | Mac OS
Take a look at the Fitbit help site for further assistance and information.

02-12-2023 11:29
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


02-12-2023 11:29
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Accel data can't be obtained from Charge 5. You'd need to use a Fitbit OS device (Versa* or Sense*).
Accel data isn't available from the Web API, probably because there would be too much of it to transfer.
You can get accel data from the Device API. You'd need to write a clockface or app that runs on the watch to collect this.
Accel data has to be collected in real-time on the watch.
You'd need to write code to transfer the data from the watch to the app/clockface companion code on the connected phone, and to send it from there to a server.
You may need to clarify what you mean by 'raw' data. You don't get access to the hardware; you can only get accel data from the API.
Gondwana Software

02-12-2023 11:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

02-12-2023 11:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Thank you so much for your reply. It is very helpful. When I say the Raw data, I mean the X,Y,Z accelerometer data at a certain frequency. For example, 50hz.
Just to confirm, there is no way to query historical accelerometer on these devices? It has to be done in real-time.
Last, if you have any examples of an app/clockface that queries accelerometer data, I would appreciate it. If not, I will continue my search.
Thanks again for your help.

02-12-2023 11:46
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


02-12-2023 11:46
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Accel data isn't stored on the devices or transferred elsewhere by the operating system (probably because there's no need and there's too much of it).
There's at least one (bad) example here (Accelerometer Fetcher).
Be warned that this is fairly difficult!
Gondwana Software

02-13-2023 14:23
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

02-13-2023 14:23
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
One more question. Let's say that we create a Clockface or an Application. I read somewhere if the app is running and the user switches to another app (Settings for example), the streaming of data to our app would be stopped. Is that correct?

02-13-2023 14:27
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


02-13-2023 14:27
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Yes, at least on Versa 3 and Sense 1 and earlier devices. Behaviour on the newest devices hasn't been announced yet.
Gondwana Software

02-13-2023 14:31
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

02-13-2023 14:31
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
What about the Versa 4 or the Sense 2?

02-13-2023 14:43
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


02-13-2023 14:43
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Behaviour on the newest devices hasn't been announced yet.
Gondwana Software

