10-14-2017 19:51 - edited 10-14-2017 19:52
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-14-2017 19:51 - edited 10-14-2017 19:52
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
The guide advises that the geolocation.watchPosition's callback "is called each time the location changes."
In a continuously moving environment (e.g. a racing yacht) the location is changing continuously, which casts doubt on that. My questions are:
- Is the callback actually called every second, on the second?
- is the timestamp actually the raw GPS timestamp? ( I ask, because some other devices:
actually report the device's system time)
- What is the reported precision of the latitude/longitude/speed/heading coordinates, i.e. how many decimals are reported?
- Do the speed and heading coordinates come from the GPS sub-system or are they derived from the time and distance in the firmware?
10-15-2017 19:49
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-15-2017 19:49
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
Interested in answers as well, and in the same context of the moving yacht.
10-20-2017 12:44
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-20-2017 12:44
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Can a developer please do some simple tests to answer some of this question?

10-21-2017 15:37
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-21-2017 15:37
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I am interested in hearing more as well. I could not get watchposition to work, based on the example in the guide. Geolocation works, but watchposition does not export data. If someone is looking into this, can you let me know if I should change something from the example?

10-21-2017 18:21 - edited 10-21-2017 18:22
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-21-2017 18:21 - edited 10-21-2017 18:22
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
@agsurf5 wrote:I am interested in hearing more as well. I could not get watchposition to work,
So what did you get? Could you post your code and its results?

10-22-2017 04:22
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-22-2017 04:22
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
I used the code from the guide:
https://dev.fitbit.com/guides/geolocation/#monitoring-the-current-location
Can an get the coordinates for getCurrentPosition, but not for watchPosition
10-22-2017 04:29 - edited 10-22-2017 04:53
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-22-2017 04:29 - edited 10-22-2017 04:53
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
do you get anything from your loctionSuccess function?
function locationSuccess(position) { console.log("Latitude: " + position.coords.latitude, "Longitude: " + position.coords.longitude); }
Reading the Guide it seems you should only get a response "...each time the location changes." Which contradicts the Reference on watchPosition() :"Request that the system monitor the position continuously and report position updates as available"
I wonder what is really going on?

10-22-2017 07:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-22-2017 07:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
WatchPosition is blank for me. Neither location nor error

10-23-2017 16:28
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


10-23-2017 16:28
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
There is definitely a bug with watchPosition(), I've escalated this with the firmware team.
- Is the callback actually called every second, on the second?
This depends upon how you configure the options. See below. - is the timestamp actually the raw GPS timestamp? ( I ask, because some other devices:
actually report the device's system time)
This is the GPS timestamp. - What is the reported precision of the latitude/longitude/speed/heading coordinates, i.e. how many decimals are reported?
{
"coords":{
"accuracy":49.9,
"latitude":51.724331666666664,
"longitude":-4.508001666666667,
"altitude":41,
"altitudeAccuracy":null,
"heading":1.32,
"speed":0.86426592
},
"timestamp":1508801196000
} - Do the speed and heading coordinates come from the GPS sub-system or are they derived from the time and distance in the firmware?
From the GPS, as far as I know.
The API is designed in partity with:
https://developer.mozilla.org/en-US/docs/Web/API/Geolocation

10-23-2017 16:53 - edited 10-23-2017 16:54
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

10-23-2017 16:53 - edited 10-23-2017 16:54
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
@JonFitbit wrote:
- Is the callback actually called every second, on the second?
This depends upon how you configure the options. See below.
I didn't see any ref to configure the options.
And what is the nature of the bug you have escalated?

10-24-2017 05:47
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


10-24-2017 05:47
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
@raceQs wrote:
@JonFitbit wrote:
- Is the callback actually called every second, on the second?
This depends upon how you configure the options. See below.I didn't see any ref to configure the options.
And what is the nature of the bug you have escalated?
The options were on the link, sorry https://developer.mozilla.org/en-US/docs/Web/API/PositionOptions
The bug is that watchPosition() doesn't seem to be working.
