tags:

views:

128

answers:

1

I released an iPhone application a few months ago. Everything has been working fine and I have confirmed at least 20 different devices/users working flawlessly. In the last week though I've had two reports have people hear no audio (it's a soundboard app). I've been able to dialog with one of the guys and confirmed that the phone wasn't in vibrate mode and the volume was up. He's on the same firmware version I am 2.2.1, but his phone model is slightly different mb704ll vs mine mb048ll.

I'm using the AVFoundation/AVAudioPlayer to play the sounds (code snip below):

- (IBAction)imagePressed:(id)sender
{
    NSString *imageIdS = [NSString stringWithFormat:@"%d", [sender tag]];
    NSString *path = [[NSBundle mainBundle] pathForResource:imageIdS ofType:@"caf"];
    AVAudioPlayer *audioPlayer = [[AVAudioPlayer alloc] initWithContentsOfURL:[NSURL fileURLWithPath:path] error:NULL];
    [audioPlayer play];
    //[audioPlayer release];
}

Do you know of any reason why this works on so many phones but a few people are having issues?

Thanks in advance!

+1  A: 

Maybe you're not handling Audio session interruptions.

Rhythmic Fistman