Mobile navigation allows map partners to easily display their maps as well as present visual and audio turn-by-turn prompts on the head unit.
Navigation apps have different behavior on the head unit than normal applications. The main differences are:
The basic connection setup is similar for all apps. Please follow the Integration Basics guide for more information.
In order to create a navigation app an
SDLAppHMITypeNavigation must be set in the
The second difference is that a
SDLStreamingMediaConfiguration must be created and passed to the
SDLConfiguration. A property called
securityManagers must be set if connecting to a version of Core that requires secure video and audio streaming. This property requires an array of classes of security managers, which will conform to the
SDLSecurityType protocol. These security libraries are provided by the OEMs themselves, and will only work for that OEM. There is no general catch-all security library.
SDLLifecycleConfiguration* lifecycleConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:@"<#App Name#>" fullAppId:@"<#App Id#>"]; lifecycleConfig.appType = SDLAppHMITypeNavigation; SDLStreamingMediaConfiguration *streamingConfig = [SDLStreamingMediaConfiguration secureConfigurationWithSecurityManagers:@[OEMSecurityManager.class]]; SDLConfiguration *config = [SDLConfiguration configurationWithLifecycle:lifecycleConfig lockScreen:[SDLLockScreenConfiguration enabledConfiguration] logging:[SDLLogConfiguration defaultConfiguration] streamingMedia:streamingConfig fileManager:[SDLFileManagerConfiguration defaultConfiguration]];
let lifecycleConfig = SDLLifecycleConfiguration(appName: "<#App Name#>", fullAppId: "<#App Id#>") lifecycleConfig.appType = .navigation let streamingConfig = SDLStreamingMediaConfiguration(securityManagers: [OEMSecurityManager.self]) let config = SDLConfiguration(lifecycle: lifecycleConfig, lockScreen: .enabled(), logging: .default(), streamingMedia: streamingConfig, fileManager: .default())
When compiling your app for production, make sure to include all possible OEM security managers that you wish to support.
To present a keyboard (such as for searching for navigation destinations), you should use the
SDLScreenManager's keyboard presentation feature. For more information, see the Popup Menus and Keyboards guide.