09-07-2019 16:38 - edited 09-07-2019 16:38
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

09-07-2019 16:38 - edited 09-07-2019 16:38
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
Sometimes when my fitbit clockface loses sync because the messaging peersocket stops opening (i'm speculating) the only way to resume normal operations is to swipe left, load a timer or any app, then return to clockface to reload. Most of the time that gets the messaging peersocket communication going again and all is well. What I would like to do is have my clockface detect when messaging fails a certain number of times, and then in code, perform some version of the unloading and reloading of the clockface to get the messaging working again. I saw the launchapp system function. What I need is a clockface restart function. Or if there is an easier way to achieve this...I'm interested.
09-10-2019 01:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


09-10-2019 01:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
You shouldn't need to, but you can exit your app using the AppBit API https://dev.fitbit.com/build/reference/device-api/appbit/

09-10-2019 13:01 - edited 09-10-2019 13:03
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

09-10-2019 13:01 - edited 09-10-2019 13:03
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Woohoo, JonFitbit is back! Do you know if Appbit would work for restarting clockfaces? Kind of academic now...I've since come up with a solution for switching from messaging - when that becomes problematic - to getting by on file transfers to keep things going (but that is dependent on the companion waking every 5min), and then continuing that way until the messaging peersocket is detected as onOpen...then the clockface resumes the messaging function to the companion - which I prefer because it keeps the companion awake. So, your thoughts on that would be interesting.
Also, 1. why not give developers control over the waking of the companion? Why limit it to 5min?
2. I believe file transfers don't wake the companion. Could that be an option? 3. the messaging.peersocket.onopen on the app...that only fires once right? I'm listening for onopen and onclose and onerror...and I've seen it open (my latest version of Sentinel X is quite well today), I've seen it close when I intentionally walk out of bluetooth range (testing), never seen error, and I've never seen it snap back open when coming back in range. It would be really cool if it could do that. Right now it seems like the peersocket closes, and then despite coming back in range, I'm at the mercy of the 5min companion wake timer...which isn't bad. But could be a little better. Took me 5 long months to get here. Haha. Just giving feedback. Thanks.

09-11-2019 04:47
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


09-11-2019 04:47
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Yes, I'm back, I've been focused on the Versa2 launch 🙂
It should work for clocks, but the system would automatically relaunch the clock again.
Companion lifecycle is tricky because of how mobile phones treat long running applications. The Fitbit app has to be a good citizen.
I don't think file transfers will wake the companion, but a peersocket message should.

09-21-2019 08:27
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

09-21-2019 08:27
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
@JonFitbit wrote:I don't think file transfers will wake the companion, but a peersocket message should.
The problem is, if the peersocket connection is closed, you have no control on reconnections since it's done automatically. From my observations, connections get closed for no apparent reason (watch is within bt range) and it often won't reconnect itself. The best option is to simply restart the watchface app.

09-21-2019 12:31
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

09-21-2019 12:31
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I guess my aim is to understand the various points of failure and to design the clockface to recognize those moments and to recover and resume normal operation. That's the goal. Especially when the end-user is a 1st grade elementary school child like my son...they can't be expected to troubleshoot their watch throughout the school day...so I continue to search for ways to make things better and easier.

10-06-2019 13:58
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-06-2019 13:58
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I've basically put all my concerns on hold. I see bits and pieces that OS 4 and/or the new watch firmwares will create more stability, more reliable comms. I hope that is the case. I told my Facebook group to basically sit tight and they all appreciate the situation. Lot of pressure and hype for OS 4 though....good luck Fitbit, I hope you stick the landing. Despite the negativity in this forum, a lot of us want you to succeed.

