pacmd “não conseguiu definir a porta do coletor” ao tentar alterar qual saída da placa de som deve ser usada

1

Linux linux 3.0.0-14-genérico # 23-Ubuntu SMP seg 21 de novembro 20:28:43 UTC 2011 x86_64 x86_64 x86_64 GNU / Linux

Oneiric Ocelot

Eu tenho uma placa de som Asus Xonar DG que tem várias saídas para escolher.

Às vezes, quero usar a saída de alto-falante normal e ver meus alto-falantes, mas outras vezes gostaria de poder usar a porta de áudio do painel frontal dos meus fones de ouvido.

Eu tentei mudar a porta de saída em pavucontrol e o painel de som Ubuntu embutido, mas assim que um fluxo de áudio começar a tocar a porta mudará de "fones de ouvido" de volta para "alto-falante" e o áudio continuará saindo dos meus alto-falantes.

Então eu caí no pacmd e tentei mudar ...

>>> list-sinks
3 sink(s) available.
    index: 0
    name: <alsa_output.pci-0000_03_00.1.hdmi-stereo>
    driver: <module-alsa-card.c>
    flags: HARDWARE DECIBEL_VOLUME LATENCY DYNAMIC_LATENCY
    state: SUSPENDED
    suspend cause: IDLE 
    priority: 9050
    volume: 0: 100% 1: 100%
            0: -0.00 dB 1: -0.00 dB
            balance 0.00
    base volume: 100%
                 0.00 dB
    volume steps: 65537
    muted: no
    current latency: 0.00 ms
    max request: 0 KiB
    max rewind: 0 KiB
    monitor source: 0
    sample spec: s16le 2ch 44100Hz
    channel map: front-left,front-right
                 Stereo
    used by: 0
    linked by: 0
    configured latency: 0.00 ms; range is 0.50 .. 1999.82 ms
    card: 0 <alsa_card.pci-0000_03_00.1>
    module: 4
    properties:
        alsa.resolution_bits = "16"
        device.api = "alsa"
        device.class = "sound"
        alsa.class = "generic"
        alsa.subclass = "generic-mix"
        alsa.name = "HDMI 0"
        alsa.id = "HDMI 0"
        alsa.subdevice = "0"
        alsa.subdevice_name = "subdevice #0"
        alsa.device = "3"
        alsa.card = "2"
        alsa.card_name = "HD-Audio Generic"
        alsa.long_card_name = "HD-Audio Generic at 0xfbbfc000 irq 78"
        alsa.driver_name = "snd_hda_intel"
        device.bus_path = "pci-0000:03:00.1"
        sysfs.path = "/devices/pci0000:00/0000:00:03.0/0000:03:00.1/sound/card2"
        device.bus = "pci"
        device.vendor.id = "1002"
        device.vendor.name = "ATI Technologies Inc"
        device.product.id = "aa50"
        device.product.name = "Cypress HDMI Audio [Radeon HD 5800 Series]"
        device.string = "hdmi:2"
        device.buffering.buffer_size = "352768"
        device.buffering.fragment_size = "176384"
        device.access_mode = "mmap+timer"
        device.profile.name = "hdmi-stereo"
        device.profile.description = "Digital Stereo (HDMI)"
        device.description = "Cypress HDMI Audio [Radeon HD 5800 Series] Digital Stereo (HDMI)"
        alsa.mixer_name = "ATI R6xx HDMI"
        alsa.components = "HDA:1002aa01,00aa0100,00100200"
        module-udev-detect.discovered = "1"
        device.icon_name = "audio-card-pci"
    ports:
        HDMI: HDMI (priority 0, available: no)
    active port: <HDMI>
    index: 1
    name: <alsa_output.pci-0000_00_1b.0.analog-stereo>
    driver: <module-alsa-card.c>
    flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY DYNAMIC_LATENCY
    state: SUSPENDED
    suspend cause: IDLE 
    priority: 9959
    volume: 0: 101% 1: 101%
            0: 0.25 dB 1: 0.25 dB
            balance 0.00
    base volume: 100%
                 0.00 dB
    volume steps: 65537
    muted: no
    current latency: 0.00 ms
    max request: 0 KiB
    max rewind: 0 KiB
    monitor source: 1
    sample spec: s16le 2ch 44100Hz
    channel map: front-left,front-right
                 Stereo
    used by: 0
    linked by: 0
    configured latency: 0.00 ms; range is 0.50 .. 1999.82 ms
    card: 1 <alsa_card.pci-0000_00_1b.0>
    module: 5
    properties:
        alsa.resolution_bits = "16"
        device.api = "alsa"
        device.class = "sound"
        alsa.class = "generic"
        alsa.subclass = "generic-mix"
        alsa.name = "ALC889 Analog"
        alsa.id = "ALC889 Analog"
        alsa.subdevice = "0"
        alsa.subdevice_name = "subdevice #0"
        alsa.device = "0"
        alsa.card = "1"
        alsa.card_name = "HDA Intel"
        alsa.long_card_name = "HDA Intel at 0xfb8f8000 irq 77"
        alsa.driver_name = "snd_hda_intel"
        device.bus_path = "pci-0000:00:1b.0"
        sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card1"
        device.bus = "pci"
        device.vendor.id = "8086"
        device.vendor.name = "Intel Corporation"
        device.product.id = "3a3e"
        device.product.name = "82801JI (ICH10 Family) HD Audio Controller"
        device.form_factor = "internal"
        device.string = "front:1"
        device.buffering.buffer_size = "352768"
        device.buffering.fragment_size = "176384"
        device.access_mode = "mmap+timer"
        device.profile.name = "analog-stereo"
        device.profile.description = "Analog Stereo"
        device.description = "Internal Audio Analog Stereo"
        alsa.mixer_name = "Realtek ALC889"
        alsa.components = "HDA:10ec0889,104383c0,00100004"
        module-udev-detect.discovered = "1"
        device.icon_name = "audio-card-pci"
    ports:
        analog-output: Analog Output (priority 9900, available: unknown)
        analog-output-headphones: Analog Headphones (priority 9000, available: no)
    active port: <analog-output-headphones>
  * index: 2
    name: <alsa_output.pci-0000_08_01.0.analog-stereo>
    driver: <module-alsa-card.c>
    flags: HARDWARE DECIBEL_VOLUME LATENCY DYNAMIC_LATENCY
    state: SUSPENDED
    suspend cause: IDLE 
    priority: 9059
    volume: 0: 100% 1: 100%
            0: 0.00 dB 1: 0.00 dB
            balance 0.00
    base volume: 100%
                 0.00 dB
    volume steps: 65537
    muted: no
    current latency: 0.00 ms
    max request: 0 KiB
    max rewind: 0 KiB
    monitor source: 3
    sample spec: s16le 2ch 44100Hz
    channel map: front-left,front-right
                 Stereo
    used by: 0
    linked by: 0
    configured latency: 0.00 ms; range is 36.00 .. 2000.00 ms
    card: 2 <alsa_card.pci-0000_08_01.0>
    module: 6
    properties:
        alsa.resolution_bits = "16"
        device.api = "alsa"
        device.class = "sound"
        alsa.class = "generic"
        alsa.subclass = "generic-mix"
        alsa.name = "Multichannel"
        alsa.id = "Multichannel"
        alsa.subdevice = "0"
        alsa.subdevice_name = "subdevice #0"
        alsa.device = "0"
        alsa.card = "0"
        alsa.card_name = "Xonar DG"
        alsa.long_card_name = "C-Media Oxygen HD Audio at 0xe800, irq 17"
        alsa.driver_name = "snd_oxygen"
        device.bus_path = "pci-0000:08:01.0"
        sysfs.path = "/devices/pci0000:00/0000:00:1e.0/0000:08:01.0/sound/card0"
        device.bus = "pci"
        device.vendor.id = "13f6"
        device.vendor.name = "C-Media Electronics Inc"
        device.product.id = "8788"
        device.product.name = "CMI8788 [Oxygen HD Audio]"
        device.string = "front: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 = "CMI8788 [Oxygen HD Audio] Analog Stereo"
        alsa.mixer_name = "CMI8786"
        alsa.components = "CS4245 CMI8786"
        module-udev-detect.discovered = "1"
        device.icon_name = "audio-card-pci"
    ports:
        analog-output;output-speaker: Analog Output / Speaker (priority 9910, available: unknown)
        analog-output;output-headphones-1: Analog Output / Headphones 1 (priority 9909, available: unknown)
        analog-output;output-headphones-2: Analog Output / Headphones 2 (priority 9908, available: unknown)
    active port: <analog-output;output-speaker>
>>> set-sink-port 2 analog-output;output-headphones-1
Failed to set sink port to 'analog-output;output-headphones-1'.

Booo. Alguma ideia?

Nada aparece em / var / log / dmesg ou / var / log / syslog, não sei onde mais devo procurar ...

    
por ashgromnies 14.12.2011 / 01:45

1 resposta

1

Da saída de seu list-sinks , podemos ver que, por padrão, seu coletor de fone de ouvido tem o índice 1 , seu coletor de alto-falantes tem o índice 2 (HDMI é 0 ). Desde que você tenha uma configuração padrão para o PulseAudio, você deve poder alternar entre esses dois coletores emitindo:

pacmd set-default-sink 1 # for headphones
pacmd set-default-sink 2 # for speakers

Veja também esta resposta para alterar a saída do coletor enquanto um fluxo ativo está sendo reproduzido e como desativar a restauração do dispositivo de fluxo.

    
por Takkat 14.12.2011 / 08:21