Virtual Midi Port/Cable
Moderators: MattKingUSA, khz
- d.healey
- Established Member
- Posts: 611
- Joined: Fri Sep 22, 2017 8:33 pm
- Has thanked: 279 times
- Been thanked: 101 times
Virtual Midi Port/Cable
How do we add virtual MIDI ports/cables in GNU/Linux? On Windows I used LoopBe but I'm assuming there is a built in way on GNU/Linux.
Thanks.
Thanks.
David Healey
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
-
- Established Member
- Posts: 108
- Joined: Sun Sep 01, 2019 12:58 pm
- Has thanked: 21 times
- Been thanked: 11 times
Re: Virtual Midi Port/Cable
Doesn't jack +aj2midi and Carla do this? Or am I thinking of something else?
OS: Manjaro
Amp: Echolette M40 / NG51S Tape Echo
Strings: Martin D15M, Yamaha FG-180, Alhambra 5P, Yamaha Revstar
Amp: Echolette M40 / NG51S Tape Echo
Strings: Martin D15M, Yamaha FG-180, Alhambra 5P, Yamaha Revstar
- bluebell
- Established Member
- Posts: 1927
- Joined: Sat Sep 15, 2012 11:44 am
- Location: Saarland, Germany
- Has thanked: 113 times
- Been thanked: 122 times
Re: Virtual Midi Port/Cable
There are 2 worlds: ALSA MIDI and JACK MIDI. For JACK MIDI to work you need a running jackd instance.d.healey wrote:How do we add virtual MIDI ports/cables in GNU/Linux? On Windows I used LoopBe but I'm assuming there is a built in way on GNU/Linux.
Thanks.
Those worlds can be connected with a2j, e.g. "a2j_control start".
Both can be extended over the network with different tools.
Connections can be made with commandline tools and graphical tools, e.g. qjackctl.
Linux – MOTU UltraLite AVB – Qtractor – http://suedwestlicht.saar.de/
-
- Established Member
- Posts: 1067
- Joined: Mon May 12, 2014 7:11 am
- Has thanked: 15 times
- Been thanked: 36 times
Re: Virtual Midi Port/Cable
There's an ALSA module called snd-seq-dummy which creates virtual midi ports
On my ubuntu system there's
/etc/modprobe.d/snd-seq-dummy.conf
contents of this file
THe virtual ALSA midi ports show up in qjackctl like this
To connect jack midi apps to these ports you indeed need a2jmidid , but Ubuntu Studio Controls takes care of that automagically by ticking a box. Cadence can do the same.
This is how they show up under the jack midi tab
hope this helps
On my ubuntu system there's
/etc/modprobe.d/snd-seq-dummy.conf
contents of this file
Code: Select all
# Enable 4 ALSA MIDI-Through ports
options snd-seq-dummy ports=4
- d.healey
- Established Member
- Posts: 611
- Joined: Fri Sep 22, 2017 8:33 pm
- Has thanked: 279 times
- Been thanked: 101 times
Re: Virtual Midi Port/Cable
Thanks. I've been working entirely with JACK MIDI. I'll install a2j.
David Healey
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
- d.healey
- Established Member
- Posts: 611
- Joined: Fri Sep 22, 2017 8:33 pm
- Has thanked: 279 times
- Been thanked: 101 times
Re: Virtual Midi Port/Cable
I don't have this. Is there a way to add it or would it require me to install a different kernel?rghvdberg wrote:There's an ALSA module called snd-seq-dummy which creates virtual midi ports
On my ubuntu system there's
/etc/modprobe.d/snd-seq-dummy.conf
David Healey
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
-
- Established Member
- Posts: 1067
- Joined: Mon May 12, 2014 7:11 am
- Has thanked: 15 times
- Been thanked: 36 times
Re: Virtual Midi Port/Cable
For the record : I'm on Ubuntu 19.10 with kxstudio repos added.d.healey wrote: ... I don't have this. Is there a way to add it or would it require me to install a different kernel?
I've also installed the kxstudio-default-settings package which adds the snd-seq-dummy.conf file
But you can do this all manually
- First check if the module isn't loaded already
notice the underscore ( _ ) instead of -Code: Select all
lsmod | grep snd_seq_dummy snd_seq_dummy 16384 8 snd_seq 69632 14 snd_seq_midi,snd_seq_midi_event,snd_seq_dummy
- if not try
(yes there it is - not _ ... thank you linux)
Code: Select all
sudo modprobe snd-seq-dummy
- and once again check if the module is loaded by running the first command
- if succesful you could manually add the /etc/modprobe.d/snd-seq-dummy.conf file
- d.healey
- Established Member
- Posts: 611
- Joined: Fri Sep 22, 2017 8:33 pm
- Has thanked: 279 times
- Been thanked: 101 times
Re: Virtual Midi Port/Cable
Thanks, that worked! How do I get a2j to auto-start? I tried "a2jmidid -e &" as a command to run after startup in qjackctl but it didn't seem to make a difference. Does it require a system restart to take effect?
David Healey
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
-
- Established Member
- Posts: 821
- Joined: Thu Mar 21, 2013 12:55 am
- Location: Vladivostok
- Has thanked: 65 times
- Been thanked: 124 times
Re: Virtual Midi Port/Cable
a2j can work only when jackd is started
not sure that starting a2j* just after qjackctl is enough, even if qjackctl starts jackd automatically, so, maybe you need to insert some "sleep" in your command
Cadence can handle this case
not sure that starting a2j* just after qjackctl is enough, even if qjackctl starts jackd automatically, so, maybe you need to insert some "sleep" in your command
Cadence can handle this case
- d.healey
- Established Member
- Posts: 611
- Joined: Fri Sep 22, 2017 8:33 pm
- Has thanked: 279 times
- Been thanked: 101 times
Re: Virtual Midi Port/Cable
Well the method recommended by the qjackctl dev is to use it as a post startup script - https://www.rncbc.org/drupal/node/212 - but it doesn't seem to make a difference. I'm wondering if I need to enable some other JACK setting too.Kott wrote:a2j can work only when jackd is started
not sure that starting a2j* just after qjackctl is enough, even if qjackctl starts jackd automatically, so, maybe you need to insert some "sleep" in your command
Cadence can handle this case
I don't really want to install cadence because I don't need all of the other stuff it comes with. I just need a JACK settings control and the a2j bridge.
David Healey
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
-
- Established Member
- Posts: 821
- Joined: Thu Mar 21, 2013 12:55 am
- Location: Vladivostok
- Has thanked: 65 times
- Been thanked: 124 times
Re: Virtual Midi Port/Cable
there is option in qjackctl that allows inserting any command which will executed after start:
it can be necessary add "killall a2jmidid" to shutdown script for preventing spawning new instances after restart of the jackd
it works for meit can be necessary add "killall a2jmidid" to shutdown script for preventing spawning new instances after restart of the jackd
-
- Established Member
- Posts: 821
- Joined: Thu Mar 21, 2013 12:55 am
- Location: Vladivostok
- Has thanked: 65 times
- Been thanked: 124 times
Re: Virtual Midi Port/Cable
Sorry, I didn't read your post closely. This option doesn't work for You.
As some advice, it can be debugged:
strace -f qjackctl 2>/tmp/out
then search for a2jmidi in /tmp/out file
As some advice, it can be debugged:
strace -f qjackctl 2>/tmp/out
then search for a2jmidi in /tmp/out file
- d.healey
- Established Member
- Posts: 611
- Joined: Fri Sep 22, 2017 8:33 pm
- Has thanked: 279 times
- Been thanked: 101 times
Re: Virtual Midi Port/Cable
Nope didn't see anything in the out file. I think I'll give in and install Cadence.Kott wrote:Sorry, I didn't read your post closely. This option doesn't work for You.
As some advice, it can be debugged:
strace -f qjackctl 2>/tmp/out
then search for a2jmidi in /tmp/out file
David Healey
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
- d.healey
- Established Member
- Posts: 611
- Joined: Fri Sep 22, 2017 8:33 pm
- Has thanked: 279 times
- Been thanked: 101 times
Re: Virtual Midi Port/Cable
Yes, but how?Kott wrote:This is very odd.
Should we cast Rui (rncbc) for help?
David Healey
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.
YouTube - Free HISE scripting and sample library dev tutorials
Libre Wave - Freedom respecting instruments and effects.