[Musix-users] [BUG] USB-MIDI not working with realtime-kernels

Jens Gulden mail at jensgulden.de
Fri Nov 3 19:58:08 CET 2006


Hello everybody, especially Marcos,

can you confirm this bug?: Realtime-patches confuse ALSA's USB-MIDI functionality.

Using Musix's realtime-kernels, MIDI-events from and to USB-MIDI devices get not passed between 
clients when the device is connected inside ALSA's sequencer API. E.g. using "'device' -> timidity" 
(connected via aconnect if available, or qjackctl's midi-connections-tab), the MIDI events seem to 
get stuck in an internal buffer:
cat /proc/asound/card2/midi0 ->

MidiSport 2x2

Output 0
   Tx bytes     : 0
Output 1
   Tx bytes     : 0
Input 0
   Rx bytes     : 1186
   Buffer size  : 4096
   Avail        : 1186  <--- ### SHOULD BE ZERO, NOT =RX BYTES! ###
   Overruns     : 0
Input 1
   Rx bytes     : 0

Instead of passing the data further to the connected timidity in this example, it remains in some 
kind of receive-buffer. When 4096 is reached, overruns start to count up. Connections have been set 
up using qjackctl, vkeybd->timidity works.

When outputting MIDI-events, the same behaviour applies to an output-buffer.

See also http://lists.ourproject.org/pipermail/musix-users/2006-October/000366.html.

However, using the "amidi" tool from the alsa-utils package (can be compiled from source on Musix), 
MIDI events show up correctly. The problem thus might not originate from a device-driver, but 
probably somewhere in ALSA's sequencer API. I'm not an ALSA expert, however. Thanks to Clemens 
Ladisch for the hint about amidi.

Booting the non-realtime kernels of the different Musix versions, everything related to MIDI works fine.

Tested Musix versions: 0.39, 0.49, 0.50, 0.59 (from cd-rom only, no hd-install).
Tested USB-Hardware:
- M-Audio Midisport 2x2 (on 0.49, 0.50 with added firmware)
- Edirol UM-1 (no firmware needed)
both devices get properly recognized by the system with both types of kernels (otherwise they 
couldn't get connected via the midi-connect-tab), but on realtime-kernels the above problem occurs
Tested Computer-Hardware:
- 800 MHz Pentium desktop-PC
- 500 MHz Celeron old notebook
- 1,4 GHz Pentium-M new notebook

Marcos, can you please add this at https://www.musix.org.ar/drupal/?q=forum/16 if it confirms to be 
a bug? (I don't know if the bug list is actually in use...)

Thanks for the work on Musix,
Jens



More information about the Musix-users mailing list