Autopilot algorithms
Nodes:navsimcom| Module:shiva| Parameters:Autopilot
The module provides control loops for navigation and stabilization.
Configuration parameters
-
AutopilotControl parameters
-
modeOperation modeoption[off,local,primary,secondary,failsafe,auxillary]The priority of data, published by the module. All priorities, except
localare broadcasting data in network. -
RollRoll [deg] to Ailerons [%]
-
tcTime constantreal[s]0.1Smaller values make it faster to respond, larger values make it slower to respond. The error is divided by this time constant to get the rate setpoint.
-
KpProportional gainreal2 -
KiIntegral gainreal2.5 -
KdDifferential gainreal -
KffFeed forward gainreal -
LpRate limitreal[deg/s]40 -
LiIntegral limitbyte[%]10 -
LoOutput limitbyte[%]100 -
rdiffRate limit diffreal -
ifactorIntegral large error factorword[deg/s] -
trimRegulator output trimming factors.
-
lowLow speed trimreal[%] -
highHigh speed trimreal[%] -
flapsFlaps trimreal[%]
-
-
gainRegulator output gains.
-
lowLow speed gainreal -
highHigh speed gainreal -
flapsFlaps gainreal -
stabStability gainrealThis value is the gain multiplier for ailerons control when estimated stability is 1 (unstable). I.e. when parameter set to
0.2- the ailerons output will be multiplied by0.2when in stall condition, thus lowering the output value. For reverse ailerons - set parameter to negative, i.e. when set to-0.5, the ailerons gain will be-0.5in stall condition, making it reversed, and zero at about0.5of estimated stability. See chart for details.
-
-
cmdSetpoint
-
maxSetpoint limitreal[deg]45 -
slewSetpoint slew rate limitword[deg/s]40 -
diffSetpoint limit diffreal -
offsetSetpoint offsetreal[deg]
-
-
-
PitchPitch [deg] to Elevator [%]
-
tcTime constantreal[s]0.5Smaller values make it faster to respond, larger values make it slower to respond. The error is divided by this time constant to get the rate setpoint.
-
KpProportional gainreal6 -
KiIntegral gainreal3.5 -
KdDifferential gainreal -
KffFeed forward gainreal -
LpRate limitreal[deg/s]40 -
LiIntegral limitbyte[%]25 -
LoOutput limitbyte[%]100 -
rdiffRate limit diffreal -
ifactorIntegral large error factorword[deg/s] -
trimRegulator output trimming factors.
-
lowLow speed trimreal[%] -
highHigh speed trimreal[%] -
flapsFlaps trimreal[%] -
stabStall condition trimbyte[%]The estimated stability value will be multiplied by this factor and subtracted from elevator control [%]. This will make elevator down when in stall condition.
-
-
gainRegulator output gains.
-
lowLow speed gainreal -
highHigh speed gainreal -
flapsFlaps gainreal
-
-
cmdSetpoint
-
maxSetpoint limitreal[deg]20 -
slewSetpoint slew rate limitword[deg/s]10 -
diffSetpoint limit diffreal -
offsetSetpoint offsetreal[deg]
-
-
-
YawYaw [deg] to Rudder [%]
-
tcTime constantreal[s]2.5Smaller values make it faster to respond, larger values make it slower to respond. The error is divided by this time constant to get the rate setpoint.
-
KpProportional gainreal6 -
KiIntegral gainreal1.1 -
KdDifferential gainreal -
KffFeed forward gainreal -
LpRate limitreal[deg/s]40 -
LiIntegral limitbyte[%]5 -
LoOutput limitbyte[%]100 -
rdiffRate limit diffreal -
ifactorIntegral large error factorword[deg/s] -
trimRegulator output trimming factors.
-
lowLow speed trimreal[%] -
highHigh speed trimreal[%] -
flapsFlaps trimreal[%]
-
-
gainRegulator output gains.
-
lowLow speed gainreal -
highHigh speed gainreal -
flapsFlaps gainreal
-
-
slewYaw setpoint slew rate limitword[deg/s] -
slipSlip error to yaw rate proportional gainreal2
-
-
BearingWaypoint to Roll [deg]. L1 controller for trajectory navigation.
-
distL1 periodreal[m]25 -
dampDamping factorreal0.9 -
radiusWaypoint switch radiusword[m]50The waypoint is passed when the distance is lower than this value.
-
trigWaypoint heading rate switch triggerword[deg/s]10Another way to detect waypoint passed condition, i.e. when the rate of heading to the waypoint is higher than this value - the waypoint is considered as passed.
-
toptTurn direction optimizationoption[optimized,shortest]Enabling this option will optimize turn directions to avoid large bank angle changes. I.e. for U-turns this makes aircraft to continue existing turn maneuver when applicable.
-
-
AirspeedKinetic Energy to Pitch (TECS). This controller regulates rate of energy by changing the commanded pitch angle.
-
tcTime constantreal[s]6Smaller values make it faster to respond, larger values make it slower to respond. The error is divided by this time constant to get the rate setpoint.
-
KpEnergy rate error gainreal0.5The energy rate error is multiplied by this factor to provide pitch angle.
-
KiIntegrator gainreal1.1Trimming for the pitch angle to maintain commanded rate of energy.
-
LiIntegral limitbyte[deg] -
weightSpeed vs altitude tecs weighting factorreal1This parameter adjusts the amount of weighting that the pitch control applies to speed vs height errors. Setting it to 0 will cause the pitch control to control height and ignore speed errors. This will normally improve height accuracy but give larger airspeed errors. Setting it to 1 will cause the pitch control loop to control speed and ignore height errors. This will normally reduce airspeed errors, but give larger height errors. The value of 0.5 allows the pitch control to simultaneously control height and speed.
-
slewSpeed setpoint slew ratereal[m/s^2]1Commanded airspeed rate of change limit.
-
-
AltitudePotential Energy to Throttle (TECS). This controller regulates rate of energy by changing the engine throttle.
-
tcTime constantreal[s]10Smaller values make it faster to respond, larger values make it slower to respond. The error is divided by this time constant to get the rate setpoint.
-
KpEnergy rate error gainreal0.3The energy rate error is multiplied by this factor to provide throttle.
-
KiIntegrator gainreal0.1Trimming gain for the throttle to maintain commanded rate of energy.
-
rollRoll to energy rate feedforwardrealIncreasing this gain increases the amount of throttle that will be used to compensate for the additional drag created by turning.
-
slewVertical speed setpoint slew ratereal[m/s^2]1Commanded vertical speed rate of change limit.
-
-
EngineRPM to Throttle governor
-
KpProportional gainreal2.5 -
KdDifferential gainreal3.1 -
KiIntegral gainreal -
KffFeed forward gainreal0.5 -
rpmEngine RPM
-
filterKalman filter
-
errRpm measurement errorword[rpm]100 -
procProcess noisereal0.2 -
rateRpm rate lp filterreal0.1
-
-
cruiseCruise rpmdword[rpm]This is the RPM setting for cruise speed.
-
maxMaximum rpmdword[rpm]This is the engine maximum allowed RPM.
-
minMinimum rpmdword[rpm]This is the engine idle RPM.
-
slewRpm setpoint max slew rateword[rpm/s]500Maximum slew rate for the commanded RPM
-
startStartup rpm slew rateword[rpm/s]Maximum slew rate for the commanded RPM on startup procedure
-
-
thrThrottle setpoint
-
maxMax throttlebyte[%]100This is the maximum throttle that can be used by the regulator. For overpowered aircraft, this should be reduced to a value that provides sufficient thrust to climb at the maximum pitch angle.
-
minMin throttlebyte[%]This is the minimum throttle that can be used by the regulator. For electric aircraft this will normally be set to zero, but can be set to a small non-zero value if a folding prop is fitted to prevent the prop from folding and unfolding repeatedly in-flight or to provide some aerodynamic drag from a turning prop to improve the descent rate. For aircraft with internal combustion engine this parameter should be set for desired idle rpm.
-
slewThrottle max slew ratebyte[%/s]Maximum slew rate for the commanded throttle
-
startStartup throttle slew ratebyte[%/s]10Maximum slew rate for the commanded throttle on startup procedure
-
-
propProp pitch
-
maxMax prop pitchreal[%]100This is the maximum prop pitch that can be used by the regulator.
-
minMin prop pitchreal[%]This is the minimum prop pitch that can be used by the regulator.
-
slewProp max slew ratebyte[%/s]Maximum slew rate for the commanded prop
-
startProp setting on startupreal[%] -
gainProp multiplier on low rpmreal0.1
-
-
gliderEngine Governor RPM to Prop pitch [%]
-
KpProportional gainreal -
KdDifferential gainreal -
KiIntegral gainreal
-
-
-
TaxiTaxiways navigation
-
SteeringYaw [deg] to Steering [%]
-
tcTime constantreal[s]2.5Smaller values make it faster to respond, larger values make it slower to respond. The error is divided by this time constant to get the rate setpoint.
-
KpProportional gainreal5 -
KiIntegral gainreal0.1 -
KffFeed forward gainreal0 -
LpRate limitreal[deg/s]1000 -
LiIntegral limitbyte[%]5 -
gainSteering high speed gainreal0.1
-
-
TrackCrosstrack [m] to Yaw [deg]
-
distL1 periodreal[m]6 -
dampDamping factorreal1.7 -
trigTaxiway switch radiusword[m]15
-
-
BrakesSpeed to Brakes [%]
-
KpProportional gainreal10 -
KdDifferential gainreal
-
-
-
FlapsAuto flaps control
-
maxVso flapsbyte[%] -
minVsi flapsbyte[%] -
stepStep in automatic modebyte[%] -
takeoffTakeoff flapsbyte[%] -
approachApproach flapsbyte[%] -
finalFinal approach flapsbyte[%] -
ldFlaps ld gainrealFlaps level will affect proportionally the LD ratio when this parameter is set. The corrected LD ratio is used by landing procedure only to estimate landing patterns. F.ex. when set to
0.6- full flaps will make LD ratio (used by landing procedure) to be 0.6 of estimated LD, but 50% flaps will make LD to be 0.8 of estimated value.
-
-
HoverHovering regulators
-
tcTime constantreal[s]4Smaller values make it faster to respond, larger values make it slower to respond. The error is divided by this time constant to get the rate setpoint.
-
pitchVelocity X [m/s] to Pitch [deg]
-
KpProportional gainreal3 -
KiIntegral gainreal0.1 -
KdDifferential gainreal -
KffFeed forward gainreal -
LiIntegral limitbyte[deg]8 -
velSpeed limitreal[m/s]
-
-
rollVelocity Y [m/s] to Roll [deg]
-
KpProportional gainreal3 -
KiIntegral gainreal0.1 -
KdDifferential gainreal -
KffFeed forward gainreal -
LiIntegral limitbyte[deg]5 -
velSpeed limitreal[m/s]
-
-
-
TakeoffTakeoff procedure
-
modeTakeoff modeoption[runway,launcher,helipad] -
checkChecks to perform before takeoff
-
pwrPower stateoptionWill cancel takeoff if power is not valid
-
hdgHeading errorbyte[deg]Will cancel takeoff if heading error is more than this value
-
xtrackCrosstrack errorbyte[m]Will cancel takeoff if crosstrack error is more than this value
-
-
runTakeoff Run phase parameters
-
speedMax speedbyte[m/s] -
pitchRun phase pitch anglebyte[deg]
-
-
climbTakeoff Climbing phase parameters
-
pitchLiftoff phase pitch anglebyte[deg] -
altitudeLiftoff phase altitudebyte[m] -
thrClimbing throttlebyte[%]
-
-
launcherLauncher parameters
-
accLauncher trigger accelerationbyte[m/s^2] -
tdelayLauncher throttle delayreal[s] -
cdelayLauncher controls delayreal[s]
-
-
-
LandingLanding procedure
-
modeLanding modeoption[runway,parachute,helipad] -
aglAgl correction altitudeword[m] -
appApproach phase parameters
-
KpDelta [m] to speed [m/s] gainreal0.1 -
thrApproach throttlebyte[%]5 -
capEnergy capacity factorreal -
airbrkDistance error[m] to airbrake[%]
-
KpProportional gainreal -
KiIntegral gainreal -
LpProportional limitbyte[%] -
LiIntegral limitbyte[%] -
LoOutput limitbyte[%] -
biasBiasbyte[%]
-
-
-
flareFlare phase parameters
-
altFlare phase altitudebyte[m]20 -
pitchFlare max pitch angle limitreal[deg] -
sinkFlare sink ratereal[m/s]0.5 -
airbrkVertical speed error[m/s] to airbrake[%]
-
KpProportional gainreal -
LoOutput limitbyte[%]
-
-
-
touchTouchdown phase parameters
-
altTouchdown phase altitudebyte[m]3 -
pitchTouchdown max pitch angle limitbyte[deg]6 -
VS1GStall speed at 1g load factorreal[m/s]0This speed is defined as the one-G stall speed at which the airplane can develop a lift force (normal to the flight path) equal to its weight.
-
-
runRun phase parameters
-
speedSpeed to trigger run phasebyte[m/s] -
accAcceleration to trigger run phasebyte[m/s^2] -
altAltitude check to trigger run phaseoption -
brakesBrakes slew rate limitbyte[%/s] -
thrThrottle blockingoption[cut,override,shutdown,ignore]
-
-
-