Class: GarminAPUtils
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:11
A utility class for working with Garmin autopilots.
Constructors
Constructor
new GarminAPUtils():
GarminAPUtils
Returns
GarminAPUtils
Methods
backCourseCanActivate()
staticbackCourseCanActivate(apValues,navData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:112
Checks whether a localizer back-course director can be activated from an armed state.
Parameters
| Parameter | Type | Description |
|---|---|---|
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APBackCourseDirectorNavData> | The current radio navigation data received by the director. |
Returns
boolean
Whether the director can be activated from an armed state.
backCourseCanArm()
staticbackCourseCanArm(apValues,navData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:100
Checks whether a localizer back-course director can be armed.
Parameters
| Parameter | Type | Description |
|---|---|---|
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APBackCourseDirectorNavData> | The current radio navigation data received by the director. |
Returns
boolean
Whether the director can be armed.
backCourseCanRemainActive()
staticbackCourseCanRemainActive(apValues,navData,activateNavData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:137
Checks whether a localizer back-course director can remain in the active state.
Parameters
| Parameter | Type | Description |
|---|---|---|
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APBackCourseDirectorNavData> | The current radio navigation data received by the director. |
activateNavData | Readonly<APBackCourseDirectorActivateNavData> | The radio navigation data received by the director at the moment of activation. |
Returns
boolean
Whether the director can remain in the active state.
glidepathCanArm()
staticglidepathCanArm(apValues):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:204
Checks whether a glidepath director can be armed.
Parameters
| Parameter | Type | Description |
|---|---|---|
apValues | APValues | Autopilot values from the director's parent autopilot. |
Returns
boolean
Whether the director can be armed.
glideslopeCanActivate()
staticglideslopeCanActivate(apValues,navData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:175
Checks whether a glideslope director can be activated from an armed state.
Parameters
| Parameter | Type | Description |
|---|---|---|
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APGSDirectorNavData> | The current radio navigation data received by the director. |
Returns
boolean
Whether the director can be activated from an armed state.
glideslopeCanArm()
staticglideslopeCanArm(apValues,navData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:157
Checks whether a glideslope director can be armed.
Parameters
| Parameter | Type | Description |
|---|---|---|
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APGSDirectorNavData> | The current radio navigation data received by the director. |
Returns
boolean
Whether the director can be armed.
glideslopeCanRemainActive()
staticglideslopeCanRemainActive(apValues,navData,activateNavData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:188
Checks whether a glideslope director can remain in the active state.
Parameters
| Parameter | Type | Description |
|---|---|---|
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APGSDirectorNavData> | The current radio navigation data received by the director. |
activateNavData | Readonly<APGSDirectorActivateNavData> | The radio navigation data received by the director at the moment of activation. |
Returns
boolean
Whether the director can remain in the active state.
lnavIntercept()
staticlnavIntercept(dtk,xtk,tas):number
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:239
Calculates intercept angles for LNAV.
Parameters
| Parameter | Type | Description |
|---|---|---|
dtk | number | The desired track, in degrees true. |
xtk | number | The cross-track error, in nautical miles. Negative values indicate that the plane is to the left of the desired track. |
tas | number | The true airspeed of the plane, in knots. |
Returns
number
The intercept angle, in degrees, to capture the desired track from the navigation signal.
localizerIntercept()
staticlocalizerIntercept(xtk,tas):number
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:250
Calculates intercept angles for localizers.
Parameters
| Parameter | Type | Description |
|---|---|---|
xtk | number | The cross-track error of the plane from the desired track, in nautical miles. Positive values indicate indicate that the plane is to the right of the track. |
tas | number | The true airspeed of the plane, in knots. |
Returns
number
The intercept angle, in degrees, to capture the localizer course.
navCanActivate()
staticnavCanActivate(mode,apValues,navData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:34
Checks whether a nav director can be activated from an armed state.
Parameters
| Parameter | Type | Description |
|---|---|---|
mode | APLateralModes | The director's lateral mode. |
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APNavDirectorNavData> | The current radio navigation data received by the director. |
Returns
boolean
Whether the director can be activated from an armed state.
navCanArm()
staticnavCanArm(mode,apValues,navData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:19
Checks whether a nav director can be armed.
Parameters
| Parameter | Type | Description |
|---|---|---|
mode | APLateralModes | The director's lateral mode. |
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APNavDirectorNavData> | The current radio navigation data received by the director. |
Returns
boolean
Whether the director can be armed.
navCanRemainActive()
staticnavCanRemainActive(mode,apValues,navData,isInZoneOfConfusion,activateNavData):boolean
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:67
Checks whether a nav director can remain in the active state.
Parameters
| Parameter | Type | Description |
|---|---|---|
mode | APLateralModes | The director's lateral mode. |
apValues | APValues | Autopilot values from the director's parent autopilot. |
navData | Readonly<APNavDirectorNavData> | The current radio navigation data received by the director. |
isInZoneOfConfusion | boolean | Whether the source of the radio navigation data is a VOR and the airplane's position is close enough to the VOR to render lateral deviation values unreliable. |
activateNavData | Readonly<APNavDirectorActivateNavData> | The radio navigation data received by the director at the moment of activation. |
Returns
boolean
Whether the director can remain in the active state.
navIntercept()
staticnavIntercept(distanceToSource,deflection,xtk,tas,isLoc):number
Defined in: src/garminsdk/autopilot/GarminAPUtils.ts:223
Calculates intercept angles for radio nav.
Parameters
| Parameter | Type | Description |
|---|---|---|
distanceToSource | number | The distance from the plane to the source of the navigation signal, in nautical miles. |
deflection | number | The lateral deflection of the desired track relative to the plane, normalized from -1 to 1. Positive values indicate that the desired track is to the right of the plane. |
xtk | number | The cross-track error of the plane from the desired track, in nautical miles. Positive values indicate indicate that the plane is to the right of the track. |
tas | number | The true airspeed of the plane, in knots. |
isLoc | boolean | Whether the source of the navigation signal is a localizer. Defaults to false. |
Returns
number
The intercept angle, in degrees, to capture the desired track from the navigation signal.