Marine systems simulation
ReferenceGenerator.h
1
4//
11#ifndef REFGENERATOR
12#define REFGENERATOR
13
14#define EIGEN_DONT_ALIGN_STATICALLY
15
16#include <SimObject.h>
17#include <string>
18
19namespace Ship{
20 class ReferenceGenerator : public SimObject
21 {
22 public:
23 ReferenceGenerator(const string& simObjectName, ISimObjectCreator* const creator);
24 void OdeFcn(const double T, const double* const X, double* const XDot, const bool bIsMajorTimeStep);
25
26 #ifdef FH_VISUALIZATION
27 virtual void RenderInit(Ogre::Root* const ogreRoot, ISimObjectCreator* const creator){}
28 virtual void RenderUpdate(const double T, const double* const X){}
29 #endif
30
31 protected:
32 ISignalPort* m_adStatePositionPort;
33 ISignalPort* m_adStateThetaPort;
34 ISignalPort* m_adStateVelocityPort;
35 ISignalPort* m_adStateRotationPort;
36
40
41 //int m_StatePosition_Desired_Index; ///< The relative index of the StatePosition_Desired state in the state array
42 //int m_StateTheta_Desired_Index; ///< The relative index of the StateTheta_Desired state in the state array
43 //int m_StateVelocity_Desired_Index; ///< The relative index of the StateVelocity_Desired state in the state array//
44 int i,j;
45 };
46}
47
48#endif
Definition: ReferenceGenerator.h:21
double m_adStateTheta_Desired[4]
Desired linear and angular velocity.
Definition: ReferenceGenerator.h:38
double m_adStateVelocity_Desired[3]
Desired linear and angular acceleration.
Definition: ReferenceGenerator.h:39
int j
counter variables
Definition: ReferenceGenerator.h:44
ISignalPort * m_adStatePositionPort
input port. Current position
Definition: ReferenceGenerator.h:32
ISignalPort * m_adStateVelocityPort
input port. Current linear velocity
Definition: ReferenceGenerator.h:34
ReferenceGenerator(const string &simObjectName, ISimObjectCreator *const creator)
reads parameters, registers states, input/output ports and shared resources
double m_adStatePosition_Desired[3]
Desired position and attitude.
Definition: ReferenceGenerator.h:37
ISignalPort * m_adStateThetaPort
input port. Current attitude as a quaternion
Definition: ReferenceGenerator.h:33
ISignalPort * m_adStateRotationPort
input port. current attitude in euler angles
Definition: ReferenceGenerator.h:35
void OdeFcn(const double T, const double *const X, double *const XDot, const bool bIsMajorTimeStep)
returns object derivatives as a function of time, states and input ports
Simple waypoint object.
Definition: CableAttach.h:16