-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathEXTERN.m
53 lines (43 loc) · 1.75 KB
/
EXTERN.m
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
%*************************************************************************%
% %
% EXTERN %
% %
%*************************************************************************%
%contains:
% world - simulated visual environment
extern = sml_system();
retinaSize = [1032 778];
state = [];
state.camPort = 0;
state.camResolution = [1023 778];
state.retinaSize = retinaSize;
state.retinaPosition = [0 0]; %[452 325];
state.color = 1;
state.viewUpdate = 1;
%extern = extern.addprocess('cam0', 'dev/aber/format7Cam', 25, state);
state = [];
state.ratio = round(fS/25);
extern = extern.addprocess('cam0', 'dev/abrg/2009/camera', fS, state);
state = [];
state.retinaSize = [In_dims(1) In_dims(2)];
state.scale = floor(388/In_dims(1));
state.scale = 6;
state.camdims = [516 388];
extern = extern.addprocess('world', 'dev/abrg/2009/emPanTilt2', fS, state);
% pan-tilt system, delivering current
% pan-tilt absolute positions
state = [];
state.panScale = 1;
state.tiltScale = 1;
state.velocity = 570;
state.acceleration = 5000;
extern = extern.addprocess('absPos', 'dev/abrg/2009/panTilt', fS, state);
extern = extern.link('cam0>timing', 'world<<cam<timing');
%
extern = extern.link('cam0>R', 'world<<cam<r');
extern = extern.link('cam0>G', 'world<<cam<g');
extern = extern.link('cam0>B', 'world<<cam<b');
%*************************************************************************%
% END EXTERN %
%*************************************************************************%
sys = sys.addsubsystem('extern', extern);