How can I get the list of microphones on android Api 17 (usb connected mic's)

1.9k Views Asked by At

For Android Api level 23, you can use AudioRecord.setPreferredDevice();

And you can also use:

AudioManager audioManager = (AudioManager) getSystemService(Context.AUDIO_SERVICE);

if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.M) {
    AudioDeviceInfo[] adi = audioManager.getDevices(AudioManager.GET_DEVICES_OUTPUTS);
}

But is it possible to get a list of your microphones, on a API level lower than 23? (I need it for 17).

0

There are 0 best solutions below