Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

When does BikeTrax record the Positions / Trips?
Which parameters determines a complete ride in the powunity app?

The tracker always records, even if it is only moved 10m. If you use the /positions API then you always get all the positions that the tracker has sent for the period.

But there is a difference in when the server (or the app) detect and show it as a trip (via the /trips API). The following parameters are used in the detection algorithm:

  • minimal trip duration - Trips of less than 130 seconds are ignored.

  • minimal trip distance - Trips of less than 215 meters are ignored.

  • minimal parking duration - Parking for less than five minutes does not detected as stop.

  • minimal no data duration - Gaps in reported positions longer than one hour are considered as stops.

  • ignition - Force switch to stop state if eBike is switched off.

Following is an example to illustrate how it works:

Trip 1 is detected correctly, because the period started from zero speed (initialized as stopped), the distance is longer than 215 meters or the duration is longer than 130 seconds, and it is followed by a stop longer than minimal parking duration.

Stop 1 is detected because it has a duration longer than the minimal parking duration and the speed is close to zero.

Trip 2 is also detected correctly from row 27 on, rows 24-25 are ignored as fluctuation. Parameters are more than minimal, and it started and followed by positions with zero speed.

Why and how straight lines occur and what does it imply on the status of the tracker?

If the bike is located in a garage (without GPS reception) and is immediately driven away from there, the GPS needs longer until it gets a position and the start / first position is then correspondingly later. This is because the GPS fix can take up to one minute, especially if the tracker is moving.

How are Alarms / Push Notifications deliverd?

There are two ways how the push notification (which triggers the sound) is handled by the app depending on it’s state:

  1. The app is in the background (or not running):
    none of our app code is run -> the push is handled only by the OS / browser. In that case the alarm will only sound for a few seconds and then stop - unless the backend / server sends another push because the device is still moving and movement alarm was triggered again.

  2. The app is in the foreground:
    Notification is handled by our app code and we start playing the alarm sound in a loop until the user switches if off (by toggling the alarm button).

  • No labels