Revision [21065]

This is an old revision of AudioLatencyMeasurement made by ToBo on 2015-03-16 23:11:31.

 

Latency Measurement of your Audio Interface


How to measure the latency of your audio interface?

If found my way to measure the total latency of my DAW. I wanted to measure the total delay, my DAW needs to get a external signal feed it through the DAW and output it again. Actually, I can imagine to measure it with with one computer, but I wanted to separate the measuring system (my laptop) and the measured system (the DAW).

The idea is to generate a white noise signal with a duration of 100 ms, repeated every 1 second and to send this signal from another computer to the DAW. I also connected the return signal from my DAW to the first channel of my laptop (measuring computer). Beside this, to eliminate the unknown latency of the measuring computer, I connect the other second output channel of the computer to the second input channel of the computer.

Here is a short summary of the connection plan between measuring computer (MC) and DAW. It depends on your measuring computer (MC) and DAW what kind of cables you need to connect them.

MC right out --> DAW in
MC left out --> MC left in
DAW out --> MC right in


I generated the test audio file using Octave. You can download the test file or generate it by yourself using the script.

Download:
Unknown action ""fileview""

Generator script: OctaveGeneratingATestFile


Now it's time to measure. I used Audacity to play the file while recording in stereo both input channels. The file is mono and should output at both channels the same signal. Make sure you record just the input channel of your computer. There must not be any internal audio link to the recorded channels.



Finally, I've got this recorded file. And now you can take a look at the time line of Audacity to check the latency of your DAW.

Alternatively, you can use the second script I wrote to automatically analyse the file. The script outputs the latency and a graph as viewed below.




You need this analysis script, if yo want Octave to measure your latency.
% Andraes Tobola, March 2015
% Analyse a test file for audio latency 
clc
clear

fs = 44100; % Sampling rate
fn = 'latency_meas1.wav'; % Filenemae

x = auload(fn);

y = abs(x);

yi = y(:,1);
yo = y(:,2);

N = length(yi);

tl = linspace(0, N/fs, N);

th= .05; % Threshold

idx_i = find(yi>th,1);
idx_o = find(yo>th,1);

ti = idx_i / fs;
to = idx_o / fs;

hold off
plot(tl,y);
hold on
m = max(max(y));
plot([ti ti],[0 m],'r')
plot([to to],[0 m],'r')
xlabel('Time (s)')
ylabel('Rectified audio samples')
grid on
legend('Input','Output')

L = (to - ti); % Latency in seconds

disp (['Latency: ' num2str(round(L*100000)/100) ' ms' ])



Final I've got a latency of 8.62 ms using my FCA1616. No remarkable delay at all playing a guitar. I need to see if I get drop outs the next days.
Edit on the next day: The DAW has drop outs approx. every 20 Minutes, lasting up to 5 seconds.


Siehe auch
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki