AVSpeechSynthesizer was not working. it was working perfect before.
below is my code objective - c.
-(void)playVoiceMemoforMessageEVO:(NSString*)msg {
[[AVAudioSession sharedInstance]
overrideOutputAudioPort:AVAudioSessionPortOverrideSpeaker
error:nil];
AVSpeechSynthesizer *synthesizer = [[AVSpeechSynthesizer alloc]init];
AVSpeechUtterance *speechutt = [AVSpeechUtterance speechUtteranceWithString:msg];
speechutt.volume=90.0f;
speechutt.rate=0.50f;
speechutt.pitchMultiplier=0.80f;
[speechutt setRate:0.3f];
speechutt.voice = [AVSpeechSynthesisVoice voiceWithLanguage:@"en-us"];
[synthesizer speakUtterance:speechutt];
} please help me to solve this issue.