This will open an audio pass thru session. By doing so the app can receive audio data through the vehicle microphone
Function Group: AudioPassThru
HMILevel needs to be FULL, LIMITED or BACKGROUND
Since SmartDeviceLink 2.0
See SDLEndAudioPassThru
Convenience init to perform an audio pass thru
- (nonnull instancetype)
initWithSamplingRate:(nonnull SDLSamplingRate)samplingRate
bitsPerSample:(nonnull SDLBitsPerSample)bitsPerSample
audioType:(nonnull SDLAudioType)audioType
maxDuration:(UInt32)maxDuration;
init(samplingRate: SDLSamplingRate, bitsPerSample: SDLBitsPerSample, audioType: SDLAudioType, maxDuration: UInt32)
A samplingRate
The quality the audio is recorded - 8 bit or 16 bit
An audioType
The maximum duration of audio recording in milliseconds
Convenience init to perform an audio pass thru
- (nonnull instancetype)
initWithInitialPrompt:(nullable NSString *)initialPrompt
audioPassThruDisplayText1:(nullable NSString *)audioPassThruDisplayText1
audioPassThruDisplayText2:(nullable NSString *)audioPassThruDisplayText2
samplingRate:(nonnull SDLSamplingRate)samplingRate
bitsPerSample:(nonnull SDLBitsPerSample)bitsPerSample
audioType:(nonnull SDLAudioType)audioType
maxDuration:(UInt32)maxDuration
muteAudio:(BOOL)muteAudio;
init(initialPrompt: String?, audioPassThruDisplayText1: String?, audioPassThruDisplayText2: String?, samplingRate: SDLSamplingRate, bitsPerSample: SDLBitsPerSample, audioType: SDLAudioType, maxDuration: UInt32, muteAudio: Bool)
Initial prompt which will be spoken before opening the audio pass thru session by SDL
A line of text displayed during audio capture
A line of text displayed during audio capture
A samplingRate
The quality the audio is recorded - 8 bit or 16 bit
An audioType
The maximum duration of audio recording in milliseconds
A Boolean value representing if the current audio source should be muted during the APT session
Convenience init to perform an audio pass thru
- (nonnull instancetype)
initWithSamplingRate:(nonnull SDLSamplingRate)samplingRate
bitsPerSample:(nonnull SDLBitsPerSample)bitsPerSample
audioType:(nonnull SDLAudioType)audioType
maxDuration:(UInt32)maxDuration
audioDataHandler:(nullable SDLAudioPassThruHandler)audioDataHandler;
init(samplingRate: SDLSamplingRate, bitsPerSample: SDLBitsPerSample, audioType: SDLAudioType, maxDuration: UInt32, audioDataHandler: SDLAudioPassThruHandler? = nil)
A samplingRate
The quality the audio is recorded - 8 bit or 16 bit
An audioType
The maximum duration of audio recording in milliseconds
A handler that will be called whenever an onAudioPassThru notification is received.
- (nonnull instancetype)
initWithInitialPrompt:(nullable NSString *)initialPrompt
audioPassThruDisplayText1:(nullable NSString *)audioPassThruDisplayText1
audioPassThruDisplayText2:(nullable NSString *)audioPassThruDisplayText2
samplingRate:(nonnull SDLSamplingRate)samplingRate
bitsPerSample:(nonnull SDLBitsPerSample)bitsPerSample
audioType:(nonnull SDLAudioType)audioType
maxDuration:(UInt32)maxDuration
muteAudio:(BOOL)muteAudio
audioDataHandler:
(nullable SDLAudioPassThruHandler)audioDataHandler;
init(initialPrompt: String?, audioPassThruDisplayText1: String?, audioPassThruDisplayText2: String?, samplingRate: SDLSamplingRate, bitsPerSample: SDLBitsPerSample, audioType: SDLAudioType, maxDuration: UInt32, muteAudio: Bool, audioDataHandler: SDLAudioPassThruHandler? = nil)
A line of text displayed during audio capture
A line of text displayed during audio capture
A samplingRate
The quality the audio is recorded - 8 bit or 16 bit
An audioType
The maximum duration of audio recording in milliseconds
A Boolean value representing if the current audio source should be muted during the APT session
A handler that will be called whenever an onAudioPassThru notification is received.
initial prompt which will be spoken before opening the audio pass
thru session by SDL
@discussion initialPrompt
a Vector
Notes:
@property (nonatomic, strong, nullable) NSArray<SDLTTSChunk *> *initialPrompt;
var initialPrompt: [SDLTTSChunk]? { get set }
a line of text displayed during audio capture @discussion audioPassThruDisplayText1 a String value representing the line of text displayed during audio capture
Notes: Maxlength=500
@property (nonatomic, strong, nullable) NSString *audioPassThruDisplayText1;
var audioPassThruDisplayText1: String? { get set }
A line of text displayed during audio capture @discussion audioPassThruDisplayText2 a String value representing the line of text displayed during audio capture
Notes: Maxlength=500
@property (nonatomic, strong, nullable) NSString *audioPassThruDisplayText2;
var audioPassThruDisplayText2: String? { get set }
A samplingRate
@discussion a SamplingRate value representing a 8 or 16 or 22 or 24 khz
@property (nonatomic, strong) SDLSamplingRate _Nonnull samplingRate;
var samplingRate: SDLSamplingRate { get set }
the maximum duration of audio recording in milliseconds
@discussion maxDuration an Integer value representing the maximum duration of audio recording in millisecond
Notes: Minvalue:1; Maxvalue:1000000
@property (nonatomic, strong) NSNumber<SDLInt> *_Nonnull maxDuration;
var maxDuration: NSNumber & SDLInt { get set }
the quality the audio is recorded - 8 bit or 16 bit
@discussion a BitsPerSample value representing 8 bit or 16 bit
@property (nonatomic, strong) SDLBitsPerSample _Nonnull bitsPerSample;
var bitsPerSample: SDLBitsPerSample { get set }
an audioType
@property (nonatomic, strong) SDLAudioType _Nonnull audioType;
var audioType: SDLAudioType { get set }
a Boolean value representing if the current audio source should be
muted during the APT session
@property (nonatomic, strong, nullable) NSNumber<SDLBool> *muteAudio;
var muteAudio: (NSNumber & SDLBool)? { get set }
A handler that will be called whenever an onAudioPassThru
notification is received.
@property (nonatomic, strong, nullable) SDLAudioPassThruHandler audioDataHandler;
var audioDataHandler: SDLAudioPassThruHandler? { get set }