1 Reply Latest reply on Jun 2, 2015 5:39 PM by PabloM_Intel

    how to have audio multiple audio output Intel Edison using Pulseaudio?

    Mohame_Ahmed

      is there a way to choose the default devices to be 2 devices not one.

      the problem is i need Intel Edison to give the audio output to 2 devices simultaneously and that these 2 devises be the default audio output for Intel Edison

      in need the output for these devices

      1- a Bluetooth headset using the A2DP

      2- a USB sound Card


      i have done the following:

      i was able to install the driver modules for the sound driver and play audio on it using mplayer and specified it as the pactl set-default-sink <device name>

      i was able to connect the Bluetooth headset to the module and also set it as default and play audio to it through Bluetooth


      now i need the output audio to be played on both the Bluetooth head set and the USB card at the same time where i need for example to set the default output be both the headset and the USB sound Card


      i am using Intel Edison with mini breakout board and connected the sound card via the middle port in the Intel Edison mini breakout board using a USB A female to micro-USB B adapter


      any help to setup pusleaudio to have multiple output or set more than device as the default device will be very appreciated.


      this is the output for pactl list sinks:


      -----------------------------------------------------------------------------------------------------------------------------------------------

      Sink #0

              State: SUSPENDED

              Name: alsa_output.0.analog-stereo

              Description: Loopback Analog Stereo

              Driver: module-alsa-card.c

              Sample Specification: s16le 2ch 44100Hz

              Channel Map: front-left,front-right

              Owner Module: 1

              Mute: no

              Volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB

                      balance 0.00

              Base Volume: 65536 / 100% / 0.00 dB

              Monitor Source: alsa_output.0.analog-stereo.monitor

              Latency: 0 usec, configured 0 usec

              Flags: HARDWARE DECIBEL_VOLUME LATENCY

              Properties:

                      alsa.resolution_bits = "16"

                      device.api = "alsa"

                      device.class = "sound"

                      alsa.class = "generic"

                      alsa.subclass = "generic-mix"

                      alsa.name = "Loopback PCM"

                      alsa.id = "Loopback PCM"

                      alsa.subdevice = "0"

                      alsa.subdevice_name = "subdevice #0"

                      alsa.device = "0"

                      alsa.card = "0"

                      alsa.card_name = "Loopback"

                      alsa.long_card_name = "Loopback 1"

                      device.bus_path = "/devices/virtual/sound/card0"

                      sysfs.path = "/devices/virtual/sound/card0"

                      device.string = "hw:0"

                      device.buffering.buffer_size = "352800"

                      device.buffering.fragment_size = "352800"

                      device.access_mode = "mmap+timer"

                      device.profile.name = "analog-stereo"

                      device.profile.description = "Analog Stereo"

                      device.description = "Loopback Analog Stereo"

                      alsa.mixer_name = "Loopback Mixer"

                      module-udev-detect.discovered = "1"

                      device.icon_name = "audio-card"

              Ports:

                      analog-output: Analog Output (priority: 9900)

              Active Port: analog-output

              Formats:

                      pcm

       

       

      Sink #2

              State: SUSPENDED

              Name: alsa_output.usb-0a12_CSR_Audio_Dongle-00-Dongle.analog-stereo

              Description: CSR Audio Dongle Analog Stereo

              Driver: module-alsa-card.c

              Sample Specification: s16le 2ch 48000Hz

              Channel Map: front-left,front-right

              Owner Module: 13

              Mute: no

              Volume: front-left: 36854 /  56% / -15.00 dB,   front-right: 36854 /  56% / -15.00 dB

                      balance 0.00

              Base Volume: 65536 / 100% / 0.00 dB

              Monitor Source: alsa_output.usb-0a12_CSR_Audio_Dongle-00-Dongle.analog-stereo.monitor

              Latency: 0 usec, configured 0 usec

              Flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY

              Properties:

                      alsa.resolution_bits = "16"

                      device.api = "alsa"

                      device.class = "sound"

                      alsa.class = "generic"

                      alsa.subclass = "generic-mix"

                      alsa.name = "USB Audio"

                      alsa.id = "USB Audio"

                      alsa.subdevice = "0"

                      alsa.subdevice_name = "subdevice #0"

                      alsa.device = "0"

                      alsa.card = "1"

                      alsa.card_name = "CSR Audio Dongle"

                      alsa.long_card_name = "CSR Audio Dongle at usb-dwc3-host.2-1, full speed"

                      alsa.driver_name = "snd_usb_audio"

                      device.bus_path = "pci-0000:00:11.0-platform-dwc3-host.2-usb-0:1:1.0"

                      sysfs.path = "/devices/pci0000:00/0000:00:11.0/dwc3-host.2/usb1/1-1/1-1:1.0/sound/card1"

                      udev.id = "usb-0a12_CSR_Audio_Dongle-00-Dongle"

                      device.bus = "usb"

                      device.vendor.id = "0a12"

                      device.vendor.name = "Cambridge Silicon Radio, Ltd"

                      device.product.id = "1004"

                      device.product.name = "CSR Audio Dongle"

                      device.serial = "0a12_CSR_Audio_Dongle"

                      device.string = "hw:1"

                      device.buffering.buffer_size = "19188"

                      device.buffering.fragment_size = "4796"

                      device.access_mode = "mmap"

                      device.profile.name = "analog-stereo"

                      device.profile.description = "Analog Stereo"

                      device.description = "CSR Audio Dongle Analog Stereo"

                      alsa.mixer_name = "USB Mixer"

                      alsa.components = "USB0a12:1004"

                      module-udev-detect.discovered = "1"

                      device.icon_name = "audio-card-usb"

              Ports:

                      analog-output: Analog Output (priority: 9900)

              Active Port: analog-output

              Formats:

                      pcm

       

       

      Sink #3

              State: SUSPENDED

              Name: bluez_sink.00_00_07_14_17_96

              Description: SPK-8635-B

              Driver: module-bluez5-device.c

              Sample Specification: s16le 2ch 44100Hz

              Channel Map: front-left,front-right

              Owner Module: 14

              Mute: no

              Volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB

                      balance 0.00

              Base Volume: 65536 / 100% / 0.00 dB

              Monitor Source: bluez_sink.00_00_07_14_17_96.monitor

              Latency: 0 usec, configured 0 usec

              Flags: HARDWARE DECIBEL_VOLUME LATENCY

              Properties:

                      bluetooth.protocol = "a2dp_sink"

                      device.description = "SPK-8635-B"

                      device.string = "00:00:07:14:17:96"

                      device.api = "bluez"

                      device.class = "sound"

                      device.bus = "bluetooth"

                      device.form_factor = "headset"

                      bluez.path = "/org/bluez/hci0/dev_00_00_07_14_17_96"

                      bluez.class = "0x240404"

                      bluez.alias = "SPK-8635-B"

                      device.icon_name = "audio-headset-bluetooth"

                      device.intended_roles = "phone"

              Ports:

                      headset-output: Headset (priority: 0)

              Active Port: headset-output

              Formats:

                      pcm

      ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

       

      and this is the output of aplay-L note that the Bluetooth headset is not available in it and the dongle is the USB sound card:

       

      -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

      card 0: Loopback [Loopback], device 0: Loopback PCM [Loopback PCM]

        Subdevices: 8/8

        Subdevice #0: subdevice #0

        Subdevice #1: subdevice #1

        Subdevice #2: subdevice #2

        Subdevice #3: subdevice #3

        Subdevice #4: subdevice #4

        Subdevice #5: subdevice #5

        Subdevice #6: subdevice #6

        Subdevice #7: subdevice #7

      card 0: Loopback [Loopback], device 1: Loopback PCM [Loopback PCM]

        Subdevices: 8/8

        Subdevice #0: subdevice #0

        Subdevice #1: subdevice #1

        Subdevice #2: subdevice #2

        Subdevice #3: subdevice #3

        Subdevice #4: subdevice #4

        Subdevice #5: subdevice #5

        Subdevice #6: subdevice #6

        Subdevice #7: subdevice #7

      card 1: Dongle [CSR Audio Dongle], device 0: USB Audio [USB Audio]

        Subdevices: 1/1

        Subdevice #0: subdevice #0

      --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------