15 #include <matrix/LibMatrix.h>
70 virtual const char*
type()
const;
90 virtual void taxiTo(
const DtVector& destination,
double speed);
98 virtual void taxi(
double speed,
double turnRate);
103 virtual double calculateSteering(
double turnAngle)
const;
107 virtual double approximateThrottle(
double speed);
111 virtual double calculateCurrentBrakingDistance()
const;
127 virtual void flyTo(
const DtVector& destination,
double speed,
double maxTerrainAvoidanceLookaheadDist = -1);
134 virtual void flyToDirect(
const DtVector& destination,
double speed,
double maxTerrainAvoidanceLookaheadDist = -1);
144 virtual void fly(
double speed,
double turnRate,
double climbRate,
double maxTerrainAvoidanceLookaheadDist = -1);
154 virtual void flyFixedPitch(
double speed,
double turnRate,
double desiredPitch,
double maxTerrainAvoidanceLookaheadDist = -1);
159 virtual double terrainAvoidancePitch(
double speed,
double desiredPitch,
double maxTerrainAvoidanceLookaheadDist);
163 virtual bool clearPathTo(
const DtVector& localPosition);
190 virtual void circle(
const DtVector& center,
double radius,
double speed,
191 double altitude,
bool clockwise =
true);
195 virtual double calcControlForRoll(
double rollRate);
210 virtual double calcControlForThrottle(
double speed,
bool& deployFlaps);
223 virtual double decelerationLimitedClimbRate(
double altitudeError,
224 double desiredSpeed,
double finalClimbRate = 0.0);
229 virtual void calcControlForTurnAndClimb(
double turnRate,
double climbRate,
230 double& stickX,
double& pedal);
236 virtual void calcControlForTurnAndPitch(
double turnRate,
double desiredPitch,
237 double& stickX,
double& pedal,
double rollRate = 0.0);
245 virtual double calculateClimbRate(
double altitude,
double climbTime)
const;
260 virtual double calculateTurnRate(
double turnAngle,
double additionalTurnRate = 0)
const;
265 virtual double calculateRollAngle(
double turnRate,
double speed)
270 virtual double calculateRollRate(
double rollAngle,
double turnRate);
287 virtual void calculateNormalizedBodyVelocity();
294 virtual void calculateLocalAngularVelocity();
302 virtual void calculateSpeedRatioSquared();
311 virtual void initializeControllerForTick();
315 virtual bool createFixedWingControlPortGroup();
316 virtual bool createThrottlePort();
317 virtual bool createStickPort();
318 virtual bool createPedalPort();
319 virtual bool createBrakePort();
322 virtual bool createFlapsDeployedPort();
332 virtual void setMaxThrustAcceleration(
double maxThrustAcceleration);
335 virtual void setTakeOffDir(
const DtVector& takeOffDir);
336 virtual const DtVector& takeOffDir()
const;
340 virtual DtReal maxTurningGsForTask()
const;
341 virtual DtReal maxTurnRateCutoffAngle()
const;
342 virtual DtReal maxTaxiingTurnSpeed()
const;
343 virtual DtReal taxiingNearDistance()
const;
344 virtual DtReal taxiingAtDistance()
const;
345 virtual DtReal taxiingApproachSpeed()
const;
346 virtual DtReal maxPitchAngle()
const;
347 virtual DtReal timeToTargetAltitude()
const;
353 virtual double maxTurningGs()
const;
357 virtual bool terrainAvoidanceEnabled();
362 virtual double terrainAvoidanceLookaheadTime();
388 virtual void lookupAndCacheProcessSR();
404 virtual void updateCurrentState();
407 virtual void processEstimatedTotCalculation();
414 virtual double calculateCollisionLookAhead(
const double climbRate,
416 const double desiredAltitude);
503 const double DtEstimatedTotCalcInterval = 5.0;
#define DT_DLL_vrfmodel
This file is used to determine how to build.
Definition: vrfmodelDefines.h:24
virtual bool postAddComponentsInit()
Called after all components have been created, initialized and added to the component manager...
Definition: simComponent.h:144
double myCurrentHeading
Definition: fixedWingPilotController.h:496
DtVrfObject is used to represent any type of simulated object (entities, aggregate, control objects) in a VR-Forces application.
Definition: vrfObject.h:215
Instances of DtConstrainedDualAxisAnalogOutputPort are output ports through which data producers can ...
Definition: constrainedDualAxisAnalogIOPort.h:61
DtFixedWingFlightPSR * myProcessState
Pointer to a process state repository used to store state data associated with this component...
Definition: fixedWingPilotController.h:487
DtVector myCurrentLocalVelocity
Definition: fixedWingPilotController.h:493
Instances of DtBooleanOutputPort are output ports through which data producers can send boolean data...
Definition: boolIOPort.h:45
double myCurrentTopoRoll
Definition: fixedWingPilotController.h:498
DtConstrainedAnalogOutputPort * myThrottlePort
Output Port Name: throttle Output Port Description: Output Port Range: 0.
Definition: fixedWingPilotController.h:450
This class provides a base class for all controllers that are capable of executing a DtSimTask...
Definition: singleTaskControllerComponent.h:20
DtConstrainedAnalogOutputPort * myBrakePort
Output Port Name: brake Output Port Description: Output Port Range: 0.
Definition: fixedWingPilotController.h:471
A readable, writable type whose name is the name of a component and that has a list of component name...
Definition: componentDescriptor.h:42
Definition: readerWriterRegistry.h:39
virtual const char * type() const =0
Returns a string identifies the class type of component.
DtOutputPortGroup is a data port group of a data provider.
Definition: outputPortGroup.h:30
DtFixedWingPilotController is a controller that models the capabilities of a fixed-wing pilot...
Definition: fixedWingPilotController.h:44
virtual bool init()
Calls setRadio()
DtConstrainedAnalogOutputPort is a version of DtAnalogOutputPort which will constrain any outgoing va...
Definition: constrainedAnalogIOPort.h:54
virtual void clearTask()
If component is currently tasked, calls clearPendingSubtasks(), sets the tasked flag to false...
double myEstimatedTotLastCalcTime
used for tot calculation intervals
Definition: fixedWingPilotController.h:510
virtual void updateTaskVisualizations()
Called to update task visualizations after every tick.
Definition: simComponent.h:485
DtDcm myCurrentOrientationMatrix
Definition: fixedWingPilotController.h:495
class DtFixedWingFlightPSR:
Definition: fixedWingFlightPSR.h:38
DtVector myEstimatedTotTextPos
tot text position
Definition: fixedWingPilotController.h:512
This repository holds all information that is common to all the forms of local fixed wing entities wi...
Definition: fixedWingEntityStateRepository.h:37
virtual void tick()
This gives the thread of control to the component.
DtConstrainedAnalogOutputPort * myPedalPort
Output Port Name: pedal Output Port Description: Output Port Range: -1.
Definition: fixedWingPilotController.h:464
const double DtLandingTolerance
This is the tolerance for determining if a control point is close enough to the terrain (and maybe la...
Definition: fixedWingPilotController.h:35
const double DtTurningSpeedTol
Allow a turn of no more than 2 degrees when moving too fast, which equals ~ 0.0556 radians...
Definition: fixedWingPilotController.h:28
DtOutputPortGroup * myFixedWingControlPortGroup
Output Port Group Name: fixed-wing-control Output Port Group Description:
Definition: fixedWingPilotController.h:443
virtual bool createPorts()
Called by init.
virtual bool decideToGiveUpTask() const
This function is used to determine if the controller should give up trying to execute the current tas...
double myCurrentSpeed
Definition: fixedWingPilotController.h:494
DtConstrainedDualAxisAnalogOutputPort * myStickPort
Output Port Name: stick Output Port Description: Output Port Range: X: -1.
Definition: fixedWingPilotController.h:457
virtual bool createPortGroups()
Called by init.
double myCurrentTopoPitch
Definition: fixedWingPilotController.h:497
DtDcm myLocalToTopoDcm
Definition: fixedWingPilotController.h:499
The DtSimComponent class is the base class for the entire simulation model component hierarchy...
Definition: simComponent.h:67
DtVector myCurrentLocalPosition
State variables updated for the current time.
Definition: fixedWingPilotController.h:492
const DtTaskControllerComponent & operator=(const DtTaskControllerComponent &orig)
assignment operator
The simulation engine is controlled by a single,top-level class called the Simulation Manager...
Definition: simManager.h:102
double myEstimatedTotValue
the tot value
Definition: fixedWingPilotController.h:508
DtBooleanOutputPort * myFlapsDeployedPort
Output Port Name: flaps Output Port Description: Output Port Range: Output Port Default Value: true...
Definition: fixedWingPilotController.h:478
A DtTaskMsg is a DtRadioMsg with a pointer to a task.
Definition: taskMessage.h:19
DtFixedWingEntityStateRepository * myFixedWingEntityState
Definition: fixedWingPilotController.h:436
bool myEstimatedTotCalcEnabled
enabled flag for the tot calculations
Definition: fixedWingPilotController.h:506