Script crashes after multiple sounds - 'Error using sound (line 76) boost::thread_resource_error'
4 views (last 30 days)
Show older comments
I am running a script for an experiment that sends triggers through a parallel port, followed by playing a sound, and so on. This happens 60 times but it is crashing on the 48th-50th run every time.
for i=1:cfg.ncycles
disp([num2str(i) ' on']);
putvalue(dio,2);
wait(0.01);
putvalue(dio,0);
sound(y2,Fs2);
wait(cfg.ontime);
disp('off');
putvalue(dio,4);
wait(0.01);
putvalue(dio,0);
sound(y3,Fs3);
wait(cfg.offtime);
end;
The error I get is:
Error using sound (line 76)
Unexpected exception in plug-in:
'boost::thread_resource_error'
Error in brushscs (line 68)
sound(y3,Fs3);
The version of MATLAB is 2014a on a 32bit computer. I do not get the same error on 2017a on a 64bit PC but need to run it on the 32bit version for practical reasons.
Has anyone encountered this error in the same or a similar situation?
0 Comments
Answers (0)
See Also
Categories
Find more on Audio I/O and Waveform Generation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!