Commit f4091558 authored by Markus Mueller-Trapet's avatar Markus Mueller-Trapet

bugfix if instrument control toolbox is not available

parent 848c7178
......@@ -12,14 +12,15 @@
try %#ok<TRYNC>
dbquit all
end
warning off %#ok<WNOFF>
warning off
clear classes %RSC - needed to clean class references in case of changes
clear global %RSC - needed to clean up global variables from preferences or mpb_filter and free memory
clear java %RSC - reduces trouble with figures
if usejava('jvm') %Only if jvm available (non_cluster)
s_obj = instrfind();
if ~isempty(s_obj)
if exist('instrfind','file')
s_obj = instrfind();
if ~isempty(s_obj)
for idx = 1:length(s_obj)
if strcmpi(s_obj(idx),'closed')
......@@ -29,7 +30,8 @@ if ~isempty(s_obj)
disp([' deleting: ' s_obj(idx).Name '...']);
delete(s_obj(idx));
end
end
end
end
end
if exist('playrec','file')
......@@ -52,6 +54,6 @@ if usejava('jvm') % bugfix mpo
end
clc
warning on %#ok<WNON>
warning on
warning off MATLAB:log:logOfZero
warning off MATLAB:pfileOlderThanMfile
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment