Jack/Alsa Midi Question

9 replies [Last post]
Edward Diehl
User offline. Last seen 2 weeks 1 day ago. Offline
Joined: 2007-02-01
Posts:

Ardour3 uses Jack midi so I am trying to see if I can get my midi devices to show up in Jack Midi without running a2jmidid. I have learned that if one runs Jack with an Alsa driver + the Midi "seq" driver (i.e. using qjackctl to run Jack) that my USB keyboard will show up in Jack Midi. If I use midi driver "none" or "raw" the keyboard shows up in Alsa midi.

However, if I use a firewire audio interface my keyboard plugged into my firewire device that shows up in Jack Midi, but my 2nd keyboard (Akai mini keyboard which only has USB midi) shows up in Alsa midi, so I have to use aj2midid to send it to Jack Midi. When using firewire there is no option to use the "seq" midi driver, I suppose because this is part of the Alsa driver which I'm not using.

So it would seem that if one uses a firewire device with a USB keyboard then there is not choice but to use aj2midid to see the USB keyboard in Jack midi. Is this true? Ok, running aj2midid is not terrible, but I'm just trying to simplify where possible.

paul
paul's picture
User offline. Last seen 4 days 22 hours ago. Offline
Joined: 2006-03-16
Posts:

@Edward: you are correct: a2jmidid -e is the best option, for all cases actually. It has better timing (jitter & latency) characteristics than the code which implements the "seq" and "raw" options of the ALSA backend. Eventually, the functionality of a2jmidi will be more easily available. It also provides "better" port names (well, more human readable ones anyway).

Edward Diehl
User offline. Last seen 2 weeks 1 day ago. Offline
Joined: 2007-02-01
Posts:

Thanks for the information. I will just run a2jmidid -e all the time, and set the Midi driver to none. I wrote a jack start script to use with qjackctl to start a2jmidid automatically (execute after startup):

#!/bin/bash
### Connect to a2jmidid if already running
if [[ `ps -C a2jmidid -o pid=` != "" ]]; then
/usr/bin/a2j_control start
### else start a2jmidid if is not running
else
/usr/bin/a2jmidid -e &
fi

Scary-Hallo
Scary-Hallo's picture
User offline. Last seen 17 hours 26 min ago. Offline
Joined: 2009-02-13
Posts:

Good idea!
Thanks for the script

leokin
User offline. Last seen 4 weeks 1 day ago. Offline
Joined: 2012-01-28
Posts:

How exactly do you execute this script? Do you paste it somewhere?

paul
paul's picture
User offline. Last seen 4 days 22 hours ago. Offline
Joined: 2006-03-16
Posts:

Note that in the latest version of JACK1 (0.124.x) the functionality of a2jmidid is now built in.

leokin
User offline. Last seen 4 weeks 1 day ago. Offline
Joined: 2012-01-28
Posts:

How do I find out if I have JACK1 (0.124.x ?

paul
paul's picture
User offline. Last seen 4 days 22 hours ago. Offline
Joined: 2006-03-16
Posts:

In a terminal window, run this command: jackd -v or check with your distribution's software package management software for version information.

bassbass
User offline. Last seen 16 weeks 4 days ago. Offline
Joined: 2010-07-18
Posts:

Is it planned to back-port these feature into jack2?

paul
paul's picture
User offline. Last seen 4 days 22 hours ago. Offline
Joined: 2006-03-16
Posts:

@bassbass: i am not involved in the development of jack2. it already has some aspects of the work done on jack1, but not really on Linux. so far there has been no sign of any interest except for the new meta-data API (unrelated to the current discussion).