Skip to content

ALSA lib pcm_route.c:878:(find_matching_chmap) Found no matching channel map #952

@TornaxO7

Description

@TornaxO7

Hello! I'm somehow getting some weird artifacts if I try to iterate through the available devices:

ALSA lib pcm_dmix.c:1000:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm_dmix.c:1000:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm_route.c:878:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:878:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:878:(find_matching_chmap) Found no matching channel map

Reproduction steps

Cargo.toml

# [packages] omitted

[dependencies]
cpal = "0.15"

main.rs

use cpal::traits::{DeviceTrait, HostTrait};

fn main() {
    for device in cpal::default_host().output_devices().unwrap() {
        if let Ok(name) = device.name() {
            println!("From my code: {}", name);
        }
    }
}

Output after cargo run:

From my code: pipewire
From my code: default
ALSA lib pcm_dmix.c:1000:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm_dmix.c:1000:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm_route.c:878:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:878:(find_matching_chmap) Found no matching channel map
ALSA lib pcm_route.c:878:(find_matching_chmap) Found no matching channel map
From my code: iec958:CARD=PCH,DEV=0
From my code: hdmi:CARD=HDMI,DEV=0
From my code: hdmi:CARD=HDMI,DEV=1
From my code: hdmi:CARD=HDMI,DEV=2
From my code: hdmi:CARD=HDMI,DEV=3
From my code: hdmi:CARD=HDMI,DEV=4
ALSA lib pcm_dmix.c:1000:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm_dmix.c:1000:(snd_pcm_dmix_open) unable to open slave

but I expected

From my code: pipewire
From my code: default
From my code: iec958:CARD=PCH,DEV=0
From my code: hdmi:CARD=HDMI,DEV=0
From my code: hdmi:CARD=HDMI,DEV=1
From my code: hdmi:CARD=HDMI,DEV=2
From my code: hdmi:CARD=HDMI,DEV=3
From my code: hdmi:CARD=HDMI,DEV=4

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions