02-19-2018 08:51
02-19-2018 08:51
Was making my first clock face ever using https://dev.fitbit.com/getting-started/ as a guide since I have never done any coding before. I was pleased with my result - getting the picture I wanted, the placement of the time exactly where I wanted it and format (12h/24h). So, not so complicated I guess, but proud of myself 😛
Then I was thinking that I would like to add day and date in the bottom left corner, BPM in the bottom right corner and a battery indicator in the top left corner. The battery indicator is not that important, but would like to get the others in place. Or maybe the day/date in the bottom and BPM in the top left corner...
I've been trying for hours looking at the forums here and looked at ozibyte.com to see if I can get it the way I want it but just can't get it to work. It just stays as I had originally made it....I can feel some techrage coming on...
Please help....
Best Answer02-19-2018 09:13 - edited 02-19-2018 09:50
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
02-19-2018 09:13 - edited 02-19-2018 09:50
Congratulations! It does feel very satisfying when things work.
Best Answer02-19-2018 09:46
02-19-2018 09:46
Did not understand any of that.....
Best Answer02-19-2018 09:49
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
02-19-2018 09:49
Sorry, I think I totally misread your post, or combined it with another.
Best Answer02-19-2018 09:55
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
02-19-2018 09:55
Firstly you need to add <text> labels for each bit of information you want to display:
https://dev.fitbit.com/build/guides/user-interface/svg/#text
Then you can put an ID on each <text> element, and use CSS to position and style those <text> elements:
https://dev.fitbit.com/build/guides/user-interface/css/
Then in your code, you can get a handle on each <text> element by using document.getElementById()
https://dev.fitbit.com/build/guides/user-interface/javascript/#getelementbyid-
Now you just need to work out where to get the values you need, and put the values into each <text> element by doing: myThing.text = somevalue;
For example, the step count comes from here:
https://dev.fitbit.com/build/reference/device-api/user-activity/#variable-today-
There's an example of heart rate here:
https://dev.fitbit.com/build/guides/sensors/heart-rate/