DIfference between ALSA midi, legacy ALSA midi, ALSA Jack1 and ALSA Jack2

Hello,
Today I switched from Ardour5 to Ardour6 via Ubuntu 20.04 and Ardour6 backport repos.
I noticed, that I cant now use ALSA Audio directly. In Ardour5 I used JACK).

When I create a new project I can select Audiosystem: ALSA and now I can (and have to) use ALSA Midi directly (raw or sequencer). This is very nice. On Midi, the latency is faster then with JACK-Midi in Ardour5.

What I’m trying to understand:
When I use Audiosystem: JACK I can select MIDI System: legacy (raw or seq), ALSA JACK1 and ALSA JACK2. But I cant figure out the difference.

At first I thought, legacy works like in ALSA Audio mode, so that I can use ALSA Midiports directly.
But this is not the case. I don’t get the ALSA MIDI Ports, but the JACK-MIDI-Ports are available. (I don’t need the a2jmidid anymore, my JACK version is 1.9.12, so I think jackd is started with -X alsa_midi from Ardour6) and the names of the ports are system_midi_capture_# / system_midi_playback_#

But the same happens, if I select ALSA JACK2 (never tried ALSA JACK1 because of my JACK version 1.9.12). I get the JACK-MIDI-Ports with their generic names.

In both cases (legacy ALSA and ALSA JACK2) the latency of MIDI (from hitting a masterkeyboards key to hearing a sound is not so good as in Audiosystem: ALSA +ALSA Midi).

Can someone explain the difference between legacy ALSA and ALSA JACK2 (what is recommended by the manual)?
And what’s the reason why I can’t use JACK Audio + ALSA Midi?

Thank You, and happy new year to everybody.

JACK2 has no builtin support for interacting with hardware MIDI ports. It is necessary to start a2jmidi -e to get these ports to be accessible.

JACK1 has support for MIDI builtin. It effectively includes the code for a2jmidi, with a few minor improvements (including port naming).

Both JACK1 and JACK2 MIDI ultimately uses ALSA MIDI (just like the audio side also always uses ALSA audio), but getting things set up is different. In addition, there is the difference between them using the ALSA sequencer MIDI API (where events are delivered to a routing system not unlike JACKs) and the ALSA raw MIDI API (where events are delivered directly to the port hardware).

1 Like

Hello Paul, and thank you for fast reply.
I’m still confused about these options and versions. I have a jackd version 1.9.12. So it is JACK2, right?
In Audio:ALSA everything looks clear. (direct ALSA midi with raw)
In Audio:JACK and (legacy) ALSA Midi raw jackd is startet and in qjackctl I get new JACK-Midi-Ports with generic names under system (midi_capture_#/ midi_playback_#). They are connected to my ALSA-Midi-Ports. When I create Midi-Tracks in Ardour, I can connect the tracks to this JACK-Midi-Ports. But I do not start a2jmidi, it works out of the box. ps aux doesnt show an a2jmidi process.
In Audio:JACK and JACK2 Midi it looks the same: no a2jmidi process, the MIDI-Ports are available with generic names and show up in JACK-Midi of qjackctl in system section.
So, what’s the difference between JACK Audio+(legacy) ALSA Midi and JACK Audio+JACK2 Midi?
Sorry for my persistence and stupidity.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.