I enabled the Loopback device and put stuff in .asoundrc which I thought would let me play through Loopback, thence to Jack and then to the default sink (ie I didn’t think it needed the alsa_out bit).
osmc@pi2:/usr/share/sounds/alsa$ cat ~/.asoundrc
pcm.dmixer {
type dmix
ipc_key 1024
slave {
pcm "hw:Loopback,0,0"
channels 2
}
}
# the capture device Jack will listen to with alsa_in
pcm.cloop {
type dsnoop
card Loopback
device 1
subdevice 0
}
Using alsa_in without sudo I got a message about permissions. Couldn’t be bothered to do what was suggested and got this:
osmc@pi2:/usr/share/sounds/alsa$ sudo alsa_in -j cloop -dcloop
connect(2) call to /tmp/jack-0/default/jack_0 failed (err=No such file or directory)
jackd 0.125.0rc1
Copyright 2001-2009 Paul Davis, Stephane Letz, Jack O'Quinn, Torben Hohn and others.
jackd comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details
JACK compiled with System V SHM support.
loading driver ..
creating alsa driver ... hw:0|hw:0|1024|2|48000|0|0|nomon|swmeter|-|32bit
ALSA: Cannot open PCM device alsa_pcm for capture. Falling back to playback-only mode
configuring for 48000Hz, period = 1024 frames (21.3 ms), buffer = 2 periods
ALSA: final selected sample format for playback: 16bit little-endian
ALSA: use 2 periods for playback
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cloop
Capture open error: No such file or directory
osmc@pi2:/usr/share/sounds/alsa$ jack main caught signal 12
Then went to bed.
Today after fixing the /etc/security thing I get this:
osmc@pi2:~$ alsa_in -j cloop -dcloop
connect(2) call to /tmp/jack-1000/default/jack_0 failed (err=No such file or directory)
jackd 0.125.0rc1
Copyright 2001-2009 Paul Davis, Stephane Letz, Jack O'Quinn, Torben Hohn and others.
jackd comes with ABSOLUTELY NO WARRANTY
This is free software, and you are welcome to redistribute it
under certain conditions; see the file COPYING for details
JACK compiled with System V SHM support.
cannot lock down memory for jackd (Cannot allocate memory)
loading driver ..
creating alsa driver ... hw:0|hw:0|1024|2|48000|0|0|nomon|swmeter|-|32bit
ALSA: Cannot open PCM device alsa_pcm for capture. Falling back to playback-only mode
configuring for 48000Hz, period = 1024 frames (21.3 ms), buffer = 2 periods
ALSA: final selected sample format for playback: 16bit little-endian
ALSA: use 2 periods for playback
JACK: unable to mlock() port buffers: Cannot allocate memory
JACK: unable to mlock() port buffers: Cannot allocate memory
ALSA lib pcm_direct.c:1765:(snd1_pcm_direct_parse_open_conf) Unknown field card
Capture open error: Invalid argument
osmc@pi2:~$ jack main caught signal 12
Oops! I changed ‘type hw’ to ‘type dsnoop’ yesterday but forgot to add a slave. Now I have:
osmc@pi2:~$ cat .asoundrc
pcm.dmixer {
type dmix
ipc_key 1024
slave {
pcm "hw:Loopback,0,0"
channels 2
}
}
# the capture device Jack will listen to with alsa_in
pcm.cloop {
type dsnoop
ipc_key 1025
slave {
pcm "hw:Loopback,1,0"
}
}
Which is much more promising.