On Mon, 29 Aug 2016, Muammar El Khatib wrote: > > Would you mind testing if this procedure makes possible to record > your audio using alsa?
Muammar, Sorry for the delay. Did a quick test. Problem is I got (too) many sound cards on this horse ;) # cat /proc/asound/cards 0 [Live ]: EMU10K1 - SB Live! 5.1 [SB0060] SB Live! 5.1 [SB0060] (rev.7, serial:0x80611102) at 0xd000, irq 17 1 [PCH ]: HDA-Intel - HDA Intel PCH HDA Intel PCH at 0xf7230000 irq 29 2 [NVidia ]: HDA-Intel - HDA NVidia HDA NVidia at 0xf7080000 irq 17 3 [Controller ]: USB-Audio - USB Audio Controller USB Audio Controller at usb-0000:00:1d.0-1.5, full speed 4 [Loopback ]: Loopback - Loopback Loopback 1 And asound.conf, ~/.asoundrc is still black magic for me, even after so many years :( Could you please heavily comment your proposed configuration so I can locate and modify the relevant bits, before testing again? > 1. Do > modprobe snd-aloop > > 2. Add the following content to ~/.asoundrc > > pcm.!default { > type asym > playback.pcm "LoopAndReal" > #capture.pcm "looprec" > capture.pcm "hw:0,0" > } > > pcm.looprec { > type hw > card "Loopback" > device 1 > subdevice 0 > } > > pcm.LoopAndReal { > type plug > slave.pcm mdev > route_policy "duplicate" > } > > pcm.mdev { > type multi > slaves.a.pcm pcm.MixReale > slaves.a.channels 2 > slaves.b.pcm pcm.MixLoopback > slaves.b.channels 2 > bindings.0.slave a > bindings.0.channel 0 > bindings.1.slave a > bindings.1.channel 1 > bindings.2.slave b > bindings.2.channel 0 > bindings.3.slave b > bindings.3.channel 1 > } > > pcm.MixReale { > type dmix > ipc_key 1024 > slave { > pcm "hw:0,0" > rate 48000 > #rate 44100 > periods 128 > period_time 0 > period_size 1024 # must be power of 2 > buffer_size 8192 > } > } > > pcm.MixLoopback { > type dmix > ipc_key 1025 > slave { > pcm "hw:Loopback,0,0" > rate 48000 > #rate 44100 > periods 128 > period_time 0 > period_size 1024 # must be power of 2 > buffer_size 8192 > } > } > > 3. Install ffmpeg, and execute this command while playing anything in your > computer: > > ffmpeg -f alsa -ac 2 -ar 44100 -i hw:0 -t 30 out.wav > > Does ffmpeg capture the audio in out.wav?. It did capture a totally silent wav. And I guess main reason is loopback device number. Cheers, -- Cristian