Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't work with the M-Audio Keystation MK3 and possibly other devices that generate two alsa ports on the same device #25

Open
rtega opened this issue Mar 22, 2024 · 4 comments

Comments

@rtega
Copy link

rtega commented Mar 22, 2024

The M-Audio Keystation Mk3 has two ports on it's Alsa device: one for the keys on the keyboard and the second for the control and transport buttons. When running the command a2jmidid -e this generates the follow messages:

JACK MIDI <-> ALSA sequencer MIDI bridge, version 9 built on Thu Jan  1 01:00:00 1970
Copyright 2006,2007 Dmitry S. Baikov
Copyright 2007,2008,2009,2011,2012 Nedko Arnaudov

Bridge starting...
Using JACK server 'default'
Hardware ports will be exported.
Bridge started
Press ctrl-c to stop the bridge
port created: Midi Through [14] (capture): Midi Through Port-0
port created: Midi Through [14] (playback): Midi Through Port-0
port created: Keystation 88 MK3 [28] (capture): Keystation 88 MK3 Keystation 88
port created: Keystation 88 MK3 [28] (playback): Keystation 88 MK3 Keystation 88
ERROR: a2j_port_create: jack_port_register() failed for 'Keystation 88 MK3 [28] (capture): Keystation 88 MK3 Keystation 88'
ERROR: a2j_port_create: jack_port_register() failed for 'Keystation 88 MK3 [28] (playback): Keystation 88 MK3 Keystation 88'

This also gives the following message on the jackd side:

port_name "a2j:Keystation 88 MK3 [28] (capture): Keystation 88 MK3 Keystation 88" already exists
port_name "a2j:Keystation 88 MK3 [28] (playback): Keystation 88 MK3 Keystation 88" already exists

This renders the control and transport buttons unusable unless you manually setup a bridge. Using the -u option does nothing to solve this problem.

@rtega
Copy link
Author

rtega commented Mar 23, 2024

Some aditional info: amidi -l shows:

Dir Device    Name
IO  hw:3,0,0  Keystation 88 MK3 Keystation 88
IO  hw:3,0,1  Keystation 88 MK3 Keystation 88

According to this thread on linuxmusicians the naming convention in the kernel changed after kernel 5.11 thus confusing a2jmidid.

This looks to be a bug in a2jmidid.

@rtega
Copy link
Author

rtega commented Mar 23, 2024

I compiled the daemon from source here and the issue is already resolved on this latest version but not the ubuntu 22.04 version that I used before. I'll file a bug against ubuntu then. I see that this has been solved with pull request #5 .

@romsom
Copy link
Contributor

romsom commented Mar 26, 2024

Actually there never was a new release/tag after the fix had been merged. The last release still shows the behaviour you described. Unless Ubuntu wants to pull in the fix manually...

If you had a look at the conversation for the PR you know @nedko pointed out it would possibly break existing scripts and sessions because of the changes to the port naming convention. So as a result he didn't want to merge it into his re-adopted (for the lack of a better word) reverse-fork.

I still use the a2jmidid-git package from AUR, but I still would like to have this fixed in a future release (whoever might tag it). I'll see if I can find some time after the holidays to build the switch to optionally disable the fix for old setups.

@rtega
Copy link
Author

rtega commented Mar 26, 2024

Thanks for your comment. I didn't look at the comment as it fixed the issue in my case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants