forked from DIDSR/eeDAP
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstage_get_pos.m
More file actions
29 lines (28 loc) · 828 Bytes
/
stage_get_pos.m
File metadata and controls
29 lines (28 loc) · 828 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
function stage=stage_get_pos(stage,h_stage)
% instrfind returns the instrument object array
% objects = instrfind
% each entry includes the type, status, and name as follows
% Index: Type: Status: Name:
% 1 serial closed Serial-COM4
%
% objects can be cleared from memory with
% delete(objects)
try
stage_label = stage.label;
if strcmp(stage_label(end-4:end),'Prior')
if exist('h_stage', 'var') == 0
stage = stage_get_pos_prior(stage);
else
stage = stage_get_pos_prior(stage,h_stage);
end
else
if exist('h_stage', 'var') == 0
stage = stage_get_pos_Ludl(stage);
else
stage = stage_get_pos_Ludl(stage,h_stage);
end
end
catch ME
error_show(ME)
end
end