??? MIDI transport -- UFX1204 -- Firewire vs. USB

Talk about your MIDI interfaces, microphones, keyboards...

Moderators: MattKingUSA, khz

Post Reply
jCandlish
Established Member
Posts: 4
Joined: Mon Jun 20, 2016 8:17 pm
Location: Switzerland
Been thanked: 1 time

??? MIDI transport -- UFX1204 -- Firewire vs. USB

Post by jCandlish »

Hello LinuxMusicians Forum

I'm hoping that I am posting this inquiry to the correct sub-forum.

I am having an unresolved issue with the MIDI transport control section of the Behringer UFX series desk. [UFX1204]

First some background.

This mixer is equipped with two interfaces. Firewire and USB.

I'm running a realtime kernel with a 1000hz tick.

Code: Select all

Linux w530 4.6.2-hz1000-rt3 #3 SMP PREEMPT RT Thu Jun 23 11:41:06 CEST 2016 x86_64 GNU/Linux
With firewire the following modules are loaded in:

Code: Select all

snd_firewire_lib       32768  1 snd_bebob
snd_rawmidi            32768  4 snd_firewire_lib,snd_bebob,snd_usbmidi_lib,snd_seq_midi
snd_pcm               106496  9 snd_firewire_lib,snd_pcm_oss,snd_usb_audio,snd_bebob,snd_hda_codec,snd_hda_intel,snd_hda_core
firewire_ohci          40960  0
firewire_core          65536  3 snd_firewire_lib,snd_bebob,firewire_ohci
crc_itu_t              16384  1 firewire_core
The USB interface uses the following modules:

Code: Select all

snd_usbmidi_lib        28672  1 snd_usb_audio
snd_seq_midi           16384  2
snd_seq_midi_event     16384  1 snd_seq_midi
snd_rawmidi            32768  2 snd_usbmidi_lib,snd_seq_midi
snd_seq                65536  10 snd_seq_midi_event,snd_seq_dummy,snd_seq_midi
snd_seq_device         16384  3 snd_seq,snd_rawmidi,snd_seq_midi
snd                    81920  26 snd_hda_codec_realtek,snd_pcm_oss,snd_usb_audio,snd_hwdep,snd_timer,snd_pcm,snd_seq,snd_rawmidi,snd_hda_codec_generic,snd_usbmidi_lib,snd_hda_codec,snd_hda_intel,thinkpad_acpi,snd_seq_device,snd_mixer_oss
usbcore               237568  8 btusb,snd_usb_audio,uvcvideo,snd_usbmidi_lib,ehci_hcd,ehci_pci,xhci_hcd,xhci_pci
The USB audio interface makes intermittent xruns, pretty much regardless of the buffer size or clock rate. Smaller is worse of course.

However the USB MIDI interface to-and-from the transport section of the desk is rock solid.

Contrarywise the Firewire audio interface runs perfectly with 0 xruns ...

However the Firewire MIDI interface from Ardour to the desk drops messages.

I have read that MIDI section of the linux Firewire stack is not respecting the protocol rate limit. ref: http://mailman.alsa-project.org/piperma ... 75912.html

Code: Select all

2.Data rate for MIDI substream
With current implementation, the maximum data rate for MIDI substream in 
out-stream is one eighth of sampling rate. For example, at 48.0kHz, it's 
6,000 bytes. This is excess over standard MIDI data rate, 3,125 bits per 
second. So a few devices can have buffer over flow when receiving much 
MIDI messages. For example, M-Audio Firewire 1814 transmits packets with 
discontinuity in this case. I guess that Fireworks based devices and 
some BeBoB based devices ignore MIDI messages in more than 8 data blocks 
of packets and this is vendor's effort for this issue.
Drivers need a throttle for this issue but this is for future work.
Conversely, the Firewire release notes say: https://ieee1394.wiki.kernel.org/index. ... Linux_3.19

Code: Select all

snd-firewire-lib
.       Limit MIDI transmission rate as per specification to prevent loss of messages. 
So I'm left to wonder what the actual status of the Firewire MIDI substream protocol is, as the behavior I see, dropped packets sent to the UFX1204, is consistent with overclocking. I am assuming that the message content is correct as the MIDI transport functions correctly when accessed via the USB interface.

How can I get the Firewire MIDI transport control working on this device?

Thanks
jCandlish

.
Post Reply