WSF
WsfRigidBodySixDOF_Mover.hpp
Go to the documentation of this file.
1// ****************************************************************************
2// CUI
3//
4// The Advanced Framework for Simulation, Integration, and Modeling (AFSIM)
5//
6// Copyright 2020 Infoscitex, a DCS Company. All rights reserved.
7//
8// The use, dissemination or disclosure of data in this file is subject to
9// limitation or restriction. See accompanying README and LICENSE for details.
10// ****************************************************************************
11
12#ifndef WSFRIGIDBODYSIXDOFMOVER_HPP
13#define WSFRIGIDBODYSIXDOFMOVER_HPP
14
27#include "WsfSixDOF_Mover.hpp"
28#include "WsfSixDOF_Route.hpp"
30
31namespace wsf
32{
33namespace six_dof
34{
37class WSF_SIX_DOF_EXPORT RigidBodyMover : public Mover
38{
39public:
41 explicit RigidBodyMover(const WsfScenario& aScenario);
42
43 RigidBodyMover& operator=(const RigidBodyMover& other) = delete;
44
45 WsfMover* Clone() const override;
46
47 bool ProcessInput(UtInput& aInput) override;
48 bool Initialize(double aSimTime) override;
49
50 static int GetTypeId() { return WsfStringId::UnsafeGetNumber("WSF_RIGID_BODY_SIX_DOF_MOVER"); }
51
52 // ====================================================================================================
53
54 // CommonController/autopilot control commands
55
56 // Returns the most recent yaw moment in newton*meters
57 double GetYawMoment_nm() const;
58
59 // Returns the most recent yaw moment in ft*lbs
60 double GetYawMoment_ftlbs() const;
61
62 // Returns the most recent pitch moment in newton*meters
63 double GetPitchMoment_nm() const;
64
65 // Returns the most recent pitch moment in ft*lbs
66 double GetPitchMoment_ftlbs() const;
67
68 // Returns the most recent roll moment in newton*meters
69 double GetRollMoment_nm() const;
70
71 // Returns the most recent roll moment in ft*lbs
72 double GetRollMoment_ftlbs() const;
73
74 // This returns a 'handle' to a control surface. If there is no control surface with the specified name, the function
75 // returns 0;
76 size_t GetControlSurfaceHandle(const std::string& aControlSurfaceName) const;
77
78 // This returns a 'handle' to the first control surface that contains the specified string. If there is no control
79 // surface that contains the name, the function returns 0;
80 size_t GetControlSurfaceHandleContainingString(const std::string& aString) const;
81
82 // This returns a 'handle' to the first control surface that contains the two specified strings. If there is no
83 // control surface that contains the names, the function returns 0;
84 size_t GetControlSurfaceHandleContainingTwoStrings(const std::string& aString1, const std::string& aString2) const;
85
86 // Returns the position (deg) of the specified control surface, or returns zero if no surface exists
87 double GetAngleOfControlSurface(std::string aControlSurfaceName) const;
88
89 // Returns the position (deg) of the specified control surface (based on handle), or returns zero if no surface exists
90 double GetAngleOfControlSurface(size_t aHandle) const;
91
92 // Returns a normalized (either +/-1 or 0-1) angle of the specified control surface (based on handle),
93 // or returns zero if no surface exists
94 double GetNormalizedAngleOfControlSurface(size_t aHandle) const;
95
96 // Returns a list(vector) containing the names of the control surfaces
97 std::vector<std::string> GetListOfControlSurfaceNames() const;
98
99 // Returns the position (deg) of the ailerons (common position)
100 double GetAileronsBothPosition() const;
101
102 // Returns the position (deg) of the left stabilator
103 double GetStabilatorLeftPosition() const;
104
105 // Returns the position (deg) of the right stabilator
106 double GetStabilatorRightPosition() const;
107
108 // Returns the position (deg) of the rudder(s) (common position)
109 double GetRudderPosition() const;
110
111 // Returns the position (deg) of the landing gear (common position)
112 double GetLandingGearPosition() const;
113
114 // Returns the position (rad) of the speed brakes (common position)
115 double GetSpeedBrakePosition_rad() const;
116
117 // Returns the position (deg) of the speed brakes (common position)
118 double GetSpeedBrakePosition() const override;
119
120 // Returns the position (deg) of the flaps (common position)
121 double GetFlapsPosition() const override;
122
123 // Returns the position (deg) of the spoilers (common position)
124 double GetSpoilersPosition() const override;
125
126 // Returns the position (deg) of the nose wheel steering angle
127 double GetNoseWheelAngle() const;
128
129 // These functions return the control surface angle in degrees
130 double GetAngleAileronLeft() const;
131 double GetAngleAileronRight() const;
132 double GetAngleFlapLeft() const;
133 double GetAngleFlapRight() const;
134 double GetAngleSpoilerLeft() const;
135 double GetAngleSpoilerRight() const;
136 double GetAngleStabilizerLeft() const;
137 double GetAngleStabilizerRight() const;
138 double GetAngleElevator() const;
139 double GetAngleRudderLeft() const;
140 double GetAngleRudder() const;
141 double GetAngleRudderRight() const;
142 double GetAngleSpeedBrake() const;
143 double GetAngleLandingGear() const;
144 double GetAngleLandingGearNose() const;
145 double GetAngleLandingGearMainLeft() const;
146 double GetAngleLandingGearMainRight() const;
147
148 // These functions return the normalized control surface angle
149 double GetNormalizedAileronLeft() const override;
150 double GetNormalizedAileronRight() const override;
151 double GetNormalizedFlapLeft() const override;
152 double GetNormalizedFlapRight() const override;
153 double GetNormalizedSpoilerLeft() const override;
154 double GetNormalizedSpoilerRight() const override;
155 double GetNormalizedStabilizerLeft() const override;
156 double GetNormalizedStabilizerRight() const override;
157 double GetNormalizedElevator() const override;
158 double GetNormalizedRudderLeft() const override;
159 double GetNormalizedRudder() const override;
160 double GetNormalizedRudderRight() const override;
161 double GetNormalizedSpeedBrake() const override;
162 double GetNormalizedLandingGear() const override;
163 double GetNormalizedLandingGearNose() const override;
164 double GetNormalizedLandingGearMainLeft() const override;
165 double GetNormalizedLandingGearMainRight() const override;
166
167 // These functions return true if the data for that control surface is valid
168 bool AileronLeftValid() const override;
169 bool AileronRightValid() const override;
170 bool FlapLeftValid() const override;
171 bool FlapRightValid() const override;
172 bool SpoilerLeftValid() const override;
173 bool SpoilerRightValid() const override;
174 bool StabilizerLeftValid() const override;
175 bool StabilizerRightValid() const override;
176 bool ElevatorValid() const override;
177 bool RudderLeftValid() const override;
178 bool RudderValid() const override;
179 bool RudderRightValid() const override;
180 bool SpeedBrakeValid() const override;
181 bool LandingGearValid() const override;
182 bool LandingGearNoseValid() const override;
183 bool LandingGearMainLeftValid() const override;
184 bool LandingGearMainRightValid() const override;
185 bool ThrottleValid() const override;
186
187 // ====================================================================================================
188
189 // Functions to support scripting
190
191 const char* GetScriptClassName() const override { return "WsfRigidBodySixDOF_Mover"; }
192
193 // This allows an external force (such as a ground tug) to apply a force to the nose gear. The angle is measured as
194 // zero being forward and positive angles being to the right.
195 void ApplyExternalForce(double aForceMagnitude_lbs, double aAngle_deg);
196
197 // This removes any external forces on the nose gear.
198 void RemoveExternalForce();
199
200 // This should be called to enable direct braking commands in script.
201 void EnableDirectBraking();
202
203 // This sets the parking brake, if equipped.
204 void SetParkingBrake();
205
206 // This applies the left main gear wheel brake with a normalized value or 0 for no braking and 1.0 for full braking.
207 void ApplyLeftGearBrake(double aValue);
208
209 // This applies the right main gear wheel brake with a normalized value or 0 for no braking and 1.0 for full braking.
210 void ApplyRightGearBrake(double aValue);
211
212 // This releases both wheel brakes.
213 void ReleaseWheelBrakes();
214
215 // This should be called to disable any further direct braking commands in script.
216 void ReleaseDirectBraking();
217
218 // This retracts the landing gear
219 void RetractLandingGear();
220
221 // This lowers the landing gear
222 void LowerLandingGear();
223
224 // Set the flaps position in normalized values ranging from 0 when flaps are retractedto 1 when flaps are
225 // fully deployed.
226 void SetFlapsPosition(double aPosition) override;
227
228 // Set the spoilers position in normalized values ranging from 0 when spoilers are retracted to 1 when spoilers are
229 // fully deployed.
230 void SetSpoilersPosition(double aPosition) override;
231
232 void SetThrustReverserPosition(double aPosition);
233 void SetEnableNWS(bool aNWS_Enabled);
234
235 // Returns true if there is weight on any wheel
236 bool GetWeightOnWheels() const override;
237
238 // Returns true if there is weight on the nose wheel
239 bool GetWeightOnNoseWheel() const;
240
241 // Limits and settings functions
242
243 // This returns the maximum ground taxi speed in ft/sec
244 double GetTaxiSpeedMax();
245
246 // This returns the maximum ground taxi yaw rate in deg/sec
247 double GetTaxiYawRateMax();
248
249 // This sets the maximum ground taxi speed in ft/sec
250 void SetTaxiSpeedMax(double aSpeedMax);
251
252 // This sets the maximum ground taxi yaw rate in deg/sec
253 void SetTaxiYawRateMax(double aSpeedMax);
254
255 // Autopilot commands
256
257 // This enable/disables taxi mode
258 void SetTaxiMode(bool aTaxiModeEnabled);
259
260 // This sets the turn radius (in feet) used for taxiing
261 void SetTaxiRadius(double aTaxiRadius_ft);
262
263 // This returns a pointer to the test object. It should only be used in testing.
266
267 // ====================================================================================================
268
269 // Initialization functions
270
271 void DeriveFrom(const RigidBodyMover& aSrc);
272
273 // Note: RigidBodySixDOF_VehicleType uses ProcessInput(), but RigidBodySixDOF_Vehicle does not
274
275 // ====================================================================================================
276 // Mass properties functions
277
278 // This calculates the current mass properties, including those from subobjects and other contributors such as fuel.
279 void CalculateCurrentMassProperties() override;
280
281 // This is used to modify the weight of a vehicle without adding fuel or subobjects for testing
282 // and should only be called in testing. Additional weight is added at the existing vehicle CG.
283 void SetCurrentWeight_lbs(double aWeight_lbs);
284
285 // This is used to modify the CG of a vehicle without adding fuel or subobjects for testing and should only be called
286 // through the test object. CG is shifted in X, Y, and/or Z with no modification to scalar mass or moments of inertia.
287 void ShiftCurrentCg_ft(UtVec3dX aDeltaCg_ft);
288
289 // ====================================================================================================
290
291 // Integrator functions
292
293 // This returns the integrator.
294 const Integrator* GetIntegrator() const override;
295
296 // ====================================================================================================
297
298 // "Last" functions
299
300 // This sets the mLastSimTime_nanosec to the specified sim time in seconds. If the
301 // aIncludeSubobjects flag is true, all subobjects will also have their last time
302 // values set.
303 void SetLastSimTime(double aSimTime_sec, bool aIncludeSubobjects = false) override;
304
305 // ====================================================================================================================
306
307 // Aerodynamics functions
308
309 // This function is used to calculate the lift, drag, side force, and moments using the current state. The reference
310 // point is typically (0,0,0), but may be a non-origin reference due to subobjects. This function will include aero
311 // contributions by subobjects, if appropriate.
312 void CalculateAeroBodyForceAndMoments(UtVec3dX& aLiftBodyVector_lbs,
313 UtVec3dX& aDragBodyVector_lbs,
314 UtVec3dX& aSideForceBodyVector_lbs,
315 UtVec3dX& aMoment_ftlbs,
316 UtVec3dX& aReferencePt_ft) override;
317
318 // This function is used to calculate the lift, drag, side force, and otherdata for lower-fidelity vehicles using the
319 // current state. This function will include aero contributions by subobjects, if appropriate.
320 void CalculateAeroBodyForceAndRotation(UtVec3dX& aLiftBodyVector_lbs,
321 UtVec3dX& aDragBodyVector_lbs,
322 UtVec3dX& aSideForceBodyVector_lbs,
323 UtVec3dX& aRotationAccelerationLimits_rps2,
324 UtVec3dX& aStabilizingFrequency_rps) override;
325
326 // This uses CalculatePitchGLoadAtSpecifiedAlpha internally to calculate the angle of attack (alpha) at the specified
327 // g-load using the current conditions. If it cannot attain the specified g-load, it will return the *best* alpha.
328 void CalculateAlphaAtSpecifiedGLoad_deg(double aGLoad, double& aAlpha_deg) const override;
329
330 // This calculates the normalized stick back position to produce a net zero moment using the current conditions. If
331 // it cannot produce a zero moment, it will do the best it can (full stick control).
332 void CalculateStickBackForZeroMoment(double aAlpha_deg, double& aStickBack);
333
334 // This calculates the normalized stick back position to produce a net zero moment using the specified Mach. If it
335 // cannot produce a zero moment, it will do the best it can (full stick control).
336 void CalculateStickBackForZeroMoment(double aAlpha_deg, double aMach, double& aStickBack);
337
338 // This calculates the angle of sideslip (beta) at the specified g-load using the current conditions. If it cannot
339 // attain the specified g-load, it will return the *best* beta.
340 void CalculateBetaAtSpecifiedGLoad_deg(double aGLoad, double& aBeta_deg) const override;
341
342 // This calculates the lift coefficient (CL), drag coefficient (Cd), and pitching moment coefficient (Cm),
343 // multiplied by the appropriate reference area, produced by all aero movable objects. It uses the specified
344 // stick back position.
345 void CalculateControlsAeroCoefficientVectors(double aMach,
346 double aAlpha_rad,
347 double aStickBack,
348 double& aCLArea,
349 double& aCdArea,
350 double& aCmArea);
351
352 // This calculates the lift coefficient (CL), multiplied by the appropriate reference area, produced by all aero
353 // movable objects. It uses the specified stick back position.
354 double CalculateControlsCLArea(double aMach, double aAlpha_rad, double aStickBack);
355
356 // This calculates the drag coefficient (Cd), multiplied by the appropriate reference area, produced by all aero
357 // movable objects. It uses the specified stick back position.
358 double CalculateControlsCdArea(double aMach, double aAlpha_rad, double aStickBack);
359
360 // This calculate the CmArea, including reference area effects, for the core aero and movable (controls) aero.
361 void CalculateCmAreaForCoreAndControls(double aMach,
362 double aAlpha_rad,
363 double aStickBack,
364 bool aPowerOn,
365 double& aThrustProduced_lbs,
366 double& aCoreCm,
367 double& aControlsCm);
368
369 // This calculate the CLArea, including reference area effects, for the core aero and movable (controls) aero.
370 void CalculateCLAreaForCoreAndControls(double aMach, double aAlpha_rad, double aStickBack, double& aCoreCL, double& aControlsCL);
371
372 // This calculate the CdArea, including reference area effects, for the core aero and movable (controls) aero.
373 void CalculateCdAreaForCoreAndControls(double aMach, double aAlpha_rad, double aStickBack, double& aCoreCd, double& aControlsCd);
374
375 // This calculates the total Cm and CL for the vehicle, including both core aero and movable (controls) aero,
376 // returning the Cm and CL via reference.
377 void CalculateTotalCmAndCL(double aMach, double aAlpha_rad, double aStickBack, double& aTotalCm, double& aTotalCL);
378
379 // This sets the active aero object using the pointer
380 void SetActiveAeroObject(RigidBodyAeroCoreObject* aObject);
381
382 // This sets the active aero object using the name
383 void SetActiveAeroObject(const std::string& aName) override;
384
385 // This returns a pointer to the active aero object
387
388 // This returns the name of the active aero object
389 std::string GetActiveAeroObjectName() const
390 {
391 return GetActiveAeroObject() ? GetActiveAeroObject()->GetModeName() : "";
392 }
393
394 // This returns the wing area (sq-ft) for the current aero mode
395 double GetWingArea_sqft() const;
396
397 // This returns the ref area (sq-ft) for the current aero mode
398 double GetRefArea_sqft() const;
399
400 // This returns the current center of gravity in feet from the reference point
401 UtVec3dX GetCenterOfGravity_ft() const override { return mMassProperties.GetCmPosRelToRef_ft(); }
402
403 // This uses the current state to calculate the maximum g-load maneuverability based on the current mass, altitude,
404 // speed/mach and CLmax
405 double MaxPotentialManeuverGLoad() const override;
406
407 // This returns the fixed-aero object or null if none exists
409
410 // ====================================================================================================
411
412 // PropulsionSystem functions
413
414 // This calculates F&M for the full propulsion system (all engines) plus the thrust from any subobjects
415 void CalculatePropulsionFM(int64_t aSimTime_nanosec,
416 double aDeltaT_sec,
417 const KinematicState& aState,
418 UtVec3dX& aInertialPropulsionVector_lbs,
419 UtVec3dX& aPropulsionMoment_ftlbs);
420
421 // This returns the propulsion system or null if no propulsion system exists
423
424 // This returns the propulsion system or null if no propulsion system exists
426
427 // This provides the maximum potential thrust available, if full throttle, including afterburner (if available),
428 // is applied
429 double GetMaximumPotentialThrust_lbs() const override;
430
431 // This provides the minimum potential thrust available
432 double GetMinimumPotentialThrust_lbs() const override;
433
434 // This provides the current thrust magnitude produced by engines on the vehicle. It includes thrust from any
435 // first-level/immediate subobjects
436 double GetCurrentThrust_lbs() override;
437
438 // This provides the current forward thrust produced by engines on the vehicle. It includes thrust from any
439 // first-level/immediate subobjects
440 double GetCurrentForwardThrust_lbs() override;
441
442 // This returns the total fuel flow (lbs/hr) for all engines on the vehicle
443 double GetTotalVehicleFuelFlow_pph() const override;
444
445 // This returns the total fuel flow (lbs/hr) for the main engines on the vehicle. It does not include any subobjects.
446 double GetTotalFuelFlow_pph() const override;
447
448 // ====================================================================================================
449
450 // PilotObject and FlightControls functions
451
452 // This returns the pilot manager object. Null is returned when no pilot manager is present.
453 PilotManager* GetPilotManager() const override { return mPilotManagerPtr; }
455
456 // This returns the flight controls object. Null is returned when
457 // no flight controls are present.
459
460 // This returns true if the object includes flaps control surfaces
461 bool HasFlaps() const;
462
463 size_t GetInputHandle(const std::string& aInputName) const override;
464 bool GetBooleanInput(size_t aHandle) const override;
465 bool GetLastBooleanInput(size_t aHandle) const override;
466
467 // This is used to restore angles specified in the list to the control surfaces specified in the other list
468 void RestoreControlSurfaceAngles(std::vector<RigidBodyFlightControlSystem::ControlSurfaceElement*>& aControlsList,
469 std::vector<double>& aAngleList);
470
471 // If true, a simple yaw damper should be used. This is determined by the autopilot, so if no autopilot is present,
472 // no yaw damper will be available. This "simple" yaw damper merely prevents any rotation about the body z-axis,
473 // so it may not be desired, since it is simplified and not very realistic.
474 bool UseSimpleYawDamper() const;
475
476 // These functions return the normalized control input (lever) value
477 double GetStickRightInput() const override;
478 double GetStickBackInput() const override;
479 double GetRudderRightInput() const override;
480 double GetThrottleInput() const override;
481 double GetSpeedBrakeInput() const override;
482 double GetSpoilerInput() const override;
483 double GetLandingGearInput() const override;
484
485 // ====================================================================================================
486
487 // Landing gear functions
488
489 void CalculateLandingGearFM(int64_t aSimTime_nanosec,
490 const UtVec3dX& aNonLandingGearTotalForceVecInertial_lbs,
491 UtVec3dX& aInertialTotalGearVector_lbs,
492 UtVec3dX& aTotalGearMoment_ftlbs);
493
494 // Use this to set landing gear position at start of simulation
495 void SetLandingGearPositionAtStart(double aPosition);
496
497 // This will force the gear to the specified position instantly. The typical name is "Landing_Gear_Extended", but it
498 // may use a different name.
499 void ForceLandingGearPositionInstantly(std::string aLandingGearControlSurfaceHandleName, double aPosition);
500
501 // This will force the gear up instantly. The typical name is "Landing_Gear_Extended", but it may use a different name.
502 void ForceLandingGearUpInstantly(const std::string& aLandingGearControlSurfaceHandleName);
503
504 // This will force the gear down instantly. The typical name is "Landing_Gear_Extended", but it may use a different name.
505 void ForceLandingGearDownInstantly(const std::string& aLandingGearControlSurfaceHandleName);
506
507 // Returns true if the object has landing gear
508 bool HasLandingGear() const { return (mLandingGearPtr != nullptr); }
509
510 // This returns the landing gear object. Null is returned when no landing gear are present.
512
513 // ====================================================================================================
514
515 // Testing functions
516
517 // This sets kinematic state parameters to a zero condition for testing
518 void ZeroKinematicsDuringTesting() override;
519
520protected:
521 explicit RigidBodyMover(const RigidBodyMover& aSrc);
522
523 // This is used by all Initialize functions to complete "details"
524 bool InitializeDetails(double aSimTime_sec) override;
525
526 // Update functions
527 void UpdateFlightControls(int64_t aSimTime_nanosec) override;
528
529 // This returns the pitching moment (ft-lbs) for the specified angle of attack (alpha) and stick back at the current
530 // conditions. Note -- this assumes that "testing" controls are being used.
531 double CalculatePitchMomentAlphaStickBack_ftlbs(double aAlpha_deg, double aDesiredStickBack);
532
533 void CalculateMovableAero(double aDynPress_lbsqft,
534 double aMach,
535 double aSpeed_fps,
536 double aAlpha_rad,
537 double aBeta_rad,
538 const UtVec3dX& aAngularRates_rps,
539 UtVec3dX& aAeroMoment,
540 double& aLift,
541 double& aDrag,
542 double& aSide,
543 double& aLiftFactor);
544
545 void CalculateThrustVectorAndMomentUpdatePropulsion(double aSimTime_sec,
546 double aDeltaTime_sec,
547 const KinematicState& aState,
548 ForceAndMomentsObject& aForceAndMoment);
549
550 void UpdatePropulsionFuelBurn(double aSimTime_sec, double aDeltaTime_sec, const KinematicState& aState) override;
551
552 void CalculateObjectPropulsion(double aSimTime_sec,
553 double aDeltaT_sec,
554 double aAlt_ft,
555 double aDynPress_lbsqft,
556 double aStatPress_lbssqft,
557 double aSpeed_fps,
558 double aMach,
559 double aAlpha_rad,
560 double aBeta_rad,
561 ForceAndMomentsObject& aForceAndMoment,
562 double& aFuelBurnRate_pps,
563 double& aFuelBurned_lbs) override;
564
565 void CalculateObjectPropulsion(double aSimTime_sec,
566 double aDeltaT_sec,
567 double aAlt_ft,
568 double aDynPress_lbsqft,
569 double aStatPress_lbssqft,
570 double aSpeed_fps,
571 double aMach,
572 double aAlpha_rad,
573 double aBeta_rad,
574 ForceAndRotationObject& aForceAndRotation,
575 double& aFuelBurnRate_pps,
576 double& aFuelBurned_lbs) override;
577
578 void UpdateObjectPropulsion(double aSimTime_sec,
579 double aDeltaT_sec,
580 double aAlt_ft,
581 double aDynPress_lbsqft,
582 double aStatPress_lbssqft,
583 double aSpeed_fps,
584 double aMach,
585 double aAlpha_rad,
586 double aBeta_rad,
587 ForceAndMomentsObject& aForceAndMoment,
588 double& aFuelBurnRate_pps,
589 double& aFuelBurned_lbs);
590
591 void ObjectPropulsionCalculations(double aSimTime_sec,
592 double aDeltaT_sec,
593 double aAlt_ft,
594 double aDynPress_lbsqft,
595 double aStatPress_lbssqft,
596 double aSpeed_fps,
597 double aMach,
598 double aAlpha_rad,
599 double aBeta_rad,
600 ForceAndMomentsObject& aForceAndMoment,
601 double& aFuelBurnRate_pps,
602 double& aFuelBurned_lbs,
603 bool aUpdateData);
604
605 void CalcTotalFuelFlowAndQuantity(double& aCurrentTotalFuelFlow_pph,
606 double& aCurrentTotalFuel_lbs,
607 double& aMaxTotalFuel_lbs) override;
608
609 // Returns the angle (deg) of the surface with the specified handle
610 double GetAngleSurface(size_t aHandle) const;
611
612 // Returns the normalized angle of the surface with the specified handle
613 double GetNormalizedSurfaceAngle(size_t aHandle) const;
614
615 // Find the various parts -- landing gear, control surfaces, engines, etc.
616 void FindParts();
617
618 // ====================================================================================================
619
620 std::unique_ptr<RigidBodyMoverTestObject> mTestSupportObjectPtr{nullptr};
621
623
624 ut::CloneablePtr<RigidBodyAeroCoreObject> mAeroCoreObjPtr{nullptr};
625 std::list<ut::CloneablePtr<RigidBodyAeroMovableObject>> mAeroPartList;
626
628
629 ut::CloneablePtr<RigidBodyPropulsionSystem> mPropulsionObjPtr{nullptr};
630
631 ut::CloneablePtr<RigidBodyIntegrator> mIntegratorPtr{nullptr};
632
633 ut::CloneablePtr<RigidBodyFlightControlSystem> mFlightControlsPtr{nullptr};
634 ut::CloneablePtr<RigidBodyPilotManager> mPilotManagerPtr{nullptr};
635 ut::CloneablePtr<RigidBodyLandingGear> mLandingGearPtr{nullptr};
636
640 bool mNWSEnabledAtStart = false;
641
650 bool mLastNWS_Enabled = false;
651
654 size_t mHandleFlapLeft = 0;
660 size_t mHandleElevator = 0;
662 size_t mHandleRudder = 0;
669};
670} // namespace six_dof
671} // namespace wsf
672
673#endif
WsfMover()=delete
Contains the data required to create a simulation, and acts as the entry point for input file process...
Definition WsfScenario.hpp:111
Definition WsfSixDOF_AeroCoreObject.hpp:35
Definition WsfSixDOF_ForceAndMomentsObject.hpp:28
Definition WsfSixDOF_ForceAndRotationObject.hpp:30
Definition WsfSixDOF_Integrator.hpp:31
Definition WsfSixDOF_KinematicState.hpp:34
Definition WsfSixDOF_MoverTestObject.hpp:33
Mover(const WsfScenario &aScenario)
Constructor.
Definition WsfSixDOF_Mover.cpp:63
MassProperties mMassProperties
Definition WsfSixDOF_Mover.hpp:1823
Definition WsfSixDOF_PilotManager.hpp:34
Definition WsfSixDOF_PropulsionSystem.hpp:35
Definition WsfRigidBodySixDOF_AeroCoreObject.hpp:28
Definition WsfRigidBodySixDOF_FlightControlSystem.hpp:44
Definition WsfRigidBodySixDOF_LandingGear.hpp:36
Definition WsfRigidBodySixDOF_MoverTestObject.hpp:23
Definition WsfRigidBodySixDOF_Mover.hpp:38
bool mParkingBrakeOnAtStart
Definition WsfRigidBodySixDOF_Mover.hpp:638
static int GetTypeId()
Definition WsfRigidBodySixDOF_Mover.hpp:50
bool mLastNWS_Enabled
Definition WsfRigidBodySixDOF_Mover.hpp:650
PropulsionSystem * GetPropulsionSystem() const override
Definition WsfRigidBodySixDOF_Mover.hpp:422
double mLastWheelBrakeRightPosition
Definition WsfRigidBodySixDOF_Mover.hpp:649
size_t mHandleStabilizerLeft
Definition WsfRigidBodySixDOF_Mover.hpp:658
RigidBodyMover & operator=(const RigidBodyMover &other)=delete
size_t mHandleLandingGearMainRight
Definition WsfRigidBodySixDOF_Mover.hpp:668
std::string GetActiveAeroObjectName() const
Definition WsfRigidBodySixDOF_Mover.hpp:389
RigidBodyPilotManager * GetRigidBodyPilotManager() const
Definition WsfRigidBodySixDOF_Mover.hpp:454
ut::CloneablePtr< RigidBodyAeroCoreObject > mAeroCoreObjPtr
Definition WsfRigidBodySixDOF_Mover.hpp:624
size_t mHandleAileronRight
Definition WsfRigidBodySixDOF_Mover.hpp:653
size_t mHandleSpoilerRight
Definition WsfRigidBodySixDOF_Mover.hpp:657
PilotManager * GetPilotManager() const override
Definition WsfRigidBodySixDOF_Mover.hpp:453
double mLastThrustVectorYawRightPosition
Definition WsfRigidBodySixDOF_Mover.hpp:644
size_t mHandleLandingGear
Definition WsfRigidBodySixDOF_Mover.hpp:665
bool ProcessInput(UtInput &aInput) override
Definition WsfRigidBodySixDOF_Mover.cpp:145
UtVec3dX GetCenterOfGravity_ft() const override
Definition WsfRigidBodySixDOF_Mover.hpp:401
std::unique_ptr< RigidBodyMoverTestObject > mTestSupportObjectPtr
Definition WsfRigidBodySixDOF_Mover.hpp:620
size_t mHandleRudderLeft
Definition WsfRigidBodySixDOF_Mover.hpp:661
ut::CloneablePtr< RigidBodyLandingGear > mLandingGearPtr
Definition WsfRigidBodySixDOF_Mover.hpp:635
size_t mHandleRudder
Definition WsfRigidBodySixDOF_Mover.hpp:662
AeroCoreObject * GetAeroCoreObject() const override
Definition WsfRigidBodySixDOF_Mover.hpp:408
std::list< ut::CloneablePtr< RigidBodyAeroMovableObject > > mAeroPartList
Definition WsfRigidBodySixDOF_Mover.hpp:625
RigidBodyFlightControlSystem * GetFlightControls() const
Definition WsfRigidBodySixDOF_Mover.hpp:458
size_t mHandleStabilizerRight
Definition WsfRigidBodySixDOF_Mover.hpp:659
RigidBodyAeroCoreObject * GetActiveAeroObject() const
Definition WsfRigidBodySixDOF_Mover.hpp:386
double mLastNoseWheelSteeringRightPosition
Definition WsfRigidBodySixDOF_Mover.hpp:647
size_t mHandleSpoilerLeft
Definition WsfRigidBodySixDOF_Mover.hpp:656
size_t mHandleAileronLeft
Definition WsfRigidBodySixDOF_Mover.hpp:652
bool HasLandingGear() const
Definition WsfRigidBodySixDOF_Mover.hpp:508
size_t mHandleLandingGearMainLeft
Definition WsfRigidBodySixDOF_Mover.hpp:667
size_t mHandleFlapRight
Definition WsfRigidBodySixDOF_Mover.hpp:655
RigidBodyAeroCoreObject * mActiveAeroObjPtr
Definition WsfRigidBodySixDOF_Mover.hpp:627
double mLastThrustVectorPitchUpPosition
Definition WsfRigidBodySixDOF_Mover.hpp:645
size_t mHandleRudderRight
Definition WsfRigidBodySixDOF_Mover.hpp:663
double mLastThrustReverserLeverPosition
Definition WsfRigidBodySixDOF_Mover.hpp:643
const char * GetScriptClassName() const override
Definition WsfRigidBodySixDOF_Mover.hpp:191
bool mTaxiModeEnabledAtStart
Definition WsfRigidBodySixDOF_Mover.hpp:639
ut::CloneablePtr< RigidBodyIntegrator > mIntegratorPtr
Definition WsfRigidBodySixDOF_Mover.hpp:631
bool Initialize(double aSimTime) override
Definition WsfRigidBodySixDOF_Mover.cpp:383
double mLastThrustVectorRollRightPosition
Definition WsfRigidBodySixDOF_Mover.hpp:646
MoverTestObject * GetTestSupportObject() const override
Definition WsfRigidBodySixDOF_Mover.hpp:265
size_t mHandleLandingGearNose
Definition WsfRigidBodySixDOF_Mover.hpp:666
bool mLandingGearDownAtStart
Definition WsfRigidBodySixDOF_Mover.hpp:637
ut::CloneablePtr< RigidBodyPropulsionSystem > mPropulsionObjPtr
Definition WsfRigidBodySixDOF_Mover.hpp:629
size_t mHandleElevator
Definition WsfRigidBodySixDOF_Mover.hpp:660
double mLastWheelBrakeLeftPosition
Definition WsfRigidBodySixDOF_Mover.hpp:648
ut::CloneablePtr< RigidBodyFlightControlSystem > mFlightControlsPtr
Definition WsfRigidBodySixDOF_Mover.hpp:633
RigidBodyPropulsionSystem * GetRigidBodyPropulsionSystem()
Definition WsfRigidBodySixDOF_Mover.hpp:425
RigidBodyMoverTestObject * GetRigidBodyTestSupportObject() const
Definition WsfRigidBodySixDOF_Mover.hpp:264
size_t mHandleFlapLeft
Definition WsfRigidBodySixDOF_Mover.hpp:654
size_t mHandleSpeedBrake
Definition WsfRigidBodySixDOF_Mover.hpp:664
ut::CloneablePtr< RigidBodyPilotManager > mPilotManagerPtr
Definition WsfRigidBodySixDOF_Mover.hpp:634
RigidBodyMover(const WsfScenario &aScenario)
Constructor.
Definition WsfRigidBodySixDOF_Mover.cpp:55
RigidBodyLandingGear * GetLandingGear() const
Definition WsfRigidBodySixDOF_Mover.hpp:511
double mLastLandingGearLeverPosition
Definition WsfRigidBodySixDOF_Mover.hpp:642
WsfMover * Clone() const override
Definition WsfRigidBodySixDOF_Mover.cpp:139
bool mNWSEnabledAtStart
Definition WsfRigidBodySixDOF_Mover.hpp:640
Definition WsfRigidBodySixDOF_PilotManager.hpp:31
Definition WsfRigidBodySixDOF_PropulsionSystem.hpp:28
Definition WsfSA_Processor.hpp:35
Function definitions for those who need run-time access to the version.
Definition WsfComm.cpp:32
Copyrights Multiple, All Rights Reserved