Follow

Itinerary long-haul guided routes

1. About Itinerary Long-haul routes

Itinerary long-haul routes (a.k.a precomputed routes) is the feature, which allows Sygic navigation to load the routes created in an external system. This type of routes is primarily meant for long-haul navigation, and it is a category of guided routes.
Guided route is basically a sequence of GPS positions, typically extended with waypoints indicating significant points on route (typically pickup/delivery points). Such routes can be loaded into navigation using the SDK function LoadComputedRoute.
Sygic navigation internally runs the route approximation algorithm, which performs map matching of that GPS sequence to currently installed Sygic maps to generate a navigable route. Once the route is generated Sygic navigation follows the route in a magnetic way.

2. Feature characteristics

Waypoints and Points

The route structure is defined with the waypoints and points (a.k.a magnetics points).
The waypoints must be visited as they typically define significant points for customer visit, or pickup/delivery points. The visit is acknowledged when vehicles passes its GPS position with the sufficient proximity (radius in meters is set to 50 meters and adaptively increased with a vehicle speed). If a waypoint is not visited with a sufficient proximity you may encounter navigation recalculations asserting on passing the waypoint position on and on (unless you apply the explicit operation skip waypoint).
On the contrary magnetic points only define a desired prescription of the routing and there is no such thing as radius definition for them. Navigation tries to do its best to follow directions of the magnetic points but there is no obligation to pass them with a predefined vicinity. If a driver makes a deviation on the route (by mistake or deliberately due to some obstacle) the navigation tries its best to get driver back on route with the possible outcome that some magnetic points were automatically skipped.

Waypoint types

Our precomputed route format currently supports only the template START – VIA ... VIA – DEST, where START and DEST are mandatory, and you may have 0 to many VIA waypoints.
The assumption is that START is a vehicle‘s current position, typically represented by a depot. And the first VIA is actually the first customer to be visited for pickup or delivery.
DEST might be considered as the last customer for visit, or a depot for vehicle.

Start waypoint

START is a specially handled waypoint, which does not need to be defined with a high precision. Actually it is also ok if it is relatively far from a real start.

During the execution of a route by Sygic navigation the start is replaced with an actual GPS position once the Sygic navigation app gets a GPS fix. This means that if your originally defined START position is close to the actual GPS position everything looks perfect. In case the originally defined START position is far from the actual GPS position then the route to the first VIA point might be significantly recalculated, but we consider this as a desired behavior.

So in short, during the navigation execution START is basically dropped and it is replaced by an actual GPS position. The importance of the START to be realistically defined is that you can calculate your route costs in office through your route planner, where you should make some assumptions where your vehicle is currently located (that is START).

Truck attributes

The Sygic route import algorithm (approximation) originally ignores truck parameters. We make the assumption that the computed route comes from a system that can compute truck routes, like PTV. Of course, when a driver deviates from the route and the navigation searches for a way how to join back the original route, it takes the truck restrictions into account.

3. Approximation criteria

Since the input GPS sequence can be of a various precision it is not always possible to finish approximation successfully.
It is always best if the precision of GPS sequencing is maximally close to the position of Sygic maps.
The ideal situation is if the route generated from the external system and Sygic navigation use the same maps (map provider and version release), e.g. Tomtom or Here.
At the same time it is also important that there are no big distances between consecutive gps points.

For successful approximation we define the following criteria:

  • the distance period between two consecutive GPS points should not exceed 200m
    This obviously is more important around complex crossings.
    On highways and long non-intersection roads the condition can be relaxed.
    Based on our experiences the range 20m to 500m distances works well.
  • the error variance from the underlying Sygic maps should not exceed 20m
    This obviously is more important around complex crossings.
    On highways and long non-intersection roads the condition can be relaxed.

4. SDK supported functions

There is the SDK function LoadComputedRoute, through which the guided route (precomputed route) can be injected into navigation.
The function is currently available only in a special release, so please contact our sales.

The SDK library provides the following supporting functions:

Windows C#

  • int LoadComputedRoute(out SError error, string routeFilename, int maxTime )
  • int LoadComputedRoute(out SError error, string routeFilename, int startWaypointID, int maxTime )

Android Java

  • void loadComputedRoute(String routeFilename, int maxTime )
  • void loadComputedRoute(String routeFilename, int startWaypointID, int maxTime )

5. Route formats

Currently we support two formats: Sygic-native format (sif files) and PTV-compatible format.
Sygic SDK function automatically recognizes the used format.

 

5.1 PTV-compatible format

These files can be obtained through exports from PTV route calculation services, like xServer, etc.

The json specification of the supported structure:

The description of the json fields: 

Field Type Default value Description
x double n/a longitude position defined as WGS84 multiplied by 100,000
y double n/a latitude position defined as WGS84 multiplied by 100,000
polyIdx int n/a index reference to the points array defining the GPS point as the waypoint/station
WayPointType string  n/a the type of waypoint, possible values are START, VIA, DEST.

 

Example:

{
  "polygon": {
    "lineString": {
      "points": [
        {
          "x": 1712571,
          "y": 4814643
        },
        {
          "x": 1712486,
          "y": 4814651.5
        },
        {
          "x": 1712461,
          "y": 4814652
        },

...
        {
          "x": 1712302,
          "y": 4814263
        },
        {
          "x": 1712355,
          "y": 4814257
        },
        {
          "x": 1712468,
          "y": 4814248
        }
      ]
    }
  },
  "stations": [
    {
      "polyIdx": 0,
      "wayPointType": "START"
    },
    {
      "polyIdx": 44,
      "wayPointType": "VIA"
    },
    {
      "polyIdx": 83,
      "wayPointType": "DEST"
    }
  ]
}

 

5.2 Sygic-native format

The json specification of the supported structure (version 1.1) :

The description of the json fields:

Field Type Default value Description
name string "" route name appearing in route info dialog
description string "" route description appearing in route info dialog
version string n/a used version, currently available 1.0 and 1.1
lat int n/a latitude position defined as WGS84 multiplied by 100,000
lon int n/a longitude position defined as WGS84 multiplied by 100,000
type string n/a the type of the waypoint, possible values are start, via, finish.
waypointId int -1 user defined identification of the waypoint
id int -1 user defined identification of the road

 

Version history

Version Release date Change log
1.1 28.8.2016 1st official release
1.0 22.6.2016 beta release

 

Example:

{
"name":		"Route-77",
"version":	"1.1",
"routeParts":
   [{
		"waypointFrom":
		{
			"lat":	        4814951,		
			"lon":	        1711001,
			"type":	       	"start"
		},
		"waypointTo":
		{
			"lat":	       	 4814791,		
			"lon":	       	 1710751,
			"type":	       	 "via"
		}
		"roads":
		[
		  {  
		     "id": 1, 
		     "points": [ { lat: 4814952, lon: 1711002 }, { lat: 4814953, lon: 1711003 }, { lat: 4814954, lon: 1711004 } ]
		  },
		  {  "id": 2,
		     "points": [ { lat: 4814955, lon: 1711005 }, { lat: 4814956, lon: 1711006 }, { lat: 4814957, lon: 1711007 } ]
		  }
		  ...
		]
   },{
		"waypointTo":
		{
			"lat":	        4814391,
			"lon":	        1710371,			
			"type":	        "finish"
		}
		"roads":
		[
		  {  
		     "id": 25, 
		     "points": [ { lat: 4814791, lon: 1710751 }, { lat: 4814792, lon: 1710752 }, { lat: 4814793, lon: 1710753 }, ... ]
		  },
		  ...
		]		
   }]
}
Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments