alsa-4sorties
Différences
Ci-dessous, les différences entre deux révisions de la page.
— | alsa-4sorties [2024/02/09 17:10] (Version actuelle) – créée - modification externe 127.0.0.1 | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
+ | ====== alsa 4 sorties avec 2 cartes USB ====== | ||
+ | mettre dans .asoundrc | ||
+ | < | ||
+ | # Utilise card " | ||
+ | # converti automatiquement channels, rate et format. | ||
+ | pcm.!default { | ||
+ | type plug | ||
+ | slave { | ||
+ | pcm " | ||
+ | rate 44100 | ||
+ | channels 2 | ||
+ | } | ||
+ | } | ||
+ | |||
+ | ctl.!default { | ||
+ | type hw | ||
+ | card " | ||
+ | } | ||
+ | |||
+ | pcm.usb1 { | ||
+ | type hw | ||
+ | card " | ||
+ | channels 2 | ||
+ | rate 44100 | ||
+ | } | ||
+ | |||
+ | ctl.usb1 { | ||
+ | type hw | ||
+ | card " | ||
+ | } | ||
+ | |||
+ | pcm.usb2 { | ||
+ | type hw | ||
+ | card " | ||
+ | channels 2 | ||
+ | rate 44100 | ||
+ | } | ||
+ | |||
+ | ctl.usb2 { | ||
+ | type hw | ||
+ | card " | ||
+ | } | ||
+ | |||
+ | # Creer card " | ||
+ | pcm.les2 { | ||
+ | # The " | ||
+ | type route | ||
+ | |||
+ | # Slave is the input card. | ||
+ | slave { | ||
+ | # The virtual input card has 4 channels. Yes, this is circumstantial and | ||
+ | # also must be specified explicitly. | ||
+ | channels 4 | ||
+ | |||
+ | # Unnamed definition of the input card. | ||
+ | pcm { | ||
+ | # The " | ||
+ | # because the " | ||
+ | type multi | ||
+ | | ||
+ | # Definition of the child cards. | ||
+ | slaves { | ||
+ | # Definition of child card " | ||
+ | a { | ||
+ | pcm { | ||
+ | type dmix | ||
+ | ipc_key 1024 | ||
+ | slave.pcm " | ||
+ | } | ||
+ | channels 2 | ||
+ | } | ||
+ | b { | ||
+ | pcm { | ||
+ | type dmix | ||
+ | ipc_key 2048 | ||
+ | slave.pcm " | ||
+ | } | ||
+ | channels 2 | ||
+ | } | ||
+ | } | ||
+ | |||
+ | # Definition of the card's channels. | ||
+ | bindings { | ||
+ | # Channel 0... | ||
+ | 0 { | ||
+ | # ... bound to child card " | ||
+ | slave a | ||
+ | # ... channel 0. | ||
+ | channel 0 | ||
+ | } | ||
+ | 1 { | ||
+ | slave a | ||
+ | channel 1 | ||
+ | } | ||
+ | 2 { | ||
+ | slave b | ||
+ | channel 0 | ||
+ | } | ||
+ | 3 { | ||
+ | slave b | ||
+ | channel 1 | ||
+ | } | ||
+ | } | ||
+ | } | ||
+ | } | ||
+ | ttable { | ||
+ | # Channel 0... | ||
+ | 0 { | ||
+ | # ... bound to child card's channel 0 at full volume... | ||
+ | 0 1.0 | ||
+ | # ... AND child child card's channel 1 at full volume. | ||
+ | 1 1.0 | ||
+ | } | ||
+ | 1 { | ||
+ | 2 1.0 | ||
+ | 3 1.0 | ||
+ | } | ||
+ | } | ||
+ | } | ||
+ | |||
+ | |||
+ | </ |