Class

INSetAudioSourceInCarIntent

A request to change the source of audio playback in a CarPlay-enabled vehicle.

Overview

Automotive venders can add support for this intent to an Intents extension that they ship with their automotive apps. When the user asks Siri to change the audio source of the vehicle, SiriKit creates an INSetAudioSourceInCarIntent object and delivers it to your app’s Intents extension. You use the intent to identify which audio source the user wants to use and to communicate the new audio source information directly to your vehicle’s systems.

Users may select audio sources by name or by asking for the next or previous audio source that is available. When the user asks for an audio source by name, Siri populates the audioSource property of this intent object with the specific source that was requested. When the user asks for the next or previous audio source, Siri places the appropriate value in the relativeAudioSourceReference property so that you can determine which audio source to select. Only one of these properties contains usable information; the other is set to a constant indicating an unknown status for the value.

The object that handles this intent must adopt the INSetAudioSourceInCarIntentHandling protocol. Use this intent object to resolve the audio source details and to create an INSetAudioSourceInCarIntentResponse object indicating the results of changing the audio source.

For a list of other intents in the CarPlay domain, see INCarPlayDomainHandling.

Additional Intent Attributes

Table 1 lists additional attributes of this intent object.

Table 1

Set audio source in car intent attributes

Attribute

Description

Supported by

Siri (in conjunction with CarPlay)

Always requires unlocked device

No

Example Phrases

There are many ways in which users can ask Siri to change the audio source in a vehicle. Table 2 provides a few sample phrases in different languages. You can use these phrases during testing to trigger your intents. This list is not exhaustive and Siri may recognize many other phrases.

Table 2

Siri phrases that trigger the changing of a vehicle’s audio source

Locale

Example 1

Example 2

en

Change the audio source to USB

Switch to the next audio source

zh_CN

音源USB

切换音源

zh_HK

音源較去USB

切換音源

zh_TW

切換到USB

切換音源

yue_CN

音源较去USB

切换音源

ar

تغيير مصدر الصوت

تبديل إلى مصدر الصوت التالي

da

aux lydkilde

Skift til næste lydindgang

de

Wechsele die Audioquelle auf USB

Die Audioquelle auf USB wechseln

es

Cambia la fuente de audio al USB

Pon la fuente de sonido al DVD

fi

Aseta äänilähteeksi USB

Vaihda seuraavaan äänilähteeseen

fr

Change l’entrée audio sur auxiliaire

he

תחליפי את מקור אודיו

תחליפי את מקור האודיו

it

Cambia la sorgente audio a USB

Cambia alla prossima sorgente audio

ja

音源をUSBに変更

次の音源に切り替えて

ko

오디오 소스를 USB로 변경

다음 오디오 소스로 바꿔줘

ms

Tukar sumber audio kepada USB

Tukar kepada sumber audio berikutnya

nb

Endre lydkilde til USB

Bytt til neste lydkilde

nl

Verander de audiobron naar USB

Schakel naar de volgende audiobron

pt

Mudar a entrada de áudio para USB

Troque para a próxima entrada de áudio

ru

Измени источник аудио на USB

Переключи на следующий источник музыки

sv

ändra ljudkälla till aux

byt ljudkälla till aux ljud

th

เปลี่ยนแหล่งเสียงเป็น USB

เปลี่ยนเป็นแหล่งเสียงถัดไป

tr

Ses kaynağı USB olsun

Bir sonraki ses kaynağına geç

When managing CarPlay features, users do not need to include the name of the app in the phrases that they speak. Siri knows automatically when CarPlay is active and routes CarPlay-related intents to the app of the corresponding automotive vendor.

Topics

Initializing the Intent Object

init(audioSource: INCarAudioSource, relativeAudioSourceReference: INRelativeReference)

Initializes the intent object with the specified audio source information.

Getting Details About the Audio Source to Set

var audioSource: INCarAudioSource

The audio source to select.

var relativeAudioSourceReference: INRelativeReference

The relative audio source to select.

Relationships

Inherits From

Conforms To

See Also

Set Audio Source in Car

protocol INSetAudioSourceInCarIntentHandling

The handler interface for changing a vehicle’s audio source.

class INSetAudioSourceInCarIntentResponse

Your app’s response to a set audio source in car intent.