Class: JetFadec
Defined in: src/sdk/fadec/JetFadec.ts:104
A FADEC for turbojets. Controls engine throttle based on throttle lever position and other inputs.
Extended by
Constructors
Constructor
new JetFadec(
bus,modes,throttleInfos,desiredThrottleMin,desiredThrottleMax):JetFadec
Defined in: src/sdk/fadec/JetFadec.ts:134
Constructor.
Parameters
| Parameter | Type | Default value | Description |
|---|---|---|---|
bus | EventBus | undefined | The event bus. |
modes | readonly JetFadecMode[] | undefined | The modes supported by this FADEC, ordered from highest to lowest priority. |
throttleInfos | readonly JetFadecThrottleInfo[] | undefined | An array containing information pertaining to the throttles controlled by this FADEC. The order of modes in the array determines their priority during mode selection. On every update cycle, the FADEC iterates through the modes array in order, calling accept() on each mode until a value of true is returned. Therefore, modes positioned earlier in the array have a higher priority for selection. |
desiredThrottleMin | number | -100 | The min value to limit the desiredThrottle by. Defaults to -100. |
desiredThrottleMax | number | 100 | The max value to limit the desiredThrottle by. Defaults to 100. |
Returns
JetFadec
Properties
bus
protectedreadonlybus:EventBus
Defined in: src/sdk/fadec/JetFadec.ts:135
The event bus.
desiredThrottleMax
protectedreadonlydesiredThrottleMax:number=100
Defined in: src/sdk/fadec/JetFadec.ts:139
The max value to limit the desiredThrottle by. Defaults to 100.
desiredThrottleMin
protectedreadonlydesiredThrottleMin:number=-100
Defined in: src/sdk/fadec/JetFadec.ts:138
The min value to limit the desiredThrottle by. Defaults to -100.
engineStates
protectedreadonlyengineStates:Record<number,JetFadecEngineState>
Defined in: src/sdk/fadec/JetFadec.ts:119
lastModes
protectedreadonlylastModes: (null|JetFadecMode)[]
Defined in: src/sdk/fadec/JetFadec.ts:121
modes
protectedreadonlymodes: readonlyJetFadecMode[]
Defined in: src/sdk/fadec/JetFadec.ts:136
The modes supported by this FADEC, ordered from highest to lowest priority.
publisher
protectedreadonlypublisher:Publisher<FadecEvents>
Defined in: src/sdk/fadec/JetFadec.ts:108
throttleInfos
protectedreadonlythrottleInfos: readonlyJetFadecThrottleInfoInternal[]
Defined in: src/sdk/fadec/JetFadec.ts:110
throttleLeverPositionValues
protectedreadonlythrottleLeverPositionValues: readonlyConsumerValue<number>[]
Defined in: src/sdk/fadec/JetFadec.ts:112
MSFS_STANDARD_SEA_LEVEL_TEMP_RANKINE
protectedreadonlystaticMSFS_STANDARD_SEA_LEVEL_TEMP_RANKINE:518.69=518.69
Defined in: src/sdk/fadec/JetFadec.ts:106
Methods
onUpdate()
protectedonUpdate(dt):void
Defined in: src/sdk/fadec/JetFadec.ts:225
A method called when this FADEC is updated.
Parameters
| Parameter | Type | Description |
|---|---|---|
dt | number | The elapsed real time, in milliseconds, since the last update. |
Returns
void
setMode()
protectedsetMode(index,mode):void
Defined in: src/sdk/fadec/JetFadec.ts:297
Sets a FADEC mode for a throttle.
Parameters
| Parameter | Type | Description |
|---|---|---|
index | number | The index of the throttle in this FADEC's throttle list. |
mode | null | JetFadecMode | The mode to set. |
Returns
void
start()
start(
frequency):void
Defined in: src/sdk/fadec/JetFadec.ts:176
Turns this FADEC on. If this FADEC is already running, then it will be turned off before turning on again with the specified frequency.
Parameters
| Parameter | Type | Description |
|---|---|---|
frequency | number | The frequency, in hertz, at which this FADEC will update. |
Returns
void
stop()
stop():
void
Defined in: src/sdk/fadec/JetFadec.ts:187
Turns this FADEC off.
Returns
void
updateEngineStates()
protectedupdateEngineStates():void
Defined in: src/sdk/fadec/JetFadec.ts:233
Updates the states for this FADEC's engines.
Returns
void
updateThrottle()
protectedupdateThrottle(index,dt):void
Defined in: src/sdk/fadec/JetFadec.ts:261
Updates a throttle.
Parameters
| Parameter | Type | Description |
|---|---|---|
index | number | The index of the throttle in this FADEC's throttle list. |
dt | number | The elapsed time, in milliseconds, since the last update. |
Returns
void
updateThrottles()
protectedupdateThrottles(dt):void
Defined in: src/sdk/fadec/JetFadec.ts:250
Updates this FADEC's engine throttles.
Parameters
| Parameter | Type | Description |
|---|---|---|
dt | number | The elapsed real time, in milliseconds, since the last update. |
Returns
void