2018-06-04 09:50:44 +02:00
|
|
|
|
%%
|
2018-06-16 22:57:54 +02:00
|
|
|
|
clear; close all; clc;
|
2018-04-11 13:44:50 +02:00
|
|
|
|
|
2018-06-21 11:42:46 +02:00
|
|
|
|
%% Initialize simulation configuration
|
|
|
|
|
opts_sim = struct(...
|
2018-10-12 18:17:03 +02:00
|
|
|
|
'Tsim', 5 ...
|
2018-06-21 11:42:46 +02:00
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
initializeSimConf(opts_sim);
|
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Inputs
|
|
|
|
|
opts_inputs = struct(...
|
2018-10-12 18:17:03 +02:00
|
|
|
|
'Dw', true, ...
|
2018-10-29 12:57:13 +01:00
|
|
|
|
'Ry', false, ...
|
2018-10-12 18:17:03 +02:00
|
|
|
|
'Rz', true ...
|
2018-06-16 22:57:54 +02:00
|
|
|
|
);
|
2018-06-06 19:16:04 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
initializeInputs(opts_inputs);
|
2018-06-06 19:16:04 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Ground
|
|
|
|
|
initializeGround();
|
2018-06-06 18:39:38 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Granite
|
|
|
|
|
initializeGranite();
|
2018-04-24 15:48:17 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Translation stage
|
|
|
|
|
initializeTy();
|
2018-06-06 18:39:38 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Tilt Stage
|
|
|
|
|
initializeRy();
|
2018-04-11 13:44:50 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Spindle
|
|
|
|
|
initializeRz();
|
2018-06-06 18:39:38 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Hexapod Sym<EFBFBD>trie
|
|
|
|
|
initializeMicroHexapod();
|
2018-04-11 13:44:50 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Center of Gravity compensation
|
|
|
|
|
initializeAxisc();
|
2018-06-06 18:39:38 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize NASS
|
2018-10-02 18:17:13 +02:00
|
|
|
|
initializeNanoHexapod(struct('actuator', 'lorentz'));
|
2018-06-06 18:39:38 +02:00
|
|
|
|
|
2018-07-11 15:44:16 +02:00
|
|
|
|
%% Initialize the Mirror
|
2018-09-29 19:08:05 +02:00
|
|
|
|
initializeMirror(struct('shape', 'spherical'));
|
2018-07-11 15:44:16 +02:00
|
|
|
|
|
2018-06-16 22:57:54 +02:00
|
|
|
|
%% Initialize Sample
|
2018-10-02 18:17:13 +02:00
|
|
|
|
initializeSample(struct('mass', 20));
|
2018-10-11 10:25:57 +02:00
|
|
|
|
|
|
|
|
|
%% Controllers
|
|
|
|
|
K = tf(zeros(6));
|
2018-10-24 15:08:23 +02:00
|
|
|
|
|
2018-10-11 10:25:57 +02:00
|
|
|
|
K_iff = tf(zeros(6));
|
2018-10-24 15:08:23 +02:00
|
|
|
|
|
|
|
|
|
save('./mat/controllers.mat', 'K', 'K_iff');
|