Class: GPSSatellite
A tracked GPS satellite.
Constructors
constructor
• new GPSSatellite(prn
, sbasGroup
, ephemeris
, timingOptions
): GPSSatellite
Creates an instance of a GPSSatellite.
Parameters
Name | Type | Description |
---|---|---|
prn | number | The GPS PRN number for this satellite. |
sbasGroup | undefined | string | Whether or not this satellite is a SBAS satellite. |
ephemeris | undefined | GPSEphemeris | The ephemeris data to use for position calculation. |
timingOptions | Readonly <Required <GPSSatelliteTimingOptions >> | Options with which to configure the timing of this satellite's state changes. |
Returns
Defined in
src/sdk/instruments/GPSSat.ts:1951
Properties
position
• Readonly
position: Vec2Subject
The current satellite position, in zenith angle radians and hour angle radians.
Defined in
src/sdk/instruments/GPSSat.ts:1901
positionCartesian
• Readonly
positionCartesian: Vec3Subject
The current satellite position, in cartesian coordinates.
Defined in
src/sdk/instruments/GPSSat.ts:1904
prn
• Readonly
prn: number
The GPS PRN number for this satellite.
Defined in
src/sdk/instruments/GPSSat.ts:1952
sbasGroup
• Readonly
sbasGroup: undefined
| string
Whether or not this satellite is a SBAS satellite.
Defined in
src/sdk/instruments/GPSSat.ts:1953
signalStrength
• Readonly
signalStrength: Subject
<number
>
The current satellite signal strength.
Defined in
src/sdk/instruments/GPSSat.ts:1907
state
• Readonly
state: Subject
<GPSSatelliteState
>
The current satellite state.
Defined in
src/sdk/instruments/GPSSat.ts:1898
Accessors
areDiffCorrectionsDownloaded
• get
areDiffCorrectionsDownloaded(): boolean
Whether SBAS differential correction data have been downloaded from this satellite.
Returns
boolean
Defined in
src/sdk/instruments/GPSSat.ts:1935
lastEphemerisTime
• get
lastEphemerisTime(): undefined
| number
The most recent simulation time at which this satellite's ephemeris was downloaded, as a Javascript timestamp, or
undefined
if this satellite's ephemeris has not yet been downloaded.
Returns
undefined
| number
Defined in
src/sdk/instruments/GPSSat.ts:1918
lastUnreachableTime
• get
lastUnreachableTime(): undefined
| number
The most recent simulation time at which this satellite was confirmed to be unreachable, as a Javascript
timestamp, or undefined
if this satellite has not been confirmed to be unreachable.
Returns
undefined
| number
Defined in
src/sdk/instruments/GPSSat.ts:1928
Methods
applyProjection
▸ applyProjection(ppos
, altitude
): void
Applies a projection to the satellite cartesian coordinates to convert to zenith and hour angles.
Parameters
Name | Type | Description |
---|---|---|
ppos | GeoPoint | The current plane position. |
altitude | number | The current plane altitude in meters. |
Returns
void
Defined in
src/sdk/instruments/GPSSat.ts:2065
calculateSignalStrength
▸ calculateSignalStrength(altitude
): void
Calculates the current signal strength.
Parameters
Name | Type | Description |
---|---|---|
altitude | number | The current plane altitude in meters. |
Returns
void
Defined in
src/sdk/instruments/GPSSat.ts:2096
computeSatellitePositions
▸ computeSatellitePositions(simTime
): void
Computes the current satellite positions given the loaded ephemeris data.
Parameters
Name | Type | Description |
---|---|---|
simTime | number | The current simulator time, in milliseconds UNIX epoch |
Returns
void
Defined in
src/sdk/instruments/GPSSat.ts:1962
eraseCachedEphemeris
▸ eraseCachedEphemeris(): void
Erases this satellite's cached ephemeris data.
Returns
void
Defined in
src/sdk/instruments/GPSSat.ts:2126
forceUpdateState
▸ forceUpdateState(simTime
, state?
, areDiffCorrectionsDownloaded?
): boolean
Forces an update of this satellite's state to a specific value.
Parameters
Name | Type | Description |
---|---|---|
simTime | number | The current simulation time, as a Javascript timestamp. |
state | GPSSatelliteState | The state to which to update this satellite. Defaults to this satellite's current state. |
areDiffCorrectionsDownloaded | boolean | Whether to force differential corrections to be downloaded. Defaults to the satellite's current differential corrections download state. |
Returns
boolean
Whether this satellite's state changed as a result of the update.
Defined in
src/sdk/instruments/GPSSat.ts:2382
isCachedEphemerisValid
▸ isCachedEphemerisValid(simTime
): boolean
Checks whether this satellite's cached ephemeris data is valid at a given simulation time.
Parameters
Name | Type | Description |
---|---|---|
simTime | number | The simulation time at which to check for ephemeris validity, as a Javascript timestamp. |
Returns
boolean
Whether this satellite's cached ephemeris data is valid at the specified simulation time.
Defined in
src/sdk/instruments/GPSSat.ts:2119
setTracked
▸ setTracked(tracked
): void
Sets whether this satellite is being tracked by a receiver channel.
Parameters
Name | Type | Description |
---|---|---|
tracked | boolean | Whether this satellite is being tracked by a receiver channel. |
Returns
void
Defined in
src/sdk/instruments/GPSSat.ts:2134
updateDiffCorrectionsApplied
▸ updateDiffCorrectionsApplied(apply
): boolean
Updates whether differential corrections are applied to this satellite's ranging data when they are used to calculate a position solution.
Parameters
Name | Type | Description |
---|---|---|
apply | boolean | Whether differential corrections are applied. |
Returns
boolean
Whether this satellite's state changed as a result of the update.
Defined in
src/sdk/instruments/GPSSat.ts:2444
updateInUse
▸ updateInUse(inUse
): boolean
Updates whether this satellite is being used to calculate a position solution.
Parameters
Name | Type | Description |
---|---|---|
inUse | boolean | Whether the satellite is being used to calculate a position solution. |
Returns
boolean
Whether this satellite's state changed as a result of the update.
Defined in
src/sdk/instruments/GPSSat.ts:2420
updateState
▸ updateState(simTime
, deltaTime
, distanceFromLastKnownPos
, forceAcquireAndUse
): boolean
Updates the state of the satellite.
Parameters
Name | Type | Description |
---|---|---|
simTime | number | The current simulation time, as a Javascript timestamp. |
deltaTime | number | The amount of sim time that has elapsed since the last update, in milliseconds. |
distanceFromLastKnownPos | number | The distance, in great-arc radians, from the airplane's current actual position to its last known position. |
forceAcquireAndUse | boolean | Whether to force this satellite to the highest possible use state (GPSSatelliteState.DataCollected) if signal strength is sufficient. |
Returns
boolean
Whether this satellite's state changed as a result of the update.
Defined in
src/sdk/instruments/GPSSat.ts:2162
calcHorizonAngle
▸ calcHorizonAngle(altitude
): number
Calculates the horizon zenith angle.
Parameters
Name | Type | Description |
---|---|---|
altitude | number | The altitude, in meters. |
Returns
number
The calculated horizon zenith angle based on the current altitude.
Defined in
src/sdk/instruments/GPSSat.ts:2110