Revision [21063]

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

 

Latency Measurement of your Audio Interface


How to measure the latency of your audio interface?

If found my way to measure what I wanted to measure.

I wanted to measure the delay my DAW needs to get a external signal and output it again. Actually it is possible to do it with one computer, but I wanted to separate the measuring system (my laptop) and the measured system (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.

Conection plan between measuring computer (MC) and DAW.

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


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

Download:
Unknown action ""fileview""

Script: OctaveGeneratingATestFile


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 ath the time line of Audacity to check the latency of your DAW.

You can also 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