Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Creating Fitbit Apps For Beginners

 

So im just beginning to learn when it comes to scripting and code. What I have to come to learn is that for a Fitbit device to create an app the script should begin with a folder structure which appears as so

/app/
/common/
/companion/
/resources/
/settings/

Lets say I want to create an app which utilizes the barometer sensor which is labeled in the list of SDK sensors. When I research the barometer sensor I found some code that is used to obtain latest reading from the barometer which looks like this

import { Barometer } from "barometer";

if (Barometer) {
  const barometer = new Barometer({ frequency: 1 });
  barometer.addEventListener("reading", () => {
    console.log(`Pressure: ${barometer.pressure} Pa`);
  });
  barometer.start();
}

So would I plug in that code in between the two slashes where it says "/app/"
If anybody has any experience with creating apps id appreciate the input.

Best Answer
0 Votes
1 REPLY 1

I suggest starting here.

Peter McLennan
Gondwana Software
Best Answer