So I would like to play a sound during experimentatation.
The code snippet so far:
-------------------------------------------------
InitializePsychSound(1);
pahandle = PsychPortAudio('Open', [], [], 3, Fsc, nrchannels, [], [], [], []); %'4' and '16' for max speed
PsychPortAudio('Fillbuffer', pahandle, probetone);
PsychPortAudio('Start', pahandle, 1, 0, 1);
--------------------------------------------------
Now for timing purposes I wish to add a GetSecs command right after the playback has finished. However, in the current script, the tone is still playing while the Matlab script is running along.
So the regular Matlab function
-----------------------------------------
playblocking(probe);
-----------------------------------------
...blocks further activity until playback is finished. is there an alternative in PTB-3 for this function?