Turn-by-turn instructions

VERSION 0.3.34
PUBLIC PREVIEW

Navigation SDK for Android is only available upon request. Contact us to get started.

To use route in a turn-by-turn navigation context, it is required to include selected options when creating a request. The most impactful parameters are summarised below. An example of routing options that can be used for this purpose is as follows:

1val amsterdam = GeoCoordinate(52.377956, 4.897070)
2val rotterdam = GeoCoordinate(51.926517, 4.462456)
3val routingOptions = RoutingOptions.Builder(itinerary = Itinerary(amsterdam, rotterdam))
4 .instructionType(InstructionType.TAGGED)
5 .instructionAnnouncementPoints(AnnouncementPoints.ALL)
6 .instructionPhonetics(InstructionPhoneticsType.IPA)
7 .sectionTypes(listOf(SectionType.LANES, SectionType.SPEED_LIMIT, SectionType.MOTORWAY))
8 .language(Locale.ENGLISH)
9 .build()

Vehicle heading

Once driving, it’s important to request a route in a specific direction. For that purpose, the vehicleHeading parameter should be used. It describes the directional heading of the vehicle, in degrees starting at true North and continuing in a clockwise direction:

  • North is 0 degrees.
  • East is 90 degrees.
  • South is 180 degrees.
  • West is 270 degrees.

Instructions

To obtain guidance instructions, the instructionsType needs to be set. Possible values are:

  • CODED - returns raw instruction data without human-readable messages.
  • TEXT - returns raw instructions data with human-readable messages in plain text.
  • TAGGED - returns raw instruction data with tagged human-readable messages to permit formatting.

If alternative routes are requested, instructions will be generated for each route returned.

Announcement points

The instructionAnnouncementPoints parameter specifies whether to include announcement points in instructions. If specified, the instruction will include up to three additional fine-grained announcement points, each with their own location, maneuver type, and distance to the instruction point. Based on that, the navigation system can decide at which point of time the audio messages should be played. Possible values are:

  • NONE - Do not include instruction announcement points in instructions.
  • ALL - Include instruction announcement points in instructions, exposing the following instruction fields, where applicable:
    • earlyWarningAnnouncement
    • mainAnnouncement
    • confirmationAnnouncement

Phonetics

The instructionPhonetics parameter specifies whether to include the phonetic transcription of street names, signpost text, and road numbers in the instructions of the response. In areas where phonetic information is not available, the result will not be returned. Possible values are:

  • NONE - Do not include phonetic transcriptions in the Response.
  • LHP - Return phonetic transcriptions in the L&H+ format from Cerence Inc.
  • IPA - Return phonetic transcriptions in the IPA (International Phonetic Alphabet).

Route sections

The sectionTypes parameter specifies which of the section types is reported in the route response. More details about available route sections are described here.

To get the best turn-by-turn experience, it’s required to include the following sections when planning a route: