Go Back   Android Forums > Android Development > Application Development
Application Development Dev lounge for our application developers.

test: Reply
 
LinkBack Thread Tools
Old May 25th, 2009, 03:05 PM   #1 (permalink)
New Member
Thread Author (OP)
 
Join Date: May 2009
Posts: 1
 
Device(s):
Carrier: Not Provided

Thanks: 0
Thanked 0 Times in 0 Posts
Default Error recording audio using native AudioRecord interface

Hi!

Has anyone been able to record audio using the native AudioRecord interface? I'm trying to do this on my Neo Freerunner but all I get in logcat is:

I/AudioHardwareALSA( 787): Initialized ALSA CAPTURE device AndroidRecord_Microphone
D/AudioHardwareALSA( 787): Set CAPTURE PCM format to S16_LE (Signed 16 bit Little Endian)
D/AudioHardwareALSA( 787): Using 1 channel for CAPTURE.
D/AudioHardwareALSA( 787): Set CAPTURE sample rate to 8000 HZ
E/AudioFlinger( 787): Error reading audio input
W/AudioRecord( 947): obtainBuffer timed out (is the CPU pegged?) user=00000000, server=00000000

The android::AudioRecord::read() function returns the number of bytes I'm trying to read, but the resulting buffer is filled with zeroes.

Any idea or input would be helpful. Thank you.

Advertisements
martinb is offline  
Reply With Quote
sponsored links
Old December 20th, 2012, 11:30 PM   #2 (permalink)
New Member
 
Join Date: Dec 2012
Posts: 3
 
Device(s):
Carrier: Not Provided

Thanks: 0
Thanked 0 Times in 0 Posts
Default Have you set the user permissions

I had a similar problem, I ended up having to set the user permission

in the android manifest xml add

<uses-permission android:name="android.permission.RECORD_AUDIO"/>

under the manifest tag
israfelwater is offline  
Reply With Quote
Reply


Go Back   Android Forums > Android Development > Application Development
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 01:02 PM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.