1
0
Fork 0

Bugfix electrical system

This commit is contained in:
legoboyvdlp R 2019-10-19 13:37:16 +01:00
parent b9f918d202
commit 040c72ccb6
3 changed files with 5 additions and 4 deletions

View file

@ -1701,7 +1701,7 @@ var canvas_lowerECAM_elec = {
me["ELEC-Line-AC2-ACESS"].hide(); me["ELEC-Line-AC2-ACESS"].hide();
} }
if (tr1_fault.getValue() != 1) { if (getprop("/systems/electrical/relay/tr-contactor-1/contact-pos") == 1) {
if (ac1.getValue() < 110) { if (ac1.getValue() < 110) {
me["ELEC-Line-AC1-TR1"].setColorFill(0.7333,0.3803,0); me["ELEC-Line-AC1-TR1"].setColorFill(0.7333,0.3803,0);
} else { } else {
@ -1714,7 +1714,7 @@ var canvas_lowerECAM_elec = {
me["ELEC-Line-TR1-DC1"].hide(); me["ELEC-Line-TR1-DC1"].hide();
} }
if (tr2_fault.getValue() != 1) { if (getprop("/systems/electrical/relay/tr-contactor-2/contact-pos") == 1) {
if (ac2.getValue() < 110) { if (ac2.getValue() < 110) {
me["ELEC-Line-AC2-TR2"].setColorFill(0.7333,0.3803,0); me["ELEC-Line-AC2-TR2"].setColorFill(0.7333,0.3803,0);
} else { } else {

View file

@ -249,7 +249,7 @@ var ECAM = {
setprop("/ECAM/warning-phase", 3); setprop("/ECAM/warning-phase", 3);
} else if (phase == 3 and speed >= 80) { } else if (phase == 3 and speed >= 80) {
setprop("/ECAM/warning-phase", 4); setprop("/ECAM/warning-phase", 4);
} else if (phase == 4 and getprop("/fdm/jsbsim/position/wow") == 0) { # Liftoff } else if ((phase >= 2 and phase <= 4) and getprop("/fdm/jsbsim/position/wow") == 0) { # Liftoff
setprop("/ECAM/warning-phase", 5); setprop("/ECAM/warning-phase", 5);
} else if (phase == 5 and getprop("/position/gear-agl-ft") >= 1500) { } else if (phase == 5 and getprop("/position/gear-agl-ft") >= 1500) {
setprop("/ECAM/warning-phase", 6); setprop("/ECAM/warning-phase", 6);

View file

@ -519,6 +519,7 @@
<switch name="/systems/electrical/relay/apu-glc/contact-pos"> <switch name="/systems/electrical/relay/apu-glc/contact-pos">
<default value="0"/> <default value="0"/>
<test logic="AND" value="1"> <test logic="AND" value="1">
/controls/APU/master eq 1
/controls/electrical/switches/apu eq 1 /controls/electrical/switches/apu eq 1
/systems/electrical/sources/apu/output-volt ge 110 /systems/electrical/sources/apu/output-volt ge 110
/systems/electrical/sources/apu/output-volt lt 130 /systems/electrical/sources/apu/output-volt lt 130
@ -992,7 +993,7 @@
/systems/electrical/relay/tr-contactor-2/output lt 25 /systems/electrical/relay/tr-contactor-2/output lt 25
/systems/electrical/relay/emer-glc/output ge 110 /systems/electrical/relay/emer-glc/output ge 110
</test> </test>
/systems/electrical/sources/ess-tr/output-volt ge 110 /systems/electrical/sources/ess-tr/output-volt ge 25
</test> </test>
</switch> </switch>