I have a standard mp3 stream that is delivered through http. I use the approach used in this example project:
https://github.com/mattgallagher/AudioStreamer/
Basically it uses the approach described in Apples "Audio Stream Reference". If I set UIBackgroundModes
to audio
iOS plays the sound if the app is in the background.
But how can I make the iPod controls in the taskbar work? How can I integrate properly with iPod on iOS?
The controls in the taskbar fire remote-control events (for example like controls that are integrated into the head phones). If you follow the instructions described in Apples documentation Remote Control of Multimedia and set UIBackgroundModes
to audio
, then everything behaves as expected: If the app is suspended the sound continues to play, you app icon appears in the iPod menu in the taskbar and the buttons trigger events.