Identify external and internal audio devices?

Options

Hi,
I am aware that when we connect external audio device(bluetooth/wired earphones) then this device would act as the default microphone and speaker. But, in my web application, when I connect external microphone, this microphone is not behaving as the default device. This might be happening, since I sometimes also connect bluetooth device and also I connect my system to the TV.

Is there a proper way to identify which are external devices and which are internal devices. So that I can prioritise external microphone.

Answers

  • mark_at_daily
    mark_at_daily Community Manager, Dailynista admin
    Options

    @svm_agilis to the best of my knowledge, there's no programmatic way to determine if a device is internal or external.

    In case it helps, here's the gist of the daily-js logic for selecting a device (priori:

    • On joining, use the OS's default device.
    • Or, if on joining, if the callObject is configured to use a cached device, use that in place of the default (link).
    • If a user selects a device, use it immediately.
    • If a user plugs in a new device, use the newly connected device immediately.

    Hope this helps!