I want to fetch multiple USB microphones simultaneously in Matlab (2012a). However, two recording functions are both short-legged.
1, recordblocking() - It allows user to specify the duration of recording, but each microphone has to be recorded IN ORDER. So I don't know any way to make it recording simultaneously.
2, record() - It allows user to record multiple signals simultaneously, but it is only run for 1 second (roughly).
The code I used was the following:
recObj1 = audiorecorder(44100, 16, 1, 1);
recObj2 = audiorecorder(44100, 16, 1, 3);
disp('Start speaking.')
% recordblocking(recObj1, n);
% recordblocking(recObj2, n);
disp('Real recording.')
% by the way, the following function doesn't take 'on' as the second argument as opposed to what the internal/external documentation says
record(recObj1, 1);
record(recObj2, 1);
disp('End of Recording.');
So basically, I couldn't achieve simultaneously recording for multiple microphone inputs for n seconds long. Please help.