mixing input/output in alsa

cancel
Showing results for 
Search instead for 
Did you mean: 

mixing input/output in alsa

1,074 Views
Contributor III

i'm newbie in linux sound and stuck now. i have savreauto IMX6QP. I'm using codeck cs42888 and connect 4 microfone on it. Audio out make via spdif. Now i need to hear music coming from QT application and sound from 4 mic's. I'm changing asound.conf to play music from QTAPP via spdif and it working, but dont understand how can i mix this music whith mic inputs

system: linux 4.1 from yocto

# aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: cs42888audio [cs42888-audio], device 0: HiFi cs42888-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: cs42888audio [cs42888-audio], device 1: HiFi-ASRC-FE (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: imxspdif [imx-spdif], device 0: S/PDIF PCM snd-soc-dummy-dai-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: imxhdmisoc [imx-hdmi-soc], device 0: i.MX HDMI Audio Tx hdmi-hifi-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0

Original Attachment has been moved to: asound.conf.zip

Labels (4)
0 Kudos
3 Replies

112 Views
Contributor III

then

gst-launch-1.0 alsasrc device="linein" ! "audio/x-raw,rate=48000,channels=2,depth=16" ! alsasink device="sysdefault:CARD=imxspdif"

0 Kudos

112 Views
Contributor III

Partially solved the problem. Write some lines to asound.conf

pcm.linein {
    type multi;
    slaves.a.pcm hw:0
    slaves.a.channels 2;
    bindings.0.slave a;
    bindings.0.channel 1;
    bindings.1.slave a;
    bindings.1.channel 3;
}

0 Kudos

112 Views
NXP TechSupport
NXP TechSupport

Hi Andrey

this may be posted on alsa/qt special forums as seems there is no i.mx specific issue

https://www.alsa-project.org/main/index.php/Asoundrc 

More sound simultaneously with QSoundEffect and alsa | Qt Forum 

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos