I get a MediaException (Prefetch error: -5) when executing the following code on a Nokia N73. It runs fine in the emulator and I have tried the same thing before on the same phone successfully. The only difference now is that I am using NetBeans to build and deploy rather than Eclipse.
inputPlayer = Manager.createPlayer("capture://audio?encoding=pcm&rate=4000&bits=16&channels=1");
inputPlayer.realize();
inputPlayer.prefetch();
inputPlayer.start();
I am wondering whether it is security related, as with Eclipse I always got a security prompt on the phone. With NetBeans I do not get any prompt, just the Exception.