diff --git a/A320-main.xml b/A320-main.xml
index 839560cd..4812ad96 100644
--- a/A320-main.xml
+++ b/A320-main.xml
@@ -428,7 +428,7 @@
300.0
- 2018.1.0
+ 2019.2.0
@@ -1690,6 +1690,15 @@
+
+ c
+ Reset view to center
+ true
+
+ nasal
+
+
+
x
Decrease field of view
@@ -1933,7 +1942,7 @@
Aircraft/A320-family/Nasal/Panels/atc.nas
- Aircraft/A320-family/Nasal/Systems/DMC.nas
+ Aircraft/A320-family/Nasal/Displays/DMC.nas
Aircraft/A320-family/gui/dialogs/refuel.nas
diff --git a/AircraftConfig/acconfig.nas b/AircraftConfig/acconfig.nas
index baeb6a24..54b93e3f 100644
--- a/AircraftConfig/acconfig.nas
+++ b/AircraftConfig/acconfig.nas
@@ -119,7 +119,7 @@ var du_quality = gui.Dialog.new("sim/gui/dialogs/acconfig/du-quality/dialog", "A
var rendering_dlg = gui.Dialog.new("sim/gui/dialogs/rendering/dialog", "Aircraft/A320-family/AircraftConfig/rendering.xml");
spinning.start();
init_dlg.open();
-http.load("https://raw.githubusercontent.com/legoboyvdlp/A320-family/master/revision.txt").done(func(r) setprop("/systems/acconfig/new-revision", r.response));
+http.load("https://raw.githubusercontent.com/legoboyvdlp/A320-family/201912/revision.txt").done(func(r) setprop("/systems/acconfig/new-revision", r.response));
var revisionFile = (getprop("/sim/aircraft-dir") ~ "/revision.txt");
var current_revision = io.readfile(revisionFile);
print("A320-family Revision: " ~ current_revision);
@@ -366,15 +366,15 @@ var beforestart_b = func {
setprop("/controls/adirs/ir[0]/knob","1");
setprop("/controls/adirs/ir[1]/knob","1");
setprop("/controls/adirs/ir[2]/knob","1");
- systems.ADIRSControlPanel.adrSw(0);
- systems.ADIRSControlPanel.adrSw(1);
- systems.ADIRSControlPanel.adrSw(2);
+ if (systems.ADIRSnew.Switches.adrSw[0].getValue() != 1) { systems.ADIRSControlPanel.adrSw(0); }
+ if (systems.ADIRSnew.Switches.adrSw[1].getValue() != 1) { systems.ADIRSControlPanel.adrSw(1); }
+ if (systems.ADIRSnew.Switches.adrSw[2].getValue() != 1) { systems.ADIRSControlPanel.adrSw(2); }
systems.ADIRSControlPanel.irModeSw(0, 1);
systems.ADIRSControlPanel.irModeSw(1, 1);
systems.ADIRSControlPanel.irModeSw(2, 1);
- systems.ADIRS.skip(0);
- systems.ADIRS.skip(1);
- systems.ADIRS.skip(2);
+ systems.ADIRSnew.ADIRunits[0].instAlign();
+ systems.ADIRSnew.ADIRunits[1].instAlign();
+ systems.ADIRSnew.ADIRunits[2].instAlign();
setprop("/controls/adirs/mcducbtn", 1);
setprop("/controls/switches/beacon", 1);
setprop("/controls/lighting/nav-lights-switch", 1);
@@ -457,15 +457,15 @@ var taxi_b = func {
setprop("/controls/adirs/ir[0]/knob","1");
setprop("/controls/adirs/ir[1]/knob","1");
setprop("/controls/adirs/ir[2]/knob","1");
- systems.ADIRSControlPanel.adrSw(0);
- systems.ADIRSControlPanel.adrSw(1);
- systems.ADIRSControlPanel.adrSw(2);
+ if (systems.ADIRSnew.Switches.adrSw[0].getValue() != 1) { systems.ADIRSControlPanel.adrSw(0); }
+ if (systems.ADIRSnew.Switches.adrSw[1].getValue() != 1) { systems.ADIRSControlPanel.adrSw(1); }
+ if (systems.ADIRSnew.Switches.adrSw[2].getValue() != 1) { systems.ADIRSControlPanel.adrSw(2); }
systems.ADIRSControlPanel.irModeSw(0, 1);
systems.ADIRSControlPanel.irModeSw(1, 1);
systems.ADIRSControlPanel.irModeSw(2, 1);
- systems.ADIRS.skip(0);
- systems.ADIRS.skip(1);
- systems.ADIRS.skip(2);
+ systems.ADIRSnew.ADIRunits[0].instAlign();
+ systems.ADIRSnew.ADIRunits[1].instAlign();
+ systems.ADIRSnew.ADIRunits[2].instAlign();
setprop("/controls/adirs/mcducbtn", 1);
setprop("/controls/switches/beacon", 1);
setprop("/controls/switches/wing-lights", 1);
diff --git a/Models/FlightDeck/a320.flightdeck.xml b/Models/FlightDeck/a320.flightdeck.xml
index da60b77d..c98a544c 100644
--- a/Models/FlightDeck/a320.flightdeck.xml
+++ b/Models/FlightDeck/a320.flightdeck.xml
@@ -464,7 +464,6 @@
select
- alt-text-test
atc-test
audio_att_sgn
audio_call_hf2_led
@@ -480,19 +479,27 @@
engine_fault_1
engine_fault_2
exped_led
- hdg-text-test
qnh-test
radio_opt_led
rudder-trim-test
- spd-text-test
terr_on_nd_on
ver.fmgc
+
+ controls/switches/annun-test
+
+
+
+
+ select
+ alt-text-test
+ hdg-text-test
+ spd-text-test
vs-text-test
-
- controls/switches/annun-test
- 1
-
+
+ /FMGC/FCU-working
+ /controls/switches/annun-test
+
diff --git a/Models/Instruments/IESI/IESI.nas b/Models/Instruments/IESI/IESI.nas
index c50b7a6b..6f86cce8 100644
--- a/Models/Instruments/IESI/IESI.nas
+++ b/Models/Instruments/IESI/IESI.nas
@@ -80,27 +80,20 @@ var canvas_IESI_base = {
dcess = systems.ELEC.Bus.dcEss.getValue();
dchot1 = systems.ELEC.Bus.dcHot1.getValue();
- if (dcess >= 25 or (dchot1 >= 25 and airspeed.getValue() >= 50)) {
+ cur_time = et.getValue();
+ if (dcess >= 25 or (dchot1 >= 25 and airspeed.getValue() >= 50 and cur_time >= 5)) {
IESI.page.show();
IESI.update();
if (aconfig.getValue() != 1 and iesi_init.getValue() != 1) {
iesi_init.setBoolValue(1);
- cur_time = et.getValue();
iesi_time.setValue(cur_time);
} else if (aconfig.getValue() == 1 and iesi_init.getValue() != 1) {
iesi_init.setBoolValue(1);
- cur_time = et.getValue() - 87;
- iesi_time.setValue(cur_time);
+ iesi_time.setValue(cur_time - 87);
}
} else {
iesi_init.setBoolValue(0);
- }
-
- if (dcess >= 25 or (dchot1 >= 25 and airspeed.getValue() >= 50)) {
- IESI.page.show();
- IESI.update();
- } else {
IESI.page.hide();
}
},
diff --git a/Models/Instruments/Lower-ECAM/Lower-ECAM.nas b/Models/Instruments/Lower-ECAM/Lower-ECAM.nas
index ac218504..0380b215 100644
--- a/Models/Instruments/Lower-ECAM/Lower-ECAM.nas
+++ b/Models/Instruments/Lower-ECAM/Lower-ECAM.nas
@@ -257,6 +257,7 @@ var gen2_load = props.globals.initNode("/systems/electrical/extra/gen2-load", 0,
var du4_test = props.globals.initNode("/instrumentation/du/du4-test", 0, "BOOL");
var du4_test_time = props.globals.initNode("/instrumentation/du/du4-test-time", 0, "DOUBLE");
var du4_test_amount = props.globals.initNode("/instrumentation/du/du4-test-amount", 0, "DOUBLE");
+var du4_offtime = props.globals.initNode("/instrumentation/du/du4-off-time", 0.0, "DOUBLE");
var canvas_lowerECAM_base = {
init: func(canvas_group, file) {
@@ -278,27 +279,34 @@ var canvas_lowerECAM_base = {
getKeys: func() {
return [];
},
- update: func() {
- elapsedtime = elapsed_sec.getValue();
+ updateDu4: func() {
+ var elapsedtime = elapsed_sec.getValue();
+
if (ac2.getValue() >= 110) {
- if (gear0_wow.getValue() == 1) {
- if (autoconfig_running.getValue() != 1 and du4_test.getValue() != 1) {
+ if (du4_offtime.getValue() + 3 < elapsedtime) {
+ if (gear0_wow.getValue() == 1) {
+ if (autoconfig_running.getValue() != 1 and du4_test.getValue() != 1) {
+ du4_test.setValue(1);
+ du4_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du4_test_time.setValue(elapsedtime);
+ } else if (autoconfig_running.getValue() == 1 and du4_test.getValue() != 1) {
+ du4_test.setValue(1);
+ du4_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du4_test_time.setValue(elapsedtime - 30);
+ }
+ } else {
du4_test.setValue(1);
- du4_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du4_test_time.setValue(elapsedtime);
- } else if (autoconfig_running.getValue() == 1 and du4_test.getValue() != 1) {
- du4_test.setValue(1);
- du4_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du4_test_time.setValue(elapsedtime - 30);
+ du4_test_amount.setValue(0);
+ du4_test_time.setValue(-100);
}
- } else {
- du4_test.setValue(1);
- du4_test_amount.setValue(0);
- du4_test_time.setValue(-100);
}
- } else if (ac1_src.getValue() == "XX" or ac2_src.getValue() == "XX") {
+ } else {
du4_test.setValue(0);
+ du4_offtime.setValue(elapsedtime);
}
+ },
+ update: func() {
+ var elapsedtime = elapsed_sec.getValue();
if (ac2.getValue() >= 110 and lighting_du4.getValue() > 0.01) {
if (du4_test_time.getValue() + du4_test_amount.getValue() >= elapsedtime) {
@@ -597,14 +605,14 @@ var canvas_lowerECAM_apu = {
me["APUAvail"].hide();
}
- if (tank3_content_lbs.getValue() < 100) {
+ if (!systems.FUEL.Pumps.apu.getBoolValue() and systems.FUEL.Pumps.allOff.getBoolValue()) {
me["APUfuelLO"].show();
} else {
me["APUfuelLO"].hide();
}
# APU Gen
- if (apu_volts.getValue() > 110) {
+ if (apu_volts.getValue() >= 110) {
me["APUGenVolt"].setColor(0.0509,0.7529,0.2941);
} else {
me["APUGenVolt"].setColor(0.7333,0.3803,0);
@@ -1433,13 +1441,13 @@ var canvas_lowerECAM_elec = {
me["GEN1-num-label"].setColor(0.8078,0.8039,0.8078);
}
- if (gen1_volts.getValue() > 120 or gen1_volts.getValue() < 110 or gen1_hz.getValue() > 410 or gen1_hz.getValue() < 390 or gen1_load.getValue() > 110) {
+ if (gen1_volts.getValue() > 120 or gen1_volts.getValue() < 110 or gen1_hz.getValue() > 410 or gen1_hz.getValue() < 390 or gen1_load.getValue() >= 110) {
me["GEN1-label"].setColor(0.7333,0.3803,0);
} else {
me["GEN1-label"].setColor(0.8078,0.8039,0.8078);
}
- if (gen1_load.getValue() > 110) {
+ if (gen1_load.getValue() >= 110) {
me["Gen1Load"].setColor(0.7333,0.3803,0);
} else {
me["Gen1Load"].setColor(0.0509,0.7529,0.2941);
@@ -1490,13 +1498,13 @@ var canvas_lowerECAM_elec = {
me["GEN2-num-label"].setColor(0.8078,0.8039,0.8078);
}
- if (gen2_volts.getValue() > 120 or gen2_volts.getValue() < 110 or gen2_hz.getValue() > 410 or gen2_hz.getValue() < 390 or gen2_load.getValue() > 110) {
+ if (gen2_volts.getValue() > 120 or gen2_volts.getValue() < 110 or gen2_hz.getValue() > 410 or gen2_hz.getValue() < 390 or gen2_load.getValue() >= 110) {
me["GEN2-label"].setColor(0.7333,0.3803,0);
} else {
me["GEN2-label"].setColor(0.8078,0.8039,0.8078);
}
- if (gen2_load.getValue() > 110) {
+ if (gen2_load.getValue() >= 110) {
me["Gen2Load"].setColor(0.7333,0.3803,0);
} else {
me["Gen2Load"].setColor(0.0509,0.7529,0.2941);
@@ -1540,13 +1548,13 @@ var canvas_lowerECAM_elec = {
me["APUGenHz"].setText(sprintf("%s", math.round(apu_hz.getValue())));
}
- if (apu_volts.getValue() > 120 or apu_volts.getValue() < 110 or apu_hz.getValue() > 410 or apu_hz.getValue() < 390 or apu_load.getValue() > 110) {
+ if (apu_volts.getValue() > 120 or apu_volts.getValue() < 110 or apu_hz.getValue() > 410 or apu_hz.getValue() < 390 or apu_load.getValue() >= 110) {
me["APUGentext"].setColor(0.7333,0.3803,0);
} else {
me["APUGentext"].setColor(0.8078,0.8039,0.8078);
}
- if(apu_load.getValue() > 110) {
+ if(apu_load.getValue() >= 110) {
me["APUGenLoad"].setColor(0.7333,0.3803,0);
} else {
me["APUGenLoad"].setColor(0.0509,0.7529,0.2941);
@@ -1625,25 +1633,25 @@ var canvas_lowerECAM_elec = {
me["ELEC-DCESS-label"].setColor(0.7333,0.3803,0);
}
- if (ac_ess.getValue() > 110) {
+ if (ac_ess.getValue() >= 110) {
me["ELEC-ACESS-label"].setColor(0.0509,0.7529,0.2941);
} else {
me["ELEC-ACESS-label"].setColor(0.7333,0.3803,0);
}
- if (systems.ELEC.Bus.acEssShed.getValue() > 110) {
+ if (systems.ELEC.Bus.acEssShed.getValue() >= 110) {
me["ACESS-SHED"].hide();
} else {
me["ACESS-SHED"].show();
}
- if (ac1.getValue() > 110) {
+ if (ac1.getValue() >= 110) {
me["ELEC-AC1-label"].setColor(0.0509,0.7529,0.2941);
} else {
me["ELEC-AC1-label"].setColor(0.7333,0.3803,0);
}
- if (ac2.getValue() > 110) {
+ if (ac2.getValue() >= 110) {
me["ELEC-AC2-label"].setColor(0.0509,0.7529,0.2941);
} else {
me["ELEC-AC2-label"].setColor(0.7333,0.3803,0);
@@ -1712,11 +1720,19 @@ var canvas_lowerECAM_elec = {
}
if (getprop("/systems/electrical/relay/ac-ess-feed-1/contact-pos") == 1) {
- me["ELEC-Line-AC1-ACESS"].show();
+ if (ac1.getValue() >= 110) {
+ me["ELEC-Line-AC1-ACESS"].show();
+ } else {
+ me["ELEC-Line-AC1-ACESS"].hide();
+ }
me["ELEC-Line-AC2-ACESS"].hide();
} elsif (getprop("/systems/electrical/relay/ac-ess-feed-2/contact-pos") == 1) {
me["ELEC-Line-AC1-ACESS"].hide();
- me["ELEC-Line-AC2-ACESS"].show();
+ if (ac2.getValue() >= 110) {
+ me["ELEC-Line-AC2-ACESS"].show();
+ } else {
+ me["ELEC-Line-AC2-ACESS"].hide();
+ }
} else {
me["ELEC-Line-AC1-ACESS"].hide();
me["ELEC-Line-AC2-ACESS"].hide();
@@ -1782,7 +1798,7 @@ var canvas_lowerECAM_elec = {
me["ELEC-Line-Emergen-ESSTR"].hide();
}
- if (!getprop("/systems/electrical/relay/ac-ess-feed-emer-gen/contact-pos") and (!getprop("/systems/electrical/relay/tr-contactor-1/contact-pos") or !getprop("/systems/electrical/relay/tr-contactor-2/contact-pos"))) {
+ if (systems.ELEC.Bus.acEss.getValue() >= 110 and !getprop("/systems/electrical/relay/ac-ess-feed-emer-gen/contact-pos") and (!getprop("/systems/electrical/relay/tr-contactor-1/contact-pos") or !getprop("/systems/electrical/relay/tr-contactor-2/contact-pos"))) {
me["ELEC-Line-ACESS-TRESS"].show();
} else {
me["ELEC-Line-ACESS-TRESS"].hide();
@@ -2739,13 +2755,13 @@ var canvas_lowerECAM_hyd = {
me["OVHT-Blue"].hide();
}
- if (systems.ELEC.Bus.ac1.getValue() > 110) {
+ if (systems.ELEC.Bus.ac1.getValue() >= 110) {
me["ELEC-Blue-label"].setColor(0.8078,0.8039,0.8078);
} else {
me["ELEC-Blue-label"].setColor(0.7333,0.3803,0);
}
- if (systems.ELEC.Bus.ac2.getValue() > 110) {
+ if (systems.ELEC.Bus.ac2.getValue() >= 110) {
me["ELEC-Yellow-label"].setColor(0.8078,0.8039,0.8078);
} else {
me["ELEC-Yellow-label"].setColor(0.7333,0.3803,0);
@@ -3329,6 +3345,7 @@ var canvas_lowerECAM_test = {
return ["Test_white","Test_text"];
},
update: func() {
+ var elapsedtime = elapsed_sec.getValue();
if (du4_test_time.getValue() + 1 >= elapsedtime) {
me["Test_white"].show();
me["Test_text"].hide();
@@ -3395,3 +3412,7 @@ var showLowerECAM = func {
var dlg = canvas.Window.new([512, 512], "dialog").set("resize", 1);
dlg.setCanvas(lowerECAM_display);
}
+
+setlistener("/systems/electrical/bus/ac-2", func() {
+ canvas_lowerECAM_base.updateDu4();
+}, 0, 0);
\ No newline at end of file
diff --git a/Models/Instruments/MCDU/MCDU.nas b/Models/Instruments/MCDU/MCDU.nas
index ed3088f4..daa64326 100644
--- a/Models/Instruments/MCDU/MCDU.nas
+++ b/Models/Instruments/MCDU/MCDU.nas
@@ -877,7 +877,7 @@ var canvas_MCDU_base = {
me["Simple_R6S"].setText("TROPO");
me["Simple_R1"].setText(sprintf("%s", depArpt.getValue() ~ "/" ~ arrArpt.getValue()));
me["Simple_R2"].setText("REQUEST ");
- me["Simple_R3"].setText("ALIGN IRS ");
+ me["Simple_R3"].setText("IRS INIT >");
me["Simple_R4"].setText("-----.--");
me["Simple_R5"].setText("WIND ");
me["Simple_R6"].setText(sprintf("%5.0f", tropo.getValue()));
diff --git a/Models/Instruments/ND/canvas/ND.nas b/Models/Instruments/ND/canvas/ND.nas
index 7b967524..ff78c1aa 100644
--- a/Models/Instruments/ND/canvas/ND.nas
+++ b/Models/Instruments/ND/canvas/ND.nas
@@ -20,8 +20,10 @@ var du1_test_amount = props.globals.getNode("/instrumentation/du/du1-test-amount
var du2_test = props.globals.getNode("/instrumentation/du/du2-test");
var du2_test_time = props.globals.getNode("/instrumentation/du/du2-test-time");
var du2_test_amount = props.globals.getNode("/instrumentation/du/du2-test-amount");
+var du2_offtime = props.globals.initNode("/instrumentation/du/du2-off-time", 0.0, "DOUBLE");
var du5_test = props.globals.getNode("/instrumentation/du/du5-test");
var du5_test_time = props.globals.getNode("/instrumentation/du/du5-test-time");
+var du5_offtime = props.globals.initNode("/instrumentation/du/du5-off-time", 0.0, "DOUBLE");
var du5_test_amount = props.globals.getNode("/instrumentation/du/du5-test-amount");
var du6_test = props.globals.getNode("/instrumentation/du/du6-test");
var du6_test_time = props.globals.getNode("/instrumentation/du/du6-test-time");
@@ -84,47 +86,60 @@ var canvas_nd_base = {
getKeys: func() {
return [];
},
- update: func() {
- elapsedtime = getprop("/sim/time/elapsed-sec");
+ updateDu2: func() {
+ var elapsedtime = getprop("/sim/time/elapsed-sec");
if (getprop("/systems/electrical/bus/ac-ess-shed") >= 110) {
- if (wow0.getValue() == 1) {
- if (getprop("/systems/acconfig/autoconfig-running") != 1 and du2_test.getValue() != 1) {
+ if (du2_offtime.getValue() + 3 < elapsedtime) {
+ if (wow0.getValue() == 1) {
+ if (getprop("/systems/acconfig/autoconfig-running") != 1 and du2_test.getValue() != 1) {
+ du2_test.setValue(1);
+ du2_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du2_test_time.setValue(getprop("/sim/time/elapsed-sec"));
+ } else if (getprop("/systems/acconfig/autoconfig-running") == 1 and du2_test.getValue() != 1) {
+ du2_test.setValue(1);
+ du2_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du2_test_time.setValue(getprop("/sim/time/elapsed-sec") - 30);
+ }
+ } else {
du2_test.setValue(1);
- du2_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du2_test_time.setValue(getprop("/sim/time/elapsed-sec"));
- } else if (getprop("/systems/acconfig/autoconfig-running") == 1 and du2_test.getValue() != 1) {
- du2_test.setValue(1);
- du2_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du2_test_time.setValue(getprop("/sim/time/elapsed-sec") - 30);
+ du2_test_amount.setValue(0);
+ du2_test_time.setValue(-100);
}
- } else {
- du2_test.setValue(1);
- du2_test_amount.setValue(0);
- du2_test_time.setValue(-100);
}
} else {
du2_test.setValue(0);
+ du2_offtime.setValue(elapsedtime);
}
+ },
+ updateDu5: func() {
+ var elapsedtime = getprop("/sim/time/elapsed-sec");
if (getprop("/systems/electrical/bus/ac-2") >= 110) {
- if (wow0.getValue() == 1) {
- if (getprop("/systems/acconfig/autoconfig-running") != 1 and du5_test.getValue() != 1) {
+ if (du5_offtime.getValue() + 3 < elapsedtime) {
+ if (wow0.getValue() == 1) {
+ if (getprop("/systems/acconfig/autoconfig-running") != 1 and du5_test.getValue() != 1) {
+ du5_test.setValue(1);
+ du5_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du5_test_time.setValue(getprop("/sim/time/elapsed-sec"));
+ } else if (getprop("/systems/acconfig/autoconfig-running") == 1 and du5_test.getValue() != 1) {
+ du5_test.setValue(1);
+ du5_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du5_test_time.setValue(getprop("/sim/time/elapsed-sec") - 30);
+ }
+ } else {
du5_test.setValue(1);
- du5_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du5_test_time.setValue(getprop("/sim/time/elapsed-sec"));
- } else if (getprop("/systems/acconfig/autoconfig-running") == 1 and du5_test.getValue() != 1) {
- du5_test.setValue(1);
- du5_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du5_test_time.setValue(getprop("/sim/time/elapsed-sec") - 30);
+ du5_test_amount.setValue(0);
+ du5_test_time.setValue(-100);
}
- } else {
- du5_test.setValue(1);
- du5_test_amount.setValue(0);
- du5_test_time.setValue(-100);
}
} else {
du5_test.setValue(0);
+ du5_offtime.setValue(elapsedtime);
}
+ },
+ update: func() {
+ var elapsedtime = getprop("/sim/time/elapsed-sec");
+
if (getprop("/systems/electrical/bus/ac-ess-shed") >= 110 and getprop("/controls/lighting/DU/du2") > 0) {
if (du2_test_time.getValue() + du2_test_amount.getValue() >= elapsedtime and cpt_du_xfr.getValue() != 1) {
ND_1.page.hide();
@@ -383,3 +398,11 @@ var showNd = func(nd = nil) {
var dlg = canvas.Window.new([512, 512], "dialog").set("resize", 1);
dlg.setCanvas(nd_display[nd]);
}
+
+setlistener("/systems/electrical/bus/ac-ess-shed", func() {
+ canvas_nd_base.updateDu2();
+}, 0, 0);
+
+setlistener("/systems/electrical/bus/ac-2", func() {
+ canvas_nd_base.updateDu5();
+}, 0, 0);
diff --git a/Models/Instruments/OHpanel/OHpanel.xml b/Models/Instruments/OHpanel/OHpanel.xml
index cad8a698..59a21701 100644
--- a/Models/Instruments/OHpanel/OHpanel.xml
+++ b/Models/Instruments/OHpanel/OHpanel.xml
@@ -40,14 +40,6 @@
ELAC1Btn1F
ELAC1Btn2O
EmerExtLtBtn2O
- Eng1FireAgt1Btn1S
- Eng1FireAgt1Btn2D
- Eng1FireAgt2Btn1S
- Eng1FireAgt2Btn2D
- Eng2FireAgt1Btn1S
- Eng2FireAgt1Btn2D
- Eng2FireAgt2Btn1S
- Eng2FireAgt2Btn2D
ExtPwrBtn2O
FAC1Btn1F
FAC1Btn2O
@@ -65,10 +57,18 @@
SEC1Btn1F
SEC1Btn2O
VentBlowBtn1F
+ Eng1FireAgt1Btn1S
+ Eng1FireAgt1Btn2D
+ Eng2FireAgt1Btn1S
+ Eng2FireAgt1Btn2D
+ Eng1FireAgt2Btn1S
+ Eng1FireAgt2Btn2D
+ Eng2FireAgt2Btn1S
+ Eng2FireAgt2Btn2D
systems/electrical/bus/ac-ess
- 25
+ 5
@@ -167,7 +167,7 @@
-
+
select
@@ -3248,16 +3248,10 @@
false
-
-
- systems/electrical/bus/dc-bat
- 25
-
-
- systems/electrical/bus/dc-ess
- 25
-
-
+
+ systems/electrical/bus/dc-bat
+ 25
+
property-toggle
controls/electrical/switches/apu
@@ -3696,21 +3690,8 @@
EmerGenInd1F
-
- systems/electrical/bus/dc-ess
- 25
-
-
-
- systems/electrical/bus/ac-1
- 0
-
-
- systems/electrical/bus/ac-2
- 0
-
-
+ /systems/electrical/light/rat-emer-gen-fault
controls/switches/annun-test
1
@@ -6497,6 +6478,18 @@
property-assign
controls/engines/engine[0]/agent1-btn
1
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+
@@ -6513,6 +6506,12 @@
property-assign
controls/engines/engine[0]/agent2-btn
1
+
+
+ systems/electrical/bus/dc-2
+ 25
+
+
@@ -6520,22 +6519,60 @@
select
Eng1FireAgt1Btn1S
+
+
+
+
+ controls/engines/engine[0]/fire-btn
+ 1
+
+
+ /controls/fire/test-btn-1
+ 1
+
+
+ controls/switches/annun-test
+ 1
+
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+
+
+
+
+
+ select
Eng1FireAgt2Btn1S
-
-
- controls/engines/engine[0]/fire-btn
- 1
-
-
- /controls/fire/test-btn-1
- 1
-
-
- controls/switches/annun-test
- 1
-
-
+
+
+
+ controls/engines/engine[0]/fire-btn
+ 1
+
+
+ /controls/fire/test-btn-1
+ 1
+
+
+ controls/switches/annun-test
+ 1
+
+
+
+ systems/electrical/bus/dc-2
+ 25
+
+
@@ -6592,6 +6629,24 @@
property-assign
controls/fire/test-btn-1
1
+
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+
+ systems/electrical/bus/dc-2
+ 25
+
+
+
@@ -6613,6 +6668,24 @@
property-assign
controls/fire/test-btn-2
1
+
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+
+ systems/electrical/bus/dc-2
+ 25
+
+
+
@@ -6634,6 +6707,18 @@
property-assign
controls/fire/apu-test-btn
1
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+
@@ -6746,6 +6831,22 @@
property-assign
controls/APU/agent-btn
1
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+ systems/electrical/bus/dc-bat
+ 25
+
+
+
@@ -6893,6 +6994,18 @@
property-assign
controls/engines/engine[1]/agent1-btn
1
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+
@@ -6909,6 +7022,12 @@
property-assign
controls/engines/engine[1]/agent2-btn
1
+
+
+ systems/electrical/bus/dc-2
+ 25
+
+
@@ -6916,22 +7035,60 @@
select
Eng2FireAgt1Btn1S
+
+
+
+
+ controls/engines/engine[1]/fire-btn
+ 1
+
+
+ /controls/fire/test-btn-2
+ 1
+
+
+ controls/switches/annun-test
+ 1
+
+
+
+
+ systems/electrical/bus/dc-hot-1
+ 25
+
+
+ systems/electrical/bus/dc-hot-2
+ 25
+
+
+
+
+
+
+
+ select
Eng2FireAgt2Btn1S
-
-
- controls/engines/engine[1]/fire-btn
- 1
-
-
- controls/fire/test-btn-2
- 1
-
-
- controls/switches/annun-test
- 1
-
-
+
+
+
+ controls/engines/engine[1]/fire-btn
+ 1
+
+
+ /controls/fire/test-btn-2
+ 1
+
+
+ controls/switches/annun-test
+ 1
+
+
+
+ systems/electrical/bus/dc-2
+ 25
+
+
diff --git a/Models/Instruments/PFD/PFD.nas b/Models/Instruments/PFD/PFD.nas
index c3e91595..44c79462 100644
--- a/Models/Instruments/PFD/PFD.nas
+++ b/Models/Instruments/PFD/PFD.nas
@@ -108,12 +108,6 @@ var athr = props.globals.getNode("/it-autoflight/output/athr", 1);
var gear_agl = props.globals.getNode("/position/gear-agl-ft", 1);
var aileron_input = props.globals.getNode("/controls/flight/aileron-input-fast", 1);
var elevator_input = props.globals.getNode("/controls/flight/elevator-input-fast", 1);
-var adirs0_active = props.globals.getNode("/instrumentation/adirs/adr[0]/active", 1);
-var adirs1_active = props.globals.getNode("/instrumentation/adirs/adr[1]/active", 1);
-var adirs2_active = props.globals.getNode("/instrumentation/adirs/adr[2]/active", 1);
-var ir0_aligned = props.globals.getNode("/instrumentation/adirs/ir[0]/aligned", 1);
-var ir1_aligned = props.globals.getNode("/instrumentation/adirs/ir[1]/aligned", 1);
-var ir2_aligned = props.globals.getNode("/instrumentation/adirs/ir[2]/aligned", 1);
var att_switch = props.globals.getNode("/controls/switching/ATTHDG", 1);
var air_switch = props.globals.getNode("/controls/switching/AIRDATA", 1);
@@ -128,11 +122,9 @@ var hdg_diff = props.globals.initNode("/instrumentation/pfd/hdg-diff", 0.0, "DOU
var hdg_scale = props.globals.initNode("/instrumentation/pfd/heading-scale", 0.0, "DOUBLE");
var track = props.globals.initNode("/instrumentation/pfd/track-deg", 0.0, "DOUBLE");
var track_diff = props.globals.initNode("/instrumentation/pfd/track-hdg-diff", 0.0, "DOUBLE");
-var speed_pred_1 = props.globals.initNode("/instrumentation/pfd/speed-lookahead-1", 0.0, "DOUBLE");
-var speed_pred_2 = props.globals.initNode("/instrumentation/pfd/speed-lookahead-2", 0.0, "DOUBLE");
-var speed_pred_3 = props.globals.initNode("/instrumentation/pfd/speed-lookahead-3", 0.0, "DOUBLE");
var du1_test = props.globals.initNode("/instrumentation/du/du1-test", 0, "BOOL");
var du1_test_time = props.globals.initNode("/instrumentation/du/du1-test-time", 0.0, "DOUBLE");
+var du1_offtime = props.globals.initNode("/instrumentation/du/du1-off-time", 0.0, "DOUBLE");
var du1_test_amount = props.globals.initNode("/instrumentation/du/du1-test-amount", 0.0, "DOUBLE");
var du2_test = props.globals.initNode("/instrumentation/du/du2-test", 0, "BOOL");
var du2_test_time = props.globals.initNode("/instrumentation/du/du2-test-time", 0.0, "DOUBLE");
@@ -143,6 +135,7 @@ var du5_test_amount = props.globals.initNode("/instrumentation/du/du5-test-amoun
var du6_test = props.globals.initNode("/instrumentation/du/du6-test", 0, "BOOL");
var du6_test_time = props.globals.initNode("/instrumentation/du/du6-test-time", 0.0, "DOUBLE");
var du6_test_amount = props.globals.initNode("/instrumentation/du/du6-test-amount", 0.0, "DOUBLE");
+var du6_offtime = props.globals.initNode("/instrumentation/du/du6-off-time", 0.0, "DOUBLE");
var canvas_PFD_base = {
init: func(canvas_group, file) {
@@ -196,47 +189,58 @@ var canvas_PFD_base = {
"QNH_std","QNH_box","LOC_pointer","LOC_scale","GS_scale","GS_pointer","CRS_pointer","HDG_target","HDG_scale","HDG_one","HDG_two","HDG_three","HDG_four","HDG_five","HDG_six","HDG_seven","HDG_digit_L","HDG_digit_R","HDG_error","HDG_group","HDG_frame",
"TRK_pointer","machError"];
},
- update: func() {
- elapsedtime_act = elapsedtime.getValue();
+ updateDu1: func() {
+ var elapsedtime_act = elapsedtime.getValue();
if (acess.getValue() >= 110) {
- if (wow0.getValue() == 1) {
- if (acconfig.getValue() != 1 and du1_test.getValue() != 1) {
+ if (du1_offtime.getValue() + 3 < elapsedtime_act) {
+ if (wow0.getValue() == 1) {
+ if (acconfig.getValue() != 1 and du1_test.getValue() != 1) {
+ du1_test.setValue(1);
+ du1_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du1_test_time.setValue(elapsedtime_act);
+ } else if (acconfig.getValue() == 1 and du1_test.getValue() != 1) {
+ du1_test.setValue(1);
+ du1_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du1_test_time.setValue(elapsedtime_act - 30);
+ }
+ } else {
du1_test.setValue(1);
- du1_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du1_test_time.setValue(elapsedtime_act);
- } else if (acconfig.getValue() == 1 and du1_test.getValue() != 1) {
- du1_test.setValue(1);
- du1_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du1_test_time.setValue(elapsedtime_act - 30);
+ du1_test_amount.setValue(0);
+ du1_test_time.setValue(-100);
}
- } else {
- du1_test.setValue(1);
- du1_test_amount.setValue(0);
- du1_test_time.setValue(-100);
}
} else {
du1_test.setValue(0);
+ du1_offtime.setValue(elapsedtime_act);
}
-
+ },
+ updateDu6: func() {
+ var elapsedtime_act = elapsedtime.getValue();
if (ac2.getValue() >= 110) {
- if (wow0.getValue() == 1) {
- if (acconfig.getValue() != 1 and du6_test.getValue() != 1) {
+ if (du6_offtime.getValue() + 3 < elapsedtime_act) {
+ if (wow0.getValue() == 1) {
+ if (acconfig.getValue() != 1 and du6_test.getValue() != 1) {
+ du6_test.setValue(1);
+ du6_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du6_test_time.setValue(elapsedtime_act);
+ } else if (acconfig.getValue() == 1 and du6_test.getValue() != 1) {
+ du6_test.setValue(1);
+ du6_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du6_test_time.setValue(elapsedtime_act - 30);
+ }
+ } else {
du6_test.setValue(1);
- du6_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du6_test_time.setValue(elapsedtime_act);
- } else if (acconfig.getValue() == 1 and du6_test.getValue() != 1) {
- du6_test.setValue(1);
- du6_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du6_test_time.setValue(elapsedtime_act - 30);
+ du6_test_amount.setValue(0);
+ du6_test_time.setValue(-100);
}
- } else {
- du6_test.setValue(1);
- du6_test_amount.setValue(0);
- du6_test_time.setValue(-100);
}
} else {
du6_test.setValue(0);
+ du6_offtime.setValue(elapsedtime_act);
}
+ },
+ update: func() {
+ var elapsedtime_act = elapsedtime.getValue();
if (acconfig_mismatch.getValue() == "0x000") {
PFD_1_mismatch.page.hide();
@@ -790,26 +794,22 @@ var canvas_PFD_1 = {
wow2_act = wow2.getValue();
# Errors
- if ((adirs0_active.getValue() == 1) or (air_switch.getValue() == -1 and adirs2_active.getValue() == 1)) {
- me["VS_group"].show();
- me["VS_error"].hide();
- } else {
- me["VS_error"].show();
- me["VS_group"].hide();
- }
-
- if ((ir0_aligned.getValue() == 1) or (ir2_aligned.getValue() == 1 and att_switch.getValue() == -1)) {
+ if (systems.ADIRSnew.ADIRunits[0].aligned == 1 or (systems.ADIRSnew.ADIRunits[2].aligned == 1 and att_switch.getValue() == -1)) {
me["AI_group"].show();
me["HDG_group"].show();
me["AI_error"].hide();
me["HDG_error"].hide();
me["HDG_frame"].setColor(1,1,1);
+ me["VS_group"].show();
+ me["VS_error"].hide(); # VS is inertial-sourced
} else {
me["AI_error"].show();
me["HDG_error"].show();
me["HDG_frame"].setColor(1,0,0);
me["AI_group"].hide();
me["HDG_group"].hide();
+ me["VS_error"].show();
+ me["VS_group"].hide();
}
# FD
@@ -938,7 +938,7 @@ var canvas_PFD_1 = {
me["ASI_target"].hide();
}
- me.ASItrend = speed_pred_1.getValue() - me.ASI;
+ me.ASItrend = dmc.DMController.DMCs[0].outputs[6].getValue() - me.ASI;
me["ASI_trend_up"].setTranslation(0, math.clamp(me.ASItrend, 0, 50) * -6.6);
me["ASI_trend_down"].setTranslation(0, math.clamp(me.ASItrend, -50, 0) * -6.6);
@@ -1083,37 +1083,22 @@ var canvas_PFD_2 = {
wow2_act = wow2.getValue();
# Errors
- if ((adirs1_active.getValue() == 1) or (air_switch.getValue() == 1 and adirs2_active.getValue() == 1)) {
- me["ALT_group"].show();
- me["ALT_group2"].show();
- me["ALT_scale"].show();
- me["VS_group"].show();
- me["ALT_error"].hide();
- me["ALT_frame"].setColor(1,1,1);
- me["VS_error"].hide();
- } else {
- me["ALT_error"].show();
- me["ALT_frame"].setColor(1,0,0);
- me["VS_error"].show();
- me["ASI_group"].hide();
- me["ALT_group"].hide();
- me["ALT_group2"].hide();
- me["ALT_scale"].hide();
- me["VS_group"].hide();
- }
-
- if ((ir1_aligned.getValue() == 1) or (ir2_aligned.getValue() == 1 and att_switch.getValue() == 1)) {
+ if (systems.ADIRSnew.ADIRunits[1].aligned == 1 or (systems.ADIRSnew.ADIRunits[2].aligned == 1 and att_switch.getValue() == 1)) {
me["AI_group"].show();
me["HDG_group"].show();
me["AI_error"].hide();
me["HDG_error"].hide();
me["HDG_frame"].setColor(1,1,1);
+ me["VS_group"].show();
+ me["VS_error"].hide(); # VS is inertial-sourced
} else {
me["AI_error"].show();
me["HDG_error"].show();
me["HDG_frame"].setColor(1,0,0);
me["AI_group"].hide();
me["HDG_group"].hide();
+ me["VS_error"].show();
+ me["VS_group"].hide();
}
# FD
@@ -1242,7 +1227,7 @@ var canvas_PFD_2 = {
me["ASI_target"].hide();
}
- me.ASItrend = speed_pred_2.getValue() - me.ASI;
+ me.ASItrend = dmc.DMController.DMCs[1].outputs[6].getValue() - me.ASI;
me["ASI_trend_up"].setTranslation(0, math.clamp(me.ASItrend, 0, 50) * -6.6);
me["ASI_trend_down"].setTranslation(0, math.clamp(me.ASItrend, -50, 0) * -6.6);
@@ -1584,4 +1569,12 @@ var fontSizeHDG = func(input) {
} else {
return 32;
}
-};
\ No newline at end of file
+};
+
+setlistener("/systems/electrical/bus/ac-ess", func() {
+ canvas_PFD_base.updateDu1();
+}, 0, 0);
+
+setlistener("/systems/electrical/bus/ac-2", func() {
+ canvas_PFD_base.updateDu6();
+}, 0, 0);
\ No newline at end of file
diff --git a/Models/Instruments/Upper-ECAM/Upper-ECAM.nas b/Models/Instruments/Upper-ECAM/Upper-ECAM.nas
index 8f1602c0..a72fa686 100644
--- a/Models/Instruments/Upper-ECAM/Upper-ECAM.nas
+++ b/Models/Instruments/Upper-ECAM/Upper-ECAM.nas
@@ -28,6 +28,7 @@ var N1_lim = props.globals.initNode("/ECAM/Upper/N1ylim", 0, "DOUBLE");
var du3_test = props.globals.initNode("/instrumentation/du/du3-test", 0, "BOOL");
var du3_test_time = props.globals.initNode("/instrumentation/du/du3-test-time", 0.0, "DOUBLE");
var du3_test_amount = props.globals.initNode("/instrumentation/du/du3-test-amount", 0.0, "DOUBLE");
+var du3_offtime = props.globals.initNode("/instrumentation/du/du3-off-time", 0.0, "DOUBLE");
# Fetch nodes:
var et = props.globals.getNode("/sim/time/elapsed-sec", 1);
@@ -133,28 +134,34 @@ var canvas_upperECAM_base = {
getKeys: func() {
return [];
},
- update: func() {
- elapsedtime = et.getValue();
+ updateDu3: func() {
+ var elapsedtime = et.getValue();
if (acess.getValue() >= 110) {
- if (wow0.getValue() == 1) {
- if (acconfig.getValue() != 1 and du3_test.getValue() != 1) {
+ if (du3_offtime.getValue() + 3 < elapsedtime) {
+ if (wow0.getValue() == 1) {
+ if (acconfig.getValue() != 1 and du3_test.getValue() != 1) {
+ du3_test.setValue(1);
+ du3_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du3_test_time.setValue(elapsedtime);
+ } else if (acconfig.getValue() == 1 and du3_test.getValue() != 1) {
+ du3_test.setValue(1);
+ du3_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
+ du3_test_time.setValue(elapsedtime - 30);
+ }
+ } else {
du3_test.setValue(1);
- du3_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du3_test_time.setValue(elapsedtime);
- } else if (acconfig.getValue() == 1 and du3_test.getValue() != 1) {
- du3_test.setValue(1);
- du3_test_amount.setValue(math.round((rand() * 5 ) + 35, 0.1));
- du3_test_time.setValue(elapsedtime - 30);
+ du3_test_amount.setValue(0);
+ du3_test_time.setValue(-100);
}
- } else {
- du3_test.setValue(1);
- du3_test_amount.setValue(0);
- du3_test_time.setValue(-100);
}
} else {
du3_test.setValue(0);
+ du3_offtime.setValue(elapsedtime);
}
+ },
+ update: func() {
+ var elapsedtime = et.getValue();
cur_eng_option = eng_option.getValue();
if (acess.getValue() >= 110 and du3_lgt.getValue() > 0.01) {
@@ -1168,6 +1175,7 @@ var canvas_upperECAM_test = {
return ["Test_white","Test_text"];
},
update: func() {
+ var elapsedtime = et.getValue();
if (du3_test_time.getValue() + 1 >= elapsedtime) {
me["Test_white"].show();
me["Test_text"].hide();
@@ -1212,3 +1220,7 @@ var showUpperECAM = func {
var dlg = canvas.Window.new([512, 512], "dialog").set("resize", 1);
dlg.setCanvas(upperECAM_display);
}
+
+setlistener("/systems/electrical/bus/ac-ess", func() {
+ canvas_upperECAM_base.updateDu3();
+}, 0, 0);
diff --git a/Nasal/Systems/DMC.nas b/Nasal/Displays/DMC.nas
similarity index 88%
rename from Nasal/Systems/DMC.nas
rename to Nasal/Displays/DMC.nas
index 64283871..ae4ccd0f 100644
--- a/Nasal/Systems/DMC.nas
+++ b/Nasal/Displays/DMC.nas
@@ -15,12 +15,13 @@ var DMC = {
altitudesPfd: [props.globals.getNode("/instrumentation/altimeter[0]/indicated-altitude-ft-pfd", 1), props.globals.getNode("/instrumentation/altimeter[1]/indicated-altitude-ft-pfd", 1), props.globals.getNode("/instrumentation/altimeter[2]/indicated-altitude-ft-pfd", 1)],
sats: [props.globals.getNode("/systems/navigation/adr/output/sat-1", 1), props.globals.getNode("/systems/navigation/adr/output/sat-2", 1), props.globals.getNode("/systems/navigation/adr/output/sat-3", 1)],
tats: [props.globals.getNode("/systems/navigation/adr/output/tat-1", 1), props.globals.getNode("/systems/navigation/adr/output/tat-2", 1), props.globals.getNode("/systems/navigation/adr/output/tat-3", 1)],
- outputs: [nil, nil, nil, nil, nil, nil], # airspeed, altitude, mach, pfd altitude, sat, tat
+ trends: [props.globals.getNode("/instrumentation/pfd/speed-lookahead-1", 1), props.globals.getNode("/instrumentation/pfd/speed-lookahead-2", 1), props.globals.getNode("/instrumentation/pfd/speed-lookahead-3", 1)],
+ outputs: [nil, nil, nil, nil, nil, nil, nil], # airspeed, altitude, mach, pfd altitude, sat, tat, speed trend
new: func(num) {
var d = { parents:[DMC] };
d.activeADIRS = num;
- d.outputs = [nil, nil, nil, nil, nil, nil];
+ d.outputs = [nil, nil, nil, nil, nil, nil, nil];
return d;
},
changeActiveADIRS: func(newADIRS) {
@@ -34,6 +35,7 @@ var DMC = {
me.outputs[3] = me.altitudesPfd[ADIRS];
me.outputs[4] = me.sats[ADIRS];
me.outputs[5] = me.tats[ADIRS];
+ me.outputs[6] = me.trends[ADIRS];
},
setOutputsNil: func() {
me.outputs[0] = nil;
@@ -42,6 +44,7 @@ var DMC = {
me.outputs[3] = nil;
me.outputs[4] = nil;
me.outputs[5] = nil;
+ me.outputs[6] = nil;
},
update: func() {
if (systems.ADIRSnew.ADIRunits[me.activeADIRS].operative and systems.ADIRSnew.ADIRunits[me.activeADIRS].outputOn) {
diff --git a/Nasal/ECAM/ECAM-controller.nas b/Nasal/ECAM/ECAM-controller.nas
index 3b9c2ca4..740ab37e 100644
--- a/Nasal/ECAM/ECAM-controller.nas
+++ b/Nasal/ECAM/ECAM-controller.nas
@@ -25,16 +25,19 @@ var statusIndex = 0;
var flash = 0;
var hasCleared = 0;
var statusFlag = 0;
+var counter = 0;
+var noMainMsg = 0;
+var storeFirstWarning = nil;
var warning = {
- new: func(msg,colour = "g",aural = 9,light = 9,hasSubmsg = 0,lastSubmsg = 0, sdPage = "nil", isMemo = 0) {
+ new: func(msg,colour = "g",aural = 9,light = 9,isMainMsg = 0,lastSubmsg = 0, sdPage = "nil", isMemo = 0) {
var t = {parents:[warning]};
t.msg = msg;
t.colour = colour;
t.aural = aural;
t.light = light;
- t.hasSubmsg = hasSubmsg;
+ t.isMainMsg = isMainMsg;
t.lastSubmsg = lastSubmsg;
t.active = 0;
t.noRepeat = 0;
@@ -51,19 +54,21 @@ var warning = {
if (me.active == 0) { return; }
me.wasActive = 1;
lineIndex = 0;
- while (lineIndex < 7 and lines[lineIndex].getValue() != "") {
+ while (lineIndex <= 7 and lines[lineIndex].getValue() != "") {
lineIndex = lineIndex + 1; # go to next line until empty line
}
- if (lineIndex == 7) {
+ if (lineIndex == 8) {
leftOverflow.setBoolValue(1);
} elsif (leftOverflow.getBoolValue()) {
leftOverflow.setBoolValue(0);
}
- if (lines[lineIndex].getValue() == "" and me.msg != "" and lineIndex <= 7) { # at empty line. Also checks if message is not blank to allow for some warnings with no displayed msg, eg stall
- lines[lineIndex].setValue(me.msg);
- linesCol[lineIndex].setValue(me.colour);
+ if (lineIndex <= 7) {
+ if (lines[lineIndex].getValue() == "" and me.msg != "") { # at empty line. Also checks if message is not blank to allow for some warnings with no displayed msg, eg stall
+ lines[lineIndex].setValue(me.msg);
+ linesCol[lineIndex].setValue(me.colour);
+ }
}
},
warnlight: func() {
@@ -89,11 +94,13 @@ var warning = {
if (me.aural != 0) {
aural[me.aural].setBoolValue(0);
+ settimer(func() {
+ aural[me.aural].setBoolValue(1);
+ }, 0.15);
+ } else {
+ aural[me.aural].setBoolValue(1);
}
me.noRepeat2 = 1;
- settimer(func() {
- aural[me.aural].setBoolValue(1);
- }, 0.15);
},
callPage: func() {
if (me.sdPage == "nil" or me.hasCalled == 1) { return; }
@@ -201,12 +208,13 @@ var ECAM_controller = {
if (!getprop("/systems/acconfig/autoconfig-running")) {
foreach (var w; warnings.vector) {
- if (counter >= 9) { break; }
if (w.active == 1) {
- w.write();
+ if (counter < 9) {
+ w.write();
+ counter += 1;
+ }
w.warnlight();
w.sound();
- counter += 1;
} elsif (w.wasActive == 1) {
w.warnlight();
w.sound();
@@ -284,32 +292,50 @@ var ECAM_controller = {
clear: func() {
hasCleared = 0;
counter = 0;
+ noMainMsg = 0;
+ storeFirstWarning = nil;
- if (leftOverflow.getBoolValue()) {
- foreach (var w; warnings.vector) {
- if (counter >= 8) { break; }
- if (w.active == 1 and w.clearFlag != 1 and w.isMemo != 1) {
- counter += 1;
- if (w.hasSubmsg == 1) { continue; }
- w.clearFlag = 1;
- hasCleared = 1;
- statusFlag = 1;
- libraries.ECAMControlPanel.lightOff("clr");
- }
- }
- } else {
- foreach (var w; warnings.vector) {
- if (w.active == 1 and w.clearFlag != 1 and w.hasSubmsg == 1 and w.isMemo != 1) {
- w.clearFlag = 1;
- hasCleared = 1;
- statusFlag = 1;
- libraries.ECAMControlPanel.lightOff("clr");
- break;
+ # first go through the first eight, see how many mainMsg there are
+ foreach (var w; warnings.vector) {
+ if (counter >= 8) { break; }
+ if (w.active == 1 and w.clearFlag != 1 and w.isMemo != 1) {
+ counter += 1;
+ if (w.isMainMsg == 1) {
+ if (noMainMsg == 0) {
+ storeFirstWarning = w;
+ }
+ noMainMsg += 1;
}
}
}
- if (statusFlag == 1) {
+ # then, if there is an overflow and noMainMsg == 1, we clear the first shown ones
+ if (leftOverflow.getBoolValue() and noMainMsg == 1) {
+ counter = 0;
+ foreach (var w; warnings.vector) {
+ if (counter >= 8) { break; }
+ if (w.active == 1 and w.clearFlag != 1 and w.isMemo != 1) {
+ counter += 1;
+ if (w.isMainMsg == 1) { continue; }
+ w.clearFlag = 1;
+ hasCleared = 1;
+ statusFlag = 1;
+ }
+ }
+ }
+
+ # else, we clear the first mainMsg stored
+ else {
+ if (storeFirstWarning != nil) {
+ if (storeFirstWarning.active == 1 and storeFirstWarning.clearFlag != 1 and storeFirstWarning.isMainMsg == 1 and storeFirstWarning.isMemo != 1) {
+ storeFirstWarning.clearFlag = 1;
+ hasCleared = 1;
+ statusFlag = 1;
+ }
+ }
+ }
+
+ if (statusFlag == 1 and lines[0].getValue() == "") {
libraries.SystemDisplay.manCall("sts");
statusFlag = 0;
}
@@ -341,12 +367,13 @@ var ECAM_controller = {
}
},
warningReset: func(warning) {
+ if (warning.aural != 9 and warning.active == 1) {
+ aural[warning.aural].setBoolValue(0);
+ }
warning.active = 0;
warning.noRepeat = 0;
warning.noRepeat2 = 0;
- if (warning.aural == 2) {
- aural[2].setValue(0);
- }
+ # don't set .wasActive to 0, warnlight / sound funcs do that
},
};
diff --git a/Nasal/ECAM/ECAM-logic.nas b/Nasal/ECAM/ECAM-logic.nas
index 55105b4c..794ada61 100644
--- a/Nasal/ECAM/ECAM-logic.nas
+++ b/Nasal/ECAM/ECAM-logic.nas
@@ -29,6 +29,10 @@ var phaseVar = nil;
var dualFailFACActive = 1;
var emerConfigFACActive = 1;
var gear_agl_cur = nil;
+var numberMinutes = nil;
+var timeNow = nil;
+var timer10secIRS = nil;
+
var messages_priority_3 = func {
phaseVar = phaseNode.getValue();
@@ -738,45 +742,6 @@ var messages_priority_3 = func {
ap_offw.active = 1;
} else {
ECAM_controller.warningReset(ap_offw);
- if (getprop("/it-autoflight/output/ap-warning") == 2) {
- setprop("/it-autoflight/output/ap-warning", 0);
- setprop("/ECAM/Lower/light/clr", 0);
- setprop("/ECAM/warnings/master-warning-light", 0);
- }
- }
-
- if ((athr_lock.clearFlag == 0) and phaseVar >= 5 and phaseVar <= 7 and getprop("/systems/thrust/thr-locked-alert") == 1) {
- if (getprop("/systems/thrust/thr-locked-flash") == 0) {
- athr_lock.msg = " ";
- } else {
- athr_lock.msg = msgSave
- }
- athr_lock.active = 1;
- athr_lock_1.active = 1;
- } else {
- ECAM_controller.warningReset(athr_lock);
- ECAM_controller.warningReset(athr_lock_1);
- }
-
- if ((athr_offw.clearFlag == 0) and athrWarn.getValue() == 2 and phaseVar != 4 and phaseVar != 8 and phaseVar != 10) {
- athr_offw.active = 1;
- athr_offw_1.active = 1;
- } else {
- ECAM_controller.warningReset(athr_offw);
- ECAM_controller.warningReset(athr_offw_1);
- if (getprop("/it-autoflight/output/athr-warning") == 2) {
- setprop("/it-autoflight/output/athr-warning", 0);
- setprop("/ECAM/Lower/light/clr", 0);
- setprop("/ECAM/warnings/master-caution-light", 0);
- }
- }
-
- if ((athr_lim.clearFlag == 0) and getprop("/it-autoflight/output/athr") == 1 and ((getprop("/systems/thrust/eng-out") != 1 and (getprop("/systems/thrust/state1") == "MAN" or getprop("/systems/thrust/state2") == "MAN")) or (getprop("/systems/thrust/eng-out") == 1 and (getprop("/systems/thrust/state1") == "MAN" or getprop("/systems/thrust/state2") == "MAN" or (getprop("/systems/thrust/state1") == "MAN THR" and getprop("/controls/engines/engine[0]/throttle-pos") <= 0.83) or (getprop("/systems/thrust/state2") == "MAN THR" and getprop("/controls/engines/engine[0]/throttle-pos") <= 0.83)))) and (phaseVar >= 5 and phaseVar <= 7)) {
- athr_lim.active = 1;
- athr_lim_1.active = 1;
- } else {
- ECAM_controller.warningReset(athr_lim);
- ECAM_controller.warningReset(athr_lim_1);
}
if (!systems.cargoTestBtn.getBoolValue()) {
@@ -784,21 +749,21 @@ var messages_priority_3 = func {
cargoSmokeFwd.active = 1;
} elsif (cargoSmokeFwd.clearFlag == 1 or systems.cargoTestBtnOff.getBoolValue()) {
ECAM_controller.warningReset(cargoSmokeFwd);
- cargoSmokeFwd.hasSubmsg = 1;
+ cargoSmokeFwd.isMainMsg = 1;
}
if (cargoSmokeFwdAgent.clearFlag == 0 and cargoSmokeFwd.active == 1 and !getprop("/systems/fire/cargo/disch")) {
cargoSmokeFwdAgent.active = 1;
} else {
ECAM_controller.warningReset(cargoSmokeFwdAgent);
- cargoSmokeFwd.hasSubmsg = 0;
+ cargoSmokeFwd.isMainMsg = 0;
}
if (cargoSmokeAft.clearFlag == 0 and systems.aftCargoFireWarn.getBoolValue() and (phaseVar <= 3 or phaseVar >= 9 or phaseVar == 6)) {
cargoSmokeAft.active = 1;
} elsif (cargoSmokeAft.clearFlag == 1 or systems.cargoTestBtnOff.getBoolValue()) {
ECAM_controller.warningReset(cargoSmokeAft);
- cargoSmokeAft.hasSubmsg = 1;
+ cargoSmokeAft.isMainMsg = 1;
systems.cargoTestBtnOff.setBoolValue(0);
}
@@ -806,7 +771,7 @@ var messages_priority_3 = func {
cargoSmokeAftAgent.active = 1;
} else {
ECAM_controller.warningReset(cargoSmokeAftAgent);
- cargoSmokeAft.hasSubmsg = 0;
+ cargoSmokeAft.isMainMsg = 0;
}
} else {
if (systems.aftCargoFireWarn.getBoolValue()) {
@@ -850,7 +815,7 @@ var messages_priority_3 = func {
}
if (!(getprop("/systems/electrical/some-electric-thingie/generator-1-reset") and getprop("/systems/electrical/some-electric-thingie/generator-2-reset")) and emerconfigGen.clearFlag == 0) {
- emerconfigGen.active = 1;
+ emerconfigGen.active = 1; # EGEN12R TRUE
} else {
ECAM_controller.warningReset(emerconfigGen);
}
@@ -862,7 +827,7 @@ var messages_priority_3 = func {
} else {
ECAM_controller.warningReset(emerconfigBusTie);
}
- emerconfigGen3.active = 1;
+ emerconfigGen3.active = 1; # EGENRESET TRUE
} else {
ECAM_controller.warningReset(emerconfigGen2);
ECAM_controller.warningReset(emerconfigBusTie);
@@ -1088,6 +1053,37 @@ var messages_priority_2 = func {
ECAM_controller.warningReset(acBusEssShedAtc);
}
+ if ((athr_offw.clearFlag == 0) and athrWarn.getValue() == 2 and phaseVar != 4 and phaseVar != 8 and phaseVar != 10) {
+ athr_offw.active = 1;
+ athr_offw_1.active = 1;
+ } else {
+ ECAM_controller.warningReset(athr_offw);
+ ECAM_controller.warningReset(athr_offw_1);
+ }
+
+ if ((athr_lock.clearFlag == 0) and phaseVar >= 5 and phaseVar <= 7 and getprop("/systems/thrust/thr-locked-alert") == 1) {
+ if (getprop("/systems/thrust/thr-locked-flash") == 0) {
+ athr_lock.msg = " ";
+ } else {
+ athr_lock.msg = msgSave
+ }
+ athr_lock.active = 1;
+ athr_lock_1.active = 1;
+ } else {
+ ECAM_controller.warningReset(athr_lock);
+ ECAM_controller.warningReset(athr_lock_1);
+ }
+
+
+ if ((athr_lim.clearFlag == 0) and getprop("/it-autoflight/output/athr") == 1 and ((getprop("/systems/thrust/eng-out") != 1 and (getprop("/systems/thrust/state1") == "MAN" or getprop("/systems/thrust/state2") == "MAN")) or (getprop("/systems/thrust/eng-out") == 1 and (getprop("/systems/thrust/state1") == "MAN" or getprop("/systems/thrust/state2") == "MAN" or (getprop("/systems/thrust/state1") == "MAN THR" and getprop("/controls/engines/engine[0]/throttle-pos") <= 0.83) or (getprop("/systems/thrust/state2") == "MAN THR" and getprop("/controls/engines/engine[0]/throttle-pos") <= 0.83)))) and (phaseVar >= 5 and phaseVar <= 7)) {
+ athr_lim.active = 1;
+ athr_lim_1.active = 1;
+ } else {
+ ECAM_controller.warningReset(athr_lim);
+ ECAM_controller.warningReset(athr_lim_1);
+ }
+
+
if (getprop("/instrumentation/tcas/serviceable") == 0 and phaseVar != 3 and phaseVar != 4 and phaseVar != 7 and systems.ELEC.Bus.ac1.getValue() and pts.Instrumentation.TCAS.Inputs.mode.getValue() != 1 and tcasFault.clearFlag == 0) {
tcasFault.active = 1;
} else {
@@ -1123,14 +1119,14 @@ var messages_priority_2 = func {
apuEmerShutdown.active = 1;
} elsif (apuEmerShutdown.clearFlag == 1) {
ECAM_controller.warningReset(apuEmerShutdown);
- apuEmerShutdown.hasSubmsg = 1;
+ apuEmerShutdown.isMainMsg = 1;
}
if (apuEmerShutdownMast.clearFlag == 0 and getprop("/controls/APU/master") and apuEmerShutdown.active == 1) {
apuEmerShutdownMast.active = 1;
} else {
ECAM_controller.warningReset(apuEmerShutdownMast);
- apuEmerShutdown.hasSubmsg = 0;
+ apuEmerShutdown.isMainMsg = 0;
}
if (eng1FireDetFault.clearFlag == 0 and (systems.engFireDetectorUnits.vector[0].condition == 0 or (systems.engFireDetectorUnits.vector[0].loopOne == 9 and systems.engFireDetectorUnits.vector[0].loopTwo == 9 and systems.eng1Inop.getBoolValue())) and (phaseVar == 6 or phaseVar >= 9 or phaseVar <= 2)) {
@@ -1362,7 +1358,7 @@ var messages_config_memo = func {
setprop("/ECAM/ldg-memo-2200-set", 0);
}
- if (phaseVar >= 6 and phaseVar <= 8) {
+ if (phaseVar != 6 and phaseVar != 7 and phaseVar != 8) {
setprop("/ECAM/ldg-memo-2200-reset", 1);
} else {
setprop("/ECAM/ldg-memo-2200-reset", 0);
@@ -1389,6 +1385,39 @@ var messages_memo = func {
refuelg.active = 0;
}
+ if ((phaseVar == 1 or phaseVar == 2) and toMemoLine1.active != 1 and ldgMemoLine1.active != 1 and (systems.ADIRSnew.ADIRunits[0].inAlign == 1 or systems.ADIRSnew.ADIRunits[1].inAlign == 1 or systems.ADIRSnew.ADIRunits[2].inAlign == 1)) {
+ irs_in_align.active = 1;
+ if (getprop("/ECAM/phases/timer/eng1or2-output")) {
+ irs_in_align.colour = "a";
+ } else {
+ irs_in_align.colour = "g";
+ }
+
+ timeNow = pts.Sim.Time.elapsedSec.getValue();
+ numberMinutes = math.round(math.max(systems.ADIRSnew.ADIRunits[0]._alignTime - timeNow, systems.ADIRSnew.ADIRunits[1]._alignTime - timeNow, systems.ADIRSnew.ADIRunits[2]._alignTime - timeNow) / 60);
+
+ if (numberMinutes >= 7) {
+ irs_in_align.msg = "IRS IN ALIGN > 7 MN";
+ } elsif (numberMinutes >= 1) {
+ irs_in_align.msg = "IRS IN ALIGN " ~ numberMinutes ~ " MN";
+ } else {
+ irs_in_align.msg = "IRS IN ALIGN";
+ }
+ } else {
+ if (irs_in_align.active and !timer10secIRS) {
+ timer10secIRS = 1;
+ irs_in_align.msg = "IRS ALIGNED";
+ settimer(func() {
+ irs_in_align.active = 0;
+ irs_in_align.msg = "IRS IN ALIGN";
+ timer10secIRS = 0;
+ }, 10);
+ } elsif (!timer10secIRS) {
+ irs_in_align.active = 0;
+ irs_in_align.msg = "IRS IN ALIGN";
+ }
+ }
+
if (getprop("/controls/flight/speedbrake-arm") == 1 and toMemoLine1.active != 1 and ldgMemoLine1.active != 1) {
gnd_splrs.active = 1;
} else {
@@ -1447,7 +1476,7 @@ var messages_right_memo = func {
ldg_inhibit.active = 0;
}
- if ((getprop("/gear/gear[1]/wow") == 0) and (getprop("/systems/fire/engine1/warning-active") == 1 or getprop("/systems/fire/engine2/warning-active") == 1 or getprop("/systems/fire/apu/warning-active") == 1 or getprop("/systems/failures/cargo-aft-fire") == 1 or getprop("/systems/failures/cargo-fwd-fire") == 1) or (((getprop("/systems/hydraulic/green-psi") < 1500 and getprop("/engines/engine[0]/state") == 3) and (getprop("/systems/hydraulic/yellow-psi") < 1500 and getprop("/engines/engine[1]/state") == 3)) or ((getprop("/systems/hydraulic/green-psi") < 1500 or getprop("/systems/hydraulic/yellow-psi") < 1500) and getprop("/engines/engine[0]/state") == 3 and getprop("/engines/engine[1]/state") == 3) and phaseVar >= 3 and phaseVar <= 8)) {
+ if ((getprop("/gear/gear[1]/wow") == 0) and (getprop("/systems/electrical/some-electric-thingie/emer-elec-config") or getprop("/systems/fire/engine1/warning-active") == 1 or getprop("/systems/fire/engine2/warning-active") == 1 or getprop("/systems/fire/apu/warning-active") == 1 or getprop("/systems/failures/cargo-aft-fire") == 1 or getprop("/systems/failures/cargo-fwd-fire") == 1) or (((getprop("/systems/hydraulic/green-psi") < 1500 and getprop("/engines/engine[0]/state") == 3) and (getprop("/systems/hydraulic/yellow-psi") < 1500 and getprop("/engines/engine[1]/state") == 3)) or ((getprop("/systems/hydraulic/green-psi") < 1500 or getprop("/systems/hydraulic/yellow-psi") < 1500) and getprop("/engines/engine[0]/state") == 3 and getprop("/engines/engine[1]/state") == 3) and phaseVar >= 3 and phaseVar <= 8)) {
# todo: emer elec
land_asap_r.active = 1;
} else {
diff --git a/Nasal/ECAM/ECAM-main.nas b/Nasal/ECAM/ECAM-main.nas
index 61334c2f..5b286f65 100644
--- a/Nasal/ECAM/ECAM-main.nas
+++ b/Nasal/ECAM/ECAM-main.nas
@@ -230,7 +230,7 @@ var SystemDisplay = {
if (APUMaster == 1 and me.APU10sec != 1) {
me.autoCall("apu");
- me.fctl20sec = 9;
+ me.fctl20sec = 0;
if (me.APU10sec == 9 and APURPM >= 95.0) {
me.APU10sec = 0;
@@ -242,7 +242,7 @@ var SystemDisplay = {
}
} elsif (engModeSel == 0 or engModeSel == 2 or (engModeSel == 1 and me.eng10sec == 0)) {
me.autoCall("eng");
- me.fctl20sec = 9;
+ me.fctl20sec = 0;
if (me.eng10sec == 9 and engModeSel == 1) {
me.eng10sec = 0;
@@ -254,7 +254,9 @@ var SystemDisplay = {
}
} else {
# Reset variables
- me.APU10sec = 9;
+ if (APUMaster == 0) {
+ me.APU10sec = 9;
+ }
me.eng10sec = 9;
# Phase logic
@@ -322,15 +324,17 @@ var ECAMControlPanel = {
},
clrBtn: func() {
me.lightOff("clr");
- if (athrWarnNode.getValue == 2) {
- athrWarnNode.setValue(0);
- return;
- }
+
if (apWarnNode.getValue() == 2) {
apWarnNode.setValue(0);
return;
}
+ if (athrWarnNode.getValue() == 2) {
+ athrWarnNode.setValue(0);
+ return;
+ }
+
if (SystemDisplay.manShownPage) {
me.lightOff(SystemDisplay.page);
SystemDisplay.manShownPage = 0;
diff --git a/Nasal/ECAM/ECAM-messages.nas b/Nasal/ECAM/ECAM-messages.nas
index ad253f08..3b1d2fc8 100644
--- a/Nasal/ECAM/ECAM-messages.nas
+++ b/Nasal/ECAM/ECAM-messages.nas
@@ -13,13 +13,13 @@ var warnings = std.Vector.new([
var stall = warning.new(msg: "", aural: 2),
var flap_not_zero = warning.new(msg: "F/CTL FLAP LVR NOT ZERO", colour: "r", aural: 0, light: 0),
- var overspeed = warning.new(msg: "OVER SPEED", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var overspeed = warning.new(msg: "OVER SPEED", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var overspeedVMO = warning.new(msg: "-VMO/MMO.......350 /.82", colour: "r"),
var overspeedGear = warning.new(msg: "-VLE...........280 /.67", colour: "r"),
var overspeedFlap = warning.new(msg: "-VFE................XXX", colour: "r"),
# DUAL ENG FAIL
- var dualFail = warning.new(msg: "ENG DUAL FAILURE", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var dualFail = warning.new(msg: "ENG DUAL FAILURE", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var dualFailModeSel = warning.new(msg: " -ENG MODE SEL.......IGN", colour: "c"),
var dualFailLevers = warning.new(msg: " -THR LEVERS........IDLE", colour: "c"),
var dualFailRelightSPD = warning.new(msg: " OPTIMUM RELIGHT SPD.280", colour: "c"),
@@ -27,41 +27,41 @@ var warnings = std.Vector.new([
var dualFailElec = warning.new(msg: " -EMER ELEC PWR...MAN ON", colour: "c"),
var dualFailRadio = warning.new(msg: " -VHF1/ATC1..........USE", colour: "c"),
var dualFailFAC = warning.new(msg: " -FAC 1......OFF THEN ON", colour: "c"),
- var dualFailRelight = warning.new(msg: "•IF NO RELIGHT AFTER 30S", colour: "w", hasSubmsg: 1),
+ var dualFailRelight = warning.new(msg: "•IF NO RELIGHT AFTER 30S", colour: "w", isMainMsg: 1),
var dualFailMasters = warning.new(msg: " -ENG MASTERS.OFF 30S/ON", colour: "c"),
- var dualFailSuccess = warning.new(msg: " •IF UNSUCCESSFUL : ", colour: "w", hasSubmsg: 1),
+ var dualFailSuccess = warning.new(msg: " •IF UNSUCCESSFUL : ", colour: "w", isMainMsg: 1),
var dualFailAPU = warning.new(msg: " -APU (IF AVAIL)...START", colour: "c"),
var dualFailAPUwing = warning.new(msg: " -WING ANTI ICE......OFF", colour: "c"),
var dualFailAPUbleed = warning.new(msg: " -APU BLEED...........ON", colour: "c"),
var dualFailMastersAPU = warning.new(msg: " -ENG MASTERS.OFF 30S/ON", colour: "c"),
var dualFailSPDGD = warning.new(msg: " OPTIMUM SPEED.....G DOT", colour: "c"),
- var dualFailAPPR = warning.new(msg: " •EARLY IN APPR : ", colour: "w", hasSubmsg: 1),
+ var dualFailAPPR = warning.new(msg: " •EARLY IN APPR : ", colour: "w", isMainMsg: 1),
var dualFailcabin = warning.new(msg: " -CAB SECURE.......ORDER", colour: "c"),
var dualFailrudd = warning.new(msg: " -USE RUDDER WITH CARE ", colour: "c"),
var dualFailflap = warning.new(msg: " -FOR LDG.....USE FLAP 3", colour: "c"),
- var dualFail5000 = warning.new(msg: " •AT 5000 FT AGL : ", colour: "w", hasSubmsg: 1),
+ var dualFail5000 = warning.new(msg: " •AT 5000 FT AGL : ", colour: "w", isMainMsg: 1),
var dualFailgear = warning.new(msg: " -L/G.........GRVTY EXTN", colour: "c"),
var dualFailfinalspeed = warning.new(msg: " TARGET SPEED.....150 KT", colour: "c"),
- var dualFailtouch = warning.new(msg: " •AT TOUCH DOWN : ", colour: "w", hasSubmsg: 1),
+ var dualFailtouch = warning.new(msg: " •AT TOUCH DOWN : ", colour: "w", isMainMsg: 1),
var dualFailmasteroff = warning.new(msg: " -ENG MASTERS........OFF", colour: "c"),
var dualFailapuoff = warning.new(msg: " -APU MASTER SW......OFF", colour: "c"),
var dualFailevac = warning.new(msg: " -EVAC..........INITIATE", colour: "c"),
var dualFailbatt = warning.new(msg: " -BAT 1+2............OFF", colour: "c"),
# ENG 1 FIRE (flight)
- var eng1Fire = warning.new(msg: "ENG 1 FIRE", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var eng1Fire = warning.new(msg: "ENG 1 FIRE", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var eng1FireFllever = warning.new(msg: " -THR LEVER 1.......IDLE", colour: "c"),
var eng1FireFlmaster = warning.new(msg: " -ENG MASTER 1.......OFF", colour: "c"),
var eng1FireFlPB = warning.new(msg: " -ENG 1 FIRE P/B....PUSH", colour: "c"),
var eng1FireFlAgent1Timer = warning.new(msg: " -AGENT 1 AFT 10 S.DISCH", colour: "w"),
var eng1FireFlAgent1 = warning.new(msg: " -AGENT 1..........DISCH", colour: "c"),
var eng1FireFlATC = warning.new(msg: " -ATC.............NOTIFY", colour: "c"),
- var eng1FireFl30Sec = warning.new(msg: " •IF FIRE AFTER 30 S:", colour: "w", hasSubmsg: 1),
+ var eng1FireFl30Sec = warning.new(msg: " •IF FIRE AFTER 30 S:", colour: "w", isMainMsg: 1),
var eng1FireFlAgent2 = warning.new(msg: " -AGENT 2..........DISCH", colour: "c"),
# ENG 1 FIRE (ground)
var eng1FireGnlever = warning.new(msg: " -THR LEVERS........IDLE", colour: "c"),
- var eng1FireGnstopped = warning.new(msg: " •WHEN A/C IS STOPPED:", colour: "w", hasSubmsg: 1),
+ var eng1FireGnstopped = warning.new(msg: " •WHEN A/C IS STOPPED:", colour: "w", isMainMsg: 1),
var eng1FireGnparkbrk = warning.new(msg: " -PARKING BRK.........ON", colour: "c"),
var eng1FireGnmaster = warning.new(msg: " -ENG MASTER 1.......OFF", colour: "c"),
var eng1FireGnPB = warning.new(msg: " -ENG 1 FIRE P/B....PUSH", colour: "c"),
@@ -70,25 +70,25 @@ var warnings = std.Vector.new([
var eng1FireGnmaster2 = warning.new(msg: " -ENG MASTER 2.......OFF", colour: "c"),
var eng1FireGnATC = warning.new(msg: " -ATC.............NOTIFY", colour: "c"),
var eng1FireGncrew = warning.new(msg: " -CABIN CREW.......ALERT", colour: "c"),
- var eng1FireGnevac = warning.new(msg: " •IF EVAC RQRD:", colour: "w", hasSubmsg: 1),
+ var eng1FireGnevac = warning.new(msg: " •IF EVAC RQRD:", colour: "w", isMainMsg: 1),
var eng1FireGnevacSw = warning.new(msg: " -EVAC COMMAND........ON", colour: "c"),
var eng1FireGnevacApu = warning.new(msg: " -APU MASTER SW......OFF", colour: "c"),
var eng1FireGnevacBat = warning.new(msg: " -BAT 1+2............OFF", colour: "c"),
# ENG 2 FIRE (flight)
- var eng2Fire = warning.new(msg: "ENG 2 FIRE", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var eng2Fire = warning.new(msg: "ENG 2 FIRE", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var eng2FireFllever = warning.new(msg: " -THR LEVER 2.......IDLE", colour: "c"),
var eng2FireFlmaster = warning.new(msg: " -ENG MASTER 2.......OFF", colour: "c"),
var eng2FireFlPB = warning.new(msg: " -ENG 2 FIRE P/B....PUSH", colour: "c"),
var eng2FireFlAgent1Timer = warning.new(msg: " -AGENT 1 AFT 10 S.DISCH", colour: "w"),
var eng2FireFlAgent1 = warning.new(msg: " -AGENT 1..........DISCH", colour: "c"),
var eng2FireFlATC = warning.new(msg: " -ATC.............NOTIFY", colour: "c"),
- var eng2FireFl30Sec = warning.new(msg: " •IF FIRE AFTER 30 S:", colour: "w", hasSubmsg: 1),
+ var eng2FireFl30Sec = warning.new(msg: " •IF FIRE AFTER 30 S:", colour: "w", isMainMsg: 1),
var eng2FireFlAgent2 = warning.new(msg: " -AGENT 2..........DISCH", colour: "c"),
# ENG 2 FIRE (ground)
var eng2FireGnlever = warning.new(msg: " -THR LEVERS........IDLE", colour: "c"),
- var eng2FireGnstopped = warning.new(msg: " •WHEN A/C IS STOPPED:", colour: "w", hasSubmsg: 1),
+ var eng2FireGnstopped = warning.new(msg: " •WHEN A/C IS STOPPED:", colour: "w", isMainMsg: 1),
var eng2FireGnparkbrk = warning.new(msg: " -PARKING BRK.........ON", colour: "c"),
var eng2FireGnmaster = warning.new(msg: " -ENG MASTER 2.......OFF", colour: "c"),
var eng2FireGnPB = warning.new(msg: " -ENG 2 FIRE P/B....PUSH", colour: "c"),
@@ -97,13 +97,13 @@ var warnings = std.Vector.new([
var eng2FireGnmaster2 = warning.new(msg: " -ENG MASTER 1.......OFF", colour: "c"),
var eng2FireGnATC = warning.new(msg: " -ATC.............NOTIFY", colour: "c"),
var eng2FireGncrew = warning.new(msg: " -CABIN CREW.......ALERT", colour: "c"),
- var eng2FireGnevac = warning.new(msg: " •IF EVAC RQRD:", colour: "w", hasSubmsg: 1),
+ var eng2FireGnevac = warning.new(msg: " •IF EVAC RQRD:", colour: "w", isMainMsg: 1),
var eng2FireGnevacSw = warning.new(msg: " -EVAC COMMAND........ON", colour: "c"),
var eng2FireGnevacApu = warning.new(msg: " -APU MASTER SW......OFF", colour: "c"),
var eng2FireGnevacBat = warning.new(msg: " -BAT 1+2............OFF", colour: "c"),
# APU FIRE
- var apuFire = warning.new(msg: "APU FIRE ", colour: "r", aural: 0, light: 0, hasSubmsg: 1, sdPage: "apu"),
+ var apuFire = warning.new(msg: "APU FIRE ", colour: "r", aural: 0, light: 0, isMainMsg: 1, sdPage: "apu"),
var apuFirePB = warning.new(msg: " -APU FIRE P/B......PUSH", colour: "c"),
var apuFireAgentTimer = warning.new(msg: " -AGENT AFT 10 S...DISCH", colour: "c"),
var apuFireAgent = warning.new(msg: " -AGENT............DISCH", colour: "c"),
@@ -122,23 +122,17 @@ var warnings = std.Vector.new([
var rud_trim_config_1 = warning.new(msg: " NOT IN T.O. RANGE", colour: "r", aural: 0, light: 0),
var park_brk_config = warning.new(msg: "CONFIG PARK BRK ON", colour: "r", aural: 0, light: 0),
- # Autopilot
- var ap_offw = warning.new(msg: "AUTO FLT AP OFF", colour: "r", light: 0),
- var athr_offw = warning.new(msg: "AUTO FLT A/THR OFF", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
- var athr_offw_1 = warning.new(msg: "-THR LEVERS........MOVE", colour: "c"),
- var athr_lock = warning.new(msg: "ENG THRUST LOCKED", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
- var athr_lock_1 = warning.new(msg: "-THR LEVERS........MOVE", colour: "c"),
- var athr_lim = warning.new(msg: "AUTO FLT A/THR LIMITED", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
- var athr_lim_1 = warning.new(msg: "-THR LEVERS........MOVE", colour: "c"),
+ # Autopilot off involuntary
+ var ap_offw = warning.new(msg: "AUTO FLT AP OFF", colour: "r", light: 0, isMainMsg: 1),
# Cargo smoke
- var cargoSmokeFwd = warning.new(msg: "SMOKE FWD CARGO SMOKE", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var cargoSmokeFwd = warning.new(msg: "SMOKE FWD CARGO SMOKE", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var cargoSmokeFwdAgent = warning.new(msg: "-AGENT............DISCH", colour: "c"),
- var cargoSmokeAft = warning.new(msg: "SMOKE AFT CARGO SMOKE", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var cargoSmokeAft = warning.new(msg: "SMOKE AFT CARGO SMOKE", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var cargoSmokeAftAgent = warning.new(msg: "-AGENT............DISCH", colour: "c"),
# ESS Bus on Bat
- var essBusOnBat = warning.new(msg: "ELEC ESS BUSES ON BAT", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var essBusOnBat = warning.new(msg: "ELEC ESS BUSES ON BAT", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var essBusOnBatLGUplock = warning.new(msg: " •WHEN L/G UPLOCKED :", colour: "w"),
var essBusOnBatManOn = warning.new(msg: "-EMER ELEC PWR...MAN ON", colour: "c"),
var essBusOnBatRetract = warning.new(msg: " •IF L/G RETRACT FAULT:", colour: "w"),
@@ -147,7 +141,7 @@ var warnings = std.Vector.new([
var essBusOnBatManOn2 = warning.new(msg: "-EMER ELEC PWR...MAN ON", colour: "c"),
# Emer Config
- var emerconfig = warning.new(msg: "ELEC EMER CONFIG", colour: "r", aural: 0, light: 0, hasSubmsg: 1),
+ var emerconfig = warning.new(msg: "ELEC EMER CONFIG", colour: "r", aural: 0, light: 0, isMainMsg: 1),
var emerconfigMinRat = warning.new(msg: "MIN RAT SPD......140 KT", colour: "c"),
var emerconfigGen = warning.new(msg: "-GEN 1+2....OFF THEN ON", colour: "c"),
var emerconfigGen2 = warning.new(msg: " •IF UNSUCCESSFUL :", colour: "w"),
@@ -168,11 +162,11 @@ var warnings = std.Vector.new([
var emerconfigMaxSpeed = warning.new(msg: " MAX SPEED........320 KT", colour: "c"),
# DC EMER CONFIG
- var dcEmerconfig = warning.new(msg: "ELEC DC EMER CONFIG", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var dcEmerconfig = warning.new(msg: "ELEC DC EMER CONFIG", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var dcEmerconfigManOn = warning.new(msg: " -EMER ELEC PWR...MAN ON", colour: "c"),
# DC BUS 1 OR 2 FAULT
- var dcBus12Fault = warning.new(msg: "ELEC DC BUS 1+2 FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var dcBus12Fault = warning.new(msg: "ELEC DC BUS 1+2 FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var dcBus12FaultBlower = warning.new(msg: " -BLOWER............OVRD", colour: "c"),
var dcBus12FaultExtract = warning.new(msg: " -EXTRACT...........OVRD", colour: "c"),
var dcBus12FaultBaroRef = warning.new(msg: " -BARO REF.........CHECK", colour: "c"),
@@ -180,78 +174,86 @@ var warnings = std.Vector.new([
var dcBus12FaultBrking = warning.new(msg: " MAX BRK........1000 PSI", colour: "c"),
# AC ESS BUS FAULT
- var AcBusEssFault = warning.new(msg: "ELEC AC ESS BUS FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var AcBusEssFault = warning.new(msg: "ELEC AC ESS BUS FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var AcBusEssFaultFeed = warning.new(msg: " -AC ESS FEED.......ALTN", colour: "c"),
var AcBusEssFaultAtc = warning.new(msg: " -ATC..............SYS 2", colour: "c"),
# AC BUS 1 FAULT
- var AcBus1Fault = warning.new(msg: "ELEC AC BUS 1 FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var AcBus1Fault = warning.new(msg: "ELEC AC BUS 1 FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var AcBus1FaultBlower = warning.new(msg: " -BLOWER............OVRD", colour: "c"),
# DC ESS BUS FAULT
- var DcEssBusFault = warning.new(msg: "ELEC DC ESS BUS FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var DcEssBusFault = warning.new(msg: "ELEC DC ESS BUS FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var DcEssBusFaultRadio = warning.new(msg: " -VHF 2 OR 3.........USE", colour: "c"),
var DcEssBusFaultRadio2 = warning.new(msg: " -AUDIO SWTG......SELECT", colour: "c"),
var DcEssBusFaultBaro = warning.new(msg: " -BARO REF.........CHECK", colour: "c"),
var DcEssBusFaultGPWS = warning.new(msg: " -GPWS...............OFF", colour: "c"),
# AC BUS 2 FAULT
- var AcBus2Fault = warning.new(msg: "ELEC AC BUS 2 FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var AcBus2Fault = warning.new(msg: "ELEC AC BUS 2 FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var AcBus2FaultExtract = warning.new(msg: " -EXTRACT...........OVRD", colour: "c"),
# DC BUS 1 FAULT
- var dcBus1Fault = warning.new(msg: "ELEC DC BUS 1 FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var dcBus1Fault = warning.new(msg: "ELEC DC BUS 1 FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var dcBus1FaultBlower = warning.new(msg: " -BLOWER............OVRD", colour: "c"),
var dcBus1FaultExtract = warning.new(msg: " -EXTRACT...........OVRD", colour: "c"),
# DC BUS 2 FAULT
- var dcBus2Fault = warning.new(msg: "ELEC DC BUS 2 FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var dcBus2Fault = warning.new(msg: "ELEC DC BUS 2 FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var dcBus2FaultAirData = warning.new(msg: " -AIR DATA SWTG......F/O", colour: "c"),
var dcBus2FaultBaro = warning.new(msg: " -BARO REF.........CHECK", colour: "c"),
# DC BAT BUS FAULT
- var dcBusBatFault = warning.new(msg: "ELEC DC BAT BUS FAULT", colour: "a", aural: 1, light: 1),
+ var dcBusBatFault = warning.new(msg: "ELEC DC BAT BUS FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
# DC ESS BUS SHED
- var dcBusEssShed = warning.new(msg: "ELEC DC ESS BUS SHED", colour: "a", aural: 1, light: 1),
+ var dcBusEssShed = warning.new(msg: "ELEC DC ESS BUS SHED", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var dcBusEssShedExtract = warning.new(msg: " -EXTRACT...........OVRD", colour: "c"),
var dcBusEssShedIcing = warning.new(msg: " AVOID ICING CONDITIONS", colour: "c"),
# AC ESS BUS SHED
- var acBusEssShed = warning.new(msg: "ELEC DC ESS BUS SHED", colour: "a", aural: 1, light: 1),
+ var acBusEssShed = warning.new(msg: "ELEC DC ESS BUS SHED", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var acBusEssShedAtc = warning.new(msg: " -ATC..............SYS 2", colour: "c"),
+ # Autothrust
+ var athr_offw = warning.new(msg: "AUTO FLT A/THR OFF", colour: "a", aural: 1, light: 1, isMainMsg: 1),
+ var athr_offw_1 = warning.new(msg: "-THR LEVERS........MOVE", colour: "c"),
+ var athr_lock = warning.new(msg: "ENG THRUST LOCKED", colour: "a", aural: 1, light: 1, isMainMsg: 1),
+ var athr_lock_1 = warning.new(msg: "-THR LEVERS........MOVE", colour: "c"),
+ var athr_lim = warning.new(msg: "AUTO FLT A/THR LIMITED", colour: "a", aural: 1, light: 1, isMainMsg: 1),
+ var athr_lim_1 = warning.new(msg: "-THR LEVERS........MOVE", colour: "c"),
+
# TCAS FAULT
- var tcasFault = warning.new(msg: "NAV TCAS FAULT", colour: "a", aural: 1, light: 1),
+ var tcasFault = warning.new(msg: "NAV TCAS FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
# FCU fault
- var fcuFault = warning.new(msg: "AUTO FLT FCU 1+2 FAULT", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var fcuFault = warning.new(msg: "AUTO FLT FCU 1+2 FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var fcuFaultBaro = warning.new(msg: " -PFD BARO REF: STD ONLY", colour: "c"),
- var fcuFault1 = warning.new(msg: "AUTO FLT FCU 1 FAULT", colour: "a", hasSubmsg: 1),
+ var fcuFault1 = warning.new(msg: "AUTO FLT FCU 1 FAULT", colour: "a", isMainMsg: 1),
var fcuFault1Baro = warning.new(msg: " -BARO REF.......X CHECK", colour: "c"),
- var fcuFault2 = warning.new(msg: "AUTO FLT FCU 2 FAULT", colour: "a", hasSubmsg: 1),
+ var fcuFault2 = warning.new(msg: "AUTO FLT FCU 2 FAULT", colour: "a", isMainMsg: 1),
var fcuFault2Baro = warning.new(msg: " -BARO REF.......X CHECK", colour: "c"),
# APU shutdown
- var apuEmerShutdown = warning.new(msg: "APU EMER SHUT DOWN", colour: "a", aural: 1, light: 1, hasSubmsg: 1),
+ var apuEmerShutdown = warning.new(msg: "APU EMER SHUT DOWN", colour: "a", aural: 1, light: 1, isMainMsg: 1),
var apuEmerShutdownMast = warning.new(msg: " -MASTER SW..........OFF", colour: "c"),
# FIRE det fault
- var eng1FireDetFault = warning.new(msg: "ENG 1 FIRE DET FAULT", colour: "a", aural: 1, light: 1),
- var eng1LoopAFault = warning.new(msg: "ENG 1 FIRE LOOP A FAULT", colour: "a"),
- var eng1LoopBFault = warning.new(msg: "ENG 1 FIRE LOOP B FAULT", colour: "a"),
- var eng2FireDetFault = warning.new(msg: "ENG 2 FIRE DET FAULT", colour: "a", aural: 1, light: 1),
- var eng2LoopAFault = warning.new(msg: "ENG 2 FIRE LOOP A FAULT", colour: "a"),
- var eng2LoopBFault = warning.new(msg: "ENG 2 FIRE LOOP B FAULT", colour: "a"),
- var apuFireDetFault = warning.new(msg: "APU FIRE DET FAULT", colour: "a", aural: 1, light: 1),
- var apuLoopAFault = warning.new(msg: "APU FIRE LOOP A FAULT", colour: "a"),
- var apuLoopBFault = warning.new(msg: "APU FIRE LOOP B FAULT", colour: "a"),
- var crgFwdFireDetFault = warning.new(msg: "FWD CRG DET FAULT", colour: "a"),
- var crgAftFireDetFault = warning.new(msg: "AFT CRG DET FAULT", colour: "a"),
+ var eng1FireDetFault = warning.new(msg: "ENG 1 FIRE DET FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
+ var eng1LoopAFault = warning.new(msg: "ENG 1 FIRE LOOP A FAULT", colour: "a", isMainMsg: 1),
+ var eng1LoopBFault = warning.new(msg: "ENG 1 FIRE LOOP B FAULT", colour: "a", isMainMsg: 1),
+ var eng2FireDetFault = warning.new(msg: "ENG 2 FIRE DET FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
+ var eng2LoopAFault = warning.new(msg: "ENG 2 FIRE LOOP A FAULT", colour: "a", isMainMsg: 1),
+ var eng2LoopBFault = warning.new(msg: "ENG 2 FIRE LOOP B FAULT", colour: "a", isMainMsg: 1),
+ var apuFireDetFault = warning.new(msg: "APU FIRE DET FAULT", colour: "a", aural: 1, light: 1, isMainMsg: 1),
+ var apuLoopAFault = warning.new(msg: "APU FIRE LOOP A FAULT", colour: "a", isMainMsg: 1),
+ var apuLoopBFault = warning.new(msg: "APU FIRE LOOP B FAULT", colour: "a", isMainMsg: 1),
+ var crgFwdFireDetFault = warning.new(msg: "FWD CRG DET FAULT", colour: "a", isMainMsg: 1),
+ var crgAftFireDetFault = warning.new(msg: "AFT CRG DET FAULT", colour: "a", isMainMsg: 1),
# Recall
- var recallNormal = warning.new(msg: " ", colour: "g", hasSubmsg: 1),
- var recallNormal1 = warning.new(msg: " ", colour: "g", hasSubmsg: 1),
- var recallNormal2 = warning.new(msg: " NORMAL", colour: "g", hasSubmsg: 1),
+ var recallNormal = warning.new(msg: " ", colour: "g", isMainMsg: 1),
+ var recallNormal1 = warning.new(msg: " ", colour: "g", isMainMsg: 1),
+ var recallNormal2 = warning.new(msg: " NORMAL", colour: "g", isMainMsg: 1),
]);
var configmemos = std.Vector.new([
@@ -270,7 +272,7 @@ var configmemos = std.Vector.new([
var leftmemos = std.Vector.new([
var company_alert = warning.new(msg: "COMPANY ALERT" ), # Not yet implemented, buzzer sound
var refuelg = warning.new(msg: "REFUELG" ),
- var irs_in_align = warning.new(msg: "IRS IN ALIGN" ), # Not yet implemented
+ var irs_in_align = warning.new(msg: "IRS IN ALIGN" ),
var gnd_splrs = warning.new(msg: "GND SPLRS ARMED" ),
var seatbelts = warning.new(msg: "SEAT BELTS" ),
var nosmoke = warning.new(msg: "NO SMOKING" ),
diff --git a/Nasal/FBW/it-fbw.nas b/Nasal/FBW/it-fbw.nas
index 4ea77502..b6f8f122 100644
--- a/Nasal/FBW/it-fbw.nas
+++ b/Nasal/FBW/it-fbw.nas
@@ -179,7 +179,7 @@ var update_loop = func {
FBW.Lights.elac2.setValue(1);
}
- if (sec1_sw and !sec1_fail and ac_ess >= 110) {
+ if (sec1_sw and !sec1_fail and dc_ess >= 25) {
setprop("/systems/fctl/sec1", 1);
setprop("/systems/failures/spoiler-l3", 0);
setprop("/systems/failures/spoiler-r3", 0);
@@ -193,7 +193,7 @@ var update_loop = func {
setprop("/systems/failures/spoiler-r4", 1);
}
- if (sec2_sw and !sec2_fail and ac_ess >= 110) {
+ if (sec2_sw and !sec2_fail and dc2 >= 25) {
setprop("/systems/fctl/sec2", 1);
setprop("/systems/failures/spoiler-l5", 0);
setprop("/systems/failures/spoiler-r5", 0);
@@ -203,7 +203,7 @@ var update_loop = func {
setprop("/systems/failures/spoiler-r5", 1);
}
- if (sec3_sw and !sec3_fail and ac_ess >= 110) {
+ if (sec3_sw and !sec3_fail and dc2 >= 25) {
setprop("/systems/fctl/sec3", 1);
setprop("/systems/failures/spoiler-l1", 0);
setprop("/systems/failures/spoiler-r1", 0);
@@ -269,15 +269,28 @@ var update_loop = func {
if (!elac1 and !elac2) {
if (law == 0) {
FBW.degradeLaw.setValue(1);
+ fcu.apOff("hard", 0);
+ fcu.athrOff("hard");
}
}
- if (ac_ess >= 110 and blue >= 1500 and green < 1500 and yellow < 1500) {
+ if (getprop("/systems/electrical/some-electric-thingie/emer-elec-config") == 1) {
+ if (law == 0) {
+ FBW.degradeLaw.setValue(1);
+ fcu.apOff("hard", 0);
+ fcu.athrOff("hard");
+ }
+ }
+ if ((blue >= 1500 and green < 1500 and yellow < 1500) or (blue < 1500 and green < 1500 and yellow >= 1500)) {
if (law == 0 or law == 1) {
FBW.degradeLaw.setValue(2);
+ fcu.apOff("hard", 0);
+ fcu.athrOff("hard");
}
- }
- if (ac_ess < 110 or (blue < 1500 and green < 1500 and yellow < 1500)) {
+ }
+ if (dc_ess < 25 and dc2 < 25) {
FBW.degradeLaw.setValue(3);
+ fcu.apOff("hard", 0);
+ fcu.athrOff("hard");
}
}
@@ -373,6 +386,7 @@ var fbw_loop = func {
if (FBW.activeLaw.getValue() != 0) {
if (getprop("/it-autoflight/output/ap1") == 1 or getprop("/it-autoflight/output/ap2") == 1) {
fcu.apOff("hard", 0);
+ fcu.athrOff("hard");
}
}
}
diff --git a/Nasal/FMGC/FCU.nas b/Nasal/FMGC/FCU.nas
index 03eee6f2..8f3ec0fc 100644
--- a/Nasal/FMGC/FCU.nas
+++ b/Nasal/FMGC/FCU.nas
@@ -34,6 +34,7 @@ var vertModeInput = props.globals.getNode("/it-autoflight/input/vert", 1);
var vsModeInput = props.globals.getNode("/it-autoflight/input/vs", 1);
var locArm = props.globals.getNode("/it-autoflight/output/loc-armed", 1);
var apprArm = props.globals.getNode("/it-autoflight/output/appr-armed", 1);
+var FCUworkingNode = props.globals.initNode("/FMGC/FCU-working", 0, "BOOL");
var FCU = {
elecSupply: "",
@@ -62,7 +63,7 @@ var FCUController = {
FCUworking: 0,
_init: 0,
init: func() {
- me.FCU1 = FCU.new(systems.ELEC.Bus.dcEssShed);
+ me.FCU1 = FCU.new(systems.ELEC.Bus.dcEss);
me.FCU2 = FCU.new(systems.ELEC.Bus.dc2);
me._init = 1;
},
@@ -73,10 +74,12 @@ var FCUController = {
me.FCU1.loop();
me.FCU2.loop();
- if (!me.FCU1.failed and !me.FCU2.failed) {
+ if (!me.FCU1.failed or !me.FCU2.failed) {
me.FCUworking = 1;
+ FCUworkingNode.setValue(1);
} else {
me.FCUworking = 0;
+ FCUworkingNode.setValue(0);
}
notification = nil;
@@ -97,16 +100,17 @@ var FCUController = {
me.FCU2.restore();
},
AP1: func() {
- if (me.FCUworking) {
+ if (me.FCUworking and fbw.FBW.activeLaw.getValue() == 0) {
if (!ap1.getBoolValue()) {
ap1Input.setValue(1);
+ libraries.apWarnNode.setValue(0);
} else {
apOff("hard", 1);
}
}
},
AP2: func() {
- if (me.FCUworking) {
+ if (me.FCUworking and fbw.FBW.activeLaw.getValue() == 0) {
if (!ap2.getBoolValue()) {
ap2Input.setValue(1);
} else {
@@ -115,8 +119,8 @@ var FCUController = {
}
},
ATHR: func() {
- if (me.FCUworking) {
- if (!athr.getBoolValue() and !pts.FMGC.CasCompare.rejectAll.getBoolValue()) {
+ if (me.FCUworking and !pts.FMGC.CasCompare.rejectAll.getBoolValue() and fbw.FBW.activeLaw.getValue() == 0) {
+ if (!athr.getBoolValue()) {
athrInput.setValue(1);
} else {
athrOff("hard");
@@ -150,8 +154,10 @@ var FCUController = {
setprop("/it-autoflight/sound/apoffsound", 0);
setprop("/it-autoflight/sound/apoffsound2", 0);
}
- setprop("/it-autoflight/output/ap-warning", 0);
- setprop("/ECAM/warnings/master-warning-light", 0);
+ if (getprop("/it-autoflight/output/ap-warning") != 0) {
+ setprop("/it-autoflight/output/ap-warning", 0);
+ setprop("/ECAM/warnings/master-warning-light", 0);
+ }
}
}
},
@@ -471,6 +477,10 @@ var updateActiveFMGC = func {
# Autopilot Disconnection
var apOff = func(type, side) {
+ if ((ap1Input.getValue() and (side == 1 or side == 0)) or (ap2Input.getValue() and (side == 2 or side == 0))) {
+ libraries.doApWarn(type);
+ }
+
if (side == 0) {
ap1Input.setValue(0);
ap2Input.setValue(0);
@@ -479,18 +489,17 @@ var apOff = func(type, side) {
} elsif (side == 2) {
ap2Input.setValue(0);
}
- libraries.doApWarn(type);
}
# Autothrust Disconnection
var athrOff = func(type) {
- if (type == "hard") {
- fadec.lockThr();
+ if (athrInput.getValue() == 1) {
+ if (type == "hard") {
+ fadec.lockThr();
+ }
+ athrInput.setValue(0);
+ libraries.doAthrWarn(type);
}
-
- athrInput.setValue(0);
-
- libraries.doAthrWarn(type);
}
# If the heading knob is turned while in nav mode, it will display heading for a period of time
diff --git a/Nasal/FMGC/FMGC-b.nas b/Nasal/FMGC/FMGC-b.nas
index f7b8be0e..c7b41368 100644
--- a/Nasal/FMGC/FMGC-b.nas
+++ b/Nasal/FMGC/FMGC-b.nas
@@ -367,8 +367,6 @@ var ITAF = {
# Misc
if (Output.ap1Temp == 1 or Output.ap2Temp == 1) { # Trip AP off
if (abs(Control.aileron.getValue()) >= 0.2 or abs(Control.elevator.getValue()) >= 0.2 or abs(Control.rudder.getValue()) >= 0.2) {
- me.ap1Master(0);
- me.ap2Master(0);
fcu.apOff("hard", 0);
}
}
diff --git a/Nasal/FMGC/FMGC.nas b/Nasal/FMGC/FMGC.nas
index 8b983ef8..92262827 100644
--- a/Nasal/FMGC/FMGC.nas
+++ b/Nasal/FMGC/FMGC.nas
@@ -266,6 +266,8 @@ var masterFMGC = maketimer(0.2, func {
if (getprop("/systems/navigation/adr/computation/overspeed-vfe-spd") != 1024) {
setprop("/FMGC/internal/maxspeed", getprop("/systems/navigation/adr/computation/overspeed-vfe-spd") - 4);
+ } elsif (pts.Gear.position[0].getValue() != 0 or pts.Gear.position[1].getValue() != 0 or pts.Gear.position[2].getValue() != 0) {
+ setprop("/FMGC/internal/maxspeed", 284);
} else {
setprop("/FMGC/internal/maxspeed", getprop("/it-fbw/speeds/vmo-mmo"));
}
diff --git a/Nasal/MCDU/INITA.nas b/Nasal/MCDU/INITA.nas
index 796c8dd2..82aed56b 100644
--- a/Nasal/MCDU/INITA.nas
+++ b/Nasal/MCDU/INITA.nas
@@ -96,9 +96,9 @@ var initInputA = func(key, i) {
}
}
} else if (key == "R3") {
- if (getprop("/controls/adirs/mcducbtn") == 0) {
- setprop("/controls/adirs/mcducbtn", 1);
- }
+ #if (getprop("/controls/adirs/mcducbtn") == 0) {
+ # setprop("/controls/adirs/mcducbtn", 1);
+ #}
} else if (key == "R6") {
if (scratchpad == "CLR") {
setprop("/FMGC/internal/tropo", 36090);
diff --git a/Nasal/Panels/atc.nas b/Nasal/Panels/atc.nas
index 167e568f..dbbb3114 100644
--- a/Nasal/Panels/atc.nas
+++ b/Nasal/Panels/atc.nas
@@ -28,7 +28,7 @@ var Transponder = {
ac1Node: props.globals.getNode("/systems/electrical/bus/ac-1", 1),
tcasNode: props.globals.getNode("/instrumentation/tcas/inputs/mode"),
aglNode: props.globals.getNode("/position/gear-agl-ft", 1),
- electricNode: props.globals.getNode("/systems/electrical/outputs/transponder", 1),
+ electricNode: props.globals.getNode("/systems/electrical/outputs/transponder", 1), # communicate to generic systems
new: func(elecSrc, ADIRS) {
var t = {parents:[Transponder]};
t.mode = 1;
diff --git a/Nasal/Sim/libraries.nas b/Nasal/Sim/libraries.nas
index 677bd04b..b301d605 100644
--- a/Nasal/Sim/libraries.nas
+++ b/Nasal/Sim/libraries.nas
@@ -233,7 +233,6 @@ var systemsLoop = maketimer(0.1, func {
systems.PNEU.loop();
systems.HYD.loop();
systems.FUEL.loop();
- systems.ADIRS.loop();
systems.ADIRSnew.loop();
libraries.ECAM.loop();
libraries.BUTTONS.update();
@@ -716,4 +715,33 @@ var APPanel = {
},
};
+var resetView = func() {
+ if (getprop("sim/current-view/view-number") == 0) {
+ if (getprop("/sim/rendering/headshake/enabled")) {
+ var _shakeFlag = 1;
+ setprop("/sim/rendering/headshake/enabled", 0);
+ } else {
+ var _shakeFlag = 0;
+ }
+
+ var hd = getprop("sim/current-view/heading-offset-deg");
+ var hd_t = 360;
+ if (hd < 180) {
+ hd_t = hd_t - 360;
+ }
+
+ interpolate("sim/current-view/field-of-view", 63, 0.66);
+ interpolate("sim/current-view/heading-offset-deg", hd_t,0.66);
+ interpolate("sim/current-view/pitch-offset-deg", -14.6,0.66);
+ interpolate("sim/current-view/roll-offset-deg", 0,0.66);
+ interpolate("sim/current-view/x-offset-m", -0.45, 0.66);
+ interpolate("sim/current-view/y-offset-m", 2.34, 0.66);
+ interpolate("sim/current-view/z-offset-m", -13.75, 0.66);
+
+ if (_shakeFlag) {
+ setprop("/sim/rendering/headshake/enabled", 1);
+ }
+ }
+}
+
setprop("/systems/acconfig/libraries-loaded", 1);
diff --git a/Nasal/Sim/property-tree-setup.nas b/Nasal/Sim/property-tree-setup.nas
index 99e2a9e3..741dd6cf 100644
--- a/Nasal/Sim/property-tree-setup.nas
+++ b/Nasal/Sim/property-tree-setup.nas
@@ -66,6 +66,7 @@ var FMGC = {
var Gear = {
compression: [props.globals.getNode("/gear/gear[0]/compression-norm"),props.globals.getNode("/gear/gear[1]/compression-norm"),props.globals.getNode("/gear/gear[2]/compression-norm")],
wow: [props.globals.getNode("/gear/gear[0]/wow"),props.globals.getNode("/gear/gear[1]/wow"),props.globals.getNode("/gear/gear[2]/wow")],
+ position: [props.globals.getNode("/gear/gear[0]/position-norm"),props.globals.getNode("/gear/gear[1]/position-norm"),props.globals.getNode("/gear/gear[2]/position-norm")],
};
var Instrumentation = {
@@ -105,8 +106,16 @@ var Options = {
eng: props.globals.getNode("/options/eng"),
};
+var Orientation = {
+ pitch: props.globals.getNode("/orientation/pitch-deg"),
+ roll: props.globals.getNode("/orientation/roll-deg"),
+ yaw: props.globals.getNode("/orientation/yaw-deg"),
+};
+
var Position = {
gearAglFt: props.globals.getNode("/position/gear-agl-ft"),
+ latitude: props.globals.getNode("/position/latitude-deg"),
+ longitude: props.globals.getNode("/position/longitude-deg"),
};
var Sim = {
@@ -119,16 +128,14 @@ var Sim = {
},
};
-var Orientation = {
- pitch: props.globals.getNode("/orientation/pitch-deg"),
- roll: props.globals.getNode("/orientation/roll-deg"),
- yaw: props.globals.getNode("/orientation/yaw-deg"),
-};
-
var PTSSystems = {
Thrust: {
flex: props.globals.getNode("/systems/thrust/lim-flex"),
},
};
+var Velocities = {
+ groundspeed: props.globals.getNode("/velocities/groundspeed-kt"),
+};
+
setprop("/systems/acconfig/property-tree-setup-loaded", 1);
diff --git a/Nasal/Systems/ADIRS/ADIRS.nas b/Nasal/Systems/ADIRS/ADIRS.nas
index e6fcbf93..63483834 100644
--- a/Nasal/Systems/ADIRS/ADIRS.nas
+++ b/Nasal/Systems/ADIRS/ADIRS.nas
@@ -2,35 +2,8 @@
# Joshua Davidson (Octal450)
# Copyright (c) 2019 Joshua Davidson (Octal450)
-
-var knob = 0;
-var roll = 0;
-var pitch = 0;
-var gs = 0;
-var ac1 = 0;
-var ac2 = 0;
-var dcbat = 0;
-var pwr_src = "XX";
-setprop("/controls/adirs/align-time", 600);
-
var ADIRS = {
init: func() {
- setprop("/controls/adirs/numm", 0);
- setprop("/instrumentation/adirs/ir[0]/aligned", 0);
- setprop("/instrumentation/adirs/ir[1]/aligned", 0);
- setprop("/instrumentation/adirs/ir[2]/aligned", 0);
- setprop("/controls/adirs/ir[0]/align", 0);
- setprop("/controls/adirs/ir[1]/align", 0);
- setprop("/controls/adirs/ir[2]/align", 0);
- setprop("/controls/adirs/ir[0]/time", 0);
- setprop("/controls/adirs/ir[1]/time", 0);
- setprop("/controls/adirs/ir[2]/time", 0);
- setprop("/controls/adirs/ir[0]/knob", 0);
- setprop("/controls/adirs/ir[1]/knob", 0);
- setprop("/controls/adirs/ir[2]/knob", 0);
- setprop("/controls/adirs/ir[0]/fault", 0);
- setprop("/controls/adirs/ir[1]/fault", 0);
- setprop("/controls/adirs/ir[2]/fault", 0);
setprop("/controls/adirs/mcdu/mode1", ""); # INVAL ALIGN NAV ATT or off (blank)
setprop("/controls/adirs/mcdu/mode2", "");
setprop("/controls/adirs/mcdu/mode3", "");
@@ -43,160 +16,4 @@ var ADIRS = {
setprop("/controls/adirs/mcdu/avgdrift3", "");
setprop("/controls/adirs/mcducbtn", 0);
},
- loop: func() {
- roll = getprop("/orientation/roll-deg");
- pitch = getprop("/orientation/pitch-deg");
- gs = getprop("/velocities/groundspeed-kt");
- ac1 = getprop("/systems/electrical/bus/ac-1");
- ac2 = getprop("/systems/electrical/bus/ac-2");
- dcbat = getprop("/systems/electrical/bus/dc-bat");
-
- if (getprop("/controls/adirs/skip") == 1) {
- if (getprop("/controls/adirs/align-time") != 5) {
- setprop("/controls/adirs/align-time", 5);
- }
- } else {
- if (getprop("/controls/adirs/align-time") != 600) {
- setprop("/controls/adirs/align-time", 600);
- }
- }
-
- if (gs > 5 or pitch > 5 or pitch < -5 or roll > 10 or roll < -10 or (ac1 < 110 and ac2 < 110 and dcbat < 25)) {
- if (getprop("/controls/adirs/ir[0]/align") == 1) {
- me.stopAlign(0,1);
- }
- if (getprop("/controls/adirs/ir[1]/align") == 1) {
- me.stopAlign(1,1);
- }
- if (getprop("/controls/adirs/ir[2]/align") == 1) {
- me.stopAlign(2,1);
- }
- }
- },
- knob: func(k) {
- knob = getprop("/controls/adirs/ir[" ~ k ~ "]/knob");
- if (knob == 0) {
- me.stopAlign(k,0);
- } else if (knob == 1) {
- me.beginAlign(k);
- } else if (knob == 2) {
- me.beginAlign(k);
- }
- },
- beginAlign: func(n) {
- ac1 = getprop("/systems/electrical/bus/ac-1");
- ac2 = getprop("/systems/electrical/bus/ac-2");
- dcbat = getprop("/systems/electrical/bus/dc-bat");
- setprop("/instrumentation/adirs/adr[" ~ n ~ "]/active", 1);
- if (getprop("/controls/adirs/ir[" ~ n ~ "]/align") != 1 and getprop("/instrumentation/adirs/ir[" ~ n ~ "]/aligned") != 1 and (ac1 >= 110 or ac2 >= 110 or dcbat >= 25)) {
- setprop("/controls/adirs/ir[" ~ n ~ "]/time", getprop("/sim/time/elapsed-sec"));
- setprop("/controls/adirs/ir[" ~ n ~ "]/align", 1);
- setprop("/controls/adirs/ir[" ~ n ~ "]/fault", 0);
- if (n == 0) {
- alignOne.start();
- } else if (n == 1) {
- alignTwo.start();
- } else if (n == 2) {
- alignThree.start();
- }
- }
- },
- stopAlign: func(n,f) {
- setprop("/controls/adirs/ir[" ~ n ~ "]/align", 0);
- if (f == 1) {
- setprop("/controls/adirs/ir[" ~ n ~ "]/fault", 1);
- } else {
- setprop("/controls/adirs/ir[" ~ n ~ "]/fault", 0);
- }
- if (n == 0) {
- alignOne.stop();
- } else if (n == 1) {
- alignTwo.stop();
- } else if (n == 2) {
- alignThree.stop();
- }
- setprop("/instrumentation/adirs/ir[" ~ n ~ "]/aligned", 0);
- setprop("/controls/adirs/mcducbtn", 0);
- },
- skip: func(n) {
- if (n == 0) {
- alignOne.stop();
- } else if (n == 1) {
- alignTwo.stop();
- } else if (n == 2) {
- alignThree.stop();
- }
- setprop("/controls/adirs/ir[" ~ n ~ "]/align", 0);
- setprop("/controls/adirs/ir[" ~ n ~ "]/fault", 0);
- setprop("/instrumentation/adirs/ir[" ~ n ~ "]/aligned", 1);
- },
-};
-
-var alignOne = maketimer(0.1, func {
- if (getprop("/controls/adirs/ir[0]/time") + getprop("/controls/adirs/align-time") >= getprop("/sim/time/elapsed-sec")) {
- if (getprop("/instrumentation/adirs/ir[0]/aligned") != 0) {
- setprop("/instrumentation/adirs/ir[0]/aligned", 0);
- }
- if (getprop("/controls/adirs/ir[0]/align") != 1) {
- setprop("/controls/adirs/ir[0]/align", 1);
- }
- } else {
- if (getprop("/instrumentation/adirs/ir[0]/aligned") != 1 and getprop("/controls/adirs/mcducbtn") == 1) {
- alignOne.stop();
- setprop("/instrumentation/adirs/ir[0]/aligned", 1);
- }
- if (getprop("/controls/adirs/ir[0]/align") != 0) {
- setprop("/controls/adirs/ir[0]/align", 0);
- }
- }
-});
-
-var alignTwo = maketimer(0.1, func {
- if (getprop("/controls/adirs/ir[1]/time") + getprop("/controls/adirs/align-time") >= getprop("/sim/time/elapsed-sec")) {
- if (getprop("/instrumentation/adirs/ir[1]/aligned") != 0) {
- setprop("/instrumentation/adirs/ir[1]/aligned", 0);
- }
- if (getprop("/controls/adirs/ir[1]/align") != 1) {
- setprop("/controls/adirs/ir[1]/align", 1);
- }
- } else {
- if (getprop("/instrumentation/adirs/ir[1]/aligned") != 1 and getprop("/controls/adirs/mcducbtn") == 1) {
- alignTwo.stop();
- setprop("/instrumentation/adirs/ir[1]/aligned", 1);
- }
- if (getprop("/controls/adirs/ir[1]/align") != 0) {
- setprop("/controls/adirs/ir[1]/align", 0);
- }
- }
-});
-
-var alignThree = maketimer(0.1, func {
- if (getprop("/controls/adirs/ir[2]/time") + getprop("/controls/adirs/align-time") >= getprop("/sim/time/elapsed-sec")) {
- if (getprop("/instrumentation/adirs/ir[2]/aligned") != 0) {
- setprop("/instrumentation/adirs/ir[2]/aligned", 0);
- }
- if (getprop("/controls/adirs/ir[2]/align") != 1) {
- setprop("/controls/adirs/ir[2]/align", 1);
- }
- } else {
- if (getprop("/instrumentation/adirs/ir[2]/aligned") != 1 and getprop("/controls/adirs/mcducbtn") == 1) {
- alignThree.stop();
- setprop("/instrumentation/adirs/ir[2]/aligned", 1);
- }
- if (getprop("/controls/adirs/ir[2]/align") != 0) {
- setprop("/controls/adirs/ir[2]/align", 0);
- }
- }
-});
-
-setlistener("/controls/adirs/ir[0]/knob", func {
- ADIRS.knob(0);
-});
-
-setlistener("/controls/adirs/ir[1]/knob", func {
- ADIRS.knob(1);
-});
-
-setlistener("/controls/adirs/ir[2]/knob", func {
- ADIRS.knob(2);
-});
+};
\ No newline at end of file
diff --git a/Nasal/Systems/ADIRS/ADR.nas b/Nasal/Systems/ADIRS/ADR.nas
index cb32b559..b995b2ed 100644
--- a/Nasal/Systems/ADIRS/ADR.nas
+++ b/Nasal/Systems/ADIRS/ADR.nas
@@ -9,17 +9,24 @@ var _selfTestTime = nil;
var ADIRU = {
# local vars
+ _alignTime: 0,
_voltageMain: 0,
_voltageBackup: 0,
_voltageLimitedTime: 0,
_noPowerTime: 0,
_timeVar: 0,
+ _roll: 0,
+ _pitch: 0,
+ _gs: 0,
num: 0,
+ aligned: 0,
+ inAlign: 0,
outputOn: 0, # 0 = disc, 1 = normal
mode: 0, # 0 = off, 1 = nav, 2 = att
energised: 0, # 0 = off, 1 = on
operative: 0, # 0 = off,
+ alignTimer: nil,
input: [],
output: [],
@@ -27,8 +34,18 @@ var ADIRU = {
new: func(n) {
var adiru = { parents:[ADIRU] };
adiru.num = n;
+ adiru.alignTimer = maketimer(0.1, adiru, me.alignLoop);
return adiru;
},
+ setOperative: func(newOperative) {
+ if (newOperative != me.operative) {
+ me.operative = newOperative;
+ if (newOperative) {
+ me.selfTest();
+ }
+ }
+ },
+ # Power and state
updateEnergised: func(mode) {
me.energised = mode != 0 ? 1 : 0;
},
@@ -41,6 +58,7 @@ var ADIRU = {
me._voltageLimitedTime = isLimited;
return me._voltageBackup;
},
+ # BITE
selfTest: func() {
ADIRSnew._selfTest = 1;
_selfTestTime = pts.Sim.Time.elapsedSec.getValue();
@@ -66,14 +84,67 @@ var ADIRU = {
ADIRSnew.selfTest();
},
- setOperative: func(newOperative) {
- if (newOperative != me.operative) {
- me.operative = newOperative;
- if (newOperative) {
- me.selfTest();
+ # Alignment
+ align: func(time) {
+ ADIRSnew.Lights.irFault[me.num].setBoolValue(0);
+ if (!ADIRSnew.skip.getValue()) {
+ if (time > 0 and me.aligned == 0 and me.inAlign == 0 and me.operative == 1) {
+ me._alignTime = pts.Sim.Time.elapsedSec.getValue() + time;
+ print("Alignment Started");
+ me.inAlign = 1;
+ if (me.alignTimer != nil) {
+ me.alignTimer.start();
+ }
+ }
+ } else {
+ if (me.aligned == 0 and me.inAlign == 0 and me.operative == 1) {
+ me._alignTime = pts.Sim.Time.elapsedSec.getValue() + 5;
+ print("Fast Alignment Started");
+ me.inAlign = 1;
+ if (me.alignTimer != nil) {
+ me.alignTimer.start();
+ }
}
}
},
+ stopAlignNoAlign: func() {
+ print("Stopping alignment or setting unaligned state");
+ me.inAlign = 0;
+ me.aligned = 0;
+ if (me.alignTimer != nil) {
+ me.alignTimer.stop();
+ }
+ },
+ stopAlignAligned: func() {
+ print("Aligned");
+ me.inAlign = 0;
+ me.aligned = 1;
+ if (me.alignTimer != nil) {
+ me.alignTimer.stop();
+ }
+ },
+ alignLoop: func() {
+ me._roll = pts.Orientation.roll.getValue();
+ me._pitch = pts.Orientation.pitch.getValue();
+ me._gs = pts.Velocities.groundspeed.getValue();
+
+ # todo use IR values
+ if (me._gs > 5 or abs(me._pitch) > 5 or abs(me._roll) > 10) {
+ me.stopAlignNoAlign();
+ print("Excessive motion, restarting");
+ me.update(); # update operative
+ me.align(calcAlignTime(pts.Position.latitude.getValue()));
+ } elsif (me.operative == 0) {
+ print("ADIRU " ~ me.num ~ " off");
+ me.stopAlignNoAlign();
+ } elsif (pts.Sim.Time.elapsedSec.getValue() >= me._alignTime) {
+ me.stopAlignAligned();
+ }
+ },
+ instAlign: func() {
+ me.stopAlignAligned();
+ },
+ # Update loop
update: func() {
me._timeVar = pts.Sim.Time.elapsedSec.getValue();
if (me.energised and !me._voltageMain and me._voltageLimitedTime and me._noPowerTime == 0) {
@@ -136,6 +207,13 @@ var ADIRSControlPanel = {
ADIRSnew.ADIRunits[n].mode = mode;
ADIRSnew.ADIRunits[n].updateEnergised(mode);
ADIRSnew.Switches.irModeSw[n].setValue(mode);
+ if (mode == 0) {
+ ADIRSnew.Lights.irFault[n].setBoolValue(0);
+ ADIRSnew.ADIRunits[n].stopAlignNoAlign();
+ } elsif (ADIRSnew.ADIRunits[n].aligned == 0) {
+ ADIRSnew.ADIRunits[n].update(); # update early so operative is set properly
+ ADIRSnew.ADIRunits[n].align(calcAlignTime(pts.Position.latitude.getValue())); # when you set NAV, it first acquires GPS position then acquires GPS. You then use IRS INIT > to set PPOS to align if you wish
+ }
}
}
};
@@ -155,7 +233,6 @@ var ADIRSnew = {
# ADIRS Units
ADIRunits: [nil, nil, nil],
- #IRunits: [nil, nil, nil],
# Electrical
mainSupply: [systems.ELEC.Bus.acEss, systems.ELEC.Bus.ac2, systems.ELEC.Bus.ac1],
@@ -180,6 +257,8 @@ var ADIRSnew = {
# Nodes
overspeedVFE: props.globals.initNode("/systems/navigation/adr/computation/overspeed-vfe-spd", 0, "INT"),
+ skip: props.globals.initNode("/controls/adirs/skip", 0, "BOOL"),
+ mcduControl: props.globals.initNode("/controls/adirs/mcducbtn", 0, "BOOL"),
# System
init: func() {
@@ -249,12 +328,26 @@ var ADIRSnew = {
};
+var calcAlignTime = func(latitude) {
+ return ((0.002 * (latitude * latitude)) + 5) * 60;
+};
+
setlistener("/systems/fmgc/cas-compare/cas-reject-all", func() {
if (pts.FMGC.CasCompare.rejectAll.getBoolValue()) {
fcu.athrOff("hard");
}
}, 0, 0);
+setlistener("/controls/adirs/skip", func() {
+ if (ADIRSnew.skip.getBoolValue()) {
+ for (i = 0; i < 3; i = i + 1) {
+ if (ADIRSnew.ADIRunits[i].inAlign == 1) {
+ ADIRSnew.ADIRunits[i].stopAlignAligned();
+ }
+ }
+ }
+}, 0, 0);
+
selfTestLoop = maketimer(0.2, func() {
if (pts.Sim.Time.elapsedSec.getValue() > _selfTestTime + 5) {
ADIRSnew.Lights.onBat.setBoolValue(0);
diff --git a/Nasal/Systems/APU.nas b/Nasal/Systems/APU.nas
new file mode 100644
index 00000000..9033032f
--- /dev/null
+++ b/Nasal/Systems/APU.nas
@@ -0,0 +1,67 @@
+# A3XX Auxilliary Power Unit
+# Jonathan Redpath (legoboyvdlp)
+
+# Copyright (c) 2019 Jonathan Redpath (legoboyvdlp)
+
+var APU = {
+ state: 0, # power up, watch, starting, run, cooldown, shutdown
+ nRpm: 0,
+ fuelValve: aircraft.door.new("/controls/apu/fuel-valve", 1),
+ inletFlap: aircraft.door.new("/controls/apu/inlet-flap", 12),
+ listenSignals: 0,
+ start: 0,
+ cancelCheckFlap: 0,
+ new: func() {
+ var a = { parents:[APU] };
+ return a;
+ },
+ setState: func(num) {
+ me.state = num;
+ },
+ powerOn: func() {
+ # apu able to receive emergency stop or start signals
+ me.fuelValve.open();
+ me.inletFlap.open();
+ me.listenSignals = 1;
+ settimer(me.setState(1), 3);
+ },
+ getStartSignal: func() {
+ if (me.listenSignals and me.state < 2 and me.nRpm < 7) {
+ me.start = 1;
+ me.startCheckFlap();
+ } elsif (me.listenSignals) {
+ settimer(me.getStartSignal(), 0);
+ }
+ },
+ startCheckFlap: func() {
+ if (me.inletFlap.getpos() != 1 and me.cancelCheckFlap == 0 and me.state == 1) {
+ settimer(me.startCheckFlap(), 0);
+ } elsif (me.cancelCheckFlap) {
+ me.cancelCheckFlap = 0;
+ } else {
+ me.setState(2);
+ }
+ },
+ getStopSignal: func() {
+ if (me.listenSignals) {
+ me.cancelCheckFlap = 1;
+ me.inletFlap.close();
+ # wait for flap close --> power down relay output
+ }
+ },
+};
+
+var APUController = {
+ _init: 0,
+ APU: nil,
+ init: func() {
+ if (!me._init) {
+ me.APU = APU.new();
+ }
+ },
+ loop: func() {
+ if (me.APU != nil) {
+ APU.update();
+ }
+ },
+};
\ No newline at end of file
diff --git a/Nasal/Systems/electrical.nas b/Nasal/Systems/electrical.nas
index e905f7b7..fd175ebb 100644
--- a/Nasal/Systems/electrical.nas
+++ b/Nasal/Systems/electrical.nas
@@ -13,6 +13,8 @@ var dc2 = 0;
# Main class
var ELEC = {
+ _timer1On: 0,
+ _timer2On: 0,
Bus: {
acEss: props.globals.getNode("/systems/electrical/bus/ac-ess"),
acEssShed: props.globals.getNode("/systems/electrical/bus/ac-ess-shed"),
@@ -227,20 +229,32 @@ var ELEC = {
# Autopilot Disconnection routines
if (me.Bus.dcEssShed.getValue() < 25) {
- if (getprop("/it-autoflight/output/ap1") == 1) {
- fcu.apOff("hard", 1);
- if (getprop("/it-autoflight/output/ap2") == 0) {
- fcu.athrOff("hard"); # TODO - athr master FMGC logic
- }
+ if (getprop("/it-autoflight/output/ap1") == 1 and !me._timer1On) {
+ me._timer1On = 1;
+ settimer(func() {
+ if (me.Bus.dcEssShed.getValue() < 25) {
+ fcu.apOff("hard", 1);
+ if (fcu.FCUController.activeFMGC.getValue() == 1) {
+ fcu.athrOff("hard");
+ }
+ }
+ me._timer1On = 0;
+ }, 0.1);
}
}
if (me.Bus.dc2.getValue() < 25) {
- if (getprop("/it-autoflight/output/ap2") == 1) {
- fcu.apOff("hard", 2);
- if (getprop("/it-autoflight/output/ap1") == 0) {
- fcu.athrOff("hard"); # TODO - athr master FMGC logic
- }
+ if (getprop("/it-autoflight/output/ap2") == 1 and !me._timer2On) {
+ me._timer2On = 1;
+ settimer(func() {
+ if (me.Bus.dc2.getValue() < 25) {
+ fcu.apOff("hard", 2);
+ if (fcu.FCUController.activeFMGC.getValue() == 2) {
+ fcu.athrOff("hard");
+ }
+ }
+ me._timer2On = 0;
+ }, 0.1);
}
}
},
diff --git a/Nasal/Systems/fire.nas b/Nasal/Systems/fire.nas
index d250b14c..7347c5d3 100644
--- a/Nasal/Systems/fire.nas
+++ b/Nasal/Systems/fire.nas
@@ -521,8 +521,8 @@ cargoDetectorLoop.new(2, 1, "/systems/fire/cargo/fwd/temperature", "/systems/fai
]);
# Create extinguisher bottles
-var extinguisherBottles = std.Vector.new([extinguisherBottle.new(0, "/systems/fire/engine1/disch1", "/systems/electrical/bus/dc-bat", "/systems/failures/engine-left-fire", "/systems/fire/engine1/warning-active"), extinguisherBottle.new(1, "/systems/fire/engine1/disch2", "/systems/electrical/bus/dc-2", "/systems/failures/engine-left-fire", "/systems/fire/engine1/warning-active"),
-extinguisherBottle.new(0, "/systems/fire/engine2/disch1", "/systems/electrical/bus/dc-bat", "/systems/failures/engine-right-fire", "/systems/fire/engine2/warning-active"), extinguisherBottle.new(1, "/systems/fire/engine2/disch2", "/systems/electrical/bus/dc-2", "/systems/failures/engine-right-fire", "/systems/fire/engine2/warning-active"),
+var extinguisherBottles = std.Vector.new([extinguisherBottle.new(0, "/systems/fire/engine1/disch1", "/systems/electrical/bus/dc-hot-1", "/systems/failures/engine-left-fire", "/systems/fire/engine1/warning-active"), extinguisherBottle.new(1, "/systems/fire/engine1/disch2", "/systems/electrical/bus/dc-2", "/systems/failures/engine-left-fire", "/systems/fire/engine1/warning-active"),
+extinguisherBottle.new(0, "/systems/fire/engine2/disch1", "/systems/electrical/bus/dc-hot-2", "/systems/failures/engine-right-fire", "/systems/fire/engine2/warning-active"), extinguisherBottle.new(1, "/systems/fire/engine2/disch2", "/systems/electrical/bus/dc-2", "/systems/failures/engine-right-fire", "/systems/fire/engine2/warning-active"),
extinguisherBottle.new(9, "/systems/fire/apu/disch", "/systems/electrical/bus/dc-bat", "/systems/failures/apu-fire", "/systems/fire/apu/warning-active") ]);
# There is only one bottle but the system will think there are two, so other parts work
@@ -585,6 +585,7 @@ eng1AgentTimerMakeTimerFunc = func() {
var timeToSetEng1 = eng1Time - etEng1;
eng1AgentTimer.setValue(timeToSetEng1);
} else {
+ eng1AgentTimer.setValue(99);
eng1AgentTimerMakeTimer.stop();
}
}
@@ -596,6 +597,7 @@ eng1Agent2TimerMakeTimerFunc = func() {
var timeToSetEng12 = eng1Time2 - etEng12;
eng1Agent2Timer.setValue(timeToSetEng12);
} else {
+ eng1Agent2Timer.setValue(99);
eng1Agent2TimerMakeTimer.stop();
}
}
@@ -626,6 +628,7 @@ eng2AgentTimerMakeTimerFunc = func() {
var timeToSetEng2 = eng2Time - etEng2;
eng2AgentTimer.setValue(timeToSetEng2);
} else {
+ eng2AgentTimer.setValue(99);
eng2AgentTimerMakeTimer.stop();
}
}
@@ -637,6 +640,7 @@ eng2Agent2TimerMakeTimerFunc = func() {
var timeToSetEng22 = eng2Time2 - etEng22;
eng2Agent2Timer.setValue(timeToSetEng22);
} else {
+ eng2Agent2Timer.setValue(99);
eng2Agent2TimerMakeTimer.stop();
}
}
diff --git a/Nasal/Systems/fuel.nas b/Nasal/Systems/fuel.nas
index 918f6d7e..3c9ae9c2 100644
--- a/Nasal/Systems/fuel.nas
+++ b/Nasal/Systems/fuel.nas
@@ -22,6 +22,10 @@ var FUEL = {
pumpRight1: props.globals.getNode("/controls/fuel/switches/pump-right-1"),
pumpRight2: props.globals.getNode("/controls/fuel/switches/pump-right-2"),
},
+ Pumps: {
+ apu: props.globals.getNode("/systems/fuel/pumps/apu-operate"),
+ allOff: props.globals.getNode("/systems/fuel/pumps/all-eng-pump-off"),
+ },
Valves: {
crossfeed: props.globals.getNode("/systems/fuel/valves/crossfeed-valve"),
lpValve1: props.globals.getNode("/systems/fuel/valves/engine-1-lp-valve"),
diff --git a/Sounds/A320-common-sound.xml b/Sounds/A320-common-sound.xml
index 53846b25..f7bfe05e 100644
--- a/Sounds/A320-common-sound.xml
+++ b/Sounds/A320-common-sound.xml
@@ -1557,6 +1557,7 @@
once
avionics
+ /sim/current-view/internal
/sim/sound/warnings/chime
10
@@ -1575,6 +1576,7 @@
+ /sim/current-view/internal
0.8
10
@@ -1590,6 +1592,7 @@
/sim/sound/warnings/cricket
+ /sim/current-view/internal
0.2
10
@@ -1605,6 +1608,7 @@
/sim/sound/warnings/stall-voice
+ /sim/current-view/internal
2.0
10
diff --git a/Sounds/cfm56-sound.xml b/Sounds/cfm56-sound.xml
index fd7700b1..5a9e5994 100644
--- a/Sounds/cfm56-sound.xml
+++ b/Sounds/cfm56-sound.xml
@@ -409,6 +409,9 @@
a320_external_idle_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idle.wav
@@ -440,6 +443,9 @@
a320_external_idle_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idle.wav
@@ -471,6 +477,9 @@
a320_external_idle_rear_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleRear.wav
@@ -502,6 +511,9 @@
a320_external_idle_rear_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleRear.wav
@@ -533,6 +545,9 @@
a320_external_idle_distant_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDist.wav
@@ -564,6 +579,9 @@
a320_external_idle_distant_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDist.wav
@@ -595,6 +613,9 @@
a320_external_idle_distant_side_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDistSide.wav
@@ -626,6 +647,9 @@
a320_external_idle_distant_side_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDistSide.wav
@@ -657,6 +681,9 @@
a320_external_idle_close_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleClose.wav
@@ -688,6 +715,9 @@
a320_external_idle_close_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleClose.wav
@@ -719,6 +749,9 @@
a320_external_spool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spool.wav
@@ -750,6 +783,9 @@
a320_external_spool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spool.wav
@@ -781,6 +817,9 @@
a320_external_lowspool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-lowspool.wav
@@ -812,6 +851,9 @@
a320_external_lowspool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-lowspool.wav
@@ -843,6 +885,9 @@
a320_external_spool_close_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolClose.wav
@@ -874,6 +919,9 @@
a320_external_spool_close_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolClose.wav
@@ -905,6 +953,9 @@
a320_external_spool_closeRear_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolCloseRear.wav
@@ -936,6 +987,9 @@
a320_external_spool_closeRear_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolCloseRear.wav
@@ -967,6 +1021,9 @@
a320_external_buzz_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-buzz.wav
@@ -998,6 +1055,9 @@
a320_external_buzz_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-buzz.wav
@@ -1029,6 +1089,9 @@
a320_external_buzz_distant_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-buzzDist.wav
@@ -1060,6 +1123,9 @@
a320_external_buzz_distant_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-buzzDist.wav
@@ -1091,6 +1157,9 @@
a320_external_rumble_distant_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleDist.wav
@@ -1119,6 +1188,9 @@
a320_external_rumble_distant_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleDist.wav
@@ -1147,6 +1219,9 @@
a320_external_rumble_side_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleSide.wav
@@ -1178,6 +1253,9 @@
a320_external_rumble_side_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleSide.wav
@@ -1209,6 +1287,9 @@
a320_external_rumble_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1240,6 +1321,9 @@
a320_external_rumble_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1271,6 +1355,9 @@
a320_external_rumble2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1302,6 +1389,9 @@
a320_external_rumble2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1333,6 +1423,9 @@
a320_external_reverse_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-reverse.wav
@@ -1364,6 +1457,9 @@
a320_external_reverse_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-reverse.wav
@@ -1401,6 +1497,9 @@
a320_wingaft_idle_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle.wav
@@ -1423,6 +1522,9 @@
a320_wingaft_idle_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle.wav
@@ -1445,6 +1547,9 @@
a320_wingaft_idle2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle2.wav
@@ -1467,6 +1572,9 @@
a320_wingaft_idle2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle2.wav
@@ -1489,6 +1597,9 @@
a320_wingaft_lowspool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1511,6 +1622,9 @@
a320_wingaft_lowspool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1533,6 +1647,9 @@
a320_wingaft_spool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1555,6 +1672,9 @@
a320_wingaft_spool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1577,6 +1697,9 @@
a320_wingaft_hum_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-hum.wav
@@ -1599,6 +1722,9 @@
a320_wingaft_hum_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-hum.wav
@@ -1621,6 +1747,9 @@
a320_wingaft_humfull_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-humfull.wav
@@ -1643,6 +1772,9 @@
a320_wingaft_humfull_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-humfull.wav
@@ -1665,6 +1797,9 @@
a320_wingaft_comb_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb.wav
@@ -1687,6 +1822,9 @@
a320_wingaft_comb_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb.wav
@@ -1709,6 +1847,9 @@
a320_wingaft_comb2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb-full.wav
@@ -1731,6 +1872,9 @@
a320_wingaft_comb2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb-full.wav
@@ -1753,6 +1897,9 @@
a320_wingaft_buzz_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-buzz.wav
@@ -1775,6 +1922,9 @@
a320_wingaft_buzz_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-buzz.wav
@@ -1797,6 +1947,9 @@
a320_wingaft_reverse_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-reverse.wav
@@ -1819,6 +1972,9 @@
a320_wingaft_reverse_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-reverse.wav
@@ -1852,6 +2008,9 @@
a320_wingfwd_idle_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle.wav
@@ -1874,6 +2033,9 @@
a320_wingfwd_idle_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle.wav
@@ -1896,6 +2058,9 @@
a320_wingfwd_idle2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle2.wav
@@ -1918,6 +2083,9 @@
a320_wingfwd_idle2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle2.wav
@@ -1940,6 +2108,9 @@
a320_wingfwd_lowspool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-lowspool.wav
@@ -1962,6 +2133,9 @@
a320_wingfwd_lowspool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-lowspool.wav
@@ -1984,6 +2158,9 @@
a320_wingfwd_spool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-lowspool.wav
@@ -2006,6 +2183,9 @@
a320_wingfwd_spool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-lowspool.wav
@@ -2028,6 +2208,9 @@
a320_wingfwd_hum_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-hum.wav
@@ -2050,6 +2233,9 @@
a320_wingfwd_hum_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-hum.wav
@@ -2072,6 +2258,9 @@
a320_wingfwd_comb_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-comb.wav
@@ -2094,6 +2283,9 @@
a320_wingfwd_comb_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-comb.wav
@@ -2116,6 +2308,9 @@
a320_wingfwd_comb2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-comb-full.wav
@@ -2138,6 +2333,9 @@
a320_wingfwd_comb2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-comb-full.wav
@@ -2160,6 +2358,9 @@
a320_wingfwd_buzz_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-buzz.wav
@@ -2182,6 +2383,9 @@
a320_wingfwd_buzz_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-buzz.wav
@@ -2204,6 +2408,9 @@
a320_wingfwd_reverse_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-reverse.wav
@@ -2226,6 +2433,9 @@
a320_wingfwd_reverse_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-reverse.wav
diff --git a/Sounds/leapx-sound.xml b/Sounds/leapx-sound.xml
index 7fc98501..68350e55 100644
--- a/Sounds/leapx-sound.xml
+++ b/Sounds/leapx-sound.xml
@@ -365,6 +365,9 @@
a320_external_idle_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idle.wav
@@ -396,6 +399,9 @@
a320_external_idle_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idle.wav
@@ -427,6 +433,9 @@
a320_external_idle_rear_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleRear.wav
@@ -458,6 +467,9 @@
a320_external_idle_rear_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleRear.wav
@@ -489,6 +501,9 @@
a320_external_idle_distant_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDist.wav
@@ -520,6 +535,9 @@
a320_external_idle_distant_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDist.wav
@@ -551,6 +569,9 @@
a320_external_idle_distant_side_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDistSide.wav
@@ -582,6 +603,9 @@
a320_external_idle_distant_side_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleDistSide.wav
@@ -613,6 +637,9 @@
a320_external_idle_close_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleClose.wav
@@ -644,6 +671,9 @@
a320_external_idle_close_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-idleClose.wav
@@ -675,6 +705,9 @@
a320_external_spool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spool.wav
@@ -706,6 +739,9 @@
a320_external_spool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spool.wav
@@ -737,6 +773,9 @@
a320_external_lowspool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-lowspool.wav
@@ -768,6 +807,9 @@
a320_external_lowspool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-lowspool.wav
@@ -799,6 +841,9 @@
a320_external_spool_close_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolClose.wav
@@ -830,6 +875,9 @@
a320_external_spool_close_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolClose.wav
@@ -861,6 +909,9 @@
a320_external_spool_closeRear_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolCloseRear.wav
@@ -892,6 +943,9 @@
a320_external_spool_closeRear_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-spoolCloseRear.wav
@@ -923,6 +977,9 @@
a320_external_rumble_distant_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleDist.wav
@@ -951,6 +1008,9 @@
a320_external_rumble_distant_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleDist.wav
@@ -979,6 +1039,9 @@
a320_external_rumble_side_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleSide.wav
@@ -1010,6 +1073,9 @@
a320_external_rumble_side_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumbleSide.wav
@@ -1041,6 +1107,9 @@
a320_external_rumble_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1072,6 +1141,9 @@
a320_external_rumble_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1103,6 +1175,9 @@
a320_external_rumble2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1134,6 +1209,9 @@
a320_external_rumble2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-rumble.wav
@@ -1165,6 +1243,9 @@
a320_external_reverse_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-reverse.wav
@@ -1196,6 +1277,9 @@
a320_external_reverse_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/external/cfm-reverse.wav
@@ -1233,6 +1317,9 @@
a320_wingaft_idle_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle.wav
@@ -1255,6 +1342,9 @@
a320_wingaft_idle_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle.wav
@@ -1277,6 +1367,9 @@
a320_wingaft_idle2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle2.wav
@@ -1299,6 +1392,9 @@
a320_wingaft_idle2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-idle2.wav
@@ -1321,6 +1417,9 @@
a320_wingaft_lowspool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1343,6 +1442,9 @@
a320_wingaft_lowspool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1365,6 +1467,9 @@
a320_wingaft_spool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1387,6 +1492,9 @@
a320_wingaft_spool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-lowspool.wav
@@ -1409,6 +1517,9 @@
a320_wingaft_hum_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-hum.wav
@@ -1431,6 +1542,9 @@
a320_wingaft_hum_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-hum.wav
@@ -1453,6 +1567,9 @@
a320_wingaft_humfull_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-humfull.wav
@@ -1475,6 +1592,9 @@
a320_wingaft_humfull_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-humfull.wav
@@ -1497,6 +1617,9 @@
a320_wingaft_comb_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb.wav
@@ -1519,6 +1642,9 @@
a320_wingaft_comb_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb.wav
@@ -1541,6 +1667,9 @@
a320_wingaft_comb2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb-full.wav
@@ -1563,6 +1692,9 @@
a320_wingaft_comb2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-comb-full.wav
@@ -1585,6 +1717,9 @@
a320_wingaft_reverse_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-reverse.wav
@@ -1607,6 +1742,9 @@
a320_wingaft_reverse_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingaft/cfm-reverse.wav
@@ -1640,6 +1778,9 @@
a320_wingfwd_idle_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle.wav
@@ -1662,6 +1803,9 @@
a320_wingfwd_idle_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle.wav
@@ -1684,6 +1828,9 @@
a320_wingfwd_idle2_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle2.wav
@@ -1706,6 +1853,9 @@
a320_wingfwd_idle2_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-idle2.wav
@@ -1728,6 +1878,9 @@
a320_wingfwd_lowspool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-lowspool.wav
@@ -1750,6 +1903,9 @@
a320_wingfwd_lowspool_2
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-lowspool.wav
@@ -1772,6 +1928,9 @@
a320_wingfwd_spool_1
+
+ sim/current-view/internal
+
looped
Aircraft/A320-family/Sounds/SASA/CFM56B/wingfwd/cfm-lowspool.wav
@@ -1794,6 +1953,9 @@
a320_wingfwd_spool_2
+
+