X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FFDM%2FJSBSim%2Fmodels%2FFGAircraft.h;h=13a499bd54a693d790e1c25db3045ee86716364d;hb=642735ab18421db87a07d6841dd720fd4615bfff;hp=c3060db37c2577a68c46b3f099d37a2ae39cb6b1;hpb=ad51a9bde2995605984161af1b4273b28ce4fddc;p=flightgear.git diff --git a/src/FDM/JSBSim/models/FGAircraft.h b/src/FDM/JSBSim/models/FGAircraft.h index c3060db37..13a499bd5 100644 --- a/src/FDM/JSBSim/models/FGAircraft.h +++ b/src/FDM/JSBSim/models/FGAircraft.h @@ -44,12 +44,13 @@ INCLUDES #include "FGModel.h" #include "input_output/FGXMLElement.h" #include "math/FGColumnVector3.h" +#include "math/FGMatrix33.h" /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% DEFINITIONS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/ -#define ID_AIRCRAFT "$Id: FGAircraft.h,v 1.16 2010/11/18 12:38:06 jberndt Exp $" +#define ID_AIRCRAFT "$Id: FGAircraft.h,v 1.19 2011/11/10 12:06:14 jberndt Exp $" /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% FORWARD DECLARATIONS @@ -90,10 +91,10 @@ CLASS DOCUMENTATION @endcode @author Jon S. Berndt - @version $Id: FGAircraft.h,v 1.16 2010/11/18 12:38:06 jberndt Exp $ + @version $Id: FGAircraft.h,v 1.19 2011/11/10 12:06:14 jberndt Exp $ @see Cooke, Zyda, Pratt, and McGhee, "NPSNET: Flight Simulation Dynamic Modeling - Using Quaternions", Presence, Vol. 1, No. 4, pp. 404-420 Naval Postgraduate - School, January 1994 + Using Quaternions", Presence, Vol. 1, No. 4, pp. 404-420 Naval Postgraduate + School, January 1994 @see D. M. Henderson, "Euler Angles, Quaternions, and Transformation Matrices", JSC 12960, July 1977 @see Richard E. McFarland, "A Standard Kinematic Model for Flight Simulation at @@ -118,9 +119,14 @@ public: ~FGAircraft(); /** Runs the Aircraft model; called by the Executive + Can pass in a value indicating if the executive is directing the simulation to Hold. + @param Holding if true, the executive has been directed to hold the sim from + advancing time. Some models may ignore this flag, such as the Input + model, which may need to be active to listen on a socket for the + "Resume" command to be given. @see JSBSim.cpp documentation @return false if no error */ - bool Run(void); + bool Run(bool Holding); bool InitModel(void); @@ -154,10 +160,6 @@ public: double GetMoments(int idx) const { return vMoments(idx); } const FGColumnVector3& GetForces(void) const { return vForces; } double GetForces(int idx) const { return vForces(idx); } - FGColumnVector3& GetBodyAccel(void) { return vBodyAccel; } - double GetBodyAccel(int idx) const { return vBodyAccel(idx); } - const FGColumnVector3& GetNcg(void) const { return vNcg; } - double GetNcg(int idx) const { return vNcg(idx); } const FGColumnVector3& GetXYZrp(void) const { return vXYZrp; } const FGColumnVector3& GetXYZvrp(void) const { return vXYZvrp; } const FGColumnVector3& GetXYZep(void) const { return vXYZep; } @@ -172,13 +174,24 @@ public: void SetWingArea(double S) {WingArea = S;} - double GetNlf(void) const; - - FGColumnVector3& GetNwcg(void) { return vNwcg; } - void bind(void); void unbind(void); + struct Inputs { + FGColumnVector3 AeroForce; + FGColumnVector3 PropForce; + FGColumnVector3 GroundForce; + FGColumnVector3 ExternalForce; + FGColumnVector3 BuoyantForce; + FGColumnVector3 AeroMoment; + FGColumnVector3 PropMoment; + FGColumnVector3 GroundMoment; + FGColumnVector3 ExternalMoment; + FGColumnVector3 BuoyantMoment; + FGMatrix33 Tl2b; + double Weight; + } in; + private: FGColumnVector3 vMoments; FGColumnVector3 vForces; @@ -186,9 +199,6 @@ private: FGColumnVector3 vXYZvrp; FGColumnVector3 vXYZep; FGColumnVector3 vDXYZcg; - FGColumnVector3 vBodyAccel; - FGColumnVector3 vNcg; - FGColumnVector3 vNwcg; double WingArea, WingSpan, cbar, WingIncidence; double HTailArea, VTailArea, HTailArm, VTailArm;