iDevGames Forums
AVAudioPlayer - Printable Version

+- iDevGames Forums (http://www.idevgames.com/forums)
+-- Forum: Development Zone (/forum-3.html)
+--- Forum: iPhone, iPad & iPod Game Development (/forum-11.html)
+--- Thread: AVAudioPlayer (/thread-7958.html)



AVAudioPlayer - kae_ - Aug 7, 2010 06:16 PM

Anyone tried to use the AVAudioPlayer class on the iPhone OS4.0 simulator ? I get this error when running the simulator:
AddRunningClient starting device on non-zero client count

The strange thing is that it works fine on the device and on the iPad simulator. My device (iPhone) is also running OS4. I've also tried other apps (Apple's avTouch and 71squared's SoundManager among others) which uses AVAudioPlayer, but I get the same error. I've also tried compiling them on both my Mac's with the same result, so it can't be anything wrong with my system either.
I've been searching for this topic all day and tried everything to fix it, but with no luck.
Anyone recognize that errormessage and know what it means ?

Thanks Smile


RE: AVAudioPlayer - EvolPenguin - Aug 7, 2010 08:52 PM

I have had this in my console log when using the AVAudioRecorder on the simulator, however, it does end up functioning after a small delay (~4-5 seconds). Have you tried waiting?
Alex


RE: AVAudioPlayer - AnotherJake - Aug 7, 2010 11:31 PM

I got this error on iOS 4 simulator side too. Without trying to suggest anything negative about how much we've inadvertently suffered at the hands of the audio engineering department at Apple, and realizing that what you see in the simulator doesn't count toward final app approval (presumably), we took a chance and submitted our latest update and it passed the magic wand test ... wink wink, nudge nudge Wink


RE: AVAudioPlayer - kae_ - Aug 8, 2010 02:32 AM

(Aug 7, 2010 08:52 PM)EvolPenguin Wrote:  I have had this in my console log when using the AVAudioRecorder on the simulator, however, it does end up functioning after a small delay (~4-5 seconds). Have you tried waiting?
Alex

Nope, nothing. Its pretty frustrating. The error message tells me nothing and I've searched all over the web, but still haven't found any real info about it. Found alot of people with the same problem, but no solution. I guess I'll have to use the iPad simulator while developing and test on my real iPhone more often and try to pretend that it doesn't bother me that much.. argh! Smile

(Aug 7, 2010 11:31 PM)AnotherJake Wrote:  I got this error on iOS 4 simulator side too. Without trying to suggest anything negative about how much we've inadvertently suffered at the hands of the audio engineering department at Apple, and realizing that what you see in the simulator doesn't count toward final app approval (presumably), we took a chance and submitted our latest update and it passed the magic wand test

Its strange that even their avTouch example doesn't work. I mean, they must have noticed that. This can't just be a local thing as there are lots of people out there with the same cryptic error and I have it on both my Macs. XCode 4 didn't help much either Sad


RE: AVAudioPlayer - kae_ - Aug 8, 2010 04:17 AM

I've filed a bug over at bugreports.apple.com and I'll see what happens... probably nothing.


RE: AVAudioPlayer - EvolPenguin - Aug 8, 2010 05:51 PM

Oh well, device testing is better regardless. Are you using the beta sdk?
Alex


RE: AVAudioPlayer - kae_ - Aug 9, 2010 05:10 AM

(Aug 8, 2010 05:51 PM)EvolPenguin Wrote:  Oh well, device testing is better regardless. Are you using the beta sdk?
Alex

Tested with 3.2.3, 3.2.4 & 4 beta at home (MacBook & Mac pro). Same problem with all of them. Just tested it on my Mac pro (3.2.3) at work and get the same weird message there, but atleast it starts to play.


RE: AVAudioPlayer - EvolPenguin - Aug 9, 2010 08:29 AM

Yeah, that has been my experience. I get the message then it plays/records fine. Oh well.
Alex
Edit: Are you using initWithData: or initWithURL: for you AVAudioPlayer? Mine are all initWithData


RE: AVAudioPlayer - kae_ - Aug 10, 2010 04:13 AM

(Aug 9, 2010 08:29 AM)EvolPenguin Wrote:  Yeah, that has been my experience. I get the message then it plays/records fine. Oh well.
Alex
Edit: Are you using initWithData: or initWithURL: for you AVAudioPlayer? Mine are all initWithData

I'm using initWithData too. Easier to switch to asynchronous loading later on i think.