You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
99 lines
3.3 KiB
99 lines
3.3 KiB
// CP: 65001 |
|
// SimulationX Version: 3.8.2.45319 x64 |
|
within AIDAModelica; |
|
model SimXToProSIVICInterface "Simulation X to ProSIVIC Interface" |
|
Modelica.Blocks.Interfaces.RealInput Position[3]( |
|
quantity="Mechanics.Translation.Displace", |
|
displayUnit="m") "'input Real' as connector" annotation(Placement( |
|
transformation(extent={{-80,60},{-40,100}}), |
|
iconTransformation( |
|
origin={-75,100}, |
|
extent={{-20,-20},{20,20}}, |
|
rotation=-90))); |
|
Modelica.Blocks.Interfaces.RealInput Attitude[3]( |
|
quantity="Mechanics.Rotation.Angle", |
|
displayUnit="rad") "'input Real' as connector" annotation(Placement( |
|
transformation(extent={{20,60},{60,100}}), |
|
iconTransformation( |
|
origin={75,100}, |
|
extent={{-20,-20},{20,20}}, |
|
rotation=-90))); |
|
Modelica.Blocks.Interfaces.RealOutput translation_x( |
|
quantity="Mechanics.Translation.Displace", |
|
displayUnit="m") "Tracking translation x" annotation(Placement( |
|
transformation(extent={{-95,30},{-75,50}}), |
|
iconTransformation( |
|
origin={-125,-100}, |
|
extent={{-10,-10},{10,10}}, |
|
rotation=-90))); |
|
Modelica.Blocks.Interfaces.RealOutput translation_y( |
|
quantity="Mechanics.Translation.Displace", |
|
displayUnit="m") "Tracking translation y" annotation(Placement( |
|
transformation(extent={{-70,30},{-50,50}}), |
|
iconTransformation( |
|
origin={-75,-100}, |
|
extent={{-10,-10},{10,10}}, |
|
rotation=-90))); |
|
Modelica.Blocks.Interfaces.RealOutput translation_z( |
|
quantity="Mechanics.Translation.Displace", |
|
displayUnit="m") "Tracking translation z" annotation(Placement( |
|
transformation(extent={{-30,30},{-10,50}}), |
|
iconTransformation( |
|
origin={-25,-100}, |
|
extent={{-10,-10},{10,10}}, |
|
rotation=-90))); |
|
Modelica.Blocks.Interfaces.RealOutput rotation_xi( |
|
quantity="Mechanics.Rotation.Angle", |
|
displayUnit="rad") "Tracking rotation xi " annotation(Placement( |
|
transformation(extent={{10,30},{30,50}}), |
|
iconTransformation( |
|
origin={125,-100}, |
|
extent={{-10,-10},{10,10}}, |
|
rotation=-90))); |
|
Modelica.Blocks.Interfaces.RealOutput rotation_theta( |
|
quantity="Mechanics.Rotation.Angle", |
|
displayUnit="rad") "Tracking rotation theta" annotation(Placement( |
|
transformation(extent={{40,30},{60,50}}), |
|
iconTransformation( |
|
origin={75,-100}, |
|
extent={{-10,-10},{10,10}}, |
|
rotation=-90))); |
|
Modelica.Blocks.Interfaces.RealOutput rotation_phi( |
|
quantity="Mechanics.Rotation.Angle", |
|
displayUnit="rad") "Tracking rotation phi" annotation(Placement( |
|
transformation(extent={{70,30},{90,50}}), |
|
iconTransformation( |
|
origin={25,-100}, |
|
extent={{-10,-10},{10,10}}, |
|
rotation=-90))); |
|
equation |
|
// enter your equations here |
|
translation_x = Position[1]; |
|
translation_y = -1*Position[2]; |
|
translation_z = -1*Position[3]; |
|
|
|
rotation_phi = Attitude[1]; |
|
rotation_theta = -1*Attitude[2]; |
|
rotation_xi = -1*Attitude[3]; |
|
annotation( |
|
Position(flags=2), |
|
Attitude(flags=2), |
|
translation_x(flags=2), |
|
translation_y(flags=2), |
|
translation_z(flags=2), |
|
rotation_xi(flags=2), |
|
rotation_theta(flags=2), |
|
rotation_phi(flags=2), |
|
Icon( |
|
coordinateSystem(extent={{-175,-100},{175,100}}), |
|
graphics={ |
|
Rectangle( |
|
fillColor={255,255,255}, |
|
fillPattern=FillPattern.Solid, |
|
extent={{-173.3,100},{173.3,-100}})}), |
|
experiment( |
|
StopTime=1, |
|
StartTime=0, |
|
Interval=0.002, |
|
MaxInterval="0.001")); |
|
end SimXToProSIVICInterface;
|
|
|