-
Notifications
You must be signed in to change notification settings - Fork 14
Routing service
Since version 3.2.0, Locus Map offers possibility to implement own add-on that will supply complete routing for Locus Map navigation. The method is based on the Service and communication with Locus works thanks to AIDL interface.
It sounds complicated but best is to check an existing Locus add-on for Offline navigation, which serve also as sample application.
To add your own routing service to Locus, you need to
- install Locus API in your IDE and add dependency to your new/existing project. More in Locus API Installation.
- create MyRoutingService extends ComputeTrackService.
- register MyRoutingService in AndroidManifest.xml file
<service
android:name=".MyRoutingService"
android:label="My routing" >
<intent-filter>
<action
android:name="locus.api.android.ACTION_COMPUTE_TRACK_PROVIDER"/>
</intent-filter>
</service>
That's all. Locus Map will find your service thanks to defined action parameter and add it to the list of available routing engines. Right below the MapQuest, Yours and others.
RoutingService allows direct integration into Locus. Thanks to AIDL users won't be aware that they use independent add-on.
What is possible
- basic information - name, attribution
- ability to call “Settings” activity directly from Locus Map
- ability to compute track between requested points and return full track back to Locus with all navigation orders and required information for full voice navigation.
-
Basics
-
Non-API tools
-
Using API
-
Work with points
-
Work with tracks
-
Integration into Locus Map
-
Other/advanced features