prevent app from sleeping/ repeat sound

In the app delegate
[UIApplication sharedApplication].idleTimerDisabled = YES;

In the root view controller
self.player.numberOfLoops = -1;