Setting Up Safe Driving
Configuring safe driving mode
Without setting a destination or route, receive guidance on surrounding information centered on your current location. After calling initWithGuidance(), you receive the guidanceDidUpdateSafetyGuide() and guidanceDidUpdateAroundSafeties() callbacks.
Up to three surrounding safety items are displayed at the top left of the screen.
TIP
In the current safe driving mode, only some services such as location, speed, and speeding warnings are supported.
When safe driving mode is disabled, the route is set to the value assigned within initWithGuidance().
kotlin
// Set safe driving mode
KNSDK.sharedGuidance()?.apply {
guideStateDelegate = this@NaviActivity
locationGuideDelegate = this@NaviActivity
routeGuideDelegate = this@NaviActivity
safetyGuideDelegate = this@NaviActivity
voiceGuideDelegate = this@NaviActivity
citsGuideDelegate = this@NaviActivity
naviView.guideStateDelegate = this@NaviActivity
naviView.mapComponent.mapView.isVisibleTraffic = true
naviView.initWithGuidance(
this,
null,
KNRoutePriority.KNRoutePriority_Recommand,
KNRouteAvoidOption.KNRouteAvoidOption_None.value
)
}