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

Tutorial for looping .pngs on watch face to make it like a gif.

Hey folks, 

 

As the subject says, i'm creating a Fallout themed watch face, and I'm trying to get a walking pip boy when i'm showing my current steps. I have the gif broken into separate .pngs, but I don't know the code to loop them. 

 

Thanks!

Best Answer
0 Votes
4 REPLIES 4

@A_handcannon Welcome to the Fitbit forums! I moved your post to the SDK Board as there are more chances for you to receive an answer to your inquiry here. 

 

I'm sure that users that check this board often will be able to answer your question. By being here on this board, I;m sure it will not take long to receive an answer.

 

See you around! Smiley Happy

Santi | Community Moderator, Fitbit

Like my response? Vote for it! Also, accept as solution!

Best Answer
0 Votes

I am no experienced Javascript developer - and I think there are very many fallpits.

 

From the sample in https://github.com/Fitbit/sdk-bart/blob/master/app/index.js at least you could find this segment:

 

 

setInterval(function() {
  console.log("BART App running - Connectivity status=" + messaging.peerSocket.readyState +
              " Connected? " + (messaging.peerSocket.readyState == messaging.peerSocket.OPEN ? "YES" : "no"));
}, 3000);

 

It gives a hint that you can set an interval, and make repeated calls. So if you replace the logging line with a call to a function that iterate through your pictures, maybe you'll succeed.

 

The bart sample also has example showing two different pictures depending if a train allows bicycles or not. https://github.com/Fitbit/sdk-bart

Best Answer
0 Votes

There's also a guide on the website about the different ways to create animations https://dev.fitbit.com/build/guides/user-interface/animations/

Best Answer
0 Votes

@JonFitbit do those animation features (scaling/rotation) work on image tags too?

Best Answer
0 Votes