Ultralite AVB

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

Moderators: MattKingUSA, khz

Musinux
Established Member
Posts: 59
Joined: Sun Jan 14, 2018 8:38 pm
Has thanked: 3 times
Been thanked: 3 times

Re: Ultralite AVB

Post by Musinux »

bluebell wrote: Tue Mar 30, 2021 6:51 pm
Musinux wrote: Tue Mar 30, 2021 3:02 pm Can somebody with flawless playback post their configuration as detailed as possible (cmdline, irqs, priorities)?
I use kernel 5.8.6 meanwhile.

My interface is one of the older ones without ESS chips.

I let the interface boot until it's ready before I start the computer. No probs even after running the interface for longer than a week.

So, if you don't boot the Interface before the computer, you have problems? Is drumfix's patch the only thing you did, no irq-fiddling and such? Does it work with kernels higher than 5.8.x? Can you run hwlatdetect in the background without glitches?

Maybe my question about the flawless setup wasn't precise enough, I'ts still not clear to me if it's possible to run the interface flawless with more than certain firmware / kernel / patch / hardware (usb controller) combinations.

With my old 2500k setup and older ultralite firmware versions I got about 12h "flawless" playback (no drumfix patch).
With my new Ryzen3xxx setup and newer and older firmware versions on kernel 5.11/5.12 I get about 5h "flawless" playback, as long as I use the "right" USB-Port.

I switched to 88k2 kHz @ 3x128 buffersize recently, I don't have more or less xruns/channel hopping than on 44k1 @ 3x64 or 3x128.
I also have a lot less xruns since I use qjackctl instead of cadence again, which doesn't really make sense to me as well...
User avatar
bluebell
Established Member
Posts: 1909
Joined: Sat Sep 15, 2012 11:44 am
Location: Saarland, Germany
Has thanked: 111 times
Been thanked: 116 times

Re: Ultralite AVB

Post by bluebell »

Musinux wrote: Tue Mar 30, 2021 7:34 pm
bluebell wrote: Tue Mar 30, 2021 6:51 pm
Musinux wrote: Tue Mar 30, 2021 3:02 pm Can somebody with flawless playback post their configuration as detailed as possible (cmdline, irqs, priorities)?
I use kernel 5.8.6 meanwhile.

My interface is one of the older ones without ESS chips.

I let the interface boot until it's ready before I start the computer. No probs even after running the interface for longer than a week.

So, if you don't boot the Interface before the computer, you have problems? Is drumfix's patch the only thing you did, no irq-fiddling and such? Does it work with kernels higher than 5.8.x? Can you run hwlatdetect in the background without glitches?

Maybe my question about the flawless setup wasn't precise enough, I'ts still not clear to me if it's possible to run the interface flawless with more than certain firmware / kernel / patch / hardware (usb controller) combinations.

With my old 2500k setup and older ultralite firmware versions I got about 12h "flawless" playback (no drumfix patch).
With my new Ryzen3xxx setup and newer and older firmware versions on kernel 5.11/5.12 I get about 5h "flawless" playback, as long as I use the "right" USB-Port.

I switched to 88k2 kHz @ 3x128 buffersize recently, I don't have more or less xruns/channel hopping than on 44k1 @ 3x64 or 3x128.
I also have a lot less xruns since I use qjackctl instead of cadence again, which doesn't really make sense to me as well...
I got some strange effects like mono output when starting jackd too early.

I run it at 48000, bufsize 32 as a minimum, no special IRQ fiddling, no realtime kernel, just a lowlatency kernel. Changing bufsize with jack_bufsize on the fly doesn't break anything.

Most recent AVB firmware works fine.

Linux – MOTU UltraLite AVB – Qtractor – http://suedwestlicht.saar.de/

tvaz
Established Member
Posts: 24
Joined: Sun Nov 10, 2019 5:55 pm
Been thanked: 1 time

Re: Ultralite AVB

Post by tvaz »

Musinux wrote: Tue Mar 30, 2021 3:02 pm 5.11.x-zen without drumfix' patches and without setting irq-priority gives some hours of playback without distortion, but channel hopping occurs quite soon after starting jack. Patching modulo8 even helps with 4 outputs, but isn't ideal of course.
Old story, sometimes it takes forever without breaking, even under high average or peak load, but it will break.
It even resumes fine from suspend with everything still working...

With drumfix' patch and nearly any combination of boot options and irq-tweaking, channel hopping or distortion happens in a few minutes (at least with 5.11.x and next- kernels).

Can somebody with flawless playback post their configuration as detailed as possible (cmdline, irqs, priorities)?

Does anybody have stable playback while running the following as root:

Code: Select all

hwlatdetect --duration 60 --threshold=15
I sometimes use that to glitch-fix, because it makes channel hopping happen so fast.
I've been playing with more than 10 kernel versions, 3 different computers, irq tweaking, drumfix's patch and so on for a long time now. Every attempt will give me the known issues at some point.

In summary: when using drumfix's patch I get a little more time of stability. Using a Lenovo x1 (which is the less powerful of these 3 computers I'm testing on) I was even able to perform a daily recording session during a few weeks with no issue. *But*, once I put a big I/O load on any computer, and no matter which kernel/distro/patch I'm using, I'll have the issues back. So, answering your question: yes, hwlatdetect gives me distortion a few seconds after I run it.

After months of many tests and frustration I tend to believe that the AVB series cannot work 100% stable in a Linux system, not yet. If it seems to work for weeks, it's likely that we probably didn't push enough load in order to wake up the little evil. I lived myself about a month thinking that everything was working fine, until the day I decided to push further a load test.
ericfontainejazz
Established Member
Posts: 4
Joined: Tue Jan 20, 2015 3:10 pm

Re: Ultralite AVB

Post by ericfontainejazz »

My Motu UltraLite AVB is getting a very reliable AVB audio stream with the latest Drumfix avb4linux ALSA driver (https://github.com/Drumfix/avb4linux) on Arch Linux (core repo kernel 5.11.11.arch1-1). If I go to my Motu UltraLite AVB's routing config page and set one channel to directly loopback the AVB input to the AVB output, and then run the precise time measurement tool jack_delay with that capture port and input port, then I get the following roundtrip latency measurements (which do include the inherent jack buffering latency) at 44.1 kHz for the following buffer_size settings form a 6-frame buffer setting at minimum to a 1024-frame buffer setting at maximum:

6-frame buffer: 44.000 frames 0.998 ms
7-frame buffer: 47.000 frames 1.066 ms
8-frame buffer: 50.000 frames 1.134 ms
9-frame buffer: 53.000 frames 1.202 ms
10-frame buffer: 56.000 frames 1.270 ms
11-frame buffer: 59.000 frames 1.338 ms
12-frame buffer: 62.000 frames 1.406 ms
13-frame buffer: 65.000 frames 1.474 ms
14-frame buffer: 68.000 frames 1.542 ms
15-frame buffer: 71.000 frames 1.610 ms
16-frame buffer: 74.000 frames 1.678 ms
17-frame buffer: 77.000 frames 1.746 ms
18-frame buffer: 80.000 frames 1.814 ms
24-frame buffer: 98.000 frames 2.222 ms
30-frame buffer: 116.000 frames 2.630 ms
32-frame buffer: 122.000 frames 2.766 ms
36-frame buffer: 134.000 frames 3.039 ms
42-frame buffer: 152.000 frames 3.447 ms
48-frame buffer: 170.000 frames 3.855 ms
54-frame buffer: 188.000 frames 4.263 ms
60-frame buffer: 206.000 frames 4.671 ms
64-frame buffer: 218.000 frames 4.943 ms
128-frame buffer: 410.000 frames 9.297 ms
256-frame buffer: 794.000 frames 18.005 ms
512-frame buffer: 1562.000 frames 35.420 ms
1024-frame buffer: 3098.000 frames 70.249 ms

(Note: there is an additional .950 ms latency to go from my UltraLite's physical audio DAC through my headphones into a mic and back into the UItraLite's ADC.)

I get these same latency measurements even if I use the Motu AVB Switch in between my computer's i210 network card and my UltraLite or if directly connect my computer's i210 network card to the UltraLite.

Turns out there is a nice simple relationship between latency in frames & buffer_size:

latency in frames = 26 + 3*buffer_size

(and can calculate the latency in milliseconds by dividing frames by 44.1)

Even on reboot, the latency is deterministic according to that equation. For 48 kHz, I get latency in frames = 28 + 3*buffer_size

I've measured a sine wave sent from my computer to audacity and looped back through the motu and I'm able to get a clean signal back, for at least an hour. (Though I did have a couple xruns in that hour, but that was simply a fault of my cpu failing to keep up). I get quite a few xruns with 6 samples, but at 12 samples it is very reliable with only the occasional xrun on my AMD Ryzen 5 1600 Six-Core Processor computer, though of course your mileage may vary on your computer.

(note: however on the other hand if I try to use my UltraLite AVB over USB, the audio connection is very unreliable and gets lots of glitches)
alcomatt
Established Member
Posts: 8
Joined: Sat Mar 31, 2018 9:57 pm

Re: Ultralite AVB

Post by alcomatt »

ericfontainejazz wrote: Sun Apr 04, 2021 3:28 am My Motu UltraLite AVB is getting a very reliable AVB audio stream with the latest Drumfix avb4linux ALSA driver (https://github.com/Drumfix/avb4linux) on Arch Linux (core repo kernel 5.11.11.arch1-1). If I go to my Motu UltraLite AVB's routing config page and set one channel to directly loopback the AVB input to the AVB output, and then run the precise time measurement tool jack_delay with that capture port and input port, then I get the following roundtrip latency measurements (which do include the inherent jack buffering latency) at 44.1 kHz for the following buffer_size settings form a 6-frame buffer setting at minimum to a 1024-frame buffer setting at maximum:

6-frame buffer: 44.000 frames 0.998 ms
7-frame buffer: 47.000 frames 1.066 ms
8-frame buffer: 50.000 frames 1.134 ms
9-frame buffer: 53.000 frames 1.202 ms
10-frame buffer: 56.000 frames 1.270 ms
11-frame buffer: 59.000 frames 1.338 ms
12-frame buffer: 62.000 frames 1.406 ms
13-frame buffer: 65.000 frames 1.474 ms
14-frame buffer: 68.000 frames 1.542 ms
15-frame buffer: 71.000 frames 1.610 ms
16-frame buffer: 74.000 frames 1.678 ms
17-frame buffer: 77.000 frames 1.746 ms
18-frame buffer: 80.000 frames 1.814 ms
24-frame buffer: 98.000 frames 2.222 ms
30-frame buffer: 116.000 frames 2.630 ms
32-frame buffer: 122.000 frames 2.766 ms
36-frame buffer: 134.000 frames 3.039 ms
42-frame buffer: 152.000 frames 3.447 ms
48-frame buffer: 170.000 frames 3.855 ms
54-frame buffer: 188.000 frames 4.263 ms
60-frame buffer: 206.000 frames 4.671 ms
64-frame buffer: 218.000 frames 4.943 ms
128-frame buffer: 410.000 frames 9.297 ms
256-frame buffer: 794.000 frames 18.005 ms
512-frame buffer: 1562.000 frames 35.420 ms
1024-frame buffer: 3098.000 frames 70.249 ms

(Note: there is an additional .950 ms latency to go from my UltraLite's physical audio DAC through my headphones into a mic and back into the UItraLite's ADC.)

I get these same latency measurements even if I use the Motu AVB Switch in between my computer's i210 network card and my UltraLite or if directly connect my computer's i210 network card to the UltraLite.

Turns out there is a nice simple relationship between latency in frames & buffer_size:

latency in frames = 26 + 3*buffer_size

(and can calculate the latency in milliseconds by dividing frames by 44.1)

Even on reboot, the latency is deterministic according to that equation. For 48 kHz, I get latency in frames = 28 + 3*buffer_size

I've measured a sine wave sent from my computer to audacity and looped back through the motu and I'm able to get a clean signal back, for at least an hour. (Though I did have a couple xruns in that hour, but that was simply a fault of my cpu failing to keep up). I get quite a few xruns with 6 samples, but at 12 samples it is very reliable with only the occasional xrun on my AMD Ryzen 5 1600 Six-Core Processor computer, though of course your mileage may vary on your computer.

(note: however on the other hand if I try to use my UltraLite AVB over USB, the audio connection is very unreliable and gets lots of glitches)
How did you manage to hook it up to jack? I can bring the avb connection up, i can see the pcm device and the avb stream is showing on ultralite's web console but does not matter what i do I cannot get the jack to start using the avb pcm device. I would appreciate any pointers...
ericfontainejazz
Established Member
Posts: 4
Joined: Tue Jan 20, 2015 3:10 pm

Re: Ultralite AVB

Post by ericfontainejazz »

alcomatt wrote: Mon Apr 05, 2021 6:16 pm How did you manage to hook it up to jack? I can bring the avb connection up, i can see the pcm device and the avb stream is showing on ultralite's web console but does not matter what i do I cannot get the jack to start using the avb pcm device. I would appreciate any pointers...
These are the JACK settings that work for me with the alsa AVB device:
2021-04-06_10-06.png
2021-04-06_10-06.png (70.27 KiB) Viewed 33725 times
alcomatt
Established Member
Posts: 8
Joined: Sat Mar 31, 2018 9:57 pm

Re: Ultralite AVB

Post by alcomatt »

ericfontainejazz wrote: Tue Apr 06, 2021 2:07 pm
alcomatt wrote: Mon Apr 05, 2021 6:16 pm How did you manage to hook it up to jack? I can bring the avb connection up, i can see the pcm device and the avb stream is showing on ultralite's web console but does not matter what i do I cannot get the jack to start using the avb pcm device. I would appreciate any pointers...
These are the JACK settings that work for me with the alsa AVB device:

2021-04-06_10-06.png
Thanks a lot!. How many input/output did you set in the Config sectiom? 8/8?
ericfontainejazz
Established Member
Posts: 4
Joined: Tue Jan 20, 2015 3:10 pm

Re: Ultralite AVB

Post by ericfontainejazz »

alcomatt wrote: Tue Apr 06, 2021 3:14 pm
ericfontainejazz wrote: Tue Apr 06, 2021 2:07 pm
alcomatt wrote: Mon Apr 05, 2021 6:16 pm How did you manage to hook it up to jack? I can bring the avb connection up, i can see the pcm device and the avb stream is showing on ultralite's web console but does not matter what i do I cannot get the jack to start using the avb pcm device. I would appreciate any pointers...
These are the JACK settings that work for me with the alsa AVB device:

2021-04-06_10-06.png
Thanks a lot!. How many input/output did you set in the Config sectiom? 8/8?
Yes, in fact I only only able to get it working with 8 inputs and 8 outputs, and the same sampling rate as the driver was set to.
DellyRosen
Posts: 1
Joined: Thu Apr 08, 2021 3:20 pm

Re: Ultralite AVB

Post by DellyRosen »

Hi...When set up appropriately, the AVB Matrix (Routing Tab) need not be gotten to again until actual switches in gear association are made. It is basically set and neglect. You will not have to get to the lattice while adding VIs in DP.

I agree that comprehension of AVB directing is at first to some degree a test. As I noted in the other string in which you communicated worries on August 5, the recordings can be useful. All things considered, it seems like you could utilize some close to home assistance. Maybe we can offer it here.

buy pcb online
Last edited by DellyRosen on Thu Apr 29, 2021 4:36 pm, edited 1 time in total.
User avatar
fohdeesha
Established Member
Posts: 3
Joined: Mon Apr 12, 2021 6:44 am
Location: Indianapolis
Has thanked: 3 times
Been thanked: 3 times
Contact:

Re: Ultralite AVB

Post by fohdeesha »

Hey all - I managed to get root on the Ultralite AVB (the embedded linux OS that runs on it). I don't know if it could be of any use to you guys (probably not), but perhaps it could at least be of some assistance during debug (I certainly saw some messages regarding USB events in the root telnet console and dmesg that didn't show up anywhere else) - https://forums.servethehome.com/index.p ... otu.32564/
shellwalker
Established Member
Posts: 68
Joined: Sun Jan 03, 2021 1:54 pm
Has thanked: 21 times
Been thanked: 11 times

Re: Ultralite AVB

Post by shellwalker »

fohdeesha wrote: Mon Apr 12, 2021 6:50 am Hey all - I managed to get root on the Ultralite AVB (the embedded linux OS that runs on it). I don't know if it could be of any use to you guys (probably not), but perhaps it could at least be of some assistance during debug (I certainly saw some messages regarding USB events in the root telnet console and dmesg that didn't show up anywhere else) - https://forums.servethehome.com/index.p ... otu.32564/
This is..... AWESOME!!!

Maybe that could give some insights on what's going on at the other end of the USB...

MOTU 828mk3, MOTU 828ES, Cakewalk by Bandlab, Kubuntu 22.04.1 LTS, https://github.com/shellwalker-coder/motu_patch_testing

User avatar
bluebell
Established Member
Posts: 1909
Joined: Sat Sep 15, 2012 11:44 am
Location: Saarland, Germany
Has thanked: 111 times
Been thanked: 116 times

Re: Ultralite AVB

Post by bluebell »

fohdeesha wrote: Mon Apr 12, 2021 6:50 am Hey all - I managed to get root on the Ultralite AVB (the embedded linux OS that runs on it). I don't know if it could be of any use to you guys (probably not), but perhaps it could at least be of some assistance during debug (I certainly saw some messages regarding USB events in the root telnet console and dmesg that didn't show up anywhere else) - https://forums.servethehome.com/index.p ... otu.32564/
What a tragedy. It runs Linux but works best with Windows and Mac.

Linux – MOTU UltraLite AVB – Qtractor – http://suedwestlicht.saar.de/

tvaz
Established Member
Posts: 24
Joined: Sun Nov 10, 2019 5:55 pm
Been thanked: 1 time

Re: Ultralite AVB

Post by tvaz »

bluebell wrote: Mon Apr 12, 2021 10:37 am
fohdeesha wrote: Mon Apr 12, 2021 6:50 am Hey all - I managed to get root on the Ultralite AVB (the embedded linux OS that runs on it). I don't know if it could be of any use to you guys (probably not), but perhaps it could at least be of some assistance during debug (I certainly saw some messages regarding USB events in the root telnet console and dmesg that didn't show up anywhere else) - https://forums.servethehome.com/index.p ... otu.32564/
What a tragedy. It runs Linux but works best with Windows and Mac.
This.

I got really upset with Motu after many many frustrated attempts. Sold my device and now I have a setup that works for real. It's a Zoom F6 + USB/MIDI interface. This Zoom is quite limited in terms of outputs, but offers a 6 high quality preamps and a battery-powered field recorder as extra feature :-)
baptiste
Established Member
Posts: 26
Joined: Sat Oct 06, 2018 7:18 am
Has thanked: 10 times
Been thanked: 8 times

Re: Ultralite AVB

Post by baptiste »

fohdeesha wrote: Mon Apr 12, 2021 6:50 am Hey all - I managed to get root on the Ultralite AVB (the embedded linux OS that runs on it). I don't know if it could be of any use to you guys (probably not), but perhaps it could at least be of some assistance during debug (I certainly saw some messages regarding USB events in the root telnet console and dmesg that didn't show up anywhere else) - https://forums.servethehome.com/index.p ... otu.32564/
Awesome. Now we have to find the pesky slowly_and_randomly_drift() function :)
shellwalker
Established Member
Posts: 68
Joined: Sun Jan 03, 2021 1:54 pm
Has thanked: 21 times
Been thanked: 11 times

Re: Ultralite AVB

Post by shellwalker »

bluebell wrote: Mon Apr 12, 2021 10:37 am What a tragedy. It runs Linux but works best with Windows and Mac.
You nailed it!! :roll:

MOTU 828mk3, MOTU 828ES, Cakewalk by Bandlab, Kubuntu 22.04.1 LTS, https://github.com/shellwalker-coder/motu_patch_testing

Post Reply