Re: [LAU] midi triggering delay

From: James Cameron <quozl@email-addr-hidden>
Date: Tue Sep 08 2009 - 12:53:38 EEST

On Tue, Sep 08, 2009 at 10:14:24AM +0100, andy baxter wrote:
> - using a program which turns the computer keyboard into a virtual midi
> device. This makes the sound much more immediate. Having tried this, the
> contrast makes it obvious that there is still a problem with delays from
> the edirol keyboard.

Interesting. Let's consider that data path further.

1. flow from keyboard USB device to USB controller,

2. an interrupt,

3. flow from USB controller to processor.

Perhaps another device on the system is preventing the USB interrupt
from being processed in a timely fashion. See if you can quieten
devices one by one and see if the problem changes. For example you can
quieten a graphics driver by switching to the text console and then
resume playing the MIDI keyboard.

General suggestions for a USB flow rate problem ... try different USB
sockets, remove as many USB devices as possible, ensure the cable is
as short as possible, ensure the cable is standards compliant, and if
there is a way to power the device differently (e.g. a DC input socket),
then try it. I've even had particularly strange devices behave better
on a powered hub.

Your lsusb shows the device is attached to a USB 1.1 hub. There is a
Freecom Technologies device attached to a USB 2.0 hub. This might be
because the keyboard is only USB 1.1 complaint, I don't know.

Watch /proc/interrupts while trying to play, and see what counters
increment in the matrix. Here's a fun way ... run this in a terminal
window while playing keys on the MIDI keyboard ...

        watch -d --interval=0.1 cat /proc/interrupts

What is the kernel version? You mentioned Debian Testing and Ubuntu
Jaunty.

I've looked at the 2.6.30 sources (latest stable), and the USB device
you showed us in lspci "0582:0033 Roland Corp. EDIROL PCR" is listed in
sound/usb/usbmidi.c and also in sound/usb/usbquirks.h . There was
nothing funny about the quirks.

I've looked at the Ubuntu Jaunty 2.6.28 sources, and usbquirks.h for
this device is no different. usbmidi.c *does* have differences, in that
there have been several fixes in 2.6.30 that might be relevant. Nothing
about the changes looked like an exact match to your problem, but that
could be my inexperience.

I suggest you try downloading and booting from the Ubuntu Karmic Alpha
CD images that are available now. The newer kernel in those images may
change the timing problem for you.

-- 
James Cameron
http://quozl.linux.org.au/
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@email-addr-hidden
http://lists.linuxaudio.org/mailman/listinfo/linux-audio-user
Received on Tue Sep 8 16:15:02 2009

This archive was generated by hypermail 2.1.8 : Tue Sep 08 2009 - 16:15:02 EEST