Problem accessing Android MIC
I have been reading the microphone class, and I cannot figure out why this code is not tracing anything out:
var mic:Microphone = Microphone.getMicrophone();
mic.gain = 100;
mic.rate = 44;
mic.setSilenceLevel(0, 6000);
mic.addEventListener(SampleDataEvent.SAMPLE_DATA, micSampleDataHandler);
private function micSampleDataHandler(event:SampleDataEvent):void{
log("Recording");
}
according to the adobe help files this is alls that is needed to actually speak into the mic and have it know you are doing so. But I cannot get the micSampleDataHandler to fire at all when whispering, talking, or screaming into the phone.
Am I missing something?
