From f13a0f2b5a2433da38f7e7933ac7a4e8553b9791 Mon Sep 17 00:00:00 2001 From: legoboyvdlp R Date: Thu, 5 Aug 2021 15:54:38 +0100 Subject: [PATCH] Bugfix the PFD --- Models/Instruments/PFD/PFD.nas | 2 +- Nasal/Libraries/property-tree-setup.nas | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Models/Instruments/PFD/PFD.nas b/Models/Instruments/PFD/PFD.nas index 46fbdc6d..1fed75d8 100644 --- a/Models/Instruments/PFD/PFD.nas +++ b/Models/Instruments/PFD/PFD.nas @@ -397,7 +397,7 @@ var canvas_PFD_base = { me["AI_agl"].setText(sprintf("%s", math.round(math.clamp(gear_agl_cur, 0, 2500)))); - if (gear_agl_cur < 400 and pts.Velocities.groundspeedKt.getValue() > 50 and pts.Controls.Engines.Engine.throttlePos[0].getValue() < 0.78 and pts.Controls.Engines.Engine.throttlePos[1].getValue() < 0.78) { + if (gear_agl_cur < 400 and pts.Velocities.groundspeedKt.getValue() > 50 and pts.Fdm.JSBsim.Fadec.detent[0].getValue() <= 3 and pts.Fdm.JSBsim.Fadec.detent[1].getValue() <= 3) { me["tailstrikeInd"].show(); } else { me["tailstrikeInd"].hide(); diff --git a/Nasal/Libraries/property-tree-setup.nas b/Nasal/Libraries/property-tree-setup.nas index 725253e1..dce36645 100644 --- a/Nasal/Libraries/property-tree-setup.nas +++ b/Nasal/Libraries/property-tree-setup.nas @@ -104,6 +104,9 @@ var Fdm = { alpha: props.globals.getNode("/fdm/jsbsim/aero/alpha-deg"), alphaNorm: props.globals.getNode("/fdm/jsbsim/aero/alpha-deg-norm"), }, + Fadec: { + detent: [props.globals.getNode("/fdm/jsbsim/fadec/control-1/detent"),props.globals.getNode("/fdm/jsbsim/fadec/control-2/detent")], + }, Fcs: { brake: [props.globals.getNode("/fdm/jsbsim/fcs/left-brake-cmd-norm"),props.globals.getNode("/fdm/jsbsim/fcs/right-brake-cmd-norm")], flapDeg: props.globals.getNode("/fdm/jsbsim/fcs/flap-pos-deg"),