From 77d1a2cfa76120edaf514d63a34d7d805d4fe4d4 Mon Sep 17 00:00:00 2001 From: Josh Davidson Date: Tue, 18 May 2021 13:15:09 -0400 Subject: [PATCH] Control: IAE EPR control law --- Models/Instruments/Upper-ECAM/Upper-ECAM.nas | 6 +- Systems/a320-v2527-a5-engine-fadec.xml | 370 +++++++++++++++++-- Systems/libraries.xml | 2 +- 3 files changed, 353 insertions(+), 25 deletions(-) diff --git a/Models/Instruments/Upper-ECAM/Upper-ECAM.nas b/Models/Instruments/Upper-ECAM/Upper-ECAM.nas index 79ffd0df..bebd84c4 100644 --- a/Models/Instruments/Upper-ECAM/Upper-ECAM.nas +++ b/Models/Instruments/Upper-ECAM/Upper-ECAM.nas @@ -206,11 +206,11 @@ var canvas_upperECAM = { }), props.UpdateManager.FromHashValue("EPR_actual_1", 0.0001, func(val) { obj["EPR1"].setText(sprintf("%1.0f", math.floor(val))); - obj["EPR1-decimal"].setText(sprintf("%03d", (val - int(val)) * 1000)); + obj["EPR1-decimal"].setText(sprintf("%03d", math.round((val - int(val)) * 1000))); }), props.UpdateManager.FromHashValue("EPR_actual_2", 0.0001, func(val) { obj["EPR2"].setText(sprintf("%1.0f", math.floor(val))); - obj["EPR2-decimal"].setText(sprintf("%03d", (val - int(val)) * 1000)); + obj["EPR2-decimal"].setText(sprintf("%03d", math.round((val - int(val)) * 1000))); }), props.UpdateManager.FromHashValue("EPR_lim", 0.005, func(val) { obj["EPR1-ylim"].setRotation((val + 90) * D2R); @@ -279,7 +279,7 @@ var canvas_upperECAM = { }), props.UpdateManager.FromHashValue("eprLimit", 0.0005, func(val) { obj["EPRLim"].setText(sprintf("%1.0f", math.floor(val))); - obj["EPRLim-decimal"].setText(sprintf("%03d", (val - int(val)) * 1000)); + obj["EPRLim-decimal"].setText(sprintf("%03d", math.round((val - int(val)) * 1000))); }), props.UpdateManager.FromHashValue("n1Limit", 0.01, func(val) { obj["N1Lim"].setText(sprintf("%s", math.floor(val + 0.05))); diff --git a/Systems/a320-v2527-a5-engine-fadec.xml b/Systems/a320-v2527-a5-engine-fadec.xml index ee918171..5da951a0 100644 --- a/Systems/a320-v2527-a5-engine-fadec.xml +++ b/Systems/a320-v2527-a5-engine-fadec.xml @@ -166,6 +166,14 @@ + @@ -184,23 +192,6 @@ - - - - - - - fadec/limit/toga-ref - 10 - - 0.5 - - - 10 - - - - @@ -246,6 +237,65 @@ + + + + + fadec/limit/toga-epr + fadec/epr/c2 + + + fadec/epr/c1 + 0.001 + + + + + + + + + + fadec/limit/toga-epr-n1-ref + + 0.00 24743.1 + 0.03 53194.6 + 1.00 10000000.0 + +
+ + 1 + 3.5 + +
+
+
+ + + + + + + + fadec/limit/toga-ref + 10 + + 0.5 + + + 10 + + + + + + + + fadec/control-1/n1-mode gt 0 + fadec/control-2/n1-mode gt 0 + + + @@ -310,7 +360,86 @@ - + + + + fadec/limit/mct-ref + 3.5 + + + + + + + + +
+ fadec/limit/mct-epr-input + + 24743.1 0.00 + 53194.6 0.03 + 10000000.0 1.00 + +
+ fadec/epr/c1 + + fadec/epr/c2 + +
+
+ + + + + + + + fadec/limit/mct-epr-ref + 1000 + + 0.5 + + + 1000 + + + + + + + + + fadec/limit/mct-epr + fadec/epr/c2 + + + fadec/epr/c1 + 0.001 + + + + + + + + + + fadec/limit/mct-epr-n1-ref + + 0.00 24743.1 + 0.03 53194.6 + 1.00 10000000.0 + +
+ + 1 + 3.5 + +
+
+
+ + @@ -327,6 +456,14 @@ + + + + fadec/control-1/n1-mode gt 0 + fadec/control-2/n1-mode gt 0 + + + @@ -357,7 +494,86 @@ - + + + + fadec/limit/climb-ref + 3.5 + + + + + + + + +
+ fadec/limit/climb-epr-input + + 24743.1 0.00 + 53194.6 0.03 + 10000000.0 1.00 + +
+ fadec/epr/c1 + + fadec/epr/c2 + +
+
+ + + + + + + + fadec/limit/climb-epr-ref + 1000 + + 0.5 + + + 1000 + + + + + + + + + fadec/limit/climb-epr + fadec/epr/c2 + + + fadec/epr/c1 + 0.001 + + + + + + + + + + fadec/limit/climb-epr-n1-ref + + 0.00 24743.1 + 0.03 53194.6 + 1.00 10000000.0 + +
+ + 1 + 3.5 + +
+
+
+ + @@ -374,6 +590,14 @@ + + + + fadec/control-1/n1-mode gt 0 + fadec/control-2/n1-mode gt 0 + + + @@ -462,7 +686,86 @@ - + + + + fadec/limit/mrev-ref + 3.5 + + + + + + + + +
+ fadec/limit/mrev-epr-input + + 24743.1 0.00 + 53194.6 0.03 + 10000000.0 1.00 + +
+ fadec/epr/c1 + + fadec/epr/c2 + +
+
+ + + + + + + + fadec/limit/mrev-epr-ref + 1000 + + 0.5 + + + 1000 + + + + + + + + + fadec/limit/mrev-epr + fadec/epr/c2 + + + fadec/epr/c1 + 0.001 + + + + + + + + + + fadec/limit/mrev-epr-n1-ref + + 0.00 24743.1 + 0.03 53194.6 + 1.00 10000000.0 + +
+ + 1 + 3.5 + +
+
+
+ + @@ -479,6 +782,14 @@ + + + + fadec/control-1/n1-mode gt 0 + fadec/control-2/n1-mode gt 0 + + + @@ -1295,7 +1606,24 @@ - + + + + fadec/limit/active-mode-int eq 4 + + + fadec/limit/active-mode-int eq 0 + + + fadec/limit/active-mode-int eq 1 + fadec/limit/active-mode-int eq 3 + + + fadec/limit/active-mode-int eq 2 + + + + fadec/limit/active-mode-int eq 4 diff --git a/Systems/libraries.xml b/Systems/libraries.xml index 851be919..f9b7e92b 100644 --- a/Systems/libraries.xml +++ b/Systems/libraries.xml @@ -29,7 +29,7 @@
/position/altitude-ft - 00.9857 + 00.9852430000.8584