We are not able to use some of the more standard ways of handling interruptions. I've registered an audio callback, and when Siri interrupts, the best way to keep her from crashing my app is to temporarily disable my audio device. The problem, though, is that when I restart the audio device, the audio is coming back very distorted. Is this an issue that you have come across when dealing with Siri?
//Stop the audio device during an interruption
void AudioModule::removeAudioCallback()
{
m_deviceManager->removeAudioCallback(m_audioIO);
m_deviceManager->closeAudioDevice();
}
//Restart the audio device after an interruption
void AudioModule::addAudioCallback()
{
m_deviceManager->restartLastAudioDevice();
m_deviceManager->addAudioCallback(m_audioIO);
}
