7575aee987
Lot's of new things: - try to use less .mat files - computation of setpoint and error in the cartesian frame fixed to the granite - change of base to have the errors w.r.t. the NASS base - add script to plot setpoint, position and error
30 lines
779 B
Matlab
30 lines
779 B
Matlab
function [ty] = initializeTy(opts_param)
|
|
%% Default values for opts
|
|
opts = struct('rigid', false);
|
|
|
|
%% Populate opts with input parameters
|
|
if exist('opts_param','var')
|
|
for opt = fieldnames(opts_param)'
|
|
opts.(opt{1}) = opts_param.(opt{1});
|
|
end
|
|
end
|
|
|
|
%%
|
|
ty = struct();
|
|
|
|
ty.m = 250; % [kg]
|
|
|
|
if opts.rigid
|
|
ty.k.ax = 1e10; % Axial Stiffness for each of the 4 guidance (y) [N/m]
|
|
else
|
|
ty.k.ax = 1e7/4; % Axial Stiffness for each of the 4 guidance (y) [N/m]
|
|
end
|
|
ty.k.rad = 9e9/4; % Radial Stiffness for each of the 4 guidance (x-z) [N/m]
|
|
|
|
ty.c.ax = 100*(1/5)*sqrt(ty.k.ax/ty.m);
|
|
ty.c.rad = 100*(1/5)*sqrt(ty.k.rad/ty.m);
|
|
|
|
%% Save
|
|
save('./mat/stages.mat', 'ty', '-append');
|
|
end
|