I am currently developing audio recording application which will run on both device and tablets.
user can set following preference before starting with recording.
Format(AAC-PCM)
Channels(Mono-Stereo)
Sample Bit Size(8-16 bits)
Sampling Rate ( 8000 , 11025 ,22050 , 44100 hz)
based on these preference values i create AudioRecord ( for uncompress) & MediaRecord ( Compress) and the recording is started.
So far so good but lately i noticed following issues.
If i set Channel to Stereo then my application runs well on Xperia Arc but on Galaxy note recorded sound plays in talking tom kind of voice.and on Samsung i9000 the recording fails.
Also i faced same issues with Sample Bit Size If i set bit size to 8 Bits.Recorder refuse to work.
As per android docs 8 bit is not guaranted to work on all devices.
So i have following approach in mind.
Is there any way i can detect recording settings which are not compatible on device so i will disable them.
So user will not have bad user experience as i will show only compatible settings once he starts the application.
I would really appreciate if someone can give me a hint on implementing above approach.
Thanks
There are not any api for this purpose. Each manufacture choose own way for speach recognition (and it can have different options for bluetooth and speacker).
So I can suggest 2 options:
1) choose one more stable option (like PCM Mono, 16KHz,22050 )
2) during first start of application do check for all posible congiguration and save it